Commit Graph

174 Commits

Author SHA1 Message Date
Martin Brennan
f47ee8fd40
WIP: Figuring out messages in thread panel 2023-02-13 12:51:39 +10:00
Martin Brennan
ff90a56f5b
DEV: Test fix 2023-02-13 11:03:20 +10:00
Martin Brennan
dd9059917f
DEV: Review fixes 2023-02-13 10:40:14 +10:00
Martin Brennan
176070cd78
Merge branch 'main' into chat-side-panel-initial-skeleton-threads 2023-02-13 10:30:42 +10:00
Joffrey JAFFEUX
e4738cb1bc
FIX: correctly listens to chat notifications (#20246)
This change will ensure we enter and subscribe to presence channels on start and will use the correct "change" events from presence channel to update state.
2023-02-12 23:26:11 +01:00
Kris
8bc9acc414
A11Y: Header icons should be buttons, not links (#20242) 2023-02-10 13:55:51 -05:00
Joffrey JAFFEUX
1a9cb0914c re-adds @tracked activeChannel 2023-02-10 12:47:10 +01:00
Joffrey JAFFEUX
074e7ad4ed
Merge branch 'main' into chat-side-panel-initial-skeleton-threads 2023-02-10 12:25:59 +01:00
Jan Cernik
8121565631
FIX: Chat's user autocomplete threw errors (#20236) 2023-02-10 11:41:46 +01:00
Martin Brennan
c9776fe84d
DEV: Change setActiveChannel to get/set in services/chat (#20237)
Per PR comment in #20209, we don't need to do setActiveChannel,
we can just use native get/set instead.
2023-02-10 11:41:29 +01:00
Martin Brennan
bf2a9063f6 DEV: Fix tracking for activeThread 2023-02-10 16:05:32 +10:00
Martin Brennan
54a4251b8e DEV: Fix lint 2023-02-10 15:41:31 +10:00
Martin Brennan
eaa49e3764 DEV: Use @tracked for activeThread 2023-02-10 15:33:15 +10:00
chapoi
00ddfd761a UX: apply grid for chat-view only 2023-02-10 12:31:29 +07:00
Martin Brennan
be8968b05b DEV: Add mainOutletModifierClasses for chat main outlet
The main outlet needs different styles based on the route,
and whether the sidebar is expanded.
2023-02-10 15:16:05 +10:00
Martin Brennan
218dbc249a
DEV: Fix routing not nulling channel/thread 2023-02-10 10:16:25 +10:00
Martin Brennan
f6081a9277
DEV: Review fixes 2023-02-10 09:25:02 +10:00
Martin Brennan
9810c9aba5
DEV: Fix mobile thread full style 2023-02-09 16:47:21 +10:00
Martin Brennan
77fb4fb2f2 DEV: Fix mobile thread spec 2023-02-09 15:50:22 +10:00
chapoi
81cd3d32f9 UX: side-panel on mobile 2023-02-09 12:25:37 +07:00
Martin Brennan
b33883db2c DEV: Spec for opening thread on mobile 2023-02-09 15:11:44 +10:00
chapoi
d93cdec8bb UX: BEM 2023-02-09 12:09:59 +07:00
chapoi
4a633597f4 UX: moved padding to different level 2023-02-09 12:06:13 +07:00
chapoi
c9f6cfce62 FIX: moved msg out header div 2023-02-09 12:05:55 +07:00
chapoi
769648652e UX: add missing flex prop 2023-02-09 12:02:36 +07:00
chapoi
827980903f UX: remove flex from side-panel 2023-02-09 12:02:01 +07:00
chapoi
fc65cdacc3 UX: add grid-area 2023-02-09 12:00:17 +07:00
chapoi
e7b810e0f9 Merge branch 'chat-side-panel-initial-skeleton-threads' of https://github.com/discourse/discourse into chat-side-panel-initial-skeleton-threads 2023-02-09 11:40:17 +07:00
chapoi
ca7b55d368 UX: use BEM modifier format 2023-02-09 11:22:46 +07:00
Martin Brennan
588e812d33 DEV: Add started by and avatar align and more specs 2023-02-09 14:07:31 +10:00
Martin Brennan
5699facfca
DEV: Start thread system specs 2023-02-09 13:33:38 +10:00
Martin Brennan
b598635753
Merge branch 'main' into chat-side-panel-initial-skeleton-threads 2023-02-09 11:15:41 +10:00
Martin Brennan
9108ef0383 WIP: Chat side panel skeleton 2023-02-08 17:01:12 +10:00
chapoi
d33d98f9c1
FIX: changed classname for YT images (#20212) 2023-02-08 05:57:36 +01:00
Joffrey JAFFEUX
a04201ae01
UX: implements a random and auto generated skeleton (#20202)
UI is not modified much besides removing the border-bottom, and using only message body.

However instead of having a fix template, this is all automatically generated and random, resulting in a more natural experience.
2023-02-07 22:48:10 +01:00
Joffrey JAFFEUX
b755b45029
FIX: apply max-height on the outer container (#20199)
This change allow to correctly work with the topic composer height changing.
2023-02-07 22:00:00 +01:00
Joffrey JAFFEUX
7dcaaec90c
UX: allows drawer to take most of height space (#20197)
Only the header's height and 15px spacing are removed from the height of the viewport.

Previously it was limited to 90vh and there was also a useless property on a child node limiting it to 85vh. We now use only one property.
2023-02-07 19:49:00 +01:00
Joffrey JAFFEUX
b89df3ca9d
DEV: refactors routes to simplify using outlet (#20179)
This work will allow us to have an {{outlet}} chat.channel route and use it for threads as a sidepanel.
2023-02-07 13:59:32 +01:00
Joffrey JAFFEUX
f4b56ea455
UX: orders public channels by slug instead of title (#20188)
Public channels were previously sorted by name, however, channels with a leading emoji in the name would always appear first in the list. By using slug we avoid this issue.
2023-02-07 10:36:28 +01:00
chapoi
2f8ad17aed
UX: apply same style for highlight mention span (#20176) 2023-02-06 10:56:52 +01:00
Martin Brennan
c3ace5ea8b
FEATURE: Inline audio player for chat uploads (#20175)
Similar to https://github.com/discourse/discourse-chat/pull/1283,
this adds the <audio> inline player for uploaded audio files in
chat channels.
2023-02-06 16:00:03 +10:00
Roman Rizzi
85e1a4934b
REFACTOR: Move mention warnings logic into a separate service. (#19465)
First follow-up to the feature introduced in #19034. We don't want to pollute main components like `chat-live-pane`, so we'll use a service to track and manage the state needed to display before-send warnings while composing a chat message.

We also move from acceptance tests to system specs.
2023-02-03 15:38:30 -03:00
Jan Cernik
44df5ee7c8
FIX: Allow keyboard navigation when searching emojis in chat (#20157) 2023-02-03 11:36:45 -03:00
Joffrey JAFFEUX
d5024d96f1
FEATURE: resizeable chat drawer (#20160)
This commit implements a requested feature: resizing the chat drawer.

The user can now adjust the drawer size to their liking, and the new size will be stored in localstorage so that it persists across refreshes. In addition to this feature, a bug was fixed where the --composer-right margin was not being correctly computed. This bug could have resulted in incorrectly positioned drawer when the composer was expanded.

Note that it includes support for RTL.
2023-02-03 15:11:12 +01:00
Joffrey JAFFEUX
24f026c895
FIX: correctly filters input with pre-filled value (#20154)
Before this fix we would fill the input but that wouldn't trigger the actual filtering.
2023-02-02 23:49:36 +01:00
Jan Cernik
6325e641d8
FIX: Emoji autocomplete “more” button not working in chat (#20113)
* FIX: Emoji autocomplete “more” button not working

* Rely on setting an intial value on the filter input

This commit removes custom logic applied on initial filter and instead gives a param to use as value for the input, automatically triggering the existing filtering handler.

Other notes:
- Slightly changes the API to be able to set a filter and open the composer in one go
- Adds a very simple service spec
- Adds a system spec to fully validate the behavior

---------

Co-authored-by: Joffrey JAFFEUX <j.jaffeux@gmail.com>
2023-02-02 15:04:52 -03:00
David Taylor
fa30ab4ed7 DEV: Correct hbs prettier violations 2023-02-02 13:03:11 +00:00
Joffrey JAFFEUX
dd4b282196
FIX: reverts value check when reseting composer value (#20110)
This change was made to prevent composer input to be reset randomly during tests but this is causing more issues for now: most notably composer state not being reset when changing channel. This will need a better solution.
2023-02-01 17:45:33 +01:00
Roman Rizzi
5c699e4384
DEV: Pass messageId as a dynamic segment instead of a query param (#20013)
* DEV: Rnemae channel path to just c

Also swap the channel id and channel slug params to be consistent with core.

* linting

* channel_path

* Drop slugify helper and channel route without slug

* Request slug and route models through the channel model if possible

* DEV: Pass messageId as a dynamic segment instead of a query param

* Ensure change is backwards-compatible

* drop query param from oneboxes

* Correctly extract channelId from routes

* Better route organization using siblings for regular and near-message

* Ensures sessions are unique even when using parallelism

* prevents didReceiveAttrs to clear input mid test

* we disable animations in capybara so sometimes the message was barely showing

* adds wait

* ensures finished loading

* is it causing more harm than good?

* this check is slowing things for no reason

* actually target the button

* more resilient select chat message

* apply similar fix to bookmark

* fix

---------

Co-authored-by: Joffrey JAFFEUX <j.jaffeux@gmail.com>
2023-02-01 12:39:23 -03:00
David Taylor
9e440dca33 DEV: Rename all uses of PluginOutlet @args in core
The `args` argument is now deprecated. This commit uses a codemod (https://github.com/discourse/discourse-ember-codemods/tree/main/transforms/rename-plugin-outlet-args) to automatically rename all uses to `@outletArgs`.
2023-01-31 13:51:25 +00:00