Created
December 22, 2017 12:43
-
-
Save jongravois/e1f9864f7813f7afac44a7beb92d7252 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<template> | |
<section class="pane sales__pane"> | |
<h1 class="pane__title">Sales</h1> | |
<div class="pane__content"> | |
<div class="level" style="margin-top: 40px;"> | |
<div class="level-left"> | |
<div class="level-item"> | |
<div class="stats__card"> | |
<span style="font-size: 0.8em; color: #bebebe"> | |
Sales vs Target | |
</span><br> | |
{{ceo_sales.count_sales}} | |
({{ceo_sales.target_percent}}%) | |
</span> | |
</div> | |
</div> | |
</div> | |
<div class="level-right"> | |
<div class="level-item"> | |
<div class="stats__card"> | |
<span style="font-size: 0.8em; color: #bebebe"> | |
Performance vs Model | |
</span><br> | |
{{ceo_sales.performance_v_model}} | |
</div> | |
</div> | |
</div> | |
</div> | |
<div class="chart"> | |
<stat-chart :ceo_sales="ceo_sales"></stat-chart> | |
</div> | |
</div> | |
<br><br> | |
</section> | |
</template> | |
<script type="text/babel"> | |
import { mapGetters } from 'vuex'; | |
import statChart from '../charts/CeoSales'; | |
export default { | |
data() { | |
return { | |
ceo_sales: {} | |
}; | |
}, | |
components: { | |
statChart | |
}, | |
created() {}, | |
watch: { | |
ceo_dash(nv, ov) { | |
this.ceo_sales = nv.sales; | |
} | |
}, | |
props: [], | |
computed: { | |
...mapGetters([ | |
'ceo_dash' | |
]) | |
}, | |
methods: {}, | |
mounted() {} | |
}; | |
</script> | |
<style scoped> | |
.pane__content { | |
color: white; | |
width: 100% !important; | |
height: 100% !important; | |
padding: 0 !important; | |
margin: 0 0.25em; | |
} | |
.chart { | |
height: 80% !important; | |
width: 94% !important; | |
margin: auto; | |
grid-column: 1 / span 2; | |
grid-row: 2; | |
} | |
/* iPads (portrait) ----------- */ | |
@media only screen | |
and (min-device-width : 768px) | |
and (max-device-width : 1023px) { | |
.sales__pane { | |
display: grid; | |
grid-template-columns: 1fr 1fr; | |
grid-template-rows: 0.5fr 1fr 1fr; | |
grid-gap: 1.5em; | |
} | |
} | |
/* Laptops ----------- */ | |
@media only screen | |
and (min-device-width : 1024px) | |
and (max-device-width : 1599px) { | |
} | |
/* Large screens ----------- */ | |
@media only screen and (min-width : 1600px) { | |
} | |
</style> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment