From 4101ce11a48ee7f38b807f9000a5c6c6997a9f9c Mon Sep 17 00:00:00 2001 From: Dariusz Szut Date: Wed, 28 Jun 2023 14:12:19 +0200 Subject: [PATCH] QA --- .../CKEditor/custom-attributes/custom-attributes-command.js | 2 +- .../custom-attributes/ui/custom-attributes-form-view.js | 4 ++-- src/bundle/Resources/public/scss/_balloon-form.scss | 1 + 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/src/bundle/Resources/public/js/CKEditor/custom-attributes/custom-attributes-command.js b/src/bundle/Resources/public/js/CKEditor/custom-attributes/custom-attributes-command.js index b0a5fd68..d3f6fc9b 100644 --- a/src/bundle/Resources/public/js/CKEditor/custom-attributes/custom-attributes-command.js +++ b/src/bundle/Resources/public/js/CKEditor/custom-attributes/custom-attributes-command.js @@ -28,7 +28,7 @@ class IbexaCustomAttributesCommand extends Command { const hasOwnCustomClasses = elementCustomClassesConfig && selectedCustomClasses - .split() + .split(' ') .every((selectedCustomClass) => elementCustomClassesConfig.choices.includes(selectedCustomClass)); if (elementName === modelElement.name || hasOwnCustomClasses) { diff --git a/src/bundle/Resources/public/js/CKEditor/custom-attributes/ui/custom-attributes-form-view.js b/src/bundle/Resources/public/js/CKEditor/custom-attributes/ui/custom-attributes-form-view.js index c700c296..610743b9 100644 --- a/src/bundle/Resources/public/js/CKEditor/custom-attributes/ui/custom-attributes-form-view.js +++ b/src/bundle/Resources/public/js/CKEditor/custom-attributes/ui/custom-attributes-form-view.js @@ -209,8 +209,8 @@ class IbexaCustomAttributesFormView extends View { addListToDropdown(labeledDropdown.fieldView, itemsList); this.listenTo(labeledDropdown.fieldView, 'execute', (event) => { - const alreadySelectedValues = labeledDropdown.fieldView.element.value ? labeledDropdown.fieldView.element.value.split(',') : []; - const value = config.multiple ? [...new Set([...alreadySelectedValues, event.source.value])].join(',') : event.source.value; + const alreadySelectedValues = labeledDropdown.fieldView.element.value ? labeledDropdown.fieldView.element.value.split(' ') : []; + const value = config.multiple ? [...new Set([...alreadySelectedValues, event.source.value])].join(' ') : event.source.value; labeledDropdown.fieldView.buttonView.set({ label: value, diff --git a/src/bundle/Resources/public/scss/_balloon-form.scss b/src/bundle/Resources/public/scss/_balloon-form.scss index c5d0b88f..aa644b81 100644 --- a/src/bundle/Resources/public/scss/_balloon-form.scss +++ b/src/bundle/Resources/public/scss/_balloon-form.scss @@ -25,6 +25,7 @@ .ck-button.ck-dropdown__button { .ck-button__label { width: calculateRem(198px); + display: inline-block; } } }