Skip to content

v3.5.0

Choose a tag to compare

@blvdmitry blvdmitry released this 21 Apr 10:06
· 6 commits to main since this release

Full web changelog · Documentation

npm install reshaped

NumberField

We've added a new NumberField component for working with numerical values.
It's built on top of TextField, inheriting most of its props.
In addition, it includes controls for adjusting the value and props for setting boundaries and step size.

Headless utilities

Starting with this release, we're exposing more internal headless utilities to help you build fully custom components.
The main highlight is the TrapFocus utility class, which lets you easily trap focus within a specific content area.

In addition to existing trap focus modes like dialog and action-menu, we've added a new action-bar mode.
It supports keyboard navigation using the ArrowLeft and ArrowRight keys.


We're also exposing two more internal hooks.
useOnClickOutside lets you handle clicks outside the given refs.
useHandlerRef helps with memoizing event handlers passed to your custom components as props.

Form field sizes

We're adding more supported sizes across all input components, aligning them better between each other and providing better support for dense user interfaces, like data-rich admin interfaces.
All sizes support responsive property syntax, allowing you to easily change it based on the application viewport.

  • Checkbox: Added small and large sizes
  • Radio: Added small and large sizes
  • Switch: Aligned the size styles and added responsive syntax support
  • Select: Added small size
  • TextField: Added small size
  • PinField: Added small size

Calendar dates selection

Calendar now supports selecting individual dates.
You can pick multiple standalone dates instead of being limited to a single date or a date range.

Other improvements

  • React: Added displayName to all components to show their name in React developer tools accurately for production builds
  • Autocomplete: Improved focus handling when clicking on disabled autocomplete items #402
  • Avatar: Added an imageAttributes property support #399
  • Avatar: Relaxed typings related to the avatar content type
  • Avatar: Added a renderImage property for integrating with framework image components, like next/image #399
  • DropdownMenu: Added className support for DropdownMenu.Item
  • FormControl: Made label element inline to avoid label events when clicking on the empty space
  • Icon: Added svg vertical alignment in case svg content is smaller that the icon size #397
  • Image: Added a renderImage property for integrating with framework image components, like next/image #399
  • Popover: Fixed outside click detection to correctly track clicked components that get unmounted #394
  • TextField: Added inputAttributes.className support
  • useScrollLock: Fixed a race condition for nested locks when using it with a container option