* MM-24891 Allow permissions to have defaults set in case where roles not in state
* MM-24891 Add tests for haveIPermission
* MM-24891 Apply the defaults to more channel permission checks
Fixes crash on Android when attempting to redirect back to a read-only channel (default channel) after using the `/leave` command.
Also, enables official support of `leave` slash command. Added as auto-complete suggestion.
* Use cache only for http URIs
* Style fixes
* No need for cache prop
* Remove redundant absolute positioning
* Cap at two lines
Co-authored-by: Miguel Alatzar <this.migbot@gmail.com>
* MM-24061 Bring back channel sidebar hamburger icon for tablets
* Remove channel sidebar icon for iPads
iPads run with a "persistent" sidebar already.
* Better conditional logic from PR review + tests
* Test tidying from PR review
* Set rehydration values to true on clean up
* Remove extra line
* Update app/store/middlewares/helpers.js
Co-authored-by: Elias Nahum <nahumhbl@gmail.com>
* Fix setting of views.root.hydrationComplete
Co-authored-by: Miguel Alatzar <this.migbot@gmail.com>
Co-authored-by: Miguel Alatzar <migbot@users.noreply.github.com>
Co-authored-by: Elias Nahum <nahumhbl@gmail.com>
* Serialize/Deserialize state as string in store, instead of map
To see if this positively impacts performance lag issues (channel sidebar opening, etc.)
* Update app/store/mmkv_adapter.ts
Co-authored-by: Elias Nahum <nahumhbl@gmail.com>
* Update app/store/mmkv_adapter.ts
* Typescript fixes
Co-authored-by: Amit Uttam <changingrainbows@gmail.com>
Co-authored-by: Miguel Alatzar <migbot@users.noreply.github.com>
Co-authored-by: Elias Nahum <nahumhbl@gmail.com>
Co-authored-by: Miguel Alatzar <this.migbot@gmail.com>
* Enable ESLint no-unused-vars
* Use FastImage instead of Image
* Update fast-image patch to support multiple cookies
* Fix ESLint errors
* Have jest run timers for post_textbox tests
* Feedback review
* Update snapshots
* MM-24463 Run message retention cleanup off of pre-existing state
Instead of a reconstructed "zero" state.
Only posts in channels, searched posts and flag posts are recalculated (as per data retention policy, if applicable). The rest of state is cloned from existing state.
* Mark hydrationComplete only if _persist state is undefined
Co-authored-by: Elias Nahum <nahumhbl@gmail.com>
* MM-22089 set default prevent double tap to 1s
* Increase tap debounce delay for ChannelInfo modal action
Co-authored-by: Elias Nahum <nahumhbl@gmail.com>
Co-authored-by: Amit Uttam <changingrainbows@gmail.com>
* Set previous app version in redux store
* Handle setting previousVersion on login and clearing data
* Set previous version on logout instead
* Remove action arg
* Fix infinite loop retrieving post files
Right now if all the attachments of a post are removed the component
update code enters into an infinite loop becuase the comparison between
arrays always return false.
* Move all the code inside the file changing detector condition
Co-authored-by: Mario de Frutos <mario@defrutos.org>
* Fix Crash on iOS with EMM enabled
* Fix Android Passcode authentication
* Fix Login screen header when EMM does not allow other servers
Co-authored-by: Elias Nahum <nahumhbl@gmail.com>
* Patch react-native-image-picker to allow selecting video
* Improve patch
* Fix Attaching a Photo capture
Co-authored-by: Elias Nahum <nahumhbl@gmail.com>
* Remove redux-offline and configure redux-persist
* Fix typo
* Fix configure store
* Upgrade to redux-persist 6.0.0
* Add migration from redux-persist v4 to v6
* Replace AsyncStorage with MMKVStorage to boost storage speed
* Mock RNFastStorage
* Fix reactions test
* Fix clearing the store on logout
* Remove the need for LOGOUT_SUCCESS
* No need to pass persistConfig to middlewares()
* Remove unused imports
* Export connection
Accidentally removed this export.
* Add batch action name
Co-Authored-By: Elias Nahum <nahumhbl@gmail.com>
* Add batch action name
Co-Authored-By: Elias Nahum <nahumhbl@gmail.com>
* Add batch action name
Co-Authored-By: Elias Nahum <nahumhbl@gmail.com>
* Add batch action name
Co-Authored-By: Elias Nahum <nahumhbl@gmail.com>
* Fix delete post
* Fix leave channel
Co-authored-by: Elias Nahum <nahumhbl@gmail.com>