@tangle-network/brand 1.22.0 → 1.22.1
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/bin/tangle-drift.mjs +4 -2
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,11 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## 1.22.1
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- 07e7a78: tangle-drift ignores CSS comments when counting header_height_literal and transcript_type_override, and no longer counts a step-progress bar (`.steps-bar`) as a header row. UI's RunGroup sets its Markdown with the shared TRANSCRIPT_TEXT instead of a fixed 15px / leading-7, so a run reads at the transcript scale.
|
|
8
|
+
|
|
3
9
|
## 1.22.0
|
|
4
10
|
|
|
5
11
|
### Minor Changes
|
package/bin/tangle-drift.mjs
CHANGED
|
@@ -83,7 +83,7 @@ export const PATTERNS = {
|
|
|
83
83
|
// the selector's last compound (pseudo-classes and attributes aside), so `.top-header .avatar`
|
|
84
84
|
// and `.top-header-avatar` size something inside a header, not the header row.
|
|
85
85
|
// A `-bar` row counts too (`.files-bar`), but not a progress, scroll, side or meter bar.
|
|
86
|
-
const HEADER_WORD = String.raw`(?:header|head|topbar|toolbar|titlebar|appbar|navbar|(?<![\w-]*(?:progress|scroll|side|meter|loading|track|fill|status)-?)bar)`;
|
|
86
|
+
const HEADER_WORD = String.raw`(?:header|head|topbar|toolbar|titlebar|appbar|navbar|(?<![\w-]*(?:progress|scroll|side|meter|loading|track|fill|status|steps?)-?)bar)`;
|
|
87
87
|
const HEADER_COMPOUND = String.raw`(?:[\w#.:-]*[.#-]${HEADER_WORD}|(?<![\w.#-])header)(?![\w-])(?::{1,2}[\w-]+(?:\([^)]*\))?|\[[^\]]*\])*`;
|
|
88
88
|
const LITERAL_HEIGHT_UTILITY = String.raw`(?<![\w-])(?:h|min-h|max-h)-(?:[0-9]|\[(?!var\())`;
|
|
89
89
|
|
|
@@ -199,7 +199,9 @@ export function ruleMatches(source, roots, metric, exts) {
|
|
|
199
199
|
.map((f) => (f.startsWith(prefix) ? f.slice(prefix.length) : f).trim()).filter(Boolean);
|
|
200
200
|
const rows = [];
|
|
201
201
|
for (const path of files) {
|
|
202
|
-
|
|
202
|
+
// Comments name things without styling them (a CSS note that mentions "transcript" or
|
|
203
|
+
// "header"); blank them, keeping offsets and newlines, so only real rules count.
|
|
204
|
+
const text = readFile(source, path).replace(/\/\*[\s\S]*?\*\//g, (comment) => comment.replace(/[^\n]/g, " "));
|
|
203
205
|
const found = new Map();
|
|
204
206
|
for (const pattern of patterns) {
|
|
205
207
|
for (const m of text.matchAll(new RegExp(pattern, "g"))) found.set(m.index, m[0]);
|
package/package.json
CHANGED