@alfadocs/ui-kit 0.42.0 → 0.43.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/_chunks/{ar-Cn_NxqkN.js → ar-DEz65ZJW.js} +2 -2
- package/dist/_chunks/bmi-calculator-DuVSFDuw.js +259 -0
- package/dist/_chunks/{booking-4mCw3Mpl.js → booking-CtLwaxkK.js} +4 -4
- package/dist/_chunks/{calculator-dialog-B74fqpFZ.js → calculator-dialog-DdexHrTP.js} +2 -2
- package/dist/_chunks/{chart-Cbt0_sKv.js → chart-Cg3e9EH9.js} +101 -99
- package/dist/_chunks/{cycle-calculator-DsZbyzX6.js → cycle-calculator-Dln-y1k_.js} +43 -42
- package/dist/_chunks/{date-picker-CvQfs6Xh.js → date-picker-Bq7xhMA-.js} +109 -108
- package/dist/_chunks/date-picker-variants-DLi1Va_e.js +3238 -0
- package/dist/_chunks/{date-range-picker-U9fn1g9d.js → date-range-picker-DcXuI9y7.js} +20 -19
- package/dist/_chunks/{date-time-picker-Cva0ZCWw.js → date-time-picker-RimumeLR.js} +18 -17
- package/dist/_chunks/{de-BMM2H7Bs.js → de-bTBGdjPS.js} +2 -2
- package/dist/_chunks/{dialog-Cee13rHU.js → dialog-DOYgd75U.js} +46 -37
- package/dist/_chunks/{due-date-calculator-s_CBgaFs.js → due-date-calculator-Cc4dRqTI.js} +46 -38
- package/dist/_chunks/{editable-currency-cell-renderer-BhUkRiPZ.js → editable-currency-cell-renderer-9jqwDv5x.js} +2 -2
- package/dist/_chunks/{el-BYPonAaK.js → el-BWG5RXxa.js} +6 -6
- package/dist/_chunks/{es-CMkVCQ4F.js → es-DfO_G435.js} +2 -2
- package/dist/_chunks/{fr-BcuWxqft.js → fr-BTn24bs8.js} +2 -2
- package/dist/_chunks/{gestation-BXEgDGmP.js → gestation-mWF4AXea.js} +3 -3
- package/dist/_chunks/{gestational-age-calculator-CWOG3bkI.js → gestational-age-calculator-ZMSrzkRW.js} +42 -41
- package/dist/_chunks/{header-CTZWX-tm.js → header-Ce1Br27u.js} +70 -75
- package/dist/_chunks/{hi-wkq_rQAh.js → hi-Dj3oYd84.js} +2 -2
- package/dist/_chunks/{insert-result-DtQQeSSf.js → insert-result-DisOY2G-.js} +91 -75
- package/dist/_chunks/{isSameWeek-Bim5ftRd.js → isSameWeek-HfxKk6Lz.js} +2 -2
- package/dist/_chunks/{it-GiQrQ9p4.js → it-Y85ofIQQ.js} +7 -7
- package/dist/_chunks/{ja-qfYg3Rua.js → ja-CQ7J6YoA.js} +2 -2
- package/dist/_chunks/{marketplace-app-shell-kVAVycz_.js → marketplace-app-shell-Dc5cTIt8.js} +186 -149
- package/dist/_chunks/{nl-xOogO4sZ.js → nl-D9kHCmp3.js} +2 -2
- package/dist/_chunks/{patient-shell-lDX3wwu6.js → patient-shell-CnT4L8gn.js} +2 -2
- package/dist/_chunks/{pl-GnOW6eGK.js → pl-B3Smqpkr.js} +3 -3
- package/dist/_chunks/{pregnancy-weight-gain-B7kBK-ZR.js → pregnancy-weight-gain-zZL5Ir2-.js} +49 -48
- package/dist/_chunks/{pt-_bV5b5RW.js → pt-D3J-1c_7.js} +6 -6
- package/dist/_chunks/{ro-BEcyh5Nj.js → ro-BKAbbEA3.js} +2 -2
- package/dist/_chunks/{ru-Bi86hqMf.js → ru-BeG8f0Ep.js} +3 -3
- package/dist/_chunks/{sign-document-QHfcNKFj.js → sign-document-B-3k_0LO.js} +165 -137
- package/dist/_chunks/{sq-BujHSAWu.js → sq-_hRPaeUy.js} +6 -6
- package/dist/_chunks/subDays-Dv7q9S7u.js +8 -0
- package/dist/_chunks/{sv-C8AeDrTA.js → sv-g009fSpe.js} +2 -2
- package/dist/_chunks/{tab-bar-C4II-7ej.js → tab-bar-Xetknddo.js} +53 -34
- package/dist/_chunks/{tr-CMSs_Vgf.js → tr-OKUOuhMW.js} +2 -2
- package/dist/_chunks/{unit-converter-D1UrEUxa.js → unit-converter-CuXCXJhK.js} +2 -2
- package/dist/_chunks/{zh-CN-eXB-PFu4.js → zh-CN-De4zwEhx.js} +3 -3
- package/dist/agent-catalog.json +1 -1
- package/dist/components/_shared/calendar-class-names.d.ts +8 -0
- package/dist/components/_shared/index.d.ts +2 -0
- package/dist/components/_shared/insert-result.d.ts +57 -2
- package/dist/components/badge/badge.d.ts +1 -1
- package/dist/components/bmi-calculator/index.js +1 -1
- package/dist/components/booking/index.js +1 -1
- package/dist/components/calculator-dialog/index.js +1 -1
- package/dist/components/card/card.d.ts +1 -1
- package/dist/components/chart/chart.d.ts +10 -0
- package/dist/components/chart/index.js +1 -1
- package/dist/components/cycle-calculator/index.js +1 -1
- package/dist/components/data-table/index.js +1 -1
- package/dist/components/date-picker/date-picker.d.ts +0 -1
- package/dist/components/date-picker/index.js +1 -1
- package/dist/components/date-range-picker/date-range-picker.d.ts +0 -1
- package/dist/components/date-range-picker/index.js +1 -1
- package/dist/components/date-time-picker/date-time-picker.d.ts +0 -1
- package/dist/components/date-time-picker/index.js +1 -1
- package/dist/components/dialog/index.js +1 -1
- package/dist/components/due-date-calculator/index.js +2 -2
- package/dist/components/gestational-age-calculator/index.js +1 -1
- package/dist/components/header/header.d.ts +8 -0
- package/dist/components/header/index.js +1 -1
- package/dist/components/index.d.ts +1 -1
- package/dist/components/pregnancy-weight-gain/index.js +1 -1
- package/dist/components/public-header/public-header.d.ts +1 -1
- package/dist/components/sign-document/index.js +1 -1
- package/dist/components/sign-document/sign-document.d.ts +12 -0
- package/dist/components/stat/stat.d.ts +1 -1
- package/dist/components/tab-bar/index.d.ts +1 -1
- package/dist/components/tab-bar/index.js +1 -1
- package/dist/components/tab-bar/tab-bar.d.ts +44 -1
- package/dist/components/unit-converter/index.js +1 -1
- package/dist/index.js +495 -494
- package/dist/patterns/marketplace-app-shell/index.js +1 -1
- package/dist/patterns/marketplace-app-shell/marketplace-app-shell.d.ts +57 -1
- package/dist/patterns/patient-shell/index.js +1 -1
- package/dist/tokens.css +1411 -2
- package/package.json +1 -1
- package/dist/_chunks/bmi-calculator-D4juUcyF.js +0 -219
- package/dist/_chunks/react-day-picker-CdtIiKjx.js +0 -3174
- package/dist/_chunks/subDays-_T9YeKPX.js +0 -8
|
@@ -5,7 +5,7 @@ import { useTranslation as G } from "react-i18next";
|
|
|
5
5
|
import { F as v } from "./form-field-BOm9hK35.js";
|
|
6
6
|
import { N as Y } from "./number-input-Dj5L3pXK.js";
|
|
7
7
|
import { S as y } from "./select-hsCaJSX3.js";
|
|
8
|
-
import { I as D } from "./insert-result-
|
|
8
|
+
import { I as D } from "./insert-result-DisOY2G-.js";
|
|
9
9
|
const F = {
|
|
10
10
|
// weight → base kg
|
|
11
11
|
kg: { id: "kg", category: "weight", factor: 1, offset: 0 },
|
|
@@ -171,4 +171,4 @@ export {
|
|
|
171
171
|
H as b,
|
|
172
172
|
M as c
|
|
173
173
|
};
|
|
174
|
-
//# sourceMappingURL=unit-converter-
|
|
174
|
+
//# sourceMappingURL=unit-converter-CuXCXJhK.js.map
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { i as u } from "./isSameWeek-
|
|
1
|
+
import { q as s, r as i, v as o, w as m } from "./date-picker-variants-DLi1Va_e.js";
|
|
2
|
+
import { i as u } from "./isSameWeek-HfxKk6Lz.js";
|
|
3
3
|
const c = {
|
|
4
4
|
lessThanXSeconds: {
|
|
5
5
|
one: "不到 1 秒",
|
|
@@ -385,4 +385,4 @@ const b = {
|
|
|
385
385
|
export {
|
|
386
386
|
Q as zhCN
|
|
387
387
|
};
|
|
388
|
-
//# sourceMappingURL=zh-CN-
|
|
388
|
+
//# sourceMappingURL=zh-CN-De4zwEhx.js.map
|
package/dist/agent-catalog.json
CHANGED
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import type { ClassNames } from 'react-day-picker';
|
|
2
|
+
/**
|
|
3
|
+
* Partial class-name map passed to every `<DayPicker classNames=…>` in the
|
|
4
|
+
* kit. Keyed by the rdp v9 enums so a future rdp upgrade surfaces missing
|
|
5
|
+
* keys at the type level.
|
|
6
|
+
*/
|
|
7
|
+
export declare const calendarClassNames: Partial<ClassNames>;
|
|
8
|
+
//# sourceMappingURL=calendar-class-names.d.ts.map
|
|
@@ -2,6 +2,7 @@ export { composeRefs } from './compose-refs';
|
|
|
2
2
|
export { isSafeImageSrc, safeImageSrc } from './safe-image-src';
|
|
3
3
|
export { SafeHtml, sanitiseHtml, type SafeHtmlProfile, type SafeHtmlProps, } from './safe-html';
|
|
4
4
|
export { groupOptions } from './group-options';
|
|
5
|
+
export { InsertButton, buildResultText, buildResultHtml, buildResultCardSvg, svgCardToPngDataUri, type InsertButtonProps, type InsertVariant, type InsertPayload, type InsertMode, type InsertCardData, type InsertCardField, type SvgCardToPngOptions, } from './insert-result';
|
|
5
6
|
export { normalizeDiacritics } from './normalize-diacritics';
|
|
6
7
|
export { useDebouncedCallback } from './use-debounced-callback';
|
|
7
8
|
export { useFocusTrap, type UseFocusTrapOptions } from './use-focus-trap';
|
|
@@ -11,6 +12,7 @@ export { INPUT_SURFACE_CHROME, INPUT_SURFACE_TONE, INPUT_SURFACE_HEIGHT, INPUT_S
|
|
|
11
12
|
export { getDateFnsLocale, getShortDateFormat, useDateFnsLocale, } from './date-locale';
|
|
12
13
|
export { buildDisabledMatcher } from './date-utils';
|
|
13
14
|
export { CalendarChevron } from './calendar-chevron';
|
|
15
|
+
export { calendarClassNames } from './calendar-class-names';
|
|
14
16
|
export { triggerVariants, calendarIconVariants, popoverContentVariants, presetButtonVariants, } from './date-picker-variants';
|
|
15
17
|
export type { OptionShape } from './option';
|
|
16
18
|
export type { TimeValue } from './time';
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { type ButtonProps } from '../button';
|
|
1
2
|
export type InsertMode = 'text' | 'image' | 'text-image';
|
|
2
3
|
export type InsertVariant = 'insert' | 'copy';
|
|
3
4
|
export interface InsertCardField {
|
|
@@ -19,10 +20,32 @@ export interface InsertPayload {
|
|
|
19
20
|
text: string;
|
|
20
21
|
/** Rich HTML summary (heading + list). Always present. */
|
|
21
22
|
html: string;
|
|
22
|
-
/**
|
|
23
|
+
/**
|
|
24
|
+
* Branded SVG result-card markup. Empty for mode `'text'`.
|
|
25
|
+
*
|
|
26
|
+
* Kept for back-compat and for callers that need the live, copy-pasteable
|
|
27
|
+
* vector. NOTE: SVG can carry `<script>` and is routinely stripped by
|
|
28
|
+
* rich-text sanitisers, so it is NOT the format to insert into an editor —
|
|
29
|
+
* use {@link InsertPayload.pngDataUri} for that.
|
|
30
|
+
*/
|
|
23
31
|
svg: string;
|
|
24
|
-
/**
|
|
32
|
+
/**
|
|
33
|
+
* SVG as an `image/svg+xml` data URI for `<img src>`. Empty for `'text'`.
|
|
34
|
+
*
|
|
35
|
+
* Same caveat as {@link InsertPayload.svg}: fine for a preview `<img>`, but a
|
|
36
|
+
* sanitiser-stripped vector once it reaches an editor. Prefer
|
|
37
|
+
* {@link InsertPayload.pngDataUri}.
|
|
38
|
+
*/
|
|
25
39
|
imageDataUri: string;
|
|
40
|
+
/**
|
|
41
|
+
* Async thunk that resolves the result-card to an `image/png` data URI —
|
|
42
|
+
* the format intended for editor insertion. PNG is a flat raster: it carries
|
|
43
|
+
* no script and survives the rich-text sanitiser that strips SVG. Resolves to
|
|
44
|
+
* an empty string for mode `'text'` (no image is built). The PNG is rendered
|
|
45
|
+
* lazily so the synchronous payload stays cheap; `await payload.pngDataUri()`
|
|
46
|
+
* only when you actually need the raster.
|
|
47
|
+
*/
|
|
48
|
+
pngDataUri: () => Promise<string>;
|
|
26
49
|
}
|
|
27
50
|
export interface InsertButtonProps {
|
|
28
51
|
/** Structured result used to build every payload representation. */
|
|
@@ -47,6 +70,12 @@ export interface InsertButtonProps {
|
|
|
47
70
|
onError?: (error: unknown) => void;
|
|
48
71
|
/** Trigger size. Defaults to `'sm'`. */
|
|
49
72
|
size?: 'sm' | 'md' | 'lg';
|
|
73
|
+
/**
|
|
74
|
+
* Visual intent of the three trigger buttons (text / image / text+image).
|
|
75
|
+
* Mirrors the `Button` `intent` prop and applies to every trigger uniformly
|
|
76
|
+
* so the three stay visually consistent. Defaults to `'primary'`.
|
|
77
|
+
*/
|
|
78
|
+
intent?: ButtonProps['intent'];
|
|
50
79
|
}
|
|
51
80
|
interface ThemeColours {
|
|
52
81
|
fg: string;
|
|
@@ -59,6 +88,32 @@ interface ThemeColours {
|
|
|
59
88
|
export declare function buildResultText(card: InsertCardData): string;
|
|
60
89
|
export declare function buildResultHtml(card: InsertCardData): string;
|
|
61
90
|
export declare function buildResultCardSvg(card: InsertCardData, c: ThemeColours): string;
|
|
91
|
+
/** Options for {@link svgCardToPngDataUri}. */
|
|
92
|
+
export interface SvgCardToPngOptions {
|
|
93
|
+
/**
|
|
94
|
+
* Resolved theme colours to paint into the card. When omitted, the card
|
|
95
|
+
* renders with `currentColor` / transparent fallbacks (see
|
|
96
|
+
* {@link buildResultCardSvg}) — pass sampled colours for a branded raster.
|
|
97
|
+
*/
|
|
98
|
+
colours?: ThemeColours;
|
|
99
|
+
/**
|
|
100
|
+
* Device-pixel scale factor for the raster. `2` yields a retina-sharp PNG.
|
|
101
|
+
* Defaults to `1`.
|
|
102
|
+
*/
|
|
103
|
+
scale?: number;
|
|
104
|
+
}
|
|
105
|
+
/**
|
|
106
|
+
* Render an {@link InsertCardData} result card to an `image/png` data URI.
|
|
107
|
+
*
|
|
108
|
+
* This is the format intended for editor insertion: a flat raster carries no
|
|
109
|
+
* `<script>` and survives the rich-text sanitiser that strips inline SVG. The
|
|
110
|
+
* card is built as SVG, loaded into an `<img>`, painted onto a canvas at the
|
|
111
|
+
* card's intrinsic size (optionally scaled), and read back as `image/png`.
|
|
112
|
+
*
|
|
113
|
+
* Browser-only — relies on `Image`, `<canvas>`, and `canvas.toBlob`. Throws if
|
|
114
|
+
* called in a non-DOM context or if the SVG fails to decode.
|
|
115
|
+
*/
|
|
116
|
+
export declare function svgCardToPngDataUri(card: InsertCardData, opts?: SvgCardToPngOptions): Promise<string>;
|
|
62
117
|
export declare const InsertButton: import("react").ForwardRefExoticComponent<InsertButtonProps & import("react").RefAttributes<HTMLDivElement>>;
|
|
63
118
|
export {};
|
|
64
119
|
//# sourceMappingURL=insert-result.d.ts.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { type ReactNode } from 'react';
|
|
2
2
|
import { type VariantProps } from 'class-variance-authority';
|
|
3
3
|
declare const badgeVariants: (props?: ({
|
|
4
|
-
variant?: "error" | "neutral" | "info" | "success" | "warning" | "brand" |
|
|
4
|
+
variant?: "error" | "accent" | "neutral" | "info" | "success" | "warning" | "brand" | null | undefined;
|
|
5
5
|
size?: "sm" | "md" | "lg" | null | undefined;
|
|
6
6
|
shape?: "pill" | "rectangular" | null | undefined;
|
|
7
7
|
} & import("class-variance-authority/types").ClassProp) | undefined) => string;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { B as m } from "../../_chunks/bmi-calculator-
|
|
1
|
+
import { B as m } from "../../_chunks/bmi-calculator-DuVSFDuw.js";
|
|
2
2
|
import { b as e, a as t, c as r, d as T, e as c, f as i, i as b, k as n, l as f } from "../../_chunks/bmi-BxD-tFzU.js";
|
|
3
3
|
export {
|
|
4
4
|
m as BmiCalculator,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { type HTMLAttributes, type ReactNode } from 'react';
|
|
2
2
|
import { type VariantProps } from 'class-variance-authority';
|
|
3
3
|
declare const cardVariants: (props?: ({
|
|
4
|
-
variant?: "default" | "
|
|
4
|
+
variant?: "default" | "outlined" | "elevated" | null | undefined;
|
|
5
5
|
interactive?: boolean | null | undefined;
|
|
6
6
|
stretch?: boolean | null | undefined;
|
|
7
7
|
} & import("class-variance-authority/types").ClassProp) | undefined) => string;
|
|
@@ -29,6 +29,16 @@ export interface ChartProps extends VariantProps<typeof chartVariants> {
|
|
|
29
29
|
width?: number | string;
|
|
30
30
|
/** Opt-in pattern fills for colour-blind users. */
|
|
31
31
|
patterns?: boolean;
|
|
32
|
+
/**
|
|
33
|
+
* Override the series colour ramp. Pass **already-resolved** colour strings
|
|
34
|
+
* (e.g. the live value of `var(--success)` sampled by the consumer) — these
|
|
35
|
+
* are handed straight to ApexCharts, which can't read CSS custom properties.
|
|
36
|
+
* When omitted, the theme bridge's `colors` ramp from `apexcharts-theme.ts`
|
|
37
|
+
* is used, so existing consumers are unaffected. Typical use: a single-arc
|
|
38
|
+
* `radialBar` gauge (e.g. BMI) that must change hue with the value —
|
|
39
|
+
* green in the healthy band, amber/red outside it.
|
|
40
|
+
*/
|
|
41
|
+
colors?: string[];
|
|
32
42
|
/** Show the ApexCharts toolbar. Defaults to false. */
|
|
33
43
|
toolbar?: boolean;
|
|
34
44
|
/** Locale override — defaults to the active i18next language. */
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { A as l, B as r, C as t, a as s, D as n, b as d, c as i, d as o, E as C, e as R, I as F, L as g, N as T, f as b, S as u, g as c, h as D, T as m, i as p, j as x, k as f, l as y, m as E, n as S, o as h, U as A, p as L, q as N, u as k } from "../../_chunks/editable-currency-cell-renderer-
|
|
1
|
+
import { A as l, B as r, C as t, a as s, D as n, b as d, c as i, d as o, E as C, e as R, I as F, L as g, N as T, f as b, S as u, g as c, h as D, T as m, i as p, j as x, k as f, l as y, m as E, n as S, o as h, U as A, p as L, q as N, u as k } from "../../_chunks/editable-currency-cell-renderer-9jqwDv5x.js";
|
|
2
2
|
export {
|
|
3
3
|
l as ActionsCellRenderer,
|
|
4
4
|
r as BalanceCellRenderer,
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { type VariantProps } from 'class-variance-authority';
|
|
2
2
|
import { triggerVariants } from '../_shared';
|
|
3
|
-
import '../../tokens/themes/bridges/react-day-picker.css';
|
|
4
3
|
/** Curated imperative handle exposed via `ref` — also consumed by the agent adapter. */
|
|
5
4
|
export interface DatePickerHandle {
|
|
6
5
|
/** Get the current selected date, or undefined. */
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { type VariantProps } from 'class-variance-authority';
|
|
2
2
|
import { triggerVariants } from '../_shared';
|
|
3
|
-
import '../../tokens/themes/bridges/react-day-picker.css';
|
|
4
3
|
/** Curated imperative handle exposed via `ref` — also consumed by the agent adapter. */
|
|
5
4
|
export interface DateTimePickerHandle {
|
|
6
5
|
/** Get the current selected datetime, or undefined. */
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { D as s } from "../../_chunks/due-date-calculator-
|
|
2
|
-
import { D as E, G as o, M as D, T as r, c as T, g as _, t as C } from "../../_chunks/gestation-
|
|
1
|
+
import { D as s } from "../../_chunks/due-date-calculator-Cc4dRqTI.js";
|
|
2
|
+
import { D as E, G as o, M as D, T as r, c as T, g as _, t as C } from "../../_chunks/gestation-mWF4AXea.js";
|
|
3
3
|
export {
|
|
4
4
|
E as DEFAULT_CYCLE_LENGTH,
|
|
5
5
|
s as DueDateCalculator,
|
|
@@ -21,6 +21,14 @@ export interface HeaderBrandProps extends Omit<AnchorHTMLAttributes<HTMLAnchorEl
|
|
|
21
21
|
children?: ReactNode;
|
|
22
22
|
/** Destination href. Defaults to "/". */
|
|
23
23
|
href?: string;
|
|
24
|
+
/**
|
|
25
|
+
* Render through Radix `Slot` so a consumer's router link (`<Link>`) takes
|
|
26
|
+
* over the brand anchor while keeping the kit's `brandVariants` styling and
|
|
27
|
+
* any forwarded `aria-label`. Pass a single link element as `children` (the
|
|
28
|
+
* logo + wordmark go inside it). With `asChild` off the output is the plain
|
|
29
|
+
* `<a href>` exactly as before.
|
|
30
|
+
*/
|
|
31
|
+
asChild?: boolean;
|
|
24
32
|
}
|
|
25
33
|
export declare const HeaderBrand: import("react").ForwardRefExoticComponent<HeaderBrandProps & import("react").RefAttributes<HTMLAnchorElement>>;
|
|
26
34
|
export declare function HeaderBrandDivider({ className, ...props }: HTMLAttributes<HTMLSpanElement>): ReactNode;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { H as r, a as d, b as H, c as s, d as n, e as t, f as i, g as o } from "../../_chunks/header-
|
|
1
|
+
import { H as r, a as d, b as H, c as s, d as n, e as t, f as i, g as o } from "../../_chunks/header-Ce1Br27u.js";
|
|
2
2
|
export {
|
|
3
3
|
r as Header,
|
|
4
4
|
d as HeaderBrand,
|
|
@@ -39,7 +39,7 @@ export * from './switch';
|
|
|
39
39
|
export * from './text-area';
|
|
40
40
|
export * from './text-input';
|
|
41
41
|
export * from './time-picker';
|
|
42
|
-
export { InsertButton, type InsertButtonProps, type InsertVariant, type InsertPayload, type InsertMode, type InsertCardData, type InsertCardField, } from './_shared/insert-result';
|
|
42
|
+
export { InsertButton, svgCardToPngDataUri, type InsertButtonProps, type InsertVariant, type InsertPayload, type InsertMode, type InsertCardData, type InsertCardField, type SvgCardToPngOptions, } from './_shared/insert-result';
|
|
43
43
|
export * from './accordion';
|
|
44
44
|
export * from './avatar';
|
|
45
45
|
export * from './badge';
|
|
@@ -65,7 +65,7 @@ export interface PublicHeaderDropdownLinkProps extends Omit<AnchorHTMLAttributes
|
|
|
65
65
|
children: ReactNode;
|
|
66
66
|
}
|
|
67
67
|
declare const rootVariants: (props?: ({
|
|
68
|
-
variant?: "dark" | "
|
|
68
|
+
variant?: "dark" | "transparent" | "pill" | null | undefined;
|
|
69
69
|
sticky?: "none" | "top" | "scroll-up" | null | undefined;
|
|
70
70
|
} & import("class-variance-authority/types").ClassProp) | undefined) => string;
|
|
71
71
|
export declare const PublicHeader: import("react").ForwardRefExoticComponent<PublicHeaderProps & import("react").RefAttributes<HTMLElement>> & {
|
|
@@ -23,6 +23,18 @@ export interface SignDocumentProps {
|
|
|
23
23
|
* that surface signed status. `null` / `undefined` → unsigned.
|
|
24
24
|
*/
|
|
25
25
|
signedAt?: string | null;
|
|
26
|
+
/**
|
|
27
|
+
* Optional on-behalf attribution. When both `signer` and `subject` are
|
|
28
|
+
* given, a "Signed by {signer} on behalf of {subject}" note renders both
|
|
29
|
+
* near the signature pad (so the signer sees who they're signing for) AND
|
|
30
|
+
* inside the already-signed read-only banner. Omit (the default) and
|
|
31
|
+
* nothing extra renders — the existing subject-agnostic API is unchanged.
|
|
32
|
+
* Provide both to opt in; a lone `signer` or `subject` renders nothing.
|
|
33
|
+
*/
|
|
34
|
+
signedByNote?: {
|
|
35
|
+
signer: string;
|
|
36
|
+
subject: string;
|
|
37
|
+
};
|
|
26
38
|
/** Disable all controls (document still readable). */
|
|
27
39
|
disabled?: boolean;
|
|
28
40
|
/** Render read-only: the document is shown but the pad is suppressed. */
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { type HTMLAttributes, type ReactNode } from 'react';
|
|
2
2
|
import { type VariantProps } from 'class-variance-authority';
|
|
3
3
|
declare const statVariants: (props?: ({
|
|
4
|
-
variant?: "default" | "compact" | "
|
|
4
|
+
variant?: "default" | "compact" | "outlined" | "elevated" | null | undefined;
|
|
5
5
|
size?: "sm" | "md" | "lg" | null | undefined;
|
|
6
6
|
align?: "center" | "end" | "start" | null | undefined;
|
|
7
7
|
} & import("class-variance-authority/types").ClassProp) | undefined) => string;
|
|
@@ -20,8 +20,16 @@
|
|
|
20
20
|
* otherwise (in-app view switching via `onSelect`). Use it as a header (top,
|
|
21
21
|
* default) for section navigation; `position="bottom"` floats it from the
|
|
22
22
|
* bottom edge for a footer.
|
|
23
|
+
*
|
|
24
|
+
* SPA / consumer-router links: pass `renderLink` and TabBar hands each `href`
|
|
25
|
+
* tab off to your router's `<Link>` instead of rendering its own `<a>` — the
|
|
26
|
+
* embedded MarketplaceAppShell strip uses this so a tab click is a client-side
|
|
27
|
+
* route change, not a full page navigation. The kit forwards the same
|
|
28
|
+
* `className` + `aria-current` so the accent-underline active styling and the
|
|
29
|
+
* `aria-current="page"` marker survive in both modes. With `renderLink`
|
|
30
|
+
* omitted the output is the plain `<a href>` exactly as before.
|
|
23
31
|
*/
|
|
24
|
-
import { type ReactNode } from 'react';
|
|
32
|
+
import { type MouseEvent, type ReactNode } from 'react';
|
|
25
33
|
export interface TabBarItem {
|
|
26
34
|
/** Stable id; also the value handed to `onSelect` for button tabs. */
|
|
27
35
|
id: string;
|
|
@@ -35,6 +43,30 @@ export interface TabBarItem {
|
|
|
35
43
|
isActive?: boolean;
|
|
36
44
|
/** When set, the tab renders as a link to this href; otherwise it's a button. */
|
|
37
45
|
href?: string;
|
|
46
|
+
/**
|
|
47
|
+
* Optional click handler threaded onto the link tab's `<a>` (or, when
|
|
48
|
+
* `renderLink` is supplied, available to the consumer's router element). Use
|
|
49
|
+
* it to intercept a same-origin click and route client-side without a full
|
|
50
|
+
* navigation. Only applies to `href` (link) tabs — button tabs use `onSelect`.
|
|
51
|
+
*/
|
|
52
|
+
onClick?: (event: MouseEvent<HTMLAnchorElement>) => void;
|
|
53
|
+
}
|
|
54
|
+
/**
|
|
55
|
+
* Props the kit hands to `renderLink` for each `href` tab. The consumer returns
|
|
56
|
+
* their router's `<Link to={href}>` carrying the same `className` (the active
|
|
57
|
+
* accent-underline styling) and `aria-current` (`'page'` on the active tab).
|
|
58
|
+
*/
|
|
59
|
+
export interface TabBarRenderLinkProps {
|
|
60
|
+
/** The tab's destination — feed it to your router's `to` / `href`. */
|
|
61
|
+
href: string;
|
|
62
|
+
/** The kit's tab classes (CVA output) — apply verbatim to the link element. */
|
|
63
|
+
className: string;
|
|
64
|
+
/** Icon + label + badge — render as the link's children. */
|
|
65
|
+
children: ReactNode;
|
|
66
|
+
/** `'page'` on the active tab, otherwise omitted — forward to the link. */
|
|
67
|
+
'aria-current'?: 'page';
|
|
68
|
+
/** Optional per-item click handler (the item's `onClick`), if supplied. */
|
|
69
|
+
onClick?: (event: MouseEvent<HTMLAnchorElement>) => void;
|
|
38
70
|
}
|
|
39
71
|
export interface TabBarProps {
|
|
40
72
|
/** The tabs, in order. */
|
|
@@ -43,6 +75,17 @@ export interface TabBarProps {
|
|
|
43
75
|
ariaLabel: string;
|
|
44
76
|
/** Fires with the tab `id` when a button tab (one without `href`) is chosen. */
|
|
45
77
|
onSelect?: (id: string) => void;
|
|
78
|
+
/**
|
|
79
|
+
* Render an `href` tab via the consumer's router instead of the kit's own
|
|
80
|
+
* `<a>`. TabBar calls it for each link tab and renders the returned node; the
|
|
81
|
+
* consumer returns their `<Link to={href}>` carrying the supplied `className`
|
|
82
|
+
* + `aria-current` so the active accent underline and the `aria-current="page"`
|
|
83
|
+
* marker are preserved. Use it for SPA navigation (e.g. the MarketplaceAppShell
|
|
84
|
+
* strip) so a tab click is a client-side route change, not a full page load.
|
|
85
|
+
* Omit it to render the plain `<a href>` exactly as before. Button tabs (no
|
|
86
|
+
* `href`) ignore `renderLink` and continue to use `onSelect`.
|
|
87
|
+
*/
|
|
88
|
+
renderLink?: (props: TabBarRenderLinkProps) => ReactNode;
|
|
46
89
|
/**
|
|
47
90
|
* Equal-width tabs that fill the bar and always stack the label under the
|
|
48
91
|
* icon (for a fixed, always-visible set). Off (default) = content-width tabs
|