@shohojdhara/atomix 0.1.24 → 0.1.26
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/CHANGELOG.md +11 -0
- package/dist/js/atomix.react.cjs.js +1 -1
- package/dist/js/atomix.react.esm.js +1 -1
- package/dist/js/atomix.react.umd.js +1 -1
- package/dist/types/components/Breadcrumb/Breadcrumb.d.ts +4 -0
- package/dist/types/layouts/Grid/Container.d.ts +39 -0
- package/dist/types/layouts/Grid/Grid.d.ts +38 -0
- package/dist/types/layouts/Grid/GridCol.d.ts +65 -0
- package/dist/types/layouts/Grid/Row.d.ts +39 -0
- package/dist/types/layouts/Grid/index.d.ts +8 -0
- package/dist/types/layouts/MasonryGrid/MasonryGrid.d.ts +72 -0
- package/dist/types/layouts/MasonryGrid/MasonryGridItem.d.ts +25 -0
- package/dist/types/layouts/MasonryGrid/index.d.ts +4 -0
- package/dist/types/layouts/index.d.ts +2 -0
- package/dist/types/lib/composables/index.d.ts +30 -0
- package/dist/types/lib/composables/useAccordion.d.ts +30 -0
- package/dist/types/lib/composables/useBadge.d.ts +10 -0
- package/dist/types/lib/composables/useBreadcrumb.d.ts +13 -0
- package/dist/types/lib/composables/useButton.d.ts +11 -0
- package/dist/types/lib/composables/useCallout.d.ts +11 -0
- package/dist/types/lib/composables/useCard.d.ts +8 -0
- package/dist/types/lib/composables/useCheckbox.d.ts +11 -0
- package/dist/types/lib/composables/useDataTable.d.ts +66 -0
- package/dist/types/lib/composables/useDatePicker.d.ts +91 -0
- package/dist/types/lib/composables/useDropdown.d.ts +26 -0
- package/dist/types/lib/composables/useEdgePanel.d.ts +15 -0
- package/dist/types/lib/composables/useForm.d.ts +12 -0
- package/dist/types/lib/composables/useFormGroup.d.ts +10 -0
- package/dist/types/lib/composables/useHero.d.ts +53 -0
- package/dist/types/lib/composables/useInput.d.ts +12 -0
- package/dist/types/lib/composables/useMessages.d.ts +38 -0
- package/dist/types/lib/composables/useModal.d.ts +40 -0
- package/dist/types/lib/composables/useNavbar.d.ts +59 -0
- package/dist/types/lib/composables/usePagination.d.ts +13 -0
- package/dist/types/lib/composables/usePhotoViewer.d.ts +57 -0
- package/dist/types/lib/composables/usePopover.d.ts +30 -0
- package/dist/types/lib/composables/useProgress.d.ts +38 -0
- package/dist/types/lib/composables/useRadio.d.ts +10 -0
- package/dist/types/lib/composables/useRating.d.ts +52 -0
- package/dist/types/lib/composables/useRiver.d.ts +107 -0
- package/dist/types/lib/composables/useSelect.d.ts +10 -0
- package/dist/types/lib/composables/useSideMenu.d.ts +28 -0
- package/dist/types/lib/composables/useSpinner.d.ts +10 -0
- package/dist/types/lib/composables/useTextarea.d.ts +10 -0
- package/dist/types/lib/composables/useTodo.d.ts +18 -0
- package/dist/types/lib/constants/components.d.ts +993 -0
- package/dist/types/lib/constants/index.d.ts +1 -0
- package/dist/types/lib/index.d.ts +6 -0
- package/dist/types/lib/types/components.d.ts +2062 -0
- package/dist/types/lib/types/index.d.ts +1 -0
- package/dist/types/lib/utils/dom.d.ts +26 -0
- package/dist/types/lib/utils/icons.d.ts +20 -0
- package/dist/types/lib/utils/index.d.ts +3 -0
- package/dist/types/lib/utils/useForkRef.d.ts +10 -0
- package/package.json +11 -3
- package/src/components/Breadcrumb/Breadcrumb.tsx +17 -3
- package/src/components/Dropdown/Dropdown.tsx +21 -11
- package/src/components/Navigation/Nav/NavItem.tsx +18 -11
- package/src/components/Navigation/SideMenu/SideMenuItem.tsx +20 -12
- package/src/components/index.ts +42 -117
- package/src/layouts/Grid/Container.tsx +2 -0
- package/src/layouts/Grid/Grid.tsx +1 -0
- package/src/layouts/Grid/GridCol.tsx +1 -0
- package/src/layouts/Grid/Row.tsx +2 -0
- package/src/layouts/MasonryGrid/MasonryGrid.tsx +2 -0
- package/src/layouts/MasonryGrid/MasonryGridItem.tsx +2 -0
- package/src/layouts/index.ts +1 -6
- package/src/lib/types/components.ts +15 -0
- package/src/htmlComponentsEntry.ts +0 -318
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './components';
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Check if element has a specific class
|
|
3
|
+
* @param element - DOM element to check
|
|
4
|
+
* @param className - Class name to check for
|
|
5
|
+
* @returns Whether element has the class
|
|
6
|
+
*/
|
|
7
|
+
export declare function hasClass(element: HTMLElement, className: string): boolean;
|
|
8
|
+
/**
|
|
9
|
+
* Add class to element if not already present
|
|
10
|
+
* @param element - DOM element to modify
|
|
11
|
+
* @param className - Class name to add
|
|
12
|
+
*/
|
|
13
|
+
export declare function addClass(element: HTMLElement, className: string): void;
|
|
14
|
+
/**
|
|
15
|
+
* Remove class from element if present
|
|
16
|
+
* @param element - DOM element to modify
|
|
17
|
+
* @param className - Class name to remove
|
|
18
|
+
*/
|
|
19
|
+
export declare function removeClass(element: HTMLElement, className: string): void;
|
|
20
|
+
/**
|
|
21
|
+
* Toggle class on element
|
|
22
|
+
* @param element - DOM element to modify
|
|
23
|
+
* @param className - Class name to toggle
|
|
24
|
+
* @param force - If true, adds class; if false, removes class
|
|
25
|
+
*/
|
|
26
|
+
export declare function toggleClass(element: HTMLElement, className: string, force?: boolean): void;
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Create a Phosphor icon SVG element
|
|
3
|
+
* @param name - Icon name
|
|
4
|
+
* @param size - Icon size in pixels
|
|
5
|
+
* @returns SVG element as HTML string
|
|
6
|
+
*/
|
|
7
|
+
export declare function createPhosphorIcon(name: string, size?: number): string;
|
|
8
|
+
/**
|
|
9
|
+
* Create an icon element
|
|
10
|
+
* @param name - Icon name
|
|
11
|
+
* @param size - Icon size in pixels
|
|
12
|
+
* @param className - Additional CSS class name
|
|
13
|
+
* @returns Icon element
|
|
14
|
+
*/
|
|
15
|
+
export declare function createIconElement(name: string, size?: number, className?: string): HTMLSpanElement;
|
|
16
|
+
/**
|
|
17
|
+
* Get all available icon names
|
|
18
|
+
* @returns Array of icon names
|
|
19
|
+
*/
|
|
20
|
+
export declare function getAvailableIcons(): string[];
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
/**
|
|
3
|
+
* Utility to merge multiple React refs into one
|
|
4
|
+
*/
|
|
5
|
+
export declare function setRef<T>(ref: React.MutableRefObject<T | null> | ((instance: T | null) => void) | null, value: T | null): void;
|
|
6
|
+
/**
|
|
7
|
+
* Combines two React refs into a single ref function
|
|
8
|
+
* This is used when you need to use and forward a ref at the same time
|
|
9
|
+
*/
|
|
10
|
+
export default function useForkRef<T>(refA: React.Ref<T> | null, refB: React.Ref<T> | null): React.RefCallback<T> | null;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@shohojdhara/atomix",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.26",
|
|
4
4
|
"description": "Atomix Design System - A modern component library for web applications",
|
|
5
5
|
"main": "dist/js/atomix.react.cjs.js",
|
|
6
6
|
"module": "dist/js/atomix.react.esm.js",
|
|
@@ -18,6 +18,7 @@
|
|
|
18
18
|
"types": "./dist/types/index.d.ts",
|
|
19
19
|
"import": "./dist/js/atomix.react.esm.js",
|
|
20
20
|
"require": "./dist/js/atomix.react.cjs.js",
|
|
21
|
+
"browser": "./dist/js/atomix.react.umd.js",
|
|
21
22
|
"default": "./dist/js/atomix.react.esm.js"
|
|
22
23
|
},
|
|
23
24
|
"./package.json": "./package.json",
|
|
@@ -30,7 +31,13 @@
|
|
|
30
31
|
"default": "./dist/css/atomix.min.css"
|
|
31
32
|
},
|
|
32
33
|
"./scss": "./src/styles/index.scss",
|
|
33
|
-
"./dist/types/*": "./dist/types/*"
|
|
34
|
+
"./dist/types/*": "./dist/types/*",
|
|
35
|
+
"./components/*": {
|
|
36
|
+
"types": "./dist/types/components/*.d.ts",
|
|
37
|
+
"import": "./dist/js/components/*.js",
|
|
38
|
+
"require": "./dist/js/components/*.js",
|
|
39
|
+
"default": "./dist/js/components/*.js"
|
|
40
|
+
}
|
|
34
41
|
},
|
|
35
42
|
"typesVersions": {
|
|
36
43
|
"*": {
|
|
@@ -107,7 +114,8 @@
|
|
|
107
114
|
},
|
|
108
115
|
"scripts": {
|
|
109
116
|
"dev": "storybook dev -p 6006",
|
|
110
|
-
"build": "npm-run-all clean:dist build:styles build:react build:types",
|
|
117
|
+
"build": "npm-run-all clean:dist build:styles build:react build:types fix:exports",
|
|
118
|
+
"fix:exports": "node scripts/fix-exports.js",
|
|
111
119
|
"build:react": "webpack --mode production --env target=components --env format=all",
|
|
112
120
|
"build:styles": "webpack --mode production --env target=styles",
|
|
113
121
|
"build:types": "npm run clean:types && tsc --emitDeclarationOnly --declaration --declarationDir dist/types && node scripts/fix-types.js",
|
|
@@ -48,12 +48,18 @@ export interface BreadcrumbProps {
|
|
|
48
48
|
* Aria label for the navigation
|
|
49
49
|
*/
|
|
50
50
|
ariaLabel?: string;
|
|
51
|
+
|
|
52
|
+
/**
|
|
53
|
+
* Optional custom link component
|
|
54
|
+
*/
|
|
55
|
+
LinkComponent?: React.ElementType;
|
|
51
56
|
}
|
|
52
57
|
export const Breadcrumb: React.FC<BreadcrumbProps> = ({
|
|
53
58
|
items,
|
|
54
59
|
divider,
|
|
55
60
|
className = '',
|
|
56
61
|
ariaLabel = 'Breadcrumb',
|
|
62
|
+
LinkComponent,
|
|
57
63
|
}) => {
|
|
58
64
|
const breadcrumbClasses = [BREADCRUMB.CLASSES.BASE, className].filter(Boolean).join(' ');
|
|
59
65
|
|
|
@@ -76,12 +82,20 @@ export const Breadcrumb: React.FC<BreadcrumbProps> = ({
|
|
|
76
82
|
</>
|
|
77
83
|
);
|
|
78
84
|
|
|
85
|
+
const linkProps = {
|
|
86
|
+
href: item.href,
|
|
87
|
+
className: BREADCRUMB.CLASSES.LINK,
|
|
88
|
+
onClick: item.onClick,
|
|
89
|
+
};
|
|
90
|
+
|
|
79
91
|
return (
|
|
80
92
|
<li key={index} className={itemClasses}>
|
|
81
93
|
{item.href && !item.active ? (
|
|
82
|
-
|
|
83
|
-
{linkContent}
|
|
84
|
-
|
|
94
|
+
LinkComponent ? (
|
|
95
|
+
<LinkComponent {...linkProps}>{linkContent}</LinkComponent>
|
|
96
|
+
) : (
|
|
97
|
+
<a {...linkProps}>{linkContent}</a>
|
|
98
|
+
)
|
|
85
99
|
) : (
|
|
86
100
|
<span className={BREADCRUMB.CLASSES.LINK}>{linkContent}</span>
|
|
87
101
|
)}
|
|
@@ -34,6 +34,7 @@ export const DropdownItem: React.FC<DropdownItemProps> = ({
|
|
|
34
34
|
icon,
|
|
35
35
|
onClick,
|
|
36
36
|
className = '',
|
|
37
|
+
LinkComponent,
|
|
37
38
|
...props
|
|
38
39
|
}) => {
|
|
39
40
|
const { close } = useContext(DropdownContext);
|
|
@@ -61,20 +62,29 @@ export const DropdownItem: React.FC<DropdownItemProps> = ({
|
|
|
61
62
|
.filter(Boolean)
|
|
62
63
|
.join(' ');
|
|
63
64
|
|
|
65
|
+
const linkProps = {
|
|
66
|
+
href,
|
|
67
|
+
className: itemClasses,
|
|
68
|
+
onClick: handleClick,
|
|
69
|
+
role: 'menuitem',
|
|
70
|
+
tabIndex: 0,
|
|
71
|
+
...props,
|
|
72
|
+
};
|
|
73
|
+
|
|
64
74
|
if (href && !disabled) {
|
|
65
75
|
return (
|
|
66
76
|
<li>
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
{...
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
77
|
+
{LinkComponent ? (
|
|
78
|
+
<LinkComponent {...linkProps}>
|
|
79
|
+
{icon && <span className="c-dropdown__menu-item-icon">{icon}</span>}
|
|
80
|
+
{children}
|
|
81
|
+
</LinkComponent>
|
|
82
|
+
) : (
|
|
83
|
+
<a {...linkProps}>
|
|
84
|
+
{icon && <span className="c-dropdown__menu-item-icon">{icon}</span>}
|
|
85
|
+
{children}
|
|
86
|
+
</a>
|
|
87
|
+
)}
|
|
78
88
|
</li>
|
|
79
89
|
);
|
|
80
90
|
}
|
|
@@ -42,6 +42,7 @@ export const NavItem = forwardRef<HTMLLIElement, NavItemProps>(
|
|
|
42
42
|
className = '',
|
|
43
43
|
disabled = false,
|
|
44
44
|
'aria-expanded': ariaExpanded,
|
|
45
|
+
LinkComponent,
|
|
45
46
|
},
|
|
46
47
|
ref
|
|
47
48
|
) => {
|
|
@@ -132,19 +133,25 @@ export const NavItem = forwardRef<HTMLLIElement, NavItemProps>(
|
|
|
132
133
|
// Use aria-expanded from props if provided, otherwise use local state
|
|
133
134
|
const expanded = typeof ariaExpanded !== 'undefined' ? ariaExpanded : isActive;
|
|
134
135
|
|
|
136
|
+
const linkProps = {
|
|
137
|
+
ref: itemRef,
|
|
138
|
+
href: href || '#',
|
|
139
|
+
className: navLinkClass,
|
|
140
|
+
onClick: dropdown || megaMenu ? handleDropdownToggle : handleClick(onClick),
|
|
141
|
+
'aria-disabled': disabled,
|
|
142
|
+
'aria-expanded': dropdown || megaMenu ? expanded : undefined,
|
|
143
|
+
'aria-current': (active && !dropdown && !megaMenu ? 'page' : undefined) as React.AriaAttributes['aria-current'],
|
|
144
|
+
};
|
|
145
|
+
|
|
135
146
|
return (
|
|
136
147
|
<li ref={ref} className={navItemClass} role="menuitem" aria-haspopup={dropdown || megaMenu}>
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
aria-current={active && !dropdown && !megaMenu ? 'page' : undefined}
|
|
145
|
-
>
|
|
146
|
-
{dropdown || megaMenu ? childContent[0] : children}
|
|
147
|
-
</a>
|
|
148
|
+
{LinkComponent ? (
|
|
149
|
+
<LinkComponent {...linkProps}>
|
|
150
|
+
{dropdown || megaMenu ? childContent[0] : children}
|
|
151
|
+
</LinkComponent>
|
|
152
|
+
) : (
|
|
153
|
+
<a {...linkProps}>{dropdown || megaMenu ? childContent[0] : children}</a>
|
|
154
|
+
)}
|
|
148
155
|
|
|
149
156
|
{(dropdown || megaMenu) && childContent.length > 1 && childContent[1]}
|
|
150
157
|
</li>
|
|
@@ -39,6 +39,7 @@ export const SideMenuItem = forwardRef<HTMLAnchorElement | HTMLButtonElement, Si
|
|
|
39
39
|
className = '',
|
|
40
40
|
target,
|
|
41
41
|
rel,
|
|
42
|
+
LinkComponent,
|
|
42
43
|
},
|
|
43
44
|
ref
|
|
44
45
|
) => {
|
|
@@ -50,20 +51,27 @@ export const SideMenuItem = forwardRef<HTMLAnchorElement | HTMLButtonElement, Si
|
|
|
50
51
|
|
|
51
52
|
const itemClass = generateSideMenuItemClass();
|
|
52
53
|
|
|
54
|
+
const linkProps = {
|
|
55
|
+
ref: ref as React.Ref<HTMLAnchorElement>,
|
|
56
|
+
href: disabled ? undefined : href,
|
|
57
|
+
className: itemClass,
|
|
58
|
+
onClick: handleClick(onClick),
|
|
59
|
+
'aria-disabled': disabled,
|
|
60
|
+
'aria-current': (active ? 'page' : undefined) as React.AriaAttributes['aria-current'],
|
|
61
|
+
target: target,
|
|
62
|
+
rel: rel,
|
|
63
|
+
tabIndex: disabled ? -1 : 0,
|
|
64
|
+
};
|
|
65
|
+
|
|
53
66
|
// Render as link if href is provided
|
|
54
67
|
if (href) {
|
|
55
|
-
return (
|
|
56
|
-
<
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
aria-current={active ? 'page' : undefined}
|
|
63
|
-
target={target}
|
|
64
|
-
rel={rel}
|
|
65
|
-
tabIndex={disabled ? -1 : 0}
|
|
66
|
-
>
|
|
68
|
+
return LinkComponent ? (
|
|
69
|
+
<LinkComponent {...linkProps}>
|
|
70
|
+
{icon && <span className="c-side-menu__link-icon">{icon}</span>}
|
|
71
|
+
<span className="c-side-menu__link-text">{children}</span>
|
|
72
|
+
</LinkComponent>
|
|
73
|
+
) : (
|
|
74
|
+
<a {...linkProps}>
|
|
67
75
|
{icon && <span className="c-side-menu__link-icon">{icon}</span>}
|
|
68
76
|
<span className="c-side-menu__link-text">{children}</span>
|
|
69
77
|
</a>
|
package/src/components/index.ts
CHANGED
|
@@ -1,117 +1,42 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
export {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
export {
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
export {
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
export {
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
export {
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
export {
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
export {
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
export {
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
export {
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
export {
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
export {
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
export {
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
export {
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
export { EdgePanel, type EdgePanelProps } from './EdgePanel/EdgePanel';
|
|
44
|
-
|
|
45
|
-
// Form components - you might want to break these down further
|
|
46
|
-
export { Form, type FormProps } from './Form/Form';
|
|
47
|
-
export { Input, type InputProps } from './Form/Input';
|
|
48
|
-
export { Textarea, type TextareaProps } from './Form/Textarea';
|
|
49
|
-
export { Select, type SelectProps } from './Form/Select';
|
|
50
|
-
export { Checkbox, type CheckboxProps } from './Form/Checkbox';
|
|
51
|
-
export { Radio, type RadioProps } from './Form/Radio';
|
|
52
|
-
|
|
53
|
-
// Hero
|
|
54
|
-
export { Hero, type HeroProps } from './Hero/Hero';
|
|
55
|
-
|
|
56
|
-
// Icon
|
|
57
|
-
export { Icon, type IconProps } from './Icon/Icon';
|
|
58
|
-
|
|
59
|
-
// List
|
|
60
|
-
export { List, type ListProps } from './List/List';
|
|
61
|
-
|
|
62
|
-
// Messages
|
|
63
|
-
export { Messages, type MessagesProps } from './Messages/Messages';
|
|
64
|
-
|
|
65
|
-
// Modal
|
|
66
|
-
export { Modal, type ModalProps } from './Modal/Modal';
|
|
67
|
-
|
|
68
|
-
// Navbar
|
|
69
|
-
export { Navbar, type NavbarProps } from './Navigation/Navbar/Navbar';
|
|
70
|
-
|
|
71
|
-
// Pagination
|
|
72
|
-
export { Pagination, type PaginationProps } from './Pagination/Pagination';
|
|
73
|
-
|
|
74
|
-
// PhotoViewer
|
|
75
|
-
export { PhotoViewer, type PhotoViewerProps } from './PhotoViewer/PhotoViewer';
|
|
76
|
-
|
|
77
|
-
// Popover
|
|
78
|
-
export { Popover, type PopoverProps } from './Popover/Popover';
|
|
79
|
-
|
|
80
|
-
// ProductReview
|
|
81
|
-
export { ProductReview, type ProductReviewProps } from './ProductReview/ProductReview';
|
|
82
|
-
|
|
83
|
-
// Progress
|
|
84
|
-
export { Progress, type ProgressProps } from './Progress/Progress';
|
|
85
|
-
|
|
86
|
-
// Rating
|
|
87
|
-
export { Rating, type RatingProps } from './Rating/Rating';
|
|
88
|
-
|
|
89
|
-
// River
|
|
90
|
-
export { River, type RiverProps } from './River/River';
|
|
91
|
-
|
|
92
|
-
// SectionIntro
|
|
93
|
-
export { SectionIntro, type SectionIntroProps } from './SectionIntro/SectionIntro';
|
|
94
|
-
|
|
95
|
-
// Spinner
|
|
96
|
-
export { Spinner, type SpinnerProps } from './Spinner/Spinner';
|
|
97
|
-
|
|
98
|
-
// Steps
|
|
99
|
-
export { Steps, type StepsProps } from './Steps/Steps';
|
|
100
|
-
|
|
101
|
-
// Tab
|
|
102
|
-
export { Tab, type TabProps } from './Tab/Tab';
|
|
103
|
-
|
|
104
|
-
// Testimonial
|
|
105
|
-
export { Testimonial, type TestimonialProps } from './Testimonial/Testimonial';
|
|
106
|
-
|
|
107
|
-
// Todo
|
|
108
|
-
export { Todo, type TodoProps } from './Todo/Todo';
|
|
109
|
-
|
|
110
|
-
// Toggle
|
|
111
|
-
export { Toggle, type ToggleProps } from './Toggle/Toggle';
|
|
112
|
-
|
|
113
|
-
// Tooltip
|
|
114
|
-
export { Tooltip, type TooltipProps } from './Tooltip/Tooltip';
|
|
115
|
-
|
|
116
|
-
// Upload
|
|
117
|
-
export { Upload, type UploadProps } from './Upload/Upload';
|
|
1
|
+
export { default as Accordion, type AccordionProps } from './Accordion/Accordion';
|
|
2
|
+
export { default as Avatar, type AvatarProps } from './Avatar/Avatar';
|
|
3
|
+
export { default as AvatarGroup, type AvatarGroupProps } from './Avatar/AvatarGroup';
|
|
4
|
+
export { default as Badge, type BadgeProps } from './Badge/Badge';
|
|
5
|
+
export { default as Breadcrumb, type BreadcrumbProps } from './Breadcrumb/Breadcrumb';
|
|
6
|
+
export { default as Button, type ButtonProps } from './Button/Button';
|
|
7
|
+
export { default as Callout, type CalloutProps } from './Callout/Callout';
|
|
8
|
+
export { default as Card, type CardProps } from './Card/Card';
|
|
9
|
+
export { default as Checkbox, type CheckboxProps } from './Form/Checkbox';
|
|
10
|
+
export { default as ColorModeToggle, type ColorModeToggleProps } from './ColorModeToggle/ColorModeToggle';
|
|
11
|
+
export { default as Countdown, type CountdownProps } from './Countdown/Countdown';
|
|
12
|
+
export { default as DataTable, type DataTableProps } from './DataTable/DataTable';
|
|
13
|
+
export { default as DatePicker, type DatePickerProps } from './DatePicker/DatePicker';
|
|
14
|
+
export { default as Dropdown, type DropdownProps } from './Dropdown/Dropdown';
|
|
15
|
+
export { default as EdgePanel, type EdgePanelProps } from './EdgePanel/EdgePanel';
|
|
16
|
+
export { default as Form, type FormProps } from './Form/Form';
|
|
17
|
+
export { default as Hero, type HeroProps } from './Hero/Hero';
|
|
18
|
+
export { default as Icon, type IconProps } from './Icon/Icon';
|
|
19
|
+
export { default as Input, type InputProps } from './Form/Input';
|
|
20
|
+
export { default as List, type ListProps } from './List/List';
|
|
21
|
+
export { default as Messages, type MessagesProps } from './Messages/Messages';
|
|
22
|
+
export { default as Modal, type ModalProps } from './Modal/Modal';
|
|
23
|
+
export { default as Navbar, type NavbarProps } from './Navigation/Navbar/Navbar';
|
|
24
|
+
export { default as Pagination, type PaginationProps } from './Pagination/Pagination';
|
|
25
|
+
export { default as PhotoViewer, type PhotoViewerProps } from './PhotoViewer/PhotoViewer';
|
|
26
|
+
export { default as Popover, type PopoverProps } from './Popover/Popover';
|
|
27
|
+
export { default as ProductReview, type ProductReviewProps } from './ProductReview/ProductReview';
|
|
28
|
+
export { default as Progress, type ProgressProps } from './Progress/Progress';
|
|
29
|
+
export { default as Radio, type RadioProps } from './Form/Radio';
|
|
30
|
+
export { default as Rating, type RatingProps } from './Rating/Rating';
|
|
31
|
+
export { default as River, type RiverProps } from './River/River';
|
|
32
|
+
export { default as SectionIntro, type SectionIntroProps } from './SectionIntro/SectionIntro';
|
|
33
|
+
export { default as Select, type SelectProps } from './Form/Select';
|
|
34
|
+
export { default as Spinner, type SpinnerProps } from './Spinner/Spinner';
|
|
35
|
+
export { default as Steps, type StepsProps } from './Steps/Steps';
|
|
36
|
+
export { default as Tab, type TabProps } from './Tab/Tab';
|
|
37
|
+
export { default as Testimonial, type TestimonialProps } from './Testimonial/Testimonial';
|
|
38
|
+
export { default as Textarea, type TextareaProps } from './Form/Textarea';
|
|
39
|
+
export { default as Todo, type TodoProps } from './Todo/Todo';
|
|
40
|
+
export { default as Toggle, type ToggleProps } from './Toggle/Toggle';
|
|
41
|
+
export { default as Tooltip, type TooltipProps } from './Tooltip/Tooltip';
|
|
42
|
+
export { default as Upload, type UploadProps } from './Upload/Upload';
|
package/src/layouts/Grid/Row.tsx
CHANGED
package/src/layouts/index.ts
CHANGED
|
@@ -1,8 +1,3 @@
|
|
|
1
|
-
// Export all layout components individually for better tree-shaking
|
|
2
|
-
export * from './Grid';
|
|
3
|
-
export * from './MasonryGrid';
|
|
4
|
-
|
|
5
|
-
// Also provide a default export for convenience
|
|
6
1
|
import * as Grid from './Grid';
|
|
7
2
|
import * as MasonryGrid from './MasonryGrid';
|
|
8
3
|
|
|
@@ -11,4 +6,4 @@ const layouts = {
|
|
|
11
6
|
...MasonryGrid,
|
|
12
7
|
};
|
|
13
8
|
|
|
14
|
-
export default layouts;
|
|
9
|
+
export default layouts;
|
|
@@ -553,6 +553,11 @@ export interface NavItemProps extends BaseComponentProps {
|
|
|
553
553
|
* Whether dropdown/mega menu is expanded
|
|
554
554
|
*/
|
|
555
555
|
'aria-expanded'?: boolean;
|
|
556
|
+
|
|
557
|
+
/**
|
|
558
|
+
* Optional custom link component
|
|
559
|
+
*/
|
|
560
|
+
LinkComponent?: React.ElementType;
|
|
556
561
|
}
|
|
557
562
|
|
|
558
563
|
/**
|
|
@@ -763,6 +768,11 @@ export interface SideMenuItemProps extends BaseComponentProps {
|
|
|
763
768
|
* Link rel attribute
|
|
764
769
|
*/
|
|
765
770
|
rel?: string;
|
|
771
|
+
|
|
772
|
+
/**
|
|
773
|
+
* Optional custom link component
|
|
774
|
+
*/
|
|
775
|
+
LinkComponent?: React.ElementType;
|
|
766
776
|
}
|
|
767
777
|
|
|
768
778
|
/**
|
|
@@ -2113,6 +2123,11 @@ export interface DropdownItemProps extends BaseComponentProps {
|
|
|
2113
2123
|
* Item click handler
|
|
2114
2124
|
*/
|
|
2115
2125
|
onClick?: (event: React.MouseEvent<HTMLButtonElement | HTMLAnchorElement>) => void;
|
|
2126
|
+
|
|
2127
|
+
/**
|
|
2128
|
+
* Optional custom link component
|
|
2129
|
+
*/
|
|
2130
|
+
LinkComponent?: React.ElementType;
|
|
2116
2131
|
}
|
|
2117
2132
|
|
|
2118
2133
|
/**
|