metronics-vue 1.1.12 → 1.2.12

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.
@@ -5576,7 +5576,7 @@ function Sr(i, s, t, e, n, r) {
5576
5576
  }
5577
5577
  const Ir = /* @__PURE__ */ N(Er, [["render", Sr]]), Ar = {
5578
5578
  props: {
5579
- modelValue: [String, Number],
5579
+ modelValue: [String, Number, Array],
5580
5580
  // Fix type declaration
5581
5581
  options: {
5582
5582
  type: Array,
@@ -5610,7 +5610,11 @@ const Ir = /* @__PURE__ */ N(Er, [["render", Sr]]), Ar = {
5610
5610
  type: Boolean,
5611
5611
  default: !1
5612
5612
  },
5613
- label: String
5613
+ label: String,
5614
+ multiple: {
5615
+ type: Boolean,
5616
+ default: !1
5617
+ }
5614
5618
  },
5615
5619
  data() {
5616
5620
  return {
@@ -5628,13 +5632,20 @@ const Ir = /* @__PURE__ */ N(Er, [["render", Sr]]), Ar = {
5628
5632
  return "";
5629
5633
  },
5630
5634
  inputRequired() {
5631
- return this.required && !this.modelValue;
5635
+ return this.required ? this.multiple ? !this.modelValue.length : !this.modelValue : !1;
5632
5636
  }
5633
5637
  },
5634
5638
  methods: {
5635
5639
  handleInput(i) {
5636
- const s = i.target.value;
5637
- this.$emit("update:modelValue", s === "close" ? "" : s);
5640
+ if (this.multiple) {
5641
+ const s = Array.from(i.target.selectedOptions).map(
5642
+ (t) => t.value
5643
+ );
5644
+ this.$emit("update:modelValue", s);
5645
+ } else {
5646
+ const s = i.target.value;
5647
+ this.$emit("update:modelValue", s === "close" ? "" : s);
5648
+ }
5638
5649
  }
5639
5650
  }
5640
5651
  }, Lr = {