Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

scrollToElement doesn't work in Android #14

Closed
Jinjiang opened this issue Apr 17, 2016 · 1 comment
Closed

scrollToElement doesn't work in Android #14

Jinjiang opened this issue Apr 17, 2016 · 1 comment
Assignees

Comments

@Jinjiang
Copy link
Contributor

code example:

<template>
  <scroller>
    <text id="top" style="height: 10000;">Hello, World!</text>
    <text onclick="gotoTop">Goto top</text>
  </scroller>
</template>

<script>
  var dom = require('@weex-module/dom')
  module.exports = {
    methods: {
      gotoTop: function () {
        var top = this.$el('top')
        dom.scrollToElement(top)
      }
    }
  }
</script>
@YorkShen
Copy link
Contributor

The method in Android expected to receive two parameter when invoking scrollToElement()method, if only one parameter is given, nothing will happen.

This issue has fixed. The second will be 0 if only one parameter is given

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants