summaryrefslogtreecommitdiffstats
path: root/web/templates/head.html
diff options
context:
space:
mode:
Diffstat (limited to 'web/templates/head.html')
-rw-r--r--web/templates/head.html191
1 files changed, 0 insertions, 191 deletions
diff --git a/web/templates/head.html b/web/templates/head.html
deleted file mode 100644
index 61b1aa12b..000000000
--- a/web/templates/head.html
+++ /dev/null
@@ -1,191 +0,0 @@
-{{define "head"}}
-<head>
- <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
- <meta name="robots" content="noindex, nofollow">
- <meta name="referrer" content="no-referrer">
-
- <title>{{ .Props.Title }}</title>
-
- <!-- iOS add to homescreen -->
- <meta name="apple-mobile-web-app-capable" content="yes" />
- <meta name="apple-mobile-web-app-status-bar-style" content="default">
- <meta name="mobile-web-app-capable" content="yes" />
- <meta name="apple-mobile-web-app-title" content="{{ .Props.Title }}">
- <meta name="application-name" content="{{ .Props.Title }}">
- <meta name="format-detection" content="telephone=no">
- <!-- iOS add to homescreen -->
-
- <!-- Android add to homescreen -->
- <link rel="apple-touch-icon" sizes="57x57" href="/static/images/favicon/apple-touch-icon-57x57.png">
- <link rel="apple-touch-icon" sizes="60x60" href="/static/images/favicon/apple-touch-icon-60x60.png">
- <link rel="apple-touch-icon" sizes="72x72" href="/static/images/favicon/apple-touch-icon-72x72.png">
- <link rel="apple-touch-icon" sizes="76x76" href="/static/images/favicon/apple-touch-icon-76x76.png">
- <link rel="apple-touch-icon" sizes="114x114" href="/static/images/favicon/apple-touch-icon-114x114.png">
- <link rel="apple-touch-icon" sizes="120x120" href="/static/images/favicon/apple-touch-icon-120x120.png">
- <link rel="apple-touch-icon" sizes="144x144" href="/static/images/favicon/apple-touch-icon-144x144.png">
- <link rel="apple-touch-icon" sizes="152x152" href="/static/images/favicon/apple-touch-icon-152x152.png">
- <link rel="apple-touch-icon" sizes="180x180" href="/static/images/favicon/apple-touch-icon-180x180.png">
- <link rel="icon" type="image/png" sizes="32x32" href="/static/images/favicon/favicon-32x32.png">
- <link rel="icon" type="image/png" sizes="192x192" href="/static/images/favicon/android-chrome-192x192.png">
- <link rel="icon" type="image/png" sizes="96x96" href="/static/images/favicon/favicon-96x96.png">
- <link rel="icon" type="image/png" sizes="16x16" href="/static/images/favicon/favicon-16x16.png">
- <link rel="manifest" href="/static/config/manifest.json">
- <!-- Android add to homescreen -->
-
- <!-- CSS Should always go first -->
- <link rel="stylesheet" href="/static/css/bootstrap-3.3.5.min.css">
- <link rel="stylesheet" href="/static/css/jasny-bootstrap.min.css">
- <link rel="stylesheet" href="/static/css/bootstrap-colorpicker.min.css">
- <link rel="stylesheet" href="/static/css/styles.css">
- <link rel="stylesheet" href="/static/css/google-fonts.css">
- <link rel="stylesheet" href="/static/css/katex.min.css">
- <link rel="stylesheet" class="code_theme" href="">
-
- <script src="/static/js/intl-1.0.0/Intl.js"></script>
- <script src="/static/js/intl-1.0.0/locale-data/jsonp/en.js"></script>
- <script src="/static/js/intl-1.0.0/locale-data/jsonp/es.js"></script>
- <script src="/static/js/intl-1.0.0/locale-data/jsonp/pt.js"></script>
-
- <script src="/static/js/react-0.14.3.js"></script>
- <script src="/static/js/react-dom-0.14.3.js"></script>
- <script src="/static/js/react-intl-2.0.0-beta-2/react-intl.js"></script>
- <script src="/static/js/react-intl-2.0.0-beta-2/locale-data/en.js"></script>
- <script src="/static/js/react-intl-2.0.0-beta-2/locale-data/es.js"></script>
- <script src="/static/js/react-intl-2.0.0-beta-2/locale-data/pt.js"></script>
- <script src="/static/js/jquery-2.1.4.js"></script>
- <script src="/static/js/bootstrap-3.3.5.js"></script>
- <script src="/static/js/bootstrap-colorpicker.min.js"></script>
- <script src="/static/js/react-bootstrap-0.28.1.js"></script>
- <script src="/static/js/velocity.min.js"></script>
- <script src="/static/js/perfect-scrollbar-0.6.7.jquery.min.js"></script>
- <script src="/static/js/jquery-dragster/jquery.dragster.js"></script>
- <script src="/static/js/babel-polyfill-6.1.18.min.js"></script>
- <script src="/static/js/katex.min.js"></script>
-
- <style id="antiClickjack">body{display:none !important;}</style>
-
- <script>
- if ('ReactIntl' in window && 'ReactIntlLocaleData' in window) {
- Object.keys(ReactIntlLocaleData).forEach(function(lang) {
- ReactIntl.addLocaleData(ReactIntlLocaleData[lang]);
- });
- }
-
- window.mm_config = {{ .ClientCfg }};
- window.mm_license = {{ .ClientLicense }};
- window.mm_team = {{ .Team }};
- window.mm_user = {{ .User }};
- window.mm_channel = {{ .Channel }};
- window.mm_locale = {{ .Locale }};
- window.mm_preferences = {{ .Preferences }};
-
- $(function() {
- if (window.mm_preferences != null) {
- PreferenceStore.setPreferences(window.mm_preferences);
- PreferenceStore.emitChange();
- }
- });
-
- if ({{.SessionTokenIndex}} >= 0) {
- window.mm_session_token_index = {{.SessionTokenIndex}};
- $.ajaxSetup({
- headers: {
- 'X-MM-TokenIndex': mm_session_token_index,
- 'Accept-Language': mm_locale
- }
- });
- } else {
- $.ajaxSetup({
- headers: {
- 'Accept-Language': mm_locale
- }
- });
- }
-
- $(function () {
- $(window).bind('storage', function (e) {
- // when one tab on a browser logs out, it sets __logout__ in localStorage to trigger other tabs to log out
- if (e.originalEvent.key === '__logout__' && e.originalEvent.storageArea === localStorage && e.originalEvent.newValue) {
- // make sure it isn't this tab that is sending the logout signal (only necessary for IE11)
- if (window.BrowserStore.isSignallingLogout(e.originalEvent.newValue)) {
- return;
- }
-
- console.log('detected logout from a different tab');
- window.location.href = '/' + window.mm_team.name;
- }
-
- if (e.originalEvent.key === '__login__' && e.originalEvent.storageArea === localStorage && e.originalEvent.newValue) {
- // make sure it isn't this tab that is sending the logout signal (only necessary for IE11)
- if (window.BrowserStore.isSignallingLogin(e.originalEvent.newValue)) {
- return;
- }
-
- console.log('detected login from a different tab');
- location.reload();
- }
- });
- });
-
- $(window).on('beforeunload', function(){
- if (window.SocketStore) {
- SocketStore.close();
- }
- });
- </script>
-
- <script>
- window.onerror = function(msg, url, line, column, stack) {
- var l = {};
- l.level = 'ERROR';
- l.message = 'msg: ' + msg + ' row: ' + line + ' col: ' + column + ' stack: ' + stack + ' url: ' + url;
-
- $.ajax({
- url: '/api/v1/admin/log_client',
- dataType: 'json',
- contentType: 'application/json',
- type: 'POST',
- data: JSON.stringify(l)
- });
-
- if (window.mm_config.EnableDeveloper === 'true') {
- window.ErrorStore.storeLastError({message: 'DEVELOPER MODE: A javascript error has occured. Please use the javascript console to capture and report the error (row: ' + line + ' col: ' + column + ').'});
- window.ErrorStore.emitChange();
- }
- }
- </script>
-
- <script src="/static/js/libs.min.js"></script>
- <script src="/static/js/bundle.js"></script>
-
- <script type="text/javascript">
- if (self === top) {
- var blocker = document.getElementById("antiClickjack");
- blocker.parentNode.removeChild(blocker);
- }
- </script>
-
- <script type="text/javascript">
- if (window.mm_config.SegmentDeveloperKey != null && window.mm_config.SegmentDeveloperKey !== "") {
- !function(){var analytics=window.analytics=window.analytics||[];if(!analytics.initialize)if(analytics.invoked)window.console&&console.error&&console.error("Segment snippet included twice.");else{analytics.invoked=!0;analytics.methods=["trackSubmit","trackClick","trackLink","trackForm","pageview","identify","group","track","ready","alias","page","once","off","on"];analytics.factory=function(t){return function(){var e=Array.prototype.slice.call(arguments);e.unshift(t);analytics.push(e);return analytics}};for(var t=0;t<analytics.methods.length;t++){var e=analytics.methods[t];analytics[e]=analytics.factory(e)}analytics.load=function(t){var e=document.createElement("script");e.type="text/javascript";e.async=!0;e.src=("https:"===document.location.protocol?"https://":"http://")+"cdn.segment.com/analytics.js/v1/"+t+"/analytics.min.js";var n=document.getElementsByTagName("script")[0];n.parentNode.insertBefore(e,n)};analytics.SNIPPET_VERSION="3.0.1";
- analytics.load(window.mm_config.SegmentDeveloperKey);
- if (window.mm_user) {
- analytics.identify(window.mm_user.id, {
- name: window.mm_user.nickname,
- email: window.mm_user.email,
- createdAt: window.mm_user.create_at,
- username: window.mm_user.username,
- team_id: window.mm_user.team_id,
- id: window.mm_user.id
- });
- }
- analytics.page();
- }}();
- } else {
- analytics = {};
- analytics.page = function(){};
- analytics.track = function(){};
- }
- </script>
-</head>
-{{end}}