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

Introduced Auth0 Integration with Event Edit feature #90

Closed

Conversation

yashksaini-coder
Copy link
Member

My PR includes changes to the event management functionality, where I particularly focused on the event editing feature and integrating Auth0 for authentication. The most important changes include adding an event editing page, enhancing event display with edit options for admins, and configuring Auth0 for authentication. Furthermore I used the WithPageAuthRequiredAppRouter in order to get auth access to the Event edit option.

Event Editing Feature:

  • src/app/(site)/editEvent/[id]/page.tsx: Added a new page for editing events, including form handling, image upload, and event data update logic. Add the WithPageAuthRequiredAppRouter and changes to the button event to display if the user is authenticated or not.

Event Display Enhancements:

  • src/app/(site)/events/page.tsx: Updated event display to include an edit button for admins, and wrapped the page with UserProvider to provide user context.
  • src/components/eventData/eventCard.tsx: Modified the Event component to include an edit button and handle click events for navigation.

Authentication Configuration:

  • .env.example: Added Auth0 configuration settings.
  • src/app/api/auth/[auth0]/route.ts: Added Auth0 authentication handler.

Description

Please include a summary of the changes and the related issue. Please also include relevant motivation and context. List any dependencies that are required for this change.

Fixes #85

Type of change

Please delete options that are not relevant.

  • 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 Configuration:

  • Firmware version:
  • Hardware:
  • Toolchain:
  • SDK:

Checklist:

  • My code follows the style guidelines of this project
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings
  • 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
  • Any dependent changes have been merged and published in downstream modules

@yashksaini-coder yashksaini-coder closed this by deleting the head repository Jan 17, 2025
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.

[FEATURE] Auth0 Integration and allow Event data edit button to admin users only
1 participant