Fix/linter (#10)
* fix(style): formatting inconsistencies across codebase - Remove trailing semicolons from TypeScript imports - Fix Vue template indentation and line breaks - Standardize component attribute formatting - Remove unnecessary empty lines - Reorder import statements for consistency * chore: update import path and add editorconfig Update SidebarNavLink import path to match new component structure and add standard editorconfig for consistent code formatting
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
<script setup lang="ts">
|
||||
import type { HeaderPrep, RefSearchNav } from '../types.ts'
|
||||
import type { HeaderPrep, RefSearchNav } from '~/components/pub/custom-ui/data/types'
|
||||
|
||||
const props = defineProps<{
|
||||
prep: HeaderPrep
|
||||
@@ -11,8 +11,8 @@ const props = defineProps<{
|
||||
<header>
|
||||
<div class="flex items-center">
|
||||
<div class="ml-3 text-lg font-bold text-gray-900">
|
||||
<Icon :name="prep.icon" class="mr-2 h-4 w-4 align-middle" />
|
||||
{{ prep.title }}
|
||||
<Icon :name="props.prep.icon!" class="mr-2 h-4 w-4 align-middle" />
|
||||
{{ props.prep.title }}
|
||||
</div>
|
||||
</div>
|
||||
</header>
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
<script setup lang="ts">
|
||||
import type { HeaderPrep, RefSearchNav } from '../types.ts'
|
||||
import type { HeaderPrep, RefSearchNav } from '~/components/pub/custom-ui/data/types'
|
||||
|
||||
const props = defineProps<{
|
||||
prep: HeaderPrep
|
||||
@@ -15,7 +15,7 @@ function onInput(event: Event) {
|
||||
}
|
||||
|
||||
function btnClick() {
|
||||
props.prep?.addNav?.onClick()
|
||||
props.prep?.addNav?.onClick?.()
|
||||
}
|
||||
</script>
|
||||
|
||||
@@ -24,20 +24,17 @@ function btnClick() {
|
||||
<div class="flex items-center justify-between">
|
||||
<div class="flex items-center">
|
||||
<div class="ml-3 text-lg font-bold text-gray-900">
|
||||
<Icon :name="prep.icon" class="mr-2 size-4 md:size-6 align-middle" />
|
||||
{{ prep.title }}
|
||||
<Icon :name="props.prep.icon!" class="mr-2 size-4 md:size-6 align-middle" />
|
||||
{{ props.prep.title }}
|
||||
</div>
|
||||
</div>
|
||||
<div class="flex items-center">
|
||||
<div v-if="props.refSearchNav"
|
||||
class="ml-3 text-lg text-gray-900">
|
||||
<div v-if="props.refSearchNav" class="ml-3 text-lg text-gray-900">
|
||||
<Input
|
||||
type="text"
|
||||
placeholder="Search"
|
||||
class="w-full rounded-md border bg-white px-4 py-2 text-gray-900 sm:text-sm"
|
||||
@click="emitSearchNavClick"
|
||||
type="text" placeholder="Search"
|
||||
class="w-full rounded-md border bg-white px-4 py-2 text-gray-900 sm:text-sm" @click="emitSearchNavClick"
|
||||
@input="onInput"
|
||||
/>
|
||||
/>
|
||||
</div>
|
||||
<div v-if="prep.addNav" class="m-2 flex items-center">
|
||||
<Button size="md" class="rounded-md border border-gray-300 px-4 py-2 text-white sm:text-sm" @click="btnClick">
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
<script setup lang="ts">
|
||||
import type { HeaderPrep, RefSearchNav } from '../types.ts'
|
||||
import type { HeaderPrep, RefSearchNav } from '~/components/pub/custom-ui/data/types'
|
||||
|
||||
const props = defineProps<{
|
||||
prep: HeaderPrep
|
||||
@@ -15,7 +15,7 @@ function onInput(event: Event) {
|
||||
}
|
||||
|
||||
function btnClick() {
|
||||
props.prep.addNav?.onClick()
|
||||
props.prep?.addNav?.onClick?.()
|
||||
}
|
||||
</script>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user