+ Start a Discussion
JeriMorrisJeriMorris 

Scrolling in a VF page for Salesforce1

I have a VF page that is used only in Salesforce1. The page displays a list of items that is longer than the screen. When I view the page from a mobile device, I can scroll it, but the scrolling performance is different from that of a regular page in Salesforce1. In a native Salesforce1 page, when I swipe up or down quickly, the page keeps scrolling for a while even after my finger is off the screen. How do I get my VF page to scroll the same way?
logontokartiklogontokartik
I am not sure if I understand your request,  your page is scrolling but it doesnt do when you scroll quickly? Do you want a delay in your scroll? There are many JS libraries / snippets out for Scroll delays, you can try those if thats what you need
JeriMorrisJeriMorris
In a standard SF1 page, when I swipe my finger up and down quickly, then lift my finger up (kind of a "flick" gesture), the page continues to scroll even after I lift my finger up, eventually slowing down to a stop. This is a nice behavior that a lot of apps, including SF1 have.

In my VF page on SF1, the page scrolls when I drag my finger up and down the screen, but the "flick" behavior described above doesn't happen. The page stops scrolling the minute I lift my finger.

I know I can find a JavaScript library out there to implement my own "flick" behavior, but I was hoping that Salesforce provided that behavior, maybe though the Mobile Design Templates. It seems silly to think that everyone who develops a VF page for SF1 would have to find and add their own JavaScript library to implement what is standard behavior on standard SF1 pages.

Look at it this way: for regular (non-SF1) VF pages, Salesforce doesn't expect us to implement our own input text box - they provide us with components like <apex:inputField>. Why aren't there other convenience components like that for SF1?