Compare commits
No commits in common. "844015bf079e7e62c02daef643774d18bcc805d9" and "5584af0fb763588bdc1794dc317a97dcc294f0ff" have entirely different histories.
844015bf07
...
5584af0fb7
3 changed files with 15 additions and 16 deletions
|
|
@ -1,9 +1,11 @@
|
||||||
|
import 'dart:developer';
|
||||||
|
|
||||||
import 'package:flutter/material.dart';
|
import 'package:flutter/material.dart';
|
||||||
import 'package:gap/gap.dart';
|
import 'package:gap/gap.dart';
|
||||||
import 'package:ocbo_esign_mobile/blocs/user/functions/bloc_getuser.dart';
|
import 'package:ocbo_esign_mobile/blocs/user/functions/bloc_getuser.dart';
|
||||||
import 'package:ocbo_esign_mobile/functions/get_api.dart';
|
import 'package:ocbo_esign_mobile/functions/get_api.dart';
|
||||||
import 'package:ocbo_esign_mobile/widgets/box_widget.dart';
|
import 'package:ocbo_esign_mobile/widgets/box_widget.dart';
|
||||||
|
import 'package:ocbo_esign_mobile/widgets/image_widget.dart';
|
||||||
import 'package:ocbo_esign_mobile/widgets/text_widget.dart';
|
import 'package:ocbo_esign_mobile/widgets/text_widget.dart';
|
||||||
|
|
||||||
class ApprovalPage extends StatefulWidget {
|
class ApprovalPage extends StatefulWidget {
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,5 @@
|
||||||
|
import 'dart:developer';
|
||||||
|
|
||||||
import 'package:flutter/material.dart';
|
import 'package:flutter/material.dart';
|
||||||
import 'package:flutter_dotenv/flutter_dotenv.dart';
|
import 'package:flutter_dotenv/flutter_dotenv.dart';
|
||||||
import 'package:gap/gap.dart';
|
import 'package:gap/gap.dart';
|
||||||
|
|
@ -135,18 +137,15 @@ class _LoginPageState extends State<LoginPage> {
|
||||||
InputWidget(controller: _passwordController, password: true),
|
InputWidget(controller: _passwordController, password: true),
|
||||||
const Gap(24),
|
const Gap(24),
|
||||||
|
|
||||||
Center(
|
ValueListenableBuilder<String>(
|
||||||
child: ValueListenableBuilder<String>(
|
valueListenable: passwordNotifier,
|
||||||
valueListenable: passwordNotifier,
|
builder: (context, password, child) {
|
||||||
builder: (context, password, child) {
|
return ButtonWidget(
|
||||||
return ButtonWidget(
|
text: password.isNotEmpty ? 'Login' : 'Required password',
|
||||||
width: MediaQuery.of(context).size.width,
|
onPressed: password.isNotEmpty ? _login : _ignoreButton,
|
||||||
text: password.isNotEmpty ? 'Login' : 'Required password',
|
disabled: password.isEmpty,
|
||||||
onPressed: password.isNotEmpty ? _login : _ignoreButton,
|
);
|
||||||
disabled: password.isEmpty,
|
},
|
||||||
);
|
|
||||||
},
|
|
||||||
),
|
|
||||||
),
|
),
|
||||||
// ValueListenableBuilder<String>(
|
// ValueListenableBuilder<String>(
|
||||||
// valueListenable: passwordNotifier,
|
// valueListenable: passwordNotifier,
|
||||||
|
|
|
||||||
|
|
@ -10,16 +10,14 @@ class LoginBoxWidget extends StatelessWidget {
|
||||||
|
|
||||||
@override
|
@override
|
||||||
Widget build(BuildContext context) {
|
Widget build(BuildContext context) {
|
||||||
final responsiveWidth = (MediaQuery.of(context).size.width - 30).clamp(100.0, 400.0);
|
|
||||||
|
|
||||||
return Container(
|
return Container(
|
||||||
padding: EdgeInsets.all(16),
|
padding: EdgeInsets.all(16),
|
||||||
decoration: BoxDecoration(
|
decoration: BoxDecoration(
|
||||||
borderRadius: BorderRadius.circular(8),
|
borderRadius: BorderRadius.circular(8),
|
||||||
color: const Color.fromRGBO(16, 22, 28, 0.584),
|
color: Color.fromRGBO(16, 22, 28, 0.584),
|
||||||
border: Border.all(color: const Color.fromRGBO(41, 60, 78, 0.914)),
|
border: Border.all(color: const Color.fromRGBO(41, 60, 78, 0.914)),
|
||||||
),
|
),
|
||||||
width: responsiveWidth,
|
width: MediaQuery.of(context).size.width - 30,
|
||||||
// height: MediaQuery.of(context).size.height / 2.2,
|
// height: MediaQuery.of(context).size.height / 2.2,
|
||||||
child: Column(
|
child: Column(
|
||||||
crossAxisAlignment: CrossAxisAlignment.start,
|
crossAxisAlignment: CrossAxisAlignment.start,
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue