quivr/frontend
Elazar Naaman c5157186e0
fix(frontend): Implement persistent dark mode setting and & Implement persistent dark mode setting (#2423)
# Description

Please include a summary of the changes and the related issue. Please
also include relevant motivation and context.

## Checklist before requesting a review

Please delete options that are not relevant.

- [x] My code follows the style guidelines of this project
- [x] I have performed a self-review of my code
- [x] I have commented hard-to-understand areas
- [x] I have ideally added tests that prove my fix is effective or that
my feature works
- [x] New and existing unit tests pass locally with my changes
- [x] Any dependent changes have been merged

## Screenshots (if appropriate):


<!--
ELLIPSIS_HIDDEN
-->


----

| <a href="https://ellipsis.dev" target="_blank"><img
src="https://avatars.githubusercontent.com/u/80834858?s=400&u=31e596315b0d8f7465b3ee670f25cea677299c96&v=4"
alt="Ellipsis" width="30px" height="30px"/></a> | 🚀 This PR
description was created by [Ellipsis](https://www.ellipsis.dev) for
commit bb45566f8a. |
|--------|--------|

### Summary:
This PR updates the `useLanguageHook` and `UserSettingsProvider`
functions to use the `shortName` of the selected language when changing
the language and to retrieve and store the dark mode setting from and to
local storage, respectively.

**Key points**:
- Updated `useLanguageHook` in
`/frontend/app/user/components/LanguageSelect/hooks/useLanguageHook.ts`
to use `shortName` of selected language when changing language.
- Updated `UserSettingsProvider` in
`/frontend/lib/context/UserSettingsProvider/User-settings.provider.tsx`
to retrieve dark mode setting from local storage.
- Updated listener for `change` event on `mediaQueryList` in
`UserSettingsProvider` to store updated dark mode setting in local
storage.


----
Generated with ❤️ by [ellipsis.dev](https://www.ellipsis.dev)



<!--
ELLIPSIS_HIDDEN
-->

---------

Co-authored-by: Zewed <dewez.antoine2@gmail.com>
2024-05-14 09:30:24 +02:00
..
app fix(frontend): Implement persistent dark mode setting and & Implement persistent dark mode setting (#2423) 2024-05-14 09:30:24 +02:00
e2e feat(frontend): Add Brain On Search Page (#2067) 2024-01-22 17:37:45 -08:00
lib fix(frontend): Implement persistent dark mode setting and & Implement persistent dark mode setting (#2423) 2024-05-14 09:30:24 +02:00
pages Update Sentry configuration and ignore file (#2250) 2024-02-23 16:15:39 -08:00
public [ImgBot] Optimize images (#2568) 2024-05-09 07:16:31 -07:00
services/analytics feat: 🎸 posthog (#1936) 2023-12-29 23:45:36 +01:00
styles feat(frontend): add notifications for document uploads (#2549) 2024-05-06 08:57:02 -07:00
.dockerignore feat: 🎸 docker (#1656) 2023-11-19 13:16:28 +01:00
.eslintrc.js fix(frontend): revamp quivr studio (#2274) 2024-02-28 16:42:14 -08:00
.gitignore fix: Update Sentry configuration to use NEXT_PUBLIC_SENTRY_DSN (#2254) 2024-02-23 18:12:50 -08:00
.lintstagedrc.js Devx/add linter rules (#331) 2023-06-15 11:52:46 +02:00
Dockerfile Add NEXT_PUBLIC_AUTH_MODES environment variable to Dockerfile and update useAuthModes hook 2024-05-04 15:21:52 +02:00
Dockerfile.dev docs(blog): updated 2023-09-21 21:14:01 +02:00
globals.css fix: 🐛📱 height now matches mobile height (#1323) 2023-10-04 12:04:57 +02:00
middleware.ts Devx/add linter rules (#331) 2023-06-15 11:52:46 +02:00
next-sitemap.config.js feat: 🎸 sitemap (#1483) 2023-10-24 22:21:12 +02:00
next.config.js feat(frontend): add notifications for document uploads (#2549) 2024-05-06 08:57:02 -07:00
package.json feat(analytics): added analytics page (#2416) 2024-04-10 02:20:21 -07:00
playwright.config.ts test: add e2e for crawling (#1288) 2023-09-29 13:15:37 +02:00
Porter.yaml feat(porter): Add Porter.yaml files for backend and frontend services 2024-04-25 10:51:10 +02:00
postcss.config.js Devx/add linter rules (#331) 2023-06-15 11:52:46 +02:00
README.md feat(api): new api init 2023-05-18 01:22:13 +02:00
sentry.client.config.ts fix: Update Sentry configuration to use NEXT_PUBLIC_SENTRY_DSN (#2254) 2024-02-23 18:12:50 -08:00
sentry.edge.config.ts fix: Update Sentry configuration to use NEXT_PUBLIC_SENTRY_DSN (#2254) 2024-02-23 18:12:50 -08:00
sentry.server.config.ts fix: Update Sentry configuration to use NEXT_PUBLIC_SENTRY_DSN (#2254) 2024-02-23 18:12:50 -08:00
tailwind.config.js feat: add chat view new design (#1897) 2023-12-14 16:22:09 +01:00
tsconfig.eslint.json Feat: chat name edit (#343) 2023-06-20 09:54:23 +02:00
tsconfig.json feat: 🎸 posthog (#1927) 2023-12-28 11:03:05 +01:00
vitest.config.ts feat: responsive sidebar (#1279) 2023-10-02 14:42:23 +02:00
vitest.setup.ts feat: responsive sidebar (#1279) 2023-10-02 14:42:23 +02:00
yarn.lock feat(analytics): added analytics page (#2416) 2024-04-10 02:20:21 -07:00

This is a Next.js project bootstrapped with create-next-app.

Getting Started

First, run the development server:

npm run dev
# or
yarn dev
# or
pnpm dev

Open http://localhost:3000 with your browser to see the result.

You can start editing the page by modifying app/page.tsx. The page auto-updates as you edit the file.

This project uses next/font to automatically optimize and load Inter, a custom Google Font.

Learn More

To learn more about Next.js, take a look at the following resources:

You can check out the Next.js GitHub repository - your feedback and contributions are welcome!

Deploy on Vercel

The easiest way to deploy your Next.js app is to use the Vercel Platform from the creators of Next.js.

Check out our Next.js deployment documentation for more details.