Skip to content

Commit

Permalink
devcon devconnect first mvp
Browse files Browse the repository at this point in the history
  • Loading branch information
lassejaco committed Dec 4, 2024
1 parent 9c7b712 commit ad15818
Show file tree
Hide file tree
Showing 4 changed files with 98 additions and 43 deletions.
3 changes: 2 additions & 1 deletion devcon/cms/pages/index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,8 @@ index_ctas:
url: 'https://devcon.org/en/experiences/'
section1:
body: >
## Devcon is the Ethereum conference for developers, thinkers, and makers.
## **Devcon is the Ethereum conference for developers, thinkers, and
makers**.
##### Devcon's mission is to bring decentralized protocols, tools, and
Expand Down
56 changes: 30 additions & 26 deletions devcon/src/components/domain/index/featured-speakers-dc7/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -203,26 +203,26 @@ const HighlightedSpeakers = ({
const isInView = useInView(ref, { once: true })
const controls = useAnimation()

useEffect(() => {
if (isInView && !isHovered) {
const rotateInterval = setInterval(() => {
try {
setCurrentIndex(prevIndex => (prevIndex + 4) % speakers.length)
controls.set({ scaleX: 0 })
controls.start({ scaleX: 1, transition: { duration: 6, ease: 'linear' } })
} catch (error) {
console.error('Error in rotateInterval:', error)
}
}, 6000)

controls.start({ scaleX: 1, transition: { duration: 6, ease: 'linear' } })

return () => clearInterval(rotateInterval)
} else if (isHovered) {
controls.stop()
controls.set({ scaleX: 0 })
}
}, [isInView, speakers, controls, isHovered])
// useEffect(() => {
// if (isInView && !isHovered) {
// const rotateInterval = setInterval(() => {
// try {
// setCurrentIndex(prevIndex => (prevIndex + 4) % speakers.length)
// controls.set({ scaleX: 0 })
// controls.start({ scaleX: 1, transition: { duration: 6, ease: 'linear' } })
// } catch (error) {
// console.error('Error in rotateInterval:', error)
// }
// }, 6000)

// controls.start({ scaleX: 1, transition: { duration: 6, ease: 'linear' } })

// return () => clearInterval(rotateInterval)
// } else if (isHovered) {
// controls.stop()
// controls.set({ scaleX: 0 })
// }
// }, [isInView, speakers, controls, isHovered])

const currentSpeakers = useMemo(() => {
const endIndex = currentIndex + 4
Expand Down Expand Up @@ -310,13 +310,13 @@ const HighlightedSpeakers = ({
))}
</motion.div>
</AnimatePresence>
<div className="flex justify-center items-center w-[100px] bg-gray-100 mx-auto transform translate-y-2">
{/* <div className="flex justify-center items-center w-[100px] bg-gray-100 mx-auto transform translate-y-2">
<motion.div
className="h-[2px] w-[100px] bg-indigo-400 origin-center"
initial={{ scaleX: 0 }}
animate={controls}
/>
</div>
</div> */}
</div>
)
}
Expand Down Expand Up @@ -442,25 +442,29 @@ const FeaturedSpeakers = () => {
name: 'Aya',
role: 'Executive Director @ Ethereum Foundation',
avatarUrl: AyaMiyaguchiImage,
link: 'https://x.com/AyaMiyagotchi',
// link: 'https://x.com/AyaMiyagotchi',
link: 'https://app.devcon.org/speakers/ADH9HF',
},
{
name: 'Vitalik Buterin',
role: 'Co-founder @ Ethereum',
avatarUrl: VitalikImage,
link: 'https://x.com/VitalikButerin',
// link: 'https://x.com/VitalikButerin',
link: 'https://app.devcon.org/speakers/FLKFV8',
},
{
name: 'Roger Dingledine',
role: 'Co-founder @ Tor Project',
avatarUrl: RogerDingledineImage,
link: 'https://x.com/RogerDingledine',
// link: 'https://x.com/RogerDingledine',
link: 'https://app.devcon.org/speakers/P9TDQR',
},
{
name: 'Bruno Macaes',
role: 'Political Scientist, Author, and former Secretary of State',
avatarUrl: BrunoImage,
link: 'https://x.com/MacaesBruno',
// link: 'https://x.com/MacaesBruno',
link: 'https://app.devcon.org/speakers/PRM7AM',
},
]

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -190,8 +190,8 @@ const StatsAnimation = () => {
render: {
sprite: {
texture: `/assets/textures/${icon}`,
xScale: 0.7,
yScale: 0.7,
xScale: 0.6,
yScale: 0.6,
},
},
frictionAir: 0.15,
Expand Down
78 changes: 64 additions & 14 deletions devcon/src/pages/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ import { GetContentSections } from 'services/page'
import { useTina } from 'tinacms/dist/react'
import { client } from '../../tina/__generated__/client'
import { PagesQuery, PagesIndex, PagesFaq_General, PagesProgramming } from '../../tina/__generated__/types'
// import TitleDevcon from 'assets/images/devcon-title.svg'
import TitleDevcon from 'assets/images/devcon-title.svg'
import LogoFlowers from 'assets/images/dc-7/logo-flowers.png'
import InfiniteScroller from 'lib/components/infinite-scroll'
import StatsAnimation from 'components/domain/index/hero/stats-anim'
Expand Down Expand Up @@ -61,17 +61,36 @@ import Security from 'assets/images/programming/Security.png'
import Layer2 from 'assets/images/programming/Layer2.png'

const videos = [
// {
// url: 'YyK8i2-0aPk',
// title: 'Devcon SEA Recap Video',
// devcon: 7,
// },
{
url: 'YyK8i2-0aPk',
title: 'This Year in Ethereum',
author: 'Josh Stark',
devcon: 7,
},
{
url: 'SE15rsPVHz0',
title: 'Redefining boundaries in the Infinite Garden',
author: 'Aya Miyaguchi',
devcon: 7,
},
{
url: 'ei3tDRMjw6k',
title: 'Ethereum in 30 minutes by Vitalik Buterin | Devcon SEA',
title: 'Ethereum in 30 minutes',
author: 'Vitalik Buterin',
devcon: 7,
},
{
url: 'n3R4ze2hesk',
title: 'Keynote: ⿻ Infinite Diversity in Infinite Combinations',
author: 'Audrey Tang',
devcon: 7,
},
{
url: '7LRbiZ_FiSg',
title: 'Keynote: Glass Houses and Tornados',
author: 'Peter Van Valkenburgh',
devcon: 7,
},
{
url: 'lgTMm7J0t7c',
title: 'Devcon VI Bogota Recap Video',
Expand All @@ -97,7 +116,7 @@ const videos = [
},
{
url: 'oLGZdLpHl1w',
title: 'A Conversation with Stewart Brand (Devcon4)',
title: 'A Conversation with Stewart Brand',
author: 'Stewart Brand',
devcon: 4,
},
Expand Down Expand Up @@ -309,7 +328,7 @@ export default pageHOC(function Index(props: any) {
{/* <TitleDevcon className="hidden lg:block" /> */}
<RichText content={pages.section1?.body}></RichText>

{cal && (
{/* {cal && (
<Modal open={calendarModalOpen} close={() => setCalendarModalOpen(false)}>
<ModalContent
className="border-solid border-[#8B6BBB] border-t-4 w-[560px]"
Expand Down Expand Up @@ -340,7 +359,7 @@ export default pageHOC(function Index(props: any) {
</div>
</ModalContent>
</Modal>
)}
)} */}
</div>
{/* <div className="flex w-full flex-col grow shrink-0 max-w-[410px] lg:grow-0 relative">
<div className="flex justify-between w-full gap-4">
Expand Down Expand Up @@ -381,12 +400,43 @@ export default pageHOC(function Index(props: any) {
</div>

<div className="section">
<div className="relative flex flex-col items-start pb-8 border-bottom gap-4 mt-8">
<div className="relative flex flex-col items-start border-bottom gap-8 pt-8 pointer-events-none ">
<div className={`${css['scrolling-text-background']}`}>
<InfiniteScroller nDuplications={2} speed="120s">
<p className="bold">SOUTHEAST ASIA&nbsp;</p>
<p className="bold">DEVCON RECAP&nbsp;</p>
</InfiniteScroller>
</div>
{/*
<div className={`${css['scrolling-text-background']} ${css['alternate']} ${css['blue']}`}>
<InfiniteScroller nDuplications={2} speed="140s" reverse>
<p className="bold">DEVCON RECAP&nbsp;</p>
</InfiniteScroller>
</div> */}

<div className={`z-10 ${css['background-text']}`}>
<RichText content={pages.section4?.body}></RichText>
</div>

<div
className="sm:h-[250px] xl:h-[300px] h-[350px] relative w-full z-0 pointer-events-auto"
ref={scrollRef}
>
{isInView && (
<motion.div initial={{ opacity: 0 }} animate={{ opacity: 1 }} transition={{ duration: 0.6 }}>
<StatsAnimation />
</motion.div>
)}
</div>
</div>
</div>

<div className="section">
<div className="relative flex flex-col items-start pb-8 border-bottom gap-4 mt-8">
{/* <div className={`${css['scrolling-text-background']}`}>
<InfiniteScroller nDuplications={2} speed="120s">
<p className="bold">SOUTHEAST ASIA&nbsp;</p>
</InfiniteScroller>
</div> */}

<div className="grid grid-cols-1 lg:grid-cols-[3fr_2fr] gap-8">
<div className="flex flex-col h-full lg:mt-2">
Expand Down Expand Up @@ -453,7 +503,7 @@ export default pageHOC(function Index(props: any) {
/>
</div>

<div className="relative flex flex-col items-start border-bottom gap-8 pt-8 pointer-events-none">
{/* <div className="relative flex flex-col items-start border-bottom gap-8 pt-8 pointer-events-none">
<div className={`z-10 ${css['background-text']}`}>
<RichText content={pages.section4?.body}></RichText>
</div>
Expand All @@ -465,7 +515,7 @@ export default pageHOC(function Index(props: any) {
</motion.div>
)}
</div>
</div>
</div> */}
</div>

<div className="section">
Expand Down

0 comments on commit ad15818

Please sign in to comment.