Commit graph

908 commits

Author SHA1 Message Date
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
Miguel Alatzar
d8f9dcc233 [MM-17637] Add flex 1 to wrapper view (#3087)
* Add flex 1

* Add snapshot test

* Fix placeholder text color
2019-08-12 08:22:21 -04:00
Elias Nahum
f263eac658
MM-17612 Fix fetch periodic status updates when re-connecting (#3089) 2019-08-09 18:47:38 -04:00
Asaad Mahmood
3c950c514c MM-17484 - Updating loading rows (#3076)
* MM-17484 - Updating loading rows

* Updating test

* Updating mobile loader css

* Updating test

* Updating changes

* Updating tests
2019-08-09 13:33:38 -04: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
Miguel Alatzar
757e58f83b
Increase ReplyIcon dimensions (#3086) 2019-08-09 06:05:11 -07:00
Hossein Ahmadian-Yazdi
55bd6a2f7e [MM-13849] Display confirmation box for [at]all and [at]channel (#3028)
* [MM-13849] Display confirmation box for @all and @channel

* [MM-13849] Fetch Channel stats when user changes channel

* [MM-13849] Address PR comments

* [MM-13849] Addressed PR comments

* [MM-13849] Made getChannelStats into it's own statement
2019-08-08 16:21:52 -04:00
Elias Nahum
fddb0cf2fb
MM-17562 scroll to new message line indicator on componentDidUpdate (#3074)
* MM-17562 scroll to new message line indicator on componentDidUpdate

* feedback review

* Cancel animation frame requests
2019-08-08 15:50:37 -04:00
Elias Nahum
e87858d7af Various fixes (#3078)
* MM-17588 Remove navigation component from stack

* MM-175986 Fix Clock Display Settings on iOS

* Fix markdown and team icon currentServerUrl

* Fix closing permalink logs out the user

* Fix file attachment document ref

* Fix applyTheme when changing a theme in the app

* Feedback review

* remove / when fetching the image on the markdown table on relative paths
2019-08-08 22:28:07 +08:00
Deepak Sah
8167c2ddea [MM-14593] Add password type for Interactive Dialogs (#2998)
* Added prop secureTextEntry for password type

* Added test cases for DialogElement

* Fixed issues
2019-08-02 14:14:49 -04:00
Elias Nahum
d230bdac1e
MM-17424 Setting to enable/disable fixed sidebar (#3060) 2019-08-02 13:50:31 -04:00
Asaad Mahmood
06f3511222 MM-13083 - Removing refresh button from some pages (#3010)
* MM-13083 - Removing refresh button from some pages

* Updating test

* Removing unused component

* Updating minor changes

* Updating failed actions import

* Updating post list error screen

* Updating connection issue error message

* Updating network connection messages

* Updating terms of service page

* Updating test

* Updating animations and FailedNetwork component

* Reverting some changes

* Updating channel post list

* Updating requestsed changes

* Updating code changes

* Removing error description
2019-07-29 14:26:24 -04:00
Miguel Alatzar
78bdf0e4e2
Check initialIndex in callback (#3025) 2019-07-24 09:51:36 -07:00
Miguel Alatzar
ebe8d45711
[MM-16816] Parse source URI (#3026)
* Parse source URI

* Revert "Parse source URI"

This reverts commit 1cf421c9b9897e46881685aabebb793ad6ff4c07.

* Pass imageUri instead of defaultSource to ProgressiveImage

* Parse source URI in ImageCacheManager
2019-07-24 07:59:06 -07:00
Miguel Alatzar
83c9856897
Call scrollToIndex only if flatListRef.current is not null (#3022) 2019-07-23 11:21:38 -07: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
Miguel Alatzar
8e48058fff
[MM-16910] Set footerColor the same as navBarBackgroundColor (#3002)
* Set footerColor the same as navBarBackgroundColor

* Oops, forgot __snapshots__
2019-07-19 17:29:17 -07:00
Elias Nahum
98da0aa607
MM-16815 Remove the failed posts banner on WS reconnect (#2983) 2019-07-18 11:36:37 -04:00
krjn
5abfb66b78 [MM-16389] Enable emojis for profile icons from webhooks (#2961)
* [MM-16389] Enable emojis for profile icons from webhooks

Removes borders from profile icons when it is from a custom URL.

* feat: reapply border for all profile pictures and shrink emojis

* feat: remove border from emoji profile pictures

* feat: decide if post has emoji icon through props instead of url

* refactor: better checking of potentially undefined property

Co-Authored-By: Elias Nahum <nahumhbl@gmail.com>
2019-07-18 10:23:41 -04:00
Miguel Alatzar
55964d2fda
Add placeholderTextColor when using placeholders (#2976) 2019-07-17 12:56:25 -07:00
Elias Nahum
cdd7000361
MM-16398 Fix Team/Channel sidebar dots overlap last item (#2975)
* MM-16398 Fix Team/Channel sidebar dots overlap last item

* Feedback review and Tablet support

* Only center dots by width on iPhone X series devices
2019-07-17 11:30:12 -04:00
Miguel Alatzar
085a3ecf6c [MM-17016] Ensure Flatlist is mounted prior to calling scrollToIndex (#2977)
* Ensure Flatlist is mounted prior to calling scrollToIndex

* Address review comment
2019-07-16 21:07:59 +08:00
Miguel Alatzar
5838d5163f Wrap setting show true in requestAnimationFrame (#2964) 2019-07-09 10:51:11 -04:00
Miguel Alatzar
5eee2b7652
[MM-16139] [MM-16140] [MM-16141] Update the remaining screens/components (#2920)
* Update screens

* Update login tests

* Remove done

* Fix failing tests

* Update screens and components

* Check styles fix

* Update tests

* Prevent setState call after component unmounts

* Add empty setButtons func to dummy navigator

* Remove platform check

* Remove Platform import

* Update react-native-navigation version

* Add separate showModalOverCurrentContext function

* check-style fixes

* Remove overriding of AppDelegate's window

* Fix modal over current context animation

* Add showSearchModal navigation action

* Check-style fix

* Address review comments

* Update SettingsSidebar and children

* Update EditProfile screen

* Update SettingsSidebar

* Keep track of latest componentId to appear

* Track componentId in state to use in navigation actions

* Update FlaggedPosts and children

* Update RecentMentions

* Update Settings

* Store componentIds in ephemeral store

* Update AttachmentButton

* Remove unnecessary dismissModal

* Fix typo

* Upate NotificationSettings

* Update NotificationSettingsAutoResponder

* Update NotificationSettingsMentions

* Update NotificationSettingsMobile

* Update CreateChannel and children

* Update MoreChannels

* Update ChannelPeek and children

* Update ChannelNavBar and children

* Update ChannelPostList and children

* Update ChannelInfo and children

* Update ChannelAddMembers

* Update ChannelMembers

* Update EditChannel

* Fix setting of top bar buttons

* Update Channel screen and children

* Update PinnedPosts

* Update LongPost

* Update PostOptions

* Update PostTextboxBase

* Update EditPost

* Check-styles fix

* Update DisplaySettings

* Update Timezone

* Update SelectTimezone

* Update IntlWrapper and Notification

* Update InteractiveDialog and children

* Update ExpandedAnnouncementBanner

* Update ClientUpgradeListener

* Update MoreDirectMessages

* Update SelectorScreen

* Update UserProfile

* Update Thread

* Update About

* Update ImagePreview

* Update TextPreview

* Update AddReaction

* Update ReactionList and children

* Update Code

* Update TermsOfService

* Update Permalink

* Update Permalink

* Update ErrorTeamsList

* Update Search

* Remove navigator prop

* Fix setButtons calls

* Remove navigationComponentId

* Fix test

* Handle in-app notifs in global event handler

* Fix in-app notification handling

* Fix typo

* Fix tests

* Auto dismiss in-app notif after 5 seconds

* Fix typo

* Update overlay dismissal

* Animate in-app notif dismissal and allow gesture dismissal
2019-07-08 10:03:31 -07:00
Miguel Alatzar
1b9b1e3f39 Merge branch 'master' into rnn-v2 2019-07-05 15:56:56 -07:00
Miguel Alatzar
51aac1e6e7 Merge branch 'master' into rnn-v2 2019-07-02 18:15:19 -07:00
Maxim Zaks
bf3f0be37e Don't show preview if remove_link_preview is set to true (#2939)
* Don't show preview if remove_link_preview is set to true

* remove white spaces
2019-07-03 01:44:29 +05:30
Elias Nahum
9f88923656
Place the new message indicator at the top of the screen (#2943)
* Place the new message indicator at the top of the screen

* Add unit tests for channel postVisibility reducer
2019-07-02 12:28:13 -04:00
Michael Kochell
1588f46ae4 Pass cookie for post actions (#2945) 2019-07-02 08:18:34 -04:00
Miguel Alatzar
c278614ca1 [MM-16137] Update post related screens (#2916)
* Update screens

* Update login tests

* Remove done

* Fix failing tests

* Update screens and components

* Check styles fix

* Update tests

* Prevent setState call after component unmounts

* Add empty setButtons func to dummy navigator

* Remove platform check

* Remove Platform import

* Update react-native-navigation version

* Add separate showModalOverCurrentContext function

* check-style fixes

* Remove overriding of AppDelegate's window

* Fix modal over current context animation

* Add showSearchModal navigation action

* Check-style fix

* Address review comments

* Update SettingsSidebar and children

* Update EditProfile screen

* Update SettingsSidebar

* Keep track of latest componentId to appear

* Track componentId in state to use in navigation actions

* Update FlaggedPosts and children

* Update RecentMentions

* Update Settings

* Store componentIds in ephemeral store

* Update AttachmentButton

* Remove unnecessary dismissModal

* Fix typo

* Upate NotificationSettings

* Update NotificationSettingsAutoResponder

* Update NotificationSettingsMentions

* Update NotificationSettingsMobile

* Update CreateChannel and children

* Update MoreChannels

* Update ChannelPeek and children

* Update ChannelNavBar and children

* Update ChannelPostList and children

* Update ChannelInfo and children

* Update ChannelAddMembers

* Update ChannelMembers

* Update EditChannel

* Fix setting of top bar buttons

* Update Channel screen and children

* Update PinnedPosts

* Update LongPost

* Update PostOptions

* Update PostTextboxBase

* Update EditPost

* Check-styles fix

* Remove navigationComponentId
2019-06-26 18:10:41 -04:00
Miguel Alatzar
b65ce5d283 [MM-16136] Update channel related screens (#2915)
* Update screens

* Update login tests

* Remove done

* Fix failing tests

* Update screens and components

* Check styles fix

* Update tests

* Prevent setState call after component unmounts

* Add empty setButtons func to dummy navigator

* Remove platform check

* Remove Platform import

* Update react-native-navigation version

* Add separate showModalOverCurrentContext function

* check-style fixes

* Remove overriding of AppDelegate's window

* Fix modal over current context animation

* Add showSearchModal navigation action

* Check-style fix

* Address review comments

* Update SettingsSidebar and children

* Update EditProfile screen

* Update SettingsSidebar

* Keep track of latest componentId to appear

* Track componentId in state to use in navigation actions

* Update FlaggedPosts and children

* Update RecentMentions

* Update Settings

* Store componentIds in ephemeral store

* Update AttachmentButton

* Remove unnecessary dismissModal

* Fix typo

* Upate NotificationSettings

* Update NotificationSettingsAutoResponder

* Update NotificationSettingsMentions

* Update NotificationSettingsMobile

* Update CreateChannel and children

* Update MoreChannels

* Update ChannelPeek and children

* Update ChannelNavBar and children

* Update ChannelPostList and children

* Update ChannelInfo and children

* Update ChannelAddMembers

* Update ChannelMembers

* Update EditChannel

* Fix setting of top bar buttons

* Update Channel screen and children

* Fix typo

* Use goToScreen for Android too

* Remove navigationComponentId
2019-06-26 16:46:05 -04:00
Elias Nahum
bef593c3cf
MM-16467 Fix iOS layout when playing a youtube video in landscape (#2926) 2019-06-26 08:33:04 -04:00
Miguel Alatzar
fdb6cc6b2a [MM-16456] Ensure Flatlist is mounted prior to calling scrollToOffset (#2925)
* Ensure Flatlist is mounted prior to calling scrollToOffset

* Make linter happy
2019-06-26 17:01:44 +08:00
Miguel Alatzar
150253d392
[MM-16012] [MM-16084] Update screens related to settings sidebar + update SearchResultPost screen and its children (#2913)
* Update screens

* Update login tests

* Remove done

* Fix failing tests

* Update screens and components

* Check styles fix

* Update tests

* Prevent setState call after component unmounts

* Add empty setButtons func to dummy navigator

* Remove platform check

* Remove Platform import

* Update react-native-navigation version

* Add separate showModalOverCurrentContext function

* check-style fixes

* Remove overriding of AppDelegate's window

* Fix modal over current context animation

* Add showSearchModal navigation action

* Check-style fix

* Address review comments

* Update SettingsSidebar and children

* Update EditProfile screen

* Update SettingsSidebar

* Keep track of latest componentId to appear

* Track componentId in state to use in navigation actions

* Update FlaggedPosts and children

* Update RecentMentions

* Update Settings

* Store componentIds in ephemeral store

* Update AttachmentButton

* Remove unnecessary dismissModal

* Fix typo

* Check-style fix

* Address review comments
2019-06-24 12:52:08 -07:00
Jesse Hallam
0e84b91257 MM-16442: count actual reactions before falling back to has_reactions (#2910)
* MM-16442: leverage post hasReactions utils function

This handles backwards compatibility with servers that do not have post
metadata, allowing the client to detect the presence of reactions that
in turn might need to be loaded when the component is mounted.

* temporary mattermost-redux commit for testing

* revert usage of hasReactions, and count directly

We still fallback to has_reactions if set, in case we're connected to a server without post metadata.

* revert mattermost-redux changes
2019-06-24 15:36:24 -04:00
Miguel Alatzar
913f05e131
[MM-16011] Update screens related to main sidebar (#2907)
* Update screens

* Update login tests

* Remove done

* Fix failing tests

* Update screens and components

* Check styles fix

* Update tests

* Prevent setState call after component unmounts

* Add empty setButtons func to dummy navigator

* Remove platform check

* Remove Platform import

* Update react-native-navigation version

* Add separate showModalOverCurrentContext function

* check-style fixes

* Remove overriding of AppDelegate's window

* Fix modal over current context animation

* Add showSearchModal navigation action

* Check-style fix

* Address review comments
2019-06-24 10:58:15 -07:00
Elias Nahum
e6fdef3451 MM-16397 save draft when app state changes (#2899)
* MM-16397 save draft when app state changes

* Unit tests
2019-06-22 11:21:57 -07:00
Chris Duarte
4d9780da56 Ios accessibility fixes (#2842)
* UCHAT-4371 // MM-15771 - iOS - Larger Fonts Cut Off Text in menu and settings screens

revert padding right

* Update snapshot
2019-06-21 16:10:16 -04:00
Elias Nahum
3f925df9d9 MM-16392 Split view support & hide sidebar on tablets (#2898) 2019-06-21 14:10:30 -04:00
Miguel Alatzar
0f948f650d Merge branch 'master' into rnn-v2 2019-06-18 09:58:35 -07:00
Elias Nahum
6546dfdfd2
Set post list data and timestamp based on the user timezone if available (#2888) 2019-06-17 15:24:28 -04:00
Eli Yukelzon
056d5a91b7 MM-15486 - Archived channels appear incorrectly on mobile (#2882)
* properly separate archived channels from 'other'

* make sure fetch is performed to display full list

* reverted unneeded change

* corrected display behaviour

* code cleanup

* redux commit reference updated
2019-06-17 10:22:36 -04:00
Miguel Alatzar
7d67f1214e
[MM-16008] Update setNavigatorStyles and replace setOnNavigatorEvent (#2877)
* Update setNavigatorStyles

* Replace navigator.setOnNavigatorEvent and callbacks

* Update unit tests

* Save user notify props on componentWillUnmount

* Add TODOs about removing componentDidAppear/setNavigatorStyles

* check-styles fix

* Fix eslint errors
2019-06-14 08:14:26 -07:00
Sudheer
d3b2759c36 MM-16228 Add compatibility for removal of ExperimentalEnablePostMetadata flag from config (#2883) 2019-06-13 16:29:35 -04:00
Elias Nahum
29240b9c6f
MM-16061 Keep unread channels in place on Tablets (#2865) 2019-06-06 15:15:40 -04:00