Permalink
Browse files

Fixed panel spacing regressions from 544d2eb

Specifically, the change removed the "add page" panel padding,
because it moved padding from .cms-panel-padded into
commonly contained elements, like .ui-tabs-panel.
Apart from breaking layouts, it makes the class meaningless,
since its only padded depending on which elements it contains.

In order to rectify some introduced inconsistencies,
much too complex were required, e.g.
.ui-tabs .cms-edit-form, .ui-tabs .cms-content-fields {...}.
  • Loading branch information...
chillu committed Dec 17, 2012
1 parent 407a19c commit 6028cf1b625ae268c7c3e08b5f5afb265a32c598
Showing with 38 additions and 53 deletions.
  1. +11 −15 admin/css/screen.css
  2. +26 −36 admin/scss/_style.scss
  3. +1 −1 css/AssetUploadField.css
  4. +0 −1 scss/AssetUploadField.scss
View

Some generated files are not rendered by default. Learn more.

Oops, something went wrong.
View
@@ -159,7 +159,7 @@ body.cms {
}
.ui-tabs-panel {
- padding: $grid-x 0;
+ padding: $grid-x*2;
background: transparent; // default it's white
border: 0; // suppress default borders
&.cms-edit-form {
@@ -174,7 +174,7 @@ body.cms {
.ui-tabs-nav {
float: right;
- margin: 0 0 -1px 0;
+ margin: $grid-x*2 0 -1px 0;
padding: 0 $grid-x*1.5 0 0;
border-bottom: none;
@@ -250,43 +250,17 @@ body.cms {
}
}
- .cms-edit-form, .cms-content-fields { /*not sure if .cms-content-fields effects other areas*/
- .cms-panel-padded { /* Has padded area inside it */
- padding: 0;
- margin: 0;
- }
- .ui-tabs-panel, .ss-gridfield {
- margin: 12px;
- padding: 0 0 12px;
- .ss-gridfield { /* Files area & inside second level tabs */
- padding: 0; /* should be zero ideally */
- margin: 0 0 12px;
- }
- }
- .ui-tabs-nav {
- margin: 10px 12px 0;
- padding: 0 8px 0 0; /* second set of tabs */
- }
- #tree_actions .ui-tabs-nav{
- margin: 0;
- }
- }
-
.cms-panel-padded {
- h3 {
- margin-left: 12px; /* reports headers, probably too specific */
- }
.ui-tabs-panel {
- margin: 0;
- padding: 12px 12px 12px;
+ padding: 0; // Avoid double padding with parent
.ui-tabs-panel {
padding: $grid-x 0 0 0;
}
}
- }
- .ui-tabs .ui-tabs-panel { /* second level tabs */
- padding-top: 8px;
+ .Actions {
+ padding: 0; // Avoid double padding with parent
+ }
}
&.ss-tabset-tabshidden .ui-tabs-panel {
@@ -301,6 +275,7 @@ body.cms {
.ui-tabs.cms-tabset-primary .ui-tabs-nav,
.ui-tabs .ui-tabs-nav.cms-tabset-nav-primary,
.ui-tabs .cms-content-header-tabs .ui-tabs-nav {
+ margin-top: 0;
border-left: 1px solid darken($color-tab, 15%);
float: none; // parent container is already right floated
@@ -483,8 +458,17 @@ body.cms {
margin: 0;
}
}
-p.message {
- margin-bottom: $grid-y*1.5;
+
+
+.cms-edit-form {
+ .message {
+ margin: $grid-x*2; // TODO Remove double padding when adjacent to a padded tabs panel
+ }
+ .ui-tabs-panel {
+ .message {
+ margin: 0 0 $grid-x*2 0; // gets padding from tab panel
+ }
+ }
}
/** --------------------------------------------
@@ -704,7 +688,7 @@ p.message {
.cms-panel-content {
width: ($grid-x * 23);
- padding: $grid-x $grid-x 0;
+ padding: $grid-x*2 $grid-x 0; // smaller left/right padding to use space efficiently
overflow: auto;
height:100%;
@@ -924,7 +908,6 @@ form.member-profile-form {
#Root_Main {
clear:both;
border-top: 1px solid darken($color-tab, 20%);
- padding-top:$grid-y*2;
.cms-help-toggle {
text-indent: -9999em;
display: inline-block;
@@ -1210,6 +1193,13 @@ form.member-profile-form {
}
}
+.cms {
+ .cms-panel-padded {
+ padding: $grid-y*2 $grid-x*2;
+ margin:0;
+ }
+}
+
/** ------------------------------------------------------------------
* Dialog
*
View

Some generated files are not rendered by default. Learn more.

Oops, something went wrong.
@@ -17,7 +17,6 @@
#AssetUploadField {
border-bottom: 0;
@include box-shadow(none);
- padding: 12px;
}
.backlink {
padding-left: 12px;

0 comments on commit 6028cf1

Please sign in to comment.