mirror of
https://github.com/squidfunk/mkdocs-material.git
synced 2024-06-14 11:52:32 +03:00
Fixed closing of search results on anchor jump
This commit is contained in:
parent
566b1363ee
commit
c0abaf5692
File diff suppressed because one or more lines are too long
1
material/assets/javascripts/bundle.21a66646.min.js.map
Normal file
1
material/assets/javascripts/bundle.21a66646.min.js.map
Normal file
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"assets/javascripts/bundle.js": "assets/javascripts/bundle.63b8430f.min.js",
|
"assets/javascripts/bundle.js": "assets/javascripts/bundle.21a66646.min.js",
|
||||||
"assets/javascripts/bundle.js.map": "assets/javascripts/bundle.63b8430f.min.js.map",
|
"assets/javascripts/bundle.js.map": "assets/javascripts/bundle.21a66646.min.js.map",
|
||||||
"assets/javascripts/vendor.js": "assets/javascripts/vendor.b0b43276.min.js",
|
"assets/javascripts/vendor.js": "assets/javascripts/vendor.b0b43276.min.js",
|
||||||
"assets/javascripts/vendor.js.map": "assets/javascripts/vendor.b0b43276.min.js.map",
|
"assets/javascripts/vendor.js.map": "assets/javascripts/vendor.b0b43276.min.js.map",
|
||||||
"assets/javascripts/worker/search.js": "assets/javascripts/worker/search.784c5235.min.js",
|
"assets/javascripts/worker/search.js": "assets/javascripts/worker/search.784c5235.min.js",
|
||||||
|
@ -178,7 +178,7 @@
|
|||||||
{% endblock %}
|
{% endblock %}
|
||||||
{% block scripts %}
|
{% block scripts %}
|
||||||
<script src="{{ 'assets/javascripts/vendor.b0b43276.min.js' | url }}"></script>
|
<script src="{{ 'assets/javascripts/vendor.b0b43276.min.js' | url }}"></script>
|
||||||
<script src="{{ 'assets/javascripts/bundle.63b8430f.min.js' | url }}"></script>
|
<script src="{{ 'assets/javascripts/bundle.21a66646.min.js' | url }}"></script>
|
||||||
{%- set translations = {} -%}
|
{%- set translations = {} -%}
|
||||||
{%- for key in [
|
{%- for key in [
|
||||||
"clipboard.copy",
|
"clipboard.copy",
|
||||||
|
@ -57,7 +57,8 @@ import {
|
|||||||
watchLocationHash,
|
watchLocationHash,
|
||||||
watchViewport,
|
watchViewport,
|
||||||
isLocationInternal,
|
isLocationInternal,
|
||||||
isLocationAnchor
|
isLocationAnchor,
|
||||||
|
setLocationHash
|
||||||
} from "./browser"
|
} from "./browser"
|
||||||
import { setupSearchWorker } from "./workers"
|
import { setupSearchWorker } from "./workers"
|
||||||
|
|
||||||
@ -270,20 +271,12 @@ export function initialize(config: unknown) {
|
|||||||
/* ----------------------------------------------------------------------- */
|
/* ----------------------------------------------------------------------- */
|
||||||
|
|
||||||
// // put into search...
|
// // put into search...
|
||||||
// hash$
|
hash$
|
||||||
// .pipe(
|
.pipe(
|
||||||
// switchMap(hash => useToggle("search")
|
tap(() => setToggle("search", false)),
|
||||||
// .pipe(
|
delay(125), // ensure that it runs after the body scroll reset...
|
||||||
// filter(x => x.checked), // only active
|
)
|
||||||
// tap(toggle => setToggle(toggle, false)),
|
.subscribe(hash => setLocationHash(`#${hash}`)) // TODO: must be unified
|
||||||
// delay(125), // ensure that it runs after the body scroll reset...
|
|
||||||
// mapTo(hash)
|
|
||||||
// )
|
|
||||||
// )
|
|
||||||
// )
|
|
||||||
// .subscribe(hash => {
|
|
||||||
// getElement(`[id="${hash}"]`)!.scrollIntoView()
|
|
||||||
// })
|
|
||||||
|
|
||||||
// Scroll lock // document -> document$ => { body } !?
|
// Scroll lock // document -> document$ => { body } !?
|
||||||
// put into search...
|
// put into search...
|
||||||
|
Loading…
Reference in New Issue
Block a user