Skip to content

feat: grid item - #19

Merged
dzole0311 merged 7 commits into
mainfrom
feat-grid-item
Aug 13, 2026
Merged

feat: grid item#19
dzole0311 merged 7 commits into
mainfrom
feat-grid-item

Conversation

@dzole0311

Copy link
Copy Markdown
Member

Sketch based on comments in: #17 (comment)

Screen.Recording.2026-08-11.at.12.48.40.mov

cc @batpad @wrynearson

Transparent wrapper that carries col_span/row_span/area placement
metadata for a child mounted inside a Grid cell. Renders its child
with no visible markup of its own, so wrapping a widget never changes
how it looks, only where/how big its cell is.
Grid resolves each child's placement before mounting it into its cell:
a GridItem wrapper's col_span/row_span apply as grid-column/grid-row
spans, or its area places the cell into a new template_areas region.
Bare (unwrapped) children keep today's 1x1 row-major behaviour.
A cell's child previously kept its own intrinsic width/height (e.g.
Stat's inline-block sizing), so a spanned or full-width cell left the
visible card sitting at its natural narrow size instead of filling the
wider track. Cells are now flex containers with their child set to
flex: 1 1 auto, so any mounted widget stretches to fill its cell
regardless of its own display value.
columns now accepts either an int (today's N-equal-columns behaviour)
or a raw grid-template-columns track string (e.g. "200px 1fr"), for a
sidebar narrower than the main content instead of a forced 50/50 split.
template_rows is a raw grid-template-rows track string (e.g.
"auto 1fr auto") for a thin header/footer with a tall middle row;
height gives the Grid itself a defined size so fr tracks have space to
distribute, matching how CSS Grid's own 1fr row sizing requires a
defined container height to mean anything.
…izing

Adds GridItem's page under the Layout nav section, and documents
col_span/row_span, template_areas, the columns track-string form, and
template_rows/height on Grid and GridItem's own doc pages.
@dzole0311 dzole0311 changed the title Feat grid item feat: grid item Aug 11, 2026
@dzole0311
dzole0311 requested a review from batpad August 11, 2026 11:04
GridItem wasn't listed in build_skill_reference.py's GROUPS, so it fell
into the unsectioned "Other" catch-all and got skipped entirely from
the generated per-widget API reference. Regenerated widgets-api.md to
match (CI's "Skill reference is up to date" check diffs this file
against a fresh regen).
@batpad

batpad commented Aug 13, 2026

Copy link
Copy Markdown
Member

@dzole0311 shall we merge this? I think once we have this merged, I can make a 0.2.0 release?

@dzole0311
dzole0311 changed the base branch from fullscreen-widget to main August 13, 2026 10:23
@dzole0311
dzole0311 merged commit 40a59ea into main Aug 13, 2026
3 checks passed
@wrynearson
wrynearson deleted the feat-grid-item branch August 13, 2026 14:34
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.

2 participants