Repository navigation
fix(frontend): 控件坞图标被 React Flow 内置样式填成实心块(#71 遗漏),恢复描边线条 - #73
Merged
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
改了什么
控件坞那九行的图标原本是实心色块、还被缩到 12px,现在恢复成与插件版一致的描边线条(14px、
strokeWidth 1.7)。修法是
index.css里加一条覆盖:为什么(#71 漏掉的)
#71 把形状换成了插件版那套内联图标,但没处理容器自带的 svg 样式。控件坞每行就是一颗 React Flow 的
.react-flow__controls-button,而 React Flow 内置:于是:
fill: currentColor顶掉 svg 上的fill="none"(presentation attribute 打不过作者样式)→ 靠 stroke 画的线条被填成实心;max-width: 12px把 14px 的图标缩一号。实测(Chromium computed style):
fill实际是rgb(82,96,111)、渲染12×12。节点右侧操作栏(#71 的另一半)不在 controls 容器里,本来就是正常线条 —— 所以上次只有控件坞出问题。
实测
computed fillrgb(82,96,111)(填充)nonemax-width/height12pxnonestroke-width验证
cd frontend; npm run buildcd frontend; npm testcd frontend; npm run lintuv run python scripts/check_docs.py新增用例(
canvasStyles.test.ts)锁住fill: none/max-width: none/width: 14px,删掉任一条就红。相关 PR
overflow裁掉提交拆分
fix(frontend): 控件坞图标压掉 React Flow 内置 svg 的 fill/12px,恢复描边线条test(frontend): 锁住控件坞图标是描边线条(fill none + 14px)docs(frontend): 记下 React Flow 会填实控件坞图标这条坑,同步仪表盘 1071真机截图
隔离实例 + 真实 Chromium、2x 像素、同一窗口号(
win=1)。本机gh无--attach,图在此处占位: