index.tpl 5.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136
  1. <!DOCTYPE html>
  2. <html lang="zh-CN">
  3. <head>
  4. <meta charset="utf-8">
  5. <meta http-equiv="X-UA-Compatible" content="IE=edge">
  6. <meta name="viewport" content="width=device-width, initial-scale=1">
  7. <meta name="renderer" content="webkit">
  8. <meta name="author" content="Minho" />
  9. <meta name="site" content="https://www.iminho.me" />
  10. <meta name="keywords" content="{{.Model.BlogTitle}}">
  11. <meta name="description" content="{{.Model.BlogTitle}}-{{.Description}}">
  12. <title>{{.Model.BlogTitle}} - Powered by MinDoc</title>
  13. <!-- Bootstrap -->
  14. <link href="{{cdncss "/static/bootstrap/css/bootstrap.min.css"}}" rel="stylesheet">
  15. <link href="{{cdncss "/static/font-awesome/css/font-awesome.min.css"}}" rel="stylesheet">
  16. <link href="{{cdncss "/static/css/kancloud.css" "version"}}" rel="stylesheet">
  17. <link href="{{cdncss "/static/editor.md/css/editormd.preview.css"}}" rel="stylesheet">
  18. <link href="{{cdncss "/static/css/markdown.preview.css" "version"}}" rel="stylesheet">
  19. <link href="{{cdncss (print "/static/editor.md/lib/highlight/styles/" .HighlightStyle ".css") "version"}}" rel="stylesheet">
  20. <link href="{{cdncss "/static/katex/katex.min.css"}}" rel="stylesheet">
  21. <link href="{{cdncss "/static/css/print.css"}}" media="print" rel="stylesheet">
  22. <link href="{{cdncss "/static/css/main.css" "version"}}" rel="stylesheet">
  23. <!-- HTML5 shim and Respond.js for IE8 support of HTML5 elements and media queries -->
  24. <!-- WARNING: Respond.js doesn't work if you view the page via file:// -->
  25. <!--[if lt IE 9]>
  26. <script src="/static/html5shiv/3.7.3/html5shiv.min.js"></script>
  27. <script src="/static/respond.js/1.4.2/respond.min.js"></script>
  28. <![endif]-->
  29. <style type="text/css">
  30. .header{
  31. min-height: 1rem;
  32. font-size: 26px;
  33. font-weight: 400;
  34. display: block;
  35. margin: 20px auto;
  36. }
  37. .blog-meta{
  38. display: inline-block;
  39. }
  40. .blog-meta>.item{
  41. display: inline-block;
  42. color: #666666;
  43. vertical-align: middle;
  44. }
  45. .blog-footer{
  46. margin: 25px auto;
  47. /*border-top: 1px solid #E5E5E5;*/
  48. padding: 20px 1px;
  49. line-height: 35px;
  50. }
  51. .blog-footer span{
  52. margin-right: 8px;
  53. padding: 6px 8px;
  54. font-size: 12px;
  55. border: 1px solid #e3e3e3;
  56. color: #4d4d4d
  57. }
  58. .blog-footer a:hover{
  59. color: #ca0c16;
  60. }
  61. .footer{
  62. margin-top: 0;
  63. }
  64. .user_img img {
  65. display: block;
  66. width: 24px;
  67. height: 24px;
  68. border-radius: 50%;
  69. -o-object-fit: cover;
  70. object-fit: cover;
  71. overflow: hidden;
  72. }
  73. </style>
  74. </head>
  75. <body>
  76. <div class="manual-reader manual-container manual-search-reader">
  77. {{template "widgets/header.tpl" .}}
  78. <div class="container manual-body">
  79. <div class="search-head" style="border-bottom-width: 1px;">
  80. <h1 class="header">
  81. {{.Model.BlogTitle}}
  82. </h1>
  83. <div class="blog-meta">
  84. <div class="item user_img"><img src="{{cdnimg .Model.MemberAvatar}}" align="{{.Model.CreateName}}"> </div>
  85. <div class="item">&nbsp;{{.Model.CreateName}}</div>
  86. <div class="item">发布于</div>
  87. <div class="item">{{date .Model.Created "Y-m-d H:i:s"}}</div>
  88. <div class="item">{{.Model.ModifyRealName}}</div>
  89. <div class="item">修改于</div>
  90. <div class="item">{{date .Model.Modified "Y-m-d H:i:s"}}</div>
  91. </div>
  92. </div>
  93. <div class="row">
  94. <div class="article-body markdown-body editormd-preview-container content">
  95. {{.Content}}
  96. {{if .Model.AttachList}}
  97. <div class="attach-list"><strong>附件</strong><ul>
  98. {{range $index,$item := .Model.AttachList}}
  99. <li><a href="{{$item.HttpPath}}" title="{{$item.FileName}}">{{$item.FileName}}</a> </li>
  100. {{end}}
  101. </ul>
  102. {{end}}
  103. </div>
  104. </div>
  105. <div class="row blog-footer">
  106. <p>
  107. <span>上一篇</span>
  108. {{if .Previous}}
  109. <a href="{{urlfor "BlogController.Index" ":id" .Previous.BlogId}}" title="{{.Previous.BlogTitle}}">{{.Previous.BlogTitle}}
  110. </a>
  111. {{else}}
  112. {{end}}
  113. </p>
  114. <p>
  115. <span>下一篇</span>
  116. {{if .Next}}
  117. <a href="{{urlfor "BlogController.Index" ":id" .Next.BlogId}}" title="{{.Next.BlogTitle}}">{{.Next.BlogTitle}}</a>
  118. {{else}}
  119. {{end}}
  120. </p>
  121. </div>
  122. </div>
  123. {{template "widgets/footer.tpl" .}}
  124. </div>
  125. </div>
  126. <script src="{{cdnjs "/static/jquery/1.12.4/jquery.min.js"}}"></script>
  127. <script src="{{cdnjs "/static/bootstrap/js/bootstrap.min.js"}}"></script>
  128. <script src="{{cdnjs "/static/layer/layer.js"}}" type="text/javascript"></script>
  129. <script src="{{cdnjs "/static/js/kancloud.js"}}" type="text/javascript"></script>
  130. </body>
  131. </html>