Files
PhotonVision/chameleon-client/src/components/ch-select.vue

46 lines
1.1 KiB
Vue
Raw Normal View History

2019-03-15 21:47:44 +02:00
<template>
2019-03-23 20:00:52 +02:00
<row type="flex" justify="start" align="middle" :gutter="1" >
<Col>
<h4 style="width:100% ; margin-right:10px;">{{title}}</h4>
2019-03-15 21:47:44 +02:00
</Col>
2019-03-23 20:00:52 +02:00
<col>
<i-select v-model="value" size="small" style="width:40%" v-bind:placeholder="placeholdert" @on-change="handleInput">
2019-03-15 21:47:44 +02:00
<i-option v-for="item in list" :value="item" :key="item">{{item}}</i-option>
</i-select>
</col>
</row>
</template>
<script>
export default {
name: 'ch-select',
props:{
title:"",
placeholdert:"",
2019-03-23 20:00:52 +02:00
list:{}
2019-03-15 21:47:44 +02:00
},
data() {
return {
content:this.value
}
},
methods: {
handleInput() {
this.$emit('input',this.value);
2019-03-15 21:47:44 +02:00
}
}
}
</script>
2019-03-16 21:47:34 +02:00
<style>
2019-03-15 21:47:44 +02:00
h4 {
color: #e6ebf1;
}
2019-03-16 21:47:34 +02:00
.ivu-select-selection{
background-color: #2c3e50 !important;
}
.ivu-select-selected-value{
color: #fff !important;
}
2019-03-15 21:47:44 +02:00
</style>