@gem-sdk/components 2.0.0-dev.373 → 2.0.0-dev.375
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/cjs/builder.js +0 -1
- package/dist/cjs/form/components/contact/Contact.liquid.js +9 -3
- package/dist/cjs/form/components/contact/common/composeStyles.js +2 -1
- package/dist/cjs/form/components/form-email/FormEmail.js +16 -22
- package/dist/cjs/form/components/newsletter/Newsletter.liquid.js +39 -34
- package/dist/cjs/form/components/newsletter/common/composeStyles.js +2 -2
- package/dist/cjs/form/setting/contact/Contact.js +6 -15
- package/dist/cjs/form/setting/contact/ContactInitConfig.js +1 -1
- package/dist/cjs/form/setting/contact/configs/settings.js +206 -0
- package/dist/cjs/form/setting/contact/configs/uiV1.js +76 -0
- package/dist/cjs/form/setting/contact/configs/uiV2.js +241 -0
- package/dist/cjs/form/setting/newsletter/Newsletter.js +1 -1
- package/dist/cjs/form/setting/newsletter/NewsletterInitConfig.js +2 -4
- package/dist/cjs/form/setting/newsletter/configs/settings.js +13 -0
- package/dist/cjs/form/setting/newsletter/configs/uiV2.js +35 -13
- package/dist/cjs/form/setting/submit-button/configs/settings.js +17 -9
- package/dist/cjs/form/setting/submit-button/configs/uiV2.js +2 -2
- package/dist/cjs/sticky/components/common/styles.js +16 -5
- package/dist/esm/builder.js +0 -1
- package/dist/esm/form/components/contact/Contact.liquid.js +9 -3
- package/dist/esm/form/components/contact/common/composeStyles.js +3 -2
- package/dist/esm/form/components/form-email/FormEmail.js +17 -23
- package/dist/esm/form/components/newsletter/Newsletter.liquid.js +40 -35
- package/dist/esm/form/components/newsletter/common/composeStyles.js +2 -2
- package/dist/esm/form/setting/contact/Contact.js +6 -15
- package/dist/esm/form/setting/contact/ContactInitConfig.js +1 -1
- package/dist/esm/form/setting/contact/configs/settings.js +202 -0
- package/dist/esm/form/setting/contact/configs/uiV1.js +74 -0
- package/dist/esm/form/setting/contact/configs/uiV2.js +239 -0
- package/dist/esm/form/setting/newsletter/Newsletter.js +1 -1
- package/dist/esm/form/setting/newsletter/NewsletterInitConfig.js +2 -4
- package/dist/esm/form/setting/newsletter/configs/settings.js +13 -0
- package/dist/esm/form/setting/newsletter/configs/uiV2.js +35 -13
- package/dist/esm/form/setting/submit-button/configs/settings.js +17 -9
- package/dist/esm/form/setting/submit-button/configs/uiV2.js +2 -2
- package/dist/esm/sticky/components/common/styles.js +16 -5
- package/dist/types/index.d.ts +5 -2
- package/package.json +2 -2
|
@@ -0,0 +1,241 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
const SettingUIV2 = [
|
|
4
|
+
{
|
|
5
|
+
label: {
|
|
6
|
+
en: 'Message'
|
|
7
|
+
},
|
|
8
|
+
controls: [
|
|
9
|
+
{
|
|
10
|
+
type: 'combo',
|
|
11
|
+
label: {
|
|
12
|
+
en: 'Success'
|
|
13
|
+
},
|
|
14
|
+
iconName: 'polaris-text-block',
|
|
15
|
+
getValueFromSettingID: 'successMessage',
|
|
16
|
+
isHideClear: true,
|
|
17
|
+
disableScrollbar: true,
|
|
18
|
+
popoverLabel: {
|
|
19
|
+
en: 'Success message'
|
|
20
|
+
},
|
|
21
|
+
controls: [
|
|
22
|
+
{
|
|
23
|
+
layout: 'vertical',
|
|
24
|
+
label: {
|
|
25
|
+
en: 'Content'
|
|
26
|
+
},
|
|
27
|
+
setting: {
|
|
28
|
+
id: 'successMessage'
|
|
29
|
+
}
|
|
30
|
+
},
|
|
31
|
+
{
|
|
32
|
+
setting: {
|
|
33
|
+
id: 'successColor'
|
|
34
|
+
},
|
|
35
|
+
label: {
|
|
36
|
+
en: 'Color'
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
]
|
|
40
|
+
},
|
|
41
|
+
{
|
|
42
|
+
type: 'combo',
|
|
43
|
+
label: {
|
|
44
|
+
en: 'Error'
|
|
45
|
+
},
|
|
46
|
+
iconName: 'polaris-text-block',
|
|
47
|
+
getValueFromSettingID: 'errorMessage',
|
|
48
|
+
isHideClear: true,
|
|
49
|
+
disableScrollbar: true,
|
|
50
|
+
popoverLabel: {
|
|
51
|
+
en: 'Error message'
|
|
52
|
+
},
|
|
53
|
+
controls: [
|
|
54
|
+
{
|
|
55
|
+
layout: 'vertical',
|
|
56
|
+
label: {
|
|
57
|
+
en: 'Content'
|
|
58
|
+
},
|
|
59
|
+
setting: {
|
|
60
|
+
id: 'errorMessage'
|
|
61
|
+
}
|
|
62
|
+
},
|
|
63
|
+
{
|
|
64
|
+
setting: {
|
|
65
|
+
id: 'errorColor'
|
|
66
|
+
},
|
|
67
|
+
label: {
|
|
68
|
+
en: 'Color'
|
|
69
|
+
}
|
|
70
|
+
}
|
|
71
|
+
]
|
|
72
|
+
}
|
|
73
|
+
]
|
|
74
|
+
},
|
|
75
|
+
{
|
|
76
|
+
label: {
|
|
77
|
+
en: 'Size'
|
|
78
|
+
},
|
|
79
|
+
controls: [
|
|
80
|
+
{
|
|
81
|
+
id: 'Width',
|
|
82
|
+
label: {
|
|
83
|
+
en: 'Width'
|
|
84
|
+
},
|
|
85
|
+
controlConfig: {
|
|
86
|
+
id: 'width',
|
|
87
|
+
type: 'dropdown:input',
|
|
88
|
+
label: 'Width',
|
|
89
|
+
inputType: 'number',
|
|
90
|
+
units: [
|
|
91
|
+
'px',
|
|
92
|
+
'%'
|
|
93
|
+
],
|
|
94
|
+
hideUnit: false,
|
|
95
|
+
linkWithSetting: {
|
|
96
|
+
name: 'globalSize',
|
|
97
|
+
field: 'width'
|
|
98
|
+
},
|
|
99
|
+
displayOptions: [
|
|
100
|
+
{
|
|
101
|
+
label: 'Fit content',
|
|
102
|
+
value: 'Auto',
|
|
103
|
+
showValue: true
|
|
104
|
+
}
|
|
105
|
+
]
|
|
106
|
+
},
|
|
107
|
+
layout: 'horizontal'
|
|
108
|
+
},
|
|
109
|
+
{
|
|
110
|
+
label: {
|
|
111
|
+
en: 'Padding'
|
|
112
|
+
},
|
|
113
|
+
controlConfig: {
|
|
114
|
+
id: 'padding',
|
|
115
|
+
type: 'padding-v2',
|
|
116
|
+
linkWithSetting: {
|
|
117
|
+
name: 'globalSize',
|
|
118
|
+
field: 'padding'
|
|
119
|
+
},
|
|
120
|
+
compoDefaultValue: {
|
|
121
|
+
desktop: {
|
|
122
|
+
default: {
|
|
123
|
+
type: 'medium',
|
|
124
|
+
top: '12px',
|
|
125
|
+
bottom: '12px',
|
|
126
|
+
left: '24px',
|
|
127
|
+
right: '24px'
|
|
128
|
+
}
|
|
129
|
+
}
|
|
130
|
+
}
|
|
131
|
+
}
|
|
132
|
+
}
|
|
133
|
+
]
|
|
134
|
+
},
|
|
135
|
+
{
|
|
136
|
+
label: {
|
|
137
|
+
en: 'Background'
|
|
138
|
+
},
|
|
139
|
+
controls: [
|
|
140
|
+
{
|
|
141
|
+
setting: {
|
|
142
|
+
id: 'background'
|
|
143
|
+
},
|
|
144
|
+
layout: 'vertical'
|
|
145
|
+
}
|
|
146
|
+
]
|
|
147
|
+
},
|
|
148
|
+
{
|
|
149
|
+
label: {
|
|
150
|
+
en: 'Shape'
|
|
151
|
+
},
|
|
152
|
+
controls: [
|
|
153
|
+
{
|
|
154
|
+
label: {
|
|
155
|
+
en: 'Border'
|
|
156
|
+
},
|
|
157
|
+
setting: {
|
|
158
|
+
id: 'border',
|
|
159
|
+
state: 'normal'
|
|
160
|
+
}
|
|
161
|
+
},
|
|
162
|
+
{
|
|
163
|
+
label: {
|
|
164
|
+
en: 'Corner'
|
|
165
|
+
},
|
|
166
|
+
setting: {
|
|
167
|
+
id: 'rounded',
|
|
168
|
+
state: 'normal'
|
|
169
|
+
}
|
|
170
|
+
},
|
|
171
|
+
{
|
|
172
|
+
label: {
|
|
173
|
+
en: 'Shadow'
|
|
174
|
+
},
|
|
175
|
+
setting: {
|
|
176
|
+
id: 'boxShadow',
|
|
177
|
+
state: 'normal'
|
|
178
|
+
},
|
|
179
|
+
options: {
|
|
180
|
+
updateFields: [
|
|
181
|
+
{
|
|
182
|
+
field: 'enable',
|
|
183
|
+
settingId: 'hasBoxShadow',
|
|
184
|
+
state: 'normal'
|
|
185
|
+
}
|
|
186
|
+
]
|
|
187
|
+
},
|
|
188
|
+
controlChangeTrigger: {
|
|
189
|
+
settings: [
|
|
190
|
+
{
|
|
191
|
+
condition: `boxShadow.normal.enable === true`,
|
|
192
|
+
source: [
|
|
193
|
+
'boxShadow',
|
|
194
|
+
'hasBoxShadow'
|
|
195
|
+
],
|
|
196
|
+
action: {
|
|
197
|
+
controlId: 'hasBoxShadow',
|
|
198
|
+
groupType: 'advanced',
|
|
199
|
+
controlType: 'advanced',
|
|
200
|
+
state: 'normal',
|
|
201
|
+
newValue: true
|
|
202
|
+
}
|
|
203
|
+
},
|
|
204
|
+
{
|
|
205
|
+
condition: `boxShadow.normal.enable === false`,
|
|
206
|
+
source: [
|
|
207
|
+
'boxShadow',
|
|
208
|
+
'hasBoxShadow'
|
|
209
|
+
],
|
|
210
|
+
action: {
|
|
211
|
+
controlId: 'hasBoxShadow',
|
|
212
|
+
groupType: 'advanced',
|
|
213
|
+
controlType: 'advanced',
|
|
214
|
+
state: 'normal',
|
|
215
|
+
newValue: false
|
|
216
|
+
}
|
|
217
|
+
}
|
|
218
|
+
],
|
|
219
|
+
options: {
|
|
220
|
+
noRecordHistory: true
|
|
221
|
+
}
|
|
222
|
+
}
|
|
223
|
+
}
|
|
224
|
+
]
|
|
225
|
+
},
|
|
226
|
+
{
|
|
227
|
+
label: {
|
|
228
|
+
en: 'After submit'
|
|
229
|
+
},
|
|
230
|
+
controls: [
|
|
231
|
+
{
|
|
232
|
+
layout: 'vertical',
|
|
233
|
+
setting: {
|
|
234
|
+
id: 'callbackURL'
|
|
235
|
+
}
|
|
236
|
+
}
|
|
237
|
+
]
|
|
238
|
+
}
|
|
239
|
+
];
|
|
240
|
+
|
|
241
|
+
exports.SettingUIV2 = SettingUIV2;
|
|
@@ -51,7 +51,7 @@ const config = {
|
|
|
51
51
|
editor: {
|
|
52
52
|
en: {
|
|
53
53
|
err_msg_default: 'Can’t send email. Please try again later.',
|
|
54
|
-
success_msg_default: `Thanks for
|
|
54
|
+
success_msg_default: `Thanks for subscribing`
|
|
55
55
|
}
|
|
56
56
|
}
|
|
57
57
|
}
|
|
@@ -49,6 +49,12 @@ const NewsletterSettings = [
|
|
|
49
49
|
autoHeight: true,
|
|
50
50
|
minHeight: 58
|
|
51
51
|
},
|
|
52
|
+
{
|
|
53
|
+
id: 'successColor',
|
|
54
|
+
type: 'color-picker-v2',
|
|
55
|
+
label: 'Color',
|
|
56
|
+
default: '#00A042'
|
|
57
|
+
},
|
|
52
58
|
{
|
|
53
59
|
id: 'errorMessage',
|
|
54
60
|
type: 'textarea',
|
|
@@ -57,6 +63,12 @@ const NewsletterSettings = [
|
|
|
57
63
|
autoHeight: true,
|
|
58
64
|
minHeight: 58
|
|
59
65
|
},
|
|
66
|
+
{
|
|
67
|
+
id: 'errorColor',
|
|
68
|
+
type: 'color-picker-v2',
|
|
69
|
+
label: 'Color',
|
|
70
|
+
default: '#F44336'
|
|
71
|
+
},
|
|
60
72
|
{
|
|
61
73
|
id: 'translate',
|
|
62
74
|
type: 'input',
|
|
@@ -66,6 +78,7 @@ const NewsletterSettings = [
|
|
|
66
78
|
id: 'background',
|
|
67
79
|
type: 'background-media',
|
|
68
80
|
ignoreReRender: true,
|
|
81
|
+
hideImage: true,
|
|
69
82
|
devices: {
|
|
70
83
|
desktop: {
|
|
71
84
|
default: {
|
|
@@ -21,9 +21,20 @@ const SettingUIV2 = [
|
|
|
21
21
|
controls: [
|
|
22
22
|
{
|
|
23
23
|
layout: 'vertical',
|
|
24
|
+
label: {
|
|
25
|
+
en: 'Content'
|
|
26
|
+
},
|
|
24
27
|
setting: {
|
|
25
28
|
id: 'successMessage'
|
|
26
29
|
}
|
|
30
|
+
},
|
|
31
|
+
{
|
|
32
|
+
setting: {
|
|
33
|
+
id: 'successColor'
|
|
34
|
+
},
|
|
35
|
+
label: {
|
|
36
|
+
en: 'Color'
|
|
37
|
+
}
|
|
27
38
|
}
|
|
28
39
|
]
|
|
29
40
|
},
|
|
@@ -42,27 +53,25 @@ const SettingUIV2 = [
|
|
|
42
53
|
controls: [
|
|
43
54
|
{
|
|
44
55
|
layout: 'vertical',
|
|
56
|
+
label: {
|
|
57
|
+
en: 'Content'
|
|
58
|
+
},
|
|
45
59
|
setting: {
|
|
46
60
|
id: 'errorMessage'
|
|
47
61
|
}
|
|
62
|
+
},
|
|
63
|
+
{
|
|
64
|
+
setting: {
|
|
65
|
+
id: 'errorColor'
|
|
66
|
+
},
|
|
67
|
+
label: {
|
|
68
|
+
en: 'Color'
|
|
69
|
+
}
|
|
48
70
|
}
|
|
49
71
|
]
|
|
50
72
|
}
|
|
51
73
|
]
|
|
52
74
|
},
|
|
53
|
-
{
|
|
54
|
-
label: {
|
|
55
|
-
en: 'After submit'
|
|
56
|
-
},
|
|
57
|
-
controls: [
|
|
58
|
-
{
|
|
59
|
-
layout: 'vertical',
|
|
60
|
-
setting: {
|
|
61
|
-
id: 'callbackURL'
|
|
62
|
-
}
|
|
63
|
-
}
|
|
64
|
-
]
|
|
65
|
-
},
|
|
66
75
|
{
|
|
67
76
|
label: {
|
|
68
77
|
en: 'Size'
|
|
@@ -145,6 +154,19 @@ const SettingUIV2 = [
|
|
|
145
154
|
}
|
|
146
155
|
}
|
|
147
156
|
]
|
|
157
|
+
},
|
|
158
|
+
{
|
|
159
|
+
label: {
|
|
160
|
+
en: 'After submit'
|
|
161
|
+
},
|
|
162
|
+
controls: [
|
|
163
|
+
{
|
|
164
|
+
layout: 'vertical',
|
|
165
|
+
setting: {
|
|
166
|
+
id: 'callbackURL'
|
|
167
|
+
}
|
|
168
|
+
}
|
|
169
|
+
]
|
|
148
170
|
}
|
|
149
171
|
];
|
|
150
172
|
|
|
@@ -127,17 +127,25 @@ const SubmitButtonSettings = [
|
|
|
127
127
|
}
|
|
128
128
|
},
|
|
129
129
|
{
|
|
130
|
-
id: '
|
|
130
|
+
id: 'backgroundColorV2',
|
|
131
131
|
type: 'color-picker-v2',
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
132
|
+
devices: {
|
|
133
|
+
desktop: {
|
|
134
|
+
default: {
|
|
135
|
+
normal: 'brand',
|
|
136
|
+
hover: 'highlight'
|
|
137
|
+
}
|
|
138
|
+
}
|
|
136
139
|
},
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
140
|
+
compoDefaultValue: {
|
|
141
|
+
desktop: {
|
|
142
|
+
default: {
|
|
143
|
+
normal: 'brand',
|
|
144
|
+
hover: 'highlight'
|
|
145
|
+
}
|
|
146
|
+
}
|
|
147
|
+
},
|
|
148
|
+
enableGradient: true
|
|
141
149
|
},
|
|
142
150
|
{
|
|
143
151
|
id: 'textColor',
|
|
@@ -132,7 +132,7 @@ const SettingUIV2 = [
|
|
|
132
132
|
en: 'Color'
|
|
133
133
|
},
|
|
134
134
|
setting: {
|
|
135
|
-
id: '
|
|
135
|
+
id: 'backgroundColorV2',
|
|
136
136
|
state: 'normal'
|
|
137
137
|
}
|
|
138
138
|
}
|
|
@@ -266,7 +266,7 @@ const SettingUIV2 = [
|
|
|
266
266
|
en: 'Background'
|
|
267
267
|
},
|
|
268
268
|
setting: {
|
|
269
|
-
id: '
|
|
269
|
+
id: 'backgroundColorV2',
|
|
270
270
|
state: 'hover'
|
|
271
271
|
}
|
|
272
272
|
},
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
3
|
var core = require('@gem-sdk/core');
|
|
4
|
-
var helpers = require('../../../helpers.js');
|
|
5
4
|
require('react/jsx-runtime');
|
|
6
5
|
require('react');
|
|
7
6
|
var _const = require('../../../common/const.js');
|
|
@@ -19,11 +18,23 @@ const getCSSAlign = (position)=>{
|
|
|
19
18
|
...getCSSAlignByDevice(position?.mobile ?? position?.desktop, '-mobile')
|
|
20
19
|
};
|
|
21
20
|
};
|
|
21
|
+
const getDisplayStyle = (device, display, position)=>{
|
|
22
|
+
const style = {
|
|
23
|
+
[`--top${device}`]: 'auto',
|
|
24
|
+
[`--${position + device}`]: '0',
|
|
25
|
+
[`--pos${device}`]: getCSSPosition(position)
|
|
26
|
+
};
|
|
27
|
+
if (display === 'after-first-cart-button') style[`--d${device}`] = 'none';
|
|
28
|
+
return style;
|
|
29
|
+
};
|
|
30
|
+
const getCSSPosition = (position)=>{
|
|
31
|
+
return position == 'top' ? 'sticky' : 'fixed';
|
|
32
|
+
};
|
|
22
33
|
const displayStyle = (display, position)=>{
|
|
23
34
|
return {
|
|
24
|
-
...
|
|
25
|
-
...
|
|
26
|
-
...
|
|
35
|
+
...getDisplayStyle('', display?.desktop, position?.desktop),
|
|
36
|
+
...getDisplayStyle('-tablet', display?.tablet ?? display?.desktop, position?.tablet ?? position?.desktop),
|
|
37
|
+
...getDisplayStyle('-mobile', display?.mobile ?? display?.desktop, position?.mobile ?? position?.desktop)
|
|
27
38
|
};
|
|
28
39
|
};
|
|
29
40
|
const getContainerStyles = (args)=>{
|
|
@@ -33,7 +44,7 @@ const getContainerStyles = (args)=>{
|
|
|
33
44
|
...style,
|
|
34
45
|
...core.makeStyleResponsive('w', w),
|
|
35
46
|
...core.getStyleBackgroundByDevice(background),
|
|
36
|
-
...displayStyle(display),
|
|
47
|
+
...displayStyle(display, position),
|
|
37
48
|
...getCSSAlign(position),
|
|
38
49
|
'z-index': _const.ELEMENT_Z_INDEX.STICKY
|
|
39
50
|
};
|
package/dist/esm/builder.js
CHANGED
|
@@ -58,7 +58,6 @@ import TextField from './form/components/textfield/TextField.js';
|
|
|
58
58
|
import FormTextArea from './form/components/textarea/TextArea.js';
|
|
59
59
|
import FormCheckbox from './form/components/form-checkbox/FormCheckbox.js';
|
|
60
60
|
import TextInput from './form/components/textinput/TextInput.js';
|
|
61
|
-
import './form/setting/contact/Contact.js';
|
|
62
61
|
import Header from './header/components/Header.js';
|
|
63
62
|
import BasicHeader from './header/components/kind/basic/index.js';
|
|
64
63
|
import ModernHeader from './header/components/kind/modern/index.js';
|
|
@@ -1,17 +1,23 @@
|
|
|
1
1
|
import { template } from '@gem-sdk/core';
|
|
2
2
|
import Newsletter from '../newsletter/Newsletter.liquid.js';
|
|
3
|
+
import { composeContainerStyles } from './common/composeStyles.js';
|
|
4
|
+
import { createStyle } from '@gem-sdk/system';
|
|
3
5
|
|
|
4
|
-
const ContactForm = ({ builderProps, setting, children, style, advanced, pageContext })=>{
|
|
6
|
+
const ContactForm = ({ builderProps, setting, children, style, advanced, pageContext, styles })=>{
|
|
7
|
+
const containerStyle = createStyle(composeContainerStyles(setting, styles));
|
|
5
8
|
return template`
|
|
6
|
-
${
|
|
9
|
+
<div style="${containerStyle}">
|
|
10
|
+
${Newsletter({
|
|
7
11
|
builderProps: builderProps,
|
|
8
12
|
setting: setting,
|
|
9
13
|
style: style,
|
|
10
14
|
children: children,
|
|
11
15
|
formType: 'contact',
|
|
12
16
|
advanced,
|
|
13
|
-
pageContext
|
|
17
|
+
pageContext,
|
|
18
|
+
styles
|
|
14
19
|
})}
|
|
20
|
+
</div>
|
|
15
21
|
`;
|
|
16
22
|
};
|
|
17
23
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { filterTruthy } from '../../../helpers/common.js';
|
|
2
|
-
import { makeGlobalSize, getStyleBackgroundByDevice } from '@gem-sdk/core';
|
|
2
|
+
import { makeGlobalSize, getStyleBackgroundByDevice, getGradientBgrStyleByDevice } from '@gem-sdk/core';
|
|
3
3
|
|
|
4
4
|
const composeStyles = (styles)=>filterTruthy(styles);
|
|
5
5
|
const composeContainerStyles = (setting, styles)=>{
|
|
@@ -12,7 +12,8 @@ const composeContainerStyles = (setting, styles)=>{
|
|
|
12
12
|
'--w': '100%'
|
|
13
13
|
},
|
|
14
14
|
...composeGlobalSize.padding,
|
|
15
|
-
...getStyleBackgroundByDevice(background)
|
|
15
|
+
...getStyleBackgroundByDevice(background),
|
|
16
|
+
...getGradientBgrStyleByDevice(background)
|
|
16
17
|
});
|
|
17
18
|
};
|
|
18
19
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
'use client';
|
|
2
|
-
import {
|
|
2
|
+
import { jsx, jsxs } from 'react/jsx-runtime';
|
|
3
3
|
import { createStyle, createClass } from '@gem-sdk/system';
|
|
4
4
|
import { composeContainerStyles, composeInnerStyles } from './common/composeStyles.js';
|
|
5
5
|
import { composeContainerClasses, composeInnerClasses } from './common/composeClasses.js';
|
|
@@ -11,32 +11,26 @@ const FormEmail = ({ builderProps, builderAttrs, setting, advanced, children })=
|
|
|
11
11
|
const innerStyles = createStyle(composeInnerStyles(setting, advanced));
|
|
12
12
|
const containerClasses = createClass(composeContainerClasses(setting, advanced, builderProps));
|
|
13
13
|
const innerClasses = createClass(composeInnerClasses(setting));
|
|
14
|
-
return /*#__PURE__*/
|
|
14
|
+
return /*#__PURE__*/ jsx("div", {
|
|
15
15
|
...builderAttrs,
|
|
16
16
|
"data-id": builderProps?.uid,
|
|
17
17
|
className: containerClasses,
|
|
18
18
|
style: containerStyles,
|
|
19
|
-
children:
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
value: hideOnClient ? defaultEmail : ''
|
|
35
|
-
}),
|
|
36
|
-
children
|
|
37
|
-
]
|
|
38
|
-
})
|
|
39
|
-
]
|
|
19
|
+
children: /*#__PURE__*/ jsxs("div", {
|
|
20
|
+
children: [
|
|
21
|
+
/*#__PURE__*/ jsx("input", {
|
|
22
|
+
type: "email",
|
|
23
|
+
className: innerClasses,
|
|
24
|
+
style: innerStyles,
|
|
25
|
+
placeholder: placeholder,
|
|
26
|
+
name: name,
|
|
27
|
+
required: required,
|
|
28
|
+
autoComplete: "email",
|
|
29
|
+
value: hideOnClient ? defaultEmail : ''
|
|
30
|
+
}),
|
|
31
|
+
children
|
|
32
|
+
]
|
|
33
|
+
})
|
|
40
34
|
});
|
|
41
35
|
};
|
|
42
36
|
|