@dimailn/vuetify 2.7.2-alpha24 → 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.
Files changed (74) hide show
  1. package/dist/vuetify.js +241 -230
  2. package/dist/vuetify.js.map +1 -1
  3. package/dist/vuetify.min.css +1 -1
  4. package/dist/vuetify.min.js +2 -2
  5. package/es5/components/VBtn/VBtn.js +16 -16
  6. package/es5/components/VBtn/VBtn.js.map +1 -1
  7. package/es5/components/VColorPicker/VColorPicker.js +18 -31
  8. package/es5/components/VColorPicker/VColorPicker.js.map +1 -1
  9. package/es5/components/VColorPicker/VColorPickerCanvas.js +45 -46
  10. package/es5/components/VColorPicker/VColorPickerCanvas.js.map +1 -1
  11. package/es5/components/VColorPicker/VColorPickerEdit.js +27 -26
  12. package/es5/components/VColorPicker/VColorPickerEdit.js.map +1 -1
  13. package/es5/components/VColorPicker/VColorPickerPreview.js +41 -30
  14. package/es5/components/VColorPicker/VColorPickerPreview.js.map +1 -1
  15. package/es5/components/VColorPicker/VColorPickerSwatches.js +13 -10
  16. package/es5/components/VColorPicker/VColorPickerSwatches.js.map +1 -1
  17. package/es5/components/VDataTable/VDataTable.js +7 -11
  18. package/es5/components/VDataTable/VDataTable.js.map +1 -1
  19. package/es5/components/VInput/VInput.js +20 -6
  20. package/es5/components/VInput/VInput.js.map +1 -1
  21. package/es5/components/VSlider/VSlider.js +23 -18
  22. package/es5/components/VSlider/VSlider.js.map +1 -1
  23. package/es5/components/VTooltip/VTooltip.js +3 -7
  24. package/es5/components/VTooltip/VTooltip.js.map +1 -1
  25. package/es5/framework.js +1 -1
  26. package/lib/components/VBtn/VBtn.js +18 -19
  27. package/lib/components/VBtn/VBtn.js.map +1 -1
  28. package/lib/components/VColorPicker/VColorPicker.js +29 -37
  29. package/lib/components/VColorPicker/VColorPicker.js.map +1 -1
  30. package/lib/components/VColorPicker/VColorPickerCanvas.js +41 -43
  31. package/lib/components/VColorPicker/VColorPickerCanvas.js.map +1 -1
  32. package/lib/components/VColorPicker/VColorPickerEdit.js +25 -31
  33. package/lib/components/VColorPicker/VColorPickerEdit.js.map +1 -1
  34. package/lib/components/VColorPicker/VColorPickerPreview.js +45 -32
  35. package/lib/components/VColorPicker/VColorPickerPreview.js.map +1 -1
  36. package/lib/components/VColorPicker/VColorPickerSwatches.js +15 -9
  37. package/lib/components/VColorPicker/VColorPickerSwatches.js.map +1 -1
  38. package/lib/components/VDataTable/VDataTable.js +3 -4
  39. package/lib/components/VDataTable/VDataTable.js.map +1 -1
  40. package/lib/components/VInput/VInput.js +12 -4
  41. package/lib/components/VInput/VInput.js.map +1 -1
  42. package/lib/components/VSlider/VSlider.js +26 -21
  43. package/lib/components/VSlider/VSlider.js.map +1 -1
  44. package/lib/components/VTooltip/VTooltip.js +6 -9
  45. package/lib/components/VTooltip/VTooltip.js.map +1 -1
  46. package/lib/framework.js +1 -1
  47. package/package.json +1 -1
  48. package/src/components/VBtn/VBtn.ts +18 -16
  49. package/src/components/VBtn/__tests__/VBtn.spec.ts +257 -242
  50. package/src/components/VBtn/__tests__/__snapshots__/VBtn.spec.ts.snap +13 -73
  51. package/src/components/VColorPicker/VColorPicker.ts +32 -35
  52. package/src/components/VColorPicker/VColorPickerCanvas.ts +44 -37
  53. package/src/components/VColorPicker/VColorPickerEdit.ts +37 -35
  54. package/src/components/VColorPicker/VColorPickerPreview.ts +48 -28
  55. package/src/components/VColorPicker/VColorPickerSwatches.ts +23 -12
  56. package/src/components/VColorPicker/__tests__/VColorPicker.spec.ts +47 -47
  57. package/src/components/VColorPicker/__tests__/VColorPickerCanvas.spec.ts +15 -13
  58. package/src/components/VColorPicker/__tests__/VColorPickerEdit.spec.ts +52 -50
  59. package/src/components/VColorPicker/__tests__/VColorPickerPreview.spec.ts +101 -30
  60. package/src/components/VColorPicker/__tests__/__snapshots__/VColorPicker.spec.ts.snap +200 -157
  61. package/src/components/VColorPicker/__tests__/__snapshots__/VColorPickerEdit.spec.ts.snap +28 -11
  62. package/src/components/VDataTable/VDataTable.ts +3 -3
  63. package/src/components/VInput/VInput.ts +8 -2
  64. package/src/components/VInput/__tests__/VInput.spec.ts +170 -234
  65. package/src/components/VInput/__tests__/__snapshots__/VInput.spec.ts.snap +50 -101
  66. package/src/components/VSkeletonLoader/__tests__/VSkeletonLoader.spec.ts +22 -15
  67. package/src/components/VSkeletonLoader/__tests__/__snapshots__/VSkeletonLoader.spec.ts.snap +60 -60
  68. package/src/components/VSlider/VSlider.ts +43 -27
  69. package/src/components/VSlider/__tests__/VSlider.spec.ts +188 -286
  70. package/src/components/VSlider/__tests__/__snapshots__/VSlider.spec.ts.snap +157 -246
  71. package/src/components/VTabs/__tests__/VTab.spec.ts +3 -3
  72. package/src/components/VTabs/__tests__/VTabsBar.spec.ts +2 -2
  73. package/src/components/VTooltip/VTooltip.ts +20 -20
  74. package/src/components/VTooltip/__tests__/VTooltip.spec.ts +60 -75
