@devvit/build-pack 0.12.2-next-2025-10-30-15-21-54-b1c02a24a.0 → 0.12.2-next-2025-10-30-17-19-17-5c55a8901.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.
@@ -1 +1 @@
1
- {"version":3,"file":"blocks.template.d.ts","sourceRoot":"","sources":["../../../src/esbuild/templatizer/blocks.template.tsx"],"names":[],"mappings":"AAKA,OAAO,KAAK,EAAU,QAAQ,EAAE,MAAM,gBAAgB,CAAC;AAGvD,OAAO,EAEL,MAAM,EACN,KAAK,OAAO,EAMb,MAAM,oBAAoB,CAAC;AAE5B,OAAO,KAAK,EAAE,0BAA0B,EAAkB,UAAU,EAAE,MAAM,gBAAgB,CAAC;AAE7F,OAAO,KAAK,EAAE,UAAU,EAAa,iBAAiB,EAAE,MAAM,8BAA8B,CAAC;AAkB7F,OAAO,QAAQ,oBAAoB,CAAC;IAGlC,UAAU,MAAM,CAAC;QACf,SAAS,UAAU,IAAI,IAAI,CAAC;QAC5B,SAAS,SAAS,IAAI,IAAI,CAAC;QAC3B,SAAS,cAAc,IAAI,IAAI,CAAC;QAChC,SAAS,aAAa,CAAC,MAAM,EAAE,OAAO,EAAE,GAAG,EAAE,OAAO,GAAG,IAAI,CAAC;KAC7D;CACF;AAQD,oFAAoF;AACpF,eAAO,MAAM,UAAU,EAAE;IAAE,CAAC,OAAO,EAAE,MAAM,GAAG,OAAO,CAAA;CAAO,CAAC;AAE7D,gBAAgB;AAChB,wBAAgB,UAAU,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAE9C;AAkID,gBAAgB;AAChB,wBAAgB,gBAAgB,CAC9B,QAAQ,EAAE,MAAM,EAChB,GAAG,EAAE,QAAQ,CAAC,iBAAiB,CAAC,GAC/B,OAAO,CAAC,GAAG,IAAI,UAAU,CAiE3B;AAED,gBAAgB;AAChB,wBAAgB,gCAAgC,CAC9C,GAAG,EAAE,QAAQ,CAAC,UAAU,CAAC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AAI,UAAU,CAiE3B;AAED,gBAAgB;AAChB,wBAAgB,gCAAgC,CAC9C,GAAG,EAAE,QAAQ,CAAC,UAAU,CAAC,GACxB,OAAO,CAAC,GAAG,IAAI,0BAA0B,CAO3C;AA4CD;;;;;;;;;GASG;AACH,wBAAsB,WAAW,CAC/B,QAAQ,EAAE,MAAM,EAChB,IAAI,EAAE,QAAQ,CAAC,iBAAiB,CAAC,EACjC,IAAI,EAAE,QAAQ,CAAC,QAAQ,CAAC,GACvB,OAAO,CAAC,UAAU,GAAG,SAAS,CAAC,CAgEjC;AAoJD,eAAe,MAAM,CAAC"}
@@ -36,26 +36,26 @@ function configurePermissions(permissions) {
36
36
  });
37
37
  }
