@devvit/shared-types 0.12.1-next-2025-09-11-21-05-37-0ad852091.0 → 0.12.1-next-2025-09-11-21-41-10-10d93e74a.0

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.
@@ -19,6 +19,6 @@ type Effect = Omit<SharedEffects, 'interval'> & {
19
19
  * and resolves the promise when a matching response is received
20
20
  * 2. Effects that don't require a response: Posts the message and resolves immediately
21
21
  */
22
- export declare const emitEffect: (effect: Effect) => Promise<WebViewInternalEventMessage | undefined>;
22
+ export declare const emitEffect: (effect: Readonly<Effect>) => Promise<WebViewInternalEventMessage | undefined>;
23
23
  export {};
24
24
  //# sourceMappingURL=emit-effect.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"emit-effect.d.ts","sourceRoot":"","sources":["../../src/client/emit-effect.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,MAAM,IAAI,aAAa,EAAc,MAAM,gBAAgB,CAAC;AAC1E,OAAO,EAAE,0BAA0B,EAAE,MAAM,2EAA2E,CAAC;AAKvH,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,kEAAkE,CAAC;AAC3G,OAAO,EACL,2BAA2B,EAE5B,MAAM,2DAA2D,CAAC;AAEnE,KAAK,MAAM,GAAG,IAAI,CAAC,aAAa,EAAE,UAAU,CAAC,GAAG;IAC9C,aAAa,CAAC,EAAE,0BAA0B,GAAG,SAAS,CAAC;IACvD,KAAK,CAAC,EAAE,kBAAkB,CAAC;CAC5B,CAAC;AAOF;;;;;;;;;;;;GAYG;AACH,eAAO,MAAM,UAAU,GAAI,QAAQ,MAAM,KAAG,OAAO,CAAC,2BAA2B,GAAG,SAAS,CA2C1F,CAAC"}
1
+ {"version":3,"file":"emit-effect.d.ts","sourceRoot":"","sources":["../../src/client/emit-effect.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,MAAM,IAAI,aAAa,EAAc,MAAM,gBAAgB,CAAC;AAC1E,OAAO,EAAE,0BAA0B,EAAE,MAAM,2EAA2E,CAAC;AAKvH,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,kEAAkE,CAAC;AAC3G,OAAO,EACL,2BAA2B,EAE5B,MAAM,2DAA2D,CAAC;AAEnE,KAAK,MAAM,GAAG,IAAI,CAAC,aAAa,EAAE,UAAU,CAAC,GAAG;IAC9C,aAAa,CAAC,EAAE,0BAA0B,GAAG,SAAS,CAAC;IACvD,KAAK,CAAC,EAAE,kBAAkB,CAAC;CAC5B,CAAC;AAOF;;;;;;;;;;;;GAYG;AACH,eAAO,MAAM,UAAU,GACrB,QAAQ,QAAQ,CAAC,MAAM,CAAC,KACvB,OAAO,CAAC,2BAA2B,GAAG,SAAS,CA6CjD,CAAC"}
@@ -35,10 +35,13 @@ export const emitEffect = (effect) => {
35
35
  else {
36
36
  message.effect = effect;
37
37
  }
38
- // For temporary backward compatibility, we set both message.effect and message.showToast
38
+ // For temporary backward compatibility, we set both `message.effect` above, its types counterpart, below
39
39
  if (effect.showToast) {
40
40
  message.showToast = effect.showToast;
41
41
  }
42
+ else if (effect.navigateToUrl) {
43
+ message.navigateToUrl = effect.navigateToUrl;
44
+ }
42
45
  // Only set message id and add a listener for effects which require a response
43
46
  if (EFFECTS_WITH_RESPONSE.includes(effect.type)) {
44
47
  const id = self.crypto.randomUUID();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@devvit/shared-types",
3
- "version": "0.12.1-next-2025-09-11-21-05-37-0ad852091.0",
3
+ "version": "0.12.1-next-2025-09-11-21-41-10-10d93e74a.0",
4
4
  "license": "BSD-3-Clause",
5
5
  "repository": {
6
6
  "type": "git",
@@ -33,13 +33,13 @@
33
33
  },
34
34
  "types": "./dist/index.d.ts",
35
35
  "dependencies": {
36
- "@devvit/protos": "0.12.1-next-2025-09-11-21-05-37-0ad852091.0",
36
+ "@devvit/protos": "0.12.1-next-2025-09-11-21-41-10-10d93e74a.0",
37
37
  "jsonschema": "1.4.1",
38
38
  "uuid": "9.0.0"
39
39
  },
40
40
  "devDependencies": {
41
- "@devvit/repo-tools": "0.12.1-next-2025-09-11-21-05-37-0ad852091.0",
42
- "@devvit/tsconfig": "0.12.1-next-2025-09-11-21-05-37-0ad852091.0",
41
+ "@devvit/repo-tools": "0.12.1-next-2025-09-11-21-41-10-10d93e74a.0",
42
+ "@devvit/tsconfig": "0.12.1-next-2025-09-11-21-41-10-10d93e74a.0",
43
43
  "@types/redis-mock": "0.17.1",
44
44
  "@types/uuid": "9.0.0",
45
45
  "chokidar-cli": "3.0.0",
@@ -51,5 +51,5 @@
51
51
  "vitest": "1.6.1"
52
52
  },
53
53
  "source": "./src/index.ts",
54
- "gitHead": "a32297809f1f0d893b519a6ec0ba98f8e1a230ef"
54
+ "gitHead": "3e0576a30357d24b0c71e8fd6333bf2cb86662ca"
55
55
  }