MCPcopy Create free account
hub / github.com/dailydotdev/apps / Icon

Function Icon

packages/shared/src/components/Icon.tsx:49–69  ·  view source on GitHub ↗
({
  secondary = false,
  size = IconSize.XSmall,
  className = '',
  IconPrimary,
  IconSecondary,
  ...rest
}: Props)

Source from the content-addressed store, hash-verified

47};
48
49const Icon = ({
50 secondary = false,
51 size = IconSize.XSmall,
52 className = '',
53 IconPrimary,
54 IconSecondary,
55 ...rest
56}: Props): ReactElement => {
57 const IconComponent = secondary ? IconSecondary : IconPrimary;
58
59 return (
60 <IconComponent
61 className={classNames(
62 iconSizeToClassName[size],
63 'pointer-events-none',
64 className,
65 )}
66 {...rest}
67 />
68 );
69};
70
71export /**
72 * Icon wrapper so we can use more then single element inside the icon

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected