Commit Graph

6 Commits

Author SHA1 Message Date
Ryan Stelly
b78be9243d lint rule & autofix for "trailing comma" (#3299)
* (lint) MOB-1063 enforce trailing commas

* autofix trailing commas

* manually fix newly introduced maxlen violations

* add trailing comma convention to i18n build
2025-12-22 20:17:13 -06:00
Johannes Klein
1439c40c6a Upgrading the app to react-native 0.71.7 (#592)
* Changes in the unproblematic files

* Remove manually linked react-native-config

* Updates to files because of upgrade

* RN 71 and dependencies packages

* Update snapshot tests

* RN 71.1

* Fix missing jest mock

* RN 71.7

* Missing mock

* Fix errors with apisauce and axios

* Remove react-native-codegen direct dependency

* Code style
2023-04-25 17:18:24 +02:00
Amanda Bullington
a07ee979e6 Custom fonts (#192)
* Add Whitney fonts to project
* Use styled components to pass whitney as default font for all app text
* Add header component using Papyrus as default font
* Update realm and add custom font examples for Android

Co-authored-by: Ken-ichi Ueda <kenichi.ueda@gmail.com>
2022-10-20 15:23:10 -07:00
Amanda Bullington
e81894d406 Use authenticated queries for fetch/search requests (#195)
* Use authenticated query for search results
* Use search API for fetching places from Settings
* Use authenticated query for authorized applications
* Use authenticated query to fetch user.me
* Move fetch/search api calls into react query format, out of hooks
* Update with react query instead of hooks
* Fetch list of blocked and muted users with authenticated query
* Added Podfile postinstall block to get app running in a Simulator
* Use auth query in identify
* Upgrade Realm to 11.0.0-rc.0, most recent version that will work with RN 0.68.2
* Upgrade @realm/react library to 0.4.0; fixes initialization error on android due to importing realm
* Use authquery for explore provider
* ObsDetail wasn't showing the edit button for obs created while signed out
* simplified ObsEditHeader so it takes a full observation instead of relying
  on the ObsEditContext
* ObsEdit now accepts an obs UUID as a param and loads that if the context
  doesn't have a current obs
* null checks for API methods, mostly to prevent requests that won't work b/c
  of missing params

Co-authored-by: Ken-ichi Ueda <kenichi.ueda@gmail.com>
2022-10-19 13:01:04 -07:00
Amanda Bullington
f46d4086ad Save observations, photos, sounds in Realm for upload (#78)
* Break uploader into helper function; add bottom model for uploading from obs list

* Create mapping function for uploading observations to iNat

* Mark observations as uploaded when id is returned from server

* Format dates on obs list

* Save all obs locally before trying to upload

* Resize grouped photo gallery photos for upload

* Resize photos btw group photos screen and obs edit

* Get sound, photo, obs uploads saving to realm and uploading later

* ObsEdit progresses to next or prev screen after one obs is saved locally

* Format date in camera; use time observed to show new local obs in ObsList

* Remove time zone attribute, since this is handled by server

* Submit sound and photo uuids as the file name for sound/photo uploads

* Make obsSounds an array in case there are multiple sounds for upload

* Removing time synced from Photo model bc not sure it's necessary

* Save _synced_at and _created_at time for all remote obs

* Fix back button, obs edit

* Don't show obs edit for unuploaded obs

* Get rid of ObservationProvider, move useObservations hook

* Fix place name; add date/time and location to no evidence uploads

* Add species_guess to observation when taxon_id changes

* Format date from picker; use string for sending to server

* Styling cleanup with react-native-paper; make ObsEdit into section components

* Add vector icons to ios (for searchbar)

* Add empty text to CV suggestions

* Cleanup code for marking records synced & uploading to server

* Use placeholder icons on bottom tab bar

* Add icons to ObsList; fix grid view when photo === null

* Fix jest tests

* Simplify setting an identification in ObsEdit

* Move inline styles to separate files

* Display all relevant saved obs data on ObsDetails; function to check for camel or snake case attributes

* Move logic for creating new sound observation to model, not sound recorder

* Add android vector icons

* Move create obs and create with no evidence into Observation model

* Add mock for react-native-fs

* Show option to edit user obs in ObsDetail; fix captive/geoprivacy/date fields for uploaded obs

* Move obsPhoto creation and obs with obsPhoto creation into models

* Create obs with sound from Obs model

* Create multiple obs from gallery photos; move logic into model

* Pass observation to ObsDetails via navigation to avoid opening and closing realm twice

* Lint error fixes

* Fix jest tests

* Use icons on normal camera

* Use timestamps from gallery and camera for new observations

* Keep simplifying code

* Update version/build number; add key to info.plist for faster ios build

* Remove TranslatedHeadline component

* Move saveLocalObservation logic to model

* Move all FIELDS for api calls into models (except messages, which doesn't have a model yet)

* Only show upload UI if user is logged in

* Fix obs edit link so it works for both logged in and logged out users

* Bug fixes: get fields from models; addListener function in test

* Model code cleanup

* More code cleanup

* Remove unused imports
2022-05-10 14:41:31 -07:00
Yaron Budowski
4f855834cd Sign up / login flow - initial implementation 2021-12-13 15:34:13 +01:00