adr-kit 0.10.0 → 0.12.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.
- package/README.md +9 -6
- package/README.zh.md +7 -5
- package/dist/cli.d.ts.map +1 -1
- package/dist/cli.js +19 -3
- package/dist/cli.js.map +1 -1
- package/dist/commands/completion.d.ts.map +1 -1
- package/dist/commands/completion.js +2 -55
- package/dist/commands/completion.js.map +1 -1
- package/dist/commands/config.d.ts.map +1 -1
- package/dist/commands/config.js +3 -0
- package/dist/commands/config.js.map +1 -1
- package/dist/commands/graph.d.ts +2 -0
- package/dist/commands/graph.d.ts.map +1 -1
- package/dist/commands/graph.js +37 -7
- package/dist/commands/graph.js.map +1 -1
- package/dist/commands/init.d.ts.map +1 -1
- package/dist/commands/init.js +3 -0
- package/dist/commands/init.js.map +1 -1
- package/dist/commands/instructions.d.ts.map +1 -1
- package/dist/commands/instructions.js +8 -1
- package/dist/commands/instructions.js.map +1 -1
- package/dist/commands/list.d.ts.map +1 -1
- package/dist/commands/list.js +7 -4
- package/dist/commands/list.js.map +1 -1
- package/dist/commands/supersede.d.ts.map +1 -1
- package/dist/commands/supersede.js +12 -7
- package/dist/commands/supersede.js.map +1 -1
- package/dist/commands/update.d.ts.map +1 -1
- package/dist/commands/update.js +3 -1
- package/dist/commands/update.js.map +1 -1
- package/dist/core/adr.d.ts +1 -0
- package/dist/core/adr.d.ts.map +1 -1
- package/dist/core/adr.js.map +1 -1
- package/dist/core/canvas-view.d.ts +19 -3
- package/dist/core/canvas-view.d.ts.map +1 -1
- package/dist/core/canvas-view.js +210 -15
- package/dist/core/canvas-view.js.map +1 -1
- package/dist/core/cli-options.d.ts +23 -0
- package/dist/core/cli-options.d.ts.map +1 -0
- package/dist/core/cli-options.js +69 -0
- package/dist/core/cli-options.js.map +1 -0
- package/dist/core/config.d.ts +29 -0
- package/dist/core/config.d.ts.map +1 -1
- package/dist/core/config.js +69 -1
- package/dist/core/config.js.map +1 -1
- package/dist/core/deliberation-html.d.ts.map +1 -1
- package/dist/core/deliberation-html.js +89 -24
- package/dist/core/deliberation-html.js.map +1 -1
- package/dist/core/deliberation-view.d.ts.map +1 -1
- package/dist/core/deliberation-view.js +28 -195
- package/dist/core/deliberation-view.js.map +1 -1
- package/dist/core/deliberation.d.ts +15 -0
- package/dist/core/deliberation.d.ts.map +1 -1
- package/dist/core/deliberation.js +35 -15
- package/dist/core/deliberation.js.map +1 -1
- package/dist/core/graph-html.d.ts +1 -1
- package/dist/core/graph-html.d.ts.map +1 -1
- package/dist/core/graph-html.js +163 -44
- package/dist/core/graph-html.js.map +1 -1
- package/dist/core/graph-view.d.ts +1 -1
- package/dist/core/graph-view.d.ts.map +1 -1
- package/dist/core/graph-view.js +9 -187
- package/dist/core/graph-view.js.map +1 -1
- package/dist/core/relation-focus.d.ts +4 -0
- package/dist/core/relation-focus.d.ts.map +1 -0
- package/dist/core/relation-focus.js +89 -0
- package/dist/core/relation-focus.js.map +1 -0
- package/dist/core/share.d.ts +30 -0
- package/dist/core/share.d.ts.map +1 -0
- package/dist/core/share.js +420 -0
- package/dist/core/share.js.map +1 -0
- package/dist/core/templates.d.ts +4 -1
- package/dist/core/templates.d.ts.map +1 -1
- package/dist/core/templates.js +4 -1
- package/dist/core/templates.js.map +1 -1
- package/dist/core/tool-integrations.d.ts.map +1 -1
- package/dist/core/tool-integrations.js +47 -29
- package/dist/core/tool-integrations.js.map +1 -1
- package/dist/core/validate.d.ts +1 -1
- package/dist/core/validate.d.ts.map +1 -1
- package/dist/core/validate.js +25 -14
- package/dist/core/validate.js.map +1 -1
- package/dist/core/view-text.d.ts +7 -0
- package/dist/core/view-text.d.ts.map +1 -1
- package/dist/core/view-text.js +15 -0
- package/dist/core/view-text.js.map +1 -1
- package/package.json +1 -1
package/dist/core/config.js
CHANGED
|
@@ -58,6 +58,9 @@ export function readConfig(root) {
|
|
|
58
58
|
raw.workflows.every((entry) => typeof entry === 'string')) {
|
|
59
59
|
config.workflows = raw.workflows;
|
|
60
60
|
}
|
|
61
|
+
if (typeof raw['installed-with'] === 'string') {
|
|
62
|
+
config.installedWith = raw['installed-with'];
|
|
63
|
+
}
|
|
61
64
|
if (raw.rules !== null && typeof raw.rules === 'object' && !Array.isArray(raw.rules)) {
|
|
62
65
|
const rules = {};
|
|
63
66
|
for (const [key, value] of Object.entries(raw.rules)) {
|
|
@@ -69,11 +72,26 @@ export function readConfig(root) {
|
|
|
69
72
|
}
|
|
70
73
|
return config;
|
|
71
74
|
}
|
|
75
|
+
/**
|
|
76
|
+
* Read the configuration without throwing. The drift notice must never turn a
|
|
77
|
+
* command into a failure: a repository with a malformed `adr/config.yaml`
|
|
78
|
+
* simply has nothing honest to say about its stamp, and `validate` remains the
|
|
79
|
+
* command that reports the broken file.
|
|
80
|
+
*/
|
|
81
|
+
export function readConfigSafe(root) {
|
|
82
|
+
try {
|
|
83
|
+
return readConfig(root);
|
|
84
|
+
}
|
|
85
|
+
catch {
|
|
86
|
+
return undefined;
|
|
87
|
+
}
|
|
88
|
+
}
|
|
72
89
|
/**
|
|
73
90
|
* Rewrite a list-valued key of `adr/config.yaml` in place. Preserves other
|
|
74
91
|
* keys (`context`, `rules`, unknown keys) and comments attached to the
|
|
75
92
|
* surrounding YAML nodes. When the existing value is a sequence, reuse that
|
|
76
|
-
* node
|
|
93
|
+
* node to keep its flow/block style; the items are re-created, so a comment
|
|
94
|
+
* attached to an individual item does not survive.
|
|
77
95
|
*/
|
|
78
96
|
function writeListConfig(root, key, values) {
|
|
79
97
|
const file = configPath(root);
|
|
@@ -102,4 +120,54 @@ export function writeToolsConfig(root, tools) {
|
|
|
102
120
|
export function writeWorkflowsConfig(root, workflows) {
|
|
103
121
|
writeListConfig(root, 'workflows', workflows);
|
|
104
122
|
}
|
|
123
|
+
/**
|
|
124
|
+
* Stamp the `installed-with:` scalar with the version that is writing the
|
|
125
|
+
* integrations. The stamp is what lets later commands notice that the
|
|
126
|
+
* installed skills predate (or postdate) the running CLI; see
|
|
127
|
+
* {@link installedWithNotice}.
|
|
128
|
+
*/
|
|
129
|
+
export function writeInstalledWithConfig(root, version) {
|
|
130
|
+
const file = configPath(root);
|
|
131
|
+
const parsed = parseConfigDocument(readFileSync(file, 'utf8'));
|
|
132
|
+
parsed.map.set('installed-with', version);
|
|
133
|
+
writeFileSync(file, parsed.document.toString());
|
|
134
|
+
}
|
|
135
|
+
const SEMVER = /^(\d+)\.(\d+)\.(\d+)$/;
|
|
136
|
+
function semver(value) {
|
|
137
|
+
const match = SEMVER.exec(value.trim());
|
|
138
|
+
return match === null ? undefined : [Number(match[1]), Number(match[2]), Number(match[3])];
|
|
139
|
+
}
|
|
140
|
+
/**
|
|
141
|
+
* The one-line drift notice for a repository whose integrations were written
|
|
142
|
+
* by a different adr-kit than the one now running. The newer side suggests
|
|
143
|
+
* `adrkit update`; the older side directs to upgrading the package instead,
|
|
144
|
+
* because running `adrkit update` there would rewrite the newer installed
|
|
145
|
+
* skills with this CLI's older templates. Quiet — `undefined` — when
|
|
146
|
+
* there is nothing honest to say: no stamp (repositories configured before it
|
|
147
|
+
* existed), an explicit integrations opt-out, equal versions, or a version
|
|
148
|
+
* either side cannot parse.
|
|
149
|
+
*/
|
|
150
|
+
export function installedWithNotice(config, currentVersion) {
|
|
151
|
+
const installed = config.installedWith;
|
|
152
|
+
if (installed === undefined)
|
|
153
|
+
return undefined;
|
|
154
|
+
if (config.tools !== undefined && config.tools.length === 0)
|
|
155
|
+
return undefined;
|
|
156
|
+
const written = semver(installed);
|
|
157
|
+
const running = semver(currentVersion);
|
|
158
|
+
if (written === undefined || running === undefined)
|
|
159
|
+
return undefined;
|
|
160
|
+
const order = written[0] - running[0] || written[1] - running[1] || written[2] - running[2];
|
|
161
|
+
if (order === 0)
|
|
162
|
+
return undefined;
|
|
163
|
+
return order < 0
|
|
164
|
+
? `note: the installed integrations were written by adr-kit ${installed}; this is ` +
|
|
165
|
+
`${currentVersion} - run "adrkit update" to refresh them`
|
|
166
|
+
: `note: this repository was configured by adr-kit ${installed}; you are running ` +
|
|
167
|
+
`${currentVersion}, which is older - upgrade adr-kit to at least ${installed}`;
|
|
168
|
+
}
|
|
169
|
+
/** Append the drift notice to a command's output as its own paragraph. */
|
|
170
|
+
export function withNotice(output, notice) {
|
|
171
|
+
return notice === undefined ? output : `${output}\n\n${notice}`;
|
|
172
|
+
}
|
|
105
173
|
//# sourceMappingURL=config.js.map
|
package/dist/core/config.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"config.js","sourceRoot":"","sources":["../../src/core/config.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,YAAY,EAAE,aAAa,EAAE,MAAM,SAAS,CAAC;AAClE,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AACnD,OAAO,EAAE,KAAK,EAAE,KAAK,EAAE,aAAa,EAA+B,MAAM,MAAM,CAAC;AAEhF,MAAM,CAAC,MAAM,OAAO,GAAG,KAAK,CAAC;AAC7B,MAAM,CAAC,MAAM,WAAW,GAAG,aAAa,CAAC;
|
|
1
|
+
{"version":3,"file":"config.js","sourceRoot":"","sources":["../../src/core/config.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,YAAY,EAAE,aAAa,EAAE,MAAM,SAAS,CAAC;AAClE,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AACnD,OAAO,EAAE,KAAK,EAAE,KAAK,EAAE,aAAa,EAA+B,MAAM,MAAM,CAAC;AAEhF,MAAM,CAAC,MAAM,OAAO,GAAG,KAAK,CAAC;AAC7B,MAAM,CAAC,MAAM,WAAW,GAAG,aAAa,CAAC;AAezC;;;;GAIG;AACH,MAAM,UAAU,QAAQ,CAAC,QAAgB;IACvC,IAAI,OAAO,GAAG,OAAO,CAAC,QAAQ,CAAC,CAAC;IAChC,SAAS,CAAC;QACR,IAAI,UAAU,CAAC,IAAI,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,SAAS,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,GAAG,MAAM,OAAO,MAAM,EAAE,CAAC;AAClE,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"deliberation-html.d.ts","sourceRoot":"","sources":["../../src/core/deliberation-html.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"deliberation-html.d.ts","sourceRoot":"","sources":["../../src/core/deliberation-html.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,mBAAmB,CAAC;AAsC1D,mFAAmF;AACnF,wBAAgB,cAAc,CAAC,KAAK,EAAE,gBAAgB,EAAE,EAAE,KAAK,EAAE,MAAM,GAAG,MAAM,CAyH/E"}
|
|
@@ -1,26 +1,32 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { RELATION_STYLE, RELATION_SCRIPT } from './relation-focus.js';
|
|
2
|
+
import { isOverride, isUnlockedQuestion } from './deliberation.js';
|
|
3
|
+
import { CANVAS_STYLE, CANVAS_SCRIPT, canvasHeaderHTML, canvasDockHTML } from './canvas-view.js';
|
|
2
4
|
import { TREE_STYLE, TREE_SCRIPT } from './deliberation-view.js';
|
|
5
|
+
import { SHARE_SCRIPT, SHARE_STYLE } from './share.js';
|
|
3
6
|
import { escapeHtml } from './view-text.js';
|
|
4
7
|
function kindOf(node) {
|
|
5
8
|
return node.type ?? (node.children.length > 0 ? 'question' : 'option');
|
|
6
9
|
}
|
|
7
|
-
/** Only option children can be answers; a settled follow-up is not an answer. */
|
|
8
|
-
function overridden(card) {
|
|
9
|
-
const chosen = card.options.filter(({ node }) => node.status === 'settled');
|
|
10
|
-
return card.kind === 'question' && chosen.length > 0
|
|
11
|
-
&& card.options.some(({ node }) => node.recommended)
|
|
12
|
-
&& !chosen.some(({ node }) => node.recommended);
|
|
13
|
-
}
|
|
14
10
|
function reason(node) {
|
|
15
11
|
return node.reason === undefined ? '' : `<p class="reason">${escapeHtml(node.reason)}</p>`;
|
|
16
12
|
}
|
|
13
|
+
/**
|
|
14
|
+
* The exception states, with the gloss the legend gives each one. `settled` is
|
|
15
|
+
* absent on purpose: it is what a node is when nothing else is said, so a chip
|
|
16
|
+
* would repeat the same word on every card.
|
|
17
|
+
*/
|
|
18
|
+
const STATE_LEGEND = [
|
|
19
|
+
['open', 'unresolved'],
|
|
20
|
+
['rejected', 'not taken'],
|
|
21
|
+
['unrecorded', 'no state marker'],
|
|
22
|
+
];
|
|
17
23
|
/** Render semantic cards on the server; the embedded script only lays them out. */
|
|
18
24
|
export function renderCardTree(nodes, title) {
|
|
19
25
|
const cards = [];
|
|
20
26
|
let sequence = 0;
|
|
21
27
|
function collect(node, parent = '', anchor = '', depth = 0) {
|
|
22
28
|
const kind = depth === 0 && node.type === undefined ? 'root' : kindOf(node);
|
|
23
|
-
const card = { id: `n${++sequence}`, node, kind, parent, anchor, depth, options: [], children: [] };
|
|
29
|
+
const card = { id: `n${++sequence}`, node, kind, parent, anchor, depth, options: [], children: [], unlocked: false };
|
|
24
30
|
cards.push(card);
|
|
25
31
|
for (const child of node.children) {
|
|
26
32
|
if (kind !== 'option' && kindOf(child) === 'option') {
|
|
@@ -36,15 +42,55 @@ export function renderCardTree(nodes, title) {
|
|
|
36
42
|
}
|
|
37
43
|
return card;
|
|
38
44
|
}
|
|
39
|
-
|
|
45
|
+
// A session that settles several decisions records them as sibling roots,
|
|
46
|
+
// which the canvas would draw as unrelated islands. Group them under one
|
|
47
|
+
// presentational card; recorded roots keep their kind, depth, and content.
|
|
48
|
+
// The card carries only its label: no heading, no count, no state.
|
|
49
|
+
const virtual = nodes.length > 1
|
|
50
|
+
? {
|
|
51
|
+
id: `n${++sequence}`,
|
|
52
|
+
node: { text: '', children: [] },
|
|
53
|
+
kind: 'virtual', parent: '', anchor: '', depth: 0, options: [], children: [], unlocked: false,
|
|
54
|
+
}
|
|
55
|
+
: undefined;
|
|
56
|
+
if (virtual !== undefined)
|
|
57
|
+
cards.push(virtual);
|
|
58
|
+
nodes.forEach((node) => {
|
|
59
|
+
const card = collect(node, virtual?.id ?? '');
|
|
60
|
+
virtual?.children.push(card.id);
|
|
61
|
+
});
|
|
62
|
+
// Whether each card's incoming edge is an unlocked one. The question is the
|
|
63
|
+
// outline's, not the drawing's: the node that raised this card is the option
|
|
64
|
+
// it anchors to, or the card it hangs off when it anchors to none. Asking it
|
|
65
|
+
// here lets the drawn edge and the legend read one answer.
|
|
66
|
+
const byId = new Map(cards.map((card) => [card.id, card]));
|
|
67
|
+
const optionNodes = new Map(cards.flatMap((card) => card.options.map(({ id, node }) => [id, node])));
|
|
68
|
+
for (const card of cards) {
|
|
69
|
+
const parent = byId.get(card.parent);
|
|
70
|
+
if (parent === undefined || card.kind === 'virtual')
|
|
71
|
+
continue;
|
|
72
|
+
const anchor = optionNodes.get(card.anchor);
|
|
73
|
+
card.unlocked = isUnlockedQuestion(card.node, anchor ?? parent.node, anchor === undefined && parent.kind === 'root');
|
|
74
|
+
}
|
|
40
75
|
let questionNumber = 0;
|
|
76
|
+
/** The states that actually draw a chip, so the legend keys only what it can point at. */
|
|
77
|
+
const chipped = new Set();
|
|
41
78
|
const markup = cards.map((card) => {
|
|
42
79
|
const { node, id, kind } = card;
|
|
43
|
-
const override =
|
|
80
|
+
const override = isOverride(card.node);
|
|
44
81
|
const chosen = card.options.filter((option) => option.node.status === 'settled');
|
|
45
82
|
const other = card.options.filter((option) => option.node.status !== 'settled');
|
|
46
83
|
const status = node.status ?? 'unrecorded';
|
|
47
|
-
|
|
84
|
+
// Only an exception earns a chip; a settled node already reads as settled
|
|
85
|
+
// from its chosen answer, so the same word on every card would say nothing.
|
|
86
|
+
const chip = kind !== 'virtual' && status !== 'settled';
|
|
87
|
+
if (chip)
|
|
88
|
+
chipped.add(status);
|
|
89
|
+
const label = kind === 'question' ? `QUESTION ${String(++questionNumber).padStart(2, '0')}`
|
|
90
|
+
: kind === 'virtual' ? 'DELIBERATION' : kind.toUpperCase();
|
|
91
|
+
const stateChip = chip ? `<span class="state ${status}">${status}</span>` : '';
|
|
92
|
+
// A folded option writes its state as plain text, not as a chip, so it earns
|
|
93
|
+
// no legend key: the word is already readable and the pill is what needs one.
|
|
48
94
|
const optionMarkup = (option) => {
|
|
49
95
|
const selected = option.node.status === 'settled';
|
|
50
96
|
const state = option.node.status ?? 'unrecorded';
|
|
@@ -52,30 +98,49 @@ export function renderCardTree(nodes, title) {
|
|
|
52
98
|
<span class="badge">${selected ? '✓ Selected' : escapeHtml(state)}${option.node.recommended ? ' · Agent recommended' : ''}</span>
|
|
53
99
|
<p>${escapeHtml(option.node.text)}</p>${reason(option.node)}</div>`;
|
|
54
100
|
};
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
101
|
+
const heading = kind === 'virtual' ? '' : `<h2 id="${id}-title">${escapeHtml(node.text)}</h2>`;
|
|
102
|
+
const labelledBy = kind === 'virtual' ? '' : ` aria-labelledby="${id}-title"`;
|
|
103
|
+
const toggleLabel = kind === 'virtual' ? 'Toggle all decisions' : `Toggle follow-ups: ${escapeHtml(node.text)}`;
|
|
104
|
+
return `<article id="${id}" class="card ${kind}" data-parent="${card.parent}" data-anchor="${card.anchor}" data-state="${status}" data-unlocked="${card.unlocked}" style="--depth:${card.depth}"${labelledBy}${kind === 'virtual' ? '' : ' tabindex="0"'}>
|
|
105
|
+
<div class="cardhead"><div class="label"><span>${label}</span>${stateChip}</div>
|
|
106
|
+
${heading}${reason(node)}
|
|
58
107
|
${node.recommended ? '<p class="badge">Agent recommended</p>' : ''}
|
|
59
108
|
${override ? '<p class="override">Human override · recommendation not taken</p>' : ''}</div>
|
|
60
109
|
${chosen.map(optionMarkup).join('\n')}
|
|
61
110
|
${other.length === 0 ? '' : `<details class="alts"><summary>${other.length} other option${other.length === 1 ? '' : 's'}${override ? ' · includes recommendation' : ''}</summary>${other.map(optionMarkup).join('\n')}</details>`}
|
|
62
|
-
${card.children.length === 0 ? '' : `<button class="branch" aria-expanded="true" aria-controls="${card.children.join(' ')}" aria-label="
|
|
111
|
+
${card.children.length === 0 ? '' : `<button class="branch" aria-expanded="true" aria-controls="${card.children.join(' ')}" aria-label="${toggleLabel}">−</button>`}
|
|
63
112
|
</article>`;
|
|
64
113
|
}).join('\n');
|
|
114
|
+
const overrides = cards.filter((card) => isOverride(card.node)).length;
|
|
115
|
+
const stats = [
|
|
116
|
+
['questions', questionNumber],
|
|
117
|
+
['options', cards.reduce((sum, card) => sum + card.options.length, 0)],
|
|
118
|
+
['overrides', overrides],
|
|
119
|
+
];
|
|
120
|
+
// The legend quotes what the picture draws: an entry for something no card
|
|
121
|
+
// shows sends the reader looking for it, so each one waits for its object.
|
|
122
|
+
// The edge keys carry a line sample in the stroke the view draws, because a
|
|
123
|
+
// dashed text dash looks like neither of the two edges it would be naming.
|
|
124
|
+
const legend = [
|
|
125
|
+
cards.some((card) => card.options.some(({ node }) => node.status === 'settled'))
|
|
126
|
+
? '<span data-share-selector=".card:not([hidden]) .answer">✓ Selected answer</span>' : '',
|
|
127
|
+
cards.some((card) => card.parent !== '' && !card.unlocked) ? '<span data-share-selector="#edges path[data-unlocked=false]"><i class="edge-key"></i>Raised by</span>' : '',
|
|
128
|
+
cards.some((card) => card.unlocked) ? '<span data-share-selector="#edges path[data-unlocked=true]"><i class="edge-key unlocked"></i>Unlocked question</span>' : '',
|
|
129
|
+
overrides === 0 ? '' : '<span class="override-key" data-share-selector=".card:not([hidden]) .override">● Human override</span>',
|
|
130
|
+
...STATE_LEGEND
|
|
131
|
+
.filter(([state]) => chipped.has(state))
|
|
132
|
+
.map(([state, gloss]) => `<span data-share-selector=".card:not([hidden]) .cardhead .state.${state}"><span class="state ${state}">${state}</span>${gloss}</span>`),
|
|
133
|
+
].filter(Boolean).join('');
|
|
65
134
|
return `<!doctype html>
|
|
66
135
|
<html lang="en">
|
|
67
136
|
<head><meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1">
|
|
68
|
-
<title>${escapeHtml(title)} — deliberation tree</title><style>${TREE_STYLE}</style></head>
|
|
137
|
+
<title>${escapeHtml(title)} — deliberation tree</title><style>${TREE_STYLE}${CANVAS_STYLE}${SHARE_STYLE}${RELATION_STYLE}</style></head>
|
|
69
138
|
<body>
|
|
70
|
-
|
|
71
|
-
<section class="intro"><div><div class="eyebrow">DELIBERATION / DESIGN TREE</div><h1>${escapeHtml(title)}</h1><p>Follow the choices. See what each answer unlocked.</p></div>
|
|
72
|
-
<div class="stats"><div><strong>${questionNumber}</strong><span>questions</span></div><div><strong>${cards.reduce((sum, card) => sum + card.options.length, 0)}</strong><span>options</span></div><div><strong>${cards.filter(overridden).length}</strong><span>overrides</span></div></div></section>
|
|
139
|
+
${canvasHeaderHTML(title, stats, 'Hover or focus a card to trace its ancestors and follow-ups. Escape clears the highlight.')}
|
|
73
140
|
<main id="viewport" tabindex="0" aria-label="Decision tree" aria-describedby="instructions"><div id="world"><svg id="edges" aria-hidden="true"></svg><div id="cards">${markup}</div></div>
|
|
74
|
-
|
|
75
|
-
${canvasControlsHTML('Fit tree')}</main>
|
|
76
|
-
<footer><span>ADR Kit / Deliberation</span><div class="legend"><span>✓ Selected answer</span><span>— Unlocked question</span><span class="override-key">● Human override</span></div></footer>
|
|
141
|
+
${canvasDockHTML(legend, 'Fit tree')}</main>
|
|
77
142
|
<noscript><p class="no-script">JavaScript is disabled. All cards are shown in outline order; expand other options to read their reasons.</p></noscript>
|
|
78
|
-
<script>${CANVAS_SCRIPT}${TREE_SCRIPT}</script>
|
|
143
|
+
<script>${CANVAS_SCRIPT}${SHARE_SCRIPT}${TREE_SCRIPT}${RELATION_SCRIPT}</script>
|
|
79
144
|
</body></html>\n`;
|
|
80
145
|
}
|
|
81
146
|
//# sourceMappingURL=deliberation-html.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"deliberation-html.js","sourceRoot":"","sources":["../../src/core/deliberation-html.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"deliberation-html.js","sourceRoot":"","sources":["../../src/core/de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,CAAC,KAAK,CAAC,CAAC;aACvC,GAAG,CAAC,CAAC,CAAC,KAAK,EAAE,KAAK,CAAC,EAAE,EAAE,CAAC,mEAAmE,KAAK,wBAAwB,KAAK,KAAK,KAAK,UAAU,KAAK,SAAS,CAAC;KACpK,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;IAC3B,OAAO;;;SAGA,UAAU,CAAC,KAAK,CAAC,sCAAsC,UAAU,GAAG,YAAY,GAAG,WAAW,GAAG,cAAc;;EAEtH,gBAAgB,CAAC,KAAK,EAAE,KAAK,EAAE,2FAA2F,CAAC;uKAC0C,MAAM;EAC3K,cAAc,CAAC,MAAM,EAAE,UAAU,CAAC;;UAE1B,aAAa,GAAG,YAAY,GAAG,WAAW,GAAG,eAAe;iBACrD,CAAC;AAClB,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"deliberation-view.d.ts","sourceRoot":"","sources":["../../src/core/deliberation-view.ts"],"names":[],"mappings":"AAAA,mFAAmF;AACnF,eAAO,MAAM,UAAU,
|
|
1
|
+
{"version":3,"file":"deliberation-view.d.ts","sourceRoot":"","sources":["../../src/core/deliberation-view.ts"],"names":[],"mappings":"AAAA,mFAAmF;AACnF,eAAO,MAAM,UAAU,QA4NtB,CAAC;AAIF,eAAO,MAAM,WAAW,QAmHvB,CAAC"}
|
|
@@ -34,92 +34,10 @@ button {
|
|
|
34
34
|
button:hover {
|
|
35
35
|
background: #edf3ef
|
|
36
36
|
}
|
|
37
|
-
header {
|
|
38
|
-
height: 72px;
|
|
39
|
-
background: #fff;
|
|
40
|
-
display: flex;
|
|
41
|
-
align-items: center;
|
|
42
|
-
justify-content: space-between;
|
|
43
|
-
padding: 0 30px;
|
|
44
|
-
border-bottom: 1px solid #e1e7e1;
|
|
45
|
-
gap: 15px
|
|
46
|
-
}
|
|
47
|
-
.brand {
|
|
48
|
-
font-size: 17px;
|
|
49
|
-
font-weight: 750;
|
|
50
|
-
letter-spacing: -.6px;
|
|
51
|
-
display: flex;
|
|
52
|
-
align-items: center;
|
|
53
|
-
gap: 11px
|
|
54
|
-
}
|
|
55
|
-
.logo {
|
|
56
|
-
background: #284f40;
|
|
57
|
-
color: white;
|
|
58
|
-
border-radius: 8px;
|
|
59
|
-
padding: 7px 9px;
|
|
60
|
-
font-family: monospace
|
|
61
|
-
}
|
|
62
|
-
.brand small {
|
|
63
|
-
font-size: 11px;
|
|
64
|
-
color: #728079;
|
|
65
|
-
font-weight: 500;
|
|
66
|
-
letter-spacing: 1px;
|
|
67
|
-
margin-left: 16px
|
|
68
|
-
}
|
|
69
|
-
.intro {
|
|
70
|
-
min-height: 145px;
|
|
71
|
-
padding: 28px 36px;
|
|
72
|
-
display: flex;
|
|
73
|
-
justify-content: space-between;
|
|
74
|
-
align-items: center;
|
|
75
|
-
gap: 24px
|
|
76
|
-
}
|
|
77
|
-
.eyebrow {
|
|
78
|
-
color: #788b7b;
|
|
79
|
-
letter-spacing: 2px;
|
|
80
|
-
font: 11px monospace;
|
|
81
|
-
margin-bottom: 9px
|
|
82
|
-
}
|
|
83
|
-
h1 {
|
|
84
|
-
font-size: 25px;
|
|
85
|
-
letter-spacing: -.7px;
|
|
86
|
-
margin: 0;
|
|
87
|
-
font-weight: 650
|
|
88
|
-
}
|
|
89
|
-
.intro p {
|
|
90
|
-
font-size: 12px;
|
|
91
|
-
color: #718078;
|
|
92
|
-
margin: 10px 0 0
|
|
93
|
-
}
|
|
94
|
-
.stats {
|
|
95
|
-
display: flex;
|
|
96
|
-
gap: 24px;
|
|
97
|
-
text-align: center
|
|
98
|
-
}
|
|
99
|
-
.stats strong {
|
|
100
|
-
font-size: 24px;
|
|
101
|
-
font-weight: 500;
|
|
102
|
-
display: block
|
|
103
|
-
}
|
|
104
|
-
.stats span {
|
|
105
|
-
font-size: 11px;
|
|
106
|
-
color: #7c8880;
|
|
107
|
-
display: block;
|
|
108
|
-
margin-top: 4px
|
|
109
|
-
}
|
|
110
37
|
main {
|
|
111
38
|
position: relative;
|
|
112
|
-
height: calc(100dvh - 251px);
|
|
113
|
-
min-height: 420px;
|
|
114
|
-
overflow: hidden;
|
|
115
|
-
touch-action: none;
|
|
116
39
|
background-image: radial-gradient(#cdd8cc .8px,transparent .8px);
|
|
117
40
|
background-size: 20px 20px;
|
|
118
|
-
border-block: 1px solid #e0e7df;
|
|
119
|
-
cursor: grab
|
|
120
|
-
}
|
|
121
|
-
main.dragging {
|
|
122
|
-
cursor: grabbing
|
|
123
41
|
}
|
|
124
42
|
#world {
|
|
125
43
|
position: absolute;
|
|
@@ -137,7 +55,6 @@ main.dragging {
|
|
|
137
55
|
border: 1px solid #dce4dc;
|
|
138
56
|
border-radius: 13px;
|
|
139
57
|
box-shadow: 0 3px 8px #25403506;
|
|
140
|
-
cursor: auto;
|
|
141
58
|
overflow: visible
|
|
142
59
|
}
|
|
143
60
|
.card:hover {
|
|
@@ -174,6 +91,7 @@ main.dragging {
|
|
|
174
91
|
margin: 0 13px 13px;
|
|
175
92
|
padding: 13px;
|
|
176
93
|
background: #f1f7f1;
|
|
94
|
+
color: #264c38;
|
|
177
95
|
border: 1px solid #e2ece1;
|
|
178
96
|
border-radius: 8px;
|
|
179
97
|
position: relative
|
|
@@ -249,6 +167,15 @@ main.dragging {
|
|
|
249
167
|
font-weight: 500;
|
|
250
168
|
line-height: 1.4
|
|
251
169
|
}
|
|
170
|
+
.virtual {
|
|
171
|
+
width: 168px;
|
|
172
|
+
background: #fbfdfb;
|
|
173
|
+
border-style: dashed;
|
|
174
|
+
border-color: #b6c7ba;
|
|
175
|
+
}
|
|
176
|
+
.virtual .cardhead {
|
|
177
|
+
padding: 14px 16px 12px;
|
|
178
|
+
}
|
|
252
179
|
.branch {
|
|
253
180
|
position: absolute;
|
|
254
181
|
right: -13px;
|
|
@@ -263,86 +190,6 @@ main.dragging {
|
|
|
263
190
|
box-shadow: 0 2px 5px #274b3910;
|
|
264
191
|
z-index: 2
|
|
265
192
|
}
|
|
266
|
-
.controls {
|
|
267
|
-
position: absolute;
|
|
268
|
-
bottom: 22px;
|
|
269
|
-
right: 24px;
|
|
270
|
-
display: flex;
|
|
271
|
-
align-items: center;
|
|
272
|
-
padding: 5px;
|
|
273
|
-
gap: 3px;
|
|
274
|
-
background: white;
|
|
275
|
-
border: 1px solid #dce4dc;
|
|
276
|
-
border-radius: 11px;
|
|
277
|
-
box-shadow: 0 4px 20px #294d3e0a
|
|
278
|
-
}
|
|
279
|
-
.controls button {
|
|
280
|
-
border: 0
|
|
281
|
-
}
|
|
282
|
-
.controls output {
|
|
283
|
-
font: 11px monospace;
|
|
284
|
-
width: 44px;
|
|
285
|
-
text-align: center
|
|
286
|
-
}
|
|
287
|
-
.hint {
|
|
288
|
-
position: absolute;
|
|
289
|
-
bottom: 25px;
|
|
290
|
-
left: 28px;
|
|
291
|
-
color: #7a8a7f;
|
|
292
|
-
font-size: 11px;
|
|
293
|
-
background: #f6f8f5df;
|
|
294
|
-
padding: 7px;
|
|
295
|
-
border-radius: 5px
|
|
296
|
-
}
|
|
297
|
-
footer {
|
|
298
|
-
height: 34px;
|
|
299
|
-
display: flex;
|
|
300
|
-
align-items: center;
|
|
301
|
-
justify-content: space-between;
|
|
302
|
-
padding: 0 30px;
|
|
303
|
-
font-size: 10px;
|
|
304
|
-
color: #87928a
|
|
305
|
-
}
|
|
306
|
-
.legend {
|
|
307
|
-
display: flex;
|
|
308
|
-
gap: 18px
|
|
309
|
-
}
|
|
310
|
-
.legend span {
|
|
311
|
-
display: flex;
|
|
312
|
-
align-items: center;
|
|
313
|
-
gap: 6px
|
|
314
|
-
}
|
|
315
|
-
@media(max-width:700px) {
|
|
316
|
-
header {
|
|
317
|
-
padding: 0 14px
|
|
318
|
-
}
|
|
319
|
-
.brand small,.stats {
|
|
320
|
-
display: none
|
|
321
|
-
}
|
|
322
|
-
.intro {
|
|
323
|
-
padding: 20px;
|
|
324
|
-
min-height: 135px
|
|
325
|
-
}
|
|
326
|
-
h1 {
|
|
327
|
-
font-size: 20px
|
|
328
|
-
}
|
|
329
|
-
main {
|
|
330
|
-
height: calc(100dvh - 241px)
|
|
331
|
-
}
|
|
332
|
-
footer {
|
|
333
|
-
padding: 0 12px
|
|
334
|
-
}
|
|
335
|
-
.hint {
|
|
336
|
-
display: none
|
|
337
|
-
}
|
|
338
|
-
.controls {
|
|
339
|
-
right: 12px;
|
|
340
|
-
bottom: 14px
|
|
341
|
-
}
|
|
342
|
-
|
|
343
|
-
}
|
|
344
|
-
|
|
345
|
-
|
|
346
193
|
.card { overflow-wrap: anywhere; }
|
|
347
194
|
.cardhead .reason { font-size: 12px; color: #67786c; line-height: 1.6; }
|
|
348
195
|
.root .reason { color: #bed0c2; }
|
|
@@ -350,26 +197,28 @@ footer {
|
|
|
350
197
|
.state.rejected { color: #96554c; background: #faeeeb; }
|
|
351
198
|
.state.unrecorded { color: #647369; background: #eff2ee; }
|
|
352
199
|
.root .state { color: #264c38; }
|
|
200
|
+
.root .alts { color: #bacdbc; border-top-color: #3f6455; }
|
|
201
|
+
.root .alt { color: #cfdcd1; border-top-color: #3f6455; }
|
|
202
|
+
.root .alt .badge { color: #a3bba9; }
|
|
203
|
+
.root .alt p { color: #b4c4b6; }
|
|
353
204
|
.override-key { color: #7750a5; }
|
|
205
|
+
/* The legend's state keys quote the card chips, so they match their size. */
|
|
206
|
+
.canvas-legend .legend .state { font-size: 10px; }
|
|
207
|
+
/* The edge keys are line samples, drawn in the stroke the view actually uses:
|
|
208
|
+
a key that looks like a line but not like the line it names teaches nothing. */
|
|
209
|
+
.edge-key { width: 22px; height: 0; border-top: 1.5px solid #b6c7ba; }
|
|
210
|
+
.edge-key.unlocked { border-top: 2px solid #7ca38a; }
|
|
354
211
|
.option { border-style: dashed; }
|
|
355
212
|
.card[hidden] { display: none; }
|
|
356
213
|
.card { position: relative; margin: 18px 24px 18px calc(24px + var(--depth) * 24px); }
|
|
357
214
|
#world { position: relative; }
|
|
358
215
|
main { height: auto; min-height: 0; overflow: auto; touch-action: auto; cursor: auto; }
|
|
359
|
-
#edges, .
|
|
360
|
-
|
|
216
|
+
#edges, .branch, .js-control { display: none; }
|
|
217
|
+
|
|
361
218
|
.interactive #world { position: absolute; }
|
|
362
219
|
.interactive .card { position: absolute; margin: 0; }
|
|
363
|
-
.interactive #edges, .interactive .branch, .interactive .
|
|
364
|
-
.interactive .controls { display: flex; }
|
|
365
|
-
.interactive .dragging { cursor: grabbing; }
|
|
220
|
+
.interactive #edges, .interactive .branch, .interactive .js-control { display: block; }
|
|
366
221
|
.no-script { padding: 20px; }
|
|
367
|
-
@media (max-width: 700px) {
|
|
368
|
-
.interactive main { height: calc(100dvh - 241px); }
|
|
369
|
-
.interactive .hint { display: none; }
|
|
370
|
-
.intro { align-items: start; }
|
|
371
|
-
footer { height: auto; min-height: 34px; gap: 12px; flex-wrap: wrap; }
|
|
372
|
-
}
|
|
373
222
|
`;
|
|
374
223
|
// Kept as readable JavaScript: tsc ships this string unchanged in the CLI bundle.
|
|
375
224
|
// All record text is server-escaped HTML, never interpolated into this program.
|
|
@@ -379,7 +228,6 @@ export const TREE_SCRIPT = String.raw `
|
|
|
379
228
|
if (!canvas) return;
|
|
380
229
|
const { viewport, world } = canvas;
|
|
381
230
|
const svg = document.getElementById('edges');
|
|
382
|
-
const allButton = document.getElementById('all');
|
|
383
231
|
const cards = Array.from(document.querySelectorAll('.card'));
|
|
384
232
|
if (!cards.length) return;
|
|
385
233
|
const items = cards.map(card => ({
|
|
@@ -450,31 +298,22 @@ export const TREE_SCRIPT = String.raw `
|
|
|
450
298
|
const startX = parent.x + parent.width;
|
|
451
299
|
const endX = item.x, endY = item.y + Math.min(65, item.height / 2);
|
|
452
300
|
const midpoint = (startX + endX) / 2;
|
|
453
|
-
|
|
454
|
-
//
|
|
455
|
-
|
|
456
|
-
// the root card is still unlocked by that option. Mermaid asks whether
|
|
457
|
-
// the immediate parent node is the root; this is the same question.
|
|
458
|
-
const sourceIsRoot = !item.anchor && parent.card.classList.contains('root');
|
|
459
|
-
const unlocked = !sourceIsRoot
|
|
460
|
-
&& item.card.classList.contains('question') && sourceState === 'settled';
|
|
301
|
+
// The server settled whether this edge is an unlocked one, so the styler
|
|
302
|
+
// and the legend cannot disagree about which edges are frontier steps.
|
|
303
|
+
const unlocked = item.card.dataset.unlocked === 'true';
|
|
461
304
|
const path = document.createElementNS('http://www.w3.org/2000/svg', 'path');
|
|
462
305
|
path.setAttribute('d', 'M' + startX + ',' + startY + ' C' + midpoint + ',' + startY
|
|
463
306
|
+ ' ' + midpoint + ',' + endY + ' ' + endX + ',' + endY);
|
|
464
307
|
path.setAttribute('fill', 'none');
|
|
465
308
|
path.setAttribute('stroke', unlocked ? '#7ca38a' : '#b6c7ba');
|
|
466
309
|
path.setAttribute('stroke-width', unlocked ? '2' : '1.5');
|
|
467
|
-
if (!unlocked && !parent.card.classList.contains('root')) path.setAttribute('stroke-dasharray', '4 4');
|
|
468
310
|
path.dataset.from = item.anchor ? item.anchor.id : parent.id;
|
|
469
311
|
path.dataset.to = item.id;
|
|
470
312
|
path.dataset.unlocked = String(unlocked);
|
|
471
313
|
svg.append(path);
|
|
472
314
|
}
|
|
473
|
-
const details = Array.from(document.querySelectorAll('.alts'));
|
|
474
|
-
allButton.textContent = details.length && details.every(detail => detail.open)
|
|
475
|
-
? 'Collapse all options' : 'Expand all options';
|
|
476
|
-
allButton.disabled = details.length === 0;
|
|
477
315
|
canvas.paint();
|
|
316
|
+
world.dispatchEvent(new Event('adr-layout'));
|
|
478
317
|
}
|
|
479
318
|
window.__adrCanvasLayout = layout;
|
|
480
319
|
|
|
@@ -493,15 +332,9 @@ export const TREE_SCRIPT = String.raw `
|
|
|
493
332
|
});
|
|
494
333
|
}
|
|
495
334
|
for (const detail of document.querySelectorAll('.alts')) detail.addEventListener('toggle', () => canvas.schedule());
|
|
496
|
-
allButton.addEventListener('click', () => {
|
|
497
|
-
const details = Array.from(document.querySelectorAll('.alts'));
|
|
498
|
-
const open = !details.every(detail => detail.open);
|
|
499
|
-
details.forEach(detail => { detail.open = open; });
|
|
500
|
-
layout();
|
|
501
|
-
});
|
|
502
335
|
|
|
503
336
|
layout();
|
|
504
|
-
canvas.
|
|
337
|
+
canvas.fitWidth();
|
|
505
338
|
})();
|
|
506
339
|
|
|
507
340
|
`;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"deliberation-view.js","sourceRoot":"","sources":["../../src/core/deliberation-view.ts"],"names":[],"mappings":"AAAA,mFAAmF;AACnF,MAAM,CAAC,MAAM,UAAU,GAAG,MAAM,CAAC,GAAG,CAAA
|
|
1
|
+
{"version":3,"file":"deliberation-view.js","sourceRoot":"","sources":["../../src/core/deliberation-view.ts"],"names":[],"mappings":"AAAA,mFAAmF;AACnF,MAAM,CAAC,MAAM,UAAU,GAAG,MAAM,CAAC,GAAG,CAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA4NnC,CAAC;AAEF,kFAAkF;AAClF,gFAAgF;AAChF,MAAM,CAAC,MAAM,WAAW,GAAG,MAAM,CAAC,GAAG,CAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAmHpC,CAAC"}
|