Commit graph

109 commits

Author SHA1 Message Date
Elias Nahum
46d7a17d4a
Fix edit post input text selection (#4647) 2020-08-06 17:23:53 -04:00
Miguel Alatzar
4992052fb0
Set results count to 0 (#4629) 2020-07-30 21:32:07 -07:00
Mattermost Build
838a52221f
Fix autocomplete after cache delete (#4623) (#4625)
(cherry picked from commit 9f98b943e7)

Co-authored-by: Shota Gvinepadze <wineson@gmail.com>
2020-07-30 15:51:24 -04:00
Shota Gvinepadze
be2211a8cc Add analytics to the command autocomplete (#4597)
* Add analytics to the command autocomplete

* Refactor analytics

* Refactor reset method
2020-07-23 20:40:18 +04:00
Mattermost Build
aafc68a0e6
Automated cherry pick of #4579 (#4592)
* Implement non-cached autocomplete for mobile

* Add partial caching support

* Fix whitespace

* Implement suggestion fetching using actions

Co-authored-by: iomodo <wineson@gmail.com>
2020-07-20 16:57:28 -04:00
Hossein Ahmadian-Yazdi
b6eb3b9349
[MM-23158] Group Mentions & Invites - Display group mentions in suggestions list in the main channel textbox (#4118)
* groups in group mention

* fix sorting issues

* address PR comments

* fix tests

* Update groups.ts

* fix nock

* fix translations

* Adding test

* fix linting

* update redux functions

* Add license check

* adddress PR comments

* remove lodash import

* fix lint problems

* revert package.json changes

* Address PR comments

* address PR comments

* fix naming

* address PR comments

* address PR comments

* Address comments found in second PR

* getAllGroups updated

* address PR comments

* Update app/mm-redux/utils/group_utils.ts

Co-authored-by: Elias Nahum <nahumhbl@gmail.com>

* revert change

* remove unneeded actions

* Use correct server version

* MM-26631: Fix order of group displaying

* MM-26633: Fix group mentions not showing up in group constrained team

* MM-26636: Group mentions not updating when role updates

* MM-26637: Group name not updating right away

* Address PR comments

* TRY AND catch

* address PR comments

Co-authored-by: Elias Nahum <nahumhbl@gmail.com>
2020-07-08 07:31:58 -04:00
Miguel Alatzar
2ccf2dc716
[MM-26077] Emoji autocomplete fixes (#4512)
* Use 0 height over null and move fuse

* Deconstruct props

* Update app/components/autocomplete/emoji_suggestion/emoji_suggestion.js

Co-authored-by: Elias Nahum <nahumhbl@gmail.com>

* Update app/components/autocomplete/emoji_suggestion/emoji_suggestion.js

* Update snapshot

Co-authored-by: Elias Nahum <nahumhbl@gmail.com>
2020-07-02 10:24:19 -07:00
Amit Uttam
99ee105e17
MM-13076 Start with store results for at-mention/search autocomplete (#4385)
Currently, at-mention and search autocomplete do not render if there is a server request or network problem/outage, because the only data used to populate autocomplete results is a server request.

Now, these autocompletes will render initially with user data currently in store, and then re-rendered in place, once the server response completes.
2020-06-08 14:13:38 -03:00
Amit Uttam
d869ddf8e5
MM-24029 Fix date re-selection on search bar (#4368)
Picking a new date string (tapping a date on the autocomplete calendar) to replace an already populated date string in the search bar, leaves the search text garbled. This was because of incorrect handling of the tap cursor position in the search box.
2020-05-29 13:29:25 -03:00
Elias Nahum
1568e08055
MM-25470 Fix emoji autocomplete results (#4344)
* Fix emoji autocomplete results

* Rename selectors with "select" prefix
2020-05-26 16:03:11 -04:00
Elias Nahum
d3a6e166ad
MM-15758 Update dependencies including Fastlane (#4272)
* Update dependencies including Fastlane and disable Flipper on iOS

* Remove EventEmitter for previous doc-viewer

* Fix android crash when setting more channels buttons

* Downgrade fuse.js

* Upgrade deps to latest

* Update Podfile.lock

* Downgrade RNN to 6.4.0

* QA Review #2

* Upgrade fuse.js to 6.0.0
2020-05-18 11:24:47 -07:00
Elias Nahum
1ae5584cb1
MM-24115 Use Native + BuiltIn emojis instead of systemEmojis (#4274)
* MM-24115 Use BuiltInEmojis instead of systemEmojis

* Address QA found issues
2020-05-13 18:23:47 -04:00
Farhan Munshi
901f31ec4b
[MM-24891] [MM-24572] Add ability to specify default value when role not found for selector (#4277)
* MM-24891 Allow permissions to have defaults set in case where roles not in state

* MM-24891 Add tests for haveIPermission

* MM-24891 Apply the defaults to more channel permission checks
2020-05-08 14:19:33 -04:00
Amit Uttam
42f93769b1
Revert "MM-24113 Support 'leave' slash command (#4273)" (#4279)
This reverts commit fd450f9988.
2020-05-07 14:40:54 -03:00
Amit Uttam
fd450f9988
MM-24113 Support 'leave' slash command (#4273)
Fixes crash on Android when attempting to redirect back to a read-only channel (default channel) after using the `/leave` command.

Also, enables official support of `leave` slash command. Added as auto-complete suggestion.
2020-05-07 13:58:09 -03:00
Elias Nahum
1a605891fe
MM-22401 Refactor Post Draft (#4122)
* Babel TS and Eslint config

* Channel is archived component

* Move Typing component

* Move Uploads component

* Add PostInput component

* QuickActions components

* Add PostDraft component

* Remove old PostTextbox component

* Rename post_textbox constant

* Fix Autocomplete

* Rename blur post draft event

* Fix references

* Feedback review

* Fix autocomplete for iOS
2020-05-06 06:30:51 -04:00
Miguel Alatzar
8bb43ca4c2
[MM-22632] Set vertical padding for SlashSuggestionItemi (#4125)
* Set minHeight

* Replace minHeight with paddingVertical
2020-04-08 11:08:59 -04:00
shred86
717350adc6
[MM-23755] Add nickname as searchable property (#4099)
* Add nickname search functionality

* Add username property to test

* Fix parentheses out of place

* Add nickname property to additional tests

* Added ability to truncate long names

* Minor clean up

* More minor clean up
2020-04-06 17:48:06 -04:00
Miguel Alatzar
ee4b85edcf
[MM-23520] Port mattermost-redux (#4088)
* Remove mattermost-redux

* Move mm-redux files into app/redux

* Add @redux path to tsconfig.json

* Fix imports

* Install missing dependencies

* Fix tsc errors

* Fix i18n_utils test

* Fix more imports

* Remove redux websocket

* Fix tests

* Rename @redux

* Apply changes from mattermost-redux PR 1103

* Remove mattermost-redux mention in template

* Add missing imports

* Rename app/redux/ to app/mm-redux/

* Remove test file

* Fix fetching Sidebar GM profiles

Co-authored-by: Elias Nahum <nahumhbl@gmail.com>
2020-03-31 11:09:26 -07:00
Elias Nahum
8fbc988c90
Upgrade Dependencies (#4034)
* Upgrade Navigation library

* Fix background color on Select Server

* Upgrade Navigation library

* Apply patch to nav lib

* Upgrade RNN to 6.1.1

* Update Dependencies

* Feedback review

* Call clearNavigationComponents when reset to channel
2020-03-18 19:05:49 -03:00
Elias Nahum
3af9af68e4
MM-22318 Fix autocomplete selection char code for native emojis (#4040) 2020-03-17 12:48:22 -07:00
Farhan Munshi
7952b5aeb7
[MM-21923] Enforce channel mentions permission (#3875)
* MM-21923 Enforce channel mentions permission by hiding it from autocomplete and disabling @mention confirmation modal

Add tests for post_textbox channel mentions

* MM-21923 Set use channel mentions to true if server version is not minimum required

* MM-21923 Point to specific redux hash and update permission check to be easier to read

* MM-21923 Fix currentChannel.id
2020-02-26 18:41:47 -07:00
Miguel Alatzar
a8f0314067
[MM-22078] [MM-22083] Sort emojis in EmojiPicker (#3865)
* Sort emojis in EmojiPicker

* Pass search term to compareEmojis

* Sort emojis that include search term first

* Fix sorting

* Handle compareEmojis without search term

* Return doDefaultComparison

* Check includes only if needed

* Make linter happy

* Use doDefaultComparison
2020-01-28 15:04:59 -07:00
Elias Nahum
1e0095d465 MM-21892 Fix TypeError cause by mm-redux#1006 (#3837) 2020-01-21 08:53:01 -07:00
Elias Nahum
7c09334dc4
Deps update (#3806)
* Dependecy updates

* Update dependencies
2020-01-20 13:20:03 -03:00
Miguel Alatzar
6879388d04
[MM-21184] Enabled Hermes (#3814)
* Enable Hermes

* Don't sort emojis in selector

* No need for transformer

* Remove unnecessary packager files
2020-01-16 12:56:44 -07:00
Chris Dobson
ce53a7ac29 MM-18571: Include self user in autocomplete (#3761)
* Include current user in search

* Removed unused parameters

* Include new text in i18n

* Update autocomplete tests to include current user

* Use FormattedText

* Update app/selectors/autocomplete.test.js

Co-Authored-By: Miguel Alatzar <migbot@users.noreply.github.com>

Co-authored-by: Miguel Alatzar <migbot@users.noreply.github.com>
2020-01-09 19:47:40 +08:00
Nev Angelova
f6addb491b [GH-11437] Fix thumbs emoji sorting logic for mobile (#3633)
* [GH-11437] Fix thumbs emoji sorting logic for mobile

* Add unit tests

* Sort emojis in selector and handle string emojis

* Remove redundant serverVersion logic

* Fix typo in app/utils/emoji_utils.test.js

Co-Authored-By: Saturnino Abril <saturnino.abril@gmail.com>
2019-12-08 10:10:56 -03:00
Miguel Alatzar
2397224f8e Show autocomplete view only when there are children (#3665) 2019-12-06 13:36:07 -05:00
Miguel Alatzar
2393eb3283 [MM-20200] Fix autocomplete when editing channel header (#3595)
* Fix autocomplete when editing channel header

* Fix iOS scroll

* Use zIndex on header help text view

* No need to use innerRef

* Fix typos
2019-11-28 01:43:28 +08:00
Elias Nahum
b2e657b159 MM-19991 Filtering search by channel should also show the channel name and not only its ID (#3561) 2019-11-18 23:56:01 +08:00
Elias Nahum
17a7054ae6 MM-19993 Fix Channel spinner is black on dark theme (#3558) 2019-11-18 22:04:52 +08:00
Elias Nahum
f8f9064968
MM-18999 Fix search in: modifier to show the appropriate badge when n… (#3343)
* MM-18999 Fix search in: modifier to show the appropriate badge when needed for DM/GM

* feedback review

* fix eslint

* fix eslint disable rule
2019-10-02 21:30:13 +03:00
Elias Nahum
3b3a696a55 MM-18603 Fix post header to prevent overlaps (#3332)
* MM-18603 Fix post header to prevent overlaps

* Export BotTag and GuestTag
2019-09-27 17:16:36 -04:00
Elias Nahum
9975a19b91
MM-18236 Prevent the post menu from triggering when using the back gesture (#3319)
* MM-18236 Prevent the post menu from triggering when using the back gesture in the thread screen

* Update snapshots

* Update app/components/touchable_with_feedback/touchable_with_feedback.ios.js

Co-Authored-By: Miguel Alatzar <migbot@users.noreply.github.com>

* Update app/components/touchable_with_feedback/touchable_with_feedback.ios.js

Co-Authored-By: Miguel Alatzar <migbot@users.noreply.github.com>

* Update app/components/post/post.js

Co-Authored-By: Miguel Alatzar <migbot@users.noreply.github.com>

* Update app/components/touchable_with_feedback/touchable_with_feedback.ios.js

* Fix eslint
2019-09-26 00:19:49 +03:00
Elias Nahum
114a18c16d
MM-18453 Use native emojis (#3260)
* MM-18453 Use native emojis

* Remove unnecessary else statement

* Add support for builtIn emojis

* Fix Native emojis snapshot tests

* Set emoji text style from StyleSheet

* Remove unneded version check and try/catch

* Add builtIn emojis as custom emojis in emojiPicker

* Simplify emojiPicker lists and fix jumping section headers

* Update snapshots
2019-09-25 12:27:47 +03:00
Elias Nahum
70102d2516 MM-18752 Rename constant to handle iPhone X and new iPhone 11 insets (#3296) 2019-09-23 13:08:32 -07:00
Hossein Ahmadian-Yazdi
ef8813f115 [MM-13843] Edit channel autocomplete is same as the posting message one (#3038)
* [MM-13843] Edit channle autocomplete is same as the posting message

* [MM-13843] Lint error fixes

* [MM-13843] Address nestedscrollenable warning comment

* [MM-13843] Added test case for edit_channel_info

* [MM-13843] nestedScrollEnabled on at_mention

* [MM-13843] Fix linting issue

* [MM-13843] Fixed test case

* [MM-13843] Address PR comments

* [MM-13843] Made prop not required
2019-08-15 21:22:32 -07:00
Elias Nahum
06e333dc52
MM-10193 Apply SafeAreaView to Landscape views (#3003) (#3081)
* MM-10193 for landscape Feature

Commit for MM-10193 to the landscape feature with latest pull.
This is the initial commit with SafeAreaView in place, but should not be merged into master as this is step one and not suitable for production.
Another commit will be following with adjustments to allow SafeAreaView to display correctly for users.

* MM-10193 for landscape Feature

Commit for MM-10193 to the landscape feature with latest pull.
This is the initial commit with SafeAreaView in place, but should not be merged into master as this is step one and not suitable for production.
Another commit will be following with adjustments to allow SafeAreaView to display correctly for users.

* MM-10193 Extend design elements for iPhoneX SafeAreaViews

This is the second portion of the MM-10193 changes for the landscape feature. This item was to extend the design elements for the application into the SafeAreaView so the application looks uniform on the iPhoneX.

* MM-10193 Patch for Snapshot tests and eslint

* MM-10193 Re-Patch

These chanbes mistakenly got reverted from last Patch

* MM-10193 Updates for PR

Fixed the 4 screens from the text box that were missed.
Updated the padding to run from a method.

* Revert "MM-10193 Updates for PR"

This reverts commit fe8d650ce3ca2828d8c94e4af470649aa2582ec1.

* MM-10193 Updates for PR

This reverts commit 4966d83d5401720d26ca22a55cf8f92f1657b7e2.
Applied Updated Snapshots

* MM-10193 Updated Modifier for iphone_x_spacing

Updated Modifier for iphone_x_spacing

* MM-10193 Updates for Review

Review changes for Post Textbox and a few states that were unavailable.

* MM-10193 Fix Longpress padding

Fixed longpress padding for Channel Info and Edit Post views.

* MM-10193 Update isLandscape

Updated isLandscape to pull directly from dimensions.
Updated padding for Recent Mentions and Flagged Posts.

* MM-10193 Updates for review longpost

Updated for longpost padding.
Fixed issue with notifications not padding right correctly.

* MM-10193 Update with Cleanup

Reverted Cocoapods back to 1.5.3.
Cleaned up spacing in two files.

* MM-10193 Merge Conflict Updates

Updates to resolve merge conflicts
2019-08-09 11:14:38 -04:00
Jesús Espino
ee93e4fa59
Adding guest accounts feature (#2990)
* MM-15059: Restict the permissions for guests (#2791)

* MM-15057: Adding guest badge to identify guest users (#2774)

* MM-15057: Adding guest badge to identify guest users

* Adding Guest tags in the channel title

* Adding i18n translations

* Adding DM and GM guest warnings

* Fixing check-style

* Adding and fixing tests

* Adding i18n text

* Only showing the subtitle when there is enough space

* Addressing new design changes

* Fixing eslint

* Addressing PR comments

* Moving getChannelStats to the handleSelectChannel action

* Adding the guest info in android landscape channel headers

* simplified the guest warning text generation

* Fixing i18n

* Fixing leaving channel behavior for guests (#2989)

* Fixing leaving channel behavior for guests

* Fixing tests and adding a new one

* fixing typo

* Addressing PR comments

* Addressing PR comments

* Fixing tests
2019-07-22 22:14:39 +02:00
Elias Nahum
f7f56e958b
MM-9494 & MM-13888 Tapping execute actions & interactive keyboard dismissal (#2799)
* MM-9494 & MM-13888 Tapping with the keyboard opened executes the action & iOS iteractive keyboard

* Fix tests

* feedback review

* add new line at the end of file

* feedback review and added todo list

* Track interactive dismiss keyboard and set scrollview bounds natively

* Fix snapshots

* Fastlane default to current branch when no BRANCH_TO_BUILD is set

* Set NODE_OPTIONS in ios build script

* Rebind scrollview when channel gets first set of posts

* Keep scrolling momentum on keyboard close

* Update react-native-keyboard-tracking-view

* Fix ScrollView offset with keyboard-tracking

* Fix offset while dragging the keyboard

* Allow action on channel drawer on tablets

* Fix typo

Co-Authored-By: Saturnino Abril <saturnino.abril@gmail.com>

* Fix indentation
2019-05-20 12:02:00 -04:00
Elias Nahum
f36ee37402
Upgrade to RN 0.59.6 and dependencies (#2777)
* Upgrade to RN 0.59.6 and dependencies

* Remove channel loader unused style

* Update to the latest netInfo that fixes a crash

* Do not set default timezone with moment

* Use RN 0.59.8
2019-05-13 13:33:18 -04:00
Jason Blais
d51d4e4c9c Update help text for at-here, at-channel, at-all (#2790)
* Update help text for at-here, at-channel, at-all

https://community.mattermost.com/core/pl/kqmabdzqb3df7xx5xjsaosozir

* Update at_mention.js
2019-05-13 11:13:39 -04:00
Miguel Alatzar
45e5bae8da
Avoid possible reading of length property on undefined (#2783) 2019-05-10 09:34:23 -07:00
Joram Wilander
df2ecf3409
Add native module to reset TextInput to fix bad cursors in some Android keyboards (#2753) 2019-05-01 09:27:21 -04:00
Christopher Speller
ec9e46fb62
MM-13618 Adding bot tags. (#2669)
* Adding bot tags.

* Snapshot update.

* Moving bot tag to own component.

* Snapshots.

* Adding missing bot tags, fixing bot profile, allowing tap of bot username to open profile.

* Snapshots and tests.
2019-03-26 16:59:45 -07:00
Jesús Espino
44a3a5c6c8 MM-13041: Not show direct channels without display name (#2388) 2018-11-28 10:41:25 -05:00
Jesús Espino
8097764d87 MM-12959: Fix autocomplete archived channels visibility (#2367)
* MM-12959: Fix autocomplete archived channels visibility

* Remove unneeded getDeletedPublicChannels
2018-11-23 12:25:46 -05:00
Chris Duarte
b4d7a23e54 Instantly show autocomplete channels (#2188)
* Instantly show autocomplete channels

* Don't show loading indicator for my channels

* Remove loaders from search
2018-11-19 14:55:43 -03:00
Elias Nahum
0079d7e27a
MM-12952 Avoid iOS autocorrect from overriding autocomplete values (#2335)
* Avoid iOS autocorrect from overriding autocomplete values

* Fix double ~ for channel mentions in Android
2018-11-13 19:46:31 -03:00