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

[Discover] Don't display hide/show button for histogram when there's no time filter #85424

Merged

Conversation

kertal
Copy link
Member

@kertal kertal commented Dec 9, 2020

Summary

Before this PR the hide/show button for Discover's histogram was also displayed when using an index pattern without timefield. Since this makes no sense, this button is no longer displayed in this case.

Index pattern with timefield:
Bildschirmfoto 2020-12-14 um 14 37 41

index pattern without timefield
Bildschirmfoto 2020-12-14 um 14 41 56

Checklist

@kertal kertal self-assigned this Dec 9, 2020
@kertal kertal added the Feature:Discover Discover Application label Dec 9, 2020
@kertal
Copy link
Member Author

kertal commented Dec 14, 2020

@elasticmachine merge upstream

@kertal kertal added release_note:skip Skip the PR/issue when compiling release notes v7.11.0 v8.0.0 Team:Visualizations Visualization editors, elastic-charts and infrastructure labels Dec 14, 2020
@kertal kertal marked this pull request as ready for review December 14, 2020 11:32
@kertal kertal requested a review from a team December 14, 2020 11:32
@elasticmachine
Copy link
Contributor

Pinging @elastic/kibana-app (Team:KibanaApp)

@kertal kertal requested review from timroes and majagrubic December 14, 2020 13:42
Copy link
Contributor

@majagrubic majagrubic left a comment

Choose a reason for hiding this comment

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

Tested this on Mac OS in Chrome, works great. Well done on writing the test as well!

if (key === SAMPLE_SIZE_SETTING) {
return 10;
}
return false;
Copy link
Contributor

Choose a reason for hiding this comment

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

Why false here? Can we return 0 or something for consistency?

Copy link
Member Author

Choose a reason for hiding this comment

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

It was copy and past of the data grid PR, can also improved there. Good catche, I've removed the return. we will need this more often in our unit tests, and can extend it this with valid returns.

@kibanamachine
Copy link
Contributor

💚 Build Succeeded

Metrics [docs]

Async chunks

Total size of all lazy-loaded chunks that will be downloaded as the user navigates the app

id before after diff
discover 450.4KB 450.5KB +70.0B

Distributable file count

id before after diff
default 47129 47889 +760

History

To update your PR or re-run it, just comment with:
@elasticmachine merge upstream

@kertal kertal merged commit 39360a2 into elastic:master Dec 15, 2020
kertal added a commit to kertal/kibana that referenced this pull request Dec 15, 2020
kertal added a commit that referenced this pull request Dec 15, 2020
gmmorris added a commit to ymao1/kibana that referenced this pull request Dec 15, 2020
* master: (66 commits)
  [Alerting] fixes broken Alerting Example plugin (elastic#85774)
  [APM] Service overview instances table (elastic#85770)
  [Security Solution] Unskip timeline creation Cypress test (elastic#85871)
  properly recognize enterprise licenses (elastic#85849)
  [SecuritySolution][Detections] Adds SavedObject persistence to Signals Migrations (elastic#85690)
  [TSVB] Fix functional tests flakiness and unskip them (elastic#85388)
  [Fleet] Change permissions for Fleet enroll role (elastic#85802)
  Gauge visualization can no longer be clicked to filter on values since Kibana 7.10.0 (elastic#84768)
  [Security Solution][Detections] Add alert source to detection rule action context (elastic#85488)
  [Discover] Don't display hide/show button for histogram when there's no time filter (elastic#85424)
  skip flaky suite (elastic#78553)
  License checks for alerts plugin (elastic#85649)
  skip flaky suite (elastic#84992)
  skip 'query return results valid for scripted field' elastic#78553
  Allow action types to perform their own mustache variable escaping in parameter templates (elastic#83919)
  [ML] More machine learning links in doc_links_service.ts (elastic#85365)
  Removed Alerting & Event Log deprecated fields that should not be using (elastic#85652)
  Closes elastic#79995 by adding new tab in transaction details to show related trace logs. (elastic#85859)
  Fix outdated jest snapshot
  [Maps] Surface on prem EMS (elastic#85729)
  ...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Feature:Discover Discover Application release_note:skip Skip the PR/issue when compiling release notes Team:Visualizations Visualization editors, elastic-charts and infrastructure v7.11.0 v8.0.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants