Spaces:
Running
Running
File size: 1,022 Bytes
d6b8d19 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 |
<!-- airbnb Lottfile animation version -->
<script src="https://cdnjs.cloudflare.com/ajax/libs/bodymovin/5.7.2/lottie.min.js"></script>
<!-- <script src="https://unpkg.com/@dotlottie/player-component@1.0.0/dist/dotlottie-player.js"></script> -->
<script>
// get acceess to the right sidebar
const quartoMarginSidebar = document.getElementById("quarto-margin-sidebar");
// generate a place where the lotti animation shall be placed
const lottieContainer = document.createElement("div");
// Load the Lottie animation
const animation = lottie.loadAnimation({
container: lottieContainer, // HTML element to render the animation in
renderer: 'svg', // Renderer type
loop: true, // Whether the animation should loop
autoplay: true, // Whether the animation should play automatically
path: '../7_Animation/bismillah.json' // URL or file path to your animation JSON file
});
quartoMarginSidebar.insertBefore(lottieContainer, quartoMarginSidebar.firstChild);
// Play the animation
animation.play();
</script> |