Skip to content
This repository has been archived by the owner on May 29, 2019. It is now read-only.

chore(docs): fix bootlint warnings #4075

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
68 changes: 33 additions & 35 deletions misc/demo/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -24,41 +24,39 @@
<link rel="author" href="https://github.com/angular-ui/bootstrap/graphs/contributors">
</head>
<body class="ng-cloak" ng-controller="MainCtrl">
<header class="navbar navbar-default navbar-fixed-top">
<div class="navbar-inner">
<div class="container">
<div class="navbar-header">
<button type="button" class="navbar-toggle" data-toggle="collapse" data-target="#bs-example-navbar-collapse-3" ng-click="isCollapsed = !isCollapsed">
<span class="sr-only">Toggle navigation</span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
<a class="navbar-brand visible-xs" href="#">UI Bootstrap</a>
</div>
<nav class="hidden-xs">
<ul class="nav navbar-nav">
<a href="#top" role="button" class="navbar-brand">
UI Bootstrap
</a>
<li class="dropdown" dropdown>
<a role="button" class="dropdown-toggle" dropdown-toggle>
Directives <b class="caret"></b>
</a>
<ul class="dropdown-menu">
<% demoModules.forEach(function(module) { %><li><a href="#<%= module.name %>"><%= module.displayName %></a></li><% }); %>
</ul>
</li>
<li><a href="#getting_started">Getting started</a></li>
</ul>
</nav>
<nav class="visible-xs" collapse="!isCollapsed">
<ul class="nav navbar-nav">
<li><a href="#getting_started" ng-click="isCollapsed = !isCollapsed">Getting started</a></li>
<li><a href="#directives_small" ng-click="isCollapsed = !isCollapsed">Directives</a></li>
</ul>
</nav>
<header class="navbar navbar-default navbar-fixed-top navbar-inner">
<div class="container">
<div class="navbar-header">
<button type="button" class="navbar-toggle" data-toggle="collapse" data-target="#bs-example-navbar-collapse-3" ng-click="isCollapsed = !isCollapsed">
<span class="sr-only">Toggle navigation</span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
<a class="navbar-brand visible-xs" href="#">UI Bootstrap</a>
</div>
<nav class="hidden-xs">
<ul class="nav navbar-nav">
<a href="#top" role="button" class="navbar-brand">
UI Bootstrap
</a>
<li class="dropdown" dropdown>
<a role="button" class="dropdown-toggle" dropdown-toggle>
Directives <b class="caret"></b>
</a>
<ul class="dropdown-menu">
<% demoModules.forEach(function(module) { %><li><a href="#<%= module.name %>"><%= module.displayName %></a></li><% }); %>
</ul>
</li>
<li><a href="#getting_started">Getting started</a></li>
</ul>
</nav>
<nav class="visible-xs" collapse="!isCollapsed">
<ul class="nav navbar-nav">
<li><a href="#getting_started" ng-click="isCollapsed = !isCollapsed">Getting started</a></li>
<li><a href="#directives_small" ng-click="isCollapsed = !isCollapsed">Directives</a></li>
</ul>
</nav>
</div>
</header>
<div class="header-placeholder"></div>
Expand Down Expand Up @@ -195,7 +193,7 @@ <h1><%= module.displayName %><small>
<div class="row code">
<div class="col-md-12" ng-controller="PlunkerCtrl">
<div class="pull-right">
<button class="btn btn-info" id="plunk-btn" ng-click="edit('<%= ngversion%>', '<%= bsversion %>', '<%= pkg.version%>', '<%= module.name %>')"><i class="glyphicon glyphicon-edit"></i> Edit in plunker</button>
<button type="button" class="btn btn-info plunk-btn" ng-click="edit('<%= ngversion%>', '<%= bsversion %>', '<%= pkg.version%>', '<%= module.name %>')"><i class="glyphicon glyphicon-edit"></i> Edit in plunker</button>
</div>
<tabset>
<tab heading="Markup">
Expand Down
16 changes: 9 additions & 7 deletions src/accordion/docs/demo.html
Original file line number Diff line number Diff line change
@@ -1,13 +1,15 @@
<div ng-controller="AccordionDemoCtrl">
<p>
<button class="btn btn-default btn-sm" ng-click="status.open = !status.open">Toggle last panel</button>
<button class="btn btn-default btn-sm" ng-click="status.isFirstDisabled = ! status.isFirstDisabled">Enable / Disable first panel</button>
<button type="button" class="btn btn-default btn-sm" ng-click="status.open = !status.open">Toggle last panel</button>
<button type="button" class="btn btn-default btn-sm" ng-click="status.isFirstDisabled = ! status.isFirstDisabled">Enable / Disable first panel</button>
</p>

<label class="checkbox">
<input type="checkbox" ng-model="oneAtATime">
Open only one at a time
</label>
<div class="checkbox">
<label>
<input type="checkbox" ng-model="oneAtATime">
Open only one at a time
</label>
</div>
<accordion close-others="oneAtATime">
<accordion-group heading="Static Header, initially expanded" is-open="status.isFirstOpen" is-disabled="status.isFirstDisabled">
This content is straight in the template.
Expand All @@ -17,7 +19,7 @@
</accordion-group>
<accordion-group heading="Dynamic Body Content">
<p>The body of the accordion group grows to fit the contents</p>
<button class="btn btn-default btn-sm" ng-click="addItem()">Add Item</button>
<button type="button" class="btn btn-default btn-sm" ng-click="addItem()">Add Item</button>
<div ng-repeat="item in items">{{item}}</div>
</accordion-group>
<accordion-group is-open="status.open">
Expand Down
2 changes: 1 addition & 1 deletion src/alert/docs/demo.html
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<div ng-controller="AlertDemoCtrl">
<alert ng-repeat="alert in alerts" type="{{alert.type}}" close="closeAlert($index)">{{alert.msg}}</alert>
<button class='btn btn-default' ng-click="addAlert()">Add Alert</button>
<button type="button" class='btn btn-default' ng-click="addAlert()">Add Alert</button>
</div>
2 changes: 1 addition & 1 deletion src/collapse/docs/demo.html
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<div ng-controller="CollapseDemoCtrl">
<button class="btn btn-default" ng-click="isCollapsed = !isCollapsed">Toggle collapse</button>
<button type="button" class="btn btn-default" ng-click="isCollapsed = !isCollapsed">Toggle collapse</button>
<hr>
<div collapse="isCollapsed">
<div class="well well-lg">Some content</div>
Expand Down
12 changes: 6 additions & 6 deletions src/modal/docs/demo.html
Original file line number Diff line number Diff line change
Expand Up @@ -12,14 +12,14 @@ <h3 class="modal-title">I'm a modal!</h3>
Selected: <b>{{ selected.item }}</b>
</div>
<div class="modal-footer">
<button class="btn btn-primary" ng-click="ok()">OK</button>
<button class="btn btn-warning" ng-click="cancel()">Cancel</button>
<button class="btn btn-primary" type="button" ng-click="ok()">OK</button>
<button class="btn btn-warning" type="button" ng-click="cancel()">Cancel</button>
</div>
</script>

<button class="btn btn-default" ng-click="open()">Open me!</button>
<button class="btn btn-default" ng-click="open('lg')">Large modal</button>
<button class="btn btn-default" ng-click="open('sm')">Small modal</button>
<button class="btn btn-default" ng-click="toggleAnimation()">Toggle Animation ({{ animationsEnabled }})</button>
<button type="button" class="btn btn-default" ng-click="open()">Open me!</button>
<button type="button" class="btn btn-default" ng-click="open('lg')">Large modal</button>
<button type="button" class="btn btn-default" ng-click="open('sm')">Small modal</button>
<button type="button" class="btn btn-default" ng-click="toggleAnimation()">Toggle Animation ({{ animationsEnabled }})</button>
<div ng-show="selected">Selection from a modal: {{ selected }}</div>
</div>
2 changes: 1 addition & 1 deletion src/pagination/docs/demo.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ <h4>Default</h4>
<pagination direction-links="false" boundary-links="true" total-items="totalItems" ng-model="currentPage"></pagination>
<pagination direction-links="false" total-items="totalItems" ng-model="currentPage" num-pages="smallnumPages"></pagination>
<pre>The selected page no: {{currentPage}}</pre>
<button class="btn btn-info" ng-click="setPage(3)">Set current page to: 3</button>
<button type="button" class="btn btn-info" ng-click="setPage(3)">Set current page to: 3</button>

