-
-
Notifications
You must be signed in to change notification settings - Fork 103
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
feat(platform): updated the empty state of dashboard #522
base: develop
Are you sure you want to change the base?
Conversation
PR Reviewer Guide 🔍Here are some key observations to aid the review process:
|
PR Code Suggestions ✨Explore these optional code suggestions:
|
ece87af
to
9ce357d
Compare
@@ -30,6 +31,7 @@ import { Projects } from '@/lib/api-functions/projects' | |||
|
|||
export default function Index(): JSX.Element { | |||
const [isSheetOpen, setIsSheetOpen] = useState<boolean>(false) | |||
const [isProjectEmpty, setIsProjectEmpty] = useState(true) |
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 think we won't need this state to track if the project list is empty or not. At line 35, we have the projects
state, which contains all the projects in the current workspace, so we can directly check on the size of this array, and conditionally render the UI.
User description
Description
Updated the empty state of the dashboard
Fixes #485
Mentions
@rajdip-b @poswalsameer
Screenshots of relevant screens
Developer's checklist
If changes are made in the code:
Documentation Update
PR Type
Enhancement
Description
isProjectEmpty
to determine if the project list is empty and update the UI accordingly.FolderSVG
and a new message encouraging users to start their first project.Changes walkthrough 📝
index.ts
Add FolderSVG to Dashboard SVG Exports
apps/platform/public/svg/dashboard/index.ts
FolderSVG
.FolderSVG
for use in other components.page.tsx
Update Dashboard Empty State with New Design
apps/platform/src/app/(main)/page.tsx
isProjectEmpty
to track if there are no projects.isProjectEmpty
.FolderSVG
in the empty state UI.