@gem-sdk/components 2.0.0-dev.703 → 2.0.0-dev.705

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 (36) hide show
  1. package/dist/cjs/article/setting/configs/ArticleReadMore/settings.js +86 -134
  2. package/dist/cjs/button/components/common/helpers.js +2 -9
  3. package/dist/cjs/button/components/common/styles.js +14 -81
  4. package/dist/cjs/button/setting/configs/settings.js +85 -133
  5. package/dist/cjs/coupon/common/classes.js +3 -12
  6. package/dist/cjs/coupon/common/styles.js +7 -17
  7. package/dist/cjs/coupon/setting/config/settings.js +60 -100
  8. package/dist/cjs/form/setting/submit-button/configs/settings.js +103 -250
  9. package/dist/cjs/product/components/DynamicCheckout/common/styles.js +12 -12
  10. package/dist/cjs/product/components/ProductBadge/index.liquid.js +1 -1
  11. package/dist/cjs/product/components/ProductButton/common/styles.js +4 -14
  12. package/dist/cjs/product/components/ProductImagesV2/common/common.js +1 -1
  13. package/dist/cjs/product/setting/dynamic-checkout/configs/settings.js +86 -134
  14. package/dist/cjs/product/setting/product-button/configs/settings.js +142 -222
  15. package/dist/cjs/product/setting/product-view-more/configs/settings.js +100 -148
  16. package/dist/cjs/tab/components/Tabs.liquid.js +2 -2
  17. package/dist/cjs/third-party/setting/Selleasy/index.js +5 -5
  18. package/dist/esm/article/setting/configs/ArticleReadMore/settings.js +86 -134
  19. package/dist/esm/button/components/common/helpers.js +2 -9
  20. package/dist/esm/button/components/common/styles.js +16 -81
  21. package/dist/esm/button/setting/configs/settings.js +85 -133
  22. package/dist/esm/coupon/common/classes.js +3 -12
  23. package/dist/esm/coupon/common/styles.js +7 -17
  24. package/dist/esm/coupon/setting/config/settings.js +60 -100
  25. package/dist/esm/form/setting/submit-button/configs/settings.js +103 -250
  26. package/dist/esm/product/components/DynamicCheckout/common/styles.js +12 -12
  27. package/dist/esm/product/components/ProductBadge/index.liquid.js +1 -1
  28. package/dist/esm/product/components/ProductButton/common/styles.js +4 -14
  29. package/dist/esm/product/components/ProductImagesV2/common/common.js +1 -1
  30. package/dist/esm/product/setting/dynamic-checkout/configs/settings.js +86 -134
  31. package/dist/esm/product/setting/product-button/configs/settings.js +142 -222
  32. package/dist/esm/product/setting/product-view-more/configs/settings.js +100 -148
  33. package/dist/esm/tab/components/Tabs.liquid.js +2 -2
  34. package/dist/esm/third-party/setting/Selleasy/index.js +5 -5
  35. package/dist/types/index.d.ts +23 -23
  36. package/package.json +2 -2
