lightning-base-components 1.18.1-alpha → 1.18.2-alpha
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.
- package/metadata/raptor.json +5 -0
- package/package.json +43 -1
- package/scopedImports/@salesforce-internal-core.appVersion.js +1 -1
- package/src/lightning/accordion/accordion.css +12 -0
- package/src/lightning/accordion/accordion.html +3 -1
- package/src/lightning/accordion/accordion.js +4 -2
- package/src/lightning/accordion/accordion.slds.css +671 -0
- package/src/lightning/accordionSection/accordion-section.slds.css +647 -0
- package/src/lightning/accordionSection/accordionSection.css +14 -0
- package/src/lightning/accordionSection/accordionSection.html +23 -19
- package/src/lightning/accordionSection/accordionSection.js +29 -2
- package/src/lightning/ariaObserver/__docs__/ariaObserver.md +21 -9
- package/src/lightning/ariaObserver/ariaObserver.js +185 -154
- package/src/lightning/ariaObserver/polyfill.js +639 -0
- package/src/lightning/avatar/avatar.css +2 -0
- package/src/lightning/avatar/avatar.html +2 -0
- package/src/lightning/avatar/avatar.js +18 -15
- package/src/lightning/avatar/avatar.slds.css +272 -0
- package/src/lightning/baseCombobox/base-combobox.slds.css +1585 -0
- package/src/lightning/baseCombobox/baseCombobox.css +11 -1
- package/src/lightning/baseCombobox/baseCombobox.html +154 -146
- package/src/lightning/baseCombobox/baseCombobox.js +82 -46
- package/src/lightning/baseCombobox/spinner.slds.css +438 -0
- package/src/lightning/baseComboboxItem/baseComboboxItem.js +4 -2
- package/src/lightning/baseComboboxItem/inline.css +2 -0
- package/src/lightning/breadcrumb/breadcrumb.css +2 -2
- package/src/lightning/breadcrumb/breadcrumb.js +4 -2
- package/src/lightning/breadcrumb/breadcrumb.slds.css +2 -7
- package/src/lightning/breadcrumbs/breadcrumbs.css +2 -2
- package/src/lightning/breadcrumbs/breadcrumbs.js +3 -2
- package/src/lightning/breadcrumbs/breadcrumbs.slds.css +7 -1
- package/src/lightning/button/__examples__/inverse/inverse.css +8 -0
- package/src/lightning/button/__examples__/inverse/inverse.html +3 -2
- package/src/lightning/button/button.css +2 -0
- package/src/lightning/button/button.html +4 -2
- package/src/lightning/button/button.js +21 -0
- package/src/lightning/button/button.slds.css +527 -0
- package/src/lightning/buttonGroup/buttonGroup.css +2 -2
- package/src/lightning/buttonGroup/buttonGroup.js +3 -2
- package/src/lightning/buttonIcon/button-icon.slds.css +215 -453
- package/src/lightning/buttonIcon/buttonIcon.css +2 -2
- package/src/lightning/buttonIcon/buttonIcon.js +4 -0
- package/src/lightning/buttonIconStateful/button-icon-stateful.slds.css +215 -453
- package/src/lightning/buttonIconStateful/buttonIconStateful.css +2 -2
- package/src/lightning/buttonMenu/{dropdown.slds.css → button-menu.slds.css} +853 -217
- package/src/lightning/buttonMenu/buttonMenu.css +2 -2
- package/src/lightning/buttonMenu/buttonMenu.html +2 -2
- package/src/lightning/buttonMenu/buttonMenu.js +10 -14
- package/src/lightning/buttonStateful/button-stateful.slds.css +225 -457
- package/src/lightning/buttonStateful/buttonStateful.css +2 -2
- package/src/lightning/buttonStateful/buttonStateful.js +3 -2
- package/src/lightning/calendar/__examples__/basic/basic.html +7 -0
- package/src/lightning/calendar/__examples__/basic/basic.js +3 -0
- package/src/lightning/calendar/calendar.css +3 -0
- package/src/lightning/calendar/calendar.html +12 -9
- package/src/lightning/calendar/calendar.js +15 -1
- package/src/lightning/calendar/calendar.slds.css +2048 -0
- package/src/lightning/card/card.css +2 -2
- package/src/lightning/card/card.js +3 -2
- package/src/lightning/card/card.slds.css +141 -88
- package/src/lightning/colorPickerCustom/colorPickerCustom.css +2 -2
- package/src/lightning/colorPickerCustom/colorPickerCustom.js +3 -2
- package/src/lightning/colorPickerPanel/color-picker-panel.slds.css +11 -38
- package/src/lightning/colorPickerPanel/colorPickerPanel.css +3 -2
- package/src/lightning/colorPickerPanel/colorPickerPanel.js +4 -2
- package/src/lightning/colorPickerPanel/popover.slds.css +121 -0
- package/src/lightning/combobox/combobox.css +4 -0
- package/src/lightning/combobox/combobox.html +31 -29
- package/src/lightning/combobox/combobox.js +21 -4
- package/src/lightning/combobox/combobox.slds.css +13 -0
- package/src/lightning/combobox/form-element.slds.css +281 -0
- package/src/lightning/configProvider/defaultConfig.js +2 -1
- package/src/lightning/datepicker/datepicker.css +3 -0
- package/src/lightning/datepicker/datepicker.html +7 -4
- package/src/lightning/datepicker/datepicker.js +73 -19
- package/src/lightning/datepicker/form-element.slds.css +281 -0
- package/src/lightning/datepicker/input-text.slds.css +398 -0
- package/src/lightning/datetimepicker/datetimepicker.css +3 -0
- package/src/lightning/datetimepicker/datetimepicker.html +9 -3
- package/src/lightning/datetimepicker/datetimepicker.js +39 -35
- package/src/lightning/datetimepicker/form-element.slds.css +281 -0
- package/src/lightning/datetimepicker/input-text.slds.css +398 -0
- package/src/lightning/dualListbox/dualListbox.css +2 -2
- package/src/lightning/dualListbox/dualListbox.html +3 -3
- package/src/lightning/dualListbox/dualListbox.js +31 -6
- package/src/lightning/dualListbox/form-element.slds.css +83 -34
- package/src/lightning/dualListbox/keyboard.js +20 -1
- package/src/lightning/dynamicIcon/dynamicIcon.js +3 -2
- package/src/lightning/dynamicIcon/ellie.css +1 -1
- package/src/lightning/dynamicIcon/eq.css +1 -1
- package/src/lightning/dynamicIcon/score.css +1 -1
- package/src/lightning/dynamicIcon/strength.css +1 -1
- package/src/lightning/dynamicIcon/trend.css +1 -1
- package/src/lightning/dynamicIcon/waffle.css +1 -1
- package/src/lightning/formattedRichText/linkify.js +2 -2
- package/src/lightning/helptext/form-element.slds.css +83 -34
- package/src/lightning/helptext/help-text.slds.css +215 -453
- package/src/lightning/helptext/helptext.css +2 -2
- package/src/lightning/helptext/helptext.js +3 -2
- package/src/lightning/i18nCldrOptions/README.md +5 -0
- package/src/lightning/i18nService/README.md +5 -0
- package/src/lightning/icon/icon.css +2 -2
- package/src/lightning/icon/icon.js +16 -2
- package/src/lightning/icon/icon.slds.css +29 -17
- package/src/lightning/icon/iconColors.js +1 -0
- package/src/lightning/input/__examples__/text/text.html +0 -1
- package/src/lightning/input/form-element.slds.css +281 -0
- package/src/lightning/input/input-checkbox.slds.css +3 -12
- package/src/lightning/input/input-text.slds.css +239 -128
- package/src/lightning/input/input.css +2 -1
- package/src/lightning/input/input.html +8 -8
- package/src/lightning/input/input.js +107 -73
- package/src/lightning/internationalizationLibrary/README.md +24 -0
- package/src/lightning/internationalizationLibrary/utils.js +4 -1
- package/src/lightning/layout/__docs__/layout.md +1 -1
- package/src/lightning/layout/__examples__/simple/simple.css +1 -1
- package/src/lightning/layout/layout.css +5 -1
- package/src/lightning/layout/layout.js +4 -2
- package/src/lightning/layoutItem/__examples__/alignmentBump/alignmentBump.css +1 -1
- package/src/lightning/layoutItem/__examples__/sizePerDevice/sizePerDevice.css +0 -1
- package/src/lightning/layoutItem/layoutItem.css +5 -0
- package/src/lightning/layoutItem/layoutItem.js +4 -2
- package/src/lightning/menuDivider/menu-divider.slds.css +15 -0
- package/src/lightning/menuDivider/menuDivider.css +3 -0
- package/src/lightning/menuDivider/menuDivider.html +1 -1
- package/src/lightning/menuDivider/menuDivider.js +4 -2
- package/src/lightning/menuItem/menu-item.slds.css +140 -0
- package/src/lightning/menuItem/menuItem.css +3 -0
- package/src/lightning/menuItem/menuItem.html +43 -41
- package/src/lightning/menuItem/menuItem.js +4 -4
- package/src/lightning/menuSubheader/menu-subheader.slds.css +22 -0
- package/src/lightning/menuSubheader/menuSubheader.css +3 -0
- package/src/lightning/menuSubheader/menuSubheader.html +3 -1
- package/src/lightning/menuSubheader/menuSubheader.js +4 -6
- package/src/lightning/modal/__docs__/modal.md +3 -1
- package/src/lightning/modal/__modalUtils__/modalContainerTestConstants.js +267 -0
- package/src/lightning/modal/__modalUtils__/modalContainerTestMethods.js +1165 -0
- package/src/lightning/modal/__modalUtils__/modalContainerTestMockData.js +131 -0
- package/src/lightning/modal/modal.js +1 -1
- package/src/lightning/pill/avatar.slds.css +272 -0
- package/src/lightning/pill/link.css +3 -0
- package/src/lightning/pill/link.html +1 -1
- package/src/lightning/pill/pill.js +29 -9
- package/src/lightning/pill/pill.slds.css +168 -0
- package/src/lightning/pill/plain.css +3 -0
- package/src/lightning/pill/plain.html +1 -1
- package/src/lightning/pill/plainLink.css +3 -0
- package/src/lightning/pill/plainLink.html +1 -1
- package/src/lightning/pillContainer/barePillContainer.css +3 -0
- package/src/lightning/pillContainer/barePillContainer.html +1 -2
- package/src/lightning/pillContainer/listbox.slds.css +267 -0
- package/src/lightning/pillContainer/pill-container.slds.css +22 -0
- package/src/lightning/pillContainer/pill.slds.css +168 -0
- package/src/lightning/pillContainer/pillContainer.js +7 -3
- package/src/lightning/pillContainer/standardPillContainer.css +4 -0
- package/src/lightning/pillContainer/standardPillContainer.html +2 -2
- package/src/lightning/popup/popover.slds.css +119 -119
- package/src/lightning/popup/popup.css +1 -2
- package/src/lightning/popup/popup.js +3 -2
- package/src/lightning/positionLibrary/elementProxy.js +7 -2
- package/src/lightning/positionLibrary/util.js +8 -0
- package/src/lightning/primitiveBubble/primitiveBubble.css +2 -2
- package/src/lightning/primitiveBubble/primitiveBubble.js +4 -2
- package/src/lightning/primitiveButton/primitiveButton.js +5 -4
- package/src/lightning/primitiveCellFactory/cellWithStandardLayout.html +29 -21
- package/src/lightning/primitiveCellFactory/primitiveCellFactory.js +4 -0
- package/src/lightning/primitiveColorpickerButton/color-picker-button.slds.css +31 -19
- package/src/lightning/primitiveColorpickerButton/primitiveColorpickerButton.css +2 -2
- package/src/lightning/primitiveColorpickerButton/primitiveColorpickerButton.js +5 -3
- package/src/lightning/primitiveIcon/icon.slds.css +209 -0
- package/src/lightning/primitiveIcon/primitiveIcon.css +2 -1
- package/src/lightning/primitiveIcon/primitiveIcon.html +1 -1
- package/src/lightning/primitiveIcon/primitiveIcon.js +18 -11
- package/src/lightning/progressStep/progressStep.js +10 -13
- package/src/lightning/radioGroup/radioGroup.css +2 -1
- package/src/lightning/radioGroup/radioGroup.js +4 -2
- package/src/lightning/select/form-element.slds.css +83 -34
- package/src/lightning/select/select.css +2 -2
- package/src/lightning/select/select.js +4 -2
- package/src/lightning/select/select.slds.css +86 -34
- package/src/lightning/sldsCommon/sldsCommon.css +135 -75
- package/src/lightning/spinner/spinner.css +2 -2
- package/src/lightning/spinner/spinner.js +4 -2
- package/src/lightning/tabBar/tab-bar.slds.css +334 -0
- package/src/lightning/tabBar/tabBar.css +2 -0
- package/src/lightning/tabBar/tabBar.html +4 -3
- package/src/lightning/tabBar/tabBar.js +30 -3
- package/src/lightning/tabset/tabset.html +5 -4
- package/src/lightning/tabset/tabset.js +29 -11
- package/src/lightning/timepicker/form-element.slds.css +281 -0
- package/src/lightning/timepicker/timepicker.css +3 -0
- package/src/lightning/timepicker/timepicker.html +5 -1
- package/src/lightning/timepicker/timepicker.js +18 -15
- package/src/lightning/timepicker/timepicker.slds.css +18 -0
- package/src/lightning/tooltipLibrary/tooltipLibrary.js +21 -19
- package/src/lightning/utilsPrivate/browser.js +5 -3
- package/src/lightning/utilsPrivate/os.js +6 -4
- package/src/lightning/utilsPrivate/ssr.js +4 -0
- package/src/lightning/utilsPrivate/utilsPrivate.js +2 -0
- package/src/lightning/verticalNavigation/verticalNavigation.css +2 -1
- package/src/lightning/verticalNavigation/verticalNavigation.js +3 -2
- package/src/lightning/verticalNavigationSection/verticalNavigationSection.css +2 -1
- package/src/lightning/verticalNavigationSection/verticalNavigationSection.js +3 -2
- package/src/lightning/accordion/__perf__DISABLED/accordion-perf-utils.js +0 -76
- package/src/lightning/accordion/__perf__DISABLED/accordion10Multiple25SectionEach.perf.js +0 -57
- package/src/lightning/accordion/__perf__DISABLED/accordion10Simple25SectionEach.perf.js +0 -37
- package/src/lightning/accordion/__perf__DISABLED/accordionMultiple50Section.perf.js +0 -45
- package/src/lightning/accordion/__perf__DISABLED/accordionSimple50Section.perf.js +0 -35
- package/src/lightning/accordion/__perf__DISABLED/container/container.html +0 -15
- package/src/lightning/accordion/__perf__DISABLED/container/container.js +0 -7
- package/src/lightning/positionLibrary/__component__/positionLibraryBounding.spec.js +0 -319
- package/src/lightning/positionLibrary/__component__/x/bounding/bounding.css +0 -16
- package/src/lightning/positionLibrary/__component__/x/bounding/bounding.html +0 -36
- package/src/lightning/positionLibrary/__component__/x/bounding/bounding.js +0 -122
- /package/src/lightning/{baseCombobox → baseComboboxItem}/listbox.slds.css +0 -0
|
@@ -99,137 +99,192 @@
|
|
|
99
99
|
}
|
|
100
100
|
|
|
101
101
|
@supports (--styling-hooks: '') {
|
|
102
|
-
|
|
102
|
+
/**
|
|
103
103
|
* Input Text
|
|
104
104
|
*/
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
105
|
+
:host([data-render-mode="shadow"]) [part~='input-text'] {
|
|
106
|
+
/* Host reassignments to composed slds-icon */
|
|
107
|
+
--slds-c-icon-color-foreground: var(
|
|
108
|
+
--slds-c-inputtext-icon-color-foreground,
|
|
109
|
+
var(--sds-g-color-neutral-base-50, #747474)
|
|
110
|
+
);
|
|
111
|
+
--slds-c-icon-sizing: var(--slds-c-inputtext-icon-sizing, 14px);
|
|
112
|
+
--sds-c-inputtext-sizing-height: var(
|
|
113
|
+
--slds-c-inputtext-sizing-height,
|
|
114
|
+
var(--sds-g-sizing-9, 2rem)
|
|
115
|
+
);
|
|
116
|
+
--sds-c-inputtext-color-background: var(
|
|
117
|
+
--slds-c-inputtext-color-background,
|
|
118
|
+
var(--sds-g-color-neutral-base-100, #ffffff)
|
|
119
|
+
);
|
|
120
|
+
--sds-c-inputtext-color-background-focus: var(
|
|
121
|
+
--slds-c-inputtext-color-background-focus,
|
|
122
|
+
var(--sds-g-color-neutral-base-100, #ffffff)
|
|
123
|
+
);
|
|
124
|
+
--sds-c-inputtext-text-color: var(--slds-c-inputtext-text-color);
|
|
125
|
+
--sds-c-inputtext-font-size: var(
|
|
126
|
+
--slds-c-inputtext-font-size,
|
|
127
|
+
var(--sds-g-font-scale-neg-2, 0.8125rem)
|
|
128
|
+
);
|
|
129
|
+
--sds-c-inputtext-text-color-placeholder: var(
|
|
130
|
+
--slds-c-inputtext-text-color-placeholder,
|
|
131
|
+
var(--sds-g-color-neutral-base-50, #747474)
|
|
132
|
+
);
|
|
133
|
+
--sds-c-inputtext-color-border: var(
|
|
134
|
+
--slds-c-inputtext-color-border,
|
|
135
|
+
var(--sds-g-color-neutral-base-80, #c9c9c9)
|
|
136
|
+
);
|
|
137
|
+
--sds-c-inputtext-sizing-border: var(--slds-c-inputtext-sizing-border);
|
|
138
|
+
--sds-c-inputtext-radius-border: var(
|
|
139
|
+
--slds-c-inputtext-radius-border,
|
|
140
|
+
var(--sds-g-radius-border-2, 0.25rem)
|
|
141
|
+
);
|
|
142
|
+
|
|
143
|
+
display: flex;
|
|
144
|
+
flex-wrap: wrap;
|
|
145
|
+
align-items: center;
|
|
146
|
+
}
|
|
137
147
|
|
|
138
|
-
|
|
148
|
+
/**
|
|
149
|
+
* Input Container
|
|
150
|
+
*/
|
|
151
|
+
:host([data-render-mode="shadow"]) [part~='input-container'] {
|
|
152
|
+
flex: 1 0 100%;
|
|
153
|
+
align-items: stretch;
|
|
154
|
+
}
|
|
155
|
+
|
|
156
|
+
:host([data-render-mode="shadow"]) [part~='input-container'][type~='range'] {
|
|
157
|
+
border: none;
|
|
158
|
+
display: inline-block;
|
|
159
|
+
}
|
|
160
|
+
|
|
161
|
+
:host([data-render-mode="shadow"]) [part~='input'][type~='range'] {
|
|
162
|
+
min-height: calc(1.875rem + (1px * 2));
|
|
163
|
+
margin: 0;
|
|
164
|
+
}
|
|
165
|
+
|
|
166
|
+
:host([data-render-mode="shadow"]) [part~='input-container'][type~='range']:focus-within,:host([data-render-mode="shadow"])
|
|
167
|
+
[part~='input-container'][type~='range']:active {
|
|
168
|
+
--sds-c-inputtext-color-border: var(--sds-g-color-brand-base-60, #1b96ff);
|
|
169
|
+
--sds-c-inputtext-shadow: 0 0 3px var(--sds-g-color-brand-base-50, #0176d3);
|
|
170
|
+
--sds-c-inputtext-color-background: var(--sds-g-color-neutral-base-100, #ffffff);
|
|
171
|
+
|
|
172
|
+
outline: 0;
|
|
173
|
+
border-width: var(--sds-c-inputtext-sizing-border, var(--sds-g-sizing-border-1, 1px));
|
|
174
|
+
border-color: var(--sds-c-inputtext-color-border, var(--sds-g-color-neutral-base-contrast-3));
|
|
175
|
+
}
|
|
176
|
+
|
|
177
|
+
/**
|
|
178
|
+
* Input
|
|
179
|
+
*/
|
|
180
|
+
:host([data-render-mode="shadow"]) [part~='input'] {
|
|
181
|
+
padding-inline-start: var(
|
|
182
|
+
--slds-c-inputtext-spacing-inline-start,
|
|
183
|
+
var(--sds-g-spacing-3, 0.75rem));
|
|
184
|
+
padding-inline-end: var(
|
|
185
|
+
--slds-c-inputtext-spacing-inline-end,
|
|
186
|
+
var(--sds-g-spacing-4, 1rem));
|
|
187
|
+
height: unset;
|
|
188
|
+
font-family: var(--sds-g-font-family, system-ui, -apple-system, BlinkMacSystemFont, Segoe UI, Roboto, 'Helvetica Neue', Arial, sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol');
|
|
189
|
+
}
|
|
190
|
+
|
|
191
|
+
/**
|
|
192
|
+
* Focus / active State
|
|
193
|
+
*/
|
|
194
|
+
:host([data-render-mode="shadow"]) [part~="input-container"]:focus-within,:host([data-render-mode="shadow"])
|
|
195
|
+
[part~="input-container"]:active {
|
|
196
|
+
--sds-c-inputtext-color-border: var(--sds-g-color-brand-base-60, #1b96ff);
|
|
197
|
+
--sds-c-inputtext-shadow: 0 0 3px var(--sds-g-color-brand-base-50, #0176d3);
|
|
198
|
+
--sds-c-inputtext-color-background: var(--sds-g-color-neutral-base-100, #ffffff);
|
|
199
|
+
|
|
200
|
+
outline: 0;
|
|
201
|
+
}
|
|
202
|
+
|
|
203
|
+
/**
|
|
139
204
|
* Read Only State
|
|
140
205
|
*/
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
206
|
+
:host([data-render-mode="shadow"][readonly]) [part~='input-text'] {
|
|
207
|
+
--sds-c-inputtext-spacing-inline-start-readonly: 0;
|
|
208
|
+
--sds-c-inputtext-color-border-focus: transparent;
|
|
209
|
+
--slds-c-inputtext-color-border: transparent;
|
|
210
|
+
--slds-c-inputtext-color-background: transparent;
|
|
211
|
+
--slds-c-inputtext-color-background-focus: transparent;
|
|
212
|
+
}
|
|
146
213
|
|
|
147
|
-
|
|
214
|
+
/**
|
|
148
215
|
* Invalid State
|
|
149
216
|
*
|
|
150
217
|
* Does not use --sds-c-inputtext-color-border-invalid due to this hook being
|
|
151
218
|
* tied to :host([aria-invalid]) which this subsystem does not use. Instead, it
|
|
152
219
|
* uses :host([invalid]).
|
|
153
220
|
*/
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
221
|
+
:host([data-render-mode="shadow"][invalid]) [part~='input-text'] {
|
|
222
|
+
--sds-c-inputtext-shadow: 0 0 0 var(--sds-g-sizing-border-1, 1px) inset
|
|
223
|
+
var(--sds-g-color-error-base-50, #ea001e);
|
|
224
|
+
--slds-c-inputtext-color-border: var(--sds-g-color-error-base-50, #ea001e);
|
|
225
|
+
--slds-c-icon-color-foreground: var(--sds-g-color-error-base-50, #ea001e);
|
|
226
|
+
}
|
|
159
227
|
|
|
160
|
-
|
|
228
|
+
/**
|
|
229
|
+
* Invalid State - Focus
|
|
230
|
+
*
|
|
231
|
+
* The following styling hooks are included in SDS and need to be reassigned
|
|
232
|
+
* here to prevent a bug with the focus state border and box-shadow
|
|
233
|
+
*/
|
|
234
|
+
:host([data-render-mode="shadow"][invalid]) [part~='input-container']:focus-within {
|
|
235
|
+
--sds-c-inputtext-shadow:
|
|
236
|
+
var(--sds-g-color-error-base-50, #ea001e) 0 0 0 var(--sds-g-sizing-border-1, 1px) inset,
|
|
237
|
+
0 0 var(--sds-g-sizing-border-3, 3px) var(--sds-g-color-brand-base-50, #0176d3);
|
|
238
|
+
--sds-c-inputtext-color-border: var(--sds-g-color-error-base-50, #ea001e);
|
|
239
|
+
}
|
|
240
|
+
|
|
241
|
+
/**
|
|
161
242
|
* Disabled State
|
|
162
243
|
*
|
|
163
244
|
* Both parts form the visible form control.
|
|
164
245
|
*/
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
246
|
+
:host([data-render-mode="shadow"][disabled]) [part~='input-container'],:host([data-render-mode="shadow"][disabled]) [part~='input'] {
|
|
247
|
+
cursor: not-allowed;
|
|
248
|
+
--sds-c-inputtext-color-background: var(--sds-g-color-neutral-base-95, #f3f3f3);
|
|
249
|
+
--sds-c-inputtext-color-border: var(--sds-g-color-neutral-base-80, #c9c9c9);
|
|
250
|
+
--sds-c-inputtext-text-color: var(--sds-g-color-neutral-base-50, #747474);
|
|
251
|
+
}
|
|
168
252
|
|
|
169
|
-
|
|
253
|
+
/**
|
|
170
254
|
* Label
|
|
171
255
|
*
|
|
172
256
|
* Add [part~='input-text'] to increase specificity and
|
|
173
257
|
* avoid collisions with other components using [part~='label'] (e.g. slds-input-checkbox)
|
|
174
258
|
*/
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
color: var(--sds-g-color-error-base-50, #ea001e);
|
|
192
|
-
}
|
|
193
|
-
|
|
194
|
-
/**
|
|
195
|
-
* Input Container
|
|
196
|
-
*/
|
|
197
|
-
:host([data-render-mode="shadow"]) [part~='input-container'] {
|
|
198
|
-
flex: 1 0 100%;
|
|
199
|
-
}
|
|
200
|
-
|
|
201
|
-
/**
|
|
202
|
-
* Help Text
|
|
203
|
-
*
|
|
204
|
-
* Note: not to be confused with lightning-helptext. This is for the text
|
|
205
|
-
* that goes below the input.
|
|
206
|
-
*/
|
|
207
|
-
:host([data-render-mode="shadow"]) [part~='help-text'] {
|
|
208
|
-
font-size: var(--slds-c-inputtext-helptext-font-size, var(--sds-g-font-scale-neg-3, 0.75rem));
|
|
209
|
-
|
|
210
|
-
/* TODO: Add global hook once SLDS creates a new spacing hook that equals the value needed here */
|
|
211
|
-
padding-block-start: 0.125rem;
|
|
212
|
-
}
|
|
213
|
-
|
|
214
|
-
/**
|
|
215
|
-
* Help Text's Invalid State – Part container is unique to SLDS
|
|
216
|
-
*/
|
|
217
|
-
:host([data-render-mode="shadow"][invalid]) [part~='help-text'] {
|
|
218
|
-
color: var(--sds-g-color-error-base-50, #ea001e);
|
|
219
|
-
}
|
|
259
|
+
:host([data-render-mode="shadow"]) [part~='input-text'] [part~='label'] {
|
|
260
|
+
padding-block-start: var(--sds-g-spacing-1, 0.25rem);
|
|
261
|
+
padding-inline-end: var(--sds-g-spacing-2, 0.5rem);
|
|
262
|
+
color: var(
|
|
263
|
+
--slds-c-inputtext-label-color,
|
|
264
|
+
var(--sds-g-color-neutral-base-30, #444444)
|
|
265
|
+
);
|
|
266
|
+
font-size: var(
|
|
267
|
+
--slds-c-inputtext-label-font-size,
|
|
268
|
+
var(--sds-g-font-scale-neg-3, 0.75rem)
|
|
269
|
+
);
|
|
270
|
+
margin-block-end: var(--sds-g-sizing-1, 0.125rem);
|
|
271
|
+
|
|
272
|
+
/* We inline flex to control the spacing between elements and not have to rely on whitespace characters */
|
|
273
|
+
display: inline-flex;
|
|
274
|
+
}
|
|
220
275
|
|
|
221
|
-
|
|
276
|
+
/**
|
|
222
277
|
* Start
|
|
223
278
|
*
|
|
224
279
|
* Only expects an SLDS icon. We assign the SLDS Icon Styling Hook here
|
|
225
280
|
* so we don't add spacing to other icons composed in the component, e.g.,
|
|
226
281
|
* the icon in the inline help text.
|
|
227
282
|
*/
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
283
|
+
:host([data-render-mode="shadow"]) [part~='start'] {
|
|
284
|
+
--slds-c-icon-spacing-inline-end: var(--sds-g-spacing-2, 0.5rem);
|
|
285
|
+
}
|
|
231
286
|
|
|
232
|
-
|
|
287
|
+
/**
|
|
233
288
|
* Label Inline Variant
|
|
234
289
|
*
|
|
235
290
|
* Note: all the 33% values you see are remnants of legacy SLDS. We need to
|
|
@@ -241,47 +296,103 @@
|
|
|
241
296
|
*
|
|
242
297
|
* Ref: https://github.com/salesforce-ux/design-system-internal/blob/240-winter-23/ui/components/form-element/horizontal/_index.scss#L63
|
|
243
298
|
*/
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
299
|
+
@media (min-width: 48em) {
|
|
300
|
+
:host([data-render-mode="shadow"][variant~='label-inline']) [part~='input-text'] {
|
|
301
|
+
display: block;
|
|
302
|
+
}
|
|
303
|
+
|
|
304
|
+
:host([data-render-mode="shadow"][variant~='label-inline']) [part~='label'] {
|
|
305
|
+
float: left;
|
|
306
|
+
|
|
307
|
+
/* TODO: Get rid of these magic numbers */
|
|
308
|
+
max-width: calc(33% - 1.125rem);
|
|
309
|
+
padding-block-start: var(--sds-g-spacing-1, 0.25rem);
|
|
310
|
+
}
|
|
311
|
+
|
|
312
|
+
:host([data-render-mode="shadow"][variant~='label-inline']) [part~='input-container'] {
|
|
313
|
+
margin-inline-start: 33%;
|
|
314
|
+
}
|
|
315
|
+
|
|
316
|
+
:host([data-render-mode="shadow"][variant~='label-inline']) [part~='inline-help'] {
|
|
317
|
+
float: left;
|
|
318
|
+
padding-block-start: var(--sds-g-spacing-1, 0.25rem);
|
|
319
|
+
}
|
|
320
|
+
}
|
|
321
|
+
|
|
322
|
+
:host([data-render-mode="shadow"]) input[type="search"] + lightning-primitive-icon::part(icon) {
|
|
323
|
+
left: var(--sds-g-spacing-3, 0.75rem);
|
|
324
|
+
fill: var(--slds-g-color-neutral-base-50, #747474);
|
|
325
|
+
}
|
|
326
|
+
|
|
327
|
+
:host([data-render-mode="shadow"]) .slds-input-has-icon .slds-button_icon {
|
|
328
|
+
background-color: transparent;
|
|
247
329
|
}
|
|
248
330
|
|
|
249
|
-
:host([data-render-mode="shadow"][
|
|
250
|
-
|
|
331
|
+
:host([data-render-mode="shadow"]) .slds-input-has-icon .slds-button_icon:focus,:host([data-render-mode="shadow"])
|
|
332
|
+
.slds-input-has-icon .slds-button_icon:hover {
|
|
333
|
+
--slds-c-icon-color-foreground: var(--sds-g-color-brand-base-30, #014486);
|
|
334
|
+
}
|
|
251
335
|
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
336
|
+
:host([data-render-mode="shadow"]) .slds-input-has-icon .slds-input__icon {
|
|
337
|
+
width: 0.875rem;
|
|
338
|
+
height: 0.875rem;
|
|
339
|
+
position: absolute;
|
|
340
|
+
top: 50%;
|
|
341
|
+
margin-top: -0.4375rem;
|
|
342
|
+
line-height: 1;
|
|
343
|
+
border: 0;
|
|
344
|
+
z-index: 2;
|
|
255
345
|
}
|
|
256
346
|
|
|
257
|
-
|
|
258
|
-
|
|
347
|
+
/**
|
|
348
|
+
* Has Icon Left
|
|
349
|
+
*/
|
|
350
|
+
:host([data-render-mode="shadow"]) .slds-input-has-icon_left {
|
|
351
|
+
--slds-c-inputtext-spacing-inline-start: var(--sds-g-spacing-6, 2rem);
|
|
259
352
|
}
|
|
260
353
|
|
|
261
|
-
:host([data-render-mode="shadow"]
|
|
262
|
-
|
|
263
|
-
|
|
354
|
+
:host([data-render-mode="shadow"]) .slds-input-has-icon_left .slds-input__icon,:host([data-render-mode="shadow"])
|
|
355
|
+
.slds-input-has-icon_left-right .slds-input__icon_left {
|
|
356
|
+
inset-inline-start: var(--sds-g-spacing-3, 0.75rem);
|
|
264
357
|
}
|
|
265
|
-
}
|
|
266
|
-
}
|
|
267
358
|
|
|
268
|
-
/**
|
|
359
|
+
/**
|
|
360
|
+
* Has Icon Right
|
|
361
|
+
*/
|
|
362
|
+
:host([data-render-mode="shadow"]) .slds-input-has-icon_right {
|
|
363
|
+
--slds-c-inputtext-spacing-inline-end: var(--sds-g-spacing-6, 2rem);
|
|
364
|
+
}
|
|
365
|
+
|
|
366
|
+
:host([data-render-mode="shadow"]) .slds-input-has-icon_right .slds-input__icon,:host([data-render-mode="shadow"])
|
|
367
|
+
.slds-input-has-icon_left-right .slds-input__icon_right {
|
|
368
|
+
inset-inline-end: var(--sds-g-spacing-3, 0.75rem);
|
|
369
|
+
}
|
|
370
|
+
|
|
371
|
+
/**
|
|
372
|
+
* Has Icon Left & Right
|
|
373
|
+
*/
|
|
374
|
+
:host([data-render-mode="shadow"]) .slds-input-has-icon_left-right {
|
|
375
|
+
--slds-c-inputtext-spacing-inline-start: var(--sds-g-spacing-6, 2rem);
|
|
376
|
+
--slds-c-inputtext-spacing-inline-end: var(--sds-g-spacing-6, 2rem);
|
|
377
|
+
}
|
|
378
|
+
|
|
379
|
+
/**
|
|
269
380
|
* A temporarily baked-in utility class until SLDS gets a proper utility package.
|
|
270
381
|
*
|
|
271
382
|
* This is a hybrid patch between synthetic and native shadow. The ideal final
|
|
272
383
|
* outcome is the removal of this class and replacing the class with the SLDS
|
|
273
384
|
* utility package solution.
|
|
274
385
|
*/
|
|
275
|
-
|
|
276
|
-
:
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
386
|
+
:host([data-render-mode="shadow"]) .slds-assistive-text {
|
|
387
|
+
position: absolute !important;
|
|
388
|
+
margin: -1px !important;
|
|
389
|
+
border: 0 !important;
|
|
390
|
+
padding: 0 !important;
|
|
391
|
+
width: 1px !important;
|
|
392
|
+
height: 1px !important;
|
|
393
|
+
overflow: hidden !important;
|
|
394
|
+
clip: rect(0 0 0 0) !important;
|
|
395
|
+
text-transform: none !important;
|
|
396
|
+
white-space: nowrap !important;
|
|
397
|
+
}
|
|
287
398
|
}
|
|
@@ -75,7 +75,6 @@
|
|
|
75
75
|
onblur={handleBlur}
|
|
76
76
|
onfocus={handleFocus}
|
|
77
77
|
onchange={handleChange}
|
|
78
|
-
onclick={handleCheckboxClick}
|
|
79
78
|
name={name}
|
|
80
79
|
required={required}
|
|
81
80
|
readonly={readOnly}
|
|
@@ -106,7 +105,7 @@
|
|
|
106
105
|
<abbr class="slds-required" title={i18n.required}>*</abbr>
|
|
107
106
|
</template>
|
|
108
107
|
</template>
|
|
109
|
-
<input type="checkbox"
|
|
108
|
+
<input type="checkbox"
|
|
110
109
|
part="checkbox"
|
|
111
110
|
id="checkbox"
|
|
112
111
|
aria-label={computedAriaLabel}
|
|
@@ -115,7 +114,6 @@
|
|
|
115
114
|
onblur={handleBlur}
|
|
116
115
|
onfocus={handleFocus}
|
|
117
116
|
onchange={handleChange}
|
|
118
|
-
onclick={handleCheckboxClick}
|
|
119
117
|
name={name}
|
|
120
118
|
required={required}
|
|
121
119
|
readonly={readOnly}
|
|
@@ -144,7 +142,6 @@
|
|
|
144
142
|
onblur={handleBlur}
|
|
145
143
|
onfocus={handleFocus}
|
|
146
144
|
onchange={handleChange}
|
|
147
|
-
onclick={handleCheckboxClick}
|
|
148
145
|
name={name}
|
|
149
146
|
required={required}
|
|
150
147
|
readonly={readOnly}
|
|
@@ -280,7 +277,8 @@
|
|
|
280
277
|
message-when-value-missing={messageWhenValueMissing}
|
|
281
278
|
message-when-range-overflow={messageWhenRangeOverflow}
|
|
282
279
|
message-when-range-underflow={messageWhenRangeUnderflow}
|
|
283
|
-
disabled={disabled}
|
|
280
|
+
disabled={disabled}
|
|
281
|
+
root-aria-node={templateRootNode}>
|
|
284
282
|
</lightning-datepicker>
|
|
285
283
|
</template>
|
|
286
284
|
|
|
@@ -305,7 +303,8 @@
|
|
|
305
303
|
message-when-value-missing={messageWhenValueMissing}
|
|
306
304
|
message-when-range-overflow={messageWhenRangeOverflow}
|
|
307
305
|
message-when-range-underflow={messageWhenRangeUnderflow}
|
|
308
|
-
disabled={disabled}
|
|
306
|
+
disabled={disabled}
|
|
307
|
+
root-aria-node={templateRootNode}>
|
|
309
308
|
</lightning-timepicker>
|
|
310
309
|
</template>
|
|
311
310
|
|
|
@@ -339,11 +338,12 @@
|
|
|
339
338
|
message-when-value-missing={messageWhenValueMissing}
|
|
340
339
|
message-when-range-overflow={messageWhenRangeOverflow}
|
|
341
340
|
message-when-range-underflow={messageWhenRangeUnderflow}
|
|
342
|
-
disabled={disabled}
|
|
341
|
+
disabled={disabled}
|
|
342
|
+
root-aria-node={templateRootNode}>
|
|
343
343
|
</lightning-datetimepicker>
|
|
344
344
|
</template>
|
|
345
345
|
|
|
346
346
|
<template if:true={_helpMessage}>
|
|
347
|
-
<div id="help-message" class=
|
|
347
|
+
<div id="help-message" class="slds-form-element__help" data-help-message role="alert" part="help-text">{_helpMessage}</div>
|
|
348
348
|
</template>
|
|
349
349
|
</template>
|