38
38
  function configurePost(name, post) {
39
- const defaultEntrypoint = post.entrypoints.default;
40
- const renderSplash = (ctx) => {
41
- const postDataHeader = ctx.metadata[Header.PostData]?.values[0];
42
- const postData = postDataHeader
43
- ? JSON.parse(postDataHeader)
44
- : {};
45
- const splash = postData.splash;
46
- const entry = splash?.entry ? post.entrypoints[splash.entry] : undefined;
39
+ const renderSplash = (entrypoint, splash) => {
47
40
  return (
48
41
  // Align to `submitCustomPost()`.
49
- Devvit.createElement(Splash, { appDisplayName: splash?.appDisplayName ?? name, appIconUri: splash?.appIconUri, backgroundUri: splash?.backgroundUri ?? backgroundUrl, buttonLabel: splash?.buttonLabel, description: splash?.description, entryUri: entry?.entry ?? defaultEntrypoint.entry, heading: splash?.title, height: entry?.height ?? defaultEntrypoint.height }));
42
+ Devvit.createElement(Splash, { appDisplayName: splash?.appDisplayName ?? name, appIconUri: splash?.appIconUri, backgroundUri: splash?.backgroundUri ?? backgroundUrl, buttonLabel: splash?.buttonLabel, description: splash?.description, entryUri: entrypoint.entry, heading: splash?.title, height: entrypoint.height }));
50
43
  };
51
- const renderInline = (_ctx) => {
52
- return (Devvit.createElement("blocks", { height: defaultEntrypoint.height },
53
- Devvit.createElement("webview", { url: defaultEntrypoint.entry, width: "100%", height: "100%" })));
44
+ const renderInline = (entrypoint) => {
45
+ return (Devvit.createElement("blocks", { height: entrypoint.height },
46
+ Devvit.createElement("webview", { url: entrypoint.entry, width: "100%", height: "100%" })));
54
47
  };
48
+ const defaultEntrypoint = post.entrypoints.default;
55
49
  Devvit.addCustomPostType({
56
50
  name: '',
57
51
  render: (ctx) => {
58
- return defaultEntrypoint.inline ? renderInline(ctx) : renderSplash(ctx);
52
+ const postDataHeader = ctx.metadata[Header.PostData]?.values[0];
53
+ const postData = postDataHeader
54
+ ? JSON.parse(postDataHeader)
55
+ : {};
56
+ const splash = postData.splash;
57
+ const entry = splash?.entry ? post.entrypoints[splash.entry] : defaultEntrypoint;
58
+ return entry.inline ? renderInline(entry) : renderSplash(entry, splash);
59
59
  },
60
60
  // to-do: vary dynamically on entrypoint.
61
61
  height: defaultEntrypoint.height,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@devvit/build-pack",
3
- "version": "0.12.2-next-2025-10-30-15-21-54-b1c02a24a.0",
3
+ "version": "0.12.2-next-2025-10-30-17-19-17-5c55a8901.0",
4
4
  "license": "BSD-3-Clause",
5
5
  "repository": {
6
6
  "type": "git",
@@ -31,10 +31,10 @@
31
31
  },
32
32
  "types": "./dist/index.d.ts",
33
33
  "dependencies": {
34
- "@devvit/payments": "0.12.2-next-2025-10-30-15-21-54-b1c02a24a.0",
35
- "@devvit/protos": "0.12.2-next-2025-10-30-15-21-54-b1c02a24a.0",
36
- "@devvit/shared-types": "0.12.2-next-2025-10-30-15-21-54-b1c02a24a.0",
37
- "@devvit/splash": "0.12.2-next-2025-10-30-15-21-54-b1c02a24a.0",
34
+ "@devvit/payments": "0.12.2-next-2025-10-30-17-19-17-5c55a8901.0",
35
+ "@devvit/protos": "0.12.2-next-2025-10-30-17-19-17-5c55a8901.0",
36
+ "@devvit/shared-types": "0.12.2-next-2025-10-30-17-19-17-5c55a8901.0",
37
+ "@devvit/splash": "0.12.2-next-2025-10-30-17-19-17-5c55a8901.0",
38
38
  "esbuild": "0.25.9",
39
39
  "rxjs": "7.8.1",
40
40
  "tsv": "0.2.0",
@@ -45,16 +45,16 @@
45
45
  "@devvit/shared": "*"
46
46
  },
47
47
  "devDependencies": {
48
- "@devvit/public-api": "0.12.2-next-2025-10-30-15-21-54-b1c02a24a.0",
49
- "@devvit/repo-tools": "0.12.2-next-2025-10-30-15-21-54-b1c02a24a.0",
50
- "@devvit/scheduler": "0.12.2-next-2025-10-30-15-21-54-b1c02a24a.0",
51
- "@devvit/server": "0.12.2-next-2025-10-30-15-21-54-b1c02a24a.0",
52
- "@devvit/shared": "0.12.2-next-2025-10-30-15-21-54-b1c02a24a.0",
53
- "@devvit/tsconfig": "0.12.2-next-2025-10-30-15-21-54-b1c02a24a.0",
48
+ "@devvit/public-api": "0.12.2-next-2025-10-30-17-19-17-5c55a8901.0",
49
+ "@devvit/repo-tools": "0.12.2-next-2025-10-30-17-19-17-5c55a8901.0",
50
+ "@devvit/scheduler": "0.12.2-next-2025-10-30-17-19-17-5c55a8901.0",
51
+ "@devvit/server": "0.12.2-next-2025-10-30-17-19-17-5c55a8901.0",
52
+ "@devvit/shared": "0.12.2-next-2025-10-30-17-19-17-5c55a8901.0",
53
+ "@devvit/tsconfig": "0.12.2-next-2025-10-30-17-19-17-5c55a8901.0",
54
54
  "@types/tsv": "0.2.1",
55
55
  "eslint": "9.11.1",
56
56
  "vitest": "1.6.1"
57
57
  },
58
58
  "source": "./src/index.ts",
59
- "gitHead": "ecde8ca9bb5f2ff761d7917bbcf3740e8e8bde49"
59
+ "gitHead": "03b2e441678c2762197a5fb9297816a2df95d2dd"
60
60
  }