|
@@ -1,6 +1,7 @@
|
|
|
import type { IUser, Ref } from '@growi/core';
|
|
import type { IUser, Ref } from '@growi/core';
|
|
|
import { pagePathUtils } from '@growi/core/dist/utils';
|
|
import { pagePathUtils } from '@growi/core/dist/utils';
|
|
|
import dynamic from 'next/dynamic';
|
|
import dynamic from 'next/dynamic';
|
|
|
|
|
+import Image from 'next/image';
|
|
|
import { useRouter } from 'next/router';
|
|
import { useRouter } from 'next/router';
|
|
|
import {
|
|
import {
|
|
|
forwardRef,
|
|
forwardRef,
|
|
@@ -181,7 +182,9 @@ export const UserPicture = memo((userProps: Props): JSX.Element => {
|
|
|
.filter(Boolean)
|
|
.filter(Boolean)
|
|
|
.join(' ');
|
|
.join(' ');
|
|
|
|
|
|
|
|
- const imgElement = <img src={src} alt={displayName} className={className} />;
|
|
|
|
|
|
|
+ const imgElement = (
|
|
|
|
|
+ <Image src={src} alt={displayName} className={className} />
|
|
|
|
|
+ );
|
|
|
const baseProps = { displayName, size, children: imgElement };
|
|
const baseProps = { displayName, size, children: imgElement };
|
|
|
|
|
|
|
|
if (username == null || noLink) {
|
|
if (username == null || noLink) {
|