zz-shopify-components 0.28.0 → 0.28.1-beta.0
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/package.json
CHANGED
|
@@ -33,6 +33,16 @@
|
|
|
33
33
|
"label": "可折叠文字颜色",
|
|
34
34
|
"default": "#B2B2B2"
|
|
35
35
|
},
|
|
36
|
+
{
|
|
37
|
+
"type": "select",
|
|
38
|
+
"id": "pc_video_position",
|
|
39
|
+
"label": "PC端视频位置",
|
|
40
|
+
"options": [
|
|
41
|
+
{ "value": "left", "label": "Left" },
|
|
42
|
+
{ "value": "right", "label": "Right" },
|
|
43
|
+
],
|
|
44
|
+
"default": "left"
|
|
45
|
+
},
|
|
36
46
|
{
|
|
37
47
|
"type": "select",
|
|
38
48
|
"id": "mobile_style",
|
|
@@ -294,7 +304,7 @@
|
|
|
294
304
|
</div>
|
|
295
305
|
{% comment %} PC端布局 {% endcomment %}
|
|
296
306
|
<div class="max-lg:tw-hidden tw-w-[90vw] xl:tw-w-[1220px] tw-mx-auto">
|
|
297
|
-
<div class="collaspse-div
|
|
307
|
+
<div class="collaspse-div tw-w-full tw-flex tw-items-center tw-justify-between {% if section.settings.pc_video_position == 'right' %}tw-flex-row-reverse{% endif %}">
|
|
298
308
|
<div class="tw-w-[68%]">
|
|
299
309
|
{% assign swiper_blocks = section.blocks | where: 'type', 'collapsible_row' %}
|
|
300
310
|
{% for collapsible_row in swiper_blocks %}
|
|
@@ -305,7 +315,7 @@
|
|
|
305
315
|
pc_video: collapsible_row.settings.video_pc,
|
|
306
316
|
pc_poster: collapsible_row.settings.poster_pc,
|
|
307
317
|
lazy: true,
|
|
308
|
-
class: 'tw-w-full tw-h-
|
|
318
|
+
class: 'tw-w-full tw-h-full tw-rounded-[16px] ',
|
|
309
319
|
autoplay: true,
|
|
310
320
|
loop: true,
|
|
311
321
|
muted: true,
|
|
@@ -316,7 +326,7 @@
|
|
|
316
326
|
{% render 'zz-img',
|
|
317
327
|
pc_image: collapsible_row.settings.poster_pc,
|
|
318
328
|
image_alt: collapsible_row.settings.heading | escape,
|
|
319
|
-
class_name: 'ratio-image',
|
|
329
|
+
class_name: 'ratio-image tw-w-full tw-h-full',
|
|
320
330
|
%}
|
|
321
331
|
{% endif %}
|
|
322
332
|
{% endif %}
|
|
@@ -360,7 +370,7 @@
|
|
|
360
370
|
mb_video: collapsible_row.settings.video_mb,
|
|
361
371
|
mb_poster: collapsible_row.settings.poster_mb,
|
|
362
372
|
lazy: true,
|
|
363
|
-
class: 'image-video-box tw-w-full tw-h-
|
|
373
|
+
class: 'image-video-box tw-w-full tw-h-full ',
|
|
364
374
|
autoplay: true,
|
|
365
375
|
loop: true,
|
|
366
376
|
muted: true,
|
|
@@ -371,7 +381,7 @@
|
|
|
371
381
|
render 'zz-img',
|
|
372
382
|
mb_image: collapsible_row.settings.poster_mb,
|
|
373
383
|
image_alt: collapsible_row.settings.heading | escape,
|
|
374
|
-
class_name: 'image-video-box',
|
|
384
|
+
class_name: 'image-video-box tw-w-full tw-h-full',
|
|
375
385
|
%}
|
|
376
386
|
{% endif %}
|
|
377
387
|
</div>
|
|
@@ -498,6 +508,10 @@
|
|
|
498
508
|
padding-bottom: 40px;
|
|
499
509
|
{% endif %}
|
|
500
510
|
|
|
511
|
+
}
|
|
512
|
+
#shopify-section-{{section.id}} .media-box {
|
|
513
|
+
aspect-ratio: 335 / 252;
|
|
514
|
+
|
|
501
515
|
}
|
|
502
516
|
|
|
503
517
|
#shopify-section-{{section.id}} .swiper-button-next,
|
|
@@ -587,6 +601,10 @@
|
|
|
587
601
|
padding-top: {{ section.settings.pc_padding_top }}px;
|
|
588
602
|
padding-bottom: {{ section.settings.pc_padding_bottom }}px;
|
|
589
603
|
}
|
|
604
|
+
#shopify-section-{{section.id}} .collasps-video-box {
|
|
605
|
+
aspect-ratio: 16 / 9;
|
|
606
|
+
|
|
607
|
+
}
|
|
590
608
|
}
|
|
591
609
|
</style>
|
|
592
610
|
|
|
@@ -13,7 +13,18 @@
|
|
|
13
13
|
{% endif %}
|
|
14
14
|
{% endif %}
|
|
15
15
|
|
|
16
|
-
|
|
16
|
+
{% assign is_available = true %}
|
|
17
|
+
{% if product.selected_or_first_available_variant.available == false %}
|
|
18
|
+
{% assign is_available = false %}
|
|
19
|
+
{% endif %}
|
|
20
|
+
{% comment %} btn Text {% endcomment %}
|
|
21
|
+
{% if is_available %}
|
|
22
|
+
{% assign btn_text = btn %}
|
|
23
|
+
{% else %}
|
|
24
|
+
{% assign btn_text = btn_out_of_stock | default: 'OUT OF STOCK' %}
|
|
25
|
+
{% endif %}
|
|
26
|
+
|
|
27
|
+
<button {% unless is_available %}disabled{% endunless %} class='tw-flex tw-items-center tw-justify-center tw-text-white tw-border-none tw-h-full tw-px-6 tw-py-4 tw-bg-[#FC6C0F] tw-rounded-full tw-font-semibold tw-text-[16px] {{ button_class }}'>
|
|
17
28
|
<span
|
|
18
29
|
class='buy-loading tw-hidden tw-daisy-loading tw-daisy-loading-spinner '
|
|
19
30
|
></span>
|
|
@@ -21,7 +32,7 @@
|
|
|
21
32
|
{% if is_edu_product %}
|
|
22
33
|
{% if is_logged_in %}
|
|
23
34
|
{% if is_edu_verified %}
|
|
24
|
-
{{
|
|
35
|
+
{{ btn_text }}
|
|
25
36
|
{% else %}
|
|
26
37
|
{{ bar_btn_edu_not_verified }}
|
|
27
38
|
{% endif %}
|
|
@@ -29,7 +40,7 @@
|
|
|
29
40
|
{{ bar_btn_edu_not_logged_in }}
|
|
30
41
|
{% endif %}
|
|
31
42
|
{% else %}
|
|
32
|
-
{{
|
|
43
|
+
{{ btn_text }}
|
|
33
44
|
{% endif %}
|
|
34
45
|
</span>
|
|
35
46
|
</button>
|