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

Refactor search bar & filters to conditionally render new look with application header #7687

Merged
merged 4 commits into from
Aug 15, 2024

Conversation

zhongnansu
Copy link
Member

@zhongnansu zhongnansu commented Aug 12, 2024

Description

  • Conditionally render new filter with new application header behind the toggle
  • hide filter row, when there's no filters applied
  • move save query into the filter menu
  • add additional "Add filter" into menu
  • add additional "Save query" into menu
  • move combined menu to be in front of the search bar

Issues Resolved

Screenshot

  • By default, with "newHome" toggle turned off, search bar & filter bar UI remains the same as what currently is.
iShot_2024-08-13_12.47.26.mp4
  • With newHome toggle turned on, new application header will show up, along with the new look of filter bar & search bar menu options
iShot_2024-08-13_12.51.05.mp4

Testing the changes

Changelog

  • refactor: Refactor search bar & filters to conditionally render new look with application header

Check List

  • All tests pass
    • yarn test:jest
    • yarn test:jest_integration
  • New functionality includes testing.
  • New functionality has been documented.
  • Update CHANGELOG.md
  • Commits are signed per the DCO using --signoff

Copy link
Contributor

❌ Empty Changelog Section

The Changelog section in your PR description is empty. Please add a valid changelog entry or entries. If you did add a changelog entry, check to make sure that it was not accidentally included inside the comment block in the Changelog section.

@github-actions github-actions bot added failed changeset Skip-Changelog PRs that are too trivial to warrant a changelog or release notes entry and removed failed changeset labels Aug 12, 2024
Copy link

codecov bot commented Aug 12, 2024

Codecov Report

Attention: Patch coverage is 77.55102% with 22 lines in your changes missing coverage. Please review.

Project coverage is 63.78%. Comparing base (265a176) to head (c4520cd).
Report is 204 commits behind head on main.

Files with missing lines Patch % Lines
...ugins/data/public/ui/filter_bar/filter_options.tsx 81.17% 9 Missing and 7 partials ⚠️
...c/plugins/data/public/ui/search_bar/search_bar.tsx 33.33% 2 Missing and 2 partials ⚠️
...ry_management/saved_query_management_component.tsx 71.42% 0 Missing and 2 partials ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #7687      +/-   ##
==========================================
+ Coverage   63.74%   63.78%   +0.04%     
==========================================
  Files        3637     3650      +13     
  Lines       80426    80896     +470     
  Branches    12786    12873      +87     
==========================================
+ Hits        51264    51600     +336     
- Misses      26030    26135     +105     
- Partials     3132     3161      +29     
Flag Coverage Δ
Linux_1 30.04% <ø> (+0.20%) ⬆️
Linux_2 55.82% <ø> (ø)
Linux_3 40.45% <77.55%> (+0.07%) ⬆️
Linux_4 31.30% <ø> (+<0.01%) ⬆️
Windows_1 30.05% <ø> (+0.20%) ⬆️
Windows_2 55.77% <ø> (ø)
Windows_3 40.45% <77.55%> (+0.07%) ⬆️
Windows_4 31.30% <ø> (+<0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@zhongnansu zhongnansu changed the title Refactor search bar & filters to conditionally render with new application header Refactor search bar & filters to conditionally render new look with application header Aug 12, 2024
@zhongnansu zhongnansu force-pushed the header-filter branch 2 times, most recently from 3d4c342 to 1b0be09 Compare August 12, 2024 23:56
Signed-off-by: Zhongnan Su <[email protected]>
Signed-off-by: Zhongnan Su <[email protected]>
virajsanghvi
virajsanghvi previously approved these changes Aug 15, 2024
@Flyingliuhub
Copy link
Member

please make sure that Changelog before you merge, thanks

Flyingliuhub
Flyingliuhub previously approved these changes Aug 15, 2024
@github-actions github-actions bot removed the Skip-Changelog PRs that are too trivial to warrant a changelog or release notes entry label Aug 15, 2024
@@ -55,3 +55,12 @@
margin-top: $euiSize * -1;
}
}

.globalFilterGroup__removeAllFilters {
Copy link
Collaborator

Choose a reason for hiding this comment

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

Can you please create an issue on OUI to allow setting the color in OuiContextItem?

Copy link
Member Author

Choose a reason for hiding this comment

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

Copy link
Collaborator

@virajsanghvi virajsanghvi left a comment

Choose a reason for hiding this comment

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

Approving assuming checks pass

@zhongnansu zhongnansu merged commit 97ddd8a into opensearch-project:main Aug 15, 2024
67 checks passed
opensearch-trigger-bot bot pushed a commit that referenced this pull request Aug 15, 2024
…pplication header (#7687)

* Refactor search bar & filters to conditionally render with new application header

Signed-off-by: Zhongnan Su <[email protected]>

* add more test coverage

Signed-off-by: Zhongnan Su <[email protected]>

* address comments

Signed-off-by: Zhongnan Su <[email protected]>

* Changeset file for PR #7687 created/updated

---------

Signed-off-by: Zhongnan Su <[email protected]>
Co-authored-by: opensearch-changeset-bot[bot] <154024398+opensearch-changeset-bot[bot]@users.noreply.github.com>
(cherry picked from commit 97ddd8a)
Signed-off-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
zhongnansu pushed a commit that referenced this pull request Aug 15, 2024
…pplication header (#7687) (#7719)

* Refactor search bar & filters to conditionally render with new application header



* add more test coverage



* address comments



* Changeset file for PR #7687 created/updated

---------



(cherry picked from commit 97ddd8a)

Signed-off-by: Zhongnan Su <[email protected]>
Signed-off-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: opensearch-changeset-bot[bot] <154024398+opensearch-changeset-bot[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants