Skip to content

Commit 3dcc658

Browse files
committed
subscription_list [nfc]: Factor out helper for dividing line
1 parent fd32618 commit 3dcc658

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

lib/widgets/subscription_list.dart

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -130,6 +130,9 @@ class _SubscriptionListHeader extends StatelessWidget {
130130

131131
final String label;
132132

133+
static final _line = Expanded(child: Divider(
134+
color: const HSLColor.fromAHSL(0.2, 240, 0.1, 0.5).toColor()));
135+
133136
@override
134137
Widget build(BuildContext context) {
135138
return SliverToBoxAdapter(
@@ -138,8 +141,7 @@ class _SubscriptionListHeader extends StatelessWidget {
138141
child: Row(crossAxisAlignment: CrossAxisAlignment.center,
139142
children: [
140143
const SizedBox(width: 16),
141-
Expanded(child: Divider(
142-
color: const HSLColor.fromAHSL(0.2, 240, 0.1, 0.5).toColor())),
144+
_line,
143145
const SizedBox(width: 8),
144146
Padding(
145147
padding: const EdgeInsets.symmetric(vertical: 7),
@@ -152,8 +154,7 @@ class _SubscriptionListHeader extends StatelessWidget {
152154
height: (16 / 14),
153155
))),
154156
const SizedBox(width: 8),
155-
Expanded(child: Divider(
156-
color: const HSLColor.fromAHSL(0.2, 240, 0.1, 0.5).toColor())),
157+
_line,
157158
const SizedBox(width: 16),
158159
])));
159160
}

0 commit comments

Comments
 (0)