]> git.mxchange.org Git - friendica.git/blob - view/templates/head.tpl
Store and display the subscribed tags
[friendica.git] / view / templates / head.tpl
1 <meta http-equiv="Content-Type" content="text/html;charset=utf-8" />
2 <base href="{{$baseurl}}/" />
3 <meta name="generator" content="{{$generator}}" />
4 <link rel="stylesheet" href="view/global.css?v={{$smarty.const.FRIENDICA_VERSION}}" type="text/css" media="all" />
5 <link rel="stylesheet" href="view/asset/jquery-colorbox/example5/colorbox.css?v={{$smarty.const.FRIENDICA_VERSION}}" type="text/css" media="screen" />
6 <link rel="stylesheet" href="view/asset/jgrowl/jquery.jgrowl.min.css?v={{$smarty.const.FRIENDICA_VERSION}}" type="text/css" media="screen" />
7 <link rel="stylesheet" href="view/asset/jquery-datetimepicker/build/jquery.datetimepicker.min.css?v={{$smarty.const.FRIENDICA_VERSION}}" type="text/css" media="screen" />
8 <link rel="stylesheet" href="view/asset/perfect-scrollbar/dist/css/perfect-scrollbar.min.css?v={{$smarty.const.FRIENDICA_VERSION}}" type="text/css" media="screen" />
9 <link rel="stylesheet" href="view/js/fancybox/jquery.fancybox.min.css?v={{$smarty.const.FRIENDICA_VERSION}}" type="text/css" media="screen" />
10
11 {{foreach $stylesheets as $stylesheetUrl => $media}}
12         <link rel="stylesheet" href="{{$stylesheetUrl}}" type="text/css" media="{{$media}}" />
13 {{/foreach}}
14
15 <link rel="icon" href="{{$shortcut_icon}}" />
16 <link rel="apple-touch-icon" href="{{$touch_icon}}"/>
17
18 <meta name="apple-mobile-web-app-capable" content="yes" />
19 <link rel="manifest" href="{{$baseurl}}/manifest" />
20 <script>
21 // @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&dn=expat.txt Expat
22 // Prevents links to switch to Safari in a home screen app - see https://gist.github.com/irae/1042167
23 (function(a,b,c){if(c in b&&b[c]){var d,e=a.location,f=/^(a|html)$/i;a.addEventListener("click",function(a){d=a.target;while(!f.test(d.nodeName))d=d.parentNode;"href"in d&&(chref=d.href).replace("{{$baseurl}}/", "").replace(e.href,"").indexOf("#")&&(!/^[a-z\+\.\-]+:/i.test(chref)||chref.indexOf(e.protocol+"//"+e.host)===0)&&(a.preventDefault(),e.href=d.href)},!1)}})(document,window.navigator,"standalone");
24 // |license-end
25 </script>
26
27 <link rel="search"
28          href="{{$baseurl}}/opensearch"
29          type="application/opensearchdescription+xml"
30          title="Search in Friendica" />
31
32 <!--[if IE]>
33 <script type="text/javascript" src="https://html5shiv.googlecode.com/svn/trunk/html5.js?v={{$smarty.const.FRIENDICA_VERSION}}"></script>
34 <![endif]-->
35 <script type="text/javascript" src="view/js/modernizr.js?v={{$smarty.const.FRIENDICA_VERSION}}"></script>
36 <script type="text/javascript" src="view/asset/jquery/dist/jquery.min.js?v={{$smarty.const.FRIENDICA_VERSION}}"></script>
37 <script type="text/javascript" src="view/js/jquery.textinputs.js?v={{$smarty.const.FRIENDICA_VERSION}}"></script>
38 <script type="text/javascript" src="view/asset/textcomplete/dist/textcomplete.min.js?v={{$smarty.const.FRIENDICA_VERSION}}"></script>
39 <script type="text/javascript" src="view/js/autocomplete.js?v={{$smarty.const.FRIENDICA_VERSION}}"></script>
40 <script type="text/javascript" src="view/asset/jquery-colorbox/jquery.colorbox-min.js?v={{$smarty.const.FRIENDICA_VERSION}}"></script>
41 <script type="text/javascript" src="view/asset/jgrowl/jquery.jgrowl.min.js?v={{$smarty.const.FRIENDICA_VERSION}}"></script>
42 <script type="text/javascript" src="view/asset/jquery-datetimepicker/build/jquery.datetimepicker.full.min.js?v={{$smarty.const.FRIENDICA_VERSION}}"></script>
43 <script type="text/javascript" src="view/asset/perfect-scrollbar/dist/js/perfect-scrollbar.jquery.min.js?v={{$smarty.const.FRIENDICA_VERSION}}"></script>
44 <script type="text/javascript" src="view/asset/imagesloaded/imagesloaded.pkgd.min.js?v={{$smarty.const.FRIENDICA_VERSION}}"></script>
45 <script type="text/javascript" src="view/asset/base64/base64.min.js?v={{$smarty.const.FRIENDICA_VERSION}}"></script>
46 <script type="text/javascript" src="view/asset/dompurify/dist/purify.min.js?v={{$smarty.const.FRIENDICA_VERSION}}"></script>
47 <script type="text/javascript" src="view/js/fancybox/jquery.fancybox.min.js?v={{$smarty.const.FRIENDICA_VERSION}}"></script>
48 <script type="text/javascript" src="view/js/fancybox/fancybox.config.js?v={{$smarty.const.FRIENDICA_VERSION}}"></script>
49 <script type="text/javascript" src="view/js/vanillaEmojiPicker/vanillaEmojiPicker.min.js?v={{$smarty.const.FRIENDICA_VERSION}}"></script>
50 <script>
51 window.onload = function(){
52         new EmojiPicker({
53                 trigger: [
54                         {
55                                 selector: '.emojis-post',
56                                 insertInto: ['#comment-edit-text-0', '#profile-jot-text']
57                         },
58                         {
59                                 selector: '.emojis',
60                                 insertInto: ['.comment-edit-text-full']
61                         }
62                 ],
63                 closeButton: true
64         });
65 };
66 </script>
67 <script type="text/javascript">
68         const updateInterval = {{$update_interval}};
69         const localUser = {{if $local_user}}{{$local_user}}{{else}}false{{/if}};
70 </script>
71 <script type="text/javascript" src="view/js/main.js?v={{$smarty.const.FRIENDICA_VERSION}}"></script>
72 <script>
73         // Lifted from https://css-tricks.com/snippets/jquery/move-cursor-to-end-of-textarea-or-input/
74     jQuery.fn.putCursorAtEnd = function() {
75         return this.each(function() {
76             // Cache references
77             var $el = $(this),
78                 el = this;
79
80             // Only focus if input isn't already
81             if (!$el.is(":focus")) {
82                 $el.focus();
83             }
84
85             // If this function exists... (IE 9+)
86             if (el.setSelectionRange) {
87                 // Double the length because Opera is inconsistent about whether a carriage return is one character or two.
88                 var len = $el.val().length * 2;
89
90                 // Timeout seems to be required for Blink
91                 setTimeout(function() {
92                     el.setSelectionRange(len, len);
93                 }, 1);
94             } else {
95                 // As a fallback, replace the contents with itself
96                 // Doesn't work in Chrome, but Chrome supports setSelectionRange
97                 $el.val($el.val());
98             }
99
100             // Scroll to the bottom, in case we're in a tall textarea
101             // (Necessary for Firefox and Chrome)
102             this.scrollTop = 999999;
103         });
104     };
105
106         function confirmDelete() { return confirm("{{$delitem}}"); }
107         function commentExpand(id) {
108                 $("#comment-edit-text-" + id).putCursorAtEnd();
109                 $("#comment-edit-text-" + id).addClass("comment-edit-text-full");
110                 $("#comment-edit-text-" + id).removeClass("comment-edit-text-empty");
111                 $("#mod-cmnt-wrap-" + id).show();
112                 openMenu("comment-edit-submit-wrapper-" + id);
113                 return true;
114         }
115         function commentOpen(obj,id) {
116                 if (obj.value == "") {
117                         $("#comment-edit-text-" + id).addClass("comment-edit-text-full");
118                         $("#comment-edit-text-" + id).removeClass("comment-edit-text-empty");
119                         $("#mod-cmnt-wrap-" + id).show();
120                         openMenu("comment-edit-submit-wrapper-" + id);
121                         return true;
122                 }
123                 return false;
124         }
125         function commentClose(obj,id) {
126                 if (obj.value == "") {
127                         $("#comment-edit-text-" + id).removeClass("comment-edit-text-full");
128                         $("#comment-edit-text-" + id).addClass("comment-edit-text-empty");
129                         $("#mod-cmnt-wrap-" + id).hide();
130                         closeMenu("comment-edit-submit-wrapper-" + id);
131                         return true;
132                 }
133                 return false;
134         }
135
136         function commentInsert(obj,id) {
137                 var tmpStr = $("#comment-edit-text-" + id).val();
138                 if (tmpStr == "") {
139                         $("#comment-edit-text-" + id).addClass("comment-edit-text-full");
140                         $("#comment-edit-text-" + id).removeClass("comment-edit-text-empty");
141                         openMenu("comment-edit-submit-wrapper-" + id);
142                 }
143                 var ins = $(obj).html();
144                 ins = ins.replace("&lt;","<");
145                 ins = ins.replace("&gt;",">");
146                 ins = ins.replace("&amp;","&");
147                 ins = ins.replace("&quot;","\"");
148                 $("#comment-edit-text-" + id).val(tmpStr + ins);
149         }
150
151         function showHideCommentBox(id) {
152                 if ($("#comment-edit-form-" + id).is(":visible")) {
153                         $("#comment-edit-form-" + id).hide();
154                 } else {
155                         $("#comment-edit-form-" + id).show();
156                 }
157         }
158 </script>