From 7ae999684a5a9771da9c989aff74d9ae74937d03 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ladislav=20Vit=C3=A1sek?= Date: Fri, 28 Mar 2025 15:54:48 +0100 Subject: [PATCH 1/2] feat: add customizable className prop to TemplateDetailButton and update CardHeader to use it MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Ladislav Vitásek --- .changeset/social-seals-shout.md | 7 +++++++ .../src/next/components/TemplateCard/CardHeader.tsx | 8 +++++++- .../next/components/TemplateCard/TemplateDetailButton.tsx | 5 +++-- 3 files changed, 17 insertions(+), 3 deletions(-) create mode 100644 .changeset/social-seals-shout.md diff --git a/.changeset/social-seals-shout.md b/.changeset/social-seals-shout.md new file mode 100644 index 0000000000..b3c386b7cb --- /dev/null +++ b/.changeset/social-seals-shout.md @@ -0,0 +1,7 @@ +--- +'@backstage/plugin-scaffolder-react': patch +--- + +Detail icon - light theme - fix + +- Fixes the detail icon in light theme to be visible in proper color (same as favorite star). diff --git a/plugins/scaffolder-react/src/next/components/TemplateCard/CardHeader.tsx b/plugins/scaffolder-react/src/next/components/TemplateCard/CardHeader.tsx index 5e5c6fe8bf..edba47ac1a 100644 --- a/plugins/scaffolder-react/src/next/components/TemplateCard/CardHeader.tsx +++ b/plugins/scaffolder-react/src/next/components/TemplateCard/CardHeader.tsx @@ -36,6 +36,9 @@ const useStyles = makeStyles< display: 'flex', justifyContent: 'space-between', }, + detailIcon: { + color: ({ cardFontColor }) => cardFontColor, + }, })); /** @@ -67,7 +70,10 @@ export const CardHeader = (props: CardHeaderProps) => {
{type}
- + { const catalogEntityRoute = useRouteRef(entityRouteRef); const { t } = useTranslationRef(scaffolderReactTranslationRef); @@ -48,14 +50,13 @@ export const TemplateDetailButton = ({ aria-label={t('cardHeader.detailBtnTitle')} id={`viewDetail-${entityRef}`} style={{ padding: 0 }} - color="inherit" > - + From 22f2ed0a448045d7e9062667f69897fc03c3e3bb Mon Sep 17 00:00:00 2001 From: Ben Lambert Date: Tue, 15 Apr 2025 11:08:55 +0200 Subject: [PATCH 2/2] Fix detail icon visibility in light theme Signed-off-by: benjdlambert --- .changeset/social-seals-shout.md | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/.changeset/social-seals-shout.md b/.changeset/social-seals-shout.md index b3c386b7cb..184d898b2f 100644 --- a/.changeset/social-seals-shout.md +++ b/.changeset/social-seals-shout.md @@ -2,6 +2,4 @@ '@backstage/plugin-scaffolder-react': patch --- -Detail icon - light theme - fix - -- Fixes the detail icon in light theme to be visible in proper color (same as favorite star). +Fixes the detail icon in light theme to be visible in proper color (same as favorite star).