Skip to content

Commit d08014a

Browse files
authored
chore: cleanup and copy changes (#68)
1 parent fb15c79 commit d08014a

File tree

10 files changed

+26
-11
lines changed

10 files changed

+26
-11
lines changed

.github/workflows/release.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,6 @@ jobs:
2626
2727
git checkout master
2828
npm version $VERSION_TAG --git-tag-version=false
29-
git commit -am "chore: bump version to $VERSION_TAG [ci skip]"
29+
git commit -am "🤖: bump version to $VERSION_TAG"
3030
git push origin -f HEAD:release
3131
git push origin -f HEAD:master

src/components/Bio.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { FunctionalComponent } from 'preact';
1+
import { FC } from 'react';
22
import { styled } from 'goober';
33

44
import { useSiteContext } from 'services/site/context';
@@ -15,7 +15,7 @@ const Container = styled('div')`
1515
}
1616
`;
1717

18-
const Bio: FunctionalComponent = () => {
18+
const Bio: FC = () => {
1919
const { talkingPoint } = useSiteContext();
2020

2121
return (

src/components/DynamicCurrentStatus.tsx

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
import { memo, FC, useEffect, useState } from 'react';
22
import { styled } from 'goober';
3-
43
import { prominent } from 'color.js';
54

65
import { Link } from 'components/core';

src/components/DynamicTagline.tsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
import { memo, FC } from 'react';
22
import TextLoop from 'react-text-loop';
3+
34
import { useSiteContext } from 'services/site/context';
45

56
const DynamicTagline: FC = memo(() => {

src/components/DynamicTime.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
import { styled } from 'goober';
21
import { memo, FC } from 'react';
2+
import { styled } from 'goober';
33

44
import { useSiteContext } from 'services/site/context';
55

src/components/MeIllustration.tsx

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -55,20 +55,29 @@ const GRIN_HAPPY = (
5555

5656
const MeIllustration: FC = memo(() => {
5757
const { isHoveringLink } = useSiteContext();
58+
const [, setNumClicks] = useState(0);
5859
const [isHovering, setHovering] = useState(false);
5960
const expression = isHoveringLink
6061
? SURPRISED
6162
: isHovering
6263
? WEIRD
6364
: GRIN_HAPPY;
6465

66+
const onIllustrationClick = () =>
67+
setNumClicks((prev) => {
68+
if (prev + 1 === 3)
69+
window.open('https://www.youtube.com/watch?v=dQw4w9WgXcQ', '_blank');
70+
return prev + 1;
71+
});
72+
6573
return (
6674
<svg
6775
height="280"
6876
overflow="visible"
6977
viewBox="233.511 78 682.97 695.5"
7078
onMouseEnter={() => setHovering(true)}
7179
onMouseLeave={() => setHovering(false)}
80+
onClick={onIllustrationClick}
7281
style={{ transition: 'transform 200ms' }}
7382
transform={`scale(${isHovering ? 1.02 : 1})`}
7483
>

src/components/core/Link.tsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
import { styled } from 'goober';
22
import { FC } from 'react';
3+
34
import { useSiteContext } from 'services/site/context';
45

56
type LinkProps = React.ComponentPropsWithoutRef<'a'> & { bare?: boolean };

src/pages/index.tsx

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
import { styled } from 'goober';
2+
import { InferGetStaticPropsType } from 'next';
23
import Head from 'next/head';
34
import dynamic from 'next/dynamic';
45

@@ -36,7 +37,7 @@ const ContentContainer = styled('main')`
3637
justify-content: center;
3738
`;
3839

39-
const IndexPage = (props) => {
40+
const IndexPage = (props: InferGetStaticPropsType<typeof getStaticProps>) => {
4041
return (
4142
<>
4243
<Head>

src/services/site/context.tsx

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
import { createContext, FunctionalComponent } from 'preact';
1+
import { Dispatch, SetStateAction, useState, FC } from 'react';
2+
import { createContext } from 'preact';
23
import { useContext } from 'preact/hooks';
3-
import { Dispatch, SetStateAction, useState } from 'react';
44

55
import type { TNowPlayingData } from 'services/now-playing';
66
import { getDateInZone, getRandomItem } from 'services/utils';
@@ -36,7 +36,7 @@ const greeting = getRandomItem(GREETINGS);
3636
const activity = getRandomItem(ACTIVITIES);
3737
const talkingPoint = getRandomItem(TALKING_POINTS);
3838

39-
const SiteContextProvider: FunctionalComponent<SiteContextProviderProps> = ({
39+
const SiteContextProvider: FC<SiteContextProviderProps> = ({
4040
nowPlayingData,
4141
currentTimeZone,
4242
children,
@@ -51,7 +51,7 @@ const SiteContextProvider: FunctionalComponent<SiteContextProviderProps> = ({
5151
taglines: TAGLINES,
5252
currentDate: getDateInZone(currentTimeZone),
5353
nowPlaying: nowPlayingData,
54-
activity, // todo: add back customStatus
54+
activity,
5555
talkingPoint,
5656

5757
isEasterEggActive,

src/services/site/copy.ts

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,11 @@ export const ACTIVITIES = [
3737
/**
3838
* Talking points
3939
*/
40-
export const TALKING_POINTS = ['how comic sans is the best font'];
40+
export const TALKING_POINTS = [
41+
'why comic sans is the best font',
42+
'dark patterns and how they affect human behaviour',
43+
'summer 2021 internship opportunities',
44+
];
4145

4246
/**
4347
* Links

0 commit comments

Comments
 (0)