@takeshape/schema 10.19.2 → 10.20.0

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 (79) hide show
  1. package/dist/migration/index.d.ts +1 -0
  2. package/dist/migration/index.d.ts.map +1 -1
  3. package/dist/migration/index.js +3 -1
  4. package/dist/migration/to/v3.41.0.d.ts +5 -0
  5. package/dist/migration/to/v3.41.0.d.ts.map +1 -0
  6. package/dist/migration/to/v3.41.0.js +16 -0
  7. package/dist/project-schema/index.d.ts +4 -1
  8. package/dist/project-schema/index.d.ts.map +1 -1
  9. package/dist/project-schema/index.js +17 -3
  10. package/dist/project-schema/latest.d.ts +2 -2
  11. package/dist/project-schema/latest.d.ts.map +1 -1
  12. package/dist/project-schema/migrate.d.ts.map +1 -1
  13. package/dist/project-schema/migrate.js +3 -0
  14. package/dist/project-schema/v3.40.0.d.ts +1 -1
  15. package/dist/project-schema/v3.40.0.d.ts.map +1 -1
  16. package/dist/project-schema/v3.41.0.d.ts +1531 -0
  17. package/dist/project-schema/v3.41.0.d.ts.map +1 -0
  18. package/dist/project-schema/v3.41.0.js +5 -0
  19. package/dist/schemas/index.d.ts +2 -2
  20. package/dist/schemas/index.d.ts.map +1 -1
  21. package/dist/schemas/index.js +5 -4
  22. package/dist/schemas/index.ts +4 -2
  23. package/dist/schemas/project-schema/latest.json +3 -2
  24. package/dist/schemas/project-schema/v3.40.0.json +1 -0
  25. package/dist/schemas/project-schema/v3.41.0.json +3222 -0
  26. package/dist/schemas/project-schema.json +3 -0
  27. package/es/migration/index.js +3 -1
  28. package/es/migration/to/v3.41.0.js +10 -0
  29. package/es/project-schema/index.js +3 -1
  30. package/es/project-schema/migrate.js +4 -1
  31. package/es/project-schema/v3.41.0.js +1 -0
  32. package/es/schemas/index.js +4 -3
  33. package/es/schemas/index.ts +4 -2
  34. package/es/schemas/project-schema/latest.json +3 -2
  35. package/es/schemas/project-schema/v3.40.0.json +1 -0
  36. package/es/schemas/project-schema/v3.41.0.json +3222 -0
  37. package/es/schemas/project-schema.json +3 -0
  38. package/examples/latest/all-fields-shapes-inline.json +1 -1
  39. package/examples/latest/all-fields-shapes.json +1 -1
  40. package/examples/latest/betzino.json +1 -1
  41. package/examples/latest/blog-schema.json +1 -1
  42. package/examples/latest/brewery-schema.json +1 -1
  43. package/examples/latest/clear-cache-schema.json +22 -8
  44. package/examples/latest/complex-project-schema.json +1 -1
  45. package/examples/latest/complex-schema.json +1 -1
  46. package/examples/latest/edit-schema.json +1 -1
  47. package/examples/latest/fabric-ecommerce.json +1 -1
  48. package/examples/latest/frank-and-fred-schema.json +1 -1
  49. package/examples/latest/klirr-schema.json +1 -1
  50. package/examples/latest/massive-schema.json +1 -1
  51. package/examples/latest/mill-components-schema.json +1 -1
  52. package/examples/latest/nested-shape-arrays.json +1 -1
  53. package/examples/latest/one-earth.json +1 -1
  54. package/examples/latest/pet-oneof-array.json +1 -1
  55. package/examples/latest/post-schema.json +1 -1
  56. package/examples/latest/pruned-shopify-product-schema.json +1 -1
  57. package/examples/latest/real-world-schema.json +1 -1
  58. package/examples/latest/recursive-repeater-schema.json +1 -1
  59. package/examples/latest/recursive-schema.json +1 -1
  60. package/examples/latest/rick-and-morty-ast.json +1 -1
  61. package/examples/latest/rick-and-morty-graphql.json +1 -1
  62. package/examples/latest/rick-and-morty-rest.json +1 -1
  63. package/examples/latest/schema-where-filter.json +1 -1
  64. package/examples/latest/schema-with-repeater-draftjs.json +1 -1
  65. package/examples/latest/schema-with-rick-and-morty.json +1 -1
  66. package/examples/latest/shape-books-v3_2_0.json +1 -1
  67. package/examples/latest/shape-books.json +1 -1
  68. package/examples/latest/shape-editor-schema-edited.json +1 -1
  69. package/examples/latest/shape-editor-schema-initial.json +1 -1
  70. package/examples/latest/shapedb-crud-every-prop-type.json +1 -1
  71. package/examples/latest/shopify-lookbook.json +1 -1
  72. package/examples/latest/shopify-product-2022-07.json +1 -1
  73. package/examples/latest/shopify-product-2023-04.json +1 -1
  74. package/examples/latest/shopify-store-with-widget.json +1 -1
  75. package/examples/latest/stripe-product-runtime-schema.json +1 -1
  76. package/examples/latest/stripe-starter-resolved.json +1 -1
  77. package/examples/latest/user-schema-no-required.json +1 -1
  78. package/examples/latest/user-schema-with-defaults.json +1 -1
  79. package/package.json +6 -6
