diff --git a/Iceshrimp.Frontend/Components/AttachmentComponent.razor b/Iceshrimp.Frontend/Components/AttachmentComponent.razor index 5b0aa510..907c4999 100644 --- a/Iceshrimp.Frontend/Components/AttachmentComponent.razor +++ b/Iceshrimp.Frontend/Components/AttachmentComponent.razor @@ -1,40 +1,35 @@ @using Iceshrimp.Assets.PhosphorIcons @using Iceshrimp.Shared.Schemas.Web -@if (Attachment.ContentType.StartsWith("image")) -{ -
+ +
+ @if (Attachment.ContentType.StartsWith("image")) + { @Attachment.AltText -
-} -// else if (Attachment.ContentType == "audio/x-mod") -// { -// TODO: Module player -// } -else if (Attachment.ContentType.StartsWith("audio")) -{ -
+ } +// else if (Attachment.ContentType == "audio/x-mod") +// { +// TODO: Module player +// } + else if (Attachment.ContentType.StartsWith("audio")) + { -
-} -else if (Attachment.ContentType.StartsWith("video")) -{ -
+ } + else if (Attachment.ContentType.StartsWith("video")) + { -
-} -else -{ -
+ } + else + { @Attachment.Url.Split("/").Last() -
-} + } +
@code { [Parameter] [EditorRequired] public required NoteAttachment Attachment { get; set; }