<hr />
<h4>Pager</h4>
Expand Down
18 changes: 9 additions & 9 deletions src/popover/docs/demo.html
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,9 @@ <h4>Dynamic</h4>
<label>Popup Template:</label>
<input type="text" ng-model="dynamicPopover.templateUrl" class="form-control">
</div>
<button popover="{{dynamicPopover.content}}" popover-title="{{dynamicPopover.title}}" class="btn btn-default">Dynamic Popover</button>
<button popover="{{dynamicPopover.content}}" popover-title="{{dynamicPopover.title}}" type="button" class="btn btn-default">Dynamic Popover</button>

<button popover-template="dynamicPopover.templateUrl" popover-title="{{dynamicPopover.title}}" class="btn btn-default">Popover With Template</button>
<button popover-template="dynamicPopover.templateUrl" popover-title="{{dynamicPopover.title}}" type="button" class="btn btn-default">Popover With Template</button>

<script type="text/ng-template" id="myPopoverTemplate.html">
<div>{{dynamicPopover.content}}</div>
Expand All @@ -25,20 +25,20 @@ <h4>Dynamic</h4>
</script>
<hr />
<h4>Positional</h4>
<button popover-placement="top" popover="On the Top!" class="btn btn-default">Top</button>
<button popover-placement="left" popover="On the Left!" class="btn btn-default">Left</button>
<button popover-placement="right" popover="On the Right!" class="btn btn-default">Right</button>
<button popover-placement="bottom" popover="On the Bottom!" class="btn btn-default">Bottom</button>
<button popover-placement="top" popover="On the Top!" type="button" class="btn btn-default">Top</button>
<button popover-placement="left" popover="On the Left!" type="button" class="btn btn-default">Left</button>
<button popover-placement="right" popover="On the Right!" type="button" class="btn btn-default">Right</button>
<button popover-placement="bottom" popover="On the Bottom!" type="button" class="btn btn-default">Bottom</button>

<hr />
<h4>Triggers</h4>
<p>
<button popover="I appeared on mouse enter!" popover-trigger="mouseenter" class="btn btn-default">Mouseenter</button>
<button popover="I appeared on mouse enter!" popover-trigger="mouseenter" type="button" class="btn btn-default">Mouseenter</button>
</p>
<input type="text" value="Click me!" popover="I appeared on focus! Click away and I'll vanish..." popover-trigger="focus" class="form-control">

<hr />
<h4>Other</h4>
<button Popover-animation="true" popover="I fade in and out!" class="btn btn-default">fading</button>
<button popover="I have a title!" popover-title="The title." class="btn btn-default">title</button>
<button Popover-animation="true" popover="I fade in and out!" type="button" class="btn btn-default">fading</button>
<button popover="I have a title!" popover-title="The title." type="button" class="btn btn-default">title</button>
</div>
4 changes: 2 additions & 2 deletions src/progressbar/docs/demo.html
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ <h3>Static</h3>
</div>

<hr />
<h3>Dynamic <button class="btn btn-sm btn-primary" type="button" ng-click="random()">Randomize</button></h3>
<h3>Dynamic <button type="button" class="btn btn-sm btn-primary" ng-click="random()">Randomize</button></h3>
<progressbar max="max" value="dynamic"><span style="color:white; white-space:nowrap;">{{dynamic}} / {{max}}</span></progressbar>

<small><em>No animation</em></small>
Expand All @@ -18,7 +18,7 @@ <h3>Dynamic <button class="btn btn-sm btn-primary" type="button" ng-click="rando
<progressbar class="progress-striped active" value="dynamic" type="{{type}}">{{type}} <i ng-show="showWarning">!!! Watch out !!!</i></progressbar>

