Bootstrap词缀总是在最后一个标签上

时间:2015-03-05 11:59:39

标签: javascript html css angularjs twitter-bootstrap

我正在尝试实现引导词缀,我有一个问题,如果内容不够大,无法滚动它总是将最后一个标签显示为当前。这是我的jsfiddle

在页面上我即使有足够的内容进行滚动时也会发生这种情况,标签总是指向最后一个元素。

这是我的代码,我很抱歉这个烂摊子:

<body data-spy="scroll" data-target="#myScrollSpy">

    <div class="container-fluid" role="main" style="padding-top: 2em" ng-controller="resultsPageController">

        <div class="row">
            <div class="col-md-1" id="myScrollSpy">
                <ul class="nav nav-tabs nav-stacked" data-spy="affix" >
                    <li class="active"><a href="#search">Top</a></li>
                    <li><a href="#results">Results</a></li>
                    <li><a href="#love1">Love 1</a></li>
                    <li><a href="#love2">Love 2</a></li>
                </ul>
            </div>
            <div class="col-md-6" infinite-scroll="searchService.search()" ng-controller="searchController">
                <div id="search" ng-include="'static/html/search-bar.html'"></div>
                <div id="results">
                    <tabset>
                        <!--<tab ng-repeat="tab in tabs" heading="{{tab.title}}" select="setMode($index)" active="tab.active">
                        <div ng-include="tab.include"  ng-if="tab.active"></div>
                        </tab>!-->
                        <tab heading="lala">
                            <ul class="media-list">
                                <li class="media" id="love1">
                                    <span class="title">Love - Wikipedia, the free encyclopedia</span>
                                    <br />
                                    <span
                                    class="description">Love is a variety of different feelings, states, and attitudes that ranges from
                                        interpersonal affection ("I love my mother") to pleasure ("I loved that meal").</span>
                                    <br />
                                    <span class="url"><img
                                        src="http://upload.wikimedia.org/wikipedia/commons/b/b0/Wikipedia-favicon.png" alt="favicon" width="16px" />&nbsp;&nbsp;en.wikipedia.org/wiki/Love</span>
                                </li>
                                <li class="media" id="love2">
                                    <span class="title">Love - Wikipedia, the free encyclopedia</span>
                                    <br />
                                    <span
                                    class="description">Love is a variety of different feelings, states, and attitudes that ranges from
                                        interpersonal affection ("I love my mother") to pleasure ("I loved that meal").</span>
                                    <br />
                                    <span class="url"><img
                                        src="http://upload.wikimedia.org/wikipedia/commons/b/b0/Wikipedia-favicon.png" alt="favicon" width="16px" />&nbsp;&nbsp;en.wikipedia.org/wiki/Love</span>
                                </li>
                            </ul>
                        </tab>
                    </tabset>
                </div>
            </div>
        </div>
    </div>
</body>

0 个答案:

没有答案