@maggioli-design-system/mds-input 7.8.1 → 7.8.3

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.
Files changed (34) hide show
  1. package/dist/cjs/loader.cjs.js +1 -1
  2. package/dist/cjs/mds-input.cjs.entry.js +20 -13
  3. package/dist/cjs/mds-input.cjs.js +1 -1
  4. package/dist/collection/components/mds-input/mds-input.js +21 -15
  5. package/dist/collection/components/mds-input/test/mds-input.stories.js +158 -109
  6. package/dist/components/mds-input.js +20 -14
  7. package/dist/documentation.json +9 -1
  8. package/dist/esm/loader.js +1 -1
  9. package/dist/esm/mds-input.entry.js +20 -13
  10. package/dist/esm/mds-input.js +1 -1
  11. package/dist/esm-es5/loader.js +1 -1
  12. package/dist/esm-es5/mds-input.entry.js +1 -1
  13. package/dist/esm-es5/mds-input.js +1 -1
  14. package/dist/mds-input/mds-input.esm.js +1 -1
  15. package/dist/mds-input/p-3d99713e.system.js +1 -1
  16. package/dist/mds-input/p-701ba8d9.entry.js +6 -0
  17. package/dist/mds-input/{p-ebcd71d8.system.entry.js → p-8e057974.system.entry.js} +1 -1
  18. package/dist/stats.json +17 -21
  19. package/dist/types/components/mds-input/mds-input.d.ts +0 -1
  20. package/dist/types/components/mds-input/test/mds-input.stories.d.ts +176 -24
  21. package/dist/types/dictionary/icon.d.ts +1 -1
  22. package/documentation.json +10 -2
  23. package/package.json +4 -4
  24. package/src/components/mds-input/mds-input.tsx +16 -6
  25. package/src/components/mds-input/readme.md +2 -0
  26. package/src/components/mds-input/test/{mds-input.stories.mdx → mds-input.mdx} +1 -1
  27. package/src/components/mds-input/test/mds-input.stories.tsx +243 -136
  28. package/www/build/mds-input.esm.js +1 -1
  29. package/www/build/p-3d99713e.system.js +1 -1
  30. package/www/build/p-701ba8d9.entry.js +6 -0
  31. package/www/build/{p-ebcd71d8.system.entry.js → p-8e057974.system.entry.js} +1 -1
  32. package/dist/mds-input/p-fc94c245.entry.js +0 -6
  33. package/src/fixtures/icons.json +0 -176
  34. package/www/build/p-fc94c245.entry.js +0 -6
@@ -8,7 +8,7 @@ const appGlobals = require('./app-globals-3a1e7e63.js');
8
8
  const defineCustomElements = async (win, options) => {
9
9
  if (typeof window === 'undefined') return undefined;
10
10
  await appGlobals.globalScripts();
11
- return index.bootstrapLazy([["mds-input.cjs",[[65,"mds-input",{"autocomplete":[513],"autofocus":[516],"await":[516],"controlsLayout":[513,"controls-layout"],"controlsIcon":[513,"controls-icon"],"controlIncreaseLabel":[513,"control-increase-label"],"controlDecreaseLabel":[513,"control-decrease-label"],"datalist":[16],"disabled":[516],"icon":[1537],"max":[520],"maxlength":[1538],"mic":[516],"min":[520],"minlength":[514],"name":[513],"pattern":[513],"placeholder":[513],"readonly":[516],"required":[516],"variant":[1537],"tip":[513],"step":[513],"type":[513],"typography":[513],"value":[1537],"hasFocus":[32],"language":[32],"isRecording":[32],"currentLengthLabel":[32],"countVariant":[32],"isPasswordVisible":[32],"transcript":[32],"updateLang":[64],"addValidator":[64],"removeValidator":[64],"hasValidator":[64],"getErrors":[64],"setFocus":[64],"getInputElement":[64]},null,{"value":["valueChanged"],"variant":["variantChanged"],"maxlength":["maxLengthChanged"],"disabled":["disabledChanged"]}]]]], options);
11
+ return index.bootstrapLazy([["mds-input.cjs",[[65,"mds-input",{"autocomplete":[513],"autofocus":[516],"await":[516],"controlsLayout":[513,"controls-layout"],"controlsIcon":[513,"controls-icon"],"controlIncreaseLabel":[513,"control-increase-label"],"controlDecreaseLabel":[513,"control-decrease-label"],"datalist":[16],"disabled":[516],"icon":[1537],"max":[520],"maxlength":[1538],"mic":[516],"min":[520],"minlength":[514],"name":[513],"pattern":[513],"placeholder":[513],"readonly":[516],"required":[516],"variant":[1537],"tip":[513],"step":[513],"type":[513],"typography":[513],"value":[1537],"hasFocus":[32],"language":[32],"isRecording":[32],"currentLengthLabel":[32],"countVariant":[32],"isPasswordVisible":[32],"updateLang":[64],"addValidator":[64],"removeValidator":[64],"hasValidator":[64],"getErrors":[64],"setFocus":[64],"getInputElement":[64]},null,{"value":["valueChanged"],"variant":["variantChanged"],"maxlength":["maxLengthChanged"],"disabled":["disabledChanged"]}]]]], options);
12
12
  };
13
13
 
14
14
  exports.setNonce = index.setNonce;
