refactor(ui): Move service card name to its icon row #352

Merged
NaiJi merged 5 commits from service-card-naming into master 2023-09-26 17:58:27 +03:00
1 changed files with 9 additions and 9 deletions

View File

@ -129,16 +129,16 @@ class _Card extends StatelessWidget {
),
),
),
const SizedBox(width: 8),
NaiJi marked this conversation as resolved Outdated

Try not to use values of 10 in paddings, it is not consistent with Material Design spec. We should use values that can be divided by 8 (or 4). Like 8, 16, 24, 32.

I want to note that we actually should also take into account the UI density set by device (desktop screens with mice are more dense than phones with touchscreens), and in the end it will be something like 8 * theme_density_multiplier. Right now you should use 8 or 16.

Try not to use values of 10 in paddings, it is not consistent with Material Design spec. We should use values that can be divided by 8 (or 4). Like 8, 16, 24, 32. I want to note that we actually should also take into account the UI density set by device (desktop screens with mice are more dense than phones with touchscreens), and in the end it will be something like 8 * theme_density_multiplier. Right now you should use 8 or 16.

Should I change all other (SizedBox: 10) in this component to 8 or 16?

Should I change all other (SizedBox: 10) in this component to 8 or 16?

Yes, these may be remains from the kherel era. Don't forget to take a look how it looks in the end.

Yes, these may be remains from the kherel era. Don't forget to take a look how it looks in the end.

image

![image](/attachments/e4fcd223-db53-42a4-a0d4-32f9253b3e24)
Text(
service.displayName,
style: Theme.of(context).textTheme.headlineMedium,
),
],
),
Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
const SizedBox(height: 12),
Text(
service.displayName,
style: Theme.of(context).textTheme.headlineMedium,
),
const SizedBox(height: 8),
if (service.url != '' && service.url != null)
Column(
@ -146,7 +146,7 @@ class _Card extends StatelessWidget {
_ServiceLink(
url: service.url ?? '',
),
const SizedBox(height: 10),
const SizedBox(height: 8),
],
),
if (service.id == 'mailserver')
@ -156,21 +156,21 @@ class _Card extends StatelessWidget {
url: domainName,
isActive: false,
),
const SizedBox(height: 10),
const SizedBox(height: 8),
],
),
Text(
service.description,
style: Theme.of(context).textTheme.bodyMedium,
),
const SizedBox(height: 10),
const SizedBox(height: 8),
Text(
service.loginInfo,
style: Theme.of(context).textTheme.bodyMedium?.copyWith(
color: Theme.of(context).colorScheme.secondary,
),
),
const SizedBox(height: 10),
const SizedBox(height: 8),
],
)
],