@wyxos/vibe 3.1.15 → 3.1.17

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.
@@ -3,6 +3,7 @@ export interface VibeAutoBucket {
3
3
  cursor: string | null;
4
4
  items: VibeViewerItem[];
5
5
  nextCursor: string | null;
6
+ nextCursorExhausted: boolean;
6
7
  previousCursor: string | null;
7
8
  }
8
9
  export declare function flattenVibeBuckets(buckets: VibeAutoBucket[]): VibeViewerItem[];
@@ -0,0 +1,15 @@
1
+ import { type VibeAutoBucket } from './autoBuckets';
2
+ import type { VibeAutoDirection } from './autoResolveHelpers';
3
+ export declare function findLeadingBoundaryBucket(buckets: VibeAutoBucket[], removedIds: Set<string>): VibeAutoBucket;
4
+ export declare function findTrailingBoundaryBucket(buckets: VibeAutoBucket[], removedIds: Set<string>): VibeAutoBucket;
5
+ export declare function getExhaustedNextCursor(bucket: VibeAutoBucket | null): string | null;
6
+ export declare function markVibeNextCursorExhausted(buckets: VibeAutoBucket[], originCursor: string | null | undefined, cursor: string | null, exhausted: boolean): VibeAutoBucket[];
7
+ export declare function resolveCollectedNextCursor(direction: VibeAutoDirection, cursor: string | null, nextPage: string | null): {
8
+ cursor: string | null;
9
+ exhausted: boolean;
10
+ };
11
+ export declare function resolveRefreshedNextCursor(bucket: VibeAutoBucket, nextPage: string | null): {
12
+ cursor: string | null;
13
+ exhausted: boolean;
14
+ };
15
+ export declare function trimVibeBucketsToVisibleWindow(buckets: VibeAutoBucket[], removedIds: Set<string>): VibeAutoBucket[];
@@ -17,6 +17,7 @@ export declare function isAbortError(error: unknown): boolean;
17
17
  export declare function createAutoResolveBucket(options: {
18
18
  cursor: string | null;
19
19
  nextCursor: string | null;
20
+ nextCursorExhausted?: boolean;
20
21
  nextItems: VibeViewerItem[];
21
22
  previousCursor: string | null;
22
23
  previousItems: VibeViewerItem[];
@@ -26,6 +27,7 @@ export declare function createAutoResolveBucket(options: {
26
27
  cursor: string | null;
27
28
  items: VibeViewerItem[];
28
29
  nextCursor: string | null;
30
+ nextCursorExhausted: boolean;
29
31
  previousCursor: string | null;
30
32
  };
31
33
  nextSequence: number;
@@ -34,6 +36,7 @@ export declare function refreshAutoResolveBucket(options: {
34
36
  cursor: string | null;
35
37
  edge: 'leading' | 'trailing';
36
38
  nextCursor: string | null;
39
+ nextCursorExhausted?: boolean;
37
40
  nextItems: VibeViewerItem[];
38
41
  previousCursor: string | null;
39
42
  previousItems: VibeViewerItem[];
@@ -43,6 +46,7 @@ export declare function refreshAutoResolveBucket(options: {
43
46
  cursor: string | null;
44
47
  items: VibeViewerItem[];
45
48
  nextCursor: string | null;
49
+ nextCursorExhausted: boolean;
46
50
  previousCursor: string | null;
47
51
  };
48
52
  nextSequence: number;
@@ -58,6 +62,7 @@ export declare function hydrateAutoResolveState(options: {
58
62
  cursor: string | null;
59
63
  items: VibeViewerItem[];
60
64
  nextCursor: string | null;
65
+ nextCursorExhausted: boolean;
61
66
  previousCursor: string | null;
62
67
  }[];
63
68
  nextSequence: number;
@@ -0,0 +1,24 @@
1
+ import type { VibeViewerItem } from '../viewer';
2
+ interface FullscreenAssetMediaController {
3
+ getItemKey: (item: VibeViewerItem) => string;
4
+ settleAssetPreload: (id: string) => void;
5
+ shouldHandleSlideAssetEvent: (index: number, item: VibeViewerItem) => boolean;
6
+ }
7
+ interface FullscreenAssetViewer {
8
+ onImageError: (id: string, url: string) => Promise<void>;
9
+ onImageLoad: (id: string, url: string) => void;
10
+ onMediaError: (id: string, url: string) => Promise<void>;
11
+ onMediaEvent: (id: string, event: Event) => void;
12
+ }
13
+ export declare function useFullscreenAssetEvents(options: {
14
+ fullscreenMedia: FullscreenAssetMediaController;
15
+ updateDominantToneFromImageElement: (id: string, image: HTMLImageElement) => void;
16
+ viewer: FullscreenAssetViewer;
17
+ }): {
18
+ getHandledItemKey: (index: number, item: VibeViewerItem) => string | null;
19
+ onFullscreenImageError: (index: number, item: VibeViewerItem) => Promise<void>;
20
+ onFullscreenImageLoad: (event: Event, index: number, item: VibeViewerItem) => void;
21
+ onFullscreenMediaError: (index: number, item: VibeViewerItem) => Promise<void>;
22
+ onFullscreenMediaEvent: (index: number, item: VibeViewerItem, event: Event) => string | null;
23
+ };
24
+ export {};
@@ -26,5 +26,6 @@ export declare function useFullscreenSurfaceMedia(options: {
26
26
  registerImageElement: (id: string, element: unknown) => void;
27
27
  registerMediaElement: (id: string, element: unknown) => void;
28
28
  settleAssetPreload: (id: string) => void;
29
+ shouldHandleSlideAssetEvent: (index: number, item: VibeViewerItem) => boolean;
29
30
  shouldPreloadSlideAsset: (index: number) => boolean;
30
31
  };