Commit Graph

109 Commits

Author SHA1 Message Date
Brandon Presley 7928cab4c1 Swap to using MaterialCommunityIcons 2023-10-19 18:28:56 +13:00
Brandon Presley 12dfa923e5 Add delete button to edit set - 1.161 🚀 2023-10-19 17:58:34 +13:00
Brandon Presley a3b376badb Use events for gym set CRUD 2023-10-18 19:06:13 +13:00
Brandon Presley c88642b2ef Fix home page adding sets - 1.160 🚀 2023-10-18 10:45:40 +13:00
Brandon Presley 386a9a7bb2 Pass whole updated set instead of just its id
Since we already have the whole updated set,
might as well pass it around instead of
re-fetching it.
2023-08-29 11:25:05 +12:00
Brandon Presley 6b524dce34 Revert "Change way we detect set updates"
This reverts commit 185ebd1824.
2023-08-28 18:12:15 +12:00
Brandon Presley 185ebd1824 Change way we detect set updates
Every time we create/update/delete fire a DeviceEventEmitter
event for gym sets. Then we subscribe to the changes in relevant
components.

Also fixed flickering of "No data yet" on graphs page.
2023-08-24 17:30:57 +12:00
Brandon Presley dd609a20e5 Fix navigation after adding a set 2023-08-22 10:00:13 +12:00
Brandon Presley 672931746b Only reset SetList in certain situations
This reduces the jitter in the homepage
when you have scrolled down a significant
amount.

Related to #165. Still need to do other
list pages.
2023-08-22 09:49:56 +12:00
Brandon Presley 331597e3ee Add increment/decrement buttons to reps/weight - 1.148
Closes #164
2023-08-14 13:32:10 +12:00
Brandon Presley 44283fc990 Validate reps+weight on EditSet
Numbers shouldn't contain dashes, spaces or commas.
2023-08-12 15:22:00 +12:00
Brandon Presley 158dd61668 Prevent sets dissapearing after updating - 1.146
Previously we would always update the created
field by making a new Date object, even if
the user didn't pick a new date. On some
devices this might slightly change the time
of the day, meaning it jumps somewhere else
on the home page.
2023-07-27 13:31:50 +12:00
Brandon Presley e628d345ca Reduce escaping of characters 2023-07-23 14:52:22 +12:00
Brandon Presley 556347e632 Include date picker for new sets - 1.144
Not sure why I had this hidden,
probably made sense in the earlier
versions of this app.
2023-07-17 18:52:38 +12:00
Brandon Presley 3e41c3bbd8 Use outlined buttons instead of contained ones
I like them better! Ahahahahahahahahah
Bwahahahahahahahahahahahahahahahahahah
2023-07-17 16:24:09 +12:00
Brandon Presley a5b6673e9a Don't auto-focus weight when editing a set - 1.142
I find myself opening up a set often to
just read the fields rather than changing
anything.
It makes sense to auto-focus the name for
a brand new set, since it's required and
typically what you first fill out.
2023-06-29 16:31:15 +12:00
Brandon Presley 4303fe2cc4 Use deno fmt instead of prettier 2023-06-27 15:16:59 +12:00
Brandon Presley 288ae1ae0c Disable timers if rest time is set to zero - 1.134 2023-03-24 19:16:35 +13:00
Brandon 28ec021258 Fix copying sets - 1.117
Related to #143
2023-01-17 10:22:21 -07:00
Brandon Presley 467df629b0 Change edit headers to add when adding 2023-01-08 18:05:59 +13:00
Brandon Presley e7f85a9954 Add date/time picker to EditSet - 1.115 2023-01-08 18:02:17 +13:00
Brandon Presley 42912040ff Simplify getNow 2023-01-04 13:24:49 +13:00
Brandon Presley a2721e9f12 Use sqlite in Android code for alarm settings
Closes #129
2023-01-02 18:54:35 +13:00
Brandon Presley 5d9df37778 Organize imports 2023-01-01 15:20:56 +13:00
Brandon Presley 3ed2d4f0cd Never pass falsy value to date format
Closes #141

After adding TypeORM I had to remove the strict checking in TypeScript.
This leads to null errors such as this. Kind of annoying, but I think
the large reduction in code from adding TypeORM is worth it. We
shall see...
2022-12-30 13:30:13 +13:00
Brandon Presley 5115055280 Reword MassiveX as AppX 2022-12-29 13:57:19 +13:00
Brandon Presley 533b21a907 Remove csv import/export
This is replaced with the backup/restore feature in Settings page.

