Bluesky app fork with some witchin' additions 💫

Fix collapsed button by simplifying, keep container width (#9712)

authored by samuel.fm and committed by

GitHub 9c563f2a 1d426307

+5 -4
+5 -4
src/screens/PostThread/components/GrowthHack.tsx
··· 33 33 a.relative, 34 34 a.justify_center, 35 35 align === 'right' ? a.align_end : a.align_start, 36 - width === undefined ? {opacity: 0} : {minWidth: width}, 36 + {minWidth: width ?? iconSizes[ICON_SIZE]}, 37 37 ]}> 38 38 <PrivacySensitive 39 39 style={[ ··· 46 46 // when finding the size of the button, we need the containing 47 47 // element to have a concrete size otherwise the text will 48 48 // collapse to 0 width. so set it to a really big number 49 - // and hide the entire thing (see above) 50 - width === undefined && {width: 10000}, 49 + // and just use `pointer-events: box-none` so it doesn't interfere with the UI 50 + {width: 1000}, 51 + a.pointer_events_box_none, 51 52 ]}> 52 53 <View 53 54 onLayout={evt => setWidth(evt.nativeEvent.layout.width)} 54 55 style={[ 55 56 t.atoms.bg, 56 - // make sure it covers the icon! the won't always be a button 57 + // make sure it covers the icon! children might be undefined 57 58 {minWidth: iconSizes[ICON_SIZE], minHeight: iconSizes[ICON_SIZE]}, 58 59 ]}> 59 60 {children}