Skip to content

Support desktop table row and column dragging for regular tables#17350

Open
devshanx wants to merge 1 commit intosiyuan-note:devfrom
devshanx:feat/table-drag-reorder
Open

Support desktop table row and column dragging for regular tables#17350
devshanx wants to merge 1 commit intosiyuan-note:devfrom
devshanx:feat/table-drag-reorder

Conversation

@devshanx
Copy link
Copy Markdown

@devshanx devshanx commented Mar 30, 2026

Description / 描述

为表格增加行列拖动柄,issue和演示视频见:#17344

范围如下:

仅桌面端
仅普通表格 NodeTable
复用现有右键菜单/快捷键对应的移动语义和事务更新逻辑
合并单元格场景(rowSpan / colSpan / .fn__none)暂不支持拖动

简单的判断规则:

列向右拖动时,以被拖动列的右边线是否越过右侧相邻列中线为准
列向左拖动时,以被拖动列的左边线是否越过左侧相邻列中线为准
行向下拖动时,以被拖动行的下边线是否越过下一行中线为准
行向上拖动时,以被拖动行的上边线是否越过上一行中线为准

也就是说,拖动判定尽量采用“前沿边越过相邻项中线”这一条单一规则,而不是复杂碰撞模型,更容易保持稳定

Type of change / 变更类型

  • Bug fix
    缺陷修复
  • Refactoring
    代码重构
  • New feature
    新功能
  • Text updates or new language additions
    修改文案或增加新语言

Checklist / 检查清单

  • I have performed a self-review of my own code
    我对自己的代码进行了自我审查
  • I have full rights to the submitted code and agree to license it under this project's AGPL-3.0 license
    我拥有所提交代码的完整权利,并同意其以本项目的 AGPL-3.0 许可证授权
  • PR is submitted to the dev branch and has no merge conflicts
    PR 提交到 dev 分支,并且没有合并冲突

@88250
Copy link
Copy Markdown
Member

88250 commented Mar 30, 2026

先问一句:仅桌面端

浏览器端不支持吗?

@devshanx
Copy link
Copy Markdown
Author

@88250 ,我之前的措辞不准确,仅不支持移动端界面,所有的桌面端界面都支持,用!isMobile()判断的

@88250
Copy link
Copy Markdown
Member

88250 commented Mar 30, 2026

懂了,等 @Vanessa219 看吧,谢谢。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants