fix: Attach Notes shows while the Notes permission is off (#32967)

The "Attach Notes" entry in the message input's "+" menu showed to users without the Notes permission, and the list it opened only said "No notes found". It now shows only when the admin has Notes turned on and the user may use Notes, the same rule the sidebar already follows for its Notes entry.

Refs #32830
This commit is contained in:
Classic298 2026-10-23 03:46:03 +02:00 • committed by GitHub
parent 9e5a355fd2
commit 9faca2ac5b
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -333,7 +333,7 @@
</button>
</Tooltip>
{#if $config?.features?.enable_notes ?? false}
{#if ($config?.features?.enable_notes ?? false) && ($user?.role === 'admin' || ($user?.permissions?.features?.notes ?? true))}
<Tooltip
content={fileUploadCapableModels.length !== selectedModels.length
? $i18n.t('Model(s) do not support file upload')