@payload-enchants/translator 1.1.38 → 1.1.40
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/client/api/index.d.ts.map +1 -1
- package/dist/client/components/CustomButton/index.d.ts +1 -2
- package/dist/client/components/CustomButton/index.d.ts.map +1 -1
- package/dist/client/components/LocaleLabel/LocaleLabel.d.ts +0 -1
- package/dist/client/components/LocaleLabel/LocaleLabel.d.ts.map +1 -1
- package/dist/client/components/ResolverButton/ResolverButton.d.ts +0 -1
- package/dist/client/components/ResolverButton/ResolverButton.d.ts.map +1 -1
- package/dist/client/components/TranslatorModal/Content.d.ts +0 -1
- package/dist/client/components/TranslatorModal/Content.d.ts.map +1 -1
- package/dist/client/components/TranslatorModal/TranslatorModal.d.ts +0 -1
- package/dist/client/components/TranslatorModal/TranslatorModal.d.ts.map +1 -1
- package/dist/client/providers/Translator/context.d.ts +0 -1
- package/dist/client/providers/Translator/context.d.ts.map +1 -1
- package/dist/translate/findEntityWithConfig.d.ts.map +1 -1
- package/dist/translate/traverseFields.d.ts.map +1 -1
- package/dist/translate/traverseFields.js +5 -5
- package/dist/translate/traverseFields.js.map +1 -1
- package/dist/translate/traverseRichText.d.ts.map +1 -1
- package/dist/translate/updateEntity.d.ts.map +1 -1
- package/dist/utils/chunkArray.d.ts.map +1 -1
- package/package.json +1 -1
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/client/api/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,qBAAqB,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;AAEpF,eAAO,MAAM,YAAY,uBAAwB;IAAE,GAAG,EAAE,MAAM,CAAC;IAAC,SAAS,EAAE,MAAM,CAAA;CAAE;sBAClD,qBAAqB,KAAG,
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/client/api/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,qBAAqB,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;AAEpF,eAAO,MAAM,YAAY,uBAAwB;IAAE,GAAG,EAAE,MAAM,CAAC;IAAC,SAAS,EAAE,MAAM,CAAA;CAAE;sBAClD,qBAAqB,KAAG,OAAO,CAAC,eAAe,CAAC;CAwBhF,CAAC"}
|
@@ -1,3 +1,2 @@
|
|
1
|
-
|
2
|
-
export declare const CustomButton: (type: 'publish' | 'save') => () => import("react").JSX.Element;
|
1
|
+
export declare const CustomButton: (type: "publish" | "save") => () => import("react").JSX.Element;
|
3
2
|
//# sourceMappingURL=index.d.ts.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/client/components/CustomButton/index.tsx"],"names":[],"mappings":"
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/client/components/CustomButton/index.tsx"],"names":[],"mappings":"AAKA,eAAO,MAAM,YAAY,SAAU,SAAS,GAAG,MAAM,sCAMpD,CAAC"}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"LocaleLabel.d.ts","sourceRoot":"","sources":["../../../../src/client/components/LocaleLabel/LocaleLabel.tsx"],"names":[],"mappings":"
|
1
|
+
{"version":3,"file":"LocaleLabel.d.ts","sourceRoot":"","sources":["../../../../src/client/components/LocaleLabel/LocaleLabel.tsx"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,gBAAgB,CAAC;AAI7C,eAAO,MAAM,WAAW,eAAgB;IAAE,MAAM,EAAE,MAAM,CAAA;CAAE,gCAczD,CAAC"}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"ResolverButton.d.ts","sourceRoot":"","sources":["../../../../src/client/components/ResolverButton/ResolverButton.tsx"],"names":[],"mappings":"
|
1
|
+
{"version":3,"file":"ResolverButton.d.ts","sourceRoot":"","sources":["../../../../src/client/components/ResolverButton/ResolverButton.tsx"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,0BAA0B,CAAC;AAGlE,eAAO,MAAM,cAAc,wCAExB;IACD,QAAQ,EAAE,iBAAiB,CAAC;CAC7B,gCAYA,CAAC"}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"Content.d.ts","sourceRoot":"","sources":["../../../../src/client/components/TranslatorModal/Content.tsx"],"names":[],"mappings":"
|
1
|
+
{"version":3,"file":"Content.d.ts","sourceRoot":"","sources":["../../../../src/client/components/TranslatorModal/Content.tsx"],"names":[],"mappings":"AAOA,eAAO,MAAM,OAAO,mCAwDnB,CAAC"}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"TranslatorModal.d.ts","sourceRoot":"","sources":["../../../../src/client/components/TranslatorModal/TranslatorModal.tsx"],"names":[],"mappings":"
|
1
|
+
{"version":3,"file":"TranslatorModal.d.ts","sourceRoot":"","sources":["../../../../src/client/components/TranslatorModal/TranslatorModal.tsx"],"names":[],"mappings":"AAAA,OAAO,eAAe,CAAC;AAOvB,eAAO,MAAM,eAAe,+CAkB3B,CAAC"}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"context.d.ts","sourceRoot":"","sources":["../../../../src/client/providers/Translator/context.ts"],"names":[],"mappings":"
|
1
|
+
{"version":3,"file":"context.d.ts","sourceRoot":"","sources":["../../../../src/client/providers/Translator/context.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,gBAAgB,CAAC;AAG7C,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,0BAA0B,CAAC;AAElE,KAAK,qBAAqB,GAAG;IAC3B,eAAe,EAAE,MAAM,IAAI,CAAC;IAC5B,qBAAqB,EAAE,MAAM,CAAC;IAC9B,cAAc,EAAE,MAAM,EAAE,CAAC;IACzB,SAAS,EAAE,MAAM,CAAC;IAClB,cAAc,EAAE,CAAC,IAAI,EAAE;QAAE,WAAW,EAAE,MAAM,CAAA;KAAE,KAAK,IAAI,CAAC;IACxD,QAAQ,EAAE,iBAAiB,GAAG,IAAI,CAAC;IACnC,SAAS,EAAE,CACT,GAAG,EACC,aAAa,GACb,cAAc,GACd,YAAY,GACZ,wBAAwB,GACxB,uBAAuB,GACvB,gBAAgB,KACjB,MAAM,CAAC;IACZ,wBAAwB,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,IAAI,CAAC;IACjD,MAAM,EAAE,CAAC,IAAI,EAAE;QAAE,SAAS,EAAE,OAAO,CAAA;KAAE,KAAK,OAAO,CAAC,IAAI,CAAC,CAAC;CACzD,CAAC;AAEF,eAAO,MAAM,iBAAiB,uDAAoD,CAAC;AAEnF,eAAO,MAAM,aAAa,6BAMzB,CAAC"}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"findEntityWithConfig.d.ts","sourceRoot":"","sources":["../../src/translate/findEntityWithConfig.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EACV,cAAc,EACd,yBAAyB,EACzB,qBAAqB,EACrB,UAAU,EACX,MAAM,eAAe,CAAC;AAEvB,KAAK,IAAI,GAAG;IACV,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,EAAE,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;IACrB,MAAM,EAAE,MAAM,CAAC;IACf,cAAc,CAAC,EAAE,OAAO,CAAC;IACzB,GAAG,EAAE,cAAc,CAAC;CACrB,CAAC;AAOF,eAAO,MAAM,oBAAoB,SACzB,IAAI,KACT,
|
1
|
+
{"version":3,"file":"findEntityWithConfig.d.ts","sourceRoot":"","sources":["../../src/translate/findEntityWithConfig.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EACV,cAAc,EACd,yBAAyB,EACzB,qBAAqB,EACrB,UAAU,EACX,MAAM,eAAe,CAAC;AAEvB,KAAK,IAAI,GAAG;IACV,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,EAAE,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;IACrB,MAAM,EAAE,MAAM,CAAC;IACf,cAAc,CAAC,EAAE,OAAO,CAAC;IACzB,GAAG,EAAE,cAAc,CAAC;CACrB,CAAC;AAOF,eAAO,MAAM,oBAAoB,SACzB,IAAI,KACT,OAAO,CAAC;IACT,MAAM,EAAE,yBAAyB,GAAG,qBAAqB,CAAC;IAC1D,GAAG,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,UAAU,CAAC;CAC3C,CA0CA,CAAC"}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"traverseFields.d.ts","sourceRoot":"","sources":["../../src/translate/traverseFields.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,KAAK,KAAK,EAAc,MAAM,eAAe,CAAC;AAIvD,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,SAAS,CAAC;AAEhD,eAAO,MAAM,cAAc,iIASxB;IACD,QAAQ,EAAE,
|
1
|
+
{"version":3,"file":"traverseFields.d.ts","sourceRoot":"","sources":["../../src/translate/traverseFields.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,KAAK,KAAK,EAAc,MAAM,eAAe,CAAC;AAIvD,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,SAAS,CAAC;AAEhD,eAAO,MAAM,cAAc,iIASxB;IACD,QAAQ,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IAClC,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,MAAM,EAAE,KAAK,EAAE,CAAC;IAChB,eAAe,CAAC,EAAE,OAAO,CAAC;IAC1B,eAAe,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IAC1C,qBAAqB,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IAChD,cAAc,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IACxC,iBAAiB,EAAE,gBAAgB,EAAE,CAAC;CACvC,SAyOA,CAAC"}
|
@@ -120,9 +120,9 @@ export const traverseFields = ({ dataFrom, emptyOnly, fields, localizedParent, s
|
|
120
120
|
break;
|
121
121
|
case 'text':
|
122
122
|
case 'textarea':
|
123
|
-
if (field.custom && typeof field.custom === 'object' && field.custom.translatorSkip)
|
124
|
-
if (!field.localized ||
|
125
|
-
if (emptyOnly && siblingDataTranslated[field.name])
|
123
|
+
if (field.custom && typeof field.custom === 'object' && field.custom.translatorSkip) break;
|
124
|
+
if (!(field.localized || localizedParent) || isEmpty(siblingDataFrom[field.name])) break;
|
125
|
+
if (emptyOnly && siblingDataTranslated[field.name]) break;
|
126
126
|
// do not translate the block ID or admin-facing label
|
127
127
|
if (field.name === 'blockName' || field.name === 'id') {
|
128
128
|
break;
|
@@ -135,8 +135,8 @@ export const traverseFields = ({ dataFrom, emptyOnly, fields, localizedParent, s
|
|
135
135
|
});
|
136
136
|
break;
|
137
137
|
case 'richText':
|
138
|
-
if (!field.localized
|
139
|
-
if (emptyOnly && siblingDataTranslated[field.name])
|
138
|
+
if (!(field.localized || localizedParent) || isEmpty(siblingDataFrom[field.name])) break;
|
139
|
+
if (emptyOnly && siblingDataTranslated[field.name]) break;
|
140
140
|
const richTextDataFrom = siblingDataFrom[field.name];
|
141
141
|
siblingDataTranslated[field.name] = richTextDataFrom;
|
142
142
|
if (!richTextDataFrom) break;
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"sources":["../../src/translate/traverseFields.ts"],"sourcesContent":["import ObjectID from 'bson-objectid';\nimport { type Field, tabHasName } from 'payload/types';\n\nimport { isEmpty } from '../utils/isEmpty';\nimport { traverseRichText } from './traverseRichText';\nimport type { ValueToTranslate } from './types';\n\nexport const traverseFields = ({\n dataFrom,\n emptyOnly,\n fields,\n localizedParent,\n siblingDataFrom,\n siblingDataTranslated,\n translatedData,\n valuesToTranslate,\n}: {\n dataFrom: Record<string, unknown>;\n emptyOnly?: boolean;\n fields: Field[];\n localizedParent?: boolean;\n siblingDataFrom?: Record<string, unknown>;\n siblingDataTranslated?: Record<string, unknown>;\n translatedData: Record<string, unknown>;\n valuesToTranslate: ValueToTranslate[];\n}) => {\n siblingDataFrom = siblingDataFrom ?? dataFrom;\n siblingDataTranslated = siblingDataTranslated ?? translatedData;\n\n fields.forEach((field) => {\n switch (field.type) {\n case 'tabs':\n field.tabs.forEach((tab) => {\n const hasName = tabHasName(tab);\n\n const tabDataFrom = hasName\n ? (siblingDataFrom[tab.name] as Record<string, unknown>)\n : siblingDataFrom;\n\n if (!tabDataFrom) return;\n\n const tabDataTranslated = hasName\n ? (siblingDataTranslated[tab.name] as Record<string, unknown>) ?? {}\n : siblingDataTranslated;\n\n traverseFields({\n dataFrom,\n emptyOnly,\n fields: tab.fields,\n localizedParent: tab.localized,\n siblingDataFrom: tabDataFrom,\n siblingDataTranslated: tabDataTranslated,\n translatedData,\n valuesToTranslate,\n });\n });\n\n break;\n\n case 'group':\n const groupDataFrom = siblingDataFrom[field.name] as Record<string, unknown>;\n\n if (!groupDataFrom) break;\n\n const groupDataTranslated =\n (siblingDataTranslated[field.name] as Record<string, unknown>) ?? {};\n\n traverseFields({\n dataFrom,\n emptyOnly,\n fields: field.fields,\n localizedParent: field.localized,\n siblingDataFrom: groupDataFrom,\n siblingDataTranslated: groupDataTranslated,\n translatedData,\n valuesToTranslate,\n });\n\n break;\n\n case 'array':\n const arrayDataFrom = siblingDataFrom[field.name] as {\n id: string;\n }[];\n\n if (isEmpty(arrayDataFrom)) break;\n\n let arrayDataTranslated =\n (siblingDataTranslated[field.name] as { id: string }[] | undefined) ?? [];\n\n if (field.localized || localizedParent) {\n if (arrayDataTranslated.length > 0 && emptyOnly) break;\n\n arrayDataTranslated = arrayDataFrom.map(() => ({\n id: ObjectID().toHexString(),\n }));\n }\n\n arrayDataTranslated.forEach((item, index) => {\n traverseFields({\n dataFrom,\n emptyOnly,\n fields: field.fields,\n localizedParent: localizedParent ?? field.localized,\n siblingDataFrom: arrayDataFrom[index],\n siblingDataTranslated: item,\n translatedData,\n valuesToTranslate,\n });\n });\n\n siblingDataTranslated[field.name] = arrayDataTranslated;\n\n break;\n\n case 'blocks':\n const blocksDataFrom = siblingDataFrom[field.name] as { blockType: string; id: string }[];\n\n if (isEmpty(blocksDataFrom)) break;\n\n let blocksDataTranslated =\n (siblingDataTranslated[field.name] as { blockType: string; id: string }[] | undefined) ??\n [];\n\n if (field.localized || localizedParent) {\n if (blocksDataTranslated.length > 0 && emptyOnly) break;\n\n blocksDataTranslated = blocksDataFrom.map(({ blockType }) => ({\n blockType,\n id: ObjectID().toHexString(),\n }));\n }\n\n blocksDataTranslated.forEach((item, index) => {\n const block = field.blocks.find((each) => each.slug === item.blockType);\n\n if (!block) return;\n\n traverseFields({\n dataFrom,\n emptyOnly,\n fields: block.fields,\n localizedParent: localizedParent ?? field.localized,\n siblingDataFrom: blocksDataFrom[index],\n siblingDataTranslated: item,\n translatedData,\n valuesToTranslate,\n });\n });\n\n siblingDataTranslated[field.name] = blocksDataTranslated;\n\n break;\n\n case 'collapsible':\n case 'row':\n traverseFields({\n dataFrom,\n emptyOnly,\n fields: field.fields,\n localizedParent,\n siblingDataFrom,\n siblingDataTranslated,\n translatedData,\n valuesToTranslate,\n });\n break;\n\n // long ass cases here we have\n case 'date':\n case 'checkbox':\n case 'json':\n case 'code':\n case 'email':\n case 'number':\n case 'point':\n case 'radio':\n case 'relationship':\n case 'select':\n case 'upload':\n siblingDataTranslated[field.name] = siblingDataFrom[field.name];\n\n break;\n\n case 'text':\n case 'textarea':\n if (field.custom && typeof field.custom === 'object' && field.custom.translatorSkip) return;\n\n if (!field.localized || !localizedParent || isEmpty(siblingDataFrom[field.name])) return;\n if (emptyOnly && siblingDataTranslated[field.name]) return;\n\n // do not translate the block ID or admin-facing label\n if (field.name === 'blockName' || field.name === 'id') {\n break;\n }\n\n valuesToTranslate.push({\n onTranslate: (translated: string) => {\n siblingDataTranslated[field.name] = translated;\n },\n value: siblingDataFrom[field.name],\n });\n break;\n\n case 'richText':\n if (!field.localized && !localizedParent && isEmpty(siblingDataFrom[field.name])) break;\n if (emptyOnly && siblingDataTranslated[field.name]) return;\n const richTextDataFrom = siblingDataFrom[field.name] as object;\n\n siblingDataTranslated[field.name] = richTextDataFrom;\n\n if (!richTextDataFrom) break;\n\n const isSlate = Array.isArray(richTextDataFrom);\n\n const isLexical = 'root' in richTextDataFrom;\n\n if (!isSlate && !isLexical) break;\n\n if (isLexical) {\n const root = (siblingDataTranslated[field.name] as Record<string, unknown>)\n ?.root as Record<string, unknown>;\n\n if (root)\n traverseRichText({\n onText: (siblingData) => {\n valuesToTranslate.push({\n onTranslate: (translated: string) => {\n siblingData.text = translated;\n },\n value: siblingData.text,\n });\n },\n root,\n });\n } else {\n for (const root of siblingDataTranslated[field.name] as unknown[]) {\n traverseRichText({\n onText: (siblingData) => {\n valuesToTranslate.push({\n onTranslate: (translated: string) => {\n siblingData.text = translated;\n },\n value: siblingData.text,\n });\n },\n root: root as Record<string, unknown>,\n });\n }\n }\n\n break;\n\n default:\n break;\n }\n });\n};\n"],"names":["ObjectID","tabHasName","isEmpty","traverseRichText","traverseFields","dataFrom","emptyOnly","fields","localizedParent","siblingDataFrom","siblingDataTranslated","translatedData","valuesToTranslate","forEach","field","type","tabs","tab","hasName","tabDataFrom","name","tabDataTranslated","localized","groupDataFrom","groupDataTranslated","arrayDataFrom","arrayDataTranslated","length","map","id","toHexString","item","index","blocksDataFrom","blocksDataTranslated","blockType","block","blocks","find","each","slug","custom","translatorSkip","push","onTranslate","translated","value","richTextDataFrom","isSlate","Array","isArray","isLexical","root","onText","siblingData","text"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":"AAAA,OAAOA,cAAc,gBAAgB;AACrC,SA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D,MAAM2B,mBAAmBtC,eAAe,CAACK,MAAMM,IAAI,CAAC;gBAEpDV,qBAAqB,CAACI,MAAMM,IAAI,CAAC,GAAG2B;gBAEpC,IAAI,CAACA,kBAAkB;gBAEvB,MAAMC,UAAUC,MAAMC,OAAO,CAACH;gBAE9B,MAAMI,YAAY,UAAUJ;gBAE5B,IAAI,CAACC,WAAW,CAACG,WAAW;gBAE5B,IAAIA,WAAW;oBACb,MAAMC,OAAQ1C,qBAAqB,CAACI,MAAMM,IAAI,CAAC,EAC3CgC;oBAEJ,IAAIA,MACFjD,iBAAiB;wBACfkD,QAAQ,CAACC;4BACP1C,kBAAkB+B,IAAI,CAAC;gCACrBC,aAAa,CAACC;oCACZS,YAAYC,IAAI,GAAGV;gCACrB;gCACAC,OAAOQ,YAAYC,IAAI;4BACzB;wBACF;wBACAH;oBACF;gBACJ,OAAO;oBACL,KAAK,MAAMA,QAAQ1C,qBAAqB,CAACI,MAAMM,IAAI,CAAC,CAAe;wBACjEjB,iBAAiB;4BACfkD,QAAQ,CAACC;gCACP1C,kBAAkB+B,IAAI,CAAC;oCACrBC,aAAa,CAACC;wCACZS,YAAYC,IAAI,GAAGV;oCACrB;oCACAC,OAAOQ,YAAYC,IAAI;gCACzB;4BACF;4BACAH,MAAMA;wBACR;oBACF;gBACF;gBAEA;YAEF;gBACE;QACJ;IACF;AACF,EAAE"}
|
1
|
+
{"version":3,"sources":["../../src/translate/traverseFields.ts"],"sourcesContent":["import ObjectID from 'bson-objectid';\nimport { type Field, tabHasName } from 'payload/types';\n\nimport { isEmpty } from '../utils/isEmpty';\nimport { traverseRichText } from './traverseRichText';\nimport type { ValueToTranslate } from './types';\n\nexport const traverseFields = ({\n dataFrom,\n emptyOnly,\n fields,\n localizedParent,\n siblingDataFrom,\n siblingDataTranslated,\n translatedData,\n valuesToTranslate,\n}: {\n dataFrom: Record<string, unknown>;\n emptyOnly?: boolean;\n fields: Field[];\n localizedParent?: boolean;\n siblingDataFrom?: Record<string, unknown>;\n siblingDataTranslated?: Record<string, unknown>;\n translatedData: Record<string, unknown>;\n valuesToTranslate: ValueToTranslate[];\n}) => {\n siblingDataFrom = siblingDataFrom ?? dataFrom;\n siblingDataTranslated = siblingDataTranslated ?? translatedData;\n\n fields.forEach((field) => {\n switch (field.type) {\n case 'tabs':\n field.tabs.forEach((tab) => {\n const hasName = tabHasName(tab);\n\n const tabDataFrom = hasName\n ? (siblingDataFrom[tab.name] as Record<string, unknown>)\n : siblingDataFrom;\n\n if (!tabDataFrom) return;\n\n const tabDataTranslated = hasName\n ? (siblingDataTranslated[tab.name] as Record<string, unknown>) ?? {}\n : siblingDataTranslated;\n\n traverseFields({\n dataFrom,\n emptyOnly,\n fields: tab.fields,\n localizedParent: tab.localized,\n siblingDataFrom: tabDataFrom,\n siblingDataTranslated: tabDataTranslated,\n translatedData,\n valuesToTranslate,\n });\n });\n\n break;\n\n case 'group':\n const groupDataFrom = siblingDataFrom[field.name] as Record<string, unknown>;\n\n if (!groupDataFrom) break;\n\n const groupDataTranslated =\n (siblingDataTranslated[field.name] as Record<string, unknown>) ?? {};\n\n traverseFields({\n dataFrom,\n emptyOnly,\n fields: field.fields,\n localizedParent: field.localized,\n siblingDataFrom: groupDataFrom,\n siblingDataTranslated: groupDataTranslated,\n translatedData,\n valuesToTranslate,\n });\n\n break;\n\n case 'array':\n const arrayDataFrom = siblingDataFrom[field.name] as {\n id: string;\n }[];\n\n if (isEmpty(arrayDataFrom)) break;\n\n let arrayDataTranslated =\n (siblingDataTranslated[field.name] as { id: string }[] | undefined) ?? [];\n\n if (field.localized || localizedParent) {\n if (arrayDataTranslated.length > 0 && emptyOnly) break;\n\n arrayDataTranslated = arrayDataFrom.map(() => ({\n id: ObjectID().toHexString(),\n }));\n }\n\n arrayDataTranslated.forEach((item, index) => {\n traverseFields({\n dataFrom,\n emptyOnly,\n fields: field.fields,\n localizedParent: localizedParent ?? field.localized,\n siblingDataFrom: arrayDataFrom[index],\n siblingDataTranslated: item,\n translatedData,\n valuesToTranslate,\n });\n });\n\n siblingDataTranslated[field.name] = arrayDataTranslated;\n\n break;\n\n case 'blocks':\n const blocksDataFrom = siblingDataFrom[field.name] as { blockType: string; id: string }[];\n\n if (isEmpty(blocksDataFrom)) break;\n\n let blocksDataTranslated =\n (siblingDataTranslated[field.name] as { blockType: string; id: string }[] | undefined) ??\n [];\n\n if (field.localized || localizedParent) {\n if (blocksDataTranslated.length > 0 && emptyOnly) break;\n\n blocksDataTranslated = blocksDataFrom.map(({ blockType }) => ({\n blockType,\n id: ObjectID().toHexString(),\n }));\n }\n\n blocksDataTranslated.forEach((item, index) => {\n const block = field.blocks.find((each) => each.slug === item.blockType);\n\n if (!block) return;\n\n traverseFields({\n dataFrom,\n emptyOnly,\n fields: block.fields,\n localizedParent: localizedParent ?? field.localized,\n siblingDataFrom: blocksDataFrom[index],\n siblingDataTranslated: item,\n translatedData,\n valuesToTranslate,\n });\n });\n\n siblingDataTranslated[field.name] = blocksDataTranslated;\n\n break;\n\n case 'collapsible':\n case 'row':\n traverseFields({\n dataFrom,\n emptyOnly,\n fields: field.fields,\n localizedParent,\n siblingDataFrom,\n siblingDataTranslated,\n translatedData,\n valuesToTranslate,\n });\n break;\n\n // long ass cases here we have\n case 'date':\n case 'checkbox':\n case 'json':\n case 'code':\n case 'email':\n case 'number':\n case 'point':\n case 'radio':\n case 'relationship':\n case 'select':\n case 'upload':\n siblingDataTranslated[field.name] = siblingDataFrom[field.name];\n\n break;\n\n case 'text':\n case 'textarea':\n if (field.custom && typeof field.custom === 'object' && field.custom.translatorSkip) break;\n\n if (!(field.localized || localizedParent) || isEmpty(siblingDataFrom[field.name])) break;\n if (emptyOnly && siblingDataTranslated[field.name]) break;\n\n // do not translate the block ID or admin-facing label\n if (field.name === 'blockName' || field.name === 'id') {\n break;\n }\n\n valuesToTranslate.push({\n onTranslate: (translated: string) => {\n siblingDataTranslated[field.name] = translated;\n },\n value: siblingDataFrom[field.name],\n });\n break;\n\n case 'richText':\n if (!(field.localized || localizedParent) || isEmpty(siblingDataFrom[field.name])) break;\n if (emptyOnly && siblingDataTranslated[field.name]) break;\n\n const richTextDataFrom = siblingDataFrom[field.name] as object;\n\n siblingDataTranslated[field.name] = richTextDataFrom;\n\n if (!richTextDataFrom) break;\n\n const isSlate = Array.isArray(richTextDataFrom);\n\n const isLexical = 'root' in richTextDataFrom;\n\n if (!isSlate && !isLexical) break;\n\n if (isLexical) {\n const root = (siblingDataTranslated[field.name] as Record<string, unknown>)\n ?.root as Record<string, unknown>;\n\n if (root)\n traverseRichText({\n onText: (siblingData) => {\n valuesToTranslate.push({\n onTranslate: (translated: string) => {\n siblingData.text = translated;\n },\n value: siblingData.text,\n });\n },\n root,\n });\n } else {\n for (const root of siblingDataTranslated[field.name] as unknown[]) {\n traverseRichText({\n onText: (siblingData) => {\n valuesToTranslate.push({\n onTranslate: (translated: string) => {\n siblingData.text = translated;\n },\n value: siblingData.text,\n });\n },\n root: root as Record<string, unknown>,\n });\n }\n }\n\n break;\n\n default:\n break;\n }\n });\n};\n"],"names":["ObjectID","tabHasName","isEmpty","traverseRichText","traverseFields","dataFrom","emptyOnly","fields","localizedParent","siblingDataFrom","siblingDataTranslated","translatedData","valuesToTranslate","forEach","field","type","tabs","tab","hasName","tabDataFrom","name","tabDataTranslated","localized","groupDataFrom","groupDataTranslated","arrayDataFrom","arrayDataTranslated","length","map","id","toHexString","item","index","blocksDataFrom","blocksDataTranslated","blockType","block","blocks","find","each","slug","custom","translatorSkip","push","onTranslate","translated","value","richTextDataFrom","isSlate","Array","isArray","isLexical","root","onText","siblingData","text"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":"AAAA,OAAOA,cAAc,gBA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,IAAI,CAAC,EAAE;gBAEpD,MAAM2B,mBAAmBtC,eAAe,CAACK,MAAMM,IAAI,CAAC;gBAEpDV,qBAAqB,CAACI,MAAMM,IAAI,CAAC,GAAG2B;gBAEpC,IAAI,CAACA,kBAAkB;gBAEvB,MAAMC,UAAUC,MAAMC,OAAO,CAACH;gBAE9B,MAAMI,YAAY,UAAUJ;gBAE5B,IAAI,CAACC,WAAW,CAACG,WAAW;gBAE5B,IAAIA,WAAW;oBACb,MAAMC,OAAQ1C,qBAAqB,CAACI,MAAMM,IAAI,CAAC,EAC3CgC;oBAEJ,IAAIA,MACFjD,iBAAiB;wBACfkD,QAAQ,CAACC;4BACP1C,kBAAkB+B,IAAI,CAAC;gCACrBC,aAAa,CAACC;oCACZS,YAAYC,IAAI,GAAGV;gCACrB;gCACAC,OAAOQ,YAAYC,IAAI;4BACzB;wBACF;wBACAH;oBACF;gBACJ,OAAO;oBACL,KAAK,MAAMA,QAAQ1C,qBAAqB,CAACI,MAAMM,IAAI,CAAC,CAAe;wBACjEjB,iBAAiB;4BACfkD,QAAQ,CAACC;gCACP1C,kBAAkB+B,IAAI,CAAC;oCACrBC,aAAa,CAACC;wCACZS,YAAYC,IAAI,GAAGV;oCACrB;oCACAC,OAAOQ,YAAYC,IAAI;gCACzB;4BACF;4BACAH,MAAMA;wBACR;oBACF;gBACF;gBAEA;YAEF;gBACE;QACJ;IACF;AACF,EAAE"}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"traverseRichText.d.ts","sourceRoot":"","sources":["../../src/translate/traverseRichText.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,gBAAgB,mCAI1B;IACD,MAAM,EAAE,CAAC,WAAW,EAAE,
|
1
|
+
{"version":3,"file":"traverseRichText.d.ts","sourceRoot":"","sources":["../../src/translate/traverseRichText.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,gBAAgB,mCAI1B;IACD,MAAM,EAAE,CAAC,WAAW,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,KAAK,IAAI,CAAC;IACvD,IAAI,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IAC9B,WAAW,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;CACvC,SAgBA,CAAC"}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"updateEntity.d.ts","sourceRoot":"","sources":["../../src/translate/updateEntity.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,cAAc,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAEhE,KAAK,IAAI,GAAG;IACV,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,IAAI,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC;IAC1B,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,EAAE,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;IACrB,MAAM,EAAE,MAAM,CAAC;IACf,cAAc,CAAC,EAAE,OAAO,CAAC;IACzB,GAAG,EAAE,cAAc,CAAC;CACrB,CAAC;AAEF,eAAO,MAAM,YAAY,iGAStB,IAAI,KAAG,
|
1
|
+
{"version":3,"file":"updateEntity.d.ts","sourceRoot":"","sources":["../../src/translate/updateEntity.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,cAAc,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAEhE,KAAK,IAAI,GAAG;IACV,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,IAAI,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC;IAC1B,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,EAAE,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;IACrB,MAAM,EAAE,MAAM,CAAC;IACf,cAAc,CAAC,EAAE,OAAO,CAAC;IACzB,GAAG,EAAE,cAAc,CAAC;CACrB,CAAC;AAEF,eAAO,MAAM,YAAY,iGAStB,IAAI,KAAG,OAAO,CAAC,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,UAAU,CA6BrD,CAAC"}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"chunkArray.d.ts","sourceRoot":"","sources":["../../src/utils/chunkArray.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,UAAU,
|
1
|
+
{"version":3,"file":"chunkArray.d.ts","sourceRoot":"","sources":["../../src/utils/chunkArray.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,UAAU,GAAI,CAAC,SAAS,CAAC,EAAE,UAAU,MAAM,KAAG,CAAC,EAAE,EAI7D,CAAC"}
|