refactor(home): align layout input and widget data wiring

Signed-off-by: Adam Kunicki <kunickiaj@gmail.com>
This commit is contained in:
Adam Kunicki
2026-02-08 19:42:11 -08:00
parent e4544fb773
commit 56c58877b1
6 changed files with 29 additions and 42 deletions
@@ -51,7 +51,7 @@ export interface HomePageLayoutBlueprintParams {
*/
export const HomePageLayoutBlueprint = createExtensionBlueprint({
kind: 'home-page-layout',
attachTo: { id: 'page:home', input: 'layouts' },
attachTo: { id: 'page:home', input: 'layout' },
output: [homePageLayoutComponentDataRef],
dataRefs: {
component: homePageLayoutComponentDataRef,
@@ -106,6 +106,7 @@ export const HomePageWidgetBlueprint = createExtensionBlueprint({
);
yield homePageWidgetDataRef({
node,
component: <Widget {...(params.componentProps ?? {})} />,
name: params.name,
title: params.title,
+8 -1
View File
@@ -14,7 +14,10 @@
* limitations under the License.
*/
import { createExtensionDataRef } from '@backstage/frontend-plugin-api';
import {
createExtensionDataRef,
type AppNode,
} from '@backstage/frontend-plugin-api';
import { JSX, ReactElement } from 'react';
import type { CardLayout, CardSettings } from '../extensions';
@@ -25,6 +28,10 @@ import type { CardLayout, CardSettings } from '../extensions';
* @alpha
*/
export interface HomePageWidgetData {
/**
* The originating app node for this widget.
*/
node: AppNode;
/**
* The rendered widget component (typically a card with header, content, etc.)
*/