@factorialco/f0-react 2.60.0 → 2.61.1

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/f0.d.ts CHANGED
@@ -409,6 +409,21 @@ declare type ActionVariant = (typeof actionVariants)[number];
409
409
 
410
410
  declare const actionVariants: readonly ["default", "outline", "critical", "neutral", "ghost", "promote", "outlinePromote", "ai", "link", "unstyled", "mention"];
411
411
 
412
+ /**
413
+ * Wraps a `pages`-paginated data adapter so it presents itself as
414
+ * `infinite-scroll`, letting page-based sources (the typical list adapter) be
415
+ * consumed by components that only support cursor pagination — e.g.
416
+ * `F0Select` and the breadcrumb jump-to select.
417
+ *
418
+ * The cursor is the stringified next page: `cursor: null` fetches page 1,
419
+ * `cursor: "3"` fetches page 3, and `hasMore` is derived from
420
+ * `currentPage < pagesCount`. All three `fetchData` return channels (sync,
421
+ * Promise, Observable of PromiseState) are mapped; loading/error emissions
422
+ * pass through untouched. Adapters that already are `infinite-scroll` /
423
+ * `no-pagination` are returned as-is (same reference).
424
+ */
425
+ export declare const adaptDataAdapterToInfiniteScroll: <R extends RecordType, Filters extends FiltersDefinition>(dataAdapter: DataAdapter<R, Filters>) => DataAdapter<R, Filters>;
426
+
412
427
  declare type AddRowActionsResult = PrimaryActionItemDefinition | PrimaryActionItemDefinition[] | undefined;
413
428
 
414
429
  /* Excluded from this release type: AgentState */
@@ -9816,6 +9831,12 @@ declare type F0SelectBaseProps<T extends string, R = unknown> = {
9816
9831
  onSearchChange?: (value: string) => void;
9817
9832
  searchValue?: string;
9818
9833
  onOpenChange?: (open: boolean) => void;
9834
+ /**
9835
+ * Called when the user changes the in-dropdown filters (requires a `source`
9836
+ * with filter definitions). Lets consumers keep an external context — e.g.
9837
+ * detail-page navigation — in sync with what the dropdown is showing.
9838
+ */
9839
+ onFiltersChange?: (filters: FiltersState<FiltersDefinition>) => void;
9819
9840
  searchEmptyMessage?: string;
9820
9841
  className?: string;
9821
9842
  actions?: Action_2[];
@@ -15877,7 +15898,7 @@ export declare const useGroups: <R extends RecordType>(groups: GroupRecord<R>[],
15877
15898
  * id is null, nothing is fetched and `neighbors` stays null — consumers
15878
15899
  * keep their fallback behaviour.
15879
15900
  */
15880
- export declare function useItemNeighbors<R extends RecordType, Filters extends FiltersDefinition>({ dataAdapter, id, filters, sortings, search, enabled, onError, }: UseItemNeighborsOptions<R, Filters>): UseItemNeighborsReturn<R>;
15901
+ export declare function useItemNeighbors<R extends RecordType, Filters extends FiltersDefinition>({ dataAdapter, id, filters, sortings, search, enabled, fetchParamsProvider, onError, }: UseItemNeighborsOptions<R, Filters>): UseItemNeighborsReturn<R>;
15881
15902
 
15882
15903
  export declare interface UseItemNeighborsOptions<R extends RecordType, Filters extends FiltersDefinition> {
15883
15904
  /** The adapter that may implement the `fetchItemNeighbors` capability */
@@ -15896,6 +15917,13 @@ export declare interface UseItemNeighborsOptions<R extends RecordType, Filters e
15896
15917
  * @default true
15897
15918
  */
15898
15919
  enabled?: boolean;
15920
+ /**
15921
+ * Extends/transforms the options passed to `fetchItemNeighbors`, mirroring
15922
+ * `useData`'s option of the same name — e.g. OneDataCollection adds
15923
+ * `navigationFilters`. The extended options also key the response cache,
15924
+ * so extra context invalidates it correctly.
15925
+ */
15926
+ fetchParamsProvider?: <O extends BaseFetchOptions<Filters>>(options: O) => O;
15899
15927
  onError?: (error: DataError) => void;
15900
15928
  }
15901
15929
 
@@ -16359,6 +16387,11 @@ declare module "gridstack" {
16359
16387
  }
16360
16388
 
16361
16389
 
16390
+ declare namespace Calendar {
16391
+ var displayName: string;
16392
+ }
16393
+
16394
+
16362
16395
  declare module "@tiptap/core" {
16363
16396
  interface Commands<ReturnType> {
16364
16397
  aiBlock: {
@@ -16408,11 +16441,6 @@ declare module "@tiptap/core" {
16408
16441
  }
16409
16442
 
16410
16443
 
16411
- declare namespace Calendar {
16412
- var displayName: string;
16413
- }
16414
-
16415
-
16416
16444
  declare namespace F0GraphNodeWrapperInner {
16417
16445
  var displayName: string;
16418
16446
  }