]> git.immae.eu Git - github/shaarli/Shaarli.git/commitdiff
Webpack / Update front paths in template files
authorArthurHoaro <arthur@hoa.ro>
Sat, 24 Feb 2018 17:34:50 +0000 (18:34 +0100)
committerArthurHoaro <arthur@hoa.ro>
Mon, 26 Mar 2018 17:29:20 +0000 (19:29 +0200)
15 files changed:
tpl/default/includes.html
tpl/default/linklist.html
tpl/default/page.footer.html
tpl/default/picwall.html
tpl/default/pluginsadmin.html
tpl/vintage/changetag.html
tpl/vintage/daily.html
tpl/vintage/editlink.html
tpl/vintage/includes.html
tpl/vintage/linklist.html
tpl/vintage/linklist.paging.html
tpl/vintage/page.footer.html
tpl/vintage/picwall.html
tpl/vintage/pluginsadmin.html
tpl/vintage/tools.html

index b2bfec30918281104cacf6c50cae5441fcc26903..2c56d3c989d28d9663e108cbb36bae3541342012 100644 (file)
@@ -6,12 +6,7 @@
 <link rel="alternate" type="application/rss+xml" href="{$feedurl}?do=rss{$searchcrits}#" title="RSS Feed" />
 <link href="img/favicon.png" rel="shortcut icon" type="image/png" />
 <link href="img/apple-touch-icon.png" rel="apple-touch-icon" sizes="180x180" />
-<link type="text/css" rel="stylesheet" href="css/pure.min.css?v={$version_hash}" />
-<link type="text/css" rel="stylesheet" href="css/grids-responsive.min.css?v={$version_hash}">
-<link type="text/css" rel="stylesheet" href="css/pure-extras.css?v={$version_hash}">
-<link type="text/css" rel="stylesheet" href="css/font-awesome.min.css?v={$version_hash}" />
-<link type="text/css" rel="stylesheet" href="inc/awesomplete.css?v={$version_hash}#" />
-<link type="text/css" rel="stylesheet" href="css/shaarli.css?v={$version_hash}" />
+<link type="text/css" rel="stylesheet" href="css/shaarli.min.css?v={$version_hash}" />
 {if="is_file('data/user.css')"}
   <link type="text/css" rel="stylesheet" href="data/user.css#" />
 {/if}
index c666e30a80d6cc698e80492c8847f7e52d0f55e9..933c1ef26bb2e2a15ccd367c953eaa27bfcf3ee1 100644 (file)
@@ -16,7 +16,6 @@
 </div>
 
 <input type="hidden" name="token" value="{$token}">
-
 <div id="search-linklist">
 
   <form method="GET" class="pure-form searchform" name="searchform">
index 659e8c7fdfcb5b58122694a090bfc81c7c975f0d..f4f09e9293bb8d7fbda01f562e3e96285ddacd95 100644 (file)
@@ -38,6 +38,4 @@
   </span>
 </div>
 
-<script src="js/shaarli.js?v={$version_hash}"></script>
-<script src="inc/awesomplete.js?v={$version_hash}#"></script>
-<script src="inc/awesomplete-multiple-tags.js?v={$version_hash}#"></script>
+<script src="js/shaarli.min.js?v={$version_hash}"></script>
index 248e56df78345029b8439b335911b27bf56ad2e3..23796ac94e4eb200de71c02cfd54197ce357f4b6 100644 (file)
@@ -39,7 +39,7 @@
 </div>
 
 {include="page.footer"}
-<script src="inc/blazy-1.3.1.min.js#"></script>
+<script src="js/picwall.min.js?v={$version_hash}"></script>
 </body>
 </html>
 
index b2d7cdc5900fff5967f6d0f6acc9afee1c7c0920..fa26c8593d534799613eb29bdfeea9fedbf19fb2 100644 (file)
 </form>
 
 {include="page.footer"}
-<script src="inc/plugin_admin.js#"></script>
+<script src="js/pluginsadmin.min.js?v={$version_hash}"></script>
 
 </body>
 </html>
index a0df3328ed67d1529b8d1a81c0ab2eaae25c72fc..670a8dd7309c2d73b92927aae72569b434dec351 100644 (file)
@@ -1,8 +1,6 @@
 <!DOCTYPE html>
 <html>
 <head>{include="includes"}
-    <link type="text/css" rel="stylesheet" href="inc/awesomplete.css#" />
-    <script src="inc/awesomplete.min.js#"></script>
 </head>
 <body onload="document.changetag.fromtag.focus();">
 <div id="pageheader">
index e86e90b1e0bd3c13e12a7d4286d62600ed917808..42db16a7f5315fb2275da5e91be99c9ab0bfc348 100644 (file)
         {/loop}
 
         <br>
-        <a href="?do=dailyrss" title="1 RSS entry per day"><img src="images/feed-icon-14x14.png#" alt="rss_feed">Daily RSS Feed</a>
+        <a href="?do=dailyrss" title="1 RSS entry per day"><img src="img/feed-icon-14x14.png" alt="rss_feed">Daily RSS Feed</a>
     </div>
 
     <div class="dailyTitle">
