mirror of
https://github.com/tenrok/vue2-datepicker.git
synced 2026-06-24 22:23:00 +03:00
feat: add slot input
This commit is contained in:
@@ -8,6 +8,7 @@
|
|||||||
}"
|
}"
|
||||||
>
|
>
|
||||||
<div v-if="!inline" class="mx-input-wrapper" @mousedown="openPopup" @touchstart="openPopup">
|
<div v-if="!inline" class="mx-input-wrapper" @mousedown="openPopup" @touchstart="openPopup">
|
||||||
|
<slot name="input">
|
||||||
<input
|
<input
|
||||||
ref="input"
|
ref="input"
|
||||||
v-bind="{ name: 'date', type: 'text', autocomplete: 'off', ...inputAttr }"
|
v-bind="{ name: 'date', type: 'text', autocomplete: 'off', ...inputAttr }"
|
||||||
@@ -22,6 +23,7 @@
|
|||||||
@input="handleInputInput"
|
@input="handleInputInput"
|
||||||
@change="handleInputChange"
|
@change="handleInputChange"
|
||||||
/>
|
/>
|
||||||
|
</slot>
|
||||||
<i v-if="showClearIcon" class="mx-icon-clear" @mousedown.stop="handleClear">
|
<i v-if="showClearIcon" class="mx-icon-clear" @mousedown.stop="handleClear">
|
||||||
<slot name="icon-clear">
|
<slot name="icon-clear">
|
||||||
<icon-close></icon-close>
|
<icon-close></icon-close>
|
||||||
|
|||||||
Reference in New Issue
Block a user