Hello,
Is there a way I can add an icon in a tab?
Label the tab an icon instead of “Events”.
If you hover over the tabs
property, you can see that we allow for Views to be used there, so yes, you can use an Icon.
To do this:
- Create a small View (probably with a Flex layout with dimensions of 30x30) which contains your Icon; we will call this “ViewA”
- Right-click the
1
withintabs
and select “Change to” > “Object”. - Add a new property to this object with a key of
viewPath
. - Supply the path to ViewA as the value for viewPath.
Thanks.I’ve solved my problem.
When you add an icon to the tab: Is it possible to also get the same background color as the default tab color? That will change according to the theme colors?
Did you set the icon's view background to transparent? Add in,
PROPS.style.backgroundColor : #77777700
The four hex bytes define RGBA where 'A' is the opacity.