It seems we are moving towards a more generalized Note taking
application. I'd still like to use it for both Note taking and
Journaling. I'm not sure how to clearly show it is meant for both.
Folders for now can only be created under the root folder. I cannot seem
to figure out how to design a good interface for designing how to choose
the parent folder.
This adds a new 'Folders' screen which shows you all your folders and
lets you manage the notes inside them. It currently doesn't allow you to
add or remove Folders, though.
This nearly addresses #18
Now when adding/editing/removing a note, it gets modified from the
directory it was present in. There is no longer a just a plain list of
all notes, but always a tree of notes, which are inside Folders.
Now clicking on a Folder shows all the notes from that folder. You can
even modify the notes, but deleting and adding notes won't work
correctly right now.
This is just me experimenting with how the folder listing could look
like, and the different libraries I could use - For now I'm using the
https://github.com/ajilo297/flutter_tree_view library which I've forked
into this file, as it requires many many modifications to get it to how
I want it to work. Plus the library is really simple.
I'm add a different interface for viewing Notes, similar to card viewer,
and it'll be nice to have a distinction between Journal viewing and Note
Viewing. The biggest difference is that when viewing a Journal, there is
a timeline and you want to be able to easily move between Journal
entries. Whereas with notes, they aren't connected in any obvious way.
If it already existed we would give an error about it already existing,
but the user would have no recourse of action, apart from uninstall and
reinstalling the app.
It seems that in dark mode the text is not visible as the primary color
remains white. This is a bug in flutter.
https://github.com/flutter/flutter/issues/32180
Thanks to William Lim for reporting.
When configuring the Git Repo server, we could optionally track one folder
in the root git repo, instead of just the root folder. This was
specifically to address my use case where I have my journals in a
sub-directory. The setup screen was super ugly, though.
Since now I'm in the process of adding folder support because of #18, I
can remove this hack. It simplifies the code a lot.
This is part of a much larger commit of adding Folder support, but since
that seems to be touching way too many things. I rather just commit
these small functions, and rethink the entire design.
This is the first step to add Folder support. For now the backend
understands the concepts of Folders, but the JournalList just shows all
of the notes, regardless of the folder.
Related to issue #18