@vyr/design 0.0.1 → 0.0.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,16 +1 @@
1
- {
2
- "name": "@vyr/design",
3
- "version": "0.0.1",
4
- "main": "./src/index.ts",
5
- "dependencies": {
6
- "vue": "3.5.22",
7
- "@popperjs/core": "^2.11.8",
8
- "@vyr/locale": "0.0.1",
9
- "async-validator": "^4.2.5",
10
- "tinycolor2": "1.6.0"
11
- },
12
- "files": [
13
- "package.json",
14
- "src/"
15
- ]
16
- }
1
+ {"name":"@vyr/design","version":"0.0.2","main":"./src/index.ts","dependencies":{"vue":"3.5.22","@popperjs/core":"^2.11.8","@vyr/locale":"0.0.2","async-validator":"^4.2.5","tinycolor2":"1.6.0"},"files":["package.json","src/"]}
@@ -5,7 +5,7 @@
5
5
  @mouseenter="e => trigger('mouseenter', e)" @mouseleave="e => trigger('mouseleave', e)"
6
6
  @contextmenu="e => trigger('rightClick', e)">
7
7
  <slot v-if="left">
8
- <div class="option-label">
8
+ <div class="option-label" :title="label">
9
9
  <slot name="label">{{ label }}</slot>
10
10
  </div>
11
11
  </slot>
@@ -15,7 +15,7 @@
15
15
  </slot>
16
16
  </div>
17
17
  <slot v-if="left === false">
18
- <div class="option-label">
18
+ <div class="option-label" :title="label">
19
19
  <slot name="label">{{ label }}</slot>
20
20
  </div>
21
21
  </slot>
@@ -6,10 +6,10 @@
6
6
  <template #trigger>
7
7
  <slot name="trigger">
8
8
  <div class="select-wrapper">
9
- <vyr-input :model-value="curInputValue" :readonly="curReadonly || searchable === false"
10
- :clearable="curClearable" :readonly-clearable="curReadonlyClearable" :placeholder="curPlaceholder"
11
- :width="`100%`" :draggable :dragkey @focus="startSearch" @blur="clearSearch"
12
- @update:model-value="updateSearch" @click="stopClosePopover" @clear.stop="clear">
9
+ <vyr-input :model-value="curInputValue" :readonly="curReadonly" :clearable="curClearable"
10
+ :readonly-clearable="curReadonlyClearable" :placeholder="curPlaceholder" :width="`100%`" :draggable
11
+ :dragkey @focus="startSearch" @blur="clearSearch" @update:model-value="updateSearch"
12
+ @click="stopClosePopover" @clear.stop="clear">
13
13
  <template #icon="icon">
14
14
  <i v-if="showClear(icon.clearable, curReadonly, curReadonlyClearable, curInputValue)"
15
15
  class="vyrfont vyr-shanchu vyr-input-icon" @click.stop="clear"></i>
@@ -141,7 +141,7 @@ const change = (item: Option, e: MouseEvent) => {
141
141
  const value = curGetter.value(item)
142
142
  if (props.modelValue !== value) {
143
143
  emit('update:modelValue', value)
144
- emit('change', value)
144
+ emit('change', value, item)
145
145
  }
146
146
  e.stopPropagation()
147
147
  close()
@@ -71,8 +71,6 @@ const useSearch = (props: { searchable: SearchFunctionProp | boolean, data: Opti
71
71
  searchState.value.status = 2
72
72
  searchState.value.content = value
73
73
  searchState.value.timeout = useTimer(delaySearch, 200)
74
-
75
- setTimeout
76
74
  }
77
75
  const delayClear = () => {
78
76
  searchState.value.status = 0