aboutsummaryrefslogtreecommitdiffhomepage
path: root/tpl/default/tools.html
diff options
context:
space:
mode:
Diffstat (limited to 'tpl/default/tools.html')
-rw-r--r--tpl/default/tools.html42
1 files changed, 6 insertions, 36 deletions
diff --git a/tpl/default/tools.html b/tpl/default/tools.html
index b9df32d9..baa033af 100644
--- a/tpl/default/tools.html
+++ b/tpl/default/tools.html
@@ -67,7 +67,7 @@
67 <div class="tools-item"> 67 <div class="tools-item">
68 <a title="{'Drag this link to your bookmarks toolbar or right-click it and Bookmark This Link'|t}, 68 <a title="{'Drag this link to your bookmarks toolbar or right-click it and Bookmark This Link'|t},
69 {'then click ✚Shaare link button in any page you want to share'|t}" 69 {'then click ✚Shaare link button in any page you want to share'|t}"
70 onclick="return alertBookmarklet();" 70 class="bookmarklet-link"
71 href="javascript:( 71 href="javascript:(
72 function(){ 72 function(){
73 var%20url%20=%20location.href; 73 var%20url%20=%20location.href;
@@ -86,8 +86,8 @@
86 <div class="tools-item"> 86 <div class="tools-item">
87 <a title="{'Drag this link to your bookmarks toolbar or right-click it and Bookmark This Link'|t}, 87 <a title="{'Drag this link to your bookmarks toolbar or right-click it and Bookmark This Link'|t},
88 {'Then click ✚Add Note button anytime to start composing a private Note (text post) to your Shaarli'|t}" 88 {'Then click ✚Add Note button anytime to start composing a private Note (text post) to your Shaarli'|t}"
89 onclick="return alertBookmarklet();" 89 href="?private=1&amp;post="
90 href="?private=1&amp;post="> 90 class="bookmarklet-link">
91 <span class="pure-button pure-u-lg-2-3 pure-u-3-4">✚ {'Add Note'|t}</span> 91 <span class="pure-button pure-u-lg-2-3 pure-u-3-4">✚ {'Add Note'|t}</span>
92 </a> 92 </a>
93 </div> 93 </div>
@@ -103,7 +103,7 @@
103 103
104 <div class="tools-item"> 104 <div class="tools-item">
105 <a title="{'Click on this button to add Shaarli to the 'Share this page' button in Firefox" 105 <a title="{'Click on this button to add Shaarli to the 'Share this page' button in Firefox"
106 onclick="activateFirefoxSocial(this)"> 106 id="ff-social-button">
107 <span class="pure-button pure-u-lg-2-3 pure-u-3-4">✚ {'Add to'|t} Firefox Social</span> 107 <span class="pure-button pure-u-lg-2-3 pure-u-3-4">✚ {'Add to'|t} Firefox Social</span>
108 </a> 108 </a>
109 </div> 109 </div>
@@ -142,38 +142,8 @@
142</div> 142</div>
143 143
144{include="page.footer"} 144{include="page.footer"}
145 145<input type="hidden" id="bookmarklet-alert"
146<script> 146 value="{'Drag this link to your bookmarks toolbar, or right-click it and choose Bookmark This Link'|t}">
147 {if="$sslenabled"}
148 function activateFirefoxSocial(node) {
149 var loc = location.href;
150 var baseURL = loc.substring(0, loc.lastIndexOf("/"));
151
152 // Keeping the data separated (ie. not in the DOM) so that it's maintainable and diffable.
153 var data = {
154 name: "{$shaarlititle}",
155 description: "The personal, minimalist, super-fast, database free, bookmarking service by the Shaarli community.",
156 author: "Shaarli",
157 version: "1.0.0",
158
159 iconURL: baseURL + "/images/favicon.ico",
160 icon32URL: baseURL + "/images/favicon.ico",
161 icon64URL: baseURL + "/images/favicon.ico",
162
163 shareURL: baseURL + "{noparse}?post=%{url}&title=%{title}&description=%{text}&source=firefoxsocialapi{/noparse}",
164 homepageURL: baseURL
165 };
166 node.setAttribute("data-service", JSON.stringify(data));
167
168 var activate = new CustomEvent("ActivateSocialFeature");
169 node.dispatchEvent(activate);
170 }
171 {/if}
172 function alertBookmarklet() {
173 alert({"'Drag this link to your bookmarks toolbar, or right-click it and choose Bookmark This Link'"|t});
174 return false;
175 }
176</script>
177</body> 147</body>
178</html> 148</html>
179 149