pull/6194/head
Simon H 5 years ago committed by GitHub
parent f4598e5463
commit 506a1d0395
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -21,13 +21,15 @@ export default class Animation extends Node {
component.add_reference(info.name.split('.')[0]);
if (parent.animation) {
return component.error(this, compiler_errors.duplicate_animation);
component.error(this, compiler_errors.duplicate_animation);
return;
}
const block = parent.parent;
if (!block || block.type !== 'EachBlock' || !block.key) {
// TODO can we relax the 'immediate child' rule?
return component.error(this, compiler_errors.invalid_animation_immediate);
component.error(this, compiler_errors.invalid_animation_immediate);
return;
}
(block as EachBlock).has_animation = true;

Loading…
Cancel
Save