diff --git a/app/assets/icons/git-logo.svg b/app/assets/icons/git-logo.svg new file mode 100644 index 000000000..0ff160fa9 --- /dev/null +++ b/app/assets/icons/git-logo.svg @@ -0,0 +1,3 @@ + + + diff --git a/app/react/components/Icon.tsx b/app/react/components/Icon.tsx index 112c65ba9..8413c1410 100644 --- a/app/react/components/Icon.tsx +++ b/app/react/components/Icon.tsx @@ -3,6 +3,8 @@ import { ComponentType, ReactNode, useEffect } from 'react'; import featherIcons from 'feather-icons'; import { isValidElementType } from 'react-is'; +import Svg, { SvgIcons } from './Svg'; + export interface IconProps { icon: ReactNode | ComponentType; featherIcon?: boolean; @@ -51,6 +53,11 @@ export function Icon({ icon, feather, className, mode, size }: Props) { ); } + if (icon.indexOf('svg-') === 0) { + const svgIcon = icon.replace('svg-', ''); + return ; + } + if (feather) { return ( + + + ); +} + +export default Svg;