@brightspace-ui/core 3.219.7 → 3.219.8

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.
@@ -3,7 +3,7 @@ import { styleMap } from 'lit/directives/style-map.js';
3
3
 
4
4
  const reduceMotion = matchMedia('(prefers-reduced-motion: reduce)').matches;
5
5
 
6
- const states = {
6
+ export const states = {
7
7
  PRECOLLAPSING: 'precollapsing', // setting up the styles so the collapse transition will run
8
8
  COLLAPSING: 'collapsing', // in the process of collapsing
9
9
  COLLAPSED: 'collapsed', // fully collapsed
@@ -88,6 +88,7 @@ class ExpandCollapseContent extends LitElement {
88
88
  this._height = '0';
89
89
  this._isFirstUpdate = true;
90
90
  this._state = states.COLLAPSED;
91
+ this._reduceMotion = reduceMotion;
91
92
  }
92
93
 
93
94
  render() {
@@ -118,7 +119,7 @@ class ExpandCollapseContent extends LitElement {
118
119
  { bubbles: true, detail: { expandComplete: eventPromise } }
119
120
  ));
120
121
  }
121
- if (reduceMotion || firstUpdate) {
122
+ if (this._reduceMotion || firstUpdate) {
122
123
  this._setExpanded();
123
124
  } else {
124
125
  this._state = states.PREEXPANDING;
@@ -139,7 +140,7 @@ class ExpandCollapseContent extends LitElement {
139
140
  { bubbles: true, detail: { collapseComplete: eventPromise } }
140
141
  ));
141
142
  }
142
- if (reduceMotion || firstUpdate) {
143
+ if (this._reduceMotion || firstUpdate) {
143
144
  this._state = states.COLLAPSED;
144
145
  this._height = '0';
145
146
  this._eventPromiseResolve();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@brightspace-ui/core",
3
- "version": "3.219.7",
3
+ "version": "3.219.8",
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",