@strapi/content-type-builder 5.50.1 → 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.
Files changed (26) hide show
  1. package/dist/admin/src/components/DataManager/utils/cleanData.d.ts +34 -34
  2. package/dist/admin/translations/ko.json.js +64 -1
  3. package/dist/admin/translations/ko.json.js.map +1 -1
  4. package/dist/admin/translations/ko.json.mjs +64 -1
  5. package/dist/admin/translations/ko.json.mjs.map +1 -1
  6. package/dist/server/controllers/validation/schema.js +37 -1
  7. package/dist/server/controllers/validation/schema.js.map +1 -1
  8. package/dist/server/controllers/validation/schema.mjs +38 -3
  9. package/dist/server/controllers/validation/schema.mjs.map +1 -1
  10. package/dist/server/services/builder.js +11 -66
  11. package/dist/server/services/builder.js.map +1 -1
  12. package/dist/server/services/builder.mjs +11 -66
  13. package/dist/server/services/builder.mjs.map +1 -1
  14. package/dist/server/src/controllers/validation/schema.d.ts +10 -0
  15. package/dist/server/src/controllers/validation/schema.d.ts.map +1 -1
  16. package/dist/server/src/index.d.ts +3 -3
  17. package/dist/server/src/routes/index.d.ts +1 -1
  18. package/dist/server/src/services/builder.d.ts +7 -0
  19. package/dist/server/src/services/builder.d.ts.map +1 -1
  20. package/dist/server/src/services/schema-builder/component-builder.d.ts +4 -4
  21. package/dist/server/src/services/schema-builder/content-type-builder.d.ts +4 -4
  22. package/dist/server/src/services/schema-builder/index.d.ts +18 -18
  23. package/dist/server/src/services/schema.d.ts +75 -75
  24. package/dist/server/src/utils/attributes.d.ts +2 -2
  25. package/dist/server/src/utils/attributes.d.ts.map +1 -1
  26. package/package.json +16 -12
@@ -1,78 +1,23 @@
1
1
  'use strict';
2
2
 
3
- var fp = require('lodash/fp');
3
+ var utils = require('@strapi/utils');
4
4
 
5
- // use snake_case
6
- const reservedAttributes = [
7
- // TODO: these need to come from a centralized place so we don't break things accidentally in the future and can share them outside the CTB, for example on Strapi bootstrap prior to schema db sync
8
- // ID fields
9
- 'id',
10
- 'document_id',
11
- // Creator fields
12
- 'created_at',
13
- 'updated_at',
14
- 'published_at',
15
- // V6: we will need to add first_published_at when it becomes the default behaviour
16
- 'created_by_id',
17
- 'updated_by_id',
18
- // does not actually conflict because the fields are called *_by_id but we'll leave it to avoid confusion
19
- 'created_by',
20
- 'updated_by',
21
- // Used for Strapi functionality
22
- 'entry_id',
23
- 'status',
24
- 'localizations',
25
- 'meta',
26
- 'locale',
27
- '__component',
28
- '__contentType',
29
- // We support ending with * to denote prefixes
30
- 'strapi*',
31
- '_strapi*',
32
- '__strapi*'
33
- ];
34
- // use snake_case
35
- const reservedModels = [
36
- 'boolean',
37
- 'date',
38
- 'date_time',
39
- 'time',
40
- 'upload',
41
- 'document',
42
- 'then',
43
- // We support ending with * to denote prefixes
44
- 'strapi*',
45
- '_strapi*',
46
- '__strapi*'
47
- ];
5
+ /**
6
+ * Reserved names are centralised in `@strapi/utils` so the bootstrap validator,
7
+ * the schema-to-model transform and this CTB service all share a single source.
8
+ *
9
+ * The arrays exported here are kept for backwards compatibility with consumers
10
+ * that import them directly. New call sites should import from `@strapi/utils`.
11
+ */ const reservedAttributes = utils.contentTypes.getReservedAttributeNames();
12
+ const reservedModels = utils.contentTypes.getReservedModelNames();
48
13
  const getReservedNames = ()=>{
49
14
  return {
50
15
  models: reservedModels,
51
16
  attributes: reservedAttributes
52
17
  };
53
18
  };
