@smart-factor/gem-ui-components 0.0.149 → 0.0.151
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/{Drawer-DbJg-t8M.js → Drawer-hW8oGQEc.js} +14 -14
- package/dist/SignEditor.js +9 -5
- package/dist/{Stack-Bsa5WF4E.js → Stack-BKtw4ken.js} +26 -24
- package/dist/{Tree-BScJ4KG_.js → Tree-D9ZVXqFc.js} +2 -2
- package/dist/components/ContextualSearchClient/ClientContextualSearch.d.ts +2 -0
- package/dist/components/ContextualSearchClient/ClientContextualSearch.stories.d.ts +7 -0
- package/dist/components/ContextualSearchClient/ContextualSearchClient.d.ts +13 -0
- package/dist/components/ContextualSearchClient/DrawerClient.d.ts +9 -0
- package/dist/components/ContextualSearchClient/index.d.ts +5 -0
- package/dist/components/ContextualSearchClient/types.d.ts +2 -0
- package/dist/components/ContextualSearchInspector/InspectorContextualSearch.d.ts +14 -0
- package/dist/components/ContextualSearchInspector/InspectorContextualSearch.stories.d.ts +6 -0
- package/dist/components/ContextualSearchInspector/index.d.ts +1 -0
- package/dist/components/Drawer/index.js +1 -1
- package/dist/components/FormComponents/RadioChips/RadioChips.styles.d.ts +1 -1
- package/dist/components/SessionModal/SessionService.d.ts +2 -0
- package/dist/components/Tree/index.js +1 -1
- package/dist/{index-BUxi-hQu.js → index-BASTfYDt.js} +59509 -57070
- package/dist/licenses.txt +553 -553
- package/dist/main.d.ts +2 -0
- package/dist/main.js +3013 -2186
- package/dist/services/auth/useTokenExpiredWhenOffline.d.ts +1 -0
- package/dist/services/generated/api.d.ts +8800 -4194
- package/dist/services/mutations/clients/useCreateClient.d.ts +7 -0
- package/dist/services/mutations/clients/useUpdateClient.d.ts +7 -0
- package/dist/services/queries/address/useGetCities.d.ts +4 -0
- package/dist/services/queries/address/useGetFullAddress.d.ts +4 -0
- package/dist/services/queries/address/useGetStreetNumbers.d.ts +4 -0
- package/dist/services/queries/address/useGetStreets.d.ts +4 -0
- package/dist/services/queries/clients/useClientsContextualSearch.d.ts +11 -0
- package/dist/services/queries/clients/useGetClientById.d.ts +5 -0
- package/dist/services/queries/clients/useGetClientsContextual.d.ts +9 -0
- package/dist/services/queries/inspectors/useGetInspectorsContextual.d.ts +4 -0
- package/dist/services/queries/inspectors/useInspectorsContextualSearch.d.ts +12 -0
- package/dist/services/queries/useContextual.d.ts +9 -0
- package/dist/services/queryKeys.d.ts +1 -0
- package/dist/{warning-BcYeNKLQ.js → warning-VtsM1Gb2.js} +1 -1
- package/package.json +2 -3
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { AddClientPayload } from '../../generated/api';
|
|
2
|
+
import { MutationOptions, UseMutationResult } from '@tanstack/react-query';
|
|
3
|
+
interface Variables {
|
|
4
|
+
payload: AddClientPayload;
|
|
5
|
+
}
|
|
6
|
+
declare const useCreateClient: (mutationOptions?: MutationOptions<number, Error, Variables, MutationOptions>) => UseMutationResult<number, Error, Variables, MutationOptions>;
|
|
7
|
+
export default useCreateClient;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { UpdateClientPayload } from '../../generated/api';
|
|
2
|
+
import { MutationOptions, UseMutationResult } from '@tanstack/react-query';
|
|
3
|
+
interface Variables {
|
|
4
|
+
payload: UpdateClientPayload;
|
|
5
|
+
}
|
|
6
|
+
declare const useUpdateClient: (mutationOptions?: MutationOptions<number, Error, Variables, MutationOptions>) => UseMutationResult<number, Error, Variables, MutationOptions>;
|
|
7
|
+
export default useUpdateClient;
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { QueryCitiesParams, RequestParams } from '../../generated/api';
|
|
2
|
+
import { UseQueryOptions } from '@tanstack/react-query';
|
|
3
|
+
declare const useGetCities: (query: QueryCitiesParams, options?: Omit<UseQueryOptions<string[], Error, string[]>, "queryKey" | "queryFn">, params?: RequestParams) => import('@tanstack/react-query').UseQueryResult<string[], Error>;
|
|
4
|
+
export default useGetCities;
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { QueryPointAddressDetailsParams, RequestParams } from '../../generated/api';
|
|
2
|
+
import { UseQueryOptions } from '@tanstack/react-query';
|
|
3
|
+
declare const useGetFullAddress: (query: QueryPointAddressDetailsParams, options?: Omit<UseQueryOptions<Record<string, unknown>, Error, Record<string, unknown>>, "queryKey" | "queryFn">, params?: RequestParams) => import('@tanstack/react-query').UseQueryResult<Record<string, unknown>, Error>;
|
|
4
|
+
export default useGetFullAddress;
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { QueryOrdinalNumbersParams, RequestParams } from '../../generated/api';
|
|
2
|
+
import { UseQueryOptions } from '@tanstack/react-query';
|
|
3
|
+
declare const useGetStreetNumbers: (query: QueryOrdinalNumbersParams, options?: Omit<UseQueryOptions<string[], Error, string[]>, "queryKey" | "queryFn">, params?: RequestParams) => import('@tanstack/react-query').UseQueryResult<string[], Error>;
|
|
4
|
+
export default useGetStreetNumbers;
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { QueryStreetsParams, RequestParams } from '../../generated/api';
|
|
2
|
+
import { UseQueryOptions } from '@tanstack/react-query';
|
|
3
|
+
declare const useGetStreets: (query: QueryStreetsParams, options?: Omit<UseQueryOptions<string[], Error, string[]>, "queryKey" | "queryFn">, params?: RequestParams) => import('@tanstack/react-query').UseQueryResult<string[], Error>;
|
|
4
|
+
export default useGetStreets;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { ClientSimpleDTO } from '../../generated/api';
|
|
2
|
+
interface UseClientsContextualSearchProps {
|
|
3
|
+
disabledFetch?: boolean;
|
|
4
|
+
}
|
|
5
|
+
export declare const useClientsContextualSearch: (props: UseClientsContextualSearchProps) => {
|
|
6
|
+
options: ClientSimpleDTO[];
|
|
7
|
+
isLoading: boolean;
|
|
8
|
+
onGeneralSearchTextChange: (_: unknown, value: string) => void;
|
|
9
|
+
onLastOptionInView: () => void;
|
|
10
|
+
};
|
|
11
|
+
export {};
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { ClientSimpleDTO, RequestParams } from '../../generated/api';
|
|
2
|
+
import { UseQueryOptions } from '@tanstack/react-query';
|
|
3
|
+
export declare const getClientById: (id: number, params?: RequestParams) => Promise<ClientSimpleDTO>;
|
|
4
|
+
declare const useGetClientById: (id: number, options?: Omit<UseQueryOptions<ClientSimpleDTO, Error, ClientSimpleDTO>, "queryKey" | "queryFn">, params?: RequestParams) => import('@tanstack/react-query').UseQueryResult<ClientSimpleDTO, Error>;
|
|
5
|
+
export default useGetClientById;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { PageClientSimpleDTO, RequestParams } from '../../generated/api';
|
|
2
|
+
import { UseQueryOptions } from '@tanstack/react-query';
|
|
3
|
+
export interface ClientsContextualQuery {
|
|
4
|
+
size: number;
|
|
5
|
+
page: number;
|
|
6
|
+
generalSearchText: string;
|
|
7
|
+
}
|
|
8
|
+
declare const useGetClientsContextual: (query: ClientsContextualQuery, options?: Omit<UseQueryOptions<PageClientSimpleDTO, Error, PageClientSimpleDTO>, "queryKey" | "queryFn">, params?: RequestParams) => import('@tanstack/react-query').UseQueryResult<PageClientSimpleDTO, Error>;
|
|
9
|
+
export default useGetClientsContextual;
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { InspectorsContextualSearchParams, PageInspectorDTO, RequestParams } from '../../generated/api';
|
|
2
|
+
import { UseQueryOptions } from '@tanstack/react-query';
|
|
3
|
+
declare const useGetInspectorsContextual: (query: InspectorsContextualSearchParams, options?: Omit<UseQueryOptions<PageInspectorDTO, Error, PageInspectorDTO>, "queryKey" | "queryFn">, params?: RequestParams) => import('@tanstack/react-query').UseQueryResult<PageInspectorDTO, Error>;
|
|
4
|
+
export default useGetInspectorsContextual;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { InspectorDTO } from '../../generated/api';
|
|
2
|
+
interface UseInspectorsContextualSearchProps {
|
|
3
|
+
disabledFetch?: boolean;
|
|
4
|
+
controllingInspector: boolean;
|
|
5
|
+
}
|
|
6
|
+
export declare const useInspectorsContextualSearch: (props: UseInspectorsContextualSearchProps) => {
|
|
7
|
+
options: InspectorDTO[];
|
|
8
|
+
isLoading: boolean;
|
|
9
|
+
onGeneralSearchTextChange: (_: unknown, value: string) => void;
|
|
10
|
+
onLastOptionInView: () => void;
|
|
11
|
+
};
|
|
12
|
+
export {};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { UseQueryOptions } from '@tanstack/react-query';
|
|
2
|
+
type ContextualQueryOptions<TData> = Omit<UseQueryOptions<TData, Error, TData>, 'queryKey' | 'queryFn'>;
|
|
3
|
+
export declare const withResponseFallback: <TData>(response: {
|
|
4
|
+
data: {
|
|
5
|
+
response?: TData;
|
|
6
|
+
};
|
|
7
|
+
}, fallback: TData) => TData;
|
|
8
|
+
export declare const useContextual: <TQuery, TData>(queryKey: string, query: TQuery, queryFn: () => Promise<TData>, options?: ContextualQueryOptions<TData>) => import('@tanstack/react-query').UseQueryResult<TData, Error>;
|
|
9
|
+
export {};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as a from "react";
|
|
2
|
-
import { r as oe, m as re, u as _, a as ie, b as se, d as ae, T as le, g as ce, c as pe, e as ue, f as de, h as fe, i as he, j as me, s as P, k as ge, l as ye, n as H, o as Ee, P as e, p as we, q as k } from "./Stack-
|
|
2
|
+
import { r as oe, m as re, u as _, a as ie, b as se, d as ae, T as le, g as ce, c as pe, e as ue, f as de, h as fe, i as he, j as me, s as P, k as ge, l as ye, n as H, o as Ee, P as e, p as we, q as k } from "./Stack-BKtw4ken.js";
|
|
3
3
|
import { jsx as y } from "react/jsx-runtime";
|
|
4
4
|
function Re(o, t, r, s, i) {
|
|
5
5
|
if (process.env.NODE_ENV === "production")
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@smart-factor/gem-ui-components",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.151",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "Gem UI Components",
|
|
6
6
|
"type": "module",
|
|
@@ -32,8 +32,7 @@
|
|
|
32
32
|
"test:ui": "vitest --ui",
|
|
33
33
|
"test:coverage": "vitest run --coverage",
|
|
34
34
|
"prepare": "husky",
|
|
35
|
-
"generate:api": "
|
|
36
|
-
"generate:api:candidate": "swagger-typescript-api -p https://dev.smart-gem.pl/api/v3/api-docs --axios --responses --extract-request-params --extract-request-body --extract-response-body -o ./src/services/generated -n api-candidate.ts"
|
|
35
|
+
"generate:api": "node ./scripts/generateApi.mjs"
|
|
37
36
|
},
|
|
38
37
|
"peerDependencies": {
|
|
39
38
|
"@mui/icons-material": "^7.0.0",
|