GeoloeG / iron-swipeable-pages

[Polymer 1.x] Element that enables switching between different pages by swiping gesture.
MIT License
49 stars 25 forks source link

Using the element inside a portion of screen doesn't seem to size correctly, origin is always left screen's edge. #66

Open Thkasis opened 6 years ago

Thkasis commented 6 years ago

First great work , thanks. I have a little problem with getting it to size correctly inside a portion of the screen . The element is nested inside a div "position : relative". Upon load the _onResize() returns a false value. If I change the screen size a bit the _onResize() runs again and returns the correct value. So far I understand what the problem might be, but I cant get the origin of where the element is sized from to be relative to parent div. It's always the left edge of screen.

I see it even in the demo with drawer. the right side has a gap that is way beyond the edgeSwipeSensitivity and its because of the drawer panel that has shifted the origin; however, swipeable-pages still assumes origin or 0.

Hope it's clear what I am saying.