444 Commits

Author SHA1 Message Date
Icaro Motta
bfc7a2d88b
Implement new URL Preview component (#15607)
Fix https://github.com/status-im/status-mobile/issues/15592

Notes:

- The red border around the icon has been reported in issue
  https://github.com/status-im/status-mobile/issues/15606
- The loading state doesn't have a spinning icon on purpose. This will be done
  separately.
2023-04-10 22:02:39 -03:00
Ulises Manuel Cárdenas
ccb20d7994
[#15578] fix code snippet 2023-04-10 12:24:22 -06:00
Parvesh Monu
6bdadd9f0d
fix create profile issues (#15561) 2023-04-03 19:49:25 +05:30
Ibrahem Khalil
7ed4bc5a5c
Add accessibility id for community unread indicators (#15485) 2023-04-02 20:16:51 +02:00
John Ngei
abe4dc7ac1
Update communities discover screen
* Fix: discover communities missing data

* made community tags scrollable
2023-03-31 13:25:56 +03:00
Jamie Caprani
2ab491f12b
chore: update to new ui on intro screen of syncing (#15450) 2023-03-31 02:49:36 -07:00
Jamie Caprani
7ad5e2181d
chore: clean up ui for onboarding screens (#15470) 2023-03-30 04:05:42 -07:00
Parvesh Monu
f0ca6372cd
Implement onboarding slide animation (#15489) 2023-03-28 20:57:54 +05:30
Ibrahem Khalil
e825f930fa
Add accessibility label for community options button (#15484) 2023-03-28 07:50:07 +02:00
Alexander
e4db23b0a9
Center input value within the field (#15472) 2023-03-27 23:00:33 +02:00
Ulises Manuel Cárdenas
94ddbbcd2e
Add checked? property, dark blur variant & tests to disclaimer component
Co-authored-by: Jamie Caprani <jamiecaprani@gmail.com>
2023-03-27 14:06:09 -06:00
Ulises M
899f89c800
Implement create password screens 2023-03-27 14:21:39 +01:00
John Ngei
2f84cfd354
Onboarding notifications flow
* enable notifications onboarding

* added blurred background

* support navigate to previous screen
2023-03-25 01:40:36 +03:00
Mohamed Javid
7d4be37111
[Feature] Sign in by scanning sync QR code (#15416) 2023-03-24 20:36:25 +05:30
Jamie Caprani
a502da6ea4
9c1c01c6...48eb7052 (#15401)
feat: add create profile to onboarding
2023-03-22 06:51:38 -07:00
Omar Basem
f9255100a1
feat: bottom sheet screen (#15399)
* feat: bottom sheet screen
2023-03-22 17:31:20 +04:00
Parvesh Monu
937c128c08
Onboarding app locked flow 2023-03-22 13:41:05 +05:30
Ulises Manuel Cárdenas
554f8aff09
Add input tests
Also fixes text align on non-multiline inputs
2023-03-21 12:28:02 -06:00
Jamie Caprani
f6f5dfbe03
chore: add skeleton flow for onboarding (#15334) 2023-03-17 05:19:39 -07:00
Ulises Manuel Cárdenas
0e36190516
Fix input padding & add blur and override-theme properties
Add with-let formatting style
2023-03-16 12:59:34 -06:00
Andrea Maria Piana
b44e4c6d59
Add collapsing of categories (#15306)
290579f7...44a0f5b7

Fixes: #15290

This commit adds collapsing of categories.
It also adds ordering of chats/categories as it was previously ignored.

It also removes the communities/enabled? flag as it's not used anymore,
and communities should always be enabled.
2023-03-16 10:17:50 +00:00
Alexander
dabe8285be
Bugfixes for the style of "New to Status" screen (#15353)
* Bugfixes for the style of "New to Status" screen

* Updates
2023-03-15 20:02:26 +01:00
Icaro Motta
e8556a9abf
Show AC unread indicator with counter and seen state color (#15304)
- Display Activity Center unread badge with the unread counter.
- Use the new seen state stored in `status-go` to change the color of the
  notification.
- Performance: split the `top-nav` component into left and right section
  components and render the unread indicator in a separate component to not
  trigger the re-render of the entire `top-nav` (as was before).
  
Fixes https://github.com/status-im/status-mobile/issues/14851

Demo: https://user-images.githubusercontent.com/46027/224299978-770dd5f1-302b-4375-af2b-3cd181ffdc9d.webm

Notes
=====

- Fix/improve: `quo/counter` displayed `NaN` to the user if the input value was
  an empty string.
- In Figma, there's a border around the unread indicator. I didn't implement
  this because the ideal solution IMO involves changing the `quo/counter`
  component a little bit because the width of the component varies according to
  the content displayed (1, 9, 99, 100, etc) and I wanted to the right thing in
  a separate PR.

Design notes
============

There's an ongoing conversation with the Design team to decide what to do with
the gray indicator on top of the bell icon, since there's little contrast when
it's is in the `seen` state.

Platforms
=========

- Android
- iOS

Steps to test
=============

- Open Status
- Receive one or more notifications in the Home screen and check the unread
  indicator is blue and has a counter.
- Open the AC and close it, notice the unread indicator is now in the `seen`
  state. You can close the app and re-open and the state is persisted.
- Mark notifications as read/unread at will, check the unread counter is
  correct.
2023-03-15 12:41:34 -03:00
Icaro Motta
9473d3f40c
Swipe gestures for Activity Center notifications with CTA (#15284)
Implements swipe actions for notifications with call to action (e.g. pending
contact requests, unverified identity verifications, etc).

Fixes https://github.com/status-im/status-mobile/issues/15118

According to the Design team, the goal is to deliver a consistent experience to
users, so whenever the user sees a notification with buttons, the same actions
can be taken via the swipe buttons.

Note: swipe buttons are using placeholder icons while the Design team works out
which ones to use

Additionally, a bunch of fixes:

- Fix: outgoing pending contact requests were not being removed from the UI when
  cancelled.
- Fix: Membership tab not showing unread indicator.
- Fix: dismissed membership notification not marked as read.
- Fix: dismissed membership notification was displaying decline/accept buttons.
  Regression came from changes in status-go related to soft deletion of
  notifications.
- Fix: incorrect check for the pending state of a contact request.
- Fixed lots of bugs for identity verification notifications, as it was
  completely broken. Unfortunately, somebody made lots of changes without
  actually testing the flows.
- Add basic error handling and log if accepting, declining or canceling contact
  requests fail.

The demo shows an identity verification with swipe actions to reply or decline.
[identity-verification-swipe-to-reply.webm](https://user-images.githubusercontent.com/46027/223565755-b2ca3f68-12e2-4e1e-9e52-edd52cfcc971.webm)

Out of scope: The old quo input is still in use in the identity verification
notification. This will eventually be solved by issue
https://github.com/status-im/status-mobile/issues/14364

### Steps to test

Notifications with one or more buttons (actions) are affected by this change,
because now the user can also swipe left/right to act on them.

- Membership notifications: private group chat. The following PR explains how to
  generate them https://github.com/status-im/status-mobile/pull/14785
- Contact requests, and community gated requests to join (Admin tab).
- Identity verifications. I believe the only way to test identity verification
  flows at the moment is to use the Desktop app, since initiating the challenge
  is not implemented in Mobile yet.
- Mentions and replies don't have new swipe buttons because they don't have call
  to action buttons throughout their lifecycle.

Steps to test identity verification flows:

#### Identity verification flow 1

- `A` and `B` are mutual contacts.
- `A` sends a verification request to `B`.
- `A` should not see any notification yet.
- `B` should receive an identity verification notification. `B` can either
  decline or reply.
- `B` declines and the status `Declined` is shown instead of buttons.
- `B` can now either swipe to toggle read/unread or swipe delete the
  notification.
- `A` should not receive any notification after `A` declined.

#### Identity verification flow 2

- `A` and `B` are mutual contacts.
- `A` sends a verification request to `B`.
- `A` should not see any notification yet.
- `B` should receive an identity verification notification. `B` can either
  decline or reply.
- `B` press `Reply` and a bottom sheet is displayed with a text input.
- `B` sends the reply/answer message and the status `Replied` is shown instead
  of buttons.
- `B` can now either swipe to toggle read/unread or swipe to delete the
  notification.
- `A` should receive a notification with the reply from `B`.
- `A` can either mark the answer as untrustworthy or accept it (trust it) via
  the normal buttons, as well as via the swipe left/right buttons.
- If `A` accepts the answer, then the status `Confirmed` is shown instead of
  buttons. On the other hand, if `A` marks as untrustworthy, then the status
  `Untrustworthy` is shown instead of buttons.
- `B` should receive no further notifications due to `A`s actions.
- `A` can now either swipe to toggle read/unread or swipe delete the
  notification.
2023-03-14 12:34:13 -03:00
Jamie Caprani
e98ce54830
feat: add profile input to quo2 (#15323) 2023-03-14 06:52:15 -07:00
flexsurfer
0fe6fea7e4
Improve home animations (#15247) 2023-03-13 19:47:04 +01:00
Ulises Manuel Cárdenas
9e4d9a05a7
Add new onboarding screen - I'm new to status 2023-03-13 10:25:04 -06:00
Jamie Caprani
d8c110bf85
feat: add title input component to quo2 (#15133) 2023-03-11 08:29:11 -08:00
Brian Sztamfater
7332f483a4
feat: integrate record audio component into composer
Signed-off-by: Brian Sztamfater <brian@status.im>
2023-03-10 12:05:12 -03:00
Mohamed Javid
f67f205fa9
Status Tag UI and usage update (#15282)
* [Feature][#15267] Status Tag UI Update

* [Fix] Typo in comment

* [Fix] Feedback from PR

* [Fix] Feedback from PR

* [Fix] Blur Type on Preview Screen

* [Fix] Blur Type on Preview Screen
2023-03-10 15:31:54 +05:30
Ulises Manuel Cárdenas
8478ac74ab
Refactor user-avatar & add tests 2023-03-08 11:07:37 -06:00
Jamie Caprani
2861190e5b
New intro screen (#15127)
* feat: add new intro page

* e2e: new intro fix

---------

Co-authored-by: Churikova Tetiana <tatiana@status.im>
2023-03-06 06:42:30 -08:00
John Ngei
7a9018ae11
replaced mocked community-tags and images with real data
Co-authored-by: jo-mut <jo_ngei@Johns-MacBook-Air.local>
2023-03-06 13:57:58 +03:00
Parvesh Monu
8454ce2e11
Onboarding add background screen (#15231) 2023-03-06 16:07:07 +05:30
Parvesh Monu
f314806b83
Improve profile card (#15264) 2023-03-06 14:24:34 +05:30
Ulises Manuel Cárdenas
ff3ba6c0f0
Add new text input component 2023-03-03 15:03:38 -06:00
John Ngei
25d44b11f1
Fix: chat header height 2023-03-02 21:57:19 +03:00
Ulises Manuel Cárdenas
7d9709ee67
Improve chat Avatar (#15036) 2023-03-01 14:54:40 -06:00
Ajay Sivan
aec1b5fafa
quo2 strength divider component (#15177) 2023-03-01 15:47:02 +00:00
yqrashawn
2ce4a820d7
fix: deleted-by user name style (#15218) 2023-03-01 15:03:27 +08:00
flexsurfer
fa03e91080
Sanitize quo2 namespace (#15207) 2023-02-28 13:59:09 +01:00
flexsurfer
80f063d0dd
[#15056] Can't see display/ens/name when mentioning in community (#15085) 2023-02-27 12:51:53 +01:00
yqrashawn
c28b34ac08
fix: toast style on android (#15194) 2023-02-27 17:25:21 +08:00
Icaro Motta
1806cb792a
Allow users to swipe to delete or swipe to toggle unread notification status (#15106)
Adds support for swiping left/right on some types of notifications. Swiping left
(from left to right) shows a blue button allowing the user to mark the
notification as read/unread. Swiping right (from right to left) shows a red
button, allowing the user to delete the notification for good.

Related PR in status-go https://github.com/status-im/status-go/pull/3201.

Fixes https://github.com/status-im/status-mobile/issues/14901
Fixes https://github.com/status-im/status-mobile/issues/14900

Technical notes
===============

How's the performance? It feels near native performance in a production release
in a mid-range smartphone. So I'd say it's pretty good, but let me know if you
find any issue.

- I refrained from trying to eliminate all code duplication in this PR. Some
  notifications will behave differently, especially the ones with call to
  action, so I ask you to please take that in consideration when reviewing. See
  https://github.com/status-im/status-mobile/issues/15118
- React Native Gesture Handler has a component named
  [Swipeable](https://docs.swmansion.com/react-native-gesture-handler/docs/api/components/swipeable/).
  I used it instead of writing a monstrosity 👹 of code in
  Reanimated to achieve the same results.
- RN Gesture Handler touchables are the only ones that work with the Swipeable
  component, so I used them and added vars to `react-native.gesture`.
- I had to manually interpolate the translation X of the buttons behind
  notifications because notifications are transparent. To make interpolation
  work with `Swipeable` it's mandatory to use RN `Animated.View` and not
  `Reanimated.View` (see next point).
- `Swipeable` expects us to pass functions that will receive RN
  `AnimatedInterpolation` instances and the rendering lifecycle does not work as
  usual. Hooks didn't trigger as expected, functional Reagent components didn't
  behave as expected, etc. This means `Reanimated.View` and its interpolation
  function is out of question. I did try for almost two days, nothing works.

Testing notes
=============

These are some of the manual tests I ran. There are more scenarios to cover
obviously. Assuming no unread notifications before each flow:

Contact request notification
============================

From the perspective of an user A:

1. Receive a contact request from a non-mutual contact B.
2. Verify the unread count is displayed over the bell icon.
3. Verify the unread count is displayed on the `Messages > Contacts` tab, as
   well as on the AC `Contact requests` tab.
4. Open the AC and before accepting/declining the contact request, check that
   you CAN'T swipe left or right.
5. Accept or decline the contact request.
6. Check the unread indicator disappears in all necessary places.
7. Press on the notification and see if you're redirected to the chat.
8. Go back to the AC and swipe left to mark as `Unread`. Notice that opening the
   chat marks the notification as `Read`. Also very important, notice that the
   `Messages > Contacts` tab will NOT show the *pending contact requests*
   section at the top. This is on purpose, given the notification is unread, but
   the user has already accepted/declined the contact request, hence it's not
   pending.
9. Swipe left againg to mark as `Read`. Check all unread indicators are updated.
10. Swipe right to delete the notification (it won't be displayed ever again).

Admin notification
==================

1. Generate an admin notification, e.g. a community owner receiving a request
   notification to join.
2. Verify the unread count is displayed over the bell icon, as well as the AC
   Admin tab.
3. Verify the community unread indicator is correctly displayed.
4. As an admin, open the AC and before accepting/declining the request, check
   that you CAN'T swipe left or right.
5. Accept or decline the membership request.
6. Check the unread indicator disappears accordingly.
7. Swipe left to mark as `Read`.
8. Swipe left to mark as `Unread`.
9. Swipe right to delete the notification (it won't be displayed ever again).

Mentions & replies
==================

Similar steps outlined for `Admin` notifications, but there's one important
difference. Mention and reply notifications don't require a call to action from
the user, so the user can swipe left/right **without** first having to do
anything on the notification (such as pressing on it). See issue
https://github.com/status-im/status-mobile/issues/15118

What about other types of notifications?
========================================

Swipe gestures for other notification types will be implemented in a separate
PR.
2023-02-24 21:22:31 -03:00
John Ngei
fac2f952d0
Fix: scroll-page component sticky header height 2023-02-23 18:31:21 +03:00
yqrashawn
e830f633d8
fix: toast style (#15170) 2023-02-23 20:18:44 +08:00
Ajay Sivan
6ffed4ad47
quo2 profile-select component
Signed-off-by: Parvesh Monu <parvesh.dhullmonu@gmail.com>
2023-02-23 01:41:56 +05:30
Ajay Sivan
c8fd7121d3
quo2 password-tips component (#15157) 2023-02-22 14:50:56 +01:00
Ajay Sivan
d6c09d289c
quo2 color-picker component (#15105) 2023-02-22 12:05:40 +01:00
yqrashawn
3fc4c36ac6
fix: toast style (#15144) 2023-02-22 09:55:21 +08:00