Skip to content

Commit eb173dd

Browse files
author
Joan He
committed
MAGETWO-93979: Required Field Indicators (Asterisks) Are Gone From Magento UI
1 parent a7893f9 commit eb173dd

File tree

2 files changed

+9
-7
lines changed
  • app
    • code/Magento/Ui/view/base/web/templates/form
    • design/adminhtml/Magento/backend/web/css/source/forms

2 files changed

+9
-7
lines changed

app/code/Magento/Ui/view/base/web/templates/form/field.html

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,11 @@
88
visible="visible"
99
css="$data.additionalClasses"
1010
attr="'data-index': index">
11-
<span class="admin__field-label" if="$data.label" visible="$data.labelVisible">
12-
<label translate="label" attr="'data-config-scope': $data.scopeLabel, for: uid" />
13-
</span>
11+
<div class="admin__field-label">
12+
<label if="$data.label" visible="$data.labelVisible" attr="for: uid">
13+
<span translate="label" attr="'data-config-scope': $data.scopeLabel" />
14+
</label>
15+
</div>
1416
<div class="admin__field-control"
1517
css="'_with-tooltip': $data.tooltip, '_with-reset': $data.showFallbackReset && $data.isDifferedFromDefault">
1618
<render args="elementTmpl" ifnot="hasAddons()"/>

app/design/adminhtml/Magento/backend/web/css/source/forms/_fields.less

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -210,7 +210,7 @@
210210
overflow: hidden;
211211
}
212212

213-
label {
213+
span {
214214
display: inline-block;
215215
line-height: @field-label__line-height;
216216
vertical-align: middle;
@@ -228,7 +228,7 @@
228228

229229
.required > &, // ToDo UI: change classes 'required' to '_required'.
230230
._required > & {
231-
> span {
231+
span {
232232
&:after {
233233
color: @validation__color;
234234
content: '*';
@@ -515,7 +515,7 @@
515515
position: absolute;
516516
top: 0;
517517

518-
label {
518+
span {
519519
&:before {
520520
display: block;
521521
}
@@ -530,7 +530,7 @@
530530
}
531531

532532
& > .admin__field-label {
533-
label {
533+
span {
534534
&:before {
535535
display: none;
536536
}

0 commit comments

Comments
 (0)