]> git.r.bdr.sh - rbdr/sorting-hat-renderer/blob - lib/components/status.js
4a8b0991594e22c43de90138fdd8ec8563d503f5
[rbdr/sorting-hat-renderer] / lib / components / status.js
1 import Vue from 'vue';
2 import DataService from '../services/data';
3
4 const internals = {};
5
6 export default Vue.component('posts', {
7 template: '<div class="status-widget">' +
8 '<transition name="fade">' +
9 '<div v-if="state === 0" class="waiting-message">Waiting</div>' +
10 '<div v-if="state === 2 && !winner" class="no-winner">Could not read you</div>' +
11 '<div v-if="state === 2 && winner" class="winner" v-bind:class="[winner]">{{winner}}</div>' +
12 '</transition>' +
13 '</div>',
14
15 data: DataService.data
16 });