mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 14:05:37 +02:00
Merge branch 'tabstyling' of https://github.com/ajshort/sapphire into ajshort-tabstyling
This commit is contained in:
commit
43483090b4
@ -603,27 +603,16 @@ form.import-form p { margin-bottom: 5px; }
|
|||||||
form.import-form label.left { width: 250px; }
|
form.import-form label.left { width: 250px; }
|
||||||
|
|
||||||
/** -------------------------------------------- Page Edit Controller -------------------------------------------- */
|
/** -------------------------------------------- Page Edit Controller -------------------------------------------- */
|
||||||
.cms-container .CMSMain.CMSPageEditController { margin-left: -1px; }
|
.cms-container .CMSPageEditController, .cms-container .CMSPageSettingsController, .cms-container .CMSPageHistoryController { margin-left: -1px; }
|
||||||
.cms-container .CMSMain.CMSPageEditController .cms-edit-form { background: #e6eaed; }
|
.cms-container .CMSPageEditController .cms-edit-form, .cms-container .CMSPageSettingsController .cms-edit-form, .cms-container .CMSPageHistoryController .cms-edit-form { background: #e6eaed; }
|
||||||
.cms-container .CMSMain.CMSPageEditController .cms-edit-form .ui-tabs-nav { border-bottom: none; float: right; margin: 8px 0 -1px 0; padding: 0 24px 0 0; }
|
.cms-container .CMSPageEditController .cms-edit-form .ui-tabs-nav, .cms-container .CMSPageSettingsController .cms-edit-form .ui-tabs-nav, .cms-container .CMSPageHistoryController .cms-edit-form .ui-tabs-nav { border-bottom: none; float: right; margin: 8px 0 -1px 0; padding: 0 24px 0 0; }
|
||||||
.cms-container .CMSMain.CMSPageEditController .cms-edit-form .ui-tabs-nav li { float: left; }
|
.cms-container .CMSPageEditController .cms-edit-form .ui-tabs-nav li, .cms-container .CMSPageSettingsController .cms-edit-form .ui-tabs-nav li, .cms-container .CMSPageHistoryController .cms-edit-form .ui-tabs-nav li { float: left; }
|
||||||
.cms-container .CMSMain.CMSPageEditController .cms-edit-form .ui-tabs-nav li a { font-weight: bold; line-height: 16px; padding: 8px 20px 8px; }
|
.cms-container .CMSPageEditController .cms-edit-form .ui-tabs-nav li a, .cms-container .CMSPageSettingsController .cms-edit-form .ui-tabs-nav li a, .cms-container .CMSPageHistoryController .cms-edit-form .ui-tabs-nav li a { font-weight: bold; line-height: 16px; padding: 8px 20px 8px; }
|
||||||
.cms-container .CMSMain.CMSPageEditController .cms-edit-form .ui-tabs-nav .ui-state-default, .cms-container .CMSMain.CMSPageEditController .cms-edit-form .ui-tabs-nav .ui-widget-content .ui-state-default, .cms-container .CMSMain.CMSPageEditController .cms-edit-form .ui-tabs-nav .ui-widget-header .ui-state-default { border: 1px solid #c0c0c2; }
|
.cms-container .CMSPageEditController .cms-edit-form .ui-tabs-nav .ui-state-default, .cms-container .CMSPageEditController .cms-edit-form .ui-tabs-nav .ui-widget-content .ui-state-default, .cms-container .CMSPageEditController .cms-edit-form .ui-tabs-nav .ui-widget-header .ui-state-default, .cms-container .CMSPageSettingsController .cms-edit-form .ui-tabs-nav .ui-state-default, .cms-container .CMSPageSettingsController .cms-edit-form .ui-tabs-nav .ui-widget-content .ui-state-default, .cms-container .CMSPageSettingsController .cms-edit-form .ui-tabs-nav .ui-widget-header .ui-state-default, .cms-container .CMSPageHistoryController .cms-edit-form .ui-tabs-nav .ui-state-default, .cms-container .CMSPageHistoryController .cms-edit-form .ui-tabs-nav .ui-widget-content .ui-state-default, .cms-container .CMSPageHistoryController .cms-edit-form .ui-tabs-nav .ui-widget-header .ui-state-default { border: 1px solid #c0c0c2; }
|
||||||
.cms-container .CMSMain.CMSPageEditController .cms-edit-form .ui-tabs-nav .ui-state-active, .cms-container .CMSMain.CMSPageEditController .cms-edit-form .ui-tabs-nav .ui-widget-content .ui-state-active, .cms-container .CMSMain.CMSPageEditController .cms-edit-form .ui-tabs-nav .ui-widget-header .ui-state-active { padding-bottom: 1px; background: #e6eaed; border: 1px solid #c0c0c2; }
|
.cms-container .CMSPageEditController .cms-edit-form .ui-tabs-nav .ui-state-active, .cms-container .CMSPageEditController .cms-edit-form .ui-tabs-nav .ui-widget-content .ui-state-active, .cms-container .CMSPageEditController .cms-edit-form .ui-tabs-nav .ui-widget-header .ui-state-active, .cms-container .CMSPageSettingsController .cms-edit-form .ui-tabs-nav .ui-state-active, .cms-container .CMSPageSettingsController .cms-edit-form .ui-tabs-nav .ui-widget-content .ui-state-active, .cms-container .CMSPageSettingsController .cms-edit-form .ui-tabs-nav .ui-widget-header .ui-state-active, .cms-container .CMSPageHistoryController .cms-edit-form .ui-tabs-nav .ui-state-active, .cms-container .CMSPageHistoryController .cms-edit-form .ui-tabs-nav .ui-widget-content .ui-state-active, .cms-container .CMSPageHistoryController .cms-edit-form .ui-tabs-nav .ui-widget-header .ui-state-active { padding-bottom: 1px; background: #e6eaed; border: 1px solid #c0c0c2; }
|
||||||
.cms-container .CMSMain.CMSPageEditController .ss-tabset .ss-tabset { position: static; }
|
.cms-container .CMSPageEditController .ss-tabset .ss-tabset, .cms-container .CMSPageSettingsController .ss-tabset .ss-tabset, .cms-container .CMSPageHistoryController .ss-tabset .ss-tabset { position: static; }
|
||||||
.cms-container .CMSMain.CMSPageEditController .ss-tabset .ui-tabs-panel { background: #e6eaed; border-top: 1px solid #c0c0c2; clear: both; }
|
.cms-container .CMSPageEditController .ss-tabset .ui-tabs-panel, .cms-container .CMSPageSettingsController .ss-tabset .ui-tabs-panel, .cms-container .CMSPageHistoryController .ss-tabset .ui-tabs-panel { background: #e6eaed; border-top: 1px solid #c0c0c2; clear: both; }
|
||||||
.cms-container .CMSPageSettingsController .cms-edit-form { background: #e6eaed; }
|
.cms-container .CMSPageEditController .ss-tabset.ss-tabset-tabshidden .ui-tabs-panel, .cms-container .CMSPageSettingsController .ss-tabset.ss-tabset-tabshidden .ui-tabs-panel, .cms-container .CMSPageHistoryController .ss-tabset.ss-tabset-tabshidden .ui-tabs-panel { border-top: none; }
|
||||||
.cms-container .CMSPageSettingsController .cms-edit-form .ui-tabs-nav { float: right; margin: 8px 40px -1px 0; }
|
|
||||||
.cms-container .CMSPageSettingsController .cms-edit-form .ui-tabs-nav li a { font-weight: bold; line-height: 16px; padding: 8px 20px 8px; }
|
|
||||||
.cms-container .CMSPageSettingsController .cms-edit-form .ui-tabs-nav .ui-state-default, .cms-container .CMSPageSettingsController .cms-edit-form .ui-tabs-nav .ui-widget-content .ui-state-default, .cms-container .CMSPageSettingsController .cms-edit-form .ui-tabs-nav .ui-widget-header .ui-state-default { border: 1px solid #c0c0c2; }
|
|
||||||
.cms-container .CMSPageSettingsController .cms-edit-form .ui-tabs-nav .ui-state-active, .cms-container .CMSPageSettingsController .cms-edit-form .ui-tabs-nav .ui-widget-content .ui-state-active, .cms-container .CMSPageSettingsController .cms-edit-form .ui-tabs-nav .ui-widget-header .ui-state-active { padding-bottom: 1px; background: #e6eaed; border: 1px solid #c0c0c2; }
|
|
||||||
.cms-container .CMSPageSettingsController .ss-tabset .ui-tabs-panel { background: #e6eaed; clear: both; /* border-top:1px solid $color-button-generic-border; */ }
|
|
||||||
.cms-container .CMSPageHistoryController .cms-edit-form { background: #e6eaed; }
|
|
||||||
.cms-container .CMSPageHistoryController .cms-edit-form .ui-tabs-nav { float: right; margin: 8px 24px -1px 0; }
|
|
||||||
.cms-container .CMSPageHistoryController .cms-edit-form .ui-tabs-nav li a { font-weight: bold; line-height: 16px; padding: 8px 20px 8px; }
|
|
||||||
.cms-container .CMSPageHistoryController .cms-edit-form .ui-tabs-nav .ui-state-default, .cms-container .CMSPageHistoryController .cms-edit-form .ui-tabs-nav .ui-widget-content .ui-state-default, .cms-container .CMSPageHistoryController .cms-edit-form .ui-tabs-nav .ui-widget-header .ui-state-default { border: 1px solid #c0c0c2; }
|
|
||||||
.cms-container .CMSPageHistoryController .cms-edit-form .ui-tabs-nav .ui-state-active, .cms-container .CMSPageHistoryController .cms-edit-form .ui-tabs-nav .ui-widget-content .ui-state-active, .cms-container .CMSPageHistoryController .cms-edit-form .ui-tabs-nav .ui-widget-header .ui-state-active { padding-bottom: 1px; background: #e6eaed; border: 1px solid #c0c0c2; }
|
|
||||||
.cms-container .CMSPageHistoryController .ss-tabset .ui-tabs-panel { background: #e6eaed; clear: both; /* border-top:1px solid $color-button-generic-border; */ }
|
|
||||||
|
|
||||||
/** -------------------------------------------- Page Settings Controller -------------------------------------------- */
|
/** -------------------------------------------- Page Settings Controller -------------------------------------------- */
|
||||||
.cms-container .CMSMain.CMSPageSettingsController .tab#Root_Settings .optionset li { white-space: nowrap; padding-top: 8px; }
|
.cms-container .CMSMain.CMSPageSettingsController .tab#Root_Settings .optionset li { white-space: nowrap; padding-top: 8px; }
|
||||||
|
@ -205,8 +205,12 @@
|
|||||||
*/
|
*/
|
||||||
$('.cms-edit-form .ss-tabset').entwine({
|
$('.cms-edit-form .ss-tabset').entwine({
|
||||||
onmatch: function() {
|
onmatch: function() {
|
||||||
var tabs = this.find("ul:first").children('li');
|
var tabs = this.find("> ul:first");
|
||||||
if(tabs.length == 1) this.find('ul:first').hide();
|
|
||||||
|
if(tabs.children("li").length == 1) {
|
||||||
|
tabs.hide().parent().addClass("ss-tabset-tabshidden");
|
||||||
|
}
|
||||||
|
|
||||||
this._super();
|
this._super();
|
||||||
},
|
},
|
||||||
onunmatch: function() {
|
onunmatch: function() {
|
||||||
|
@ -1728,7 +1728,7 @@ form.import-form {
|
|||||||
* -------------------------------------------- */
|
* -------------------------------------------- */
|
||||||
|
|
||||||
.cms-container {
|
.cms-container {
|
||||||
.CMSMain.CMSPageEditController {
|
.CMSPageEditController, .CMSPageSettingsController, .CMSPageHistoryController {
|
||||||
// Fix pixel gap between nav tree and main page header
|
// Fix pixel gap between nav tree and main page header
|
||||||
margin-left: -1px; // Removed to close gap far right of right tabs?
|
margin-left: -1px; // Removed to close gap far right of right tabs?
|
||||||
//Styling of tabs on page edit
|
//Styling of tabs on page edit
|
||||||
@ -1774,75 +1774,11 @@ form.import-form {
|
|||||||
border-top:1px solid $color-button-generic-border;
|
border-top:1px solid $color-button-generic-border;
|
||||||
clear: both;
|
clear: both;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
&.ss-tabset-tabshidden .ui-tabs-panel {
|
||||||
|
border-top: none;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
//Styling of tabs on page settings
|
|
||||||
.CMSPageSettingsController {
|
|
||||||
.cms-edit-form {
|
|
||||||
background:darken($color-widget-bg, 2%);
|
|
||||||
.ui-tabs-nav {
|
|
||||||
float:right;
|
|
||||||
margin:$grid-x $grid-x*5 -1px 0;
|
|
||||||
li {
|
|
||||||
a {
|
|
||||||
font-weight: bold;
|
|
||||||
line-height: $grid-y * 2;
|
|
||||||
padding: $grid-y $grid-x*2.5 $grid-y;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
.ui-state-default,
|
|
||||||
.ui-widget-content .ui-state-default,
|
|
||||||
.ui-widget-header .ui-state-default {
|
|
||||||
border:1px solid $color-button-generic-border;
|
|
||||||
}
|
|
||||||
.ui-state-active,
|
|
||||||
.ui-widget-content .ui-state-active,
|
|
||||||
.ui-widget-header .ui-state-active {
|
|
||||||
padding-bottom:1px;
|
|
||||||
background:darken($color-widget-bg, 2%);
|
|
||||||
border:1px solid $color-button-generic-border;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
.ss-tabset .ui-tabs-panel {
|
|
||||||
background:darken($color-widget-bg, 2%);
|
|
||||||
clear:both;
|
|
||||||
/* border-top:1px solid $color-button-generic-border; */
|
|
||||||
}
|
|
||||||
}
|
|
||||||
//Styling of tabs on page History
|
|
||||||
.CMSPageHistoryController {
|
|
||||||
.cms-edit-form {
|
|
||||||
background:darken($color-widget-bg, 2%);
|
|
||||||
.ui-tabs-nav {
|
|
||||||
float:right;
|
|
||||||
margin:$grid-x $grid-x*3 -1px 0;
|
|
||||||
li {
|
|
||||||
a {
|
|
||||||
font-weight: bold;
|
|
||||||
line-height: $grid-y * 2;
|
|
||||||
padding: $grid-y $grid-x*2.5 $grid-y;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
.ui-state-default,
|
|
||||||
.ui-widget-content .ui-state-default,
|
|
||||||
.ui-widget-header .ui-state-default {
|
|
||||||
border:1px solid $color-button-generic-border;
|
|
||||||
}
|
|
||||||
.ui-state-active,
|
|
||||||
.ui-widget-content .ui-state-active,
|
|
||||||
.ui-widget-header .ui-state-active {
|
|
||||||
padding-bottom:1px;
|
|
||||||
background:darken($color-widget-bg, 2%);
|
|
||||||
border:1px solid $color-button-generic-border;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
.ss-tabset .ui-tabs-panel {
|
|
||||||
background:darken($color-widget-bg, 2%);
|
|
||||||
clear:both;
|
|
||||||
/* border-top:1px solid $color-button-generic-border; */ // Double border?
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user