@nivaro/react 0.1.259 → 0.1.261
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/full.css +1 -1
- package/dist/index.d.ts +104 -12
- package/dist/index.js +37193 -33926
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -251,14 +251,24 @@ export declare interface ApiRequestLogFilters {
|
|
|
251
251
|
* same-origin fetch, which is what the admin SPA needs — it is served BY the
|
|
252
252
|
* API in production and proxied to it in dev, and has no provider at its root.
|
|
253
253
|
*/
|
|
254
|
-
export declare function ApiUpdateBanner({ appName, fetchVersion }: {
|
|
254
|
+
export declare function ApiUpdateBanner({ appName, fetchVersion, releaseNotesUrl }: {
|
|
255
255
|
appName?: string;
|
|
256
256
|
fetchVersion?: () => Promise<ApiVersionInfo | null>;
|
|
257
|
+
/**
|
|
258
|
+
* "What changed" link (#62): given the update notice (served version +
|
|
259
|
+
* the version this tab loaded against), return the release-notes URL —
|
|
260
|
+
* the admin passes `/changelog?since=<from>&to=<version>`. Null hides it.
|
|
261
|
+
* Rendered as a plain anchor on purpose: following it is a full navigation,
|
|
262
|
+
* which lands the reader on the NEW build's notes.
|
|
263
|
+
*/
|
|
264
|
+
releaseNotesUrl?: (info: ApiVersionInfo) => string | null;
|
|
257
265
|
}): JSX.Element | null;
|
|
258
266
|
|
|
259
267
|
export declare interface ApiVersionInfo {
|
|
260
268
|
version: string;
|
|
261
269
|
environment?: string;
|
|
270
|
+
/** The version this tab loaded against — set on an update notice only. */
|
|
271
|
+
from?: string | null;
|
|
262
272
|
}
|
|
263
273
|
|
|
264
274
|
export declare function applyValidationRule(rule: FormValidationRule_2, value: unknown, label: string, record?: Record<string, unknown>): string | null;
|
|
@@ -894,6 +904,36 @@ export declare function CommentPanel({ collection, item, title, defaultExpanded,
|
|
|
894
904
|
onQueueComment?: (text: string) => void;
|
|
895
905
|
}): React_2.JSX.Element;
|
|
896
906
|
|
|
907
|
+
/**
|
|
908
|
+
* Comparison series for an inline grid (`options.compare_series`).
|
|
909
|
+
*
|
|
910
|
+
* A second, read-only line of figures under the grid's own cells — "what
|
|
911
|
+
* actually happened" beside "what was planned" — fetched from an endpoint the
|
|
912
|
+
* layout names. The grid stays domain-blind: the endpoint says which row key
|
|
913
|
+
* and columns it speaks about, which columns are closed (final), the verdict
|
|
914
|
+
* it wants shown, and what each figure is made of. Any month × key planning
|
|
915
|
+
* grid whose "what really happened" lives elsewhere fits the contract — the
|
|
916
|
+
* nouns (what a detail row IS, what the grid's own figures are called) come
|
|
917
|
+
* from the endpoint too, so this file never names a domain.
|
|
918
|
+
*
|
|
919
|
+
* Contract (endpoint response, under `data`):
|
|
920
|
+
* label 'Actual' — the series name
|
|
921
|
+
* plan_label 'Plan' — what the grid's own figures are called (default 'Plan')
|
|
922
|
+
* unit { one, many } — the noun for a detail row (default entry/entries)
|
|
923
|
+
* key_field the grid column that identifies a row (e.g. 'year')
|
|
924
|
+
* columns the grid columns the series speaks about
|
|
925
|
+
* rows[] { key, values: {column: number}, details?: {column: DetailRow[]} }
|
|
926
|
+
* closed_through 'YYYY-MM' | null — month columns at or before it are final
|
|
927
|
+
* closed_rule one sentence explaining how a month closes
|
|
928
|
+
* status { key, label, tone, reason } | null — the verdict + why
|
|
929
|
+
* figures[] { label, value, format } — strip chips beside the grid's own
|
|
930
|
+
*/
|
|
931
|
+
declare interface CompareSeriesConfig {
|
|
932
|
+
/** `/my-extension/actuals/{{$parent.id}}` — `{{$parent.<field>}}` tokens read the parent draft. */
|
|
933
|
+
endpoint: string;
|
|
934
|
+
label?: string;
|
|
935
|
+
}
|
|
936
|
+
|
|
897
937
|
export declare type ComponentOverrides = {
|
|
898
938
|
text?: default_2.ComponentType<FieldComponentProps>;
|
|
899
939
|
textarea?: default_2.ComponentType<FieldComponentProps>;
|
|
@@ -1725,6 +1765,12 @@ declare interface GridSpreadConfig {
|
|
|
1725
1765
|
/** Fill only empty/zero targets (default true); false = overwrite all. */
|
|
1726
1766
|
only_empty?: boolean;
|
|
1727
1767
|
format?: 'currency' | 'number';
|
|
1768
|
+
/** Shapes offered beside the button (default all: even, front-loaded,
|
|
1769
|
+
* back-loaded, and "like the previous row" when one exists). */
|
|
1770
|
+
presets?: SpreadPreset[];
|
|
1771
|
+
/** Also offer a grid-level spread over every row's empty targets
|
|
1772
|
+
* (default true). */
|
|
1773
|
+
across_rows?: boolean;
|
|
1728
1774
|
}
|
|
1729
1775
|
|
|
1730
1776
|
/**
|
|
@@ -1843,6 +1889,40 @@ export declare interface ImportDefinition {
|
|
|
1843
1889
|
receipt?: string | null;
|
|
1844
1890
|
}
|
|
1845
1891
|
|
|
1892
|
+
declare interface ImportDryRun {
|
|
1893
|
+
created: number;
|
|
1894
|
+
updated: number;
|
|
1895
|
+
unchanged: number;
|
|
1896
|
+
skipped: Record<string, number>;
|
|
1897
|
+
failed: number;
|
|
1898
|
+
log: string;
|
|
1899
|
+
samples?: {
|
|
1900
|
+
creates: Array<{
|
|
1901
|
+
key: string;
|
|
1902
|
+
values: Record<string, unknown>;
|
|
1903
|
+
}>;
|
|
1904
|
+
updates: Array<{
|
|
1905
|
+
key: string;
|
|
1906
|
+
id: unknown;
|
|
1907
|
+
changes: Array<{
|
|
1908
|
+
field: string;
|
|
1909
|
+
from: unknown;
|
|
1910
|
+
to: unknown;
|
|
1911
|
+
}>;
|
|
1912
|
+
}>;
|
|
1913
|
+
skipped_rows: Array<{
|
|
1914
|
+
row: number;
|
|
1915
|
+
key: string | null;
|
|
1916
|
+
reason: string;
|
|
1917
|
+
}>;
|
|
1918
|
+
would_create_lookups: Array<{
|
|
1919
|
+
column: string;
|
|
1920
|
+
collection: string;
|
|
1921
|
+
values: string[];
|
|
1922
|
+
}>;
|
|
1923
|
+
};
|
|
1924
|
+
}
|
|
1925
|
+
|
|
1846
1926
|
export declare function ImportFromFileButton({ collection, templateFilter, getLabel, onParsed, compact }: {
|
|
1847
1927
|
collection: string;
|
|
1848
1928
|
templateFilter?: (t: ImportTemplateSummary) => boolean;
|
|
@@ -1900,6 +1980,8 @@ export declare interface ImportPreview {
|
|
|
1900
1980
|
missing_columns: string[];
|
|
1901
1981
|
/** Pre-flight report — errors here block queueing server-side too. */
|
|
1902
1982
|
validation?: ImportValidationReport;
|
|
1983
|
+
/** Service-mode definitions only: what a run would do, nothing written. */
|
|
1984
|
+
dry_run?: ImportDryRun | null;
|
|
1903
1985
|
}
|
|
1904
1986
|
|
|
1905
1987
|
/** Emitted by the worker on the `import:progress` socket event. */
|
|
@@ -1989,18 +2071,11 @@ declare interface ImportValidationReport {
|
|
|
1989
2071
|
truncated: boolean;
|
|
1990
2072
|
}
|
|
1991
2073
|
|
|
1992
|
-
/**
|
|
1993
|
-
* Inbound integrations — every caller that is not a person's browser session,
|
|
1994
|
-
* as cards, plus the request log scoped to the picked one. This is the
|
|
1995
|
-
* dedicated "external API logs" view: partner file pushes, legacy GraphQL
|
|
1996
|
-
* writes, named API keys — who called, how often, what failed, and the exact
|
|
1997
|
-
* response body the caller got back.
|
|
1998
|
-
*/
|
|
1999
2074
|
export declare function InboundCallersView({ hours: initialHours }: {
|
|
2000
2075
|
hours?: number;
|
|
2001
2076
|
}): JSX.Element;
|
|
2002
2077
|
|
|
2003
|
-
export declare function InlineTableField({ relatedCollection, manyField, parentId, parentCollection, layoutId, showRowRevisions, rowComments, allowRevisionRestore, saveMode, showLineNumbers, enableReorder, parentCascades, rowRules, columnPresets, defaultPreset, drawerRelations, parentContextFields, uniqueBy, sortField, sortDir, sectionGroupBy, freezeFirstColumn, rowFilter, rowDefaults, allocateDrawer, autoAllocate, rowBulkActions, uploadTemplate, rowMatchPanel, lineSla, rowLints, stats, sumCap, spreadRemaining, submissionErrors, prefillParentId, parentFieldKey, readOnly, emptyLabel, editorMode }: {
|
|
2078
|
+
export declare function InlineTableField({ relatedCollection, manyField, parentId, parentCollection, layoutId, showRowRevisions, rowComments, allowRevisionRestore, saveMode, showLineNumbers, enableReorder, parentCascades, rowRules, columnPresets, defaultPreset, drawerRelations, parentContextFields, uniqueBy, sortField, sortDir, sectionGroupBy, freezeFirstColumn, rowFilter, rowDefaults, allocateDrawer, autoAllocate, rowBulkActions, uploadTemplate, rowMatchPanel, lineSla, rowLints, stats, compareSeries, sumCap, spreadRemaining, submissionErrors, prefillParentId, parentFieldKey, readOnly, emptyLabel, editorMode }: {
|
|
2004
2079
|
relatedCollection: string;
|
|
2005
2080
|
manyField: string;
|
|
2006
2081
|
parentId: string;
|
|
@@ -2069,6 +2144,11 @@ export declare function InlineTableField({ relatedCollection, manyField, parentI
|
|
|
2069
2144
|
* edits and the row being typed into included) and `{{$count}}`. A
|
|
2070
2145
|
* negative result reads red when `negative` is 'danger'. */
|
|
2071
2146
|
stats?: GridStatConfig[] | null;
|
|
2147
|
+
/** options.compare_series — a second, read-only line of figures under the
|
|
2148
|
+
* cells ("what actually happened" beside the plan) fetched from an endpoint
|
|
2149
|
+
* the layout names; closed columns shade, a verdict chip leads the strip,
|
|
2150
|
+
* each figure opens the rows behind it. See CompareSeries.tsx. */
|
|
2151
|
+
compareSeries?: CompareSeriesConfig | null;
|
|
2072
2152
|
/** options.sum_cap — refuse to save/stage a row when `field` summed over the
|
|
2073
2153
|
* grid (this row's draft included) would exceed `cap` (same tokens as
|
|
2074
2154
|
* stats). The client twin of the server's sum_cap validation rule. */
|
|
@@ -2085,7 +2165,7 @@ export declare function InlineTableField({ relatedCollection, manyField, parentI
|
|
|
2085
2165
|
};
|
|
2086
2166
|
prefillParentId?: string;
|
|
2087
2167
|
parentFieldKey?: string;
|
|
2088
|
-
}): JSX.Element;
|
|
2168
|
+
}): React_2.JSX.Element;
|
|
2089
2169
|
|
|
2090
2170
|
declare interface InputBinding {
|
|
2091
2171
|
key: string;
|
|
@@ -2786,7 +2866,7 @@ export declare function NotificationAnalyticsView({ className }: {
|
|
|
2786
2866
|
* click-through routing via the shared notification-target resolver. Needs
|
|
2787
2867
|
* `<NivaroProvider>`.
|
|
2788
2868
|
*/
|
|
2789
|
-
export declare function NotificationBell({ routes, onNavigate, app, subscribe, buttonClassName, panelClassName, beforeList, extraBadge, mailLogUrl, renderTrigger, allPath, onActionError, panelPlacement }: NotificationBellProps): JSX.Element;
|
|
2869
|
+
export declare function NotificationBell({ routes, onNavigate, app, subscribe, buttonClassName, panelClassName, beforeList, extraBadge, mailLogUrl, renderTrigger, allPath, subscriptionsPath, onActionError, panelPlacement }: NotificationBellProps): JSX.Element;
|
|
2790
2870
|
|
|
2791
2871
|
export declare interface NotificationBellProps {
|
|
2792
2872
|
/** Where each notification kind lands in the host app. */
|
|
@@ -2822,6 +2902,8 @@ export declare interface NotificationBellProps {
|
|
|
2822
2902
|
}) => ReactNode;
|
|
2823
2903
|
/** Path of the full notifications page — renders a "See all" footer link. */
|
|
2824
2904
|
allPath?: string | null;
|
|
2905
|
+
/** Path of the subscriptions page — a watch's "Why me?" offers a Manage link. */
|
|
2906
|
+
subscriptionsPath?: string | null;
|
|
2825
2907
|
/** Called with an error message when an inline action fails. */
|
|
2826
2908
|
onActionError?: (message: string) => void;
|
|
2827
2909
|
/** Where the panel opens relative to the trigger. 'below' (default) keeps
|
|
@@ -2831,13 +2913,15 @@ export declare interface NotificationBellProps {
|
|
|
2831
2913
|
panelPlacement?: 'below' | 'right';
|
|
2832
2914
|
}
|
|
2833
2915
|
|
|
2834
|
-
export declare function NotificationCenterView({ routes, onNavigate, app, mailLogUrl, onNotice, onError, className }: NotificationCenterViewProps): JSX.Element;
|
|
2916
|
+
export declare function NotificationCenterView({ routes, onNavigate, app, mailLogUrl, subscriptionsPath, onNotice, onError, className }: NotificationCenterViewProps): JSX.Element;
|
|
2835
2917
|
|
|
2836
2918
|
export declare interface NotificationCenterViewProps {
|
|
2837
2919
|
routes: NotificationRouteMap;
|
|
2838
2920
|
onNavigate: (path: string) => void;
|
|
2839
2921
|
app?: 'portal' | 'admin';
|
|
2840
2922
|
mailLogUrl?: (mailLogId: number) => string | null;
|
|
2923
|
+
/** Host route of the subscriptions page (a watch's "Why me?" links there). */
|
|
2924
|
+
subscriptionsPath?: string | null;
|
|
2841
2925
|
/** Toast hooks — hosts wire their own toaster. */
|
|
2842
2926
|
onNotice?: (message: string) => void;
|
|
2843
2927
|
onError?: (message: string) => void;
|
|
@@ -3797,6 +3881,12 @@ export declare interface RealtimeAdapter {
|
|
|
3797
3881
|
|
|
3798
3882
|
export declare const RealtimeContext: Context<RealtimeAdapter | null>;
|
|
3799
3883
|
|
|
3884
|
+
export declare function RecentRecordsRail({ limit, title, className }: {
|
|
3885
|
+
limit?: number;
|
|
3886
|
+
title?: string;
|
|
3887
|
+
className?: string;
|
|
3888
|
+
}): JSX.Element;
|
|
3889
|
+
|
|
3800
3890
|
export declare function RecordChatActions({ collection, itemDraft, compact }: {
|
|
3801
3891
|
collection: string;
|
|
3802
3892
|
itemDraft: Record<string, unknown>;
|
|
@@ -4545,6 +4635,8 @@ export declare type SlotRendererProps = {
|
|
|
4545
4635
|
|
|
4546
4636
|
export declare function splitMessageTokens(text: string, entityPattern: string): MessageToken[];
|
|
4547
4637
|
|
|
4638
|
+
declare type SpreadPreset = 'even' | 'front' | 'back' | 'shape';
|
|
4639
|
+
|
|
4548
4640
|
/**
|
|
4549
4641
|
* Idempotent; safe from an effect that runs more than once, and safe to call
|
|
4550
4642
|
* from several components — only the first call arms the timer.
|