@flint.fyi/jsx 0.3.3 → 0.4.0
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/lib/plugin.d.ts +45 -48
- package/lib/plugin.js +0 -2
- package/lib/rules/accessKeys.d.ts +0 -1
- package/lib/rules/accessKeys.js +0 -2
- package/lib/rules/altTexts.d.ts +0 -1
- package/lib/rules/altTexts.js +1 -3
- package/lib/rules/anchorAmbiguousText.d.ts +0 -1
- package/lib/rules/anchorAmbiguousText.js +1 -3
- package/lib/rules/anchorContent.d.ts +0 -1
- package/lib/rules/anchorContent.js +0 -2
- package/lib/rules/anchorValidity.d.ts +0 -1
- package/lib/rules/anchorValidity.js +0 -2
- package/lib/rules/ariaActiveDescendantTabIndex.d.ts +0 -1
- package/lib/rules/ariaActiveDescendantTabIndex.js +1 -3
- package/lib/rules/ariaHiddenFocusables.d.ts +0 -1
- package/lib/rules/ariaHiddenFocusables.js +1 -3
- package/lib/rules/ariaPropTypes.d.ts +0 -1
- package/lib/rules/ariaPropTypes.js +9 -11
- package/lib/rules/ariaProps.d.ts +0 -1
- package/lib/rules/ariaProps.js +1 -3
- package/lib/rules/ariaRoleValidity.d.ts +0 -1
- package/lib/rules/ariaRoleValidity.js +1 -3
- package/lib/rules/ariaUnsupportedElements.d.ts +0 -1
- package/lib/rules/ariaUnsupportedElements.js +1 -3
- package/lib/rules/autoFocusProps.d.ts +0 -1
- package/lib/rules/autoFocusProps.js +0 -2
- package/lib/rules/autocomplete.d.ts +0 -1
- package/lib/rules/autocomplete.js +4 -10
- package/lib/rules/booleanValues.d.ts +0 -1
- package/lib/rules/booleanValues.js +0 -2
- package/lib/rules/bracedStatements.d.ts +0 -1
- package/lib/rules/bracedStatements.js +0 -2
- package/lib/rules/buttonTypes.d.ts +0 -1
- package/lib/rules/buttonTypes.js +5 -13
- package/lib/rules/childrenProps.d.ts +0 -1
- package/lib/rules/childrenProps.js +0 -2
- package/lib/rules/clickEventKeyEvents.d.ts +0 -1
- package/lib/rules/clickEventKeyEvents.js +1 -3
- package/lib/rules/commentTextNodes.d.ts +0 -1
- package/lib/rules/commentTextNodes.js +0 -2
- package/lib/rules/distractingElements.d.ts +0 -1
- package/lib/rules/distractingElements.js +1 -3
- package/lib/rules/elementChildrenValidity.d.ts +0 -1
- package/lib/rules/elementChildrenValidity.js +1 -3
- package/lib/rules/headingContents.d.ts +0 -1
- package/lib/rules/headingContents.js +1 -3
- package/lib/rules/htmlLangs.d.ts +0 -1
- package/lib/rules/htmlLangs.js +0 -2
- package/lib/rules/iframeTitles.d.ts +0 -1
- package/lib/rules/iframeTitles.js +0 -2
- package/lib/rules/interactiveElementRoles.d.ts +0 -1
- package/lib/rules/interactiveElementRoles.js +2 -4
- package/lib/rules/interactiveElementsFocusable.d.ts +0 -1
- package/lib/rules/interactiveElementsFocusable.js +4 -6
- package/lib/rules/labelAssociatedControls.d.ts +0 -1
- package/lib/rules/labelAssociatedControls.js +1 -3
- package/lib/rules/langValidity.d.ts +0 -1
- package/lib/rules/langValidity.js +0 -2
- package/lib/rules/mediaCaptions.d.ts +0 -1
- package/lib/rules/mediaCaptions.js +0 -2
- package/lib/rules/mouseEventKeyEvents.d.ts +0 -1
- package/lib/rules/mouseEventKeyEvents.js +1 -3
- package/lib/rules/nonInteractiveElementInteractions.d.ts +0 -1
- package/lib/rules/nonInteractiveElementInteractions.js +2 -4
- package/lib/rules/nonInteractiveElementRoles.d.ts +0 -1
- package/lib/rules/nonInteractiveElementRoles.js +7 -9
- package/lib/rules/nonInteractiveElementTabIndexes.d.ts +0 -1
- package/lib/rules/nonInteractiveElementTabIndexes.js +2 -4
- package/lib/rules/propDuplicates.d.ts +0 -1
- package/lib/rules/propDuplicates.js +0 -2
- package/lib/rules/roleRedundancies.d.ts +0 -1
- package/lib/rules/roleRedundancies.js +0 -2
- package/lib/rules/roleRequiredAriaProps.d.ts +0 -1
- package/lib/rules/roleRequiredAriaProps.js +0 -2
- package/lib/rules/roleSupportedAriaProps.d.ts +0 -1
- package/lib/rules/roleSupportedAriaProps.js +81 -83
- package/lib/rules/roleTags.d.ts +0 -1
- package/lib/rules/roleTags.js +0 -2
- package/lib/rules/ruleCreator.d.ts +0 -1
- package/lib/rules/ruleCreator.js +0 -2
- package/lib/rules/scopeProps.d.ts +0 -1
- package/lib/rules/scopeProps.js +0 -2
- package/lib/rules/staticElementInteractions.d.ts +0 -1
- package/lib/rules/staticElementInteractions.js +1 -3
- package/lib/rules/svgTitles.d.ts +0 -1
- package/lib/rules/svgTitles.js +0 -2
- package/lib/rules/tabIndexPositiveValues.d.ts +0 -1
- package/lib/rules/tabIndexPositiveValues.js +0 -2
- package/lib/rules/unescapedEntities.d.ts +0 -1
- package/lib/rules/unescapedEntities.js +0 -2
- package/lib/rules/unnecessaryFragments.d.ts +0 -1
- package/lib/rules/unnecessaryFragments.js +0 -2
- package/package.json +7 -8
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { ruleCreator } from "./ruleCreator.js";
|
|
2
2
|
import { SyntaxKind } from "typescript";
|
|
3
|
-
import { getTSNodeRange, typescriptLanguage } from "@flint.fyi/typescript-language";
|
|
3
|
+
import { getStaticStringValue, getTSNodeRange, typescriptLanguage } from "@flint.fyi/typescript-language";
|
|
4
4
|
import { nullThrows } from "@flint.fyi/utils";
|
|
5
5
|
//#region src/rules/autocomplete.ts
|
|
6
|
-
const validAutocompleteValues = new Set([
|
|
6
|
+
const validAutocompleteValues = /* @__PURE__ */ new Set([
|
|
7
7
|
"address-level1",
|
|
8
8
|
"address-level2",
|
|
9
9
|
"address-level3",
|
|
@@ -54,7 +54,7 @@ const validAutocompleteValues = new Set([
|
|
|
54
54
|
"username",
|
|
55
55
|
"webauthn"
|
|
56
56
|
]);
|
|
57
|
-
const billingAndShippingValues = new Set([
|
|
57
|
+
const billingAndShippingValues = /* @__PURE__ */ new Set([
|
|
58
58
|
"address-level1",
|
|
59
59
|
"address-level2",
|
|
60
60
|
"address-level3",
|
|
@@ -102,7 +102,7 @@ var autocomplete_default = ruleCreator.createRule(typescriptLanguage, {
|
|
|
102
102
|
if (tagName.text.toLowerCase() !== "input") return;
|
|
103
103
|
const autocomplete = attributes.properties.find((property) => property.kind === SyntaxKind.JsxAttribute && property.name.kind === SyntaxKind.Identifier && property.name.text.toLowerCase() === "autocomplete");
|
|
104
104
|
if (autocomplete?.kind !== SyntaxKind.JsxAttribute || !autocomplete.initializer) return;
|
|
105
|
-
const value =
|
|
105
|
+
const value = getStaticStringValue(autocomplete.initializer);
|
|
106
106
|
if (value === void 0 || isValidAutocompleteValue(value)) return;
|
|
107
107
|
context.report({
|
|
108
108
|
data: { value },
|
|
@@ -116,11 +116,5 @@ var autocomplete_default = ruleCreator.createRule(typescriptLanguage, {
|
|
|
116
116
|
} };
|
|
117
117
|
}
|
|
118
118
|
});
|
|
119
|
-
function getStringLiteralValue(node) {
|
|
120
|
-
if (node.kind === SyntaxKind.StringLiteral) return node.text;
|
|
121
|
-
if (node.kind === SyntaxKind.NoSubstitutionTemplateLiteral && node.parent.kind !== SyntaxKind.TaggedTemplateExpression) return node.text;
|
|
122
|
-
}
|
|
123
119
|
//#endregion
|
|
124
120
|
export { autocomplete_default as default };
|
|
125
|
-
|
|
126
|
-
//# sourceMappingURL=autocomplete.js.map
|
package/lib/rules/buttonTypes.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { ruleCreator } from "./ruleCreator.js";
|
|
2
2
|
import { SyntaxKind } from "typescript";
|
|
3
|
-
import { getTSNodeRange, typescriptLanguage } from "@flint.fyi/typescript-language";
|
|
3
|
+
import { getStaticStringValue, getTSNodeRange, typescriptLanguage } from "@flint.fyi/typescript-language";
|
|
4
4
|
//#region src/rules/buttonTypes.ts
|
|
5
|
-
const validButtonTypes = new Set([
|
|
5
|
+
const validButtonTypes = /* @__PURE__ */ new Set([
|
|
6
6
|
"button",
|
|
7
7
|
"reset",
|
|
8
8
|
"submit"
|
|
@@ -49,7 +49,9 @@ var buttonTypes_default = ruleCreator.createRule(typescriptLanguage, {
|
|
|
49
49
|
});
|
|
50
50
|
return;
|
|
51
51
|
}
|
|
52
|
-
const
|
|
52
|
+
const typeInitializer = typeAttribute.initializer;
|
|
53
|
+
const typeExpression = typeInitializer?.kind === SyntaxKind.JsxExpression ? typeInitializer.expression : typeInitializer;
|
|
54
|
+
const typeValue = typeExpression && getStaticStringValue(typeExpression);
|
|
53
55
|
if (typeValue && !validButtonTypes.has(typeValue)) context.report({
|
|
54
56
|
data: { type: typeValue },
|
|
55
57
|
message: "invalidType",
|
|
@@ -62,15 +64,5 @@ var buttonTypes_default = ruleCreator.createRule(typescriptLanguage, {
|
|
|
62
64
|
} };
|
|
63
65
|
}
|
|
64
66
|
});
|
|
65
|
-
function getTypeValue(attribute) {
|
|
66
|
-
if (!attribute.initializer) return;
|
|
67
|
-
if (attribute.initializer.kind === SyntaxKind.StringLiteral) return attribute.initializer.text;
|
|
68
|
-
if (attribute.initializer.kind === SyntaxKind.JsxExpression) {
|
|
69
|
-
const expr = attribute.initializer.expression;
|
|
70
|
-
if (expr?.kind === SyntaxKind.StringLiteral) return expr.text;
|
|
71
|
-
}
|
|
72
|
-
}
|
|
73
67
|
//#endregion
|
|
74
68
|
export { buttonTypes_default as default };
|
|
75
|
-
|
|
76
|
-
//# sourceMappingURL=buttonTypes.js.map
|
|
@@ -2,7 +2,7 @@ import { ruleCreator } from "./ruleCreator.js";
|
|
|
2
2
|
import { SyntaxKind } from "typescript";
|
|
3
3
|
import { getTSNodeRange, typescriptLanguage } from "@flint.fyi/typescript-language";
|
|
4
4
|
//#region src/rules/clickEventKeyEvents.ts
|
|
5
|
-
const interactiveElements = new Set([
|
|
5
|
+
const interactiveElements = /* @__PURE__ */ new Set([
|
|
6
6
|
"a",
|
|
7
7
|
"button",
|
|
8
8
|
"input",
|
|
@@ -52,5 +52,3 @@ var clickEventKeyEvents_default = ruleCreator.createRule(typescriptLanguage, {
|
|
|
52
52
|
});
|
|
53
53
|
//#endregion
|
|
54
54
|
export { clickEventKeyEvents_default as default };
|
|
55
|
-
|
|
56
|
-
//# sourceMappingURL=clickEventKeyEvents.js.map
|
|
@@ -2,7 +2,7 @@ import { ruleCreator } from "./ruleCreator.js";
|
|
|
2
2
|
import { SyntaxKind } from "typescript";
|
|
3
3
|
import { getTSNodeRange, typescriptLanguage } from "@flint.fyi/typescript-language";
|
|
4
4
|
//#region src/rules/distractingElements.ts
|
|
5
|
-
const distractingElements = new Set(["blink", "marquee"]);
|
|
5
|
+
const distractingElements = /* @__PURE__ */ new Set(["blink", "marquee"]);
|
|
6
6
|
var distractingElements_default = ruleCreator.createRule(typescriptLanguage, {
|
|
7
7
|
about: {
|
|
8
8
|
description: "Reports distracting elements like <marquee> and <blink>.",
|
|
@@ -36,5 +36,3 @@ var distractingElements_default = ruleCreator.createRule(typescriptLanguage, {
|
|
|
36
36
|
});
|
|
37
37
|
//#endregion
|
|
38
38
|
export { distractingElements_default as default };
|
|
39
|
-
|
|
40
|
-
//# sourceMappingURL=distractingElements.js.map
|
|
@@ -2,7 +2,7 @@ import { ruleCreator } from "./ruleCreator.js";
|
|
|
2
2
|
import { SyntaxKind } from "typescript";
|
|
3
3
|
import { getTSNodeRange, typescriptLanguage } from "@flint.fyi/typescript-language";
|
|
4
4
|
//#region src/rules/elementChildrenValidity.ts
|
|
5
|
-
const voidElements = new Set([
|
|
5
|
+
const voidElements = /* @__PURE__ */ new Set([
|
|
6
6
|
"area",
|
|
7
7
|
"base",
|
|
8
8
|
"br",
|
|
@@ -50,5 +50,3 @@ var elementChildrenValidity_default = ruleCreator.createRule(typescriptLanguage,
|
|
|
50
50
|
});
|
|
51
51
|
//#endregion
|
|
52
52
|
export { elementChildrenValidity_default as default };
|
|
53
|
-
|
|
54
|
-
//# sourceMappingURL=elementChildrenValidity.js.map
|
|
@@ -2,7 +2,7 @@ import { ruleCreator } from "./ruleCreator.js";
|
|
|
2
2
|
import { SyntaxKind } from "typescript";
|
|
3
3
|
import { getTSNodeRange, typescriptLanguage } from "@flint.fyi/typescript-language";
|
|
4
4
|
//#region src/rules/headingContents.ts
|
|
5
|
-
const headingElements = new Set([
|
|
5
|
+
const headingElements = /* @__PURE__ */ new Set([
|
|
6
6
|
"h1",
|
|
7
7
|
"h2",
|
|
8
8
|
"h3",
|
|
@@ -50,5 +50,3 @@ var headingContents_default = ruleCreator.createRule(typescriptLanguage, {
|
|
|
50
50
|
});
|
|
51
51
|
//#endregion
|
|
52
52
|
export { headingContents_default as default };
|
|
53
|
-
|
|
54
|
-
//# sourceMappingURL=headingContents.js.map
|
package/lib/rules/htmlLangs.d.ts
CHANGED
package/lib/rules/htmlLangs.js
CHANGED
|
@@ -2,7 +2,7 @@ import { ruleCreator } from "./ruleCreator.js";
|
|
|
2
2
|
import { SyntaxKind } from "typescript";
|
|
3
3
|
import { getTSNodeRange, typescriptLanguage } from "@flint.fyi/typescript-language";
|
|
4
4
|
//#region src/rules/interactiveElementRoles.ts
|
|
5
|
-
const interactiveElements = new Set([
|
|
5
|
+
const interactiveElements = /* @__PURE__ */ new Set([
|
|
6
6
|
"a",
|
|
7
7
|
"audio",
|
|
8
8
|
"button",
|
|
@@ -13,7 +13,7 @@ const interactiveElements = new Set([
|
|
|
13
13
|
"textarea",
|
|
14
14
|
"video"
|
|
15
15
|
]);
|
|
16
|
-
const nonInteractiveRoles = new Set([
|
|
16
|
+
const nonInteractiveRoles = /* @__PURE__ */ new Set([
|
|
17
17
|
"article",
|
|
18
18
|
"banner",
|
|
19
19
|
"complementary",
|
|
@@ -89,5 +89,3 @@ var interactiveElementRoles_default = ruleCreator.createRule(typescriptLanguage,
|
|
|
89
89
|
});
|
|
90
90
|
//#endregion
|
|
91
91
|
export { interactiveElementRoles_default as default };
|
|
92
|
-
|
|
93
|
-
//# sourceMappingURL=interactiveElementRoles.js.map
|
|
@@ -10,7 +10,7 @@ const interactiveHandlers = [
|
|
|
10
10
|
"onMouseDown",
|
|
11
11
|
"onMouseUp"
|
|
12
12
|
];
|
|
13
|
-
const interactiveRoles = new Set([
|
|
13
|
+
const interactiveRoles = /* @__PURE__ */ new Set([
|
|
14
14
|
"button",
|
|
15
15
|
"checkbox",
|
|
16
16
|
"columnheader",
|
|
@@ -42,7 +42,7 @@ const interactiveRoles = new Set([
|
|
|
42
42
|
"treegrid",
|
|
43
43
|
"treeitem"
|
|
44
44
|
]);
|
|
45
|
-
const inherentlyFocusableElements = new Set([
|
|
45
|
+
const inherentlyFocusableElements = /* @__PURE__ */ new Set([
|
|
46
46
|
"a",
|
|
47
47
|
"audio",
|
|
48
48
|
"button",
|
|
@@ -51,7 +51,7 @@ const inherentlyFocusableElements = new Set([
|
|
|
51
51
|
"textarea",
|
|
52
52
|
"video"
|
|
53
53
|
]);
|
|
54
|
-
const nonInteractiveElements = new Set([
|
|
54
|
+
const nonInteractiveElements = /* @__PURE__ */ new Set([
|
|
55
55
|
"article",
|
|
56
56
|
"aside",
|
|
57
57
|
"body",
|
|
@@ -79,7 +79,7 @@ const nonInteractiveElements = new Set([
|
|
|
79
79
|
"td",
|
|
80
80
|
"ul"
|
|
81
81
|
]);
|
|
82
|
-
const nonInteractiveRoles = new Set([
|
|
82
|
+
const nonInteractiveRoles = /* @__PURE__ */ new Set([
|
|
83
83
|
"article",
|
|
84
84
|
"banner",
|
|
85
85
|
"complementary",
|
|
@@ -168,5 +168,3 @@ var interactiveElementsFocusable_default = ruleCreator.createRule(typescriptLang
|
|
|
168
168
|
});
|
|
169
169
|
//#endregion
|
|
170
170
|
export { interactiveElementsFocusable_default as default };
|
|
171
|
-
|
|
172
|
-
//# sourceMappingURL=interactiveElementsFocusable.js.map
|
|
@@ -2,7 +2,7 @@ import { ruleCreator } from "./ruleCreator.js";
|
|
|
2
2
|
import { SyntaxKind } from "typescript";
|
|
3
3
|
import { getTSNodeRange, typescriptLanguage } from "@flint.fyi/typescript-language";
|
|
4
4
|
//#region src/rules/labelAssociatedControls.ts
|
|
5
|
-
const controlElements = new Set([
|
|
5
|
+
const controlElements = /* @__PURE__ */ new Set([
|
|
6
6
|
"input",
|
|
7
7
|
"meter",
|
|
8
8
|
"output",
|
|
@@ -66,5 +66,3 @@ var labelAssociatedControls_default = ruleCreator.createRule(typescriptLanguage,
|
|
|
66
66
|
});
|
|
67
67
|
//#endregion
|
|
68
68
|
export { labelAssociatedControls_default as default };
|
|
69
|
-
|
|
70
|
-
//# sourceMappingURL=labelAssociatedControls.js.map
|
|
@@ -2,7 +2,7 @@ import { ruleCreator } from "./ruleCreator.js";
|
|
|
2
2
|
import { SyntaxKind } from "typescript";
|
|
3
3
|
import { getTSNodeRange, typescriptLanguage } from "@flint.fyi/typescript-language";
|
|
4
4
|
//#region src/rules/mouseEventKeyEvents.ts
|
|
5
|
-
const mouseNamesToKeyboardNames = new Map([["onMouseOut", "onBlur"], ["onMouseOver", "onFocus"]]);
|
|
5
|
+
const mouseNamesToKeyboardNames = /* @__PURE__ */ new Map([["onMouseOut", "onBlur"], ["onMouseOver", "onFocus"]]);
|
|
6
6
|
var mouseEventKeyEvents_default = ruleCreator.createRule(typescriptLanguage, {
|
|
7
7
|
about: {
|
|
8
8
|
description: "Reports mouse events without corresponding keyboard events.",
|
|
@@ -45,5 +45,3 @@ var mouseEventKeyEvents_default = ruleCreator.createRule(typescriptLanguage, {
|
|
|
45
45
|
});
|
|
46
46
|
//#endregion
|
|
47
47
|
export { mouseEventKeyEvents_default as default };
|
|
48
|
-
|
|
49
|
-
//# sourceMappingURL=mouseEventKeyEvents.js.map
|
|
@@ -10,7 +10,7 @@ const interactiveHandlers = [
|
|
|
10
10
|
"onMouseDown",
|
|
11
11
|
"onMouseUp"
|
|
12
12
|
];
|
|
13
|
-
const nonInteractiveElements = new Set([
|
|
13
|
+
const nonInteractiveElements = /* @__PURE__ */ new Set([
|
|
14
14
|
"area",
|
|
15
15
|
"article",
|
|
16
16
|
"aside",
|
|
@@ -37,7 +37,7 @@ const nonInteractiveElements = new Set([
|
|
|
37
37
|
"td",
|
|
38
38
|
"ul"
|
|
39
39
|
]);
|
|
40
|
-
const nonInteractiveRoles = new Set([
|
|
40
|
+
const nonInteractiveRoles = /* @__PURE__ */ new Set([
|
|
41
41
|
"article",
|
|
42
42
|
"banner",
|
|
43
43
|
"complementary",
|
|
@@ -91,5 +91,3 @@ var nonInteractiveElementInteractions_default = ruleCreator.createRule(typescrip
|
|
|
91
91
|
});
|
|
92
92
|
//#endregion
|
|
93
93
|
export { nonInteractiveElementInteractions_default as default };
|
|
94
|
-
|
|
95
|
-
//# sourceMappingURL=nonInteractiveElementInteractions.js.map
|
|
@@ -2,7 +2,7 @@ import { ruleCreator } from "./ruleCreator.js";
|
|
|
2
2
|
import { SyntaxKind } from "typescript";
|
|
3
3
|
import { getTSNodeRange, typescriptLanguage } from "@flint.fyi/typescript-language";
|
|
4
4
|
//#region src/rules/nonInteractiveElementRoles.ts
|
|
5
|
-
const nonInteractiveElements = new Set([
|
|
5
|
+
const nonInteractiveElements = /* @__PURE__ */ new Set([
|
|
6
6
|
"article",
|
|
7
7
|
"aside",
|
|
8
8
|
"body",
|
|
@@ -29,7 +29,7 @@ const nonInteractiveElements = new Set([
|
|
|
29
29
|
"td",
|
|
30
30
|
"ul"
|
|
31
31
|
]);
|
|
32
|
-
const interactiveRoles = new Set([
|
|
32
|
+
const interactiveRoles = /* @__PURE__ */ new Set([
|
|
33
33
|
"button",
|
|
34
34
|
"checkbox",
|
|
35
35
|
"link",
|
|
@@ -46,14 +46,14 @@ const interactiveRoles = new Set([
|
|
|
46
46
|
"textbox"
|
|
47
47
|
]);
|
|
48
48
|
const allowedExceptions = {
|
|
49
|
-
li: new Set([
|
|
49
|
+
li: /* @__PURE__ */ new Set([
|
|
50
50
|
"menuitem",
|
|
51
51
|
"option",
|
|
52
52
|
"row",
|
|
53
53
|
"tab",
|
|
54
54
|
"treeitem"
|
|
55
55
|
]),
|
|
56
|
-
ol: new Set([
|
|
56
|
+
ol: /* @__PURE__ */ new Set([
|
|
57
57
|
"listbox",
|
|
58
58
|
"menu",
|
|
59
59
|
"menubar",
|
|
@@ -62,9 +62,9 @@ const allowedExceptions = {
|
|
|
62
62
|
"tree",
|
|
63
63
|
"treegrid"
|
|
64
64
|
]),
|
|
65
|
-
table: new Set(["grid"]),
|
|
66
|
-
td: new Set(["gridcell"]),
|
|
67
|
-
ul: new Set([
|
|
65
|
+
table: /* @__PURE__ */ new Set(["grid"]),
|
|
66
|
+
td: /* @__PURE__ */ new Set(["gridcell"]),
|
|
67
|
+
ul: /* @__PURE__ */ new Set([
|
|
68
68
|
"listbox",
|
|
69
69
|
"menu",
|
|
70
70
|
"menubar",
|
|
@@ -114,5 +114,3 @@ var nonInteractiveElementRoles_default = ruleCreator.createRule(typescriptLangua
|
|
|
114
114
|
});
|
|
115
115
|
//#endregion
|
|
116
116
|
export { nonInteractiveElementRoles_default as default };
|
|
117
|
-
|
|
118
|
-
//# sourceMappingURL=nonInteractiveElementRoles.js.map
|
|
@@ -2,7 +2,7 @@ import { ruleCreator } from "./ruleCreator.js";
|
|
|
2
2
|
import { SyntaxKind } from "typescript";
|
|
3
3
|
import { getTSNodeRange, typescriptLanguage } from "@flint.fyi/typescript-language";
|
|
4
4
|
//#region src/rules/nonInteractiveElementTabIndexes.ts
|
|
5
|
-
const nonInteractiveElements = new Set([
|
|
5
|
+
const nonInteractiveElements = /* @__PURE__ */ new Set([
|
|
6
6
|
"article",
|
|
7
7
|
"aside",
|
|
8
8
|
"body",
|
|
@@ -28,7 +28,7 @@ const nonInteractiveElements = new Set([
|
|
|
28
28
|
"span",
|
|
29
29
|
"ul"
|
|
30
30
|
]);
|
|
31
|
-
const interactiveRoles = new Set([
|
|
31
|
+
const interactiveRoles = /* @__PURE__ */ new Set([
|
|
32
32
|
"button",
|
|
33
33
|
"checkbox",
|
|
34
34
|
"link",
|
|
@@ -105,5 +105,3 @@ var nonInteractiveElementTabIndexes_default = ruleCreator.createRule(typescriptL
|
|
|
105
105
|
});
|
|
106
106
|
//#endregion
|
|
107
107
|
export { nonInteractiveElementTabIndexes_default as default };
|
|
108
|
-
|
|
109
|
-
//# sourceMappingURL=nonInteractiveElementTabIndexes.js.map
|