From 123f5ed10a0f6ba02ee0c8545bed2e9eb25bca1a Mon Sep 17 00:00:00 2001 From: Alex Wuttke Date: Fri, 2 Mar 2018 11:45:24 +0100 Subject: [PATCH] Work around MultiColumnWizard select styling and behavior issues. Select doesn't get a fixed width automatically because, unlike the ModuleWizard, MultiColumnWizard doesn't add the tl_select_column CSS class. After row duplication, select options can only be selected when chosen is used: https://github.com/menatwork/MultiColumnWizard/issues/188 --- dca/tl_layout.php | 16 ++++++++++++++-- 1 file changed, 14 insertions(+), 2 deletions(-) diff --git a/dca/tl_layout.php b/dca/tl_layout.php index c7d750b..2d0beb1 100644 --- a/dca/tl_layout.php +++ b/dca/tl_layout.php @@ -45,12 +45,24 @@ 'col' => [ 'label' => &$GLOBALS['TL_LANG']['tl_layout']['fallbackArticlesCol'], 'inputType' => 'select', - 'options_callback' => [Layout::class, 'getSections'] + 'options_callback' => [Layout::class, 'getSections'], + 'eval' => [ + // MultiColumnWizard doesn't set tl_select_column class + 'style' => 'width: 140px;', + // see https://github.com/menatwork/MultiColumnWizard/issues/188 + 'chosen' => true + ] ], 'fallback' => [ 'label' => &$GLOBALS['TL_LANG']['tl_layout']['fallbackArticlesFallback'], 'inputType' => 'select', - 'options_callback' => [Layout::class, 'getFallbackMethods'] + 'options_callback' => [Layout::class, 'getFallbackMethods'], + 'eval' => [ + // MultiColumnWizard doesn't set tl_select_column class + 'style' => 'width: 140px;', + // see https://github.com/menatwork/MultiColumnWizard/issues/188 + 'chosen' => true + ] ] ] ],