@domandigital/craft 0.19.2 → 0.19.3
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 +6 -0
- package/dist/{chunk-ZKZCPVQ6.js → chunk-6M2LK7QE.js} +2 -2
- package/dist/{chunk-D2PEKYKH.js → chunk-BK4AS2RU.js} +9 -9
- package/dist/{chunk-EDM4L5WJ.js → chunk-D2FTTM4F.js} +1 -1
- package/dist/{chunk-EKGHL4D2.js → chunk-XVMKZ4SM.js} +2 -2
- package/dist/{cli-OS5ESEJV.js → cli-4LEAEOOV.js} +4 -4
- package/dist/{cli-RAH4CKYY.js → cli-6LCOSHMW.js} +3 -3
- package/dist/{cli-BZSJIUQH.js → cli-APYEOHFV.js} +1 -1
- package/dist/{cli-VLNOQYEL.js → cli-Q5X3W6I4.js} +2 -2
- package/dist/{cli-T3IA7IQK.js → cli-QAYH2OX5.js} +3 -3
- package/dist/{cli-GUEBFFF3.js → cli-TMLHMNWU.js} +2 -2
- package/dist/{cli-KTN5OXHZ.js → cli-WN2GHYPF.js} +3 -3
- package/dist/cli.js +1 -1
- package/dist/phone.cjs +2 -2
- package/dist/phone.js +2 -2
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,11 @@
|
|
|
1
1
|
# @domandigital/craft
|
|
2
2
|
|
|
3
|
+
## 0.19.3
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- 95af0f3: `craft phone-first` folds digits only in an element's text, so `<h1>` stays `<h1>` in a baseline, and says how many of a breach it found ("3 of them", "2 found, the baseline allows 1") (DOM-775).
|
|
8
|
+
|
|
3
9
|
## 0.19.2
|
|
4
10
|
|
|
5
11
|
### Patch Changes
|
|
@@ -7,10 +7,10 @@ import {
|
|
|
7
7
|
} from "./chunk-4LJFZH2I.js";
|
|
8
8
|
import {
|
|
9
9
|
loadNull
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-D2FTTM4F.js";
|
|
11
11
|
import {
|
|
12
12
|
parseFlags
|
|
13
|
-
} from "./chunk-
|
|
13
|
+
} from "./chunk-BK4AS2RU.js";
|
|
14
14
|
import {
|
|
15
15
|
toJson
|
|
16
16
|
} from "./chunk-QIEDBL4J.js";
|
|
@@ -621,7 +621,7 @@ async function briefFor(flags, cwd) {
|
|
|
621
621
|
if (typeof brief === "string" && brief.trim()) return brief;
|
|
622
622
|
} else if (flags.direction) throw new Error(`no such file: ${flags.direction}`);
|
|
623
623
|
if (flags.null) {
|
|
624
|
-
const { loadNull } = await import("./cli-
|
|
624
|
+
const { loadNull } = await import("./cli-TMLHMNWU.js");
|
|
625
625
|
return loadNull(flags.null, cwd).brief;
|
|
626
626
|
}
|
|
627
627
|
return void 0;
|
|
@@ -647,34 +647,34 @@ async function compareWithCompetitor(flags, io) {
|
|
|
647
647
|
function run(argv, io) {
|
|
648
648
|
const [command, ...rest] = argv;
|
|
649
649
|
if (command === "direction") {
|
|
650
|
-
return import("./cli-
|
|
650
|
+
return import("./cli-APYEOHFV.js").then((m) => m.runDirection(rest, io));
|
|
651
651
|
}
|
|
652
652
|
if (command === "report" || command === "retrofit") {
|
|
653
|
-
return import("./cli-
|
|
653
|
+
return import("./cli-4LEAEOOV.js").then((m) => m.runReport(command, rest, io));
|
|
654
654
|
}
|
|
655
655
|
if (command === "register") {
|
|
656
656
|
return import("./cli-VPARW6FY.js").then((m) => m.runRegister(rest, io));
|
|
657
657
|
}
|
|
658
658
|
if (command === "estate") {
|
|
659
|
-
return import("./cli-
|
|
659
|
+
return import("./cli-QAYH2OX5.js").then((m) => m.runEstate(rest, io));
|
|
660
660
|
}
|
|
661
661
|
if (command === "null") {
|
|
662
|
-
return import("./cli-
|
|
662
|
+
return import("./cli-TMLHMNWU.js").then((m) => m.runNull(rest, io));
|
|
663
663
|
}
|
|
664
664
|
if (command === "calibrate") {
|
|
665
|
-
return import("./cli-
|
|
665
|
+
return import("./cli-Q5X3W6I4.js").then((m) => m.runCalibrate(rest, io));
|
|
666
666
|
}
|
|
667
667
|
if (command === "tells" && rest[0] === "harvest") {
|
|
668
|
-
return import("./cli-
|
|
668
|
+
return import("./cli-TMLHMNWU.js").then((m) => m.runHarvest(rest, io)).catch((error) => {
|
|
669
669
|
io.err(`craft: ${error.message}`);
|
|
670
670
|
return 2;
|
|
671
671
|
});
|
|
672
672
|
}
|
|
673
673
|
if (command === "phone-first") {
|
|
674
|
-
return import("./cli-
|
|
674
|
+
return import("./cli-6LCOSHMW.js").then((m) => m.runPhoneFirst(rest, io));
|
|
675
675
|
}
|
|
676
676
|
if (command === "snapshot" || command === "audit") {
|
|
677
|
-
return import("./cli-
|
|
677
|
+
return import("./cli-WN2GHYPF.js").then((m) => m.runAudit(command, rest, io));
|
|
678
678
|
}
|
|
679
679
|
if (!command || command === "help" || command === "--help" || command === "-h") {
|
|
680
680
|
io.out(HELP);
|
|
@@ -5,7 +5,7 @@ import {
|
|
|
5
5
|
import {
|
|
6
6
|
describeTypicality,
|
|
7
7
|
loadNull
|
|
8
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-D2FTTM4F.js";
|
|
9
9
|
import {
|
|
10
10
|
SOURCE_FILE,
|
|
11
11
|
finish,
|
|
@@ -14,7 +14,7 @@ import {
|
|
|
14
14
|
parseFlags,
|
|
15
15
|
prepareReport,
|
|
16
16
|
readPaths
|
|
17
|
-
} from "./chunk-
|
|
17
|
+
} from "./chunk-BK4AS2RU.js";
|
|
18
18
|
import {
|
|
19
19
|
toJson
|
|
20
20
|
} from "./chunk-QIEDBL4J.js";
|
|
@@ -3,21 +3,21 @@ import {
|
|
|
3
3
|
} from "./chunk-OKVHWXYV.js";
|
|
4
4
|
import {
|
|
5
5
|
merge
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-XVMKZ4SM.js";
|
|
7
7
|
import "./chunk-VDUIIWG7.js";
|
|
8
8
|
import "./chunk-JYNXGCYZ.js";
|
|
9
9
|
import {
|
|
10
10
|
SIBLING_AT,
|
|
11
11
|
compareToEstate,
|
|
12
12
|
loadEstate
|
|
13
|
-
} from "./chunk-
|
|
13
|
+
} from "./chunk-6M2LK7QE.js";
|
|
14
14
|
import {
|
|
15
15
|
PAGE_TYPES,
|
|
16
16
|
validateDirection
|
|
17
17
|
} from "./chunk-4LJFZH2I.js";
|
|
18
18
|
import {
|
|
19
19
|
loadNull
|
|
20
|
-
} from "./chunk-
|
|
20
|
+
} from "./chunk-D2FTTM4F.js";
|
|
21
21
|
import "./chunk-OQXTQQAU.js";
|
|
22
22
|
import {
|
|
23
23
|
COPY_FILE,
|
|
@@ -28,7 +28,7 @@ import {
|
|
|
28
28
|
loadExceptions,
|
|
29
29
|
parseFlags,
|
|
30
30
|
readPaths
|
|
31
|
-
} from "./chunk-
|
|
31
|
+
} from "./chunk-BK4AS2RU.js";
|
|
32
32
|
import {
|
|
33
33
|
toJson
|
|
34
34
|
} from "./chunk-QIEDBL4J.js";
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import {
|
|
2
2
|
SOURCE_FILE,
|
|
3
3
|
readPaths
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-BK4AS2RU.js";
|
|
5
5
|
import {
|
|
6
6
|
toJson
|
|
7
7
|
} from "./chunk-QIEDBL4J.js";
|
|
@@ -62,7 +62,7 @@ function checkExceptions(exceptions, exists) {
|
|
|
62
62
|
});
|
|
63
63
|
return problems;
|
|
64
64
|
}
|
|
65
|
-
var normaliseElement = (element) => element.replace(/\d+/g, "#");
|
|
65
|
+
var normaliseElement = (element) => element.replace(/("[^]*)$/, (text) => text.replace(/\d+/g, "#"));
|
|
66
66
|
var tally = (items, key) => {
|
|
67
67
|
const m = /* @__PURE__ */ new Map();
|
|
68
68
|
for (const item of items) {
|
|
@@ -110,7 +110,7 @@ function judgeMeasured(routes, baseline) {
|
|
|
110
110
|
const allow = allowed.get(key) ?? 0;
|
|
111
111
|
known += Math.min(count, allow);
|
|
112
112
|
if (count > allow) {
|
|
113
|
-
const times =
|
|
113
|
+
const times = allow ? ` (${count} found, the baseline allows ${allow})` : count > 1 ? ` (${count} of them)` : "";
|
|
114
114
|
fresh.push(`${route}: ${LABEL[item.check]} ${item.element}: ${item.detail}${times}`);
|
|
115
115
|
}
|
|
116
116
|
}
|
|
@@ -4,11 +4,11 @@ import {
|
|
|
4
4
|
import {
|
|
5
5
|
expandNullTargets,
|
|
6
6
|
loadNull
|
|
7
|
-
} from "./chunk-
|
|
7
|
+
} from "./chunk-D2FTTM4F.js";
|
|
8
8
|
import "./chunk-OQXTQQAU.js";
|
|
9
9
|
import {
|
|
10
10
|
parseFlags
|
|
11
|
-
} from "./chunk-
|
|
11
|
+
} from "./chunk-BK4AS2RU.js";
|
|
12
12
|
import {
|
|
13
13
|
toJson
|
|
14
14
|
} from "./chunk-QIEDBL4J.js";
|
|
@@ -4,11 +4,11 @@ import {
|
|
|
4
4
|
formatPairs,
|
|
5
5
|
loadEstate,
|
|
6
6
|
runEstate
|
|
7
|
-
} from "./chunk-
|
|
7
|
+
} from "./chunk-6M2LK7QE.js";
|
|
8
8
|
import "./chunk-4LJFZH2I.js";
|
|
9
|
-
import "./chunk-
|
|
9
|
+
import "./chunk-D2FTTM4F.js";
|
|
10
10
|
import "./chunk-OQXTQQAU.js";
|
|
11
|
-
import "./chunk-
|
|
11
|
+
import "./chunk-BK4AS2RU.js";
|
|
12
12
|
import "./chunk-QIEDBL4J.js";
|
|
13
13
|
import "./chunk-WUACK2HX.js";
|
|
14
14
|
import "./chunk-WK2WMWTH.js";
|
|
@@ -9,9 +9,9 @@ import {
|
|
|
9
9
|
runHarvest,
|
|
10
10
|
runNull,
|
|
11
11
|
serveDir
|
|
12
|
-
} from "./chunk-
|
|
12
|
+
} from "./chunk-D2FTTM4F.js";
|
|
13
13
|
import "./chunk-OQXTQQAU.js";
|
|
14
|
-
import "./chunk-
|
|
14
|
+
import "./chunk-BK4AS2RU.js";
|
|
15
15
|
import "./chunk-QIEDBL4J.js";
|
|
16
16
|
import "./chunk-WUACK2HX.js";
|
|
17
17
|
import "./chunk-WK2WMWTH.js";
|
|
@@ -4,12 +4,12 @@ import {
|
|
|
4
4
|
merge,
|
|
5
5
|
resolvePages,
|
|
6
6
|
runAudit
|
|
7
|
-
} from "./chunk-
|
|
7
|
+
} from "./chunk-XVMKZ4SM.js";
|
|
8
8
|
import "./chunk-VDUIIWG7.js";
|
|
9
9
|
import "./chunk-JYNXGCYZ.js";
|
|
10
|
-
import "./chunk-
|
|
10
|
+
import "./chunk-D2FTTM4F.js";
|
|
11
11
|
import "./chunk-OQXTQQAU.js";
|
|
12
|
-
import "./chunk-
|
|
12
|
+
import "./chunk-BK4AS2RU.js";
|
|
13
13
|
import "./chunk-QIEDBL4J.js";
|
|
14
14
|
import "./chunk-WUACK2HX.js";
|
|
15
15
|
import "./chunk-WK2WMWTH.js";
|
package/dist/cli.js
CHANGED
package/dist/phone.cjs
CHANGED
|
@@ -149,7 +149,7 @@ function checkExceptions(exceptions, exists) {
|
|
|
149
149
|
});
|
|
150
150
|
return problems;
|
|
151
151
|
}
|
|
152
|
-
var normaliseElement = (element) => element.replace(/\d+/g, "#");
|
|
152
|
+
var normaliseElement = (element) => element.replace(/("[^]*)$/, (text) => text.replace(/\d+/g, "#"));
|
|
153
153
|
var tally = (items, key) => {
|
|
154
154
|
const m = /* @__PURE__ */ new Map();
|
|
155
155
|
for (const item of items) {
|
|
@@ -197,7 +197,7 @@ function judgeMeasured(routes, baseline) {
|
|
|
197
197
|
const allow = allowed.get(key) ?? 0;
|
|
198
198
|
known += Math.min(count, allow);
|
|
199
199
|
if (count > allow) {
|
|
200
|
-
const times =
|
|
200
|
+
const times = allow ? ` (${count} found, the baseline allows ${allow})` : count > 1 ? ` (${count} of them)` : "";
|
|
201
201
|
fresh.push(`${route}: ${LABEL[item.check]} ${item.element}: ${item.detail}${times}`);
|
|
202
202
|
}
|
|
203
203
|
}
|
package/dist/phone.js
CHANGED
|
@@ -112,7 +112,7 @@ function checkExceptions(exceptions, exists) {
|
|
|
112
112
|
});
|
|
113
113
|
return problems;
|
|
114
114
|
}
|
|
115
|
-
var normaliseElement = (element) => element.replace(/\d+/g, "#");
|
|
115
|
+
var normaliseElement = (element) => element.replace(/("[^]*)$/, (text) => text.replace(/\d+/g, "#"));
|
|
116
116
|
var tally = (items, key) => {
|
|
117
117
|
const m = /* @__PURE__ */ new Map();
|
|
118
118
|
for (const item of items) {
|
|
@@ -160,7 +160,7 @@ function judgeMeasured(routes, baseline) {
|
|
|
160
160
|
const allow = allowed.get(key) ?? 0;
|
|
161
161
|
known += Math.min(count, allow);
|
|
162
162
|
if (count > allow) {
|
|
163
|
-
const times =
|
|
163
|
+
const times = allow ? ` (${count} found, the baseline allows ${allow})` : count > 1 ? ` (${count} of them)` : "";
|
|
164
164
|
fresh.push(`${route}: ${LABEL[item.check]} ${item.element}: ${item.detail}${times}`);
|
|
165
165
|
}
|
|
166
166
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@domandigital/craft",
|
|
3
|
-
"version": "0.19.
|
|
3
|
+
"version": "0.19.3",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "The Doman Digital house craft standard as numbers: OKLCh colour ramps that snap to existing anchors, derived semantic tokens with measured WCAG and APCA contrast, one shared motion vocabulary for CSS and JS, and a base stylesheet. Zero dependencies.",
|
|
6
6
|
"license": "Apache-2.0",
|