Commit Graph

72910 Commits

Author SHA1 Message Date
Patrik Oldsberg 86b9839044 Fix override name in catalog-graph README
The entity card override example used `name: 'entity-relations'` but
the actual extension uses `name: 'relations'`.

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-04-13 22:31:29 +02:00
Patrik Oldsberg 8923d6def0 Drop Zod v3 support from new configSchema path
The new `configSchema` option now strictly requires StandardSchemaV1
values (e.g. Zod v4 or `zod/v4` from the Zod v3 package). Direct Zod
v3 schemas are no longer silently converted and will throw an error.

The deprecated `config.schema` callback path continues to work with
Zod v3 through a separate `createDeprecatedConfigSchema` function.

Also adds `createZodV4FilterPredicateSchema` to `@backstage/filter-predicates`
as a v4 counterpart to the now-deprecated v3 variant.

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-04-13 21:38:28 +02:00
Patrik Oldsberg 25392cab00 Use StandardSchemaV1.InferOutput/InferInput utility types
Replace raw NonNullable<T['~standard']['types']>['output'] access
with the canonical StandardSchemaV1.InferOutput and InferInput
utility types for improved readability.

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-04-12 19:17:39 +02:00
Patrik Oldsberg 5b6061ac77 Address review feedback: zod import path and legacy route ref
Use explicit zod/v4 import path in tests, and remove unnecessary
convertLegacyRouteRef wrapper in catalog-graph README.

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-04-10 16:54:06 +02:00
Patrik Oldsberg 461d4fc48b Clean up parse output and schema enumerability
Skip assigning undefined keys for absent optional fields in parse,
matching the previous zod-object behavior. Make the schema getter
non-enumerable so JSON.stringify on the portable schema only
serializes parse and _fields.

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-04-10 15:09:02 +02:00
Patrik Oldsberg 27f6fb30e7 Update SearchResultListItemBlueprint snapshot
The inline snapshot was stale after the PortableSchema internal
representation changed to use lazy schema and _fields structure.

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-04-10 14:42:40 +02:00
Patrik Oldsberg fe8473b5f1 Fix review feedback: override warnings and search docs
Add explicit deprecation warnings in override and makeWithOverrides when
config.schema is used, since the merged result now passes through
configSchema. Update search declarative-integration docs to use
SearchResultListItemBlueprint instead of the removed extension creator.

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-04-10 13:58:38 +02:00
Patrik Oldsberg 27bc970c91 Fix review feedback: override warning, input guard, required tests
Pass merged config schemas via configSchema instead of config.schema in
the override method to avoid false deprecation warnings. Add type guard
for non-object inputs in parse. Add tests for defaulted field required
semantics (already correct) and invalid input types.

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-04-10 13:16:25 +02:00
Patrik Oldsberg 8330f1319a frontend-plugin-api: restore @ignore on internal utility types
Route createExtension overloads through CreateExtensionOptions so that
ResolvedExtensionInputs, VerifyExtensionFactoryOutput, VerifyExtensionAttachTo,
and RequiredExtensionIds can remain @ignore without ae-forgotten-export warnings.

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-04-10 12:52:59 +02:00
Patrik Oldsberg effa7bf459 Fix missing changesets and tsc errors from CI
Add changesets for plugin-app and plugin-catalog-graph. Fix cross-style
merge test to use direct schema values with configSchema instead of
factory functions.

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-04-10 12:26:25 +02:00
Patrik Oldsberg a2a6c3b72e Add migration docs and changeset for new configSchema option
Add 1.50 migration section documenting the config.schema to configSchema
migration with examples for createExtension, createExtensionBlueprint,
and makeWithOverrides. Add a separate changeset for the new feature and
update the existing breaking changeset to reference the migration docs.

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-04-10 11:51:22 +02:00
Patrik Oldsberg 540a03171c Add missing changeset and test coverage for PR review gaps
Add changeset for catalog-react blueprint migration. Add tests for
cross-style config merge (configSchema + deprecated config.schema),
deprecation warning emission, and empty configSchema edge case.

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-04-10 11:28:38 +02:00
Patrik Oldsberg 2d89e198bd frontend-plugin-api: remove deprecated createSchemaFromZod
The helper is no longer used internally and has been replaced by
the `configSchema` option with direct Standard Schema values.

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-04-10 11:18:03 +02:00
Patrik Oldsberg 1e6d2e91ad frontend-plugin-api: thorough error message tests for portable schema
Cover zod v3, zod v4, mixed, and merged schema error messages
with exact string assertions to document the error format produced
for missing fields, type mismatches, nested paths, and multi-field
errors.

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-04-10 11:13:27 +02:00
Patrik Oldsberg 3218028048 docs: update extension config schema examples to new configSchema format
Switch all documentation examples from the deprecated
`config: { schema: { field: z => z.type() } }` pattern to the new
`configSchema: { field: z.type() }` format using zod v4 imports.
Also update catalog-graph README to use current blueprint APIs.

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-04-10 10:58:21 +02:00
Patrik Oldsberg 1ef7954725 Migrate catalog-react and app blueprints to configSchema
Move EntityCardBlueprint and EntityContentBlueprint to the new
`configSchema` option using zod v3, and AppLanguageApi to zod v4.
Fix config schema merge in `makeWithOverrides` when mixing
`configSchema` and deprecated `config.schema` sources.

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-04-10 10:39:50 +02:00
Patrik Oldsberg 8bb8560557 frontend-plugin-api: always warn on deprecated config.schema with call site
Instead of a one-time warning, emit a deprecation warning every time
an extension is created using the deprecated `config.schema` option,
including the call site location to help track down each usage.

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-04-10 10:19:51 +02:00
Patrik Oldsberg 426d1b389f frontend-plugin-api: clean up comments in createPortableSchema
Replace box-style section comments with TSDoc comments to match
the style used throughout the rest of the repository.

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-04-10 10:17:35 +02:00
Patrik Oldsberg 1f80e1a5a4 frontend-plugin-api: per-field config schema with lazy JSON Schema
Replace the monolithic `createSchemaFromZod` approach with per-field
schema resolution via `createConfigSchema`. Each field is resolved
individually and eagerly validated for JSON Schema conversion support,
but the actual JSON Schema generation is deferred until first access.

