@versaur/react 1.0.13 → 1.0.15
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/blocks.d.ts +36 -110
- package/dist/blocks.js +535 -709
- package/dist/drawer-BjNHPqBr.js +120 -0
- package/dist/forms.d.ts +125 -0
- package/dist/forms.js +615 -321
- package/dist/helpers-D23F5WBX.js +159 -0
- package/dist/{overlay-parts-Zq9CuT31.js → overlay-parts-BtD-Qj_k.js} +3 -3
- package/dist/primitive.d.ts +13 -0
- package/dist/primitive.js +16 -205
- package/dist/tooltip-Cn7Ml9vw.js +364 -0
- package/dist/utils.d.ts +87 -0
- package/dist/utils.js +62 -5
- package/package.json +2 -2
- package/dist/tooltip-_eEMRSo8.js +0 -268
- package/dist/use-data-attrs-iPFyfiKN.js +0 -16
package/dist/blocks.d.ts
CHANGED
|
@@ -98,10 +98,6 @@ declare interface AppLayoutType extends ForwardRefExoticComponent<AppLayoutRootP
|
|
|
98
98
|
SideRight: ForwardRefExoticComponent<AppLayoutRegionProps & RefAttributes<HTMLElement>>;
|
|
99
99
|
}
|
|
100
100
|
|
|
101
|
-
declare interface AsProp<C extends ElementType = ElementType> {
|
|
102
|
-
as?: C;
|
|
103
|
-
}
|
|
104
|
-
|
|
105
101
|
export declare namespace AttributeList {
|
|
106
102
|
export type Layout = AttributeList_2.Layout;
|
|
107
103
|
export type Props = AttributeListProps;
|
|
@@ -891,111 +887,6 @@ export declare interface ModalRootProps extends Omit<DialogHTMLAttributes<HTMLDi
|
|
|
891
887
|
children?: ReactNode;
|
|
892
888
|
}
|
|
893
889
|
|
|
894
|
-
/**
|
|
895
|
-
* Namespace merging: Nav.Item syntax
|
|
896
|
-
*/
|
|
897
|
-
export declare const Nav: ForwardRefExoticComponent<NavProps & RefAttributes<HTMLElement>> & {
|
|
898
|
-
Item: ForwardRefExoticComponent<Omit<NavItemProps, "ref"> & RefAttributes<HTMLButtonElement | HTMLAnchorElement>>;
|
|
899
|
-
};
|
|
900
|
-
|
|
901
|
-
/**
|
|
902
|
-
* NavItem - Polymorphic navigation item
|
|
903
|
-
*
|
|
904
|
-
* Renders as button by default, but supports any element type (a, Link, custom).
|
|
905
|
-
* Supports left and right icons for flexible composition.
|
|
906
|
-
*
|
|
907
|
-
* Can be used in two modes:
|
|
908
|
-
* - Uncontrolled: Pass `active` prop and handle clicks with `onClick`
|
|
909
|
-
* - Controlled: Use within Nav with `value` and let Nav manage active state
|
|
910
|
-
*
|
|
911
|
-
* @example
|
|
912
|
-
* ```tsx
|
|
913
|
-
* // Uncontrolled
|
|
914
|
-
* <Nav>
|
|
915
|
-
* <Nav.Item active onClick={handleHome}>Home</Nav.Item>
|
|
916
|
-
* <Nav.Item>Docs</Nav.Item>
|
|
917
|
-
* </Nav>
|
|
918
|
-
*
|
|
919
|
-
* // Controlled (recommended)
|
|
920
|
-
* const [active, setActive] = useState('home');
|
|
921
|
-
* <Nav value={active} onChange={setActive}>
|
|
922
|
-
* <Nav.Item value="home">Home</Nav.Item>
|
|
923
|
-
* <Nav.Item value="docs">Docs</Nav.Item>
|
|
924
|
-
* </Nav>
|
|
925
|
-
*
|
|
926
|
-
* // With icons
|
|
927
|
-
* <Nav.Item leftIcon={HomeIcon} value="home">Home</Nav.Item>
|
|
928
|
-
* <Nav.Item rightIcon={ChevronIcon} value="more">More</Nav.Item>
|
|
929
|
-
* ```
|
|
930
|
-
*/
|
|
931
|
-
export declare const NavItem: ForwardRefExoticComponent<Omit<NavItemProps, "ref"> & RefAttributes<HTMLButtonElement | HTMLAnchorElement>>;
|
|
932
|
-
|
|
933
|
-
/**
|
|
934
|
-
* NavItem base props
|
|
935
|
-
*/
|
|
936
|
-
declare interface NavItemBaseProps {
|
|
937
|
-
/**
|
|
938
|
-
* Whether this nav item represents current page (uncontrolled)
|
|
939
|
-
* Sets aria-current="page" for anchor/Link elements
|
|
940
|
-
* Ignored if Nav has value/onChange (controlled mode)
|
|
941
|
-
*/
|
|
942
|
-
active?: boolean;
|
|
943
|
-
/**
|
|
944
|
-
* Unique identifier for this item in controlled mode
|
|
945
|
-
* When Nav has onChange, this value is passed to onChange when clicked
|
|
946
|
-
*/
|
|
947
|
-
value?: string | number;
|
|
948
|
-
/**
|
|
949
|
-
* Icon to render on the left side of the text
|
|
950
|
-
*/
|
|
951
|
-
leftIcon?: ComponentType<SVGProps<SVGSVGElement>>;
|
|
952
|
-
/**
|
|
953
|
-
* Icon to render on the right side of the text
|
|
954
|
-
*/
|
|
955
|
-
rightIcon?: ComponentType<SVGProps<SVGSVGElement>>;
|
|
956
|
-
/**
|
|
957
|
-
* Loading state - disables interaction and shows visual loading indicator
|
|
958
|
-
*/
|
|
959
|
-
loading?: boolean;
|
|
960
|
-
/**
|
|
961
|
-
* Disabled state - prevents all interactions
|
|
962
|
-
*/
|
|
963
|
-
disabled?: boolean;
|
|
964
|
-
children?: ReactNode;
|
|
965
|
-
}
|
|
966
|
-
|
|
967
|
-
/**
|
|
968
|
-
* Polymorphic NavItem type
|
|
969
|
-
* Defaults to "button" but supports "a", Next.js Link, React Router Link, or any custom component
|
|
970
|
-
*/
|
|
971
|
-
export declare type NavItemProps<C extends ElementType = ElementType> = PolymorphicProps<C, NavItemBaseProps>;
|
|
972
|
-
|
|
973
|
-
/**
|
|
974
|
-
* Nav props
|
|
975
|
-
*/
|
|
976
|
-
export declare interface NavProps extends Omit<HTMLAttributes<HTMLElement>, "onChange"> {
|
|
977
|
-
/**
|
|
978
|
-
* Layout direction for the navigation container
|
|
979
|
-
* @default "horizontal"
|
|
980
|
-
*/
|
|
981
|
-
direction?: "horizontal" | "vertical";
|
|
982
|
-
/**
|
|
983
|
-
* Gap between nav items
|
|
984
|
-
* Uses Versaur spacing scale: xs, sm, md, lg
|
|
985
|
-
*/
|
|
986
|
-
gap?: "xs" | "sm" | "md" | "lg";
|
|
987
|
-
/**
|
|
988
|
-
* Controlled value - which nav item is currently active
|
|
989
|
-
* @default undefined
|
|
990
|
-
*/
|
|
991
|
-
value?: string | number;
|
|
992
|
-
/**
|
|
993
|
-
* Callback when a nav item is selected
|
|
994
|
-
*/
|
|
995
|
-
onChange?: (value: string | number) => void;
|
|
996
|
-
children?: ReactNode;
|
|
997
|
-
}
|
|
998
|
-
|
|
999
890
|
/**
|
|
1000
891
|
* NoResults component - displays an empty state with icon, title, subtitle, and optional action
|
|
1001
892
|
*
|
|
@@ -1069,7 +960,34 @@ declare interface OverlayTitleProps extends HTMLAttributes<HTMLHeadingElement> {
|
|
|
1069
960
|
as?: ElementType;
|
|
1070
961
|
}
|
|
1071
962
|
|
|
1072
|
-
declare
|
|
963
|
+
export declare const PageHeader: PageHeaderComponent;
|
|
964
|
+
|
|
965
|
+
export declare interface PageHeaderComponent extends ForwardRefExoticComponent<PageHeaderRootProps & RefAttributes<HTMLElement>> {
|
|
966
|
+
Title: ForwardRefExoticComponent<PageHeaderTitleProps & RefAttributes<HTMLDivElement>>;
|
|
967
|
+
Subtitle: ForwardRefExoticComponent<PageHeaderSubtitleProps & RefAttributes<HTMLElement>>;
|
|
968
|
+
}
|
|
969
|
+
|
|
970
|
+
export declare interface PageHeaderRootProps extends Omit<HTMLAttributes<HTMLElement>, "title"> {
|
|
971
|
+
title?: ReactNode;
|
|
972
|
+
subtitle?: ReactNode;
|
|
973
|
+
supplementary?: ReactNode;
|
|
974
|
+
}
|
|
975
|
+
|
|
976
|
+
/** Alias for Text — all TextProps forwarded to the internal <Text> */
|
|
977
|
+
export declare interface PageHeaderSubtitleProps extends HTMLAttributes<HTMLParagraphElement> {
|
|
978
|
+
/** Content rendered to the right of the subtitle text */
|
|
979
|
+
additionalInfo?: ReactNode;
|
|
980
|
+
children?: ReactNode;
|
|
981
|
+
}
|
|
982
|
+
|
|
983
|
+
/** Exposes Heading visual props — all forwarded to the internal <Heading> */
|
|
984
|
+
export declare interface PageHeaderTitleProps extends Pick<HTMLAttributes<HTMLDivElement>, "className" | "style"> {
|
|
985
|
+
/** Icon/button rendered to the right of the heading text. Activates sub-grid layout. */
|
|
986
|
+
action?: ReactNode;
|
|
987
|
+
/** Content rendered below the heading row (badges, status chips, etc.) */
|
|
988
|
+
additionalInfo?: ReactNode;
|
|
989
|
+
children?: ReactNode;
|
|
990
|
+
}
|
|
1073
991
|
|
|
1074
992
|
/**
|
|
1075
993
|
* Compound Sidebar component with sub-components
|
|
@@ -1406,6 +1324,14 @@ export declare interface TabsItemProps extends Omit<React.HTMLAttributes<HTMLDiv
|
|
|
1406
1324
|
* Whether the item is disabled
|
|
1407
1325
|
*/
|
|
1408
1326
|
disabled?: boolean;
|
|
1327
|
+
/**
|
|
1328
|
+
* Icon element to display on the left side
|
|
1329
|
+
*/
|
|
1330
|
+
leftIcon?: ReactNode;
|
|
1331
|
+
/**
|
|
1332
|
+
* Icon element to display on the right side
|
|
1333
|
+
*/
|
|
1334
|
+
rightIcon?: ReactNode;
|
|
1409
1335
|
/**
|
|
1410
1336
|
* The content of the item
|
|
1411
1337
|
*/
|