@alfadocs/ui-kit 0.43.0 → 0.45.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/{alia-sidebar-BpX4z_af.js → alia-sidebar-Be8FhKYd.js} +332 -237
- package/dist/_chunks/{autocomplete-DIgdhCGJ.js → autocomplete-CDqxB68B.js} +2 -2
- package/dist/_chunks/bmi-calculator-CQqXTVNL.js +258 -0
- package/dist/_chunks/{booking-CtLwaxkK.js → booking-DlDVuWMd.js} +2 -2
- package/dist/_chunks/{calculator-dialog-DdexHrTP.js → calculator-dialog-D-nfvteH.js} +2 -2
- package/dist/_chunks/{cycle-calculator-Dln-y1k_.js → cycle-calculator-KxA8dqDf.js} +73 -54
- package/dist/_chunks/dialog-BTpZV6It.js +223 -0
- package/dist/_chunks/{due-date-calculator-Cc4dRqTI.js → due-date-calculator-mFxpHLml.js} +73 -49
- package/dist/_chunks/{editable-currency-cell-renderer-9jqwDv5x.js → editable-currency-cell-renderer-BEBUQl9P.js} +2 -2
- package/dist/_chunks/{freemium-paywall-BLXESpH4.js → freemium-paywall-BYist2sJ.js} +2 -2
- package/dist/_chunks/gestational-age-calculator-gWI_uRA1.js +203 -0
- package/dist/_chunks/insert-result-C5ABnzDl.js +711 -0
- package/dist/_chunks/{marketplace-app-shell-Dc5cTIt8.js → marketplace-app-shell-Gfsf78ge.js} +2 -2
- package/dist/_chunks/{patient-search-DPe2ZYEL.js → patient-search-CocVcGJ3.js} +2 -2
- package/dist/_chunks/{payment-form-BzVsG6Ks.js → payment-form-DqEiEJRO.js} +247 -195
- package/dist/_chunks/{pdf-viewer-B6MC6VTx.js → pdf-viewer-CWEXTlwq.js} +2 -2
- package/dist/_chunks/{practice-results-CrLpEiiW.js → practice-results-DDi-kvaD.js} +2 -2
- package/dist/_chunks/{pregnancy-weight-gain-zZL5Ir2-.js → pregnancy-weight-gain-BtEHaSqy.js} +78 -56
- package/dist/_chunks/{search-bar-CP6wUJFY.js → search-bar-CvN_S0jW.js} +2 -2
- package/dist/_chunks/{search-input-C1C3jQpD.js → search-input-D3aMvi4l.js} +2 -2
- package/dist/_chunks/{sign-document-B-3k_0LO.js → sign-document-BCyLpFHJ.js} +2 -2
- package/dist/_chunks/{sign-in-with-alfadocs-button-DeHBFRNS.js → sign-in-with-alfadocs-button-CuYn_kKP.js} +2 -2
- package/dist/_chunks/{social-sign-in-button-X54ySJr1.js → social-sign-in-button-uJYLM366.js} +2 -2
- package/dist/_chunks/{spinner-CCByyvcb.js → spinner-OjQNn8oN.js} +7 -3
- package/dist/_chunks/{transcript-panel-CR7VY1uw.js → transcript-panel-B4HiC7ed.js} +2 -2
- package/dist/_chunks/{unit-converter-CuXCXJhK.js → unit-converter-u3CwNDpP.js} +96 -74
- package/dist/_chunks/{wallet-pay-button-DK4ESYge.js → wallet-pay-button-DuDPBlCO.js} +2 -2
- package/dist/agent-catalog.json +1 -1
- package/dist/components/_shared/banded-gauge.d.ts +193 -0
- package/dist/components/_shared/index.d.ts +1 -1
- package/dist/components/_shared/insert-result.d.ts +173 -10
- package/dist/components/autocomplete/index.js +1 -1
- package/dist/components/bmi-calculator/bmi-calculator.d.ts +6 -0
- 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/cycle-calculator/cycle-calculator.d.ts +6 -0
- package/dist/components/cycle-calculator/index.js +1 -1
- package/dist/components/data-table/index.js +1 -1
- package/dist/components/dialog/dialog.d.ts +1 -0
- package/dist/components/dialog/index.js +1 -1
- package/dist/components/due-date-calculator/due-date-calculator.d.ts +6 -0
- package/dist/components/due-date-calculator/index.js +1 -1
- package/dist/components/freemium-paywall/index.js +1 -1
- package/dist/components/gestational-age-calculator/gestational-age-calculator.d.ts +6 -0
- package/dist/components/gestational-age-calculator/index.js +1 -1
- package/dist/components/index.d.ts +1 -1
- package/dist/components/patient-search/index.js +1 -1
- package/dist/components/payment-form/index.js +1 -1
- package/dist/components/payment-form/payment-form.d.ts +24 -2
- package/dist/components/pdf-viewer/index.js +1 -1
- package/dist/components/practice-results/index.js +1 -1
- package/dist/components/pregnancy-weight-gain/index.js +1 -1
- package/dist/components/pregnancy-weight-gain/pregnancy-weight-gain.d.ts +6 -0
- package/dist/components/search-bar/index.js +1 -1
- package/dist/components/search-input/index.js +1 -1
- package/dist/components/sign-document/index.js +1 -1
- package/dist/components/sign-in-with-alfadocs-button/index.js +1 -1
- package/dist/components/social-sign-in-button/index.js +1 -1
- package/dist/components/spinner/index.js +1 -1
- package/dist/components/spinner/spinner.d.ts +2 -2
- package/dist/components/transcript-panel/index.js +1 -1
- package/dist/components/unit-converter/index.js +1 -1
- package/dist/components/unit-converter/unit-converter.d.ts +6 -0
- package/dist/components/wallet-pay-button/index.js +1 -1
- package/dist/i18n/locales/ar.d.ts +1 -1
- package/dist/i18n/locales/ar.js +1 -1
- package/dist/i18n/locales/de.d.ts +1 -1
- package/dist/i18n/locales/de.js +1 -1
- package/dist/i18n/locales/el.d.ts +1 -1
- package/dist/i18n/locales/el.js +1 -1
- package/dist/i18n/locales/en.d.ts +1 -1
- package/dist/i18n/locales/en.js +1 -1
- package/dist/i18n/locales/es.d.ts +1 -1
- package/dist/i18n/locales/es.js +1 -1
- package/dist/i18n/locales/fr.d.ts +1 -1
- package/dist/i18n/locales/fr.js +1 -1
- package/dist/i18n/locales/hi.d.ts +1 -1
- package/dist/i18n/locales/hi.js +1 -1
- package/dist/i18n/locales/it.d.ts +1 -1
- package/dist/i18n/locales/it.js +1 -1
- package/dist/i18n/locales/ja.d.ts +1 -1
- package/dist/i18n/locales/ja.js +1 -1
- package/dist/i18n/locales/nl.d.ts +1 -1
- package/dist/i18n/locales/nl.js +1 -1
- package/dist/i18n/locales/pl.d.ts +1 -1
- package/dist/i18n/locales/pl.js +1 -1
- package/dist/i18n/locales/pt.d.ts +1 -1
- package/dist/i18n/locales/pt.js +1 -1
- package/dist/i18n/locales/ro.d.ts +1 -1
- package/dist/i18n/locales/ro.js +1 -1
- package/dist/i18n/locales/ru.d.ts +1 -1
- package/dist/i18n/locales/ru.js +1 -1
- package/dist/i18n/locales/sq.d.ts +1 -1
- package/dist/i18n/locales/sq.js +1 -1
- package/dist/i18n/locales/sv.d.ts +1 -1
- package/dist/i18n/locales/sv.js +1 -1
- package/dist/i18n/locales/tr.d.ts +1 -1
- package/dist/i18n/locales/tr.js +1 -1
- package/dist/i18n/locales/zh.d.ts +1 -1
- package/dist/i18n/locales/zh.js +1 -1
- package/dist/index.js +497 -496
- package/dist/locales/ar.json +1 -1
- package/dist/locales/de.json +1 -1
- package/dist/locales/el.json +1 -1
- package/dist/locales/en.json +1 -1
- package/dist/locales/es.json +1 -1
- package/dist/locales/fr.json +1 -1
- package/dist/locales/hi.json +1 -1
- package/dist/locales/it.json +1 -1
- package/dist/locales/ja.json +1 -1
- package/dist/locales/nl.json +1 -1
- package/dist/locales/pl.json +1 -1
- package/dist/locales/pt.json +1 -1
- package/dist/locales/ro.json +1 -1
- package/dist/locales/ru.json +1 -1
- package/dist/locales/sq.json +1 -1
- package/dist/locales/sv.json +1 -1
- package/dist/locales/tr.json +1 -1
- package/dist/locales/zh.json +1 -1
- package/dist/patterns/alia-assistant/alia-types.d.ts +20 -0
- package/dist/patterns/alia-assistant/index.js +1 -1
- package/dist/patterns/marketplace-app-shell/index.js +1 -1
- package/dist/tokens.css +1 -1
- package/package.json +1 -1
- package/dist/_chunks/bmi-calculator-DuVSFDuw.js +0 -259
- package/dist/_chunks/dialog-DOYgd75U.js +0 -224
- package/dist/_chunks/gestational-age-calculator-ZMSrzkRW.js +0 -179
- package/dist/_chunks/insert-result-DisOY2G-.js +0 -243
|
@@ -1,17 +1,139 @@
|
|
|
1
1
|
import { type ButtonProps } from '../button';
|
|
2
|
+
import { type BandedGaugeBand } from './banded-gauge';
|
|
2
3
|
export type InsertMode = 'text' | 'image' | 'text-image';
|
|
3
4
|
export type InsertVariant = 'insert' | 'copy';
|
|
5
|
+
/**
|
|
6
|
+
* The handful of lucide glyphs the result-card header can carry. Each maps to a
|
|
7
|
+
* static native-SVG geometry string in {@link ICON_GEOMETRY}, hand-transcribed
|
|
8
|
+
* from lucide-react 1.8.0's `__iconNode` arrays (pinned to that version so the
|
|
9
|
+
* paths match the on-screen React glyphs exactly). We do NOT import the lucide
|
|
10
|
+
* React components into the raster path — they can't be serialised into the
|
|
11
|
+
* `<img>` data-URI — so the geometry is inlined as raw `<path>` elements.
|
|
12
|
+
*/
|
|
13
|
+
export type IconKey = 'activity' | 'scale' | 'ruler' | 'calendar' | 'calendar-heart' | 'baby' | 'heart' | 'droplets' | 'clock' | 'tag' | 'trending-up' | 'percent';
|
|
4
14
|
export interface InsertCardField {
|
|
5
15
|
label: string;
|
|
6
16
|
value: string;
|
|
17
|
+
/**
|
|
18
|
+
* Optional leading glyph for the row, drawn at {@link FIELD_ICON_SLOT} in
|
|
19
|
+
* place of the default bullet dot. One of the known {@link IconKey} names; an
|
|
20
|
+
* unknown / omitted value falls back to the muted bullet (fully
|
|
21
|
+
* back-compatible — a field without an icon renders exactly as before).
|
|
22
|
+
*/
|
|
23
|
+
icon?: IconKey;
|
|
7
24
|
}
|
|
25
|
+
/**
|
|
26
|
+
* Radial gauge — a hand-rolled native-SVG donut (track `<circle>` + value arc
|
|
27
|
+
* via `stroke-dasharray`) drawn in the card's inline-end corner box. Survives
|
|
28
|
+
* the `<img>` → `<canvas>` → `toBlob` raster. No `<foreignObject>`, no charting
|
|
29
|
+
* lib.
|
|
30
|
+
*
|
|
31
|
+
* This is the original gauge shape; `variant` is optional and defaults to
|
|
32
|
+
* `'radial'`, so a gauge object authored before the banded variant existed
|
|
33
|
+
* renders exactly as before.
|
|
34
|
+
*/
|
|
35
|
+
export interface InsertCardRadialGauge {
|
|
36
|
+
/** Discriminant. Optional — omitted means `'radial'` (back-compat). */
|
|
37
|
+
variant?: 'radial';
|
|
38
|
+
/** Big number rendered in the gauge centre (e.g. `'22.4'`). */
|
|
39
|
+
value: string;
|
|
40
|
+
/**
|
|
41
|
+
* Filled fraction of the ring, `0`–`1`. Takes precedence when supplied;
|
|
42
|
+
* otherwise derived from a `value`/`max` numeric parse (falling back to a
|
|
43
|
+
* full ring when neither is numeric).
|
|
44
|
+
*/
|
|
45
|
+
fraction?: number;
|
|
46
|
+
/** Denominator used to derive `fraction` when `fraction` is omitted. */
|
|
47
|
+
max?: number;
|
|
48
|
+
/**
|
|
49
|
+
* Number of evenly-spaced segment gaps to notch into the ring (e.g. `4` for
|
|
50
|
+
* a quartered dial). `0`/omitted draws a continuous arc.
|
|
51
|
+
*/
|
|
52
|
+
segments?: number;
|
|
53
|
+
/**
|
|
54
|
+
* DS token NAME for the arc colour — e.g. `'--success'`, `'--warning'`,
|
|
55
|
+
* `'--destructive'`, `'--info'`, or the light-orange overweight override.
|
|
56
|
+
* Resolved to a concrete colour from a probe span at raster time; never a
|
|
57
|
+
* hex literal in source.
|
|
58
|
+
*/
|
|
59
|
+
colorToken: string;
|
|
60
|
+
/** Small category label under the value inside the ring. */
|
|
61
|
+
label?: string;
|
|
62
|
+
}
|
|
63
|
+
/**
|
|
64
|
+
* Banded gauge — a full-width horizontal track split into coloured zones with a
|
|
65
|
+
* marker at the value's position (the WHO BMI dial, drawn via the shared
|
|
66
|
+
* `banded-gauge` module). It spans the card edge-to-edge below the field rows.
|
|
67
|
+
* Same raster-safety guarantees as the radial donut: pure native SVG, no
|
|
68
|
+
* `<foreignObject>`.
|
|
69
|
+
*
|
|
70
|
+
* Every visible string (`valueLabel`, `categoryLabel`, `rangeLabel`,
|
|
71
|
+
* `ariaLabel`) arrives ALREADY TRANSLATED — the calculator supplies `t()`-
|
|
72
|
+
* resolved text. Every band's `colorToken` is registered for probe sampling so
|
|
73
|
+
* the baked raster carries theme-correct fills.
|
|
74
|
+
*/
|
|
75
|
+
export interface InsertCardBandedGauge {
|
|
76
|
+
/** Discriminant for the banded layout. */
|
|
77
|
+
variant: 'banded';
|
|
78
|
+
/** The true value (printed verbatim even when clamped to a bar end). */
|
|
79
|
+
value: number;
|
|
80
|
+
/** Ascending coloured zones; the last `upTo` should equal `max`. */
|
|
81
|
+
bands: BandedGaugeBand[];
|
|
82
|
+
/** Low end of the drawn scale (maps to the bar's inline start). */
|
|
83
|
+
min: number;
|
|
84
|
+
/** High end of the drawn scale (maps to the bar's inline end). */
|
|
85
|
+
max: number;
|
|
86
|
+
/** Big number rendered above the marker (e.g. `'24.6'`). */
|
|
87
|
+
valueLabel: string;
|
|
88
|
+
/** Band name shown beside the value (e.g. `'normal'`). Pre-translated. */
|
|
89
|
+
categoryLabel?: string;
|
|
90
|
+
/** Range string for the band (e.g. `'18.5–24.9'`). Pre-translated. */
|
|
91
|
+
rangeLabel?: string;
|
|
92
|
+
/** Full accessible name, e.g. `'BMI 24.6 — normal (18.5–24.9)'`. */
|
|
93
|
+
ariaLabel: string;
|
|
94
|
+
/** Threshold tick values drawn under the bar (e.g. `[18.5, 25, 30]`). */
|
|
95
|
+
ticks?: number[];
|
|
96
|
+
}
|
|
97
|
+
/**
|
|
98
|
+
* Optional in-card gauge. A discriminated union on `variant`:
|
|
99
|
+
*
|
|
100
|
+
* • `'radial'` (default when `variant` is omitted) — the corner-box donut.
|
|
101
|
+
* • `'banded'` — a full-width horizontal banded bar below the fields.
|
|
102
|
+
*/
|
|
103
|
+
export type InsertCardGauge = InsertCardRadialGauge | InsertCardBandedGauge;
|
|
8
104
|
export interface InsertCardData {
|
|
9
105
|
/** Card heading. */
|
|
10
106
|
title: string;
|
|
11
107
|
/** Key/value rows. */
|
|
12
108
|
fields: InsertCardField[];
|
|
13
|
-
/**
|
|
109
|
+
/**
|
|
110
|
+
* Optional header glyph drawn inline-end of the title, tinted with the card's
|
|
111
|
+
* category colour ({@link InsertCardData.highlightToken}). One of the known
|
|
112
|
+
* {@link IconKey} names; an unknown / omitted value simply skips the glyph
|
|
113
|
+
* (fully back-compatible — a card without an icon renders as before).
|
|
114
|
+
*/
|
|
115
|
+
icon?: IconKey;
|
|
116
|
+
/** Optional highlighted line, rendered as a category chip (pill). */
|
|
14
117
|
highlight?: string;
|
|
118
|
+
/**
|
|
119
|
+
* DS token NAME for the highlight chip fill. Defaults to the accent token
|
|
120
|
+
* (`--primary`). The chip text uses the matching `<token>-foreground` when it
|
|
121
|
+
* resolves, else falls back to the card background for contrast.
|
|
122
|
+
*/
|
|
123
|
+
highlightToken?: string;
|
|
124
|
+
/** Optional radial gauge drawn natively in the card. */
|
|
125
|
+
gauge?: InsertCardGauge;
|
|
126
|
+
/**
|
|
127
|
+
* Optional brand wordmark line printed at the foot of the card.
|
|
128
|
+
*
|
|
129
|
+
* - omitted / `false` → no brand line and no footer at all; the card ends
|
|
130
|
+
* after the fields/gauge.
|
|
131
|
+
* - a string → that wordmark, rendered as a single quiet line (no hairline
|
|
132
|
+
* rule above it).
|
|
133
|
+
*
|
|
134
|
+
* A `brand` passed to {@link SvgCardToPngOptions} overrides this per-render.
|
|
135
|
+
*/
|
|
136
|
+
brand?: string | false;
|
|
15
137
|
}
|
|
16
138
|
export interface InsertPayload {
|
|
17
139
|
/** Which button the user chose. */
|
|
@@ -38,14 +160,30 @@ export interface InsertPayload {
|
|
|
38
160
|
*/
|
|
39
161
|
imageDataUri: string;
|
|
40
162
|
/**
|
|
41
|
-
* Async thunk that resolves the result-card
|
|
42
|
-
*
|
|
43
|
-
*
|
|
44
|
-
*
|
|
45
|
-
*
|
|
46
|
-
*
|
|
163
|
+
* Async thunk that resolves the result-card raster — the format intended for
|
|
164
|
+
* editor insertion. PNG is a flat raster: it carries no script and survives
|
|
165
|
+
* the rich-text sanitiser that strips SVG.
|
|
166
|
+
*
|
|
167
|
+
* Resolves to `{ dataUri, width, height }` where `width`/`height` are the
|
|
168
|
+
* **logical (un-scaled) CSS pixel** dimensions: set them on the inserted
|
|
169
|
+
* `<img width height>` and the supersampled (`>= 2×`) PNG renders crisp with
|
|
170
|
+
* no consumer-side shim. For mode `'text'` resolves to an empty
|
|
171
|
+
* `{ dataUri: '', width: 0, height: 0 }`. Rendered lazily so the synchronous
|
|
172
|
+
* payload stays cheap; `await payload.pngDataUri()` only when you need it.
|
|
173
|
+
*
|
|
174
|
+
* @since 0.43.0 — this return shape changed from a bare `Promise<string>` to
|
|
175
|
+
* `Promise<{ dataUri; width; height }>` (see CHANGELOG).
|
|
47
176
|
*/
|
|
48
|
-
pngDataUri: () => Promise<
|
|
177
|
+
pngDataUri: () => Promise<InsertPngResult>;
|
|
178
|
+
}
|
|
179
|
+
/** Resolved PNG raster plus its logical (un-scaled) `<img>` dimensions. */
|
|
180
|
+
export interface InsertPngResult {
|
|
181
|
+
/** `image/png` data URI, or `''` for the text-only mode. */
|
|
182
|
+
dataUri: string;
|
|
183
|
+
/** Logical (CSS px) width to set on the inserted `<img>`. `0` when empty. */
|
|
184
|
+
width: number;
|
|
185
|
+
/** Logical (CSS px) height to set on the inserted `<img>`. `0` when empty. */
|
|
186
|
+
height: number;
|
|
49
187
|
}
|
|
50
188
|
export interface InsertButtonProps {
|
|
51
189
|
/** Structured result used to build every payload representation. */
|
|
@@ -84,10 +222,22 @@ interface ThemeColours {
|
|
|
84
222
|
border: string;
|
|
85
223
|
bg: string;
|
|
86
224
|
font: string;
|
|
225
|
+
/**
|
|
226
|
+
* Concrete colours resolved from arbitrary DS token names, keyed by the token
|
|
227
|
+
* name the caller passed (e.g. `'--success'`). Populated for the gauge arc
|
|
228
|
+
* and the highlight chip; consulted by {@link buildResultCardSvg} via
|
|
229
|
+
* {@link resolveToken}.
|
|
230
|
+
*/
|
|
231
|
+
tokens?: Record<string, string>;
|
|
87
232
|
}
|
|
233
|
+
/**
|
|
234
|
+
* Internal resolved-colour shape, re-exported for tests that construct a card
|
|
235
|
+
* raster without a live DOM probe. Not part of the public component API.
|
|
236
|
+
*/
|
|
237
|
+
export type ThemeColoursForTest = ThemeColours;
|
|
88
238
|
export declare function buildResultText(card: InsertCardData): string;
|
|
89
239
|
export declare function buildResultHtml(card: InsertCardData): string;
|
|
90
|
-
export declare function buildResultCardSvg(card: InsertCardData, c: ThemeColours): string;
|
|
240
|
+
export declare function buildResultCardSvg(card: InsertCardData, c: ThemeColours, brand?: string | false): string;
|
|
91
241
|
/** Options for {@link svgCardToPngDataUri}. */
|
|
92
242
|
export interface SvgCardToPngOptions {
|
|
93
243
|
/**
|
|
@@ -98,9 +248,15 @@ export interface SvgCardToPngOptions {
|
|
|
98
248
|
colours?: ThemeColours;
|
|
99
249
|
/**
|
|
100
250
|
* Device-pixel scale factor for the raster. `2` yields a retina-sharp PNG.
|
|
101
|
-
* Defaults to `
|
|
251
|
+
* Defaults to `Math.max(2, devicePixelRatio)` so the inserted image is crisp
|
|
252
|
+
* without a consumer-side supersampling shim.
|
|
102
253
|
*/
|
|
103
254
|
scale?: number;
|
|
255
|
+
/**
|
|
256
|
+
* Brand wordmark for the footer. Omitted → the card's own `brand` (then the
|
|
257
|
+
* default `'AlfaDocs'`); a string overrides it; `false` removes it.
|
|
258
|
+
*/
|
|
259
|
+
brand?: string | false;
|
|
104
260
|
}
|
|
105
261
|
/**
|
|
106
262
|
* Render an {@link InsertCardData} result card to an `image/png` data URI.
|
|
@@ -114,6 +270,13 @@ export interface SvgCardToPngOptions {
|
|
|
114
270
|
* called in a non-DOM context or if the SVG fails to decode.
|
|
115
271
|
*/
|
|
116
272
|
export declare function svgCardToPngDataUri(card: InsertCardData, opts?: SvgCardToPngOptions): Promise<string>;
|
|
273
|
+
/**
|
|
274
|
+
* Like {@link svgCardToPngDataUri} but also returns the **logical (un-scaled)**
|
|
275
|
+
* card dimensions so consumers can size the inserted `<img width height>` and
|
|
276
|
+
* drop their own supersampling shim. The PNG itself is rasterised at `scale`
|
|
277
|
+
* (default `Math.max(2, devicePixelRatio)`) for crispness.
|
|
278
|
+
*/
|
|
279
|
+
export declare function svgCardToPng(card: InsertCardData, opts?: SvgCardToPngOptions): Promise<InsertPngResult>;
|
|
117
280
|
export declare const InsertButton: import("react").ForwardRefExoticComponent<InsertButtonProps & import("react").RefAttributes<HTMLDivElement>>;
|
|
118
281
|
export {};
|
|
119
282
|
//# sourceMappingURL=insert-result.d.ts.map
|
|
@@ -27,6 +27,12 @@ export interface BmiCalculatorProps extends VariantProps<typeof rootVariants> {
|
|
|
27
27
|
onCopy?: (mode: InsertMode) => void;
|
|
28
28
|
/** `copy` variant only — fired if the clipboard write can't proceed. */
|
|
29
29
|
onError?: (error: unknown) => void;
|
|
30
|
+
/**
|
|
31
|
+
* Brand wordmark printed in the inserted/copied result-card footer.
|
|
32
|
+
* Omitted → no brand line (and no footer hairline); a string → that custom
|
|
33
|
+
* brand; `false` → no brand line. Brand is opt-in.
|
|
34
|
+
*/
|
|
35
|
+
insertBrand?: string | false;
|
|
30
36
|
/** Opaque instance id, emitted as `data-component-id`. */
|
|
31
37
|
id?: string;
|
|
32
38
|
/** Extra class names on the wrapper. */
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { B as m } from "../../_chunks/bmi-calculator-
|
|
1
|
+
import { B as m } from "../../_chunks/bmi-calculator-CQqXTVNL.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,
|
|
@@ -21,6 +21,12 @@ export interface CycleCalculatorProps extends VariantProps<typeof rootVariants>
|
|
|
21
21
|
onCopy?: (mode: InsertMode) => void;
|
|
22
22
|
/** `copy` variant only — fired if the clipboard write can't proceed. */
|
|
23
23
|
onError?: (error: unknown) => void;
|
|
24
|
+
/**
|
|
25
|
+
* Brand wordmark printed in the inserted/copied result-card footer.
|
|
26
|
+
* Omitted → no brand line (and no footer hairline); a string → that custom
|
|
27
|
+
* brand; `false` → no brand line. Brand is opt-in.
|
|
28
|
+
*/
|
|
29
|
+
insertBrand?: string | false;
|
|
24
30
|
/** Opaque instance id, emitted as `data-component-id`. */
|
|
25
31
|
id?: string;
|
|
26
32
|
/** Extra class names on the wrapper. */
|
|
@@ -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-BEBUQl9P.js";
|
|
2
2
|
export {
|
|
3
3
|
l as ActionsCellRenderer,
|
|
4
4
|
r as BalanceCellRenderer,
|
|
@@ -36,6 +36,7 @@ export declare const Dialog: {
|
|
|
36
36
|
Header: import("react").ForwardRefExoticComponent<HTMLAttributes<HTMLDivElement> & import("react").RefAttributes<HTMLDivElement>>;
|
|
37
37
|
Title: import("react").ForwardRefExoticComponent<Omit<RadixDialog.DialogTitleProps & import("react").RefAttributes<HTMLHeadingElement>, "ref"> & import("react").RefAttributes<HTMLHeadingElement>>;
|
|
38
38
|
Description: import("react").ForwardRefExoticComponent<Omit<RadixDialog.DialogDescriptionProps & import("react").RefAttributes<HTMLParagraphElement>, "ref"> & import("react").RefAttributes<HTMLParagraphElement>>;
|
|
39
|
+
Body: import("react").ForwardRefExoticComponent<HTMLAttributes<HTMLDivElement> & import("react").RefAttributes<HTMLDivElement>>;
|
|
39
40
|
Footer: import("react").ForwardRefExoticComponent<DialogFooterProps & import("react").RefAttributes<HTMLDivElement>>;
|
|
40
41
|
Close: import("react").ForwardRefExoticComponent<Omit<RadixDialog.DialogCloseProps & import("react").RefAttributes<HTMLButtonElement>, "ref"> & import("react").RefAttributes<HTMLButtonElement>>;
|
|
41
42
|
};
|
|
@@ -21,6 +21,12 @@ export interface DueDateCalculatorProps extends VariantProps<typeof rootVariants
|
|
|
21
21
|
onCopy?: (mode: InsertMode) => void;
|
|
22
22
|
/** `copy` variant only — fired if the clipboard write can't proceed. */
|
|
23
23
|
onError?: (error: unknown) => void;
|
|
24
|
+
/**
|
|
25
|
+
* Brand wordmark printed in the inserted/copied result-card footer.
|
|
26
|
+
* Omitted → no brand line (and no footer hairline); a string → that custom
|
|
27
|
+
* brand; `false` → no brand line. Brand is opt-in.
|
|
28
|
+
*/
|
|
29
|
+
insertBrand?: string | false;
|
|
24
30
|
/** Opaque instance id, emitted as `data-component-id`. */
|
|
25
31
|
id?: string;
|
|
26
32
|
/** Extra class names on the wrapper. */
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { D as s } from "../../_chunks/due-date-calculator-
|
|
1
|
+
import { D as s } from "../../_chunks/due-date-calculator-mFxpHLml.js";
|
|
2
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,
|
|
@@ -27,6 +27,12 @@ export interface GestationalAgeCalculatorProps extends VariantProps<typeof rootV
|
|
|
27
27
|
onCopy?: (mode: InsertMode) => void;
|
|
28
28
|
/** `copy` variant only — fired if the clipboard write can't proceed. */
|
|
29
29
|
onError?: (error: unknown) => void;
|
|
30
|
+
/**
|
|
31
|
+
* Brand wordmark printed in the inserted/copied result-card footer.
|
|
32
|
+
* Omitted → no brand line (and no footer hairline); a string → that custom
|
|
33
|
+
* brand; `false` → no brand line. Brand is opt-in.
|
|
34
|
+
*/
|
|
35
|
+
insertBrand?: string | false;
|
|
30
36
|
/** Opaque instance id, emitted as `data-component-id`. */
|
|
31
37
|
id?: string;
|
|
32
38
|
/** Extra class names on the wrapper. */
|
|
@@ -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, svgCardToPngDataUri, type InsertButtonProps, type InsertVariant, type InsertPayload, type InsertMode, type InsertCardData, type InsertCardField, type SvgCardToPngOptions, } from './_shared/insert-result';
|
|
42
|
+
export { InsertButton, svgCardToPngDataUri, svgCardToPng, type InsertButtonProps, type InsertVariant, type InsertPayload, type InsertPngResult, type InsertMode, type InsertCardData, type InsertCardField, type InsertCardGauge, type SvgCardToPngOptions, } from './_shared/insert-result';
|
|
43
43
|
export * from './accordion';
|
|
44
44
|
export * from './avatar';
|
|
45
45
|
export * from './badge';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { P as r, f as s, p as m, a as e, s as n, b as o, c as i } from "../../_chunks/payment-form-
|
|
1
|
+
import { P as r, f as s, p as m, a as e, s as n, b as o, c as i } from "../../_chunks/payment-form-DqEiEJRO.js";
|
|
2
2
|
export {
|
|
3
3
|
r as PaymentForm,
|
|
4
4
|
s as formatPaymentAmount,
|
|
@@ -3,8 +3,30 @@ export type PaymentCurrency = string;
|
|
|
3
3
|
export interface PaymentFormProps {
|
|
4
4
|
/** Opaque instance id — emitted as `data-component-id` for the agent registry. */
|
|
5
5
|
id?: string;
|
|
6
|
-
/**
|
|
7
|
-
|
|
6
|
+
/**
|
|
7
|
+
* Client secret from your server, created via the PaymentIntents API.
|
|
8
|
+
*
|
|
9
|
+
* Omit to use **deferred-intent mode** — the Payment Element renders from
|
|
10
|
+
* just the publishable key (no `clientSecret`, no backend round-trip up
|
|
11
|
+
* front). In deferred mode supply `onCreatePaymentIntent` to actually
|
|
12
|
+
* confirm: your server mints + returns the client secret at submit time.
|
|
13
|
+
*/
|
|
14
|
+
clientSecret?: string;
|
|
15
|
+
/**
|
|
16
|
+
* Deferred-intent setup: `'payment'` collects a charge, `'setup'` saves a
|
|
17
|
+
* method for later. Ignored when `clientSecret` is supplied (the secret's
|
|
18
|
+
* own intent type wins). Defaults to `'payment'`.
|
|
19
|
+
*/
|
|
20
|
+
mode?: 'payment' | 'setup';
|
|
21
|
+
/**
|
|
22
|
+
* Deferred-confirm callback. Called at submit time (after client-side
|
|
23
|
+
* field validation succeeds) so your server can mint a PaymentIntent and
|
|
24
|
+
* return its `client_secret`. The returned secret is used ONLY to confirm
|
|
25
|
+
* and is never logged or sent to any third-party origin. When omitted in
|
|
26
|
+
* deferred mode the form runs in PREVIEW: fields render + validate, but no
|
|
27
|
+
* charge is attempted.
|
|
28
|
+
*/
|
|
29
|
+
onCreatePaymentIntent?: () => Promise<string>;
|
|
8
30
|
/** Stripe publishable key (`pk_test_…` / `pk_live_…`). */
|
|
9
31
|
publishableKey: string;
|
|
10
32
|
/** ISO-4217 currency code (e.g. 'EUR', 'USD', 'JPY'). */
|
|
@@ -19,6 +19,12 @@ export interface PregnancyWeightGainProps extends VariantProps<typeof rootVarian
|
|
|
19
19
|
onCopy?: (mode: InsertMode) => void;
|
|
20
20
|
/** `copy` variant only — fired if the clipboard write can't proceed. */
|
|
21
21
|
onError?: (error: unknown) => void;
|
|
22
|
+
/**
|
|
23
|
+
* Brand wordmark printed in the inserted/copied result-card footer.
|
|
24
|
+
* Omitted → no brand line (and no footer hairline); a string → that custom
|
|
25
|
+
* brand; `false` → no brand line. Brand is opt-in.
|
|
26
|
+
*/
|
|
27
|
+
insertBrand?: string | false;
|
|
22
28
|
/** Opaque instance id, emitted as `data-component-id`. */
|
|
23
29
|
id?: string;
|
|
24
30
|
/** Extra class names on the wrapper. */
|
|
@@ -2,10 +2,10 @@ import { type HTMLAttributes } from 'react';
|
|
|
2
2
|
import { type VariantProps } from 'class-variance-authority';
|
|
3
3
|
declare const spinnerVariants: (props?: ({
|
|
4
4
|
size?: "sm" | "md" | "lg" | null | undefined;
|
|
5
|
-
variant?: "pulse" | "chase" | "prism" | null | undefined;
|
|
5
|
+
variant?: "static" | "pulse" | "chase" | "prism" | null | undefined;
|
|
6
6
|
speed?: "slower" | "slow" | "normal" | "fast" | "faster" | null | undefined;
|
|
7
7
|
} & import("class-variance-authority/types").ClassProp) | undefined) => string;
|
|
8
|
-
export type SpinnerVariant = 'pulse' | 'chase' | 'prism';
|
|
8
|
+
export type SpinnerVariant = 'pulse' | 'chase' | 'prism' | 'static';
|
|
9
9
|
export type SpinnerSpeed = 'slower' | 'slow' | 'normal' | 'fast' | 'faster';
|
|
10
10
|
export interface SpinnerProps extends Omit<HTMLAttributes<HTMLSpanElement>, 'role' | 'children'>, VariantProps<typeof spinnerVariants> {
|
|
11
11
|
size?: 'sm' | 'md' | 'lg';
|
|
@@ -21,6 +21,12 @@ export interface UnitConverterProps extends VariantProps<typeof rootVariants> {
|
|
|
21
21
|
onCopy?: (mode: InsertMode) => void;
|
|
22
22
|
/** `copy` variant only — fired if the clipboard write can't proceed. */
|
|
23
23
|
onError?: (error: unknown) => void;
|
|
24
|
+
/**
|
|
25
|
+
* Brand wordmark printed in the inserted/copied result-card footer.
|
|
26
|
+
* Omitted → no brand line (and no footer hairline); a string → that custom
|
|
27
|
+
* brand; `false` → no brand line. Brand is opt-in.
|
|
28
|
+
*/
|
|
29
|
+
insertBrand?: string | false;
|
|
24
30
|
/** Opaque instance id, emitted as `data-component-id`. */
|
|
25
31
|
id?: string;
|
|
26
32
|
/** Extra class names on the wrapper. */
|
|
@@ -1673,7 +1673,7 @@ export declare const arUi: {
|
|
|
1673
1673
|
readonly overweight: "25.0 – 29.9";
|
|
1674
1674
|
readonly obese: "30.0 فأكثر";
|
|
1675
1675
|
};
|
|
1676
|
-
readonly gaugeAria: "مؤشر كتلة الجسم {{bmi}}
|
|
1676
|
+
readonly gaugeAria: "مؤشر كتلة الجسم {{bmi}} — {{category}} ({{range}})";
|
|
1677
1677
|
readonly empty: "أدخل الطول والوزن لحساب مؤشر كتلة الجسم.";
|
|
1678
1678
|
};
|
|
1679
1679
|
readonly dueDateCalculator: {
|
package/dist/i18n/locales/ar.js
CHANGED
|
@@ -1650,7 +1650,7 @@ const e = {
|
|
|
1650
1650
|
overweight: "25.0 – 29.9",
|
|
1651
1651
|
obese: "30.0 فأكثر"
|
|
1652
1652
|
},
|
|
1653
|
-
gaugeAria: "مؤشر كتلة الجسم {{bmi}}
|
|
1653
|
+
gaugeAria: "مؤشر كتلة الجسم {{bmi}} — {{category}} ({{range}})",
|
|
1654
1654
|
empty: "أدخل الطول والوزن لحساب مؤشر كتلة الجسم."
|
|
1655
1655
|
},
|
|
1656
1656
|
dueDateCalculator: {
|
|
@@ -1673,7 +1673,7 @@ export declare const deUi: {
|
|
|
1673
1673
|
readonly overweight: "25,0 – 29,9";
|
|
1674
1674
|
readonly obese: "30,0 und mehr";
|
|
1675
1675
|
};
|
|
1676
|
-
readonly gaugeAria: "Body-Mass-Index {{bmi}}
|
|
1676
|
+
readonly gaugeAria: "Body-Mass-Index {{bmi}} — {{category}} ({{range}})";
|
|
1677
1677
|
readonly empty: "Größe und Gewicht eingeben, um den BMI zu berechnen.";
|
|
1678
1678
|
};
|
|
1679
1679
|
readonly dueDateCalculator: {
|
package/dist/i18n/locales/de.js
CHANGED
|
@@ -1649,7 +1649,7 @@ const e = {
|
|
|
1649
1649
|
overweight: "25,0 – 29,9",
|
|
1650
1650
|
obese: "30,0 und mehr"
|
|
1651
1651
|
},
|
|
1652
|
-
gaugeAria: "Body-Mass-Index {{bmi}}
|
|
1652
|
+
gaugeAria: "Body-Mass-Index {{bmi}} — {{category}} ({{range}})",
|
|
1653
1653
|
empty: "Größe und Gewicht eingeben, um den BMI zu berechnen."
|
|
1654
1654
|
},
|
|
1655
1655
|
dueDateCalculator: {
|
|
@@ -1670,7 +1670,7 @@ export declare const elUi: {
|
|
|
1670
1670
|
readonly overweight: "25,0 – 29,9";
|
|
1671
1671
|
readonly obese: "30,0 και άνω";
|
|
1672
1672
|
};
|
|
1673
|
-
readonly gaugeAria: "Δείκτης μάζας σώματος {{bmi}}
|
|
1673
|
+
readonly gaugeAria: "Δείκτης μάζας σώματος {{bmi}} — {{category}} ({{range}})";
|
|
1674
1674
|
readonly empty: "Εισαγάγετε ύψος και βάρος για τον υπολογισμό του ΔΜΣ.";
|
|
1675
1675
|
};
|
|
1676
1676
|
readonly dueDateCalculator: {
|
package/dist/i18n/locales/el.js
CHANGED
|
@@ -1650,7 +1650,7 @@ const e = {
|
|
|
1650
1650
|
overweight: "25,0 – 29,9",
|
|
1651
1651
|
obese: "30,0 και άνω"
|
|
1652
1652
|
},
|
|
1653
|
-
gaugeAria: "Δείκτης μάζας σώματος {{bmi}}
|
|
1653
|
+
gaugeAria: "Δείκτης μάζας σώματος {{bmi}} — {{category}} ({{range}})",
|
|
1654
1654
|
empty: "Εισαγάγετε ύψος και βάρος για τον υπολογισμό του ΔΜΣ."
|
|
1655
1655
|
},
|
|
1656
1656
|
dueDateCalculator: {
|
|
@@ -1670,7 +1670,7 @@ export declare const enUi: {
|
|
|
1670
1670
|
readonly overweight: "25.0 – 29.9";
|
|
1671
1671
|
readonly obese: "30.0 and above";
|
|
1672
1672
|
};
|
|
1673
|
-
readonly gaugeAria: "Body mass index {{bmi}}
|
|
1673
|
+
readonly gaugeAria: "Body mass index {{bmi}} — {{category}} ({{range}})";
|
|
1674
1674
|
readonly empty: "Enter a height and weight to see the BMI.";
|
|
1675
1675
|
};
|
|
1676
1676
|
readonly dueDateCalculator: {
|