Build ImageVectors with dynamic colors that adapt to Material3 themes in Jetpack Compose.
View on GitHub ↗Shows how to build programmatic ImageVectors in Jetpack Compose whose colors adapt to a Material3 dynamic color theme at runtime.
Instead of using static XML drawables, each path is constructed via ImageVector.Builder with explicit color parameters — making it trivial to swap colors from MaterialTheme.colorScheme or any runtime source.
Key pattern: a makeIcon() function accepts backgroundColor, primaryColor, and secondaryColor as arguments (defaulting to theme colors when used as a @Composable), then builds the vector on-the-fly using addPath + SolidColor.