react-lib-tools 0.0.10 → 0.0.12
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/GettingStartedRoute-Da-KZIf6.cjs +2 -0
- package/dist/GettingStartedRoute-Da-KZIf6.cjs.map +1 -0
- package/dist/GettingStartedRoute-n1iZy0On.js +38 -0
- package/dist/GettingStartedRoute-n1iZy0On.js.map +1 -0
- package/dist/PageNotFound-BbBqPkkF.js +24 -0
- package/dist/PageNotFound-BbBqPkkF.js.map +1 -0
- package/dist/PageNotFound-BhQMB2FT.cjs +2 -0
- package/dist/PageNotFound-BhQMB2FT.cjs.map +1 -0
- package/dist/SupportRoute-CmcE6ZZa.cjs +2 -0
- package/dist/SupportRoute-CmcE6ZZa.cjs.map +1 -0
- package/dist/SupportRoute-DuPMzYIe.js +44 -0
- package/dist/SupportRoute-DuPMzYIe.js.map +1 -0
- package/dist/index-BiL6y7tb.cjs +8 -0
- package/dist/index-BiL6y7tb.cjs.map +1 -0
- package/dist/index-CUStiGoe.js +9403 -0
- package/dist/index-CUStiGoe.js.map +1 -0
- package/dist/react-lib-tools.cjs +1 -7
- package/dist/react-lib-tools.cjs.map +1 -1
- package/dist/react-lib-tools.d.ts +28 -1
- package/dist/react-lib-tools.js +25 -9385
- package/dist/react-lib-tools.js.map +1 -1
- package/package.json +1 -1
- package/scripts/compile-docs.ts +16 -9
- package/scripts/compile-examples.ts +4 -2
- package/scripts/utils/docs/compileComponents.ts +3 -1
- package/scripts/utils/docs/compileImperativeHandles.ts +8 -5
- package/scripts/utils/syntax-highlight.ts +7 -1
- package/styles.css +1 -0
|
@@ -5,17 +5,20 @@ import { CSSProperties } from 'react';
|
|
|
5
5
|
import { HTMLAttributes } from 'react';
|
|
6
6
|
import { InputHTMLAttributes } from 'react';
|
|
7
7
|
import { JSX } from 'react/jsx-runtime';
|
|
8
|
+
import { KeyboardEvent as KeyboardEvent_2 } from 'react';
|
|
8
9
|
import { LazyExoticComponent } from 'react';
|
|
9
10
|
import { MouseEvent as MouseEvent_2 } from 'react';
|
|
10
11
|
import { PropsWithChildren } from 'react';
|
|
11
12
|
import { ReactNode } from 'react';
|
|
12
13
|
|
|
13
|
-
export declare function AppRoot({ hideVersions, navLinks, packageDescription, packageName, routes }: {
|
|
14
|
+
export declare function AppRoot({ hideVersions, navLinks, overview, packageDescription, packageName, routes, showOpenCollectLink }: {
|
|
14
15
|
hideVersions?: boolean | undefined;
|
|
15
16
|
navLinks: ReactNode;
|
|
17
|
+
overview?: ReactNode | undefined;
|
|
16
18
|
packageDescription: ReactNode;
|
|
17
19
|
packageName: string;
|
|
18
20
|
routes: Record<string, LazyExoticComponent<ComponentType<unknown>>>;
|
|
21
|
+
showOpenCollectLink?: boolean | undefined;
|
|
19
22
|
}): JSX.Element;
|
|
20
23
|
|
|
21
24
|
export declare function assert(expectedCondition: unknown, message?: string): asserts expectedCondition;
|
|
@@ -41,6 +44,7 @@ export declare function Button({ children, className, disabled, intent, ...rest
|
|
|
41
44
|
disabled?: boolean | undefined;
|
|
42
45
|
intent?: Intent | undefined;
|
|
43
46
|
onClick?: ((event: MouseEvent_2) => void) | undefined;
|
|
47
|
+
onKeyDown?: ((event: KeyboardEvent_2) => void) | undefined;
|
|
44
48
|
}>): JSX.Element;
|
|
45
49
|
|
|
46
50
|
export declare function Callout({ children, className, html, inline, intent, minimal, ...rest }: PropsWithChildren<HTMLAttributes<HTMLDivElement> & {
|
|
@@ -86,6 +90,13 @@ export declare function ComponentProps({ json, section }: {
|
|
|
86
90
|
section: string;
|
|
87
91
|
}): JSX.Element;
|
|
88
92
|
|
|
93
|
+
export declare function ComponentPropsSection({ header, props }: {
|
|
94
|
+
header: string;
|
|
95
|
+
props: ComponentPropMetadata[];
|
|
96
|
+
}): JSX.Element | null;
|
|
97
|
+
|
|
98
|
+
export declare type DefaultPath = keyof Routes;
|
|
99
|
+
|
|
89
100
|
export declare function DocsSection({ className, sections }: {
|
|
90
101
|
className?: string;
|
|
91
102
|
sections: Section[];
|
|
@@ -97,6 +108,8 @@ export declare function ExternalLink({ children, className, href, target, ...res
|
|
|
97
108
|
|
|
98
109
|
export declare function getIntentClassNames(intent: Intent, minimal?: boolean): "bg-red-950 text-red-300 [&_svg]:text-red-500" | "bg-black/10 bg-border border-2 border-red-500 text-white [&_svg]:text-red-500 [&_a]:text-red-400!" | "bg-white/10 text-slate-300 [&_svg]:text-slate-400" | "bg-black/10 bg-border border-2 border-white/40 text-white [&_svg]:text-white/60" | "bg-sky-950 text-sky-300 [&_svg]:text-sky-400" | "bg-black/10 bg-border border-2 border-sky-400 text-white [&_svg]:text-sky-400" | "bg-emerald-950 text-emerald-300 [&_svg]:text-emerald-400" | "bg-black/10 bg-border border-2 border-emerald-400 text-white [&_svg]:text-emerald-400" | "bg-amber-950/65 text-amber-200 [&_svg]:text-amber-300" | "bg-black/10 bg-border border-2 border-amber-400 text-white [&_svg]:text-amber-400 [&_a]:text-amber-400!";
|
|
99
110
|
|
|
111
|
+
declare function GettingStartedRoute(): JSX.Element;
|
|
112
|
+
|
|
100
113
|
export declare function Header({ section, title }: {
|
|
101
114
|
section?: string;
|
|
102
115
|
title: string;
|
|
@@ -150,6 +163,8 @@ declare type Option_2<Value extends string> = {
|
|
|
150
163
|
};
|
|
151
164
|
export { Option_2 as Option }
|
|
152
165
|
|
|
166
|
+
declare function PageNotFoundRoute(): JSX.Element;
|
|
167
|
+
|
|
153
168
|
export declare function Radio<Value extends string>({ checked, children, className, name, onChange, value, ...rest }: PropsWithChildren<Omit<HTMLAttributes<HTMLElement>, "defaultChecked" | "onChange"> & {
|
|
154
169
|
checked: boolean;
|
|
155
170
|
name: string;
|
|
@@ -162,6 +177,16 @@ declare type RenderFunction = (params: {
|
|
|
162
177
|
isPending: boolean;
|
|
163
178
|
}) => ReactNode;
|
|
164
179
|
|
|
180
|
+
declare type Route = LazyExoticComponent<ComponentType<unknown>>;
|
|
181
|
+
|
|
182
|
+
declare type Routes = Record<keyof typeof routes, Route>;
|
|
183
|
+
|
|
184
|
+
declare const routes: {
|
|
185
|
+
"*": LazyExoticComponent<PageNotFoundRoute>;
|
|
186
|
+
"/": LazyExoticComponent<GettingStartedRoute>;
|
|
187
|
+
"/support": LazyExoticComponent<SupportRoute>;
|
|
188
|
+
};
|
|
189
|
+
|
|
165
190
|
export declare type Section = {
|
|
166
191
|
content: string;
|
|
167
192
|
intent?: Intent | undefined;
|
|
@@ -176,4 +201,6 @@ export declare function Select<Value extends string>({ className, defaultValue,
|
|
|
176
201
|
value: Option_2<Value> | undefined;
|
|
177
202
|
}): JSX.Element;
|
|
178
203
|
|
|
204
|
+
declare function SupportRoute(): JSX.Element;
|
|
205
|
+
|
|
179
206
|
export { }
|