Skip to content

Commit 1d791b5

Browse files
committed
ESLint: enforce html indentation
1 parent 23d0092 commit 1d791b5

File tree

9 files changed

+175
-168
lines changed

9 files changed

+175
-168
lines changed

.eslintrc.cjs

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,13 @@ module.exports = {
4646
'error',
4747
commaDangle,
4848
],
49+
'vue/html-indent': [
50+
'error',
51+
2,
52+
{
53+
alignAttributesVertically: false,
54+
},
55+
],
4956
'no-console': [
5057
'error',
5158
{

src/components/cylc/GraphSubgraph.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
3131
stroke-width="8px"
3232
stroke="grey"
3333
stroke-dasharray="50 50"
34-
/>
34+
/>
3535
<text
3636
:x="labelXPosition"
3737
:y="labelYPosition"

src/components/cylc/Mutation.vue

Lines changed: 99 additions & 99 deletions
Original file line numberDiff line numberDiff line change
@@ -16,111 +16,111 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
1616
-->
1717

1818
<template>
19-
<v-card>
20-
<!-- the mutation title -->
21-
<v-card-title class="py-3">
22-
{{ mutation._title }}
23-
</v-card-title>
24-
<v-card-text class="card-text py-0 px-4">
25-
<!-- the mutation description -->
26-
<v-expansion-panels
27-
v-bind="extendedDescription ? { hover: true } : { readonly: true }"
19+
<v-card>
20+
<!-- the mutation title -->
21+
<v-card-title class="py-3">
22+
{{ mutation._title }}
23+
</v-card-title>
24+
<v-card-text class="card-text py-0 px-4">
25+
<!-- the mutation description -->
26+
<v-expansion-panels
27+
v-bind="extendedDescription ? { hover: true } : { readonly: true }"
28+
>
29+
<v-expansion-panel
30+
class="mutation-desc"
31+
elevation="0"
2832
>
29-
<v-expansion-panel
30-
class="mutation-desc"
31-
elevation="0"
33+
<v-expansion-panel-title
34+
v-bind="extendedDescription ? {} : {
35+
expandIcon: null,
36+
style: {
37+
cursor: 'default',
38+
},
39+
}"
3240
>
33-
<v-expansion-panel-title
34-
v-bind="extendedDescription ? {} : {
35-
expandIcon: null,
36-
style: {
37-
cursor: 'default',
38-
},
39-
}"
40-
>
41-
<Markdown :markdown="shortDescription"/>
42-
</v-expansion-panel-title>
43-
<v-expansion-panel-text v-if="extendedDescription">
44-
<Markdown :markdown="extendedDescription"/>
45-
</v-expansion-panel-text>
46-
</v-expansion-panel>
47-
</v-expansion-panels>
48-
<v-divider />
49-
<EditRuntimeForm
50-
v-if="mutation.name === 'editRuntime'"
51-
v-bind="{
52-
cylcObject,
53-
types,
54-
}"
55-
ref="form"
56-
v-model="isValid"
57-
/>
58-
<FormGenerator
59-
v-else
60-
v-bind="{
61-
mutation,
62-
types,
63-
initialData,
64-
}"
65-
ref="form"
66-
v-model="isValid"
67-
/>
68-
</v-card-text>
69-
<v-card-actions class="pa-3">
70-
<v-spacer></v-spacer>
71-
<v-btn
72-
color="grey"
73-
@click="close()"
74-
variant="text"
75-
data-cy="cancel"
76-
>
77-
Cancel
78-
</v-btn>
79-
<v-btn
80-
color="orange"
81-
@click="$refs.form.reset()"
82-
variant="text"
83-
data-cy="reset"
41+
<Markdown :markdown="shortDescription"/>
42+
</v-expansion-panel-title>
43+
<v-expansion-panel-text v-if="extendedDescription">
44+
<Markdown :markdown="extendedDescription"/>
45+
</v-expansion-panel-text>
46+
</v-expansion-panel>
47+
</v-expansion-panels>
48+
<v-divider />
49+
<EditRuntimeForm
50+
v-if="mutation.name === 'editRuntime'"
51+
v-bind="{
52+
cylcObject,
53+
types,
54+
}"
55+
ref="form"
56+
v-model="isValid"
57+
/>
58+
<FormGenerator
59+
v-else
60+
v-bind="{
61+
mutation,
62+
types,
63+
initialData,
64+
}"
65+
ref="form"
66+
v-model="isValid"
67+
/>
68+
</v-card-text>
69+
<v-card-actions class="pa-3">
70+
<v-spacer></v-spacer>
71+
<v-btn
72+
color="grey"
73+
@click="close()"
74+
variant="text"
75+
data-cy="cancel"
76+
>
77+
Cancel
78+
</v-btn>
79+
<v-btn
80+
color="orange"
81+
@click="$refs.form.reset()"
82+
variant="text"
83+
data-cy="reset"
84+
>
85+
Reset
86+
</v-btn>
87+
<v-btn
88+
variant="text"
89+
:color="isValid ? 'primary' : 'error'"
90+
@click="submit"
91+
:loading="submitting"
92+
data-cy="submit"
93+
>
94+
Submit
95+
<v-tooltip
96+
location="top"
97+
content-class="bg-error"
98+
:disabled="isValid"
8499
>
85-
Reset
86-
</v-btn>
100+
<span>Form contains invalid or missing values!</span>
101+
</v-tooltip>
102+
</v-btn>
103+
</v-card-actions>
104+
<v-snackbar
105+
v-model="showWarning"
106+
timeout="4e3"
107+
color="amber-accent-2"
108+
data-cy="warning-snack"
109+
>
110+
{{ warningMsg }}
111+
<template v-slot:actions>
87112
<v-btn
88-
variant="text"
89-
:color="isValid ? 'primary' : 'error'"
90-
@click="submit"
91-
:loading="submitting"
92-
data-cy="submit"
113+
@click="showWarning = false"
114+
icon
115+
data-cy="snack-close"
93116
>
94-
Submit
95-
<v-tooltip
96-
location="top"
97-
content-class="bg-error"
98-
:disabled="isValid"
99-
>
100-
<span>Form contains invalid or missing values!</span>
101-
</v-tooltip>
117+
<v-icon>
118+
{{ $options.icons.close }}
119+
</v-icon>
102120
</v-btn>
103-
</v-card-actions>
104-
<v-snackbar
105-
v-model="showWarning"
106-
timeout="4e3"
107-
color="amber-accent-2"
108-
data-cy="warning-snack"
109-
>
110-
{{ warningMsg }}
111-
<template v-slot:actions>
112-
<v-btn
113-
@click="showWarning = false"
114-
icon
115-
data-cy="snack-close"
116-
>
117-
<v-icon>
118-
{{ $options.icons.close }}
119-
</v-icon>
120-
</v-btn>
121-
</template>
122-
</v-snackbar>
123-
</v-card>
121+
</template>
122+
</v-snackbar>
123+
</v-card>
124124
</template>
125125

126126
<script>

src/components/cylc/analysis/TimeSeries.vue

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
7171
:height="450"
7272
width="95%"
7373
class="d-flex justify-center"
74-
/>
74+
/>
7575
</div>
7676
<div id="miniTimeSeries">
7777
<VueApexCharts
@@ -84,7 +84,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
8484
class="d-flex justify-center"
8585
/>
8686
</div>
87-
</template>
87+
</template>
8888

8989
<script>
9090
import VueApexCharts from 'vue3-apexcharts'

src/components/cylc/tree/TreeItem.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
5454
v-if="node.familyTree?.length"
5555
:key="node.id"
5656
:task="node.familyTree[0].node"
57-
/>
57+
/>
5858
<span class="mx-1">{{ node.name }}</span>
5959
</template>
6060
<template v-else-if="node.type === 'family'">

src/components/graphqlFormGenerator/FormGenerator.vue

Lines changed: 23 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -26,29 +26,29 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
2626
v-for="input in inputs"
2727
v-bind:key="input.label"
2828
>
29-
<v-list-item-title class="d-flex align-center mb-2">
30-
<!-- input label - the display title for this input -->
31-
{{ upperFirst(lowerCase(input.label)) }}
32-
<!-- help button - tooltip for more information -->
33-
<v-tooltip
34-
v-if="input.description"
35-
:activator="null"
36-
>
37-
<template v-slot:activator="{ props }">
38-
<v-icon v-bind="props" class="mx-2">
39-
{{ $options.icons.mdiHelpCircleOutline }}
40-
</v-icon>
41-
</template>
42-
<Markdown
43-
:markdown="input.description"
44-
/>
45-
</v-tooltip>
46-
</v-list-item-title>
47-
<FormInput
48-
v-model="model[input.label]"
49-
:gqlType="input.gqlType"
50-
:types="types"
51-
/>
29+
<v-list-item-title class="d-flex align-center mb-2">
30+
<!-- input label - the display title for this input -->
31+
{{ upperFirst(lowerCase(input.label)) }}
32+
<!-- help button - tooltip for more information -->
33+
<v-tooltip
34+
v-if="input.description"
35+
:activator="null"
36+
>
37+
<template v-slot:activator="{ props }">
38+
<v-icon v-bind="props" class="mx-2">
39+
{{ $options.icons.mdiHelpCircleOutline }}
40+
</v-icon>
41+
</template>
42+
<Markdown
43+
:markdown="input.description"
44+
/>
45+
</v-tooltip>
46+
</v-list-item-title>
47+
<FormInput
48+
v-model="model[input.label]"
49+
:gqlType="input.gqlType"
50+
:types="types"
51+
/>
5252
</v-list-item>
5353
</v-list>
5454
</v-form>

src/components/graphqlFormGenerator/components/Object.vue

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -19,11 +19,11 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
1919
<v-input>
2020
<template>
2121
<FormInput
22-
v-for="input in inputs"
23-
v-bind:key="input.label"
24-
v-model="model[input.label]"
25-
:gqlType="input.gqlType"
26-
:types="types"
22+
v-for="input in inputs"
23+
v-bind:key="input.label"
24+
v-model="model[input.label]"
25+
:gqlType="input.gqlType"
26+
:types="types"
2727
/>
2828
</template>
2929
<template v-slot:append>

src/views/Dashboard.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -160,7 +160,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
160160
<v-icon size="1.6em">{{ $options.icons.mdiGraphql }}</v-icon>
161161
</template>
162162
<v-list-item-title class="text-h6 font-weight-light">
163-
GraphiQL
163+
GraphiQL
164164
</v-list-item-title>
165165
<v-list-item-subtitle>
166166
Explore the Cylc GraphQL API

0 commit comments

Comments
 (0)