Skip to content

Commit 10fefd9

Browse files
committed
refactor: remove all css modules
1 parent a552882 commit 10fefd9

File tree

2 files changed

+38
-59
lines changed

2 files changed

+38
-59
lines changed

src/App.module.css

Lines changed: 0 additions & 36 deletions
This file was deleted.

src/App.tsx

Lines changed: 38 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ import { ReactNode, useState } from "react";
77
import { HashLink } from "react-router-hash-link";
88
import news from "./News";
99
import A from "./A";
10-
import { MdEmail, MdLocationPin } from "react-icons/md";
10+
import { MdEmail, MdLocationPin, MdDarkMode } from "react-icons/md";
1111
import {
1212
FaGithub,
1313
FaTwitter,
@@ -28,7 +28,7 @@ const NewsFeed = () => {
2828
({ time }) => time.getUTCFullYear() >= today.getUTCFullYear() - 1
2929
)
3030
.map(({ time, msg }, i) => (
31-
<div className="py-2 text-[#777] text-sm" key={`news-${i}`}>
31+
<div className="py-2 text-icon md:text-sm" key={`news-${i}`}>
3232
<div className="w-fit bg-[#eee] rounded py-px px-1">
3333
{time.toLocaleString("default", {
3434
month: "long",
@@ -84,46 +84,55 @@ const Publications = () => (
8484
id,
8585
bibtex,
8686
}: Paper) => (
87-
<div key={id} className={styles.PaperEntry}>
87+
<div key={id} className="my-4">
8888
<a href={pdf}>
89-
<span className={styles.PaperTitle}>{title}</span>
89+
<span className="text-lg font-semibold cursor-pointer">
90+
{title}
91+
</span>
9092
</a>
9193
<br />
92-
<span className={styles.PaperAuthors}>
94+
<span className="text-base">
9395
{authors
9496
.map((a) => (coauthors?.includes(a) ? `${a}*` : a))
9597
.map((a) =>
9698
a === "Wode Ni" || a === "Wode Ni*" ? <strong>{a}</strong> : a
9799
)
98100
.map((a, i) => (
99-
<li key={`id-author-${i}`}>{a}</li>
101+
<>
102+
<li className={`inline`} key={`id-author-${i}`}>
103+
{a}
104+
</li>
105+
{i !== authors.length - 1 && (
106+
<span key={`author-comma-${i}`}>, </span>
107+
)}
108+
</>
100109
))}
101110
</span>
102111
.{/* <br /> */}{" "}
103-
<span className={styles.PaperVenue}>
112+
<span className="text-base font-light italic">
104113
{/* {venue} ({series}) */}
105114
{series}
106115
</span>
107116
{"."}
108-
<div style={{ display: "flex", gap: "5px" }}>
109-
<div className={styles.PaperAsset}>
117+
<div className="flex gap-2">
118+
<div className="flex items-center gap-0.5">
110119
<BsBookmarkCheck />
111120
<Copy data={bibtex}>bib</Copy>
112121
</div>
113122
{pdf && (
114-
<div className={styles.PaperAsset}>
123+
<div className="flex items-center gap-0.5">
115124
<FaRegFilePdf />
116125
<A href={pdf}>pdf</A>
117126
</div>
118127
)}
119128
{talk && (
120-
<div className={styles.PaperAsset}>
129+
<div className="flex items-center gap-0.5">
121130
<FaRegPlayCircle />
122131
<A href={talk}>talk</A>
123132
</div>
124133
)}
125134
{slides && (
126-
<div className={styles.PaperAsset}>
135+
<div className="flex items-center gap-0.5">
127136
<BiSlideshow />
128137
<A href={slides}>slides</A>
129138
</div>
@@ -146,6 +155,12 @@ const Hero = ({ className }: { className?: string }) => (
146155
</div>
147156
);
148157

158+
const DarkToggle = () => (
159+
<div className="mx-1 w-6 h-6 text-xl flex cursor-pointer justify-center hover:opacity-50 ease-in-out duration-200 justify-self-center">
160+
<MdDarkMode fill={theme.colors.icon} />
161+
</div>
162+
);
163+
149164
const Socials = ({ className }: { className?: string }) => (
150165
<div
151166
className={`${className} flex items-start md:items-top md:ml-auto mb-0 color-primary`}
@@ -155,13 +170,14 @@ const Socials = ({ className }: { className?: string }) => (
155170
<GitHub />
156171
<Email />
157172
<Office />
173+
{/* <DarkToggle /> */}
158174
</div>
159175
);
160176

161177
const Icon = ({ url, icon }: { url: string; icon: ReactNode }) => (
162178
<a
163179
href={url}
164-
className="px-1 text-xl flex cursor-pointer hover:opacity-50 ease-in-out duration-200 justify-self-center"
180+
className="mx-1 w-6 h-6 text-xl flex cursor-pointer justify-center hover:opacity-50 ease-in-out duration-200 justify-self-center"
165181
>
166182
{icon}
167183
</a>
@@ -170,36 +186,33 @@ const Icon = ({ url, icon }: { url: string; icon: ReactNode }) => (
170186
const Office = () => (
171187
<Icon
172188
url="https://goo.gl/maps/Zp92ofs6ze3y8hc19"
173-
icon={<MdLocationPin width={theme.sizes.icon} fill={theme.colors.icon} />}
189+
icon={<MdLocationPin fill={theme.colors.icon} />}
174190
/>
175191
);
176192

177193
const Twitter = () => (
178194
<Icon
179195
url="https://twitter.com/wodenimoni"
180-
icon={<FaTwitter width={theme.sizes.icon} fill={theme.colors.icon} />}
196+
icon={<FaTwitter fill={theme.colors.icon} />}
181197
/>
182198
);
183199

184200
const GitHub = () => (
185201
<Icon
186202
url="https://github.com/wodeni"
187-
icon={<FaGithub width={theme.sizes.icon} fill={theme.colors.icon} />}
203+
icon={<FaGithub fill={theme.colors.icon} />}
188204
/>
189205
);
190206

191207
const CV = () => (
192208
<Icon
193209
url="http://wodenimoni.com/nimo-markdown-cv/"
194-
icon={<span className="font-extralight leading-5">CV</span>}
210+
icon={<span className="font-extralight leading-5 text-icon">CV</span>}
195211
/>
196212
);
197213

198214
const Email = () => (
199-
<Icon
200-
url="mailto:nimo@cmu.edu"
201-
icon={<MdEmail width={theme.sizes.icon} fill={theme.colors.icon} />}
202-
/>
215+
<Icon url="mailto:nimo@cmu.edu" icon={<MdEmail fill={theme.colors.icon} />} />
203216
);
204217

205218
const Text = ({
@@ -209,7 +222,9 @@ const Text = ({
209222
className?: string;
210223
children: ReactNode;
211224
}) => (
212-
<p className={`${className} font-sans font-light text-lg my-2`}>{children}</p>
225+
<p className={`${className} font-sans font-extralight text-lg my-2`}>
226+
{children}
227+
</p>
213228
);
214229

215230
const Section = ({
@@ -251,7 +266,7 @@ const Section = ({
251266

252267
const App: React.FC = () => {
253268
return (
254-
<div className="font-sans grid md:grid-cols-3 m-4 md:m-10 max-w-screen-xl">
269+
<div className="font-sans md:grid md:grid-cols-3 m-4 md:m-10 max-w-screen-xl">
255270
<Hero className="md:col-span-2" />
256271
<Socials className="mt-8" />
257272
<Text className="md:col-span-2 mt-8">

0 commit comments

Comments
 (0)