Commit graph

19 commits

Author SHA1 Message Date
Nick Taylor
86eb75cee7
Report a Message in Connect (#12229)
* Frontend Ready for Connect Report Abuse

* add feedback api

* js defination fix

* Added Hooks to the Component

* add json response in feedback

* Block popup added

* fix render issue

* Made changes in internal view

* change error message

* Added few design changes =

* add test cases

* Update app/javascript/chat/actions/requestActions.js

Co-authored-by: Nick Taylor <nick@iamdeveloper.com>

* add PR suggestions

* add backend test cases

* report abuse form close

* Update app/javascript/chat/actions/requestActions.js

Co-authored-by: Nick Taylor <nick@iamdeveloper.com>

* Update app/javascript/chat/ReportAbuse/index.jsx

Co-authored-by: Nick Taylor <nick@iamdeveloper.com>

* add test cases

* Update app/javascript/chat/ReportAbuse/index.jsx

Co-authored-by: Nick Taylor <nick@iamdeveloper.com>

* Update app/javascript/chat/ReportAbuse/index.jsx

Co-authored-by: Marcy Sutton <holla@marcysutton.com>

* Update app/javascript/chat/ReportAbuse/index.jsx

Co-authored-by: Marcy Sutton <holla@marcysutton.com>

* group the fieldset

* fix report abuse api

* fix test case

* fix request test case

* fix typo

* cleaned up markup in report abuse component.

* Fixed spacing between abuse options.

* Fixed wording in report abuse confirmation.

* Removed unnecessary data-testid and aria-label attributes.

* Added some top margin to the report abuse form.

* Update app/javascript/chat/message.jsx

Co-authored-by: Suzanne Aitchison <suzanne@forem.com>

* Added a legend to the the fieldset.

* Update app/javascript/chat/actions/requestActions.js

Co-authored-by: Michael Kohl <citizen428@dev.to>

Co-authored-by: Sarthak <7lovesharma7@gmail.com>
Co-authored-by: Narender Singh <narender2031@gmail.com>
Co-authored-by: Marcy Sutton <holla@marcysutton.com>
Co-authored-by: Suzanne Aitchison <suzanne@forem.com>
Co-authored-by: Michael Kohl <citizen428@dev.to>
2021-01-19 12:07:47 -05:00
Timothy Ng
a943f045c5
Connect: Highlight @ mentions to logged in user (#10216)
* Wrap with <mark> tags if mentioning current user

* Add test for @mention highlight

* Match @{username} mention

* Remove default param
2020-10-07 23:23:58 -04:00
Bolarinwa Balogun
2995687d0c
Move edit and delete buttons on chat messages to dropdown menu (#7820)
* Move edit and delete buttons on chat messages to dropdown menu

* Move edit and delete buttons on chat messages to dropdown menu

* Use 'up arrow' as shortcut to edit last message

* Use 'delete key' as shortcut to delete last message

* Change span to button and handle case when lastMessage is undefined

* Fix up code

* Fix code
2020-06-29 14:14:23 +02:00
Nick Taylor
653ec12300
Upgrade to Preact 10.4.4 (#8739)
Co-authored-by: Nick Taylor <nick@iamdeveloper.com>
Co-authored-by: Ridhwana <Ridhwana.Khan16@gmail.com>
2020-06-18 10:07:17 -04:00
Ben Halpern
5812ecc383
Open /connect sidecar links in iframe (#5203) [deploy]
* Use iframe for connect sidecar

* Modify css of lefthand sidebar

* Add proper sidecar markup

* Update tests
2019-12-21 15:46:36 -05:00
Ben Halpern
cb3a0c462c
Separate chat channel unopened status from Algolia (#5198) [deploy] 2019-12-21 13:05:16 -05:00
Sarthak Sharma
b602b7b91f 🚀Feature/ability to edit messages (#5139) [deploy]
* Feature 🚀 : Ability to delete messages in chat channels

- Sending message ID to frontend
- Deleting Message
- Use pusher to delete message realtime

* Minor Bug 🐞: Show message action only for current user

- User can delete or edit their own messages

* Test cases added

* Bug 🐞: Update message id for receiver

Message id was not sent to receiver by pusher

* Refactoring🛠: Message controller refactoring

* Test Cases📝 : Specs for Delete message added

* Feature 🚀 : Ability to edit messages

* Test Cases📝 : Specs for Edit message added

* Refactoring🔩: Refactoring for edit messages

* Refactoring🔩: Refactoring:2 for edit messages

* Refactoring🔩: Refactoring:2 for edit messages

* Test Cases📝 : Test Cases for edit message added

* Minor Bug 🐞: Show message action only for current user

- User can delete or edit their own messages

* Test cases added

* Bug 🐞: Update message id for receiver

Message id was not sent to receiver by pusher

* Feature 🚀 : Ability to edit messages

* Test Cases📝 : Specs for Edit message added

* Refactoring🔩: Refactoring for edit messages

* Refactoring🔩: Refactoring:2 for edit messages

* Refactoring🔩: Refactoring:2 for edit messages

* Bug Fix 🐞: Added space between edited and timestamp

Co-authored-by: Ben Halpern <bendhalpern@gmail.com>
2019-12-20 10:19:00 -05:00
Ben Halpern
c746da3a5e
Remove unused "Edit" button as follow-on to #5056 (#5071) [deploy]
* Feature 🚀 : Ability to delete messages in chat channels

- Sending message ID to frontend
- Deleting Message
- Use pusher to delete message realtime

* Minor Bug 🐞: Show message action only for current user

- User can delete or edit their own messages

* Test cases added

* Bug 🐞: Update message id for receiver

Message id was not sent to receiver by pusher

* Refactoring🛠: Message controller refactoring

* Test Cases📝 : Specs for Delete message added

* Remove edit button and modify css
2019-12-10 14:15:56 -05:00
Sarthak Sharma
4db5399ee8 Feature🚀: Ability to Delete Messages realtime (#5056)
* Feature 🚀 : Ability to delete messages in chat channels

- Sending message ID to frontend
- Deleting Message
- Use pusher to delete message realtime

* Minor Bug 🐞: Show message action only for current user

- User can delete or edit their own messages

* Test cases added

* Bug 🐞: Update message id for receiver

Message id was not sent to receiver by pusher

* Refactoring🛠: Message controller refactoring

* Test Cases📝 : Specs for Delete message added
2019-12-10 13:58:34 -05:00
Tamas Fodor
76e099599b Fix eslint lints in chat's jsx files (#4302) [deploy] 2019-11-04 15:51:30 -05:00
Ben Halpern
5f3fd96960
Modify social share button and functionality (#2316)
* Modify social share button and functionality

* Some nightmode changes tossed in

* Style adjustments and test snapshot fix
2019-04-06 14:49:52 -04:00
Ben Halpern
277739609e
Adjust location of timestamps (#447) 2018-06-14 19:08:19 -04:00
Ben Halpern
fb20b8adf7
Add content sidecar for chat (#413)
* Rearchitect chat channel subscriptions

* Add browser push notifications (attempt)

* Add content sidecar for chat

* Add live code basics

* Add content features to chat

* Fix chat_channels test
2018-06-11 11:00:51 -04:00
Ben Halpern
bf56ad5cb4
Add message HTML and other goodies (#411) 2018-06-08 23:15:21 -04:00
Mac Siri
2c456dcf86 Update Chat (#342)
* Remove the need for hiddenMessage class

* Prevent compose component from being re-rendered

* Add IntersectionObserver polyfill
2018-05-23 09:10:00 -04:00
Mac Siri
7cb65649e4 Update chat app (#326)
* Fix spacing

* Update webpacker gem to 3.5

* Add custom preact-compact config

* Add babel-loader to resolve a weird issue

* Add react-textarea-autocomplete

* Move 2 dependencies into devDependencies

* Add babel-eslint & eslint-plugin-babel

* Refactor chat

* Add fixed width to chat's channels

* Add timestamp for chat

* Fix long word issue

* Add showTimestamp options to chat

* Add profile image to chat

* Make profile image in chat circle

* Improve message send logic

* Add proper user session handling for chat

* Choose profile user image source for chat

* Adjust user's text color

* Fix lint
2018-05-21 13:19:56 -04:00
Mac Siri
b4292ade33 Implement chatroom (#308)
* Fix multiple chat loading bug

* Open profile links in chat via new tab

* Add unmount handling for chat

* Add overscroll property to chat

* Add channel_name to ChatChannel model

* Create route and page for chatroom WIP

* Expose ChatChannel id to live page

* Implement multichannel support WIP

* Implement chatroom page WIP

* Add css for chatroom

* Update chat's moderation

* Refactor chat's message type

* Swap the use of :message_markdown & :message_html

* Add channel permissions WIP

* Fix failing specs

* Adjust json reponses

* Add empty message prevention

* Update participant error message

* Change Workshop channel to General
2018-05-14 12:50:32 -04:00
Mac Siri
0f35939906 Update chat app's features (#204)
* Update chat.scss --skip-ci

* Fix height issue

* Add highlighting

* Implement bannged user handling for chat

* Add scroll obsever

* Limit initial messages load count & max messages

* Add new message alert when scrolled

* Add link to usernames in chat

* Implement channel clearing feature

* Update parserOptions

* Implement banning feature for chat app WIP

* Add policy for ChatChannelsController

* Fix arugment error

* Update user_not_authorized to handle JSON request

* Update specs for updated user_not_authorized

* Update font-weight for windows os
2018-04-16 13:20:12 -07:00
Mac Siri
8003191a4e Create Chat app (#175)
* Setup Pusher gem

* Create ChatChannel and Message model

* Create ChatChannelController

* Add back fix-db-schema-conflicts gem

* Add pusher-js package

* Add validations on Message & ChatChannel models

* Update Route

* Create MessageController

* Update ChatChannelController

* Create Chat app WIP

* Extract messenger render to Message Component

* Implement live chat WIP

* Implement live chat WIP (2)

* Add style and scrollToBottom feature for chat

* Create getUserDataAndCsrfToken function

* Add feature toggle to the new live chat

* Clean up ChatChannelsController & create spec

* Update ChatChannel spec

* Update Message spec

* Create MessagesController spec & refactor

* Clean up Chat app

* Fix lint

* Add character limit to Message
2018-04-04 14:19:57 -07:00