`PortableSchema.schema` is now a lazy callable — it can still be
accessed as a property (backward compat, deprecated) or called as a
method returning `{ schema: JsonObject }` for the new API.

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-04-10 10:13:19 +02:00
Patrik Oldsberg 0d398f3271 frontend-plugin-api: remove ConfigFieldSchema and fix API report warnings
Remove the `ConfigFieldSchema` and `ConfigSchemaRecord` types that are
no longer needed now that `configSchema` and `config.schema` each accept
only one form. The deprecated overloads now constrain directly to the
factory signature `(zImpl: typeof z) => z.ZodType`.

Also fix pre-existing API report warnings by promoting
`ResolvedExtensionInputs`, `RequiredExtensionIds`,
`VerifyExtensionFactoryOutput`, and `VerifyExtensionAttachTo` to
`@public` and exporting them from both entry points.

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-04-10 09:21:40 +02:00
Patrik Oldsberg 4c7905d22c frontend-plugin-api: add configSchema option and deprecate config.schema
Introduce a new top-level `configSchema` option for `createExtension`,
`createExtensionBlueprint`, `override`, and `makeWithOverrides` that
accepts Standard Schema values directly. The old `config.schema` form
is deprecated via function/method overloads so that the entire call
site gets editor strikethrough when matched.

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-04-10 08:54:43 +02:00
Patrik Oldsberg 787200224e frontend-plugin-api: use @standard-schema/spec dependency instead of inlining
Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-04-09 18:45:20 +02:00
Patrik Oldsberg 23a35d1b91 frontend-plugin-api: widen config schema constraint to accept Standard Schema
Widens the TConfigSchema generic constraint in createExtension,
createExtensionBlueprint, and their override/makeWithOverrides methods
to accept both the existing zod factory form and direct Standard Schema
instances via the new ConfigFieldSchema union type.

