@nswds/app 1.35.0 → 1.37.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/globals.css +724 -79
- package/dist/index.cjs +326 -151
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +29 -2
- package/dist/index.d.ts +29 -2
- package/dist/index.js +307 -141
- package/dist/index.js.map +1 -1
- package/dist/styles.css +721 -79
- package/dist/styles.css.map +1 -1
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -2,12 +2,12 @@
|
|
|
2
2
|
|
|
3
3
|
var AccordionPrimitive = require('@radix-ui/react-accordion');
|
|
4
4
|
var jsxRuntime = require('react/jsx-runtime');
|
|
5
|
-
var
|
|
5
|
+
var clsx4 = require('clsx');
|
|
6
6
|
var tailwindMerge = require('tailwind-merge');
|
|
7
7
|
var classVarianceAuthority = require('class-variance-authority');
|
|
8
8
|
var AspectRatioPrimitive = require('@radix-ui/react-aspect-ratio');
|
|
9
9
|
var AvatarPrimitive = require('@radix-ui/react-avatar');
|
|
10
|
-
var
|
|
10
|
+
var Headless4 = require('@headlessui/react');
|
|
11
11
|
var React15 = require('react');
|
|
12
12
|
var Link10 = require('next/link');
|
|
13
13
|
var culori = require('culori');
|
|
@@ -27,7 +27,6 @@ require('prismjs/components/prism-tsx');
|
|
|
27
27
|
require('prismjs/components/prism-typescript');
|
|
28
28
|
var SelectPrimitive = require('@radix-ui/react-select');
|
|
29
29
|
var PopoverPrimitive = require('@radix-ui/react-popover');
|
|
30
|
-
var LabelPrimitive = require('@radix-ui/react-label');
|
|
31
30
|
var RadioGroupPrimitive = require('@radix-ui/react-radio-group');
|
|
32
31
|
var lucideReact = require('lucide-react');
|
|
33
32
|
var TabsPrimitive2 = require('@radix-ui/react-tabs');
|
|
@@ -40,6 +39,7 @@ var ContextMenuPrimitive = require('@radix-ui/react-context-menu');
|
|
|
40
39
|
var vaul = require('vaul');
|
|
41
40
|
var SeparatorPrimitive = require('@radix-ui/react-separator');
|
|
42
41
|
var reactHookForm = require('react-hook-form');
|
|
42
|
+
var LabelPrimitive = require('@radix-ui/react-label');
|
|
43
43
|
var ToggleGroupPrimitive = require('@radix-ui/react-toggle-group');
|
|
44
44
|
var TogglePrimitive = require('@radix-ui/react-toggle');
|
|
45
45
|
var MenubarPrimitive = require('@radix-ui/react-menubar');
|
|
@@ -82,10 +82,10 @@ function _interopNamespace(e) {
|
|
|
82
82
|
}
|
|
83
83
|
|
|
84
84
|
var AccordionPrimitive__namespace = /*#__PURE__*/_interopNamespace(AccordionPrimitive);
|
|
85
|
-
var
|
|
85
|
+
var clsx4__default = /*#__PURE__*/_interopDefault(clsx4);
|
|
86
86
|
var AspectRatioPrimitive__namespace = /*#__PURE__*/_interopNamespace(AspectRatioPrimitive);
|
|
87
87
|
var AvatarPrimitive__namespace = /*#__PURE__*/_interopNamespace(AvatarPrimitive);
|
|
88
|
-
var
|
|
88
|
+
var Headless4__namespace = /*#__PURE__*/_interopNamespace(Headless4);
|
|
89
89
|
var React15__namespace = /*#__PURE__*/_interopNamespace(React15);
|
|
90
90
|
var Link10__default = /*#__PURE__*/_interopDefault(Link10);
|
|
91
91
|
var culori__namespace = /*#__PURE__*/_interopNamespace(culori);
|
|
@@ -95,13 +95,13 @@ var TooltipPrimitive__namespace = /*#__PURE__*/_interopNamespace(TooltipPrimitiv
|
|
|
95
95
|
var Prism__default = /*#__PURE__*/_interopDefault(Prism);
|
|
96
96
|
var SelectPrimitive__namespace = /*#__PURE__*/_interopNamespace(SelectPrimitive);
|
|
97
97
|
var PopoverPrimitive__namespace = /*#__PURE__*/_interopNamespace(PopoverPrimitive);
|
|
98
|
-
var LabelPrimitive__namespace = /*#__PURE__*/_interopNamespace(LabelPrimitive);
|
|
99
98
|
var RadioGroupPrimitive__namespace = /*#__PURE__*/_interopNamespace(RadioGroupPrimitive);
|
|
100
99
|
var TabsPrimitive2__namespace = /*#__PURE__*/_interopNamespace(TabsPrimitive2);
|
|
101
100
|
var CollapsiblePrimitive__namespace = /*#__PURE__*/_interopNamespace(CollapsiblePrimitive);
|
|
102
101
|
var DialogPrimitive__namespace = /*#__PURE__*/_interopNamespace(DialogPrimitive);
|
|
103
102
|
var ContextMenuPrimitive__namespace = /*#__PURE__*/_interopNamespace(ContextMenuPrimitive);
|
|
104
103
|
var SeparatorPrimitive__namespace = /*#__PURE__*/_interopNamespace(SeparatorPrimitive);
|
|
104
|
+
var LabelPrimitive__namespace = /*#__PURE__*/_interopNamespace(LabelPrimitive);
|
|
105
105
|
var ToggleGroupPrimitive__namespace = /*#__PURE__*/_interopNamespace(ToggleGroupPrimitive);
|
|
106
106
|
var TogglePrimitive__namespace = /*#__PURE__*/_interopNamespace(TogglePrimitive);
|
|
107
107
|
var MenubarPrimitive__namespace = /*#__PURE__*/_interopNamespace(MenubarPrimitive);
|
|
@@ -213,7 +213,7 @@ var Icons = {
|
|
|
213
213
|
west: (props) => /* @__PURE__ */ jsxRuntime.jsx("svg", { fill: "currentColor", "data-slot": "icon", viewBox: "0 -960 960 960", ...props, children: /* @__PURE__ */ jsxRuntime.jsx("path", { d: "M233-440h607q17 0 28.5-11.5T880-480q0-17-11.5-28.5T840-520H233l155-156q11-11 11.5-27.5T388-732q-11-11-28-11t-28 11L108-508q-6 6-8.5 13T97-480q0 8 2.5 15t8.5 13l224 224q11 11 27.5 11t28.5-11q12-12 12-28.5T388-285L233-440Z" }) })
|
|
214
214
|
};
|
|
215
215
|
function cn(...inputs) {
|
|
216
|
-
return tailwindMerge.twMerge(
|
|
216
|
+
return tailwindMerge.twMerge(clsx4.clsx(inputs));
|
|
217
217
|
}
|
|
218
218
|
function truncate(text, maxLength) {
|
|
219
219
|
if (text.length <= maxLength) {
|
|
@@ -409,7 +409,7 @@ function AvatarFallback({
|
|
|
409
409
|
);
|
|
410
410
|
}
|
|
411
411
|
var Link = React15.forwardRef(function Link2(props, ref) {
|
|
412
|
-
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
412
|
+
return /* @__PURE__ */ jsxRuntime.jsx(Headless4__namespace.DataInteractive, { children: /* @__PURE__ */ jsxRuntime.jsx(Link10__default.default, { ...props, ref }) });
|
|
413
413
|
});
|
|
414
414
|
var styles = {
|
|
415
415
|
base: [
|
|
@@ -732,11 +732,11 @@ var Button2 = React15.forwardRef(function Button3({ className, variant, color, s
|
|
|
732
732
|
children: /* @__PURE__ */ jsxRuntime.jsx(TouchTarget, { children })
|
|
733
733
|
}
|
|
734
734
|
) : /* @__PURE__ */ jsxRuntime.jsx(
|
|
735
|
-
|
|
735
|
+
Headless4__namespace.Button,
|
|
736
736
|
{
|
|
737
737
|
"data-variant": variant,
|
|
738
738
|
...props,
|
|
739
|
-
className:
|
|
739
|
+
className: clsx4__default.default(classes, "cursor-pointer"),
|
|
740
740
|
ref,
|
|
741
741
|
children: /* @__PURE__ */ jsxRuntime.jsx(TouchTarget, { children })
|
|
742
742
|
}
|
|
@@ -1201,7 +1201,7 @@ var BadgeButton = React15.forwardRef(function BadgeButton2({
|
|
|
1201
1201
|
children,
|
|
1202
1202
|
...props
|
|
1203
1203
|
}, ref) {
|
|
1204
|
-
const classes =
|
|
1204
|
+
const classes = clsx4__default.default(className, focusOutline[color], [
|
|
1205
1205
|
// Base
|
|
1206
1206
|
"group relative inline-flex rounded-sm",
|
|
1207
1207
|
// Focus
|
|
@@ -1219,11 +1219,11 @@ var BadgeButton = React15.forwardRef(function BadgeButton2({
|
|
|
1219
1219
|
children: /* @__PURE__ */ jsxRuntime.jsx(TouchTarget, { children: /* @__PURE__ */ jsxRuntime.jsx(Badge, { variant, color, size, children }) })
|
|
1220
1220
|
}
|
|
1221
1221
|
) : /* @__PURE__ */ jsxRuntime.jsx(
|
|
1222
|
-
|
|
1222
|
+
Headless4__namespace.Button,
|
|
1223
1223
|
{
|
|
1224
1224
|
"data-variant": variant,
|
|
1225
1225
|
...props,
|
|
1226
|
-
className:
|
|
1226
|
+
className: clsx4__default.default(classes, "cursor-pointer"),
|
|
1227
1227
|
ref,
|
|
1228
1228
|
children: /* @__PURE__ */ jsxRuntime.jsx(TouchTarget, { children: /* @__PURE__ */ jsxRuntime.jsx(Badge, { variant, color, size, children }) })
|
|
1229
1229
|
}
|
|
@@ -2360,16 +2360,108 @@ function PopoverContent({
|
|
|
2360
2360
|
function PopoverAnchor({ ...props }) {
|
|
2361
2361
|
return /* @__PURE__ */ jsxRuntime.jsx(PopoverPrimitive__namespace.Anchor, { "data-slot": "popover-anchor", ...props });
|
|
2362
2362
|
}
|
|
2363
|
-
function
|
|
2363
|
+
function Fieldset2({
|
|
2364
|
+
className,
|
|
2365
|
+
...props
|
|
2366
|
+
}) {
|
|
2364
2367
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
2365
|
-
|
|
2368
|
+
Headless4__namespace.Fieldset,
|
|
2369
|
+
{
|
|
2370
|
+
...props,
|
|
2371
|
+
className: clsx4__default.default(className, "*:data-[slot=text]:mt-1 [&>*+[data-slot=control]]:mt-6")
|
|
2372
|
+
}
|
|
2373
|
+
);
|
|
2374
|
+
}
|
|
2375
|
+
function Legend2({
|
|
2376
|
+
className,
|
|
2377
|
+
...props
|
|
2378
|
+
}) {
|
|
2379
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
2380
|
+
Headless4__namespace.Legend,
|
|
2381
|
+
{
|
|
2382
|
+
"data-slot": "legend",
|
|
2383
|
+
...props,
|
|
2384
|
+
className: clsx4__default.default(
|
|
2385
|
+
className,
|
|
2386
|
+
"text-grey-900 text-base/6 font-semibold data-disabled:opacity-50 sm:text-sm/6 dark:text-white"
|
|
2387
|
+
)
|
|
2388
|
+
}
|
|
2389
|
+
);
|
|
2390
|
+
}
|
|
2391
|
+
function FieldGroup({ className, ...props }) {
|
|
2392
|
+
return /* @__PURE__ */ jsxRuntime.jsx("div", { "data-slot": "control", ...props, className: clsx4__default.default(className, "space-y-8") });
|
|
2393
|
+
}
|
|
2394
|
+
function Field2({
|
|
2395
|
+
className,
|
|
2396
|
+
...props
|
|
2397
|
+
}) {
|
|
2398
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
2399
|
+
Headless4__namespace.Field,
|
|
2400
|
+
{
|
|
2401
|
+
...props,
|
|
2402
|
+
className: clsx4__default.default(
|
|
2403
|
+
className,
|
|
2404
|
+
"[&>[data-slot=label]+[data-slot=control]]:mt-3",
|
|
2405
|
+
"[&>[data-slot=label]+[data-slot=description]]:mt-1",
|
|
2406
|
+
"[&>[data-slot=description]+[data-slot=control]]:mt-3",
|
|
2407
|
+
"[&>[data-slot=control]+[data-slot=description]]:mt-3",
|
|
2408
|
+
"[&>[data-slot=control]+[data-slot=error]]:mt-3",
|
|
2409
|
+
"*:data-[slot=label]:font-medium"
|
|
2410
|
+
)
|
|
2411
|
+
}
|
|
2412
|
+
);
|
|
2413
|
+
}
|
|
2414
|
+
function Label4({
|
|
2415
|
+
className,
|
|
2416
|
+
...props
|
|
2417
|
+
}) {
|
|
2418
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
2419
|
+
Headless4__namespace.Label,
|
|
2366
2420
|
{
|
|
2367
2421
|
"data-slot": "label",
|
|
2368
|
-
|
|
2369
|
-
|
|
2422
|
+
...props,
|
|
2423
|
+
className: clsx4__default.default(
|
|
2424
|
+
// Base
|
|
2425
|
+
"flex items-center gap-2",
|
|
2426
|
+
"text-grey-900 text-base/6 font-semibold select-none",
|
|
2427
|
+
// Dark mode
|
|
2428
|
+
"dark:group-data-[disabled=true]:text-grey-400 dark:text-white",
|
|
2429
|
+
// Disabled state
|
|
2430
|
+
"group-data-[disabled=true]:pointer-events-none group-data-[disabled=true]:opacity-50 peer-disabled:cursor-not-allowed peer-disabled:opacity-50",
|
|
2370
2431
|
className
|
|
2371
|
-
)
|
|
2372
|
-
|
|
2432
|
+
)
|
|
2433
|
+
}
|
|
2434
|
+
);
|
|
2435
|
+
}
|
|
2436
|
+
function Description2({
|
|
2437
|
+
className,
|
|
2438
|
+
...props
|
|
2439
|
+
}) {
|
|
2440
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
2441
|
+
Headless4__namespace.Description,
|
|
2442
|
+
{
|
|
2443
|
+
"data-slot": "description",
|
|
2444
|
+
...props,
|
|
2445
|
+
className: clsx4__default.default(
|
|
2446
|
+
className,
|
|
2447
|
+
"text-grey-500 dark:text-grey-400 text-base/6 data-disabled:opacity-50 sm:text-sm/6"
|
|
2448
|
+
)
|
|
2449
|
+
}
|
|
2450
|
+
);
|
|
2451
|
+
}
|
|
2452
|
+
function ErrorMessage({
|
|
2453
|
+
className,
|
|
2454
|
+
...props
|
|
2455
|
+
}) {
|
|
2456
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
2457
|
+
Headless4__namespace.Description,
|
|
2458
|
+
{
|
|
2459
|
+
"data-slot": "error",
|
|
2460
|
+
...props,
|
|
2461
|
+
className: clsx4__default.default(
|
|
2462
|
+
className,
|
|
2463
|
+
"text-danger-600 dark:text-danger-500 text-base/6 data-disabled:opacity-50 sm:text-sm/6"
|
|
2464
|
+
)
|
|
2373
2465
|
}
|
|
2374
2466
|
);
|
|
2375
2467
|
}
|
|
@@ -2581,7 +2673,7 @@ function ThemeSelector({
|
|
|
2581
2673
|
className: "grid grid-cols-2 gap-2",
|
|
2582
2674
|
children: Object.entries(colorThemes2[themeCategory]).map(([key, theme2]) => /* @__PURE__ */ jsxRuntime.jsxs("div", { className: cn(labelStyles.base, ""), children: [
|
|
2583
2675
|
/* @__PURE__ */ jsxRuntime.jsx(RadioGroupItem, { value: key, id: `primary-${key}`, className: "peer sr-only" }),
|
|
2584
|
-
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
2676
|
+
/* @__PURE__ */ jsxRuntime.jsxs(Label4, { htmlFor: `primary-${key}`, className: cn(labelStyles.label, ""), children: [
|
|
2585
2677
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
2586
2678
|
"div",
|
|
2587
2679
|
{
|
|
@@ -2606,7 +2698,7 @@ function ThemeSelector({
|
|
|
2606
2698
|
className: "grid grid-cols-2 gap-2",
|
|
2607
2699
|
children: availableAccentColors.map((key) => /* @__PURE__ */ jsxRuntime.jsxs("div", { className: cn(labelStyles.base, ""), children: [
|
|
2608
2700
|
/* @__PURE__ */ jsxRuntime.jsx(RadioGroupItem, { value: key, id: `accent-${key}`, className: "peer sr-only" }),
|
|
2609
|
-
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
2701
|
+
/* @__PURE__ */ jsxRuntime.jsxs(Label4, { htmlFor: `accent-${key}`, className: cn(labelStyles.label, ""), children: [
|
|
2610
2702
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
2611
2703
|
"div",
|
|
2612
2704
|
{
|
|
@@ -6262,7 +6354,7 @@ function CodePreview({
|
|
|
6262
6354
|
children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
6263
6355
|
"div",
|
|
6264
6356
|
{
|
|
6265
|
-
className:
|
|
6357
|
+
className: clsx4.clsx(
|
|
6266
6358
|
"group dark:bg-grey-900 mx-auto bg-white bg-gradient-to-r",
|
|
6267
6359
|
view === "desktop" && "w-full",
|
|
6268
6360
|
view === "tablet" && "max-w-lg",
|
|
@@ -6500,7 +6592,7 @@ function ColorCard({ name, token, hex, rgb: rgb2, hsl, oklch: oklch2, format, vi
|
|
|
6500
6592
|
{
|
|
6501
6593
|
className: "flex h-24 w-full items-center justify-center",
|
|
6502
6594
|
style: { backgroundColor: hex },
|
|
6503
|
-
children: /* @__PURE__ */ jsxRuntime.jsx("p", { className:
|
|
6595
|
+
children: /* @__PURE__ */ jsxRuntime.jsx("p", { className: clsx4.clsx("font-medium", isLightColor(hex) ? "text-primary-950" : "text-white"), children: name })
|
|
6504
6596
|
}
|
|
6505
6597
|
),
|
|
6506
6598
|
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex flex-col gap-2 p-4", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-between", children: [
|
|
@@ -7226,6 +7318,25 @@ function Footer({
|
|
|
7226
7318
|
/* @__PURE__ */ jsxRuntime.jsx(FooterSmallPrint, { department, socialLinks })
|
|
7227
7319
|
] });
|
|
7228
7320
|
}
|
|
7321
|
+
function Label6({ className, ...props }) {
|
|
7322
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
7323
|
+
LabelPrimitive__namespace.Root,
|
|
7324
|
+
{
|
|
7325
|
+
"data-slot": "label",
|
|
7326
|
+
className: cn(
|
|
7327
|
+
// Base
|
|
7328
|
+
"flex items-center gap-2",
|
|
7329
|
+
"text-grey-900 text-base/6 font-semibold select-none",
|
|
7330
|
+
// Dark mode
|
|
7331
|
+
"dark:group-data-[disabled=true]:text-grey-400 dark:text-white",
|
|
7332
|
+
// Disabled state
|
|
7333
|
+
"group-data-[disabled=true]:pointer-events-none group-data-[disabled=true]:opacity-50 peer-disabled:cursor-not-allowed peer-disabled:opacity-50",
|
|
7334
|
+
className
|
|
7335
|
+
),
|
|
7336
|
+
...props
|
|
7337
|
+
}
|
|
7338
|
+
);
|
|
7339
|
+
}
|
|
7229
7340
|
var Form = reactHookForm.FormProvider;
|
|
7230
7341
|
var FormFieldContext = React15__namespace.createContext({});
|
|
7231
7342
|
var FormField = ({
|
|
@@ -7260,7 +7371,7 @@ function FormItem({ className, ...props }) {
|
|
|
7260
7371
|
function FormLabel({ className, ...props }) {
|
|
7261
7372
|
const { error, formItemId } = useFormField();
|
|
7262
7373
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
7263
|
-
|
|
7374
|
+
Label6,
|
|
7264
7375
|
{
|
|
7265
7376
|
"data-slot": "form-label",
|
|
7266
7377
|
"data-error": !!error,
|
|
@@ -7354,7 +7465,7 @@ var toggleVariants = classVarianceAuthority.cva(styles3.base, {
|
|
|
7354
7465
|
variants: {
|
|
7355
7466
|
variant: {
|
|
7356
7467
|
ghost: "",
|
|
7357
|
-
outline:
|
|
7468
|
+
outline: clsx4__default.default(styles3.outline)
|
|
7358
7469
|
},
|
|
7359
7470
|
size: {
|
|
7360
7471
|
default: "h-9 px-2 min-w-9",
|
|
@@ -7498,7 +7609,7 @@ function Heading({
|
|
|
7498
7609
|
Element,
|
|
7499
7610
|
{
|
|
7500
7611
|
...props,
|
|
7501
|
-
className:
|
|
7612
|
+
className: clsx4__default.default(
|
|
7502
7613
|
className,
|
|
7503
7614
|
trimClasses[trim],
|
|
7504
7615
|
"m-0",
|
|
@@ -7513,7 +7624,7 @@ function Heading({
|
|
|
7513
7624
|
|
|
7514
7625
|
// package.json
|
|
7515
7626
|
var package_default = {
|
|
7516
|
-
version: "1.
|
|
7627
|
+
version: "1.36.0"};
|
|
7517
7628
|
function Logo(props) {
|
|
7518
7629
|
return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
7519
7630
|
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "sr-only", children: "NSW Government" }),
|
|
@@ -7651,7 +7762,12 @@ function Header2({
|
|
|
7651
7762
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
7652
7763
|
"header",
|
|
7653
7764
|
{
|
|
7654
|
-
|
|
7765
|
+
"aria-label": "Header",
|
|
7766
|
+
role: "banner",
|
|
7767
|
+
"data-slot": "header",
|
|
7768
|
+
"data-scrolled": isScrolled,
|
|
7769
|
+
id: "nsw-header",
|
|
7770
|
+
className: clsx4__default.default(
|
|
7655
7771
|
"sticky top-0 z-50 flex flex-none flex-wrap items-center justify-between bg-white px-4 py-5 transition duration-500 sm:px-6 lg:px-12",
|
|
7656
7772
|
shadow && "shadow-md shadow-slate-900/5 dark:shadow-none",
|
|
7657
7773
|
isScrolled ? "dark:bg-slate-900/95 dark:backdrop-blur-sm dark:[@supports(backdrop-filter:blur(0))]:bg-slate-900/75" : "dark:bg-transparent"
|
|
@@ -7722,7 +7838,7 @@ function Input({ className, type, ...props }) {
|
|
|
7722
7838
|
);
|
|
7723
7839
|
}
|
|
7724
7840
|
function cn2(...inputs) {
|
|
7725
|
-
return tailwindMerge.twMerge(
|
|
7841
|
+
return tailwindMerge.twMerge(clsx4.clsx(inputs));
|
|
7726
7842
|
}
|
|
7727
7843
|
var sizeStyles = {
|
|
7728
7844
|
sm: "text-sm",
|
|
@@ -7770,7 +7886,7 @@ ListItem.displayName = "List.Item";
|
|
|
7770
7886
|
var _List = List2;
|
|
7771
7887
|
_List.Item = ListItem;
|
|
7772
7888
|
function Masthead() {
|
|
7773
|
-
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: "bg-primary-800
|
|
7889
|
+
return /* @__PURE__ */ jsxRuntime.jsx("div", { id: "nsw-masthead", className: "bg-primary-800 w-full", children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "mx-auto flex w-full items-center justify-between px-4 py-2 sm:px-6 lg:px-12", children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex items-center gap-x-12", children: /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-xs text-white", children: "A NSW Government website" }) }) }) });
|
|
7774
7890
|
}
|
|
7775
7891
|
function Menubar({ className, ...props }) {
|
|
7776
7892
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -7979,43 +8095,41 @@ function MenubarSubContent({
|
|
|
7979
8095
|
}
|
|
7980
8096
|
);
|
|
7981
8097
|
}
|
|
7982
|
-
function
|
|
7983
|
-
const [
|
|
8098
|
+
function useSelectorHeight(selector = "header") {
|
|
8099
|
+
const [height, setHeight] = React15.useState(0);
|
|
8100
|
+
const elementRef = React15.useRef(null);
|
|
8101
|
+
const resizeObserverRef = React15.useRef(null);
|
|
7984
8102
|
React15.useEffect(() => {
|
|
7985
|
-
const
|
|
7986
|
-
|
|
7987
|
-
|
|
7988
|
-
|
|
8103
|
+
const element = document.querySelector(selector);
|
|
8104
|
+
if (!element) return;
|
|
8105
|
+
elementRef.current = element;
|
|
8106
|
+
setHeight(element.offsetHeight);
|
|
8107
|
+
resizeObserverRef.current = new ResizeObserver(() => {
|
|
8108
|
+
if (elementRef.current) {
|
|
8109
|
+
setHeight(elementRef.current.offsetHeight);
|
|
7989
8110
|
}
|
|
7990
|
-
};
|
|
7991
|
-
|
|
7992
|
-
const header = document.querySelector("header");
|
|
7993
|
-
let resizeObserver = null;
|
|
7994
|
-
if (header) {
|
|
7995
|
-
resizeObserver = new ResizeObserver((entries) => {
|
|
7996
|
-
for (const entry of entries) {
|
|
7997
|
-
setHeaderHeight(entry.contentRect.height);
|
|
7998
|
-
}
|
|
7999
|
-
});
|
|
8000
|
-
resizeObserver.observe(header);
|
|
8001
|
-
}
|
|
8111
|
+
});
|
|
8112
|
+
resizeObserverRef.current.observe(element);
|
|
8002
8113
|
return () => {
|
|
8003
|
-
|
|
8004
|
-
if (resizeObserver) {
|
|
8005
|
-
resizeObserver.disconnect();
|
|
8006
|
-
}
|
|
8114
|
+
resizeObserverRef.current?.disconnect();
|
|
8007
8115
|
};
|
|
8008
|
-
}, []);
|
|
8116
|
+
}, [selector]);
|
|
8117
|
+
return height;
|
|
8118
|
+
}
|
|
8119
|
+
function MainNavigation({ navigation }) {
|
|
8120
|
+
const headerHeight = useSelectorHeight();
|
|
8009
8121
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
8010
8122
|
"nav",
|
|
8011
8123
|
{
|
|
8124
|
+
"aria-label": "Main Navigation",
|
|
8125
|
+
role: "navigation",
|
|
8126
|
+
id: "nsw-main-navigation",
|
|
8012
8127
|
className: "shadow-grey-900/5 sticky z-40 hidden bg-gray-100 shadow-md sm:px-6 lg:block lg:px-4 dark:shadow-none",
|
|
8013
8128
|
style: {
|
|
8014
8129
|
top: `${headerHeight}px`,
|
|
8015
|
-
// Ensure the nav doesn't jump when header height is calculated
|
|
8016
8130
|
transition: "top 0.2s ease-in-out"
|
|
8017
8131
|
},
|
|
8018
|
-
children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "relative z-50 mx-auto flex items-center justify-between", children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
8132
|
+
children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "relative z-50 mx-auto flex items-center justify-between", children: /* @__PURE__ */ jsxRuntime.jsx(Headless4.PopoverGroup, { className: "flex justify-start", children: navigation.map(
|
|
8019
8133
|
(item, index) => item.links ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
8020
8134
|
MegaMenu,
|
|
8021
8135
|
{
|
|
@@ -8048,9 +8162,9 @@ function TopLevel({ title, href }) {
|
|
|
8048
8162
|
);
|
|
8049
8163
|
}
|
|
8050
8164
|
function MegaMenu({ title, href, links }) {
|
|
8051
|
-
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
8165
|
+
return /* @__PURE__ */ jsxRuntime.jsx(Headless4.Popover, { className: "group", children: ({ open }) => /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
8052
8166
|
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "m-0 mx-auto", children: /* @__PURE__ */ jsxRuntime.jsxs(
|
|
8053
|
-
|
|
8167
|
+
Headless4.PopoverButton,
|
|
8054
8168
|
{
|
|
8055
8169
|
className: cn(
|
|
8056
8170
|
"text-nsw-grey-900 hover:bg-nsw-grey-900/10 inline-flex items-center gap-x-1 p-4 text-base leading-6 font-bold transition focus:ring-0 focus:ring-offset-0 focus:outline-none lg:px-8",
|
|
@@ -8064,7 +8178,7 @@ function MegaMenu({ title, href, links }) {
|
|
|
8064
8178
|
}
|
|
8065
8179
|
) }),
|
|
8066
8180
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
8067
|
-
|
|
8181
|
+
Headless4.PopoverPanel,
|
|
8068
8182
|
{
|
|
8069
8183
|
transition: true,
|
|
8070
8184
|
className: "absolute inset-x-0 top-0 -z-10 pt-14 shadow transition data-[closed]:-translate-y-1 data-[closed]:opacity-0 data-[enter]:duration-200 data-[enter]:ease-out data-[leave]:duration-150 data-[leave]:ease-in",
|
|
@@ -8105,7 +8219,7 @@ function Navigation({
|
|
|
8105
8219
|
navigation: navigation$1
|
|
8106
8220
|
}) {
|
|
8107
8221
|
const pathname = navigation.usePathname();
|
|
8108
|
-
return /* @__PURE__ */ jsxRuntime.jsx("nav", { className:
|
|
8222
|
+
return /* @__PURE__ */ jsxRuntime.jsx("nav", { className: clsx4__default.default("text-base lg:text-sm", className), children: /* @__PURE__ */ jsxRuntime.jsx("ul", { role: "list", className: "flex flex-col gap-9", children: navigation$1.map((section, index) => /* @__PURE__ */ jsxRuntime.jsxs("li", { children: [
|
|
8109
8223
|
section.links ? /* @__PURE__ */ jsxRuntime.jsx("h2", { className: "font-display text-foreground font-medium dark:text-white", children: section.title }) : /* @__PURE__ */ jsxRuntime.jsx(
|
|
8110
8224
|
"ul",
|
|
8111
8225
|
{
|
|
@@ -8116,7 +8230,7 @@ function Navigation({
|
|
|
8116
8230
|
{
|
|
8117
8231
|
href: section.href || "/",
|
|
8118
8232
|
onClick: onLinkClick,
|
|
8119
|
-
className:
|
|
8233
|
+
className: clsx4__default.default(
|
|
8120
8234
|
"text-foreground inline-block border-l border-transparent pl-5 text-base/8 sm:pl-4 sm:text-sm/6",
|
|
8121
8235
|
"hover:border-nsw-grey-950 hover:text-nsw-gray-950 hover:font-semibold",
|
|
8122
8236
|
"dark:text-nsw-grey-400",
|
|
@@ -8138,7 +8252,7 @@ function Navigation({
|
|
|
8138
8252
|
{
|
|
8139
8253
|
href: link.href,
|
|
8140
8254
|
onClick: onLinkClick,
|
|
8141
|
-
className:
|
|
8255
|
+
className: clsx4__default.default(
|
|
8142
8256
|
"text-foreground inline-block border-l border-transparent pl-5 text-base/8 sm:pl-4 sm:text-sm/6",
|
|
8143
8257
|
"hover:border-nsw-grey-950 hover:text-nsw-gray-950 hover:font-semibold",
|
|
8144
8258
|
"dark:text-nsw-grey-400",
|
|
@@ -8395,7 +8509,7 @@ function PrevNextLinksPageLink({
|
|
|
8395
8509
|
Link10__default.default,
|
|
8396
8510
|
{
|
|
8397
8511
|
href,
|
|
8398
|
-
className:
|
|
8512
|
+
className: clsx4__default.default(
|
|
8399
8513
|
"flex items-center gap-x-1 text-base font-semibold text-slate-500 hover:text-slate-600 dark:text-slate-400 dark:hover:text-slate-300",
|
|
8400
8514
|
dir === "previous" && "flex-row-reverse"
|
|
8401
8515
|
),
|
|
@@ -8404,7 +8518,7 @@ function PrevNextLinksPageLink({
|
|
|
8404
8518
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
8405
8519
|
Icons.east,
|
|
8406
8520
|
{
|
|
8407
|
-
className:
|
|
8521
|
+
className: clsx4__default.default("size-5 flex-none fill-current", dir === "previous" && "-scale-x-100")
|
|
8408
8522
|
}
|
|
8409
8523
|
)
|
|
8410
8524
|
]
|
|
@@ -8647,7 +8761,7 @@ function SidebarNavigation({
|
|
|
8647
8761
|
navigation: navigation$1
|
|
8648
8762
|
}) {
|
|
8649
8763
|
const pathname = navigation.usePathname();
|
|
8650
|
-
return /* @__PURE__ */ jsxRuntime.jsx("nav", { className:
|
|
8764
|
+
return /* @__PURE__ */ jsxRuntime.jsx("nav", { className: clsx4__default.default("text-base lg:text-sm", className), children: /* @__PURE__ */ jsxRuntime.jsx("ul", { role: "list", className: "flex flex-col gap-9", children: navigation$1.map((section, sectionIndex) => /* @__PURE__ */ jsxRuntime.jsxs("li", { children: [
|
|
8651
8765
|
section.links ? /* @__PURE__ */ jsxRuntime.jsx("h2", { className: "font-display text-foreground font-medium dark:text-white", children: section.title }) : /* @__PURE__ */ jsxRuntime.jsx(
|
|
8652
8766
|
"ul",
|
|
8653
8767
|
{
|
|
@@ -8688,7 +8802,7 @@ function SidebarNavigation({
|
|
|
8688
8802
|
function SidebarLink({ link, pathname, onLinkClick, depth }) {
|
|
8689
8803
|
const hasChildren = Array.isArray(link.links) && link.links.length > 0;
|
|
8690
8804
|
const isActive = pathname === link.href;
|
|
8691
|
-
const baseLinkClasses =
|
|
8805
|
+
const baseLinkClasses = clsx4__default.default(
|
|
8692
8806
|
"border-l border-transparent pl-4 pr-2 text-base/8 sm:text-sm/6 w-full text-left py-1 rounded-r-md cursor-pointer",
|
|
8693
8807
|
"hover:border-nsw-grey-950 hover:text-nsw-gray-950 hover:font-semibold hover:bg-primary-800/10",
|
|
8694
8808
|
"dark:text-nsw-grey-400 dark:hover:border-nsw-grey-400 dark:hover:text-white",
|
|
@@ -8698,13 +8812,13 @@ function SidebarLink({ link, pathname, onLinkClick, depth }) {
|
|
|
8698
8812
|
/* @__PURE__ */ jsxRuntime.jsx(CollapsibleTrigger2, { asChild: true, children: /* @__PURE__ */ jsxRuntime.jsxs(
|
|
8699
8813
|
"button",
|
|
8700
8814
|
{
|
|
8701
|
-
className:
|
|
8815
|
+
className: clsx4__default.default(baseLinkClasses, "group flex items-center justify-between gap-1"),
|
|
8702
8816
|
children: [
|
|
8703
8817
|
/* @__PURE__ */ jsxRuntime.jsx("span", { children: link.title }),
|
|
8704
8818
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
8705
8819
|
Icons.chevron_right,
|
|
8706
8820
|
{
|
|
8707
|
-
className:
|
|
8821
|
+
className: clsx4__default.default(
|
|
8708
8822
|
"ml-2 size-5 transition-transform duration-200",
|
|
8709
8823
|
"group-data-[state=open]:rotate-90"
|
|
8710
8824
|
)
|
|
@@ -8716,7 +8830,7 @@ function SidebarLink({ link, pathname, onLinkClick, depth }) {
|
|
|
8716
8830
|
/* @__PURE__ */ jsxRuntime.jsx(CollapsibleContent2, { children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
8717
8831
|
"ul",
|
|
8718
8832
|
{
|
|
8719
|
-
className:
|
|
8833
|
+
className: clsx4__default.default(
|
|
8720
8834
|
"border-nsw-grey-400 dark:border-nsw-grey-200/15 mt-2 ml-5 flex flex-col gap-1 border-l pl-0"
|
|
8721
8835
|
),
|
|
8722
8836
|
children: link.links && link.links.map((childLink) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -8739,7 +8853,7 @@ var StepIndicator = React15__namespace.forwardRef(
|
|
|
8739
8853
|
return /* @__PURE__ */ jsxRuntime.jsx("ul", { role: "list", ref, className: cn("w-full", className), ...props, children: array.map((step, stepIdx) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
8740
8854
|
"li",
|
|
8741
8855
|
{
|
|
8742
|
-
className:
|
|
8856
|
+
className: clsx4__default.default(stepIdx !== array.length - 1 ? "pb-3" : "", "relative"),
|
|
8743
8857
|
children: step.href === pathname && !(step.status === "completed" || step.status === "error" || step.status === "saved" || step.status === "cannot-start") ? /* @__PURE__ */ jsxRuntime.jsx(jsxRuntime.Fragment, { children: step.status === "in-progress" ? /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
8744
8858
|
stepIdx !== array.length - 1 ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
8745
8859
|
"div",
|
|
@@ -8985,7 +9099,7 @@ function StepNavigation({
|
|
|
8985
9099
|
})),
|
|
8986
9100
|
[navigation, formStatus, getStatus]
|
|
8987
9101
|
);
|
|
8988
|
-
return /* @__PURE__ */ jsxRuntime.jsx("nav", { className:
|
|
9102
|
+
return /* @__PURE__ */ jsxRuntime.jsx("nav", { className: clsx4__default.default("text-base lg:text-sm", className), children: /* @__PURE__ */ jsxRuntime.jsx("ul", { role: "list", className: "space-y-9", children: navigationWithStatus.map((section) => /* @__PURE__ */ jsxRuntime.jsxs("li", { children: [
|
|
8989
9103
|
/* @__PURE__ */ jsxRuntime.jsx("h2", { className: "font-display font-medium text-slate-900 dark:text-white", children: section.title }),
|
|
8990
9104
|
/* @__PURE__ */ jsxRuntime.jsx(StepIndicator, { className: "mt-2 lg:mt-4", array: section.links })
|
|
8991
9105
|
] }, section.title)) }) });
|
|
@@ -9230,91 +9344,114 @@ function TableCaption({ className, ...props }) {
|
|
|
9230
9344
|
}
|
|
9231
9345
|
);
|
|
9232
9346
|
}
|
|
9233
|
-
function
|
|
9234
|
-
const
|
|
9235
|
-
const
|
|
9236
|
-
|
|
9237
|
-
|
|
9238
|
-
if (!el) return null;
|
|
9239
|
-
const style = window.getComputedStyle(el);
|
|
9240
|
-
const scrollMt = parseFloat(style.scrollMarginTop);
|
|
9241
|
-
const top = window.scrollY + el.getBoundingClientRect().top - scrollMt;
|
|
9242
|
-
return { id, top };
|
|
9243
|
-
}).filter((x) => x !== null);
|
|
9244
|
-
}, []);
|
|
9347
|
+
function useActiveSectionObserver(tableOfContents) {
|
|
9348
|
+
const headerHeight = useSelectorHeight("#nsw-header");
|
|
9349
|
+
const mastheadHeight = useSelectorHeight("#nsw-masthead");
|
|
9350
|
+
const navigationHeight = useSelectorHeight("#nsw-main-navigation");
|
|
9351
|
+
const [currentSection, setCurrentSection] = React15.useState(null);
|
|
9245
9352
|
React15.useEffect(() => {
|
|
9246
9353
|
if (tableOfContents.length === 0) return;
|
|
9247
|
-
|
|
9248
|
-
|
|
9249
|
-
|
|
9250
|
-
|
|
9251
|
-
|
|
9252
|
-
|
|
9253
|
-
|
|
9254
|
-
|
|
9255
|
-
|
|
9256
|
-
|
|
9257
|
-
|
|
9354
|
+
if (!headerHeight) return;
|
|
9355
|
+
const totalHeight = headerHeight + mastheadHeight + navigationHeight;
|
|
9356
|
+
let observer = null;
|
|
9357
|
+
const initializeObserver = () => {
|
|
9358
|
+
const ids = tableOfContents.flatMap((node) => [
|
|
9359
|
+
node.id,
|
|
9360
|
+
...node.children.map((child) => child.id)
|
|
9361
|
+
]);
|
|
9362
|
+
ids.forEach((id) => {
|
|
9363
|
+
const el = document.getElementById(id);
|
|
9364
|
+
if (el) {
|
|
9365
|
+
el.style.scrollMarginTop = `${totalHeight + 16}px`;
|
|
9366
|
+
}
|
|
9367
|
+
});
|
|
9368
|
+
observer = new IntersectionObserver(
|
|
9369
|
+
(entries) => {
|
|
9370
|
+
const visible = entries.filter((entry) => entry.isIntersecting).sort((a, b) => a.boundingClientRect.top - b.boundingClientRect.top);
|
|
9371
|
+
if (visible.length > 0) {
|
|
9372
|
+
setCurrentSection(visible[0].target.id);
|
|
9258
9373
|
}
|
|
9374
|
+
},
|
|
9375
|
+
{
|
|
9376
|
+
rootMargin: `-${totalHeight}px 0px -70% 0px`,
|
|
9377
|
+
threshold: [0, 0.25, 0.5, 0.75, 1]
|
|
9259
9378
|
}
|
|
9260
|
-
|
|
9261
|
-
|
|
9262
|
-
|
|
9263
|
-
|
|
9264
|
-
|
|
9265
|
-
|
|
9266
|
-
|
|
9267
|
-
|
|
9379
|
+
);
|
|
9380
|
+
ids.forEach((id) => {
|
|
9381
|
+
const el = document.getElementById(id);
|
|
9382
|
+
if (el) observer.observe(el);
|
|
9383
|
+
});
|
|
9384
|
+
};
|
|
9385
|
+
const raf = requestAnimationFrame(() => {
|
|
9386
|
+
initializeObserver();
|
|
9387
|
+
});
|
|
9268
9388
|
return () => {
|
|
9269
|
-
|
|
9389
|
+
if (observer) observer.disconnect();
|
|
9390
|
+
cancelAnimationFrame(raf);
|
|
9391
|
+
};
|
|
9392
|
+
}, [tableOfContents, headerHeight, mastheadHeight, navigationHeight]);
|
|
9393
|
+
React15.useEffect(() => {
|
|
9394
|
+
const handleResize = () => {
|
|
9395
|
+
setCurrentSection(null);
|
|
9270
9396
|
};
|
|
9271
|
-
|
|
9397
|
+
window.addEventListener("resize", handleResize);
|
|
9398
|
+
return () => window.removeEventListener("resize", handleResize);
|
|
9399
|
+
}, []);
|
|
9400
|
+
return currentSection;
|
|
9401
|
+
}
|
|
9402
|
+
function TableOfContents({ tableOfContents }) {
|
|
9403
|
+
const currentSection = useActiveSectionObserver(tableOfContents);
|
|
9272
9404
|
function isActive(section) {
|
|
9273
|
-
if (section.id === currentSection)
|
|
9274
|
-
|
|
9275
|
-
}
|
|
9276
|
-
if (!section.children) {
|
|
9277
|
-
return false;
|
|
9278
|
-
}
|
|
9279
|
-
return section.children.findIndex(isActive) > -1;
|
|
9405
|
+
if (section.id === currentSection) return true;
|
|
9406
|
+
return section.children?.some(isActive) ?? false;
|
|
9280
9407
|
}
|
|
9281
|
-
return /* @__PURE__ */ jsxRuntime.jsx("
|
|
9408
|
+
return /* @__PURE__ */ jsxRuntime.jsx("nav", { "aria-labelledby": "on-this-page-title", className: "w-56", children: tableOfContents.length > 0 && /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
9282
9409
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
9283
9410
|
"h2",
|
|
9284
9411
|
{
|
|
9285
9412
|
id: "on-this-page-title",
|
|
9286
|
-
className: "
|
|
9413
|
+
className: "text-grey-950 text-sm/6 font-semibold dark:text-white",
|
|
9287
9414
|
children: "On this page"
|
|
9288
9415
|
}
|
|
9289
9416
|
),
|
|
9290
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
9291
|
-
|
|
9292
|
-
|
|
9293
|
-
|
|
9294
|
-
|
|
9295
|
-
|
|
9296
|
-
|
|
9417
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
9418
|
+
"ol",
|
|
9419
|
+
{
|
|
9420
|
+
role: "list",
|
|
9421
|
+
className: clsx4__default.default(
|
|
9422
|
+
"mt-3 flex flex-col gap-2",
|
|
9423
|
+
"border-grey-900/10 border-l dark:border-white/10",
|
|
9424
|
+
"text-grey-700 dark:text-grey-400 text-sm/6"
|
|
9425
|
+
),
|
|
9426
|
+
children: tableOfContents.map((section) => /* @__PURE__ */ jsxRuntime.jsxs("li", { children: [
|
|
9427
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
9428
|
+
Link10__default.default,
|
|
9429
|
+
{
|
|
9430
|
+
href: `#${section.id}`,
|
|
9431
|
+
className: clsx4__default.default(
|
|
9432
|
+
"-ml-px inline-block border-l pl-4",
|
|
9433
|
+
"hover:border-primary-800 dark:hover:border-white",
|
|
9434
|
+
isActive(section) ? "text-primary-800 border-primary-800 font-semibold dark:border-white dark:text-white" : "border-transparent"
|
|
9435
|
+
),
|
|
9436
|
+
children: section.title
|
|
9437
|
+
}
|
|
9297
9438
|
),
|
|
9298
|
-
children: section.
|
|
9299
|
-
}
|
|
9300
|
-
) }),
|
|
9301
|
-
section.children.length > 0 && /* @__PURE__ */ jsxRuntime.jsx(
|
|
9302
|
-
"ol",
|
|
9303
|
-
{
|
|
9304
|
-
role: "list",
|
|
9305
|
-
className: "mt-2 space-y-3 pl-5 text-slate-500 dark:text-slate-400",
|
|
9306
|
-
children: section.children.map((subSection) => /* @__PURE__ */ jsxRuntime.jsx("li", { children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
9439
|
+
section.children.length > 0 && /* @__PURE__ */ jsxRuntime.jsx("ol", { role: "list", className: "mt-3 flex flex-col gap-2", children: section.children.map((subSection) => /* @__PURE__ */ jsxRuntime.jsx("li", { children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
9307
9440
|
Link10__default.default,
|
|
9308
9441
|
{
|
|
9309
9442
|
href: `#${subSection.id}`,
|
|
9310
|
-
className:
|
|
9443
|
+
className: clsx4__default.default(
|
|
9444
|
+
"-ml-px inline-block border-l pl-8",
|
|
9445
|
+
"hover:border-primary-800 dark:hover:border-white",
|
|
9446
|
+
isActive(subSection) ? "text-primary-800 border-primary-800 font-semibold dark:border-white dark:text-white" : "border-transparent"
|
|
9447
|
+
),
|
|
9311
9448
|
children: subSection.title
|
|
9312
9449
|
}
|
|
9313
|
-
) }, subSection.id))
|
|
9314
|
-
}
|
|
9315
|
-
|
|
9316
|
-
|
|
9317
|
-
] }) })
|
|
9450
|
+
) }, subSection.id)) })
|
|
9451
|
+
] }, section.id))
|
|
9452
|
+
}
|
|
9453
|
+
)
|
|
9454
|
+
] }) });
|
|
9318
9455
|
}
|
|
9319
9456
|
function Tabs2({ className, ...props }) {
|
|
9320
9457
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -9415,7 +9552,7 @@ function Text({ className, trim = "normal", size = 2, label = false, ...props })
|
|
|
9415
9552
|
{
|
|
9416
9553
|
"data-slot": "text",
|
|
9417
9554
|
...props,
|
|
9418
|
-
className:
|
|
9555
|
+
className: clsx4__default.default(className, trimClasses[trim], "text-grey-800 dark:text-grey-400", sizeClass)
|
|
9419
9556
|
}
|
|
9420
9557
|
);
|
|
9421
9558
|
}
|
|
@@ -9424,7 +9561,7 @@ function TextLink({ className, ...props }) {
|
|
|
9424
9561
|
Link,
|
|
9425
9562
|
{
|
|
9426
9563
|
...props,
|
|
9427
|
-
className:
|
|
9564
|
+
className: clsx4__default.default(
|
|
9428
9565
|
className,
|
|
9429
9566
|
"text-primary-800 decoration-primary-800/50 data-hover:decoration-primary-800 underline dark:text-white dark:decoration-white/50 dark:data-hover:decoration-white"
|
|
9430
9567
|
)
|
|
@@ -9432,14 +9569,14 @@ function TextLink({ className, ...props }) {
|
|
|
9432
9569
|
);
|
|
9433
9570
|
}
|
|
9434
9571
|
function Strong({ className, ...props }) {
|
|
9435
|
-
return /* @__PURE__ */ jsxRuntime.jsx("strong", { ...props, className:
|
|
9572
|
+
return /* @__PURE__ */ jsxRuntime.jsx("strong", { ...props, className: clsx4__default.default(className, "text-grey-950 font-medium dark:text-white") });
|
|
9436
9573
|
}
|
|
9437
9574
|
function Code({ className, ...props }) {
|
|
9438
9575
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
9439
9576
|
"code",
|
|
9440
9577
|
{
|
|
9441
9578
|
...props,
|
|
9442
|
-
className:
|
|
9579
|
+
className: clsx4__default.default(
|
|
9443
9580
|
className,
|
|
9444
9581
|
"border-grey-950/10 bg-grey-950/[2.5%] text-grey-950 rounded-sm border px-0.5 text-sm font-medium sm:text-[0.8125rem] dark:border-white/20 dark:bg-white/5 dark:text-white"
|
|
9445
9582
|
)
|
|
@@ -10068,7 +10205,7 @@ var ScrollButton = ({ icon, onClick, disabled }) => {
|
|
|
10068
10205
|
}
|
|
10069
10206
|
);
|
|
10070
10207
|
};
|
|
10071
|
-
var
|
|
10208
|
+
var Legend4 = React15__namespace.default.forwardRef((props, ref) => {
|
|
10072
10209
|
const {
|
|
10073
10210
|
categories,
|
|
10074
10211
|
colors: colors2 = AvailableChartColors,
|
|
@@ -10208,7 +10345,7 @@ var Legend2 = React15__namespace.default.forwardRef((props, ref) => {
|
|
|
10208
10345
|
) }) : null
|
|
10209
10346
|
] });
|
|
10210
10347
|
});
|
|
10211
|
-
|
|
10348
|
+
Legend4.displayName = "Legend";
|
|
10212
10349
|
var ChartLegend2 = ({ payload }, categoryColors, setLegendHeight, activeLegend, onClick, enableLegendSlider, legendPosition, yAxisWidth) => {
|
|
10213
10350
|
const legendRef = React15__namespace.default.useRef(null);
|
|
10214
10351
|
useOnWindowResize(() => {
|
|
@@ -10229,7 +10366,7 @@ var ChartLegend2 = ({ payload }, categoryColors, setLegendHeight, activeLegend,
|
|
|
10229
10366
|
{ "justify-end": legendPosition === "right" }
|
|
10230
10367
|
),
|
|
10231
10368
|
children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
10232
|
-
|
|
10369
|
+
Legend4,
|
|
10233
10370
|
{
|
|
10234
10371
|
categories: legendPayload.map((entry) => entry.value),
|
|
10235
10372
|
colors: legendPayload.map((entry) => categoryColors.get(entry.value)),
|
|
@@ -10827,7 +10964,7 @@ var ScrollButton2 = ({ icon, onClick, disabled }) => {
|
|
|
10827
10964
|
}
|
|
10828
10965
|
);
|
|
10829
10966
|
};
|
|
10830
|
-
var
|
|
10967
|
+
var Legend5 = React15__namespace.default.forwardRef((props, ref) => {
|
|
10831
10968
|
const {
|
|
10832
10969
|
categories,
|
|
10833
10970
|
colors: colors2 = AvailableChartColors,
|
|
@@ -10967,7 +11104,7 @@ var Legend3 = React15__namespace.default.forwardRef((props, ref) => {
|
|
|
10967
11104
|
) }) : null
|
|
10968
11105
|
] });
|
|
10969
11106
|
});
|
|
10970
|
-
|
|
11107
|
+
Legend5.displayName = "Legend";
|
|
10971
11108
|
var ChartLegend3 = ({ payload }, categoryColors, setLegendHeight, activeLegend, onClick, enableLegendSlider, legendPosition, yAxisWidth) => {
|
|
10972
11109
|
const legendRef = React15__namespace.default.useRef(null);
|
|
10973
11110
|
useOnWindowResize(() => {
|
|
@@ -10990,7 +11127,7 @@ var ChartLegend3 = ({ payload }, categoryColors, setLegendHeight, activeLegend,
|
|
|
10990
11127
|
{ "justify-end": legendPosition === "right" }
|
|
10991
11128
|
),
|
|
10992
11129
|
children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
10993
|
-
|
|
11130
|
+
Legend5,
|
|
10994
11131
|
{
|
|
10995
11132
|
categories: filteredPayload.map((entry) => entry.value),
|
|
10996
11133
|
colors: filteredPayload.map((entry) => categoryColors.get(entry.value)),
|
|
@@ -11827,7 +11964,7 @@ var ScrollButton3 = ({ icon, onClick, disabled }) => {
|
|
|
11827
11964
|
}
|
|
11828
11965
|
);
|
|
11829
11966
|
};
|
|
11830
|
-
var
|
|
11967
|
+
var Legend6 = React15__namespace.default.forwardRef((props, ref) => {
|
|
11831
11968
|
const {
|
|
11832
11969
|
categories,
|
|
11833
11970
|
barCategoryColors,
|
|
@@ -11969,7 +12106,7 @@ var Legend4 = React15__namespace.default.forwardRef((props, ref) => {
|
|
|
11969
12106
|
) }) : null
|
|
11970
12107
|
] });
|
|
11971
12108
|
});
|
|
11972
|
-
|
|
12109
|
+
Legend6.displayName = "Legend";
|
|
11973
12110
|
var ChartLegend4 = ({ payload }, barCategoryColors, lineCategoryColors, setLegendHeight, activeLegend, onClick, enableLegendSlider, legendPosition, barYAxisWidth, lineYAxisWidth) => {
|
|
11974
12111
|
const legendRef = React15__namespace.default.useRef(null);
|
|
11975
12112
|
useOnWindowResize(() => {
|
|
@@ -11993,7 +12130,7 @@ var ChartLegend4 = ({ payload }, barCategoryColors, lineCategoryColors, setLegen
|
|
|
11993
12130
|
{ "justify-end": legendPosition === "right" }
|
|
11994
12131
|
),
|
|
11995
12132
|
children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
11996
|
-
|
|
12133
|
+
Legend6,
|
|
11997
12134
|
{
|
|
11998
12135
|
categories: filteredPayload.map((entry) => ({
|
|
11999
12136
|
name: entry.value,
|
|
@@ -12879,7 +13016,7 @@ var ScrollButton4 = ({ icon, onClick, disabled }) => {
|
|
|
12879
13016
|
}
|
|
12880
13017
|
);
|
|
12881
13018
|
};
|
|
12882
|
-
var
|
|
13019
|
+
var Legend7 = React15__namespace.default.forwardRef((props, ref) => {
|
|
12883
13020
|
const {
|
|
12884
13021
|
categories,
|
|
12885
13022
|
colors: colors2 = AvailableChartColors,
|
|
@@ -13019,7 +13156,7 @@ var Legend5 = React15__namespace.default.forwardRef((props, ref) => {
|
|
|
13019
13156
|
) }) : null
|
|
13020
13157
|
] });
|
|
13021
13158
|
});
|
|
13022
|
-
|
|
13159
|
+
Legend7.displayName = "Legend";
|
|
13023
13160
|
var ChartLegend5 = ({ payload }, categoryColors, setLegendHeight, activeLegend, onClick, enableLegendSlider, legendPosition, yAxisWidth) => {
|
|
13024
13161
|
const legendRef = React15__namespace.default.useRef(null);
|
|
13025
13162
|
useOnWindowResize(() => {
|
|
@@ -13040,7 +13177,7 @@ var ChartLegend5 = ({ payload }, categoryColors, setLegendHeight, activeLegend,
|
|
|
13040
13177
|
{ "justify-end": legendPosition === "right" }
|
|
13041
13178
|
),
|
|
13042
13179
|
children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
13043
|
-
|
|
13180
|
+
Legend7,
|
|
13044
13181
|
{
|
|
13045
13182
|
categories: legendPayload.map((entry) => entry.value),
|
|
13046
13183
|
colors: legendPayload.map((entry) => categoryColors.get(entry.value)),
|
|
@@ -14477,6 +14614,35 @@ function InputOTPSlot({
|
|
|
14477
14614
|
function InputOTPSeparator({ ...props }) {
|
|
14478
14615
|
return /* @__PURE__ */ jsxRuntime.jsx("div", { "data-slot": "input-otp-separator", role: "separator", ...props, children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.MinusIcon, {}) });
|
|
14479
14616
|
}
|
|
14617
|
+
function Prose({
|
|
14618
|
+
as,
|
|
14619
|
+
className,
|
|
14620
|
+
...props
|
|
14621
|
+
}) {
|
|
14622
|
+
const Component = as ?? "div";
|
|
14623
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
14624
|
+
Component,
|
|
14625
|
+
{
|
|
14626
|
+
className: clsx4__default.default(
|
|
14627
|
+
className,
|
|
14628
|
+
"prose dark:!prose-invert max-w-none",
|
|
14629
|
+
// headings
|
|
14630
|
+
"",
|
|
14631
|
+
// lead
|
|
14632
|
+
"",
|
|
14633
|
+
// links
|
|
14634
|
+
"prose-a:font-medium prose-a:text-primary-800 prose-a:dark:text-grey-100 prose-a:hover:bg-primary-800/10 prose-a:focus-visible:bg-primary-800/10",
|
|
14635
|
+
// link underline
|
|
14636
|
+
"prose-a:underline prose-a:decoration-primary-800 prose-a:underline-offset-4 prose-a:hover:decoration-2",
|
|
14637
|
+
// pre
|
|
14638
|
+
"",
|
|
14639
|
+
// hr
|
|
14640
|
+
""
|
|
14641
|
+
),
|
|
14642
|
+
...props
|
|
14643
|
+
}
|
|
14644
|
+
);
|
|
14645
|
+
}
|
|
14480
14646
|
var MOBILE_BREAKPOINT = 768;
|
|
14481
14647
|
function useIsMobile() {
|
|
14482
14648
|
const [isMobile, setIsMobile] = React15__namespace.useState(void 0);
|
|
@@ -14726,6 +14892,7 @@ exports.ContextMenuSub = ContextMenuSub;
|
|
|
14726
14892
|
exports.ContextMenuSubContent = ContextMenuSubContent;
|
|
14727
14893
|
exports.ContextMenuSubTrigger = ContextMenuSubTrigger;
|
|
14728
14894
|
exports.ContextMenuTrigger = ContextMenuTrigger;
|
|
14895
|
+
exports.Description = Description2;
|
|
14729
14896
|
exports.Dialog = Dialog;
|
|
14730
14897
|
exports.DialogClose = DialogClose;
|
|
14731
14898
|
exports.DialogContent = DialogContent;
|
|
@@ -14763,8 +14930,12 @@ exports.DropdownMenuSubContent = DropdownMenuSubContent;
|
|
|
14763
14930
|
exports.DropdownMenuSubTrigger = DropdownMenuSubTrigger;
|
|
14764
14931
|
exports.DropdownMenuTrigger = DropdownMenuTrigger;
|
|
14765
14932
|
exports.DynamicFavicon = DynamicFavicon;
|
|
14933
|
+
exports.ErrorMessage = ErrorMessage;
|
|
14766
14934
|
exports.ExpandableSearch = ExpandableSearch;
|
|
14767
14935
|
exports.ExpandableSearchField = ExpandableSearchField;
|
|
14936
|
+
exports.Field = Field2;
|
|
14937
|
+
exports.FieldGroup = FieldGroup;
|
|
14938
|
+
exports.Fieldset = Fieldset2;
|
|
14768
14939
|
exports.Footer = Footer;
|
|
14769
14940
|
exports.FooterAcknowledgement = FooterAcknowledgement;
|
|
14770
14941
|
exports.FooterLegalLinks = FooterLegalLinks;
|
|
@@ -14790,7 +14961,8 @@ exports.InputOTP = InputOTP;
|
|
|
14790
14961
|
exports.InputOTPGroup = InputOTPGroup;
|
|
14791
14962
|
exports.InputOTPSeparator = InputOTPSeparator;
|
|
14792
14963
|
exports.InputOTPSlot = InputOTPSlot;
|
|
14793
|
-
exports.Label =
|
|
14964
|
+
exports.Label = Label4;
|
|
14965
|
+
exports.Legend = Legend2;
|
|
14794
14966
|
exports.LineChart = LineChart;
|
|
14795
14967
|
exports.Link = Link;
|
|
14796
14968
|
exports.List = _List;
|
|
@@ -14840,6 +15012,7 @@ exports.PrevNextLinksPageLink = PrevNextLinksPageLink;
|
|
|
14840
15012
|
exports.Progress = Progress;
|
|
14841
15013
|
exports.ProgressBar = ProgressBar;
|
|
14842
15014
|
exports.ProgressCircle = ProgressCircle;
|
|
15015
|
+
exports.Prose = Prose;
|
|
14843
15016
|
exports.RadioGroup = RadioGroup2;
|
|
14844
15017
|
exports.RadioGroupItem = RadioGroupItem;
|
|
14845
15018
|
exports.ResizableHandle = ResizableHandle;
|
|
@@ -14961,11 +15134,13 @@ exports.themeIndices = themeIndices;
|
|
|
14961
15134
|
exports.themeTokens = themeTokens;
|
|
14962
15135
|
exports.toggleVariants = toggleVariants;
|
|
14963
15136
|
exports.truncate = truncate;
|
|
15137
|
+
exports.useActiveSectionObserver = useActiveSectionObserver;
|
|
14964
15138
|
exports.useDisableToc = useDisableToc;
|
|
14965
15139
|
exports.useFormField = useFormField;
|
|
14966
15140
|
exports.useIsMobile = useIsMobile;
|
|
14967
15141
|
exports.useOnWindowResize = useOnWindowResize;
|
|
14968
15142
|
exports.usePageHeadings = usePageHeadings;
|
|
15143
|
+
exports.useSelectorHeight = useSelectorHeight;
|
|
14969
15144
|
exports.useToc = useToc;
|
|
14970
15145
|
//# sourceMappingURL=index.cjs.map
|
|
14971
15146
|
//# sourceMappingURL=index.cjs.map
|