@total_onion/onion-library 2.0.160 → 2.0.163

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.
@@ -1,287 +1,304 @@
1
1
  {
2
- "key": "group_66296c3716b4f",
3
- "title": "Block: Site Copyright Notice v3",
4
- "fields": [
5
- {
6
- "key": "field_6721ff9f2e67a",
7
- "label": "Settings",
8
- "name": "",
9
- "aria-label": "",
10
- "type": "tab",
11
- "instructions": "",
12
- "required": 0,
13
- "conditional_logic": 0,
14
- "wrapper": {
15
- "width": "",
16
- "class": "",
17
- "id": ""
18
- },
19
- "wpml_cf_preferences": 3,
20
- "placement": "top",
21
- "endpoint": 0,
22
- "no_preference": 0,
23
- "selected": 0
24
- },
25
- {
26
- "key": "field_66296c3740e28",
27
- "label": "Enable Site Copyright notice",
28
- "name": "enable_site_copyright_notice",
29
- "aria-label": "",
30
- "type": "true_false",
31
- "instructions": "",
32
- "required": 0,
33
- "conditional_logic": 0,
34
- "wrapper": {
35
- "width": "",
36
- "class": "",
37
- "id": ""
38
- },
39
- "wpml_cf_preferences": 3,
40
- "message": "",
41
- "default_value": 0,
42
- "ui_on_text": "",
43
- "ui_off_text": "",
44
- "ui": 1,
45
- "style": ""
46
- },
47
- {
48
- "key": "field_66296c8ff3719",
49
- "label": "Site Copyright font size desktop",
50
- "name": "site_copyright_font_size_desktop",
51
- "aria-label": "",
52
- "type": "range",
53
- "instructions": "",
54
- "required": 0,
55
- "conditional_logic": 0,
56
- "wrapper": {
57
- "width": "",
58
- "class": "",
59
- "id": ""
60
- },
61
- "wpml_cf_preferences": 3,
62
- "default_value": 20,
63
- "min": "",
64
- "max": "",
65
- "step": "",
66
- "prepend": "",
67
- "append": ""
68
- },
69
- {
70
- "key": "field_66296ca5f371a",
71
- "label": "Site Copyright font size portrait",
72
- "name": "site_copyright_font_size_portrait",
73
- "aria-label": "",
74
- "type": "range",
75
- "instructions": "",
76
- "required": 0,
77
- "conditional_logic": 0,
78
- "wrapper": {
79
- "width": "",
80
- "class": "",
81
- "id": ""
82
- },
83
- "wpml_cf_preferences": 3,
84
- "default_value": 20,
85
- "min": "",
86
- "max": "",
87
- "step": "",
88
- "prepend": "",
89
- "append": ""
90
- },
91
- {
92
- "key": "field_66296cabf371b",
93
- "label": "Site Copyright font size mobile",
94
- "name": "site_copyright_font_size_mobile",
95
- "aria-label": "",
96
- "type": "range",
97
- "instructions": "",
98
- "required": 0,
99
- "conditional_logic": 0,
100
- "wrapper": {
101
- "width": "",
102
- "class": "",
103
- "id": ""
104
- },
105
- "wpml_cf_preferences": 3,
106
- "default_value": 20,
107
- "min": "",
108
- "max": "",
109
- "step": "",
110
- "prepend": "",
111
- "append": ""
112
- },
113
- {
114
- "key": "field_6721ff0d58df4",
115
- "label": "Block Padding",
116
- "name": "",
117
- "aria-label": "",
118
- "type": "tab",
119
- "instructions": "",
120
- "required": 0,
121
- "conditional_logic": 0,
122
- "wrapper": {
123
- "width": "",
124
- "class": "",
125
- "id": ""
126
- },
127
- "wpml_cf_preferences": 3,
128
- "placement": "top",
129
- "endpoint": 0,
130
- "no_preference": 0,
131
- "selected": 0
132
- },
133
- {
134
- "key": "field_6721ff1e58df5",
135
- "label": "block padding fields",
136
- "name": "block_padding_fields",
137
- "aria-label": "",
138
- "type": "clone",
139
- "instructions": "",
140
- "required": 0,
141
- "conditional_logic": 0,
142
- "wrapper": {
143
- "width": "",
144
- "class": "",
145
- "id": ""
146
- },
147
- "wpml_cf_preferences": 3,
148
- "user_roles": [
149
- "all"
150
- ],
151
- "clone": [
152
- "group_638f4148bc10b"
153
- ],
154
- "display": "seamless",
155
- "layout": "block",
156
- "prefix_label": 0,
157
- "prefix_name": 0,
158
- "acfe_seamless_style": 0,
159
- "acfe_clone_modal": 0,
160
- "acfe_clone_modal_close": 0,
161
- "acfe_clone_modal_button": "",
162
- "acfe_clone_modal_size": "large"
163
- },
164
- {
165
- "key": "field_6721ffc454f27",
166
- "label": "Block settings",
167
- "name": "",
168
- "aria-label": "",
169
- "type": "tab",
170
- "instructions": "",
171
- "required": 0,
172
- "conditional_logic": 0,
173
- "wrapper": {
174
- "width": "",
175
- "class": "",
176
- "id": ""
177
- },
178
- "wpml_cf_preferences": 3,
179
- "placement": "top",
180
- "endpoint": 0,
181
- "no_preference": 0,
182
- "selected": 0
183
- },
184
- {
185
- "key": "field_672200439f45c",
186
- "label": "Block",
187
- "name": "",
188
- "aria-label": "",
189
- "type": "accordion",
190
- "instructions": "",
191
- "required": 0,
192
- "conditional_logic": 0,
193
- "wrapper": {
194
- "width": "",
195
- "class": "",
196
- "id": ""
197
- },
198
- "wpml_cf_preferences": 3,
199
- "user_roles": [
200
- "all"
201
- ],
202
- "open": 0,
203
- "multi_expand": 0,
204
- "endpoint": 0
205
- },
206
- {
207
- "key": "field_6721ffda54f28",
208
- "label": "block settings fields",
209
- "name": "block_settings_fields",
210
- "aria-label": "",
211
- "type": "clone",
212
- "instructions": "",
213
- "required": 0,
214
- "conditional_logic": 0,
215
- "wrapper": {
216
- "width": "",
217
- "class": "",
218
- "id": ""
219
- },
220
- "wpml_cf_preferences": 3,
221
- "user_roles": [
222
- "all"
223
- ],
224
- "clone": [
225
- "group_65a45ada4e128"
226
- ],
227
- "display": "seamless",
228
- "layout": "block",
229
- "prefix_label": 0,
230
- "prefix_name": 0,
231
- "acfe_seamless_style": 0,
232
- "acfe_clone_modal": 0,
233
- "acfe_clone_modal_close": 0,
234
- "acfe_clone_modal_button": "",
235
- "acfe_clone_modal_size": "large"
236
- },
237
- {
238
- "key": "field_6722004e9f45d",
239
- "label": "accordion end",
240
- "name": "",
241
- "aria-label": "",
242
- "type": "accordion",
243
- "instructions": "",
244
- "required": 0,
245
- "conditional_logic": 0,
246
- "wrapper": {
247
- "width": "",
248
- "class": "",
249
- "id": ""
250
- },
251
- "wpml_cf_preferences": 3,
252
- "user_roles": [
253
- "all"
254
- ],
255
- "open": 0,
256
- "multi_expand": 0,
257
- "endpoint": 1
258
- }
259
- ],
260
- "location": [
261
- [
262
- {
263
- "param": "block",
264
- "operator": "==",
265
- "value": "acf\/site-copyright-notice-v3"
266
- }
267
- ]
268
- ],
269
- "menu_order": 0,
270
- "position": "normal",
271
- "style": "default",
272
- "label_placement": "left",
273
- "instruction_placement": "label",
274
- "hide_on_screen": "",
275
- "active": true,
276
- "description": "",
277
- "show_in_rest": 0,
278
- "acfe_autosync": [
279
- "json"
280
- ],
281
- "acfml_field_group_mode": "localization",
282
- "acfe_form": 0,
283
- "acfe_display_title": "",
284
- "acfe_meta": "",
285
- "acfe_note": "",
286
- "modified": 1758878905
2
+ "key": "group_66296c3716b4f",
3
+ "title": "Block: Site Copyright Notice v3",
4
+ "fields": [
5
+ {
6
+ "key": "field_6721ff9f2e67a",
7
+ "label": "Settings",
8
+ "name": "",
9
+ "aria-label": "",
10
+ "type": "tab",
11
+ "instructions": "",
12
+ "required": 0,
13
+ "conditional_logic": 0,
14
+ "wrapper": {
15
+ "width": "",
16
+ "class": "",
17
+ "id": ""
18
+ },
19
+ "wpml_cf_preferences": 3,
20
+ "placement": "top",
21
+ "endpoint": 0,
22
+ "no_preference": 0,
23
+ "selected": 0
24
+ },
25
+ {
26
+ "key": "field_6932f4997ae04",
27
+ "label": "Site copyright notice colour",
28
+ "name": "site_copyright_notice_colour",
29
+ "aria-label": "",
30
+ "type": "select",
31
+ "instructions": "",
32
+ "required": 0,
33
+ "conditional_logic": 0,
34
+ "wrapper": {
35
+ "width": "",
36
+ "class": "",
37
+ "id": ""
38
+ },
39
+ "choices": {
40
+ "var(--theme-primary-text-colour)": "Primary",
41
+ "var(--theme-secondary-text-colour)": "Secondary"
42
+ },
43
+ "default_value": "var(--theme-primary-text-colour)",
44
+ "return_format": "value",
45
+ "multiple": 0,
46
+ "max": "",
47
+ "allow_custom": 0,
48
+ "placeholder": "",
49
+ "search_placeholder": "",
50
+ "prepend": "",
51
+ "append": "",
52
+ "allow_null": 0,
53
+ "allow_in_bindings": 0,
54
+ "ui": 0,
55
+ "ajax": 0,
56
+ "create_options": 0,
57
+ "save_options": 0,
58
+ "min": ""
59
+ },
60
+ {
61
+ "key": "field_66296c3740e28",
62
+ "label": "Enable Site Copyright notice",
63
+ "name": "enable_site_copyright_notice",
64
+ "aria-label": "",
65
+ "type": "true_false",
66
+ "instructions": "",
67
+ "required": 0,
68
+ "conditional_logic": 0,
69
+ "wrapper": {
70
+ "width": "",
71
+ "class": "",
72
+ "id": ""
73
+ },
74
+ "wpml_cf_preferences": 3,
75
+ "message": "",
76
+ "default_value": 0,
77
+ "ui_on_text": "",
78
+ "ui_off_text": "",
79
+ "ui": 1,
80
+ "style": ""
81
+ },
82
+ {
83
+ "key": "field_66296c8ff3719",
84
+ "label": "Site Copyright font size desktop",
85
+ "name": "site_copyright_font_size_desktop",
86
+ "aria-label": "",
87
+ "type": "range",
88
+ "instructions": "",
89
+ "required": 0,
90
+ "conditional_logic": 0,
91
+ "wrapper": {
92
+ "width": "",
93
+ "class": "",
94
+ "id": ""
95
+ },
96
+ "wpml_cf_preferences": 3,
97
+ "default_value": 20,
98
+ "min": "",
99
+ "max": "",
100
+ "step": "",
101
+ "prepend": "",
102
+ "append": ""
103
+ },
104
+ {
105
+ "key": "field_66296ca5f371a",
106
+ "label": "Site Copyright font size portrait",
107
+ "name": "site_copyright_font_size_portrait",
108
+ "aria-label": "",
109
+ "type": "range",
110
+ "instructions": "",
111
+ "required": 0,
112
+ "conditional_logic": 0,
113
+ "wrapper": {
114
+ "width": "",
115
+ "class": "",
116
+ "id": ""
117
+ },
118
+ "wpml_cf_preferences": 3,
119
+ "default_value": 20,
120
+ "min": "",
121
+ "max": "",
122
+ "step": "",
123
+ "prepend": "",
124
+ "append": ""
125
+ },
126
+ {
127
+ "key": "field_66296cabf371b",
128
+ "label": "Site Copyright font size mobile",
129
+ "name": "site_copyright_font_size_mobile",
130
+ "aria-label": "",
131
+ "type": "range",
132
+ "instructions": "",
133
+ "required": 0,
134
+ "conditional_logic": 0,
135
+ "wrapper": {
136
+ "width": "",
137
+ "class": "",
138
+ "id": ""
139
+ },
140
+ "wpml_cf_preferences": 3,
141
+ "default_value": 20,
142
+ "min": "",
143
+ "max": "",
144
+ "step": "",
145
+ "prepend": "",
146
+ "append": ""
147
+ },
148
+ {
149
+ "key": "field_6721ff0d58df4",
150
+ "label": "Block Padding",
151
+ "name": "",
152
+ "aria-label": "",
153
+ "type": "tab",
154
+ "instructions": "",
155
+ "required": 0,
156
+ "conditional_logic": 0,
157
+ "wrapper": {
158
+ "width": "",
159
+ "class": "",
160
+ "id": ""
161
+ },
162
+ "wpml_cf_preferences": 3,
163
+ "placement": "top",
164
+ "endpoint": 0,
165
+ "no_preference": 0,
166
+ "selected": 0
167
+ },
168
+ {
169
+ "key": "field_6721ff1e58df5",
170
+ "label": "block padding fields",
171
+ "name": "block_padding_fields",
172
+ "aria-label": "",
173
+ "type": "clone",
174
+ "instructions": "",
175
+ "required": 0,
176
+ "conditional_logic": 0,
177
+ "wrapper": {
178
+ "width": "",
179
+ "class": "",
180
+ "id": ""
181
+ },
182
+ "clone": ["group_689f66f3e26df"],
183
+ "display": "seamless",
184
+ "layout": "block",
185
+ "prefix_label": 0,
186
+ "prefix_name": 0,
187
+ "acfe_seamless_style": 0,
188
+ "acfe_clone_modal": 0,
189
+ "acfe_clone_modal_close": 0,
190
+ "acfe_clone_modal_button": "",
191
+ "acfe_clone_modal_size": "large"
192
+ },
193
+ {
194
+ "key": "field_6721ffc454f27",
195
+ "label": "Block settings",
196
+ "name": "",
197
+ "aria-label": "",
198
+ "type": "tab",
199
+ "instructions": "",
200
+ "required": 0,
201
+ "conditional_logic": 0,
202
+ "wrapper": {
203
+ "width": "",
204
+ "class": "",
205
+ "id": ""
206
+ },
207
+ "wpml_cf_preferences": 3,
208
+ "placement": "top",
209
+ "endpoint": 0,
210
+ "no_preference": 0,
211
+ "selected": 0
212
+ },
213
+ {
214
+ "key": "field_672200439f45c",
215
+ "label": "Block",
216
+ "name": "",
217
+ "aria-label": "",
218
+ "type": "accordion",
219
+ "instructions": "",
220
+ "required": 0,
221
+ "conditional_logic": 0,
222
+ "wrapper": {
223
+ "width": "",
224
+ "class": "",
225
+ "id": ""
226
+ },
227
+ "wpml_cf_preferences": 3,
228
+ "user_roles": ["all"],
229
+ "open": 0,
230
+ "multi_expand": 0,
231
+ "endpoint": 0
232
+ },
233
+ {
234
+ "key": "field_6721ffda54f28",
235
+ "label": "block settings fields",
236
+ "name": "block_settings_fields",
237
+ "aria-label": "",
238
+ "type": "clone",
239
+ "instructions": "",
240
+ "required": 0,
241
+ "conditional_logic": 0,
242
+ "wrapper": {
243
+ "width": "",
244
+ "class": "",
245
+ "id": ""
246
+ },
247
+ "clone": ["group_689f649af2ac4"],
248
+ "display": "seamless",
249
+ "layout": "block",
250
+ "prefix_label": 0,
251
+ "prefix_name": 0,
252
+ "acfe_seamless_style": 0,
253
+ "acfe_clone_modal": 0,
254
+ "acfe_clone_modal_close": 0,
255
+ "acfe_clone_modal_button": "",
256
+ "acfe_clone_modal_size": "large"
257
+ },
258
+ {
259
+ "key": "field_6722004e9f45d",
260
+ "label": "accordion end",
261
+ "name": "",
262
+ "aria-label": "",
263
+ "type": "accordion",
264
+ "instructions": "",
265
+ "required": 0,
266
+ "conditional_logic": 0,
267
+ "wrapper": {
268
+ "width": "",
269
+ "class": "",
270
+ "id": ""
271
+ },
272
+ "wpml_cf_preferences": 3,
273
+ "user_roles": ["all"],
274
+ "open": 0,
275
+ "multi_expand": 0,
276
+ "endpoint": 1
277
+ }
278
+ ],
279
+ "location": [
280
+ [
281
+ {
282
+ "param": "block",
283
+ "operator": "==",
284
+ "value": "all"
285
+ }
286
+ ]
287
+ ],
288
+ "menu_order": 0,
289
+ "position": "normal",
290
+ "style": "default",
291
+ "label_placement": "left",
292
+ "instruction_placement": "label",
293
+ "hide_on_screen": "",
294
+ "active": false,
295
+ "description": "",
296
+ "show_in_rest": 0,
297
+ "display_title": "",
298
+ "acfe_autosync": ["json"],
299
+ "acfe_form": 0,
300
+ "acfe_display_title": "",
301
+ "acfe_meta": "",
302
+ "acfe_note": "",
303
+ "modified": 1764947168
287
304
  }
