@eturnity/eturnity_reusable_components 7.32.1 → 7.33.0

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,6 +1,6 @@
1
1
  {
2
2
  "name": "@eturnity/eturnity_reusable_components",
3
- "version": "7.32.1",
3
+ "version": "7.33.0",
4
4
  "private": false,
5
5
  "scripts": {
6
6
  "dev": "vue-cli-service serve",
@@ -73,6 +73,7 @@
73
73
  <SelectWrapper v-if="showSelect">
74
74
  <Divider />
75
75
  <Select
76
+ :disabled="isSelectDisabled"
76
77
  :select-width="`${selectWidth}px`"
77
78
  :show-border="false"
78
79
  @input-change="$emit('select-change', $event)"
@@ -511,6 +512,10 @@
511
512
  type: [String, Number],
512
513
  default: null,
513
514
  },
515
+ isSelectDisabled: {
516
+ type: Boolean,
517
+ default: false,
518
+ },
514
519
  },
515
520
  data() {
516
521
  return {
@@ -13,7 +13,7 @@
13
13
  <LabelWrapper
14
14
  v-if="label"
15
15
  :data-id="labelDataId"
16
- :info-text-message="!!infoTextMessage"
16
+ :info-text-message="!!infoTextMessage || !!$slots.infoText"
17
17
  >
18
18
  <InputLabel
19
19
  :font-color="
@@ -181,6 +181,7 @@
181
181
  import Icon from '../../icon'
182
182
  import InputText from '../inputText'
183
183
  import DraggableInputHandle from '../../draggableInputHandle'
184
+ import { debounce } from '../../../utils'
184
185
 
185
186
  const CARET_WIDTH = '30px'
186
187
  const BORDER_WIDTH = '1px'
@@ -733,9 +734,9 @@
733
734
  this.blur()
734
735
  this.$emit('input-change', e)
735
736
  },
736
- optionHovered(e) {
737
+ optionHovered: debounce(function (e) {
737
738
  this.hoveredValue = e
738
- },
739
+ }, 300),
739
740
  mouseEnterHandler() {
740
741
  if (this.hoverDropdown) {
741
742
  this.focus()
@@ -0,0 +1,12 @@
1
+ export function debounce(fn, wait) {
2
+ let timer
3
+ return function (...args) {
4
+ if (timer) {
5
+ clearTimeout(timer)
6
+ }
7
+ const context = this
8
+ timer = setTimeout(() => {
9
+ fn.apply(context, args)
10
+ }, wait)
11
+ }
12
+ }