Skip to content

Commit

Permalink
Update Box ref prop
Browse files Browse the repository at this point in the history
  • Loading branch information
huzefakagdi committed Jul 3, 2024
1 parent 5fd1f27 commit d4bdf41
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 8 deletions.
2 changes: 1 addition & 1 deletion packages/core/src/Absolute/Absolute.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ import { Box, BoxProps } from '../Box/Box'
/**
* @public
*/
export type AbsoluteProps<T extends HTMLElement = HTMLDivElement> = BoxProps<T> &
export type AbsoluteProps = BoxProps &
TopProps &
RightProps &
BottomProps &
Expand Down
7 changes: 3 additions & 4 deletions packages/core/src/Box/Box.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import React, { type ForwardedRef } from 'react'
import React from 'react'
import styled from 'styled-components'
import {
BorderRadiusProps,
Expand Down Expand Up @@ -38,7 +38,7 @@ import { applyVariations, color, colorScheme } from '../utils/utils'
/**
* @public
*/
export type BoxProps<T extends HTMLElement = HTMLDivElement> = Omit<BorderRadiusProps, 'borderRadius'> &
export type BoxProps = Omit<BorderRadiusProps, 'borderRadius'> &
BoxShadowProps &
DisplayProps &
HeightProps &
Expand All @@ -51,7 +51,7 @@ export type BoxProps<T extends HTMLElement = HTMLDivElement> = Omit<BorderRadius
SpaceProps &
TextAlignProps &
WidthProps &
React.HTMLAttributes<T> & {
React.ComponentPropsWithRef<'div'> & {
children?: React.ReactNode
as?: unknown
role?: string
Expand Down Expand Up @@ -79,7 +79,6 @@ export type BoxProps<T extends HTMLElement = HTMLDivElement> = Omit<BorderRadius
| 'background'
colorScheme?: ColorSchemeName
onClick?: React.ComponentProps<'div'>['onClick']
ref?: ForwardedRef<T>
rounded?:
| 'round'
| 'top'
Expand Down
2 changes: 1 addition & 1 deletion packages/core/src/Flex/Flex.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ import { applyVariations } from '../utils/utils'
/**
* @public
*/
export type FlexProps<T extends HTMLElement = HTMLDivElement> = BoxProps<T> &
export type FlexProps = BoxProps &
SpaceProps &
WidthProps &
AlignItemsProps &
Expand Down
4 changes: 2 additions & 2 deletions packages/core/src/Relative/Relative.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -17,12 +17,12 @@ import { Box, type BoxProps } from '../Box/Box'
/**
* @public
*/
export type RelativeProps<T extends HTMLElement = HTMLDivElement> = TopProps &
export type RelativeProps = TopProps &
RightProps &
BottomProps &
LeftProps &
ZIndexProps &
BoxProps<T>
BoxProps

/**
* @public
Expand Down

0 comments on commit d4bdf41

Please sign in to comment.