Files
mtdb_movie/common/resources/client/i18n/mixed-text.tsx
T
maher 511fad8199
Build / run (push) Has been cancelled
Initial commit
2026-05-14 13:42:10 +02:00

17 lines
379 B
TypeScript
Executable File

import {MessageDescriptor} from './message-descriptor';
import {Trans} from './trans';
import {Fragment} from 'react';
interface Props {
value?: string | MessageDescriptor | null;
}
export function MixedText({value}: Props) {
if (!value) {
return null;
}
if (typeof value === 'string') {
return <Fragment>{value}</Fragment>;
}
return <Trans {...value} />;
}