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

[QF-625] introduced proxy to backend with redirect to auth #2191

Merged

Conversation

mohsinayoob
Copy link
Collaborator

@mohsinayoob mohsinayoob commented Aug 18, 2024

Summary

Fixes #QF-625

This PR introduces an HTTP proxy to forward all API requests from the frontend to the backend. It also adds a new page to handle redirectToken from the backend, allowing the frontend to obtain and set cookies for user authentication.

Type of change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • This change requires a documentation update

Test plan

This should state how this PR have been tested.

Checklist

  • My code follows the style guidelines of this project
  • I have performed a self-review of my code
  • My changes generate no new warnings
  • Any dependent changes have been merged and published in downstream modules
  • I have commented on my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • I have added tests that prove my fix is effective or that my feature works
  • New and existing unit tests pass locally with my changes

Screenshots or videos

Before After
IMAGE HERE IMAGE HERE

Copy link

vercel bot commented Aug 18, 2024

@mohsinayoob is attempting to deploy a commit to the Quran Team on Vercel.

A member of the Team first needs to authorize it.

Copy link

vercel bot commented Aug 19, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
quran-com ✅ Ready (Inspect) Visit Preview 💬 Add feedback Oct 7, 2024 11:02pm

src/pages/auth.tsx Outdated Show resolved Hide resolved
@osamasayed osamasayed merged commit 755e807 into quran:testing Oct 29, 2024
2 checks passed
osamasayed added a commit that referenced this pull request Dec 19, 2024
* Fix Tajweed Mushaf V4 (#2215)

fix font files

* QF-984 add support for multiple authors per learning plan (#2217)

* QF-984 add support for multiple authors per learning plan

* QF-985 Add multiple learning plan editors (#2218)

* Update localized Surah names (#2197)

* Fix duplicated translations languge name (#2198)

* Update Urdu Surah names (#2202)

* QF-1065 Add MS locale support (#2222)

Add MS locale support

* fix pages sidebar for the tajweed mushaf (#2212)

Co-authored-by: Ahmed Hussein <ahmed_hussein.dev@outlook.com>

* QF-985 allow more than 3 editors

* QF-1056 disable auto-translate for media generator content (#2220)

* QF-986 Add the ability to embed iframes in markdown (#2219)

* Add the ability to embed iframes in markdown

* Fix TS issue

* Fix TS issue

* Fix TS issue

* Fix TS issue

* QF-986 allow Youtube embeddings

* QF-982 allow user to play audio on login page (#2225)

* [QF-625] introduced proxy to backend with redirect to auth (#2191)

* Feat: Request signature generation to interact with API gateway (#2226)

* introduced proxy to backend with redirect to auth

* feat: introduced signature generation for interecting with api gateway

* fix: added documentation and resolved some changes requested

* adds documentation

* fix: added comment to explain the purpose of [...path] file

* Fix linting issues

* fix: added support for content and auth service through API gateway

* fix: resolve build issue for static props building

* fix: fixed env var name

---------

Co-authored-by: Osama Sayed <toto777_90@hotmail.com>

* QF-1056 disable auto-translate for media generator content

* QF-982 allow user to play audio on login page

* QF-1112, QF-1111 update embedded iframe styling (#2229)

* Update mushaf pages (#2230)

* QF-985 Add multiple learning plan editors

* QF-984 add support for multiple authors per learning plan

* Update localized Surah names

* Add MS locale support

* fix: added env in package.json to use it on build time (#2227)

* QF-986 allow Youtube embeddings

* Add the ability to embed iframes in markdown

* Fix TS issue

* Fix TS issue

* Fix TS issue

* Fix TS issue

* QF-1112, QF-1111 update embedded iframe styling

* [QF-1165]: resolves the build and redirect issue (#2233)

* fix: resolves the build and redirect issue

* Fix cyclic dependency issue

* fix TS issue

---------

Co-authored-by: Osama Sayed <toto777_90@hotmail.com>

* Add clarity to security headers

* fix: base url for auth page issue (#2234)

* fix: fixed undefined issue for unapproved translations (#2231)

* Fix: reoslves undefined and patch requests issue (#2235)

* fix: add patch in signature gen to use body

* fix: undifend issue in selected translation

* QF-1105 remove hiring footer section (#2232)

* [QF-625] introduced proxy to backend with redirect to auth (#2191)

* Feat: Request signature generation to interact with API gateway (#2226)

* introduced proxy to backend with redirect to auth

* feat: introduced signature generation for interecting with api gateway

* fix: added documentation and resolved some changes requested

* adds documentation

* fix: added comment to explain the purpose of [...path] file

* Fix linting issues

* fix: added support for content and auth service through API gateway

* fix: resolve build issue for static props building

* fix: fixed env var name

---------

Co-authored-by: Osama Sayed <toto777_90@hotmail.com>

* fix: added env in package.json to use it on build time (#2227)

* [QF-1165]: resolves the build and redirect issue (#2233)

* fix: resolves the build and redirect issue

* Fix cyclic dependency issue

* fix TS issue

---------

Co-authored-by: Osama Sayed <toto777_90@hotmail.com>

* fix: base url for auth page issue (#2234)

* Fix: reoslves undefined and patch requests issue (#2235)

* fix: add patch in signature gen to use body

* fix: undifend issue in selected translation

* fix: added env in package.json to use it on build time (#2227)

* Updates

* QF-1214 change editors to contributors (#2244)

* QF-1214 change editors to contributors (#2244)

* QF-1188 Revert disabling wbw audio data (#2248)

* Revert disabling wbw audio data

* Fix audioUrl

* Sync locales

* Sync locales

* QF-1188 Revert disabling wbw audio data (#2248)

* Revert disabling wbw audio data

* Fix audioUrl

* Sync locales

* Sync locales

* Tajweed mushaf fixes 21 11 2024 (#2247)

* update page 202

* update page 310 and 395

* update page 303

* update page 400

* Tajweed mushaf fixes 21 11 2024 (#2247)

* update page 202

* update page 310 and 395

* update page 303

* update page 400

* Set maximum width for iframes (#2254)

* Set maximum width for iframes (#2254)

* Upgrade Next.js to V14 (#2194)

* Upgrade

* Update storybook

* Update @svgr/webpack

* Update vitest

* Update playwright

* Update Redux

* Update Husky

* Update Typescript

* Update types

* Fix Husky

* Remove next-transpile-modules

* Update next-translate

* Fix sitemap generation issue

* Update next-seo

* Update react-hotkeys-hook

* Update lint-staged

* Update Remotion

* Update postcss, sass and sass-loader

* Update @next/bundle-analyzer

* Fix video thumbnails

* Solve merge conflict changes

* Fix tests failing issue

* Upgrade Next.js to V14 (#2194)

* Upgrade

* Update storybook

* Update @svgr/webpack

* Update vitest

* Update playwright

* Update Redux

* Update Husky

* Update Typescript

* Update types

* Fix Husky

* Remove next-transpile-modules

* Update next-translate

* Fix sitemap generation issue

* Update next-seo

* Update react-hotkeys-hook

* Update lint-staged

* Update Remotion

* Update postcss, sass and sass-loader

* Update @next/bundle-analyzer

* Fix video thumbnails

* Solve merge conflict changes

* Fix tests failing issue

* fix: signature generation for Delete method with payload (#2255)

* fix page 3, 445, and 453 (#2258)

* fix page 3,445, and 453

* fix the ayah text on collection page (#2257)

* fix the ayah text on collection page

* QF-1426 wbw (#2261)

* Enable word by word for all users and enable it for reading view

* Always enable Ayah menu for reading view (#2262)

* fix: signature generation for Delete method with payload (#2255)

* QF-1426 wbw (#2261)

* Enable word by word for all users and enable it for reading view

* Always enable Ayah menu for reading view (#2262)

* QF-946 Update french locales (#2209)

* Update French locales

* Update French locales

* QF-946 Update french locales (#2209)

* Update French locales

* Update French locales

* Update locales and remove new label (#2264)

* Update locales and remove new label

* fix: site map generation (#2246)

fix: site map generation with tafsirs, reciters and courses after api gateway resolved

* QF-1453 Update API docs link (#2266)

Update API docs link

* sync locales

---------

Co-authored-by: Ahmed Hussein <ahmedhussein.developer@gmail.com>
Co-authored-by: Ahmed Hussein <ahmed_hussein.dev@outlook.com>
Co-authored-by: Hafiz Mohsin Ayoob <41894237+mohsinayoob@users.noreply.github.com>
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