Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 16 additions & 0 deletions doc-kit.config.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
import { resolve } from "node:path";
import { fileURLToPath } from "node:url";

const __dirname = fileURLToPath(new URL(".", import.meta.url));

export default {
global: {
repository: "webpack/webpack",
},
web: {
title: "webpack",
imports: {
"#config/Logo": resolve(__dirname, "ui/WebpackLogo.jsx"),
},
},
};
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"scripts": {
"generate-docs": "node generate-md.mjs",
"build-html": "doc-kit generate -t web -i ./pages/v5.x/**/*.md --type-map ./pages/v5.x/type-map.json -o out",
"build-html": "doc-kit generate --config-file ./doc-kit.config.mjs -t web -i ./pages/v5.x/**/*.md --type-map ./pages/v5.x/type-map.json -o out",
"build": "npm run generate-docs && npm run build-html",
"lint": "eslint .",
"lint:fix": "eslint --fix .",
Expand Down
21 changes: 21 additions & 0 deletions ui/WebpackLogo.jsx
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Technically, this isn't part of the typedoc theme, rather, it's part of doc-kit.

For better organization, let's make a new root folder, say ui/ (or whatever name you want)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done — moved WebpackLogo.jsx to a new root-level ui/ folder and updated the path in doc-kit.config.mjs accordingly.

Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
const WebpackLogo = (props) => (
<svg
xmlns="http://www.w3.org/2000/svg"
viewBox="0 0 774 875.7"
width="24"
height="28"
{...props}
>
<path fill="#FFF" d="M387 0l387 218.9v437.9L387 875.7 0 656.8V218.9z" />
<path
fill="#8ed6fb"
d="M704.9 641.7L399.8 814.3V679.9l190.1-104.6 115 66.4zm20.9-18.9V261.9l-111.6 64.5v232l111.6 64.4zM67.9 641.7L373 814.3V679.9L182.8 575.3 67.9 641.7zM47 622.8V261.9l111.6 64.5v232L47 622.8zm13.1-384.3L373 61.5v129.9L172.5 301.7l-1.6.9-110.8-64.1zm652.6 0l-312.9-177v129.9l200.5 110.2 1.6.9 110.8-64z"
/>
<path
fill="#1c78c0"
d="M373 649.3L185.4 546.1V341.8L373 450.1v199.2zm26.8 0l187.6-103.1V341.8L399.8 450.1v199.2zm-13.4-207zM198.1 318.2l188.3-103.5 188.3 103.5-188.3 108.7-188.3-108.7z"
/>
</svg>
);

export default WebpackLogo;