website refactor
This commit is contained in:
@@ -1,26 +1,10 @@
|
||||
import React, { ReactNode, MouseEventHandler } from 'react';
|
||||
import { Box, BoxProps } from './primitives/Box';
|
||||
|
||||
type Spacing = 0 | 0.5 | 1 | 1.5 | 2 | 2.5 | 3 | 3.5 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 14 | 16 | 20 | 24 | 28 | 32 | 36 | 40 | 44 | 48 | 52 | 56 | 60 | 64 | 72 | 80 | 96;
|
||||
|
||||
interface ResponsiveSpacing {
|
||||
base?: Spacing;
|
||||
md?: Spacing;
|
||||
lg?: Spacing;
|
||||
}
|
||||
|
||||
interface CardProps extends Omit<BoxProps<'div'>, 'children' | 'className' | 'onClick'> {
|
||||
export interface CardProps extends Omit<BoxProps<'div'>, 'children' | 'onClick'> {
|
||||
children: ReactNode;
|
||||
className?: string;
|
||||
onClick?: MouseEventHandler<HTMLDivElement>;
|
||||
variant?: 'default' | 'outline' | 'ghost';
|
||||
p?: Spacing | ResponsiveSpacing;
|
||||
px?: Spacing | ResponsiveSpacing;
|
||||
py?: Spacing | ResponsiveSpacing;
|
||||
pt?: Spacing | ResponsiveSpacing;
|
||||
pb?: Spacing | ResponsiveSpacing;
|
||||
pl?: Spacing | ResponsiveSpacing;
|
||||
pr?: Spacing | ResponsiveSpacing;
|
||||
variant?: 'default' | 'outline' | 'ghost' | 'muted' | 'dark' | 'glass';
|
||||
}
|
||||
|
||||
export function Card({
|
||||
@@ -35,7 +19,10 @@ export function Card({
|
||||
const variantClasses = {
|
||||
default: 'bg-panel-gray border border-border-gray shadow-card',
|
||||
outline: 'bg-transparent border border-border-gray',
|
||||
ghost: 'bg-transparent border-none'
|
||||
ghost: 'bg-transparent border-none',
|
||||
muted: 'bg-panel-gray/40 border border-border-gray',
|
||||
dark: 'bg-graphite-black border border-border-gray',
|
||||
glass: 'bg-graphite-black/60 backdrop-blur-md border border-border-gray'
|
||||
};
|
||||
|
||||
const classes = [
|
||||
|
||||
Reference in New Issue
Block a user