54
- // compare snake case to check the actual column names that will be used in the database
55
- const isReservedModelName = (name)=>{
56
- const snakeCaseName = fp.snakeCase(name);
57
- if (reservedModels.includes(snakeCaseName)) {
58
- return true;
59
- }
60
- if (reservedModels.filter((key)=>key.endsWith('*')).map((key)=>key.slice(0, -1)).some((prefix)=>snakeCaseName.startsWith(prefix))) {
61
- return true;
62
- }
63
- return false;
64
- };
65
- // compare snake case to check the actual column names that will be used in the database
66
- const isReservedAttributeName = (name)=>{
67
- const snakeCaseName = fp.snakeCase(name);
68
- if (reservedAttributes.includes(snakeCaseName)) {
69
- return true;
70
- }
71
- if (reservedAttributes.filter((key)=>key.endsWith('*')).map((key)=>key.slice(0, -1)).some((prefix)=>snakeCaseName.startsWith(prefix))) {
72
- return true;
73
- }
74
- return false;
75
- };
19
+ const isReservedModelName = (name)=>utils.contentTypes.isReservedModelName(name);
20
+ const isReservedAttributeName = (name)=>utils.contentTypes.isReservedAttributeName(name);
76
21
 
77
22
  exports.getReservedNames = getReservedNames;
78
23
  exports.isReservedAttributeName = isReservedAttributeName;
@@ -1 +1 @@
1
- {"version":3,"file":"builder.js","sources":["../../../server/src/services/builder.ts"],"sourcesContent":["import { snakeCase } from 'lodash/fp';\n\n// use snake_case\nexport const reservedAttributes = [\n // TODO: these need to come from a centralized place so we don't break things accidentally in the future and can share them outside the CTB, for example on Strapi bootstrap prior to schema db sync\n\n // ID fields\n 'id',\n 'document_id',\n\n // Creator fields\n 'created_at',\n 'updated_at',\n 'published_at',\n // V6: we will need to add first_published_at when it becomes the default behaviour\n 'created_by_id',\n 'updated_by_id',\n // does not actually conflict because the fields are called *_by_id but we'll leave it to avoid confusion\n 'created_by',\n 'updated_by',\n\n // Used for Strapi functionality\n 'entry_id',\n 'status',\n 'localizations',\n 'meta',\n 'locale',\n '__component',\n '__contentType',\n\n // We support ending with * to denote prefixes\n 'strapi*',\n '_strapi*',\n '__strapi*',\n];\n\n// use snake_case\nexport const reservedModels = [\n 'boolean',\n 'date',\n 'date_time',\n 'time',\n 'upload',\n 'document',\n 'then', // no longer an issue but still restricting for being a javascript keyword\n\n // We support ending with * to denote prefixes\n 'strapi*',\n '_strapi*',\n '__strapi*',\n];\n\nexport const getReservedNames = () => {\n return {\n models: reservedModels,\n attributes: reservedAttributes,\n };\n};\n\n// compare snake case to check the actual column names that will be used in the database\nexport const isReservedModelName = (name: string) => {\n const snakeCaseName = snakeCase(name);\n if (reservedModels.includes(snakeCaseName)) {\n return true;\n }\n\n if (\n reservedModels\n .filter((key) => key.endsWith('*'))\n .map((key) => key.slice(0, -1))\n .some((prefix) => snakeCaseName.startsWith(prefix))\n ) {\n return true;\n }\n\n return false;\n};\n\n// compare snake case to check the actual column names that will be used in the database\nexport const isReservedAttributeName = (name: string) => {\n const snakeCaseName = snakeCase(name);\n if (reservedAttributes.includes(snakeCaseName)) {\n return true;\n }\n\n if (\n reservedAttributes\n .filter((key) => key.endsWith('*'))\n .map((key) => key.slice(0, -1))\n .some((prefix) => snakeCaseName.startsWith(prefix))\n ) {\n return true;\n }\n\n return false;\n};\n"],"names":["reservedAttributes","reservedModels","getReservedNames","models","attributes","isReservedModelName","name","snakeCaseName","snakeCase","includes","filter","key","endsWith","map","slice","some","prefix","startsWith","isReservedAttributeName"],"mappings":";;;;AAEA;MACaA,kBAAAA,GAAqB;;;AAIhC,IAAA,IAAA;AACA,IAAA,aAAA;;AAGA,IAAA,YAAA;AACA,IAAA,YAAA;AACA,IAAA,cAAA;;AAEA,IAAA,eAAA;AACA,IAAA,eAAA;;AAEA,IAAA,YAAA;AACA,IAAA,YAAA;;AAGA,IAAA,UAAA;AACA,IAAA,QAAA;AACA,IAAA,eAAA;AACA,IAAA,MAAA;AACA,IAAA,QAAA;AACA,IAAA,aAAA;AACA,IAAA,eAAA;;AAGA,IAAA,SAAA;AACA,IAAA,UAAA;AACA,IAAA;;AAGF;MACaC,cAAAA,GAAiB;AAC5B,IAAA,SAAA;AACA,IAAA,MAAA;AACA,IAAA,WAAA;AACA,IAAA,MAAA;AACA,IAAA,QAAA;AACA,IAAA,UAAA;AACA,IAAA,MAAA;;AAGA,IAAA,SAAA;AACA,IAAA,UAAA;AACA,IAAA;;MAGWC,gBAAAA,GAAmB,IAAA;IAC9B,OAAO;QACLC,MAAAA,EAAQF,cAAAA;QACRG,UAAAA,EAAYJ;AACd,KAAA;AACF;AAEA;AACO,MAAMK,sBAAsB,CAACC,IAAAA,GAAAA;AAClC,IAAA,MAAMC,gBAAgBC,YAAAA,CAAUF,IAAAA,CAAAA;IAChC,IAAIL,cAAAA,CAAeQ,QAAQ,CAACF,aAAAA,CAAAA,EAAgB;QAC1C,OAAO,IAAA;AACT,IAAA;IAEA,IACEN,cAAAA,CACGS,MAAM,CAAC,CAACC,GAAAA,GAAQA,GAAAA,CAAIC,QAAQ,CAAC,GAAA,CAAA,CAAA,CAC7BC,GAAG,CAAC,CAACF,GAAAA,GAAQA,IAAIG,KAAK,CAAC,CAAA,EAAG,EAAC,CAAA,CAAA,CAC3BC,IAAI,CAAC,CAACC,MAAAA,GAAWT,aAAAA,CAAcU,UAAU,CAACD,MAAAA,CAAAA,CAAAA,EAC7C;QACA,OAAO,IAAA;AACT,IAAA;IAEA,OAAO,KAAA;AACT;AAEA;AACO,MAAME,0BAA0B,CAACZ,IAAAA,GAAAA;AACtC,IAAA,MAAMC,gBAAgBC,YAAAA,CAAUF,IAAAA,CAAAA;IAChC,IAAIN,kBAAAA,CAAmBS,QAAQ,CAACF,aAAAA,CAAAA,EAAgB;QAC9C,OAAO,IAAA;AACT,IAAA;IAEA,IACEP,kBAAAA,CACGU,MAAM,CAAC,CAACC,GAAAA,GAAQA,GAAAA,CAAIC,QAAQ,CAAC,GAAA,CAAA,CAAA,CAC7BC,GAAG,CAAC,CAACF,GAAAA,GAAQA,IAAIG,KAAK,CAAC,CAAA,EAAG,EAAC,CAAA,CAAA,CAC3BC,IAAI,CAAC,CAACC,MAAAA,GAAWT,aAAAA,CAAcU,UAAU,CAACD,MAAAA,CAAAA,CAAAA,EAC7C;QACA,OAAO,IAAA;AACT,IAAA;IAEA,OAAO,KAAA;AACT;;;;;;;;"}
1
+ {"version":3,"file":"builder.js","sources":["../../../server/src/services/builder.ts"],"sourcesContent":["import { contentTypes } from '@strapi/utils';\n\n/**\n * Reserved names are centralised in `@strapi/utils` so the bootstrap validator,\n * the schema-to-model transform and this CTB service all share a single source.\n *\n * The arrays exported here are kept for backwards compatibility with consumers\n * that import them directly. New call sites should import from `@strapi/utils`.\n */\nexport const reservedAttributes = contentTypes.getReservedAttributeNames();\nexport const reservedModels = contentTypes.getReservedModelNames();\n\nexport const getReservedNames = () => {\n return {\n models: reservedModels,\n attributes: reservedAttributes,\n };\n};\n\nexport const isReservedModelName = (name: string): boolean =>\n contentTypes.isReservedModelName(name);\n\nexport const isReservedAttributeName = (name: string): boolean =>\n contentTypes.isReservedAttributeName(name);\n"],"names":["reservedAttributes","contentTypes","getReservedAttributeNames","reservedModels","getReservedModelNames","getReservedNames","models","attributes","isReservedModelName","name","isReservedAttributeName"],"mappings":";;;;AAEA;;;;;;AAMC,IACM,MAAMA,kBAAAA,GAAqBC,kBAAAA,CAAaC,yBAAyB;AACjE,MAAMC,cAAAA,GAAiBF,kBAAAA,CAAaG,qBAAqB;MAEnDC,gBAAAA,GAAmB,IAAA;IAC9B,OAAO;QACLC,MAAAA,EAAQH,cAAAA;QACRI,UAAAA,EAAYP;AACd,KAAA;AACF;MAEaQ,mBAAAA,GAAsB,CAACC,OAClCR,kBAAAA,CAAaO,mBAAmB,CAACC,IAAAA;MAEtBC,uBAAAA,GAA0B,CAACD,OACtCR,kBAAAA,CAAaS,uBAAuB,CAACD,IAAAA;;;;;;;;"}
@@ -1,76 +1,21 @@
1
- import { snakeCase } from 'lodash/fp';
1
+ import { contentTypes } from '@strapi/utils';
2
2
 
