@atom63/ui-react 0.2.0-beta.11 → 0.2.0-beta.13
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 +12 -0
- package/dist/button-DMnQeAEL.d.ts +22 -0
- package/dist/calendar/index.d.ts +2 -1
- package/dist/calendar/index.js +16 -1
- package/dist/calendar/index.js.map +1 -1
- package/dist/{chunk-J77BAGTA.js → chunk-IFBF2IA3.js} +17 -6
- package/dist/chunk-IFBF2IA3.js.map +1 -0
- package/dist/{chunk-NBHGMMQN.js → chunk-R7IQ3IL5.js} +26 -4
- package/dist/chunk-R7IQ3IL5.js.map +1 -0
- package/dist/{chunk-GDUMA6FI.js → chunk-RLF45GBS.js} +443 -275
- package/dist/chunk-RLF45GBS.js.map +1 -0
- package/dist/{chunk-R67OZVA2.js → chunk-WL27K6MO.js} +3 -2
- package/dist/chunk-WL27K6MO.js.map +1 -0
- package/dist/{chunk-X5L5DEUZ.js → chunk-ZEY2VU4O.js} +3 -3
- package/dist/{chunk-X5L5DEUZ.js.map → chunk-ZEY2VU4O.js.map} +1 -1
- package/dist/{destination-link-DMLeR-oF.d.ts → destination-link-BHVQyWry.d.ts} +2 -1
- package/dist/{index-BDzW8upQ.d.ts → index-CbgpSG4j.d.ts} +47 -8
- package/dist/index.d.ts +513 -141
- package/dist/index.js +1126 -235
- package/dist/index.js.map +1 -1
- package/dist/layout/index.d.ts +73 -1
- package/dist/layout/index.js +78 -2
- package/dist/layout/index.js.map +1 -1
- package/dist/media/index.d.ts +5 -4
- package/dist/media/index.js +35 -7
- package/dist/media/index.js.map +1 -1
- package/dist/media/media-lightbox/parts/index.d.ts +5 -4
- package/dist/media/media-lightbox/parts/index.js +2 -2
- package/dist/preview/index.d.ts +2 -3
- package/dist/preview/index.js +2 -2
- package/dist/theme/index.d.ts +3 -2
- package/dist/theme/index.js +2 -2
- package/dist/{types-Dxe5IzjE.d.ts → types-KQLxlHQZ.d.ts} +21 -0
- package/package.json +36 -26
- package/src/components/alert/alert.css +21 -18
- package/src/components/amount/amount.css +60 -0
- package/src/components/app-view/app-view.css +232 -0
- package/src/components/autocomplete/autocomplete.css +21 -5
- package/src/components/avatar/avatar.css +64 -8
- package/src/components/badge/badge.css +65 -0
- package/src/components/button/button.css +160 -31
- package/src/components/calendar/calendar.css +7 -3
- package/src/components/card/card.css +26 -10
- package/src/components/carousel/carousel.css +90 -5
- package/src/components/chat-composer/chat-composer.css +69 -0
- package/src/components/chat-message/chat-message.css +93 -0
- package/src/components/chat-steps/chat-steps.css +132 -0
- package/src/components/chat-typing-indicator/chat-typing-indicator.css +83 -0
- package/src/components/checkbox/checkbox.css +14 -1
- package/src/components/command/command.css +35 -5
- package/src/components/connected-panel/connected-panel.css +4 -19
- package/src/components/destination-link/destination-link.css +28 -0
- package/src/components/dialog/dialog.css +2 -2
- package/src/components/drawer/drawer.css +15 -2
- package/src/components/empty/empty.css +2 -4
- package/src/components/field/field.css +14 -9
- package/src/components/form/form.css +1 -1
- package/src/components/frame/frame.css +1 -1
- package/src/components/input/input.css +72 -4
- package/src/components/input-otp/input-otp.css +2 -2
- package/src/components/item/item.css +72 -2
- package/src/components/load-more-trigger/load-more-trigger.css +17 -0
- package/src/components/marquee/marquee.css +25 -3
- package/src/components/menu/menu.css +36 -1
- package/src/components/message/message.css +170 -0
- package/src/components/navigation-menu/navigation-menu.css +22 -4
- package/src/components/panel-setting-button/panel-setting-button.css +14 -0
- package/src/components/progress/progress.css +31 -1
- package/src/components/radio/radio.css +32 -5
- package/src/components/rating/rating.css +120 -0
- package/src/components/resizable/resizable.css +1 -1
- package/src/components/scroll-area/scroll-area.css +1 -1
- package/src/components/scrollable-list/scrollable-list.css +10 -5
- package/src/components/segmented-control/segmented-control.css +14 -0
- package/src/components/select/select.css +11 -3
- package/src/components/separator/separator.css +3 -1
- package/src/components/sheet/sheet.css +8 -4
- package/src/components/sidebar/sidebar.css +54 -24
- package/src/components/sidebar-nav-tree/sidebar-nav-tree.css +38 -5
- package/src/components/slider/slider.css +11 -6
- package/src/components/switch/switch.css +30 -11
- package/src/components/table/table.css +118 -10
- package/src/components/tabs/tabs.css +10 -0
- package/src/components/textarea/textarea.css +3 -3
- package/src/components/toaster/toaster.css +32 -0
- package/src/components/toggle/toggle.css +20 -8
- package/src/components/toggle-group/toggle-group.css +79 -1
- package/src/media/media-lightbox/media-lightbox.css +32 -2
- package/src/styles/recipes.css +10 -0
- package/src/styles/reset.css +13 -2
- package/src/styles/utilities.css +41 -28
- package/dist/button-CfLIHg-R.d.ts +0 -13
- package/dist/chunk-GDUMA6FI.js.map +0 -1
- package/dist/chunk-J77BAGTA.js.map +0 -1
- package/dist/chunk-NBHGMMQN.js.map +0 -1
- package/dist/chunk-R67OZVA2.js.map +0 -1
package/dist/layout/index.d.ts
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
import { ReactNode, CSSProperties, ComponentPropsWithoutRef, ReactElement } from 'react';
|
|
3
3
|
import { useRender } from '@base-ui/react/use-render';
|
|
4
|
+
import { AppViewLayout, AppViewChrome, AppViewTopBarSpan } from '@atom63/ui-foundation';
|
|
4
5
|
|
|
5
6
|
type ContainerMaxWidth = 'fluid' | 'widest' | 'wider' | 'wide' | 'default' | 'narrow' | 'narrower' | 'narrowest';
|
|
6
7
|
/** Shared max-width class map for Container and GridChrome. */
|
|
@@ -184,6 +185,76 @@ interface SectionHeaderProps {
|
|
|
184
185
|
}
|
|
185
186
|
declare function SectionHeader({ title, description, className, titleClassName, descriptionClassName, level, variant, align, }: SectionHeaderProps): React.JSX.Element;
|
|
186
187
|
|
|
188
|
+
type AppViewProps = Omit<React.ComponentProps<'div'>, 'children'> & {
|
|
189
|
+
/** The main region; it is the only part that scrolls. */
|
|
190
|
+
children: React.ReactNode;
|
|
191
|
+
/**
|
|
192
|
+
* `window` (the default): a desktop window, the side panel from `md` up and
|
|
193
|
+
* the tab bar on narrow screens only. `phone`: a phone app screen, edge to
|
|
194
|
+
* edge, with no side panel and the tab bar always shown. It stamps
|
|
195
|
+
* `data-a63-form-factor="phone"`, which sets phone-sized type and controls
|
|
196
|
+
* (body 17px, 44px controls) for everything inside.
|
|
197
|
+
*/
|
|
198
|
+
layout?: AppViewLayout;
|
|
199
|
+
/**
|
|
200
|
+
* How a `window` is drawn. `inset` (the default): a padded window with the
|
|
201
|
+
* side panel and the main region on rounded cards. `flush`: columns to the
|
|
202
|
+
* window edges, split by borders. `phone` is always flush.
|
|
203
|
+
*/
|
|
204
|
+
chrome?: AppViewChrome;
|
|
205
|
+
/** The bar across the top. It takes the top safe-area inset. */
|
|
206
|
+
topBar?: React.ReactNode;
|
|
207
|
+
/**
|
|
208
|
+
* Where the top bar runs in a `window`. `window` (the default): across the
|
|
209
|
+
* whole window. `main`: over the main region and the aside only, so the rail
|
|
210
|
+
* and the panel run the full height of the window.
|
|
211
|
+
*/
|
|
212
|
+
topBarSpan?: AppViewTopBarSpan;
|
|
213
|
+
/** A narrow column before the side panel, such as an icon rail; from `md` up, windows only. */
|
|
214
|
+
rail?: React.ReactNode;
|
|
215
|
+
/** The accessible name of the rail. */
|
|
216
|
+
railLabel?: string;
|
|
217
|
+
/**
|
|
218
|
+
* The rail's width as a CSS length (4rem by default). It sets
|
|
219
|
+
* `--a63-app-view-rail-width`, which a stylesheet can set too.
|
|
220
|
+
*/
|
|
221
|
+
railWidth?: string;
|
|
222
|
+
/** A side panel beside the main region, hidden on phones. */
|
|
223
|
+
panel?: React.ReactNode;
|
|
224
|
+
/** The accessible name of the side panel. */
|
|
225
|
+
panelLabel?: string;
|
|
226
|
+
/**
|
|
227
|
+
* The side panel's width as a CSS length, such as `'12.5rem'` (18rem by
|
|
228
|
+
* default). It sets `--a63-app-view-panel-width`, which a stylesheet can set too.
|
|
229
|
+
*/
|
|
230
|
+
panelWidth?: string;
|
|
231
|
+
/**
|
|
232
|
+
* Content floating over the main region, anchored to its bottom end and
|
|
233
|
+
* above the docked bar, such as a scroll-to-bottom button. It does not scroll.
|
|
234
|
+
*/
|
|
235
|
+
overlay?: React.ReactNode;
|
|
236
|
+
/**
|
|
237
|
+
* A column after the main region, such as a thread or a details pane; from
|
|
238
|
+
* `lg` up, windows only. Below `lg` it is not shown, so show its content
|
|
239
|
+
* another way there, such as in a Sheet.
|
|
240
|
+
*/
|
|
241
|
+
aside?: React.ReactNode;
|
|
242
|
+
/** The accessible name of the aside. */
|
|
243
|
+
asideLabel?: string;
|
|
244
|
+
/**
|
|
245
|
+
* The aside's width as a CSS length (22rem by default). It sets
|
|
246
|
+
* `--a63-app-view-aside-width`, which a stylesheet can set too.
|
|
247
|
+
*/
|
|
248
|
+
asideWidth?: string;
|
|
249
|
+
/** A bar docked at the bottom, such as a player, a status bar or an action bar. */
|
|
250
|
+
bottomBar?: React.ReactNode;
|
|
251
|
+
/** The accessible name of the docked bar's region. */
|
|
252
|
+
bottomBarLabel?: string;
|
|
253
|
+
/** Bottom navigation, such as the tab-bar block. It takes the bottom safe-area inset. */
|
|
254
|
+
tabBar?: React.ReactNode;
|
|
255
|
+
};
|
|
256
|
+
declare function AppView({ aside, asideLabel, asideWidth, bottomBar, bottomBarLabel, children, chrome, className, layout, overlay, panel, panelLabel, panelWidth, rail, railLabel, railWidth, style, tabBar, topBar, topBarSpan, ...props }: AppViewProps): React.ReactElement;
|
|
257
|
+
|
|
187
258
|
interface ReaderLayoutProps {
|
|
188
259
|
aside?: ReactNode;
|
|
189
260
|
asideClassName?: string;
|
|
@@ -195,4 +266,5 @@ interface ReaderLayoutProps {
|
|
|
195
266
|
}
|
|
196
267
|
declare function ReaderLayout({ aside, asideClassName, children, className, contentClassName, reserveAside, }: ReaderLayoutProps): React.JSX.Element;
|
|
197
268
|
|
|
198
|
-
export {
|
|
269
|
+
export { AppView, Container, DEFAULT_PAGE_SKELETON_COUNT, GRID_CHROME_VARS, GRID_HAIRLINE_CENTER_PX, GRID_HAIRLINE_PX, GridChrome, GridCrosshair, GridGuides, GridRule, Page, PageSkeleton, ReaderLayout, Section, SectionHeader, containerFrameClassName, containerMaxWidthStyles, gridChromeStyle, pageIndexHeroDescriptionClassName, pageIndexHeroTitleClassName, useGridChrome };
|
|
270
|
+
export type { AppViewProps, ContainerChrome, ContainerMaxWidth, ContainerPadding, ContainerProps, GridChromeContextValue, GridChromeCssVars, GridChromeLineStyle, GridChromeProps, GridChromeStyle, GridChromeTone, GridGuidesColumns, GridGuidesProps, GridRuleProps, PageProps, PageSkeletonProps, ReaderLayoutProps, SectionHeaderLevel, SectionHeaderProps, SectionHeaderVariant, SectionProps };
|
package/dist/layout/index.js
CHANGED
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
import { cn } from '../chunk-AJLHJRK6.js';
|
|
2
2
|
import { createContext, useContext } from 'react';
|
|
3
|
-
import { jsx, jsxs } from 'react/jsx-runtime';
|
|
3
|
+
import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
|
|
4
4
|
import { mergeProps } from '@base-ui/react/merge-props';
|
|
5
5
|
import { useRender } from '@base-ui/react/use-render';
|
|
6
|
+
import { appViewContract } from '@atom63/ui-foundation';
|
|
6
7
|
|
|
7
8
|
// src/layout/max-width.ts
|
|
8
9
|
var containerMaxWidthStyles = {
|
|
@@ -465,6 +466,81 @@ function SectionHeader({
|
|
|
465
466
|
}
|
|
466
467
|
);
|
|
467
468
|
}
|
|
469
|
+
function AppView({
|
|
470
|
+
aside,
|
|
471
|
+
asideLabel = "Details",
|
|
472
|
+
asideWidth,
|
|
473
|
+
bottomBar,
|
|
474
|
+
bottomBarLabel = "Player",
|
|
475
|
+
children,
|
|
476
|
+
chrome = appViewContract.defaultChrome,
|
|
477
|
+
className,
|
|
478
|
+
layout = appViewContract.defaultLayout,
|
|
479
|
+
overlay,
|
|
480
|
+
panel,
|
|
481
|
+
panelLabel = "Library",
|
|
482
|
+
panelWidth,
|
|
483
|
+
rail,
|
|
484
|
+
railLabel = "Navigation",
|
|
485
|
+
railWidth,
|
|
486
|
+
style,
|
|
487
|
+
tabBar,
|
|
488
|
+
topBar,
|
|
489
|
+
topBarSpan = appViewContract.defaultTopBarSpan,
|
|
490
|
+
...props
|
|
491
|
+
}) {
|
|
492
|
+
const bottomInset = tabBar ? "tab-bar" : bottomBar ? "bottom-bar" : "main";
|
|
493
|
+
const isWindow = layout === "window";
|
|
494
|
+
const spansMain = isWindow && topBarSpan === "main";
|
|
495
|
+
const widths = {
|
|
496
|
+
...panelWidth ? { "--a63-app-view-panel-width": panelWidth } : {},
|
|
497
|
+
...railWidth ? { "--a63-app-view-rail-width": railWidth } : {},
|
|
498
|
+
...asideWidth ? { "--a63-app-view-aside-width": asideWidth } : {}
|
|
499
|
+
};
|
|
500
|
+
const header = topBar ? /* @__PURE__ */ jsx("header", { "data-slot": "app-view-top-bar", children: topBar }) : null;
|
|
501
|
+
const content = /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
502
|
+
/* @__PURE__ */ jsx("main", { "data-slot": "app-view-main", tabIndex: 0, children }),
|
|
503
|
+
overlay ? /* @__PURE__ */ jsx("div", { "data-slot": "app-view-overlay", children: overlay }) : null,
|
|
504
|
+
aside && isWindow ? (
|
|
505
|
+
// eslint-disable-next-line jsx-a11y/no-noninteractive-tabindex -- a scroll region takes focus so a keyboard can scroll it.
|
|
506
|
+
/* @__PURE__ */ jsx("aside", { "aria-label": asideLabel, "data-slot": "app-view-aside", tabIndex: 0, children: aside })
|
|
507
|
+
) : null
|
|
508
|
+
] });
|
|
509
|
+
return /* @__PURE__ */ jsxs(
|
|
510
|
+
"div",
|
|
511
|
+
{
|
|
512
|
+
className: cn("a63-AppView", className),
|
|
513
|
+
"data-a63-form-factor": layout === "phone" ? "phone" : void 0,
|
|
514
|
+
"data-aside": aside && isWindow ? "" : void 0,
|
|
515
|
+
"data-bottom-inset": bottomInset,
|
|
516
|
+
"data-chrome": layout === "phone" ? "flush" : chrome,
|
|
517
|
+
"data-layout": layout,
|
|
518
|
+
"data-slot": "app-view",
|
|
519
|
+
"data-top-bar-span": isWindow ? topBarSpan : void 0,
|
|
520
|
+
style: Object.keys(widths).length ? { ...widths, ...style } : style,
|
|
521
|
+
...props,
|
|
522
|
+
children: [
|
|
523
|
+
spansMain ? null : header,
|
|
524
|
+
/* @__PURE__ */ jsxs("div", { "data-slot": "app-view-body", children: [
|
|
525
|
+
rail && isWindow ? (
|
|
526
|
+
// eslint-disable-next-line jsx-a11y/no-noninteractive-tabindex -- a scroll region takes focus so a keyboard can scroll it.
|
|
527
|
+
/* @__PURE__ */ jsx("aside", { "aria-label": railLabel, "data-slot": "app-view-rail", tabIndex: 0, children: rail })
|
|
528
|
+
) : null,
|
|
529
|
+
panel && isWindow ? (
|
|
530
|
+
// eslint-disable-next-line jsx-a11y/no-noninteractive-tabindex -- a scroll region takes focus so a keyboard can scroll it.
|
|
531
|
+
/* @__PURE__ */ jsx("aside", { "aria-label": panelLabel, "data-slot": "app-view-panel", tabIndex: 0, children: panel })
|
|
532
|
+
) : null,
|
|
533
|
+
spansMain ? /* @__PURE__ */ jsxs("div", { "data-slot": "app-view-content", children: [
|
|
534
|
+
header,
|
|
535
|
+
/* @__PURE__ */ jsx("div", { "data-slot": "app-view-body", children: content })
|
|
536
|
+
] }) : content
|
|
537
|
+
] }),
|
|
538
|
+
bottomBar ? /* @__PURE__ */ jsx("section", { "aria-label": bottomBarLabel, "data-slot": "app-view-bottom-bar", children: bottomBar }) : null,
|
|
539
|
+
tabBar ? /* @__PURE__ */ jsx("div", { "data-slot": "app-view-tab-bar", children: tabBar }) : null
|
|
540
|
+
]
|
|
541
|
+
}
|
|
542
|
+
);
|
|
543
|
+
}
|
|
468
544
|
function ReaderLayout({
|
|
469
545
|
aside,
|
|
470
546
|
asideClassName,
|
|
@@ -497,6 +573,6 @@ function ReaderLayout({
|
|
|
497
573
|
] });
|
|
498
574
|
}
|
|
499
575
|
|
|
500
|
-
export { Container, DEFAULT_PAGE_SKELETON_COUNT, GRID_CHROME_VARS, GRID_HAIRLINE_CENTER_PX, GRID_HAIRLINE_PX, GridChrome, GridCrosshair, GridGuides, GridRule, Page, PageSkeleton, ReaderLayout, Section, SectionHeader, containerFrameClassName, containerMaxWidthStyles, gridChromeStyle, pageIndexHeroDescriptionClassName, pageIndexHeroTitleClassName, useGridChrome };
|
|
576
|
+
export { AppView, Container, DEFAULT_PAGE_SKELETON_COUNT, GRID_CHROME_VARS, GRID_HAIRLINE_CENTER_PX, GRID_HAIRLINE_PX, GridChrome, GridCrosshair, GridGuides, GridRule, Page, PageSkeleton, ReaderLayout, Section, SectionHeader, containerFrameClassName, containerMaxWidthStyles, gridChromeStyle, pageIndexHeroDescriptionClassName, pageIndexHeroTitleClassName, useGridChrome };
|
|
501
577
|
//# sourceMappingURL=index.js.map
|
|
502
578
|
//# sourceMappingURL=index.js.map
|
package/dist/layout/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/layout/max-width.ts","../../src/layout/grid/hairline.ts","../../src/layout/grid/style.ts","../../src/layout/grid/chrome.tsx","../../src/layout/grid/crosshair.tsx","../../src/layout/grid/guides.tsx","../../src/layout/grid/rule.tsx","../../src/layout/container.tsx","../../src/layout/page.tsx","../../src/layout/page-skeleton.tsx","../../src/layout/section.tsx","../../src/layout/section-header.tsx","../../src/layout/reader-layout.tsx"],"names":["jsx","jsxs"],"mappings":";;;;;;;AAIO,IAAM,uBAAA,GAA6D;AAAA,EACxE,KAAA,EAAO,YAAA;AAAA,EACP,MAAA,EAAQ,WAAA;AAAA,EACR,KAAA,EAAO,WAAA;AAAA,EACP,IAAA,EAAM,WAAA;AAAA,EACN,OAAA,EAAS,WAAA;AAAA,EACT,MAAA,EAAQ,WAAA;AAAA,EACR,QAAA,EAAU,WAAA;AAAA,EACV,SAAA,EAAW;AACb;AAMO,SAAS,uBAAA,CAAwB,WAA8B,SAAA,EAAmB;AACvF,EAAA,OAAO,CAAA,uBAAA,EAA0B,uBAAA,CAAwB,QAAQ,CAAC,CAAA,CAAA;AACpE;;;ACjBO,IAAM,gBAAA,G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,QACvE,WAAA,EAAU,qBAAA;AAAA,QAET,QAAA,EAAA;AAAA;AAAA,KACH,GACE;AAAA,GAAA,EACN,CAAA;AAEJ","file":"index.js","sourcesContent":["export type ContainerMaxWidth =\n 'fluid' | 'widest' | 'wider' | 'wide' | 'default' | 'narrow' | 'narrower' | 'narrowest'\n\n/** Shared max-width class map for Container and GridChrome. */\nexport const containerMaxWidthStyles: Record<ContainerMaxWidth, string> = {\n fluid: 'max-w-full',\n widest: 'max-w-8xl',\n wider: 'max-w-7xl',\n wide: 'max-w-6xl',\n default: 'max-w-5xl',\n narrow: 'max-w-4xl',\n narrower: 'max-w-2xl',\n narrowest: 'max-w-xl',\n}\n\n/**\n * Centered max-width frame (no Tailwind `container` padding).\n * Used for fixed rails / guides so edges align with content chrome.\n */\nexport function containerFrameClassName(maxWidth: ContainerMaxWidth = 'default'): string {\n return `mx-auto w-full min-w-0 ${containerMaxWidthStyles[maxWidth]}`\n}\n","/**\n * Shared hairline metrics for grid chrome rails / rules / sparkles.\n * Must stay in sync with Tailwind `border` (1px) on rail + rule strokes.\n */\nexport const GRID_HAIRLINE_PX = 1\n\n/** Distance from the frame’s outer edge to the stroke’s optical center. */\nexport const GRID_HAIRLINE_CENTER_PX = GRID_HAIRLINE_PX / 2\n","import type { CSSProperties } from 'react'\nimport { GRID_HAIRLINE_PX } from './hairline'\n\nexport const GRID_CHROME_VARS = {\n lineColor: '--a63-grid-line-color',\n guideColor: '--a63-grid-guide-color',\n crosshairColor: '--a63-grid-crosshair-color',\n hairlineWidth: '--a63-grid-hairline-width',\n lineStyle: '--a63-grid-line-style',\n} as const\n\nexport type GridChromeLineStyle = 'solid' | 'dashed'\nexport type GridChromeTone = 'subtle' | 'default' | 'strong'\n\nexport type GridChromeCssVars = Partial<\n Record<(typeof GRID_CHROME_VARS)[keyof typeof GRID_CHROME_VARS], string>\n>\n\nexport type GridChromeStyle = CSSProperties & GridChromeCssVars\n\nconst GRID_CHROME_TONE_STYLES = {\n subtle: {\n [GRID_CHROME_VARS.lineColor]: 'color-mix(in oklch, var(--a63-border-subtle) 34%, transparent)',\n [GRID_CHROME_VARS.guideColor]: 'color-mix(in oklch, var(--a63-border-subtle) 16%, transparent)',\n [GRID_CHROME_VARS.crosshairColor]:\n 'color-mix(in oklch, var(--a63-border-subtle) 42%, transparent)',\n },\n default: {\n [GRID_CHROME_VARS.lineColor]: 'color-mix(in oklch, var(--a63-border-subtle) 50%, transparent)',\n [GRID_CHROME_VARS.guideColor]: 'color-mix(in oklch, var(--a63-border-subtle) 24%, transparent)',\n [GRID_CHROME_VARS.crosshairColor]:\n 'color-mix(in oklch, var(--a63-border-subtle) 58%, transparent)',\n },\n strong: {\n [GRID_CHROME_VARS.lineColor]: 'var(--a63-border-control)',\n [GRID_CHROME_VARS.guideColor]: 'var(--a63-border-subtle)',\n [GRID_CHROME_VARS.crosshairColor]: 'var(--a63-border-control)',\n },\n} as const satisfies Record<GridChromeTone, GridChromeCssVars>\n\nexport function gridChromeStyle({\n lineStyle,\n style,\n tone,\n}: {\n lineStyle: GridChromeLineStyle\n style?: GridChromeStyle\n tone: GridChromeTone\n}): GridChromeStyle {\n return {\n [GRID_CHROME_VARS.hairlineWidth]: `${GRID_HAIRLINE_PX}px`,\n [GRID_CHROME_VARS.lineStyle]: lineStyle,\n ...GRID_CHROME_TONE_STYLES[tone],\n ...style,\n }\n}\n","import { type ComponentPropsWithoutRef, createContext, type ReactNode, useContext } from 'react'\nimport { cn } from '../../lib/cn'\nimport { containerFrameClassName, type ContainerMaxWidth } from '../max-width'\nimport {\n gridChromeStyle,\n type GridChromeLineStyle,\n type GridChromeStyle,\n type GridChromeTone,\n} from './style'\n\nexport interface GridChromeContextValue {\n crosshairs: boolean\n /** True when page rails are painted by {@link GridChrome}. */\n fixedRails: boolean\n lineStyle: GridChromeLineStyle\n maxWidth: ContainerMaxWidth\n}\n\nconst GridChromeContext = createContext<GridChromeContextValue | null>(null)\n\nexport function useGridChrome(): GridChromeContextValue | null {\n return useContext(GridChromeContext)\n}\n\nexport interface GridChromeProps extends Omit<ComponentPropsWithoutRef<'div'>, 'children'> {\n children: ReactNode\n /**\n * Default sparkle crosshairs on nested `GridRule`s.\n * @default true\n */\n crosshairs?: boolean\n /**\n * Full-height vertical rails matching `maxWidth`. Absolute inside the chrome\n * (not `position: fixed` / sticky-on-self) so `max-w-*` + `mx-auto` keep working\n * and edges stay symmetric with the scroll container.\n * @default true\n */\n fixedRails?: boolean\n /**\n * Stroke style shared by rails, rules, and guides.\n * @default 'dashed'\n */\n lineStyle?: GridChromeLineStyle\n maxWidth?: ContainerMaxWidth\n /**\n * Central color preset for rails, rules, guides, and crosshairs.\n * Override individual values with CSS variables on `style`.\n * @default 'default'\n */\n tone?: GridChromeTone\n style?: GridChromeStyle\n}\n\n/**\n * Firecrawl-style page frame: continuous column rails + crosshair context.\n *\n * Wrap the **entire scroll document** (header, main, footer) so one pair of\n * rails meets every band. Nesting `GridChrome` only around a page body leaves\n * the footer as a floating card — the opposite of Firecrawl’s T-junctions.\n */\nexport function GridChrome({\n children,\n className,\n crosshairs = true,\n fixedRails = true,\n lineStyle = 'dashed',\n maxWidth = 'default',\n style,\n tone = 'default',\n ...props\n}: GridChromeProps) {\n return (\n <GridChromeContext.Provider value={{ crosshairs, fixedRails, lineStyle, maxWidth }}>\n <div\n className={cn('relative isolate flex min-h-svh flex-col', className)}\n data-slot=\"grid-chrome\"\n style={gridChromeStyle({ lineStyle, style, tone })}\n {...props}\n >\n {fixedRails ? (\n <div\n aria-hidden\n className=\"pointer-events-none absolute inset-0 z-[60]\"\n data-slot=\"grid-chrome-rails-root\"\n >\n {/*\n z-60 sits above sticky header (z-50) so backdrop-blur never frosts\n the hairlines. Width is constrained here (not sticky-on-self) so\n max-w + mx-auto stay aligned with the scrollport.\n */}\n <div\n className={cn(\n 'h-full min-h-svh border-y-0 border-[color:var(--a63-grid-line-color)]',\n lineStyle === 'solid' ? 'border-solid' : 'border-dashed',\n containerFrameClassName(maxWidth)\n )}\n data-slot=\"grid-chrome-rails\"\n style={{\n borderLeftWidth: 'var(--a63-grid-hairline-width)',\n borderRightWidth: 'var(--a63-grid-hairline-width)',\n }}\n />\n </div>\n ) : null}\n <div className=\"relative z-1 flex min-h-svh flex-1 flex-col\">{children}</div>\n </div>\n </GridChromeContext.Provider>\n )\n}\n","import type { ComponentPropsWithoutRef } from 'react'\nimport { cn } from '../../lib/cn'\n\n/**\n * Four-point sparkle at a rail / crossbar junction (Firecrawl-style).\n * Decorative — parent should set `aria-hidden`.\n */\nexport function GridCrosshair({\n className,\n ...props\n}: Omit<ComponentPropsWithoutRef<'svg'>, 'children' | 'viewBox'>) {\n return (\n <svg\n className={cn(\n 'size-3 text-[color:var(--a63-grid-crosshair-color,var(--input,var(--a63-border-subtle)))]',\n className\n )}\n fill=\"currentColor\"\n overflow=\"visible\"\n viewBox=\"0 0 24 24\"\n xmlns=\"http://www.w3.org/2000/svg\"\n {...props}\n >\n {/*\n Classic 4-point sparkle (concave sides, tips on the axes). Larger\n viewBox + softer control points so it reads as a star, not a plus.\n */}\n <path d=\"M12 0C12.8 7.2 7.2 12.8 0 12C7.2 12.8 12.8 16.8 12 24C11.2 16.8 16.8 12.8 24 12C16.8 11.2 12.8 7.2 12 0Z\" />\n </svg>\n )\n}\n","import type { ComponentPropsWithoutRef } from 'react'\nimport { cn } from '../../lib/cn'\nimport { containerFrameClassName } from '../max-width'\nimport { useGridChrome } from './chrome'\n\nexport type GridGuidesColumns = 2 | 3 | 4\n\nexport interface GridGuidesProps extends Omit<ComponentPropsWithoutRef<'div'>, 'children'> {\n /**\n * Number of equal inset vertical columns (draws columns − 1 inner hairlines).\n * @default 3\n */\n columns?: GridGuidesColumns\n}\n\n/**\n * Nested vertical guides inside the chrome width for denser compositions.\n * Hidden below `md` to avoid noise on narrow viewports.\n */\nexport function GridGuides({ className, columns = 3, ...props }: GridGuidesProps) {\n const chrome = useGridChrome()\n const lineStyle = chrome?.lineStyle ?? 'dashed'\n const maxWidth = chrome?.maxWidth ?? 'default'\n const innerLines = Math.max(columns - 1, 0)\n\n return (\n <div\n aria-hidden\n className={cn('pointer-events-none absolute inset-0 z-0 hidden md:block', className)}\n data-slot=\"grid-guides\"\n {...props}\n >\n <div className={cn('relative h-full', containerFrameClassName(maxWidth))}>\n {Array.from({ length: innerLines }, (_, index) => {\n const position = ((index + 1) / columns) * 100\n return (\n <span\n className={cn(\n 'absolute inset-y-0 border-s border-[color:var(--a63-grid-guide-color,var(--input,var(--a63-border-subtle)))]',\n lineStyle === 'solid' ? 'border-solid' : 'border-dashed'\n )}\n data-slot=\"grid-guide\"\n key={position}\n style={{\n borderLeftWidth: 'var(--a63-grid-hairline-width, 1px)',\n left: `${position}%`,\n }}\n />\n )\n })}\n </div>\n </div>\n )\n}\n","import type { ComponentPropsWithoutRef } from 'react'\nimport { cn } from '../../lib/cn'\nimport { containerFrameClassName, containerMaxWidthStyles } from '../max-width'\nimport { useGridChrome } from './chrome'\nimport { GridCrosshair } from './crosshair'\nimport { GRID_HAIRLINE_CENTER_PX } from './hairline'\n\nexport interface GridRuleProps extends Omit<ComponentPropsWithoutRef<'div'>, 'children'> {\n /**\n * Stretch the hairline across the full scrollport width (crosshairs still sit on the rails).\n * @default false\n */\n bleed?: boolean\n /**\n * Sparkle marks at each rail intersection. Defaults to {@link GridChrome} context, else true.\n */\n crosshairs?: boolean\n}\n\n/**\n * Horizontal section hairline. Optional sparkle crosshairs at the left/right rails.\n */\nexport function GridRule({\n bleed = false,\n className,\n crosshairs: crosshairsProp,\n style,\n ...props\n}: GridRuleProps) {\n const chrome = useGridChrome()\n const crosshairs = crosshairsProp ?? chrome?.crosshairs ?? true\n const lineStyle = chrome?.lineStyle ?? 'dashed'\n const maxWidth = chrome?.maxWidth ?? 'default'\n\n return (\n <div\n aria-hidden\n className={cn('relative w-full', className)}\n data-slot=\"grid-rule\"\n style={{ height: 'var(--a63-grid-hairline-width, 1px)', ...style }}\n {...props}\n >\n <div\n className={cn(\n 'absolute inset-x-0 top-0 border-t border-[color:var(--a63-grid-line-color,var(--input,var(--a63-border-subtle)))]',\n lineStyle === 'solid' ? 'border-solid' : 'border-dashed',\n bleed ? null : cn('mx-auto w-full', containerMaxWidthStyles[maxWidth])\n )}\n data-slot=\"grid-rule-line\"\n style={{\n borderTopWidth: 'var(--a63-grid-hairline-width, 1px)',\n }}\n />\n {crosshairs ? (\n <div\n className={cn(\n 'pointer-events-none absolute inset-x-0 inset-y-0',\n containerFrameClassName(maxWidth)\n )}\n data-slot=\"grid-rule-crosshairs\"\n >\n {/*\n Frame left/right = outer edge of the border-box rails. Sparkle center\n sits on the stroke midline: outerEdge + hairline/2.\n */}\n <GridCrosshair\n className=\"absolute z-1 -translate-x-1/2 -translate-y-1/2\"\n style={{ left: GRID_HAIRLINE_CENTER_PX, top: GRID_HAIRLINE_CENTER_PX }}\n />\n <GridCrosshair\n className=\"absolute z-1 translate-x-1/2 -translate-y-1/2\"\n style={{ right: GRID_HAIRLINE_CENTER_PX, top: GRID_HAIRLINE_CENTER_PX }}\n />\n </div>\n ) : null}\n </div>\n )\n}\n","import type { ReactNode } from 'react'\nimport { cn } from '../lib/cn'\nimport { useGridChrome } from './grid'\nimport { type ContainerMaxWidth, containerFrameClassName } from './max-width'\n\nexport type { ContainerMaxWidth }\n\nexport type ContainerPadding = 'all' | 'x' | 'none'\n\nexport type ContainerChrome = 'none' | 'grid'\n\nexport interface ContainerProps {\n children: ReactNode\n /**\n * In-flow vertical rails (`border-x`). Skipped automatically when nested under\n * {@link GridChrome} with `fixedRails` so lines don’t double up.\n * @default 'none'\n */\n chrome?: ContainerChrome\n className?: string\n maxWidth?: ContainerMaxWidth\n padding?: ContainerPadding\n}\n\nconst paddingStyles: Record<ContainerPadding, string> = {\n all: 'p-6',\n x: 'px-6',\n none: 'p-0',\n}\n\nexport function Container({\n children,\n chrome = 'none',\n maxWidth = 'default',\n padding = 'all',\n className,\n}: ContainerProps) {\n const grid = useGridChrome()\n const showGridBorder = chrome === 'grid' && !grid?.fixedRails\n\n return (\n <div\n className={cn(\n 'flex min-w-0 flex-col gap-8',\n containerFrameClassName(maxWidth),\n paddingStyles[padding],\n showGridBorder &&\n 'relative border-y-0 border-[color:var(--a63-grid-line-color,var(--a63-border-subtle))]',\n showGridBorder && (grid?.lineStyle === 'solid' ? 'border-solid' : 'border-dashed'),\n className\n )}\n data-chrome={showGridBorder ? 'grid' : undefined}\n data-slot=\"container\"\n style={\n showGridBorder\n ? {\n borderLeftWidth: 'var(--a63-grid-hairline-width, 1px)',\n borderRightWidth: 'var(--a63-grid-hairline-width, 1px)',\n }\n : undefined\n }\n >\n {children}\n </div>\n )\n}\n","import { mergeProps } from '@base-ui/react/merge-props'\nimport { useRender } from '@base-ui/react/use-render'\nimport type { ReactElement } from 'react'\nimport { cn } from '../lib/cn'\n\nexport interface PageProps extends useRender.ComponentProps<'main'> {\n noPadding?: boolean\n}\n\n/**\n * Renders `<main>` by default. Inside a shell that already owns the `main`\n * landmark, such as `SidebarInset`, pass `render={<div />}`.\n */\nexport function Page({ className, noPadding = false, render, ...props }: PageProps): ReactElement {\n const defaultProps = {\n className: cn('min-h-full', !noPadding && 'pt-8 pb-20', className),\n 'data-slot': 'page',\n }\n return useRender({\n defaultTagName: 'main',\n props: mergeProps<'main'>(defaultProps, props),\n render,\n })\n}\n","import type * as React from 'react'\nimport { cn } from '../lib/cn'\n\n/** Minimal loading placeholder (inlined — no @atom63/ui dep). */\nfunction Skeleton({ className }: { className?: string }): React.ReactElement {\n return <div className={cn('animate-pulse rounded-md bg-muted', className)} />\n}\n\nexport const DEFAULT_PAGE_SKELETON_COUNT = 6\n\nexport interface PageSkeletonProps {\n className?: string\n count?: number\n showFilters?: boolean\n showHeader?: boolean\n variant?: 'list' | 'card' | 'grid'\n}\n\nexport function PageSkeleton({\n variant = 'list',\n count = DEFAULT_PAGE_SKELETON_COUNT,\n className,\n showFilters = true,\n showHeader = true,\n}: PageSkeletonProps) {\n const skeletonItems = Array.from({ length: count }, (_, index) => ({\n id: `${variant}-${index + 1}`,\n }))\n\n const renderSkeletonItem = (id: string) => {\n switch (variant) {\n case 'card':\n return (\n <div className=\"space-y-3\" key={`skeleton-card-${id}`}>\n <Skeleton className=\"h-48 w-full rounded-sm\" />\n <div className=\"space-y-2\">\n <Skeleton className=\"h-5 w-3/4 rounded\" />\n <Skeleton className=\"h-4 w-full rounded\" />\n <Skeleton className=\"h-4 w-2/3 rounded\" />\n <div className=\"flex gap-2\">\n <Skeleton className=\"h-6 w-16 rounded\" />\n <Skeleton className=\"h-6 w-20 rounded\" />\n </div>\n </div>\n </div>\n )\n\n case 'grid':\n return (\n <div className=\"space-y-3\" key={`skeleton-grid-${id}`}>\n <Skeleton className=\"aspect-square w-full rounded-sm\" />\n <div className=\"space-y-2\">\n <Skeleton className=\"h-4 w-3/4 rounded\" />\n <Skeleton className=\"h-3 w-1/2 rounded\" />\n </div>\n </div>\n )\n\n default:\n return (\n <div className=\"flex items-center gap-4\" key={`skeleton-list-${id}`}>\n <Skeleton className=\"h-12 w-12 rounded-sm\" />\n <div className=\"flex-1 space-y-3\">\n <Skeleton className=\"h-4 w-full rounded\" />\n <Skeleton className=\"h-4 w-3/4 rounded\" />\n </div>\n </div>\n )\n }\n }\n\n return (\n <div aria-busy=\"true\" className={className} data-slot=\"page-skeleton\">\n {showHeader && (\n <div className=\"mb-8 space-y-4\">\n <Skeleton className=\"h-8 w-48\" />\n <Skeleton className=\"h-5 w-96\" />\n </div>\n )}\n\n {showFilters && (\n <div className=\"mb-8 space-y-4\">\n <div className=\"flex flex-wrap gap-2\">\n <Skeleton className=\"h-9 w-16\" />\n <Skeleton className=\"h-9 w-32\" />\n <Skeleton className=\"h-9 w-48\" />\n <Skeleton className=\"h-9 w-24\" />\n </div>\n <div className=\"flex items-center gap-4\">\n <Skeleton className=\"h-10 w-64\" />\n <Skeleton className=\"h-10 w-32\" />\n </div>\n </div>\n )}\n\n <div\n className={\n variant === 'grid' ? 'grid grid-cols-1 gap-6 sm:grid-cols-2 lg:grid-cols-3' : 'space-y-6'\n }\n >\n {skeletonItems.map(item => renderSkeletonItem(item.id))}\n </div>\n </div>\n )\n}\n","import type { ReactNode } from 'react'\nimport { cn } from '../lib/cn'\n\nexport interface SectionProps {\n children: ReactNode\n className?: string\n gap?: boolean\n id?: string\n removeTopSpacing?: boolean\n spacing?: 'tight' | 'default' | 'loose' | 'generous' | 'spacious'\n}\n\nexport function Section({\n children,\n className,\n id,\n spacing = 'default',\n removeTopSpacing = true,\n gap = true,\n}: SectionProps) {\n const paddingClasses = {\n tight: 'py-8',\n default: 'py-16',\n loose: 'py-16 md:py-20',\n generous: 'py-20 sm:py-28 md:py-32',\n spacious: 'py-24 sm:py-32 md:py-40',\n }\n\n const gapClasses = {\n tight: 'space-y-4',\n default: 'space-y-6',\n loose: 'space-y-8',\n generous: 'space-y-6',\n spacious: 'space-y-8',\n }\n\n return (\n <section\n className={cn(\n paddingClasses[spacing],\n gap && gapClasses[spacing],\n removeTopSpacing && 'pt-0 md:pt-0',\n className\n )}\n data-slot=\"section\"\n id={id}\n >\n {children}\n </section>\n )\n}\n","import { cn } from '../lib/cn'\n\n/** Typography for index-style page heroes (projects, resources, …). */\nexport const pageIndexHeroTitleClassName =\n 'text-balance font-secondary text-4xl tracking-tight md:text-6xl'\n\nexport const pageIndexHeroDescriptionClassName = 'text-lg'\n\nexport type SectionHeaderLevel = 1 | 2 | 3 | 4 | 5 | 6\nexport type SectionHeaderVariant =\n 'display' | 'primary' | 'secondary' | 'muted' | 'subtle' | 'label'\n\nexport interface SectionHeaderProps {\n align?: 'left' | 'center' | 'right'\n className?: string\n description?: string\n descriptionClassName?: string\n /**\n * Semantic heading level for the title. Visual scale is still controlled by\n * `variant`; use this when the surrounding page hierarchy needs a different\n * heading level than the variant default.\n */\n level?: SectionHeaderLevel\n title: string\n titleClassName?: string\n variant?: SectionHeaderVariant\n}\n\nconst headingTags: Record<SectionHeaderLevel, 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6'> = {\n 1: 'h1',\n 2: 'h2',\n 3: 'h3',\n 4: 'h4',\n 5: 'h5',\n 6: 'h6',\n} as const\n\ntype SectionHeaderVariantConfig = {\n DescTag: 'p'\n defaultLevel?: SectionHeaderLevel\n descClass: string\n titleClass: string\n}\n\nexport function SectionHeader({\n title,\n description,\n className,\n titleClassName,\n descriptionClassName,\n level,\n variant = 'primary',\n align = 'left',\n}: SectionHeaderProps) {\n const variantConfig = {\n display: {\n DescTag: 'p' as const,\n titleClass:\n 'max-w-3xl text-balance font-heading font-semibold text-5xl leading-none md:text-6xl',\n descClass:\n 'mt-4 max-w-2xl text-balance text-lg text-muted-foreground leading-relaxed md:text-xl',\n defaultLevel: 1,\n },\n primary: {\n DescTag: 'p' as const,\n titleClass: 'max-w-2xl text-balance font-heading font-semibold text-3xl leading-tight',\n descClass: 'mt-2 max-w-2xl text-balance text-muted-foreground text-base leading-7',\n defaultLevel: 1,\n },\n secondary: {\n DescTag: 'p' as const,\n titleClass: 'max-w-2xl text-balance font-heading font-semibold text-2xl leading-tight',\n descClass: 'mt-2 max-w-xl text-balance text-muted-foreground text-sm leading-6',\n defaultLevel: 2,\n },\n muted: {\n DescTag: 'p' as const,\n titleClass: 'max-w-xl text-balance font-heading font-medium text-lg leading-snug',\n descClass: 'mt-1.5 max-w-lg text-balance text-muted-foreground text-sm leading-6',\n defaultLevel: 3,\n },\n subtle: {\n DescTag: 'p' as const,\n titleClass: 'max-w-lg text-balance font-medium text-base leading-snug text-foreground',\n descClass: 'mt-1 max-w-md text-balance text-muted-foreground text-sm leading-5',\n defaultLevel: 4,\n },\n label: {\n DescTag: 'p' as const,\n titleClass: 'font-medium text-muted-foreground text-xs uppercase tracking-[0.16em]',\n descClass: 'mt-1 max-w-md text-balance text-muted-foreground text-sm leading-5',\n defaultLevel: undefined,\n },\n } satisfies Record<SectionHeaderVariant, SectionHeaderVariantConfig>\n\n const { DescTag, titleClass, descClass, defaultLevel } = variantConfig[variant]\n const titleLevel = level ?? defaultLevel\n const TitleTag = titleLevel ? headingTags[titleLevel] : 'p'\n\n const alignClasses = {\n center: 'mx-auto text-center',\n right: 'ms-auto text-end',\n left: '',\n }\n\n return (\n <div\n className={cn(\n align === 'center' && 'text-center',\n align === 'right' && 'text-end',\n className\n )}\n >\n <TitleTag className={cn(titleClass, alignClasses[align], titleClassName)}>{title}</TitleTag>\n {description && (\n <DescTag className={cn(descClass, alignClasses[align], descriptionClassName)}>\n {description}\n </DescTag>\n )}\n </div>\n )\n}\n","import type { ReactNode } from 'react'\nimport { cn } from '../lib/cn'\n\nexport interface ReaderLayoutProps {\n aside?: ReactNode\n asideClassName?: string\n children: ReactNode\n className?: string\n contentClassName?: string\n /** Keep the aside column even with no aside, so the content measure holds across pages. */\n reserveAside?: boolean\n}\n\nexport function ReaderLayout({\n aside,\n asideClassName,\n children,\n className,\n contentClassName,\n reserveAside = false,\n}: ReaderLayoutProps) {\n return (\n <div className={cn('mx-auto flex w-full max-w-5xl', className)} data-slot=\"reader-layout\">\n <article\n className={cn(\n 'min-w-0 flex-1 space-y-8 px-4 pt-8 pb-8 sm:px-6 lg:px-8 xl:max-w-4xl',\n contentClassName\n )}\n data-slot=\"reader-layout-content\"\n >\n {children}\n </article>\n {aside || reserveAside ? (\n <div\n aria-hidden={aside ? undefined : true}\n className={cn('hidden w-64 shrink-0 px-4 pt-8 xl:block', asideClassName)}\n data-slot=\"reader-layout-aside\"\n >\n {aside}\n </div>\n ) : null}\n </div>\n )\n}\n"]}
|
|
1
|
+
{"version":3,"sources":["../../src/layout/max-width.ts","../../src/layout/grid/hairline.ts","../../src/layout/grid/style.ts","../../src/layout/grid/chrome.tsx","../../src/layout/grid/crosshair.tsx","../../src/layout/grid/guides.tsx","../../src/layout/grid/rule.tsx","../../src/layout/container.tsx","../../src/layout/page.tsx","../../src/layout/page-skeleton.tsx","../../src/layout/section.tsx","../../src/layout/section-header.tsx","../../src/components/app-view/app-view.tsx","../../src/layout/reader-layout.tsx"],"names":["jsx","jsxs"],"mappings":";;;;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erMaxWidth =\n 'fluid' | 'widest' | 'wider' | 'wide' | 'default' | 'narrow' | 'narrower' | 'narrowest'\n\n/** Shared max-width class map for Container and GridChrome. */\nexport const containerMaxWidthStyles: Record<ContainerMaxWidth, string> = {\n fluid: 'max-w-full',\n widest: 'max-w-8xl',\n wider: 'max-w-7xl',\n wide: 'max-w-6xl',\n default: 'max-w-5xl',\n narrow: 'max-w-4xl',\n narrower: 'max-w-2xl',\n narrowest: 'max-w-xl',\n}\n\n/**\n * Centered max-width frame (no Tailwind `container` padding).\n * Used for fixed rails / guides so edges align with content chrome.\n */\nexport function containerFrameClassName(maxWidth: ContainerMaxWidth = 'default'): string {\n return `mx-auto w-full min-w-0 ${containerMaxWidthStyles[maxWidth]}`\n}\n","/**\n * Shared hairline metrics for grid chrome rails / rules / sparkles.\n * Must stay in sync with Tailwind `border` (1px) on rail + rule strokes.\n */\nexport const GRID_HAIRLINE_PX = 1\n\n/** Distance from the frame’s outer edge to the stroke’s optical center. */\nexport const GRID_HAIRLINE_CENTER_PX = GRID_HAIRLINE_PX / 2\n","import type { CSSProperties } from 'react'\nimport { GRID_HAIRLINE_PX } from './hairline'\n\nexport const GRID_CHROME_VARS = {\n lineColor: '--a63-grid-line-color',\n guideColor: '--a63-grid-guide-color',\n crosshairColor: '--a63-grid-crosshair-color',\n hairlineWidth: '--a63-grid-hairline-width',\n lineStyle: '--a63-grid-line-style',\n} as const\n\nexport type GridChromeLineStyle = 'solid' | 'dashed'\nexport type GridChromeTone = 'subtle' | 'default' | 'strong'\n\nexport type GridChromeCssVars = Partial<\n Record<(typeof GRID_CHROME_VARS)[keyof typeof GRID_CHROME_VARS], string>\n>\n\nexport type GridChromeStyle = CSSProperties & GridChromeCssVars\n\nconst GRID_CHROME_TONE_STYLES = {\n subtle: {\n [GRID_CHROME_VARS.lineColor]: 'color-mix(in oklch, var(--a63-border-subtle) 34%, transparent)',\n [GRID_CHROME_VARS.guideColor]: 'color-mix(in oklch, var(--a63-border-subtle) 16%, transparent)',\n [GRID_CHROME_VARS.crosshairColor]:\n 'color-mix(in oklch, var(--a63-border-subtle) 42%, transparent)',\n },\n default: {\n [GRID_CHROME_VARS.lineColor]: 'color-mix(in oklch, var(--a63-border-subtle) 50%, transparent)',\n [GRID_CHROME_VARS.guideColor]: 'color-mix(in oklch, var(--a63-border-subtle) 24%, transparent)',\n [GRID_CHROME_VARS.crosshairColor]:\n 'color-mix(in oklch, var(--a63-border-subtle) 58%, transparent)',\n },\n strong: {\n [GRID_CHROME_VARS.lineColor]: 'var(--a63-border-control)',\n [GRID_CHROME_VARS.guideColor]: 'var(--a63-border-subtle)',\n [GRID_CHROME_VARS.crosshairColor]: 'var(--a63-border-control)',\n },\n} as const satisfies Record<GridChromeTone, GridChromeCssVars>\n\nexport function gridChromeStyle({\n lineStyle,\n style,\n tone,\n}: {\n lineStyle: GridChromeLineStyle\n style?: GridChromeStyle\n tone: GridChromeTone\n}): GridChromeStyle {\n return {\n [GRID_CHROME_VARS.hairlineWidth]: `${GRID_HAIRLINE_PX}px`,\n [GRID_CHROME_VARS.lineStyle]: lineStyle,\n ...GRID_CHROME_TONE_STYLES[tone],\n ...style,\n }\n}\n","import { type ComponentPropsWithoutRef, createContext, type ReactNode, useContext } from 'react'\nimport { cn } from '../../lib/cn'\nimport { containerFrameClassName, type ContainerMaxWidth } from '../max-width'\nimport {\n gridChromeStyle,\n type GridChromeLineStyle,\n type GridChromeStyle,\n type GridChromeTone,\n} from './style'\n\nexport interface GridChromeContextValue {\n crosshairs: boolean\n /** True when page rails are painted by {@link GridChrome}. */\n fixedRails: boolean\n lineStyle: GridChromeLineStyle\n maxWidth: ContainerMaxWidth\n}\n\nconst GridChromeContext = createContext<GridChromeContextValue | null>(null)\n\nexport function useGridChrome(): GridChromeContextValue | null {\n return useContext(GridChromeContext)\n}\n\nexport interface GridChromeProps extends Omit<ComponentPropsWithoutRef<'div'>, 'children'> {\n children: ReactNode\n /**\n * Default sparkle crosshairs on nested `GridRule`s.\n * @default true\n */\n crosshairs?: boolean\n /**\n * Full-height vertical rails matching `maxWidth`. Absolute inside the chrome\n * (not `position: fixed` / sticky-on-self) so `max-w-*` + `mx-auto` keep working\n * and edges stay symmetric with the scroll container.\n * @default true\n */\n fixedRails?: boolean\n /**\n * Stroke style shared by rails, rules, and guides.\n * @default 'dashed'\n */\n lineStyle?: GridChromeLineStyle\n maxWidth?: ContainerMaxWidth\n /**\n * Central color preset for rails, rules, guides, and crosshairs.\n * Override individual values with CSS variables on `style`.\n * @default 'default'\n */\n tone?: GridChromeTone\n style?: GridChromeStyle\n}\n\n/**\n * Firecrawl-style page frame: continuous column rails + crosshair context.\n *\n * Wrap the **entire scroll document** (header, main, footer) so one pair of\n * rails meets every band. Nesting `GridChrome` only around a page body leaves\n * the footer as a floating card — the opposite of Firecrawl’s T-junctions.\n */\nexport function GridChrome({\n children,\n className,\n crosshairs = true,\n fixedRails = true,\n lineStyle = 'dashed',\n maxWidth = 'default',\n style,\n tone = 'default',\n ...props\n}: GridChromeProps) {\n return (\n <GridChromeContext.Provider value={{ crosshairs, fixedRails, lineStyle, maxWidth }}>\n <div\n className={cn('relative isolate flex min-h-svh flex-col', className)}\n data-slot=\"grid-chrome\"\n style={gridChromeStyle({ lineStyle, style, tone })}\n {...props}\n >\n {fixedRails ? (\n <div\n aria-hidden\n className=\"pointer-events-none absolute inset-0 z-[60]\"\n data-slot=\"grid-chrome-rails-root\"\n >\n {/*\n z-60 sits above sticky header (z-50) so backdrop-blur never frosts\n the hairlines. Width is constrained here (not sticky-on-self) so\n max-w + mx-auto stay aligned with the scrollport.\n */}\n <div\n className={cn(\n 'h-full min-h-svh border-y-0 border-[color:var(--a63-grid-line-color)]',\n lineStyle === 'solid' ? 'border-solid' : 'border-dashed',\n containerFrameClassName(maxWidth)\n )}\n data-slot=\"grid-chrome-rails\"\n style={{\n borderLeftWidth: 'var(--a63-grid-hairline-width)',\n borderRightWidth: 'var(--a63-grid-hairline-width)',\n }}\n />\n </div>\n ) : null}\n <div className=\"relative z-1 flex min-h-svh flex-1 flex-col\">{children}</div>\n </div>\n </GridChromeContext.Provider>\n )\n}\n","import type { ComponentPropsWithoutRef } from 'react'\nimport { cn } from '../../lib/cn'\n\n/**\n * Four-point sparkle at a rail / crossbar junction (Firecrawl-style).\n * Decorative — parent should set `aria-hidden`.\n */\nexport function GridCrosshair({\n className,\n ...props\n}: Omit<ComponentPropsWithoutRef<'svg'>, 'children' | 'viewBox'>) {\n return (\n <svg\n className={cn(\n 'size-3 text-[color:var(--a63-grid-crosshair-color,var(--input,var(--a63-border-subtle)))]',\n className\n )}\n fill=\"currentColor\"\n overflow=\"visible\"\n viewBox=\"0 0 24 24\"\n xmlns=\"http://www.w3.org/2000/svg\"\n {...props}\n >\n {/*\n Classic 4-point sparkle (concave sides, tips on the axes). Larger\n viewBox + softer control points so it reads as a star, not a plus.\n */}\n <path d=\"M12 0C12.8 7.2 7.2 12.8 0 12C7.2 12.8 12.8 16.8 12 24C11.2 16.8 16.8 12.8 24 12C16.8 11.2 12.8 7.2 12 0Z\" />\n </svg>\n )\n}\n","import type { ComponentPropsWithoutRef } from 'react'\nimport { cn } from '../../lib/cn'\nimport { containerFrameClassName } from '../max-width'\nimport { useGridChrome } from './chrome'\n\nexport type GridGuidesColumns = 2 | 3 | 4\n\nexport interface GridGuidesProps extends Omit<ComponentPropsWithoutRef<'div'>, 'children'> {\n /**\n * Number of equal inset vertical columns (draws columns − 1 inner hairlines).\n * @default 3\n */\n columns?: GridGuidesColumns\n}\n\n/**\n * Nested vertical guides inside the chrome width for denser compositions.\n * Hidden below `md` to avoid noise on narrow viewports.\n */\nexport function GridGuides({ className, columns = 3, ...props }: GridGuidesProps) {\n const chrome = useGridChrome()\n const lineStyle = chrome?.lineStyle ?? 'dashed'\n const maxWidth = chrome?.maxWidth ?? 'default'\n const innerLines = Math.max(columns - 1, 0)\n\n return (\n <div\n aria-hidden\n className={cn('pointer-events-none absolute inset-0 z-0 hidden md:block', className)}\n data-slot=\"grid-guides\"\n {...props}\n >\n <div className={cn('relative h-full', containerFrameClassName(maxWidth))}>\n {Array.from({ length: innerLines }, (_, index) => {\n const position = ((index + 1) / columns) * 100\n return (\n <span\n className={cn(\n 'absolute inset-y-0 border-s border-[color:var(--a63-grid-guide-color,var(--input,var(--a63-border-subtle)))]',\n lineStyle === 'solid' ? 'border-solid' : 'border-dashed'\n )}\n data-slot=\"grid-guide\"\n key={position}\n style={{\n borderLeftWidth: 'var(--a63-grid-hairline-width, 1px)',\n left: `${position}%`,\n }}\n />\n )\n })}\n </div>\n </div>\n )\n}\n","import type { ComponentPropsWithoutRef } from 'react'\nimport { cn } from '../../lib/cn'\nimport { containerFrameClassName, containerMaxWidthStyles } from '../max-width'\nimport { useGridChrome } from './chrome'\nimport { GridCrosshair } from './crosshair'\nimport { GRID_HAIRLINE_CENTER_PX } from './hairline'\n\nexport interface GridRuleProps extends Omit<ComponentPropsWithoutRef<'div'>, 'children'> {\n /**\n * Stretch the hairline across the full scrollport width (crosshairs still sit on the rails).\n * @default false\n */\n bleed?: boolean\n /**\n * Sparkle marks at each rail intersection. Defaults to {@link GridChrome} context, else true.\n */\n crosshairs?: boolean\n}\n\n/**\n * Horizontal section hairline. Optional sparkle crosshairs at the left/right rails.\n */\nexport function GridRule({\n bleed = false,\n className,\n crosshairs: crosshairsProp,\n style,\n ...props\n}: GridRuleProps) {\n const chrome = useGridChrome()\n const crosshairs = crosshairsProp ?? chrome?.crosshairs ?? true\n const lineStyle = chrome?.lineStyle ?? 'dashed'\n const maxWidth = chrome?.maxWidth ?? 'default'\n\n return (\n <div\n aria-hidden\n className={cn('relative w-full', className)}\n data-slot=\"grid-rule\"\n style={{ height: 'var(--a63-grid-hairline-width, 1px)', ...style }}\n {...props}\n >\n <div\n className={cn(\n 'absolute inset-x-0 top-0 border-t border-[color:var(--a63-grid-line-color,var(--input,var(--a63-border-subtle)))]',\n lineStyle === 'solid' ? 'border-solid' : 'border-dashed',\n bleed ? null : cn('mx-auto w-full', containerMaxWidthStyles[maxWidth])\n )}\n data-slot=\"grid-rule-line\"\n style={{\n borderTopWidth: 'var(--a63-grid-hairline-width, 1px)',\n }}\n />\n {crosshairs ? (\n <div\n className={cn(\n 'pointer-events-none absolute inset-x-0 inset-y-0',\n containerFrameClassName(maxWidth)\n )}\n data-slot=\"grid-rule-crosshairs\"\n >\n {/*\n Frame left/right = outer edge of the border-box rails. Sparkle center\n sits on the stroke midline: outerEdge + hairline/2.\n */}\n <GridCrosshair\n className=\"absolute z-1 -translate-x-1/2 -translate-y-1/2\"\n style={{ left: GRID_HAIRLINE_CENTER_PX, top: GRID_HAIRLINE_CENTER_PX }}\n />\n <GridCrosshair\n className=\"absolute z-1 translate-x-1/2 -translate-y-1/2\"\n style={{ right: GRID_HAIRLINE_CENTER_PX, top: GRID_HAIRLINE_CENTER_PX }}\n />\n </div>\n ) : null}\n </div>\n )\n}\n","import type { ReactNode } from 'react'\nimport { cn } from '../lib/cn'\nimport { useGridChrome } from './grid'\nimport { type ContainerMaxWidth, containerFrameClassName } from './max-width'\n\nexport type { ContainerMaxWidth }\n\nexport type ContainerPadding = 'all' | 'x' | 'none'\n\nexport type ContainerChrome = 'none' | 'grid'\n\nexport interface ContainerProps {\n children: ReactNode\n /**\n * In-flow vertical rails (`border-x`). Skipped automatically when nested under\n * {@link GridChrome} with `fixedRails` so lines don’t double up.\n * @default 'none'\n */\n chrome?: ContainerChrome\n className?: string\n maxWidth?: ContainerMaxWidth\n padding?: ContainerPadding\n}\n\nconst paddingStyles: Record<ContainerPadding, string> = {\n all: 'p-6',\n x: 'px-6',\n none: 'p-0',\n}\n\nexport function Container({\n children,\n chrome = 'none',\n maxWidth = 'default',\n padding = 'all',\n className,\n}: ContainerProps) {\n const grid = useGridChrome()\n const showGridBorder = chrome === 'grid' && !grid?.fixedRails\n\n return (\n <div\n className={cn(\n 'flex min-w-0 flex-col gap-8',\n containerFrameClassName(maxWidth),\n paddingStyles[padding],\n showGridBorder &&\n 'relative border-y-0 border-[color:var(--a63-grid-line-color,var(--a63-border-subtle))]',\n showGridBorder && (grid?.lineStyle === 'solid' ? 'border-solid' : 'border-dashed'),\n className\n )}\n data-chrome={showGridBorder ? 'grid' : undefined}\n data-slot=\"container\"\n style={\n showGridBorder\n ? {\n borderLeftWidth: 'var(--a63-grid-hairline-width, 1px)',\n borderRightWidth: 'var(--a63-grid-hairline-width, 1px)',\n }\n : undefined\n }\n >\n {children}\n </div>\n )\n}\n","import { mergeProps } from '@base-ui/react/merge-props'\nimport { useRender } from '@base-ui/react/use-render'\nimport type { ReactElement } from 'react'\nimport { cn } from '../lib/cn'\n\nexport interface PageProps extends useRender.ComponentProps<'main'> {\n noPadding?: boolean\n}\n\n/**\n * Renders `<main>` by default. Inside a shell that already owns the `main`\n * landmark, such as `SidebarInset`, pass `render={<div />}`.\n */\nexport function Page({ className, noPadding = false, render, ...props }: PageProps): ReactElement {\n const defaultProps = {\n className: cn('min-h-full', !noPadding && 'pt-8 pb-20', className),\n 'data-slot': 'page',\n }\n return useRender({\n defaultTagName: 'main',\n props: mergeProps<'main'>(defaultProps, props),\n render,\n })\n}\n","import type * as React from 'react'\nimport { cn } from '../lib/cn'\n\n/** Minimal loading placeholder (inlined — no @atom63/ui dep). */\nfunction Skeleton({ className }: { className?: string }): React.ReactElement {\n return <div className={cn('animate-pulse rounded-md bg-muted', className)} />\n}\n\nexport const DEFAULT_PAGE_SKELETON_COUNT = 6\n\nexport interface PageSkeletonProps {\n className?: string\n count?: number\n showFilters?: boolean\n showHeader?: boolean\n variant?: 'list' | 'card' | 'grid'\n}\n\nexport function PageSkeleton({\n variant = 'list',\n count = DEFAULT_PAGE_SKELETON_COUNT,\n className,\n showFilters = true,\n showHeader = true,\n}: PageSkeletonProps) {\n const skeletonItems = Array.from({ length: count }, (_, index) => ({\n id: `${variant}-${index + 1}`,\n }))\n\n const renderSkeletonItem = (id: string) => {\n switch (variant) {\n case 'card':\n return (\n <div className=\"space-y-3\" key={`skeleton-card-${id}`}>\n <Skeleton className=\"h-48 w-full rounded-sm\" />\n <div className=\"space-y-2\">\n <Skeleton className=\"h-5 w-3/4 rounded\" />\n <Skeleton className=\"h-4 w-full rounded\" />\n <Skeleton className=\"h-4 w-2/3 rounded\" />\n <div className=\"flex gap-2\">\n <Skeleton className=\"h-6 w-16 rounded\" />\n <Skeleton className=\"h-6 w-20 rounded\" />\n </div>\n </div>\n </div>\n )\n\n case 'grid':\n return (\n <div className=\"space-y-3\" key={`skeleton-grid-${id}`}>\n <Skeleton className=\"aspect-square w-full rounded-sm\" />\n <div className=\"space-y-2\">\n <Skeleton className=\"h-4 w-3/4 rounded\" />\n <Skeleton className=\"h-3 w-1/2 rounded\" />\n </div>\n </div>\n )\n\n default:\n return (\n <div className=\"flex items-center gap-4\" key={`skeleton-list-${id}`}>\n <Skeleton className=\"h-12 w-12 rounded-sm\" />\n <div className=\"flex-1 space-y-3\">\n <Skeleton className=\"h-4 w-full rounded\" />\n <Skeleton className=\"h-4 w-3/4 rounded\" />\n </div>\n </div>\n )\n }\n }\n\n return (\n <div aria-busy=\"true\" className={className} data-slot=\"page-skeleton\">\n {showHeader && (\n <div className=\"mb-8 space-y-4\">\n <Skeleton className=\"h-8 w-48\" />\n <Skeleton className=\"h-5 w-96\" />\n </div>\n )}\n\n {showFilters && (\n <div className=\"mb-8 space-y-4\">\n <div className=\"flex flex-wrap gap-2\">\n <Skeleton className=\"h-9 w-16\" />\n <Skeleton className=\"h-9 w-32\" />\n <Skeleton className=\"h-9 w-48\" />\n <Skeleton className=\"h-9 w-24\" />\n </div>\n <div className=\"flex items-center gap-4\">\n <Skeleton className=\"h-10 w-64\" />\n <Skeleton className=\"h-10 w-32\" />\n </div>\n </div>\n )}\n\n <div\n className={\n variant === 'grid' ? 'grid grid-cols-1 gap-6 sm:grid-cols-2 lg:grid-cols-3' : 'space-y-6'\n }\n >\n {skeletonItems.map(item => renderSkeletonItem(item.id))}\n </div>\n </div>\n )\n}\n","import type { ReactNode } from 'react'\nimport { cn } from '../lib/cn'\n\nexport interface SectionProps {\n children: ReactNode\n className?: string\n gap?: boolean\n id?: string\n removeTopSpacing?: boolean\n spacing?: 'tight' | 'default' | 'loose' | 'generous' | 'spacious'\n}\n\nexport function Section({\n children,\n className,\n id,\n spacing = 'default',\n removeTopSpacing = true,\n gap = true,\n}: SectionProps) {\n const paddingClasses = {\n tight: 'py-8',\n default: 'py-16',\n loose: 'py-16 md:py-20',\n generous: 'py-20 sm:py-28 md:py-32',\n spacious: 'py-24 sm:py-32 md:py-40',\n }\n\n const gapClasses = {\n tight: 'space-y-4',\n default: 'space-y-6',\n loose: 'space-y-8',\n generous: 'space-y-6',\n spacious: 'space-y-8',\n }\n\n return (\n <section\n className={cn(\n paddingClasses[spacing],\n gap && gapClasses[spacing],\n removeTopSpacing && 'pt-0 md:pt-0',\n className\n )}\n data-slot=\"section\"\n id={id}\n >\n {children}\n </section>\n )\n}\n","import { cn } from '../lib/cn'\n\n/** Typography for index-style page heroes (projects, resources, …). */\nexport const pageIndexHeroTitleClassName =\n 'text-balance font-secondary text-4xl tracking-tight md:text-6xl'\n\nexport const pageIndexHeroDescriptionClassName = 'text-lg'\n\nexport type SectionHeaderLevel = 1 | 2 | 3 | 4 | 5 | 6\nexport type SectionHeaderVariant =\n 'display' | 'primary' | 'secondary' | 'muted' | 'subtle' | 'label'\n\nexport interface SectionHeaderProps {\n align?: 'left' | 'center' | 'right'\n className?: string\n description?: string\n descriptionClassName?: string\n /**\n * Semantic heading level for the title. Visual scale is still controlled by\n * `variant`; use this when the surrounding page hierarchy needs a different\n * heading level than the variant default.\n */\n level?: SectionHeaderLevel\n title: string\n titleClassName?: string\n variant?: SectionHeaderVariant\n}\n\nconst headingTags: Record<SectionHeaderLevel, 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6'> = {\n 1: 'h1',\n 2: 'h2',\n 3: 'h3',\n 4: 'h4',\n 5: 'h5',\n 6: 'h6',\n} as const\n\ntype SectionHeaderVariantConfig = {\n DescTag: 'p'\n defaultLevel?: SectionHeaderLevel\n descClass: string\n titleClass: string\n}\n\nexport function SectionHeader({\n title,\n description,\n className,\n titleClassName,\n descriptionClassName,\n level,\n variant = 'primary',\n align = 'left',\n}: SectionHeaderProps) {\n const variantConfig = {\n display: {\n DescTag: 'p' as const,\n titleClass:\n 'max-w-3xl text-balance font-heading font-semibold text-5xl leading-none md:text-6xl',\n descClass:\n 'mt-4 max-w-2xl text-balance text-lg text-muted-foreground leading-relaxed md:text-xl',\n defaultLevel: 1,\n },\n primary: {\n DescTag: 'p' as const,\n titleClass: 'max-w-2xl text-balance font-heading font-semibold text-3xl leading-tight',\n descClass: 'mt-2 max-w-2xl text-balance text-muted-foreground text-base leading-7',\n defaultLevel: 1,\n },\n secondary: {\n DescTag: 'p' as const,\n titleClass: 'max-w-2xl text-balance font-heading font-semibold text-2xl leading-tight',\n descClass: 'mt-2 max-w-xl text-balance text-muted-foreground text-sm leading-6',\n defaultLevel: 2,\n },\n muted: {\n DescTag: 'p' as const,\n titleClass: 'max-w-xl text-balance font-heading font-medium text-lg leading-snug',\n descClass: 'mt-1.5 max-w-lg text-balance text-muted-foreground text-sm leading-6',\n defaultLevel: 3,\n },\n subtle: {\n DescTag: 'p' as const,\n titleClass: 'max-w-lg text-balance font-medium text-base leading-snug text-foreground',\n descClass: 'mt-1 max-w-md text-balance text-muted-foreground text-sm leading-5',\n defaultLevel: 4,\n },\n label: {\n DescTag: 'p' as const,\n titleClass: 'font-medium text-muted-foreground text-xs uppercase tracking-[0.16em]',\n descClass: 'mt-1 max-w-md text-balance text-muted-foreground text-sm leading-5',\n defaultLevel: undefined,\n },\n } satisfies Record<SectionHeaderVariant, SectionHeaderVariantConfig>\n\n const { DescTag, titleClass, descClass, defaultLevel } = variantConfig[variant]\n const titleLevel = level ?? defaultLevel\n const TitleTag = titleLevel ? headingTags[titleLevel] : 'p'\n\n const alignClasses = {\n center: 'mx-auto text-center',\n right: 'ms-auto text-end',\n left: '',\n }\n\n return (\n <div\n className={cn(\n align === 'center' && 'text-center',\n align === 'right' && 'text-end',\n className\n )}\n >\n <TitleTag className={cn(titleClass, alignClasses[align], titleClassName)}>{title}</TitleTag>\n {description && (\n <DescTag className={cn(descClass, alignClasses[align], descriptionClassName)}>\n {description}\n </DescTag>\n )}\n </div>\n )\n}\n","import {\n type AppViewChrome,\n type AppViewLayout,\n type AppViewTopBarSpan,\n appViewContract,\n} from '@atom63/ui-foundation'\nimport type * as React from 'react'\n\nimport { cn } from '../../lib/cn'\n\nexport type AppViewProps = Omit<React.ComponentProps<'div'>, 'children'> & {\n /** The main region; it is the only part that scrolls. */\n children: React.ReactNode\n /**\n * `window` (the default): a desktop window, the side panel from `md` up and\n * the tab bar on narrow screens only. `phone`: a phone app screen, edge to\n * edge, with no side panel and the tab bar always shown. It stamps\n * `data-a63-form-factor=\"phone\"`, which sets phone-sized type and controls\n * (body 17px, 44px controls) for everything inside.\n */\n layout?: AppViewLayout\n /**\n * How a `window` is drawn. `inset` (the default): a padded window with the\n * side panel and the main region on rounded cards. `flush`: columns to the\n * window edges, split by borders. `phone` is always flush.\n */\n chrome?: AppViewChrome\n /** The bar across the top. It takes the top safe-area inset. */\n topBar?: React.ReactNode\n /**\n * Where the top bar runs in a `window`. `window` (the default): across the\n * whole window. `main`: over the main region and the aside only, so the rail\n * and the panel run the full height of the window.\n */\n topBarSpan?: AppViewTopBarSpan\n /** A narrow column before the side panel, such as an icon rail; from `md` up, windows only. */\n rail?: React.ReactNode\n /** The accessible name of the rail. */\n railLabel?: string\n /**\n * The rail's width as a CSS length (4rem by default). It sets\n * `--a63-app-view-rail-width`, which a stylesheet can set too.\n */\n railWidth?: string\n /** A side panel beside the main region, hidden on phones. */\n panel?: React.ReactNode\n /** The accessible name of the side panel. */\n panelLabel?: string\n /**\n * The side panel's width as a CSS length, such as `'12.5rem'` (18rem by\n * default). It sets `--a63-app-view-panel-width`, which a stylesheet can set too.\n */\n panelWidth?: string\n /**\n * Content floating over the main region, anchored to its bottom end and\n * above the docked bar, such as a scroll-to-bottom button. It does not scroll.\n */\n overlay?: React.ReactNode\n /**\n * A column after the main region, such as a thread or a details pane; from\n * `lg` up, windows only. Below `lg` it is not shown, so show its content\n * another way there, such as in a Sheet.\n */\n aside?: React.ReactNode\n /** The accessible name of the aside. */\n asideLabel?: string\n /**\n * The aside's width as a CSS length (22rem by default). It sets\n * `--a63-app-view-aside-width`, which a stylesheet can set too.\n */\n asideWidth?: string\n /** A bar docked at the bottom, such as a player, a status bar or an action bar. */\n bottomBar?: React.ReactNode\n /** The accessible name of the docked bar's region. */\n bottomBarLabel?: string\n /** Bottom navigation, such as the tab-bar block. It takes the bottom safe-area inset. */\n tabBar?: React.ReactNode\n}\n\n/*\n * The frame of a full-window product view. Only the main region scrolls, and\n * each safe-area inset has one owner: the top bar takes the top one (with no\n * top bar, the main region's first block pads itself, so a hero can run under\n * the status bar); the tab bar takes the bottom one, else the docked bar,\n * else the main region; the root takes the inline ones.\n * For a dense product view (a table, an inbox, an admin dashboard), wrap it\n * in <UIProvider density=\"compact\">.\n */\nexport function AppView({\n aside,\n asideLabel = 'Details',\n asideWidth,\n bottomBar,\n bottomBarLabel = 'Player',\n children,\n chrome = appViewContract.defaultChrome,\n className,\n layout = appViewContract.defaultLayout,\n overlay,\n panel,\n panelLabel = 'Library',\n panelWidth,\n rail,\n railLabel = 'Navigation',\n railWidth,\n style,\n tabBar,\n topBar,\n topBarSpan = appViewContract.defaultTopBarSpan,\n ...props\n}: AppViewProps): React.ReactElement {\n const bottomInset = tabBar ? 'tab-bar' : bottomBar ? 'bottom-bar' : 'main'\n const isWindow = layout === 'window'\n const spansMain = isWindow && topBarSpan === 'main'\n const widths = {\n ...(panelWidth ? { '--a63-app-view-panel-width': panelWidth } : {}),\n ...(railWidth ? { '--a63-app-view-rail-width': railWidth } : {}),\n ...(asideWidth ? { '--a63-app-view-aside-width': asideWidth } : {}),\n }\n const header = topBar ? <header data-slot=\"app-view-top-bar\">{topBar}</header> : null\n const content = (\n <>\n {/* eslint-disable-next-line jsx-a11y/no-noninteractive-tabindex -- a scroll region takes focus so a keyboard can scroll it. */}\n <main data-slot=\"app-view-main\" tabIndex={0}>\n {children}\n </main>\n {overlay ? <div data-slot=\"app-view-overlay\">{overlay}</div> : null}\n {aside && isWindow ? (\n // eslint-disable-next-line jsx-a11y/no-noninteractive-tabindex -- a scroll region takes focus so a keyboard can scroll it.\n <aside aria-label={asideLabel} data-slot=\"app-view-aside\" tabIndex={0}>\n {aside}\n </aside>\n ) : null}\n </>\n )\n return (\n <div\n className={cn('a63-AppView', className)}\n data-a63-form-factor={layout === 'phone' ? 'phone' : undefined}\n data-aside={aside && isWindow ? '' : undefined}\n data-bottom-inset={bottomInset}\n data-chrome={layout === 'phone' ? 'flush' : chrome}\n data-layout={layout}\n data-slot=\"app-view\"\n data-top-bar-span={isWindow ? topBarSpan : undefined}\n style={Object.keys(widths).length ? { ...widths, ...style } : style}\n {...props}\n >\n {spansMain ? null : header}\n <div data-slot=\"app-view-body\">\n {rail && isWindow ? (\n // eslint-disable-next-line jsx-a11y/no-noninteractive-tabindex -- a scroll region takes focus so a keyboard can scroll it.\n <aside aria-label={railLabel} data-slot=\"app-view-rail\" tabIndex={0}>\n {rail}\n </aside>\n ) : null}\n {panel && isWindow ? (\n // eslint-disable-next-line jsx-a11y/no-noninteractive-tabindex -- a scroll region takes focus so a keyboard can scroll it.\n <aside aria-label={panelLabel} data-slot=\"app-view-panel\" tabIndex={0}>\n {panel}\n </aside>\n ) : null}\n {spansMain ? (\n <div data-slot=\"app-view-content\">\n {header}\n <div data-slot=\"app-view-body\">{content}</div>\n </div>\n ) : (\n content\n )}\n </div>\n {bottomBar ? (\n <section aria-label={bottomBarLabel} data-slot=\"app-view-bottom-bar\">\n {bottomBar}\n </section>\n ) : null}\n {tabBar ? <div data-slot=\"app-view-tab-bar\">{tabBar}</div> : null}\n </div>\n )\n}\n","import type { ReactNode } from 'react'\nimport { cn } from '../lib/cn'\n\nexport interface ReaderLayoutProps {\n aside?: ReactNode\n asideClassName?: string\n children: ReactNode\n className?: string\n contentClassName?: string\n /** Keep the aside column even with no aside, so the content measure holds across pages. */\n reserveAside?: boolean\n}\n\nexport function ReaderLayout({\n aside,\n asideClassName,\n children,\n className,\n contentClassName,\n reserveAside = false,\n}: ReaderLayoutProps) {\n return (\n <div className={cn('mx-auto flex w-full max-w-5xl', className)} data-slot=\"reader-layout\">\n <article\n className={cn(\n 'min-w-0 flex-1 space-y-8 px-4 pt-8 pb-8 sm:px-6 lg:px-8 xl:max-w-4xl',\n contentClassName\n )}\n data-slot=\"reader-layout-content\"\n >\n {children}\n </article>\n {aside || reserveAside ? (\n <div\n aria-hidden={aside ? undefined : true}\n className={cn('hidden w-64 shrink-0 px-4 pt-8 xl:block', asideClassName)}\n data-slot=\"reader-layout-aside\"\n >\n {aside}\n </div>\n ) : null}\n </div>\n )\n}\n"]}
|
package/dist/media/index.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import * as React$1 from 'react';
|
|
2
2
|
import { ReactElement, PointerEvent, VideoHTMLAttributes, ReactNode } from 'react';
|
|
3
|
-
import { M as MediaLightboxLabels, a as MediaLightboxProps, b as MediaLightboxTransition } from '../types-
|
|
4
|
-
export { c as MediaLightboxAppearance, d as MediaLightboxItem, e as MediaLightboxItemKind, f as MediaLightboxVideoSource, g as MediaLightboxVideoTrack } from '../types-
|
|
3
|
+
import { M as MediaLightboxLabels, a as MediaLightboxProps, b as MediaLightboxTransition } from '../types-KQLxlHQZ.js';
|
|
4
|
+
export { c as MediaLightboxAppearance, d as MediaLightboxItem, e as MediaLightboxItemKind, f as MediaLightboxVideoSource, g as MediaLightboxVideoTrack } from '../types-KQLxlHQZ.js';
|
|
5
5
|
|
|
6
6
|
declare const clearImageAnimationCache: () => void;
|
|
7
7
|
type AspectRatio = 'auto' | '1/1' | '4/3' | '3/4' | '16/9' | '9/16' | '2/3' | '3/2' | '5/4' | '21/9' | '9/21';
|
|
@@ -45,7 +45,7 @@ declare const DEFAULT_MEDIA_LIGHTBOX_LABELS: MediaLightboxLabels;
|
|
|
45
45
|
* pixel of appearance — the glass buttons, the dock, the safe-area padding,
|
|
46
46
|
* the responsive reveal of the side chevrons — lives here.
|
|
47
47
|
*/
|
|
48
|
-
declare function MediaLightbox({ appearance, className, index, items, labels, onAppearanceChange, onExitComplete, onIndexChange, onOpenChange, open, origin, preload, thumbnails, transition, }: MediaLightboxProps): ReactElement | null;
|
|
48
|
+
declare function MediaLightbox({ actions, appearance, className, index, items, labels, onAppearanceChange, onExitComplete, onIndexChange, onOpenChange, open, origin, preload, thumbnails, toolbar, transition, }: MediaLightboxProps): ReactElement | null;
|
|
49
49
|
|
|
50
50
|
type ExcludeRef = {
|
|
51
51
|
readonly current: HTMLElement | null;
|
|
@@ -216,4 +216,5 @@ interface VideoThumbnailProps {
|
|
|
216
216
|
}
|
|
217
217
|
declare function VideoThumbnail({ src, className }: VideoThumbnailProps): React$1.JSX.Element;
|
|
218
218
|
|
|
219
|
-
export {
|
|
219
|
+
export { DEFAULT_MEDIA_LIGHTBOX_LABELS, Image, MediaLightbox, MediaLightboxLabels, MediaLightboxProps, MediaLightboxTransition, MediaLightboxZoomCursor, Video, VideoDialog, VideoManagerContext, VideoManagerProvider, VideoModal, VideoThumbnail, clearImageAnimationCache, isVideoSrc, useMediaLightbox, useMediaLightboxZoomCursor, useVideoManager };
|
|
220
|
+
export type { AspectRatio, ImageProps, UseMediaLightboxOptions, UseMediaLightboxResult, VideoDialogProps, VideoManagerContextType, VideoManagerProviderProps, VideoModalInteractionMode, VideoModalProps, VideoProps, VideoSource, VideoThumbnailProps };
|
package/dist/media/index.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { useReducedMotion, Lightbox, revealOrigin, supportsViewTransitions, preferCheapMediaTransition, runMediaViewTransition, useLightboxRefs, useLightboxConfig, useLightboxState, CHROME_IN, CHROME_OUT, CHROME_EXIT_OFFSET, AXIS_LOCK_THRESHOLD } from '../chunk-
|
|
2
|
-
export { DEFAULT_MEDIA_LIGHTBOX_LABELS } from '../chunk-
|
|
3
|
-
import '../chunk-
|
|
1
|
+
import { useReducedMotion, Lightbox, revealOrigin, supportsViewTransitions, preferCheapMediaTransition, runMediaViewTransition, useLightboxRefs, useLightboxConfig, useLightboxState, CHROME_IN, CHROME_OUT, CHROME_EXIT_OFFSET, AXIS_LOCK_THRESHOLD } from '../chunk-ZEY2VU4O.js';
|
|
2
|
+
export { DEFAULT_MEDIA_LIGHTBOX_LABELS } from '../chunk-ZEY2VU4O.js';
|
|
3
|
+
import '../chunk-WL27K6MO.js';
|
|
4
4
|
import '../chunk-UPPHQLZ2.js';
|
|
5
5
|
import { cn } from '../chunk-AJLHJRK6.js';
|
|
6
6
|
import { motion, AnimatePresence } from 'motion/react';
|
|
@@ -626,9 +626,15 @@ function lightboxIconButtonClassName(tone = "glass") {
|
|
|
626
626
|
)
|
|
627
627
|
);
|
|
628
628
|
}
|
|
629
|
-
function PresetFloatingChrome({
|
|
630
|
-
|
|
629
|
+
function PresetFloatingChrome({
|
|
630
|
+
chrome,
|
|
631
|
+
toolbar
|
|
632
|
+
}) {
|
|
633
|
+
const { items, transition } = useLightboxConfig();
|
|
634
|
+
const { index } = useLightboxState();
|
|
631
635
|
const { rootRef } = useLightboxRefs();
|
|
636
|
+
const item = items[index];
|
|
637
|
+
const toolbarContent = item && toolbar ? toolbar(item, index) : null;
|
|
632
638
|
const viewTransition = transition === "view-transition";
|
|
633
639
|
const pointerEventsClassName = chrome.visible ? "pointer-events-auto" : "pointer-events-none";
|
|
634
640
|
return /* @__PURE__ */ jsx(
|
|
@@ -660,6 +666,15 @@ function PresetFloatingChrome({ chrome }) {
|
|
|
660
666
|
{
|
|
661
667
|
className: cn("absolute top-4 right-4 flex items-center gap-1.5", pointerEventsClassName),
|
|
662
668
|
children: [
|
|
669
|
+
toolbarContent != null ? /* @__PURE__ */ jsx(
|
|
670
|
+
"div",
|
|
671
|
+
{
|
|
672
|
+
className: "flex items-center gap-1.5",
|
|
673
|
+
"data-a63-no-drag": "",
|
|
674
|
+
"data-slot": "media-lightbox-toolbar",
|
|
675
|
+
children: toolbarContent
|
|
676
|
+
}
|
|
677
|
+
) : null,
|
|
663
678
|
/* @__PURE__ */ jsx(Lightbox.AppearanceToggle, { className: lightboxIconButtonClassName("glass") }),
|
|
664
679
|
/* @__PURE__ */ jsx(Lightbox.Destination, { className: lightboxIconButtonClassName("glass") }),
|
|
665
680
|
/* @__PURE__ */ jsxs(
|
|
@@ -713,6 +728,7 @@ function PresetFloatingChrome({ chrome }) {
|
|
|
713
728
|
);
|
|
714
729
|
}
|
|
715
730
|
function Dock({
|
|
731
|
+
actions,
|
|
716
732
|
chrome,
|
|
717
733
|
thumbnails
|
|
718
734
|
}) {
|
|
@@ -724,6 +740,7 @@ function Dock({
|
|
|
724
740
|
const isAboveSm = useMinWidth(SM_BREAKPOINT_PX);
|
|
725
741
|
const showThumbnails = thumbnails && itemCount > 1 && isAboveSm;
|
|
726
742
|
const pointerEventsClassName = chrome.visible ? "pointer-events-auto" : "pointer-events-none";
|
|
743
|
+
const actionsContent = item && actions ? actions(item, index) : null;
|
|
727
744
|
return /* @__PURE__ */ jsx(
|
|
728
745
|
"div",
|
|
729
746
|
{
|
|
@@ -784,6 +801,15 @@ function Dock({
|
|
|
784
801
|
}
|
|
785
802
|
) : null
|
|
786
803
|
] }),
|
|
804
|
+
actionsContent != null ? /* @__PURE__ */ jsx(
|
|
805
|
+
"div",
|
|
806
|
+
{
|
|
807
|
+
className: "flex max-w-full items-center justify-start gap-2 overflow-x-auto sm:justify-center",
|
|
808
|
+
"data-a63-no-drag": "",
|
|
809
|
+
"data-slot": "media-lightbox-actions",
|
|
810
|
+
children: actionsContent
|
|
811
|
+
}
|
|
812
|
+
) : null,
|
|
787
813
|
showThumbnails ? /* @__PURE__ */ jsx(Lightbox.Thumbnails, { className: "max-w-full min-w-0 justify-start sm:justify-center", children: (thumbnail) => /* @__PURE__ */ jsx(
|
|
788
814
|
Lightbox.Thumbnail,
|
|
789
815
|
{
|
|
@@ -845,6 +871,7 @@ function revealFor(chrome) {
|
|
|
845
871
|
};
|
|
846
872
|
}
|
|
847
873
|
function MediaLightbox({
|
|
874
|
+
actions,
|
|
848
875
|
appearance,
|
|
849
876
|
className,
|
|
850
877
|
index,
|
|
@@ -858,6 +885,7 @@ function MediaLightbox({
|
|
|
858
885
|
origin,
|
|
859
886
|
preload,
|
|
860
887
|
thumbnails,
|
|
888
|
+
toolbar,
|
|
861
889
|
transition = "flip"
|
|
862
890
|
}) {
|
|
863
891
|
const chrome = useChromeAutoHide(open);
|
|
@@ -905,11 +933,11 @@ function MediaLightbox({
|
|
|
905
933
|
/* @__PURE__ */ jsx(SlideCloseArea, { touchRef }),
|
|
906
934
|
/* @__PURE__ */ jsx(Lightbox.Frame, { className: "sm:rounded-2xl", children: /* @__PURE__ */ jsx(Lightbox.Zoom, { children: /* @__PURE__ */ jsx(Lightbox.Media, {}) }) })
|
|
907
935
|
] }, slide.item.id) }),
|
|
908
|
-
/* @__PURE__ */ jsx(PresetFloatingChrome, { chrome })
|
|
936
|
+
/* @__PURE__ */ jsx(PresetFloatingChrome, { chrome, toolbar })
|
|
909
937
|
]
|
|
910
938
|
}
|
|
911
939
|
),
|
|
912
|
-
/* @__PURE__ */ jsx(Dock, { chrome, thumbnails: Boolean(thumbnails) })
|
|
940
|
+
/* @__PURE__ */ jsx(Dock, { actions, chrome, thumbnails: Boolean(thumbnails) })
|
|
913
941
|
]
|
|
914
942
|
}
|
|
915
943
|
)
|