<hr />
<h3>Stacked <button class="btn btn-sm btn-primary" type="button" ng-click="randomStacked()">Randomize</button></h3>
<h3>Stacked <button type="button" class="btn btn-sm btn-primary" ng-click="randomStacked()">Randomize</button></h3>
<progress><bar ng-repeat="bar in stacked track by $index" value="bar.value" type="{{bar.type}}"><span ng-hide="bar.value < 5">{{bar.value}}%</span></bar></progress>

</div>
4 changes: 2 additions & 2 deletions src/rating/docs/demo.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ <h4>Default</h4>

<pre style="margin:15px 0;">Rate: <b>{{rate}}</b> - Readonly is: <i>{{isReadonly}}</i> - Hovering over: <b>{{overStar || "none"}}</b></pre>

<button class="btn btn-sm btn-danger" ng-click="rate = 0" ng-disabled="isReadonly">Clear</button>
<button class="btn btn-sm btn-default" ng-click="isReadonly = ! isReadonly">Toggle Readonly</button>
<button type="button" class="btn btn-sm btn-danger" ng-click="rate = 0" ng-disabled="isReadonly">Clear</button>
<button type="button" class="btn btn-sm btn-default" ng-click="isReadonly = ! isReadonly">Toggle Readonly</button>
<hr />

<h4>Custom icons</h4>
Expand Down
6 changes: 3 additions & 3 deletions src/tabs/docs/demo.html
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
<div ng-controller="TabsDemoCtrl">
<p>Select a tab by setting active binding to true:</p>
<p>
<button class="btn btn-default btn-sm" ng-click="tabs[0].active = true">Select second tab</button>
<button class="btn btn-default btn-sm" ng-click="tabs[1].active = true">Select third tab</button>
<button type="button" class="btn btn-default btn-sm" ng-click="tabs[0].active = true">Select second tab</button>
<button type="button" class="btn btn-default btn-sm" ng-click="tabs[1].active = true">Select third tab</button>
</p>
<p>
<button class="btn btn-default btn-sm" ng-click="tabs[1].disabled = ! tabs[1].disabled">Enable / Disable third tab</button>
<button type="button" class="btn btn-default btn-sm" ng-click="tabs[1].disabled = ! tabs[1].disabled">Enable / Disable third tab</button>
</p>
<hr />

Expand Down
6 changes: 3 additions & 3 deletions src/timepicker/docs/demo.html
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@

<hr>

<button class="btn btn-info" ng-click="toggleMode()">12H / 24H</button>
<button class="btn btn-default" ng-click="update()">Set to 14:00</button>
<button class="btn btn-danger" ng-click="clear()">Clear</button>
<button type="button" class="btn btn-info" ng-click="toggleMode()">12H / 24H</button>
<button type="button" class="btn btn-default" ng-click="update()">Set to 14:00</button>
<button type="button" class="btn btn-danger" ng-click="clear()">Clear</button>

</div>
5 changes: 2 additions & 3 deletions template/rating/rating.html
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
<span ng-mouseleave="reset()" ng-keydown="onKeydown($event)" tabindex="0" role="slider" aria-valuemin="0" aria-valuemax="{{range.length}}" aria-valuenow="{{value}}">
<i ng-repeat="r in range track by $index" ng-mouseenter="enter($index + 1)" ng-click="rate($index + 1)" class="glyphicon" ng-class="$index < value && (r.stateOn || 'glyphicon-star') || (r.stateOff || 'glyphicon-star-empty')" ng-attr-title="{{r.title}}" >
<span class="sr-only">({{ $index < value ? '*' : ' ' }})</span>
</i>
<span ng-repeat-start="r in range track by $index" class="sr-only">({{ $index < value ? '*' : ' ' }})</span>
<i ng-repeat-end ng-mouseenter="enter($index + 1)" ng-click="rate($index + 1)" class="glyphicon" ng-class="$index < value && (r.stateOn || 'glyphicon-star') || (r.stateOff || 'glyphicon-star-empty')" ng-attr-title="{{r.title}}" ></i>
</span>