From d8e7a16f6861936244f543c38cdeff585bf2a439 Mon Sep 17 00:00:00 2001 From: Kyoichi Date: Thu, 19 Aug 2021 16:48:37 +0900 Subject: [PATCH] =?UTF-8?q?=E9=85=8D=E5=B8=83=E3=81=95=E3=82=8C=E3=81=9F?= =?UTF-8?q?=E3=83=87=E3=82=B6=E3=82=A4=E3=83=B3=EF=BC=97=E3=81=AE=E5=AE=9F?= =?UTF-8?q?=E8=A3=85(=E9=80=94=E4=B8=AD=E7=B5=8C=E9=81=8E)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- lib/domain/operation.dart | 1 + lib/pages/home_menu.dart | 239 +++++++----------- lib/pages/mainmenuserch.dart | 105 ++++++++ lib/pages/notemenuinfo.dart | 70 ++--- lib/pages/selectchangebutton.dart | 138 ++++++++++ lib/pages/shareuserinfo.dart | 186 ++++++++------ lib/pages/theme/palette.dart | 1 + lib/pages/userinfo.dart | 2 +- .../idea_list_page_state_notifier.dart | 14 +- 9 files changed, 495 insertions(+), 261 deletions(-) create mode 100644 lib/pages/mainmenuserch.dart create mode 100644 lib/pages/selectchangebutton.dart diff --git a/lib/domain/operation.dart b/lib/domain/operation.dart index aa13805..30f6a36 100644 --- a/lib/domain/operation.dart +++ b/lib/domain/operation.dart @@ -14,6 +14,7 @@ class Operation with _$Operation { @Default([]) List args, }) = _Operation; + // ignore: prefer_constructors_over_static_methods static Operation next(String ideaId, String? currentIdeaId) { return Operation( id: const Uuid().v4(), diff --git a/lib/pages/home_menu.dart b/lib/pages/home_menu.dart index 66afa05..448e039 100644 --- a/lib/pages/home_menu.dart +++ b/lib/pages/home_menu.dart @@ -1,6 +1,8 @@ import 'dart:ui'; import 'package:alexander/addIcon/web_icon_app_icons.dart'; +import 'package:alexander/pages/mainmenuserch.dart'; import 'package:alexander/pages/notemenuinfo.dart'; +import 'package:alexander/pages/selectchangebutton.dart'; import 'package:alexander/pages/shareuserinfo.dart'; import 'package:alexander/pages/theme/palette.dart'; import 'package:alexander/pages/userinfo.dart'; @@ -25,9 +27,7 @@ class _HomePageState extends State { const sharecheck = true; //共有しているかしていないかのチェック //タグの管理 - final List menugenre = [ - 'ジャンル1', - ]; + final List menugenre = ['ジャンル1', 'ジャンル2']; return Scaffold( body: SingleChildScrollView( child: Row( @@ -52,93 +52,23 @@ class _HomePageState extends State { color: Palette.bgContentsNormalColor, child: Column( children: [ - Row( - children: [ - Container( - margin: const EdgeInsets.only(left: 80), - child: const SizedBox( - width: 437, - height: 32, - child: TextField( - textAlignVertical: TextAlignVertical.center, - decoration: InputDecoration( - border: OutlineInputBorder( - borderRadius: - BorderRadius.all(Radius.circular(30)), - ), - prefixIcon: Icon(Icons.search), - hintText: '検索', - ), - ), - ), - ), - //アイデア追加ボタン - Padding( - padding: const EdgeInsets.only(left: 25, right: 15), - child: Container( - alignment: Alignment.center, - width: 178, - height: 32, - decoration: BoxDecoration( - color: Palette.inviteandborder, - // 角丸 - borderRadius: BorderRadius.circular(5), - ), - child: InkWell( - //ボタンのクリックイベント - onTap: () {}, - child: Row( - mainAxisAlignment: - MainAxisAlignment.spaceEvenly, - children: [ - const Padding( - padding: EdgeInsets.only(bottom: 5), - child: Text( - '整理整頓をする', - style: TextStyle( - color: Palette.bgContentsLightColor, - fontSize: 16), - textAlign: TextAlign.center, - ), - ), - const Padding( - padding: EdgeInsets.only(top: 4), - child: Icon( - WebIconApp.keyboardarrowdown, - color: Palette.bgContentsLightColor, - ), - ), - ], - ), - ), + Padding( + padding: const EdgeInsets.only(top: 50), + child: Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + //検索バー + const Padding( + padding: EdgeInsets.only(left: 80), + child: Mainmenuserch(), ), - ), - //チームを抜けるボタン - if (sharecheck == true) - Padding( - padding: const EdgeInsets.all(15), - child: Container( - alignment: Alignment.center, - width: 121, - height: 32, - decoration: BoxDecoration( - color: Palette.bgContentsColor, - // 角丸 - borderRadius: BorderRadius.circular(5), - ), - child: InkWell( - //ボタンのクリックイベント - onTap: () {}, - child: const Text( - 'チームを抜ける', - style: - TextStyle(color: Palette.mainTextColor), - textAlign: TextAlign.center, - ), - ), - ), + //アイデア追加ボタン + const Padding( + padding: EdgeInsets.only(right: 120), + child: Tidybutton(), ), - ], + ], + ), ), Expanded( child: SingleChildScrollView( @@ -148,27 +78,23 @@ class _HomePageState extends State { children: [ //メインタグの処理 Padding( - padding: - const EdgeInsets.only(top: 20, left: 20), + padding: const EdgeInsets.only( + top: 20, left: 80, right: 80), child: Row( mainAxisAlignment: MainAxisAlignment.center, children: [ - Container( - width: 16, - height: 276, - decoration: const BoxDecoration( - color: Palette.bgContentsColor), - ), Container( width: 1000, height: 276, decoration: const BoxDecoration( - color: Palette.bgContentsLightColor), + color: + Palette.bgContentsLightColor), child: Column( children: [ + //タイトル Padding( padding: const EdgeInsets.only( - left: 40, right: 40, top: 30), + left: 56, right: 40, top: 30), child: Row( mainAxisAlignment: MainAxisAlignment @@ -179,68 +105,75 @@ class _HomePageState extends State { style: TextStyle(fontSize: 24), ), - SizedBox( - width: 200, - height: 30, - child: Row( - mainAxisAlignment: - MainAxisAlignment - .spaceAround, - children: [ - //radiobuttonは後日記載 - const Text( - '採用', - style: TextStyle( - fontSize: 16, - color: Palette - .titleTextColor), - ), - const Text( - '保留', - style: TextStyle( - fontSize: 16, - color: Palette - .titleTextColor), - ), - const Text( - 'ボツ案', - style: TextStyle( - fontSize: 16, + //保留ボタン + Container( + alignment: Alignment.center, + width: 91, + height: 32, + decoration: BoxDecoration( + border: Border.all( + color: Palette + .mainTextColor), + borderRadius: + BorderRadius.circular( + 5), + ), + child: InkWell( + //クリックイベント + onTap: () {}, + child: Row( + mainAxisAlignment: + MainAxisAlignment + .spaceEvenly, + children: [ + const Padding( + padding: + EdgeInsets.only( + bottom: 5), + child: Text( + '保留', + style: TextStyle( + color: Palette + .titleTextColor, + fontSize: 16), + textAlign: + TextAlign + .center, + ), + ), + const Padding( + padding: + EdgeInsets.only( + top: 4), + child: Icon( + WebIconApp + .keyboardarrowdown, color: Palette - .titleTextColor), - ), - ], + .mainTextColor, + ), + ), + ], + ), ), ), ], ), ), + //メインテキスト Flexible( child: Column( crossAxisAlignment: CrossAxisAlignment.start, children: [ - Container( - padding: - const EdgeInsets.all( - 40), - child: - const SingleChildScrollView( - child: Text( - 'サンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプルサンプル', - softWrap: true, - maxLines: 4, - overflow: TextOverflow - .ellipsis, - ), - ), - ), + //タグ一覧 Row( children: [ Padding( padding: const EdgeInsets - .only(left: 40), + .only( + left: 56, + top: 25), child: SizedBox( width: 880, height: 24, @@ -293,10 +226,26 @@ class _HomePageState extends State { ), ), ), - //下記にタグ追加のプラスボタンを配置 ], ), + //テキスト文 + const Padding( + padding: EdgeInsets.only( + left: 56, top: 25), + child: + SingleChildScrollView( + child: Text( + 'サンプルサンプルサンプルサンプルサンプル', + softWrap: true, + maxLines: 4, + overflow: TextOverflow + .ellipsis, + ), + ), + ), + //マンダラボタンなどの表示 + const SelectChangeButton(), ], ), ), diff --git a/lib/pages/mainmenuserch.dart b/lib/pages/mainmenuserch.dart new file mode 100644 index 0000000..059b3b5 --- /dev/null +++ b/lib/pages/mainmenuserch.dart @@ -0,0 +1,105 @@ +import 'package:alexander/addIcon/web_icon_app_icons.dart'; +import 'package:alexander/pages/theme/palette.dart'; +import 'package:flutter/cupertino.dart'; +import 'package:flutter/material.dart'; + +//検索バー +class Mainmenuserch extends StatelessWidget { + const Mainmenuserch({Key? key}) : super(key: key); + + @override + Widget build(BuildContext context) { + return const SizedBox( + width: 437, + height: 32, + child: TextField( + textAlignVertical: TextAlignVertical.center, + decoration: InputDecoration( + border: OutlineInputBorder( + borderRadius: BorderRadius.all(Radius.circular(20)), + borderSide: BorderSide( + color: Palette.borderColor, + ), + ), + prefixIcon: Icon(Icons.search), + hintText: '検索', + ), + ), + ); + } +} + +//チームを抜けるボタン +class Exitteambutton extends StatelessWidget { + const Exitteambutton({Key? key}) : super(key: key); + + @override + Widget build(BuildContext context) { + return Padding( + padding: const EdgeInsets.all(15), + child: Container( + alignment: Alignment.center, + width: 121, + height: 32, + decoration: BoxDecoration( + color: Palette.bgContentsColor, + // 角丸 + borderRadius: BorderRadius.circular(5), + ), + child: InkWell( + //ボタンのクリックイベント + onTap: () {}, + child: const Text( + 'チームを抜ける', + style: TextStyle(color: Palette.mainTextColor), + textAlign: TextAlign.center, + ), + ), + ), + ); + } +} + +//整理整頓ボタン表示 +class Tidybutton extends StatelessWidget { + const Tidybutton({Key? key}) : super(key: key); + + @override + Widget build(BuildContext context) { + return Container( + alignment: Alignment.center, + width: 178, + height: 32, + decoration: BoxDecoration( + color: Palette.inviteandborder, + // 角丸 + borderRadius: BorderRadius.circular(5), + ), + child: InkWell( + //ボタンのクリックイベント + onTap: () {}, + child: Row( + mainAxisAlignment: MainAxisAlignment.spaceEvenly, + children: [ + const Padding( + padding: EdgeInsets.only(bottom: 5), + child: Text( + '整理整頓をする', + style: TextStyle( + color: Palette.bgContentsLightColor, fontSize: 16), + textAlign: TextAlign.center, + ), + ), + const Padding( + padding: EdgeInsets.only(top: 4), + child: Icon( + WebIconApp.keyboardarrowdown, + color: Palette.bgContentsLightColor, + ), + ), + ], + ), + ), + ); + } +} diff --git a/lib/pages/notemenuinfo.dart b/lib/pages/notemenuinfo.dart index ab6be2f..c809053 100644 --- a/lib/pages/notemenuinfo.dart +++ b/lib/pages/notemenuinfo.dart @@ -8,9 +8,7 @@ class Notemenu extends StatelessWidget { @override Widget build(BuildContext context) { //ノート名を格納する変数 - final List noteName = [ - 'ここに', - ]; + final List noteName = ['ノートサンプル', 'ノートサンプル2', 'ノートサンプル3']; return //ノート追加の部分のウィジェット Container( width: 280, @@ -18,21 +16,22 @@ class Notemenu extends StatelessWidget { color: Palette.bgContentsLightColor, child: Column( children: [ - const Padding(padding: EdgeInsets.all(5)), Row( children: [ - Container( - margin: const EdgeInsets.only(left: 24), - width: 32, - height: 32, - decoration: BoxDecoration( - shape: BoxShape.circle, - border: Border.all(color: Palette.titleTextColor, width: 2), - ), - child: InkWell( - //ボタンのクリックイベント - onTap: () {}, - child: const Icon(Icons.add), + Padding( + padding: const EdgeInsets.only(top: 30, bottom: 30, left: 24), + child: Container( + width: 32, + height: 32, + decoration: BoxDecoration( + shape: BoxShape.circle, + border: Border.all(color: Palette.titleTextColor, width: 2), + ), + child: InkWell( + //ボタンのクリックイベント + onTap: () {}, + child: const Icon(Icons.add), + ), ), ), const SingleChildScrollView( @@ -49,30 +48,33 @@ class Notemenu extends StatelessWidget { ), ], ), - const Padding(padding: EdgeInsets.all(20)), + // 区切り線 + const Divider( + thickness: 2, + color: Palette.borderColor, + ), //配列noteNameの要素が全てTextで表示される - ListView.builder( - shrinkWrap: true, - itemCount: noteName.length, - itemBuilder: (BuildContext context, int index) { - return Container( - padding: const EdgeInsets.all(10), - child: Row( - mainAxisAlignment: MainAxisAlignment.end, - children: [ - Container( - margin: const EdgeInsets.only(right: 24), - child: Text( + Padding( + padding: const EdgeInsets.only(left: 24), + child: ListView.builder( + shrinkWrap: true, + itemCount: noteName.length, + itemBuilder: (BuildContext context, int index) { + return Padding( + padding: const EdgeInsets.only(top: 40), + child: Row( + children: [ + Text( noteName[index], textAlign: TextAlign.right, style: const TextStyle( fontSize: 15, color: Palette.titleTextColor), ), - ), - ], - ), - ); - }, + ], + ), + ); + }, + ), ), ], ), diff --git a/lib/pages/selectchangebutton.dart b/lib/pages/selectchangebutton.dart new file mode 100644 index 0000000..8bc45e9 --- /dev/null +++ b/lib/pages/selectchangebutton.dart @@ -0,0 +1,138 @@ +import 'package:alexander/pages/theme/palette.dart'; +import 'package:flutter/cupertino.dart'; +import 'package:flutter/material.dart'; + +class SelectChangeButton extends StatelessWidget { + const SelectChangeButton({Key? key}) : super(key: key); + + @override + Widget build(BuildContext context) { + return Padding( + padding: const EdgeInsets.only(left: 56, top: 25), + child: Row( + children: [ + //マンダラ + Padding( + padding: const EdgeInsets.only(right: 15), + child: Column( + children: [ + Container( + height: 48, + width: 48, + decoration: BoxDecoration( + border: Border.all(color: Palette.borderColor), + borderRadius: BorderRadius.circular(5), + ), + child: InkWell( + //マンダラボタンクリックイベント + onTap: () {}, + ), + ), + const Padding( + padding: EdgeInsets.only(top: 10), + child: Text( + 'マンダラ', + style: + TextStyle(fontSize: 12, color: Palette.accentTextColor), + ), + ) + ], + ), + ), + //履歴 + Padding( + padding: const EdgeInsets.only(right: 15), + child: Column( + children: [ + Container( + height: 48, + width: 48, + decoration: BoxDecoration( + border: Border.all(color: Palette.borderColor), + borderRadius: BorderRadius.circular(5), + ), + child: InkWell( + //履歴ボタンのクリックイベント + onTap: () {}, + child: const Icon( + Icons.access_time, + color: Palette.accentTextColor, + ), + ), + ), + const Padding( + padding: EdgeInsets.only(top: 10), + child: Text( + '履歴', + style: + TextStyle(fontSize: 12, color: Palette.accentTextColor), + ), + ) + ], + ), + ), + //ミックス + Padding( + padding: const EdgeInsets.only(right: 15), + child: Column( + children: [ + Container( + height: 48, + width: 48, + decoration: BoxDecoration( + border: Border.all(color: Palette.borderColor), + borderRadius: BorderRadius.circular(5), + ), + child: InkWell( + //ミックスボタンクリックイベント + onTap: () {}, + ), + ), + const Padding( + padding: EdgeInsets.only(top: 10), + child: Text( + 'ミックス', + style: + TextStyle(fontSize: 12, color: Palette.accentTextColor), + ), + ) + ], + ), + ), + //消去 + Padding( + padding: const EdgeInsets.only(right: 15), + child: Column( + children: [ + Container( + height: 48, + width: 48, + decoration: BoxDecoration( + border: Border.all(color: Palette.borderColor), + borderRadius: BorderRadius.circular(5), + ), + child: InkWell( + //消去ボタンクリックイベント + onTap: () {}, + child: const Icon( + Icons.delete_outline, + color: Palette.accentTextColor, + ), + ), + ), + const Padding( + padding: EdgeInsets.only(top: 10), + child: Text( + '消去', + style: + TextStyle(fontSize: 12, color: Palette.accentTextColor), + ), + ) + ], + ), + ) + ], + ), + ); + } +} diff --git a/lib/pages/shareuserinfo.dart b/lib/pages/shareuserinfo.dart index 8ebcc35..e7ccd5b 100644 --- a/lib/pages/shareuserinfo.dart +++ b/lib/pages/shareuserinfo.dart @@ -1,4 +1,3 @@ -import 'package:alexander/addIcon/web_icon_app_icons.dart'; import 'package:alexander/pages/theme/palette.dart'; import 'package:flutter/cupertino.dart'; import 'package:flutter/material.dart'; @@ -15,97 +14,80 @@ class Shareuserinfo extends StatelessWidget { ]; return SizedBox( width: 1160, - height: 112, + height: 80, child: Container( color: Palette.bgContentsColor, child: Row( mainAxisAlignment: MainAxisAlignment.spaceBetween, children: [ - //共有状態の確認の表示ウィジェット - Row( - children: [ - Container( - margin: const EdgeInsets.only(left: 80), - width: 16, - height: 16, - decoration: const BoxDecoration( - shape: BoxShape.circle, - color: Palette.emphasisTextColor, + //共有しているユーザー名を格納するウィジェット + Padding( + padding: const EdgeInsets.only(left: 136), + child: SizedBox( + width: 600, + child: Container( + padding: const EdgeInsets.symmetric( + horizontal: 3, + vertical: 3, ), - ), - const Padding( - padding: EdgeInsets.all(10), - child: Text( - '共有済み', - style: TextStyle( - color: Palette.emphasisTextColor, - ), + height: 30, + child: ListView.builder( + scrollDirection: Axis.horizontal, + itemCount: shereuser.length, + itemBuilder: (context, index) { + return Row( + mainAxisAlignment: MainAxisAlignment.center, + children: [ + Container( + width: 32, + height: 32, + decoration: const BoxDecoration( + shape: BoxShape.circle, + color: Palette.loginleft, + ), + ), + Text( + shereuser[index], + style: const TextStyle( + fontSize: 20, color: Palette.titleTextColor), + ), + ], + ); + }, ), ), - ], + ), ), - //共有しているユーザー名を格納するウィジェット - SizedBox( - width: 600, + //共有中表示 + Padding( + padding: const EdgeInsets.only(right: 80), child: Container( - padding: const EdgeInsets.symmetric( - horizontal: 3, - vertical: 3, - ), - height: 30, - child: ListView.builder( - scrollDirection: Axis.horizontal, - itemCount: shereuser.length, - itemBuilder: (context, index) { - return Row( - mainAxisAlignment: MainAxisAlignment.center, - children: [ - Container( - width: 32, - height: 32, - decoration: const BoxDecoration( - shape: BoxShape.circle, - color: Palette.loginleft, - ), - ), - Text( - shereuser[index], - style: const TextStyle( - fontSize: 20, color: Palette.titleTextColor), - ), - ], - ); - }, + padding: const EdgeInsets.all(5.0), + width: 112, + height: 40, + decoration: BoxDecoration( + border: Border.all(color: Palette.emphasisTextColor), + borderRadius: BorderRadius.circular(5), ), - ), - ), - //招待ボタンを作成したウィジェット - Container( - height: 40, - width: 110, - margin: const EdgeInsets.only(right: 80), - decoration: BoxDecoration( - color: Palette.bgContentsLightColor, - border: Border.all(color: Palette.inviteandborder, width: 2), - borderRadius: BorderRadius.circular(5), - ), - child: InkWell( - onTap: () {}, child: Row( - mainAxisAlignment: MainAxisAlignment.center, + mainAxisAlignment: MainAxisAlignment.spaceEvenly, children: [ - const Icon( - WebIconApp.share, - color: Palette.inviteandborder, - ), Container( - padding: const EdgeInsets.only(left: 5, bottom: 5), - child: const Text( - '招待', + width: 16, + height: 16, + decoration: const BoxDecoration( + shape: BoxShape.circle, + color: Palette.emphasisTextColor, + ), + ), + const Padding( + padding: EdgeInsets.only(bottom: 5), + child: Text( + '共有中', style: TextStyle( - color: Palette.inviteandborder, fontSize: 15), + color: Palette.emphasisTextColor, fontSize: 16), ), - ) + ), ], ), ), @@ -125,9 +107,57 @@ class Notshareuserinfo extends StatelessWidget { Widget build(BuildContext context) { return SizedBox( width: 1160, - height: 112, + height: 80, child: Container( - color: Palette.bgContentsColor, + color: Palette.bgContentsNormalColor, + child: Padding( + padding: const EdgeInsets.only(left: 136, right: 80), + child: Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + Container( + margin: const EdgeInsets.only(left: 24), + width: 32, + height: 32, + decoration: const BoxDecoration( + shape: BoxShape.circle, + color: Palette.loginleft, + ), + ), + //非共有中表示 + Container( + padding: const EdgeInsets.all(5.0), + width: 112, + height: 40, + decoration: BoxDecoration( + border: Border.all(color: Palette.accentTextColor), + borderRadius: BorderRadius.circular(5), + ), + child: Row( + mainAxisAlignment: MainAxisAlignment.spaceEvenly, + children: [ + Container( + width: 16, + height: 16, + decoration: const BoxDecoration( + shape: BoxShape.circle, + color: Palette.accentTextColor, + ), + ), + const Padding( + padding: EdgeInsets.only(bottom: 5), + child: Text( + '非共有', + style: TextStyle( + color: Palette.accentTextColor, fontSize: 16), + ), + ), + ], + ), + ), + ], + ), + ), ), ); } diff --git a/lib/pages/theme/palette.dart b/lib/pages/theme/palette.dart index 39c11c9..c097191 100644 --- a/lib/pages/theme/palette.dart +++ b/lib/pages/theme/palette.dart @@ -7,6 +7,7 @@ class Palette { static const Color titleTextColor = Color(0xff323b50); //テキスト5 static const Color emphasisTextColor = Color(0xffff6c00); //テキストアクセント static const Color googleTextColor = Color(0xff3162b4); + static const Color borderColor = Color(0xffd3dee6); //線 static const Color bgContentsColor = Color(0xffe9eff0); //コンテンツ背景 static const Color bgContentsHighLightColor = diff --git a/lib/pages/userinfo.dart b/lib/pages/userinfo.dart index e45f0d4..969a32e 100644 --- a/lib/pages/userinfo.dart +++ b/lib/pages/userinfo.dart @@ -11,7 +11,7 @@ class Userinfo extends StatelessWidget { //ホームメニューの左上(ユーザー情報が記載されているウィジェット) return SizedBox( width: 280, - height: 112, + height: 80, child: Container( color: Palette.bgContentsDarkColor, child: Row( diff --git a/lib/view_model/idea_list_page_state_notifier.dart b/lib/view_model/idea_list_page_state_notifier.dart index c79af0e..37512fb 100644 --- a/lib/view_model/idea_list_page_state_notifier.dart +++ b/lib/view_model/idea_list_page_state_notifier.dart @@ -10,7 +10,7 @@ import 'package:uuid/uuid.dart'; @Deprecated('') final ideaListPageProvider = StateNotifierProvider.autoDispose< IdeaListPageStateNotifier, IdeaListPageState>( - (refs) => IdeaListPageStateNotifier(IdeaListPageState()), + (refs) => IdeaListPageStateNotifier(IdeaListPageState()), ); /// 現在は使用されていません。 @@ -28,7 +28,11 @@ class IdeaListPageStateNotifier extends StateNotifier void addIdea([String? id]) { final tmp = state.ideaList; - final newIdea = Idea(id: const Uuid().v4(), onSubmittedAction: addIdea, onDeleteAction: deleteIdea,); + final newIdea = Idea( + id: const Uuid().v4(), + onSubmittedAction: addIdea, + onDeleteAction: deleteIdea, + ); final index = ideaIndexFindById(id ?? ''); @@ -71,13 +75,17 @@ class IdeaListPageStateNotifier extends StateNotifier /// 現在は使用されていません。 @Deprecated('') +// ignore: must_be_immutable class Idea extends HookWidget { final String id; final Function(String) onSubmittedAction; final Function(String) onDeleteAction; String name = ''; - Idea({required this.id, required this.onSubmittedAction, required this.onDeleteAction}); + Idea( + {required this.id, + required this.onSubmittedAction, + required this.onDeleteAction}); @override Widget build(BuildContext context) {