@booki-aui/readiness 0.2.5 → 0.3.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/CHANGELOG.md +18 -0
- package/README.md +2 -2
- package/dist/conformance.js +7 -3
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,23 @@
|
|
|
1
1
|
# @booki/readiness
|
|
2
2
|
|
|
3
|
+
## 0.3.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- [#184](https://github.com/Walgermo/booki/pull/184) [`eb83ef8`](https://github.com/Walgermo/booki/commit/eb83ef87b6a3eaa8c91e63a27879710904361cd2) Thanks [@Walgermo](https://github.com/Walgermo)! - Preserve fractional basis points when calculating invoice and voucher tax. Payment batch approval and release now require a real calendar date. Aging reports, filtered money columns and party drill-downs calculate totals exactly and refuse totals outside the safe minor-unit range.
|
|
8
|
+
|
|
9
|
+
New working-paper proposals receive opaque, durable IDs. Read the ID from the proposal or bridge result when accepting, rejecting or withdrawing it. Existing pending proposals keep their IDs. HTML-backed papers preserve callout editability and list item identities. In the editor, Alt+Down focuses the command or mention list. Arrow keys, Home and End navigate, Enter selects, and Escape returns to the text without changing it.
|
|
10
|
+
|
|
11
|
+
Conformance checks on an empty bridge now report an incomplete result and return `conforms: false`. Run the check after the screen mounts.
|
|
12
|
+
|
|
13
|
+
### Patch Changes
|
|
14
|
+
|
|
15
|
+
- [#186](https://github.com/Walgermo/booki/pull/186) [`c735db6`](https://github.com/Walgermo/booki/commit/c735db698802f13d18b7aa698a07a5bd49099f5d) Thanks [@Walgermo](https://github.com/Walgermo)! - Preserve the classification of HTML callouts, such as `data-callout="warning"`, when a working paper is opened and saved.
|
|
16
|
+
|
|
17
|
+
Keep editor buttons in place during pointer clicks below open suggestions. Rejected aging filters now preserve the report and CSV. Unrepresentable aging reports show an issue, and a hidden money column with an unrepresentable total no longer prevents other columns from rendering.
|
|
18
|
+
|
|
19
|
+
Conformance checks skip the person-only probe until the screen has mounted controls.
|
|
20
|
+
|
|
3
21
|
## 0.2.5
|
|
4
22
|
|
|
5
23
|
### Patch Changes
|
package/README.md
CHANGED
|
@@ -158,7 +158,7 @@ The checks, with the section each enforces:
|
|
|
158
158
|
|
|
159
159
|
| Id | § | Level | What it checks |
|
|
160
160
|
| --- | --- | --- | --- |
|
|
161
|
-
| `bridge-shape` | 2 | MUST | `snapshot`, `act` and `subscribe` are functions, and `snapshot` returns an array. |
|
|
161
|
+
| `bridge-shape` | 2 | MUST | `snapshot`, `act` and `subscribe` are functions, and `snapshot` returns an array with mounted controls. An empty array skips this check. |
|
|
162
162
|
| `snapshot-named` | 3.1 | MUST | Every component has a `ref`, `component`, `label` and string `actions`; labels are unique. |
|
|
163
163
|
| `snapshot-values` | 3.2 | MUST | Minor-unit values are integers or `null`; dates (and a date control's `value`) are `YYYY-MM-DD` or `null`, at every level, lists included. |
|
|
164
164
|
| `snapshot-secrets` | 3.5 | MUST | The snapshot holds none of the literal `secrets` and no secret pattern (the same finder as the audit; amounts in minor units are not read as account numbers). |
|
|
@@ -174,7 +174,7 @@ The checks, with the section each enforces:
|
|
|
174
174
|
Each check returns `pass`, `fail` or `skip`. A **skip** means the suite had no
|
|
175
175
|
input for the check, not that the check passed: no `drive`, `closedList`,
|
|
176
176
|
`server` or `secrets` option was given, or the bridge has no components to
|
|
177
|
-
probe. `conforms` is `false`
|
|
177
|
+
probe. `conforms` is `false` when a MUST check fails or the bridge has no mounted controls. An empty screen reports an incomplete check. The report lists the
|
|
178
178
|
passes, failures and skips, so give every option you can.
|
|
179
179
|
|
|
180
180
|
The suite does not yet cover the per-language refusals (spec 10.4) or the
|
package/dist/conformance.js
CHANGED
|
@@ -38,6 +38,7 @@ var checks = [
|
|
|
38
38
|
if (missing.length > 0) return fail(`Missing functions: ${missing.join(", ")}.`);
|
|
39
39
|
const snap = await target.bridge.snapshot();
|
|
40
40
|
if (!Array.isArray(snap)) return fail("snapshot() must return an array of components.");
|
|
41
|
+
if (snap.length === 0) return skip("No mounted controls. Mount the screen before running conformance.");
|
|
41
42
|
return pass(`snapshot, act and subscribe are functions; snapshot returns ${snap.length} components.`);
|
|
42
43
|
}
|
|
43
44
|
},
|
|
@@ -221,6 +222,7 @@ var checks = [
|
|
|
221
222
|
level: "MUST",
|
|
222
223
|
run: async (target) => {
|
|
223
224
|
const snap = await components(target);
|
|
225
|
+
if (!snap.length) return skip("No mounted controls to check for person-only actions.");
|
|
224
226
|
const offered = snap.flatMap((c) => c.actions.filter((a) => PERSON_ACTION.test(a)).map((a) => `${c.ref}.${a}`));
|
|
225
227
|
if (offered.length > 0) {
|
|
226
228
|
return fail(`An agent is offered person-only actions: ${offered.join(", ")}.`);
|
|
@@ -334,14 +336,16 @@ async function runConformance(target) {
|
|
|
334
336
|
const passed = checks2.filter((c) => c.status === "pass").length;
|
|
335
337
|
const failed = checks2.filter((c) => c.status === "fail").length;
|
|
336
338
|
const skipped = checks2.filter((c) => c.status === "skip").length;
|
|
337
|
-
const
|
|
339
|
+
const measured = checks2.find((c) => c.id === "bridge-shape")?.status === "pass";
|
|
340
|
+
const conforms = measured && !checks2.some((c) => c.level === "MUST" && c.status === "fail");
|
|
338
341
|
return { contract: "0.1", checks: checks2, passed, failed, skipped, conforms };
|
|
339
342
|
}
|
|
340
343
|
function formatConformance(report) {
|
|
341
344
|
const lines = report.checks.map((c) => `${c.status.toUpperCase()} \xA7${c.section} ${c.id} ${c.message}`);
|
|
342
|
-
const
|
|
345
|
+
const empty = report.checks.some((c) => c.id === "bridge-shape" && c.status === "skip");
|
|
346
|
+
const verdict = empty ? "Incomplete conformance check for" : report.conforms ? "Conforms to" : "Does not conform to";
|
|
343
347
|
lines.push(
|
|
344
|
-
`${verdict}
|
|
348
|
+
`${verdict} the Agent Contract ${report.contract}: ${report.passed} passed, ${report.failed} failed, ${report.skipped} skipped.`
|
|
345
349
|
);
|
|
346
350
|
return lines.join("\n");
|
|
347
351
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@booki-aui/readiness",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.3.0",
|
|
4
4
|
"description": "Agent readiness check for accounting screens: what stops an AI agent on a page, scored 0-100 against the Agent Contract, with fixes.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "MIT",
|