@wix/auto-patterns 1.18.0 → 1.19.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.
@@ -44,7 +44,10 @@ export interface AppConfig {
44
44
  label?: string; // Text displayed for the action
45
45
  collection: {
46
46
  collectionId: string; // ID of the Wix Data collection
47
- entityTypeSource: 'cms'; // Data source type. Always 'cms'
47
+ entityTypeSource: 'cms' | 'custom'; // Data source type.
48
+ custom?: {
49
+ id: string;
50
+ };
48
51
  };
49
52
  create?: { // Required when type is 'create'
50
53
  mode: 'page'; // Create mode
@@ -329,7 +332,10 @@ export interface AppConfig {
329
332
  }[];
330
333
  };
331
334
  collectionId: string; // Related collection ID
332
- entityTypeSource: 'cms'; // Data source type. Always 'cms'
335
+ entityTypeSource: 'cms' | 'custom'; // Data source type.
336
+ custom?: {
337
+ id: string;
338
+ };
333
339
  };
334
340
  }[];
335
341
  }
@@ -121,7 +121,10 @@ export interface AppConfig {
121
121
  label?: string; // Text displayed for the action
122
122
  collection: {
123
123
  collectionId: string; // ID of the Wix Data collection
124
- entityTypeSource: 'cms'; // Data source type. Always 'cms'
124
+ entityTypeSource: 'cms' | 'custom'; // Data source type.
125
+ custom?: {
126
+ id: string;
127
+ };
125
128
  };
126
129
  create?: { // Required when type is 'create'
127
130
  mode: 'page'; // Create mode
@@ -406,7 +409,10 @@ export interface AppConfig {
406
409
  }[];
407
410
  };
408
411
  collectionId: string; // Related collection ID
409
- entityTypeSource: 'cms'; // Data source type. Always 'cms'
412
+ entityTypeSource: 'cms' | 'custom'; // Data source type.
413
+ custom?: {
414
+ id: string;
415
+ };
410
416
  };
411
417
  }[];
412
418
  }
@@ -1019,7 +1025,7 @@ export const quickToggle: CustomActionCollectionPageActionOnRowClickResolver = (
1019
1025
  ✓ `primaryActions` and `secondaryActions` (if defined) have a valid `type` ("action" or "menu").
1020
1026
  ✓ If `type: "action"`, `action.item` is a valid action item configuration.
1021
1027
  ✓ If `type: "menu"`, `menu.items` is an array of valid action item configurations that can include dividers.
1022
- ✓ Each action item contains a unique `id`, and the full `collection` object (`collectionId`, `entityTypeSource: 'cms'`).
1028
+ ✓ Each action item contains a unique `id`, and the full `collection` object (`collectionId`, `entityTypeSource`).
1023
1029
  ✓ Each action item has a supported `type` (`create`, `custom`) and its corresponding configuration block (e.g., `create` block for `type: "create"`).
1024
1030
  ✓ `create` actions specify a `create.page.id` that matches an existing `entityPage` ID in the configuration.
1025
1031
  ✓ `custom` actions (identified by their main `id`) correspond to an action resolver function name registered in the `actions` override.
@@ -1828,7 +1834,6 @@ All entity pages must have:
1828
1834
 
1829
1835
  * Displays details for a **single entity**.
1830
1836
  * Always tied to a single Wix collection.
1831
- * `entityTypeSource` is always `'cms'`.
1832
1837
 
1833
1838
  > The custom actions must be defined inside the `moreActions` array.
1834
1839
 
@@ -330,7 +330,7 @@ export const quickToggle: CustomActionCollectionPageActionOnRowClickResolver = (
330
330
  ✓ `primaryActions` and `secondaryActions` (if defined) have a valid `type` ("action" or "menu").
331
331
  ✓ If `type: "action"`, `action.item` is a valid action item configuration.
332
332
  ✓ If `type: "menu"`, `menu.items` is an array of valid action item configurations that can include dividers.
333
- ✓ Each action item contains a unique `id`, and the full `collection` object (`collectionId`, `entityTypeSource: 'cms'`).
333
+ ✓ Each action item contains a unique `id`, and the full `collection` object (`collectionId`, `entityTypeSource`).
334
334
  ✓ Each action item has a supported `type` (`create`, `custom`) and its corresponding configuration block (e.g., `create` block for `type: "create"`).
335
335
  ✓ `create` actions specify a `create.page.id` that matches an existing `entityPage` ID in the configuration.
336
336
  ✓ `custom` actions (identified by their main `id`) correspond to an action resolver function name registered in the `actions` override.
@@ -11,7 +11,6 @@ All entity pages must have:
11
11
 
12
12
  * Displays details for a **single entity**.
13
13
  * Always tied to a single Wix collection.
14
- * `entityTypeSource` is always `'cms'`.
15
14
 
16
15
  > The custom actions must be defined inside the `moreActions` array.
17
16
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@wix/auto-patterns",
3
- "version": "1.18.0",
3
+ "version": "1.19.0",
4
4
  "license": "UNLICENSED",
5
5
  "author": {
6
6
  "name": "Matvey Oklander",
@@ -125,5 +125,5 @@
125
125
  "wallaby": {
126
126
  "autoDetect": true
127
127
  },
128
- "falconPackageHash": "c6791c0a4becf416bbc24a972f72ecefc440142f57ee542c67ee1277"
128
+ "falconPackageHash": "c019aa91a8eb6d3b052e8dadb2970238d9750fc11e7600581b9abdc3"
129
129
  }