@booki-aui/core 0.3.0 → 0.3.2
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 +20 -0
- package/dist/activity.js +2 -2
- package/dist/aging.js +2 -2
- package/dist/approval.js +2 -2
- package/dist/attachments.js +2 -2
- package/dist/audit.js +2 -2
- package/dist/{chunk-SBWIM62T.js → chunk-4FRT7XRX.js} +2 -2
- package/dist/{chunk-SPA45TN5.js → chunk-5YV57WVB.js} +2 -2
- package/dist/{chunk-DT3HAYKU.js → chunk-62QTK3RO.js} +3 -3
- package/dist/{chunk-PG6CC27E.js → chunk-6IVK3UQA.js} +2 -2
- package/dist/{chunk-PL2ZRRTV.js → chunk-6SFOABFT.js} +2 -2
- package/dist/{chunk-LVKCG5WR.js → chunk-B45JAHB5.js} +3 -3
- package/dist/{chunk-YUPCBRRP.js → chunk-BIFYH2Y6.js} +2 -2
- package/dist/{chunk-TYL4PAUC.js → chunk-BUMQBGO3.js} +2 -2
- package/dist/{chunk-33O2OHL6.js → chunk-CBOKL727.js} +2 -2
- package/dist/{chunk-AK5V6MNR.js → chunk-D7CU3G3K.js} +2 -2
- package/dist/{chunk-J3LLJEU2.js → chunk-EGUAYFGH.js} +11 -3
- package/dist/{chunk-J3LLJEU2.js.map → chunk-EGUAYFGH.js.map} +1 -1
- package/dist/{chunk-A2QYZDOI.js → chunk-EOY5C5DL.js} +2 -2
- package/dist/{chunk-YGHY2MVR.js → chunk-HCMLRRN4.js} +3 -3
- package/dist/{chunk-PLYGQ63I.js → chunk-JMOLS4U5.js} +2 -2
- package/dist/{chunk-FWZPV7NF.js → chunk-KAFDCP6S.js} +2 -2
- package/dist/{chunk-HCJY7UL5.js → chunk-KDCB6RKO.js} +3 -3
- package/dist/{chunk-I5SGNZIS.js → chunk-KMXOHG6A.js} +2 -2
- package/dist/{chunk-LR4X7GTZ.js → chunk-KXYJZ6HG.js} +2 -2
- package/dist/{chunk-5ELWBE73.js → chunk-MEZZFV6D.js} +24 -4
- package/dist/{chunk-5ELWBE73.js.map → chunk-MEZZFV6D.js.map} +1 -1
- package/dist/{chunk-2HIQCBZT.js → chunk-MN3MBEQ7.js} +2 -2
- package/dist/{chunk-UFGTZK2J.js → chunk-OKVUS75Z.js} +2 -2
- package/dist/{chunk-ZFWPR3SQ.js → chunk-SRVXIZKH.js} +3 -3
- package/dist/{chunk-64OXR7M2.js → chunk-TTD6VZNY.js} +2 -2
- package/dist/{chunk-XSBPSQMB.js → chunk-U2M6WCUI.js} +2 -2
- package/dist/{chunk-GGK3KTR6.js → chunk-V5DTXL3H.js} +2 -2
- package/dist/{chunk-VMDKFRLL.js → chunk-VCBYT2E7.js} +2 -2
- package/dist/{chunk-GH6FRLYM.js → chunk-VOA56E4X.js} +2 -2
- package/dist/{chunk-GSDFDZPH.js → chunk-XDAXPC27.js} +2 -2
- package/dist/{chunk-HTILL5EQ.js → chunk-XKUL5BDJ.js} +2 -2
- package/dist/{chunk-4F5QLWKQ.js → chunk-ZVBXNHFR.js} +4 -4
- package/dist/client-request.js +2 -2
- package/dist/close.js +2 -2
- package/dist/document-signoff.js +2 -2
- package/dist/expense.js +2 -2
- package/dist/findings.js +2 -2
- package/dist/fixed-assets.js +3 -3
- package/dist/funnel.js +2 -2
- package/dist/fx.js +3 -3
- package/dist/index.js +30 -30
- package/dist/invoice.js +2 -2
- package/dist/ledger.js +3 -3
- package/dist/locale/index.js +2 -2
- package/dist/messages.js +2 -2
- package/dist/money.js +2 -2
- package/dist/msg.d.ts +9 -1
- package/dist/msg.js +1 -1
- package/dist/payment-batch.js +2 -2
- package/dist/period-lock.js +3 -3
- package/dist/period.js +2 -2
- package/dist/permissions.js +2 -2
- package/dist/pipeline.js +2 -2
- package/dist/reconciliation.js +2 -2
- package/dist/recurring.js +2 -2
- package/dist/server.js +16 -16
- package/dist/supplier-invoice.js +2 -2
- package/dist/table.js +2 -2
- package/dist/vat-return.js +3 -3
- package/dist/voucher.js +6 -6
- package/package.json +1 -1
- /package/dist/{chunk-SBWIM62T.js.map → chunk-4FRT7XRX.js.map} +0 -0
- /package/dist/{chunk-SPA45TN5.js.map → chunk-5YV57WVB.js.map} +0 -0
- /package/dist/{chunk-DT3HAYKU.js.map → chunk-62QTK3RO.js.map} +0 -0
- /package/dist/{chunk-PG6CC27E.js.map → chunk-6IVK3UQA.js.map} +0 -0
- /package/dist/{chunk-PL2ZRRTV.js.map → chunk-6SFOABFT.js.map} +0 -0
- /package/dist/{chunk-LVKCG5WR.js.map → chunk-B45JAHB5.js.map} +0 -0
- /package/dist/{chunk-YUPCBRRP.js.map → chunk-BIFYH2Y6.js.map} +0 -0
- /package/dist/{chunk-TYL4PAUC.js.map → chunk-BUMQBGO3.js.map} +0 -0
- /package/dist/{chunk-33O2OHL6.js.map → chunk-CBOKL727.js.map} +0 -0
- /package/dist/{chunk-AK5V6MNR.js.map → chunk-D7CU3G3K.js.map} +0 -0
- /package/dist/{chunk-A2QYZDOI.js.map → chunk-EOY5C5DL.js.map} +0 -0
- /package/dist/{chunk-YGHY2MVR.js.map → chunk-HCMLRRN4.js.map} +0 -0
- /package/dist/{chunk-PLYGQ63I.js.map → chunk-JMOLS4U5.js.map} +0 -0
- /package/dist/{chunk-FWZPV7NF.js.map → chunk-KAFDCP6S.js.map} +0 -0
- /package/dist/{chunk-HCJY7UL5.js.map → chunk-KDCB6RKO.js.map} +0 -0
- /package/dist/{chunk-I5SGNZIS.js.map → chunk-KMXOHG6A.js.map} +0 -0
- /package/dist/{chunk-LR4X7GTZ.js.map → chunk-KXYJZ6HG.js.map} +0 -0
- /package/dist/{chunk-2HIQCBZT.js.map → chunk-MN3MBEQ7.js.map} +0 -0
- /package/dist/{chunk-UFGTZK2J.js.map → chunk-OKVUS75Z.js.map} +0 -0
- /package/dist/{chunk-ZFWPR3SQ.js.map → chunk-SRVXIZKH.js.map} +0 -0
- /package/dist/{chunk-64OXR7M2.js.map → chunk-TTD6VZNY.js.map} +0 -0
- /package/dist/{chunk-XSBPSQMB.js.map → chunk-U2M6WCUI.js.map} +0 -0
- /package/dist/{chunk-GGK3KTR6.js.map → chunk-V5DTXL3H.js.map} +0 -0
- /package/dist/{chunk-VMDKFRLL.js.map → chunk-VCBYT2E7.js.map} +0 -0
- /package/dist/{chunk-GH6FRLYM.js.map → chunk-VOA56E4X.js.map} +0 -0
- /package/dist/{chunk-GSDFDZPH.js.map → chunk-XDAXPC27.js.map} +0 -0
- /package/dist/{chunk-HTILL5EQ.js.map → chunk-XKUL5BDJ.js.map} +0 -0
- /package/dist/{chunk-4F5QLWKQ.js.map → chunk-ZVBXNHFR.js.map} +0 -0
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,25 @@
|
|
|
1
1
|
# @booki/core
|
|
2
2
|
|
|
3
|
+
## 0.3.2
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [#129](https://github.com/Walgermo/booki/pull/129) [`a6462a0`](https://github.com/Walgermo/booki/commit/a6462a086d56505249a3d6fa8481aa8f6dcd04b8) Thanks [@Walgermo](https://github.com/Walgermo)! - With `language: "nb"`, the bridge's own step refusals from ui-sdk now come back in Norwegian too: "… har ingenting å trykke på nå.", "… tar ikke … nå. Den tar: …" and the sentence on what `press` takes. The refusal for an account number with other characters than digits now reads "can only hold digits" ("kan bare inneholde sifre").
|
|
8
|
+
|
|
9
|
+
## 0.3.1
|
|
10
|
+
|
|
11
|
+
### Patch Changes
|
|
12
|
+
|
|
13
|
+
- [#127](https://github.com/Walgermo/booki/pull/127) [`536a34a`](https://github.com/Walgermo/booki/commit/536a34a8fb35f575862ec5cfee06fe74000dac75) Thanks [@Walgermo](https://github.com/Walgermo)! - `useBookiField`: `expect` now works on every kind. Each snapshot holds `value` beside its own key (`minor`, `code`, `account`, `date`), and `expect` compares `value`, so `expect` after `setAccount("2400")` passes instead of reading null. An amount's `value` and `minor` are both integer minor units.
|
|
14
|
+
|
|
15
|
+
With `language: "nb"`, a failed multi-step `act` now ends in Norwegian: "Stegene før dette er utført." and "Send det på nytt med …" replace the English "The steps before this one stay done." and "Send it again with …". This holds when the failing step's own sentence ends in a list ("Its labels: …", "Buttons: …") or is one the catalogue does not know.
|
|
16
|
+
|
|
17
|
+
`useBookiField` with `group: false` no longer puts `aria-label` on the root, so `getByLabelText("Your label")` finds the input alone and your visible `<label>` is the only accessible name. The agent still reads the same label, from a `hidden` element inside the root, which is not shown or read aloud with or without `@booki-aui/styles`. If you query that text with `getByText`, it now matches two elements: use `getByLabelText(label)` or `getByText(label, { selector: "label" })`.
|
|
18
|
+
|
|
19
|
+
`useBookiField`: `value` is now in each kind's `controlled`, so when your `onValueChange` refuses a change on a field you do not update, the agent's `setAccount`, `setCode`, `setDate` or `setMinor` now fails with "didn't take: it is still …" instead of reporting ok.
|
|
20
|
+
|
|
21
|
+
Docs: render the product's own input inside `useBookiField`, never one that is on the bridge such as ui-sdk's `Input`, or the field appears twice.
|
|
22
|
+
|
|
3
23
|
## 0.3.0
|
|
4
24
|
|
|
5
25
|
### Minor Changes
|
package/dist/activity.js
CHANGED
package/dist/aging.js
CHANGED
package/dist/approval.js
CHANGED
package/dist/attachments.js
CHANGED
|
@@ -9,8 +9,8 @@ import {
|
|
|
9
9
|
removeAttachment,
|
|
10
10
|
setAttachmentKind,
|
|
11
11
|
validateAttachmentFile
|
|
12
|
-
} from "./chunk-
|
|
13
|
-
import "./chunk-
|
|
12
|
+
} from "./chunk-KXYJZ6HG.js";
|
|
13
|
+
import "./chunk-EGUAYFGH.js";
|
|
14
14
|
export {
|
|
15
15
|
ATTACHMENT_KINDS,
|
|
16
16
|
assertEvidenced,
|
package/dist/audit.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import {
|
|
2
2
|
BookiError,
|
|
3
3
|
msg
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-EGUAYFGH.js";
|
|
5
5
|
|
|
6
6
|
// src/permissions.ts
|
|
7
7
|
var PERMISSIONS = [
|
|
@@ -175,4 +175,4 @@ export {
|
|
|
175
175
|
can,
|
|
176
176
|
assertCan
|
|
177
177
|
};
|
|
178
|
-
//# sourceMappingURL=chunk-
|
|
178
|
+
//# sourceMappingURL=chunk-4FRT7XRX.js.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import {
|
|
2
2
|
BookiError,
|
|
3
3
|
msg
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-EGUAYFGH.js";
|
|
5
5
|
|
|
6
6
|
// src/close.ts
|
|
7
7
|
var finished = (task) => task.status !== "open";
|
|
@@ -119,4 +119,4 @@ export {
|
|
|
119
119
|
summarizeClose,
|
|
120
120
|
assertReadyToClose
|
|
121
121
|
};
|
|
122
|
-
//# sourceMappingURL=chunk-
|
|
122
|
+
//# sourceMappingURL=chunk-5YV57WVB.js.map
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import {
|
|
2
2
|
minorDigitsFor
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-BUMQBGO3.js";
|
|
4
4
|
import {
|
|
5
5
|
BookiError
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-EGUAYFGH.js";
|
|
7
7
|
|
|
8
8
|
// src/fx.ts
|
|
9
9
|
var RATE_SCALE = 1e6;
|
|
@@ -94,4 +94,4 @@ export {
|
|
|
94
94
|
assertForeignAmount,
|
|
95
95
|
revalue
|
|
96
96
|
};
|
|
97
|
-
//# sourceMappingURL=chunk-
|
|
97
|
+
//# sourceMappingURL=chunk-62QTK3RO.js.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import {
|
|
2
2
|
BookiError,
|
|
3
3
|
msg
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-EGUAYFGH.js";
|
|
5
5
|
|
|
6
6
|
// src/reconciliation.ts
|
|
7
7
|
var live = (match) => match.status !== "rejected";
|
|
@@ -119,4 +119,4 @@ export {
|
|
|
119
119
|
assertReconciled,
|
|
120
120
|
suggestMatches
|
|
121
121
|
};
|
|
122
|
-
//# sourceMappingURL=chunk-
|
|
122
|
+
//# sourceMappingURL=chunk-6IVK3UQA.js.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import {
|
|
2
2
|
BookiError,
|
|
3
3
|
msg
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-EGUAYFGH.js";
|
|
5
5
|
|
|
6
6
|
// src/activity.ts
|
|
7
7
|
var ACTIVITY_KINDS = ["call", "email", "meeting", "note", "task"];
|
|
@@ -136,4 +136,4 @@ export {
|
|
|
136
136
|
activityIssues,
|
|
137
137
|
findActivity
|
|
138
138
|
};
|
|
139
|
-
//# sourceMappingURL=chunk-
|
|
139
|
+
//# sourceMappingURL=chunk-6SFOABFT.js.map
|
|
@@ -3,11 +3,11 @@ import {
|
|
|
3
3
|
} from "./chunk-ICBA5A2V.js";
|
|
4
4
|
import {
|
|
5
5
|
periodBounds
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-JMOLS4U5.js";
|
|
7
7
|
import {
|
|
8
8
|
BookiError,
|
|
9
9
|
msg
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-EGUAYFGH.js";
|
|
11
11
|
|
|
12
12
|
// src/ledger.ts
|
|
13
13
|
function checkRange(range = {}) {
|
|
@@ -260,4 +260,4 @@ export {
|
|
|
260
260
|
accountLedger,
|
|
261
261
|
explainVariance
|
|
262
262
|
};
|
|
263
|
-
//# sourceMappingURL=chunk-
|
|
263
|
+
//# sourceMappingURL=chunk-B45JAHB5.js.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import {
|
|
2
2
|
BookiError,
|
|
3
3
|
msg
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-EGUAYFGH.js";
|
|
5
5
|
|
|
6
6
|
// src/client-request.ts
|
|
7
7
|
var CLIENT_REQUEST_STATUSES = [
|
|
@@ -153,4 +153,4 @@ export {
|
|
|
153
153
|
assertAnswered,
|
|
154
154
|
redactRequest
|
|
155
155
|
};
|
|
156
|
-
//# sourceMappingURL=chunk-
|
|
156
|
+
//# sourceMappingURL=chunk-BIFYH2Y6.js.map
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
BookiError
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-EGUAYFGH.js";
|
|
4
4
|
|
|
5
5
|
// src/money.ts
|
|
6
6
|
var MINOR_DIGITS = {
|
|
@@ -274,4 +274,4 @@ export {
|
|
|
274
274
|
parseToMinor,
|
|
275
275
|
parseToMoney
|
|
276
276
|
};
|
|
277
|
-
//# sourceMappingURL=chunk-
|
|
277
|
+
//# sourceMappingURL=chunk-BUMQBGO3.js.map
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
BookiError
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-EGUAYFGH.js";
|
|
4
4
|
|
|
5
5
|
// src/locale/profiles.ts
|
|
6
6
|
var NO_PROFILE = {
|
|
@@ -385,4 +385,4 @@ export {
|
|
|
385
385
|
BOOKI_PROFILES,
|
|
386
386
|
getBookiProfile
|
|
387
387
|
};
|
|
388
|
-
//# sourceMappingURL=chunk-
|
|
388
|
+
//# sourceMappingURL=chunk-CBOKL727.js.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import {
|
|
2
2
|
BookiError,
|
|
3
3
|
msg
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-EGUAYFGH.js";
|
|
5
5
|
|
|
6
6
|
// src/payment-batch.ts
|
|
7
7
|
function batchTotalMinor(batch) {
|
|
@@ -102,4 +102,4 @@ export {
|
|
|
102
102
|
assertReleasable,
|
|
103
103
|
releaseBatch
|
|
104
104
|
};
|
|
105
|
-
//# sourceMappingURL=chunk-
|
|
105
|
+
//# sourceMappingURL=chunk-D7CU3G3K.js.map
|
|
@@ -449,7 +449,7 @@ var EN = {
|
|
|
449
449
|
"field.person-only-code": `"{item}" is a person's choice here. Ask them to pick it themselves.`,
|
|
450
450
|
"field.unknown-code": 'No option "{value}". The options, as value (label): {items}.',
|
|
451
451
|
"field.unknown-code-more": 'No option "{value}" among the {count}. Closest: {items}. query({ within, text }) finds one by code or whole word.',
|
|
452
|
-
"field.account-not-digits": 'Account number "{value}"
|
|
452
|
+
"field.account-not-digits": 'Account number "{value}" can only hold digits. Send digits only, with no letters or separators.',
|
|
453
453
|
"field.account-empty": "An account number is needed here: {min} to {max} digits.",
|
|
454
454
|
"field.account-empty-chart": "An account number is needed here: pick one of the {count} accounts in the chart.",
|
|
455
455
|
"field.account-not-text": 'setAccount takes the account number as digits, like "4711". Got {got}.',
|
|
@@ -607,6 +607,11 @@ var EN = {
|
|
|
607
607
|
"bridge.no-button": 'No button "{text}" in {ref}. Buttons: {buttons}.',
|
|
608
608
|
"bridge.button-disabled": '"{button}" in {ref} is disabled now.',
|
|
609
609
|
"bridge.disabled": "{component} {ref} is disabled now.",
|
|
610
|
+
"bridge.nothing-to-press": "{component} {ref} has nothing to press now.",
|
|
611
|
+
"bridge.takes-no": "{component} {ref} takes no {action} now. It takes: {actions}.",
|
|
612
|
+
"bridge.takes-no-nothing": "{component} {ref} takes no {action} now. It takes: nothing.",
|
|
613
|
+
"bridge.press-takes-buttons": "press takes a button's text: {buttons}.",
|
|
614
|
+
"bridge.press-opens": "press takes the text of a button inside it, and opens it first to find the button.",
|
|
610
615
|
"bridge.no-item": 'No item "{item}" in {name}. Its items: {items}.',
|
|
611
616
|
"bridge.needs-ref": "A step needs a ref: a component's ref from snapshot, or its label.",
|
|
612
617
|
"bridge.needs-action": 'A step on "{ref}" needs an action, like "press".',
|
|
@@ -629,7 +634,10 @@ var EN = {
|
|
|
629
634
|
"bridge.act-extra": 'act takes "steps" and nothing else, not "{key}". No step ran.',
|
|
630
635
|
"bridge.step-needs-ref": "{at} needs a ref: a component's ref from snapshot, or its label. No step ran.",
|
|
631
636
|
"bridge.step-needs-action": '{at}, on "{ref}", needs an action, like "press". No step ran.',
|
|
632
|
-
"bridge.step-needs-value": '{action} on "{ref}" needs its value, as "args": [value]. No step ran.'
|
|
637
|
+
"bridge.step-needs-value": '{action} on "{ref}" needs its value, as "args": [value]. No step ran.',
|
|
638
|
+
"bridge.steps-stay-done": "The steps before this one stay done.",
|
|
639
|
+
"bridge.send-again-one": "Send it again with the step after it, {total} steps in one call.",
|
|
640
|
+
"bridge.send-again-many": "Send it again with the {rest} steps after it, {total} steps in one call."
|
|
633
641
|
};
|
|
634
642
|
|
|
635
643
|
// src/msg.ts
|
|
@@ -686,4 +694,4 @@ export {
|
|
|
686
694
|
BookiError,
|
|
687
695
|
isBookiError
|
|
688
696
|
};
|
|
689
|
-
//# sourceMappingURL=chunk-
|
|
697
|
+
//# sourceMappingURL=chunk-EGUAYFGH.js.map
|