0

Before implementing Texture/AsyncDisplayKit, I used a negative bottom space constraint to have a background image overflow from the collection view header. This caused the header element to appear like it was underneath first row of collection view cells.

enter image description here

I cannot figure out how to do this with layoutSpecThatFits in Texture. So, is it possible or will I have to find a completely different way to show this overlapping header element?

ciffa
  • 39
  • 2
  • 8
  • Sorry, didn't understand, do you try to do sticky header or what? – Bimawa Jan 26 '18 at 03:37
  • No. I've added an image as an example. I what that header with the text to disappear when scolling, like section headers do. And that works fine, but I cannot figure how to get the image to appear behind the first row of cells. – ciffa Jan 26 '18 at 06:41
  • Its looks like you want add blue image under CollectionView, right? – Bimawa Jan 26 '18 at 10:50
  • Yes, and that blue image moves with the content. Not a sticky background. – ciffa Jan 26 '18 at 13:47
  • Its looks like custom `UICollectionViewLayout`. But you can do `ASBackgroundLayoutSpec` for layout Blue Node under ASCollectionNode, and overwrite `layout` property for stop calculation when u scrolling collectionNode, and do offset by manually. – Bimawa Jan 27 '18 at 10:27
  • Other advies, if u want change dynamically frame, u always can overwrite layout method, for disable ADK calculation – Bimawa Jan 28 '18 at 11:31
  • Ok, I think I understand. Thanks for the advice. – ciffa Jan 29 '18 at 06:37

0 Answers0