@orangecheck/app-design 1.6.2 → 1.7.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/README.md +3 -3
- package/dist/chrome.d.mts +11 -6
- package/dist/chrome.d.ts +11 -6
- package/dist/chrome.js +152 -128
- package/dist/chrome.js.map +1 -1
- package/dist/chrome.mjs +151 -129
- package/dist/chrome.mjs.map +1 -1
- package/dist/components.d.mts +40 -5
- package/dist/components.d.ts +40 -5
- package/dist/components.js +131 -10
- package/dist/components.js.map +1 -1
- package/dist/components.mjs +128 -11
- package/dist/components.mjs.map +1 -1
- package/dist/{docs-CFE5mU_6.d.mts → docs-B9G1BNXI.d.mts} +2 -2
- package/dist/{docs-ByUx4t-D.d.ts → docs-BWWnm5Jv.d.ts} +2 -2
- package/dist/family.d.mts +1 -1
- package/dist/family.d.ts +1 -1
- package/dist/family.js +7 -1
- package/dist/family.js.map +1 -1
- package/dist/family.mjs +5 -2
- package/dist/family.mjs.map +1 -1
- package/dist/{index-DmfyPYe5.d.mts → index-Bkl49Vgy.d.mts} +4 -1
- package/dist/{index-DmfyPYe5.d.ts → index-Bkl49Vgy.d.ts} +4 -1
- package/dist/index.d.mts +7 -7
- package/dist/index.d.ts +7 -7
- package/dist/index.js +189 -43
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +181 -44
- package/dist/index.mjs.map +1 -1
- package/dist/mdx.d.mts +3 -3
- package/dist/mdx.d.ts +3 -3
- package/dist/mdx.js +3 -2
- package/dist/mdx.js.map +1 -1
- package/dist/mdx.mjs +3 -2
- package/dist/mdx.mjs.map +1 -1
- package/dist/primitives.d.mts +2 -2
- package/dist/primitives.d.ts +2 -2
- package/dist/session.d.mts +4 -4
- package/dist/session.d.ts +4 -4
- package/dist/session.js +122 -1
- package/dist/session.js.map +1 -1
- package/dist/session.mjs +122 -1
- package/dist/session.mjs.map +1 -1
- package/dist/{status-badge-BJ9Sdsx8.d.mts → status-badge-BBbCO6ZA.d.mts} +1 -1
- package/dist/{status-badge-Bt8x3RhO.d.ts → status-badge-CHHxtFkP.d.ts} +1 -1
- package/dist/styles/swagger.css +24 -1
- package/dist/styles/tokens.css +5 -0
- package/dist/{tool-shell-CQZNRUgH.d.mts → tool-shell-CnZ3NUSi.d.ts} +10 -4
- package/dist/{tool-shell-CRmceGrV.d.ts → tool-shell-DQFEMLLe.d.mts} +10 -4
- package/dist/{tools-Bg1gi2HO.d.mts → tools-CKO8IseL.d.mts} +2 -2
- package/dist/{tools-Bw7RhO92.d.ts → tools-CzjFPng4.d.ts} +2 -2
- package/package.json +2 -2
package/dist/chrome.mjs
CHANGED
|
@@ -3,16 +3,16 @@ import Link from 'next/link';
|
|
|
3
3
|
import { forwardRef, createContext, useContext, useState, useMemo, useEffect, useRef, useId, useSyncExternalStore, createElement } from 'react';
|
|
4
4
|
import { clsx } from 'clsx';
|
|
5
5
|
import { extendTailwindMerge } from 'tailwind-merge';
|
|
6
|
-
import {
|
|
6
|
+
import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
|
|
7
|
+
import { Slot } from '@radix-ui/react-slot';
|
|
8
|
+
import { cva } from 'class-variance-authority';
|
|
9
|
+
import * as SeparatorPrimitive from '@radix-ui/react-separator';
|
|
10
|
+
import { useTheme } from 'next-themes';
|
|
11
|
+
import 'sonner';
|
|
7
12
|
import * as DialogPrimitive from '@radix-ui/react-dialog';
|
|
8
13
|
import * as DropdownMenuPrimitive from '@radix-ui/react-dropdown-menu';
|
|
9
14
|
import * as PopoverPrimitive from '@radix-ui/react-popover';
|
|
10
15
|
import * as TooltipPrimitive from '@radix-ui/react-tooltip';
|
|
11
|
-
import { useTheme } from 'next-themes';
|
|
12
|
-
import { cva } from 'class-variance-authority';
|
|
13
|
-
import * as SeparatorPrimitive from '@radix-ui/react-separator';
|
|
14
|
-
import 'sonner';
|
|
15
|
-
import { Slot } from '@radix-ui/react-slot';
|
|
16
16
|
import { useRouter } from 'next/compat/router';
|
|
17
17
|
|
|
18
18
|
var merge = extendTailwindMerge({
|
|
@@ -108,6 +108,9 @@ function Lockup({ name = "orangecheck", size = 28, className }) {
|
|
|
108
108
|
// src/family/index.ts
|
|
109
109
|
var OCHK_IO = "https://ochk.io";
|
|
110
110
|
var DOCS_HREF = `${OCHK_IO}/docs`;
|
|
111
|
+
var OCHK_APP = "https://ochk.app";
|
|
112
|
+
var GET_AN_ACCOUNT = { href: OCHK_APP, label: "Get an account" };
|
|
113
|
+
var SIGN_IN_LABEL = "Sign in";
|
|
111
114
|
function protocol(slug, verb, line, kinds) {
|
|
112
115
|
return {
|
|
113
116
|
slug,
|
|
@@ -144,7 +147,7 @@ var FAMILY = [
|
|
|
144
147
|
{
|
|
145
148
|
slug: "me",
|
|
146
149
|
label: "ochk.app",
|
|
147
|
-
href:
|
|
150
|
+
href: OCHK_APP,
|
|
148
151
|
group: "orangecheck",
|
|
149
152
|
line: "One account, with Bitcoin behind it.",
|
|
150
153
|
status: "testing"
|
|
@@ -253,6 +256,93 @@ var OCHK_IO_FOOTER = [
|
|
|
253
256
|
]
|
|
254
257
|
}
|
|
255
258
|
];
|
|
259
|
+
function Spinner({ className, label }) {
|
|
260
|
+
return /* @__PURE__ */ jsxs(
|
|
261
|
+
"svg",
|
|
262
|
+
{
|
|
263
|
+
viewBox: "0 0 24 24",
|
|
264
|
+
fill: "none",
|
|
265
|
+
role: label ? "status" : void 0,
|
|
266
|
+
"aria-label": label,
|
|
267
|
+
"aria-hidden": label ? void 0 : true,
|
|
268
|
+
className: cn("size-4 animate-spin", className),
|
|
269
|
+
children: [
|
|
270
|
+
/* @__PURE__ */ jsx("circle", { cx: "12", cy: "12", r: "9", stroke: "currentColor", strokeOpacity: "0.2", strokeWidth: "2.5" }),
|
|
271
|
+
/* @__PURE__ */ jsx("path", { d: "M21 12a9 9 0 0 0-9-9", stroke: "currentColor", strokeWidth: "2.5", strokeLinecap: "round" })
|
|
272
|
+
]
|
|
273
|
+
}
|
|
274
|
+
);
|
|
275
|
+
}
|
|
276
|
+
forwardRef(function Separator2({ className, orientation = "horizontal", decorative = true, ...props }, ref) {
|
|
277
|
+
return /* @__PURE__ */ jsx(
|
|
278
|
+
SeparatorPrimitive.Root,
|
|
279
|
+
{
|
|
280
|
+
ref,
|
|
281
|
+
decorative,
|
|
282
|
+
orientation,
|
|
283
|
+
className: cn(
|
|
284
|
+
"shrink-0 bg-border",
|
|
285
|
+
orientation === "horizontal" ? "h-px w-full" : "h-full w-px",
|
|
286
|
+
className
|
|
287
|
+
),
|
|
288
|
+
...props
|
|
289
|
+
}
|
|
290
|
+
);
|
|
291
|
+
});
|
|
292
|
+
var buttonVariants = cva(
|
|
293
|
+
[
|
|
294
|
+
"inline-flex shrink-0 select-none items-center justify-center gap-2 whitespace-nowrap rounded-full font-medium",
|
|
295
|
+
"transition-[background-color,border-color,color,box-shadow,transform] duration-150",
|
|
296
|
+
"outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-background",
|
|
297
|
+
"active:translate-y-px disabled:pointer-events-none",
|
|
298
|
+
// Disabled is one look for every variant: a quiet grey pill, never a
|
|
299
|
+
// faded black or orange slab that reads as broken.
|
|
300
|
+
"disabled:border disabled:border-border disabled:bg-muted disabled:text-oca-subtle disabled:shadow-none",
|
|
301
|
+
"[&_svg]:pointer-events-none [&_svg]:size-[1.1em] [&_svg]:shrink-0"
|
|
302
|
+
],
|
|
303
|
+
{
|
|
304
|
+
variants: {
|
|
305
|
+
variant: {
|
|
306
|
+
primary: "bg-primary text-primary-foreground hover:bg-primary/85",
|
|
307
|
+
secondary: "border border-border bg-secondary text-secondary-foreground hover:border-oca-hairline-strong hover:bg-accent",
|
|
308
|
+
brand: "bg-brand text-brand-foreground hover:bg-oca-orange-deep",
|
|
309
|
+
ghost: "text-foreground hover:bg-accent",
|
|
310
|
+
danger: "bg-destructive text-destructive-foreground hover:bg-destructive/90",
|
|
311
|
+
link: "h-auto rounded-none px-0 text-foreground underline decoration-foreground/35 underline-offset-4 hover:decoration-foreground",
|
|
312
|
+
onInk: "bg-white text-oca-ink hover:bg-white/90",
|
|
313
|
+
onInkOutline: "border border-white/20 text-white hover:bg-white/10"
|
|
314
|
+
},
|
|
315
|
+
size: {
|
|
316
|
+
sm: "h-9 px-4 text-sm",
|
|
317
|
+
md: "h-11 px-5 text-[0.9375rem]",
|
|
318
|
+
lg: "h-14 px-7 text-[1.0625rem]",
|
|
319
|
+
icon: "size-10",
|
|
320
|
+
"icon-sm": "size-8"
|
|
321
|
+
}
|
|
322
|
+
},
|
|
323
|
+
compoundVariants: [{ variant: "link", className: "h-auto px-0" }],
|
|
324
|
+
defaultVariants: { variant: "primary", size: "md" }
|
|
325
|
+
}
|
|
326
|
+
);
|
|
327
|
+
var Button = forwardRef(function Button2({ className, variant, size, asChild = false, loading = false, disabled, children, type, ...props }, ref) {
|
|
328
|
+
const Comp = asChild ? Slot : "button";
|
|
329
|
+
return /* @__PURE__ */ jsx(
|
|
330
|
+
Comp,
|
|
331
|
+
{
|
|
332
|
+
ref,
|
|
333
|
+
"data-ui": "button",
|
|
334
|
+
className: cn(buttonVariants({ variant, size }), className),
|
|
335
|
+
disabled: asChild ? void 0 : disabled || loading,
|
|
336
|
+
"aria-busy": loading || void 0,
|
|
337
|
+
type: asChild ? void 0 : type ?? "button",
|
|
338
|
+
...props,
|
|
339
|
+
children: asChild ? children : /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
340
|
+
loading ? /* @__PURE__ */ jsx(Spinner, { className: "size-[1.1em]" }) : null,
|
|
341
|
+
children
|
|
342
|
+
] })
|
|
343
|
+
}
|
|
344
|
+
);
|
|
345
|
+
});
|
|
256
346
|
var overlayClass = "oca-animate-fade fixed inset-0 z-50 bg-[rgb(10_10_10/0.38)] backdrop-blur-[2px] data-[state=closed]:opacity-0";
|
|
257
347
|
forwardRef(function DialogContent2({ className, children, hideClose, ...props }, ref) {
|
|
258
348
|
return /* @__PURE__ */ jsxs(DialogPrimitive.Portal, { children: [
|
|
@@ -416,7 +506,8 @@ function sharedContext(name, initial) {
|
|
|
416
506
|
return store[key] ?? (store[key] = createContext(initial));
|
|
417
507
|
}
|
|
418
508
|
|
|
419
|
-
// src/lib/
|
|
509
|
+
// src/lib/column.ts
|
|
510
|
+
var InColumnContext = sharedContext("in-column", false);
|
|
420
511
|
var ShellContext = sharedContext("shell-place", {});
|
|
421
512
|
function useShellPlace() {
|
|
422
513
|
return useContext(ShellContext);
|
|
@@ -828,7 +919,7 @@ function SidebarShell({
|
|
|
828
919
|
/* @__PURE__ */ jsxs("div", { className: "flex min-w-0 flex-1 flex-col", children: [
|
|
829
920
|
/* @__PURE__ */ jsx("div", { className: "hidden h-[4.5rem] items-center justify-end gap-3 px-8 lg:flex", children: account }),
|
|
830
921
|
banner ? /* @__PURE__ */ jsx("div", { className: "px-4 pb-2 pt-4 md:px-8 lg:pt-0", children: banner }) : null,
|
|
831
|
-
/* @__PURE__ */ jsx("main", { id: "main-content", className: "flex-1 px-4 pb-16 pt-6 md:px-8 lg:pt-2", children: /* @__PURE__ */ jsx("div", { className: "mx-auto w-full max-w-[72rem]", children }) })
|
|
922
|
+
/* @__PURE__ */ jsx("main", { id: "main-content", className: "flex-1 px-4 pb-16 pt-6 md:px-8 lg:pt-2", children: /* @__PURE__ */ jsx("div", { className: "mx-auto w-full max-w-[72rem]", children: /* @__PURE__ */ jsx(InColumnContext.Provider, { value: true, children }) }) })
|
|
832
923
|
] })
|
|
833
924
|
] }),
|
|
834
925
|
tabs ? /* @__PURE__ */ jsx(TabBar, { items: tabs }) : null
|
|
@@ -1023,6 +1114,18 @@ function NavDropdown({ item }) {
|
|
|
1023
1114
|
] })
|
|
1024
1115
|
] });
|
|
1025
1116
|
}
|
|
1117
|
+
function AccountCta({ href = GET_AN_ACCOUNT.href, className }) {
|
|
1118
|
+
return /* @__PURE__ */ jsx(Button, { asChild: true, size: "sm", className, children: /* @__PURE__ */ jsx("a", { href, children: GET_AN_ACCOUNT.label }) });
|
|
1119
|
+
}
|
|
1120
|
+
function ProductLockup({ size, product }) {
|
|
1121
|
+
return /* @__PURE__ */ jsxs("span", { className: "inline-flex items-center", children: [
|
|
1122
|
+
/* @__PURE__ */ jsx(Lockup, { size }),
|
|
1123
|
+
product ? /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
1124
|
+
/* @__PURE__ */ jsx("span", { "aria-hidden": true, className: "mx-3 h-5 w-px bg-oca-hairline-strong" }),
|
|
1125
|
+
/* @__PURE__ */ jsx("span", { className: "font-medium tracking-[-0.01em]", style: { fontSize: size * 0.56 }, children: product })
|
|
1126
|
+
] }) : null
|
|
1127
|
+
] });
|
|
1128
|
+
}
|
|
1026
1129
|
function SiteHeader({
|
|
1027
1130
|
home = "/",
|
|
1028
1131
|
brand,
|
|
@@ -1042,13 +1145,7 @@ function SiteHeader({
|
|
|
1042
1145
|
const current = typeof family === "string" ? family : void 0;
|
|
1043
1146
|
const phoneNav = navOnPhone ? nav : [];
|
|
1044
1147
|
const menu = phoneNav.length > 0 || Boolean(family) || Boolean(menuExtra);
|
|
1045
|
-
const brandNode = brand ?? /* @__PURE__ */
|
|
1046
|
-
/* @__PURE__ */ jsx(Lockup, { size }),
|
|
1047
|
-
product ? /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
1048
|
-
/* @__PURE__ */ jsx("span", { "aria-hidden": true, className: "mx-3 h-5 w-px bg-oca-hairline-strong" }),
|
|
1049
|
-
/* @__PURE__ */ jsx("span", { className: "font-medium tracking-[-0.01em]", style: { fontSize: size * 0.56 }, children: product })
|
|
1050
|
-
] }) : null
|
|
1051
|
-
] });
|
|
1148
|
+
const brandNode = brand ?? /* @__PURE__ */ jsx(ProductLockup, { size, product });
|
|
1052
1149
|
const navigation = nav.length > 0 ? /* @__PURE__ */ jsx("nav", { "aria-label": "Main", className: "hidden items-center gap-1 md:flex", children: nav.map(
|
|
1053
1150
|
(n) => n.children?.length ? /* @__PURE__ */ jsx(NavDropdown, { item: n }, n.href) : (
|
|
1054
1151
|
// Between md and lg the family menu and the actions share the row: tighter.
|
|
@@ -1178,7 +1275,7 @@ function SiteBanner({
|
|
|
1178
1275
|
var FOOT_LINK = "inline-flex min-h-11 items-center transition-colors hover:text-foreground md:min-h-0";
|
|
1179
1276
|
function LegalRow({ links }) {
|
|
1180
1277
|
return /* @__PURE__ */ jsxs("div", { className: "flex flex-col gap-x-6 gap-y-2 sm:flex-row sm:items-center sm:justify-between", children: [
|
|
1181
|
-
/* @__PURE__ */ jsx("nav", { "aria-label": "Legal", children: /* @__PURE__ */ jsx("ul", { className: "flex flex-wrap gap-x-5", children: links.map((l) => /* @__PURE__ */ jsx("li", { children: l.href.startsWith("/") ? /* @__PURE__ */ jsx(Link, { href: l.href, className: FOOT_LINK, children: l.label }) : /* @__PURE__ */ jsx("a", { href: l.href, className: FOOT_LINK, children: l.label }) }, l.
|
|
1278
|
+
/* @__PURE__ */ jsx("nav", { "aria-label": "Legal", children: /* @__PURE__ */ jsx("ul", { className: "flex flex-wrap gap-x-5", children: links.map((l, i) => /* @__PURE__ */ jsx("li", { children: l.href.startsWith("/") ? /* @__PURE__ */ jsx(Link, { href: l.href, className: FOOT_LINK, children: l.label }) : /* @__PURE__ */ jsx("a", { href: l.href, className: FOOT_LINK, children: l.label }) }, `${i}:${l.label}`)) }) }),
|
|
1182
1279
|
/* @__PURE__ */ jsxs("p", { children: [
|
|
1183
1280
|
"\xA9 ",
|
|
1184
1281
|
(/* @__PURE__ */ new Date()).getFullYear(),
|
|
@@ -1198,16 +1295,26 @@ function SiteFooter({
|
|
|
1198
1295
|
}) {
|
|
1199
1296
|
const legalLinks = legal === true ? LEGAL_LINKS : legal || null;
|
|
1200
1297
|
if (compact) {
|
|
1201
|
-
return
|
|
1202
|
-
|
|
1203
|
-
|
|
1204
|
-
|
|
1205
|
-
|
|
1206
|
-
|
|
1207
|
-
|
|
1208
|
-
|
|
1209
|
-
|
|
1210
|
-
|
|
1298
|
+
return (
|
|
1299
|
+
// The tools' column (ToolColumn): the lockup lines up with the page's title.
|
|
1300
|
+
/* @__PURE__ */ jsx("footer", { className: cn("border-t border-border bg-background px-4 text-[0.875rem] text-muted-foreground md:px-8", className), children: /* @__PURE__ */ jsxs("div", { className: "mx-auto flex w-full max-w-[72rem] flex-col gap-x-8 gap-y-3 py-5 lg:flex-row lg:items-center lg:justify-between", children: [
|
|
1301
|
+
/* @__PURE__ */ jsxs("div", { className: "flex flex-wrap items-center gap-x-6 gap-y-3", children: [
|
|
1302
|
+
/* @__PURE__ */ jsx(
|
|
1303
|
+
"a",
|
|
1304
|
+
{
|
|
1305
|
+
href: OCHK_IO,
|
|
1306
|
+
className: "relative rounded-lg text-foreground before:absolute before:inset-x-0 before:top-1/2 before:h-11 before:-translate-y-1/2",
|
|
1307
|
+
children: /* @__PURE__ */ jsx(Lockup, { size: 22 })
|
|
1308
|
+
}
|
|
1309
|
+
),
|
|
1310
|
+
family ? /* @__PURE__ */ jsx("nav", { "aria-label": "Protocols", children: /* @__PURE__ */ jsx("ul", { className: "flex flex-wrap gap-x-4", children: PROTOCOLS.map((p) => /* @__PURE__ */ jsx("li", { children: /* @__PURE__ */ jsx("a", { href: p.pageHref, className: FOOT_LINK, children: p.label }) }, p.slug)) }) }) : null
|
|
1311
|
+
] }),
|
|
1312
|
+
legalLinks || meta ? /* @__PURE__ */ jsxs("div", { className: "flex flex-col gap-x-6 gap-y-2 sm:flex-row sm:flex-wrap sm:items-center", children: [
|
|
1313
|
+
legalLinks ? /* @__PURE__ */ jsx(LegalRow, { links: legalLinks }) : null,
|
|
1314
|
+
meta
|
|
1315
|
+
] }) : null
|
|
1316
|
+
] }) })
|
|
1317
|
+
);
|
|
1211
1318
|
}
|
|
1212
1319
|
const cols = [
|
|
1213
1320
|
...columns,
|
|
@@ -1242,17 +1349,17 @@ function SiteFooter({
|
|
|
1242
1349
|
className: cn("flex min-w-0 flex-col gap-1", spans && "col-span-2 md:col-span-1"),
|
|
1243
1350
|
children: [
|
|
1244
1351
|
/* @__PURE__ */ jsx("p", { className: "mb-2 text-[0.875rem] font-medium", children: col.heading }),
|
|
1245
|
-
/* @__PURE__ */ jsx("div", { className: cn("flex flex-col gap-1", spans && "grid grid-cols-2 gap-x-6 md:flex md:flex-col"), children: col.links.map((l) => /* @__PURE__ */ jsx(
|
|
1352
|
+
/* @__PURE__ */ jsx("div", { className: cn("flex flex-col gap-1", spans && "grid grid-cols-2 gap-x-6 md:flex md:flex-col"), children: col.links.map((l, j) => /* @__PURE__ */ jsx(
|
|
1246
1353
|
NavLink,
|
|
1247
1354
|
{
|
|
1248
1355
|
item: l,
|
|
1249
1356
|
className: "-mx-3 py-2.5 text-[0.9375rem] md:py-1.5"
|
|
1250
1357
|
},
|
|
1251
|
-
l.
|
|
1358
|
+
`${j}:${l.label}`
|
|
1252
1359
|
)) })
|
|
1253
1360
|
]
|
|
1254
1361
|
},
|
|
1255
|
-
col.heading
|
|
1362
|
+
`${i}:${col.heading}`
|
|
1256
1363
|
);
|
|
1257
1364
|
})
|
|
1258
1365
|
]
|
|
@@ -1352,12 +1459,13 @@ function IsoCheck({ size = 360, settle = false, shadow = true, tilt = false, tit
|
|
|
1352
1459
|
);
|
|
1353
1460
|
}
|
|
1354
1461
|
function SignInFrame({
|
|
1355
|
-
title =
|
|
1462
|
+
title = SIGN_IN_LABEL,
|
|
1356
1463
|
lead,
|
|
1357
1464
|
children,
|
|
1358
1465
|
error,
|
|
1359
1466
|
fineprint,
|
|
1360
1467
|
brand,
|
|
1468
|
+
product,
|
|
1361
1469
|
home,
|
|
1362
1470
|
protocol: protocol2,
|
|
1363
1471
|
back,
|
|
@@ -1375,7 +1483,7 @@ function SignInFrame({
|
|
|
1375
1483
|
/* @__PURE__ */ jsxs("section", { className: "flex flex-col px-4 pb-8 pt-5 sm:px-8 lg:px-14 lg:pt-8", children: [
|
|
1376
1484
|
/* @__PURE__ */ jsxs("header", { className: "flex items-center justify-between gap-4", children: [
|
|
1377
1485
|
/* @__PURE__ */ jsxs(Link, { href: homeHref, className: "w-fit rounded-lg", children: [
|
|
1378
|
-
brand ?? /* @__PURE__ */ jsx(
|
|
1486
|
+
brand ?? /* @__PURE__ */ jsx(ProductLockup, { size: 28, product: product ?? (protocol2 ? protocolSite(protocol2).label : void 0) }),
|
|
1379
1487
|
/* @__PURE__ */ jsx("span", { className: "sr-only", children: " home" })
|
|
1380
1488
|
] }),
|
|
1381
1489
|
back === void 0 ? /* @__PURE__ */ jsx(
|
|
@@ -1412,97 +1520,10 @@ function SignInFrame({
|
|
|
1412
1520
|
}
|
|
1413
1521
|
);
|
|
1414
1522
|
}
|
|
1415
|
-
function Spinner({ className, label }) {
|
|
1416
|
-
return /* @__PURE__ */ jsxs(
|
|
1417
|
-
"svg",
|
|
1418
|
-
{
|
|
1419
|
-
viewBox: "0 0 24 24",
|
|
1420
|
-
fill: "none",
|
|
1421
|
-
role: label ? "status" : void 0,
|
|
1422
|
-
"aria-label": label,
|
|
1423
|
-
"aria-hidden": label ? void 0 : true,
|
|
1424
|
-
className: cn("size-4 animate-spin", className),
|
|
1425
|
-
children: [
|
|
1426
|
-
/* @__PURE__ */ jsx("circle", { cx: "12", cy: "12", r: "9", stroke: "currentColor", strokeOpacity: "0.2", strokeWidth: "2.5" }),
|
|
1427
|
-
/* @__PURE__ */ jsx("path", { d: "M21 12a9 9 0 0 0-9-9", stroke: "currentColor", strokeWidth: "2.5", strokeLinecap: "round" })
|
|
1428
|
-
]
|
|
1429
|
-
}
|
|
1430
|
-
);
|
|
1431
|
-
}
|
|
1432
|
-
forwardRef(function Separator3({ className, orientation = "horizontal", decorative = true, ...props }, ref) {
|
|
1433
|
-
return /* @__PURE__ */ jsx(
|
|
1434
|
-
SeparatorPrimitive.Root,
|
|
1435
|
-
{
|
|
1436
|
-
ref,
|
|
1437
|
-
decorative,
|
|
1438
|
-
orientation,
|
|
1439
|
-
className: cn(
|
|
1440
|
-
"shrink-0 bg-border",
|
|
1441
|
-
orientation === "horizontal" ? "h-px w-full" : "h-full w-px",
|
|
1442
|
-
className
|
|
1443
|
-
),
|
|
1444
|
-
...props
|
|
1445
|
-
}
|
|
1446
|
-
);
|
|
1447
|
-
});
|
|
1448
1523
|
var DensityContext = sharedContext("density", "comfortable");
|
|
1449
1524
|
function DensityProvider({ density, children }) {
|
|
1450
1525
|
return createElement(DensityContext.Provider, { value: density }, children);
|
|
1451
1526
|
}
|
|
1452
|
-
var buttonVariants = cva(
|
|
1453
|
-
[
|
|
1454
|
-
"inline-flex shrink-0 select-none items-center justify-center gap-2 whitespace-nowrap rounded-full font-medium",
|
|
1455
|
-
"transition-[background-color,border-color,color,box-shadow,transform] duration-150",
|
|
1456
|
-
"outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-background",
|
|
1457
|
-
"active:translate-y-px disabled:pointer-events-none",
|
|
1458
|
-
// Disabled is one look for every variant: a quiet grey pill, never a
|
|
1459
|
-
// faded black or orange slab that reads as broken.
|
|
1460
|
-
"disabled:border disabled:border-border disabled:bg-muted disabled:text-oca-subtle disabled:shadow-none",
|
|
1461
|
-
"[&_svg]:pointer-events-none [&_svg]:size-[1.1em] [&_svg]:shrink-0"
|
|
1462
|
-
],
|
|
1463
|
-
{
|
|
1464
|
-
variants: {
|
|
1465
|
-
variant: {
|
|
1466
|
-
primary: "bg-primary text-primary-foreground hover:bg-primary/85",
|
|
1467
|
-
secondary: "border border-border bg-secondary text-secondary-foreground hover:border-oca-hairline-strong hover:bg-accent",
|
|
1468
|
-
brand: "bg-brand text-brand-foreground hover:bg-oca-orange-deep",
|
|
1469
|
-
ghost: "text-foreground hover:bg-accent",
|
|
1470
|
-
danger: "bg-destructive text-destructive-foreground hover:bg-destructive/90",
|
|
1471
|
-
link: "h-auto rounded-none px-0 text-foreground underline decoration-foreground/35 underline-offset-4 hover:decoration-foreground",
|
|
1472
|
-
onInk: "bg-white text-oca-ink hover:bg-white/90",
|
|
1473
|
-
onInkOutline: "border border-white/20 text-white hover:bg-white/10"
|
|
1474
|
-
},
|
|
1475
|
-
size: {
|
|
1476
|
-
sm: "h-9 px-4 text-sm",
|
|
1477
|
-
md: "h-11 px-5 text-[0.9375rem]",
|
|
1478
|
-
lg: "h-14 px-7 text-[1.0625rem]",
|
|
1479
|
-
icon: "size-10",
|
|
1480
|
-
"icon-sm": "size-8"
|
|
1481
|
-
}
|
|
1482
|
-
},
|
|
1483
|
-
compoundVariants: [{ variant: "link", className: "h-auto px-0" }],
|
|
1484
|
-
defaultVariants: { variant: "primary", size: "md" }
|
|
1485
|
-
}
|
|
1486
|
-
);
|
|
1487
|
-
var Button = forwardRef(function Button2({ className, variant, size, asChild = false, loading = false, disabled, children, type, ...props }, ref) {
|
|
1488
|
-
const Comp = asChild ? Slot : "button";
|
|
1489
|
-
return /* @__PURE__ */ jsx(
|
|
1490
|
-
Comp,
|
|
1491
|
-
{
|
|
1492
|
-
ref,
|
|
1493
|
-
"data-ui": "button",
|
|
1494
|
-
className: cn(buttonVariants({ variant, size }), className),
|
|
1495
|
-
disabled: asChild ? void 0 : disabled || loading,
|
|
1496
|
-
"aria-busy": loading || void 0,
|
|
1497
|
-
type: asChild ? void 0 : type ?? "button",
|
|
1498
|
-
...props,
|
|
1499
|
-
children: asChild ? children : /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
1500
|
-
loading ? /* @__PURE__ */ jsx(Spinner, { className: "size-[1.1em]" }) : null,
|
|
1501
|
-
children
|
|
1502
|
-
] })
|
|
1503
|
-
}
|
|
1504
|
-
);
|
|
1505
|
-
});
|
|
1506
1527
|
function useActiveHeading(ids) {
|
|
1507
1528
|
const [active, setActive] = useState(ids[0]);
|
|
1508
1529
|
const key = ids.join("|");
|
|
@@ -1756,7 +1777,7 @@ function SessionAccountView({
|
|
|
1756
1777
|
items = [],
|
|
1757
1778
|
signInHref,
|
|
1758
1779
|
signInPath,
|
|
1759
|
-
signInLabel =
|
|
1780
|
+
signInLabel = SIGN_IN_LABEL,
|
|
1760
1781
|
accountHref = OCHK_APP_ACCOUNT,
|
|
1761
1782
|
onSignOut,
|
|
1762
1783
|
nameFrom = "lg"
|
|
@@ -1787,6 +1808,13 @@ function SessionAccountView({
|
|
|
1787
1808
|
/* @__PURE__ */ jsx("span", { className: state === "checking" ? "contents invisible" : "contents", "aria-hidden": state === "checking" || void 0, children: /* @__PURE__ */ jsx(Button, { asChild: true, size: "sm", variant: "secondary", tabIndex: state === "checking" ? -1 : void 0, children: /* @__PURE__ */ jsx("a", { href: signInHref ?? inPlace ?? "https://ochk.io/signin", children: signInLabel }) }) })
|
|
1788
1809
|
);
|
|
1789
1810
|
}
|
|
1811
|
+
function ToolColumn({
|
|
1812
|
+
measure = "wide",
|
|
1813
|
+
className,
|
|
1814
|
+
children
|
|
1815
|
+
}) {
|
|
1816
|
+
return /* @__PURE__ */ jsx("div", { className: cn("px-4 pb-16 pt-8 md:px-8 md:pt-10", className), children: /* @__PURE__ */ jsx("div", { className: "mx-auto w-full max-w-[72rem]", children: /* @__PURE__ */ jsx(InColumnContext.Provider, { value: true, children: measure === "narrow" ? /* @__PURE__ */ jsx("div", { className: "max-w-[48rem]", children }) : children }) }) });
|
|
1817
|
+
}
|
|
1790
1818
|
function ToolShell({
|
|
1791
1819
|
protocol: protocol2,
|
|
1792
1820
|
tools,
|
|
@@ -1795,6 +1823,7 @@ function ToolShell({
|
|
|
1795
1823
|
rail = false,
|
|
1796
1824
|
railFooter,
|
|
1797
1825
|
variant = "tool",
|
|
1826
|
+
measure = "wide",
|
|
1798
1827
|
banner,
|
|
1799
1828
|
footer,
|
|
1800
1829
|
children
|
|
@@ -1852,14 +1881,7 @@ function ToolShell({
|
|
|
1852
1881
|
/* @__PURE__ */ jsx(SideNav, { groups: [{ label: "Tools", items: tools.map(({ href, label, icon, active }) => ({ href, label, icon, active })) }] }),
|
|
1853
1882
|
railFooter ? /* @__PURE__ */ jsx("div", { className: "mt-auto flex flex-col gap-0.5 px-3 text-[0.875rem] text-muted-foreground [&_a:hover]:text-foreground [&_a]:py-1.5 [&_a]:transition-colors", children: railFooter }) : null
|
|
1854
1883
|
] }) : null,
|
|
1855
|
-
/* @__PURE__ */ jsx(
|
|
1856
|
-
"main",
|
|
1857
|
-
{
|
|
1858
|
-
id: "main-content",
|
|
1859
|
-
className: cn("min-w-0 flex-1", app ? "flex min-h-0 flex-col" : "px-4 pb-16 pt-8 md:px-8 md:pt-10"),
|
|
1860
|
-
children: /* @__PURE__ */ jsx(SiteHomeContext.Provider, { value: homeHref, children: app ? children : /* @__PURE__ */ jsx("div", { className: "mx-auto w-full max-w-[72rem]", children }) })
|
|
1861
|
-
}
|
|
1862
|
-
)
|
|
1884
|
+
/* @__PURE__ */ jsx("main", { id: "main-content", className: cn("min-w-0 flex-1", app && "flex min-h-0 flex-col"), children: /* @__PURE__ */ jsx(SiteHomeContext.Provider, { value: homeHref, children: app ? children : /* @__PURE__ */ jsx(ToolColumn, { measure, children }) }) })
|
|
1863
1885
|
] }),
|
|
1864
1886
|
app || footer === false ? null : footer ?? /* @__PURE__ */ jsx(SiteFooter, { compact: true, family: true, legal: true }),
|
|
1865
1887
|
tabs ? /* @__PURE__ */ jsx(TabBar, { items: tabs }) : null
|
|
@@ -1868,6 +1890,6 @@ function ToolShell({
|
|
|
1868
1890
|
) });
|
|
1869
1891
|
}
|
|
1870
1892
|
|
|
1871
|
-
export { AccountMenu, AppShell, DOCS_HEADER_NAV, DocsNav, DocsShell, FamilyMenu, OCHK_APP_ACCOUNT, OchkIoFooter, SessionAccountView, ShellContext, SignInFrame, SiteBanner, SiteFooter, SiteHeader, SkipLink, ThemeToggle, ToolShell, useShellPlace, useSignInHref };
|
|
1893
|
+
export { AccountCta, AccountMenu, AppShell, DOCS_HEADER_NAV, DocsNav, DocsShell, FamilyMenu, OCHK_APP_ACCOUNT, OchkIoFooter, SessionAccountView, ShellContext, SignInFrame, SiteBanner, SiteFooter, SiteHeader, SkipLink, ThemeToggle, ToolColumn, ToolShell, useShellPlace, useSignInHref };
|
|
1872
1894
|
//# sourceMappingURL=chrome.mjs.map
|
|
1873
1895
|
//# sourceMappingURL=chrome.mjs.map
|