@mnmal-ai/substrate-tui 1.0.0-alpha.5 → 1.0.0-alpha.7

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,7 +1,7 @@
1
1
  #!/usr/bin/env node
2
2
  import { i as isKeyRejection, t as adminCapabilityOf } from "./session-C1D5Ermr.js";
3
3
  import { resolve } from "node:path";
4
- import { AdminBackfillError, AuthError, CURRENT_MARK, NetworkError, STEP_MARKS, adminClaimCapabilities, capabilitiesFor, checkRevocable, checkUpdatable, currentStep, decodeList, describeGrant, diagnose, encodeGrant, flattenGrant, grantEntriesConfer, isActiveAdminKeyRow, isEncryptedKey, makeTokenProvider, parseGrantEntries, planOnboarding, resolveAdminCredential } from "@mnmal-ai/substrate/client";
4
+ import { AdminBackfillError, AuthError, CURRENT_MARK, NetworkError, STEP_MARKS, adminClaimCapabilities, capabilitiesFor, checkRevocable, checkUpdatable, currentStep, decodeList, describeGrant, diagnose, encodeGrant, flattenGrant, grantEntriesConfer, isActiveAdminKeyRow, isEncryptedKey, makeTokenProvider, parseGrantEntries, planOnboarding, resolveAdminCredential, tokenAudience } from "@mnmal-ai/substrate/client";
5
5
  import { createApp, defineModule, sanitise } from "@mnmal-ai/surface-core";
6
6
  import { marathon } from "@mnmal-ai/surface-theme";
7
7
  import { complete } from "@mnmal-ai/substrate-nl/complete";
@@ -76,6 +76,7 @@ function adminModule(deps, io = {}) {
76
76
  kid
77
77
  }, {
78
78
  capabilities: adminClaimCapabilities(deps.adminEnv),
79
+ audience: tokenAudience(deps.endpoint),
79
80
  ...passphrase !== void 0 ? { passphrase } : {}
80
81
  });
81
82
  return verifyAndUnlock(() => `Bearer ${getToken()}`, keyPath, kid, getToken);
@@ -3687,6 +3688,7 @@ function substrateAppOptions(deps, opts = {}) {
3687
3688
  defaultTurn: "substrate.ask:ask",
3688
3689
  band: true,
3689
3690
  gutter: 2,
3691
+ anchored: true,
3690
3692
  terminal: false
3691
3693
  };
3692
3694
  }
@@ -1,7 +1,7 @@
1
1
  #!/usr/bin/env node
2
2
  import { t as colorDepthEnv } from "../terminal-XfKFiD7r.js";
3
3
  import { basename } from "node:path";
4
- import { DEFAULT_CAPABILITIES, makeTokenProvider } from "@mnmal-ai/substrate/client";
4
+ import { DEFAULT_CAPABILITIES, makeTokenProvider, tokenAudience } from "@mnmal-ai/substrate/client";
5
5
  import { trimTrailingSlashes } from "@mnmal-ai/substrate/sdk";
6
6
 
7
7
  //#region src/config.ts
@@ -20,7 +20,10 @@ function readConfig(env, cwd) {
20
20
  token = makeTokenProvider({
21
21
  keyPath,
22
22
  kid
23
- }, { capabilities: raw !== void 0 && raw.length > 0 ? raw : DEFAULT_CAPABILITIES });
23
+ }, {
24
+ capabilities: raw !== void 0 && raw.length > 0 ? raw : DEFAULT_CAPABILITIES,
25
+ audience: tokenAudience(endpoint)
26
+ });
24
27
  } catch (err) {
25
28
  return { error: `agent identity: ${message(err)}` };
26
29
  }
@@ -48,7 +51,7 @@ async function main() {
48
51
  }
49
52
  Object.assign(process.env, colorDepthEnv(process.env));
50
53
  const [{ createTui }, { makeDeps }, { prepareTerminal }, { terminalOptions }] = await Promise.all([
51
- import("../app-DUbUKySy.js"),
54
+ import("../app-D0ccrk1L.js"),
52
55
  import("../deps-WzqsHHiC.js"),
53
56
  import("@mnmal-ai/surface-core/pure"),
54
57
  import("../terminal-CVX2CKWu.js")
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mnmal-ai/substrate-tui",
3
- "version": "1.0.0-alpha.5",
3
+ "version": "1.0.0-alpha.7",
4
4
  "description": "Terminal UI for Substrate: ask in natural language, browse the schema, see the service status.",
5
5
  "license": "Apache-2.0",
6
6
  "repository": {
@@ -10,7 +10,7 @@
10
10
  },
11
11
  "type": "module",
12
12
  "bin": {
13
- "substrate-tui": "dist/bin/tui.js"
13
+ "substrate-tui": "dist/bin/substrate-tui.js"
14
14
  },
15
15
  "files": [
16
16
  "dist"
@@ -20,8 +20,8 @@
20
20
  "access": "public"
21
21
  },
22
22
  "dependencies": {
23
- "@mnmal-ai/substrate": "1.0.0-alpha.5",
24
- "@mnmal-ai/substrate-nl": "1.0.0-alpha.5",
23
+ "@mnmal-ai/substrate": "1.0.0-alpha.7",
24
+ "@mnmal-ai/substrate-nl": "1.0.0-alpha.7",
25
25
  "@mnmal-ai/surface-core": "0.14.5",
26
26
  "@mnmal-ai/surface-kit": "0.14.5",
27
27
  "@mnmal-ai/surface-theme": "0.14.5",
@@ -30,7 +30,7 @@
30
30
  },
31
31
  "devDependencies": {
32
32
  "@biomejs/biome": "^2.5.15",
33
- "@mnmal-ai/substrate-config": "1.0.0-alpha.5",
33
+ "@mnmal-ai/substrate-config": "1.0.0-alpha.7",
34
34
  "@types/node": "^26.6.4",
35
35
  "@types/react": "^19.2.0",
36
36
  "ink-testing-library": "^4.0.0",