3
- // use snake_case
4
- const reservedAttributes = [
5
- // TODO: these need to come from a centralized place so we don't break things accidentally in the future and can share them outside the CTB, for example on Strapi bootstrap prior to schema db sync
6
- // ID fields
7
- 'id',
8
- 'document_id',
9
- // Creator fields
10
- 'created_at',
11
- 'updated_at',
12
- 'published_at',
13
- // V6: we will need to add first_published_at when it becomes the default behaviour
14
- 'created_by_id',
15
- 'updated_by_id',
16
- // does not actually conflict because the fields are called *_by_id but we'll leave it to avoid confusion
17
- 'created_by',
18
- 'updated_by',
19
- // Used for Strapi functionality
20
- 'entry_id',
21
- 'status',
22
- 'localizations',
23
- 'meta',
24
- 'locale',
25
- '__component',
26
- '__contentType',
27
- // We support ending with * to denote prefixes
28
- 'strapi*',
29
- '_strapi*',
30
- '__strapi*'
31
- ];
32
- // use snake_case
33
- const reservedModels = [
34
- 'boolean',
35
- 'date',
36
- 'date_time',
37
- 'time',
38
- 'upload',
39
- 'document',
40
- 'then',
41
- // We support ending with * to denote prefixes
42
- 'strapi*',
43
- '_strapi*',
44
- '__strapi*'
45
- ];
3
+ /**
4
+ * Reserved names are centralised in `@strapi/utils` so the bootstrap validator,
5
+ * the schema-to-model transform and this CTB service all share a single source.
6
+ *
7
+ * The arrays exported here are kept for backwards compatibility with consumers
8
+ * that import them directly. New call sites should import from `@strapi/utils`.
9
+ */ const reservedAttributes = contentTypes.getReservedAttributeNames();
10
+ const reservedModels = contentTypes.getReservedModelNames();
46
11
  const getReservedNames = ()=>{
47
12
  return {
48
13
  models: reservedModels,
49
14
  attributes: reservedAttributes
50
15
  };
51
16
  };
52
- // compare snake case to check the actual column names that will be used in the database
53
- const isReservedModelName = (name)=>{
54
- const snakeCaseName = snakeCase(name);
55
- if (reservedModels.includes(snakeCaseName)) {
56
- return true;
57
- }
58
- if (reservedModels.filter((key)=>key.endsWith('*')).map((key)=>key.slice(0, -1)).some((prefix)=>snakeCaseName.startsWith(prefix))) {
59
- return true;
60
- }
61
- return false;
62
- };
63
- // compare snake case to check the actual column names that will be used in the database
64
- const isReservedAttributeName = (name)=>{
65
- const snakeCaseName = snakeCase(name);
66
- if (reservedAttributes.includes(snakeCaseName)) {
67
- return true;
68
- }
69
- if (reservedAttributes.filter((key)=>key.endsWith('*')).map((key)=>key.slice(0, -1)).some((prefix)=>snakeCaseName.startsWith(prefix))) {
70
- return true;
71
- }
72
- return false;
73
- };
17
+ const isReservedModelName = (name)=>contentTypes.isReservedModelName(name);
18
+ const isReservedAttributeName = (name)=>contentTypes.isReservedAttributeName(name);
74
19
 
75
20
  export { getReservedNames, isReservedAttributeName, isReservedModelName, reservedAttributes, reservedModels };
