@oub/fusion 0.2.49 → 0.2.51

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.
@@ -51,6 +51,7 @@ declare const _default: import("vue").DefineComponent<{
51
51
  }, {}, {
52
52
  closePanel(): void;
53
53
  handleSelect(option: FusionSelectOption): void;
54
+ handleInput(inputValue: string): void;
54
55
  handleKeydownSelect(event: KeyboardEvent, option: FusionSelectOption): void;
55
56
  }, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("handle:select" | "handle:search" | "handle:close")[], "handle:select" | "handle:search" | "handle:close", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
56
57
  theme: {
@@ -23,7 +23,7 @@ declare const _default: import("vue").DefineComponent<{
23
23
  type: StringConstructor;
24
24
  default: string;
25
25
  };
26
- modelValue: {
26
+ input: {
27
27
  type: StringConstructor;
28
28
  default: string;
29
29
  };
@@ -80,7 +80,7 @@ declare const _default: import("vue").DefineComponent<{
80
80
  handleMouseover(): void;
81
81
  handleMouseleave(): void;
82
82
  focus(): void;
83
- }, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("input:blur" | "input:focus" | "update:modelValue" | "keydown:enter")[], "input:blur" | "input:focus" | "update:modelValue" | "keydown:enter", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
83
+ }, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("input:blur" | "input:focus" | "keydown:enter" | "update:input")[], "input:blur" | "input:focus" | "keydown:enter" | "update:input", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
84
84
  id: {
85
85
  type: StringConstructor;
86
86
  required: true;
@@ -105,7 +105,7 @@ declare const _default: import("vue").DefineComponent<{
105
105
  type: StringConstructor;
106
106
  default: string;
107
107
  };
108
- modelValue: {
108
+ input: {
109
109
  type: StringConstructor;
110
110
  default: string;
111
111
  };
@@ -144,15 +144,15 @@ declare const _default: import("vue").DefineComponent<{
144
144
  }>> & {
145
145
  "onInput:blur"?: ((...args: any[]) => any) | undefined;
146
146
  "onInput:focus"?: ((...args: any[]) => any) | undefined;
147
- "onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
148
147
  "onKeydown:enter"?: ((...args: any[]) => any) | undefined;
148
+ "onUpdate:input"?: ((...args: any[]) => any) | undefined;
149
149
  }, {
150
+ input: string;
150
151
  label: string;
151
152
  title: string;
152
153
  dataTest: string;
153
154
  type: string;
154
155
  disabled: boolean;
155
- modelValue: string;
156
156
  placeholder: string;
157
157
  readonly: boolean;
158
158
  required: boolean;
@@ -23,7 +23,7 @@ declare const _default: import("vue").DefineComponent<{
23
23
  type: StringConstructor;
24
24
  default: string;
25
25
  };
26
- modelValue: {
26
+ input: {
27
27
  type: StringConstructor;
28
28
  default: string;
29
29
  };
@@ -57,18 +57,12 @@ declare const _default: import("vue").DefineComponent<{
57
57
  focused: boolean;
58
58
  };
59
59
  showPassword: boolean;
60
- }, {
61
- inputStates(): {
62
- focused: boolean;
63
- disabled: boolean;
64
- error: boolean;
65
- };
66
- }, {
67
- updateInput(): void;
60
+ }, {}, {
61
+ updateInput(value: string): void;
68
62
  handleFocus(): void;
69
63
  handleBlur(): void;
70
64
  handleKeydownEnter(): void;
71
- }, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("input:blur" | "input:focus" | "update:modelValue" | "keydown:enter")[], "input:blur" | "input:focus" | "update:modelValue" | "keydown:enter", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
65
+ }, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("input:blur" | "input:focus" | "keydown:enter" | "update:input")[], "input:blur" | "input:focus" | "keydown:enter" | "update:input", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
72
66
  id: {
73
67
  type: StringConstructor;
74
68
  required: true;
@@ -93,7 +87,7 @@ declare const _default: import("vue").DefineComponent<{
93
87
  type: StringConstructor;
94
88
  default: string;
95
89
  };
96
- modelValue: {
90
+ input: {
97
91
  type: StringConstructor;
98
92
  default: string;
99
93
  };
@@ -124,12 +118,12 @@ declare const _default: import("vue").DefineComponent<{
124
118
  }>> & {
125
119
  "onInput:blur"?: ((...args: any[]) => any) | undefined;
126
120
  "onInput:focus"?: ((...args: any[]) => any) | undefined;
127
- "onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
128
121
  "onKeydown:enter"?: ((...args: any[]) => any) | undefined;
122
+ "onUpdate:input"?: ((...args: any[]) => any) | undefined;
129
123
  }, {
124
+ input: string;
130
125
  dataTest: string;
131
126
  disabled: boolean;
132
- modelValue: string;
133
127
  placeholder: string;
134
128
  required: boolean;
135
129
  autocomplete: string;
@@ -31,7 +31,7 @@ declare const _default: import("vue").DefineComponent<{
31
31
  type: StringConstructor;
32
32
  default: string;
33
33
  };
34
- hasError: {
34
+ error: {
35
35
  type: BooleanConstructor;
36
36
  default: boolean;
37
37
  };
@@ -84,7 +84,7 @@ declare const _default: import("vue").DefineComponent<{
84
84
  type: StringConstructor;
85
85
  default: string;
86
86
  };
87
- hasError: {
87
+ error: {
88
88
  type: BooleanConstructor;
89
89
  default: boolean;
90
90
  };
@@ -102,6 +102,6 @@ declare const _default: import("vue").DefineComponent<{
102
102
  modelValue: string;
103
103
  required: boolean;
104
104
  helperLabel: string;
105
- hasError: boolean;
105
+ error: boolean;
106
106
  }, {}>;
107
107
  export default _default;
@@ -119,7 +119,7 @@ declare const _default: import("vue").DefineComponent<{
119
119
  handleKeydownEnter(): void;
120
120
  closePanel(): void;
121
121
  handleKeyDown(event: KeyboardEvent): void;
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<{
122
+ }, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("update:modelValue" | "keydown:enter" | "update:input" | "select:blur" | "select:focus" | "selected:option")[], "update:modelValue" | "keydown:enter" | "update:input" | "select:blur" | "select:focus" | "selected:option", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
123
123
  id: {
124
124
  type: StringConstructor;
125
125
  required: true;
@@ -218,10 +218,10 @@ declare const _default: import("vue").DefineComponent<{
218
218
  }>> & {
219
219
  "onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
220
220
  "onKeydown:enter"?: ((...args: any[]) => any) | undefined;
221
+ "onUpdate:input"?: ((...args: any[]) => any) | undefined;
221
222
  "onSelect:blur"?: ((...args: any[]) => any) | undefined;
222
223
  "onSelect:focus"?: ((...args: any[]) => any) | undefined;
223
224
  "onSelected:option"?: ((...args: any[]) => any) | undefined;
224
- "onUpdate:input"?: ((...args: any[]) => any) | undefined;
225
225
  }, {
226
226
  label: string;
227
227
  title: string;
@@ -1,9 +1,3 @@
1
- import type { FusionElementStates } from '../../../../types/Global';
2
-
3
- export interface FusionSelectStates extends FusionElementStates {
4
- opened: boolean;
5
- }
6
-
7
1
  export interface FusionSelectOption {
8
2
  label: string;
9
3
  value: any;
package/dist/fusion.js CHANGED
@@ -557,7 +557,7 @@ const Oi = /* @__PURE__ */ Ne(wi, [["render", Fi], ["__scopeId", "data-v-6a48f2b
557
557
  type: String,
558
558
  default: ""
559
559
  },
560
- hasError: {
560
+ error: {
561
561
  type: Boolean,
562
562
  default: !1
563
563
  },
@@ -576,7 +576,7 @@ const Oi = /* @__PURE__ */ Ne(wi, [["render", Fi], ["__scopeId", "data-v-6a48f2b
576
576
  stateClasses: function() {
577
577
  return {
578
578
  disabled: this.disabled,
579
- error: this.hasError
579
+ error: this.error
580
580
  };
581
581
  },
582
582
  isSelected: function() {
@@ -636,7 +636,7 @@ function Hi(e, t, n, r, a, o) {
636
636
  ], 2)
637
637
  ], 10, Ui);
638
638
  }
639
- const b0 = /* @__PURE__ */ Ne(Ii, [["render", Hi], ["__scopeId", "data-v-690dc389"]]), qi = Ce({
639
+ const b0 = /* @__PURE__ */ Ne(Ii, [["render", Hi], ["__scopeId", "data-v-9dd8874b"]]), qi = Ce({
640
640
  name: "FusionTextLink",
641
641
  props: {
642
642
  id: {
@@ -1074,7 +1074,7 @@ const Qn = /* @__PURE__ */ Ne(fl, [["render", yl]]), bl = Ce({
1074
1074
  type: String,
1075
1075
  default: ""
1076
1076
  },
1077
- modelValue: {
1077
+ input: {
1078
1078
  type: String,
1079
1079
  default: ""
1080
1080
  },
@@ -1111,10 +1111,10 @@ const Qn = /* @__PURE__ */ Ne(fl, [["render", yl]]), bl = Ce({
1111
1111
  default: "fusion-input"
1112
1112
  }
1113
1113
  },
1114
- emits: ["update:modelValue", "input:blur", "input:focus", "keydown:enter"],
1114
+ emits: ["input:blur", "input:focus", "keydown:enter", "update:input"],
1115
1115
  data() {
1116
1116
  return {
1117
- inputValue: this.modelValue,
1117
+ inputValue: this.input || "",
1118
1118
  styleVariables: {},
1119
1119
  interactionStates: {
1120
1120
  focused: !1,
@@ -1132,7 +1132,7 @@ const Qn = /* @__PURE__ */ Ne(fl, [["render", yl]]), bl = Ce({
1132
1132
  }
1133
1133
  },
1134
1134
  watch: {
1135
- modelValue: {
1135
+ input: {
1136
1136
  handler(e) {
1137
1137
  this.inputValue = e;
1138
1138
  },
@@ -1141,7 +1141,7 @@ const Qn = /* @__PURE__ */ Ne(fl, [["render", yl]]), bl = Ce({
1141
1141
  },
1142
1142
  methods: {
1143
1143
  updateInput() {
1144
- this.$emit("update:modelValue", this.inputValue);
1144
+ this.$emit("update:input", this.inputValue);
1145
1145
  },
1146
1146
  handleFocus() {
1147
1147
  this.interactionStates.focused = !0, this.$emit("input:focus");
@@ -1225,7 +1225,7 @@ function Tl(e, t, n, r, a, o) {
1225
1225
  oe(e.$slots, "content", {}, void 0, !0)
1226
1226
  ], 10, Al);
1227
1227
  }
1228
- const Vn = /* @__PURE__ */ Ne(bl, [["render", Tl], ["__scopeId", "data-v-10f7ca3f"]]), Bl = Ce({
1228
+ const Vn = /* @__PURE__ */ Ne(bl, [["render", Tl], ["__scopeId", "data-v-5aa1c13a"]]), Bl = Ce({
1229
1229
  name: "FusionPanel",
1230
1230
  components: { SVGSearch: Er, CheckCircle: Qn, FusionLoadingSpinner: Fn, SVGInbox: il, FusionInput: Vn, OnClickOutside: zi },
1231
1231
  props: {
@@ -1295,6 +1295,9 @@ const Vn = /* @__PURE__ */ Ne(bl, [["render", Tl], ["__scopeId", "data-v-10f7ca3
1295
1295
  handleSelect(e) {
1296
1296
  this.$emit("handle:select", e);
1297
1297
  },
1298
+ handleInput(e) {
1299
+ this.searchInputValue = e;
1300
+ },
1298
1301
  handleKeydownSelect(e, t) {
1299
1302
  if (e.key === "Enter") {
1300
1303
  this.handleSelect(t);
@@ -1311,7 +1314,7 @@ const Vn = /* @__PURE__ */ Ne(bl, [["render", Tl], ["__scopeId", "data-v-10f7ca3
1311
1314
  }
1312
1315
  }
1313
1316
  });
1314
- const Jr = (e) => (qo("data-v-6fc68b79"), e = e(), Ro(), e), xl = ["data-test"], Fl = { class: "fusion-select-panel" }, Ol = { class: "fusion-select-panel-content" }, Il = { class: "list-wrapper" }, Ul = {
1317
+ const Jr = (e) => (qo("data-v-c2f964da"), e = e(), Ro(), e), xl = ["data-test"], Fl = { class: "fusion-select-panel" }, Ol = { class: "fusion-select-panel-content" }, Il = { class: "list-wrapper" }, Ul = {
1315
1318
  key: 0,
1316
1319
  class: "p-xl",
1317
1320
  "data-test": "search-loading-wrapper"
@@ -1358,20 +1361,20 @@ function Gl(e, t, n, r, a, o) {
1358
1361
  key: 0,
1359
1362
  id: `${e.selectId}-search-field`,
1360
1363
  ref: "searchInput",
1361
- modelValue: e.searchInputValue,
1362
- "onUpdate:modelValue": t[0] || (t[0] = (m) => e.searchInputValue = m),
1364
+ input: e.searchInputValue,
1363
1365
  theme: e.theme,
1364
1366
  "data-test": "search-input",
1365
1367
  name: `${e.selectId}-search`,
1366
1368
  placeholder: e.searchPlaceholder,
1367
1369
  autocomplete: "false",
1370
+ "onUpdate:input": e.handleInput,
1368
1371
  onKeydown: e.handleKeydownSelect
1369
1372
  }, {
1370
1373
  icon: ke(() => [
1371
1374
  Se(i, { class: "search-icon" })
1372
1375
  ]),
1373
1376
  _: 1
1374
- }, 8, ["id", "modelValue", "theme", "name", "placeholder", "onKeydown"])),
1377
+ }, 8, ["id", "input", "theme", "name", "placeholder", "onUpdate:input", "onKeydown"])),
1375
1378
  S("div", Il, [
1376
1379
  e.searchLoading ? (v(), k("div", Ul, [
1377
1380
  S("div", Ql, [
@@ -1424,7 +1427,7 @@ function Gl(e, t, n, r, a, o) {
1424
1427
  _: 3
1425
1428
  }, 8, ["options", "onTrigger"]);
1426
1429
  }
1427
- const Nn = /* @__PURE__ */ Ne(Bl, [["render", Gl], ["__scopeId", "data-v-6fc68b79"]]), Zl = {
1430
+ const Nn = /* @__PURE__ */ Ne(Bl, [["render", Gl], ["__scopeId", "data-v-c2f964da"]]), Zl = {
1428
1431
  name: "SVGArrowDown"
1429
1432
  }, _l = {
1430
1433
  xmlns: "http://www.w3.org/2000/svg",
@@ -1716,7 +1719,7 @@ const k0 = /* @__PURE__ */ Ne(ns, [["render", ps], ["__scopeId", "data-v-cbd3b01
1716
1719
  type: String,
1717
1720
  default: ""
1718
1721
  },
1719
- modelValue: {
1722
+ input: {
1720
1723
  type: String,
1721
1724
  default: ""
1722
1725
  },
@@ -1745,27 +1748,18 @@ const k0 = /* @__PURE__ */ Ne(ns, [["render", ps], ["__scopeId", "data-v-cbd3b01
1745
1748
  default: "fusion-password-input"
1746
1749
  }
1747
1750
  },
1748
- emits: ["update:modelValue", "input:blur", "input:focus", "keydown:enter"],
1751
+ emits: ["input:blur", "input:focus", "keydown:enter", "update:input"],
1749
1752
  data() {
1750
1753
  return {
1751
- inputValue: this.modelValue,
1754
+ inputValue: this.input || "",
1752
1755
  interactionStates: {
1753
1756
  focused: !1
1754
1757
  },
1755
1758
  showPassword: !1
1756
1759
  };
1757
1760
  },
1758
- computed: {
1759
- inputStates() {
1760
- return {
1761
- focused: this.interactionStates.focused,
1762
- disabled: this.disabled,
1763
- error: !!this.errorLabel
1764
- };
1765
- }
1766
- },
1767
1761
  watch: {
1768
- modelValue: {
1762
+ input: {
1769
1763
  handler(e) {
1770
1764
  this.inputValue = e;
1771
1765
  },
@@ -1773,8 +1767,8 @@ const k0 = /* @__PURE__ */ Ne(ns, [["render", ps], ["__scopeId", "data-v-cbd3b01
1773
1767
  }
1774
1768
  },
1775
1769
  methods: {
1776
- updateInput() {
1777
- this.$emit("update:modelValue", this.inputValue);
1770
+ updateInput(e) {
1771
+ this.inputValue = e, this.$emit("update:input", e);
1778
1772
  },
1779
1773
  handleFocus() {
1780
1774
  this.interactionStates.focused = !0, this.$emit("input:focus");
@@ -1796,8 +1790,7 @@ function gs(e, t, n, r, a, o) {
1796
1790
  }, [
1797
1791
  Se(l, {
1798
1792
  id: e.id,
1799
- modelValue: e.inputValue,
1800
- "onUpdate:modelValue": t[1] || (t[1] = (u) => e.inputValue = u),
1793
+ input: e.inputValue,
1801
1794
  type: e.showPassword ? "text" : "password",
1802
1795
  placeholder: e.placeholder,
1803
1796
  autocomplete: e.autocomplete,
@@ -1809,7 +1802,7 @@ function gs(e, t, n, r, a, o) {
1809
1802
  "helper-label": e.helperLabel,
1810
1803
  name: e.name,
1811
1804
  "error-label": e.errorLabel,
1812
- onInput: e.updateInput,
1805
+ "onUpdate:input": e.updateInput,
1813
1806
  onBlur: e.handleBlur,
1814
1807
  onFocus: e.handleFocus,
1815
1808
  onKeydown: ye(e.handleKeydownEnter, ["enter"])
@@ -1832,10 +1825,10 @@ function gs(e, t, n, r, a, o) {
1832
1825
  ]),
1833
1826
  key: "0"
1834
1827
  } : void 0
1835
- ]), 1032, ["id", "modelValue", "type", "placeholder", "autocomplete", "required", "class", "disabled", "label", "helper-label", "name", "error-label", "onInput", "onBlur", "onFocus", "onKeydown"])
1828
+ ]), 1032, ["id", "input", "type", "placeholder", "autocomplete", "required", "class", "disabled", "label", "helper-label", "name", "error-label", "onUpdate:input", "onBlur", "onFocus", "onKeydown"])
1836
1829
  ], 8, vs);
1837
1830
  }
1838
- const w0 = /* @__PURE__ */ Ne(fs, [["render", gs], ["__scopeId", "data-v-df7f6a9f"]]), Aa = {
1831
+ const w0 = /* @__PURE__ */ Ne(fs, [["render", gs], ["__scopeId", "data-v-0facf0fc"]]), Aa = {
1839
1832
  default: {
1840
1833
  code: "GB",
1841
1834
  dialCode: 44,
@@ -11827,7 +11820,7 @@ function Yv(e, t, n, r, a, o) {
11827
11820
  "aria-disabled": e.disabled,
11828
11821
  "error-label": e.errorLabel,
11829
11822
  disabled: e.disabled,
11830
- "model-value": e.selected.label,
11823
+ input: e.selected.label,
11831
11824
  placeholder: e.searchPlaceholder,
11832
11825
  autocomplete: e.autocomplete,
11833
11826
  onClick: e.handleInputClick,
@@ -11837,13 +11830,13 @@ function Yv(e, t, n, r, a, o) {
11837
11830
  ye(e.handleKeydownEnter, ["enter"]),
11838
11831
  e.handleKeyDown
11839
11832
  ],
11840
- "onUpdate:modelValue": e.updateInput
11833
+ "onUpdate:input": e.updateInput
11841
11834
  }, {
11842
11835
  icon: ke(() => [
11843
11836
  Se(i)
11844
11837
  ]),
11845
11838
  _: 1
11846
- }, 8, ["id", "tabindex", "autofocus", "aria-labelledby", "aria-invalid", "aria-disabled", "class", "error-label", "disabled", "model-value", "placeholder", "autocomplete", "onClick", "onInput:blur", "onInput:focus", "onKeydown", "onUpdate:modelValue"]),
11839
+ }, 8, ["id", "tabindex", "autofocus", "aria-labelledby", "aria-invalid", "aria-disabled", "class", "error-label", "disabled", "input", "placeholder", "autocomplete", "onClick", "onInput:blur", "onInput:focus", "onKeydown", "onUpdate:input"]),
11847
11840
  e.interactionStates.opened ? (v(), be(u, {
11848
11841
  key: 0,
11849
11842
  "select-id": "fusion-searchable-input-select-" + e.id,
@@ -11862,7 +11855,7 @@ function Yv(e, t, n, r, a, o) {
11862
11855
  ])
11863
11856
  ], 8, Rv);
11864
11857
  }
11865
- const P0 = /* @__PURE__ */ Ne(qv, [["render", Yv], ["__scopeId", "data-v-9a8c389e"]]), Wv = Ce({
11858
+ const P0 = /* @__PURE__ */ Ne(qv, [["render", Yv], ["__scopeId", "data-v-4656f6fe"]]), Wv = Ce({
11866
11859
  name: "SVGDecrement"
11867
11860
  }), zv = {
11868
11861
  width: "24",