@sc-360-v2/storefront-cms-library 0.3.85 → 0.3.87

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/bundle.scss CHANGED
@@ -40,7 +40,7 @@ $resizeActive: '[data-cms-element-resizer="true"]';
40
40
  )
41
41
  );
42
42
 
43
- height: auto;
43
+ // height: auto;
44
44
 
45
45
  margin: var(
46
46
  --_ctm-mob-bun-lt-mn,
@@ -1356,7 +1356,7 @@ $resizeActive: '[data-cms-element-resizer="true"]';
1356
1356
  .bundle_detail_product_qty_select {
1357
1357
  display: flex;
1358
1358
  justify-content: space-between;
1359
- align-items: center;
1359
+ align-items: flex-start;
1360
1360
  width: 100%;
1361
1361
 
1362
1362
  .add_to_cart_qty_wrapper {
@@ -192,10 +192,6 @@ $resizeActive: '[data-cms-element-resizer="true"]';
192
192
  pointer-events: none;
193
193
  }
194
194
  }
195
- .disabled {
196
- opacity: 0.5;
197
- pointer-events: none;
198
- }
199
195
  }
200
196
  }
201
197
  }
@@ -0,0 +1,94 @@
1
+ @use "sass:map";
2
+ @use "sass:list";
3
+
4
+ // 1: Image,
5
+ // 2: Text
6
+
7
+ @mixin FlexEmbroideryPreviewStyles($type) {
8
+ @if ($type == 1) {
9
+ & > .emb__img__main__element {
10
+ display: var(--_d-flex);
11
+ grid-area: 1/1/2/2;
12
+ position: var(--_p-relative);
13
+ width: var(--_sf-embr-att-wdth, var(--_width-80));
14
+ height: var(--_sf-embr-att-hght, var(--_height-80));
15
+
16
+ & > .emb__img__wrapper {
17
+ display: var(--_d-flex);
18
+ width: 100%;
19
+
20
+ & > div {
21
+ &.emb__img__box {
22
+ display: var(--_d-flex);
23
+ width: 100%;
24
+ height: 100%;
25
+ border-radius: var(--_br-4);
26
+ background: var(--_primary-25);
27
+ display: var(--_d-flex);
28
+ align-items: center;
29
+ justify-content: center;
30
+
31
+ & > svg {
32
+ width: 65%;
33
+ height: 65%;
34
+ }
35
+ }
36
+ &.emb__img__data__box {
37
+ display: var(--_d-flex);
38
+ width: 100%;
39
+ height: 100%;
40
+
41
+ & > img {
42
+ width: 100%;
43
+ height: 100%;
44
+ object-fit: contain;
45
+ }
46
+ }
47
+ }
48
+ }
49
+ }
50
+ } @else if($type == 2) {
51
+ & > .emb__text__main__element {
52
+ display: var(--_d-flex);
53
+ grid-area: 1/1/2/2;
54
+ position: var(--_p-relative);
55
+ width: var(--_sf-embr-att-wdth, var(--_width-80));
56
+ height: var(--_sf-embr-att-hght, var(--_height-80));
57
+
58
+ & > .emb__text__wrapper {
59
+ display: var(--_d-flex);
60
+ width: 100%;
61
+
62
+ & > div {
63
+ &.emb__text__box {
64
+ display: var(--_d-flex);
65
+ width: 100%;
66
+ height: 100%;
67
+ border-radius: var(--_br-4);
68
+ background: var(--_primary-25);
69
+ display: var(--_d-flex);
70
+ align-items: center;
71
+ justify-content: center;
72
+
73
+ & > svg {
74
+ width: 65%;
75
+ height: 65%;
76
+ }
77
+ }
78
+
79
+ &.emb__text__data__box {
80
+ display: var(--_d-flex);
81
+ width: 100%;
82
+ height: 100%;
83
+
84
+ & > span {
85
+ word-break: break-all;
86
+ width: 100%;
87
+ text-align: center;
88
+ }
89
+ }
90
+ }
91
+ }
92
+ }
93
+ }
94
+ }
@@ -0,0 +1,417 @@
1
+ @use "sass:map";
2
+ @use "sass:list";
3
+ @use "./functions.scss" as *;
4
+ @use "./embroider-preview-element.scss" as *;
5
+
6
+ $tmpWrapper: ".emb__tmp__wrapper";
7
+ $paListParent: ".emb__tmp__pa__list";
8
+ $pacListParent: ".emb__tmp__pac__parent";
9
+ $positionHeader: ".emb__tmp__psn__header";
10
+ $grpDiv: ".grp__div";
11
+ $positionToggleDiv: ".psn__tgle__parent";
12
+ $tmpDsWrapper: ".emb__tmp1__ds__wrapper";
13
+ $previewMain: ".emb__preview__me";
14
+ $previewMainWrapper: ".emb__preview__me__wrapper";
15
+ $previewMainOuput: ".output__ele__v1";
16
+
17
+ @mixin EmbroideryTemplate1Styles() {
18
+ & > #{$tmpWrapper} {
19
+ & > #{$paListParent} {
20
+ display: var(--_d-flex);
21
+ flex-direction: column;
22
+ row-gap: 16px;
23
+ width: 100%;
24
+ & > #{$pacListParent} {
25
+ display: var(--_d-flex);
26
+ flex-direction: column;
27
+ row-gap: 16px;
28
+
29
+ // Header
30
+ & > #{$positionHeader} {
31
+ display: var(--_d-flex);
32
+ align-items: center;
33
+ justify-content: space-between;
34
+ gap: 8px;
35
+
36
+ & > span {
37
+ display: var(--_d-flex);
38
+ &.tt1 {
39
+ color: prepareMediaVariable(--_ctm-dn-te-cr, #101828);
40
+ font-size: prepareMediaVariable(--_ctm-dn-te-ft-se, 30px);
41
+ font-weight: prepareMediaVariable(--_ctm-dn-te-ft-wt, 500);
42
+ line-height: prepareMediaVariable(--_ctm-dn-te-le-ht, 125%);
43
+ font-style: prepareMediaVariable(--_ctm-dn-te-ft-se-ic, normal);
44
+ font-family: prepareMediaVariable(--_ctm-dn-te-ft-fy), sans-serif;
45
+ text-decoration: prepareMediaVariable(--_ctm-dn-te-ue);
46
+ letter-spacing: prepareMediaVariable(--_ctm-dn-te-lr-sg);
47
+ text-align: prepareMediaVariable(--_ctm-dn-te-tt-an);
48
+ }
49
+
50
+ &.icn1 {
51
+ --_sf-size: 24px;
52
+ width: var(--_sf-size);
53
+ height: var(--_sf-size);
54
+ align-items: center;
55
+ justify-content: center;
56
+ transition: transform 0.45s ease-in-out;
57
+ cursor: pointer;
58
+
59
+ &[data-is-open="true"] {
60
+ transform: rotate(180deg);
61
+ }
62
+
63
+ & > svg {
64
+ --_perc: 0.75;
65
+ width: calc(var(--_sf-size) * var(--_perc));
66
+ height: calc(var(--_sf-size) * var(--_perc));
67
+
68
+ path {
69
+ stroke: prepareMediaVariable(--_ctm-dn-te-cr, #667085);
70
+ }
71
+ }
72
+ }
73
+ }
74
+ }
75
+
76
+ // Preview
77
+
78
+ & > #{$previewMain} {
79
+ width: 100%;
80
+ display: var(--_d-flex);
81
+ align-items: flex-start;
82
+ justify-content: center;
83
+ --_perc-1: 20%;
84
+ background: color-mix(
85
+ in srgb,
86
+ #000 calc(100% - var(--_perc-1, 0%)),
87
+ transparent var(--_perc-1, 0%)
88
+ );
89
+ padding: 8px;
90
+ border-radius: 6px;
91
+
92
+ flex-direction: column;
93
+ row-gap: 6px;
94
+
95
+ & > .emb__preview__title {
96
+ color: color-mix(in srgb, #fff 70%, transparent 30%);
97
+ font-size: 14px;
98
+ }
99
+
100
+ & > #{$previewMainWrapper} {
101
+ display: var(--_d-flex);
102
+ // flex-direction: column;
103
+ max-width: min(500px, 100%);
104
+ align-items: center;
105
+ width: 100%;
106
+ justify-content: center;
107
+ position: var(--_p-relative);
108
+ --_blk-perc: 5%;
109
+ background: color-mix(
110
+ in srgb,
111
+ var(--_base-white) calc(100% - #{var(--_blk-perc)}),
112
+ var(--_base-black) var(--_blk-perc)
113
+ );
114
+ border-radius: 6px;
115
+ min-height: var(--_sf-emb-prw-mn-ht-vl, 150px);
116
+
117
+ & > #{$previewMainOuput} {
118
+ display: var(--_d-grid);
119
+ width: 100%;
120
+ align-self: stretch;
121
+
122
+ // Image Element CSS
123
+ @include FlexEmbroideryPreviewStyles(1);
124
+
125
+ // Text Element CSS
126
+ @include FlexEmbroideryPreviewStyles(2);
127
+ }
128
+ }
129
+ }
130
+
131
+ // Position Toggle
132
+ #{$positionToggleDiv} {
133
+ display: var(--_d-grid);
134
+ width: 100%;
135
+ --_gap: 12px;
136
+ --_col: 2;
137
+ gap: var(--_gap);
138
+ // grid-template-columns: getRepeatColWidth(--_col, --_gap);
139
+ grid-template-columns: repeat(auto-fill, minmax(min(100%, 200px), 1fr));
140
+ align-items: center;
141
+
142
+ & > button {
143
+ min-height: 40px;
144
+ display: var(--_d-flex);
145
+ align-items: center;
146
+ justify-content: center;
147
+ padding: 8px 12px;
148
+ border-radius: 4px;
149
+ --_perc-clr-bb: 50%;
150
+ border: 0.5px solid
151
+ var(
152
+ --_sp-color,
153
+ color-mix(
154
+ in srgb,
155
+ #{prepareMediaVariable(--_ctm-dn-dt-tt-cr, #475467)}
156
+ calc(100% - var(--_perc-clr-bb)),
157
+ transparent var(--_perc-clr-bb)
158
+ )
159
+ );
160
+ background: color-mix(in srgb, var(--_sp-color, transparent) 6%, transparent 94%);
161
+ gap: 6px;
162
+
163
+ & > .icn__spn {
164
+ display: var(--_d-flex);
165
+ align-items: center;
166
+ justify-content: center;
167
+
168
+ svg {
169
+ width: 20px;
170
+ height: 20px;
171
+
172
+ path {
173
+ &:not(.acv *) {
174
+ stroke: color-mix(
175
+ in srgb,
176
+ var(
177
+ --_sp-color,
178
+ var(
179
+ --_ctm-mob-dn-dt-tt-cr,
180
+ var(--_ctm-tab-dn-dt-tt-cr, var(--_ctm-dn-dt-tt-cr, #475467))
181
+ )
182
+ )
183
+ 75%,
184
+ transparent 25%
185
+ );
186
+ }
187
+ }
188
+ }
189
+ }
190
+
191
+ & > .pac__name__div {
192
+ display: var(--_d-flex);
193
+ align-items: center;
194
+ gap: 8px;
195
+
196
+ & > .pac__name__span {
197
+ display: var(--_d-flex);
198
+ color: var(--_sp-color, #{prepareMediaVariable(--_ctm-dn-dt-tt-cr, #475467)});
199
+ font-size: prepareMediaVariable(--_ctm-dn-dt-tt-ft-se, 16px);
200
+ font-family: prepareMediaVariable(--_ctm-dn-dt-tt-ft-fy), sans-serif;
201
+ font-style: prepareMediaVariable(--_ctm-dn-dt-tt-ft-se-ic, normal);
202
+ font-weight: var(--_fw-wt, prepareMediaVariable(--_ctm-dn-dt-tt-ft-wt, 400));
203
+ line-height: prepareMediaVariable(--_ctm-dn-dt-tt-le-ht, 24px);
204
+ letter-spacing: prepareMediaVariable(--_ctm-dn-dt-tt-lr-sg);
205
+ text-transform: capitalize;
206
+
207
+ @include restrictToLinesShow(1);
208
+ }
209
+ }
210
+
211
+ &.acv {
212
+ --_sp-color: #{prepareMediaVariable(--_ctm-dn-ae-tt-cr, #243dc6)};
213
+ --_fw-wt: #{prepareMediaVariable(--_ctm-dn-ae-tt-ft-wt, 600)};
214
+
215
+ svg {
216
+ rect {
217
+ fill: var(
218
+ --_sp-color,
219
+ var(
220
+ --_ctm-mob-dn-dt-tt-cr,
221
+ var(--_ctm-tab-dn-dt-tt-cr, var(--_ctm-dn-dt-tt-cr, #475467))
222
+ )
223
+ );
224
+ }
225
+ }
226
+ }
227
+ }
228
+ }
229
+
230
+ // Data Settings Wrapper
231
+
232
+ & > #{$tmpDsWrapper} {
233
+ display: var(--_d-flex);
234
+ flex-direction: column;
235
+ row-gap: 16px;
236
+ }
237
+
238
+ #{$grpDiv} {
239
+ display: var(--_d-flex);
240
+ flex-direction: column;
241
+ row-gap: 6px;
242
+
243
+ & > label {
244
+ color: prepareMediaVariable(--_ctm-dn-dt-tt-cr, #475467);
245
+ font-family: prepareMediaVariable(--_ctm-dn-dt-tt-ft-fy), sans-serif;
246
+ font-style: prepareMediaVariable(--_ctm-dn-dt-tt-ft-se-ic, normal);
247
+ font-size: prepareMediaVariable(--_ctm-dn-dt-tt-ft-se, 16px);
248
+ font-weight: 600;
249
+ line-height: 24px;
250
+ }
251
+
252
+ // Text Editor
253
+ & > .text__div {
254
+ --_perc-clr-bb: 50%;
255
+ border-radius: 4px;
256
+ border: 0.5px solid
257
+ var(
258
+ --_fcs-clr,
259
+ color-mix(
260
+ in srgb,
261
+ #{prepareMediaVariable(--_ctm-dn-dt-tt-cr, #475467)}
262
+ calc(100% - var(--_perc-clr-bb)),
263
+ transparent var(--_perc-clr-bb)
264
+ )
265
+ );
266
+ background: #fff;
267
+ padding: 8px 12px;
268
+
269
+ &:has(:focus) {
270
+ --_fcs-clr: #{prepareMediaVariable(--_ctm-dn-ae-tt-cr, #243dc6)};
271
+ }
272
+
273
+ & > input {
274
+ color: prepareMediaVariable(--_ctm-dn-dt-tt-cr, #475467);
275
+ font-size: prepareMediaVariable(--_ctm-dn-dt-tt-ft-se, 16px);
276
+ font-family: prepareMediaVariable(--_ctm-dn-dt-tt-ft-fy), sans-serif;
277
+ font-style: prepareMediaVariable(--_ctm-dn-dt-tt-ft-se-ic, normal);
278
+ font-weight: var(--_fw-wt, prepareMediaVariable(--_ctm-dn-dt-tt-ft-wt, 400));
279
+ line-height: prepareMediaVariable(--_ctm-dn-dt-tt-le-ht, 24px);
280
+ letter-spacing: prepareMediaVariable(--_ctm-dn-dt-tt-lr-sg);
281
+ border: none;
282
+ height: auto;
283
+
284
+ &:focus {
285
+ outline: none;
286
+ }
287
+ }
288
+ }
289
+
290
+ // Common Dropdown
291
+
292
+ & > .cmn__drp__parent__v2 {
293
+ & > ul {
294
+ display: var(--_d-flex);
295
+ flex-wrap: wrap;
296
+ gap: 12px;
297
+
298
+ & > li {
299
+ display: var(--_d-flex);
300
+ align-content: center;
301
+ gap: 6px;
302
+ padding: 8px 12px;
303
+ border-radius: 4px;
304
+ --_perc-clr-bb: 50%;
305
+ border: 0.5px solid
306
+ var(
307
+ --_sp-color,
308
+ color-mix(
309
+ in srgb,
310
+ #{prepareMediaVariable(--_ctm-dn-dt-tt-cr, #475467)}
311
+ calc(100% - var(--_perc-clr-bb)),
312
+ transparent var(--_perc-clr-bb)
313
+ )
314
+ );
315
+ background: color-mix(in srgb, var(--_sp-color, transparent) 6%, transparent 94%);
316
+ cursor: pointer;
317
+
318
+ &:has(.list__img) {
319
+ --_size-w: 128px;
320
+ --_size-h: 48px;
321
+
322
+ width: var(--_size-w);
323
+ height: var(--_size-h);
324
+ position: var(--_p-relative);
325
+
326
+ & > .list__icon {
327
+ position: var(--_p-absolute);
328
+ left: 2px;
329
+ top: 2px;
330
+ visibility: var(--_sf-at-vt, hidden);
331
+ opacity: var(--_sf-at-op, 0);
332
+ }
333
+
334
+ &.active {
335
+ --_sf-at-vt: visible;
336
+ --_sf-at-op: 1;
337
+ }
338
+ }
339
+ &,
340
+ * {
341
+ user-select: none;
342
+ }
343
+
344
+ &.active {
345
+ --_sp-color: #{prepareMediaVariable(--_ctm-dn-ae-tt-cr, #243dc6)};
346
+ --_fw-wt: #{prepareMediaVariable(--_ctm-dn-ae-tt-ft-wt, 600)};
347
+ }
348
+
349
+ & > span {
350
+ display: var(--_d-flex);
351
+ &.list__text {
352
+ color: var(--_sp-color, #{prepareMediaVariable(--_ctm-dn-dt-tt-cr, #475467)});
353
+ font-size: prepareMediaVariable(--_ctm-dn-dt-tt-ft-se, 16px);
354
+ font-family: prepareMediaVariable(--_ctm-dn-dt-tt-ft-fy), sans-serif;
355
+ font-style: prepareMediaVariable(--_ctm-dn-dt-tt-ft-se-ic, normal);
356
+ font-weight: var(--_fw-wt, prepareMediaVariable(--_ctm-dn-dt-tt-ft-wt, 400));
357
+ line-height: prepareMediaVariable(--_ctm-dn-dt-tt-le-ht, 24px);
358
+ letter-spacing: prepareMediaVariable(--_ctm-dn-dt-tt-lr-sg);
359
+ text-transform: capitalize;
360
+ }
361
+
362
+ &.list__icon {
363
+ display: var(--_d-flex);
364
+ align-items: center;
365
+ justify-content: center;
366
+
367
+ svg {
368
+ width: 20px;
369
+ height: 20px;
370
+
371
+ path {
372
+ &:not(.active *) {
373
+ stroke: color-mix(
374
+ in srgb,
375
+ var(
376
+ --_sp-color,
377
+ var(
378
+ --_ctm-mob-dn-dt-tt-cr,
379
+ var(--_ctm-tab-dn-dt-tt-cr, var(--_ctm-dn-dt-tt-cr, #475467))
380
+ )
381
+ )
382
+ 75%,
383
+ transparent 25%
384
+ );
385
+ }
386
+ }
387
+ &:is(.active *) {
388
+ rect {
389
+ fill: var(
390
+ --_sp-color,
391
+ var(
392
+ --_ctm-mob-dn-dt-tt-cr,
393
+ var(--_ctm-tab-dn-dt-tt-cr, var(--_ctm-dn-dt-tt-cr, #475467))
394
+ )
395
+ );
396
+ }
397
+ }
398
+ }
399
+ }
400
+
401
+ &.list__img {
402
+ width: 100%;
403
+ img {
404
+ width: 100%;
405
+ height: 100%;
406
+ object-fit: contain;
407
+ }
408
+ }
409
+ }
410
+ }
411
+ }
412
+ }
413
+ }
414
+ }
415
+ }
416
+ }
417
+ }