@@ -119,7 +119,8 @@ class _FamilynameScreenState extends State<FamilynameScreen> {
119119 ),
120120 ),
121121 Padding (
122- padding: const EdgeInsets .only (left: 30 , right: 30 , top: 20 ),
122+
123+ padding: const EdgeInsets .only (left: 40 , right: 40 , top: 40 ),
123124 child: Row (
124125 children: [
125126 Checkbox (
@@ -185,33 +186,69 @@ class _FamilynameScreenState extends State<FamilynameScreen> {
185186 ),
186187 ),
187188 Padding (
188- padding: const EdgeInsets .only (left: 40 , right: 40 , top: 20 ),
189- child: SizedBox (
190- width: double .infinity,
191- height: 65 ,
192- child: ElevatedButton (
193- style: ElevatedButton .styleFrom (
194- padding: const EdgeInsets .symmetric (vertical: 10 ),
195- backgroundColor: AppColors .ongiOrange,
196- shape: RoundedRectangleBorder (
197- borderRadius: BorderRadius .circular (20 ),
198- ),
189+ padding: const EdgeInsets .only (left: 40 , right: 30 , top: 10 ),
190+ child: Row (
191+ children: [
192+ Checkbox (
193+ value: _isChecked,
194+ activeColor: AppColors .ongiOrange,
195+ materialTapTargetSize: MaterialTapTargetSize .shrinkWrap,
196+ visualDensity: VisualDensity .compact,
197+
198+ onChanged: (bool ? value) {
199+ if (value == null ) return ;
200+ setState (() => _isChecked = value);
201+
202+ if (value) {
203+ Navigator .push (
204+ context,
205+ MaterialPageRoute (
206+ builder: (_) => const FamilycodeScreen (),
207+ ),
208+ ).then ((_) => setState (() => _isChecked = false ));
209+ }
210+ },
199211 ),
200- onPressed: _handleSubmit,
201- child: const Text (
202- '함께하기' ,
212+ const Text (
213+ '이미 가입한 가족이 있어요!' ,
203214 style: TextStyle (
204- fontSize: 33 ,
215+ fontSize: 20 ,
205216 fontWeight: FontWeight .w400,
206- color: Colors .white,
217+ height: 1.2 ,
218+ color: AppColors .ongiOrange,
207219 ),
208220 ),
209- ) ,
221+ ] ,
210222 ),
211223 ),
212224 ],
213225 ),
214226 ),
227+ bottomNavigationBar: SafeArea (
228+ minimum: const EdgeInsets .only (left: 40 , right: 40 , bottom: 16 ),
229+ child: SizedBox (
230+ width: double .infinity,
231+ height: 65 ,
232+ child: ElevatedButton (
233+ style: ElevatedButton .styleFrom (
234+ padding: const EdgeInsets .symmetric (vertical: 10 ),
235+ backgroundColor: AppColors .ongiOrange,
236+ shape: RoundedRectangleBorder (
237+ borderRadius: BorderRadius .circular (20 ),
238+ ),
239+ ),
240+ onPressed: _handleSubmit,
241+ child: const Text (
242+ '함께하기' ,
243+ style: TextStyle (
244+ fontSize: 33 ,
245+ fontWeight: FontWeight .w400,
246+ color: Colors .white,
247+ ),
248+ ),
249+ ),
250+ ),
251+ ),
215252 );
216253 }
217254}
0 commit comments