code: private void applyFullImageState(float position, boolean isLeaving) {
          views.fullBackground.setVisibility(position == 0f ? View.INVISIBLE : View.VISIBLE);
          views.fullBackground.setAlpha(position);
  
          views.fullImageToolbar.setVisibility(position == 0f ? View.INVISIBLE : View.VISIBLE);
          views.fullImageToolbar.setAlpha(position);
  
          views.fullImage.setVisibility(position == 0f && isLeaving
                  ? View.INVISIBLE : View.VISIBLE);
      }
docs: Applying top image animation state: fading out toolbar and background.