@@ -1,34 +1,41 @@
1
- // Libraries
2
- import Vue from 'vue'
3
-
4
- // Plugins
5
- import Router from 'vue-router'
6
-
1
+ /* eslint-disable max-statements */
7
2
  // Components
8
3
  import VBtn from '../VBtn'
9
4
 
10
5
  // Utilities
11
- import {
12
- createLocalVue,
13
- mount,
14
- Wrapper,
15
- } from '@vue/test-utils'
16
- // import { compileToFunctions } from 'vue-template-compiler'
17
-
18
- describe('VBtn.ts', () => { // eslint-disable-line max-statements
19
- let mountFunction: (options?: object) => Wrapper<Vue>
20
- let router: Router
21
- let localVue: typeof Vue
6
+ import { mount, enableAutoUnmount, VueWrapper } from '@vue/test-utils'
7
+ import { createRouter, createWebHistory } from 'vue-router'
8
+ import { nextTick } from 'vue'
9
+ import { Vue3RouterLinkStub } from '../../../../test/util/stubs'
10
+
11
+ // Auto cleanup after each test
12
+ enableAutoUnmount(afterEach)
13
+
14
+ describe('VBtn.ts', () => {
15
+ // eslint-disable-line max-statements
16
+ let mountFunction: (options?: object) => VueWrapper<any>
17
+ let router: any
22
18
 
23
19
  beforeEach(() => {
24
- // router = new Router()
25
- // localVue = createLocalVue()
26
- // localVue.use(Router)
20
+ router = createRouter({
21
+ history: createWebHistory(),
22
+ routes: [
23
+ { path: '/', component: { template: '<div>Home</div>' } },
24
+ { path: '/foobar', component: { template: '<div>Foobar</div>' } },
25
+ { path: '/fizzbuzz', component: { template: '<div>Fizzbuzz</div>' } },
26
+ { path: '/foo', component: { template: '<div>Foo</div>' } },
27
+ ],
28
+ })
27
29
 
28
30
  mountFunction = (options = {}) => {
29
31
  return mount(VBtn, {
30
- // localVue,
31
- // router,
32
+ global: {
33
+ plugins: [router],
34
+ components: {
35
+ 'router-link': Vue3RouterLinkStub,
36
+ },
37
+ ...options.global,
38
+ },
32
39
  ...options,
33
40
  })
34
41
  }
@@ -39,248 +46,256 @@ describe('VBtn.ts', () => { // eslint-disable-line max-statements
39
46
  })
40
47
 
41
48
  it('should render component with color prop and match snapshot', () => {
42
- expect(mountFunction({
49
+ expect(
50
+ mountFunction({
51
+ props: {
52
+ color: 'green darken-1',
53
+ },
54
+ }).html()
55
+ ).toMatchSnapshot()
56
+
57
+ expect(
58
+ mountFunction({
59
+ props: {
60
+ color: 'green darken-1',
61
+ text: true,
62
+ },
63
+ }).html()
64
+ ).toMatchSnapshot()
65
+ })
66
+
67
+ it('should render component with loader slot and match snapshot', () => {
68
+ const wrapper = mountFunction({
43
69
  props: {
44
- color: 'green darken-1',
70
+ loading: true,
45
71
  },
46
- }).html()).toMatchSnapshot()
72
+ slots: {
73
+ loader: '<span>loader</span>',
74
+ },
75
+ })
47
76
 
48
- expect(mountFunction({
77
+ expect(wrapper.html()).toMatchSnapshot()
78
+ })
79
+
80
+ it('should register and unregister', () => {
81
+ const register = jest.fn()
82
+ const unregister = jest.fn()
83
+
84
+ const wrapper = mountFunction({
85
+ global: {
86
+ provide: {
87
+ btnToggle: {
88
+ register,
89
+ unregister,
90
+ },
91
+ },
92
+ },
93
+ })
94
+
95
+ expect(register).toHaveBeenCalled()
96
+ wrapper.unmount()
97
+ expect(unregister).toHaveBeenCalled()
98
+ })
99
+ it('should use custom active-class', () => {
100
+ const wrapper = mountFunction({
49
101
  props: {
50
- color: 'green darken-1',
51
- text: true,
102
+ inputValue: true,
103
+ activeClass: 'foo',
52
104
  },
53
- }).html()).toMatchSnapshot()
105
+ })
106
+
107
+ expect(wrapper.classes('foo')).toBe(true)
54
108
  })
55
109
 
56
- it('should render component with loader slot and match snapshot', () => {
110
+ it('should have v-btn--plain class when plain prop is set to true', () => {
57
111
  const wrapper = mountFunction({
58
112
  props: {
59
- loading: true
113
+ plain: true,
60
114
  },
61
- slots: {
62
- loader: [{template: '<span>loader</span>' }],
115
+ })
116
+
117
+ expect(wrapper.classes('v-btn--plain')).toBe(true)
118
+ })
119
+
120
+ it('should have the correct icon classes', async () => {
121
+ const wrapper = mountFunction({
122
+ props: {
123
+ icon: true,
124
+ },
125
+ })
126
+ expect(wrapper.classes('v-btn--icon')).toBe(true)
127
+
128
+ await wrapper.setProps({ icon: false })
129
+
130
+ expect(wrapper.classes('v-btn--icon')).toBe(false)
131
+ })
132
+
133
+ it('should have the correct elevation', async () => {
134
+ // eslint-disable-line max-statements
135
+ const wrapper = mountFunction()
136
+
137
+ await wrapper.setProps({ disabled: true })
138
+ expect(wrapper.classes('elevation-2')).toBe(false)
139
+ expect(wrapper.classes('v-btn--disabled')).toBe(true)
140
+
141
+ await wrapper.setProps({ disabled: false, elevation: 24 })
142
+ expect(wrapper.classes('elevation-24')).toBe(true)
143
+
144
+ await wrapper.setProps({ elevation: 2 })
145
+ expect(wrapper.classes('elevation-2')).toBe(true)
146
+ })
147
+
148
+ it('should stringify non string|number values', async () => {
149
+ const wrapper = mountFunction({
150
+ props: {
151
+ value: 'foo',
152
+ },
153
+ })
154
+
155
+ expect(wrapper.attributes('value')).toBe('foo')
156
+
157
+ await wrapper.setProps({ value: 2 })
158
+ expect(wrapper.attributes('value')).toBe('2')
159
+
160
+ await wrapper.setProps({ value: { foo: 'bar' } })
161
+ expect(wrapper.attributes('value')).toBe('{"foo":"bar"}')
162
+ })
163
+
164
+ it('should not add color classes if disabled', async () => {
165
+ const wrapper = mountFunction({
166
+ props: {
167
+ color: 'primary darken-2',
63
168
  },
64
169
  })
65
170
 
66
171
  expect(wrapper.html()).toMatchSnapshot()
172
+
173
+ await wrapper.setProps({
174
+ disabled: true,
175
+ })
176
+ expect(wrapper.html()).toMatchSnapshot()
67
177
  })
68
178
 
69
- it('should render component with loader and match snapshot', () => {
179
+ it('should retain focus when clicked', async () => {
180
+ const wrapper = mountFunction({
181
+ props: {
182
+ retainFocusOnClick: true,
183
+ },
184
+ })
185
+ const event = new MouseEvent('click', { detail: 1 })
186
+ const blur = jest.fn()
187
+
188
+ wrapper.element.blur = blur
189
+ wrapper.element.dispatchEvent(event)
190
+
191
+ expect(blur).not.toHaveBeenCalled()
192
+
193
+ await wrapper.setProps({ retainFocusOnClick: false })
194
+ wrapper.element.dispatchEvent(event)
195
+
196
+ expect(blur).toHaveBeenCalled()
197
+ })
198
+
199
+ // Test attributes inheritance and merging
200
+ it('should handle attributes inheritance correctly', () => {
70
201
  const wrapper = mount(VBtn, {
202
+ global: {
203
+ plugins: [router],
204
+ },
205
+ attrs: {
206
+ 'data-test': 'my-button',
207
+ 'aria-label': 'Test button',
208
+ id: 'custom-id',
209
+ class: 'custom-class another-class',
210
+ },
211
+ props: {
212
+ color: 'primary',
213
+ },
214
+ })
215
+
216
+ // Check that component receives attrs
217
+ expect(wrapper.vm.$attrs['data-test']).toBe('my-button')
218
+ expect(wrapper.vm.$attrs['aria-label']).toBe('Test button')
219
+ expect(wrapper.vm.$attrs.id).toBe('custom-id')
220
+
221
+ // Check class merging
222
+ expect(wrapper.classes()).toContain('custom-class')
223
+ expect(wrapper.classes()).toContain('another-class')
224
+ expect(wrapper.classes()).toContain('v-btn')
225
+ })
226
+
227
+ it('should render loader when loading prop is true', () => {
228
+ const wrapper = mountFunction({
71
229
  props: {
72
230
  loading: true,
73
231
  },
74
232
  })
75
233
 
76
- expect(wrapper.html()).toMatchSnapshot()
234
+ expect(wrapper.classes('v-btn--loading')).toBe(true)
235
+ expect(wrapper.find('.v-btn__loader').exists()).toBe(true)
236
+ })
237
+ it('should compute button states and classes correctly', () => {
238
+ // Test multiple button variants and their classes
239
+ const variants = [
240
+ { props: {}, classes: ['v-btn'], hasBg: true, isElevated: true, isRound: false },
241
+ { props: { text: true }, classes: ['v-btn--text'], hasBg: false, isElevated: false, isRound: false },
242
+ { props: { plain: true }, classes: ['v-btn--plain'], hasBg: false, isElevated: false, isRound: false },
243
+ { props: { outlined: true }, classes: ['v-btn--outlined'], hasBg: false, isElevated: false, isRound: false },
244
+ { props: { icon: true }, classes: ['v-btn--icon'], hasBg: false, isElevated: false, isRound: true },
245
+ { props: { fab: true }, classes: ['v-btn--fab'], hasBg: true, isElevated: true, isRound: true },
246
+ { props: { block: true }, classes: ['v-btn--block'], hasBg: true, isElevated: true, isRound: false },
247
+ { props: { rounded: true }, classes: ['v-btn--rounded'], hasBg: true, isElevated: true, isRound: false },
248
+ { props: { disabled: true }, classes: ['v-btn--disabled'], hasBg: true, isElevated: false, isRound: false },
249
+ ]
250
+
251
+ variants.forEach(({ props, classes, hasBg, isElevated, isRound }) => {
252
+ const wrapper = mountFunction({ props })
253
+
254
+ // Check classes
255
+ classes.forEach(className => {
256
+ expect(wrapper.classes(className)).toBe(true)
257
+ })
258
+
259
+ // Check computed properties
260
+ expect(wrapper.vm.hasBg).toBe(hasBg)
261
+ expect(wrapper.vm.isElevated).toBe(isElevated)
262
+ expect(wrapper.vm.isRound).toBe(isRound)
263
+ })
264
+ })
265
+
266
+ it('should compute ripple correctly', () => {
267
+ // Should have ripple by default
268
+ let wrapper = mountFunction()
269
+ expect(wrapper.vm.computedRipple).toBe(true)
270
+
271
+ // Should not have ripple when disabled
272
+ wrapper = mountFunction({
273
+ props: { disabled: true },
274
+ })
275
+ expect(wrapper.vm.computedRipple).toBe(false)
276
+
277
+ // Should have circle ripple for icon buttons
278
+ wrapper = mountFunction({
279
+ props: { icon: true },
280
+ })
281
+ expect(wrapper.vm.computedRipple).toEqual({ circle: true })
282
+
283
+ // Should have circle ripple for fab buttons
284
+ wrapper = mountFunction({
285
+ props: { fab: true },
286
+ })
287
+ expect(wrapper.vm.computedRipple).toEqual({ circle: true })
77
288
  })
289
+ it('should add router class when to prop is provided', () => {
290
+ const wrapper = mountFunction({
291
+ props: {
292
+ to: '/test-route',
293
+ },
294
+ slots: {
295
+ default: () => 'Router Button',
296
+ },
297
+ })
78
298
 
79
- // it('should render tile button and match snapshot', () => {
80
- // const wrapper = mount(VBtn, {
81
- // propsData: {
82
- // tile: true,
83
- // },
84
- // })
85
-
86
- // expect(wrapper.html()).toMatchSnapshot()
87
- // })
88
-
89
- // it('should render an <a> tag when using href prop', () => {
90
- // const wrapper = mountFunction({
91
- // propsData: {
92
- // href: 'http://www.google.com',
93
- // },
94
- // })
95
-
96
- // expect(wrapper.html()).toMatchSnapshot()
97
- // })
98
-
99
- // it('should render specified tag when using tag prop', () => {
100
- // const wrapper = mountFunction({
101
- // propsData: {
102
- // tag: 'a',
103
- // },
104
- // })
105
-
106
- // expect(wrapper.html()).toMatchSnapshot()
107
- // })
108
-
109
- // it('should register and unregister', () => {
110
- // const register = jest.fn()
111
- // const unregister = jest.fn()
112
-
113
- // const wrapper = mountFunction({
114
- // provide: {
115
- // btnToggle: {
116
- // register,
117
- // unregister,
118
- // },
119
- // },
120
- // })
121
-
122
- // expect(register).toHaveBeenCalled()
123
- // wrapper.destroy()
124
- // expect(unregister).toHaveBeenCalled()
125
- // })
126
-
127
- // it('should emit a click event', async () => {
128
- // const wrapper = mountFunction({
129
- // propsData: {
130
- // href: '#!',
131
- // },
132
- // })
133
-
134
- // const click = jest.fn()
135
- // wrapper.vm.$on('click', click)
136
- // wrapper.trigger('click')
137
-
138
- // wrapper.setProps({ href: undefined, to: '/foo' })
139
- // wrapper.trigger('click')
140
-
141
- // expect(click.mock.calls).toHaveLength(2)
142
- // })
143
-
144
- // it('should use custom active-class', () => {
145
- // const wrapper = mountFunction({
146
- // propsData: {
147
- // inputValue: true,
148
- // activeClass: 'foo',
149
- // },
150
- // })
151
-
152
- // expect(wrapper.classes('foo')).toBe(true)
153
- // })
154
-
155
- // it('should have v-btn--plain class when plain prop is set to true', () => {
156
- // const wrapper = mountFunction({
157
- // propsData: {
158
- // plain: true,
159
- // },
160
- // })
161
-
162
- // expect(wrapper.classes('v-btn--plain')).toBe(true)
163
- // })
164
-
165
- // it('should have the correct icon classes', () => {
166
- // const wrapper = mountFunction({
167
- // propsData: {
168
- // icon: true,
169
- // },
170
- // })
171
- // expect(wrapper.classes('v-btn--icon')).toBe(true)
172
-
173
- // wrapper.setProps({ icon: false })
174
-
175
- // expect(wrapper.classes('v-btn--icon')).toBe(false)
176
- // })
177
-
178
- // it('should have the correct elevation', async () => { // eslint-disable-line max-statements
179
- // const wrapper = mountFunction()
180
-
181
- // wrapper.setProps({ disabled: true })
182
- // expect(wrapper.classes('elevation-2')).toBe(false)
183
- // expect(wrapper.classes('v-btn--disabled')).toBe(true)
184
-
185
- // wrapper.setProps({ disabled: false, elevation: 24 })
186
- // expect(wrapper.classes('elevation-24')).toBe(true)
187
-
188
- // wrapper.setProps({ elevation: 2 })
189
- // expect(wrapper.classes('elevation-2')).toBe(true)
190
- // })
191
-
192
- // it('should toggle on route change if provided a to prop', async () => {
193
- // const toggle = jest.fn()
194
- // const register = jest.fn()
195
- // const unregister = jest.fn()
196
- // const wrapper = mountFunction({
197
- // provide: {
198
- // btnToggle: {
199
- // activeClass: 'foobar',
200
- // register,
201
- // unregister,
202
- // },
203
- // },
204
- // methods: { toggle },
205
- // ref: 'link',
206
- // })
207
-
208
- // router.push('/foobar')
209
-
210
- // await wrapper.vm.$nextTick()
211
- // expect(toggle).not.toHaveBeenCalled()
212
-
213
- // wrapper.setProps({ to: 'fizzbuzz' })
214
-
215
- // router.push('/fizzbuzz')
216
-
217
- // await wrapper.vm.$nextTick()
218
- // expect(toggle).toHaveBeenCalled()
219
- // })
220
-
221
- // it('should call toggle when used in button group', () => {
222
- // const register = jest.fn()
223
- // const unregister = jest.fn()
224
- // const toggle = jest.fn()
225
- // const wrapper = mountFunction({
226
- // provide: {
227
- // btnToggle: { register, unregister },
228
- // },
229
- // methods: { toggle },
230
- // })
231
-
232
- // wrapper.trigger('click')
233
- // expect(toggle).toHaveBeenCalled()
234
- // })
235
-
236
- // it('should stringify non string|number values', () => {
237
- // const wrapper = mountFunction({
238
- // propsData: {
239
- // value: 'foo',
240
- // },
241
- // })
242
-
243
- // expect(wrapper.attributes('value')).toBe('foo')
244
-
245
- // wrapper.setProps({ value: 2 })
246
- // expect(wrapper.attributes('value')).toBe('2')
247
-
248
- // wrapper.setProps({ value: { foo: 'bar' } })
249
- // expect(wrapper.attributes('value')).toBe('{"foo":"bar"}')
250
- // })
251
-
252
- // it('should not add color classes if disabled', () => {
253
- // const wrapper = mountFunction({
254
- // propsData: {
255
- // color: 'primary darken-2',
256
- // },
257
- // })
258
-
259
- // expect(wrapper.html()).toMatchSnapshot()
260
-
261
- // wrapper.setProps({
262
- // disabled: true,
263
- // })
264
- // expect(wrapper.html()).toMatchSnapshot()
265
- // })
266
-
267
- // it('should retain focus when clicked', async () => {
268
- // const wrapper = mountFunction({
269
- // propsData: {
270
- // retainFocusOnClick: true,
271
- // },
272
- // })
273
- // const event = new MouseEvent('click', { detail: 1 })
274
- // const blur = jest.fn()
275
-
276
- // wrapper.element.blur = blur
277
- // wrapper.element.dispatchEvent(event)
278
-
279
- // expect(blur).not.toHaveBeenCalled()
280
-
281
- // wrapper.setProps({ retainFocusOnClick: false })
282
- // wrapper.element.dispatchEvent(event)
283
-
284
- // expect(blur).toHaveBeenCalled()
285
- // })
299
+ expect(wrapper.classes('v-btn--router')).toBe(true)
300
+ })
286
301
  })
@@ -1,8 +1,8 @@
1
1
  // Jest Snapshot v1, https://goo.gl/fbAQLP
2
2
 
3
3
  exports[`VBtn.ts should not add color classes if disabled 1`] = `
4
- <button type="button"
5
- class="v-btn v-btn--is-elevated v-btn--has-bg theme--light v-size--default primary darken-2"
4
+ <button class="v-btn v-btn--is-elevated v-btn--has-bg theme--light v-size--default primary darken-2"
5
+ type="button"
6
6
  >
7
7
  <span class="v-btn__content">
8
8
  </span>
@@ -10,27 +10,18 @@ exports[`VBtn.ts should not add color classes if disabled 1`] = `
10
10
  `;
11
11
 
12
12
  exports[`VBtn.ts should not add color classes if disabled 2`] = `
13
- <button type="button"
14
- class="v-btn v-btn--disabled v-btn--has-bg theme--light v-size--default"
15
- disabled="disabled"
13
+ <button class="v-btn v-btn--disabled v-btn--has-bg theme--light v-size--default"
14
+ type="button"
15
+ disabled
16
16
  >
17
17
  <span class="v-btn__content">
18
18
  </span>
19
19
  </button>
20
20
  `;
21
21
 
22
- exports[`VBtn.ts should render an <a> tag when using href prop 1`] = `
23
- <a href="http://www.google.com"
24
- class="v-btn v-btn--is-elevated v-btn--has-bg theme--light v-size--default"
25
- >
26
- <span class="v-btn__content">
27
- </span>
28
- </a>
29
- `;
30
-
31
22
  exports[`VBtn.ts should render component and match snapshot 1`] = `
32
- <button type="button"
33
- class="v-btn v-btn--is-elevated v-btn--has-bg theme--light v-size--default"
23
+ <button class="v-btn v-btn--is-elevated v-btn--has-bg theme--light v-size--default"
24
+ type="button"
34
25
  >
35
26
  <span class="v-btn__content">
36
27
  </span>
@@ -38,8 +29,8 @@ exports[`VBtn.ts should render component and match snapshot 1`] = `
38
29
  `;
39
30
 
40
31
  exports[`VBtn.ts should render component with color prop and match snapshot 1`] = `
41
- <button type="button"
42
- class="v-btn v-btn--is-elevated v-btn--has-bg theme--light v-size--default green darken-1"
32
+ <button class="v-btn v-btn--is-elevated v-btn--has-bg theme--light v-size--default green darken-1"
33
+ type="button"
43
34
  >
44
35
  <span class="v-btn__content">
45
36
  </span>
@@ -47,52 +38,17 @@ exports[`VBtn.ts should render component with color prop and match snapshot 1`]
47
38
  `;
48
39
 
49
40
  exports[`VBtn.ts should render component with color prop and match snapshot 2`] = `
50
- <button type="button"
51
- class="v-btn v-btn--text theme--light v-size--default green--text text--darken-1"
41
+ <button class="v-btn v-btn--text theme--light v-size--default green--text text--darken-1"
42
+ type="button"
52
43
  >
53
44
  <span class="v-btn__content">
54
45
  </span>
55
46
  </button>
56
47
  `;
57
48
 
58
- exports[`VBtn.ts should render component with loader and match snapshot 1`] = `
59
- <button type="button"
60
- class="v-btn v-btn--is-elevated v-btn--has-bg v-btn--loading theme--light v-size--default"
61
- >
62
- <span class="v-btn__content">
63
- </span>
64
- <span class="v-btn__loader">
65
- <div role="progressbar"
66
- aria-valuemin="0"
67
- aria-valuemax="100"
68
- class="v-progress-circular v-progress-circular--indeterminate"
69
- style="height: 23px; width: 23px;"
70
- >
71
- <svg xmlns="http://www.w3.org/2000/svg"
72
- viewbox="21.904761904761905 21.904761904761905 43.80952380952381 43.80952380952381"
73
- style="transform: rotate(0deg);"
74
- >
75
- <circle fill="transparent"
76
- cx="43.80952380952381"
77
- cy="43.80952380952381"
78
- r="20"
79
- stroke-width="3.8095238095238093"
80
- stroke-dasharray="125.664"
81
- stroke-dashoffset="125.66370614359172px"
82
- class="v-progress-circular__overlay"
83
- >
84
- </circle>
85
- </svg>
86
- <div class="v-progress-circular__info">
87
- </div>
88
- </div>
89
- </span>
90
- </button>
91
- `;
92
-
93
49
  exports[`VBtn.ts should render component with loader slot and match snapshot 1`] = `
94
- <button type="button"
95
- class="v-btn v-btn--is-elevated v-btn--has-bg v-btn--loading theme--light v-size--default"
50
+ <button class="v-btn v-btn--is-elevated v-btn--has-bg v-btn--loading theme--light v-size--default"
51
+ type="button"
96
52
  >
97
53
  <span class="v-btn__content">
98
54
  </span>
@@ -103,19 +59,3 @@ exports[`VBtn.ts should render component with loader slot and match snapshot 1`]
103
59
  </span>
104
60
  </button>
105
61
  `;
106
-
107
- exports[`VBtn.ts should render specified tag when using tag prop 1`] = `
108
- <a class="v-btn v-btn--is-elevated v-btn--has-bg theme--light v-size--default">
109
- <span class="v-btn__content">
110
- </span>
111
- </a>
112
- `;
113
-
114
- exports[`VBtn.ts should render tile button and match snapshot 1`] = `
115
- <button type="button"
116
- class="v-btn v-btn--is-elevated v-btn--has-bg v-btn--tile theme--light v-size--default"
117
- >
118
- <span class="v-btn__content">
119
- </span>
120
- </button>
121
- `;