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

disableDrag property not used #232

Open
jarrodek opened this issue Aug 15, 2018 · 1 comment
Open

disableDrag property not used #232

jarrodek opened this issue Aug 15, 2018 · 1 comment

Comments

@jarrodek
Copy link

Description

The disableDrag property is not used anywhere in the code and therefore it is not working as intended.
I believe that _scroll() function supposed to have the following condition but it is missing.

_scroll: function(e, detail) {
  if (!this.scrollable || this.disableDrag) {
    return;
  }
  ...
},

Expected outcome

Tabs are not scrolling when used in the following way:

<paper-tabs scrollable disable-drag>
   ...
</paper-tabs>

Actual outcome

You can still drag the tabs. It is a problem when you implement your own draggable tabs so you can rearrange pages.

Steps to reproduce

  1. Create enough tabs so they won't fit into the available area.
  2. Set both scrollable and disable-drag attributes or corresponding properties.
  3. Drag the list of tabs

Browsers Affected

It's not dependent on browser.

@jarrodek
Copy link
Author

Just as a workaround:

<paper-tabs scrollable disable-drag id="tabs">
   ...
</paper-tabs>
connectedCallback() {
  super.connectedCallback();
  this.$.tabs._scroll = function() {};
}

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

No branches or pull requests

1 participant