ES Lint fix migration to vuetify 2

This commit is contained in:
Stefan Zermatten
2021-03-25 10:20:13 +02:00
parent 6ffb48b7b6
commit 480da6fc7d
42 changed files with 88 additions and 106 deletions

View File

@@ -15,7 +15,6 @@
<v-card class="overflow-hidden">
<v-card-text>
<v-layout
row
wrap
>
<div

View File

@@ -1,6 +1,5 @@
<template>
<v-layout
row
align-center
justify-center
class="increment-menu"

View File

@@ -51,7 +51,6 @@
</v-btn>
</div>
<v-layout
row
wrap
style="max-height: 400px; overflow-y: auto;"
>

View File

@@ -17,7 +17,7 @@
outline
@click="makeRoll"
>
<div class="display-1">
<div class="text-h4">
{{ numberToSignedString(bonus) }}
</div>
</v-btn>
@@ -26,7 +26,7 @@
</template>
<template v-else>
<div>
<div class="title">
<div class="text-h6">
<span
v-for="(roll, index) of rolls"
:key="index"
@@ -39,7 +39,7 @@
{{ numberToSignedString(bonus) }}
</span>
</div>
<div class="display-1">
<div class="text-h4">
{{ result }}
</div>
</div>

View File

@@ -52,7 +52,6 @@
label="Race"
/>
<v-layout
row
justify-center
align-center
>
@@ -225,7 +224,6 @@
:items="hitDiceItems"
label="Hit Dice"
/>
</v-text-field>
</v-stepper-content>
</v-stepper-items>
</v-stepper>

View File

@@ -11,7 +11,7 @@
v-if="creature.picture"
:src="creature.picture"
/>
<v-card-title class="title">
<v-card-title class="text-h6">
{{ creature.name }}
</v-card-title>
<v-card-text>
@@ -37,7 +37,7 @@
<v-card class="class-details">
<v-card-title
v-if="creature.variables.level"
class="title"
class="text-h6"
>
Level {{ creature.variables.level.value }}
</v-card-title>

View File

@@ -11,7 +11,7 @@
v-if="milestone"
label="Levels"
type="number"
class="base-value-field text-xs-center large-format no-flex"
class="base-value-field text-center large-format no-flex"
:value="model.levels"
:error-messages="errors.levels"
@change="change('levels', ...arguments)"
@@ -19,7 +19,7 @@
<text-field
v-else
type="number"
class="base-value-field text-xs-center large-format no-flex"
class="base-value-field text-center large-format no-flex"
suffix="XP"
autofocus
:value="model.xp"

View File

@@ -11,7 +11,6 @@
</template>
<script lang="js">
import Creatures from '/imports/api/creature/Creatures.js';
import DialogBase from '/imports/ui/dialogStack/DialogBase.vue';
import Slots from '/imports/ui/creature/slots/Slots.vue'

View File

@@ -45,7 +45,7 @@
/>
<v-card-title primary-title>
<tree-node-view
class="mr-2 title mb-0"
class="mr-2 text-h6 mb-0"
:class="{'theme--dark': node._id === (selectedNode && selectedNode._id)}"
:hide-icon="node.picture"
:model="node"

View File

@@ -1,11 +1,11 @@
import store from "/imports/ui/vuexStore.js";
import store from '/imports/ui/vuexStore.js';
if (window){
window.onpopstate = function(event){
let state = event.state;
let numDialogs = store.state.dialogStack.dialogs.length;
if (_.isFinite(state.openDialogs) && numDialogs > state.openDialogs){
store.commit("popDialogStackMutation", store.state.dialogStack.currentResult);
store.commit('popDialogStackMutation', store.state.dialogStack.currentResult);
}
};
}

View File

@@ -17,7 +17,7 @@
:data-id="library._id"
>
<template #header>
<div class="title">
<div class="text-h6">
{{ library.name }}
</div>
</template>

View File

@@ -14,7 +14,6 @@
/>
<v-layout
v-else
row
align-center
justify-center
style="width: 100%;"

View File

