Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[WIP]TW-2042 Update contacts screen ui #2057

Open
wants to merge 6 commits into
base: main
Choose a base branch
from

Conversation

KhaledNjim
Copy link
Contributor

@KhaledNjim KhaledNjim commented Sep 23, 2024

Ticket

#2042

Resolved

Attach screenshots or videos demonstrating the changes

  • Web:
    Screenshot_1

  • Android:
    2042_mobile

  • IOS:

Copy link

This PR has been deployed to https://linagora.github.io/twake-on-matrix/2057

@KhaledNjim KhaledNjim changed the title [WIP]TW-2042 Update contacts screen ui TW-2042 Update contacts screen ui Sep 30, 2024
@hoangdat
Copy link
Member

hoangdat commented Oct 1, 2024

  • still not see the screenshot of contacts which load from address book @KhaledNjim

Comment on lines 36 to 37
color: LinagoraStateLayer(LinagoraSysColors.material().surfaceTint)
.opacityLayer3,
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

IMO, it is surface color ( ref from chat list item)
image

Please create a util class to make us reuse it.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is the color for the seperator between items, its the same as in chat list
contact list
image
chat list
image

Comment on lines 59 to 61
const SizedBox(
width: 12.0,
),
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it should be 8

image

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fixed

contactDisplayName: contact.displayName,
highlightKeyword: highlightKeyword,
style: LinagoraTextStyle.material()
.bodyMedium2
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

you use it exactly, but when I run in web app, the weight of this text is not precise

image

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

and color is not true too.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fixed

.textTheme
.bodyMedium
?.copyWith(
color: LinagoraRefColors.material().neutral[60],
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

wrong color
image

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fixed

.textTheme
.bodyMedium
?.copyWith(
color: LinagoraRefColors.material().neutral[60],
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

idem?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fixed


static EdgeInsetsDirectional appbarPadding =
const EdgeInsetsDirectional.symmetric(
horizontal: 16.0,
);

static EdgeInsetsDirectional contentPadding = EdgeInsetsDirectional.zero;
static const double textStyleHeight = 24 / 17;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

what is it? can you explain it?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The default height of the text( 17 is this case) will be multiplied by this, to make the height of the text 24
image

@nqhhdev
Copy link
Member

nqhhdev commented Oct 1, 2024

Wrong hint text

Screenshot 2024-10-01 at 12 48 52

@nqhhdev
Copy link
Member

nqhhdev commented Oct 1, 2024

Missing padding

Screenshot 2024-10-01 at 12 51 26

@KhaledNjim
Copy link
Contributor Author

  • still not see the screenshot of contacts which load from address book @KhaledNjim

The contacts at the bottom are from my phonebook

2042_phoneBook.webm

@nqhhdev
Copy link
Member

nqhhdev commented Oct 1, 2024

  • Need to move hover style, divider style, selected background to system design

@hoangdat
Copy link
Member

hoangdat commented Oct 3, 2024

  • please apply also system-design to this PR @KhaledNjim

@KhaledNjim KhaledNjim changed the title TW-2042 Update contacts screen ui [WIP]TW-2042 Update contacts screen ui Oct 4, 2024
@hoangdat
Copy link
Member

hoangdat commented Oct 4, 2024

  • please keep align to this in top. we should not keep it in center because if we have only 2 lines, blink blink will occur
Screenshot 2024-10-04 at 10 27 59

import 'package:linagora_design_flutter/linagora_design_flutter.dart';
import 'package:matrix/matrix.dart';

class ContactsTabBodyView extends StatelessWidget {
final ContactsTabController controller;
final bool enableFriendsInvite = false;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If it doesn't change use const for it.

size: 48.0,
return TwakeListItem(
child: Padding(
padding: const EdgeInsets.only(left: 8.0, top: 8.0, bottom: 8.0),
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
padding: const EdgeInsets.only(left: 8.0, top: 8.0, bottom: 8.0),
padding: const EdgeInsetsDirectional.only(start: 8.0, top: 8.0, bottom: 8.0),

: null,
builder: (context, snapshot) {
return Row(
crossAxisAlignment: CrossAxisAlignment.center,
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

CrossAxisAlignment.center is the default value so we don't need to set it again.

@@ -23,7 +23,7 @@ class SearchTextField extends StatelessWidget {
@override
Widget build(BuildContext context) {
return Material(
borderRadius: BorderRadius.circular(16.0),
borderRadius: BorderRadius.circular(24.0),
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
borderRadius: BorderRadius.circular(24.0),
borderRadius: const BorderRadius.all(Radius.circular(24.0)),

Comment on lines +24 to 26
itemBuilder: (context, index) {
return widget.itemBuilder(context, index);
},
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
itemBuilder: (context, index) {
return widget.itemBuilder(context, index);
},
itemBuilder: widget.itemBuilder,

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants