19202 Commits

Author SHA1 Message Date
Patrik Oldsberg 21ba6588f9 Lazily load BUI CSS in createDevApp
Move the BUI stylesheet into a lazily rendered helper so importing frontend-dev-utils no longer triggers global CSS side effects.

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-03-16 16:10:28 +01:00
Patrik Oldsberg 1594749d8e Simplify createDevApp options
Accept createApp options at the top level in createDevApp and update the tests, docs, API report, and changeset to match the new shape.

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-03-16 16:10:28 +01:00
Patrik Oldsberg 2e5c65120a Fix PluginHeader ResizeObserver loop
Defer header height updates to avoid ResizeObserver loop warnings in FullPage layouts and normalize header actions before rendering.

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-03-16 16:10:28 +01:00
Patrik Oldsberg 8ea3899944 Add BUI CSS to createDevApp
Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-03-16 16:10:28 +01:00
Patrik Oldsberg 63248c824e Bypass sign-in page in createDevApp
The dev app now automatically disables the sign-in page extension,
so plugins under development don't require authentication.

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-03-16 16:10:28 +01:00
Patrik Oldsberg c25532a7a1 Add @backstage/frontend-dev-utils package
Adds a new `@backstage/frontend-dev-utils` package for the new frontend
system. It provides a minimal `createDevApp` helper for wiring up a
development app from a `dev/` entry point.

The app-visualizer plugin is updated to use this new package as the
initial testing ground.

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-03-16 16:10:27 +01:00
Patrik Oldsberg 3775ef5b51 Merge pull request #33364 from backstage/rugvip/auth-provider-icon-element
frontend-plugin-api: accept IconElement in AuthProviderInfo
2026-03-16 16:10:13 +01:00
Patrik Oldsberg 99d80927bd Merge pull request #33367 from backstage/rugvip/reduce-frontend-plugin-api-surface
frontend-plugin-api: reduce top-level API surface clutter
2026-03-16 16:06:54 +01:00
Patrik Oldsberg d7ff199a69 Merge pull request #33366 from backstage/promote-plugin-wrapper-api
frontend-plugin-api: promote PluginWrapper API to stable with useWrapperValue hook
2026-03-16 16:06:35 +01:00
Charles de Dreuille 2f581de6ba Fixed keyboard navigation
Signed-off-by: Charles de Dreuille <charles.dedreuille@gmail.com>
2026-03-16 14:51:49 +00:00
Johan Persson d9d2dd6827 feat(ui): add SearchAutocomplete component
Add SearchAutocomplete and SearchAutocompleteItem components for
building accessible search-with-results patterns. Built on React
Aria's Autocomplete with virtual focus for keyboard navigation
and a non-modal popover for results.

Features:
- Controlled input via inputValue/onInputChange
- Configurable popover width and placement
- Rich content support per result item
- Item selection via onAction
- defaultOpen prop for visual testing
- Close on interact outside and input clear

Includes Storybook stories, docs-ui documentation, changeset,
and API report.

Signed-off-by: Johan Persson <johanopersson@gmail.com>
2026-03-16 15:41:58 +01:00
Patrik Oldsberg 96e8b060f0 Merge pull request #33355 from backstage/rugvip/cli-plugin-api
cli: add CLI module plugin API and auto-discovery
2026-03-16 14:50:27 +01:00
Patrik Oldsberg 08dbd83cd3 chore: remove redundant cli.ts files from CLI modules
The bin scripts already had the full runCliModule logic for the production
path. Inline the same pattern for local dev and drop the intermediate
src/cli.ts files that just duplicated it.

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-03-16 13:12:00 +01:00
Charles de Dreuille 985788ff6d Move to GridList
Signed-off-by: Charles de Dreuille <charles.dedreuille@gmail.com>
2026-03-16 12:05:48 +00:00
Patrik Oldsberg 92b0f79d9c Make @swc/core an optional peer dependency of cli-node
The node transform config is only loaded at runtime when running
backend processes, so @swc/core should not be a hard dependency
for all cli-node consumers.

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-03-16 13:03:17 +01:00
Patrik Oldsberg 4d081452b1 Address review feedback from freben
- Use cli-defaults instead of listing individual CLI modules in
  create-app template and root package.json
- Move nodeTransform config files from cli-module-build to cli-node
  to avoid cross-module direct imports
- Rename cli-module-create-github-app to cli-module-github
- Start createCliModule init chain with Promise.resolve()
- Deduplicate exitWithError in runCliModule.ts
- Extract shared isCommandNodeHidden to @internal/cli
- Add explanatory comment for fromArray deduplication field
- Restore error for cli role packages missing bin in runCliExtraction

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-03-16 12:55:22 +01:00
Patrik Oldsberg 26eab3bf83 Rename CLI module bin entries to use backstage prefix
Rename all bin entries from `cli-module-*` to `backstage-cli-module-*`
to establish a clear namespace for Backstage CLI tooling.

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-03-16 12:27:08 +01:00
Charles de Dreuille fd1854e3bc Merge pull request #33322 from backstage/jonathanroebuck/bucks-2919-fe-reusable-skeletonloading-state-for-bui-table-components
feat(ui): replace Table loading text with skeleton rows
2026-03-16 11:12:29 +00:00
Charles de Dreuille fdcec89a1a Merge pull request #33354 from backstage/charlesdedreuille/bacui-249-fix-container-bottom-margin-clash-in-bui-oss
fix(ui): fix Container bottom margin clash in Header
2026-03-16 10:28:57 +00:00
Patrik Oldsberg 72991a5211 frontend-plugin-api: remove helper types from top-level API surface
Remove `ResolvedExtensionInput` and `ExtensionDataRefToValue` from
the public API to reduce top-level API clutter. These types were
internal plumbing not needed by plugin authors.

`ResolvedExtensionInput` is now a file-local type only used by
`ResolvedExtensionInputs`. `ExtensionDataRefToValue` is no longer
re-exported from the barrel.

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-03-16 11:21:13 +01:00
Patrik Oldsberg 9508514116 frontend-plugin-api: promote PluginWrapper API to stable with useWrapperValue hook
Promote PluginWrapperApi, pluginWrapperApiRef, PluginWrapperBlueprint, and
the new PluginWrapperDefinition type from @alpha to @public. Add getRootWrapper()
method to PluginWrapperApi and integrate the useWrapperValue hook pattern from
the rugvip/plugin-wrapper branch, allowing plugin wrappers to share stateful
values via a hook that runs once in the root wrapper and is distributed to all
wrapper instances via useSyncExternalStore.

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-03-16 11:19:57 +01:00
Charles de Dreuille d32708ef71 Merge pull request #33353 from backstage/charlesdedreuille/bacui-272-fix-table-row-external-href
fix(ui): open external Table row hrefs in a new tab
2026-03-16 10:16:18 +00:00
Patrik Oldsberg e26e3de81e frontend-plugin-api: accept IconElement in AuthProviderInfo
Update the `icon` field on `AuthProviderInfo` to accept `IconElement`
in addition to `IconComponent`, and update consumers in core-components
and user-settings to handle both types at runtime.

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-03-16 11:07:36 +01:00
Charles de Dreuille af4610d138 Fix types
Signed-off-by: Charles de Dreuille <charles.dedreuille@gmail.com>
2026-03-16 09:52:45 +00:00
Charles de Dreuille 0b0e642d88 Update types.ts
Signed-off-by: Charles de Dreuille <charles.dedreuille@gmail.com>
2026-03-16 09:44:25 +00:00
shivamtiwari3 bc42b608b1 Fix: replace removed --bui-bg-tint tokens in Table component (fixes #33292)
Root cause: The --bui-bg-tint-* CSS tokens were removed from the design system
in favour of --bui-bg-neutral-* tokens, but Table.module.css was not updated
during the migration, leaving row hover, selected, pressed, and disabled states
with no visual effect.

Fix: Replace --bui-bg-tint-hover/pressed/disabled with the equivalent
--bui-bg-neutral-1-hover/pressed/disabled tokens, matching the migration
mapping documented in the CHANGELOG.

Signed-off-by: shivamtiwari3 <33183708+shivamtiwari3@users.noreply.github.com>
2026-03-16 10:41:06 +05:30
Patrik Oldsberg b76bbfb461 Exclude cli-report files from stale API report detection
The runApiExtraction function was detecting cli-report.md files as
stale API reports because they matched the report filename pattern.
These files are managed by runCliExtraction instead and should be
excluded from the stale report check.

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-03-15 23:54:51 +01:00
Patrik Oldsberg ac96393a12 Fix jest peer dependency in cli-module-test-jest
Change peer dependency from jest-cli to jest to match the actual
runtime usage of require('jest') and the original @backstage/cli
peer dependency declaration.

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-03-15 23:30:19 +01:00
Patrik Oldsberg 6395e35c6a Generate CLI reports for cli-module packages
Include cli-module role in CLI report generation alongside the
existing cli role. Packages without a bin field are silently skipped.

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-03-15 23:12:59 +01:00
Patrik Oldsberg 55f6eb8c64 Move config files to CLI modules with lazy proxies
Move jest config files to cli-module-test-jest/config and node
transform + webpack-public-path to cli-module-build/config. Replace
originals in @backstage/cli/config with lazy proxies that forward
to the appropriate module or throw if it is not installed.

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-03-15 22:11:43 +01:00
Patrik Oldsberg 00adaa9902 Restore findOwnPaths for serve_index.html in build module
Move serve_index.html to cli-module-build/templates and use
findOwnPaths instead of require.resolve for safer path resolution.

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-03-15 22:01:41 +01:00
Patrik Oldsberg 2069f64201 Remove extra exports from CLI module packages
CLI modules should only export the module itself as a default export.
Remove the named `buildPlugin` export from cli-module-build and the
unused `configOption` export from cli-module-config. Also remove the
API report warning skip for CLI module packages.

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-03-15 21:51:07 +01:00
Patrik Oldsberg 7879215cca Add CLI module deduplication and improve conflict reporting
Individual CLI modules now silently take precedence over array-sourced
modules (e.g. from cli-defaults) when their commands overlap. Conflict
errors between non-array modules include both package names for easier
debugging.

Commands reference their parent module instead of storing a raw package
name string. createCliModule now validates that packageJson has a name.

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-03-15 21:16:00 +01:00
Charles de Dreuille b2110c19c6 Update CardsWithListBox.stories.tsx
Signed-off-by: Charles de Dreuille <charles.dedreuille@gmail.com>
2026-03-15 19:10:58 +00:00
Patrik Oldsberg 4f2d7d555b Add README files to CLI module packages
Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-03-15 15:03:35 +01:00
Patrik Oldsberg 7781ae5911 Add @backstage/cli-defaults package
Introduces a new `@backstage/cli-defaults` package that re-exports all
standard CLI modules as a single array, simplifying dependency management
for consumers. The CLI's `CliInitializer` is updated to support array
exports alongside single module exports. The create-app template,
changesets, and CLI fallback are updated to use `@backstage/cli-defaults`
instead of listing 11 individual modules.

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-03-15 15:01:35 +01:00
Patrik Oldsberg 7db7ca5714 Convert discovered module paths to file URLs for Windows compatibility
On Windows, require.resolve() returns paths like D:\...\index.cjs.js
which when passed to import() causes ERR_UNSUPPORTED_ESM_URL_SCHEME
because the D: prefix is interpreted as a URL protocol. Use
pathToFileURL() to produce proper file:// URLs.

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-03-15 13:35:12 +01:00
Patrik Oldsberg 47b50ef3c4 Add back @types/webpack-env to CLI dependencies
The CLI provides tsconfig presets that include webpack-env in the
types array, so @types/webpack-env must remain a dependency of the
CLI package for consuming apps to compile correctly.

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-03-15 12:56:32 +01:00
Patrik Oldsberg 9937a8aa8e Clean up CLI module dependencies and revert incorrect require() changes
Align dependency versions in CLI modules to match the original CLI
package versions. Move dependencies that are only used by modules out
of the main CLI package, and add missing dependencies to the modules
that actually use them. Revert import-to-require conversions in
cli-module-build that were incorrectly introduced during the split.

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-03-15 12:40:25 +01:00
Charles de Dreuille 668639722c Cleanups
Signed-off-by: Charles de Dreuille <charles.dedreuille@gmail.com>
2026-03-15 08:39:46 +00:00
Charles de Dreuille 9ee2931cc8 Improve styles
Signed-off-by: Charles de Dreuille <charles.dedreuille@gmail.com>
2026-03-15 08:32:41 +00:00
Patrik Oldsberg ff593fa8fa Capture stderr in E2E plugin creation step
Keep stderr capture from the plugin creation child process to aid
debugging if the command fails in the future.

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-03-15 02:11:14 +01:00
Patrik Oldsberg 2c952496bf Use static imports for version extraction in cli-module-new
Convert dynamic require() calls to static import statements so that
Rollup can inline the version values at build time. The cli-module role
uses preserveModules in Rollup, which cannot resolve dynamic requires.

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-03-15 01:40:26 +01:00
Patrik Oldsberg 99af21a711 Add stderr logging to E2E plugin creation step
Capture and print stdout and stderr when the plugin creation command
fails, so that the actual error is visible in CI logs.

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-03-15 01:26:54 +01:00
Patrik Oldsberg 935c646e89 Fix CLI module discovery and create-app test mock
Resolve CLI module entry points relative to the target project root
rather than relying on bare module name resolution. This ensures modules
are found even when the CLI package is symlinked from a separate location,
such as in the E2E test workspace setup.

Also add the missing cli-module-* entries to the create-app tasks test
mock that were omitted in a previous commit.

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-03-15 01:12:43 +01:00
Patrik Oldsberg f100c26c92 Fix relative paths in cli-module-translations test
The test file was moved from packages/cli/src/modules/translations/lib/
to packages/cli-module-translations/src/lib/ but the relative paths to
the repo root tsconfig.json and test fixtures were not updated.

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-03-14 20:25:16 +01:00
Charles de Dreuille 2b1bb9ca3e feat(ui): add customActions prop to ListBoxItem
Adds a `customActions` prop that renders a flex row of React nodes on
the right side of a list item. Click and keyboard events on the actions
area are stopped from propagating to the item's selection handler.

Adds two new stories:
- WithActionsMenu: ButtonIcon (ellipsis) triggering a dropdown Menu
- WithActionsTags: inline TagGroup showing metadata tags per item

Signed-off-by: Charles de Dreuille <charles.dedreuille@gmail.com>
Made-with: Cursor
2026-03-14 18:17:03 +00:00
Charles de Dreuille b7b1b86d8a fix(ui): update ListBox item check and icon design
- Check icon is now only rendered when the item is selected, so it
  takes no space when unselected and pushes content in when selected
- Icon slot is now a fixed 32x32px box to consistently frame any
  React icon component (e.g. from Remix icons)

Signed-off-by: Charles de Dreuille <charles.dedreuille@gmail.com>
Made-with: Cursor
2026-03-14 18:11:39 +00:00
Patrik Oldsberg 2fae035613 Move @types packages to devDependencies in cli-module-config and cli-module-create-github-app
Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-03-14 17:12:41 +01:00
Patrik Oldsberg 95a5771b47 Fix remaining undeclared imports in cli-module-new and cli-module-test-jest
Add missing devDependencies to cli-module-new and add cleye, yargs,
and jest-cli peer dependency to cli-module-test-jest.

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-03-14 16:57:58 +01:00