Browse Source

created branch xpplannot

ansible-setup-and-deploy
ange 6 years ago
parent
commit
f210ef42ea
  1. 8
      app/static/css/style.css
  2. 42
      app/templates/annotations.html
  3. 4
      app/templates/show_book_detail.html
  4. 4
      app/views.py

8
app/static/css/style.css

@ -196,6 +196,14 @@ font-size: 12px;
background-color: yellow;
}
#annotindication{
width: 30%;
margin: 0;
padding: 3px;
font-size: 14px;
background-color: red;
}
div.marquee {
white-space:no-wrap;
overflow:hidden;

42
app/templates/annotations.html

@ -0,0 +1,42 @@
{% block main %}
<h1 class="header">Annotations</h1>
<script src="https://hypothes.is/embed.js" async></script>
<iframe src="https://jonudell.info/h/facet/" style="width:100%;height:100px;"></iframe>
<!-- <iframe src="http://localhost:8080/app/uploads/viewer/web/viewer.html?file=%2Ftheresa.pdf"> -->
<script src="https://gist.github.com/mjlavin80/186a6395c5819dbe25a8a0e001d5acfd.js"></script>
<!-- <filename> -->
<!-- <embed type="PdfFileReader" src="http://localhost:8000/uploads/viewer.html?file=<filename>" width="300" height="300"> -->
{% endblock %}
<!-- <script type="application/json" class="js-hypothesis-config">
{
"showHighlights": "always",
"theme": "classic",
"branding": {"appBackgroundColor": "red"},
"onLayoutChange": {"width": 70},
"sidebarAppUrl": "https://hypothes.is/app.html"
}
</script>
<script async src="https://hypothes.is/embed.js"></script> -->
<!-- style="width:100%; height:500px;" -->
<!-- iframe {
#controlsContainer{ display:none; };
#title { display:none; };
width:100%;
height:500px;
} -->

4
app/templates/show_book_detail.html

@ -20,6 +20,10 @@
{% endfor %}</ul></p>
<a href="../uploads/{{ book.file }}">download {{ book.fileformat }}</a>
<link rel="stylesheet" href="/static/css/style.css">
<div id="annotindication">
--> Feel free to annotate</div>
<br>
<br>
<a href="{{ url_for('edit_book_by_id', id=book.id )}}">edit</a>

4
app/views.py

@ -338,6 +338,10 @@ def send_text_file(file_name):
file_dot_text = file_name + '.txt'
return app.send_static_file(file_dot_text)
@app.route('/annotations')
def annotations():
"""Render annotations page."""
return render_template('annotations.html')
@app.after_request
def add_header(response):

Loading…
Cancel
Save