Skip to content

Commit

Permalink
feat(web): embed SVG into HTML directly
Browse files Browse the repository at this point in the history
* Makes sure element IDs and CSS do not interfere with other diagrams in the
  same HTML document.
* Disables SVGO to allow embedding in Docusaurus with CSS intact.
* Replaces PNG figures with SVG in documentation.
  • Loading branch information
kris7t committed Apr 11, 2024
1 parent 5684bdf commit 12e7bf6
Show file tree
Hide file tree
Showing 20 changed files with 801 additions and 98 deletions.
1 change: 1 addition & 0 deletions subprojects/docs/docusaurus.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@ export default {
markdownOptions satisfies PagesOptions,
],
'@docusaurus/plugin-sitemap',
'./src/plugins/loadersPlugin.ts',
'./src/plugins/swcMinifyPlugin.ts',
],
themes: [
Expand Down
4 changes: 4 additions & 0 deletions subprojects/docs/src/css/custom.css
Original file line number Diff line number Diff line change
Expand Up @@ -125,3 +125,7 @@ code {
.hero__title {
font-weight: 800;
}

.markdown svg {
max-width: 100%;
}
Binary file not shown.
72 changes: 72 additions & 0 deletions subprojects/docs/src/learn/tutorials/file-system/fig1.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
Loading

0 comments on commit 12e7bf6

Please sign in to comment.