diff --git a/lib/pages/live_area/view.dart b/lib/pages/live_area/view.dart index 5d901c4a..af78a416 100644 --- a/lib/pages/live_area/view.dart +++ b/lib/pages/live_area/view.dart @@ -234,7 +234,9 @@ class _LiveAreaPageState extends State { behavior: HitTestBehavior.opaque, onTap: () { if (_controller.isEditing.value) { - onPressed(); + if (item.id != 0) { + onPressed(); + } return; } @@ -268,35 +270,38 @@ class _LiveAreaPageState extends State { ), ], ), - Positioned( - top: 0, - right: 16, - child: Obx(() { - if (_controller.isEditing.value && - _controller.favState.value is Success) { - // init isFav - item.isFav ??= _controller.favState.value.data.contains(item); + if (item.id != 0) + Positioned( + top: 0, + right: 16, + child: Obx(() { + if (_controller.isEditing.value && + _controller.favState.value is Success) { + // init isFav + item.isFav ??= _controller.favState.value.data.contains(item); - return Builder( - builder: (context) { - return iconButton( - size: 17, - iconSize: 13, - context: context, - icon: item.isFav == true ? MdiIcons.check : MdiIcons.plus, - bgColor: item.isFav == true - ? theme.colorScheme.onInverseSurface - : null, - iconColor: - item.isFav == true ? theme.colorScheme.outline : null, - onPressed: onPressed, - ); - }, - ); - } - return const SizedBox.shrink(); - }), - ), + return Builder( + builder: (context) { + return iconButton( + size: 17, + iconSize: 13, + context: context, + icon: + item.isFav == true ? MdiIcons.check : MdiIcons.plus, + bgColor: item.isFav == true + ? theme.colorScheme.onInverseSurface + : null, + iconColor: item.isFav == true + ? theme.colorScheme.outline + : null, + onPressed: onPressed, + ); + }, + ); + } + return const SizedBox.shrink(); + }), + ), ], ), );