Skip to content

feat: add Label input primitive#645

Merged
isaquebock merged 3 commits into
mainfrom
feat/inputs-label
Jun 18, 2026
Merged

feat: add Label input primitive#645
isaquebock merged 3 commits into
mainfrom
feat/inputs-label

Conversation

@isaquebock

Copy link
Copy Markdown
Contributor

Summary

Introduce @aziontech/webkit/inputs/label — a thin <label> wrapper that:

  • Renders the field text via the value prop or a default slot.
  • Appends a Required tag (severity=warning, size=small) when required is true.
  • Wires for="<input-id>" so clicking the label focuses the control.

The component is the label only — helper text, error messages, and the input itself live in sibling primitives composed by the form-field layer.

Test plan

  • pnpm --filter @aziontech/webkit lint — clean.
  • Storybook → Webkit/Inputs/Label → Default + Required variants render.
  • Click the label text → focus moves to the associated input (manual a11y check).

Introduce `@aziontech/webkit/inputs/label` — a thin `<label>` wrapper that
renders the field text, supports a default slot, and appends a `Required`
tag when the field is required. Wires `for` to the underlying input id so
clicking the label focuses the control.

The component is the label only — helper text, error messages, and the
input itself live in sibling primitives composed by the form-field layer.
@isaquebock isaquebock marked this pull request as ready for review June 18, 2026 18:54
@isaquebock isaquebock merged commit 8783bbb into main Jun 18, 2026
11 checks passed
@robsongajunior

Copy link
Copy Markdown
Contributor

🎉 This PR is included in version 3.9.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

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

Labels

Development

Successfully merging this pull request may close these issues.

3 participants