mirror of
https://github.com/ramvignesh-b/pi-ku.git
synced 2026-05-04 08:56:52 +00:00
refactor: update crypto envelope encryption and add canvas serialization support
This commit is contained in:
@@ -0,0 +1,12 @@
|
||||
import { create } from "zustand";
|
||||
|
||||
interface KeyState {
|
||||
masterKey: CryptoKey | null;
|
||||
setMasterKey: (key: CryptoKey | null) => void;
|
||||
}
|
||||
|
||||
// this key will be used to encrypt and decrypt the user's data
|
||||
export const useKeyStore = create<KeyState>((set) => ({
|
||||
masterKey: null,
|
||||
setMasterKey: (masterKey) => set({ masterKey }),
|
||||
}));
|
||||
Reference in New Issue
Block a user