@brightspace-ui/core 2.67.3 → 2.67.4

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.
@@ -18,6 +18,7 @@
18
18
  import '../list.js';
19
19
  import '../../menu/menu.js';
20
20
  import '../../menu/menu-item.js';
21
+ import '../../paging/pager-load-more.js';
21
22
  import '../../selection/selection-action.js';
22
23
  </script>
23
24
  </head>
@@ -111,6 +112,8 @@
111
112
  <d2l-list-item selectable key="L1-3" label="Label for L1-3">
112
113
  <div>Computer Science (L1)</div>
113
114
  </d2l-list-item>
115
+ <d2l-pager-load-more slot="pager" has-more page-size="5">
116
+ </d2l-pager-load-more>
114
117
  </d2l-list>
115
118
  </template>
116
119
  </d2l-demo-snippet>
@@ -138,6 +141,11 @@
138
141
  document.querySelector('d2l-list').addEventListener('d2l-list-selection-changes', (e) => {
139
142
  console.log('d2l-list-selection-changes', e.detail);
140
143
  });
144
+
145
+ document.querySelector('d2l-pager-load-more').addEventListener('d2l-pager-load-more', (e) => {
146
+ console.log('Load more requested!');
147
+ setTimeout(() => e.detail.complete(), 2000);
148
+ });
141
149
  }, 1000);
142
150
  </script>
143
151
 
@@ -207,8 +207,8 @@ class List extends PageableMixin(SelectionMixin(LitElement)) {
207
207
  if (!this.grid || this.slot === 'nested' || e.keyCode !== keyCodes.TAB) return;
208
208
  e.preventDefault();
209
209
  if (!this.shadowRoot) return;
210
- const focusable = (e.shiftKey ? getPreviousFocusable(this.shadowRoot.querySelector('slot:not([name])'))
211
- : getNextFocusable(this, false, true, true));
210
+ const listSlot = this.shadowRoot.querySelector('slot:not([name])');
211
+ const focusable = (e.shiftKey ? getPreviousFocusable(listSlot) : getNextFocusable(listSlot, false, true, true));
212
212
  if (focusable) focusable.focus();
213
213
  }
214
214
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@brightspace-ui/core",
3
- "version": "2.67.3",
3
+ "version": "2.67.4",
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",