-
Notifications
You must be signed in to change notification settings - Fork 77
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(input-time-zone): fix handling of unknown and cityless time zones from offset display mode #7947
fix(input-time-zone): fix handling of unknown and cityless time zones from offset display mode #7947
Conversation
…es from offset display mode
@@ -4,6 +4,48 @@ import { InputTimeZoneMessages } from "./assets/input-time-zone/t9n"; | |||
|
|||
const hourToMinutes = 60; | |||
|
|||
const timeZoneNameBlockList = [ |
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.
Is there a way to get this list from a trusted source rather than having to maintain it ourselves?
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.
Good idea. I could reliably exclude Etc/X
ones, but would have to investigate separately if entries with no delimiter are reliable to block as well.
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.
I focused too much on having this dynamically generated that I didn't address the "trusted source" part of your question. Unfortunately, Intl
doesn't provide metadata for time zone names, so we have to handle this on our side. That would definitely make things simpler here.
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.
👏 👍 💯
🤖 I have created a release *beep* *boop* --- <details><summary>@esri/calcite-components: 1.9.1</summary> ## [1.9.1](https://github.com/Esri/calcite-design-system/compare/@esri/calcite-components@1.9.0...@esri/calcite-components@1.9.1) (2023-10-05) ### Bug Fixes * **combobox:** Fix issue causing value to be cleared when selecting an item (Windows + trackpad) ([#7954](#7954)) ([557d658](557d658)) * **input-time-zone:** Fix handling of unknown and cityless time zones from offset display mode ([#7947](#7947)) ([75e0302](75e0302)) * **panel:** Fix collapse action title and reverse icon direction ([#7927](#7927)) ([5f620f8](5f620f8)) </details> <details><summary>@esri/calcite-components-react: 1.9.1</summary> ## [1.9.1](https://github.com/Esri/calcite-design-system/compare/@esri/calcite-components-react@1.9.0...@esri/calcite-components-react@1.9.1) (2023-10-05) ### Miscellaneous Chores * **@esri/calcite-components-react:** Synchronize undefined versions ### Dependencies * The following workspace dependencies were updated * dependencies * @esri/calcite-components bumped from ^1.9.1-next.1 to ^1.9.1 </details> --- This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please). --------- Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* origin/main: (83 commits) chore: add design tokens to monorepo (#7948) test(input-time-zone): restore common tests (#7963) chore: release next fix(input-time-zone): fix error caused by time zone group filtering (#7971) chore: release next fix(table): Improve scrollbar display (#7967) build: bump timezone-groups (#7962) chore: release next fix(flow-item): update collapsed property when collapse button is clicked (#7960) chore: release main (#7945) chore: release next fix(input-time-zone): fix handling of unknown and cityless time zones from offset display mode (#7947) fix(combobox): fix issue causing value to be cleared when selecting an item (Windows + trackpad) (#7954) chore(deps): update calcite-ui-icons to 3.24.7 (#7949) test(flow-item, panel): add tests for internal property. (#7931) chore: release next fix(panel): fix collapse action title and reverse icon direction (#7927) chore: update issue template labels to support workflows (#7938) build(deps): bump timezone-groups (#7933) build(deps): update dependency @esri/calcite-ui-icons to v3.24.6 (#7925) ...
Related Issue: #7944
Summary
This updates the component to remove cityless time zone entries in the
offset
mode and for unknown entries (either from browser differences or updated values) their city part will be displayed as is.Note: due to time constraints, testing will be tackled in #7951.