You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

190 lines
7.7 KiB

10 years ago
Add lang specific font stacks for CJK (#6007) * Add lang specific font stacks * Force font changes Signed-off-by: Andrew Thornton <art27@cantab.net> * Fix icons Signed-off-by: Andrew Thornton <art27@cantab.net> * Fix octicons and icons Signed-off-by: Andrew Thornton <art27@cantab.net> * Just override the semantic ui fonts only Signed-off-by: Andrew Thornton <art27@cantab.net> * Missed the headers... override them too * Missed some more semantic ui stuff * Fix PT Sans Signed-off-by: Andrew Thornton <art27@cantab.net> * More changes Signed-off-by: Andrew Thornton <art27@cantab.net> * Squashed commit of the following: commit 7d1679e9079541359869c9e677ba7412bfcc59f3 Author: Mike L <cl.jeremy@qq.com> Date: Wed Mar 13 13:53:49 2019 +0100 Remove missed YaHei leftover from _home.less commit 0079121ea91860a323ed4e5cc1a9c0d490d9cefd Author: Mike L <cl.jeremy@qq.com> Date: Wed Mar 13 12:03:54 2019 +0100 Fix overdone fixes (inherit, :lang) commit 62c919915928ec1db4731d547e95885f91a0618d Author: Mike L <cl.jeremy@qq.com> Date: Wed Mar 13 02:29:10 2019 +0100 Fix elements w/ explicit lang (language chooser) commit b3117587aa2eb8570d60bed583a11ee5565418be Author: Mike L <cl.jeremy@qq.com> Date: Tue Mar 12 20:17:26 2019 +0100 Fix textarea also (to match body) commit 81cedf2c3012c4dd05a7680782b4a98e1b947f67 Author: Mike L <cl.jeremy@qq.com> Date: Tue Mar 12 19:41:39 2019 +0100 Revert css temporarily to fix conflict commit 80ff82797f3203cbeaf866f22e961334e137df89 Author: Mike L <cl.jeremy@qq.com> Date: Tue Mar 12 19:15:30 2019 +0100 Tweak CJK, fix Yu Gothic, more monospace inherits commit 581dceb9a869646c2c486dabb925c88c2680d70c Author: Mike L <cl.jeremy@qq.com> Date: Mon Mar 11 13:09:26 2019 +0100 Add Lato for latin extd. & cyrillic, improve CJK * update stylesheet
5 years ago
9 years ago
9 years ago
9 years ago
10 years ago
10 years ago
9 years ago
10 years ago
9 years ago
9 years ago
9 years ago
  1. <!DOCTYPE html>
  2. <html lang="{{.Language}}">
  3. <head data-suburl="{{AppSubUrl}}">
  4. <meta charset="utf-8">
  5. <meta name="viewport" content="width=device-width, initial-scale=1">
  6. <meta http-equiv="x-ua-compatible" content="ie=edge">
  7. <title>{{if .Title}}{{.Title}} - {{end}} {{if .Repository.Name}}{{.Repository.Name}} - {{end}}{{AppName}}</title>
  8. <link rel="manifest" href="{{AppSubUrl}}/manifest.json" crossorigin="use-credentials">
  9. {{if UseServiceWorker}}
  10. <script>
  11. if ('serviceWorker' in navigator) {
  12. navigator.serviceWorker.register('{{AppSubUrl}}/serviceworker.js').then(function(registration) {
  13. // Registration was successful
  14. console.info('ServiceWorker registration successful with scope: ', registration.scope);
  15. }, function(err) {
  16. // registration failed :(
  17. console.info('ServiceWorker registration failed: ', err);
  18. });
  19. }
  20. </script>
  21. {{else}}
  22. <script>
  23. if ('serviceWorker' in navigator) {
  24. navigator.serviceWorker.getRegistrations().then(function(registrations) {
  25. registrations.forEach(function(registration) {
  26. registration.unregister();
  27. console.info('ServiceWorker unregistered');
  28. });
  29. });
  30. }
  31. </script>
  32. {{end}}
  33. <meta name="theme-color" content="{{ThemeColorMetaTag}}">
  34. <meta name="author" content="{{if .Repository}}{{.Owner.Name}}{{else}}{{MetaAuthor}}{{end}}" />
  35. <meta name="description" content="{{if .Repository}}{{.Repository.Name}}{{if .Repository.Description}} - {{.Repository.Description}}{{end}}{{else}}{{MetaDescription}}{{end}}" />
  36. <meta name="keywords" content="{{MetaKeywords}}">
  37. <meta name="referrer" content="no-referrer" />
  38. <meta name="_csrf" content="{{.CsrfToken}}" />
  39. <meta name="_suburl" content="{{AppSubUrl}}" />
  40. {{if .IsSigned}}
  41. <meta name="_uid" content="{{.SignedUser.ID}}" />
  42. {{end}}
  43. {{if .ContextUser}}
  44. <meta name="_context_uid" content="{{.ContextUser.ID}}" />
  45. {{end}}
  46. {{if .SearchLimit}}
  47. <meta name="_search_limit" content="{{.SearchLimit}}" />
  48. {{end}}
  49. {{if .GoGetImport}}
  50. <meta name="go-import" content="{{.GoGetImport}} git {{.CloneLink.HTTPS}}">
  51. <meta name="go-source" content="{{.GoGetImport}} _ {{.GoDocDirectory}} {{.GoDocFile}}">
  52. {{end}}
  53. <script>
  54. {{SafeJS `/*
  55. @licstart The following is the entire license notice for the
  56. JavaScript code in this page.
  57. Copyright (c) 2016 The Gitea Authors
  58. Copyright (c) 2015 The Gogs Authors
  59. Permission is hereby granted, free of charge, to any person obtaining a copy
  60. of this software and associated documentation files (the "Software"), to deal
  61. in the Software without restriction, including without limitation the rights
  62. to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
  63. copies of the Software, and to permit persons to whom the Software is
  64. furnished to do so, subject to the following conditions:
  65. The above copyright notice and this permission notice shall be included in
  66. all copies or substantial portions of the Software.
  67. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
  68. IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
  69. FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
  70. AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
  71. LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
  72. OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
  73. THE SOFTWARE.
  74. ---
  75. Licensing information for additional javascript libraries can be found at:
  76. {{StaticUrlPrefix}}/vendor/librejs.html
  77. @licend The above is the entire license notice
  78. for the JavaScript code in this page.
  79. */`}}
  80. </script>
  81. <link rel="shortcut icon" href="{{StaticUrlPrefix}}/img/favicon.png" />
  82. <link rel="mask-icon" href="{{StaticUrlPrefix}}/img/gitea-safari.svg" color="#609926">
  83. <link rel="preload" href="{{StaticUrlPrefix}}/vendor/assets/font-awesome/css/font-awesome.min.css" as="style" onload="this.rel='stylesheet'">
  84. <noscript><link rel="stylesheet" href="{{StaticUrlPrefix}}/vendor/assets/font-awesome/css/font-awesome.min.css"></noscript>
  85. <link rel="stylesheet" href="{{StaticUrlPrefix}}/vendor/assets/octicons/octicons.min.css">
  86. {{if .RequireSimpleMDE}}
  87. <link rel="stylesheet" href="{{StaticUrlPrefix}}/vendor/plugins/simplemde/simplemde.min.css">
  88. {{end}}
  89. {{if .RequireTribute}}
  90. <link rel="stylesheet" href="{{StaticUrlPrefix}}/vendor/plugins/tribute/tribute.css">
  91. {{end}}
  92. <!-- Stylesheet -->
  93. <link rel="stylesheet" href="{{StaticUrlPrefix}}/vendor/plugins/fomantic/semantic.min.css?v={{MD5 AppVer}}">
  94. <link rel="stylesheet" href="{{StaticUrlPrefix}}/css/index.css?v={{MD5 AppVer}}">
  95. <noscript>
  96. <style>
  97. .dropdown:hover > .menu { display: block; }
  98. .ui.secondary.menu .dropdown.item > .menu { margin-top: 0; }
  99. </style>
  100. </noscript>
  101. {{if .RequireHighlightJS}}
  102. <link rel="stylesheet" href="{{StaticUrlPrefix}}/vendor/plugins/highlight/github.css">
  103. {{end}}
  104. {{if .RequireMinicolors}}
  105. <link rel="stylesheet" href="{{StaticUrlPrefix}}/vendor/plugins/jquery.minicolors/jquery.minicolors.css">
  106. {{end}}
  107. {{if .RequireDatetimepicker}}
  108. <link rel="stylesheet" href="{{StaticUrlPrefix}}/vendor/plugins/jquery.datetimepicker/jquery.datetimepicker.css">
  109. {{end}}
  110. {{if .RequireDropzone}}
  111. <link rel="stylesheet" href="{{StaticUrlPrefix}}/vendor/plugins/dropzone/dropzone.css">
  112. {{end}}
  113. {{if .EnableHeatmap}}
  114. <link rel="stylesheet" href="{{StaticUrlPrefix}}/vendor/plugins/vue-calendar-heatmap/vue-calendar-heatmap.css">
  115. {{end}}
  116. <style class="list-search-style"></style>
  117. <script src="{{StaticUrlPrefix}}/vendor/plugins/promise-polyfill/polyfill.min.js"></script>
  118. <script src="{{StaticUrlPrefix}}/vendor/plugins/cssrelpreload/loadCSS.min.js"></script>
  119. <script src="{{StaticUrlPrefix}}/vendor/plugins/cssrelpreload/cssrelpreload.min.js"></script>
  120. {{if .PageIsUserProfile}}
  121. <meta property="og:title" content="{{.Owner.Name}}" />
  122. <meta property="og:type" content="profile" />
  123. <meta property="og:image" content="{{.Owner.AvatarLink}}" />
  124. <meta property="og:url" content="{{.Owner.HTMLURL}}" />
  125. {{if .Owner.Description}}
  126. <meta property="og:description" content="{{.Owner.Description}}">
  127. {{end}}
  128. {{else if .Repository}}
  129. {{if .Issue}}
  130. <meta property="og:title" content="{{.Issue.Title}}" />
  131. <meta property="og:url" content="{{.Issue.HTMLURL}}" />
  132. {{if .Issue.Content}}
  133. <meta property="og:description" content="{{.Issue.Content}}" />
  134. {{end}}
  135. {{else}}
  136. <meta property="og:title" content="{{.Repository.Name}}" />
  137. <meta property="og:url" content="{{.Repository.HTMLURL}}" />
  138. {{if .Repository.Description}}
  139. <meta property="og:description" content="{{.Repository.Description}}" />
  140. {{end}}
  141. {{end}}
  142. <meta property="og:type" content="object" />
  143. <meta property="og:image" content="{{.Repository.Owner.AvatarLink}}" />
  144. {{else}}
  145. <meta property="og:title" content="{{AppName}}">
  146. <meta property="og:type" content="website" />
  147. <meta property="og:image" content="{{StaticUrlPrefix}}img/gitea-lg.png" />
  148. <meta property="og:url" content="{{AppUrl}}" />
  149. <meta property="og:description" content="{{MetaDescription}}">
  150. {{end}}
  151. <meta property="og:site_name" content="{{AppName}}" />
  152. {{if .IsSigned }}
  153. {{ if ne .SignedUser.Theme "gitea" }}
  154. <link rel="stylesheet" href="{{StaticUrlPrefix}}/css/theme-{{.SignedUser.Theme}}.css?v={{MD5 AppVer}}">
  155. {{end}}
  156. {{else if ne DefaultTheme "gitea"}}
  157. <link rel="stylesheet" href="{{StaticUrlPrefix}}/css/theme-{{DefaultTheme}}.css?v={{MD5 AppVer}}">
  158. {{end}}
  159. {{template "custom/header" .}}
  160. </head>
  161. <body>
  162. {{template "custom/body_outer_pre" .}}
  163. <div class="full height">
  164. <noscript>{{.i18n.Tr "enable_javascript"}}</noscript>
  165. {{template "custom/body_inner_pre" .}}
  166. {{if not .PageIsInstall}}
  167. <div class="ui top secondary stackable main menu following bar light">
  168. {{template "base/head_navbar" .}}
  169. </div><!-- end bar -->
  170. {{end}}
  171. {{/*
  172. </div>
  173. </body>
  174. </html>
  175. */}}