From c8e12c45ec6434232fcf460f1af6597ef9eb2d45 Mon Sep 17 00:00:00 2001 From: danidfra Date: Tue, 10 Dec 2024 22:43:03 -0300 Subject: [PATCH] Remove ImmutableList of "attachment.ts" --- src/components/preview-card.tsx | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/components/preview-card.tsx b/src/components/preview-card.tsx index c9f70c981..19e7bcd79 100644 --- a/src/components/preview-card.tsx +++ b/src/components/preview-card.tsx @@ -3,7 +3,6 @@ import linkIcon from '@tabler/icons/outline/link.svg'; import playerPlayIcon from '@tabler/icons/outline/player-play.svg'; import zoomInIcon from '@tabler/icons/outline/zoom-in.svg'; import clsx from 'clsx'; -import { List as ImmutableList } from 'immutable'; import { useState, useEffect, useRef } from 'react'; import Blurhash from 'soapbox/components/blurhash.tsx'; @@ -22,7 +21,7 @@ interface IPreviewCard { card: CardEntity; maxTitle?: number; maxDescription?: number; - onOpenMedia: (attachments: ImmutableList, index: number) => void; + onOpenMedia: (attachments: Attachment[], index: number) => void; compact?: boolean; defaultWidth?: number; cacheWidth?: (width: number) => void; @@ -75,7 +74,7 @@ const PreviewCard: React.FC = ({ }, }); - onOpenMedia(ImmutableList([attachment]), 0); + onOpenMedia([attachment], 0); }; const handleEmbedClick: React.MouseEventHandler = (e) => {