Skip to content

fix(ui): Field keeps its control at h-control when stretched - #191

Merged
ajianaz merged 1 commit into
developfrom
fix/190-field-content-start
Nov 15, 2026
Merged

ajianaz merged 1 commit into
developfrom
fix/190-field-content-start

Conversation

@ajianaz

@ajianaz ajianaz commented Nov 15, 2026 •

Copy link
Copy Markdown
Contributor

What

Field packs its rows at the top (content-start), so a field stretched by its parent keeps its Input, Select or Textarea at h-control (#190). Closes #190.

  • packages/ui/src/lib/Field.svelte: grid gap-1 becomes grid content-start gap-1, with a comment explaining why.
  • A unit test checks that the field grid packs its rows at the top.
  • Changeset: ui patch.

Why

With the default align-content, the field's rows (label, control, hint, error) share any height the parent adds. So a field in a form row beside a field with an error, in a stretching flex column, or in a grid with a minimum height grew its control past the control height.

The pre-release consumer check found it: a plain Vite app built from the packed tarballs rendered the input 76 px tall instead of 44 px. The plain-CSS Field before the Tailwind move behaved the same, so this is not a migration regression. Where a field is not stretched (the playground, the visual baselines), nothing changes.

Testing

  • bun run check, test (ui 120), lint and detect pass.
  • In the consumer app, the input in a grid min-h-screen measures 76 px with the current tarball and 44 px with this fix packed into it.
  • Cora review on the staged diff (severity major): deterministic checks found nothing; the agent judge returned should_block: false, 0 issues.

Field is a grid; with the default align-content its rows shared any
extra height, so a field stretched by its parent (a form row beside a
field with an error, a stretching flex column) grew its Input, Select or
Textarea past h-control. content-start packs the rows at the top. Found
by the pre-release check of a plain Vite app built from the packed
tarballs; unchanged where a field is not stretched.

Closes #190
@ajianaz
ajianaz merged commit d760abb into develop Nov 15, 2026
14 checks passed
@ajianaz
ajianaz deleted the fix/190-field-content-start branch November 15, 2026 14:19
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.

fix(ui): Field stretches its control when the field is taller than its content

1 participant