Button press and unpress affecting adjacent button's shade #938
Unanswered
mandar-saiyan87
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi,
I have created 3 individual buttons placed next to each other and applied touchopacity to change color after press.
code for button "Man":
`export const Man = ({ isActive }: { isActive: boolean }) => {
return (
<Canvas style={{ width: 80, height: 70 }}>
<Box box={rrect(rect(0, 0, 65, 60), 5, 5)} color="white">
{isActive ?
: }
<Text tw={'absolute p-5'}>Man
)
}`
Putting code screeshot as well because preview is showing incomplete code
Similarly I have created individual button for "Woman" and "Other"
On press button looks like this
But after unpressing it, it's creating an extra shadow around adjacent button like below
Similarly if i press Woman and unpress it, it's creating extra shadow around "Other"
Not able to undestand what is happening because all the buttons are created individually.
Beta Was this translation helpful? Give feedback.
All reactions