From be84f9a54d46b68053b5edde0f901ca6dd03f606 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20Krier?= Date: Tue, 14 May 2024 19:44:39 +0200 Subject: [PATCH] Put textarea and richtext under an input-group If the widget is translatable, the translate button is an input-group-btn which must be under the same input-group as the principal input. Closes #13238 (grafted from 20af97ade53035f1c725cb2600e9abbb2664f664) --HG-- branch : 6.0 --- sao/src/sao.less | 2 +- sao/src/view/form.js | 22 ++++++++++++++-------- 2 files changed, 15 insertions(+), 9 deletions(-) diff --git a/sao/src/sao.less b/sao/src/sao.less index bac1b8d556..89a8baa2b8 100644 --- a/sao/src/sao.less +++ b/sao/src/sao.less @@ -636,7 +636,7 @@ img.icon { } } .form-text, .form-richtext { - > textarea, .richtext { + textarea, .richtext { height: 100%; line-height: 2.5ex; min-height: 12.5ex; diff --git a/sao/src/view/form.js b/sao/src/view/form.js index 39cfb4d9a4..523a81c23f 100644 --- a/sao/src/view/form.js +++ b/sao/src/view/form.js @@ -2149,10 +2149,13 @@ function eval_pyson(value){ this.el = jQuery('
', { 'class': this.class_ }); + this.group = jQuery('
', { + 'class': 'input-group', + }).appendTo(this.el); this.input = this.labelled = jQuery('