blur placeholder on article images
This commit is contained in:
1 parent
df229b5e8c
commit
8260e3cf34
9 files changed
+1108
-81
No files matched your search
@@ -36,11 +36,14 @@ export const Picture: React.FC<PictureProps> = memo(({ wide = false, ...props })
|
||||
return (
|
||||
<figure className={`${s.pic} ${layout} ${w ? s.wide : ''}`}>
|
||||
<Image
|
||||
className={s.img}
|
||||
src={props.src}
|
||||
alt={props.alt}
|
||||
// alt={props.alt}
|
||||
width={props.width}
|
||||
height={props.height}
|
||||
layout={'responsive'}
|
||||
blurDataURL={props.blur}
|
||||
placeholder={'blur'}
|
||||
/>
|
||||
{!props.caption ? null : (
|
||||
<figcaption>{props.caption}</figcaption>
|
||||
|
||||
@@ -16,8 +16,12 @@
|
||||
max-width: 80%;
|
||||
}
|
||||
|
||||
.pic img {
|
||||
.img {
|
||||
border-radius: var(--radius);
|
||||
|
||||
/* override nextjs blurred placeholder filter */
|
||||
/* need for border radius */
|
||||
filter: none !important;
|
||||
}
|
||||
|
||||
.pic figcaption {
|
||||
|
||||
Reference in new issue
Block a user