diff --git a/src/components/CountDown/src/CountButton.vue b/src/components/CountDown/src/CountButton.vue index a1787f4..85214c9 100644 --- a/src/components/CountDown/src/CountButton.vue +++ b/src/components/CountDown/src/CountButton.vue @@ -38,9 +38,8 @@ async function handleStart() { loading.value = true try { const canStart = await beforeStartFunc() - if (canStart) + if (canStart) start() - } finally { loading.value = false diff --git a/src/components/FormDesign/src/components/VFormDesign/components/CodeModal.vue b/src/components/FormDesign/src/components/VFormDesign/components/CodeModal.vue index 8aba302..66a32ec 100644 --- a/src/components/FormDesign/src/components/VFormDesign/components/CodeModal.vue +++ b/src/components/FormDesign/src/components/VFormDesign/components/CodeModal.vue @@ -27,8 +27,7 @@ export default { fApi:{}, formData:{}, formConfig: ` -/* eslint-disable */ -let codeVueLast = ` +const codeVueLast = ` } }, methods: { @@ -38,36 +37,37 @@ let codeVueLast = ` } } } -<\/script>`; +<\/script>` // const state = reactive({ open: false, jsonData: {} as IFormConfig, -}); +}) -const showModal = (formConfig: IFormConfig) => { - formConfig.schemas && formatRules(formConfig.schemas); - state.open = true; - state.jsonData = formConfig; -}; +function showModal(formConfig: IFormConfig) { + formConfig.schemas && formatRules(formConfig.schemas) + state.open = true + state.jsonData = formConfig +} const editorVueJson = computed(() => { - return codeVueFront + JSON.stringify(removeAttrs(state.jsonData), null, '\t') + codeVueLast; -}); + return codeVueFront + JSON.stringify(removeAttrs(state.jsonData), null, '\t') + codeVueLast +}) defineExpose({ showModal }) + diff --git a/src/components/FormDesign/src/components/VFormDesign/components/FormNode.vue b/src/components/FormDesign/src/components/VFormDesign/components/FormNode.vue index 7a1b04f..e1d1677 100644 --- a/src/components/FormDesign/src/components/VFormDesign/components/FormNode.vue +++ b/src/components/FormDesign/src/components/VFormDesign/components/FormNode.vue @@ -9,13 +9,13 @@ import VFormItem from '../../VFormItem/index.vue' import FormNodeOperate from './FormNodeOperate.vue' const props = defineProps( - { + { schema: { type: Object as PropType, required: true, - }, + }, }, - + ) const { formConfig, formDesignMethods } = useFormDesignState() @@ -28,8 +28,7 @@ function handleSelectItem() { - diff --git a/src/layouts/default/sider/MixSider.vue b/src/layouts/default/sider/MixSider.vue index e8fbf40..d1ce065 100644 --- a/src/layouts/default/sider/MixSider.vue +++ b/src/layouts/default/sider/MixSider.vue @@ -72,7 +72,6 @@ const getIsFixed = computed(() => { return isFixed }) - const getDomStyle = computed((): CSSProperties => { const fixedWidth = unref(getIsFixed) ? unref(getRealWidth) : 0 const width = `${unref(getMixSideWidth) + fixedWidth}px` diff --git a/src/types/module.d.ts b/src/types/module.d.ts index f959d62..d464833 100644 --- a/src/types/module.d.ts +++ b/src/types/module.d.ts @@ -9,7 +9,7 @@ declare module 'ant-design-vue/es/locale/*' { import type { Locale } from 'ant-design-vue/types/locale-provider' const locale: Locale & ReadonlyRecordable - export default locale + export default locale } declare module 'virtual:*' { diff --git a/src/utils/domUtils.ts b/src/utils/domUtils.ts index e627afa..94517b4 100644 --- a/src/utils/domUtils.ts +++ b/src/utils/domUtils.ts @@ -167,7 +167,7 @@ export function useRafThrottle(fn: T): T { window.requestAnimationFrame(() => { // eslint-disable-next-line @typescript-eslint/ban-ts-comment // @ts-expect-error - // eslint-disable-next-line @typescript-eslint/no-invalid-this + // eslint-disable-next-line @typescript-eslint/no-invalid-this fn.apply(this, args) locked = false }) diff --git a/src/utils/index.ts b/src/utils/index.ts index 1b24389..3e2d8b0 100644 --- a/src/utils/index.ts +++ b/src/utils/index.ts @@ -94,6 +94,7 @@ export function openWindow(url: string, opt?: { target?: TargetContext | string; export function getDynamicProps, U>(props: T): Partial { const ret: Recordable = {} + // eslint-disable-next-line array-callback-return Object.keys(props).map((key) => { ret[key] = unref((props as Recordable)[key]) })