Skip to content

Commit

Permalink
Merge branch 'main' of https://github.com/efdevcon/monorepo
Browse files Browse the repository at this point in the history
  • Loading branch information
lassejaco committed Sep 30, 2024
2 parents bea5317 + 28f638b commit 57f1673
Show file tree
Hide file tree
Showing 4 changed files with 38 additions and 6 deletions.
7 changes: 4 additions & 3 deletions devcon/cms/pages/devcon_week.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,10 @@ main_section:
about: |
hahaha I can write this and itworks
alert: >
Remember, Devcon is different from [Devconnect](https://devconnect.org/) with
its goals being cross-collaboration, reduction of silos, and being together
for 4 days in one place, one venue.
Remember, Devcon is different from [Devconnect](https://devconnect.org
"Devconnect") with its goals being cross-collaboration, reduction of silos,
and being together for 4 days in one place, one venue. We encourage any
daytime side events to take place before or after Devcon event days.
devcon_week:
about: "## **Devcon Week Calendar**\n\n### This calendar highlights selected events organized by the Ethereum community before and after Devcon. It doesn’t feature side events during Devcon days because Devcon has full-day programming that you don't want to miss.\n\n**Plan your trip to Bangkok**\L\n\nUse this calendar to decide when to arrive in Bangkok and maximize your Devcon experience. Check the schedule and the **[City Guide](/city-guide)** and start planning today.\n\n<Buttons\n Button={[\n { text: \"City Guide\", url: \"/city-guide\", color: \"orange-1\" },\n { text: \"Get Tickets\", url: \"/tickets\", color: \"orange-1\" }\n ]}\n/>\n"
snapshot:
Expand Down
2 changes: 1 addition & 1 deletion devcon/src/components/common/card/CallToActionCard.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import cn from 'classnames'

type CallToActionProps = {
title: string
tag?: string
tag?: string | React.ReactNode
children: any
color?: 'orange' | 'purple' | 'blue' | 'teal'
BackgroundSvg: any
Expand Down
2 changes: 1 addition & 1 deletion devcon/src/pages/tickets.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@ export default pageHOC(function Tickets(props: any) {
<CallToAction
color="blue"
title={'Ticketing Status'}
tag={waveActive ? 'Ticket Wave Live' : 'Discounts Available'}
tag={waveActive ? 'Ticket Wave Live' : <Link to="#discounts">Discounts Available</Link>}
BackgroundSvg={SpeakersBackground}
// link="https://tickets.devcon.org"
// linkText="Buy Tickets"
Expand Down
33 changes: 32 additions & 1 deletion devconnect/src/pages/_app.tsx
Original file line number Diff line number Diff line change
@@ -1,14 +1,17 @@
import React from 'react'
import React, { useState } from 'react'
import 'styles/globals.scss'
import type { AppProps } from 'next/app'
import { Roboto, Roboto_Condensed } from 'next/font/google'
import { motion, AnimatePresence } from 'framer-motion'
export const roboto = Roboto({ subsets: ['latin'], variable: '--font-roboto', weight: ['400', '700'], display: 'swap' })
export const robotoCondensed = Roboto_Condensed({
subsets: ['latin'],
variable: '--font-roboto-condensed',
weight: ['400', '700'],
})
import { init } from '@socialgouv/matomo-next'
import { Button } from 'lib/components/button'
import Link from 'common/components/link'

const MATOMO_URL = 'https://ethereumfoundation.matomo.cloud'
const MATOMO_SITE_ID = '29'
Expand All @@ -28,6 +31,8 @@ if (typeof window !== 'undefined') {
}

function MyApp({ Component, pageProps }: AppProps) {
const [showBanner, setShowBanner] = useState(true)

React.useEffect(() => {
if (!matomoAdded && process.env.NODE_ENV === 'production') {
init({ url: MATOMO_URL, siteId: MATOMO_SITE_ID })
Expand All @@ -43,6 +48,32 @@ function MyApp({ Component, pageProps }: AppProps) {
--font-roboto-condensed: ${robotoCondensed.style.fontFamily};
}
`}</style>

<AnimatePresence>
{showBanner && (
<motion.div
initial={{ y: -100 }}
animate={{ y: 0 }}
exit={{ y: -100 }}
transition={{ duration: 1 }}
className="fixed top-4 pointer-events-none flex left-0 right-0 justify-center items-center text-black text-center z-50 rounded-md mx-4"
>
<div className="flex flex-wrap justify-center gap-2 items-center bg-white shadow-md pointer-events-auto p-2.5 rounded-md">
<p>
Devcon is happening on November 12-15! Learn more on{' '}
<Link href="https://devcon.org" className="underline">
devcon.org
</Link>
.
</p>
<Button className="" color="black-1" fill onClick={() => setShowBanner(false)}>
Dismiss
</Button>
</div>
</motion.div>
)}
</AnimatePresence>

<Component {...pageProps} />
</>
)
Expand Down

0 comments on commit 57f1673

Please sign in to comment.