prettier

parent 633ce4f6
......@@ -9,7 +9,7 @@
:color="getColor"
no-caps
flat
:class="{active: activeFilter==='All'}"
:class="{ active: activeFilter === 'All' }"
@click="setFilter('All')"
label="All"
/>
......@@ -18,10 +18,10 @@
<q-btn
:color="getColor"
:key="i"
v-for="(t,i) in types"
v-for="(t, i) in types"
no-caps
flat
:class="{active: activeFilter===t}"
:class="{ active: activeFilter === t }"
@click="setFilter(t)"
:label="t"
/>
......@@ -30,10 +30,10 @@
</section>
</template>
<script>
import getColor from "../mixins/getColor.mixin.js"
import getColor from '../mixins/getColor.mixin.js';
export default {
name: "HiFilter",
name: 'HiFilter',
mixins: [getColor],
props: {
types: {
......@@ -44,25 +44,25 @@ export default {
methods: {
reset_animation() {
var el = document.getElementsByClassName("animated")
var el = document.getElementsByClassName('animated');
for (let x of el) {
x.style.animation = "none"
x.offsetHeight /* trigger reflow */
x.style.animation = null
x.style.animation = 'none';
x.offsetHeight; /* trigger reflow */
x.style.animation = null;
}
},
setFilter(a) {
this.activeFilter = a
this.$emit("setFilter", a)
this.reset_animation()
this.activeFilter = a;
this.$emit('setFilter', a);
this.reset_animation();
}
},
data() {
return {
activeFilter: "All"
}
activeFilter: 'All'
};
}
}
};
</script>
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment