Преглед на файлове

修改时间框左键事件

ZaiZai преди 2 години
родител
ревизия
f6637da015
променени са 1 файла, в които са добавени 4 реда и са изтрити 1 реда
  1. 4 1
      packages/components/time-picker/src/common/picker.vue

+ 4 - 1
packages/components/time-picker/src/common/picker.vue

@@ -99,8 +99,9 @@
         >
           <component :is="triggerIcon" />
         </el-icon>
+        <!-- id && id[0]-->
         <input
-          :id="id && id[0]"
+          :id="(id as string | undefined)"
           autocomplete="off"
           :name="name && name[0]"
           :placeholder="startPlaceholder"
@@ -108,6 +109,7 @@
           :disabled="pickerDisabled"
           :readonly="!editable || readonly"
           :class="nsRange.b('input')"
+          :data-test="(id as string | undefined)"
           @click="handleClickInput"
           @mousedown="onMouseDownInput"
           @input="handleStartInput"
@@ -118,6 +120,7 @@
         <slot name="range-separator">
           <span :class="nsRange.b('separator')">{{ rangeSeparator }}</span>
         </slot>
+        <!-- id && id[1]-->
         <input
           :id="id && id[1]"
           autocomplete="off"