Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Create Icon component #26

Open
wants to merge 3 commits into
base: main
Choose a base branch
from
Open

Create Icon component #26

wants to merge 3 commits into from

Conversation

Brunonascdev
Copy link
Contributor

Addresses issue #10

This PR add a Icon component that can be used like this:

<Icon.Activity size={32} color="#fff" />

The icons were imported from the SDS.

Samples:

@Brunonascdev Brunonascdev added the enhancement New feature or request label Mar 6, 2025
@Brunonascdev Brunonascdev self-assigned this Mar 6, 2025
@Brunonascdev Brunonascdev requested a review from piyalbasu March 6, 2025 19:22
Comment on lines +2365 to +2366
width: ${({ size }: { size: number }) => size * 1.5}px;
height: ${({ size }: { size: number }) => size * 1.5}px;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we should wrap those with px() instead of the inline px string so it resizes accordingly.

}

const iconElement = (
<IconSvg width={size} height={size} color={color} testID={testID} />
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

same thing here, I think we should do pxValue(size) to resize accordingly

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

my bad! I forgot about this function

Copy link
Contributor

@CassioMG CassioMG left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Aside from the missing px() and pxValue() wrappers - LGTM!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants