@atom-learning/components 3.26.4 → 3.26.5

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/CHANGELOG.md CHANGED
@@ -1,9 +1,9 @@
1
- ## [3.26.4](https://github.com/Atom-Learning/components/compare/v3.26.3...v3.26.4) (2024-06-27)
1
+ ## [3.26.5](https://github.com/Atom-Learning/components/compare/v3.26.4...v3.26.5) (2024-07-02)
2
2
 
3
3
 
4
4
  ### Bug Fixes
5
5
 
6
- * props being passed to a fragment with asChild in Accordion.Trigger ([5893e3e](https://github.com/Atom-Learning/components/commit/5893e3e3cb4bf52ee99a0e777d19f5c4182837cb))
6
+ * do EmptyState sizing via context so it propagates to nested or extended components ([ec054db](https://github.com/Atom-Learning/components/commit/ec054db40524862703bc3f8c86a1275eb7aa429d))
7
7
 
8
8
  # [1.4.0](https://github.com/Atom-Learning/components/compare/v1.3.0...v1.4.0) (2022-04-11)
9
9
 
@@ -0,0 +1,8 @@
1
+ import * as React from 'react';
2
+ import type { EmptyStateProps } from './EmptyState';
3
+ declare type EmptyStateProviderProps = {
4
+ size?: EmptyStateProps['size'];
5
+ };
6
+ export declare const EmptyStateContext: React.Context<EmptyStateProviderProps>;
7
+ export declare const EmptyStateProvider: ({ size, children }: React.PropsWithChildren<EmptyStateProviderProps>) => JSX.Element;
8
+ export {};
@@ -0,0 +1,2 @@
1
+ import*as e from"react";const r=e.createContext({}),a=({size:t,children:o})=>{const n=e.useMemo(()=>({size:t}),[t]);return e.createElement(r.Provider,{value:n},o)};export{r as EmptyStateContext,a as EmptyStateProvider};
2
+ //# sourceMappingURL=EmptyState.context.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"EmptyState.context.js","sources":["../../../src/components/empty-state/EmptyState.context.tsx"],"sourcesContent":["import * as React from 'react'\n\nimport type { EmptyStateProps } from './EmptyState'\n\ntype EmptyStateProviderProps = {\n size?: EmptyStateProps['size']\n}\n\ntype EmptyStateContextValue = EmptyStateProviderProps\n\nexport const EmptyStateContext = React.createContext<EmptyStateContextValue>({})\n\nexport const EmptyStateProvider = ({\n size,\n children\n}: React.PropsWithChildren<EmptyStateProviderProps>) => {\n const value = React.useMemo<EmptyStateContextValue>(() => ({ size }), [size])\n return (\n <EmptyStateContext.Provider value={value}>\n {children}\n </EmptyStateContext.Provider>\n )\n}\n"],"names":["EmptyStateContext","React","EmptyStateProvider","size","children","value"],"mappings":"wBAUO,MAAMA,EAAoBC,EAAM,cAAsC,CAAA,CAAE,EAElEC,EAAqB,CAAC,CACjC,KAAAC,EACA,SAAAC,CACF,IAAwD,CACtD,MAAMC,EAAQJ,EAAM,QAAgC,KAAO,CAAE,KAAAE,CAAK,GAAI,CAACA,CAAI,CAAC,EAC5E,OACEF,EAAA,cAACD,EAAkB,SAAlB,CAA2B,MAAOK,CAAAA,EAChCD,CACH,CAEJ"}