TSK-1252: Dispatch update event for attribute bar (#3017)

Signed-off-by: Anton Brechka <anton.brechka@ezthera.com>
This commit is contained in:
Anton Brechka 2023-04-19 23:13:07 +07:00 committed by GitHub
parent f3ff78843d
commit c917f9c59a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -42,9 +42,11 @@
function onChange (value: any) {
const doc = object as Doc
dispatch('update', { key, value })
if (draft) {
;(doc as any)[attributeKey] = value
dispatch('update', { key, value })
} else {
updateAttribute(client, doc, doc._class, { key: attributeKey, attr: attribute }, value)
}