3 <div class="card" :class="item.class">
4 <a :href="item.url" :target="item.target" rel="noreferrer">
5 <div class="card-content">
7 <div v-if="item.logo" class="media-left">
8 <figure class="image is-48x48">
9 <img :src="item.logo" :alt="`${item.name} logo`" />
12 <div v-if="item.icon" class="media-left">
13 <figure class="image is-48x48">
14 <i style="font-size: 35px" :class="['fa-fw', item.icon]"></i>
17 <div class="media-content">
18 <p class="title is-4">{{ item.name }}</p>
19 <p class="subtitle is-6">{{ item.subtitle }}</p>
24 class="notif activity"
26 >{{ activity }}</strong
30 class="notif warnings"
32 >{{ warnings }}</strong
34 <strong v-if="errors > 0" class="notif errors" title="Error">{{
40 title="Connection error to Sonarr API, check url and apikey in config.yml"
45 <div class="tag" :class="item.tagstyle" v-if="item.tag">
46 <strong class="tag-text">#{{ item.tag }}</strong>
68 created: function () {
72 fetchConfig: function () {
73 fetch(`${this.item.url}/api/health?apikey=${this.item.apikey}`)
75 if (response.status != 200) {
76 throw new Error(response.statusText);
78 return response.json();
83 for (var i = 0; i < health.length; i++) {
84 if (health[i].type == "warning") {
86 } else if (health[i].type == "error") {
93 this.serverError = true;
95 fetch(`${this.item.url}/api/queue?apikey=${this.item.apikey}`)
97 if (response.status != 200) {
98 throw new Error(response.statusText);
100 return response.json();
104 for (var i = 0; i < queue.length; i++) {
105 if (queue[i].series) {
112 this.serverError = true;
119 <style scoped lang="scss">
126 font-family: sans-serif;
131 padding-right: 0.35em;
132 padding-left: 0.35em;
134 padding-bottom: 0.2em;
135 border-radius: 0.25em;
141 background-color: #4fb5d6;
145 background-color: #d08d2e;
149 background-color: #e51111;