Skip to content

Release v4.6.0

Choose a tag to compare

@github-actions github-actions released this 15 Sep 18:33
e6543e6

One body of work: what a product needs to own its numeric and entity-picking fields on Components without touching React Aria internals. The first commit fixes the number input's restyling contract; the second adds the picker the catalog lacked. Both were motivated by the same consumer, which restyles NumberInput on root and had hand-rolled its customer, contact and company pickers with no roles and no keyboard path.

Added

  • ComboBox under @cratis/components/Common: the input owns the combobox role with aria-expanded/aria-controls/aria-activedescendant; options render in a listbox popover; ArrowUp/Down move, Enter selects, Escape closes, typing filters (contains, startsWith, or none for consumer-side search via onInputChange); openOnFocus; loading/loadingMessage as a busy status region, failure as an alert replacing the options, emptyMessage; an action footer row after the options that receives the typed text; options with label, optional description (inline or stacked) and disabled; description/errorMessage associated through aria-describedby/aria-errormessage (#279)
  • Fourteen stable ComboBox parts with canonical states in the generated manifest; no new tokens (#279)
  • group is a stable part on NumberInput and NumberInputField (data-cratis-part="group", states disabled / invalid / readonly), so a product that owns the box on root removes the built-in one through pt.group (#277)
  • showSteppers (default true) on NumberInput removes the decrement/increment buttons entirely; keyboard stepping still commits with the Step reason; the field forwards it (#277)
  • Documentation for both, seven stories (one ComboBox keyboard play, one product-owned NumberInput box), and specs — the ComboBox ones drive the real React Aria popover in jsdom (#277, #279)

Changed

  • The Styling cascade contract explains that a product declaring its own @layer order first must name the cratis-* layers in that statement, between its reset and its utilities — declaring them after the Components import ranks a component stylesheet above every product utility (#277)
  • The duplicated narrow-width .cratis-number-input__steps block in NumberInput.css is merged into one rule (same declarations, same media query).
  • The packed stylesheet's raw ceiling moves from 204 KiB to 205 KiB against the new measurement (raw 209017, gzip 32022, 1170 blocks). The gzip ceiling — the size a consumer transfers — is not raised and keeps 746 bytes of headroom; the comment records that the next stylesheet has to come with a reduction. Flagged for your judgement.

Dropdown is unchanged; existing NumberInput consumers render the same DOM and CSS with the defaults.

Verification

  • 50 specs across for_ComboBox, for_NumberInput and for_NumberInputField; parts manifest (57 components, 313 parts); TSDoc coverage; story index attestation (302 stories / 70 modules); packed archive within budget; story × axe matrix: 4 renderers × 302 stories × 2 appearances = 2,416 cases, zero violations.

Supersedes #278 and #282, which carried these two commits separately.

Proposed release intent: minor.