|
@ -7,7 +7,7 @@ |
|
|
flex-shrink: 0; |
|
|
flex-shrink: 0; |
|
|
display:flex; |
|
|
display:flex; |
|
|
align-items: center; |
|
|
align-items: center; |
|
|
background:#fff; |
|
|
background:var(--bg,#fff); |
|
|
margin:30rpx; |
|
|
margin:30rpx; |
|
|
border-radius: 40rpx; |
|
|
border-radius: 40rpx; |
|
|
padding:6rpx; |
|
|
padding:6rpx; |
|
@ -90,7 +90,7 @@ |
|
|
</style> |
|
|
</style> |
|
|
<template> |
|
|
<template> |
|
|
<view class="d-search" @click="isShow=false"> |
|
|
<view class="d-search" @click="isShow=false"> |
|
|
<view class="search" @click.stop=""> |
|
|
<view class="search" @click.stop="" :style="{'--bg':background}"> |
|
|
<u-icon name="search" color="#999999" size="20"/> |
|
|
<u-icon name="search" color="#999999" size="20"/> |
|
|
<input placeholder="请输入搜索内容" :value="(list.find(v=>v.value==value)||{label:''}).label||value" auto-blur @focus="isShow=true" @input="$emit('input',$event.detail.value)" @confirm="isShow=false;$emit('search')"/> |
|
|
<input placeholder="请输入搜索内容" :value="(list.find(v=>v.value==value)||{label:''}).label||value" auto-blur @focus="isShow=true" @input="$emit('input',$event.detail.value)" @confirm="isShow=false;$emit('search')"/> |
|
|
<text class="plant-zengjia" v-if="value" @click="$emit('input','');$emit('search')"/> |
|
|
<text class="plant-zengjia" v-if="value" @click="$emit('input','');$emit('search')"/> |
|
@ -120,6 +120,10 @@ export default { |
|
|
type:[String,Number], |
|
|
type:[String,Number], |
|
|
default:'' |
|
|
default:'' |
|
|
}, |
|
|
}, |
|
|
|
|
|
background:{ |
|
|
|
|
|
type:String, |
|
|
|
|
|
default:"#fff" |
|
|
|
|
|
} |
|
|
}, |
|
|
}, |
|
|
data(){ |
|
|
data(){ |
|
|
return{ |
|
|
return{ |
|
|