@nivaro/react 0.2.18 → 0.2.20
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 +21 -1
- package/dist/index.d.ts +627 -1
- package/dist/index.js +70712 -61759
- package/package.json +1 -1
- package/styles.css +20 -0
package/dist/index.d.ts
CHANGED
|
@@ -9,11 +9,13 @@ import { JSX } from 'react';
|
|
|
9
9
|
import { JSXElementConstructor } from 'react';
|
|
10
10
|
import type { LucideIcon } from 'lucide-react';
|
|
11
11
|
import { ManagedUser } from '@nivaro/sdk';
|
|
12
|
+
import { MutableRefObject } from 'react';
|
|
12
13
|
import { NivaroClient } from '@nivaro/sdk';
|
|
13
14
|
import { default as React_2 } from 'react';
|
|
14
15
|
import { ReactElement } from 'react';
|
|
15
16
|
import { ReactNode } from 'react';
|
|
16
17
|
import { ReactPortal } from 'react';
|
|
18
|
+
import { RefObject } from 'react';
|
|
17
19
|
import { ReportDateRange } from '@nivaro/sdk';
|
|
18
20
|
import { ReportEntityFilter } from '@nivaro/sdk';
|
|
19
21
|
import { ReportQueryWidgetConfig } from '@nivaro/sdk';
|
|
@@ -180,6 +182,19 @@ declare type AllocateDrawerConfig = {
|
|
|
180
182
|
value_max?: string;
|
|
181
183
|
};
|
|
182
184
|
|
|
185
|
+
declare interface Annotation {
|
|
186
|
+
id: string;
|
|
187
|
+
type: AnnotationType;
|
|
188
|
+
start_ms: number;
|
|
189
|
+
end_ms: number;
|
|
190
|
+
rect: Rect;
|
|
191
|
+
to: Point | null;
|
|
192
|
+
text: string;
|
|
193
|
+
tone: Tone;
|
|
194
|
+
}
|
|
195
|
+
|
|
196
|
+
declare type AnnotationType = 'callout' | 'arrow' | 'box' | 'ripple';
|
|
197
|
+
|
|
183
198
|
/**
|
|
184
199
|
* Admin-authored announcement banners ("maintenance Friday 6pm") — polled
|
|
185
200
|
* every minute, role/window-filtered server-side, dismiss = acknowledge
|
|
@@ -353,6 +368,9 @@ declare type AskRelationInput = {
|
|
|
353
368
|
option_filter?: Record<string, unknown> | null;
|
|
354
369
|
};
|
|
355
370
|
|
|
371
|
+
/** Admins choose which roles may record and edit videos (admins always can). */
|
|
372
|
+
export declare function AuthorRolesButton(): JSX.Element | null;
|
|
373
|
+
|
|
356
374
|
declare type AutoAllocateConfig = {
|
|
357
375
|
/** Button label; defaults to 'Auto allocate'. */
|
|
358
376
|
label?: string;
|
|
@@ -495,8 +513,20 @@ export declare interface BaseMapPin {
|
|
|
495
513
|
pulse?: boolean;
|
|
496
514
|
}
|
|
497
515
|
|
|
516
|
+
/** Turns clean mode on until the returned release runs (idempotent). Nested
|
|
517
|
+
* holders count; the mode ends when the last one releases. */
|
|
518
|
+
export declare function beginCleanRecording(): () => void;
|
|
519
|
+
|
|
498
520
|
declare type BinaryOp = '+' | '-' | '*' | '/' | '==' | '!=' | '<' | '<=' | '>' | '>=' | '&&' | '||';
|
|
499
521
|
|
|
522
|
+
declare interface Blur {
|
|
523
|
+
id: string;
|
|
524
|
+
start_ms: number;
|
|
525
|
+
end_ms: number;
|
|
526
|
+
rect: Rect;
|
|
527
|
+
strength: number;
|
|
528
|
+
}
|
|
529
|
+
|
|
500
530
|
export declare function BooleanField({ field, value, onChange, error, disabled, readOnly, inputId, errorId }: FieldComponentProps): JSX.Element;
|
|
501
531
|
|
|
502
532
|
export declare function BroadcastView({ className }: {
|
|
@@ -573,6 +603,13 @@ export declare function canPreviewFile(type: string | null | undefined): boolean
|
|
|
573
603
|
|
|
574
604
|
export declare function canViewAs(): boolean;
|
|
575
605
|
|
|
606
|
+
declare interface Caption {
|
|
607
|
+
id: string;
|
|
608
|
+
start_ms: number;
|
|
609
|
+
end_ms: number;
|
|
610
|
+
text: string;
|
|
611
|
+
}
|
|
612
|
+
|
|
576
613
|
/**
|
|
577
614
|
* Grab the replay link for an error being reported right now. Resolves null
|
|
578
615
|
* when no recorder is active (both settings off, recording failed, or the
|
|
@@ -701,6 +738,12 @@ declare interface ChannelMeta {
|
|
|
701
738
|
default_roles?: string[];
|
|
702
739
|
}
|
|
703
740
|
|
|
741
|
+
declare interface Chapter {
|
|
742
|
+
id: string;
|
|
743
|
+
at_ms: number;
|
|
744
|
+
title: string;
|
|
745
|
+
}
|
|
746
|
+
|
|
704
747
|
export declare function ChatAnalyticsView(): JSX.Element;
|
|
705
748
|
|
|
706
749
|
/** Where a room view opens: the newest messages, or around a message / day. */
|
|
@@ -1011,6 +1054,25 @@ declare type CheckFrequency = 'hourly' | 'daily' | 'weekly';
|
|
|
1011
1054
|
*/
|
|
1012
1055
|
export declare function choiceLabel(text: string | null | undefined): string;
|
|
1013
1056
|
|
|
1057
|
+
/**
|
|
1058
|
+
* Clean recording mode: while a help video records, the screen being recorded
|
|
1059
|
+
* hides what belongs to the author rather than the walkthrough (notification
|
|
1060
|
+
* counts, chat, toasts, banners, floating chips) and shows "Demo User" in place
|
|
1061
|
+
* of the author's own name, email and photo.
|
|
1062
|
+
*
|
|
1063
|
+
* Two halves:
|
|
1064
|
+
* - `<html data-nvr-recording-clean>` drives CSS: anything tagged
|
|
1065
|
+
* `data-nvr-recording-hide` disappears (`="keep-space"` keeps its box), and
|
|
1066
|
+
* Sonner's toaster is hidden by its own attribute. Hosts that cannot import
|
|
1067
|
+
* this module (a pinned package) read the attribute directly.
|
|
1068
|
+
* - `useCleanRecording()` / `useIsRecordingSelf()` for components that swap
|
|
1069
|
+
* content (a name, an avatar).
|
|
1070
|
+
*
|
|
1071
|
+
* The mode is held, never set: every holder releases on unmount, so a crash
|
|
1072
|
+
* or a closed recorder can never leave the page stuck hidden.
|
|
1073
|
+
*/
|
|
1074
|
+
export declare const CLEAN_RECORDING_ATTR = "data-nvr-recording-clean";
|
|
1075
|
+
|
|
1014
1076
|
/** Clear the schema cache (e.g. after a schema change). */
|
|
1015
1077
|
export declare function clearFormSchemaCache(collection?: string): void;
|
|
1016
1078
|
|
|
@@ -1517,6 +1579,15 @@ declare interface DeliveryChipsProps {
|
|
|
1517
1579
|
className?: string;
|
|
1518
1580
|
}
|
|
1519
1581
|
|
|
1582
|
+
/** What the author reads as while a clean recording runs. */
|
|
1583
|
+
export declare const DEMO_USER: {
|
|
1584
|
+
readonly name: "Demo User";
|
|
1585
|
+
readonly first_name: "Demo";
|
|
1586
|
+
readonly last_name: "User";
|
|
1587
|
+
readonly initials: "DU";
|
|
1588
|
+
readonly email: "demo.user@example.com";
|
|
1589
|
+
};
|
|
1590
|
+
|
|
1520
1591
|
export declare function deriveGroupKey<T extends QueueGroupingRow>(row: T, attribute: string): string;
|
|
1521
1592
|
|
|
1522
1593
|
export declare function describeCron(cron: string): string;
|
|
@@ -1684,6 +1755,14 @@ export declare function dotsForRecord(rows: Array<{
|
|
|
1684
1755
|
tone: 'positive' | 'warning' | 'danger' | 'neutral';
|
|
1685
1756
|
}>;
|
|
1686
1757
|
|
|
1758
|
+
/** Ticketed download links (`attachment`), relative to the API origin. */
|
|
1759
|
+
declare interface DownloadUrls {
|
|
1760
|
+
video: string;
|
|
1761
|
+
/** Null when the video has no captions. */
|
|
1762
|
+
captions_vtt: string | null;
|
|
1763
|
+
captions_srt: string | null;
|
|
1764
|
+
}
|
|
1765
|
+
|
|
1687
1766
|
declare type DrawerRelationConfig = string | {
|
|
1688
1767
|
field: string;
|
|
1689
1768
|
hint?: {
|
|
@@ -1746,6 +1825,8 @@ export declare function EmptyState({ icon: Icon, title, detail, action }: {
|
|
|
1746
1825
|
/** `?prefill=` payload encoder — base64 of the JSON, URL-encoded. */
|
|
1747
1826
|
export declare function encodePrefill(values: Record<string, unknown>): string;
|
|
1748
1827
|
|
|
1828
|
+
export declare function endHelpVideoWalk(): void;
|
|
1829
|
+
|
|
1749
1830
|
export declare function ErpFailureBanner({ collection, itemId }: {
|
|
1750
1831
|
collection: string;
|
|
1751
1832
|
itemId: string;
|
|
@@ -2484,6 +2565,294 @@ export declare interface HeaderWidgetInfo {
|
|
|
2484
2565
|
inputBindings: InputBinding[];
|
|
2485
2566
|
}
|
|
2486
2567
|
|
|
2568
|
+
/** Every mutation, as plain functions over the client. */
|
|
2569
|
+
export declare function helpVideoApi(client: NivaroClient): {
|
|
2570
|
+
create: (body: {
|
|
2571
|
+
upload_id: string;
|
|
2572
|
+
title?: string;
|
|
2573
|
+
contexts?: HelpVideoContext[];
|
|
2574
|
+
}) => Promise<HelpVideoDto>;
|
|
2575
|
+
update: (id: string, body: {
|
|
2576
|
+
title?: string;
|
|
2577
|
+
description?: string | null;
|
|
2578
|
+
category?: string | null;
|
|
2579
|
+
visibility?: Visibility;
|
|
2580
|
+
/** Viewers may download (authors always may). */
|
|
2581
|
+
allow_downloads?: boolean;
|
|
2582
|
+
}) => Promise<HelpVideoDto>;
|
|
2583
|
+
/** A fresh ticketed download link (relative to the API origin). 403
|
|
2584
|
+
* HELP_VIDEO_DOWNLOAD_OFF when downloads are off for this viewer; `draft`
|
|
2585
|
+
* is for authors. */
|
|
2586
|
+
downloadLink: (id: string, file?: "video" | "captions.vtt" | "captions.srt", draft?: boolean) => Promise<string>;
|
|
2587
|
+
setContexts: (id: string, contexts: HelpVideoContext[]) => Promise<unknown>;
|
|
2588
|
+
setRequirements: (id: string, role_ids: string[]) => Promise<unknown>;
|
|
2589
|
+
archive: (id: string) => Promise<unknown>;
|
|
2590
|
+
/** Deletes the video, its versions, files, views and requirements for good. Administrators
|
|
2591
|
+
* only (403 ADMIN_ONLY otherwise); 404 when it is already gone. */
|
|
2592
|
+
purge: (id: string) => Promise<unknown>;
|
|
2593
|
+
draft: (id: string) => Promise<VersionDto>;
|
|
2594
|
+
/** 409 HELP_VIDEO_EDITS_CONFLICT (with `current_hash`) when `base_hash` is stale;
|
|
2595
|
+
* 422 HELP_VIDEO_EDITS_INVALID when the edits keep under a second. */
|
|
2596
|
+
saveDraft: (id: string, edits: VideoEdits, base_hash?: string) => Promise<VersionDto>;
|
|
2597
|
+
publish: (id: string, watch_again: boolean) => Promise<HelpVideoDto>;
|
|
2598
|
+
rerecord: (id: string, upload_id: string) => Promise<VersionDto>;
|
|
2599
|
+
versions: (id: string) => Promise<(VersionDto & {
|
|
2600
|
+
is_published: boolean;
|
|
2601
|
+
is_draft: boolean;
|
|
2602
|
+
created_by_name: string | null;
|
|
2603
|
+
})[]>;
|
|
2604
|
+
restore: (id: string, versionId: string) => Promise<VersionDto>;
|
|
2605
|
+
rerender: (id: string, draft?: boolean) => Promise<unknown>;
|
|
2606
|
+
progress: (id: string, body: {
|
|
2607
|
+
position_ms: number;
|
|
2608
|
+
watched_ms_delta: number;
|
|
2609
|
+
buckets: string;
|
|
2610
|
+
version_id?: string;
|
|
2611
|
+
}) => Promise<{
|
|
2612
|
+
data: {
|
|
2613
|
+
completed: boolean;
|
|
2614
|
+
};
|
|
2615
|
+
} | undefined>;
|
|
2616
|
+
analytics: (id: string) => Promise<{
|
|
2617
|
+
views: number;
|
|
2618
|
+
unique_viewers: number;
|
|
2619
|
+
completion_rate: number;
|
|
2620
|
+
drop_off: number[];
|
|
2621
|
+
watched_hours: number;
|
|
2622
|
+
}>;
|
|
2623
|
+
openUpload: (mime: string) => Promise<{
|
|
2624
|
+
id: string;
|
|
2625
|
+
next_part: number;
|
|
2626
|
+
}>;
|
|
2627
|
+
/** Opens an upload for a video file someone picked. The server ignores the
|
|
2628
|
+
* browser's type: the first part's bytes decide the container (MP4/MOV or
|
|
2629
|
+
* WebM; 422 UPLOAD_NOT_VIDEO otherwise). 503 UPLOAD_NO_FFMPEG when the
|
|
2630
|
+
* server cannot read videos, 413 past 1.2 GB. */
|
|
2631
|
+
openFileUpload: (file: {
|
|
2632
|
+
name: string;
|
|
2633
|
+
size: number;
|
|
2634
|
+
type: string;
|
|
2635
|
+
}) => Promise<{
|
|
2636
|
+
id: string;
|
|
2637
|
+
next_part: number;
|
|
2638
|
+
}>;
|
|
2639
|
+
/** Closes a picked file's upload. The server checks (and if needed
|
|
2640
|
+
* converts) it in the background: poll uploadStatus until `finalized`. */
|
|
2641
|
+
finalizeFileUpload: (id: string) => Promise<{
|
|
2642
|
+
data: unknown;
|
|
2643
|
+
}>;
|
|
2644
|
+
uploadStatus: (id: string) => Promise<UploadRow>;
|
|
2645
|
+
/**
|
|
2646
|
+
* Closes an upload and stores the recorder's data with it, as given.
|
|
2647
|
+
* - `duration_ms`: recording time without pauses (the server prefers its
|
|
2648
|
+
* own probe of the file; 0 when unknown).
|
|
2649
|
+
* - `clicks`: `{ t_ms, x, y }` per click on the recorded tab: `t_ms` is
|
|
2650
|
+
* recording time, `x`/`y` are fractions (0–1) of the captured frame;
|
|
2651
|
+
* plus what was clicked (label, role, hook, page_key, path, origin —
|
|
2652
|
+
* see RecordedClick). Null when clicks were not captured.
|
|
2653
|
+
* - `levels`: microphone loudness, one number from 0 (silence) to 1 every
|
|
2654
|
+
* 100 ms of recording time (10 per second), so `levels[i]` covers
|
|
2655
|
+
* `i * 100` ms. Null without a microphone.
|
|
2656
|
+
* Matches `HelpVideoVersion.clicks` / `.levels` in @nivaro/sdk.
|
|
2657
|
+
* 422 UPLOAD_TOO_LONG past 31 minutes, 409 UPLOAD_CLOSED when finished.
|
|
2658
|
+
*/
|
|
2659
|
+
finalizeUpload: (id: string, meta: {
|
|
2660
|
+
duration_ms: number;
|
|
2661
|
+
clicks: RecordedClick[] | null;
|
|
2662
|
+
levels: number[] | null;
|
|
2663
|
+
}) => Promise<{
|
|
2664
|
+
file_id: string;
|
|
2665
|
+
duration_ms: number | null;
|
|
2666
|
+
}>;
|
|
2667
|
+
myUploads: () => Promise<UploadRow[]>;
|
|
2668
|
+
abandonUpload: (id: string) => Promise<unknown>;
|
|
2669
|
+
/** The published version's walk steps (none for a draft-only video). */
|
|
2670
|
+
walk: (id: string) => Promise<{
|
|
2671
|
+
version_id: string | null;
|
|
2672
|
+
steps: WalkStep[];
|
|
2673
|
+
}>;
|
|
2674
|
+
registerPage: (key: string, label: string, app?: string) => Promise<unknown>;
|
|
2675
|
+
authorRoles: () => Promise<string[]>;
|
|
2676
|
+
setAuthorRoles: (ids: string[]) => Promise<unknown>;
|
|
2677
|
+
};
|
|
2678
|
+
|
|
2679
|
+
export declare function HelpVideoButton({ collection, item, page, pageLabel, compact }: {
|
|
2680
|
+
collection?: string;
|
|
2681
|
+
item?: string | number;
|
|
2682
|
+
page?: string;
|
|
2683
|
+
/** Name authors see when choosing where a video shows (registered once per 10 min). */
|
|
2684
|
+
pageLabel?: string;
|
|
2685
|
+
compact?: boolean;
|
|
2686
|
+
}): JSX.Element;
|
|
2687
|
+
|
|
2688
|
+
export declare type HelpVideoContext = {
|
|
2689
|
+
kind: 'collection' | 'page';
|
|
2690
|
+
key: string;
|
|
2691
|
+
state_key: string | null;
|
|
2692
|
+
};
|
|
2693
|
+
|
|
2694
|
+
export declare interface HelpVideoDto {
|
|
2695
|
+
id: string;
|
|
2696
|
+
title: string;
|
|
2697
|
+
description: string | null;
|
|
2698
|
+
category: string | null;
|
|
2699
|
+
status: 'draft' | 'published' | 'archived';
|
|
2700
|
+
duration_ms: number | null;
|
|
2701
|
+
/** Ticketed URLs (`?st=`, relative to the API origin): use them as given,
|
|
2702
|
+
* never rebuild them. Tickets expire after 3–6 hours. */
|
|
2703
|
+
poster_url: string | null;
|
|
2704
|
+
stream_url: string | null;
|
|
2705
|
+
captions_url: string | null;
|
|
2706
|
+
contexts: HelpVideoContext[];
|
|
2707
|
+
/** Required for THIS viewer's role (not for the video in general). */
|
|
2708
|
+
required: boolean;
|
|
2709
|
+
published: VersionDto | null;
|
|
2710
|
+
visibility?: Visibility;
|
|
2711
|
+
required_role_ids?: string[];
|
|
2712
|
+
draft?: VersionDto | null;
|
|
2713
|
+
/** Author-only: the draft is exactly the published version (same recording,
|
|
2714
|
+
* same edits), so publishing it would change nothing. */
|
|
2715
|
+
draft_matches_published?: boolean;
|
|
2716
|
+
/** The draft's original recording (already carries `source=1`). */
|
|
2717
|
+
draft_stream_url?: string | null;
|
|
2718
|
+
draft_captions_url?: string | null;
|
|
2719
|
+
/** Author-only: the "Allow downloads" switch (for viewers; authors always may). */
|
|
2720
|
+
allow_downloads?: boolean;
|
|
2721
|
+
/** Author-only: the draft's downloads (render when current, else the original). */
|
|
2722
|
+
draft_download_urls?: DownloadUrls | null;
|
|
2723
|
+
created_by_name?: string | null;
|
|
2724
|
+
/** Null when this person may not download the published version. A
|
|
2725
|
+
* viewer's video link answers 409 HELP_VIDEO_PROCESSING while
|
|
2726
|
+
* `published.playable` is false. */
|
|
2727
|
+
download_urls: DownloadUrls | null;
|
|
2728
|
+
updated_at: string;
|
|
2729
|
+
my_progress: HelpVideoProgress | null;
|
|
2730
|
+
}
|
|
2731
|
+
|
|
2732
|
+
export declare function HelpVideoEditor({ videoId, onClose }: {
|
|
2733
|
+
videoId: string;
|
|
2734
|
+
onClose?: () => void;
|
|
2735
|
+
}): JSX.Element;
|
|
2736
|
+
|
|
2737
|
+
export declare const helpVideoKeys: {
|
|
2738
|
+
all: readonly ["help-videos"];
|
|
2739
|
+
one: (id: string) => readonly ["help-videos", "one", string];
|
|
2740
|
+
forCtx: (ctx: Record<string, unknown>) => readonly ["help-videos", "for", Record<string, unknown>];
|
|
2741
|
+
library: (p: Record<string, unknown>) => readonly ["help-videos", "library", Record<string, unknown>];
|
|
2742
|
+
required: readonly ["help-videos", "required"];
|
|
2743
|
+
pages: readonly ["help-videos", "pages"];
|
|
2744
|
+
walk: (id: string) => readonly ["help-videos", "walk", string];
|
|
2745
|
+
/** The editor's draft load. Outside the `all` prefix on purpose: GET
|
|
2746
|
+
* /draft/edits creates a missing draft, so a broad invalidation must
|
|
2747
|
+
* never refetch it. `n` bumps on Reload. */
|
|
2748
|
+
draftEdits: (id: string, n: number) => readonly ["help-video-draft", string, number];
|
|
2749
|
+
};
|
|
2750
|
+
|
|
2751
|
+
export declare function HelpVideoLibrary({ watchId, editId, onWatch, onEdit, headerExtra }: {
|
|
2752
|
+
watchId: string | null;
|
|
2753
|
+
editId: string | null;
|
|
2754
|
+
onWatch: (id: string | null) => void;
|
|
2755
|
+
onEdit: (id: string | null) => void;
|
|
2756
|
+
/** Host slot beside the Record button (admin puts "Who can record" there). */
|
|
2757
|
+
headerExtra?: React.ReactNode;
|
|
2758
|
+
}): JSX.Element;
|
|
2759
|
+
|
|
2760
|
+
/** Keyed by video id: switching to another video starts a fresh player, so
|
|
2761
|
+
* progress, the resume point and the one-retry flag never carry over. */
|
|
2762
|
+
export declare function HelpVideoPlayer(props: HelpVideoPlayerProps): JSX.Element;
|
|
2763
|
+
|
|
2764
|
+
declare type HelpVideoPlayerProps = {
|
|
2765
|
+
video: HelpVideoDto;
|
|
2766
|
+
/** viewer = rendered file when current; live = always source + edits (authors). */
|
|
2767
|
+
mode?: 'viewer' | 'live';
|
|
2768
|
+
/** Editor working copy (live mode). */
|
|
2769
|
+
edits?: VideoEdits;
|
|
2770
|
+
/** Play the draft (authors in the editor). */
|
|
2771
|
+
useDraft?: boolean;
|
|
2772
|
+
onTime?: (sourceMs: number, editedMs: number) => void;
|
|
2773
|
+
trackProgress?: boolean;
|
|
2774
|
+
autoPlay?: boolean;
|
|
2775
|
+
handleRef?: MutableRefObject<PlayerHandle | null>;
|
|
2776
|
+
/** Start here (edited time) instead of the viewer's resume point. */
|
|
2777
|
+
startAtMs?: number | null;
|
|
2778
|
+
className?: string;
|
|
2779
|
+
/** Rendered in frame coordinates above the video, outside the zoom (editor tools). */
|
|
2780
|
+
children?: (frame: {
|
|
2781
|
+
width: number;
|
|
2782
|
+
height: number;
|
|
2783
|
+
}) => ReactNode;
|
|
2784
|
+
};
|
|
2785
|
+
|
|
2786
|
+
declare interface HelpVideoProgress {
|
|
2787
|
+
position_ms: number;
|
|
2788
|
+
completed: boolean;
|
|
2789
|
+
percent: number;
|
|
2790
|
+
}
|
|
2791
|
+
|
|
2792
|
+
/**
|
|
2793
|
+
* Records this tab, a window or the whole screen with optional microphone
|
|
2794
|
+
* narration. Parts upload every five seconds and are kept in this browser
|
|
2795
|
+
* (IndexedDB) before they are sent and until the server confirms each one, so
|
|
2796
|
+
* an outage or a closed tab loses nothing: recording carries on through an
|
|
2797
|
+
* outage, and a refused or interrupted recording stays in the browser until
|
|
2798
|
+
* the person keeps or discards it. Recording stops by itself at 30:00.
|
|
2799
|
+
*
|
|
2800
|
+
* During recording only a small control bar shows. It portals into the
|
|
2801
|
+
* hosting [role="dialog"] when the recorder sits inside one (a modal sheet
|
|
2802
|
+
* makes everything outside it unclickable), else into document.body.
|
|
2803
|
+
*/
|
|
2804
|
+
export declare function HelpVideoRecorder({ open, onClose, onDone, videoId, contexts, defaultTitle, barHost: hostOverride }: {
|
|
2805
|
+
open: boolean;
|
|
2806
|
+
onClose: () => void;
|
|
2807
|
+
onDone: (video: HelpVideoDto) => void;
|
|
2808
|
+
videoId?: string;
|
|
2809
|
+
contexts?: HelpVideoContext[];
|
|
2810
|
+
defaultTitle?: string;
|
|
2811
|
+
/** Mount the setup dialog and the recording bar inside this element (the
|
|
2812
|
+
* modal the recording was started from) while it is connected; document.body
|
|
2813
|
+
* after it goes. Without it the recorder follows its own place in the tree. */
|
|
2814
|
+
barHost?: HTMLElement | null;
|
|
2815
|
+
}): JSX.Element | null;
|
|
2816
|
+
|
|
2817
|
+
/**
|
|
2818
|
+
* Holds ONE recorder for the whole app. A walkthrough means clicking through
|
|
2819
|
+
* other screens, and a recorder mounted inside a screen ends the take at the
|
|
2820
|
+
* first route change.
|
|
2821
|
+
*
|
|
2822
|
+
* Placement (hosts: admin, efp-new): mount it ONCE, ABOVE the router outlet
|
|
2823
|
+
* and ABOVE every screen that calls useHelpVideoRecording(), and INSIDE a
|
|
2824
|
+
* QueryClientProvider, a NivaroProvider and an app-level NavigationContext
|
|
2825
|
+
* (navigate plus helpVideosPath). Without a NavigationContext it falls back
|
|
2826
|
+
* to window.location.href and the default /help-videos path.
|
|
2827
|
+
*/
|
|
2828
|
+
export declare function HelpVideoRecordingProvider({ children }: {
|
|
2829
|
+
children: ReactNode;
|
|
2830
|
+
}): JSX.Element;
|
|
2831
|
+
|
|
2832
|
+
export declare function HelpVideoSheet({ videoId, open, onOpenChange, upNext, onPick, returnFocusRef, startAtMs, showMe }: {
|
|
2833
|
+
videoId: string | null;
|
|
2834
|
+
open: boolean;
|
|
2835
|
+
onOpenChange: (open: boolean) => void;
|
|
2836
|
+
/** Other videos for the same screen, offered under the player. */
|
|
2837
|
+
upNext?: HelpVideoDto[];
|
|
2838
|
+
onPick?: (id: string) => void;
|
|
2839
|
+
/** Where focus goes on close when the opener unmounts while the sheet is
|
|
2840
|
+
* open (a popover row). Absent = whatever had focus when the sheet opened. */
|
|
2841
|
+
returnFocusRef?: RefObject<HTMLElement | null>;
|
|
2842
|
+
/** Start the player here (edited time), e.g. a walk's "Watch this step". */
|
|
2843
|
+
startAtMs?: number | null;
|
|
2844
|
+
/** Offer "Show me on this page" when the video has steps for this screen. */
|
|
2845
|
+
showMe?: boolean;
|
|
2846
|
+
}): JSX.Element;
|
|
2847
|
+
|
|
2848
|
+
/**
|
|
2849
|
+
* Draws the guided walk ("Show me on this page") when one is running. Mount
|
|
2850
|
+
* it once per host; several may be mounted (the recording provider, every
|
|
2851
|
+
* help-video sheet) and only the earliest still mounted draws, so a walk
|
|
2852
|
+
* survives the sheet that started it closing.
|
|
2853
|
+
*/
|
|
2854
|
+
export declare function HelpVideoWalkHost(): JSX.Element | null;
|
|
2855
|
+
|
|
2487
2856
|
/** Always-visible horizontal scrollbar proxy for the table scroller —
|
|
2488
2857
|
* overlay-OS scrollbars hide, so wide tables get a persistent draggable
|
|
2489
2858
|
* track pinned above the pagination footer. */
|
|
@@ -3305,10 +3674,23 @@ export declare interface IntegrationSignalView {
|
|
|
3305
3674
|
shown: number;
|
|
3306
3675
|
}
|
|
3307
3676
|
|
|
3677
|
+
/** A title card before the recording (real extra edited time). Blank
|
|
3678
|
+
* `title` / `subtitle` mean the video's title and the first line of its
|
|
3679
|
+
* description. */
|
|
3680
|
+
declare interface IntroCard {
|
|
3681
|
+
enabled: true;
|
|
3682
|
+
duration_ms: number;
|
|
3683
|
+
show_chapters: boolean;
|
|
3684
|
+
title: string;
|
|
3685
|
+
subtitle: string;
|
|
3686
|
+
}
|
|
3687
|
+
|
|
3308
3688
|
/** Whether this browser pinned the chat panel open — hosts read it for their
|
|
3309
3689
|
* initial open state, so a pinned panel is still there after a reload. */
|
|
3310
3690
|
export declare function isChatPanelPinned(): boolean;
|
|
3311
3691
|
|
|
3692
|
+
export declare function isCleanRecording(): boolean;
|
|
3693
|
+
|
|
3312
3694
|
export declare function ItemActionButtons({ collection, itemId }: {
|
|
3313
3695
|
collection: string;
|
|
3314
3696
|
itemId: string;
|
|
@@ -3321,7 +3703,7 @@ export declare type ItemEditAuthContextValue = {
|
|
|
3321
3703
|
userId: string;
|
|
3322
3704
|
};
|
|
3323
3705
|
|
|
3324
|
-
export declare function ItemEditForm({ collection, itemId: itemIdProp, layoutSlug: layoutSlugProp, initialAddendumViewId, onAddendumViewChange, onBack, onSaved, onDeleted, showHeader, headerExtra, focusField, showItemActions, onDirtyChange, documentTitle, registerSaveHandler, onDuplicate, showRevisions, showClone, showPipeline, showWorkflow, showComments, showTasks, showLockBanner, className, headerClassName, renderField, extraTopContent, extraBottomContent, onHeaderWidgets, autofillProposalId, onAutofillConsumed, initialImportResult, initialValues, initialLinks, initialRows }: ItemEditFormProps): JSX.Element;
|
|
3706
|
+
export declare function ItemEditForm({ collection, itemId: itemIdProp, layoutSlug: layoutSlugProp, initialAddendumViewId, onAddendumViewChange, onBack, onSaved, onDeleted, showHeader, headerExtra, focusField, showItemActions, onDirtyChange, documentTitle, registerSaveHandler, onDuplicate, showRevisions, showClone, showPipeline, showWorkflow, showComments, showTasks, showLockBanner, className, headerClassName, renderField, extraTopContent, hideHelpVideoButton, extraBottomContent, onHeaderWidgets, autofillProposalId, onAutofillConsumed, initialImportResult, initialValues, initialLinks, initialRows }: ItemEditFormProps): JSX.Element;
|
|
3325
3707
|
|
|
3326
3708
|
export declare interface ItemEditFormProps {
|
|
3327
3709
|
collection: string;
|
|
@@ -3381,6 +3763,8 @@ export declare interface ItemEditFormProps {
|
|
|
3381
3763
|
headerClassName?: string;
|
|
3382
3764
|
renderField?: (props: RenderFieldProps) => ReactNode;
|
|
3383
3765
|
extraTopContent?: ReactNode;
|
|
3766
|
+
/** Hide the header's own Videos button, for a host whose top bar already carries it. */
|
|
3767
|
+
hideHelpVideoButton?: boolean;
|
|
3384
3768
|
extraBottomContent?: ReactNode;
|
|
3385
3769
|
onHeaderWidgets?: (widgets: HeaderWidgetInfo[]) => void;
|
|
3386
3770
|
/** Open the new-record form on a stored document proposal (`?autofill=<id>`
|
|
@@ -3909,6 +4293,9 @@ export declare type NavigationContextValue = {
|
|
|
3909
4293
|
* the link is hidden. Headless hosts that embed the admin elsewhere can
|
|
3910
4294
|
* return an absolute URL. */
|
|
3911
4295
|
consoleUrl?: (adminPath: string) => string | null;
|
|
4296
|
+
/** Where the host mounts the help-video library (`?watch=` / `?edit=` are read there).
|
|
4297
|
+
* Absent = `/help-videos` (the admin route). */
|
|
4298
|
+
helpVideosPath?: string;
|
|
3912
4299
|
};
|
|
3913
4300
|
|
|
3914
4301
|
export declare function networkdaysBetween(a: Date, b: Date): number;
|
|
@@ -4408,6 +4795,13 @@ export declare function OutboundPreviewSection({ collection, itemId, onShowReque
|
|
|
4408
4795
|
onJump?: () => void;
|
|
4409
4796
|
}): JSX.Element | null;
|
|
4410
4797
|
|
|
4798
|
+
/** An end card after the recording. Blank `text` means OUTRO_DEFAULT_TEXT. */
|
|
4799
|
+
declare interface OutroCard {
|
|
4800
|
+
enabled: true;
|
|
4801
|
+
duration_ms: number;
|
|
4802
|
+
text: string;
|
|
4803
|
+
}
|
|
4804
|
+
|
|
4411
4805
|
/**
|
|
4412
4806
|
* Lets a host put transient overlay state — a drill-down sheet and how deep it
|
|
4413
4807
|
* is — into browser history, so Back closes the sheet instead of abandoning the
|
|
@@ -4887,9 +5281,27 @@ export declare interface PlanGridRowHistoryArgs {
|
|
|
4887
5281
|
onClose: () => void;
|
|
4888
5282
|
}
|
|
4889
5283
|
|
|
5284
|
+
export declare type PlayerHandle = {
|
|
5285
|
+
seekEdited(ms: number): void;
|
|
5286
|
+
seekSource(ms: number): void;
|
|
5287
|
+
play(): void;
|
|
5288
|
+
pause(): void;
|
|
5289
|
+
sourceMs(): number;
|
|
5290
|
+
editedMs(): number;
|
|
5291
|
+
frame(): {
|
|
5292
|
+
width: number;
|
|
5293
|
+
height: number;
|
|
5294
|
+
} | null;
|
|
5295
|
+
};
|
|
5296
|
+
|
|
4890
5297
|
/** Play the configured notification sound. No-op for 'off'/unknown/unavailable audio. */
|
|
4891
5298
|
export declare function playNotificationSound(kind: NotificationSound | string | null | undefined): void;
|
|
4892
5299
|
|
|
5300
|
+
declare type Point = {
|
|
5301
|
+
x: number;
|
|
5302
|
+
y: number;
|
|
5303
|
+
};
|
|
5304
|
+
|
|
4893
5305
|
declare function pollProposal(opts: {
|
|
4894
5306
|
fetchResult: () => Promise<ProposalPollAnswer>;
|
|
4895
5307
|
onRunning?: (documentName?: string) => void;
|
|
@@ -5597,6 +6009,25 @@ export declare function RecordDrilldownSheet({ collection, itemId, layoutId, roo
|
|
|
5597
6009
|
onClose: () => void;
|
|
5598
6010
|
}): JSX.Element;
|
|
5599
6011
|
|
|
6012
|
+
/**
|
|
6013
|
+
* One click on the recorded tab: recording time and frame fractions (0–1).
|
|
6014
|
+
* When the recorder captured its own tab, also what was clicked: accessible
|
|
6015
|
+
* name (≤ 80 chars, never an input's value), role, nearest data-* hook
|
|
6016
|
+
* (`data-name` or `data-name=value`), the screen's page key, path and origin.
|
|
6017
|
+
* Inside `.nvr-no-record` only the position is kept.
|
|
6018
|
+
*/
|
|
6019
|
+
export declare type RecordedClick = {
|
|
6020
|
+
t_ms: number;
|
|
6021
|
+
x: number;
|
|
6022
|
+
y: number;
|
|
6023
|
+
label?: string;
|
|
6024
|
+
role?: string;
|
|
6025
|
+
hook?: string;
|
|
6026
|
+
page_key?: string;
|
|
6027
|
+
path?: string;
|
|
6028
|
+
origin?: string;
|
|
6029
|
+
};
|
|
6030
|
+
|
|
5600
6031
|
export declare function RecordGraphExplorer({ collection, itemId, className }: {
|
|
5601
6032
|
collection: string;
|
|
5602
6033
|
itemId: string;
|
|
@@ -5717,6 +6148,8 @@ export declare function RecordGridWidgetBody({ widget }: {
|
|
|
5717
6148
|
widget: PageRendererWidget;
|
|
5718
6149
|
}): JSX.Element;
|
|
5719
6150
|
|
|
6151
|
+
export declare const RECORDING_HIDE_ATTR = "data-nvr-recording-hide";
|
|
6152
|
+
|
|
5720
6153
|
export declare function RecordReadView({ collection, itemId, layoutData, flush, renderSlot, integrityMarks, renderGrid, onEditSection, gridCounts }: {
|
|
5721
6154
|
collection: string;
|
|
5722
6155
|
itemId: string;
|
|
@@ -5789,6 +6222,13 @@ export declare function RecordSubscribeButton({ collection, itemId, recordLabel,
|
|
|
5789
6222
|
compact?: boolean;
|
|
5790
6223
|
}): JSX.Element;
|
|
5791
6224
|
|
|
6225
|
+
declare type Rect = {
|
|
6226
|
+
x: number;
|
|
6227
|
+
y: number;
|
|
6228
|
+
w: number;
|
|
6229
|
+
h: number;
|
|
6230
|
+
};
|
|
6231
|
+
|
|
5792
6232
|
/** Register a detail opener for a catalog collection. Returns an unregister
|
|
5793
6233
|
* cleanup — call it on unmount so a dead host can't leave a stale opener. */
|
|
5794
6234
|
export declare function registerCatalogItemOpener(collection: string, fn: CatalogItemOpener): () => void;
|
|
@@ -5798,6 +6238,9 @@ export declare function registerDmOpener(fn: DmOpener): () => void;
|
|
|
5798
6238
|
|
|
5799
6239
|
export declare function registerFieldInterface(plugin: FieldInterfacePlugin): void;
|
|
5800
6240
|
|
|
6241
|
+
/** Marks `key` as the screen's page key until the returned function runs. */
|
|
6242
|
+
export declare function registerHelpVideoPage(key: string): () => void;
|
|
6243
|
+
|
|
5801
6244
|
export declare function registerLayoutSlot(plugin: LayoutSlotPlugin): void;
|
|
5802
6245
|
|
|
5803
6246
|
export declare function registerRoomOpener(fn: RoomOpener): () => void;
|
|
@@ -5890,6 +6333,8 @@ export declare type RenderFieldProps = {
|
|
|
5890
6333
|
requiredParentLabel?: string | null;
|
|
5891
6334
|
};
|
|
5892
6335
|
|
|
6336
|
+
declare type RenderStatus = 'none' | 'queued' | 'rendering' | 'ready' | 'failed' | 'unavailable';
|
|
6337
|
+
|
|
5893
6338
|
export declare function ReportView({ reportId, showFilterBar, dateRange, initialEntityFilters, refetchInterval, className, emptyState, reportUrl }: ReportViewProps & {
|
|
5894
6339
|
reportUrl?: (id: string) => string;
|
|
5895
6340
|
}): JSX.Element;
|
|
@@ -5934,6 +6379,10 @@ export declare function ReportWidgetCard({ reportId, widget, dateRange, entityFi
|
|
|
5934
6379
|
entityFilters?: ReportEntityFilter[];
|
|
5935
6380
|
}): JSX.Element;
|
|
5936
6381
|
|
|
6382
|
+
export declare function RequiredVideosCard({ className }: {
|
|
6383
|
+
className?: string;
|
|
6384
|
+
}): JSX.Element;
|
|
6385
|
+
|
|
5937
6386
|
export declare function resolveCollectionIcon(iconName: string | null | undefined): React.ElementType | null;
|
|
5938
6387
|
|
|
5939
6388
|
export declare function resolveNotificationTarget(collection: string | null | undefined, item: string | null | undefined, routes: NotificationRouteMap): NotificationTarget;
|
|
@@ -6290,6 +6739,12 @@ export declare function seedQuickPickerSteps(fieldConfig: Array<{
|
|
|
6290
6739
|
junction_field: string | null;
|
|
6291
6740
|
}>, collection: string): string[];
|
|
6292
6741
|
|
|
6742
|
+
declare interface Segment {
|
|
6743
|
+
start_ms: number;
|
|
6744
|
+
end_ms: number;
|
|
6745
|
+
speed: Speed;
|
|
6746
|
+
}
|
|
6747
|
+
|
|
6293
6748
|
export declare function SelectField({ field, value, onChange, error, disabled, readOnly, inputId, errorId }: FieldComponentProps): JSX.Element;
|
|
6294
6749
|
|
|
6295
6750
|
declare interface SendInput {
|
|
@@ -6351,6 +6806,10 @@ export declare function setNumberFormat(opts: {
|
|
|
6351
6806
|
compact?: boolean;
|
|
6352
6807
|
} | null | undefined): void;
|
|
6353
6808
|
|
|
6809
|
+
/** Tells shared components who the signed-in person is, so their own photo
|
|
6810
|
+
* reads as Demo User during a clean recording. Hosts call it once they know. */
|
|
6811
|
+
export declare function setRecordingSelf(userId: string | number | null | undefined): void;
|
|
6812
|
+
|
|
6354
6813
|
export declare function setTimeDisplay(mode: string | null | undefined): void;
|
|
6355
6814
|
|
|
6356
6815
|
/**
|
|
@@ -6509,6 +6968,8 @@ export declare function SnoozeMenu({ signal, signalLabel, rowKey, group, default
|
|
|
6509
6968
|
compact?: boolean;
|
|
6510
6969
|
}): JSX.Element;
|
|
6511
6970
|
|
|
6971
|
+
declare type Speed = 1 | 1.5 | 2 | 4;
|
|
6972
|
+
|
|
6512
6973
|
export declare function splitMessageTokens(text: string, entityPattern: string): MessageToken[];
|
|
6513
6974
|
|
|
6514
6975
|
declare type SpreadPreset = 'even' | 'front' | 'back' | 'shape';
|
|
@@ -6533,6 +6994,27 @@ export declare function startAutofillRun(cfg: FetchCfg, run: {
|
|
|
6533
6994
|
poll?: typeof pollProposal;
|
|
6534
6995
|
}): AutofillRun;
|
|
6535
6996
|
|
|
6997
|
+
export declare function startHelpVideoWalk(w: {
|
|
6998
|
+
videoId: string;
|
|
6999
|
+
title: string;
|
|
7000
|
+
steps: WalkStep[];
|
|
7001
|
+
index?: number;
|
|
7002
|
+
}): void;
|
|
7003
|
+
|
|
7004
|
+
export declare type StartRecordingOptions = {
|
|
7005
|
+
/** Where the new video shows (a new recording only). */
|
|
7006
|
+
contexts?: HelpVideoContext[];
|
|
7007
|
+
/** Re-record this video instead of making a new one. */
|
|
7008
|
+
videoId?: string;
|
|
7009
|
+
/** Called with the saved video when the caller is still mounted. When the
|
|
7010
|
+
* caller is gone (or gave none) the provider opens the editor instead. */
|
|
7011
|
+
onDone?: (video: HelpVideoDto) => void;
|
|
7012
|
+
/** An element of the caller. When it sits inside a modal dialog or sheet, the
|
|
7013
|
+
* setup dialog and the recording bar mount inside that modal (a modal makes
|
|
7014
|
+
* everything outside it unclickable). Absent = the element focused at start. */
|
|
7015
|
+
from?: HTMLElement | null;
|
|
7016
|
+
};
|
|
7017
|
+
|
|
6536
7018
|
export declare function startRum(opts?: {
|
|
6537
7019
|
app?: string;
|
|
6538
7020
|
routePattern?: (path: string) => string;
|
|
@@ -6807,6 +7289,8 @@ export declare function titleCase(str: string): string;
|
|
|
6807
7289
|
|
|
6808
7290
|
export declare type TokenResolver = (path: string) => unknown;
|
|
6809
7291
|
|
|
7292
|
+
declare type Tone = 'accent' | 'warning' | 'neutral';
|
|
7293
|
+
|
|
6810
7294
|
/** Which of the four alert tones an outcome reads as — overdue/failed/missing
|
|
6811
7295
|
* are the record still does NOT have what it should (danger); pending and
|
|
6812
7296
|
* skipped are in flight or a deliberate no with a reason (warning, worth a
|
|
@@ -6942,6 +7426,31 @@ declare interface UnsavedSummary {
|
|
|
6942
7426
|
text: string;
|
|
6943
7427
|
}
|
|
6944
7428
|
|
|
7429
|
+
/** An upload session as `/help-videos/uploads/*` returns it. */
|
|
7430
|
+
declare type UploadRow = {
|
|
7431
|
+
id: string;
|
|
7432
|
+
bytes_received: number;
|
|
7433
|
+
next_part: number;
|
|
7434
|
+
/** `open`, `finalizing`, `finalized` (uploaded, not yet a video), `used`
|
|
7435
|
+
* or `abandoned`. */
|
|
7436
|
+
status: string;
|
|
7437
|
+
duration_ms: number | null;
|
|
7438
|
+
created_at: string;
|
|
7439
|
+
updated_at: string;
|
|
7440
|
+
/** 'recording' from the recorder, 'upload' for a picked video file. */
|
|
7441
|
+
source?: 'recording' | 'upload';
|
|
7442
|
+
/** Picked files: the file's name and size. */
|
|
7443
|
+
name?: string | null;
|
|
7444
|
+
size?: number | null;
|
|
7445
|
+
/** Picked files while finishing: 'checking' | 'converting' | 'saving'. */
|
|
7446
|
+
phase?: string | null;
|
|
7447
|
+
/** Picked files while converting: 0–100. */
|
|
7448
|
+
progress?: number | null;
|
|
7449
|
+
/** Why a picked file was not kept (`abandoned`), or why saving failed (`open`). */
|
|
7450
|
+
error?: string | null;
|
|
7451
|
+
error_code?: string | null;
|
|
7452
|
+
};
|
|
7453
|
+
|
|
6945
7454
|
/**
|
|
6946
7455
|
* `useAfterIdle(ms)` — false on mount, true once the browser has had `ms` of
|
|
6947
7456
|
* settle time after the first paint. Gate secondary reads on it (freshness
|
|
@@ -7049,6 +7558,9 @@ export declare function useChatSearch(q: string, filters?: ChatSearchFilters): {
|
|
|
7049
7558
|
loading: boolean;
|
|
7050
7559
|
};
|
|
7051
7560
|
|
|
7561
|
+
/** True while a clean recording runs. */
|
|
7562
|
+
export declare function useCleanRecording(): boolean;
|
|
7563
|
+
|
|
7052
7564
|
export declare function useCreateChannel(): UseMutationResult<unknown, Error, {
|
|
7053
7565
|
name: string;
|
|
7054
7566
|
key?: string;
|
|
@@ -7067,6 +7579,8 @@ user_ids: string[];
|
|
|
7067
7579
|
name?: string;
|
|
7068
7580
|
}, unknown>;
|
|
7069
7581
|
|
|
7582
|
+
export declare function useCurrentHelpVideoPage(): string | null;
|
|
7583
|
+
|
|
7070
7584
|
/**
|
|
7071
7585
|
* Returns a value that trails `value` by `delayMs`. Useful for keeping text
|
|
7072
7586
|
* inputs bound to live state while queries key off the debounced copy so a
|
|
@@ -7159,8 +7673,45 @@ export declare function useFormStatus(form: UseNivaroFormReturn): FormStatus;
|
|
|
7159
7673
|
|
|
7160
7674
|
export declare function useGridFlush(): GridFlushContextValue | null;
|
|
7161
7675
|
|
|
7676
|
+
export declare function useHelpVideo(id: string | null): UseQueryResult<NoInfer<HelpVideoDto>, Error>;
|
|
7677
|
+
|
|
7678
|
+
/**
|
|
7679
|
+
* Start a recording from anywhere. With a provider above, the recording
|
|
7680
|
+
* survives this component unmounting. Without one, `fallback` is a local
|
|
7681
|
+
* recorder the caller renders (it ends with the caller), so nothing breaks
|
|
7682
|
+
* before a host mounts the provider.
|
|
7683
|
+
*/
|
|
7684
|
+
export declare function useHelpVideoRecording(): {
|
|
7685
|
+
/** false when a recording is already in progress (show RECORDING_BUSY). */
|
|
7686
|
+
start: (opts?: StartRecordingOptions) => boolean;
|
|
7687
|
+
active: boolean;
|
|
7688
|
+
/** Render this somewhere in the caller. Null when a provider hosts the recorder. */
|
|
7689
|
+
fallback: ReactNode;
|
|
7690
|
+
};
|
|
7691
|
+
|
|
7692
|
+
export declare function useHelpVideosFor(ctx: {
|
|
7693
|
+
collection?: string;
|
|
7694
|
+
item?: string | number;
|
|
7695
|
+
state?: string;
|
|
7696
|
+
page?: string;
|
|
7697
|
+
}, enabled?: boolean): UseQueryResult<NoInfer<{
|
|
7698
|
+
data: HelpVideoDto[];
|
|
7699
|
+
can_author: boolean;
|
|
7700
|
+
state: string | null;
|
|
7701
|
+
}>, Error>;
|
|
7702
|
+
|
|
7703
|
+
/** "Show me on this page": the published version's labelled clicks. */
|
|
7704
|
+
export declare function useHelpVideoWalk(id: string | null): UseQueryResult<NoInfer<{
|
|
7705
|
+
version_id: string | null;
|
|
7706
|
+
steps: WalkStep[];
|
|
7707
|
+
}>, Error>;
|
|
7708
|
+
|
|
7162
7709
|
export declare function useImportHealth(): UseQueryResult<NoInfer<ImportHealth>, Error>;
|
|
7163
7710
|
|
|
7711
|
+
/** True when clean mode runs AND `userId` is the signed-in person (the host's
|
|
7712
|
+
* setRecordingSelf, else the record form's auth context). */
|
|
7713
|
+
export declare function useIsRecordingSelf(userId: string | number | null | undefined): boolean;
|
|
7714
|
+
|
|
7164
7715
|
export declare function useItemEditAuth(): ItemEditAuthContextValue;
|
|
7165
7716
|
|
|
7166
7717
|
export declare function useItemLock(collection: string | undefined, item: string | undefined, enabled: boolean): {
|
|
@@ -7352,6 +7903,9 @@ export declare function useQuickPickerSteps(collection: string | null | undefine
|
|
|
7352
7903
|
* The FALLBACK is the caller's own styled disc: every site already has its
|
|
7353
7904
|
* exact colors/ring/size, and this component must never change how a user
|
|
7354
7905
|
* without a photo renders.
|
|
7906
|
+
*
|
|
7907
|
+
* During a clean help-video recording the signed-in person's own avatar reads
|
|
7908
|
+
* as a neutral "DU" (Demo User) disc; everyone else's stays.
|
|
7355
7909
|
*/
|
|
7356
7910
|
export declare function UserAvatar({ userId, fallback, className, style, alt }: {
|
|
7357
7911
|
userId: string | number | null | undefined;
|
|
@@ -7399,6 +7953,8 @@ export declare function useRelationOptions(client: NivaroClient | null, relatedC
|
|
|
7399
7953
|
error: Error | null;
|
|
7400
7954
|
};
|
|
7401
7955
|
|
|
7956
|
+
export declare function useRequiredVideos(): UseQueryResult<NoInfer<HelpVideoDto[]>, Error>;
|
|
7957
|
+
|
|
7402
7958
|
export declare function useRoomMembership(): {
|
|
7403
7959
|
join: UseMutationResult<unknown, Error, string, unknown>;
|
|
7404
7960
|
leave: UseMutationResult<unknown, Error, string, unknown>;
|
|
@@ -7556,6 +8112,49 @@ declare interface ValidationResult {
|
|
|
7556
8112
|
unknownTokens: string[];
|
|
7557
8113
|
}
|
|
7558
8114
|
|
|
8115
|
+
declare interface VersionDto {
|
|
8116
|
+
id: string;
|
|
8117
|
+
version: number;
|
|
8118
|
+
edits: VideoEdits;
|
|
8119
|
+
edits_hash: string;
|
|
8120
|
+
source_duration_ms: number | null;
|
|
8121
|
+
width: number | null;
|
|
8122
|
+
height: number | null;
|
|
8123
|
+
render_status: RenderStatus;
|
|
8124
|
+
render_progress: number | null;
|
|
8125
|
+
render_error: string | null;
|
|
8126
|
+
rendered_current: boolean;
|
|
8127
|
+
/** Published version only: false when a non-author would get the 409
|
|
8128
|
+
* HELP_VIDEO_PROCESSING ("still being prepared") from the stream. */
|
|
8129
|
+
playable?: boolean;
|
|
8130
|
+
note: string | null;
|
|
8131
|
+
created_at: string;
|
|
8132
|
+
/** Draft, re-record and restore results only (recorder data). */
|
|
8133
|
+
/** Clicks on the recorded tab: `t_ms` source time, `x`/`y` frame fractions (0–1);
|
|
8134
|
+
* recorded since #1486, also what was clicked (see RecordedClick). */
|
|
8135
|
+
clicks?: RecordedClick[] | null;
|
|
8136
|
+
/** Microphone loudness 0–1, one value per 100 ms of source time. */
|
|
8137
|
+
levels?: number[] | null;
|
|
8138
|
+
/** Draft load only: 'upload' when the source is a video file someone picked
|
|
8139
|
+
* (it has no clicks and no microphone levels), else 'recording'. */
|
|
8140
|
+
source_kind?: 'recording' | 'upload';
|
|
8141
|
+
}
|
|
8142
|
+
|
|
8143
|
+
export declare interface VideoEdits {
|
|
8144
|
+
v: 1;
|
|
8145
|
+
segments: Segment[];
|
|
8146
|
+
poster_ms: number;
|
|
8147
|
+
chapters: Chapter[];
|
|
8148
|
+
annotations: Annotation[];
|
|
8149
|
+
zooms: Zoom[];
|
|
8150
|
+
blurs: Blur[];
|
|
8151
|
+
captions: Caption[];
|
|
8152
|
+
/** Stored only while switched on (absent = off). */
|
|
8153
|
+
intro?: IntroCard;
|
|
8154
|
+
outro?: OutroCard;
|
|
8155
|
+
chapter_banners?: true;
|
|
8156
|
+
}
|
|
8157
|
+
|
|
7559
8158
|
export declare function viewAs(person: {
|
|
7560
8159
|
id: string;
|
|
7561
8160
|
name: string;
|
|
@@ -7573,6 +8172,25 @@ declare type ViewAsOpener = (person: {
|
|
|
7573
8172
|
name: string;
|
|
7574
8173
|
}) => void | Promise<void>;
|
|
7575
8174
|
|
|
8175
|
+
declare type Visibility = {
|
|
8176
|
+
mode: 'everyone' | 'roles';
|
|
8177
|
+
role_ids: string[];
|
|
8178
|
+
};
|
|
8179
|
+
|
|
8180
|
+
/** One step of "Show me on this page" (GET /help-videos/:id/walk). */
|
|
8181
|
+
export declare interface WalkStep {
|
|
8182
|
+
label: string;
|
|
8183
|
+
role: string | null;
|
|
8184
|
+
hook: string | null;
|
|
8185
|
+
page_key: string | null;
|
|
8186
|
+
path: string | null;
|
|
8187
|
+
origin: string | null;
|
|
8188
|
+
/** Where the step happens in the finished video (edited time). */
|
|
8189
|
+
edited_ms: number;
|
|
8190
|
+
/** The callout or box text shown around the click, else null. */
|
|
8191
|
+
text: string | null;
|
|
8192
|
+
}
|
|
8193
|
+
|
|
7576
8194
|
export declare function WidgetSlot({ widgetId, inputBindings, itemDraft, itemCollection, ready, label, defaultExpanded, frameless, apiBase: apiBaseProp, compact, strip, onClientAction, onWidgetType, onContentChange }: WidgetSlotProps): JSX.Element | null;
|
|
7577
8195
|
|
|
7578
8196
|
declare interface WidgetSlotProps {
|
|
@@ -7606,4 +8224,12 @@ export declare function WorkflowPanel({ collection, item }: {
|
|
|
7606
8224
|
item: string;
|
|
7607
8225
|
}): JSX.Element | null;
|
|
7608
8226
|
|
|
8227
|
+
declare interface Zoom {
|
|
8228
|
+
id: string;
|
|
8229
|
+
start_ms: number;
|
|
8230
|
+
end_ms: number;
|
|
8231
|
+
rect: Rect;
|
|
8232
|
+
ease_ms: number;
|
|
8233
|
+
}
|
|
8234
|
+
|
|
7609
8235
|
export { }
|