From 591b399df4147153bbfc2f85f885131c7da68860 Mon Sep 17 00:00:00 2001 From: antoine37120 <ant.dupre@gmail.com> Date: Tue, 5 Sep 2023 17:46:42 +0200 Subject: [PATCH] fix comment form auto eval --- src/styles/evaluations.scss | 6 +++++- src/widjets-display-evaluation-tzcld.js | 18 ++++++++++-------- 2 files changed, 15 insertions(+), 9 deletions(-) diff --git a/src/styles/evaluations.scss b/src/styles/evaluations.scss index 12025ab..21f9ead 100644 --- a/src/styles/evaluations.scss +++ b/src/styles/evaluations.scss @@ -17,7 +17,11 @@ tzcld-autoeval { font-size: 16px; font-weight: 800; } - + [name="evaluation_point_answer"] { + solid-form solid-form-dropdown-label select { + padding: 12px 40px 12px 14px; + } + } } diff --git a/src/widjets-display-evaluation-tzcld.js b/src/widjets-display-evaluation-tzcld.js index a1dcc15..87d7850 100644 --- a/src/widjets-display-evaluation-tzcld.js +++ b/src/widjets-display-evaluation-tzcld.js @@ -207,7 +207,7 @@ core.Sib.register({ empty() { //console.debug(); - this.element.innerHTML = "<div>rrrrr></div>"; + this.element.innerHTML = ""; }, async populate() { @@ -256,7 +256,7 @@ core.Sib.register({ <solid-form solid-resource fields="${field_name}" data-src="${await tzcldprofile.answer['@id']}" widget-${field_name}="solid-form-dropdown-label" range-${field_name}="${apiUrl}${await tzcldPoint.point.fieldType}/" - class-${field_name}="segment margin-bottom-none full padding-left-small sm-padding-none text-xlarge text-semibold text-color-heading" + class-${field_name}="segment margin-bottom-none full padding-left-small padding-right-small sm-padding-none text-xlarge text-semibold text-color-heading" label-${field_name}=" " class-submit-button="" autosave @@ -331,12 +331,14 @@ core.Sib.register({ </div> </div> <div class="segment half padding-small text-top"> - <solid-display - data-src="\${value}" - fields="comment" - widget-comment="solid-display-div" - editable-comment - ></solid-display> + <solid-form + solid-resource bind-resources fields="comment" class="form" data-src="\${value}" + widget-comment="solid-form-textarea-label" + label-comment=" " + class-comment="segment margin-bottom-medium full sm-full padding-right-small sm-padding-none text-small text-semibold text-color-heading whitespace-normal text-xlarge" + class-submit-button="hidden" + autosave + ></solid-form> </div> </div> </template> -- GitLab