patternfly / patternfly/patternfly-react
DatePicker: specify time zone for today's date (current)
Nadie ha tomado este issue todavía.
- Lenguaje dominante
- TypeScript
- Estrellas
- 862
- Forks
- 392
- Merge medio
- 4 d 8 h
- PR fusionados (30 d)
- 9
Descripción
Describe the enhancement or change
We propose adding a property to the DatePicker (and CalendarMonth) components to specify the time zone to be applied when determining today's date.
Details
In our application, users can specify the time zone they are working in.
For instance, a user located in the PST time zone may collaborate with users in the UK and choose to use the UTC time zone within the application.
If the user sets the time zone to UTC (01:02, 21 November), the application may still highlight the 20th because it reflects the local date based on the user's computer settings rather than the selected UTC time zone (17:02, 20 November).
When the user changes their computer’s clock to UTC, then the today's date is updated to the 21st as expected.
Is this request originating from a Red Hat product team? If so, which ones and is there any sort of deadline for this enhancement?
No
Any other information?
Link to hardcoded today's date: https://github.com/patternfly/patternfly-react/blob/main/packages/react-core/src/components/CalendarMonth/CalendarMonth.tsx#L122
Guía de contribución
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Línea de trabajo
Comienza en packages/react-core/src/components/CalendarMonth/CalendarMonth.tsx, alrededor de la fecha de hoy codificada directamente, y luego sigue cómo DatePicker y CalendarMonth determinan el día actual. Define el comportamiento de la propiedad de zona horaria a partir del ejemplo UTC del issue y verifica que el resaltado de la fecha de hoy siga la zona horaria seleccionada en lugar de la configuración local del ordenador.
Escrito por el modelo de indexación a partir del texto del issue.
Evaluación
- Stack tecnológico
- react, typescript
- Área
- frontend
- Tipo de issue
- Nueva funcionalidad
- Dificultad
- 4/5
- Tiempo estimado
- 3-5 días
- Estado de actividad
- Estancado
- Claridad
- Bastante claro
- Aptitud para principiantes
- 42/100