1
0
mirror of https://gitnet.fr/deblan/gist.git synced 2021-08-14 08:30:49 +02:00

embed code and commit link

This commit is contained in:
Simon Vieille 2015-05-25 02:38:51 +02:00
parent aa671216ce
commit bc801e7a71
2 changed files with 6 additions and 4 deletions

View File

@ -50,9 +50,11 @@
<div class="panel-heading"> <div class="panel-heading">
{% if not gist.cipher %} {% if not gist.cipher %}
<div class="pull-right actions"> <div class="pull-right actions">
<a target="_blank" href="{{ path('view', app.request.attributes.get('_route_params')) }}" class="btn btn-default btn-sm">
<span class="btn btn-warning btn-xs"> <span class="btn btn-warning btn-xs">
{{ commit|slice(0, 10) }} {{ commit|slice(0, 10) }}
</span> </span>
</a>
<a target="_blank" href="{{ path('raw', app.request.attributes.get('_route_params')) }}" class="btn btn-default btn-sm"> <a target="_blank" href="{{ path('raw', app.request.attributes.get('_route_params')) }}" class="btn btn-default btn-sm">
<span class="glyphicon glyphicon-eye-open"></span> <span class="glyphicon glyphicon-eye-open"></span>

View File

@ -70,7 +70,7 @@
<p id="embed" class="pull-right"> <p id="embed" class="pull-right">
{{ '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')) ~ '"></script>' }}" /> <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>' }}" />
</p> </p>
</div> </div>
</div> </div>