💄 Optimize shuffle post
This commit is contained in:
@@ -5,6 +5,7 @@ import 'package:hooks_riverpod/hooks_riverpod.dart';
|
|||||||
import 'package:island/pods/post/post_list.dart';
|
import 'package:island/pods/post/post_list.dart';
|
||||||
import 'package:island/widgets/app_scaffold.dart';
|
import 'package:island/widgets/app_scaffold.dart';
|
||||||
import 'package:island/widgets/post/post_item.dart';
|
import 'package:island/widgets/post/post_item.dart';
|
||||||
|
import 'package:styled_widget/styled_widget.dart';
|
||||||
|
|
||||||
const kShufflePostListId = 'shuffle';
|
const kShufflePostListId = 'shuffle';
|
||||||
|
|
||||||
@@ -60,6 +61,7 @@ class PostShuffleScreen extends HookConsumerWidget {
|
|||||||
}, [items.length, postListNotifier.fetchedAll]);
|
}, [items.length, postListNotifier.fetchedAll]);
|
||||||
|
|
||||||
return AppScaffold(
|
return AppScaffold(
|
||||||
|
isNoBackground: false,
|
||||||
appBar: AppBar(title: const Text('postShuffle').tr()),
|
appBar: AppBar(title: const Text('postShuffle').tr()),
|
||||||
body: Builder(
|
body: Builder(
|
||||||
builder: (context) {
|
builder: (context) {
|
||||||
@@ -75,13 +77,16 @@ class PostShuffleScreen extends HookConsumerWidget {
|
|||||||
itemCount: items.length,
|
itemCount: items.length,
|
||||||
itemBuilder: (context, index) {
|
itemBuilder: (context, index) {
|
||||||
return SingleChildScrollView(
|
return SingleChildScrollView(
|
||||||
child: PostActionableItem(
|
child: ConstrainedBox(
|
||||||
item: items[index],
|
constraints: const BoxConstraints(maxWidth: 640),
|
||||||
padding: const EdgeInsets.symmetric(
|
child: PostActionableItem(
|
||||||
horizontal: 8,
|
item: items[index],
|
||||||
vertical: 8,
|
padding: const EdgeInsets.symmetric(
|
||||||
|
horizontal: 8,
|
||||||
|
vertical: 8,
|
||||||
|
),
|
||||||
),
|
),
|
||||||
),
|
).center(),
|
||||||
);
|
);
|
||||||
},
|
},
|
||||||
),
|
),
|
||||||
|
|||||||
Reference in New Issue
Block a user