@talogic/react 0.0.0-stage → 0.6.1

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.
Files changed (130) hide show
  1. package/README.md +106 -2
  2. package/app/app-shell.component.d.ts +59 -0
  3. package/app/command-shortcut.hook.d.ts +21 -0
  4. package/app/filter-bar.component.d.ts +38 -0
  5. package/app/form-section.component.d.ts +21 -0
  6. package/app/index.d.ts +14 -0
  7. package/app/page-header.component.d.ts +20 -0
  8. package/app/records-table.component.d.ts +38 -0
  9. package/app/sparkline.algorithm.d.ts +11 -0
  10. package/app/stat-card.component.d.ts +28 -0
  11. package/class-names/class-names.algorithm.d.ts +8 -0
  12. package/class-names/index.d.ts +1 -0
  13. package/desktop/flow-node.component.d.ts +25 -0
  14. package/desktop/index.d.ts +12 -0
  15. package/desktop/inspector.component.d.ts +29 -0
  16. package/desktop/status-bar.component.d.ts +17 -0
  17. package/desktop/timeline-lanes.component.d.ts +43 -0
  18. package/desktop/timeline.algorithm.d.ts +22 -0
  19. package/desktop/title-bar.component.d.ts +24 -0
  20. package/fonts.css +4 -0
  21. package/index.d.ts +17 -0
  22. package/index.js +3495 -0
  23. package/index.js.map +1 -0
  24. package/mobile/bottom-nav.component.d.ts +23 -0
  25. package/mobile/capture-frame.component.d.ts +30 -0
  26. package/mobile/index.d.ts +6 -0
  27. package/mobile/record-button.component.d.ts +24 -0
  28. package/package.json +63 -4
  29. package/product/index.d.ts +8 -0
  30. package/product/product-catalogue.content.d.ts +16 -0
  31. package/product/product-logo.component.d.ts +17 -0
  32. package/product/product-switcher.component.d.ts +21 -0
  33. package/product/sidebar-brand.component.d.ts +18 -0
  34. package/status/index.d.ts +6 -0
  35. package/status/run-status.contract.d.ts +7 -0
  36. package/status/run-status.mapper.d.ts +18 -0
  37. package/status/status-badge.component.d.ts +14 -0
  38. package/talogic-react.css +2 -0
  39. package/timecode/index.d.ts +1 -0
  40. package/timecode/timecode.mapper.d.ts +17 -0
  41. package/tokens/apca-contrast.algorithm.d.ts +23 -0
  42. package/tokens/hue-fill.style.d.ts +6 -0
  43. package/tokens/index.d.ts +12 -0
  44. package/tokens/logo-color.algorithm.d.ts +21 -0
  45. package/tokens/palette.style.d.ts +6 -0
  46. package/tokens/product-hue.policy.d.ts +15 -0
  47. package/tokens/theme-attributes.mapper.d.ts +18 -0
  48. package/tokens/theme-root.component.d.ts +15 -0
  49. package/tokens/theme.contract.d.ts +34 -0
  50. package/tokens.css +949 -0
  51. package/ui/active-indicator/active-indicator.hook.d.ts +11 -0
  52. package/ui/active-indicator/active-indicator.recipe.d.ts +5 -0
  53. package/ui/active-indicator/index.d.ts +2 -0
  54. package/ui/avatar/avatar.component.d.ts +23 -0
  55. package/ui/avatar/index.d.ts +1 -0
  56. package/ui/badge/badge.component.d.ts +14 -0
  57. package/ui/badge/badge.recipe.d.ts +12 -0
  58. package/ui/badge/index.d.ts +4 -0
  59. package/ui/button/button.component.d.ts +16 -0
  60. package/ui/button/button.recipe.d.ts +11 -0
  61. package/ui/button/index.d.ts +4 -0
  62. package/ui/choice/checkbox.component.d.ts +11 -0
  63. package/ui/choice/index.d.ts +5 -0
  64. package/ui/choice/radio-group.component.d.ts +17 -0
  65. package/ui/choice/slider.component.d.ts +10 -0
  66. package/ui/choice/switch.component.d.ts +9 -0
  67. package/ui/choice/toggle-group.component.d.ts +17 -0
  68. package/ui/feedback/alert.component.d.ts +41 -0
  69. package/ui/feedback/empty-state.component.d.ts +19 -0
  70. package/ui/feedback/index.d.ts +8 -0
  71. package/ui/feedback/progress.component.d.ts +9 -0
  72. package/ui/feedback/skeleton.component.d.ts +8 -0
  73. package/ui/feedback/spinner.component.d.ts +10 -0
  74. package/ui/feedback/toaster.component.d.ts +10 -0
  75. package/ui/field/control.recipe.d.ts +5 -0
  76. package/ui/field/field-control.hook.d.ts +26 -0
  77. package/ui/field/field.component.d.ts +22 -0
  78. package/ui/field/index.d.ts +10 -0
  79. package/ui/field/input.component.d.ts +13 -0
  80. package/ui/field/label.component.d.ts +9 -0
  81. package/ui/field/select.component.d.ts +43 -0
  82. package/ui/field/textarea.component.d.ts +8 -0
  83. package/ui/index.d.ts +11 -0
  84. package/ui/layout/accordion.component.d.ts +30 -0
  85. package/ui/layout/card.component.d.ts +43 -0
  86. package/ui/layout/index.d.ts +7 -0
  87. package/ui/layout/kbd.component.d.ts +8 -0
  88. package/ui/layout/resizable.component.d.ts +23 -0
  89. package/ui/layout/scroll-area.component.d.ts +16 -0
  90. package/ui/layout/separator.component.d.ts +9 -0
  91. package/ui/layout/table.component.d.ts +50 -0
  92. package/ui/menu/command.component.d.ts +72 -0
  93. package/ui/menu/context-menu.component.d.ts +39 -0
  94. package/ui/menu/dropdown-menu.component.d.ts +57 -0
  95. package/ui/menu/index.d.ts +6 -0
  96. package/ui/menu/menu.recipe.d.ts +13 -0
  97. package/ui/navigation/breadcrumb.component.d.ts +45 -0
  98. package/ui/navigation/index.d.ts +11 -0
  99. package/ui/navigation/menu-icon.component.d.ts +18 -0
  100. package/ui/navigation/menubar.component.d.ts +48 -0
  101. package/ui/navigation/navigation-menu.component.d.ts +39 -0
  102. package/ui/navigation/pagination.component.d.ts +20 -0
  103. package/ui/navigation/stepper.component.d.ts +28 -0
  104. package/ui/navigation/tabs.component.d.ts +39 -0
  105. package/ui/overlay/alert-dialog.component.d.ts +42 -0
  106. package/ui/overlay/dialog.component.d.ts +48 -0
  107. package/ui/overlay/drawer.component.d.ts +29 -0
  108. package/ui/overlay/index.d.ts +9 -0
  109. package/ui/overlay/overlay.recipe.d.ts +18 -0
  110. package/ui/overlay/popover.component.d.ts +15 -0
  111. package/ui/overlay/sheet.component.d.ts +31 -0
  112. package/ui/overlay/tooltip.component.d.ts +20 -0
  113. package/ui/sidebar/index.d.ts +11 -0
  114. package/ui/sidebar/sidebar-context.hook.d.ts +29 -0
  115. package/ui/sidebar/sidebar-group.component.d.ts +26 -0
  116. package/ui/sidebar/sidebar-item.component.d.ts +35 -0
  117. package/ui/sidebar/sidebar-sheet.component.d.ts +25 -0
  118. package/ui/sidebar/sidebar.component.d.ts +80 -0
  119. package/ui/sidebar/sidebar.recipe.d.ts +8 -0
  120. package/web/cta-band.component.d.ts +20 -0
  121. package/web/faq.component.d.ts +19 -0
  122. package/web/feature-grid.component.d.ts +22 -0
  123. package/web/hero.component.d.ts +20 -0
  124. package/web/how-it-works.component.d.ts +22 -0
  125. package/web/index.d.ts +20 -0
  126. package/web/mobile-menu.component.d.ts +25 -0
  127. package/web/pricing-table.component.d.ts +37 -0
  128. package/web/product-card.component.d.ts +20 -0
  129. package/web/site-footer.component.d.ts +25 -0
  130. package/web/site-header.component.d.ts +32 -0