-        <img src="images/floral_left.png" width="51" height="50" class="nomobile" alt="floral_left">
+        <img src="img/floral_left.png" width="51" height="50" class="nomobile" alt="floral_left">
         The Daily Shaarli
-        <img src="images/floral_right.png" width="51" height="50" class="nomobile" alt="floral_right">
+        <img src="img/floral_right.png" width="51" height="50" class="nomobile" alt="floral_right">
     </div>
 
     <div class="dailyDate">
@@ -50,7 +50,7 @@
                     <div class="dailyEntry">
                         <div class="dailyEntryPermalink">
                             <a href="?{$value.shorturl}">
-                                <img src="images/squiggle.png" width="25" height="26" title="permalink" alt="permalink">
+                                <img src="img/squiggle.png" width="25" height="26" title="permalink" alt="permalink">
                             </a>
                         </div>
                         {if="!$hide_timestamps || isLoggedIn()"}
@@ -94,7 +94,7 @@
             {$value}
         {/loop}
     </div>
-    <div id="closing"><img src="images/squiggle_closing.png" width="66" height="61" alt="-"></div>
+    <div id="closing"><img src="img/squiggle_closing.png" width="66" height="61" alt="-"></div>
 </div>
 {include="page.footer"}
 </body>
index f855dfb186739aaf79ec085710e21b08558799ea..5fa7d19490b64295917691c2073176fb1ba937f4 100644 (file)
 {if="$source !== 'firefoxsocialapi'"}
 {include="page.footer"}
 {/if}
-<script src="inc/awesomplete.min.js#"></script>
-<script src="inc/awesomplete-multiple-tags.js#"></script>
-<script>
-    awesompleteUniqueTag('#lf_tags');
-</script>
 </body>
 </html>
index 17b78b17ccda034cf074c4a175e07ce843b9b15a..4ddfc8409471422dd92e40f7b75cdc1277b4e278 100644 (file)
@@ -5,9 +5,8 @@
 <meta name="referrer" content="same-origin">
 <link rel="alternate" type="application/rss+xml" href="{$feedurl}?do=rss{$searchcrits}#" title="RSS Feed" />
 <link rel="alternate" type="application/atom+xml" href="{$feedurl}?do=atom{$searchcrits}#" title="ATOM Feed" />
-<link href="images/favicon.ico#" rel="shortcut icon" type="image/x-icon" />
-<link type="text/css" rel="stylesheet" href="css/reset.css" />
-<link type="text/css" rel="stylesheet" href="css/shaarli.css" />
+<link href="img/favicon.ico" rel="shortcut icon" type="image/x-icon" />
+<link type="text/css" rel="stylesheet" href="css/shaarli.min.css" />
 {if="is_file('data/user.css')"}<link type="text/css" rel="stylesheet" href="data/user.css#" />{/if}
 {loop="$plugins_includes.css_files"}
 <link type="text/css" rel="stylesheet" href="{$value}#"/>
index 8458caa1c89224f377370b34ecfaedeb2ae8b395..e7137246d95ff9d6ef5ac88eaa74279b3194df3f 100644 (file)
@@ -22,7 +22,7 @@
                 {if="!empty($search_tags)"}
                     value="{$search_tags}"
                 {/if}
-                autocomplete="off" class="awesomplete" data-multiple data-minChars="1"
+                autocomplete="off" data-multiple data-minChars="1"
                 data-list="{loop="$tags"}{$key}, {/loop}"
             >
             <input type="submit" value="Search" class="bigbutton">
                     <div class="linkeditbuttons">
                         <form method="GET" class="buttoneditform">
                             <input type="hidden" name="edit_link" value="{$value.id}">
-                            <input type="image" alt="Edit" src="images/edit_icon.png#" title="Edit" class="button_edit">
+                            <input type="image" alt="Edit" src="img/edit_icon.png" title="Edit" class="button_edit">
                         </form><br>
                         <form method="GET" class="buttoneditform">
                             <input type="hidden" name="lf_linkdate" value="{$value.id}">
                             <input type="hidden" name="token" value="{$token}">
                             <input type="hidden" name="delete_link">
-                            <input type="image" alt="Delete" src="images/delete_icon.png#" title="Delete"
+                            <input type="image" alt="Delete" src="img/delete_icon.png" title="Delete"
                                    class="button_delete" onClick="return confirmDeleteLink();">
                         </form>
                     </div>
 
     {include="page.footer"}
 
-<script src="inc/awesomplete.min.js#"></script>
-<script src="inc/awesomplete-multiple-tags.js#"></script>
-<script>
-    awesompleteUniqueTag('#tagfilter_value');
-</script>
 </body>
 </html>
index 12828a97405296257ed6f2a8b3ed455c6508f0a8..e3b88ee6498881684a5f17806ab24c95a259b73b 100644 (file)
@@ -1,11 +1,11 @@
 <div class="paging">
 {if="isLoggedIn()"}
     <div class="paging_privatelinks">
-        <a href="?visibility=private">
+      <a href="?visibility=private">
                {if="$visibility=='private'"}
-               <img src="images/private_16x16_active.png#" width="16" height="16" title="Filter links by visibility" alt="Filter links by visibility">
-               {else}
-               <img src="images/private_16x16.png#" width="16" height="16" title="Filter links by visibility" alt="Filter links by visibility">
+      <img src="img/private_16x16_active.png" width="16" height="16" title="Click to see all links" alt="Click to see all links">
+    {else}
+      <img src="img/private_16x16.png" width="16" height="16" title="Click to see only private links" alt="Click to see only private links">
                {/if}
                </a>
 
index 4ce0803a064dcbf3a78efed3043566b7986cf1ca..1485e1ce53f237308793dcf036c4fdeb3b55e59f 100644 (file)
   Error: {$versionError}
 </div>
 {/if}
+
+<script src="js/shaarli.min.js"></script>
+
 {if="isLoggedIn()"}
 <script>function confirmDeleteLink() { var agree=confirm("Are you sure you want to delete this link ?"); if (agree) return true ; else return false ; }</script>
 {/if}
 
-<script src="js/shaarli.js"></script>
 {loop="$plugins_footer.js_files"}
        <script src="{$value}#"></script>
 {/loop}
index 4e227e3744038cd440fed8e89e8d3564ce87e6db..29688914165ed19f870b75d29087b29fab80a88d 100644 (file)
@@ -1,7 +1,6 @@
 <!DOCTYPE html>
 <html>
 <head>{include="includes"}
-<script src="inc/blazy-1.3.1.min.js#"></script>
 </head>
 <body>
 <div id="pageheader">{include="page.header"}</div>
 
 {include="page.footer"}
 
-<script>
-window.onload = function() {
-  var bLazy = new Blazy();
-}
-</script>
+<script src="js/picwall.min.js"></script>
 </body>
 </html>
index ead1734e850980096cfc59c5143ca1591bd4ad92..63b45cac5d13b7719fe71a4684ca229192be68a0 100644 (file)
 </div>
 {include="page.footer"}
 
-<script src="inc/plugin_admin.js#"></script>
+<script>
+  /**
+   * Change the position counter of a row.
+   *
+   * @param elem  Element Node to change.
+   * @param toPos int     New position.
+   */
+  function changePos(elem, toPos) {
+    var elemName = elem.getAttribute('data-line');
+
+    elem.setAttribute('data-order', toPos);
+    var hiddenInput = document.querySelector('[name="order_' + elemName + '"]');
+    hiddenInput.setAttribute('value', toPos);
+  }
+
+  /**
+   * Move a row up or down.
+   *
+   * @param pos  Element Node to move.
+   * @param move int     Move: +1 (down) or -1 (up)
+   */
+  function changeOrder(pos, move) {
+    var newpos = parseInt(pos) + move;
+    var lines = document.querySelectorAll('[data-order="' + pos + '"]');
+    var changelines = document.querySelectorAll('[data-order="' + newpos + '"]');
+
+    // If we go down reverse lines to preserve the rows order
+    if (move > 0) {
+      lines = [].slice.call(lines).reverse();
+    }
+
+    for (var i = 0; i < lines.length; i++) {
+      var parent = changelines[0].parentNode;
+      changePos(lines[i], newpos);
+      changePos(changelines[i], parseInt(pos));
+      var changeItem = move < 0 ? changelines[0] : changelines[changelines.length - 1].nextSibling;
+      parent.insertBefore(lines[i], changeItem);
+    }
+  }
+
+  /**
+   * Move a row up in the table.
+   *
+   * @param pos int row counter.
+   *
+   * @returns false
+   */
+  function orderUp(pos) {
+    if (pos == 0) {
+      return false;
+    }
+    changeOrder(pos, -1);
+    return false;
+  }
+
+  /**
+   * Move a row down in the table.
+   *
+   * @param pos int row counter.
+   *
+   * @returns false
+   */
+  function orderDown(pos) {
+    var lastpos = document.querySelector('[data-order]:last-child').getAttribute('data-order');
+    if (pos == lastpos) {
+      return false;
+    }
+
+    changeOrder(pos, +1);
+    return false;
+  }
+</script>
 </body>
 </html>
index 69689807e2cdbc9f71390927187630800e46c5b5..3194844adfb6a49379b95b559691c9ed204c0f7e 100644 (file)
@@ -81,9 +81,9 @@
                                        author: "Shaarli",
                                        version: "1.0.0",
 
-                                       iconURL: baseURL + "/images/favicon.ico",
-                                       icon32URL: baseURL + "/images/favicon.ico",
-                                       icon64URL: baseURL + "/images/favicon.ico",
+                                       iconURL: baseURL + "/img/favicon.ico",
+                                       icon32URL: baseURL + "/img/favicon.ico",
+                                       icon64URL: baseURL + "/img/favicon.ico",
 
                                        shareURL: baseURL + "{noparse}?post=%{url}&title=%{title}&description=%{text}&source=firefoxsocialapi{/noparse}",
                                        homepageURL: baseURL