lucent-ui 0.23.0 → 0.25.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 +78 -46
- package/dist/index.d.ts +82 -3
- package/dist/index.js +3116 -2473
- package/dist-cli/cli/entry.js +0 -0
- package/dist-cli/cli/index.js +0 -0
- package/dist-server/server/index.js +0 -0
- package/dist-server/src/components/atoms/Text/Text.manifest.js +7 -1
- package/dist-server/src/components/molecules/Card/Card.manifest.js +32 -3
- package/dist-server/src/components/molecules/Collapsible/Collapsible.manifest.js +43 -3
- package/dist-server/src/components/molecules/NavMenu/NavMenu.manifest.js +256 -0
- package/dist-server/src/components/molecules/SearchInput/SearchInput.manifest.js +18 -4
- package/dist-server/src/manifest/validate.test.js +28 -0
- package/package.json +15 -13
package/dist/index.d.ts
CHANGED
|
@@ -145,7 +145,7 @@ export declare type ButtonSize = '2xs' | 'xs' | 'sm' | 'md' | 'lg';
|
|
|
145
145
|
|
|
146
146
|
export declare type ButtonVariant = 'primary' | 'secondary' | 'outline' | 'ghost' | 'danger' | 'danger-outline' | 'danger-ghost';
|
|
147
147
|
|
|
148
|
-
export declare function Card({ variant, header, footer, children, padding, shadow, radius, style, onClick, href, target, rel, disabled, status, selected, media, }: CardProps): JSX_2.Element;
|
|
148
|
+
export declare function Card({ variant, header, footer, children, padding, shadow, radius, style, onClick, href, target, rel, disabled, status, selected, hoverable, media, }: CardProps): JSX_2.Element;
|
|
149
149
|
|
|
150
150
|
export declare function CardBleed({ children, style }: CardBleedProps): JSX_2.Element;
|
|
151
151
|
|
|
@@ -183,6 +183,8 @@ export declare interface CardProps {
|
|
|
183
183
|
status?: CardStatus;
|
|
184
184
|
/** Accent inset ring indicating selection. */
|
|
185
185
|
selected?: boolean;
|
|
186
|
+
/** Enables hover/press visual feedback without making the card a button or link. */
|
|
187
|
+
hoverable?: boolean;
|
|
186
188
|
/** Full-bleed content rendered at the top (before header). */
|
|
187
189
|
media?: ReactNode;
|
|
188
190
|
}
|
|
@@ -275,7 +277,7 @@ export declare interface CodeBlockTab {
|
|
|
275
277
|
|
|
276
278
|
export declare type CodeBlockVariant = 'code' | 'prompt';
|
|
277
279
|
|
|
278
|
-
export declare function Collapsible({ trigger, children, defaultOpen, open, onOpenChange, style }: CollapsibleProps): JSX_2.Element;
|
|
280
|
+
export declare function Collapsible({ trigger, children, defaultOpen, open, onOpenChange, padded, disabled, style }: CollapsibleProps): JSX_2.Element;
|
|
279
281
|
|
|
280
282
|
export declare interface CollapsibleProps {
|
|
281
283
|
trigger: ReactNode;
|
|
@@ -283,6 +285,10 @@ export declare interface CollapsibleProps {
|
|
|
283
285
|
defaultOpen?: boolean;
|
|
284
286
|
open?: boolean;
|
|
285
287
|
onOpenChange?: (open: boolean) => void;
|
|
288
|
+
/** When false, removes the default content padding so children can provide their own. */
|
|
289
|
+
padded?: boolean;
|
|
290
|
+
/** Disables the trigger button. */
|
|
291
|
+
disabled?: boolean;
|
|
286
292
|
style?: CSSProperties;
|
|
287
293
|
}
|
|
288
294
|
|
|
@@ -913,6 +919,76 @@ export declare interface NavLinkProps {
|
|
|
913
919
|
style?: CSSProperties;
|
|
914
920
|
}
|
|
915
921
|
|
|
922
|
+
export declare function NavMenu({ children, orientation, inverse, size, hasIcons, style, 'aria-label': ariaLabel, }: NavMenuProps): JSX_2.Element;
|
|
923
|
+
|
|
924
|
+
export declare namespace NavMenu {
|
|
925
|
+
var Item: typeof NavMenuItem;
|
|
926
|
+
var Group: typeof NavMenuGroup;
|
|
927
|
+
var Sub: typeof NavMenuSub;
|
|
928
|
+
var Separator: typeof NavMenuSeparator;
|
|
929
|
+
}
|
|
930
|
+
|
|
931
|
+
export declare function NavMenuGroup({ children, label, defaultOpen, open, onOpenChange, collapsible: collapsibleProp, style, }: NavMenuGroupProps): JSX_2.Element;
|
|
932
|
+
|
|
933
|
+
export declare interface NavMenuGroupProps {
|
|
934
|
+
children: ReactNode;
|
|
935
|
+
/** Section header label. */
|
|
936
|
+
label?: ReactNode;
|
|
937
|
+
/** Whether this group starts open. Only applies to vertical orientation. */
|
|
938
|
+
defaultOpen?: boolean;
|
|
939
|
+
/** Controlled open state. */
|
|
940
|
+
open?: boolean;
|
|
941
|
+
/** Callback when the group open state changes. */
|
|
942
|
+
onOpenChange?: (open: boolean) => void;
|
|
943
|
+
/** Whether the group is collapsible. Defaults to `true` when a label is provided. */
|
|
944
|
+
collapsible?: boolean;
|
|
945
|
+
style?: CSSProperties;
|
|
946
|
+
}
|
|
947
|
+
|
|
948
|
+
export declare function NavMenuItem({ children, href, isActive, icon, badge, disabled, onClick, as, style, }: NavMenuItemProps): JSX_2.Element;
|
|
949
|
+
|
|
950
|
+
export declare interface NavMenuItemProps {
|
|
951
|
+
children: ReactNode;
|
|
952
|
+
href?: string;
|
|
953
|
+
isActive?: boolean;
|
|
954
|
+
icon?: ReactNode;
|
|
955
|
+
badge?: ReactNode;
|
|
956
|
+
disabled?: boolean;
|
|
957
|
+
onClick?: MouseEventHandler;
|
|
958
|
+
/** Polymorphic root element. Defaults to `<a>`. Use e.g. `Link` from react-router. */
|
|
959
|
+
as?: React.ElementType;
|
|
960
|
+
style?: CSSProperties;
|
|
961
|
+
}
|
|
962
|
+
|
|
963
|
+
export declare interface NavMenuProps {
|
|
964
|
+
children: ReactNode;
|
|
965
|
+
/** Layout direction. Defaults to `"vertical"`. */
|
|
966
|
+
orientation?: 'vertical' | 'horizontal';
|
|
967
|
+
/** Uses surface background instead of accent for the active state. */
|
|
968
|
+
inverse?: boolean;
|
|
969
|
+
/** Size variant. `"sm"` for compact sidebar layouts. Defaults to `"md"`. */
|
|
970
|
+
size?: NavMenuSize;
|
|
971
|
+
/** Whether items use icons. Tightens left padding so group headers align with icons. */
|
|
972
|
+
hasIcons?: boolean;
|
|
973
|
+
style?: CSSProperties;
|
|
974
|
+
/** Accessible label for the `<nav>` element. */
|
|
975
|
+
'aria-label'?: string;
|
|
976
|
+
}
|
|
977
|
+
|
|
978
|
+
export declare function NavMenuSeparator({ style }: NavMenuSeparatorProps): JSX_2.Element;
|
|
979
|
+
|
|
980
|
+
export declare interface NavMenuSeparatorProps {
|
|
981
|
+
style?: CSSProperties;
|
|
982
|
+
}
|
|
983
|
+
|
|
984
|
+
declare type NavMenuSize = 'sm' | 'md' | 'lg';
|
|
985
|
+
|
|
986
|
+
export declare function NavMenuSub({ children }: NavMenuSubProps): JSX_2.Element;
|
|
987
|
+
|
|
988
|
+
export declare interface NavMenuSubProps {
|
|
989
|
+
children: ReactNode;
|
|
990
|
+
}
|
|
991
|
+
|
|
916
992
|
export declare const oceanPalette: ColorPalette;
|
|
917
993
|
|
|
918
994
|
export declare function PageLayout({ children, header, sidebar, sidebarWidth, headerHeight, sidebarCollapsed, rightSidebar, rightSidebarWidth, rightSidebarCollapsed, footer, footerHeight, chromeBackground, mainStyle, style, }: PageLayoutProps): JSX_2.Element;
|
|
@@ -1079,13 +1155,16 @@ export declare interface RowProps {
|
|
|
1079
1155
|
'aria-labelledby'?: string;
|
|
1080
1156
|
}
|
|
1081
1157
|
|
|
1082
|
-
export declare function SearchInput({ value, onChange, placeholder, size, label, helperText, errorText, results, onResultSelect, isLoading, disabled, id, style, }: SearchInputProps): JSX_2.Element;
|
|
1158
|
+
export declare function SearchInput({ value, onChange, mode, placeholder, size, label, helperText, errorText, results, onResultSelect, isLoading, disabled, id, style, }: SearchInputProps): JSX_2.Element;
|
|
1083
1159
|
|
|
1084
1160
|
export declare const SearchInputManifest: ComponentManifest;
|
|
1085
1161
|
|
|
1162
|
+
export declare type SearchInputMode = 'search' | 'filter';
|
|
1163
|
+
|
|
1086
1164
|
export declare interface SearchInputProps {
|
|
1087
1165
|
value: string;
|
|
1088
1166
|
onChange: (value: string) => void;
|
|
1167
|
+
mode?: SearchInputMode;
|
|
1089
1168
|
placeholder?: string;
|
|
1090
1169
|
size?: InputSize;
|
|
1091
1170
|
label?: string;
|