отладка прикрепления файлов

This commit is contained in:
2026-06-17 22:07:52 +03:00
parent 043595beff
commit 9c4535e8c1
3 changed files with 34 additions and 26 deletions
+6 -4
View File
@@ -1,3 +1,4 @@
import { Paperclip } from "lucide-react";
import { useRef } from "react";
import { ApiError } from "../api/client";
@@ -81,15 +82,16 @@ export function MatchMedia({
))}
</div>
)}
{editable && (
{editable && !full && (
<>
<button
className="btn small"
style={{ marginTop: 8 }}
style={{ marginTop: 8, gap: 6 }}
onClick={() => fileRef.current?.click()}
disabled={pending || full}
disabled={pending}
>
{full ? `Максимум ${max} фото` : "Добавить фото"}
<Paperclip size={16} />
Прикрепить медиа
</button>
<input
ref={fileRef}