Skip to content

Commit ed40a51

Browse files
mhartingtonFrozenPandaz
authored andcommitted
fix(nx-dev): fix heroicons for safari (#29544)
(cherry picked from commit 97e1e3b)
1 parent b8752db commit ed40a51

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

nx-dev/ui-markdoc/src/lib/tags/cards.component.tsx

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -101,9 +101,9 @@ export function Cards({
101101
);
102102
}
103103

104-
function callIfFunction(fn: any) {
104+
function callIfFunction(fn: any, props: { [key: string]: string } = {}) {
105105
if (typeof fn === 'function') {
106-
return fn({});
106+
return fn(props);
107107
}
108108
return fn;
109109
}
@@ -142,7 +142,8 @@ export function LinkCard({
142142
(frameworkIcons[icon as Framework]?.image ||
143143
callIfFunction(nxDevIcons[icon as keyof typeof nxDevIcons]) ||
144144
callIfFunction(
145-
(heroIcons[icon as keyof typeof heroIcons] as any)?.render
145+
(heroIcons[icon as keyof typeof heroIcons] as any)?.render,
146+
{ className: 'w-full h-full' }
146147
))}
147148
</div>
148149
)}

0 commit comments

Comments
 (0)