Commit 7731176f authored by Dio Maulana's avatar Dio Maulana

fixed type, and logout navigation

parent 3d1014fb
...@@ -181,16 +181,25 @@ class BodyWidget extends StatelessWidget { ...@@ -181,16 +181,25 @@ class BodyWidget extends StatelessWidget {
Routes.changePasswordRoute, Routes.changePasswordRoute,
); );
}, },
child: PorfileButton( child: ProfileButton(
marginTop: 32, marginTop: 32,
icon: Assets.passwordIcon, icon: Assets.passwordIcon,
text: "Ganti Password", text: "Ganti Password",
), ),
), ),
PorfileButton( GestureDetector(
marginTop: 16, onTap: () {
icon: Assets.logoutGreyIcon, Navigator.pushNamedAndRemoveUntil(
text: "Log Out", context,
Routes.loginRoute,
(route) => false,
);
},
child: ProfileButton(
marginTop: 16,
icon: Assets.logoutGreyIcon,
text: "Log Out",
),
), ),
], ],
), ),
...@@ -199,8 +208,8 @@ class BodyWidget extends StatelessWidget { ...@@ -199,8 +208,8 @@ class BodyWidget extends StatelessWidget {
} }
} }
class PorfileButton extends StatelessWidget { class ProfileButton extends StatelessWidget {
const PorfileButton({ const ProfileButton({
Key? key, Key? key,
required this.marginTop, required this.marginTop,
required this.text, required this.text,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment