You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
13 lines
477 B
13 lines
477 B
4 years ago
|
import * as React from 'react';
|
||
|
import RcImage, { ImageProps } from 'rc-image';
|
||
|
import { ConfigConsumerProps, ConfigContext } from '../config-provider';
|
||
|
|
||
|
const Image: React.FC<ImageProps> = ({ prefixCls: customizePrefixCls, ...otherProps }) => {
|
||
|
const { getPrefixCls }: ConfigConsumerProps = React.useContext(ConfigContext);
|
||
|
const prefixCls = getPrefixCls('image', customizePrefixCls);
|
||
|
|
||
|
return <RcImage prefixCls={prefixCls} {...otherProps} />;
|
||
|
};
|
||
|
|
||
|
export default Image;
|