Conditionally render labels button when media exists in post (#5942)
* conditionally render button * update labels on remove * tweak
This commit is contained in:
@@ -896,13 +896,14 @@ function ComposerPills({
|
||||
style={bottomBarAnimatedStyle}
|
||||
/>
|
||||
)}
|
||||
<LabelsBtn
|
||||
labels={draft.labels}
|
||||
onChange={nextLabels => {
|
||||
dispatch({type: 'update_labels', labels: nextLabels})
|
||||
}}
|
||||
hasMedia={hasMedia || hasLink}
|
||||
/>
|
||||
{hasMedia || hasLink ? (
|
||||
<LabelsBtn
|
||||
labels={draft.labels}
|
||||
onChange={nextLabels => {
|
||||
dispatch({type: 'update_labels', labels: nextLabels})
|
||||
}}
|
||||
/>
|
||||
) : null}
|
||||
</ScrollView>
|
||||
</Animated.View>
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user