forked from Kieran/snort
bug: proxy banners
This commit is contained in:
parent
0fb387e35c
commit
08acab4831
@ -1,7 +1,8 @@
|
|||||||
import useImgProxy from "Feed/ImgProxy";
|
import useImgProxy from "Feed/ImgProxy";
|
||||||
import { useEffect, useState } from "react";
|
import { useEffect, useState } from "react";
|
||||||
|
|
||||||
export const ProxyImg = ({ src, ...rest }: { src?: string }) => {
|
export const ProxyImg = (props: any) => {
|
||||||
|
const { src, ...rest } = props;
|
||||||
const [url, setUrl] = useState<string>();
|
const [url, setUrl] = useState<string>();
|
||||||
const { proxy } = useImgProxy();
|
const { proxy } = useImgProxy();
|
||||||
|
|
||||||
|
@ -29,6 +29,7 @@ import { HexKey } from "Nostr";
|
|||||||
import FollowsYou from "Element/FollowsYou"
|
import FollowsYou from "Element/FollowsYou"
|
||||||
import QrCode from "Element/QrCode";
|
import QrCode from "Element/QrCode";
|
||||||
import Modal from "Element/Modal";
|
import Modal from "Element/Modal";
|
||||||
|
import { ProxyImg } from "Element/ProxyImg"
|
||||||
|
|
||||||
enum ProfileTab {
|
enum ProfileTab {
|
||||||
Notes = "Notes",
|
Notes = "Notes",
|
||||||
@ -193,7 +194,7 @@ export default function ProfilePage() {
|
|||||||
return (
|
return (
|
||||||
<>
|
<>
|
||||||
<div className="profile flex">
|
<div className="profile flex">
|
||||||
{user?.banner && <img alt="banner" className="banner" src={user.banner} />}
|
{user?.banner && <ProxyImg alt="banner" className="banner" src={user.banner} />}
|
||||||
<div className="profile-wrapper flex">
|
<div className="profile-wrapper flex">
|
||||||
{avatar()}
|
{avatar()}
|
||||||
{userDetails()}
|
{userDetails()}
|
||||||
|
Loading…
Reference in New Issue
Block a user