fix: don't show whitespace when no options are selected (#2493)

This commit is contained in:
Richard Shiue 2023-05-15 10:56:38 +08:00 committed by GitHub
parent d44de62b90
commit 99ad9dcaff
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -161,6 +161,9 @@ class CalendarDayCard extends StatelessWidget {
});
renderHook.addSelectOptionHook((selectedOptions, cardData, _) {
if (selectedOptions.isEmpty) {
return const SizedBox.shrink();
}
final children = selectedOptions.map(
(option) {
return SelectOptionTag.fromOption(