discourse/plugins/chat/spec/services/chat
Joffrey JAFFEUX d8d756cd2f
DEV: chat streaming (#25736)
This commit introduces the possibility to stream messages. To allow plugins to use streaming this commit also ships a `ChatSDK` library to allow to interact with few parts of discourse chat.

```ruby
ChatSDK::Message.create_with_stream(raw: "test") do |helper|
  5.times do |i|
    is_streaming = helper.stream(raw: "more #{i}")
    next if !is_streaming
    sleep 2
  end
end
```

This commit also introduces all the frontend parts:
- messages can now be marked as streaming
- when streaming their content will be updated when a new content is appended
- a special UI will be showing (a blinking indicator)
- a cancel button allows the user to stop the streaming, when cancelled `helper.stream(...)` will return `false`, and the plugin can decide exit early
2024-02-20 09:49:19 +01:00
..
add_users_to_channel_spec.rb FEATURE: Allow users to DM groups in chat (#25189) 2024-01-19 11:09:47 -03:00
auto_join_channel_batch_spec.rb DEV: fixes flakey spec from auto-join-channel-batch (#23044) 2023-08-09 22:37:28 +02:00
create_category_channel_spec.rb FIX: Allow several chat channels to have an empty slug (#25680) 2024-02-15 00:39:39 +04:00
create_direct_message_channel_spec.rb DEV: Remove full group refreshes from tests (#25414) 2024-01-25 14:28:26 +08:00
create_message_spec.rb DEV: chat streaming (#25736) 2024-02-20 09:49:19 +01:00
create_thread_spec.rb DEV: adds a :chat_thread_created trigger (#24133) 2023-10-27 10:27:34 +02:00
flag_message_spec.rb DEV: uses in: {} with lambda to work with eager_load (#25039) 2023-12-29 12:45:07 +08:00
invite_users_to_channel_spec.rb FIX: ensures users can open channel invites (#24067) 2023-10-24 18:51:33 +02:00
leave_channel_spec.rb FIX: leaving a group channel should destroy membership (#24631) 2023-11-29 17:48:14 +01:00
list_channel_messages_spec.rb FIX: nullifies target message id when not readable (#24540) 2023-11-24 11:46:00 +01:00
list_channel_thread_messages_spec.rb DEV: Allow fab! without block (#24314) 2023-11-09 16:47:59 -06:00
lookup_channel_threads_spec.rb FEATURE: my threads page (#24771) 2023-12-11 07:38:07 +01:00
lookup_thread_spec.rb DEV: Remove experimental site setting for chat threads (#22720) 2023-07-26 12:46:23 +02:00
lookup_user_threads_spec.rb FEATURE: my threads page (#24771) 2023-12-11 07:38:07 +01:00
mark_all_user_channels_read_spec.rb DEV: Redesign chat mentions (#24752) 2024-01-17 15:24:01 +04:00
message_destroyer_spec.rb DEV: Refactor chat specs related to message creation 2023-08-31 11:21:23 +02:00
publisher_spec.rb DEV: Allow fab! without block (#24314) 2023-11-09 16:47:59 -06:00
restore_message_spec.rb FEATURE: add outgoing web hooks for Chat messages 2023-09-13 17:31:42 -03:00
search_chatable_spec.rb FEATURE: Allow users to DM groups in chat (#25189) 2024-01-19 11:09:47 -03:00
stop_message_streaming_spec.rb DEV: chat streaming (#25736) 2024-02-20 09:49:19 +01:00
tracking_state_spec.rb DEV: Remove experimental site setting for chat threads (#22720) 2023-07-26 12:46:23 +02:00
trash_channel_spec.rb
trash_message_spec.rb DEV: Redesign chat mentions (#24752) 2024-01-17 15:24:01 +04:00
unfollow_channel_spec.rb FIX: leaving a group channel should destroy membership (#24631) 2023-11-29 17:48:14 +01:00
update_channel_spec.rb FIX: use site setting to show my threads chat footer tab (#25277) 2024-01-23 19:14:46 +08:00
update_channel_status_spec.rb
update_message_spec.rb DEV: Remove full group refreshes from tests (#25414) 2024-01-25 14:28:26 +08:00
update_thread_notification_settings_spec.rb DEV: Refactor chat specs related to message creation 2023-08-31 11:21:23 +02:00
update_thread_spec.rb DEV: chat streaming (#25736) 2024-02-20 09:49:19 +01:00
update_user_last_read_spec.rb DEV: Redesign chat mentions (#24752) 2024-01-17 15:24:01 +04:00
update_user_thread_last_read_spec.rb DEV: Redesign chat mentions (#24752) 2024-01-17 15:24:01 +04:00
upsert_draft_spec.rb FEATURE: implements drafts for threads (#24483) 2023-11-22 11:54:23 +01:00