I have encountered an issue with a modal that I am using on both the login and home pages of my website. The modal works perfectly on the home page, but it seems to malfunction on the login page where it is displayed within its designated component. If you'd like to see a visual representation of the issue, check out this GIF: Issue reproduction
Any suggestions on how to resolve this problem would be greatly appreciated.
The project's folder structure is as follows:
├── src
│ ├── styles
│ │ │ ├── globalstyles.tsx
│ │ │ ├── render-theme.tsx
│ │ │ ├── theme.ts
│ ├── components
│ │ ├── Modal
│ │ │ ├── index.tsx
│ │ │ ├── styles.ts
│ ├── pages
│ │ ├── Home
│ │ │ ├── index.tsx
│ │ │ ├── styles.ts
│ │ ├── Posts
│ │ │ ├── index.tsx
│ │ │ ├── styles.ts
In addition to being used for login and post deletion functionalities, the modal component will also be utilized for editing posts:
Modal code:
(Code snippet provided in original text)
Modal Styles code:
(Code snippet provided in original text)
Globalstyle code:
(Code snippet provided in original text)