Skip to content

[6.x] Hide redundant 'This field' timezone row in date pickers#14635

Merged
jasonvarga merged 1 commit into6.xfrom
hide-redundant-timezone
May 8, 2026
Merged

[6.x] Hide redundant 'This field' timezone row in date pickers#14635
jasonvarga merged 1 commit into6.xfrom
hide-redundant-timezone

Conversation

@jasonvarga
Copy link
Copy Markdown
Member

@jasonvarga jasonvarga commented May 8, 2026

Summary

In #14612 the date and date-range pickers gained a "This field" row in the timezone hover card. When the field's timezone matches "Site time" or your computer's local time, that extra row is just a duplicate and makes the hover card more confusing rather than more informative.

This change skips passing the additional row to TimezoneHoverCard when the field's timezone equals either the configured displayTimezone or getLocalTimeZone(). The small timezone label below the input still renders so the field's zone remains visible.

The dedup logic is extracted into resources/js/components/ui/DatePicker/util.js so both DatePicker.vue and DateRangePicker.vue share it.

Test plan

  • Open a date field whose timezone matches the site's display timezone — hover card shows only Site time / Your time
  • Open a date field whose timezone matches the browser's local timezone — hover card shows only Site time / Your time
  • Open a date field whose timezone differs from both — hover card shows the "This field" row
  • Repeat above with a date range field

@jasonvarga jasonvarga merged commit 5481e06 into 6.x May 8, 2026
22 checks passed
@jasonvarga jasonvarga deleted the hide-redundant-timezone branch May 8, 2026 19:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant