聚合物纸卡霓虹动画焦点

时间:2016-08-29 12:46:18

标签: polymer-1.0

我正在使用纸质卡片,其中包含调查的每个元素,该元素由霓虹动画页面包裹。当我有一个很长的问题或有多个答案并且必须在电话上向下滚动时,当我切换到下一个更短的问题时,由于你必须向下导航而离开屏幕。我如何专注于顶部?特别是因为我所使用的代码目前正在我要离开的卡上运行,而不是我正在导航的卡。

<neon-animated-pages id="views" class="flex" selected="0" entry-animation="slide-from-right-animation" exit-animation="slide-left-animation">
   <template is="dom-repeat" id="surveyquestions" items="{{survey.Questions}}" sort="_sort">
       <template is="dom-if" restamp if="{{isFormat(item.Type, 'Single-Select')}}" >
          <question-singleselect question="{{item}}" auth-Data="{{authData}}"></question-singleselect>
       </template>
        ....
    </template>
</neon-animated-pages>

1 个答案:

答案 0 :(得分:0)

在搜索了很久之后,实际上找到了....我尝试这样做,但与实际的元素,但这是有效的。     document.getElementById(“mainContainer”)。scrollTop = 0

相关问题