Skip to content

Commit

Permalink
fix(TDS-7339/Date): Language switch does not update Date Field error …
Browse files Browse the repository at this point in the history
…messages (#5296)
  • Loading branch information
yyanwang committed Apr 30, 2024
1 parent eb201ac commit b502805
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
5 changes: 5 additions & 0 deletions .changeset/slimy-tigers-bow.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@talend/react-components": patch
---

Fix translation for date range
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
import getDefaultT from '../../translate';

const t = getDefaultT();

export default function getErrorMessage(key) {
const t = getDefaultT();
switch (key) {
case 'INVALID_HOUR_EMPTY':
return t('INVALID_HOUR_EMPTY', { defaultValue: 'Hour is required' });
Expand Down

0 comments on commit b502805

Please sign in to comment.