Skip to content

Commit 61504ca

Browse files
committed
refactor(app): ♻️ refactor code and assets
1 parent 123aa7c commit 61504ca

18 files changed

+1893
-906
lines changed

app/globals.css

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,6 @@
8383
width: 2px;
8484
display: block;
8585
margin-left: -1.5px;
86-
display: none;
8786
background-color: #e4e4e4;
8887
}
8988
.experience__content > li {

app/layout.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ export default function RootLayout({children}: {children: React.ReactNode}) {
3434
<head />
3535
<body
3636
className={
37-
'group antialiased min-h-screen dark:bg-black-900 bg-white-300 transition-colors duration-1000 ease-in-out'
37+
'group antialiased min-h-screen dark:bg-black-900 bg-neutral-200 transition-colors duration-1000 ease-in-out'
3838
}
3939
>
4040
<Providers>

components/about-me.tsx

Lines changed: 24 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,16 @@
1+
import {Squircle} from '@squircle-js/react'
12
import {Link, Picture} from 'components'
23

34
export default function AboutMe() {
45
return (
56
<div className="flex flex-col justify-center items-center mx-auto">
67
<div className="grid w-full gap-6 sm:grid-flow-col">
7-
<div className="flex flex-col items-start justify-center gap-1.5 rounded-3xl p-6 border-[0.5px] dark:border-black-600 border-black-200 dark:bg-black-800 bg-black-100">
8-
<div className="text-5xl font-extrabold text-transparent bg-clip-text bg-gradient-to-r from-yellow-400 via-purple-500 to-green-400 dark:from-yellow-300 dark:via-purple-400 dark:to-green-300">
8+
<Squircle
9+
cornerRadius={60}
10+
cornerSmoothing={1}
11+
className="flex flex-col items-start justify-center gap-1.5 rounded-3xl p-12 border-[0.5px] dark:border-black-800 border-black-100 dark:bg-black-800 bg-gray-100"
12+
>
13+
<div className="text-5xl font-extrabold text-transparent bg-clip-text bg-gradient-to-r bg-black-900 dark:bg-black-200 ">
914
Criston Mascarenhas
1015
</div>
1116
<div className="text-sm font-medium pl-1 dark:text-black-200">
@@ -25,10 +30,25 @@ export default function AboutMe() {
2530
<div className="text-md mt-4 font-semibold italic text-gray-400">
2631
&quot;Make it work, make it right, make it fast. &quot; - Kent Beck
2732
</div>
33+
</Squircle>
34+
<div className="flex flex-col items-center justify-center gap-6">
35+
<Squircle
36+
cornerRadius={60}
37+
cornerSmoothing={1}
38+
className="border-[0.5px] dark:border-black-800 border-black-100 dark:bg-black-800 bg-gray-100"
39+
>
40+
<Picture
41+
className="w-full h-full"
42+
alt="Criston Mascarenhas"
43+
width={160}
44+
height={160}
45+
src="https://dqy38fnwh4fqs.cloudfront.net/UHBADP79DNJ867R3OQJ8RMR8A7N6/hbadp79dnj867r3oqj8rmr8a7n6-profile.webp"
46+
/>
47+
</Squircle>
2848
</div>
29-
<div className="hidden md:block border-[0.5px] h-40 sm:h-auto dark:border-black-600 border-black-200 rounded-3xl bg-[conic-gradient(var(--tw-gradient-stops))] from-yellow-600 to-black-100"></div>
49+
{/* <div className="hidden md:block border-[0.5px] h-40 sm:h-auto dark:border-black-600 border-black-200 rounded-3xl bg-[conic-gradient(var(--tw-gradient-stops))] from-yellow-600 to-black-100"></div>
3050
<div className="hidden md:block border-[0.5px] h-40 sm:h-auto dark:border-black-600 border-black-200 rounded-3xl bg-[conic-gradient(var(--tw-gradient-stops))] from-purple-600 to-black-100"></div>
31-
<div className="hidden md:block border-[0.5px] h-40 sm:h-auto dark:border-black-600 border-black-200 rounded-3xl bg-[conic-gradient(var(--tw-gradient-stops))] from-green-600 to-black-100"></div>
51+
<div className="hidden md:block border-[0.5px] h-40 sm:h-auto dark:border-black-600 border-black-200 rounded-3xl bg-[conic-gradient(var(--tw-gradient-stops))] from-green-600 to-black-100"></div> */}
3252
</div>
3353
</div>
3454
)

components/box.tsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
import { Squircle } from "@squircle-js/react";
12
import { t } from "lib";
23

34
interface IBox {

components/button.tsx

Lines changed: 14 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,25 @@
1+
import { Squircle } from "@squircle-js/react";
12
import { PropsWithChildren } from "react";
23

34
interface IButton {
45
onClick: () => void;
56
}
67

8+
79
export default function Button(props: PropsWithChildren<IButton>) {
810
const { children, onClick } = props;
911
return (
10-
<button
11-
className="border-none bg-brand-100 hover:bg-brand-200 dark:bg-black-800 hover:dark:bg-black-600 p-2 rounded-xl transition duration-700 ease-in-out"
12-
onClick={onClick}
12+
<Squircle
13+
cornerRadius={10}
14+
cornerSmoothing={1}
15+
className="p-4 bg-black text-white"
1316
>
14-
{children}
15-
</button>
16-
);
17+
<button
18+
className="border-none bg-brand-100 hover:bg-brand-200 dark:bg-black-800 hover:dark:bg-black-600 p-2 rounded-xl transition duration-700 ease-in-out"
19+
onClick={onClick}
20+
>
21+
{children}
22+
</button>
23+
</Squircle>
24+
)
1725
}

components/experience-section.tsx

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
import {PropsWithChildren} from 'react'
22
import {Box, Link, Picture} from 'components'
33
import {t} from 'lib'
4+
import {Squircle} from '@squircle-js/react'
45

56
interface IInfo {
67
place?: string
@@ -55,9 +56,11 @@ export default function Experience(props: PropsWithChildren<IExperiences>) {
5556
</div>
5657
<div className="mt-6 grid grid-cols-1 gap-6 sm:grid-cols-3">
5758
{exp.info.map((exp, idx) => (
58-
<div
59+
<Squircle
60+
cornerRadius={40}
61+
cornerSmoothing={1}
5962
key={idx}
60-
className="break-words p-6 rounded-3xl border-[0.5px] dark:border-black-600 border-black-200 dark:bg-black-800 bg-black-100 flex items-center"
63+
className="break-words p-6 rounded-3xl border-[1px] dark:border-black-800 border-black-100 dark:bg-black-800 bg-gray-100 flex items-center "
6164
>
6265
<div className="flex flex-col gap-6">
6366
<div className="w-20 h-20 rounded-full">
@@ -110,7 +113,7 @@ export default function Experience(props: PropsWithChildren<IExperiences>) {
110113
</div>
111114
</div>
112115
</div>
113-
</div>
116+
</Squircle>
114117
))}
115118
</div>
116119
</div>

components/footer.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ export default function Footer() {
3535
<div className="hover:animate-jelly">
3636
<Link
3737
href="https://github.com/crstnmac"
38-
className="font-extrabold text-transparent text-2xl bg-clip-text bg-gradient-to-r from-yellow-300 via-purple-400 to-green-300 "
38+
className="font-extrabold text-transparent text-2xl bg-clip-text bg-gradient-to-r bg-black-900 dark:bg-black-200"
3939
>
4040
crstnmac
4141
</Link>

components/header.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ export default function Header() {
1818
<div className="flex items-center hover:animate-jelly">
1919
<Link
2020
href="/"
21-
className="font-extrabold text-transparent text-2xl bg-clip-text bg-gradient-to-r from-yellow-400 via-purple-500 to-green-400 dark:from-yellow-300 dark:via-purple-400 dark:to-green-300 animate-jelly flex flex-row flex-nowrap items-center justify-start"
21+
className="font-extrabold text-transparent text-2xl bg-clip-text bg-gradient-to-r bg-black-900 dark:bg-black-200 animate-jelly flex flex-row flex-nowrap items-center justify-start"
2222
>
2323
crstnmac
2424
</Link>

components/icons/moon.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ export default function Moon() {
1717
>
1818
<motion.path
1919
d="M 43.81 29.354 C 43.688 28.958 43.413 28.626 43.046 28.432 C 42.679 28.238 42.251 28.198 41.854 28.321 C 36.161 29.886 30.067 28.272 25.894 24.096 C 21.722 19.92 20.113 13.824 21.683 8.133 C 21.848 7.582 21.697 6.985 21.29 6.578 C 20.884 6.172 20.287 6.022 19.736 6.187 C 10.659 8.728 4.691 17.389 5.55 26.776 C 6.408 36.163 13.847 43.598 23.235 44.451 C 32.622 45.304 41.28 39.332 43.816 30.253 C 43.902 29.96 43.9 29.647 43.81 29.354 Z"
20-
fill="currentColor"
20+
fill="#000000"
2121
initial="initial"
2222
animate="animate"
2323
whileTap="whileTap"

components/snippet-section.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ export default function BlogSection({snippets}: {snippets: Snippet[]}) {
1616
{snippets.map((b) => (
1717
<div
1818
key={b._id}
19-
className="group p-2 w-full sm:w-[330px] flex-none rounded-2xl bg-black-200 dark:bg-black-800 transition duration-700 ease-in-out"
19+
className="group p-2 w-full sm:w-[330px] flex-none rounded-2xl border-black-800 dark:border-black-200 bg-black-100 dark:bg-black-800 transition duration-700 ease-in-out"
2020
>
2121
<Link
2222
href={`/snippets/${b.slugAsParams}`}

0 commit comments

Comments
 (0)