@@ -1,11 +1,11 @@
<template lang="html">
<selectable-property-dialog v-model="type">
<library-node-insert-form
:type="type"
:property-name="getPropertyName(type)"
@back="type = undefined"
/>
</selectable-property-dialog>
<selectable-property-dialog v-model="type">
<library-node-insert-form
:type="type"
:property-name="getPropertyName(type)"
@back="type = undefined"
/>
</selectable-property-dialog>
</template>
<script lang="js">
@@ -14,13 +14,13 @@ import LibraryNodeInsertForm from '/imports/ui/library/LibraryNodeInsertForm.vue
import { getPropertyName } from '/imports/constants/PROPERTIES.js';
export default {
data() { return {
type: undefined,
};},
components: {
SelectablePropertyDialog,
LibraryNodeInsertForm,
},
data() { return {
type: undefined,
};},
methods: {
getPropertyName,
},

View File

@@ -12,7 +12,7 @@
class="white--text"
>
<p
class="white--text ma-2 headline text-xs-center"
class="white--text ma-2 text-h5 text-center"
style="max-width: 1200px;"
>
DiceCloud is a single-developer project started in 2014 with the aim of
@@ -25,7 +25,7 @@
</section>
<section class="layout column align-center ma-2 mt-4">
<div>
<h3 class="headline mb-2">
<h3 class="text-h5 mb-2">
Special Thanks
</h3>
<p>
@@ -34,7 +34,7 @@
<b>The "Heroes" of Asaea</b> The D&amp;D party whose joy was the fuel
with which DiceCloud was powered
</p>
<h3 class="title">
<h3 class="text-h6">
Paragon tier Patrons
</h3>
<v-list

View File

@@ -100,7 +100,6 @@
</v-list-item>
</v-list>
<v-layout
row
justify-end
>
<v-btn
@@ -142,7 +141,6 @@
</v-list>
</template>
<v-layout
row
justify-end
class="mt-3"
>

View File

@@ -12,7 +12,7 @@
/>
<v-card-title primary-title>
<div>
<h3 class="headline mb-0">
<h3 class="text-h5 mb-0">
DiceCloud Discord server
</h3>
<div>

View File

@@ -48,7 +48,7 @@
<div class="error--text">
{{ error }}
</div>
<v-layout row>
<v-layout>
<v-btn
:disabled="!valid"
color="accent"

View File

@@ -35,7 +35,7 @@
<div class="error--text">
{{ error }}
</div>
<v-layout row>
<v-layout>
<v-btn
:disabled="!valid"
color="accent"

View File

@@ -4,7 +4,7 @@
v-on="hasClickListener ? {click} : {}"
>
<v-list-item-action class="mr-4">
<div class="display-1 mod">
<div class="text-h4 mod">
<template v-if="swapScoresAndMods">
<span :class="{'primary--text': model.currentValue !== model.value}">
{{ model.currentValue }}
@@ -14,7 +14,7 @@
{{ numberToSignedString(model.modifier) }}
</template>
</div>
<div class="title value">
<div class="text-h6 value">
<template v-if="swapScoresAndMods">
{{ numberToSignedString(model.modifier) }}
</template>

View File

@@ -5,7 +5,7 @@
>
<v-card-text>
<div class="layout align-center">
<div class="value display-1 mr-1">
<div class="value text-h4 mr-1">
{{ computedValue }}
</div>
<div class="name text-truncate">

View File

@@ -1,6 +1,5 @@
<template>
<v-layout
row
wrap
align-center
justify-center

View File

@@ -5,9 +5,8 @@
>
<v-list-item-action class="mr-4">
<v-layout
row
align-center
class="left"
class="float-left"
>
<v-layout
column
@@ -33,13 +32,12 @@
</v-layout>
<v-layout
row
align-end
>
<div class="display-1">
<div class="text-h4">
{{ currentValue }}
</div>
<div class="title max-value ml-2">
<div class="text-h6 max-value ml-2">
/{{ model.value }}
</div>
</v-layout>

View File

@@ -24,10 +24,10 @@
<div
class="layout align-center value pl-2 pr-3"
>
<div class="display-1">
<div class="text-h4">
{{ currentValue }}
</div>
<div class="title ml-2 max-value">
<div class="text-h6 ml-2 max-value">
/{{ value }}
</div>
</div>

View File

@@ -7,7 +7,7 @@
:light="model.color && !isDark"
@click="clickProperty(model._id)"
>
<v-card-title class="title">
<v-card-title class="text-h6">
{{ model.name }}
</v-card-title>
<v-card-text v-if="model.summary">

View File

@@ -70,7 +70,7 @@
<template slot="left">
<div
key="slot-title"
class="title my-3"
class="text-h6 my-3"
>
Slot
</div>
@@ -82,7 +82,7 @@
@click="selectedSlotId = undefined"
>
<v-list-item-content>
<v-list-item-title class="title">
<v-list-item-title class="text-h6">
Cantrip
</v-list-item-title>
</v-list-item-content>
@@ -99,7 +99,7 @@
<template slot="right">
<div
key="spell-title"
class="title my-3"
class="text-h6 my-3"
>
Spell
</div>

View File

@@ -91,7 +91,7 @@
<text-field
label="Damage"
type="number"
class="damage-field text-xs-center"
class="damage-field text-center"
style="max-width: 300px;"
hint="The attribute's final value is reduced by this amount"
disabled

View File

@@ -4,7 +4,7 @@
<text-field
label="Level"
type="number"
class="base-value-field text-xs-center large-format no-flex"
class="base-value-field text-center large-format no-flex"
:value="model.level"
:error-messages="errors.level"
@change="change('level', ...arguments)"
@@ -36,7 +36,7 @@
@change="change('description', ...arguments)"
/>
<calculation-error-list :calculations="model.descriptionCalculations" />
<text-field
label="Condition"
hint="A caclulation to determine if this can be added to the character"

View File

@@ -1,5 +1,7 @@
<template lang="html">
<v-icon v-if="value !== undefined">{{displayedIcon}}</v-icon>
<v-icon v-if="value !== undefined">
{{ displayedIcon }}
</v-icon>
</template>
<script lang="js">

View File

@@ -6,7 +6,6 @@
fill-height
>
<v-layout
row
wrap
fill-height
>

View File

@@ -17,7 +17,7 @@
<span>{{ tooltip }}</span>
</v-tooltip>
</v-list-item-avatar>
<v-list-item-action class="headline">
<v-list-item-action class="text-h5">
{{ displayedValue }}
</v-list-item-action>
<v-list-item-content>

View File

@@ -6,7 +6,7 @@
>
<div
v-if="model.value !== undefined"
class="display-1"
class="text-h4"
>
<div
v-if="model.damage !== undefined"
@@ -19,7 +19,7 @@
</div>
<div
v-if="model.modifier !== undefined"
class="title"
class="text-h6"
>
{{ numberToSignedString(model.modifier) }}
</div>

View File

@@ -1,7 +1,7 @@
<template lang="html">
<div class="class-level-viewer">
<div>
<span class="name headline">
<span class="name text-h5">
{{ model.name }} {{ model.level }}
</span>
</div>

View File

@@ -7,7 +7,6 @@
>
<v-layout
v-if="model.value !== undefined"
row
align-center
class="mb-2"
>
@@ -18,12 +17,11 @@
$vuetify.icons.two_coins
</v-icon>
<coin-value
class="title mr-2"
class="text-h6 mr-2"
:value="model.value"
/>
</v-layout>
<v-layout
row
align-center
>
<v-icon
@@ -33,10 +31,10 @@
$vuetify.icons.cash
</v-icon>
<coin-value
class="title mr-2"
class="text-h6 mr-2"
:value="model.contentsValue"
/>
<span class="title">
<span class="text-h6">
contents
</span>
</v-layout>
@@ -46,12 +44,11 @@
>
<v-layout
v-if="model.weight !== undefined"
row
align-center
justify-end
class="mb-2"
>
<span class="title mr-2">
<span class="text-h6 mr-2">
{{ model.weight }} lb
</span>
<v-icon
@@ -62,16 +59,15 @@
</v-icon>
</v-layout>
<v-layout
row
align-center
justify-end
:class="{'mb-2': model.contentsWeightless}"
>
<span class="title mr-2">
<span class="text-h6 mr-2">
{{ model.contentsWeight }} lb
</span>
<span
class="title"
class="text-h6"
>
contents
</span>
@@ -84,12 +80,11 @@
</v-layout>
<v-layout
v-if="model.contentsWeightless"
row
align-center
justify-end
>
<span
class="title"
class="text-h6"
>
Contents weightless
</span>

View File

@@ -16,7 +16,7 @@
</v-list-item-avatar>
<v-list-item-action
v-if="showValue"
class="headline"
class="text-h5"
>
{{ displayedValue }}
</v-list-item-action>

View File

@@ -5,7 +5,7 @@
v-if="model.quantity > 1 || model.showIncrement"
class="layout justify-center align-center wrap"
>
<div class="display-1">
<div class="text-h4">
{{ model.quantity }}
</div>
<increment-button
@@ -27,7 +27,6 @@
>
<v-layout
v-if="model.quantity > 1"
row
align-center
class="mb-2"
>
@@ -38,12 +37,11 @@
$vuetify.icons.cash
</v-icon>
<coin-value
class="title"
class="text-h6"
:value="totalValue"
/>
</v-layout>
<v-layout
row
align-center
>
<v-icon
@@ -53,12 +51,12 @@
$vuetify.icons.two_coins
</v-icon>
<coin-value
class="title mr-2"
class="text-h6 mr-2"
:value="model.value"
/>
<span
v-if="model.quantity > 1"
class="title"
class="text-h6"
>
each
</span>
@@ -70,12 +68,11 @@
>
<v-layout
v-if="model.quantity > 1"
row
align-center
justify-end
class="mb-2"
>
<span class="title">
<span class="text-h6">
{{ totalWeight }} lb
</span>
<v-icon
@@ -86,17 +83,16 @@
</v-icon>
</v-layout>
<v-layout
row
align-center
justify-end
:class="{'mb-2': model.attuned}"
>
<span class="title mr-2">
<span class="text-h6 mr-2">
{{ model.weight }} lb
</span>
<span
v-if="model.quantity > 1"
class="title"
class="text-h6"
>
each
</span>
@@ -109,11 +105,10 @@
</v-layout>
<v-layout
v-if="model.attuned"
row
align-center
justify-end
>
<span class="title">
<span class="text-h6">
Attuned
</span>
<v-icon

View File

@@ -1,6 +1,6 @@
<template lang="html">
<div class="proficiency-viewer">
<div class="headline layout row">
<div class="text-h5 layout row">
{{ model.skill }}
<proficiency-icon
:value="model.value"

View File

@@ -6,7 +6,7 @@
>
<div
v-if="model.value !== undefined"
class="display-1 layout row align-center"
class="text-h4 layout row align-center"
>
<v-icon class="mr-4">
{{ icon }}

View File

@@ -19,7 +19,7 @@
:value="model.slotConditionResult"
/>
<template v-if="model.tags.length">
<div class="caption">
<div class="text-caption">
Tags
</div>
<property-tags :tags="model.tags" />

View File

@@ -1,6 +1,6 @@
<template lang="html">
<div v-if="value !== undefined || $slots.default">
<div class="caption">
<div class="text-caption">
{{ name }}
</div>
<p class="ml-2 subheading">

View File

@@ -1,7 +1,7 @@
<template lang="html">
<div class="name headline mb-2">
{{value}}
</div>
<div class="name text-h5 mb-2">
{{ value }}
</div>
</template>
<script lang="js">

View File

@@ -1,7 +1,10 @@
<template lang="html">
<div v-if="value" class="mb-3">
<code>{{value}}</code>
</div>
<div
v-if="value"
class="mb-3"
>
<code>{{ value }}</code>
</div>
</template>
<script lang="js">

View File

@@ -1,14 +1,14 @@
const INDEX = {
"base": 1,
"add": 2,
"mul": 3,
"min": 4,
"max": 5,
"advantage": 6,
"disadvantage": 7,
"passiveAdd": 8,
"fail": 9,
"conditional": 10,
'base': 1,
'add': 2,
'mul': 3,
'min': 4,
'max': 5,
'advantage': 6,
'disadvantage': 7,
'passiveAdd': 8,
'fail': 9,
'conditional': 10,
};
function sortEffects(effects){