Commit Graph

32 Commits

Author SHA1 Message Date
Harrison Healey
4092836c94 PLT-1990 Closed markdown preview when edit post modal is closed (#5921) 2017-03-30 13:45:58 -04:00
bonespiked
28ad645153 Ticket 4665 - Emoji Picker (#5157)
*  #4665  Added EmojiPicker

Work primarily by @broernr-de and @harrison on pre-release.mattermost.com

* Final fixes to handle custom emojis from internal review and single merge error

* ESLint fixes

* CSS changes and other code to support emoji picker in reply window

* Fix for file upload and emoji picker icon positions on post and comment.

RHS emoji picker appearing see-through at this time.

* Fix for two ESLint issues.

* covered most of feedback:
RHS emoji picker looks correct color-wise
RHS emoji picker dynamically positions against height of thread size (post + reply messages)
escape closes emoji window
search box focused on open

ESLint fixes against other files
oversized emoji preview fixes

* Adding in 'outside click' eventing to dismiss the emoji window

* Changing some formatting to fix mismatch between my local eslant rules and jenkins.

* adding alternative import method due to downstream testing errors

* yet another attempt to retain functionality and pass tests - skipping import of browser store

* fix for feedback items 5 and 7:
* move search to float on top with stylistic changes
* whitespace in the header (+1 squashed commit)
Squashed commits:
[6a26d32] changes that address items
1, 2, 6, 8, and 9 of latest feedback

* Fix for attachment preview location on mobile

* Fix for latest rounds of feedback

* fixing eslint issue

* making emojipicker sprite based, fixing alignments

* Fix for emoji quality, fixing some behavior (hover background and cursor settings)
undoing config changes

* Preview feature for emojis

* Adjustments to config file, and changing layout/design of attachment and emoji icon.

* manual revert from master branch for config.json

* reverting paperclip and fixing alignments.  Additionally fixing inadvertent display of picker on mobile.

* CSS changes to try to fix the hover behavior - currently working for emoji picker (when enabled), but hover for attachment isn't working

* Made suggested changes by jwilander except for jQuery removal

* Adding hover for both icons

* removal of some usages of jQuery

* Fix for two layout issues on IE11/Edge

* UI improvements for emoji picker

* Fix for many minor display issues

* fix for additional appearance items

* fix to two minor UI items

* A little extra padding for IE11

* fix for IE11 scroll issue, and removing align attribute on img tag which was throwing js error

* fixes some display issues on firefox

* fix for uneven sides of emojis

* fix for eslint issues that I didn't introduce

* fix for missing bottom edge of RHS emojipicker.  also fixing text overlapping icons on text area (including RHS)

* Update "emoji selector" to "emoji picker"

* changes for code review
- removal of ..getDOMNode
- use sprite imagery for emoji preview
- remove lastBlurAt from state as it wasn't used

* fixes for:
- fake custom emoji preview in picker
- RHS scrollbar on preview

* fix for minor alignment of preview emoji
2017-03-24 09:09:51 -04:00
Robin Naundorf
54c699b7ca Fix typo (#5380)
* Replace 'recieve' with 'receive'
2017-02-13 15:29:54 +00:00
Harrison Healey
b3f2ab654e Made Edit Post Modal autocomplete always attach to the bottom of the textarea (#4956) 2017-01-04 14:11:37 -05:00
Asaad Mahmood
be5aa0398b Ui fixes (#4954)
* PLT-5102 - Adjusting whitespace for post textarea

* PLT-5099 - Fixing alignment for inputs

* PLT-5095 - Pending post controls z-index increase
2017-01-04 11:29:55 -05:00
Nick Frazier
0a1b0d051a Add error to RHS reply box for messages > 4000 chars, consistent with create post and edit post errors (#4871)
* functionality

* CSS updates

* cleanup

* moved message length checks to Textbox component

* cleanup
2016-12-26 09:25:50 -05:00
Nick Frazier
ed15f10b79 [PLT-4318] Display a message when post is over 4000 characters (#4687)
* test changes

* added functionality

* css updates

* additional css updates

* i18n updates

* textbox cleanup

* var naming tweak

* replaced jQuery with React-based UI changes
2016-12-06 18:49:36 -05:00
Harrison Healey
165ad0d4f7 PLT-1378 Initial version of emoji reactions (#4520)
* Refactored emoji.json to support multiple aliases and emoji categories

* Added custom category to emoji.jsx and stabilized all fields

* Removed conflicting aliases for :mattermost: and :ca:

* fixup after store changes

* Added emoji reactions

* Removed reactions for an emoji when that emoji is deleted

* Fixed incorrect test case

* Renamed ReactionList to ReactionListView

* Fixed 👍 and 👎 not showing up as possible reactions

* Removed text emoticons from emoji reaction autocomplete

* Changed emoji reactions to be sorted by the order that they were first created

* Set a maximum number of listeners for the ReactionStore

* Removed unused code from Textbox component

* Fixed reaction permissions

* Changed error code when trying to modify reactions for another user

* Fixed merge conflicts

* Properly applied theme colours to reactions

* Fixed ESLint and gofmt errors

* Fixed ReactionListContainer to properly update when its post prop changes

* Removed unnecessary escape characters from reaction regexes

* Shared reaction message pattern between CreatePost and CreateComment

* Removed an unnecessary select query when saving a reaction

* Changed reactions route to be under /reactions

* Fixed copyright dates on newly added files

* Removed debug code that prevented all unit tests from being ran

* Cleaned up unnecessary code for reactions

* Renamed ReactionStore.List to ReactionStore.GetForPost
2016-11-30 13:55:49 -05:00
Harrison Healey
e63e80dee0 PLT-4404/PLT-4578/PLT-4541/PLT-4542 Replaced third party autosizing textarea with a custom one (#4442)
* PLT-4578 Replaced third party autosizing textarea with a custom one

* Fix Textbox.handleHeightChange not being called

* Removed unused CSS

* PLT-4541 Force EditPostModal to resize upon opening

* Removed usage of jquery from AutosizeTextarea

* Reverted changes made for PLT-4580 as they're no longer needed
2016-11-04 12:35:38 -04:00
Mike Piccolo
dbdd719c51 PLT-4376 iOS and Android: Keep the keyboard open after sending a message (#4377)
* Force keyboard to retain focus on submitting post on mobile

* Fix lint error

* Allow keyboard to stay closed if the keyboard was closed earlier before submitting

* Increase delay time and add to comment

* Remove pass through props on suggestion box
2016-11-04 09:14:19 -04:00
Harrison Healey
9f6ba5e031 PLT-4595 Fixed post drafts and renamed some fields to be consistent (#4418)
* PLT-4595 Fixed post drafts and renamed some fields to be consistent

* Removed unused state from CreatePost
2016-11-01 15:46:41 -07:00
Joram Wilander
db80a819f7 Fix opening RHS (#4402)
* Fix opening RHS

* Add fix for draft itself
2016-11-01 08:30:33 -04:00
Harrison Healey
0741d3be0a PLT-4404 Replace calls to onInput with onChange to better support IE11 (#4315)
* Replace calls to onInput with onChange to better support IE11

* Replaced react-textarea-autosize with react-autosize-textarea
2016-10-25 10:11:34 -04:00
Joram Wilander
365b8b465e Merging performance branch into master (#4268)
* improve performance on sendNotifications

* Fix SQL queries

* Remove get direct profiles, not needed anymore

* Add raw data to error details if AppError fails to decode

* men

* Fix decode (#4052)

* Fixing json decode

* Adding unit test

* Initial work for client scaling (#4051)

* Begin adding paging to profiles API

* Added more paging functionality

* Finish hooking up admin console user lists

* Add API for searching users and add searching to all user lists

* Add lazy loading of profiles

* Revert config.json

* Fix unit tests and some style issues

* Add GetProfilesFromList to Go driver and fix web unit test

* Update etag for GetProfiles

* Updating ui for filters and pagination (#4044)

* Updating UI for pagination

* Adjusting margins for filter row

* Adjusting margin for specific modals

* Adding relative padding to system console

* Adjusting responsive view

* Update client user tests

* Minor fixes for direct messages modal (#4056)

* Remove some unneeded initial load calls (#4057)

* UX updates to user lists, added smart counts and bug fixes (#4059)

* Improved getExplicitMentions and unit tests (#4064)

* Refactor getting posts to lazy load profiles correctly (#4062)

* Comment out SetActiveChannel test (#4066)

* Profiler cpu, block, and memory profiler. (#4081)

* Fix TestSetActiveChannel unit test (#4071)

* Fixing build failure caused by dependancies updating (#4076)

* Adding profiler

* Fix admin_team_member_dropdown eslint errors

* Bumping session cache size (#4077)

* Bumping session cache size

* Bumping status cache

* Refactor how the client handles channel members to be large team friendly (#4106)

* Refactor how the client handles channel members to be large team friendly

* Change Id to ChannelId in ChannelStats model

* Updated getChannelMember and getProfilesByIds routes to match proposal

* Performance improvements (#4100)

* Performance improvements

* Fixing re-connect issue

* Fixing error message

* Some other minor perf tweaks

* Some other minor perf tweaks

* Fixing config file

* Fixing buffer size

* Fixing web socket send message

* adding some error logging

* fix getMe to be user required

* Fix websocket event for new user

* Fixing shutting down

* Reverting web socket changes

* Fixing logging lvl

* Adding caching to GetMember

* Adding some logging

* Fixing caching

* Fixing caching invalidate

* Fixing direct message caching

* Fixing caching

* Fixing caching

* Remove GetDirectProfiles from initial load

* Adding logging and fixing websocket client

* Adding back caching from bad merge.

* Explicitly close go driver requests (#4162)

* Refactored how the client handles team members to be more large team friendly (#4159)

* Refactor getProfilesForDirectMessageList API into getAllProfiles API

* Refactored how the client handles team members to be more large team friendly

* Fix js error when receiving a notification

* Fix JS error caused by current user being overwritten with sanitized version (#4165)

* Adding error message to status failure (#4167)

* Fix a few bugs caused by client scaling refactoring (#4170)

* When there is no read replica, don't open a second set of connections to the master database (#4173)

* Adding connection tacking to stats (#4174)

* Reduce DB writes for statuses and other status related changes (#4175)

* Fix bug preventing opening of DM channels from more modal (#4181)

* 	Fixing socket timing error (#4183)

* Fixing ping/pong handler

* Fixing socket timing error

* Commenting out status broadcasting

* Removing user status changes

* Removing user status changes

* Removing user status changes

* Removing user status changes

* Adding DoPreComputeJson()

* Performance improvements (#4194)

* * Fix System Console Analytics queries
* Add db.SetConnMaxLifetime to 15 minutes
* Add "net/http/pprof" for profiling
* Add FreeOSMemory() to manually release memory on reload config

* Add flag to enable http profiler

* Fix memory leak (#4197)

* Fix memory leak

* removed unneeded nil assignment

* Fixing go routine leak (#4208)

* Merge fixes

* Merge fix

* Refactored statuses to be queried by the client rather than broadcast by the server (#4212)

* Refactored server code to reduce status broadcasts and to allow getting statuses by IDs

* Refactor client code to periodically fetch statuses

* Add store unit test for getting statuses by ids

* Fix status unit test

* Add getStatusesByIds REST API and move the client over to use that instead of the WebSocket

* Adding multiple threads to websocket hub (#4230)

* Adding multiple threads to websocket hub

* Fixing unit tests

* Fixing so websocket connections from the same user end up in the same… (#4240)

* Fixing so websocket connections from the same user end up in the same list

* Removing old comment

* Refactor user autocomplete to query the server (#4239)

* Add API for autocompleting users

* Converted at mention autocomplete to query server

* Converted user search autocomplete to query server

* Switch autocomplete API naming to use term instead of username

* Split autocomplete API into two, one for channels and for teams

* Fix copy/paste error

* Some final client scaling fixes (#4246)

* Add lazy loading of profiles to integration pages

* Add lazy loading of profiles to emoji page

* Fix JS error when receiving post in select team menu and also clean up channel store
2016-10-19 14:49:25 -04:00
Christopher Speller
93f2b6a833 Updating ESLint (#4085) 2016-09-23 12:29:54 -04:00
Yi EungJun
bb69e98631 PLT-4182 Fix incorrect listing for at-mention in comment (#4031)
* Add missing eol

* PLT-4182 Fix incorrect listing for at-mention in comment

Suggestion box for at-mention listed users for the center channel even
if the current textbox is for reply for a post which belongs to a
different channel.
2016-09-19 17:41:19 -04:00
George Goldberg
8443ca5828 PLT-1759 - Auto-complete for !channels when posting messages. (#3890)
* Auto-complete for !channels when posting messages.

This is part 1 of the fix for PLT-1759 to make channels linkable.

Still to do:
- Make the !channels clickable when they appear in messages. This is
  blocked until PR #3865 is resolved as it looks like that refactors
  some of the code that would be touched by making this change.

- Unit tests. Again, I think the above referenced PR should be merged
  before tackling this.

* Fix style problems.

* Highlighting of !channel-names in messages.

This only identifies the !channel-name (not the display name). The
implementation of the auto-complete on channel names now needs to be
modified to convert to the channel handle before sending the message.

* Display !channel-name as !Display Name.

When we encounter !channel-name in a message, display it as a link using
the channel's actual name rather than it's handle (name).

* Match on names and display name, and use name.

* Autocomplete channels matching on both the name and the the display
  name.
* Use the name as the text we fill in instead of the display name. It's
  potentially a bit ugly, but it minimises complexity for now as
  otherwise we'd have to do complicated things to the message box.

* Fix style issues.

* Load more channels everywhere.

Whenever we load the list of channels, we should also load the list of
more channels. This is to enable auto-completing and auto-linking of all
channels whether or not the user is in them currently.

* Include more channels in the map for linking.

* Listen for channel list updates for autolinking.

* Remove accidental console.log.

* Autocomplete on more channels too.

* i18n for channel autocomplete.

* Link directly to channels in !channel mentions.

This currently does not work if you aren't a member of that channel.
Need to decide what the correct behaviour is in that case.

* Fix style issues.

* Show channel name and handle in suggestion.

* Match channels only at start or after space.

* Better matching in text-formatting.

Only match channels after a space-type character or at the start in the
posts list too.

* Move the route construction to make tests work.

Moves route-construction out of text_formatting.jsx and into utils.jsx
so that the unit tests work once again.
2016-09-19 08:21:22 -04:00
Harrison Healey
47f92441ac PLT-4100 Made SuggestionList dividers optional (#3990)
* Made SuggestionList dividers optional

* Stopped mutating the User object in the AtMentionProvider
2016-09-08 09:48:53 -03:00
enahum
c99db74390 PLT-4084 Fix Unable to send messages in RC (#3983) 2016-09-07 08:02:24 -04:00
enahum
024a72b440 PLT-4025 fixed so Ctrl+Enter works on windows (#3979) 2016-09-06 17:39:46 -04:00
enahum
a820b1640b PLT-2345 Switch "help" link below text input box to localizable version (#3794) 2016-08-18 14:36:43 -08:00
Harrison Healey
500b2dce10 Fixed input handlers used by Textbox and SuggestionBox components to properly update when typing quickly (#3598) 2016-07-15 10:37:51 -04:00
Asaad Mahmood
f91b9d4a65 PLT-3418, PLT-2950, PLT-3375, PLT-3382, PLT-3446, PLT-3465: Multiple UI Improvements (#3449)
Improving help text margins

Updating changes for get link and create post files

Fixing icon for select team screen

Fixing styles for select team button

Adding improvements to posts UI

Adding improvement to post layout

Updating changes for post controls

Updating z-index for sidebar--right

Updating help text position

Fixing code for posts

Fixing css for post view

Pushing improvements for posts view

Updating changes for post view

Updating post layout

Fixing system time css

Updating header for system posts

Updating post css

Removing opacity and changing color for system messages

Simplifying root post and system post behaviour

Removing images from compact view

Updating help text for display

Updating embed preview text for advanced option

PLT-3490 - Fixing RHS issue on Edge
2016-07-05 15:46:36 -04:00
enahum
65f51c7bc4 PLT-3056 Fix Unable to type quickly in post textbox in IE11 (#3249) 2016-06-06 14:54:02 -04:00
Christopher Speller
4b260b761a Updating client dependancies and ESLint (#2954)
* Updating client dependancies

* Fixing eslint errors with updates

* Updating eslint
2016-05-12 07:50:53 -04:00
samogot
b49dc28d7e Allow autocorrection in textbox (#2730)
* remove autocorrect=off attribute from textbox, allowing word suggestion in android keyboards

* autocomplete attribute is also involved for this keyboard feature
2016-04-28 08:26:44 -04:00
Asaad Mahmood
18c29e9ab2 Multiple UI Improvements 2016-03-30 20:16:10 +05:00
Asaad Mahmood
501eef0385 Additional UI improvements 2016-03-29 17:55:30 +05:00
Harrison Healey
f134df04b0 Switched Textbox to use a TextareaAutosize and removed custom resizing code 2016-03-21 09:49:29 -04:00
Christopher Speller
35320efe1a Revert "PLT-2183 Slash command auto-complete" 2016-03-18 13:16:51 -04:00
Nicolas Clerc
5e2596598f add external slashcommands management 2016-03-17 01:45:37 +01:00
Christopher Speller
12896bd23e Converting to Webpack. Stage 1. 2016-03-16 18:02:55 -04:00