nativescript-cradleTabBar icon indicating copy to clipboard operation
nativescript-cradleTabBar copied to clipboard

Circle Button kind of "off" on iPad

Open maxlam79 opened this issue 4 years ago • 1 comments

When running on iPad, the circle button seems "off" when it is panned to right or to the left. Index 2 (middle) is fine...

Screenshot 2020-12-13 at 5 49 55 PM

My work around was:

getTabTranslateX(index: number): number {
    //return index * screen.mainScreen.widthDIPs / this.tabList.length - (screen.mainScreen.widthDIPs / 2) + (80 / 2);
    const ratio = 5.1375;

    return index * screen.mainScreen.widthDIPs / this.tabList.length - ( screen.mainScreen.widthDIPs / 2 ) + ( ( screen.mainScreen.widthDIPs / ratio ) / 2 )
  }

maxlam79 avatar Dec 13 '20 10:12 maxlam79

@maxlam79 Thanks, for reporting this and providing a workaround. I'll update the code to take into account ipad screen sizes

williamjuan027 avatar Dec 15 '20 13:12 williamjuan027