📝 Update style
5
.idea/.gitignore
generated
vendored
Normal file
@ -0,0 +1,5 @@
|
||||
# Default ignored files
|
||||
/shelf/
|
||||
/workspace.xml
|
||||
# Editor-based HTTP Client requests
|
||||
/httpRequests/
|
12
.idea/DefectingCat.github.io.iml
generated
Normal file
@ -0,0 +1,12 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<module type="WEB_MODULE" version="4">
|
||||
<component name="NewModuleRootManager">
|
||||
<content url="file://$MODULE_DIR$">
|
||||
<excludeFolder url="file://$MODULE_DIR$/temp" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/.tmp" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/tmp" />
|
||||
</content>
|
||||
<orderEntry type="inheritedJdk" />
|
||||
<orderEntry type="sourceFolder" forTests="false" />
|
||||
</component>
|
||||
</module>
|
6
.idea/inspectionProfiles/Project_Default.xml
generated
Normal file
@ -0,0 +1,6 @@
|
||||
<component name="InspectionProjectProfileManager">
|
||||
<profile version="1.0">
|
||||
<option name="myName" value="Project Default" />
|
||||
<inspection_tool class="Eslint" enabled="true" level="WARNING" enabled_by_default="true" />
|
||||
</profile>
|
||||
</component>
|
8
.idea/modules.xml
generated
Normal file
@ -0,0 +1,8 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project version="4">
|
||||
<component name="ProjectModuleManager">
|
||||
<modules>
|
||||
<module fileurl="file://$PROJECT_DIR$/.idea/DefectingCat.github.io.iml" filepath="$PROJECT_DIR$/.idea/DefectingCat.github.io.iml" />
|
||||
</modules>
|
||||
</component>
|
||||
</project>
|
7
.idea/prettier.xml
generated
Normal file
@ -0,0 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project version="4">
|
||||
<component name="PrettierConfiguration">
|
||||
<option name="myRunOnSave" value="true" />
|
||||
<option name="myRunOnReformat" value="true" />
|
||||
</component>
|
||||
</project>
|
6
.idea/vcs.xml
generated
Normal file
@ -0,0 +1,6 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project version="4">
|
||||
<component name="VcsDirectoryMappings">
|
||||
<mapping directory="$PROJECT_DIR$" vcs="Git" />
|
||||
</component>
|
||||
</project>
|
4
.prettierrc.json
Normal file
@ -0,0 +1,4 @@
|
||||
{
|
||||
"semi": true,
|
||||
"singleQuote": true
|
||||
}
|
@ -1,6 +1,5 @@
|
||||
import classNames from 'classnames';
|
||||
import React, { useState } from 'react';
|
||||
import { useCallback } from 'react';
|
||||
import React, { useCallback, useState } from 'react';
|
||||
import { ItemProps } from './TabItem';
|
||||
|
||||
type Props = {
|
||||
|
@ -5,10 +5,12 @@
|
||||
/* box-shadow: 0 13px 27px -5px rgb(50 50 93 / 25%),
|
||||
0 8px 16px -8px rgb(0 0 0 / 30%), 0 -6px 16px -6px rgb(0 0 0 / 3%); */
|
||||
}
|
||||
|
||||
.wrapper pre {
|
||||
margin: unset;
|
||||
border-radius: unset;
|
||||
}
|
||||
|
||||
.wrapper .loading span {
|
||||
margin: unset;
|
||||
}
|
||||
|
@ -8,7 +8,7 @@ import 'styles/rua.css';
|
||||
import { MDXProvider } from '@mdx-js/react';
|
||||
import Anchor from 'components/mdx/Anchor';
|
||||
import { useRouter } from 'next/router';
|
||||
import { useCallback, useState, useEffect } from 'react';
|
||||
import { useCallback, useEffect, useState } from 'react';
|
||||
import dynamic from 'next/dynamic';
|
||||
|
||||
const VercelLoading = dynamic(
|
||||
|
@ -1,4 +1,4 @@
|
||||
import { Html, Head, Main, NextScript } from 'next/document';
|
||||
import { Head, Html, Main, NextScript } from 'next/document';
|
||||
|
||||
export default function Document() {
|
||||
return (
|
||||
|
@ -1,13 +1,13 @@
|
||||
// Next.js API route support: https://nextjs.org/docs/api-routes/introduction
|
||||
import type { NextApiRequest, NextApiResponse } from 'next'
|
||||
import type { NextApiRequest, NextApiResponse } from 'next';
|
||||
|
||||
type Data = {
|
||||
name: string
|
||||
}
|
||||
name: string;
|
||||
};
|
||||
|
||||
export default function handler(
|
||||
req: NextApiRequest,
|
||||
res: NextApiResponse<Data>
|
||||
) {
|
||||
res.status(200).json({ name: 'John Doe' })
|
||||
res.status(200).json({ name: 'John Doe' });
|
||||
}
|
||||
|
@ -3,7 +3,7 @@ import { ReactElement } from 'react';
|
||||
import { postLists } from 'lib/posts';
|
||||
import cn from 'classnames';
|
||||
import dynamic from 'next/dynamic';
|
||||
import PostCardLoading from 'components/RUA/loading/PostCardLoading'
|
||||
import PostCardLoading from 'components/RUA/loading/PostCardLoading';
|
||||
|
||||
const PostCard = dynamic(() => import('components/PostCard'), {
|
||||
loading: () => <PostCardLoading />,
|
||||
|
@ -1,4 +1,4 @@
|
||||
import { GetStaticProps, InferGetStaticPropsType, GetStaticPaths } from 'next';
|
||||
import { GetStaticPaths, GetStaticProps, InferGetStaticPropsType } from 'next';
|
||||
import dynamic from 'next/dynamic';
|
||||
import { ReactElement } from 'react';
|
||||
import { SignalGist } from 'types';
|
||||
|
@ -4,6 +4,7 @@ date: '2022-04-06'
|
||||
tags: ['Hello world']
|
||||
---
|
||||
|
||||
|
||||
import Layout from 'layouts/MDXLayout';
|
||||
import dynamic from 'next/dynamic';
|
||||
|
||||
|
@ -4,10 +4,9 @@ date: '2022-04-13'
|
||||
tags: ['three.js', 'JavaScript']
|
||||
---
|
||||
|
||||
|
||||
import Layout from 'layouts/MDXLayout';
|
||||
import dynamic from 'next/dynamic';
|
||||
import Image from 'components/mdx/Image';
|
||||
import image1 from 'public/images/p/how-to-load-a-background-with-threejs/Skybox_example.png';
|
||||
|
||||
export const RUASandpack = dynamic(() => import('components/RUA/RUASandpack'));
|
||||
|
||||
@ -60,46 +59,46 @@ renderer.render(scene, camera);
|
||||
|
||||
Now, we can get a black canvas in our document.
|
||||
|
||||
export const main = `import { useEffect, useRef } from 'react';
|
||||
import * as THREE from 'three';
|
||||
export const main = `
|
||||
|
||||
export default function App() {
|
||||
const ref = useRef(null);
|
||||
const scene = new THREE.Scene();
|
||||
const camera = new THREE.PerspectiveCamera(
|
||||
75,
|
||||
window.innerWidth / window.innerHeight,
|
||||
0.1,
|
||||
1000
|
||||
);
|
||||
useEffect(() => {
|
||||
const renderer = new THREE.WebGLRenderer({
|
||||
canvas: ref.current,
|
||||
});
|
||||
renderer.setPixelRatio(window.devicePixelRatio);
|
||||
renderer.setSize(window.innerWidth, window.innerHeight);
|
||||
const render = (time) => {
|
||||
renderer.render(scene, camera);
|
||||
requestAnimationFrame(render);
|
||||
};
|
||||
requestAnimationFrame(render);
|
||||
function onWindowResize() {
|
||||
camera.aspect = window.innerWidth / window.innerHeight;
|
||||
camera.updateProjectionMatrix();
|
||||
renderer.setSize(window.innerWidth, window.innerHeight);
|
||||
render(0);
|
||||
}
|
||||
window.addEventListener('resize', onWindowResize);
|
||||
return () => {
|
||||
window.removeEventListener('resize', onWindowResize);
|
||||
};
|
||||
}, []);
|
||||
return (
|
||||
<>
|
||||
<canvas ref={ref}></canvas>
|
||||
</>
|
||||
)
|
||||
}`;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
`;
|
||||
|
||||
export const styles = `* {
|
||||
padding: 0;
|
||||
@ -184,67 +183,67 @@ controls.enablePan = false;
|
||||
controls.update();
|
||||
```
|
||||
|
||||
export const main2 = `import { useEffect, useRef } from "react";
|
||||
import * as THREE from "three";
|
||||
import { OrbitControls } from "three/examples/jsm/controls/OrbitControls";
|
||||
const manager = new THREE.LoadingManager();
|
||||
manager.onProgress = (item, loaded, total) => {
|
||||
console.log(loaded, total);
|
||||
};
|
||||
export const main2 = `
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
export default function App() {
|
||||
const ref = useRef(null);
|
||||
const scene = new THREE.Scene();
|
||||
const sky = new THREE.CubeTextureLoader(manager).load([
|
||||
"https://raw.githubusercontent.com/DefectingCat/three-playground/master/src/assets/first-project/skybox/corona_ft.png",
|
||||
"https://raw.githubusercontent.com/DefectingCat/three-playground/master/src/assets/first-project/skybox/corona_bk.png",
|
||||
"https://raw.githubusercontent.com/DefectingCat/three-playground/master/src/assets/first-project/skybox/corona_up.png",
|
||||
"https://raw.githubusercontent.com/DefectingCat/three-playground/master/src/assets/first-project/skybox/corona_dn.png",
|
||||
"https://raw.githubusercontent.com/DefectingCat/three-playground/master/src/assets/first-project/skybox/corona_rt.png",
|
||||
"https://raw.githubusercontent.com/DefectingCat/three-playground/master/src/assets/first-project/skybox/corona_lf.png"
|
||||
]);
|
||||
scene.background = sky;
|
||||
const camera = new THREE.PerspectiveCamera(
|
||||
75,
|
||||
window.innerWidth / window.innerHeight,
|
||||
0.1,
|
||||
1000
|
||||
);
|
||||
camera.position.set(0, 1, 0);
|
||||
camera.up.set(0, 0, 1);
|
||||
scene.add(camera);
|
||||
useEffect(() => {
|
||||
const renderer = new THREE.WebGLRenderer({
|
||||
canvas: ref.current
|
||||
});
|
||||
renderer.setPixelRatio(window.devicePixelRatio);
|
||||
renderer.setSize(window.innerWidth, window.innerHeight);
|
||||
const controls = new OrbitControls(camera, ref.current);
|
||||
controls.enablePan = false;
|
||||
controls.target.set(0, 0, 0);
|
||||
controls.update();
|
||||
const render = (time) => {
|
||||
renderer.render(scene, camera);
|
||||
requestAnimationFrame(render);
|
||||
};
|
||||
requestAnimationFrame(render);
|
||||
function onWindowResize() {
|
||||
camera.aspect = window.innerWidth / window.innerHeight;
|
||||
camera.updateProjectionMatrix();
|
||||
renderer.setSize(window.innerWidth, window.innerHeight);
|
||||
render(0);
|
||||
}
|
||||
window.addEventListener("resize", onWindowResize);
|
||||
return () => {
|
||||
window.removeEventListener("resize", onWindowResize);
|
||||
};
|
||||
}, []);
|
||||
return (
|
||||
<>
|
||||
<canvas ref={ref}></canvas>
|
||||
</>
|
||||
);
|
||||
}
|
||||
`;
|
||||
|
||||
<RUASandpack
|
||||
|
@ -4,6 +4,7 @@ date: '2022-04-14'
|
||||
tags: [Linux, Server]
|
||||
---
|
||||
|
||||
|
||||
import Layout from 'layouts/MDXLayout';
|
||||
import Image from 'components/mdx/Image';
|
||||
import image1 from 'public/images/p/my-develop-environmental/logo.svg';
|
||||
|
@ -4,6 +4,7 @@ date: '2022-04-18'
|
||||
tags: ['Next.js', 'JavaScript']
|
||||
---
|
||||
|
||||
|
||||
import Layout from 'layouts/MDXLayout';
|
||||
import dynamic from 'next/dynamic';
|
||||
import Image from 'components/mdx/Image';
|
||||
|
@ -3,4 +3,4 @@ module.exports = {
|
||||
tailwindcss: {},
|
||||
autoprefixer: {},
|
||||
},
|
||||
}
|
||||
};
|
||||
|
Before Width: | Height: | Size: 318 KiB After Width: | Height: | Size: 343 KiB |
Before Width: | Height: | Size: 61 KiB After Width: | Height: | Size: 64 KiB |
@ -1,4 +1,4 @@
|
||||
<svg xmlns="http://www.w3.org/2000/svg" version="1.1" xmlns:xlink="http://www.w3.org/1999/xlink" viewBox="0 0 800 400">
|
||||
<svg xmlns="http://www.w3.org/2000/svg" version="1.1" viewBox="0 0 800 400">
|
||||
<path
|
||||
d="M-0.597907304763794,263.6771240234375C1.6442451079686484,257.3990987141927,5.5306423107783,226.158447265625,12.85500717163086,226.00897216796875C20.179372032483418,225.8594970703125,34.379672368367515,263.0792287190755,43.34828186035156,262.7802734375C52.31689135233561,262.4813181559245,59.49177678426107,225.26158142089844,66.66666412353516,224.21524047851562C73.84155146280925,223.1688995361328,76.23318099975586,254.85798136393228,86.3976058959961,256.5022277832031C96.56203079223633,258.14647420247394,116.29297510782878,234.08071899414062,127.65321350097656,234.08071899414062C139.01345189412436,234.08071899414062,144.8430430094401,257.24961344401044,154.5590362548828,256.5022277832031C164.27502950032553,255.75484212239584,176.68160756429037,229.89535522460938,185.9491729736328,229.59640502929688C195.21673838297525,229.29745483398438,202.54110972086588,254.55904897054037,210.1644287109375,254.70852661132812C217.78774770100912,254.85800425211588,223.3183848063151,230.49327087402344,231.6890869140625,230.49327087402344C240.0597890218099,230.49327087402344,250.5231679280599,255.75486501057944,260.3886413574219,254.70852661132812C270.2541147867839,253.6621882120768,280.7175038655599,224.81314849853516,290.8819274902344,224.21524047851562C301.0463511149089,223.6173324584961,310.01494852701825,251.12107849121094,321.37518310546875,251.12107849121094C332.73541768391925,251.12107849121094,346.78623453776044,224.06576283772787,359.0433349609375,224.21524047851562C371.30043538411456,224.36471811930338,381.9132995605469,252.16741943359375,394.91778564453125,252.0179443359375C407.9222717285156,251.86846923828125,424.96262613932294,223.31838989257812,437.07025146484375,223.31838989257812C449.17787679036456,223.31838989257812,457.2496337890625,251.7189915974935,467.56353759765625,252.0179443359375C477.87744140625,252.3168970743815,487.5934346516927,224.6636759440104,498.95367431640625,225.1121063232422C510.3139139811198,225.56053670247397,526.6068929036459,255.00747934977213,535.7249755859375,254.70852661132812C544.8430582682291,254.40957387288412,546.9357198079427,223.61734517415366,553.6621704101562,223.31838989257812C560.3886210123698,223.0194346110026,567.1150716145834,253.36322530110678,576.0836791992188,252.914794921875C585.0522867838541,252.46636454264322,598.0567728678385,221.22571563720703,607.4738159179688,220.6278076171875C616.890858968099,220.02989959716797,621.2256978352865,248.13153330485025,632.5859375,249.3273468017578C643.9461771647135,250.52316029866537,666.8161214192709,228.40059407552084,675.63525390625,227.8026885986328C684.4543863932291,227.20478312174478,676.5321146647135,246.33782196044922,685.500732421875,245.7399139404297C694.4693501790365,245.14200592041016,718.2361958821615,223.46785736083984,729.4469604492188,224.21524047851562C740.657725016276,224.9626235961914,742.7503763834635,249.32735188802084,752.7653198242188,250.22421264648438C762.780263264974,251.1210734049479,783.4080708821615,233.03437296549478,789.53662109375,229.59640502929688"
|
||||
fill="none" stroke-width="8" stroke="url("#SvgjsLinearGradient1003")" stroke-linecap="round"
|
||||
|
Before Width: | Height: | Size: 3.5 KiB After Width: | Height: | Size: 3.5 KiB |
@ -1,4 +1,4 @@
|
||||
<svg xmlns="http://www.w3.org/2000/svg" version="1.1" xmlns:xlink="http://www.w3.org/1999/xlink" viewBox="0 0 800 400">
|
||||
<svg xmlns="http://www.w3.org/2000/svg" version="1.1" viewBox="0 0 800 400">
|
||||
<path
|
||||
d="M-0.597907304763794,263.6771240234375C1.6442451079686484,257.3990987141927,5.5306423107783,226.158447265625,12.85500717163086,226.00897216796875C20.179372032483418,225.8594970703125,34.379672368367515,263.0792287190755,43.34828186035156,262.7802734375C52.31689135233561,262.4813181559245,59.49177678426107,225.26158142089844,66.66666412353516,224.21524047851562C73.84155146280925,223.1688995361328,76.23318099975586,254.85798136393228,86.3976058959961,256.5022277832031C96.56203079223633,258.14647420247394,116.29297510782878,234.08071899414062,127.65321350097656,234.08071899414062C139.01345189412436,234.08071899414062,144.8430430094401,257.24961344401044,154.5590362548828,256.5022277832031C164.27502950032553,255.75484212239584,176.68160756429037,229.89535522460938,185.9491729736328,229.59640502929688C195.21673838297525,229.29745483398438,202.54110972086588,254.55904897054037,210.1644287109375,254.70852661132812C217.78774770100912,254.85800425211588,223.3183848063151,230.49327087402344,231.6890869140625,230.49327087402344C240.0597890218099,230.49327087402344,250.5231679280599,255.75486501057944,260.3886413574219,254.70852661132812C270.2541147867839,253.6621882120768,280.7175038655599,224.81314849853516,290.8819274902344,224.21524047851562C301.0463511149089,223.6173324584961,310.01494852701825,251.12107849121094,321.37518310546875,251.12107849121094C332.73541768391925,251.12107849121094,346.78623453776044,224.06576283772787,359.0433349609375,224.21524047851562C371.30043538411456,224.36471811930338,381.9132995605469,252.16741943359375,394.91778564453125,252.0179443359375C407.9222717285156,251.86846923828125,424.96262613932294,223.31838989257812,437.07025146484375,223.31838989257812C449.17787679036456,223.31838989257812,457.2496337890625,251.7189915974935,467.56353759765625,252.0179443359375C477.87744140625,252.3168970743815,487.5934346516927,224.6636759440104,498.95367431640625,225.1121063232422C510.3139139811198,225.56053670247397,526.6068929036459,255.00747934977213,535.7249755859375,254.70852661132812C544.8430582682291,254.40957387288412,546.9357198079427,223.61734517415366,553.6621704101562,223.31838989257812C560.3886210123698,223.0194346110026,567.1150716145834,253.36322530110678,576.0836791992188,252.914794921875C585.0522867838541,252.46636454264322,598.0567728678385,221.22571563720703,607.4738159179688,220.6278076171875C616.890858968099,220.02989959716797,621.2256978352865,248.13153330485025,632.5859375,249.3273468017578C643.9461771647135,250.52316029866537,666.8161214192709,228.40059407552084,675.63525390625,227.8026885986328C684.4543863932291,227.20478312174478,676.5321146647135,246.33782196044922,685.500732421875,245.7399139404297C694.4693501790365,245.14200592041016,718.2361958821615,223.46785736083984,729.4469604492188,224.21524047851562C740.657725016276,224.9626235961914,742.7503763834635,249.32735188802084,752.7653198242188,250.22421264648438C762.780263264974,251.1210734049479,783.4080708821615,233.03437296549478,789.53662109375,229.59640502929688"
|
||||
fill="none" stroke-width="8" stroke="url("#SvgjsLinearGradient1003")" stroke-linecap="round"
|
||||
|
Before Width: | Height: | Size: 3.5 KiB After Width: | Height: | Size: 3.5 KiB |
@ -349,7 +349,8 @@
|
||||
<path class="prefix__cls-27"
|
||||
d="M1430.75 586.63c-.18 1-.63 1.92-1.83 1.9a1.77 1.77 0 01-1.77-1.94c0-1.3.61-2.31 2-2.13 1.14.13 1.6 1.06 1.6 2.17z"
|
||||
transform="translate(-260 -146)"/>
|
||||
<path class="prefix__cls-36" d="M1454.9 588.57a1.89 1.89 0 01-1.77-2c0-1.29.69-2.3 2.11-2.07a2.11 2.11 0 01-.34 4.1z"
|
||||
<path class="prefix__cls-36"
|
||||
d="M1454.9 588.57a1.89 1.89 0 01-1.77-2c0-1.29.69-2.3 2.11-2.07a2.11 2.11 0 01-.34 4.1z"
|
||||
transform="translate(-260 -146)"/>
|
||||
<path class="prefix__cls-37"
|
||||
d="M1584.11 588.58a1.86 1.86 0 01-2-1.75 1.89 1.89 0 011.32-2.32c1.44-.37 2.13.6 2.25 1.88a2 2 0 01-1.57 2.19z"
|
||||
@ -385,7 +386,8 @@
|
||||
transform="translate(-260 -146)"/>
|
||||
<path class="prefix__cls-17" d="M313.67 690a1.9 1.9 0 01-2 1.77c-1.29 0-2.3-.68-2.08-2.1a2.11 2.11 0 014.11.33z"
|
||||
transform="translate(-260 -146)"/>
|
||||
<path class="prefix__cls-25" d="M1508.51 638.12a2 2 0 01-2.14 1.66c-1.29-.09-2.27-.78-1.93-2.21a2.1 2.1 0 014.07.55z"
|
||||
<path class="prefix__cls-25"
|
||||
d="M1508.51 638.12a2 2 0 01-2.14 1.66c-1.29-.09-2.27-.78-1.93-2.21a2.1 2.1 0 014.07.55z"
|
||||
transform="translate(-260 -146)"/>
|
||||
<path class="prefix__cls-40"
|
||||
d="M287.67 663.81a1.85 1.85 0 01-1.76 1.94 1.9 1.9 0 01-2.31-1.35c-.35-1.45.63-2.12 1.91-2.22a1.94 1.94 0 012.16 1.63z"
|
||||
@ -608,7 +610,8 @@
|
||||
<path class="prefix__cls-19"
|
||||
d="M361.52 406.25a1.78 1.78 0 011.68-1.94 1.39 1.39 0 011.7 1.27c.18 1-.07 2-1.26 2.18a1.84 1.84 0 01-2.12-1.51z"
|
||||
transform="translate(-260 -146)"/>
|
||||
<path class="prefix__cls-21" d="M1559.81 637.73c0 1.29-.47 2.1-1.72 2a1.72 1.72 0 01-.12-3.43 1.5 1.5 0 011.84 1.43z"
|
||||
<path class="prefix__cls-21"
|
||||
d="M1559.81 637.73c0 1.29-.47 2.1-1.72 2a1.72 1.72 0 01-.12-3.43 1.5 1.5 0 011.84 1.43z"
|
||||
transform="translate(-260 -146)"/>
|
||||
<path class="prefix__cls-30"
|
||||
d="M1584.13 639.73c-1-.18-1.83-.68-1.75-1.85a1.74 1.74 0 012-1.64 1.45 1.45 0 011.41 1.6c.03 1.1-.38 1.87-1.66 1.89z"
|
||||
@ -675,7 +678,8 @@
|
||||
transform="translate(-260 -146)"/>
|
||||
<path d="M1480.48 430.26c1.07.08 1.91.52 2 1.66s-.71 1.73-1.78 1.83a1.4 1.4 0 01-1.6-1.39c-.1-1.03.14-1.91 1.38-2.1z"
|
||||
transform="translate(-260 -146)" fill="#1f282f"/>
|
||||
<path class="prefix__cls-21" d="M1611.8 663.72c0 1.3-.47 2.11-1.72 2a1.72 1.72 0 01-.12-3.44 1.49 1.49 0 011.84 1.44z"
|
||||
<path class="prefix__cls-21"
|
||||
d="M1611.8 663.72c0 1.3-.47 2.11-1.72 2a1.72 1.72 0 01-.12-3.44 1.49 1.49 0 011.84 1.44z"
|
||||
transform="translate(-260 -146)"/>
|
||||
<path class="prefix__cls-23"
|
||||
d="M335.52 716.14a1.76 1.76 0 011.69-1.9 1.38 1.38 0 011.69 1.26c.18 1-.07 2-1.25 2.19a1.85 1.85 0 01-2.13-1.55z"
|
||||
|
Before Width: | Height: | Size: 52 KiB After Width: | Height: | Size: 56 KiB |
@ -95,5 +95,6 @@ function test() {
|
||||
const posts = postLists();
|
||||
posts.map((p) => console.log(p));
|
||||
}
|
||||
|
||||
// test();
|
||||
main();
|
||||
|
@ -43,13 +43,16 @@ font-family: 'Poppins', sans-serif;
|
||||
width: 7px;
|
||||
height: 7px;
|
||||
}
|
||||
|
||||
::-webkit-scrollbar-track {
|
||||
border-radius: 3px;
|
||||
box-shadow: inset 0 0 5px rgba(0, 0, 0, 0.08);
|
||||
}
|
||||
|
||||
::-webkit-scrollbar-track-piece {
|
||||
background: 0 0;
|
||||
}
|
||||
|
||||
/* 滚动条滑块 */
|
||||
::-webkit-scrollbar-thumb {
|
||||
@apply bg-gray-400;
|
||||
@ -78,12 +81,15 @@ html.dark {
|
||||
--docsearch-logo-color: #fff;
|
||||
--docsearch-muted-color: #7f8497;
|
||||
}
|
||||
|
||||
html {
|
||||
--docsearch-primary-color: rgb(75, 85, 99) !important;
|
||||
}
|
||||
|
||||
.DocSearch-wrapper .DocSearch-Button {
|
||||
margin-left: unset;
|
||||
}
|
||||
|
||||
@media (max-width: 640px) {
|
||||
.DocSearch-wrapper .DocSearch-Button {
|
||||
align-items: unset;
|
||||
@ -92,12 +98,15 @@ html {
|
||||
height: unset;
|
||||
}
|
||||
}
|
||||
|
||||
.DocSearch-wrapper .DocSearch-Button .DocSearch-Search-Icon {
|
||||
@apply text-gray-600 dark:text-gray-200;
|
||||
}
|
||||
|
||||
.DocSearch .DocSearch-Form {
|
||||
border-radius: 6px;
|
||||
}
|
||||
|
||||
.DocSearch .DocSearch-Screen-Icon {
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
|
@ -42,6 +42,7 @@
|
||||
--color-attention-subtle: #fff8c5;
|
||||
--color-danger-fg: #cf222e;
|
||||
}
|
||||
|
||||
.dark #article {
|
||||
--color-prettylights-syntax-comment: #8b949e;
|
||||
--color-prettylights-syntax-constant: #79c0ff;
|
||||
@ -95,6 +96,7 @@
|
||||
padding-left: 0.8em;
|
||||
@apply my-4;
|
||||
}
|
||||
|
||||
#article .toc li {
|
||||
list-style-type: none;
|
||||
}
|
||||
@ -120,6 +122,7 @@ h5,
|
||||
h6 {
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
#article h2:hover::before,
|
||||
h3:hover::before,
|
||||
h4:hover::before,
|
||||
@ -166,30 +169,38 @@ h6:hover::before {
|
||||
margin-top: 0;
|
||||
margin-bottom: 16px;
|
||||
}
|
||||
|
||||
#article td,
|
||||
#article th {
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
#article details summary {
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
#article table th {
|
||||
font-weight: 600;
|
||||
}
|
||||
|
||||
#article table th,
|
||||
#article table td {
|
||||
padding: 6px 13px;
|
||||
}
|
||||
|
||||
#article thead tr:first-child {
|
||||
@apply border-t-0;
|
||||
}
|
||||
|
||||
#article table tr {
|
||||
background-color: var(--color-canvas-default);
|
||||
border-top: 1px solid var(--color-border-muted);
|
||||
}
|
||||
|
||||
#article table tr:nth-child(2n) {
|
||||
background-color: var(--color-canvas-subtle);
|
||||
}
|
||||
|
||||
#article table img {
|
||||
background-color: transparent;
|
||||
}
|
||||
@ -227,10 +238,12 @@ h6:hover::before {
|
||||
background-color: var(--color-border-default);
|
||||
border: 0;
|
||||
}
|
||||
|
||||
#article hr::before {
|
||||
display: table;
|
||||
content: '';
|
||||
}
|
||||
|
||||
#article hr::after {
|
||||
display: table;
|
||||
clear: both;
|
||||
@ -245,6 +258,7 @@ h6:hover::before {
|
||||
background-color: var(--color-neutral-muted);
|
||||
border-radius: 6px;
|
||||
}
|
||||
|
||||
#article pre > code {
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
@ -274,9 +288,11 @@ h6:hover::before {
|
||||
position: relative;
|
||||
vertical-align: baseline;
|
||||
}
|
||||
|
||||
#article sub {
|
||||
bottom: -0.25em;
|
||||
}
|
||||
|
||||
#article sup {
|
||||
top: -0.5em;
|
||||
}
|
||||
@ -284,42 +300,52 @@ h6:hover::before {
|
||||
#article ol li {
|
||||
list-style-type: auto;
|
||||
}
|
||||
|
||||
#article ul li {
|
||||
list-style-type: initial;
|
||||
}
|
||||
|
||||
#article ul.no-list,
|
||||
#article ol.no-list {
|
||||
padding: 0;
|
||||
list-style-type: none;
|
||||
}
|
||||
|
||||
#article ol[type='1'] {
|
||||
list-style-type: decimal;
|
||||
}
|
||||
|
||||
#article ol[type='a'] {
|
||||
list-style-type: lower-alpha;
|
||||
}
|
||||
|
||||
#article ol[type='i'] {
|
||||
list-style-type: lower-roman;
|
||||
}
|
||||
|
||||
#article div > ol:not([type]) {
|
||||
list-style-type: decimal;
|
||||
}
|
||||
|
||||
#article ul,
|
||||
#article ol {
|
||||
margin-top: 0;
|
||||
margin-bottom: 0;
|
||||
padding-left: 2em;
|
||||
}
|
||||
|
||||
#article ol ol,
|
||||
#article ul ol {
|
||||
list-style-type: lower-roman;
|
||||
}
|
||||
|
||||
#article ul ul ol,
|
||||
#article ul ol ol,
|
||||
#article ol ul ol,
|
||||
#article ol ol ol {
|
||||
list-style-type: lower-alpha;
|
||||
}
|
||||
|
||||
#article dd {
|
||||
margin-left: 0;
|
||||
}
|
||||
@ -327,6 +353,7 @@ h6:hover::before {
|
||||
#article .sp-layout > .sp-stack {
|
||||
height: 400px;
|
||||
}
|
||||
|
||||
@media screen and (max-width: 768px) {
|
||||
#article .sp-layout > .sp-stack {
|
||||
height: auto;
|
||||
|
@ -2,7 +2,11 @@
|
||||
"compilerOptions": {
|
||||
"baseUrl": ".",
|
||||
"target": "es5",
|
||||
"lib": ["dom", "dom.iterable", "esnext"],
|
||||
"lib": [
|
||||
"dom",
|
||||
"dom.iterable",
|
||||
"esnext"
|
||||
],
|
||||
"allowJs": true,
|
||||
"skipLibCheck": true,
|
||||
"strict": true,
|
||||
@ -17,6 +21,12 @@
|
||||
// "typeRoots": ["./types", "./node_modules/@types"],
|
||||
"incremental": true
|
||||
},
|
||||
"include": ["next-env.d.ts", "**/*.ts", "**/*.tsx"],
|
||||
"exclude": ["node_modules"]
|
||||
"include": [
|
||||
"next-env.d.ts",
|
||||
"**/*.ts",
|
||||
"**/*.tsx"
|
||||
],
|
||||
"exclude": [
|
||||
"node_modules"
|
||||
]
|
||||
}
|
||||
|
@ -41,6 +41,7 @@ export interface Gist {
|
||||
owner: GistsOwner;
|
||||
truncated: boolean;
|
||||
}
|
||||
|
||||
export interface GistsFile {
|
||||
filename: string;
|
||||
type: GistsFileType;
|
||||
@ -49,17 +50,20 @@ export interface GistsFile {
|
||||
size: number;
|
||||
content: string;
|
||||
}
|
||||
|
||||
export enum GistsLanguage {
|
||||
JavaScript = 'JavaScript',
|
||||
PublicKey = 'Public Key',
|
||||
TypeScript = 'TypeScript',
|
||||
}
|
||||
|
||||
export enum GistsFileType {
|
||||
ApplicationJavascript = 'application/javascript',
|
||||
ApplicationPGPSignature = 'application/pgp-signature',
|
||||
TextPlain = 'text/plain',
|
||||
VideoMP2T = 'video/MP2T',
|
||||
}
|
||||
|
||||
export interface GistsOwner {
|
||||
login: GistsLogin;
|
||||
id: number;
|
||||
@ -80,24 +84,31 @@ export interface GistsOwner {
|
||||
type: GistsOwnerType;
|
||||
site_admin: boolean;
|
||||
}
|
||||
|
||||
export enum GistsEventsURL {
|
||||
HTTPSAPIGithubCOMUsersDefectingCatEventsPrivacy = 'https://api.github.com/users/DefectingCat/events{/privacy}',
|
||||
}
|
||||
|
||||
export enum GistsFollowingURL {
|
||||
HTTPSAPIGithubCOMUsersDefectingCatFollowingOtherUser = 'https://api.github.com/users/DefectingCat/following{/other_user}',
|
||||
}
|
||||
|
||||
export enum GistsURL {
|
||||
HTTPSAPIGithubCOMUsersDefectingCatGistsGistID = 'https://api.github.com/users/DefectingCat/gists{/gist_id}',
|
||||
}
|
||||
|
||||
export enum GistsLogin {
|
||||
DefectingCat = 'DefectingCat',
|
||||
}
|
||||
|
||||
export enum GistsNodeID {
|
||||
MDQ6VXNlcjI1MDMzNDkz = 'MDQ6VXNlcjI1MDMzNDkz',
|
||||
}
|
||||
|
||||
export enum GistsStarredURL {
|
||||
HTTPSAPIGithubCOMUsersDefectingCatStarredOwnerRepo = 'https://api.github.com/users/DefectingCat/starred{/owner}{/repo}',
|
||||
}
|
||||
|
||||
export enum GistsOwnerType {
|
||||
User = 'User',
|
||||
}
|
||||
|