@@ -93,44 +93,36 @@ const ProductViewMoreSettings = [
93
93
  {
94
94
  id: 'borderBtnV2',
95
95
  type: 'border-v2',
96
- devices: {
97
- desktop: {
98
- default: {
99
- normal: {
100
- borderType: 'none',
101
- border: 'none',
102
- borderWidth: '1px',
103
- width: '1px 1px 1px 1px',
104
- color: '#121212',
105
- isCustom: true
106
- },
107
- hover: {
108
- borderType: 'none',
109
- border: 'none',
110
- borderWidth: '1px',
111
- width: '1px 1px 1px 1px',
112
- color: '#121212',
113
- isCustom: true
114
- }
115
- }
96
+ default: {
97
+ normal: {
98
+ borderType: 'none',
99
+ border: 'none',
100
+ borderWidth: '1px',
101
+ width: '1px 1px 1px 1px',
102
+ color: '#121212',
103
+ isCustom: true
104
+ },
105
+ hover: {
106
+ borderType: 'none',
107
+ border: 'none',
108
+ borderWidth: '1px',
109
+ width: '1px 1px 1px 1px',
110
+ color: '#121212',
111
+ isCustom: true
116
112
  }
117
113
  },
118
114
  compoDefaultValue: {
119
- desktop: {
120
- default: {
121
- normal: {
122
- border: 'solid',
123
- color: '#121212',
124
- width: '1px',
125
- borderWidth: '1px'
126
- },
127
- hover: {
128
- border: 'solid',
129
- color: '#121212',
130
- width: '1px',
131
- borderWidth: '1px'
132
- }
133
- }
115
+ normal: {
116
+ border: 'solid',
117
+ color: '#121212',
118
+ width: '1px',
119
+ borderWidth: '1px'
120
+ },
121
+ hover: {
122
+ border: 'solid',
123
+ color: '#121212',
124
+ width: '1px',
125
+ borderWidth: '1px'
134
126
  }
135
127
  }
136
128
  },
@@ -150,66 +142,50 @@ const ProductViewMoreSettings = [
150
142
  {
151
143
  id: 'backgroundColorV2',
152
144
  type: 'color-picker-v2',
153
- devices: {
154
- desktop: {
155
- default: {
156
- normal: 'brand',
157
- hover: 'highlight'
158
- }
159
- }
145
+ default: {
146
+ normal: 'brand',
147
+ hover: 'highlight'
160
148
  },
161
149
  compoDefaultValue: {
162
- desktop: {
163
- default: {
164
- normal: 'brand',
165
- hover: 'highlight'
166
- }
167
- }
150
+ normal: 'brand',
151
+ hover: 'highlight'
168
152
  },
169
153
  enableGradient: true
170
154
  },
171
155
  {
172
156
  id: 'backgroundImage',
173
157
  type: 'background-image',
174
- devices: {
175
- desktop: {
176
- default: {
177
- normal: {},
178
- hover: {}
179
- }
180
- }
158
+ default: {
159
+ normal: {},
160
+ hover: {}
181
161
  },
182
162
  compoDefaultValue: {
183
- desktop: {
184
- default: {
185
- normal: {
186
- size: 'cover',
187
- position: {
188
- x: 50,
189
- y: 50
190
- },
191
- repeat: 'no-repeat',
192
- attachment: 'scroll',
193
- image: {
194
- src: 'https://ucarecdn.com/06075225-af9e-460c-8e3c-6be63c0b773a/-/format/auto/',
195
- width: 1200,
196
- height: 480
197
- }
198
- },
199
- hover: {
200
- size: 'cover',
201
- position: {
202
- x: 50,
203
- y: 50
204
- },
205
- repeat: 'no-repeat',
206
- attachment: 'scroll',
207
- image: {
208
- src: 'https://ucarecdn.com/06075225-af9e-460c-8e3c-6be63c0b773a/-/format/auto/',
209
- width: 1200,
210
- height: 480
211
- }
212
- }
163
+ normal: {
164
+ size: 'cover',
165
+ position: {
166
+ x: 50,
167
+ y: 50
168
+ },
169
+ repeat: 'no-repeat',
170
+ attachment: 'scroll',
171
+ image: {
172
+ src: 'https://ucarecdn.com/06075225-af9e-460c-8e3c-6be63c0b773a/-/format/auto/',
173
+ width: 1200,
174
+ height: 480
175
+ }
176
+ },
177
+ hover: {
178
+ size: 'cover',
179
+ position: {
180
+ x: 50,
181
+ y: 50
182
+ },
183
+ repeat: 'no-repeat',
184
+ attachment: 'scroll',
185
+ image: {
186
+ src: 'https://ucarecdn.com/06075225-af9e-460c-8e3c-6be63c0b773a/-/format/auto/',
187
+ width: 1200,
188
+ height: 480
213
189
  }
214
190
  }
215
191
  }
@@ -265,25 +241,17 @@ const ProductViewMoreSettings = [
265
241
  {
266
242
  id: 'boxShadowBtnV2',
267
243
  type: 'shadow-v2',
268
- devices: {
269
- desktop: {
270
- default: {
271
- normal: {}
272
- }
273
- }
244
+ default: {
245
+ normal: {}
274
246
  },
275
247
  compoDefaultValue: {
276
- desktop: {
277
- default: {
278
- normal: {
279
- type: 'shadow-2',
280
- distance: '12px',
281
- blur: '12px',
282
- spread: '0px',
283
- color: 'rgba(18, 18, 18, 0.2)',
284
- angle: 45
285
- }
286
- }
248
+ normal: {
249
+ type: 'shadow-2',
250
+ distance: '12px',
251
+ blur: '12px',
252
+ spread: '0px',
253
+ color: 'rgba(18, 18, 18, 0.2)',
254
+ angle: 45
287
255
  }
288
256
  }
289
257
  },
@@ -304,63 +272,47 @@ const ProductViewMoreSettings = [
304
272
  {
305
273
  id: 'roundedBtnV2',
306
274
  type: 'corner-v2',
307
- devices: {
308
- desktop: {
309
- default: {
310
- normal: {
311
- btrr: '0px',
312
- bblr: '0px',
313
- bbrr: '0px',
314
- btlr: '0px',
315
- radiusType: 'none'
316
- },
317
- hover: {
318
- btrr: '0px',
319
- bblr: '0px',
320
- bbrr: '0px',
321
- btlr: '0px',
322
- radiusType: 'none'
323
- }
324
- }
275
+ default: {
276
+ normal: {
277
+ btrr: '0px',
278
+ bblr: '0px',
279
+ bbrr: '0px',
280
+ btlr: '0px',
281
+ radiusType: 'none'
282
+ },
283
+ hover: {
284
+ btrr: '0px',
285
+ bblr: '0px',
286
+ bbrr: '0px',
287
+ btlr: '0px',
288
+ radiusType: 'none'
325
289
  }
326
290
  },
327
291
  compoDefaultValue: {
328
- desktop: {
329
- default: {
330
- normal: {
331
- btrr: '8px',
332
- bblr: '8px',
333
- bbrr: '8px',
334
- btlr: '8px',
335
- radiusType: 'rounded'
336
- },
337
- hover: {
338
- btrr: '8px',
339
- bblr: '8px',
340
- bbrr: '8px',
341
- btlr: '8px',
342
- radiusType: 'rounded'
343
- }
344
- }
292
+ normal: {
293
+ btrr: '8px',
294
+ bblr: '8px',
295
+ bbrr: '8px',
296
+ btlr: '8px',
297
+ radiusType: 'rounded'
298
+ },
299
+ hover: {
300
+ btrr: '8px',
301
+ bblr: '8px',
302
+ bbrr: '8px',
303
+ btlr: '8px',
304
+ radiusType: 'rounded'
345
305
  }
346
306
  }
347
307
  },
348
308
  {
349
309
  id: 'textColorHover',
350
310
  type: 'color-picker-v2',
351
- devices: {
352
- desktop: {
353
- default: {
354
- hover: 'text-3'
355
- }
356
- }
311
+ default: {
312
+ hover: 'text-3'
357
313
  },
358
314
  compoDefaultValue: {
359
- desktop: {
360
- default: {
361
- hover: 'text-3'
362
- }
363
- }
315
+ hover: 'text-3'
364
316
  }
365
317
  },
366
318
  {
@@ -93,7 +93,7 @@ const Tabs = (props)=>{
93
93
  const textClasses = system.createClass({
94
94
  ...getClasses.getTextClasses()
95
95
  });
96
- const childrenItemRender = ()=>childItem?.map((item)=>item.replaceAll("'", '''))?.map((item, index)=>{
96
+ const childrenItemRender = ()=>childItem?.map((item)=>item?.replaceAll("'", '''))?.map((item, index)=>{
97
97
  const isActive = false;
98
98
  const val = helpers.getDynamicSourceLocales({
99
99
  val: item,
@@ -146,7 +146,7 @@ const Tabs = (props)=>{
146
146
  }}
147
147
  style="${wrapperStyle}"
148
148
  class="${wrapperClasses}"
149
- gp-data='${JSON.stringify(stateData).replaceAll("'", ''')}'>
149
+ gp-data='${JSON.stringify(stateData)?.replaceAll("'", ''')}'>
150
150
  <style>${styleTagClasses}</style>
151
151
  <div class="${containClasses}">
152
152
  <div class="${tabParentListClasses}" style="${tabParentListStyle}">
@@ -56,17 +56,17 @@ const config = {
56
56
  type: 'select',
57
57
  options: [
58
58
  {
59
- label: 'Frequently bought together',
60
- value: 'lb-upsell-fbt-block',
59
+ label: 'FBT List',
60
+ value: 'lb-upsell-widget-bl',
61
61
  maxOption: 1
62
62
  },
63
63
  {
64
- label: 'Product add-ons',
65
- value: 'lb-upsell-addon-block',
64
+ label: 'Add-ons List',
65
+ value: 'lb-upsell-widget-pal',
66
66
  maxOption: 1
67
67
  }
68
68
  ],
69
- default: 'lb-upsell-fbt-block'
69
+ default: 'lb-upsell-widget-bl'
70
70
  },
71
71
  {
72
72
  id: 'install',
@@ -265,65 +265,49 @@ const ArticleReadMoreSettings = [
265
265
  {
266
266
  id: 'borderBtnV2',
267
267
  type: 'border-v2',
268
- devices: {
269
- desktop: {
270
- default: {
271
- normal: {
272
- borderType: 'none',
273
- border: 'none',
274
- borderWidth: '1px',
275
- width: '1px 1px 1px 1px',
276
- color: '#121212',
277
- isCustom: true
278
- },
279
- hover: {
280
- borderType: 'none',
281
- border: 'none',
282
- borderWidth: '1px',
283
- width: '1px 1px 1px 1px',
284
- color: '#121212',
285
- isCustom: true
286
- }
287
- }
268
+ default: {
269
+ normal: {
270
+ borderType: 'none',
271
+ border: 'none',
272
+ borderWidth: '1px',
273
+ width: '1px 1px 1px 1px',
274
+ color: '#121212',
275
+ isCustom: true
276
+ },
277
+ hover: {
278
+ borderType: 'none',
279
+ border: 'none',
280
+ borderWidth: '1px',
281
+ width: '1px 1px 1px 1px',
282
+ color: '#121212',
283
+ isCustom: true
288
284
  }
289
285
  },
290
286
  compoDefaultValue: {
291
- desktop: {
292
- default: {
293
- normal: {
294
- border: 'solid',
295
- color: '#121212',
296
- width: '1px',
297
- borderWidth: '1px'
298
- },
299
- hover: {
300
- border: 'solid',
301
- color: '#121212',
302
- width: '1px',
303
- borderWidth: '1px'
304
- }
305
- }
287
+ normal: {
288
+ border: 'solid',
289
+ color: '#121212',
290
+ width: '1px',
291
+ borderWidth: '1px'
292
+ },
293
+ hover: {
294
+ border: 'solid',
295
+ color: '#121212',
296
+ width: '1px',
297
+ borderWidth: '1px'
306
298
  }
307
299
  }
308
300
  },
309
301
  {
310
302
  id: 'backgroundColorV2',
311
303
  type: 'color-picker-v2',
312
- devices: {
313
- desktop: {
314
- default: {
315
- normal: 'brand',
316
- hover: 'highlight'
317
- }
318
- }
304
+ default: {
305
+ normal: 'brand',
306
+ hover: 'highlight'
319
307
  },
320
308
  compoDefaultValue: {
321
- desktop: {
322
- default: {
323
- normal: 'brand',
324
- hover: 'highlight'
325
- }
326
- }
309
+ normal: 'brand',
310
+ hover: 'highlight'
327
311
  }
328
312
  },
329
313
  {
@@ -342,31 +326,23 @@ const ArticleReadMoreSettings = [
342
326
  {
343
327
  id: 'backgroundImage',
344
328
  type: 'background-image',
345
- devices: {
346
- desktop: {
347
- default: {
348
- normal: {},
349
- hover: {}
350
- }
351
- }
329
+ default: {
330
+ normal: {},
331
+ hover: {}
352
332
  },
353
333
  compoDefaultValue: {
354
- desktop: {
355
- default: {
356
- normal: {
357
- image: {
358
- src: 'https://ucarecdn.com/06075225-af9e-460c-8e3c-6be63c0b773a/-/format/auto/',
359
- width: 1200,
360
- height: 480
361
- }
362
- },
363
- hover: {
364
- image: {
365
- src: 'https://ucarecdn.com/06075225-af9e-460c-8e3c-6be63c0b773a/-/format/auto/',
366
- width: 1200,
367
- height: 480
368
- }
369
- }
334
+ normal: {
335
+ image: {
336
+ src: 'https://ucarecdn.com/06075225-af9e-460c-8e3c-6be63c0b773a/-/format/auto/',
337
+ width: 1200,
338
+ height: 480
339
+ }
340
+ },
341
+ hover: {
342
+ image: {
343
+ src: 'https://ucarecdn.com/06075225-af9e-460c-8e3c-6be63c0b773a/-/format/auto/',
344
+ width: 1200,
345
+ height: 480
370
346
  }
371
347
  }
372
348
  }
@@ -387,19 +363,11 @@ const ArticleReadMoreSettings = [
387
363
  {
388
364
  id: 'textColorHover',
389
365
  type: 'color-picker-v2',
390
- devices: {
391
- desktop: {
392
- default: {
393
- hover: 'text-3'
394
- }
395
- }
366
+ default: {
367
+ hover: 'text-3'
396
368
  },
397
369
  compoDefaultValue: {
398
- desktop: {
399
- default: {
400
- hover: 'text-3'
401
- }
402
- }
370
+ hover: 'text-3'
403
371
  },
404
372
  enableGradient: true
405
373
  },
@@ -420,69 +388,53 @@ const ArticleReadMoreSettings = [
420
388
  {
421
389
  id: 'roundedBtnV2',
422
390
  type: 'corner-v2',
423
- devices: {
424
- desktop: {
425
- default: {
426
- normal: {
427
- btrr: '0px',
428
- bblr: '0px',
429
- bbrr: '0px',
430
- btlr: '0px',
431
- radiusType: 'none'
432
- },
433
- hover: {
434
- btrr: '0px',
435
- bblr: '0px',
436
- bbrr: '0px',
437
- btlr: '0px',
438
- radiusType: 'none'
439
- }
440
- }
391
+ default: {
392
+ normal: {
393
+ btrr: '0px',
394
+ bblr: '0px',
395
+ bbrr: '0px',
396
+ btlr: '0px',
397
+ radiusType: 'none'
398
+ },
399
+ hover: {
400
+ btrr: '0px',
401
+ bblr: '0px',
402
+ bbrr: '0px',
403
+ btlr: '0px',
404
+ radiusType: 'none'
441
405
  }
442
406
  },
443
407
  compoDefaultValue: {
444
- desktop: {
445
- default: {
446
- normal: {
447
- btrr: '8px',
448
- bblr: '8px',
449
- bbrr: '8px',
450
- btlr: '8px',
451
- radiusType: 'rounded'
452
- },
453
- hover: {
454
- btrr: '8px',
455
- bblr: '8px',
456
- bbrr: '8px',
457
- btlr: '8px',
458
- radiusType: 'rounded'
459
- }
460
- }
408
+ normal: {
409
+ btrr: '8px',
410
+ bblr: '8px',
411
+ bbrr: '8px',
412
+ btlr: '8px',
413
+ radiusType: 'rounded'
414
+ },
415
+ hover: {
416
+ btrr: '8px',
417
+ bblr: '8px',
418
+ bbrr: '8px',
419
+ btlr: '8px',
420
+ radiusType: 'rounded'
461
421
  }
462
422
  }
463
423
  },
464
424
  {
465
425
  id: 'boxShadowBtnV2',
466
426
  type: 'shadow-v2',
467
- devices: {
468
- desktop: {
469
- default: {
470
- normal: {}
471
- }
472
- }
427
+ default: {
428
+ normal: {}
473
429
  },
474
430
  compoDefaultValue: {
475
- desktop: {
476
- default: {
477
- normal: {
478
- type: 'shadow-2',
479
- distance: '12px',
480
- blur: '12px',
481
- spread: '0px',
482
- color: 'rgba(18, 18, 18, 0.2)',
483
- angle: 45
484
- }
485
- }
431
+ normal: {
432
+ type: 'shadow-2',
433
+ distance: '12px',
434
+ blur: '12px',
435
+ spread: '0px',
436
+ color: 'rgba(18, 18, 18, 0.2)',
437
+ angle: 45
486
438
  }
487
439
  }
488
440
  }
@@ -12,15 +12,8 @@ const getCleanedStyles = (styles, disabled)=>{
12
12
  'hover',
13
13
  'focus'
14
14
  ];
15
- const devices = [
16
- 'tablet',
17
- 'mobile',
18
- 'desktop'
19
- ];
20
- devices.forEach((device)=>{
21
- states.forEach((state)=>{
22
- delete cleanedStyles?.backgroundColorV2?.[device]?.[state];
23
- });
15
+ states.forEach((state)=>{
16
+ delete cleanedStyles?.backgroundColorV2?.[state];
24
17
  });
25
18
  return cleanedStyles;
26
19
  };