@@ -0,0 +1,15 @@
1
+ import { Popover as PopoverPrimitive } from 'radix-ui';
2
+ import type { ComponentProps } from 'react';
3
+ /** The shadcn/ui Popover root (Radix). */
4
+ export declare const Popover: import("react").FC<PopoverPrimitive.PopoverProps>;
5
+ /** The element that opens a {@link Popover}. */
6
+ export declare const PopoverTrigger: import("react").ForwardRefExoticComponent<PopoverPrimitive.PopoverTriggerProps & import("react").RefAttributes<HTMLButtonElement>>;
7
+ /** An element the popover places itself against, in place of the trigger. */
8
+ export declare const PopoverAnchor: import("react").ForwardRefExoticComponent<PopoverPrimitive.PopoverAnchorProps & import("react").RefAttributes<HTMLDivElement>>;
9
+ /**
10
+ * The floating panel of a {@link Popover}: medium elevation, 10 px radius.
11
+ *
12
+ * @param props - Radix Popover content props.
13
+ * @returns The panel in a portal.
14
+ */
15
+ export declare function PopoverContent({ className, align, sideOffset, ...props }: ComponentProps<typeof PopoverPrimitive.Content>): import("react").JSX.Element;
@@ -0,0 +1,31 @@
1
+ import { Dialog as SheetPrimitive } from 'radix-ui';
2
+ import type { ComponentProps } from 'react';
3
+ /** The shadcn/ui Sheet root: a dialog that slides in from an edge. */
4
+ export declare const Sheet: import("react").FC<SheetPrimitive.DialogProps>;
5
+ /** The element that opens a {@link Sheet}. */
6
+ export declare const SheetTrigger: import("react").ForwardRefExoticComponent<SheetPrimitive.DialogTriggerProps & import("react").RefAttributes<HTMLButtonElement>>;
7
+ /** An element that closes a {@link Sheet}. */
8
+ export declare const SheetClose: import("react").ForwardRefExoticComponent<SheetPrimitive.DialogCloseProps & import("react").RefAttributes<HTMLButtonElement>>;
9
+ /** The title of a {@link Sheet}. */
10
+ export declare const SheetTitle: import("react").ForwardRefExoticComponent<SheetPrimitive.DialogTitleProps & import("react").RefAttributes<HTMLHeadingElement>>;
11
+ /** The description of a {@link Sheet}. */
12
+ export declare const SheetDescription: import("react").ForwardRefExoticComponent<SheetPrimitive.DialogDescriptionProps & import("react").RefAttributes<HTMLParagraphElement>>;
13
+ declare const sideClassName: {
14
+ readonly start: "inset-y-0 start-0 h-full w-3/4 max-w-sm border-e";
15
+ readonly end: "inset-y-0 end-0 h-full w-3/4 max-w-sm border-s";
16
+ readonly top: "inset-x-0 top-0 border-b";
17
+ readonly bottom: "inset-x-0 bottom-0 border-t";
18
+ };
19
+ /** Props of {@link SheetContent}. */
20
+ export interface SheetContentProps extends ComponentProps<typeof SheetPrimitive.Content> {
21
+ /** The edge the sheet comes from. Default `end`. */
22
+ side?: keyof typeof sideClassName;
23
+ }
24
+ /**
25
+ * The panel of a {@link Sheet}, against one edge, with a close button.
26
+ *
27
+ * @param props - `side` and Radix Dialog content props.
28
+ * @returns The panel in a portal.
29
+ */
30
+ export declare function SheetContent({ className, children, side, ...props }: SheetContentProps): import("react").JSX.Element;
31
+ export {};
@@ -0,0 +1,20 @@
1
+ import { Tooltip as TooltipPrimitive } from 'radix-ui';
2
+ import type { ComponentProps } from 'react';
3
+ /** Shares the tooltip delay across the app. Put one near the root. */
4
+ export declare const TooltipProvider: import("react").FC<TooltipPrimitive.TooltipProviderProps>;
5
+ /**
6
+ * The shadcn/ui Tooltip root. It brings its own provider, so it also works alone.
7
+ *
8
+ * @param props - Radix Tooltip root props.
9
+ * @returns The tooltip.
10
+ */
11
+ export declare function Tooltip(props: ComponentProps<typeof TooltipPrimitive.Root>): import("react").JSX.Element;
12
+ /** The element that shows a {@link Tooltip} on hover and focus. */
13
+ export declare const TooltipTrigger: import("react").ForwardRefExoticComponent<TooltipPrimitive.TooltipTriggerProps & import("react").RefAttributes<HTMLButtonElement>>;
14
+ /**
15
+ * The tip: inverted colours, 12 px text.
16
+ *
17
+ * @param props - Radix Tooltip content props.
18
+ * @returns The tip in a portal.
19
+ */
20
+ export declare function TooltipContent({ className, sideOffset, ...props }: ComponentProps<typeof TooltipPrimitive.Content>): import("react").JSX.Element;
@@ -0,0 +1,11 @@
1
+ export { Sidebar, SidebarCollapseButton, SidebarContent, SidebarFooter, SidebarHeader, SidebarTooltip } from './sidebar.component';
2
+ export type { SidebarHeaderProps, SidebarProps } from './sidebar.component';
3
+ export { useSidebar } from './sidebar-context.hook';
4
+ export type { SidebarState, SidebarVariant } from './sidebar-context.hook';
5
+ export { fadingLabelClassName, navRowClassName } from './sidebar.recipe';
6
+ export { SidebarGroup } from './sidebar-group.component';
7
+ export type { SidebarGroupProps } from './sidebar-group.component';
8
+ export { SidebarItem } from './sidebar-item.component';
9
+ export type { SidebarItemProps } from './sidebar-item.component';
10
+ export { SidebarSheet } from './sidebar-sheet.component';
11
+ export type { SidebarSheetProps } from './sidebar-sheet.component';
@@ -0,0 +1,29 @@
1
+ /**
2
+ * The two sidebars of the family. `panel` is the desktop app's tool panel (loomgic's plugins): foldable groups of
3
+ * items with a colour bar and a meta line, collapsing to a rail with its name written down the side. `nav` is the
4
+ * web platform's navigation (pargic's portal): sections of icon links, collapsing to its icons by narrowing, with
5
+ * the labels fading in place so the icons never move.
6
+ */
7
+ export type SidebarVariant = 'panel' | 'nav';
8
+ /** What a {@link Sidebar} tells the parts inside it. */
9
+ export interface SidebarState {
10
+ /** True when the sidebar shows only its icons. */
11
+ collapsed: boolean;
12
+ /** Expands or collapses the sidebar. */
13
+ setCollapsed: (collapsed: boolean) => void;
14
+ /** The sidebar's name, such as "Plugins" or "Portal". */
15
+ label: string;
16
+ /** The edge the sidebar sits on. */
17
+ side: 'start' | 'end';
18
+ /** The kind of sidebar. */
19
+ variant: SidebarVariant;
20
+ }
21
+ /** The context a {@link Sidebar} provides. Null outside a sidebar. */
22
+ export declare const SidebarContext: import("react").Context<SidebarState | null>;
23
+ /**
24
+ * Reads the state of the sidebar around a part.
25
+ *
26
+ * @returns The sidebar state.
27
+ * @throws Error when the part is not inside a Sidebar.
28
+ */
29
+ export declare function useSidebar(): SidebarState;
@@ -0,0 +1,26 @@
1
+ import { type ReactNode } from 'react';
2
+ /** Props of {@link SidebarGroup}. */
3
+ export interface SidebarGroupProps {
4
+ /** The group's title, such as "Speech" or "Build". */
5
+ title: string;
6
+ /** The number shown at the end of the title row, such as the number of plugins. */
7
+ count?: number;
8
+ /** Opens a folding group whatever the user chose, for example while a search is typed. */
9
+ forceOpen?: boolean;
10
+ /** The first open state of a folding group. Default true. */
11
+ defaultOpen?: boolean;
12
+ /** Whether the group folds. Default true in the `panel` variant and false in the `nav` variant. */
13
+ collapsible?: boolean;
14
+ /** The group's items. */
15
+ children: ReactNode;
16
+ className?: string;
17
+ }
18
+ /**
19
+ * A titled group of a {@link Sidebar}. In the `panel` variant it folds; while the sidebar collapses its title row
20
+ * slides away like the labels, and its items stay as a column of colour bars (a folded group opens on the rail). In the `nav` variant it is a section whose title fades in place when
21
+ * the sidebar collapses.
22
+ *
23
+ * @param props - Title, count, open state, whether it folds, and the items.
24
+ * @returns The group.
25
+ */
26
+ export declare function SidebarGroup({ title, count, forceOpen, defaultOpen, collapsible, className, children }: SidebarGroupProps): import("react").JSX.Element;
@@ -0,0 +1,35 @@
1
+ import { type ComponentProps, type ReactNode } from 'react';
2
+ import { type Hue } from '../../tokens';
3
+ /** Props of {@link SidebarItem}. */
4
+ export interface SidebarItemProps extends Omit<ComponentProps<'button'>, 'title'> {
5
+ /** The item's name, such as a plugin or a page. */
6
+ title: string;
7
+ /** One short line under the title in Fira Code, such as a version or a type. `panel` variant only. */
8
+ meta?: ReactNode;
9
+ /** A 16 px icon. In the `nav` variant every item has one; in the `panel` variant it replaces the colour bar. */
10
+ icon?: ReactNode;
11
+ /** The family hue of the colour bar (`panel` variant). */
12
+ hue?: Hue;
13
+ /** A colour for the bar when it is not a family hue, such as a plugin's own colour. */
14
+ color?: string;
15
+ /** A count or short badge at the end of the row, such as the number of recipes. */
16
+ badge?: ReactNode;
17
+ /** Marks the current item or page: the brand-soft background and `aria-current`. */
18
+ active?: boolean;
19
+ /**
20
+ * Renders the item through its only child, such as a router link: the child gets the item's look and content.
21
+ * Its own children are replaced.
22
+ */
23
+ asChild?: boolean;
24
+ /** With `asChild`, the element to render, such as `<a href='/runs' />`. */
25
+ children?: ReactNode;
26
+ }
27
+ /**
28
+ * One entry of a {@link Sidebar}. In the `panel` variant: a colour bar or an icon, the title and a meta line; it can
29
+ * be dragged, for example onto a canvas. In the `nav` variant: an icon and a label. In both, the text slides away
30
+ * while the sidebar collapses and the bar or icon stays put; collapsed, the title shows in a tooltip.
31
+ *
32
+ * @param props - Title, meta, icon or colour, the active state, `asChild` and any button props.
33
+ * @returns The item.
34
+ */
35
+ export declare function SidebarItem({ title, meta, icon, hue, color, badge, active, asChild, className, children, ...props }: SidebarItemProps): import("react").JSX.Element;
@@ -0,0 +1,25 @@
1
+ import type { ReactNode } from 'react';
2
+ /** Props of {@link SidebarSheet}. */
3
+ export interface SidebarSheetProps {
4
+ /** The sidebar's name, for the button and the sheet's title. */
5
+ label: string;
6
+ /** The Sidebar to show. */
7
+ children: ReactNode;
8
+ /** The edge the sheet comes from. Default `start`. */
9
+ side?: 'start' | 'end';
10
+ /** Controls the open state. */
11
+ open?: boolean;
12
+ /** Called with the new open state. */
13
+ onOpenChange?: (open: boolean) => void;
14
+ /** Classes for the open button, such as `md:hidden`. */
15
+ className?: string;
16
+ }
17
+ /**
18
+ * The sidebar on a phone: a button that opens the {@link Sidebar} in a sheet from the side, at the mobile density.
19
+ * The sheet slides in and the labels slide into place, as when the desktop sidebar widens.
20
+ * Close the sheet when the user picks an item, with `open` and `onOpenChange`.
21
+ *
22
+ * @param props - The label, the sidebar, the side and the open state.
23
+ * @returns The button, and the sheet while it is open.
24
+ */
25
+ export declare function SidebarSheet({ label, children, side, open, onOpenChange, className }: SidebarSheetProps): import("react").JSX.Element;
@@ -0,0 +1,80 @@
1
+ import { type ComponentProps, type ReactNode } from 'react';
2
+ import { type SidebarVariant } from './sidebar-context.hook';
3
+ /** Props of {@link Sidebar}. */
4
+ export interface SidebarProps extends Omit<ComponentProps<'aside'>, 'aria-label'> {
5
+ /** The sidebar's name, such as "Plugins". It labels the landmark, and the panel rail shows it down the side. */
6
+ label: string;
7
+ /** `panel` for a desktop tool panel (default), `nav` for a web platform's navigation. */
8
+ variant?: SidebarVariant;
9
+ /** The edge the sidebar sits on. Default `start`. */
10
+ side?: 'start' | 'end';
11
+ /** Controls the collapsed state. Leave it out for a sidebar that keeps its own. */
12
+ collapsed?: boolean;
13
+ /** The first collapsed state of a sidebar that keeps its own. Default false. */
14
+ defaultCollapsed?: boolean;
15
+ /** Called with the new collapsed state. */
16
+ onCollapsedChange?: (collapsed: boolean) => void;
17
+ }
18
+ /**
19
+ * The family sidebar, in two variants built from the same parts. `panel` follows loomgic's plugin sidebar: search
20
+ * and a collapse button on top, foldable groups of items with a colour bar, and a rail with the sidebar's name when
21
+ * collapsed (put it in a ResizablePanel to let the user widen it). `nav` follows pargic's portal: the product at the
22
+ * top, sections of icon links, and a foot with the account and the collapse button; it narrows to its icons while
23
+ * the labels fade in place. On a phone, put either in a SidebarSheet.
24
+ *
25
+ * @param props - Label, variant, side, the collapsed state, and any `aside` props.
26
+ * @returns The sidebar.
27
+ */
28
+ export declare function Sidebar({ label, variant, side, collapsed, defaultCollapsed, onCollapsedChange, className, children, ...props }: SidebarProps): import("react").JSX.Element;
29
+ /**
30
+ * Shows a tooltip with the name of a part while the sidebar is collapsed, when its label is hidden.
31
+ *
32
+ * @param props - The name and the part.
33
+ * @returns The part, with a tooltip when collapsed.
34
+ */
35
+ export declare function SidebarTooltip({ label, children }: {
36
+ label: string;
37
+ children: ReactNode;
38
+ }): string | number | bigint | boolean | import("react").JSX.Element | Iterable<ReactNode> | Promise<string | number | bigint | boolean | import("react").ReactPortal | import("react").ReactElement<unknown, string | import("react").JSXElementConstructor<any>> | Iterable<ReactNode> | null | undefined> | null | undefined;
39
+ /**
40
+ * The button that collapses the sidebar and expands it again. In the `nav` variant it is a full row with a label.
41
+ *
42
+ * @param props - Any button props.
43
+ * @returns The button.
44
+ */
45
+ export declare function SidebarCollapseButton({ className, ...props }: ComponentProps<'button'>): import("react").JSX.Element;
46
+ /** Props of {@link SidebarHeader}. */
47
+ export interface SidebarHeaderProps {
48
+ /** The search text. Leave out `onQueryChange` for a header without search. */
49
+ query?: string;
50
+ /** Called with the new search text. */
51
+ onQueryChange?: (query: string) => void;
52
+ /** The search field's accessible label and placeholder. Default "Search" and the sidebar's name. */
53
+ searchLabel?: string;
54
+ /** Controls beside the search in the `panel` variant, or the brand in the `nav` variant. */
55
+ children?: ReactNode;
56
+ className?: string;
57
+ }
58
+ /**
59
+ * The top of a {@link Sidebar}. In the `panel` variant: the search field and the collapse button; collapsed, only the
60
+ * button stays. In the `nav` variant: its children, usually a SidebarBrand.
61
+ *
62
+ * @param props - The search state, its label, and extra controls.
63
+ * @returns The header.
64
+ */
65
+ export declare function SidebarHeader({ query, onQueryChange, searchLabel, children, className }: SidebarHeaderProps): import("react").JSX.Element;
66
+ /**
67
+ * The scrolling body of a {@link Sidebar}, which holds the groups. In the `nav` variant it is the navigation landmark.
68
+ *
69
+ * @param props - Any `div` props, and `label` for the navigation's name in the `nav` variant.
70
+ * @returns The body.
71
+ */
72
+ export declare function SidebarContent({ className, ...props }: ComponentProps<'div'>): import("react").JSX.Element;
73
+ /**
74
+ * The foot of a {@link Sidebar}, for the account, the collapse button or a status. In the `panel` variant it is
75
+ * hidden on the rail; in the `nav` variant it stays, with its labels faded.
76
+ *
77
+ * @param props - Any `div` props.
78
+ * @returns The footer.
79
+ */
80
+ export declare function SidebarFooter({ className, ...props }: ComponentProps<'div'>): import("react").JSX.Element | null;
@@ -0,0 +1,8 @@
1
+ /**
2
+ * A label beside an icon, after pargic's sidebar: while the sidebar narrows, the label slides 12 px to the right and
3
+ * fades as the edge covers it; while it widens, it slides back. The icon never moves. In a SidebarSheet the labels
4
+ * slide in the same way when the sheet opens.
5
+ */
6
+ export declare const fadingLabelClassName: string;
7
+ /** A row of a `nav` sidebar: a 36 px link or button with a 16 px icon, the accent colours when current. */
8
+ export declare const navRowClassName: string;
@@ -0,0 +1,20 @@
1
+ import { type ReactNode } from 'react';
2
+ /** Props of {@link CtaBand}. */
3
+ export interface CtaBandProps {
4
+ title: ReactNode;
5
+ body?: ReactNode;
6
+ /** Called with the email address when the user sends the form. */
7
+ onSubmit: (email: string) => void;
8
+ /** The field's accessible label and placeholder. Default "Work email". */
9
+ inputLabel?: string;
10
+ /** The button label. Default "Send". */
11
+ submitLabel?: string;
12
+ className?: string;
13
+ }
14
+ /**
15
+ * The CTABand pattern: a primary-colour band with a title and a one-field email form.
16
+ *
17
+ * @param props - Title, body, submit handler and labels.
18
+ * @returns The section.
19
+ */
20
+ export declare function CtaBand({ title, body, onSubmit, inputLabel, submitLabel, className }: CtaBandProps): import("react").JSX.Element;
@@ -0,0 +1,19 @@
1
+ import type { ReactNode } from 'react';
2
+ /** One question of a {@link Faq}. */
3
+ export interface FaqItem {
4
+ question: string;
5
+ answer: ReactNode;
6
+ }
7
+ /** Props of {@link Faq}. */
8
+ export interface FaqProps {
9
+ title: ReactNode;
10
+ items: readonly FaqItem[];
11
+ className?: string;
12
+ }
13
+ /**
14
+ * The FAQ pattern: a title and an accordion of questions. One answer opens at a time.
15
+ *
16
+ * @param props - Title and questions.
17
+ * @returns The section.
18
+ */
19
+ export declare function Faq({ title, items, className }: FaqProps): import("react").JSX.Element;
@@ -0,0 +1,22 @@
1
+ import type { ReactNode } from 'react';
2
+ /** One feature of a {@link FeatureGrid}. */
3
+ export interface Feature {
4
+ /** A 24 px lucide icon. It sits in a 44 px brand-soft tile. */
5
+ icon: ReactNode;
6
+ title: string;
7
+ body: string;
8
+ }
9
+ /** Props of {@link FeatureGrid}. */
10
+ export interface FeatureGridProps {
11
+ title?: ReactNode;
12
+ lead?: ReactNode;
13
+ features: readonly Feature[];
14
+ className?: string;
15
+ }
16
+ /**
17
+ * The FeatureGrid pattern: a section of feature cards on the canvas colour.
18
+ *
19
+ * @param props - Title, lead and features.
20
+ * @returns The section.
21
+ */
22
+ export declare function FeatureGrid({ title, lead, features, className }: FeatureGridProps): import("react").JSX.Element;
@@ -0,0 +1,20 @@
1
+ import type { ReactNode } from 'react';
2
+ /** Props of {@link Hero}. */
3
+ export interface HeroProps {
4
+ /** A short label over the title, on brand-soft. */
5
+ eyebrow?: ReactNode;
6
+ /** The headline, in DM Sans display. */
7
+ title: ReactNode;
8
+ /** The paragraph under the headline. */
9
+ lead?: ReactNode;
10
+ /** The calls to action, usually one primary and one outline large button. */
11
+ actions?: ReactNode;
12
+ className?: string;
13
+ }
14
+ /**
15
+ * The Hero pattern: the opening section of a website or product page.
16
+ *
17
+ * @param props - Eyebrow, title, lead and actions.
18
+ * @returns The hero section.
19
+ */
20
+ export declare function Hero({ eyebrow, title, lead, actions, className }: HeroProps): import("react").JSX.Element;
@@ -0,0 +1,22 @@
1
+ import type { ReactNode } from 'react';
2
+ /** One step of {@link HowItWorks}. */
3
+ export interface HowItWorksStep {
4
+ title: string;
5
+ body: string;
6
+ }
7
+ /** Props of {@link HowItWorks}. */
8
+ export interface HowItWorksProps {
9
+ title: ReactNode;
10
+ lead?: ReactNode;
11
+ /** A link under the lead, such as "How an engagement works". */
12
+ link?: ReactNode;
13
+ steps: readonly HowItWorksStep[];
14
+ className?: string;
15
+ }
16
+ /**
17
+ * The HowItWorks pattern: a title on one side and numbered steps on the other.
18
+ *
19
+ * @param props - Title, lead, link and steps.
20
+ * @returns The section.
21
+ */
22
+ export declare function HowItWorks({ title, lead, link, steps, className }: HowItWorksProps): import("react").JSX.Element;
package/web/index.d.ts ADDED
@@ -0,0 +1,20 @@
1
+ export { CtaBand } from './cta-band.component';
2
+ export type { CtaBandProps } from './cta-band.component';
3
+ export { Faq } from './faq.component';
4
+ export type { FaqItem, FaqProps } from './faq.component';
5
+ export { FeatureGrid } from './feature-grid.component';
6
+ export type { Feature, FeatureGridProps } from './feature-grid.component';
7
+ export { Hero } from './hero.component';
8
+ export type { HeroProps } from './hero.component';
9
+ export { HowItWorks } from './how-it-works.component';
10
+ export type { HowItWorksProps, HowItWorksStep } from './how-it-works.component';
11
+ export { MobileMenu } from './mobile-menu.component';
12
+ export type { MobileMenuLink, MobileMenuProps } from './mobile-menu.component';
13
+ export { PricingTable } from './pricing-table.component';
14
+ export type { Billing, PricingPlan, PricingTableProps } from './pricing-table.component';
15
+ export { ProductCard } from './product-card.component';
16
+ export type { ProductCardProps } from './product-card.component';
17
+ export { SiteFooter } from './site-footer.component';
18
+ export type { FooterColumn, SiteFooterProps } from './site-footer.component';
19
+ export { SiteHeader } from './site-header.component';
20
+ export type { SiteHeaderProps, SiteLink, SiteNavEntry } from './site-header.component';
@@ -0,0 +1,25 @@
1
+ import { type ReactNode } from 'react';
2
+ /** A link of the {@link MobileMenu}. */
3
+ export interface MobileMenuLink {
4
+ label: string;
5
+ href: string;
6
+ }
7
+ /** Props of {@link MobileMenu}. */
8
+ export interface MobileMenuProps {
9
+ links: readonly MobileMenuLink[];
10
+ /** The actions at the foot of the panel, such as Sign in and Talk to us. */
11
+ actions?: ReactNode;
12
+ /** The accessible name of the navigation. Default "Main". */
13
+ label?: string;
14
+ /** Classes for the toggle button, such as `md:hidden`. */
15
+ className?: string;
16
+ }
17
+ /**
18
+ * The mobile menu of a website. The panel grows out of the toggle as a circle while the page behind blurs and turns
19
+ * grey, and the links fade in one after another. The toggle twirls into an X and back. With reduced motion, the
20
+ * panel and the backdrop only fade.
21
+ *
22
+ * @param props - Links, actions, the navigation label and the toggle's classes.
23
+ * @returns The toggle, and the menu while it is open.
24
+ */
25
+ export declare function MobileMenu({ links, actions, label, className }: MobileMenuProps): import("react").JSX.Element;
@@ -0,0 +1,37 @@
1
+ import { type ReactNode } from 'react';
2
+ /** How often a plan is billed. */
3
+ export type Billing = 'monthly' | 'yearly';
4
+ /** One plan of a {@link PricingTable}. */
5
+ export interface PricingPlan {
6
+ name: string;
7
+ /** The price, the same for both billings, or one per billing. */
8
+ price: string | Readonly<Record<Billing, string>>;
9
+ blurb: string;
10
+ features: readonly string[];
11
+ cta: {
12
+ label: string;
13
+ href: string;
14
+ };
15
+ /** The plan most teams pick. It gets a brand border, a badge and the primary button. */
16
+ featured?: boolean;
17
+ }
18
+ /** Props of {@link PricingTable}. */
19
+ export interface PricingTableProps {
20
+ title: ReactNode;
21
+ lead?: ReactNode;
22
+ plans: readonly PricingPlan[];
23
+ /** The billing shown first. */
24
+ defaultBilling?: Billing;
25
+ /** A note under the plans, such as a placeholder warning. */
26
+ note?: ReactNode;
27
+ /** The featured badge text. Default "Most teams". */
28
+ featuredLabel?: string;
29
+ className?: string;
30
+ }
31
+ /**
32
+ * The PricingTable pattern: plan cards with a monthly and yearly switch.
33
+ *
34
+ * @param props - Title, lead, plans, first billing and note.
35
+ * @returns The section.
36
+ */
37
+ export declare function PricingTable({ title, lead, plans, defaultBilling, note, featuredLabel, className }: PricingTableProps): import("react").JSX.Element;
@@ -0,0 +1,20 @@
1
+ import type { Product } from '../tokens';
2
+ /** Props of {@link ProductCard}. */
3
+ export interface ProductCardProps {
4
+ /** The product. The card takes its accent, so a grid of cards shows each product's colour. */
5
+ product: Product;
6
+ /** Where the card links. */
7
+ href: string;
8
+ /** Replaces the catalogue tagline. */
9
+ description?: string;
10
+ /** Replaces the catalogue stage. */
11
+ stage?: string;
12
+ className?: string;
13
+ }
14
+ /**
15
+ * The ProductCard pattern: a linked card with a brand band, the logo, the name, one sentence and the stage.
16
+ *
17
+ * @param props - Product, link, and optional copy.
18
+ * @returns The card link.
19
+ */
20
+ export declare function ProductCard({ product, href, description, stage, className }: ProductCardProps): import("react").JSX.Element;
@@ -0,0 +1,25 @@
1
+ import type { ReactNode } from 'react';
2
+ /** A column of links in a {@link SiteFooter}. */
3
+ export interface FooterColumn {
4
+ title: string;
5
+ links: readonly {
6
+ label: string;
7
+ href: string;
8
+ }[];
9
+ }
10
+ /** Props of {@link SiteFooter}. */
11
+ export interface SiteFooterProps {
12
+ /** The line under the brand. */
13
+ tagline?: ReactNode;
14
+ columns: readonly FooterColumn[];
15
+ /** The bottom row, such as copyright and legal links. */
16
+ legal?: ReactNode;
17
+ className?: string;
18
+ }
19
+ /**
20
+ * The SiteFooter pattern: the brand and tagline, columns of links, and a legal row.
21
+ *
22
+ * @param props - Tagline, link columns and legal row.
23
+ * @returns The footer.
24
+ */
25
+ export declare function SiteFooter({ tagline, columns, legal, className }: SiteFooterProps): import("react").JSX.Element;
@@ -0,0 +1,32 @@
1
+ import type { ReactNode } from 'react';
2
+ /** A link in the site navigation. */
3
+ export interface SiteLink {
4
+ label: string;
5
+ href: string;
6
+ /** One line under the label, in a drop-down panel. */
7
+ description?: string;
8
+ }
9
+ /** A top-level entry of the site navigation: a link, or a drop-down of links. */
10
+ export interface SiteNavEntry {
11
+ label: string;
12
+ href?: string;
13
+ links?: readonly SiteLink[];
14
+ }
15
+ /** Props of {@link SiteHeader}. */
16
+ export interface SiteHeaderProps {
17
+ /** The main navigation. */
18
+ nav: readonly SiteNavEntry[];
19
+ /** The actions at the end, such as Sign in and Talk to us. */
20
+ actions?: ReactNode;
21
+ /** The brand at the start. Default the Talogic symbol and name, linking home. */
22
+ brand?: ReactNode;
23
+ className?: string;
24
+ }
25
+ /**
26
+ * The SiteHeader pattern: a sticky, blurred bar with the brand, the main navigation and the actions. Below
27
+ * 768 px the navigation moves into the animated {@link MobileMenu}.
28
+ *
29
+ * @param props - Navigation, actions and brand.
30
+ * @returns The header.
31
+ */
32
+ export declare function SiteHeader({ nav, actions, brand, className }: SiteHeaderProps): import("react").JSX.Element;