@intlayer/design-system 5.5.9 → 5.5.10
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/README.md +42 -9
- package/dist/.vite/manifest.json +43 -27
- package/dist/components/Auth/ChangePasswordForm/useChangePasswordSchema.cjs +1 -1
- package/dist/components/Auth/ChangePasswordForm/useChangePasswordSchema.mjs +1 -1
- package/dist/components/Auth/DefineNewPasswordForm/useDefineNewPasswordSchema.cjs +1 -1
- package/dist/components/Auth/DefineNewPasswordForm/useDefineNewPasswordSchema.mjs +1 -1
- package/dist/components/Auth/ResetPasswordForm/useResetPasswordSchema.cjs +1 -1
- package/dist/components/Auth/ResetPasswordForm/useResetPasswordSchema.mjs +1 -1
- package/dist/components/Auth/SignInForm/useSignInSchema.cjs +1 -1
- package/dist/components/Auth/SignInForm/useSignInSchema.mjs +1 -1
- package/dist/components/Auth/SignUpForm/useSignUpSchema.cjs +1 -1
- package/dist/components/Auth/SignUpForm/useSignUpSchema.mjs +1 -1
- package/dist/components/Auth/VerifyEmailForm/VerifyEmailSchema.cjs +1 -1
- package/dist/components/Auth/VerifyEmailForm/VerifyEmailSchema.mjs +1 -1
- package/dist/components/Auth/useAuth/useCSRF.d.ts +1 -1
- package/dist/components/Auth/useAuth/useOAuth2.d.ts +1 -1
- package/dist/components/Command/index.d.ts +83 -0
- package/dist/components/Command/index.d.ts.map +1 -0
- package/dist/components/DictionaryFieldEditor/DictionaryCreationForm/useDictionaryFormSchema.cjs +1 -1
- package/dist/components/DictionaryFieldEditor/DictionaryCreationForm/useDictionaryFormSchema.mjs +1 -1
- package/dist/components/DictionaryFieldEditor/DictionaryDetails/useDictionaryDetailsSchema.cjs +1 -1
- package/dist/components/DictionaryFieldEditor/DictionaryDetails/useDictionaryDetailsSchema.mjs +1 -1
- package/dist/components/DictionaryFieldEditor/StructureView/StructureView.cjs +1 -1
- package/dist/components/DictionaryFieldEditor/StructureView/StructureView.cjs.map +1 -1
- package/dist/components/DictionaryFieldEditor/StructureView/StructureView.d.ts +1 -1
- package/dist/components/DictionaryFieldEditor/StructureView/StructureView.d.ts.map +1 -1
- package/dist/components/DictionaryFieldEditor/StructureView/StructureView.mjs +1 -1
- package/dist/components/DictionaryFieldEditor/StructureView/StructureView.mjs.map +1 -1
- package/dist/components/DropDown/index.cjs +1 -13
- package/dist/components/DropDown/index.cjs.map +1 -1
- package/dist/components/DropDown/index.d.ts.map +1 -1
- package/dist/components/DropDown/index.mjs +1 -13
- package/dist/components/DropDown/index.mjs.map +1 -1
- package/dist/components/Form/FormBase.cjs +2 -2
- package/dist/components/Form/FormBase.mjs +2 -2
- package/dist/components/Form/elements/FormElementWrapper.cjs +3 -3
- package/dist/components/Form/elements/FormElementWrapper.mjs +3 -3
- package/dist/components/IDE/FileList.cjs +1 -1
- package/dist/components/IDE/FileList.cjs.map +1 -1
- package/dist/components/IDE/FileList.d.ts +1 -1
- package/dist/components/IDE/FileList.d.ts.map +1 -1
- package/dist/components/IDE/FileList.mjs +1 -1
- package/dist/components/IDE/FileList.mjs.map +1 -1
- package/dist/components/KeyboardScreenAdapter/index.cjs +1 -1
- package/dist/components/KeyboardScreenAdapter/index.cjs.map +1 -1
- package/dist/components/KeyboardScreenAdapter/index.mjs +1 -1
- package/dist/components/KeyboardScreenAdapter/index.mjs.map +1 -1
- package/dist/components/MarkDownRender/index.cjs +1 -1
- package/dist/components/MarkDownRender/index.cjs.map +1 -1
- package/dist/components/MarkDownRender/index.mjs +1 -1
- package/dist/components/MarkDownRender/index.mjs.map +1 -1
- package/dist/components/TextArea/AutoSizeTextArea.cjs +1 -1
- package/dist/components/TextArea/AutoSizeTextArea.cjs.map +1 -1
- package/dist/components/TextArea/AutoSizeTextArea.mjs +1 -1
- package/dist/components/TextArea/AutoSizeTextArea.mjs.map +1 -1
- package/dist/hooks/intlayerAPIHooks.d.ts +54 -54
- package/dist/hooks/intlayerAPIHooks.d.ts.map +1 -1
- package/dist/hooks/useIntlayerAPI.d.ts +65 -65
- package/dist/hooks/useIntlayerAPI.d.ts.map +1 -1
- package/dist/index-BCuMWKyy.js.map +1 -1
- package/dist/index-BYzBot7l.cjs.map +1 -1
- package/dist/parse-BJVwmz92.cjs +511 -0
- package/dist/parse-BJVwmz92.cjs.map +1 -0
- package/dist/parse-pnJgclyf.js +512 -0
- package/dist/parse-pnJgclyf.js.map +1 -0
- package/dist/{schemas-DJhUvjsx.cjs → schemas-DlCjM5d_.cjs} +260 -726
- package/dist/schemas-DlCjM5d_.cjs.map +1 -0
- package/dist/{schemas-7jC6hy_u.js → schemas-itjzX6bG.js} +21 -487
- package/dist/schemas-itjzX6bG.js.map +1 -0
- package/dist/tailwind.css +2 -2
- package/dist/zod-D4WapgbL.js +92 -0
- package/dist/zod-D4WapgbL.js.map +1 -0
- package/dist/zod-K7y5gPX4.cjs +91 -0
- package/dist/zod-K7y5gPX4.cjs.map +1 -0
- package/package.json +15 -15
- package/dist/schemas-7jC6hy_u.js.map +0 -1
- package/dist/schemas-DJhUvjsx.cjs.map +0 -1
- package/dist/zod-DIGMabE8.js +0 -48
- package/dist/zod-DIGMabE8.js.map +0 -1
- package/dist/zod-DpajDxlG.cjs +0 -47
- package/dist/zod-DpajDxlG.cjs.map +0 -1
package/README.md
CHANGED
|
@@ -5,15 +5,48 @@
|
|
|
5
5
|
</div>
|
|
6
6
|
|
|
7
7
|
<div align="center">
|
|
8
|
-
<a href="https://www.npmjs.com/package/intlayer"
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
8
|
+
<a href="https://www.npmjs.com/package/intlayer" target="blank"><img
|
|
9
|
+
align="center"
|
|
10
|
+
alt="npm"
|
|
11
|
+
src="https://img.shields.io/npm/v/intlayer.svg?labelColor=49516F&color=8994BC&style=for-the-badge"
|
|
12
|
+
height="30" /></a>
|
|
13
|
+
<a href="https://npmjs.org/package/intlayer" target="blank"><img
|
|
14
|
+
align="center"
|
|
15
|
+
src="https://img.shields.io/npm/dm/intlayer?labelColor=49516F&color=8994BC&style=for-the-badge"
|
|
16
|
+
alt="monthly downloads"
|
|
17
|
+
height="30"
|
|
18
|
+
/></a>
|
|
19
|
+
<a href="https://npmjs.org/package/intlayer" target="blank"><img
|
|
20
|
+
align="center"
|
|
21
|
+
src="https://img.shields.io/npm/types/intlayer?label=types%20included&labelColor=49516F&color=8994BC&style=for-the-badge"
|
|
22
|
+
alt="types included"
|
|
23
|
+
height="30"
|
|
24
|
+
/></a>
|
|
25
|
+
</div>
|
|
26
|
+
|
|
27
|
+
<div>
|
|
28
|
+
<br/>
|
|
29
|
+
<p align="center">
|
|
30
|
+
<a href="https://www.linkedin.com/company/intlayerorg" target="blank"><img align="center"
|
|
31
|
+
src="https://img.shields.io/badge/linkedin-%231DA1F2.svg?style=for-the-badge&logo=linkedin&logoColor=white"
|
|
32
|
+
alt="Intlayer LinkedIn" height="30"/></a>
|
|
33
|
+
<a href="https://www.facebook.com/intlayer" target="blank"><img align="center"
|
|
34
|
+
src="https://img.shields.io/badge/facebook-4267B2.svg?style=for-the-badge&logo=facebook&logoColor=white"
|
|
35
|
+
alt="Intlayer Facebook" height="30"/></a>
|
|
36
|
+
<a href="https://www.instagram.com/intlayer_org/" target="blank"><img align="center"
|
|
37
|
+
src="https://img.shields.io/badge/instagram-%23E4405F.svg?style=for-the-badge&logo=Instagram&logoColor=white"
|
|
38
|
+
alt="Intlayer Instagram" height="30"/></a>
|
|
39
|
+
<a href="https://x.com/Intlayer183096" target="blank"><img align="center"
|
|
40
|
+
src="https://img.shields.io/badge/x-1DA1F2.svg?style=for-the-badge&logo=x&logoColor=white"
|
|
41
|
+
alt="Intlayer X" height="30"/></a>
|
|
42
|
+
<a href="https://www.youtube.com/@intlayer" target="blank"><img align="center"
|
|
43
|
+
src="https://img.shields.io/badge/youtube-FF0000.svg?style=for-the-badge&logo=youtube&logoColor=white"
|
|
44
|
+
alt="Intlayer YouTube" height="30"/></a>
|
|
45
|
+
<a href="https://www.tiktok.com/@intlayer" target="blank"><img align="center"
|
|
46
|
+
src="https://img.shields.io/badge/tiktok-000000.svg?style=for-the-badge&logo=tiktok&logoColor=white"
|
|
47
|
+
alt="Intlayer TikTok" height="30"/></a>
|
|
48
|
+
<br>
|
|
49
|
+
</p>
|
|
17
50
|
</div>
|
|
18
51
|
|
|
19
52
|
# @intlayer/design-system: Containing the UI library of Intlayer
|
package/dist/.vite/manifest.json
CHANGED
|
@@ -81,21 +81,41 @@
|
|
|
81
81
|
"src/components/DictionaryEditor/NodeWrapper/StringWrapper.tsx"
|
|
82
82
|
]
|
|
83
83
|
},
|
|
84
|
-
"
|
|
85
|
-
"file": "
|
|
86
|
-
"name": "
|
|
84
|
+
"_parse-BJVwmz92.cjs": {
|
|
85
|
+
"file": "parse-BJVwmz92.cjs",
|
|
86
|
+
"name": "parse"
|
|
87
87
|
},
|
|
88
|
-
"
|
|
89
|
-
"file": "
|
|
90
|
-
"name": "
|
|
88
|
+
"_parse-pnJgclyf.js": {
|
|
89
|
+
"file": "parse-pnJgclyf.js",
|
|
90
|
+
"name": "parse"
|
|
91
91
|
},
|
|
92
|
-
"
|
|
93
|
-
"file": "
|
|
94
|
-
"name": "
|
|
92
|
+
"_schemas-DlCjM5d_.cjs": {
|
|
93
|
+
"file": "schemas-DlCjM5d_.cjs",
|
|
94
|
+
"name": "schemas",
|
|
95
|
+
"imports": [
|
|
96
|
+
"_parse-BJVwmz92.cjs"
|
|
97
|
+
]
|
|
98
|
+
},
|
|
99
|
+
"_schemas-itjzX6bG.js": {
|
|
100
|
+
"file": "schemas-itjzX6bG.js",
|
|
101
|
+
"name": "schemas",
|
|
102
|
+
"imports": [
|
|
103
|
+
"_parse-pnJgclyf.js"
|
|
104
|
+
]
|
|
105
|
+
},
|
|
106
|
+
"_zod-D4WapgbL.js": {
|
|
107
|
+
"file": "zod-D4WapgbL.js",
|
|
108
|
+
"name": "zod",
|
|
109
|
+
"imports": [
|
|
110
|
+
"_parse-pnJgclyf.js"
|
|
111
|
+
]
|
|
95
112
|
},
|
|
96
|
-
"_zod-
|
|
97
|
-
"file": "zod-
|
|
98
|
-
"name": "zod"
|
|
113
|
+
"_zod-K7y5gPX4.cjs": {
|
|
114
|
+
"file": "zod-K7y5gPX4.cjs",
|
|
115
|
+
"name": "zod",
|
|
116
|
+
"imports": [
|
|
117
|
+
"_parse-BJVwmz92.cjs"
|
|
118
|
+
]
|
|
99
119
|
},
|
|
100
120
|
"src/components/Accordion/Accordion.tsx": {
|
|
101
121
|
"file": "components/Accordion/Accordion.cjs",
|
|
@@ -216,7 +236,7 @@
|
|
|
216
236
|
"isEntry": true,
|
|
217
237
|
"imports": [
|
|
218
238
|
"src/components/Auth/ChangePasswordForm/useChangePasswordSchema.content.ts",
|
|
219
|
-
"_schemas-
|
|
239
|
+
"_schemas-DlCjM5d_.cjs"
|
|
220
240
|
]
|
|
221
241
|
},
|
|
222
242
|
"src/components/Auth/DefineNewPasswordForm/DefineNewPasswordForm.tsx": {
|
|
@@ -262,7 +282,7 @@
|
|
|
262
282
|
"isEntry": true,
|
|
263
283
|
"imports": [
|
|
264
284
|
"src/components/Auth/DefineNewPasswordForm/useDefineNewPasswordSchema.content.ts",
|
|
265
|
-
"_schemas-
|
|
285
|
+
"_schemas-DlCjM5d_.cjs"
|
|
266
286
|
]
|
|
267
287
|
},
|
|
268
288
|
"src/components/Auth/ExternalsLoginButtons/ExternalsLoginButtons.tsx": {
|
|
@@ -347,7 +367,7 @@
|
|
|
347
367
|
"isEntry": true,
|
|
348
368
|
"imports": [
|
|
349
369
|
"src/components/Auth/ResetPasswordForm/useResetPasswordSchema.content.ts",
|
|
350
|
-
"_schemas-
|
|
370
|
+
"_schemas-DlCjM5d_.cjs"
|
|
351
371
|
]
|
|
352
372
|
},
|
|
353
373
|
"src/components/Auth/SignInForm/SignInForm.tsx": {
|
|
@@ -393,7 +413,7 @@
|
|
|
393
413
|
"isEntry": true,
|
|
394
414
|
"imports": [
|
|
395
415
|
"src/components/Auth/SignInForm/useSignInSchema.content.ts",
|
|
396
|
-
"_schemas-
|
|
416
|
+
"_schemas-DlCjM5d_.cjs"
|
|
397
417
|
]
|
|
398
418
|
},
|
|
399
419
|
"src/components/Auth/SignUpForm/SignUpForm.tsx": {
|
|
@@ -438,7 +458,7 @@
|
|
|
438
458
|
"isEntry": true,
|
|
439
459
|
"imports": [
|
|
440
460
|
"src/components/Auth/SignUpForm/useSignUpSchema.content.ts",
|
|
441
|
-
"_schemas-
|
|
461
|
+
"_schemas-DlCjM5d_.cjs"
|
|
442
462
|
]
|
|
443
463
|
},
|
|
444
464
|
"src/components/Auth/VerifyEmailForm/VerifyEmailForm.tsx": {
|
|
@@ -464,7 +484,7 @@
|
|
|
464
484
|
"src": "src/components/Auth/VerifyEmailForm/VerifyEmailSchema.ts",
|
|
465
485
|
"isEntry": true,
|
|
466
486
|
"imports": [
|
|
467
|
-
"_schemas-
|
|
487
|
+
"_schemas-DlCjM5d_.cjs"
|
|
468
488
|
]
|
|
469
489
|
},
|
|
470
490
|
"src/components/Auth/VerifyEmailForm/index.content.ts": {
|
|
@@ -945,7 +965,7 @@
|
|
|
945
965
|
"isEntry": true,
|
|
946
966
|
"imports": [
|
|
947
967
|
"src/components/DictionaryFieldEditor/DictionaryCreationForm/useDictionaryFormSchema.content.ts",
|
|
948
|
-
"_schemas-
|
|
968
|
+
"_schemas-DlCjM5d_.cjs"
|
|
949
969
|
]
|
|
950
970
|
},
|
|
951
971
|
"src/components/DictionaryFieldEditor/DictionaryDetails/DictionaryDetailsForm.tsx": {
|
|
@@ -1002,7 +1022,7 @@
|
|
|
1002
1022
|
"isEntry": true,
|
|
1003
1023
|
"imports": [
|
|
1004
1024
|
"src/components/DictionaryFieldEditor/DictionaryDetails/useDictionaryDetailsSchema.content.ts",
|
|
1005
|
-
"_schemas-
|
|
1025
|
+
"_schemas-DlCjM5d_.cjs"
|
|
1006
1026
|
]
|
|
1007
1027
|
},
|
|
1008
1028
|
"src/components/DictionaryFieldEditor/DictionaryFieldEditor.tsx": {
|
|
@@ -1238,10 +1258,6 @@
|
|
|
1238
1258
|
"src": "src/components/DropDown/index.tsx",
|
|
1239
1259
|
"isEntry": true,
|
|
1240
1260
|
"imports": [
|
|
1241
|
-
"src/hooks/useDevice.ts",
|
|
1242
|
-
"src/hooks/useScrollBlockage/useScrollBlockageStore.ts",
|
|
1243
|
-
"src/hooks/useAsync/useAsyncStateStore.tsx",
|
|
1244
|
-
"src/components/Toaster/Toast.tsx",
|
|
1245
1261
|
"src/utils/cn.ts",
|
|
1246
1262
|
"src/components/MaxHeightSmoother/index.tsx"
|
|
1247
1263
|
]
|
|
@@ -1340,7 +1356,7 @@
|
|
|
1340
1356
|
"src": "src/components/Form/FormBase.tsx",
|
|
1341
1357
|
"isEntry": true,
|
|
1342
1358
|
"imports": [
|
|
1343
|
-
"_zod-
|
|
1359
|
+
"_zod-K7y5gPX4.cjs",
|
|
1344
1360
|
"src/utils/cn.ts"
|
|
1345
1361
|
]
|
|
1346
1362
|
},
|
|
@@ -1454,8 +1470,8 @@
|
|
|
1454
1470
|
"src": "src/components/Form/elements/FormElementWrapper.tsx",
|
|
1455
1471
|
"isEntry": true,
|
|
1456
1472
|
"imports": [
|
|
1457
|
-
"_zod-
|
|
1458
|
-
"_schemas-
|
|
1473
|
+
"_zod-K7y5gPX4.cjs",
|
|
1474
|
+
"_schemas-DlCjM5d_.cjs"
|
|
1459
1475
|
]
|
|
1460
1476
|
},
|
|
1461
1477
|
"src/components/Form/elements/InputElement.tsx": {
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
3
3
|
const reactIntlayer = require("react-intlayer");
|
|
4
4
|
const components_Auth_ChangePasswordForm_useChangePasswordSchema_content = require("./useChangePasswordSchema.content.cjs");
|
|
5
|
-
const schemas = require("../../../schemas-
|
|
5
|
+
const schemas = require("../../../schemas-DlCjM5d_.cjs");
|
|
6
6
|
const useChangePasswordSchema = () => {
|
|
7
7
|
const {
|
|
8
8
|
requiredErrorPassword,
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { useDictionary } from "react-intlayer";
|
|
2
2
|
import { changePasswordSchemaContent } from "./useChangePasswordSchema.content.mjs";
|
|
3
|
-
import { o as object, s as string } from "../../../schemas-
|
|
3
|
+
import { o as object, s as string } from "../../../schemas-itjzX6bG.js";
|
|
4
4
|
const useChangePasswordSchema = () => {
|
|
5
5
|
const {
|
|
6
6
|
requiredErrorPassword,
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
3
3
|
const reactIntlayer = require("react-intlayer");
|
|
4
4
|
const components_Auth_DefineNewPasswordForm_useDefineNewPasswordSchema_content = require("./useDefineNewPasswordSchema.content.cjs");
|
|
5
|
-
const schemas = require("../../../schemas-
|
|
5
|
+
const schemas = require("../../../schemas-DlCjM5d_.cjs");
|
|
6
6
|
const useDefineNewPasswordSchema = () => {
|
|
7
7
|
const {
|
|
8
8
|
invalidPasswordLengthError,
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { useDictionary } from "react-intlayer";
|
|
2
2
|
import { changePasswordSchemaContent } from "./useDefineNewPasswordSchema.content.mjs";
|
|
3
|
-
import { o as object, s as string } from "../../../schemas-
|
|
3
|
+
import { o as object, s as string } from "../../../schemas-itjzX6bG.js";
|
|
4
4
|
const useDefineNewPasswordSchema = () => {
|
|
5
5
|
const {
|
|
6
6
|
invalidPasswordLengthError,
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
3
3
|
const reactIntlayer = require("react-intlayer");
|
|
4
4
|
const components_Auth_ResetPasswordForm_useResetPasswordSchema_content = require("./useResetPasswordSchema.content.cjs");
|
|
5
|
-
const schemas = require("../../../schemas-
|
|
5
|
+
const schemas = require("../../../schemas-DlCjM5d_.cjs");
|
|
6
6
|
const useResetPasswordSchema = () => {
|
|
7
7
|
const { requiredErrorEmail, invalidTypeErrorEmail, invalidLengthErrorEmail } = reactIntlayer.useDictionary(components_Auth_ResetPasswordForm_useResetPasswordSchema_content.useResetPasswordSchemaContent);
|
|
8
8
|
return schemas.object({
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { useDictionary } from "react-intlayer";
|
|
2
2
|
import { useResetPasswordSchemaContent } from "./useResetPasswordSchema.content.mjs";
|
|
3
|
-
import { o as object, e as email } from "../../../schemas-
|
|
3
|
+
import { o as object, e as email } from "../../../schemas-itjzX6bG.js";
|
|
4
4
|
const useResetPasswordSchema = () => {
|
|
5
5
|
const { requiredErrorEmail, invalidTypeErrorEmail, invalidLengthErrorEmail } = useDictionary(useResetPasswordSchemaContent);
|
|
6
6
|
return object({
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
3
3
|
const reactIntlayer = require("react-intlayer");
|
|
4
4
|
const components_Auth_SignInForm_useSignInSchema_content = require("./useSignInSchema.content.cjs");
|
|
5
|
-
const schemas = require("../../../schemas-
|
|
5
|
+
const schemas = require("../../../schemas-DlCjM5d_.cjs");
|
|
6
6
|
const useSignInSchema = () => {
|
|
7
7
|
const {
|
|
8
8
|
requiredErrorEmail,
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { useDictionary } from "react-intlayer";
|
|
2
2
|
import { signInSchemaContent } from "./useSignInSchema.content.mjs";
|
|
3
|
-
import { o as object, s as string, e as email } from "../../../schemas-
|
|
3
|
+
import { o as object, s as string, e as email } from "../../../schemas-itjzX6bG.js";
|
|
4
4
|
const useSignInSchema = () => {
|
|
5
5
|
const {
|
|
6
6
|
requiredErrorEmail,
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
3
3
|
const reactIntlayer = require("react-intlayer");
|
|
4
4
|
const components_Auth_SignUpForm_useSignUpSchema_content = require("./useSignUpSchema.content.cjs");
|
|
5
|
-
const schemas = require("../../../schemas-
|
|
5
|
+
const schemas = require("../../../schemas-DlCjM5d_.cjs");
|
|
6
6
|
const useSignUpSchema = () => {
|
|
7
7
|
const {
|
|
8
8
|
requiredErrorEmail,
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { useDictionary } from "react-intlayer";
|
|
2
2
|
import { signUpSchemaContent } from "./useSignUpSchema.content.mjs";
|
|
3
|
-
import { o as object, s as string, e as email } from "../../../schemas-
|
|
3
|
+
import { o as object, s as string, e as email } from "../../../schemas-itjzX6bG.js";
|
|
4
4
|
const useSignUpSchema = () => {
|
|
5
5
|
const {
|
|
6
6
|
requiredErrorEmail,
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
3
|
-
const schemas = require("../../../schemas-
|
|
3
|
+
const schemas = require("../../../schemas-DlCjM5d_.cjs");
|
|
4
4
|
const getVerifyEmailSchema = () => {
|
|
5
5
|
return schemas.object({});
|
|
6
6
|
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { IntlayerConfig } from '@intlayer/config/client';
|
|
2
2
|
export declare const useOAuth2: (intlayerConfiguration?: IntlayerConfig) => {
|
|
3
|
-
oAuth2AccessToken:
|
|
3
|
+
oAuth2AccessToken: any;
|
|
4
4
|
};
|
|
5
5
|
//# sourceMappingURL=useOAuth2.d.ts.map
|
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
import { DialogProps } from '@radix-ui/react-dialog';
|
|
2
|
+
import { Command as CommandPrimitive } from 'cmdk';
|
|
3
|
+
import { ComponentProps, FC, HTMLAttributes } from 'react';
|
|
4
|
+
export declare const CommandRoot: FC<ComponentProps<typeof CommandPrimitive>>;
|
|
5
|
+
/**
|
|
6
|
+
* Usage example:
|
|
7
|
+
* ```jsx
|
|
8
|
+
* <Command>
|
|
9
|
+
* <Command.Trigger>
|
|
10
|
+
* <Command.Input placeholder="Search..." />
|
|
11
|
+
* </Command.Trigger>
|
|
12
|
+
* <Command.Dialog>
|
|
13
|
+
* <Command.List>
|
|
14
|
+
* <Command.Item>Item 1</Command.Item>
|
|
15
|
+
* <Command.Item>Item 2</Command.Item>
|
|
16
|
+
* <Command.Item>Item 3</Command.Item>
|
|
17
|
+
* </Command.List>
|
|
18
|
+
* </Command.Dialog>
|
|
19
|
+
* </Command>
|
|
20
|
+
* ```
|
|
21
|
+
*/
|
|
22
|
+
export declare const Command: {
|
|
23
|
+
Dialog: FC<DialogProps>;
|
|
24
|
+
Input: FC<Omit<Pick<Pick<import('react').DetailedHTMLProps<import('react').InputHTMLAttributes<HTMLInputElement>, HTMLInputElement>, "key" | keyof import('react').InputHTMLAttributes<HTMLInputElement>> & {
|
|
25
|
+
ref?: React.Ref<HTMLInputElement>;
|
|
26
|
+
} & {
|
|
27
|
+
asChild?: boolean;
|
|
28
|
+
}, "key" | "asChild" | keyof import('react').InputHTMLAttributes<HTMLInputElement>>, "onChange" | "type" | "value"> & {
|
|
29
|
+
value?: string;
|
|
30
|
+
onValueChange?: (search: string) => void;
|
|
31
|
+
} & import('react').RefAttributes<HTMLInputElement>>;
|
|
32
|
+
List: FC<{
|
|
33
|
+
children?: React.ReactNode;
|
|
34
|
+
} & Pick<Pick<import('react').DetailedHTMLProps<HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "key" | keyof HTMLAttributes<HTMLDivElement>> & {
|
|
35
|
+
ref?: React.Ref<HTMLDivElement>;
|
|
36
|
+
} & {
|
|
37
|
+
asChild?: boolean;
|
|
38
|
+
}, "key" | "asChild" | keyof HTMLAttributes<HTMLDivElement>> & {
|
|
39
|
+
label?: string;
|
|
40
|
+
} & import('react').RefAttributes<HTMLDivElement>>;
|
|
41
|
+
Empty: FC<{
|
|
42
|
+
children?: React.ReactNode;
|
|
43
|
+
} & Pick<Pick<import('react').DetailedHTMLProps<HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "key" | keyof HTMLAttributes<HTMLDivElement>> & {
|
|
44
|
+
ref?: React.Ref<HTMLDivElement>;
|
|
45
|
+
} & {
|
|
46
|
+
asChild?: boolean;
|
|
47
|
+
}, "key" | "asChild" | keyof HTMLAttributes<HTMLDivElement>> & import('react').RefAttributes<HTMLDivElement>>;
|
|
48
|
+
Group: FC<{
|
|
49
|
+
children?: React.ReactNode;
|
|
50
|
+
} & Omit<Pick<Pick<import('react').DetailedHTMLProps<HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "key" | keyof HTMLAttributes<HTMLDivElement>> & {
|
|
51
|
+
ref?: React.Ref<HTMLDivElement>;
|
|
52
|
+
} & {
|
|
53
|
+
asChild?: boolean;
|
|
54
|
+
}, "key" | "asChild" | keyof HTMLAttributes<HTMLDivElement>>, "heading" | "value"> & {
|
|
55
|
+
heading?: React.ReactNode;
|
|
56
|
+
value?: string;
|
|
57
|
+
forceMount?: boolean;
|
|
58
|
+
} & import('react').RefAttributes<HTMLDivElement>>;
|
|
59
|
+
Separator: FC<Pick<Pick<import('react').DetailedHTMLProps<HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "key" | keyof HTMLAttributes<HTMLDivElement>> & {
|
|
60
|
+
ref?: React.Ref<HTMLDivElement>;
|
|
61
|
+
} & {
|
|
62
|
+
asChild?: boolean;
|
|
63
|
+
}, "key" | "asChild" | keyof HTMLAttributes<HTMLDivElement>> & {
|
|
64
|
+
alwaysRender?: boolean;
|
|
65
|
+
} & import('react').RefAttributes<HTMLDivElement>>;
|
|
66
|
+
Item: FC<{
|
|
67
|
+
children?: React.ReactNode;
|
|
68
|
+
} & Omit<Pick<Pick<import('react').DetailedHTMLProps<HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "key" | keyof HTMLAttributes<HTMLDivElement>> & {
|
|
69
|
+
ref?: React.Ref<HTMLDivElement>;
|
|
70
|
+
} & {
|
|
71
|
+
asChild?: boolean;
|
|
72
|
+
}, "key" | "asChild" | keyof HTMLAttributes<HTMLDivElement>>, "onSelect" | "disabled" | "value"> & {
|
|
73
|
+
disabled?: boolean;
|
|
74
|
+
onSelect?: (value: string) => void;
|
|
75
|
+
value?: string;
|
|
76
|
+
keywords?: string[];
|
|
77
|
+
forceMount?: boolean;
|
|
78
|
+
} & import('react').RefAttributes<HTMLDivElement>>;
|
|
79
|
+
Shortcut: ({ className, ...props }: HTMLAttributes<HTMLSpanElement>) => import("react/jsx-runtime").JSX.Element;
|
|
80
|
+
propTypes?: any;
|
|
81
|
+
displayName?: string | undefined;
|
|
82
|
+
};
|
|
83
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/Command/index.tsx"],"names":[],"mappings":"AAGA,OAAO,EAGL,KAAK,WAAW,EACjB,MAAM,wBAAwB,CAAC;AAChC,OAAO,EAAE,OAAO,IAAI,gBAAgB,EAAE,MAAM,MAAM,CAAC;AAEnD,OAAO,EAAE,KAAK,cAAc,EAAE,KAAK,EAAE,EAAE,KAAK,cAAc,EAAE,MAAM,OAAO,CAAC;AAG1E,eAAO,MAAM,WAAW,EAAE,EAAE,CAAC,cAAc,CAAC,OAAO,gBAAgB,CAAC,CAWnE,CAAC;AA8FF;;;;;;;;;;;;;;;;GAgBG;AACH,eAAO,MAAM,OAAO;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;wCA7BjB,cAAc,CAAC,eAAe,CAAC;;;CAuCjC,CAAC"}
|
package/dist/components/DictionaryFieldEditor/DictionaryCreationForm/useDictionaryFormSchema.cjs
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
3
3
|
const reactIntlayer = require("react-intlayer");
|
|
4
4
|
const components_DictionaryFieldEditor_DictionaryCreationForm_useDictionaryFormSchema_content = require("./useDictionaryFormSchema.content.cjs");
|
|
5
|
-
const schemas = require("../../../schemas-
|
|
5
|
+
const schemas = require("../../../schemas-DlCjM5d_.cjs");
|
|
6
6
|
const useDictionarySchema = (projectId) => {
|
|
7
7
|
const {
|
|
8
8
|
requiredErrorName,
|
package/dist/components/DictionaryFieldEditor/DictionaryCreationForm/useDictionaryFormSchema.mjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { useDictionary } from "react-intlayer";
|
|
2
2
|
import { dictionaryFormSchemaContent } from "./useDictionaryFormSchema.content.mjs";
|
|
3
|
-
import { o as object, a as array, s as string } from "../../../schemas-
|
|
3
|
+
import { o as object, a as array, s as string } from "../../../schemas-itjzX6bG.js";
|
|
4
4
|
const useDictionarySchema = (projectId) => {
|
|
5
5
|
const {
|
|
6
6
|
requiredErrorName,
|
package/dist/components/DictionaryFieldEditor/DictionaryDetails/useDictionaryDetailsSchema.cjs
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
3
3
|
const reactIntlayer = require("react-intlayer");
|
|
4
4
|
const components_DictionaryFieldEditor_DictionaryDetails_useDictionaryDetailsSchema_content = require("./useDictionaryDetailsSchema.content.cjs");
|
|
5
|
-
const schemas = require("../../../schemas-
|
|
5
|
+
const schemas = require("../../../schemas-DlCjM5d_.cjs");
|
|
6
6
|
const useDictionaryDetailsSchema = (projectId) => {
|
|
7
7
|
const {
|
|
8
8
|
titleRequiredError,
|
package/dist/components/DictionaryFieldEditor/DictionaryDetails/useDictionaryDetailsSchema.mjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { useDictionary } from "react-intlayer";
|
|
2
2
|
import { useDictionaryDetailsSchemaContent } from "./useDictionaryDetailsSchema.content.mjs";
|
|
3
|
-
import { o as object, a as array, s as string } from "../../../schemas-
|
|
3
|
+
import { o as object, a as array, s as string } from "../../../schemas-itjzX6bG.js";
|
|
4
4
|
const useDictionaryDetailsSchema = (projectId) => {
|
|
5
5
|
const {
|
|
6
6
|
titleRequiredError,
|
|
@@ -214,7 +214,7 @@ const ObjectView = ({
|
|
|
214
214
|
if (!section || typeof section !== "object") {
|
|
215
215
|
return /* @__PURE__ */ jsxRuntime.jsx("div", { children: "Not an object" });
|
|
216
216
|
}
|
|
217
|
-
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col gap-2 overflow-y-
|
|
217
|
+
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col gap-2 overflow-y-auto", children: [
|
|
218
218
|
/* @__PURE__ */ jsxRuntime.jsx("ul", { className: "mr-auto flex flex-col gap-4", children: Object.keys(section).map((key) => /* @__PURE__ */ jsxRuntime.jsx("li", { className: "flex w-full", children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
219
219
|
NodeView,
|
|
220
220
|
{
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"StructureView.cjs","sources":["../../../../src/components/DictionaryFieldEditor/StructureView/StructureView.tsx"],"sourcesContent":["'use client';\n\nimport {\n type KeyPath,\n type TypedNode,\n type ContentNode,\n getNodeChildren,\n getNodeType,\n isSameKeyPath,\n NodeType,\n getDefaultNode,\n} from '@intlayer/core';\nimport {\n useConfiguration,\n useEditedContentActions,\n useFocusDictionary,\n useFocusDictionaryActions,\n} from '@intlayer/editor-react';\nimport { Plus, Trash } from 'lucide-react';\nimport { type FC } from 'react';\nimport { useDictionary } from 'react-intlayer';\nimport { camelCaseToSentence } from '../../../utils/camelCase';\nimport { Button } from '../../Button';\nimport { Container } from '../../Container';\nimport { EditableFieldInput } from '../../EditableField';\nimport { NodeTypeSelector } from '../NodeTypeSelector';\nimport { structureViewContent } from './structureView.content';\n\ntype NodeTypeViewProps = {\n dictionaryKey: string;\n keyPath: KeyPath[];\n section: ContentNode;\n onNodeTypeChange: (content?: ContentNode) => void;\n};\n\nconst NodeTypeView: FC<NodeTypeViewProps> = ({\n section,\n dictionaryKey,\n keyPath,\n onNodeTypeChange: onNodeTypeChangeProp,\n}) => {\n const locales = useConfiguration()?.internationalization.locales ?? [];\n const nodeType = getNodeType(section);\n const children = getNodeChildren(section);\n\n const onNodeTypeChange = (content?: ContentNode) => {\n const transformedContent = getDefaultNode(\n nodeType,\n locales,\n content\n ) as ContentNode;\n\n onNodeTypeChangeProp(transformedContent);\n };\n\n if (\n nodeType === NodeType.Translation ||\n nodeType === NodeType.Condition ||\n nodeType === NodeType.Enumeration\n ) {\n const firstKey = Object.keys(\n (section as unknown as TypedNode)[nodeType as keyof typeof section]\n )[0];\n const childrenKeyPath = [\n ...keyPath,\n { type: nodeType, key: firstKey },\n ] as KeyPath[];\n\n return (\n <div className=\"flex w-full flex-col gap-1\">\n <NodeTypeSelector\n section={section}\n onValueChange={(nodeType) =>\n onNodeTypeChangeProp(\n getDefaultNode(nodeType, locales) as ContentNode\n )\n }\n />\n\n <NodeTypeView\n section={children}\n keyPath={childrenKeyPath}\n dictionaryKey={dictionaryKey}\n onNodeTypeChange={onNodeTypeChange}\n />\n </div>\n );\n }\n\n if (nodeType === NodeType.Array) {\n const childrenKeyPath = [...keyPath, { type: nodeType, key: 0 } as KeyPath];\n return (\n <div className=\"flex w-full flex-col gap-1\">\n <NodeTypeSelector\n section={section}\n onValueChange={(nodeType) =>\n onNodeTypeChangeProp(\n getDefaultNode(nodeType, locales) as ContentNode\n )\n }\n />\n\n <NodeTypeView\n section={children}\n keyPath={childrenKeyPath}\n dictionaryKey={dictionaryKey}\n onNodeTypeChange={onNodeTypeChange}\n />\n </div>\n );\n }\n\n if (nodeType === NodeType.Object) {\n return (\n <>\n <NodeTypeSelector\n section={section}\n onValueChange={(nodeType) =>\n onNodeTypeChangeProp(\n getDefaultNode(nodeType, locales) as ContentNode\n )\n }\n />\n <div className=\"ml-10 mt-6\">\n <StructureView\n keyPath={keyPath}\n section={section}\n dictionaryKey={dictionaryKey}\n />\n </div>\n </>\n );\n }\n\n return (\n <NodeTypeSelector\n section={section}\n onValueChange={(nodeType) =>\n onNodeTypeChangeProp(getDefaultNode(nodeType, locales) as ContentNode)\n }\n />\n );\n};\n\ntype NodeWrapperProps = {\n sectionKey?: string;\n dictionaryKey: string;\n keyPath: KeyPath[];\n section: ContentNode;\n};\n\nexport const NodeView: FC<NodeWrapperProps> = ({\n sectionKey,\n section,\n keyPath,\n dictionaryKey,\n}) => {\n const { focusedContent, setFocusedContentKeyPath } = useFocusDictionary();\n const { renameEditedContent, addEditedContent } = useEditedContentActions();\n\n const { titleInput, deleteButton } = useDictionary(structureViewContent);\n\n const handleRenameNodeKey = (keyName: string) => {\n renameEditedContent(dictionaryKey, keyName, keyPath);\n const prevKeyPath: KeyPath[] = keyPath.slice(0, -1);\n const lastKeyPath: KeyPath = keyPath[keyPath.length - 1];\n const newKeyPath: KeyPath[] = [\n ...prevKeyPath,\n { ...lastKeyPath, key: keyName } as KeyPath,\n ];\n setFocusedContentKeyPath(newKeyPath);\n };\n\n return (\n <Container\n transparency=\"xl\"\n roundedSize=\"xl\"\n className=\"w-full min-w-80 gap-2 overflow-auto px-5 py-2\"\n border\n borderColor=\"text\"\n background=\"none\"\n aria-selected={isSameKeyPath(keyPath, focusedContent?.keyPath ?? [])}\n onClick={() => setFocusedContentKeyPath(keyPath)}\n >\n <div className=\"flex w-full flex-col items-start justify-between gap-3\">\n {typeof sectionKey === 'string' && (\n <div className=\"w-full\">\n <div className=\"flex w-full items-center justify-between gap-10\">\n <EditableFieldInput\n name=\"key\"\n aria-label=\"Key\"\n placeholder={titleInput.placeholder.value}\n defaultValue={sectionKey}\n onSave={(value) => handleRenameNodeKey(value)}\n variant=\"invisible\"\n />\n <Button\n label={deleteButton.label.value}\n variant=\"hoverable\"\n size=\"icon-sm\"\n color=\"text\"\n className=\"translate-x-2\"\n Icon={Trash}\n onClick={() => {\n addEditedContent(dictionaryKey, undefined, keyPath);\n\n const parentKeyPath: KeyPath[] = keyPath.slice(0, -1);\n setFocusedContentKeyPath(parentKeyPath);\n }}\n />\n </div>\n\n <span className=\"text-neutral ml-3 text-sm\">\n ( {camelCaseToSentence(sectionKey)} )\n </span>\n </div>\n )}\n <NodeTypeView\n keyPath={keyPath}\n dictionaryKey={dictionaryKey}\n section={section}\n onNodeTypeChange={(content) => {\n addEditedContent(dictionaryKey, content, keyPath);\n }}\n />\n </div>\n </Container>\n );\n};\n\ntype ObjectViewProps = {\n dictionaryKey: string;\n keyPath: KeyPath[];\n section: ContentNode;\n};\n\nexport const ObjectView: FC<ObjectViewProps> = ({\n section,\n keyPath,\n dictionaryKey,\n}) => {\n const { addNodeButton } = useDictionary(structureViewContent);\n const { setFocusedContentKeyPath } = useFocusDictionaryActions();\n const { addEditedContent } = useEditedContentActions();\n\n if (!section || typeof section !== 'object') {\n return <div>Not an object</div>;\n }\n\n return (\n <div className=\"flex flex-col gap-2 overflow-y-scroll\">\n <ul className=\"mr-auto flex flex-col gap-4\">\n {Object.keys(section).map((key) => (\n <li key={key} className=\"flex w-full\">\n <NodeView\n sectionKey={key}\n section={section?.[key as keyof typeof section]}\n keyPath={[...keyPath, { type: NodeType.Object, key }]}\n dictionaryKey={dictionaryKey}\n />\n </li>\n ))}\n </ul>\n <Button\n label={addNodeButton.label.value}\n variant=\"hoverable\"\n size=\"md\"\n color=\"text\"\n Icon={Plus}\n className=\"flex-1\"\n onClick={() => {\n const newKey = 'newKey';\n const newKeyPath = [\n ...keyPath,\n { type: NodeType.Object, key: newKey },\n ] as KeyPath[];\n addEditedContent(dictionaryKey, '', newKeyPath);\n setFocusedContentKeyPath(newKeyPath);\n }}\n >\n {addNodeButton.text}\n </Button>\n </div>\n );\n};\n\ntype StructureViewProps = {\n dictionaryKey: string;\n keyPath: KeyPath[];\n section: ContentNode;\n};\n\nexport const StructureView: FC<StructureViewProps> = ({\n section,\n keyPath,\n dictionaryKey,\n}) => {\n if (\n !section ||\n typeof section !== 'object' ||\n typeof section.nodeType === 'string'\n ) {\n return (\n <NodeView\n sectionKey={'content'}\n section={section}\n keyPath={keyPath}\n dictionaryKey={dictionaryKey}\n />\n );\n }\n\n return (\n <ObjectView\n section={section}\n keyPath={keyPath}\n dictionaryKey={dictionaryKey}\n />\n );\n};\n"],"names":["useConfiguration","getNodeType","getNodeChildren","getDefaultNode","NodeType","jsxs","jsx","NodeTypeSelector","nodeType","Fragment","useFocusDictionary","useEditedContentActions","useDictionary","structureViewContent","Container","isSameKeyPath","EditableFieldInput","Button","Trash","camelCaseToSentence","useFocusDictionaryActions","Plus"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;AAmCA,MAAM,eAAsC,CAAC;AAAA,EAC3C;AAAA,EACA;AAAA,EACA;AAAA,EACA,kBAAkB;AACpB,MAAM;AACJ,QAAM,UAAUA,YAAA,iBAAA,GAAoB,qBAAqB,WAAW,CAAC;AAC/D,QAAA,WAAWC,iBAAY,OAAO;AAC9B,QAAA,WAAWC,qBAAgB,OAAO;AAElC,QAAA,mBAAmB,CAAC,YAA0B;AAClD,UAAM,qBAAqBC,KAAA;AAAA,MACzB;AAAA,MACA;AAAA,MACA;AAAA,IACF;AAEA,yBAAqB,kBAAkB;AAAA,EACzC;AAGE,MAAA,aAAaC,cAAS,eACtB,aAAaA,cAAS,aACtB,aAAaA,cAAS,aACtB;AACA,UAAM,WAAW,OAAO;AAAA,MACrB,QAAiC,QAAgC;AAAA,MAClE,CAAC;AACH,UAAM,kBAAkB;AAAA,MACtB,GAAG;AAAA,MACH,EAAE,MAAM,UAAU,KAAK,SAAS;AAAA,IAClC;AAGE,WAAAC,2BAAA,KAAC,OAAI,EAAA,WAAU,8BACb,UAAA;AAAA,MAAAC,2BAAA;AAAA,QAACC,kDAAA;AAAA,QAAA;AAAA,UACC;AAAA,UACA,eAAe,CAACC,cACd;AAAA,YACEL,KAAA,eAAeK,WAAU,OAAO;AAAA,UAAA;AAAA,QAClC;AAAA,MAEJ;AAAA,MAEAF,2BAAA;AAAA,QAAC;AAAA,QAAA;AAAA,UACC,SAAS;AAAA,UACT,SAAS;AAAA,UACT;AAAA,UACA;AAAA,QAAA;AAAA,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AMF,cAAS,QAAQ,KAAK;AAAA,QACpD;AAAA,MAAA;AAAA,IAAA,KALK,GAOT,CACD,GACH;AAAA,IACAE,2BAAA;AAAA,MAACW,yBAAA;AAAA,MAAA;AAAA,QACC,OAAO,cAAc,MAAM;AAAA,QAC3B,SAAQ;AAAA,QACR,MAAK;AAAA,QACL,OAAM;AAAA,QACN,MAAMI,YAAA;AAAA,QACN,WAAU;AAAA,QACV,SAAS,MAAM;AACb,gBAAM,SAAS;AACf,gBAAM,aAAa;AAAA,YACjB,GAAG;AAAA,YACH,EAAE,MAAMjB,KAAAA,SAAS,QAAQ,KAAK,OAAO;AAAA,UACvC;AACiB,2BAAA,eAAe,IAAI,UAAU;AAC9C,mCAAyB,UAAU;AAAA,QACrC;AAAA,QAEC,UAAc,cAAA;AAAA,MAAA;AAAA,IAAA;AAAA,EACjB,GACF;AAEJ;AAQO,MAAM,gBAAwC,CAAC;AAAA,EACpD;AAAA,EACA;AAAA,EACA;AACF,MAAM;AAEF,MAAA,CAAC,WACD,OAAO,YAAY,YACnB,OAAO,QAAQ,aAAa,UAC5B;AAEE,WAAAE,2BAAA;AAAA,MAAC;AAAA,MAAA;AAAA,QACC,YAAY;AAAA,QACZ;AAAA,QACA;AAAA,QACA;AAAA,MAAA;AAAA,IACF;AAAA,EAAA;AAKF,SAAAA,2BAAA;AAAA,IAAC;AAAA,IAAA;AAAA,MACC;AAAA,MACA;AAAA,MACA;AAAA,IAAA;AAAA,EACF;AAEJ;;;;"}
|
|
1
|
+
{"version":3,"file":"StructureView.cjs","sources":["../../../../src/components/DictionaryFieldEditor/StructureView/StructureView.tsx"],"sourcesContent":["'use client';\n\nimport {\n type ContentNode,\n getDefaultNode,\n getNodeChildren,\n getNodeType,\n isSameKeyPath,\n type KeyPath,\n NodeType,\n type TypedNode,\n} from '@intlayer/core';\nimport {\n useConfiguration,\n useEditedContentActions,\n useFocusDictionary,\n useFocusDictionaryActions,\n} from '@intlayer/editor-react';\nimport { Plus, Trash } from 'lucide-react';\nimport { type FC } from 'react';\nimport { useDictionary } from 'react-intlayer';\nimport { camelCaseToSentence } from '../../../utils/camelCase';\nimport { Button } from '../../Button';\nimport { Container } from '../../Container';\nimport { EditableFieldInput } from '../../EditableField';\nimport { NodeTypeSelector } from '../NodeTypeSelector';\nimport { structureViewContent } from './structureView.content';\n\ntype NodeTypeViewProps = {\n dictionaryKey: string;\n keyPath: KeyPath[];\n section: ContentNode;\n onNodeTypeChange: (content?: ContentNode) => void;\n};\n\nconst NodeTypeView: FC<NodeTypeViewProps> = ({\n section,\n dictionaryKey,\n keyPath,\n onNodeTypeChange: onNodeTypeChangeProp,\n}) => {\n const locales = useConfiguration()?.internationalization.locales ?? [];\n const nodeType = getNodeType(section);\n const children = getNodeChildren(section);\n\n const onNodeTypeChange = (content?: ContentNode) => {\n const transformedContent = getDefaultNode(\n nodeType,\n locales,\n content\n ) as ContentNode;\n\n onNodeTypeChangeProp(transformedContent);\n };\n\n if (\n nodeType === NodeType.Translation ||\n nodeType === NodeType.Condition ||\n nodeType === NodeType.Enumeration\n ) {\n const firstKey = Object.keys(\n (section as unknown as TypedNode)[nodeType as keyof typeof section]\n )[0];\n const childrenKeyPath = [\n ...keyPath,\n { type: nodeType, key: firstKey },\n ] as KeyPath[];\n\n return (\n <div className=\"flex w-full flex-col gap-1\">\n <NodeTypeSelector\n section={section}\n onValueChange={(nodeType) =>\n onNodeTypeChangeProp(\n getDefaultNode(nodeType, locales) as ContentNode\n )\n }\n />\n\n <NodeTypeView\n section={children}\n keyPath={childrenKeyPath}\n dictionaryKey={dictionaryKey}\n onNodeTypeChange={onNodeTypeChange}\n />\n </div>\n );\n }\n\n if (nodeType === NodeType.Array) {\n const childrenKeyPath = [...keyPath, { type: nodeType, key: 0 } as KeyPath];\n return (\n <div className=\"flex w-full flex-col gap-1\">\n <NodeTypeSelector\n section={section}\n onValueChange={(nodeType) =>\n onNodeTypeChangeProp(\n getDefaultNode(nodeType, locales) as ContentNode\n )\n }\n />\n\n <NodeTypeView\n section={children}\n keyPath={childrenKeyPath}\n dictionaryKey={dictionaryKey}\n onNodeTypeChange={onNodeTypeChange}\n />\n </div>\n );\n }\n\n if (nodeType === NodeType.Object) {\n return (\n <>\n <NodeTypeSelector\n section={section}\n onValueChange={(nodeType) =>\n onNodeTypeChangeProp(\n getDefaultNode(nodeType, locales) as ContentNode\n )\n }\n />\n <div className=\"ml-10 mt-6\">\n <StructureView\n keyPath={keyPath}\n section={section}\n dictionaryKey={dictionaryKey}\n />\n </div>\n </>\n );\n }\n\n return (\n <NodeTypeSelector\n section={section}\n onValueChange={(nodeType) =>\n onNodeTypeChangeProp(getDefaultNode(nodeType, locales) as ContentNode)\n }\n />\n );\n};\n\ntype NodeWrapperProps = {\n sectionKey?: string;\n dictionaryKey: string;\n keyPath: KeyPath[];\n section: ContentNode;\n};\n\nexport const NodeView: FC<NodeWrapperProps> = ({\n sectionKey,\n section,\n keyPath,\n dictionaryKey,\n}) => {\n const { focusedContent, setFocusedContentKeyPath } = useFocusDictionary();\n const { renameEditedContent, addEditedContent } = useEditedContentActions();\n\n const { titleInput, deleteButton } = useDictionary(structureViewContent);\n\n const handleRenameNodeKey = (keyName: string) => {\n renameEditedContent(dictionaryKey, keyName, keyPath);\n const prevKeyPath: KeyPath[] = keyPath.slice(0, -1);\n const lastKeyPath: KeyPath = keyPath[keyPath.length - 1];\n const newKeyPath: KeyPath[] = [\n ...prevKeyPath,\n { ...lastKeyPath, key: keyName } as KeyPath,\n ];\n setFocusedContentKeyPath(newKeyPath);\n };\n\n return (\n <Container\n transparency=\"xl\"\n roundedSize=\"xl\"\n className=\"w-full min-w-80 gap-2 overflow-auto px-5 py-2\"\n border\n borderColor=\"text\"\n background=\"none\"\n aria-selected={isSameKeyPath(keyPath, focusedContent?.keyPath ?? [])}\n onClick={() => setFocusedContentKeyPath(keyPath)}\n >\n <div className=\"flex w-full flex-col items-start justify-between gap-3\">\n {typeof sectionKey === 'string' && (\n <div className=\"w-full\">\n <div className=\"flex w-full items-center justify-between gap-10\">\n <EditableFieldInput\n name=\"key\"\n aria-label=\"Key\"\n placeholder={titleInput.placeholder.value}\n defaultValue={sectionKey}\n onSave={(value) => handleRenameNodeKey(value)}\n variant=\"invisible\"\n />\n <Button\n label={deleteButton.label.value}\n variant=\"hoverable\"\n size=\"icon-sm\"\n color=\"text\"\n className=\"translate-x-2\"\n Icon={Trash}\n onClick={() => {\n addEditedContent(dictionaryKey, undefined, keyPath);\n\n const parentKeyPath: KeyPath[] = keyPath.slice(0, -1);\n setFocusedContentKeyPath(parentKeyPath);\n }}\n />\n </div>\n\n <span className=\"text-neutral ml-3 text-sm\">\n ( {camelCaseToSentence(sectionKey)} )\n </span>\n </div>\n )}\n <NodeTypeView\n keyPath={keyPath}\n dictionaryKey={dictionaryKey}\n section={section}\n onNodeTypeChange={(content) => {\n addEditedContent(dictionaryKey, content, keyPath);\n }}\n />\n </div>\n </Container>\n );\n};\n\ntype ObjectViewProps = {\n dictionaryKey: string;\n keyPath: KeyPath[];\n section: ContentNode;\n};\n\nexport const ObjectView: FC<ObjectViewProps> = ({\n section,\n keyPath,\n dictionaryKey,\n}) => {\n const { addNodeButton } = useDictionary(structureViewContent);\n const { setFocusedContentKeyPath } = useFocusDictionaryActions();\n const { addEditedContent } = useEditedContentActions();\n\n if (!section || typeof section !== 'object') {\n return <div>Not an object</div>;\n }\n\n return (\n <div className=\"flex flex-col gap-2 overflow-y-auto\">\n <ul className=\"mr-auto flex flex-col gap-4\">\n {Object.keys(section).map((key) => (\n <li key={key} className=\"flex w-full\">\n <NodeView\n sectionKey={key}\n section={section?.[key as keyof typeof section]}\n keyPath={[...keyPath, { type: NodeType.Object, key }]}\n dictionaryKey={dictionaryKey}\n />\n </li>\n ))}\n </ul>\n <Button\n label={addNodeButton.label.value}\n variant=\"hoverable\"\n size=\"md\"\n color=\"text\"\n Icon={Plus}\n className=\"flex-1\"\n onClick={() => {\n const newKey = 'newKey';\n const newKeyPath = [\n ...keyPath,\n { type: NodeType.Object, key: newKey },\n ] as KeyPath[];\n addEditedContent(dictionaryKey, '', newKeyPath);\n setFocusedContentKeyPath(newKeyPath);\n }}\n >\n {addNodeButton.text}\n </Button>\n </div>\n );\n};\n\ntype StructureViewProps = {\n dictionaryKey: string;\n keyPath: KeyPath[];\n section: ContentNode;\n};\n\nexport const StructureView: FC<StructureViewProps> = ({\n section,\n keyPath,\n dictionaryKey,\n}) => {\n if (\n !section ||\n typeof section !== 'object' ||\n typeof section.nodeType === 'string'\n ) {\n return (\n <NodeView\n sectionKey={'content'}\n section={section}\n keyPath={keyPath}\n dictionaryKey={dictionaryKey}\n />\n );\n }\n\n return (\n <ObjectView\n section={section}\n keyPath={keyPath}\n dictionaryKey={dictionaryKey}\n />\n );\n};\n"],"names":["useConfiguration","getNodeType","getNodeChildren","getDefaultNode","NodeType","jsxs","jsx","NodeTypeSelector","nodeType","Fragment","useFocusDictionary","useEditedContentActions","useDictionary","structureViewContent","Container","isSameKeyPath","EditableFieldInput","Button","Trash","camelCaseToSentence","useFocusDictionaryActions","Plus"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;AAmCA,MAAM,eAAsC,CAAC;AAAA,EAC3C;AAAA,EACA;AAAA,EACA;AAAA,EACA,kBAAkB;AACpB,MAAM;AACJ,QAAM,UAAUA,YAAA,iBAAA,GAAoB,qBAAqB,WAAW,CAAC;AAC/D,QAAA,WAAWC,iBAAY,OAAO;AAC9B,QAAA,WAAWC,qBAAgB,OAAO;AAElC,QAAA,mBAAmB,CAAC,YAA0B;AAClD,UAAM,qBAAqBC,KAAA;AAAA,MACzB;AAAA,MACA;AAAA,MACA;AAAA,IACF;AAEA,yBAAqB,kBAAkB;AAAA,EACzC;AAGE,MAAA,aAAaC,cAAS,eACtB,aAAaA,cAAS,aACtB,aAAaA,cAAS,aACtB;AACA,UAAM,WAAW,OAAO;AAAA,MACrB,QAAiC,QAAgC;AAAA,MAClE,CAAC;AACH,UAAM,kBAAkB;AAAA,MACtB,GAAG;AAAA,MACH,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;AAAA,MACC;AAAA,MACA;AAAA,MACA;AAAA,IAAA;AAAA,EACF;AAEJ;;;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"StructureView.d.ts","sourceRoot":"","sources":["../../../../src/components/DictionaryFieldEditor/StructureView/StructureView.tsx"],"names":[],"mappings":"AAEA,OAAO,EACL,KAAK,
|
|
1
|
+
{"version":3,"file":"StructureView.d.ts","sourceRoot":"","sources":["../../../../src/components/DictionaryFieldEditor/StructureView/StructureView.tsx"],"names":[],"mappings":"AAEA,OAAO,EACL,KAAK,WAAW,EAKhB,KAAK,OAAO,EAGb,MAAM,gBAAgB,CAAC;AAQxB,OAAO,EAAE,KAAK,EAAE,EAAE,MAAM,OAAO,CAAC;AA6HhC,KAAK,gBAAgB,GAAG;IACtB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,aAAa,EAAE,MAAM,CAAC;IACtB,OAAO,EAAE,OAAO,EAAE,CAAC;IACnB,OAAO,EAAE,WAAW,CAAC;CACtB,CAAC;AAEF,eAAO,MAAM,QAAQ,EAAE,EAAE,CAAC,gBAAgB,CA6EzC,CAAC;AAEF,KAAK,eAAe,GAAG;IACrB,aAAa,EAAE,MAAM,CAAC;IACtB,OAAO,EAAE,OAAO,EAAE,CAAC;IACnB,OAAO,EAAE,WAAW,CAAC;CACtB,CAAC;AAEF,eAAO,MAAM,UAAU,EAAE,EAAE,CAAC,eAAe,CAgD1C,CAAC;AAEF,KAAK,kBAAkB,GAAG;IACxB,aAAa,EAAE,MAAM,CAAC;IACtB,OAAO,EAAE,OAAO,EAAE,CAAC;IACnB,OAAO,EAAE,WAAW,CAAC;CACtB,CAAC;AAEF,eAAO,MAAM,aAAa,EAAE,EAAE,CAAC,kBAAkB,CA2BhD,CAAC"}
|
|
@@ -212,7 +212,7 @@ const ObjectView = ({
|
|
|
212
212
|
if (!section || typeof section !== "object") {
|
|
213
213
|
return /* @__PURE__ */ jsx("div", { children: "Not an object" });
|
|
214
214
|
}
|
|
215
|
-
return /* @__PURE__ */ jsxs("div", { className: "flex flex-col gap-2 overflow-y-
|
|
215
|
+
return /* @__PURE__ */ jsxs("div", { className: "flex flex-col gap-2 overflow-y-auto", children: [
|
|
216
216
|
/* @__PURE__ */ jsx("ul", { className: "mr-auto flex flex-col gap-4", children: Object.keys(section).map((key) => /* @__PURE__ */ jsx("li", { className: "flex w-full", children: /* @__PURE__ */ jsx(
|
|
217
217
|
NodeView,
|
|
218
218
|
{
|