mirror of
https://github.com/squidfunk/mkdocs-material.git
synced 2024-06-14 11:52:32 +03:00
Fixed basic authentication for search index retrieval
This commit is contained in:
parent
33c183754c
commit
b273c429d9
File diff suppressed because one or more lines are too long
1
material/assets/stylesheets/application-0d18cb003b.css
Normal file
1
material/assets/stylesheets/application-0d18cb003b.css
Normal file
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@ -36,7 +36,7 @@
|
||||
{% include "partials/fonts.html" %}
|
||||
{% endblock %}
|
||||
{% block styles %}
|
||||
<link rel="stylesheet" href="{{ base_url }}/assets/stylesheets/application-868145bb77.css">
|
||||
<link rel="stylesheet" href="{{ base_url }}/assets/stylesheets/application-0d18cb003b.css">
|
||||
{% if config.extra.palette %}
|
||||
<link rel="stylesheet" href="{{ base_url }}/assets/stylesheets/application-0352baa348.palette.css">
|
||||
{% endif %}
|
||||
@ -110,7 +110,7 @@
|
||||
<script src="https://cdn.mathjax.org/{{ path }}"></script>
|
||||
{% endif %}
|
||||
{% endfor %}
|
||||
<script src="{{ base_url }}/assets/javascripts/application-c57ff8e45a.js"></script>
|
||||
<script src="{{ base_url }}/assets/javascripts/application-c6a54b6fec.js"></script>
|
||||
<script>var config={url:{base:"{{ base_url }}"}},app=new Application(config);app.initialize()</script>
|
||||
{% for path in extra_javascript %}
|
||||
<script src="{{ path }}"></script>
|
||||
|
@ -141,8 +141,9 @@ export default class Application {
|
||||
new Material.Event.Listener(document.forms.search.query, [
|
||||
"focus", "keyup"
|
||||
], new Material.Search.Result("[data-md-component=result]", () => {
|
||||
return fetch(`${this.config_.url.base}/mkdocs/search_index.json`)
|
||||
.then(response => response.json())
|
||||
return fetch(`${this.config_.url.base}/mkdocs/search_index.json`, {
|
||||
credentials: "same-origin"
|
||||
}).then(response => response.json())
|
||||
.then(data => {
|
||||
return data.docs.map(doc => {
|
||||
doc.location = this.config_.url.base + doc.location
|
||||
|
Loading…
Reference in New Issue
Block a user