fix(mobile): people collection page layout broken in landscape (#19004)

fix(mobile): people collection page layout broken on landscape
This commit is contained in:
JobiJoba 2025-06-09 09:49:13 +07:00 committed by GitHub
parent 48e16f0a5a
commit e376366b7b
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -60,7 +60,8 @@ class PeopleCollectionPage extends HookConsumerWidget {
), ),
], ],
), ),
body: people.when( body: SafeArea(
child: people.when(
data: (people) { data: (people) {
if (search.value != null) { if (search.value != null) {
people = people.where((person) { people = people.where((person) {
@ -105,7 +106,8 @@ class PeopleCollectionPage extends HookConsumerWidget {
), ),
const SizedBox(height: 12), const SizedBox(height: 12),
GestureDetector( GestureDetector(
onTap: () => showNameEditModel(person.id, person.name), onTap: () =>
showNameEditModel(person.id, person.name),
child: person.name.isEmpty child: person.name.isEmpty
? Text( ? Text(
'add_a_name'.tr(), 'add_a_name'.tr(),
@ -121,7 +123,8 @@ class PeopleCollectionPage extends HookConsumerWidget {
child: Text( child: Text(
person.name, person.name,
overflow: TextOverflow.ellipsis, overflow: TextOverflow.ellipsis,
style: context.textTheme.titleSmall?.copyWith( style:
context.textTheme.titleSmall?.copyWith(
fontWeight: FontWeight.w500, fontWeight: FontWeight.w500,
), ),
), ),
@ -135,6 +138,7 @@ class PeopleCollectionPage extends HookConsumerWidget {
error: (error, stack) => const Text("error"), error: (error, stack) => const Text("error"),
loading: () => const Center(child: CircularProgressIndicator()), loading: () => const Center(child: CircularProgressIndicator()),
), ),
),
); );
}, },
); );