0

我想在页面左侧有一个垂直拆分视图栏,它像data-position="fixed"我拥有的​​标题栏一样保持固定。

就像在这个例子中一样(编辑:这个链接现在坏了),但左边的列表也固定了,与标题一起标记。

我考虑过尝试将其插入标题中以“继承”固定定位。不确定这是否可行。

这是我的样式表的内容。

.content-right {
    float: right;
    width: 75%;
}
.content-left {
    width: 23%; /* Not 25%: I am not using padding */
}

div 首先出现.content-right在 HTML 中。

如果固定标题被隐藏(通过单击),我还希望该栏优雅地向上滑动,但这并不重要(我现在可以强制单击隐藏)。

4

2 回答 2

2

Nothing out of the box.

You could use my multiview plugin, which is in the works. I'm finishing the navigation and panel history right now. Plus fixing everything for tablet/smartphone view. If you don't mind the bugs still in there for now it would be ready to use (please post issues on Github).

Here is one sample page I'm working currently testing with: sample-overthrow

This view locks the screen and scrolls each panel separately using overthrow. Nothing to configure except add data-scrollmode="overthrow" to the wrapper page. Check the HTML to see how its set up. Also beware, this is my first attempt at integrating Overthrow and it's not very smooth yet.

in which the whole page scrolls like a regular JQM page. This is the default behavior.

You can use 1/2/3 panels side by side (need to label them "menu", "mid" and "main", I'm removing "fullwidth" from the code - used in previous versions), so if you only want a "navbar/sidebar" on the side, just use a menu with ... 50px width and put your toolbar in there. The main panel should scale automatically to fill the screen. I also started on a yield-mode which allows to slide in/out the toolbar. Haven't got around to finishing this yet.

于 2012-04-25T22:07:06.183 回答
0

我想出的解决方案在左侧使用一个固定的 div,而右侧是自然滚动的实际“页面”。

由于我的左 div 超出了页面,因此在桌面浏览器上,滚动条也离开了页面。这需要处理。但是,在iOS5上,完美-webkit-overflow-scrolling: touch的使用 了固定的div滚动功能!

于 2012-04-28T15:56:43.063 回答