Skip to content
Snippets Groups Projects
Commit f62c79f9 authored by Eike Cochu's avatar Eike Cochu
Browse files

updated ui tabindexes, changed article topic list to ul

parent a0e2f989
Branches
No related tags found
No related merge requests found
......@@ -50,35 +50,26 @@
<div class="row">
<div class="col-md-12">
<h3><anchor-link fragment="similar" />Similar articles</h3>
<ul class="list-unstyled" ng-attr-start="{{(page-1)*limit+1}}">
<li ng-repeat="simArticle in article.similarArticles" class="ellipsis">
<ul class="list-unstyled">
<li ng-repeat="simArticle in article.similarArticles | orderBy:'divergence'" class="ellipsis">
<small class="text-muted percent-align" ng-bind-template="({{((1-simArticle.divergence)*100).toFixed(0)}}%)"></small>
<a ui-sref="articles.show({id: simArticle.article.id})" ng-attr-title="{{::simArticle.article.title}}" ng-bind="::simArticle.article.title"></a>
</li>
<li class="text-muted" ng-show="!article.similarArticles">
None
</li>
</ul>
</div>
</div>
</div>
<div class="col-md-4">
<h3><anchor-link fragment="topics" />Topics</h3>
<table class="table table-bordered table-condensed table-nomargin" ng-show="article.topics.length > 0">
<tbody>
<tr>
<th>
Name
</th>
<th class="topic-share text-right">
Share
</th>
</tr>
<tr ng-repeat="topic in article.topics | orderBy:topicSort:topicSortRev">
<td>
<topic-link topic="topic.topic" />
</td>
<td class="text-right" ng-bind-template="{{(topic.share*100).toFixed(1)}}%"></td>
</tr>
</tbody>
</table>
<ul class="list-unstyled">
<li ng-repeat="topic in article.topics | orderBy:'share'">
<small class="text-muted percent-align" ng-bind-template="({{(topic.share*100).toFixed(0)}}%)"></small>
<topic-link topic="topic.topic" />
</li>
</ul>
<span class="text-muted" ng-hide="article.topics.length > 0">No topics</span>
<div class="pie-chart" id="topic-share" highcharts="topicShare"></div>
</div>
......
<i class="pointer fa" ng-class="{'fa-sort-amount-desc':ngModel,'fa-sort-amount-asc':!ngModel}" ng-click="ngModel=!ngModel; $event.stopPropagation()"></i>
\ No newline at end of file
<a tabindex="0">
<i class="pointer fa" ng-class="{'fa-sort-amount-desc':ngModel,'fa-sort-amount-asc':!ngModel}" ng-click="ngModel=!ngModel; $event.stopPropagation()"></i>
</a>
\ No newline at end of file
<div class="fullsize navpadding explorer" ng-cloak ng-hide="!rootModels.topicModel || $state.current.name !== 'explorer'">
<div class="sidebar">
<div class="btn-group btn-group-justified" role="group" aria-label="...">
<a class="btn btn-sm btn-default" ng-click="checkTopics(true)" title="Select all topics">All</a>
<a class="btn btn-sm btn-default" ng-click="checkTopics(false)" title="Deselect all topics">None</a>
<a class="btn btn-sm btn-default" ng-click="checkTopics()" title="Toggle all topics">Toggle</a>
<a tabindex="0" class="btn btn-sm btn-default" ng-click="checkTopics(true)" title="Select all topics">All</a>
<a tabindex="0" class="btn btn-sm btn-default" ng-click="checkTopics(false)" title="Deselect all topics">None</a>
<a tabindex="0" class="btn btn-sm btn-default" ng-click="checkTopics()" title="Toggle all topics">Toggle</a>
</div>
<div class="btn-group btn-group-justified">
<a class="btn btn-sm btn-default" ng-model="explorerModels.sorttopics" bs-radio="'name'" title="Sort by name">&#945;</a>
<a class="btn btn-sm btn-default" ng-model="explorerModels.sorttopics" bs-radio="'avgRelevance'" title="Sort by average relevance">&#956;</a>
<a class="btn btn-sm btn-default" ng-model="explorerModels.sorttopics" bs-radio="'varRelevance'" title="Sort by variance in relevance">&#963;</a>
<a class="btn btn-sm btn-default" ng-model="explorerModels.sorttopics" bs-radio="'fallingRelevance'" title="Sort by falling relevance">&#8600;</a>
<a class="btn btn-sm btn-default" ng-model="explorerModels.sorttopics" bs-radio="'risingRelevance'" title="Sort by rising relevance">&#8599;</a>
<a class="btn btn-sm btn-default" ng-model="explorerModels.sorttopics" bs-radio="'risingDecayRelevance'" title="Sort by rising relevance with decay">&#8605;</a>
<a class="btn btn-sm btn-link btn-plain" ng-click="explorerModels.sortdir=!explorerModels.sortdir">
<a tabindex="0" class="btn btn-sm btn-default" ng-model="explorerModels.sorttopics" bs-radio="'name'" title="Sort by name">&#945;</a>
<a tabindex="0" class="btn btn-sm btn-default" ng-model="explorerModels.sorttopics" bs-radio="'avgRelevance'" title="Sort by average relevance">&#956;</a>
<a tabindex="0" class="btn btn-sm btn-default" ng-model="explorerModels.sorttopics" bs-radio="'varRelevance'" title="Sort by variance in relevance">&#963;</a>
<a tabindex="0" class="btn btn-sm btn-default" ng-model="explorerModels.sorttopics" bs-radio="'fallingRelevance'" title="Sort by falling relevance">&#8600;</a>
<a tabindex="0" class="btn btn-sm btn-default" ng-model="explorerModels.sorttopics" bs-radio="'risingRelevance'" title="Sort by rising relevance">&#8599;</a>
<a tabindex="0" class="btn btn-sm btn-default" ng-model="explorerModels.sorttopics" bs-radio="'risingDecayRelevance'" title="Sort by rising relevance with decay">&#8605;</a>
<a tabindex="0" class="btn btn-sm btn-link btn-plain" ng-click="explorerModels.sortdir=!explorerModels.sortdir">
<sort-dir ng-model="explorerModels.sortdir" />
</a>
</div>
......@@ -24,7 +24,7 @@
<li ng-repeat="topic in topics | orderBy:explorerModels.sorttopics:explorerModels.sortdir | filter:search" ng-mouseenter="highlightSeries(topic.id, true)" ng-mouseleave="highlightSeries(topic.id, false)">
<div class="checkbox checkbox-condensed" ng-class="{selected:topic.selected}">
<span class="valuebar" ng-style="{width:topic.topicCurrValue}"></span>
<input type="checkbox" ng-model="topic.selected" ng-attr-id="{{::topic.id}}" ng-change="redrawGraph()">
<input tabindex="0" type="checkbox" ng-model="topic.selected" ng-attr-id="{{::topic.id}}" ng-change="redrawGraph()">
<label class="check" ng-attr-for="{{::topic.id}}">
<topic-menu topic="topic" />
<span class="ellipsis topic">
......@@ -41,24 +41,24 @@
<div class="topbar">
<small>Values:</small>
<div class="btn-group">
<a class="btn btn-sm btn-default" ng-model="explorerModels.seqstyle" bs-radio="'absolute'">Absolute</a>
<a class="btn btn-sm btn-default" ng-model="explorerModels.seqstyle" bs-radio="'relative'">Relative</a>
<a tabindex="0" class="btn btn-sm btn-default" ng-model="explorerModels.seqstyle" bs-radio="'absolute'">Absolute</a>
<a tabindex="0" class="btn btn-sm btn-default" ng-model="explorerModels.seqstyle" bs-radio="'relative'">Relative</a>
</div>
&nbsp;
<small>Chart:</small>
<div class="btn-group">
<a class="btn btn-sm btn-default" ng-model="explorerModels.chartstyle" bs-radio="'areaspline'">Area</a>
<a class="btn btn-sm btn-default" ng-model="explorerModels.chartstyle" bs-radio="'spline'">Line</a>
<a tabindex="0" class="btn btn-sm btn-default" ng-model="explorerModels.chartstyle" bs-radio="'areaspline'">Area</a>
<a tabindex="0" class="btn btn-sm btn-default" ng-model="explorerModels.chartstyle" bs-radio="'spline'">Line</a>
</div>
&nbsp;
<small>Stacking:</small>
<div class="btn-group">
<a class="btn btn-sm btn-default" ng-model="explorerModels.chartstack" bs-radio="'none'">None</a>
<a class="btn btn-sm btn-default" ng-model="explorerModels.chartstack" bs-radio="'normal'">Value</a>
<a class="btn btn-sm btn-default" ng-model="explorerModels.chartstack" bs-radio="'percent'">Percent</a>
<a tabindex="0" class="btn btn-sm btn-default" ng-model="explorerModels.chartstack" bs-radio="'none'">None</a>
<a tabindex="0" class="btn btn-sm btn-default" ng-model="explorerModels.chartstack" bs-radio="'normal'">Value</a>
<a tabindex="0" class="btn btn-sm btn-default" ng-model="explorerModels.chartstack" bs-radio="'percent'">Percent</a>
</div>
<div class="pull-right">
<a class="btn btn-sm btn-default" ng-click="resetZoom()" ng-show="topicsSelected">Reset zoom</a>
<a tabindex="0" class="btn btn-sm btn-default" ng-click="resetZoom()" ng-show="topicsSelected">Reset zoom</a>
</div>
</div>
<div id="topicRelChart" class="chart" highcharts="topicSeq" style="height:500px"></div>
......
......@@ -43,7 +43,7 @@
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
<a ui-sref="index" class="navbar-brand">
<a tabindex="0" ui-sref="index" class="navbar-brand">
<svg class="logo hover" viewBox="0 0 200 120" ng-class="{animate:loading.any}">
<polyline style="animation-delay:0s" class="logo-shape" points="0,0 100,45 100,75 0,0" fill="#006591" />
<polyline style="animation-delay:.5s" class="logo-shape" points="100,45 200,0 100,75 100,45" fill="#0079a2" />
......@@ -56,30 +56,37 @@
<div class="collapse navbar-collapse" id="vipra-navbar-collapse-1">
<ul class="nav navbar-nav">
<li ui-sref-active="active">
<a ui-sref="explorer"><span class="mnemonic">E</span>xplorer</a>
<a tabindex="0" ui-sref="explorer"><span class="mnemonic">E</span>xplorer</a>
</li>
<li ui-sref-active="active">
<a ui-sref="articles"><span class="mnemonic">A</span>rticles</a>
<a tabindex="0" ui-sref="articles"><span class="mnemonic">A</span>rticles</a>
</li>
<li ui-sref-active="active">
<a ui-sref="topics"><span class="mnemonic">T</span>opics</a>
<a tabindex="0" ui-sref="topics"><span class="mnemonic">T</span>opics</a>
</li>
</ul>
<form class="navbar-form navbar-left" role="search" ng-hide="$state.current.name === 'index'">
<div class="form-group has-feedback">
<input type="text" class="form-control" placeholder="Search..." ng-model="rootModels.search" ng-enter="menubarSearch(rootModels.search)" id="menuSearchBox">
<input tabindex="0" type="text" class="form-control" placeholder="Search..." ng-model="rootModels.search" ng-enter="menubarSearch(rootModels.search)" id="menuSearchBox">
<i class="form-control-feedback glyphicon glyphicon-search text-muted"></i>
</div>
</form>
<ul class="nav navbar-nav navbar-right">
<li ng-class="{'text-italic':rootModels.topicModel}">
<a ng-click="chooseTopicModel()" ng-bind-template="{{rootModels.topicModel ? rootModels.topicModel.id : 'Models'}}" ng-attr-title="{{rootModels.topicModel.modelConfig.description}}"></a>
<ul class="nav navbar-nav">
<li ng-class="{'text-italic active':rootModels.topicModel}">
<a tabindex="0" ng-click="chooseTopicModel()" ng-bind-template="{{rootModels.topicModel ? rootModels.topicModel.id : 'Models'}}" ng-attr-title="{{rootModels.topicModel.modelConfig.description}}"></a>
</li>
</ul>
<ul class="nav navbar-nav navbar-right">
<li ui-sref-active="active">
<a ui-sref="about">
<a tabindex="0" ui-sref="about">
About
</a>
</li>
<li title="Keyboard cheatsheet">
<a tabindex="0" ng-click="showCheatSheet()">
<i class="fa fa-keyboard-o"></i>
</a>
</li>
</ul>
</div>
</div>
......
......@@ -100,6 +100,8 @@
$scope.chooseTopicModel();
}
});
$scope.showCheatSheet = hotkeys.toggleCheatSheet;
}
]);
......@@ -612,9 +614,6 @@
app.controller('ArticlesShowController', ['$scope', '$state', '$stateParams', '$timeout', 'ArticleFactory',
function($scope, $state, $stateParams, $timeout, ArticleFactory) {
$scope.topicSort = $scope.topicSort || 'share';
$scope.topicSortRev = typeof $scope.topicSortRev === 'undefined' ? true : $scope.topicSortRev;
ArticleFactory.get({
id: $stateParams.id
}, function(data) {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment