mirror of
https://github.com/squidfunk/mkdocs-material.git
synced 2024-11-14 19:07:41 +01:00
Fixed invalid versions.json URL (regression)
This commit is contained in:
parent
f869d275b4
commit
a855133f16
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@ -223,7 +223,7 @@
|
|||||||
</script>
|
</script>
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
{% block scripts %}
|
{% block scripts %}
|
||||||
<script src="{{ 'assets/javascripts/bundle.143c17e5.min.js' | url }}"></script>
|
<script src="{{ 'assets/javascripts/bundle.a0ca7753.min.js' | url }}"></script>
|
||||||
{% for path in config["extra_javascript"] %}
|
{% for path in config["extra_javascript"] %}
|
||||||
<script src="{{ path | url }}"></script>
|
<script src="{{ path | url }}"></script>
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
|
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@ -16,5 +16,5 @@
|
|||||||
{% endblock %}
|
{% endblock %}
|
||||||
{% block scripts %}
|
{% block scripts %}
|
||||||
{{ super() }}
|
{{ super() }}
|
||||||
<script src="{{ 'overrides/assets/javascripts/bundle.25c9f9b3.min.js' | url }}"></script>
|
<script src="{{ 'overrides/assets/javascripts/bundle.515b7185.min.js' | url }}"></script>
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
|
@ -96,7 +96,7 @@ export interface Config {
|
|||||||
*/
|
*/
|
||||||
const script = getElementOrThrow("#__config")
|
const script = getElementOrThrow("#__config")
|
||||||
const config: Config = JSON.parse(script.textContent!)
|
const config: Config = JSON.parse(script.textContent!)
|
||||||
config.base = new URL(config.base, getLocation()).toString()
|
config.base = `${new URL(config.base, getLocation())}`
|
||||||
|
|
||||||
/* ----------------------------------------------------------------------------
|
/* ----------------------------------------------------------------------------
|
||||||
* Functions
|
* Functions
|
||||||
|
@ -33,7 +33,7 @@ import { Version, renderVersionSelector } from "~/templates"
|
|||||||
*/
|
*/
|
||||||
export function setupVersionSelector(): void {
|
export function setupVersionSelector(): void {
|
||||||
const config = configuration()
|
const config = configuration()
|
||||||
requestJSON<Version[]>(new URL("versions.json", config.base))
|
requestJSON<Version[]>(new URL("../versions.json", config.base))
|
||||||
.subscribe(versions => {
|
.subscribe(versions => {
|
||||||
const topic = getElementOrThrow(".md-header__topic")
|
const topic = getElementOrThrow(".md-header__topic")
|
||||||
topic.appendChild(renderVersionSelector(versions))
|
topic.appendChild(renderVersionSelector(versions))
|
||||||
|
Loading…
Reference in New Issue
Block a user