optimize(projects): 🎨 fix warning Component name should always be multi-word (#46)

This commit is contained in:
一寸灰
2025-01-06 19:38:45 +08:00
committed by GitHub
parent c94c8454b2
commit aceff344dd
15 changed files with 14 additions and 16 deletions

View File

@@ -4,7 +4,6 @@ import { $t } from '@/locales';
defineOptions({ name: 'TableHeaderOperation' });
interface Props {
itemAlign?: UI.Align;
disabledDelete?: boolean;
loading?: boolean;
}

View File

@@ -1,6 +1,5 @@
declare namespace UI {
type ThemeColor = 'danger' | 'primary' | 'info' | 'success' | 'warning';
type Align = 'stretch' | 'baseline' | 'start' | 'end' | 'center' | 'flex-end' | 'flex-start';
type TableColumnCheck = import('@sa/hooks').TableColumnCheck;
type TableDataWithIndex<T> = import('@sa/hooks').TableDataWithIndex<T>;

View File

@@ -8,11 +8,11 @@ interface Props {
defineProps<Props>();
onMounted(() => {
console.log('mounted');
// console.log('mounted');
});
onActivated(() => {
console.log('activated');
// console.log('activated');
});
</script>

View File

@@ -12,7 +12,7 @@ import Register from './modules/register.vue';
import ResetPwd from './modules/reset-pwd.vue';
import BindWechat from './modules/bind-wechat.vue';
defineOptions({ name: 'Login' });
defineOptions({ name: 'LoginPage' });
interface Props {
/** The login module */

View File

@@ -4,7 +4,7 @@ import { $t } from '@/locales';
import { useAppStore } from '@/store/modules/app';
import pkg from '~/package.json';
defineOptions({ name: 'About' });
defineOptions({ name: 'AboutPage' });
const appStore = useAppStore();

View File

@@ -3,7 +3,7 @@ import JsBarcode from 'jsbarcode';
import type { Options } from 'jsbarcode';
import { onMounted } from 'vue';
defineOptions({ name: 'Barcode' });
defineOptions({ name: 'BarcodePage' });
const text = 'Soybean';

View File

@@ -2,7 +2,7 @@
import { ref } from 'vue';
import { useClipboard } from '@vueuse/core';
defineOptions({ name: 'Copy' });
defineOptions({ name: 'CopyPage' });
const { copy, isSupported } = useClipboard();

View File

@@ -4,7 +4,7 @@ import Vditor from 'vditor';
import 'vditor/dist/index.css';
import { useThemeStore } from '@/store/modules/theme';
defineOptions({ name: 'Markdown' });
defineOptions({ name: 'MarkdownPage' });
const theme = useThemeStore();

View File

@@ -2,7 +2,7 @@
import { onMounted, ref } from 'vue';
import WangEditor from 'wangeditor';
defineOptions({ name: 'Quill' });
defineOptions({ name: 'QuillPage' });
const editor = ref<WangEditor>();
const domRef = ref<HTMLElement>();

View File

@@ -6,7 +6,7 @@ import { fetchGetUserList } from '@/service/api';
import { enableStatusRecord, userGenderRecord } from '@/constants/business';
import { $t } from '@/locales';
defineOptions({ name: 'Excel' });
defineOptions({ name: 'ExcelPage' });
const { columns, data, loading } = useTable({
apiFn: fetchGetUserList,

View File

@@ -5,7 +5,7 @@ import type { GanttConfigOptions, ZoomLevel } from 'dhtmlx-gantt';
import 'dhtmlx-gantt/codebase/dhtmlxgantt.css';
import { ganttTasks } from './data';
defineOptions({ name: 'Gantt' });
defineOptions({ name: 'GanttPage' });
const ganttRef = shallowRef<HTMLElement>();

View File

@@ -2,7 +2,7 @@
import { ref } from 'vue';
import { icons } from './icons';
defineOptions({ name: 'Icon' });
defineOptions({ name: 'IconPage' });
const selectValue = ref('');

View File

@@ -3,7 +3,7 @@ import { ref, shallowRef } from 'vue';
import VuePdfEmbed from 'vue-pdf-embed';
import { useLoading } from '@sa/hooks';
defineOptions({ name: 'Pdf' });
defineOptions({ name: 'PdfPage' });
const { loading, endLoading } = useLoading(true);

View File

@@ -3,7 +3,7 @@ import { onMounted, ref } from 'vue';
import { html } from 'pinyin-pro';
import domPurify from 'dompurify';
defineOptions({ name: 'Pinyin' });
defineOptions({ name: 'PinyinPage' });
const domRef = ref<HTMLElement | null>(null);
const domRef2 = ref<HTMLElement | null>(null);

View File

@@ -1,7 +1,7 @@
<script lang="ts" setup>
import printJS from 'print-js';
defineOptions({ name: 'Print' });
defineOptions({ name: 'PrintPage' });
function printTable() {
printJS({