|
@ -1,9 +1,9 @@ |
|
|
import { css } from "@emotion/css"; |
|
|
import { css, cx } from "@emotion/css"; |
|
|
import React from "react"; |
|
|
import React from "react"; |
|
|
import { setupCursorTracking } from "../../util"; |
|
|
import { setupCursorTracking } from "../../util"; |
|
|
import { Experience } from "./types"; |
|
|
import { Experience } from "./types"; |
|
|
|
|
|
|
|
|
const Circle: React.FC = () => ( |
|
|
const TimelineSegment: React.FC = () => ( |
|
|
<div className="timeline-segment" aria-hidden> |
|
|
<div className="timeline-segment" aria-hidden> |
|
|
<div |
|
|
<div |
|
|
className={css` |
|
|
className={css` |
|
@ -12,21 +12,25 @@ const Circle: React.FC = () => ( |
|
|
background: #333333; |
|
|
background: #333333; |
|
|
left: -50vw; |
|
|
left: -50vw; |
|
|
position: absolute; |
|
|
position: absolute; |
|
|
top: calc(-3rem + 0.2rem / 2); |
|
|
top: calc(-3rem + 0.3rem / 2); |
|
|
|
|
|
transform: translateY(-50%); |
|
|
z-index: 0; |
|
|
z-index: 0; |
|
|
`}></div>
|
|
|
`}></div>
|
|
|
<div |
|
|
<div |
|
|
className={css` |
|
|
className={cx( |
|
|
width: 0.25rem; |
|
|
"timeline-circle", |
|
|
height: 0.25rem; |
|
|
css` |
|
|
|
|
|
width: 0.3rem; |
|
|
|
|
|
height: 0.3rem; |
|
|
background: #333333; |
|
|
background: #333333; |
|
|
background: #ffffff; |
|
|
|
|
|
border-radius: 100%; |
|
|
border-radius: 100%; |
|
|
position: absolute; |
|
|
position: absolute; |
|
|
top: -3rem; |
|
|
top: -3rem; |
|
|
left: 0; |
|
|
left: 0; |
|
|
z-index: 100; |
|
|
z-index: 100; |
|
|
`}></div>
|
|
|
transition: background var(--transition-time) ease-in-out; |
|
|
|
|
|
`,
|
|
|
|
|
|
)}></div> |
|
|
</div> |
|
|
</div> |
|
|
); |
|
|
); |
|
|
|
|
|
|
|
@ -56,7 +60,6 @@ const btn = css` |
|
|
@media (pointer: fine) { |
|
|
@media (pointer: fine) { |
|
|
&:hover { |
|
|
&:hover { |
|
|
background-color: var(--card-hover); |
|
|
background-color: var(--card-hover); |
|
|
z-index: 1000; |
|
|
|
|
|
box-shadow: 0 0 25rem 2rem rgba(190, 190, 190, 0.1); |
|
|
box-shadow: 0 0 25rem 2rem rgba(190, 190, 190, 0.1); |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
@ -92,7 +95,7 @@ export const Content = ({ |
|
|
return ( |
|
|
return ( |
|
|
<button className={btn} onClick={onClick} ref={setupCursorTracking}> |
|
|
<button className={btn} onClick={onClick} ref={setupCursorTracking}> |
|
|
<div className="dynamic-gradient" /> |
|
|
<div className="dynamic-gradient" /> |
|
|
<Circle /> |
|
|
<TimelineSegment /> |
|
|
<h4> |
|
|
<h4> |
|
|
{title} |
|
|
{title} |
|
|
<span className="year"> · ({year})</span> |
|
|
<span className="year"> · ({year})</span> |
|
|