@vaadin/field-base 23.0.8 → 23.0.11
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/package.json +3 -3
- package/src/checked-mixin.d.ts +1 -1
- package/src/checked-mixin.js +3 -3
- package/src/delegate-focus-mixin.d.ts +1 -1
- package/src/delegate-focus-mixin.js +5 -5
- package/src/delegate-state-mixin.d.ts +1 -1
- package/src/delegate-state-mixin.js +3 -3
- package/src/error-controller.js +1 -1
- package/src/field-mixin.d.ts +1 -1
- package/src/field-mixin.js +4 -4
- package/src/helper-controller.js +4 -4
- package/src/input-constraints-mixin.d.ts +1 -1
- package/src/input-constraints-mixin.js +4 -4
- package/src/input-control-mixin.d.ts +1 -1
- package/src/input-control-mixin.js +12 -11
- package/src/input-controller.js +1 -1
- package/src/input-field-mixin.d.ts +1 -1
- package/src/input-field-mixin.js +5 -5
- package/src/input-mixin.js +5 -5
- package/src/label-controller.js +5 -5
- package/src/label-mixin.d.ts +1 -1
- package/src/label-mixin.js +3 -3
- package/src/pattern-mixin.d.ts +1 -1
- package/src/pattern-mixin.js +3 -3
- package/src/shadow-focus-mixin.d.ts +1 -1
- package/src/shadow-focus-mixin.js +2 -2
- package/src/slot-styles-mixin.d.ts +1 -1
- package/src/slot-styles-mixin.js +1 -1
- package/src/slot-target-controller.d.ts +1 -1
- package/src/slot-target-controller.js +1 -1
- package/src/text-area-controller.js +1 -1
- package/src/validate-mixin.js +4 -4
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vaadin/field-base",
|
|
3
|
-
"version": "23.0.
|
|
3
|
+
"version": "23.0.11",
|
|
4
4
|
"publishConfig": {
|
|
5
5
|
"access": "public"
|
|
6
6
|
},
|
|
@@ -32,7 +32,7 @@
|
|
|
32
32
|
"dependencies": {
|
|
33
33
|
"@open-wc/dedupe-mixin": "^1.3.0",
|
|
34
34
|
"@polymer/polymer": "^3.0.0",
|
|
35
|
-
"@vaadin/component-base": "^23.0.
|
|
35
|
+
"@vaadin/component-base": "^23.0.11",
|
|
36
36
|
"lit": "^2.0.0"
|
|
37
37
|
},
|
|
38
38
|
"devDependencies": {
|
|
@@ -40,5 +40,5 @@
|
|
|
40
40
|
"@vaadin/testing-helpers": "^0.3.2",
|
|
41
41
|
"sinon": "^9.2.1"
|
|
42
42
|
},
|
|
43
|
-
"gitHead": "
|
|
43
|
+
"gitHead": "10838304fe6f5c98b838ec3a90bdcf49cbf4650b"
|
|
44
44
|
}
|
package/src/checked-mixin.d.ts
CHANGED
|
@@ -12,7 +12,7 @@ import { InputMixinClass } from './input-mixin.js';
|
|
|
12
12
|
* A mixin to manage the checked state.
|
|
13
13
|
*/
|
|
14
14
|
export declare function CheckedMixin<T extends Constructor<object>>(
|
|
15
|
-
base: T
|
|
15
|
+
base: T,
|
|
16
16
|
): T &
|
|
17
17
|
Constructor<CheckedMixinClass> &
|
|
18
18
|
Constructor<DelegateStateMixinClass> &
|
package/src/checked-mixin.js
CHANGED
|
@@ -29,8 +29,8 @@ export const CheckedMixin = dedupingMixin(
|
|
|
29
29
|
type: Boolean,
|
|
30
30
|
value: false,
|
|
31
31
|
notify: true,
|
|
32
|
-
reflectToAttribute: true
|
|
33
|
-
}
|
|
32
|
+
reflectToAttribute: true,
|
|
33
|
+
},
|
|
34
34
|
};
|
|
35
35
|
}
|
|
36
36
|
|
|
@@ -50,5 +50,5 @@ export const CheckedMixin = dedupingMixin(
|
|
|
50
50
|
_toggleChecked(checked) {
|
|
51
51
|
this.checked = checked;
|
|
52
52
|
}
|
|
53
|
-
}
|
|
53
|
+
},
|
|
54
54
|
);
|
|
@@ -12,7 +12,7 @@ import { TabindexMixinClass } from '@vaadin/component-base/src/tabindex-mixin.js
|
|
|
12
12
|
* A mixin to forward focus to an element in the light DOM.
|
|
13
13
|
*/
|
|
14
14
|
export declare function DelegateFocusMixin<T extends Constructor<HTMLElement>>(
|
|
15
|
-
base: T
|
|
15
|
+
base: T,
|
|
16
16
|
): T &
|
|
17
17
|
Constructor<DelegateFocusMixinClass> &
|
|
18
18
|
Constructor<DisabledMixinClass> &
|
|
@@ -23,7 +23,7 @@ export const DelegateFocusMixin = dedupingMixin(
|
|
|
23
23
|
* Specify that this control should have input focus when the page loads.
|
|
24
24
|
*/
|
|
25
25
|
autofocus: {
|
|
26
|
-
type: Boolean
|
|
26
|
+
type: Boolean,
|
|
27
27
|
},
|
|
28
28
|
|
|
29
29
|
/**
|
|
@@ -41,7 +41,7 @@ export const DelegateFocusMixin = dedupingMixin(
|
|
|
41
41
|
focusElement: {
|
|
42
42
|
type: Object,
|
|
43
43
|
readOnly: true,
|
|
44
|
-
observer: '_focusElementChanged'
|
|
44
|
+
observer: '_focusElementChanged',
|
|
45
45
|
},
|
|
46
46
|
|
|
47
47
|
/**
|
|
@@ -53,8 +53,8 @@ export const DelegateFocusMixin = dedupingMixin(
|
|
|
53
53
|
* @override
|
|
54
54
|
*/
|
|
55
55
|
_lastTabIndex: {
|
|
56
|
-
value: 0
|
|
57
|
-
}
|
|
56
|
+
value: 0,
|
|
57
|
+
},
|
|
58
58
|
};
|
|
59
59
|
}
|
|
60
60
|
|
|
@@ -224,5 +224,5 @@ export const DelegateFocusMixin = dedupingMixin(
|
|
|
224
224
|
this.tabindex = undefined;
|
|
225
225
|
}
|
|
226
226
|
}
|
|
227
|
-
}
|
|
227
|
+
},
|
|
228
228
|
);
|
|
@@ -9,7 +9,7 @@ import { Constructor } from '@open-wc/dedupe-mixin';
|
|
|
9
9
|
* A mixin to delegate properties and attributes to a target element.
|
|
10
10
|
*/
|
|
11
11
|
export declare function DelegateStateMixin<T extends Constructor<HTMLElement>>(
|
|
12
|
-
base: T
|
|
12
|
+
base: T,
|
|
13
13
|
): T & Constructor<DelegateStateMixinClass>;
|
|
14
14
|
|
|
15
15
|
export declare class DelegateStateMixinClass {
|
|
@@ -21,8 +21,8 @@ export const DelegateStateMixin = dedupingMixin(
|
|
|
21
21
|
*/
|
|
22
22
|
stateTarget: {
|
|
23
23
|
type: Object,
|
|
24
|
-
observer: '_stateTargetChanged'
|
|
25
|
-
}
|
|
24
|
+
observer: '_stateTargetChanged',
|
|
25
|
+
},
|
|
26
26
|
};
|
|
27
27
|
}
|
|
28
28
|
|
|
@@ -121,5 +121,5 @@ export const DelegateStateMixin = dedupingMixin(
|
|
|
121
121
|
|
|
122
122
|
this.stateTarget[name] = value;
|
|
123
123
|
}
|
|
124
|
-
}
|
|
124
|
+
},
|
|
125
125
|
);
|
package/src/error-controller.js
CHANGED
package/src/field-mixin.d.ts
CHANGED
|
@@ -13,7 +13,7 @@ import { ValidateMixinClass } from './validate-mixin.js';
|
|
|
13
13
|
* A mixin to provide common field logic: label, error message and helper text.
|
|
14
14
|
*/
|
|
15
15
|
export declare function FieldMixin<T extends Constructor<HTMLElement>>(
|
|
16
|
-
superclass: T
|
|
16
|
+
superclass: T,
|
|
17
17
|
): T &
|
|
18
18
|
Constructor<ControllerMixinClass> &
|
|
19
19
|
Constructor<FieldMixinClass> &
|
package/src/field-mixin.js
CHANGED
|
@@ -28,7 +28,7 @@ export const FieldMixin = (superclass) =>
|
|
|
28
28
|
*/
|
|
29
29
|
ariaTarget: {
|
|
30
30
|
type: Object,
|
|
31
|
-
observer: '_ariaTargetChanged'
|
|
31
|
+
observer: '_ariaTargetChanged',
|
|
32
32
|
},
|
|
33
33
|
|
|
34
34
|
/**
|
|
@@ -38,7 +38,7 @@ export const FieldMixin = (superclass) =>
|
|
|
38
38
|
*/
|
|
39
39
|
errorMessage: {
|
|
40
40
|
type: String,
|
|
41
|
-
observer: '_errorMessageChanged'
|
|
41
|
+
observer: '_errorMessageChanged',
|
|
42
42
|
},
|
|
43
43
|
|
|
44
44
|
/**
|
|
@@ -47,11 +47,11 @@ export const FieldMixin = (superclass) =>
|
|
|
47
47
|
*/
|
|
48
48
|
helperText: {
|
|
49
49
|
type: String,
|
|
50
|
-
observer: '_helperTextChanged'
|
|
50
|
+
observer: '_helperTextChanged',
|
|
51
51
|
},
|
|
52
52
|
|
|
53
53
|
/** @protected */
|
|
54
|
-
_helperId: String
|
|
54
|
+
_helperId: String,
|
|
55
55
|
};
|
|
56
56
|
}
|
|
57
57
|
|
package/src/helper-controller.js
CHANGED
|
@@ -151,7 +151,7 @@ export class HelperController extends SlotController {
|
|
|
151
151
|
attributeFilter: ['id'],
|
|
152
152
|
childList: true,
|
|
153
153
|
subtree: true,
|
|
154
|
-
characterData: true
|
|
154
|
+
characterData: true,
|
|
155
155
|
});
|
|
156
156
|
}
|
|
157
157
|
|
|
@@ -167,9 +167,9 @@ export class HelperController extends SlotController {
|
|
|
167
167
|
new CustomEvent('helper-changed', {
|
|
168
168
|
detail: {
|
|
169
169
|
hasHelper,
|
|
170
|
-
node: this.node
|
|
171
|
-
}
|
|
172
|
-
})
|
|
170
|
+
node: this.node,
|
|
171
|
+
},
|
|
172
|
+
}),
|
|
173
173
|
);
|
|
174
174
|
}
|
|
175
175
|
|
|
@@ -13,7 +13,7 @@ import { ValidateMixinClass } from './validate-mixin.js';
|
|
|
13
13
|
* A mixin to combine multiple input validation constraints.
|
|
14
14
|
*/
|
|
15
15
|
export declare function InputConstraintsMixin<T extends Constructor<HTMLElement>>(
|
|
16
|
-
base: T
|
|
16
|
+
base: T,
|
|
17
17
|
): T &
|
|
18
18
|
Constructor<DelegateStateMixinClass> &
|
|
19
19
|
Constructor<DisabledMixinClass> &
|
|
@@ -108,11 +108,11 @@ export const InputConstraintsMixin = dedupingMixin(
|
|
|
108
108
|
this.dispatchEvent(
|
|
109
109
|
new CustomEvent('change', {
|
|
110
110
|
detail: {
|
|
111
|
-
sourceEvent: event
|
|
111
|
+
sourceEvent: event,
|
|
112
112
|
},
|
|
113
113
|
bubbles: event.bubbles,
|
|
114
|
-
cancelable: event.cancelable
|
|
115
|
-
})
|
|
114
|
+
cancelable: event.cancelable,
|
|
115
|
+
}),
|
|
116
116
|
);
|
|
117
117
|
}
|
|
118
118
|
|
|
@@ -121,5 +121,5 @@ export const InputConstraintsMixin = dedupingMixin(
|
|
|
121
121
|
// 0 is valid for `minlength` and `maxlength`
|
|
122
122
|
return Boolean(constraint) || constraint === 0;
|
|
123
123
|
}
|
|
124
|
-
}
|
|
124
|
+
},
|
|
125
125
|
);
|
|
@@ -20,7 +20,7 @@ import { ValidateMixinClass } from './validate-mixin.js';
|
|
|
20
20
|
* A mixin to provide shared logic for the editable form input controls.
|
|
21
21
|
*/
|
|
22
22
|
export declare function InputControlMixin<T extends Constructor<HTMLElement>>(
|
|
23
|
-
base: T
|
|
23
|
+
base: T,
|
|
24
24
|
): T &
|
|
25
25
|
Constructor<ControllerMixinClass> &
|
|
26
26
|
Constructor<DelegateFocusMixinClass> &
|
|
@@ -19,7 +19,7 @@ import { InputConstraintsMixin } from './input-constraints-mixin.js';
|
|
|
19
19
|
*/
|
|
20
20
|
export const InputControlMixin = (superclass) =>
|
|
21
21
|
class InputControlMixinClass extends DelegateFocusMixin(
|
|
22
|
-
InputConstraintsMixin(FieldMixin(KeyboardMixin(superclass)))
|
|
22
|
+
InputConstraintsMixin(FieldMixin(KeyboardMixin(superclass))),
|
|
23
23
|
) {
|
|
24
24
|
static get properties() {
|
|
25
25
|
return {
|
|
@@ -28,7 +28,7 @@ export const InputControlMixin = (superclass) =>
|
|
|
28
28
|
*/
|
|
29
29
|
autoselect: {
|
|
30
30
|
type: Boolean,
|
|
31
|
-
value: false
|
|
31
|
+
value: false,
|
|
32
32
|
},
|
|
33
33
|
|
|
34
34
|
/**
|
|
@@ -38,7 +38,7 @@ export const InputControlMixin = (superclass) =>
|
|
|
38
38
|
clearButtonVisible: {
|
|
39
39
|
type: Boolean,
|
|
40
40
|
reflectToAttribute: true,
|
|
41
|
-
value: false
|
|
41
|
+
value: false,
|
|
42
42
|
},
|
|
43
43
|
|
|
44
44
|
/**
|
|
@@ -46,7 +46,7 @@ export const InputControlMixin = (superclass) =>
|
|
|
46
46
|
*/
|
|
47
47
|
name: {
|
|
48
48
|
type: String,
|
|
49
|
-
reflectToAttribute: true
|
|
49
|
+
reflectToAttribute: true,
|
|
50
50
|
},
|
|
51
51
|
|
|
52
52
|
/**
|
|
@@ -54,7 +54,7 @@ export const InputControlMixin = (superclass) =>
|
|
|
54
54
|
*/
|
|
55
55
|
placeholder: {
|
|
56
56
|
type: String,
|
|
57
|
-
reflectToAttribute: true
|
|
57
|
+
reflectToAttribute: true,
|
|
58
58
|
},
|
|
59
59
|
|
|
60
60
|
/**
|
|
@@ -63,7 +63,7 @@ export const InputControlMixin = (superclass) =>
|
|
|
63
63
|
readonly: {
|
|
64
64
|
type: Boolean,
|
|
65
65
|
value: false,
|
|
66
|
-
reflectToAttribute: true
|
|
66
|
+
reflectToAttribute: true,
|
|
67
67
|
},
|
|
68
68
|
|
|
69
69
|
/**
|
|
@@ -71,8 +71,8 @@ export const InputControlMixin = (superclass) =>
|
|
|
71
71
|
*/
|
|
72
72
|
title: {
|
|
73
73
|
type: String,
|
|
74
|
-
reflectToAttribute: true
|
|
75
|
-
}
|
|
74
|
+
reflectToAttribute: true,
|
|
75
|
+
},
|
|
76
76
|
};
|
|
77
77
|
}
|
|
78
78
|
|
|
@@ -136,6 +136,7 @@ export const InputControlMixin = (superclass) =>
|
|
|
136
136
|
super._onKeyDown(event);
|
|
137
137
|
|
|
138
138
|
if (event.key === 'Escape' && this.clearButtonVisible && !!this.value) {
|
|
139
|
+
event.stopPropagation();
|
|
139
140
|
this.__clear();
|
|
140
141
|
}
|
|
141
142
|
}
|
|
@@ -156,11 +157,11 @@ export const InputControlMixin = (superclass) =>
|
|
|
156
157
|
this.dispatchEvent(
|
|
157
158
|
new CustomEvent('change', {
|
|
158
159
|
detail: {
|
|
159
|
-
sourceEvent: event
|
|
160
|
+
sourceEvent: event,
|
|
160
161
|
},
|
|
161
162
|
bubbles: event.bubbles,
|
|
162
|
-
cancelable: event.cancelable
|
|
163
|
-
})
|
|
163
|
+
cancelable: event.cancelable,
|
|
164
|
+
}),
|
|
164
165
|
);
|
|
165
166
|
}
|
|
166
167
|
|
package/src/input-controller.js
CHANGED
|
@@ -21,7 +21,7 @@ import { ValidateMixinClass } from './validate-mixin.js';
|
|
|
21
21
|
* A mixin to provide logic for vaadin-text-field and related components.
|
|
22
22
|
*/
|
|
23
23
|
export declare function InputFieldMixin<T extends Constructor<HTMLElement>>(
|
|
24
|
-
base: T
|
|
24
|
+
base: T,
|
|
25
25
|
): T &
|
|
26
26
|
Constructor<ControllerMixinClass> &
|
|
27
27
|
Constructor<DelegateFocusMixinClass> &
|
package/src/input-field-mixin.js
CHANGED
|
@@ -21,7 +21,7 @@ export const InputFieldMixin = (superclass) =>
|
|
|
21
21
|
* https://developer.mozilla.org/en/docs/Web/HTML/Element/input#attr-autocomplete
|
|
22
22
|
*/
|
|
23
23
|
autocomplete: {
|
|
24
|
-
type: String
|
|
24
|
+
type: String,
|
|
25
25
|
},
|
|
26
26
|
|
|
27
27
|
/**
|
|
@@ -32,7 +32,7 @@ export const InputFieldMixin = (superclass) =>
|
|
|
32
32
|
* off: Disable autocorrection.
|
|
33
33
|
*/
|
|
34
34
|
autocorrect: {
|
|
35
|
-
type: String
|
|
35
|
+
type: String,
|
|
36
36
|
},
|
|
37
37
|
|
|
38
38
|
/**
|
|
@@ -45,7 +45,7 @@ export const InputFieldMixin = (superclass) =>
|
|
|
45
45
|
* none: No capitalization.
|
|
46
46
|
*/
|
|
47
47
|
autocapitalize: {
|
|
48
|
-
type: String
|
|
48
|
+
type: String,
|
|
49
49
|
},
|
|
50
50
|
|
|
51
51
|
/**
|
|
@@ -61,8 +61,8 @@ export const InputFieldMixin = (superclass) =>
|
|
|
61
61
|
*/
|
|
62
62
|
_enabledCharPattern: {
|
|
63
63
|
type: String,
|
|
64
|
-
observer: '_enabledCharPatternChanged'
|
|
65
|
-
}
|
|
64
|
+
observer: '_enabledCharPatternChanged',
|
|
65
|
+
},
|
|
66
66
|
};
|
|
67
67
|
}
|
|
68
68
|
|
package/src/input-mixin.js
CHANGED
|
@@ -31,7 +31,7 @@ export const InputMixin = dedupingMixin(
|
|
|
31
31
|
inputElement: {
|
|
32
32
|
type: Object,
|
|
33
33
|
readOnly: true,
|
|
34
|
-
observer: '_inputElementChanged'
|
|
34
|
+
observer: '_inputElementChanged',
|
|
35
35
|
},
|
|
36
36
|
|
|
37
37
|
/**
|
|
@@ -40,7 +40,7 @@ export const InputMixin = dedupingMixin(
|
|
|
40
40
|
*/
|
|
41
41
|
type: {
|
|
42
42
|
type: String,
|
|
43
|
-
readOnly: true
|
|
43
|
+
readOnly: true,
|
|
44
44
|
},
|
|
45
45
|
|
|
46
46
|
/**
|
|
@@ -50,8 +50,8 @@ export const InputMixin = dedupingMixin(
|
|
|
50
50
|
type: String,
|
|
51
51
|
value: '',
|
|
52
52
|
observer: '_valueChanged',
|
|
53
|
-
notify: true
|
|
54
|
-
}
|
|
53
|
+
notify: true,
|
|
54
|
+
},
|
|
55
55
|
};
|
|
56
56
|
}
|
|
57
57
|
|
|
@@ -176,5 +176,5 @@ export const InputMixin = dedupingMixin(
|
|
|
176
176
|
// Setting a value programmatically, sync it to input element.
|
|
177
177
|
this._forwardInputValue(newVal);
|
|
178
178
|
}
|
|
179
|
-
}
|
|
179
|
+
},
|
|
180
180
|
);
|
package/src/label-controller.js
CHANGED
|
@@ -22,7 +22,7 @@ export class LabelController extends SlotController {
|
|
|
22
22
|
this.__updateDefaultLabel(this.label);
|
|
23
23
|
|
|
24
24
|
this.__observeLabel(node);
|
|
25
|
-
}
|
|
25
|
+
},
|
|
26
26
|
);
|
|
27
27
|
}
|
|
28
28
|
|
|
@@ -138,7 +138,7 @@ export class LabelController extends SlotController {
|
|
|
138
138
|
attributeFilter: ['id'],
|
|
139
139
|
childList: true,
|
|
140
140
|
subtree: true,
|
|
141
|
-
characterData: true
|
|
141
|
+
characterData: true,
|
|
142
142
|
});
|
|
143
143
|
}
|
|
144
144
|
|
|
@@ -154,9 +154,9 @@ export class LabelController extends SlotController {
|
|
|
154
154
|
new CustomEvent('label-changed', {
|
|
155
155
|
detail: {
|
|
156
156
|
hasLabel,
|
|
157
|
-
node: this.node
|
|
158
|
-
}
|
|
159
|
-
})
|
|
157
|
+
node: this.node,
|
|
158
|
+
},
|
|
159
|
+
}),
|
|
160
160
|
);
|
|
161
161
|
}
|
|
162
162
|
|
package/src/label-mixin.d.ts
CHANGED
|
@@ -11,7 +11,7 @@ import { LabelController } from './label-controller.js';
|
|
|
11
11
|
* A mixin to provide label via corresponding property or named slot.
|
|
12
12
|
*/
|
|
13
13
|
export declare function LabelMixin<T extends Constructor<HTMLElement>>(
|
|
14
|
-
base: T
|
|
14
|
+
base: T,
|
|
15
15
|
): T & Constructor<LabelMixinClass> & Constructor<SlotMixinClass>;
|
|
16
16
|
|
|
17
17
|
export declare class LabelMixinClass {
|
package/src/label-mixin.js
CHANGED
|
@@ -24,8 +24,8 @@ export const LabelMixin = dedupingMixin(
|
|
|
24
24
|
*/
|
|
25
25
|
label: {
|
|
26
26
|
type: String,
|
|
27
|
-
observer: '_labelChanged'
|
|
28
|
-
}
|
|
27
|
+
observer: '_labelChanged',
|
|
28
|
+
},
|
|
29
29
|
};
|
|
30
30
|
}
|
|
31
31
|
|
|
@@ -50,5 +50,5 @@ export const LabelMixin = dedupingMixin(
|
|
|
50
50
|
_labelChanged(label) {
|
|
51
51
|
this._labelController.setLabel(label);
|
|
52
52
|
}
|
|
53
|
-
}
|
|
53
|
+
},
|
|
54
54
|
);
|
package/src/pattern-mixin.d.ts
CHANGED
|
@@ -14,7 +14,7 @@ import { ValidateMixinClass } from './validate-mixin.js';
|
|
|
14
14
|
* A mixin to provide `pattern` and `preventInvalidInput` properties.
|
|
15
15
|
*/
|
|
16
16
|
export declare function PatternMixin<T extends Constructor<HTMLElement>>(
|
|
17
|
-
base: T
|
|
17
|
+
base: T,
|
|
18
18
|
): T &
|
|
19
19
|
Constructor<DelegateStateMixinClass> &
|
|
20
20
|
Constructor<DisabledMixinClass> &
|
package/src/pattern-mixin.js
CHANGED
|
@@ -22,7 +22,7 @@ export const PatternMixin = (superclass) =>
|
|
|
22
22
|
* The pattern must match the entire value, not just some subset.
|
|
23
23
|
*/
|
|
24
24
|
pattern: {
|
|
25
|
-
type: String
|
|
25
|
+
type: String,
|
|
26
26
|
},
|
|
27
27
|
|
|
28
28
|
/**
|
|
@@ -31,8 +31,8 @@ export const PatternMixin = (superclass) =>
|
|
|
31
31
|
* @attr {boolean} prevent-invalid-input
|
|
32
32
|
*/
|
|
33
33
|
preventInvalidInput: {
|
|
34
|
-
type: Boolean
|
|
35
|
-
}
|
|
34
|
+
type: Boolean,
|
|
35
|
+
},
|
|
36
36
|
};
|
|
37
37
|
}
|
|
38
38
|
|
|
@@ -14,7 +14,7 @@ import { DelegateFocusMixinClass } from './delegate-focus-mixin.js';
|
|
|
14
14
|
* A mixin to forward focus to an element in the shadow DOM.
|
|
15
15
|
*/
|
|
16
16
|
export declare function ShadowFocusMixin<T extends Constructor<HTMLElement>>(
|
|
17
|
-
base: T
|
|
17
|
+
base: T,
|
|
18
18
|
): T &
|
|
19
19
|
Constructor<DelegateFocusMixinClass> &
|
|
20
20
|
Constructor<DisabledMixinClass> &
|
|
@@ -10,7 +10,7 @@ import { Constructor } from '@open-wc/dedupe-mixin';
|
|
|
10
10
|
* This is useful e.g. to hide native `<input type="number">` controls.
|
|
11
11
|
*/
|
|
12
12
|
export declare function SlotStylesMixin<T extends Constructor<HTMLElement>>(
|
|
13
|
-
base: T
|
|
13
|
+
base: T,
|
|
14
14
|
): T & Constructor<SlotStylesMixinClass>;
|
|
15
15
|
|
|
16
16
|
export declare class SlotStylesMixinClass {
|
package/src/slot-styles-mixin.js
CHANGED
|
@@ -9,7 +9,7 @@ export class SlotTargetController implements ReactiveController {
|
|
|
9
9
|
constructor(
|
|
10
10
|
sourceSlot: HTMLSlotElement,
|
|
11
11
|
targetFactory: () => HTMLElement,
|
|
12
|
-
copyCallback?: (nodes: HTMLElement[]) => void
|
|
12
|
+
copyCallback?: (nodes: HTMLElement[]) => void,
|
|
13
13
|
);
|
|
14
14
|
|
|
15
15
|
hostConnected(): void;
|
package/src/validate-mixin.js
CHANGED
|
@@ -22,7 +22,7 @@ export const ValidateMixin = dedupingMixin(
|
|
|
22
22
|
type: Boolean,
|
|
23
23
|
reflectToAttribute: true,
|
|
24
24
|
notify: true,
|
|
25
|
-
value: false
|
|
25
|
+
value: false,
|
|
26
26
|
},
|
|
27
27
|
|
|
28
28
|
/**
|
|
@@ -30,8 +30,8 @@ export const ValidateMixin = dedupingMixin(
|
|
|
30
30
|
*/
|
|
31
31
|
required: {
|
|
32
32
|
type: Boolean,
|
|
33
|
-
reflectToAttribute: true
|
|
34
|
-
}
|
|
33
|
+
reflectToAttribute: true,
|
|
34
|
+
},
|
|
35
35
|
};
|
|
36
36
|
}
|
|
37
37
|
|
|
@@ -52,5 +52,5 @@ export const ValidateMixin = dedupingMixin(
|
|
|
52
52
|
checkValidity() {
|
|
53
53
|
return !this.required || !!this.value;
|
|
54
54
|
}
|
|
55
|
-
}
|
|
55
|
+
},
|
|
56
56
|
);
|