Last active
July 8, 2018 20:01
-
-
Save bogoslavskiy/a78d5e1d83d511c7646ea73c5fecd9a5 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
scrollToOffset(offset, animated) { | |
if(offset != this.scrollY._value) { | |
this.initialState.scrollToOffset({offset, animated}); | |
} | |
} | |
minimizeBar = () => { | |
if(Math.round(this.scrollY._value) == 0) { // Full | |
this.scrollToOffset(this.topPartHeight); | |
} else { // Clamped | |
// ??? | |
} | |
}; | |
expandBar = () => { | |
if(this.stateBarTypes.EXPANDED == this.stateBar) { | |
return; | |
} | |
if(Math.round(this.scrollY._value) == this.topPartHeight) { // Full | |
this.scrollToOffset(0); | |
} else { // Clamped | |
// ??? | |
} | |
}; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment