Started on general window layout

This commit is contained in:
Gregory Schier
2023-02-19 23:11:59 -08:00
parent 0a0839cc3c
commit b95429dbeb
17 changed files with 337 additions and 99 deletions

View File

@@ -0,0 +1,34 @@
import { ComponentType } from 'react';
import {
ArchiveIcon,
CameraIcon,
ChevronDownIcon,
GearIcon,
HomeIcon,
TriangleDownIcon,
} from '@radix-ui/react-icons';
import classnames from 'classnames';
type IconName = 'archive' | 'home' | 'camera' | 'gear' | 'triangle-down';
const icons: Record<IconName, ComponentType> = {
archive: ArchiveIcon,
home: HomeIcon,
camera: CameraIcon,
gear: GearIcon,
'triangle-down': TriangleDownIcon,
};
export interface IconProps {
icon: IconName;
className?: string;
}
export function Icon({ icon, className }: IconProps) {
const Component = icons[icon];
return (
<div className={classnames(className, 'flex items-center')}>
<Component />
</div>
);
}