1
1
<template>
2
2
<div class="md-tabs" :class="[tabsClasses, $mdActiveTheme]">
3
-
<div class="md-tabs-navigation" :class="navigationClasses">
3
+
<div class="md-tabs-navigation" :class="navigationClasses" ref="navigation">
4
4
<md-button
5
5
v-for="({ label, props, icon, disabled, data, events }, index) in MdTabs.items"
6
6
:key="index"
75
75
hasContent: false,
76
76
MdTabs: {
77
77
items: {}
78
-
}
78
+
},
79
+
alignmentChanging: false
79
80
}),
80
81
provide () {
81
82
return {
112
113
this.$emit('md-changed', tab)
113
114
},
114
115
async mdAlignment () {
116
+
if (this.alignmentChanging) {
117
+
return false
118
+
}
119
+
120
+
this.alignmentChanging = true
115
121
await this.$nextTick()
116
-
this.setIndicatorStyles()
122
+
123
+
let cb = event => {
124
+
if (event.propertyName !== 'min-width') {
125
+
return false
126
+
}
127
+
128
+
this.$refs.navigation.removeEventListener('transitionend', cb)
129
+
this.setIndicatorStyles()
130
+
this.alignmentChanging = false
131
+
}
132
+
133
+
this.$refs.navigation.addEventListener('transitionend', cb)
117
134
}
118
135
},
119
136
methods: {
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4