@markuplint/config-presets 3.0.0-dev.54 → 3.0.0-dev.96
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 +4 -2
- package/package.json +2 -2
- package/preset.a11y.json +1 -1
- package/preset.html-standard.json +1 -1
package/README.md
CHANGED
|
@@ -24,9 +24,8 @@ You can choose some presets appropriately for your preference.
|
|
|
24
24
|
|
|
25
25
|
Ruleset|Description|`recommended`|`recommended-vue`|`recommended-svelte`|`recommended-static-html`|`recommended-react`|`a11y`|`code-styles`|`html-standard`|`performance`|`rdfa`|`security`|
|
|
26
26
|
---|---|---|---|---|---|---|---|---|---|---|---|---|
|
|
27
|
-
[Disallow `<hgroup>`](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/hgroup)|The hgroup element should not be used because no assistive technology supports it.|✅|✅|✅|✅|✅|✅|❌|❌|❌|❌|❌|
|
|
28
27
|
[Must not duplicate **ID**](https://www.w3.org/WAI/WCAG21/Techniques/html/H93.html)|Be able to avoid problems in assistive technologies from the viewpoint of machine readability.|✅|✅|✅|✅|✅|✅|❌|✅|❌|❌|❌|
|
|
29
|
-
[Disallow `
|
|
28
|
+
[Disallow `accesskey` attr](https://developer.mozilla.org/en-US/docs/Web/HTML/Global_attributes/accesskey#accessibility_concerns)| |✅|✅|✅|✅|✅|✅|❌|❌|❌|❌|❌|
|
|
30
29
|
[`tabindex` attr only `-1` or `0`](https://developer.mozilla.org/en-US/docs/Web/HTML/Global_attributes/tabindex#accessibility_concerns)| |✅|✅|✅|✅|✅|✅|❌|❌|❌|❌|❌|
|
|
31
30
|
`<label>` should have control| |✅|✅|✅|✅|✅|✅|❌|❌|❌|❌|❌|
|
|
32
31
|
[Use **landmark**](https://www.w3.org/TR/wai-aria-practices/examples/landmarks/)| |✅|✅|✅|✅|✅|✅|❌|❌|❌|❌|❌|
|
|
@@ -41,6 +40,7 @@ Require `<track>`| |✅|✅|✅|✅|✅|✅|❌|❌|❌|❌|❌|
|
|
|
41
40
|
Require `<video muted>`| |✅|✅|✅|✅|✅|✅|❌|❌|❌|❌|❌|
|
|
42
41
|
No merge cells| |✅|✅|✅|✅|✅|✅|❌|❌|❌|❌|❌|
|
|
43
42
|
[`<summary>` no contains interactive contents](https://github.com/whatwg/html/issues/2272#issuecomment-1242415594)|There is a case where an assistive technology can't access contents, or contents don't propagate a mouse event to `<summary>`.|✅|✅|✅|✅|✅|✅|❌|❌|❌|❌|❌|
|
|
43
|
+
[Disallow `autofocus` attr to except in the dialog scope](https://developer.mozilla.org/en-US/docs/Web/HTML/Global_attributes/autofocus#accessibility_considerations)|Don't take away a focus to forced. However, the `dialog` element and its descendants allow it.|✅|✅|✅|✅|✅|✅|❌|❌|❌|❌|❌|
|
|
44
44
|
[No duplicate attr](https://html.spec.whatwg.org/multipage/parsing.html#parse-error-duplicate-attribute)|The parser ignores all such duplicate occurrences of the attribute.|✅|✅|✅|✅|✅|❌|❌|✅|❌|❌|❌|
|
|
45
45
|
Use **character reference**| |✅|✅|✅|✅|✅|❌|❌|✅|❌|❌|❌|
|
|
46
46
|
No use deprecated attr|You should not use deprecated attributes from the viewpoint of compatibility.|✅|✅|✅|✅|✅|❌|❌|✅|❌|❌|❌|
|
|
@@ -48,6 +48,8 @@ No use deprecated element|You should not use deprecated elements from the viewpo
|
|
|
48
48
|
[Require `doctype`](https://html.spec.whatwg.org/multipage/syntax.html#syntax-doctype)|It has the effect of avoiding quirks mode.|✅|✅|✅|✅|✅|❌|❌|✅|❌|❌|❌|
|
|
49
49
|
No use ineffective attr| |✅|✅|✅|✅|✅|❌|❌|✅|❌|❌|❌|
|
|
50
50
|
Allow only **permitted contents**| |✅|✅|✅|✅|✅|❌|❌|✅|❌|❌|❌|
|
|
51
|
+
Need **placeholder label option**| |✅|✅|✅|✅|✅|❌|❌|✅|❌|❌|❌|
|
|
52
|
+
Require the `datetime` attribute if the content of the `time` element is invalid| |✅|✅|✅|✅|✅|❌|❌|✅|❌|❌|❌|
|
|
51
53
|
Specify required attr| |✅|✅|✅|✅|✅|❌|❌|✅|❌|❌|❌|
|
|
52
54
|
[Specify `charset=UTF-8`](https://html.spec.whatwg.org/multipage/semantics.html#charset)| |✅|✅|✅|✅|✅|❌|❌|✅|❌|❌|❌|
|
|
53
55
|
[No use `<small>` as **subheadings**](https://html.spec.whatwg.org/multipage/text-level-semantics.html#the-small-element)|Should not use it in `<h1>`, `<h2>`, `<h3>`, `<h4>`, `<h5>`, and `<h6>`.|✅|✅|✅|✅|✅|❌|❌|✅|❌|❌|❌|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@markuplint/config-presets",
|
|
3
|
-
"version": "3.0.0-dev.
|
|
3
|
+
"version": "3.0.0-dev.96+3b9f1720",
|
|
4
4
|
"description": "markuplint config presets",
|
|
5
5
|
"repository": "git@github.com:markuplint/markuplint.git",
|
|
6
6
|
"author": "Yusuke Hirao <yusukehirao@me.com>",
|
|
@@ -17,5 +17,5 @@
|
|
|
17
17
|
"jsonc-parser": "^3.2.0",
|
|
18
18
|
"mustache": "^4.2.0"
|
|
19
19
|
},
|
|
20
|
-
"gitHead": "
|
|
20
|
+
"gitHead": "3b9f17205d7754b29edf790bdbbf5e4931ba27a2"
|
|
21
21
|
}
|
package/preset.a11y.json
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"rules":{"
|
|
1
|
+
{"rules":{"id-duplication":true,"invalid-attr":{"options":{"attrs":{"autofocus":{"disallowed":true},"accesskey":{"disallowed":true},"tabindex":{"enum":["-1","0"]}}}},"label-has-control":true,"landmark-roles":true,"no-refer-to-non-existent-id":true,"require-accessible-name":true,"required-h1":true,"use-list":true,"wai-aria":true},"nodeRules":[{"selector":":where(html)","rules":{"required-attr":["lang"]}},{"selector":":where(abbr)","rules":{"required-attr":["title"]}},{"selector":":where(video, audio)","rules":{"required-element":["track"]}},{"selector":":where(video[autoplay])","rules":{"required-attr":["muted"]}},{"selector":":where(th, td)","rules":{"invalid-attr":{"options":{"attrs":{"colspan":{"disallowed":true},"rowspan":{"disallowed":true}}}}}},{"selector":":where(summary)","rules":{"disallowed-element":[":model(interactive)"]}}]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"rules":{"attr-duplication":true,"character-reference":true,"deprecated-attr":true,"deprecated-element":true,"doctype":true,"id-duplication":true,"ineffective-attr":true,"no-refer-to-non-existent-id":true,"permitted-contents":true,"required-attr":true},"nodeRules":[{"selector":":where(head)","rules":{"required-element":["meta[charset=\"UTF-8\" i]"]}},{"selector":"h1, h2, h3, h4, h5, h6","rules":{"disallowed-element":{"value":["small"],"reason":"The small element must not be used for subheadings. https://html.spec.whatwg.org/multipage/text-level-semantics.html#the-small-element"}}},{"selector":":where(figcaption ~ table, table:has(~ figcaption))","rules":{"disallowed-element":{"value":["caption"],"reason":"When a table element is the only content in a figure element other than the figcaption, the caption element should be omitted in favor of the figcaption. (https://html.spec.whatwg.org/multipage/tables.html#the-caption-element)"},"require-accessible-name":false}}]}
|
|
1
|
+
{"rules":{"attr-duplication":true,"character-reference":true,"deprecated-attr":true,"deprecated-element":true,"doctype":true,"id-duplication":true,"ineffective-attr":true,"no-refer-to-non-existent-id":true,"permitted-contents":true,"placeholder-label-option":true,"require-datetime":true,"required-attr":true},"nodeRules":[{"selector":":where(head)","rules":{"required-element":["meta[charset=\"UTF-8\" i]"]}},{"selector":"h1, h2, h3, h4, h5, h6","rules":{"disallowed-element":{"value":["small"],"reason":"The small element must not be used for subheadings. https://html.spec.whatwg.org/multipage/text-level-semantics.html#the-small-element"}}},{"selector":":where(figcaption ~ table, table:has(~ figcaption))","rules":{"disallowed-element":{"value":["caption"],"reason":"When a table element is the only content in a figure element other than the figcaption, the caption element should be omitted in favor of the figcaption. (https://html.spec.whatwg.org/multipage/tables.html#the-caption-element)"},"require-accessible-name":false}}]}
|