我正在使用layout.jquery插件。
我正在尝试为Wast Pane创建一个自定义切换器。
如何创建旋转文本div作为切换器。
请参见下面的图片。
JSFIDDLE:https://jsfiddle.net/kap0e06s/3/
HTML:
<div class="myDiv" style="height:400px">
<div class="ui-layout-center">Center</div>
<div class="ui-layout-north">North</div>
<div class="ui-layout-south">South</div>
<div class="ui-layout-east">East</div>
<div class="ui-layout-west">West</div>
</div>
JS:
$('.myDiv').layout({
resizeWhileDragging: true,
sizable: false,
animatePaneSizing: true,
fxSpeed: 'slow',
west__spacing_closed: 0,
west__spacing_open: 0,
north__spacing_closed: 0,
north__spacing_open: 0,
});
最佳答案
抱歉...无法正确创建jsfiddle。这是修改后的代码:
JS:
// OUTER-LAYOUT
$('.myDiv').layout({
resizeWhileDragging: true,
sizable: false,
livePaneResizing: true,
animatePaneSizing: true,
fxSpeed: 'slow',
west__spacing_closed: 0,
west__spacing_open: 0,
north__spacing_closed: 0,
north__spacing_open: 0,
east__spacing_open: 50,
});
CSS:
body {
background-color: white;
}
.ui-layout-center,
.ui-layout-north,
.ui-layout-south,
.ui-layout-east,
.ui-layout-west {
border: 0px;
}
.ui-layout-toggler{
background-image: url("http://placehold.it/50/ff9933/ffffff?text=Panel");
}