@total_onion/onion-library 1.0.237 → 1.0.239

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.
@@ -39,13 +39,14 @@
39
39
  "wpml_cf_preferences": 3,
40
40
  "choices": {
41
41
  "__grid": "Grid",
42
- "__flex": "Flex"
42
+ "__flex": "Flex",
43
+ "__subgrid": "Subgrid"
43
44
  },
44
45
  "default_value": "",
45
46
  "return_format": "value",
46
47
  "allow_null": 0,
47
48
  "other_choice": 0,
48
- "layout": "vertical",
49
+ "layout": "horizontal",
49
50
  "save_other_choice": 0
50
51
  },
51
52
  {
@@ -63,6 +64,13 @@
63
64
  "operator": "==",
64
65
  "value": "__grid"
65
66
  }
67
+ ],
68
+ [
69
+ {
70
+ "field": "field_68b30f66d6499",
71
+ "operator": "==",
72
+ "value": "__subgrid"
73
+ }
66
74
  ]
67
75
  ],
68
76
  "wrapper": {
@@ -2387,5 +2395,5 @@
2387
2395
  "acfe_display_title": "",
2388
2396
  "acfe_meta": "",
2389
2397
  "acfe_note": "",
2390
- "modified": 1756565391
2398
+ "modified": 1756572779
2391
2399
  }
@@ -1,13 +1,13 @@
1
- {% set gridLayoutElement = include('components/grid-layout-element.twig', { fields: field, block: block }, with_context = false) %}
1
+ {% set gridLayoutElement = include('components/grid-layout-element-v3.twig', { fields: field, block: block }, with_context = false) %}
2
2
  {% set textStyle = include('components/text-style.twig', {field, post}) %}
3
3
  {% set elementStyles = gridLayoutElement ~ textStyle %}
4
4
  <style>
