@angular-eslint/eslint-plugin-template 17.3.1-alpha.8 → 17.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/dist/index.d.ts +152 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/processors.d.ts +38 -0
- package/dist/processors.d.ts.map +1 -0
- package/dist/rules/alt-text.d.ts +5 -0
- package/dist/rules/alt-text.d.ts.map +1 -0
- package/dist/rules/attributes-order.d.ts +19 -0
- package/dist/rules/attributes-order.d.ts.map +1 -0
- package/dist/rules/attributes-order.js +31 -22
- package/dist/rules/banana-in-box.d.ts +5 -0
- package/dist/rules/banana-in-box.d.ts.map +1 -0
- package/dist/rules/button-has-type.d.ts +6 -0
- package/dist/rules/button-has-type.d.ts.map +1 -0
- package/dist/rules/click-events-have-key-events.d.ts +5 -0
- package/dist/rules/click-events-have-key-events.d.ts.map +1 -0
- package/dist/rules/conditional-complexity.d.ts +8 -0
- package/dist/rules/conditional-complexity.d.ts.map +1 -0
- package/dist/rules/cyclomatic-complexity.d.ts +8 -0
- package/dist/rules/cyclomatic-complexity.d.ts.map +1 -0
- package/dist/rules/elements-content.d.ts +10 -0
- package/dist/rules/elements-content.d.ts.map +1 -0
- package/dist/rules/eqeqeq.d.ts +9 -0
- package/dist/rules/eqeqeq.d.ts.map +1 -0
- package/dist/rules/i18n.d.ts +19 -0
- package/dist/rules/i18n.d.ts.map +1 -0
- package/dist/rules/interactive-supports-focus.d.ts +5 -0
- package/dist/rules/interactive-supports-focus.d.ts.map +1 -0
- package/dist/rules/label-has-associated-control.d.ts +15 -0
- package/dist/rules/label-has-associated-control.d.ts.map +1 -0
- package/dist/rules/mouse-events-have-key-events.d.ts +6 -0
- package/dist/rules/mouse-events-have-key-events.d.ts.map +1 -0
- package/dist/rules/mouse-events-have-key-events.js +13 -3
- package/dist/rules/no-any.d.ts +5 -0
- package/dist/rules/no-any.d.ts.map +1 -0
- package/dist/rules/no-autofocus.d.ts +5 -0
- package/dist/rules/no-autofocus.d.ts.map +1 -0
- package/dist/rules/no-call-expression.d.ts +10 -0
- package/dist/rules/no-call-expression.d.ts.map +1 -0
- package/dist/rules/no-distracting-elements.d.ts +5 -0
- package/dist/rules/no-distracting-elements.d.ts.map +1 -0
- package/dist/rules/no-duplicate-attributes.d.ts +12 -0
- package/dist/rules/no-duplicate-attributes.d.ts.map +1 -0
- package/dist/rules/no-inline-styles.d.ts +11 -0
- package/dist/rules/no-inline-styles.d.ts.map +1 -0
- package/dist/rules/no-interpolation-in-attributes.d.ts +5 -0
- package/dist/rules/no-interpolation-in-attributes.d.ts.map +1 -0
- package/dist/rules/no-negated-async.d.ts +8 -0
- package/dist/rules/no-negated-async.d.ts.map +1 -0
- package/dist/rules/no-positive-tabindex.d.ts +5 -0
- package/dist/rules/no-positive-tabindex.d.ts.map +1 -0
- package/dist/rules/prefer-control-flow.d.ts +5 -0
- package/dist/rules/prefer-control-flow.d.ts.map +1 -0
- package/dist/rules/prefer-ngsrc.d.ts +5 -0
- package/dist/rules/prefer-ngsrc.d.ts.map +1 -0
- package/dist/rules/prefer-self-closing-tags.d.ts +5 -0
- package/dist/rules/prefer-self-closing-tags.d.ts.map +1 -0
- package/dist/rules/role-has-required-aria.d.ts +5 -0
- package/dist/rules/role-has-required-aria.d.ts.map +1 -0
- package/dist/rules/table-scope.d.ts +5 -0
- package/dist/rules/table-scope.d.ts.map +1 -0
- package/dist/rules/use-track-by-function.d.ts +8 -0
- package/dist/rules/use-track-by-function.d.ts.map +1 -0
- package/dist/rules/valid-aria.d.ts +5 -0
- package/dist/rules/valid-aria.d.ts.map +1 -0
- package/dist/utils/attributes-comparator.d.ts +4 -0
- package/dist/utils/attributes-comparator.d.ts.map +1 -0
- package/dist/utils/constants.d.ts +9 -0
- package/dist/utils/constants.d.ts.map +1 -0
- package/dist/utils/create-eslint-rule.d.ts +3 -0
- package/dist/utils/create-eslint-rule.d.ts.map +1 -0
- package/dist/utils/get-attribute-value.d.ts +13 -0
- package/dist/utils/get-attribute-value.d.ts.map +1 -0
- package/dist/utils/get-dom-elements.d.ts +2 -0
- package/dist/utils/get-dom-elements.d.ts.map +1 -0
- package/dist/utils/get-nearest-node-from.d.ts +7 -0
- package/dist/utils/get-nearest-node-from.d.ts.map +1 -0
- package/dist/utils/get-original-attribute-name.d.ts +14 -0
- package/dist/utils/get-original-attribute-name.d.ts.map +1 -0
- package/dist/utils/is-child-node-of.d.ts +3 -0
- package/dist/utils/is-child-node-of.d.ts.map +1 -0
- package/dist/utils/is-content-editable.d.ts +3 -0
- package/dist/utils/is-content-editable.d.ts.map +1 -0
- package/dist/utils/is-disabled-element.d.ts +3 -0
- package/dist/utils/is-disabled-element.d.ts.map +1 -0
- package/dist/utils/is-hidden-from-screen-reader.d.ts +10 -0
- package/dist/utils/is-hidden-from-screen-reader.d.ts.map +1 -0
- package/dist/utils/is-interactive-element/get-interactive-element-ax-object-schemas.d.ts +10 -0
- package/dist/utils/is-interactive-element/get-interactive-element-ax-object-schemas.d.ts.map +1 -0
- package/dist/utils/is-interactive-element/get-interactive-element-role-schemas.d.ts +3 -0
- package/dist/utils/is-interactive-element/get-interactive-element-role-schemas.d.ts.map +1 -0
- package/dist/utils/is-interactive-element/get-non-interactive-element-role-schemas.d.ts +4 -0
- package/dist/utils/is-interactive-element/get-non-interactive-element-role-schemas.d.ts.map +1 -0
- package/dist/utils/is-interactive-element/index.d.ts +10 -0
- package/dist/utils/is-interactive-element/index.d.ts.map +1 -0
- package/dist/utils/is-presentation-role.d.ts +3 -0
- package/dist/utils/is-presentation-role.d.ts.map +1 -0
- package/dist/utils/is-semantic-role-element.d.ts +3 -0
- package/dist/utils/is-semantic-role-element.d.ts.map +1 -0
- package/dist/utils/to-pattern.d.ts +2 -0
- package/dist/utils/to-pattern.d.ts.map +1 -0
- package/package.json +6 -5
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1,152 @@
|
|
|
1
|
+
declare const _default: {
|
|
2
|
+
configs: {
|
|
3
|
+
all: {
|
|
4
|
+
parser: string;
|
|
5
|
+
plugins: string[];
|
|
6
|
+
rules: {
|
|
7
|
+
"@angular-eslint/template/alt-text": string;
|
|
8
|
+
"@angular-eslint/template/attributes-order": string;
|
|
9
|
+
"@angular-eslint/template/banana-in-box": string;
|
|
10
|
+
"@angular-eslint/template/button-has-type": string;
|
|
11
|
+
"@angular-eslint/template/click-events-have-key-events": string;
|
|
12
|
+
"@angular-eslint/template/conditional-complexity": string;
|
|
13
|
+
"@angular-eslint/template/cyclomatic-complexity": string;
|
|
14
|
+
"@angular-eslint/template/elements-content": string;
|
|
15
|
+
"@angular-eslint/template/eqeqeq": string;
|
|
16
|
+
"@angular-eslint/template/i18n": string;
|
|
17
|
+
"@angular-eslint/template/interactive-supports-focus": string;
|
|
18
|
+
"@angular-eslint/template/label-has-associated-control": string;
|
|
19
|
+
"@angular-eslint/template/mouse-events-have-key-events": string;
|
|
20
|
+
"@angular-eslint/template/no-any": string;
|
|
21
|
+
"@angular-eslint/template/no-autofocus": string;
|
|
22
|
+
"@angular-eslint/template/no-call-expression": string;
|
|
23
|
+
"@angular-eslint/template/no-distracting-elements": string;
|
|
24
|
+
"@angular-eslint/template/no-duplicate-attributes": string;
|
|
25
|
+
"@angular-eslint/template/no-inline-styles": string;
|
|
26
|
+
"@angular-eslint/template/no-interpolation-in-attributes": string;
|
|
27
|
+
"@angular-eslint/template/no-negated-async": string;
|
|
28
|
+
"@angular-eslint/template/no-positive-tabindex": string;
|
|
29
|
+
"@angular-eslint/template/prefer-control-flow": string;
|
|
30
|
+
"@angular-eslint/template/prefer-ngsrc": string;
|
|
31
|
+
"@angular-eslint/template/prefer-self-closing-tags": string;
|
|
32
|
+
"@angular-eslint/template/role-has-required-aria": string;
|
|
33
|
+
"@angular-eslint/template/table-scope": string;
|
|
34
|
+
"@angular-eslint/template/use-track-by-function": string;
|
|
35
|
+
"@angular-eslint/template/valid-aria": string;
|
|
36
|
+
};
|
|
37
|
+
};
|
|
38
|
+
recommended: {
|
|
39
|
+
parser: string;
|
|
40
|
+
plugins: string[];
|
|
41
|
+
rules: {
|
|
42
|
+
"@angular-eslint/template/banana-in-box": string;
|
|
43
|
+
"@angular-eslint/template/eqeqeq": string;
|
|
44
|
+
"@angular-eslint/template/no-negated-async": string;
|
|
45
|
+
};
|
|
46
|
+
};
|
|
47
|
+
accessibility: {
|
|
48
|
+
parser: string;
|
|
49
|
+
plugins: string[];
|
|
50
|
+
rules: {
|
|
51
|
+
"@angular-eslint/template/alt-text": string;
|
|
52
|
+
"@angular-eslint/template/click-events-have-key-events": string;
|
|
53
|
+
"@angular-eslint/template/elements-content": string;
|
|
54
|
+
"@angular-eslint/template/interactive-supports-focus": string;
|
|
55
|
+
"@angular-eslint/template/label-has-associated-control": string;
|
|
56
|
+
"@angular-eslint/template/mouse-events-have-key-events": string;
|
|
57
|
+
"@angular-eslint/template/no-autofocus": string;
|
|
58
|
+
"@angular-eslint/template/no-distracting-elements": string;
|
|
59
|
+
"@angular-eslint/template/role-has-required-aria": string;
|
|
60
|
+
"@angular-eslint/template/table-scope": string;
|
|
61
|
+
"@angular-eslint/template/valid-aria": string;
|
|
62
|
+
};
|
|
63
|
+
};
|
|
64
|
+
'process-inline-templates': {
|
|
65
|
+
parser: string;
|
|
66
|
+
parserOptions: {
|
|
67
|
+
ecmaVersion: number;
|
|
68
|
+
sourceType: string;
|
|
69
|
+
};
|
|
70
|
+
plugins: string[];
|
|
71
|
+
processor: string;
|
|
72
|
+
};
|
|
73
|
+
};
|
|
74
|
+
processors: {
|
|
75
|
+
'extract-inline-html': {
|
|
76
|
+
preprocess: typeof import("./processors").preprocessComponentFile;
|
|
77
|
+
postprocess: typeof import("./processors").postprocessComponentFile;
|
|
78
|
+
supportsAutofix: boolean;
|
|
79
|
+
};
|
|
80
|
+
};
|
|
81
|
+
rules: {
|
|
82
|
+
"alt-text": import("@typescript-eslint/utils/ts-eslint").RuleModule<"altText", [], import("@typescript-eslint/utils/ts-eslint").RuleListener>;
|
|
83
|
+
"attributes-order": import("@typescript-eslint/utils/ts-eslint").RuleModule<"attributesOrder", [{
|
|
84
|
+
readonly alphabetical: boolean;
|
|
85
|
+
readonly order: readonly import("./rules/attributes-order").OrderType[];
|
|
86
|
+
}], import("@typescript-eslint/utils/ts-eslint").RuleListener>;
|
|
87
|
+
"banana-in-box": import("@typescript-eslint/utils/ts-eslint").RuleModule<"bananaInBox", [], import("@typescript-eslint/utils/ts-eslint").RuleListener>;
|
|
88
|
+
"button-has-type": import("@typescript-eslint/utils/ts-eslint").RuleModule<import("./rules/button-has-type").MessageIds, [], import("@typescript-eslint/utils/ts-eslint").RuleListener>;
|
|
89
|
+
"click-events-have-key-events": import("@typescript-eslint/utils/ts-eslint").RuleModule<"clickEventsHaveKeyEvents", [], import("@typescript-eslint/utils/ts-eslint").RuleListener>;
|
|
90
|
+
"conditional-complexity": import("@typescript-eslint/utils/ts-eslint").RuleModule<"conditionalComplexity", [{
|
|
91
|
+
maxComplexity: number;
|
|
92
|
+
}], import("@typescript-eslint/utils/ts-eslint").RuleListener>;
|
|
93
|
+
"cyclomatic-complexity": import("@typescript-eslint/utils/ts-eslint").RuleModule<"cyclomaticComplexity", [{
|
|
94
|
+
maxComplexity: number;
|
|
95
|
+
}], import("@typescript-eslint/utils/ts-eslint").RuleListener>;
|
|
96
|
+
"elements-content": import("@typescript-eslint/utils/ts-eslint").RuleModule<"elementsContent", [{
|
|
97
|
+
readonly allowList?: readonly string[] | undefined;
|
|
98
|
+
}], import("@typescript-eslint/utils/ts-eslint").RuleListener>;
|
|
99
|
+
eqeqeq: import("@typescript-eslint/utils/ts-eslint").RuleModule<import("./rules/eqeqeq").MessageIds, [{
|
|
100
|
+
readonly allowNullOrUndefined?: boolean | undefined;
|
|
101
|
+
}], import("@typescript-eslint/utils/ts-eslint").RuleListener>;
|
|
102
|
+
i18n: import("@typescript-eslint/utils/ts-eslint").RuleModule<import("./rules/i18n").MessageIds, [{
|
|
103
|
+
readonly boundTextAllowedPattern?: string | undefined;
|
|
104
|
+
readonly checkAttributes?: boolean | undefined;
|
|
105
|
+
readonly checkDuplicateId?: boolean | undefined;
|
|
106
|
+
readonly checkId?: boolean | undefined;
|
|
107
|
+
readonly checkText?: boolean | undefined;
|
|
108
|
+
readonly ignoreAttributes?: readonly string[] | undefined;
|
|
109
|
+
readonly ignoreTags?: readonly string[] | undefined;
|
|
110
|
+
readonly requireDescription?: boolean | undefined;
|
|
111
|
+
readonly requireMeaning?: boolean | undefined;
|
|
112
|
+
}], import("@typescript-eslint/utils/ts-eslint").RuleListener>;
|
|
113
|
+
"interactive-supports-focus": import("@typescript-eslint/utils/ts-eslint").RuleModule<"interactiveSupportsFocus", [], import("@typescript-eslint/utils/ts-eslint").RuleListener>;
|
|
114
|
+
"label-has-associated-control": import("@typescript-eslint/utils/ts-eslint").RuleModule<"labelHasAssociatedControl", [{
|
|
115
|
+
readonly controlComponents?: readonly string[] | undefined;
|
|
116
|
+
readonly labelComponents?: readonly {
|
|
117
|
+
readonly inputs?: readonly string[] | undefined;
|
|
118
|
+
readonly selector: string;
|
|
119
|
+
}[] | undefined;
|
|
120
|
+
}], import("@typescript-eslint/utils/ts-eslint").RuleListener>;
|
|
121
|
+
"mouse-events-have-key-events": import("@typescript-eslint/utils/ts-eslint").RuleModule<"mouseEventsHaveKeyEvents", [], import("@typescript-eslint/utils/ts-eslint").RuleListener>;
|
|
122
|
+
"no-any": import("@typescript-eslint/utils/ts-eslint").RuleModule<import("./rules/no-any").MessageIds, [], import("@typescript-eslint/utils/ts-eslint").RuleListener>;
|
|
123
|
+
"no-autofocus": import("@typescript-eslint/utils/ts-eslint").RuleModule<"noAutofocus", [], import("@typescript-eslint/utils/ts-eslint").RuleListener>;
|
|
124
|
+
"no-call-expression": import("@typescript-eslint/utils/ts-eslint").RuleModule<"noCallExpression", [{
|
|
125
|
+
readonly allowList?: readonly string[] | undefined;
|
|
126
|
+
}], import("@typescript-eslint/utils/ts-eslint").RuleListener>;
|
|
127
|
+
"no-distracting-elements": import("@typescript-eslint/utils/ts-eslint").RuleModule<"noDistractingElements", [], import("@typescript-eslint/utils/ts-eslint").RuleListener>;
|
|
128
|
+
"no-duplicate-attributes": import("@typescript-eslint/utils/ts-eslint").RuleModule<import("./rules/no-duplicate-attributes").MessageIds, [{
|
|
129
|
+
readonly allowTwoWayDataBinding?: boolean | undefined;
|
|
130
|
+
readonly allowStylePrecedenceDuplicates?: boolean | undefined;
|
|
131
|
+
readonly ignore?: readonly string[] | undefined;
|
|
132
|
+
}], import("@typescript-eslint/utils/ts-eslint").RuleListener>;
|
|
133
|
+
"no-inline-styles": import("@typescript-eslint/utils/ts-eslint").RuleModule<"noInlineStyles", [{
|
|
134
|
+
readonly allowNgStyle?: boolean | undefined;
|
|
135
|
+
readonly allowBindToStyle?: boolean | undefined;
|
|
136
|
+
}], import("@typescript-eslint/utils/ts-eslint").RuleListener>;
|
|
137
|
+
"no-interpolation-in-attributes": import("@typescript-eslint/utils/ts-eslint").RuleModule<"noInterpolationInAttributes", [], import("@typescript-eslint/utils/ts-eslint").RuleListener>;
|
|
138
|
+
"no-negated-async": import("@typescript-eslint/utils/ts-eslint").RuleModule<import("./rules/no-negated-async").MessageIds, [], import("@typescript-eslint/utils/ts-eslint").RuleListener>;
|
|
139
|
+
"no-positive-tabindex": import("@typescript-eslint/utils/ts-eslint").RuleModule<import("./rules/no-positive-tabindex").MessageIds, [], import("@typescript-eslint/utils/ts-eslint").RuleListener>;
|
|
140
|
+
"prefer-control-flow": import("@typescript-eslint/utils/ts-eslint").RuleModule<"preferControlFlow", [], import("@typescript-eslint/utils/ts-eslint").RuleListener>;
|
|
141
|
+
"prefer-self-closing-tags": import("@typescript-eslint/utils/ts-eslint").RuleModule<"preferSelfClosingTags", [], import("@typescript-eslint/utils/ts-eslint").RuleListener>;
|
|
142
|
+
"prefer-ngsrc": import("@typescript-eslint/utils/ts-eslint").RuleModule<import("./rules/prefer-ngsrc").MessageIds, [], import("@typescript-eslint/utils/ts-eslint").RuleListener>;
|
|
143
|
+
"role-has-required-aria": import("@typescript-eslint/utils/ts-eslint").RuleModule<import("./rules/role-has-required-aria").MessageIds, [], import("@typescript-eslint/utils/ts-eslint").RuleListener>;
|
|
144
|
+
"table-scope": import("@typescript-eslint/utils/ts-eslint").RuleModule<"tableScope", [], import("@typescript-eslint/utils/ts-eslint").RuleListener>;
|
|
145
|
+
"use-track-by-function": import("@typescript-eslint/utils/ts-eslint").RuleModule<"useTrackByFunction", [{
|
|
146
|
+
readonly alias: readonly string[];
|
|
147
|
+
}], import("@typescript-eslint/utils/ts-eslint").RuleListener>;
|
|
148
|
+
"valid-aria": import("@typescript-eslint/utils/ts-eslint").RuleModule<import("./rules/valid-aria").MessageIds, [], import("@typescript-eslint/utils/ts-eslint").RuleListener>;
|
|
149
|
+
};
|
|
150
|
+
};
|
|
151
|
+
export = _default;
|
|
152
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAmFA,kBAuCE"}
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Because ultimately a user is in control of how and when this processor gets invoked,
|
|
3
|
+
* we can't fully protect them against doing more work than is necessary in all cases.
|
|
4
|
+
*
|
|
5
|
+
* Therefore, before we do a full parse of a TypeScript file to try and extract one or
|
|
6
|
+
* more Component declarations we want to do a really quick check for whether or not
|
|
7
|
+
* a file is likely to contain them.
|
|
8
|
+
*/
|
|
9
|
+
export declare function isFileLikelyToContainComponentDeclarations(text: string, filename: string): boolean;
|
|
10
|
+
type PreprocessResult = (string | {
|
|
11
|
+
text: string;
|
|
12
|
+
filename: string;
|
|
13
|
+
})[];
|
|
14
|
+
export declare function preprocessComponentFile(text: string, filename: string): PreprocessResult;
|
|
15
|
+
export declare function postprocessComponentFile(multiDimensionalMessages: {
|
|
16
|
+
ruleId: string;
|
|
17
|
+
severity: number;
|
|
18
|
+
message: string;
|
|
19
|
+
line: number;
|
|
20
|
+
column: number;
|
|
21
|
+
nodeType: string;
|
|
22
|
+
messageId: string;
|
|
23
|
+
endLine: number;
|
|
24
|
+
endColumn: number;
|
|
25
|
+
fix?: {
|
|
26
|
+
range: number[];
|
|
27
|
+
text: string;
|
|
28
|
+
};
|
|
29
|
+
}[][], filename: string): readonly unknown[];
|
|
30
|
+
declare const _default: {
|
|
31
|
+
'extract-inline-html': {
|
|
32
|
+
preprocess: typeof preprocessComponentFile;
|
|
33
|
+
postprocess: typeof postprocessComponentFile;
|
|
34
|
+
supportsAutofix: boolean;
|
|
35
|
+
};
|
|
36
|
+
};
|
|
37
|
+
export default _default;
|
|
38
|
+
//# sourceMappingURL=processors.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"processors.d.ts","sourceRoot":"","sources":["../src/processors.ts"],"names":[],"mappings":"AAMA;;;;;;;GAOG;AACH,wBAAgB,0CAA0C,CACxD,IAAI,EAAE,MAAM,EACZ,QAAQ,EAAE,MAAM,GACf,OAAO,CA2BT;AAED,KAAK,gBAAgB,GAAG,CAAC,MAAM,GAAG;IAAE,IAAI,EAAE,MAAM,CAAC;IAAC,QAAQ,EAAE,MAAM,CAAA;CAAE,CAAC,EAAE,CAAC;AAExE,wBAAgB,uBAAuB,CACrC,IAAI,EAAE,MAAM,EACZ,QAAQ,EAAE,MAAM,GACf,gBAAgB,CAsJlB;AAED,wBAAgB,wBAAwB,CACtC,wBAAwB,EAAE;IACxB,MAAM,EAAE,MAAM,CAAC;IACf,QAAQ,EAAE,MAAM,CAAC;IACjB,OAAO,EAAE,MAAM,CAAC;IAChB,IAAI,EAAE,MAAM,CAAC;IACb,MAAM,EAAE,MAAM,CAAC;IACf,QAAQ,EAAE,MAAM,CAAC;IACjB,SAAS,EAAE,MAAM,CAAC;IAClB,OAAO,EAAE,MAAM,CAAC;IAChB,SAAS,EAAE,MAAM,CAAC;IAClB,GAAG,CAAC,EAAE;QACJ,KAAK,EAAE,MAAM,EAAE,CAAC;QAChB,IAAI,EAAE,MAAM,CAAC;KACd,CAAC;CACH,EAAE,EAAE,EACL,QAAQ,EAAE,MAAM,GACf,SAAS,OAAO,EAAE,CAmDpB;;;;;;;;AAED,wBAME"}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
export type MessageIds = 'altText';
|
|
2
|
+
export declare const RULE_NAME = "alt-text";
|
|
3
|
+
declare const _default: import("@typescript-eslint/utils/ts-eslint").RuleModule<"altText", [], import("@typescript-eslint/utils/ts-eslint").RuleListener>;
|
|
4
|
+
export default _default;
|
|
5
|
+
//# sourceMappingURL=alt-text.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"alt-text.d.ts","sourceRoot":"","sources":["../../src/rules/alt-text.ts"],"names":[],"mappings":"AASA,MAAM,MAAM,UAAU,GAAG,SAAS,CAAC;AACnC,eAAO,MAAM,SAAS,aAAa,CAAC;;AAEpC,wBAsCG"}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
export declare enum OrderType {
|
|
2
|
+
TemplateReferenceVariable = "TEMPLATE_REFERENCE",
|
|
3
|
+
StructuralDirective = "STRUCTURAL_DIRECTIVE",
|
|
4
|
+
AttributeBinding = "ATTRIBUTE_BINDING",
|
|
5
|
+
InputBinding = "INPUT_BINDING",
|
|
6
|
+
OutputBinding = "OUTPUT_BINDING",
|
|
7
|
+
TwoWayBinding = "TWO_WAY_BINDING"
|
|
8
|
+
}
|
|
9
|
+
type Options = [
|
|
10
|
+
{
|
|
11
|
+
readonly alphabetical: boolean;
|
|
12
|
+
readonly order: readonly OrderType[];
|
|
13
|
+
}
|
|
14
|
+
];
|
|
15
|
+
export type MessageIds = 'attributesOrder';
|
|
16
|
+
export declare const RULE_NAME = "attributes-order";
|
|
17
|
+
declare const _default: import("@typescript-eslint/utils/ts-eslint").RuleModule<"attributesOrder", Options, import("@typescript-eslint/utils/ts-eslint").RuleListener>;
|
|
18
|
+
export default _default;
|
|
19
|
+
//# sourceMappingURL=attributes-order.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"attributes-order.d.ts","sourceRoot":"","sources":["../../src/rules/attributes-order.ts"],"names":[],"mappings":"AAiBA,oBAAY,SAAS;IACnB,yBAAyB,uBAAuB;IAChD,mBAAmB,yBAAyB;IAC5C,gBAAgB,sBAAsB;IACtC,YAAY,kBAAkB;IAC9B,aAAa,mBAAmB;IAChC,aAAa,oBAAoB;CAClC;AAED,KAAK,OAAO,GAAG;IACb;QACE,QAAQ,CAAC,YAAY,EAAE,OAAO,CAAC;QAC/B,QAAQ,CAAC,KAAK,EAAE,SAAS,SAAS,EAAE,CAAC;KACtC;CACF,CAAC;AA6BF,MAAM,MAAM,UAAU,GAAG,iBAAiB,CAAC;AAC3C,eAAO,MAAM,SAAS,qBAAqB,CAAC;;AAgB5C,wBAmJG"}
|
|
@@ -1,17 +1,26 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.RULE_NAME = void 0;
|
|
3
|
+
exports.RULE_NAME = exports.OrderType = void 0;
|
|
4
4
|
const bundled_angular_compiler_1 = require("@angular-eslint/bundled-angular-compiler");
|
|
5
5
|
const utils_1 = require("@angular-eslint/utils");
|
|
6
6
|
const create_eslint_rule_1 = require("../utils/create-eslint-rule");
|
|
7
|
+
var OrderType;
|
|
8
|
+
(function (OrderType) {
|
|
9
|
+
OrderType["TemplateReferenceVariable"] = "TEMPLATE_REFERENCE";
|
|
10
|
+
OrderType["StructuralDirective"] = "STRUCTURAL_DIRECTIVE";
|
|
11
|
+
OrderType["AttributeBinding"] = "ATTRIBUTE_BINDING";
|
|
12
|
+
OrderType["InputBinding"] = "INPUT_BINDING";
|
|
13
|
+
OrderType["OutputBinding"] = "OUTPUT_BINDING";
|
|
14
|
+
OrderType["TwoWayBinding"] = "TWO_WAY_BINDING";
|
|
15
|
+
})(OrderType || (exports.OrderType = OrderType = {}));
|
|
7
16
|
exports.RULE_NAME = 'attributes-order';
|
|
8
17
|
const DEFAULT_ORDER = [
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
18
|
+
OrderType.StructuralDirective,
|
|
19
|
+
OrderType.TemplateReferenceVariable,
|
|
20
|
+
OrderType.AttributeBinding,
|
|
21
|
+
OrderType.InputBinding,
|
|
22
|
+
OrderType.TwoWayBinding,
|
|
23
|
+
OrderType.OutputBinding,
|
|
15
24
|
];
|
|
16
25
|
const DEFAULT_OPTIONS = {
|
|
17
26
|
alphabetical: false,
|
|
@@ -57,7 +66,7 @@ exports.default = (0, create_eslint_rule_1.createESLintRule)({
|
|
|
57
66
|
function getLocation(attr) {
|
|
58
67
|
const loc = parserServices.convertNodeSourceSpanToLoc(attr.sourceSpan);
|
|
59
68
|
switch (attr.orderType) {
|
|
60
|
-
case
|
|
69
|
+
case OrderType.StructuralDirective:
|
|
61
70
|
return {
|
|
62
71
|
start: {
|
|
63
72
|
line: loc.start.line,
|
|
@@ -168,37 +177,37 @@ function getOrderIndex(attr, order) {
|
|
|
168
177
|
function toAttributeBindingOrderType(attribute) {
|
|
169
178
|
return {
|
|
170
179
|
...attribute,
|
|
171
|
-
orderType:
|
|
180
|
+
orderType: OrderType.AttributeBinding,
|
|
172
181
|
};
|
|
173
182
|
}
|
|
174
183
|
function toInputBindingOrderType(input) {
|
|
175
184
|
return {
|
|
176
185
|
...input,
|
|
177
|
-
orderType:
|
|
186
|
+
orderType: OrderType.InputBinding,
|
|
178
187
|
};
|
|
179
188
|
}
|
|
180
189
|
function toStructuralDirectiveOrderType(attributeOrInput) {
|
|
181
190
|
return {
|
|
182
191
|
...attributeOrInput,
|
|
183
|
-
orderType:
|
|
192
|
+
orderType: OrderType.StructuralDirective,
|
|
184
193
|
};
|
|
185
194
|
}
|
|
186
195
|
function toOutputBindingOrderType(output) {
|
|
187
196
|
return {
|
|
188
197
|
...output,
|
|
189
|
-
orderType:
|
|
198
|
+
orderType: OrderType.OutputBinding,
|
|
190
199
|
};
|
|
191
200
|
}
|
|
192
201
|
function toTwoWayBindingOrderType(output) {
|
|
193
202
|
return {
|
|
194
203
|
...output,
|
|
195
|
-
orderType:
|
|
204
|
+
orderType: OrderType.TwoWayBinding,
|
|
196
205
|
};
|
|
197
206
|
}
|
|
198
207
|
function toTemplateReferenceVariableOrderType(reference) {
|
|
199
208
|
return {
|
|
200
209
|
...reference,
|
|
201
|
-
orderType:
|
|
210
|
+
orderType: OrderType.TemplateReferenceVariable,
|
|
202
211
|
};
|
|
203
212
|
}
|
|
204
213
|
function isImplicitTemplate(node) {
|
|
@@ -271,22 +280,22 @@ function isOnSameLocation(input, output) {
|
|
|
271
280
|
function getMessageName(expected) {
|
|
272
281
|
const fullName = expected.keySpan?.details ?? expected.name;
|
|
273
282
|
switch (expected.orderType) {
|
|
274
|
-
case
|
|
283
|
+
case OrderType.StructuralDirective:
|
|
275
284
|
return `*${fullName}`;
|
|
276
|
-
case
|
|
285
|
+
case OrderType.TemplateReferenceVariable:
|
|
277
286
|
return `#${fullName}`;
|
|
278
|
-
case
|
|
287
|
+
case OrderType.InputBinding:
|
|
279
288
|
return `[${fullName}]`;
|
|
280
|
-
case
|
|
289
|
+
case OrderType.OutputBinding:
|
|
281
290
|
return `(${fullName})`;
|
|
282
|
-
case
|
|
291
|
+
case OrderType.TwoWayBinding:
|
|
283
292
|
return `[(${fullName})]`;
|
|
284
293
|
default:
|
|
285
294
|
return fullName;
|
|
286
295
|
}
|
|
287
296
|
}
|
|
288
297
|
function isValuelessStructuralDirective(attr) {
|
|
289
|
-
if (attr.orderType !==
|
|
298
|
+
if (attr.orderType !== OrderType.StructuralDirective || !attr.keySpan) {
|
|
290
299
|
return false;
|
|
291
300
|
}
|
|
292
301
|
const attrSpan = attr.sourceSpan;
|
|
@@ -305,7 +314,7 @@ function isValuelessStructuralDirective(attr) {
|
|
|
305
314
|
}
|
|
306
315
|
function getStartPos(expected) {
|
|
307
316
|
switch (expected.orderType) {
|
|
308
|
-
case
|
|
317
|
+
case OrderType.StructuralDirective:
|
|
309
318
|
return expected.sourceSpan.start.offset - 1;
|
|
310
319
|
default:
|
|
311
320
|
return expected.sourceSpan.start.offset;
|
|
@@ -313,7 +322,7 @@ function getStartPos(expected) {
|
|
|
313
322
|
}
|
|
314
323
|
function getEndPos(expected) {
|
|
315
324
|
switch (expected.orderType) {
|
|
316
|
-
case
|
|
325
|
+
case OrderType.StructuralDirective:
|
|
317
326
|
return (expected.sourceSpan.end.offset +
|
|
318
327
|
(isValuelessStructuralDirective(expected) ? 0 : 1));
|
|
319
328
|
default:
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
export type MessageIds = 'bananaInBox';
|
|
2
|
+
export declare const RULE_NAME = "banana-in-box";
|
|
3
|
+
declare const _default: import("@typescript-eslint/utils/ts-eslint").RuleModule<"bananaInBox", [], import("@typescript-eslint/utils/ts-eslint").RuleListener>;
|
|
4
|
+
export default _default;
|
|
5
|
+
//# sourceMappingURL=banana-in-box.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"banana-in-box.d.ts","sourceRoot":"","sources":["../../src/rules/banana-in-box.ts"],"names":[],"mappings":"AAKA,MAAM,MAAM,UAAU,GAAG,aAAa,CAAC;AACvC,eAAO,MAAM,SAAS,kBAAkB,CAAC;;AAKzC,wBA2CG"}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
export declare const RULE_NAME = "button-has-type";
|
|
2
|
+
export declare const INVALID_TYPE_DATA_KEY = "type";
|
|
3
|
+
export type MessageIds = 'invalidType' | 'missingType';
|
|
4
|
+
declare const _default: import("@typescript-eslint/utils/ts-eslint").RuleModule<MessageIds, [], import("@typescript-eslint/utils/ts-eslint").RuleListener>;
|
|
5
|
+
export default _default;
|
|
6
|
+
//# sourceMappingURL=button-has-type.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"button-has-type.d.ts","sourceRoot":"","sources":["../../src/rules/button-has-type.ts"],"names":[],"mappings":"AAWA,eAAO,MAAM,SAAS,oBAAoB,CAAC;AAC3C,eAAO,MAAM,qBAAqB,SAAS,CAAC;AAC5C,MAAM,MAAM,UAAU,GAAG,aAAa,GAAG,aAAa,CAAC;;AAWvD,wBAyCG"}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
export type MessageIds = 'clickEventsHaveKeyEvents';
|
|
2
|
+
export declare const RULE_NAME = "click-events-have-key-events";
|
|
3
|
+
declare const _default: import("@typescript-eslint/utils/ts-eslint").RuleModule<"clickEventsHaveKeyEvents", [], import("@typescript-eslint/utils/ts-eslint").RuleListener>;
|
|
4
|
+
export default _default;
|
|
5
|
+
//# sourceMappingURL=click-events-have-key-events.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"click-events-have-key-events.d.ts","sourceRoot":"","sources":["../../src/rules/click-events-have-key-events.ts"],"names":[],"mappings":"AASA,MAAM,MAAM,UAAU,GAAG,0BAA0B,CAAC;AACpD,eAAO,MAAM,SAAS,iCAAiC,CAAC;;AAExD,wBAwDG"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
type Options = [{
|
|
2
|
+
maxComplexity: number;
|
|
3
|
+
}];
|
|
4
|
+
export type MessageIds = 'conditionalComplexity';
|
|
5
|
+
export declare const RULE_NAME = "conditional-complexity";
|
|
6
|
+
declare const _default: import("@typescript-eslint/utils/ts-eslint").RuleModule<"conditionalComplexity", Options, import("@typescript-eslint/utils/ts-eslint").RuleListener>;
|
|
7
|
+
export default _default;
|
|
8
|
+
//# sourceMappingURL=conditional-complexity.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"conditional-complexity.d.ts","sourceRoot":"","sources":["../../src/rules/conditional-complexity.ts"],"names":[],"mappings":"AAgBA,KAAK,OAAO,GAAG,CAAC;IAAE,aAAa,EAAE,MAAM,CAAA;CAAE,CAAC,CAAC;AAC3C,MAAM,MAAM,UAAU,GAAG,uBAAuB,CAAC;AACjD,eAAO,MAAM,SAAS,2BAA2B,CAAC;;AAIlD,wBAkFG"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
type Options = [{
|
|
2
|
+
maxComplexity: number;
|
|
3
|
+
}];
|
|
4
|
+
export type MessageIds = 'cyclomaticComplexity';
|
|
5
|
+
export declare const RULE_NAME = "cyclomatic-complexity";
|
|
6
|
+
declare const _default: import("@typescript-eslint/utils/ts-eslint").RuleModule<"cyclomaticComplexity", Options, import("@typescript-eslint/utils/ts-eslint").RuleListener>;
|
|
7
|
+
export default _default;
|
|
8
|
+
//# sourceMappingURL=cyclomatic-complexity.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"cyclomatic-complexity.d.ts","sourceRoot":"","sources":["../../src/rules/cyclomatic-complexity.ts"],"names":[],"mappings":"AAOA,KAAK,OAAO,GAAG,CAAC;IAAE,aAAa,EAAE,MAAM,CAAA;CAAE,CAAC,CAAC;AAC3C,MAAM,MAAM,UAAU,GAAG,sBAAsB,CAAC;AAChD,eAAO,MAAM,SAAS,0BAA0B,CAAC;;AAIjD,wBA+CG"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
type Options = [
|
|
2
|
+
{
|
|
3
|
+
readonly allowList?: readonly string[];
|
|
4
|
+
}
|
|
5
|
+
];
|
|
6
|
+
export type MessageIds = 'elementsContent';
|
|
7
|
+
export declare const RULE_NAME = "elements-content";
|
|
8
|
+
declare const _default: import("@typescript-eslint/utils/ts-eslint").RuleModule<"elementsContent", Options, import("@typescript-eslint/utils/ts-eslint").RuleListener>;
|
|
9
|
+
export default _default;
|
|
10
|
+
//# sourceMappingURL=elements-content.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"elements-content.d.ts","sourceRoot":"","sources":["../../src/rules/elements-content.ts"],"names":[],"mappings":"AAKA,KAAK,OAAO,GAAG;IACb;QACE,QAAQ,CAAC,SAAS,CAAC,EAAE,SAAS,MAAM,EAAE,CAAC;KACxC;CACF,CAAC;AACF,MAAM,MAAM,UAAU,GAAG,iBAAiB,CAAC;AAC3C,eAAO,MAAM,SAAS,qBAAqB,CAAC;;AAa5C,wBAwDG"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import type { TSESLint } from '@typescript-eslint/utils';
|
|
2
|
+
type Options = [{
|
|
3
|
+
readonly allowNullOrUndefined?: boolean;
|
|
4
|
+
}];
|
|
5
|
+
export type MessageIds = 'eqeqeq' | 'suggestStrictEquality';
|
|
6
|
+
export declare const RULE_NAME = "eqeqeq";
|
|
7
|
+
declare const _default: TSESLint.RuleModule<MessageIds, Options, TSESLint.RuleListener>;
|
|
8
|
+
export default _default;
|
|
9
|
+
//# sourceMappingURL=eqeqeq.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"eqeqeq.d.ts","sourceRoot":"","sources":["../../src/rules/eqeqeq.ts"],"names":[],"mappings":"AAOA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,0BAA0B,CAAC;AAIzD,KAAK,OAAO,GAAG,CAAC;IAAE,QAAQ,CAAC,oBAAoB,CAAC,EAAE,OAAO,CAAA;CAAE,CAAC,CAAC;AAC7D,MAAM,MAAM,UAAU,GAAG,QAAQ,GAAG,uBAAuB,CAAC;AAC5D,eAAO,MAAM,SAAS,WAAW,CAAC;;AAGlC,wBA4EG"}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import type { TSESLint } from '@typescript-eslint/utils';
|
|
2
|
+
type Options = [
|
|
3
|
+
{
|
|
4
|
+
readonly boundTextAllowedPattern?: string;
|
|
5
|
+
readonly checkAttributes?: boolean;
|
|
6
|
+
readonly checkDuplicateId?: boolean;
|
|
7
|
+
readonly checkId?: boolean;
|
|
8
|
+
readonly checkText?: boolean;
|
|
9
|
+
readonly ignoreAttributes?: readonly string[];
|
|
10
|
+
readonly ignoreTags?: readonly string[];
|
|
11
|
+
readonly requireDescription?: boolean;
|
|
12
|
+
readonly requireMeaning?: boolean;
|
|
13
|
+
}
|
|
14
|
+
];
|
|
15
|
+
export type MessageIds = 'i18nAttribute' | 'i18nAttributeOnIcuOrText' | 'i18nCustomIdOnAttribute' | 'i18nCustomIdOnElement' | 'i18nDuplicateCustomId' | 'suggestAddI18nAttribute' | 'i18nMissingDescription' | 'i18nMissingMeaning';
|
|
16
|
+
export declare const RULE_NAME = "i18n";
|
|
17
|
+
declare const _default: TSESLint.RuleModule<MessageIds, Options, TSESLint.RuleListener>;
|
|
18
|
+
export default _default;
|
|
19
|
+
//# sourceMappingURL=i18n.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"i18n.d.ts","sourceRoot":"","sources":["../../src/rules/i18n.ts"],"names":[],"mappings":"AAkBA,OAAO,KAAK,EAAE,QAAQ,EAAY,MAAM,0BAA0B,CAAC;AA6CnE,KAAK,OAAO,GAAG;IACb;QACE,QAAQ,CAAC,uBAAuB,CAAC,EAAE,MAAM,CAAC;QAC1C,QAAQ,CAAC,eAAe,CAAC,EAAE,OAAO,CAAC;QACnC,QAAQ,CAAC,gBAAgB,CAAC,EAAE,OAAO,CAAC;QACpC,QAAQ,CAAC,OAAO,CAAC,EAAE,OAAO,CAAC;QAC3B,QAAQ,CAAC,SAAS,CAAC,EAAE,OAAO,CAAC;QAC7B,QAAQ,CAAC,gBAAgB,CAAC,EAAE,SAAS,MAAM,EAAE,CAAC;QAC9C,QAAQ,CAAC,UAAU,CAAC,EAAE,SAAS,MAAM,EAAE,CAAC;QACxC,QAAQ,CAAC,kBAAkB,CAAC,EAAE,OAAO,CAAC;QACtC,QAAQ,CAAC,cAAc,CAAC,EAAE,OAAO,CAAC;KACnC;CACF,CAAC;AACF,MAAM,MAAM,UAAU,GAClB,eAAe,GACf,0BAA0B,GAC1B,yBAAyB,GACzB,uBAAuB,GACvB,uBAAuB,GACvB,yBAAyB,GACzB,wBAAwB,GACxB,oBAAoB,CAAC;AAqBzB,eAAO,MAAM,SAAS,SAAS,CAAC;;AAiBhC,wBAqTG"}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
export type MessageIds = 'interactiveSupportsFocus';
|
|
2
|
+
export declare const RULE_NAME = "interactive-supports-focus";
|
|
3
|
+
declare const _default: import("@typescript-eslint/utils/ts-eslint").RuleModule<"interactiveSupportsFocus", [], import("@typescript-eslint/utils/ts-eslint").RuleListener>;
|
|
4
|
+
export default _default;
|
|
5
|
+
//# sourceMappingURL=interactive-supports-focus.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"interactive-supports-focus.d.ts","sourceRoot":"","sources":["../../src/rules/interactive-supports-focus.ts"],"names":[],"mappings":"AAcA,MAAM,MAAM,UAAU,GAAG,0BAA0B,CAAC;AACpD,eAAO,MAAM,SAAS,+BAA+B,CAAC;;AAEtD,wBAmEG"}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
type LabelComponent = {
|
|
2
|
+
readonly inputs?: readonly string[];
|
|
3
|
+
readonly selector: string;
|
|
4
|
+
};
|
|
5
|
+
type Options = [
|
|
6
|
+
{
|
|
7
|
+
readonly controlComponents?: readonly string[];
|
|
8
|
+
readonly labelComponents?: readonly LabelComponent[];
|
|
9
|
+
}
|
|
10
|
+
];
|
|
11
|
+
export type MessageIds = 'labelHasAssociatedControl';
|
|
12
|
+
export declare const RULE_NAME = "label-has-associated-control";
|
|
13
|
+
declare const _default: import("@typescript-eslint/utils/ts-eslint").RuleModule<"labelHasAssociatedControl", Options, import("@typescript-eslint/utils/ts-eslint").RuleListener>;
|
|
14
|
+
export default _default;
|
|
15
|
+
//# sourceMappingURL=label-has-associated-control.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"label-has-associated-control.d.ts","sourceRoot":"","sources":["../../src/rules/label-has-associated-control.ts"],"names":[],"mappings":"AAKA,KAAK,cAAc,GAAG;IACpB,QAAQ,CAAC,MAAM,CAAC,EAAE,SAAS,MAAM,EAAE,CAAC;IACpC,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAC;CAC3B,CAAC;AACF,KAAK,OAAO,GAAG;IACb;QACE,QAAQ,CAAC,iBAAiB,CAAC,EAAE,SAAS,MAAM,EAAE,CAAC;QAC/C,QAAQ,CAAC,eAAe,CAAC,EAAE,SAAS,cAAc,EAAE,CAAC;KACtD;CACF,CAAC;AACF,MAAM,MAAM,UAAU,GAAG,2BAA2B,CAAC;AACrD,eAAO,MAAM,SAAS,iCAAiC,CAAC;;AAiBxD,wBAqFG"}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import type { TSESLint } from '@typescript-eslint/utils';
|
|
2
|
+
export type MessageIds = 'mouseEventsHaveKeyEvents';
|
|
3
|
+
export declare const RULE_NAME = "mouse-events-have-key-events";
|
|
4
|
+
declare const _default: TSESLint.RuleModule<"mouseEventsHaveKeyEvents", [], TSESLint.RuleListener>;
|
|
5
|
+
export default _default;
|
|
6
|
+
//# sourceMappingURL=mouse-events-have-key-events.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"mouse-events-have-key-events.d.ts","sourceRoot":"","sources":["../../src/rules/mouse-events-have-key-events.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,0BAA0B,CAAC;AAMzD,MAAM,MAAM,UAAU,GAAG,0BAA0B,CAAC;AACpD,eAAO,MAAM,SAAS,iCAAiC,CAAC;;AAaxD,wBAuCG"}
|
|
@@ -7,12 +7,22 @@ const get_dom_elements_1 = require("../utils/get-dom-elements");
|
|
|
7
7
|
const to_pattern_1 = require("../utils/to-pattern");
|
|
8
8
|
exports.RULE_NAME = 'mouse-events-have-key-events';
|
|
9
9
|
const STYLE_GUIDE_LINK = 'https://www.w3.org/WAI/WCAG21/Understanding/keyboard';
|
|
10
|
+
var KeyEvents;
|
|
11
|
+
(function (KeyEvents) {
|
|
12
|
+
KeyEvents["Blur"] = "blur";
|
|
13
|
+
KeyEvents["Focus"] = "focus";
|
|
14
|
+
})(KeyEvents || (KeyEvents = {}));
|
|
15
|
+
var MouseEvents;
|
|
16
|
+
(function (MouseEvents) {
|
|
17
|
+
MouseEvents["MouseOut"] = "mouseout";
|
|
18
|
+
MouseEvents["MouseOver"] = "mouseover";
|
|
19
|
+
})(MouseEvents || (MouseEvents = {}));
|
|
10
20
|
exports.default = (0, create_eslint_rule_1.createESLintRule)({
|
|
11
21
|
name: exports.RULE_NAME,
|
|
12
22
|
meta: {
|
|
13
23
|
type: 'suggestion',
|
|
14
24
|
docs: {
|
|
15
|
-
description: `[Accessibility] Ensures that the mouse events \`${
|
|
25
|
+
description: `[Accessibility] Ensures that the mouse events \`${MouseEvents.MouseOut}\` and \`${MouseEvents.MouseOver}\` are accompanied by \`${KeyEvents.Focus}\` and \`${KeyEvents.Blur}\` events respectively. Coding for the keyboard is important for users with physical disabilities who cannot use a mouse, AT compatibility, and screenreader users. See more at ${STYLE_GUIDE_LINK}`,
|
|
16
26
|
},
|
|
17
27
|
schema: [],
|
|
18
28
|
messages: {
|
|
@@ -24,8 +34,8 @@ exports.default = (0, create_eslint_rule_1.createESLintRule)({
|
|
|
24
34
|
const parserServices = (0, utils_1.getTemplateParserServices)(context);
|
|
25
35
|
const domElementsPattern = (0, to_pattern_1.toPattern)([...(0, get_dom_elements_1.getDomElements)()]);
|
|
26
36
|
const eventPairs = [
|
|
27
|
-
[
|
|
28
|
-
[
|
|
37
|
+
[KeyEvents.Blur, MouseEvents.MouseOut],
|
|
38
|
+
[KeyEvents.Focus, MouseEvents.MouseOver],
|
|
29
39
|
];
|
|
30
40
|
return eventPairs.reduce((accumulator, [keyEvent, mouseEvent]) => ({
|
|
31
41
|
...accumulator,
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
export type MessageIds = 'noAny' | 'suggestRemoveAny';
|
|
2
|
+
export declare const RULE_NAME = "no-any";
|
|
3
|
+
declare const _default: import("@typescript-eslint/utils/ts-eslint").RuleModule<MessageIds, [], import("@typescript-eslint/utils/ts-eslint").RuleListener>;
|
|
4
|
+
export default _default;
|
|
5
|
+
//# sourceMappingURL=no-any.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"no-any.d.ts","sourceRoot":"","sources":["../../src/rules/no-any.ts"],"names":[],"mappings":"AAUA,MAAM,MAAM,UAAU,GAAG,OAAO,GAAG,kBAAkB,CAAC;AACtD,eAAO,MAAM,SAAS,WAAW,CAAC;;AAGlC,wBA0DG"}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
export type MessageIds = 'noAutofocus';
|
|
2
|
+
export declare const RULE_NAME = "no-autofocus";
|
|
3
|
+
declare const _default: import("@typescript-eslint/utils/ts-eslint").RuleModule<"noAutofocus", [], import("@typescript-eslint/utils/ts-eslint").RuleListener>;
|
|
4
|
+
export default _default;
|
|
5
|
+
//# sourceMappingURL=no-autofocus.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"no-autofocus.d.ts","sourceRoot":"","sources":["../../src/rules/no-autofocus.ts"],"names":[],"mappings":"AAUA,MAAM,MAAM,UAAU,GAAG,aAAa,CAAC;AACvC,eAAO,MAAM,SAAS,iBAAiB,CAAC;;AAExC,wBAsCG"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
type Options = [
|
|
2
|
+
{
|
|
3
|
+
readonly allowList?: readonly string[];
|
|
4
|
+
}
|
|
5
|
+
];
|
|
6
|
+
export type MessageIds = 'noCallExpression';
|
|
7
|
+
export declare const RULE_NAME = "no-call-expression";
|
|
8
|
+
declare const _default: import("@typescript-eslint/utils/ts-eslint").RuleModule<"noCallExpression", Options, import("@typescript-eslint/utils/ts-eslint").RuleListener>;
|
|
9
|
+
export default _default;
|
|
10
|
+
//# sourceMappingURL=no-call-expression.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"no-call-expression.d.ts","sourceRoot":"","sources":["../../src/rules/no-call-expression.ts"],"names":[],"mappings":"AAMA,KAAK,OAAO,GAAG;IACb;QACE,QAAQ,CAAC,SAAS,CAAC,EAAE,SAAS,MAAM,EAAE,CAAC;KACxC;CACF,CAAC;AACF,MAAM,MAAM,UAAU,GAAG,kBAAkB,CAAC;AAC5C,eAAO,MAAM,SAAS,uBAAuB,CAAC;;AAE9C,wBAqDG"}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
export type MessageIds = 'noDistractingElements';
|
|
2
|
+
export declare const RULE_NAME = "no-distracting-elements";
|
|
3
|
+
declare const _default: import("@typescript-eslint/utils/ts-eslint").RuleModule<"noDistractingElements", [], import("@typescript-eslint/utils/ts-eslint").RuleListener>;
|
|
4
|
+
export default _default;
|
|
5
|
+
//# sourceMappingURL=no-distracting-elements.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"no-distracting-elements.d.ts","sourceRoot":"","sources":["../../src/rules/no-distracting-elements.ts"],"names":[],"mappings":"AAKA,MAAM,MAAM,UAAU,GAAG,uBAAuB,CAAC;AACjD,eAAO,MAAM,SAAS,4BAA4B,CAAC;;AAEnD,wBAoCG"}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
type Options = [
|
|
2
|
+
{
|
|
3
|
+
readonly allowTwoWayDataBinding?: boolean;
|
|
4
|
+
readonly allowStylePrecedenceDuplicates?: boolean;
|
|
5
|
+
readonly ignore?: readonly string[];
|
|
6
|
+
}
|
|
7
|
+
];
|
|
8
|
+
export type MessageIds = 'noDuplicateAttributes' | 'suggestRemoveAttribute';
|
|
9
|
+
export declare const RULE_NAME = "no-duplicate-attributes";
|
|
10
|
+
declare const _default: import("@typescript-eslint/utils/ts-eslint").RuleModule<MessageIds, Options, import("@typescript-eslint/utils/ts-eslint").RuleListener>;
|
|
11
|
+
export default _default;
|
|
12
|
+
//# sourceMappingURL=no-duplicate-attributes.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"no-duplicate-attributes.d.ts","sourceRoot":"","sources":["../../src/rules/no-duplicate-attributes.ts"],"names":[],"mappings":"AAUA,KAAK,OAAO,GAAG;IACb;QACE,QAAQ,CAAC,sBAAsB,CAAC,EAAE,OAAO,CAAC;QAC1C,QAAQ,CAAC,8BAA8B,CAAC,EAAE,OAAO,CAAC;QAClD,QAAQ,CAAC,MAAM,CAAC,EAAE,SAAS,MAAM,EAAE,CAAC;KACrC;CACF,CAAC;AACF,MAAM,MAAM,UAAU,GAAG,uBAAuB,GAAG,wBAAwB,CAAC;AAC5E,eAAO,MAAM,SAAS,4BAA4B,CAAC;;AAOnD,wBA2IG"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
type Options = [
|
|
2
|
+
{
|
|
3
|
+
readonly allowNgStyle?: boolean;
|
|
4
|
+
readonly allowBindToStyle?: boolean;
|
|
5
|
+
}
|
|
6
|
+
];
|
|
7
|
+
export type MessageIds = 'noInlineStyles';
|
|
8
|
+
export declare const RULE_NAME = "no-inline-styles";
|
|
9
|
+
declare const _default: import("@typescript-eslint/utils/ts-eslint").RuleModule<"noInlineStyles", Options, import("@typescript-eslint/utils/ts-eslint").RuleListener>;
|
|
10
|
+
export default _default;
|
|
11
|
+
//# sourceMappingURL=no-inline-styles.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"no-inline-styles.d.ts","sourceRoot":"","sources":["../../src/rules/no-inline-styles.ts"],"names":[],"mappings":"AAOA,KAAK,OAAO,GAAG;IACb;QACE,QAAQ,CAAC,YAAY,CAAC,EAAE,OAAO,CAAC;QAChC,QAAQ,CAAC,gBAAgB,CAAC,EAAE,OAAO,CAAC;KACrC;CACF,CAAC;AAKF,MAAM,MAAM,UAAU,GAAG,gBAAgB,CAAC;AAC1C,eAAO,MAAM,SAAS,qBAAqB,CAAC;;AAE5C,wBAqEG"}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
export declare const MESSAGE_ID = "noInterpolationInAttributes";
|
|
2
|
+
export declare const RULE_NAME = "no-interpolation-in-attributes";
|
|
3
|
+
declare const _default: import("@typescript-eslint/utils/ts-eslint").RuleModule<"noInterpolationInAttributes", [], import("@typescript-eslint/utils/ts-eslint").RuleListener>;
|
|
4
|
+
export default _default;
|
|
5
|
+
//# sourceMappingURL=no-interpolation-in-attributes.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"no-interpolation-in-attributes.d.ts","sourceRoot":"","sources":["../../src/rules/no-interpolation-in-attributes.ts"],"names":[],"mappings":"AAIA,eAAO,MAAM,UAAU,gCAAgC,CAAC;AACxD,eAAO,MAAM,SAAS,mCAAmC,CAAC;;AAE1D,wBAkCG"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
export type MessageIds = 'noNegatedAsync' | 'noNegatedValueForAsync' | 'suggestFalseComparison' | 'suggestNullComparison' | 'suggestUndefinedComparison' | 'suggestUsingNonNegatedValue';
|
|
2
|
+
export declare const RULE_NAME = "no-negated-async";
|
|
3
|
+
declare const _default: import("@typescript-eslint/utils/ts-eslint").RuleModule<MessageIds, [], import("@typescript-eslint/utils/ts-eslint").RuleListener>;
|
|
4
|
+
export default _default;
|
|
5
|
+
export declare const RULE_DOCS_EXTENSION: {
|
|
6
|
+
rationale: string;
|
|
7
|
+
};
|
|
8
|
+
//# sourceMappingURL=no-negated-async.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"no-negated-async.d.ts","sourceRoot":"","sources":["../../src/rules/no-negated-async.ts"],"names":[],"mappings":"AAMA,MAAM,MAAM,UAAU,GAClB,gBAAgB,GAChB,wBAAwB,GACxB,wBAAwB,GACxB,uBAAuB,GACvB,4BAA4B,GAC5B,6BAA6B,CAAC;AAClC,eAAO,MAAM,SAAS,qBAAqB,CAAC;;AAE5C,wBA2EG;AAEH,eAAO,MAAM,mBAAmB;;CAE/B,CAAC"}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
export type MessageIds = 'noPositiveTabindex' | 'suggestNonNegativeTabindex';
|
|
2
|
+
export declare const RULE_NAME = "no-positive-tabindex";
|
|
3
|
+
declare const _default: import("@typescript-eslint/utils/ts-eslint").RuleModule<MessageIds, [], import("@typescript-eslint/utils/ts-eslint").RuleListener>;
|
|
4
|
+
export default _default;
|
|
5
|
+
//# sourceMappingURL=no-positive-tabindex.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"no-positive-tabindex.d.ts","sourceRoot":"","sources":["../../src/rules/no-positive-tabindex.ts"],"names":[],"mappings":"AAWA,MAAM,MAAM,UAAU,GAAG,oBAAoB,GAAG,4BAA4B,CAAC;AAC7E,eAAO,MAAM,SAAS,yBAAyB,CAAC;;AAEhD,wBA2CG"}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
export declare const MESSAGE_ID = "preferControlFlow";
|
|
2
|
+
export declare const RULE_NAME = "prefer-control-flow";
|
|
3
|
+
declare const _default: import("@typescript-eslint/utils/ts-eslint").RuleModule<"preferControlFlow", [], import("@typescript-eslint/utils/ts-eslint").RuleListener>;
|
|
4
|
+
export default _default;
|
|
5
|
+
//# sourceMappingURL=prefer-control-flow.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"prefer-control-flow.d.ts","sourceRoot":"","sources":["../../src/rules/prefer-control-flow.ts"],"names":[],"mappings":"AAIA,eAAO,MAAM,UAAU,sBAAsB,CAAC;AAC9C,eAAO,MAAM,SAAS,wBAAwB,CAAC;;AAE/C,wBA8BG"}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
export type MessageIds = 'missingAttribute' | 'invalidDoubleSource';
|
|
2
|
+
export declare const RULE_NAME = "prefer-ngsrc";
|
|
3
|
+
declare const _default: import("@typescript-eslint/utils/ts-eslint").RuleModule<MessageIds, [], import("@typescript-eslint/utils/ts-eslint").RuleListener>;
|
|
4
|
+
export default _default;
|
|
5
|
+
//# sourceMappingURL=prefer-ngsrc.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"prefer-ngsrc.d.ts","sourceRoot":"","sources":["../../src/rules/prefer-ngsrc.ts"],"names":[],"mappings":"AASA,MAAM,MAAM,UAAU,GAAG,kBAAkB,GAAG,qBAAqB,CAAC;AACpE,eAAO,MAAM,SAAS,iBAAiB,CAAC;;AAExC,wBA4CG"}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
export declare const MESSAGE_ID = "preferSelfClosingTags";
|
|
2
|
+
export declare const RULE_NAME = "prefer-self-closing-tags";
|
|
3
|
+
declare const _default: import("@typescript-eslint/utils/ts-eslint").RuleModule<"preferSelfClosingTags", [], import("@typescript-eslint/utils/ts-eslint").RuleListener>;
|
|
4
|
+
export default _default;
|
|
5
|
+
//# sourceMappingURL=prefer-self-closing-tags.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"prefer-self-closing-tags.d.ts","sourceRoot":"","sources":["../../src/rules/prefer-self-closing-tags.ts"],"names":[],"mappings":"AAUA,eAAO,MAAM,UAAU,0BAA0B,CAAC;AAClD,eAAO,MAAM,SAAS,6BAA6B,CAAC;;AAEpD,wBA2HG"}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
export type MessageIds = 'roleHasRequiredAria' | 'suggestRemoveRole';
|
|
2
|
+
export declare const RULE_NAME = "role-has-required-aria";
|
|
3
|
+
declare const _default: import("@typescript-eslint/utils/ts-eslint").RuleModule<MessageIds, [], import("@typescript-eslint/utils/ts-eslint").RuleListener>;
|
|
4
|
+
export default _default;
|
|
5
|
+
//# sourceMappingURL=role-has-required-aria.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"role-has-required-aria.d.ts","sourceRoot":"","sources":["../../src/rules/role-has-required-aria.ts"],"names":[],"mappings":"AAaA,MAAM,MAAM,UAAU,GAAG,qBAAqB,GAAG,mBAAmB,CAAC;AACrE,eAAO,MAAM,SAAS,2BAA2B,CAAC;;AAElD,wBA2EG"}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
export type MessageIds = 'tableScope';
|
|
2
|
+
export declare const RULE_NAME = "table-scope";
|
|
3
|
+
declare const _default: import("@typescript-eslint/utils/ts-eslint").RuleModule<"tableScope", [], import("@typescript-eslint/utils/ts-eslint").RuleListener>;
|
|
4
|
+
export default _default;
|
|
5
|
+
//# sourceMappingURL=table-scope.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"table-scope.d.ts","sourceRoot":"","sources":["../../src/rules/table-scope.ts"],"names":[],"mappings":"AAUA,MAAM,MAAM,UAAU,GAAG,YAAY,CAAC;AACtC,eAAO,MAAM,SAAS,gBAAgB,CAAC;;AAEvC,wBAuCG"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
type Options = [{
|
|
2
|
+
readonly alias: readonly string[];
|
|
3
|
+
}];
|
|
4
|
+
export type MessageIds = 'useTrackByFunction';
|
|
5
|
+
export declare const RULE_NAME = "use-track-by-function";
|
|
6
|
+
declare const _default: import("@typescript-eslint/utils/ts-eslint").RuleModule<"useTrackByFunction", Options, import("@typescript-eslint/utils/ts-eslint").RuleListener>;
|
|
7
|
+
export default _default;
|
|
8
|
+
//# sourceMappingURL=use-track-by-function.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"use-track-by-function.d.ts","sourceRoot":"","sources":["../../src/rules/use-track-by-function.ts"],"names":[],"mappings":"AAQA,KAAK,OAAO,GAAG,CAAC;IAAE,QAAQ,CAAC,KAAK,EAAE,SAAS,MAAM,EAAE,CAAA;CAAE,CAAC,CAAC;AACvD,MAAM,MAAM,UAAU,GAAG,oBAAoB,CAAC;AAC9C,eAAO,MAAM,SAAS,0BAA0B,CAAC;;AAIjD,wBAyEG"}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
export type MessageIds = 'validAria' | 'validAriaValue' | 'suggestRemoveInvalidAria';
|
|
2
|
+
export declare const RULE_NAME = "valid-aria";
|
|
3
|
+
declare const _default: import("@typescript-eslint/utils/ts-eslint").RuleModule<MessageIds, [], import("@typescript-eslint/utils/ts-eslint").RuleListener>;
|
|
4
|
+
export default _default;
|
|
5
|
+
//# sourceMappingURL=valid-aria.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"valid-aria.d.ts","sourceRoot":"","sources":["../../src/rules/valid-aria.ts"],"names":[],"mappings":"AAiBA,MAAM,MAAM,UAAU,GAClB,WAAW,GACX,gBAAgB,GAChB,0BAA0B,CAAC;AAC/B,eAAO,MAAM,SAAS,eAAe,CAAC;;AAEtC,wBAuEG"}
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import type { TmplAstElement } from '@angular-eslint/bundled-angular-compiler';
|
|
2
|
+
import type { ARIARoleRelationConceptAttribute } from 'aria-query';
|
|
3
|
+
export declare function attributesComparator(ariaRoleRelationConceptAttributes: readonly ARIARoleRelationConceptAttribute[], node: TmplAstElement): boolean;
|
|
4
|
+
//# sourceMappingURL=attributes-comparator.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"attributes-comparator.d.ts","sourceRoot":"","sources":["../../src/utils/attributes-comparator.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,0CAA0C,CAAC;AAC/E,OAAO,KAAK,EAAE,gCAAgC,EAAE,MAAM,YAAY,CAAC;AAGnE,wBAAgB,oBAAoB,CAClC,iCAAiC,EAAE,SAAS,gCAAgC,EAAE,EAC9E,IAAI,EAAE,cAAc,GACnB,OAAO,CAqBT"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"constants.d.ts","sourceRoot":"","sources":["../../src/utils/constants.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AACH,eAAO,MAAM,aAAa,eAA0B,CAAC"}
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
import { ESLintUtils } from '@typescript-eslint/utils';
|
|
2
|
+
export declare const createESLintRule: <Options extends readonly unknown[], MessageIds extends string>({ name, meta, ...rule }: Readonly<ESLintUtils.RuleWithMetaAndName<Options, MessageIds>>) => ESLintUtils.RuleModule<MessageIds, Options, ESLintUtils.RuleListener>;
|
|
3
|
+
//# sourceMappingURL=create-eslint-rule.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"create-eslint-rule.d.ts","sourceRoot":"","sources":["../../src/utils/create-eslint-rule.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,0BAA0B,CAAC;AA4BvD,eAAO,MAAM,gBAAgB,mOAG5B,CAAC"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import type { TmplAstElement } from '@angular-eslint/bundled-angular-compiler';
|
|
2
|
+
/**
|
|
3
|
+
* Extracts the attribute value.
|
|
4
|
+
* @example
|
|
5
|
+
* ```ts
|
|
6
|
+
* getAttributeValue(Element(`<div property="test"></div>`), 'nonExistent'); // null
|
|
7
|
+
* getAttributeValue(Element(`<div aria-role="none"></div>`), 'role'); // 'none'
|
|
8
|
+
* getAttributeValue(Element(`<div [attr.aria-checked]="true"></div>`), 'aria-checked'); // true
|
|
9
|
+
* getAttributeValue(Element(`<button [variant]="variant"></button>`), 'variant'); // PROPERTY
|
|
10
|
+
* ```
|
|
11
|
+
*/
|
|
12
|
+
export declare function getAttributeValue({ attributes, inputs }: TmplAstElement, attributeName: string): unknown;
|
|
13
|
+
//# sourceMappingURL=get-attribute-value.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"get-attribute-value.d.ts","sourceRoot":"","sources":["../../src/utils/get-attribute-value.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,0CAA0C,CAAC;AAU/E;;;;;;;;;GASG;AACH,wBAAgB,iBAAiB,CAC/B,EAAE,UAAU,EAAE,MAAM,EAAE,EAAE,cAAc,EACtC,aAAa,EAAE,MAAM,GACpB,OAAO,CA6BT"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"get-dom-elements.d.ts","sourceRoot":"","sources":["../../src/utils/get-dom-elements.ts"],"names":[],"mappings":"AAGA,wBAAgB,cAAc,IAAI,WAAW,CAAC,MAAM,CAAC,CAEpD"}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import type { AST, TmplAstNode } from '@angular-eslint/bundled-angular-compiler';
|
|
2
|
+
type ASTOrNodeWithParent = (AST | TmplAstNode) & {
|
|
3
|
+
parent?: ASTOrNodeWithParent;
|
|
4
|
+
};
|
|
5
|
+
export declare function getNearestNodeFrom<T extends ASTOrNodeWithParent>({ parent }: ASTOrNodeWithParent, predicate: (parent: ASTOrNodeWithParent) => parent is T): T | null;
|
|
6
|
+
export {};
|
|
7
|
+
//# sourceMappingURL=get-nearest-node-from.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"get-nearest-node-from.d.ts","sourceRoot":"","sources":["../../src/utils/get-nearest-node-from.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,GAAG,EACH,WAAW,EACZ,MAAM,0CAA0C,CAAC;AAIlD,KAAK,mBAAmB,GAAG,CAAC,GAAG,GAAG,WAAW,CAAC,GAAG;IAC/C,MAAM,CAAC,EAAE,mBAAmB,CAAC;CAC9B,CAAC;AAMF,wBAAgB,kBAAkB,CAAC,CAAC,SAAS,mBAAmB,EAC9D,EAAE,MAAM,EAAE,EAAE,mBAAmB,EAC/B,SAAS,EAAE,CAAC,MAAM,EAAE,mBAAmB,KAAK,MAAM,IAAI,CAAC,GACtD,CAAC,GAAG,IAAI,CAUV"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import type { TmplAstBoundAttribute, TmplAstTextAttribute } from '@angular-eslint/bundled-angular-compiler';
|
|
2
|
+
import { TmplAstBoundEvent } from '@angular-eslint/bundled-angular-compiler';
|
|
3
|
+
/**
|
|
4
|
+
* Returns the original attribute name.
|
|
5
|
+
* @example
|
|
6
|
+
* ```html
|
|
7
|
+
* <div [style.display.none]="test"></div> <!-- Instead of "display", "style.display.none" -->
|
|
8
|
+
* <div [attr.role]="'none'"></div> <!-- Instead of "attr.role", "role" -->
|
|
9
|
+
* <div ([ngModel])="test"></div> <!-- Instead of "ngModel", "ngModelChange" -->
|
|
10
|
+
* <div (@fade.start)="handle()"></div> <!-- Instead of "fade", "@fade.start" -->
|
|
11
|
+
* ```
|
|
12
|
+
*/
|
|
13
|
+
export declare function getOriginalAttributeName(attribute: TmplAstBoundAttribute | TmplAstBoundEvent | TmplAstTextAttribute): string;
|
|
14
|
+
//# sourceMappingURL=get-original-attribute-name.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"get-original-attribute-name.d.ts","sourceRoot":"","sources":["../../src/utils/get-original-attribute-name.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,qBAAqB,EACrB,oBAAoB,EACrB,MAAM,0CAA0C,CAAC;AAClD,OAAO,EAAE,iBAAiB,EAAE,MAAM,0CAA0C,CAAC;AAE7E;;;;;;;;;GASG;AACH,wBAAgB,wBAAwB,CACtC,SAAS,EAAE,qBAAqB,GAAG,iBAAiB,GAAG,oBAAoB,GAC1E,MAAM,CAYR"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"is-child-node-of.d.ts","sourceRoot":"","sources":["../../src/utils/is-child-node-of.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,MAAM,0CAA0C,CAAC;AAE1E,wBAAgB,aAAa,CAC3B,GAAG,EAAE,cAAc,EACnB,aAAa,EAAE,MAAM,GACpB,OAAO,CAUT"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"is-content-editable.d.ts","sourceRoot":"","sources":["../../src/utils/is-content-editable.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,0CAA0C,CAAC;AAI/E,wBAAgB,iBAAiB,CAAC,IAAI,EAAE,cAAc,GAAG,OAAO,CAW/D"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"is-disabled-element.d.ts","sourceRoot":"","sources":["../../src/utils/is-disabled-element.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,0CAA0C,CAAC;AAI/E,wBAAgB,iBAAiB,CAAC,IAAI,EAAE,cAAc,GAAG,OAAO,CAkB/D"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { TmplAstElement } from '@angular-eslint/bundled-angular-compiler';
|
|
2
|
+
/**
|
|
3
|
+
* Whether an element content cannot be read by a screen reader. It can happen in the following situations:
|
|
4
|
+
* - It has `display: none` or `visibility: hidden` style;
|
|
5
|
+
* - It has `aria-hidden` or `hidden` attribute;
|
|
6
|
+
* - It's an `<input type="hidden">`;
|
|
7
|
+
* - One of its ancestors met one of the following situations above.
|
|
8
|
+
*/
|
|
9
|
+
export declare function isHiddenFromScreenReader(node: TmplAstElement): boolean;
|
|
10
|
+
//# sourceMappingURL=is-hidden-from-screen-reader.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"is-hidden-from-screen-reader.d.ts","sourceRoot":"","sources":["../../src/utils/is-hidden-from-screen-reader.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,MAAM,0CAA0C,CAAC;AAI1E;;;;;;GAMG;AACH,wBAAgB,wBAAwB,CAAC,IAAI,EAAE,cAAc,GAAG,OAAO,CAyBtE"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
interface AXObjectSchema {
|
|
2
|
+
name: string;
|
|
3
|
+
attributes?: {
|
|
4
|
+
name: string;
|
|
5
|
+
value?: string;
|
|
6
|
+
}[];
|
|
7
|
+
}
|
|
8
|
+
export declare function getInteractiveElementAXObjectSchemas(): AXObjectSchema[];
|
|
9
|
+
export {};
|
|
10
|
+
//# sourceMappingURL=get-interactive-element-ax-object-schemas.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"get-interactive-element-ax-object-schemas.d.ts","sourceRoot":"","sources":["../../../src/utils/is-interactive-element/get-interactive-element-ax-object-schemas.ts"],"names":[],"mappings":"AAEA,UAAU,cAAc;IACtB,IAAI,EAAE,MAAM,CAAC;IACb,UAAU,CAAC,EAAE;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,KAAK,CAAC,EAAE,MAAM,CAAA;KAAE,EAAE,CAAC;CACjD;AAQD,wBAAgB,oCAAoC,IAAI,cAAc,EAAE,CA+BvE"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"get-interactive-element-role-schemas.d.ts","sourceRoot":"","sources":["../../../src/utils/is-interactive-element/get-interactive-element-role-schemas.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAEV,uBAAuB,EACxB,MAAM,YAAY,CAAC;AASpB,wBAAgB,gCAAgC,IAAI,uBAAuB,EAAE,CAuC5E"}
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import type { ARIARoleDefinitionKey, ARIARoleRelationConcept } from 'aria-query';
|
|
2
|
+
export declare function getNonInteractiveElementRoleSchemas(): ARIARoleRelationConcept[];
|
|
3
|
+
export declare function getNonInteractiveRoles(): Set<ARIARoleDefinitionKey>;
|
|
4
|
+
//# sourceMappingURL=get-non-interactive-element-role-schemas.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"get-non-interactive-element-role-schemas.d.ts","sourceRoot":"","sources":["../../../src/utils/is-interactive-element/get-non-interactive-element-role-schemas.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,qBAAqB,EACrB,uBAAuB,EACxB,MAAM,YAAY,CAAC;AAWpB,wBAAgB,mCAAmC,IAAI,uBAAuB,EAAE,CAgB/E;AAED,wBAAgB,sBAAsB,IAAI,GAAG,CAAC,qBAAqB,CAAC,CAyBnE"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import type { TmplAstElement } from '@angular-eslint/bundled-angular-compiler';
|
|
2
|
+
/**
|
|
3
|
+
* Returns boolean indicating whether the given element is
|
|
4
|
+
* interactive on the DOM or not. Usually used when an element
|
|
5
|
+
* has a dynamic handler on it and we need to discern whether or not
|
|
6
|
+
* it's intention is to be interacted with on the DOM.
|
|
7
|
+
*/
|
|
8
|
+
export declare function isInteractiveElement(node: TmplAstElement): boolean;
|
|
9
|
+
export declare function isNonInteractiveRole(node: TmplAstElement): boolean;
|
|
10
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/utils/is-interactive-element/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,0CAA0C,CAAC;AAwC/E;;;;;GAKG;AACH,wBAAgB,oBAAoB,CAAC,IAAI,EAAE,cAAc,GAAG,OAAO,CAElE;AAED,wBAAgB,oBAAoB,CAAC,IAAI,EAAE,cAAc,GAAG,OAAO,CAElE"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"is-presentation-role.d.ts","sourceRoot":"","sources":["../../src/utils/is-presentation-role.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,0CAA0C,CAAC;AAQ/E,wBAAgB,kBAAkB,CAAC,IAAI,EAAE,cAAc,GAAG,OAAO,CAMhE"}
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
import type { TmplAstBoundAttribute, TmplAstTextAttribute } from '@angular-eslint/bundled-angular-compiler';
|
|
2
|
+
export declare function isSemanticRoleElement(element: string, role: string, elementAttributes: (TmplAstTextAttribute | TmplAstBoundAttribute)[]): boolean;
|
|
3
|
+
//# sourceMappingURL=is-semantic-role-element.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"is-semantic-role-element.d.ts","sourceRoot":"","sources":["../../src/utils/is-semantic-role-element.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,qBAAqB,EACrB,oBAAoB,EACrB,MAAM,0CAA0C,CAAC;AAalD,wBAAgB,qBAAqB,CACnC,OAAO,EAAE,MAAM,EACf,IAAI,EAAE,MAAM,EACZ,iBAAiB,EAAE,CAAC,oBAAoB,GAAG,qBAAqB,CAAC,EAAE,GAClE,OAAO,CA+BT"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"to-pattern.d.ts","sourceRoot":"","sources":["../../src/utils/to-pattern.ts"],"names":[],"mappings":"AAAA,wBAAgB,SAAS,CAAC,KAAK,EAAE,SAAS,OAAO,EAAE,GAAG,MAAM,CAE3D"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@angular-eslint/eslint-plugin-template",
|
|
3
|
-
"version": "17.
|
|
3
|
+
"version": "17.4.0",
|
|
4
4
|
"description": "ESLint plugin for Angular Templates",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"main": "dist/index.js",
|
|
@@ -12,15 +12,16 @@
|
|
|
12
12
|
},
|
|
13
13
|
"files": [
|
|
14
14
|
"dist",
|
|
15
|
+
"!**/*.tsbuildinfo",
|
|
15
16
|
"package.json",
|
|
16
17
|
"README.md",
|
|
17
18
|
"LICENSE"
|
|
18
19
|
],
|
|
19
20
|
"dependencies": {
|
|
20
|
-
"@angular-eslint/bundled-angular-compiler": "17.
|
|
21
|
-
"@angular-eslint/utils": "17.
|
|
22
|
-
"@typescript-eslint/type-utils": "7.
|
|
23
|
-
"@typescript-eslint/utils": "7.
|
|
21
|
+
"@angular-eslint/bundled-angular-compiler": "17.4.0",
|
|
22
|
+
"@angular-eslint/utils": "17.4.0",
|
|
23
|
+
"@typescript-eslint/type-utils": "7.8.0",
|
|
24
|
+
"@typescript-eslint/utils": "7.8.0",
|
|
24
25
|
"aria-query": "5.3.0",
|
|
25
26
|
"axobject-query": "4.0.0"
|
|
26
27
|
},
|