@@ -1,2 +1,20 @@
1
+ @use '../fields-core-mixins-v3/core-mixins-v3';
2
+ @use '../fields-core-functions-v3/core-functions-v3';
3
+ @use '../../breakpoints';
4
+
1
5
  .site-copyright-notice-v3 {
6
+ color: var(--site-copyright-notice-colour);
7
+ font-size: core-functions-v3.fontSize(
8
+ var(--site-copyright-font-size-mobile, 14px)
9
+ );
10
+ @include core-mixins-v3.device(breakpoints.$tabPortrait) {
11
+ font-size: core-functions-v3.fontSize(
12
+ var(--site-copyright-font-size-portrait, 16px)
13
+ );
14
+ }
15
+ @include core-mixins-v3.device(breakpoints.$tabLandscape) {
16
+ font-size: core-functions-v3.fontSize(
17
+ var(--site-copyright-font-size-desktop, 18px)
18
+ );
19
+ }
2
20
  }
@@ -4,28 +4,27 @@
4
4
  {% set dataAttributeEntryPoint = include('entry-points/entry-point-data-attribute.twig', { fields: fields, block: block }, with_context = false) %}
5
5
  {% set styleEntryPoint = include('entry-points/entry-point-style-v3.twig', { fields: fields, block: block, is_preview }, with_context = false) %}
