ソースを参照

Move css files and adjust template

Sotaro KARASAWA 9 年 前
コミット
aa99a49446
5 ファイル変更12 行追加4 行削除
  1. 5 1
      gulpfile.js
  2. 0 1
      lib/views/layout/layout.html
  3. 1 1
      lib/views/page.html
  4. 1 1
      lib/views/page_list.html
  5. 5 0
      resource/css/crowi.scss

+ 5 - 1
gulpfile.js

@@ -129,7 +129,11 @@ gulp.task('css:sass', function() {
 });
 
 gulp.task('css:concat', ['css:sass'], function() {
-  return gulp.src([css.main, 'node_modules/highlight.js/styles/tomorrow-night.css'])
+  return gulp.src([
+      css.main,
+      'node_modules/highlight.js/styles/tomorrow-night.css',
+      'node_modules/diff2html/dist/diff2html.css',
+    ])
     .pipe(concat('crowi.css'))
     .pipe(gulp.dest(dirs.cssDist))
 });

+ 0 - 1
lib/views/layout/layout.html

@@ -12,7 +12,6 @@
   <meta name="viewport" content="width=device-width,initial-scale=1">
 
   <link rel="stylesheet" href="/css/crowi{% if env  == 'production' %}.min{% endif %}.css">
-  <link rel="stylesheet" href="/css/diff2html/diff2html{% if env  == 'production' %}.min{% endif %}.css">
 
   <script src="{{ assets('/js/bundled.js') }}"></script>
   <link href='//fonts.googleapis.com/css?family=Open+Sans:400,700' rel='stylesheet' type='text/css'>

+ 1 - 1
lib/views/page.html

@@ -189,7 +189,7 @@
               <a class="diff-view" data-revision-id="{{ tt._id.toString() }}">
                 <i id="diff-icon-{{ tt._id.toString() }}" class="fa fa-arrow-circle-right"></i> {{ t('View diff') }}
               </a>
-              <pre class="" id="diff-display-{{ tt._id.toString()}}" style="display: none"></pre>
+              <div class="" id="diff-display-{{ tt._id.toString()}}" style="display: none"></div>
             </div>
           </div>
         </div>

+ 1 - 1
lib/views/page_list.html

@@ -148,7 +148,7 @@
               <a class="diff-view" data-revision-id="{{ tr._id.toString() }}">
                 <i id="diff-icon-{{ tr._id.toString() }}" class="fa fa-arrow-circle-right"></i> {{ t('View diff') }}
               </a>
-              <pre class="" id="diff-display-{{ tr._id.toString()}}" style="display: none"></pre>
+              <div class="" id="diff-display-{{ tr._id.toString()}}" style="display: none"></div>
             </div>
           </div>
         </div>

+ 5 - 0
resource/css/crowi.scss

@@ -251,6 +251,11 @@ footer {
   border-radius: 3px;
 }
 
+// adust
+.d2h-file-header {
+  display: none;
+}
+
 // components
 .flip-container { // {{{
   perspective: 1000;