mirror of
https://github.com/PhotonVision/photonvision
synced 2026-06-29 02:21:41 +00:00
38 lines
760 B
Vue
38 lines
760 B
Vue
<template>
|
|
<div>
|
|
<v-row align="center">
|
|
<v-col :cols="2">
|
|
<span>{{name}}</span>
|
|
</v-col>
|
|
<v-col>
|
|
<v-switch v-model="localValue" color="#4baf62"></v-switch>
|
|
</v-col>
|
|
</v-row>
|
|
</div>
|
|
</template>
|
|
|
|
<script>
|
|
export default {
|
|
name: 'CVSwitch',
|
|
props:['name','value'],
|
|
data() {
|
|
return {
|
|
|
|
}
|
|
},
|
|
computed:{
|
|
localValue:{
|
|
get(){
|
|
return this.value;
|
|
},
|
|
set(value){
|
|
this.$emit('input',value)
|
|
}
|
|
}
|
|
}
|
|
}
|
|
</script>
|
|
|
|
<style lang="" scoped>
|
|
|
|
</style> |