Skip to content

Issue 15 create sponsors & guests page - #38

Merged
allyharrison merged 15 commits into
mainfrom
issue-15-Create_Sponsors_&_Guests_page
Jul 19, 2025
Merged

Issue 15 create sponsors & guests page#38
allyharrison merged 15 commits into
mainfrom
issue-15-Create_Sponsors_&_Guests_page

Conversation

@JoJohowl

@JoJohowl JoJohowl commented Jul 18, 2025

Copy link
Copy Markdown
Contributor

Change Summary

This pull request introduces a new "Sponsors and Guests" feature for the client application. It includes components for displaying special guests and sponsors, a dedicated page for this feature, and updates to the configuration to support image domains. The most important changes focus on implementing reusable components, fetching data dynamically, and ensuring compatibility with the development environment.

Change Form

Fill this up (NA if not available). If a certain criteria is not met, can you please give a reason.

  • The pull request title has an issue number
  • The change works by "Smoke testing" or quick testing
  • The change has tests
  • The change has documentation

Other Information

[Is there anything in particular in the review that I should be aware of?]

Resolves #15

Related issue

jozellerebecca and others added 10 commits July 5, 2025 03:27
1. Add Sponsor component
2. Add index.ts to export it
…ith backend placeholder

- Modified SponsorSection component to use Montserrat font for consistent typography
- Added SponsorSection to SponsorsAndGuest page, passing partners state
- Implemented useEffect hook in SponsorsAndGuest to asynchronously fetch partners data from /api/partners
- Added loading state to handle asynchronous data fetching UX
- Prepared page for future backend integration, ensuring seamless sponsor data flow
- Improved component structure and styling for better maintainability and UI consistency
Updated .gitignore to exclude /server/media and /server/static_files directories from version control.
Changed the fetch URL for partners data from a relative path to 'http://localhost:8000/api/partners' to ensure correct API endpoint is used during local development.
Introduces the GuestSection component to display special guests, updates the SponsorsGuests index to export both SponsorSection and GuestSection, and modifies the sponsorsGuests page to support and render guest data alongside sponsors.
Combined data fetching for partners and guests using Promise.all and refactored the UI to use the GuestSection component for displaying guests. This improves maintainability and enables dynamic rendering of guest data from the backend.
Changed API endpoints in sponsorsGuests.tsx to use new sponsor routes. Allowed localhost and 127.0.0.1 domains for Next.js image optimization. Added 'relative' class to guest image container for improved styling.
The guest link is now rendered in its own paragraph below the description for improved clarity and separation in the GuestSection component.
@JoJohowl JoJohowl added the frontend Task must have a front end issue label Jul 18, 2025
@JoJohowl JoJohowl self-assigned this Jul 18, 2025
Comment thread client/src/pages/sponsorsGuests.tsx

@junhyap junhyap left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Pretty good but I have some comments peppered throughout the files.

A common theme I noticed in every file is that you're importing fonts individually. A good rule of thumb is if you find that your repeating yourself frequently, there's usually a good way to minimise that. You can actually import a font into tailwind itself and just use it as a class name. i.e. instead of constantly adding

import { Montserrat } from "next/font/google";

const montserrat = Montserrat({
  subsets: ["latin"],
  weight: ["400", "600", "700"],
});

You can actually just import it once into tailwind and use it as a class.

Reference: https://tailwindcss.com/docs/font-family#customizing-your-theme

Another thing is the custom classes.

Feel free to let me know your thoughts :)

Comment thread client/src/components/SponsorsGuests/GuestSection.tsx Outdated
Comment thread client/src/components/SponsorsGuests/GuestSection.tsx Outdated
Comment thread client/src/components/SponsorsGuests/GuestSection.tsx Outdated
Comment thread client/src/components/SponsorsGuests/GuestSection.tsx Outdated
Comment thread client/src/components/SponsorsGuests/GuestSection.tsx Outdated
Comment thread client/src/components/SponsorsGuests/SponsorSection.tsx Outdated
Comment thread client/src/pages/sponsorsGuests.tsx Outdated
Comment thread client/src/pages/sponsorsGuests.tsx
@allyharrison
allyharrison requested a review from junhyap July 19, 2025 05:23
@allyharrison

Copy link
Copy Markdown
Contributor

@junhyap - PR Feedback should be actioned, please review again

@allyharrison
allyharrison merged commit 63caa9d into main Jul 19, 2025
5 checks passed
@allyharrison

Copy link
Copy Markdown
Contributor

@junhyap - I'm merging, but if you have more feedback, let me know and I'll raise another PR

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

frontend Task must have a front end issue

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Create Sponsors & Guests page

5 participants