import React from 'react';
import { Image as ImagePrimitive, ImageProps as ImagePropsPrimitive } from '@modulz/primitives';

export type ImageProps = ImagePropsPrimitive

type ExtractRefType<TypesThatMayContainReactRef> = TypesThatMayContainReactRef extends {ref?: React.Ref<infer T>} ? T : unknown;
type PrimitiveRefType = ExtractRefType<ImagePropsPrimitive>  

export const Image = React.forwardRef<PrimitiveRefType, ImageProps>((props, ref) => {
  return (
    <ImagePrimitive {...props} ref={ref}  styleConfig={{"base":{"image":{"normal":{"borderBottomLeftRadius":"0px","borderBottomRightRadius":"0px","borderTopLeftRadius":"0px","borderTopRightRadius":"0px"}}},"variants":{}}}/>
  );
});


