Skip to content

Conversation

felixturner
Copy link

@felixturner felixturner commented Sep 25, 2025

Description:

Summary

  • Improve group title layout to visually match node titles with consistent spacing and alignment
  • Reduce group title font size from 24px to 20px for better proportions
  • Remove font sizing from themes and workflow serialization, making them hardcoded constants

Changes Made

First commit - Remove font sizing from themes:

  • Remove NODE_TEXT_SIZE, NODE_SUBTEXT_SIZE, and GROUP_TEXT_SIZE from all palette JSON files
  • Remove font_size from group serialization/deserialization to prevent workflow overrides
  • Update schemas and tests to reflect font size removal from themes
  • Ensure themes only contain colors, making them the single source of truth for colors only

This change prevents themes and saved workflows from overriding font sizes, ensuring consistent typography controlled by hardcoded constants. Also prevents layout issues if the font sizes are changed from the default.

Second commit - Update group title layout:

  • Use NODE_TITLE_HEIGHT (30px) for group title area height consistently
  • Center text vertically in title area with left padding (font_size / 2)
  • Add precise +1px vertical offset for optimal text centering
  • Update LGraphCanvas header height calculation to use NODE_TITLE_HEIGHT

This gives more whitespace around group titles and fixes the odd group title height of ~3.3 grid units

Test Plan

  • All existing tests pass
  • Updated test snapshots reflect new GROUP_TEXT_SIZE value
  • Typecheck passes
  • Lint passes
  • Visual testing confirms improved group title layout matches node titles

Screenshots

Before

before

After

after

┆Issue is synchronized with this Notion page by Unito

  - Remove NODE_TEXT_SIZE, NODE_SUBTEXT_SIZE, and GROUP_TEXT_SIZE from all palette JSON files
  - Make font sizes hardcoded constants in LiteGraphGlobal instead of theme-configurable
  - Remove font_size from group serialization/deserialization to prevent workflow overrides
  - Update schemas and tests to reflect font size removal from themes
  - Ensure themes only contain colors, making them the single source of truth for colors only

This change prevents themes and saved workflows from overriding font sizes, ensuring consistent typography controlled by hardcoded constants. Also prevents layout issues if the font sizes are changed from the default.
- Reduce GROUP_TEXT_SIZE from 24 to 20px for better proportions
- Use NODE_TITLE_HEIGHT (30px) for group title area height consistently
- Center text vertically in title area with left padding (font_size / 2)
- Update LGraphCanvas header height calculation to use NODE_TITLE_HEIGHT
- Update test snapshots to reflect new GROUP_TEXT_SIZE value

This gives more whitespace around group titles and fixes the odd group title height of ~3.3 grid units
@dosubot dosubot bot added the size:M This PR changes 30-99 lines, ignoring generated files. label Sep 25, 2025
Copy link

🎭 Playwright Test Results

loading Tests are starting...

⏰ Started at: 09/25/2025, 08:30:49 PM UTC

🚀 Running Tests

  • 🧪 chromium: Running tests...
  • 🧪 chromium-0.5x: Running tests...
  • 🧪 chromium-2x: Running tests...
  • 🧪 mobile-chrome: Running tests...

⏱️ Please wait while tests are running...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
size:M This PR changes 30-99 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant