show_article.blade.php 2.5 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677
  1. @inject('systemPresenter', 'App\Presenters\SystemPresenter')
  2. @extends('layouts.app')
  3. @section('title', $systemPresenter->checkReturnValue('title', $article->title))
  4. @section('description', $systemPresenter->checkReturnValue('seo_desc', $article->desc))
  5. @section('keywords', $systemPresenter->checkReturnValue('seo_keyword', $article->keyword))
  6. @section('style')
  7. <link rel="stylesheet" href="{{ asset('editor.md/css/editormd.preview.min.css') }}">
  8. <link rel="stylesheet" href="{{ asset('share.js/css/share.min.css') }}">
  9. @endsection
  10. @section('header-text')
  11. <div class="text-inner">
  12. <div class="row">
  13. <div class="col-md-12 article-info">
  14. <h3 class="to-animate fadeInUp animated">
  15. {{ $article->title }}
  16. </h3>
  17. <p class="to-animate fadeInUp animated" style="margin-top:10px;">
  18. {{ $article->desc }}
  19. </p>
  20. <p class="to-animate fadeInUp animated">
  21. <i class="glyphicon glyphicon-calendar"></i>{{ $article->created_at }}
  22. &nbsp;
  23. <i class="glyphicon glyphicon-user"></i>{{ $user->name }}
  24. </p>
  25. </div>
  26. </div>
  27. </div>
  28. @endsection
  29. @section('content')
  30. <div class="markdown-body editormd-html-preview" style="padding:0;">
  31. {!! $article->html_content !!}
  32. </div>
  33. <div class="panel panel-default" style="margin-top:10px;">
  34. <div>
  35. <div id="share" class="social-share"></div>
  36. </div>
  37. <div class="panel-body">
  38. <p>分类:
  39. <i class="glyphicon glyphicon-th-list"></i>
  40. <a href="{{ route('category', ['id' => $category->id]) }}" target="_blank">
  41. {{ $category->name }}
  42. </a>
  43. </p>
  44. @if ($tags)
  45. <p>标签:
  46. <i class="glyphicon glyphicon-tags"></i>&nbsp;
  47. @foreach ($tags as $tag)
  48. <a href="{{ route('tag', ['id' => $tag->id]) }}" target="_blank">
  49. {{ $tag->tag_name }} &nbsp;
  50. </a>
  51. @endforeach
  52. </p>
  53. @endif
  54. </div>
  55. </div>
  56. @endsection
  57. @section('script')
  58. <script src="{{ asset('share.js/js/jquery.share.min.js') }}"></script>
  59. <script>
  60. $(function(){
  61. $('#share').share({sites: ['qzone', 'qq', 'weibo','wechat']});
  62. });
  63. </script>
  64. @endsection