@@ -150,6 +150,9 @@
150
150
  {
151
151
  "$ref": "https://schema.takeshape.io/project-schema/v3.40.0#"
152
152
  },
153
+ {
154
+ "$ref": "https://schema.takeshape.io/project-schema/v3.41.0#"
155
+ },
153
156
  {
154
157
  "$ref": "https://schema.takeshape.io/project-schema/v4.0.0#"
155
158
  }
@@ -46,6 +46,7 @@ import migrateToV3_37_0 from './to/v3.37.0';
46
46
  import migrateToV3_38_0 from './to/v3.38.0';
47
47
  import migrateToV3_39_0 from './to/v3.39.0';
48
48
  import migrateToV3_40_0 from './to/v3.40.0';
49
+ import migrateToV3_41_0 from './to/v3.41.0';
49
50
  export const migrateTo = {
50
51
  'v3.0.0': migrateToV3_0_0,
51
52
  'v3.1.0': migrateToV3_1_0,
@@ -94,7 +95,8 @@ export const migrateTo = {
94
95
  'v3.37.0': migrateToV3_37_0,
95
96
  'v3.38.0': migrateToV3_38_0,
96
97
  'v3.39.0': migrateToV3_39_0,
97
- 'v3.40.0': migrateToV3_40_0
98
+ 'v3.40.0': migrateToV3_40_0,
99
+ 'v3.41.0': migrateToV3_41_0
98
100
  };
99
101
  export * from './utils';
100
102
  export const listTypePrefix = 'PaginatedList';
@@ -0,0 +1,10 @@
1
+ const migrate = async (_, projectSchema) => {
2
+ /**
3
+ * No migration needed all changes are backwards compatible.
4
+ */
5
+ return {
6
+ ...projectSchema,
7
+ schemaVersion: '3.41.0'
8
+ };
9
+ };
10
+ export default migrate;
@@ -49,6 +49,7 @@ export * from './v3.37.0';
49
49
  export * from './v3.38.0';
50
50
  export * from './v3.39.0';
51
51
  export * from './v3.40.0';
52
+ export * from './v3.41.0';
52
53
  export * from './v4.0.0';
53
54
  // Schema type utilities
54
55
  function createVersionPredicate(expectedVersion) {
@@ -114,5 +115,6 @@ export const isProjectSchemaJSONV3_37_0 = createVersionPredicate('3.37.0');
114
115
  export const isProjectSchemaJSONV3_38_0 = createVersionPredicate('3.38.0');
115
116
  export const isProjectSchemaJSONV3_39_0 = createVersionPredicate('3.39.0');
116
117
  export const isProjectSchemaJSONV3_40_0 = createVersionPredicate('3.40.0');
117
- export const isLatestProjectSchemaJSON = createVersionPredicate('3.40.0');
118
+ export const isProjectSchemaJSONV3_41_0 = createVersionPredicate('3.41.0');
119
+ export const isLatestProjectSchemaJSON = createVersionPredicate('3.41.0');
118
120
  export const isProjectSchemaJSONV4_0_0 = createVersionPredicate('4.0.0');
@@ -1,7 +1,7 @@
1
1
  // This file is generated by "pnpm json2ts"
2
2
 
3
3
  import { migrateTo } from '../migration';
4
- import { isProjectSchemaJSONV1_0_0, isProjectSchemaJSONV3_0_0, isProjectSchemaJSONV3_1_0, isProjectSchemaJSONV3_2_0, isProjectSchemaJSONV3_3_0, isProjectSchemaJSONV3_4_0, isProjectSchemaJSONV3_5_0, isProjectSchemaJSONV3_5_1, isProjectSchemaJSONV3_6_0, isProjectSchemaJSONV3_7_0, isProjectSchemaJSONV3_8_0, isProjectSchemaJSONV3_9_0, isProjectSchemaJSONV3_10_0, isProjectSchemaJSONV3_11_0, isProjectSchemaJSONV3_12_0, isProjectSchemaJSONV3_12_1, isProjectSchemaJSONV3_12_2, isProjectSchemaJSONV3_12_3, isProjectSchemaJSONV3_13_0, isProjectSchemaJSONV3_14_0, isProjectSchemaJSONV3_15_0, isProjectSchemaJSONV3_16_0, isProjectSchemaJSONV3_17_0, isProjectSchemaJSONV3_17_1, isProjectSchemaJSONV3_18_0, isProjectSchemaJSONV3_18_1, isProjectSchemaJSONV3_18_2, isProjectSchemaJSONV3_19_0, isProjectSchemaJSONV3_20_0, isProjectSchemaJSONV3_21_0, isProjectSchemaJSONV3_22_0, isProjectSchemaJSONV3_23_0, isProjectSchemaJSONV3_24_0, isProjectSchemaJSONV3_25_0, isProjectSchemaJSONV3_26_0, isProjectSchemaJSONV3_27_0, isProjectSchemaJSONV3_28_0, isProjectSchemaJSONV3_29_0, isProjectSchemaJSONV3_30_0, isProjectSchemaJSONV3_31_0, isProjectSchemaJSONV3_32_0, isProjectSchemaJSONV3_33_0, isProjectSchemaJSONV3_34_0, isProjectSchemaJSONV3_35_0, isProjectSchemaJSONV3_36_0, isProjectSchemaJSONV3_37_0, isProjectSchemaJSONV3_38_0, isProjectSchemaJSONV3_39_0, isProjectSchemaJSONV4_0_0, isLatestProjectSchemaJSON } from './index';
4
+ import { isProjectSchemaJSONV1_0_0, isProjectSchemaJSONV3_0_0, isProjectSchemaJSONV3_1_0, isProjectSchemaJSONV3_2_0, isProjectSchemaJSONV3_3_0, isProjectSchemaJSONV3_4_0, isProjectSchemaJSONV3_5_0, isProjectSchemaJSONV3_5_1, isProjectSchemaJSONV3_6_0, isProjectSchemaJSONV3_7_0, isProjectSchemaJSONV3_8_0, isProjectSchemaJSONV3_9_0, isProjectSchemaJSONV3_10_0, isProjectSchemaJSONV3_11_0, isProjectSchemaJSONV3_12_0, isProjectSchemaJSONV3_12_1, isProjectSchemaJSONV3_12_2, isProjectSchemaJSONV3_12_3, isProjectSchemaJSONV3_13_0, isProjectSchemaJSONV3_14_0, isProjectSchemaJSONV3_15_0, isProjectSchemaJSONV3_16_0, isProjectSchemaJSONV3_17_0, isProjectSchemaJSONV3_17_1, isProjectSchemaJSONV3_18_0, isProjectSchemaJSONV3_18_1, isProjectSchemaJSONV3_18_2, isProjectSchemaJSONV3_19_0, isProjectSchemaJSONV3_20_0, isProjectSchemaJSONV3_21_0, isProjectSchemaJSONV3_22_0, isProjectSchemaJSONV3_23_0, isProjectSchemaJSONV3_24_0, isProjectSchemaJSONV3_25_0, isProjectSchemaJSONV3_26_0, isProjectSchemaJSONV3_27_0, isProjectSchemaJSONV3_28_0, isProjectSchemaJSONV3_29_0, isProjectSchemaJSONV3_30_0, isProjectSchemaJSONV3_31_0, isProjectSchemaJSONV3_32_0, isProjectSchemaJSONV3_33_0, isProjectSchemaJSONV3_34_0, isProjectSchemaJSONV3_35_0, isProjectSchemaJSONV3_36_0, isProjectSchemaJSONV3_37_0, isProjectSchemaJSONV3_38_0, isProjectSchemaJSONV3_39_0, isProjectSchemaJSONV3_40_0, isProjectSchemaJSONV4_0_0, isLatestProjectSchemaJSON } from './index';
5
5
 
6
6
  // eslint-disable-next-line complexity
7
7
  export async function migrateToLatestProjectSchema(context, projectSchema) {
@@ -152,6 +152,9 @@ export async function migrateToLatestProjectSchema(context, projectSchema) {
152
152
  if (isProjectSchemaJSONV3_39_0(projectSchema)) {
153
153
  projectSchema = await migrateTo['v3.40.0'](context, projectSchema);
154
154
  }
155
+ if (isProjectSchemaJSONV3_40_0(projectSchema)) {
156
+ projectSchema = await migrateTo['v3.41.0'](context, projectSchema);
157
+ }
155
158
  if (isProjectSchemaJSONV4_0_0(projectSchema)) {
156
159
  throw new Error('You are using an unreleased schema version. Migration is not possible');
157
160
  }
@@ -0,0 +1 @@
1
+ export {};
@@ -1,7 +1,7 @@
1
1
  // This file is generated by "pnpm json2ts"
2
- export const CURRENT_SCHEMA_VERSION = '3.40.0';
2
+ export const CURRENT_SCHEMA_VERSION = '3.41.0';
3
3
  export { default as anyProjectSchema } from './project-schema.json';
4
- export { default as latestSchemaJson } from './project-schema/v3.40.0.json';
4
+ export { default as latestSchemaJson } from './project-schema/v3.41.0.json';
5
5
  import metaSchemaV1_0_0 from './project-schema/meta-schema-v1.0.0.json';
6
6
  import projectSchemaV1_0_0 from './project-schema/v1.0.0.json';
7
7
  import metaSchemaV3_0_0 from './project-schema/meta-schema-v3.0.0.json';
@@ -63,5 +63,6 @@ import projectSchemaV3_37_0 from './project-schema/v3.37.0.json';
63
63
  import projectSchemaV3_38_0 from './project-schema/v3.38.0.json';
64
64
  import projectSchemaV3_39_0 from './project-schema/v3.39.0.json';
65
65
  import projectSchemaV3_40_0 from './project-schema/v3.40.0.json';
66
+ import projectSchemaV3_41_0 from './project-schema/v3.41.0.json';
66
67
  import projectSchemaV4_0_0 from './project-schema/v4.0.0.json';
67
- export const allProjectSchemas = [metaSchemaV1_0_0, projectSchemaV1_0_0, metaSchemaV3_0_0, projectSchemaV3_0_0, metaSchemaV3_1_0, projectSchemaV3_1_0, metaSchemaV3_2_0, projectSchemaV3_2_0, metaSchemaV3_3_0, projectSchemaV3_3_0, metaSchemaV3_4_0, projectSchemaV3_4_0, metaSchemaV3_5_0, projectSchemaV3_5_0, metaSchemaV3_5_1, projectSchemaV3_5_1, metaSchemaV3_6_0, projectSchemaV3_6_0, metaSchemaV3_7_0, projectSchemaV3_7_0, metaSchemaV3_8_0, projectSchemaV3_8_0, metaSchemaV3_9_0, projectSchemaV3_9_0, projectSchemaV3_10_0, projectSchemaV3_11_0, projectSchemaV3_12_0, projectSchemaV3_12_1, projectSchemaV3_12_2, projectSchemaV3_12_3, projectSchemaV3_13_0, projectSchemaV3_14_0, projectSchemaV3_15_0, projectSchemaV3_16_0, projectSchemaV3_17_0, projectSchemaV3_17_1, projectSchemaV3_18_0, projectSchemaV3_18_1, projectSchemaV3_18_2, projectSchemaV3_19_0, projectSchemaV3_20_0, projectSchemaV3_21_0, projectSchemaV3_22_0, projectSchemaV3_23_0, projectSchemaV3_24_0, projectSchemaV3_25_0, projectSchemaV3_26_0, projectSchemaV3_27_0, projectSchemaV3_28_0, projectSchemaV3_29_0, projectSchemaV3_30_0, projectSchemaV3_31_0, projectSchemaV3_32_0, projectSchemaV3_33_0, projectSchemaV3_34_0, projectSchemaV3_35_0, projectSchemaV3_36_0, projectSchemaV3_37_0, projectSchemaV3_38_0, projectSchemaV3_39_0, projectSchemaV3_40_0, projectSchemaV4_0_0];
68
+ export const allProjectSchemas = [metaSchemaV1_0_0, projectSchemaV1_0_0, metaSchemaV3_0_0, projectSchemaV3_0_0, metaSchemaV3_1_0, projectSchemaV3_1_0, metaSchemaV3_2_0, projectSchemaV3_2_0, metaSchemaV3_3_0, projectSchemaV3_3_0, metaSchemaV3_4_0, projectSchemaV3_4_0, metaSchemaV3_5_0, projectSchemaV3_5_0, metaSchemaV3_5_1, projectSchemaV3_5_1, metaSchemaV3_6_0, projectSchemaV3_6_0, metaSchemaV3_7_0, projectSchemaV3_7_0, metaSchemaV3_8_0, projectSchemaV3_8_0, metaSchemaV3_9_0, projectSchemaV3_9_0, projectSchemaV3_10_0, projectSchemaV3_11_0, projectSchemaV3_12_0, projectSchemaV3_12_1, projectSchemaV3_12_2, projectSchemaV3_12_3, projectSchemaV3_13_0, projectSchemaV3_14_0, projectSchemaV3_15_0, projectSchemaV3_16_0, projectSchemaV3_17_0, projectSchemaV3_17_1, projectSchemaV3_18_0, projectSchemaV3_18_1, projectSchemaV3_18_2, projectSchemaV3_19_0, projectSchemaV3_20_0, projectSchemaV3_21_0, projectSchemaV3_22_0, projectSchemaV3_23_0, projectSchemaV3_24_0, projectSchemaV3_25_0, projectSchemaV3_26_0, projectSchemaV3_27_0, projectSchemaV3_28_0, projectSchemaV3_29_0, projectSchemaV3_30_0, projectSchemaV3_31_0, projectSchemaV3_32_0, projectSchemaV3_33_0, projectSchemaV3_34_0, projectSchemaV3_35_0, projectSchemaV3_36_0, projectSchemaV3_37_0, projectSchemaV3_38_0, projectSchemaV3_39_0, projectSchemaV3_40_0, projectSchemaV3_41_0, projectSchemaV4_0_0];
@@ -1,7 +1,7 @@
1
1
  // This file is generated by "pnpm json2ts"
2
- export const CURRENT_SCHEMA_VERSION = '3.40.0';
2
+ export const CURRENT_SCHEMA_VERSION = '3.41.0';
3
3
  export {default as anyProjectSchema} from './project-schema.json';
4
- export {default as latestSchemaJson} from './project-schema/v3.40.0.json';
4
+ export {default as latestSchemaJson} from './project-schema/v3.41.0.json';
5
5
  import metaSchemaV1_0_0 from './project-schema/meta-schema-v1.0.0.json';
6
6
  import projectSchemaV1_0_0 from './project-schema/v1.0.0.json';
7
7
  import metaSchemaV3_0_0 from './project-schema/meta-schema-v3.0.0.json';
@@ -63,6 +63,7 @@ import projectSchemaV3_37_0 from './project-schema/v3.37.0.json';
63
63
  import projectSchemaV3_38_0 from './project-schema/v3.38.0.json';
64
64
  import projectSchemaV3_39_0 from './project-schema/v3.39.0.json';
65
65
  import projectSchemaV3_40_0 from './project-schema/v3.40.0.json';
66
+ import projectSchemaV3_41_0 from './project-schema/v3.41.0.json';
66
67
  import projectSchemaV4_0_0 from './project-schema/v4.0.0.json';
67
68
  export const allProjectSchemas = [
68
69
  metaSchemaV1_0_0,
@@ -126,5 +127,6 @@ export const allProjectSchemas = [
126
127
  projectSchemaV3_38_0,
127
128
  projectSchemaV3_39_0,
128
129
  projectSchemaV3_40_0,
130
+ projectSchemaV3_41_0,
129
131
  projectSchemaV4_0_0
130
132
  ];
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "$schema": "http://json-schema.org/draft-07/schema#",
3
- "$id": "https://schema.takeshape.io/project-schema/v3.40.0#",
3
+ "$id": "https://schema.takeshape.io/project-schema/v3.41.0#",
4
4
  "title": "Project Schema JSON",
5
5
  "definitions": {
6
6
  "schemaArray": {
@@ -1384,6 +1384,7 @@
1384
1384
  "enum": [
1385
1385
  "takeshape:getUser",
1386
1386
  "takeshape:search",
1387
+ "takeshape:vectorSearch",
1387
1388
  "takeshape:queryApiIndex"
1388
1389
  ]
1389
1390
  },
@@ -3151,7 +3152,7 @@
3151
3152
  "schemaVersion": {
3152
3153
  "type": "string",
3153
3154
  "enum": [
3154
- "3.40.0"
3155
+ "3.41.0"
3155
3156
  ],
3156
3157
  "description": "The version of the schema format your project is using. We increase the version as we make breaking changes to the schema format."
3157
3158
  },
@@ -1384,6 +1384,7 @@
1384
1384
  "enum": [
1385
1385
  "takeshape:getUser",
1386
1386
  "takeshape:search",
1387
+ "takeshape:vectorSearch",
1387
1388
  "takeshape:queryApiIndex"
1388
1389
  ]
1389
1390
  },