SamAmco / track-and-graph

An android app for tracking personal data and creating custom graphs
GNU General Public License v3.0
428 stars 39 forks source link

New forms for tracker and graph creation #262

Closed PropellantDyke closed 1 month ago

PropellantDyke commented 6 months ago

This PR continue #261

SamAmco commented 6 months ago

Sorry for being slow on this. I just want to re-assure you that I know this PR is here. I just need to find time to review it.

PropellantDyke commented 5 months ago

Hi! The big parts are done, but there is still a lot of small adjustment to do:

There is also some bigger changes to make, like breaking some forms into multiple smaller one, which is a classic approach to reduce the cognitive load when filling a form. But that's an another topic :)

Here is some screenshot of the actual result:

New tracker New tracker, expended New tracker, expended
SamAmco commented 2 months ago

Hi @PropellantDyke

Today I found time to check out this branch and take a look at the new UI and the code. I apologise again for how long it's taken me, life has been pretty hectic lately.

First I'd just like to thank you again for your contribution. The code and the UI are looking brilliant in this branch, really well done! I think most people will be pleased to see the new cleaned up look when it's ready.

I hope you haven't given up working on it as I know you still had some improvements you wanted to make in your last post there. I would agree with most of that stuff and I do notice the odd component that looks a bit out of place or themed in a bit of an "old school" way compared to your new UI. There are also a few things I would add though:

If you get stuck with anything let me know and I might be able to just do it my self. Let me know as and when you want to merge . There are some things that would probably be good to address directly in this PR before merging, but there's also plenty of stuff I'm happy for you to put in a new PR. Stuff like aligning the dimens and colours files would be good to fix in this PR. Other than that I'm happy to merge.

Once again thanks for all your work and sorry for the slow response time. I hope you're still interested in rounding this off.

PropellantDyke commented 1 month ago

Thanks a lot for your feedback!!

My goal for this PR was to polish the UX of AddTracker and AddGraph form, while leaving intact the rest of the app. And then, in an another bunch of commits, make the whole app coherent. That's why I put effort to strictly separate new colors/widgets/radius from the the old ones, by using Form prefix. That way, I'm sure that I don't destroy something in an another page without knowing it. It also helps to ensure that I use a set a coherent functions and properties in the new code. But of course, this create code duplication and discrepancies in the app and this should be fixed before merging your 256_improved_trancker_creation_form to master. I hope it's okay for you, but let me know if you prefer a different approach.

Colors You are right about the blue that is out of nowhere. I just found it more appealing for dark mode, as tested with the mockup in my issue. And I admit that I've no clue about how was working the theme system, so thanks for the mini-tutorial! I've pushed a new commit where I've created a new FormTheme, derivated from TnGComposeTheme, and based a bit more on default colors.

Corners I've tried to follow what I see in most of the apps: buttons are 100% rounded, and fields got small rounded corners. In addition, when one or more fields are contained in a rounded box (like a section), I round the box a bit more so the circle center of the rounded corner of both parent and child (almost) match. Anyway, only 3 types of radius are needed for the new form, plus the older ones that are visible in the rest of the app until the new style is propagated everywhere. If old corner radius are still visible in the new forms, that's a bug or an unfinished work from me (like the "+" button to add a new graph line). If it's okay to keep separation between old and new code/theme for now, I don't see the need to modify the dimens.xml file.

Remember function I didn't know the existence of remember(), thanks for pointing that out :) I've fixed some of them. Some other are more complicated because apparently, remember() can't contain stringResource calls.

SamAmco commented 1 month ago

That all sounds very reasonable. Thanks for looking at those remember calls as well. I'm happy to merge this in then if that's how you'd like to proceed? I have also been doing a little work on master so i can merge that into the branch as well soon and then you can work off the latest if you branch back off of 256.

PropellantDyke commented 1 month ago

Perfect, you can merge it!

I will try to separate things in different PR now that the core of the new form is available in the branch.

SamAmco commented 1 month ago

Merged! .. I will merge master into this branch soon and let you know here when that's ready here.

SamAmco commented 1 month ago

Ok feature/256.. should now have the latest from rc-v4.0.0 so feel free to keep working off that.