Skip to content

Commit f4b1f97

Browse files
committed
Fixed execution of RxJS teardown logic on complete (7.2.3 regression)
1 parent 281fa3a commit f4b1f97

File tree

22 files changed

+88
-55
lines changed

22 files changed

+88
-55
lines changed

material/assets/javascripts/bundle.9264e2c0.min.js

+29
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

material/assets/javascripts/bundle.febc23d1.min.js.map renamed to material/assets/javascripts/bundle.9264e2c0.min.js.map

+2-2
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

material/assets/javascripts/bundle.febc23d1.min.js

-29
This file was deleted.

material/base.html

+1-1
Original file line numberDiff line numberDiff line change
@@ -223,7 +223,7 @@ <h1>{{ page.title | d(config.site_name, true)}}</h1>
223223
</script>
224224
{% endblock %}
225225
{% block scripts %}
226-
<script src="{{ 'assets/javascripts/bundle.febc23d1.min.js' | url }}"></script>
226+
<script src="{{ 'assets/javascripts/bundle.9264e2c0.min.js' | url }}"></script>
227227
{% for path in config["extra_javascript"] %}
228228
<script src="{{ path | url }}"></script>
229229
{% endfor %}

material/overrides/assets/javascripts/bundle.515b7185.min.js renamed to material/overrides/assets/javascripts/bundle.a07ad7e8.min.js

+4-4
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

material/overrides/assets/javascripts/bundle.515b7185.min.js.map renamed to material/overrides/assets/javascripts/bundle.a07ad7e8.min.js.map

+2-2
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

material/overrides/main.html

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,5 +16,5 @@
1616
{% endblock %}
1717
{% block scripts %}
1818
{{ super() }}
19-
<script src="{{ 'overrides/assets/javascripts/bundle.515b7185.min.js' | url }}"></script>
19+
<script src="{{ 'overrides/assets/javascripts/bundle.a07ad7e8.min.js' | url }}"></script>
2020
{% endblock %}

src/assets/javascripts/components/content/code/index.ts

