@momentum-design/components 0.80.0 → 0.80.2

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 (69) hide show
  1. package/dist/browser/index.js +420 -398
  2. package/dist/browser/index.js.map +4 -4
  3. package/dist/components/checkbox/checkbox.component.d.ts +4 -0
  4. package/dist/components/checkbox/checkbox.component.js +4 -0
  5. package/dist/components/checkbox/index.d.ts +4 -1
  6. package/dist/components/checkbox/index.js +5 -2
  7. package/dist/components/dialog/dialog.component.d.ts +25 -8
  8. package/dist/components/dialog/dialog.component.js +50 -19
  9. package/dist/components/formfieldgroup/formfieldgroup.component.d.ts +5 -0
  10. package/dist/components/formfieldgroup/formfieldgroup.component.js +5 -0
  11. package/dist/components/formfieldgroup/index.d.ts +4 -2
  12. package/dist/components/formfieldgroup/index.js +4 -2
  13. package/dist/components/formfieldwrapper/formfieldwrapper.component.d.ts +21 -1
  14. package/dist/components/formfieldwrapper/formfieldwrapper.component.js +40 -2
  15. package/dist/components/formfieldwrapper/formfieldwrapper.constants.d.ts +3 -0
  16. package/dist/components/formfieldwrapper/formfieldwrapper.constants.js +3 -0
  17. package/dist/components/formfieldwrapper/index.d.ts +3 -1
  18. package/dist/components/formfieldwrapper/index.js +4 -2
  19. package/dist/components/input/index.d.ts +2 -1
  20. package/dist/components/input/index.js +3 -2
  21. package/dist/components/input/input.component.d.ts +1 -0
  22. package/dist/components/input/input.component.js +1 -0
  23. package/dist/components/input/input.constants.d.ts +1 -1
  24. package/dist/components/popover/popover.component.d.ts +1 -1
  25. package/dist/components/popover/popover.component.js +2 -6
  26. package/dist/components/progressbar/progressbar.component.js +2 -0
  27. package/dist/components/radio/index.d.ts +5 -1
  28. package/dist/components/radio/index.js +5 -1
  29. package/dist/components/radio/radio.component.d.ts +6 -1
  30. package/dist/components/radio/radio.component.js +6 -1
  31. package/dist/components/select/index.d.ts +2 -0
  32. package/dist/components/select/index.js +2 -0
  33. package/dist/components/select/select.component.d.ts +2 -1
  34. package/dist/components/select/select.component.js +7 -6
  35. package/dist/components/textarea/index.d.ts +1 -0
  36. package/dist/components/textarea/index.js +1 -0
  37. package/dist/components/textarea/textarea.component.d.ts +2 -2
  38. package/dist/components/textarea/textarea.component.js +2 -2
  39. package/dist/components/toggle/index.d.ts +3 -0
  40. package/dist/components/toggle/index.js +3 -0
  41. package/dist/components/toggle/toggle.component.d.ts +3 -0
  42. package/dist/components/toggle/toggle.component.js +3 -0
  43. package/dist/components/toggletip/toggletip.component.d.ts +1 -1
  44. package/dist/components/toggletip/toggletip.component.js +5 -12
  45. package/dist/components/toggletip/toggletip.styles.js +2 -2
  46. package/dist/custom-elements.json +2328 -1498
  47. package/dist/react/checkbox/index.d.ts +4 -0
  48. package/dist/react/checkbox/index.js +4 -0
  49. package/dist/react/formfieldgroup/index.d.ts +5 -0
  50. package/dist/react/formfieldgroup/index.js +5 -0
  51. package/dist/react/formfieldwrapper/index.d.ts +5 -1
  52. package/dist/react/formfieldwrapper/index.js +5 -1
  53. package/dist/react/index.d.ts +1 -1
  54. package/dist/react/index.js +1 -1
  55. package/dist/react/input/index.d.ts +1 -0
  56. package/dist/react/input/index.js +1 -0
  57. package/dist/react/radio/index.d.ts +6 -1
  58. package/dist/react/radio/index.js +6 -1
  59. package/dist/react/select/index.d.ts +2 -0
  60. package/dist/react/select/index.js +2 -0
  61. package/dist/react/textarea/index.d.ts +2 -2
  62. package/dist/react/textarea/index.js +2 -2
  63. package/dist/react/toggle/index.d.ts +3 -0
  64. package/dist/react/toggle/index.js +3 -0
  65. package/dist/utils/mixins/CardAndDialogFooterMixin.d.ts +3 -3
  66. package/dist/utils/mixins/CardAndDialogFooterMixin.js +20 -16
  67. package/package.json +1 -1
  68. package/dist/components/dialog/dialog.utils.d.ts +0 -7
  69. package/dist/components/dialog/dialog.utils.js +0 -33
@@ -10,7 +10,11 @@ declare const Checkbox_base: import("../../utils/mixins/index.types").Constructo
10
10
  *
11
11
  * To create a group of checkboxes, use the FormFieldGroup component.
12
12
  *
13
+ * @dependency mdc-button
13
14
  * @dependency mdc-icon
15
+ * @dependency mdc-staticcheckbox
16
+ * @dependency mdc-text
17
+ * @dependency mdc-toggletip
14
18
  *
15
19
  * @tagname mdc-checkbox
16
20
  *
@@ -23,7 +23,11 @@ import styles from './checkbox.styles';
23
23
  *
24
24
  * To create a group of checkboxes, use the FormFieldGroup component.
25
25
  *
26
+ * @dependency mdc-button
26
27
  * @dependency mdc-icon
28
+ * @dependency mdc-staticcheckbox
29
+ * @dependency mdc-text
30
+ * @dependency mdc-toggletip
27
31
  *
28
32
  * @tagname mdc-checkbox
29
33
  *
@@ -1,6 +1,9 @@
1
- import Checkbox from './checkbox.component';
1
+ import '../button';
2
2
  import '../icon';
3
3
  import '../staticcheckbox';
4
+ import '../text';
5
+ import '../toggletip';
6
+ import Checkbox from './checkbox.component';
4
7
  declare global {
5
8
  interface HTMLElementTagNameMap {
6
9
  ['mdc-checkbox']: Checkbox;
@@ -1,6 +1,9 @@
1
- import Checkbox from './checkbox.component';
2
- import { TAG_NAME } from './checkbox.constants';
1
+ import '../button';
3
2
  import '../icon';
4
3
  import '../staticcheckbox';
4
+ import '../text';
5
+ import '../toggletip';
6
+ import Checkbox from './checkbox.component';
7
+ import { TAG_NAME } from './checkbox.constants';
5
8
  Checkbox.register(TAG_NAME);
6
9
  export default Checkbox;
@@ -56,8 +56,10 @@ declare class Dialog extends Dialog_base {
56
56
  id: string;
57
57
  /**
58
58
  * The ID of the element that triggers the dialog
59
+ *
60
+ * @default undefined
59
61
  */
60
- triggerId: string;
62
+ triggerId?: string;
61
63
  /**
62
64
  * The visibility of the dialog
63
65
  * @default false
@@ -73,6 +75,10 @@ declare class Dialog extends Dialog_base {
73
75
  * @default small
74
76
  */
75
77
  size: DialogSize;
78
+ /**
79
+ * The variant of the dialog, can be 'default' or 'promotional'
80
+ * @default default
81
+ */
76
82
  variant: DialogVariant;
77
83
  /**
78
84
  * Defines a string value for the aria-label attribute for close button accessibility
@@ -90,11 +96,11 @@ declare class Dialog extends Dialog_base {
90
96
  /**
91
97
  * Defines a string value to display as the title of the dialog
92
98
  */
93
- headerText: string;
99
+ headerText?: string;
94
100
  /**
95
101
  * Defines a string value to display as the under-header description of the dialog
96
102
  */
97
- descriptionText: string;
103
+ descriptionText?: string;
98
104
  /**
99
105
  * The html tag to be used for the header text
100
106
  */
@@ -109,14 +115,25 @@ declare class Dialog extends Dialog_base {
109
115
  */
110
116
  role: DialogRole;
111
117
  /** @internal */
112
- triggerElement: HTMLElement | null;
118
+ protected triggerElement: HTMLElement | null;
113
119
  /** @internal */
114
- private utils;
120
+ protected backdropElement: HTMLElement | null;
115
121
  /** @internal */
116
- backdropElement: HTMLElement | null;
117
- /** @internal */
118
- private lastActiveElement;
122
+ protected lastActiveElement: HTMLElement | null;
119
123
  constructor();
124
+ /**
125
+ * Sets up the aria attributes for the dialog based on the header text and aria attributes.
126
+ * If no header text or aria attributes are provided, it will use the triggerId if available.
127
+ * @internal
128
+ */
129
+ private setupAriaAttributes;
130
+ /**
131
+ * Creates a backdrop element for the dialog.
132
+ * The backdrop is a full-screen overlay that appears behind the dialog when it is open.
133
+ * It prevents interaction with the rest of the application while the dialog is open.
134
+ * @internal
135
+ */
136
+ private createBackdrop;
120
137
  protected firstUpdated(changedProperties: PropertyValues): Promise<void>;
121
138
  disconnectedCallback(): Promise<void>;
122
139
  /**
@@ -14,7 +14,6 @@ import styles from './dialog.styles';
14
14
  import { Component } from '../../models';
15
15
  import { FocusTrapMixin } from '../../utils/mixins/FocusTrapMixin';
16
16
  import { DEFAULTS } from './dialog.constants';
17
- import { DialogUtils } from './dialog.utils';
18
17
  import { TYPE, VALID_TEXT_TAGS } from '../text/text.constants';
19
18
  import { DialogEventManager } from './dialog.events';
20
19
  import { BUTTON_VARIANTS, ICON_BUTTON_SIZES } from '../button/button.constants';
@@ -73,10 +72,6 @@ class Dialog extends FocusTrapMixin(CardAndDialogFooterMixin(Component)) {
73
72
  * The unique ID of the dialog
74
73
  */
75
74
  this.id = '';
76
- /**
77
- * The ID of the element that triggers the dialog
78
- */
79
- this.triggerId = '';
80
75
  /**
81
76
  * The visibility of the dialog
82
77
  * @default false
@@ -92,6 +87,10 @@ class Dialog extends FocusTrapMixin(CardAndDialogFooterMixin(Component)) {
92
87
  * @default small
93
88
  */
94
89
  this.size = DEFAULTS.SIZE;
90
+ /**
91
+ * The variant of the dialog, can be 'default' or 'promotional'
92
+ * @default default
93
+ */
95
94
  this.variant = DEFAULTS.VARIANT;
96
95
  /**
97
96
  * Defines a string value for the aria-label attribute for close button accessibility
@@ -106,14 +105,6 @@ class Dialog extends FocusTrapMixin(CardAndDialogFooterMixin(Component)) {
106
105
  * Defines a string value for the aria-label attribute when header is not used
107
106
  */
108
107
  this.ariaLabel = null;
109
- /**
110
- * Defines a string value to display as the title of the dialog
111
- */
112
- this.headerText = '';
113
- /**
114
- * Defines a string value to display as the under-header description of the dialog
115
- */
116
- this.descriptionText = '';
117
108
  /**
118
109
  * The html tag to be used for the header text
119
110
  */
@@ -159,14 +150,53 @@ class Dialog extends FocusTrapMixin(CardAndDialogFooterMixin(Component)) {
159
150
  this.showDialog = () => {
160
151
  this.visible = true;
161
152
  };
162
- /** @internal */
163
- this.utils = new DialogUtils(this);
164
153
  document.addEventListener('keydown', this.onEscapeKeydown);
165
154
  }
155
+ /**
156
+ * Sets up the aria attributes for the dialog based on the header text and aria attributes.
157
+ * If no header text or aria attributes are provided, it will use the triggerId if available.
158
+ * @internal
159
+ */
160
+ setupAriaAttributes() {
161
+ if (this.headerText && !this.ariaLabel && !this.ariaLabelledby) {
162
+ this.setAttribute('aria-labelledby', this.headerText);
163
+ }
164
+ else if (!this.headerText && !this.ariaLabel && !this.ariaLabelledby) {
165
+ if (this.triggerId) {
166
+ this.setAttribute('aria-labelledby', this.triggerId);
167
+ }
168
+ }
169
+ }
170
+ /**
171
+ * Creates a backdrop element for the dialog.
172
+ * The backdrop is a full-screen overlay that appears behind the dialog when it is open.
173
+ * It prevents interaction with the rest of the application while the dialog is open.
174
+ * @internal
175
+ */
176
+ createBackdrop() {
177
+ var _a;
178
+ const backdrop = document.createElement('div');
179
+ backdrop.classList.add('dialog-backdrop');
180
+ const styleElement = document.createElement('style');
181
+ styleElement.textContent = `
182
+ .dialog-backdrop {
183
+ position: fixed;
184
+ top: 0;
185
+ left: 0;
186
+ width: 100%;
187
+ height: 100%;
188
+ background: var(--mds-color-theme-common-overlays-secondary-normal);
189
+ z-index: ${this.zIndex - 1};
190
+ }
191
+ `;
192
+ backdrop.appendChild(styleElement);
193
+ (_a = this.parentElement) === null || _a === void 0 ? void 0 : _a.appendChild(backdrop);
194
+ this.backdropElement = backdrop;
195
+ }
166
196
  async firstUpdated(changedProperties) {
167
197
  super.firstUpdated(changedProperties);
168
198
  this.setupTriggerListener();
169
- this.utils.setupAriaAttributes();
199
+ this.setupAriaAttributes();
170
200
  this.style.zIndex = `${this.zIndex}`;
171
201
  DialogEventManager.onCreatedDialog(this);
172
202
  if (this.visible) {
@@ -212,7 +242,7 @@ class Dialog extends FocusTrapMixin(CardAndDialogFooterMixin(Component)) {
212
242
  }
213
243
  if (changedProperties.has('aria-label')
214
244
  || changedProperties.has('aria-labelledby')) {
215
- this.utils.setupAriaAttributes();
245
+ this.setupAriaAttributes();
216
246
  }
217
247
  }
218
248
  /**
@@ -232,7 +262,7 @@ class Dialog extends FocusTrapMixin(CardAndDialogFooterMixin(Component)) {
232
262
  this.lastActiveElement = document.activeElement;
233
263
  this.enabledFocusTrap = true;
234
264
  this.enabledPreventScroll = true;
235
- this.utils.createBackdrop();
265
+ this.createBackdrop();
236
266
  await this.handleCreateDialogFirstUpdate();
237
267
  // If we have a trigger element, update its attributes
238
268
  if (this.triggerElement) {
@@ -264,8 +294,9 @@ class Dialog extends FocusTrapMixin(CardAndDialogFooterMixin(Component)) {
264
294
  async handleCreateDialogFirstUpdate() {
265
295
  var _a, _b;
266
296
  if (this.visible) {
267
- (_a = this.setFocusableElements) === null || _a === void 0 ? void 0 : _a.call(this);
297
+ // Wait for the first update to complete before setting focusable elements
268
298
  await this.updateComplete;
299
+ (_a = this.setFocusableElements) === null || _a === void 0 ? void 0 : _a.call(this);
269
300
  (_b = this.setInitialFocus) === null || _b === void 0 ? void 0 : _b.call(this);
270
301
  }
271
302
  }
@@ -19,6 +19,11 @@ declare const FormfieldGroup_base: import("../../utils/mixins/index.types").Cons
19
19
  *
20
20
  * @tagname mdc-formfieldgroup
21
21
  *
22
+ * @dependency mdc-button
23
+ * @dependency mdc-icon
24
+ * @dependency mdc-text
25
+ * @dependency mdc-toggletip
26
+ *
22
27
  * @slot default - This is a default slot for checkbox or toggle components.
23
28
  */
24
29
  declare class FormfieldGroup extends FormfieldGroup_base {
@@ -23,6 +23,11 @@ import styles from './formfieldgroup.styles';
23
23
  *
24
24
  * @tagname mdc-formfieldgroup
25
25
  *
26
+ * @dependency mdc-button
27
+ * @dependency mdc-icon
28
+ * @dependency mdc-text
29
+ * @dependency mdc-toggletip
30
+ *
26
31
  * @slot default - This is a default slot for checkbox or toggle components.
27
32
  */
28
33
  class FormfieldGroup extends DataAriaLabelMixin(FormfieldWrapper) {
@@ -1,6 +1,8 @@
1
- import FormfieldGroup from './formfieldgroup.component';
2
- import '../text';
1
+ import '../button';
3
2
  import '../icon';
3
+ import '../text';
4
+ import '../toggletip';
5
+ import FormfieldGroup from './formfieldgroup.component';
4
6
  declare global {
5
7
  interface HTMLElementTagNameMap {
6
8
  ['mdc-formfieldgroup']: FormfieldGroup;
@@ -1,6 +1,8 @@
1
+ import '../button';
2
+ import '../icon';
3
+ import '../text';
4
+ import '../toggletip';
1
5
  import FormfieldGroup from './formfieldgroup.component';
2
6
  import { TAG_NAME } from './formfieldgroup.constants';
3
- import '../text';
4
- import '../icon';
5
7
  FormfieldGroup.register(TAG_NAME);
6
8
  export default FormfieldGroup;
@@ -1,5 +1,6 @@
1
1
  import { CSSResult, nothing } from 'lit';
2
2
  import { Component } from '../../models';
3
+ import type { PopoverPlacement } from '../popover/popover.types';
3
4
  import type { ValidationType } from './formfieldwrapper.types';
4
5
  declare const FormfieldWrapper_base: import("../../utils/mixins/index.types").Constructor<import("../../utils/mixins/DisabledMixin").DisabledMixinInterface> & typeof Component;
5
6
  /**
@@ -9,7 +10,11 @@ declare const FormfieldWrapper_base: import("../../utils/mixins/index.types").Co
9
10
  *
10
11
  * @tagname mdc-formfieldwrapper
11
12
  *
12
- * @slot label-info - slot to add the label info icon
13
+ * @dependency mdc-text
14
+ * @dependency mdc-icon
15
+ * @dependency mdc-button
16
+ * @dependency mdc-toggletip
17
+ *
13
18
  *
14
19
  */
15
20
  declare class FormfieldWrapper extends FormfieldWrapper_base {
@@ -36,6 +41,21 @@ declare class FormfieldWrapper extends FormfieldWrapper_base {
36
41
  * The help text that is displayed below the input field.
37
42
  */
38
43
  helpText?: string;
44
+ /**
45
+ * The toggletip text that is displayed when the label is hovered.
46
+ * It is used to provide additional information about the label.
47
+ */
48
+ toggletipText?: string;
49
+ /**
50
+ * The placement of the toggletip that is displayed when the info icon is hovered.
51
+ * @default 'top'
52
+ */
53
+ toggletipPlacement: PopoverPlacement;
54
+ /**
55
+ * Aria label for the info icon that is displayed next to the label when `toggletipText` is set.
56
+ * This is used for accessibility purposes to provide a description of the icon.
57
+ */
58
+ infoIconAriaLabel?: string;
39
59
  /** @internal */
40
60
  protected shouldRenderLabel: Boolean;
41
61
  /**
@@ -9,9 +9,11 @@ var __metadata = (this && this.__metadata) || function (k, v) {
9
9
  };
10
10
  import { html, nothing } from 'lit';
11
11
  import { property } from 'lit/decorators.js';
12
+ import { ifDefined } from 'lit/directives/if-defined.js';
12
13
  import { Component } from '../../models';
13
14
  import { DisabledMixin } from '../../utils/mixins/DisabledMixin';
14
15
  import { DEFAULTS, MDC_TEXT_OPTIONS } from './formfieldwrapper.constants';
16
+ import { BUTTON_VARIANTS } from '../button/button.constants';
15
17
  import styles from './formfieldwrapper.styles';
16
18
  import { getHelperIcon } from './formfieldwrapper.utils';
17
19
  /**
@@ -21,7 +23,11 @@ import { getHelperIcon } from './formfieldwrapper.utils';
21
23
  *
22
24
  * @tagname mdc-formfieldwrapper
23
25
  *
24
- * @slot label-info - slot to add the label info icon
26
+ * @dependency mdc-text
27
+ * @dependency mdc-icon
28
+ * @dependency mdc-button
29
+ * @dependency mdc-toggletip
30
+ *
25
31
  *
26
32
  */
27
33
  class FormfieldWrapper extends DisabledMixin(Component) {
@@ -42,6 +48,11 @@ class FormfieldWrapper extends DisabledMixin(Component) {
42
48
  * The type of help text. It can be 'default', 'error', 'warning', 'success', 'priority'.
43
49
  */
44
50
  this.helpTextType = DEFAULTS.VALIDATION;
51
+ /**
52
+ * The placement of the toggletip that is displayed when the info icon is hovered.
53
+ * @default 'top'
54
+ */
55
+ this.toggletipPlacement = DEFAULTS.TOGGLETIP_PLACEMENT;
45
56
  /** @internal */
46
57
  this.shouldRenderLabel = true;
47
58
  }
@@ -109,7 +120,22 @@ class FormfieldWrapper extends DisabledMixin(Component) {
109
120
  return html `<div class="mdc-label-text" part="label-text">
110
121
  <slot name="label">${this.renderLabelElement()}</slot>
111
122
  ${this.required ? html `<span part="required-indicator">*</span>` : nothing}
112
- <slot name="label-info"></slot>
123
+ ${this.toggletipText ? html `
124
+ <mdc-button
125
+ part="info-icon-btn"
126
+ prefix-icon="${DEFAULTS.INFO_ICON}"
127
+ size="${DEFAULTS.ICON_SIZE}"
128
+ variant="${BUTTON_VARIANTS.TERTIARY}"
129
+ aria-label="${ifDefined(this.infoIconAriaLabel)}"
130
+ id="info-icon-id"></mdc-button>
131
+ <mdc-toggletip
132
+ part="label-toggletip"
133
+ triggerid="info-icon-id"
134
+ id="label-toggletip-id"
135
+ placement="${this.toggletipPlacement}"
136
+ show-arrow
137
+ >${this.toggletipText}</mdc-toggletip
138
+ >` : nothing}
113
139
  </div>`;
114
140
  }
115
141
  /**
@@ -147,4 +173,16 @@ __decorate([
147
173
  property({ type: String, reflect: true, attribute: 'help-text' }),
148
174
  __metadata("design:type", String)
149
175
  ], FormfieldWrapper.prototype, "helpText", void 0);
176
+ __decorate([
177
+ property({ type: String, reflect: true, attribute: 'toggletip-text' }),
178
+ __metadata("design:type", String)
179
+ ], FormfieldWrapper.prototype, "toggletipText", void 0);
180
+ __decorate([
181
+ property({ type: String, reflect: true, attribute: 'toggletip-placement' }),
182
+ __metadata("design:type", String)
183
+ ], FormfieldWrapper.prototype, "toggletipPlacement", void 0);
184
+ __decorate([
185
+ property({ type: String, reflect: true, attribute: 'info-icon-aria-label' }),
186
+ __metadata("design:type", String)
187
+ ], FormfieldWrapper.prototype, "infoIconAriaLabel", void 0);
150
188
  export default FormfieldWrapper;
@@ -10,6 +10,9 @@ declare const DEFAULTS: {
10
10
  readonly VALIDATION: "default";
11
11
  readonly HELPER_TEXT_ID: "helper-text-id";
12
12
  readonly HEADING_ID: "heading-id";
13
+ readonly ICON_SIZE: 20;
14
+ readonly INFO_ICON: "info-badge-filled";
15
+ readonly TOGGLETIP_PLACEMENT: "top";
13
16
  };
14
17
  declare const MDC_TEXT_OPTIONS: {
15
18
  TAGNAME: "span";
@@ -12,6 +12,9 @@ const DEFAULTS = {
12
12
  VALIDATION: VALIDATION.DEFAULT,
13
13
  HELPER_TEXT_ID: 'helper-text-id',
14
14
  HEADING_ID: 'heading-id',
15
+ ICON_SIZE: 20,
16
+ INFO_ICON: 'info-badge-filled',
17
+ TOGGLETIP_PLACEMENT: 'top',
15
18
  };
16
19
  const MDC_TEXT_OPTIONS = {
17
20
  TAGNAME: VALID_TEXT_TAGS.SPAN,
@@ -1,6 +1,8 @@
1
- import FormfieldWrapper from './formfieldwrapper.component';
1
+ import '../button';
2
2
  import '../icon';
3
3
  import '../text';
4
+ import '../toggletip';
5
+ import FormfieldWrapper from './formfieldwrapper.component';
4
6
  declare global {
5
7
  interface HTMLElementTagNameMap {
6
8
  ['mdc-formfieldwrapper']: FormfieldWrapper;
@@ -1,6 +1,8 @@
1
- import FormfieldWrapper from './formfieldwrapper.component';
2
- import { TAG_NAME } from './formfieldwrapper.constants';
1
+ import '../button';
3
2
  import '../icon';
4
3
  import '../text';
4
+ import '../toggletip';
5
+ import FormfieldWrapper from './formfieldwrapper.component';
6
+ import { TAG_NAME } from './formfieldwrapper.constants';
5
7
  FormfieldWrapper.register(TAG_NAME);
6
8
  export default FormfieldWrapper;
@@ -1,7 +1,8 @@
1
- import Input from './input.component';
2
1
  import '../button';
3
2
  import '../icon';
4
3
  import '../text';
4
+ import '../toggletip';
5
+ import Input from './input.component';
5
6
  declare global {
6
7
  interface HTMLElementTagNameMap {
7
8
  ['mdc-input']: Input;
@@ -1,7 +1,8 @@
1
- import Input from './input.component';
2
- import { TAG_NAME } from './input.constants';
3
1
  import '../button';
4
2
  import '../icon';
5
3
  import '../text';
4
+ import '../toggletip';
5
+ import Input from './input.component';
6
+ import { TAG_NAME } from './input.constants';
6
7
  Input.register(TAG_NAME);
7
8
  export default Input;
@@ -26,6 +26,7 @@ declare const Input_base: import("../../utils/mixins/index.types").Constructor<i
26
26
  * @dependency mdc-icon
27
27
  * @dependency mdc-text
28
28
  * @dependency mdc-button
29
+ * @dependency mdc-toggletip
29
30
  *
30
31
  * @cssproperty --mdc-input-disabled-border-color - Border color for the input container when disabled
31
32
  * @cssproperty --mdc-input-disabled-text-color - Text color for the input field when disabled
@@ -38,6 +38,7 @@ import { FormInternalsMixin } from '../../utils/mixins/FormInternalsMixin';
38
38
  * @dependency mdc-icon
39
39
  * @dependency mdc-text
40
40
  * @dependency mdc-button
41
+ * @dependency mdc-toggletip
41
42
  *
42
43
  * @cssproperty --mdc-input-disabled-border-color - Border color for the input container when disabled
43
44
  * @cssproperty --mdc-input-disabled-text-color - Text color for the input field when disabled
@@ -23,7 +23,7 @@ declare const DEFAULTS: {
23
23
  VALIDATION: "default";
24
24
  ICON_SIZE_VALUE: number;
25
25
  ICON_SIZE_UNIT: string;
26
- CLEAR_BUTTON_ICON: string;
26
+ CLEAR_BUTTON_ICON: "cancel-bold";
27
27
  CLEAR_BUTTON_VARIANT: "tertiary";
28
28
  CLEAR_BUTTON_SIZE: 20;
29
29
  PREFIX_TEXT_TYPE: "body-midsize-regular";
@@ -163,7 +163,7 @@ declare class Popover extends Popover_base {
163
163
  * Element ID that the popover append to.
164
164
  * @default ''
165
165
  */
166
- appendTo: string;
166
+ appendTo?: string;
167
167
  /**
168
168
  * aria-label attribute to be set for close button accessibility.
169
169
  * @default null
@@ -177,11 +177,6 @@ class Popover extends FocusTrapMixin(Component) {
177
177
  * @default 1000
178
178
  */
179
179
  this.zIndex = DEFAULTS.Z_INDEX;
180
- /**
181
- * Element ID that the popover append to.
182
- * @default ''
183
- */
184
- this.appendTo = '';
185
180
  /**
186
181
  * aria-label attribute to be set for close button accessibility.
187
182
  * @default null
@@ -512,8 +507,9 @@ class Popover extends FocusTrapMixin(Component) {
512
507
  async handleCreatePopoverFirstUpdate() {
513
508
  var _a, _b;
514
509
  if (this.visible && this.interactive) {
515
- (_a = this.setFocusableElements) === null || _a === void 0 ? void 0 : _a.call(this);
510
+ // Wait for the first update to complete before setting focusable elements
516
511
  await this.updateComplete;
512
+ (_a = this.setFocusableElements) === null || _a === void 0 ? void 0 : _a.call(this);
517
513
  (_b = this.setInitialFocus) === null || _b === void 0 ? void 0 : _b.call(this);
518
514
  }
519
515
  }
@@ -95,6 +95,8 @@ class Progressbar extends DataAriaLabelMixin(FormfieldWrapper) {
95
95
  super.connectedCallback();
96
96
  this.id = `mdc-progressbar-${uuidv4()}`;
97
97
  this.disabled = undefined;
98
+ this.toggletipText = undefined;
99
+ this.toggletipPlacement = undefined;
98
100
  }
99
101
  /**
100
102
  * Ensures that the value is clamped between 0 and 100
@@ -1,5 +1,9 @@
1
- import Radio from './radio.component';
1
+ import '../button';
2
+ import '../icon';
2
3
  import '../staticradio';
4
+ import '../text';
5
+ import '../tooltip';
6
+ import Radio from './radio.component';
3
7
  declare global {
4
8
  interface HTMLElementTagNameMap {
5
9
  ['mdc-radio']: Radio;
@@ -1,5 +1,9 @@
1
+ import '../button';
2
+ import '../icon';
3
+ import '../staticradio';
4
+ import '../text';
5
+ import '../tooltip';
1
6
  import Radio from './radio.component';
2
7
  import { TAG_NAME } from './radio.constants';
3
- import '../staticradio';
4
8
  Radio.register(TAG_NAME);
5
9
  export default Radio;
@@ -7,7 +7,12 @@ declare const Radio_base: import("../../utils/mixins/index.types").Constructor<i
7
7
  * These are often used in forms, settings, and selection in lists.
8
8
  *
9
9
  * A radio component contains an optional label, optional info icon and an optional helper text.
10
- * @dependency mdc-formfieldwrapper
10
+ *
11
+ * @dependency mdc-button
12
+ * @dependency mdc-icon
13
+ * @dependency mdc-text
14
+ * @dependency mdc-staticradio
15
+ * @dependency mdc-toggletip
11
16
  *
12
17
  * @tagname mdc-radio
13
18
  *
@@ -21,7 +21,12 @@ import { DEFAULTS as FORMFIELD_DEFAULTS } from '../formfieldwrapper/formfieldwra
21
21
  * These are often used in forms, settings, and selection in lists.
22
22
  *
23
23
  * A radio component contains an optional label, optional info icon and an optional helper text.
24
- * @dependency mdc-formfieldwrapper
24
+ *
25
+ * @dependency mdc-button
26
+ * @dependency mdc-icon
27
+ * @dependency mdc-text
28
+ * @dependency mdc-staticradio
29
+ * @dependency mdc-toggletip
25
30
  *
26
31
  * @tagname mdc-radio
27
32
  *
@@ -1,6 +1,8 @@
1
+ import '../button';
1
2
  import '../icon';
2
3
  import '../popover';
3
4
  import '../text';
5
+ import '../toggletip';
4
6
  import Select from './select.component';
5
7
  declare global {
6
8
  interface HTMLElementTagNameMap {
@@ -1,6 +1,8 @@
1
+ import '../button';
1
2
  import '../icon';
2
3
  import '../popover';
3
4
  import '../text';
5
+ import '../toggletip';
4
6
  import Select from './select.component';
5
7
  import { TAG_NAME } from './select.constants';
6
8
  Select.register(TAG_NAME);
@@ -10,9 +10,11 @@ declare const Select_base: import("../../utils/mixins/index.types").Constructor<
10
10
  * The component ensures accessibility and usability while handling various use cases,
11
11
  * including long text truncation with tooltip support.
12
12
  *
13
+ * @dependency mdc-button
13
14
  * @dependency mdc-icon
14
15
  * @dependency mdc-popover
15
16
  * @dependency mdc-text
17
+ * @dependency mdc-toggletip
16
18
  *
17
19
  * @tagname mdc-select
18
20
  *
@@ -61,7 +63,6 @@ declare class Select extends Select_base implements AssociatedFormControl {
61
63
  */
62
64
  inputElement: HTMLInputElement;
63
65
  connectedCallback(): void;
64
- disconnectedCallback(): void;
65
66
  /**
66
67
  * A helper function which returns a flattened array of all valid options from the assigned slot.
67
68
  * It takes care of the edge cases where the option is either a direct child or a