@oub/fusion 0.2.17 → 0.2.19

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.
@@ -41,6 +41,10 @@ declare const _default: import("vue").DefineComponent<{
41
41
  type: StringConstructor;
42
42
  default: string;
43
43
  };
44
+ minSearchLength: {
45
+ type: NumberConstructor;
46
+ default: number;
47
+ };
44
48
  helperLabel: {
45
49
  type: StringConstructor;
46
50
  default: string;
@@ -115,7 +119,7 @@ declare const _default: import("vue").DefineComponent<{
115
119
  handleKeydownEnter(): void;
116
120
  closePanel(): void;
117
121
  handleKeyDown(event: KeyboardEvent): void;
118
- }, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("update:modelValue" | "keydown:enter" | "select:blur" | "select:focus")[], "update:modelValue" | "keydown:enter" | "select:blur" | "select:focus", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
122
+ }, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("update:modelValue" | "keydown:enter" | "select:blur" | "select:focus" | "selected:option" | "update:input")[], "update:modelValue" | "keydown:enter" | "select:blur" | "select:focus" | "selected:option" | "update:input", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
119
123
  id: {
120
124
  type: StringConstructor;
121
125
  required: true;
@@ -156,6 +160,10 @@ declare const _default: import("vue").DefineComponent<{
156
160
  type: StringConstructor;
157
161
  default: string;
158
162
  };
163
+ minSearchLength: {
164
+ type: NumberConstructor;
165
+ default: number;
166
+ };
159
167
  helperLabel: {
160
168
  type: StringConstructor;
161
169
  default: string;
@@ -212,6 +220,8 @@ declare const _default: import("vue").DefineComponent<{
212
220
  "onKeydown:enter"?: ((...args: any[]) => any) | undefined;
213
221
  "onSelect:blur"?: ((...args: any[]) => any) | undefined;
214
222
  "onSelect:focus"?: ((...args: any[]) => any) | undefined;
223
+ "onSelected:option"?: ((...args: any[]) => any) | undefined;
224
+ "onUpdate:input"?: ((...args: any[]) => any) | undefined;
215
225
  }, {
216
226
  label: string;
217
227
  title: string;
@@ -230,6 +240,7 @@ declare const _default: import("vue").DefineComponent<{
230
240
  searchLoading: boolean;
231
241
  searchErrorTitle: string;
232
242
  searchErrorDescription: string;
243
+ minSearchLength: number;
233
244
  autofocus: boolean;
234
245
  ariaLabel: string;
235
246
  }, {}>;
package/dist/fusion.js CHANGED
@@ -11542,6 +11542,10 @@ const uv = /* @__PURE__ */ Le(x0, [["render", U0], ["__scopeId", "data-v-1cc3fea
11542
11542
  type: String,
11543
11543
  default: ""
11544
11544
  },
11545
+ minSearchLength: {
11546
+ type: Number,
11547
+ default: 2
11548
+ },
11545
11549
  helperLabel: {
11546
11550
  type: String,
11547
11551
  default: ""
@@ -11591,7 +11595,7 @@ const uv = /* @__PURE__ */ Le(x0, [["render", U0], ["__scopeId", "data-v-1cc3fea
11591
11595
  default: "fusion-searchable-input"
11592
11596
  }
11593
11597
  },
11594
- emits: ["update:modelValue", "select:blur", "select:focus", "keydown:enter"],
11598
+ emits: ["update:modelValue", "select:blur", "select:focus", "keydown:enter", "selected:option", "update:input"],
11595
11599
  data() {
11596
11600
  return {
11597
11601
  selected: this.modelValue,
@@ -11622,10 +11626,14 @@ const uv = /* @__PURE__ */ Le(x0, [["render", U0], ["__scopeId", "data-v-1cc3fea
11622
11626
  },
11623
11627
  methods: {
11624
11628
  handleSelect: function(e) {
11625
- this.selected = e, this.interactionStates.opened = !1, this.$emit("update:modelValue", this.selected);
11629
+ this.selected = e, this.interactionStates.opened = !1, this.$emit("update:modelValue", this.selected), this.$emit("selected:option", this.selected);
11626
11630
  },
11627
11631
  updateInput(e) {
11628
- this.searchInputValue = e, this.interactionStates.opened = e.length > 0, this.$emit("update:modelValue", this.searchInputValue);
11632
+ if (this.searchInputValue = e, e.length < this.minSearchLength) {
11633
+ this.interactionStates.opened = !1;
11634
+ return;
11635
+ }
11636
+ this.interactionStates.opened = !0, this.$emit("update:input", this.searchInputValue);
11629
11637
  },
11630
11638
  handleInputClick() {
11631
11639
  this.searchInputValue.length > 0 && (this.interactionStates.opened = !0);
@@ -11713,7 +11721,7 @@ function M0(e, t, n, r, a, o) {
11713
11721
  }, null, 8, ["select-id", "options", "search-text", "search-placeholder", "search-loading", "search-error-title", "search-error-description", "selected", "onHandle:select", "onHandle:close"])) : Q("", !0)
11714
11722
  ], 8, V0);
11715
11723
  }
11716
- const dv = /* @__PURE__ */ Le(Q0, [["render", M0], ["__scopeId", "data-v-8ff4c318"]]), L0 = Ce({
11724
+ const dv = /* @__PURE__ */ Le(Q0, [["render", M0], ["__scopeId", "data-v-002807fa"]]), L0 = Ce({
11717
11725
  name: "SVGDecrement"
11718
11726
  }), H0 = {
11719
11727
  width: "21",