@smart-factor/gem-ui-components 0.0.80 → 0.0.82

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.
Files changed (31) hide show
  1. package/dist/{Drawer-CldXrceX.js → Drawer-BHtGTSrC.js} +42 -42
  2. package/dist/SignEditor.js +17847 -45443
  3. package/dist/{Tree-zB7xEw6c.js → Tree-COTxbWgl.js} +1 -1
  4. package/dist/components/Drawer/index.js +1 -1
  5. package/dist/components/Tree/index.js +1 -1
  6. package/dist/helpers/index.d.ts +1 -0
  7. package/dist/hooks/index.d.ts +1 -0
  8. package/dist/hooks/useDebounce.d.ts +1 -0
  9. package/dist/hooks/useTableQuery/JSONParseSafe.d.ts +1 -0
  10. package/dist/hooks/useTableQuery/downloadBlob.d.ts +1 -0
  11. package/dist/hooks/useTableQuery/getLogicOperator.d.ts +3 -0
  12. package/dist/hooks/useTableQuery/helpers.d.ts +3 -0
  13. package/dist/hooks/useTableQuery/index.d.ts +1 -0
  14. package/dist/hooks/useTableQuery/isOperatorWithValue.d.ts +1 -0
  15. package/dist/hooks/useTableQuery/normalizeFilterModel.d.ts +3 -0
  16. package/dist/hooks/useTableQuery/toPrimitiveValue.d.ts +1 -0
  17. package/dist/hooks/useTableQuery/types.d.ts +4 -0
  18. package/dist/hooks/useTableQuery/useDataGridQueryState.d.ts +3 -0
  19. package/dist/hooks/useTableQuery/useExportGridAsExcel.d.ts +11 -0
  20. package/dist/hooks/useTableQuery/useExportToExcel.d.ts +3 -0
  21. package/dist/hooks/useTableQuery/usePaginationAndSort.d.ts +30 -0
  22. package/dist/hooks/useTableQuery/useSetQueryParamValues.d.ts +9 -0
  23. package/dist/hooks/useTableQuery/useTableFilter.d.ts +15 -0
  24. package/dist/hooks/useTableQuery/useTableQuery.d.ts +28 -0
  25. package/dist/licenses.txt +409 -409
  26. package/dist/main.js +1733 -1384
  27. package/dist/services/generated/api-candidate.d.ts +22942 -0
  28. package/dist/theme-D2kKiipg.js +421649 -0
  29. package/dist/{useFormControl-v82Vw7n0.js → useFormControl-DNMBlMLT.js} +3 -3
  30. package/package.json +1 -1
  31. package/dist/theme-6BrOzZN-.js +0 -39427
@@ -2,7 +2,7 @@ import { jsx as w, jsxs as ve } from "react/jsx-runtime";
2
2
  import * as x from "react";
3
3
  import { createElement as Wt } from "react";
4
4
  import { p as fe, q as me, r as U, _ as D, v as nt, O as Jt, A as Gt, w as Le, x as Ht, Q as Yt, l as de, y as Ie, P as r, R as ot, z as ge, D as Qe, U as Qt, I as rt, j as Zt, V as it, b as ue, e as te, t as en, h as tn, k as G, o as nn, J as on, g as rn, H as ce, W as sn, X as st, Y as ie, G as Ze, i as ln, K as an, S as cn, M as dn, N as un } from "./Stack-CU3sSZaK.js";
5
- import { u as pn, a as fn, b as X } from "./useFormControl-v82Vw7n0.js";
5
+ import { u as pn, a as fn, b as X } from "./useFormControl-DNMBlMLT.js";
6
6
  function mn(e) {
7
7
  return fe("MuiCollapse", e);
8
8
  }
@@ -1,4 +1,4 @@
1
- import { D as e } from "../../Drawer-CldXrceX.js";
1
+ import { D as e } from "../../Drawer-BHtGTSrC.js";
2
2
  export {
3
3
  e as Drawer
4
4
  };
@@ -1,4 +1,4 @@
1
- import { T as o } from "../../Tree-zB7xEw6c.js";
1
+ import { T as o } from "../../Tree-COTxbWgl.js";
2
2
  export {
3
3
  o as Tree
4
4
  };
@@ -1,3 +1,4 @@
1
1
  export * from './columns';
2
2
  export * from './date';
3
3
  export { getErrorMessage } from './getErrorMessage';
4
+ export * from './zodTransforms';
@@ -2,3 +2,4 @@ export { useContextMenu } from './useContextMenu';
2
2
  export { useDataGridState } from './useDataGridState';
3
3
  export { useGetFileUrl } from './useGetFileUrl';
4
4
  export { useScrollPosition } from './useScrollPosition';
5
+ export { useTableQuery } from './useTableQuery';
@@ -0,0 +1 @@
1
+ export declare function useDebounce(value: any, delay: number, callback?: () => void): any;
@@ -0,0 +1 @@
1
+ export declare const JSONParseSafe: (value: unknown) => any;
@@ -0,0 +1 @@
1
+ export declare function downloadBlob(blob: Blob, name?: string): void;
@@ -0,0 +1,3 @@
1
+ import { GridFilterModel, GridLogicOperator } from '@mui/x-data-grid-pro';
2
+
3
+ export declare const getLogicOperator: (filterModel: GridFilterModel | undefined) => GridLogicOperator | undefined;
@@ -0,0 +1,3 @@
1
+ export type DataGridQueryState = Record<string, unknown>[] | undefined;
2
+ export declare const getDataGridQueryStateFromLocalStorage: (key: string) => DataGridQueryState;
3
+ export declare const getQueryFromGridQueryState: <T>(gridQueryState: DataGridQueryState | undefined, key: string) => T | undefined;
@@ -0,0 +1 @@
1
+ export { useTableQuery } from './useTableQuery';
@@ -0,0 +1 @@
1
+ export declare const isOperatorWithValue: (operator: string) => boolean;
@@ -0,0 +1,3 @@
1
+ import { GridFilterModel } from '@mui/x-data-grid-pro';
2
+
3
+ export declare const normalizeFilterModel: (filterModel: GridFilterModel | undefined) => GridFilterModel;
@@ -0,0 +1 @@
1
+ export declare function toPrimitiveValue<T>(value: T): string | T | undefined;
@@ -0,0 +1,4 @@
1
+ export declare enum TabType {
2
+ ALL = 0,
3
+ MINE = 1
4
+ }
@@ -0,0 +1,3 @@
1
+ import { DataGridQueryState } from './helpers';
2
+
3
+ export declare const useDataGridQueryState: (key: string, allQueryParams: DataGridQueryState) => DataGridQueryState;
@@ -0,0 +1,11 @@
1
+ import { GridApiPro, GridFilterModel } from '@mui/x-data-grid-pro';
2
+
3
+ interface UseExportGridAsExcelProps {
4
+ mine: boolean;
5
+ entityType: string;
6
+ generalSearchText: string;
7
+ filterModel: GridFilterModel | undefined;
8
+ fileNameLabel?: string;
9
+ }
10
+ export declare const useExportGridAsExcel: ({ mine, entityType, generalSearchText, filterModel, fileNameLabel, }: UseExportGridAsExcelProps) => (gridApiRef: React.MutableRefObject<GridApiPro>) => Promise<void>;
11
+ export {};
@@ -0,0 +1,3 @@
1
+ import { ExportRequest } from '../../services/generated/api';
2
+
3
+ export declare const exportToExcel: (payload: ExportRequest) => Promise<Blob>;
@@ -0,0 +1,30 @@
1
+ import { DataGridQueryState } from './helpers';
2
+
3
+ interface SortState {
4
+ field: string;
5
+ direction: 'asc' | 'desc' | '';
6
+ }
7
+ export interface PaginationAndSort {
8
+ page: number;
9
+ size: number;
10
+ sort: SortState;
11
+ }
12
+ export declare const usePaginationAndSort: (dataGridQueryState?: DataGridQueryState) => {
13
+ paginationAndSortState: PaginationAndSort;
14
+ setPaginationAndSortState: import('react').Dispatch<import('react').SetStateAction<PaginationAndSort>>;
15
+ routerPaginationAndSortQueryParams: {
16
+ query: string;
17
+ newValue: string | number;
18
+ }[];
19
+ apiRequestPaginationAndSortParams: {
20
+ [k: string]: string | number;
21
+ };
22
+ };
23
+ export declare const transformMapToRouterParams: (paginationAndSortParamsMap: Map<string, string | number>) => {
24
+ query: string;
25
+ newValue: string | number;
26
+ }[];
27
+ export declare const transformMapToApiRequestParams: (paginationAndSortParamsMap: Map<string, string | number>) => {
28
+ [k: string]: string | number;
29
+ };
30
+ export {};
@@ -0,0 +1,9 @@
1
+ type V = string | number | boolean | undefined;
2
+ export interface QueryParam {
3
+ query: string;
4
+ newValue?: V | V[] | {
5
+ [k: string]: V | V[];
6
+ };
7
+ }
8
+ export declare const useUpdateQueryParams: (listOfQueriesToSet: QueryParam[]) => void;
9
+ export {};
@@ -0,0 +1,15 @@
1
+ import { GridFilterModel } from '@mui/x-data-grid-pro';
2
+
3
+ export declare const useTableFilter: (defaultGridFilter?: GridFilterModel) => {
4
+ filterModel: GridFilterModel | undefined;
5
+ onFilterModelChange: (model: GridFilterModel) => void;
6
+ apiRequestFilterParams: {
7
+ filter: GridFilterModel;
8
+ } | undefined;
9
+ routerFilterQueryParams: {
10
+ query: string;
11
+ newValue: GridFilterModel;
12
+ }[] | {
13
+ query: string;
14
+ }[];
15
+ };
@@ -0,0 +1,28 @@
1
+ import { GridFilterModel } from '@smart-factor/gem-ui-components';
2
+ import { TabType } from './types';
3
+
4
+ export interface QueryState {
5
+ generalSearchText: string;
6
+ }
7
+ interface Props {
8
+ placeholder: string;
9
+ entityType: string;
10
+ tab?: TabType;
11
+ fileNameLabel?: string;
12
+ }
13
+ export declare const useTableQuery: ({ placeholder, tab, entityType, fileNameLabel, }: Props) => {
14
+ paginationAndSortState: import('./usePaginationAndSort').PaginationAndSort;
15
+ setPaginationAndSortState: import('react').Dispatch<import('react').SetStateAction<import('./usePaginationAndSort').PaginationAndSort>>;
16
+ apiRequestParams: {
17
+ [k: string]: any;
18
+ };
19
+ searchNode: import("react/jsx-runtime").JSX.Element;
20
+ filterModel: GridFilterModel | undefined;
21
+ onFilterModelChange: (model: GridFilterModel) => void;
22
+ debouncedSearchTerm: any;
23
+ exportDataAsExcel: (gridApiRef: import('react').MutableRefObject<import('@smart-factor/gem-ui-components').GridApiPro>) => Promise<void>;
24
+ allQueryParams: {
25
+ query: string;
26
+ }[];
27
+ };
28
+ export {};