Existing consumers are unaffected — the factory form continues to
infer concrete types through z.infer<ReturnType<...>>. Direct Standard
Schema values are accepted but infer as any in the current iteration.

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-04-09 16:36:00 +02:00
Patrik Oldsberg 7169cd543c exploration: Standard Schema utility for zod version decoupling
Adds a mock/exploration file showing what a central Standard-Schema-based
utility could look like for decoupling the exact zod version from the
public API surface of extension config schemas.

This is not wired into anything — just saving progress on the design
exploration for per-field validation, JSON Schema generation, and
schema merging across different sources (blueprint + override) that
may use different schema libraries or zod versions.

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-04-08 11:18:58 +02:00
Patrik Oldsberg 5c9b621ffb Merge pull request #33760 from backstage/rugvip/parter-cleanup
docs: update commercial partners and FAQ
2026-04-05 21:59:29 +02:00
Patrik Oldsberg f0fb2aec37 microsite: prettier fix
Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
2026-04-05 21:49:16 +02:00
Patrik Oldsberg 76fdf2cb31 docs: update FAQ about commercial Backstage offerings
Update the question about hosted/commercial versions of Backstage
to be vendor-neutral and link to the commercial partners page.

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-04-05 19:38:20 +02:00
Patrik Oldsberg ee18ff20c5 microsite: update commercial partners list
Remove solo.io, VMware, and Alauda as commercial partners due to
broken/irrelevant landing pages. Add Spotify for Backstage as a
partner. Sort partners alphabetically and normalize logo sizes
with per-partner height control.

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-04-05 19:26:33 +02:00
Patrik Oldsberg 262bc296a4 Merge pull request #33754 from kurtaking/migrate-google-pubsub-alpha-metrics
Migrate to MetricsService
2026-04-05 12:04:14 +02:00
Kurt King ea0d31a1bc Merge branch 'master' of https://github.com/backstage/backstage into migrate-google-pubsub-alpha-metrics 2026-04-04 13:33:39 -06:00
Fredrik Adelöw 98d9a75dc2 Merge pull request #33632 from wpessers/feat/github-catalog-backend-extensiont/add-retry-to-github-client
feat(catalog): add retries to octokit client
2026-04-04 17:20:22 +02:00
Fredrik Adelöw c59dccbaf5 Merge pull request #33745 from backstage/freben/permissions-cleanup-step-2
refactor(catalog-node,catalog-backend): permissions cleanup step 2
2026-04-03 22:15:57 +02:00
Charles de Dreuille d10fbd3e29 Merge pull request #33744 from backstage/bui-badge 2026-04-03 20:40:08 +01:00
Fredrik Adelöw 056e18e4bf refactor(catalog-node,catalog-backend): permissions cleanup step 2
Remove the deprecated alpha exports CatalogPermissionRuleInput,
CatalogPermissionExtensionPoint, and catalogPermissionExtensionPoint
from catalog-node, and remove the corresponding CatalogPermissionExtensionPointImpl,
addPermissions, and addPermissionRules from catalog-backend. Custom permission
rules and permissions are now registered via coreServices.permissionsRegistry.

