Skip to content

Commit c2ce312

Browse files
authored
fix(form): inline calendar fields did not display properly
When a ui calendar is used within a inline field, its display was broken (shrunk and not inline) I had to use a proper direct em setting to fix this, as the input field is inside the calendar component making the usual width: auto not work as for the other standard input form fields.
1 parent c512cf2 commit c2ce312

File tree

2 files changed

+11
-0
lines changed

2 files changed

+11
-0
lines changed

src/definitions/collections/form.less

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1097,6 +1097,16 @@
10971097
font-size: @inlineInputSize;
10981098
}
10991099

1100+
.ui.form .inline.fields .field .calendar:not(.popup),
1101+
.ui.form .inline.field .calendar:not(.popup) {
1102+
display:inline-block;
1103+
}
1104+
1105+
.ui.form .inline.fields .field .calendar:not(.popup) > .input > input,
1106+
.ui.form .inline.field .calendar:not(.popup) > .input > input {
1107+
width: @inlineCalendarWidth;
1108+
}
1109+
11001110
/* Label */
11011111
.ui.form .inline.fields .field > :first-child,
11021112
.ui.form .inline.field > :first-child {

src/themes/default/collections/form.variables

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -158,6 +158,7 @@
158158
@inlineLabelFontSize: @labelFontSize;
159159
@inlineLabelFontWeight: @labelFontWeight;
160160
@inlineLabelTextTransform: @labelTextTransform;
161+
@inlineCalendarWidth: 13.11em;
161162

162163
@groupedInlineLabelMargin: 0.035714em 1em 0 0;
163164

0 commit comments

Comments
 (0)