mirror of
https://github.com/slint-ui/slint.git
synced 2025-10-02 22:54:36 +00:00
Move all HTML/CSS/JS related to preview and syntax highlighting in the docs into a shared folder
This will also be the place where the .60 language definition for highlight.js can go.
This commit is contained in:
parent
3f5ad42683
commit
8003c06f3a
7 changed files with 6 additions and 6 deletions
2
.github/workflows/ci.yaml
vendored
2
.github/workflows/ci.yaml
vendored
|
@ -305,7 +305,7 @@ jobs:
|
|||
# allow deprecated warning because we are using nightly and some things might be deprecated in nightly
|
||||
# for which the stable alternative is not yet available
|
||||
RUSTFLAGS: -D warnings -W deprecated
|
||||
RUSTDOCFLAGS: --html-in-header=/home/runner/work/sixtyfps/sixtyfps/api/sixtyfps-rs/sixtyfps-docs-preview.html --html-in-header=/home/runner/work/sixtyfps/sixtyfps/api/sixtyfps-rs/sixtyfps-docs-highlight.html -D warnings -W deprecated
|
||||
RUSTDOCFLAGS: --html-in-header=/home/runner/work/sixtyfps/sixtyfps/docs/html/sixtyfps-docs-preview.html --html-in-header=/home/runner/work/sixtyfps/sixtyfps/docs/html/sixtyfps-docs-highlight-rust.html -D warnings -W deprecated
|
||||
SIXTYFPS_NO_QT: 1
|
||||
CARGO_INCREMENTAL: false
|
||||
MDBOOK_VERSION: 0.4.10
|
||||
|
|
4
api/sixtyfps-cpp/docs/_templates/layout.html
vendored
4
api/sixtyfps-cpp/docs/_templates/layout.html
vendored
|
@ -1,6 +1,6 @@
|
|||
{% extends "!layout.html" %}
|
||||
{% block scripts %}
|
||||
{{ super() }}
|
||||
{% include "../../../sixtyfps-rs/sixtyfps-docs-preview.html" %}
|
||||
{% include "../sixtyfps-docs-highlight.html" %}
|
||||
{% include "../../../../docs/html/sixtyfps-docs-preview.html" %}
|
||||
{% include "../../../../docs/html/sixtyfps-docs-highlight-cpp.html" %}
|
||||
{% endblock %}
|
|
@ -31,4 +31,4 @@ pin-weak = "1"
|
|||
rustc_version = "0.4"
|
||||
|
||||
[package.metadata.docs.rs]
|
||||
rustdoc-args = [ "--html-in-header", "sixtyfps-docs-preview.html", "--html-in-header", "sixtyfps-docs-highlight.html" ]
|
||||
rustdoc-args = [ "--html-in-header", "docs/html/sixtyfps-docs-preview.html", "--html-in-header", "docs/html/sixtyfps-docs-highlight-rust.html" ]
|
||||
|
|
|
@ -125,7 +125,7 @@ html to the documentation with the `--html-in-header` rustdoc flag.
|
|||
Here is how to build the documentation to include preview of the .60 files.
|
||||
|
||||
```sh
|
||||
RUSTDOCFLAGS="--html-in-header=$PWD/api/sixtyfps-rs/sixtyfps-docs-preview.html --html-in-header=$PWD/api/sixtyfps-rs/sixtyfps-docs-highlight.html" cargo +nightly doc --no-deps
|
||||
RUSTDOCFLAGS="--html-in-header=$PWD/docs/html/sixtyfps-docs-preview.html --html-in-header=$PWD/docs/html/sixtyfps-docs-highlight-rust.html" cargo +nightly doc --no-deps
|
||||
```
|
||||
|
||||
### C++ doc
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
<!--
|
||||
This file is used to add syntax highlighting of the `.60` snippets in the generated rustdoc documentation.
|
||||
It can be injected via the `--html-in-header sixtyfps-docs-highlight.html` option of rustdoc.
|
||||
It can be injected via the `--html-in-header sixtyfps-docs-highlight-rust.html` option of rustdoc.
|
||||
-->
|
||||
<link rel="stylesheet" href="https://sixtyfps.io/highlight-default.css">
|
||||
<script src="https://sixtyfps.io/highlight.pack.js"></script>
|
Loading…
Add table
Add a link
Reference in a new issue