@brightspace-ui/core 1.239.0 → 1.239.1

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.
@@ -37,4 +37,11 @@ The `d2l-scroll-wrapper` element can be used to wrap content which may overflow
37
37
  | Property | Type | Description |
38
38
  |---|---|---|
39
39
  | `hide-actions` | Boolean, default: `false` | Whether to hide left/right scroll buttons |
40
+
41
+ ### Variables
42
+
43
+ | Variable | Type | Description |
44
+ |---|---|---|
45
+ | `--d2l-scroll-wrapper-overflow-y` | [Any valid overflow-y setting](https://developer.mozilla.org/en-US/docs/Web/CSS/overflow-y), defaults to `visible` | Set the `overflow-y` property of the inner scroll wrapper |
46
+
40
47
  <!-- docs: end hidden content -->
@@ -53,11 +53,11 @@ class ScrollWrapper extends FocusVisiblePolyfillMixin(RtlMixin(LitElement)) {
53
53
  :host([hidden]) {
54
54
  display: none;
55
55
  }
56
-
57
56
  .d2l-scroll-wrapper-container {
58
57
  box-sizing: border-box;
59
58
  outline: none;
60
59
  overflow-x: auto;
60
+ overflow-y: var(--d2l-scroll-wrapper-overflow-y, visible);
61
61
  }
62
62
  .d2l-scroll-wrapper-container.focus-visible {
63
63
  box-shadow: 0 0 0 2px #ffffff, 0 0 0 4px var(--d2l-color-celestine), 0 2px 12px 0 rgba(0, 0, 0, 0.15);
@@ -172,8 +172,7 @@ class ScrollWrapper extends FocusVisiblePolyfillMixin(RtlMixin(LitElement)) {
172
172
 
173
173
  checkScrollbar() {
174
174
  if (!this._container) return;
175
- const hScrollbar = Math.abs(this._container.offsetWidth - this._container.scrollWidth);
176
- this._hScrollbar = (hScrollbar > 0);
175
+ this._hScrollbar = this._container.offsetWidth !== this._container.scrollWidth;
177
176
  this._checkScrollThresholds();
178
177
  }
179
178
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@brightspace-ui/core",
3
- "version": "1.239.0",
3
+ "version": "1.239.1",
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",