: rotating_light: Lint

This commit is contained in:
Liyas Thomas
2019-10-25 13:44:34 +05:30
parent 96adfa0b5a
commit a09d7d76d3
35 changed files with 3133 additions and 2620 deletions

View File

@@ -1,6 +1,11 @@
<template>
<fieldset :id="label.toLowerCase()" :class="{ 'no-colored-frames': noFrameColors }">
<legend @click.prevent="collapse"><i class="material-icons icon">{{ icon }}</i><span>{{ label }}</span><i class="material-icons" v-if="isCollapsed">expand_more</i><i class="material-icons" v-if="!isCollapsed">expand_less</i></legend>
<legend @click.prevent="collapse">
<i class="material-icons icon">{{ icon }}</i>
<span>{{ label }}</span>
<i class="material-icons" v-if="isCollapsed">expand_more</i>
<i class="material-icons" v-if="!isCollapsed">expand_less</i>
</legend>
<div class="collapsible" :class="{ hidden: collapsed }">
<slot />
</div>
@@ -17,39 +22,39 @@
</style>
<script>
export default {
computed: {
noFrameColors() {
return this.$store.state.postwoman.settings.DISABLE_FRAME_COLORS || false;
export default {
computed: {
noFrameColors() {
return this.$store.state.postwoman.settings.DISABLE_FRAME_COLORS || false;
}
},
},
data() {
return {
isCollapsed: false
}
},
props: {
label: {
type: String,
default: "Section"
data() {
return {
isCollapsed: false
};
},
icon: {
type: String,
default: "lens"
},
collapsed: {
type: Boolean
}
},
methods: {
collapse({ target }) {
const parent = target.parentNode.parentNode;
parent.querySelector(".collapsible").classList.toggle("hidden");
this.isCollapsed = !this.isCollapsed;
props: {
label: {
type: String,
default: "Section"
},
icon: {
type: String,
default: "lens"
},
collapsed: {
type: Boolean
}
},
methods: {
collapse({ target }) {
const parent = target.parentNode.parentNode;
parent.querySelector(".collapsible").classList.toggle("hidden");
this.isCollapsed = !this.isCollapsed;
}
}
}
};
};
</script>