Skip to content

Commit 53d8a6e

Browse files
Add files via upload
1 parent abda9cf commit 53d8a6e

File tree

1 file changed

+0
-30
lines changed

1 file changed

+0
-30
lines changed

index.html

Lines changed: 0 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -25,36 +25,6 @@
2525
text-align: center;
2626
}
2727
</style>
28-
<script>
29-
function loadVideo(element) {
30-
const iframe = element.querySelector('iframe');
31-
const src = iframe.getAttribute('data-src');
32-
iframe.src = src;
33-
}
34-
35-
function handleIntersection(entries) {
36-
entries.forEach((entry) => {
37-
if (entry.isIntersecting) {
38-
loadVideo(entry.target);
39-
observer.unobserve(entry.target);
40-
}
41-
});
42-
}
43-
44-
const videoSections = document.querySelectorAll('section');
45-
46-
const options = {
47-
root: null,
48-
rootMargin: '0px',
49-
threshold: 0.1
50-
};
51-
52-
const observer = new IntersectionObserver(handleIntersection, options);
53-
54-
videoSections.forEach((section) => {
55-
observer.observe(section);
56-
});
57-
</script>
5828
</head>
5929
<body>
6030
<header>

0 commit comments

Comments
 (0)