6
6
 
7
+ {% set siteCopyrightColour = '--site-copyright-notice-colour: ' ~ fields.site_copyright_notice_colour ~ ';' %}
7
8
  {% set siteCopyrightFontSizeDesktop = '--site-copyright-font-size-desktop: ' ~ fields.site_copyright_font_size_desktop ~ ';' %}
8
9
  {% set siteCopyrightFontSizePortrait = '--site-copyright-font-size-portrait: ' ~ fields.site_copyright_font_size_portrait ~ ';'%}
9
10
  {% set siteCopyrightFontSizeMobile = '--site-copyright-font-size-mobile: ' ~ fields.site_copyright_font_size_mobile ~ ';' %}
10
11
 
11
-
12
- {% set sectionStyles = styleEntryPoint ~ siteCopyrightFontSizeDesktop ~ siteCopyrightFontSizePortrait ~ siteCopyrightFontSizeMobile %}
13
-
12
+ {% set sectionStyles = styleEntryPoint ~ siteCopyrightColour ~ siteCopyrightFontSizeDesktop ~ siteCopyrightFontSizePortrait ~ siteCopyrightFontSizeMobile %}
14
13
 
15
14
  <style>
16
15
  .{{blockClassName}}.{{block.id}}{
17
16
  {{sectionStyles}}
18
17
  }
