orchard/src/renderer/views/components/artwork-material.ejs
2022-08-04 05:27:29 +01:00

36 lines
746 B
Text

<script type="text/x-template" id="artwork-material">
<div class="artworkMaterial">
<mediaitem-artwork :url="src" :size="500" v-for="image in images" />
</div>
</script>
<script>
Vue.component('artwork-material', {
template: '#artwork-material',
data: function() {
return {
src: ""
}
},
mounted() {
this.src = app.getMediaItemArtwork(this.url, this.size)
},
props: {
url: {
type: String,
required: true
},
size: {
type: [String, Number],
required: false,
default: '32'
},
images: {
type: [String, Number],
required: false,
default: '2'
}
},
methods: {}
});
</script>