File tree Expand file tree Collapse file tree 1 file changed +6
-7
lines changed Expand file tree Collapse file tree 1 file changed +6
-7
lines changed Original file line number Diff line number Diff line change @@ -384,22 +384,21 @@ const ExpandableCalendar = (props: ExpandableCalendarProps) => {
384384 _height . current = toValue || newValue ;
385385 _isOpen = _height . current >= threshold ; // re-check after _height.current was set
386386
387+ resetWeekCalendarOpacity ( _isOpen ) ;
387388 Animated . spring ( deltaY , {
388389 toValue : _height . current ,
389390 speed : SPEED ,
390391 bounciness : BOUNCINESS ,
391392 useNativeDriver : false
392- } ) . start ( ) ;
393-
394- onCalendarToggled ?.( _isOpen ) ;
395-
396- setPosition ( ( ) => _height . current === closedHeight ? Positions . CLOSED : Positions . OPEN ) ;
393+ } ) . start ( ( ) => {
394+ onCalendarToggled ?.( _isOpen ) ;
395+ setPosition ( ( ) => _height . current === closedHeight ? Positions . CLOSED : Positions . OPEN ) ;
396+ } ) ;
397397 closeHeader ( _isOpen ) ;
398- resetWeekCalendarOpacity ( _isOpen ) ;
399398 }
400399 } ;
401400
402- const resetWeekCalendarOpacity = ( isOpen : boolean ) => {
401+ const resetWeekCalendarOpacity = async ( isOpen : boolean ) => {
403402 _weekCalendarStyles . style . opacity = isOpen ? 0 : 1 ;
404403 updateNativeStyles ( ) ;
405404 } ;
You can’t perform that action at this time.
0 commit comments