@dimailn/vuetify 2.7.2-alpha23 → 2.7.2-alpha25
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/vuetify.js +280 -256
- package/dist/vuetify.js.map +1 -1
- package/dist/vuetify.min.css +1 -1
- package/dist/vuetify.min.js +2 -2
- package/es5/components/VBadge/VBadge.js +17 -14
- package/es5/components/VBadge/VBadge.js.map +1 -1
- package/es5/components/VBtn/VBtn.js +16 -16
- package/es5/components/VBtn/VBtn.js.map +1 -1
- package/es5/components/VColorPicker/VColorPicker.js +18 -31
- package/es5/components/VColorPicker/VColorPicker.js.map +1 -1
- package/es5/components/VColorPicker/VColorPickerCanvas.js +45 -46
- package/es5/components/VColorPicker/VColorPickerCanvas.js.map +1 -1
- package/es5/components/VColorPicker/VColorPickerEdit.js +27 -26
- package/es5/components/VColorPicker/VColorPickerEdit.js.map +1 -1
- package/es5/components/VColorPicker/VColorPickerPreview.js +41 -30
- package/es5/components/VColorPicker/VColorPickerPreview.js.map +1 -1
- package/es5/components/VColorPicker/VColorPickerSwatches.js +13 -10
- package/es5/components/VColorPicker/VColorPickerSwatches.js.map +1 -1
- package/es5/components/VDataTable/VDataTable.js +7 -11
- package/es5/components/VDataTable/VDataTable.js.map +1 -1
- package/es5/components/VInput/VInput.js +24 -6
- package/es5/components/VInput/VInput.js.map +1 -1
- package/es5/components/VSelect/VSelectList.js +1 -1
- package/es5/components/VSelect/VSelectList.js.map +1 -1
- package/es5/components/VSlider/VSlider.js +23 -18
- package/es5/components/VSlider/VSlider.js.map +1 -1
- package/es5/components/VTooltip/VTooltip.js +3 -7
- package/es5/components/VTooltip/VTooltip.js.map +1 -1
- package/es5/framework.js +1 -1
- package/es5/mixins/activatable/index.js +2 -1
- package/es5/mixins/activatable/index.js.map +1 -1
- package/es5/mixins/bootable/index.js +1 -2
- package/es5/mixins/bootable/index.js.map +1 -1
- package/es5/mixins/mouse/index.js +10 -5
- package/es5/mixins/mouse/index.js.map +1 -1
- package/es5/mixins/selectable/index.js +3 -0
- package/es5/mixins/selectable/index.js.map +1 -1
- package/lib/components/VBadge/VBadge.js +14 -13
- package/lib/components/VBadge/VBadge.js.map +1 -1
- package/lib/components/VBtn/VBtn.js +18 -19
- package/lib/components/VBtn/VBtn.js.map +1 -1
- package/lib/components/VColorPicker/VColorPicker.js +29 -37
- package/lib/components/VColorPicker/VColorPicker.js.map +1 -1
- package/lib/components/VColorPicker/VColorPickerCanvas.js +41 -43
- package/lib/components/VColorPicker/VColorPickerCanvas.js.map +1 -1
- package/lib/components/VColorPicker/VColorPickerEdit.js +25 -31
- package/lib/components/VColorPicker/VColorPickerEdit.js.map +1 -1
- package/lib/components/VColorPicker/VColorPickerPreview.js +45 -32
- package/lib/components/VColorPicker/VColorPickerPreview.js.map +1 -1
- package/lib/components/VColorPicker/VColorPickerSwatches.js +15 -9
- package/lib/components/VColorPicker/VColorPickerSwatches.js.map +1 -1
- package/lib/components/VDataTable/VDataTable.js +3 -4
- package/lib/components/VDataTable/VDataTable.js.map +1 -1
- package/lib/components/VInput/VInput.js +16 -4
- package/lib/components/VInput/VInput.js.map +1 -1
- package/lib/components/VSelect/VSelectList.js +2 -1
- package/lib/components/VSelect/VSelectList.js.map +1 -1
- package/lib/components/VSlider/VSlider.js +26 -21
- package/lib/components/VSlider/VSlider.js.map +1 -1
- package/lib/components/VTooltip/VTooltip.js +6 -9
- package/lib/components/VTooltip/VTooltip.js.map +1 -1
- package/lib/framework.js +1 -1
- package/lib/mixins/activatable/index.js +2 -1
- package/lib/mixins/activatable/index.js.map +1 -1
- package/lib/mixins/bootable/index.js +2 -4
- package/lib/mixins/bootable/index.js.map +1 -1
- package/lib/mixins/mouse/index.js +9 -5
- package/lib/mixins/mouse/index.js.map +1 -1
- package/lib/mixins/selectable/index.js +4 -0
- package/lib/mixins/selectable/index.js.map +1 -1
- package/package.json +1 -1
- package/src/components/VBadge/VBadge.ts +24 -25
- package/src/components/VBadge/__tests__/VBadge.spec.ts +47 -30
- package/src/components/VBadge/__tests__/__snapshots__/VBadge.spec.ts.snap +5 -5
- package/src/components/VBtn/VBtn.ts +18 -16
- package/src/components/VBtn/__tests__/VBtn.spec.ts +257 -242
- package/src/components/VBtn/__tests__/__snapshots__/VBtn.spec.ts.snap +13 -73
- package/src/components/VColorPicker/VColorPicker.ts +32 -35
- package/src/components/VColorPicker/VColorPickerCanvas.ts +44 -37
- package/src/components/VColorPicker/VColorPickerEdit.ts +37 -35
- package/src/components/VColorPicker/VColorPickerPreview.ts +48 -28
- package/src/components/VColorPicker/VColorPickerSwatches.ts +23 -12
- package/src/components/VColorPicker/__tests__/VColorPicker.spec.ts +47 -47
- package/src/components/VColorPicker/__tests__/VColorPickerCanvas.spec.ts +15 -13
- package/src/components/VColorPicker/__tests__/VColorPickerEdit.spec.ts +52 -50
- package/src/components/VColorPicker/__tests__/VColorPickerPreview.spec.ts +101 -30
- package/src/components/VColorPicker/__tests__/__snapshots__/VColorPicker.spec.ts.snap +200 -157
- package/src/components/VColorPicker/__tests__/__snapshots__/VColorPickerEdit.spec.ts.snap +28 -11
- package/src/components/VDataTable/VDataTable.ts +3 -3
- package/src/components/VInput/VInput.ts +12 -2
- package/src/components/VInput/__tests__/VInput.spec.ts +170 -234
- package/src/components/VInput/__tests__/__snapshots__/VInput.spec.ts.snap +50 -101
- package/src/components/VSelect/VSelectList.ts +1 -0
- package/src/components/VSkeletonLoader/__tests__/VSkeletonLoader.spec.ts +22 -15
- package/src/components/VSkeletonLoader/__tests__/__snapshots__/VSkeletonLoader.spec.ts.snap +60 -60
- package/src/components/VSlider/VSlider.ts +43 -27
- package/src/components/VSlider/__tests__/VSlider.spec.ts +188 -286
- package/src/components/VSlider/__tests__/__snapshots__/VSlider.spec.ts.snap +157 -246
- package/src/components/VTabs/__tests__/VTab.spec.ts +3 -3
- package/src/components/VTabs/__tests__/VTabsBar.spec.ts +2 -2
- package/src/components/VTooltip/VTooltip.ts +20 -20
- package/src/components/VTooltip/__tests__/VTooltip.spec.ts +60 -75
- package/src/mixins/activatable/index.ts +2 -1
- package/src/mixins/bootable/__tests__/bootable.spec.ts +17 -11
- package/src/mixins/bootable/index.ts +4 -3
- package/src/mixins/mouse/__tests__/mouse.spec.ts +54 -40
- package/src/mixins/mouse/index.ts +10 -6
- package/src/mixins/selectable/index.ts +4 -0
|
@@ -1,43 +1,54 @@
|
|
|
1
1
|
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
|
2
2
|
|
|
3
|
+
exports[`VInput.ts should apply attrs to root element 1`] = `
|
|
4
|
+
<div class="v-input theme--light"
|
|
5
|
+
foo="bar"
|
|
6
|
+
>
|
|
7
|
+
<div class="v-input__control">
|
|
8
|
+
<div class="v-input__slot">
|
|
9
|
+
</div>
|
|
10
|
+
<div class="v-messages theme--light">
|
|
11
|
+
<div class="v-messages__wrapper">
|
|
12
|
+
</div>
|
|
13
|
+
</div>
|
|
14
|
+
</div>
|
|
15
|
+
</div>
|
|
16
|
+
`;
|
|
17
|
+
|
|
3
18
|
exports[`VInput.ts should apply theme to label, counter, messages and icons 1`] = `
|
|
4
19
|
<div class="v-input theme--light">
|
|
5
20
|
<div class="v-input__prepend-outer">
|
|
6
21
|
<div class="v-input__icon v-input__icon--prepend">
|
|
7
|
-
<
|
|
8
|
-
|
|
22
|
+
<span class="v-icon notranslate theme--light"
|
|
23
|
+
aria-hidden="true"
|
|
9
24
|
>
|
|
10
|
-
|
|
11
|
-
</i>
|
|
25
|
+
</span>
|
|
12
26
|
</div>
|
|
13
27
|
</div>
|
|
14
28
|
<div class="v-input__control">
|
|
15
29
|
<div class="v-input__slot">
|
|
16
|
-
<label
|
|
17
|
-
|
|
30
|
+
<label class="v-label theme--light"
|
|
31
|
+
for="input-50"
|
|
32
|
+
aria-hidden="false"
|
|
18
33
|
style="left: 0px; position: relative;"
|
|
19
34
|
>
|
|
20
35
|
foo
|
|
21
36
|
</label>
|
|
22
37
|
</div>
|
|
23
38
|
<div class="v-messages theme--light">
|
|
24
|
-
<
|
|
25
|
-
tag="div"
|
|
26
|
-
class="v-messages__wrapper"
|
|
27
|
-
>
|
|
39
|
+
<div class="v-messages__wrapper">
|
|
28
40
|
<div class="v-messages__message">
|
|
29
41
|
bar
|
|
30
42
|
</div>
|
|
31
|
-
</
|
|
43
|
+
</div>
|
|
32
44
|
</div>
|
|
33
45
|
</div>
|
|
34
46
|
<div class="v-input__append-outer">
|
|
35
47
|
<div class="v-input__icon v-input__icon--append">
|
|
36
|
-
<
|
|
37
|
-
|
|
48
|
+
<span class="v-icon notranslate theme--light"
|
|
49
|
+
aria-hidden="true"
|
|
38
50
|
>
|
|
39
|
-
|
|
40
|
-
</i>
|
|
51
|
+
</span>
|
|
41
52
|
</div>
|
|
42
53
|
</div>
|
|
43
54
|
</div>
|
|
@@ -49,11 +60,8 @@ exports[`VInput.ts should be in an error state 1`] = `
|
|
|
49
60
|
<div class="v-input__slot">
|
|
50
61
|
</div>
|
|
51
62
|
<div class="v-messages theme--light error--text">
|
|
52
|
-
<
|
|
53
|
-
|
|
54
|
-
class="v-messages__wrapper"
|
|
55
|
-
>
|
|
56
|
-
</span>
|
|
63
|
+
<div class="v-messages__wrapper">
|
|
64
|
+
</div>
|
|
57
65
|
</div>
|
|
58
66
|
</div>
|
|
59
67
|
</div>
|
|
@@ -67,14 +75,11 @@ exports[`VInput.ts should be in an error state 2`] = `
|
|
|
67
75
|
<div class="v-messages theme--light error--text"
|
|
68
76
|
role="alert"
|
|
69
77
|
>
|
|
70
|
-
<
|
|
71
|
-
|
|
72
|
-
class="v-messages__wrapper"
|
|
73
|
-
>
|
|
74
|
-
<div class="v-messages__message">
|
|
78
|
+
<div class="v-messages__wrapper">
|
|
79
|
+
<div class="v-messages__message message-transition-enter-from message-transition-enter-active">
|
|
75
80
|
required
|
|
76
81
|
</div>
|
|
77
|
-
</
|
|
82
|
+
</div>
|
|
78
83
|
</div>
|
|
79
84
|
</div>
|
|
80
85
|
</div>
|
|
@@ -84,22 +89,18 @@ exports[`VInput.ts should generate an icon and match snapshot 1`] = `
|
|
|
84
89
|
<div class="v-input theme--light">
|
|
85
90
|
<div class="v-input__prepend-outer">
|
|
86
91
|
<div class="v-input__icon v-input__icon--prepend">
|
|
87
|
-
<
|
|
88
|
-
|
|
92
|
+
<span class="v-icon notranslate theme--light"
|
|
93
|
+
aria-hidden="true"
|
|
89
94
|
>
|
|
90
|
-
|
|
91
|
-
</i>
|
|
95
|
+
</span>
|
|
92
96
|
</div>
|
|
93
97
|
</div>
|
|
94
98
|
<div class="v-input__control">
|
|
95
99
|
<div class="v-input__slot">
|
|
96
100
|
</div>
|
|
97
101
|
<div class="v-messages theme--light">
|
|
98
|
-
<
|
|
99
|
-
|
|
100
|
-
class="v-messages__wrapper"
|
|
101
|
-
>
|
|
102
|
-
</span>
|
|
102
|
+
<div class="v-messages__wrapper">
|
|
103
|
+
</div>
|
|
103
104
|
</div>
|
|
104
105
|
</div>
|
|
105
106
|
</div>
|
|
@@ -111,20 +112,16 @@ exports[`VInput.ts should generate an icon and match snapshot 2`] = `
|
|
|
111
112
|
<div class="v-input__slot">
|
|
112
113
|
</div>
|
|
113
114
|
<div class="v-messages theme--light">
|
|
114
|
-
<
|
|
115
|
-
|
|
116
|
-
class="v-messages__wrapper"
|
|
117
|
-
>
|
|
118
|
-
</span>
|
|
115
|
+
<div class="v-messages__wrapper">
|
|
116
|
+
</div>
|
|
119
117
|
</div>
|
|
120
118
|
</div>
|
|
121
119
|
<div class="v-input__append-outer">
|
|
122
120
|
<div class="v-input__icon v-input__icon--append">
|
|
123
|
-
<
|
|
124
|
-
|
|
121
|
+
<span class="v-icon notranslate theme--light"
|
|
122
|
+
aria-hidden="true"
|
|
125
123
|
>
|
|
126
|
-
|
|
127
|
-
</i>
|
|
124
|
+
</span>
|
|
128
125
|
</div>
|
|
129
126
|
</div>
|
|
130
127
|
</div>
|
|
@@ -136,11 +133,8 @@ exports[`VInput.ts should generate append and prepend slots 1`] = `
|
|
|
136
133
|
<div class="v-input__slot">
|
|
137
134
|
</div>
|
|
138
135
|
<div class="v-messages theme--light">
|
|
139
|
-
<
|
|
140
|
-
|
|
141
|
-
class="v-messages__wrapper"
|
|
142
|
-
>
|
|
143
|
-
</span>
|
|
136
|
+
<div class="v-messages__wrapper">
|
|
137
|
+
</div>
|
|
144
138
|
</div>
|
|
145
139
|
</div>
|
|
146
140
|
<div class="v-input__append-outer">
|
|
@@ -162,27 +156,8 @@ exports[`VInput.ts should generate append and prepend slots 2`] = `
|
|
|
162
156
|
<div class="v-input__slot">
|
|
163
157
|
</div>
|
|
164
158
|
<div class="v-messages theme--light">
|
|
165
|
-
<
|
|
166
|
-
|
|
167
|
-
class="v-messages__wrapper"
|
|
168
|
-
>
|
|
169
|
-
</span>
|
|
170
|
-
</div>
|
|
171
|
-
</div>
|
|
172
|
-
</div>
|
|
173
|
-
`;
|
|
174
|
-
|
|
175
|
-
exports[`VInput.ts should not apply attrs to element 1`] = `
|
|
176
|
-
<div class="v-input theme--light">
|
|
177
|
-
<div class="v-input__control">
|
|
178
|
-
<div class="v-input__slot">
|
|
179
|
-
</div>
|
|
180
|
-
<div class="v-messages theme--light">
|
|
181
|
-
<span name="message-transition"
|
|
182
|
-
tag="div"
|
|
183
|
-
class="v-messages__wrapper"
|
|
184
|
-
>
|
|
185
|
-
</span>
|
|
159
|
+
<div class="v-messages__wrapper">
|
|
160
|
+
</div>
|
|
186
161
|
</div>
|
|
187
162
|
</div>
|
|
188
163
|
</div>
|
|
@@ -201,43 +176,17 @@ exports[`VInput.ts should render a label 1`] = `
|
|
|
201
176
|
<div class="v-input theme--light">
|
|
202
177
|
<div class="v-input__control">
|
|
203
178
|
<div class="v-input__slot">
|
|
204
|
-
<label
|
|
205
|
-
|
|
179
|
+
<label class="v-label theme--light"
|
|
180
|
+
for="input-45"
|
|
181
|
+
aria-hidden="false"
|
|
206
182
|
style="left: 0px; position: relative;"
|
|
207
183
|
>
|
|
208
184
|
foo
|
|
209
185
|
</label>
|
|
210
186
|
</div>
|
|
211
187
|
<div class="v-messages theme--light">
|
|
212
|
-
<
|
|
213
|
-
|
|
214
|
-
class="v-messages__wrapper"
|
|
215
|
-
>
|
|
216
|
-
</span>
|
|
217
|
-
</div>
|
|
218
|
-
</div>
|
|
219
|
-
</div>
|
|
220
|
-
`;
|
|
221
|
-
|
|
222
|
-
exports[`VInput.ts should render a label 2`] = `
|
|
223
|
-
<div class="v-input theme--light">
|
|
224
|
-
<div class="v-input__control">
|
|
225
|
-
<div class="v-input__slot">
|
|
226
|
-
<label for="input-63"
|
|
227
|
-
class="v-label theme--light"
|
|
228
|
-
style="left: 0px; position: relative;"
|
|
229
|
-
>
|
|
230
|
-
<div>
|
|
231
|
-
foo
|
|
232
|
-
</div>
|
|
233
|
-
</label>
|
|
234
|
-
</div>
|
|
235
|
-
<div class="v-messages theme--light">
|
|
236
|
-
<span name="message-transition"
|
|
237
|
-
tag="div"
|
|
238
|
-
class="v-messages__wrapper"
|
|
239
|
-
>
|
|
240
|
-
</span>
|
|
188
|
+
<div class="v-messages__wrapper">
|
|
189
|
+
</div>
|
|
241
190
|
</div>
|
|
242
191
|
</div>
|
|
243
192
|
</div>
|
|
@@ -4,21 +4,26 @@ import VSkeletonLoader, { HTMLSkeletonLoaderElement } from '../VSkeletonLoader'
|
|
|
4
4
|
// Utilities
|
|
5
5
|
import {
|
|
6
6
|
mount,
|
|
7
|
-
|
|
8
|
-
|
|
7
|
+
enableAutoUnmount,
|
|
8
|
+
VueWrapper,
|
|
9
9
|
} from '@vue/test-utils'
|
|
10
|
+
import { nextTick } from 'vue'
|
|
10
11
|
|
|
11
12
|
describe('VSkeletonLoader.ts', () => {
|
|
12
13
|
type Instance = InstanceType<typeof VSkeletonLoader>
|
|
13
|
-
let mountFunction: (options?:
|
|
14
|
+
let mountFunction: (options?: any) => VueWrapper
|
|
15
|
+
|
|
16
|
+
enableAutoUnmount(afterEach)
|
|
14
17
|
|
|
15
18
|
beforeEach(() => {
|
|
16
19
|
mountFunction = (options = {}) => {
|
|
17
20
|
return mount(VSkeletonLoader, {
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
21
|
+
global: {
|
|
22
|
+
mocks: {
|
|
23
|
+
$vuetify: {
|
|
24
|
+
lang: {
|
|
25
|
+
t: (v: string) => v,
|
|
26
|
+
},
|
|
22
27
|
},
|
|
23
28
|
},
|
|
24
29
|
},
|
|
@@ -40,13 +45,13 @@ describe('VSkeletonLoader.ts', () => {
|
|
|
40
45
|
for (const key in wrapper.vm.rootTypes) {
|
|
41
46
|
const type = wrapper.vm.rootTypes[key]
|
|
42
47
|
|
|
43
|
-
const iteration = mountFunction({
|
|
48
|
+
const iteration = mountFunction({ props: { type } })
|
|
44
49
|
|
|
45
50
|
expect(iteration.html()).toMatchSnapshot()
|
|
46
51
|
}
|
|
47
52
|
})
|
|
48
53
|
|
|
49
|
-
it('should dynamically render content', () => {
|
|
54
|
+
it('should dynamically render content', async () => {
|
|
50
55
|
const wrapper = mountFunction({
|
|
51
56
|
slots: {
|
|
52
57
|
default: '<div>foobar</div>',
|
|
@@ -55,14 +60,15 @@ describe('VSkeletonLoader.ts', () => {
|
|
|
55
60
|
|
|
56
61
|
expect(wrapper.html()).toMatchSnapshot()
|
|
57
62
|
|
|
58
|
-
wrapper.setProps({ loading: true })
|
|
63
|
+
await wrapper.setProps({ loading: true })
|
|
64
|
+
await nextTick()
|
|
59
65
|
|
|
60
66
|
expect(wrapper.html()).toMatchSnapshot()
|
|
61
67
|
})
|
|
62
68
|
|
|
63
|
-
it('should have the correct a11y attributes when loading', () => {
|
|
69
|
+
it('should have the correct a11y attributes when loading', async () => {
|
|
64
70
|
const wrapper = mountFunction({
|
|
65
|
-
|
|
71
|
+
props: { loading: true },
|
|
66
72
|
slots: {
|
|
67
73
|
// Add a default slot to allow
|
|
68
74
|
// toggling the loading prop
|
|
@@ -74,7 +80,8 @@ describe('VSkeletonLoader.ts', () => {
|
|
|
74
80
|
expect(wrapper.element.getAttribute('aria-live')).toBe('polite')
|
|
75
81
|
expect(wrapper.element.getAttribute('role')).toBe('alert')
|
|
76
82
|
|
|
77
|
-
wrapper.setProps({ loading: false })
|
|
83
|
+
await wrapper.setProps({ loading: false })
|
|
84
|
+
await nextTick()
|
|
78
85
|
|
|
79
86
|
expect(wrapper.element.getAttribute('aria-busy')).toBeNull()
|
|
80
87
|
expect(wrapper.element.getAttribute('aria-live')).toBeNull()
|
|
@@ -83,7 +90,7 @@ describe('VSkeletonLoader.ts', () => {
|
|
|
83
90
|
|
|
84
91
|
it('should not render aria attributes when using boilerplate', () => {
|
|
85
92
|
const wrapper = mountFunction({
|
|
86
|
-
|
|
93
|
+
props: { boilerplate: true },
|
|
87
94
|
})
|
|
88
95
|
|
|
89
96
|
expect(wrapper.vm.attrs).toEqual({})
|
|
@@ -94,7 +101,7 @@ describe('VSkeletonLoader.ts', () => {
|
|
|
94
101
|
it('should remove transition when loading content', () => {
|
|
95
102
|
const el = document.createElement('div') as HTMLSkeletonLoaderElement
|
|
96
103
|
const wrapper = mountFunction({
|
|
97
|
-
|
|
104
|
+
props: { loading: true },
|
|
98
105
|
})
|
|
99
106
|
|
|
100
107
|
wrapper.vm.onBeforeEnter(el)
|