chore: make plus icon color match theme (#2179)
This commit is contained in:
parent
84fde3026a
commit
0d4fef8a14
2 changed files with 11 additions and 1 deletions
|
|
@ -43,7 +43,10 @@ class CreateChatCard extends StatelessWidget {
|
|||
child: CustomizedSvg(
|
||||
svgUrl:
|
||||
"${AppConfig.assetsBaseURL}/${ActivitySuggestionsConstants.plusIconPath}",
|
||||
colorReplacements: const {},
|
||||
colorReplacements: {
|
||||
"#CDBEF9":
|
||||
colorToHex(Theme.of(context).colorScheme.secondary),
|
||||
},
|
||||
height: 80,
|
||||
width: 80,
|
||||
),
|
||||
|
|
|
|||
|
|
@ -138,3 +138,10 @@ class CustomizedSvg extends StatelessWidget {
|
|||
);
|
||||
}
|
||||
}
|
||||
|
||||
String colorToHex(Color color) {
|
||||
return '#'
|
||||
'${(color.r * 255).toInt().toRadixString(16).padLeft(2, '0')}'
|
||||
'${(color.g * 255).toInt().toRadixString(16).padLeft(2, '0')}'
|
||||
'${(color.b * 255).toInt().toRadixString(16).padLeft(2, '0')}';
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue