mirror of
https://github.com/Comfy-Org/ComfyUI_frontend.git
synced 2026-05-03 04:31:58 +00:00
[feat] Improve group title layout (#9839)
Rebased and adopted from #5774 by @felixturner. ## Changes - Remove unused font-size properties (`NODE_TEXT_SIZE`, `NODE_SUBTEXT_SIZE`, `DEFAULT_GROUP_FONT`) from theme palettes and color palette schema - Replace `DEFAULT_GROUP_FONT`/`DEFAULT_GROUP_FONT_SIZE` with a single `GROUP_TEXT_SIZE = 20` constant (reduced from 24px) - Use `NODE_TITLE_HEIGHT` for group header height instead of `font_size * 1.4` - Vertically center group title text using `textBaseline = 'middle'` - Use `GROUP_TEXT_SIZE` directly in TitleEditor instead of per-group `font_size` - Remove `font_size` from group serialization (no longer per-group configurable) ## Original PR Closes #5774 ┆Issue is synchronized with this [Notion page](https://www.notion.so/PR-9839-feat-Improve-group-title-layout-3216d73d36508112a0edc2a370af20ba) by [Unito](https://www.unito.io) --------- Co-authored-by: Felix Turner <felixturner@gmail.com> Co-authored-by: github-actions <github-actions@github.com> Co-authored-by: Alexander Brown <drjkl@comfy.org>
This commit is contained in:
@@ -34,9 +34,7 @@
|
||||
"CLEAR_BACKGROUND_COLOR": "#040506",
|
||||
"NODE_TITLE_COLOR": "#999",
|
||||
"NODE_SELECTED_TITLE_COLOR": "#e5eaf0",
|
||||
"NODE_TEXT_SIZE": 14,
|
||||
"NODE_TEXT_COLOR": "#bcc2c8",
|
||||
"NODE_SUBTEXT_SIZE": 12,
|
||||
"NODE_DEFAULT_COLOR": "#161b22",
|
||||
"NODE_DEFAULT_BGCOLOR": "#13171d",
|
||||
"NODE_DEFAULT_BOXCOLOR": "#30363d",
|
||||
@@ -45,7 +43,6 @@
|
||||
"NODE_BYPASS_BGCOLOR": "#FF00FF",
|
||||
"NODE_ERROR_COLOUR": "#E00",
|
||||
"DEFAULT_SHADOW_COLOR": "rgba(0,0,0,0.5)",
|
||||
"DEFAULT_GROUP_FONT": 24,
|
||||
"WIDGET_BGCOLOR": "#161b22",
|
||||
"WIDGET_OUTLINE_COLOR": "#30363d",
|
||||
"WIDGET_TEXT_COLOR": "#bcc2c8",
|
||||
|
||||
Reference in New Issue
Block a user