From a738666960e4a1d48604e3ce654de67decb649f6 Mon Sep 17 00:00:00 2001 From: Npepperlinux Date: Sat, 20 Apr 2024 20:01:44 +0900 Subject: [PATCH] =?UTF-8?q?ui:=20=E6=B7=BB=E4=BB=98=E3=83=95=E3=82=A1?= =?UTF-8?q?=E3=82=A4=E3=83=AB=E3=81=AE=E8=A1=A8=E7=A4=BA=E3=82=92=E6=A8=AA?= =?UTF-8?q?=E5=B9=85=E3=82=92=E5=88=B6=E9=99=90=E3=81=97=E3=81=9FCard()?= =?UTF-8?q?=E3=81=AB=E5=A4=89=E6=9B=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../note_create_page/create_file_view.dart | 52 ++++++++++++------- 1 file changed, 33 insertions(+), 19 deletions(-) diff --git a/lib/view/note_create_page/create_file_view.dart b/lib/view/note_create_page/create_file_view.dart index b713f670e..bc4062857 100644 --- a/lib/view/note_create_page/create_file_view.dart +++ b/lib/view/note_create_page/create_file_view.dart @@ -59,27 +59,41 @@ class CreateFileView extends ConsumerWidget { switch (data) { case ImageFile(): - return Column( - children: [ - SizedBox( - height: 200, - child: GestureDetector( - onTap: () async => await onTap(context, ref), - child: Image.memory(data.data)), - ), - Row( + return Card.outlined( + child: SizedBox( + width: 210, + child: Column( children: [ - if (data.isNsfw) const Icon(Icons.details_rounded), - Text(data.fileName), - IconButton( - onPressed: () => detailTap(context, ref), - icon: const Icon(Icons.more_vert)), - IconButton( - onPressed: () => delete(context, ref), - icon: const Icon(Icons.delete)), + Container( + padding: const EdgeInsets.all(5), + child: SizedBox( + height: 200, + child: GestureDetector( + onTap: () async => await onTap(context, ref), + child: Image.memory(data.data)), + ), + ), + Row( + children: [ + if (data.isNsfw) const Icon(Icons.details_rounded), + if (!data.isNsfw) const SizedBox(width: 5,), + Expanded( + child: Text( + data.fileName, + overflow: TextOverflow.ellipsis + ), + ), + IconButton( + onPressed: () => detailTap(context, ref), + icon: const Icon(Icons.more_vert)), + IconButton( + onPressed: () => delete(context, ref), + icon: const Icon(Icons.delete)), + ], + ) ], - ) - ], + ), + ), ); case ImageFileAlreadyPostedFile(): return Column(