lightning-base-components 1.21.3-alpha → 1.21.5-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 +49 -0
- package/package.json +96 -21
- package/scopedImports/@salesforce-label-LightningDatatable.showActions.js +1 -1
- package/scopedImports/@salesforce-label-LightningForm.controllerFieldsMessage.js +1 -0
- package/scopedImports/@salesforce-label-LightningForm.dependentFieldsHeader.js +1 -0
- package/scopedImports/@salesforce-label-LightningForm.dependentFieldsListHeading.js +1 -0
- package/scopedImports/@salesforce-label-LightningForm.generalDependentFieldsMessage.js +1 -0
- package/scopedImports/@salesforce-label-LightningForm.learnMore.js +1 -0
- package/scopedImports/@salesforce-label-LightningForm.okButton.js +1 -0
- package/scopedImports/@salesforce-label-LightningLookup.messageWhenSearchTermTooShort.js +1 -0
- package/scopedImports/@salesforce-label-LightningLookup.modalCancel.js +1 -0
- package/scopedImports/@salesforce-label-LightningLookup.modalSelect.js +1 -0
- package/scopedImports/@salesforce-label-LightningProgressIndicator.currentStage.js +1 -1
- package/scopedImports/@salesforce-label-LightningProgressIndicator.errorStage.js +1 -0
- package/scopedImports/@salesforce-label-LightningProgressIndicator.stageComplete.js +1 -1
- package/scopedImports/@salesforce-label-LightningProgressIndicator.stageNotStarted.js +1 -1
- package/src/lightning/accordion/__docs__/accordion.md +0 -4
- package/src/lightning/accordionSection/__docs__/accordionSection.md +0 -4
- package/src/lightning/avatar/__docs__/avatar.md +0 -4
- package/src/lightning/avatar/avatar.html +1 -0
- package/src/lightning/badge/__docs__/badge.md +0 -4
- package/src/lightning/badge/badge.html +3 -3
- package/src/lightning/barcodeScanner/__docs__/barcodeScanner.md +0 -4
- package/src/lightning/baseCombobox/baseCombobox.html +4 -1
- package/src/lightning/baseCombobox/baseCombobox.js +5 -18
- package/src/lightning/baseComboboxItem/baseComboboxItem.js +6 -10
- package/src/lightning/button/__docs__/button.md +5 -8
- package/src/lightning/button/button.js +3 -4
- package/src/lightning/buttonGroup/__docs__/buttonGroup.md +0 -4
- package/src/lightning/buttonIcon/__docs__/buttonIcon.md +1 -4
- package/src/lightning/buttonIcon/buttonIcon.html +1 -1
- package/src/lightning/buttonIcon/buttonIcon.js +18 -17
- package/src/lightning/buttonIconStateful/__docs__/buttonIconStateful.md +0 -4
- package/src/lightning/buttonMenu/__docs__/buttonMenu.md +0 -4
- package/src/lightning/buttonMenu/buttonMenu.css +5 -0
- package/src/lightning/buttonMenu/buttonMenu.js +2 -0
- package/src/lightning/buttonStateful/__docs__/buttonStateful.md +0 -4
- package/src/lightning/buttonStateful/buttonStateful.html +5 -3
- package/src/lightning/buttonStateful/buttonStateful.js +4 -0
- package/src/lightning/card/__docs__/card.md +0 -4
- package/src/lightning/card/card.js-meta.xml +3 -0
- package/src/lightning/carousel/__docs__/carousel.md +0 -4
- package/src/lightning/checkboxGroup/__docs__/checkboxGroup.md +0 -4
- package/src/lightning/colorPickerCustom/colorPickerCustom.js +12 -0
- package/src/lightning/colorPickerPanel/colorPickerPanel.js +11 -1
- package/src/lightning/combobox/__docs__/combobox.md +0 -4
- package/src/lightning/combobox/combobox.html +1 -0
- package/src/lightning/datatable/__examples__disabled/customComponentWrapper/customComponentWrapper.html +11 -0
- package/src/lightning/datatable/__examples__disabled/customComponentWrapper/customComponentWrapper.js +25 -0
- package/src/lightning/datatable/__examples__disabled/customComponentWrapper/generateData.js +15 -0
- package/src/lightning/datatable/__examples__disabled/myCustomTypeDatatable/customInput.html +4 -0
- package/src/lightning/datatable/__examples__disabled/myCustomTypeDatatable/myCustomTypeDatatable.js +17 -0
- package/src/lightning/datatable/__examples__disabled/myCustomTypeDatatable/nestedSimpleComponentParent.html +7 -0
- package/src/lightning/datatable/__examples__disabled/simpleComponentNested/simpleComponentNested.html +9 -0
- package/src/lightning/datatable/__examples__disabled/simpleComponentNested/simpleComponentNested.js +6 -0
- package/src/lightning/datatable/autoWidthStrategy.js +8 -36
- package/src/lightning/datatable/columnResizer.js +51 -161
- package/src/lightning/datatable/columnWidthManager.js +25 -81
- package/src/lightning/datatable/columns.js +180 -302
- package/src/lightning/datatable/datatable.js +454 -441
- package/src/lightning/datatable/errors.js +17 -29
- package/src/lightning/datatable/fixedWidthStrategy.js +7 -22
- package/src/lightning/datatable/headerActions.js +8 -38
- package/src/lightning/datatable/indexes.js +42 -0
- package/src/lightning/datatable/infiniteLoading.js +16 -35
- package/src/lightning/datatable/inlineEdit.js +126 -156
- package/src/lightning/datatable/keyboard.js +226 -282
- package/src/lightning/datatable/renderManager.js +0 -4
- package/src/lightning/datatable/resizeObserver.js +4 -13
- package/src/lightning/datatable/rowLevelActions.js +2 -2
- package/src/lightning/datatable/rowNumber.js +21 -59
- package/src/lightning/datatable/rowSelection.js +95 -178
- package/src/lightning/datatable/rowSelectionShared.js +13 -27
- package/src/lightning/datatable/rows.js +171 -418
- package/src/lightning/datatable/sort.js +16 -75
- package/src/lightning/datatable/templates/div/div.html +12 -4
- package/src/lightning/datatable/templates/div/div.lbc.synthetic.css +10 -16
- package/src/lightning/datatable/templates/table/table.html +15 -5
- package/src/lightning/datatable/tree.js +17 -35
- package/src/lightning/datatable/types.js +10 -31
- package/src/lightning/datatable/utils.js +48 -24
- package/src/lightning/datatable/virtualization.js +2 -5
- package/src/lightning/datatable/widthManagerShared.js +0 -20
- package/src/lightning/datatable/wrapText.js +29 -60
- package/src/lightning/dualListbox/__docs__/dualListbox.md +0 -4
- package/src/lightning/dualListbox/dualListbox.js +7 -8
- package/src/lightning/dynamicIcon/__docs__/dynamicIcon.md +0 -4
- package/src/lightning/formattedDateTime/__docs__/formattedDateTime.md +0 -4
- package/src/lightning/formattedLocation/__docs__/formattedLocation.md +0 -4
- package/src/lightning/formattedName/__docs__/formattedName.md +0 -4
- package/src/lightning/formattedName/formattedName.js +3 -2
- package/src/lightning/formattedName/formattedName.js-meta.xml +3 -0
- package/src/lightning/formattedNumber/__docs__/formattedNumber.md +0 -4
- package/src/lightning/formattedNumber/formattedNumber.js +3 -2
- package/src/lightning/formattedNumber/formattedNumber.js-meta.xml +3 -0
- package/src/lightning/formattedPhone/__docs__/formattedPhone.md +0 -4
- package/src/lightning/formattedRichText/richTextConfig.js +1 -0
- package/src/lightning/formattedText/__docs__/formattedText.md +0 -4
- package/src/lightning/formattedTime/__docs__/formattedTime.md +0 -4
- package/src/lightning/formattedUrl/__docs__/formattedUrl.md +0 -4
- package/src/lightning/helptext/helptext.css +7 -0
- package/src/lightning/helptext/helptext.js +3 -4
- package/src/lightning/icon/__docs__/icon.md +0 -4
- package/src/lightning/icon/icon.html +1 -1
- package/src/lightning/input/input.html +5 -0
- package/src/lightning/inputAddress/addressFormat.js +31 -4
- package/src/lightning/inputAddress/fieldsLayout.js +6 -0
- package/src/lightning/inputAddress/inputAddress.html +19 -1
- package/src/lightning/inputAddress/inputAddress.js +80 -3
- package/src/lightning/inputLocation/__docs__/inputLocation.md +0 -4
- package/src/lightning/internationalizationLibrary/address/AddressFormat.js +553 -610
- package/src/lightning/layout/__docs__/layout.md +0 -4
- package/src/lightning/layoutItem/__docs__/layoutItem.md +0 -4
- package/src/lightning/lookupAddress/lookupAddress.html +6 -1
- package/src/lightning/lookupAddress/lookupAddress.js +25 -0
- package/src/lightning/menuItem/__docs__/menuItem.md +0 -4
- package/src/lightning/menuSubheader/menu-subheader.slds.css +1 -1
- package/src/lightning/modal/__docs__/modal.md +10 -1
- package/src/lightning/modal/__modalUtils__/modalContainerTestConstants.js +3 -7
- package/src/lightning/modal/__modalUtils__/modalContainerTestMethods.js +39 -133
- package/src/lightning/modal/__modalUtils__/modalContainerTestMockData.js +1 -1
- package/src/lightning/modal/modal.js +1 -1
- package/src/lightning/modalBase/modalBase.html +15 -10
- package/src/lightning/modalBase/modalBase.js +132 -147
- package/src/lightning/modalBody/modalBody.css +6 -0
- package/src/lightning/modalHeader/modalHeader.html +16 -4
- package/src/lightning/modalHeader/modalHeader.js +61 -14
- package/src/lightning/pill/__docs__/pill.md +0 -4
- package/src/lightning/pill/link.html +1 -0
- package/src/lightning/pill/plain.html +1 -0
- package/src/lightning/pill/plainLink.html +1 -0
- package/src/lightning/pillContainer/__docs__/pillContainer.md +0 -4
- package/src/lightning/primitiveBubble/primitiveBubble.js +42 -0
- package/src/lightning/primitiveDatatableCell/primitiveDatatableCell.js +1 -1
- package/src/lightning/primitiveHeaderActions/primitiveHeaderActions.html +1 -1
- package/src/lightning/primitiveHeaderActions/primitiveHeaderActions.js +13 -0
- package/src/lightning/primitiveHeaderFactory/nonsortableHeader.html +19 -6
- package/src/lightning/primitiveHeaderFactory/sortableHeader.html +3 -1
- package/src/lightning/primitiveResizeHandler/primitiveResizeHandler.css +11 -0
- package/src/lightning/primitiveResizeHandler/primitiveResizeHandler.html +2 -1
- package/src/lightning/primitiveResizeHandler/primitiveResizeHandler.js +1 -0
- package/src/lightning/progressStep/base.html +5 -6
- package/src/lightning/progressStep/progressStep.js +14 -9
- package/src/lightning/prompt/__docs__/prompt.md +1 -1
- package/src/lightning/radioGroup/__docs__/radioGroup.md +0 -4
- package/src/lightning/relativeDateTime/__docs__/relativeDateTime.md +0 -4
- package/src/lightning/shadowBaseClassPrivate/shadowBaseClassPrivate.js +0 -2
- package/src/lightning/sldsCommon/sldsCommon.css +134 -98
- package/src/lightning/sldsUtilsAlignment/sldsUtilsAlignment.css +1 -1
- package/src/lightning/sldsUtilsBox/sldsUtilsBox.css +14 -13
- package/src/lightning/sldsUtilsGrid/sldsUtilsGrid.css +95 -92
- package/src/lightning/sldsUtilsHyphenation/sldsUtilsHyphenation.css +1 -1
- package/src/lightning/sldsUtilsMargin/sldsUtilsMargin.css +77 -75
- package/src/lightning/sldsUtilsPadding/sldsUtilsPadding.css +73 -73
- package/src/lightning/sldsUtilsSizing/sldsUtilsSizing.css +552 -558
- package/src/lightning/sldsUtilsVisibility/sldsUtilsVisibility.css +2 -2
- package/src/lightning/slider/__docs__/slider.md +0 -4
- package/src/lightning/spinner/__docs__/spinner.md +0 -4
- package/src/lightning/staticMap/staticMap.js +3 -2
- package/src/lightning/tab/__docs__/tab.md +0 -4
- package/src/lightning/tab/tab.js +6 -3
- package/src/lightning/tab/tab.js-meta.xml +3 -0
- package/src/lightning/tabBar/tabBar.js +10 -5
- package/src/lightning/tabset/__docs__/tabset.md +0 -4
- package/src/lightning/tabset/tabset.html +2 -0
- package/src/lightning/tabset/tabset.js-meta.xml +3 -0
- package/src/lightning/textarea/__docs__/textarea.md +0 -4
- package/src/lightning/textarea/textarea.js +6 -1
- package/src/lightning/tile/__docs__/tile.md +0 -4
- package/src/lightning/toastContainer/__docs__/toastContainer.md +3 -2
- package/src/lightning/tooltipLibrary/tooltipLibrary.js +24 -15
- package/src/lightning/tree/__docs__/tree.md +0 -4
- package/src/lightning/tree/tree.js +5 -1
- package/src/lightning/verticalNavigation/__docs__/verticalNavigation.md +0 -4
- package/src/lightning/verticalNavigation/vertical-navigation.slds.css +14 -0
- package/src/lightning/verticalNavigation/verticalNavigation.css +1 -1
- package/src/lightning/verticalNavigation/verticalNavigation.html +1 -1
- package/src/lightning/verticalNavigation/verticalNavigation.js +66 -28
- package/src/lightning/verticalNavigation/verticalNavigation.js-meta.xml +3 -0
- package/src/lightning/verticalNavigationItem/__docs__/verticalNavigationItem.md +0 -4
- package/src/lightning/verticalNavigationItem/vertical-navigation-item.slds.css +63 -0
- package/src/lightning/verticalNavigationItem/verticalNavigationItem.css +2 -3
- package/src/lightning/verticalNavigationItem/verticalNavigationItem.js +29 -15
- package/src/lightning/verticalNavigationItem/verticalNavigationItem.js-meta.xml +3 -0
- package/src/lightning/verticalNavigationItem/verticalNavigationItem.lbc.native.css +2 -0
- package/src/lightning/verticalNavigationItem/verticalNavigationItem.lbc.synthetic.css +3 -0
- package/src/lightning/verticalNavigationItemBadge/__docs__/verticalNavigationItemBadge.md +0 -4
- package/src/lightning/verticalNavigationItemBadge/badge.slds.css +76 -0
- package/src/lightning/verticalNavigationItemBadge/vertical-navigation-item.slds.css +63 -0
- package/src/lightning/verticalNavigationItemBadge/verticalNavigationItemBadge.css +2 -3
- package/src/lightning/verticalNavigationItemBadge/verticalNavigationItemBadge.html +1 -1
- package/src/lightning/verticalNavigationItemBadge/verticalNavigationItemBadge.js +28 -15
- package/src/lightning/verticalNavigationItemBadge/verticalNavigationItemBadge.js-meta.xml +3 -0
- package/src/lightning/verticalNavigationItemBadge/verticalNavigationItemBadge.lbc.native.css +5 -0
- package/src/lightning/verticalNavigationItemBadge/verticalNavigationItemBadge.lbc.synthetic.css +3 -0
- package/src/lightning/verticalNavigationItemIcon/__docs__/verticalNavigationItemIcon.md +0 -4
- package/src/lightning/verticalNavigationItemIcon/vertical-navigation-item.slds.css +63 -0
- package/src/lightning/verticalNavigationItemIcon/verticalNavigationItemIcon.css +2 -3
- package/src/lightning/verticalNavigationItemIcon/verticalNavigationItemIcon.js +29 -15
- package/src/lightning/verticalNavigationItemIcon/verticalNavigationItemIcon.js-meta.xml +3 -0
- package/src/lightning/verticalNavigationItemIcon/verticalNavigationItemIcon.lbc.native.css +3 -0
- package/src/lightning/verticalNavigationItemIcon/verticalNavigationItemIcon.lbc.synthetic.css +3 -0
- package/src/lightning/verticalNavigationOverflow/button.slds.css +503 -0
- package/src/lightning/verticalNavigationOverflow/vertical-navigation-item.slds.css +63 -0
- package/src/lightning/verticalNavigationOverflow/vertical-navigation-section.slds.css +17 -0
- package/src/lightning/verticalNavigationOverflow/verticalNavigationOverflow.css +2 -1
- package/src/lightning/verticalNavigationOverflow/verticalNavigationOverflow.html +2 -0
- package/src/lightning/verticalNavigationOverflow/verticalNavigationOverflow.js +18 -13
- package/src/lightning/verticalNavigationOverflow/verticalNavigationOverflow.js-meta.xml +3 -0
- package/src/lightning/verticalNavigationOverflow/verticalNavigationOverflow.lbc.native.css +5 -0
- package/src/lightning/verticalNavigationSection/vertical-navigation-section.slds.css +14 -14
- package/src/lightning/verticalNavigationSection/verticalNavigationSection.js-meta.xml +3 -0
- package/src/lightning/datatable/inlineEditShared.js +0 -26
- /package/src/lightning/datatable/{__examples__ → __examples__disabled}/customDatatableWrapper/customDatatableWrapper.html +0 -0
- /package/src/lightning/datatable/{__examples__ → __examples__disabled}/customDatatableWrapper/customDatatableWrapper.js +0 -0
- /package/src/lightning/datatable/{__examples__ → __examples__disabled}/customDatatypeDeleteRowBtn/customDatatypeDeleteRowBtn.html +0 -0
- /package/src/lightning/datatable/{__examples__ → __examples__disabled}/customDatatypeDeleteRowBtn/customDatatypeDeleteRowBtn.js +0 -0
- /package/src/lightning/datatable/{__examples__ → __examples__disabled}/customDatatypeLink/customDatatypeLink.html +0 -0
- /package/src/lightning/datatable/{__examples__ → __examples__disabled}/customDatatypeLink/customDatatypeLink.js +0 -0
- /package/src/lightning/datatable/{__examples__ → __examples__disabled}/customDatatypeNumber/customDatatypeNumber.html +0 -0
- /package/src/lightning/datatable/{__examples__ → __examples__disabled}/customDatatypeNumber/customDatatypeNumber.js +0 -0
- /package/src/lightning/datatable/{__examples__ → __examples__disabled}/customDatatypeRowOrderingBtn/customDatatypeRowOrderingBtn.html +0 -0
- /package/src/lightning/datatable/{__examples__ → __examples__disabled}/customDatatypeRowOrderingBtn/customDatatypeRowOrderingBtn.js +0 -0
- /package/src/lightning/datatable/{__examples__ → __examples__disabled}/customDatatypeTable/customDatatypeTable.js +0 -0
- /package/src/lightning/datatable/{__examples__ → __examples__disabled}/customDatatypeTable/customLink.html +0 -0
- /package/src/lightning/datatable/{__examples__ → __examples__disabled}/customDatatypeTable/customName.html +0 -0
- /package/src/lightning/datatable/{__examples__ → __examples__disabled}/customDatatypeTable/customNumber.html +0 -0
- /package/src/lightning/datatable/{__examples__ → __examples__disabled}/customDatatypeTable/customNumberEdit.html +0 -0
- /package/src/lightning/datatable/{__examples__ → __examples__disabled}/customDatatypeTable/deleteRow.html +0 -0
- /package/src/lightning/datatable/{__examples__ → __examples__disabled}/customDatatypeTable/iconPill.html +0 -0
- /package/src/lightning/datatable/{__examples__ → __examples__disabled}/customDatatypeTable/orderingButtons.html +0 -0
- /package/src/lightning/datatable/{__examples__ → __examples__disabled}/customNestedComponent/customNestedComponent.html +0 -0
- /package/src/lightning/datatable/{__examples__ → __examples__disabled}/customNestedComponent/customNestedComponent.js +0 -0
|
@@ -43,10 +43,9 @@ export default class LightningButton extends LightningPrimitiveButton {
|
|
|
43
43
|
@api label;
|
|
44
44
|
|
|
45
45
|
/**
|
|
46
|
-
* Reserved for internal use only.
|
|
47
|
-
*
|
|
48
|
-
*
|
|
49
|
-
* be set to 0 if button should be focused.
|
|
46
|
+
* Reserved for internal use only. Use the global tabindex attribute instead.
|
|
47
|
+
* Set tab index to -1 to prevent focus on the button during tab navigation.
|
|
48
|
+
* The default value is 0, which makes the button focusable during tab navigation.
|
|
50
49
|
* @type {number}
|
|
51
50
|
*/
|
|
52
51
|
@api tabIndex;
|
|
@@ -73,10 +73,6 @@ To apply additional styling, use SLDS [utility classes](https://www.lightningdes
|
|
|
73
73
|
|
|
74
74
|
You can customize the `lightning-button-*` base components you use within `lightning-button-group` using SLDS styling hooks. For more information, see the corresponding base component documentation.
|
|
75
75
|
|
|
76
|
-
#### Source Code
|
|
77
|
-
|
|
78
|
-
`lightning-button-group` is available in the [Base Components Recipes GitHub repository](https://github.com/salesforce/base-components-recipes#documentation). It's transpiled into the `c` namespace so that you can use it in your own projects.
|
|
79
|
-
|
|
80
76
|
#### See Also
|
|
81
77
|
|
|
82
78
|
[lightning-navigation](bundle/lightning-navigation/documentation)
|
|
@@ -205,9 +205,6 @@ Use the following accessibility and `aria` attributes on `lightning-button-icon`
|
|
|
205
205
|
| aria-haspopup | token | Indicates that the button has an interactive popup element. Valid values are 'true', 'dialog', 'menu', 'listbox', 'tree', and 'grid'. To create a button that displays a list of menu items when clicked, use `lightning-button-menu` instead. |
|
|
206
206
|
| aria-label | string | Provides an assistive label where a visible label cannot be used. |
|
|
207
207
|
| aria-live | token | Indicates the button can dynamically update without a page reload, and specifies how the change is announced by assistive technologies. Possible values include `off`, `polite`, and `assertive`. The default is `off`. For the screen reader to announce changes when the user is idle, use `polite`. For immediate notifications, use `assertive`. |
|
|
208
|
+
| tabindex | integer | Specifies whether the button is focusable during tab navigation. Set tab index to -1 to prevent focus on the button during tab navigation. The default value is 0, which makes the button focusable during tab navigation. For more information, see [tabindex](https://developer.mozilla.org/en-US/docs/Web/HTML/Global_attributes/tabindex). |
|
|
208
209
|
|
|
209
210
|
For more information, see the [WAI-ARIA Specification](https://www.w3.org/TR/wai-aria/).
|
|
210
|
-
|
|
211
|
-
#### Source Code
|
|
212
|
-
|
|
213
|
-
`lightning-button-icon` is available in the [Base Components Recipes GitHub repository](https://github.com/salesforce/base-components-recipes#documentation). It's transpiled into the `c` namespace so that you can use it in your own projects.
|
|
@@ -16,7 +16,7 @@
|
|
|
16
16
|
part="button button-icon"
|
|
17
17
|
tabindex={tabIndex}>
|
|
18
18
|
|
|
19
|
-
<lightning-primitive-icon icon-name={iconName} svg-class={computedIconClass} variant="bare"></lightning-primitive-icon>
|
|
19
|
+
<lightning-primitive-icon icon-name={iconName} svg-class={computedIconClass} variant="bare" exportparts="icon"></lightning-primitive-icon>
|
|
20
20
|
|
|
21
21
|
<template if:true={alternativeText}>
|
|
22
22
|
<span class="slds-assistive-text">{alternativeText}</span>
|
|
@@ -35,14 +35,15 @@ export default class LightningButtonIcon extends LightningPrimitiveButton {
|
|
|
35
35
|
@api value;
|
|
36
36
|
|
|
37
37
|
/**
|
|
38
|
-
* Reserved for internal use only.
|
|
39
|
-
*
|
|
40
|
-
*
|
|
41
|
-
* be set to 0 if button should be focused.
|
|
38
|
+
* Reserved for internal use only. Use the global tabindex attribute instead.
|
|
39
|
+
* Set tab index to -1 to prevent focus on the button during tab navigation.
|
|
40
|
+
* The default value is 0, which makes the button focusable during tab navigation.
|
|
42
41
|
* @type {number}
|
|
43
42
|
*/
|
|
44
43
|
@api tabIndex;
|
|
45
44
|
|
|
45
|
+
_variant = DEFAULT_VARIANT;
|
|
46
|
+
|
|
46
47
|
/**
|
|
47
48
|
* The variant changes the appearance of button-icon.
|
|
48
49
|
* Accepted variants include bare, container, brand, border, border-filled, bare-inverse, and border-inverse.
|
|
@@ -51,11 +52,11 @@ export default class LightningButtonIcon extends LightningPrimitiveButton {
|
|
|
51
52
|
* @type {string}
|
|
52
53
|
* @default border
|
|
53
54
|
*/
|
|
54
|
-
_variant = DEFAULT_VARIANT;
|
|
55
55
|
@api
|
|
56
56
|
get variant() {
|
|
57
57
|
return this._originalVariant;
|
|
58
58
|
}
|
|
59
|
+
|
|
59
60
|
set variant(val) {
|
|
60
61
|
this._originalVariant = val;
|
|
61
62
|
this._variant = this.normalizeVariant(val);
|
|
@@ -82,6 +83,8 @@ export default class LightningButtonIcon extends LightningPrimitiveButton {
|
|
|
82
83
|
*/
|
|
83
84
|
@api iconClass;
|
|
84
85
|
|
|
86
|
+
_size = DEFAULT_SIZE;
|
|
87
|
+
|
|
85
88
|
/**
|
|
86
89
|
* The size of the button-icon. For the bare variant, options include x-small, small, medium, and large.
|
|
87
90
|
* For non-bare variants, options include xx-small, x-small, small, and medium.
|
|
@@ -90,8 +93,6 @@ export default class LightningButtonIcon extends LightningPrimitiveButton {
|
|
|
90
93
|
* @type {string}
|
|
91
94
|
* @default medium
|
|
92
95
|
*/
|
|
93
|
-
_size = DEFAULT_SIZE;
|
|
94
|
-
|
|
95
96
|
@api
|
|
96
97
|
get size() {
|
|
97
98
|
return this._originalSize;
|
|
@@ -119,16 +120,6 @@ export default class LightningButtonIcon extends LightningPrimitiveButton {
|
|
|
119
120
|
*/
|
|
120
121
|
@api alternativeText;
|
|
121
122
|
|
|
122
|
-
// remove-next-line-for-c-namespace
|
|
123
|
-
set tooltip(value) {
|
|
124
|
-
this.tooltipValue = value;
|
|
125
|
-
if (this._tooltip) {
|
|
126
|
-
this._tooltip.value = value;
|
|
127
|
-
} else if (value && this.rendered) {
|
|
128
|
-
this.createTooltip(value);
|
|
129
|
-
}
|
|
130
|
-
}
|
|
131
|
-
|
|
132
123
|
// remove-next-line-for-c-namespace
|
|
133
124
|
/**
|
|
134
125
|
* Text to display when the user mouses over or focuses on the button.
|
|
@@ -141,6 +132,16 @@ export default class LightningButtonIcon extends LightningPrimitiveButton {
|
|
|
141
132
|
return this._tooltip ? this._tooltip.value : undefined;
|
|
142
133
|
}
|
|
143
134
|
|
|
135
|
+
// remove-next-line-for-c-namespace
|
|
136
|
+
set tooltip(value) {
|
|
137
|
+
this.tooltipValue = value;
|
|
138
|
+
if (this._tooltip) {
|
|
139
|
+
this._tooltip.value = value;
|
|
140
|
+
} else if (value && this.rendered) {
|
|
141
|
+
this.createTooltip(value);
|
|
142
|
+
}
|
|
143
|
+
}
|
|
144
|
+
|
|
144
145
|
// remove-next-line-for-c-namespace
|
|
145
146
|
_tooltip = null;
|
|
146
147
|
tooltipValue = null;
|
|
@@ -179,7 +179,3 @@ Use the following accessibility and `aria` attributes on `lightning-button-icon-
|
|
|
179
179
|
| aria-live | string | Indicates whether the button will be updated, and describes the types of updates assistive technologies will make. Possible values include `off`, `polite`, and `assertive`. The default is `off`. For the screen reader to announce changes when the user is idle, use `polite`. For immediate notifications, use `assertive`. |
|
|
180
180
|
|
|
181
181
|
For more information, see the [WAI-ARIA Specification](https://www.w3.org/TR/wai-aria/).
|
|
182
|
-
|
|
183
|
-
#### Source Code
|
|
184
|
-
|
|
185
|
-
`lightning-button-icon-stateful` is available in the [Base Components Recipes GitHub repository](https://github.com/salesforce/base-components-recipes#documentation). It's transpiled into the `c` namespace so that you can use it in your own projects.
|
|
@@ -327,7 +327,3 @@ The event properties are as follows.
|
|
|
327
327
|
| bubbles | false | This event does not bubble. |
|
|
328
328
|
| cancelable | false | This event has no default behavior that can be canceled. You cannot call `preventDefault()` on this event. |
|
|
329
329
|
| composed | false | This event does not propagate outside of the component in which it was dispatched. |
|
|
330
|
-
|
|
331
|
-
#### Source Code
|
|
332
|
-
|
|
333
|
-
`lightning-button-menu` is available in the [Base Components Recipes GitHub repository](https://github.com/salesforce/base-components-recipes#documentation). It's transpiled into the `c` namespace so that you can use it in your own projects.
|
|
@@ -473,6 +473,8 @@ export default class LightningButtonMenu extends LightningShadowBaseClass {
|
|
|
473
473
|
this.variant === 'border' && isDropdownIcon,
|
|
474
474
|
'slds-button_icon-border-filled':
|
|
475
475
|
this.variant === 'border-filled',
|
|
476
|
+
'fix-slds-button_icon-border-filled':
|
|
477
|
+
this.variant === 'border-filled' && this.groupOrder !== '',
|
|
476
478
|
'slds-button_icon-border-inverse':
|
|
477
479
|
this.variant === 'border-inverse',
|
|
478
480
|
'slds-button_icon-inverse': this.variant === 'bare-inverse',
|
|
@@ -162,7 +162,3 @@ This component has usage differences from its Aura counterpart. See [Base Compon
|
|
|
162
162
|
This component uses `aria-live="polite"`, which means the button label is read after the current user task or content.
|
|
163
163
|
|
|
164
164
|
To inform screen readers that a button is disabled, set the `disabled` attribute to true.
|
|
165
|
-
|
|
166
|
-
#### Source Code
|
|
167
|
-
|
|
168
|
-
`lightning-button-stateful` is available in the [Base Components Recipes GitHub repository](https://github.com/salesforce/base-components-recipes#documentation). It's transpiled into the `c` namespace so that you can use it in your own projects.
|
|
@@ -4,24 +4,26 @@
|
|
|
4
4
|
onblur={handleButtonBlur}
|
|
5
5
|
onclick={handleButtonClick}
|
|
6
6
|
aria-live="polite"
|
|
7
|
+
aria-relevant="additions"
|
|
8
|
+
aria-pressed={computedAriaPressed}
|
|
7
9
|
part="button"
|
|
8
10
|
disabled={disabled}>
|
|
9
11
|
|
|
10
12
|
<span class="slds-text-not-selected">
|
|
11
13
|
<template if:true={iconNameWhenOff}>
|
|
12
|
-
<lightning-primitive-icon part="start" icon-name={iconNameWhenOff} svg-class="slds-button__icon_stateful slds-button__icon_left" variant="bare"></lightning-primitive-icon>
|
|
14
|
+
<lightning-primitive-icon aria-hidden="true" part="start" icon-name={iconNameWhenOff} svg-class="slds-button__icon_stateful slds-button__icon_left" variant="bare"></lightning-primitive-icon>
|
|
13
15
|
</template>
|
|
14
16
|
{privateLabelWhenOff}
|
|
15
17
|
</span>
|
|
16
18
|
<span class="slds-text-selected">
|
|
17
19
|
<template if:true={iconNameWhenOn}>
|
|
18
|
-
<lightning-primitive-icon part="start" icon-name={iconNameWhenOn} svg-class="slds-button__icon_stateful slds-button__icon_left" variant="bare"></lightning-primitive-icon>
|
|
20
|
+
<lightning-primitive-icon aria-hidden="true" part="start" icon-name={iconNameWhenOn} svg-class="slds-button__icon_stateful slds-button__icon_left" variant="bare"></lightning-primitive-icon>
|
|
19
21
|
</template>
|
|
20
22
|
{privateLabelWhenOn}
|
|
21
23
|
</span>
|
|
22
24
|
<span class="slds-text-selected-focus">
|
|
23
25
|
<template if:true={privateIconNameWhenHover}>
|
|
24
|
-
<lightning-primitive-icon part="start" icon-name={privateIconNameWhenHover} svg-class="slds-button__icon_stateful slds-button__icon_left" variant="bare"></lightning-primitive-icon>
|
|
26
|
+
<lightning-primitive-icon aria-hidden="true" part="start" icon-name={privateIconNameWhenHover} svg-class="slds-button__icon_stateful slds-button__icon_left" variant="bare"></lightning-primitive-icon>
|
|
25
27
|
</template>
|
|
26
28
|
{privateLabelWhenHover}
|
|
27
29
|
</span>
|
|
@@ -239,6 +239,10 @@ export default class LightningButtonStateful extends LightningShadowBaseClass {
|
|
|
239
239
|
this.dispatchEvent(new CustomEvent('focus'));
|
|
240
240
|
}
|
|
241
241
|
|
|
242
|
+
get computedAriaPressed() {
|
|
243
|
+
return String(this.state.selected);
|
|
244
|
+
}
|
|
245
|
+
|
|
242
246
|
// validate a label is a string and not zero length
|
|
243
247
|
isValidLabel(labelVal) {
|
|
244
248
|
// if not a string or of length 0 then label is not valid
|
|
@@ -108,7 +108,3 @@ To understand how we implemented SLDS in `lightning-card`, see the **Source Code
|
|
|
108
108
|
Icons are not available in Lightning Out, but they are available in Lightning Components for Visualforce and other experiences.
|
|
109
109
|
|
|
110
110
|
This component has usage differences from its Aura counterpart. See [Base Components: Aura Vs Lightning Web Components](https://developer.salesforce.com/docs/platform/lwc/guide/migrate-map-aura-lwc-components) in the Lightning Web Components Developer Guide.
|
|
111
|
-
|
|
112
|
-
#### Source Code
|
|
113
|
-
|
|
114
|
-
`lightning-card` is available in the [Base Components Recipes GitHub repository](https://github.com/salesforce/base-components-recipes#documentation). It's transpiled into the `c` namespace so that you can use it in your own projects.
|
|
@@ -88,7 +88,3 @@ This example creates a basic carousel with three images and disables automatic s
|
|
|
88
88
|
|
|
89
89
|
Use the Tab key to move focus to the carousel, then tab again to focus on the indicator buttons.
|
|
90
90
|
Use right and left arrow keys to scroll to the next or previous image.
|
|
91
|
-
|
|
92
|
-
#### Source Code
|
|
93
|
-
|
|
94
|
-
`lightning-carousel` is available in the [Base Components Recipes GitHub repository](https://github.com/salesforce/base-components-recipes#documentation). It's transpiled into the `c` namespace so that you can use it in your own projects.
|
|
@@ -194,7 +194,3 @@ element. The legend contains the `label` value. The `fieldset` element enables
|
|
|
194
194
|
grouping of related checkboxes to facilitate tabbing navigation and speech
|
|
195
195
|
navigation for accessibility purposes. Similarly, the `legend` element
|
|
196
196
|
improves accessibility by enabling a caption to be assigned to the `fieldset`.
|
|
197
|
-
|
|
198
|
-
#### Source Code
|
|
199
|
-
|
|
200
|
-
`lightning-checkbox-group` is available in the [Base Components Recipes GitHub repository](https://github.com/salesforce/base-components-recipes#documentation). It's transpiled into the `c` namespace so that you can use it in your own projects.
|
|
@@ -95,6 +95,18 @@ export default class LightningColorPickerCustom extends LightningShadowBaseClass
|
|
|
95
95
|
this._currentColor = value;
|
|
96
96
|
this._hex = fullHex;
|
|
97
97
|
this._rgb = hexToRgb(fullHex);
|
|
98
|
+
|
|
99
|
+
// W-13851481 bug-fix: if canvas open, update it
|
|
100
|
+
if (this._canvas) {
|
|
101
|
+
const hue = rgbToHsl(this._rgb).hue;
|
|
102
|
+
const position = this.rgbToPosition(this._rgb);
|
|
103
|
+
const selectedColor = `#${rgbToHex(this._rgb)}`;
|
|
104
|
+
|
|
105
|
+
this.updateRainbow(hue);
|
|
106
|
+
this.setCanvasColor(hue);
|
|
107
|
+
this.setCanvasCursor(position.x, position.y);
|
|
108
|
+
this.updateSelectedColor(selectedColor);
|
|
109
|
+
}
|
|
98
110
|
}
|
|
99
111
|
|
|
100
112
|
@api
|
|
@@ -5,7 +5,7 @@ import labelDoneButton from '@salesforce/label/LightningColorPicker.doneButton';
|
|
|
5
5
|
import { api, track } from 'lwc';
|
|
6
6
|
import LightningShadowBaseClass from 'lightning/shadowBaseClassPrivate';
|
|
7
7
|
import { classSet } from 'lightning/utils';
|
|
8
|
-
import { keyCodes } from 'lightning/utilsPrivate';
|
|
8
|
+
import { keyCodes, isCSR } from 'lightning/utilsPrivate';
|
|
9
9
|
|
|
10
10
|
const i18n = {
|
|
11
11
|
cancelButton: labelCancelButton,
|
|
@@ -26,6 +26,16 @@ export default class LightningColorPickerPanel extends LightningShadowBaseClass
|
|
|
26
26
|
this._selectedColor = this.currentColor || DEFAULT_COLOR;
|
|
27
27
|
}
|
|
28
28
|
|
|
29
|
+
renderedCallback() {
|
|
30
|
+
// W-14600421 bug fix: prevent panel from falling outside user focus,
|
|
31
|
+
// like when viewports are too small
|
|
32
|
+
if (isCSR && typeof document.body.scrollIntoView === 'function') {
|
|
33
|
+
this.template
|
|
34
|
+
.querySelector('lightning-color-picker-custom')
|
|
35
|
+
.scrollIntoView();
|
|
36
|
+
}
|
|
37
|
+
}
|
|
38
|
+
|
|
29
39
|
get i18n() {
|
|
30
40
|
return i18n;
|
|
31
41
|
}
|
|
@@ -156,7 +156,3 @@ The `open` event does not return any parameters.
|
|
|
156
156
|
| bubbles | false | This event does not bubble. |
|
|
157
157
|
| cancelable | false | This event has no default behavior that can be canceled. You cannot call `preventDefault()` on this event. |
|
|
158
158
|
| composed | false | This event does not propagate outside of the component in which it was dispatched. |
|
|
159
|
-
|
|
160
|
-
#### Source Code
|
|
161
|
-
|
|
162
|
-
`lightning-combobox` is available in the [Base Components Recipes GitHub repository](https://github.com/salesforce/base-components-recipes#documentation). It's transpiled into the `c` namespace so that you can use it in your own projects.
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<!-- Move this component to __examples__ -->
|
|
3
|
+
<!-- In playground add <datatable-custom-component-wrapper></datatable-custom-component-wrapper> -->
|
|
4
|
+
<datatable-my-custom-type-datatable
|
|
5
|
+
key-field="Id"
|
|
6
|
+
data={data}
|
|
7
|
+
columns={columns}
|
|
8
|
+
show-row-number-column
|
|
9
|
+
>
|
|
10
|
+
</datatable-my-custom-type-datatable>
|
|
11
|
+
</template>
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { LightningElement } from 'lwc';
|
|
2
|
+
import generateData from './generateData.js';
|
|
3
|
+
const columns = [
|
|
4
|
+
{
|
|
5
|
+
label: 'Custom input',
|
|
6
|
+
type: 'customInput',
|
|
7
|
+
},
|
|
8
|
+
{
|
|
9
|
+
label: 'Custom Component Buttons',
|
|
10
|
+
type: 'customComponent',
|
|
11
|
+
},
|
|
12
|
+
{ label: 'Label', fieldName: 'name' },
|
|
13
|
+
{ label: 'Website', fieldName: 'website', type: 'url' },
|
|
14
|
+
{ label: 'Phone', fieldName: 'phone', type: 'phone' },
|
|
15
|
+
{ label: 'Balance', fieldName: 'amount', type: 'currency' },
|
|
16
|
+
];
|
|
17
|
+
export default class MyDatatable extends LightningElement {
|
|
18
|
+
data = [];
|
|
19
|
+
columns = columns;
|
|
20
|
+
rowOffset = 0;
|
|
21
|
+
|
|
22
|
+
connectedCallback() {
|
|
23
|
+
this.data = generateData({ amountOfRecords: 5 });
|
|
24
|
+
}
|
|
25
|
+
}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
export default function generateData({ amountOfRecords }) {
|
|
2
|
+
return [...Array(amountOfRecords)].map((_, index) => {
|
|
3
|
+
return {
|
|
4
|
+
name: `Name (${index})`,
|
|
5
|
+
website: 'www.salesforce.com',
|
|
6
|
+
amount: Math.floor(Math.random() * 100),
|
|
7
|
+
phone: `${
|
|
8
|
+
Math.floor(Math.random() * 900 + 100) * 10000000 + 5551212
|
|
9
|
+
}`,
|
|
10
|
+
closeAt: new Date(
|
|
11
|
+
Date.now() + 86400000 * Math.ceil(Math.random() * 20)
|
|
12
|
+
),
|
|
13
|
+
};
|
|
14
|
+
});
|
|
15
|
+
}
|
package/src/lightning/datatable/__examples__disabled/myCustomTypeDatatable/myCustomTypeDatatable.js
ADDED
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
//myCustomTypeDatatable.js
|
|
2
|
+
import LightningDatatable from 'lightning/datatable';
|
|
3
|
+
import customInputTemplate from './customInput.html';
|
|
4
|
+
import customComponentTemplate from './nestedSimpleComponentParent.html';
|
|
5
|
+
|
|
6
|
+
export default class MyCustomTypeDatatable extends LightningDatatable {
|
|
7
|
+
static customTypes = {
|
|
8
|
+
customInput: {
|
|
9
|
+
template: customInputTemplate,
|
|
10
|
+
standardCellLayout: true,
|
|
11
|
+
},
|
|
12
|
+
customComponent: {
|
|
13
|
+
template: customComponentTemplate,
|
|
14
|
+
standardCellLayout: false,
|
|
15
|
+
},
|
|
16
|
+
};
|
|
17
|
+
}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<!-- We add an internal component here so that we can garner access to a full LWC component including access to a JS file. -->
|
|
3
|
+
<!-- This is common if a custom component needs some kind of wiring up. -->
|
|
4
|
+
<!-- We pass tabindex down as we don't want this component to be shown as accessible in the dom, but we want children of it to be -->
|
|
5
|
+
<!-- We set data-navigation here as this component has children that are navigable -->
|
|
6
|
+
<datatable-simple-component-nested internal-tab-index={internalTabIndex} data-navigation="enable"></datatable-simple-component-nested>
|
|
7
|
+
</template>
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<!-- We don't need to set data-navigation on this div as we are not traversing a shadowroot -->
|
|
3
|
+
<div>
|
|
4
|
+
<!-- Since this component needs to be navigable we set data-navigation to enable navigation. -->
|
|
5
|
+
<!-- As it is navigable we also need to set the tabindex=0 so that from a dom structure perspective it shows as navgiable. -->
|
|
6
|
+
<lightning-button variant="base" label="Base" title="Looks like a link" class="slds-m-left_x-small" data-navigation="enable" tabindex={internalTabIndex}></lightning-button>
|
|
7
|
+
<lightning-button label="Neutral" title="Non-primary action" class="slds-m-left_x-small" data-navigation="enable" tabindex={internalTabIndex}></lightning-button>
|
|
8
|
+
</div>
|
|
9
|
+
</template>
|
|
@@ -4,17 +4,6 @@ import { getColumnWidth, getTotalWidthsData } from './widthManagerShared';
|
|
|
4
4
|
const MIN_MAX_THRESHOLD = 0.5;
|
|
5
5
|
const TRUNCATION_ALLOWANCE = 20;
|
|
6
6
|
|
|
7
|
-
/**
|
|
8
|
-
* Determines if a column exists at a specified index
|
|
9
|
-
*
|
|
10
|
-
* @param {Array} columns An array of columns
|
|
11
|
-
* @param {Integer} colIndex The column index to locate
|
|
12
|
-
* @returns {Boolean} Whether the column exists at the specified index
|
|
13
|
-
*/
|
|
14
|
-
function hasColumn(columns, colIndex) {
|
|
15
|
-
return columns.some((current) => current === colIndex);
|
|
16
|
-
}
|
|
17
|
-
|
|
18
7
|
/**
|
|
19
8
|
* Calculates the total width of all columns
|
|
20
9
|
*
|
|
@@ -61,34 +50,21 @@ function canAddWidth(currentWidth, widthToAdd, maxColumnWidth) {
|
|
|
61
50
|
* @returns {Number} The expected width of the table
|
|
62
51
|
*/
|
|
63
52
|
function getExpectedTableWidth(availableWidth, widthsData) {
|
|
64
|
-
const minExpectedTableWidth = getMinExpectedTableWidth(widthsData);
|
|
65
|
-
return widthsData.totalFlexibleColumns === 0
|
|
66
|
-
? minExpectedTableWidth
|
|
67
|
-
: Math.max(minExpectedTableWidth, availableWidth);
|
|
68
|
-
}
|
|
69
|
-
|
|
70
|
-
/**
|
|
71
|
-
* Determines the minimum expected table width
|
|
72
|
-
*
|
|
73
|
-
* @param {Object} widthsData The widths data
|
|
74
|
-
* @returns {Number} The minimum expected table width
|
|
75
|
-
*/
|
|
76
|
-
function getMinExpectedTableWidth(widthsData) {
|
|
77
53
|
const minTotalFlexibleWidth =
|
|
78
54
|
widthsData.totalFlexibleColumns * widthsData.minColumnWidth;
|
|
79
|
-
|
|
55
|
+
const minExpectedTableWidth =
|
|
80
56
|
minTotalFlexibleWidth +
|
|
81
57
|
widthsData.totalFixedWidth +
|
|
82
|
-
widthsData.totalResizedWidth
|
|
83
|
-
|
|
58
|
+
widthsData.totalResizedWidth;
|
|
59
|
+
return widthsData.totalFlexibleColumns === 0
|
|
60
|
+
? minExpectedTableWidth
|
|
61
|
+
: Math.max(minExpectedTableWidth, availableWidth);
|
|
84
62
|
}
|
|
85
63
|
|
|
86
64
|
/**
|
|
87
65
|
* Strategy for columns that automatically determine their widths.
|
|
88
66
|
*/
|
|
89
67
|
export class AutoWidthStrategy {
|
|
90
|
-
// Private variables
|
|
91
|
-
|
|
92
68
|
// Instance array to hold column width ratios either calculated from visual distribution of column labels
|
|
93
69
|
// or from distribution of data amongst the columns. These ratios are reused except when datatable reacts
|
|
94
70
|
// to changes in data or columns and other variables at which point they are recalculated.
|
|
@@ -102,8 +78,6 @@ export class AutoWidthStrategy {
|
|
|
102
78
|
// It is used in redistribution of extra space that is left or taken up while calculating auto widths
|
|
103
79
|
columnWidthsDistribution = {};
|
|
104
80
|
|
|
105
|
-
/************************** LIFECYCLE HOOKS **************************/
|
|
106
|
-
|
|
107
81
|
constructor(minColumnWidth, maxColumnWidth, wrapTextMaxLines = 3) {
|
|
108
82
|
this.columnWidthData = {
|
|
109
83
|
minColumnWidth,
|
|
@@ -114,8 +88,6 @@ export class AutoWidthStrategy {
|
|
|
114
88
|
this.columnWidthsDistribution.colsWithMaxWidth = [];
|
|
115
89
|
}
|
|
116
90
|
|
|
117
|
-
/************************** PRIVATE SETTERS **************************/
|
|
118
|
-
|
|
119
91
|
/**
|
|
120
92
|
* Sets the minimum column width
|
|
121
93
|
*
|
|
@@ -182,7 +154,7 @@ export class AutoWidthStrategy {
|
|
|
182
154
|
recomputeAutoWidthRatios &&
|
|
183
155
|
this.columnWidthRatios.length !== columns.length
|
|
184
156
|
) {
|
|
185
|
-
return {
|
|
157
|
+
return { columnWidths: [] };
|
|
186
158
|
}
|
|
187
159
|
|
|
188
160
|
// First pass - Distribute widths as per ratios or defined widths if there are any
|
|
@@ -213,7 +185,7 @@ export class AutoWidthStrategy {
|
|
|
213
185
|
columns
|
|
214
186
|
);
|
|
215
187
|
}
|
|
216
|
-
return { columnWidths
|
|
188
|
+
return { columnWidths };
|
|
217
189
|
}
|
|
218
190
|
|
|
219
191
|
/**
|
|
@@ -535,7 +507,7 @@ export class AutoWidthStrategy {
|
|
|
535
507
|
const col = columns[colIndex];
|
|
536
508
|
const currentWidth = columnWidths[colIndex];
|
|
537
509
|
if (
|
|
538
|
-
!
|
|
510
|
+
!colsWithMinWidth.includes(colIndex) &&
|
|
539
511
|
!getColumnWidth(col) &&
|
|
540
512
|
canRemoveWidth(
|
|
541
513
|
currentWidth,
|