lightning-base-components 1.21.4-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.
Files changed (61) hide show
  1. package/metadata/raptor.json +1 -1
  2. package/package.json +9 -1
  3. package/scopedImports/@salesforce-label-LightningLookup.messageWhenSearchTermTooShort.js +1 -0
  4. package/src/lightning/accordion/__docs__/accordion.md +0 -4
  5. package/src/lightning/accordionSection/__docs__/accordionSection.md +0 -4
  6. package/src/lightning/avatar/__docs__/avatar.md +0 -4
  7. package/src/lightning/badge/__docs__/badge.md +0 -4
  8. package/src/lightning/barcodeScanner/__docs__/barcodeScanner.md +0 -4
  9. package/src/lightning/baseCombobox/baseCombobox.js +2 -2
  10. package/src/lightning/baseComboboxItem/baseComboboxItem.js +6 -10
  11. package/src/lightning/button/__docs__/button.md +3 -7
  12. package/src/lightning/buttonGroup/__docs__/buttonGroup.md +0 -4
  13. package/src/lightning/buttonIcon/__docs__/buttonIcon.md +0 -4
  14. package/src/lightning/buttonIconStateful/__docs__/buttonIconStateful.md +0 -4
  15. package/src/lightning/buttonMenu/__docs__/buttonMenu.md +0 -4
  16. package/src/lightning/buttonStateful/__docs__/buttonStateful.md +0 -4
  17. package/src/lightning/buttonStateful/buttonStateful.html +5 -3
  18. package/src/lightning/buttonStateful/buttonStateful.js +4 -0
  19. package/src/lightning/card/__docs__/card.md +0 -4
  20. package/src/lightning/card/card.js-meta.xml +3 -0
  21. package/src/lightning/carousel/__docs__/carousel.md +0 -4
  22. package/src/lightning/checkboxGroup/__docs__/checkboxGroup.md +0 -4
  23. package/src/lightning/combobox/__docs__/combobox.md +0 -4
  24. package/src/lightning/datatable/columnWidthManager.js +3 -3
  25. package/src/lightning/datatable/datatable.js +3 -4
  26. package/src/lightning/datatable/inlineEdit.js +1 -0
  27. package/src/lightning/datatable/utils.js +4 -5
  28. package/src/lightning/dualListbox/__docs__/dualListbox.md +0 -4
  29. package/src/lightning/dynamicIcon/__docs__/dynamicIcon.md +0 -4
  30. package/src/lightning/formattedDateTime/__docs__/formattedDateTime.md +0 -4
  31. package/src/lightning/formattedLocation/__docs__/formattedLocation.md +0 -4
  32. package/src/lightning/formattedName/__docs__/formattedName.md +0 -4
  33. package/src/lightning/formattedNumber/__docs__/formattedNumber.md +0 -4
  34. package/src/lightning/formattedPhone/__docs__/formattedPhone.md +0 -4
  35. package/src/lightning/formattedText/__docs__/formattedText.md +0 -4
  36. package/src/lightning/formattedTime/__docs__/formattedTime.md +0 -4
  37. package/src/lightning/formattedUrl/__docs__/formattedUrl.md +0 -4
  38. package/src/lightning/icon/__docs__/icon.md +0 -4
  39. package/src/lightning/inputAddress/inputAddress.js +13 -7
  40. package/src/lightning/inputLocation/__docs__/inputLocation.md +0 -4
  41. package/src/lightning/layout/__docs__/layout.md +0 -4
  42. package/src/lightning/layoutItem/__docs__/layoutItem.md +0 -4
  43. package/src/lightning/menuItem/__docs__/menuItem.md +0 -4
  44. package/src/lightning/menuSubheader/menu-subheader.slds.css +1 -1
  45. package/src/lightning/modalBase/modalBase.js +2 -2
  46. package/src/lightning/pill/__docs__/pill.md +0 -4
  47. package/src/lightning/pillContainer/__docs__/pillContainer.md +0 -4
  48. package/src/lightning/radioGroup/__docs__/radioGroup.md +0 -4
  49. package/src/lightning/relativeDateTime/__docs__/relativeDateTime.md +0 -4
  50. package/src/lightning/slider/__docs__/slider.md +0 -4
  51. package/src/lightning/spinner/__docs__/spinner.md +0 -4
  52. package/src/lightning/tab/__docs__/tab.md +0 -4
  53. package/src/lightning/tabset/__docs__/tabset.md +0 -4
  54. package/src/lightning/textarea/__docs__/textarea.md +0 -4
  55. package/src/lightning/tile/__docs__/tile.md +0 -4
  56. package/src/lightning/tree/__docs__/tree.md +0 -4
  57. package/src/lightning/tree/tree.js +5 -1
  58. package/src/lightning/verticalNavigation/__docs__/verticalNavigation.md +0 -4
  59. package/src/lightning/verticalNavigationItem/__docs__/verticalNavigationItem.md +0 -4
  60. package/src/lightning/verticalNavigationItemBadge/__docs__/verticalNavigationItemBadge.md +0 -4
  61. package/src/lightning/verticalNavigationItemIcon/__docs__/verticalNavigationItemIcon.md +0 -4
@@ -2030,7 +2030,7 @@
2030
2030
  "name": "showAddressLookup"
2031
2031
  },
2032
2032
  {
2033
- "name": "showCompactAddressLookup"
2033
+ "name": "showCompactAddress"
2034
2034
  },
2035
2035
  {
2036
2036
  "name": "street"
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "lightning-base-components",
3
- "version": "1.21.4-alpha",
3
+ "version": "1.21.5-alpha",
4
4
  "license": "MIT",
5
5
  "files": [
6
6
  "external",
@@ -986,6 +986,10 @@
986
986
  "name": "@salesforce/label/LightningLookup.modalCancel",
987
987
  "path": "scopedImports/@salesforce-label-LightningLookup.modalCancel.js"
988
988
  },
989
+ {
990
+ "name": "@salesforce/label/LightningLookup.messageWhenSearchTermTooShort",
991
+ "path": "scopedImports/@salesforce-label-LightningLookup.messageWhenSearchTermTooShort.js"
992
+ },
989
993
  {
990
994
  "name": "@salesforce/label/LightningRecordPicker.invalidConfigurationErrorMessage",
991
995
  "path": "scopedImports/@salesforce-label-LightningRecordPicker.invalidConfigurationErrorMessage.js"
@@ -1365,6 +1369,7 @@
1365
1369
  "lightning-button-icon-stateful",
1366
1370
  "lightning-button-menu",
1367
1371
  "lightning-button-stateful",
1372
+ "lightning-card",
1368
1373
  "lightning-calendar",
1369
1374
  "lightning-color-picker-custom",
1370
1375
  "lightning-color-picker-panel",
@@ -1402,9 +1407,11 @@
1402
1407
  "lightning-progress-ring",
1403
1408
  "lightning-primitive-bubble",
1404
1409
  "lightning-primitive-button",
1410
+ "primitive-file-droppable-zone",
1405
1411
  "lightning-primitive-input-checkbox",
1406
1412
  "lightning-primitive-input-checkbox-button",
1407
1413
  "lightning-primitive-input-color",
1414
+ "lightning-primitive-colorpicker-button",
1408
1415
  "lightning-primitive-input-file",
1409
1416
  "lightning-primitive-input-simple",
1410
1417
  "lightning-primitive-input-toggle",
@@ -1524,6 +1531,7 @@
1524
1531
  "lightning-primitive-bubble",
1525
1532
  "lightning-primitive-button",
1526
1533
  "lightning-primitive-color-picker-button",
1534
+ "primitive-file-droppable-zone",
1527
1535
  "lightning-primitive-icon",
1528
1536
  "lightning-primitive-input-checkbox",
1529
1537
  "lightning-primitive-input-checkbox-button",
@@ -0,0 +1 @@
1
+ export default 'Type at least 2 characters to perform a search.';
@@ -272,7 +272,3 @@ The event properties are as follows.
272
272
  | bubbles | false | This event does not bubble. |
273
273
  | cancelable | false | This event has no default behavior that can be canceled. You can't call `preventDefault()` on this event. |
274
274
  | composed | false | This event does not propagate outside the template in which it was dispatched. |
275
-
276
- #### Source Code
277
-
278
- `lightning-accordion` 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.
@@ -91,7 +91,3 @@ renders with `aria-expanded="true"`. When a section is collapsed, the button ren
91
91
  Additionally, the button uses the `aria-controls` attribute to identify the content that relates to the controlling button on the accordion section.
92
92
 
93
93
  To expand or collapse a section using the keyboard, press the Tab key to set focus on the toggle button or header text and press Enter.
94
-
95
- #### Source Code
96
-
97
- `lightning-accordion-section` 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.
@@ -153,7 +153,3 @@ To understand how we implemented SLDS in `lightning-avatar`, see the **Source Co
153
153
  #### Accessibility
154
154
 
155
155
  Use the `alternative-text` attribute to describe the avatar, such as a user's initials or name. This description provides the value for the `alt` attribute in the `img` HTML tag.
156
-
157
- #### Source Code
158
-
159
- `lightning-avatar` 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.
@@ -97,7 +97,3 @@ To understand how we implemented SLDS in `lightning-badge`, see the **Source Cod
97
97
  #### Usage Considerations
98
98
 
99
99
  Badges with nested elements are not supported. To create a label that can contain links, use `lightning-pill` instead.
100
-
101
- #### Source Code
102
-
103
- `lightning-badge` 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.
@@ -116,7 +116,3 @@ The `errors` event has these properties.
116
116
  | bubbles | false | This event does not bubble. |
117
117
  | cancelable | true | This event can be canceled. You can call `preventDefault()` on this event to prevent firing the click event. |
118
118
  | composed | false | This event does not propagate outside the template in which it was dispatched. |
119
-
120
- #### Source Code
121
-
122
- `lightning-barcode-scanner` 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.
@@ -856,7 +856,7 @@ export default class LightningBaseCombobox extends LightningShadowBaseClass {
856
856
  highlightOption(option) {
857
857
  this.removeHighlight();
858
858
  if (option) {
859
- option.highlight(option.ariaChecked);
859
+ option.highlight();
860
860
  this._highlightedOptionElement = option;
861
861
  this._highlightedOptionElementId =
862
862
  option.getAttribute('data-item-id');
@@ -877,7 +877,7 @@ export default class LightningBaseCombobox extends LightningShadowBaseClass {
877
877
  removeHighlight() {
878
878
  const option = this._highlightedOptionElement;
879
879
  if (option) {
880
- option.removeHighlight(option.ariaChecked);
880
+ option.removeHighlight();
881
881
  this._highlightedOptionElement = null;
882
882
  this._highlightedOptionElementId = null;
883
883
  this._activeElementDomId = null;
@@ -43,22 +43,18 @@ export default class LightningBaseComboboxItem extends LightningShadowBaseClass
43
43
  }
44
44
 
45
45
  @api
46
- highlight(isSelected) {
47
- this.toggleHighlight(true, isSelected);
46
+ highlight() {
47
+ this.toggleHighlight(true);
48
48
  }
49
49
 
50
50
  @api
51
- removeHighlight(isSelected) {
52
- this.toggleHighlight(false, isSelected);
51
+ removeHighlight() {
52
+ this.toggleHighlight(false);
53
53
  }
54
54
 
55
- toggleHighlight(highlighted, isSelected) {
55
+ toggleHighlight(highlighted) {
56
56
  if (this.item.selectable) {
57
- //Only announce the selected item from the list, not the hovered or focused ones.
58
- this.setAttribute(
59
- 'aria-selected',
60
- isSelected === 'true' ? true : false
61
- );
57
+ this.setAttribute('aria-selected', highlighted ? 'true' : 'false');
62
58
  this.classList.toggle('slds-has-focus', highlighted);
63
59
  }
64
60
  }
@@ -104,15 +104,15 @@ Use the `variant` attribute with one of these values to apply styling and animat
104
104
  - `inverse` uses the background color and light text, useful for dark backgrounds.
105
105
  - `success` is a green button used to indicate a successful action.
106
106
 
107
- ##### Animation
107
+ ##### Animation
108
108
 
109
- Buttons are animated by default. For the `base` variant, an underline is drawn when you mouse over the button. For the other variants, a ripple of contrasting color displays when you click the button.
109
+ Buttons are animated by default. For the `base` variant, an underline is drawn when you mouse over the button. For the other variants, a ripple of contrasting color displays when you click the button.
110
110
 
111
111
  When a button is disabled, the animation is disabled as well.
112
112
 
113
113
  If your browser or operating system is set to reduce animation, the button animations don't display.
114
114
 
115
- To prevent animation for a button, use the `disable-animation` attribute.
115
+ To prevent animation for a button, use the `disable-animation` attribute.
116
116
 
117
117
  ```html
118
118
  <template>
@@ -279,7 +279,3 @@ Use the following accessibility and `aria` attributes on `lightning-button`.
279
279
  | 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). |
280
280
 
281
281
  For more information, see the [WAI-ARIA Specification](https://www.w3.org/TR/wai-aria/).
282
-
283
- #### Source Code
284
-
285
- `lightning-button` 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.
@@ -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)
@@ -208,7 +208,3 @@ Use the following accessibility and `aria` attributes on `lightning-button-icon`
208
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). |
209
209
 
210
210
  For more information, see the [WAI-ARIA Specification](https://www.w3.org/TR/wai-aria/).
211
-
212
- #### Source Code
213
-
214
- `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.
@@ -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.
@@ -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.
@@ -3,4 +3,7 @@
3
3
  <isExposed>true</isExposed>
4
4
  <minApiVersion>0.0</minApiVersion>
5
5
  <support>GA</support>
6
+ <capabilities>
7
+ <capability>lightning__ServerRenderableWithHydration</capability>
8
+ </capabilities>
6
9
  </LightningComponentBundle>
@@ -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.
@@ -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.
@@ -1,7 +1,7 @@
1
1
  import { RESIZER_DEFAULT_STATE, isTableRenderedVisible } from './columnResizer';
2
2
  import { AutoWidthStrategy } from './autoWidthStrategy';
3
3
  import { FixedWidthStrategy } from './fixedWidthStrategy';
4
- import { getScrollerXFromScrollerY, getScrollerY } from './utils';
4
+ import { getScrollerX } from './utils';
5
5
  import {
6
6
  getRowNumberColumnIndex,
7
7
  getAdjustedRowNumberColumnWidth,
@@ -364,8 +364,8 @@ export class ColumnWidthManager {
364
364
  getDatatableInterface(template) {
365
365
  return {
366
366
  getAvailableWidthFromDom() {
367
- const scrollerY = getScrollerY(template);
368
- return getScrollerXFromScrollerY(scrollerY).offsetWidth;
367
+ const scrollerX = getScrollerX(template);
368
+ return scrollerX.offsetWidth;
369
369
  },
370
370
  getDataCellWidths() {
371
371
  const cellElements = template.querySelectorAll(
@@ -126,7 +126,7 @@ import {
126
126
  import {
127
127
  getGridContainerFromScrollerY,
128
128
  getRowDataSelector,
129
- getScrollerXFromScrollerY,
129
+ getScrollerX,
130
130
  getScrollerY,
131
131
  } from './utils';
132
132
  import { setWrapTextMaxLines } from './wrapText';
@@ -1011,8 +1011,7 @@ export default class LightningDatatable extends LightningElement {
1011
1011
  this._privateTypes = new DatatableTypes(this.constructor.customTypes);
1012
1012
 
1013
1013
  this._renderManager = new RenderManager();
1014
- this.getWrapperHeight = () =>
1015
- getScrollerXFromScrollerY(getScrollerY(this.template)).offsetHeight;
1014
+ this.getWrapperHeight = () => getScrollerX(this.template).offsetHeight;
1016
1015
  }
1017
1016
 
1018
1017
  /**
@@ -1819,7 +1818,7 @@ export default class LightningDatatable extends LightningElement {
1819
1818
  const { template } = this;
1820
1819
  const scrollerY = getScrollerY(template);
1821
1820
  const scrollerYRect = scrollerY.getBoundingClientRect();
1822
- const scrollerX = getScrollerXFromScrollerY(scrollerY);
1821
+ const scrollerX = getScrollerX(template);
1823
1822
  const scrollerXRect = scrollerX.getBoundingClientRect();
1824
1823
 
1825
1824
  return {
@@ -160,6 +160,7 @@ export function cancelInlineEdit(dt) {
160
160
  const { state, _privateTypes } = dt;
161
161
  resetErrors(state);
162
162
  state.inlineEdit.dirtyValues = {};
163
+ dt._draftValues = [];
163
164
  updateRowsAndCellIndexes(state, _privateTypes);
164
165
  }
165
166
 
@@ -91,14 +91,13 @@ export function getGridContainerFromScrollerY(scrollerY) {
91
91
  }
92
92
 
93
93
  /**
94
- * Gets the scrollerX element from the scrollerY element.
94
+ * Gets the scrollerX element from the template.
95
95
  *
96
- * @param {Node} scrollerY The scrollerY element
96
+ * @param {Node} template The datatable template
97
97
  * @returns {Node} The scrollerX element
98
98
  */
99
- export function getScrollerXFromScrollerY(scrollerY) {
100
- const { parentElement: scrollerX } = scrollerY;
101
- return scrollerX;
99
+ export function getScrollerX(template) {
100
+ return template.querySelector('.slds-scrollable_x');
102
101
  }
103
102
 
104
103
  /**
@@ -176,7 +176,3 @@ The event properties are as follows.
176
176
  | bubbles | true | This event bubbles up through the DOM. |
177
177
  | cancelable | false | This event has no default behavior that can be canceled. You can't call `preventDefault()` on this event. |
178
178
  | composed | true | This event propagates outside of the component in which it was dispatched. |
179
-
180
- #### Source Code
181
-
182
- `lightning-dual-listbox` 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.
@@ -60,7 +60,3 @@ However, on smaller screens and windows the `lightning-dynamic-icon` can also be
60
60
  informational. In this case, include `alternative-text`. If you don't include
61
61
  `alternative-text`, check smaller screens and windows to ensure that the
62
62
  `lightning-dynamic-icon` is only decorative on all formats.
63
-
64
- #### Source Code
65
-
66
- `lightning-dynamic-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.
@@ -219,10 +219,6 @@ Displays: December 03, 2017, 12:00 PM
219
219
 
220
220
  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.
221
221
 
222
- #### Source Code
223
-
224
- `lightning-formatted-date-time` 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.
225
-
226
222
  #### LWC Recipes
227
223
 
228
224
  The [LWC Recipes GitHub repository](https://github.com/trailheadapps/lwc-recipes) contains code examples for Lightning Web Components that you can test in an org.
@@ -27,7 +27,3 @@ longitude of -122.3948370.
27
27
  </lightning-formatted-location>
28
28
  </template>
29
29
  ```
30
-
31
- #### Source Code
32
-
33
- `lightning-formatted-location` 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.
@@ -47,7 +47,3 @@ in the Salesforce Help.
47
47
  To create a form that takes in user input for names, you can use the
48
48
  `lightning-input-name` component, which displays a name compound field that
49
49
  supports user input for salutation, suffix, and so on.
50
-
51
- #### Source Code
52
-
53
- `lightning-formatted-name` 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.
@@ -166,10 +166,6 @@ The locale set in your Salesforce user preferences determines how numbers are fo
166
166
  The `format-style` attribute is called the `style` attribute in the Aura version of this component.
167
167
  See [Base Components: Aura Vs Lightning Web Components](https://developer.salesforce.com/docs/platform/lwc/guide/migrate-map-aura-lwc-components).
168
168
 
169
- #### Source Code
170
-
171
- `lightning-formatted-number` 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.
172
-
173
169
  #### LWC Recipes
174
170
 
175
171
  The [LWC Recipes GitHub repository](https://github.com/trailheadapps/lwc-recipes) contains code examples for Lightning Web Components that you can test in an org.
@@ -67,10 +67,6 @@ To display the phone number in plain text without a hyperlink, include the
67
67
  </template>
68
68
  ```
69
69
 
70
- #### Source Code
71
-
72
- `lightning-formatted-phone` 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.
73
-
74
70
  #### LWC Recipes
75
71
 
76
72
  The [LWC Recipes GitHub repository](https://github.com/trailheadapps/lwc-recipes) contains code examples for Lightning Web Components that you can test in an org.
@@ -52,7 +52,3 @@ use `lightning-formatted-email`.
52
52
 
53
53
  For rich text that uses tags beyond anchor tags, use
54
54
  `lightning-formatted-rich-text` instead.
55
-
56
- #### Source Code
57
-
58
- `lightning-formatted-text` 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.
@@ -33,7 +33,3 @@ The following example returns `10:12:30 PM`.
33
33
  Salesforce uses the format HH:mm:ss.SSSZ for time fields. The time field is a
34
34
  timestamp without the date included. Time values in Salesforce are not
35
35
  localized or associated with a time zone.
36
-
37
- #### Source Code
38
-
39
- `lightning-formatted-time` 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.
@@ -113,7 +113,3 @@ behavior with `lightning-formatted-url`.
113
113
  To create a link with a
114
114
  custom `onclick` event handler, use the HTML anchor tag `<a>` instead. To create a URL that navigates to another page in Salesforce, use
115
115
  [`lightning-navigation`](bundle/lightning-navigation/documentation).
116
-
117
- #### Source Code
118
-
119
- `lightning-formatted-url` 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.
@@ -176,7 +176,3 @@ screens and windows to ensure that the icon is decorative on all formats.
176
176
  Icons are not available in Lightning Out, but they are available in Lightning Components for Visualforce and other experiences.
177
177
 
178
178
  For IE11, the custom icon feature is disabled for now due to performance issues.
179
-
180
- #### Source Code
181
-
182
- `lightning-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.
@@ -311,16 +311,18 @@ export default class LightningInputAddress extends LightningShadowBaseClass {
311
311
  }
312
312
 
313
313
  /**
314
- * If present, a compact address lookup using Google Maps is enabled.
314
+ * If present, the street field is rendered as two separate inputs instead of a single textarea.
315
+ * In addition, the search field is no longer rendered as a separate input and its functionality
316
+ * is moved to the street field.
315
317
  * @type {boolean}
316
318
  * @default false
317
319
  */
318
320
  @api
319
- get showCompactAddressLookup() {
320
- return this._showAddressLookup;
321
+ get showCompactAddress() {
322
+ return this._showCompactAddress;
321
323
  }
322
- set showCompactAddressLookup(value) {
323
- this._showCompactAddressLookup = normalizeBoolean(value);
324
+ set showCompactAddress(value) {
325
+ this._showCompactAddress = normalizeBoolean(value);
324
326
  }
325
327
 
326
328
  /**
@@ -491,6 +493,10 @@ export default class LightningInputAddress extends LightningShadowBaseClass {
491
493
  reflectAttribute(this, 'variant', this.variant);
492
494
  }
493
495
 
496
+ get showCompactAddressLookup() {
497
+ return this._showAddressLookup && this._showCompactAddress;
498
+ }
499
+
494
500
  get computedFieldsetClass() {
495
501
  return classSet(
496
502
  'slds-form-element slds-form-element_compound slds-form-element_address'
@@ -571,7 +577,7 @@ export default class LightningInputAddress extends LightningShadowBaseClass {
571
577
  langCode,
572
578
  countryCode,
573
579
  hasCountryPicklist,
574
- this._showCompactAddressLookup
580
+ this._showCompactAddress
575
581
  );
576
582
  }
577
583
 
@@ -580,7 +586,7 @@ export default class LightningInputAddress extends LightningShadowBaseClass {
580
586
  return getRequiredFields(
581
587
  langCode,
582
588
  countryCode,
583
- this._showCompactAddressLookup
589
+ this._showCompactAddress
584
590
  );
585
591
  }
586
592
 
@@ -81,7 +81,3 @@ The `change` event properties are as follows.
81
81
  | bubbles | true | This event bubbles up through the DOM. |
82
82
  | cancelable | false | This event has no default behavior that can be canceled. You can't call `preventDefault()` on this event. |
83
83
  | composed | true | This event propagates outside of the component in which it was dispatched. |
84
-
85
- #### Source Code
86
-
87
- `lightning-input-location` 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.
@@ -136,7 +136,3 @@ which creates two columns with fixed widths.
136
136
  <div class="slds-col slds-size_2-of-3">Columns 2 content</div>
137
137
  </div>
138
138
  ```
139
-
140
- #### Source Code
141
-
142
- `lightning-layout` 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.
@@ -81,7 +81,3 @@ Here is an example using default values.
81
81
  #### Usage Considerations
82
82
 
83
83
  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.
84
-
85
- #### Source Code
86
-
87
- `lightning-layout-item` 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.
@@ -120,7 +120,3 @@ is shown for the menu item when `is-draft` is `true`. The
120
120
  reason the item is considered in a draft state. The draft state might be used
121
121
  to show there is unsaved state or data that could be lost, for example if
122
122
  there's a user change in a customizable menu.
123
-
124
- #### Source Code
125
-
126
- `lightning-menu-item` 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.
@@ -3,7 +3,7 @@
3
3
  Licensed under BSD 3-Clause - see LICENSE.txt or git.io/sfdc-license */
4
4
 
5
5
  :host([data-render-mode="shadow"]) .slds-dropdown__header {
6
- font-size: var(--slds-g-font-scale-neg-1);
6
+ font-size: var(--slds-g-font-size-base);
7
7
  font-weight: var(--slds-g-font-weight-7);
8
8
  padding-block: var(--slds-g-spacing-2);
9
9
  padding-inline: var(--slds-g-spacing-3);
@@ -388,7 +388,7 @@ export default class LightningModalBase extends LightningShadowBaseClass {
388
388
 
389
389
  // Modal with Header variant has close button icon on lightning-modal-header child component
390
390
  // where-as Headless Modal variant has close button icon on modal-base,
391
- if (!this.isHeadlessModalVariant) {
391
+ if (!this.isHeadlessModalVariant && this.headerTitleRef) {
392
392
  // dispatch secondary event to disable close button icon present on lightning-modal-header
393
393
  this.headerTitleRef.dispatchEvent(
394
394
  new CustomEvent('privatemodalheaderdisableclose', {
@@ -784,7 +784,7 @@ export default class LightningModalBase extends LightningShadowBaseClass {
784
784
 
785
785
  const fallbackFocusElem = this.disableCloseButton
786
786
  ? outerModalElem
787
- : closeButtonElem;
787
+ : closeButtonElem || outerModalElem;
788
788
 
789
789
  const focusElem = preferredFocusElem
790
790
  ? preferredFocusElem
@@ -217,7 +217,3 @@ The event properties are as follows.
217
217
  | bubbles | false | This event does not bubble. |
218
218
  | cancelable | true | This event can be canceled. You can call `preventDefault()` on this event to prevent the `click` event from being fired. |
219
219
  | composed | false | This event does not propagate outside the template in which it was dispatched. |
220
-
221
- #### Source Code
222
-
223
- `lightning-pill` 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.
@@ -291,7 +291,3 @@ The event properties are as follows.
291
291
  | bubbles | false | This event does not bubble. |
292
292
  | cancelable | true | This event can be canceled. You can call `preventDefault()` on this event. |
293
293
  | composed | false | This event does not propagate outside the template in which it was dispatched. |
294
-
295
- #### Source Code
296
-
297
- `lightning-pill-container` 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.
@@ -184,7 +184,3 @@ element. The legend contains the `label` value. The `fieldset` element enables
184
184
  grouping of related radio buttons to facilitate tabbing navigation and speech
185
185
  navigation for accessibility purposes. Similarly, the `legend` element
186
186
  improves accessibility by enabling a caption to be assigned to the `fieldset`.
187
-
188
- #### Source Code
189
-
190
- `lightning-radio-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.
@@ -75,7 +75,3 @@ To obtain the language and locale information in your org, use the `@salesforce/
75
75
 
76
76
  The `lightning-relative-date-time` component is limited to the en-US locale when running in
77
77
  the Playground and Mini-Playground in the Examples tab of this Component Reference.
78
-
79
- #### Source Code
80
-
81
- `lightning-relative-date-time` 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.
@@ -107,7 +107,3 @@ value.
107
107
 
108
108
  For precise numerical values, we recommend using the `lightning-input`
109
109
  component of `type="number"` instead.
110
-
111
- #### Source Code
112
-
113
- `lightning-slider` 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.
@@ -66,7 +66,3 @@ export default class DemoSpinner extends LightningElement {
66
66
  }
67
67
  }
68
68
  ```
69
-
70
- #### Source Code
71
-
72
- `lightning-spinner` 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.
@@ -50,7 +50,3 @@ The event properties are as follows.
50
50
  | bubbles | true | This event bubbles up through the DOM. |
51
51
  | cancelable | true | This event can be canceled. You can call `preventDefault()` on this event. |
52
52
  | composed | true | This event propagates outside of the component in which it was dispatched. |
53
-
54
- #### Source Code
55
-
56
- `lightning-tab` 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.
@@ -179,7 +179,3 @@ This example sets custom assistive text for a heading, specifies `heading-level`
179
179
  </lightning-tabset>
180
180
  </template>
181
181
  ```
182
-
183
- #### Source Code
184
-
185
- `lightning-tabset` 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.
@@ -241,7 +241,3 @@ See [Styling Hooks Overview](https://www.lightningdesignsystem.com/components/ri
241
241
  Use the `label` attribute to identify the text area for users of assistive technology.
242
242
  The `label` attribute creates an HTML label element on the input element. To hide a
243
243
  label from view and make it available to assistive technology, use the `label-hidden` variant.
244
-
245
- #### Source Code
246
-
247
- `lightning-textarea` 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.
@@ -165,7 +165,3 @@ The event properties are as follows.
165
165
  | bubbles | false | This event does not bubble. |
166
166
  | cancelable | false | This event has no default behavior that can be canceled. You can't call `preventDefault()` on this event. |
167
167
  | composed | false | This event does not propagate outside the template in which it was dispatched. |
168
-
169
- #### Source Code
170
-
171
- `lightning-tile` 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.
@@ -339,7 +339,3 @@ The event properties are as follows.
339
339
  The [LWC Recipes GitHub repository](https://github.com/trailheadapps/lwc-recipes) contains code examples for Lightning Web Components that you can test in an org.
340
340
 
341
341
  For a recipe that uses `lightning-tree`, see the `c-wire-get-picklist-values-by-record-type` component in the LWC Recipes repo.
342
-
343
- #### Source Code
344
-
345
- `lightning-tree` 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.
@@ -263,7 +263,11 @@ export default class LightningTree extends LightningElement {
263
263
  // Need to dispatch a change event specifically for interop to pick up the change to node.expanded
264
264
  this.dispatchEvent(
265
265
  new CustomEvent('change', {
266
- detail: { items: deepCopy(this._items) },
266
+ detail: {
267
+ items: deepCopy(this._items),
268
+ key: node.nodeRef.name,
269
+ expand: node.nodeRef.expanded,
270
+ },
267
271
  })
268
272
  );
269
273
  }
@@ -194,7 +194,3 @@ The event properties are as follows.
194
194
  | bubbles | false | This event does not bubble. |
195
195
  | cancelable | false | This event has no default behavior that can be canceled. You can't call `preventDefault()` on this event. |
196
196
  | composed | false | This event does not propagate outside the template in which it was dispatched. |
197
-
198
- #### Source Code
199
-
200
- `lightning-vertical-navigation` 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.
@@ -9,7 +9,3 @@ A `lightning-vertical-navigation-item` component is a navigation item within `li
9
9
 
10
10
  For more information, see the
11
11
  [lightning-vertical-navigation](bundle/lightning-vertical-navigation/documentation) documentation.
12
-
13
- #### Source Code
14
-
15
- `lightning-vertical-navigation-item` 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.
@@ -40,7 +40,3 @@ Here's an example that creates a navigation menu with an item containing a badge
40
40
  </lightning-vertical-navigation>
41
41
  </template>
42
42
  ```
43
-
44
- #### Source Code
45
-
46
- `lightning-vertical-navigation-item-badge` 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.
@@ -37,7 +37,3 @@ Icons from the Lightning Design System are supported. Visit [https://lightningde
37
37
  When applying Lightning Design System classes or icons, check that they are available in the
38
38
  Lightning Design System release tied to your org. The latest Lightning Design System
39
39
  resources become available only when the new release is available in your org.
40
-
41
- #### Source Code
42
-
43
- `lightning-vertical-navigation-item-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.