diff --git a/CHANGELOG.md b/CHANGELOG.md index ba0afe7810..a59187b740 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -14,8 +14,10 @@ For a list of issues targeted for the next release, see the [23Q1][] milestone. **Breaking changes**: -- **Upgraded Bootstrap ([#470])** to v5.2. For a list of Bootstrap's breaking - changes, see the [Bootstrap migration guide][bsv5mig]. Other Docsy-specific +- **Detection of draw.io diagrams** is now **disabled** by default [#1185][] + +- **[Upgraded Bootstrap ([#470][])** to v5.2. For a list of Bootstrap breaking + changes, see the [Bootstrap migration guide][bsv5mig]. Other, Docsy-specific changes are listed below: - Clean up of unused, or rarely used, variables, functions, and mixins: - Dropped `$primary-light` @@ -44,6 +46,7 @@ For a list of issues targeted for the next release, see the [23Q1][] milestone. - Draw.io diagram edit button: replaced custom colors by BS's outline primary. [#470]: https://github.com/google/docsy/issues/470 +[#1185]: https://github.com/google/docsy/issues/1185 [#906]: https://github.com/google/docsy/issues/906 [#939]: https://github.com/google/docsy/issues/939 [#1369]: https://github.com/google/docsy/issues/1369 diff --git a/hugo.yaml b/hugo.yaml index 8a4d145dc3..b6efdf112f 100644 --- a/hugo.yaml +++ b/hugo.yaml @@ -6,8 +6,6 @@ params: time_format_blog: Monday, January 02, 2006 time_format_default: January 2, 2006 rss_sections: [blog] - drawio: - enable: true outputFormats: PRINT: diff --git a/userguide/content/en/docs/adding-content/diagrams-and-formulae/index.md b/userguide/content/en/docs/adding-content/diagrams-and-formulae/index.md index 50451c5d96..eb8147a911 100644 --- a/userguide/content/en/docs/adding-content/diagrams-and-formulae/index.md +++ b/userguide/content/en/docs/adding-content/diagrams-and-formulae/index.md @@ -1,6 +1,6 @@ --- -title: "Diagrams and Formulae" -linkTitle: "Diagrams and Formulae" +title: Diagrams and Formulae +linkTitle: Diagrams and Formulae weight: 11 description: Add generated diagrams and scientific formulae to your site. math: true @@ -634,39 +634,39 @@ params: ## Diagrams with Diagrams.net -[Diagrams.net](https://diagrams.net/) (aka draw.io) provides a free and open source diagram editor that can generate a wider range of diagrams than Mermaid or PlantUML using a web or desktop editor. +[Diagrams.net](https://diagrams.net/) (aka `draw.io`) provides a free and open source diagram editor that can generate a wider range of diagrams than Mermaid or PlantUML using a web or desktop editor. -SVG and PNG files exported with the tool contain the source code of the original diagram by default, which allows the diagrams.net site to import those images again for edit in the future. Docsy can detect this and automatically add an "edit" button over any image that can be edited using the online site. +SVG and PNG files exported with the tool contain the source code of the original diagram by default, which allows the diagrams.net site to import those images again for edit in the future. With `draw.io` enabled, Docsy will detect this and automatically add an `Edit` button over any image that can be edited using the online site. -Hover over the image below and click edit to instantly start working with it. Clicking the "Save" button will cause the edited diagram to be exported using the same filename and filetype, and downloaded to your browser. +Hover over the image below and click edit to instantly start working with it. Clicking the `Save` button will cause the edited diagram to be exported using the same filename and filetype, and downloaded to your browser. {{%alert title="Note" color="primary" %}} -If you're creating a new diagram, be sure to File -> Export in either svg or png format (svg is usually the best choice) and ensure the "Include a copy of my diagram" is selected so it can be edited again later. +If you're creating a new diagram, be sure to `File -> Export` in either `svg` or `png` format (`svg` is usually the best choice) and ensure the `Include a copy of my diagram` is selected so it can be edited again later. {{%/alert%}} As the diagram data is transported via the browser, the diagrams.net server does not need to access the content on your Docsy server directly at all. -{{< figure src="docsy-diagrams.svg" caption="Mouse over the above image and click the edit button!">}} +{{< figure src="docsy-diagrams.svg" caption="Mouse over the above image and click the `Edit` button!">}} -To disable detection of diagrams, update `hugo.toml`/`hugo.yaml`/`hugo.json`: +To enable detection of diagrams, update `hugo.toml`/`hugo.yaml`/`hugo.json`: {{< tabpane persistLang=false >}} {{< tab header="Configuration file:" disabled=true />}} {{< tab header="hugo.toml" lang="toml" >}} [params.drawio] -enable = false +enable = true {{< /tab >}} {{< tab header="hugo.yaml" lang="yaml" >}} params: drawio: - enable: false + enable: true {{< /tab >}} {{< tab header="hugo.json" lang="json" >}} { "params": { "drawio": { - "enable": false + "enable": true } } } diff --git a/userguide/hugo.yaml b/userguide/hugo.yaml index 4c05b16069..8057b275cf 100644 --- a/userguide/hugo.yaml +++ b/userguide/hugo.yaml @@ -123,6 +123,9 @@ params: theme: default flowchart: diagramPadding: 20 + drawio: + enable: true + taxonomies: tag: tags