fixed client review player annotations
Deploy / deploy (push) Successful in 2m46s

This commit is contained in:
twotalesanimation
2026-07-02 15:58:20 +02:00
parent 75d5149bea
commit 7026a5342b
4 changed files with 125 additions and 3 deletions
@@ -445,6 +445,23 @@ export default function ClientReviewPage({
comments={comments as any}
versionId={version.id}
onAddComment={handlePlayerAddComment}
saveAnnotationFn={async (data) => {
const res = await fetch(`/api/client/${token}/annotation`, {
method: "POST",
headers: { "Content-Type": "application/json" },
body: JSON.stringify(data),
});
if (!res.ok) throw new Error("Failed to save annotation");
}}
addCommentFn={async (data) => {
const res = await fetch(`/api/client/${token}/comment`, {
method: "POST",
headers: { "Content-Type": "application/json" },
body: JSON.stringify(data),
});
if (!res.ok) throw new Error("Failed to post comment");
await refreshComments(token, version.id);
}}
/>
</div>