diff --git a/packages/alert/src/lib/alert.tsx b/packages/alert/src/lib/alert.tsx index 58153b8..f575b95 100644 --- a/packages/alert/src/lib/alert.tsx +++ b/packages/alert/src/lib/alert.tsx @@ -1,4 +1,5 @@ import React, { ReactNode, useState } from 'react'; +import { cn } from "@bootwind/common" import { GoInfo, GoXCircle, GoCheckCircle } from 'react-icons/go'; export interface AlertProps { @@ -7,6 +8,7 @@ export interface AlertProps { title?: string; description?: string | ReactNode; actions?: React.ReactNode; + className?: string border?: "left" | "right" | "all" | "none" link?: { url: string; @@ -60,6 +62,7 @@ export const Alert: React.FC = ({ description, actions, border = "none", + className, link, dismissButton = false, }) => { @@ -104,7 +107,7 @@ export const Alert: React.FC = ({ return (
{icon && ( diff --git a/packages/avatar/src/lib/avatar.tsx b/packages/avatar/src/lib/avatar.tsx index c8bc979..fedcbab 100644 --- a/packages/avatar/src/lib/avatar.tsx +++ b/packages/avatar/src/lib/avatar.tsx @@ -1,17 +1,20 @@ import React from 'react'; +import { cn } from "@bootwind/common" export interface AvatarProps { - src?: string; - alt: string; - rounded?: 'none' | 'sm' | 'md' | 'lg' | 'full'; - notificationDot?: 'gray' | 'red' | 'green'; - showPlaceholder?: boolean; // Tambahkan properti showPlaceholder + src?: string + alt: string + className?: string + rounded?: 'none' | 'sm' | 'md' | 'lg' | 'full' + notificationDot?: 'gray' | 'red' | 'green' + showPlaceholder?: boolean // Tambahkan properti showPlaceholder } export const Avatar: React.FC = ({ src, alt, rounded = 'md', + className, notificationDot, showPlaceholder = false, // Defaultnya tidak menampilkan placeholder }) => { @@ -32,7 +35,7 @@ export const Avatar: React.FC = ({ const shouldShowPlaceholder = !src && showPlaceholder; return ( - + {notificationDot && ( = ({ withIcon = null, withDot = false, children, + className }) => { const baseClasses = `inline-flex items-center rounded-md px-2.5 py-0.5 font-medium`; @@ -81,7 +84,7 @@ export const Badge: React.FC = ({ }; return ( - + {badgeContent} ); diff --git a/packages/breadcrumb/src/lib/breadcrumb.tsx b/packages/breadcrumb/src/lib/breadcrumb.tsx index f368258..9627844 100644 --- a/packages/breadcrumb/src/lib/breadcrumb.tsx +++ b/packages/breadcrumb/src/lib/breadcrumb.tsx @@ -1,14 +1,16 @@ import React from 'react'; import { GoChevronRight, GoHome } from 'react-icons/go'; +import { cn } from "@bootwind/common" export interface BreadcrumbsProps { children: React.ReactNode items?: BreadcrumbItemProps[] + className?: string } -export const Breadcrumbs: React.FC = ({ children, items }) => { +export const Breadcrumbs: React.FC = ({ children, items, className }) => { return ( -