@overmap-ai/blocks 1.0.27-attachment-viewers.7 → 1.0.27-custom-table-component.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.
package/README.md CHANGED
@@ -1,3 +1,3 @@
1
- # overmap-ai blocks
2
-
3
- Contains basic components used by overmap-ai libraries.
1
+ # overmap-ai blocks
2
+
3
+ Contains basic components used by overmap-ai libraries.
@@ -17,5 +17,4 @@ export interface MultiPagePopoverProps extends Omit<PopoverProps, "content"> {
17
17
  page: MultiPagePopoverPage;
18
18
  className?: string;
19
19
  direction?: "vertical" | "horizontal";
20
- color: "light" | "dark";
21
20
  }
@@ -1,2 +1,2 @@
1
1
  import { OvermapItemSizes, SizeDependableProps } from "./typings";
2
- export declare const SizePropsMapping: Record<OvermapItemSizes, SizeDependableProps>;
2
+ export declare const OvermapItemSizeDependantProps: Record<OvermapItemSizes, SizeDependableProps>;
@@ -14,7 +14,7 @@ export interface OvermapItemProps extends Omit<HTMLProps<HTMLDivElement>, "ref"
14
14
  leftSlot?: ReactNode;
15
15
  /** content to be rendered on the right of any children */
16
16
  rightSlot?: ReactNode;
17
- /** */
17
+ /** supports five different sizes, changing the overall proportions of the OvermapItem including font size. */
18
18
  size?: OvermapResponsive<OvermapItemSizes>;
19
19
  }
20
20
  export {};
@@ -0,0 +1,8 @@
1
+ /// <reference types="react" />
2
+ import { PaginationStatus } from "./typings.ts";
3
+ import { Size } from "../typings.ts";
4
+ type PaginationControlsProps = Pick<PaginationStatus<unknown>, "currentPage" | "setCurrentPage" | "visiblePages"> & {
5
+ size: Size;
6
+ };
7
+ export declare const PaginationControls: import("react").MemoExoticComponent<(props: PaginationControlsProps) => import("react/jsx-runtime").JSX.Element | null>;
8
+ export {};
@@ -0,0 +1,2 @@
1
+ import { PaginationStatus } from "./typings.ts";
2
+ export declare const usePagination: <TItem>(items: TItem[], itemsPerPage: number, maxVisiblePages: number) => PaginationStatus<TItem>;
@@ -0,0 +1,6 @@
1
+ export type PaginationStatus<TItem> = {
2
+ page: TItem[];
3
+ currentPage: number;
4
+ setCurrentPage: (page: number) => void;
5
+ visiblePages: (number | null)[];
6
+ };
@@ -1,3 +1,11 @@
1
- import { FC } from "react";
2
- import { TableProps } from "./typings";
3
- export declare const Table: FC<TableProps>;
1
+ import { CSSProperties } from "react";
2
+ import { TableColumn, TableRow } from "./typings";
3
+ export interface TableProps {
4
+ columns: TableColumn[];
5
+ data: TableRow[];
6
+ emptyMessage?: string;
7
+ className?: string;
8
+ style?: CSSProperties;
9
+ columnClassName?: string;
10
+ }
11
+ export declare const Table: import("react").MemoExoticComponent<(props: TableProps) => import("react/jsx-runtime").JSX.Element>;
@@ -40,30 +40,3 @@ export interface TableRow {
40
40
  };
41
41
  decorator?: (row: ReactElement) => ReactElement;
42
42
  }
43
- export interface TableProps {
44
- columns: TableColumn[];
45
- data: TableRow[];
46
- color?: "light" | "dark";
47
- title?: string | ReactNode;
48
- description?: string | ReactNode;
49
- defaultRowsPerPage?: number;
50
- rowsPerPage?: number[];
51
- fixHeader?: boolean;
52
- showSearchBar?: boolean;
53
- searchBarPlaceholder?: string;
54
- showSelect?: boolean;
55
- showFilterButton?: boolean;
56
- showContainer?: boolean;
57
- showRowsPerPage?: boolean;
58
- showPageNumber?: boolean;
59
- showPageNavigation?: boolean;
60
- children?: ReactNode;
61
- topBarComponents?: ReactNode;
62
- showTopBar?: boolean;
63
- showBottomBar?: boolean;
64
- emptyMessage?: string;
65
- className?: string;
66
- columnClassName?: string;
67
- rowClassName?: string;
68
- cellClassName?: string;
69
- }