@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.
- package/dist/cjs/article/setting/configs/ArticleReadMore/settings.js +86 -134
- package/dist/cjs/button/components/common/helpers.js +2 -9
- package/dist/cjs/button/components/common/styles.js +14 -81
- package/dist/cjs/button/setting/configs/settings.js +85 -133
- package/dist/cjs/coupon/common/classes.js +3 -12
- package/dist/cjs/coupon/common/styles.js +7 -17
- package/dist/cjs/coupon/setting/config/settings.js +60 -100
- package/dist/cjs/form/setting/submit-button/configs/settings.js +103 -250
- package/dist/cjs/product/components/DynamicCheckout/common/styles.js +12 -12
- package/dist/cjs/product/components/ProductBadge/index.liquid.js +1 -1
- package/dist/cjs/product/components/ProductButton/common/styles.js +4 -14
- package/dist/cjs/product/components/ProductImagesV2/common/common.js +1 -1
- package/dist/cjs/product/setting/dynamic-checkout/configs/settings.js +86 -134
- package/dist/cjs/product/setting/product-button/configs/settings.js +142 -222
- package/dist/cjs/product/setting/product-view-more/configs/settings.js +100 -148
- package/dist/cjs/tab/components/Tabs.liquid.js +2 -2
- package/dist/cjs/third-party/setting/Selleasy/index.js +5 -5
- package/dist/esm/article/setting/configs/ArticleReadMore/settings.js +86 -134
- package/dist/esm/button/components/common/helpers.js +2 -9
- package/dist/esm/button/components/common/styles.js +16 -81
- package/dist/esm/button/setting/configs/settings.js +85 -133
- package/dist/esm/coupon/common/classes.js +3 -12
- package/dist/esm/coupon/common/styles.js +7 -17
- package/dist/esm/coupon/setting/config/settings.js +60 -100
- package/dist/esm/form/setting/submit-button/configs/settings.js +103 -250
- package/dist/esm/product/components/DynamicCheckout/common/styles.js +12 -12
- package/dist/esm/product/components/ProductBadge/index.liquid.js +1 -1
- package/dist/esm/product/components/ProductButton/common/styles.js +4 -14
- package/dist/esm/product/components/ProductImagesV2/common/common.js +1 -1
- package/dist/esm/product/setting/dynamic-checkout/configs/settings.js +86 -134
- package/dist/esm/product/setting/product-button/configs/settings.js +142 -222
- package/dist/esm/product/setting/product-view-more/configs/settings.js +100 -148
- package/dist/esm/tab/components/Tabs.liquid.js +2 -2
- package/dist/esm/third-party/setting/Selleasy/index.js +5 -5
- package/dist/types/index.d.ts +23 -23
- package/package.json +2 -2
|
@@ -126,44 +126,36 @@ const ButtonSettings = [
|
|
|
126
126
|
{
|
|
127
127
|
id: 'borderBtnV2',
|
|
128
128
|
type: 'border-v2',
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
color: '#121212',
|
|
146
|
-
isCustom: true
|
|
147
|
-
}
|
|
148
|
-
}
|
|
129
|
+
default: {
|
|
130
|
+
normal: {
|
|
131
|
+
borderType: 'none',
|
|
132
|
+
border: 'none',
|
|
133
|
+
borderWidth: '1px',
|
|
134
|
+
width: '1px 1px 1px 1px',
|
|
135
|
+
color: '#121212',
|
|
136
|
+
isCustom: true
|
|
137
|
+
},
|
|
138
|
+
hover: {
|
|
139
|
+
borderType: 'none',
|
|
140
|
+
border: 'none',
|
|
141
|
+
borderWidth: '1px',
|
|
142
|
+
width: '1px 1px 1px 1px',
|
|
143
|
+
color: '#121212',
|
|
144
|
+
isCustom: true
|
|
149
145
|
}
|
|
150
146
|
},
|
|
151
147
|
compoDefaultValue: {
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
width: '1px',
|
|
164
|
-
borderWidth: '1px'
|
|
165
|
-
}
|
|
166
|
-
}
|
|
148
|
+
normal: {
|
|
149
|
+
border: 'solid',
|
|
150
|
+
color: '#121212',
|
|
151
|
+
width: '1px',
|
|
152
|
+
borderWidth: '1px'
|
|
153
|
+
},
|
|
154
|
+
hover: {
|
|
155
|
+
border: 'solid',
|
|
156
|
+
color: '#121212',
|
|
157
|
+
width: '1px',
|
|
158
|
+
borderWidth: '1px'
|
|
167
159
|
}
|
|
168
160
|
}
|
|
169
161
|
},
|
|
@@ -188,30 +180,22 @@ const ButtonSettings = [
|
|
|
188
180
|
{
|
|
189
181
|
id: 'roundedBtnV2',
|
|
190
182
|
type: 'corner-v2',
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
btlr: '0px',
|
|
199
|
-
radiusType: 'none'
|
|
200
|
-
}
|
|
201
|
-
}
|
|
183
|
+
default: {
|
|
184
|
+
normal: {
|
|
185
|
+
btrr: '0px',
|
|
186
|
+
bblr: '0px',
|
|
187
|
+
bbrr: '0px',
|
|
188
|
+
btlr: '0px',
|
|
189
|
+
radiusType: 'none'
|
|
202
190
|
}
|
|
203
191
|
},
|
|
204
192
|
compoDefaultValue: {
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
btlr: '8px',
|
|
212
|
-
radiusType: 'rounded'
|
|
213
|
-
}
|
|
214
|
-
}
|
|
193
|
+
normal: {
|
|
194
|
+
btrr: '8px',
|
|
195
|
+
bblr: '8px',
|
|
196
|
+
bbrr: '8px',
|
|
197
|
+
btlr: '8px',
|
|
198
|
+
radiusType: 'rounded'
|
|
215
199
|
}
|
|
216
200
|
}
|
|
217
201
|
},
|
|
@@ -268,46 +252,30 @@ const ButtonSettings = [
|
|
|
268
252
|
{
|
|
269
253
|
id: 'boxShadowBtnV2',
|
|
270
254
|
type: 'shadow-v2',
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
default: {
|
|
274
|
-
normal: {}
|
|
275
|
-
}
|
|
276
|
-
}
|
|
255
|
+
default: {
|
|
256
|
+
normal: {}
|
|
277
257
|
},
|
|
278
258
|
compoDefaultValue: {
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
color: '#121212',
|
|
287
|
-
angle: 45
|
|
288
|
-
}
|
|
289
|
-
}
|
|
259
|
+
normal: {
|
|
260
|
+
type: 'shadow-1',
|
|
261
|
+
distance: '4px',
|
|
262
|
+
blur: '4px',
|
|
263
|
+
spread: '0px',
|
|
264
|
+
color: '#121212',
|
|
265
|
+
angle: 45
|
|
290
266
|
}
|
|
291
267
|
}
|
|
292
268
|
},
|
|
293
269
|
{
|
|
294
270
|
id: 'backgroundColorV2',
|
|
295
271
|
type: 'color-picker-v2',
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
normal: 'brand',
|
|
300
|
-
hover: 'highlight'
|
|
301
|
-
}
|
|
302
|
-
}
|
|
272
|
+
default: {
|
|
273
|
+
normal: 'brand',
|
|
274
|
+
hover: 'highlight'
|
|
303
275
|
},
|
|
304
276
|
compoDefaultValue: {
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
normal: 'brand',
|
|
308
|
-
hover: 'highlight'
|
|
309
|
-
}
|
|
310
|
-
}
|
|
277
|
+
normal: 'brand',
|
|
278
|
+
hover: 'highlight'
|
|
311
279
|
},
|
|
312
280
|
enableGradient: true
|
|
313
281
|
},
|
|
@@ -327,44 +295,36 @@ const ButtonSettings = [
|
|
|
327
295
|
{
|
|
328
296
|
id: 'backgroundImage',
|
|
329
297
|
type: 'background-image',
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
default: {
|
|
333
|
-
normal: {}
|
|
334
|
-
}
|
|
335
|
-
}
|
|
298
|
+
default: {
|
|
299
|
+
normal: {}
|
|
336
300
|
},
|
|
337
301
|
compoDefaultValue: {
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
width: 1200,
|
|
365
|
-
height: 480
|
|
366
|
-
}
|
|
367
|
-
}
|
|
302
|
+
normal: {
|
|
303
|
+
size: 'cover',
|
|
304
|
+
position: {
|
|
305
|
+
x: 50,
|
|
306
|
+
y: 50
|
|
307
|
+
},
|
|
308
|
+
repeat: 'no-repeat',
|
|
309
|
+
attachment: 'scroll',
|
|
310
|
+
image: {
|
|
311
|
+
src: 'https://ucarecdn.com/06075225-af9e-460c-8e3c-6be63c0b773a/-/format/auto/',
|
|
312
|
+
width: 1200,
|
|
313
|
+
height: 480
|
|
314
|
+
}
|
|
315
|
+
},
|
|
316
|
+
hover: {
|
|
317
|
+
size: 'cover',
|
|
318
|
+
position: {
|
|
319
|
+
x: 50,
|
|
320
|
+
y: 50
|
|
321
|
+
},
|
|
322
|
+
repeat: 'no-repeat',
|
|
323
|
+
attachment: 'scroll',
|
|
324
|
+
image: {
|
|
325
|
+
src: 'https://ucarecdn.com/06075225-af9e-460c-8e3c-6be63c0b773a/-/format/auto/',
|
|
326
|
+
width: 1200,
|
|
327
|
+
height: 480
|
|
368
328
|
}
|
|
369
329
|
}
|
|
370
330
|
}
|
|
@@ -425,19 +385,11 @@ const ButtonSettings = [
|
|
|
425
385
|
{
|
|
426
386
|
id: 'textColorHover',
|
|
427
387
|
type: 'color-picker-v2',
|
|
428
|
-
|
|
429
|
-
|
|
430
|
-
default: {
|
|
431
|
-
hover: 'text-3'
|
|
432
|
-
}
|
|
433
|
-
}
|
|
388
|
+
default: {
|
|
389
|
+
hover: 'text-3'
|
|
434
390
|
},
|
|
435
391
|
compoDefaultValue: {
|
|
436
|
-
|
|
437
|
-
default: {
|
|
438
|
-
hover: 'text-3'
|
|
439
|
-
}
|
|
440
|
-
}
|
|
392
|
+
hover: 'text-3'
|
|
441
393
|
},
|
|
442
394
|
enableGradient: true
|
|
443
395
|
},
|
|
@@ -3,19 +3,10 @@
|
|
|
3
3
|
var core = require('@gem-sdk/core');
|
|
4
4
|
|
|
5
5
|
const getActiveClasses = (backgroundColor, text)=>{
|
|
6
|
-
const
|
|
7
|
-
desktop: '',
|
|
8
|
-
tablet: 'tablet:',
|
|
9
|
-
mobile: 'mobile:'
|
|
10
|
-
};
|
|
11
|
-
const generateClass = (type, device, value)=>value ? `${breakpoints[device]}[&_button]:data-[active=true]:!gp-${type}-[${value}]` : '';
|
|
6
|
+
const generateClass = (type, value)=>value ? `[&_button]:data-[active=true]:!gp-${type}-[${value}]` : '';
|
|
12
7
|
const classes = [
|
|
13
|
-
generateClass('bg',
|
|
14
|
-
generateClass('
|
|
15
|
-
generateClass('bg', 'mobile', backgroundColor?.mobile?.active),
|
|
16
|
-
generateClass('text', 'desktop', text?.desktop?.active),
|
|
17
|
-
generateClass('text', 'tablet', text?.tablet?.active),
|
|
18
|
-
generateClass('text', 'mobile', text?.mobile?.active)
|
|
8
|
+
generateClass('bg', backgroundColor?.active),
|
|
9
|
+
generateClass('text', text?.active)
|
|
19
10
|
].filter(Boolean).join(' ');
|
|
20
11
|
return core.composeClasses(core.cls('gp-coupon', classes));
|
|
21
12
|
};
|
|
@@ -14,21 +14,11 @@ const getButtonStyle = (style, styles)=>{
|
|
|
14
14
|
...core.makeStyleResponsive('ta', styles?.align)
|
|
15
15
|
};
|
|
16
16
|
};
|
|
17
|
-
const getResponsiveSetting = (setting)=>{
|
|
18
|
-
const desktop = setting.desktop;
|
|
19
|
-
const tablet = setting.tablet ? setting.tablet : desktop;
|
|
20
|
-
const mobile = setting.mobile ? setting.mobile : tablet;
|
|
21
|
-
return {
|
|
22
|
-
desktop,
|
|
23
|
-
tablet,
|
|
24
|
-
mobile
|
|
25
|
-
};
|
|
26
|
-
};
|
|
27
17
|
const getInnerBorderCornerCss = (data)=>{
|
|
28
18
|
const { uid, styles } = data;
|
|
29
|
-
const borderBtnV2 =
|
|
30
|
-
const roundedBtnV2 =
|
|
31
|
-
const boxShadowBtnV2 =
|
|
19
|
+
const borderBtnV2 = styles?.borderBtnV2;
|
|
20
|
+
const roundedBtnV2 = styles?.roundedBtnV2;
|
|
21
|
+
const boxShadowBtnV2 = styles?.boxShadowBtnV2;
|
|
32
22
|
const getShadowValue = (value)=>value ? core.getStyleShadow({
|
|
33
23
|
value,
|
|
34
24
|
state: 'active',
|
|
@@ -46,14 +36,14 @@ const getInnerBorderCornerCss = (data)=>{
|
|
|
46
36
|
return `
|
|
47
37
|
${mediaQuery}
|
|
48
38
|
.gp-coupon[data-active="true"] .${uid}::before {
|
|
49
|
-
${core.composeBorderCss(borderBtnV2?.
|
|
39
|
+
${core.composeBorderCss(borderBtnV2?.active, {
|
|
50
40
|
important: true
|
|
51
41
|
})};
|
|
52
|
-
${core.composeCornerCss(roundedBtnV2?.
|
|
53
|
-
box-shadow: ${getShadowValue(boxShadowBtnV2?.
|
|
42
|
+
${core.composeCornerCss(roundedBtnV2?.active, true)};
|
|
43
|
+
box-shadow: ${getShadowValue(boxShadowBtnV2?.active ?? {})} !important;
|
|
54
44
|
}
|
|
55
45
|
.gp-coupon[data-active="true"] .${uid} {
|
|
56
|
-
${core.composeCornerCss(roundedBtnV2?.
|
|
46
|
+
${core.composeCornerCss(roundedBtnV2?.active, true)};
|
|
57
47
|
}
|
|
58
48
|
${closeMediaQuery}
|
|
59
49
|
`;
|
|
@@ -185,23 +185,15 @@ const CouponSettings = [
|
|
|
185
185
|
{
|
|
186
186
|
id: 'backgroundColorV2',
|
|
187
187
|
type: 'color-picker-v2',
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
hover: 'highlight',
|
|
193
|
-
active: '#2C934E'
|
|
194
|
-
}
|
|
195
|
-
}
|
|
188
|
+
default: {
|
|
189
|
+
normal: 'brand',
|
|
190
|
+
hover: 'highlight',
|
|
191
|
+
active: '#2C934E'
|
|
196
192
|
},
|
|
197
193
|
compoDefaultValue: {
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
hover: 'highlight',
|
|
202
|
-
active: '#2C934E'
|
|
203
|
-
}
|
|
204
|
-
}
|
|
194
|
+
normal: 'brand',
|
|
195
|
+
hover: 'highlight',
|
|
196
|
+
active: '#2C934E'
|
|
205
197
|
}
|
|
206
198
|
},
|
|
207
199
|
{
|
|
@@ -220,18 +212,10 @@ const CouponSettings = [
|
|
|
220
212
|
{
|
|
221
213
|
id: 'textColorHover',
|
|
222
214
|
type: 'color-picker-v2',
|
|
223
|
-
|
|
224
|
-
desktop: {
|
|
225
|
-
default: {}
|
|
226
|
-
}
|
|
227
|
-
},
|
|
215
|
+
default: {},
|
|
228
216
|
compoDefaultValue: {
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
hover: 'text-3',
|
|
232
|
-
active: 'text-3'
|
|
233
|
-
}
|
|
234
|
-
}
|
|
217
|
+
hover: 'text-3',
|
|
218
|
+
active: 'text-3'
|
|
235
219
|
}
|
|
236
220
|
},
|
|
237
221
|
{
|
|
@@ -428,100 +412,76 @@ const CouponSettings = [
|
|
|
428
412
|
{
|
|
429
413
|
id: 'borderBtnV2',
|
|
430
414
|
type: 'border-v2',
|
|
431
|
-
|
|
432
|
-
|
|
433
|
-
|
|
434
|
-
|
|
435
|
-
|
|
436
|
-
|
|
437
|
-
|
|
438
|
-
|
|
439
|
-
|
|
440
|
-
|
|
441
|
-
|
|
442
|
-
|
|
443
|
-
|
|
444
|
-
|
|
445
|
-
|
|
446
|
-
|
|
447
|
-
color: '#121212',
|
|
448
|
-
isCustom: true
|
|
449
|
-
}
|
|
450
|
-
}
|
|
415
|
+
default: {
|
|
416
|
+
normal: {
|
|
417
|
+
borderType: 'none',
|
|
418
|
+
border: 'none',
|
|
419
|
+
borderWidth: '1px',
|
|
420
|
+
width: '1px 1px 1px 1px',
|
|
421
|
+
color: '#121212',
|
|
422
|
+
isCustom: true
|
|
423
|
+
},
|
|
424
|
+
hover: {
|
|
425
|
+
borderType: 'none',
|
|
426
|
+
border: 'none',
|
|
427
|
+
borderWidth: '1px',
|
|
428
|
+
width: '1px 1px 1px 1px',
|
|
429
|
+
color: '#121212',
|
|
430
|
+
isCustom: true
|
|
451
431
|
}
|
|
452
432
|
},
|
|
453
433
|
compoDefaultValue: {
|
|
454
|
-
|
|
455
|
-
|
|
456
|
-
|
|
457
|
-
|
|
458
|
-
|
|
459
|
-
|
|
460
|
-
|
|
461
|
-
|
|
462
|
-
|
|
463
|
-
|
|
464
|
-
|
|
465
|
-
width: '1px',
|
|
466
|
-
borderWidth: '1px'
|
|
467
|
-
}
|
|
468
|
-
}
|
|
434
|
+
normal: {
|
|
435
|
+
border: 'solid',
|
|
436
|
+
color: '#121212',
|
|
437
|
+
width: '1px',
|
|
438
|
+
borderWidth: '1px'
|
|
439
|
+
},
|
|
440
|
+
hover: {
|
|
441
|
+
border: 'solid',
|
|
442
|
+
color: '#121212',
|
|
443
|
+
width: '1px',
|
|
444
|
+
borderWidth: '1px'
|
|
469
445
|
}
|
|
470
446
|
}
|
|
471
447
|
},
|
|
472
448
|
{
|
|
473
449
|
id: 'roundedBtnV2',
|
|
474
450
|
type: 'corner-v2',
|
|
475
|
-
|
|
476
|
-
|
|
477
|
-
|
|
478
|
-
|
|
479
|
-
|
|
480
|
-
|
|
481
|
-
|
|
482
|
-
btlr: '0px',
|
|
483
|
-
radiusType: 'none'
|
|
484
|
-
}
|
|
485
|
-
}
|
|
451
|
+
default: {
|
|
452
|
+
normal: {
|
|
453
|
+
btrr: '0px',
|
|
454
|
+
bblr: '0px',
|
|
455
|
+
bbrr: '0px',
|
|
456
|
+
btlr: '0px',
|
|
457
|
+
radiusType: 'none'
|
|
486
458
|
}
|
|
487
459
|
},
|
|
488
460
|
compoDefaultValue: {
|
|
489
|
-
|
|
490
|
-
|
|
491
|
-
|
|
492
|
-
|
|
493
|
-
|
|
494
|
-
|
|
495
|
-
btlr: '8px',
|
|
496
|
-
radiusType: 'rounded'
|
|
497
|
-
}
|
|
498
|
-
}
|
|
461
|
+
normal: {
|
|
462
|
+
btrr: '8px',
|
|
463
|
+
bblr: '8px',
|
|
464
|
+
bbrr: '8px',
|
|
465
|
+
btlr: '8px',
|
|
466
|
+
radiusType: 'rounded'
|
|
499
467
|
}
|
|
500
468
|
}
|
|
501
469
|
},
|
|
502
470
|
{
|
|
503
471
|
id: 'boxShadowBtnV2',
|
|
504
472
|
type: 'shadow-v2',
|
|
505
|
-
|
|
506
|
-
|
|
507
|
-
default: {
|
|
508
|
-
normal: {}
|
|
509
|
-
}
|
|
510
|
-
}
|
|
473
|
+
default: {
|
|
474
|
+
normal: {}
|
|
511
475
|
},
|
|
512
476
|
compoDefaultValue: {
|
|
513
|
-
|
|
514
|
-
|
|
515
|
-
|
|
516
|
-
|
|
517
|
-
|
|
518
|
-
|
|
519
|
-
|
|
520
|
-
|
|
521
|
-
angle: 45,
|
|
522
|
-
enable: true
|
|
523
|
-
}
|
|
524
|
-
}
|
|
477
|
+
normal: {
|
|
478
|
+
type: 'shadow-1',
|
|
479
|
+
distance: '4px',
|
|
480
|
+
blur: '4px',
|
|
481
|
+
spread: '0px',
|
|
482
|
+
color: 'rgba(18, 18, 18, 0.2)',
|
|
483
|
+
angle: 45,
|
|
484
|
+
enable: true
|
|
525
485
|
}
|
|
526
486
|
}
|
|
527
487
|
}
|