- Not sure anybody is using this besides me for testing purposes
- Backing up the entire SQLite database is faster than CSV conversion
- This prevents missing data and will work nicely with future plan
  changes

Closes #128
2022-12-08 14:51:34 +13:00
Brandon Presley 26e0391022 Add missing margin to save set button 2022-12-01 14:11:47 +13:00
Brandon Presley 521fa0e9d3 Remove margins from buttons
These were for my ios testing, which I might
add back in later.
2022-11-30 18:14:34 +13:00
Brandon Presley 1b1bb41ed7 Combine SetForm + EditSet
The abstraction here added more complexity than it saved.
2022-11-30 13:58:56 +13:00
Brandon Presley 8019df7418 Add some useCallbacks 2022-11-03 23:32:41 +13:00
Brandon Presley 29d14d74ff Fix rest timers for new sets from homepage 2022-11-03 22:16:18 +13:00
Brandon Presley 31f1528c35 Replace settings context with theme context
The settings context was having a big performance
impact on the app. We only truly need the theme + color
to be a global context.
2022-11-01 16:50:03 +13:00
Brandon Presley 49b5eb48c6 Refactor MassiveSnack
Instead of using a context for the whole app
use DeviceEventEmitter with root state.
This will probably improve performance,
since I think the react context was
re-rendering the entire DOM tree.
2022-11-01 15:55:37 +13:00
Brandon Presley bc7aca03e8 Remove semicolons from line endings 2022-10-31 17:22:08 +13:00
Brandon Presley b7f1c2192e Pause converting to typeorm due to odd error
ERROR  TypeError: Cannot read property 'getItem' of undefined

This error is located at:
    in FlatList (created by SetList)
    in RCTView (created by View)
    in View (created by Page)
    in Page (created by SetList)
    in SetList (created by SceneView)
...

I found an open issue on the react-native github which seems
related https://github.com/facebook/react-native/issues/31523
but after following all of their suggestions I still have the
same error. I tried:
- Removing @babel/plugin-proposal-class-properties & @babel/plugin-transform-flow-strip-types
- Adding @babel/plugin-transform-flow-strip-types
2022-10-31 13:20:36 +13:00
Brandon Presley e6dcd4a47e Use hermes engine
https://reactnative.dev/docs/hermes
2022-10-28 18:36:47 +13:00
Brandon Presley 859fa2a89f Add setting to disable sound on rest timers
Closes #50
2022-10-27 17:28:27 +13:00
Brandon Presley 80b1a1ef56 Fix single views for new custom headers 2022-10-23 19:13:58 +13:00
Brandon Presley b95024abe0 Fix rest timers for newly edited Workouts
Previously if you were to add a new workout, then
add a set for that workout immediately afterwards,
the rest timers would be the default 3:30.
Now, they are the actual value set when creating the
workout.
2022-10-21 18:39:06 +13:00
Brandon Presley 4d35d617e8 Change wording on new record notification 2022-10-16 14:37:31 +13:00
Brandon Presley 46f0875497 Create useSnackbar custom hook 2022-10-14 17:27:19 +13:00
Brandon Presley 228383ed23 Bottom align save button on set form 2022-10-13 16:32:12 +13:00
Brandon Presley 3cbabb723a Add sessions page
Related to #82
2022-10-05 23:38:52 +13:00
Brandon Presley b0b804eae1 Use react context for settings
Closes #81
2022-10-01 16:01:07 +13:00
Brandon Presley edf823ca8b Prevent title counting sets when we aren't predicting them 2022-10-01 15:35:20 +13:00
Brandon Presley 9d42760dff Rename some variables in EditSet
Not sure if I like the look of variables starting with
underscores. Perhaps the only use of this would be to prevent
editor warnings for unused variables.
2022-10-01 13:30:06 +13:00
Brandon Presley a20a0a1832 Add timer page
Closes #54
2022-09-26 14:38:25 +13:00
Brandon Presley 235b806eeb Fix counting current progress in a workout 2022-09-25 19:06:16 +13:00
Brandon Presley 71d223f0a1 Add current workout progress to title of set editing
Related to #48

Should be thoroughly tested before closing.
2022-09-24 19:09:58 +12:00