diff --git a/packages/effects/plugins/src/vxe-table/__tests__/use-vxe-grid.reactivity.test.ts b/packages/effects/plugins/src/vxe-table/__tests__/use-vxe-grid.reactivity.test.ts index a165ee069..d2e542cef 100644 --- a/packages/effects/plugins/src/vxe-table/__tests__/use-vxe-grid.reactivity.test.ts +++ b/packages/effects/plugins/src/vxe-table/__tests__/use-vxe-grid.reactivity.test.ts @@ -52,7 +52,11 @@ vi.mock('@vben/locales', () => ({ $t: (key: string) => key })); vi.mock('@vben-core/shadcn-ui', async () => { const { defineComponent, h } = await import('vue'); - const Stub = defineComponent((_, { slots }) => () => h('div', slots.default?.())); + const Stub = defineComponent( + (_, { slots }) => + () => + h('div', slots.default?.()), + ); return { VbenHelpTooltip: Stub, VbenLoading: Stub }; }); @@ -121,15 +125,16 @@ describe('vben vxe grid toolbar slots', () => { unmount: vi.fn(), useStore: vi.fn(() => ({})), }; - const Consumer = defineComponent(() => () => - h(VbenVxeGrid, { api } as any, { - [slotName]: () => - h( - 'span', - { 'data-slot-state': '' }, - loading.value ? 'loading' : 'idle', - ), - }), + const Consumer = defineComponent( + () => () => + h(VbenVxeGrid, { api } as any, { + [slotName]: () => + h( + 'span', + { 'data-slot-state': '' }, + loading.value ? 'loading' : 'idle', + ), + }), ); const host = document.createElement('div'); document.body.append(host); diff --git a/packages/effects/plugins/src/vxe-table/use-vxe-grid.vue b/packages/effects/plugins/src/vxe-table/use-vxe-grid.vue index f45912d3e..e1e7c69a9 100644 --- a/packages/effects/plugins/src/vxe-table/use-vxe-grid.vue +++ b/packages/effects/plugins/src/vxe-table/use-vxe-grid.vue @@ -157,9 +157,7 @@ const showTableTitle = computed(() => { const showToolbar = computed(() => { return ( - !!slots[TOOLBAR_ACTIONS] || - !!slots[TOOLBAR_TOOLS] || - showTableTitle.value + !!slots[TOOLBAR_ACTIONS] || !!slots[TOOLBAR_TOOLS] || showTableTitle.value ); });