Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[R20-1952][R20-1954] add support for extending search bar #1158

Merged
merged 7 commits into from
May 27, 2024

Conversation

lambry
Copy link
Contributor

@lambry lambry commented May 12, 2024

Issue:
https://digital-vic.atlassian.net/browse/R20-1952
https://digital-vic.atlassian.net/browse/R20-1954

What I did

  • Support for extending the search term parameters, i.e. adding custom search term parameters
  • Add slot to RplSearchBar to accommodate custom functionality e.g. a drop down to choose what the search term queries against, also adds prop to manage the clear button display
  • Support for overriding the search bar component in listings and custom collections
  • Support for using a function to handle the query config
  • Allow sorting aggregation order for dropdowns
  • Add option to hide the search bar entirely i.e. show only the filters (also adds option to hide the search form entirely in custom collection to bring it inline with listings)
  • Fix some search bar console errors
Screenshot 2024-05-13 at 9 09 08 AM

Mobile example
Screenshot 2024-05-13 at 11 52 41 AM

Showing only filters
Screenshot 2024-05-14 at 8 24 07 AM

Checklist

For all PR's

  • I've added relevant changes to the project Readme if needed.
  • I've updated the documentation site as needed.
  • I have added cypress tests to cover my changes (if not applicable, please state why in a comment)

For new components only

  • I have added a story covering all variants
  • I have checked a11y tab in storybook passes
  • Any events are emitted on the event bus

…rch listing search bar

adds support for extending the search term parameters, and queryConfig, RplSearchBar
@lambry lambry self-assigned this May 12, 2024
Copy link

netlify bot commented May 12, 2024

Deploy Preview for ripple-docs canceled.

Name Link
🔨 Latest commit c4e77bc
🔍 Latest deploy log https://app.netlify.com/sites/ripple-docs/deploys/6653c9d8fd78e400089db053

Copy link

cypress bot commented May 13, 2024

Passing run #1791 ↗︎

0 155 0 0 Flakiness 0

Details:

feat(@dpc-sdp/ripple-tide-search): always give custom query config functions con...
Project: ripple-framework Commit: c4e77bccf3
Status: Passed Duration: 06:53 💡
Started: May 26, 2024 11:49 PM Ended: May 26, 2024 11:56 PM

Review all test suite changes for PR #1158 ↗︎

@mockserver
Example: Should only show filters when showFiltersOnly is set
Given I load the page fixture with "/landingpage/custom-collection/page"
And the custom collection config has "showFiltersOnly" set to "true"
Copy link
Contributor

Choose a reason for hiding this comment

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

This is picky but I still think that:
And the custom collection is set to only show filters
is more future proof, even though you need to add more step definitions.

If "showFiltersOnly" ever changes we'll have to update it anywhere it's reference

@dylankelly dylankelly added this pull request to the merge queue May 27, 2024
Merged via the queue into develop with commit 2fb085e May 27, 2024
8 checks passed
@dylankelly dylankelly deleted the feature/R20-1952-search-term-extension-conf branch May 27, 2024 00:05
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.

3 participants