-
Notifications
You must be signed in to change notification settings - Fork 8.3k
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] Fix time zone for field popover histogram and remove getTimeZone duplicates #172705
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reused this implementation
Pinging @elastic/kibana-data-discovery (Team:DataDiscovery) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanx Julia for creating this package for us, it will be very helpful in the future. LGTM!
LGTM 🎉 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice cleanup! 🧹 🧼
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice cleanup! And fixes the issue too 👍 LGTM, thanks!
}); | ||
|
||
afterAll(() => { | ||
moment.tz.setDefault(originalTimezone ? originalTimezone.name : ''); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nit: It doesn't look like originalTimezone
is ever set.
}); | ||
|
||
it('returns timezone defined on uiSettings', () => { | ||
const timezone = 'America/Toronto'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🇨🇦
@elasticmachine merge upstream |
💛 Build succeeded, but was flaky
Failed CI StepsMetrics [docs]Module Count
Public APIs missing comments
Async chunks
Page load bundle
History
To update your PR or re-run it, just comment with: cc @jughosta |
Summary
This PR creates a new package
@kbn/visualization-utils
and movesgetTimeZone
helper into it. Also the PR removes duplicates of other similar helpers.And the histogram in the field popover has now the same time zone configuration as the the main hits histogram:
For testing
Change
dateFormat:tz
in Advanced Settings and check if histograms are rendered accordingly.