Ion-scroll missing functionality? (ionic 2 - beta.11)

Hello,
I am trying to use ion-scroll, and I would like to

  • display an image (this works)
  • scroll the image (this works)
  • zoom the image (this does not work)
  • programmatically set scroll x/y (i.e. scroll it to 100/100), (is functionality is apparently not implemented)

There appears to be no function to set the scrolling x,y programmatically.

This is my code:

  <ion-scroll scrollX="true" scrollY="true" zoom="true" style="width: 100%; height: 100%">
    <div [style.width]="width+'px'" [style.height]="height+'px'" [style.background]="imageUrl"</div>
  </ion-scroll>

Does anyone know why

  1. zooming is not working?
  2. if there will be the option to programmatically set the scrolling x,y and perhaps the zooming too.

Many thanks,
Philipp

  1. Your image isn’t an image but a css background. Try with an img instead of background-image and change image style with document.getElementById("youImageId").height...

  2. Is x,y the ration of the scrolled content in ion-scroll ?

x,y are pixels.

I ended up using the javascript d3 library to do the zooming and scrolling of a photo.