From 13ad5063935f080cde984ae2c055b8b553bb8015 Mon Sep 17 00:00:00 2001
From: Johannes Meyer <johannes.meyer@icinga.com>
Date: Mon, 22 Jul 2019 08:10:55 +0200
Subject: [PATCH] css: Rename class `icinga-forms` to `icinga-form`

---
 .../forms/Config/UserGroup/UserGroupForm.php  |  2 +-
 library/Icinga/Web/Form.php                   |  2 +-
 public/css/icinga/forms.less                  | 26 +++++++++----------
 3 files changed, 15 insertions(+), 15 deletions(-)

diff --git a/application/forms/Config/UserGroup/UserGroupForm.php b/application/forms/Config/UserGroup/UserGroupForm.php
index 10860da4d..a590524de 100644
--- a/application/forms/Config/UserGroup/UserGroupForm.php
+++ b/application/forms/Config/UserGroup/UserGroupForm.php
@@ -64,7 +64,7 @@ class UserGroupForm extends RepositoryForm
             . ' have their membership cleared automatically.'
         ));
         $this->setSubmitLabel($this->translate('Yes'));
-        $this->setAttrib('class', 'icinga-forms icinga-controls');
+        $this->setAttrib('class', 'icinga-form icinga-controls');
     }
 
     /**
diff --git a/library/Icinga/Web/Form.php b/library/Icinga/Web/Form.php
index 6dc71cc28..a2ad8f984 100644
--- a/library/Icinga/Web/Form.php
+++ b/library/Icinga/Web/Form.php
@@ -35,7 +35,7 @@ class Form extends Zend_Form
     /**
      * A form's default CSS classes
      */
-    const DEFAULT_CLASSES = 'icinga-forms icinga-controls';
+    const DEFAULT_CLASSES = 'icinga-form icinga-controls';
 
     /**
      * Identifier for notifications of type error
diff --git a/public/css/icinga/forms.less b/public/css/icinga/forms.less
index b63a657cf..8adaf351e 100644
--- a/public/css/icinga/forms.less
+++ b/public/css/icinga/forms.less
@@ -3,7 +3,7 @@
 /**
  Rules found in here are structured with two layers:
 
-  1) form.icinga-forms, that's what defines the general structure of our single/individual forms. It's not
+  1) form.icinga-form, that's what defines the general structure of our single/individual forms. It's not
      supposed to be used for any other forms that are not the only content on the page (e.g. inline-forms)
   2) .icinga-controls, this defines the design of our controls. Any input that's part of a container with
      this class gets our design applied
@@ -19,7 +19,7 @@
 
 // General form layout
 
-form.icinga-forms {
+form.icinga-form {
   max-width: 70em;
   width: 80%;
 
@@ -47,7 +47,7 @@ form.icinga-forms {
 
 #layout.minimal-layout,
 #layout.twocols:not(.wide-layout) {
-  form.icinga-forms {
+  form.icinga-form {
     width: 100%;
 
     .control-label-group {
@@ -74,7 +74,7 @@ form.icinga-forms {
 
 // Label styles
 
-form.icinga-forms .control-group .control-label-group {
+form.icinga-form .control-group .control-label-group {
   display: flex;
   flex-direction: column;
   justify-content: center;
@@ -94,10 +94,10 @@ form.icinga-forms .control-group .control-label-group {
   }
 }
 
-form.icinga-forms .control-group .control-info {
+form.icinga-form .control-group .control-info {
   margin-left: -.5em;
 }
-form.icinga-forms .control-group .toggle-switch ~ .control-info {
+form.icinga-form .control-group .toggle-switch ~ .control-info {
   margin-left: 0;
 }
 
@@ -126,7 +126,7 @@ form.inline {
   }
 }
 
-form.icinga-forms {
+form.icinga-form {
   input[type="text"],
   input[type="password"],
   input[type="number"],
@@ -166,7 +166,7 @@ form.icinga-forms {
   }
 }
 
-form.icinga-forms {
+form.icinga-form {
   .control-group .toggle-switch,
   .form-controls .toggle-switch {
     margin-top: 0.5em*0.666666667;
@@ -174,7 +174,7 @@ form.icinga-forms {
   }
 }
 
-form.icinga-forms select:not([multiple]) {
+form.icinga-form select:not([multiple]) {
   // Compensate inconsistent select height calculations
   line-height: 1em;
   height: 2.25em;
@@ -194,7 +194,7 @@ form.icinga-forms select:not([multiple]) {
   background-size: contain;
 }
 
-form.icinga-forms select {
+form.icinga-form select {
   width: 0; // Prevent selects with long option values from exceeding the container
 }
 
@@ -242,7 +242,7 @@ form.inline select {
   }
 }
 
-form.icinga-forms .form-controls {
+form.icinga-form .form-controls {
   .spinner {
     order: -1;
   }
@@ -370,7 +370,7 @@ form.icinga-forms .form-controls {
 
 // Errors and additional information
 
-form.icinga-forms {
+form.icinga-form {
   .form-notifications,
   .form-description {
     border-radius: .25em;
@@ -432,7 +432,7 @@ form.icinga-forms {
   }
 }
 
-form.icinga-forms .form-info {
+form.icinga-form .form-info {
   color: @text-color-light;
   font-size: @font-size-small;
   list-style: none;