* Minimize the number of rerenders by splitting sheet logic into separate component
* Fix agree sheet
* Fix y offset for scrolling from notifications to activity item
* Add typescript parser and fix Flow errors in JS files
* Uninstall packages from react-native/eslint-config
* Fix all flow errors (or ignore them for unknowns
* Shows notice when user or obs is opted out of Community Taxon on ObsDetails
(closes#882)
* Unifies mapApiToRealm methods around a single interface
* Ensure that the remote obs used on ObsDetail is normalized to look like a
local obs
* Ensure some tests that use signIn() have isolated Realm instances
* Update current user's obs from ObsDetails (closes#1045)
* Fixed CC0 license display on ObsDetails (was not actually related to
updating the local copy of the obs
Syncing was broken when an unsynced obs was deleted
The main problem here was that MyObs state has a list of observations that
need upload, but since it was a plain array of Realm objects it crashed when
one of those objects was invalid, which happened after deletion. This fix
isn't great: it just makes it so the thing in state is a Realm.Results
object, which will update dynamically when its underlying data changes. We
could also JSONify what we have in state, but then you get into problems of
nested objects and deep JSONification.
Also
* Delete local obs if remote doesn't exist
* Bugfix: ObsDetail tried to mark non-existent remote obs as viewed
* Tried to handle react query retries better
* Bugfix: TaxonDetails was crashing if it received a null taxon
* Send lat and lng instead of latitude and longitude to the score_image
endpoint
* Show offline suggestions when you are offline
* Show notice when viewing offline suggestions
* Moved code unique to useOnlineSuggestions into that file
* Ensure we use a medium size image to get suggestions when dealing with
remote URLs
* More logging around React Query retries
* Use default retry logic for useAuthenticatedQuery
* Made a module-resolver shortcut for tests
* Move offline notice above top suggestion; hide when offlines exist but onlines do too
* Update to realm 12
* Remove unused mocks to fix some tests
* Fix test by unmocking ObsEditProvider
* Fix more tests by removing mocks/changing when tests write to realm
* Remove mocks on ObsEdit component test and fix accessibility labels
* Fix hooks tests with realm
* Set test path for realm; finish fixing tests
* Small tweak
* Upgrade realm/react library
* Migrate schema
* Simplify ObsEditProvider by moving functions into local state & calling reducer less frequently
* Fix delete all observations
* Fixes
* Move index selection to MediaViewer via params
* Access ObsEditContext on top level of ObsEdit and pass props
* Move context to top level screen components
* Fix tests
* Use waitFor to fix ObsDetails integration test
* Alphabetize props; remove realm check; refactor new Id method
---------
Co-authored-by: Ken-ichi Ueda <kenichi.ueda@gmail.com>
* Make minimum viable RemoteComment
* Minimum vialbe RemoteIdentification
* Minimum viable remote project, place, and messages
* Create minimum viable records for all remote factories
* Remove factories for local device data
* Minimum viable local taxon, comment, id
* Minimum viable for local observation photo (photo has no primary key)
* Minimum viable LocalUser
* Minimum viable record for LocalObservation
* Ensure layout of the PhotoCarousel photos doesn't change in delete mode
* Stop conflating screen-size layout differences with tablet layout differences
* Bugfix: deleting one photo in the StandardCamera removed all photos
* Animated rotation of rotatable elements on StandardCamera
* Ensure loading status shows while first photo is being taken
* Tried to remove some open handles and shore up some unhappy tests
* Refactor ObsStatus, add filled property
* Remove viewed prop from observation
* Update properties for ObsDetail mark viewed
* Use separate fields for comments and ids for ObsStatus
* Add hook for fetching updates
* Unit tests for the updates hook
* Unit tests for different paths for updating the realm observation when using the hook
* Update MyObservations.test.js
* Add integration test if updates has been called in my observations
* Update Podfile.lock
* Update observation to not viewed if the keys have not been initialized
* Add test case if observation fields are not initialized
* Add test case
* Refetch stale data on coming back from the background
* Subscribe to observation updates also in ObsDetail screen
This also invalidates and refetches the data after a successful mutation of the id or comment being viewed.
* Refetch observation updates data on sync button press
* Throw error in updates query
* Return refetch function from hook
* Add mock to ObsDetails
* Remove unused var
* Update useObservationsUpdates.test.js
* Reset realm viewed state to true ...
for all observations on app mount and coming to the foreground.
* Reorder function calls
* Change hook to use boolean as enabled param
* Create ObsDetails.test.js
* Update date handle tests to make sure Remote data classes have parseable date
* Add test case for comment and identification
* Update ObsDetails.test.js
* Also check for user in ObsDetails
* Refactored into separate hook for App.js
* Unit and integration test for new hook
* Rename const
* Rename field
* Rename field
* Export query key from hook
* Refactor true check
* Additional methods for obs being viewed or not
* Changed test description
* Add per_page to observations updated