Browse Source

fix: Fix Layout Page Tabs dragable (#1433)

* fix: pnpm install

* fix: Fix Tabs dragable
humanscrew 3 years ago
parent
commit
cfda62ef9c
2 changed files with 80 additions and 413 deletions
  1. 77 412
      pnpm-lock.yaml
  2. 3 1
      src/layouts/default/tabs/useMultipleTabs.ts

File diff suppressed because it is too large
+ 77 - 412
pnpm-lock.yaml


+ 3 - 1
src/layouts/default/tabs/useMultipleTabs.ts

@@ -56,7 +56,9 @@ export function useTabsDrag(affixTextList: string[]) {
   const { prefixCls } = useDesign('multiple-tabs');
   nextTick(() => {
     if (!multiTabsSetting.canDrag) return;
-    const el = document.querySelectorAll(`.${prefixCls} .ant-tabs-nav > div`)?.[0] as HTMLElement;
+    const el = document.querySelectorAll(
+      `.${prefixCls} .ant-tabs-nav-wrap > div`,
+    )?.[0] as HTMLElement;
     const { initSortable } = useSortable(el, {
       filter: (e: ChangeEvent) => {
         const text = e?.target?.innerText;

Some files were not shown because too many files changed in this diff