summaryrefslogtreecommitdiff
path: root/layout
diff options
context:
space:
mode:
authorDoge Gui <[email protected]>2022-11-22 21:19:36 +0300
committer135e2 <[email protected]>2022-12-29 17:19:51 +0800
commitdf82c591c6177d0ab0a1656f368ac84e667ad0a2 (patch)
tree0382216dd62ebee148487fc82a5428bd81197035 /layout
parent1fa0c6cd4c93d37cb1aca86318476fa3b21c2b77 (diff)
downloadchromate-df82c591c6177d0ab0a1656f368ac84e667ad0a2.tar.gz
chromate-df82c591c6177d0ab0a1656f368ac84e667ad0a2.tar.bz2
chromate-df82c591c6177d0ab0a1656f368ac84e667ad0a2.zip
Fix player not working error
Conflicts: layout/post.ejs Co-authored-by: 135e2 <[email protected]>
Diffstat (limited to 'layout')
-rw-r--r--layout/post.ejs5
1 files changed, 3 insertions, 2 deletions
diff --git a/layout/post.ejs b/layout/post.ejs
index 67f1ed0..71f8f15 100644
--- a/layout/post.ejs
+++ b/layout/post.ejs
@@ -54,14 +54,15 @@
<% } %>
<script>
window.addEventListener("load", () => {
- if (typeof Chapter !== 'undefined') Shikwasa.use(Chapter);
+ const { Player } = window.Shikwasa;
+ if (typeof Chapter !== 'undefined') Player.use(Chapter);
// Check for local audio media url
let url = "<%= page.podcast.media.url %>";
if (!(url.startsWith("http://") || url.startsWith("https://")))
url = "<%= full_url_for(path, {relative: false}) %>".replace("index.html", '') + url;
- const player = new Shikwasa({
+ const player = new Player({
container: () => document.querySelector('.post-podcast-player'),
audio: {
title: "<%= page.title %>",