fix: readers see a remove button on a shared note's files (#33281)

Since a recent dev change, a reader opening a shared note sees the remove button on every file in the note, although clicking it does nothing. The editor was created editable and only switched to read-only afterwards, so the files were drawn as if the reader could edit. It now starts read-only for readers, and their files show without the button.

Fixes #33279
This commit is contained in:
Classic298
2026-10-29 06:30:02 +09:00
committed by GitHub
parent 58536b6503
commit 0a4be809c4
@@ -1051,6 +1051,7 @@
...(collaboration && provider ? [provider.getEditorExtension()] : [])
],
content: provider ? undefined : content,
editable,
autofocus: messageInput && !$showCallOverlay,
onTransaction: ({ transaction }) => {
if (!editor) return;