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 TextWithIcon component #3590
Conversation
ABA-293 Create TextWithIcon component
At the moment, we have the same layout of having an icon next to some textual content. Therefore, this should be generalized into a separate component that can be used throughout the webapp. An example of usage: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice to standardize stuff like this 💯 Just fix up in Olav's comment and we should be good here
To generalize the usage of text together with icons. At the moment we have a lot of different ways of doing this.
01cae5a
to
76e6d63
Compare
Previously it could only be ReactElement, but it should also accept a simple string for simplicity reasons.
76e6d63
to
8e273b7
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good now!
Description
Text is displayed with icons throughout the whole webapp. However, there is no component or common way of doing this. With the
<TextWithIcon />
component there is now a generalized component that can be used for this purpose. An example of usage can be seen here:There should be no visual changes to the text with icons.
Also fixes some TS errors and moves the tooltip on
<EventDetail />
to be on the icon rather than the text.Result
Before
After
Testing
Tested by clicking through where changes have been done.
Resolves ABA-293