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

Epic 2 Foundational UI -- Profile Notifications/No Organizations Views #324

Merged
merged 24 commits into from
Feb 14, 2024

Conversation

joshua-rdrgz
Copy link
Collaborator

Sorry for the code bomb! This PR contains foundational UI components for building out Epic 2's UI, as well as the UI for the Profile page's "Notifications" view and "My Organizations" view when the user has no organizations.

Changes

Foundational UI components added:

  • Dialog (modals)
  • Form
  • Label
  • Input
  • Select
  • CreateOrganizationBtn: button component that activates a modal dialog containing the form for creating organizations.

Layout UI components added:

  • ProfileNotifications view for user's invitations to organizations
  • ProfileOrganizations view for viewing user's organizations.
  • Updated profile page base component to incorporate two new views.

Libraries Introduced

  • Radix UI -- open-source component library with unstyled components focused on ease of use and accessibility. More here: https://www.radix-ui.com/primitives
  • Shadcn/ui -- based foundational UI components off this copy/paste library (no dependency needed). Contains default styles that look amazing, and the library is based off Radix UI. I converted the Tailwind classes the library provides to CSS modules that fit with NPDC. More here: https://ui.shadcn.com/
  • Zod -- a library for TypeScript-first schema validations, used primarily for easy and effective form validation. More here: https://zod.dev/?id=introduction
  • @hookform/resolvers -- an easy to use package that connects Zod schemas to React Hook Form for easy and effective form validation. More here: https://www.npmjs.com/package/@hookform/resolvers

Screenshots

Screenshot 2024-02-11 at 5 33 06 PM Screenshot 2024-02-11 at 5 35 19 PM Screenshot 2024-02-11 at 5 33 29 PM Screenshot 2024-02-11 at 5 33 55 PM Screenshot 2024-02-11 at 5 34 21 PM Screenshot 2024-02-11 at 5 34 43 PM Screenshot 2024-02-11 at 5 35 03 PM

Radix UI Dependencies:
@radix-ui/react-dialog
@radix-ui/react-label
@radix-ui/react-select
@radix-ui/react-slot
@radix-ui/react-toggle-group

Form Validation Dependencies:
@hookform/resolvers
react-hook-form (UPDATED)
zod
Notifications View
No Organizations View
@joshua-rdrgz joshua-rdrgz added enhancement New feature or request frontend labels Feb 11, 2024
Solves type errors related to react-hook-form and form validation resolvers
Copy link
Collaborator

@DMalone87 DMalone87 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Excellent! Looks good.

@joshua-rdrgz joshua-rdrgz merged commit 6f29f7f into codeforboston:main Feb 14, 2024
3 checks passed
@joshua-rdrgz joshua-rdrgz deleted the josh/epic-two-ui branch February 14, 2024 21:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request frontend
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants