From 0ea3b63458bd12b707be620e7f5b581027ff6c7f Mon Sep 17 00:00:00 2001 From: Sukhwinder Dhillon Date: Thu, 27 Mar 2025 09:33:39 +0100 Subject: [PATCH] Controller: Remove obsolete if condition Ipl-web manages this now --- library/Icingadb/Web/Controller.php | 6 +----- library/Icingadb/Widget/ItemTable/StateItemTable.php | 2 +- public/css/common.less | 11 ----------- 3 files changed, 2 insertions(+), 17 deletions(-) diff --git a/library/Icingadb/Web/Controller.php b/library/Icingadb/Web/Controller.php index ffa711ac..ae812047 100644 --- a/library/Icingadb/Web/Controller.php +++ b/library/Icingadb/Web/Controller.php @@ -37,8 +37,6 @@ use ipl\Html\ValidHtml; use ipl\Orm\Query; use ipl\Orm\UnionQuery; use ipl\Stdlib\Filter; -use ipl\Web\Common\BaseItemList; -use ipl\Web\Common\BaseItemTable; use ipl\Web\Compat\CompatController; use ipl\Web\Control\LimitControl; use ipl\Web\Control\PaginationControl; @@ -486,9 +484,7 @@ class Controller extends CompatController protected function addContent(ValidHtml $content) { - if ($content instanceof BaseItemList || $content instanceof BaseItemTable) { - $this->content->getAttributes()->add('class', 'full-width'); - } elseif ($content instanceof StateItemTable) { + if ($content instanceof StateItemTable) { $this->content->getAttributes()->add('class', 'full-height'); } diff --git a/library/Icingadb/Widget/ItemTable/StateItemTable.php b/library/Icingadb/Widget/ItemTable/StateItemTable.php index f392322a..251ed7c4 100644 --- a/library/Icingadb/Widget/ItemTable/StateItemTable.php +++ b/library/Icingadb/Widget/ItemTable/StateItemTable.php @@ -16,7 +16,7 @@ use ipl\Web\Control\SortControl; use ipl\Web\Widget\EmptyStateBar; use ipl\Web\Widget\Icon; -/** @todo Figure out what this might (should) have in common with the new BaseItemTable implementation */ +/** @todo Figure out what this might (should) have in common with the new ItemTable implementation */ abstract class StateItemTable extends BaseHtmlElement { protected $baseAttributes = [ diff --git a/public/css/common.less b/public/css/common.less index 291b79e7..73d51663 100644 --- a/public/css/common.less +++ b/public/css/common.less @@ -4,17 +4,6 @@ @iplWebAssets: "../lib/icinga/icinga-php-library"; }; -& > .content.full-width { - padding-left: 0; - padding-right: 0; - - .list-item, - .table-row { - padding-left: 1em; - padding-right: 1em; - } -} - & > .content.full-height { padding-top: 0; padding-bottom: 0;