mirror of
https://github.com/hansjone/mind-map.git
synced 2026-10-13 08:23:20 +08:00
Initial commit: DSH mind-map canvas monorepo
Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
commit
2ecd300ada
92 changed files with 20486 additions and 0 deletions
22
apps/web/scripts/fix-topology-cjk4.py
Normal file
22
apps/web/scripts/fix-topology-cjk4.py
Normal file
|
|
@ -0,0 +1,22 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
from pathlib import Path
|
||||
|
||||
p = Path(__file__).resolve().parents[1] / "src" / "TopologyCanvas.tsx"
|
||||
t = p.read_text(encoding="utf-8")
|
||||
pairs = [
|
||||
(
|
||||
'title="???????????? (N)??? Shift ??????"',
|
||||
'title="单点拖拽:只移动当前节点 (N);按住 Shift 也可临时单点"',
|
||||
),
|
||||
(
|
||||
'title="?????????????? (B)"',
|
||||
'title="整枝拖拽:节点与子孙一起移动 (B)"',
|
||||
),
|
||||
]
|
||||
for old, new in pairs:
|
||||
if old not in t:
|
||||
raise SystemExit(f"missing: {old}")
|
||||
t = t.replace(old, new, 1)
|
||||
print("fixed:", new[:40])
|
||||
p.write_text(t, encoding="utf-8", newline="\n")
|
||||
print("done")
|
||||
Loading…
Add table
Add a link
Reference in a new issue