+3-1
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@ import {
3131
} from "rxjs"
3232
import {
3333
distinctUntilKeyChanged,
34+
finalize,
3435
map,
3536
switchMap,
3637
tap,
@@ -175,7 +176,8 @@ export function mountCodeBlock(
175176
/* Create and return component */
176177
return watchCodeBlock(el, options)
177178
.pipe(
178-
tap(internal$),
179+
tap(state => internal$.next(state)),
180+
finalize(() => internal$.complete()),
179181
map(state => ({ ref: el, ...state }))
180182
)
181183
}

src/assets/javascripts/components/content/details/index.ts

+3-1
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,7 @@
2323
import { Observable, Subject } from "rxjs"
2424
import {
2525
filter,
26+
finalize,
2627
map,
2728
mapTo,
2829
mergeWith,
@@ -107,7 +108,8 @@ export function mountDetails(
107108
/* Create and return component */
108109
return watchDetails(el, options)
109110
.pipe(
110-
tap(internal$),
111+
tap(state => internal$.next(state)),
112+
finalize(() => internal$.complete()),
111113
mapTo({ ref: el })
112114
)
113115
}

src/assets/javascripts/components/dialog/index.ts

+3-1
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@ import {
2828
of
2929
} from "rxjs"
3030
import {
31+
finalize,
3132
delay,
3233
map,
3334
observeOn,
@@ -131,7 +132,8 @@ export function mountDialog(
131132
/* Create and return component */
132133
return watchDialog(el, options)
133134
.pipe(
134-
tap(internal$),
135+
tap(state => internal$.next(state)),
136+
finalize(() => internal$.complete()),
135137
map(state => ({ ref: el, ...state }))
136138
)
137139
}

src/assets/javascripts/components/header/title/index.ts

+3-1
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@ import {
2828
} from "rxjs"
2929
import {
3030
distinctUntilKeyChanged,
31+
finalize,
3132
map,
3233
observeOn,
3334
tap
@@ -139,7 +140,8 @@ export function mountHeaderTitle(
139140
/* Create and return component */
140141
return watchHeaderTitle(headline, options)
141142
.pipe(
142-
tap(internal$),
143+
tap(state => internal$.next(state)),
144+
finalize(() => internal$.complete()),
143145
map(state => ({ ref: el, ...state }))
144146
)
145147
}

src/assets/javascripts/components/palette/index.ts

+3-1
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@ import {
2727
of
2828
} from "rxjs"
2929
import {
30+
finalize,
3031
map,
3132
mapTo,
3233
mergeMap,
@@ -140,7 +141,8 @@ export function mountPalette(
140141
const inputs = getElements<HTMLInputElement>("input", el)
141142
return watchPalette(inputs)
142143
.pipe(
143-
tap(internal$),
144+
tap(state => internal$.next(state)),
145+
finalize(() => internal$.complete()),
144146
map(state => ({ ref: el, ...state }))
145147
)
146148
}

src/assets/javascripts/components/search/query/index.ts

+3-1
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,7 @@ import {
3232
distinctUntilChanged,
3333
distinctUntilKeyChanged,
3434
filter,
35+
finalize,
3536
map,
3637
take,
3738
takeLast,
@@ -172,7 +173,8 @@ export function mountSearchQuery(
172173
/* Create and return component */
173174
return watchSearchQuery(el, { tx$, rx$ })
174175
.pipe(
175-
tap(internal$),
176+
tap(state => internal$.next(state)),
177+
finalize(() => internal$.complete()),
176178
map(state => ({ ref: el, ...state }))
177179
)
178180
}

src/assets/javascripts/components/search/result/index.ts

+3-1
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,7 @@ import {
3030
import {
3131
bufferCount,
3232
filter,
33+
finalize,
3334
map,
3435
observeOn,
3536
switchMap,
@@ -152,7 +153,8 @@ export function mountSearchResult(
152153
/* Create and return component */
153154
return result$
154155
.pipe(
155-
tap(internal$),
156+
tap(state => internal$.next(state)),
157+
finalize(() => internal$.complete()),
156158
map(state => ({ ref: el, ...state }))
157159
)
158160
}

src/assets/javascripts/components/search/share/index.ts

+7-2
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,11 @@ import {
2525
Subject,
2626
fromEvent
2727
} from "rxjs"
28-
import { map, tap } from "rxjs/operators"
28+
import {
29+
finalize,
30+
map,
31+
tap
32+
} from "rxjs/operators"
2933

3034
import { getLocation } from "~/browser"
3135

@@ -112,7 +116,8 @@ export function mountSearchShare(
112116
/* Create and return component */
113117
return watchSearchShare(el, options)
114118
.pipe(
115-
tap(internal$),
119+
tap(state => internal$.next(state)),
120+
finalize(() => internal$.complete()),
116121
map(state => ({ ref: el, ...state }))
117122
)
118123
}

src/assets/javascripts/components/search/suggest/index.ts

+3-1
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,7 @@ import {
3030
combineLatestWith,
3131
distinctUntilChanged,
3232
filter,
33+
finalize,
3334
map,
3435
observeOn,
3536
tap
@@ -144,7 +145,8 @@ export function mountSearchSuggest(
144145
/* Create and return component */
145146
return result$
146147
.pipe(
147-
tap(internal$),
148+
tap(state => internal$.next(state)),
149+
finalize(() => internal$.complete()),
148150
map(() => ({ ref: el }))
149151
)
150152
}

src/assets/javascripts/components/sidebar/index.ts

+3-1
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@ import {
2828
} from "rxjs"
2929
import {
3030
distinctUntilChanged,
31+
finalize,
3132
map,
3233
observeOn,
3334
tap,
@@ -157,7 +158,8 @@ export function mountSidebar(
157158
/* Create and return component */
158159
return watchSidebar(el, options)
159160
.pipe(
160-
tap(internal$),
161+
tap(state => internal$.next(state)),
162+
finalize(() => internal$.complete()),
161163
map(state => ({ ref: el, ...state }))
162164
)
163165
}

src/assets/javascripts/components/source/_/index.ts

+3-1
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@ import { NEVER, Observable, Subject, defer, of } from "rxjs"
2424
import {
2525
catchError,
2626
filter,
27+
finalize,
2728
map,
2829
shareReplay,
2930
tap
@@ -117,7 +118,8 @@ export function mountSource(
117118
/* Create and return component */
118119
return watchSource(el)
119120
.pipe(
120-
tap(internal$),
121+
tap(state => internal$.next(state)),
122+
finalize(() => internal$.complete()),
121123
map(state => ({ ref: el, ...state }))
122124
)
123125
}

src/assets/javascripts/components/tabs/index.ts

+3-1
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,7 @@
2323
import { Observable, Subject, animationFrameScheduler } from "rxjs"
2424
import {
2525
distinctUntilKeyChanged,
26+
finalize,
2627
map,
2728
observeOn,
2829
switchMap,
@@ -135,7 +136,8 @@ export function mountTabs(
135136
/* Create and return component */
136137
return watchTabs(el, options)
137138
.pipe(
138-
tap(internal$),
139+
tap(state => internal$.next(state)),
140+
finalize(() => internal$.complete()),
139141
map(state => ({ ref: el, ...state }))
140142
)
141143
}

src/assets/javascripts/components/toc/index.ts

+3-1
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,7 @@ import {
3030
bufferCount,
3131
distinctUntilChanged,
3232
distinctUntilKeyChanged,
33+
finalize,
3334
map,
3435
observeOn,
3536
scan,
@@ -267,7 +268,8 @@ export function mountTableOfContents(
267268
const anchors = getElements<HTMLAnchorElement>("[href^=\\#]", el)
268269
return watchTableOfContents(anchors, options)
269270
.pipe(
270-
tap(internal$),
271+
tap(state => internal$.next(state)),
272+
finalize(() => internal$.complete()),
271273
map(state => ({ ref: el, ...state }))
272274
)
273275
}

src/assets/javascripts/components/top/index.ts

+3-1
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,7 @@ import {
3030
bufferCount,
3131
distinctUntilChanged,
3232
distinctUntilKeyChanged,
33+
finalize,
3334
map,
3435
observeOn,
3536
tap,
@@ -170,7 +171,8 @@ export function mountBackToTop(
170171
/* Create and return component */
171172
return watchBackToTop(el, { viewport$, header$, main$ })
172173
.pipe(
173-
tap(internal$),
174+
tap(state => internal$.next(state)),
175+
finalize(() => internal$.complete()),
174176
map(state => ({ ref: el, ...state }))
175177
)
176178
}

src/overrides/assets/javascripts/components/iconsearch/result/index.ts

+3-1
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@ import {
3333
bufferCount,
3434
distinctUntilKeyChanged,
3535
filter,
36+
finalize,
3637
map,
3738
observeOn,
3839
switchMap,
@@ -191,7 +192,8 @@ export function mountIconSearchResult(
191192
/* Create and return component */
192193
return watchIconSearchResult(el, { query$, index$ })
193194
.pipe(
194-
tap(internal$),
195+
tap(state => internal$.next(state)),
196+
finalize(() => internal$.complete()),
195197
map(state => ({ ref: el, ...state }))
196198
)
197199
}

0 commit comments

Comments
 (0)