@factorialco/f0-react 4.47.3 → 4.49.2

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.
@@ -812,6 +812,20 @@ blurArea?: "l" | "r" | "lr";
812
812
 
813
813
  export declare const AreaChartWidget: ForwardRefExoticComponent<Omit<AreaChartWidgetProps & RefAttributes<HTMLDivElement>, "ref"> & RefAttributes<HTMLElement | SVGElement>>;
814
814
 
815
+ /**
816
+ * Upper bound for the resolved page size, so a very tall container never
817
+ * fetches an unreasonably large page.
818
+ */
819
+ export declare const AUTO_PER_PAGE_MAX = 30;
820
+
821
+ /**
822
+ * Number of rows the min-height reservation keeps space for (see
823
+ * `getAutoPerPageMinHeight`). This is NOT a lower bound on the page size — the
824
+ * page size always matches what actually fits, so it never overflows. It only
825
+ * sizes the space a squeezed collection reserves to stay usable.
826
+ */
827
+ export declare const AUTO_PER_PAGE_MIN_RESERVED_ROWS = 10;
828
+
815
829
  export declare const AutoGrid: ForwardRefExoticComponent<Omit<HTMLAttributes<HTMLDivElement> & VariantProps<(props?: ({
816
830
  tileSize?: "lg" | "md" | "sm" | undefined;
817
831
  gap?: "0" | "1" | "2" | "3" | "4" | "lg" | "md" | "sm" | "5" | "6" | "7" | "8" | "9" | "10" | "11" | "12" | "14" | "16" | "px" | "xl" | "1.5" | "0.5" | "2.5" | undefined;
@@ -6635,6 +6649,15 @@ declare interface GaugeComputation {
6635
6649
 
6636
6650
  export declare function generateCSVContent<R extends RecordType, Filters extends FiltersDefinition, Sortings extends SortingsDefinition, Summaries extends SummariesDefinition, ItemActions extends ItemActionsDefinition<R>, NavigationFilters extends NavigationFiltersDefinition, Grouping extends GroupingDefinition<R>>(data: R[], visualization: Visualization<R, Filters, Sortings, Summaries, ItemActions, NavigationFilters, Grouping> | undefined, options?: CSVExportOptions): string;
6637
6651
 
6652
+ /**
6653
+ * Minimum height a `perPage: "auto"` collection reserves so it stays usable
6654
+ * (space for AUTO_PER_PAGE_MIN_RESERVED_ROWS rows plus chrome). Applied as a
6655
+ * `min-height` so the collection stays visible when its siblings would
6656
+ * otherwise squeeze it to nothing — the whole page scrolls instead of the
6657
+ * collection disappearing.
6658
+ */
6659
+ export declare function getAutoPerPageMinHeight(rowHeight?: number): number;
6660
+
6638
6661
  export declare const getGranularityDefinition: (granularityKey: GranularityDefinitionKey) => GranularityDefinition;
6639
6662
 
6640
6663
  /**
@@ -8544,8 +8567,15 @@ declare interface PageProps {
8544
8567
  export declare type PaginatedDataAdapter<R extends RecordType, Filters extends FiltersDefinition, Options extends PaginatedFetchOptions<Filters> = PaginatedFetchOptions<Filters>, FetchReturn = PaginatedResponse<R>> = {
8545
8568
  /** Indicates this adapter uses page-based pagination */
8546
8569
  paginationType: PaginationType;
8547
- /** Default number of records per page */
8548
- perPage?: number;
8570
+ /**
8571
+ * Number of records per page. Pass `"auto"` to derive the page size from the
8572
+ * available vertical space (page-based pagination inside a `fullHeight`
8573
+ * collection only), sized to exactly the rows that fit (capped at 30). In a
8574
+ * `fullHeight` collection, leaving this unset behaves like `"auto"` — an
8575
+ * unspecified page size means "fill the height". Outside `fullHeight`, an
8576
+ * unset value falls back to the default page size.
8577
+ */
8578
+ perPage?: number | "auto";
8549
8579
  /**
8550
8580
  * Function to fetch paginated data based on filter and pagination options
8551
8581
  * @param options - The filter and pagination options to apply when fetching data