fix embed style inclusion and embed overflow handling v0.5.0
authorChristian Weiske <cweiske@cweiske.de>
Tue, 3 Feb 2015 19:41:59 +0000 (20:41 +0100)
committerChristian Weiske <cweiske@cweiske.de>
Tue, 3 Feb 2015 19:41:59 +0000 (20:41 +0100)
data/templates/embed.htm
www/css/embed.css

index 22c9b1970b65cf49dfb98b2201a95addb1ef3d50..fcbd2ccac09798c4f022d062c063e18dc51ff472 100644 (file)
@@ -1,8 +1,9 @@
 /* embedding all files of {{repo.getLink('display', null, true)}} */
 var me = document.getElementById('phork-script-{{repo.id}}');
 /* embedding all files of {{repo.getLink('display', null, true)}} */
 var me = document.getElementById('phork-script-{{repo.id}}');
-me.insertAdjacentHTML('afterend', '<link rel="stylesheet" href="{{htmlhelper.fullUrl('css/embed.css')}}"/>');
-me.insertAdjacentHTML('afterend',
-    '<div class="phork" id="{{repo.id}}">'
+me.insertAdjacentHTML(
+    'afterend',
+    '<link rel="stylesheet" href="{{htmlhelper.fullUrl('css/embed.css')}}"/>'
+    + '<div class="phork" id="{{repo.id}}">'
 {% for file in repo.getFiles %}
     + {% filter json_encode(constant('JSON_UNESCAPED_SLASHES'))|raw -%}{% include 'embed-part-file.htm' %}{%- endfilter %}
 {% endfor %}
 {% for file in repo.getFiles %}
     + {% filter json_encode(constant('JSON_UNESCAPED_SLASHES'))|raw -%}{% include 'embed-part-file.htm' %}{%- endfilter %}
 {% endfor %}
index 4d5c05022d78a4408c7b50ae42ec778af309ffd5..11839a949186ab03cfa8c35e52e15e3750ff5c01 100644 (file)
@@ -10,7 +10,7 @@
 .phork-content {
     padding: 0.6ex;
 }
 .phork-content {
     padding: 0.6ex;
 }
-.phork-file > .code {
+.phork-content > .code {
     overflow-x: auto;
 }
 .phork-file .code pre {
     overflow-x: auto;
 }
 .phork-file .code pre {