Skip to content

Commit

Permalink
More sponsors
Browse files Browse the repository at this point in the history
  • Loading branch information
dooman87 committed Oct 31, 2023
1 parent d40f3bf commit b015500
Show file tree
Hide file tree
Showing 6 changed files with 49 additions and 6 deletions.
19 changes: 17 additions & 2 deletions components/Sponsors/sponsors.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ export const Sponsors = ({ sponsors, show, hideUpsell }: SponsorsProps) => {
)
}

const diamondSponsors: Sponsor[] = []
const platinumSponsors: Sponsor[] = []
const goldSponsors: Sponsor[] = []
const silverSponsors: Sponsor[] = []
Expand All @@ -41,6 +42,9 @@ export const Sponsors = ({ sponsors, show, hideUpsell }: SponsorsProps) => {

for (const sponsor of sponsors) {
switch (sponsor.type) {
case SponsorType.Diamond:
diamondSponsors.push(sponsor)
break
case SponsorType.Platinum:
platinumSponsors.push(sponsor)
break
Expand Down Expand Up @@ -71,10 +75,10 @@ export const Sponsors = ({ sponsors, show, hideUpsell }: SponsorsProps) => {
return (
<Fragment>
<StyledSponsorsContainer>
{platinumSponsors.length > 0 && (
{diamondSponsors.length > 0 && (
<Fragment>
<h2>Diamond Sponsors</h2>
{platinumSponsors.map((sponsor) => (
{diamondSponsors.map((sponsor) => (
<StyledSponsorLink href={sponsor.url} target="_blank" key={sponsor.name} title={sponsor.name}>
<StyledSponsorLogo
level={SponsorType.Platinum}
Expand All @@ -87,6 +91,17 @@ export const Sponsors = ({ sponsors, show, hideUpsell }: SponsorsProps) => {
</Fragment>
)}

{platinumSponsors.length > 0 && (
<Fragment>
<h2>Platinum Sponsors</h2>
{platinumSponsors.map((sponsor) => (
<StyledSponsorLink href={sponsor.url} target="_blank" key={sponsor.name} title={sponsor.name}>
<StyledSponsorLogo src={imgUrl(sponsor.imageUrl, 260)} alt={sponsor.name} loading="lazy" />
</StyledSponsorLink>
))}
</Fragment>
)}

{goldSponsors.length > 0 && (
<Fragment>
<h2>Gold Sponsors</h2>
Expand Down
35 changes: 31 additions & 4 deletions config/sponsors.ts
Original file line number Diff line number Diff line change
@@ -1,15 +1,25 @@
import { Sponsor, SponsorType } from './types'

const platinumSponsors: Sponsor[] = [
const diamondSponsors: Sponsor[] = [
{
id: '2024-liberty',
imageUrl: '/static/images/sponsors/2024-liberty.png',
name: 'Liberty',
type: SponsorType.Platinum,
type: SponsorType.Diamond,
url: 'https://www.liberty.com.au/',
},
]

const platinumSponsors: Sponsor[] = [
{
id: '2024-DevExpress',
imageUrl: '/static/images/sponsors/2024-devexpress.png',
name: 'DevExpress',
type: SponsorType.Platinum,
url: 'https://www.devexpress.com/',
},
]

const goldSponsors: Sponsor[] = [
{
id: 'webjet',
Expand All @@ -27,7 +37,15 @@ const goldSponsors: Sponsor[] = [
},
]

const silverSponsors: Sponsor[] = []
const silverSponsors: Sponsor[] = [
{
id: 'qoria',
imageUrl: '/static/images/sponsors/2024-qoria.png',
name: 'Qoria',
type: SponsorType.Silver,
url: 'https://qoria.com/',
},
]

const coffeeCartSponsors: Sponsor[] = [
{
Expand All @@ -41,18 +59,27 @@ const coffeeCartSponsors: Sponsor[] = [

const serviceSponsors: Sponsor[] = [
{
id: '2022-luminary',
id: '2024-luminary',
imageUrl: '/static/images/sponsors/2024-luminary.png',
name: 'Luminary',
type: SponsorType.Service,
serviceProvided: 'Wi-Fi',
url: 'https://luminary.com/',
},
{
id: '2024-ssw',
imageUrl: '/static/images/sponsors/2024-ssw.png',
name: 'SSW',
type: SponsorType.Service,
serviceProvided: 'Childcare',
url: 'https://www.ssw.com.au/',
},
]

const communityPartners: Sponsor[] = []

const Sponsors: Sponsor[] = [
...diamondSponsors,
...platinumSponsors,
...goldSponsors,
...silverSponsors,
Expand Down
1 change: 1 addition & 0 deletions config/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -181,6 +181,7 @@ export enum SponsorType {
CoffeeCart,
Service,
Community,
Diamond,
}

export interface Sponsor {
Expand Down
Binary file added public/static/images/sponsors/2024-devexpress.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added public/static/images/sponsors/2024-qoria.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added public/static/images/sponsors/2024-ssw.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit b015500

Please sign in to comment.