New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Bug 1839073: Calculate max width for VM wizard general form #5578
Bug 1839073: Calculate max width for VM wizard general form #5578
Conversation
@pcbailey: This pull request references Bugzilla bug 1839073, which is valid. The bug has been moved to the POST state. The bug has been updated to refer to the pull request using the external bug tracker. 3 validation(s) were run on this bug
In response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
I think we may need it in providers and init forms too: |
@@ -6,3 +6,9 @@ | |||
.kubevirt-create-vm-modal__memory-row { | |||
margin-right: 0.5em; | |||
} | |||
|
|||
.kubevirt-create-vm-modal__form { | |||
@media (min-width: 1200px) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can you look what removing padding and margin do, I think it looks nicer WDYT ?
margin: 0;
padding: 0;
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I may be misunderstanding you or missing something, but let me explain my logic and then you can tell me where I'm wrong.
If we're trying to match the size of the OCP forms, I don't think removing the padding and margin is enough. That element only has a total of 60px of padding and no margin. So, the max width we can gain from removing them is 60px.
In OCP forms and the wizard general tab form, the forms will take up 50% of the available space in viewports greater than 1200px. The problem is the size of the available space:
OCP available space = browser width - side nav
Wizard available space = browser width - side nav - wizard nav (300px) - pf-c-wizard--main padding (64px) - OCP padding (60px)
The cleanest way I could think of to match the OCP forms at any given width of a large viewport is to simply calculate it. Thoughts?
7653fbc
to
2541a8e
Compare
/lgtm |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: pcbailey, yaacov The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
@pcbailey: All pull requests linked via external trackers have merged: openshift/console#5578. Bugzilla bug 1839073 has been moved to the MODIFIED state. In response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
Currently, the width of the general tab form in the VM wizard is narrower than other forms at larger viewport sizes. This is due to additional padding added by the
pf-c-wizard--main
class and the added width of the wizard side navigation. This PR calculates themax-width
of the form, compensating for these additional values.