This is an automated email from the ASF dual-hosted git repository. riemer pushed a commit to branch dev in repository https://gitbox.apache.org/repos/asf/incubator-streampipes.git
commit 53c3d7c1aa4a888a55cc4601165acbc10eeb139e Author: Dominik Riemer <[email protected]> AuthorDate: Sat Sep 12 01:49:05 2020 +0200 [hotfix] Fix placeholder in free text static property renderer --- .../static-free-input/static-free-input.component.ts | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/ui/src/app/core-ui/static-properties/static-free-input/static-free-input.component.ts b/ui/src/app/core-ui/static-properties/static-free-input/static-free-input.component.ts index 14342cf..174a78f 100644 --- a/ui/src/app/core-ui/static-properties/static-free-input/static-free-input.component.ts +++ b/ui/src/app/core-ui/static-properties/static-free-input/static-free-input.component.ts @@ -92,8 +92,13 @@ export class StaticFreeInputComponent } applyPlaceholder(runtimeName) { - let currentIndex = this.quillEditorComponent.quillEditor.selection.savedRange.index; - this.quillEditorComponent.quillEditor.insertText(currentIndex, "#" + runtimeName + "#", "user"); + let valueToInsert = "#" + runtimeName + "#"; + if (this.quillEditorComponent) { + let currentIndex = this.quillEditorComponent.quillEditor.selection.savedRange.index; + this.quillEditorComponent.quillEditor.insertText(currentIndex, valueToInsert, "user"); + } else { + this.parentForm.controls[this.fieldName].setValue(this.parentForm.controls[this.fieldName].value + " " +valueToInsert); + } } formatLabel(value: number) {
