Skip to content

Commit

Permalink
リアクションデッキの一括操作系ボタンをポップアップメニューからページ下部に移動
Browse files Browse the repository at this point in the history
  • Loading branch information
Npepperlinux committed Nov 12, 2024
1 parent 4eb70b6 commit 4260338
Showing 1 changed file with 28 additions and 25 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -57,31 +57,6 @@ class ReactionDeckPageState extends ConsumerState<ReactionDeckPage> {
return Scaffold(
appBar: AppBar(
title: Text(S.of(context).reactionDeck),
actions: [
PopupMenuButton(
onSelected: (type) => switch (type) {
ReactionDeckPageMenuType.addMany =>
showAddReactionsDialog(context: context),
ReactionDeckPageMenuType.copy => copyReactions(context: context),
ReactionDeckPageMenuType.clear =>
clearReactions(context: context),
},
itemBuilder: (context) => [
PopupMenuItem(
value: ReactionDeckPageMenuType.addMany,
child: Text(S.of(context).bulkAddReactions),
),
PopupMenuItem(
value: ReactionDeckPageMenuType.clear,
child: Text(S.of(context).clear),
),
PopupMenuItem(
value: ReactionDeckPageMenuType.copy,
child: Text(S.of(context).copy),
),
],
),
],
),
body: Padding(
padding: const EdgeInsets.all(10),
Expand Down Expand Up @@ -152,6 +127,34 @@ class ReactionDeckPageState extends ConsumerState<ReactionDeckPage> {
),
],
),
const Padding(padding: EdgeInsets.only(top: 10)),
Wrap(
direction: Axis.horizontal,
alignment: WrapAlignment.center,
spacing: 10,
children: [
ElevatedButton.icon(
onPressed: () async {
await showAddReactionsDialog(context: context);
},
icon: const Icon(Icons.file_download_outlined),
label: Text(S.of(context).bulkAddReactions),
),
ElevatedButton.icon(
onPressed: () async {
await copyReactions(context: context);
},
icon: const Icon(Icons.copy_all),
label: Text(S.of(context).copy),
),
OutlinedButton(
onPressed: () async {
await clearReactions(context: context);
},
child: const Icon(Icons.clear),
),
],
),
],
),
),
Expand Down

0 comments on commit 4260338

Please sign in to comment.