@focus-reactive/payload-plugin-translator 0.1.3 → 0.1.5
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 +6 -3
- package/dist/client/app/cache/CacheProvider.d.ts +1 -2
- package/dist/client/app/cache/CacheProvider.export.d.ts +0 -1
- package/dist/client/app/config/TranslateKitConfigContext.d.ts +1 -2
- package/dist/client/app/config/index.d.ts +0 -1
- package/dist/client/entities/translation/api/mutations/useCancelCollectionTranslations.d.ts +0 -1
- package/dist/client/entities/translation/api/mutations/useCancelDocumentTranslation.d.ts +0 -1
- package/dist/client/entities/translation/api/mutations/useQueueDocumentTranslation.d.ts +0 -1
- package/dist/client/entities/translation/api/mutations/useQueueDocumentTranslations.d.ts +0 -1
- package/dist/client/entities/translation/api/mutations/useRunDocumentTranslation.d.ts +0 -1
- package/dist/client/entities/translation/api/queries/useCollectionTranslationStatus.d.ts +7 -72
- package/dist/client/entities/translation/api/queries/useDocumentTranslation.d.ts +7 -72
- package/dist/client/entities/translation/index.d.ts +0 -1
- package/dist/client/entities/translation/model/enums.d.ts +0 -1
- package/dist/client/entities/translation/model/enums.js +3 -3
- package/dist/client/entities/translation/model/types.d.ts +0 -1
- package/dist/client/entities/translation/ui/CompletedTranslationStatus/CompletedTranslationStatus.d.ts +1 -2
- package/dist/client/entities/translation/ui/CompletedTranslationStatus/index.d.ts +0 -1
- package/dist/client/entities/translation/ui/FailedTranslationStatus/FailedTranslationStatus.d.ts +1 -2
- package/dist/client/entities/translation/ui/FailedTranslationStatus/index.d.ts +0 -1
- package/dist/client/entities/translation/ui/PendingTranslationStatus/PendingTranslationStatus.d.ts +1 -2
- package/dist/client/entities/translation/ui/PendingTranslationStatus/index.d.ts +0 -1
- package/dist/client/entities/translation/ui/RunningTranslationStatus/RunningTranslationStatus.d.ts +1 -2
- package/dist/client/entities/translation/ui/RunningTranslationStatus/index.d.ts +0 -1
- package/dist/client/entities/translation/ui/TranslationDirection/TranslationDirection.d.ts +1 -2
- package/dist/client/entities/translation/ui/TranslationDirection/index.d.ts +0 -1
- package/dist/client/features/collection-translation-form/index.client.d.ts +0 -1
- package/dist/client/features/collection-translation-form/index.d.ts +0 -1
- package/dist/client/features/collection-translation-form/model/constants.d.ts +0 -1
- package/dist/client/features/collection-translation-form/model/form-model.d.ts +0 -1
- package/dist/client/features/collection-translation-form/model/index.d.ts +0 -1
- package/dist/client/features/collection-translation-form/model/schema.d.ts +0 -1
- package/dist/client/features/collection-translation-form/ui/CollectionTranslationForm.d.ts +1 -2
- package/dist/client/features/collection-translation-form/ui/index.d.ts +0 -1
- package/dist/client/features/collection-translation-popup/index.d.ts +0 -1
- package/dist/client/features/collection-translation-popup/ui/CollectionTranslationPopup.d.ts +1 -2
- package/dist/client/features/collection-translation-progress/index.d.ts +0 -1
- package/dist/client/features/collection-translation-progress/ui/CollectionTranslationProgress.d.ts +1 -2
- package/dist/client/features/document-translation-progress-failed/index.d.ts +0 -1
- package/dist/client/features/document-translation-progress-failed/ui/DocumentTranslationProgressFailed.d.ts +1 -2
- package/dist/client/features/document-translation-progress-pending/index.d.ts +0 -1
- package/dist/client/features/document-translation-progress-pending/ui/DocumentTranslationProgressPending.d.ts +1 -2
- package/dist/client/features/document-translation-progress-running/index.d.ts +0 -1
- package/dist/client/features/document-translation-progress-running/ui/DocumentTranslationProgressRunning.d.ts +1 -2
- package/dist/client/features/open-document-translation-popup/index.d.ts +0 -1
- package/dist/client/features/open-document-translation-popup/ui/OpenDocumentTranslationPopup.d.ts +1 -2
- package/dist/client/features/translate-document-form/index.client.d.ts +0 -1
- package/dist/client/features/translate-document-form/index.d.ts +0 -1
- package/dist/client/features/translate-document-form/model/constants.d.ts +0 -1
- package/dist/client/features/translate-document-form/model/form-model.d.ts +0 -1
- package/dist/client/features/translate-document-form/model/index.d.ts +0 -1
- package/dist/client/features/translate-document-form/model/schema.d.ts +0 -1
- package/dist/client/features/translate-document-form/ui/DocumentTranslationForm.d.ts +1 -2
- package/dist/client/features/translate-document-form/ui/index.d.ts +0 -1
- package/dist/client/shared/lib/assets/icons/LanguageTranslateIcon.d.ts +1 -2
- package/dist/client/shared/lib/assets/icons/QuestionCircleIcon.d.ts +1 -2
- package/dist/client/shared/lib/assets/icons/ReloadIcon.d.ts +1 -2
- package/dist/client/shared/lib/errors/handleApiError.d.ts +0 -1
- package/dist/client/shared/lib/errors/handleApiError.js +3 -1
- package/dist/client/shared/lib/forms/handle-form-error.d.ts +0 -1
- package/dist/client/shared/lib/payload/hooks/useCollectionDashboardUrlParams.d.ts +0 -1
- package/dist/client/shared/lib/payload/hooks/useCollectionDocumentUrlParams.d.ts +0 -1
- package/dist/client/shared/lib/payload/hooks/useLocaleOptions.d.ts +0 -1
- package/dist/client/shared/lib/utils/errors/handleApiError.d.ts +0 -1
- package/dist/client/shared/lib/utils/errors/handleApiError.js +3 -1
- package/dist/client/shared/lib/utils/react/useToggle.d.ts +0 -1
- package/dist/client/shared/providers/CacheClientProvider/CacheClientProvider.factory.d.ts +0 -1
- package/dist/client/shared/providers/CacheClientProvider/index.d.ts +0 -1
- package/dist/client/shared/types/AccessGuard.d.ts +0 -1
- package/dist/client/shared/types/PayloadComponentExport.d.ts +0 -1
- package/dist/client/shared/ui/Alert/Alert.d.ts +0 -1
- package/dist/client/shared/ui/Alert/index.d.ts +0 -1
- package/dist/client/shared/ui/Button/Button.d.ts +0 -1
- package/dist/client/shared/ui/Button/index.d.ts +0 -1
- package/dist/client/shared/ui/Checkbox/Checkbox.d.ts +0 -1
- package/dist/client/shared/ui/Checkbox/index.d.ts +0 -1
- package/dist/client/shared/ui/ColorIndicator/ColorIndicator.d.ts +1 -2
- package/dist/client/shared/ui/ColorIndicator/index.d.ts +0 -1
- package/dist/client/shared/ui/Description/Description.d.ts +1 -2
- package/dist/client/shared/ui/Description/index.d.ts +0 -1
- package/dist/client/shared/ui/Divider/Divider.d.ts +0 -1
- package/dist/client/shared/ui/Divider/index.d.ts +0 -1
- package/dist/client/shared/ui/Label/Label.d.ts +0 -1
- package/dist/client/shared/ui/Label/index.d.ts +0 -1
- package/dist/client/shared/ui/Loading/Loading.d.ts +1 -2
- package/dist/client/shared/ui/Loading/index.d.ts +0 -1
- package/dist/client/shared/ui/Popup/Popup.d.ts +1 -2
- package/dist/client/shared/ui/Popup/index.d.ts +0 -1
- package/dist/client/shared/ui/ProgressBar/ProgressBar.d.ts +1 -2
- package/dist/client/shared/ui/ProgressBar/index.d.ts +0 -1
- package/dist/client/shared/ui/Select/Select.d.ts +2 -3
- package/dist/client/shared/ui/Select/index.d.ts +0 -1
- package/dist/client/shared/ui/StatusCounter/StatusCounter.d.ts +1 -2
- package/dist/client/shared/ui/StatusCounter/index.d.ts +0 -1
- package/dist/client/shared/ui/StatusIndicator/StatusIndicator.d.ts +1 -2
- package/dist/client/shared/ui/StatusIndicator/index.d.ts +0 -1
- package/dist/client/shared/ui/Tooltip/Tooltip.d.ts +1 -2
- package/dist/client/shared/ui/Tooltip/index.d.ts +0 -1
- package/dist/client/shared/ui/form/FormCheckbox/FormCheckbox.d.ts +1 -2
- package/dist/client/shared/ui/form/FormCheckbox/index.d.ts +0 -1
- package/dist/client/shared/ui/form/FormCheckboxPublish/FormCheckboxPublish.d.ts +1 -2
- package/dist/client/shared/ui/form/FormCheckboxPublish/index.d.ts +0 -1
- package/dist/client/shared/ui/form/FormSelect/FormSelect.d.ts +1 -2
- package/dist/client/shared/ui/form/FormSelect/index.d.ts +0 -1
- package/dist/client/shared/ui/form/FormSelectLocale/FormSelectLocale.d.ts +1 -2
- package/dist/client/shared/ui/form/FormSelectLocale/index.d.ts +0 -1
- package/dist/client/shared/ui/form/FormSelectStrategy/FormSelectStrategy.d.ts +1 -2
- package/dist/client/shared/ui/form/FormSelectStrategy/index.d.ts +0 -1
- package/dist/client/shared/utils/componentPath.d.ts +0 -1
- package/dist/client/widgets/bulk-translation-dashboard/index.d.ts +0 -1
- package/dist/client/widgets/bulk-translation-dashboard/ui/BulkTranslationDashboard.d.ts +1 -2
- package/dist/client/widgets/bulk-translation-dashboard/ui/BulkTranslationDashboard.export.d.ts +0 -1
- package/dist/client/widgets/bulk-translation-dashboard/ui/BulkTranslationDashboard.export.js +2 -1
- package/dist/client/widgets/bulk-translation-dashboard/ui/BulkTranslationDashboard.server.d.ts +1 -2
- package/dist/client/widgets/bulk-translation-dashboard/ui/index.d.ts +0 -1
- package/dist/client/widgets/translate-document/index.d.ts +0 -1
- package/dist/client/widgets/translate-document/ui/TranslateDocument.d.ts +1 -2
- package/dist/client/widgets/translate-document/ui/TranslateDocument.export.d.ts +0 -1
- package/dist/client/widgets/translate-document/ui/TranslateDocument.export.js +2 -1
- package/dist/client/widgets/translate-document/ui/TranslateDocument.server.d.ts +1 -2
- package/dist/client/widgets/translate-document/ui/index.d.ts +0 -1
- package/dist/field-config.d.ts +0 -1
- package/dist/index.d.ts +0 -1
- package/dist/plugin.d.ts +0 -1
- package/dist/plugin.js +7 -3
- package/dist/server/features/_lib/collection-utils.d.ts +0 -1
- package/dist/server/features/_lib/index.d.ts +0 -1
- package/dist/server/features/cancel/handler.d.ts +0 -1
- package/dist/server/features/cancel/index.d.ts +0 -1
- package/dist/server/features/cancel/model.d.ts +0 -1
- package/dist/server/features/cancel/route.d.ts +0 -1
- package/dist/server/features/cancel-by-collection/handler.d.ts +0 -1
- package/dist/server/features/cancel-by-collection/index.d.ts +0 -1
- package/dist/server/features/cancel-by-collection/model.d.ts +0 -1
- package/dist/server/features/cancel-by-collection/route.d.ts +0 -1
- package/dist/server/features/enqueue-translation/handler.d.ts +0 -1
- package/dist/server/features/enqueue-translation/index.d.ts +0 -1
- package/dist/server/features/enqueue-translation/model.d.ts +0 -1
- package/dist/server/features/enqueue-translation/route.d.ts +0 -1
- package/dist/server/features/get-collection-status/handler.d.ts +0 -1
- package/dist/server/features/get-collection-status/index.d.ts +0 -1
- package/dist/server/features/get-collection-status/model.d.ts +0 -1
- package/dist/server/features/get-collection-status/route.d.ts +0 -1
- package/dist/server/features/get-document-status/handler.d.ts +0 -1
- package/dist/server/features/get-document-status/index.d.ts +0 -1
- package/dist/server/features/get-document-status/model.d.ts +0 -1
- package/dist/server/features/get-document-status/route.d.ts +0 -1
- package/dist/server/features/index.d.ts +0 -1
- package/dist/server/features/run-translation/handler.d.ts +0 -1
- package/dist/server/features/run-translation/index.d.ts +0 -1
- package/dist/server/features/run-translation/model.d.ts +0 -1
- package/dist/server/features/run-translation/route.d.ts +0 -1
- package/dist/server/features/translate-document/handler.d.ts +0 -1
- package/dist/server/features/translate-document/handler.js +4 -2
- package/dist/server/features/translate-document/index.d.ts +0 -1
- package/dist/server/features/translate-document/model.d.ts +0 -1
- package/dist/server/features/translate-document/task.d.ts +0 -1
- package/dist/server/index.d.ts +0 -1
- package/dist/server/modules/index.d.ts +0 -1
- package/dist/server/modules/task-runner/TaskRunner.interface.d.ts +0 -1
- package/dist/server/modules/task-runner/TaskRunnerProvider.interface.d.ts +3 -4
- package/dist/server/modules/task-runner/index.d.ts +0 -1
- package/dist/server/modules/task-runner/payload-jobs-runner/PayloadJobsRunnerProvider.d.ts +1 -2
- package/dist/server/modules/task-runner/payload-jobs-runner/PayloadJobsTaskRunner.d.ts +0 -1
- package/dist/server/modules/task-runner/payload-jobs-runner/index.d.ts +0 -1
- package/dist/server/modules/task-runner/payload-jobs-runner/normalizeJob.d.ts +0 -1
- package/dist/server/modules/task-runner/payload-jobs-runner/types.d.ts +0 -1
- package/dist/server/modules/task-runner/sync-runner/SyncRunnerProvider.d.ts +0 -1
- package/dist/server/modules/task-runner/sync-runner/SyncTaskRunner.d.ts +0 -1
- package/dist/server/modules/task-runner/sync-runner/index.d.ts +0 -1
- package/dist/server/modules/task-runner/sync-runner/types.d.ts +0 -1
- package/dist/server/modules/task-runner/types.d.ts +0 -1
- package/dist/server/modules/translation-pipeline/TranslationPipeline.d.ts +0 -1
- package/dist/server/modules/translation-pipeline/index.d.ts +0 -1
- package/dist/server/modules/translation-pipeline/stages/data-reconciler/DataReconciler.d.ts +0 -1
- package/dist/server/modules/translation-pipeline/stages/data-reconciler/DataReconciler.stage.d.ts +0 -1
- package/dist/server/modules/translation-pipeline/stages/data-reconciler/index.d.ts +0 -1
- package/dist/server/modules/translation-pipeline/stages/field-collector/FieldChunkCollector.d.ts +0 -1
- package/dist/server/modules/translation-pipeline/stages/field-collector/FieldChunkCollector.js +2 -1
- package/dist/server/modules/translation-pipeline/stages/field-collector/FieldChunkCollector.stage.d.ts +0 -1
- package/dist/server/modules/translation-pipeline/stages/field-collector/index.d.ts +0 -1
- package/dist/server/modules/translation-pipeline/stages/index.d.ts +0 -1
- package/dist/server/modules/translation-pipeline/stages/text-expander/PlainTextExpander.d.ts +0 -1
- package/dist/server/modules/translation-pipeline/stages/text-expander/RichTextExpander.d.ts +0 -1
- package/dist/server/modules/translation-pipeline/stages/text-expander/TextChunkExpander.d.ts +0 -1
- package/dist/server/modules/translation-pipeline/stages/text-expander/TextChunkExpander.stage.d.ts +0 -1
- package/dist/server/modules/translation-pipeline/stages/text-expander/TextExpander.interface.d.ts +0 -1
- package/dist/server/modules/translation-pipeline/stages/text-expander/index.d.ts +0 -1
- package/dist/server/modules/translation-pipeline/stages/translation/Translation.stage.d.ts +0 -1
- package/dist/server/modules/translation-pipeline/stages/translation/index.d.ts +0 -1
- package/dist/server/modules/translation-pipeline/stages/translation-applicator/TranslationMutator.d.ts +0 -1
- package/dist/server/modules/translation-pipeline/stages/translation-applicator/TranslationMutator.stage.d.ts +0 -1
- package/dist/server/modules/translation-pipeline/stages/translation-applicator/index.d.ts +0 -1
- package/dist/server/modules/translation-pipeline/strategies/Overwrite.strategy.d.ts +0 -1
- package/dist/server/modules/translation-pipeline/strategies/SkipExisting.strategy.d.ts +0 -1
- package/dist/server/modules/translation-pipeline/strategies/TranslationStrategy.interface.d.ts +0 -1
- package/dist/server/modules/translation-pipeline/strategies/index.d.ts +0 -1
- package/dist/server/modules/translation-pipeline/types/FieldChunk.d.ts +0 -1
- package/dist/server/modules/translation-pipeline/types/Pipeline.d.ts +0 -1
- package/dist/server/modules/translation-pipeline/types/PipelineContext.d.ts +0 -1
- package/dist/server/modules/translation-pipeline/types/TextChunk.d.ts +0 -1
- package/dist/server/modules/translation-pipeline/types/index.d.ts +0 -1
- package/dist/server/modules/translation-providers/OpenAITranslation.provider.d.ts +1 -2
- package/dist/server/modules/translation-providers/TranslationProvider.interface.d.ts +0 -1
- package/dist/server/modules/translation-providers/index.d.ts +0 -1
- package/dist/server/shared/access/AnyAccessGuard.d.ts +0 -1
- package/dist/server/shared/access/handler.d.ts +1 -2
- package/dist/server/shared/access/index.d.ts +0 -1
- package/dist/server/shared/access/types.d.ts +0 -1
- package/dist/server/shared/field-config/getFieldConfig.d.ts +0 -1
- package/dist/server/shared/field-config/index.d.ts +0 -1
- package/dist/server/shared/field-config/types.d.ts +0 -1
- package/dist/server/shared/guards/collection-guards.d.ts +0 -1
- package/dist/server/shared/guards/field-guards.d.ts +0 -1
- package/dist/server/shared/guards/index.d.ts +0 -1
- package/dist/server/shared/http/ServerResponse.d.ts +0 -1
- package/dist/server/shared/http/index.d.ts +0 -1
- package/dist/server/shared/http/withAccessCheck.d.ts +0 -1
- package/dist/server/shared/http/withErrorHandler.d.ts +0 -1
- package/dist/server/shared/index.d.ts +0 -1
- package/dist/server/shared/lexical/collectTextNodes.d.ts +0 -1
- package/dist/server/shared/lexical/guards.d.ts +0 -1
- package/dist/server/shared/lexical/index.d.ts +0 -1
- package/dist/server/shared/lexical/isEmptyRichText.d.ts +0 -1
- package/dist/server/shared/lexical/traverseLexicalTree.d.ts +0 -1
- package/dist/server/shared/lexical/types.d.ts +0 -1
- package/dist/server/shared/utils/LazyMap.d.ts +0 -1
- package/dist/server/shared/utils/filterLocalizedFields.d.ts +0 -1
- package/dist/server/shared/utils/getByPath.d.ts +0 -1
- package/dist/server/shared/utils/index.d.ts +0 -1
- package/dist/server/shared/utils/isEmpty.d.ts +0 -1
- package/dist/server/shared/utils/isObject.d.ts +0 -1
- package/dist/server/shared/utils/normalizePath.d.ts +0 -1
- package/dist/server/shared/utils/pipe.d.ts +0 -1
- package/dist/server/shared/utils/setByPath.d.ts +0 -1
- package/dist/types/AccessGuard.d.ts +0 -1
- package/dist/types/index.d.ts +0 -1
- package/package.json +33 -32
- package/dist/vitest-env.d.js +0 -3
|
@@ -5,6 +5,5 @@ type DocumentTranslationFormProps = {
|
|
|
5
5
|
onSubmit: (values: FormValues) => Promise<void>;
|
|
6
6
|
hasDrafts?: boolean;
|
|
7
7
|
};
|
|
8
|
-
export declare function DocumentTranslationForm({ form, onSubmit, hasDrafts }: DocumentTranslationFormProps): import("react").JSX.Element;
|
|
8
|
+
export declare function DocumentTranslationForm({ form, onSubmit, hasDrafts }: DocumentTranslationFormProps): import("react/jsx-runtime").JSX.Element;
|
|
9
9
|
export {};
|
|
10
|
-
//# sourceMappingURL=DocumentTranslationForm.d.ts.map
|
|
@@ -1,2 +1 @@
|
|
|
1
|
-
export declare const LanguageTranslateIcon: () => import("react").JSX.Element;
|
|
2
|
-
//# sourceMappingURL=LanguageTranslateIcon.d.ts.map
|
|
1
|
+
export declare const LanguageTranslateIcon: () => import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,2 +1 @@
|
|
|
1
|
-
export declare const QuestionCircleIcon: () => import("react").JSX.Element;
|
|
2
|
-
//# sourceMappingURL=QuestionCircleIcon.d.ts.map
|
|
1
|
+
export declare const QuestionCircleIcon: () => import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,2 +1 @@
|
|
|
1
|
-
export declare const ReloadIcon: () => import("react").JSX.Element;
|
|
2
|
-
//# sourceMappingURL=ReloadIcon.d.ts.map
|
|
1
|
+
export declare const ReloadIcon: () => import("react/jsx-runtime").JSX.Element;
|
|
@@ -3,7 +3,9 @@ export class NextApiError extends Error {
|
|
|
3
3
|
message;
|
|
4
4
|
details;
|
|
5
5
|
constructor(message, details){
|
|
6
|
-
super(message)
|
|
6
|
+
super(message);
|
|
7
|
+
this.message = message;
|
|
8
|
+
this.details = details;
|
|
7
9
|
}
|
|
8
10
|
}
|
|
9
11
|
export async function handleNextApiError(callback) {
|
|
@@ -3,7 +3,9 @@ export class TranslationApiError extends Error {
|
|
|
3
3
|
message;
|
|
4
4
|
details;
|
|
5
5
|
constructor(message, details){
|
|
6
|
-
super(message)
|
|
6
|
+
super(message);
|
|
7
|
+
this.message = message;
|
|
8
|
+
this.details = details;
|
|
7
9
|
}
|
|
8
10
|
}
|
|
9
11
|
export async function handleApiError(callback) {
|
|
@@ -4,4 +4,3 @@ type CheckboxProps = Omit<ComponentPropsWithRef<'input'>, 'type'> & {
|
|
|
4
4
|
};
|
|
5
5
|
declare const Checkbox: import("react").ForwardRefExoticComponent<Omit<CheckboxProps, "ref"> & import("react").RefAttributes<HTMLInputElement>>;
|
|
6
6
|
export default Checkbox;
|
|
7
|
-
//# sourceMappingURL=Checkbox.d.ts.map
|
|
@@ -4,6 +4,5 @@ type ColorIndicatorProps = {
|
|
|
4
4
|
title?: string;
|
|
5
5
|
className?: string;
|
|
6
6
|
};
|
|
7
|
-
export default function ColorIndicator({ $color, $animated, title, className }: ColorIndicatorProps): import("react").JSX.Element;
|
|
7
|
+
export default function ColorIndicator({ $color, $animated, title, className }: ColorIndicatorProps): import("react/jsx-runtime").JSX.Element;
|
|
8
8
|
export {};
|
|
9
|
-
//# sourceMappingURL=ColorIndicator.d.ts.map
|
|
@@ -3,6 +3,5 @@ type DescriptionProps = ComponentPropsWithoutRef<'div'> & {
|
|
|
3
3
|
id: string;
|
|
4
4
|
variant?: 'default' | 'error';
|
|
5
5
|
};
|
|
6
|
-
export default function Description({ children, className, id, variant, ...props }: DescriptionProps): import("react").JSX.Element;
|
|
6
|
+
export default function Description({ children, className, id, variant, ...props }: DescriptionProps): import("react/jsx-runtime").JSX.Element;
|
|
7
7
|
export {};
|
|
8
|
-
//# sourceMappingURL=Description.d.ts.map
|
|
@@ -3,6 +3,5 @@ type LoadingProps = {
|
|
|
3
3
|
className?: string;
|
|
4
4
|
size?: 'small' | 'medium';
|
|
5
5
|
};
|
|
6
|
-
declare function Loading({ text, className, size }: LoadingProps): import("react").JSX.Element;
|
|
6
|
+
declare function Loading({ text, className, size }: LoadingProps): import("react/jsx-runtime").JSX.Element;
|
|
7
7
|
export default Loading;
|
|
8
|
-
//# sourceMappingURL=Loading.d.ts.map
|
|
@@ -6,6 +6,5 @@ type PopupProps = PropsWithChildren<{
|
|
|
6
6
|
open: boolean;
|
|
7
7
|
onOpenChange: (open: boolean) => void;
|
|
8
8
|
}>;
|
|
9
|
-
declare function Popup({ open, children, onOpenChange, $trigger, $align, $side }: PopupProps): import("react").JSX.Element;
|
|
9
|
+
declare function Popup({ open, children, onOpenChange, $trigger, $align, $side }: PopupProps): import("react/jsx-runtime").JSX.Element;
|
|
10
10
|
export default Popup;
|
|
11
|
-
//# sourceMappingURL=Popup.d.ts.map
|
|
@@ -5,6 +5,5 @@ type ProgressBarProps = {
|
|
|
5
5
|
showPercentage?: boolean;
|
|
6
6
|
className?: string;
|
|
7
7
|
};
|
|
8
|
-
export default function ProgressBar({ percentage, size, color, showPercentage, className, }: ProgressBarProps): import("react").JSX.Element;
|
|
8
|
+
export default function ProgressBar({ percentage, size, color, showPercentage, className, }: ProgressBarProps): import("react/jsx-runtime").JSX.Element;
|
|
9
9
|
export {};
|
|
10
|
-
//# sourceMappingURL=ProgressBar.d.ts.map
|
|
@@ -8,8 +8,8 @@ type SelectProps = ComponentPropsWithRef<'select'> & {
|
|
|
8
8
|
};
|
|
9
9
|
type SelectOptionProps = ComponentPropsWithoutRef<'option'>;
|
|
10
10
|
type SelectEmptyOptionProps = Omit<SelectOptionProps, 'value' | 'disabled' | 'hidden'>;
|
|
11
|
-
declare const SelectOption: ({ children, ...props }: SelectOptionProps) => import("react").JSX.Element;
|
|
12
|
-
declare const SelectEmptyOption: ({ children, ...props }: SelectEmptyOptionProps) => import("react").JSX.Element;
|
|
11
|
+
declare const SelectOption: ({ children, ...props }: SelectOptionProps) => import("react/jsx-runtime").JSX.Element;
|
|
12
|
+
declare const SelectEmptyOption: ({ children, ...props }: SelectEmptyOptionProps) => import("react/jsx-runtime").JSX.Element;
|
|
13
13
|
declare const Select: import("react").ForwardRefExoticComponent<Omit<SelectProps, "ref"> & import("react").RefAttributes<HTMLSelectElement>>;
|
|
14
14
|
type SelectComponent = typeof Select & {
|
|
15
15
|
SelectOption: typeof SelectOption;
|
|
@@ -17,4 +17,3 @@ type SelectComponent = typeof Select & {
|
|
|
17
17
|
};
|
|
18
18
|
declare const _default: SelectComponent;
|
|
19
19
|
export default _default;
|
|
20
|
-
//# sourceMappingURL=Select.d.ts.map
|
|
@@ -6,6 +6,5 @@ type StatusCounterProps = {
|
|
|
6
6
|
size?: 'small' | 'medium';
|
|
7
7
|
className?: string;
|
|
8
8
|
};
|
|
9
|
-
export default function StatusCounter({ status, count, label, animated, size, className, }: StatusCounterProps): import("react").JSX.Element;
|
|
9
|
+
export default function StatusCounter({ status, count, label, animated, size, className, }: StatusCounterProps): import("react/jsx-runtime").JSX.Element;
|
|
10
10
|
export {};
|
|
11
|
-
//# sourceMappingURL=StatusCounter.d.ts.map
|
|
@@ -5,6 +5,5 @@ type StatusIndicatorProps = PropsWithChildren<{
|
|
|
5
5
|
title?: string;
|
|
6
6
|
className?: string;
|
|
7
7
|
}>;
|
|
8
|
-
export default function StatusIndicator({ $color, $animated, title, className, children }: StatusIndicatorProps): import("react").JSX.Element;
|
|
8
|
+
export default function StatusIndicator({ $color, $animated, title, className, children }: StatusIndicatorProps): import("react/jsx-runtime").JSX.Element;
|
|
9
9
|
export {};
|
|
10
|
-
//# sourceMappingURL=StatusIndicator.d.ts.map
|
|
@@ -6,6 +6,5 @@ type TooltipProps = {
|
|
|
6
6
|
sideOffset?: number;
|
|
7
7
|
delayDuration?: number;
|
|
8
8
|
};
|
|
9
|
-
export default function Tooltip({ children, content, side, sideOffset, delayDuration, }: TooltipProps): import("react").JSX.Element;
|
|
9
|
+
export default function Tooltip({ children, content, side, sideOffset, delayDuration, }: TooltipProps): import("react/jsx-runtime").JSX.Element;
|
|
10
10
|
export {};
|
|
11
|
-
//# sourceMappingURL=Tooltip.d.ts.map
|
|
@@ -6,6 +6,5 @@ type FormCheckboxProps = {
|
|
|
6
6
|
disabled?: boolean;
|
|
7
7
|
className?: string;
|
|
8
8
|
};
|
|
9
|
-
export declare function FormCheckbox({ name, label, description, disabled, className }: FormCheckboxProps): import("react").JSX.Element;
|
|
9
|
+
export declare function FormCheckbox({ name, label, description, disabled, className }: FormCheckboxProps): import("react/jsx-runtime").JSX.Element;
|
|
10
10
|
export {};
|
|
11
|
-
//# sourceMappingURL=FormCheckbox.d.ts.map
|
|
@@ -3,6 +3,5 @@ type FormCheckboxPublishProps = {
|
|
|
3
3
|
disabled?: boolean;
|
|
4
4
|
className?: string;
|
|
5
5
|
};
|
|
6
|
-
export declare function FormCheckboxPublish({ name, disabled, className }: FormCheckboxPublishProps): import("react").JSX.Element;
|
|
6
|
+
export declare function FormCheckboxPublish({ name, disabled, className }: FormCheckboxPublishProps): import("react/jsx-runtime").JSX.Element;
|
|
7
7
|
export {};
|
|
8
|
-
//# sourceMappingURL=FormCheckboxPublish.d.ts.map
|
|
@@ -15,6 +15,5 @@ type FormSelectProps = {
|
|
|
15
15
|
'aria-labelledby'?: string;
|
|
16
16
|
className?: string;
|
|
17
17
|
};
|
|
18
|
-
export default function FormSelect({ name, required, options, label, description, disabled, size, placeholder, 'aria-label': ariaLabel, 'aria-labelledby': ariaLabelledby, className, }: FormSelectProps): import("react").JSX.Element;
|
|
18
|
+
export default function FormSelect({ name, required, options, label, description, disabled, size, placeholder, 'aria-label': ariaLabel, 'aria-labelledby': ariaLabelledby, className, }: FormSelectProps): import("react/jsx-runtime").JSX.Element;
|
|
19
19
|
export {};
|
|
20
|
-
//# sourceMappingURL=FormSelect.d.ts.map
|
|
@@ -7,6 +7,5 @@ type FormSelectProps = {
|
|
|
7
7
|
size?: 'sm' | 'md' | 'lg';
|
|
8
8
|
className?: string;
|
|
9
9
|
};
|
|
10
|
-
export default function FormSelectLocale({ name, required, label, description, disabled, size, className, }: FormSelectProps): import("react").JSX.Element;
|
|
10
|
+
export default function FormSelectLocale({ name, required, label, description, disabled, size, className, }: FormSelectProps): import("react/jsx-runtime").JSX.Element;
|
|
11
11
|
export {};
|
|
12
|
-
//# sourceMappingURL=FormSelectLocale.d.ts.map
|
|
@@ -13,7 +13,6 @@ type FormSelectStrategyProps = {
|
|
|
13
13
|
size?: 'sm' | 'md' | 'lg';
|
|
14
14
|
className?: string;
|
|
15
15
|
};
|
|
16
|
-
export declare function FormSelectStrategy({ name, required, description, disabled, size, className, }: FormSelectStrategyProps): import("react").JSX.Element;
|
|
16
|
+
export declare function FormSelectStrategy({ name, required, description, disabled, size, className, }: FormSelectStrategyProps): import("react/jsx-runtime").JSX.Element;
|
|
17
17
|
export type TranslationStrategy = (typeof STRATEGY_OPTIONS)[number]['value'];
|
|
18
18
|
export {};
|
|
19
|
-
//# sourceMappingURL=FormSelectStrategy.d.ts.map
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
type BulkTranslationDashboardProps = {
|
|
2
2
|
hasDrafts: boolean;
|
|
3
3
|
};
|
|
4
|
-
export default function BulkTranslationDashboard({ hasDrafts }: BulkTranslationDashboardProps): import("react").JSX.Element;
|
|
4
|
+
export default function BulkTranslationDashboard({ hasDrafts }: BulkTranslationDashboardProps): import("react/jsx-runtime").JSX.Element;
|
|
5
5
|
export {};
|
|
6
|
-
//# sourceMappingURL=BulkTranslationDashboard.d.ts.map
|
package/dist/client/widgets/bulk-translation-dashboard/ui/BulkTranslationDashboard.export.js
CHANGED
|
@@ -5,11 +5,12 @@ export class BulkDocumentTranslationDashboard {
|
|
|
5
5
|
serverProps;
|
|
6
6
|
constructor(access = new AnyAccessGuard()){
|
|
7
7
|
this.access = access;
|
|
8
|
+
this.path = clientComponentPath('widgets/bulk-translation-dashboard/ui/BulkTranslationDashboard.server');
|
|
8
9
|
this.serverProps = {
|
|
9
10
|
access
|
|
10
11
|
};
|
|
11
12
|
}
|
|
12
|
-
path
|
|
13
|
+
path;
|
|
13
14
|
}
|
|
14
15
|
|
|
15
16
|
//# sourceMappingURL=BulkTranslationDashboard.export.js.map
|
package/dist/client/widgets/bulk-translation-dashboard/ui/BulkTranslationDashboard.server.d.ts
CHANGED
|
@@ -3,6 +3,5 @@ import type { AccessGuard } from '../../../../types/AccessGuard';
|
|
|
3
3
|
type BulkTranslationDashboardServerProps = BeforeListTableServerProps & {
|
|
4
4
|
access: AccessGuard;
|
|
5
5
|
};
|
|
6
|
-
declare const BulkTranslationDashboardServer: (props: BulkTranslationDashboardServerProps) => Promise<import("react").JSX.Element | null>;
|
|
6
|
+
declare const BulkTranslationDashboardServer: (props: BulkTranslationDashboardServerProps) => Promise<import("react/jsx-runtime").JSX.Element | null>;
|
|
7
7
|
export default BulkTranslationDashboardServer;
|
|
8
|
-
//# sourceMappingURL=BulkTranslationDashboard.server.d.ts.map
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
type TranslateDocumentProps = {
|
|
2
2
|
hasDrafts: boolean;
|
|
3
3
|
};
|
|
4
|
-
declare const TranslateDocument: ({ hasDrafts }: TranslateDocumentProps) => import("react").JSX.Element;
|
|
4
|
+
declare const TranslateDocument: ({ hasDrafts }: TranslateDocumentProps) => import("react/jsx-runtime").JSX.Element;
|
|
5
5
|
export default TranslateDocument;
|
|
6
|
-
//# sourceMappingURL=TranslateDocument.d.ts.map
|
|
@@ -7,12 +7,13 @@ export class TranslateDocumentExport {
|
|
|
7
7
|
constructor(collection, access = new AnyAccessGuard()){
|
|
8
8
|
this.collection = collection;
|
|
9
9
|
this.access = access;
|
|
10
|
+
this.path = clientComponentPath('widgets/translate-document/ui/TranslateDocument.server');
|
|
10
11
|
this.serverProps = {
|
|
11
12
|
collection,
|
|
12
13
|
access
|
|
13
14
|
};
|
|
14
15
|
}
|
|
15
|
-
path
|
|
16
|
+
path;
|
|
16
17
|
}
|
|
17
18
|
|
|
18
19
|
//# sourceMappingURL=TranslateDocument.export.js.map
|
|
@@ -4,6 +4,5 @@ type TranslateDocumentServerProps = BeforeDocumentControlsServerProps & {
|
|
|
4
4
|
collection: CollectionConfig;
|
|
5
5
|
access: AccessGuard;
|
|
6
6
|
};
|
|
7
|
-
declare function TranslateDocumentServer(props: TranslateDocumentServerProps): Promise<import("react").JSX.Element | null>;
|
|
7
|
+
declare function TranslateDocumentServer(props: TranslateDocumentServerProps): Promise<import("react/jsx-runtime").JSX.Element | null>;
|
|
8
8
|
export default TranslateDocumentServer;
|
|
9
|
-
//# sourceMappingURL=TranslateDocument.server.d.ts.map
|
package/dist/field-config.d.ts
CHANGED
package/dist/index.d.ts
CHANGED
|
@@ -12,4 +12,3 @@ export type { TranslateCollectionPluginConfig } from './plugin';
|
|
|
12
12
|
export { OpenAITranslationProvider } from './server/modules/translation-providers';
|
|
13
13
|
export { translateKitField } from './field-config';
|
|
14
14
|
export type { TranslateKitFieldConfig } from './field-config';
|
|
15
|
-
//# sourceMappingURL=index.d.ts.map
|
package/dist/plugin.d.ts
CHANGED
|
@@ -60,4 +60,3 @@ export declare class TranslateCollectionPlugin {
|
|
|
60
60
|
export declare function translatorPlugin(config: TranslatorPluginConfig): (config: Config) => Promise<Config>;
|
|
61
61
|
/** @deprecated Use `translatorPlugin` instead */
|
|
62
62
|
export declare const createTranslatePlugin: typeof translatorPlugin;
|
|
63
|
-
//# sourceMappingURL=plugin.d.ts.map
|
package/dist/plugin.js
CHANGED
|
@@ -19,15 +19,19 @@ import { normalizePath, pipe } from './server/shared';
|
|
|
19
19
|
const { access, translationProvider, basePath: rawBasePath = '/translate' } = this.pluginConfig;
|
|
20
20
|
// Build schema map from deep-cloned collections
|
|
21
21
|
// Deep clone is required because Payload mutates the original collection objects,
|
|
22
|
-
// removing `localized: true` from nested fields during sanitization
|
|
22
|
+
// removing `localized: true` from nested fields during sanitization.
|
|
23
|
+
// We use JSON round-trip instead of structuredClone because Lexical editor
|
|
24
|
+
// configs contain async functions that structuredClone cannot handle.
|
|
25
|
+
// TODO: Consider introducing a FieldLike interface with only the properties
|
|
26
|
+
// used by the pipeline (name, type, localized, fields, blocks, tabs, custom)
|
|
27
|
+
// to make the contract explicit and avoid reliance on JSON round-trip.
|
|
23
28
|
const schemaMap = new Map(this.pluginConfig.collections.map((col)=>[
|
|
24
29
|
col.slug,
|
|
25
|
-
|
|
30
|
+
JSON.parse(JSON.stringify(col.fields))
|
|
26
31
|
]));
|
|
27
32
|
const collectionSlugs = new Set(schemaMap.keys());
|
|
28
33
|
const basePath = normalizePath(rawBasePath);
|
|
29
34
|
const translateHandler = new TranslateDocumentHandler(translationProvider, schemaMap);
|
|
30
|
-
// Configure runner with handler callback
|
|
31
35
|
const runnerConfigModifier = this.pluginConfig.runner.configure({
|
|
32
36
|
handler: async (payload, input)=>{
|
|
33
37
|
await translateHandler.handle(payload, {
|
|
@@ -7,4 +7,3 @@ export declare function isCollectionAvailable(collectionSlug: string, availableC
|
|
|
7
7
|
* Gets all document IDs from a collection (for select_all option)
|
|
8
8
|
*/
|
|
9
9
|
export declare function getAllCollectionIds(payload: Payload, collectionSlug: CollectionSlug): Promise<string[]>;
|
|
10
|
-
//# sourceMappingURL=collection-utils.d.ts.map
|
|
@@ -5,4 +5,3 @@ import type { TaskRunnerProvider } from '../../modules/task-runner';
|
|
|
5
5
|
* Creates the batch cancel endpoint
|
|
6
6
|
*/
|
|
7
7
|
export declare function createCancelRoute(taskRunnerFactory: TaskRunnerProvider, access?: AccessGuard, basePath?: string): Endpoint;
|
|
8
|
-
//# sourceMappingURL=route.d.ts.map
|