@maple-kit/lint 0.1.1 → 0.1.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/README.md +27 -3
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -1,7 +1,27 @@
|
|
|
1
1
|
# @maple-kit/lint
|
|
2
2
|
|
|
3
|
-
Design-system lint for Maple. This
|
|
4
|
-
that need a browser to have laid
|
|
3
|
+
Design-system lint for [Maple](https://github.com/maple-kit/maple). This
|
|
4
|
+
package is the **rendered tier**: the rules that need a browser to have laid
|
|
5
|
+
the page out before they can judge it.
|
|
6
|
+
|
|
7
|
+
**Pre-release.** Every package here is 0.x and makes no compatibility promise.
|
|
8
|
+
|
|
9
|
+
<p align="center">
|
|
10
|
+
<img src="https://raw.githubusercontent.com/maple-kit/maple/main/docs/assets/features/design-lint.gif" alt="A preview is scanned and each design rule lands as a tick or a cross, with a raw colour and a small touch target ringed on the page. Below, the pull request's maple/design-lint check fails and the merge is blocked." width="480">
|
|
11
|
+
</p>
|
|
12
|
+
|
|
13
|
+
The rendered rules run today. The `maple/design-lint` check that holds the
|
|
14
|
+
merge, shown at the end of the clip, is in progress.
|
|
15
|
+
|
|
16
|
+
## Install
|
|
17
|
+
|
|
18
|
+
```sh
|
|
19
|
+
npm install @maple-kit/lint playwright
|
|
20
|
+
```
|
|
21
|
+
|
|
22
|
+
`playwright` is a peer: a run drives your browser, not one this package ships.
|
|
23
|
+
|
|
24
|
+
## Use
|
|
5
25
|
|
|
6
26
|
A static linter reads the source. A rendered rule reads what the cascade, the
|
|
7
27
|
theme and the media query finally produced, which is where an off-token colour
|
|
@@ -33,7 +53,7 @@ comment does. `findingComment(finding, { branch, context })` turns one into a
|
|
|
33
53
|
| `maple/rendered-motion-property` | Motion on anything but `opacity` and `transform`. |
|
|
34
54
|
| `maple/rendered-reduced-motion` | Motion that survives `prefers-reduced-motion`. |
|
|
35
55
|
|
|
36
|
-
[docs/lint.md](
|
|
56
|
+
[docs/lint.md](https://github.com/maple-kit/maple/blob/main/docs/lint.md) covers each of them and the tiers around this
|
|
37
57
|
one.
|
|
38
58
|
|
|
39
59
|
## What it cannot read
|
|
@@ -48,3 +68,7 @@ did not fully check.
|
|
|
48
68
|
A run sends the preview platform's bypass as request headers and nothing else.
|
|
49
69
|
Reviewer cookies are never used: CI's lint run does not borrow a person's
|
|
50
70
|
session to see a page.
|
|
71
|
+
|
|
72
|
+
## Licence
|
|
73
|
+
|
|
74
|
+
Apache-2.0. See `LICENSE` and `NOTICE`.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@maple-kit/lint",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.3",
|
|
4
4
|
"description": "Design-system lint for Maple: rendered-tier rules over a live preview",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"type": "module",
|
|
@@ -25,7 +25,7 @@
|
|
|
25
25
|
"./package.json": "./package.json"
|
|
26
26
|
},
|
|
27
27
|
"dependencies": {
|
|
28
|
-
"@maple-kit/core": "0.
|
|
28
|
+
"@maple-kit/core": "0.12.1"
|
|
29
29
|
},
|
|
30
30
|
"peerDependencies": {
|
|
31
31
|
"playwright": "^1.50.0"
|