@devvit/build-pack 0.11.19-next-2025-07-09-20-20-27-3938f00aa.0 → 0.11.19-next-2025-07-09-23-35-14-5a55c997e.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":"dependency-spec-util.d.ts","sourceRoot":"","sources":["../../src/esbuild/dependency-spec-util.ts"],"names":[],"mappings":"AA+CA,OAAO,KAAK,EAAE,SAAS,EAAE,cAAc,EAAE,MAAM,6BAA6B,CAAC;AAK7E,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,mCAAmC,CAAC;AACnE,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,gDAAgD,CAAC;AAEhF;;;;GAIG;AACH,wBAAgB,oBAAoB,CAClC,SAAS,EAAE,QAAQ,CAAC,SAAS,CAAC,EAC9B,MAAM,EAAE,QAAQ,CAAC,IAAI,CAAC,SAAS,EAAE,MAAM,CAAC,CAAC,EACzC,SAAS,EAAE,QAAQ,CAAC,SAAS,CAAC,GAC7B,cAAc,
|
|
1
|
+
{"version":3,"file":"dependency-spec-util.d.ts","sourceRoot":"","sources":["../../src/esbuild/dependency-spec-util.ts"],"names":[],"mappings":"AA+CA,OAAO,KAAK,EAAE,SAAS,EAAE,cAAc,EAAE,MAAM,6BAA6B,CAAC;AAK7E,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,mCAAmC,CAAC;AACnE,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,gDAAgD,CAAC;AAEhF;;;;GAIG;AACH,wBAAgB,oBAAoB,CAClC,SAAS,EAAE,QAAQ,CAAC,SAAS,CAAC,EAC9B,MAAM,EAAE,QAAQ,CAAC,IAAI,CAAC,SAAS,EAAE,MAAM,CAAC,CAAC,EACzC,SAAS,EAAE,QAAQ,CAAC,SAAS,CAAC,GAC7B,cAAc,CA4FhB"}
|
|
@@ -41,8 +41,6 @@ export function createDependencySpec(actorSpec, config, namespace) {
|
|
|
41
41
|
use(spec, RedisAPIDefinition);
|
|
42
42
|
if (config.post) {
|
|
43
43
|
provide(spec, CustomPostDefinition, UIEventHandlerDefinition);
|
|
44
|
-
if (config.post.create.onInstall)
|
|
45
|
-
provide(spec, OnAppInstallDefinition);
|
|
46
44
|
}
|
|
47
45
|
if (config.server)
|
|
48
46
|
provide(spec, WebbitServerDefinition);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"blocks.template.d.ts","sourceRoot":"","sources":["../../../src/esbuild/templatizer/blocks.template.tsx"],"names":[],"mappings":"AAEA,OAAO,EAEL,MAAM,EACN,KAAK,OAAO,
|
|
1
|
+
{"version":3,"file":"blocks.template.d.ts","sourceRoot":"","sources":["../../../src/esbuild/templatizer/blocks.template.tsx"],"names":[],"mappings":"AAEA,OAAO,EAEL,MAAM,EACN,KAAK,OAAO,EAKb,MAAM,oBAAoB,CAAC;AAK5B,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,qCAAqC,CAAC;AAiBtE,oFAAoF;AACpF,eAAO,MAAM,UAAU,EAAE;IAAE,CAAC,OAAO,EAAE,MAAM,GAAG,OAAO,CAAA;CAAO,CAAC;AA8F7D,gBAAgB;AAChB,wBAAgB,kBAAkB,CAAC,UAAU,EAAE,UAAU,GAAG,IAAI,CA4D/D;AA+JD,eAAe,MAAM,CAAC"}
|
|
@@ -29,32 +29,11 @@ function configurePost(post) {
|
|
|
29
29
|
// eslint-disable-next-line security/detect-non-literal-regexp
|
|
30
30
|
const path = post.client.entry.replace(new RegExp(`^${post.client.dir}/?`), '');
|
|
31
31
|
Devvit.addCustomPostType({
|
|
32
|
-
name:
|
|
32
|
+
name: '',
|
|
33
33
|
render: () => renderModal(path),
|
|
34
|
-
|
|
34
|
+
// TODO: no way to specify regular vs. tall right now. Move this to post config.
|
|
35
|
+
height: 'tall',
|
|
35
36
|
});
|
|
36
|
-
if (post.create.menu.enable) {
|
|
37
|
-
Devvit.addMenuItem({
|
|
38
|
-
forUserType: post.create.menu.scope === 'moderator' ? 'moderator' : 'loggedOut',
|
|
39
|
-
label: post.create.menu.label,
|
|
40
|
-
location: 'subreddit',
|
|
41
|
-
async onPress(_ev, ctx) {
|
|
42
|
-
const newPost = await createPost(ctx, post.create);
|
|
43
|
-
ctx.ui.showToast({
|
|
44
|
-
text: `Created post "${newPost.title}" in ${ctx.subredditName}. Navigating to it now.`,
|
|
45
|
-
appearance: 'success',
|
|
46
|
-
});
|
|
47
|
-
ctx.ui.navigateTo(newPost);
|
|
48
|
-
},
|
|
49
|
-
});
|
|
50
|
-
}
|
|
51
|
-
if (post.create.onInstall)
|
|
52
|
-
Devvit.addTrigger({
|
|
53
|
-
event: 'AppInstall',
|
|
54
|
-
async onEvent(_ev, ctx) {
|
|
55
|
-
await createPost(ctx, post.create);
|
|
56
|
-
},
|
|
57
|
-
});
|
|
58
37
|
}
|
|
59
38
|
function configureMenuActions(menuActions) {
|
|
60
39
|
for (const action of menuActions) {
|
|
@@ -263,15 +242,6 @@ function configureScheduler(schedulerConfig) {
|
|
|
263
242
|
});
|
|
264
243
|
}
|
|
265
244
|
}
|
|
266
|
-
async function createPost(ctx, create) {
|
|
267
|
-
if (!ctx.subredditName)
|
|
268
|
-
throw Error('no sub name');
|
|
269
|
-
return await ctx.reddit.submitPost({
|
|
270
|
-
preview: Devvit.createElement("text", null, "Loading\u2026"),
|
|
271
|
-
subredditName: ctx.subredditName,
|
|
272
|
-
title: create.title,
|
|
273
|
-
});
|
|
274
|
-
}
|
|
275
245
|
function renderModal(path) {
|
|
276
246
|
const webView = useWebView({ url: path, onMessage() { } });
|
|
277
247
|
return (Devvit.createElement("vstack", { alignment: "center middle", height: "100%" },
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@devvit/build-pack",
|
|
3
|
-
"version": "0.11.19-next-2025-07-09-
|
|
3
|
+
"version": "0.11.19-next-2025-07-09-23-35-14-5a55c997e.0",
|
|
4
4
|
"license": "BSD-3-Clause",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -23,8 +23,8 @@
|
|
|
23
23
|
},
|
|
24
24
|
"types": "./index.d.ts",
|
|
25
25
|
"dependencies": {
|
|
26
|
-
"@devvit/protos": "0.11.19-next-2025-07-09-
|
|
27
|
-
"@devvit/shared-types": "0.11.19-next-2025-07-09-
|
|
26
|
+
"@devvit/protos": "0.11.19-next-2025-07-09-23-35-14-5a55c997e.0",
|
|
27
|
+
"@devvit/shared-types": "0.11.19-next-2025-07-09-23-35-14-5a55c997e.0",
|
|
28
28
|
"esbuild": "0.23.0",
|
|
29
29
|
"rxjs": "7.8.1",
|
|
30
30
|
"tsv": "0.2.0",
|
|
@@ -35,12 +35,12 @@
|
|
|
35
35
|
"@devvit/shared": "*"
|
|
36
36
|
},
|
|
37
37
|
"devDependencies": {
|
|
38
|
-
"@devvit/public-api": "0.11.19-next-2025-07-09-
|
|
39
|
-
"@devvit/repo-tools": "0.11.19-next-2025-07-09-
|
|
40
|
-
"@devvit/scheduler": "0.11.19-next-2025-07-09-
|
|
41
|
-
"@devvit/server": "0.11.19-next-2025-07-09-
|
|
42
|
-
"@devvit/shared": "0.11.19-next-2025-07-09-
|
|
43
|
-
"@devvit/tsconfig": "0.11.19-next-2025-07-09-
|
|
38
|
+
"@devvit/public-api": "0.11.19-next-2025-07-09-23-35-14-5a55c997e.0",
|
|
39
|
+
"@devvit/repo-tools": "0.11.19-next-2025-07-09-23-35-14-5a55c997e.0",
|
|
40
|
+
"@devvit/scheduler": "0.11.19-next-2025-07-09-23-35-14-5a55c997e.0",
|
|
41
|
+
"@devvit/server": "0.11.19-next-2025-07-09-23-35-14-5a55c997e.0",
|
|
42
|
+
"@devvit/shared": "0.11.19-next-2025-07-09-23-35-14-5a55c997e.0",
|
|
43
|
+
"@devvit/tsconfig": "0.11.19-next-2025-07-09-23-35-14-5a55c997e.0",
|
|
44
44
|
"@types/tsv": "0.2.1",
|
|
45
45
|
"eslint": "9.11.1",
|
|
46
46
|
"vitest": "1.6.1"
|
|
@@ -49,5 +49,5 @@
|
|
|
49
49
|
"directory": "dist"
|
|
50
50
|
},
|
|
51
51
|
"source": "./src/index.ts",
|
|
52
|
-
"gitHead": "
|
|
52
|
+
"gitHead": "490003bcebac72d388e3e2ab4780f7666b271ade"
|
|
53
53
|
}
|