.
This commit is contained in:
@@ -512,110 +512,116 @@ class _MihInfoState extends State<MihInfo> {
|
|||||||
}
|
}
|
||||||
|
|
||||||
Widget displayBusinessCount() {
|
Widget displayBusinessCount() {
|
||||||
return Column(
|
return SizedBox(
|
||||||
mainAxisAlignment: MainAxisAlignment.center,
|
// width: 300,
|
||||||
mainAxisSize: MainAxisSize.min,
|
child: Column(
|
||||||
children: [
|
mainAxisAlignment: MainAxisAlignment.center,
|
||||||
FutureBuilder<int>(
|
mainAxisSize: MainAxisSize.min,
|
||||||
future: _futureBusinessCount,
|
children: [
|
||||||
builder: (context, snapshot) {
|
FutureBuilder<int>(
|
||||||
bool isLoading = true;
|
future: _futureBusinessCount,
|
||||||
String userCount = "⚠️";
|
builder: (context, snapshot) {
|
||||||
if (snapshot.connectionState == ConnectionState.waiting) {
|
bool isLoading = true;
|
||||||
isLoading = true;
|
String userCount = "⚠️";
|
||||||
} else if (snapshot.connectionState == ConnectionState.done &&
|
if (snapshot.connectionState == ConnectionState.waiting) {
|
||||||
snapshot.hasError) {
|
isLoading = true;
|
||||||
isLoading = false;
|
} else if (snapshot.connectionState == ConnectionState.done &&
|
||||||
} else if (snapshot.connectionState == ConnectionState.done &&
|
snapshot.hasError) {
|
||||||
snapshot.hasData) {
|
isLoading = false;
|
||||||
isLoading = false;
|
} else if (snapshot.connectionState == ConnectionState.done &&
|
||||||
userCount = snapshot.data.toString();
|
snapshot.hasData) {
|
||||||
} else {
|
isLoading = false;
|
||||||
isLoading = true;
|
userCount = snapshot.data.toString();
|
||||||
}
|
} else {
|
||||||
return SizedBox(
|
isLoading = true;
|
||||||
child: Text(
|
}
|
||||||
userCount,
|
return SizedBox(
|
||||||
style: TextStyle(
|
child: Text(
|
||||||
fontWeight: FontWeight.bold,
|
userCount,
|
||||||
fontSize: 23,
|
style: TextStyle(
|
||||||
|
fontWeight: FontWeight.bold,
|
||||||
|
fontSize: 23,
|
||||||
|
),
|
||||||
),
|
),
|
||||||
),
|
).redacted(
|
||||||
).redacted(
|
context: context,
|
||||||
context: context,
|
redact: isLoading,
|
||||||
redact: isLoading,
|
configuration: RedactedConfiguration(
|
||||||
configuration: RedactedConfiguration(
|
defaultBorderRadius: BorderRadius.circular(5),
|
||||||
defaultBorderRadius: BorderRadius.circular(5),
|
redactedColor: MihColors.getSecondaryColor(
|
||||||
redactedColor: MihColors.getSecondaryColor(
|
MzansiInnovationHub.of(context)!.theme.mode == "Dark",
|
||||||
MzansiInnovationHub.of(context)!.theme.mode == "Dark",
|
),
|
||||||
),
|
),
|
||||||
),
|
);
|
||||||
);
|
},
|
||||||
},
|
|
||||||
),
|
|
||||||
Text(
|
|
||||||
"Businesses",
|
|
||||||
textAlign: TextAlign.center,
|
|
||||||
style: TextStyle(
|
|
||||||
fontWeight: FontWeight.normal,
|
|
||||||
fontSize: 20,
|
|
||||||
),
|
),
|
||||||
),
|
Text(
|
||||||
],
|
"Businesses",
|
||||||
|
textAlign: TextAlign.center,
|
||||||
|
style: TextStyle(
|
||||||
|
fontWeight: FontWeight.normal,
|
||||||
|
fontSize: 20,
|
||||||
|
),
|
||||||
|
),
|
||||||
|
],
|
||||||
|
),
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
Widget displayUserCount() {
|
Widget displayUserCount() {
|
||||||
return Column(
|
return SizedBox(
|
||||||
mainAxisAlignment: MainAxisAlignment.center,
|
// width: 300,
|
||||||
mainAxisSize: MainAxisSize.min,
|
child: Column(
|
||||||
children: [
|
mainAxisAlignment: MainAxisAlignment.center,
|
||||||
FutureBuilder<int>(
|
mainAxisSize: MainAxisSize.min,
|
||||||
future: _futureUserCount,
|
children: [
|
||||||
builder: (context, snapshot) {
|
FutureBuilder<int>(
|
||||||
bool isLoading = true;
|
future: _futureUserCount,
|
||||||
String userCount = "⚠️";
|
builder: (context, snapshot) {
|
||||||
if (snapshot.connectionState == ConnectionState.waiting) {
|
bool isLoading = true;
|
||||||
isLoading = true;
|
String userCount = "⚠️";
|
||||||
} else if (snapshot.connectionState == ConnectionState.done &&
|
if (snapshot.connectionState == ConnectionState.waiting) {
|
||||||
snapshot.hasError) {
|
isLoading = true;
|
||||||
isLoading = false;
|
} else if (snapshot.connectionState == ConnectionState.done &&
|
||||||
} else if (snapshot.connectionState == ConnectionState.done &&
|
snapshot.hasError) {
|
||||||
snapshot.hasData) {
|
isLoading = false;
|
||||||
isLoading = false;
|
} else if (snapshot.connectionState == ConnectionState.done &&
|
||||||
userCount = snapshot.data.toString();
|
snapshot.hasData) {
|
||||||
} else {
|
isLoading = false;
|
||||||
isLoading = true;
|
userCount = snapshot.data.toString();
|
||||||
}
|
} else {
|
||||||
return SizedBox(
|
isLoading = true;
|
||||||
child: Text(
|
}
|
||||||
userCount,
|
return SizedBox(
|
||||||
style: TextStyle(
|
child: Text(
|
||||||
fontWeight: FontWeight.bold,
|
userCount,
|
||||||
fontSize: 23,
|
style: TextStyle(
|
||||||
|
fontWeight: FontWeight.bold,
|
||||||
|
fontSize: 23,
|
||||||
|
),
|
||||||
),
|
),
|
||||||
),
|
).redacted(
|
||||||
).redacted(
|
context: context,
|
||||||
context: context,
|
redact: isLoading,
|
||||||
redact: isLoading,
|
configuration: RedactedConfiguration(
|
||||||
configuration: RedactedConfiguration(
|
defaultBorderRadius: BorderRadius.circular(5),
|
||||||
defaultBorderRadius: BorderRadius.circular(5),
|
redactedColor: MihColors.getSecondaryColor(
|
||||||
redactedColor: MihColors.getSecondaryColor(
|
MzansiInnovationHub.of(context)!.theme.mode == "Dark",
|
||||||
MzansiInnovationHub.of(context)!.theme.mode == "Dark",
|
),
|
||||||
),
|
),
|
||||||
),
|
);
|
||||||
);
|
},
|
||||||
},
|
|
||||||
),
|
|
||||||
Text(
|
|
||||||
"Users",
|
|
||||||
textAlign: TextAlign.center,
|
|
||||||
style: TextStyle(
|
|
||||||
fontWeight: FontWeight.normal,
|
|
||||||
fontSize: 20,
|
|
||||||
),
|
),
|
||||||
),
|
Text(
|
||||||
],
|
"Users",
|
||||||
|
textAlign: TextAlign.center,
|
||||||
|
style: TextStyle(
|
||||||
|
fontWeight: FontWeight.normal,
|
||||||
|
fontSize: 20,
|
||||||
|
),
|
||||||
|
),
|
||||||
|
],
|
||||||
|
),
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -668,9 +674,17 @@ class _MihInfoState extends State<MihInfo> {
|
|||||||
fontSize: 15,
|
fontSize: 15,
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
const Padding(
|
// ===================== Divider
|
||||||
padding: EdgeInsets.symmetric(vertical: 10.0),
|
Padding(
|
||||||
child: Divider(),
|
padding: EdgeInsets.symmetric(
|
||||||
|
vertical: 10.0,
|
||||||
|
horizontal: 25,
|
||||||
|
),
|
||||||
|
child: Divider(
|
||||||
|
thickness: 1,
|
||||||
|
color: MihColors.getGreenColor(
|
||||||
|
MzansiInnovationHub.of(context)!.theme.mode == "Dark"),
|
||||||
|
),
|
||||||
),
|
),
|
||||||
// const SizedBox(
|
// const SizedBox(
|
||||||
// height: 10,
|
// height: 10,
|
||||||
@@ -692,25 +706,36 @@ class _MihInfoState extends State<MihInfo> {
|
|||||||
displayBusinessCount(),
|
displayBusinessCount(),
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
const Padding(
|
// ===================== Divider
|
||||||
padding: EdgeInsets.symmetric(vertical: 10.0),
|
Padding(
|
||||||
child: Divider(),
|
padding: EdgeInsets.symmetric(
|
||||||
|
vertical: 10.0,
|
||||||
|
horizontal: 25,
|
||||||
|
),
|
||||||
|
child: Divider(
|
||||||
|
thickness: 1,
|
||||||
|
color: MihColors.getGreenColor(
|
||||||
|
MzansiInnovationHub.of(context)!.theme.mode == "Dark"),
|
||||||
|
),
|
||||||
),
|
),
|
||||||
// const SizedBox(
|
// const SizedBox(
|
||||||
// height: 10,
|
// height: 10,
|
||||||
// ),
|
// ),
|
||||||
Wrap(
|
Padding(
|
||||||
alignment: WrapAlignment.start,
|
padding: const EdgeInsets.symmetric(horizontal: 25.0),
|
||||||
crossAxisAlignment: WrapCrossAlignment.start,
|
child: Wrap(
|
||||||
spacing: 10,
|
alignment: WrapAlignment.start,
|
||||||
runSpacing: 10,
|
crossAxisAlignment: WrapCrossAlignment.start,
|
||||||
children: [
|
spacing: 10,
|
||||||
ourVision(),
|
runSpacing: 10,
|
||||||
ourMission(),
|
children: [
|
||||||
],
|
ourVision(),
|
||||||
|
ourMission(),
|
||||||
|
],
|
||||||
|
),
|
||||||
),
|
),
|
||||||
const SizedBox(
|
const SizedBox(
|
||||||
height: 10,
|
height: 25,
|
||||||
),
|
),
|
||||||
Wrap(
|
Wrap(
|
||||||
alignment: WrapAlignment.center,
|
alignment: WrapAlignment.center,
|
||||||
@@ -802,9 +827,17 @@ class _MihInfoState extends State<MihInfo> {
|
|||||||
const SizedBox(
|
const SizedBox(
|
||||||
height: 10,
|
height: 10,
|
||||||
),
|
),
|
||||||
const Padding(
|
// ===================== Divider
|
||||||
padding: EdgeInsets.symmetric(vertical: 10.0),
|
Padding(
|
||||||
child: Divider(),
|
padding: EdgeInsets.symmetric(
|
||||||
|
vertical: 10.0,
|
||||||
|
horizontal: 25,
|
||||||
|
),
|
||||||
|
child: Divider(
|
||||||
|
thickness: 1,
|
||||||
|
color: MihColors.getGreenColor(
|
||||||
|
MzansiInnovationHub.of(context)!.theme.mode == "Dark"),
|
||||||
|
),
|
||||||
),
|
),
|
||||||
Column(
|
Column(
|
||||||
mainAxisAlignment: MainAxisAlignment.center,
|
mainAxisAlignment: MainAxisAlignment.center,
|
||||||
@@ -817,9 +850,17 @@ class _MihInfoState extends State<MihInfo> {
|
|||||||
founderBio(),
|
founderBio(),
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
const Padding(
|
// ===================== Divider
|
||||||
padding: EdgeInsets.symmetric(vertical: 10.0),
|
Padding(
|
||||||
child: Divider(),
|
padding: EdgeInsets.symmetric(
|
||||||
|
vertical: 10.0,
|
||||||
|
horizontal: 25,
|
||||||
|
),
|
||||||
|
child: Divider(
|
||||||
|
thickness: 1,
|
||||||
|
color: MihColors.getGreenColor(
|
||||||
|
MzansiInnovationHub.of(context)!.theme.mode == "Dark"),
|
||||||
|
),
|
||||||
),
|
),
|
||||||
mihSocials(),
|
mihSocials(),
|
||||||
],
|
],
|
||||||
|
|||||||
Reference in New Issue
Block a user