neo.mjs 5.16.1 → 5.16.2
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/apps/ServiceWorker.mjs
CHANGED
@@ -75,12 +75,6 @@ class MainContainer extends ConfigurationViewport {
|
|
75
75
|
minValue : 50,
|
76
76
|
stepSize : 5,
|
77
77
|
value : me.exampleComponent.labelWidth
|
78
|
-
}, {
|
79
|
-
module : CheckBox,
|
80
|
-
checked : me.exampleComponent.readOnly,
|
81
|
-
labelText: 'readOnly',
|
82
|
-
listeners: {change: me.onConfigChange.bind(me, 'readOnly')},
|
83
|
-
style : {marginTop: '10px'}
|
84
78
|
}, {
|
85
79
|
module : CheckBox,
|
86
80
|
checked : me.exampleComponent.required,
|
@@ -114,6 +108,7 @@ class MainContainer extends ConfigurationViewport {
|
|
114
108
|
return Neo.create(SwitchField, {
|
115
109
|
labelText : 'Label',
|
116
110
|
labelWidth: 70,
|
111
|
+
name : 'mySwitch',
|
117
112
|
width : 200
|
118
113
|
})
|
119
114
|
}
|
package/package.json
CHANGED
@@ -23,7 +23,7 @@
|
|
23
23
|
100% {transform: translate(0) scaleX(1)}
|
24
24
|
}
|
25
25
|
|
26
|
-
input
|
26
|
+
.neo-switchfield-input {
|
27
27
|
background-clip : padding-box;
|
28
28
|
background-color: v(switchfield-background-color);
|
29
29
|
border-color : transparent;
|
@@ -85,21 +85,21 @@
|
|
85
85
|
transform-origin: left center;
|
86
86
|
}
|
87
87
|
}
|
88
|
-
}
|
89
88
|
|
90
|
-
|
91
|
-
|
92
|
-
|
89
|
+
&::before {
|
90
|
+
animation: switch-off-position 0.25s ease-out forwards;
|
91
|
+
}
|
93
92
|
|
94
|
-
|
95
|
-
|
96
|
-
|
93
|
+
&:checked::before {
|
94
|
+
animation: switch-on-position 0.25s ease-out forwards;
|
95
|
+
}
|
97
96
|
|
98
|
-
|
99
|
-
|
100
|
-
|
97
|
+
&::before {
|
98
|
+
animation: switch-off-transform 0.25s ease-out forwards;
|
99
|
+
}
|
101
100
|
|
102
|
-
|
103
|
-
|
101
|
+
&:checked::before {
|
102
|
+
animation: switch-on-transform 0.25s ease-out forwards;
|
103
|
+
}
|
104
104
|
}
|
105
105
|
}
|
package/src/DefaultConfig.mjs
CHANGED
@@ -245,12 +245,12 @@ const DefaultConfig = {
|
|
245
245
|
useVdomWorker: true,
|
246
246
|
/**
|
247
247
|
* buildScripts/injectPackageVersion.mjs will update this value
|
248
|
-
* @default '5.16.
|
248
|
+
* @default '5.16.2'
|
249
249
|
* @memberOf! module:Neo
|
250
250
|
* @name config.version
|
251
251
|
* @type String
|
252
252
|
*/
|
253
|
-
version: '5.16.
|
253
|
+
version: '5.16.2'
|
254
254
|
};
|
255
255
|
|
256
256
|
Object.assign(DefaultConfig, {
|
@@ -1,4 +1,5 @@
|
|
1
1
|
import CheckBox from './CheckBox.mjs';
|
2
|
+
import NeoArray from '../../util/Array.mjs';
|
2
3
|
|
3
4
|
/**
|
4
5
|
* @class Neo.form.field.Switch
|
@@ -17,19 +18,19 @@ class Switch extends CheckBox {
|
|
17
18
|
*/
|
18
19
|
ntype: 'switchfield',
|
19
20
|
/**
|
20
|
-
* @member {String[]} baseCls=['neo-switchfield']
|
21
|
+
* @member {String[]} baseCls=['neo-switchfield', 'neo-checkboxfield']
|
21
22
|
*/
|
22
|
-
baseCls: ['neo-switchfield'],
|
23
|
+
baseCls: ['neo-switchfield', 'neo-checkboxfield'],
|
23
24
|
/**
|
24
25
|
* @member {Object} _vdom
|
25
26
|
*/
|
26
27
|
_vdom:
|
27
28
|
{cn: [
|
28
29
|
{tag: 'label', cls: ['neo-checkbox-label'], cn: [
|
29
|
-
{tag: 'span',
|
30
|
-
{tag: 'input', cls: ['neo-
|
31
|
-
{tag: 'i',
|
32
|
-
{tag: 'span',
|
30
|
+
{tag: 'span', cls: []},
|
31
|
+
{tag: 'input', cls: ['neo-switchfield-input']},
|
32
|
+
{tag: 'i', cls: ['neo-switchfield-icon'], removeDom: true},
|
33
|
+
{tag: 'span', cls: ['neo-checkbox-value-label']}
|
33
34
|
]},
|
34
35
|
{cls: ['neo-error-wrapper'], removeDom: true, cn: [
|
35
36
|
{cls: ['neo-error']}
|