@@ -1154,7 +1154,6 @@ const MdsInput = class {
1154
1154
  this.isRecording = false;
1155
1155
  this.countVariant = 'count-empty';
1156
1156
  this.isPasswordVisible = false;
1157
- this.transcript = '';
1158
1157
  // private valuePristine?: string
1159
1158
  this.t = new Locale({
1160
1159
  el: localeEl,
@@ -1323,11 +1322,19 @@ const MdsInput = class {
1323
1322
  this.recognition.lang = navigator.language || 'it-IT';
1324
1323
  this.recognition.interimResults = true;
1325
1324
  this.recognition.maxAlternatives = 1;
1325
+ let transcript = '';
1326
+ let progress = 0; // need to save position progress on speech results
1326
1327
  // eslint-disable-next-line @typescript-eslint/no-explicit-any
1327
1328
  this.recognition.onresult = (event) => {
1328
- const speechResult = event.results[0][0].transcript;
1329
- this.transcript = speechResult;
1330
- this.value = this.transcript;
1329
+ const speechResult = event.results;
1330
+ const interimResult = speechResult[progress];
1331
+ if (interimResult.isFinal) {
1332
+ transcript += interimResult[0].transcript;
1333
+ this.value = transcript;
1334
+ progress += 1;
1335
+ return;
1336
+ }
1337
+ this.value = transcript + interimResult[0].transcript;
1331
1338
  };
1332
1339
  // eslint-disable-next-line @typescript-eslint/no-explicit-any
1333
1340
  this.recognition.onerror = (event) => {
@@ -1488,21 +1495,21 @@ const MdsInput = class {
1488
1495
  }
1489
1496
  render() {
1490
1497
  var _a, _b;
1491
- return (index.h(index.Host, { key: '648689ad5aa037e75aa79e6108546b27d262aedc' }, this.type === 'number'
1498
+ return (index.h(index.Host, { key: '6c3728c33cf55c79ffa444d89154255695baf62b' }, this.type === 'number'
1492
1499
  && this.controlsLayout === 'horizontal'
1493
- && index.h("mds-button", { key: '92db9293088b824482526ad1477e6bae28ca70d9', class: "counter-button counter-button--horizontal counter-button--decrease", icon: this.controlsIcon === 'arrow' ? miBaselineArrowDown : miBaselineRemove, onClick: this.stepDown, tabindex: "0", title: this.t.get('decrease'), part: "counter-button-decrease" }), this.type === 'textarea'
1500
+ && index.h("mds-button", { key: '0e2e5e0644bd6b3aad3b8b12df734abfc309927e', class: "counter-button counter-button--horizontal counter-button--decrease", icon: this.controlsIcon === 'arrow' ? miBaselineArrowDown : miBaselineRemove, onClick: this.stepDown, tabindex: "0", title: this.t.get('decrease'), part: "counter-button-decrease" }), this.type === 'textarea'
1494
1501
  ? index.h("textarea", { class: clsx('input', ((_a = this.icon) !== null && _a !== void 0 ? _a : this.await) && 'has-icon', this.mic && 'has-right-icon'), autoFocus: this.autofocus, disabled: this.disabled, maxLength: this.maxlength, minLength: this.minlength, name: this.name, onBlur: this.onBlur, onFocus: this.onFocus, onInput: this.onInput, part: "field", placeholder: this.placeholder, readOnly: this.readonly, ref: input => (this.nativeInput = input), required: this.required, tabIndex: this.tabindex, value: this.value })
1495
1502
  : index.h("input", { class: clsx('input', ((_b = this.icon) !== null && _b !== void 0 ? _b : this.await) && 'has-icon', this.mic && 'has-right-icon'), autoComplete: this.autocomplete, autoFocus: this.autofocus, disabled: this.disabled, max: this.max, maxLength: this.maxlength, min: this.min, minLength: this.minlength, name: this.name, onBlur: this.onBlur, onFocus: this.onFocus, onInput: this.onInput, pattern: this.pattern, list: this.datalistId, part: "field", placeholder: this.placeholder, readOnly: this.readonly, ref: input => (this.nativeInput = input), required: this.required, step: this.step, tabIndex: this.tabindex, type: this.type === 'password' && this.isPasswordVisible ? 'text' : this.type, value: this.value }), this.type === 'number'
1496
1503
  && this.controlsLayout === 'vertical'
1497
- && index.h("div", { key: '7a26c610edafb5bd6dc95c7d07cf1f5621eb0f27', class: "counter counter--vertical" }, index.h("mds-button", { key: 'c5a69b3fdfdd645592d4b899822f61280769c48a', class: "counter-button", icon: this.controlsIcon === 'arrow' ? miBaselineArrowUp : miBaselineAdd, onClick: this.stepUp, tabindex: "0", title: this.t.get('increase'), part: "counter-button-increase" }), index.h("mds-button", { key: 'a5e510b3a98155ad78dc7bec5f40a0447135d32b', class: "counter-button", icon: this.controlsIcon === 'arrow' ? miBaselineArrowDown : miBaselineRemove, onClick: this.stepDown, tabindex: "0", title: this.t.get('decrease'), part: "counter-button-decrease" })), this.type === 'number'
1504
+ && index.h("div", { key: '48fd016a7a0917ba5c669789ed373221e8e920d7', class: "counter counter--vertical" }, index.h("mds-button", { key: '8507fb252cbb8a92bc1b9cce05df97e01e900593', class: "counter-button", icon: this.controlsIcon === 'arrow' ? miBaselineArrowUp : miBaselineAdd, onClick: this.stepUp, tabindex: "0", title: this.t.get('increase'), part: "counter-button-increase" }), index.h("mds-button", { key: 'c22c5b5370f3121645f053b3c3d91e7fc5933a08', class: "counter-button", icon: this.controlsIcon === 'arrow' ? miBaselineArrowDown : miBaselineRemove, onClick: this.stepDown, tabindex: "0", title: this.t.get('decrease'), part: "counter-button-decrease" })), this.type === 'number'
1498
1505
  && this.controlsLayout === 'horizontal'
1499
- && index.h("mds-button", { key: '178d90aafc52d838e8a2e7065931ca48fae2ce81', class: "counter-button counter-button--horizontal counter-button--increase", icon: this.controlsIcon === 'arrow' ? miBaselineArrowUp : miBaselineAdd, onClick: this.stepUp, tabindex: "0", title: this.t.get('increase'), part: "counter-button-increase" }), this.type === 'password'
1500
- && index.h("mds-button", { key: '6ba4f1ce6db2a03f4beec5105e63689517c836df', class: "password-toggle-button", icon: this.isPasswordVisible ? miBaselineVisibleOff : miBaselineVisible, onClick: () => this.isPasswordVisible = !this.isPasswordVisible, tabindex: "0", tone: "quiet", title: this.isPasswordVisible ? this.t.get('hidePassword') : this.t.get('showPassword'), part: "password-toggle-button" }), this.mic
1501
- && index.h("mds-button", { key: '6d31ca6b568f2308b92fc267c7b048709a0fc43d', class: clsx('mic-toggle-button', this.isRecording && 'mic-toggle-button--recording'), icon: this.speechToTextIcon, onClick: () => this.toggleTextRecognition(), tabindex: "0", variant: "dark", tone: "quiet", title: this.speechToTextLabel, part: "mic-toggle-button" }), index.h("mds-input-tip", { key: '91c4d5034f8f7cce57f312aafb4a5ea87e70d0d2', lang: this.language, position: "top", active: this.hasFocus }, this.disabled && index.h("mds-input-tip-item", { key: 'a63198033ff3ece7c9962ae51c5b1c21c7021579', expanded: true, variant: "disabled" }), this.readonly && index.h("mds-input-tip-item", { key: '856cb3387ab27a9b82442bf36db2d670a685bd69', expanded: true, variant: "readonly" }), this.required &&
1502
- index.h("mds-input-tip-item", { key: '26ff9e6801f2d558a36736ef1c62543cbc1e2795', expanded: this.hasFocus, variant: this.isValid ? 'required-success' : 'required' })), index.h("mds-input-tip", { key: '55b2bea8c5860db8dd8b3c3a0f2277b050bf610a', lang: this.language, position: "bottom", active: this.hasFocus }, this.tip && index.h("mds-input-tip-item", { key: 'a0d407594e91bff200062cf1915bf93843015f36', expanded: true, variant: "text" }, this.tip), this.maxlength && index.h("mds-input-tip-item", { key: '59b89c4e91582562ebb608a428d0601b0b3abc24', part: "tip-count", expanded: true, variant: this.countVariant }, this.currentLengthLabel)), this.datalist &&
1503
- index.h("datalist", { key: '47869a8f66759aad40645ac4fe2b9c8e9ddc2325', id: this.datalistId, class: "datalist" }, this.datalist.map((element, i) => {
1506
+ && index.h("mds-button", { key: '10215d151779798d8b77d44e7bac708f1c737939', class: "counter-button counter-button--horizontal counter-button--increase", icon: this.controlsIcon === 'arrow' ? miBaselineArrowUp : miBaselineAdd, onClick: this.stepUp, tabindex: "0", title: this.t.get('increase'), part: "counter-button-increase" }), this.type === 'password'
1507
+ && index.h("mds-button", { key: 'f97e9aeb646697bd63ec7cf152bbe56ff41f7902', class: "password-toggle-button", icon: this.isPasswordVisible ? miBaselineVisibleOff : miBaselineVisible, onClick: () => this.isPasswordVisible = !this.isPasswordVisible, tabindex: "0", tone: "quiet", title: this.isPasswordVisible ? this.t.get('hidePassword') : this.t.get('showPassword'), part: "password-toggle-button" }), this.mic
1508
+ && index.h("mds-button", { key: 'e293ab7cc45fa62973830e6a8d50a4752f9b9a3c', class: clsx('mic-toggle-button', this.isRecording && 'mic-toggle-button--recording'), icon: this.speechToTextIcon, onClick: () => this.toggleTextRecognition(), tabindex: "0", variant: "dark", tone: "quiet", title: this.speechToTextLabel, part: "mic-toggle-button" }), index.h("mds-input-tip", { key: '5f0fbae757653b1d3bcbb2a24bc8f897d37f24fc', lang: this.language, position: "top", active: this.hasFocus, part: 'tip-top' }, this.disabled && index.h("mds-input-tip-item", { key: '4f0b400762f31ee29d767afccca5daf3d37734f9', expanded: true, variant: "disabled" }), this.readonly && index.h("mds-input-tip-item", { key: '4ebf8150c21ccf4ebb3bff559735305d5df69fd1', expanded: true, variant: "readonly" }), this.required &&
1509
+ index.h("mds-input-tip-item", { key: '96af6b54e03f634a604193579772c076b5857eb4', expanded: this.hasFocus, variant: this.isValid ? 'required-success' : 'required' })), index.h("mds-input-tip", { key: '4b57532ce1640feba598504f9d53a024bdd56f43', lang: this.language, position: "bottom", active: this.hasFocus, part: 'tip-bottom' }, this.tip && index.h("mds-input-tip-item", { key: 'c54fc1e7903946ab4d6b8a77beb54df3fc108ba0', expanded: true, variant: "text" }, this.tip), this.maxlength && index.h("mds-input-tip-item", { key: '60f23a6717e8effc1b01064349fa78df198b89e4', part: "tip-count", expanded: true, variant: this.countVariant }, this.currentLengthLabel)), this.datalist &&
1510
+ index.h("datalist", { key: '7ff09a4e142d4e070b55c2bd6101eacae8f91889', id: this.datalistId, class: "datalist" }, this.datalist.map((element, i) => {
1504
1511
  return index.h("option", { key: i, value: element });
1505
- })), this.icon && !this.await && index.h("mds-icon", { key: 'a1bd0fa20067f42462a126d0a25d1aff8e72cd4f', class: clsx('icon', this.variant), name: this.icon }), index.h("mds-spinner", { key: 'ee45b5b26e83dbf43c3bf82eb97625774c001f77', running: this.await, class: clsx('await', this.variant) })));
1512
+ })), this.icon && !this.await && index.h("mds-icon", { key: '12f4bb73d9edec126cf5b86c2d83e646c1504e78', class: clsx('icon', this.variant), name: this.icon }), index.h("mds-spinner", { key: 'a8453e655fb3d09ccd1ed4c3a9a388414dd6e4fe', running: this.await, class: clsx('await', this.variant) })));
1506
1513
  }
1507
1514
  static get formAssociated() { return true; }
1508
1515
  get el() { return index.getElement(this); }
@@ -19,7 +19,7 @@ var patchBrowser = () => {
19
19
 
20
20
  patchBrowser().then(async (options) => {
21
21
  await appGlobals.globalScripts();
22
- return index.bootstrapLazy([["mds-input.cjs",[[65,"mds-input",{"autocomplete":[513],"autofocus":[516],"await":[516],"controlsLayout":[513,"controls-layout"],"controlsIcon":[513,"controls-icon"],"controlIncreaseLabel":[513,"control-increase-label"],"controlDecreaseLabel":[513,"control-decrease-label"],"datalist":[16],"disabled":[516],"icon":[1537],"max":[520],"maxlength":[1538],"mic":[516],"min":[520],"minlength":[514],"name":[513],"pattern":[513],"placeholder":[513],"readonly":[516],"required":[516],"variant":[1537],"tip":[513],"step":[513],"type":[513],"typography":[513],"value":[1537],"hasFocus":[32],"language":[32],"isRecording":[32],"currentLengthLabel":[32],"countVariant":[32],"isPasswordVisible":[32],"transcript":[32],"updateLang":[64],"addValidator":[64],"removeValidator":[64],"hasValidator":[64],"getErrors":[64],"setFocus":[64],"getInputElement":[64]},null,{"value":["valueChanged"],"variant":["variantChanged"],"maxlength":["maxLengthChanged"],"disabled":["disabledChanged"]}]]]], options);
22
+ return index.bootstrapLazy([["mds-input.cjs",[[65,"mds-input",{"autocomplete":[513],"autofocus":[516],"await":[516],"controlsLayout":[513,"controls-layout"],"controlsIcon":[513,"controls-icon"],"controlIncreaseLabel":[513,"control-increase-label"],"controlDecreaseLabel":[513,"control-decrease-label"],"datalist":[16],"disabled":[516],"icon":[1537],"max":[520],"maxlength":[1538],"mic":[516],"min":[520],"minlength":[514],"name":[513],"pattern":[513],"placeholder":[513],"readonly":[516],"required":[516],"variant":[1537],"tip":[513],"step":[513],"type":[513],"typography":[513],"value":[1537],"hasFocus":[32],"language":[32],"isRecording":[32],"currentLengthLabel":[32],"countVariant":[32],"isPasswordVisible":[32],"updateLang":[64],"addValidator":[64],"removeValidator":[64],"hasValidator":[64],"getErrors":[64],"setFocus":[64],"getInputElement":[64]},null,{"value":["valueChanged"],"variant":["variantChanged"],"maxlength":["maxLengthChanged"],"disabled":["disabledChanged"]}]]]], options);
23
23
  });
24
24
 
25
25
  exports.setNonce = index.setNonce;
@@ -25,7 +25,6 @@ export class MdsInput {
25
25
  this.isRecording = false;
26
26
  this.countVariant = 'count-empty';
27
27
  this.isPasswordVisible = false;
28
- this.transcript = '';
29
28
  // private valuePristine?: string
30
29
  this.t = new Locale({
31
30
  el: localeEl,
@@ -194,11 +193,19 @@ export class MdsInput {
194
193
  this.recognition.lang = navigator.language || 'it-IT';
195
194
  this.recognition.interimResults = true;
196
195
  this.recognition.maxAlternatives = 1;
196
+ let transcript = '';
197
+ let progress = 0; // need to save position progress on speech results
197
198
  // eslint-disable-next-line @typescript-eslint/no-explicit-any
198
199
  this.recognition.onresult = (event) => {
199
- const speechResult = event.results[0][0].transcript;
200
- this.transcript = speechResult;
201
- this.value = this.transcript;
200
+ const speechResult = event.results;
201
+ const interimResult = speechResult[progress];
202
+ if (interimResult.isFinal) {
203
+ transcript += interimResult[0].transcript;
204
+ this.value = transcript;
205
+ progress += 1;
206
+ return;
207
+ }
208
+ this.value = transcript + interimResult[0].transcript;
202
209
  };
203
210
  // eslint-disable-next-line @typescript-eslint/no-explicit-any
204
211
  this.recognition.onerror = (event) => {
@@ -359,21 +366,21 @@ export class MdsInput {
359
366
  }
360
367
  render() {
361
368
  var _a, _b;
362
- return (h(Host, { key: '648689ad5aa037e75aa79e6108546b27d262aedc' }, this.type === 'number'
369
+ return (h(Host, { key: '6c3728c33cf55c79ffa444d89154255695baf62b' }, this.type === 'number'
363
370
  && this.controlsLayout === 'horizontal'
364
- && h("mds-button", { key: '92db9293088b824482526ad1477e6bae28ca70d9', class: "counter-button counter-button--horizontal counter-button--decrease", icon: this.controlsIcon === 'arrow' ? miBaselineArrowDown : miBaselineRemove, onClick: this.stepDown, tabindex: "0", title: this.t.get('decrease'), part: "counter-button-decrease" }), this.type === 'textarea'
371
+ && h("mds-button", { key: '0e2e5e0644bd6b3aad3b8b12df734abfc309927e', class: "counter-button counter-button--horizontal counter-button--decrease", icon: this.controlsIcon === 'arrow' ? miBaselineArrowDown : miBaselineRemove, onClick: this.stepDown, tabindex: "0", title: this.t.get('decrease'), part: "counter-button-decrease" }), this.type === 'textarea'
365
372
  ? h("textarea", { class: clsx('input', ((_a = this.icon) !== null && _a !== void 0 ? _a : this.await) && 'has-icon', this.mic && 'has-right-icon'), autoFocus: this.autofocus, disabled: this.disabled, maxLength: this.maxlength, minLength: this.minlength, name: this.name, onBlur: this.onBlur, onFocus: this.onFocus, onInput: this.onInput, part: "field", placeholder: this.placeholder, readOnly: this.readonly, ref: input => (this.nativeInput = input), required: this.required, tabIndex: this.tabindex, value: this.value })
366
373
  : h("input", { class: clsx('input', ((_b = this.icon) !== null && _b !== void 0 ? _b : this.await) && 'has-icon', this.mic && 'has-right-icon'), autoComplete: this.autocomplete, autoFocus: this.autofocus, disabled: this.disabled, max: this.max, maxLength: this.maxlength, min: this.min, minLength: this.minlength, name: this.name, onBlur: this.onBlur, onFocus: this.onFocus, onInput: this.onInput, pattern: this.pattern, list: this.datalistId, part: "field", placeholder: this.placeholder, readOnly: this.readonly, ref: input => (this.nativeInput = input), required: this.required, step: this.step, tabIndex: this.tabindex, type: this.type === 'password' && this.isPasswordVisible ? 'text' : this.type, value: this.value }), this.type === 'number'
367
374
  && this.controlsLayout === 'vertical'
368
- && h("div", { key: '7a26c610edafb5bd6dc95c7d07cf1f5621eb0f27', class: "counter counter--vertical" }, h("mds-button", { key: 'c5a69b3fdfdd645592d4b899822f61280769c48a', class: "counter-button", icon: this.controlsIcon === 'arrow' ? miBaselineArrowUp : miBaselineAdd, onClick: this.stepUp, tabindex: "0", title: this.t.get('increase'), part: "counter-button-increase" }), h("mds-button", { key: 'a5e510b3a98155ad78dc7bec5f40a0447135d32b', class: "counter-button", icon: this.controlsIcon === 'arrow' ? miBaselineArrowDown : miBaselineRemove, onClick: this.stepDown, tabindex: "0", title: this.t.get('decrease'), part: "counter-button-decrease" })), this.type === 'number'
375
+ && h("div", { key: '48fd016a7a0917ba5c669789ed373221e8e920d7', class: "counter counter--vertical" }, h("mds-button", { key: '8507fb252cbb8a92bc1b9cce05df97e01e900593', class: "counter-button", icon: this.controlsIcon === 'arrow' ? miBaselineArrowUp : miBaselineAdd, onClick: this.stepUp, tabindex: "0", title: this.t.get('increase'), part: "counter-button-increase" }), h("mds-button", { key: 'c22c5b5370f3121645f053b3c3d91e7fc5933a08', class: "counter-button", icon: this.controlsIcon === 'arrow' ? miBaselineArrowDown : miBaselineRemove, onClick: this.stepDown, tabindex: "0", title: this.t.get('decrease'), part: "counter-button-decrease" })), this.type === 'number'
369
376
  && this.controlsLayout === 'horizontal'
370
- && h("mds-button", { key: '178d90aafc52d838e8a2e7065931ca48fae2ce81', class: "counter-button counter-button--horizontal counter-button--increase", icon: this.controlsIcon === 'arrow' ? miBaselineArrowUp : miBaselineAdd, onClick: this.stepUp, tabindex: "0", title: this.t.get('increase'), part: "counter-button-increase" }), this.type === 'password'
371
- && h("mds-button", { key: '6ba4f1ce6db2a03f4beec5105e63689517c836df', class: "password-toggle-button", icon: this.isPasswordVisible ? miBaselineVisibleOff : miBaselineVisible, onClick: () => this.isPasswordVisible = !this.isPasswordVisible, tabindex: "0", tone: "quiet", title: this.isPasswordVisible ? this.t.get('hidePassword') : this.t.get('showPassword'), part: "password-toggle-button" }), this.mic
372
- && h("mds-button", { key: '6d31ca6b568f2308b92fc267c7b048709a0fc43d', class: clsx('mic-toggle-button', this.isRecording && 'mic-toggle-button--recording'), icon: this.speechToTextIcon, onClick: () => this.toggleTextRecognition(), tabindex: "0", variant: "dark", tone: "quiet", title: this.speechToTextLabel, part: "mic-toggle-button" }), h("mds-input-tip", { key: '91c4d5034f8f7cce57f312aafb4a5ea87e70d0d2', lang: this.language, position: "top", active: this.hasFocus }, this.disabled && h("mds-input-tip-item", { key: 'a63198033ff3ece7c9962ae51c5b1c21c7021579', expanded: true, variant: "disabled" }), this.readonly && h("mds-input-tip-item", { key: '856cb3387ab27a9b82442bf36db2d670a685bd69', expanded: true, variant: "readonly" }), this.required &&
373
- h("mds-input-tip-item", { key: '26ff9e6801f2d558a36736ef1c62543cbc1e2795', expanded: this.hasFocus, variant: this.isValid ? 'required-success' : 'required' })), h("mds-input-tip", { key: '55b2bea8c5860db8dd8b3c3a0f2277b050bf610a', lang: this.language, position: "bottom", active: this.hasFocus }, this.tip && h("mds-input-tip-item", { key: 'a0d407594e91bff200062cf1915bf93843015f36', expanded: true, variant: "text" }, this.tip), this.maxlength && h("mds-input-tip-item", { key: '59b89c4e91582562ebb608a428d0601b0b3abc24', part: "tip-count", expanded: true, variant: this.countVariant }, this.currentLengthLabel)), this.datalist &&
374
- h("datalist", { key: '47869a8f66759aad40645ac4fe2b9c8e9ddc2325', id: this.datalistId, class: "datalist" }, this.datalist.map((element, i) => {
377
+ && h("mds-button", { key: '10215d151779798d8b77d44e7bac708f1c737939', class: "counter-button counter-button--horizontal counter-button--increase", icon: this.controlsIcon === 'arrow' ? miBaselineArrowUp : miBaselineAdd, onClick: this.stepUp, tabindex: "0", title: this.t.get('increase'), part: "counter-button-increase" }), this.type === 'password'
378
+ && h("mds-button", { key: 'f97e9aeb646697bd63ec7cf152bbe56ff41f7902', class: "password-toggle-button", icon: this.isPasswordVisible ? miBaselineVisibleOff : miBaselineVisible, onClick: () => this.isPasswordVisible = !this.isPasswordVisible, tabindex: "0", tone: "quiet", title: this.isPasswordVisible ? this.t.get('hidePassword') : this.t.get('showPassword'), part: "password-toggle-button" }), this.mic
379
+ && h("mds-button", { key: 'e293ab7cc45fa62973830e6a8d50a4752f9b9a3c', class: clsx('mic-toggle-button', this.isRecording && 'mic-toggle-button--recording'), icon: this.speechToTextIcon, onClick: () => this.toggleTextRecognition(), tabindex: "0", variant: "dark", tone: "quiet", title: this.speechToTextLabel, part: "mic-toggle-button" }), h("mds-input-tip", { key: '5f0fbae757653b1d3bcbb2a24bc8f897d37f24fc', lang: this.language, position: "top", active: this.hasFocus, part: 'tip-top' }, this.disabled && h("mds-input-tip-item", { key: '4f0b400762f31ee29d767afccca5daf3d37734f9', expanded: true, variant: "disabled" }), this.readonly && h("mds-input-tip-item", { key: '4ebf8150c21ccf4ebb3bff559735305d5df69fd1', expanded: true, variant: "readonly" }), this.required &&
380
+ h("mds-input-tip-item", { key: '96af6b54e03f634a604193579772c076b5857eb4', expanded: this.hasFocus, variant: this.isValid ? 'required-success' : 'required' })), h("mds-input-tip", { key: '4b57532ce1640feba598504f9d53a024bdd56f43', lang: this.language, position: "bottom", active: this.hasFocus, part: 'tip-bottom' }, this.tip && h("mds-input-tip-item", { key: 'c54fc1e7903946ab4d6b8a77beb54df3fc108ba0', expanded: true, variant: "text" }, this.tip), this.maxlength && h("mds-input-tip-item", { key: '60f23a6717e8effc1b01064349fa78df198b89e4', part: "tip-count", expanded: true, variant: this.countVariant }, this.currentLengthLabel)), this.datalist &&
381
+ h("datalist", { key: '7ff09a4e142d4e070b55c2bd6101eacae8f91889', id: this.datalistId, class: "datalist" }, this.datalist.map((element, i) => {
375
382
  return h("option", { key: i, value: element });
376
- })), this.icon && !this.await && h("mds-icon", { key: 'a1bd0fa20067f42462a126d0a25d1aff8e72cd4f', class: clsx('icon', this.variant), name: this.icon }), h("mds-spinner", { key: 'ee45b5b26e83dbf43c3bf82eb97625774c001f77', running: this.await, class: clsx('await', this.variant) })));
383
+ })), this.icon && !this.await && h("mds-icon", { key: '12f4bb73d9edec126cf5b86c2d83e646c1504e78', class: clsx('icon', this.variant), name: this.icon }), h("mds-spinner", { key: 'a8453e655fb3d09ccd1ed4c3a9a388414dd6e4fe', running: this.await, class: clsx('await', this.variant) })));
377
384
  }
378
385
  static get is() { return "mds-input"; }
379
386
  static get encapsulation() { return "shadow"; }
@@ -941,8 +948,7 @@ export class MdsInput {
941
948
  "isRecording": {},
942
949
  "currentLengthLabel": {},
943
950
  "countVariant": {},
944
- "isPasswordVisible": {},
945
- "transcript": {}
951
+ "isPasswordVisible": {}
946
952
  };
947
953
  }
948
954
  static get events() {
@@ -1,7 +1,7 @@
1
1
  import { citiesDictionary } from "../../../fixtures/cities";
2
2
  import { themeInputVariantDictionary } from "../../../dictionary/variant";
3
3
  import { autoCompleteDictionary } from "../../../dictionary/autocomplete";
4
- import { inputTextTypeDictionary, inputControlsLayoutDictionary, inputControlsIconDictionary } from "../../../dictionary/input";
4
+ import { inputTextTypeDictionary, inputControlsLayoutDictionary, inputControlsIconDictionary, } from "../../../dictionary/input";
5
5
  import { typographyInputDictionary } from "../../../dictionary/typography";
6
6
  import { iconsDictionary } from "../../../dictionary/icon";
7
7
  import { h } from "@stencil/core";
@@ -128,101 +128,135 @@ export default {
128
128
  },
129
129
  };
130
130
  const Template = (args) => h("mds-input", Object.assign({}, args));
131
- const TemplateLanguage = (args) => h("div", { class: "grid gap-400" }, h("mds-input", Object.assign({}, args)), h("div", { class: "grid gap grid-cols-3" }, h("mds-pref", null, h("mds-pref-language", null, h("mds-pref-language-item", { code: "it" }), h("mds-pref-language-item", { code: "en" }), h("mds-pref-language-item", { code: "el" }), h("mds-pref-language-item", { code: "es" }), h("mds-pref-language-item", { code: "ja" })))));
132
- export const Default = Template.bind({});
133
- Default.args = {
134
- placeholder: 'Scrivi qualcosa',
131
+ const TemplateLanguage = (args) => (h("div", { class: "grid gap-400" }, h("mds-input", Object.assign({}, args)), h("div", { class: "grid gap grid-cols-3" }, h("mds-pref", null, h("mds-pref-language", null, h("mds-pref-language-item", { code: "it" }), h("mds-pref-language-item", { code: "en" }), h("mds-pref-language-item", { code: "el" }), h("mds-pref-language-item", { code: "es" }), h("mds-pref-language-item", { code: "ja" }))))));
132
+ export const Default = {
133
+ render: Template,
134
+ args: {
135
+ placeholder: 'Scrivi qualcosa',
136
+ },
135
137
  };
136
- export const AutoComplete = Template.bind({});
137
- AutoComplete.args = {
138
- autocomplete: 'address',
139
- type: 'text',
140
- placeholder: 'Intestatario carta di credito',
138
+ export const AutoComplete = {
139
+ render: Template,
140
+ args: {
141
+ autocomplete: 'address',
142
+ type: 'text',
143
+ placeholder: 'Intestatario carta di credito',
144
+ },
141
145
  };
142
- export const AutoFocus = Template.bind({});
143
- AutoFocus.args = {
144
- autofocus: true,
145
- placeholder: 'Auto focus input text',
146
+ export const AutoFocus = {
147
+ render: Template,
148
+ args: {
149
+ autofocus: true,
150
+ placeholder: 'Auto focus input text',
151
+ },
146
152
  };
147
- export const ControlsLayout = Template.bind({});
148
- ControlsLayout.args = {
149
- 'controls-layout': 'horizontal',
150
- type: 'number',
151
- placeholder: 'Controls layout',
153
+ export const ControlsLayout = {
154
+ render: Template,
155
+ args: {
156
+ 'controls-layout': 'horizontal',
157
+ type: 'number',
158
+ placeholder: 'Controls layout',
159
+ },
152
160
  };
153
- export const ControlsIcon = Template.bind({});
154
- ControlsIcon.args = {
155
- 'controls-icon': 'arithmetic',
156
- type: 'number',
157
- placeholder: 'Controls icon',
161
+ export const ControlsIcon = {
162
+ render: Template,
163
+ args: {
164
+ 'controls-icon': 'arithmetic',
165
+ type: 'number',
166
+ placeholder: 'Controls icon',
167
+ },
158
168
  };
159
- export const ControlsLabels = Template.bind({});
160
- ControlsLabels.args = {
161
- 'controls-icon': 'arrow',
162
- 'controls-layout': 'horizontal',
163
- 'control-increase-label': 'Alza',
164
- 'control-decrease-label': 'Abbassa',
165
- type: 'number',
166
- placeholder: 'Controls labels',
169
+ export const ControlsLabels = {
170
+ render: Template,
171
+ args: {
172
+ 'controls-icon': 'arrow',
173
+ 'controls-layout': 'horizontal',
174
+ 'control-increase-label': 'Alza',
175
+ 'control-decrease-label': 'Abbassa',
176
+ type: 'number',
177
+ placeholder: 'Controls labels',
178
+ },
167
179
  };
168
- export const Disabled = Template.bind({});
169
- Disabled.args = {
170
- disabled: true,
171
- placeholder: 'Disabled',
180
+ export const Disabled = {
181
+ render: Template,
182
+ args: {
183
+ disabled: true,
184
+ placeholder: 'Disabled',
185
+ },
172
186
  };
173
- export const Max = Template.bind({});
174
- Max.args = {
175
- max: '3',
176
- type: 'number',
177
- value: '2',
187
+ export const Max = {
188
+ render: Template,
189
+ args: {
190
+ max: '3',
191
+ type: 'number',
192
+ value: '2',
193
+ },
178
194
  };
179
- export const MaxLength = Template.bind({});
180
- MaxLength.args = {
181
- maxlength: 128,
182
- type: 'text',
183
- value: 'Hello',
195
+ export const MaxLength = {
196
+ render: Template,
197
+ args: {
198
+ maxlength: 128,
199
+ type: 'text',
200
+ value: 'Hello',
201
+ },
184
202
  };
185
- export const Min = Template.bind({});
186
- Min.args = {
187
- min: '3',
188
- type: 'number',
189
- value: '5',
203
+ export const Min = {
204
+ render: Template,
205
+ args: {
206
+ min: '3',
207
+ type: 'number',
208
+ value: '5',
209
+ },
190
210
  };
191
- export const MinLength = Template.bind({});
192
- MinLength.args = {
193
- MinLength: 5,
194
- type: 'text',
195
- value: 'Hello',
211
+ export const MinLength = {
212
+ render: Template,
213
+ args: {
214
+ MinLength: 5,
215
+ type: 'text',
216
+ value: 'Hello',
217
+ },
196
218
  };
197
- export const Required = Template.bind({});
198
- Required.args = {
199
- required: true,
200
- placeholder: 'This is a required field',
219
+ export const Required = {
220
+ render: Template,
221
+ args: {
222
+ required: true,
223
+ placeholder: 'This is a required field',
224
+ },
201
225
  };
202
- export const ReadOnly = Template.bind({});
203
- ReadOnly.args = {
204
- readOnly: true,
205
- value: 'Read only text',
226
+ export const ReadOnly = {
227
+ render: Template,
228
+ args: {
229
+ readOnly: true,
230
+ value: 'Read only text',
231
+ },
206
232
  };
207
- export const Variant = Template.bind({});
208
- Variant.args = {
209
- variant: 'error',
210
- placeholder: 'Status input field',
211
- tip: 'errore',
233
+ export const Variant = {
234
+ render: Template,
235
+ args: {
236
+ variant: 'error',
237
+ placeholder: 'Status input field',
238
+ tip: 'errore',
239
+ },
212
240
  };
213
- export const Tip = Template.bind({});
214
- Tip.args = {
215
- placeholder: 'Scrivi qualcosa...',
216
- tip: 'input',
241
+ export const Tip = {
242
+ render: Template,
243
+ args: {
244
+ placeholder: 'Scrivi qualcosa...',
245
+ tip: 'input',
246
+ },
217
247
  };
218
- export const Password = Template.bind({});
219
- Password.args = {
220
- type: 'password',
221
- placeholder: 'Insert a pasword',
248
+ export const Password = {
249
+ render: Template,
250
+ args: {
251
+ type: 'password',
252
+ placeholder: 'Insert a pasword',
253
+ },
222
254
  };
223
- export const Placeholder = Template.bind({});
224
- Placeholder.args = {
225
- placeholder: 'Es: change this placeholder',
255
+ export const Placeholder = {
256
+ render: Template,
257
+ args: {
258
+ placeholder: 'Es: change this placeholder',
259
+ },
226
260
  };
227
261
  const TemplateSearch = (args) => {
228
262
  useEffect(() => {
@@ -230,33 +264,43 @@ const TemplateSearch = (args) => {
230
264
  });
231
265
  return h("mds-input", Object.assign({}, args));
232
266
  };
233
- export const Search = TemplateSearch.bind({});
234
- Search.args = {
235
- datalist: citiesDictionary,
236
- type: 'search',
237
- placeholder: 'Search a city name...',
267
+ export const Search = {
268
+ render: TemplateSearch,
269
+ args: {
270
+ datalist: citiesDictionary,
271
+ type: 'search',
272
+ placeholder: 'Search a city name...',
273
+ },
238
274
  };
239
- export const Icon = Template.bind({});
240
- Icon.args = {
241
- icon: 'mi/round/email',
242
- placeholder: 'Status input field',
275
+ export const Icon = {
276
+ render: Template,
277
+ args: {
278
+ icon: 'mi/round/email',
279
+ placeholder: 'Status input field',
280
+ },
243
281
  };
244
- export const TestLanguageChange = TemplateLanguage.bind({});
245
- TestLanguageChange.args = {
246
- icon: 'mi/round/email',
247
- readonly: true,
248
- placeholder: 'Status input field',
282
+ export const TestLanguageChange = {
283
+ render: TemplateLanguage,
284
+ args: {
285
+ icon: 'mi/round/email',
286
+ readonly: true,
287
+ placeholder: 'Status input field',
288
+ },
249
289
  };
250
- export const VariantAi = Template.bind({});
251
- VariantAi.args = {
252
- variant: 'ai',
253
- placeholder: 'Es: Come si cresce un bovaro del bernese?',
290
+ export const VariantAi = {
291
+ render: Template,
292
+ args: {
293
+ variant: 'ai',
294
+ placeholder: 'Es: Come si cresce un bovaro del bernese?',
295
+ },
254
296
  };
255
- export const TextRecognition = Template.bind({});
256
- TextRecognition.args = {
257
- variant: 'ai',
258
- mic: true,
259
- placeholder: 'Es: Come si cresce un bovaro del bernese?',
297
+ export const TextRecognition = {
298
+ render: Template,
299
+ args: {
300
+ variant: 'ai',
301
+ mic: true,
302
+ placeholder: 'Es: Come si cresce un bovaro del bernese?',
303
+ },
260
304
  };
261
305
  const FormIntegrationTemplate = (args) => {
262
306
  return (h("div", { class: "grid gap-600" }, h("form", { class: "grid gap-400", id: "mds-icon-fi", name: "mds-icon-fi", onSubmit: (e) => {
@@ -266,11 +310,16 @@ const FormIntegrationTemplate = (args) => {
266
310
  e.preventDefault();
267
311
  const form = document.querySelector('form');
268
312
  const span = document.querySelector('span.input-value');
269
- span.innerText = form['mds-input'].value !== '' ? form['mds-input'].value : 'Empty';
270
- } }, "Check value")), h("mds-text", { variant: "code" }, "Input value taken from form element: ", h("span", { class: "inline-flex input-value rounded text-tone-neutral-01 bg-tone-neutral-08 px-200 py-50" }, "Empty"))));
313
+ span.innerText =
314
+ form['mds-input'].value !== ''
315
+ ? form['mds-input'].value
316
+ : 'Empty';
317
+ } }, "Check value")), h("mds-text", { variant: "code" }, "Input value taken from form element:", ' ', h("span", { class: "inline-flex input-value rounded text-tone-neutral-01 bg-tone-neutral-08 px-200 py-50" }, "Empty"))));
271
318
  };
272
- export const FormIntegration = FormIntegrationTemplate.bind({});
273
- FormIntegration.args = {
274
- placeholder: 'Es: Hello world!',
275
- name: 'mds-input',
319
+ export const FormIntegration = {
320
+ render: FormIntegrationTemplate,
321
+ args: {
322
+ placeholder: 'Es: Hello world!',
323
+ name: 'mds-input',
324
+ },
276
325
  };
@@ -1146,7 +1146,6 @@ const MdsInput$1 = /*@__PURE__*/ proxyCustomElement(class MdsInput extends HTMLE
1146
1146
  this.isRecording = false;
1147
1147
  this.countVariant = 'count-empty';
1148
1148
  this.isPasswordVisible = false;
1149
- this.transcript = '';
1150
1149
  // private valuePristine?: string
1151
1150
  this.t = new Locale({
1152
1151
  el: localeEl,
@@ -1315,11 +1314,19 @@ const MdsInput$1 = /*@__PURE__*/ proxyCustomElement(class MdsInput extends HTMLE
1315
1314
  this.recognition.lang = navigator.language || 'it-IT';
1316
1315
  this.recognition.interimResults = true;
1317
1316
  this.recognition.maxAlternatives = 1;
1317
+ let transcript = '';
1318
+ let progress = 0; // need to save position progress on speech results
1318
1319
  // eslint-disable-next-line @typescript-eslint/no-explicit-any
1319
1320
  this.recognition.onresult = (event) => {
1320
- const speechResult = event.results[0][0].transcript;
1321
- this.transcript = speechResult;
1322
- this.value = this.transcript;
1321
+ const speechResult = event.results;
1322
+ const interimResult = speechResult[progress];
1323
+ if (interimResult.isFinal) {
1324
+ transcript += interimResult[0].transcript;
1325
+ this.value = transcript;
1326
+ progress += 1;
1327
+ return;
1328
+ }
1329
+ this.value = transcript + interimResult[0].transcript;
1323
1330
  };
1324
1331
  // eslint-disable-next-line @typescript-eslint/no-explicit-any
1325
1332
  this.recognition.onerror = (event) => {
@@ -1480,21 +1487,21 @@ const MdsInput$1 = /*@__PURE__*/ proxyCustomElement(class MdsInput extends HTMLE
1480
1487
  }
1481
1488
  render() {
1482
1489
  var _a, _b;
1483
- return (h(Host, { key: '648689ad5aa037e75aa79e6108546b27d262aedc' }, this.type === 'number'
1490
+ return (h(Host, { key: '6c3728c33cf55c79ffa444d89154255695baf62b' }, this.type === 'number'
1484
1491
  && this.controlsLayout === 'horizontal'
1485
- && h("mds-button", { key: '92db9293088b824482526ad1477e6bae28ca70d9', class: "counter-button counter-button--horizontal counter-button--decrease", icon: this.controlsIcon === 'arrow' ? miBaselineArrowDown : miBaselineRemove, onClick: this.stepDown, tabindex: "0", title: this.t.get('decrease'), part: "counter-button-decrease" }), this.type === 'textarea'
1492
+ && h("mds-button", { key: '0e2e5e0644bd6b3aad3b8b12df734abfc309927e', class: "counter-button counter-button--horizontal counter-button--decrease", icon: this.controlsIcon === 'arrow' ? miBaselineArrowDown : miBaselineRemove, onClick: this.stepDown, tabindex: "0", title: this.t.get('decrease'), part: "counter-button-decrease" }), this.type === 'textarea'
1486
1493
  ? h("textarea", { class: clsx('input', ((_a = this.icon) !== null && _a !== void 0 ? _a : this.await) && 'has-icon', this.mic && 'has-right-icon'), autoFocus: this.autofocus, disabled: this.disabled, maxLength: this.maxlength, minLength: this.minlength, name: this.name, onBlur: this.onBlur, onFocus: this.onFocus, onInput: this.onInput, part: "field", placeholder: this.placeholder, readOnly: this.readonly, ref: input => (this.nativeInput = input), required: this.required, tabIndex: this.tabindex, value: this.value })
1487
1494
  : h("input", { class: clsx('input', ((_b = this.icon) !== null && _b !== void 0 ? _b : this.await) && 'has-icon', this.mic && 'has-right-icon'), autoComplete: this.autocomplete, autoFocus: this.autofocus, disabled: this.disabled, max: this.max, maxLength: this.maxlength, min: this.min, minLength: this.minlength, name: this.name, onBlur: this.onBlur, onFocus: this.onFocus, onInput: this.onInput, pattern: this.pattern, list: this.datalistId, part: "field", placeholder: this.placeholder, readOnly: this.readonly, ref: input => (this.nativeInput = input), required: this.required, step: this.step, tabIndex: this.tabindex, type: this.type === 'password' && this.isPasswordVisible ? 'text' : this.type, value: this.value }), this.type === 'number'
1488
1495
  && this.controlsLayout === 'vertical'
1489
- && h("div", { key: '7a26c610edafb5bd6dc95c7d07cf1f5621eb0f27', class: "counter counter--vertical" }, h("mds-button", { key: 'c5a69b3fdfdd645592d4b899822f61280769c48a', class: "counter-button", icon: this.controlsIcon === 'arrow' ? miBaselineArrowUp : miBaselineAdd, onClick: this.stepUp, tabindex: "0", title: this.t.get('increase'), part: "counter-button-increase" }), h("mds-button", { key: 'a5e510b3a98155ad78dc7bec5f40a0447135d32b', class: "counter-button", icon: this.controlsIcon === 'arrow' ? miBaselineArrowDown : miBaselineRemove, onClick: this.stepDown, tabindex: "0", title: this.t.get('decrease'), part: "counter-button-decrease" })), this.type === 'number'
1496
+ && h("div", { key: '48fd016a7a0917ba5c669789ed373221e8e920d7', class: "counter counter--vertical" }, h("mds-button", { key: '8507fb252cbb8a92bc1b9cce05df97e01e900593', class: "counter-button", icon: this.controlsIcon === 'arrow' ? miBaselineArrowUp : miBaselineAdd, onClick: this.stepUp, tabindex: "0", title: this.t.get('increase'), part: "counter-button-increase" }), h("mds-button", { key: 'c22c5b5370f3121645f053b3c3d91e7fc5933a08', class: "counter-button", icon: this.controlsIcon === 'arrow' ? miBaselineArrowDown : miBaselineRemove, onClick: this.stepDown, tabindex: "0", title: this.t.get('decrease'), part: "counter-button-decrease" })), this.type === 'number'
1490
1497
  && this.controlsLayout === 'horizontal'
1491
- && h("mds-button", { key: '178d90aafc52d838e8a2e7065931ca48fae2ce81', class: "counter-button counter-button--horizontal counter-button--increase", icon: this.controlsIcon === 'arrow' ? miBaselineArrowUp : miBaselineAdd, onClick: this.stepUp, tabindex: "0", title: this.t.get('increase'), part: "counter-button-increase" }), this.type === 'password'
1492
- && h("mds-button", { key: '6ba4f1ce6db2a03f4beec5105e63689517c836df', class: "password-toggle-button", icon: this.isPasswordVisible ? miBaselineVisibleOff : miBaselineVisible, onClick: () => this.isPasswordVisible = !this.isPasswordVisible, tabindex: "0", tone: "quiet", title: this.isPasswordVisible ? this.t.get('hidePassword') : this.t.get('showPassword'), part: "password-toggle-button" }), this.mic
1493
- && h("mds-button", { key: '6d31ca6b568f2308b92fc267c7b048709a0fc43d', class: clsx('mic-toggle-button', this.isRecording && 'mic-toggle-button--recording'), icon: this.speechToTextIcon, onClick: () => this.toggleTextRecognition(), tabindex: "0", variant: "dark", tone: "quiet", title: this.speechToTextLabel, part: "mic-toggle-button" }), h("mds-input-tip", { key: '91c4d5034f8f7cce57f312aafb4a5ea87e70d0d2', lang: this.language, position: "top", active: this.hasFocus }, this.disabled && h("mds-input-tip-item", { key: 'a63198033ff3ece7c9962ae51c5b1c21c7021579', expanded: true, variant: "disabled" }), this.readonly && h("mds-input-tip-item", { key: '856cb3387ab27a9b82442bf36db2d670a685bd69', expanded: true, variant: "readonly" }), this.required &&
1494
- h("mds-input-tip-item", { key: '26ff9e6801f2d558a36736ef1c62543cbc1e2795', expanded: this.hasFocus, variant: this.isValid ? 'required-success' : 'required' })), h("mds-input-tip", { key: '55b2bea8c5860db8dd8b3c3a0f2277b050bf610a', lang: this.language, position: "bottom", active: this.hasFocus }, this.tip && h("mds-input-tip-item", { key: 'a0d407594e91bff200062cf1915bf93843015f36', expanded: true, variant: "text" }, this.tip), this.maxlength && h("mds-input-tip-item", { key: '59b89c4e91582562ebb608a428d0601b0b3abc24', part: "tip-count", expanded: true, variant: this.countVariant }, this.currentLengthLabel)), this.datalist &&
1495
- h("datalist", { key: '47869a8f66759aad40645ac4fe2b9c8e9ddc2325', id: this.datalistId, class: "datalist" }, this.datalist.map((element, i) => {
1498
+ && h("mds-button", { key: '10215d151779798d8b77d44e7bac708f1c737939', class: "counter-button counter-button--horizontal counter-button--increase", icon: this.controlsIcon === 'arrow' ? miBaselineArrowUp : miBaselineAdd, onClick: this.stepUp, tabindex: "0", title: this.t.get('increase'), part: "counter-button-increase" }), this.type === 'password'
1499
+ && h("mds-button", { key: 'f97e9aeb646697bd63ec7cf152bbe56ff41f7902', class: "password-toggle-button", icon: this.isPasswordVisible ? miBaselineVisibleOff : miBaselineVisible, onClick: () => this.isPasswordVisible = !this.isPasswordVisible, tabindex: "0", tone: "quiet", title: this.isPasswordVisible ? this.t.get('hidePassword') : this.t.get('showPassword'), part: "password-toggle-button" }), this.mic
1500
+ && h("mds-button", { key: 'e293ab7cc45fa62973830e6a8d50a4752f9b9a3c', class: clsx('mic-toggle-button', this.isRecording && 'mic-toggle-button--recording'), icon: this.speechToTextIcon, onClick: () => this.toggleTextRecognition(), tabindex: "0", variant: "dark", tone: "quiet", title: this.speechToTextLabel, part: "mic-toggle-button" }), h("mds-input-tip", { key: '5f0fbae757653b1d3bcbb2a24bc8f897d37f24fc', lang: this.language, position: "top", active: this.hasFocus, part: 'tip-top' }, this.disabled && h("mds-input-tip-item", { key: '4f0b400762f31ee29d767afccca5daf3d37734f9', expanded: true, variant: "disabled" }), this.readonly && h("mds-input-tip-item", { key: '4ebf8150c21ccf4ebb3bff559735305d5df69fd1', expanded: true, variant: "readonly" }), this.required &&
1501
+ h("mds-input-tip-item", { key: '96af6b54e03f634a604193579772c076b5857eb4', expanded: this.hasFocus, variant: this.isValid ? 'required-success' : 'required' })), h("mds-input-tip", { key: '4b57532ce1640feba598504f9d53a024bdd56f43', lang: this.language, position: "bottom", active: this.hasFocus, part: 'tip-bottom' }, this.tip && h("mds-input-tip-item", { key: 'c54fc1e7903946ab4d6b8a77beb54df3fc108ba0', expanded: true, variant: "text" }, this.tip), this.maxlength && h("mds-input-tip-item", { key: '60f23a6717e8effc1b01064349fa78df198b89e4', part: "tip-count", expanded: true, variant: this.countVariant }, this.currentLengthLabel)), this.datalist &&
1502
+ h("datalist", { key: '7ff09a4e142d4e070b55c2bd6101eacae8f91889', id: this.datalistId, class: "datalist" }, this.datalist.map((element, i) => {
1496
1503
  return h("option", { key: i, value: element });
1497
- })), this.icon && !this.await && h("mds-icon", { key: 'a1bd0fa20067f42462a126d0a25d1aff8e72cd4f', class: clsx('icon', this.variant), name: this.icon }), h("mds-spinner", { key: 'ee45b5b26e83dbf43c3bf82eb97625774c001f77', running: this.await, class: clsx('await', this.variant) })));
1504
+ })), this.icon && !this.await && h("mds-icon", { key: '12f4bb73d9edec126cf5b86c2d83e646c1504e78', class: clsx('icon', this.variant), name: this.icon }), h("mds-spinner", { key: 'a8453e655fb3d09ccd1ed4c3a9a388414dd6e4fe', running: this.await, class: clsx('await', this.variant) })));
1498
1505
  }
1499
1506
  static get formAssociated() { return true; }
1500
1507
  get el() { return this; }
@@ -1538,7 +1545,6 @@ const MdsInput$1 = /*@__PURE__*/ proxyCustomElement(class MdsInput extends HTMLE
1538
1545
  "currentLengthLabel": [32],
1539
1546
  "countVariant": [32],
1540
1547
  "isPasswordVisible": [32],
1541
- "transcript": [32],
1542
1548
  "updateLang": [64],
1543
1549
  "addValidator": [64],
1544
1550
  "removeValidator": [64],
@@ -1,5 +1,5 @@
1
1
  {
2
- "timestamp": "2025-07-04T10:36:20",
2
+ "timestamp": "2026-01-16T14:57:17",
3
3
  "compiler": {
4
4
  "name": "@stencil/core",
5
5
  "version": "4.27.2",
@@ -1234,9 +1234,17 @@
1234
1234
  "name": "password-toggle-button",
1235
1235
  "docs": ""
1236
1236
  },
1237
+ {
1238
+ "name": "tip-bottom",
1239
+ "docs": ""
1240
+ },
1237
1241
  {
1238
1242
  "name": "tip-count",
1239
1243
  "docs": ""
1244
+ },
1245
+ {
1246
+ "name": "tip-top",
1247
+ "docs": ""
1240
1248
  }
1241
1249
  ],
1242
1250
  "dependents": [],