File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -5,6 +5,7 @@ import getRevisionDiffURL from '../../wiki/util/getRevisionDiffURL';
55import nsId from '../../wiki/util/nsId' ;
66import type { ExpandedRevisionData } from '../../api/ExpandedRevisionData' ;
77import { ContributionSurveyRevision } from '../../models/ContributionSurveyRevision' ;
8+ import { USER_LOCALE } from '../../wiki/Locale' ;
89
910/**
1011 * @param root0
@@ -94,7 +95,7 @@ export function ChangesListTime(
9495 { timestamp } : { timestamp : string }
9596) : JSX . Element {
9697 const time = new Date ( timestamp ) ;
97- const formattedTime = time . toLocaleTimeString ( window . deputyLang , {
98+ const formattedTime = time . toLocaleTimeString ( USER_LOCALE , {
9899 hourCycle : 'h24' ,
99100 timeStyle : mw . user . options . get ( 'date' ) === 'ISO 8601' ? 'long' : 'short'
100101 } ) ;
@@ -118,12 +119,12 @@ export function ChangesListDate(
118119 if ( window . deputy . config . cci . forceUtc . get ( ) ) {
119120 now = now . utc ( ) ;
120121 }
121- const formattedTime = time . toLocaleTimeString ( window . deputyLang , {
122+ const formattedTime = time . toLocaleTimeString ( USER_LOCALE , {
122123 hourCycle : 'h24' ,
123124 timeStyle : mw . user . options . get ( 'date' ) === 'ISO 8601' ? 'long' : 'short' ,
124125 timeZone : window . deputy ?. config . cci . forceUtc . get ( ) ? 'UTC' : undefined
125126 } ) ;
126- const formattedDate = now . locale ( window . deputyLang ) . format ( {
127+ const formattedDate = now . locale ( USER_LOCALE ) . format ( {
127128 dmy : 'D MMMM YYYY' ,
128129 mdy : 'MMMM D, Y' ,
129130 ymd : 'YYYY MMMM D' ,
You can’t perform that action at this time.
0 commit comments