Commit Graph

93 Commits

Author SHA1 Message Date
Saturnino Abril
82d9995f2b fix issue that blocks adding test for thread screen (#2221) 2018-10-05 21:50:03 +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
enahum
c13a436d18 Enable SAML authentication (#325)
* enable saml authentication

* Fix unit tests

* Fix android cookies

* Feedback review
2017-03-09 14:07:18 -03:00
Chris Duarte
bb1446da91 Fix android web socket error (#321)
* Fix android web socket error

* Modify init args
2017-03-02 17:34:45 -03:00
enahum
b71052bd64 PLT-5660 Handle channel created WebSocket event (#306)
* Handle channel created WebSocket event

* increasing test timeout
2017-02-27 19:51:04 -03:00
enahum
c121097974 PLT-5587 Create channel (#300)
* PLT-5587 Create channel

* Feedback review

* hidding options in account settings
2017-02-27 16:17:18 -05:00
enahum
c1318fe834 PLT-5589 Reload configuration when the server config changes (#301) 2017-02-27 13:15:51 -05:00
Chris Duarte
b09dbbb79c PLT-5493 Add a profile scene that shows user information (#287)
* PLT-5493 React Native: Add a profile scene that shows user information

* Review feedback
2017-02-24 10:17:05 -03:00
Chris Duarte
4f2d769766 PLT-5541 Autocomplete mentions in post textbox (#266)
* WIP channel autocomplete

* Channel mentions

* Feedback Review
2017-02-20 18:19:11 -03:00
Chris Duarte
3b7a6df617 PLT-5530 Render placeholder icons + metadata for file attachments in posts list (#249)
* Add icons for file types

* Compress image files for file type icons

* Add constants for file types

* Add utils for file metadata

* Add actions & reducers for fetching file attachments

* Render file attachments in posts

* Add reducers for handling files requests

* Refactor getFileType in file utils

* Refactor getFileIconPath in file utils

* Refactor getFormattedFileSize in file utils

* Trim trailing whitespace in getTruncatedFilename

* Style file attachment metadata

* Remove entity store reducer for files fetch failure

* Change filesForPost to fileIdsForPost in files store

* Use a selector for getFilesForPost

* Memoize getFilesForPost selector

* Dispatch postId with getFilesForPost

* Add test for getFilesForPost

* Upload seed file in getFilesForPost test

* Display correct icon for image attachments

* Fix reducers for receiving files for post

Expect response data to be array not object

* Style attachment post

* Merge headers (defaults + opts) in Client.doFetch

* Upload file as FormData

* Use form-data lib instead of built-in polyfill

* Associate file with post in getFilesForPost test

* Improve assertions in getFilesForPost test

* Check for createPost failure in getFilesForPost test

* Use correct post id in getFilesForPost test

* Use client not action to create post in getFilesForPost test

* Fix file upload in getFilesForPost test

* Add assertion for name of uploaded file

* Update attachment post style

* Fix spelling of loadFilesForPostIfNecessary

* Remove eslint-disable no-magic-numbers from file_utils.js

* Remove unused index prop from FileAttachment

* Clarify code for merging headers in Client.getOptions

* Dynamically truncate file attachment names

* Extract component for FileAttachmentIcon

* Use white bg for FileAttachmentIcon to match webapp styles

* Match webapp styles for file attachment borders

* Move file icon path lookup to FileAttachmentIcon

* Use more logical ordering for file type lookup
2017-02-17 17:40:40 -05:00
Harrison Healey
1115d882ca PLT-5566 Added clientside handling to automatically show direct channels (#270)
* Added TestServerUrl config setting

* Added clientside handling to show direct channels in the sidebar when a DM is received
2017-02-17 10:53:46 -05:00
enahum
61576c9474 PostList date separator to match webapp (#264)
* PostList date separator to match webapp

* Remove preference change test
2017-02-16 09:11:00 -05:00
enahum
a97238f75c Removed channel_viewed websocket event (#254) 2017-02-15 14:08:41 -03:00
enahum
51e8ee6ea2 More Direct Messages scene (#244)
* More Direct Messages scene

* Adding search_bar.js to mock tests

* Feedback review

* Address feedback review 2
2017-02-14 11:49:41 -05:00
Harrison Healey
249312b852 PLT-5252 Added Thread view (#239)
* Added Thread view

* Fixed added unit test

* Fixed copyright date on added file

* Moved scene-specific selector into service directory
2017-02-13 18:08:26 -03:00
Chris Duarte
c370e895bd Mention autocomplete (#242)
* Mention autocomplete

* Review feedback
2017-02-13 16:07:50 -05:00
Chris Duarte
088a2c7737 Navigation Drawer and Modal (#220)
Navigation header now responds to theme changes
Improve channel selection transition
Implement navigation modal
Reword options modal
2017-02-08 12:16:24 -08:00
enahum
b3b3d9a39a Squashing several bugs (#221)
* Squashing several bugs

* Fix websocket tests
2017-02-08 10:28:27 -08:00
Chris Duarte
ce58429a21 Reworking navigation (#212)
* Reworking navigation

* Fixed navigation testing and lint errors
2017-02-02 16:13:25 -05:00