803 Commits

Author SHA1 Message Date
Johan Persson 1f709a386b fix(ui): preserve Header breadcrumb typography
Increase the specificity of Header breadcrumb styles so that Link defaults do not override contextual typography when stylesheets are loaded in a different order.

Add a patch changeset for @backstage/ui.

Signed-off-by: Johan Persson <johanopersson@gmail.com>
2026-06-01 11:32:46 +02:00
Charles de Dreuille c2f9d8c25d Merge pull request #34400 from backstage/feat/bui-token-redesign
feat(ui): introduce semantic color token families and deprecate legacy tokens
2026-05-29 15:40:20 +01:00
Charles de Dreuille a4f2c56110 Bring back correct neutral tokens
Signed-off-by: Charles de Dreuille <charles.dedreuille@gmail.com>
2026-05-29 15:59:39 +02:00
James Brooks b33bb24b5a Add NumberField component to @backstage/ui (#34264)
* Add NumberField component to @backstage/ui

Signed-off-by: James Brooks <jamesbrooks@spotify.com>

* Address review feedback on NumberField

Signed-off-by: James Brooks <jamesbrooks@spotify.com>

* Fix NumberField CSS formatting

Signed-off-by: James Brooks <jamesbrooks@spotify.com>

* Add increment/decrement buttons to NumberField

Signed-off-by: James Brooks <jamesbrooks@spotify.com>

* Fix NumberField looking disabled at min/max bounds

Signed-off-by: James Brooks <jamesbrooks@spotify.com>

---------

Signed-off-by: James Brooks <jamesbrooks@spotify.com>
2026-05-27 17:20:27 +02:00
Charles de Dreuille 657aad6cf0 refactor(ui): rename surface tokens to neutral background tokens
Replace --bui-surface-1..5 with --bui-bg-neutral-1..5 for both light
and dark themes. --bui-bg-neutral-1 replaces the deprecated --bui-bg-app,
and --bui-bg-neutral-2..5 extend the scale. The old bare --bui-bg-neutral-1..4
entries are removed from the deprecated section since their names are now
reused; the hover/pressed/disabled variants remain deprecated.

Updates colors.stories.tsx, the ESLint rule and tests, and all migration
documentation and the PR description accordingly.

Signed-off-by: Charles de Dreuille <charles.dedreuille@gmail.com>
2026-05-27 13:11:38 +02:00
Charles de Dreuille c2966d6a84 Update tokens.css
Signed-off-by: Charles de Dreuille <charles.dedreuille@gmail.com>
2026-05-26 22:06:28 +02:00
Charles de Dreuille 5d80f77e43 chore: add changesets and fix colors story layout
- Add patch changeset for @backstage/ui (new semantic color token families)
- Add patch changeset for @backstage/eslint-plugin (no-deprecated-bui-tokens rule)
- Remove redundant wrapper div in the Colors story and drop minHeight
  that was preventing scroll in the Storybook canvas

Signed-off-by: Charles de Dreuille <charles.dedreuille@gmail.com>
2026-05-26 21:25:52 +02:00
Charles de Dreuille d38977c7b4 feat(ui): introduce semantic color token families and deprecate legacy tokens
Redesigns the BUI color token system in `@backstage/ui`:

- Adds a gray scale (`--bui-gray-1` through `--bui-gray-11`)
- Adds new foreground tokens with explicit hex values (primary, secondary, disabled, positive, negative, warning, announcement)
- Introduces five new semantic color families — Accent, Announcement, Warning, Negative, Positive — each with bg-base, bg-subdued, border, fg-on-base, and fg-on-subdued variants, for both light and dark themes
- Moves all legacy tokens (`--bui-bg-solid-*`, `--bui-bg-neutral-*`, `--bui-bg-danger/warning/success/info`, `--bui-fg-solid`, `--bui-fg-danger/success/info`, `--bui-border-*`, `--bui-shadow`) into a clearly marked `/* Deprecated tokens */` section in both light and dark themes
- Updates the Spotify theme overrides to use the new accent tokens and mark legacy overrides as deprecated
- Rewrites the `Colors` Storybook story to display all token families as a live, theme-aware reference grid
- Adds a new `@backstage/no-deprecated-bui-tokens` ESLint rule to `@backstage/eslint-plugin` that warns when any deprecated BUI token is referenced in JS/TS string literals; the rule is included in the `recommended` config so it applies to all plugin authors automatically

Signed-off-by: Charles de Dreuille <charles.dedreuille@gmail.com>
2026-05-26 15:08:53 +02:00
github-actions[bot] b97fcb0a93 Version Packages 2026-05-19 18:28:24 +00:00
Fredrik Adelöw eab8f7a510 Merge pull request #34256 from backstage/cursor/ui-field-flex
fix(ui): allow fields to grow in flex layouts
2026-05-16 16:53:46 +02:00
Fredrik Adelöw c667c2bf90 Merge pull request #34262 from backstage/chore/upgrade-storybook-10.4 2026-05-15 19:10:05 +02:00
Charles de Dreuille 18aa6e4d56 Merge pull request #34151 from backstage/password
Style PasswordField like TextField
2026-05-15 14:22:17 +01:00
Charles de Dreuille e6e796e45c chore(deps): update storybook monorepo to v10.4.0
Signed-off-by: Charles de Dreuille <charles.dedreuille@gmail.com>
2026-05-15 10:29:56 +01:00
Charles de Dreuille 5520e07992 fix(ui): allow fields to grow in flex layouts
Signed-off-by: Charles de Dreuille <charles.dedreuille@gmail.com>
2026-05-14 15:39:41 +01:00
Charles de Dreuille 3e0ff6c240 fix(ui): align header sections with container
Add container layout to Header sections so the title, actions, tags, metadata, and tabs align with surrounding page content.

Signed-off-by: Charles de Dreuille <charles.dedreuille@gmail.com>
2026-05-13 17:44:07 +01:00
github-actions[bot] 42a2f56e61 Version Packages (next) 2026-05-12 18:28:01 +00:00
Erik Hughes d726bcd842 feat(ui): add DatePicker component (#34184)
* feat(ui): add DatePicker component

Add a single-date picker built on React Aria's DatePicker, mirroring the
existing DateRangePicker implementation. Includes the date field with
segmented input, calendar popover, BUI design tokens, bg consumer
pattern, and full keyboard/screen reader accessibility.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Signed-off-by: Erik Hughes <erikh@spotify.com>

* fix(ui): address DatePicker PR feedback

- Remove unused dataAttributes spread from DatePickerGroup
- Mark DatePickerGroupDefinition and DatePickerCalendarDefinition as
  public so CSS class name changes appear in API reports
- Add Affected components line to changeset

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Signed-off-by: Erik Hughes <erikh@spotify.com>

* fix(ui): restore dataAttributes spread in DatePickerGroup

The bg: 'consumer' config on DatePickerGroupDefinition emits
data-on-bg attributes via useDefinition. Without spreading
dataAttributes onto <Group>, the CSS [data-on-bg] selectors
never match and background auto-increment doesn't work.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Signed-off-by: Erik Hughes <erikh@spotify.com>

---------

Signed-off-by: Erik Hughes <erikh@spotify.com>
Co-authored-by: Erik Hughes <erikh@spotify.com>
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-05-12 10:46:46 +02:00
Johan Persson 4bb649d511 fix(ui): prevent selection checkboxes from creating phantom scroll height
Add `position: relative` to `.bui-Table` so it becomes the containing
block for react-aria's absolutely positioned hidden checkbox inputs.

Without this, the inputs position themselves relative to a distant
ancestor, extending its scrollable area and creating phantom scroll
height.

Signed-off-by: Johan Persson <johanopersson@gmail.com>
2026-05-07 16:39:02 +02:00
James Brooks 11699ac31f Style PasswordField like TextField
Signed-off-by: James Brooks <jamesbrooks@spotify.com>
2026-05-07 14:10:31 +01:00
github-actions[bot] b0bc1e5cc9 Version Packages (next) 2026-05-05 14:57:07 +00:00
Johan Persson 25909ba27a feat(ui): add searchDebounceMs/filterDebounceMs to useTable complete mode (#34127)
* feat(ui): add internal useDebouncedValue hook for Table

Signed-off-by: Johan Persson <johanopersson@gmail.com>

* feat(ui): expose searchDebounceMs and filterDebounceMs on UseTableCompleteOptions

Signed-off-by: Johan Persson <johanopersson@gmail.com>

* feat(ui): debounce search/filter in useTable complete mode pipeline

Signed-off-by: Johan Persson <johanopersson@gmail.com>

* docs(ui): add SearchWithDebounce Table dev story

Signed-off-by: Johan Persson <johanopersson@gmail.com>

* docs(ui): document searchDebounceMs/filterDebounceMs and fix Table search note

Signed-off-by: Johan Persson <johanopersson@gmail.com>

* docs(ui): add searchDebounceMs/filterDebounceMs to Table props reference

Signed-off-by: Johan Persson <johanopersson@gmail.com>

* docs(ui): note controlled-callback behavior on Table debounce props

Signed-off-by: Johan Persson <johanopersson@gmail.com>

* chore(ui): regenerate API report for useTable debounce options

Signed-off-by: Johan Persson <johanopersson@gmail.com>

* chore(ui): changeset for useTable complete-mode debounce options

Signed-off-by: Johan Persson <johanopersson@gmail.com>

* chore: accept 'debouncing' in Vale vocabulary

Signed-off-by: Johan Persson <johanopersson@gmail.com>

---------

Signed-off-by: Johan Persson <johanopersson@gmail.com>
2026-05-05 16:45:18 +02:00
James Brooks ddca41f775 Add Combobox component to Backstage UI (#34118)
Introduces a Combobox component to Backstage UI for times when you want to allow users to choose from a list of values but also specify their own in some cases.

---------

Signed-off-by: James Brooks <jamesbrooks@spotify.com>
2026-05-05 15:29:15 +01:00
Johan Persson 37535b2a60 feat(ui): add --bui-bg-inherit CSS variable (#34124)
* feat(ui): add --bui-bg-inherit CSS variable in core.css

Signed-off-by: Johan Persson <johanopersson@gmail.com>

* refactor(ui): remove duplicated data-bg painting from Box.module.css

Signed-off-by: Johan Persson <johanopersson@gmail.com>

* refactor(ui): remove duplicated data-bg painting from Flex.module.css

Signed-off-by: Johan Persson <johanopersson@gmail.com>

* refactor(ui): remove duplicated data-bg painting from Grid.module.css

Signed-off-by: Johan Persson <johanopersson@gmail.com>

* refactor(ui): centralize Accordion data-bg painting, preserve no-intent behavior

Signed-off-by: Johan Persson <johanopersson@gmail.com>

* refactor(ui): use --bui-bg-inherit for Card scroll-shadow gradients

Signed-off-by: Johan Persson <johanopersson@gmail.com>

* docs(ui): document --bui-bg-inherit token

Signed-off-by: Johan Persson <johanopersson@gmail.com>

* chore: changeset for --bui-bg-inherit

Signed-off-by: Johan Persson <johanopersson@gmail.com>

* docs(ui): add Storybook story for --bui-bg-inherit

Signed-off-by: Johan Persson <johanopersson@gmail.com>

* docs(ui): fold --bui-bg-inherit story into colors stories

Signed-off-by: Johan Persson <johanopersson@gmail.com>

* changeset: Reword for clarity.

Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Signed-off-by: Johan Persson <johanopersson@gmail.com>

---------

Signed-off-by: Johan Persson <johanopersson@gmail.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
2026-05-05 16:00:47 +02:00
Emma Indal 9c16bf9707 fix(ui): render focus ring on Link via data-focus-visible
Style the bui-Link itself when keyboard-focused using the ring token,
matching the established pattern from ButtonLink. Also tweak the
changeset wording to reflect the new behavior.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Signed-off-by: Emma Indal <emma.indahl@gmail.com>
2026-05-05 09:48:53 +02:00
Emma Indal 5b85902ede fix(ui): show focus indicator on Card when used as a link
Card's focus-ring CSS keys off data-focus-visible on the
bui-CardTrigger, but Link (the trigger when href is set) wasn't
emitting it because useLink does not track focus-visible state.
Compose useFocusRing in Link so keyboard focus is now properly
indicated on Card href=... and any other Link styled via
[data-focus-visible].

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Signed-off-by: Emma Indal <emma.indahl@gmail.com>
2026-05-04 17:18:52 +02:00
Charles de Dreuille eecd8130dc fix(ui): tune plugin header core spacing
Signed-off-by: Charles de Dreuille <charles.dedreuille@gmail.com>
2026-05-04 08:41:17 +01:00
Charles de Dreuille 36825fe290 Update PluginHeaderAndHeader.stories.tsx
Signed-off-by: Charles de Dreuille <charles.dedreuille@gmail.com>
2026-04-30 15:01:45 +01:00
Charles de Dreuille 4955e51e07 fix(ui): handle core page after plugin header
Signed-off-by: Charles de Dreuille <charles.dedreuille@gmail.com>
2026-04-30 09:56:17 +01:00
Charles de Dreuille 021b36800f fix(ui): collapse plugin header spacing before headers
Signed-off-by: Charles de Dreuille <charles.dedreuille@gmail.com>
2026-04-30 09:33:18 +01:00
Charles de Dreuille a9f3d7189f Update PluginHeader.tsx
Signed-off-by: Charles de Dreuille <charles.dedreuille@gmail.com>
2026-04-29 19:07:59 +01:00
Charles de Dreuille 93d1d40e64 fix(ui): refine plugin header spacing
Signed-off-by: Charles de Dreuille <charles.dedreuille@gmail.com>
2026-04-29 19:07:59 +01:00
Charles de Dreuille 38bb056aa6 fix(ui): adjust plugin header spacing
Align PluginHeader spacing across tabbed and non-tabbed variants so the component owns the surrounding page spacing more consistently.

Signed-off-by: Charles de Dreuille <charles.dedreuille@gmail.com>
2026-04-29 19:07:59 +01:00
github-actions[bot] 7295193bb6 Version Packages (next) 2026-04-28 15:53:09 +00:00
James Brooks e7fc79fb13 Add support for sections to Select (#34012)
Updates the Select component to accept a set of sections with options as opposed to just a flat list of options.

---------

Signed-off-by: James Brooks <jamesbrooks@spotify.com>
2026-04-28 16:13:39 +01:00
Charles de Dreuille ca53b86336 Merge pull request #34067 from backstage/cursor/header-sticky-prop
BUI - Add sticky Header support
2026-04-27 14:20:23 +01:00
Charles de Dreuille de75f7c0f4 fix(ui): set CardBody minimum height
Signed-off-by: Charles de Dreuille <charles.dedreuille@gmail.com>
2026-04-27 08:56:12 +01:00
Charles de Dreuille ec93dd281a fix(ui): always render headerTop, adjust content padding, add story
- Always render headerTop wrapper for consistent spacing
- Reduce default content padding-top from space-6 to space-3
- Add PluginHeaderAndHeader story and update Spotify theme

Signed-off-by: Charles de Dreuille <charles.dedreuille@gmail.com>
2026-04-26 21:15:42 +01:00
Charles de Dreuille 7b0c998fea fix(ui): remove unused root class name from HeaderDefinition
Signed-off-by: Charles de Dreuille <charles.dedreuille@gmail.com>
2026-04-26 20:57:57 +01:00
Charles de Dreuille 84f151c5ee fix(ui): simplify HeaderTop padding-top to always use space-6
Signed-off-by: Charles de Dreuille <charles.dedreuille@gmail.com>
2026-04-26 20:52:54 +01:00
Charles de Dreuille 8a0a5c9553 feat(ui): improve Header layout with tag-aware padding and renamed sections
- Add data-has-tags attribute to reduce header padding-top when tags are present
- Rename beforeSticky/afterSticky classes to headerTop/headerBottom
- Always render headerBottom for consistent bottom margin
- Inline JSX sections into a single return statement

Signed-off-by: Charles de Dreuille <charles.dedreuille@gmail.com>
2026-04-26 20:36:24 +01:00
Charles de Dreuille 0e71545ee6 Preserve Header className target
Signed-off-by: Charles de Dreuille <charles.dedreuille@gmail.com>
2026-04-26 17:36:18 +01:00
Charles de Dreuille 68d1f91c91 Avoid hidden duplicate Header links
Signed-off-by: Charles de Dreuille <charles.dedreuille@gmail.com>
2026-04-26 16:07:50 +01:00
Charles de Dreuille aa56d03cd2 Unify Header landmark structure
Signed-off-by: Charles de Dreuille <charles.dedreuille@gmail.com>
2026-04-26 15:43:41 +01:00
Charles de Dreuille fc6f0d98e0 Remove display contents from sticky Header
Signed-off-by: Charles de Dreuille <charles.dedreuille@gmail.com>
2026-04-26 15:29:36 +01:00
Charles de Dreuille 6b05c0a4de Address sticky Header review feedback
Signed-off-by: Charles de Dreuille <charles.dedreuille@gmail.com>
2026-04-26 15:20:12 +01:00
Charles de Dreuille 6c4606a71c Polish sticky Header implementation
Signed-off-by: Charles de Dreuille <charles.dedreuille@gmail.com>
2026-04-26 15:05:45 +01:00
Charles de Dreuille dceca05fb4 Fix non-sticky Header title duplication
Signed-off-by: Charles de Dreuille <charles.dedreuille@gmail.com>
2026-04-26 14:16:09 +01:00
Charles de Dreuille eb1fabae6b Refine sticky Header title transition
Signed-off-by: Charles de Dreuille <charles.dedreuille@gmail.com>
2026-04-26 09:26:12 +01:00
Charles de Dreuille 5351d8ac63 Add sticky Header support
Signed-off-by: Charles de Dreuille <charles.dedreuille@gmail.com>
2026-04-26 09:04:51 +01:00
Charles de Dreuille 030fb311aa Merge pull request #33997 from backstage/charlesdedreuille/act-355-header-improvements
feat(ui): add description, tags, and metadata props to Header
2026-04-24 13:59:56 +01:00