lightning-base-components 1.18.7-alpha → 1.18.7-ssr
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 +30 -9
- package/package.json +68 -2
- package/src/lightning/accordion/accordion.css +4 -4
- package/src/lightning/accordion/accordion.js +4 -2
- package/src/lightning/accordion/accordion.slds.css +26 -20
- package/src/lightning/accordionSection/accordion-section.slds.css +20 -14
- package/src/lightning/accordionSection/accordionSection.css +4 -4
- package/src/lightning/accordionSection/accordionSection.js +4 -2
- package/src/lightning/avatar/avatar.css +2 -2
- package/src/lightning/avatar/avatar.js +3 -2
- package/src/lightning/avatar/avatar.slds.css +10 -10
- package/src/lightning/badge/__examples__/basic/basic.html +3 -1
- package/src/lightning/badge/badge.css +2 -0
- package/src/lightning/badge/badge.html +16 -14
- package/src/lightning/badge/badge.js +4 -2
- package/src/lightning/badge/badge.slds.css +73 -0
- package/src/lightning/baseCombobox/base-combobox.slds.css +23 -23
- package/src/lightning/baseCombobox/baseCombobox.css +2 -2
- package/src/lightning/baseCombobox/baseCombobox.html +7 -11
- package/src/lightning/baseCombobox/baseCombobox.js +87 -37
- package/src/lightning/baseCombobox/listbox.slds.css +267 -0
- package/src/lightning/baseCombobox/spinner.slds.css +34 -34
- package/src/lightning/baseComboboxItem/baseComboboxItem.js +4 -2
- package/src/lightning/baseComboboxItem/inline.css +2 -2
- package/src/lightning/breadcrumb/breadcrumb.css +2 -2
- package/src/lightning/breadcrumb/breadcrumb.js +8 -4
- package/src/lightning/breadcrumb/breadcrumb.slds.css +3 -3
- package/src/lightning/breadcrumbs/breadcrumbs.css +2 -2
- package/src/lightning/breadcrumbs/breadcrumbs.js +3 -2
- package/src/lightning/breadcrumbs/breadcrumbs.slds.css +5 -5
- package/src/lightning/button/button.css +2 -2
- package/src/lightning/button/button.slds.css +8 -2
- package/src/lightning/buttonGroup/button-group.slds.css +5 -5
- package/src/lightning/buttonGroup/buttonGroup.css +2 -2
- package/src/lightning/buttonGroup/buttonGroup.js +3 -2
- package/src/lightning/buttonIcon/button-icon.slds.css +9 -3
- package/src/lightning/buttonIcon/buttonIcon.css +2 -2
- package/src/lightning/buttonIcon/buttonIcon.js +1 -0
- package/src/lightning/buttonIconStateful/button-icon-stateful.slds.css +15 -9
- package/src/lightning/buttonIconStateful/buttonIconStateful.css +2 -2
- package/src/lightning/buttonMenu/button-menu.slds.css +13 -7
- package/src/lightning/buttonMenu/buttonMenu.css +2 -2
- package/src/lightning/buttonMenu/buttonMenu.js +4 -2
- package/src/lightning/buttonMenu/dropdown.slds.css +1360 -0
- package/src/lightning/buttonStateful/button-stateful.slds.css +11 -5
- package/src/lightning/buttonStateful/buttonStateful.css +2 -2
- package/src/lightning/buttonStateful/buttonStateful.js +3 -2
- package/src/lightning/calendar/calendar.css +2 -2
- package/src/lightning/calendar/calendar.js +19 -25
- package/src/lightning/calendar/calendar.slds.css +29 -23
- package/src/lightning/card/card.css +2 -2
- package/src/lightning/card/card.js +3 -2
- package/src/lightning/card/card.slds.css +68 -68
- package/src/lightning/colorPickerCustom/colorPickerCustom.css +2 -2
- package/src/lightning/colorPickerCustom/colorPickerCustom.js +3 -2
- package/src/lightning/colorPickerPanel/colorPickerPanel.css +2 -2
- package/src/lightning/colorPickerPanel/colorPickerPanel.js +4 -2
- package/src/lightning/combobox/combobox.css +2 -2
- package/src/lightning/combobox/combobox.js +4 -2
- package/src/lightning/combobox/combobox.slds.css +1 -1
- package/src/lightning/combobox/form-element.slds.css +8 -0
- package/src/lightning/datatable/datatable.js +3 -0
- package/src/lightning/datatable/keyboard.js +8 -4
- package/src/lightning/datatable/sort.js +1 -1
- package/src/lightning/datepicker/datepicker.css +2 -2
- package/src/lightning/datepicker/datepicker.js +5 -3
- package/src/lightning/datepicker/form-element.slds.css +8 -0
- package/src/lightning/datepicker/input-text.slds.css +23 -23
- package/src/lightning/datetimepicker/datetimepicker.css +2 -2
- package/src/lightning/datetimepicker/datetimepicker.js +4 -2
- package/src/lightning/datetimepicker/form-element.slds.css +8 -0
- package/src/lightning/datetimepicker/input-text.slds.css +23 -23
- package/src/lightning/dualListbox/dualListbox.css +2 -2
- package/src/lightning/dualListbox/dualListbox.js +4 -2
- package/src/lightning/dualListbox/form-element.slds.css +8 -0
- 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/f6Controller/f6Controller.js +31 -22
- package/src/lightning/formattedRichText/formattedRichText.css +2 -2
- package/src/lightning/formattedRichText/formattedRichText.js +4 -2
- package/src/lightning/formattedText/formattedText.css +1 -1
- package/src/lightning/formattedText/formattedText.js +3 -2
- package/src/lightning/groupedCombobox/groupedCombobox.html +4 -0
- package/src/lightning/groupedCombobox/groupedCombobox.js +3 -2
- package/src/lightning/helptext/form-element.slds.css +8 -0
- package/src/lightning/helptext/help-text.slds.css +10 -4
- package/src/lightning/helptext/helptext.css +2 -2
- package/src/lightning/helptext/helptext.js +3 -2
- package/src/lightning/icon/icon.css +2 -2
- package/src/lightning/icon/icon.js +10 -3
- package/src/lightning/icon/icon.slds.css +3 -3
- package/src/lightning/input/__examples__/checkboxbutton/checkboxbutton.css +6 -0
- package/src/lightning/input/__examples__/checkboxbutton/checkboxbutton.html +2 -1
- package/src/lightning/input/__examples__/checkboxbutton/checkboxbutton.js +1 -1
- package/src/lightning/input/__examples__/number/number.html +0 -5
- package/src/lightning/input/form-element.slds.css +8 -0
- package/src/lightning/input/input.css +2 -4
- package/src/lightning/input/input.html +149 -239
- package/src/lightning/input/input.js +221 -539
- package/src/lightning/inputUtils/inputUtils.js +15 -20
- package/src/lightning/inputUtils/normalize.js +7 -0
- package/src/lightning/{input/numberUtil.js → inputUtils/number.js} +1 -1
- package/src/lightning/inputUtils/utils.js +18 -0
- package/src/lightning/layout/layout.css +2 -2
- package/src/lightning/layout/layout.js +6 -2
- package/src/lightning/layoutItem/layoutItem.css +2 -2
- package/src/lightning/layoutItem/layoutItem.js +6 -2
- package/src/lightning/menuDivider/menuDivider.css +2 -2
- package/src/lightning/menuDivider/menuDivider.js +4 -2
- package/src/lightning/menuItem/menuItem.css +2 -2
- package/src/lightning/menuItem/menuItem.js +4 -2
- package/src/lightning/menuSubheader/menuSubheader.css +2 -2
- package/src/lightning/menuSubheader/menuSubheader.js +4 -2
- package/src/lightning/modal/__docs__/modal.md +102 -3
- package/src/lightning/modal/__examples__disabled/basic/basic.css +1 -1
- package/src/lightning/modal/__examples__disabled/demo/demo.css +1 -0
- package/src/lightning/modal/__examples__disabled/demoall/demoall.css +5 -0
- package/src/lightning/modal/__examples__disabled/demoallform/demoallform.css +4 -2
- package/src/lightning/modal/__examples__disabled/demoallformfull/demoallformfull.css +4 -2
- package/src/lightning/modal/__examples__disabled/demofootless/demofootless.css +1 -0
- package/src/lightning/modal/__examples__disabled/demoheadless/demoheadless.css +5 -0
- package/src/lightning/modal/__modalUtils__/modalContainerTestConstants.js +15 -0
- package/src/lightning/modalBase/modal-base.slds.css +240 -0
- package/src/lightning/modalBase/modalBase.css +7 -2
- package/src/lightning/modalBase/modalBase.html +2 -0
- package/src/lightning/modalBase/modalBase.js +44 -5
- package/src/lightning/modalBody/modal-body.slds.css +61 -0
- package/src/lightning/modalBody/modalBody.css +3 -0
- package/src/lightning/modalBody/modalBody.html +1 -0
- package/src/lightning/modalBody/modalBody.js +15 -2
- package/src/lightning/modalFooter/modal-footer.slds.css +68 -0
- package/src/lightning/modalFooter/modalFooter.css +2 -0
- package/src/lightning/modalFooter/modalFooter.html +1 -1
- package/src/lightning/modalFooter/modalFooter.js +17 -2
- package/src/lightning/modalHeader/modal-header.slds.css +70 -0
- package/src/lightning/modalHeader/modalHeader.css +3 -0
- package/src/lightning/modalHeader/modalHeader.html +1 -1
- package/src/lightning/modalHeader/modalHeader.js +18 -2
- package/src/lightning/overlay/overlay.js +3 -2
- package/src/lightning/pill/avatar.slds.css +10 -10
- package/src/lightning/pill/link.css +2 -2
- package/src/lightning/pill/pill.js +4 -2
- package/src/lightning/pill/plain.css +2 -2
- package/src/lightning/pill/plainLink.css +2 -2
- package/src/lightning/pillContainer/barePillContainer.css +2 -2
- package/src/lightning/pillContainer/pillContainer.js +4 -2
- package/src/lightning/pillContainer/standardPillContainer.css +2 -2
- package/src/lightning/popup/popup.css +2 -2
- package/src/lightning/popup/popup.js +3 -2
- package/src/lightning/primitiveBubble/primitiveBubble.css +2 -2
- package/src/lightning/primitiveBubble/primitiveBubble.js +4 -2
- package/src/lightning/primitiveButton/primitiveButton.js +3 -2
- package/src/lightning/primitiveColorpickerButton/color-picker-button.slds.css +9 -9
- package/src/lightning/primitiveColorpickerButton/primitiveColorpickerButton.css +2 -2
- package/src/lightning/primitiveColorpickerButton/primitiveColorpickerButton.js +3 -2
- package/src/lightning/primitiveIcon/icon.slds.css +3 -3
- package/src/lightning/primitiveIcon/primitiveIcon.css +2 -2
- package/src/lightning/primitiveInputCheckbox/form-element.slds.css +289 -0
- package/src/lightning/primitiveInputCheckbox/input-checkbox.slds.css +395 -0
- package/src/lightning/primitiveInputCheckbox/primitiveInputCheckbox.css +3 -0
- package/src/lightning/primitiveInputCheckbox/primitiveInputCheckbox.html +48 -0
- package/src/lightning/primitiveInputCheckbox/primitiveInputCheckbox.js +139 -0
- package/src/lightning/primitiveInputCheckboxButton/form-element.slds.css +289 -0
- package/src/lightning/primitiveInputCheckboxButton/input-checkbox-button.slds.css +126 -0
- package/src/lightning/primitiveInputCheckboxButton/primitiveInputCheckboxButton.css +6 -0
- package/src/lightning/primitiveInputCheckboxButton/primitiveInputCheckboxButton.html +24 -0
- package/src/lightning/primitiveInputCheckboxButton/primitiveInputCheckboxButton.js +176 -0
- package/src/lightning/primitiveInputColor/form-element.slds.css +289 -0
- package/src/lightning/primitiveInputColor/input-color.slds.css +35 -0
- package/src/lightning/primitiveInputColor/input-text.slds.css +398 -0
- package/src/lightning/primitiveInputColor/primitiveInputColor.css +4 -0
- package/src/lightning/primitiveInputColor/primitiveInputColor.html +50 -0
- package/src/lightning/primitiveInputColor/primitiveInputColor.js +184 -0
- package/src/lightning/primitiveInputFile/button.slds.css +533 -0
- package/src/lightning/primitiveInputFile/form-element.slds.css +289 -0
- package/src/lightning/primitiveInputFile/input-file.slds.css +62 -0
- package/src/lightning/primitiveInputFile/primitiveInputFile.css +5 -0
- package/src/lightning/primitiveInputFile/primitiveInputFile.html +45 -0
- package/src/lightning/primitiveInputFile/primitiveInputFile.js +111 -0
- package/src/lightning/primitiveInputRadio/primitiveInputRadio.html +24 -0
- package/src/lightning/primitiveInputRadio/primitiveInputRadio.js +103 -0
- package/src/lightning/primitiveInputSimple/form-element.slds.css +289 -0
- package/src/lightning/primitiveInputSimple/input-text.slds.css +398 -0
- package/src/lightning/primitiveInputSimple/primitiveInputSimple.css +9 -0
- package/src/lightning/primitiveInputSimple/primitiveInputSimple.html +65 -0
- package/src/lightning/primitiveInputSimple/primitiveInputSimple.js +585 -0
- package/src/lightning/primitiveInputToggle/form-element.slds.css +289 -0
- package/src/lightning/primitiveInputToggle/input-toggle.slds.css +170 -0
- package/src/lightning/primitiveInputToggle/primitiveInputToggle.css +3 -0
- package/src/lightning/primitiveInputToggle/primitiveInputToggle.html +34 -0
- package/src/lightning/primitiveInputToggle/primitiveInputToggle.js +164 -0
- package/src/lightning/progressBar/progress-bar.slds.css +66 -0
- package/src/lightning/progressBar/progressBar.css +2 -0
- package/src/lightning/progressBar/progressBar.html +1 -0
- package/src/lightning/progressBar/progressBar.js +3 -2
- package/src/lightning/progressRing/progress-ring.slds.css +140 -0
- package/src/lightning/progressRing/progressRing.css +2 -0
- package/src/lightning/progressRing/progressRing.html +8 -3
- package/src/lightning/progressRing/progressRing.js +3 -2
- package/src/lightning/radioGroup/input-radio-group.slds.css +57 -57
- package/src/lightning/radioGroup/radioGroup.css +2 -3
- package/src/lightning/radioGroup/radioGroup.js +4 -2
- package/src/lightning/select/form-element.slds.css +8 -0
- package/src/lightning/select/select.css +2 -2
- package/src/lightning/select/select.js +5 -2
- package/src/lightning/select/select.slds.css +30 -22
- package/src/lightning/sldsCommon/sldsCommon.css +21 -0
- package/src/lightning/spinner/spinner.css +2 -2
- package/src/lightning/spinner/spinner.js +11 -5
- package/src/lightning/spinner/spinner.slds.css +34 -34
- package/src/lightning/tab/tab.css +2 -0
- package/src/lightning/tab/tab.js +37 -14
- package/src/lightning/tab/tab.slds.css +47 -0
- package/src/lightning/tabBar/tab-bar.slds.css +5 -5
- package/src/lightning/tabBar/tabBar.css +2 -2
- package/src/lightning/tabBar/tabBar.js +4 -2
- package/src/lightning/tabset/tabset.css +2 -0
- package/src/lightning/tabset/tabset.js +35 -9
- package/src/lightning/tabset/tabset.slds.css +9 -0
- package/src/lightning/timepicker/form-element.slds.css +8 -0
- package/src/lightning/timepicker/timepicker.css +2 -2
- package/src/lightning/timepicker/timepicker.js +4 -2
- package/src/lightning/toast/button-icon.slds.css +9 -3
- package/src/lightning/toast/icon.slds.css +3 -3
- package/src/lightning/toast/toast.css +2 -2
- package/src/lightning/toast/toast.js +4 -2
- package/src/lightning/toastContainer/toastContainer.css +2 -2
- package/src/lightning/verticalNavigation/vertical-navigation.slds.css +1 -1
- package/src/lightning/verticalNavigation/verticalNavigation.css +2 -3
- package/src/lightning/verticalNavigation/verticalNavigation.js +3 -2
- package/src/lightning/verticalNavigationSection/verticalNavigationSection.css +2 -3
- package/src/lightning/verticalNavigationSection/verticalNavigationSection.js +3 -2
- /package/src/lightning/{input/emailUtil.js → inputUtils/email.js} +0 -0
- /package/src/lightning/{input → primitiveInputSimple}/normalize.js +0 -0
- /package/src/lightning/{input → primitiveInputSimple}/selection.js +0 -0
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import labelRequired from '@salesforce/label/LightningControl.required';
|
|
2
2
|
import labelPlaceholder from '@salesforce/label/LightningCombobox.placeholder';
|
|
3
3
|
import labelHelpTextAlternativeText from '@salesforce/label/LightningInput.helptextAlternativeText';
|
|
4
|
-
import {
|
|
4
|
+
import { api, track } from 'lwc';
|
|
5
|
+
import LightningShadowBaseClass from 'lightning/shadowBaseClassPrivate';
|
|
5
6
|
import { classSet, formatLabel } from 'lightning/utils';
|
|
6
7
|
import {
|
|
7
8
|
classListMutation,
|
|
@@ -29,7 +30,7 @@ const i18n = {
|
|
|
29
30
|
* A widget that provides an input field that is readonly,
|
|
30
31
|
* accompanied by a dropdown list of selectable options.
|
|
31
32
|
*/
|
|
32
|
-
export default class LightningCombobox extends
|
|
33
|
+
export default class LightningCombobox extends LightningShadowBaseClass {
|
|
33
34
|
static delegatesFocus = true;
|
|
34
35
|
static validationOptOut = ['class'];
|
|
35
36
|
|
|
@@ -95,6 +96,7 @@ export default class LightningCombobox extends LightningElement {
|
|
|
95
96
|
}
|
|
96
97
|
|
|
97
98
|
connectedCallback() {
|
|
99
|
+
super.connectedCallback();
|
|
98
100
|
this.classList.add('slds-form-element');
|
|
99
101
|
this.updateClassList();
|
|
100
102
|
this.interactingState = new InteractingState();
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
/**
|
|
7
7
|
* Invalid State
|
|
8
8
|
*/
|
|
9
|
-
:host([data-render-mode="shadow"][invalid]) [part
|
|
9
|
+
:host([data-render-mode="shadow"][invalid]) [part='combobox'] {
|
|
10
10
|
--slds-c-inputtext-color-border: var(--sds-g-color-error-base-50, #ea001e);
|
|
11
11
|
--slds-c-inputtext-sizing-border: var(--sds-g-sizing-border-1, 1px);
|
|
12
12
|
}
|
|
@@ -278,4 +278,12 @@
|
|
|
278
278
|
:host([data-render-mode="shadow"]) .slds-form-element_address .slds-form-element__row {
|
|
279
279
|
align-items: flex-end;
|
|
280
280
|
}
|
|
281
|
+
|
|
282
|
+
/* --------------------------------------- */
|
|
283
|
+
|
|
284
|
+
/* FORM ELEMENT: HIDDEN */
|
|
285
|
+
|
|
286
|
+
:host([data-render-mode="shadow"][variant~='label-hidden']) .slds-form-element__label {
|
|
287
|
+
display: none
|
|
288
|
+
}
|
|
281
289
|
}
|
|
@@ -84,6 +84,7 @@ import {
|
|
|
84
84
|
getActiveCellElement,
|
|
85
85
|
getDataRow,
|
|
86
86
|
FOCUS_CLASS,
|
|
87
|
+
updateActiveCellTabIndexAfterSync,
|
|
87
88
|
} from './keyboard';
|
|
88
89
|
import {
|
|
89
90
|
getRowNumberOffset,
|
|
@@ -333,6 +334,8 @@ export default class LightningDatatable extends LightningElement {
|
|
|
333
334
|
if (hasValidKeyField(this.state)) {
|
|
334
335
|
this.updateRowsAndCellIndexes(this.state);
|
|
335
336
|
}
|
|
337
|
+
|
|
338
|
+
updateActiveCellTabIndexAfterSync(this.state);
|
|
336
339
|
}
|
|
337
340
|
|
|
338
341
|
/**
|
|
@@ -1173,10 +1173,7 @@ export function updateTabIndexActiveCell(state, index = 0) {
|
|
|
1173
1173
|
}
|
|
1174
1174
|
|
|
1175
1175
|
// we need to check again because maybe there is no active cell after sync
|
|
1176
|
-
|
|
1177
|
-
const { rowIndex, colIndex } = getIndexesActiveCell(state);
|
|
1178
|
-
updateTabIndex(state, rowIndex, colIndex, index);
|
|
1179
|
-
}
|
|
1176
|
+
updateActiveCellTabIndexAfterSync(state, index);
|
|
1180
1177
|
return state;
|
|
1181
1178
|
}
|
|
1182
1179
|
|
|
@@ -1417,3 +1414,10 @@ function isActiveCellValid(state) {
|
|
|
1417
1414
|
}
|
|
1418
1415
|
return false;
|
|
1419
1416
|
}
|
|
1417
|
+
|
|
1418
|
+
export function updateActiveCellTabIndexAfterSync(state, index = 0) {
|
|
1419
|
+
if (state.activeCell && !isRowNavigationMode(state)) {
|
|
1420
|
+
const { rowIndex, colIndex } = getIndexesActiveCell(state);
|
|
1421
|
+
updateTabIndex(state, rowIndex, colIndex, index);
|
|
1422
|
+
}
|
|
1423
|
+
}
|
|
@@ -133,7 +133,7 @@ export function updateColumnSortingState(column, state) {
|
|
|
133
133
|
} else {
|
|
134
134
|
Object.assign(column, {
|
|
135
135
|
sorted: false,
|
|
136
|
-
sortAriaLabel: column.sortable ? '
|
|
136
|
+
sortAriaLabel: column.sortable ? 'other' : null,
|
|
137
137
|
sortedDirection: defaultSortDirection,
|
|
138
138
|
});
|
|
139
139
|
}
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
|
|
1
|
+
@import 'lightning/sldsCommon';
|
|
2
2
|
@import './input-text.slds.css';
|
|
3
|
-
@import './form-element.slds.css';
|
|
3
|
+
@import './form-element.slds.css';
|
|
@@ -7,7 +7,8 @@ import labelMinAndMaxRangeMessage from '@salesforce/label/LightningDateTimePicke
|
|
|
7
7
|
import labelRequired from '@salesforce/label/LightningControl.required';
|
|
8
8
|
import labelSelectDateFor from '@salesforce/label/LightningDateTimePicker.selectDateFor';
|
|
9
9
|
import labelHelpTextAlternativeText from '@salesforce/label/LightningInput.helptextAlternativeText';
|
|
10
|
-
import {
|
|
10
|
+
import { api, track } from 'lwc';
|
|
11
|
+
import LightningShadowBaseClass from 'lightning/shadowBaseClassPrivate';
|
|
11
12
|
import {
|
|
12
13
|
normalizeISODate,
|
|
13
14
|
parseFormattedDate,
|
|
@@ -63,7 +64,7 @@ const DATE_STYLE = {
|
|
|
63
64
|
LONG: 'long',
|
|
64
65
|
};
|
|
65
66
|
|
|
66
|
-
export default class LightningDatePicker extends
|
|
67
|
+
export default class LightningDatePicker extends LightningShadowBaseClass {
|
|
67
68
|
static delegatesFocus = true;
|
|
68
69
|
|
|
69
70
|
@track _disabled = false;
|
|
@@ -381,6 +382,7 @@ export default class LightningDatePicker extends LightningElement {
|
|
|
381
382
|
}
|
|
382
383
|
|
|
383
384
|
connectedCallback() {
|
|
385
|
+
super.connectedCallback();
|
|
384
386
|
this.connected = true;
|
|
385
387
|
|
|
386
388
|
this.keyboardInterface = this.datepickerKeyboardInterface();
|
|
@@ -750,7 +752,7 @@ export default class LightningDatePicker extends LightningElement {
|
|
|
750
752
|
const isAriaInvalid =
|
|
751
753
|
this.template.host.getAttribute('data-aria-invalid') ||
|
|
752
754
|
this._errorMessage;
|
|
753
|
-
return computeAriaInvalid(isAriaInvalid, this.
|
|
755
|
+
return computeAriaInvalid(isAriaInvalid, this.hasBadInput() || '');
|
|
754
756
|
}
|
|
755
757
|
|
|
756
758
|
get helptextAlternativeText() {
|
|
@@ -278,4 +278,12 @@
|
|
|
278
278
|
:host([data-render-mode="shadow"]) .slds-form-element_address .slds-form-element__row {
|
|
279
279
|
align-items: flex-end;
|
|
280
280
|
}
|
|
281
|
+
|
|
282
|
+
/* --------------------------------------- */
|
|
283
|
+
|
|
284
|
+
/* FORM ELEMENT: HIDDEN */
|
|
285
|
+
|
|
286
|
+
:host([data-render-mode="shadow"][variant~='label-hidden']) .slds-form-element__label {
|
|
287
|
+
display: none
|
|
288
|
+
}
|
|
281
289
|
}
|
|
@@ -102,7 +102,7 @@
|
|
|
102
102
|
/**
|
|
103
103
|
* Input Text
|
|
104
104
|
*/
|
|
105
|
-
:host([data-render-mode="shadow"]) [part
|
|
105
|
+
:host([data-render-mode="shadow"]) [part='input-text'] {
|
|
106
106
|
/* Host reassignments to composed slds-icon */
|
|
107
107
|
--slds-c-icon-color-foreground: var(
|
|
108
108
|
--slds-c-inputtext-icon-color-foreground,
|
|
@@ -148,23 +148,23 @@
|
|
|
148
148
|
/**
|
|
149
149
|
* Input Container
|
|
150
150
|
*/
|
|
151
|
-
:host([data-render-mode="shadow"]) [part
|
|
151
|
+
:host([data-render-mode="shadow"]) [part='input-container'] {
|
|
152
152
|
flex: 1 0 100%;
|
|
153
153
|
align-items: stretch;
|
|
154
154
|
}
|
|
155
155
|
|
|
156
|
-
:host([data-render-mode="shadow"]) [part
|
|
156
|
+
:host([data-render-mode="shadow"]) [part='input-container'][type~='range'] {
|
|
157
157
|
border: none;
|
|
158
158
|
display: inline-block;
|
|
159
159
|
}
|
|
160
160
|
|
|
161
|
-
:host([data-render-mode="shadow"]) [part
|
|
161
|
+
:host([data-render-mode="shadow"]) [part='input'][type~='range'] {
|
|
162
162
|
min-height: calc(1.875rem + (1px * 2));
|
|
163
163
|
margin: 0;
|
|
164
164
|
}
|
|
165
165
|
|
|
166
|
-
:host([data-render-mode="shadow"]) [part
|
|
167
|
-
[part
|
|
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
168
|
--sds-c-inputtext-color-border: var(--sds-g-color-brand-base-60, #1b96ff);
|
|
169
169
|
--sds-c-inputtext-shadow: 0 0 3px var(--sds-g-color-brand-base-50, #0176d3);
|
|
170
170
|
--sds-c-inputtext-color-background: var(--sds-g-color-neutral-base-100, #ffffff);
|
|
@@ -177,7 +177,7 @@
|
|
|
177
177
|
/**
|
|
178
178
|
* Input
|
|
179
179
|
*/
|
|
180
|
-
:host([data-render-mode="shadow"]) [part
|
|
180
|
+
:host([data-render-mode="shadow"]) [part='input'] {
|
|
181
181
|
padding-inline-start: var(
|
|
182
182
|
--slds-c-inputtext-spacing-inline-start,
|
|
183
183
|
var(--sds-g-spacing-3, 0.75rem));
|
|
@@ -191,8 +191,8 @@
|
|
|
191
191
|
/**
|
|
192
192
|
* Focus / active State
|
|
193
193
|
*/
|
|
194
|
-
:host([data-render-mode="shadow"]) [part
|
|
195
|
-
[part
|
|
194
|
+
:host([data-render-mode="shadow"]) [part="input-container"]:focus-within,:host([data-render-mode="shadow"])
|
|
195
|
+
[part="input-container"]:active {
|
|
196
196
|
--sds-c-inputtext-color-border: var(--sds-g-color-brand-base-60, #1b96ff);
|
|
197
197
|
--sds-c-inputtext-shadow: 0 0 3px var(--sds-g-color-brand-base-50, #0176d3);
|
|
198
198
|
--sds-c-inputtext-color-background: var(--sds-g-color-neutral-base-100, #ffffff);
|
|
@@ -203,7 +203,7 @@
|
|
|
203
203
|
/**
|
|
204
204
|
* Read Only State
|
|
205
205
|
*/
|
|
206
|
-
:host([data-render-mode="shadow"][readonly]) [part
|
|
206
|
+
:host([data-render-mode="shadow"][readonly]) [part='input-text'] {
|
|
207
207
|
--sds-c-inputtext-spacing-inline-start-readonly: 0;
|
|
208
208
|
--sds-c-inputtext-color-border-focus: transparent;
|
|
209
209
|
--slds-c-inputtext-color-border: transparent;
|
|
@@ -218,7 +218,7 @@
|
|
|
218
218
|
* tied to :host([aria-invalid]) which this subsystem does not use. Instead, it
|
|
219
219
|
* uses :host([invalid]).
|
|
220
220
|
*/
|
|
221
|
-
:host([data-render-mode="shadow"][invalid]) [part
|
|
221
|
+
:host([data-render-mode="shadow"][invalid]) [part='input-text'] {
|
|
222
222
|
--sds-c-inputtext-shadow: 0 0 0 var(--sds-g-sizing-border-1, 1px) inset
|
|
223
223
|
var(--sds-g-color-error-base-50, #ea001e);
|
|
224
224
|
--slds-c-inputtext-color-border: var(--sds-g-color-error-base-50, #ea001e);
|
|
@@ -231,7 +231,7 @@
|
|
|
231
231
|
* The following styling hooks are included in SDS and need to be reassigned
|
|
232
232
|
* here to prevent a bug with the focus state border and box-shadow
|
|
233
233
|
*/
|
|
234
|
-
:host([data-render-mode="shadow"][invalid]) [part
|
|
234
|
+
:host([data-render-mode="shadow"][invalid]) [part='input-container']:focus-within {
|
|
235
235
|
--sds-c-inputtext-shadow:
|
|
236
236
|
var(--sds-g-color-error-base-50, #ea001e) 0 0 0 var(--sds-g-sizing-border-1, 1px) inset,
|
|
237
237
|
0 0 var(--sds-g-sizing-border-3, 3px) var(--sds-g-color-brand-base-50, #0176d3);
|
|
@@ -243,7 +243,7 @@
|
|
|
243
243
|
*
|
|
244
244
|
* Both parts form the visible form control.
|
|
245
245
|
*/
|
|
246
|
-
:host([data-render-mode="shadow"][disabled]) [part
|
|
246
|
+
:host([data-render-mode="shadow"][disabled]) [part='input-container'],:host([data-render-mode="shadow"][disabled]) [part='input'] {
|
|
247
247
|
cursor: not-allowed;
|
|
248
248
|
--sds-c-inputtext-color-background: var(--sds-g-color-neutral-base-95, #f3f3f3);
|
|
249
249
|
--sds-c-inputtext-color-border: var(--sds-g-color-neutral-base-80, #c9c9c9);
|
|
@@ -253,10 +253,10 @@
|
|
|
253
253
|
/**
|
|
254
254
|
* Label
|
|
255
255
|
*
|
|
256
|
-
* Add [part
|
|
257
|
-
* avoid collisions with other components using [part
|
|
256
|
+
* Add [part='input-text'] to increase specificity and
|
|
257
|
+
* avoid collisions with other components using [part='label'] (e.g. slds-input-checkbox)
|
|
258
258
|
*/
|
|
259
|
-
:host([data-render-mode="shadow"]) [part
|
|
259
|
+
:host([data-render-mode="shadow"]) [part='input-text'] [part='label'] {
|
|
260
260
|
padding-block-start: var(--sds-g-spacing-1, 0.25rem);
|
|
261
261
|
padding-inline-end: var(--sds-g-spacing-2, 0.5rem);
|
|
262
262
|
color: var(
|
|
@@ -280,7 +280,7 @@
|
|
|
280
280
|
* so we don't add spacing to other icons composed in the component, e.g.,
|
|
281
281
|
* the icon in the inline help text.
|
|
282
282
|
*/
|
|
283
|
-
:host([data-render-mode="shadow"]) [part
|
|
283
|
+
:host([data-render-mode="shadow"]) [part='start'] {
|
|
284
284
|
--slds-c-icon-spacing-inline-end: var(--sds-g-spacing-2, 0.5rem);
|
|
285
285
|
}
|
|
286
286
|
|
|
@@ -297,11 +297,11 @@
|
|
|
297
297
|
* Ref: https://github.com/salesforce-ux/design-system-internal/blob/240-winter-23/ui/components/form-element/horizontal/_index.scss#L63
|
|
298
298
|
*/
|
|
299
299
|
@media (min-width: 48em) {
|
|
300
|
-
:host([data-render-mode="shadow"][variant~='label-inline']) [part
|
|
300
|
+
:host([data-render-mode="shadow"][variant~='label-inline']) [part='input-text'] {
|
|
301
301
|
display: block;
|
|
302
302
|
}
|
|
303
303
|
|
|
304
|
-
:host([data-render-mode="shadow"][variant~='label-inline']) [part
|
|
304
|
+
:host([data-render-mode="shadow"][variant~='label-inline']) [part='label'] {
|
|
305
305
|
float: left;
|
|
306
306
|
|
|
307
307
|
/* TODO: Get rid of these magic numbers */
|
|
@@ -309,11 +309,11 @@
|
|
|
309
309
|
padding-block-start: var(--sds-g-spacing-1, 0.25rem);
|
|
310
310
|
}
|
|
311
311
|
|
|
312
|
-
:host([data-render-mode="shadow"][variant~='label-inline']) [part
|
|
312
|
+
:host([data-render-mode="shadow"][variant~='label-inline']) [part='input-container'] {
|
|
313
313
|
margin-inline-start: 33%;
|
|
314
314
|
}
|
|
315
315
|
|
|
316
|
-
:host([data-render-mode="shadow"][variant~='label-inline']) [part
|
|
316
|
+
:host([data-render-mode="shadow"][variant~='label-inline']) [part='inline-help'] {
|
|
317
317
|
float: left;
|
|
318
318
|
padding-block-start: var(--sds-g-spacing-1, 0.25rem);
|
|
319
319
|
}
|
|
@@ -323,7 +323,7 @@
|
|
|
323
323
|
left: var(--sds-g-spacing-3, 0.75rem);
|
|
324
324
|
fill: var(--slds-g-color-neutral-base-50, #747474);
|
|
325
325
|
}
|
|
326
|
-
|
|
326
|
+
|
|
327
327
|
:host([data-render-mode="shadow"]) .slds-input-has-icon .slds-button_icon {
|
|
328
328
|
background-color: transparent;
|
|
329
329
|
}
|
|
@@ -375,7 +375,7 @@
|
|
|
375
375
|
--slds-c-inputtext-spacing-inline-start: var(--sds-g-spacing-6, 2rem);
|
|
376
376
|
--slds-c-inputtext-spacing-inline-end: var(--sds-g-spacing-6, 2rem);
|
|
377
377
|
}
|
|
378
|
-
|
|
378
|
+
|
|
379
379
|
/**
|
|
380
380
|
* A temporarily baked-in utility class until SLDS gets a proper utility package.
|
|
381
381
|
*
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
|
|
1
|
+
@import 'lightning/sldsCommon';
|
|
2
2
|
@import './input-text.slds.css';
|
|
3
|
-
@import './form-element.slds.css';
|
|
3
|
+
@import './form-element.slds.css';
|
|
@@ -4,7 +4,8 @@ import labelRangeUnderflow from '@salesforce/label/LightningDateTimePicker.range
|
|
|
4
4
|
import labelTime from '@salesforce/label/LightningDateTimePicker.timeLabel';
|
|
5
5
|
import labelHelpTextAlternativeText from '@salesforce/label/LightningInput.helptextAlternativeText';
|
|
6
6
|
import sfTimeZone from '@salesforce/i18n/timeZone';
|
|
7
|
-
import {
|
|
7
|
+
import { api, track } from 'lwc';
|
|
8
|
+
import LightningShadowBaseClass from 'lightning/shadowBaseClassPrivate';
|
|
8
9
|
import { classSet, formatLabel } from 'lightning/utils';
|
|
9
10
|
import {
|
|
10
11
|
normalizeBoolean,
|
|
@@ -34,7 +35,7 @@ const i18n = {
|
|
|
34
35
|
helpTextAlternativeText: labelHelpTextAlternativeText,
|
|
35
36
|
};
|
|
36
37
|
|
|
37
|
-
export default class LightningDateTimePicker extends
|
|
38
|
+
export default class LightningDateTimePicker extends LightningShadowBaseClass {
|
|
38
39
|
static delegatesFocus = true;
|
|
39
40
|
|
|
40
41
|
@track _disabled = false;
|
|
@@ -409,6 +410,7 @@ export default class LightningDateTimePicker extends LightningElement {
|
|
|
409
410
|
}
|
|
410
411
|
|
|
411
412
|
connectedCallback() {
|
|
413
|
+
super.connectedCallback();
|
|
412
414
|
this.connected = true;
|
|
413
415
|
|
|
414
416
|
// we set the initial values here in order to make sure timezone is available.
|
|
@@ -278,4 +278,12 @@
|
|
|
278
278
|
:host([data-render-mode="shadow"]) .slds-form-element_address .slds-form-element__row {
|
|
279
279
|
align-items: flex-end;
|
|
280
280
|
}
|
|
281
|
+
|
|
282
|
+
/* --------------------------------------- */
|
|
283
|
+
|
|
284
|
+
/* FORM ELEMENT: HIDDEN */
|
|
285
|
+
|
|
286
|
+
:host([data-render-mode="shadow"][variant~='label-hidden']) .slds-form-element__label {
|
|
287
|
+
display: none
|
|
288
|
+
}
|
|
281
289
|
}
|
|
@@ -102,7 +102,7 @@
|
|
|
102
102
|
/**
|
|
103
103
|
* Input Text
|
|
104
104
|
*/
|
|
105
|
-
:host([data-render-mode="shadow"]) [part
|
|
105
|
+
:host([data-render-mode="shadow"]) [part='input-text'] {
|
|
106
106
|
/* Host reassignments to composed slds-icon */
|
|
107
107
|
--slds-c-icon-color-foreground: var(
|
|
108
108
|
--slds-c-inputtext-icon-color-foreground,
|
|
@@ -148,23 +148,23 @@
|
|
|
148
148
|
/**
|
|
149
149
|
* Input Container
|
|
150
150
|
*/
|
|
151
|
-
:host([data-render-mode="shadow"]) [part
|
|
151
|
+
:host([data-render-mode="shadow"]) [part='input-container'] {
|
|
152
152
|
flex: 1 0 100%;
|
|
153
153
|
align-items: stretch;
|
|
154
154
|
}
|
|
155
155
|
|
|
156
|
-
:host([data-render-mode="shadow"]) [part
|
|
156
|
+
:host([data-render-mode="shadow"]) [part='input-container'][type~='range'] {
|
|
157
157
|
border: none;
|
|
158
158
|
display: inline-block;
|
|
159
159
|
}
|
|
160
160
|
|
|
161
|
-
:host([data-render-mode="shadow"]) [part
|
|
161
|
+
:host([data-render-mode="shadow"]) [part='input'][type~='range'] {
|
|
162
162
|
min-height: calc(1.875rem + (1px * 2));
|
|
163
163
|
margin: 0;
|
|
164
164
|
}
|
|
165
165
|
|
|
166
|
-
:host([data-render-mode="shadow"]) [part
|
|
167
|
-
[part
|
|
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
168
|
--sds-c-inputtext-color-border: var(--sds-g-color-brand-base-60, #1b96ff);
|
|
169
169
|
--sds-c-inputtext-shadow: 0 0 3px var(--sds-g-color-brand-base-50, #0176d3);
|
|
170
170
|
--sds-c-inputtext-color-background: var(--sds-g-color-neutral-base-100, #ffffff);
|
|
@@ -177,7 +177,7 @@
|
|
|
177
177
|
/**
|
|
178
178
|
* Input
|
|
179
179
|
*/
|
|
180
|
-
:host([data-render-mode="shadow"]) [part
|
|
180
|
+
:host([data-render-mode="shadow"]) [part='input'] {
|
|
181
181
|
padding-inline-start: var(
|
|
182
182
|
--slds-c-inputtext-spacing-inline-start,
|
|
183
183
|
var(--sds-g-spacing-3, 0.75rem));
|
|
@@ -191,8 +191,8 @@
|
|
|
191
191
|
/**
|
|
192
192
|
* Focus / active State
|
|
193
193
|
*/
|
|
194
|
-
:host([data-render-mode="shadow"]) [part
|
|
195
|
-
[part
|
|
194
|
+
:host([data-render-mode="shadow"]) [part="input-container"]:focus-within,:host([data-render-mode="shadow"])
|
|
195
|
+
[part="input-container"]:active {
|
|
196
196
|
--sds-c-inputtext-color-border: var(--sds-g-color-brand-base-60, #1b96ff);
|
|
197
197
|
--sds-c-inputtext-shadow: 0 0 3px var(--sds-g-color-brand-base-50, #0176d3);
|
|
198
198
|
--sds-c-inputtext-color-background: var(--sds-g-color-neutral-base-100, #ffffff);
|
|
@@ -203,7 +203,7 @@
|
|
|
203
203
|
/**
|
|
204
204
|
* Read Only State
|
|
205
205
|
*/
|
|
206
|
-
:host([data-render-mode="shadow"][readonly]) [part
|
|
206
|
+
:host([data-render-mode="shadow"][readonly]) [part='input-text'] {
|
|
207
207
|
--sds-c-inputtext-spacing-inline-start-readonly: 0;
|
|
208
208
|
--sds-c-inputtext-color-border-focus: transparent;
|
|
209
209
|
--slds-c-inputtext-color-border: transparent;
|
|
@@ -218,7 +218,7 @@
|
|
|
218
218
|
* tied to :host([aria-invalid]) which this subsystem does not use. Instead, it
|
|
219
219
|
* uses :host([invalid]).
|
|
220
220
|
*/
|
|
221
|
-
:host([data-render-mode="shadow"][invalid]) [part
|
|
221
|
+
:host([data-render-mode="shadow"][invalid]) [part='input-text'] {
|
|
222
222
|
--sds-c-inputtext-shadow: 0 0 0 var(--sds-g-sizing-border-1, 1px) inset
|
|
223
223
|
var(--sds-g-color-error-base-50, #ea001e);
|
|
224
224
|
--slds-c-inputtext-color-border: var(--sds-g-color-error-base-50, #ea001e);
|
|
@@ -231,7 +231,7 @@
|
|
|
231
231
|
* The following styling hooks are included in SDS and need to be reassigned
|
|
232
232
|
* here to prevent a bug with the focus state border and box-shadow
|
|
233
233
|
*/
|
|
234
|
-
:host([data-render-mode="shadow"][invalid]) [part
|
|
234
|
+
:host([data-render-mode="shadow"][invalid]) [part='input-container']:focus-within {
|
|
235
235
|
--sds-c-inputtext-shadow:
|
|
236
236
|
var(--sds-g-color-error-base-50, #ea001e) 0 0 0 var(--sds-g-sizing-border-1, 1px) inset,
|
|
237
237
|
0 0 var(--sds-g-sizing-border-3, 3px) var(--sds-g-color-brand-base-50, #0176d3);
|
|
@@ -243,7 +243,7 @@
|
|
|
243
243
|
*
|
|
244
244
|
* Both parts form the visible form control.
|
|
245
245
|
*/
|
|
246
|
-
:host([data-render-mode="shadow"][disabled]) [part
|
|
246
|
+
:host([data-render-mode="shadow"][disabled]) [part='input-container'],:host([data-render-mode="shadow"][disabled]) [part='input'] {
|
|
247
247
|
cursor: not-allowed;
|
|
248
248
|
--sds-c-inputtext-color-background: var(--sds-g-color-neutral-base-95, #f3f3f3);
|
|
249
249
|
--sds-c-inputtext-color-border: var(--sds-g-color-neutral-base-80, #c9c9c9);
|
|
@@ -253,10 +253,10 @@
|
|
|
253
253
|
/**
|
|
254
254
|
* Label
|
|
255
255
|
*
|
|
256
|
-
* Add [part
|
|
257
|
-
* avoid collisions with other components using [part
|
|
256
|
+
* Add [part='input-text'] to increase specificity and
|
|
257
|
+
* avoid collisions with other components using [part='label'] (e.g. slds-input-checkbox)
|
|
258
258
|
*/
|
|
259
|
-
:host([data-render-mode="shadow"]) [part
|
|
259
|
+
:host([data-render-mode="shadow"]) [part='input-text'] [part='label'] {
|
|
260
260
|
padding-block-start: var(--sds-g-spacing-1, 0.25rem);
|
|
261
261
|
padding-inline-end: var(--sds-g-spacing-2, 0.5rem);
|
|
262
262
|
color: var(
|
|
@@ -280,7 +280,7 @@
|
|
|
280
280
|
* so we don't add spacing to other icons composed in the component, e.g.,
|
|
281
281
|
* the icon in the inline help text.
|
|
282
282
|
*/
|
|
283
|
-
:host([data-render-mode="shadow"]) [part
|
|
283
|
+
:host([data-render-mode="shadow"]) [part='start'] {
|
|
284
284
|
--slds-c-icon-spacing-inline-end: var(--sds-g-spacing-2, 0.5rem);
|
|
285
285
|
}
|
|
286
286
|
|
|
@@ -297,11 +297,11 @@
|
|
|
297
297
|
* Ref: https://github.com/salesforce-ux/design-system-internal/blob/240-winter-23/ui/components/form-element/horizontal/_index.scss#L63
|
|
298
298
|
*/
|
|
299
299
|
@media (min-width: 48em) {
|
|
300
|
-
:host([data-render-mode="shadow"][variant~='label-inline']) [part
|
|
300
|
+
:host([data-render-mode="shadow"][variant~='label-inline']) [part='input-text'] {
|
|
301
301
|
display: block;
|
|
302
302
|
}
|
|
303
303
|
|
|
304
|
-
:host([data-render-mode="shadow"][variant~='label-inline']) [part
|
|
304
|
+
:host([data-render-mode="shadow"][variant~='label-inline']) [part='label'] {
|
|
305
305
|
float: left;
|
|
306
306
|
|
|
307
307
|
/* TODO: Get rid of these magic numbers */
|
|
@@ -309,11 +309,11 @@
|
|
|
309
309
|
padding-block-start: var(--sds-g-spacing-1, 0.25rem);
|
|
310
310
|
}
|
|
311
311
|
|
|
312
|
-
:host([data-render-mode="shadow"][variant~='label-inline']) [part
|
|
312
|
+
:host([data-render-mode="shadow"][variant~='label-inline']) [part='input-container'] {
|
|
313
313
|
margin-inline-start: 33%;
|
|
314
314
|
}
|
|
315
315
|
|
|
316
|
-
:host([data-render-mode="shadow"][variant~='label-inline']) [part
|
|
316
|
+
:host([data-render-mode="shadow"][variant~='label-inline']) [part='inline-help'] {
|
|
317
317
|
float: left;
|
|
318
318
|
padding-block-start: var(--sds-g-spacing-1, 0.25rem);
|
|
319
319
|
}
|
|
@@ -323,7 +323,7 @@
|
|
|
323
323
|
left: var(--sds-g-spacing-3, 0.75rem);
|
|
324
324
|
fill: var(--slds-g-color-neutral-base-50, #747474);
|
|
325
325
|
}
|
|
326
|
-
|
|
326
|
+
|
|
327
327
|
:host([data-render-mode="shadow"]) .slds-input-has-icon .slds-button_icon {
|
|
328
328
|
background-color: transparent;
|
|
329
329
|
}
|
|
@@ -375,7 +375,7 @@
|
|
|
375
375
|
--slds-c-inputtext-spacing-inline-start: var(--sds-g-spacing-6, 2rem);
|
|
376
376
|
--slds-c-inputtext-spacing-inline-end: var(--sds-g-spacing-6, 2rem);
|
|
377
377
|
}
|
|
378
|
-
|
|
378
|
+
|
|
379
379
|
/**
|
|
380
380
|
* A temporarily baked-in utility class until SLDS gets a proper utility package.
|
|
381
381
|
*
|
|
@@ -17,7 +17,8 @@ import labelLoadingText from '@salesforce/label/LightningCombobox.loadingText';
|
|
|
17
17
|
import labelMovedOptionsSingular from '@salesforce/label/LightningDualListbox.movedOptionsSingular';
|
|
18
18
|
import labelMovedOptionsPlural from '@salesforce/label/LightningDualListbox.movedOptionsPlural';
|
|
19
19
|
import labelHelpTextAlternativeText from '@salesforce/label/LightningInput.helptextAlternativeText';
|
|
20
|
-
import {
|
|
20
|
+
import { api, track } from 'lwc';
|
|
21
|
+
import LightningShadowBaseClass from 'lightning/shadowBaseClassPrivate';
|
|
21
22
|
import { handleKeyDownOnOption } from './keyboard';
|
|
22
23
|
import { classSet, formatLabel } from 'lightning/utils';
|
|
23
24
|
import {
|
|
@@ -59,7 +60,7 @@ const i18n = {
|
|
|
59
60
|
/**
|
|
60
61
|
* A pair of listboxes that enables multiple options to be selected and reordered.
|
|
61
62
|
*/
|
|
62
|
-
export default class LightningDualListbox extends
|
|
63
|
+
export default class LightningDualListbox extends LightningShadowBaseClass {
|
|
63
64
|
// Component attributes
|
|
64
65
|
/**
|
|
65
66
|
* Label for the source options listbox.
|
|
@@ -354,6 +355,7 @@ export default class LightningDualListbox extends LightningElement {
|
|
|
354
355
|
}
|
|
355
356
|
|
|
356
357
|
connectedCallback() {
|
|
358
|
+
super.connectedCallback();
|
|
357
359
|
this.classList.add('slds-form-element');
|
|
358
360
|
this.updateClassList();
|
|
359
361
|
this.keyboardInterface = this.selectKeyboardInterface();
|
|
@@ -278,4 +278,12 @@
|
|
|
278
278
|
:host([data-render-mode="shadow"]) .slds-form-element_address .slds-form-element__row {
|
|
279
279
|
align-items: flex-end;
|
|
280
280
|
}
|
|
281
|
+
|
|
282
|
+
/* --------------------------------------- */
|
|
283
|
+
|
|
284
|
+
/* FORM ELEMENT: HIDDEN */
|
|
285
|
+
|
|
286
|
+
:host([data-render-mode="shadow"][variant~='label-hidden']) .slds-form-element__label {
|
|
287
|
+
display: none
|
|
288
|
+
}
|
|
281
289
|
}
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { api } from 'lwc';
|
|
2
|
+
import LightningShadowBaseClass from 'lightning/shadowBaseClassPrivate';
|
|
2
3
|
import { classSet } from 'lightning/utils';
|
|
3
4
|
import { normalizeString as normalize } from 'lightning/utilsPrivate';
|
|
4
5
|
import eqHtml from './eq.html';
|
|
@@ -12,7 +13,7 @@ import defaultHtml from './default.html';
|
|
|
12
13
|
/**
|
|
13
14
|
* Represents various animated icons with different states.
|
|
14
15
|
*/
|
|
15
|
-
export default class LightningDynamicIcon extends
|
|
16
|
+
export default class LightningDynamicIcon extends LightningShadowBaseClass {
|
|
16
17
|
/**
|
|
17
18
|
* The alternative text used to describe the dynamic icon.
|
|
18
19
|
* This text should describe what's happening.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
@import './dynamic-icon-ellie.slds.css';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
@import './dynamic-icon-eq.slds.css';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
@import './dynamic-icon-score.slds.css';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
@import './dynamic-icon-strength.slds.css';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
@import './dynamic-icon-trend.slds.css';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
@import './dynamic-icon-waffle.slds.css';
|