Skip to content

feat(cdm): add fill first row/column toggle for icon distribution#81

Open
nulltyto wants to merge 1 commit intoEllesmereGaming:mainfrom
nulltyto:feat/cdm-fill-first-row
Open

feat(cdm): add fill first row/column toggle for icon distribution#81
nulltyto wants to merge 1 commit intoEllesmereGaming:mainfrom
nulltyto:feat/cdm-fill-first-row

Conversation

@nulltyto
Copy link
Copy Markdown
Contributor

Summary

  • Adds a Fill Top Row First / Fill Left Column First toggle to CDM bar options, controlling whether the first or last row gets filled completely when icons don't divide evenly across rows
  • Pairs the new toggle with Show Tooltip on Hover (moved from its own standalone row) on a new DualRow
  • Number of Rows label dynamically switches to Number of Columns when Vertical Orientation is enabled
  • Clamps effective numRows after computing stride (numRows = ceil(count/stride)) to prevent empty row bugs
  • Slider getValue/setValue clamped to ceil(spellCount/2) for sensible limits

Test plan

  • Set a bar to 2+ rows with an uneven icon count (e.g., 7 icons, 2 rows) — verify default shows 3 top / 4 bottom
  • Toggle Fill Top Row First on — verify it shows 4 top / 3 bottom with the partial row centered
  • Toggle Vertical Orientation — verify label changes to Fill Left Column First and Number of Columns
  • Toggle fills left column first in vertical mode
  • Set rows to 1 — verify the fill toggle is disabled with tooltip
  • Remove spells until count < stored numRows — verify no empty rows appear
  • Verify preview matches live bar layout in all configurations

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant