Commit Graph

346 Commits

Author SHA1 Message Date
Liam Fitzgerald
b29e98ec10 Merge branch 'master' into lf/profile-overlay 2020-04-21 15:11:02 +10:00
Liam Fitzgerald
5fbe955874 chat-fe: more FF scrollback fixes 2020-04-17 15:17:52 +10:00
Liam Fitzgerald
1b90328f39 chat-fe: fix index issue with pending messages
To produce message elements we iterate over pendingMessage ++ messages,
but to check whether they're adjacent to a message by the same author,
we index back into messages, which produces incorrect results when
pendingMessages is nonEmpty
2020-04-17 14:20:28 +10:00
Liam Fitzgerald
41be649764 Merge branch 'master' into mp/chat/firefox-take-2 2020-04-17 12:06:34 +10:00
Jared Tobin
e7984324be
Merge branch 'fix-pending' (#2751)
* origin/fix-pending:
  chat-js: fix chat ordering and pending messages

Signed-off-by: Jared Tobin <jared@tlon.io>
2020-04-16 16:54:12 +04:00
Logan Allen
e98605c1bb chat-js: fix chat ordering and pending messages 2020-04-15 16:48:33 -04:00
Logan Allen
c497d5a6a6 chat-js: fix auto-join and a chatSynced error 2020-04-15 15:58:03 -04:00
Logan Allen
f035070387 chat-js: fix issue with autojoining 2020-04-15 15:04:54 -04:00
Liam Fitzgerald
8b48f3fa0f chat-js: adjust line height in chat input
Set the line height of the input to be the same as a sent message.
Additionally fixes an issue that would cause unnecessary scrollbars to
be shown.
2020-04-15 15:08:42 +10:00
Liam Fitzgerald
b538cfd3ea chat-fe: address review comments 2020-04-15 10:48:46 +10:00
ixv
5bb9776b70
Merge pull request #2730 from liam-fitzgerald/lf/chat-synced-fix
chat-fe: resubscribe message iff chatSynced is populated
2020-04-14 11:40:45 -07:00
ixv
e5cf4fb813
Merge pull request #2720 from urbit/la-channel-err
channel.js: added way to handle event source errors more smoothly, and implemented in chat
2020-04-14 11:40:02 -07:00
Liam Fitzgerald
9ddf06d2a1 chat-fe: correct FF scroll behaviour
Firefox treats the reflow in the scroll container weirdly so for the
scrollback case, we save the position to restore later, when the backlog
messages come in. For the 'locked at bottom' case we add a new state
variable and rescroll based on that.
2020-04-14 16:34:10 +10:00
Liam Fitzgerald
a6c5e96902 chat-fe: don't redirect if creating group 2020-04-14 11:50:47 +10:00
Liam Fitzgerald
786f2518e7 chat-fe: resubscribe message iff chatSynced is populated
Previously, if a room was navigated to directly, the resubscribe message
would show before the chatSynced state was loaded. Initialises
chatSynced as null and checks it is not null before showing the
resubscribe message.
2020-04-14 11:41:38 +10:00
Matilde Park
a4d37c0313 Merge branch 'master' into mp/chat/firefox-take-2 2020-04-13 21:38:27 -04:00
Liam Fitzgerald
1d81107d72 Merge branch 'master' into lf/profile-overlay 2020-04-14 11:04:52 +10:00
Liam Fitzgerald
a2998bdc41 chat-fe: redirect to DMs on trivial new group case
Create or view a DM upon trying to create an invite-only group with one invitee.
2020-04-14 11:01:31 +10:00
ixv
a7f20c37c1
Merge pull request #2700 from liam-fitzgerald/lf/invite-search-short
invite-search: handle suggestions for short searches
2020-04-13 16:56:26 -07:00
Liam Fitzgerald
2c870cdfc0 chat-fe: resuscitate scrollback
If the initial 20 messages doesn't cause the messages container to
overflow then the backlog will never be requested, making scrollback
impossible. This is due to making the container have position:relative
in order to display an overlay inside it.  Fixed by unconditionally
requesting the first page of backlog on load.
2020-04-11 20:07:01 +10:00
Liam Fitzgerald
d2d9158ea3 chat-fe: hide profile overlay on click outside
Hides the profile overlay when the users clicks outside the overlay.
2020-04-11 19:34:11 +10:00
Liam Fitzgerald
966155088c chat-fe: move new DMs to ship select popover
Refactored the patp autocomplete into a reusable component, and then
used that to add the DM popover interface. Also introduces some
performance improvements for the popover.
2020-04-11 17:47:11 +10:00
Liam Fitzgerald
803c7b4816 chat-fe: edit group identity if own profile overlay
Shows an "Edit Group Identity" button instead of "Send Message" if the
profile overlay being shown is the user's own.
2020-04-11 10:44:57 +10:00
Liam Fitzgerald
e5634a913d invite-search: always add search query if valid patp 2020-04-11 10:17:49 +10:00
Logan Allen
fb3111e88a channel.js: added way to handle event source errors more smoothly, and implemented in chat 2020-04-10 19:38:13 -04:00
Logan Allen
98f4df14a4 chat-js: made scrollback work for new message indexing 2020-04-10 22:22:14 +00:00
Logan Allen
6d1efde884 chat-js: fixed scrollback for reverse message chatrooms 2020-04-10 17:29:23 -04:00
Matilde Park
948dbe85e7 chat: scrollToBottom on mount for FF 2020-04-10 16:55:23 -04:00
Matilde Park
1ddbc77157 chat: only scrolltobottom if first backlog grab 2020-04-10 16:42:05 -04:00
Matilde Park
3dc6a0bc9a chat: add firefox-specific chat window 2020-04-10 16:34:27 -04:00
Logan Allen
ecc8942eaf chat: reversed order that messages are stored in for faster performance 2020-04-10 15:25:58 -04:00
Liam Fitzgerald
e7887b34c3 invite-search: handle suggestions for short searches
Triggers invitee suggestions after one character of input. To
compensate for the potential explosion of suggestions, we
tighten our group searching criteria and truncate the
ship suggestions on short searches. Also addresses a bug where names of
groups were not being downcased before search.

Fixes #2635
2020-04-10 19:57:50 +10:00
Liam Fitzgerald
c162f0f212 chat-fe: add DMs and related screens
Adds DMs, which are just unmanaged chats whose last path component
starts with dm-- followed by the patp of the other user.
2020-04-10 19:45:25 +10:00
Liam Fitzgerald
1bca495d8a chat-fe: reflow profile overlay near edges of screen
Polls for the distance between the top of the container and reflows the
overlay accordingly.
2020-04-10 17:59:04 +10:00
Liam Fitzgerald
188a1e8dcf chat-fe: hide/show profile overlay on sigil click
Hide and shows profile overlay on sigil click. Shows the overlay for 2
seconds after click. If the user moves their mouse into the overlay then
it will remain open as long as the mouse is inside the overlay.
2020-04-10 17:59:04 +10:00
Liam Fitzgerald
f3c21fae36 chat-fe: add profile overlay
Adds a profile overlay to display information about the user on hover.
Also adds the svgClass prop to the sigil component, to allow setting
classes directly on the sigil svg.
2020-04-10 17:58:46 +10:00
ixv
b43f4d9d39
Merge pull request #2709 from urbit/mp/chat/namespace-group-chats
chat: add unique ID to grouped chat paths
2020-04-09 15:54:53 -07:00
ixv
d376fd6998
Merge pull request #2704 from liam-fitzgerald/lf/chat-padding-sidebar
chat-fe: filter empty groups in sidebar
2020-04-09 15:53:55 -07:00
ixv
8e480b611d
Merge pull request #2703 from liam-fitzgerald/lf/chat-patp-copy
chat-fe: copy patp to clipboard on author name click
2020-04-09 15:53:46 -07:00
ixv
c5eb540c71
Merge pull request #2702 from liam-fitzgerald/lf/chat-join-spinner
chat-fe: show spinner on join
2020-04-09 15:53:35 -07:00
ixv
a41096153d
Merge pull request #2694 from liam-fitzgerald/lf/invite-search-arrow-keys
invite-search: allow keyboard nav + selection
2020-04-09 15:52:36 -07:00
ixv
77933e992a
Merge pull request #2693 from urbit/mp/re-alphabetise
various: alphabetise associations accesses the object
2020-04-09 15:52:18 -07:00
ixv
5fe16a7f47
Merge pull request #2687 from urbit/la-resub-on-err
chat-js: resubscribe on error, not just on quit
2020-04-09 15:52:03 -07:00
Matilde Park
9881fb2a2b chat: add unique ID to grouped chat paths 2020-04-09 14:37:21 -04:00
Liam Fitzgerald
6586aa98e3 chat-fe: filter empty groups in sidebar
Empty groups caused the padding on the first group to be too large.
Filter the groups before we map over them so that we can set padding
properly.

Fixes #2674
2020-04-09 15:08:06 +10:00
Liam Fitzgerald
e2f8be20de chat-fe: make copy status text inter 2020-04-09 14:13:23 +10:00
Liam Fitzgerald
648eced4ff chat-fe: copy patp to clipboard on author name click 2020-04-09 13:12:48 +10:00
Liam Fitzgerald
b4fb8d5163 chat-fe: show spinner on join
Shows the spinner whilst joining a channel, both manually and from a
url. Also fixes an issue where a newly joined channel may be navigated
away from automatically.
2020-04-09 12:48:55 +10:00
Liam Fitzgerald
3801056d3c invite-search: allow keyboard nav + selection
Allows the user to navigate potential invitees with the arrow keys and
with shift+tab and tab. Enter adds the currently selected invitee.
2020-04-09 08:03:21 +10:00
Matilde Park
839f9090bb various: alphabetise associations accesses obj
Previously we were checking for a title for the association by accessing
a non-existent property of the key we were using to iterate through
the object. What we want to do is access the iterated object to find
that title, and so this commit does that.
2020-04-07 17:35:02 -04:00