Skip to content

Commit 9745b61

Browse files
authored
fixed typo in each loop animation error (#5648)
1 parent 80300f9 commit 9745b61

File tree

5 files changed

+8
-8
lines changed

5 files changed

+8
-8
lines changed

src/compiler/compile/nodes/Animation.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ export default class Animation extends Node {
2727
// TODO can we relax the 'immediate child' rule?
2828
component.error(this, {
2929
code: 'invalid-animation',
30-
message: 'An element that use the animate directive must be the immediate child of a keyed each block'
30+
message: 'An element that uses the animate directive must be the immediate child of a keyed each block'
3131
});
3232
}
3333

src/compiler/compile/nodes/EachBlock.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ export default class EachBlock extends AbstractBlock {
6161
const child = this.children.find(child => !!(child as Element).animation);
6262
component.error((child as Element).animation, {
6363
code: 'invalid-animation',
64-
message: 'An element that use the animate directive must be the sole child of a keyed each block'
64+
message: 'An element that uses the animate directive must be the sole child of a keyed each block'
6565
});
6666
}
6767
}

test/validator/samples/animation-not-in-each/errors.json

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[{
22
"code": "invalid-animation",
3-
"message": "An element that use the animate directive must be the immediate child of a keyed each block",
3+
"message": "An element that uses the animate directive must be the immediate child of a keyed each block",
44
"start": {
55
"line": 5,
66
"column": 5,
@@ -12,4 +12,4 @@
1212
"character": 55
1313
},
1414
"pos": 44
15-
}]
15+
}]

test/validator/samples/animation-not-in-keyed-each/errors.json

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[{
22
"code": "invalid-animation",
3-
"message": "An element that use the animate directive must be the immediate child of a keyed each block",
3+
"message": "An element that uses the animate directive must be the immediate child of a keyed each block",
44
"start": {
55
"line": 6,
66
"column": 6,
@@ -12,4 +12,4 @@
1212
"character": 80
1313
},
1414
"pos": 69
15-
}]
15+
}]

test/validator/samples/animation-siblings/errors.json

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[{
22
"code": "invalid-animation",
3-
"message": "An element that use the animate directive must be the sole child of a keyed each block",
3+
"message": "An element that uses the animate directive must be the sole child of a keyed each block",
44
"start": {
55
"line": 6,
66
"column": 6,
@@ -12,4 +12,4 @@
1212
"character": 88
1313
},
1414
"pos": 77
15-
}]
15+
}]

0 commit comments

Comments
 (0)