|
|
|
@ -26,12 +26,17 @@ export default class Animation extends Node {
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
const block = parent.parent;
|
|
|
|
const block = parent.parent;
|
|
|
|
if (!block || block.type !== 'EachBlock' || !block.key) {
|
|
|
|
if (!block || block.type !== 'EachBlock') {
|
|
|
|
// TODO can we relax the 'immediate child' rule?
|
|
|
|
// TODO can we relax the 'immediate child' rule?
|
|
|
|
component.error(this, compiler_errors.invalid_animation_immediate);
|
|
|
|
component.error(this, compiler_errors.invalid_animation_immediate);
|
|
|
|
return;
|
|
|
|
return;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (block && block.type === 'EachBlock' && !block.key) {
|
|
|
|
|
|
|
|
component.error(this, compiler_errors.invalid_animation_key);
|
|
|
|
|
|
|
|
return;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
(block as EachBlock).has_animation = true;
|
|
|
|
(block as EachBlock).has_animation = true;
|
|
|
|
|
|
|
|
|
|
|
|
this.expression = info.expression
|
|
|
|
this.expression = info.expression
|
|
|
|
|