Change classname "image-loader" to custom Tailwind
This commit is contained in:
parent
46e849d8e3
commit
348a4f4bbf
|
@ -135,16 +135,16 @@ class ImageLoader extends React.PureComponent<IImageLoader> {
|
||||||
const { alt, src, width, height, onClick } = this.props;
|
const { alt, src, width, height, onClick } = this.props;
|
||||||
const { loading } = this.state;
|
const { loading } = this.state;
|
||||||
|
|
||||||
const className = clsx('image-loader', {
|
const className = 'relative size-full flex items-center justify-center flex-col';
|
||||||
'image-loader--loading': loading,
|
|
||||||
'image-loader--amorphous': !this.hasSize(),
|
|
||||||
});
|
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div className={className}>
|
<div className={className}>
|
||||||
{loading ? (
|
{loading ? (
|
||||||
<canvas
|
<canvas
|
||||||
className='image-loader__preview-canvas'
|
className={clsx('max-h-[80%] max-w-full object-contain', { 'hidden': !this.hasSize() })}
|
||||||
|
style={{
|
||||||
|
background: 'url(\'../assets/images/void.png\') repeat',
|
||||||
|
}}
|
||||||
ref={this.setCanvasRef}
|
ref={this.setCanvasRef}
|
||||||
width={width}
|
width={width}
|
||||||
height={height}
|
height={height}
|
||||||
|
|
Loading…
Reference in New Issue