@nanobpm/urban 0.23.1 → 0.24.1
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,14 +1,6 @@
|
|
|
1
1
|
import type { HostContext } from "./host.ts";
|
|
2
2
|
import type { AppManifest, Worker } from "@nanobpm/nano-app-schema";
|
|
3
|
-
export type { ActionDecl, AppManifest, ChatSurface, Connection, Data, DataSource, DomainField, DomainType, LlmBinding, Models, PagesSurface, Runtime, Security, Surfaces, TaskInboxSurface, Trigger, TriggerAction, Worker, } from "@nanobpm/nano-app-schema";
|
|
4
|
-
declare module "@nanobpm/nano-app-schema" {
|
|
5
|
-
interface Models {
|
|
6
|
-
/** `{{name}}` template sources substituted into model resources at deploy time: globs, a bare
|
|
7
|
-
* directory (scanned), or literal files. A template's name is its file stem
|
|
8
|
-
* (`prompts/review-round.md` → `{{review-round}}`). See `deployModels`. */
|
|
9
|
-
templates?: string[];
|
|
10
|
-
}
|
|
11
|
-
}
|
|
3
|
+
export type { ActionDecl, AppManifest, AppUi, ChatSurface, Connection, Data, DataSource, DomainField, DomainType, LlmBinding, Models, PagesSurface, Runtime, Security, Surfaces, TaskInboxSurface, Trigger, TriggerAction, Worker, } from "@nanobpm/nano-app-schema";
|
|
12
4
|
/** The job type a worker subscribes to (schema key: `taskType`). */
|
|
13
5
|
export declare function workerJobType(w: Worker): string | undefined;
|
|
14
6
|
/**
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@nanobpm/urban",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.24.1",
|
|
4
4
|
"description": "Urban: build and run code-first apps on Nano — runtime, derivation toolkit, and CLI in one. Author durable processes with @nanobpm/workflow (defineFlow), a typed datasource, forms, triggers and surfaces from a nano.app.json manifest, on Node or Deno.",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"type": "module",
|
|
@@ -62,11 +62,11 @@
|
|
|
62
62
|
"test:deno": "deno test -A --no-check src/"
|
|
63
63
|
},
|
|
64
64
|
"dependencies": {
|
|
65
|
-
"@nanobpm/nano-app-schema": "^0.
|
|
65
|
+
"@nanobpm/nano-app-schema": "^0.3.0",
|
|
66
66
|
"@nanobpm/nano-sdk": "^1.2.3",
|
|
67
67
|
"@nanobpm/workflow": "^0.8.0",
|
|
68
68
|
"bpmn-auto-layout": "^2.0.0-alpha.2",
|
|
69
|
-
"create-urban-app": "^0.
|
|
69
|
+
"create-urban-app": "^0.7.0"
|
|
70
70
|
},
|
|
71
71
|
"devDependencies": {
|
|
72
72
|
"@types/node": "^22.20.1",
|
|
@@ -14,6 +14,7 @@ import type { AppManifest, Worker } from "@nanobpm/nano-app-schema";
|
|
|
14
14
|
export type {
|
|
15
15
|
ActionDecl,
|
|
16
16
|
AppManifest,
|
|
17
|
+
AppUi,
|
|
17
18
|
ChatSurface,
|
|
18
19
|
Connection,
|
|
19
20
|
Data,
|
|
@@ -32,19 +33,6 @@ export type {
|
|
|
32
33
|
Worker,
|
|
33
34
|
} from "@nanobpm/nano-app-schema";
|
|
34
35
|
|
|
35
|
-
// The published `@nanobpm/nano-app-schema` does not yet declare `models.templates`; the manifest
|
|
36
|
-
// validator only enforces `additionalProperties:false` at the top level (see validate.ts), so the
|
|
37
|
-
// nested key is accepted at runtime. Augment `Models` here so the deploy path can read it typed
|
|
38
|
-
// (no cast) until it is formalized in the schema package.
|
|
39
|
-
declare module "@nanobpm/nano-app-schema" {
|
|
40
|
-
interface Models {
|
|
41
|
-
/** `{{name}}` template sources substituted into model resources at deploy time: globs, a bare
|
|
42
|
-
* directory (scanned), or literal files. A template's name is its file stem
|
|
43
|
-
* (`prompts/review-round.md` → `{{review-round}}`). See `deployModels`. */
|
|
44
|
-
templates?: string[];
|
|
45
|
-
}
|
|
46
|
-
}
|
|
47
|
-
|
|
48
36
|
/** The job type a worker subscribes to (schema key: `taskType`). */
|
|
49
37
|
export function workerJobType(w: Worker): string | undefined {
|
|
50
38
|
return w.taskType;
|
|
@@ -37,6 +37,14 @@ test("an `actions` array is an accepted top-level key (ADR 0055 §3)", () => {
|
|
|
37
37
|
assert.deepEqual(issues, []);
|
|
38
38
|
});
|
|
39
39
|
|
|
40
|
+
test("a `ui` block is an accepted top-level key (Studio App View, ADR 0057 / nano-bpm #638)", () => {
|
|
41
|
+
const issues = collectManifestIssues({
|
|
42
|
+
...valid,
|
|
43
|
+
ui: { enabled: true, portEnv: "PORT", path: "/", label: "Nano Workforce" },
|
|
44
|
+
});
|
|
45
|
+
assert.deepEqual(issues, []);
|
|
46
|
+
});
|
|
47
|
+
|
|
40
48
|
test("bad schemaVersion and bad slug id are reported", () => {
|
|
41
49
|
const issues = collectManifestIssues({ ...valid, schemaVersion: 2, id: "Not A Slug" });
|
|
42
50
|
assert.ok(issues.some((i) => i.path === "schemaVersion"));
|