1 {% extends "base.html" %}
2 {% load url from future %}
9 <link rel="stylesheet" type="text/css" media="all" href="{{ STATIC_URL }}css/note_course_pages.css">
12 {% block pagescripts %}
13 <script type="text/javascript">
14 var note_thank_url = "{% url 'thank_note' note.id %}"
15 var note_flag_url = "{% url 'flag_note' note.id %}"
16 var csrf_token = "{{ csrf_token }}";
18 <script src="{{ STATIC_URL }}js/setup-ajax.js"></script>
19 <script src="{{ STATIC_URL }}js/note-detail.js" ></script>
20 <script src="{{ STATIC_URL }}js/pxem.jQuery.js"></script>
24 <section id="note_content">
26 <div id="note_header" class="hero_gradient_bar">
28 <div class="twelve columns header_subhead">
29 <a href="{{note.course.get_absolute_url}}">
30 <i class="fa fa-arrow-left"></i> back to {{ note.course.name }}
36 <div class="small-12 columns header_title">
38 </div><!-- /note_name -->
42 <div id="note_status" class="twelve columns">
43 <div class="activity_details_status">
44 So far, <span id="thank-number" class="activity_details_status_number">{{ note.thanks }}</span> people have completely fallen in love with with these notes.
45 </div><!-- /activity_details_status -->
46 </div><!-- /note_status -->
50 <div id="note_actions" class="large-3 medium-6 small-12 columns small-centered">
52 <div class="small-4 column">
53 <a href="#" id="flag-button" {% if already_flagged %} class="hide" {% endif %}><img src="{{ STATIC_URL }}img/note_flag.png" alt="note_flag" width="25" height="35"/></a>
54 <a href="#" id="flag-button-disabled" {% if not already_flagged %} class="hide" {% endif %}><img src="{{ STATIC_URL }}img/note_flag_disabled.png" alt="note_flag" width="25" height="35"/></a>
56 <div class="small-4 column">
57 <a href="#" id="thank-button" {% if already_thanked %} class="hide" {% endif %}><img src="{{ STATIC_URL }}img/note_thank.png" alt="note_thank" width="34" height="34"/></a>
58 <a href="#" id="thank-button-disabled" {% if not already_thanked %} class="hide" {% endif %}><img src="{{ STATIC_URL }}img/note_thank_disabled.png" alt="note_thank" width="34" height="34"/></a>
60 <div class="small-4 column">
61 <a href="{{ note.fp_file }}">
62 <img src="{{ STATIC_URL }}img/note_download.png" alt="note_download" width="51" height="36" />
66 </div><!-- /note_actions -->
71 <div id="note_pedigree" class="twelve columns activity_details_status">
72 {{ note.license.html|safe }} {% if note.upstream_link %}<a href="{{note.upstream_link}}" target="_blank">{{ note.upstream_link|slice:":80" }}</a>{% endif %}
73 </div><!-- /note_pedigree -->
77 </div><!-- /course_header -->
80 <div id="zoom-buttons" class="row show-for-medium-up">
81 <div id="outline-btn-wrapper" class="small-1 columns hide show-for-medium-up">
82 <i id="outline-btn" class="zoom-button fa fa-bars fa-2x"></i>
84 <div class="small-4 columns">
86 <input id="scroll-to" type="text" style="width: 3em; display: inline" /></span>
88 <div class="small-2 small-centered columns center">
89 <i id="minus-btn" class="zoom-button fa fa-search-minus fa-2x"></i>
90 <i id="plus-btn" class="zoom-button fa fa-search-plus fa-2x"></i>
96 <div id="note_container">
100 <div class="small-12 columns">
102 style="border:none; width:100%; min-height: 700px; margins: auto;"
104 src="/pdfview/{{ note.id }}"
105 onload="autoResize('noteframe')"> </iframe>
110 # TODO: embed and pass the url with this included when we fix the css integration issues
111 {% include 'partial/pdfembed.html' %}
114 {% else %} {# if pdf #}
117 <div class="small-12 small-centered columns medium-12 large-12 body_copy">
119 <div class="note-text">
120 <iframe style="border:none; width:100%; min-height: 1000px;" id="noteframe" src="/raw/{{ note.id }}"
121 onload="autoResize('noteframe'); {% if pdf_controls %} setupPdfViewer(); {% endif %}"> </iframe>
122 </div> <!-- .note-text -->
124 {% else %} {# note.html #}
125 <div class="note-error">
126 This document's content is currently unavailable. Please try again later.
128 {% endif %} {# note.html #}
130 {% endif %} {# note.filetype == 'pdf' #}
132 </div><!-- /body_copy -->
135 </div><!-- /note_container -->
138 </section><!--/note_content-->