Skip to content

v1.1.0

Latest

Choose a tag to compare

@github-actions github-actions released this 07 Nov 15:40
· 61 commits to main since this release

The first minor after the 1.0 freeze: it closes the Fluent UI v9 gap backlog of docs/ROADMAP.md (§8.2, §8.5 and §8.6) that the freeze allowed, and adds nothing breaking. Every addition is optional and defaults to the 1.0 behaviour, with the few exceptions under "Upgrading from 1.0". What stays open, and why, is in the roadmap's §8.1a.

Upgrading from 1.0

Nothing needs to change. Three kinds of difference can show in code or markup that depends on exact details:

  1. Widened unions. PresenceStatus gains 'blocked' and 'unknown', TimePickerInvalidReason gains 'not-listed', SpinnerSize gains three sizes, ToastPosition gains 'top' and 'bottom', DismissReason and ModalOpenChangeReason gain 'parent-closed'/'focus-outside', and ToastController has three more members (updateToast, pauseToast, playToast). An exhaustive switch over one of these unions, or code that implements ToastController itself, needs the new cases.
  2. Markup. MenuButton always renders aria-expanded; RadioGroup.Item renders data-label-position and Slider renders data-orientation; a bare Skeleton is 16px tall; ToggleButton as an anchor with an href and no role no longer renders aria-pressed; a popup with the default motion is data-presence="exited" until it is placed; a Popover, Menu or other popup opened inside a Dialog or Drawer closes with it. Literal markup pins in your own tests may need a refresh.
  3. Migration codemod. chart-1 to chart-5 are names a stock shadcn/ui theme also defines, so the codemod now treats 22 names as shared (the 17 of 1.0 and these five).

Added

  • Text takes Fluent's layout and decoration props: wrap, truncate, italic, underline, strikethrough, align and block (closes text-1, text-2 and text-5).
  • Divider takes appearance (default, subtle, strong, brand), inset and alignContent (start, center, end), with data-appearance, data-inset and, on a labelled divider, data-align-content (closes divider-1, divider-2 and divider-3). DividerAppearance is a new exported type.
  • Badge takes the ghost appearance (the color as text alone), shape (circular, rounded, square), the tiny size (a 6px dot with no content), and an icon slot with iconPosition (before, after), with data-shape and data-size and the stable class wave-badge__icon (closes badge-3, badge-4, badge-5 and badge-6). BadgeAppearance gains 'ghost', and BadgeSize ('tiny' and Size) is a new exported type.
  • CounterBadge takes the ghost appearance, shape and size (extra-small to extra-large; a dot stays 6px), with data-shape and data-size (closes counterbadge-4).
  • PresenceBadge takes the statuses blocked and unknown (each with a glyph of its own) and the outOfOffice modifier, which draws the out-of-office arrow in the status's color and names the badge ", out of office" (closes presence-1 and presence-2). PresenceStatus gains 'blocked' and 'unknown', so a switch over it that has no default needs the two cases. presence-4 is not changed: see the roadmap.
  • Buttons: shape (rounded, circular, square; default rounded) on Button, ToggleButton, MenuButton, CompoundButton and SplitButton and the Toolbar buttons, with data-shape while it is set (closes buttons-1). ToggleButton and MenuButton are polymorphic (as), with the new types ToggleButtonOwnProps and MenuButtonOwnProps (closes buttons-11). CompoundButton's secondaryText takes a slot object and the new contentContainer slot object re-elements the text column; both merge over slotProps (closes buttons-7). SplitButton menuButtonLabel={null} names the menu half by the primary action through aria-labelledby (closes buttons-14). Link takes background (default, brand, inverted; new type LinkBackground) with data-background (closes buttons-18).
  • Textarea takes resize (none, vertical, horizontal, both; default vertical; type TextareaResize) and onValueChange(value) (closes form-basic-13 and form-basic-15).
  • Select takes icon (a custom chevron drawn in a wave-select__wrapper beside the select; false hides the chevron; new classes wave-select__wrapper and wave-select__icon) and onValueChange(value), which with multiple gets the first selected value (closes form-basic-27 and form-basic-28).
  • RadioGroup and RadioGroup.Item take labelPosition (after, below; type RadioLabelPosition); orientation="horizontal" with labelPosition="below" is Fluent's horizontal-stacked (closes form-basic-20).
  • Slider takes orientation="vertical" (closes form-basic-30).
  • TimePicker takes showSeconds (value HH:mm:ss), formatTime(value), parseTime(text) and freeform (false limits the selection to listed times and reports others as the new 'not-listed' reason of TimePickerInvalidReason, with the message labels.notListed), closing timepicker-2, timepicker-4 and timepicker-5. A switch over TimePickerInvalidReason that has no default needs the new case.
  • Table and DataGrid take size ('medium', 'small' or 'extra-small'; type TableSize): it tightens the padding of cells, header cells, sort buttons and selection cells and sizes the media of Table.CellLayout, rendered as data-size (closes table-1). Table.Row takes appearance ('none', 'brand' or 'neutral'; type TableRowAppearance), the fill of a selected DataGrid row for a row of your own state, rendered as data-appearance (closes tr-1).
  • DataGrid takes focusMode ('cell', 'row' or 'none'; type DataGridFocusMode; Fluent's row_unstable is 'row', its 'composite' has no counterpart), and useGridNavigation takes the same option (GridNavigationFocusMode), rendered as data-focus-mode (closes dg-4, except 'composite'). DataGrid.Cell and DataGrid.HeaderCell take focusMode ('cell', 'group' or 'none'; type DataGridCellFocusMode): 'none' takes the cell and its widgets out of the arrow-key navigation, 'group' makes the cell its own focus target (closes dgc-1).
  • Table takes virtualWindow and Table.Body takes count with a function child that returns the row at an index: only the rows in view render, between spacer rows (new class wave-table__spacer), with aria-rowcount, aria-rowindex and data-row-index. GridNavigationModel takes an optional footerRowCount.
  • Dialog: Dialog.Content mountNode, titleAs and Dialog.Title as (a heading level, div or span; type DialogTitleElement), Dialog.Footer position, startActions, fluid and stackOnNarrow, and lightDismiss on a non-modal Dialog and Drawer (a press outside or focus leaving closes it, with the reasons outside-press and focus-outside) (closes dialog-6, dialogtitle-1, dialogactions-1, dialogactions-2).
  • Popover: onOpenChange(open, details?) with reason and event (types PopoverOpenChangeReason, PopoverOpenChangeDetails), withArrow, trapFocus, inline, closeOnScroll, appearance (neutral, brand, inverted), size, and Popover.Content role (closes popover-4, popover-5, popover-6, popoversurface-1, popoversurface-2, popoversurface-4).
  • Tooltip: relationship="inaccessible", withArrow with slotProps.beak, positioning.target, and asChild (no wrapper element) (closes tooltip-2, tooltip-4, tooltip-5, tooltip-7; tooltip-6 is covered by slotProps.content). TeachingPopover: appearance and trapFocus (closes teaching-2, teaching-4; teaching-3 is covered by positioning).
  • Menu: onOpenChange(open, details?) reports details.reason and the DOM event (types MenuOpenChangeReason, MenuOpenChangeDetails), closeOnScroll, inline and mountNode (both inherited by submenus), and id on Menu.Popover, which the trigger's aria-controls follows (closes menu-4 and menu-5). Menu items take subText (a second line that is part of the name; slotProps.subText), secondaryContent and disabledFocusable (closes menu-7, menu-8, menu-9). A touch or pen long press (600 ms) opens an openOnContext menu in browsers that fire no contextmenu (iOS Safari).
  • Nav and NavDrawer take density="small" (data-density), multiple={false} (one open category) and details on onValueChange, onItemSelect and onOpenCategoriesChange (types NavDensity, NavSelectDetails, NavCategoryToggleDetails) (closes nav-1, nav-2, nav-4). useNavDrawerToggle wires a Hamburger outside a NavDrawer.
  • chartSeries and the tokens --wave-chart-1 to --wave-chart-10 (chart1 to chart10, bg-wave-chart-N): ten categorical colors made for charts, 3:1 on background and card and at least 7 apart (OKLab dE x100) for full color vision and under simulated protanopia, deuteranopia and tritanopia, tested as a set in light and dark; white in high contrast. chartPalette is unchanged.
  • motion on the listbox popups of Combobox, Dropdown, TagPicker and TimePicker (and ListboxSurface), on the DatePicker calendar, and on AvatarGroup and AvatarGroup.Popover: these popups fade and slide like Popover (popupMotion), and the listbox stays in its popup while it exits.
  • useVirtualWindow takes measureItems: rows of different heights, with itemSize as the estimate; rows are measured, and the scroll position is corrected when a measured size differs. VirtualWindow.itemProps?(index) and the type VirtualItemProps are new. List, Listbox, Combobox and Dropdown lay out from it; DataGrid and FlatTree keep fixed rows.
  • virtualWindow on TimePicker and TagPicker (array form), with the classes wave-time-picker__spacer and wave-tag-picker__spacer. List takes getItemLabel(index), typeahead over every item of a windowed list.
  • Listbox (multi-select) takes range keys: Shift+Arrow, Shift+Space, Ctrl+Shift+Home/End and Ctrl/Cmd+A, with useListbox onSelectRange, the type ListboxRangeDetails and labels.rangeAdded and labels.rangeRemoved.
  • Tag and InteractionTag take disabledFocusable, InteractionTag.Primary is polymorphic (type InteractionTagPrimaryOwnProps), and TagGroup takes selectionMode="single" and wires into a Field (label, hint, message, required).
  • TagPicker takes noPopover, secondaryAction (root and TagPicker.Control, class wave-tag-picker__secondary-action), disabled on options entries, and onOptionCreate(text, details?) (type TagPickerCreateDetails).
  • Spinner takes labelPosition, the sizes extra-tiny, tiny and huge (type SpinnerSize) and a ReactNode label; SpinnerContextProvider gives a default size. ProgressBar takes thickness and shape. Skeleton takes size presets, animation="wave" and appearance="translucent", and Skeleton.Group carries the same defaults (closes spinner-3 to spinner-5, progress-3, progress-4, skeleton-1 to skeleton-3, skeletonitem-1).
  • MessageBar takes shape and politeness. Toast takes appearance="inverted" and showDismissButton. Toaster takes offset, the centered positions top and bottom, inline and announce; dispatch options take position, politeness, priority, pauseOnHover, pauseOnWindowBlur, appearance, showDismissButton and onStatusChange; the controller gains updateToast, pauseToast and playToast, also on createToaster handles (closes messagebar-4, messagebar-5, toast-4, toaster-3, toaster-4, toaster-6 to toaster-9, toastctl-2 to toastctl-4).
  • announce() and useAnnounce take an options object with batchId, priority, deferWhileTyping and ariaNotify (closes announce-1, foundation-30, foundation-31, foundation-32).
  • WaveProvider classNames: app-wide classes by root class ('wave-button': 'rounded-full'), composed after a component's own classes and before its className. They merge key by key through nested providers ('' removes one, null clears all) and reach portaled overlays. Closes the deferred half of foundation-38 (the Phase 13 ruling R17).
  • The built-in glyphs are exported (28 *Icon components, IconProps, IconComponent), each with flipInRtl, and flipIconInRtl(icon) mirrors an icon of your own in right-to-left layouts (closes foundation-42, foundation-44; the Guides/Icons story lists them).
  • Hooks useTimeout, useAnimationFrame, useScrollbarWidth, useApplyScrollbarWidth, useObservedElement and useFocusObserved (closes foundation-29, foundation-41).
  • Accordion takes collapsible={false}, number item values (Accordion<V>), AccordionToggleDetails as the optional second argument of its change callbacks, size, expandIconPosition, and a Trigger expandIcon slot, icon slot (wave-accordion-trigger__icon) and inline (closes acc-1 to acc-5).
  • Card takes disabled, defaultSelected, onSelectionChange(selected, { event }), an optional event on onSelect, and focusMode (closes card-4 to card-6). TabList takes disabled (closes tab-4). Carousel onValueChange(index, details?) reports CarouselChangeDetails (reason, event; closes car-5). Drawer takes mountNode (closes drw-5).
  • Tree takes size, appearance, independentChecks, range selection in a checkbox tree (Ctrl+A, Shift+Space, Shift+Arrow), Tree.Item open, onOpenChange and actionsVisible, and onExpandedItemsChange reports TreeOpenChangeDetails (closes tree-3, tree-5, tree-6).
  • FlatTree navigationMode="treegrid": real WAI-ARIA treegrid roles (treegrid, row, gridcell) with aria-level, aria-posinset, aria-setsize, aria-rowindex and aria-rowcount, and the APG keyboard (rows and cells, Enter or F2 into a cell's controls, Escape back); it works with virtualWindow. renderCells(row) draws the further cells, slotProps.cell and the class wave-flat-tree-item__cell style them. The nested Tree keeps its tree roles (its navigationMode="treegrid" changes the keyboard only).
  • Option groups in data mode: ListboxItem.group and renderGroup(group, { index, size }) (type ListboxGroupRenderState) on Listbox, Combobox and Dropdown draw the items of a group under a header as a named role="group", and a virtualWindow windows them with their headers. Headers are no options, so the keys and typeahead skip them; useListbox onScrollToItem(index, target?) receives the window rows of an option when items have groups. Sticky headers are not supported.
  • NavDrawer takes mountNode, as Drawer does.

Changed

  • MenuButton always reports aria-expanded: "false" unless expanded, a Menu.Trigger or your own aria-expanded says otherwise (closes buttons-12).
  • ToggleButton rendered as an anchor with href and no role no longer renders aria-pressed (not allowed on a link) and warns in development.
  • RadioGroup.Item renders data-label-position, and Slider renders data-orientation, always (enumerated attributes, C-CLASS).
  • A Popover, Menu or other popup opened inside a Dialog or Drawer closes with it (the new reason parent-closed of DismissReason, parent for a Menu), also when the surface is kept mounted or still exiting.
  • Only one Tooltip is shown at a time; it hides while the document is hidden or its anchor is clipped, and never shows over a trigger whose popup is expanded.
  • An import of only Nav no longer includes Button's modules (about 7.5 KiB minified smaller): a Button glyph is recognised by a marker.
  • A surface opened from inside a hover-closing surface, with no trigger and no focused opener, closes along with it without moving focus.
  • The pickers' popup surfaces, the DatePicker calendar and the AvatarGroup popup render data-presence and data-state, and are inert while they exit.
  • The Guides/Charts stories use chartSeries, ink their patterns in background and hide the chart's own markup (aria-hidden) inside the role="img" frame; the guide documents both. The declaration roll-up is built with unplugin-dts instead of vite-plugin-dts (build tooling only).
  • An editable combobox (Combobox, TagPicker, TimePicker) clears the highlight and aria-activedescendant on ArrowLeft, ArrowRight, Home and End, as Fluent does.
  • A Skeleton with no height is 16px tall (it drew no box before); pass height or size to change it.
  • Toasts stay beside an overlay drawer while it slides out, and a toast's shadow stays visible while it fades out.
  • ToastController has three more members (updateToast, pauseToast, playToast): code that implements the type itself must add them.
  • WaveProvider tokens={null} also resets the theme-independent tokens (the ramps, font families, stacking layers, motion) that an enclosing provider overrode.
  • A popup with the default motion (Popover, Menu.Popover, the InfoButton note, the TeachingPopover surface, the DatePicker calendar, the AvatarGroup popup and the picker listbox popups) carries data-presence="exited" for the moment before it is placed, and an open-by-default popup reaches entering only after floating-ui has placed it. The class string of popupMotion grew by six exited classes.
  • The development warning for OptionGroup children beside a virtualWindow points to group and renderGroup.
  • Smaller bundles: the provider's token reset table and useVirtualWindow are leaner (WaveProvider with Dialog -748 B minified, useVirtualWindow -728 B minified and -334 B gzip).

Fixed

  • PresenceBadge no longer throws for a status that is neither a member of PresenceStatus nor one of the removed 0.x names (a misspelled name, different casing, null from server data): it draws 'offline' and, in development, warns once. A throw there unmounted the whole Persona or Avatar around it. A throw from the development warning itself (a console that throws) now surfaces instead of being swallowed with the missing-process case.
  • useSelection clears the details of a change in a finally, so a throw from the update or from onSelectedItemsChange leaves nothing for a later change to report.
  • The rows of a <tfoot> in a windowed DataGrid get aria-rowindex, are counted in aria-rowcount and are reached by the arrow keys, PageUp/PageDown and Ctrl+End.
  • A column resize drag whose end never reaches the handle (WebKit, right to left, a table wider than its wrapper) now ends at a pointerup or pointercancel on the document, or at the next press of the same pointer, instead of leaving data-resizing and data-dragging set.
  • A Tooltip keeps the content it showed while it fades out, and backdropMotion={null} on a non-modal Dialog, Drawer or inline drawer no longer logs the backdrop-ignored warning.
  • createBrandTokens' ramp check and WaveProvider's tokens warnings are no longer skipped when there is no process global (an unbundled import in a browser); production bundles still drop them.
  • A Dropdown opened with a mouse click is focused on pointerdown, so its keys work in WebKit. Combobox, Dropdown, DatePicker, TimePicker and SearchBox move focus to the control when the clear button disappears while focused.
  • A <Fragment ref> around a trigger child, a Tooltip target, a Presence child or an asChild Overflow.Item receives its ref.
  • A selection changed while the TabList line still slides starts the next slide from the line's visible box. A percentage max-height on an Accordion region, a Tree group or a Nav list no longer resolves against the collapsing track. The check cascade of Tree and FlatTree no longer overflows the stack on very deep trees.
  • A popup whose placement flips now enters sliding away from its anchor, not toward it: the surface starts its enter on the side floating-ui resolved (Popover, Menu.Popover, the InfoButton note, the TeachingPopover surface, the DatePicker calendar, the AvatarGroup popup, and the picker listbox popups). Popups with a custom motion string, motion={null} or WaveProvider motion="none" are unchanged.
  • Dialog.Footer stackOnNarrow stacks the actions at a viewport of exactly 480px, as documented (Tailwind's max-[480px] stopped at 479px).

Documentation

  • Input's slotProps.root JSDoc says that, where the root is the <input> itself, a tab stop or roving marker goes through slotProps.input.

Size

Against 1.0.0 as published on npm, measured with this release's build tools (verify-dist's measureImport: a minified production Vite build of an entry that imports the names from dist/index.mjs, bare imports external, gzip by node:zlib; the stylesheets as built, gzip at level 9). Sizes are in bytes:

Import 1.0.0 1.1.0 Growth
dist/styles.css 110,691 (16,555 gzip) 123,260 (18,189 gzip) +12,569 (+1,634 gzip)
dist/components.css (internal) 92,638 (13,299 gzip) 104,544 (14,730 gzip) +11,906 (+1,431 gzip)
dist/utilities.css 62,857 (6,786 gzip) 65,869 (7,138 gzip) +3,012 (+352 gzip)
dist/preflight.css 3,453 (1,272 gzip) 3,453 (1,272 gzip) 0
An import of only Button 12,037 (4,033 gzip) 12,425 (4,205 gzip) +388 (+172 gzip)
An import of only MessageBar 30,070 (10,222 gzip) 30,860 (10,553 gzip) +790 (+331 gzip)
An import of only Tree 51,190 (17,427 gzip) 55,392 (18,773 gzip) +4,202 (+1,346 gzip)
An import of only Dialog 73,934 (24,667 gzip) 75,973 (25,387 gzip) +2,039 (+720 gzip)
An import of WaveProvider and Dialog 76,487 (25,640 gzip) 80,310 (27,319 gzip) +3,823 (+1,679 gzip)
An import of only DataGrid 72,123 (24,325 gzip) 72,132 (24,521 gzip) +9 (+196 gzip)
An import of usePresence and Presence 5,453 (2,341 gzip) 5,648 (2,407 gzip) +195 (+66 gzip)
An import of only useVirtualWindow 3,868 (1,817 gzip) 6,933 (2,783 gzip) +3,065 (+966 gzip)
An import of only createBrandTokens 3,630 (1,956 gzip) 3,630 (1,956 gzip) 0
An import of only waveTokens 3,071 (969 gzip) 3,142 (994 gzip) +71 (+25 gzip)
An import of only Table 33,005 (11,100 gzip) 33,949 (11,897 gzip) +944 (+797 gzip)
An import of only cn 1,062 (532 gzip) 1,062 (532 gzip) 0
An import of only mergeSlotProps 2,782 (1,344 gzip) 2,782 (1,344 gzip) 0
An import of only getNativeElementProps 2,604 (1,214 gzip) 2,604 (1,214 gzip) 0
The npm package 2,415,234 (537 files) 2,678,799 (581 files) +263,565
  • Every component pays for WaveProvider classNames (about 280 bytes in Button: the context read each component makes) and the stylesheets grow with the new utilities. DataGrid stays at its 1.0 size (+9 bytes) although it gained the row and cell focus modes, footer rows and the size variants.
  • useVirtualWindow grows by the measuring path (measureItems), which a fixed-size-only import cannot leave out; Tree by range selection, independent checks, open control and iterative cascades; Dialog by light dismiss, the title element, footer options and mountNode.
  • Budgets: verify-dist gates the ten imports from Button to waveTokens at their size measured at this release plus 512 bytes (192 gzip), and prints each against 0.18.1. Development warnings still ship in production bundles (lib/dev is a function call a minifier cannot fold); gating them behind the literal process.env.NODE_ENV check would save several KB in DataGrid, Dialog and Tree and is left for a later release.

Known limits

  • Real-browser checks of this release ran in Chromium (the popup motion, the Table and DataGrid modes, the Toaster, Tree, Accordion, Card, Dialog, Popover, Tooltip, Menu and Nav additions, and the charts in right-to-left layouts), with the vertical Slider, the DataGrid resize drag, the Combobox popup motion and the Dialog footer also in Firefox and WebKit. Not covered: real touch devices and the Android long-press contextmenu path, forced colors beyond the Tree row actions, the dark theme for the popup, Tree and Menu areas, the flipped enter of Menu.Popover submenus, InfoButton, TeachingPopover and the picker popups in Firefox, WebKit and right-to-left layouts, and the treegrid with a screen reader.
  • Still open (docs/ROADMAP.md §8.1a): the arrow keys between toasts (no screen-reader pattern), real treegrid roles in the nested Tree (use FlatTree navigationMode="treegrid"), sticky headers for option groups, and TagPicker option groups; DataGrid focusMode="row" is ignored with a virtualWindow (a development warning says so), and focusMode="composite" has no counterpart.