@gem-sdk/components 2.0.0-dev.246 → 2.0.0-dev.248

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 (80) hide show
  1. package/dist/cjs/article/setting/configs/ArticleReadMore/settings.js +1 -1
  2. package/dist/cjs/article/setting/configs/ArticleReadMore/uiV2.js +4 -0
  3. package/dist/cjs/breadcrumb/setting/configs/settings.js +1 -1
  4. package/dist/cjs/breadcrumb/setting/configs/uiV2.js +2 -1
  5. package/dist/cjs/button/setting/configs/settings.js +1 -1
  6. package/dist/cjs/button/setting/configs/uiV2.js +2 -1
  7. package/dist/cjs/collection/setting/collection-description/configs/settings.js +1 -1
  8. package/dist/cjs/collection/setting/collection-description/configs/uiV2.js +2 -1
  9. package/dist/cjs/collection/setting/collection-toolbar/configs/settings.js +1 -1
  10. package/dist/cjs/collection/setting/collection-toolbar/configs/uiV2.js +2 -1
  11. package/dist/cjs/form/setting/submit-button/configs/settings.js +1 -1
  12. package/dist/cjs/form/setting/submit-button/configs/uiV2.js +2 -1
  13. package/dist/cjs/image-comparison/setting/configs/settings.js +1 -1
  14. package/dist/cjs/image-comparison/setting/configs/uiV2.js +2 -1
  15. package/dist/cjs/marquee/setting/configs/settingsV2.js +1 -1
  16. package/dist/cjs/marquee/setting/configs/uiV2.js +2 -1
  17. package/dist/cjs/post-purchase/callout-banner/setting/config/callout-text/setting.js +21 -3
  18. package/dist/cjs/post-purchase/product/common/getAttrs.js +10 -0
  19. package/dist/cjs/post-purchase/product/common/getClasses.js +12 -0
  20. package/dist/cjs/post-purchase/product/common/getSettings.js +9 -0
  21. package/dist/cjs/post-purchase/product/common/getStyles.js +10 -0
  22. package/dist/cjs/post-purchase/product/components/ProductDiscountTag.js +34 -13
  23. package/dist/cjs/post-purchase/product/settings/index.js +1 -1
  24. package/dist/cjs/post-purchase/product/settings/{ProductDiscountTag.js → product-discount-tag/ProductDiscountTag.js} +7 -89
  25. package/dist/cjs/post-purchase/product/settings/product-discount-tag/settingV2.js +63 -0
  26. package/dist/cjs/post-purchase/product/settings/product-discount-tag/uiV1.js +52 -0
  27. package/dist/cjs/post-purchase/product/settings/product-discount-tag/uiV2.js +67 -0
  28. package/dist/cjs/product/setting/product-button/configs/settings.js +2 -2
  29. package/dist/cjs/product/setting/product-button/configs/uiV2.js +4 -2
  30. package/dist/cjs/product/setting/product-description/configs/settings.js +1 -1
  31. package/dist/cjs/product/setting/product-description/configs/uiV2.js +2 -1
  32. package/dist/cjs/product/setting/product-list/configs/settingsV2.js +2 -2
  33. package/dist/cjs/product/setting/product-list/configs/uiV2.js +2 -1
  34. package/dist/cjs/product/setting/product-title/configs/settings.js +2 -2
  35. package/dist/cjs/product/setting/product-title/configs/uiV2.js +2 -1
  36. package/dist/cjs/product/setting/product-vendor/configs/settings.js +1 -1
  37. package/dist/cjs/product/setting/product-vendor/configs/uiV2.js +2 -1
  38. package/dist/cjs/stock-counter/setting/configs/settings.js +2 -2
  39. package/dist/cjs/stock-counter/setting/configs/uiV2.js +2 -1
  40. package/dist/esm/article/setting/configs/ArticleReadMore/settings.js +1 -1
  41. package/dist/esm/article/setting/configs/ArticleReadMore/uiV2.js +4 -0
  42. package/dist/esm/breadcrumb/setting/configs/settings.js +1 -1
  43. package/dist/esm/breadcrumb/setting/configs/uiV2.js +2 -1
  44. package/dist/esm/button/setting/configs/settings.js +1 -1
  45. package/dist/esm/button/setting/configs/uiV2.js +2 -1
  46. package/dist/esm/collection/setting/collection-description/configs/settings.js +1 -1
  47. package/dist/esm/collection/setting/collection-description/configs/uiV2.js +2 -1
  48. package/dist/esm/collection/setting/collection-toolbar/configs/settings.js +1 -1
  49. package/dist/esm/collection/setting/collection-toolbar/configs/uiV2.js +2 -1
  50. package/dist/esm/form/setting/submit-button/configs/settings.js +1 -1
  51. package/dist/esm/form/setting/submit-button/configs/uiV2.js +2 -1
  52. package/dist/esm/image-comparison/setting/configs/settings.js +1 -1
  53. package/dist/esm/image-comparison/setting/configs/uiV2.js +2 -1
  54. package/dist/esm/marquee/setting/configs/settingsV2.js +1 -1
  55. package/dist/esm/marquee/setting/configs/uiV2.js +2 -1
  56. package/dist/esm/post-purchase/callout-banner/setting/config/callout-text/setting.js +21 -3
  57. package/dist/esm/post-purchase/product/common/getAttrs.js +8 -0
  58. package/dist/esm/post-purchase/product/common/getClasses.js +10 -0
  59. package/dist/esm/post-purchase/product/common/getSettings.js +7 -0
  60. package/dist/esm/post-purchase/product/common/getStyles.js +8 -0
  61. package/dist/esm/post-purchase/product/components/ProductDiscountTag.js +35 -14
  62. package/dist/esm/post-purchase/product/settings/index.js +1 -1
  63. package/dist/esm/post-purchase/product/settings/{ProductDiscountTag.js → product-discount-tag/ProductDiscountTag.js} +7 -89
  64. package/dist/esm/post-purchase/product/settings/product-discount-tag/settingV2.js +61 -0
  65. package/dist/esm/post-purchase/product/settings/product-discount-tag/uiV1.js +50 -0
  66. package/dist/esm/post-purchase/product/settings/product-discount-tag/uiV2.js +65 -0
  67. package/dist/esm/product/setting/product-button/configs/settings.js +2 -2
  68. package/dist/esm/product/setting/product-button/configs/uiV2.js +4 -2
  69. package/dist/esm/product/setting/product-description/configs/settings.js +1 -1
  70. package/dist/esm/product/setting/product-description/configs/uiV2.js +2 -1
  71. package/dist/esm/product/setting/product-list/configs/settingsV2.js +2 -2
  72. package/dist/esm/product/setting/product-list/configs/uiV2.js +2 -1
  73. package/dist/esm/product/setting/product-title/configs/settings.js +2 -2
  74. package/dist/esm/product/setting/product-title/configs/uiV2.js +2 -1
  75. package/dist/esm/product/setting/product-vendor/configs/settings.js +1 -1
  76. package/dist/esm/product/setting/product-vendor/configs/uiV2.js +2 -1
  77. package/dist/esm/stock-counter/setting/configs/settings.js +2 -2
  78. package/dist/esm/stock-counter/setting/configs/uiV2.js +2 -1
  79. package/dist/types/index.d.ts +16 -14
  80. package/package.json +2 -2
