Skip to content

Text Color

Use text-{color} utilities like text-blue-600 and text-sky-400 to control the text color of an element.


Use utilities like text-blue-600 and text-sky-400 to control the text color of an element:

Style('text-blue-600', child: Text('The quick brown fox...'))

Use the color opacity modifier to control the text color opacity of an element:

Style('text-blue-600/100', child: Text('The quick brown fox...'))
Style('text-blue-600/75', child: Text('The quick brown fox...'))
Style('text-blue-600/50', child: Text('The quick brown fox...'))
Style('text-blue-600/25', child: Text('The quick brown fox...'))

Hover over the link to see the text color change:

Style('...', children: [
Text('Oh I gotta get on that '),
Style('underline hover:text-blue-600', child: Text('internet')),
Text(", I'm late on everything!"),
])
ClassDescription
text-{color}-{shade}Sets text color (e.g. text-blue-500)
text-{color}-{shade}/{opacity}Sets text color with opacity (e.g. text-blue-500/50)
text-blackBlack text
text-whiteWhite text
text-transparentTransparent text
text-[<value>]Arbitrary hex value (e.g. text-[#243c5a])