clapton 0.0.20 → 0.0.21
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/clapton/javascripts/dist/client.js +9 -0
- data/lib/clapton/javascripts/src/client.ts +11 -0
- data/lib/clapton/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 27fa8b6f3ac907d41af32dc550fa4556dc127895ace2e296969b49b8dc8f887a
|
4
|
+
data.tar.gz: 8b5099fd20fc5f804d792c48da12b694755b18e8d51a9f65442ad61e1b2a7f6d
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: be4dabb30c708af3c0ce9b1cb0a20eb1b58d79924e2303c880b2d4b0a563eb304d906d456b105b24999baaaebb05053d618136de336c0b5b579581f07817a9b6
|
7
|
+
data.tar.gz: ddd55a8d86a0c9f5666c7fb686ed137c442e8d377341279856eb140d39a2eb08fe5538f05aa3be29ae9448ce1aee6e64eb0d93187c6bf8a1f45b1f4bdf44f12b
|
@@ -1448,3 +1448,12 @@ document.addEventListener("DOMContentLoaded", async () => {
|
|
1448
1448
|
const event = new Event('clapton:render');
|
1449
1449
|
document.dispatchEvent(event);
|
1450
1450
|
});
|
1451
|
+
window.addEventListener('beforeunload', () => {
|
1452
|
+
sessionStorage.setItem('scrollPosition', window.scrollY.toString());
|
1453
|
+
});
|
1454
|
+
document.addEventListener("clapton:render", () => {
|
1455
|
+
const scrollPosition = sessionStorage.getItem('scrollPosition');
|
1456
|
+
if (scrollPosition) {
|
1457
|
+
window.scrollTo(0, parseInt(scrollPosition));
|
1458
|
+
}
|
1459
|
+
});
|
@@ -45,3 +45,14 @@ document.addEventListener("DOMContentLoaded", async () => {
|
|
45
45
|
const event = new Event('clapton:render');
|
46
46
|
document.dispatchEvent(event);
|
47
47
|
});
|
48
|
+
|
49
|
+
window.addEventListener('beforeunload', () => {
|
50
|
+
sessionStorage.setItem('scrollPosition', window.scrollY.toString());
|
51
|
+
});
|
52
|
+
|
53
|
+
document.addEventListener("clapton:render", () => {
|
54
|
+
const scrollPosition = sessionStorage.getItem('scrollPosition');
|
55
|
+
if (scrollPosition) {
|
56
|
+
window.scrollTo(0, parseInt(scrollPosition));
|
57
|
+
}
|
58
|
+
});
|
data/lib/clapton/version.rb
CHANGED