lucent-ui 0.22.0 → 0.24.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/index.cjs +113 -86
- package/dist/index.d.ts +130 -0
- package/dist/index.js +4557 -3563
- package/dist-server/src/components/atoms/ButtonGroup/ButtonGroup.manifest.js +43 -0
- package/dist-server/src/components/atoms/SplitButton/SplitButton.manifest.js +75 -0
- package/dist-server/src/components/molecules/NavMenu/NavMenu.manifest.js +247 -0
- package/dist-server/src/manifest/examples/button.manifest.js +11 -5
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -107,6 +107,21 @@ export declare interface BreadcrumbProps {
|
|
|
107
107
|
|
|
108
108
|
export declare const Button: ForwardRefExoticComponent<ButtonProps & RefAttributes<HTMLButtonElement>>;
|
|
109
109
|
|
|
110
|
+
export declare function ButtonGroup({ children, style, }: ButtonGroupProps): JSX_2.Element;
|
|
111
|
+
|
|
112
|
+
export declare namespace ButtonGroup {
|
|
113
|
+
var displayName: string;
|
|
114
|
+
}
|
|
115
|
+
|
|
116
|
+
export declare const ButtonGroupManifest: ComponentManifest;
|
|
117
|
+
|
|
118
|
+
export declare interface ButtonGroupProps {
|
|
119
|
+
/** Button or SplitButton children to group. */
|
|
120
|
+
children: ReactNode;
|
|
121
|
+
/** Style overrides for the wrapper. */
|
|
122
|
+
style?: CSSProperties;
|
|
123
|
+
}
|
|
124
|
+
|
|
110
125
|
export declare const ButtonManifest: ComponentManifest;
|
|
111
126
|
|
|
112
127
|
export declare interface ButtonProps extends ButtonHTMLAttributes<HTMLButtonElement> {
|
|
@@ -898,6 +913,76 @@ export declare interface NavLinkProps {
|
|
|
898
913
|
style?: CSSProperties;
|
|
899
914
|
}
|
|
900
915
|
|
|
916
|
+
export declare function NavMenu({ children, orientation, inverse, size, hasIcons, style, 'aria-label': ariaLabel, }: NavMenuProps): JSX_2.Element;
|
|
917
|
+
|
|
918
|
+
export declare namespace NavMenu {
|
|
919
|
+
var Item: typeof NavMenuItem;
|
|
920
|
+
var Group: typeof NavMenuGroup;
|
|
921
|
+
var Sub: typeof NavMenuSub;
|
|
922
|
+
var Separator: typeof NavMenuSeparator;
|
|
923
|
+
}
|
|
924
|
+
|
|
925
|
+
export declare function NavMenuGroup({ children, label, defaultOpen, open, onOpenChange, collapsible: collapsibleProp, style, }: NavMenuGroupProps): JSX_2.Element;
|
|
926
|
+
|
|
927
|
+
export declare interface NavMenuGroupProps {
|
|
928
|
+
children: ReactNode;
|
|
929
|
+
/** Section header label. */
|
|
930
|
+
label?: ReactNode;
|
|
931
|
+
/** Whether this group starts open. Only applies to vertical orientation. */
|
|
932
|
+
defaultOpen?: boolean;
|
|
933
|
+
/** Controlled open state. */
|
|
934
|
+
open?: boolean;
|
|
935
|
+
/** Callback when the group open state changes. */
|
|
936
|
+
onOpenChange?: (open: boolean) => void;
|
|
937
|
+
/** Whether the group is collapsible. Defaults to `true` when a label is provided. */
|
|
938
|
+
collapsible?: boolean;
|
|
939
|
+
style?: CSSProperties;
|
|
940
|
+
}
|
|
941
|
+
|
|
942
|
+
export declare function NavMenuItem({ children, href, isActive, icon, badge, disabled, onClick, as, style, }: NavMenuItemProps): JSX_2.Element;
|
|
943
|
+
|
|
944
|
+
export declare interface NavMenuItemProps {
|
|
945
|
+
children: ReactNode;
|
|
946
|
+
href?: string;
|
|
947
|
+
isActive?: boolean;
|
|
948
|
+
icon?: ReactNode;
|
|
949
|
+
badge?: ReactNode;
|
|
950
|
+
disabled?: boolean;
|
|
951
|
+
onClick?: MouseEventHandler;
|
|
952
|
+
/** Polymorphic root element. Defaults to `<a>`. Use e.g. `Link` from react-router. */
|
|
953
|
+
as?: React.ElementType;
|
|
954
|
+
style?: CSSProperties;
|
|
955
|
+
}
|
|
956
|
+
|
|
957
|
+
export declare interface NavMenuProps {
|
|
958
|
+
children: ReactNode;
|
|
959
|
+
/** Layout direction. Defaults to `"vertical"`. */
|
|
960
|
+
orientation?: 'vertical' | 'horizontal';
|
|
961
|
+
/** Uses surface background instead of accent for the active state. */
|
|
962
|
+
inverse?: boolean;
|
|
963
|
+
/** Size variant. `"sm"` for compact sidebar layouts. Defaults to `"md"`. */
|
|
964
|
+
size?: NavMenuSize;
|
|
965
|
+
/** Whether items use icons. Tightens left padding so group headers align with icons. */
|
|
966
|
+
hasIcons?: boolean;
|
|
967
|
+
style?: CSSProperties;
|
|
968
|
+
/** Accessible label for the `<nav>` element. */
|
|
969
|
+
'aria-label'?: string;
|
|
970
|
+
}
|
|
971
|
+
|
|
972
|
+
export declare function NavMenuSeparator({ style }: NavMenuSeparatorProps): JSX_2.Element;
|
|
973
|
+
|
|
974
|
+
export declare interface NavMenuSeparatorProps {
|
|
975
|
+
style?: CSSProperties;
|
|
976
|
+
}
|
|
977
|
+
|
|
978
|
+
declare type NavMenuSize = 'sm' | 'md' | 'lg';
|
|
979
|
+
|
|
980
|
+
export declare function NavMenuSub({ children }: NavMenuSubProps): JSX_2.Element;
|
|
981
|
+
|
|
982
|
+
export declare interface NavMenuSubProps {
|
|
983
|
+
children: ReactNode;
|
|
984
|
+
}
|
|
985
|
+
|
|
901
986
|
export declare const oceanPalette: ColorPalette;
|
|
902
987
|
|
|
903
988
|
export declare function PageLayout({ children, header, sidebar, sidebarWidth, headerHeight, sidebarCollapsed, rightSidebar, rightSidebarWidth, rightSidebarCollapsed, footer, footerHeight, chromeBackground, mainStyle, style, }: PageLayoutProps): JSX_2.Element;
|
|
@@ -1270,6 +1355,51 @@ export declare interface SpinnerProps {
|
|
|
1270
1355
|
|
|
1271
1356
|
export declare type SpinnerSize = 'xs' | 'sm' | 'md' | 'lg';
|
|
1272
1357
|
|
|
1358
|
+
export declare function SplitButton({ children, onClick, menuItems, variant, size, bordered, menuPlacement, disabled, loading, leftIcon, style, }: SplitButtonProps): JSX_2.Element;
|
|
1359
|
+
|
|
1360
|
+
export declare namespace SplitButton {
|
|
1361
|
+
var displayName: string;
|
|
1362
|
+
}
|
|
1363
|
+
|
|
1364
|
+
export declare const SplitButtonManifest: ComponentManifest;
|
|
1365
|
+
|
|
1366
|
+
export declare interface SplitButtonMenuItem {
|
|
1367
|
+
label: string;
|
|
1368
|
+
onSelect: () => void;
|
|
1369
|
+
disabled?: boolean;
|
|
1370
|
+
danger?: boolean;
|
|
1371
|
+
icon?: ReactNode;
|
|
1372
|
+
}
|
|
1373
|
+
|
|
1374
|
+
export declare interface SplitButtonProps {
|
|
1375
|
+
/** Primary button label. */
|
|
1376
|
+
children: ReactNode;
|
|
1377
|
+
/** Handler for the primary action (left half). */
|
|
1378
|
+
onClick: () => void;
|
|
1379
|
+
/** Items shown in the dropdown menu. */
|
|
1380
|
+
menuItems: SplitButtonMenuItem[];
|
|
1381
|
+
/** Visual variant applied to both halves. */
|
|
1382
|
+
variant?: SplitButtonVariant;
|
|
1383
|
+
/** Size applied to both halves. */
|
|
1384
|
+
size?: SplitButtonSize;
|
|
1385
|
+
/** If false, removes the border on both halves. */
|
|
1386
|
+
bordered?: boolean;
|
|
1387
|
+
/** Dropdown placement relative to the chevron trigger. */
|
|
1388
|
+
menuPlacement?: MenuPlacement;
|
|
1389
|
+
/** Disables both halves. */
|
|
1390
|
+
disabled?: boolean;
|
|
1391
|
+
/** Shows a spinner in the primary half and disables both. */
|
|
1392
|
+
loading?: boolean;
|
|
1393
|
+
/** Icon rendered before the label in the primary half. */
|
|
1394
|
+
leftIcon?: ReactNode;
|
|
1395
|
+
/** Style overrides for the wrapper. */
|
|
1396
|
+
style?: CSSProperties;
|
|
1397
|
+
}
|
|
1398
|
+
|
|
1399
|
+
export declare type SplitButtonSize = '2xs' | 'xs' | 'sm' | 'md' | 'lg';
|
|
1400
|
+
|
|
1401
|
+
export declare type SplitButtonVariant = 'primary' | 'secondary' | 'outline' | 'ghost' | 'danger' | 'danger-outline' | 'danger-ghost';
|
|
1402
|
+
|
|
1273
1403
|
export declare function Stack({ gap, align, justify, as, wrap, children, style, ...rest }: StackProps): JSX_2.Element;
|
|
1274
1404
|
|
|
1275
1405
|
export declare type StackAlign = 'start' | 'center' | 'end' | 'stretch' | 'baseline';
|