Skip to main content
Question

Code Connect property disappears in Simple Design System button example

  • August 22, 2024
  • 1 reply
  • 58 views

Roozemond

The excellent code connect example repo provides a button with conditional icons. I’ve noticed that the label of the button disappears when you select an icon.

Without Icon

With Icon

I would expect it to look like:

<Button onPress={() => {}} variant="primary" size="small">
  <Star />
  Button
</Button>

If you wrap the label in something it works fine, so I guess it’s a bug?

example: ({ label, hierarchy, iconStart, iconEnd, isDisabled }) => (
      <Button variant={hierarchy} disabled={isDisabled}>
        {iconStart}
        <>{label}</>
        {iconEnd}
      </Button>
    ),

image

1 reply

y_toku
Figmate
  • Community Support
  • 2317 replies
  • August 27, 2024

Hi there,

Thanks for reaching out. I’m checking with our internal team. I will get back to you when I have anything I can share with you.

Thanks for your patience.
Toku


Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings