@momentum-design/components 0.120.1 → 0.120.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 (79) hide show
  1. package/dist/browser/index.js +71 -70
  2. package/dist/browser/index.js.map +2 -2
  3. package/dist/components/checkbox/checkbox.component.d.ts +11 -0
  4. package/dist/components/checkbox/checkbox.component.js +11 -0
  5. package/dist/components/combobox/combobox.component.d.ts +9 -1
  6. package/dist/components/combobox/combobox.component.js +10 -3
  7. package/dist/components/combobox/combobox.styles.js +1 -1
  8. package/dist/components/formfieldgroup/formfieldgroup.component.d.ts +11 -0
  9. package/dist/components/formfieldgroup/formfieldgroup.component.js +11 -0
  10. package/dist/components/formfieldwrapper/formfieldwrapper.component.d.ts +9 -0
  11. package/dist/components/formfieldwrapper/formfieldwrapper.component.js +9 -0
  12. package/dist/components/input/input.component.d.ts +14 -0
  13. package/dist/components/input/input.component.js +18 -6
  14. package/dist/components/input/input.styles.js +32 -32
  15. package/dist/components/password/password.component.d.ts +12 -0
  16. package/dist/components/password/password.component.js +12 -0
  17. package/dist/components/popover/popover.component.js +2 -2
  18. package/dist/components/popover/popover.portal.component.js +1 -0
  19. package/dist/components/popover/popover.styles.js +1 -1
  20. package/dist/components/progressbar/progressbar.component.d.ts +6 -0
  21. package/dist/components/progressbar/progressbar.component.js +6 -0
  22. package/dist/components/radio/radio.component.d.ts +10 -0
  23. package/dist/components/radio/radio.component.js +10 -0
  24. package/dist/components/searchfield/searchfield.component.d.ts +8 -0
  25. package/dist/components/searchfield/searchfield.component.js +8 -1
  26. package/dist/components/select/select.component.d.ts +15 -0
  27. package/dist/components/select/select.component.js +15 -0
  28. package/dist/components/staticcheckbox/staticcheckbox.component.d.ts +3 -0
  29. package/dist/components/staticcheckbox/staticcheckbox.component.js +4 -1
  30. package/dist/components/staticcheckbox/staticcheckbox.styles.js +4 -3
  31. package/dist/components/staticradio/staticradio.component.d.ts +4 -0
  32. package/dist/components/staticradio/staticradio.component.js +5 -1
  33. package/dist/components/staticradio/staticradio.styles.js +13 -13
  34. package/dist/components/statictoggle/statictoggle.component.d.ts +5 -0
  35. package/dist/components/statictoggle/statictoggle.component.js +6 -1
  36. package/dist/components/statictoggle/statictoggle.styles.js +7 -4
  37. package/dist/components/textarea/textarea.component.d.ts +11 -0
  38. package/dist/components/textarea/textarea.component.js +11 -0
  39. package/dist/components/toast/toast.component.d.ts +1 -0
  40. package/dist/components/toast/toast.component.js +2 -1
  41. package/dist/components/toast/toast.styles.js +1 -1
  42. package/dist/components/toggle/toggle.component.d.ts +11 -0
  43. package/dist/components/toggle/toggle.component.js +11 -0
  44. package/dist/custom-elements.json +7324 -6196
  45. package/dist/react/checkbox/index.d.ts +11 -0
  46. package/dist/react/checkbox/index.js +11 -0
  47. package/dist/react/combobox/index.d.ts +9 -1
  48. package/dist/react/combobox/index.js +9 -1
  49. package/dist/react/formfieldgroup/index.d.ts +11 -0
  50. package/dist/react/formfieldgroup/index.js +11 -0
  51. package/dist/react/formfieldwrapper/index.d.ts +9 -0
  52. package/dist/react/formfieldwrapper/index.js +9 -0
  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 +14 -0
  56. package/dist/react/input/index.js +14 -0
  57. package/dist/react/password/index.d.ts +12 -0
  58. package/dist/react/password/index.js +12 -0
  59. package/dist/react/progressbar/index.d.ts +6 -0
  60. package/dist/react/progressbar/index.js +6 -0
  61. package/dist/react/radio/index.d.ts +10 -0
  62. package/dist/react/radio/index.js +10 -0
  63. package/dist/react/searchfield/index.d.ts +8 -0
  64. package/dist/react/searchfield/index.js +8 -0
  65. package/dist/react/select/index.d.ts +15 -0
  66. package/dist/react/select/index.js +15 -0
  67. package/dist/react/staticcheckbox/index.d.ts +3 -0
  68. package/dist/react/staticcheckbox/index.js +3 -0
  69. package/dist/react/staticradio/index.d.ts +4 -0
  70. package/dist/react/staticradio/index.js +4 -0
  71. package/dist/react/statictoggle/index.d.ts +5 -0
  72. package/dist/react/statictoggle/index.js +5 -0
  73. package/dist/react/textarea/index.d.ts +11 -0
  74. package/dist/react/textarea/index.js +11 -0
  75. package/dist/react/toast/index.d.ts +1 -0
  76. package/dist/react/toast/index.js +1 -0
  77. package/dist/react/toggle/index.d.ts +11 -0
  78. package/dist/react/toggle/index.js +11 -0
  79. package/package.json +1 -1
@@ -31,6 +31,17 @@ declare const Checkbox_base: import("../../utils/mixins/index.types").Constructo
31
31
  * @slot toggletip - Slot for the toggletip info icon button. If not provided, the `toggletip-text` property will be used to render the info icon button and toggletip.
32
32
  * @slot help-icon - Slot for the helper/validation icon. If not provided, the icon will be rendered based on the `helpTextType` property.
33
33
  * @slot help-text - Slot for the helper/validation text. If not provided, the `helpText` property will be used to render the helper/validation text.
34
+ *
35
+ * @csspart label - The label element.
36
+ * @csspart label-text - The container for the label and required indicator elements.
37
+ * @csspart required-indicator - The required indicator element that is displayed next to the label when the `required` property is set to true.
38
+ * @csspart info-icon-btn - The info icon button element that is displayed next to the label when the `toggletip-text` property is set.
39
+ * @csspart label-toggletip - The toggletip element that is displayed when the info icon button is clicked.
40
+ * @csspart help-text - The helper/validation text element.
41
+ * @csspart helper-icon - The helper/validation icon element that is displayed next to the helper/validation text.
42
+ * @csspart help-text-container - The container for the helper/validation icon and text elements.
43
+ * @csspart checkbox-input - The native checkbox input element.
44
+ * @csspart text-container - The container for the label and helper text elements.
34
45
  */
35
46
  declare class Checkbox extends Checkbox_base implements AssociatedFormControl {
36
47
  /**
@@ -46,6 +46,17 @@ import styles from './checkbox.styles';
46
46
  * @slot toggletip - Slot for the toggletip info icon button. If not provided, the `toggletip-text` property will be used to render the info icon button and toggletip.
47
47
  * @slot help-icon - Slot for the helper/validation icon. If not provided, the icon will be rendered based on the `helpTextType` property.
48
48
  * @slot help-text - Slot for the helper/validation text. If not provided, the `helpText` property will be used to render the helper/validation text.
49
+ *
50
+ * @csspart label - The label element.
51
+ * @csspart label-text - The container for the label and required indicator elements.
52
+ * @csspart required-indicator - The required indicator element that is displayed next to the label when the `required` property is set to true.
53
+ * @csspart info-icon-btn - The info icon button element that is displayed next to the label when the `toggletip-text` property is set.
54
+ * @csspart label-toggletip - The toggletip element that is displayed when the info icon button is clicked.
55
+ * @csspart help-text - The helper/validation text element.
56
+ * @csspart helper-icon - The helper/validation icon element that is displayed next to the helper/validation text.
57
+ * @csspart help-text-container - The container for the helper/validation icon and text elements.
58
+ * @csspart checkbox-input - The native checkbox input element.
59
+ * @csspart text-container - The container for the label and helper text elements.
49
60
  */
50
61
  class Checkbox extends AutoFocusOnMountMixin(FormInternalsMixin(DataAriaLabelMixin(FormfieldWrapper))) {
51
62
  constructor() {
@@ -61,8 +61,16 @@ declare const Combobox_base: import("../../utils/mixins/index.types").Constructo
61
61
  * @cssproperty --mdc-combobox-text-color-disabled - The text color of the combobox when disabled
62
62
  * @cssproperty --mdc-combobox-focused-border-color - The border color of the combobox when focused
63
63
  *
64
+ * @csspart label - The label element.
65
+ * @csspart label-text - The container for the label and required indicator elements.
66
+ * @csspart required-indicator - The required indicator element that is displayed next to the label when the `required` property is set to true.
67
+ * @csspart info-icon-btn - The info icon button element that is displayed next to the label when the `toggletip-text` property is set.
68
+ * @csspart label-toggletip - The toggletip element that is displayed when the info icon button is clicked.
69
+ * @csspart help-text - The helper/validation text element.
70
+ * @csspart helper-icon - The helper/validation icon element that is displayed next to the helper/validation text.
71
+ * @csspart help-text-container - The container for the helper/validation icon and text elements.
64
72
  * @csspart internal-native-input - The internal native input element of the combobox.
65
- * @csspart mdc-input - The input element of the combobox.
73
+ * @csspart input-text - The input element of the combobox.
66
74
  * @csspart no-result-text - The no result text element of the combobox.
67
75
  * @csspart combobox__base - The base container element of the combobox.
68
76
  * @csspart combobox__button - The button element of the combobox.
@@ -87,8 +87,16 @@ import styles from './combobox.styles';
87
87
  * @cssproperty --mdc-combobox-text-color-disabled - The text color of the combobox when disabled
88
88
  * @cssproperty --mdc-combobox-focused-border-color - The border color of the combobox when focused
89
89
  *
90
+ * @csspart label - The label element.
91
+ * @csspart label-text - The container for the label and required indicator elements.
92
+ * @csspart required-indicator - The required indicator element that is displayed next to the label when the `required` property is set to true.
93
+ * @csspart info-icon-btn - The info icon button element that is displayed next to the label when the `toggletip-text` property is set.
94
+ * @csspart label-toggletip - The toggletip element that is displayed when the info icon button is clicked.
95
+ * @csspart help-text - The helper/validation text element.
96
+ * @csspart helper-icon - The helper/validation icon element that is displayed next to the helper/validation text.
97
+ * @csspart help-text-container - The container for the helper/validation icon and text elements.
90
98
  * @csspart internal-native-input - The internal native input element of the combobox.
91
- * @csspart mdc-input - The input element of the combobox.
99
+ * @csspart input-text - The input element of the combobox.
92
100
  * @csspart no-result-text - The no result text element of the combobox.
93
101
  * @csspart combobox__base - The base container element of the combobox.
94
102
  * @csspart combobox__button - The button element of the combobox.
@@ -602,8 +610,7 @@ class Combobox extends CaptureDestroyEventForChildElement(AutoFocusOnMountMixin(
602
610
  ?disabled="${this.disabled}"
603
611
  .value="${live(this.filteredValue)}"
604
612
  autocomplete="${AUTO_COMPLETE.OFF}"
605
- class="input"
606
- part="mdc-input"
613
+ part="input-text"
607
614
  placeholder="${ifDefined(this.placeholder)}"
608
615
  role="${ROLE.COMBOBOX}"
609
616
  ?readonly="${this.readonly}"
@@ -74,7 +74,7 @@ const styles = css `
74
74
  :host([disabled])::part(combobox__button) {
75
75
  border-left: 1px solid var(--mdc-combobox-text-color-disabled);
76
76
  }
77
- :host::part(mdc-input) {
77
+ :host::part(input-text) {
78
78
  width: calc(100% - 1.5rem);
79
79
  }
80
80
  :host::part(combobox__button-icon) {
@@ -29,6 +29,17 @@ declare const FormfieldGroup_base: import("../../utils/mixins/index.types").Cons
29
29
  * @slot toggletip - Slot for the toggletip info icon button. If not provided, the `toggletip-text` property will be used to render the info icon button and toggletip.
30
30
  * @slot help-icon - Slot for the helper/validation icon. If not provided, the icon will be rendered based on the `helpTextType` property.
31
31
  * @slot help-text - Slot for the helper/validation text. If not provided, the `helpText` property will be used to render the helper/validation text.
32
+ *
33
+ * @csspart label - The label element.
34
+ * @csspart label-text - The container for the label and required indicator elements.
35
+ * @csspart required-indicator - The required indicator element that is displayed next to the label when the `required` property is set to true.
36
+ * @csspart info-icon-btn - The info icon button element that is displayed next to the label when the `toggletip-text` property is set.
37
+ * @csspart label-toggletip - The toggletip element that is displayed when the info icon button is clicked.
38
+ * @csspart help-text - The helper/validation text element.
39
+ * @csspart helper-icon - The helper/validation icon element that is displayed next to the helper/validation text.
40
+ * @csspart help-text-container - The container for the helper/validation icon and text elements.
41
+ * @csspart container - Formfieldgroup host container
42
+ * @csspart group-header - This contains the label and help text for the group
32
43
  */
33
44
  declare class FormfieldGroup extends FormfieldGroup_base {
34
45
  /**
@@ -33,6 +33,17 @@ import styles from './formfieldgroup.styles';
33
33
  * @slot toggletip - Slot for the toggletip info icon button. If not provided, the `toggletip-text` property will be used to render the info icon button and toggletip.
34
34
  * @slot help-icon - Slot for the helper/validation icon. If not provided, the icon will be rendered based on the `helpTextType` property.
35
35
  * @slot help-text - Slot for the helper/validation text. If not provided, the `helpText` property will be used to render the helper/validation text.
36
+ *
37
+ * @csspart label - The label element.
38
+ * @csspart label-text - The container for the label and required indicator elements.
39
+ * @csspart required-indicator - The required indicator element that is displayed next to the label when the `required` property is set to true.
40
+ * @csspart info-icon-btn - The info icon button element that is displayed next to the label when the `toggletip-text` property is set.
41
+ * @csspart label-toggletip - The toggletip element that is displayed when the info icon button is clicked.
42
+ * @csspart help-text - The helper/validation text element.
43
+ * @csspart helper-icon - The helper/validation icon element that is displayed next to the helper/validation text.
44
+ * @csspart help-text-container - The container for the helper/validation icon and text elements.
45
+ * @csspart container - Formfieldgroup host container
46
+ * @csspart group-header - This contains the label and help text for the group
36
47
  */
37
48
  class FormfieldGroup extends DataAriaLabelMixin(FormfieldWrapper) {
38
49
  constructor() {
@@ -19,6 +19,15 @@ declare const FormfieldWrapper_base: import("../../utils/mixins/index.types").Co
19
19
  * @slot toggletip - Slot for the toggletip info icon button. If not provided, the `toggletip-text` property will be used to render the info icon button and toggletip.
20
20
  * @slot help-icon - Slot for the helper/validation icon. If not provided, the icon will be rendered based on the `helpTextType` property.
21
21
  * @slot help-text - Slot for the helper/validation text. If not provided, the `helpText` property will be used to render the helper/validation text.
22
+ *
23
+ * @csspart label - The label element.
24
+ * @csspart label-text - The container for the label and required indicator elements.
25
+ * @csspart required-indicator - The required indicator element that is displayed next to the label when the `required` property is set to true.
26
+ * @csspart info-icon-btn - The info icon button element that is displayed next to the label when the `toggletip-text` property is set.
27
+ * @csspart label-toggletip - The toggletip element that is displayed when the info icon button is clicked.
28
+ * @csspart help-text - The helper/validation text element.
29
+ * @csspart helper-icon - The helper/validation icon element that is displayed next to the helper/validation text.
30
+ * @csspart help-text-container - The container for the helper/validation icon and text elements.
22
31
  */
23
32
  declare class FormfieldWrapper extends FormfieldWrapper_base {
24
33
  /**
@@ -33,6 +33,15 @@ import { getHelperIcon } from './formfieldwrapper.utils';
33
33
  * @slot toggletip - Slot for the toggletip info icon button. If not provided, the `toggletip-text` property will be used to render the info icon button and toggletip.
34
34
  * @slot help-icon - Slot for the helper/validation icon. If not provided, the icon will be rendered based on the `helpTextType` property.
35
35
  * @slot help-text - Slot for the helper/validation text. If not provided, the `helpText` property will be used to render the helper/validation text.
36
+ *
37
+ * @csspart label - The label element.
38
+ * @csspart label-text - The container for the label and required indicator elements.
39
+ * @csspart required-indicator - The required indicator element that is displayed next to the label when the `required` property is set to true.
40
+ * @csspart info-icon-btn - The info icon button element that is displayed next to the label when the `toggletip-text` property is set.
41
+ * @csspart label-toggletip - The toggletip element that is displayed when the info icon button is clicked.
42
+ * @csspart help-text - The helper/validation text element.
43
+ * @csspart helper-icon - The helper/validation icon element that is displayed next to the helper/validation text.
44
+ * @csspart help-text-container - The container for the helper/validation icon and text elements.
36
45
  */
37
46
  class FormfieldWrapper extends DisabledMixin(Component) {
38
47
  constructor() {
@@ -55,6 +55,20 @@ declare const Input_base: import("../../utils/mixins/index.types").Constructor<i
55
55
  * @cssproperty --mdc-input-success-border-color - Border color for the input container when success
56
56
  * @cssproperty --mdc-input-primary-border-color - Border color for the input container when primary
57
57
  *
58
+ * @csspart label - The label element.
59
+ * @csspart label-text - The container for the label and required indicator elements.
60
+ * @csspart required-indicator - The required indicator element that is displayed next to the label when the `required` property is set to true.
61
+ * @csspart info-icon-btn - The info icon button element that is displayed next to the label when the `toggletip-text` property is set.
62
+ * @csspart label-toggletip - The toggletip element that is displayed when the info icon button is clicked.
63
+ * @csspart help-text - The helper/validation text element.
64
+ * @csspart helper-icon - The helper/validation icon element that is displayed next to the helper/validation text.
65
+ * @csspart help-text-container - The container for the helper/validation icon and text elements.
66
+ * @csspart leading-icon - The leading icon element that is displayed before the input field.
67
+ * @csspart prefix-text - The prefix text element that is displayed before the input field.
68
+ * @csspart input-container - The container for the input field, leading icon, prefix text, and trailing button elements.
69
+ * @csspart input-section - The container for the input field, leading icon, and prefix text elements.
70
+ * @csspart input-text - The input field element.
71
+ * @csspart trailing-button - The trailing button element that is displayed to clear the input field when the `trailingButton` property is set to true.
58
72
  */
59
73
  declare class Input extends Input_base implements AssociatedFormControl {
60
74
  /**
@@ -70,6 +70,20 @@ import styles from './input.styles';
70
70
  * @cssproperty --mdc-input-success-border-color - Border color for the input container when success
71
71
  * @cssproperty --mdc-input-primary-border-color - Border color for the input container when primary
72
72
  *
73
+ * @csspart label - The label element.
74
+ * @csspart label-text - The container for the label and required indicator elements.
75
+ * @csspart required-indicator - The required indicator element that is displayed next to the label when the `required` property is set to true.
76
+ * @csspart info-icon-btn - The info icon button element that is displayed next to the label when the `toggletip-text` property is set.
77
+ * @csspart label-toggletip - The toggletip element that is displayed when the info icon button is clicked.
78
+ * @csspart help-text - The helper/validation text element.
79
+ * @csspart helper-icon - The helper/validation icon element that is displayed next to the helper/validation text.
80
+ * @csspart help-text-container - The container for the helper/validation icon and text elements.
81
+ * @csspart leading-icon - The leading icon element that is displayed before the input field.
82
+ * @csspart prefix-text - The prefix text element that is displayed before the input field.
83
+ * @csspart input-container - The container for the input field, leading icon, prefix text, and trailing button elements.
84
+ * @csspart input-section - The container for the input field, leading icon, and prefix text elements.
85
+ * @csspart input-text - The input field element.
86
+ * @csspart trailing-button - The trailing button element that is displayed to clear the input field when the `trailingButton` property is set to true.
73
87
  */
74
88
  class Input extends AutoFocusOnMountMixin(FormInternalsMixin(DataAriaLabelMixin(FormfieldWrapper))) {
75
89
  constructor() {
@@ -225,7 +239,6 @@ class Input extends AutoFocusOnMountMixin(FormInternalsMixin(DataAriaLabelMixin(
225
239
  }
226
240
  return html `
227
241
  <mdc-icon
228
- class="leading-icon"
229
242
  part="leading-icon"
230
243
  name=${this.leadingIcon}
231
244
  size="${DEFAULTS.ICON_SIZE_VALUE}"
@@ -250,7 +263,7 @@ class Input extends AutoFocusOnMountMixin(FormInternalsMixin(DataAriaLabelMixin(
250
263
  }
251
264
  return html `
252
265
  <mdc-text
253
- class="prefix-text"
266
+ part="prefix-text"
254
267
  tagname="${DEFAULTS.PREFIX_TEXT_TAG}"
255
268
  type="${DEFAULTS.PREFIX_TEXT_TYPE}"
256
269
  aria-hidden="true"
@@ -296,8 +309,7 @@ class Input extends AutoFocusOnMountMixin(FormInternalsMixin(DataAriaLabelMixin(
296
309
  const placeholderText = hidePlaceholder ? '' : this.placeholder;
297
310
  return html `<input
298
311
  aria-label="${(_a = this.dataAriaLabel) !== null && _a !== void 0 ? _a : ''}"
299
- class="input"
300
- part="mdc-input"
312
+ part="input-text"
301
313
  id="${this.inputId}"
302
314
  name="${this.name}"
303
315
  .value="${live(this.value)}"
@@ -324,9 +336,9 @@ class Input extends AutoFocusOnMountMixin(FormInternalsMixin(DataAriaLabelMixin(
324
336
  render() {
325
337
  return html `
326
338
  ${this.renderLabel()}
327
- <div class="input-container mdc-focus-ring" part="input-container">
339
+ <div class="mdc-focus-ring" part="input-container">
328
340
  <slot name="input-leading-icon">${this.renderLeadingIcon()}</slot>
329
- <div class="input-section" part="input-section">
341
+ <div part="input-section">
330
342
  <slot name="input-prefix-text">${this.renderPrefixText()}</slot>
331
343
  <slot name="input">${this.renderInputElement(DEFAULTS.INPUT_TYPE)}</slot>
332
344
  </div>
@@ -21,9 +21,9 @@ const styles = [
21
21
  --mdc-input-primary-border-color: var(--mds-color-theme-text-accent-normal);
22
22
  }
23
23
  :host,
24
- .input-container,
25
- .input-section,
26
- .input {
24
+ :host::part(input-container),
25
+ :host::part(input-section),
26
+ :host::part(input-text) {
27
27
  width: 100%;
28
28
  }
29
29
 
@@ -31,42 +31,42 @@ const styles = [
31
31
  font-family: inherit;
32
32
  }
33
33
 
34
- :host .input-container:hover {
34
+ :host::part(input-container):hover {
35
35
  background-color: var(--mdc-input-hover-background-color);
36
36
  }
37
37
 
38
- :host .input-container:active,
39
- :host .input-container:focus-within {
38
+ :host::part(input-container):active,
39
+ :host::part(input-container):focus-within {
40
40
  background-color: var(--mdc-input-focused-background-color);
41
41
  border-color: var(--mdc-input-focused-border-color);
42
42
  }
43
43
 
44
- :host([readonly]) .leading-icon {
44
+ :host([readonly])::part(leading-icon) {
45
45
  color: var(--mdc-input-support-text-color);
46
46
  }
47
47
 
48
- :host([disabled]) .input,
49
- :host([disabled]) .input::placeholder,
50
- :host([disabled]) .prefix-text {
48
+ :host([disabled])::part(input-text),
49
+ :host([disabled]) input::placeholder,
50
+ :host([disabled])::part(prefix-text) {
51
51
  color: var(--mdc-input-disabled-text-color);
52
52
  }
53
53
 
54
- :host([disabled]) .input-container,
55
- :host([readonly]) .input-container,
56
- :host([disabled][help-text-type='default']) .input-container,
57
- :host([disabled][help-text-type='success']) .input-container,
58
- :host([disabled][help-text-type='warning']) .input-container,
59
- :host([disabled][help-text-type='error']) .input-container,
60
- :host([disabled][help-text-type='priority']) .input-container {
54
+ :host([disabled])::part(input-container),
55
+ :host([readonly])::part(input-container),
56
+ :host([disabled][help-text-type='default'])::part(input-container),
57
+ :host([disabled][help-text-type='success'])::part(input-container),
58
+ :host([disabled][help-text-type='warning'])::part(input-container),
59
+ :host([disabled][help-text-type='error'])::part(input-container),
60
+ :host([disabled][help-text-type='priority'])::part(input-container) {
61
61
  border-color: var(--mdc-input-disabled-border-color);
62
62
  background: var(--mdc-input-disabled-background-color);
63
63
  }
64
64
 
65
- .leading-icon {
65
+ :host::part(leading-icon) {
66
66
  aspect-ratio: 1;
67
67
  }
68
68
 
69
- .input-container {
69
+ :host::part(input-container) {
70
70
  height: 2rem;
71
71
  border-radius: 0.5rem;
72
72
  border: 0.0625rem solid var(--mdc-input-border-color);
@@ -77,46 +77,46 @@ const styles = [
77
77
  min-width: 3.25rem;
78
78
  }
79
79
 
80
- .input-section {
80
+ :host::part(input-section) {
81
81
  display: flex;
82
82
  gap: 0.25rem;
83
83
  }
84
84
 
85
- .input {
85
+ :host::part(input-text) {
86
86
  border: none;
87
87
  color: var(--mdc-input-text-color);
88
88
  background-color: var(--mdc-input-background-color);
89
89
  outline: none;
90
90
  }
91
91
 
92
- .input::selection {
92
+ input::selection {
93
93
  background-color: var(--mdc-input-selection-background-color);
94
94
  color: var(--mdc-input-selection-text-color);
95
95
  }
96
96
 
97
- .prefix-text {
97
+ :host::part(prefix-text) {
98
98
  color: var(--mdc-input-support-text-color);
99
99
  white-space: nowrap; /* restrict prefix text to be in one line */
100
100
  }
101
101
 
102
- .input::placeholder {
102
+ input::placeholder {
103
103
  color: var(--mdc-input-support-text-color);
104
104
  }
105
105
 
106
- :host([help-text-type='error']) .input-container,
107
- :host([help-text-type='error']) .input-container:focus-within {
106
+ :host([help-text-type='error'])::part(input-container),
107
+ :host([help-text-type='error'])::part(input-container):focus-within {
108
108
  border-color: var(--mdc-input-error-border-color);
109
109
  }
110
- :host([help-text-type='warning']) .input-container,
111
- :host([help-text-type='warning']) .input-container:focus-within {
110
+ :host([help-text-type='warning'])::part(input-container),
111
+ :host([help-text-type='warning'])::part(input-container):focus-within {
112
112
  border-color: var(--mdc-input-warning-border-color);
113
113
  }
114
- :host([help-text-type='success']) .input-container,
115
- :host([help-text-type='success']) .input-container:focus-within {
114
+ :host([help-text-type='success'])::part(input-container),
115
+ :host([help-text-type='success'])::part(input-container):focus-within {
116
116
  border-color: var(--mdc-input-success-border-color);
117
117
  }
118
- :host([help-text-type='priority']) .input-container,
119
- :host([help-text-type='priority']) input-container:focus-within {
118
+ :host([help-text-type='priority'])::part(input-container),
119
+ :host([help-text-type='priority'])::part(input-container):focus-within {
120
120
  border-color: var(--mdc-input-primary-border-color);
121
121
  }
122
122
 
@@ -42,6 +42,18 @@ import type { ValidationType } from '../formfieldwrapper/formfieldwrapper.types'
42
42
  * @cssproperty --mdc-input-success-border-color - Border color for the password container when success
43
43
  * @cssproperty --mdc-input-primary-border-color - Border color for the password container when primary
44
44
  *
45
+ * @csspart label - The label element.
46
+ * @csspart label-text - The container for the label and required indicator elements.
47
+ * @csspart required-indicator - The required indicator element that is displayed next to the label when the `required` property is set to true.
48
+ * @csspart info-icon-btn - The info icon button element that is displayed next to the label when the `toggletip-text` property is set.
49
+ * @csspart label-toggletip - The toggletip element that is displayed when the info icon button is clicked.
50
+ * @csspart help-text - The helper/validation text element.
51
+ * @csspart helper-icon - The helper/validation icon element that is displayed next to the helper/validation text.
52
+ * @csspart help-text-container - The container for the helper/validation icon and text elements.
53
+ * @csspart input-container - The container for the input field, leading icon, prefix text, and trailing button elements.
54
+ * @csspart input-section - The container for the input field, leading icon, and prefix text elements.
55
+ * @csspart input-text - The input field element.
56
+ * @csspart trailing-button - The trailing button element that is displayed to clear the input field when the `trailingButton` property is set to true.
45
57
  */
46
58
  declare class Password extends Input {
47
59
  /**
@@ -54,6 +54,18 @@ import { PASSWORD_VISIBILITY_ICONS } from './password.constants';
54
54
  * @cssproperty --mdc-input-success-border-color - Border color for the password container when success
55
55
  * @cssproperty --mdc-input-primary-border-color - Border color for the password container when primary
56
56
  *
57
+ * @csspart label - The label element.
58
+ * @csspart label-text - The container for the label and required indicator elements.
59
+ * @csspart required-indicator - The required indicator element that is displayed next to the label when the `required` property is set to true.
60
+ * @csspart info-icon-btn - The info icon button element that is displayed next to the label when the `toggletip-text` property is set.
61
+ * @csspart label-toggletip - The toggletip element that is displayed when the info icon button is clicked.
62
+ * @csspart help-text - The helper/validation text element.
63
+ * @csspart helper-icon - The helper/validation icon element that is displayed next to the helper/validation text.
64
+ * @csspart help-text-container - The container for the helper/validation icon and text elements.
65
+ * @csspart input-container - The container for the input field, leading icon, prefix text, and trailing button elements.
66
+ * @csspart input-section - The container for the input field, leading icon, and prefix text elements.
67
+ * @csspart input-text - The input field element.
68
+ * @csspart trailing-button - The trailing button element that is displayed to clear the input field when the `trailingButton` property is set to true.
57
69
  */
58
70
  class Password extends Input {
59
71
  constructor() {
@@ -635,7 +635,7 @@ class Popover extends BackdropMixin(PreventScrollMixin(FocusTrapMixin(Component)
635
635
  }));
636
636
  }
637
637
  if (this.showArrow) {
638
- this.arrowElement = this.renderRoot.querySelector('.popover-arrow');
638
+ this.arrowElement = this.renderRoot.querySelector('div[part="popover-arrow"]');
639
639
  if (this.arrowElement) {
640
640
  const arrowLen = this.arrowElement.offsetHeight;
641
641
  const arrowOffset = Math.sqrt(2 * arrowLen ** 2) / 2;
@@ -873,7 +873,7 @@ class Popover extends BackdropMixin(PreventScrollMixin(FocusTrapMixin(Component)
873
873
  @click="${this.hide}"
874
874
  ></mdc-button>`
875
875
  : nothing}
876
- ${this.showArrow ? html `<div class="popover-arrow"></div>` : nothing}
876
+ ${this.showArrow ? html `<div class="popover-arrow" part="popover-arrow"></div>` : nothing}
877
877
  <div part="popover-content">
878
878
  <slot></slot>
879
879
  </div>
@@ -24,6 +24,7 @@ export class PopoverPortal extends Component {
24
24
  super.connectedCallback();
25
25
  // We don't want the portal to be focusable or visible for screen readers
26
26
  this.ariaHidden = 'true';
27
+ this.style.display = 'none';
27
28
  }
28
29
  /**
29
30
  * When the portal removed from the DOM, we remove the popover from the container as well.
@@ -70,7 +70,7 @@ const styles = css `
70
70
  pointer-events: auto;
71
71
  }
72
72
 
73
- .popover-arrow {
73
+ :host::part(popover-arrow) {
74
74
  position: absolute;
75
75
  width: 1rem;
76
76
  height: 1rem;
@@ -29,6 +29,12 @@ declare const Progressbar_base: import("../../utils/mixins/index.types").Constru
29
29
  * @cssproperty --mdc-progressbar-label-font-weight - Font weight of the label text.
30
30
  * @cssproperty --mdc-progressbar-help-text-color - Color of the help text.
31
31
  *
32
+ * @csspart label - The label element.
33
+ * @csspart label-text - The container for the label and required indicator elements.
34
+ * @csspart info-icon-btn - The info icon button element that is displayed next to the label when the `toggletip-text` property is set.
35
+ * @csspart help-text - The helper/validation text element.
36
+ * @csspart helper-icon - The helper/validation icon element that is displayed next to the helper/validation text.
37
+ * @csspart help-text-container - The container for the helper/validation icon and text elements.
32
38
  * @csspart gap - The gap between the label and the progressbar.
33
39
  * @csspart inline-label-container - The container of the label in inline variant.
34
40
  * @csspart label-container - The container of the label in inline variant.
@@ -43,6 +43,12 @@ import styles from './progressbar.styles';
43
43
  * @cssproperty --mdc-progressbar-label-font-weight - Font weight of the label text.
44
44
  * @cssproperty --mdc-progressbar-help-text-color - Color of the help text.
45
45
  *
46
+ * @csspart label - The label element.
47
+ * @csspart label-text - The container for the label and required indicator elements.
48
+ * @csspart info-icon-btn - The info icon button element that is displayed next to the label when the `toggletip-text` property is set.
49
+ * @csspart help-text - The helper/validation text element.
50
+ * @csspart helper-icon - The helper/validation icon element that is displayed next to the helper/validation text.
51
+ * @csspart help-text-container - The container for the helper/validation icon and text elements.
46
52
  * @csspart gap - The gap between the label and the progressbar.
47
53
  * @csspart inline-label-container - The container of the label in inline variant.
48
54
  * @csspart label-container - The container of the label in inline variant.
@@ -28,6 +28,16 @@ declare const Radio_base: import("../../utils/mixins/index.types").Constructor<i
28
28
  * @cssproperty --mdc-radio-control-active-disabled-background - color of the radio button when active and disabled
29
29
  * @cssproperty --mdc-radio-control-inactive-disabled-background - color of the radio button when inactive and disabled
30
30
  *
31
+ * @csspart label - The label element.
32
+ * @csspart label-text - The container for the label and required indicator elements.
33
+ * @csspart required-indicator - The required indicator element that is displayed next to the label when the `required` property is set to true.
34
+ * @csspart info-icon-btn - The info icon button element that is displayed next to the label when the `toggletip-text` property is set.
35
+ * @csspart label-toggletip - The toggletip element that is displayed when the info icon button is clicked.
36
+ * @csspart help-text - The helper/validation text element.
37
+ * @csspart helper-icon - The helper/validation icon element that is displayed next to the helper/validation text.
38
+ * @csspart help-text-container - The container for the helper/validation icon and text elements.
39
+ * @csspart radio-input - The native radio input element.
40
+ * @csspart text-container - The container for the label and helper text elements.
31
41
  */
32
42
  declare class Radio extends Radio_base implements AssociatedFormControl {
33
43
  /**
@@ -45,6 +45,16 @@ import styles from './radio.styles';
45
45
  * @cssproperty --mdc-radio-control-active-disabled-background - color of the radio button when active and disabled
46
46
  * @cssproperty --mdc-radio-control-inactive-disabled-background - color of the radio button when inactive and disabled
47
47
  *
48
+ * @csspart label - The label element.
49
+ * @csspart label-text - The container for the label and required indicator elements.
50
+ * @csspart required-indicator - The required indicator element that is displayed next to the label when the `required` property is set to true.
51
+ * @csspart info-icon-btn - The info icon button element that is displayed next to the label when the `toggletip-text` property is set.
52
+ * @csspart label-toggletip - The toggletip element that is displayed when the info icon button is clicked.
53
+ * @csspart help-text - The helper/validation text element.
54
+ * @csspart helper-icon - The helper/validation icon element that is displayed next to the helper/validation text.
55
+ * @csspart help-text-container - The container for the helper/validation icon and text elements.
56
+ * @csspart radio-input - The native radio input element.
57
+ * @csspart text-container - The container for the label and helper text elements.
48
58
  */
49
59
  class Radio extends AutoFocusOnMountMixin(FormInternalsMixin(DataAriaLabelMixin(FormfieldWrapper))) {
50
60
  constructor() {
@@ -16,6 +16,14 @@ import Input from '../input/input.component';
16
16
  * @event clear - (React: onClear) This event is dispatched when the input text is cleared.
17
17
  *
18
18
  * @slot filters - Slot for input chips
19
+ *
20
+ * @csspart label - The label element.
21
+ * @csspart label-text - The container for the label and required indicator elements.
22
+ * @csspart leading-icon - The leading icon element that is displayed before the input field.
23
+ * @csspart input-container - The container for the input field, leading icon, prefix text, and trailing button elements.
24
+ * @csspart input-section - The container for the input field, leading icon, and prefix text elements.
25
+ * @csspart input-text - The input field element.
26
+ * @csspart trailing-button - The trailing button element that is displayed to clear the input field when the `trailingButton` property is set to true.
19
27
  */
20
28
  declare class Searchfield extends Input {
21
29
  inputChips?: Array<HTMLElement>;
@@ -30,6 +30,14 @@ import { DEFAULTS } from './searchfield.constants';
30
30
  * @event clear - (React: onClear) This event is dispatched when the input text is cleared.
31
31
  *
32
32
  * @slot filters - Slot for input chips
33
+ *
34
+ * @csspart label - The label element.
35
+ * @csspart label-text - The container for the label and required indicator elements.
36
+ * @csspart leading-icon - The leading icon element that is displayed before the input field.
37
+ * @csspart input-container - The container for the input field, leading icon, prefix text, and trailing button elements.
38
+ * @csspart input-section - The container for the input field, leading icon, and prefix text elements.
39
+ * @csspart input-text - The input field element.
40
+ * @csspart trailing-button - The trailing button element that is displayed to clear the input field when the `trailingButton` property is set to true.
33
41
  */
34
42
  class Searchfield extends Input {
35
43
  constructor() {
@@ -107,7 +115,6 @@ class Searchfield extends Input {
107
115
  ${this.renderLabelElement()}
108
116
  <div
109
117
  class="${classMap({
110
- 'input-container': true,
111
118
  'mdc-focus-ring': this.isInputFocused,
112
119
  })}"
113
120
  part="input-container"
@@ -50,6 +50,21 @@ declare const Select_base: import("../../utils/mixins/index.types").Constructor<
50
50
  * @cssproperty --mdc-select-width - The width of the select.
51
51
  * @cssproperty --mdc-select-listbox-height - The height of the listbox inside the select.
52
52
  * @cssproperty --mdc-select-listbox-width - The width of the listbox inside the select (default: `--mdc-select-width`).
53
+ *
54
+ * @csspart label - The label element.
55
+ * @csspart label-text - The container for the label and required indicator elements.
56
+ * @csspart required-indicator - The required indicator element that is displayed next to the label when the `required` property is set to true.
57
+ * @csspart info-icon-btn - The info icon button element that is displayed next to the label when the `toggletip-text` property is set.
58
+ * @csspart label-toggletip - The toggletip element that is displayed when the info icon button is clicked.
59
+ * @csspart help-text - The helper/validation text element.
60
+ * @csspart helper-icon - The helper/validation icon element that is displayed next to the helper/validation text.
61
+ * @csspart help-text-container - The container for the helper/validation icon and text elements.
62
+ * @csspart container - The container element that wraps the visual combobox and the dropdown icon.
63
+ * @csspart base-container - The container element that wraps the visual combobox, dropdown icon, and the popover.
64
+ * @csspart selected-icon - The icon element that is displayed next to the selected option in the dropdown list.
65
+ * @csspart base-text - The text element that displays the selected option or placeholder in the visual combobox.
66
+ * @csspart icon-container - The container element that wraps the dropdown icon.
67
+ * @csspart native-input - The native hidden input element.
53
68
  */
54
69
  declare class Select extends Select_base implements AssociatedFormControl {
55
70
  /**
@@ -70,6 +70,21 @@ import styles from './select.styles';
70
70
  * @cssproperty --mdc-select-width - The width of the select.
71
71
  * @cssproperty --mdc-select-listbox-height - The height of the listbox inside the select.
72
72
  * @cssproperty --mdc-select-listbox-width - The width of the listbox inside the select (default: `--mdc-select-width`).
73
+ *
74
+ * @csspart label - The label element.
75
+ * @csspart label-text - The container for the label and required indicator elements.
76
+ * @csspart required-indicator - The required indicator element that is displayed next to the label when the `required` property is set to true.
77
+ * @csspart info-icon-btn - The info icon button element that is displayed next to the label when the `toggletip-text` property is set.
78
+ * @csspart label-toggletip - The toggletip element that is displayed when the info icon button is clicked.
79
+ * @csspart help-text - The helper/validation text element.
80
+ * @csspart helper-icon - The helper/validation icon element that is displayed next to the helper/validation text.
81
+ * @csspart help-text-container - The container for the helper/validation icon and text elements.
82
+ * @csspart container - The container element that wraps the visual combobox and the dropdown icon.
83
+ * @csspart base-container - The container element that wraps the visual combobox, dropdown icon, and the popover.
84
+ * @csspart selected-icon - The icon element that is displayed next to the selected option in the dropdown list.
85
+ * @csspart base-text - The text element that displays the selected option or placeholder in the visual combobox.
86
+ * @csspart icon-container - The container element that wraps the dropdown icon.
87
+ * @csspart native-input - The native hidden input element.
73
88
  */
74
89
  class Select extends ListNavigationMixin(CaptureDestroyEventForChildElement(AutoFocusOnMountMixin(FormInternalsMixin(DataAriaLabelMixin(FormfieldWrapper))))) {
75
90
  constructor() {
@@ -23,6 +23,9 @@ declare const StaticCheckbox_base: import("../../utils/mixins/index.types").Cons
23
23
  * @cssproperty --mdc-staticcheckbox-icon-color - Icon color for an unselected checkbox.
24
24
  *
25
25
  * @csspart icon-container - The container for the checkbox icon.
26
+ * @csspart checkbox-icon - The checkbox icon.
27
+ *
28
+ * @slot - Default slot for adding label text.
26
29
  */
27
30
  declare class StaticCheckbox extends StaticCheckbox_base {
28
31
  /**