@tagplus/components 2.1.3 → 2.1.9

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
@@ -8,7 +8,7 @@
8
8
  "email": "bruno@tagplus.com.br"
9
9
  }
10
10
  ],
11
- "version": "2.1.3",
11
+ "version": "2.1.9",
12
12
  "main": "./dist/tp.common.js",
13
13
  "directories": {
14
14
  "lib": "src/lib"
@@ -426,10 +426,6 @@ export default {
426
426
  },
427
427
 
428
428
  methods: {
429
- handleFocus (event) {
430
- this.focused = true
431
- this.$emit('focus', event)
432
- },
433
429
  /**
434
430
  * Adiciona um evento no elemento dinamicamente
435
431
  * @args el {Object} Elemento que tem o listener
@@ -525,7 +521,7 @@ export default {
525
521
  const cachedOption = this.cachedOptions[i]
526
522
  const isEqual = isObject
527
523
  ? getValueByPath(cachedOption.value, this.valueKey) ===
528
- getValueByPath(value, this.valueKey)
524
+ getValueByPath(value, this.valueKey)
529
525
  : cachedOption.value === value
530
526
 
531
527
  if (isEqual) {
@@ -680,7 +676,7 @@ export default {
680
676
  </script>
681
677
 
682
678
  <style lang="scss" scoped>
683
- :deep() {
679
+ :deep(){
684
680
  .el-input-group__append {
685
681
  padding: 0px 6px 0px 0px;
686
682
  border: 0;
@@ -522,7 +522,10 @@ export default {
522
522
  if (Array.isArray(this.value)) {
523
523
  this.value.forEach((item, key) => {
524
524
  this.suggestionsList.forEach(suggestion => {
525
- if (suggestion[this.valueKey] === item) {
525
+ const formatItem = parseInt(item) ? parseInt(item) : item
526
+ const formatSuggestion = parseInt(suggestion[this.valueKey]) ? parseInt(suggestion[this.valueKey]) : suggestion[this.valueKey]
527
+
528
+ if (formatSuggestion === formatItem) {
526
529
  this.selectedLabelsArray.push(suggestion)
527
530
  }
528
531
  })