feat(ui): 重构核心 UI 组件库,新增 shadcn/ui 组件
- 重构 Button、Card、Badge、Input、Textarea 等基础组件 - 新增 Accordion、Alert、Dialog、Dropdown、Form 等 shadcn/ui 组件 - 新增 AnimatedCounter、StatsShowcase、MetricCard 等数据展示组件 - 新增 ScrollReveal 滚动动画组件 - 重构 Toast 通知系统与 Tooltip 提示组件 - 更新设计令牌系统,对齐新品牌视觉
This commit is contained in:
@@ -0,0 +1,204 @@
|
||||
// === shadcn/ui 标准组件 ===
|
||||
export { Button, buttonVariants } from './button';
|
||||
export type { ButtonProps } from './button';
|
||||
|
||||
export {
|
||||
Card,
|
||||
CardHeader,
|
||||
CardFooter,
|
||||
CardTitle,
|
||||
CardAction,
|
||||
CardDescription,
|
||||
CardContent,
|
||||
} from './card';
|
||||
|
||||
export { Badge, badgeVariants } from './badge';
|
||||
|
||||
export { Input } from './input';
|
||||
|
||||
export { Textarea } from './textarea';
|
||||
|
||||
export { Label, labelVariants } from './label';
|
||||
|
||||
export { LabeledInput } from './labeled-input';
|
||||
export type { LabeledInputProps } from './labeled-input';
|
||||
|
||||
export { LabeledTextarea } from './labeled-textarea';
|
||||
export type { LabeledTextareaProps } from './labeled-textarea';
|
||||
|
||||
export { Skeleton, SkeletonText, SkeletonCard, SkeletonList, SkeletonHero, SkeletonForm } from './skeleton';
|
||||
|
||||
// === 表单类 ===
|
||||
export { Checkbox } from './checkbox';
|
||||
export { Switch } from './switch';
|
||||
export { RadioGroup, RadioGroupItem } from './radio-group';
|
||||
export { Slider } from './slider';
|
||||
export {
|
||||
Select,
|
||||
SelectGroup,
|
||||
SelectValue,
|
||||
SelectTrigger,
|
||||
SelectContent,
|
||||
SelectLabel,
|
||||
SelectItem,
|
||||
SelectSeparator,
|
||||
SelectScrollUpButton,
|
||||
SelectScrollDownButton,
|
||||
} from './select';
|
||||
export {
|
||||
Form,
|
||||
FormField,
|
||||
FormItem,
|
||||
FormLabel,
|
||||
FormControl,
|
||||
FormDescription,
|
||||
FormMessage,
|
||||
useFormField,
|
||||
useFormWithZod,
|
||||
} from './form';
|
||||
|
||||
// === 反馈类 ===
|
||||
export { Alert, AlertTitle, AlertDescription, alertVariants } from './alert';
|
||||
export {
|
||||
AlertDialog,
|
||||
AlertDialogPortal,
|
||||
AlertDialogOverlay,
|
||||
AlertDialogTrigger,
|
||||
AlertDialogContent,
|
||||
AlertDialogHeader,
|
||||
AlertDialogFooter,
|
||||
AlertDialogTitle,
|
||||
AlertDialogDescription,
|
||||
AlertDialogAction,
|
||||
AlertDialogCancel,
|
||||
} from './alert-dialog';
|
||||
export {
|
||||
Dialog,
|
||||
DialogPortal,
|
||||
DialogOverlay,
|
||||
DialogTrigger,
|
||||
DialogClose,
|
||||
DialogContent,
|
||||
DialogHeader,
|
||||
DialogFooter,
|
||||
DialogTitle,
|
||||
DialogDescription,
|
||||
} from './dialog';
|
||||
export { Progress } from './progress';
|
||||
|
||||
// === 导航类 ===
|
||||
export {
|
||||
DropdownMenu,
|
||||
DropdownMenuTrigger,
|
||||
DropdownMenuContent,
|
||||
DropdownMenuItem,
|
||||
DropdownMenuCheckboxItem,
|
||||
DropdownMenuRadioItem,
|
||||
DropdownMenuLabel,
|
||||
DropdownMenuSeparator,
|
||||
DropdownMenuShortcut,
|
||||
DropdownMenuGroup,
|
||||
DropdownMenuPortal,
|
||||
DropdownMenuSub,
|
||||
DropdownMenuSubContent,
|
||||
DropdownMenuSubTrigger,
|
||||
DropdownMenuRadioGroup,
|
||||
} from './dropdown-menu';
|
||||
export { Tabs, TabsList, TabsTrigger, TabsContent } from './tabs';
|
||||
export { Accordion, AccordionItem, AccordionTrigger, AccordionContent } from './accordion';
|
||||
export {
|
||||
Pagination,
|
||||
PaginationContent,
|
||||
PaginationLink,
|
||||
PaginationItem,
|
||||
PaginationPrevious,
|
||||
PaginationNext,
|
||||
PaginationEllipsis,
|
||||
} from './pagination';
|
||||
export {
|
||||
Breadcrumb,
|
||||
BreadcrumbList,
|
||||
BreadcrumbItem,
|
||||
BreadcrumbLink,
|
||||
BreadcrumbPage,
|
||||
BreadcrumbSeparator,
|
||||
BreadcrumbEllipsis,
|
||||
} from './breadcrumb';
|
||||
|
||||
// === 数据类 ===
|
||||
export {
|
||||
Table,
|
||||
TableHeader,
|
||||
TableBody,
|
||||
TableFooter,
|
||||
TableHead,
|
||||
TableRow,
|
||||
TableCell,
|
||||
TableCaption,
|
||||
} from './table';
|
||||
export { Avatar, AvatarImage, AvatarFallback } from './avatar';
|
||||
export { Separator } from './separator';
|
||||
export { ScrollArea, ScrollBar } from './scroll-area';
|
||||
|
||||
// === 浮层类 ===
|
||||
export {
|
||||
Tooltip,
|
||||
TooltipTrigger,
|
||||
TooltipContent,
|
||||
TooltipProvider,
|
||||
LegacyTooltip,
|
||||
} from './tooltip';
|
||||
export { Popover, PopoverTrigger, PopoverContent, PopoverAnchor } from './popover';
|
||||
export { HoverCard, HoverCardTrigger, HoverCardContent } from './hover-card';
|
||||
export {
|
||||
ContextMenu,
|
||||
ContextMenuTrigger,
|
||||
ContextMenuContent,
|
||||
ContextMenuItem,
|
||||
ContextMenuCheckboxItem,
|
||||
ContextMenuRadioItem,
|
||||
ContextMenuLabel,
|
||||
ContextMenuSeparator,
|
||||
ContextMenuShortcut,
|
||||
ContextMenuGroup,
|
||||
ContextMenuPortal,
|
||||
ContextMenuSub,
|
||||
ContextMenuSubContent,
|
||||
ContextMenuSubTrigger,
|
||||
ContextMenuRadioGroup,
|
||||
} from './context-menu';
|
||||
|
||||
// === Toast (Sonner) ===
|
||||
export { Toaster, toast } from './sonner';
|
||||
export { Toast } from './toast';
|
||||
|
||||
// === 业务自定义组件(保留) ===
|
||||
export { ScrollReveal, StaggerReveal } from './scroll-reveal';
|
||||
export { ScrollProgress } from './scroll-progress';
|
||||
export { BackToTop } from './back-to-top';
|
||||
export { StaticLink } from './static-link';
|
||||
export { Spinner, LoadingState, PageLoader, useLoadingState } from './loading-state';
|
||||
export { ErrorBoundary } from './error-boundary';
|
||||
export { PageTransition, StaggerChildren } from './page-transition';
|
||||
export {
|
||||
EASE_OUT,
|
||||
GrainOverlay,
|
||||
FloatingInkParticles,
|
||||
SectionLabel,
|
||||
} from './page-decoration';
|
||||
export {
|
||||
GeometricDecoration,
|
||||
DataBar,
|
||||
GradientDivider,
|
||||
BrandStamp,
|
||||
} from './brand-visuals';
|
||||
export { InkGlowCard } from './ink-glow-card';
|
||||
export { ChallengeCard } from './challenge-card';
|
||||
export { ProductCard as UiProductCard } from './product-card';
|
||||
export { DetailSwipeNav } from './detail-swipe-nav';
|
||||
export { HeroInkBackground } from './hero-ink-background';
|
||||
export { FlipClock } from './flip-clock';
|
||||
export { AnimatedCounter } from './animated-counter';
|
||||
export { MetricCard } from './metric-card';
|
||||
export { StatsShowcase } from './stats-showcase';
|
||||
export { MilestoneTimeline } from './milestone-timeline';
|
||||
Reference in New Issue
Block a user