Compare commits
6 Commits
Author | SHA1 | Date | |
---|---|---|---|
87fbfe4940 | |||
271aa60247 | |||
ba34e314c9 | |||
f41bc644b1 | |||
a18cec4826 | |||
61e589f0f4 |
@ -4,12 +4,7 @@
|
||||
"parserOptions": {
|
||||
"project": "./tsconfig.json"
|
||||
},
|
||||
"env": {
|
||||
"node": true,
|
||||
"browser": true
|
||||
},
|
||||
"rules": {
|
||||
"prettier/prettier": "error",
|
||||
"@next/next/no-img-element": "off"
|
||||
"prettier/prettier": "error"
|
||||
}
|
||||
}
|
||||
|
@ -1,4 +1,4 @@
|
||||
<h1 align="center"><a href="https://divlo.fr/">Divlo</a></h1>
|
||||
<h1 align="center"><a href="https://divlo.fr/">Théo LUDWIG (Divlo)</a></h1>
|
||||
|
||||
<p align="center">
|
||||
<strong>Developer Full Stack • Open-Source enthusiast</strong>
|
||||
@ -21,9 +21,9 @@
|
||||
|
||||
```json
|
||||
{
|
||||
"name": "Divlo",
|
||||
"name": "Théo LUDWIG (Divlo)",
|
||||
"pronouns": "He/Him",
|
||||
"birthDate": "31/03/2003",
|
||||
"birthdate": "31/03/2003",
|
||||
"nationality": "Alsace, France",
|
||||
"interests": ["Open-Source enthusiast", "Passionate about High-Tech"],
|
||||
"skills": {
|
||||
|
@ -21,7 +21,7 @@ export const Footer: React.FC<FooterProps> = (props) => {
|
||||
href='/'
|
||||
className='text-yellow hover:underline dark:text-yellow-dark'
|
||||
>
|
||||
Divlo
|
||||
Théo LUDWIG (Divlo)
|
||||
</Link>{' '}
|
||||
| {t('common:all-rights-reserved')}
|
||||
</p>
|
||||
|
@ -9,9 +9,9 @@ interface HeadProps {
|
||||
|
||||
export const Head: React.FC<HeadProps> = (props) => {
|
||||
const {
|
||||
title = 'Divlo',
|
||||
image = 'https://divlo.fr/images/icons/icon-96x96.png',
|
||||
description = 'Divlo - Developer Full Stack • Passionate about High-Tech',
|
||||
title = 'Théo LUDWIG (Divlo)',
|
||||
image = 'https://divlo.fr/images/icon-96x96.png',
|
||||
description = 'Théo LUDWIG (Divlo) - Developer Full Stack • Passionate about High-Tech',
|
||||
url = 'https://divlo.fr/'
|
||||
} = props
|
||||
|
||||
@ -23,7 +23,7 @@ export const Head: React.FC<HeadProps> = (props) => {
|
||||
{/* Meta Tag */}
|
||||
<meta name='viewport' content='width=device-width, initial-scale=1.0' />
|
||||
<meta name='description' content={description} />
|
||||
<meta name='Language' content='fr, en' />
|
||||
<meta name='Language' content='fr-FR, en-US' />
|
||||
<meta name='theme-color' content='#ffd800' />
|
||||
|
||||
{/* Open Graph Metadata */}
|
||||
@ -32,7 +32,7 @@ export const Head: React.FC<HeadProps> = (props) => {
|
||||
<meta property='og:url' content={url} />
|
||||
<meta property='og:image' content={image} />
|
||||
<meta property='og:description' content={description} />
|
||||
<meta property='og:locale' content='fr_FR, en_US' />
|
||||
<meta property='og:locale' content='fr-FR, en-US' />
|
||||
<meta property='og:site_name' content={title} />
|
||||
|
||||
{/* Twitter card Metadata */}
|
||||
@ -46,12 +46,6 @@ export const Head: React.FC<HeadProps> = (props) => {
|
||||
name='google-site-verification'
|
||||
content='j9CQEbSuYydXytr6gdkTfam_xX_pU97NSpVH3Bq-6f4'
|
||||
/>
|
||||
|
||||
{/* PWA Data */}
|
||||
<link rel='manifest' href='/manifest.json' />
|
||||
<meta name='apple-mobile-web-app-capable' content='yes' />
|
||||
<meta name='mobile-web-app-capable' content='yes' />
|
||||
<link rel='apple-touch-icon' href={image} />
|
||||
</NextHead>
|
||||
)
|
||||
}
|
||||
|
@ -21,9 +21,10 @@ export const Header: React.FC<HeaderProps> = (props) => {
|
||||
height={60}
|
||||
src='/images/divlo_icon_small.png'
|
||||
alt='Divlo'
|
||||
priority
|
||||
/>
|
||||
<strong className='ml-1 hidden font-headline font-semibold text-yellow dark:text-yellow-dark xs:block'>
|
||||
Divlo
|
||||
Théo LUDWIG (Divlo)
|
||||
</strong>
|
||||
</div>
|
||||
</Link>
|
||||
@ -37,7 +38,7 @@ export const Header: React.FC<HeaderProps> = (props) => {
|
||||
Blog
|
||||
</Link>
|
||||
</div>
|
||||
{showLanguage && <Language />}
|
||||
{showLanguage ? <Language /> : null}
|
||||
<SwitchTheme />
|
||||
</div>
|
||||
</header>
|
||||
|
@ -6,7 +6,7 @@ export const ProfileDescriptionBottom: React.FC = () => {
|
||||
return (
|
||||
<p className='mb-8 mt-8 text-base font-normal text-gray dark:text-gray-dark'>
|
||||
{t('home:about.description-bottom')}
|
||||
{lang === 'fr' && (
|
||||
{lang === 'fr' ? (
|
||||
<>
|
||||
<br />
|
||||
<br />
|
||||
@ -17,7 +17,7 @@ export const ProfileDescriptionBottom: React.FC = () => {
|
||||
Curriculum vitæ
|
||||
</a>
|
||||
</>
|
||||
)}
|
||||
) : null}
|
||||
</p>
|
||||
)
|
||||
}
|
||||
|
@ -5,11 +5,8 @@ export const ProfileInformation: React.FC = () => {
|
||||
|
||||
return (
|
||||
<div className='mb-6 border-b-2 border-gray-600 pb-2 font-headline dark:border-gray-400'>
|
||||
<h1 className='mb-2 text-4xl'>
|
||||
{t('home:about.i-am')}{' '}
|
||||
<strong className='font-semibold text-yellow dark:text-yellow-dark'>
|
||||
Divlo
|
||||
</strong>
|
||||
<h1 className='mb-2 text-4xl font-semibold text-yellow dark:text-yellow-dark'>
|
||||
Théo LUDWIG (Divlo)
|
||||
</h1>
|
||||
<h2 className='mb-3 text-base'>{t('home:about.description')}</h2>
|
||||
</div>
|
||||
|
@ -1,7 +1,7 @@
|
||||
import useTranslation from 'next-translate/useTranslation'
|
||||
import { useMemo } from 'react'
|
||||
|
||||
import { DIVLO_BIRTHDAY, DIVLO_BIRTHDAY_DATE, getAge } from 'utils/getAge'
|
||||
import { DIVLO_BIRTH_DATE, DIVLO_BIRTH_DATE_STRING, getAge } from 'utils/getAge'
|
||||
|
||||
import { ProfileItem } from './ProfileItem'
|
||||
|
||||
@ -9,15 +9,20 @@ export const ProfileList: React.FC = () => {
|
||||
const { t } = useTranslation('home')
|
||||
|
||||
const age = useMemo(() => {
|
||||
return getAge(DIVLO_BIRTHDAY)
|
||||
return getAge(DIVLO_BIRTH_DATE)
|
||||
}, [])
|
||||
|
||||
return (
|
||||
<ul className='m-0 list-none p-0'>
|
||||
<ProfileItem title={t('home:about.full-name')} value='Théo LUDWIG' />
|
||||
<ProfileItem
|
||||
title={t('home:about.pronouns')}
|
||||
value={t('home:about.pronouns-value')}
|
||||
/>
|
||||
<ProfileItem
|
||||
title={t('home:about.birth-date')}
|
||||
value={`${DIVLO_BIRTHDAY_DATE} (${age} ${t('home:about.years-old')})`}
|
||||
value={`${DIVLO_BIRTH_DATE_STRING} (${age} ${t(
|
||||
'home:about.years-old'
|
||||
)})`}
|
||||
/>
|
||||
<ProfileItem title={t('home:about.nationality')} value='Alsace, France' />
|
||||
<ProfileItem
|
||||
|
@ -23,7 +23,9 @@ export const Section: React.FC<SectionProps> = (props) => {
|
||||
<div className='w-full px-3'>
|
||||
<ShadowContainer style={{ marginTop: 50 }}>
|
||||
<section {...rest}>
|
||||
{heading != null && <SectionHeading>{heading}</SectionHeading>}
|
||||
{heading != null ? (
|
||||
<SectionHeading>{heading}</SectionHeading>
|
||||
) : null}
|
||||
<div className='w-full px-3'>{children}</div>
|
||||
</section>
|
||||
</ShadowContainer>
|
||||
@ -34,7 +36,7 @@ export const Section: React.FC<SectionProps> = (props) => {
|
||||
if (withoutShadowContainer) {
|
||||
return (
|
||||
<section {...rest}>
|
||||
{heading != null && <SectionHeading>{heading}</SectionHeading>}
|
||||
{heading != null ? <SectionHeading>{heading}</SectionHeading> : null}
|
||||
<div className='w-full px-3'>{children}</div>
|
||||
</section>
|
||||
)
|
||||
@ -42,16 +44,18 @@ export const Section: React.FC<SectionProps> = (props) => {
|
||||
|
||||
return (
|
||||
<section {...rest}>
|
||||
{heading != null && (
|
||||
<SectionHeading style={{ ...(description != null && { margin: 0 }) }}>
|
||||
{heading != null ? (
|
||||
<SectionHeading
|
||||
style={{ ...(description != null ? { margin: 0 } : {}) }}
|
||||
>
|
||||
{heading}
|
||||
</SectionHeading>
|
||||
)}
|
||||
{description != null && (
|
||||
) : null}
|
||||
{description != null ? (
|
||||
<p style={{ marginTop: 7 }} className='text-center'>
|
||||
{description}
|
||||
</p>
|
||||
)}
|
||||
) : null}
|
||||
<div className='w-full px-3'>
|
||||
<ShadowContainer>
|
||||
<div className='w-full px-16 py-4 leading-8'>{children}</div>
|
||||
|
@ -38,7 +38,7 @@ describe('Common > Header', () => {
|
||||
|
||||
describe('Switch Language', () => {
|
||||
it('should switch language from EN (default) to FR', () => {
|
||||
cy.get('h1').contains('I am Divlo')
|
||||
cy.get('h1').contains('Divlo')
|
||||
cy.get('[data-cy=language-flag-text]').contains('EN')
|
||||
cy.get('[data-cy=languages-list]').should('not.be.visible')
|
||||
cy.get('[data-cy=language-click]').click()
|
||||
@ -46,7 +46,7 @@ describe('Common > Header', () => {
|
||||
cy.get('[data-cy=languages-list] > li:first-child').contains('FR').click()
|
||||
cy.get('[data-cy=languages-list]').should('not.be.visible')
|
||||
cy.get('[data-cy=language-flag-text]').contains('FR')
|
||||
cy.get('h1').contains('Je suis Divlo')
|
||||
cy.get('h1').contains('Divlo')
|
||||
})
|
||||
|
||||
it('should close the language list menu when clicking outside', () => {
|
||||
|
@ -1,5 +1,5 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="fr">
|
||||
<html lang="fr-FR">
|
||||
<head>
|
||||
<meta charset="UTF-8" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
||||
|
40
jsonresume-theme-custom/package-lock.json
generated
@ -12,9 +12,9 @@
|
||||
"modern-normalize": "2.0.0"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@types/node": "20.2.1",
|
||||
"@types/node": "20.2.5",
|
||||
"date-and-time": "3.0.0",
|
||||
"vite": "4.3.8",
|
||||
"vite": "4.3.9",
|
||||
"vite-plugin-html": "3.2.0"
|
||||
}
|
||||
},
|
||||
@ -483,9 +483,9 @@
|
||||
}
|
||||
},
|
||||
"node_modules/@types/node": {
|
||||
"version": "20.2.1",
|
||||
"resolved": "https://registry.npmjs.org/@types/node/-/node-20.2.1.tgz",
|
||||
"integrity": "sha512-DqJociPbZP1lbZ5SQPk4oag6W7AyaGMO6gSfRwq3PWl4PXTwJpRQJhDq4W0kzrg3w6tJ1SwlvGZ5uKFHY13LIg==",
|
||||
"version": "20.2.5",
|
||||
"resolved": "https://registry.npmjs.org/@types/node/-/node-20.2.5.tgz",
|
||||
"integrity": "sha512-JJulVEQXmiY9Px5axXHeYGLSjhkZEnD+MDPDGbCbIAbMslkKwmygtZFy1X6s/075Yo94sf8GuSlFfPzysQrWZQ==",
|
||||
"dev": true
|
||||
},
|
||||
"node_modules/acorn": {
|
||||
@ -1020,9 +1020,9 @@
|
||||
}
|
||||
},
|
||||
"node_modules/jake": {
|
||||
"version": "10.8.6",
|
||||
"resolved": "https://registry.npmjs.org/jake/-/jake-10.8.6.tgz",
|
||||
"integrity": "sha512-G43Ub9IYEFfu72sua6rzooi8V8Gz2lkfk48rW20vEWCGizeaEPlKB1Kh8JIA84yQbiAEfqlPmSpGgCKKxH3rDA==",
|
||||
"version": "10.8.7",
|
||||
"resolved": "https://registry.npmjs.org/jake/-/jake-10.8.7.tgz",
|
||||
"integrity": "sha512-ZDi3aP+fG/LchyBzUM804VjddnwfSfsdeYkwt8NcbKRvo4rFkjhs456iLFn3k2ZUWvNe4i48WACDbza8fhq2+w==",
|
||||
"dev": true,
|
||||
"dependencies": {
|
||||
"async": "^3.2.3",
|
||||
@ -1203,9 +1203,9 @@
|
||||
}
|
||||
},
|
||||
"node_modules/postcss": {
|
||||
"version": "8.4.23",
|
||||
"resolved": "https://registry.npmjs.org/postcss/-/postcss-8.4.23.tgz",
|
||||
"integrity": "sha512-bQ3qMcpF6A/YjR55xtoTr0jGOlnPOKAIMdOWiv0EIT6HVPEaJiJB4NLljSbiHoC2RX7DN5Uvjtpbg1NPdwv1oA==",
|
||||
"version": "8.4.24",
|
||||
"resolved": "https://registry.npmjs.org/postcss/-/postcss-8.4.24.tgz",
|
||||
"integrity": "sha512-M0RzbcI0sO/XJNucsGjvWU9ERWxb/ytp1w6dKtxTKgixdtQDq4rmx/g8W1hnaheq9jgwL/oyEdH5Bc4WwJKMqg==",
|
||||
"dev": true,
|
||||
"funding": [
|
||||
{
|
||||
@ -1270,9 +1270,9 @@
|
||||
}
|
||||
},
|
||||
"node_modules/rollup": {
|
||||
"version": "3.22.0",
|
||||
"resolved": "https://registry.npmjs.org/rollup/-/rollup-3.22.0.tgz",
|
||||
"integrity": "sha512-imsigcWor5Y/dC0rz2q0bBt9PabcL3TORry2hAa6O6BuMvY71bqHyfReAz5qyAqiQATD1m70qdntqBfBQjVWpQ==",
|
||||
"version": "3.23.0",
|
||||
"resolved": "https://registry.npmjs.org/rollup/-/rollup-3.23.0.tgz",
|
||||
"integrity": "sha512-h31UlwEi7FHihLe1zbk+3Q7z1k/84rb9BSwmBSr/XjOCEaBJ2YyedQDuM0t/kfOS0IxM+vk1/zI9XxYj9V+NJQ==",
|
||||
"dev": true,
|
||||
"bin": {
|
||||
"rollup": "dist/bin/rollup"
|
||||
@ -1349,9 +1349,9 @@
|
||||
}
|
||||
},
|
||||
"node_modules/terser": {
|
||||
"version": "5.17.4",
|
||||
"resolved": "https://registry.npmjs.org/terser/-/terser-5.17.4.tgz",
|
||||
"integrity": "sha512-jcEKZw6UPrgugz/0Tuk/PVyLAPfMBJf5clnGueo45wTweoV8yh7Q7PEkhkJ5uuUbC7zAxEcG3tqNr1bstkQ8nw==",
|
||||
"version": "5.17.6",
|
||||
"resolved": "https://registry.npmjs.org/terser/-/terser-5.17.6.tgz",
|
||||
"integrity": "sha512-V8QHcs8YuyLkLHsJO5ucyff1ykrLVsR4dNnS//L5Y3NiSXpbK1J+WMVUs67eI0KTxs9JtHhgEQpXQVHlHI92DQ==",
|
||||
"dev": true,
|
||||
"dependencies": {
|
||||
"@jridgewell/source-map": "^0.3.2",
|
||||
@ -1400,9 +1400,9 @@
|
||||
}
|
||||
},
|
||||
"node_modules/vite": {
|
||||
"version": "4.3.8",
|
||||
"resolved": "https://registry.npmjs.org/vite/-/vite-4.3.8.tgz",
|
||||
"integrity": "sha512-uYB8PwN7hbMrf4j1xzGDk/lqjsZvCDbt/JC5dyfxc19Pg8kRm14LinK/uq+HSLNswZEoKmweGdtpbnxRtrAXiQ==",
|
||||
"version": "4.3.9",
|
||||
"resolved": "https://registry.npmjs.org/vite/-/vite-4.3.9.tgz",
|
||||
"integrity": "sha512-qsTNZjO9NoJNW7KnOrgYwczm0WctJ8m/yqYAMAK9Lxt4SoySUfS5S8ia9K7JHpa3KEeMfyF8LoJ3c5NeBJy6pg==",
|
||||
"dev": true,
|
||||
"dependencies": {
|
||||
"esbuild": "^0.17.5",
|
||||
|
@ -13,9 +13,9 @@
|
||||
"modern-normalize": "2.0.0"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@types/node": "20.2.1",
|
||||
"@types/node": "20.2.5",
|
||||
"date-and-time": "3.0.0",
|
||||
"vite": "4.3.8",
|
||||
"vite": "4.3.9",
|
||||
"vite-plugin-html": "3.2.0"
|
||||
}
|
||||
}
|
||||
|
@ -1,5 +1,5 @@
|
||||
import { DIVLO_BIRTHDAY, getAge } from '../../utils/getAge.ts'
|
||||
import { DIVLO_BIRTH_DATE, getAge } from '../../utils/getAge.ts'
|
||||
|
||||
const yearOld = document.getElementById('year-old')
|
||||
|
||||
yearOld.textContent = getAge(DIVLO_BIRTHDAY).toString()
|
||||
yearOld.textContent = getAge(DIVLO_BIRTH_DATE).toString()
|
||||
|
@ -1,8 +1,8 @@
|
||||
{
|
||||
"about": {
|
||||
"i-am": "I am",
|
||||
"description": "Developer Full Stack • Open-Source enthusiast",
|
||||
"full-name": "Full name",
|
||||
"pronouns": "Pronouns",
|
||||
"pronouns-value": "He/Him",
|
||||
"birth-date": "Birth date",
|
||||
"years-old": "years old",
|
||||
"nationality": "Nationality",
|
||||
|
@ -1,8 +1,8 @@
|
||||
{
|
||||
"about": {
|
||||
"i-am": "Je suis",
|
||||
"description": "Développeur Full Stack • Enthousiaste de l'Open-Source",
|
||||
"full-name": "Prénom NOM",
|
||||
"pronouns": "Pronoms",
|
||||
"pronouns-value": "Il/Lui",
|
||||
"birth-date": "Date de naissance",
|
||||
"years-old": "ans",
|
||||
"nationality": "Nationalité",
|
||||
|
@ -1,7 +1,3 @@
|
||||
const nextPWA = require('next-pwa')({
|
||||
disable: process.env.NODE_ENV !== 'production',
|
||||
dest: 'public'
|
||||
})
|
||||
const nextTranslate = require('next-translate-plugin')
|
||||
|
||||
/** @type {import("next").NextConfig} */
|
||||
@ -10,4 +6,4 @@ const nextConfig = {
|
||||
output: 'standalone'
|
||||
}
|
||||
|
||||
module.exports = nextTranslate(nextPWA(nextConfig))
|
||||
module.exports = nextTranslate(nextConfig)
|
||||
|
3423
package-lock.json
generated
23
package.json
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "divlo",
|
||||
"version": "2.7.0",
|
||||
"version": "2.7.2",
|
||||
"private": true,
|
||||
"repository": {
|
||||
"type": "git",
|
||||
@ -12,7 +12,7 @@
|
||||
},
|
||||
"scripts": {
|
||||
"dev": "next dev",
|
||||
"start": "next start",
|
||||
"start": "node .next/standalone/server.js",
|
||||
"build": "npm run resume:build && next build",
|
||||
"lint:commit": "commitlint",
|
||||
"lint:editorconfig": "editorconfig-checker",
|
||||
@ -30,7 +30,7 @@
|
||||
"postinstall": "husky install"
|
||||
},
|
||||
"dependencies": {
|
||||
"@fontsource/montserrat": "5.0.0",
|
||||
"@fontsource/montserrat": "5.0.1",
|
||||
"@fortawesome/fontawesome-svg-core": "6.4.0",
|
||||
"@fortawesome/free-brands-svg-icons": "6.4.0",
|
||||
"@fortawesome/free-solid-svg-icons": "6.4.0",
|
||||
@ -41,9 +41,8 @@
|
||||
"gray-matter": "4.0.3",
|
||||
"html-react-parser": "3.0.16",
|
||||
"katex": "0.16.7",
|
||||
"next": "13.4.3",
|
||||
"next": "13.4.4",
|
||||
"next-mdx-remote": "4.4.1",
|
||||
"next-pwa": "5.6.0",
|
||||
"next-themes": "0.2.1",
|
||||
"next-translate": "2.0.5",
|
||||
"react": "18.2.0",
|
||||
@ -67,16 +66,16 @@
|
||||
"@semantic-release/git": "10.0.1",
|
||||
"@tailwindcss/typography": "0.5.9",
|
||||
"@tsconfig/strictest": "2.0.1",
|
||||
"@types/node": "20.2.1",
|
||||
"@types/react": "18.2.6",
|
||||
"@types/node": "20.2.5",
|
||||
"@types/react": "18.2.7",
|
||||
"@types/unist": "2.0.6",
|
||||
"@typescript-eslint/eslint-plugin": "5.59.6",
|
||||
"@typescript-eslint/eslint-plugin": "5.59.7",
|
||||
"autoprefixer": "10.4.14",
|
||||
"cypress": "12.12.0",
|
||||
"cypress": "12.13.0",
|
||||
"editorconfig-checker": "5.0.1",
|
||||
"eslint": "8.41.0",
|
||||
"eslint-config-conventions": "9.0.0",
|
||||
"eslint-config-next": "13.4.3",
|
||||
"eslint-config-next": "13.4.4",
|
||||
"eslint-config-prettier": "8.8.0",
|
||||
"eslint-plugin-import": "2.27.5",
|
||||
"eslint-plugin-prettier": "4.2.1",
|
||||
@ -89,13 +88,13 @@
|
||||
"markdownlint-cli2": "0.7.1",
|
||||
"markdownlint-rule-relative-links": "1.2.0",
|
||||
"next-translate-plugin": "2.0.5",
|
||||
"postcss": "8.4.23",
|
||||
"postcss": "8.4.24",
|
||||
"prettier": "2.8.8",
|
||||
"prettier-plugin-tailwindcss": "0.3.0",
|
||||
"semantic-release": "21.0.2",
|
||||
"start-server-and-test": "2.0.0",
|
||||
"tailwindcss": "3.3.2",
|
||||
"typescript": "5.0.4",
|
||||
"vercel": "29.3.6"
|
||||
"vercel": "30.0.0"
|
||||
}
|
||||
}
|
||||
|
@ -13,7 +13,7 @@ const Error404: NextPage<Error404Props> = (props) => {
|
||||
|
||||
return (
|
||||
<>
|
||||
<Head title='404 | Divlo' />
|
||||
<Head title='404 | Théo LUDWIG (Divlo)' />
|
||||
<ErrorPage
|
||||
statusCode={404}
|
||||
message={t('errors:not-found')}
|
||||
|
@ -13,7 +13,7 @@ const Error500: NextPage<Error500Props> = (props) => {
|
||||
|
||||
return (
|
||||
<>
|
||||
<Head title='500 | Divlo' />
|
||||
<Head title='500 | Théo LUDWIG (Divlo)' />
|
||||
<ErrorPage
|
||||
statusCode={500}
|
||||
message={t('errors:server-error')}
|
||||
|
@ -1,4 +1,5 @@
|
||||
import type { GetStaticProps, GetStaticPaths, NextPage } from 'next'
|
||||
import Image from 'next/image'
|
||||
import { MDXRemote } from 'next-mdx-remote'
|
||||
import date from 'date-and-time'
|
||||
import Giscus from '@giscus/react'
|
||||
@ -24,56 +25,63 @@ const BlogPostPage: NextPage<BlogPostPageProps> = (props) => {
|
||||
return (
|
||||
<>
|
||||
<Head
|
||||
title={`${post.frontmatter.title} | Divlo`}
|
||||
title={`${post.frontmatter.title} | Théo LUDWIG (Divlo)`}
|
||||
description={post.frontmatter.description}
|
||||
/>
|
||||
|
||||
<Header />
|
||||
<main className='flex flex-1 flex-col flex-wrap items-center'>
|
||||
<div className='my-10 flex flex-col items-center'>
|
||||
<main className='break-wrap-words flex flex-1 flex-col flex-wrap items-center'>
|
||||
<div className='my-10 flex flex-col items-center text-center'>
|
||||
<h1 className='text-3xl font-semibold'>{post.frontmatter.title}</h1>
|
||||
<p className='mt-2' data-cy='blog-post-date'>
|
||||
{date.format(new Date(post.frontmatter.publishedOn), 'DD/MM/YYYY')}
|
||||
</p>
|
||||
</div>
|
||||
<div className='prose mb-10 px-8'>
|
||||
<MDXRemote
|
||||
{...post.source}
|
||||
components={{
|
||||
img: (properties) => {
|
||||
const { src, alt, ...props } = properties
|
||||
let source = src
|
||||
source = src?.replace('../public/', '/')
|
||||
return (
|
||||
<span className='flex flex-col items-center justify-center'>
|
||||
<img src={source} alt={alt} {...props} />
|
||||
</span>
|
||||
)
|
||||
},
|
||||
a: (props) => {
|
||||
if (props.href?.startsWith('#') ?? false) {
|
||||
return <a {...props} />
|
||||
<div className='prose mb-10'>
|
||||
<div className='px-8'>
|
||||
<MDXRemote
|
||||
{...post.source}
|
||||
components={{
|
||||
img: (properties) => {
|
||||
const { src = '', alt = 'Blog Image' } = properties
|
||||
const source = src.replace('../public/', '/')
|
||||
return (
|
||||
<span className='flex flex-col items-center justify-center'>
|
||||
<Image
|
||||
src={source}
|
||||
alt={alt}
|
||||
width={1000}
|
||||
height={1000}
|
||||
className='h-auto w-auto'
|
||||
/>
|
||||
</span>
|
||||
)
|
||||
},
|
||||
a: (props) => {
|
||||
if (props.href?.startsWith('#') ?? false) {
|
||||
return <a {...props} />
|
||||
}
|
||||
return (
|
||||
<a target='_blank' rel='noopener noreferrer' {...props} />
|
||||
)
|
||||
}
|
||||
return (
|
||||
<a target='_blank' rel='noopener noreferrer' {...props} />
|
||||
)
|
||||
}
|
||||
}}
|
||||
/>
|
||||
<Giscus
|
||||
id='comments'
|
||||
repo='Divlo/Divlo'
|
||||
repoId='MDEwOlJlcG9zaXRvcnkzNTg5NDg1NDQ='
|
||||
category='General'
|
||||
categoryId='DIC_kwDOFWUewM4CQ_WK'
|
||||
mapping='pathname'
|
||||
reactionsEnabled='1'
|
||||
emitMetadata='0'
|
||||
inputPosition='top'
|
||||
theme={theme}
|
||||
lang='en'
|
||||
loading='lazy'
|
||||
/>
|
||||
}}
|
||||
/>
|
||||
<Giscus
|
||||
id='comments'
|
||||
repo='Divlo/Divlo'
|
||||
repoId='MDEwOlJlcG9zaXRvcnkzNTg5NDg1NDQ='
|
||||
category='General'
|
||||
categoryId='DIC_kwDOFWUewM4CQ_WK'
|
||||
mapping='pathname'
|
||||
reactionsEnabled='1'
|
||||
emitMetadata='0'
|
||||
inputPosition='top'
|
||||
theme={theme}
|
||||
lang='en'
|
||||
loading='lazy'
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
</main>
|
||||
<Footer version={version} />
|
||||
|
Before Width: | Height: | Size: 7.5 KiB After Width: | Height: | Size: 7.5 KiB |
Before Width: | Height: | Size: 10 KiB |
Before Width: | Height: | Size: 12 KiB |
Before Width: | Height: | Size: 12 KiB |
Before Width: | Height: | Size: 16 KiB |
Before Width: | Height: | Size: 32 KiB |
Before Width: | Height: | Size: 49 KiB |
Before Width: | Height: | Size: 5.2 KiB |
@ -1,51 +0,0 @@
|
||||
{
|
||||
"name": "Divlo",
|
||||
"short_name": "Divlo",
|
||||
"icons": [
|
||||
{
|
||||
"src": "images/icons/icon-72x72.png",
|
||||
"sizes": "72x72",
|
||||
"type": "image/png"
|
||||
},
|
||||
{
|
||||
"src": "images/icons/icon-96x96.png",
|
||||
"sizes": "96x96",
|
||||
"type": "image/png"
|
||||
},
|
||||
{
|
||||
"src": "images/icons/icon-128x128.png",
|
||||
"sizes": "128x128",
|
||||
"type": "image/png"
|
||||
},
|
||||
{
|
||||
"src": "images/icons/icon-144x144.png",
|
||||
"sizes": "144x144",
|
||||
"type": "image/png"
|
||||
},
|
||||
{
|
||||
"src": "images/icons/icon-152x152.png",
|
||||
"sizes": "152x152",
|
||||
"type": "image/png"
|
||||
},
|
||||
{
|
||||
"src": "images/icons/icon-192x192.png",
|
||||
"sizes": "192x192",
|
||||
"type": "image/png",
|
||||
"purpose": "maskable"
|
||||
},
|
||||
{
|
||||
"src": "images/icons/icon-384x384.png",
|
||||
"sizes": "384x384",
|
||||
"type": "image/png"
|
||||
},
|
||||
{
|
||||
"src": "images/icons/icon-512x512.png",
|
||||
"sizes": "512x512",
|
||||
"type": "image/png"
|
||||
}
|
||||
],
|
||||
"theme_color": "#ffd800",
|
||||
"background_color": "#181818",
|
||||
"start_url": "/",
|
||||
"display": "standalone"
|
||||
}
|
@ -2,8 +2,13 @@
|
||||
@tailwind components;
|
||||
@tailwind utilities;
|
||||
|
||||
.break-wrap-words {
|
||||
word-wrap: break-word;
|
||||
word-break: break-word;
|
||||
}
|
||||
|
||||
.prose {
|
||||
@apply !max-w-4xl text-gray dark:text-gray-300;
|
||||
@apply !max-w-5xl text-gray dark:text-gray-300;
|
||||
}
|
||||
|
||||
.prose a,
|
||||
@ -28,8 +33,6 @@
|
||||
}
|
||||
.shiki {
|
||||
white-space: pre-wrap !important;
|
||||
word-break: normal !important;
|
||||
word-wrap: normal;
|
||||
}
|
||||
code {
|
||||
counter-reset: step;
|
||||
@ -43,4 +46,12 @@ code .line::before {
|
||||
display: inline-block;
|
||||
text-align: right;
|
||||
color: rgba(133, 133, 133, 0.8);
|
||||
word-wrap: normal;
|
||||
word-break: normal;
|
||||
}
|
||||
|
||||
.katex .base {
|
||||
display: inline !important;
|
||||
white-space: normal !important;
|
||||
width: 100% !important;
|
||||
}
|
||||
|
@ -1,11 +1,11 @@
|
||||
export const DIVLO_BIRTHDAY_DAY = '31' as const
|
||||
export const DIVLO_BIRTHDAY_MONTH = '03' as const
|
||||
export const DIVLO_BIRTHDAY_YEAR = '2003' as const
|
||||
export const DIVLO_BIRTHDAY_DATE =
|
||||
`${DIVLO_BIRTHDAY_DAY}/${DIVLO_BIRTHDAY_MONTH}/${DIVLO_BIRTHDAY_YEAR}` as const
|
||||
export const DIVLO_BIRTHDAY_DATE_ISO_8061 =
|
||||
`${DIVLO_BIRTHDAY_YEAR}-${DIVLO_BIRTHDAY_MONTH}-${DIVLO_BIRTHDAY_DAY}` as const
|
||||
export const DIVLO_BIRTHDAY = new Date(DIVLO_BIRTHDAY_DATE_ISO_8061)
|
||||
export const DIVLO_BIRTH_DATE_DAY = '31' as const
|
||||
export const DIVLO_BIRTH_DATE_MONTH = '03' as const
|
||||
export const DIVLO_BIRTH_DATE_YEAR = '2003' as const
|
||||
export const DIVLO_BIRTH_DATE_STRING =
|
||||
`${DIVLO_BIRTH_DATE_DAY}/${DIVLO_BIRTH_DATE_MONTH}/${DIVLO_BIRTH_DATE_YEAR}` as const
|
||||
export const DIVLO_BIRTH_DATE_ISO_8601 =
|
||||
`${DIVLO_BIRTH_DATE_YEAR}-${DIVLO_BIRTH_DATE_MONTH}-${DIVLO_BIRTH_DATE_DAY}` as const
|
||||
export const DIVLO_BIRTH_DATE = new Date(DIVLO_BIRTH_DATE_ISO_8601)
|
||||
|
||||
/**
|
||||
* Calculates the age of a person based on their birth date
|
||||
|