aboutsummaryrefslogtreecommitdiffhomepage
path: root/app/Resources
diff options
context:
space:
mode:
Diffstat (limited to 'app/Resources')
-rw-r--r--app/Resources/CraueConfigBundle/translations/CraueConfigBundle.da.yml2
-rw-r--r--app/Resources/CraueConfigBundle/translations/CraueConfigBundle.de.yml2
-rw-r--r--app/Resources/CraueConfigBundle/translations/CraueConfigBundle.en.yml2
-rw-r--r--app/Resources/CraueConfigBundle/translations/CraueConfigBundle.es.yml2
-rw-r--r--app/Resources/CraueConfigBundle/translations/CraueConfigBundle.fa.yml2
-rw-r--r--app/Resources/CraueConfigBundle/translations/CraueConfigBundle.fr.yml2
-rw-r--r--app/Resources/CraueConfigBundle/translations/CraueConfigBundle.it.yml2
-rw-r--r--app/Resources/CraueConfigBundle/translations/CraueConfigBundle.oc.yml2
-rw-r--r--app/Resources/CraueConfigBundle/translations/CraueConfigBundle.pl.yml2
-rw-r--r--app/Resources/CraueConfigBundle/translations/CraueConfigBundle.pt.yml1
-rw-r--r--app/Resources/CraueConfigBundle/translations/CraueConfigBundle.ro.yml2
-rw-r--r--app/Resources/CraueConfigBundle/translations/CraueConfigBundle.tr.yml2
-rw-r--r--app/Resources/static/themes/_global/img/icons/unmark-icon--black.pngbin0 -> 926 bytes
-rw-r--r--app/Resources/static/themes/_global/js/bookmarklet.js1
-rw-r--r--app/Resources/static/themes/_global/js/shortcuts/entry.js0
-rw-r--r--app/Resources/static/themes/_global/js/shortcuts/main.js15
-rw-r--r--app/Resources/static/themes/_global/js/tools.js7
-rwxr-xr-xapp/Resources/static/themes/baggy/css/main.css5
-rwxr-xr-xapp/Resources/static/themes/baggy/js/autoCompleteTags.js2
-rwxr-xr-xapp/Resources/static/themes/baggy/js/init.js27
-rw-r--r--app/Resources/static/themes/baggy/js/shortcuts/entry.js22
-rw-r--r--app/Resources/static/themes/baggy/js/shortcuts/main.js0
-rw-r--r--app/Resources/static/themes/baggy/js/uiTools.js4
-rwxr-xr-xapp/Resources/static/themes/material/css/main.css5
-rwxr-xr-xapp/Resources/static/themes/material/js/init.js17
-rw-r--r--app/Resources/static/themes/material/js/shortcuts/entry.js22
-rw-r--r--app/Resources/static/themes/material/js/shortcuts/main.js70
27 files changed, 206 insertions, 14 deletions
diff --git a/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.da.yml b/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.da.yml
index 3e11d675..8ee0a303 100644
--- a/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.da.yml
+++ b/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.da.yml
@@ -15,6 +15,7 @@ share_diaspora: Aktiver deling til Diaspora
15share_mail: Aktiver deling med email 15share_mail: Aktiver deling med email
16share_shaarli: Aktiver deling gennem Shaarli 16share_shaarli: Aktiver deling gennem Shaarli
17share_twitter: Aktiver deling gennem Twitter 17share_twitter: Aktiver deling gennem Twitter
18share_unmark: Aktiver deling gennem Unmark.it
18show_printlink: Vis et link til print-indhold 19show_printlink: Vis et link til print-indhold
19wallabag_support_url: Support-URL for wallabag 20wallabag_support_url: Support-URL for wallabag
20wallabag_url: URL for *sin* wallabag-installation 21wallabag_url: URL for *sin* wallabag-installation
@@ -29,3 +30,4 @@ piwik_enabled: Aktiver Piwik
29demo_mode_enabled: "Aktiver demo-indstilling? (anvendes kun til wallabags offentlige demo)" 30demo_mode_enabled: "Aktiver demo-indstilling? (anvendes kun til wallabags offentlige demo)"
30demo_mode_username: "Demobruger" 31demo_mode_username: "Demobruger"
31# share_public: Allow public url for entries 32# share_public: Allow public url for entries
33# download_images_enabled: Download images locally
diff --git a/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.de.yml b/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.de.yml
index c74b5c1f..73a9d640 100644
--- a/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.de.yml
+++ b/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.de.yml
@@ -15,6 +15,7 @@ share_diaspora: Teilen zu Diaspora aktiveren
15share_mail: Teilen via E-Mail aktiveren 15share_mail: Teilen via E-Mail aktiveren
16share_shaarli: Teilen zu Shaarli aktiveren 16share_shaarli: Teilen zu Shaarli aktiveren
17share_twitter: Teilen zu Twitter aktiveren 17share_twitter: Teilen zu Twitter aktiveren
18share_unmark: Teilen zu Unmark.it aktiveren
18show_printlink: Link anzeigen, um den Inhalt auszudrucken 19show_printlink: Link anzeigen, um den Inhalt auszudrucken
19wallabag_support_url: Support-URL für wallabag 20wallabag_support_url: Support-URL für wallabag
20wallabag_url: URL von *deiner* wallabag-Instanz 21wallabag_url: URL von *deiner* wallabag-Instanz
@@ -29,3 +30,4 @@ piwik_enabled: Piwik aktivieren
29demo_mode_enabled: "Test-Modus aktivieren? (nur für die öffentliche wallabag-Demo genutzt)" 30demo_mode_enabled: "Test-Modus aktivieren? (nur für die öffentliche wallabag-Demo genutzt)"
30demo_mode_username: "Test-Benutzer" 31demo_mode_username: "Test-Benutzer"
31share_public: Erlaube eine öffentliche URL für Einträge 32share_public: Erlaube eine öffentliche URL für Einträge
33# download_images_enabled: Download images locally
diff --git a/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.en.yml b/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.en.yml
index 77c09db4..c8c13805 100644
--- a/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.en.yml
+++ b/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.en.yml
@@ -15,6 +15,7 @@ share_diaspora: Enable share to Diaspora
15share_mail: Enable share by email 15share_mail: Enable share by email
16share_shaarli: Enable share to Shaarli 16share_shaarli: Enable share to Shaarli
17share_twitter: Enable share to Twitter 17share_twitter: Enable share to Twitter
18share_unmark: Enable share to Unmark.it
18show_printlink: Display a link to print content 19show_printlink: Display a link to print content
19wallabag_support_url: Support URL for wallabag 20wallabag_support_url: Support URL for wallabag
20wallabag_url: URL of *your* wallabag instance 21wallabag_url: URL of *your* wallabag instance
@@ -29,3 +30,4 @@ piwik_enabled: Enable Piwik
29demo_mode_enabled: "Enable demo mode ? (only used for the wallabag public demo)" 30demo_mode_enabled: "Enable demo mode ? (only used for the wallabag public demo)"
30demo_mode_username: "Demo user" 31demo_mode_username: "Demo user"
31share_public: Allow public url for entries 32share_public: Allow public url for entries
33download_images_enabled: Download images locally
diff --git a/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.es.yml b/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.es.yml
index baa83849..0ea98d8f 100644
--- a/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.es.yml
+++ b/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.es.yml
@@ -15,6 +15,7 @@ share_diaspora: Activar compartir con Diaspora
15share_mail: Activar compartir con email 15share_mail: Activar compartir con email
16share_shaarli: Activar compartir con Shaarli 16share_shaarli: Activar compartir con Shaarli
17share_twitter: Activar compartir con Twitter 17share_twitter: Activar compartir con Twitter
18share_unmark: Activar compartir con Unmark.it
18show_printlink: Mostrar un enlace para imprimir contenido 19show_printlink: Mostrar un enlace para imprimir contenido
19wallabag_support_url: URL de soporte de wallabag 20wallabag_support_url: URL de soporte de wallabag
20wallabag_url: URL de *tu* instancia de wallabag 21wallabag_url: URL de *tu* instancia de wallabag
@@ -29,3 +30,4 @@ piwik_enabled: Activar Piwik
29demo_mode_enabled: "Activar modo demo (sólo usado para la demo de wallabag)" 30demo_mode_enabled: "Activar modo demo (sólo usado para la demo de wallabag)"
30demo_mode_username: "Nombre de usuario demo" 31demo_mode_username: "Nombre de usuario demo"
31# share_public: Allow public url for entries 32# share_public: Allow public url for entries
33# download_images_enabled: Download images locally
diff --git a/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.fa.yml b/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.fa.yml
index b394977e..c527b971 100644
--- a/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.fa.yml
+++ b/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.fa.yml
@@ -15,6 +15,7 @@ share_diaspora: فعال‌سازی هم‌رسانی به Diaspora
15share_mail: فعال‌سازی هم‌رسانی با ایمیل 15share_mail: فعال‌سازی هم‌رسانی با ایمیل
16share_shaarli: فعال‌سازی هم‌رسانی به Shaarli 16share_shaarli: فعال‌سازی هم‌رسانی به Shaarli
17share_twitter: فعال‌سازی هم‌رسانی به Twitter 17share_twitter: فعال‌سازی هم‌رسانی به Twitter
18share_unmark: فعال‌سازی هم‌رسانی به Unmark.it
18show_printlink: نمایش پیوندی برای چاپ مطلب 19show_printlink: نمایش پیوندی برای چاپ مطلب
19wallabag_support_url: نشانی صفحهٔ پشتیبانی wallabag 20wallabag_support_url: نشانی صفحهٔ پشتیبانی wallabag
20wallabag_url: نشانی صفحهٔ wallabag *شما* 21wallabag_url: نشانی صفحهٔ wallabag *شما*
@@ -29,3 +30,4 @@ modify_settings: "اعمال"
29# demo_mode_enabled: "Enable demo mode ? (only used for the wallabag public demo)" 30# demo_mode_enabled: "Enable demo mode ? (only used for the wallabag public demo)"
30# demo_mode_username: "Demo user" 31# demo_mode_username: "Demo user"
31# share_public: Allow public url for entries 32# share_public: Allow public url for entries
33# download_images_enabled: Download images locally
diff --git a/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.fr.yml b/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.fr.yml
index 31a80880..176e7c86 100644
--- a/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.fr.yml
+++ b/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.fr.yml
@@ -15,6 +15,7 @@ share_diaspora: Activer le partage vers Diaspora
15share_mail: Activer le partage par email 15share_mail: Activer le partage par email
16share_shaarli: Activer le partage vers Shaarli 16share_shaarli: Activer le partage vers Shaarli
17share_twitter: Activer le partage vers Twitter 17share_twitter: Activer le partage vers Twitter
18share_unmark: Activer le partage vers Unmark.it
18show_printlink: Afficher un lien pour imprimer 19show_printlink: Afficher un lien pour imprimer
19wallabag_support_url: URL de support de wallabag 20wallabag_support_url: URL de support de wallabag
20wallabag_url: URL de *votre* instance de wallabag 21wallabag_url: URL de *votre* instance de wallabag
@@ -29,3 +30,4 @@ piwik_enabled: Activer Piwik
29demo_mode_enabled: "Activer le mode démo ? (utiliser uniquement pour la démo publique de wallabag)" 30demo_mode_enabled: "Activer le mode démo ? (utiliser uniquement pour la démo publique de wallabag)"
30demo_mode_username: "Utilisateur de la démo" 31demo_mode_username: "Utilisateur de la démo"
31share_public: Autoriser une URL publique pour les articles 32share_public: Autoriser une URL publique pour les articles
33download_images_enabled: Télécharger les images en local
diff --git a/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.it.yml b/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.it.yml
index ba038556..621d4dcd 100644
--- a/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.it.yml
+++ b/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.it.yml
@@ -15,6 +15,7 @@ share_diaspora: Abilita la condivisione con Diaspora
15share_mail: Abilita la condivisione per email 15share_mail: Abilita la condivisione per email
16share_shaarli: Abilita la condivisione con Shaarli 16share_shaarli: Abilita la condivisione con Shaarli
17share_twitter: Abilita la condivisione con Twitter 17share_twitter: Abilita la condivisione con Twitter
18share_unmark: Abilita la condivisione con Unmark.it
18show_printlink: Mostra un collegamento per stampare il contenuto 19show_printlink: Mostra un collegamento per stampare il contenuto
19wallabag_support_url: URL di supporto per wallabag 20wallabag_support_url: URL di supporto per wallabag
20wallabag_url: URL della *tua* installazione di wallabag 21wallabag_url: URL della *tua* installazione di wallabag
@@ -29,3 +30,4 @@ piwik_enabled: Abilita Piwik
29demo_mode_enabled: "Abilita modalità demo ? (usato solo per la demo pubblica di wallabag)" 30demo_mode_enabled: "Abilita modalità demo ? (usato solo per la demo pubblica di wallabag)"
30demo_mode_username: "Utente Demo" 31demo_mode_username: "Utente Demo"
31# share_public: Allow public url for entries 32# share_public: Allow public url for entries
33# download_images_enabled: Download images locally
diff --git a/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.oc.yml b/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.oc.yml
index 55249e33..04accd45 100644
--- a/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.oc.yml
+++ b/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.oc.yml
@@ -15,6 +15,7 @@ share_diaspora: Activar lo partatge cap a Diaspora
15share_mail: Activar lo partatge per corrièl 15share_mail: Activar lo partatge per corrièl
16share_shaarli: Activar lo partatge cap a Shaarli 16share_shaarli: Activar lo partatge cap a Shaarli
17share_twitter: Activar lo partatge cap a Twitter 17share_twitter: Activar lo partatge cap a Twitter
18share_unmark: Activar lo partatge cap a Unmark.it
18show_printlink: Afichar un ligam per imprimir 19show_printlink: Afichar un ligam per imprimir
19wallabag_support_url: URL d'assisténcia de wallabag 20wallabag_support_url: URL d'assisténcia de wallabag
20wallabag_url: URL de *vòstra* instància de wallabag 21wallabag_url: URL de *vòstra* instància de wallabag
@@ -29,3 +30,4 @@ piwik_enabled: Activar Piwik
29demo_mode_enabled: "Activar lo mode demostracion ? (utilizar solament per la demostracion publica de wallabag)" 30demo_mode_enabled: "Activar lo mode demostracion ? (utilizar solament per la demostracion publica de wallabag)"
30demo_mode_username: "Utilizaire de la demostracion" 31demo_mode_username: "Utilizaire de la demostracion"
31# share_public: Allow public url for entries 32# share_public: Allow public url for entries
33# download_images_enabled: Download images locally
diff --git a/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.pl.yml b/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.pl.yml
index 42cc5b52..2f4f3154 100644
--- a/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.pl.yml
+++ b/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.pl.yml
@@ -15,6 +15,7 @@ share_diaspora: Włącz udostępnianie dla Diaspora
15share_mail: Włącz udostępnianie przez email 15share_mail: Włącz udostępnianie przez email
16share_shaarli: Włącz udostępnianie dla Shaarli 16share_shaarli: Włącz udostępnianie dla Shaarli
17share_twitter: Włącz udostępnianie dla Twitter 17share_twitter: Włącz udostępnianie dla Twitter
18share_unmark: Włącz udostępnianie dla Unmark.it
18show_printlink: Pokaż link do wydrukowania zawartości 19show_printlink: Pokaż link do wydrukowania zawartości
19wallabag_support_url: Adres URL wsparcia dla wallabag 20wallabag_support_url: Adres URL wsparcia dla wallabag
20wallabag_url: Adres *twojej* instacji wallabag 21wallabag_url: Adres *twojej* instacji wallabag
@@ -29,3 +30,4 @@ piwik_enabled: Włacz Piwik
29demo_mode_enabled: "Włacz tryb demo? (używany wyłącznie dla publicznej demonstracji Wallabag)" 30demo_mode_enabled: "Włacz tryb demo? (używany wyłącznie dla publicznej demonstracji Wallabag)"
30demo_mode_username: "Użytkownik Demonstracyjny" 31demo_mode_username: "Użytkownik Demonstracyjny"
31share_public: Zezwalaj na publiczny adres url dla wpisow 32share_public: Zezwalaj na publiczny adres url dla wpisow
33# download_images_enabled: Download images locally
diff --git a/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.pt.yml b/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.pt.yml
index e8260422..5da940e9 100644
--- a/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.pt.yml
+++ b/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.pt.yml
@@ -14,6 +14,7 @@ share_diaspora: Habilitar compartilhamento para o Diaspora
14share_mail: Habilitar compartilhamento por e-mail 14share_mail: Habilitar compartilhamento por e-mail
15share_shaarli: Habilitar compartilhamento para o Shaarli 15share_shaarli: Habilitar compartilhamento para o Shaarli
16share_twitter: Habilitar compartilhamento para o Twitter 16share_twitter: Habilitar compartilhamento para o Twitter
17share_unmark: Habilitar compartilhamento para o Unmark.it
17show_printlink: Mostrar um link para imprimir o conteúdo 18show_printlink: Mostrar um link para imprimir o conteúdo
18wallabag_support_url: URL de Suporte do wallabag 19wallabag_support_url: URL de Suporte do wallabag
19wallabag_url: URL de *sua* instância do wallabag 20wallabag_url: URL de *sua* instância do wallabag
diff --git a/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.ro.yml b/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.ro.yml
index 8e72b955..6d2eaffd 100644
--- a/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.ro.yml
+++ b/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.ro.yml
@@ -15,6 +15,7 @@ share_diaspora: Permite share către Diaspora
15share_mail: Permite share prin email 15share_mail: Permite share prin email
16share_shaarli: Permite share către Shaarli 16share_shaarli: Permite share către Shaarli
17share_twitter: Permite share către Twitter 17share_twitter: Permite share către Twitter
18share_unmark: Permite share către Unmark.it
18show_printlink: Afișează un link pentru a printa content-ul 19show_printlink: Afișează un link pentru a printa content-ul
19wallabag_support_url: URL-ul de suport pentru wallabag 20wallabag_support_url: URL-ul de suport pentru wallabag
20wallabag_url: URL-ul instanței tale wallabag 21wallabag_url: URL-ul instanței tale wallabag
@@ -29,3 +30,4 @@ modify_settings: "aplică"
29# demo_mode_enabled: "Enable demo mode ? (only used for the wallabag public demo)" 30# demo_mode_enabled: "Enable demo mode ? (only used for the wallabag public demo)"
30# demo_mode_username: "Demo user" 31# demo_mode_username: "Demo user"
31# share_public: Allow public url for entries 32# share_public: Allow public url for entries
33# download_images_enabled: Download images locally
diff --git a/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.tr.yml b/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.tr.yml
index 55f70843..9146bfb6 100644
--- a/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.tr.yml
+++ b/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.tr.yml
@@ -15,6 +15,7 @@
15# share_mail: Enable share by email 15# share_mail: Enable share by email
16# share_shaarli: Enable share to Shaarli 16# share_shaarli: Enable share to Shaarli
17# share_twitter: Enable share to Twitter 17# share_twitter: Enable share to Twitter
18# share_unmark: Enable share to Unmark.it
18# show_printlink: Display a link to print content 19# show_printlink: Display a link to print content
19# wallabag_support_url: Support URL for wallabag 20# wallabag_support_url: Support URL for wallabag
20# wallabag_url: URL of *your* wallabag instance 21# wallabag_url: URL of *your* wallabag instance
@@ -29,3 +30,4 @@
29# demo_mode_enabled: "Enable demo mode ? (only used for the wallabag public demo)" 30# demo_mode_enabled: "Enable demo mode ? (only used for the wallabag public demo)"
30# demo_mode_username: "Demo user" 31# demo_mode_username: "Demo user"
31# share_public: Allow public url for entries 32# share_public: Allow public url for entries
33# download_images_enabled: Download images locally
diff --git a/app/Resources/static/themes/_global/img/icons/unmark-icon--black.png b/app/Resources/static/themes/_global/img/icons/unmark-icon--black.png
new file mode 100644
index 00000000..45f679ee
--- /dev/null
+++ b/app/Resources/static/themes/_global/img/icons/unmark-icon--black.png
Binary files differ
diff --git a/app/Resources/static/themes/_global/js/bookmarklet.js b/app/Resources/static/themes/_global/js/bookmarklet.js
index 5174ff47..a497628b 100644
--- a/app/Resources/static/themes/_global/js/bookmarklet.js
+++ b/app/Resources/static/themes/_global/js/bookmarklet.js
@@ -1,4 +1,3 @@
1
2top['bookmarklet-url@wallabag.org'] = 1top['bookmarklet-url@wallabag.org'] =
3 '<!DOCTYPE html><html><head><title>bag it!</title>' + 2 '<!DOCTYPE html><html><head><title>bag it!</title>' +
4 '<link rel="icon" href="tpl/img/favicon.ico" />' + 3 '<link rel="icon" href="tpl/img/favicon.ico" />' +
diff --git a/app/Resources/static/themes/_global/js/shortcuts/entry.js b/app/Resources/static/themes/_global/js/shortcuts/entry.js
new file mode 100644
index 00000000..e69de29b
--- /dev/null
+++ b/app/Resources/static/themes/_global/js/shortcuts/entry.js
diff --git a/app/Resources/static/themes/_global/js/shortcuts/main.js b/app/Resources/static/themes/_global/js/shortcuts/main.js
new file mode 100644
index 00000000..ef6a1b84
--- /dev/null
+++ b/app/Resources/static/themes/_global/js/shortcuts/main.js
@@ -0,0 +1,15 @@
1import Mousetrap from 'mousetrap';
2
3/** Shortcuts **/
4
5/* Go to */
6Mousetrap.bind('g u', () => { window.location.href = Routing.generate('homepage'); });
7Mousetrap.bind('g s', () => { window.location.href = Routing.generate('starred'); });
8Mousetrap.bind('g r', () => { window.location.href = Routing.generate('archive'); });
9Mousetrap.bind('g a', () => { window.location.href = Routing.generate('all'); });
10Mousetrap.bind('g t', () => { window.location.href = Routing.generate('tag'); });
11Mousetrap.bind('g c', () => { window.location.href = Routing.generate('config'); });
12Mousetrap.bind('g i', () => { window.location.href = Routing.generate('import'); });
13Mousetrap.bind('g d', () => { window.location.href = Routing.generate('developer'); });
14Mousetrap.bind('?', () => { window.location.href = Routing.generate('howto'); });
15Mousetrap.bind('g l', () => { window.location.href = Routing.generate('logout'); });
diff --git a/app/Resources/static/themes/_global/js/tools.js b/app/Resources/static/themes/_global/js/tools.js
index ab30deb1..568b2dce 100644
--- a/app/Resources/static/themes/_global/js/tools.js
+++ b/app/Resources/static/themes/_global/js/tools.js
@@ -1,4 +1,9 @@
1const $ = require('jquery'); 1import $ from 'jquery';
2import './shortcuts/main';
3import './shortcuts/entry';
4
5/* Allows inline call qr-code call */
6import jrQrcode from 'jr-qrcode'; // eslint-disable-line
2 7
3function supportsLocalStorage() { 8function supportsLocalStorage() {
4 try { 9 try {
diff --git a/app/Resources/static/themes/baggy/css/main.css b/app/Resources/static/themes/baggy/css/main.css
index 4dfa8790..4f48f8ca 100755
--- a/app/Resources/static/themes/baggy/css/main.css
+++ b/app/Resources/static/themes/baggy/css/main.css
@@ -936,6 +936,11 @@ a.add-to-wallabag-link-after::after {
936 background-image: url("../../_global/img/icons/diaspora-icon--black.png"); 936 background-image: url("../../_global/img/icons/diaspora-icon--black.png");
937} 937}
938 938
939/* Unmark.it */
940.icon-image--unmark {
941 background-image: url("../../_global/img/icons/unmark-icon--black.png");
942}
943
939/* shaarli */ 944/* shaarli */
940.icon-image--shaarli { 945.icon-image--shaarli {
941 background-image: url("../../_global/img/icons/shaarli.png"); 946 background-image: url("../../_global/img/icons/shaarli.png");
diff --git a/app/Resources/static/themes/baggy/js/autoCompleteTags.js b/app/Resources/static/themes/baggy/js/autoCompleteTags.js
index f287ebfa..64fdaa92 100755
--- a/app/Resources/static/themes/baggy/js/autoCompleteTags.js
+++ b/app/Resources/static/themes/baggy/js/autoCompleteTags.js
@@ -5,4 +5,4 @@ function extractLast(term) {
5 return split(term).pop(); 5 return split(term).pop();
6} 6}
7 7
8export { split, extractLast }; 8export default { split, extractLast };
diff --git a/app/Resources/static/themes/baggy/js/init.js b/app/Resources/static/themes/baggy/js/init.js
index dc11043a..05360a28 100755
--- a/app/Resources/static/themes/baggy/js/init.js
+++ b/app/Resources/static/themes/baggy/js/init.js
@@ -1,11 +1,26 @@
1import { savePercent, retrievePercent } from '../../_global/js/tools'; 1/* jQuery */
2import { toggleSaveLinkForm } from './uiTools'; 2import $ from 'jquery';
3
4/* eslint-disable no-unused-vars */
5/* jquery has default scope */
6import cookie from 'jquery.cookie';
7import ui from 'jquery-ui-browserify';
8/* eslint-enable no-unused-vars */
9
10/* Annotations */
11import annotator from 'annotator';
3 12
4const $ = global.jquery = require('jquery'); 13/* Shortcuts */
5require('jquery.cookie'); 14import './shortcuts/main';
6require('jquery-ui-browserify'); 15import './shortcuts/entry';
7const annotator = require('annotator'); 16import '../../_global/js/shortcuts/main';
17import '../../_global/js/shortcuts/entry';
18
19/* Tools */
20import { savePercent, retrievePercent } from '../../_global/js/tools';
21import toggleSaveLinkForm from './uiTools';
8 22
23global.jquery = $;
9 24
10$.fn.ready(() => { 25$.fn.ready(() => {
11 const $listmode = $('#listmode'); 26 const $listmode = $('#listmode');
diff --git a/app/Resources/static/themes/baggy/js/shortcuts/entry.js b/app/Resources/static/themes/baggy/js/shortcuts/entry.js
new file mode 100644
index 00000000..728df8bd
--- /dev/null
+++ b/app/Resources/static/themes/baggy/js/shortcuts/entry.js
@@ -0,0 +1,22 @@
1import Mousetrap from 'mousetrap';
2import $ from 'jquery';
3
4/* Article view */
5Mousetrap.bind('o', () => {
6 $('div#article_toolbar ul.links a.original')[0].click();
7});
8
9/* mark as favorite */
10Mousetrap.bind('s', () => {
11 $('div#article_toolbar ul.links a.favorite')[0].click();
12});
13
14/* mark as read */
15Mousetrap.bind('a', () => {
16 $('div#article_toolbar ul.links a.markasread')[0].click();
17});
18
19/* delete */
20Mousetrap.bind('del', () => {
21 $('div#article_toolbar ul.links a.delete')[0].click();
22});
diff --git a/app/Resources/static/themes/baggy/js/shortcuts/main.js b/app/Resources/static/themes/baggy/js/shortcuts/main.js
new file mode 100644
index 00000000..e69de29b
--- /dev/null
+++ b/app/Resources/static/themes/baggy/js/shortcuts/main.js
diff --git a/app/Resources/static/themes/baggy/js/uiTools.js b/app/Resources/static/themes/baggy/js/uiTools.js
index 900b2707..713c53f7 100644
--- a/app/Resources/static/themes/baggy/js/uiTools.js
+++ b/app/Resources/static/themes/baggy/js/uiTools.js
@@ -1,4 +1,4 @@
1const $ = require('jquery'); 1import $ from 'jquery';
2 2
3function toggleSaveLinkForm(url, event) { 3function toggleSaveLinkForm(url, event) {
4 $('#add-link-result').empty(); 4 $('#add-link-result').empty();
@@ -32,4 +32,4 @@ function toggleSaveLinkForm(url, event) {
32 plainUrl.focus(); 32 plainUrl.focus();
33} 33}
34 34
35export { toggleSaveLinkForm }; 35export default toggleSaveLinkForm;
diff --git a/app/Resources/static/themes/material/css/main.css b/app/Resources/static/themes/material/css/main.css
index 408fe14c..df126fb4 100755
--- a/app/Resources/static/themes/material/css/main.css
+++ b/app/Resources/static/themes/material/css/main.css
@@ -150,6 +150,11 @@
150 background-image: url("../../_global/img/icons/diaspora-icon--black.png"); 150 background-image: url("../../_global/img/icons/diaspora-icon--black.png");
151} 151}
152 152
153/* Unmark.it */
154.icon-image--unmark {
155 background-image: url("../../_global/img/icons/unmark-icon--black.png");
156}
157
153/* Shaarli */ 158/* Shaarli */
154.icon-image--shaarli { 159.icon-image--shaarli {
155 background-image: url("../../_global/img/icons/shaarli.png"); 160 background-image: url("../../_global/img/icons/shaarli.png");
diff --git a/app/Resources/static/themes/material/js/init.js b/app/Resources/static/themes/material/js/init.js
index a68269e0..9746224b 100755
--- a/app/Resources/static/themes/material/js/init.js
+++ b/app/Resources/static/themes/material/js/init.js
@@ -1,10 +1,21 @@
1/* jQuery */
2import $ from 'jquery';
3
4/* Annotations */
5import annotator from 'annotator';
6
7/* Tools */
1import { savePercent, retrievePercent, initFilters, initExport } from '../../_global/js/tools'; 8import { savePercent, retrievePercent, initFilters, initExport } from '../../_global/js/tools';
2 9
3const $ = require('jquery'); 10/* Import shortcuts */
11import './shortcuts/main';
12import './shortcuts/entry';
13import '../../_global/js/shortcuts/main';
14import '../../_global/js/shortcuts/entry';
4 15
5global.jQuery = $;
6require('materialize'); // eslint-disable-line 16require('materialize'); // eslint-disable-line
7const annotator = require('annotator'); 17
18global.jQuery = $;
8 19
9$(document).ready(() => { 20$(document).ready(() => {
10 // sideNav 21 // sideNav
diff --git a/app/Resources/static/themes/material/js/shortcuts/entry.js b/app/Resources/static/themes/material/js/shortcuts/entry.js
new file mode 100644
index 00000000..357c22fe
--- /dev/null
+++ b/app/Resources/static/themes/material/js/shortcuts/entry.js
@@ -0,0 +1,22 @@
1import Mousetrap from 'mousetrap';
2import $ from 'jquery';
3
4/* open original article */
5Mousetrap.bind('o', () => {
6 $('ul.side-nav a.original i')[0].click();
7});
8
9/* mark as favorite */
10Mousetrap.bind('s', () => {
11 $('ul.side-nav a.favorite i')[0].click();
12});
13
14/* mark as read */
15Mousetrap.bind('a', () => {
16 $('ul.side-nav a.markasread i')[0].click();
17});
18
19/* delete */
20Mousetrap.bind('del', () => {
21 $('ul.side-nav a.delete i')[0].click();
22});
diff --git a/app/Resources/static/themes/material/js/shortcuts/main.js b/app/Resources/static/themes/material/js/shortcuts/main.js
new file mode 100644
index 00000000..8514f71e
--- /dev/null
+++ b/app/Resources/static/themes/material/js/shortcuts/main.js
@@ -0,0 +1,70 @@
1import Mousetrap from 'mousetrap';
2import $ from 'jquery';
3
4function toggleFocus(cardToToogleFocus) {
5 if (cardToToogleFocus) {
6 $(cardToToogleFocus).toggleClass('z-depth-4');
7 }
8}
9
10$(document).ready(() => {
11 let cardIndex = 0;
12 const cardNumber = $('#content ul.data > li').length;
13 let card = $('#content ul.data > li')[cardIndex];
14 const pagination = $('.pagination');
15
16 /* Show nothing on quickstart */
17 if ($('#content > div.quickstart').length > 0) {
18 return;
19 }
20
21 /* If we come from next page */
22 if (window.location.hash === '#prev') {
23 cardIndex = cardNumber - 1;
24 card = $('ul.data > li')[cardIndex];
25 }
26
27 /* Focus current card */
28 toggleFocus(card);
29
30 /* Actions */
31 Mousetrap.bind('g n', () => {
32 $('#nav-btn-add').trigger('click');
33 });
34
35 Mousetrap.bind('esc', () => {
36 $('.close').trigger('click');
37 });
38
39 /* Select right card. If there's a next page, go to next page */
40 Mousetrap.bind('right', () => {
41 if (cardIndex >= 0 && cardIndex < cardNumber - 1) {
42 toggleFocus(card);
43 cardIndex += 1;
44 card = $('ul.data > li')[cardIndex];
45 toggleFocus(card);
46 return;
47 }
48 if (pagination.length > 0 && pagination.find('li.next:not(.disabled)').length > 0 && cardIndex === cardNumber - 1) {
49 window.location.href = window.location.origin + $(pagination).find('li.next a').attr('href');
50 }
51 });
52
53 /* Select previous card. If there's a previous page, go to next page */
54 Mousetrap.bind('left', () => {
55 if (cardIndex > 0 && cardIndex < cardNumber) {
56 toggleFocus(card);
57 cardIndex -= 1;
58 card = $('ul.data > li')[cardIndex];
59 toggleFocus(card);
60 return;
61 }
62 if (pagination.length > 0 && $(pagination).find('li.prev:not(.disabled)').length > 0 && cardIndex === 0) {
63 window.location.href = `${window.location.origin + $(pagination).find('li.prev a').attr('href')}#prev`;
64 }
65 });
66
67 Mousetrap.bind('enter', () => {
68 window.location.href = window.location.origin + $(card).find('span.card-title a').attr('href');
69 });
70});