From c0429138dc60ef3d9924e2242e26b431b44b553d Mon Sep 17 00:00:00 2001 From: Dan Seawel Date: Wed, 10 Apr 2019 14:51:22 -0500 Subject: [PATCH] Merge 1.17 from staging to production (#52) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * Count the posts received after combining join/leave (#2378) * Fix Post and network indicator Layouts (#2382) * Fix post layout that caused text cutoff * Fix network indicator layout on non iPhone X devices * Fetch team channels on extension init (#2383) * Fix jewel in team sidebar for android (#2386) * Fix post menu touchables (#2385) * MM-12960: Only back to previous channel if is not archived (#2389) * Fixing no parseable (by the i18n extractor) optional chaining construction (#2387) * MM-13041: Not show direct channels without display name (#2388) * Android: Fix crash when attaching files from the downloads folder (#2390) * Add Ukrainian to Mattermost (#2392) * Fix fetching more channels to join (#2393) * Fix fetching more channels to join * update snapshot * Fixed issue where message attachments were empty if text came through on fallback (#2395) * Bump app build number to 160 (#2396) * More fixes to the post layout (#2408) * File image attachments sometimes do not open the image preview (#2397) * Update mattermost-redux sidebar sorting and WS fixes (#2410) * NOTICE.txt updates for December 2018 (#2417) - Removed no-longer-used dependency `react-native-drawer-layout` - Minor authorship/copyright/URL updates * Add support for Elixir syntax highlighting (#2355) see https://github.com/mattermost/mattermost-webapp/pull/2056 * Adding i18n-extract task to the Makefile (#2416) * Fixed typo in i18nId (#2384) There are should be `mobile.advanced_settings.delete_file_cache` instead of `mobile.advanced_settings.clear_downloads`. * 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 * Bump app build number to 161 (#2421) * Wait 1s before clearing notifications when app is brought to the foreground (#2419) * [MM-8404] Channel notification setting for disabling channel mentions (#MM-8404) (#2302) * Channel notification setting for disabling channel mentions (#MM-8404) * Replaces raw string value by constants (#MM-8404) * Updates import according to redux update (#MM-8404) * make circular badge on jewel for single-digit mention (#2422) * render text for non-existent emoji when post metadata is enabled (#2423) * Fix opening documents on Android (#2425) * Android extension channel list to display all items (#2426) * Update fastlane env vars example (#2402) * Fix reaction list cutoff at end of list (#2424) * MM-13361 Set Open Teams icons background to white (#2430) * MM-13362 Update account settings header color when changing theme (#2431) * MM-13362 Update account settings header color when changing theme * Removed unneded static var * Fix team mention badge alignment on iOS (#2427) * MM-13364 Fix text too light on dark themes in TextSetting widget (#2432) * MM-13366 Post menu doesn't hint at more options below the fold (#2434) * MM-13367 Unexpected scrolling/blank while long post is incoming (#2435) * MM-13374 Fix collapse posts with long message attachments (#2436) * MM-13379 Make deleted comments indented (#2437) * Sort pinned posts from newest to oldest (#2440) * Sort pinned posts from newest to oldest * Update mattermost-redux * MM-13368 Do not truncate tall images in preview screen (#2438) * MM-13368 Do not truncate tall images in preview screen * Add unit test for viewport max height * Fix typo * MM-13358 iOS Share extension channel list (#2429) * Hide Favorite channel section when there are not favorite channels (#2439) * Properly check if link is an image when link is shortened (#2441) * MM-13365/MM-13375 Fix edit profile image (#2433) * MM-13365/MM-13375 Fix edit profile image * Set Max file size to 20Mb * MM-13419 Fix leaving private channel from another client (#2442) * update redux commit to fix sorting of channels at sidebar unreads section (#2444) * Bump app build number to 162 (#2445) * Update react-native-image-picker dependency (#2446) * Fix edit profile image (#2448) * Fix copy markdown link (#2449) * MM-13420 Always show the Unreads section in the channel list (#2451) * MM-13421 Fix channel sidebar sometimes using old permissions (#2450) * MM-12906 - Add thumbnails to theme selection (#2381) * MM-13431 Fix load more posts (#2452) * Load more posts of a channel by determining the amount of posts shown regardless of how many are in the store * Feedback review * do not combine posts when fetching them * Post Menu initial position to show one option cut off (#2453) * MM-13333 Fix minor alignment issue with reply thread indicator (#2456) * Add a pixel to margin right for profile_picture container to compensate status icon platform styles * Bump app build number to 163 (#2459) * prevent double tap on Channel Info options (#2455) * Update date separators when timezone changes (#2443) * Update date separators when timezone changes * Fix typo * Remove extra divider below Edit Channel in Channel info (#2454) * Remove extra divider below Edit Channel in Channel info * Fix indentation * v1.15 Changelog (#2370) * Update CHANGELOG.md * Update CHANGELOG.md * Update CHANGELOG.md * Update CHANGELOG.md Co-Authored-By: amyblais * Update CHANGELOG.md * Update CHANGELOG.md * Update CHANGELOG.md Co-Authored-By: amyblais * Update CHANGELOG.md * Update CHANGELOG.md Co-Authored-By: amyblais * MM-12354 Remove Profile Image (#2428) * save progress * Add option to remove profile picture * missed when rebasing * rename extraOptions to removeProfileImage * clean up removeProfileImage action * placeholder after removing profile picture, unit tests * [MM-13433] Fix unnecessary rendering for reactions component and reaction list screen (#2464) * fix unnecessary rendering for reactions component and reaction list screen * update redux commit * Show an alert box when the team could not be joined (#2462) * Bump app build number to 164 (#2469) * Bump app build number to 165 and increase minimum Android SDK version (#2470) * Bump app build number to 165 * Increase Android minimum SDK version * Add the onMessage handler when sso completes (#2474) * Add the onMessage handler when sso completes * Enable handler only for mattermost server * Bump App Version to 1.15.1 and Build number to 166 (#2475) * Bump app version number to 1.15.1 * Bump app build number to 166 * Fix formatting error in changelog and add note about Android compatibility change in v1.15 (#2465) * Fix formatting error in changelog * Update CHANGELOG.md * Update CHANGELOG.md * Fixes for duplicate text on message attachments, empty space when attachment has no title (#2460) * LHS use getSortedFavoriteChannelIds instead of getFavoriteChannelIds (#2471) * Fix post menu rounded corners (#2472) * Bump version to 1.16.0 and Build number to 167 (#2481) * Fix fastlane platform thumbnail * Bump app version number to 1.16.0 * Bump app build number to 167 * Edit Profile fix * Update CHANGELOG.md (#2486) * Handling nulls in getMyCurrentChannelMembership (#2488) * MM-13405 Change warning message to be singular when adding last user to GM (#2478) * MM-13432 Remove unsed request flags from channel_members (#2490) * Remove unsed request flags from channel_members * Fix intial state to match redux state * Update redux hash * MM-11232 Fix table column width to better support wide tables (#2467) * MM-11232 Fix table column width to better support wide tables * Fix horizontal scrolling on Android * Fix visibility of retry failed message option (#2492) * Fix visibility of retry failed message option * Feedback review * Fix other users status changes (#2491) * Update fastlane (#2494) * Handling nulls in getMyChannelMember (#2493) * Handling nulls in getMyChannelMember * Addressing review comments * MM-13432 Remove getFilesForPost request state and use react state (#2496) * MM-13432 Remove getFilesForPost request state and use react state * Add test cases * Fix Keywords modal title on Android (#2498) * MM-13666 Detect post as emoji only if not a codeblock (#2497) * Detect post as emoji only if not a codeblock * Feedback review Co-Authored-By: enahum * Feedback review Co-Authored-By: enahum * MM-13654: Removes pin and delete longpress options from posts in arch… (#2495) * MM-13654: Removes pin and delete longpress options from posts in archived channels. * MM-13654: Maintains existing option order. Updates others' posts options. * Fix settings screen not showing joinable teams (#2500) * Bump app build number to 168 (#2505) * MM-13665 Prevent quick multiple taps on file to open multiple file previews (#2503) * MM-13751: Fix for incorrect access to delete button. (#2508) * Bump app build number to 169 (#2510) * Version 1.15.2 and Build number 170 (#2513) * Bump app version number to 1.15.2 * Bump app build number to 170 * v1.16 Changelog (#2487) * Update CHANGELOG.md * Update CHANGELOG.md * Update CHANGELOG.md * Update CHANGELOG.md * translations PR 20190121 (#2518) * Clicking username in read-only allows sending message (#2489) * Update fastlane (#2526) * Fastlane env vars example update (#2527) * MM-13722 Set the application badge to the number of mentions (#2523) * MM-13752 Thread view should not display new message indicator (#2519) * Change the prop `indicateNewMessages` on postList in thread view to be false * MM-13439 change close edit profile window text to Cancel (#2520) * MM-13673 combine reset cache & delete files into one action (#2499) * MM-13846 Alert boxes to follow UX Guidelines (#2525) * MM-13525 Fix alignment of jewel on channel drawer icon (#2473) * MM-13525 Fix alignement of jewel on channel drawer icon Fix position of dot Fix snapshot Change unread indicator to be View instead of . text * Fix position of dot for unread indicator in badge * Update snapshot * Bump Version to 1.16.0 and Build number 171 (#2530) * Bump app build number to 171 * Bump app version number to 1.16.0 * [MM-13412 & MM-13711] Allow showing of all post options if possible to fit 75% of the screen height (#2501) * allow showing all options if possible to fit 60% of the screen height * change max initial position from 60% to 70% * fix broken UI of the bottom part of post options * change to 75% * Bump redux version. (#2531) * MM-13875 Fix user profile icon for a Webhook to follow the prop for use_user_icon (#2533) * MM-13876 React Native: Webhook icon is misaligned and bottom edges are cut off (#2536) * Enable tapping on channels when jump to textfield is focused. (#2535) * Allow tapping on channels in the filtered list … … when the keyboard is open. This option also allows tapping on non-interactive areas to still dismiss the keyboard. * keyboard propery updates - change ‘on-drag’ to ‘interractive’ - change ‘handled’ to ‘always’ to be more consistent with other uses of same property * support multiple keyboard dismiss modes * MM-13866 Never ending loader if app is un authenticated (#2539) * if token or url is not present setState of loaded flag to true * [MM-13839] Remove possibility to change eMail within mobile app (#2540) * Make eMail setting read only * Add translation entry, change wording * Update wording * MM-13897 preserve iOS push notifications when opening the app and set the proper badge count (#2541) * MM-13859 set the auth token when fetching images from the server (#2537) * MM-13859 set the auth token when fetching images from the server * set the image_cache siteURL from redux * HH suggestion Co-Authored-By: enahum * Removing comment * Bump app build number to 172 (#2543) * Update NOTICE.txt (#2544) - Minor copyright owner updates * [MM-13677] Fix to ensure unsupported unicode emoji can be rendered jumbo size (#2545) * fixes unicode emoji not rendering jumbo - replace inline emoji regex with npm emoji-regex library - update notice.txt with emoji-regex license - jumbo emoji issue automatically fixed with updated unicode emoji regex * Add several tests specifically for 🤟emoji. * Fix previewing doc files more than once on Android (#2550) * MM-13974 Missing translations (#2549) * Missing translations * update snapshots * Fix placeholder image on Android when profile pic is removed (#2551) * MM-13830 Ensure schedule of session expired notification (#2554) * Ensure schedule of session expired notification * feedback review * passing intl instead of message * Add support for relative permalinks (#2555) * Bump app build number to 173 (#2557) * MM-13337 Fix EMM connections using VPN on-demand (#2558) * Fix EMM connections using VPN on-demand * Update package.json * Update package-lock.json * MM-13428 Updating mm-redux hash (#2566) * [MM 13720] Fix for "No internet connection" banner not always showing (#2563) * Add `opacity` to compopnent state … … to trigger render updates when the property changes. * Fix bug stopping app from updating connection status - if the app is opened when no internet connection is present, turning on the internet with the app open will not remove the `No internet connection` message. * style corrections * Build Fix * MM-14001 Don't mount PostBodyAdditionalContent for system messages (#2564) * MM-14055: Load the channel even if not joining. (#2567) * Fix alignment of count on channel drawer (#2569) * [MM 13934] Prevent blank mention keys from crashing the app (#2570) * don’t match blank word boundaries * test for blank mention keys * Check for blank mention before looking for match * account for multiple spaces as a blank mention * Deep linking based on channel url; Fix merge conflicts (#2542) Code cleanup * Bump app build number to 174 (#2572) * Bump app build number to 175 (#2573) * Update mattermost-redux to latest (#2574) * v1.16 Changelog (#2529) * MM-13896 Sync channel as read between clients (including opening Push Notifications) (#2548) * Update mattermost-redux to use latest WS changes * Properly mark channel as read, keep the new message indicator, and fix push notification flow * unneeded parameter in setCurrentUserStatusOffline Co-Authored-By: enahum * Feedback review * Update mm-redux ref * [MM-13295] Make channel link clickable for user who's not member of the public channel (#2466) * Make channel link clickable for user who's not member of the public channel * update per review * update per comment * remove setChannelDisplayName * Don't show confusing versioning message in "Check for Updates" screen when using a beta/testing build or platform config hasn't been updated for prod (#2556) UI doesn't update when NO_BETA is set * Fix opengraph and reactions for older servers (#2581) * [MM-14017] Fix whitespace between input box and post list on iOS (#2580) * fix whitespace between input box and post list on iOS * corrected viewPosition when pulling down the post list and add constant for thread screen * corrected changes made to viewPosition * [MM-13975] Add Terms of Service and Privacy Policy Links (#2559) * [MM-13975] Add terms of service and privacy policy links * [MM-13975] Address comments * [MM-10346] Set CSRF Token from Cookie after Login / on App load (#2534) * Set CSRF Token from Cookie after Login / on App load * Reset CSRF on Logout * Simplify cookie value access * Make Set CSRF Blocking * [MM 13161] Mobile: Add paging to Select Teams screen (#2468) * Use updated getJoinableTeams function from mattermost-redux * Use onEndReached for infinite scrolling of paginated teams * Add onRefresh * Update Settings screen to expect joinableTeams as array * Fix linter issues * Test that page is updated after getTeams() call * Revert package-lock.json changes * Update mattermost-redux dependency * Update mattermost-redux dependency * Only call getTeams if more can be loaded and only after a previous call has completed * Update snapshot due to prop * Update CustomList to support refreshing as well as option to not render the separator * Use CustomList in SelectTeam * Prevent the app from crashing when file mime type is null (#2582) * Bump app Version to 1.16.1 and Build Number to 176 (#2584) * Bump app build number to 176 * Bump app version number to 1.16.1 * Update fastlane * Dependencies update (#2576) * Dependencies update * Fix WebView * Update to RN 0.58.5 and include the WebSocket fix * Update react-native-video * Fix RNFetchBlob * Migrate Android from GCM to FCM (#2577) * Fix utils reference (#2586) * Update mattermost-redux (#2587) * [MM-13954] Fix prop type for post reactions (#2578) * Fix prop type for post reactions * Update react list test * Update CHANGELOG.md (#2589) * [MM-14193] Render emojis in Message Attachment title (#2591) * immediately return when connection is offline (#2594) * Update Android RAM Bundle (#2585) * Update Android RAM Bundle * Remove missed files and fix README * rename schedule to scheduler * fix README.md formatting (#2592) * iOS Native Share Extension (Swift) (#2575) * iOS Native Share Extension (Swift) * Re-arrange files * Fix .gitignore * Use forked react-native-navigation with v1 patch (#2596) * Bump Version to 1.17.0 Build 177 (#2602) * Bump app build number to 177 * Bump app version number to 1.17.0 * Update sentry to fix android build (#2603) * Handle pending posts when dispatching RECEIVED_NEW_POST (#2606) * Check for null uri prior to getting path to shared content (#2607) * Ensure data has url key before attempting upload (#2609) * Fix crash when fresh install android when getting the fcm token (#2608) * Add coverage to .gitignore (#2601) * [MM-14081] Show MFA Prompt after Server returned error for login request (#2599) * Show MFA Prompt after Server returned error for login request * eslint * Hide MFA error on first login attempt * [MM-13824] add one_you strings for better translatability in team/channel related messages. (#2604) * [MM-14238] Add make command to generate unsigned x86_64 build for VM/simulator (#2597) * add make command to generate unsigned x86_64 build for VM/simulator * updated per comment, added common function at makefile * added start|stop_packger to start and stop phony * Update NOTICE.txt (#2618) - Minor copyright owner updates * fix intermittent crash when selecting a link (#2620) * fix default email interval from never to immediate (#2614) * Fix checkLoginResponse for MFA (#2623) * Update PULL_REQUEST_TEMPLATE.md (#2616) So the links looked like placeholder wiki redirects, fixed them to their targets * fix undefined site URL when copying permalink (#2629) * fix enabling post icon override (#2611) * Fix github issues link (#2615) * Fix github issues link * Fix link to issues for server tagged ReactNative * Fix regression when sharing files with spaces in the filename (#2624) * Set the correct channel display name when switching teams (#2625) * Add target to Mattermost and MattermostShare (#2626) * Wait for VPN connection only when appconfig flag is set (#2627) * Bump app build number to 178 (#2630) * Bump app build number to 179 (#2632) * Do not show deactivated users when adding members (#2613) * Highlight CJK mention keywords in sentense (#2590) * [MM-14192] Render hyperlinks in Message Attachment title (#2617) * Change comment to more common xml format (#2621) * fix multiple text entries when typing with Shift+Letter on Android (#2634) * do not save email interval preference on cancel on Android device (#2633) * Add Office 365 login support (#2628) * fix channel mention when app is started from push notification (#2638) * MM-14461: make @-mentions (and searches) case insensitive (#2641) * [MM-14527] Fix default behavior when enabling/disabling email batching (#2642) * fix default behavior when enabling/disabling email batching * update redux commit to master - 98856a3 * Bump app build number to 180 (#2645) * fix channel mention badge and posts after opening the app from push notification (which is initially at closed state) (#2648) * fix email setting to "Never" when first saved (hitting back button on iOS) without actually changing the selection (#2650) * Bump app build number to 181 (#2651) * Clear iOS notifications on channel read (#2652) * MM-14630 Mark channel as read and viewed when opening brought from the background (#2658) * iOS Share Extension fix post and dm/gm list (#2659) * MM-14629 DMs and GMs for the iOS extension to match sidebar * MM-14631 ios extension logging and fix race condition to post after uploading * Bump app build number to 182 (#2661) * MM-13795 Detect timezone updates on Android (#2660) * MM-14154 Update react-native-image-gallery (#2655) * translations PR 20190318 (#2657) * remove state.value and rely only on props.value (#2635) * MM-14316 Android Notifications and reply to notifications from native code (#2653) * MM-14316 Android Notifications and reply to notifications from native code * Feedback review * Fix typo * setBadgeIconType only for Android 8+ * v1.17 changelog (#2598) * fix showing o fpost options for system admin (#2644) * Do not use WebKit for CookieManager operations in SSO (#2515) * Do not use WebKit for CookieManager operations in SSO This allows the SSO login to function again with devices that are not running IOS-11. * Use WebKit for CookieManager operations only with iOS 11 or later Detect OS version and use WebKit only when iOS 11 or later is detected. This allows the SSO login to function again with older devices. * Support MinimumHashtagLength setting (#2583) * Support MinimumHashtagLength setting * Set default value if missing * IWA support for Android and iOS (#2654) * MM-14459 Ensure hydrationComplete is set to true when resetting the cache and logging out (#2664) * Transfer dependencies from enahum to mattermost (#2666) * Bump Version to 1.18.0 and Build to 183 (#2667) * Bump app build number to 183 * Bump app version number to 1.18.0 * [MM-13381] Added reply to post options (#2665) * [MM-13381] Added reply to post options * [MM-13381] Fixes for adding reply to post options * [MM-13381] Fixed logic for adding reply to post options * [MM-13381] Fixed canReply logic for post options * MM-14345: Changes the channelIsReadOnly prop to be associated to the post's channel rather than the current channel. Show the unpin regardless of whether a channel is read-only. (#2656) * BG load messages (on latest upstream) * Allow for deep linking with "/vault#" in url to support email notifications * Fixes for iOS crash when attempting to scroll to recent post on empty channel * [MM-14866] Fix app crash due to parseInt call on null and display test notification message (#2690) * Call setNumber on notification only if badge is not null * Move setNumber call * Add bundle to empty list * Reminder message (`/remind`) do not show message text on mobile. (#51) --- .gitignore | 2 + CHANGELOG.md | 155 + Makefile | 101 +- NOTICE.txt | 224 +- PULL_REQUEST_TEMPLATE.md | 2 +- README.md | 16 +- android/app/build.gradle | 32 +- android/app/src/main/AndroidManifest.xml | 4 +- .../app/src/main/assets/fonts/AntDesign.ttf | Bin 0 -> 70344 bytes .../app/src/main/assets/fonts/EvilIcons.ttf | Bin 13128 -> 13456 bytes android/app/src/main/assets/fonts/Feather.ttf | Bin 0 -> 65112 bytes .../main/assets/fonts/FontAwesome5_Brands.ttf | Bin 0 -> 134160 bytes .../assets/fonts/FontAwesome5_Regular.ttf | Bin 0 -> 40080 bytes .../main/assets/fonts/FontAwesome5_Solid.ttf | Bin 0 -> 208792 bytes .../app/src/main/assets/fonts/Ionicons.ttf | Bin 143936 -> 112472 bytes .../assets/fonts/MaterialCommunityIcons.ttf | Bin 274464 -> 515304 bytes .../app/src/main/assets/fonts/Octicons.ttf | Bin 27428 -> 28364 bytes .../ResolvePromise.java | 26 + .../rnbeta/CustomPushNotification.java | 203 +- .../rnbeta/CustomPushNotificationDrawer.java | 39 + .../mattermost/rnbeta/MainApplication.java | 30 +- .../rnbeta/NotificationDismissService.java | 2 +- .../rnbeta/NotificationPreferencesModule.java | 28 + .../NotificationReplyBroadcastReceiver.java | 156 + .../rnbeta/NotificationReplyService.java | 81 - .../com/mattermost/share/RealPathUtil.java | 12 +- .../com/mattermost/share/ShareModule.java | 35 +- android/build.gradle | 18 +- .../gradle/wrapper/gradle-wrapper.properties | 2 +- android/settings.gradle | 4 + app/actions/views/channel.js | 148 +- app/actions/views/command.js | 9 +- app/actions/views/create_channel.js | 4 +- app/actions/views/edit_profile.js | 10 +- app/actions/views/login.js | 68 +- app/actions/views/login.test.js | 15 + app/actions/views/post.js | 6 +- app/actions/views/root.js | 22 +- app/actions/views/root.test.js | 23 + app/actions/views/select_team.js | 24 +- app/actions/views/user.js | 20 + app/actions/views/user.test.js | 50 + app/app.js | 3 +- .../__snapshots__/badge.test.js.snap | 68 + .../profile_picture_button.test.js.snap | 57 + .../announcement_banner.test.js.snap | 4 +- app/components/at_mention/at_mention.js | 39 +- app/components/attachment_button.js | 98 +- .../autocomplete_section_header.js | 12 +- .../channel_mention/channel_mention.js | 36 +- .../autocomplete/channel_mention/index.js | 2 - .../channel_mention_item.js | 7 +- .../emoji_suggestion/emoji_suggestion.js | 18 +- .../slash_suggestion/slash_suggestion.js | 16 +- .../autocomplete_selector.js | 289 + app/components/autocomplete_selector/index.js | 28 + app/components/badge.js | 73 +- app/components/badge.test.js | 27 + .../__snapshots__/channel_link.test.js.snap | 8 +- app/components/channel_link/channel_link.js | 54 +- .../channel_link/channel_link.test.js | 87 +- app/components/channel_link/index.js | 36 +- .../channel_loader/channel_loader.js | 16 +- app/components/channel_loader/index.js | 3 - .../client_upgrade_listener.js | 10 +- .../combined_system_message.js | 16 + app/components/custom_flat_list.js | 240 - .../__snapshots__/index.test.js.snap | 144 +- app/components/custom_list/custom_list_row.js | 1 + app/components/custom_list/index.js | 321 +- app/components/custom_list/index.test.js | 67 +- .../option_list_row/option_list_row.js | 6 + .../__snapshots__/user_list_test.test.js.snap | 67 +- .../user_list_row/user_list_row.js | 1 + app/components/custom_section_list.js | 306 - app/components/edit_channel_info/index.js | 11 +- app/components/emoji/emoji.js | 14 +- app/components/emoji/index.js | 4 +- .../__snapshots__/error_text.test.js.snap | 4 +- .../file_attachment_list.test.js.snap | 70 + .../file_attachment_list/file_attachment.js | 16 +- .../file_attachment_document.js | 59 +- .../file_attachment_icon.js | 8 +- .../file_attachment_list.js | 95 +- .../file_attachment_list.test.js | 90 + app/components/file_attachment_list/index.js | 1 - .../file_upload_item/file_upload_item.js | 3 +- app/components/flag_icon.js | 31 - app/components/formatted_markdown_text.js | 3 +- .../interactive_dialog_controller/index.js | 15 + .../interactive_dialog_controller.js | 76 + .../__snapshots__/hashtag.test.js.snap | 4 +- app/components/markdown/index.js | 5 +- app/components/markdown/markdown.js | 90 +- .../markdown_code_block.js | 23 +- .../__snapshots__/markdown_emoji.test.js.snap | 33 + .../markdown/markdown_emoji/index.js | 16 + .../markdown/markdown_emoji/markdown_emoji.js | 148 + .../markdown_emoji/markdown_emoji.test.js | 27 + .../markdown/markdown_image/markdown_image.js | 50 +- .../markdown/markdown_link/index.js | 12 +- .../markdown/markdown_link/markdown_link.js | 50 +- .../markdown/markdown_table/markdown_table.js | 81 +- .../markdown_table_cell.js | 12 +- .../markdown_table_row/markdown_table_row.js | 11 +- app/components/markdown/transform.js | 15 +- app/components/markdown/transform.test.js | 68 + .../action_menu/action_menu.js | 196 +- .../message_attachments/action_menu/index.js | 7 +- .../attachement_pretext.js | 57 + .../message_attachments/attachment_actions.js | 65 + .../message_attachments/attachment_author.js | 81 + .../message_attachments/attachment_fields.js | 145 + .../message_attachments/attachment_image.js | 169 + .../message_attachments/attachment_text.js | 120 + .../attachment_thumbnail.js | 43 + .../message_attachments/attachment_title.js | 95 + app/components/message_attachments/index.js | 12 +- .../message_attachments/message_attachment.js | 549 +- app/components/network_indicator/index.js | 46 + .../network_indicator/network_indicator.js | 434 + app/components/no_results.js | 17 +- app/components/offline_indicator/index.js | 36 - .../offline_indicator/offline_indicator.js | 307 - app/components/options_context/index.js | 6 - .../options_context.android.js | 71 - .../options_context/options_context.ios.js | 108 - app/components/post/index.js | 53 +- app/components/post/post.js | 312 +- .../post_add_channel_member.js | 5 +- .../post_attachment_opengraph.test.js.snap | 120 +- .../post_attachment_opengraph.js | 102 +- .../post_attachment_opengraph.test.js | 9 + app/components/post_body/index.js | 166 +- app/components/post_body/post_body.js | 430 +- app/components/post_body/post_body.test.js | 70 + .../post_body_additional_content/index.js | 18 +- .../post_body_additional_content.js | 133 +- .../post_pre_header.test.js.snap | 356 + app/components/post_header/index.js | 4 +- app/components/post_header/post_header.js | 12 - app/components/post_header/post_pre_header.js | 130 + .../post_header/post_pre_header.test.js | 153 + .../__snapshots__/post_list.test.js.snap | 145 + .../__snapshots__/date_header.test.js.snap | 84 +- .../post_list/date_header/date_header.js | 20 +- .../post_list/date_header/date_header.test.js | 16 + app/components/post_list/date_header/index.js | 13 + app/components/post_list/index.js | 3 +- app/components/post_list/post_list.ios.js | 41 +- app/components/post_list/post_list.test.js | 59 + app/components/post_list/post_list_base.js | 25 +- app/components/post_profile_picture/index.js | 6 +- app/components/post_textbox/index.js | 4 +- app/components/post_textbox/post_textbox.js | 2 +- .../profile_picture/profile_picture.js | 48 +- app/components/profile_picture_button.js | 80 + app/components/profile_picture_button.test.js | 66 + .../progressive_image/progressive_image.js | 3 + app/components/reactions/index.js | 21 +- app/components/reactions/reactions.js | 93 +- .../search_bar/search_bar.android.js | 18 +- .../show_more_button.test.js.snap | 36 +- .../__snapshots__/channel_item.test.js.snap | 90 +- .../channel_item/channel_item.js | 2 - .../filtered_list/filtered_list.js | 4 +- .../sidebars/main/channels_list/list/index.js | 8 +- .../sidebars/main/channels_list/list/list.js | 23 +- .../switch_teams_button.js | 2 - app/components/sidebars/main/main_sidebar.js | 10 +- .../teams_list_item/teams_list_item.js | 4 +- .../slide_up_panel/slide_up_panel.js | 379 +- .../slide_up_panel_indicator.js | 35 +- .../text_input_with_localized_placeholder.js | 14 +- .../widgets/settings/text_setting.js | 235 + .../widgets/settings/text_setting.test.js | 29 + app/constants/deep_linking.js | 8 + app/constants/index.js | 2 + app/constants/screen.js | 4 + app/constants/view.js | 6 + app/fetch_preconfig.js | 48 +- app/i18n/index.js | 12 +- app/initial_state.js | 108 +- app/mattermost.js | 36 +- app/mattermost_bucket/index.js | 26 +- .../push_notifications.android.js | 12 +- .../push_notifications.ios.js | 25 +- app/reducers/views/channel.js | 37 + app/screens/about/about.js | 59 +- app/screens/channel/channel.js | 149 +- .../channel_nav_bar/channel_drawer_button.js | 27 +- .../channel_post_list/channel_post_list.js | 3 + .../channel/channel_post_list/index.js | 5 +- app/screens/channel/index.js | 5 +- .../channel_add_members.js | 419 +- .../channel_add_members.test.js | 78 + app/screens/channel_add_members/index.js | 23 +- app/screens/channel_info/channel_info.js | 283 +- app/screens/channel_info/channel_info_row.js | 2 +- app/screens/channel_info/index.js | 10 +- .../channel_members/channel_members.js | 431 +- app/screens/channel_members/index.js | 17 +- app/screens/channel_peek/channel_peek.js | 4 +- app/screens/channel_peek/index.js | 8 +- app/screens/client_upgrade/client_upgrade.js | 23 +- app/screens/create_channel/create_channel.js | 1 - app/screens/edit_post/edit_post.js | 2 +- .../__snapshots__/edit_profile.test.js.snap | 118 + app/screens/edit_profile/edit_profile.js | 193 +- app/screens/edit_profile/edit_profile.test.js | 84 + app/screens/edit_profile/edit_profile_item.js | 133 - app/screens/edit_profile/index.js | 3 +- app/screens/entry/entry.js | 4 - .../error_teams_list.test.js.snap | 4 +- .../error_teams_list/error_teams_list.js | 3 + app/screens/flagged_posts/flagged_posts.js | 3 + .../forgot_password.test.js.snap | 40 +- .../downloader_bottom_content.test.js.snap | 93 + .../__snapshots__/image_preview.test.js.snap | 16 +- app/screens/image_preview/downloader.ios.js | 67 +- .../downloader_bottom_content.js | 75 + .../downloader_bottom_content.test.js | 58 + app/screens/image_preview/image_preview.js | 19 +- app/screens/index.js | 10 +- .../interactive_dialog/dialog_element.js | 139 + app/screens/interactive_dialog/index.js | 36 + .../interactive_dialog/interactive_dialog.js | 195 + .../interactive_dialog.test.js | 95 + app/screens/login/index.js | 6 +- app/screens/login/login.js | 59 +- app/screens/login_options/login_options.js | 36 + app/screens/long_post/long_post.js | 6 +- .../menu_action_selector.test.js.snap | 525 - app/screens/menu_action_selector/index.js | 58 - .../menu_action_selector.js | 286 - app/screens/mfa/mfa.js | 5 +- .../__snapshots__/more_channels.test.js.snap | 50 +- app/screens/more_channels/index.js | 10 +- app/screens/more_channels/more_channels.js | 341 +- .../more_channels/more_channels.test.js | 80 +- app/screens/more_dms/index.js | 40 +- app/screens/more_dms/more_dms.js | 604 +- .../__snapshots__/selected_users.test.js.snap | 246 + .../more_dms/selected_users/selected_users.js | 43 +- .../selected_users/selected_users.test.js | 70 + app/screens/notification/notification.js | 2 +- .../option_modal_list.test.js.snap | 44 +- .../options_modal_list.android.js | 7 +- .../options_modal/options_modal_list.ios.js | 7 +- .../__snapshots__/permalink.test.js.snap | 34 +- app/screens/permalink/index.js | 4 +- app/screens/permalink/permalink.js | 22 +- app/screens/permalink/permalink.test.js | 2 - app/screens/pinned_posts/index.js | 51 + app/screens/pinned_posts/pinned_posts.js | 288 + .../__snapshots__/post_options.test.js.snap | 127 + app/screens/post_options/index.js | 137 + app/screens/post_options/post_option.js | 133 + app/screens/post_options/post_options.js | 469 + app/screens/post_options/post_options.test.js | 102 + .../post_options/post_options_utils.js | 27 + .../post_options/post_options_utils.test.js | 41 + .../reaction_header.test.js.snap | 166 +- .../reaction_header_item.test.js.snap | 12 +- .../__snapshots__/reaction_list.test.js.snap | 368 +- .../__snapshots__/reaction_row.test.js.snap | 32 +- app/screens/reaction_list/reaction_header.js | 26 +- app/screens/reaction_list/reaction_list.js | 77 +- .../reaction_list/reaction_list.test.js | 2 +- .../recent_mentions/recent_mentions.js | 1 + .../__snapshots__/modifier.test.js.snap | 82 + .../__snapshots__/recent_item.test.js.snap | 54 + app/screens/search/modifier.js | 96 + app/screens/search/modifier.test.js | 34 + app/screens/search/recent_item.js | 88 + app/screens/search/recent_item.test.js | 36 + app/screens/search/search.js | 181 +- .../search_result_post/search_result_post.js | 6 + app/screens/select_server/index.js | 4 +- app/screens/select_server/select_server.js | 54 +- .../__snapshots__/select_team.test.js.snap | 77 +- app/screens/select_team/index.js | 19 +- app/screens/select_team/select_team.js | 66 +- app/screens/select_team/select_team.test.js | 4 +- .../selector_screen.test.js.snap | 530 + app/screens/selector_screen/index.js | 39 + .../selector_screen/selector_screen.js | 389 + .../selector_screen.test.js} | 12 +- .../advanced_settings/advanced_settings.js | 76 +- .../display_settings.test.js.snap | 78 + .../display_settings/display_settings.js | 50 +- .../display_settings/display_settings.test.js | 36 + .../settings/display_settings/index.js | 4 + app/screens/settings/general/settings.js | 14 +- ...cation_settings_email.android.test.js.snap | 32 +- ...tification_settings_email.ios.test.js.snap | 6 +- .../notification_settings_email/index.js | 4 +- .../notification_settings_email.android.js | 8 +- ...otification_settings_email.android.test.js | 40 +- .../notification_settings_email.ios.js | 18 +- .../notification_settings_email.ios.test.js | 35 +- .../notification_settings_email_base.js | 57 +- .../notification_settings_mentions.android.js | 4 +- app/screens/settings/settings_item/index.js | 7 +- app/screens/sso/index.js | 4 +- app/screens/sso/sso.js | 78 +- app/screens/table/table.js | 45 +- .../terms_of_service.test.js.snap | 783 + app/screens/terms_of_service/index.js | 32 + .../terms_of_service/terms_of_service.js | 306 + .../terms_of_service/terms_of_service.test.js | 134 + .../theme/__snapshots__/theme.test.js.snap | 220 + app/screens/theme/index.js | 31 + app/screens/theme/theme.js | 167 + app/screens/theme/theme.test.js | 150 + app/screens/theme/theme_tile.js | 127 + .../thread/__snapshots__/thread.test.js.snap | 17 +- app/screens/thread/thread.js | 12 +- app/screens/thread/thread.test.js | 3 + .../__snapshots__/user_profile.test.js.snap | 28 +- app/screens/user_profile/user_profile.js | 3 + app/selectors/autocomplete.js | 36 +- app/selectors/autocomplete.test.js | 59 + app/selectors/post_list.js | 3 +- app/selectors/post_list.test.js | 109 +- app/selectors/theme.js | 39 + app/store/index.js | 27 +- app/store/middleware.js | 3 + .../bottom_sheet/bottom_sheet.android.js | 5 + app/utils/bottom_sheet/bottom_sheet.ios.js | 14 + app/utils/bottom_sheet/index.js | 5 + app/utils/client_upgrade.js | 13 +- app/utils/emoji_utils.js | 103 + app/utils/emoji_utils.test.js | 285 + app/utils/image_cache_manager.js | 23 +- app/utils/images.js | 3 + app/utils/images.test.js | 5 + app/utils/markdown.js | 1 + app/utils/member_list.js | 27 +- app/utils/network.js | 63 +- app/utils/push_notifications.js | 18 +- app/utils/reaction.js | 8 +- app/utils/reaction.test.js | 40 +- app/utils/security.js | 28 + app/utils/status.js | 1 + app/utils/theme.js | 5 + app/utils/timezone.js | 5 +- app/utils/url.js | 21 +- app/utils/url.test.js | 22 + assets/base/config.json | 5 +- assets/base/i18n/de.json | 113 +- assets/base/i18n/en.json | 49 +- assets/base/i18n/es.json | 79 +- assets/base/i18n/fr.json | 91 +- assets/base/i18n/it.json | 77 +- assets/base/i18n/ja.json | 99 +- assets/base/i18n/ko.json | 191 +- assets/base/i18n/nl.json | 79 +- assets/base/i18n/pl.json | 663 +- assets/base/i18n/pt-BR.json | 89 +- assets/base/i18n/ro.json | 119 +- assets/base/i18n/ru.json | 529 +- assets/base/i18n/tr.json | 75 +- assets/base/i18n/uk.json | 550 + assets/base/i18n/zh-CN.json | 77 +- assets/base/i18n/zh-TW.json | 83 +- assets/base/images/channel_info/pin.png | Bin 0 -> 328 bytes assets/base/images/channel_info/pin@2x.png | Bin 0 -> 900 bytes assets/base/images/channel_info/pin@3x.png | Bin 0 -> 1334 bytes assets/base/images/icons/webhook.jpg | Bin 20565 -> 13535 bytes assets/base/images/no_results/pin.png | Bin 0 -> 907 bytes assets/base/images/no_results/pin@2x.png | Bin 0 -> 1959 bytes assets/base/images/no_results/pin@3x.png | Bin 0 -> 2650 bytes assets/base/images/post_header/flag.png | Bin 0 -> 186 bytes assets/base/images/post_header/flag@2x.png | Bin 0 -> 257 bytes assets/base/images/post_header/flag@3x.png | Bin 0 -> 321 bytes assets/base/images/post_header/pin.png | Bin 0 -> 245 bytes assets/base/images/post_header/pin@2x.png | Bin 0 -> 425 bytes assets/base/images/post_header/pin@3x.png | Bin 0 -> 647 bytes assets/base/images/post_menu/copy.png | Bin 0 -> 293 bytes assets/base/images/post_menu/copy@2x.png | Bin 0 -> 493 bytes assets/base/images/post_menu/copy@3x.png | Bin 0 -> 719 bytes assets/base/images/post_menu/edit.png | Bin 0 -> 399 bytes assets/base/images/post_menu/edit@2x.png | Bin 0 -> 851 bytes assets/base/images/post_menu/edit@3x.png | Bin 0 -> 1278 bytes assets/base/images/post_menu/emoji.png | Bin 0 -> 400 bytes assets/base/images/post_menu/emoji@2x.png | Bin 0 -> 883 bytes assets/base/images/post_menu/emoji@3x.png | Bin 0 -> 1558 bytes assets/base/images/post_menu/flag.png | Bin 0 -> 365 bytes assets/base/images/post_menu/flag@2x.png | Bin 0 -> 612 bytes assets/base/images/post_menu/flag@3x.png | Bin 0 -> 878 bytes assets/base/images/post_menu/link.png | Bin 0 -> 441 bytes assets/base/images/post_menu/link@2x.png | Bin 0 -> 945 bytes assets/base/images/post_menu/link@3x.png | Bin 0 -> 1471 bytes assets/base/images/post_menu/pin.png | Bin 0 -> 448 bytes assets/base/images/post_menu/pin@2x.png | Bin 0 -> 920 bytes assets/base/images/post_menu/pin@3x.png | Bin 0 -> 1414 bytes assets/base/images/post_menu/reply.png | Bin 0 -> 380 bytes assets/base/images/post_menu/reply@2x.png | Bin 0 -> 737 bytes assets/base/images/post_menu/reply@3x.png | Bin 0 -> 1046 bytes assets/base/images/post_menu/trash.png | Bin 0 -> 511 bytes assets/base/images/post_menu/trash@2x.png | Bin 0 -> 952 bytes assets/base/images/post_menu/trash@3x.png | Bin 0 -> 1435 bytes assets/base/images/themes/check.png | Bin 0 -> 571 bytes assets/base/images/themes/check@2x.png | Bin 0 -> 937 bytes assets/base/images/themes/check@3x.png | Bin 0 -> 1246 bytes assets/base/images/themes/mattermost.png | Bin 0 -> 994 bytes assets/base/images/themes/mattermost@2x.png | Bin 0 -> 2095 bytes assets/base/images/themes/mattermost@3x.png | Bin 0 -> 3529 bytes assets/base/images/themes/mattermost_dark.png | Bin 0 -> 910 bytes .../base/images/themes/mattermost_dark@2x.png | Bin 0 -> 1976 bytes .../base/images/themes/mattermost_dark@3x.png | Bin 0 -> 3375 bytes assets/base/images/themes/organization.png | Bin 0 -> 996 bytes assets/base/images/themes/organization@2x.png | Bin 0 -> 2109 bytes assets/base/images/themes/organization@3x.png | Bin 0 -> 3529 bytes assets/base/images/themes/windows_dark.png | Bin 0 -> 905 bytes assets/base/images/themes/windows_dark@2x.png | Bin 0 -> 1961 bytes assets/base/images/themes/windows_dark@3x.png | Bin 0 -> 3354 bytes fastlane/Fastfile | 95 +- fastlane/Gemfile.lock | 65 +- fastlane/env_vars_example | 174 +- index.js | 1 + ios/Mattermost.xcodeproj/project.pbxproj | 824 +- .../xcschemes/Mattermost.xcscheme | 14 + .../xcschemes/MattermostShare.xcscheme | 111 + .../xcshareddata/WorkspaceSettings.xcsettings | 5 + ios/{ => Mattermost}/0155-keys.png | Bin ios/Mattermost/AppDelegate.m | 79 +- ios/Mattermost/Info.plist | 10 +- ios/Mattermost/Mattermost-Bridging-Header.h | 4 + ios/Mattermost/MattermostBucketModule.h | 7 + ios/Mattermost/MattermostBucketModule.m | 67 + ios/Mattermost/RuntimeUtils.swift | 7 + ios/MattermostBucket.h | 7 - ios/MattermostBucket.m | 126 - .../Base.lproj/MainInterface.storyboard | 4 +- .../ChannelsViewController.swift | 134 + ios/MattermostShare/GenericPreview.swift | 25 + ios/MattermostShare/GenericPreview.xib | 57 + ios/MattermostShare/Images/generic.png | Bin 0 -> 45380 bytes ios/MattermostShare/Info.plist | 15 +- ios/MattermostShare/Item.swift | 7 + .../MattermostShare-Bridging-Header.h | 6 + .../MattermostShare.entitlements | 18 - ios/MattermostShare/PerformRequests.h | 23 - ios/MattermostShare/PerformRequests.m | 154 - ios/MattermostShare/Section.swift | 13 + ios/MattermostShare/SessionManager.h | 23 - ios/MattermostShare/SessionManager.m | 300 - ios/MattermostShare/ShareViewController.h | 5 - ios/MattermostShare/ShareViewController.m | 285 - ios/MattermostShare/ShareViewController.swift | 405 + ios/MattermostShare/TeamsViewController.swift | 57 + ios/MattermostTests/Info.plist | 4 +- ios/Podfile | 2 +- ios/Podfile.lock | 8 +- .../project.pbxproj | 371 + .../xcschemes/UploadAttachments.xcscheme | 80 + .../UploadAttachments/AttachmentArray.swift | 269 + .../UploadAttachments/AttachmentItem.swift | 11 + .../UploadAttachments/Constants.h | 7 + .../UploadAttachments/Constants.m | 6 + .../UploadAttachments/MattermostBucket.h | 12 + .../UploadAttachments/MattermostBucket.m | 69 + .../UploadAttachments/StoreManager.h | 22 + .../UploadAttachments/StoreManager.m | 391 + .../UploadAttachments-Bridging-Header.h | 7 + .../UploadAttachments/UploadManager.swift | 53 + .../UploadAttachments/UploadSession.swift | 126 + .../UploadSessionManager.swift | 79 + ios/uploadDebugSymbols.sh | 2 - native_modules/RNCWKWebView.m | 693 + native_modules/RNCWebViewManager.java | 877 ++ native_modules/RNDocumentPicker.m | 44 +- package-lock.json | 11957 ++++++++-------- package.json | 133 +- packager/README.md | 3 +- packager/moduleNames.js | 861 +- packager/modulePaths.js | 383 +- share.ios.js | 8 - share_extension/android/actions/index.js | 12 +- share_extension/android/extension.js | 2 - .../extension_channels/extension_channels.js | 5 +- .../android/extension_channels/index.js | 2 +- .../android/extension_post/extension_post.js | 14 +- .../android/extension_post/index.js | 16 +- share_extension/android/index.js | 51 +- share_extension/android/navigation.js | 6 +- .../{android => common}/selectors/index.js | 28 +- share_extension/ios/error_message.js | 86 - share_extension/ios/extension.js | 164 - share_extension/ios/extension_channels.js | 350 - share_extension/ios/extension_nav_bar.js | 150 - share_extension/ios/extension_post.js | 839 -- share_extension/ios/extension_team_item.js | 119 - share_extension/ios/extension_teams.js | 219 - share_extension/ios/index.js | 68 - test/setup.js | 16 + 498 files changed, 30307 insertions(+), 18802 deletions(-) create mode 100644 android/app/src/main/assets/fonts/AntDesign.ttf create mode 100755 android/app/src/main/assets/fonts/Feather.ttf create mode 100644 android/app/src/main/assets/fonts/FontAwesome5_Brands.ttf create mode 100644 android/app/src/main/assets/fonts/FontAwesome5_Regular.ttf create mode 100644 android/app/src/main/assets/fonts/FontAwesome5_Solid.ttf create mode 100644 android/app/src/main/java/com/mattermost/rnbeta/CustomPushNotificationDrawer.java create mode 100644 android/app/src/main/java/com/mattermost/rnbeta/NotificationReplyBroadcastReceiver.java delete mode 100644 android/app/src/main/java/com/mattermost/rnbeta/NotificationReplyService.java create mode 100644 app/actions/views/root.test.js create mode 100644 app/actions/views/user.js create mode 100644 app/actions/views/user.test.js create mode 100644 app/components/__snapshots__/badge.test.js.snap create mode 100644 app/components/__snapshots__/profile_picture_button.test.js.snap create mode 100644 app/components/autocomplete_selector/autocomplete_selector.js create mode 100644 app/components/autocomplete_selector/index.js create mode 100644 app/components/badge.test.js delete mode 100644 app/components/custom_flat_list.js delete mode 100644 app/components/custom_section_list.js create mode 100644 app/components/file_attachment_list/__snapshots__/file_attachment_list.test.js.snap create mode 100644 app/components/file_attachment_list/file_attachment_list.test.js delete mode 100644 app/components/flag_icon.js create mode 100644 app/components/interactive_dialog_controller/index.js create mode 100644 app/components/interactive_dialog_controller/interactive_dialog_controller.js create mode 100644 app/components/markdown/markdown_emoji/__snapshots__/markdown_emoji.test.js.snap create mode 100644 app/components/markdown/markdown_emoji/index.js create mode 100644 app/components/markdown/markdown_emoji/markdown_emoji.js create mode 100644 app/components/markdown/markdown_emoji/markdown_emoji.test.js create mode 100644 app/components/message_attachments/attachement_pretext.js create mode 100644 app/components/message_attachments/attachment_actions.js create mode 100644 app/components/message_attachments/attachment_author.js create mode 100644 app/components/message_attachments/attachment_fields.js create mode 100644 app/components/message_attachments/attachment_image.js create mode 100644 app/components/message_attachments/attachment_text.js create mode 100644 app/components/message_attachments/attachment_thumbnail.js create mode 100644 app/components/message_attachments/attachment_title.js create mode 100644 app/components/network_indicator/index.js create mode 100644 app/components/network_indicator/network_indicator.js delete mode 100644 app/components/offline_indicator/index.js delete mode 100644 app/components/offline_indicator/offline_indicator.js delete mode 100644 app/components/options_context/index.js delete mode 100644 app/components/options_context/options_context.android.js delete mode 100644 app/components/options_context/options_context.ios.js create mode 100644 app/components/post_body/post_body.test.js create mode 100644 app/components/post_header/__snapshots__/post_pre_header.test.js.snap create mode 100644 app/components/post_header/post_pre_header.js create mode 100644 app/components/post_header/post_pre_header.test.js create mode 100644 app/components/post_list/__snapshots__/post_list.test.js.snap create mode 100644 app/components/post_list/post_list.test.js create mode 100644 app/components/profile_picture_button.js create mode 100644 app/components/profile_picture_button.test.js create mode 100644 app/components/widgets/settings/text_setting.js create mode 100644 app/components/widgets/settings/text_setting.test.js create mode 100644 app/constants/deep_linking.js create mode 100644 app/constants/screen.js create mode 100644 app/screens/channel_add_members/channel_add_members.test.js create mode 100644 app/screens/edit_profile/__snapshots__/edit_profile.test.js.snap create mode 100644 app/screens/edit_profile/edit_profile.test.js delete mode 100644 app/screens/edit_profile/edit_profile_item.js create mode 100644 app/screens/image_preview/__snapshots__/downloader_bottom_content.test.js.snap create mode 100644 app/screens/image_preview/downloader_bottom_content.js create mode 100644 app/screens/image_preview/downloader_bottom_content.test.js create mode 100644 app/screens/interactive_dialog/dialog_element.js create mode 100644 app/screens/interactive_dialog/index.js create mode 100644 app/screens/interactive_dialog/interactive_dialog.js create mode 100644 app/screens/interactive_dialog/interactive_dialog.test.js delete mode 100644 app/screens/menu_action_selector/__snapshots__/menu_action_selector.test.js.snap delete mode 100644 app/screens/menu_action_selector/index.js delete mode 100644 app/screens/menu_action_selector/menu_action_selector.js create mode 100644 app/screens/more_dms/selected_users/__snapshots__/selected_users.test.js.snap create mode 100644 app/screens/more_dms/selected_users/selected_users.test.js create mode 100644 app/screens/pinned_posts/index.js create mode 100644 app/screens/pinned_posts/pinned_posts.js create mode 100644 app/screens/post_options/__snapshots__/post_options.test.js.snap create mode 100644 app/screens/post_options/index.js create mode 100644 app/screens/post_options/post_option.js create mode 100644 app/screens/post_options/post_options.js create mode 100644 app/screens/post_options/post_options.test.js create mode 100644 app/screens/post_options/post_options_utils.js create mode 100644 app/screens/post_options/post_options_utils.test.js create mode 100644 app/screens/search/__snapshots__/modifier.test.js.snap create mode 100644 app/screens/search/__snapshots__/recent_item.test.js.snap create mode 100644 app/screens/search/modifier.js create mode 100644 app/screens/search/modifier.test.js create mode 100644 app/screens/search/recent_item.js create mode 100644 app/screens/search/recent_item.test.js create mode 100644 app/screens/selector_screen/__snapshots__/selector_screen.test.js.snap create mode 100644 app/screens/selector_screen/index.js create mode 100644 app/screens/selector_screen/selector_screen.js rename app/screens/{menu_action_selector/menu_action_selector.test.js => selector_screen/selector_screen.test.js} (92%) create mode 100644 app/screens/settings/display_settings/__snapshots__/display_settings.test.js.snap create mode 100644 app/screens/settings/display_settings/display_settings.test.js create mode 100644 app/screens/terms_of_service/__snapshots__/terms_of_service.test.js.snap create mode 100644 app/screens/terms_of_service/index.js create mode 100644 app/screens/terms_of_service/terms_of_service.js create mode 100644 app/screens/terms_of_service/terms_of_service.test.js create mode 100644 app/screens/theme/__snapshots__/theme.test.js.snap create mode 100644 app/screens/theme/index.js create mode 100644 app/screens/theme/theme.js create mode 100644 app/screens/theme/theme.test.js create mode 100644 app/screens/theme/theme_tile.js create mode 100644 app/selectors/autocomplete.test.js create mode 100644 app/selectors/theme.js create mode 100644 app/utils/bottom_sheet/bottom_sheet.android.js create mode 100644 app/utils/bottom_sheet/bottom_sheet.ios.js create mode 100644 app/utils/bottom_sheet/index.js create mode 100644 app/utils/emoji_utils.js create mode 100644 app/utils/emoji_utils.test.js create mode 100644 app/utils/security.js create mode 100644 assets/base/i18n/uk.json create mode 100644 assets/base/images/channel_info/pin.png create mode 100644 assets/base/images/channel_info/pin@2x.png create mode 100644 assets/base/images/channel_info/pin@3x.png create mode 100644 assets/base/images/no_results/pin.png create mode 100644 assets/base/images/no_results/pin@2x.png create mode 100644 assets/base/images/no_results/pin@3x.png create mode 100755 assets/base/images/post_header/flag.png create mode 100755 assets/base/images/post_header/flag@2x.png create mode 100755 assets/base/images/post_header/flag@3x.png create mode 100755 assets/base/images/post_header/pin.png create mode 100755 assets/base/images/post_header/pin@2x.png create mode 100755 assets/base/images/post_header/pin@3x.png create mode 100755 assets/base/images/post_menu/copy.png create mode 100755 assets/base/images/post_menu/copy@2x.png create mode 100755 assets/base/images/post_menu/copy@3x.png create mode 100755 assets/base/images/post_menu/edit.png create mode 100755 assets/base/images/post_menu/edit@2x.png create mode 100755 assets/base/images/post_menu/edit@3x.png create mode 100755 assets/base/images/post_menu/emoji.png create mode 100755 assets/base/images/post_menu/emoji@2x.png create mode 100755 assets/base/images/post_menu/emoji@3x.png create mode 100755 assets/base/images/post_menu/flag.png create mode 100755 assets/base/images/post_menu/flag@2x.png create mode 100755 assets/base/images/post_menu/flag@3x.png create mode 100755 assets/base/images/post_menu/link.png create mode 100755 assets/base/images/post_menu/link@2x.png create mode 100755 assets/base/images/post_menu/link@3x.png create mode 100755 assets/base/images/post_menu/pin.png create mode 100755 assets/base/images/post_menu/pin@2x.png create mode 100755 assets/base/images/post_menu/pin@3x.png create mode 100644 assets/base/images/post_menu/reply.png create mode 100644 assets/base/images/post_menu/reply@2x.png create mode 100644 assets/base/images/post_menu/reply@3x.png create mode 100755 assets/base/images/post_menu/trash.png create mode 100755 assets/base/images/post_menu/trash@2x.png create mode 100755 assets/base/images/post_menu/trash@3x.png create mode 100644 assets/base/images/themes/check.png create mode 100644 assets/base/images/themes/check@2x.png create mode 100644 assets/base/images/themes/check@3x.png create mode 100644 assets/base/images/themes/mattermost.png create mode 100644 assets/base/images/themes/mattermost@2x.png create mode 100644 assets/base/images/themes/mattermost@3x.png create mode 100644 assets/base/images/themes/mattermost_dark.png create mode 100644 assets/base/images/themes/mattermost_dark@2x.png create mode 100644 assets/base/images/themes/mattermost_dark@3x.png create mode 100644 assets/base/images/themes/organization.png create mode 100644 assets/base/images/themes/organization@2x.png create mode 100644 assets/base/images/themes/organization@3x.png create mode 100644 assets/base/images/themes/windows_dark.png create mode 100644 assets/base/images/themes/windows_dark@2x.png create mode 100644 assets/base/images/themes/windows_dark@3x.png create mode 100644 ios/Mattermost.xcodeproj/xcshareddata/xcschemes/MattermostShare.xcscheme create mode 100644 ios/Mattermost.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings rename ios/{ => Mattermost}/0155-keys.png (100%) create mode 100644 ios/Mattermost/Mattermost-Bridging-Header.h create mode 100644 ios/Mattermost/MattermostBucketModule.h create mode 100644 ios/Mattermost/MattermostBucketModule.m create mode 100644 ios/Mattermost/RuntimeUtils.swift delete mode 100644 ios/MattermostBucket.h delete mode 100644 ios/MattermostBucket.m create mode 100644 ios/MattermostShare/ChannelsViewController.swift create mode 100644 ios/MattermostShare/GenericPreview.swift create mode 100644 ios/MattermostShare/GenericPreview.xib create mode 100644 ios/MattermostShare/Images/generic.png create mode 100644 ios/MattermostShare/Item.swift create mode 100644 ios/MattermostShare/MattermostShare-Bridging-Header.h delete mode 100644 ios/MattermostShare/PerformRequests.h delete mode 100644 ios/MattermostShare/PerformRequests.m create mode 100644 ios/MattermostShare/Section.swift delete mode 100644 ios/MattermostShare/SessionManager.h delete mode 100644 ios/MattermostShare/SessionManager.m delete mode 100644 ios/MattermostShare/ShareViewController.h delete mode 100644 ios/MattermostShare/ShareViewController.m create mode 100644 ios/MattermostShare/ShareViewController.swift create mode 100644 ios/MattermostShare/TeamsViewController.swift create mode 100644 ios/UploadAttachments/UploadAttachments.xcodeproj/project.pbxproj create mode 100644 ios/UploadAttachments/UploadAttachments.xcodeproj/xcshareddata/xcschemes/UploadAttachments.xcscheme create mode 100644 ios/UploadAttachments/UploadAttachments/AttachmentArray.swift create mode 100644 ios/UploadAttachments/UploadAttachments/AttachmentItem.swift create mode 100644 ios/UploadAttachments/UploadAttachments/Constants.h create mode 100644 ios/UploadAttachments/UploadAttachments/Constants.m create mode 100644 ios/UploadAttachments/UploadAttachments/MattermostBucket.h create mode 100644 ios/UploadAttachments/UploadAttachments/MattermostBucket.m create mode 100644 ios/UploadAttachments/UploadAttachments/StoreManager.h create mode 100644 ios/UploadAttachments/UploadAttachments/StoreManager.m create mode 100644 ios/UploadAttachments/UploadAttachments/UploadAttachments-Bridging-Header.h create mode 100644 ios/UploadAttachments/UploadAttachments/UploadManager.swift create mode 100644 ios/UploadAttachments/UploadAttachments/UploadSession.swift create mode 100644 ios/UploadAttachments/UploadAttachments/UploadSessionManager.swift create mode 100644 native_modules/RNCWKWebView.m create mode 100644 native_modules/RNCWebViewManager.java delete mode 100644 share.ios.js rename share_extension/{android => common}/selectors/index.js (89%) delete mode 100644 share_extension/ios/error_message.js delete mode 100644 share_extension/ios/extension.js delete mode 100644 share_extension/ios/extension_channels.js delete mode 100644 share_extension/ios/extension_nav_bar.js delete mode 100644 share_extension/ios/extension_post.js delete mode 100644 share_extension/ios/extension_team_item.js delete mode 100644 share_extension/ios/extension_teams.js delete mode 100644 share_extension/ios/index.js diff --git a/.gitignore b/.gitignore index 125949039f9..965da8f362c 100644 --- a/.gitignore +++ b/.gitignore @@ -1,5 +1,6 @@ assets/override dist +build-ios *.zip server.PID mattermost.keystore @@ -80,6 +81,7 @@ ios/sentry.properties # Testing .nyc_output +coverage # Pods .podinstall diff --git a/CHANGELOG.md b/CHANGELOG.md index 62a74055000..84503a9403e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,160 @@ # Mattermost Mobile Apps Changelog +## 1.17.0 Release +- Release Date: March 20, 2019 +- Server Versions Supported: Server v4.10+ is required, Self-Signed SSL Certificates are not supported unless the user installs the CA certificate on their device + +### Combatibility + - If **DisableLegacyMfa** setting in ``config.json`` is set to ``true`` and [multi-factor authentication](https://docs.mattermost.com/deployment/auth.html) is enabled, ensure your users have upgraded to mobile app version 1.17 or later. See [Important Upgrade Notes](https://docs.mattermost.com/administration/important-upgrade-notes.html) for more details. + - Fixed support for EMM connections using VPN on-demand to indicate that every request should wait for the VPN connection to be establish and to set the value in seconds for the timeout. See docs for more details on [setting AppConfig values](https://docs.mattermost.com/mobile/mobile-appconfig.html#mattermost-appconfig-values) for VPN support. + - Mobile App v1.13+ is required for Mattermost Server v5.4+. + - Android operating system 7+ [is required by Google](https://android-developers.googleblog.com/2017/12/improving-app-security-and-performance.html). + - iPhone 5s devices and later with iOS 11+ is required. + +### Highlights + - iOS Share Extension now supports large file sizes and improved performance + +### Bug Fixes + - Fixed support for EMM connections using VPN on-demand. See docs for more details on [setting AppConfig values](https://docs.mattermost.com/mobile/mobile-appconfig.html#mattermost-appconfig-values) for VPN support. + - Fixed several Android app crash / fatal error issues. + - Fixed an issue on Android where the app crashed intermittently when selecting a link. + - Fixed an issue where email notifications setting was out of sync with the webapp until the setting was edited. + - Fixed an issue where notification badges were not cleared from other clients when clicking on a push notification after opening the mobile app. + - Fixed an issue where the app did not show local notification when session expired. + - Fixed an issue where the profile picture for webhooks was showing the hook owner picture. + - Fixed an issue where some emoji were not rendered as jumbo. + - Fixed an issue where jumbo emoji posted as a reply sometimes appeared with large space beneath. + - Fixed an issue where the "No Internet Connection" banner did not always display when internet connectivity was lost. + - Fixed an issue where the "No Internet Connection" banner did not always disappear when connection was re-estabilished. + - Fixed an issue where opening channels with unreads had loading indicator placed above unread messages line. + +## 1.16.1 Release +- Release Date: February 21, 2019 +- Server Versions Supported: Server v4.10+ is required, Self-Signed SSL Certificates are not supported unless the user installs the CA certificate on their device + +### Combatibility + - Mobile App v1.13+ is required for Mattermost Server v5.4+. + - Android operating system 7+ [is required by Google](https://android-developers.googleblog.com/2017/12/improving-app-security-and-performance.html). + +### Bug Fixes + - Fixed an issue where link previews and reactions weren't displayed when post metadata was disabled. + - Fixed an issue on Android where the app crashed when sharing multiple files. + +## 1.16.0 Release +- Release Date: February 16, 2019 +- Server Versions Supported: Server v4.10+ is required, Self-Signed SSL Certificates are not supported unless the user installs the CA certificate on their device + +### Combatibility + + - Mobile App v1.13+ is required for Mattermost Server v5.4+. + - Android operating system 7+ [is required by Google](https://android-developers.googleblog.com/2017/12/improving-app-security-and-performance.html). + +### Improvements + - Added the ability to remove own profile picture. + - Changed "X" to "Cancel" on Edit Profile page. + - Added support for relative permalinks. + +### Bug Fixes + - Fixed an issue where the iOS app did not wait until the on-demand VPN connection was established. (EMM Providers) + - Fixed an issue with a white screen caused by missing Russian translations. + - Fixed an issue where the iOS badge notification did not always clear. + - Fixed an issue where the thread view displayed a new message indicator. + - Fixed an issue where quick multiple taps on the file icon opened multiple file previews. + - Fixed an issue where the settings page did not show an option to join other teams. + - Fixed an issue where image previews didn't work after using Delete File Cache. + - Fixed an issue on Android where the notification trigger word modal title was "Send email notifications" instead of "Keywords". + - Fixed an issue where the Webhook icon was misaligned and bottom edges were cut off. + - Fixed an issue on Android where the user was not asked to authenticate to the app first when trying to share a photo, resulting in a white "Share modal" screen with a never-ending loading indicator. + - Fixed an issue on iOS where push notifications were not preserved when opening the app via the Mattermost icon. + +## 1.15.2 Release +- Release Date: January 16, 2019 +- Server Versions Supported: Server v4.10+ is required, Self-Signed SSL Certificates are not supported unless the user installs the CA certificate on their device + +### Combatibility + + - Mobile App v1.13+ is required for Mattermost Server v5.4+. + - Android operating system 7+ [is required by Google](https://android-developers.googleblog.com/2017/12/improving-app-security-and-performance.html). + +### Bug Fixes + + - Fixed an issue where the status changes for other users did not always stay current in the mobile app. + - Fixed an issue where a post did not fail properly when the user attempted to send the post while there was no network access. + - Fixed an issue where date separators did not update when changing timezones. + - Fixed an issue where the Favorites section did not clear from a users's channel drawer. + - Removed an extra divider below "Edit Channel" of Direct Message Channel Info. + - Fixed an issue where a user was not returned to previously viewed channel after viewing and then closing an archived channel. + - Fixed an issue where a quick double tap on switch of Channel Info created and extra on/off state. + - Fixed an issue where iOS long press menu didn't have rounded corners. + +## 1.15.1 Release +- Release Date: December 28, 2018 +- Server Versions Supported: Server v4.10+ is required, Self-Signed SSL Certificates are not supported unless the user installs the CA certificate on their device + +### Combatibility + + - Mobile App v1.13+ is required for Mattermost Server v5.4+. + - Android operating system 7+ [is required by Google](https://android-developers.googleblog.com/2017/12/improving-app-security-and-performance.html). + +### Bug Fixes + - Fixed an issue preventing some users from logging in using OKTA. + +## 1.15.0 Release +- Release Date: December 16, 2018 +- Server Versions Supported: Server v4.10+ is required, Self-Signed SSL Certificates are not supported unless the user installs the CA certificate on their device + +### Combatibility + + - Mobile App v1.13+ is required for Mattermost Server v5.4+. + - Android operating system 7+ [is required by Google](https://android-developers.googleblog.com/2017/12/improving-app-security-and-performance.html). + +### Highlights + - Added mention and reply mention highlighting. + - Added a sliding animation for the reaction list. + - Added support for pinned posts. + - Added support for jumbo emojis. + - Added support for interactive dialogs. + - Improved UI for the long press menu and emoji reaction viewer. + +### Improvements + - Added the ability to include custom headers with requests for custom builds. + - Push Notifications that are grouped by channels are cleared once the channel is read. +- Improved auto-reconnect when unable to reach the server. + - Added support for changing the mobile client status to offline when the app loses connection. + - Added 'View Members' button to archived channels. + - Added support on iOS for keeping the postlist in place without scrolling when new content is available. + +### Bug Fixes + - Fixed an issue where clicking on a file did not show downloading progress. + - Fixed an issue on Android where on fresh install the share extension would not properly show available channels. + - Fixed an issue where recently archived channels remained in in: autocomplete when they had been archived. + - Fixed an issue where text should render when no actual custom emoji matched the named emoji pattern. + - Fixed an issue on iOS where text got cut-off after replying to a message. + - Fixed an issue where search modifier for channels was showing Direct Messages without usernames. + - Fixed an issue where "Close Channel" did not work properly when viewing two archived channels in a row. + - Fixed an issue with "Critical Error" screen when trying to upload certain file types from "+" to the left of message input box. + +## 1.14.0 Release +- Release Date: November 16, 2018 +- Server Versions Supported: Server v4.10+ is required, Self-Signed SSL Certificates are not supported unless the user installs the CA certificate on their device + +**Combatibility Note: Mobile App v1.13+ is required for Mattermost Server v5.4+** + +### Bug Fixes +- Fixed an issue where the Android app did not allow establishing a network connection with any server that used a self-signed certificate that had the CA certificate user installed on the device. +- Removed "Copy Post" option on long-press message menu for posts without text. +- Fixed an issue where the "Search Results" header was not fully scrolled to top on search "from:username". +- Fixed an issue where channel names truncated at fewer characters than necessary. +- Fixed an issue where the same uploaded photo generated a different file size. +- Fixed an issue where the "(you)" was not displayed to the right of a user's name in the channel drawer when a user opened a Direct Message channel with themself. +- Fixed an issue where a dark theme set from webapp broke mobile display. +- Fixed an issue where channel drawer transition sometimes lagged. +- Fixed an issue where sending photos to Mattermost created large files. +- Fixed an issue where the apps showed "Select a Team" screen when opened. +- Fixed an issue where at-mention, emoji, and slash command autocompletes had a double top border. +- Fixed an issue where the drawer was unable to close when showing the team list. +- Fixed an issue where team sidebar showed + sign even without more teams to join. + ## 1.13.1 Release - Release Date: October 18, 2018 diff --git a/Makefile b/Makefile index 3acfed81d9f..0177bf25bec 100644 --- a/Makefile +++ b/Makefile @@ -2,7 +2,7 @@ .PHONY: check-style .PHONY: start stop .PHONY: run run-ios run-android -.PHONY: build build-ios build-android unsigned-ios unsigned-android +.PHONY: build build-ios build-android unsigned-ios unsigned-android ios-sim-x86_64 .PHONY: build-pr can-build-pr prepare-pr .PHONY: test help @@ -10,6 +10,7 @@ POD := $(shell which pod 2> /dev/null) OS := $(shell sh -c 'uname -s 2>/dev/null') BASE_ASSETS = $(shell find assets/base -type d) $(shell find assets/base -type f -name '*') OVERRIDE_ASSETS = $(shell find assets/override -type d 2> /dev/null) $(shell find assets/override -type f -name '*' 2> /dev/null) +MM_UTILITIES_DIR = ../mattermost-utilities node_modules: package.json @if ! [ $(shell which npm 2> /dev/null) ]; then \ @@ -75,6 +76,10 @@ post-install: @# Need to copy custom RNDocumentPicker.m that implements direct access to the document picker in iOS @cp ./native_modules/RNDocumentPicker.m node_modules/react-native-document-picker/ios/RNDocumentPicker/RNDocumentPicker.m + @# Need to copy custom RNCWebViewManager.java and RNCWEKWebView.m that implements IWA support for the WebView to avoid forking the lib + @cp ./native_modules/RNCWebViewManager.java node_modules/react-native-webview/android/src/main/java/com/reactnativecommunity/webview/RNCWebViewManager.java + @cp ./native_modules/RNCWKWebView.m node_modules/react-native-webview/ios/RNCWKWebView.m + @rm -f node_modules/intl/.babelrc @# Hack to get react-intl and its dependencies to work with react-native @# Based off of https://github.com/este/este/blob/master/gulp/native-fix.js @@ -91,21 +96,10 @@ post-install: @sed -i'' -e 's|transform: \[{scaleY: -1}\],|...Platform.select({android: {transform: \[{perspective: 1}, {scaleY: -1}\]}, ios: {transform: \[{scaleY: -1}\]}}),|g' node_modules/react-native/Libraries/Lists/VirtualizedList.js start: | pre-run ## Starts the React Native packager server - @if [ $(shell ps -ef | grep -i "cli.js start" | grep -civ grep) -eq 0 ]; then \ - echo Starting React Native packager server; \ - npm start; \ - else \ - echo React Native packager server already running; \ - fi + $(call start_packager) stop: ## Stops the React Native packager server - @echo Stopping React Native packager server - @if [ $(shell ps -ef | grep -i "cli.js start" | grep -civ grep) -eq 1 ]; then \ - ps -ef | grep -i "cli.js start" | grep -iv grep | awk '{print $$2}' | xargs kill -9; \ - echo React Native packager server stopped; \ - else \ - echo No React Native packager server running; \ - fi + $(call stop_packager) check-device-ios: @if ! [ $(shell which xcodebuild) ]; then \ @@ -181,68 +175,61 @@ run-android: | check-device-android pre-run prepare-android-build ## Runs the ap fi build: | stop pre-build check-style ## Builds the app for Android & iOS - @if [ $(shell ps -ef | grep -i "cli.js start" | grep -civ grep) -eq 0 ]; then \ - echo Starting React Native packager server; \ - npm start & echo; \ - fi + $(call start_packager) @echo "Building App" @cd fastlane && BABEL_ENV=production NODE_ENV=production bundle exec fastlane build - @ps -ef | grep -i "cli.js start" | grep -iv grep | awk '{print $$2}' | xargs kill -9 + $(call stop_packager) build-ios: | stop pre-build check-style ## Builds the iOS app - @if [ $(shell ps -ef | grep -i "cli.js start" | grep -civ grep) -eq 0 ]; then \ - echo Starting React Native packager server; \ - npm start & echo; \ - fi + $(call start_packager) @echo "Building iOS app" @cd fastlane && BABEL_ENV=production NODE_ENV=production bundle exec fastlane ios build - @ps -ef | grep -i "cli.js start" | grep -iv grep | awk '{print $$2}' | xargs kill -9 + $(call stop_packager) build-android: | stop pre-build check-style prepare-android-build ## Build the Android app - @if [ $(shell ps -ef | grep -i "cli.js start" | grep -civ grep) -eq 0 ]; then \ - echo Starting React Native packager server; \ - npm start & echo; \ - fi + $(call start_packager) @echo "Building Android app" @cd fastlane && BABEL_ENV=production NODE_ENV=production bundle exec fastlane android build - @ps -ef | grep -i "cli.js start" | grep -iv grep | awk '{print $$2}' | xargs kill -9 + $(call stop_packager) unsigned-ios: stop pre-build check-style ## Build an unsigned version of the iOS app - @if [ $(shell ps -ef | grep -i "cli.js start" | grep -civ grep) -eq 0 ]; then \ - echo Starting React Native packager server; \ - npm start & echo; \ - fi + $(call start_packager) @echo "Building unsigned iOS app" @cd fastlane && NODE_ENV=production bundle exec fastlane ios unsigned @mkdir -p build-ios - @cd ios/ && xcodebuild -workspace Mattermost.xcworkspace/ -scheme Mattermost -sdk iphoneos -configuration Relase -parallelizeTargets -resultBundlePath ../build-ios/result -derivedDataPath ../build-ios/ CODE_SIGN_IDENTITY="" CODE_SIGNING_REQUIRED=NO + @cd ios/ && xcodebuild -workspace Mattermost.xcworkspace/ -scheme Mattermost -sdk iphoneos -configuration Release -parallelizeTargets -resultBundlePath ../build-ios/result -derivedDataPath ../build-ios/ CODE_SIGN_IDENTITY="" CODE_SIGNING_REQUIRED=NO @cd build-ios/ && mkdir -p Payload && cp -R Build/Products/Release-iphoneos/Mattermost.app Payload/ && zip -r Mattermost-unsigned.ipa Payload/ @mv build-ios/Mattermost-unsigned.ipa . @rm -rf build-ios/ - @ps -ef | grep -i "cli.js start" | grep -iv grep | awk '{print $$2}' | xargs kill -9 + $(call stop_packager) + +ios-sim-x86_64: stop pre-build check-style ## Build an unsigned x86_64 version of the iOS app for iPhone simulator + $(call start_packager) + @echo "Building unsigned x86_64 iOS app for iPhone simulator" + @cd fastlane && NODE_ENV=production bundle exec fastlane ios unsigned + @mkdir -p build-ios + @cd ios/ && xcodebuild -workspace Mattermost.xcworkspace/ -scheme Mattermost -arch x86_64 -sdk iphonesimulator -configuration Release -parallelizeTargets -resultBundlePath ../build-ios/result -derivedDataPath ../build-ios/ ENABLE_BITCODE=NO CODE_SIGN_IDENTITY="" CODE_SIGNING_REQUIRED=NO ENABLE_BITCODE=NO + @cd build-ios/Build/Products/Release-iphonesimulator/ && zip -r Mattermost-simulator-x86_64.app.zip Mattermost.app/ + @mv build-ios/Build/Products/Release-iphonesimulator/Mattermost-simulator-x86_64.app.zip . + @rm -rf build-ios/ + $(call stop_packager) unsigned-android: stop pre-build check-style prepare-android-build ## Build an unsigned version of the Android app - @if [ $(shell ps -ef | grep -i "cli.js start" | grep -civ grep) -eq 0 ]; then \ - echo Starting React Native packager server; \ - npm start & echo; \ - fi + $(call start_packager) @echo "Building unsigned Android app" @cd fastlane && NODE_ENV=production bundle exec fastlane android unsigned @mv android/app/build/outputs/apk/unsigned/app-unsigned-unsigned.apk ./Mattermost-unsigned.apk - @ps -ef | grep -i "cli.js start" | grep -iv grep | awk '{print $$2}' | xargs kill -9 + $(call stop_packager) test: | pre-run check-style ## Runs tests @npm test build-pr: | can-build-pr stop pre-build check-style ## Build a PR from the mattermost-mobile repo - @if [ $(shell ps -ef | grep -i "cli.js start" | grep -civ grep) -eq 0 ]; then \ - echo Starting React Native packager server; \ - npm start & echo; \ - fi + $(call start_packager) @echo "Building App from PR ${PR_ID}" @cd fastlane && BABEL_ENV=production NODE_ENV=production bundle exec fastlane build_pr pr:PR-${PR_ID} - @ps -ef | grep -i "cli.js start" | grep -iv grep | awk '{print $$2}' | xargs kill -9 + $(call stop_packager) can-build-pr: @if [ -z ${PR_ID} ]; then \ @@ -250,6 +237,30 @@ can-build-pr: exit 1; \ fi +i18n-extract: ## Extract strings for translation from the source code + @[[ -d $(MM_UTILITIES_DIR) ]] || echo "You must clone github.com/mattermost/mattermost-utilities repo in .. to use this command" + @[[ -d $(MM_UTILITIES_DIR) ]] && cd $(MM_UTILITIES_DIR) && npm install && npm run babel && node mmjstool/build/index.js i18n extract-mobile + + ## Help documentation https://marmelab.com/blog/2016/02/29/auto-documented-makefile.html help: @grep -E '^[a-zA-Z_-]+:.*?## .*$$' $(MAKEFILE_LIST) | sort | awk 'BEGIN {FS = ":.*?## "}; {printf "\033[36m%-30s\033[0m %s\n", $$1, $$2}' + +define start_packager + @if [ $(shell ps -ef | grep -i "cli.js start" | grep -civ grep) -eq 0 ]; then \ + echo Starting React Native packager server; \ + npm start & echo; \ + else \ + echo React Native packager server already running; \ + fi +endef + +define stop_packager + @echo Stopping React Native packager server + @if [ $(shell ps -ef | grep -i "cli.js start" | grep -civ grep) -eq 1 ]; then \ + ps -ef | grep -i "cli.js start" | grep -iv grep | awk '{print $$2}' | xargs kill -9; \ + echo React Native packager server stopped; \ + else \ + echo No React Native packager server running; \ + fi +endef diff --git a/NOTICE.txt b/NOTICE.txt index 766baf1a310..8a18237520d 100644 --- a/NOTICE.txt +++ b/NOTICE.txt @@ -20,7 +20,7 @@ Provides polyfills necessary for a full ES2015+ environment MIT License -Copyright (c) 2014-2018 Sebastian McKenzie and other contributors +Copyright (c) 2014-present Sebastian McKenzie and other contributors Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the @@ -56,7 +56,7 @@ babel's modular runtime helpers MIT License -Copyright (c) 2014-2018 Sebastian McKenzie and other contributors +Copyright (c) 2014-present Sebastian McKenzie and other contributors Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the @@ -310,6 +310,42 @@ CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. --- +## emoji-regex + +This product contains 'emoji-regex' by Mathias Bynens. + +A regular expression to match all Emoji-only symbols as per the Unicode Standard. + +* HOMEPAGE: + * https://mths.be/emoji-regex + +* LICENSE: MIT + +MIT License + +Copyright Mathias Bynens + +Permission is hereby granted, free of charge, to any person obtaining +a copy of this software and associated documentation files (the +"Software"), to deal in the Software without restriction, including +without limitation the rights to use, copy, modify, merge, publish, +distribute, sublicense, and/or sell copies of the Software, and to +permit persons to whom the Software is furnished to do so, subject to +the following conditions: + +The above copyright notice and this permission notice shall be +included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND +NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE +LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION +OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION +WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +--- + ## fuse.js This product contains 'fuse.js' by Kirollos Risk. @@ -641,7 +677,7 @@ SOFTWARE. ## jsc-android -This product contains 'jsc-android' by React Community. +This product contains 'jsc-android' by React Native Community. Pre-build version of JavaScriptCore to be used by React Native apps @@ -1431,45 +1467,55 @@ SOFTWARE. --- -## react-native-drawer-layout +## react-native-exception-handler -This product contains a modified version of 'react-native-drawer-layout' by Brent Vatne. +This product contains 'react-native-exception-handler' by master-atul. -A platform-agnostic drawer layout. Pure JavaScript implementation on iOS and native implementation on Android. Why? Because the drawer layout is a useful component regardless of the platform! And if you can use it without changing any code, that's perfect +A react native module that lets you to register a global error handler that can capture fatal/non fatal uncaught exceptions. * HOMEPAGE: - * https://github.com/react-native-community/react-native-drawer-layout#readme + * https://github.com/master-atul/react-native-exception-handler * LICENSE: MIT -Note: An original license file for this dependency is not available. We determined the type of license based on the package registry entry for this project. The following text has been prepared using a template from the SPDX Workgroup (https://spdx.org) for this type of license. - -MIT License +The MIT License (MIT) -Copyright (c) 2018 Brent Vatne +Copyright (c) 2017 Atul -Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: -The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. --- -## react-native-exception-handler +## react-native-gesture-handler -This product contains 'react-native-exception-handler' by master-atul. +This product contains 'react-native-gesture-handler' by Krzysztof Magiera. -A react native module that lets you to register a global error handler that can capture fatal/non fatal uncaught exceptions. +Experimental implementation of a new declarative API for gesture handling in react-native * HOMEPAGE: - * https://github.com/master-atul/react-native-exception-handler + * https://github.com/kmagiera/react-native-gesture-handler#readme * LICENSE: MIT The MIT License (MIT) -Copyright (c) 2017 Atul +Copyright (c) 2016 Krzysztof Magiera Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal @@ -1624,10 +1670,10 @@ SOFTWARE. This product contains 'react-native-linear-gradient' by Brent Vatne. -A element for react-native +A element for React Native * HOMEPAGE: - * https://github.com/brentvatne/react-native-linear-gradient#readme + * https://github.com/react-native-community/react-native-linear-gradient#readme * LICENSE: MIT @@ -1676,7 +1722,7 @@ THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH RE ## react-native-navigation -This product contains 'react-native-navigation' by Tal Kol. +This product contains a modified version of 'react-native-navigation' by Daniel Zlotin. React Native Navigation - truly native navigation for iOS and Android @@ -1685,26 +1731,27 @@ React Native Navigation - truly native navigation for iOS and Android * LICENSE: MIT -The MIT License (MIT) +MIT License -Copyright (c) Wix.com +Copyright (c) 2016 Wix.com -Permission is hereby granted, free of charge, to any person obtaining a copy of -this software and associated documentation files (the "Software"), to deal in -the Software without restriction, including without limitation the rights to -use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of -the Software, and to permit persons to whom the Software is furnished to do so, -subject to the following conditions: +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS -FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR -COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER -IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN -CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. --- @@ -1994,7 +2041,7 @@ Note: An original license file for this dependency is not available. We determin MIT License -Copyright (c) 2018 Brent Vatne +Copyright (c) 2019 Brent Vatne Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: @@ -2011,7 +2058,7 @@ This product contains 'react-native-svg' by React Native Community. SVG library for react-native * HOMEPAGE: - * https://github.com/magicismight/react-native-svg#readme + * https://github.com/react-native-community/react-native-svg#readme * LICENSE: MIT @@ -2039,92 +2086,55 @@ SOFTWARE. --- -## react-native-tableview - -This product contains 'react-native-tableview' by Pavlo Aksonov. - -Native iOS TableView wrapper for React Native - -* HOMEPAGE: - * https://github.com/aksonov/react-native-tableview#readme - -* LICENSE: BSD-2-Clause - -Copyright (c) 2015, aksonov -All rights reserved. - -Redistribution and use in source and binary forms, with or without -modification, are permitted provided that the following conditions are met: - -* Redistributions of source code must retain the above copyright notice, this - list of conditions and the following disclaimer. - -* Redistributions in binary form must reproduce the above copyright notice, - this list of conditions and the following disclaimer in the documentation - and/or other materials provided with the distribution. - -THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" -AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE -IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE -DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE -FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL -DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER -CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, -OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - ---- - -## react-native-tooltip +## react-native-vector-icons -This product contains 'react-native-tooltip' by Chirag Jain. +This product contains 'react-native-vector-icons' by Joel Arvidsson. -A react-native wrapper for showing tooltips +Customizable Icons for React Native with support for NavBar/TabBar/ToolbarAndroid, image source and full styling. * HOMEPAGE: - * https://github.com/chirag04/react-native-tooltip#readme + * https://github.com/oblador/react-native-vector-icons * LICENSE: MIT -The MIT License (MIT) +The MIT License (MIT) -Copyright (c) 2015-2016 Chirag Jain +Copyright (c) 2015 Joel Arvidsson -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. --- -## react-native-vector-icons +## react-native-video -This product contains 'react-native-vector-icons' by Joel Arvidsson. +This product contains 'react-native-video' by Brent Vatne. -Customizable Icons for React Native with support for NavBar/TabBar/ToolbarAndroid, image source and full styling. +A