Unify date formatting in UN house style across all six locales#3
Closed
davidpomerenke wants to merge 2 commits into
Closed
Unify date formatting in UN house style across all six locales#3davidpomerenke wants to merge 2 commits into
davidpomerenke wants to merge 2 commits into
Conversation
formatMeetingDate now produces day-month-year per UN editorial style:
en→en-GB ("15 June 2025"), Arabic uses dual Levantine/Western month names
("حزيران/يونيه"), Russian strips Intl's trailing " г." suffix. Adds a
weekday option ("long" | "short" | "none") and a relative mode
("alone" | "prefix" | "off") so callers can render "Today, 15 June" on
schedule headings while dropping the weekday on meeting headers and
clipboard exports. Migrates statement-feed and subscriptions-manager off
their bespoke browser-locale formatters onto the shared hook.
Co-Authored-By: Claude Opus 4.7 <[email protected]>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
UN English style consistently writes "Monday, 9 March" with a comma
after the weekday, but Intl en-GB omits it without a year and includes
it with a year — inject the comma after the weekday for English so
both cases match. UN Chinese style writes "6月16日 星期一" with a space;
CLDR runs them together. Hand-assemble zh like ar so date and weekday
are separated. Also pipe the locale-appropriate comma into
formatMeetingDateTime so the time tail reads as one phrase
("Today, 10:30" / "今天,10:30") instead of "Today 10:30".
Co-Authored-By: Claude Opus 4.7 <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
formatMeetingDatenow produces day-month-year per UN editorial style:en→en-GB("15 June 2025"), Arabic uses dual Levantine/Western month names (حزيران/يونيه), Russian strips Intl's trailingг.suffix; month is always long-form.weekday: "long" | "short" | "none"andrelative: "alone" | "prefix" | "off"options so callers can render "Today, 15 June" on schedule headings, drop the weekday on meeting headers and clipboard exports, and disable relative entirely where it's not wanted.statement-feed.tsxandsubscriptions-manager.tsxoff bespoke browser-localeIntlcalls onto the shareduseMeetingFormathook.Test plan
pnpm typecheckclean/en,/es) — verified "Today, 15 June" / "Hoy, 15 de junio" prefix, full month, weekday only on absolute-only rows/en/sc/10171) — verified relative prefix with weekday dropped🤖 Generated with Claude Code