mirror of
https://gitnet.fr/deblan/gist.git
synced 2021-08-14 08:30:49 +02:00
Embed block moved
This commit is contained in:
parent
21a85c0db4
commit
1a79e4520f
@ -37,7 +37,7 @@ gist:
|
|||||||
raw: '源文件'
|
raw: '源文件'
|
||||||
download: '下载'
|
download: '下载'
|
||||||
clone: '克隆'
|
clone: '克隆'
|
||||||
embed: '引用:'
|
embed: '引用'
|
||||||
add: '新建'
|
add: '新建'
|
||||||
|
|
||||||
date:
|
date:
|
||||||
|
@ -37,7 +37,7 @@ gist:
|
|||||||
raw: 'RAW'
|
raw: 'RAW'
|
||||||
download: 'Herunterladen'
|
download: 'Herunterladen'
|
||||||
clone: 'Klonen'
|
clone: 'Klonen'
|
||||||
embed: 'Einfügen:'
|
embed: 'Einfügen'
|
||||||
add: 'Hinzufügen'
|
add: 'Hinzufügen'
|
||||||
|
|
||||||
date:
|
date:
|
||||||
|
@ -38,7 +38,7 @@ gist:
|
|||||||
raw: 'RAW'
|
raw: 'RAW'
|
||||||
download: 'Download'
|
download: 'Download'
|
||||||
clone: 'Clone'
|
clone: 'Clone'
|
||||||
embed: 'Embed:'
|
embed: 'Embed'
|
||||||
add: 'New'
|
add: 'New'
|
||||||
|
|
||||||
date:
|
date:
|
||||||
|
@ -37,7 +37,7 @@ gist:
|
|||||||
raw: 'RAW'
|
raw: 'RAW'
|
||||||
download: 'Descargar'
|
download: 'Descargar'
|
||||||
clone: 'Clonar'
|
clone: 'Clonar'
|
||||||
embed: 'Insertar : '
|
embed: 'Insertar'
|
||||||
add: 'Añadir'
|
add: 'Añadir'
|
||||||
|
|
||||||
date:
|
date:
|
||||||
|
@ -37,7 +37,7 @@ gist:
|
|||||||
raw: 'RAW'
|
raw: 'RAW'
|
||||||
download: 'Télécharger'
|
download: 'Télécharger'
|
||||||
clone: 'Clôner'
|
clone: 'Clôner'
|
||||||
embed: 'Insérer : '
|
embed: 'Insérer'
|
||||||
add: 'Ajouter'
|
add: 'Ajouter'
|
||||||
|
|
||||||
date:
|
date:
|
||||||
|
@ -12,10 +12,6 @@
|
|||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
||||||
<style type="text/css">
|
<style type="text/css">
|
||||||
#embed {
|
|
||||||
padding: 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
.panel-body {
|
.panel-body {
|
||||||
padding: 0;
|
padding: 0;
|
||||||
}
|
}
|
||||||
|
@ -64,11 +64,19 @@
|
|||||||
<div id="viewer">
|
<div id="viewer">
|
||||||
<pre><code {% if gist.cipher %}data-cipher{% endif %} class="language-{{ gist.type }}" data-dependencies="{{ gist.type }}">{{ raw_content }}</code></pre>
|
<pre><code {% if gist.cipher %}data-cipher{% endif %} class="language-{{ gist.type }}" data-dependencies="{{ gist.type }}">{{ raw_content }}</code></pre>
|
||||||
</div>
|
</div>
|
||||||
|
</div>
|
||||||
<p id="embed" class="pull-right">
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="panel panel-default">
|
||||||
|
<div class="panel-heading">
|
||||||
{{ 'gist.action.embed'|trans }}
|
{{ 'gist.action.embed'|trans }}
|
||||||
<input type="text" class="form-control" id="embed-input" value="{{ '<div%key%id="gist-' ~ gist.file ~ '-' ~ commit ~ '" class="gist-container"></div><script src="' ~ app.request.getSchemeAndHttpHost() ~ path('embedjs', app.request.attributes.get('_route_params')) ~ '" async></script>' }}" />
|
</div>
|
||||||
</p>
|
<div class="panel-body" id="embed">
|
||||||
|
<div class="tab-content">
|
||||||
|
<div class="tab-pane active in">
|
||||||
|
<pre><code class="language-html">{{ '<div%key%id="gist-' ~ gist.file ~ '-' ~ commit ~ '" class="gist-container"></div>
|
||||||
|
<script src="' ~ app.request.getSchemeAndHttpHost() ~ path('embedjs', app.request.attributes.get('_route_params')) ~ '" async></script>' }}</code></pre>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
@ -26,7 +26,7 @@ body {
|
|||||||
margin-right: 4px;
|
margin-right: 4px;
|
||||||
}
|
}
|
||||||
|
|
||||||
#viewer pre, #viewer code, #revisions pre, #revisions code {
|
#viewer pre, #viewer code, #revisions pre, #revisions code, #embed pre, #embed code {
|
||||||
background: none !important;
|
background: none !important;
|
||||||
white-space: pre-wrap;
|
white-space: pre-wrap;
|
||||||
white-space: -moz-pre-wrap;
|
white-space: -moz-pre-wrap;
|
||||||
|
@ -144,7 +144,7 @@ var viewerEvents = function() {
|
|||||||
var key = getKey();
|
var key = getKey();
|
||||||
|
|
||||||
var $cipherEditor = $('.cipher-editor');
|
var $cipherEditor = $('.cipher-editor');
|
||||||
var $embedInput = $('#embed-input');
|
var $embedCode = $('#embed code');
|
||||||
|
|
||||||
var to = ' ';
|
var to = ' ';
|
||||||
|
|
||||||
@ -177,8 +177,8 @@ var viewerEvents = function() {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if ($embedInput.length) {
|
if ($embedCode.length) {
|
||||||
$embedInput.val($embedInput.val().replace('%key%', to));
|
$embedCode.html($embedCode.html().replace('%key%', to));
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user