5
- .{{blockClassName}}__bazaarvoice.{{block.id}} {
5
+ .{{blockClassName}}__bazaarvoice.{{block.id}}{
6
6
  {{elementStyles}}
7
7
  }
8
8
  </style>
9
9
  <div class="{{blockClassName}}__bazaarvoice {{blockClassName}}__info-item {{field.text_style.typography_style|ru}} {{block.id}}">
10
- {% if post.product_bazaarvoice is defined and post.product_bazaarvoice is not empty %}
11
- {{function( 'do_shortcode', '[bazaarvoice bazaarvoice_product_id=' ~ post.product_bazaarvoice ~ ' type="inline_rating"]' )|raw}}
12
- {% endif %}
10
+ {% if post.product_bazaarvoice is defined and post.product_bazaarvoice is not empty %}
11
+ {{function( 'do_shortcode', '[bazaarvoice bazaarvoice_product_id=' ~ post.product_bazaarvoice ~ ' type="inline_rating"]' )|raw}}
12
+ {% endif %}
13
13
  </div>
@@ -1,4 +1,4 @@
1
- {% set gridLayoutElement = include('components/grid-layout-element.twig', { fields: field, block: block }, with_context = false) %}
1
+ {% set gridLayoutElement = include('components/grid-layout-element-v3.twig', { fields: field, block: block }, with_context = false) %}
2
2
  {% set textStyle = include('components/text-style.twig', {field, post}) %}
3
3
  {% set elementStyles = gridLayoutElement ~ textStyle %}
4
4
  {% set display_options = field.display_settings.options|join(', ')|replace({'__': ""}) %}
@@ -6,7 +6,7 @@
6
6
  {% set display_options = 'stars' %}
7
7
  {% endif %}
8
8
  <style>
9
- .{{blockClassName}}__better-reviews.{{block.id}} {
9
+ .{{blockClassName}}__better-reviews.{{block.id}}{
10
10
  {{elementStyles}}
11
11
  }
12
12
  </style>
@@ -1,4 +1,4 @@
1
- {% set gridLayoutElement = include('components/grid-layout-element.twig', { fields: field, block: block }, with_context = false) %}
1
+ {% set gridLayoutElement = include('components/grid-layout-element-v3.twig', { fields: field, block: block }, with_context = false) %}
2
2
  {% set icon = field.enable_cta_icon %}
3
3
  {% set postColour = '--post-colour: ' ~ post.post_colour|ru ~ ';' %}
4
4
  {% set postTextColourStyle = '--post-text-colour-style: ' ~ post.post_text_colour_style|ru ~ ';' %}
@@ -13,7 +13,7 @@
13
13
  {% set buyNowOptionSelect = post.meta('buy_now_option_select') %}
14
14
  {% if buyNowOptionSelect|ru == 'none' %}
15
15
  <style>
16
- .{{blockClassName}}__product-buy-now.{{block.id}} {
16
+ .{{blockClassName}}__product-buy-now.{{block.id}}{
17
17
  {{widgetStyles}}
18
18
  }
19
19
  </style>
@@ -1,9 +1,9 @@
1
- {% set gridLayoutElement = include('components/grid-layout-element.twig', { fields: field, block: block }, with_context = false) %}
1
+ {% set gridLayoutElement = include('components/grid-layout-element-v3.twig', { fields: field, block: block }, with_context = false) %}
2
2
  {% set textStyle = include('components/text-style.twig', {field, post}) %}
3
3
  {% set elementStyles = gridLayoutElement ~ textStyle %}
4
4
  {% set drink_desc = post.meta('drink_description') %}
5
5
  <style>
6
- .{{blockClassName}}__drink-description.{{block.id}} {
6
+ .{{blockClassName}}__drink-description.{{block.id}}{
7
7
  {{elementStyles}}
8
8
  }
9
9
  </style>
@@ -1,4 +1,4 @@
1
- {% set gridLayoutElement = include('components/grid-layout-element.twig', { fields: field, block: block }, with_context = false) %}
1
+ {% set gridLayoutElement = include('components/grid-layout-element-v3.twig', { fields: field, block: block }, with_context = false) %}
2
2
  {% set imageSelect = field.image_select|ru %}
3
3
  {% set globalImageFitStyle = '--global-image-fit-style: ' ~ field.global_image_fit_style|ru ~ ';' %}
4
4
  {% set globalImageWidth = '--global-image-width: ' ~ field.global_image_width ~ '%;' %}
@@ -7,8 +7,8 @@
7
7
  {% set globalImagePosition = '--global-image-position: ' ~ field.global_image_position|ru ~ ';' %}
8
8
  {% set styleVars = globalImageWidth ~ globalImageMaxWidth ~ globalImageFitStyle ~ globalImageZindex ~ globalImagePosition %}
9
9
  <style>
10
- .{{blockClassName}}__global-image-container.{{block.id}} {
11
- {{elementStyles}};
10
+ .{{blockClassName}}__global-image-container.{{block.id}}{
11
+ {{gridLayoutElement}}
12
12
  {{styleVars}}
13
13
  }
14
14
  </style>
@@ -1,10 +1,10 @@
1
- {% set gridLayoutElement = include('components/grid-layout-element.twig', { fields: field, block: block }, with_context = false) %}
1
+ {% set gridLayoutElement = include('components/grid-layout-element-v3.twig', { fields: field, block: block }, with_context = false) %}
2
2
  {% set gradientVars = include('components/gradient-overlay.twig', {fields: field}, with_context="false") %}
3
- {% set elementStyles = gridLayoutElement %}
3
+
4
4
  <style>
5
- .{{blockClassName}}__gradient-overlay.{{block.id}} {
5
+ .{{blockClassName}}__gradient-overlay.{{block.id}}{
6
6
  {{elementStyles}}
7
- {{gradientVars}}
7
+ {{gridLayoutElement}}
8
8
  }
9
9
  </style>
10
10
  <div class="{{blockClassName}}__info-item {{blockClassName}}__gradient-overlay {{block.id}}"></div>
@@ -1,4 +1,4 @@
1
- {% set gridLayoutElement = include('components/grid-layout-element.twig', { fields: field, block: block }, with_context = false) %}
1
+ {% set gridLayoutElement = include('components/grid-layout-element-v3.twig', { fields: field, block: block }, with_context = false) %}
2
2
  {% set textEditorStyleVars = include('components/text-editor-settings-variables-v3.twig', { fields: field, block, blockClassName, is_preview }, with_context = false) %}
3
3
  {% set textEditorContainerClasses = include('components/text-editor-settings-container-classes-v3.twig', { fields: field, block, blockClassName, is_preview }, with_context = false) %}
4
4
  {% set textEditorElementClasses = include('components/text-editor-settings-element-classes-v3.twig', { fields: field, block, blockClassName, is_preview }, with_context = false) %}
@@ -7,6 +7,7 @@
7
7
  <style>
8
8
  .{{blockClassName}}__post-categories.{{block.id}}{
9
9
  {{textEditorStyleVars}}
10
+ {{gridLayoutElement}}
10
11
  }
11
12
  </style>
12
13
  <div class="{{blockClassName}}__content-container {{textEditorContainerClasses}} {{block.id}}">
@@ -6,9 +6,10 @@
6
6
  <style>
7
7
  .{{blockClassName}}__product-headline.{{block.id}}, .{{blockClassName}}__content-container.{{block.id}}{
8
8
  {{textEditorStyleVars}}
9
+ {{gridLayoutElement}}
9
10
  }
10
11
  </style>
11
12
 
12
13
  <div class="{{blockClassName}}__content-container {{textEditorContainerClasses}} {{blockClassName}}__info-item {{block.id}}">
13
14
  <{{elementType|default('p')}} data-pattern-post-info="headline" class="{{blockClassName}}__product-headline {{textEditorElementClasses}} {{block.id}}">{{field.headline_text}}</{{elementType|default('p')}}>
14
- </div>
15
+ </div>
@@ -1,4 +1,4 @@
1
- {% set gridLayoutElement = include('components/grid-layout-element.twig', { fields: field, block: block }, with_context = false) %}
1
+ {% set gridLayoutElement = include('components/grid-layout-element-v3.twig', { fields: field, block: block }, with_context = false) %}
2
2
  {% set textEditorStyleVars = include('components/text-editor-settings-variables-v3.twig', { fields: field, block, blockClassName, is_preview }, with_context = false) %}
3
3
  {% set textEditorContainerClasses = include('components/text-editor-settings-container-classes-v3.twig', { fields: field, block, blockClassName, is_preview }, with_context = false) %}
4
4
  {% set textEditorElementClasses = include('components/text-editor-settings-element-classes-v3.twig', { fields: field, block, blockClassName, is_preview }, with_context = false) %}
@@ -6,6 +6,7 @@
6
6
  <style>
7
7
  .{{blockClassName}}__post-info-description.{{block.id}}, .{{blockClassName}}__content-container.{{block.id}}{
8
8
  {{textEditorStyleVars}}
9
+ {{gridLayoutElement}}
9
10
  }
10
11
  </style>
11
12
  <div class="{{blockClassName}}__content-container {{textEditorContainerClasses}} {{block.id}} {{blockClassName}}__info-item">
@@ -1,4 +1,4 @@
1
- {% set gridLayoutElement = include('components/grid-layout-element.twig', { fields: field, block: block }, with_context = false) %}
1
+ {% set gridLayoutElement = include('components/grid-layout-element-v3.twig', { fields: field, block: block }, with_context = false) %}
2
2
  {% set textEditorStyleVars = include('components/text-editor-settings-variables-v3.twig', { fields: field, block, blockClassName, is_preview }, with_context = false) %}
3
3
  {% set textEditorContainerClasses = include('components/text-editor-settings-container-classes-v3.twig', { fields: field, block, blockClassName, is_preview }, with_context = false) %}
4
4
  {% set textEditorElementClasses = include('components/text-editor-settings-element-classes-v3.twig', { fields: field, block, blockClassName, is_preview }, with_context = false) %}
@@ -6,6 +6,7 @@
6
6
  <style>
7
7
  .{{blockClassName}}__post-info-subtitle.{{block.id}}{
8
8
  {{textEditorStyleVars}}
9
+ {{gridLayoutElement}}
9
10
  }
10
11
  </style>
11
12
  <div class="{{blockClassName}}__content-container {{textEditorContainerClasses}} {{block.id}} {{blockClassName}}__info-item">
@@ -1,9 +1,10 @@
1
- {% set gridLayoutElement = include('components/grid-layout-element.twig', { fields: field, block: block }, with_context = false) %}
1
+ {% set gridLayoutElement = include('components/grid-layout-element-v3.twig', { fields: field, block: block }, with_context = false) %}
2
2
  {% set textStyle = include('components/text-style.twig', {field, post}) %}
3
3
  {% set elementStyles = gridLayoutElement ~ textStyle %}
4
4
  <style>
5
- .{{blockClassName}}__post-publish-date.{{block.id}} {
5
+ .{{blockClassName}}__post-publish-date.{{block.id}}{
6
6
  {{elementStyles}}
7
+ {{gridLayoutElement}}
7
8
  }
8
9
  </style>
9
10
  <{{field.text_style.text_element_type|ru}} class="{{blockClassName}}__post-publish-date {{blockClassName}}__info-item {{field.text_style.typography_style|ru}} {{block.id}}">{{field.enable_label ? '<span class="post-publish-date-label">' ~ field.label ~ '</span>' : ''}}
@@ -1,13 +1,14 @@
1
- {% set gridLayoutElement = include('components/grid-layout-element.twig', { fields: field, block: block }, with_context = false) %}
1
+ {% set gridLayoutElement = include('components/grid-layout-element-v3.twig', { fields: field, block: block }, with_context = false) %}
2
2
  {% set textStyle = include('components/text-style.twig', {field, post}) %}
3
3
  {% set elementStyles = gridLayoutElement ~ textStyle %}
4
4
 
5
5
  {% if field.rb_grouping_id is defined and field.rb_grouping_id is not empty %}
6
- <style>
7
- .{{blockClassName}}__rb-add-to-cart.{{block.id}} {
8
- {{elementStyles}}
9
- }
10
- </style>
6
+ <style>
7
+ .{{blockClassName}}__rb-add-to-cart.{{block.id}}{
8
+ {{elementStyles}}
9
+ {{gridLayoutElement}}
10
+ }
11
+ </style>
11
12
  <div class="{{blockClassName}}__rb-add-to-cart rb-add-to-cart {{block.id}}">
12
13
  <h4>{{__('Enter your address to check online availability', 'Global Theme')}}</h4>
13
14
  <div class="rb-add-to-cart-wrapper">
@@ -1,4 +1,4 @@
1
- {% set gridLayoutElement = include('components/grid-layout-element.twig', { fields: field, block: block }, with_context = false) %}
1
+ {% set gridLayoutElement = include('components/grid-layout-element-v3.twig', { fields: field, block: block }, with_context = false) %}
2
2
  {% set icon = field.enable_cta_icon %}
3
3
  {% set postColour = '--post-colour: ' ~ post.post_colour|ru ~ ';' %}
4
4
  {% set postTextColourStyle = '--post-text-colour-style: ' ~ post.post_text_colour_style|ru ~ ';' %}
@@ -13,7 +13,7 @@
13
13
  {% set productType = field.product_type|ru %}
14
14
  {% if productType == 'standard' %}
15
15
  <style>
16
- .{{blockClassName}}__shopify-add-to-cart.{{block.id}} {
16
+ .{{blockClassName}}__shopify-add-to-cart.{{block.id}}{
17
17
  {{widgetStyles}}
18
18
  }
19
19
  </style>
@@ -22,7 +22,7 @@
22
22
  {% endif %}
23
23
  {% if productType == 'engraved' %}
24
24
  <style>
25
- .{{blockClassName}}__shopify-add-to-cart.{{block.id}} {
25
+ .{{blockClassName}}__shopify-add-to-cart.{{block.id}}{
26
26
  {{widgetStyles}}
27
27
  }
28
28
  </style>
@@ -4,9 +4,9 @@
4
4
  @use 'NodeModules/@total_onion/onion-library/components/component-grid-layout-container-v3/grid-layout-container-v3';
5
5
  @use 'NodeModules/@total_onion/onion-library/components/component-grid-layout-element-v3/grid-layout-element-v3';
6
6
  @use 'NodeModules/@total_onion/onion-library/components/component-element-positioning-v3/element-positioning-v3';
7
- @use 'Assets/scss/modules/library-modules/gradient-overlay/gradient-overlay';
8
- @use 'Assets/scss/modules/library-modules/social-media-share/social-media-share';
9
- @use 'Assets/scss/modules/library-modules/better-reviews/better-reviews';
7
+ @use 'NodeModules/@total_onion/onion-library/components/component-gradient-overlay-v3/gradient-overlay-v3';
8
+ @use 'NodeModules/@total_onion/onion-library/components/component-social-media-share-v3/social-media-share-v3';
9
+ @use 'NodeModules/@total_onion/onion-library/components/component-better-reviews-v3/better-reviews-v3';
10
10
  @use 'Assets/scss/blocks/post-info-v3/post-info-v3-extra';
11
11
  @use 'Assets/scss/theme/breakpoints';
12
12
 
@@ -16,8 +16,14 @@
16
16
  grid-template: 'main' / 1fr;
17
17
  @include content-container-settings-v3.contentContainerSettingsV3();
18
18
  @include grid-layout-container-v3.gridLayoutContainer();
19
- @include social-media-share.social-media-share();
20
- @include better-reviews.better-reviews();
19
+ @include social-media-share-v3.social-media-share();
20
+ @include better-reviews-v3.better-reviews();
21
+ &--subgrid {
22
+ grid-row: 1 / -1;
23
+ grid-column: 1 / -1;
24
+ grid-template-rows: subgrid;
25
+ background: red;
26
+ }
21
27
  &__post-cover-link {
22
28
  grid-area: unset;
23
29
  position: absolute;
@@ -42,6 +48,7 @@
42
48
  @include grid-layout-element-v3.gridLayoutElement();
43
49
  width: 100%;
44
50
  position: relative;
51
+ overflow: hidden;
45
52
  }
46
53
  &__post-video {
47
54
  aspect-ratio: var(
@@ -95,7 +102,7 @@
95
102
  }
96
103
  &__gradient-overlay {
97
104
  height: 100%;
98
- @include gradient-overlay.gradientOverlay();
105
+ @include gradient-overlay-v3.gradientOverlay();
99
106
  }
100
107
  &__post-tags {
101
108
  pointer-events: none;
@@ -14,6 +14,9 @@
14
14
  {% elseif layoutType == 'grid' %}
15
15
  {% set layoutStyles = include('components/grid-layout-container-v3.twig', { fields, block }, with_context = false) %}
16
16
  {% set layoutClass = 'grid-layout-container' %}
17
+ {% elseif layoutType == 'subgrid' %}
18
+ {% set layoutStyles = include('components/grid-layout-container-v3.twig', { fields, block }, with_context = false) %}
19
+ {% set layoutClass = 'grid-layout-container ' ~ blockClassName ~ '--subgrid ' %}
17
20
  {% endif %}
18
21
 
19
22
  {% set sectionStyles = styleEntryPoint ~ gridGapMults ~ layoutStyles %}
@@ -37,7 +40,8 @@
37
40
  }
38
41
  </style>
39
42
 
40
- <section {{block.anchor ? "id=" ~ block.anchor : ''}} class="{{blockClassName}} {{block.className}} {{loop ? block.className.index ~ '-' ~ loop.index : ''}} {{postType}}-type {{classNameEntryPoint}} {{block.className}} lazy-fade {{block.id}}" {{dataAttributeEntryPoint}} data-assetkey="post-info-v3" data-post-info-type={{fields.post_info_type}}>
43
+ <section {{block.anchor ? "id=" ~ block.anchor : ''}} class="{{blockClassName}} {{layoutClass}} {{block.className}} {{loop ? block.className.index ~ '-' ~ loop.index : ''}} {{classNameEntryPoint}} {{block.className}} lazy-fade {{block.id}}" {{dataAttributeEntryPoint}} data-assetkey="post-info-v3" data-post-info-type={{fields.post_info_type}}>
44
+
41
45
 
42
46
  {% for field in postTypeFields %}
43
47
  {% if block %}
@@ -124,7 +124,7 @@
124
124
  margin-inline: auto;
125
125
  background-image: var(--main-container-background-image);
126
126
  background-repeat: repeat;
127
- container-type: size;
127
+ // container-type: size;
128
128
  }
129
129
 
130
130
  header,
@@ -19,12 +19,9 @@ fs.writeFileSync(
19
19
  );
20
20
 
21
21
  const dynamicEntryPoints = globSync(
22
- `${themePath}/assets/scss/blocks/*-v3.scss`
22
+ `${themePath}/node_modules/@total_onion/onion-library/components/block-*/*-v3.scss`
23
23
  ).map((path) => {
24
- const assetPath = path.replace(
25
- 'assets/scss/blocks/',
26
- 'Assets/scss/blocks/'
27
- );
24
+ const assetPath = path.replace('node_modules', 'NodeModules');
28
25
  return assetPath;
29
26
  });
30
27
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@total_onion/onion-library",
3
- "version": "1.0.237",
3
+ "version": "1.0.239",
4
4
  "description": "Component library",
5
5
  "main": "index.js",
6
6
  "scripts": {
@@ -31,6 +31,7 @@
31
31
  "@total_onion/onion-videocontroller": "^1.0.2",
32
32
  "dotenv": "^16.0.3",
33
33
  "esbuild": "0.25.5",
34
+ "flatpickr": "^4.6.13",
34
35
  "swiper": "^11.2.10"
35
36
  }
36
37
  }