@ssa-ui-kit/core 2.32.0-canary-b64be64-20251219 → 2.32.0-canary-6379a60-20251223

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.
@@ -1,13 +1,18 @@
1
- import React from 'react';
1
+ import { type ComponentType } from 'react';
2
2
  /**
3
3
  * React 19 compatibility wrapper for Nivo responsive components.
4
4
  *
5
- * @nivo/core's ResponsiveWrapper returns an object in React 19, which causes
6
- * type checking issues. This utility wraps any Nivo responsive component
7
- * with forwardRef to ensure it's recognized as a proper React component.
5
+ * @nivo components can be received as module objects instead of functions due to
6
+ * CommonJS/ESM interop issues. This wrapper detects and unwraps such objects,
7
+ * then creates a functional component wrapper.
8
8
  *
9
- * @param Component - The Nivo responsive component to wrap (e.g., ResponsiveLine, ResponsivePie)
10
- * @param displayName - The display name for the wrapped component
11
- * @returns A React 19 compatible version of the component
9
+ * The unwrapping process checks for:
10
+ * - .default export (CommonJS/ESM default export)
11
+ * - .ResponsiveWrapper property (Nivo's internal wrapper)
12
+ * - Direct function component
13
+ *
14
+ * @param Component - The Nivo responsive component (e.g., ResponsiveLine, ResponsivePie)
15
+ * @param displayName - Display name for debugging in React DevTools
16
+ * @returns A React 19 compatible functional component
12
17
  */
13
- export declare function wrapNivoResponsiveComponent<T extends React.ComponentType<any>>(Component: T, displayName: string): T;
18
+ export declare function wrapNivoResponsiveComponent<T extends ComponentType<any>>(Component: T, displayName?: string): T;
@@ -8,7 +8,4 @@ export type FullscreenModeContextType = {
8
8
  export declare const FullscreenModeContext: import("react").Context<FullscreenModeContextType>;
9
9
  export declare const FullscreenModeProvider: ({ children, }: React.PropsWithChildren) => import("@emotion/react/jsx-runtime").JSX.Element;
10
10
  export declare const useFullscreenMode: () => FullscreenModeContextType;
11
- export declare const WithFullscreenMode: <T extends object>(Component: React.ComponentType<T>, rest?: Parameters<typeof FullscreenModeProvider>[0]) => {
12
- (props: T): import("@emotion/react/jsx-runtime").JSX.Element;
13
- displayName: string;
14
- };
11
+ export declare const WithFullscreenMode: <T extends object>(Component: React.ComponentType<T>, rest?: Parameters<typeof FullscreenModeProvider>[0]) => React.ComponentType<T>;