From 8e6441ff7d96b5b51b2f08e60dac77a1dd95b817 Mon Sep 17 00:00:00 2001 From: Alexander Kucera Date: Fri, 24 Oct 2025 16:42:04 +0200 Subject: [PATCH] Improves timestamp localization for note prompts Uses the user's preferred language locale for timestamp formatting, enhancing regional customization and user experience Allows automatic fallback to 'en-US' if navigator language is unavailable --- commands/notePrompts.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/commands/notePrompts.ts b/commands/notePrompts.ts index 2e72fe1..d703d42 100644 --- a/commands/notePrompts.ts +++ b/commands/notePrompts.ts @@ -146,7 +146,9 @@ export class NotePromptsCommand { * @returns Formatted markdown string ready for insertion */ private formatPrompts(prompts: string[]): string { - const timestamp = new Intl.DateTimeFormat('en-US', { + // Use user's locale for timestamp formatting to respect regional preferences + const locale = navigator?.language ?? 'en-US'; + const timestamp = new Intl.DateTimeFormat(locale, { year: 'numeric', month: 'short', day: 'numeric',