feed-common 1.35.3 → 1.35.5

Sign up to get free protection for your applications and to get access to all the features.
package/CHANGELOG.md CHANGED
@@ -1,3 +1,17 @@
1
+ ## [1.35.5](https://github.com/advertikon/package-maxify-feed-common/compare/v1.35.4...v1.35.5) (2024-08-16)
2
+
3
+
4
+ ### Bug Fixes
5
+
6
+ * update facebook feed template ([104b9ff](https://github.com/advertikon/package-maxify-feed-common/commit/104b9ff21e1c9140e29e0823d508e1055e981e0d))
7
+
8
+ ## [1.35.4](https://github.com/advertikon/package-maxify-feed-common/compare/v1.35.3...v1.35.4) (2024-08-15)
9
+
10
+
11
+ ### Bug Fixes
12
+
13
+ * fix feed template number validators ([77866b6](https://github.com/advertikon/package-maxify-feed-common/commit/77866b619291e34cdf366a8dcfcdc3ab0f92d546))
14
+
1
15
  ## [1.35.3](https://github.com/advertikon/package-maxify-feed-common/compare/v1.35.2...v1.35.3) (2024-08-13)
2
16
 
3
17
 
@@ -1 +1 @@
1
- {"version":3,"file":"facebook.template.d.ts","sourceRoot":"","sources":["../../../src/utils/feed-templates/facebook.template.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,mBAAmB,EAAE,MAAM,8BAA8B,CAAC;AAiEnE,eAAO,MAAM,oBAAoB,EAAE,mBA6UlC,CAAC"}
1
+ {"version":3,"file":"facebook.template.d.ts","sourceRoot":"","sources":["../../../src/utils/feed-templates/facebook.template.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,mBAAmB,EAAE,MAAM,8BAA8B,CAAC;AA2DnE,eAAO,MAAM,oBAAoB,EAAE,mBAoVlC,CAAC"}
@@ -8,50 +8,48 @@ import { XmlFeedFormat } from '../../constants/profile.constants.js';
8
8
  const availabilityMapping = {
9
9
  attribute: 'availability',
10
10
  label: 'Availability',
11
- description: "The current availability of the item. Supported values: in stock, out of stock. Out of stock items don't appear in ads, which prevents advertising items that aren't available. They do still appear in shops on Facebook and Instagram, but are marked as sold out",
11
+ description: "The current availability of the item. Supported values: in stock, out of stock. Out of stock items don't appear in ads, which prevents advertising items that aren't available. They do still appear in shops on Facebook and Instagram, but are marked as sold out. Example: in stock",
12
12
  required: true,
13
13
  type: 'macro-input',
14
- validator: (v) => validate(v, z.enum(['in stock', 'out of stock']), false),
14
+ validator: (v) => validateIfNoMacro(v, z.enum(['in stock', 'out of stock'])),
15
15
  };
16
16
  const conditionMapping = {
17
17
  attribute: 'condition',
18
18
  label: 'Condition',
19
- description: 'The condition of the item. Supported values: new, refurbished, used',
19
+ description: 'The condition of the item. Supported values: new, refurbished, used. Example: new',
20
20
  required: true,
21
21
  type: 'macro-input',
22
- validator: (v) => validate(v, z.enum(['new', 'refurbished', 'used'])),
22
+ validator: (v) => validateIfNoMacro(v, z.enum(['new', 'refurbished', 'used'])),
23
23
  };
24
24
  const videoMapping = {
25
25
  attribute: 'video[0].url',
26
26
  label: 'Video URL 1',
27
- description: 'Up to 20 fields each containing a link to a product video. video[0].url will be your default video and a 4:5 aspect ratio is recommended. To add multiple videos per product, such as alternative 1:1 or 9:16 aspect ratios, add additional video fields',
27
+ description: 'Up to 20 fields each containing a link to a product video. video[0].url will be your default video and a 4:5 aspect ratio is recommended. To add multiple videos per product, such as alternative 1:1 or 9:16 aspect ratios, add additional video fields. Example: http://www.jaspersmarket.com/product_video.avi',
28
28
  required: false,
29
29
  type: 'macro-input',
30
30
  defaultValue: '',
31
31
  rules: { sections: [] },
32
- validator: (v) => validateIfNoMacro(v, z.string().url()),
32
+ validator: (v) => validateIfNoMacro(v, z.string().url().optional()),
33
33
  };
34
34
  const customLabelMapping = {
35
35
  attribute: 'custom_label_0',
36
36
  label: 'Custom Label 1',
37
- description: 'Up to five custom fields. Use these fields to create custom labels for your items. For example, you can use custom labels to filter your products in your Facebook catalog. Supported values: 0-100 characters',
37
+ description: 'Up to five custom fields. Use these fields to create custom labels for your items. For example, you can use custom labels to filter your products in your Facebook catalog. Supported values: 0-100 characters. Example: Summer sale',
38
38
  required: false,
39
39
  type: 'macro-input',
40
40
  defaultValue: '',
41
41
  rules: { sections: [] },
42
- validator: (v) => validate(v, z.string().max(100)),
42
+ validator: (v) => validate(v, z.string().max(100).optional()),
43
43
  };
44
44
  const customNumberMapping = {
45
45
  attribute: '',
46
46
  label: '',
47
- description: 'Up to five custom fields for any additional number-related information you want to filter items by when you create product sets. These fields allow you to filter by number ranges (is greater than and is less than) when you create a set. For example, you could use a custom number field to indicate the year each item was produced, and then filter a certain year range into a set. Supported whole number from 0 to 4294967295',
47
+ description: 'Up to five custom fields for any additional number-related information you want to filter items by when you create product sets. These fields allow you to filter by number ranges (is greater than and is less than) when you create a set. For example, you could use a custom number field to indicate the year each item was produced, and then filter a certain year range into a set. Supported whole number from 0 to 4294967295. Example: 2022',
48
48
  required: false,
49
49
  type: 'macro-input',
50
50
  defaultValue: '',
51
51
  rules: { sections: [] },
52
- validator: (v) => validateIfNoMacro(v, z.string().refine(v => Number(v) >= 0 && Number(v) <= 4294967295 && Number.isInteger(Number(v)), {
53
- message: 'Must be a whole number from 0 to 4294967295',
54
- })),
52
+ validator: (v) => validateIfNoMacro(v, z.coerce.number().min(0).max(4294967295).int().optional()),
55
53
  };
56
54
  export const facebookFeedTemplate = {
57
55
  formats: [XmlFeedFormat.CSV, XmlFeedFormat.XMLS, XmlFeedFormat.TSV, XmlFeedFormat.XML],
@@ -60,30 +58,30 @@ export const facebookFeedTemplate = {
60
58
  {
61
59
  attribute: 'id',
62
60
  label: 'ID',
63
- description: "A unique content ID for the item. Use the item's stock keeping unit (SKU) number if possible. Each content ID must appear only once in your catalog. If you use the same content ID for multiple items, none of them will be uploaded. Character limit: 100",
61
+ description: "A unique content ID for the item. Use the item's stock keeping unit (SKU) number if possible. Each content ID must appear only once in your catalog. If you use the same content ID for multiple items, none of them will be uploaded. Character limit: 100. Example: 12345",
64
62
  required: true,
65
63
  type: 'macro-input',
66
- validator: v => validate(v, z.string().max(100), false),
64
+ validator: v => validateIfNoMacro(v, z.string().max(100).min(1)),
67
65
  defaultValue: '{{shopify.sku}}',
68
66
  rules: { sections: [] },
69
67
  },
70
68
  {
71
69
  attribute: 'title',
72
70
  label: 'Title',
73
- description: 'A specific, relevant title for the item, written in title case. Character limit: 200, but we recommend 65 maximum to avoid longer titles being cut off',
71
+ description: 'A specific, relevant title for the item, written in title case. Character limit: 200, but we recommend 65 maximum to avoid longer titles being cut off. Example: Blue Cotton T-Shirt',
74
72
  required: true,
75
73
  type: 'macro-input',
76
- validator: (v) => validate(v, z.string().max(200), false),
74
+ validator: (v) => validateIfNoMacro(v, z.string().max(200).min(1)),
77
75
  defaultValue: '{{shopify.title}}',
78
76
  rules: { sections: [] },
79
77
  },
80
78
  {
81
79
  attribute: 'description',
82
80
  label: 'Description',
83
- description: "A detailed description of the item. Include specific and unique product features like material or color. Use plain text only (to use HTML, see rich_text description) and don't enter text in all capital letters. The description should be different from the title. We recommend not including any links. See product description specifications. Character limit: 9,999",
81
+ description: "A detailed description of the item. Include specific and unique product features like material or color. Use plain text only (to use HTML, see rich_text description) and don't enter text in all capital letters. The description should be different from the title. We recommend not including any links. See product description specifications. Character limit: 9,999. Example: A comfortable royal blue women's T-shirt in organic cotton. Cap sleeves and relaxed fit. Perfect for warm summer days.",
84
82
  required: true,
85
83
  type: 'macro-input',
86
- validator: (v) => validate(v, z.string().max(9999), false),
84
+ validator: (v) => validateIfNoMacro(v, z.string().max(9999).min(1)),
87
85
  defaultValue: '{{shopify.description}}',
88
86
  rules: { sections: [] },
89
87
  },
@@ -132,16 +130,17 @@ export const facebookFeedTemplate = {
132
130
  {
133
131
  attribute: 'price',
134
132
  label: 'Price',
135
- description: "The price of the item. Format the price as a number, followed by a space and then the 3-letter ISO 4217 currency code. Always use a period (.) as the decimal point, not a comma (,). Don't include currency symbols such as $, € or £. Only use one currency in your feed. To add prices in other currencies for selling in different countries, upload a country feed.",
133
+ description: "The price of the item. Format the price as a number, followed by a space and then the 3-letter ISO 4217 currency code. Always use a period (.) as the decimal point, not a comma (,). Don't include currency symbols such as $, € or £. Only use one currency in your feed. To add prices in other currencies for selling in different countries, upload a country feed. Examples: 9.99 USD or 7.99 EUR",
136
134
  required: true,
137
135
  type: 'macro-input',
136
+ validator: (v) => validateIfNoMacro(v, z.string().min(1)),
138
137
  defaultValue: '{{shopify.price}} {{shopify.shop_currency}}',
139
138
  rules: { sections: [] },
140
139
  },
141
140
  {
142
141
  attribute: 'link',
143
142
  label: 'Link',
144
- description: "The link to the item's specific product page on your business's website where people can learn more about or buy the item. Links must begin with http:// or https://, be valid and be hosted on your business’s website domain",
143
+ description: "The link to the item's specific product page on your business's website where people can learn more about or buy the item. Links must begin with http:// or https://, be valid and be hosted on your business’s website domain. Example: http://www.jaspersmarket.com/products/shirt",
145
144
  required: true,
146
145
  type: 'macro-input',
147
146
  validator: (v) => validateIfNoMacro(v, z.string().url()),
@@ -151,7 +150,7 @@ export const facebookFeedTemplate = {
151
150
  {
152
151
  attribute: 'image_link',
153
152
  label: 'Image link',
154
- description: 'The URL for the main image of your item. Images must be in JPEG or PNG format, at least 500 x 500 pixels and up to 8 MB',
153
+ description: 'The URL for the main image of your item. Images must be in JPEG or PNG format, at least 500 x 500 pixels and up to 8 MB. Example: http://www.jaspersmarket.com/products/shirt.jpg',
155
154
  required: true,
156
155
  type: 'macro-input',
157
156
  validator: (v) => validateIfNoMacro(v, z.string().url()),
@@ -161,37 +160,37 @@ export const facebookFeedTemplate = {
161
160
  {
162
161
  attribute: 'brand',
163
162
  label: 'Brand',
164
- description: 'The brand name of the item. Character limit: 100',
163
+ description: "The brand name of the item. Character limit: 100. Example: Jasper's Market",
165
164
  required: true,
166
165
  type: 'macro-input',
167
- validator: (v) => validate(v, z.string().max(100), false),
166
+ validator: (v) => validateIfNoMacro(v, z.string().max(100).min(1)),
168
167
  defaultValue: '{{shopify.vendor}}',
169
168
  rules: { sections: [] },
170
169
  },
171
170
  {
172
171
  attribute: 'quantity_to_sell_on_facebook',
173
172
  label: 'Quantity to sell on Facebook',
174
- description: "Checkout on Facebook and Instagram (US only). The quantity of this item that you have available to sell. Enter a whole number. To prevent overselling, an item's quantity is automatically reduced each time a purchase order is confirmed through checkout. When the quantity reaches 0, the item is marked as sold out in your shop on Facebook and Instagram. After 56 days, out of stock items stop appearing in your shop",
173
+ description: "Checkout on Facebook and Instagram (US only). The quantity of this item that you have available to sell. Enter a whole number. To prevent overselling, an item's quantity is automatically reduced each time a purchase order is confirmed through checkout. When the quantity reaches 0, the item is marked as sold out in your shop on Facebook and Instagram. After 56 days, out of stock items stop appearing in your shop. Example: 150",
175
174
  required: false,
176
175
  type: 'macro-input',
177
- validator: (v) => validateIfNoMacro(v, z.number().min(0)),
176
+ validator: (v) => validateIfNoMacro(v, z.coerce.number().min(0).optional()),
178
177
  defaultValue: '{{shopify.inventory_quantity}}',
179
178
  rules: { sections: [] },
180
179
  },
181
180
  {
182
181
  attribute: 'size',
183
182
  label: 'Size',
184
- description: 'Required for items in specific product categories including clothing and shoes. The size of the item written as a word, abbreviation or number, such as "Small", "XL", "12" or "One size". Include a space between words and numbers (such as "US 12" or "15 months" instead of "US12" or "15months") and don\'t include the word "size" if not necessary (such as "XS" instead of "Size XS"). Character limit: 200',
183
+ description: 'Required for items in specific product categories including clothing and shoes. The size of the item written as a word, abbreviation or number, such as "Small", "XL", "12" or "One size". Include a space between words and numbers (such as "US 12" or "15 months" instead of "US12" or "15months") and don\'t include the word "size" if not necessary (such as "XS" instead of "Size XS"). Character limit: 200. Example: Medium',
185
184
  required: false,
186
185
  type: 'macro-input',
187
- validator: (v) => validate(v, z.string().max(200)),
186
+ validator: (v) => validate(v, z.string().max(200).optional()),
188
187
  defaultValue: '',
189
188
  rules: { sections: [] },
190
189
  },
191
190
  {
192
191
  attribute: 'sale_price',
193
192
  label: 'Sale price',
194
- description: 'If the item is on sale, enter its discounted price. Use the same formatting as the price field',
193
+ description: 'If the item is on sale, enter its discounted price. Use the same formatting as the price field. Example: 5.99 USD',
195
194
  required: false,
196
195
  type: 'macro-input',
197
196
  defaultValue: '',
@@ -200,7 +199,7 @@ export const facebookFeedTemplate = {
200
199
  {
201
200
  attribute: 'sale_price_effective_date',
202
201
  label: 'Sale price effective date',
203
- description: "The date, time and time zone when your sale starts and ends. If you don't add this field, any items with a sale_price remain on sale until you remove their sale price. Use this format: YYYY-MM-DDT23:59+00:00/YYYY-MM-DDT23:59+00:00",
202
+ description: "The date, time and time zone when your sale starts and ends. If you don't add this field, any items with a sale_price remain on sale until you remove their sale price. Use this format: YYYY-MM-DDT23:59+00:00/YYYY-MM-DDT23:59+00:00. Example (using PST time zone -08:00): 2020-04-30T09:30-08:00/2020-05-30T23:59-08:00",
204
203
  required: false,
205
204
  type: 'macro-input',
206
205
  defaultValue: '',
@@ -209,7 +208,7 @@ export const facebookFeedTemplate = {
209
208
  {
210
209
  attribute: 'item_group_id',
211
210
  label: 'Item group ID',
212
- description: "Allows you to set up variants of the same product, such as different sizes, colors or patterns. Enter the same group ID in this field for all variants of the same product to indicate they're part of a group",
211
+ description: "Allows you to set up variants of the same product, such as different sizes, colors or patterns. Enter the same group ID in this field for all variants of the same product to indicate they're part of a group. Example: Shirt_1",
213
212
  required: false,
214
213
  type: 'macro-input',
215
214
  defaultValue: '{{shopify.id}}',
@@ -218,16 +217,17 @@ export const facebookFeedTemplate = {
218
217
  {
219
218
  attribute: 'status',
220
219
  label: 'Status',
221
- description: 'Controls whether the item is active or archived in your catalog. Only active items can be seen by people in your ads, shops or any other channels. Supported values: active, archived. Items are active by default',
220
+ description: 'Controls whether the item is active or archived in your catalog. Only active items can be seen by people in your ads, shops or any other channels. Supported values: active, archived. Items are active by default. Example: active',
222
221
  required: false,
223
222
  type: 'macro-input',
224
223
  defaultValue: '{{shopify.status}}',
224
+ validator: (v) => validateIfNoMacro(v, z.enum(['active', 'archived', '']).optional()),
225
225
  rules: { sections: [] },
226
226
  },
227
227
  {
228
228
  attribute: 'additional_image_link',
229
229
  label: 'Additional image link',
230
- description: 'Links to up to 20 additional images of your item, separated by a comma (,), semicolon (;), space ( ) or vertical bar (|). Follow the same image specifications as image_link',
230
+ description: 'Links to up to 20 additional images of your item, separated by a comma (,), semicolon (;), space ( ) or vertical bar (|). Follow the same image specifications as image_link. Example: http://www.jaspersmarket.com/products/shirt2.jpg, http://www.jaspersmarket.com/products/shirt3.jpg',
231
231
  required: false,
232
232
  type: 'macro-input',
233
233
  defaultValue: '{{shopify.images}}',
@@ -236,7 +236,7 @@ export const facebookFeedTemplate = {
236
236
  {
237
237
  attribute: 'gtin',
238
238
  label: 'GTIN',
239
- description: 'The item’s Global Trade Item Number (GTIN). Providing a GTIN is highly recommended to help classify the item. The GTIN may appear on the barcode, packaging or book cover. Not all items have a GTIN. Only provide one if you’re sure it’s correct. Don’t include dashes or spaces',
239
+ description: 'The item’s Global Trade Item Number (GTIN). Providing a GTIN is highly recommended to help classify the item. The GTIN may appear on the barcode, packaging or book cover. Not all items have a GTIN. Only provide one if you’re sure it’s correct. Don’t include dashes or spaces. Example: 4011200296908',
240
240
  required: false,
241
241
  type: 'macro-input',
242
242
  defaultValue: '',
@@ -245,11 +245,11 @@ export const facebookFeedTemplate = {
245
245
  {
246
246
  attribute: 'mpn',
247
247
  label: 'MPN',
248
- description: 'The item’s manufacturer part number (MPN), a unique alphanumeric code assigned by the manufacturer in some industries to identify a specific item or part. It may appear on the packaging, label or etched directly onto the item. Providing a MPN is recommended to help classify the item if there is no GTIN. Not all items have a MPN. Only provide one if you’re sure it’s correct. Character limit: 100',
248
+ description: 'The item’s manufacturer part number (MPN), a unique alphanumeric code assigned by the manufacturer in some industries to identify a specific item or part. It may appear on the packaging, label or etched directly onto the item. Providing a MPN is recommended to help classify the item if there is no GTIN. Not all items have a MPN. Only provide one if you’re sure it’s correct. Character limit: 100. Example: JAS12345PER',
249
249
  required: false,
250
250
  type: 'macro-input',
251
251
  defaultValue: '',
252
- validator: (v) => validate(v, z.string()),
252
+ validator: (v) => validate(v, z.string().optional()),
253
253
  rules: { sections: [] },
254
254
  },
255
255
  {
@@ -273,52 +273,52 @@ export const facebookFeedTemplate = {
273
273
  {
274
274
  attribute: 'color',
275
275
  label: 'Color',
276
- description: 'The main color of the item. Describe the color in words, not a hex code. Character limit: 200',
276
+ description: 'The main color of the item. Describe the color in words, not a hex code. Character limit: 200. Example: Royal blue',
277
277
  required: false,
278
278
  type: 'macro-input',
279
279
  defaultValue: '',
280
280
  rules: { sections: [] },
281
- validator: (v) => validate(v, z.string()),
281
+ validator: (v) => validate(v, z.string().optional()),
282
282
  },
283
283
  {
284
284
  attribute: 'gender',
285
285
  label: 'Gender',
286
- description: 'The gender your item is targeted towards. Supported values: female, male, unisex',
286
+ description: 'The gender your item is targeted towards. Supported values: female, male, unisex. Example: female',
287
287
  required: false,
288
288
  type: 'macro-input',
289
289
  defaultValue: '',
290
290
  rules: { sections: [] },
291
- validator: v => validate(v, z.enum(['female', 'male', 'unisex'])),
291
+ validator: v => validate(v, z.enum(['female', 'male', 'unisex', '']).optional()),
292
292
  },
293
293
  {
294
294
  attribute: 'age_group',
295
295
  label: 'Age group',
296
- description: 'The age group that the item is targeted towards. Supported values: adult, all ages, teen, kids, toddler, infant, newborn',
296
+ description: 'The age group that the item is targeted towards. Supported values: adult, all ages, teen, kids, toddler, infant, newborn. Example: adult',
297
297
  required: false,
298
298
  type: 'macro-input',
299
299
  defaultValue: '',
300
300
  rules: { sections: [] },
301
- validator: v => validate(v, z.enum(['adult', 'all ages', 'teen', 'kids', 'toddler', 'infant', 'newborn'])),
301
+ validator: v => validate(v, z.enum(['adult', 'all ages', 'teen', 'kids', 'toddler', 'infant', 'newborn', '']).optional()),
302
302
  },
303
303
  {
304
304
  attribute: 'material',
305
305
  label: 'Material',
306
- description: 'The material the item is made from, such as cotton, polyester, denim or leather. Character limit: 200',
306
+ description: 'The material the item is made from, such as cotton, polyester, denim or leather. Character limit: 200. Example: Organic cotton',
307
307
  required: false,
308
308
  type: 'macro-input',
309
309
  defaultValue: '',
310
310
  rules: { sections: [] },
311
- validator: (v) => validate(v, z.string()),
311
+ validator: (v) => validate(v, z.string().optional()),
312
312
  },
313
313
  {
314
314
  attribute: 'pattern',
315
315
  label: 'Pattern',
316
- description: 'The pattern or graphic print on the item. Character limit: 100',
316
+ description: 'The pattern or graphic print on the item. Character limit: 100. Example: Stripes',
317
317
  required: false,
318
318
  type: 'macro-input',
319
319
  defaultValue: '',
320
320
  rules: { sections: [] },
321
- validator: (v) => validate(v, z.string().max(100)),
321
+ validator: (v) => validate(v, z.string().max(100).optional()),
322
322
  },
323
323
  {
324
324
  attribute: 'rich_text_description',
@@ -328,7 +328,7 @@ export const facebookFeedTemplate = {
328
328
  type: 'macro-input',
329
329
  defaultValue: '{{shopify.description_html}}',
330
330
  rules: { sections: [] },
331
- validator: (v) => validate(v, z.string()),
331
+ validator: (v) => validate(v, z.string().optional()),
332
332
  },
333
333
  ...[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19].map(i => ({
334
334
  ...videoMapping,
@@ -1 +1 @@
1
- {"version":3,"file":"facebook.template.js","sourceRoot":"","sources":["../../../src/utils/feed-templates/facebook.template.ts"],"names":[],"mappings":"AAAA,uDAAuD;AACvD,2BAA2B;AAC3B,OAAO,KAAK,CAAC,MAAM,KAAK,CAAC;AACzB,OAAO,EAAE,IAAI,EAAE,MAAM,MAAM,CAAC;AAC5B,OAAO,EAAE,QAAQ,EAAE,iBAAiB,EAAE,MAAM,YAAY,CAAC;AAEzD,OAAO,EAAE,aAAa,EAAE,MAAM,sCAAsC,CAAC;AAErE,4BAA4B;AAC5B,MAAM,mBAAmB,GAAG;IACxB,SAAS,EAAE,cAAc;IACzB,KAAK,EAAE,cAAc;IACrB,WAAW,EACP,qQAAqQ;IACzQ,QAAQ,EAAE,IAAI;IACd,IAAI,EAAE,aAAoB;IAC1B,SAAS,EAAE,CAAC,CAAkB,EAAE,EAAE,CAAC,QAAQ,CAAC,CAAC,EAAE,CAAC,CAAC,IAAI,CAAC,CAAC,UAAU,EAAE,cAAc,CAAC,CAAC,EAAE,KAAK,CAAC;CAC9F,CAAC;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Y;YACf,SAAS,EAAE,SAAS,CAAC,OAAO;YAC5B,KAAK,EAAE,aAAa,CAAC,GAAG,CAAC,EAAE;SAC9B,CAAC,CAAC;QACH;YACI,SAAS,EAAE,UAAU;YACrB,KAAK,EAAE,UAAU;YACjB,WAAW,EACP,oNAAoN;YACxN,QAAQ,EAAE,KAAK;YACf,IAAI,EAAE,aAAa;YACnB,YAAY,EAAE,EAAE;YAChB,KAAK,EAAE,EAAE,QAAQ,EAAE,EAAE,EAAE;SAC1B;QACD;YACI,SAAS,EAAE,iBAAiB;YAC5B,KAAK,EAAE,iBAAiB;YACxB,WAAW,EAAE,qEAAqE;YAClF,QAAQ,EAAE,KAAK;YACf,IAAI,EAAE,aAAa;YACnB,YAAY,EAAE,4CAA4C;YAC1D,KAAK,EAAE,EAAE,QAAQ,EAAE,EAAE,EAAE;SAC1B;QACD,GAAG,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC;YACzB,GAAG,kBAAkB;YACrB,SAAS,EAAE,gBAAgB,CAAC,EAAE;YAC9B,KAAK,EAAE,gBAAgB,CAAC,GAAG,CAAC,EAAE;SACjC,CAAC,CAAC;QACH,GAAG,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC;YACzB,GAAG,mBAAmB;YACtB,SAAS,EAAE,iBAAiB,CAAC,EAAE;YAC/B,KAAK,EAAE,iBAAiB,CAAC,GAAG,CAAC,EAAE;SAClC,CAAC,CAAC;KACN;CACJ,CAAC"}
1
+ {"version":3,"file":"facebook.template.js","sourceRoot":"","sources":["../../../src/utils/feed-templates/facebook.template.ts"],"names":[],"mappings":"AAAA,uDAAuD;AACvD,2BAA2B;AAC3B,OAAO,KAAK,CAAC,MAAM,KAAK,CAAC;AACzB,OAAO,EAAE,IA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AAK,EAAE,EAAE,QAAQ,EAAE,EAAE,EAAE;SAC1B;QACD;YACI,SAAS,EAAE,iBAAiB;YAC5B,KAAK,EAAE,iBAAiB;YACxB,WAAW,EAAE,qEAAqE;YAClF,QAAQ,EAAE,KAAK;YACf,IAAI,EAAE,aAAa;YACnB,YAAY,EAAE,4CAA4C;YAC1D,KAAK,EAAE,EAAE,QAAQ,EAAE,EAAE,EAAE;SAC1B;QACD,GAAG,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC;YACzB,GAAG,kBAAkB;YACrB,SAAS,EAAE,gBAAgB,CAAC,EAAE;YAC9B,KAAK,EAAE,gBAAgB,CAAC,GAAG,CAAC,EAAE;SACjC,CAAC,CAAC;QACH,GAAG,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC;YACzB,GAAG,mBAAmB;YACtB,SAAS,EAAE,iBAAiB,CAAC,EAAE;YAC/B,KAAK,EAAE,iBAAiB,CAAC,GAAG,CAAC,EAAE;SAClC,CAAC,CAAC;KACN;CACJ,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "feed-common",
3
- "version": "1.35.3",
3
+ "version": "1.35.5",
4
4
  "description": "Maxify feed common library",
5
5
  "main": "dist/index.js",
6
6
  "type": "module",
@@ -11,61 +11,55 @@ const availabilityMapping = {
11
11
  attribute: 'availability',
12
12
  label: 'Availability',
13
13
  description:
14
- "The current availability of the item. Supported values: in stock, out of stock. Out of stock items don't appear in ads, which prevents advertising items that aren't available. They do still appear in shops on Facebook and Instagram, but are marked as sold out",
14
+ "The current availability of the item. Supported values: in stock, out of stock. Out of stock items don't appear in ads, which prevents advertising items that aren't available. They do still appear in shops on Facebook and Instagram, but are marked as sold out. Example: in stock",
15
15
  required: true,
16
16
  type: 'macro-input' as any,
17
- validator: (v: string | number) => validate(v, z.enum(['in stock', 'out of stock']), false),
17
+ validator: (v: string | number) => validateIfNoMacro(v, z.enum(['in stock', 'out of stock'])),
18
18
  };
19
19
 
20
20
  const conditionMapping = {
21
21
  attribute: 'condition',
22
22
  label: 'Condition',
23
- description: 'The condition of the item. Supported values: new, refurbished, used',
23
+ description: 'The condition of the item. Supported values: new, refurbished, used. Example: new',
24
24
  required: true,
25
25
  type: 'macro-input' as any,
26
- validator: (v: string | number) => validate(v, z.enum(['new', 'refurbished', 'used'])),
26
+ validator: (v: string | number) => validateIfNoMacro(v, z.enum(['new', 'refurbished', 'used'])),
27
27
  };
28
28
 
29
29
  const videoMapping = {
30
30
  attribute: 'video[0].url',
31
31
  label: 'Video URL 1',
32
32
  description:
33
- 'Up to 20 fields each containing a link to a product video. video[0].url will be your default video and a 4:5 aspect ratio is recommended. To add multiple videos per product, such as alternative 1:1 or 9:16 aspect ratios, add additional video fields',
33
+ 'Up to 20 fields each containing a link to a product video. video[0].url will be your default video and a 4:5 aspect ratio is recommended. To add multiple videos per product, such as alternative 1:1 or 9:16 aspect ratios, add additional video fields. Example: http://www.jaspersmarket.com/product_video.avi',
34
34
  required: false,
35
35
  type: 'macro-input' as any,
36
36
  defaultValue: '',
37
37
  rules: { sections: [] },
38
- validator: (v: string | number) => validateIfNoMacro(v, z.string().url()),
38
+ validator: (v: string | number) => validateIfNoMacro(v, z.string().url().optional()),
39
39
  };
40
40
 
41
41
  const customLabelMapping = {
42
42
  attribute: 'custom_label_0',
43
43
  label: 'Custom Label 1',
44
44
  description:
45
- 'Up to five custom fields. Use these fields to create custom labels for your items. For example, you can use custom labels to filter your products in your Facebook catalog. Supported values: 0-100 characters',
45
+ 'Up to five custom fields. Use these fields to create custom labels for your items. For example, you can use custom labels to filter your products in your Facebook catalog. Supported values: 0-100 characters. Example: Summer sale',
46
46
  required: false,
47
47
  type: 'macro-input' as any,
48
48
  defaultValue: '',
49
49
  rules: { sections: [] },
50
- validator: (v: string | number) => validate(v, z.string().max(100)),
50
+ validator: (v: string | number) => validate(v, z.string().max(100).optional()),
51
51
  };
52
52
 
53
53
  const customNumberMapping = {
54
54
  attribute: '',
55
55
  label: '',
56
56
  description:
57
- 'Up to five custom fields for any additional number-related information you want to filter items by when you create product sets. These fields allow you to filter by number ranges (is greater than and is less than) when you create a set. For example, you could use a custom number field to indicate the year each item was produced, and then filter a certain year range into a set. Supported whole number from 0 to 4294967295',
57
+ 'Up to five custom fields for any additional number-related information you want to filter items by when you create product sets. These fields allow you to filter by number ranges (is greater than and is less than) when you create a set. For example, you could use a custom number field to indicate the year each item was produced, and then filter a certain year range into a set. Supported whole number from 0 to 4294967295. Example: 2022',
58
58
  required: false,
59
59
  type: 'macro-input' as any,
60
60
  defaultValue: '',
61
61
  rules: { sections: [] },
62
- validator: (v: string | number) =>
63
- validateIfNoMacro(
64
- v,
65
- z.string().refine(v => Number(v) >= 0 && Number(v) <= 4294967295 && Number.isInteger(Number(v)), {
66
- message: 'Must be a whole number from 0 to 4294967295',
67
- })
68
- ),
62
+ validator: (v: string | number) => validateIfNoMacro(v, z.coerce.number().min(0).max(4294967295).int().optional()),
69
63
  };
70
64
 
71
65
  export const facebookFeedTemplate: XmlFeedTemplateType = {
@@ -76,10 +70,10 @@ export const facebookFeedTemplate: XmlFeedTemplateType = {
76
70
  attribute: 'id',
77
71
  label: 'ID',
78
72
  description:
79
- "A unique content ID for the item. Use the item's stock keeping unit (SKU) number if possible. Each content ID must appear only once in your catalog. If you use the same content ID for multiple items, none of them will be uploaded. Character limit: 100",
73
+ "A unique content ID for the item. Use the item's stock keeping unit (SKU) number if possible. Each content ID must appear only once in your catalog. If you use the same content ID for multiple items, none of them will be uploaded. Character limit: 100. Example: 12345",
80
74
  required: true,
81
75
  type: 'macro-input',
82
- validator: v => validate(v, z.string().max(100), false),
76
+ validator: v => validateIfNoMacro(v, z.string().max(100).min(1)),
83
77
  defaultValue: '{{shopify.sku}}',
84
78
  rules: { sections: [] },
85
79
  },
@@ -87,10 +81,10 @@ export const facebookFeedTemplate: XmlFeedTemplateType = {
87
81
  attribute: 'title',
88
82
  label: 'Title',
89
83
  description:
90
- 'A specific, relevant title for the item, written in title case. Character limit: 200, but we recommend 65 maximum to avoid longer titles being cut off',
84
+ 'A specific, relevant title for the item, written in title case. Character limit: 200, but we recommend 65 maximum to avoid longer titles being cut off. Example: Blue Cotton T-Shirt',
91
85
  required: true,
92
86
  type: 'macro-input',
93
- validator: (v: string | number) => validate(v, z.string().max(200), false),
87
+ validator: (v: string | number) => validateIfNoMacro(v, z.string().max(200).min(1)),
94
88
  defaultValue: '{{shopify.title}}',
95
89
  rules: { sections: [] },
96
90
  },
@@ -98,10 +92,10 @@ export const facebookFeedTemplate: XmlFeedTemplateType = {
98
92
  attribute: 'description',
99
93
  label: 'Description',
100
94
  description:
101
- "A detailed description of the item. Include specific and unique product features like material or color. Use plain text only (to use HTML, see rich_text description) and don't enter text in all capital letters. The description should be different from the title. We recommend not including any links. See product description specifications. Character limit: 9,999",
95
+ "A detailed description of the item. Include specific and unique product features like material or color. Use plain text only (to use HTML, see rich_text description) and don't enter text in all capital letters. The description should be different from the title. We recommend not including any links. See product description specifications. Character limit: 9,999. Example: A comfortable royal blue women's T-shirt in organic cotton. Cap sleeves and relaxed fit. Perfect for warm summer days.",
102
96
  required: true,
103
97
  type: 'macro-input',
104
- validator: (v: string | number) => validate(v, z.string().max(9999), false),
98
+ validator: (v: string | number) => validateIfNoMacro(v, z.string().max(9999).min(1)),
105
99
  defaultValue: '{{shopify.description}}',
106
100
  rules: { sections: [] },
107
101
  },
@@ -151,9 +145,10 @@ export const facebookFeedTemplate: XmlFeedTemplateType = {
151
145
  attribute: 'price',
152
146
  label: 'Price',
153
147
  description:
154
- "The price of the item. Format the price as a number, followed by a space and then the 3-letter ISO 4217 currency code. Always use a period (.) as the decimal point, not a comma (,). Don't include currency symbols such as $, € or £. Only use one currency in your feed. To add prices in other currencies for selling in different countries, upload a country feed.",
148
+ "The price of the item. Format the price as a number, followed by a space and then the 3-letter ISO 4217 currency code. Always use a period (.) as the decimal point, not a comma (,). Don't include currency symbols such as $, € or £. Only use one currency in your feed. To add prices in other currencies for selling in different countries, upload a country feed. Examples: 9.99 USD or 7.99 EUR",
155
149
  required: true,
156
150
  type: 'macro-input',
151
+ validator: (v: string | number) => validateIfNoMacro(v, z.string().min(1)),
157
152
  defaultValue: '{{shopify.price}} {{shopify.shop_currency}}',
158
153
  rules: { sections: [] },
159
154
  },
@@ -161,7 +156,7 @@ export const facebookFeedTemplate: XmlFeedTemplateType = {
161
156
  attribute: 'link',
162
157
  label: 'Link',
163
158
  description:
164
- "The link to the item's specific product page on your business's website where people can learn more about or buy the item. Links must begin with http:// or https://, be valid and be hosted on your business’s website domain",
159
+ "The link to the item's specific product page on your business's website where people can learn more about or buy the item. Links must begin with http:// or https://, be valid and be hosted on your business’s website domain. Example: http://www.jaspersmarket.com/products/shirt",
165
160
  required: true,
166
161
  type: 'macro-input',
167
162
  validator: (v: string | number) => validateIfNoMacro(v, z.string().url()),
@@ -172,7 +167,7 @@ export const facebookFeedTemplate: XmlFeedTemplateType = {
172
167
  attribute: 'image_link',
173
168
  label: 'Image link',
174
169
  description:
175
- 'The URL for the main image of your item. Images must be in JPEG or PNG format, at least 500 x 500 pixels and up to 8 MB',
170
+ 'The URL for the main image of your item. Images must be in JPEG or PNG format, at least 500 x 500 pixels and up to 8 MB. Example: http://www.jaspersmarket.com/products/shirt.jpg',
176
171
  required: true,
177
172
  type: 'macro-input',
178
173
  validator: (v: string | number) => validateIfNoMacro(v, z.string().url()),
@@ -182,10 +177,10 @@ export const facebookFeedTemplate: XmlFeedTemplateType = {
182
177
  {
183
178
  attribute: 'brand',
184
179
  label: 'Brand',
185
- description: 'The brand name of the item. Character limit: 100',
180
+ description: "The brand name of the item. Character limit: 100. Example: Jasper's Market",
186
181
  required: true,
187
182
  type: 'macro-input',
188
- validator: (v: string | number) => validate(v, z.string().max(100), false),
183
+ validator: (v: string | number) => validateIfNoMacro(v, z.string().max(100).min(1)),
189
184
  defaultValue: '{{shopify.vendor}}',
190
185
  rules: { sections: [] },
191
186
  },
@@ -193,10 +188,10 @@ export const facebookFeedTemplate: XmlFeedTemplateType = {
193
188
  attribute: 'quantity_to_sell_on_facebook',
194
189
  label: 'Quantity to sell on Facebook',
195
190
  description:
196
- "Checkout on Facebook and Instagram (US only). The quantity of this item that you have available to sell. Enter a whole number. To prevent overselling, an item's quantity is automatically reduced each time a purchase order is confirmed through checkout. When the quantity reaches 0, the item is marked as sold out in your shop on Facebook and Instagram. After 56 days, out of stock items stop appearing in your shop",
191
+ "Checkout on Facebook and Instagram (US only). The quantity of this item that you have available to sell. Enter a whole number. To prevent overselling, an item's quantity is automatically reduced each time a purchase order is confirmed through checkout. When the quantity reaches 0, the item is marked as sold out in your shop on Facebook and Instagram. After 56 days, out of stock items stop appearing in your shop. Example: 150",
197
192
  required: false,
198
193
  type: 'macro-input',
199
- validator: (v: string | number) => validateIfNoMacro(v, z.number().min(0)),
194
+ validator: (v: string | number) => validateIfNoMacro(v, z.coerce.number().min(0).optional()),
200
195
  defaultValue: '{{shopify.inventory_quantity}}',
201
196
  rules: { sections: [] },
202
197
  },
@@ -204,10 +199,10 @@ export const facebookFeedTemplate: XmlFeedTemplateType = {
204
199
  attribute: 'size',
205
200
  label: 'Size',
206
201
  description:
207
- 'Required for items in specific product categories including clothing and shoes. The size of the item written as a word, abbreviation or number, such as "Small", "XL", "12" or "One size". Include a space between words and numbers (such as "US 12" or "15 months" instead of "US12" or "15months") and don\'t include the word "size" if not necessary (such as "XS" instead of "Size XS"). Character limit: 200',
202
+ 'Required for items in specific product categories including clothing and shoes. The size of the item written as a word, abbreviation or number, such as "Small", "XL", "12" or "One size". Include a space between words and numbers (such as "US 12" or "15 months" instead of "US12" or "15months") and don\'t include the word "size" if not necessary (such as "XS" instead of "Size XS"). Character limit: 200. Example: Medium',
208
203
  required: false,
209
204
  type: 'macro-input',
210
- validator: (v: string | number) => validate(v, z.string().max(200)),
205
+ validator: (v: string | number) => validate(v, z.string().max(200).optional()),
211
206
  defaultValue: '',
212
207
  rules: { sections: [] },
213
208
  },
@@ -215,7 +210,7 @@ export const facebookFeedTemplate: XmlFeedTemplateType = {
215
210
  attribute: 'sale_price',
216
211
  label: 'Sale price',
217
212
  description:
218
- 'If the item is on sale, enter its discounted price. Use the same formatting as the price field',
213
+ 'If the item is on sale, enter its discounted price. Use the same formatting as the price field. Example: 5.99 USD',
219
214
  required: false,
220
215
  type: 'macro-input',
221
216
  defaultValue: '',
@@ -225,7 +220,7 @@ export const facebookFeedTemplate: XmlFeedTemplateType = {
225
220
  attribute: 'sale_price_effective_date',
226
221
  label: 'Sale price effective date',
227
222
  description:
228
- "The date, time and time zone when your sale starts and ends. If you don't add this field, any items with a sale_price remain on sale until you remove their sale price. Use this format: YYYY-MM-DDT23:59+00:00/YYYY-MM-DDT23:59+00:00",
223
+ "The date, time and time zone when your sale starts and ends. If you don't add this field, any items with a sale_price remain on sale until you remove their sale price. Use this format: YYYY-MM-DDT23:59+00:00/YYYY-MM-DDT23:59+00:00. Example (using PST time zone -08:00): 2020-04-30T09:30-08:00/2020-05-30T23:59-08:00",
229
224
  required: false,
230
225
  type: 'macro-input',
231
226
  defaultValue: '',
@@ -235,7 +230,7 @@ export const facebookFeedTemplate: XmlFeedTemplateType = {
235
230
  attribute: 'item_group_id',
236
231
  label: 'Item group ID',
237
232
  description:
238
- "Allows you to set up variants of the same product, such as different sizes, colors or patterns. Enter the same group ID in this field for all variants of the same product to indicate they're part of a group",
233
+ "Allows you to set up variants of the same product, such as different sizes, colors or patterns. Enter the same group ID in this field for all variants of the same product to indicate they're part of a group. Example: Shirt_1",
239
234
  required: false,
240
235
  type: 'macro-input',
241
236
  defaultValue: '{{shopify.id}}',
@@ -245,17 +240,18 @@ export const facebookFeedTemplate: XmlFeedTemplateType = {
245
240
  attribute: 'status',
246
241
  label: 'Status',
247
242
  description:
248
- 'Controls whether the item is active or archived in your catalog. Only active items can be seen by people in your ads, shops or any other channels. Supported values: active, archived. Items are active by default',
243
+ 'Controls whether the item is active or archived in your catalog. Only active items can be seen by people in your ads, shops or any other channels. Supported values: active, archived. Items are active by default. Example: active',
249
244
  required: false,
250
245
  type: 'macro-input',
251
246
  defaultValue: '{{shopify.status}}',
247
+ validator: (v: string | number) => validateIfNoMacro(v, z.enum(['active', 'archived', '']).optional()),
252
248
  rules: { sections: [] },
253
249
  },
254
250
  {
255
251
  attribute: 'additional_image_link',
256
252
  label: 'Additional image link',
257
253
  description:
258
- 'Links to up to 20 additional images of your item, separated by a comma (,), semicolon (;), space ( ) or vertical bar (|). Follow the same image specifications as image_link',
254
+ 'Links to up to 20 additional images of your item, separated by a comma (,), semicolon (;), space ( ) or vertical bar (|). Follow the same image specifications as image_link. Example: http://www.jaspersmarket.com/products/shirt2.jpg, http://www.jaspersmarket.com/products/shirt3.jpg',
259
255
  required: false,
260
256
  type: 'macro-input',
261
257
  defaultValue: '{{shopify.images}}',
@@ -265,7 +261,7 @@ export const facebookFeedTemplate: XmlFeedTemplateType = {
265
261
  attribute: 'gtin',
266
262
  label: 'GTIN',
267
263
  description:
268
- 'The item’s Global Trade Item Number (GTIN). Providing a GTIN is highly recommended to help classify the item. The GTIN may appear on the barcode, packaging or book cover. Not all items have a GTIN. Only provide one if you’re sure it’s correct. Don’t include dashes or spaces',
264
+ 'The item’s Global Trade Item Number (GTIN). Providing a GTIN is highly recommended to help classify the item. The GTIN may appear on the barcode, packaging or book cover. Not all items have a GTIN. Only provide one if you’re sure it’s correct. Don’t include dashes or spaces. Example: 4011200296908',
269
265
  required: false,
270
266
  type: 'macro-input',
271
267
  defaultValue: '',
@@ -275,11 +271,11 @@ export const facebookFeedTemplate: XmlFeedTemplateType = {
275
271
  attribute: 'mpn',
276
272
  label: 'MPN',
277
273
  description:
278
- 'The item’s manufacturer part number (MPN), a unique alphanumeric code assigned by the manufacturer in some industries to identify a specific item or part. It may appear on the packaging, label or etched directly onto the item. Providing a MPN is recommended to help classify the item if there is no GTIN. Not all items have a MPN. Only provide one if you’re sure it’s correct. Character limit: 100',
274
+ 'The item’s manufacturer part number (MPN), a unique alphanumeric code assigned by the manufacturer in some industries to identify a specific item or part. It may appear on the packaging, label or etched directly onto the item. Providing a MPN is recommended to help classify the item if there is no GTIN. Not all items have a MPN. Only provide one if you’re sure it’s correct. Character limit: 100. Example: JAS12345PER',
279
275
  required: false,
280
276
  type: 'macro-input',
281
277
  defaultValue: '',
282
- validator: (v: string | number) => validate(v, z.string()),
278
+ validator: (v: string | number) => validate(v, z.string().optional()),
283
279
  rules: { sections: [] },
284
280
  },
285
281
  {
@@ -306,54 +302,59 @@ export const facebookFeedTemplate: XmlFeedTemplateType = {
306
302
  attribute: 'color',
307
303
  label: 'Color',
308
304
  description:
309
- 'The main color of the item. Describe the color in words, not a hex code. Character limit: 200',
305
+ 'The main color of the item. Describe the color in words, not a hex code. Character limit: 200. Example: Royal blue',
310
306
  required: false,
311
307
  type: 'macro-input',
312
308
  defaultValue: '',
313
309
  rules: { sections: [] },
314
- validator: (v: string | number) => validate(v, z.string()),
310
+ validator: (v: string | number) => validate(v, z.string().optional()),
315
311
  },
316
312
  {
317
313
  attribute: 'gender',
318
314
  label: 'Gender',
319
- description: 'The gender your item is targeted towards. Supported values: female, male, unisex',
315
+ description:
316
+ 'The gender your item is targeted towards. Supported values: female, male, unisex. Example: female',
320
317
  required: false,
321
318
  type: 'macro-input',
322
319
  defaultValue: '',
323
320
  rules: { sections: [] },
324
- validator: v => validate(v, z.enum(['female', 'male', 'unisex'])),
321
+ validator: v => validate(v, z.enum(['female', 'male', 'unisex', '']).optional()),
325
322
  },
326
323
  {
327
324
  attribute: 'age_group',
328
325
  label: 'Age group',
329
326
  description:
330
- 'The age group that the item is targeted towards. Supported values: adult, all ages, teen, kids, toddler, infant, newborn',
327
+ 'The age group that the item is targeted towards. Supported values: adult, all ages, teen, kids, toddler, infant, newborn. Example: adult',
331
328
  required: false,
332
329
  type: 'macro-input',
333
330
  defaultValue: '',
334
331
  rules: { sections: [] },
335
- validator: v => validate(v, z.enum(['adult', 'all ages', 'teen', 'kids', 'toddler', 'infant', 'newborn'])),
332
+ validator: v =>
333
+ validate(
334
+ v,
335
+ z.enum(['adult', 'all ages', 'teen', 'kids', 'toddler', 'infant', 'newborn', '']).optional()
336
+ ),
336
337
  },
337
338
  {
338
339
  attribute: 'material',
339
340
  label: 'Material',
340
341
  description:
341
- 'The material the item is made from, such as cotton, polyester, denim or leather. Character limit: 200',
342
+ 'The material the item is made from, such as cotton, polyester, denim or leather. Character limit: 200. Example: Organic cotton',
342
343
  required: false,
343
344
  type: 'macro-input',
344
345
  defaultValue: '',
345
346
  rules: { sections: [] },
346
- validator: (v: string | number) => validate(v, z.string()),
347
+ validator: (v: string | number) => validate(v, z.string().optional()),
347
348
  },
348
349
  {
349
350
  attribute: 'pattern',
350
351
  label: 'Pattern',
351
- description: 'The pattern or graphic print on the item. Character limit: 100',
352
+ description: 'The pattern or graphic print on the item. Character limit: 100. Example: Stripes',
352
353
  required: false,
353
354
  type: 'macro-input',
354
355
  defaultValue: '',
355
356
  rules: { sections: [] },
356
- validator: (v: string | number) => validate(v, z.string().max(100)),
357
+ validator: (v: string | number) => validate(v, z.string().max(100).optional()),
357
358
  },
358
359
  {
359
360
  attribute: 'rich_text_description',
@@ -364,7 +365,7 @@ export const facebookFeedTemplate: XmlFeedTemplateType = {
364
365
  type: 'macro-input',
365
366
  defaultValue: '{{shopify.description_html}}',
366
367
  rules: { sections: [] },
367
- validator: (v: string | number) => validate(v, z.string()),
368
+ validator: (v: string | number) => validate(v, z.string().optional()),
368
369
  },
369
370
  ...[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19].map(i => ({
370
371
  ...videoMapping,