Updated DataView to V3

pull/496/head
Cagatay Civici 2020-09-23 15:50:30 +03:00
parent 1e350808b7
commit 99a1ee7dfc
1 changed files with 4 additions and 4 deletions

View File

@ -12,25 +12,25 @@
<script> <script>
export default { export default {
props: { props: {
value: String modelValue: String
}, },
computed: { computed: {
buttonListClass(){ buttonListClass(){
return [ return [
'p-button p-button-icon-only', 'p-button p-button-icon-only',
{'p-highlight': this.value === 'list'} {'p-highlight': this.modelValue === 'list'}
] ]
}, },
buttonGridClass() { buttonGridClass() {
return [ return [
'p-button p-button-icon-only', 'p-button p-button-icon-only',
{'p-highlight': this.value === 'grid'} {'p-highlight': this.modelValue === 'grid'}
] ]
} }
}, },
methods: { methods: {
changeLayout(layout){ changeLayout(layout){
this.$emit('input', layout); this.$emit('update:modelValue', layout);
} }
} }
} }