@total_onion/onion-library 2.0.119 → 2.0.120

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.
@@ -46,10 +46,10 @@
46
46
  height: 40px;
47
47
  border: 1px solid #faf8ec;
48
48
  overflow: hidden;
49
-
49
+
50
50
  .servings-dec-btn {
51
51
  cursor: pointer;
52
- background-color: #0054FF;
52
+ background-color: #0054ff;
53
53
  color: #faf8ec;
54
54
  font-size: 28px;
55
55
  padding-bottom: 4px;
@@ -57,11 +57,11 @@
57
57
  height: 100%;
58
58
  border: unset;
59
59
  transform: translateX(0);
60
- transition: transform .3s ease;
60
+ transition: transform 0.3s ease;
61
61
 
62
62
  &::after {
63
63
  content: '\2212';
64
- color: #0054FF;
64
+ color: #0054ff;
65
65
  padding-top: 4px;
66
66
  width: 38px;
67
67
  height: 38px;
@@ -106,14 +106,14 @@
106
106
 
107
107
  .servings-inc-btn {
108
108
  cursor: pointer;
109
- color: #0054FF;
109
+ color: #0054ff;
110
110
  font-size: 30px;
111
111
  background-color: #faf8ec;
112
112
  width: 100%;
113
113
  height: 100%;
114
114
  border: unset;
115
115
  transform: translateX(-100%);
116
- transition: transform .3s ease;
116
+ transition: transform 0.3s ease;
117
117
 
118
118
  &::after {
119
119
  content: '+';
@@ -124,7 +124,7 @@
124
124
  position: absolute;
125
125
  top: 0;
126
126
  right: -38px;
127
- background-color: #0054FF;
127
+ background-color: #0054ff;
128
128
  }
129
129
  }
130
130
 
@@ -209,12 +209,12 @@
209
209
  gap: core-functions-v3.fluidSize(30);
210
210
  }
211
211
 
212
- // to be changed
213
- img {
214
- max-width: 50px;
212
+ .ingredient-image {
213
+ max-width: core-functions-v3.fluidSize(50);
214
+ aspect-ratio: 1;
215
215
 
216
216
  @include core-mixins-v3.device(breakpoints.$tabPortrait) {
217
- max-width: 100px;
217
+ max-width: core-functions-v3.fluidSize(100);
218
218
  }
219
219
  }
220
220
 
@@ -260,16 +260,16 @@
260
260
  gap: core-functions-v3.fluidSize(30);
261
261
  }
262
262
 
263
- // to be changed
264
- img {
265
- max-width: 50px;
263
+ .equipment-image {
264
+ max-width: core-functions-v3.fluidSize(50);
265
+ aspect-ratio: 1;
266
266
 
267
267
  @include core-mixins-v3.device(breakpoints.$tabPortrait) {
268
- max-width: 100px;
268
+ max-width: core-functions-v3.fluidSize(100);
269
269
  }
270
270
  }
271
271
 
272
- .equipments-text {
272
+ .equipment-text {
273
273
  font-family: var(--tertiary-font-family);
274
274
  font-size: core-functions-v3.fontSize(18);
275
275
  font-weight: 400;
@@ -288,7 +288,7 @@
288
288
  font-weight: 500;
289
289
  text-transform: uppercase;
290
290
  padding-block: core-functions-v3.fluidSize(10);
291
-
291
+
292
292
  @include core-mixins-v3.device(breakpoints.$tabPortrait) {
293
293
  padding-block: core-functions-v3.fluidSize(40);
294
294
  font-size: core-functions-v3.fontSize(160);
@@ -324,4 +324,4 @@
324
324
  }
325
325
  }
326
326
  }
327
- }
327
+ }
@@ -55,7 +55,9 @@
55
55
 
56
56
  {% for ingredient in ingredients %}
57
57
  <div class="ingredients-wrapper">
58
- <img src="{{ get_image(ingredient.ingredient_image) }}" width="20">
58
+ {% set ingredientSelect = ingredient.ingredients_list %}
59
+ {% set image = get_image(options.ingredient[ingredientSelect].ingredient_image) %}
60
+ <img class="ingredient-image" src="{{ image }}" width="{{ image.width }}" height="{{ image.height }}" alt="{{ image.alt }}">
59
61
  <p class="ingredient-text" data-ingredients data-amount="{{ ingredient.amount }}" data-unit="{{ ingredient.default_unit }}" data-name="{{ ingredient.name }}">{{ ingredient.amount }}{{ ingredient.default_unit }}
60
62
  {{ ingredient.name }}</p>
61
63
  </div>
@@ -68,8 +70,10 @@
68
70
 
69
71
  {% for equipment in equipments %}
70
72
  <div class="equipments-wrapper">
71
- <img src="{{ get_image(equipment.equipment_image) }}" width="20">
72
- <p class="equipments-text">{{ equipment.equipment_name }}</p>
73
+ {% set equipmentSelect = equipment.equipment_list %}
74
+ {% set image = get_image(options.equipments[equipmentSelect].equipment_image) %}
75
+ <img class="equipment-image" src="{{ image }}" width="{{ image.width }}" height="{{ image.height }}" alt="{{ image.alt }}">
76
+ <p class="equipment-text">{{ equipment.equipment_name }}</p>
73
77
  </div>
74
78
  {% endfor %}
75
79
  </div>
@@ -67,42 +67,12 @@
67
67
  "button_label": "Add Row",
68
68
  "rows_per_page": 20,
69
69
  "sub_fields": [
70
- {
71
- "key": "field_68ffebf28918f",
72
- "label": "Ingredient Image",
73
- "name": "ingredient_image",
74
- "aria-label": "",
75
- "type": "image",
76
- "instructions": "",
77
- "required": 0,
78
- "conditional_logic": 0,
79
- "wrapper": {
80
- "width": "",
81
- "class": "",
82
- "id": ""
83
- },
84
- "wpml_cf_preferences": 3,
85
- "uploader": "",
86
- "return_format": "id",
87
- "library": "all",
88
- "upload_folder": "",
89
- "acfe_thumbnail": 0,
90
- "min_width": "",
91
- "min_height": "",
92
- "min_size": "",
93
- "max_width": "",
94
- "max_height": "",
95
- "max_size": "",
96
- "mime_types": "",
97
- "preview_size": "medium",
98
- "parent_repeater": "field_68ffeb3d8918b"
99
- },
100
70
  {
101
71
  "key": "field_6900f15dbea6c",
102
72
  "label": "Ingredients List",
103
73
  "name": "ingredients_list",
104
74
  "aria-label": "",
105
- "type": "acfe_field_types",
75
+ "type": "select",
106
76
  "instructions": "",
107
77
  "required": 0,
108
78
  "conditional_logic": 0,
@@ -111,26 +81,28 @@
111
81
  "class": "",
112
82
  "id": ""
113
83
  },
114
- "wpml_cf_preferences": 2,
115
- "field_types": [
116
- "repeater"
84
+ "wpml_cf_preferences": 3,
85
+ "choices": [
86
+ "sour cream",
87
+ "coca cola",
88
+ "arrroow"
117
89
  ],
118
- "field_type": "select",
119
- "default_value": [],
120
- "return_format": "object",
121
- "allow_null": 0,
90
+ "default_value": "placeholder1",
91
+ "return_format": "value",
122
92
  "multiple": 0,
93
+ "max": "",
94
+ "placeholder": "",
95
+ "prepend": "",
96
+ "append": "",
97
+ "allow_null": 0,
98
+ "allow_in_bindings": 0,
123
99
  "ui": 0,
124
- "choices": [],
125
100
  "ajax": 0,
126
- "placeholder": "",
127
- "search_placeholder": "",
128
- "layout": "",
129
- "toggle": 0,
101
+ "create_options": 0,
102
+ "save_options": 0,
130
103
  "allow_custom": 0,
131
- "other_choice": 0,
104
+ "search_placeholder": "",
132
105
  "min": "",
133
- "max": "",
134
106
  "parent_repeater": "field_68ffeb3d8918b"
135
107
  },
136
108
  {
@@ -171,7 +143,7 @@
171
143
  "class": "",
172
144
  "id": ""
173
145
  },
174
- "wpml_cf_preferences": 0,
146
+ "wpml_cf_preferences": 3,
175
147
  "choices": {
176
148
  "parts": "Parts",
177
149
  "ml": "ML",
@@ -192,7 +164,9 @@
192
164
  "allow_custom": 0,
193
165
  "search_placeholder": "",
194
166
  "min": "",
195
- "parent_repeater": "field_68ffeb3d8918b"
167
+ "parent_repeater": "field_68ffeb3d8918b",
168
+ "create_options": 0,
169
+ "save_options": 0
196
170
  },
197
171
  {
198
172
  "key": "field_68ffebe08918e",
@@ -302,33 +276,40 @@
302
276
  "rows_per_page": 20,
303
277
  "sub_fields": [
304
278
  {
305
- "key": "field_68ffec4f89192",
306
- "label": "Equipment Image",
307
- "name": "equipment_image",
279
+ "key": "field_690a596627485",
280
+ "label": "Equipment List",
281
+ "name": "equipment_list",
308
282
  "aria-label": "",
309
- "type": "image",
283
+ "type": "select",
310
284
  "instructions": "",
311
285
  "required": 0,
312
286
  "conditional_logic": 0,
313
287
  "wrapper": {
314
- "width": "50",
288
+ "width": "",
315
289
  "class": "",
316
290
  "id": ""
317
291
  },
318
- "wpml_cf_preferences": 3,
319
- "uploader": "",
320
- "return_format": "id",
321
- "library": "all",
322
- "upload_folder": "",
323
- "acfe_thumbnail": 0,
324
- "min_width": "",
325
- "min_height": "",
326
- "min_size": "",
327
- "max_width": "",
328
- "max_height": "",
329
- "max_size": "",
330
- "mime_types": "",
331
- "preview_size": "medium",
292
+ "wpml_cf_preferences": 0,
293
+ "choices": {
294
+ "placeholder1": "Placeholder 1",
295
+ "placeholder2": "Placeholder 2"
296
+ },
297
+ "default_value": "placeholder1",
298
+ "return_format": "value",
299
+ "multiple": 0,
300
+ "max": "",
301
+ "prepend": "",
302
+ "append": "",
303
+ "allow_null": 0,
304
+ "allow_in_bindings": 0,
305
+ "ui": 0,
306
+ "ajax": 0,
307
+ "placeholder": "",
308
+ "create_options": 0,
309
+ "save_options": 0,
310
+ "allow_custom": 0,
311
+ "search_placeholder": "",
312
+ "min": "",
332
313
  "parent_repeater": "field_68ffec3389191"
333
314
  },
334
315
  {
@@ -463,6 +444,7 @@
463
444
  "active": true,
464
445
  "description": "Library version - Do not modify in this project as any changes will be overwritten by future updates.",
465
446
  "show_in_rest": 0,
447
+ "display_title": "",
466
448
  "acfe_autosync": [
467
449
  "json"
468
450
  ],
@@ -471,5 +453,5 @@
471
453
  "acfe_display_title": "",
472
454
  "acfe_meta": "",
473
455
  "acfe_note": "",
474
- "modified": 1761835240
456
+ "modified": 1762286000
475
457
  }
@@ -16,14 +16,14 @@
16
16
  "class": "",
17
17
  "id": ""
18
18
  },
19
- "wpml_cf_preferences": 0,
19
+ "wpml_cf_preferences": 3,
20
20
  "acfe_repeater_stylised_button": 0,
21
21
  "layout": "table",
22
22
  "pagination": 0,
23
23
  "min": 0,
24
24
  "max": 0,
25
25
  "collapsed": "",
26
- "button_label": "Add Row",
26
+ "button_label": "Add Ingredient",
27
27
  "rows_per_page": 20,
28
28
  "sub_fields": [
29
29
  {
@@ -40,7 +40,7 @@
40
40
  "class": "",
41
41
  "id": ""
42
42
  },
43
- "wpml_cf_preferences": 0,
43
+ "wpml_cf_preferences": 3,
44
44
  "uploader": "",
45
45
  "return_format": "id",
46
46
  "library": "all",
@@ -53,6 +53,7 @@
53
53
  "max_height": "",
54
54
  "max_size": "",
55
55
  "mime_types": "",
56
+ "allow_in_bindings": 1,
56
57
  "preview_size": "medium",
57
58
  "parent_repeater": "field_6900f19ee7cdd"
58
59
  },
@@ -70,15 +71,127 @@
70
71
  "class": "",
71
72
  "id": ""
72
73
  },
73
- "wpml_cf_preferences": 0,
74
+ "wpml_cf_preferences": 2,
74
75
  "default_value": "",
75
76
  "maxlength": "",
77
+ "allow_in_bindings": 1,
76
78
  "placeholder": "",
77
79
  "prepend": "",
78
80
  "append": "",
79
81
  "parent_repeater": "field_6900f19ee7cdd"
80
82
  }
81
83
  ]
84
+ },
85
+ {
86
+ "key": "field_690a82f1a07ff",
87
+ "label": "Enable Equipments",
88
+ "name": "enable_equipments",
89
+ "aria-label": "",
90
+ "type": "true_false",
91
+ "instructions": "",
92
+ "required": 0,
93
+ "conditional_logic": 0,
94
+ "wrapper": {
95
+ "width": "",
96
+ "class": "",
97
+ "id": ""
98
+ },
99
+ "wpml_cf_preferences": 3,
100
+ "message": "",
101
+ "default_value": 0,
102
+ "allow_in_bindings": 0,
103
+ "ui_on_text": "",
104
+ "ui_off_text": "",
105
+ "ui": 1,
106
+ "style": ""
107
+ },
108
+ {
109
+ "key": "field_690a82ffa0800",
110
+ "label": "Equipments",
111
+ "name": "equipments",
112
+ "aria-label": "",
113
+ "type": "repeater",
114
+ "instructions": "",
115
+ "required": 0,
116
+ "conditional_logic": [
117
+ [
118
+ {
119
+ "field": "field_690a82f1a07ff",
120
+ "operator": "==",
121
+ "value": "1"
122
+ }
123
+ ]
124
+ ],
125
+ "wrapper": {
126
+ "width": "",
127
+ "class": "",
128
+ "id": ""
129
+ },
130
+ "wpml_cf_preferences": 3,
131
+ "acfe_repeater_stylised_button": 0,
132
+ "layout": "table",
133
+ "pagination": 0,
134
+ "min": 0,
135
+ "max": 0,
136
+ "collapsed": "",
137
+ "button_label": "Add Equipment",
138
+ "rows_per_page": 20,
139
+ "sub_fields": [
140
+ {
141
+ "key": "field_690a82ffa0801",
142
+ "label": "Equipment Image",
143
+ "name": "equipment_image",
144
+ "aria-label": "",
145
+ "type": "image",
146
+ "instructions": "",
147
+ "required": 0,
148
+ "conditional_logic": 0,
149
+ "wrapper": {
150
+ "width": "",
151
+ "class": "",
152
+ "id": ""
153
+ },
154
+ "wpml_cf_preferences": 3,
155
+ "uploader": "",
156
+ "return_format": "id",
157
+ "library": "all",
158
+ "upload_folder": "",
159
+ "acfe_thumbnail": 0,
160
+ "min_width": "",
161
+ "min_height": "",
162
+ "min_size": "",
163
+ "max_width": "",
164
+ "max_height": "",
165
+ "max_size": "",
166
+ "mime_types": "",
167
+ "allow_in_bindings": 1,
168
+ "preview_size": "medium",
169
+ "parent_repeater": "field_690a82ffa0800"
170
+ },
171
+ {
172
+ "key": "field_690a82ffa0802",
173
+ "label": "Equipment Name",
174
+ "name": "equipment_name",
175
+ "aria-label": "",
176
+ "type": "text",
177
+ "instructions": "",
178
+ "required": 0,
179
+ "conditional_logic": 0,
180
+ "wrapper": {
181
+ "width": "",
182
+ "class": "",
183
+ "id": ""
184
+ },
185
+ "wpml_cf_preferences": 2,
186
+ "default_value": "",
187
+ "maxlength": "",
188
+ "allow_in_bindings": 1,
189
+ "placeholder": "",
190
+ "prepend": "",
191
+ "append": "",
192
+ "parent_repeater": "field_690a82ffa0800"
193
+ }
194
+ ]
82
195
  }
83
196
  ],
84
197
  "location": [
@@ -99,6 +212,7 @@
99
212
  "active": true,
100
213
  "description": "",
101
214
  "show_in_rest": 0,
215
+ "display_title": "",
102
216
  "acfe_autosync": [
103
217
  "json"
104
218
  ],
@@ -107,5 +221,5 @@
107
221
  "acfe_display_title": "",
108
222
  "acfe_meta": "",
109
223
  "acfe_note": "",
110
- "modified": 1761669641
224
+ "modified": 1762297559
111
225
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@total_onion/onion-library",
3
- "version": "2.0.119",
3
+ "version": "2.0.120",
4
4
  "description": "Component library",
5
5
  "main": "index.js",
6
6
  "scripts": {