mirror of
https://github.com/wallabag/wallabag.git
synced 2025-02-04 09:47:39 +01:00
Added shortcuts
This commit is contained in:
parent
644b340178
commit
3cc78f0679
@ -30,6 +30,7 @@ class AppKernel extends Kernel
|
||||
new Doctrine\Bundle\MigrationsBundle\DoctrineMigrationsBundle(),
|
||||
new Craue\ConfigBundle\CraueConfigBundle(),
|
||||
new WhiteOctober\PagerfantaBundle\WhiteOctoberPagerfantaBundle(),
|
||||
new FOS\JsRoutingBundle\FOSJsRoutingBundle(),
|
||||
|
||||
// wallabag bundles
|
||||
new Wallabag\CoreBundle\WallabagCoreBundle(),
|
||||
|
@ -1,4 +1,5 @@
|
||||
const $ = require('jquery');
|
||||
require('mousetrap');
|
||||
|
||||
/* Allows inline call qr-code call */
|
||||
import jrQrcode from 'jr-qrcode'; // eslint-disable-line
|
||||
@ -51,3 +52,14 @@ function initExport() {
|
||||
}
|
||||
|
||||
export { savePercent, retrievePercent, initFilters, initExport };
|
||||
|
||||
/** Shortcuts **/
|
||||
|
||||
/* Go to */
|
||||
Mousetrap.bind('g u', function() { window.location.href = Routing.generate('homepage') });
|
||||
Mousetrap.bind('g s', function() { window.location.href = Routing.generate('starred') });
|
||||
|
||||
/* Actions */
|
||||
Mousetrap.bind('g a', function() {
|
||||
$("#nav-btn-add").trigger("click");
|
||||
});
|
||||
|
@ -351,3 +351,6 @@ old_sound_rabbit_mq:
|
||||
queue_options:
|
||||
name: 'wallabag.import.chrome'
|
||||
callback: wallabag_import.consumer.amqp.chrome
|
||||
|
||||
fos_js_routing:
|
||||
routes_to_expose: [ homepage, starred, archive, all, tag, config, import, developer, howto, about, logout ]
|
||||
|
@ -52,3 +52,6 @@ craue_config_settings_modify:
|
||||
path: /settings
|
||||
defaults:
|
||||
_controller: CraueConfigBundle:Settings:modify
|
||||
|
||||
fos_js_routing:
|
||||
resource: "@FOSJsRoutingBundle/Resources/config/routing/routing.xml"
|
||||
|
@ -82,7 +82,8 @@
|
||||
"php-amqplib/rabbitmq-bundle": "^1.8",
|
||||
"predis/predis": "^1.0",
|
||||
"javibravo/simpleue": "^1.0",
|
||||
"symfony/dom-crawler": "^3.1"
|
||||
"symfony/dom-crawler": "^3.1",
|
||||
"friendsofsymfony/jsrouting-bundle": "^1.6"
|
||||
},
|
||||
"require-dev": {
|
||||
"doctrine/doctrine-fixtures-bundle": "~2.2",
|
||||
|
@ -101,6 +101,7 @@
|
||||
"through": "^2.3.8"
|
||||
},
|
||||
"dependencies": {
|
||||
"jr-qrcode": "^1.0.5"
|
||||
"jr-qrcode": "^1.0.5",
|
||||
"mousetrap": "^1.6.0"
|
||||
}
|
||||
}
|
||||
|
@ -41,6 +41,8 @@
|
||||
{% block css %}
|
||||
{% endblock %}
|
||||
{% block scripts %}
|
||||
<script src="{{ asset('bundles/fosjsrouting/js/router.js') }}"></script>
|
||||
<script src="{{ path('fos_js_routing_js', { callback: 'fos.Router.setData' }) }}"></script>
|
||||
{% endblock %}
|
||||
|
||||
<title>{% block title %}{% endblock %} – wallabag</title>
|
||||
|
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
1
web/js/fos_js_routes.js
Normal file
1
web/js/fos_js_routes.js
Normal file
@ -0,0 +1 @@
|
||||
fos.Router.setData({"base_url":"","routes":{"starred":{"tokens":[["variable","\/","[^\/]++","page"],["text","\/starred\/list"]],"defaults":{"page":"1"},"requirements":[],"hosttokens":[]},"starred_rss":{"tokens":[["text","\/starred.xml"],["variable","\/","[^\/]++","token"],["variable","\/","[^\/]++","username"]],"defaults":[],"requirements":[],"hosttokens":[]},"homepage":{"tokens":[["variable","\/","\\d+","page"]],"defaults":{"page":1},"requirements":{"page":"\\d+"},"hosttokens":[]}},"prefix":"","host":"localhost","scheme":"http"});
|
Loading…
x
Reference in New Issue
Block a user