@strapi/content-type-builder 5.50.0 → 5.50.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/admin/components/AIChat/Chat.js +2 -4
- package/dist/admin/components/AIChat/Chat.js.map +1 -1
- package/dist/admin/components/AIChat/Chat.mjs +2 -4
- package/dist/admin/components/AIChat/Chat.mjs.map +1 -1
- package/dist/admin/components/AIChat/UploadFigmaModal.js +1 -1
- package/dist/admin/components/AIChat/UploadFigmaModal.js.map +1 -1
- package/dist/admin/components/AIChat/UploadFigmaModal.mjs +1 -1
- package/dist/admin/components/AIChat/UploadFigmaModal.mjs.map +1 -1
- package/dist/admin/components/AIChat/components/Messages/Message.js +8 -3
- package/dist/admin/components/AIChat/components/Messages/Message.js.map +1 -1
- package/dist/admin/components/AIChat/components/Messages/Message.mjs +8 -3
- package/dist/admin/components/AIChat/components/Messages/Message.mjs.map +1 -1
- package/dist/admin/components/AIChat/lib/aiClient.js +8 -2
- package/dist/admin/components/AIChat/lib/aiClient.js.map +1 -1
- package/dist/admin/components/AIChat/lib/aiClient.mjs +8 -2
- package/dist/admin/components/AIChat/lib/aiClient.mjs.map +1 -1
- package/dist/admin/components/AIChat/lib/transforms/schemas/fromCTB.js +0 -3
- package/dist/admin/components/AIChat/lib/transforms/schemas/fromCTB.js.map +1 -1
- package/dist/admin/components/AIChat/lib/transforms/schemas/fromCTB.mjs +0 -3
- package/dist/admin/components/AIChat/lib/transforms/schemas/fromCTB.mjs.map +1 -1
- package/dist/admin/components/AIChat/lib/transforms/schemas/toCTB.js +9 -7
- package/dist/admin/components/AIChat/lib/transforms/schemas/toCTB.js.map +1 -1
- package/dist/admin/components/AIChat/lib/transforms/schemas/toCTB.mjs +9 -7
- package/dist/admin/components/AIChat/lib/transforms/schemas/toCTB.mjs.map +1 -1
- package/dist/admin/components/AIChat/providers/SchemaProvider.js +1 -1
- package/dist/admin/components/AIChat/providers/SchemaProvider.js.map +1 -1
- package/dist/admin/components/AIChat/providers/SchemaProvider.mjs +1 -1
- package/dist/admin/components/AIChat/providers/SchemaProvider.mjs.map +1 -1
- package/dist/admin/components/AllowedTypesSelect.js.map +1 -1
- package/dist/admin/components/AllowedTypesSelect.mjs.map +1 -1
- package/dist/admin/components/AttributeIcon.js +1 -1
- package/dist/admin/components/AttributeIcon.js.map +1 -1
- package/dist/admin/components/AttributeIcon.mjs +1 -1
- package/dist/admin/components/AttributeIcon.mjs.map +1 -1
- package/dist/admin/components/BooleanDefaultValueSelect.js +3 -2
- package/dist/admin/components/BooleanDefaultValueSelect.js.map +1 -1
- package/dist/admin/components/BooleanDefaultValueSelect.mjs +3 -2
- package/dist/admin/components/BooleanDefaultValueSelect.mjs.map +1 -1
- package/dist/admin/components/BooleanRadioGroup.js.map +1 -1
- package/dist/admin/components/BooleanRadioGroup.mjs.map +1 -1
- package/dist/admin/components/CTBSession/useCTBTracking.js +3 -3
- package/dist/admin/components/CTBSession/useCTBTracking.js.map +1 -1
- package/dist/admin/components/CTBSession/useCTBTracking.mjs +3 -3
- package/dist/admin/components/CTBSession/useCTBTracking.mjs.map +1 -1
- package/dist/admin/components/CheckboxWithNumberField.js +3 -2
- package/dist/admin/components/CheckboxWithNumberField.js.map +1 -1
- package/dist/admin/components/CheckboxWithNumberField.mjs +3 -2
- package/dist/admin/components/CheckboxWithNumberField.mjs.map +1 -1
- package/dist/admin/components/ComponentCard/ComponentCard.js.map +1 -1
- package/dist/admin/components/ComponentCard/ComponentCard.mjs.map +1 -1
- package/dist/admin/components/ContentTypeBuilderNav/ContentTypeBuilderNav.js +160 -162
- package/dist/admin/components/ContentTypeBuilderNav/ContentTypeBuilderNav.js.map +1 -1
- package/dist/admin/components/ContentTypeBuilderNav/ContentTypeBuilderNav.mjs +160 -162
- package/dist/admin/components/ContentTypeBuilderNav/ContentTypeBuilderNav.mjs.map +1 -1
- package/dist/admin/components/ContentTypeBuilderNav/useContentTypeBuilderMenu.js +1 -1
- package/dist/admin/components/ContentTypeBuilderNav/useContentTypeBuilderMenu.js.map +1 -1
- package/dist/admin/components/ContentTypeBuilderNav/useContentTypeBuilderMenu.mjs +1 -1
- package/dist/admin/components/ContentTypeBuilderNav/useContentTypeBuilderMenu.mjs.map +1 -1
- package/dist/admin/components/ContentTypeRadioGroup.js.map +1 -1
- package/dist/admin/components/ContentTypeRadioGroup.mjs.map +1 -1
- package/dist/admin/components/CustomRadioGroup/CustomRadioGroup.js +6 -5
- package/dist/admin/components/CustomRadioGroup/CustomRadioGroup.js.map +1 -1
- package/dist/admin/components/CustomRadioGroup/CustomRadioGroup.mjs +6 -5
- package/dist/admin/components/CustomRadioGroup/CustomRadioGroup.mjs.map +1 -1
- package/dist/admin/components/CustomRadioGroup/Styles.js.map +1 -1
- package/dist/admin/components/CustomRadioGroup/Styles.mjs.map +1 -1
- package/dist/admin/components/DataManager/DataManagerContext.js.map +1 -1
- package/dist/admin/components/DataManager/DataManagerContext.mjs.map +1 -1
- package/dist/admin/components/DataManager/DataManagerProvider.js +16 -4
- package/dist/admin/components/DataManager/DataManagerProvider.js.map +1 -1
- package/dist/admin/components/DataManager/DataManagerProvider.mjs +16 -4
- package/dist/admin/components/DataManager/DataManagerProvider.mjs.map +1 -1
- package/dist/admin/components/DataManager/reducer.js +2 -2
- package/dist/admin/components/DataManager/reducer.js.map +1 -1
- package/dist/admin/components/DataManager/reducer.mjs +2 -2
- package/dist/admin/components/DataManager/reducer.mjs.map +1 -1
- package/dist/admin/components/DataManager/useServerRestartWatcher.js.map +1 -1
- package/dist/admin/components/DataManager/useServerRestartWatcher.mjs.map +1 -1
- package/dist/admin/components/DataManager/utils/retrieveSpecificInfoFromComponents.js.map +1 -1
- package/dist/admin/components/DataManager/utils/retrieveSpecificInfoFromComponents.mjs.map +1 -1
- package/dist/admin/components/DraftAndPublishToggle.js.map +1 -1
- package/dist/admin/components/DraftAndPublishToggle.mjs.map +1 -1
- package/dist/admin/components/DynamicZoneList.js.map +1 -1
- package/dist/admin/components/DynamicZoneList.mjs.map +1 -1
- package/dist/admin/components/FormModal/FormModal.js +91 -71
- package/dist/admin/components/FormModal/FormModal.js.map +1 -1
- package/dist/admin/components/FormModal/FormModal.mjs +91 -70
- package/dist/admin/components/FormModal/FormModal.mjs.map +1 -1
- package/dist/admin/components/FormModal/attributes/ConditionForm.js +20 -17
- package/dist/admin/components/FormModal/attributes/ConditionForm.js.map +1 -1
- package/dist/admin/components/FormModal/attributes/ConditionForm.mjs +20 -17
- package/dist/admin/components/FormModal/attributes/ConditionForm.mjs.map +1 -1
- package/dist/admin/components/FormModal/attributes/validation/common.js.map +1 -1
- package/dist/admin/components/FormModal/attributes/validation/common.mjs.map +1 -1
- package/dist/admin/components/FormModal/forms/forms.js +4 -6
- package/dist/admin/components/FormModal/forms/forms.js.map +1 -1
- package/dist/admin/components/FormModal/forms/forms.mjs +4 -6
- package/dist/admin/components/FormModal/forms/forms.mjs.map +1 -1
- package/dist/admin/components/FormModal/forms/utils/getUsedAttributeNames.js.map +1 -1
- package/dist/admin/components/FormModal/forms/utils/getUsedAttributeNames.mjs.map +1 -1
- package/dist/admin/components/FormModal/reducer.js +9 -6
- package/dist/admin/components/FormModal/reducer.js.map +1 -1
- package/dist/admin/components/FormModal/reducer.mjs +9 -6
- package/dist/admin/components/FormModal/reducer.mjs.map +1 -1
- package/dist/admin/components/FormModal/utils/customFieldDefaultOptionsReducer.js +3 -3
- package/dist/admin/components/FormModal/utils/customFieldDefaultOptionsReducer.js.map +1 -1
- package/dist/admin/components/FormModal/utils/customFieldDefaultOptionsReducer.mjs +3 -3
- package/dist/admin/components/FormModal/utils/customFieldDefaultOptionsReducer.mjs.map +1 -1
- package/dist/admin/components/FormModal/utils/getFormInputNames.js +1 -1
- package/dist/admin/components/FormModal/utils/getFormInputNames.js.map +1 -1
- package/dist/admin/components/FormModal/utils/getFormInputNames.mjs +1 -1
- package/dist/admin/components/FormModal/utils/getFormInputNames.mjs.map +1 -1
- package/dist/admin/components/FormModal/utils/relations.js +2 -2
- package/dist/admin/components/FormModal/utils/relations.js.map +1 -1
- package/dist/admin/components/FormModal/utils/relations.mjs +2 -2
- package/dist/admin/components/FormModal/utils/relations.mjs.map +1 -1
- package/dist/admin/components/FormModalHeader.js.map +1 -1
- package/dist/admin/components/FormModalHeader.mjs.map +1 -1
- package/dist/admin/components/FormModalNavigation/FormModalNavigationContext.js.map +1 -1
- package/dist/admin/components/FormModalNavigation/FormModalNavigationContext.mjs.map +1 -1
- package/dist/admin/components/FormModalNavigation/FormModalNavigationProvider.js +13 -13
- package/dist/admin/components/FormModalNavigation/FormModalNavigationProvider.js.map +1 -1
- package/dist/admin/components/FormModalNavigation/FormModalNavigationProvider.mjs +13 -13
- package/dist/admin/components/FormModalNavigation/FormModalNavigationProvider.mjs.map +1 -1
- package/dist/admin/components/GenericInputs.js +24 -12
- package/dist/admin/components/GenericInputs.js.map +1 -1
- package/dist/admin/components/GenericInputs.mjs +24 -12
- package/dist/admin/components/GenericInputs.mjs.map +1 -1
- package/dist/admin/components/IconPicker/IconPicker.js.map +1 -1
- package/dist/admin/components/IconPicker/IconPicker.mjs.map +1 -1
- package/dist/admin/components/PluralName.js.map +1 -1
- package/dist/admin/components/PluralName.mjs.map +1 -1
- package/dist/admin/components/Relation/Relation.js +3 -3
- package/dist/admin/components/Relation/Relation.js.map +1 -1
- package/dist/admin/components/Relation/Relation.mjs +3 -3
- package/dist/admin/components/Relation/Relation.mjs.map +1 -1
- package/dist/admin/components/Relation/RelationField/RelationField.js +1 -1
- package/dist/admin/components/Relation/RelationField/RelationField.js.map +1 -1
- package/dist/admin/components/Relation/RelationField/RelationField.mjs +1 -1
- package/dist/admin/components/Relation/RelationField/RelationField.mjs.map +1 -1
- package/dist/admin/components/SelectCategory.js +6 -0
- package/dist/admin/components/SelectCategory.js.map +1 -1
- package/dist/admin/components/SelectCategory.mjs +6 -0
- package/dist/admin/components/SelectCategory.mjs.map +1 -1
- package/dist/admin/components/SelectComponent.js +1 -1
- package/dist/admin/components/SelectComponent.js.map +1 -1
- package/dist/admin/components/SelectComponent.mjs +1 -1
- package/dist/admin/components/SelectComponent.mjs.map +1 -1
- package/dist/admin/components/SingularName.js.map +1 -1
- package/dist/admin/components/SingularName.mjs.map +1 -1
- package/dist/admin/components/TabForm.js +50 -51
- package/dist/admin/components/TabForm.js.map +1 -1
- package/dist/admin/components/TabForm.mjs +51 -52
- package/dist/admin/components/TabForm.mjs.map +1 -1
- package/dist/admin/src/components/AIChat/components/Messages/Message.d.ts +1 -2
- package/dist/admin/src/components/AIChat/lib/aiClient.d.ts +1 -1
- package/dist/admin/src/components/AIChat/lib/transforms/schemas/fromCTB.d.ts +6 -2
- package/dist/admin/src/components/AIChat/lib/transforms/schemas/toCTB.d.ts +1 -1
- package/dist/admin/src/components/AIChat/lib/types/schema.d.ts +5 -5
- package/dist/admin/src/components/AllowedTypesSelect.d.ts +3 -3
- package/dist/admin/src/components/BooleanDefaultValueSelect.d.ts +3 -3
- package/dist/admin/src/components/BooleanRadioGroup.d.ts +2 -2
- package/dist/admin/src/components/CTBSession/useCTBTracking.d.ts +1 -1
- package/dist/admin/src/components/CheckboxWithNumberField.d.ts +6 -4
- package/dist/admin/src/components/ContentTypeRadioGroup.d.ts +3 -2
- package/dist/admin/src/components/CustomRadioGroup/CustomRadioGroup.d.ts +3 -2
- package/dist/admin/src/components/DataManager/DataManagerContext.d.ts +13 -11
- package/dist/admin/src/components/DataManager/reducer.d.ts +14 -10
- package/dist/admin/src/components/DataManager/utils/cleanData.d.ts +42 -42
- package/dist/admin/src/components/DataManager/utils/formatSchemas.d.ts +9 -3
- package/dist/admin/src/components/DataManager/utils/retrieveSpecificInfoFromComponents.d.ts +2 -1
- package/dist/admin/src/components/DraftAndPublishToggle.d.ts +1 -6
- package/dist/admin/src/components/DynamicZoneList.d.ts +2 -2
- package/dist/admin/src/components/FormModal/attributes/ConditionForm.d.ts +3 -2
- package/dist/admin/src/components/FormModal/attributes/validation/common.d.ts +3 -1
- package/dist/admin/src/components/FormModal/forms/forms.d.ts +59 -26
- package/dist/admin/src/components/FormModal/forms/utils/getUsedAttributeNames.d.ts +12 -2
- package/dist/admin/src/components/FormModal/reducer.d.ts +104 -32
- package/dist/admin/src/components/FormModal/utils/customFieldDefaultOptionsReducer.d.ts +11 -1
- package/dist/admin/src/components/FormModal/utils/getFormInputNames.d.ts +8 -1
- package/dist/admin/src/components/FormModal/utils/relations.d.ts +2 -2
- package/dist/admin/src/components/FormModalHeader.d.ts +5 -8
- package/dist/admin/src/components/FormModalNavigation/FormModalNavigationContext.d.ts +2 -2
- package/dist/admin/src/components/FormModalNavigation/FormModalNavigationProvider.d.ts +17 -1
- package/dist/admin/src/components/GenericInputs.d.ts +12 -7
- package/dist/admin/src/components/IconPicker/IconPicker.d.ts +2 -7
- package/dist/admin/src/components/PluralName.d.ts +6 -14
- package/dist/admin/src/components/Relation/Relation.d.ts +12 -3
- package/dist/admin/src/components/Relation/RelationField/RelationField.d.ts +3 -2
- package/dist/admin/src/components/SelectCategory.d.ts +3 -12
- package/dist/admin/src/components/SelectComponent.d.ts +8 -7
- package/dist/admin/src/components/SingularName.d.ts +5 -8
- package/dist/admin/src/components/TabForm.d.ts +38 -7
- package/dist/admin/src/types.d.ts +20 -12
- package/dist/admin/src/utils/conditions.d.ts +13 -4
- package/dist/admin/src/utils/formAPI.d.ts +38 -33
- package/dist/admin/src/utils/getRelationType.d.ts +1 -1
- package/dist/admin/src/utils/parseNumberInputValue.d.ts +1 -0
- package/dist/admin/translations/ko.json.js +64 -1
- package/dist/admin/translations/ko.json.js.map +1 -1
- package/dist/admin/translations/ko.json.mjs +64 -1
- package/dist/admin/translations/ko.json.mjs.map +1 -1
- package/dist/admin/utils/conditions.js +38 -28
- package/dist/admin/utils/conditions.js.map +1 -1
- package/dist/admin/utils/conditions.mjs +37 -28
- package/dist/admin/utils/conditions.mjs.map +1 -1
- package/dist/admin/utils/formAPI.js +9 -6
- package/dist/admin/utils/formAPI.js.map +1 -1
- package/dist/admin/utils/formAPI.mjs +9 -6
- package/dist/admin/utils/formAPI.mjs.map +1 -1
- package/dist/admin/utils/getRelationType.js +3 -0
- package/dist/admin/utils/getRelationType.js.map +1 -1
- package/dist/admin/utils/getRelationType.mjs +3 -0
- package/dist/admin/utils/getRelationType.mjs.map +1 -1
- package/dist/admin/utils/getYupInnerErrors.js +6 -4
- package/dist/admin/utils/getYupInnerErrors.js.map +1 -1
- package/dist/admin/utils/getYupInnerErrors.mjs +6 -4
- package/dist/admin/utils/getYupInnerErrors.mjs.map +1 -1
- package/dist/admin/utils/parseNumberInputValue.js +15 -0
- package/dist/admin/utils/parseNumberInputValue.js.map +1 -0
- package/dist/admin/utils/parseNumberInputValue.mjs +13 -0
- package/dist/admin/utils/parseNumberInputValue.mjs.map +1 -0
- package/dist/server/controllers/validation/relations.js +1 -1
- package/dist/server/controllers/validation/relations.js.map +1 -1
- package/dist/server/controllers/validation/relations.mjs +1 -1
- package/dist/server/controllers/validation/relations.mjs.map +1 -1
- package/dist/server/controllers/validation/schema.js +37 -1
- package/dist/server/controllers/validation/schema.js.map +1 -1
- package/dist/server/controllers/validation/schema.mjs +38 -3
- package/dist/server/controllers/validation/schema.mjs.map +1 -1
- package/dist/server/controllers/validation/types.js +4 -3
- package/dist/server/controllers/validation/types.js.map +1 -1
- package/dist/server/controllers/validation/types.mjs +4 -3
- package/dist/server/controllers/validation/types.mjs.map +1 -1
- package/dist/server/services/builder.js +11 -66
- package/dist/server/services/builder.js.map +1 -1
- package/dist/server/services/builder.mjs +11 -66
- package/dist/server/services/builder.mjs.map +1 -1
- package/dist/server/src/controllers/validation/schema.d.ts +10 -0
- package/dist/server/src/controllers/validation/schema.d.ts.map +1 -1
- package/dist/server/src/index.d.ts +3 -3
- package/dist/server/src/routes/index.d.ts +1 -1
- package/dist/server/src/services/builder.d.ts +7 -0
- package/dist/server/src/services/builder.d.ts.map +1 -1
- package/dist/server/src/services/schema-builder/component-builder.d.ts +4 -4
- package/dist/server/src/services/schema-builder/content-type-builder.d.ts +4 -4
- package/dist/server/src/services/schema-builder/index.d.ts +18 -18
- package/dist/server/src/services/schema.d.ts +75 -75
- package/dist/server/src/utils/attributes.d.ts +2 -2
- package/dist/server/src/utils/attributes.d.ts.map +1 -1
- package/package.json +17 -13
|
@@ -1 +1,11 @@
|
|
|
1
|
-
|
|
1
|
+
type CustomFieldDefaultOption = {
|
|
2
|
+
name: string;
|
|
3
|
+
defaultValue: unknown;
|
|
4
|
+
};
|
|
5
|
+
type CustomFieldOption = {
|
|
6
|
+
items?: CustomFieldOption[];
|
|
7
|
+
name?: string;
|
|
8
|
+
defaultValue?: unknown;
|
|
9
|
+
};
|
|
10
|
+
export declare const customFieldDefaultOptionsReducer: (acc: CustomFieldDefaultOption[], option: CustomFieldOption) => CustomFieldDefaultOption[];
|
|
11
|
+
export {};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import type { Schema } from '@strapi/types';
|
|
2
|
-
declare const shouldPluralizeName: (nature
|
|
3
|
-
declare const shouldPluralizeTargetAttribute: (nature
|
|
2
|
+
declare const shouldPluralizeName: (nature?: Schema.Attribute.RelationKind.Any) => 2 | 1;
|
|
3
|
+
declare const shouldPluralizeTargetAttribute: (nature?: Schema.Attribute.RelationKind.Any) => 2 | 1;
|
|
4
4
|
export { shouldPluralizeName, shouldPluralizeTargetAttribute };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { IconByType } from './AttributeIcon';
|
|
2
|
-
import type { Internal } from '@strapi/types';
|
|
2
|
+
import type { Internal, Struct } from '@strapi/types';
|
|
3
3
|
type BaseProps = {
|
|
4
4
|
actionType?: string | null;
|
|
5
5
|
attributeName: string;
|
|
@@ -10,12 +10,9 @@ type BaseProps = {
|
|
|
10
10
|
customFieldUid?: string | null;
|
|
11
11
|
showBackLink?: boolean;
|
|
12
12
|
};
|
|
13
|
-
type FormModalHeaderProps = BaseProps &
|
|
14
|
-
forTarget:
|
|
15
|
-
targetUid: Internal.UID.
|
|
16
|
-
}
|
|
17
|
-
forTarget: 'contentType';
|
|
18
|
-
targetUid: Internal.UID.ContentType;
|
|
19
|
-
});
|
|
13
|
+
type FormModalHeaderProps = BaseProps & {
|
|
14
|
+
forTarget: Struct.ModelType;
|
|
15
|
+
targetUid: Internal.UID.Schema;
|
|
16
|
+
};
|
|
20
17
|
export declare const FormModalHeader: ({ actionType, attributeName, attributeType, contentTypeKind, dynamicZoneTarget, forTarget, modalType, targetUid, customFieldUid, showBackLink, }: FormModalHeaderProps) => import("react/jsx-runtime").JSX.Element;
|
|
21
18
|
export {};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
|
-
import type { State, SelectFieldPayload, SelectCustomFieldPayload, NavigateToChooseAttributeModalPayload, NavigateToAddCompoToDZModalPayload, OpenModalAddComponentsToDZPayload, OpenModalEditFieldPayload, OpenModalEditCustomFieldPayload, OpenModalEditSchemaPayload, OpenModalAddFieldPayload } from './FormModalNavigationProvider';
|
|
2
|
+
import type { State, SelectFieldPayload, SelectCustomFieldPayload, NavigateToChooseAttributeModalPayload, NavigateToAddCompoToDZModalPayload, OpenModalAddComponentsToDZPayload, OpenModalEditFieldPayload, OpenModalEditCustomFieldPayload, OpenModalEditSchemaPayload, OpenModalAddFieldPayload, OpenModalCreateSchemaPayload } from './FormModalNavigationProvider';
|
|
3
3
|
export type FormModalNavigationContextValue = State & {
|
|
4
4
|
onCloseModal: () => void;
|
|
5
5
|
onOpenModalAddField: (options: OpenModalAddFieldPayload) => void;
|
|
@@ -9,7 +9,7 @@ export type FormModalNavigationContextValue = State & {
|
|
|
9
9
|
onNavigateToAddCompoToDZModal: (options: NavigateToAddCompoToDZModalPayload) => void;
|
|
10
10
|
onOpenModalAddComponentsToDZ: (options: OpenModalAddComponentsToDZPayload) => void;
|
|
11
11
|
onNavigateToCreateComponentStep2: () => void;
|
|
12
|
-
onOpenModalCreateSchema: (options:
|
|
12
|
+
onOpenModalCreateSchema: (options: OpenModalCreateSchemaPayload) => void;
|
|
13
13
|
onOpenModalEditField: (options: OpenModalEditFieldPayload) => void;
|
|
14
14
|
onOpenModalEditCustomField: (options: OpenModalEditCustomFieldPayload) => void;
|
|
15
15
|
onOpenModalEditSchema: (options: OpenModalEditSchemaPayload) => void;
|
|
@@ -4,7 +4,22 @@ type FormModalNavigationProviderProps = {
|
|
|
4
4
|
};
|
|
5
5
|
export type Tab = 'basic' | 'advanced';
|
|
6
6
|
export type ModalType = 'chooseAttribute' | 'edit' | 'attribute' | 'customField' | 'addComponentToDynamicZone' | 'contentType' | 'component';
|
|
7
|
-
export type
|
|
7
|
+
export type ActionType = 'create' | 'edit' | null;
|
|
8
|
+
export type State = {
|
|
9
|
+
actionType: Exclude<ActionType, null>;
|
|
10
|
+
attributeName: string;
|
|
11
|
+
attributeType: string;
|
|
12
|
+
dynamicZoneTarget: string;
|
|
13
|
+
forTarget: Struct.ModelType;
|
|
14
|
+
modalType: ModalType | null;
|
|
15
|
+
isOpen: boolean;
|
|
16
|
+
showBackLink: boolean;
|
|
17
|
+
kind: Struct.ContentTypeKind;
|
|
18
|
+
step: string | null;
|
|
19
|
+
targetUid: Internal.UID.Schema;
|
|
20
|
+
customFieldUid: string;
|
|
21
|
+
activeTab: Tab;
|
|
22
|
+
};
|
|
8
23
|
export declare const INITIAL_STATE_DATA: State;
|
|
9
24
|
export type SelectCustomFieldPayload = {
|
|
10
25
|
attributeType: string;
|
|
@@ -49,5 +64,6 @@ export type NavigateToChooseAttributeModalPayload = {
|
|
|
49
64
|
export type NavigateToAddCompoToDZModalPayload = {
|
|
50
65
|
dynamicZoneTarget: string;
|
|
51
66
|
};
|
|
67
|
+
export type OpenModalCreateSchemaPayload = Pick<State, 'actionType' | 'forTarget' | 'kind' | 'modalType'>;
|
|
52
68
|
export declare const FormModalNavigationProvider: ({ children }: FormModalNavigationProviderProps) => import("react/jsx-runtime").JSX.Element;
|
|
53
69
|
export {};
|
|
@@ -18,6 +18,11 @@ interface InputOption {
|
|
|
18
18
|
key: string;
|
|
19
19
|
value: string;
|
|
20
20
|
}
|
|
21
|
+
type ConditionField = {
|
|
22
|
+
name: string;
|
|
23
|
+
type: string;
|
|
24
|
+
enum?: string[];
|
|
25
|
+
};
|
|
21
26
|
interface CustomInputProps<TAttribute extends Schema.Attribute.AnyAttribute = Schema.Attribute.AnyAttribute> {
|
|
22
27
|
attribute?: TAttribute;
|
|
23
28
|
autoComplete?: string;
|
|
@@ -31,7 +36,7 @@ interface CustomInputProps<TAttribute extends Schema.Attribute.AnyAttribute = Sc
|
|
|
31
36
|
onChange: (payload: {
|
|
32
37
|
target: {
|
|
33
38
|
name: string;
|
|
34
|
-
value
|
|
39
|
+
value?: unknown;
|
|
35
40
|
type?: string;
|
|
36
41
|
};
|
|
37
42
|
}, shouldSetInitialValue?: boolean) => void;
|
|
@@ -41,10 +46,10 @@ interface CustomInputProps<TAttribute extends Schema.Attribute.AnyAttribute = Sc
|
|
|
41
46
|
required?: boolean;
|
|
42
47
|
step?: number;
|
|
43
48
|
type: string;
|
|
44
|
-
value?:
|
|
49
|
+
value?: unknown;
|
|
45
50
|
autoFocus?: boolean;
|
|
46
51
|
attributeName?: string;
|
|
47
|
-
conditionFields?:
|
|
52
|
+
conditionFields?: ConditionField[];
|
|
48
53
|
}
|
|
49
54
|
interface GenericInputProps<TAttribute extends Schema.Attribute.AnyAttribute = Schema.Attribute.AnyAttribute> {
|
|
50
55
|
attribute?: TAttribute;
|
|
@@ -59,7 +64,7 @@ interface GenericInputProps<TAttribute extends Schema.Attribute.AnyAttribute = S
|
|
|
59
64
|
onChange: (payload: {
|
|
60
65
|
target: {
|
|
61
66
|
name: string;
|
|
62
|
-
value
|
|
67
|
+
value?: unknown;
|
|
63
68
|
type?: string;
|
|
64
69
|
};
|
|
65
70
|
}, shouldSetInitialValue?: boolean) => void;
|
|
@@ -69,17 +74,17 @@ interface GenericInputProps<TAttribute extends Schema.Attribute.AnyAttribute = S
|
|
|
69
74
|
required?: boolean;
|
|
70
75
|
step?: number;
|
|
71
76
|
type: string;
|
|
72
|
-
value?:
|
|
77
|
+
value?: unknown;
|
|
73
78
|
isNullable?: boolean;
|
|
74
79
|
autoFocus?: boolean;
|
|
75
80
|
attributeName?: string;
|
|
76
|
-
conditionFields?:
|
|
81
|
+
conditionFields?: ConditionField[];
|
|
77
82
|
}
|
|
78
83
|
/**
|
|
79
84
|
* we've memoized this component because we use a context to store all the data in our form in the content-manager.
|
|
80
85
|
* This then causes _every_ component to re-render because there are no selects incurring performance issues
|
|
81
86
|
* in content-types as the content-type gets more complicated.
|
|
82
87
|
*/
|
|
83
|
-
declare const MemoizedGenericInput: React.MemoExoticComponent<({ autoComplete, customInputs, description, disabled, intlLabel, labelAction, error, name, onChange, onDelete, options, placeholder, required, step, type, value: defaultValue, isNullable, autoFocus, attribute, attributeName, conditionFields, ...rest }: GenericInputProps) => import("react/jsx-runtime").JSX.Element>;
|
|
88
|
+
declare const MemoizedGenericInput: React.MemoExoticComponent<({ autoComplete, customInputs, description, disabled, intlLabel, labelAction, error, name, onChange, onDelete, options, placeholder, required, step, type, value: defaultValue, isNullable: _isNullable, autoFocus, attribute, attributeName, conditionFields, ...rest }: GenericInputProps) => import("react/jsx-runtime").JSX.Element>;
|
|
84
89
|
export type { GenericInputProps, CustomInputProps };
|
|
85
90
|
export { MemoizedGenericInput as GenericInput };
|
|
@@ -1,13 +1,8 @@
|
|
|
1
|
-
import type { IntlLabel } from '../../types';
|
|
1
|
+
import type { FormChangeHandler, IntlLabel } from '../../types';
|
|
2
2
|
export interface IconPickerProps {
|
|
3
3
|
intlLabel: IntlLabel;
|
|
4
4
|
name: string;
|
|
5
|
-
onChange:
|
|
6
|
-
target: {
|
|
7
|
-
name: string;
|
|
8
|
-
value: string;
|
|
9
|
-
};
|
|
10
|
-
}) => void;
|
|
5
|
+
onChange: FormChangeHandler<string>;
|
|
11
6
|
value?: string;
|
|
12
7
|
}
|
|
13
8
|
export declare const IconPicker: ({ intlLabel, name, onChange, value }: IconPickerProps) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,21 +1,13 @@
|
|
|
1
|
-
import type { IntlLabel } from '../types';
|
|
2
|
-
interface Description {
|
|
3
|
-
id: string;
|
|
4
|
-
defaultMessage: string;
|
|
5
|
-
values?: Record<string, any>;
|
|
6
|
-
}
|
|
1
|
+
import type { FormChangeHandler, IntlLabel } from '../types';
|
|
7
2
|
interface PluralNameProps {
|
|
8
|
-
description?:
|
|
3
|
+
description?: IntlLabel;
|
|
9
4
|
error?: string;
|
|
10
5
|
intlLabel: IntlLabel;
|
|
11
|
-
modifiedData:
|
|
6
|
+
modifiedData: {
|
|
7
|
+
displayName?: string;
|
|
8
|
+
};
|
|
12
9
|
name: string;
|
|
13
|
-
onChange:
|
|
14
|
-
target: {
|
|
15
|
-
name: string;
|
|
16
|
-
value: string;
|
|
17
|
-
};
|
|
18
|
-
}) => void;
|
|
10
|
+
onChange: FormChangeHandler<string>;
|
|
19
11
|
value?: string;
|
|
20
12
|
}
|
|
21
13
|
export declare const PluralName: ({ description, error, intlLabel, modifiedData, name, onChange, value, }: PluralNameProps) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,8 +1,17 @@
|
|
|
1
|
+
import type { FormChangeHandler } from '../../types';
|
|
2
|
+
import type { Schema } from '@strapi/types';
|
|
1
3
|
interface RelationProps {
|
|
2
|
-
formErrors: Record<string,
|
|
4
|
+
formErrors: Record<string, {
|
|
5
|
+
id?: string;
|
|
6
|
+
} | undefined>;
|
|
3
7
|
mainBoxHeader: string;
|
|
4
|
-
modifiedData:
|
|
5
|
-
|
|
8
|
+
modifiedData: {
|
|
9
|
+
name?: string;
|
|
10
|
+
relation?: Schema.Attribute.RelationKind.Any;
|
|
11
|
+
target?: string;
|
|
12
|
+
targetAttribute?: string | null;
|
|
13
|
+
};
|
|
14
|
+
onChange: FormChangeHandler;
|
|
6
15
|
naturePickerType: string;
|
|
7
16
|
targetUid: string;
|
|
8
17
|
}
|
|
@@ -1,11 +1,12 @@
|
|
|
1
|
+
import type { FormChangeHandler } from '../../../types';
|
|
1
2
|
import type { Internal } from '@strapi/types';
|
|
2
3
|
interface RelationFormBoxProps {
|
|
3
4
|
disabled?: boolean;
|
|
4
|
-
error?:
|
|
5
|
+
error?: string | null;
|
|
5
6
|
header?: string;
|
|
6
7
|
isMain?: boolean;
|
|
7
8
|
name: string;
|
|
8
|
-
onChange:
|
|
9
|
+
onChange: FormChangeHandler;
|
|
9
10
|
oneThatIsCreatingARelationWithAnother?: string;
|
|
10
11
|
target?: Internal.UID.ContentType;
|
|
11
12
|
value?: string;
|
|
@@ -1,18 +1,9 @@
|
|
|
1
|
+
import type { FormChangeHandler, IntlLabel } from '../types';
|
|
1
2
|
interface SelectCategoryProps {
|
|
2
3
|
error?: string | null;
|
|
3
|
-
intlLabel:
|
|
4
|
-
id: string;
|
|
5
|
-
defaultMessage: string;
|
|
6
|
-
values?: Record<string, any>;
|
|
7
|
-
};
|
|
4
|
+
intlLabel: IntlLabel;
|
|
8
5
|
name: string;
|
|
9
|
-
onChange:
|
|
10
|
-
target: {
|
|
11
|
-
name: string;
|
|
12
|
-
value: any;
|
|
13
|
-
type: string;
|
|
14
|
-
};
|
|
15
|
-
}) => void;
|
|
6
|
+
onChange: FormChangeHandler<string, 'select-category'>;
|
|
16
7
|
value?: string;
|
|
17
8
|
isCreating?: boolean;
|
|
18
9
|
dynamicZoneTarget?: string | null;
|
|
@@ -1,17 +1,18 @@
|
|
|
1
|
+
import type { FormChangeHandler, IntlLabel } from '../types';
|
|
1
2
|
import type { Internal } from '@strapi/types';
|
|
3
|
+
type ComponentToCreate = {
|
|
4
|
+
displayName?: string;
|
|
5
|
+
category?: string;
|
|
6
|
+
};
|
|
2
7
|
interface SelectComponentProps {
|
|
3
|
-
componentToCreate?:
|
|
8
|
+
componentToCreate?: ComponentToCreate | null;
|
|
4
9
|
error?: string | null;
|
|
5
|
-
intlLabel:
|
|
6
|
-
id: string;
|
|
7
|
-
defaultMessage: string;
|
|
8
|
-
values?: Record<string, any>;
|
|
9
|
-
};
|
|
10
|
+
intlLabel: IntlLabel;
|
|
10
11
|
isAddingAComponentToAnotherComponent: boolean;
|
|
11
12
|
isCreating: boolean;
|
|
12
13
|
isCreatingComponentWhileAddingAField: boolean;
|
|
13
14
|
name: string;
|
|
14
|
-
onChange:
|
|
15
|
+
onChange: FormChangeHandler<string, 'select-category'>;
|
|
15
16
|
targetUid: Internal.UID.Schema;
|
|
16
17
|
value: string;
|
|
17
18
|
forTarget: string;
|
|
@@ -1,16 +1,13 @@
|
|
|
1
|
-
import type { IntlLabel } from '../types';
|
|
1
|
+
import type { FormChangeHandler, IntlLabel } from '../types';
|
|
2
2
|
interface SingularNameProps {
|
|
3
3
|
description?: IntlLabel | null;
|
|
4
4
|
error?: string | null;
|
|
5
5
|
intlLabel: IntlLabel;
|
|
6
|
-
modifiedData:
|
|
6
|
+
modifiedData: {
|
|
7
|
+
displayName?: string;
|
|
8
|
+
};
|
|
7
9
|
name: string;
|
|
8
|
-
onChange:
|
|
9
|
-
target: {
|
|
10
|
-
name: string;
|
|
11
|
-
value: string;
|
|
12
|
-
};
|
|
13
|
-
}) => void;
|
|
10
|
+
onChange: FormChangeHandler<string>;
|
|
14
11
|
value?: string | null;
|
|
15
12
|
}
|
|
16
13
|
export declare const SingularName: ({ description, error, intlLabel, modifiedData, name, onChange, value, }: SingularNameProps) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,9 +1,40 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
}
|
|
1
|
+
import { GenericInput } from './GenericInputs';
|
|
2
|
+
import type { AnyAttribute, IntlLabel } from '../types';
|
|
3
|
+
type FormInput = Partial<React.ComponentProps<typeof GenericInput>> & {
|
|
4
|
+
name: string;
|
|
5
|
+
type: string;
|
|
6
|
+
size?: number;
|
|
7
|
+
};
|
|
8
|
+
type FormSection = {
|
|
9
|
+
sectionTitle?: IntlLabel | null;
|
|
10
|
+
intlLabel?: IntlLabel;
|
|
11
|
+
items: FormInput[];
|
|
12
|
+
};
|
|
13
|
+
type FormError = {
|
|
14
|
+
id?: string;
|
|
15
|
+
};
|
|
16
|
+
type GenericInputProps = Record<string, unknown> & {
|
|
17
|
+
attributeName?: string;
|
|
18
|
+
contentTypeSchema?: {
|
|
19
|
+
attributes?: AnyAttribute[];
|
|
20
|
+
};
|
|
21
|
+
};
|
|
22
|
+
type ModifiedData = Record<string, unknown> & {
|
|
23
|
+
name?: string;
|
|
24
|
+
};
|
|
25
|
+
type TabFormChangeHandler = (value: {
|
|
26
|
+
target: {
|
|
27
|
+
name: string;
|
|
28
|
+
value?: unknown;
|
|
29
|
+
type?: string;
|
|
30
|
+
};
|
|
31
|
+
}) => void;
|
|
32
|
+
type TabFormProps = {
|
|
33
|
+
form: FormSection[];
|
|
34
|
+
formErrors: Record<string, FormError>;
|
|
35
|
+
genericInputProps: GenericInputProps;
|
|
36
|
+
modifiedData: ModifiedData;
|
|
37
|
+
onChange: TabFormChangeHandler;
|
|
38
|
+
};
|
|
8
39
|
export declare const TabForm: ({ form, formErrors, genericInputProps, modifiedData, onChange, }: TabFormProps) => import("react/jsx-runtime").JSX.Element;
|
|
9
40
|
export {};
|
|
@@ -1,23 +1,32 @@
|
|
|
1
1
|
import type { Schema, Struct, UID } from '@strapi/types';
|
|
2
|
+
import type { PrimitiveType } from 'react-intl';
|
|
2
3
|
export type IntlLabel = {
|
|
3
4
|
id: string;
|
|
4
5
|
defaultMessage: string;
|
|
5
|
-
values?: Record<string,
|
|
6
|
+
values?: Record<string, PrimitiveType>;
|
|
6
7
|
};
|
|
8
|
+
export type FormChange<TValue = unknown, TType extends string = string> = {
|
|
9
|
+
target: {
|
|
10
|
+
name: string;
|
|
11
|
+
value?: TValue;
|
|
12
|
+
type?: TType;
|
|
13
|
+
};
|
|
14
|
+
};
|
|
15
|
+
export type FormChangeHandler<TValue = unknown, TType extends string = string> = (value: FormChange<TValue, TType>) => void;
|
|
7
16
|
export type DifferentAttributesKind = 'Populatable' | 'NonPopulatable' | 'Any';
|
|
8
17
|
export type Status = 'UNCHANGED' | 'CHANGED' | 'REMOVED' | 'NEW';
|
|
9
|
-
type
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
18
|
+
export type AttributeConditionValue = string | number | boolean;
|
|
19
|
+
export type AttributeConditionRule = [{
|
|
20
|
+
var: string;
|
|
21
|
+
}, AttributeConditionValue];
|
|
22
|
+
export type AttributeConditions = {
|
|
23
|
+
visible?: Record<string, AttributeConditionRule>;
|
|
13
24
|
};
|
|
14
25
|
export type Base = {
|
|
15
26
|
name: string;
|
|
16
27
|
status?: Status;
|
|
17
|
-
customField?:
|
|
18
|
-
conditions?:
|
|
19
|
-
visible?: Record<string, any>;
|
|
20
|
-
};
|
|
28
|
+
customField?: string;
|
|
29
|
+
conditions?: AttributeConditions;
|
|
21
30
|
};
|
|
22
31
|
export type Relation = Base & {
|
|
23
32
|
type: 'relation';
|
|
@@ -26,7 +35,7 @@ export type Relation = Base & {
|
|
|
26
35
|
targetAttribute?: string | null;
|
|
27
36
|
configurable?: boolean;
|
|
28
37
|
private?: boolean;
|
|
29
|
-
pluginOptions?: Record<string,
|
|
38
|
+
pluginOptions?: Record<string, unknown>;
|
|
30
39
|
};
|
|
31
40
|
export type Media = Base & {
|
|
32
41
|
type: 'media';
|
|
@@ -35,7 +44,7 @@ export type Media = Base & {
|
|
|
35
44
|
configurable?: boolean;
|
|
36
45
|
private?: boolean;
|
|
37
46
|
allowedTypes?: string[];
|
|
38
|
-
pluginOptions?: Record<string,
|
|
47
|
+
pluginOptions?: Record<string, unknown>;
|
|
39
48
|
};
|
|
40
49
|
export type AnyAttribute = Base & (Schema.Attribute.BigInteger | Schema.Attribute.Boolean | Schema.Attribute.Blocks | Schema.Attribute.Component<UID.Component, boolean> | Schema.Attribute.DateTime | Schema.Attribute.Date | Schema.Attribute.Decimal | Schema.Attribute.DynamicZone | Schema.Attribute.Email | Schema.Attribute.Enumeration<string[]> | Schema.Attribute.Float | Schema.Attribute.Integer | Schema.Attribute.JSON | Schema.Attribute.Password | Schema.Attribute.RichText | Schema.Attribute.String | Schema.Attribute.Text | Schema.Attribute.Time | Schema.Attribute.Timestamp | Schema.Attribute.UID | Media | Relation);
|
|
41
50
|
export type Component = Omit<Struct.ComponentSchema, 'attributes'> & {
|
|
@@ -51,4 +60,3 @@ export type ContentType = Omit<Struct.ContentTypeSchema, 'attributes'> & {
|
|
|
51
60
|
};
|
|
52
61
|
export type Components = Record<string, Component>;
|
|
53
62
|
export type ContentTypes = Record<string, ContentType>;
|
|
54
|
-
export {};
|
|
@@ -1,17 +1,26 @@
|
|
|
1
|
-
import type { AnyAttribute } from '../types';
|
|
1
|
+
import type { AnyAttribute, AttributeConditionValue, AttributeConditions, ContentTypes } from '../types';
|
|
2
2
|
interface DependentRow {
|
|
3
3
|
contentTypeUid: string;
|
|
4
4
|
contentType: string;
|
|
5
5
|
attribute: string;
|
|
6
6
|
}
|
|
7
|
-
|
|
8
|
-
|
|
7
|
+
type VisibleConditionEntry = {
|
|
8
|
+
operator: string;
|
|
9
|
+
fieldVar: {
|
|
10
|
+
var: string;
|
|
11
|
+
};
|
|
12
|
+
value: AttributeConditionValue;
|
|
13
|
+
};
|
|
14
|
+
export declare const getVisibleConditionEntries: (condition?: AttributeConditions | null) => VisibleConditionEntry[];
|
|
15
|
+
export declare const getFirstVisibleConditionEntry: (condition?: AttributeConditions | null) => VisibleConditionEntry;
|
|
16
|
+
export declare const checkDependentRows: (contentTypes: ContentTypes, fieldName: string) => DependentRow[];
|
|
17
|
+
export declare const formatCondition: (condition: AttributeConditions, availableFields: Array<{
|
|
9
18
|
name: string;
|
|
10
19
|
type: string;
|
|
11
20
|
}>, attributeName: string) => string;
|
|
12
21
|
export declare const getAvailableConditionFields: (attributes: AnyAttribute[], currentFieldName: string) => {
|
|
13
22
|
name: string;
|
|
14
|
-
type: "string" | "boolean" | "time" | "text" | "media" | "date" | "email" | "password" | "decimal" | "
|
|
23
|
+
type: "string" | "boolean" | "time" | "text" | "media" | "date" | "email" | "password" | "decimal" | "relation" | "biginteger" | "blocks" | "component" | "datetime" | "dynamiczone" | "enumeration" | "float" | "integer" | "json" | "richtext" | "timestamp" | "uid";
|
|
15
24
|
enum: string[] | undefined;
|
|
16
25
|
}[];
|
|
17
26
|
export {};
|
|
@@ -1,43 +1,48 @@
|
|
|
1
|
-
|
|
1
|
+
import * as yup from 'yup';
|
|
2
|
+
type YupObjectShape = Parameters<ReturnType<typeof yup.object>['shape']>[0];
|
|
3
|
+
type YupObjectSchema = ReturnType<typeof yup.object>;
|
|
4
|
+
type FormSection = unknown;
|
|
5
|
+
type FormExtensionHandler = (props?: unknown) => FormSection[];
|
|
6
|
+
type FormValidator = (args: unknown[]) => YupObjectShape;
|
|
7
|
+
type ContentTypeSchemaMutation = (data: Record<string, unknown>, initialData: Record<string, unknown>) => Record<string, unknown>;
|
|
8
|
+
type ExtensionForm = {
|
|
9
|
+
advanced: FormExtensionHandler[];
|
|
10
|
+
base: FormExtensionHandler[];
|
|
11
|
+
};
|
|
12
|
+
type ExtensionDefinition = {
|
|
13
|
+
validators: FormValidator[];
|
|
14
|
+
form: ExtensionForm;
|
|
15
|
+
};
|
|
16
|
+
type ExtensionInput = {
|
|
17
|
+
validator?: FormValidator;
|
|
18
|
+
form: {
|
|
19
|
+
advanced: FormExtensionHandler;
|
|
20
|
+
base: FormExtensionHandler;
|
|
21
|
+
};
|
|
22
|
+
};
|
|
23
|
+
export type FormAPI = {
|
|
2
24
|
components: {
|
|
3
|
-
inputs: Record<string,
|
|
25
|
+
inputs: Record<string, unknown>;
|
|
4
26
|
add: ({ id, component }: {
|
|
5
27
|
id: string;
|
|
6
|
-
component:
|
|
28
|
+
component: unknown;
|
|
7
29
|
}) => void;
|
|
8
30
|
};
|
|
9
31
|
types: {
|
|
10
32
|
attribute: {
|
|
11
|
-
[key: string]:
|
|
12
|
-
validators: any[];
|
|
13
|
-
form: {
|
|
14
|
-
advanced: any[];
|
|
15
|
-
base: any[];
|
|
16
|
-
};
|
|
17
|
-
};
|
|
18
|
-
};
|
|
19
|
-
contentType: {
|
|
20
|
-
validators: any[];
|
|
21
|
-
form: {
|
|
22
|
-
advanced: any[];
|
|
23
|
-
base: any[];
|
|
24
|
-
};
|
|
25
|
-
};
|
|
26
|
-
component: {
|
|
27
|
-
validators: any[];
|
|
28
|
-
form: {
|
|
29
|
-
advanced: any[];
|
|
30
|
-
base: any[];
|
|
31
|
-
};
|
|
33
|
+
[key: string]: ExtensionDefinition;
|
|
32
34
|
};
|
|
35
|
+
contentType: ExtensionDefinition;
|
|
36
|
+
component: ExtensionDefinition;
|
|
33
37
|
};
|
|
34
|
-
contentTypeSchemaMutations:
|
|
35
|
-
addContentTypeSchemaMutation: (cb:
|
|
36
|
-
extendContentType: (data:
|
|
37
|
-
extendFields: (fields:
|
|
38
|
-
getAdvancedForm: (target:
|
|
39
|
-
makeCustomFieldValidator: (attributeShape:
|
|
40
|
-
makeValidator: (target:
|
|
41
|
-
mutateContentTypeSchema: (data: Record<string, unknown>, initialData: Record<string, unknown>) =>
|
|
42
|
-
}
|
|
38
|
+
contentTypeSchemaMutations: ContentTypeSchemaMutation[];
|
|
39
|
+
addContentTypeSchemaMutation: (cb: ContentTypeSchemaMutation) => void;
|
|
40
|
+
extendContentType: (data: ExtensionInput) => void;
|
|
41
|
+
extendFields: (fields: string[], data: ExtensionInput) => void;
|
|
42
|
+
getAdvancedForm: (target: string[], props?: unknown) => FormSection[];
|
|
43
|
+
makeCustomFieldValidator: (attributeShape: YupObjectSchema, validator: FormValidator | undefined, ...validatorArgs: unknown[]) => YupObjectSchema;
|
|
44
|
+
makeValidator: (target: string[], initShape: YupObjectSchema, ...args: unknown[]) => YupObjectSchema;
|
|
45
|
+
mutateContentTypeSchema: (data: Record<string, unknown>, initialData: Record<string, unknown>) => Record<string, unknown>;
|
|
46
|
+
};
|
|
43
47
|
export declare const formsAPI: FormAPI;
|
|
48
|
+
export {};
|
|
@@ -3,4 +3,4 @@ import type { Schema } from '@strapi/types';
|
|
|
3
3
|
*
|
|
4
4
|
* Retrieves the relation type
|
|
5
5
|
*/
|
|
6
|
-
export declare const getRelationType: (relation
|
|
6
|
+
export declare const getRelationType: (relation?: Schema.Attribute.RelationKind.Any, targetAttribute?: string | null) => "oneToOne" | "oneToMany" | "manyToOne" | "manyToMany" | Schema.Attribute.RelationKind.Morph | "oneWay" | "manyWay" | undefined;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const parseNumberInputValue: (value: string | number | null | undefined) => number;
|
|
@@ -230,7 +230,70 @@ var ko = {
|
|
|
230
230
|
"chat.code-upload.title": "Next.js 애플리케이션 가져오기",
|
|
231
231
|
"chat.code-upload.description": "AI가 애플리케이션을 분석합니다. 가져오기 전에 모든 민감한 데이터를 제거해주세요.",
|
|
232
232
|
"chat.code-upload.drop-zone": ".zip 파일을 여기에 놓거나",
|
|
233
|
-
"chat.code-upload.drop-zone-browse": "파일 찾아보기"
|
|
233
|
+
"chat.code-upload.drop-zone-browse": "파일 찾아보기",
|
|
234
|
+
"media.multiple": "다중",
|
|
235
|
+
"error.category.format": "카테고리 이름은 문자로 시작해야 하며, 문자, 숫자, 대시(-), 밑줄(_)만 포함할 수 있습니다.",
|
|
236
|
+
"form.attribute.item.maximumComponents": "최대 컴포넌트 수",
|
|
237
|
+
"form.attribute.item.minimumComponents": "최소 컴포넌트 수",
|
|
238
|
+
"form.attribute.item.uniqueField.v5.willBeDisabled'": "현재 컴포넌트에서는 고유 필드가 올바르게 작동하지 않습니다. 이 기능을 비활성화하면 문제가 해결될 때까지 필드가 비활성화됩니다.",
|
|
239
|
+
"form.attribute.condition.title": "조건",
|
|
240
|
+
"form.attribute.condition.description": "다른 불리언 또는 열거형 필드의 값에 따라 필드 설정을 전환합니다.",
|
|
241
|
+
"form.attribute.condition.label": "조건",
|
|
242
|
+
"form.attribute.condition.field": "필드",
|
|
243
|
+
"form.attribute.condition.operator": "연산자",
|
|
244
|
+
"form.attribute.condition.value": "값",
|
|
245
|
+
"form.attribute.condition.operator.is": "다음과 같음",
|
|
246
|
+
"form.attribute.condition.operator.isNot": "다음과 같지 않음",
|
|
247
|
+
"form.attribute.condition.value.true": "참",
|
|
248
|
+
"form.attribute.condition.value.false": "거짓",
|
|
249
|
+
"form.attribute.condition.apply": "조건 적용",
|
|
250
|
+
"form.attribute.condition.then": "그러면",
|
|
251
|
+
"form.attribute.condition.action": "동작",
|
|
252
|
+
"form.attribute.condition.action.show": "표시",
|
|
253
|
+
"form.attribute.condition.action.hide": "숨기기",
|
|
254
|
+
"form.attribute.condition.no-fields": "조건을 설정할 수 있는 불리언 또는 열거형 필드가 없습니다.",
|
|
255
|
+
"form.attribute.condition.enum-change-warning": "다음 필드에 이 필드에 의존하는 조건이 있습니다: {fieldNames}. 열거형 값 {values}을(를) 변경하거나 삭제하면 이 조건들이 깨집니다. 계속하시겠습니까?",
|
|
256
|
+
"form.attribute.condition.enum-change-warning-values": ". 열거형 값 ",
|
|
257
|
+
"form.attribute.condition.enum-change-warning-end": "을(를) 변경하거나 삭제하면 이 조건들이 깨집니다. 계속하시겠습니까?",
|
|
258
|
+
"form.attribute.condition.field-change-warning": "다음 필드에 이 필드에 의존하는 조건이 있습니다: {fieldNames}. 이름을 변경하면 이 조건들이 깨집니다. 계속하시겠습니까?",
|
|
259
|
+
"form.attribute.condition.field-change-warning-end": ". 이름을 변경하면 이 조건들이 깨집니다. 계속하시겠습니까?",
|
|
260
|
+
"form.button.submit": "제출",
|
|
261
|
+
"modalForm.header.categories": "카테고리",
|
|
262
|
+
"modalForm.header.back": "뒤로",
|
|
263
|
+
"modelPage.attribute.with": "함께",
|
|
264
|
+
"popUpWarning.discardAll.message": "모든 변경 사항을 취소하시겠습니까?",
|
|
265
|
+
"popUpWarning.bodyMessage.delete-condition": "이 조건을 삭제하시겠습니까?",
|
|
266
|
+
"popUpWarning.bodyMessage.delete-attribute-with-conditions": "다음 필드에 이 필드에 의존하는 조건이 있습니다: ",
|
|
267
|
+
"popUpWarning.bodyMessage.delete-attribute-with-conditions-end": ". 그래도 삭제하시겠습니까?",
|
|
268
|
+
"table.content.create-first-content-type.import-code": "컴퓨터에서 가져오기",
|
|
269
|
+
"chat.tooltips.upload-attachments": "첨부 파일 업로드",
|
|
270
|
+
"chat.messages.too-many-requests": "요청이 너무 많습니다. 잠시 후 다시 시도해주세요.",
|
|
271
|
+
"chat.messages.license-limit-reached": "라이선스 한도에 도달했습니다. 내일 다시 시도해주세요.",
|
|
272
|
+
"chat.messages.license-limit-exceeded": "AI 크레딧 한도를 초과했습니다.",
|
|
273
|
+
"chat.messages.too-long-error": "이 대화가 최대 길이에 도달했습니다. 새 대화를 시작해주세요",
|
|
274
|
+
"chat.code-upload.drop-zone-folder": "여기에 폴더를 놓거나",
|
|
275
|
+
"chat.attachments.menu.import-code": "코드 가져오기",
|
|
276
|
+
"chat.attachments.menu.attach-image": "이미지 첨부",
|
|
277
|
+
"chat.attachments.menu.import-figma": "Figma에서 가져오기",
|
|
278
|
+
"chat.feedback.title": "피드백 남기기",
|
|
279
|
+
"chat.feedback.subtitle": "이 메시지에 대한 추가 피드백을 제공해주세요. 해당하는 항목을 모두 선택하세요.",
|
|
280
|
+
"chat.feedback.comment.label": "어떻게 개선하면 좋을까요? (선택 사항)",
|
|
281
|
+
"chat.feedback.placeholder": "피드백을 입력하세요...",
|
|
282
|
+
"chat.feedback.submitted": "피드백을 보내주셔서 감사합니다!",
|
|
283
|
+
"chat.feedback.error": "피드백을 제출하는 중 오류가 발생했습니다",
|
|
284
|
+
"chat.feedback.reason.invalid_schema": "잘못된 스키마",
|
|
285
|
+
"chat.feedback.reason.bad_recommendation": "잘못된 추천",
|
|
286
|
+
"chat.feedback.reason.slow": "느림",
|
|
287
|
+
"chat.feedback.reason.instructions_ignored": "지시 사항 무시됨",
|
|
288
|
+
"chat.feedback.reason.being_lazy": "성의 없는 답변",
|
|
289
|
+
"chat.feedback.reason.other": "기타",
|
|
290
|
+
"chat.figma-upload.step1-title": "Figma URL 입력",
|
|
291
|
+
"chat.figma-upload.step2-title": "이미지 미리보기",
|
|
292
|
+
"chat.figma-upload.select-images": "가져올 프레임 선택",
|
|
293
|
+
"chat.figma-upload.no-images": "Figma 파일에서 프레임을 찾을 수 없습니다.",
|
|
294
|
+
"chat.figma-upload.import-button": "가져오기",
|
|
295
|
+
"form.button.finish": "완료",
|
|
296
|
+
"form.button.back": "뒤로"
|
|
234
297
|
};
|
|
235
298
|
|
|
236
299
|
exports.configurations = configurations;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ko.json.js","sources":[],"sourcesContent":[],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"ko.json.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|