Giter Site home page Giter Site logo

bit-badger / myprayerjournal Goto Github PK

View Code? Open in Web Editor NEW
13.0 3.0 0.0 1.81 MB

Minimalist prayer journal to enhance your prayer life

Home Page: https://prayerjournal.me

License: MIT License

JavaScript 3.66% F# 94.62% PowerShell 0.16% CSS 0.96% Dockerfile 0.60%
prayer prayer-journal f-sharp fsharp giraffe htmx litedb

myprayerjournal's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

myprayerjournal's Issues

Requests Disappear when Prayed

On different devices, requests are disappearing rather than going to the bottom of the journal. I suspect this is due to time differences between the device and the server. Modify the web app to send the timestamp along with actions such as "Prayed" or "Updated", and use that instead of taking the value of "now" from the server.

Notes - sort and overflow

In v2, the notes display does not scroll; once notes fill the available space, that's all we get. Make that portion of the dialog scrollable.

Also, the notes are sorted oldest-to-newest; change that to newest-to-oldest.

Use FSharpLu.Json for API serialization

Newtonsoft.Json (AKA JSON.NET) handles Options by putting Some or None in a Case property, and the value in the Fields property. FSharpLu.Json renders null for None cases, and the actual value for the Some cases, making for a much more compact format that still ends up with the equivalent value in JavaScript.

Change the API to use FSharpLu.Json for serialization, and update the Vue code to no longer look for the Case and Fields properties.

Convert to htmx

A proof-of-concept with htmx proved quite successful. Modify the application to use Bootstrap 5 UI and htmx, using Giraffe's view engine to generate the HTML server-side.

Change "Dashboard" to "Journal"

Since praying through requests can be done from the main page, change it from "Dashboard" to "Journal". This will also set it up better when we add the "Answered" link.

Pass Time Zone in Header

The server calculates dates/times based on GMT. Modify the application to derive the user's time zone and pass it in a header that can be used to render dates/times in the user's local time zone.

Only return answered date for answered list

The page that displays answered requests only needs the date answered to display the page, and the "view full request" page loads the request from the server. So, we don't need to send the entire request history in the results used to display the answered requests page.

Update to Vue CLI 3.0

The new Vue CLI brings many upgrades; take the time to update the app for this new layout/configuration, and update the build process to utilize modern mode.

Sort by "show after" for non-immediate recurrence

Requests should be ordered by the max value between "last prayed on" (or last activity, if implemented before #34) and "show after"; this will put non-immediate recurrence requests below the immediate recurrence ones when they reappear on the journal.

(This is a regression with v3; v2 did this correctly.)

Convert to LiteDB

Modify the data store to use LiteDB; the current structure is several levels of overkill for the volume of data being processed.

Create a new "pray through" process

The current flow of praying through the journal is not as distraction-free as I had hoped. My vision is for a process that eliminates everything on the screen, and displays requests one-at-a-time. Requests can be marked as prayed, and also flagged for follow-up. The follow-up state should be scoped to the user's session, and should be cleared once any other action occurs with a request.

Snooze requests

Some prayer requests recur. An example would be prayer for a student to do well in their studies; over summer break, this request is not timely.

  • Allow requests to be "snoozed" to a later time
  • Provide a page similar to "Answered" where snoozed requests can be maintained
  • Modify the journal page to exclude snoozed requests until the time has passed

Maintain separate "last prayed" and "last activity" times

Separate out a "last prayed" date from the "last activity" date (though praying for a request would set both), and sort requests in the journal by last prayed. This will keep update actions from moving a request to the bottom of the journal.

Write a better answered request view

Currently, answered requests use the same "full request" view that active requests do. This is not terribly friendly for reviewing. Create a view that has both history and notes, with the final request text at the top, and the history/notes below, going from most recent to least recent. Provide a "jump to bottom" button/link to enable the user to easily read from beginning to end, instead of vice versa.

Request edit `trim` is janky

Instead of applying the trim attribute to the field, set an event to trim the contents on blur. This will keep one backspace from resulting in two characters being deleted.

Add "notes" ability

Sometimes a request doesn't change, but you want to record notes about the situation, what prompted you to pray, etc. Provide a way to do this.

Switch to Vuetify UI components

I have been somewhat dissatisfied with v2's user interface; switching to Vuetify, with its components, should be a better experience. Loading indicator and snackbar are the two biggest disappointments.

Update times on journal page

Currently, the journal relative times don't ever update unless the page is completely reloaded; figure out how to make it update every minute.

Update back end to .NET 5

.NET 5 was released earlier this week, and contains significant performance gains. Update the back end to use it.

Detect when the authorization token has expired

See if Auth0 has a "keep this going" request we can send behind the scenes. If we can't do that, display a message to the user that they need to reauthenticate before making any more changes.

Revisit API usage

Every time the journal page is loaded, the entire journal is reloaded from the server. This is unnecessary if it is not stale; implement a way to determine if this call should be made.

Specify prayer recurrence duration

There may be requests for which prayer is desired more frequently (in personal usage, these are the requests that would be the ones I'd want to pray for even if I only had a few minutes).

  • Allow requests to be marked as "priority"
  • Separate priority requests on the journal page

Authorization not refreshing

When returning to the site after being on it the previous day, it picks up as not being logged on (which is fine). After going through the log on process, everything comes up fine. However, ~30 seconds from that time, the menu changes back to the non-logged-on version. API calls still work, but something is switching isAuthenticated back to false.

I suspect the issue lies in the refreshTokens function.

Update to .NET 6

.NET 5 is not a long-term-support release, but .NET 6 is. Now that there is a go-live version of .NET 6, update the back end to use it.

Sort journal requests by "show after" date

Requests that are snoozed (#17) or have a non-immediate recurrence (#16) reappear at the top of the list, because the list is sorted by the last activity date. Instead, change this sort to the calculated "show after" date; this will be transparent for immediately-recurring requests, but will bring reappearing requests back into the journal below them.

Convert to Vue 3 / composition API

Development that occurs soon can use the @vue/composition-api package; if Vue v3 is available before this project is completed, go ahead and upgrade.

tryJournalById returns entire request

The Data.tryJournalById function (called by Handlers.Request.get) is returning the entire request, including notes and history, which it should not be doing - that's what Data.tryFullRequestById (called by Handlers.Request.getFull) is for. Modify it to return the request with empty history and notes arrays.

(This was broken in the v2 conversion between EF Core and RavenDB.)

Title not updated on dates when activity occurs

The "last activity [relative time]" has a title attribute, which should enable the user to hover over it to see the actual date/time. The displayed relative time is being updated as it should, but the actual date/time is not being updated when activity occurs on a request.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.