@arkyn/types 1.3.0 → 1.3.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/hooks/Modal.d.ts +17 -0
- package/dist/hooks/Modal.d.ts.map +1 -0
- package/dist/hooks/Modal.js +1 -0
- package/dist/hooks/Toast.d.ts +12 -0
- package/dist/hooks/Toast.d.ts.map +1 -0
- package/dist/hooks/Toast.js +1 -0
- package/dist/index.d.ts +2 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +3 -0
- package/package.json +1 -1
- package/src/hooks/Modal.ts +20 -0
- package/src/hooks/Toast.ts +14 -0
- package/src/index.ts +4 -0
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import type { ReactNode } from "react";
|
|
2
|
+
type ModalContextProps = {
|
|
3
|
+
modalIsOpen(key: string): boolean;
|
|
4
|
+
modalData(key: string): any;
|
|
5
|
+
openModal(key: string, data?: any): void;
|
|
6
|
+
closeModal(key: string): void;
|
|
7
|
+
};
|
|
8
|
+
type OpenedModals = {
|
|
9
|
+
key: string;
|
|
10
|
+
data?: any;
|
|
11
|
+
}[];
|
|
12
|
+
type ModalProviderProps = {
|
|
13
|
+
children: ReactNode;
|
|
14
|
+
enableModalAutomation?: boolean;
|
|
15
|
+
};
|
|
16
|
+
export type { ModalContextProps, OpenedModals, ModalProviderProps };
|
|
17
|
+
//# sourceMappingURL=Modal.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Modal.d.ts","sourceRoot":"","sources":["../../src/hooks/Modal.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAEvC,KAAK,iBAAiB,GAAG;IACvB,WAAW,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC;IAClC,SAAS,CAAC,GAAG,EAAE,MAAM,GAAG,GAAG,CAAC;IAC5B,SAAS,CAAC,GAAG,EAAE,MAAM,EAAE,IAAI,CAAC,EAAE,GAAG,GAAG,IAAI,CAAC;IACzC,UAAU,CAAC,GAAG,EAAE,MAAM,GAAG,IAAI,CAAC;CAC/B,CAAC;AAEF,KAAK,YAAY,GAAG;IAClB,GAAG,EAAE,MAAM,CAAC;IACZ,IAAI,CAAC,EAAE,GAAG,CAAC;CACZ,EAAE,CAAC;AAEJ,KAAK,kBAAkB,GAAG;IACxB,QAAQ,EAAE,SAAS,CAAC;IACpB,qBAAqB,CAAC,EAAE,OAAO,CAAC;CACjC,CAAC;AAEF,YAAY,EAAE,iBAAiB,EAAE,YAAY,EAAE,kBAAkB,EAAE,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import type { ReactNode } from "react";
|
|
2
|
+
type ToastContextProps = {
|
|
3
|
+
errorToast(message: string): void;
|
|
4
|
+
warningToast(message: string): void;
|
|
5
|
+
successToast(message: string): void;
|
|
6
|
+
infoToast(message: string): void;
|
|
7
|
+
};
|
|
8
|
+
type ToastProviderProps = {
|
|
9
|
+
children: ReactNode;
|
|
10
|
+
};
|
|
11
|
+
export type { ToastContextProps, ToastProviderProps };
|
|
12
|
+
//# sourceMappingURL=Toast.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Toast.d.ts","sourceRoot":"","sources":["../../src/hooks/Toast.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAEvC,KAAK,iBAAiB,GAAG;IACvB,UAAU,CAAC,OAAO,EAAE,MAAM,GAAG,IAAI,CAAC;IAClC,YAAY,CAAC,OAAO,EAAE,MAAM,GAAG,IAAI,CAAC;IACpC,YAAY,CAAC,OAAO,EAAE,MAAM,GAAG,IAAI,CAAC;IACpC,SAAS,CAAC,OAAO,EAAE,MAAM,GAAG,IAAI,CAAC;CAClC,CAAC;AAEF,KAAK,kBAAkB,GAAG;IACxB,QAAQ,EAAE,SAAS,CAAC;CACrB,CAAC;AAEF,YAAY,EAAE,iBAAiB,EAAE,kBAAkB,EAAE,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
package/dist/index.d.ts
CHANGED
|
@@ -20,6 +20,8 @@ export * from "./components/ModalProps";
|
|
|
20
20
|
export * from "./components/SelectProps";
|
|
21
21
|
export * from "./components/SkeletonProps";
|
|
22
22
|
export * from "./components/TooltipProps";
|
|
23
|
+
export * from "./hooks/Modal";
|
|
24
|
+
export * from "./hooks/Toast";
|
|
23
25
|
export * from "./server/formParseProps";
|
|
24
26
|
export * from "./shared/CalculateCardInstallmentProps";
|
|
25
27
|
//# sourceMappingURL=index.d.ts.map
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AACA,cAAc,iBAAiB,CAAC;AAChC,cAAc,cAAc,CAAC;AAC7B,cAAc,gCAAgC,CAAC;AAC/C,cAAc,2BAA2B,CAAC;AAC1C,cAAc,gBAAgB,CAAC;AAC/B,cAAc,eAAe,CAAC;AAC9B,cAAc,cAAc,CAAC;AAC7B,cAAc,2BAA2B,CAAC;AAC1C,cAAc,uBAAuB,CAAC;AACtC,cAAc,0BAA0B,CAAC;AAGzC,cAAc,yBAAyB,CAAC;AACxC,cAAc,8BAA8B,CAAC;AAC7C,cAAc,0BAA0B,CAAC;AACzC,cAAc,4BAA4B,CAAC;AAC3C,cAAc,2BAA2B,CAAC;AAC1C,cAAc,wBAAwB,CAAC;AACvC,cAAc,8BAA8B,CAAC;AAC7C,cAAc,yBAAyB,CAAC;AACxC,cAAc,yBAAyB,CAAC;AACxC,cAAc,0BAA0B,CAAC;AACzC,cAAc,4BAA4B,CAAC;AAC3C,cAAc,2BAA2B,CAAC;AAG1C,cAAc,yBAAyB,CAAC;AAGxC,cAAc,wCAAwC,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AACA,cAAc,iBAAiB,CAAC;AAChC,cAAc,cAAc,CAAC;AAC7B,cAAc,gCAAgC,CAAC;AAC/C,cAAc,2BAA2B,CAAC;AAC1C,cAAc,gBAAgB,CAAC;AAC/B,cAAc,eAAe,CAAC;AAC9B,cAAc,cAAc,CAAC;AAC7B,cAAc,2BAA2B,CAAC;AAC1C,cAAc,uBAAuB,CAAC;AACtC,cAAc,0BAA0B,CAAC;AAGzC,cAAc,yBAAyB,CAAC;AACxC,cAAc,8BAA8B,CAAC;AAC7C,cAAc,0BAA0B,CAAC;AACzC,cAAc,4BAA4B,CAAC;AAC3C,cAAc,2BAA2B,CAAC;AAC1C,cAAc,wBAAwB,CAAC;AACvC,cAAc,8BAA8B,CAAC;AAC7C,cAAc,yBAAyB,CAAC;AACxC,cAAc,yBAAyB,CAAC;AACxC,cAAc,0BAA0B,CAAC;AACzC,cAAc,4BAA4B,CAAC;AAC3C,cAAc,2BAA2B,CAAC;AAG1C,cAAc,eAAe,CAAC;AAC9B,cAAc,eAAe,CAAC;AAG9B,cAAc,yBAAyB,CAAC;AAGxC,cAAc,wCAAwC,CAAC"}
|
package/dist/index.js
CHANGED
|
@@ -22,6 +22,9 @@ export * from "./components/ModalProps";
|
|
|
22
22
|
export * from "./components/SelectProps";
|
|
23
23
|
export * from "./components/SkeletonProps";
|
|
24
24
|
export * from "./components/TooltipProps";
|
|
25
|
+
// Hooks
|
|
26
|
+
export * from "./hooks/Modal";
|
|
27
|
+
export * from "./hooks/Toast";
|
|
25
28
|
// Server
|
|
26
29
|
export * from "./server/formParseProps";
|
|
27
30
|
// Shared
|
package/package.json
CHANGED
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import type { ReactNode } from "react";
|
|
2
|
+
|
|
3
|
+
type ModalContextProps = {
|
|
4
|
+
modalIsOpen(key: string): boolean;
|
|
5
|
+
modalData(key: string): any;
|
|
6
|
+
openModal(key: string, data?: any): void;
|
|
7
|
+
closeModal(key: string): void;
|
|
8
|
+
};
|
|
9
|
+
|
|
10
|
+
type OpenedModals = {
|
|
11
|
+
key: string;
|
|
12
|
+
data?: any;
|
|
13
|
+
}[];
|
|
14
|
+
|
|
15
|
+
type ModalProviderProps = {
|
|
16
|
+
children: ReactNode;
|
|
17
|
+
enableModalAutomation?: boolean;
|
|
18
|
+
};
|
|
19
|
+
|
|
20
|
+
export type { ModalContextProps, OpenedModals, ModalProviderProps };
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import type { ReactNode } from "react";
|
|
2
|
+
|
|
3
|
+
type ToastContextProps = {
|
|
4
|
+
errorToast(message: string): void;
|
|
5
|
+
warningToast(message: string): void;
|
|
6
|
+
successToast(message: string): void;
|
|
7
|
+
infoToast(message: string): void;
|
|
8
|
+
};
|
|
9
|
+
|
|
10
|
+
type ToastProviderProps = {
|
|
11
|
+
children: ReactNode;
|
|
12
|
+
};
|
|
13
|
+
|
|
14
|
+
export type { ToastContextProps, ToastProviderProps };
|
package/src/index.ts
CHANGED
|
@@ -24,6 +24,10 @@ export * from "./components/SelectProps";
|
|
|
24
24
|
export * from "./components/SkeletonProps";
|
|
25
25
|
export * from "./components/TooltipProps";
|
|
26
26
|
|
|
27
|
+
// Hooks
|
|
28
|
+
export * from "./hooks/Modal";
|
|
29
|
+
export * from "./hooks/Toast";
|
|
30
|
+
|
|
27
31
|
// Server
|
|
28
32
|
export * from "./server/formParseProps";
|
|
29
33
|
|