cognovi-ai / the-cdj

The Cognitive Distortion Journal (CDJ) is a smart journaling tool that helps remedy distorted thinking. It can feel impossible to follow the CBT technique of labeling and reframing distorted thinking when you've been thinking this way your whole life. The CDJ can help with that 🧠✨ -- v2 is in development!
https://thecdj.app
3 stars 0 forks source link

Remove Copyright duplication. #38

Closed hiyaryan closed 10 months ago

hiyaryan commented 10 months ago

This PR refactors the in line styles into new styled components that can be reused and easily traceable or updated.

The first PR removes the creates a new Copyright component in utils then removes duplicate definitions and imports the new component to be used in place.

hiyaryan commented 10 months ago

After reviewing the code there does not seem to be any apparent reason to remove the current inline styles other than for pragmatic purposes. These refactors could be incorporated if they were simple to apply. Aside from a few components with full styles applied using sx, such as TitleStacked and TitleUnstacked on the nav bar, most other components use sx as a means to apply reactive styles based on the view size with xs and md. These reactive inline styles seem appropriate as they are.

This PR now only refactors the Copyright component into a single component that can be shared across the app. Moving forward any style refactoring may be easier to implement as part of debugging overlapping styles. This can be done by isolating which styles are overriding which and pulling the styles up or into separate styled components. This should only be done as necessary and should not stop the app from making progress in other areas.