@cloudscape-design/components 3.0.198 → 3.0.199
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.
package/internal/environment.js
CHANGED
package/internal/manifest.json
CHANGED
package/internal/motion.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"motion.d.ts","sourceRoot":"","sources":["../../../src/internal/motion.ts"],"names":[],"mappings":"AAIA,eAAO,MAAM,gBAAgB,YAAa,WAAW,KAAG,
|
|
1
|
+
{"version":3,"file":"motion.d.ts","sourceRoot":"","sources":["../../../src/internal/motion.ts"],"names":[],"mappings":"AAIA,eAAO,MAAM,gBAAgB,YAAa,WAAW,KAAG,OAEoB,CAAC"}
|
package/internal/motion.js
CHANGED
|
@@ -2,8 +2,8 @@
|
|
|
2
2
|
// SPDX-License-Identifier: Apache-2.0
|
|
3
3
|
import { findUpUntil } from './utils/dom';
|
|
4
4
|
export var isMotionDisabled = function (element) {
|
|
5
|
-
var _a;
|
|
5
|
+
var _a, _b;
|
|
6
6
|
return !!findUpUntil(element, function (node) { return node.classList.contains('awsui-motion-disabled'); }) ||
|
|
7
|
-
(
|
|
7
|
+
((_b = (_a = window.matchMedia) === null || _a === void 0 ? void 0 : _a.call(window, '(prefers-reduced-motion: reduce)').matches) !== null && _b !== void 0 ? _b : false);
|
|
8
8
|
};
|
|
9
9
|
//# sourceMappingURL=motion.js.map
|
package/internal/motion.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"motion.js","sourceRoot":"","sources":["../../../src/internal/motion.ts"],"names":[],"mappings":"AAAA,qEAAqE;AACrE,sCAAsC;AACtC,OAAO,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;AAE1C,MAAM,CAAC,IAAM,gBAAgB,GAAG,UAAC,OAAoB;;IACnD,OAAA,CAAC,CAAC,WAAW,CAAC,OAAO,EAAE,UAAA,IAAI,IAAI,OAAA,IAAI,CAAC,SAAS,CAAC,QAAQ,CAAC,uBAAuB,CAAC,EAAhD,CAAgD,CAAC;QAChF,CAAC,
|
|
1
|
+
{"version":3,"file":"motion.js","sourceRoot":"","sources":["../../../src/internal/motion.ts"],"names":[],"mappings":"AAAA,qEAAqE;AACrE,sCAAsC;AACtC,OAAO,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;AAE1C,MAAM,CAAC,IAAM,gBAAgB,GAAG,UAAC,OAAoB;;IACnD,OAAA,CAAC,CAAC,WAAW,CAAC,OAAO,EAAE,UAAA,IAAI,IAAI,OAAA,IAAI,CAAC,SAAS,CAAC,QAAQ,CAAC,uBAAuB,CAAC,EAAhD,CAAgD,CAAC;QAChF,CAAC,MAAA,MAAA,MAAM,CAAC,UAAU,uDAAG,kCAAkC,EAAE,OAAO,mCAAI,KAAK,CAAC,CAAA;CAAA,CAAC","sourcesContent":["// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.\n// SPDX-License-Identifier: Apache-2.0\nimport { findUpUntil } from './utils/dom';\n\nexport const isMotionDisabled = (element: HTMLElement): boolean =>\n !!findUpUntil(element, node => node.classList.contains('awsui-motion-disabled')) ||\n (window.matchMedia?.('(prefers-reduced-motion: reduce)').matches ?? false);\n"]}
|
package/package.json
CHANGED