@factorialco/f0-react 4.51.0 → 4.52.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.
@@ -4104,6 +4104,22 @@ declare const defaultTranslations: {
4104
4104
  readonly other: "Showing the first {{count}} rows";
4105
4105
  };
4106
4106
  };
4107
+ readonly videoPlayer: {
4108
+ readonly regionLabel: "Video player";
4109
+ readonly play: "Play";
4110
+ readonly pause: "Pause";
4111
+ readonly playing: "Playing";
4112
+ readonly paused: "Paused";
4113
+ readonly mute: "Mute";
4114
+ readonly unmute: "Unmute";
4115
+ readonly volume: "Volume";
4116
+ readonly seekLabel: "Seek";
4117
+ readonly enterFullscreen: "Enter fullscreen";
4118
+ readonly exitFullscreen: "Exit fullscreen";
4119
+ readonly playbackSpeed: "Playback speed ({{rate}})";
4120
+ readonly playbackSpeedLabel: "Playback speed";
4121
+ readonly timeProgress: "{{current}} of {{total}}";
4122
+ };
4107
4123
  };
4108
4124
 
4109
4125
  export declare interface DeleteBlockNotesTextEditorPageDocumentPatch {
@@ -11383,16 +11399,6 @@ declare namespace Calendar {
11383
11399
  }
11384
11400
 
11385
11401
 
11386
- declare module "@tiptap/core" {
11387
- interface Commands<ReturnType> {
11388
- aiBlock: {
11389
- insertAIBlock: (data: AIBlockData, config: AIBlockConfig) => ReturnType;
11390
- executeAIAction: (actionType: string, config: AIBlockConfig) => ReturnType;
11391
- };
11392
- }
11393
- }
11394
-
11395
-
11396
11402
  declare module "@tiptap/core" {
11397
11403
  interface Commands<ReturnType> {
11398
11404
  enhanceHighlight: {
@@ -11414,6 +11420,16 @@ declare module "@tiptap/core" {
11414
11420
  }
11415
11421
 
11416
11422
 
11423
+ declare module "@tiptap/core" {
11424
+ interface Commands<ReturnType> {
11425
+ aiBlock: {
11426
+ insertAIBlock: (data: AIBlockData, config: AIBlockConfig) => ReturnType;
11427
+ executeAIAction: (actionType: string, config: AIBlockConfig) => ReturnType;
11428
+ };
11429
+ }
11430
+ }
11431
+
11432
+
11417
11433
  declare module "@tiptap/core" {
11418
11434
  interface Commands<ReturnType> {
11419
11435
  transcript: {
package/dist/f0.d.ts CHANGED
@@ -5310,6 +5310,22 @@ export declare const defaultTranslations: {
5310
5310
  readonly other: "Showing the first {{count}} rows";
5311
5311
  };
5312
5312
  };
5313
+ readonly videoPlayer: {
5314
+ readonly regionLabel: "Video player";
5315
+ readonly play: "Play";
5316
+ readonly pause: "Pause";
5317
+ readonly playing: "Playing";
5318
+ readonly paused: "Paused";
5319
+ readonly mute: "Mute";
5320
+ readonly unmute: "Unmute";
5321
+ readonly volume: "Volume";
5322
+ readonly seekLabel: "Seek";
5323
+ readonly enterFullscreen: "Enter fullscreen";
5324
+ readonly exitFullscreen: "Exit fullscreen";
5325
+ readonly playbackSpeed: "Playback speed ({{rate}})";
5326
+ readonly playbackSpeedLabel: "Playback speed";
5327
+ readonly timeProgress: "{{current}} of {{total}}";
5328
+ };
5313
5329
  };
5314
5330
 
5315
5331
  /**
@@ -11880,6 +11896,57 @@ export declare type F0ToolCall = {
11880
11896
  };
11881
11897
  };
11882
11898
 
11899
+ /**
11900
+ * @experimental This is an experimental component, use it at your own risk.
11901
+ *
11902
+ * Video player built on a native `<video>` element with f0-styled controls
11903
+ * (play/pause, seekbar, volume, playback speed, fullscreen) plus keyboard
11904
+ * shortcuts. Analytics, watch-% milestones, completion and forward-seek
11905
+ * restriction are built in and enabled via props (`onTrackAction`,
11906
+ * `onMilestone`, `onComplete`, `restrictForwardSeek`).
11907
+ */
11908
+ export declare const F0VideoPlayer: WithDataTestIdReturnType_3<typeof F0VideoPlayerInternal>;
11909
+
11910
+ /**
11911
+ * Video player built on a native `<video>` element.
11912
+ *
11913
+ * useVideoState → element ref, native listeners, derived state.
11914
+ * useFullscreen → toggles fullscreen on the wrapper (keeps controls visible).
11915
+ * useKeyboardShortcuts → Space, ←/→, ↑/↓, M, F.
11916
+ * useVideoTracking → analytics callback on play/pause + interval.
11917
+ * useVideoMilestones → watched-% milestone callbacks (25/50/75).
11918
+ * useVideoCompletion → "watched enough" callback (min(10s, 3%)).
11919
+ * useRestrictForwardSeek → blocks seeking past the furthest-watched point.
11920
+ * <Controls> → presentation only; interactions delegated back here.
11921
+ */
11922
+ declare function F0VideoPlayerInternal({ src, autoPlay, autoFocus, restrictForwardSeek, onTrackAction, onMilestone, onComplete, ...dataAttributes }: F0VideoPlayerProps): JSX_2.Element;
11923
+
11924
+ export declare interface F0VideoPlayerProps extends DataAttributes_2 {
11925
+ /** Video source URL. */
11926
+ src: string;
11927
+ /** Start playing on mount. Default `false`. */
11928
+ autoPlay?: boolean;
11929
+ /** Focus the player on mount so keyboard shortcuts work immediately. Default `false`. */
11930
+ autoFocus?: boolean;
11931
+ /**
11932
+ * Prevent seeking past the furthest point already watched. Renders a marker at
11933
+ * that position and blocks the cursor beyond it. Default `false`.
11934
+ */
11935
+ restrictForwardSeek?: boolean;
11936
+ /** Called on play, on pause and on a recurring heartbeat during playback. */
11937
+ onTrackAction?: () => void;
11938
+ /**
11939
+ * Called once when each watched-% milestone (`25`, `50`, `75`) is first
11940
+ * reached. For progress analytics; completion is reported via `onComplete`.
11941
+ */
11942
+ onMilestone?: (milestone: number, video: HTMLVideoElement) => void;
11943
+ /**
11944
+ * Called once when the video is "watched enough": the remaining time drops to
11945
+ * `min(10s, 3% of duration)` (the later of "last 10s" and "97%").
11946
+ */
11947
+ onComplete?: (video: HTMLVideoElement) => void;
11948
+ }
11949
+
11883
11950
  export declare const F0WizardForm: {
11884
11951
  <TSchema extends F0FormSchema_2>(props: F0WizardFormSingleSchemaProps<TSchema>): default_2.ReactElement;
11885
11952
  <T extends F0PerSectionSchema_2>(props: F0WizardFormPerSectionProps<T>): default_2.ReactElement;
@@ -18374,16 +18441,6 @@ declare namespace Calendar {
18374
18441
  }
18375
18442
 
18376
18443
 
18377
- declare module "@tiptap/core" {
18378
- interface Commands<ReturnType> {
18379
- aiBlock: {
18380
- insertAIBlock: (data: AIBlockData, config: AIBlockConfig) => ReturnType;
18381
- executeAIAction: (actionType: string, config: AIBlockConfig) => ReturnType;
18382
- };
18383
- }
18384
- }
18385
-
18386
-
18387
18444
  declare module "@tiptap/core" {
18388
18445
  interface Commands<ReturnType> {
18389
18446
  enhanceHighlight: {
@@ -18405,6 +18462,16 @@ declare module "@tiptap/core" {
18405
18462
  }
18406
18463
 
18407
18464
 
18465
+ declare module "@tiptap/core" {
18466
+ interface Commands<ReturnType> {
18467
+ aiBlock: {
18468
+ insertAIBlock: (data: AIBlockData, config: AIBlockConfig) => ReturnType;
18469
+ executeAIAction: (actionType: string, config: AIBlockConfig) => ReturnType;
18470
+ };
18471
+ }
18472
+ }
18473
+
18474
+
18408
18475
  declare module "@tiptap/core" {
18409
18476
  interface Commands<ReturnType> {
18410
18477
  transcript: {