feat: 稍后再看添加/清除已看

This commit is contained in:
guozhigq
2023-08-05 22:24:03 +08:00
parent 6b0adbc3e1
commit 1676f6f473
6 changed files with 107 additions and 3 deletions

View File

@ -28,10 +28,28 @@ class _LaterPageState extends State<LaterPage> {
appBar: AppBar(
titleSpacing: 0,
centerTitle: false,
title: Text(
'稍后再看',
style: Theme.of(context).textTheme.titleMedium,
title: Obx(
() => Text(
'稍后再看 (${_laterController.laterList.length}/100)',
style: Theme.of(context).textTheme.titleMedium,
),
),
actions: [
TextButton(
onPressed: () => _laterController.toViewDel(),
child: const Text('移除已看'),
),
// IconButton(
// tooltip: '一键清空',
// onPressed: () {},
// icon: Icon(
// Icons.clear_all_outlined,
// size: 21,
// color: Theme.of(context).colorScheme.primary,
// ),
// ),
const SizedBox(width: 8),
],
),
body: CustomScrollView(
controller: _laterController.scrollController,