Skip to content

Commit

Permalink
feat: update docs
Browse files Browse the repository at this point in the history
  • Loading branch information
Chocolate1999 committed Sep 11, 2022
1 parent 0660d30 commit bc6c003
Show file tree
Hide file tree
Showing 8 changed files with 93 additions and 26 deletions.
6 changes: 6 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,12 @@ The most beautiful minimalist blog in modern built with Nextjs and tailwindcss.

![Alt](https://repobeats.axiom.co/api/embed/0d333a7111c72a0c7ed603bfab7298225a46a856.svg 'Repobeats analytics image')

## 🧑‍💻 Contribution

Thank you to all the people who already contributed to my project!

<a href="https://github.com/Chocolate1999/nextjs-tailwind-blog/graphs/contributors"><img src="https://github.com/Chocolate1999/nextjs-tailwind-blog/blob/main/CONTRIBUTORS.svg" /></a>

## 📄 License

[MIT License](https://github.com/Chocolate1999/nextjs-tailwind-blog/blob/main/LICENSE) © 2022-PRESENT [Chocolate](https://github.com/Chocolate1999)
8 changes: 4 additions & 4 deletions src/components/layout/Footer.tsx
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import UnderlineLink from '@/components/links/UnderlineLink';
import CustomLink from '@/components/links/CustomLink';

export default function Footer() {
return (
<footer className='mt-16 text-right text-[#b3b3b3] dark:text-gray-200'>
<footer className='mt-16 text-right text-[#b3b3b3] '>
<section className='flex flex-col items-end'>
<div>
<a
Expand All @@ -22,9 +22,9 @@ export default function Footer() {
© Yang Chao Yi
</a>
</div>
<UnderlineLink href='https://beian.miit.gov.cn/'>
<CustomLink href='https://beian.miit.gov.cn/'>
湘ICP备20002952号
</UnderlineLink>
</CustomLink>
</section>
</footer>
);
Expand Down
2 changes: 1 addition & 1 deletion src/components/layout/Header.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ export default function Header() {
'sticky top-0 z-50 w-full bg-transparent',
isDocHover &&
'solid border-b border-black border-opacity-[0.12] bg-white bg-opacity-[98] backdrop-blur-[40px]',
'dark:border-b dark:border-black dark:bg-[#060807]'
'dark:border-b dark:border-black dark:bg-[#215c8c]'
)}
>
<section className='layout'>
Expand Down
4 changes: 2 additions & 2 deletions src/components/links/CustomLink.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -13,11 +13,11 @@ export default function CustomLink({
className={clsx(
'animated-underline custom-link inline-flex items-center font-medium',
'focus:outline-none focus-visible:ring focus-visible:ring-primary-300',
'border-b border-dotted border-dark hover:border-black/0',
'border-b border-dotted border-dark hover:border-black/0 dark:border-white',
className
)}
>
<span className='dark:bg-gradient-to-tr dark:from-primary-300 dark:to-primary-400 dark:bg-clip-text dark:text-transparent'>
<span className=' dark:bg-gradient-to-tr dark:from-primary-300 dark:to-primary-400 dark:bg-clip-text dark:text-[#b3b3b3]'>
{children}
</span>
</UnstyledLink>
Expand Down
2 changes: 1 addition & 1 deletion src/pages/_app.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ Router.events.on('routeChangeComplete', nProgress.done);
function MyApp({ Component, pageProps }: AppProps) {
return (
<RecoilRoot>
<ThemeProvider attribute='class' enableSystem={false}>
<ThemeProvider attribute='class' enableSystem={true}>
<Component {...pageProps} />
</ThemeProvider>
</RecoilRoot>
Expand Down
92 changes: 78 additions & 14 deletions src/pages/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -15,36 +15,100 @@ export default function HomePage() {
<Seo />
<main>
<section className={clsxm(isLoaded && 'fade-in-start')}>
<div className='mt-[120px] text-center'>
<article className='layout '>
<div className='flex flex-col items-start'>
<h2 className='text-2x dark:text-gray-100' data-fade='1'>
Hi!
</h2>
<h1 className=' mt-1 text-3xl dark:text-gray-100' data-fade='2'>
You can call me Chocolate
</h1>
<div className='mt-[120px] text-left'>
<article className=''>
<div className='mx-8 flex flex-col items-start'>
<p
className='mb-8 text-4xl text-[#555] dark:text-[#bbb]'
data-fade='1'
>
一百个Chocolate
</p>
<p
className='text-lg text-[#555] dark:text-[#bbb]'
data-fade='1'
>
Hey, I am Chocolate, the 21st front-end development, currently
moving bricks in a large factory.
</p>
<p
className={clsxm(
'mt-6 text-[#555] dark:text-[#bbb]',
'2xl:text-xl text-left text-lg'
)}
data-fade='3'
>
JS, TS, LeetCode, Vue, React, algorithm lovers.
</p>
<hr
className='mx-auto my-[2em] h-0 w-[50px] border-t-[1px] border-[#7d7d7d4d]'
data-fade='4'
/>
<p
className={clsxm(
' mt-6 max-w-2xl text-gray-700 dark:text-gray-300',
'mt-6 text-[#555] dark:text-[#bbb]',
'2xl:text-xl text-left text-lg'
)}
data-fade='3'
>
JS, TS, LeetCode, Vue, React, algorithm lovers.The 21st
front-end development, currently moving bricks in a large
factory.
After experiencing high school life, I understand that
"fortunately, the cold window has been bitter for several
years, and since then there are many warm springs"
</p>
<p
className={clsxm(
' mt-2 max-w-2xl text-gray-700 dark:text-gray-300',
'mt-6 text-[#555] dark:text-[#bbb]',
'2xl:text-xl text-left text-lg'
)}
data-fade='3'
>
And through college life, I understand that "learning is like
sailing against the current, if you don't advance, you will
retreat".
</p>
<p
className={clsxm(
'mt-6 text-[#555] dark:text-[#bbb]',
'2xl:text-xl text-left text-lg'
)}
data-fade='3'
>
The dream is to become a person with a certain influence,
sweat with blood, and create the future with positivity!
</p>
<hr
className='mx-auto my-[2em] h-0 w-[50px] border-t-[1px] border-[#7d7d7d4d]'
data-fade='4'
/>
<p
className={clsxm(
' mt-2 text-[#555] dark:text-[#bbb]',
'2xl:text-xl text-left text-lg'
)}
data-fade='4'
>
Find me on{' '}
<CustomLink href='https://github.com/Chocolate1999'>
Github
</CustomLink>{' '}
and{' '}
<CustomLink href='https://space.bilibili.com/351534170'>
哔哩哔哩
</CustomLink>
.
</p>

<p
className={clsxm(
' mt-2 text-[#555] dark:text-[#bbb]',
'2xl:text-xl text-left text-lg'
)}
data-fade='4'
>
Motto: Learning is like sailing against the current, if you
don't advance, you will retreat!
</p>

<div data-fade='5' className='mt-4 flex'>
<CustomLink href='/blog'>To Blog</CustomLink>
<CustomLink href='/about' className='ml-6'>
Expand Down
4 changes: 0 additions & 4 deletions src/styles/globals.css
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,6 @@
}
}

/* #region /**=========== Fade In =========== */
[data-fade] {
@apply translate-y-10 opacity-0 transition duration-[400ms] ease-out motion-reduce:translate-y-0 motion-reduce:opacity-100;
}
Expand Down Expand Up @@ -142,11 +141,8 @@
.fade-in-start [data-fade='8'] {
transition-delay: 800ms;
}
/* #endregion /**======== Fade In =========== */

/* #region /**=========== Animate Shadow =========== */
.animate-shadow {
@apply after:absolute after:inset-0 after:z-[-1] after:opacity-0 after:transition-opacity hover:after:opacity-100;
@apply after:shadow-md dark:after:shadow-none;
}
/* #endregion /**======== Animate Shadow =========== */
1 change: 1 addition & 0 deletions tailwind.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ const { fontFamily } = require('tailwindcss/defaultTheme');
/** @type {import('tailwindcss').Config} */
module.exports = {
content: ['./src/**/*.{js,jsx,ts,tsx}'],
darkMode: 'class',
theme: {
screens: {
mobile: {
Expand Down

0 comments on commit bc6c003

Please sign in to comment.