@dimasbaguspm/versaur 0.0.26 → 0.0.27
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/js/{bottom-sheet-CQw_O-4W.js → bottom-sheet-DCwLmjiX.js} +20 -20
- package/dist/js/{bottom-sheet-input-1C3Up2xF.js → bottom-sheet-input-D14wjCoC.js} +2 -2
- package/dist/js/forms/index.js +1 -1
- package/dist/js/{image-rectangle--Sy82Ff9.js → image-rectangle-BGLYH2Gl.js} +205 -151
- package/dist/js/index.js +65 -63
- package/dist/js/layouts/index.js +9 -8
- package/dist/js/navigation/index.js +1 -1
- package/dist/js/overlays/index.js +2 -2
- package/dist/js/primitive/index.js +16 -15
- package/dist/js/{tabs-CoNG51E1.js → tabs-C0hcpxNk.js} +1 -1
- package/dist/js/{tooltip-BbTHXz6h.js → tooltip-DlbAOUeP.js} +16 -16
- package/dist/js/top-bar-BA88ij4M.js +669 -0
- package/dist/types/layouts/badge-group/badge-group.d.ts +27 -0
- package/dist/types/layouts/badge-group/index.d.ts +2 -0
- package/dist/types/layouts/badge-group/types.d.ts +32 -0
- package/dist/types/layouts/index.d.ts +1 -0
- package/dist/types/primitive/card/card.d.ts +24 -0
- package/dist/types/primitive/card/index.d.ts +2 -0
- package/dist/types/primitive/card/types.d.ts +39 -0
- package/dist/types/primitive/index.d.ts +1 -0
- package/dist/utils/enforce-subpath-import.js +2 -0
- package/package.json +1 -1
- package/dist/js/top-bar-BjE0FiE8.js +0 -607
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import { HTMLAttributes, ReactNode } from 'react';
|
|
2
|
+
import { VariantProps } from '../../utils/variants';
|
|
3
|
+
import { badgeGroupVariants } from './helpers';
|
|
4
|
+
/**
|
|
5
|
+
* Props for the BadgeGroup component
|
|
6
|
+
*/
|
|
7
|
+
export interface BadgeGroupProps extends HTMLAttributes<HTMLDivElement>, VariantProps<typeof badgeGroupVariants> {
|
|
8
|
+
/**
|
|
9
|
+
* Children (should be Badge components)
|
|
10
|
+
*/
|
|
11
|
+
children: ReactNode;
|
|
12
|
+
/**
|
|
13
|
+
* Alignment of badges within the group
|
|
14
|
+
* @default 'start'
|
|
15
|
+
*/
|
|
16
|
+
alignment?: 'start' | 'center' | 'end' | 'between' | 'around' | 'evenly';
|
|
17
|
+
/**
|
|
18
|
+
* Whether badges should be fluid (full width)
|
|
19
|
+
* @default false
|
|
20
|
+
*/
|
|
21
|
+
fluid?: boolean;
|
|
22
|
+
/**
|
|
23
|
+
* Orientation of the badge group
|
|
24
|
+
* @default 'horizontal'
|
|
25
|
+
*/
|
|
26
|
+
orientation?: 'horizontal' | 'vertical';
|
|
27
|
+
/**
|
|
28
|
+
* Size of the gap between badges
|
|
29
|
+
* @default 'md'
|
|
30
|
+
*/
|
|
31
|
+
gap?: 'xs' | 'sm' | 'md' | 'lg' | 'xl';
|
|
32
|
+
}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { CardProps } from './types';
|
|
2
|
+
/**
|
|
3
|
+
* Card component - A clickable container component for displaying structured information
|
|
4
|
+
*
|
|
5
|
+
* Features:
|
|
6
|
+
* - All cards are clickable by default with hover effects
|
|
7
|
+
* - Structured layout with avatar, title, subtitle, badge, and supplementary info
|
|
8
|
+
* - Multiple color variants with soft backgrounds
|
|
9
|
+
* - Configurable padding sizes and shapes
|
|
10
|
+
* - Built with accessibility in mind
|
|
11
|
+
*
|
|
12
|
+
* @example
|
|
13
|
+
* ```tsx
|
|
14
|
+
* <Card
|
|
15
|
+
* title="John Doe"
|
|
16
|
+
* subtitle="Software Engineer"
|
|
17
|
+
* avatar={<Avatar shape="rounded">JD</Avatar>}
|
|
18
|
+
* badge={<BadgeGroup><Badge color="secondary">Available</Badge></BadgeGroup>}
|
|
19
|
+
* supplementaryInfo="$2,847.32"
|
|
20
|
+
* onClick={handleClick}
|
|
21
|
+
* />
|
|
22
|
+
* ```
|
|
23
|
+
*/
|
|
24
|
+
export declare const Card: import('react').ForwardRefExoticComponent<CardProps & import('react').RefAttributes<HTMLDivElement>>;
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import { HTMLAttributes, ReactNode } from 'react';
|
|
2
|
+
import { VariantProps } from 'class-variance-authority';
|
|
3
|
+
import { cardVariants } from './helpers';
|
|
4
|
+
/**
|
|
5
|
+
* Props for the Card component
|
|
6
|
+
*/
|
|
7
|
+
export interface CardProps extends Omit<HTMLAttributes<HTMLDivElement>, 'title' | 'children'>, VariantProps<typeof cardVariants> {
|
|
8
|
+
/**
|
|
9
|
+
* Size variant affecting padding
|
|
10
|
+
* @default 'md'
|
|
11
|
+
*/
|
|
12
|
+
size?: 'xs' | 'sm' | 'md' | 'lg' | 'xl';
|
|
13
|
+
/**
|
|
14
|
+
* Shape variant affecting border radius
|
|
15
|
+
* @default 'rounded'
|
|
16
|
+
*/
|
|
17
|
+
shape?: 'rounded' | 'square';
|
|
18
|
+
/**
|
|
19
|
+
* Avatar element to display on the left side
|
|
20
|
+
*/
|
|
21
|
+
avatar?: ReactNode;
|
|
22
|
+
/**
|
|
23
|
+
* Main title text
|
|
24
|
+
*/
|
|
25
|
+
title: ReactNode;
|
|
26
|
+
/**
|
|
27
|
+
* Subtitle or description text
|
|
28
|
+
*/
|
|
29
|
+
subtitle?: ReactNode;
|
|
30
|
+
/**
|
|
31
|
+
* Badge element to display in the header area
|
|
32
|
+
*/
|
|
33
|
+
badge?: ReactNode;
|
|
34
|
+
/**
|
|
35
|
+
* Supplementary information to display on the right side
|
|
36
|
+
* Usually used for amounts, status, or additional info
|
|
37
|
+
*/
|
|
38
|
+
supplementaryInfo?: ReactNode;
|
|
39
|
+
}
|
|
@@ -28,6 +28,7 @@ const symbolToSubpath = {
|
|
|
28
28
|
"TextAreaInput": "forms",
|
|
29
29
|
"TimePickerInput": "forms",
|
|
30
30
|
"AppBar": "layouts",
|
|
31
|
+
"BadgeGroup": "layouts",
|
|
31
32
|
"BottomBar": "layouts",
|
|
32
33
|
"ButtonGroup": "layouts",
|
|
33
34
|
"FormLayout": "layouts",
|
|
@@ -53,6 +54,7 @@ const symbolToSubpath = {
|
|
|
53
54
|
"ButtonIcon": "primitive",
|
|
54
55
|
"Calculator": "primitive",
|
|
55
56
|
"Calendar": "primitive",
|
|
57
|
+
"Card": "primitive",
|
|
56
58
|
"DescriptionList": "primitive",
|
|
57
59
|
"Icon": "primitive",
|
|
58
60
|
"ImageCircle": "primitive",
|