19
18
  </style>
20
- <section {{block.anchor ? "id=" ~ block.anchor : ''}} class="{{blockClassName}} {{block.className}} {{loop ? block.className ~ '-' ~ loop.index : ''}} {{classNameEntryPoint}} {{block.id}} lazy-fade" {{dataAttributeEntryPoint}} data-jsload="false" data-blockid="{{block.id}}" data-pattern-site-copyright-notice data-assetkey="{{blockClassName}}">
19
+ <section {{block.anchor ? "id=" ~ block.anchor : ''}} class="{{blockClassName}} {{fields.section_class}} {{classNameEntryPoint}} {{block.id}} lazy-fade" {{dataAttributeEntryPoint}} data-jsload="false" data-blockid="{{block.id}}" data-pattern-site-copyright-notice data-assetkey="{{blockClassName}}">
21
20
 
22
21
  {% if fields.enable_site_copyright_notice %}
23
22
  <div
24
23
  class="{{blockClassName}}__title">
25
24
  <!-- site-copyright-notice -->
26
- {{market_settings.site_copyright_notice|default('Pernod Ricard 2024')}}
25
+ {{options.site_copyright_notice|default('@Total Onion')}}
27
26
  <!-- end-site-copyright-notice -->
28
- </div>
27
+ </div>
29
28
  {% endif %}
30
29
  {{htmlEntryPoint}}
31
30
  </section>
@@ -0,0 +1,58 @@
1
+ {
2
+ "key": "group_63c83de4f0a99",
3
+ "title": "Component: Enable Global Content Max Width",
4
+ "fields": [
5
+ {
6
+ "key": "field_63c83de5d114d",
7
+ "label": "Enable global content max width",
8
+ "name": "enable_global_content_max_width",
9
+ "aria-label": "",
10
+ "type": "true_false",
11
+ "instructions": "",
12
+ "required": 0,
13
+ "conditional_logic": 0,
14
+ "wrapper": {
15
+ "width": "50",
16
+ "class": "",
17
+ "id": ""
18
+ },
19
+ "wpml_cf_preferences": 3,
20
+ "user_roles": [
21
+ "administrator"
22
+ ],
23
+ "message": "This will restrict the block width to the global content max width setting",
24
+ "default_value": 0,
25
+ "ui_on_text": "",
26
+ "ui_off_text": "",
27
+ "ui": 1,
28
+ "style": ""
29
+ }
30
+ ],
31
+ "location": [
32
+ [
33
+ {
34
+ "param": "block",
35
+ "operator": "!=",
36
+ "value": "all"
37
+ }
38
+ ]
39
+ ],
40
+ "menu_order": 0,
41
+ "position": "normal",
42
+ "style": "default",
43
+ "label_placement": "top",
44
+ "instruction_placement": "label",
45
+ "hide_on_screen": "",
46
+ "active": false,
47
+ "description": "Library version - Do not modify in this project as any changes will be overwritten by future updates.",
48
+ "show_in_rest": 0,
49
+ "display_title": "",
50
+ "acfe_autosync": [
51
+ "json"
52
+ ],
53
+ "acfe_form": 0,
54
+ "acfe_display_title": "",
55
+ "acfe_meta": "",
56
+ "acfe_note": "",
57
+ "modified": 1764943547
58
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@total_onion/onion-library",
3
- "version": "2.0.160",
3
+ "version": "2.0.163",
4
4
  "description": "Component library",
5
5
  "main": "index.js",
6
6
  "scripts": {