Skip to content

feat(sortableTable): auto-build filters#1178

Open
wesleyboar wants to merge 4 commits into
mainfrom
feat/sortableTable-auto-filter
Open

feat(sortableTable): auto-build filters#1178
wesleyboar wants to merge 4 commits into
mainfrom
feat/sortableTable-auto-filter

Conversation

@wesleyboar

@wesleyboar wesleyboar commented Jun 9, 2026

Copy link
Copy Markdown
Member

Overview

Sortable tables can declare filters in data-sortable-filters JSON; sortableTable.js clones a shared page template and wires search, column selects, and result counts before List.js init.

Important

  • Restore <i class="icon icon-search"></i>.
  • Choose a path:
    • Either: Split sortableTable sort logic and filter logic.
    • Or: Make CMS WYSIWYG support data-aria-* in markup.
  • Polish code.

Related

Changes

  • added includes/sortable_table_filter_templates.html and include in assets_core_delayed.html
  • updated sortableTable.js to build filter fieldsets from template + JSON specs
  • updated module demo HTML and tmp/pr-1169.html for local smoke test
  • updated deferred plan doc (steps 5–6 on branch)

Testing

  1. Open tmp/pr-1169.html with a local static server and ./sortableTable.js (or module path in repo).
  2. Confirm sort, search, column selects, and result count update.
  3. After deploy, any page with delayed core assets gets #sortable-table-filters once per page.

UI

Screenshots: pending upload

Notes

After merge and release, bump tup-ui snippet sortableTable.js jsDelivr pin from branch to the new Core-CMS tag. Step 7 (CKEditor aria-* allowlist) remains a separate PR to main.

Tables with data-sortable-filters get a cloned fieldset before init; shared template ships via delayed assets and tup-ui snippet.
@qodo-code-review

Copy link
Copy Markdown

Qodo reviews are paused for this user.

Troubleshooting steps vary by plan Learn more →

On a Teams plan?
Reviews resume once this user has a paid seat and their Git account is linked in Qodo.
Link Git account →

Using GitHub Enterprise Server, GitLab Self-Managed, or Bitbucket Data Center?
These require an Enterprise plan - Contact us
Contact us →

Filter labels keep abbr and other header HTML; fallback to JSON label or column name when the th is empty.
@wesleyboar wesleyboar changed the title feat(sortableTable): JS-built filters from data-sortable-filters feat(sortableTable): auto-build filters Jun 9, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant