Commit Graph

110 Commits

Author SHA1 Message Date
Miguel Alatzar
04210b8a14 [MM-19968] Ensure SELECT_CHANNEL_WITH_MEMBER is dispatched when app opened from a push notification (#3533)
* Dispatch SELECT_CHANNEL_WITH_MEMBER

* Call handleSelectChannel with true when from any push notification

* Always dispatch SELECT_CHANNEL_WITH_MEMBER with passed channelId

* Add missing comma

* Update unit tests

* Fix makrChannelViewedAndRead call
2019-11-12 17:45:11 -05:00
Miguel Alatzar
1efb01deda [MM-16593] Upgrade to RN 0.61.2 (#3455)
* [MM-16593] [MM-17175] [MM-17164] [MM-17189] [MM-17181] Android - Upgrade to RN 0.60 (#3145)

* Upgrade to react-native 0.60

* Use @sentry/react-native

* Manually link @sentry/react-native

* Address review comments

* Jetify after install

* Call jetify from node_modules

* [MM-17785] iOS - Upgrade to RN 0.60 (#3153)

* Upgrade to react-native 0.60

* Use @sentry/react-native

* Manually link @sentry/react-native

* Address review comments

* Jetify after install

* Call jetify from node_modules

* Get app building for iOS

* Revert react-native-image-picker upgrade

* Minor version upgrade of react-native-image-picker

* [MM-17142] Convert all string refs to callbacks (#3217)

* Replace string refs

* Fix tests

* Don't use inline functions

* Fix mattermost-redux reversion from master merge

* [MM-18336] Upload Sentry debug symbols only when SENTRY_ENABLED is true (#3227)

* Upgrade @sentry/react-native

* Run Sentry gradle tasks only when enabled

* Upgrade @sentry/react-native and remove extra Sentry build phase

* [MM-17144] Use Hermes (#3226)

* Replace string refs

* Fix tests

* Don't use inline functions

* Fix mattermost-redux reversion from master merge

* Use Hermes

* bundleCommand ram-bundle no longer needed

* Require harmony-reflect only for Android

* Fix failing test

* Path react-native's splitLayoutProps (#3337)

* [MM-18867] [MM-17186] [MM-18866] [MM-19447] [MM-18967] Upgrade to RN 0.61.2 (#3423)

* Upgrade to RN 0.61.2

* Update rn-fetch-blob commit hash

* Update react-native-keyboard-tracking-view commit hash

* Use react-native-youtube with AVPlayer fix

* Fix jest mocks

* Use updated document picker API

* Remove unnecessary linking

* Revert "MM-17759 Add code highlighting (#3072)"

This reverts commit 26b999e885.

* Fix share extension

* Revert "Revert "MM-17759 Add code highlighting (#3072)""

This reverts commit 52aca776b1.

* Address PR reviews

* Rename patch to match version

* Update react-native-youtube patch

* Update dependencies

* Fix RNDocViewer reference

* Update tests and revert to redux-persist 4.10.2

* Revert "Revert "Revert "MM-17759 Add code highlighting (#3072)"""

This reverts commit 5ef383be26.

* Android fixes after dep upgrades

* Use fresco 2.0.0

* Use mattermost forks

* Use React-Core in Mattermost.scheme instead of react

* Remove packager (#3452)

* Remove Pods from source control

* Fix unit tests

* Add new line before entering the keystore in gradle.properties

* set ios as working directory for cocoapods

* Cache cocoapods on circleCI builds

* set ios as working dir

* fix cocoapods cache key

* Unify fastlane and npm dependencies command

* Use package-lock.json checksum for npm cache

* Fix package.json and use the checksum as the cache key

* Fix package.json and use the checksum as the cache key

* changes to circleci.yaml fastlane and removing pods from git

* Fix Mattermost.xcodeproj

* Update coocoapods to 1.7.5 and fix xcode header search paths

* Update package-lock.json

* Remove unused tooltip component

* Fix incorrect ref

* Disable Hermes (#3460)

* Revert "Remove packager (#3452)"

This reverts commit b2a79e184b.

* Disable Hermes :'(

* Update preloaded modules

* Fix packages moduleNames and modulePaths, update snapshots and update mm-redux (ts version)

* remove document picker from modulePaths

* Fix package-lock.json

* Add eslint disable rules
2019-10-28 15:04:24 -07: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
Miguel Alatzar
faf97f9945 Ensure onAppStateChange runs only after GlobalEventHandler is configured (#3268) 2019-09-18 09:59:52 -07: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 65187f8f98, reversing
changes made to daca425676.

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

This reverts commit c82fa628d5.

* Add NSPhotoLibraryAddUsageDescription description

* Fix bad import

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

* Fix indent
2019-09-11 01:18:53 -03: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
Elias Nahum
1d37c81163 Fix tests (#3114) 2019-08-13 09:51:51 -07: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
Elias Nahum
76df42bbd1 MM-16752 Fix unhandled promise rejection TypeError state.websocket.lastConnectAt (#3039) 2019-08-02 13:04:50 -07:00
Miguel Alatzar
9a894641fc [MM-14926] Include in-app notifications in iOS badge number (#3001)
* Include in-app notifications in iOS badge number

* Make foreground notifications key a const
2019-07-24 07:58:15 -07:00
Harrison Healey
fcd9e401f5 MM-15582 Don't show forgot password link without email/username login (#2811) 2019-05-22 11:55:27 -04:00
Elias Nahum
08df256c1d MM-14921 Fix iPad layout including safeAreaInsets (#2748)
* MM-14780 and MM-14921 Fix iPad layout including safeAreaInsets

* Fix unit tests
2019-05-03 17:42:32 -04:00
Miguel Alatzar
19c493ff6e [MM-15401] Fix setting of extension when caching files (#2762)
* Get extension from Content-Disposition first

* User ImageCacheManager.cache over getCacheFile

* Add unit tests for ImageCacheManager.getCacheFile

* Add unit tests for ImageCacheManager.cache

* Use exports and require to be able to mock isDownloading

* Chain mockReturnValueOnce calls

* Fix getExtensionFromContentDisposition and its unit tests
2019-05-03 09:24:40 -07:00
Elias Nahum
88f5848850 Dependencies update (#2576)
* Dependencies update

* Fix WebView

* Update to RN 0.58.5 and include the WebSocket fix

* Update react-native-video

* Fix RNFetchBlob
2019-02-20 17:17:04 -03:00
Elias Nahum
2184696e65 post menu and file attachments (#2414)
* post menu and file attachments

* Fix post list selector test

* Use new Gesture handler to avoid gesture conflicts in post menu and reaction list

* Allow reaction list to scroll the header on Android

* Feedback review

* Add some comments

* Fix eslint
2018-12-05 14:59:41 -03:00
Elias Nahum
9a5122c19c Slide up panel for reaction list (#2285)
* Slide up panel for reaction list

* Feedback review

* UI Feedback review

* Feedback review

* Improve slide speed and fix end position

* Scroll to top when changing reaction view

* dismiss modal without animation so backdrop does not scroll down

* Smooth animation to show/hide

* Change animation speed
2018-11-02 13:21:43 -03:00
Sudheer
1b54e1ebe3 Fix for LHS populating you next to current user (#2263)
* Fix for LHS populating you next to current user

* Add test cases
 * Refactor to use avaiable props conditions in component
   instead of passing flags from connector
2018-10-15 21:00:11 +05:30
Saturnino Abril
dd506d4c9f fix issue that blocks adding test for thread screen (#2221) 2018-10-05 14:46:21 +08:00
Sudheer
5aac68e785 Change rn-fetch-blob to mock globally in jest (#2124) 2018-09-14 12:14:37 -03:00
Saturnino Abril
059db1a788 fix warnings in running jest test (#2087) 2018-09-07 23:05:35 +08:00
Jesse Hallam
8372e95d4a add eslint-plugin-header, and --fix all (#1726) 2018-06-19 19:14:50 -04:00
Saturnino Abril
1e4ee0716f [MM-10594] Add feature to combine join/add/leave/remove to channel/team system messages (#1682)
* add feature to combine system messages

Signed-off-by: Saturnino Abril <saturnino.abril@gmail.com>

* updated copyright to 2015

Signed-off-by: Saturnino Abril <saturnino.abril@gmail.com>

* updated per comments

Signed-off-by: Saturnino Abril <saturnino.abril@gmail.com>
2018-05-24 16:34:33 -04:00
Saturnino Abril
8a152ac1e7 convert test runner from mocha to jest (#1637) 2018-04-30 10:55:01 -04:00
Elias Nahum
80dd9366a1 Update Dependencies (#1641)
* Update dependencies including react-native

* Update react-native-circle-progress dependency

* Fix prop warnings and possible crashes
2018-04-27 17:49:09 -04:00
Saturnino Abril
8531212060 [MM-9516] Add feature to add user to channel after at-mention (#1521)
* add feature to add user to channel after at-mention

* update per comment and update mattermost-redux

* move sendAddToChannelEphemeralPost to actions folder

* rebase and fix merge conflicts, do clean up a bit
2018-03-26 13:20:13 -04:00
Jesse Hallam
58b72302d6 update eslint's comma-dangle rule to always-multiline (#1457)
* update eslint's `comma-dangle` rule to `always-multiline`

* add check and fix scripts to package.json

* Invoke `yarn fix` to adopt the updated eslint rules. No other changes are included.
2018-02-23 09:06:02 -05:00
Harrison Healey
ede4d22f75 ICU-624 Added markdown tables (#1434)
* ICU-624 Added initial table rendering support

* ICU-624 Added full table view

* Added proper pluralization to +X more lines in code blocks

* ICU-624 Added support for images in tables

* Stopped using injectIntl for tables

* ICU-624 Updated commonmark-react-renderer

* ICU-624 Hid scroll indicator in collapsed table view

* Addressed feedback
2018-02-16 19:31:14 -03:00
Harrison Healey
d187399fce ICU-653 Stopped filtering out join/leave messages about the current user (#1419)
* ICU-653 Stopped filtering out join/leave messages about the current user

* Switched redux back to master
2018-02-07 09:25:05 -05:00
enahum
70c4e3e005 iOS Share Extension (#1308)
* objective-C share extension

* MattermostBucket module to share data between the main app and the extension

* middleware that shares the data between the main app and the extension

* Fix setState when safe area in unmounted

* Share extension for iOS

* Fastlane changes to include iOS share extension

* Fix unit test

* Feedback review

* define proptypes for icons
2018-01-15 16:11:42 -03:00
Chris Duarte
2e951cbfca Upgrade to RN 0.50.4 (#1303)
* Update to RN 0.50.4

* Fix intl context in post textbox
2017-12-22 19:39:51 -03:00
Harrison Healey
c71b116c71 RN-173 Added support for Markdown images (#1202)
* RN-173 Added support for Markdown images

* RN-173 Added proper alt text when image fails to load

* Changed (edited) indicator not add itself as a child of an image

* RN-173 Removed space between an image and the following text

* Made sure MarkdownImage is mounted when setState is called

* Fixed images in links having their location overwritten

* Made images work in links

* Fixed uppercase links not working on Android

* Added vertical margin around images

* RN-173 Added styling for markdown image error text

* RN-173 Added error when image exceeds max dimensions on Android
2017-11-28 11:00:28 -03:00
enahum
bc1554e1bd Add Document and Video previews (#1170)
* Video file previewer

* Document preview support

* Fix tests

* Feedback review

* feedback review 2

* feedback review 3

* Fix video_controls copyright

* Fix mime undefined
2017-11-20 18:28:20 -03:00
enahum
c9fd1ac97d Scroll to search result in preview (#1129)
* Scroll to search result in preview

* Fix uni test

* Feedback review

* Remove listeners for mattermostManaged

* Remove specific event listeners for mattermostManaged
2017-11-13 11:55:26 -05:00
Chris Duarte
e49f89d727 Add better network detection (#1054)
* Add better network detection

* Mock NetInfo for store
2017-10-24 19:43:22 -03:00
enahum
c8a0753289 Fix new message indicator (#1053)
* Fix new message indicator

* Revert "Fix new message indicator"

This reverts commit 3732d2e531.

* Fixed new messages indicator and added unit tests for it
2017-10-24 19:42:50 -03:00
Harrison Healey
0e4f9d5825 Changed to pass IDs to PostList instead of posts (#1036)
* Moved PostList to take a list of postIds instead of posts

* Removed usage of selectors that return posts from ChannelPostList and Thread

* Fixed search and switched to use getPostIdsAroundPost selector

* Removed use of selectors that returned posts from emoji reactions

* Updated makePreparePostIdsForPostList to be better memoized

* Fixed filter of join/leave messages

* Added unit tests for makePrepaprePostIdsForPostList

* Check if post edit/delete should be enabled more often

* Updated mattermost-redux version in yarn.lock
2017-10-20 18:58:44 -03:00
enahum
4995a76f2c Add Landscape support for both platforms (#909)
* Landscape support

* Fix image rotation on Android

* Fix landscape mode for login and login options

* Fix previewer will receive props

* Move device dimensions and others to redux

* Fix unit tests

* Include orientation and tablet in the store
2017-09-20 12:54:24 -07:00
enahum
0628cbc693 Upgrade to RN 0.48.3 (#911)
* Upgrade to RN 0.48.1

* Update deps to be exact

* Fix tests

* Remove unneeded code from setup and add socketcluster dep

* Fix drawer pan issue

* Fix bridge issues on iOS

* Upgrade to RN 0.48.3

* Search to use RN SectionList
2017-09-18 12:01:47 -04:00
Harrison Healey
3ac7b48adc RN-289 Sentry integration (#873)
* Added JS code for Sentry

* Removed leftover initializeSentry call

* Added SentryOptions config setting

* Added native components for react-native-exception-handler

* Removed default props from ErrorText

* Moved where Sentry is initialized

* Added ios/sentry.properties to .gitignore

* Added linking react-native-sentry to Fastlane

* Fixed fastlane to include newlines in sentry.properties

* Moved to manually link react-native-sentry

* Captured redux errors with Sentry

* Redid how Sentry is optionally compiled to be simpler

* Added Sentry middleware to create redux breadcrumbs

* Added Sentry tags for server version

* Initialize Sentry when testing

* Fixed string replacement for SentryEnabled in fastlane

* Added react-native-sentry to NOTICE.txt
2017-09-01 14:50:17 -03:00
enahum
ecf39f61dd Various fixes & improvements (#611)
* RN-166 follow user prefs for join/leave messages

* RN-158 Fix Android input textbox offscreen issue

* RN-181 Use device locale as default locale

* Upgrade mattermost-redux

* Fix TouchableHighlight in the channel drawer items

* Update channel title when switching channels

* Fix channel name title when switching teams

* Fix unit test
2017-06-08 15:40:29 -04:00
Chris Duarte
cbdfb4ff46 Add component unit testing (#588) 2017-05-31 08:59:20 -04:00
enahum
248dafbe0e RN-97 Changed navigation from NavigationExperimental to ReactNative Navigation (#540)
* Add react-navigator dependency

* Add react-native-navigation dependency

* react-native-navigation, ios and android config

* update react-native-navigation

* New navigation and code cleanup

* Set ScreenBackgroundColor

* Fix channel drawer event issue

* Applied RNPN non-working popInitial notification

* Android navbar and back button

* packages and notices

* MM-redux update

* Fix draft on team switch

* Remove custom NavBar
2017-05-16 11:19:46 -04:00
Chris Duarte
d206ea68de PLT-6173: Offline redux store (#471)
* PLT-6173: Offline redux store

* Review feedback
2017-04-09 21:51:47 -03:00
enahum
618b4bfc6f PLT-6156 Update npm dependencies (#451)
* PLT-6156 Update npm dependencies

* re-add remote-redux devtools to build in jenkins
2017-04-03 16:34:03 -03:00
enahum
56a27ce7ad PLT-5711 Fix Tapping on the button to open the drawers not always work (#383)
* PLT-5711 Fix Tapping on the button to open the drawers not always work

* PLT-6052 Include drawer transition fix

* feedback + unit tests
2017-03-22 23:38:01 -03:00
Chris Duarte
18cc7f1e7f PLT-5518 RN: Allow user to upload + send image file attachments (#373)
* PLT-5518 RN: Allow user to upload + send image file attachments

* Review feedback
2017-03-21 17:58:31 -04:00
Chris Duarte
2638a9c75d PLT-5517 Image file previewer (#344)
* PLT-5517 RN: Image file previewer

Add preview component and client routes
Add fade transition for modal
Add paging controls, title header, and info footer
Add drag to dismiss behavior
Fix android layout issues
Handle orientation change

* Fix tests

* Review feedback

* Review feedback
2017-03-17 09:04:35 -04:00
Chris Duarte
1e63ac2667 PLT-5599 RN: Modal options for Android (#353) 2017-03-16 15:13:36 -04:00
enahum
548633f5c0 PLT-5857 replace the service folder with mattermost-redux library (#348) 2017-03-14 10:52:24 -03:00
Chris Duarte
d36dc3412a PLT-5492 Add Account Settings > Notifications (#323)
* PLT-5492 RN: Add Account Settings > Notifications

* Review feedback
2017-03-13 15:37:44 -03:00