diff --git a/src/components/Image/index.tsx b/src/components/Image/index.tsx index 2e366fd..8d1b38d 100644 --- a/src/components/Image/index.tsx +++ b/src/components/Image/index.tsx @@ -8,14 +8,10 @@ export default function Image({ image: { url, blurHash }, alt, className = '', - classNames = {}, ...props }: HTMLAttributes & { image: TImageInfo alt?: string - classNames?: { - wrapper?: string - } }) { const [isLoading, setIsLoading] = useState(true) const [displayBlurHash, setDisplayBlurHash] = useState(true) @@ -24,8 +20,8 @@ export default function Image({ useEffect(() => { if (blurHash) { const { numX, numY } = decodeBlurHashSize(blurHash) - const width = numX * 5 - const height = numY * 5 + const width = numX * 3 + const height = numY * 3 const pixels = decode(blurHash, width, height) const canvas = document.createElement('canvas') canvas.width = width @@ -41,7 +37,7 @@ export default function Image({ }, [blurHash]) return ( -
+
{isLoading && } push(toNote(event))}> +
push(toNote(event))}> -
{title}
-
- - +
+
{title}
+
+ + +
) diff --git a/src/services/client.service.ts b/src/services/client.service.ts index 17f03a1..85f020f 100644 --- a/src/services/client.service.ts +++ b/src/services/client.service.ts @@ -48,11 +48,11 @@ class ClientService extends EventTarget { private profileEventCache = new LRUCache>({ max: 10000 }) private profileEventDataloader = new DataLoader( (ids) => Promise.all(ids.map((id) => this._fetchProfileEvent(id))), - { cacheMap: this.profileEventCache } + { cacheMap: this.profileEventCache, maxBatchSize: 10 } ) private fetchProfileEventFromDefaultRelaysDataloader = new DataLoader( this.profileEventBatchLoadFn.bind(this), - { cache: false } + { cache: false, maxBatchSize: 10 } ) private relayListEventDataLoader = new DataLoader( this.relayListEventBatchLoadFn.bind(this),