@babylonlabs-io/core-ui 1.1.0 → 1.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/Badge/Badge.d.ts +32 -0
- package/dist/components/Badge/index.d.ts +1 -0
- package/dist/index.cjs.js +3 -3
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.d.ts +1 -0
- package/dist/index.es.js +529 -512
- package/dist/index.es.js.map +1 -1
- package/dist/style.css +1 -1
- package/package.json +3 -2
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import { PropsWithChildren, ReactNode } from 'react';
|
|
2
|
+
export interface BadgeProps extends PropsWithChildren {
|
|
3
|
+
/**
|
|
4
|
+
* The number or content to display in the badge
|
|
5
|
+
*/
|
|
6
|
+
count?: number | ReactNode;
|
|
7
|
+
/**
|
|
8
|
+
* Max count to show. If count is greater than max, show max+
|
|
9
|
+
*/
|
|
10
|
+
max?: number;
|
|
11
|
+
/**
|
|
12
|
+
* The position of the badge
|
|
13
|
+
*/
|
|
14
|
+
position?: "top-right" | "top-left" | "bottom-right" | "bottom-left";
|
|
15
|
+
/**
|
|
16
|
+
* The color of the badge
|
|
17
|
+
*/
|
|
18
|
+
color?: "primary" | "secondary" | "error" | "warning" | "info" | "success";
|
|
19
|
+
/**
|
|
20
|
+
* Additional CSS class for the badge wrapper
|
|
21
|
+
*/
|
|
22
|
+
className?: string;
|
|
23
|
+
/**
|
|
24
|
+
* Additional CSS class for the badge indicator
|
|
25
|
+
*/
|
|
26
|
+
badgeClassName?: string;
|
|
27
|
+
/**
|
|
28
|
+
* Additional CSS class for the badge content
|
|
29
|
+
*/
|
|
30
|
+
contentClassName?: string;
|
|
31
|
+
}
|
|
32
|
+
export declare function Badge({ children, count, max, position, color, className, badgeClassName, contentClassName, }: BadgeProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './Badge';
|