TF-2676 Fix lost button at the bottom of identity editor
This commit is contained in:
@@ -120,55 +120,83 @@ class IdentityCreatorView extends GetWidget<IdentityCreatorController>
|
|||||||
const SizedBox(height: 12),
|
const SizedBox(height: 12),
|
||||||
if (controller.isMobile(context))
|
if (controller.isMobile(context))
|
||||||
_buildActionButtonMobile(context)
|
_buildActionButtonMobile(context)
|
||||||
else
|
|
||||||
_buildActionButtonDesktop(context)
|
|
||||||
]),
|
]),
|
||||||
),
|
),
|
||||||
);
|
);
|
||||||
|
|
||||||
if (PlatformInfo.isWeb) {
|
if (PlatformInfo.isWeb) {
|
||||||
return GestureDetector(
|
return PointerInterceptor(
|
||||||
onTap: () => controller.clearFocusEditor(context),
|
child: GestureDetector(
|
||||||
child: ResponsiveWidget(
|
onTap: () => controller.clearFocusEditor(context),
|
||||||
responsiveUtils: controller.responsiveUtils,
|
child: ResponsiveWidget(
|
||||||
mobile: Scaffold(
|
responsiveUtils: controller.responsiveUtils,
|
||||||
backgroundColor: Colors.black38,
|
mobile: Scaffold(
|
||||||
body: Card(
|
backgroundColor: Colors.black38,
|
||||||
margin: EdgeInsets.zero,
|
body: Card(
|
||||||
borderOnForeground: false,
|
margin: EdgeInsets.zero,
|
||||||
color: Colors.transparent,
|
borderOnForeground: false,
|
||||||
child: ClipRRect(
|
color: Colors.transparent,
|
||||||
borderRadius: const BorderRadius.only(
|
child: ClipRRect(
|
||||||
topRight: Radius.circular(16),
|
borderRadius: const BorderRadius.only(
|
||||||
topLeft: Radius.circular(16)),
|
topRight: Radius.circular(16),
|
||||||
child: Container(
|
topLeft: Radius.circular(16)),
|
||||||
decoration: const BoxDecoration(
|
child: Container(
|
||||||
color: Colors.white,
|
decoration: const BoxDecoration(
|
||||||
borderRadius: BorderRadius.only(
|
color: Colors.white,
|
||||||
topRight: Radius.circular(16),
|
borderRadius: BorderRadius.only(
|
||||||
topLeft: Radius.circular(16)
|
topRight: Radius.circular(16),
|
||||||
|
topLeft: Radius.circular(16)
|
||||||
|
),
|
||||||
),
|
),
|
||||||
|
child: Column(children: [
|
||||||
|
_buildHeaderView(context),
|
||||||
|
Expanded(child: bodyCreatorView)
|
||||||
|
]),
|
||||||
),
|
),
|
||||||
child: Column(children: [
|
|
||||||
_buildHeaderView(context),
|
|
||||||
Expanded(child: PointerInterceptor(child: bodyCreatorView))
|
|
||||||
]),
|
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
landscapeMobile: Scaffold(
|
||||||
landscapeMobile: Scaffold(
|
backgroundColor: Colors.white,
|
||||||
backgroundColor: Colors.white,
|
body: Column(children: [
|
||||||
body: Column(children: [
|
_buildHeaderView(context),
|
||||||
_buildHeaderView(context),
|
Expanded(child: bodyCreatorView)
|
||||||
Expanded(child: PointerInterceptor(child: bodyCreatorView))
|
])
|
||||||
])
|
),
|
||||||
),
|
tablet: Scaffold(
|
||||||
tablet: Scaffold(
|
backgroundColor: Colors.black38,
|
||||||
backgroundColor: Colors.black38,
|
body: Center(
|
||||||
body: Center(
|
child: Padding(
|
||||||
child: Padding(
|
padding: const EdgeInsetsDirectional.symmetric(horizontal: 24),
|
||||||
padding: const EdgeInsetsDirectional.symmetric(horizontal: 24),
|
child: Card(
|
||||||
|
color: Colors.transparent,
|
||||||
|
shape: const RoundedRectangleBorder(
|
||||||
|
borderRadius: BorderRadius.all(Radius.circular(16))
|
||||||
|
),
|
||||||
|
child: Container(
|
||||||
|
decoration: const BoxDecoration(
|
||||||
|
color: Colors.white,
|
||||||
|
borderRadius: BorderRadius.all(Radius.circular(16))
|
||||||
|
),
|
||||||
|
width: math.max(controller.responsiveUtils.getSizeScreenWidth(context) * 0.4, 700),
|
||||||
|
height: controller.responsiveUtils.getSizeScreenHeight(context) * 0.8,
|
||||||
|
child: ClipRRect(
|
||||||
|
borderRadius: const BorderRadius.all(Radius.circular(16)),
|
||||||
|
child: Column(children: [
|
||||||
|
_buildHeaderView(context),
|
||||||
|
Expanded(child: bodyCreatorView),
|
||||||
|
const SizedBox(height: 12),
|
||||||
|
_buildActionButtonDesktop(context)
|
||||||
|
])
|
||||||
|
)
|
||||||
|
)
|
||||||
|
),
|
||||||
|
)
|
||||||
|
),
|
||||||
|
),
|
||||||
|
desktop: Scaffold(
|
||||||
|
backgroundColor: Colors.black38,
|
||||||
|
body: Center(
|
||||||
child: Card(
|
child: Card(
|
||||||
color: Colors.transparent,
|
color: Colors.transparent,
|
||||||
shape: const RoundedRectangleBorder(
|
shape: const RoundedRectangleBorder(
|
||||||
@@ -179,46 +207,22 @@ class IdentityCreatorView extends GetWidget<IdentityCreatorController>
|
|||||||
color: Colors.white,
|
color: Colors.white,
|
||||||
borderRadius: BorderRadius.all(Radius.circular(16))
|
borderRadius: BorderRadius.all(Radius.circular(16))
|
||||||
),
|
),
|
||||||
width: math.max(controller.responsiveUtils.getSizeScreenWidth(context) * 0.4, 700),
|
width: math.max(controller.responsiveUtils.getSizeScreenWidth(context) * 0.4, 800),
|
||||||
height: controller.responsiveUtils.getSizeScreenHeight(context) * 0.8,
|
height: controller.responsiveUtils.getSizeScreenHeight(context) * 0.8,
|
||||||
child: ClipRRect(
|
child: ClipRRect(
|
||||||
borderRadius: const BorderRadius.all(Radius.circular(16)),
|
borderRadius: const BorderRadius.all(Radius.circular(16)),
|
||||||
child: Column(children: [
|
child: Column(children: [
|
||||||
_buildHeaderView(context),
|
_buildHeaderView(context),
|
||||||
Expanded(child: PointerInterceptor(child: bodyCreatorView))
|
Expanded(child: bodyCreatorView),
|
||||||
|
const SizedBox(height: 12),
|
||||||
|
_buildActionButtonDesktop(context)
|
||||||
])
|
])
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
),
|
|
||||||
)
|
|
||||||
),
|
|
||||||
),
|
|
||||||
desktop: Scaffold(
|
|
||||||
backgroundColor: Colors.black38,
|
|
||||||
body: Center(
|
|
||||||
child: Card(
|
|
||||||
color: Colors.transparent,
|
|
||||||
shape: const RoundedRectangleBorder(
|
|
||||||
borderRadius: BorderRadius.all(Radius.circular(16))
|
|
||||||
),
|
|
||||||
child: Container(
|
|
||||||
decoration: const BoxDecoration(
|
|
||||||
color: Colors.white,
|
|
||||||
borderRadius: BorderRadius.all(Radius.circular(16))
|
|
||||||
),
|
|
||||||
width: math.max(controller.responsiveUtils.getSizeScreenWidth(context) * 0.4, 800),
|
|
||||||
height: controller.responsiveUtils.getSizeScreenHeight(context) * 0.8,
|
|
||||||
child: ClipRRect(
|
|
||||||
borderRadius: const BorderRadius.all(Radius.circular(16)),
|
|
||||||
child: Column(children: [
|
|
||||||
_buildHeaderView(context),
|
|
||||||
Expanded(child: PointerInterceptor(child: bodyCreatorView))
|
|
||||||
])
|
|
||||||
)
|
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
)
|
),
|
||||||
),
|
),
|
||||||
);
|
);
|
||||||
} else {
|
} else {
|
||||||
@@ -344,7 +348,9 @@ class IdentityCreatorView extends GetWidget<IdentityCreatorController>
|
|||||||
height: controller.responsiveUtils.getSizeScreenHeight(context) * 0.8,
|
height: controller.responsiveUtils.getSizeScreenHeight(context) * 0.8,
|
||||||
child: Column(children: [
|
child: Column(children: [
|
||||||
_buildHeaderView(context),
|
_buildHeaderView(context),
|
||||||
Expanded(child: bodyCreatorView)
|
Expanded(child: bodyCreatorView),
|
||||||
|
const SizedBox(height: 12),
|
||||||
|
_buildActionButtonDesktop(context)
|
||||||
])
|
])
|
||||||
)
|
)
|
||||||
),
|
),
|
||||||
@@ -484,14 +490,17 @@ class IdentityCreatorView extends GetWidget<IdentityCreatorController>
|
|||||||
}
|
}
|
||||||
|
|
||||||
Widget _buildActionButtonDesktop(BuildContext context) {
|
Widget _buildActionButtonDesktop(BuildContext context) {
|
||||||
return Row(
|
return Padding(
|
||||||
children: [
|
padding: const EdgeInsetsDirectional.symmetric(vertical: 12, horizontal: 24),
|
||||||
Expanded(child: _buildCheckboxIdentityDefault(context)),
|
child: Row(
|
||||||
const SizedBox(width: 12),
|
children: [
|
||||||
_buildCancelButton(context, width: 156),
|
Expanded(child: _buildCheckboxIdentityDefault(context)),
|
||||||
const SizedBox(width: 12),
|
const SizedBox(width: 12),
|
||||||
_buildSaveButton(context, width: 156)
|
_buildCancelButton(context, width: 156),
|
||||||
],
|
const SizedBox(width: 12),
|
||||||
|
_buildSaveButton(context, width: 156)
|
||||||
|
],
|
||||||
|
),
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user