@gem-sdk/components 2.0.0-dev.663 → 2.0.0-dev.665

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.
@@ -0,0 +1,413 @@
1
+ const SettingUIV2 = [
2
+ {
3
+ label: {
4
+ en: 'Logo'
5
+ },
6
+ controls: [
7
+ {
8
+ label: {
9
+ en: 'Image'
10
+ },
11
+ type: 'combo',
12
+ getValueFromSettingID: 'logo.src',
13
+ comboType: 'image',
14
+ isHideClear: true,
15
+ popoverLabel: {
16
+ en: 'Image'
17
+ },
18
+ controls: [
19
+ {
20
+ type: 'control',
21
+ label: {
22
+ en: 'Source'
23
+ },
24
+ layout: 'vertical',
25
+ options: {
26
+ labelVariant: 'primary'
27
+ },
28
+ setting: {
29
+ id: 'logo'
30
+ }
31
+ },
32
+ {
33
+ type: 'control',
34
+ label: {
35
+ en: 'Aspect Ratio'
36
+ },
37
+ setting: {
38
+ id: 'logoAspectRatio'
39
+ }
40
+ },
41
+ {
42
+ type: 'control',
43
+ conditionDisplay: 'logoAspectRatio == "custom"',
44
+ setting: {
45
+ id: 'customAspectRadio'
46
+ }
47
+ },
48
+ {
49
+ type: 'control',
50
+ label: {
51
+ en: 'Object Fit'
52
+ },
53
+ setting: {
54
+ id: 'layout'
55
+ }
56
+ }
57
+ ]
58
+ },
59
+ {
60
+ id: 'Width',
61
+ label: {
62
+ en: 'Width'
63
+ },
64
+ setting: {
65
+ id: 'logoWidth'
66
+ },
67
+ layout: 'horizontal'
68
+ }
69
+ ]
70
+ },
71
+ {
72
+ label: {
73
+ en: 'Menu management'
74
+ },
75
+ controls: [
76
+ {
77
+ id: 'menu',
78
+ label: {
79
+ en: 'Order'
80
+ },
81
+ setting: {
82
+ id: 'menu'
83
+ }
84
+ }
85
+ ]
86
+ },
87
+ {
88
+ label: {
89
+ en: 'Text style'
90
+ },
91
+ controls: [
92
+ {
93
+ label: {
94
+ en: 'Text style'
95
+ },
96
+ type: 'combo',
97
+ iconName: 'polaris-text-title',
98
+ getValueFromSettingID: 'typo.type',
99
+ isTypoValue: true,
100
+ isHideClear: true,
101
+ controls: [
102
+ {
103
+ setting: {
104
+ id: 'typo'
105
+ },
106
+ layout: 'vertical',
107
+ options: {
108
+ updateFields: [
109
+ {
110
+ field: 'attrs.color',
111
+ settingId: 'textColor',
112
+ state: 'normal'
113
+ }
114
+ ]
115
+ },
116
+ controlChangeTrigger: {
117
+ settings: [
118
+ {
119
+ action: {
120
+ controlId: 'textColor',
121
+ valueFromField: 'attrs.color',
122
+ groupType: 'style',
123
+ controlType: 'style',
124
+ removeDevice: true,
125
+ state: 'normal'
126
+ }
127
+ }
128
+ ],
129
+ options: {
130
+ noRecordHistory: true
131
+ }
132
+ }
133
+ }
134
+ ]
135
+ },
136
+ {
137
+ label: {
138
+ en: 'Icon'
139
+ },
140
+ setting: {
141
+ id: 'arrow'
142
+ }
143
+ },
144
+ {
145
+ label: {
146
+ en: 'Hover'
147
+ },
148
+ type: 'combo',
149
+ getValueFromSettingID: 'textColor.hover',
150
+ compoDefaultValue: 'text-2',
151
+ comboType: 'color',
152
+ popoverLabel: {
153
+ en: 'Hover'
154
+ },
155
+ controls: [
156
+ {
157
+ label: {
158
+ en: 'Text color'
159
+ },
160
+ setting: {
161
+ id: 'textColor',
162
+ state: 'hover'
163
+ }
164
+ }
165
+ ]
166
+ },
167
+ {
168
+ label: {
169
+ en: 'Dropdown'
170
+ },
171
+ type: 'combo',
172
+ iconName: 'polaris-status-active',
173
+ fixedValue: 'Styled',
174
+ isHideClear: true,
175
+ help: {
176
+ content: 'Dropdown menu appears when hovering on a menu item'
177
+ },
178
+ popoverLabel: {
179
+ en: 'Dropdown menu'
180
+ },
181
+ controls: [
182
+ {
183
+ label: {
184
+ en: 'Text color'
185
+ },
186
+ popoverLabel: {
187
+ en: 'Text color'
188
+ },
189
+ setting: {
190
+ id: 'menuTextColor',
191
+ state: 'normal'
192
+ }
193
+ },
194
+ {
195
+ label: {
196
+ en: 'Background'
197
+ },
198
+ popoverLabel: {
199
+ en: 'Background'
200
+ },
201
+ setting: {
202
+ id: 'menuBg'
203
+ }
204
+ },
205
+ {
206
+ label: {
207
+ en: 'Hover'
208
+ },
209
+ popoverLabel: {
210
+ en: 'Hover'
211
+ },
212
+ setting: {
213
+ id: 'menuTextColor',
214
+ state: 'hover'
215
+ }
216
+ }
217
+ ]
218
+ }
219
+ ]
220
+ },
221
+ {
222
+ label: {
223
+ en: 'Cart'
224
+ },
225
+ controls: [
226
+ {
227
+ label: {
228
+ en: 'Icon'
229
+ },
230
+ setting: {
231
+ id: 'cartIcon'
232
+ }
233
+ },
234
+ {
235
+ label: {
236
+ en: 'Icon Color'
237
+ },
238
+ setting: {
239
+ id: 'cartIconColor',
240
+ state: 'normal'
241
+ }
242
+ },
243
+ {
244
+ label: {
245
+ en: 'Hover'
246
+ },
247
+ type: 'combo',
248
+ iconName: 'polaris-plus',
249
+ getValueFromSettingID: 'cartIconColor.hover',
250
+ comboType: 'color',
251
+ compoDefaultValue: 'text-2',
252
+ popoverLabel: {
253
+ en: 'Hover'
254
+ },
255
+ controls: [
256
+ {
257
+ label: {
258
+ en: 'Icon color'
259
+ },
260
+ setting: {
261
+ id: 'cartIconColor',
262
+ state: 'hover'
263
+ }
264
+ }
265
+ ]
266
+ }
267
+ ]
268
+ },
269
+ {
270
+ label: {
271
+ en: 'Size'
272
+ },
273
+ controls: [
274
+ {
275
+ id: 'height',
276
+ label: {
277
+ en: 'Height'
278
+ },
279
+ setting: {
280
+ id: 'height'
281
+ },
282
+ controlConfig: {
283
+ id: 'height',
284
+ type: 'dropdown:input',
285
+ units: [
286
+ 'px'
287
+ ],
288
+ displayOptions: [
289
+ {
290
+ label: 'Fit content',
291
+ value: 'Auto',
292
+ showValue: true
293
+ }
294
+ ]
295
+ },
296
+ layout: 'horizontal'
297
+ }
298
+ ]
299
+ },
300
+ {
301
+ label: {
302
+ en: 'Background'
303
+ },
304
+ controls: [
305
+ {
306
+ id: 'headerBg',
307
+ label: {
308
+ en: 'Color'
309
+ },
310
+ setting: {
311
+ id: 'headerBg'
312
+ },
313
+ layout: 'horizontal'
314
+ }
315
+ ]
316
+ },
317
+ {
318
+ label: {
319
+ en: 'Shape'
320
+ },
321
+ controls: [
322
+ {
323
+ label: {
324
+ en: 'Border'
325
+ },
326
+ setting: {
327
+ id: 'border',
328
+ state: 'normal'
329
+ }
330
+ },
331
+ {
332
+ label: {
333
+ en: 'Corner'
334
+ },
335
+ setting: {
336
+ id: 'rounded',
337
+ state: 'normal'
338
+ }
339
+ },
340
+ {
341
+ label: {
342
+ en: 'Shadow'
343
+ },
344
+ setting: {
345
+ id: 'boxShadow',
346
+ state: 'normal'
347
+ },
348
+ options: {
349
+ updateFields: [
350
+ {
351
+ field: 'normal.enable',
352
+ settingId: 'hasBoxShadow',
353
+ state: 'normal'
354
+ }
355
+ ]
356
+ },
357
+ controlChangeTrigger: {
358
+ settings: [
359
+ {
360
+ condition: `boxShadow.normal.enable === true`,
361
+ source: [
362
+ 'boxShadow',
363
+ 'hasBoxShadow'
364
+ ],
365
+ action: {
366
+ controlId: 'hasBoxShadow',
367
+ groupType: 'advanced',
368
+ controlType: 'advanced',
369
+ state: 'normal',
370
+ newValue: true
371
+ }
372
+ },
373
+ {
374
+ condition: `boxShadow.normal.enable === false`,
375
+ source: [
376
+ 'boxShadow',
377
+ 'hasBoxShadow'
378
+ ],
379
+ action: {
380
+ controlId: 'hasBoxShadow',
381
+ groupType: 'advanced',
382
+ controlType: 'advanced',
383
+ state: 'normal',
384
+ newValue: false
385
+ }
386
+ }
387
+ ],
388
+ options: {
389
+ noRecordHistory: true
390
+ }
391
+ }
392
+ }
393
+ ]
394
+ },
395
+ {
396
+ label: {
397
+ en: 'Display condition'
398
+ },
399
+ controls: [
400
+ {
401
+ id: 'breakpoint',
402
+ label: {
403
+ en: 'Menu icon'
404
+ },
405
+ setting: {
406
+ id: 'breakpoint'
407
+ }
408
+ }
409
+ ]
410
+ }
411
+ ];
412
+
413
+ export { SettingUIV2 };
@@ -43,7 +43,7 @@ const ProductDescriptionSettings = [
43
43
  disableDecimal: true,
44
44
  devices: {
45
45
  desktop: {
46
- default: 12
46
+ default: 3
47
47
  }
48
48
  }
49
49
  },
