Hero Animation in polymer 1.0

♀尐吖头ヾ 提交于 2019-12-03 15:46:04
Dimitriy Mospanenko
  1. You are using wrong behavior. NeonAnimationRunnerBehavior is for components who play or run the animation inside themselves. Very good example will be neon-animated-pages component, it implements NeonAnimationRunnerBehavior because it runs animations inside.

  2. Every item which placed in neon-animated-pages has to implement NeonAnimatableBehavior, not NeonAnimationRunnerBehavior.

  3. To run the animation we have to switch somehow between our animatable components. The "selected" attribute of neon-animated-pages help us with that. When selected = "0" neon-animated-pages shows you name-tag, when selected = "1" neon-animated-pages shows you name-tag1 component.

  4. You want to change view after click but I don't see any click event listeners. Add click events which will change selected attribute value and it'll work.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!