import 'package:resource/theme.dart';
Ex: Text("Card header", style: context.cardHeader)
Ex: Text("Card title", style: context.cardTitle)
Ex: Text("Body text"),
Ex: Text("Highlight Text", style: Theme.of(context).textTheme.labelLarge)
- Small price => textStyle.priceSmall
- Medium price => textStyle.priceMedium
- Large price => textStyle.priceLarge Ex: Text("123.000.VND", style: context.priceText.priceMedium)
- Notice, error color => textStyle.notice
- Primary color => textStyle.primary
- On primary color => textStyle.onPrimary
- Normal color (black) => textStyle.normal
- body text color (gray) => textStyle.body
- Green, focus color => textStyle.green
- Red color => textStyle.red
- Orange => textStyle.orange Ex: Text("Color text", style: Theme.of(context).textTheme.labelLarge.notice)
Các thuộc tính mặc định như shape, color, margin không truyền vào
- Nếu Card ko có bo góc thì dùng HaloShape.zeroBorderShape Ex: shape: HaloShape.zeroBorderShape
Sử dụng màu custom như orange, green, yellow(hạn chế dùng màu vàng này, sẽ bỏ trong tương lai) Ex: context.orangeColor, context.orangeContainer context.greenColor, context.greenContainer