mirror of
https://github.com/Athou/commafeed.git
synced 2026-03-21 21:37:29 +00:00
more keyboard shortcuts goodness
This commit is contained in:
@@ -378,8 +378,8 @@ module.controller('FeedListCtrl', function($scope, $stateParams, $http, $route,
|
|||||||
$scope.mark(entry, true);
|
$scope.mark(entry, true);
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
$scope.noop = function(event){
|
$scope.noop = function(event) {
|
||||||
if (!event.ctrlKey && event.which != 2) {
|
if (!event.ctrlKey && event.which != 2) {
|
||||||
event.preventDefault();
|
event.preventDefault();
|
||||||
event.stopPropagation();
|
event.stopPropagation();
|
||||||
@@ -438,7 +438,6 @@ module.controller('FeedListCtrl', function($scope, $stateParams, $http, $route,
|
|||||||
openNextEntry(e);
|
openNextEntry(e);
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
Mousetrap.bind('shift+space', function(e) {
|
Mousetrap.bind('shift+space', function(e) {
|
||||||
$scope.$apply(function() {
|
$scope.$apply(function() {
|
||||||
openPreviousEntry(e);
|
openPreviousEntry(e);
|
||||||
@@ -449,6 +448,30 @@ module.controller('FeedListCtrl', function($scope, $stateParams, $http, $route,
|
|||||||
openPreviousEntry(e);
|
openPreviousEntry(e);
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
Mousetrap.bind('o', function(e) {
|
||||||
|
$scope.$apply(function() {
|
||||||
|
if ($scope.current) {
|
||||||
|
$scope.entryClicked($scope.current, e);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
});
|
||||||
|
Mousetrap.bind('enter', function(e) {
|
||||||
|
$scope.$apply(function() {
|
||||||
|
if ($scope.current) {
|
||||||
|
$scope.entryClicked($scope.current, e);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
});
|
||||||
|
Mousetrap.bind('r', function(e) {
|
||||||
|
$scope.$apply(function() {
|
||||||
|
$scope.$emit('emitReload');
|
||||||
|
});
|
||||||
|
});
|
||||||
|
Mousetrap.bind('v', function(e) {
|
||||||
|
if ($scope.current) {
|
||||||
|
window.open($scope.current.url);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
$scope.$on('markAll', function(event, args) {
|
$scope.$on('markAll', function(event, args) {
|
||||||
var service = $scope.selectedType == 'feed' ? FeedService
|
var service = $scope.selectedType == 'feed' ? FeedService
|
||||||
|
|||||||
@@ -1,19 +1,48 @@
|
|||||||
<div>
|
<div>
|
||||||
|
<ul class="nav nav-tabs">
|
||||||
<h3>CommaFeed</h3>
|
<li class="active">
|
||||||
<p>
|
<a href="#about" data-toggle="tab">About</a>
|
||||||
CommaFeed is an open-source project. Sources are hosted on <a href="https://github.com/Athou/commafeed" target="_blank">GitHub</a>.
|
</li>
|
||||||
</p>
|
<li>
|
||||||
<p>
|
<a href="#shortcuts" data-toggle="tab">Keyboard shortcuts</a>
|
||||||
If you encounter an issue, please report it on the <a href="https://github.com/Athou/commafeed/issues" target="_blank">issues page</a> of the GitHub project.
|
</li>
|
||||||
</p>
|
</ul>
|
||||||
|
<div class="tab-content">
|
||||||
<h3>REST API</h3>
|
<div class="tab-pane active" id="about">
|
||||||
<p>
|
<h3>CommaFeed</h3>
|
||||||
CommaFeed is built on top of JAX-RS and AngularJS. As such, a REST API is available.
|
<p>
|
||||||
</p>
|
CommaFeed is an open-source project. Sources are hosted on <a href="https://github.com/Athou/commafeed" target="_blank">GitHub</a>.
|
||||||
<p>
|
</p>
|
||||||
The documentation about the API is available <a href="api" target="_blank">here</a>.
|
<p>
|
||||||
</p>
|
If you encounter an issue, please report it on the <a href="https://github.com/Athou/commafeed/issues" target="_blank">issues page</a> of the GitHub project.
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<h3>REST API</h3>
|
||||||
|
<p>
|
||||||
|
CommaFeed is built on top of JAX-RS and AngularJS. As such, a REST API is available.
|
||||||
|
</p>
|
||||||
|
<p>
|
||||||
|
The documentation about the API is available <a href="api" target="_blank">here</a>.
|
||||||
|
</p>
|
||||||
|
</div>
|
||||||
|
<div class="tab-pane active" id="shortcuts">
|
||||||
|
<dl class="dl-horizontal">
|
||||||
|
<dt>k, space</dt>
|
||||||
|
<dd>open next entry</dd>
|
||||||
|
|
||||||
|
<dt>j, shift+space</dt>
|
||||||
|
<dd>open previous entry</dd>
|
||||||
|
|
||||||
|
<dt>o, enter</dt>
|
||||||
|
<dd>open/close current entry</dd>
|
||||||
|
|
||||||
|
<dt>v</dt>
|
||||||
|
<dd>open current entry in a new window</dd>
|
||||||
|
|
||||||
|
<dt>mouse middleclick</dt>
|
||||||
|
<dd>open entry in new tab and mark as read</dd>
|
||||||
|
</dl>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
Reference in New Issue
Block a user