76
21
  //# sourceMappingURL=builder.mjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"builder.mjs","sources":["../../../server/src/services/builder.ts"],"sourcesContent":["import { snakeCase } from 'lodash/fp';\n\n// use snake_case\nexport const reservedAttributes = [\n // TODO: these need to come from a centralized place so we don't break things accidentally in the future and can share them outside the CTB, for example on Strapi bootstrap prior to schema db sync\n\n // ID fields\n 'id',\n 'document_id',\n\n // Creator fields\n 'created_at',\n 'updated_at',\n 'published_at',\n // V6: we will need to add first_published_at when it becomes the default behaviour\n 'created_by_id',\n 'updated_by_id',\n // does not actually conflict because the fields are called *_by_id but we'll leave it to avoid confusion\n 'created_by',\n 'updated_by',\n\n // Used for Strapi functionality\n 'entry_id',\n 'status',\n 'localizations',\n 'meta',\n 'locale',\n '__component',\n '__contentType',\n\n // We support ending with * to denote prefixes\n 'strapi*',\n '_strapi*',\n '__strapi*',\n];\n\n// use snake_case\nexport const reservedModels = [\n 'boolean',\n 'date',\n 'date_time',\n 'time',\n 'upload',\n 'document',\n 'then', // no longer an issue but still restricting for being a javascript keyword\n\n // We support ending with * to denote prefixes\n 'strapi*',\n '_strapi*',\n '__strapi*',\n];\n\nexport const getReservedNames = () => {\n return {\n models: reservedModels,\n attributes: reservedAttributes,\n };\n};\n\n// compare snake case to check the actual column names that will be used in the database\nexport const isReservedModelName = (name: string) => {\n const snakeCaseName = snakeCase(name);\n if (reservedModels.includes(snakeCaseName)) {\n return true;\n }\n\n if (\n reservedModels\n .filter((key) => key.endsWith('*'))\n .map((key) => key.slice(0, -1))\n .some((prefix) => snakeCaseName.startsWith(prefix))\n ) {\n return true;\n }\n\n return false;\n};\n\n// compare snake case to check the actual column names that will be used in the database\nexport const isReservedAttributeName = (name: string) => {\n const snakeCaseName = snakeCase(name);\n if (reservedAttributes.includes(snakeCaseName)) {\n return true;\n }\n\n if (\n reservedAttributes\n .filter((key) => key.endsWith('*'))\n .map((key) => key.slice(0, -1))\n .some((prefix) => snakeCaseName.startsWith(prefix))\n ) {\n return true;\n }\n\n return false;\n};\n"],"names":["reservedAttributes","reservedModels","getReservedNames","models","attributes","isReservedModelName","name","snakeCaseName","snakeCase","includes","filter","key","endsWith","map","slice","some","prefix","startsWith","isReservedAttributeName"],"mappings":";;AAEA;MACaA,kBAAAA,GAAqB;;;AAIhC,IAAA,IAAA;AACA,IAAA,aAAA;;AAGA,IAAA,YAAA;AACA,IAAA,YAAA;AACA,IAAA,cAAA;;AAEA,IAAA,eAAA;AACA,IAAA,eAAA;;AAEA,IAAA,YAAA;AACA,IAAA,YAAA;;AAGA,IAAA,UAAA;AACA,IAAA,QAAA;AACA,IAAA,eAAA;AACA,IAAA,MAAA;AACA,IAAA,QAAA;AACA,IAAA,aAAA;AACA,IAAA,eAAA;;AAGA,IAAA,SAAA;AACA,IAAA,UAAA;AACA,IAAA;;AAGF;MACaC,cAAAA,GAAiB;AAC5B,IAAA,SAAA;AACA,IAAA,MAAA;AACA,IAAA,WAAA;AACA,IAAA,MAAA;AACA,IAAA,QAAA;AACA,IAAA,UAAA;AACA,IAAA,MAAA;;AAGA,IAAA,SAAA;AACA,IAAA,UAAA;AACA,IAAA;;MAGWC,gBAAAA,GAAmB,IAAA;IAC9B,OAAO;QACLC,MAAAA,EAAQF,cAAAA;QACRG,UAAAA,EAAYJ;AACd,KAAA;AACF;AAEA;AACO,MAAMK,sBAAsB,CAACC,IAAAA,GAAAA;AAClC,IAAA,MAAMC,gBAAgBC,SAAAA,CAAUF,IAAAA,CAAAA;IAChC,IAAIL,cAAAA,CAAeQ,QAAQ,CAACF,aAAAA,CAAAA,EAAgB;QAC1C,OAAO,IAAA;AACT,IAAA;IAEA,IACEN,cAAAA,CACGS,MAAM,CAAC,CAACC,GAAAA,GAAQA,GAAAA,CAAIC,QAAQ,CAAC,GAAA,CAAA,CAAA,CAC7BC,GAAG,CAAC,CAACF,GAAAA,GAAQA,IAAIG,KAAK,CAAC,CAAA,EAAG,EAAC,CAAA,CAAA,CAC3BC,IAAI,CAAC,CAACC,MAAAA,GAAWT,aAAAA,CAAcU,UAAU,CAACD,MAAAA,CAAAA,CAAAA,EAC7C;QACA,OAAO,IAAA;AACT,IAAA;IAEA,OAAO,KAAA;AACT;AAEA;AACO,MAAME,0BAA0B,CAACZ,IAAAA,GAAAA;AACtC,IAAA,MAAMC,gBAAgBC,SAAAA,CAAUF,IAAAA,CAAAA;IAChC,IAAIN,kBAAAA,CAAmBS,QAAQ,CAACF,aAAAA,CAAAA,EAAgB;QAC9C,OAAO,IAAA;AACT,IAAA;IAEA,IACEP,kBAAAA,CACGU,MAAM,CAAC,CAACC,GAAAA,GAAQA,GAAAA,CAAIC,QAAQ,CAAC,GAAA,CAAA,CAAA,CAC7BC,GAAG,CAAC,CAACF,GAAAA,GAAQA,IAAIG,KAAK,CAAC,CAAA,EAAG,EAAC,CAAA,CAAA,CAC3BC,IAAI,CAAC,CAACC,MAAAA,GAAWT,aAAAA,CAAcU,UAAU,CAACD,MAAAA,CAAAA,CAAAA,EAC7C;QACA,OAAO,IAAA;AACT,IAAA;IAEA,OAAO,KAAA;AACT;;;;"}