Signed-off-by: Fredrik Adelöw <freben@spotify.com>
Made-with: Cursor
2026-04-03 21:36:46 +02:00
Patrik Oldsberg 205c8c8dc1 Merge pull request #33714 from backstage/rugvip/dev-db
cli: experimental embedded-postgres support for local dev
2026-04-03 21:07:15 +02:00
Andre Wanlin 735af5b2d6 Merge pull request #33421 from awanlin/docs/clean-up-items
Clean up of the contrib folder
2026-04-03 12:53:38 -05:00
Andre Wanlin 8bf97618ee Fixed links
Signed-off-by: Andre Wanlin <awanlin@spotify.com>
2026-04-03 12:39:28 -05:00
Andre Wanlin e66fa1898c Sidebar fix
Signed-off-by: Andre Wanlin <awanlin@spotify.com>
2026-04-03 12:30:40 -05:00
Andre Wanlin 6e6eff9b90 Fixes
Signed-off-by: Andre Wanlin <awanlin@spotify.com>
2026-04-03 12:28:56 -05:00
Andre Wanlin 13c3c0ab15 Potential fix for pull request finding
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Signed-off-by: Andre Wanlin <67169551+awanlin@users.noreply.github.com>
2026-04-03 12:28:56 -05:00
Andre Wanlin d42d56d62b Fixed broken link
Signed-off-by: Andre Wanlin <awanlin@spotify.com>
2026-04-03 12:28:56 -05:00
Andre Wanlin 5cbd39e980 Clean up of the contrib folder
Signed-off-by: Andre Wanlin <awanlin@spotify.com>
2026-04-03 12:28:53 -05:00
Patrik Oldsberg a4b9c45277 Merge pull request #33054 from StateFarmIns/theme-fix-mui-5-class-name-prefix
fix: MUI 5 v5- class name prefix reliability
2026-04-03 19:15:45 +02:00
Charles de Dreuille 4032ad7fc4 feat(ui): add Badge component
Adds a new `Badge` component to the Backstage UI library. Badge shares the same visual appearance as `Tag` (size tokens, colors, border radius, icon slot) but renders as a plain non-interactive `<span>` with no React Aria plumbing.

Key characteristics:
- Plain DOM element — accessible text content exposed to screen readers without any role override
- Background consumer — participates in the bg context system and steps up neutral background levels (`neutral-2` → `neutral-3` → `neutral-4`) when placed inside colored containers
- Supports `icon`, `size` (`small` | `medium`, defaults to `small`), `children`, and `className` props
- Fully themeable via `BadgeDefinition`

Also includes Storybook stories and full docs-ui documentation (props table, examples, theming section, changelog).

Signed-off-by: Charles de Dreuille <charles.dedreuille@gmail.com>
Made-with: Cursor
2026-04-03 17:19:02 +01:00
Fredrik Adelöw 3dfb6ddc3c Merge pull request #33743 from backstage/freben/permissions-cleanup-step-1
refactor(catalog-backend): permissions cleanup step 1
2026-04-03 18:14:47 +02:00
Patrik Oldsberg 8f9c1d64b8 verify-links: catch broken anchors, directory links, and invisible characters (#33713)
* verify-links: catch broken anchors, directory links, and invisible characters

Enhances the link verification script to catch several categories of
broken links that were previously missed:

- Broken anchors (cross-file and same-file) by extracting heading slugs
  from target documents and verifying anchors resolve
- Directory links missing index.md suffix within docs/
- Invisible/zero-width characters in URLs
- Case-sensitive anchor mismatches

Also strips fenced code blocks before scanning for links to avoid false
positives, and handles duplicate heading slug deduplication (GitHub and
Docusaurus append -1, -2, etc.).

Fixes a few newly-caught broken links in existing docs.

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor

* Fix CodeQL incomplete multi-character sanitization alert

Apply HTML tag stripping in a loop so that nested fragments
like <scr<script>ipt> are fully removed.

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor

---------

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
2026-04-03 17:48:40 +02:00
Rajib Quayum 452bb50432 chore: fix documentation
Signed-off-by: Rajib Quayum <rajibq@users.noreply.github.com>
2026-04-03 10:30:00 -04:00
Rajib Quayum a0100d4197 chore: add changeset
Signed-off-by: Rajib Quayum <rajibq@users.noreply.github.com>
2026-04-03 10:06:11 -04:00
Fredrik Adelöw 7e63730288 chore: add changeset for permissions cleanup step 1
Signed-off-by: Fredrik Adelöw <freben@spotify.com>
Made-with: Cursor
2026-04-03 16:05:49 +02:00
Fredrik Adelöw c1802eb603 refactor(catalog-backend): permissions cleanup step 1
Make `permissionsRegistry` required and `permissions` always a
`PermissionsService` in `CatalogEnvironment`. Remove the deprecated
`PermissionAuthorizer` fallback path and the `createPermissionIntegrationRouter`
fallback — catalog now exclusively uses `permissionsRegistry.addResourceType`
to register its permission resource type.

Signed-off-by: Fredrik Adelöw <freben@spotify.com>
Made-with: Cursor
2026-04-03 16:03:15 +02:00