refactor: group import statements

Signed-off-by: Pranav C <pranavxc@gmail.com>
This commit is contained in:
Pranav C
2022-11-22 11:21:41 +05:30
parent 26d7759c9e
commit 0d98aac265
2 changed files with 12 additions and 12 deletions

View File

@@ -10,6 +10,7 @@ import {
ReadonlyInj,
computed,
enumColor,
extractSdkResponseErrorMsg,
h,
inject,
onMounted,
@@ -21,7 +22,6 @@ import {
useSelectedCellKeyupListener,
watch,
} from '#imports'
import { extractSdkResponseErrorMsg } from '~/utils'
import MdiCloseCircle from '~icons/mdi/close-circle'
interface Props {
@@ -107,13 +107,13 @@ const selectedTitles = computed(() =>
? typeof modelValue === 'string'
? isMysql
? modelValue.split(',').sort((a, b) => {
const opa = options.value.find((el) => el.title === a)
const opb = options.value.find((el) => el.title === b)
if (opa && opb) {
return opa.order! - opb.order!
}
return 0
})
const opa = options.value.find((el) => el.title === a)
const opb = options.value.find((el) => el.title === b)
if (opa && opb) {
return opa.order! - opb.order!
}
return 0
})
: modelValue.split(',')
: modelValue
: [],
@@ -284,13 +284,13 @@ const onTagClick = (e: Event, onClose: Function) => {
<template #tagRender="{ value: val, onClose }">
<a-tag
@click="onTagClick($event, onClose)"
v-if="options.find((el) => el.title === val)"
class="rounded-tag nc-selected-option"
:style="{ display: 'flex', alignItems: 'center' }"
:color="options.find((el) => el.title === val)?.color"
:closable="(active || editable) && (vModel.length > 1 || !column?.rqd)"
:close-icon="h(MdiCloseCircle, { class: ['ms-close-icon'] })"
@click="onTagClick($event, onClose)"
@close="onClose"
>
<span