1
+ {"version":3,"file":"builder.mjs","sources":["../../../server/src/services/builder.ts"],"sourcesContent":["import { contentTypes } from '@strapi/utils';\n\n/**\n * Reserved names are centralised in `@strapi/utils` so the bootstrap validator,\n * the schema-to-model transform and this CTB service all share a single source.\n *\n * The arrays exported here are kept for backwards compatibility with consumers\n * that import them directly. New call sites should import from `@strapi/utils`.\n */\nexport const reservedAttributes = contentTypes.getReservedAttributeNames();\nexport const reservedModels = contentTypes.getReservedModelNames();\n\nexport const getReservedNames = () => {\n return {\n models: reservedModels,\n attributes: reservedAttributes,\n };\n};\n\nexport const isReservedModelName = (name: string): boolean =>\n contentTypes.isReservedModelName(name);\n\nexport const isReservedAttributeName = (name: string): boolean =>\n contentTypes.isReservedAttributeName(name);\n"],"names":["reservedAttributes","contentTypes","getReservedAttributeNames","reservedModels","getReservedModelNames","getReservedNames","models","attributes","isReservedModelName","name","isReservedAttributeName"],"mappings":";;AAEA;;;;;;AAMC,IACM,MAAMA,kBAAAA,GAAqBC,YAAAA,CAAaC,yBAAyB;AACjE,MAAMC,cAAAA,GAAiBF,YAAAA,CAAaG,qBAAqB;MAEnDC,gBAAAA,GAAmB,IAAA;IAC9B,OAAO;QACLC,MAAAA,EAAQH,cAAAA;QACRI,UAAAA,EAAYP;AACd,KAAA;AACF;MAEaQ,mBAAAA,GAAsB,CAACC,OAClCR,YAAAA,CAAaO,mBAAmB,CAACC,IAAAA;MAEtBC,uBAAAA,GAA0B,CAACD,OACtCR,YAAAA,CAAaS,uBAAuB,CAACD,IAAAA;;;;"}
@@ -1,5 +1,15 @@
1
1
  import { z } from 'zod';
2
2
  import type { UID } from '@strapi/types';
3
+ type ContentTypeSchemaAction = {
4
+ action: 'create' | 'update' | 'delete';
5
+ draftAndPublish?: boolean;
6
+ uid?: UID.ContentType;
7
+ attributes?: Array<{
8
+ action: 'create' | 'update' | 'delete';
9
+ name: string;
10
+ }>;
11
+ };
12
+ export declare const verifyDraftAndPublishReservedAttributes: z.SuperRefinement<ContentTypeSchemaAction>;
3
13
  export declare const maxLengthGreaterThanMinLength: z.SuperRefinement<Record<string, unknown>>;
4
14
  export declare const maxGreaterThanMin: z.SuperRefinement<Record<string, unknown>>;
5
15
  declare const createComponentSchema: z.ZodObject<{