@@ -63,18 +63,42 @@ const SettingUIV2 = [
63
63
  label: {
64
64
  en: 'Show more label'
65
65
  },
66
- setting: {
67
- id: 'viewMoreText'
68
- },
66
+ type: 'combo',
67
+ iconName: 'polaris-text-block',
68
+ getValueFromSettingID: 'viewMoreText',
69
+ isHideClear: true,
70
+ controls: [
71
+ {
72
+ label: {
73
+ en: 'Content'
74
+ },
75
+ setting: {
76
+ id: 'viewMoreText'
77
+ },
78
+ layout: 'vertical'
79
+ }
80
+ ],
69
81
  conditionDisplay: 'hasLineClamp == true'
70
82
  },
71
83
  {
72
84
  label: {
73
85
  en: 'Show less label'
74
86
  },
75
- setting: {
76
- id: 'viewLessText'
77
- },
87
+ type: 'combo',
88
+ iconName: 'polaris-text-block',
89
+ getValueFromSettingID: 'viewLessText',
90
+ isHideClear: true,
91
+ controls: [
92
+ {
93
+ label: {
94
+ en: 'Content'
95
+ },
96
+ setting: {
97
+ id: 'viewLessText'
98
+ },
99
+ layout: 'vertical'
100
+ }
101
+ ],
78
102
  conditionDisplay: 'hasLineClamp == true'
79
103
  },
80
104
  {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@gem-sdk/components",
3
- "version": "2.0.0-dev.663",
3
+ "version": "2.0.0-dev.665",
4
4
  "license": "MIT",
5
5
  "sideEffects": false,
6
6
  "main": "dist/cjs/index.js",