Skip to content

Conversation

@Miodec
Copy link
Member

@Miodec Miodec commented Jan 21, 2026

Also updates and adds some dom utils

Copilot AI review requested due to automatic review settings January 21, 2026 09:50
@monkeytypegeorge monkeytypegeorge added the frontend User interface or web stuff label Jan 21, 2026
@github-actions github-actions bot added the waiting for review Pull requests that require a review before continuing label Jan 21, 2026
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR refactors the SortedTable class to remove jQuery dependency by replacing it with custom DOM utility wrappers (ElementWithUtils and ElementsWithUtils). The refactoring maintains the same functionality while using a more modern, type-safe approach.

Changes:

  • Replaced jQuery methods with custom DOM utilities in sorted-table.ts
  • Extended ElementWithUtils.append() to support arrays and ElementsWithUtils
  • Added getChildren() methods to both ElementWithUtils and ElementsWithUtils
  • Added appendHtml() method to ElementsWithUtils

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated no comments.

File Description
frontend/src/ts/utils/sorted-table.ts Refactored to use ElementWithUtils instead of jQuery, replacing jQuery methods with custom DOM utility equivalents
frontend/src/ts/utils/dom.ts Extended append() method to handle arrays, added getChildren() and appendHtml() methods to support the refactoring
frontend/src/ts/pages/friends.ts Updated SortedTable instantiation to pass ElementWithUtils via qsr() instead of string selector
frontend/src/ts/pages/account.ts Updated SortedTableWithLimit instantiation to pass ElementWithUtils via qsr() instead of string selector

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@github-actions github-actions bot removed the waiting for review Pull requests that require a review before continuing label Jan 21, 2026
@Miodec Miodec merged commit f4a756d into master Jan 21, 2026
14 checks passed
@Miodec Miodec deleted the sorted-table branch January 21, 2026 10:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

frontend User interface or web stuff

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants