aboutsummaryrefslogtreecommitdiff
path: root/ext/display-templates.html
diff options
context:
space:
mode:
authortoasted-nutbread <toasted-nutbread@users.noreply.github.com>2021-02-15 21:34:10 -0500
committerGitHub <noreply@github.com>2021-02-15 21:34:10 -0500
commit55f5182ca93778b74105c9c9097174d3138cad9e (patch)
treefd02c62d1de5accd2a4d1ddfa37cd5a568314ce5 /ext/display-templates.html
parentf2a387237bac02d93d1664ed7acb6a10108915b6 (diff)
Audio popup menu primary card audio selection (#1406)
* Add card icon to audio menu items * Update cache data format * Create _getCacheItem * Add _playAudioFromSource function * Implement default card audio info * Specify exact audio to download when an override is assigned * Abstract using _getMenuItemSourceInfo * Update downloadability check * Update the main audio menu buttons to also assign the default source
Diffstat (limited to 'ext/display-templates.html')
-rw-r--r--ext/display-templates.html5
1 files changed, 4 insertions, 1 deletions
diff --git a/ext/display-templates.html b/ext/display-templates.html
index 82a9b97f..3074e287 100644
--- a/ext/display-templates.html
+++ b/ext/display-templates.html
@@ -158,6 +158,9 @@
<!-- Popup menu -->
<template id="audio-button-popup-menu-template"><div class="popup-menu-container scan-disable audio-button-popup-menu" tabindex="-1" role="dialog"><div class="popup-menu popup-menu-auto-size"><div class="popup-menu-body"></div></div></div></template>
-<template id="audio-button-popup-menu-item-template"><div class="popup-menu-item-group"><button class="popup-menu-item" data-menu-action="playAudioFromSource"><div class="popup-menu-item-icon icon" data-icon="none"></div><span class="popup-menu-item-label"></span></button></div></template>
+<template id="audio-button-popup-menu-item-template"><div class="popup-menu-item-group">
+ <button class="popup-menu-item popup-menu-item-audio-button" data-menu-action="playAudioFromSource"><div class="popup-menu-item-icon icon" data-icon="none"></div><span class="popup-menu-item-label"></span></button>
+ <button class="popup-menu-item popup-menu-item-set-primary-audio-button" data-menu-action="setPrimaryAudio" title="Use as audio for Anki card"><div class="popup-menu-item-icon icon" data-icon="note-card"></div></button>
+</div></template>
</body></html>