Components · App
Macro card
A card that shows one macronutrient's progress against the daily target.
App · Flutter · macromath_mobile
Shows one macronutrient's progress against the day's target: icon and name, the current value / target, the percentage and a progress bar in the macro's color.
Preview
PProtein67%
120/ 180 g
Properties
| Property | Type | Default | Description |
|---|---|---|---|
macro | Macro | — | The card's macronutrient. |
current | double | — | Current value. |
goal | double | — | Daily target. |
unit | String | 'g' | Unit displayed. |
Usage
MmMacroCard(
macro: Macro.protein,
current: 120,
goal: 180,
);Play with the sliders in the Widgetbook → Cards › Macro card › Progress.