kotori 6.1.0 → 6.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.cts +2 -2
- package/dist/index.d.mts +2 -2
- package/package.json +1 -1
package/dist/index.d.cts
CHANGED
|
@@ -235,13 +235,13 @@ declare const detectLanguage: <const T extends {
|
|
|
235
235
|
secondaries: BCP47LanguageTagNameWithSubTag[];
|
|
236
236
|
};
|
|
237
237
|
}>(instance: T["config"]["primary"] | T["config"]["secondaries"][number] extends infer A ? {
|
|
238
|
-
setLanguage: Parameters<T["setLanguage"]>[0] extends infer L ? L[] extends
|
|
238
|
+
setLanguage: Parameters<T["setLanguage"]>[0] extends infer L ? L[] extends BCP47LanguageTagNameWithSubTag[] ? A[] extends L[] ? (language: L) => void : "language param does not match primary or secondaries language types" : "language param does not match BCP47LanguageTagNameWithSubTag types" : never;
|
|
239
239
|
config: {
|
|
240
240
|
primary: T["config"]["primary"];
|
|
241
241
|
secondaries: Exclude<BCP47LanguageTagNameWithSubTag, T["config"]["primary"]>[];
|
|
242
242
|
};
|
|
243
243
|
} : T, options?: {
|
|
244
244
|
fallbackToSubtag?: boolean;
|
|
245
|
-
}) =>
|
|
245
|
+
}) => any;
|
|
246
246
|
//#endregion
|
|
247
247
|
export { BCP47LanguageTagNameWithSubTag, SubTags, Tags, detectLanguage, kotori };
|
package/dist/index.d.mts
CHANGED
|
@@ -235,13 +235,13 @@ declare const detectLanguage: <const T extends {
|
|
|
235
235
|
secondaries: BCP47LanguageTagNameWithSubTag[];
|
|
236
236
|
};
|
|
237
237
|
}>(instance: T["config"]["primary"] | T["config"]["secondaries"][number] extends infer A ? {
|
|
238
|
-
setLanguage: Parameters<T["setLanguage"]>[0] extends infer L ? L[] extends
|
|
238
|
+
setLanguage: Parameters<T["setLanguage"]>[0] extends infer L ? L[] extends BCP47LanguageTagNameWithSubTag[] ? A[] extends L[] ? (language: L) => void : "language param does not match primary or secondaries language types" : "language param does not match BCP47LanguageTagNameWithSubTag types" : never;
|
|
239
239
|
config: {
|
|
240
240
|
primary: T["config"]["primary"];
|
|
241
241
|
secondaries: Exclude<BCP47LanguageTagNameWithSubTag, T["config"]["primary"]>[];
|
|
242
242
|
};
|
|
243
243
|
} : T, options?: {
|
|
244
244
|
fallbackToSubtag?: boolean;
|
|
245
|
-
}) =>
|
|
245
|
+
}) => any;
|
|
246
246
|
//#endregion
|
|
247
247
|
export { BCP47LanguageTagNameWithSubTag, SubTags, Tags, detectLanguage, kotori };
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "kotori",
|
|
3
3
|
"description": "0.28kB Strongly-typed and tree-shakeable internationalization library for React",
|
|
4
|
-
"version": "6.1.
|
|
4
|
+
"version": "6.1.1",
|
|
5
5
|
"scripts": {
|
|
6
6
|
"setup": "rm -rf node_modules && npm i && git init && husky",
|
|
7
7
|
"prepublishOnly": "npm i && npx tsc && npm run build",
|