Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

light-dark-theme #15

Open
wants to merge 5 commits into
base: main
Choose a base branch
from
Open

Conversation

VedmaPranav
Copy link

This PR addresses Issue #3

Screenshot of the change:
Screenshot 2024-09-29 at 3 45 19 PM
Screenshot 2024-09-29 at 3 45 45 PM

Please feel free to suggest different styling, or any other feedback

Copy link
Collaborator

@arkid15r arkid15r left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey @VedmaPranav thanks for the PR!

Could you format code using make pre-commit and update the PR?

…theme

* 'main' of https://github.com/OWASP/Nest:
  Turn server tokens off
  Update issue index and Nginx config
  Update Nginx config
  Make some Repository fields optional
  Update Repository model
  Set up Sentry
  Update CI/CD
  Bump openai from 1.47.0 to 1.50.2 in /backend (OWASP#18)
  Bump pytest-cov from 4.1.0 to 5.0.0 in /backend (OWASP#16)
  Bump ruff from 0.5.7 to 0.6.8 in /backend (OWASP#17)
  Update issue-manager config
  Add issue manager
  Update dependabot config (docker)
  Update dependabot config
@VedmaPranav
Copy link
Author

@arkid15r I ran the pre-commit checks and updated the PR

@VedmaPranav
Copy link
Author

I mistakenly merged the main branch into this branch, I need to undo the merge.

@arkid15r
Copy link
Collaborator

arkid15r commented Oct 2, 2024

I mistakenly merged the main branch into this branch, I need to undo the merge.

So the pre-commit step of CI/CD is still failing. Could you address the pre-commit requirement issues?

Copy link
Collaborator

@arkid15r arkid15r left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@VedmaPranav thanks addressing the pre-commit issue

Please find my comment below and let me know your thoughts

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I noticed you didn't use the recommended bootstrap way to implement light/dark theme -- https://getbootstrap.com/docs/5.3/customize/color-modes/#enable-dark-mode

This looks like a more straight-forward solution and might not require a ton of extra CSS.
Do you think it's worth looking into the bootstrap recommended way and remove the extra complexity?

Copy link
Author

@VedmaPranav VedmaPranav Oct 5, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@ arkid15r I suggest a combination of Bootstrap and some custom CSS. Bootstrap recommended adding a dark theme to the HTML tag element; however, since the page class on the body element has a background color set to #f4f6fc we would see something as the following screenshot when dark theme is applied.
image
So, we must set the background color to None when the dark theme is applied. Also, the tooltips/github icons in the dark mode have a white border; we can remove this border through some custom CSS.

app.css file also contains some CSS related to the light-dark toggle slider. Switching this slider to a button or something similar will lose the aesthetic of a toggle slider.

The following is a screenshot of how the page would look with the changes I suggested. let me know your thoughts
image

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we use font-awesome icons for the style consistency?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

changed the icons to font-awesome icons

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants