Loading karaokatalog/ui/static/components/pieces/Song.js 0 → 100644 +25 −0 Original line number Diff line number Diff line export default { view: function (vnode) { const { song } = vnode.attrs return m("article.song", [ m(".info", [ m(".title", song.title), m(".artist", song.artist), ]), m(".actions", [ m( "span.material-symbols-outlined.heart-icon", { class: song.favorite ? "is-favorite" : "", onclick: () => song.toggleFavorite(), title: song.favorite ? "Als Favorit entfernen" : "Als Favorit markieren", }, "favorite", ), ]), ]) }, } Loading
karaokatalog/ui/static/components/pieces/Song.js 0 → 100644 +25 −0 Original line number Diff line number Diff line export default { view: function (vnode) { const { song } = vnode.attrs return m("article.song", [ m(".info", [ m(".title", song.title), m(".artist", song.artist), ]), m(".actions", [ m( "span.material-symbols-outlined.heart-icon", { class: song.favorite ? "is-favorite" : "", onclick: () => song.toggleFavorite(), title: song.favorite ? "Als Favorit entfernen" : "Als Favorit markieren", }, "favorite", ), ]), ]) }, }