chore: fix type check for i18n (#30058)

Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
Co-authored-by: yyh <yuanyouhuilyz@gmail.com>
This commit is contained in:
Stephen Zhou
2025-12-24 16:31:16 +08:00
committed by GitHub
parent 0f41924db4
commit 1e3823e605
155 changed files with 560 additions and 1015 deletions

View File

@ -121,7 +121,7 @@ const DatasetItem: FC<Props> = ({
payload.provider === 'external' && (
<Badge
className="shrink-0 group-hover/dataset-item:hidden"
text={t('dataset.externalTag') as string}
text={t('dataset.externalTag')}
/>
)
}

View File

@ -42,7 +42,7 @@ const ConditionOperator = ({
const options = useMemo(() => {
return getOperators(variableType).map((o) => {
return {
label: isComparisonOperatorNeedTranslate(o) ? t(`${i18nPrefix}.comparisonOperator.${o}`) : o,
label: isComparisonOperatorNeedTranslate(o) ? t(`${i18nPrefix}.comparisonOperator.${o}` as any) as string : o,
value: o,
}
})
@ -68,7 +68,7 @@ const ConditionOperator = ({
{
selectedOption
? selectedOption.label
: t(`${i18nPrefix}.select`)
: t(`${i18nPrefix}.select` as any) as string
}
<RiArrowDownSLine className="ml-1 h-3.5 w-3.5" />
</Button>