@brightspace-ui/core 3.134.3 → 3.135.0

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.
@@ -341,6 +341,7 @@ export const ListItemDragDropMixin = superclass => class extends superclass {
341
341
  :host([selected]) d2l-list-item-drag-handle,
342
342
  :host([current]) d2l-list-item-drag-handle,
343
343
  :host([_focusing-elem]) d2l-list-item-drag-handle,
344
+ :host([_list-item-new-styles][_focusing]) d2l-list-item-drag-handle,
344
345
  d2l-list-item-drag-handle:hover,
345
346
  d2l-list-item-drag-handle.d2l-hovering,
346
347
  d2l-list-item-drag-handle.d2l-focusing {
@@ -637,7 +637,10 @@ export const ListItemMixin = superclass => class extends composeMixins(
637
637
  return node.role === 'row' || node.role === 'listitem';
638
638
  }
639
639
 
640
- _onFocusIn() {
640
+ _onFocusIn(e) {
641
+ if (this._listItemNewStyles) {
642
+ e.stopPropagation(); // prevent _focusing from being set on the parent
643
+ }
641
644
  this._focusing = true;
642
645
  if (this.role !== 'row' || !tabPressed || hasDisplayedKeyboardTooltip) return;
643
646
  this._displayKeyboardTooltip = true;
@@ -1,7 +1,5 @@
1
1
  import '../colors/colors.js';
2
2
  import { css } from 'lit';
3
- import { findComposedAncestor } from '../../helpers/dom.js';
4
- import { getComposedActiveElement } from '../../helpers/focus.js';
5
3
  import { ListItemLinkMixin } from './list-item-link-mixin.js';
6
4
 
7
5
  export const ListItemNavMixin = superclass => class extends ListItemLinkMixin(superclass) {
@@ -119,15 +117,10 @@ export const ListItemNavMixin = superclass => class extends ListItemLinkMixin(su
119
117
  super._handleLinkClick(e);
120
118
  }
121
119
 
120
+ /* clean up (including _focusingElem) with GAUD-7495-list-item-new-styles flag */
122
121
  #handleFocusIn(e) {
123
122
  e.stopPropagation(); // prevent _focusing from being set on the parent
124
- requestAnimationFrame(() => {
125
- const activeElement = getComposedActiveElement();
126
- const parentListItem = findComposedAncestor(activeElement, (node) => node.role === 'row' || node.role === 'listitem');
127
- if (parentListItem && parentListItem === this) {
128
- this._focusingElem = true;
129
- }
130
- });
123
+ this._focusingElem = true;
131
124
  }
132
125
 
133
126
  #handleFocusOut() {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@brightspace-ui/core",
3
- "version": "3.134.3",
3
+ "version": "3.135.0",
4
4
  "description": "A collection of accessible, free, open-source web components for building Brightspace applications",
5
5
  "type": "module",
6
6
  "repository": "https://github.com/BrightspaceUI/core.git",