-
Notifications
You must be signed in to change notification settings - Fork 0
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
Installed MUI and display popup modal when shopping list is empty #25
Conversation
Visit the preview URL for this PR (updated for commit 09d1f89): https://tcl-76-smart-shopping-list--pr25-sm-eb-create-welcome-sg37cw5r.web.app (expires Sun, 15 Sep 2024 05:52:49 GMT) 🔥 via Firebase Hosting GitHub Action 🌎 Sign: 512b1a88be8ae05fd3e727b99332819df760271d |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I made sure MUI was installed, I thought that was the issue, but let me know if anyone else comes across this issue. |
Hi Marcos, the reason for only seeing the btn text, not the Tip information might be due to the dark mode you are using, let me see how to fix this.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks great! I was initially having trouble because I needed to npm i MUI. Everything works great!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Everything looks good after re-testing the code. Good work!
src/views/Modal.jsx
Outdated
fontSize: 20, | ||
}); | ||
|
||
export default function BasicModal({ dataEmpty }) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
suggestion ( non-blocking ): Adding this modal in is very nice! Something to consider for the future is to make it more extensible. For example, you could pass in props like header
, body
, and buttonText
and then use this throughout your codebase.
The changes look great! Well done! 👏 |
Description
This added an alert to the List page, for users without any items. The popup message alerts them to add items to the Manage List page, and includes a button to navigate them there. We installed the Material UI dependency and used their popup model, and we leveraged conditional rendering to determine when the popup model shows up.
Related Issue
Closes #8
Acceptance Criteria
Type of Changes
feature
Updates
After
Testing Steps / QA Criteria