imported highlight.js theme css using postcss & tailwindcss

This commit is contained in:
Suyono 2024-05-10 19:22:12 +10:00
parent d7a9fb6a8c
commit 552c99bfe7
5 changed files with 45 additions and 41 deletions

View File

@ -1,2 +0,0 @@
nodejs 20.12.2
pnpm 9.0.6

View File

@ -1,3 +1,5 @@
@tailwind base;
@tailwind components;
@tailwind utilities;
@import "tailwindcss/base";
@import "tailwindcss/components";
@import "tailwindcss/utilities";
@import "highlight.js/styles/base16/atelier-forest-light.min.css";

View File

@ -14,8 +14,8 @@ export default async function Mark() {
.use(remarkParse)
.use(remarkGfm)
.use(remarkRehype)
.use(rehypeHighlight)
.use(rehypeSanitize)
.use(rehypeHighlight)
.use(rehypeReact, {
Fragment: Fragment,
jsx: jsx,

View File

@ -14,16 +14,17 @@
"@types/node": "20.6.5",
"@types/react": "18.3.1",
"@types/react-dom": "18.3.0",
"autoprefixer": "10.4.16",
"autoprefixer": "10.4.19",
"bright": "^0.8.5",
"dompurify": "^3.1.2",
"eslint": "8.57.0",
"eslint-config-next": "14.2.3",
"highlight.js": "^11.9.0",
"html-react-parser": "^4.2.10",
"jsdom": "^22.1.0",
"mysql2": "^3.9.7",
"next": "14.2.3",
"postcss": "8.4.30",
"postcss": "8.4.38",
"react": "18.3.1",
"react-dom": "18.3.1",
"react-remark": "^2.1.0",
@ -36,7 +37,7 @@
"remark-parse": "^11.0.0",
"remark-rehype": "^11.1.0",
"sharp": "^0.33.3",
"tailwindcss": "3.3.3",
"tailwindcss": "3.4.3",
"typescript": "5.2.2",
"unified": "^11.0.4"
},

67
pnpm-lock.yaml generated
View File

@ -24,8 +24,8 @@ importers:
specifier: 18.3.0
version: 18.3.0
autoprefixer:
specifier: 10.4.16
version: 10.4.16(postcss@8.4.30)
specifier: 10.4.19
version: 10.4.19(postcss@8.4.38)
bright:
specifier: ^0.8.5
version: 0.8.5(react@18.3.1)
@ -38,6 +38,9 @@ importers:
eslint-config-next:
specifier: 14.2.3
version: 14.2.3(eslint@8.57.0)(typescript@5.2.2)
highlight.js:
specifier: ^11.9.0
version: 11.9.0
html-react-parser:
specifier: ^4.2.10
version: 4.2.10(react@18.3.1)
@ -51,8 +54,8 @@ importers:
specifier: 14.2.3
version: 14.2.3(react-dom@18.3.1(react@18.3.1))(react@18.3.1)
postcss:
specifier: 8.4.30
version: 8.4.30
specifier: 8.4.38
version: 8.4.38
react:
specifier: 18.3.1
version: 18.3.1
@ -90,8 +93,8 @@ importers:
specifier: ^0.33.3
version: 0.33.3
tailwindcss:
specifier: 3.3.3
version: 3.3.3
specifier: 3.4.3
version: 3.4.3
typescript:
specifier: 5.2.2
version: 5.2.2
@ -590,8 +593,8 @@ packages:
asynckit@0.4.0:
resolution: {integrity: sha512-Oei9OH4tRh0YqU3GxhX79dM/mwVgvbZJaSNaRk+bshkj0S5cfHcgYakreBjrHwatXKbz+IoIdYLxrKim2MjW0Q==}
autoprefixer@10.4.16:
resolution: {integrity: sha512-7vd3UC6xKp0HLfua5IjZlcXvGAGy7cBAXTg2lyQ/8WpNhd6SiZ8Be+xm3FyBSYJx5GKcpRCzBh7RH4/0dnY+uQ==}
autoprefixer@10.4.19:
resolution: {integrity: sha512-BaENR2+zBZ8xXhM4pUaKUxlVdxZ0EZhjvbopwnXmxRUfqDmwSpC2lAi/QXvx7NRdPCo1WKEcEF6mV64si1z4Ew==}
engines: {node: ^10 || ^12 || >=14}
hasBin: true
peerDependencies:
@ -1929,14 +1932,14 @@ packages:
postcss-value-parser@4.2.0:
resolution: {integrity: sha512-1NNCs6uurfkVbeXG4S8JFT9t19m45ICnif8zWLd5oPSZ50QnwMfK+H3jv408d4jw/7Bttv5axS5IiHoLaVNHeQ==}
postcss@8.4.30:
resolution: {integrity: sha512-7ZEao1g4kd68l97aWG/etQKPKq07us0ieSZ2TnFDk11i0ZfDW2AwKHYU8qv4MZKqN2fdBfg+7q0ES06UA73C1g==}
engines: {node: ^10 || ^12 || >=14}
postcss@8.4.31:
resolution: {integrity: sha512-PS08Iboia9mts/2ygV3eLpY5ghnUcfLV/EXTOW1E2qYxJKGGBUtNjN76FYHnMs36RmARn41bC0AZmn+rR0OVpQ==}
engines: {node: ^10 || ^12 || >=14}
postcss@8.4.38:
resolution: {integrity: sha512-Wglpdk03BSfXkHoQa3b/oulrotAkwrlLDRSOb9D0bN86FdRyE9lppSp33aHNPgBa0JKCoB+drFLZkQoRRYae5A==}
engines: {node: ^10 || ^12 || >=14}
prelude-ls@1.2.1:
resolution: {integrity: sha512-vkcDPrRZo1QZLbn5RLGPpg/WmIQ65qoWWhcGKf/b5eplkkarX0m9z8ppCat4mlOqUsWpyNuYgO3VRyrYHSzX5g==}
engines: {node: '>= 0.8.0'}
@ -2241,8 +2244,8 @@ packages:
symbol-tree@3.2.4:
resolution: {integrity: sha512-9QNk5KwDF+Bvz+PyObkmSYjI5ksVUYtjW7AU22r2NKcfLJcXp96hkDWU3+XndOsUb+AQ9QhfzfCT2O+CNWT5Tw==}
tailwindcss@3.3.3:
resolution: {integrity: sha512-A0KgSkef7eE4Mf+nKJ83i75TMyq8HqY3qmFIJSWy8bNt0v1lG7jUcpGpoTFxAwYcWOphcTBLPPJg+bDfhDf52w==}
tailwindcss@3.4.3:
resolution: {integrity: sha512-U7sxQk/n397Bmx4JHbJx/iSOOv5G+II3f1kpLpY2QeUv5DcPdcTsYLlusZfq1NthHS1c1cZoyFmmkex1rzke0A==}
engines: {node: '>=14.0.0'}
hasBin: true
@ -2981,14 +2984,14 @@ snapshots:
asynckit@0.4.0: {}
autoprefixer@10.4.16(postcss@8.4.30):
autoprefixer@10.4.19(postcss@8.4.38):
dependencies:
browserslist: 4.23.0
caniuse-lite: 1.0.30001615
fraction.js: 4.3.7
normalize-range: 0.1.2
picocolors: 1.0.0
postcss: 8.4.30
postcss: 8.4.38
postcss-value-parser: 4.2.0
available-typed-arrays@1.0.7:
@ -4762,28 +4765,28 @@ snapshots:
possible-typed-array-names@1.0.0: {}
postcss-import@15.1.0(postcss@8.4.30):
postcss-import@15.1.0(postcss@8.4.38):
dependencies:
postcss: 8.4.30
postcss: 8.4.38
postcss-value-parser: 4.2.0
read-cache: 1.0.0
resolve: 1.22.8
postcss-js@4.0.1(postcss@8.4.30):
postcss-js@4.0.1(postcss@8.4.38):
dependencies:
camelcase-css: 2.0.1
postcss: 8.4.30
postcss: 8.4.38
postcss-load-config@4.0.2(postcss@8.4.30):
postcss-load-config@4.0.2(postcss@8.4.38):
dependencies:
lilconfig: 3.1.1
yaml: 2.4.2
optionalDependencies:
postcss: 8.4.30
postcss: 8.4.38
postcss-nested@6.0.1(postcss@8.4.30):
postcss-nested@6.0.1(postcss@8.4.38):
dependencies:
postcss: 8.4.30
postcss: 8.4.38
postcss-selector-parser: 6.0.16
postcss-selector-parser@6.0.16:
@ -4793,13 +4796,13 @@ snapshots:
postcss-value-parser@4.2.0: {}
postcss@8.4.30:
postcss@8.4.31:
dependencies:
nanoid: 3.3.7
picocolors: 1.0.0
source-map-js: 1.2.0
postcss@8.4.31:
postcss@8.4.38:
dependencies:
nanoid: 3.3.7
picocolors: 1.0.0
@ -5199,7 +5202,7 @@ snapshots:
symbol-tree@3.2.4: {}
tailwindcss@3.3.3:
tailwindcss@3.4.3:
dependencies:
'@alloc/quick-lru': 5.2.0
arg: 5.0.2
@ -5215,11 +5218,11 @@ snapshots:
normalize-path: 3.0.0
object-hash: 3.0.0
picocolors: 1.0.0
postcss: 8.4.30
postcss-import: 15.1.0(postcss@8.4.30)
postcss-js: 4.0.1(postcss@8.4.30)
postcss-load-config: 4.0.2(postcss@8.4.30)
postcss-nested: 6.0.1(postcss@8.4.30)
postcss: 8.4.38
postcss-import: 15.1.0(postcss@8.4.38)
postcss-js: 4.0.1(postcss@8.4.38)
postcss-load-config: 4.0.2(postcss@8.4.38)
postcss-nested: 6.0.1(postcss@8.4.38)
postcss-selector-parser: 6.0.16
resolve: 1.22.8
sucrase: 3.35.0