Commit Graph

82 Commits (e1907e41627ca4f9292d28c69383e4481281938c)

Author SHA1 Message Date
Audric Ackermann 77a3a7417d
Session 1.7.5 (#2094)
* Added message requests disabled for now

* no longer showing empty space for conversations moved from list.

* Added syncing accepting of contact between running instances.

* Adding blocking of individual requests and syncing of block to devices. Added approval by replying to a message.

* fixed typos for translations and method name.

* Blocking, accepting on click and accepting on msg send
working across clients.

* adding setting of active_at to hide unapproved messages.

* adding feature flag for config message receiving

* fix archlinux pw unused issue

on archlinux, the appimage links to the system sqlite by default which
does not support sqlcipher

* hide activeAt = 0 convo from search results

Fixes #2033

* opengroup messages from blocked user are dropped

Fixes #2019

* opengroup messages from blocked user are dropped

Fixes #2019

* dismiss a call when answered from another of our devices

* add data-testid for leftpane sections and edit profile dialog

* update turn servers

* cleanup sessionprotobuf

* move the state of calling to its own slice

* no video track by default and will be turn ON if asked to

* message request refactoring.

* create offer and answer ourselves and do not use the negotiation needed

event.

this event is causing us to loop in negotiation needed when each side
try to create one, gets the answer and so on...

* auto select the first audio input on connection success webrtc

* add a way to choose the audioouput/mute a webrtc call

* mute audio from bg when video is in fullscreen

this is to avoid having two times the remote sound playing
one in the bg and one in the fullscreen

* Adding improvements to message request handling.

* Only updating approval when it is a true value as we consider a block a decline.

* Linting and formatting.

* More formatting and linting

* fixing merge conflicts

* linting and formatting changes

* darken a bit the green of sent message box in light theme

* disable deduplication based serverId+sender

only use the serverTimestamp+sender for searching because
serverId+sender might have false positive

* Fixing up block all logic.

* speed up fetching closed group's members avatar

* Applying PR changes.

* cleanup props passing of avatar and name with a custom hook

* fix a bug releasing the decrypted attachment blobs too early


* Adding trigger logic for conversation filtering of requests.

* Fixing rimraf transpile bug. Adding PR fixes - icon buttons.

* Minor call tweaks (#2051)

* show missed-call,started-call and answered call notification in chat

* fix types for createLastMessageUpdate

* show incoming dialog if we have a pending call when enable call receptio

* simplify a bit the avatar component

* move disableDrag to a custom hook

* speed up hash colors of avatarPlaceHolders

* fixup text selection and double click reply on message

* keep avatar decoded items longer before releasing memory

* add incoming/outgoing/missed call notification

also, merge that notification with the timer and group notification
component

* hangup call if no answer after 30sec

* refactor SessionInput using hook + add testid field for recovery

* disable message request feature flag for now

* fix merge issue

* force loading screen to be black instead of white

for our dark theme user's eyes safety

* Fetch translations (#2056)

* show missed-call,started-call and answered call notification in chat

* fix types for createLastMessageUpdate

* show incoming dialog if we have a pending call when enable call receptio

* simplify a bit the avatar component

* move disableDrag to a custom hook

* speed up hash colors of avatarPlaceHolders

* fixup text selection and double click reply on message

* keep avatar decoded items longer before releasing memory

* add incoming/outgoing/missed call notification

also, merge that notification with the timer and group notification
component

* hangup call if no answer after 30sec

* refactor SessionInput using hook + add testid field for recovery

* disable message request feature flag for now

* fix merge issue

* force loading screen to be black instead of white

for our dark theme user's eyes safety

* add type for i18n to run update after crowdin  fetch with tools/updateI18nKeysType.py

* update to latest translations

* Open group regex fixes (#2058)

* Open group URL regex fixes

- Capital letters in room tokens were not being accepted (it eventually
  gets lower-cased internally, which works fine, but that happens
  *after* the URL is tested for acceptability).
- `-` in room was not being allowed (it is and always has been on SOGS,
  session-android, and session-ios).
- single-letter room ids are valid, but only 2+ letter ids were being
  accepted.
- complete URL regex wasn't anchored so something like
  `garbagehttps://example.com/room?public_key=<64hex>moregarbage` was
  being accepted in the GUI input (it fails later when other code tries
  to parse it as a URL).
- removed `m` modifier from open group regex: without anchors it wasn't
  doing anything anyway, but *with* anchors it would still allow
  leading/trailing garbage if delineated by newlines.
- public key regex was accepting g-z letters, and not accepting A-F.
- various regex cleanups:
  - use non-capture groups (?:...) rather than capturing groups (...)
  - avoid repetition in host segment matching
- tightened up host pattern matching a bit:
  - DNS host segments have a max length of 63
  - Limit port max length to 5, and disallow starting with 0

* Show an error when the open group URL is invalid

It's quite disconcerting when you have a bad open group URL and try to
add it and the join button just "doesn't work" without any feedback at
all.  Fix it to show an error message.  (There is already an i18n entry
for this because this same message is thrown if the URL can't be parsed
later on).

* Add call duration (#2059)

* add call duration once connected

* close incoming call dialog if endCall from same sender

* disable message request toggle if featureFlag is OFF

* Cleanup message request (#2063)

* close incoming call dialog if endCall from seame sender

* disable message request toggle if featureFlag is OFF

* cleanup UI of message requests

* mark all existing conversations as approved in a migration

* fix regex with conversationID for opengroups

* Various UI fixes (#2070)

* cleanup unused convo json fields in db

* display a toast if the user is not approved yet on call OFFER received

* enable CBR for calls

* do not update active_at on configMessage if !!active_at

* remove mkdirp dependency

* disable call button if focused convo is blocked

* quote: do not include the full body in quote, but just the first 100

* click on the edit profile qr code padding

* Allow longer input for opengroup join overlay

Fixes #2068

* Fix overlay feature for start new session button

* make ringing depend on redux CALL status

* turn ON read-receipt by default

* keep read-receipts disabled by default (#2071)

* refactor most of the components to outside of their Session folder (#2072)

* refactor most of the components to outside of their Session folder

* finish moving overlay and memberListItem to react hook

* fix bug with kicked member len >2 not being displayed

also sort admins first in UpdateGroupMembers dialog

* fix admin leaving text of groupNotification

* add a useFocusMount hook to focus input fields on mount

* make click avatar convo item open only user dialog

* cleanup config default.json

* make sure to use convoController to build sync message

* disable showing pubkey on opengroups

* add a pause on audio playback

Fixes #2079

* Minor styling fix for large amount of message requests (#2080)

* Minor styling fix for large amount of message requests

* Vertical center fix for message request banner.

* removing top margin from banner again.

* reactify group updates text bubble from redux store (#2083)

* add crown icon for closed group admins (#2084)

* disable call for now + fix left pane actions overflow (#2085)

* Fix attachment dl freeze (#2086)

* fix attachment download freezing app for some opengroups

* make registration page work with smaller height

* Unban UI (#2091)

* adding basic functionaliy for unbanning a user

* merge ban and unban user dialog in to one dialog

Co-authored-by: warrickct <warrickct@gmail.com>

* use React Provider for convoListItem (#2088)

this is to avoid passing down the prop to all the components

* fix closed group updates undefined on no names (#2092)

Co-authored-by: Warrick Corfe-Tan <warrickct@gmail.com>
Co-authored-by: Jason Rhinelander <jason@imaginary.ca>
Co-authored-by: Warrick <wcor690@aucklanduni.ac.nz>
3 years ago
Audric Ackermann ef25e5956f
add a spinner for when video call video is loading 3 years ago
Warrick Corfe-Tan 8d75fde012 yarn ready changes 4 years ago
Warrick Corfe-Tan ff1d7cefe4 changing some code. 4 years ago
Warrick Corfe-Tan 3c7c3220a1 Marking conversation as read if received a sync message from same users other device. 4 years ago
Warrick 1d459ba533
Unsend messages (only message hashes saving for now is enabled) (#1891)
* WIP unsending message.

* retrieving message with hash from db on receiving unsend request.

* outgoing messages hashes updated on message sent success

* unsend messaging

* unsend message - deleting messages and marking as isDeleted.

* add msg hash to unprocessed records.

* Message unsending working for closed groups provided the message has been updated with a hash from server.

* adding 2-stage confirmation modal for message deletion

* adding rendering of removed incoming messages, disabling rendering of unsent outgoing messages in coversation screen.

* Adding logging

* debugging.

* outgoing only saved for sync message instead of regular message.

* deleting locally

* adding post unsend deletioncode.

* starting adding feature flag.

* Added feature flag.

* addding mandatory messageHash  pollling pipeline methods swarm polling.

* Conversation list item message preview showing deletion placeholder text if deleted.

* add condition to drop unsend requests not send by message author

* refactoring deleteMessage. Saving response hash for closed group message sending

* running yarn ready

* removing logging.

* Adding PR fixes

* Minor changes and running yarn ready

* fix typo

* Moved feature flag to lokiFeatureFlags. Fixing linting errors


Co-authored-by: Audric Ackermann <audric@loki.network>
4 years ago
Audric Ackermann b17312c13c
Cleanup redux store (#1925)
* do not consider expire timer update unread messages #1881

* cleanup conversation props in redux to only have what cannot be derived

* fix app not starting without the await on convo creation

* cleanup props of message model
4 years ago
Audric Ackermann b45109985c
use timestamp offset in for messages storage requests (#1892)
* add using timestamp offset from network for sending part1

* remove MessageController as we now rely on the database

* fix tests for message sending overriding timestamp
4 years ago
audric 0d90248450 fix scrolling jumping to bottom on new messages 4 years ago
audric 7fa50b4a73 do not pass props not needed between message list components 4 years ago
audric f9988119f9 major UI rewrite of messages view with redux improvements 4 years ago
audric f7b0c6c7e1 make conversation screen closer to mobile UI part1 4 years ago
audric 9e37985d03 enable no-unused local and imports and fix tslint 4 years ago
Audric Ackermann 3f065a7b0e
improve marking message as read with hooks 4 years ago
Audric Ackermann 12d09bc896
preload messages when switching conversation 4 years ago
Audric Ackermann f9ecfccc0a
batch UI updates of message added events 4 years ago
audric fce86989f0 make sure profileKey is a hex string in all convos 4 years ago
audric e72885944b use selector to sort and add first of serie flag 4 years ago
Audric Ackermann 672eb91975
add types for message props and remove props function calls msg 4 years ago
Audric Ackermann e5a60af93f
Merge pull request #1751 from Bilb/fix-expire-without-seeing
do not start expire timer before seing message
4 years ago
audric 9cb69cf8fd do not start expire timer before seing message 4 years ago
Audric Ackermann e9e718bfcb
remove getInstance on MessageController=> getMessageController 4 years ago
Audric Ackermann 89a0868fc3
remove getInstance of conversationController to get() 4 years ago
Audric Ackermann a659d5b480
fix open group invitation logic 4 years ago
Audric Ackermann 8ef9c8ed1a
remove delivery receipt logic 4 years ago
Audric Ackermann 03fe67b974
remove unused contact field on message 4 years ago
Audric Ackermann 5cab7908b4
add some test for partial path rebuilding 4 years ago
Audric Ackermann c599d0b629
WIP 4 years ago
Warrick e6128fa5a7
Reply attachments (#1591)
* First attachment showing in reply composition.

* WIP: Adding thumbnail to quote response composition component.

* Added icon for voice recording attachment

* Updated formatting.

* Formatting.

* removed duplicate styling.

* WIP: Converting quote component to functional components.

* Fix bug where thumbnails for attachment replies wasn't showing.

* yarn Formatting.

* Removed old quote component.

* Add type to contentTypeSupported method.

* Moved  quote subcomponents out of Quote component.

* yarn format

* Add export to quote subcomponents.

* Fixing linting errors.

* remove commented line.

* Addressing PR comments.
4 years ago
Audric Ackermann cbc816c3ed
update displayname even if we dont have avatar on incoming profile 4 years ago
Audric Ackermann c77b24a2d4
fix avatar loading for opengroupv2 4 years ago
Audric Ackermann a26c5da6cb
Uniformize once and for all the conversation types
no more 'direct'. those are private convos
4 years ago
Audric Ackermann 98b69c17f0
add userblocking opengroupv2 and quoting back of messages 4 years ago
Audric Ackermann 34148e67ec
add return of url after v2 attachment upload 4 years ago
Audric Ackermann f7581cf4eb
increase prettier maxWidth to 100 4 years ago
Audric Ackermann c07271109f
Add a ConversationType OPEN_GROUP 4 years ago
Audric Ackermann ec6a5995db
sync expire timer updates 4 years ago
Audric Ackermann 553f264d12
make unread attrs as before a number, and remove calculatingPow
calculating pow is just the same as sending state
4 years ago
Audric Ackermann ad117fe4e5
uniformized redux convo type and getProps() of conversation 4 years ago
Audric Ackermann e1114c8ce7
add some types to Data.ts calls 4 years ago
Audric Ackermann 05e9c936ff speed up loading of messages by not notify on every new message 4 years ago
Audric Ackermann fc24df00fb
always share our profileKey on outgoing messages 4 years ago
Audric Ackermann ca22b4635f fixup some building of sync message issues 4 years ago
Audric Ackermann 8ea9f02cec Move data.js to data.ts 4 years ago
Audric Ackermann 850233bc9e review PR 4 years ago
Audric Ackermann ed84760f0e
add a tslint rule to forbid use of async without await 4 years ago
Audric Ackermann 36fab86d30
Merge remote-tracking branch 'upstream/clearnet' into move-models-to-ts-2 4 years ago
Audric Ackermann 5ec9722e00
autobind typescript class methods with autobind 4 years ago
Audric Ackermann b76ce0f2ff
update models to TS part2 4 years ago
Audric Ackermann a51f95d28c
move models to TS part1 4 years ago