chore: add eslint rules for spacing (#464)

Co-authored-by: Benjamin Canac <canacb1@gmail.com>
This commit is contained in:
Haytham A. Salama
2023-07-30 16:56:01 +03:00
committed by GitHub
parent 1bc055935e
commit 5221294f78
10 changed files with 55 additions and 31 deletions

View File

@@ -38,7 +38,7 @@ import { defu } from 'defu'
import UIcon from '../elements/Icon.vue'
import UAvatar from '../elements/Avatar.vue'
import UButton from '../elements/Button.vue'
import type { Avatar} from '../../types/avatar'
import type { Avatar } from '../../types/avatar'
import type { Button } from '../../types/button'
import { classNames } from '../../utils'
import { useAppConfig } from '#imports'

View File

@@ -84,7 +84,7 @@ export default defineComponent({
}
})
const switchClass = computed(()=>{
const switchClass = computed(() => {
return classNames(
ui.value.base,
ui.value.rounded,
@@ -93,13 +93,13 @@ export default defineComponent({
)
})
const onIconClass = computed(()=>{
const onIconClass = computed(() => {
return classNames(
ui.value.icon.on.replaceAll('{color}', props.color)
)
})
const offIconClass = computed(()=>{
const offIconClass = computed(() => {
return classNames(
ui.value.icon.off.replaceAll('{color}', props.color)
)

View File

@@ -1,6 +1,6 @@
<template>
<component
:is="$attrs.onSubmit ? 'form': as"
:is="$attrs.onSubmit ? 'form' : as"
:class="[ui.base, ui.rounded, ui.divide, ui.ring, ui.shadow, ui.background]"
v-bind="$attrs"
>

View File

@@ -123,7 +123,7 @@ export default defineComponent({
return typeof label === 'function' ? label(props.query) : label
})
function highlight (text: string, { indices, value }: { indices: number[][], value:string }): string {
function highlight (text: string, { indices, value }: { indices: number[][], value: string }): string {
if (text === value) {
return ''
}

View File

@@ -47,7 +47,7 @@ import UAvatar from '../elements/Avatar.vue'
import UButton from '../elements/Button.vue'
import { useTimer } from '../../composables/useTimer'
import type { NotificationAction } from '../../types'
import type { Avatar} from '../../types/avatar'
import type { Avatar } from '../../types/avatar'
import type { Button } from '../../types/button'
import { classNames } from '../../utils'
import { useAppConfig } from '#imports'