Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.

Bug 1543528

Summary: Improper text alignment in 'Upload Image' dialogue (one column instead of four)
Product: [oVirt] ovirt-engine Reporter: Radek Duda <rduda>
Component: Frontend.WebAdminAssignee: Daniel Erez <derez>
Status: CLOSED CURRENTRELEASE QA Contact: samuel macko <smacko>
Severity: low Docs Contact:
Priority: unspecified    
Version: 4.2.1.4CC: amureini, awels, bugs, derez, lsvaty, tjelinek, tnisan
Target Milestone: ovirt-4.2.2Flags: rule-engine: ovirt-4.2+
Target Release: 4.2.2.2   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: ovirt-engine-4.2.2.5 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2018-03-29 11:03:58 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: Storage RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
Screenshot of wrongly aligned text
none
proper alignment none

Description Radek Duda 2018-02-08 16:10:17 UTC
Created attachment 1393246 [details]
Screenshot of wrongly aligned text

Description of problem:
Informational text containing uploaded file parameters is improperly aligned.

Version-Release number of selected component (if applicable):
ovirt-engine-webadmin-portal-4.2.1.6-0.1.el7.noarch

How reproducible:
always

Steps to Reproduce:
1. Open Firefox, adjust dimensions of its window to have width < 979 pixels
2. open rhv42 admin portal and go to 'Upload Image' dialogue (Storage > Disks)
3. Hit button 'Choose File' and choose some file (does not matter)

Actual results:
Text of file properties is formed to one column and overlaps to table underneath, so that those properties are barely readable.

Expected results:
Text of file properties should be formed to four columns as is when Firefox window width > 979 pixels.

Comment 1 Radek Duda 2018-02-08 16:10:49 UTC
Created attachment 1393247 [details]
proper alignment

Comment 2 Allon Mureinik 2018-02-12 10:57:10 UTC
Looks like a low hanging fruit - let's just fix this.
If it's too much work, please push out to 4.2.4

Comment 3 Daniel Erez 2018-02-12 15:42:17 UTC
@Alex - do we support such low resolutions in the webadmin (iirc, the supported minimum was 1024x768)? If we should support it, can we fix it in GeneralFormPanel, as the same issue also affects the general sub tabs.

Comment 4 Radek Duda 2018-02-16 11:04:03 UTC
this applies also for rhv 4.1.10

Comment 5 Alexander Wels 2018-02-26 13:04:15 UTC
Interesting I wrote a whole reply to this but it disappeared. Anyway, since 4.2 we basically support any resolution including low resolution mobile devices. The solution to your problem is to replace SM_XX with XS_XX in the ui binder of the popup dialog. That will stop the wrapping to the next line when you make the browser small enough. That fix should also backport to 4.1, however many other dialogs will have a similar issue in 4.1

In the form panel we want them to wrap like that when the resolution becomes low enough.

Comment 6 Daniel Erez 2018-03-14 15:06:13 UTC
(In reply to Alexander Wels from comment #5)
> Interesting I wrote a whole reply to this but it disappeared. Anyway, since
> 4.2 we basically support any resolution including low resolution mobile
> devices. The solution to your problem is to replace SM_XX with XS_XX in the
> ui binder of the popup dialog. That will stop the wrapping to the next line

The specific dialog (UploadImagePopupView) is using ImageInfoForm component (which extends AbstractModelBoundFormWidget), which encapsulates the FormBuilder. Where should we add the XS_XX? Don't we need a support in the GeneralFormPanel for that first?

> when you make the browser small enough. That fix should also backport to
> 4.1, however many other dialogs will have a similar issue in 4.1
> 
> In the form panel we want them to wrap like that when the resolution becomes
> low enough.

Comment 7 Alexander Wels 2018-03-14 17:33:45 UTC
Okay, looked into it a little more you are correct, if you open up AbstractFormPanel, you will find a COL_PREFIX which defines the prefix used in the column widths, its md_ right now, try either sm_ or xs_ and if that fixes it for you.

Comment 8 Allon Mureinik 2018-03-15 13:44:04 UTC
Daniel, this looks like a safe and trivial patch to cherry-pick. Can we have this in 4.2[.z] too?

Comment 9 Daniel Erez 2018-03-15 14:04:44 UTC
(In reply to Allon Mureinik from comment #8)
> Daniel, this looks like a safe and trivial patch to cherry-pick. Can we have
> this in 4.2[.z] too?

sure, I'll backport it.

Comment 10 samuel macko 2018-03-26 10:36:54 UTC
Verified in ovirt version 4.2.2.5-0.1.el7.

Verified by following the reproducer.

Comment 11 Sandro Bonazzola 2018-03-29 11:03:58 UTC
This bugzilla is included in oVirt 4.2.2 release, published on March 28th 2018.

Since the problem described in this bug report should be
resolved in oVirt 4.2.2 release, it has been closed with a resolution of CURRENT RELEASE.

If the solution does not work for you, please open a new bug report.