@fluentui/react-motion
Advanced tools
Comparing version 9.2.0 to 9.2.1
# Change Log - @fluentui/react-motion | ||
This log was last generated on Mon, 17 Jun 2024 07:31:07 GMT and should not be manually modified. | ||
This log was last generated on Mon, 01 Jul 2024 20:25:35 GMT and should not be manually modified. | ||
<!-- Start content --> | ||
## [9.2.1](https://github.com/microsoft/fluentui/tree/@fluentui/react-motion_v9.2.1) | ||
Mon, 01 Jul 2024 20:25:35 GMT | ||
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-motion_v9.2.0..@fluentui/react-motion_v9.2.1) | ||
### Patches | ||
- chore: add eslint react-compiler ([PR #31457](https://github.com/microsoft/fluentui/pull/31457) by seanmonahan@microsoft.com) | ||
- fix: improve Jest compat ([PR #31715](https://github.com/microsoft/fluentui/pull/31715) by olfedias@microsoft.com) | ||
- chore: adds 'use no memo' directive ([PR #31787](https://github.com/microsoft/fluentui/pull/31787) by seanmonahan@microsoft.com) | ||
- Bump @fluentui/react-utilities to v9.18.11 ([PR #31861](https://github.com/microsoft/fluentui/pull/31861) by beachball) | ||
## [9.2.0](https://github.com/microsoft/fluentui/tree/@fluentui/react-motion_v9.2.0) | ||
Mon, 17 Jun 2024 07:31:07 GMT | ||
Mon, 17 Jun 2024 07:34:16 GMT | ||
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-motion_v9.1.0..@fluentui/react-motion_v9.2.0) | ||
@@ -11,0 +23,0 @@ |
@@ -14,8 +14,9 @@ "use strict"; | ||
const _react = /*#__PURE__*/ _interop_require_wildcard._(require("react")); | ||
const _useAnimateAtoms = require("../hooks/useAnimateAtoms"); | ||
const _useMotionImperativeRef = require("../hooks/useMotionImperativeRef"); | ||
const _useIsReducedMotion = require("../hooks/useIsReducedMotion"); | ||
const _useMotionImperativeRef = require("../hooks/useMotionImperativeRef"); | ||
const _animateAtoms = require("../utils/animateAtoms"); | ||
const _getChildElement = require("../utils/getChildElement"); | ||
function createMotionComponent(value) { | ||
const Atom = (props)=>{ | ||
'use no memo'; | ||
const { children, imperativeRef, onMotionFinish: onMotionFinishProp, onMotionStart: onMotionStartProp, onMotionCancel: onMotionCancelProp, ..._rest } = props; | ||
@@ -27,2 +28,3 @@ const params = _rest; | ||
const paramsRef = _react.useRef(params); | ||
const animateAtoms = (0, _useAnimateAtoms.useAnimateAtoms)(); | ||
const isReducedMotion = (0, _useIsReducedMotion.useIsReducedMotion)(); | ||
@@ -51,3 +53,3 @@ const onMotionStart = (0, _reactutilities.useEventCallback)(()=>{ | ||
onMotionStart(); | ||
const handle = (0, _animateAtoms.animateAtoms)(element, atoms, { | ||
const handle = animateAtoms(element, atoms, { | ||
isReducedMotion: isReducedMotion() | ||
@@ -62,2 +64,3 @@ }); | ||
}, [ | ||
animateAtoms, | ||
handleRef, | ||
@@ -64,0 +67,0 @@ isReducedMotion, |
@@ -15,6 +15,6 @@ "use strict"; | ||
const _PresenceGroupChildContext = require("../contexts/PresenceGroupChildContext"); | ||
const _useIsReducedMotion = require("../hooks/useIsReducedMotion"); | ||
const _useAnimateAtoms = require("../hooks/useAnimateAtoms"); | ||
const _useMotionImperativeRef = require("../hooks/useMotionImperativeRef"); | ||
const _useMountedState = require("../hooks/useMountedState"); | ||
const _animateAtoms = require("../utils/animateAtoms"); | ||
const _useIsReducedMotion = require("../hooks/useIsReducedMotion"); | ||
const _getChildElement = require("../utils/getChildElement"); | ||
@@ -26,2 +26,3 @@ function shouldSkipAnimation(appear, isFirstMount, visible) { | ||
const Presence = (props)=>{ | ||
'use no memo'; | ||
const itemContext = _react.useContext(_PresenceGroupChildContext.PresenceGroupChildContext); | ||
@@ -43,2 +44,3 @@ const merged = { | ||
}); | ||
const animateAtoms = (0, _useAnimateAtoms.useAnimateAtoms)(); | ||
const isFirstMount = (0, _reactutilities.useFirstMount)(); | ||
@@ -88,3 +90,3 @@ const isReducedMotion = (0, _useIsReducedMotion.useIsReducedMotion)(); | ||
} | ||
const handle = (0, _animateAtoms.animateAtoms)(element, atoms, { | ||
const handle = animateAtoms(element, atoms, { | ||
isReducedMotion: isReducedMotion() | ||
@@ -105,2 +107,3 @@ }); | ||
[ | ||
animateAtoms, | ||
handleRef, | ||
@@ -107,0 +110,0 @@ isReducedMotion, |
import { useEventCallback, useIsomorphicLayoutEffect, useMergedRefs } from '@fluentui/react-utilities'; | ||
import * as React from 'react'; | ||
import { useAnimateAtoms } from '../hooks/useAnimateAtoms'; | ||
import { useMotionImperativeRef } from '../hooks/useMotionImperativeRef'; | ||
import { useIsReducedMotion } from '../hooks/useIsReducedMotion'; | ||
import { useMotionImperativeRef } from '../hooks/useMotionImperativeRef'; | ||
import { animateAtoms } from '../utils/animateAtoms'; | ||
import { getChildElement } from '../utils/getChildElement'; | ||
@@ -13,2 +13,3 @@ /** | ||
const Atom = (props)=>{ | ||
'use no memo'; | ||
const { children, imperativeRef, onMotionFinish: onMotionFinishProp, onMotionStart: onMotionStartProp, onMotionCancel: onMotionCancelProp, ..._rest } = props; | ||
@@ -20,2 +21,3 @@ const params = _rest; | ||
const paramsRef = React.useRef(params); | ||
const animateAtoms = useAnimateAtoms(); | ||
const isReducedMotion = useIsReducedMotion(); | ||
@@ -54,2 +56,3 @@ const onMotionStart = useEventCallback(()=>{ | ||
}, [ | ||
animateAtoms, | ||
handleRef, | ||
@@ -56,0 +59,0 @@ isReducedMotion, |
import { useEventCallback, useFirstMount, useIsomorphicLayoutEffect, useMergedRefs } from '@fluentui/react-utilities'; | ||
import * as React from 'react'; | ||
import { PresenceGroupChildContext } from '../contexts/PresenceGroupChildContext'; | ||
import { useIsReducedMotion } from '../hooks/useIsReducedMotion'; | ||
import { useAnimateAtoms } from '../hooks/useAnimateAtoms'; | ||
import { useMotionImperativeRef } from '../hooks/useMotionImperativeRef'; | ||
import { useMountedState } from '../hooks/useMountedState'; | ||
import { animateAtoms } from '../utils/animateAtoms'; | ||
import { useIsReducedMotion } from '../hooks/useIsReducedMotion'; | ||
import { getChildElement } from '../utils/getChildElement'; | ||
@@ -14,2 +14,3 @@ function shouldSkipAnimation(appear, isFirstMount, visible) { | ||
const Presence = (props)=>{ | ||
'use no memo'; | ||
const itemContext = React.useContext(PresenceGroupChildContext); | ||
@@ -31,2 +32,3 @@ const merged = { | ||
}); | ||
const animateAtoms = useAnimateAtoms(); | ||
const isFirstMount = useFirstMount(); | ||
@@ -93,2 +95,3 @@ const isReducedMotion = useIsReducedMotion(); | ||
[ | ||
animateAtoms, | ||
handleRef, | ||
@@ -95,0 +98,0 @@ isReducedMotion, |
{ | ||
"name": "@fluentui/react-motion", | ||
"version": "9.2.0", | ||
"version": "9.2.1", | ||
"description": "A package with utilities & motion definitions using Web Animations API", | ||
@@ -30,3 +30,4 @@ "main": "lib-commonjs/index.js", | ||
"e2e": "cypress run --component", | ||
"e2e:local": "cypress open --component" | ||
"e2e:local": "cypress open --component", | ||
"bundle-size": "monosize measure" | ||
}, | ||
@@ -43,3 +44,3 @@ "devDependencies": { | ||
"@fluentui/react-shared-contexts": "^9.19.0", | ||
"@fluentui/react-utilities": "^9.18.10", | ||
"@fluentui/react-utilities": "^9.18.11", | ||
"@swc/helpers": "^0.5.1", | ||
@@ -46,0 +47,0 @@ "react-is": "^17.0.2" |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Environment variable access
Supply chain riskPackage accesses environment variables, which may be a sign of credential stuffing or data theft.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
163253
1538
2