@@ -29,7 +29,7 @@ const ProductDescriptionSettings = [
29
29
  {
30
30
  id: 'hasLineClamp',
31
31
  label: 'Enable View More',
32
- type: 'switch',
32
+ type: 'toggle',
33
33
  devices: {
34
34
  desktop: {
35
35
  default: true
@@ -39,7 +39,8 @@ const SettingUIV2 = [
39
39
  id: 'hasLineClamp'
40
40
  },
41
41
  options: {
42
- labelVariant: 'primary'
42
+ labelVariant: 'primary',
43
+ toggleStyle: 'switch'
43
44
  }
44
45
  },
45
46
  {
@@ -54,7 +54,7 @@ const ProductListSettingsV2 = [
54
54
  {
55
55
  id: 'dot',
56
56
  label: 'Dot',
57
- type: 'switch',
57
+ type: 'toggle',
58
58
  devices: {
59
59
  desktop: {
60
60
  default: false
@@ -135,7 +135,7 @@ const ProductListSettingsV2 = [
135
135
  {
136
136
  id: 'arrow',
137
137
  label: 'Next/Prev Arrow',
138
- type: 'switch',
138
+ type: 'toggle',
139
139
  devices: {
140
140
  desktop: {
141
141
  default: false
@@ -158,7 +158,8 @@ const SettingUIV2 = [
158
158
  id: 'dot'
159
159
  },
160
160
  options: {
161
- labelVariant: 'primary'
161
+ labelVariant: 'primary',
162
+ toggleStyle: 'switch'
162
163
  }
163
164
  },
164
165
  {
@@ -43,7 +43,7 @@ const ProductTitleSettings = [
43
43
  {
44
44
  id: 'linkProduct',
45
45
  label: 'Link To Product',
46
- type: 'switch',
46
+ type: 'toggle',
47
47
  default: false,
48
48
  info: 'Ability to click on product title to goto product detail page.'
49
49
  }
@@ -100,7 +100,7 @@ const ProductTitleSettings = [
100
100
  },
101
101
  {
102
102
  id: 'hasLineClamp',
103
- type: 'switch',
103
+ type: 'toggle',
104
104
  label: 'Has Line Clamp',
105
105
  devices: {
106
106
  desktop: {
@@ -75,7 +75,8 @@ const SettingUIV2 = [
75
75
  id: 'linkProduct'
76
76
  },
77
77
  options: {
78
- labelVariant: 'primary'
78
+ labelVariant: 'primary',
79
+ toggleStyle: 'switch'
79
80
  }
80
81
  }
81
82
  ]
@@ -13,7 +13,7 @@ const ProductVendorSettings = [
13
13
  {
14
14
  id: 'url',
15
15
  label: 'Open collection URL',
16
- type: 'switch',
16
+ type: 'toggle',
17
17
  default: false
18
18
  },
19
19
  {
@@ -102,7 +102,8 @@ const SettingUIV2 = [
102
102
  id: 'url'
103
103
  },
104
104
  options: {
105
- labelVariant: 'primary'
105
+ labelVariant: 'primary',
106
+ toggleStyle: 'switch'
106
107
  },
107
108
  help: {
108
109
  content: `Click to open a collection page with all products from the same vendor.`
@@ -102,7 +102,7 @@ const StockCounterSettings = [
102
102
  {
103
103
  id: 'showIcon',
104
104
  label: 'Show Icon',
105
- type: 'switch',
105
+ type: 'toggle',
106
106
  default: true
107
107
  },
108
108
  {
@@ -227,7 +227,7 @@ const StockCounterSettings = [
227
227
  {
228
228
  id: 'displayProgressBar',
229
229
  label: 'Display',
230
- type: 'switch',
230
+ type: 'toggle',
231
231
  default: true
232
232
  },
233
233
  {
@@ -71,7 +71,8 @@ const SettingUIV2 = [
71
71
  id: 'showIcon'
72
72
  },
73
73
  options: {
74
- labelVariant: 'primary'
74
+ labelVariant: 'primary',
75
+ toggleStyle: 'switch'
75
76
  }
76
77
  },
77
78
  {
@@ -38,7 +38,7 @@ const ArticleReadMoreSettings = [
38
38
  {
39
39
  id: 'iconVisible',
40
40
  label: 'Icon Visible',
41
- type: 'switch',
41
+ type: 'toggle',
42
42
  default: false
43
43
  },
44
44
  {
@@ -322,6 +322,10 @@ const uiV2 = [
322
322
  },
323
323
  setting: {
324
324
  id: 'iconVisible'
325
+ },
326
+ options: {
327
+ labelVariant: 'primary',
328
+ toggleStyle: 'switch'
325
329
  }
326
330
  }
327
331
  ]
@@ -4,7 +4,7 @@ const BreadcrumbSettings = [
4
4
  controls: [
5
5
  {
6
6
  id: 'hideCurrentPage',
7
- type: 'switch',
7
+ type: 'toggle',
8
8
  label: 'Hide current page',
9
9
  devices: {
10
10
  desktop: {
@@ -9,7 +9,8 @@ const SettingUIV2 = [
9
9
  id: 'hideCurrentPage'
10
10
  },
11
11
  options: {
12
- labelVariant: 'primary'
12
+ labelVariant: 'primary',
13
+ toggleStyle: 'switch'
13
14
  }
14
15
  }
15
16
  ]
@@ -35,7 +35,7 @@ const ButtonSettings = [
35
35
  {
36
36
  id: 'iconVisible',
37
37
  label: 'Icon Visible',
38
- type: 'switch',
38
+ type: 'toggle',
39
39
  default: false
40
40
  },
41
41
  {
@@ -197,7 +197,8 @@ const SettingUIV2 = [
197
197
  id: 'iconVisible'
198
198
  },
199
199
  options: {
200
- labelVariant: 'primary'
200
+ labelVariant: 'primary',
201
+ toggleStyle: 'switch'
201
202
  }
202
203
  },
203
204
  {
@@ -27,7 +27,7 @@ const CollectionDescriptionSettings = [
27
27
  {
28
28
  id: 'hasLineClamp',
29
29
  label: 'Enable View More',
30
- type: 'switch',
30
+ type: 'toggle',
31
31
  devices: {
32
32
  desktop: {
33
33
  default: true
@@ -51,7 +51,8 @@ const SettingUIV2 = [
51
51
  id: 'hasLineClamp'
52
52
  },
53
53
  options: {
54
- labelVariant: 'primary'
54
+ labelVariant: 'primary',
55
+ toggleStyle: 'switch'
55
56
  }
56
57
  },
57
58
  {
@@ -10,7 +10,7 @@ const CollectionToolbarSettings = [
10
10
  },
11
11
  {
12
12
  id: 'displayQuantity',
13
- type: 'switch',
13
+ type: 'toggle',
14
14
  label: 'Quantity text',
15
15
  default: true
16
16
  },
@@ -40,7 +40,8 @@ const SettingUIV2 = [
40
40
  id: 'displayQuantity'
41
41
  },
42
42
  options: {
43
- labelVariant: 'primary'
43
+ labelVariant: 'primary',
44
+ toggleStyle: 'switch'
44
45
  }
45
46
  },
46
47
  {
@@ -16,7 +16,7 @@ const SubmitButtonSettings = [
16
16
  {
17
17
  id: 'iconVisible',
18
18
  label: 'Icon Visible',
19
- type: 'switch',
19
+ type: 'toggle',
20
20
  default: false
21
21
  },
22
22
  {
@@ -167,7 +167,8 @@ const SettingUIV2 = [
167
167
  id: 'iconVisible'
168
168
  },
169
169
  options: {
170
- labelVariant: 'primary'
170
+ labelVariant: 'primary',
171
+ toggleStyle: 'switch'
171
172
  }
172
173
  },
173
174
  {
@@ -121,7 +121,7 @@ const ImageComparisonSettings = [
121
121
  },
122
122
  {
123
123
  id: 'enableLabel',
124
- type: 'switch',
124
+ type: 'toggle',
125
125
  default: false
126
126
  },
127
127
  {
@@ -171,7 +171,8 @@ const SettingUIV2 = [
171
171
  id: 'enableLabel'
172
172
  },
173
173
  options: {
174
- labelVariant: 'primary'
174
+ labelVariant: 'primary',
175
+ toggleStyle: 'switch'
175
176
  }
176
177
  },
177
178
  {
@@ -29,7 +29,7 @@ const MarqueeSettingsV2 = [
29
29
  {
30
30
  id: 'isShowIconSeparator',
31
31
  label: 'isShowIconSeparator',
32
- type: 'switch',
32
+ type: 'toggle',
33
33
  default: false
34
34
  },
35
35
  {
@@ -102,7 +102,8 @@ const SettingUIV2 = [
102
102
  id: 'isShowIconSeparator'
103
103
  },
104
104
  options: {
105
- labelVariant: 'primary'
105
+ labelVariant: 'primary',
106
+ toggleStyle: 'switch'
106
107
  }
107
108
  },
108
109
  {
@@ -89,13 +89,14 @@ const CalloutTextSettings = [
89
89
  },
90
90
  {
91
91
  id: 'width',
92
- type: 'input:unit-width',
92
+ type: 'dropdown:input',
93
93
  label: 'Width',
94
- min: 0,
94
+ inputType: 'number',
95
95
  units: [
96
96
  'px',
97
97
  '%'
98
98
  ],
99
+ hideUnit: false,
99
100
  devices: {
100
101
  desktop: {
101
102
  default: '100%'
@@ -106,7 +107,24 @@ const CalloutTextSettings = [
106
107
  mobile: {
107
108
  default: '100%'
108
109
  }
109
- }
110
+ },
111
+ displayOptions: [
112
+ {
113
+ label: 'Fit content',
114
+ value: 'Auto',
115
+ showValue: true
116
+ },
117
+ {
118
+ label: 'Full',
119
+ value: '100%',
120
+ showValue: true
121
+ },
122
+ {
123
+ label: 'Default',
124
+ value: 'default',
125
+ showValue: true
126
+ }
127
+ ]
110
128
  },
111
129
  {
112
130
  id: 'direction',
@@ -0,0 +1,8 @@
1
+ const getContainerAttrs = ({ currentProductId, uid })=>{
2
+ return {
3
+ id: `shopify-text-element-${uid}`,
4
+ 'data-product-id': currentProductId || ''
5
+ };
6
+ };
7
+
8
+ export { getContainerAttrs };
@@ -0,0 +1,10 @@
1
+ import { composeClasses } from '@gem-sdk/core';
2
+
3
+ const getContainerClasses = ({ uid })=>{
4
+ return {
5
+ ...composeClasses(uid),
6
+ ...composeClasses('gp-flex gp-w-full')
7
+ };
8
+ };
9
+
10
+ export { getContainerClasses };
@@ -0,0 +1,7 @@
1
+ const getTextSettings = ({ hasDiscount, message })=>{
2
+ return {
3
+ text: hasDiscount ? message : message?.replace(new RegExp(/\{\{Discount\}\}/, 'gi'), '0%')
4
+ };
5
+ };
6
+
7
+ export { getTextSettings };
@@ -0,0 +1,8 @@
1
+ const getContainerStyles = ({ style, hasDiscount })=>{
2
+ return {
3
+ ...style,
4
+ opacity: hasDiscount ? 1 : 0.2
5
+ };
6
+ };
7
+
8
+ export { getContainerStyles };
@@ -1,33 +1,54 @@
1
1
  'use client';
2
2
  import { jsxs, jsx } from 'react/jsx-runtime';
3
- import { useProduct, useProductOfferDiscount, cls } from '@gem-sdk/core';
3
+ import { useProduct, useProductOfferDiscount } from '@gem-sdk/core';
4
4
  import Text from '../../text/components/Text.js';
5
5
  import { useDynamicProduct } from '../hooks/useDynamicProduct.js';
6
+ import { createClass, createAttr, createStyle } from '@gem-sdk/system';
7
+ import { getContainerAttrs } from '../common/getAttrs.js';
8
+ import { getContainerClasses } from '../common/getClasses.js';
9
+ import { getContainerStyles } from '../common/getStyles.js';
10
+ import { getTextSettings } from '../common/getSettings.js';
6
11
 
7
12
  const PostPurchaseProductDiscountTag = ({ setting = {}, styles = {}, style, builderAttrs, builderProps, children })=>{
8
13
  const currentProduct = useProduct();
9
14
  const currentProductId = currentProduct?.baseID?.replace('gid://shopify/Product/', '');
10
15
  const currentOfferDiscount = useProductOfferDiscount();
11
16
  const { isDynamicProduct, isEnableDynamicDiscount } = useDynamicProduct();
12
- const { typo } = styles;
17
+ const { typo, direction } = styles;
13
18
  const { message } = setting;
14
19
  const hasDiscount = !!currentOfferDiscount || isDynamicProduct && isEnableDynamicDiscount;
20
+ const containerClasses = createClass({
21
+ ...getContainerClasses({
22
+ uid: builderProps?.uid
23
+ })
24
+ });
25
+ const containerAttrs = createAttr({
26
+ ...getContainerAttrs({
27
+ ...builderAttrs,
28
+ currentProductId,
29
+ uid: builderProps?.uid
30
+ })
31
+ });
32
+ const containerStyles = createStyle({
33
+ ...getContainerStyles({
34
+ style,
35
+ hasDiscount
36
+ })
37
+ });
38
+ const textSettings = getTextSettings({
39
+ hasDiscount,
40
+ message
41
+ });
15
42
  return /*#__PURE__*/ jsxs("div", {
16
- ...builderAttrs,
17
- className: cls(builderProps?.uid, 'gp-flex gp-w-full'),
18
- style: {
19
- ...style,
20
- opacity: hasDiscount ? 1 : 0.2
21
- },
22
- id: `shopify-text-element-${builderProps?.uid}`,
23
- "data-product-id": currentProductId,
43
+ ...containerAttrs,
44
+ className: containerClasses,
45
+ style: containerStyles,
24
46
  children: [
25
47
  /*#__PURE__*/ jsx(Text, {
26
- setting: {
27
- text: hasDiscount ? message : message?.replace(new RegExp(/\{\{Discount\}\}/, 'gi'), '0%')
28
- },
48
+ setting: textSettings,
29
49
  styles: {
30
- typo
50
+ typo,
51
+ direction
31
52
  }
32
53
  }),
33
54
  children
@@ -6,7 +6,7 @@ import config$3 from './product-variants/ProductVariant.js';
6
6
  import config$5 from './product-quantity/index.js';
7
7
  import config$7 from './ProductOffer.js';
8
8
  import config$6 from './product-price-breakdown/index.js';
9
- import config$8 from './ProductDiscountTag.js';
9
+ import config$8 from './product-discount-tag/ProductDiscountTag.js';
10
10
  import config$9 from './product-image/ProductImages.js';
11
11
 
12
12
  var postPurchaseProductSetting = {
@@ -1,96 +1,14 @@
1
+ import { settingV2 } from './settingV2.js';
2
+ import { uiV1 } from './uiV1.js';
3
+ import { uiV2 } from './uiV2.js';
4
+
1
5
  const config = {
2
6
  tag: 'PostPurchaseProductDiscountTag',
3
7
  label: 'Discount Tag',
4
8
  icon: ``,
5
- settings: [
6
- {
7
- id: 'setting',
8
- controls: [
9
- {
10
- id: 'discountAndShippingFee',
11
- type: 'discount-and-shipping-fee-product-offer',
12
- multiple: false
13
- },
14
- {
15
- id: 'message',
16
- label: '',
17
- type: 'textarea',
18
- autoHeight: true,
19
- default: '(Save {{Discount}})',
20
- suggestContents: [
21
- {
22
- message: '{{Discount}}',
23
- eg: '20%'
24
- }
25
- ]
26
- }
27
- ]
28
- },
29
- {
30
- id: 'style',
31
- controls: [
32
- {
33
- id: 'typo',
34
- label: 'Label',
35
- type: 'typography-post-purchase',
36
- default: {
37
- fontSize: 'default',
38
- textColor: 'critical',
39
- fontWeight: 'bold',
40
- textTransform: 'none'
41
- }
42
- }
43
- ]
44
- }
45
- ],
46
- ui: [
47
- {
48
- type: 'group',
49
- label: {
50
- en: ''
51
- },
52
- controls: [
53
- {
54
- type: 'control',
55
- label: {
56
- en: ''
57
- },
58
- setting: {
59
- id: 'discountAndShippingFee'
60
- },
61
- layout: 'vertical'
62
- }
63
- ]
64
- },
65
- {
66
- type: 'group',
67
- label: {
68
- en: 'Text'
69
- },
70
- controls: [
71
- {
72
- type: 'control',
73
- label: {
74
- en: ''
75
- },
76
- setting: {
77
- id: 'message'
78
- },
79
- layout: 'vertical'
80
- },
81
- {
82
- type: 'control',
83
- label: {
84
- en: ''
85
- },
86
- setting: {
87
- id: 'typo'
88
- },
89
- layout: 'vertical'
90
- }
91
- ]
92
- }
93
- ],
9
+ settings: settingV2,
10
+ ui: uiV1,
11
+ uiV2: uiV2,
94
12
  editorConfigs: {
95
13
  placeholder: {
96
14
  flowTag: [
@@ -0,0 +1,61 @@
1
+ const settingV2 = [
2
+ {
3
+ id: 'setting',
4
+ controls: [
5
+ {
6
+ id: 'discountAndShippingFee',
7
+ type: 'discount-and-shipping-fee-product-offer',
8
+ multiple: false
9
+ },
10
+ {
11
+ id: 'message',
12
+ label: '',
13
+ type: 'textarea',
14
+ defaultRows: 4,
15
+ showPlusBtn: true,
16
+ autoHeight: true,
17
+ default: '(Save {{Discount}})',
18
+ suggestContents: [
19
+ {
20
+ message: '{{Discount}}',
21
+ eg: '20%'
22
+ }
23
+ ]
24
+ }
25
+ ]
26
+ },
27
+ {
28
+ id: 'style',
29
+ controls: [
30
+ {
31
+ id: 'direction',
32
+ label: 'Direction',
33
+ type: 'segment',
34
+ options: [
35
+ {
36
+ label: 'LTR',
37
+ value: 'ltr'
38
+ },
39
+ {
40
+ label: 'RTL',
41
+ value: 'rtl'
42
+ }
43
+ ],
44
+ default: 'ltr'
45
+ },
46
+ {
47
+ id: 'typo',
48
+ label: 'Label',
49
+ type: 'typography-post-purchase',
50
+ default: {
51
+ fontSize: 'default',
52
+ textColor: 'critical',
53
+ fontWeight: 'bold',
54
+ textTransform: 'none'
55
+ }
56
+ }
57
+ ]
58
+ }
59
+ ];
60
+
61
+ export { settingV2 };