// Utils import { createNamespace } from '../utils'; import { preventDefault } from '../utils/dom/event'; // Components import Field from '../field'; const [createComponent, bem, t] = createNamespace('search'); export default createComponent({ inheritAttrs: false, props: { label: String, rightIcon: String, modelValue: String, actionText: String, background: String, showAction: Boolean, clearTrigger: String, shape: { type: String, default: 'square', }, clearable: { type: Boolean, default: true, }, leftIcon: { type: String, default: 'search', }, }, emits: ['search', 'cancel', 'keypress'], setup(props, { emit, slots }) { return function () { function Label() { if (slots.label || props.label) { return (