Skip to content

Commit

Permalink
chore(MessageBar): roll back deprecations of MessageBarTransitionContext
Browse files Browse the repository at this point in the history
- based on code review
  • Loading branch information
robertpenner committed Dec 13, 2024
1 parent d4bfcac commit 9fe67fb
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 16 deletions.
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
import * as React from 'react';

/**
* @deprecated Code is unused, replaced by motion components
*/
export type MessageBarTransitionContextValue = {
/**
* @deprecated CSS className is no longer used for this transition, replaced by motion components
*/
className: string;
nodeRef: React.Ref<HTMLDivElement | null>;
};
Expand All @@ -12,22 +12,19 @@ const messageBarTransitionContext = React.createContext<MessageBarTransitionCont

/**
* @internal
* @deprecated Code is unused, replaced by motion components
*/
export const messageBarTransitionContextDefaultValue: MessageBarTransitionContextValue = {
className: '',
nodeRef: React.createRef<HTMLDivElement | null>(),
};

/**
* Context to pass animation className to MessageBar components
* Context to pass nodeRef for animation to MessageBar components
* @internal
* @deprecated Code is unused, replaced by motion components
*/
export const MessageBarTransitionContextProvider = messageBarTransitionContext.Provider;
/**
* @internal
* @deprecated Code is unused, replaced by motion components
*/
export const useMessageBarTransitionContext = () =>
React.useContext(messageBarTransitionContext) ?? messageBarTransitionContextDefaultValue;
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,9 @@ export const createCollapsePresence: PresenceMotionFnCreator<CollapseVariantPara
// @public
export const createFadePresence: PresenceMotionCreator<FadeVariantParams>;

// @public
export const createScalePresence: PresenceMotionFnCreator<ScaleVariantParams_unstable, ScaleRuntimeParams_unstable>;

// @public
export const Fade: PresenceComponent< {}>;

Expand All @@ -46,19 +49,13 @@ export const FadeRelaxed: PresenceComponent< {}>;
export const FadeSnappy: PresenceComponent< {}>;

// @public
export const Scale: PresenceComponent< {
animateOpacity?: boolean | undefined;
}>;
export const Scale: PresenceComponent<ScaleRuntimeParams_unstable>;

// @public (undocumented)
export const ScaleRelaxed: PresenceComponent< {
animateOpacity?: boolean | undefined;
}>;
export const ScaleRelaxed: PresenceComponent<ScaleRuntimeParams_unstable>;

// @public (undocumented)
export const ScaleSnappy: PresenceComponent< {
animateOpacity?: boolean | undefined;
}>;
export const ScaleSnappy: PresenceComponent<ScaleRuntimeParams_unstable>;

// (No @packageDocumentation comment for this package)

Expand Down

0 comments on commit 9fe67fb

Please sign in to comment.