Commit graph

952 commits

Author SHA1 Message Date
Elias Nahum
65e62371ab
Revert long post as ScrollView instead of View (#3333) 2019-09-27 01:30:51 +03:00
Miguel Alatzar
459801d10b
[MM-17560] Await dismissAllModals and popToRoot prior to calling showSearchModal (#3298)
* Patch react-native-navigation

* Make navigation actions regular functions

* Fix unhandled promise rejection warning

* Missing semicolons

* Mock navigation actions

* Add unit tests for navigation actions

* Place all patches in patches directory

* Fix channel_info snapshot test
2019-09-25 15:23:45 -07: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
9da5b234ed MM-18542 Fix file attachment scroll on tablets, MM-18732 Slow scroll in landscape & MM-18836 settings sidebar width (#3321) 2019-09-25 10:27:18 -07:00
CJ
67ae09f868 MM-18658 Edit Channel MaxLength (#3317)
Set MaxLength on Edit Channel Name.
Updated ViewTypes MaxLength from 22 to 64 for validation/errors.
2019-09-25 16:53:52 +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
218e104010 Fix paste files with multiple instances of post textbox (#3302) 2019-09-25 17:03:14 +08:00
Miguel Alatzar
8fd0a515a8
Null check on current (#3309)
* Null check on current

* Null check on current
2019-09-24 17:13:27 -07:00
Miguel Alatzar
6131c44dc2 [MM-18325] Properly determine if channel is archived (#3289)
* Properly determine if channel is archived

* Remove check on ownProps.channelIsArchived
2019-09-24 19:39:28 +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
Miguel Alatzar
20fb25df8d
Call scrollToIndex only when ref is set and index is in range (#3285) 2019-09-19 12:39:47 -07:00
Sudheer
0f67b47026 Revert "Call scrollToIndex only when ref is set and index is in range (#3282)" (#3284)
This reverts commit ecbbb3f0e5.
2019-09-19 11:39:52 -07:00
Miguel Alatzar
ecbbb3f0e5 Call scrollToIndex only when ref is set and index is in range (#3282) 2019-09-20 00:00:43 +05:30
Patrick Kang
760b92ceee Adds support for 'radio' type in interactive dialogs (#3212) 2019-09-18 15:35:32 +02:00
Devin Binnie
0db54cd3c2
[MM-18550] Force drawer to open to channel menu when new teams are added (#3266) 2019-09-18 09:22:55 -04:00
Elias Nahum
e9db272a9e Go to channel screen when tapping on a channel link (#3265) 2019-09-17 08:30:06 -07:00
Elias Nahum
0811fd7149
Fix crash accessing property of undefined teammate 2019-09-17 09:00:58 -03:00
Saturnino Abril
4d8fa314d1
MM-14273 Add boolean element support to interactive dialog (#3239)
* add boolean element support to interactive dialog

* determine landscape orientation by Dimension
2019-09-17 09:39:12 +08:00
Ewe Tek Min
0d1fd78263 MM-9599 Paste image from clipboard (#3084)
* Show image paste menu

* Get pasted image

* Add more info for file

* Add custom text input and add extension

* Dismiss contextual menu after paste image

* Group image info together

* Add max file check

* Fix max file size text

* Add PropTypes

* Add support for gif and tiff

* add onchange null check

* Use onPaste event

* Move get image info logic

* Clean up listener when no observer

* Add android upload

* Copy file from google docs

* Clean up file after upload

* Prevent text pasted in textbox if it's content uri

* Rename paste file thread

* Move on paste listener logic

* Remove the redundant data in ios

* Get realpath of item

* Clean up

* Only download for image

* Rename to custom text input

* Update RNPasteableEditTextOnPasteListener.java

* Handle for download image failed

* Fix eslint

* Fix test

* Allow multiple images to be pasted

* Remove additional null check

* Add managed control for Android

* Disable only copy, cut and paste

* Accept image in Android edit text

* Add comment for custom text input

* Do not upload when more than max file

* Stop uplaod when exceed file size

* Fix crash when clip data is null

* Return error to JS

* Move download file logic

* Remove console

* Add some tests

* Add test for handleUploadImages

* Add test for file_upload_item

* Use ImageCacheManager to cache remote images

* Fix crashes from one note

* Remove commented code

* Update test
2019-09-16 20:10:14 -03:00
Elias Nahum
da9be433e3
Fix snapshots 2019-09-16 20:06:10 -03:00
Elias Nahum
0ef2156b3f MM-17953 Do not show deactivated users in autocomplete (#3251)
* MM-17953 Do not show deactivated users in autocomplete

* feedback review
2019-09-16 16:02:52 -04:00
Theo Gkourasas
30f91a3814 MM-15219 Added support for introduction text in interactive dialogs (#3222)
* MM-15219 Added support for optional introduction text in interactive dialogs

* Fixed margins in introduction text for interactive dialogs

* Created DialogIntroductionText component to render the introduction text.  Changed text color

* Changed DialogIntroductionText component to only render if a value is supplied
2019-09-16 09:22:59 -07:00
Elias Nahum
19e6b2a00e
[MM-18362] Sidebar improvements (#3223)
* sidebar lists displays past bottom safe area insets

* Sidebar animation speed

* Sidebar improvements

* Add status icons and avatars to mattermost font

* Bot icon the same size as other channel icons

* improvements to the channel badge

* Badge color and border

* More precision when showing more unread above

* Improve GM icon

* Fix badge on team sidebar

* Align channel sidebar badges

* alignments

* Fix tests

* Remove unnecessary isLandscape in main sidebar connector
2019-09-16 13:17:48 -03:00
Elias Nahum
d28aaf21a8 MM-18241 Fix emoji picker selection and added keyboard tracking on iOS (#3244)
* MM-18241 Fix emoji picker selection and added keyboard tracking on iOS

* Fix flatlist spacing on iOS when searching

* Fix snapshot
2019-09-15 20:31:54 -07:00
Harrison Healey
6fc8569266 MM-18466 Change recent date separators to yesterday/today (#3245)
* MM-18466 Change recent date separators to yesterday/today

* Add i18n strings
2019-09-14 07:02:51 -03:00
Miguel Alatzar
b795a0bba4 [MM-18361] Style text inputs and post options with theme (#3213)
* Style text inputs with theme

* Add snapshot test

* Use theme for post options background and text colors

* Use theme for post options icon color

* Use theme for reaction list

* Use theme for slide up indicator

* Fix post options localization

* PM Feedback review

* Slideup PM changes and channel edit

* fix tests

* Fix i18n
2019-09-13 10:24:36 -03:00
Miguel de la Cruz
72d1895bd3 [MM-18365] When searching for profiles, allow inactive (#3252) 2019-09-12 16:27:40 +02:00
Nathan Friend
9ccde970fa GH-11994: Add support for footer and footer_icon in attachments (#3228)
This commit adds support for the footer and footer_icon fields that are
rendered at the bottom of message attachments.
2019-09-11 20:58:55 -04:00
Ewe Tek Min
f6c9c950c5 MM-12879 Fix iOS photo/camera permission denied prompt (#2904)
* Update Github issues link

* Update GH issue to permalink

* Add missing comma

* Fix ios not prompting alert after denied photo or camera permission

* Rename permission var

* Update text

* Change to correct text

* Update text for attachement button

* Update text for image_preview

* Fix test

* Integrate react-native-android-open-settings for storage permission denied

* Move react-native-android-open-settings

* Change all default permission denied message

* Revert "Merge remote-tracking branch 'upstream/master'"

This reverts commit 65187f8f98de4943103bdab4b39bd7e1ebd5a220, reversing
changes made to daca425676503a57936a5539b5b5fa68a6c5427e.

* Revert "Revert "Merge remote-tracking branch 'upstream/master'""

This reverts commit c82fa628d5addc1262353539c32b76c6a1130e83.

* Add NSPhotoLibraryAddUsageDescription description

* Fix bad import

* Lazy load react-native-android-open-settings

* Fix indent
2019-09-11 01:18:53 -03:00
Devin Binnie
8f9255aa12
[MM-18174] Replicated missing user functionality for system messages from webapp in RN (#3219) 2019-09-10 13:04:54 -04:00
Elias Nahum
49991a57d4 MM-18223 Fix channel actions on combined sidebar (#3221) 2019-09-09 21:12:23 +08:00
Elias Nahum
223bd64a43
[MM-18349] Post menu delay animation speed and haptic feedback (#3214)
* Animate backdrop opacity in slide up panel

* Set delayLongPress to 75ms for post

* Add haptic feedback on slide up of post options

* Ease in slide up animation

* Add haptic feedback to android

* reduce long press delay for post options menu

* helper function for haptic feedback

* Add haptic feedback when opening post options menu

* Patch haptic feedback RN module on Android

* Fix tests

* Move hapticFeedback call to SlideUpPanel

* Decrease long press time for reaction
2019-09-07 07:45:07 +09:00
Asaad Mahmood
d8adb25640 MM-17966 - Updating background for archive wrapper (#3206) 2019-09-05 22:43:52 +09:00
Devin Binnie
e2031de0ab
[MM-18172] Added state for message length such that alerts for long length aren't fired too often (#3218)
* [MM-18172] Added state for message length such that alerts for long length aren't fired too often

* Added a test

* Naming change
2019-09-05 09:12:21 -04:00
Elias Nahum
67a28d0af3
MM-18179 Clear cache and cookies for SSO login (#3220)
* MM-18179 Clear cache and cookies for SSO login

* Update app/components/failed_network_action/index.js

Co-Authored-By: Miguel Alatzar <migbot@users.noreply.github.com>
2019-09-05 19:23:23 +09:00
Miguel Alatzar
02ecaf8de9
Rebuild emojis when emojis change and use props.deviceWidth (#3208) 2019-09-01 09:03:28 +09:00
Miguel Alatzar
6ab325ca9e Increase cancel button width (#3203) 2019-08-30 05:24:50 +05:30
Miguel Alatzar
6bfe6f917c Set rebuilt emojis only after search bar animation completes (#3191) 2019-08-26 10:17:05 -04:00
Miguel Alatzar
6c46368083 Re-render MainSidebar on theme change (#3190) 2019-08-26 10:16:44 -04:00
Michael Kochell
7646a8821c [MM-17873] Update attachment image when image url is updated (#3170)
* update attachment image when image url changes

* update image dimensions from metadata

* use componentDidUpdate

* add tests for AttachmentImage

* add test for when imageUrl is not present
2019-08-26 10:16:18 -04:00
Matheus Cardoso
73518da91e Make keyboard dark on dark themes (iOS only) (#3102)
* Support keyboardAppearance theme parameter

* Change approach of keyboardAppearance to auto-detect

* Fix style

* Update snapshots

* Add unit test for getKeyboardAppearanceFromTheme

* Update snapshot

* Fix failing test
2019-08-23 13:18:05 -04:00
Elias Nahum
a6a299352e
MM-18024 MM-18025 Fix race condition when push notification opens the app and credentials are not set (#3168) 2019-08-23 09:37:48 -04:00
Asaad Mahmood
4b6c83f5b9 MM-17700 - Updating bot tag css (#3127)
* MM-17700 - Updating bot tag css

* Updating spacing for android
2019-08-19 17:13:12 -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
0856d4b517
Migrate to moment to fix timestamps based on timezone or local time (#3126) 2019-08-15 12:32:16 -04:00
Eric Shyong
958df2e65f [MM-14018] Ignore leading/trailing colon in emoji picker search (#2974)
* [MM-14018] Ignore leading/trailing colon in emoji picker search

* Respond to feedback

* fix failing test on ESlint
2019-08-15 16:43:23 +08:00
Harrison Healey
0faeb535b9 MM-17425/MM-17683 Disable Send button when sending post (#3099)
* MM-17425/MM-17683 Disable Send button when sending post

* Update snapshot and add tests
2019-08-14 08:29:55 -07:00
Miguel Alatzar
6cf6e51457 [MM-17709] Avoid async getSource (#3115)
* Await getSource

* Use server url from EphemeralStore

* Set currentServerUrl in getAppCredentials too
2019-08-14 16:07:12 +05:30
Elias Nahum
f0a885865f
MM-17692 execute callback after closing post options (#3107)
* MM-17692 execute callback after closing post options

* Fix unit tests
2019-08-13 10:19:11 -04:00
Saturnino Abril
ca61faafd5 MM-15218 Open as alert dialog when interactive message is without element (#3088)
* open as alert dialog when interactive message is without element

* add missing translations
2019-08-13 10:16:14 -04:00