Skip to content

Commit 6512875

Browse files
committed
refactor: 复用脚本
1 parent b46465e commit 6512875

File tree

1 file changed

+2
-7
lines changed

1 file changed

+2
-7
lines changed

src/BootstrapBlazor/Components/Table/Table.razor.js

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
export { getResponsive } from '../../modules/responsive.js'
1+
export { getResponsive } from '../../modules/responsive.js'
22
import { copy, drag, getDescribedElement, getOuterHeight, getWidth, isVisible } from '../../modules/utility.js'
33
import '../../modules/browser.js'
44
import Data from '../../modules/data.js'
@@ -931,12 +931,7 @@ const setDraggable = table => {
931931
let index = 0
932932
table.dragColumns = [...table.tables[0].querySelectorAll('thead > tr > th')].filter(i => i.draggable)
933933
table.dragColumns.forEach(col => {
934-
EventHandler.off(col, 'dragstart')
935-
EventHandler.off(col, 'dragend')
936-
EventHandler.off(col, 'drop')
937-
EventHandler.off(col, 'dragenter')
938-
EventHandler.off(col, 'dragover')
939-
EventHandler.off(col, 'dragleave')
934+
disposeDragColumns(col);
940935

941936
EventHandler.on(col, 'dragstart', e => {
942937
col.parentNode.classList.add('table-dragging')

0 commit comments

Comments
 (0)