]> git.immae.eu Git - github/wallabag/wallabag.git/blobdiff - app/Resources/static/themes/baggy/js/init.js
Bring navigation (with right, left and enter) on material entries page. Supports...
[github/wallabag/wallabag.git] / app / Resources / static / themes / baggy / js / init.js
index c6a54f6fa696fc75c858d8a4ee327a3455aa89fa..05360a287bc340c7f2d6fea724981d5e0e311b1e 100755 (executable)
@@ -1,11 +1,26 @@
-const $ = global.jquery = require('jquery');
-require('jquery.cookie');
-require('jquery-ui');
-const annotator = require('annotator');
-import { savePercent, retrievePercent } from '../../_global/js/tools.js';
-import { split, extractLast } from './autoCompleteTags.js';
-import { toggleSaveLinkForm } from './uiTools.js';
+/* jQuery */
+import $ from 'jquery';
 
+/* eslint-disable no-unused-vars */
+/* jquery has default scope */
+import cookie from 'jquery.cookie';
+import ui from 'jquery-ui-browserify';
+/* eslint-enable no-unused-vars */
+
+/* Annotations */
+import annotator from 'annotator';
+
+/* Shortcuts */
+import './shortcuts/main';
+import './shortcuts/entry';
+import '../../_global/js/shortcuts/main';
+import '../../_global/js/shortcuts/entry';
+
+/* Tools */
+import { savePercent, retrievePercent } from '../../_global/js/tools';
+import toggleSaveLinkForm from './uiTools';
+
+global.jquery = $;
 
 $.fn.ready(() => {
   const $listmode = $('#listmode');
@@ -124,6 +139,10 @@ $.fn.ready(() => {
   /**
    * Tags autocomplete
    */
+  /**
+   * Not working on v2
+   *
+
   $('#value').bind('keydown', (event) => {
     if (event.keyCode === $.ui.keyCode.TAB && $(this).data('ui-autocomplete').menu.active) {
       event.preventDefault();
@@ -156,6 +175,7 @@ $.fn.ready(() => {
       return false;
     },
   });
+  */
 
   //---------------------------------------------------------------------------
   // Close the message box when the user clicks the close icon