@trackunit/react-components 0.1.180 → 0.1.181
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/package.json
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export interface LocalStorageParams<
|
|
1
|
+
import { z } from "zod";
|
|
2
|
+
export interface LocalStorageParams<TState> {
|
|
3
3
|
/**
|
|
4
4
|
* The key used to store the value in local storage.
|
|
5
5
|
*/
|
|
@@ -7,11 +7,11 @@ export interface LocalStorageParams<State> {
|
|
|
7
7
|
/**
|
|
8
8
|
* The default state value.
|
|
9
9
|
*/
|
|
10
|
-
defaultState:
|
|
10
|
+
defaultState: TState;
|
|
11
11
|
/**
|
|
12
12
|
* Optional schema for validating the state.
|
|
13
13
|
*/
|
|
14
|
-
schema?:
|
|
14
|
+
schema?: z.Schema<TState>;
|
|
15
15
|
}
|
|
16
16
|
export interface LocalStorageCallbacks {
|
|
17
17
|
/**
|