minor #27886 [Form] Removed .form-control-label class. (vudaltsov)

This PR was squashed before being merged into the 3.4 branch (closes #27886).

Discussion
----------

[Form] Removed .form-control-label class.

| Q             | A
| ------------- | ---
| Branch?       | 3.4
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets |
| License       | MIT
| Doc PR        |

There is no such a class neither in [bootstrap 4.0](https://getbootstrap.com/docs/4.0/components/forms/#form-controls) nor in [bootstrap 4.1](https://getbootstrap.com/docs/4.1/components/forms/#form-controls).

Commits
-------

cb3e712698 [Form] Removed .form-control-label class.
This commit is contained in:
Nicolas Grekas 2018-07-09 14:42:10 +02:00
commit 55ddaee7b1
3 changed files with 9 additions and 9 deletions

View File

@ -187,7 +187,7 @@
{%- set element = 'legend' -%}
{%- set label_attr = label_attr|merge({class: (label_attr.class|default('') ~ ' col-form-label')|trim}) -%}
{%- else -%}
{%- set label_attr = label_attr|merge({for: id, class: (label_attr.class|default('') ~ ' form-control-label')|trim}) -%}
{%- set label_attr = label_attr|merge({for: id}) -%}
{%- endif -%}
{% if required -%}
{% set label_attr = label_attr|merge({class: (label_attr.class|default('') ~ ' required')|trim}) %}

View File

@ -72,7 +72,7 @@ abstract class AbstractBootstrap4HorizontalLayoutTest extends AbstractBootstrap4
$this->assertMatchesXpath($html,
'/label
[@for="name"]
[@class="col-form-label col-sm-2 form-control-label required"]
[@class="col-form-label col-sm-2 required"]
'
);
}
@ -89,7 +89,7 @@ abstract class AbstractBootstrap4HorizontalLayoutTest extends AbstractBootstrap4
$this->assertMatchesXpath($html,
'/label
[@for="name"]
[@class="my&class col-form-label col-sm-2 form-control-label required"]
[@class="my&class col-form-label col-sm-2 required"]
'
);
}
@ -106,7 +106,7 @@ abstract class AbstractBootstrap4HorizontalLayoutTest extends AbstractBootstrap4
$this->assertMatchesXpath($html,
'/label
[@for="name"]
[@class="my&class col-form-label col-sm-2 form-control-label required"]
[@class="my&class col-form-label col-sm-2 required"]
[.="[trans]Custom label[/trans]"]
'
);
@ -126,7 +126,7 @@ abstract class AbstractBootstrap4HorizontalLayoutTest extends AbstractBootstrap4
$this->assertMatchesXpath($html,
'/label
[@for="name"]
[@class="my&class col-form-label col-sm-2 form-control-label required"]
[@class="my&class col-form-label col-sm-2 required"]
[.="[trans]Custom label[/trans]"]
'
);

View File

@ -81,7 +81,7 @@ abstract class AbstractBootstrap4LayoutTest extends AbstractBootstrap3LayoutTest
$this->assertMatchesXpath($html,
'/label
[@for="name"]
[@class="form-control-label required"]
[@class="required"]
'
);
}
@ -98,7 +98,7 @@ abstract class AbstractBootstrap4LayoutTest extends AbstractBootstrap3LayoutTest
$this->assertMatchesXpath($html,
'/label
[@for="name"]
[@class="my&class form-control-label required"]
[@class="my&class required"]
'
);
}
@ -115,7 +115,7 @@ abstract class AbstractBootstrap4LayoutTest extends AbstractBootstrap3LayoutTest
$this->assertMatchesXpath($html,
'/label
[@for="name"]
[@class="my&class form-control-label required"]
[@class="my&class required"]
[.="[trans]Custom label[/trans]"]
'
);
@ -135,7 +135,7 @@ abstract class AbstractBootstrap4LayoutTest extends AbstractBootstrap3LayoutTest
$this->assertMatchesXpath($html,
'/label
[@for="name"]
[@class="my&class form-control-label required"]
[@class="my&class required"]
[.="[trans]Custom label[/trans]"]
'
);