@vlayer/sdk 0.1.0-nightly-20241115-70dfc11 → 0.1.0-nightly-20241118-da2817b

Sign up to get free protection for your applications and to get access to all the features.
@@ -10,8 +10,9 @@ export async function parseEmail(mime) {
10
10
  }
11
11
  export function getDkimSigners(mail) {
12
12
  const dkimHeader = mail.headers.filter((h) => h.key === "dkim-signature");
13
- if (dkimHeader.length === 0)
13
+ if (dkimHeader.length === 0) {
14
14
  throw new DkimParsingError("No DKIM header found");
15
+ }
15
16
  return dkimHeader.map(parseHeader);
16
17
  }
17
18
  export function parseParams(str) {
@@ -11,7 +11,7 @@ class ExtensionWebProofProvider {
11
11
  }
12
12
  notifyZkProvingStatus(status) {
13
13
  if (typeof chrome !== "undefined") {
14
- this.connectToExtension().postMessage({
14
+ chrome.runtime.sendMessage(EXTENSION_ID, {
15
15
  action: 1 /* ExtensionAction.NotifyZkProvingStatus */,
16
16
  payload: { status },
17
17
  });
@@ -11,10 +11,10 @@ export declare const enum ExtensionAction {
11
11
  NotifyZkProvingStatus = 1
12
12
  }
13
13
  export declare enum ZkProvingStatus {
14
- NotStarted = "notStarted",
15
- Proving = "proving",
16
- Done = "done",
17
- Error = "error"
14
+ NotStarted = "NotStarted",
15
+ Proving = "Proving",
16
+ Done = "Done",
17
+ Error = "Error"
18
18
  }
19
19
  export type MessageToExtension = {
20
20
  action: ExtensionAction.RequestWebProof;
@@ -5,10 +5,10 @@ export const EXTENSION_STEP = {
5
5
  };
6
6
  export var ZkProvingStatus;
7
7
  (function (ZkProvingStatus) {
8
- ZkProvingStatus["NotStarted"] = "notStarted";
9
- ZkProvingStatus["Proving"] = "proving";
10
- ZkProvingStatus["Done"] = "done";
11
- ZkProvingStatus["Error"] = "error";
8
+ ZkProvingStatus["NotStarted"] = "NotStarted";
9
+ ZkProvingStatus["Proving"] = "Proving";
10
+ ZkProvingStatus["Done"] = "Done";
11
+ ZkProvingStatus["Error"] = "Error";
12
12
  })(ZkProvingStatus || (ZkProvingStatus = {}));
13
13
  export var ExtensionMessageType;
14
14
  (function (ExtensionMessageType) {
package/package.json CHANGED
@@ -15,7 +15,7 @@
15
15
  "types": "./dist/config/index.d.ts"
16
16
  }
17
17
  },
18
- "version": "0.1.0-nightly-20241115-70dfc11",
18
+ "version": "0.1.0-nightly-20241118-da2817b",
19
19
  "scripts": {
20
20
  "build": "bun tsc && bun tsc-alias",
21
21
  "test:unit": "vitest --run",