mirror of
https://github.com/CorentinTh/it-tools.git
synced 2025-05-04 13:29:13 -04:00
chore(lint): switched to a better lint config
This commit is contained in:
parent
4d2b037dbe
commit
33c9b6643f
178 changed files with 4105 additions and 3371 deletions
|
@ -1,12 +1,3 @@
|
|||
<template>
|
||||
<div flex items-center>
|
||||
<template v-for="(item, index) in items">
|
||||
<n-divider v-if="item.type === 'divider'" :key="`divider${index}`" vertical />
|
||||
<menu-bar-item v-else-if="item.type === 'button'" :key="index" v-bind="item" />
|
||||
</template>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script setup lang="ts">
|
||||
import type { Editor } from '@tiptap/vue-3';
|
||||
import {
|
||||
|
@ -27,7 +18,7 @@ import {
|
|||
Strikethrough,
|
||||
TextWrap,
|
||||
} from '@vicons/tabler';
|
||||
import { toRefs, type Component } from 'vue';
|
||||
import { type Component, toRefs } from 'vue';
|
||||
import MenuBarItem from './menu-bar-item.vue';
|
||||
|
||||
const props = defineProps<{ editor: Editor }>();
|
||||
|
@ -35,12 +26,12 @@ const { editor } = toRefs(props);
|
|||
|
||||
type MenuItem =
|
||||
| {
|
||||
icon: Component;
|
||||
title: string;
|
||||
action: () => void;
|
||||
isActive?: () => boolean;
|
||||
type: 'button';
|
||||
}
|
||||
icon: Component
|
||||
title: string
|
||||
action: () => void
|
||||
isActive?: () => boolean
|
||||
type: 'button'
|
||||
}
|
||||
| { type: 'divider' };
|
||||
|
||||
const items: MenuItem[] = [
|
||||
|
@ -166,4 +157,11 @@ const items: MenuItem[] = [
|
|||
];
|
||||
</script>
|
||||
|
||||
<style scoped></style>
|
||||
<template>
|
||||
<div flex items-center>
|
||||
<template v-for="(item, index) in items">
|
||||
<n-divider v-if="item.type === 'divider'" :key="`divider${index}`" vertical />
|
||||
<MenuBarItem v-else-if="item.type === 'button'" :key="index" v-bind="item" />
|
||||
</template>
|
||||
</div>
|
||||
</template>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue