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

Fix (discover): Fix dismiss callout and next styling #4938

Conversation

joshuarrrr
Copy link
Member

@joshuarrrr joshuarrrr commented Sep 5, 2023

Description

Fixes some small styling issues identified by @KrooshalUX and @kgcreative when reviewing next theming

  1. Fix onDismiss prop of callout
  2. Put callout in panel for better alignment in discover
  3. Add subdued to combobox panel
  4. Use primary-derived color for field titles in discover (and lint-ignore)

Note - I tried to fix the histogram rect highlight color in next dark mode, but can't figure out the problem. I got as far as confirming that both discover and legacy_discover pass the same styling props, but somehow it's not applied the same in each case.

I also notices some other minor fit and finish issues in the video:

  1. Layout jank when hovering on the source, as the inline text adjusts its width to make room for the expand button
  2. Loading spinner sometimes overlaps callout and other elements
  3. Time range not maintained when switching
  4. The way field names break across lines seems less than ideal

Issues Resolved

Screenshot

Screen.Recording.2023-09-05.at.3.48.24.PM.mov

Testing the changes

Check List

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

1. Fix `onDismiss` prop of callout
2. Put callout in panel for better alignment in discover
3. Add `subdued` to combobox panel
4. Use `primary`-derived color for field titles in discover (and lint-ignore)

Signed-off-by: Josh Romero <rmerqg@amazon.com>
Signed-off-by: Josh Romero <rmerqg@amazon.com>
kavilla
kavilla previously approved these changes Sep 5, 2023
@kavilla
Copy link
Member

kavilla commented Sep 5, 2023

Backporting for 2.10 right?

abbyhu2000
abbyhu2000 previously approved these changes Sep 5, 2023
fix conflict
@joshuarrrr joshuarrrr dismissed stale reviews from abbyhu2000 and kavilla via 50237e7 September 5, 2023 23:14
@@ -49,11 +49,27 @@ export default function DiscoverCanvas({ setHeaderActionMenu, history }: ViewPro
if (isCallOutVisible) {
callOut = (
<EuiFlexItem grow={false}>
<EuiPanel hasBorder={false} hasShadow={false} color="transparent" paddingSize="s">
Copy link
Member

Choose a reason for hiding this comment

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

Why do we have 2 callouts here?

Copy link
Member Author

Choose a reason for hiding this comment

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

that was a merge conflict - should be fixed

Copy link
Member Author

Choose a reason for hiding this comment

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

oh, somehow managed to not commit - let me try again.

Copy link
Member Author

Choose a reason for hiding this comment

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

ha, OK, yeah, this should be fixed - but doublecheck my resolution here.

ashwin-pc
ashwin-pc previously approved these changes Sep 5, 2023
@ashwin-pc ashwin-pc added discover for discover reinvent de-angular de-angularize work Skip-Changelog PRs that are too trivial to warrant a changelog or release notes entry data explorer Issues related to the Data Explorer project labels Sep 5, 2023
abbyhu2000
abbyhu2000 previously approved these changes Sep 5, 2023
@codecov
Copy link

codecov bot commented Sep 5, 2023

Codecov Report

Merging #4938 (dce11a3) into main (5eedbb5) will not change coverage.
The diff coverage is n/a.

@@           Coverage Diff           @@
##             main    #4938   +/-   ##
=======================================
  Coverage   66.39%   66.39%           
=======================================
  Files        3398     3398           
  Lines       64815    64815           
  Branches    10362    10362           
=======================================
  Hits        43033    43033           
+ Misses      19221    19198   -23     
- Partials     2561     2584   +23     
Flag Coverage Δ
Linux_1 34.84% <ø> (ø)
Linux_2 55.16% <ø> (ø)
Linux_3 44.23% <ø> (ø)
Linux_4 34.92% <ø> (ø)
Windows_1 34.86% <ø> (ø)
Windows_2 55.12% <ø> (ø)
Windows_3 44.24% <ø> (ø)
Windows_4 34.92% <ø> (ø)

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

Files Changed Coverage Δ
.../data_explorer/public/components/sidebar/index.tsx 3.12% <ø> (ø)
...omponents/data_grid/data_grid_table_cell_value.tsx 70.83% <ø> (ø)
.../public/application/components/discover_legacy.tsx 0.00% <ø> (ø)

... and 16 files with indirect coverage changes

Signed-off-by: Josh Romero <rmerqg@amazon.com>
@joshuarrrr joshuarrrr dismissed stale reviews from abbyhu2000 and ashwin-pc via 47b0b26 September 6, 2023 00:07
@kavilla
Copy link
Member

kavilla commented Sep 6, 2023

@joshuarrrr looks like it just needs a snapshot updating

Signed-off-by: Josh Romero <rmerqg@amazon.com>
@kavilla
Copy link
Member

kavilla commented Sep 6, 2023

Will set DCO to pass, it's being squashed anyways.

@joshuarrrr joshuarrrr merged commit d3388c5 into opensearch-project:main Sep 6, 2023
54 checks passed
@joshuarrrr joshuarrrr deleted the chore/tweak-data-explorer-next-theme branch September 6, 2023 21:41
opensearch-trigger-bot bot pushed a commit that referenced this pull request Sep 6, 2023
* Fix (discover): Fix dismiss callout and next styling

1. Fix `onDismiss` prop of callout
2. Put callout in panel for better alignment in discover
3. Add `subdued` to combobox panel
4. Use `primary`-derived color for field titles in discover (and lint-ignore)

Signed-off-by: Josh Romero <rmerqg@amazon.com>

* Update index.tsx

fix conflict

* fix linting indentation

Signed-off-by: Josh Romero <rmerqg@amazon.com>

* update snapshot

Signed-off-by: Josh Romero <rmerqg@amazon.com>

---------

Signed-off-by: Josh Romero <rmerqg@amazon.com>
(cherry picked from commit d3388c5)
Signed-off-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
joshuarrrr pushed a commit that referenced this pull request Sep 7, 2023
* Fix (discover): Fix dismiss callout and next styling

1. Fix `onDismiss` prop of callout
2. Put callout in panel for better alignment in discover
3. Add `subdued` to combobox panel
4. Use `primary`-derived color for field titles in discover (and lint-ignore)



* Update index.tsx

fix conflict

* fix linting indentation



* update snapshot



---------


(cherry picked from commit d3388c5)

Signed-off-by: Josh Romero <rmerqg@amazon.com>
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>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport 2.x data explorer Issues related to the Data Explorer project de-angular de-angularize work discover for discover reinvent distinguished-contributor Skip-Changelog PRs that are too trivial to warrant a changelog or release notes entry v2.10.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants