From 5f0e8c66b43d76733cdffa8170c47cc643892449 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jakub=20=C4=8Curda?= Date: Fri, 27 Dec 2024 11:40:11 +0100 Subject: [PATCH] fixup! Feat(web-react): Additional parameter for styleProps and Box refactor --- .../Box/__tests__/useBoxStyleProps.test.ts | 72 ------------------- 1 file changed, 72 deletions(-) diff --git a/packages/web-react/src/components/Box/__tests__/useBoxStyleProps.test.ts b/packages/web-react/src/components/Box/__tests__/useBoxStyleProps.test.ts index 29e7805391..a285622989 100644 --- a/packages/web-react/src/components/Box/__tests__/useBoxStyleProps.test.ts +++ b/packages/web-react/src/components/Box/__tests__/useBoxStyleProps.test.ts @@ -19,78 +19,6 @@ describe('useBoxStyleProps', () => { expect(result.current.classProps).toBe('bg-secondary'); }); - it('should return padding classProps', () => { - const props: SpiritBoxProps = { - padding: 'space-400', - }; - const { result } = renderHook(() => useBoxStyleProps(props)); - - expect(result.current.classProps).toBe('p-400'); - }); - - it('should return paddingX classProps', () => { - const props: SpiritBoxProps = { - paddingX: 'space-400', - }; - const { result } = renderHook(() => useBoxStyleProps(props)); - - expect(result.current.classProps).toBe('px-400'); - }); - - it('should return paddingY classProps', () => { - const props: SpiritBoxProps = { - paddingY: 'space-400', - }; - const { result } = renderHook(() => useBoxStyleProps(props)); - - expect(result.current.classProps).toBe('py-400'); - }); - - it('should return paddingTop classProps', () => { - const props: SpiritBoxProps = { - paddingTop: 'space-400', - }; - const { result } = renderHook(() => useBoxStyleProps(props)); - - expect(result.current.classProps).toBe('pt-400'); - }); - - it('should return paddingBottom classProps', () => { - const props: SpiritBoxProps = { - paddingBottom: 'space-400', - }; - const { result } = renderHook(() => useBoxStyleProps(props)); - - expect(result.current.classProps).toBe('pb-400'); - }); - - it('should return paddingLeft classProps', () => { - const props: SpiritBoxProps = { - paddingLeft: 'space-400', - }; - const { result } = renderHook(() => useBoxStyleProps(props)); - - expect(result.current.classProps).toBe('pl-400'); - }); - - it('should return paddingRight classProps', () => { - const props: SpiritBoxProps = { - paddingRight: 'space-400', - }; - const { result } = renderHook(() => useBoxStyleProps(props)); - - expect(result.current.classProps).toBe('pr-400'); - }); - - it('should return responsive padding classProps', () => { - const props: SpiritBoxProps = { - padding: { mobile: 'space-400', tablet: 'space-500', desktop: 'space-600' }, - }; - const { result } = renderHook(() => useBoxStyleProps(props)); - - expect(result.current.classProps).toBe('p-400 p-tablet-500 p-desktop-600'); - }); - it('should return border radius classProps', () => { const props: SpiritBoxProps = { borderRadius: '200',