mirror of
https://github.com/squidfunk/mkdocs-material.git
synced 2024-11-24 07:30:12 +01:00
Removed unnecessary deferrals to animation frames
This commit is contained in:
parent
87df85def8
commit
732565b3af
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@ -213,7 +213,7 @@
|
||||
</script>
|
||||
{% endblock %}
|
||||
{% block scripts %}
|
||||
<script src="{{ 'assets/javascripts/bundle.7d4612cf.min.js' | url }}"></script>
|
||||
<script src="{{ 'assets/javascripts/bundle.cb647d62.min.js' | url }}"></script>
|
||||
{% for path in config["extra_javascript"] %}
|
||||
<script src="{{ path | url }}"></script>
|
||||
{% 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 %}
|
||||
{% block scripts %}
|
||||
{{ super() }}
|
||||
<script src="{{ 'overrides/assets/javascripts/bundle.fa323f41.min.js' | url }}"></script>
|
||||
<script src="{{ 'overrides/assets/javascripts/bundle.876eeeea.min.js' | url }}"></script>
|
||||
{% endblock %}
|
||||
|
@ -23,13 +23,11 @@
|
||||
import {
|
||||
Observable,
|
||||
Subject,
|
||||
animationFrameScheduler,
|
||||
bufferCount,
|
||||
filter,
|
||||
finalize,
|
||||
map,
|
||||
merge,
|
||||
observeOn,
|
||||
of,
|
||||
skipUntil,
|
||||
switchMap,
|
||||
@ -106,7 +104,6 @@ export function mountSearchResult(
|
||||
/* Update search result metadata */
|
||||
push$
|
||||
.pipe(
|
||||
observeOn(animationFrameScheduler),
|
||||
withLatestFrom(query$),
|
||||
skipUntil(ready$)
|
||||
)
|
||||
@ -139,7 +136,6 @@ export function mountSearchResult(
|
||||
/* Update search result list */
|
||||
push$
|
||||
.pipe(
|
||||
observeOn(animationFrameScheduler),
|
||||
tap(() => list.innerHTML = ""),
|
||||
switchMap(({ items }) => merge(
|
||||
of(...items.slice(0, 10)),
|
||||
|
@ -22,11 +22,9 @@
|
||||
|
||||
import {
|
||||
Observable,
|
||||
animationFrameScheduler,
|
||||
combineLatest,
|
||||
delay,
|
||||
map,
|
||||
observeOn,
|
||||
of,
|
||||
switchMap,
|
||||
withLatestFrom
|
||||
@ -71,8 +69,7 @@ export function patchScrolllock(
|
||||
map(([active, tablet]) => active && !tablet),
|
||||
switchMap(active => of(active)
|
||||
.pipe(
|
||||
delay(active ? 400 : 100),
|
||||
observeOn(animationFrameScheduler)
|
||||
delay(active ? 400 : 100)
|
||||
)
|
||||
),
|
||||
withLatestFrom(viewport$)
|
||||
|
@ -24,7 +24,6 @@ import { filter as search } from "fuzzaldrin-plus"
|
||||
import {
|
||||
Observable,
|
||||
Subject,
|
||||
animationFrameScheduler,
|
||||
bufferCount,
|
||||
combineLatest,
|
||||
distinctUntilKeyChanged,
|
||||
@ -32,7 +31,6 @@ import {
|
||||
finalize,
|
||||
map,
|
||||
merge,
|
||||
observeOn,
|
||||
of,
|
||||
switchMap,
|
||||
tap,
|
||||
@ -152,7 +150,6 @@ export function mountIconSearchResult(
|
||||
const meta = getElement(":scope > :first-child", el)
|
||||
push$
|
||||
.pipe(
|
||||
observeOn(animationFrameScheduler),
|
||||
withLatestFrom(query$)
|
||||
)
|
||||
.subscribe(([{ data }, { value }]) => {
|
||||
@ -185,7 +182,6 @@ export function mountIconSearchResult(
|
||||
const list = getElement(":scope > :last-child", el)
|
||||
push$
|
||||
.pipe(
|
||||
observeOn(animationFrameScheduler),
|
||||
tap(() => list.innerHTML = ""),
|
||||
switchMap(({ data }) => merge(
|
||||
of(...data.slice(0, 10)),
|
||||
|
Loading…
Reference in New Issue
Block a user