Start work on fluent categories.

Fix Locale loading when syncing invalid lang.
This commit is contained in:
Paul
2021-08-04 14:31:55 +01:00
parent c93f0245f1
commit 8cc92e0c42
4 changed files with 76 additions and 24 deletions

View File

@@ -1,6 +1,8 @@
import { IntlContext, translate } from "preact-i18n";
import { useContext } from "preact/hooks";
import { Dictionary } from "../context/Locale";
import { Children } from "../types/Preact";
interface Fields {
@@ -12,18 +14,6 @@ interface Props {
fields: Fields;
}
export interface Dictionary {
dayjs: {
defaults: {
twelvehour: "yes" | "no";
separator: string;
date: "traditional" | "simplified" | "ISO8601";
};
timeFormat: string;
};
[key: string]: Object | string;
}
export interface IntlType {
intl: {
dictionary: Dictionary;