@korioinc/next-core 1.0.9 → 1.2.0

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.
@@ -1,7 +1,7 @@
1
1
  interface LocaleSwitcherProps {
2
2
  /**
3
3
  * Array of language codes to display in the switcher.
4
- * Example: ['en', 'ko', 'jp']
4
+ * Example: ['en', 'ko', 'ja']
5
5
  * If not provided, defaults to all supported languages.
6
6
  */
7
7
  languages?: string[];
@@ -23,7 +23,7 @@ const allLanguages = [
23
23
  flag: _jsx(KoreaFlag, {}),
24
24
  },
25
25
  {
26
- code: 'jp',
26
+ code: 'ja',
27
27
  name: '日本語',
28
28
  flag: _jsx(JapanFlag, {}),
29
29
  },
@@ -1 +1 @@
1
- {"version":3,"file":"routing.d.ts","sourceRoot":"","sources":["../../src/i18n/routing.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,iBAAiB,CAAC;AAC/D,OAAO,EAAE,KAAK,WAAW,EAAE,YAAY,EAAE,MAAM,aAAa,CAAC;AAgB7D;;GAEG;AACH,wBAAgB,UAAU,IAAI,MAAM,EAAE,CAErC;AAED;;GAEG;AACH,wBAAgB,gBAAgB,IAAI,MAAM,CAEzC;AA2DD,wBAAgB,mBAAmB,CAAC,OAAO,EAAE,WAAW,yBA2EvD;AAED,wBAAgB,gBAAgB,CAAC,cAAc,EAAE,OAAO,GAAG,MAAM,CAShE;AAED,wBAAgB,eAAe,CAAC,cAAc,EAAE,OAAO,EAAE,QAAQ,CAAC,EAAE,MAAM,GAAG,MAAM,GAAG,SAAS,CAkB9F;AAED,wBAAgB,mBAAmB,CAAC,QAAQ,EAAE,MAAM,EAAE,aAAa,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,GAAG,MAAM,CAoBvG;AAED,wBAAgB,WAAW,CAAC,EAAE,MAAM,EAAE,IAAI,EAAE,EAAE;IAAE,MAAM,EAAE,MAAM,CAAC;IAAC,IAAI,EAAE,M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C,CAK1D;AAED;;GAEG;AACH,wBAAgB,UAAU,CACxB,QAAQ,EAAE,MAAM,EAChB,MAAM,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM,EAAE,GAAG,SAAS,CAAC,GAAG,uBAAuB,GAAG,SAAS,GAC3F,MAAM,CAkCR"}
@@ -4,7 +4,18 @@ import { match } from '@formatjs/intl-localematcher';
4
4
  import linguiConfig from 'lingui.config';
5
5
  import Negotiator from 'negotiator';
6
6
  const { locales, fallbackLocales } = linguiConfig;
7
- const DEFAULT_FALLBACK = () => fallbackLocales && typeof fallbackLocales === 'object' ? fallbackLocales.default || 'en' : 'en';
7
+ const DEFAULT_FALLBACK = () => {
8
+ if (fallbackLocales && typeof fallbackLocales === 'object') {
9
+ const fallback = fallbackLocales.default;
10
+ if (Array.isArray(fallback)) {
11
+ return fallback[0] || 'en';
12
+ }
13
+ if (typeof fallback === 'string') {
14
+ return fallback;
15
+ }
16
+ }
17
+ return 'en';
18
+ };
8
19
  const LOCALE_COOKIE_NAME = 'NEXT_LOCALE';
9
20
  const LOCALE_PREFIX = 'as-needed';
10
21
  /**
@@ -0,0 +1,7 @@
1
+ declare module '*.po' {
2
+ import type { Messages } from '@lingui/core';
3
+
4
+ export const messages: Messages | undefined;
5
+ const defaultExport: Messages | undefined;
6
+ export default defaultExport;
7
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@korioinc/next-core",
3
- "version": "1.0.9",
3
+ "version": "1.2.0",
4
4
  "type": "module",
5
5
  "exports": {
6
6
  "./ads": {
@@ -62,39 +62,39 @@
62
62
  "LICENSE"
63
63
  ],
64
64
  "devDependencies": {
65
- "@headlessui/react": "^2.2.8",
66
- "@lingui/conf": "5.5.0",
67
- "@lingui/core": "5.5.0",
68
- "@lingui/react": "5.5.0",
69
- "@tailwindcss/typography": "^0.5.16",
65
+ "@headlessui/react": "^2.2.9",
66
+ "@lingui/conf": "^5.6.1",
67
+ "@lingui/core": "^5.6.1",
68
+ "@lingui/react": "^5.6.1",
69
+ "@tailwindcss/typography": "^0.5.19",
70
70
  "@types/negotiator": "^0.6.4",
71
- "@types/node": "^22.18.3",
72
- "@types/react": "^19.1.12",
73
- "@types/react-dom": "^19.1.9",
74
- "eslint": "^9.35.0",
71
+ "@types/node": "^24.10.0",
72
+ "@types/react": "^19.2.3",
73
+ "@types/react-dom": "^19.2.3",
74
+ "eslint": "^9.39.1",
75
75
  "next-themes": "^0.4.6",
76
- "react": "19.1.1",
77
- "react-dom": "19.1.1",
78
- "tailwindcss": "^4.1.13",
76
+ "react": "^19.2.3",
77
+ "react-dom": "^19.2.3",
78
+ "tailwindcss": "^4.1.17",
79
79
  "tsc-alias": "^1.8.16",
80
- "tw-animate-css": "^1.3.8",
81
- "typescript": "^5.9.2",
80
+ "tw-animate-css": "^1.4.0",
81
+ "typescript": "^5.9.3",
82
82
  "@korioinc/next-configs": "1.0.0"
83
83
  },
84
84
  "dependencies": {
85
85
  "@floating-ui/react": "^0.27.16",
86
- "@formatjs/intl-localematcher": "^0.6.1",
86
+ "@formatjs/intl-localematcher": "^0.6.2",
87
87
  "clsx": "^2.1.1",
88
- "cookies-next": "^6.1.0",
88
+ "cookies-next": "^6.1.1",
89
89
  "cosmiconfig": "^9.0.0",
90
- "jose": "^6.1.0",
90
+ "jose": "^6.1.1",
91
91
  "localforage": "^1.10.0",
92
92
  "negotiator": "^1.0.0",
93
93
  "pretendard": "^1.3.9",
94
94
  "schema-dts": "^1.1.5",
95
- "tailwind-merge": "^3.3.1",
96
- "valtio": "^2.1.7",
97
- "@korioinc/next-conf": "1.0.6"
95
+ "tailwind-merge": "^3.4.0",
96
+ "valtio": "^2.2.0",
97
+ "@korioinc/next-conf": "1.2.0"
98
98
  },
99
99
  "publishConfig": {
100
100
  "access": "public",
@@ -108,12 +108,12 @@
108
108
  "author": "Korio Inc.",
109
109
  "peerDependencies": {
110
110
  "@headlessui/react": ">=2.2.0",
111
- "@lingui/core": ">=5.0.0",
112
- "@lingui/react": ">=5.0.0",
113
- "next": ">=15",
111
+ "@lingui/core": ">=5.6.1",
112
+ "@lingui/react": ">=5.6.1",
113
+ "next": ">=16.0.10",
114
114
  "next-themes": ">=0.4.5",
115
- "react": ">=19",
116
- "react-dom": ">=19",
115
+ "react": ">=19.2.3",
116
+ "react-dom": ">=19.2.3",
117
117
  "tailwindcss": ">=4.0.0"
118
118
  },
119
119
  "scripts": {