Commit 11b815bc authored by Jérome Perrin's avatar Jérome Perrin

web_renderjs_ui: make bottom editor not too big in dialog mode

- introduce a `form_dialog` class on dialog gadget, so that we can apply
different styles.
- add a rule overriding the rule making "big" editors in bottom group so
that in dialog mode they are not so big.
- force the maximize class to apply its height as !important, because
the added selector being more specific, it has priority over the one
from maximize.

http://lesscss.org/less-preview/ has been used to compile .less in .css
parent eabda869
......@@ -1187,6 +1187,9 @@ div[data-gadget-scope='header'] .ui-header ul {
.gadget-content .bottom div[data-gadget-url$="gadget_erp5_field_listbox.html"] iframe {
height: 30vh;
}
.gadget-content .form_dialog .bottom iframe {
height: 20em;
}
.gadget-content form .ui-field-contain {
position: relative;
}
......@@ -1761,7 +1764,7 @@ div[data-gadget-scope='maximize'] button:active {
height: calc(100vh - 30pt );
}
.editor-maximize div[data-gadget-scope='editor'] iframe {
height: 100%;
height: 100% !important;
}
/**********************************************
* Front page
......
......@@ -260,8 +260,8 @@
</tuple>
<state>
<tuple>
<float>1533747628.29</float>
<string>UTC</string>
<float>1542086791.36</float>
<string>GMT+9</string>
</tuple>
</state>
</object>
......
......@@ -33,7 +33,7 @@
</section>
<!-- XXX action, method, fieldset -->
<form>
<form class="form_dialog">
<div data-gadget-url="gadget_erp5_form.html"
data-gadget-scope="erp5_form"
data-gadget-sandbox="public">
......
......@@ -252,8 +252,8 @@
</tuple>
<state>
<tuple>
<float>1537196435.99</float>
<string>UTC</string>
<float>1542080124.77</float>
<string>GMT+9</string>
</tuple>
</state>
</object>
......
......@@ -1386,6 +1386,16 @@ div[data-gadget-scope='header'] .ui-header {
}
}
}
// In form_dialog, we don't want editors to be too big, because there
// is a dialog_button_container below, which we want to be in viewport
.form_dialog {
.bottom {
iframe {
height: 20em;
}
}
}
/*
@media @smartphone {
......@@ -2002,7 +2012,9 @@ div[data-gadget-scope='maximize'] button {
width: 100vw;
height: ~"calc(100vh - "@headerheight~")";
iframe {
height: 100%;
// this is !important because we want it to have priority over
// the rule for form_dialog bottom iframe rule
height: 100% !important;
}
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment