Skip to content

Commit e8b5090

Browse files
authored
fix(global-header): add ability to use custom star icons (#1704)
Signed-off-by: Yash Oswal <yoswal@redhat.com>
1 parent 2cd673e commit e8b5090

2 files changed

Lines changed: 8 additions & 3 deletions

File tree

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
'@red-hat-developer-hub/backstage-plugin-global-header': patch
3+
---
4+
5+
fix: add ability to use custom star icons

workspaces/global-header/plugins/global-header/src/components/HeaderDropdownComponent/StarredDropdown.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ import {
1919
useEntityPresentation,
2020
useStarredEntities,
2121
} from '@backstage/plugin-catalog-react';
22-
import { Link } from '@backstage/core-components';
22+
import { Link, AppIcon } from '@backstage/core-components';
2323
import {
2424
CompoundEntityRef,
2525
Entity,
@@ -107,7 +107,7 @@ const StarredItem: FC<SectionComponentProps> = ({
107107
color: rhdhPalette?.general?.starredItemsColor ?? '#F3BA37',
108108
}}
109109
>
110-
<Star />
110+
<AppIcon id="star" Fallback={Star} />
111111
</IconButton>
112112
</Tooltip>
113113
</MenuItem>
@@ -123,7 +123,7 @@ export const StarredDropdown = () => {
123123

124124
return (
125125
<HeaderDropdownComponent
126-
buttonContent={<StarBorderIcon />}
126+
buttonContent={<AppIcon id="unstarred" Fallback={StarBorderIcon} />}
127127
onOpen={handleOpen}
128128
onClose={handleClose}
129129
anchorEl={anchorEl}

0 commit comments

Comments
 (0)