stable

Clone or download

Read-only

feat: Filter list of authors

part of story #35821 Pull request new home page - Filter on Authors In this contribution, it is made possible to filter the lists of items displayed in the selectors-dropdown through a specific callback. Note: - I had to override the default hotkeys-js filter callback, otherwise the shortcuts are triggered when the user is typing in the input. How to test: - Click [+ Add filter] and click on "Author" in the menu - Filter the authors using the input --> It works Change-Id: Icc68ece9d6d2ce4112518811c5b7f8c9796fdb55

Modified Files

Name
A lib/frontend/keyboard-shortcuts/src/filter/hotkeys-filter.test.ts +99 −0 Go to diff View file
A lib/frontend/keyboard-shortcuts/src/filter/hotkeys-filter.ts +43 −0 Go to diff View file
M lib/frontend/keyboard-shortcuts/src/handle-shortcuts-group.ts +2 −0 Go to diff View file
M plugins/pullrequest/scripts/lib/selectors-dropdown/src/elements/SelectorsDropdown.ts +5 −0 Go to diff View file
M plugins/pullrequest/scripts/lib/selectors-dropdown/src/elements/SelectorsDropdownAutocompleter.test.ts +2 −1 Go to diff View file
M plugins/pullrequest/scripts/lib/selectors-dropdown/src/elements/SelectorsDropdownAutocompleter.ts +13 −3 Go to diff View file
M plugins/pullrequest/scripts/lib/selectors-dropdown/src/main.ts +1 −0 Go to diff View file
M plugins/pullrequest/scripts/lib/selectors-dropdown/tests/SelectorEntryStub.ts +4 −0 Go to diff View file
A plugins/pullrequest/scripts/pullrequest-homepage/src/components/Filters/Author/AuthorFilteringCallback.test.ts +45 −0 Go to diff View file
A plugins/pullrequest/scripts/pullrequest-homepage/src/components/Filters/Author/AuthorFilteringCallback.ts +38 −0 Go to diff View file
M plugins/pullrequest/scripts/pullrequest-homepage/src/components/Filters/Author/AuthorSelectorEntry.ts +7 −1 Go to diff View file
M plugins/pullrequest/scripts/pullrequest-homepage/src/components/Filters/Author/AuthorTemplatingCallback.ts +1 −4 Go to diff View file