Commit Graph

9 Commits

Author SHA1 Message Date
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
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
Felipe Cardoso
99ec4ebfa1 Add EventThemesContext for managing event theme state
Introduced a new React context, EventThemesContext, to handle event theme state and CRUD operations. It includes support for creating, updating, deleting, and fetching themes with React Query integration. This provides a centralized solution for managing event theme-related data in the application.
2025-03-12 15:55:28 +01:00
Felipe Cardoso
d8980e18ce Add support for fetching events by slug in context
Introduced `fetchEventBySlug` method and `event` state to the events context, enabling retrieval of event data via slugs. Updated context state to handle related loading and error states (`isLoadingEvent` and `eventError`), and integrated query logic for slug-based event fetching.
2025-03-12 09:21:45 +01:00
Felipe Cardoso
80ff350053 Add EventsContext for managing events state and operations
Introduce an EventsContext and EventsProvider to centralize event-related logic, including queries, mutations, and pagination. Wrap the application with the EventsProvider in the providers index to make the context accessible throughout the app.
2025-03-11 06:19:06 +01:00
Felipe Cardoso
1b453e80c9 Refactor authentication flows and improve logout handling
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 44s
Split authentication logic into a reusable `MainLayout` component for better structure and consistency. Enhanced logout functionality to ensure proper state resetting and added minor delays for reliable redirect behavior. Improved safeguards for unauthenticated access, reducing potential edge case errors.
2025-03-05 10:56:20 +01:00
Felipe Cardoso
c61ad52331 Refactor auto-generated schemas and types formatting
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 42s
Updated the formatting for auto-generated schemas, types, and related files to adhere to consistent coding standards (e.g., double quotes, indentation). No functional changes were made, ensuring behavior remains identical.
2025-03-05 10:13:33 +01:00
Felipe Cardoso
a7504f6876 Add authentication context and provider for user management
Introduce `AuthContext` with login, logout, and token management. Includes protected route handling, token refresh logic, and user session persistence via React Context API. Prepares the app for authentication workflows.
2025-03-05 10:09:19 +01:00