Commit Graph

227 Commits

Author SHA1 Message Date
Felipe Cardoso
445d644538 Add GuestContext for managing guest-related state
Some checks failed
Build and Push Docker Images / changes (push) Successful in 5s
Build and Push Docker Images / build-backend (push) Has been skipped
Build and Push Docker Images / build-frontend (push) Failing after 51s
Introduced a new GuestContext with accompanying provider to handle guest-related data, including fetching, creating, updating, and deleting guests. Integrated GuestsProvider into the application's data provider hierarchy to ensure guest data is accessible across components.
2025-03-15 21:45:16 +01:00
Felipe Cardoso
90f49f99c6 Add @radix-ui/react-dropdown-menu dependency
Integrates the @radix-ui/react-dropdown-menu package to the project. Updates both package.json and package-lock.json to include the relevant version and dependencies. This prepares the app for dropdown menu functionality using Radix UI components.
2025-03-15 21:03:20 +01:00
Felipe Cardoso
22e11e9bfe Add guests list table MOCK component with search and actions
Introduce a dynamic guests list table featuring search, filters, and status badges. Includes functionality to add new guests, perform actions like editing or deleting, and view summarized data for confirmations and additional guests. just the mock
2025-03-15 21:03:13 +01:00
Felipe Cardoso
3800fcea19 Comment out RSVP section and update Gift Registry text
Some checks failed
Build and Push Docker Images / changes (push) Successful in 5s
Build and Push Docker Images / build-backend (push) Has been skipped
Build and Push Docker Images / build-frontend (push) Failing after 51s
The RSVP section is now commented out, removing its visibility from the page. Additionally, the text and button for the Gift Registry section have been updated to better reflect its purpose, allowing users to manage and edit the registry.
2025-03-15 20:58:17 +01:00
Felipe Cardoso
df5a11a2a3 Make invitation_code optional and nullable in Guest schemas
Some checks failed
Build and Push Docker Images / changes (push) Successful in 5s
Build and Push Docker Images / build-backend (push) Has been skipped
Build and Push Docker Images / build-frontend (push) Failing after 51s
Updated GuestCreate and GuestRead schemas to adjust the `invitation_code` field. It is now optional and can be null for GuestCreate, while required for GuestRead. This change ensures better flexibility in handling guest data.
2025-03-15 20:35:39 +01:00
Felipe Cardoso
3c196b1e91 Add invitation code validation and auto-generation for guests
All checks were successful
Build and Push Docker Images / changes (push) Successful in 4s
Build and Push Docker Images / build-backend (push) Successful in 50s
Build and Push Docker Images / build-frontend (push) Has been skipped
Validate uniqueness of invitation codes during guest creation to prevent duplicates. Automatically generate an 8-character code if none is provided, ensuring consistent data handling. Updated tests and schemas to support these changes.
2025-03-15 20:34:38 +01:00
Felipe Cardoso
e41e7d0867 Add RSVP modal and form components for event attendance
Some checks failed
Build and Push Docker Images / changes (push) Successful in 4s
Build and Push Docker Images / build-backend (push) Has been skipped
Build and Push Docker Images / build-frontend (push) Failing after 50s
Introduced a new RSVP modal and form to enable guests to RSVP to events more seamlessly. Updated the invite page to integrate the new modal and handle guest attendance submissions. Refactored the RSVP functionality into reusable components for better maintainability.
2025-03-15 20:19:08 +01:00
Felipe Cardoso
695743fa76 Refactor schemas to update event-related models.
Some checks failed
Build and Push Docker Images / changes (push) Successful in 5s
Build and Push Docker Images / build-backend (push) Has been skipped
Build and Push Docker Images / build-frontend (push) Failing after 50s
Replaced generation-related schemas with event-oriented ones like EventCreate, EventResponse, and EventTheme schemas. Introduced new fields and structures to support event management, including RSVP, themes, and contact information. Removed unused schemas and adjusted naming for consistency.
2025-03-15 20:00:54 +01:00
Felipe Cardoso
9695c29ab5 Add reusable Dialog component using Radix UI
Implemented a Dialog component with Radix UI's primitives for a customizable and accessible modal experience. Updated dependencies to include `@radix-ui/react-dialog` and structured the component for extensibility and reuse.
2025-03-15 19:56:57 +01:00
Felipe Cardoso
0ee314f1c0 Update react-query typings and methods for API endpoints
This refactor replaces outdated API methods with new ones, aligning with updated backend endpoints. The changes include renaming and restructuring query/mutation functions and their corresponding types to improve consistency and support additional API capabilities.
2025-03-15 19:56:50 +01:00
Felipe Cardoso
7f3401e759 Refactor: Update auto-generated schemas for API changes
Replaced and updated multiple schema definitions to align with new API structures. Includes renaming, adding new enums, refining object properties, and reorganizing schemas for clarity. Ensures better compatibility and adherence to the updated API specifications.
2025-03-15 19:56:38 +01:00
Felipe Cardoso
58ac33990f Add RSVP context and provider for managing RSVP state
Some checks failed
Build and Push Docker Images / changes (push) Successful in 5s
Build and Push Docker Images / build-backend (push) Has been skipped
Build and Push Docker Images / build-frontend (push) Failing after 51s
Introduce a context and provider for handling RSVP data, including fetching, updating, creating, and deleting RSVPs. The implementation utilizes React Query for data management and exposes methods for managing RSVP operations throughout the application.
2025-03-15 19:44:20 +01:00
Felipe Cardoso
c0516c1086 Add schemas and APIs for Guest and RSVP management
Some checks failed
Build and Push Docker Images / changes (push) Successful in 4s
Build and Push Docker Images / build-backend (push) Has been skipped
Build and Push Docker Images / build-frontend (push) Failing after 50s
Introduced schemas and types for Guests and RSVPs, along with their create, read, update, and delete endpoints. This also includes React Query integrations for managing guest and RSVP data in the frontend.
2025-03-15 02:26:04 +01:00
Felipe Cardoso
85eed0eac0 Add RSVP routes and integrate with events API router
Some checks failed
Build and Push Docker Images / build-frontend (push) Blocked by required conditions
Build and Push Docker Images / changes (push) Successful in 4s
Build and Push Docker Images / build-backend (push) Has been cancelled
This commit introduces a new RSVP module with endpoints for creating, reading, updating, and deleting RSVPs, along with a custom status update endpoint. The router is integrated into the events API, providing full RSVP management capabilities. Validation and error handling have been implemented to ensure data consistency.
2025-03-15 02:25:32 +01:00
Felipe Cardoso
632a762d64 Add CRUD and schema for RSVP management
Introduce CRUD operations and Pydantic schemas to manage RSVP entries, including creation, updates, retrieval, and deletion. This enables comprehensive handling of RSVP data with validation and support for guest and event IDs.
2025-03-15 02:20:36 +01:00
Felipe Cardoso
270bfda1f8 Add guests API with CRUD operations and tests
All checks were successful
Build and Push Docker Images / changes (push) Successful in 4s
Build and Push Docker Images / build-backend (push) Successful in 50s
Build and Push Docker Images / build-frontend (push) Has been skipped
Introduce a new API for managing event guests, including endpoints for creating, reading, updating, deleting, and changing guest status. Added corresponding Pydantic schemas, database CRUD logic, and extensive test coverage to validate functionality. Integrated the guests API under the events router.
2025-03-15 02:09:17 +01:00
Felipe Cardoso
12161e048d Refactor tests and fix patch imports in event themes tests
Updated `@patch` targets to match their correct import paths and adjusted imports for clarity and consistency. Fixed indentation issues and resolved minor import ordering problems to improve code readability.
2025-03-15 01:29:39 +01:00
Felipe Cardoso
fee7d8b5ec Refactor CRUD module imports and usage for clarity.
Replaces ambiguous shorthand references like `event` and `user` with more descriptive names such as `event_crud` and `user_crud`. Updates imports, function calls, tests, and other references across the codebase to maintain consistency. This improves code readability and reduces potential confusion.
2025-03-15 01:22:04 +01:00
Felipe Cardoso
d5d6c4b3c9 Update RSVP date format and enhance invite page styles
Some checks failed
Build and Push Docker Images / changes (push) Successful in 5s
Build and Push Docker Images / build-backend (push) Has been skipped
Build and Push Docker Images / build-frontend (push) Failing after 50s
Changed the RSVP deadline format to "dd.MM.yyyy" for consistency. Improved text styles by adding bold fonts to emphasize key sections and included a new confirmation message for RSVP deadline.
2025-03-15 01:18:10 +01:00
Felipe Cardoso
78533d3d17 Revamp invite page banner styling and layout.
Some checks failed
Build and Push Docker Images / changes (push) Successful in 4s
Build and Push Docker Images / build-backend (push) Has been skipped
Build and Push Docker Images / build-frontend (push) Failing after 50s
Updated the invite page banner to use a more dynamic and visually appealing design with a background image or fallback styling. Added a text overlay for improved readability and enhanced the fallback display when an image is unavailable.
2025-03-14 18:47:02 +01:00
Felipe Cardoso
cb092cd643 Revamp invite page banner styling and layout.
Updated the invite page banner to use a more dynamic and visually appealing design with a background image or fallback styling. Added a text overlay for improved readability and enhanced the fallback display when an image is unavailable.
2025-03-14 17:00:10 +01:00
Felipe Cardoso
f65500902c Revamp invite page banner styling and layout.
Updated the invite page banner to use a more dynamic and visually appealing design with a background image or fallback styling. Added a text overlay for improved readability and enhanced the fallback display when an image is unavailable.
2025-03-14 16:14:32 +01:00
Felipe Cardoso
08f5661c99 Refactor gift registry UI to use InfoCard component
Some checks failed
Build and Push Docker Images / changes (push) Successful in 4s
Build and Push Docker Images / build-backend (push) Has been skipped
Build and Push Docker Images / build-frontend (push) Failing after 49s
Simplified the gift registry section by replacing custom JSX with the reusable InfoCard component. This improves code maintainability and consistency in the UI while retaining the existing styles and functionality. Updated InfoCard styling to ensure compatibility with the new use case.
2025-03-14 15:54:53 +01:00
Felipe Cardoso
03cb95b4b3 Refactor gift registry UI to use InfoCard component
Some checks failed
Build and Push Docker Images / changes (push) Successful in 5s
Build and Push Docker Images / build-backend (push) Has been skipped
Build and Push Docker Images / build-frontend (push) Failing after 57s
Simplified the gift registry section by replacing custom JSX with the reusable InfoCard component. This improves code maintainability and consistency in the UI while retaining the existing styles and functionality. Updated InfoCard styling to ensure compatibility with the new use case.
2025-03-14 15:27:13 +01:00
Felipe Cardoso
5ca138928a Refactor event details to use reusable InfoCard component
Replaced repetitive JSX for event details (date/time, location) with the reusable `InfoCard` component. This reduces code duplication, improves readability, and centralizes styling logic. Added support for image positioning and optional button props in `InfoCard`.
2025-03-14 11:46:06 +01:00
Felipe Cardoso
991fd0356a Add InfoCard component to display customizable card layouts
Introduced a reusable InfoCard component with support for a variety of props including images, colors, text, and buttons. This component enhances flexibility and consistency in displaying card-based UI elements across the application.
2025-03-14 11:45:34 +01:00
Felipe Cardoso
41464f8bea Style adjustments 2025-03-14 11:18:10 +01:00
Felipe Cardoso
c82d80bc4c Refactor asset image handling in event theme form.
Some checks failed
Build and Push Docker Images / changes (push) Successful in 4s
Build and Push Docker Images / build-backend (push) Has been skipped
Build and Push Docker Images / build-frontend (push) Failing after 49s
Ensure asset_image_urls are merged instead of replaced during updates. Add a useEffect hook to log theme assets when editing an existing theme. These changes improve data handling consistency and debugging clarity.
2025-03-14 05:10:02 +01:00
Felipe Cardoso
9bf8025389 Remove debug console log from image uploader component
Commented out a leftover console log statement used for debugging. This cleans up the code and prevents unnecessary logging in the production environment.
2025-03-14 05:09:56 +01:00
Felipe Cardoso
382df4f83f Enhance invitation page with theme-based design and features
This update integrates theme-based styling and assets for the invitation page, including dynamic colors, fonts, and images. Added features include improved loading states, detailed event information, RSVP handling, gift registry, and interactive map functionality. This refactor enhances the user experience and supports event-specific personalization.
2025-03-14 05:03:15 +01:00
Felipe Cardoso
3862fdb1ad Add date-fns dependency to the frontend project
Added date-fns version 4.1.0 to package.json and package-lock.json. This introduces date utility functions, enabling easier date manipulations and formatting across the frontend. No functional changes yet, just preparing for future use.
2025-03-14 05:03:09 +01:00
Felipe Cardoso
9d13760b5f Add refetchThemes function to event theme context and usage
Some checks failed
Build and Push Docker Images / changes (push) Successful in 5s
Build and Push Docker Images / build-backend (push) Has been skipped
Build and Push Docker Images / build-frontend (push) Failing after 50s
Introduce a new `refetchThemes` function in the event theme context to allow for refreshing event theme data. Update `EventThemeForm` to call `refetchThemes` after updating a theme, ensuring the data stays synchronized. This enhances the consistency of the UI after changes to event themes.
2025-03-14 04:43:29 +01:00
Felipe Cardoso
0fa298ef4b Fix syntax error by removing extraneous semicolon
Removed an unnecessary semicolon within the JSX structure to adhere to proper syntax rules. This change prevents potential rendering issues and maintains consistency with the codebase style.
2025-03-14 03:55:46 +01:00
Felipe Cardoso
c580effb52 Display event theme details on the event detail page
Some checks failed
Build and Push Docker Images / changes (push) Successful in 4s
Build and Push Docker Images / build-backend (push) Has been skipped
Build and Push Docker Images / build-frontend (push) Failing after 49s
Added functionality to show event theme information, including name, description, and preview image, on the event detail page. Integrated `useEventThemes` context and updated utility function `getServerFileUrl` to handle nullable URLs.
2025-03-14 03:33:19 +01:00
Felipe Cardoso
4c6b97c9be Format event date as DD.MM.YYYY on the dashboard.
Updated the event date formatting logic to display dates in the DD.MM.YYYY format (used in the RSVP section). This improves consistency and aligns with user expectations for date representation.
2025-03-14 03:19:40 +01:00
Felipe Cardoso
33c3a03d19 Set RSVP deadline to date-only format in event form.
This ensures that the RSVP deadline value is always stored and displayed as a date-only string. It prevents issues with time components affecting the form's behavior and improves consistency across the app.
2025-03-14 03:16:57 +01:00
Felipe Cardoso
c7120b84b6 Simplify event date initialization in event form.
Some checks failed
Build and Push Docker Images / changes (push) Successful in 4s
Build and Push Docker Images / build-backend (push) Has been skipped
Build and Push Docker Images / build-frontend (push) Failing after 49s
Ensure the event date is formatted to 'YYYY-MM-DD' when pre-filling the form. This prevents potential issues with date handling and improves consistency in date rendering.
2025-03-14 03:15:38 +01:00
Felipe Cardoso
08ad83a872 Format event date and time consistently.
Some checks failed
Build and Push Docker Images / changes (push) Successful in 4s
Build and Push Docker Images / build-backend (push) Has been skipped
Build and Push Docker Images / build-frontend (push) Failing after 48s
Updated event date to use "DD.MM.YYYY" format and replaced time formatting logic with substring extraction for improved simplicity and consistency. This ensures a cleaner and more localized display of event information.
2025-03-14 03:09:40 +01:00
Felipe Cardoso
b18f684afb Fix incorrect timezone assignment in event_date validator
Updated the validation logic to correctly replace the timezone for `event_date`. This ensures proper handling of datetime objects without tzinfo.
2025-03-14 03:09:31 +01:00
Felipe Cardoso
74d37fc54c Add "Edit" button to event details page
Introduced an "Edit" button in the event details header for improved user access to editing event information. This button uses a link with an outline variant and includes an icon for better visual context. The layout was adjusted to accommodate the new button while preserving responsiveness.
2025-03-14 03:06:39 +01:00
Felipe Cardoso
e50fca4e77 Fix timezone handling for RSVP deadline validation
Updated the RSVP deadline validation to automatically assign UTC as the timezone if none is provided, ensuring consistency. This prevents errors and enforces proper timezone-aware datetime usage.
2025-03-14 03:02:51 +01:00
Felipe Cardoso
3e12a47e1d Add event editing page with delete functionality
This commit introduces a new page for editing events at the route `dashboard/events/[slug]/edit`. It includes features for loading event details, updating event data via a form, and a confirmation dialog for deleting events. Error handling and loading states are also implemented.
2025-03-14 03:02:46 +01:00
Felipe Cardoso
a49411d62d Add AlertDialog and Select UI components using Radix primitives
This commit introduces reusable AlertDialog and Select UI components built with Radix UI primitives, enabling consistent UI patterns in the project. Necessary dependencies for these components have been added to the package.json and package-lock.json files.
2025-03-14 02:56:20 +01:00
Felipe Cardoso
fa5daa605c Refactor event creation page to use reusable EventForm component
Replaced inlined event creation logic on `CreateEventPage` with a new reusable `EventForm` component. This decouples the form functionality, improves modularity, and enables future reuse for editing events. Enhanced validation and added support for event themes and additional settings within `EventForm`.
2025-03-14 02:55:59 +01:00
Felipe Cardoso
a5ce709e9e Enable hard delete option for event theme deletion
Updated the delete mutation to include a `hard_delete` query parameter. This ensures themes are permanently removed when deleted. The change improves clarity and control over deletion behavior.
2025-03-14 02:24:01 +01:00
Felipe Cardoso
ea91511ae5 Add delete theme functionality to Edit Theme page
Introduced a delete button to the Edit Theme page, allowing users to delete themes with a confirmation prompt. Upon deletion, users are redirected to the event themes dashboard. Updated relevant imports and added a handler for the delete action.
2025-03-14 02:23:53 +01:00
Felipe Cardoso
41eb631a5e Remove leading slash from 'uploads/' checks in theme URLs
Updated conditions to check 'uploads/' without a leading slash across preview, background, foreground, and asset image URLs. This ensures consistent handling of URLs during the relocation process and avoids potential mismatches in the path string comparison.
2025-03-14 02:23:44 +01:00
Felipe Cardoso
d2e71feb69 Refactor file relocation logic for theme-specific files.
All checks were successful
Build and Push Docker Images / changes (push) Successful in 4s
Build and Push Docker Images / build-backend (push) Successful in 49s
Build and Push Docker Images / build-frontend (push) Has been skipped
Updated the file relocation function to use `settings.DATA_FILES_DIR` for theme folders and improved filename handling by prefixing with the file type. Adjusted logic to handle URLs consistently and ensure paths are properly resolved. This enhances maintainability and organizes theme files more effectively.
2025-03-14 02:22:21 +01:00
Felipe Cardoso
3244fd8beb Update grid layout, refetch interval, and image handling
Adjusted the grid column behavior for medium screens in event themes and commented out unused badge rendering. Updated the image uploader to handle `existingImage` using the server URL and added debugging output. Modified the event theme context to use a fixed refetch interval of 60 seconds.
2025-03-14 02:00:41 +01:00
Felipe Cardoso
b7a9e3f981 Enable automatic refetching for event theme queries
Added `refetchOnWindowFocus` and `refetchIntervalInBackground` options to the event theme query. This ensures data stays updated when switching tabs or in the background.
2025-03-14 01:46:10 +01:00