mirror of
https://github.com/bggRGjQaUbCoE/PiliPlus.git
synced 2026-06-01 08:38:18 +08:00
opt vote option
Signed-off-by: bggRGjQaUbCoE <githubaccount56556@proton.me>
This commit is contained in:
@@ -225,24 +225,29 @@ class PercentageChip extends StatelessWidget {
|
|||||||
Padding(
|
Padding(
|
||||||
padding: const EdgeInsets.symmetric(horizontal: 12, vertical: 10),
|
padding: const EdgeInsets.symmetric(horizontal: 12, vertical: 10),
|
||||||
child: Row(
|
child: Row(
|
||||||
// mainAxisSize: MainAxisSize.min,
|
spacing: 8,
|
||||||
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
|
||||||
children: [
|
children: [
|
||||||
Row(
|
Expanded(
|
||||||
|
child: Row(
|
||||||
|
spacing: 4,
|
||||||
mainAxisSize: MainAxisSize.min,
|
mainAxisSize: MainAxisSize.min,
|
||||||
children: [
|
children: [
|
||||||
Text(label, maxLines: 1, overflow: TextOverflow.ellipsis),
|
Flexible(
|
||||||
|
child: Text(
|
||||||
|
label,
|
||||||
|
maxLines: 1,
|
||||||
|
overflow: TextOverflow.ellipsis,
|
||||||
|
),
|
||||||
|
),
|
||||||
if (selected)
|
if (selected)
|
||||||
Padding(
|
Icon(
|
||||||
padding: const EdgeInsets.only(left: 4),
|
|
||||||
child: Icon(
|
|
||||||
Icons.check_circle,
|
Icons.check_circle,
|
||||||
size: 12,
|
size: 12,
|
||||||
color: colorScheme.onPrimaryContainer,
|
color: colorScheme.onPrimaryContainer,
|
||||||
),
|
),
|
||||||
),
|
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
|
),
|
||||||
if (percentage != null)
|
if (percentage != null)
|
||||||
Text('${(percentage! * 100).toStringAsFixed(0)}%'),
|
Text('${(percentage! * 100).toStringAsFixed(0)}%'),
|
||||||
],
|
],
|
||||||
|
|||||||
Reference in New Issue
Block a user