From 5c5b4b0960b5f385b1d9f98e9a1dd4ff0216f976 Mon Sep 17 00:00:00 2001 From: ashrafzarkanisala Date: Thu, 4 Jul 2024 00:02:46 +0300 Subject: [PATCH] fix icons --- .../scene/widgets/if_then_containers/then_added_tasks.dart | 7 +++++-- .../scene/widgets/scene_devices/scene_devices_body.dart | 3 ++- 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/lib/features/scene/widgets/if_then_containers/then_added_tasks.dart b/lib/features/scene/widgets/if_then_containers/then_added_tasks.dart index abbda46..a50b2a6 100644 --- a/lib/features/scene/widgets/if_then_containers/then_added_tasks.dart +++ b/lib/features/scene/widgets/if_then_containers/then_added_tasks.dart @@ -122,8 +122,11 @@ class ThenAddedTasksContainer extends StatelessWidget }, child: SceneListTile( padding: EdgeInsets.zero, - assetPath: taskItem.icon, - iconsSize: 32, + leadingWidget: SvgPicture.asset( + taskItem.deviceIcon ?? taskItem.icon, + fit: BoxFit.fill, + ), + minLeadingWidth: 32, titleWidget: BodyMedium( text: taskItem.deviceName, style: context.bodyMedium.copyWith( diff --git a/lib/features/scene/widgets/scene_devices/scene_devices_body.dart b/lib/features/scene/widgets/scene_devices/scene_devices_body.dart index 0eaa7e2..6ee9ab4 100644 --- a/lib/features/scene/widgets/scene_devices/scene_devices_body.dart +++ b/lib/features/scene/widgets/scene_devices/scene_devices_body.dart @@ -41,7 +41,8 @@ class SceneDevicesBody extends StatelessWidget { text: e.name ?? '', textAlign: TextAlign.start, style: context.bodyLarge.copyWith( - color: (tabState is TabSelected) && tabState.roomId == e.id + color: (tabState is TabSelected) && + tabState.roomId == e.id ? ColorsManager.textPrimaryColor : ColorsManager.textPrimaryColor.withOpacity(0.2), ),