[cleanup] cleanup style
This commit is contained in:
parent
951fafd1fa
commit
023127f8be
10
.eslintrc.js
10
.eslintrc.js
|
@ -17,11 +17,11 @@ module.exports = {
|
||||||
project: resolve(__dirname, './tsconfig.json'),
|
project: resolve(__dirname, './tsconfig.json'),
|
||||||
tsconfigRootDir: __dirname,
|
tsconfigRootDir: __dirname,
|
||||||
ecmaVersion: 2019, // Allows for the parsing of modern ECMAScript features
|
ecmaVersion: 2019, // Allows for the parsing of modern ECMAScript features
|
||||||
sourceType: 'module' // Allows for the use of imports
|
sourceType: 'module', // Allows for the use of imports
|
||||||
},
|
},
|
||||||
|
|
||||||
env: {
|
env: {
|
||||||
browser: true
|
browser: true,
|
||||||
},
|
},
|
||||||
|
|
||||||
// Rules order is important, please avoid shuffling them
|
// Rules order is important, please avoid shuffling them
|
||||||
|
@ -70,6 +70,6 @@ module.exports = {
|
||||||
'@typescript-eslint/explicit-module-boundary-types': 'off',
|
'@typescript-eslint/explicit-module-boundary-types': 'off',
|
||||||
|
|
||||||
// allow debugger during development only
|
// allow debugger during development only
|
||||||
'no-debugger': process.env.NODE_ENV === 'production' ? 'error' : 'off'
|
'no-debugger': process.env.NODE_ENV === 'production' ? 'error' : 'off',
|
||||||
}
|
},
|
||||||
}
|
};
|
||||||
|
|
|
@ -15,7 +15,7 @@
|
||||||
"main": "src/index.ts",
|
"main": "src/index.ts",
|
||||||
"types": "src/api.d.ts",
|
"types": "src/api.d.ts",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"format": "prettier --config ./package.json --write '{,!(node_modules)/**/}*.ts'",
|
"format": "prettier --config ./package.json --write '{,!(node_modules)/**/}*.{ts,vue,js}'",
|
||||||
"lint": "eslint --ext .js,.ts,.vue ./src"
|
"lint": "eslint --ext .js,.ts,.vue ./src"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
|
@ -42,7 +42,7 @@
|
||||||
"prettier": {
|
"prettier": {
|
||||||
"singleQuote": true,
|
"singleQuote": true,
|
||||||
"semi": true,
|
"semi": true,
|
||||||
"printWidth": 120,
|
"printWidth": 100,
|
||||||
"arrowParens": "always"
|
"arrowParens": "always"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -55,7 +55,7 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<template #error>
|
<template #error>
|
||||||
<q-img class="bg-white" style="max-height: 256px" src='no-image.svg' />
|
<q-img class="bg-white" style="max-height: 256px" src="no-image.svg" />
|
||||||
<div
|
<div
|
||||||
v-if="!public && !nodetails && editable"
|
v-if="!public && !nodetails && editable"
|
||||||
class="absolute-top-right justify-end"
|
class="absolute-top-right justify-end"
|
||||||
|
@ -495,7 +495,7 @@ export default defineComponent({
|
||||||
|
|
||||||
function image(uuid: string | undefined) {
|
function image(uuid: string | undefined) {
|
||||||
if (uuid) {
|
if (uuid) {
|
||||||
return `${api.defaults.baseURL||''}/pricelist/picture/${uuid}?size=256`;
|
return `${api.defaults.baseURL || ''}/pricelist/picture/${uuid}?size=256`;
|
||||||
}
|
}
|
||||||
return 'no-image.svg';
|
return 'no-image.svg';
|
||||||
}
|
}
|
||||||
|
|
|
@ -27,7 +27,7 @@
|
||||||
options-cover
|
options-cover
|
||||||
/>
|
/>
|
||||||
<q-btn round icon="mdi-backburger">
|
<q-btn round icon="mdi-backburger">
|
||||||
<q-tooltip anchor='top middle' self='bottom middle'> Reihenfolge ändern </q-tooltip>
|
<q-tooltip anchor="top middle" self="bottom middle"> Reihenfolge ändern </q-tooltip>
|
||||||
<q-menu anchor="bottom middle" self="top middle">
|
<q-menu anchor="bottom middle" self="top middle">
|
||||||
<drag v-model="order" class="q-list" ghost-class="ghost" group="people" item-key="id">
|
<drag v-model="order" class="q-list" ghost-class="ghost" group="people" item-key="id">
|
||||||
<template #item="{ element }">
|
<template #item="{ element }">
|
||||||
|
|
|
@ -157,7 +157,7 @@ export default defineComponent({
|
||||||
const search_keys = computed(() => columns_drinks.filter((column) => column.filterable));
|
const search_keys = computed(() => columns_drinks.filter((column) => column.filterable));
|
||||||
function image(uuid: string | undefined) {
|
function image(uuid: string | undefined) {
|
||||||
if (uuid) {
|
if (uuid) {
|
||||||
return `${api.defaults.baseURL||''}/pricelist/picture/${uuid}?size=256`;
|
return `${api.defaults.baseURL || ''}/pricelist/picture/${uuid}?size=256`;
|
||||||
}
|
}
|
||||||
return 'no-image.svg';
|
return 'no-image.svg';
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,6 +1,11 @@
|
||||||
import { Drink } from '../store';
|
import { Drink } from '../store';
|
||||||
|
|
||||||
function filter(rows: Array<Drink>, terms: Search, cols: Array<Col>, cellValue: { (col: Col, row: Drink): string }) {
|
function filter(
|
||||||
|
rows: Array<Drink>,
|
||||||
|
terms: Search,
|
||||||
|
cols: Array<Col>,
|
||||||
|
cellValue: { (col: Col, row: Drink): string }
|
||||||
|
) {
|
||||||
if (terms.value) {
|
if (terms.value) {
|
||||||
return rows.filter((row) => {
|
return rows.filter((row) => {
|
||||||
if (!terms.key || terms.key === '') {
|
if (!terms.key || terms.key === '') {
|
||||||
|
|
Loading…
Reference in New Issue