mirror of
https://github.com/Hopiu/wagtail.git
synced 2026-05-10 16:24:49 +00:00
old reference to edit bird removed. wagtail set to use offline js libs to avoid internet outage issues for local/intranet builds. Tweaks to way userbar is added to page to ensure resulting html is still valid
This commit is contained in:
parent
e29b52f35e
commit
83a5455251
7 changed files with 30 additions and 19 deletions
|
|
@ -17,7 +17,7 @@ nav{
|
|||
float:right;
|
||||
|
||||
/* moving menu only for browser that can support hover and transitions */
|
||||
.no-touch.csstransitions & {
|
||||
.no-touch & {
|
||||
ul{
|
||||
height:0;
|
||||
}
|
||||
|
|
@ -114,7 +114,7 @@ div.action{
|
|||
display:block;
|
||||
text-transform:uppercase;
|
||||
padding:1em;
|
||||
width:100%;
|
||||
width:10em;
|
||||
position:relative;
|
||||
z-index:1;
|
||||
text-align:left;
|
||||
|
|
|
|||
|
|
@ -0,0 +1,10 @@
|
|||
#wagtail-userbar{
|
||||
background:transparent;
|
||||
position:fixed;
|
||||
top:0;
|
||||
right:0;
|
||||
z-index:9000;
|
||||
border:0;
|
||||
width:150px;
|
||||
height:300px;
|
||||
}
|
||||
|
|
@ -12,12 +12,12 @@
|
|||
{% endblock %}
|
||||
|
||||
{% block js %}
|
||||
<script src="//ajax.googleapis.com/ajax/libs/jquery/1.10.1/jquery.min.js"></script>
|
||||
|
||||
{% compress js %}
|
||||
{% comment %}
|
||||
Core JS includes (for inclusion on all pages) to be specified here
|
||||
{% endcomment %}
|
||||
|
||||
<script src="{{ STATIC_URL }}wagtailadmin/js/vendor/jquery-1.10.3.js"></script>
|
||||
<script src="{{ STATIC_URL }}wagtailadmin/js/vendor/jquery-ui-1.10.3.js"></script>
|
||||
<script src="{{ STATIC_URL }}wagtailadmin/js/vendor/jquery.timepicker.min.js"></script>
|
||||
<script src="{{ STATIC_URL }}wagtailadmin/js/vendor/jquery.autosize.js"></script>
|
||||
|
|
|
|||
|
|
@ -11,7 +11,7 @@
|
|||
<meta name="description" content="" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
||||
|
||||
<script src="//cdnjs.cloudflare.com/ajax/libs/modernizr/2.6.2/modernizr.min.js"></script>
|
||||
<script src="{{ STATIC_URL }}wagtailadmin/js/vendor/modernizr-2.6.2.min.js"></script>
|
||||
|
||||
<link rel="stylesheet" href="//fonts.googleapis.com/css?family=Open+Sans:300,400,600,700" />
|
||||
<link rel="stylesheet" href="//fonts.googleapis.com/css?family=Bitter:400,700" />
|
||||
|
|
|
|||
|
|
@ -23,6 +23,6 @@
|
|||
|
||||
{% block js %}
|
||||
{% compress js %}
|
||||
<script src="{{ STATIC_URL }}wagtailadmin/js/edit_bird.js"></script>
|
||||
<script src="{{ STATIC_URL }}wagtailadmin/js/userbar.js"></script>
|
||||
{% endcompress %}
|
||||
{% endblock %}
|
||||
|
|
@ -1,13 +1,14 @@
|
|||
<style type="text/css">
|
||||
#wagtail-userbar{
|
||||
background:transparent;
|
||||
position:absolute;
|
||||
top:0;
|
||||
right:0;
|
||||
z-index:9000;
|
||||
border:0;
|
||||
width:150px;
|
||||
height:300px;
|
||||
}
|
||||
</style>
|
||||
<iframe id="wagtail-userbar" src="{% if revision_id %}{% url 'wagtailadmin_userbar_moderation' revision_id %}{% else %}{% url 'wagtailadmin_userbar_frontend' page.self.id %}{% endif %}" width="1000px" height="1000px" frameborder="0" allowtransparency="true" scrolling="no"></iframe>
|
||||
{% load static %}
|
||||
<!-- Wagtail user bar embed code -->
|
||||
<script type="text/javascript">
|
||||
(function(w,d){
|
||||
var l, f, h;
|
||||
l = d.createElement('link'); l.rel = 'stylesheet';
|
||||
l.href = '{% static "wagtailadmin/scss/userbar_embed.css" %}';
|
||||
f = d.createElement('iframe'); f.id = 'wagtail-userbar'; f.frameborder = '0'; f.allowtransparency = 'true'; f.scrolling = 'no';
|
||||
f.src = '{% if revision_id %}{% url "wagtailadmin_userbar_moderation" revision_id %}{% else %}{% url "wagtailadmin_userbar_frontend" page.self.id %}{% endif %}';
|
||||
t = d.getElementsByTagName('title')[0]; t.parentNode.insertBefore(l, t.nextSibling);
|
||||
d.body.appendChild(f);
|
||||
}(window,document));
|
||||
</script>
|
||||
<!-- end Wagtail user bar embed code -->
|
||||
Loading…
Reference in a new issue