75cf617e62629863b08df771496d0595bf22a878
[redakcja.git] / apps / wiki / templates / wiki / document_details.html
1 {% extends "base.html" %}
2 {% load toolbar_tags %}
3 {% block title %}{{ document.name }} - {{ block.super }}{% endblock %}
4 {% block extrahead %}
5 {% load compressed %}
6 {% compressed_css 'detail' %}
7 {% endblock %}
8 {% block extrabody %}
9 <script type="text/javascript" charset="utf-8">
10     var STATIC_URL = '{{STATIC_URL}}';
11 </script>
12 <script src="{{STATIC_URL}}js/lib/codemirror/codemirror.js" type="text/javascript" charset="utf-8">
13 </script>
14 {% compressed_js 'detail' %}
15 {% endblock %}
16 {% block maincontent %}
17 <div id="loading-overlay">
18     <div id="loading-message">
19         <img src="{{STATIC_URL}}img/spinner.gif" />
20         <p>
21             Ładowanie
22         </p>
23     </div>
24 </div>
25
26 <div id="document-meta" data-document-name="{{ document.name }}" style="display:none">
27 {% for k, v in document.meta.items %}
28         <span data-key="{{ k }}">{{ v }}</span>
29 {% endfor %}
30 </div>
31
32 <div id="header">
33     <h1><a href="{% url wiki.views.document_list %}">Platforma</a></h1>
34     <div id="tools">
35         <a href="{{ REDMINE_URL }}projects/wl-publikacje/wiki/Pomoc" target="_blank">Pomoc</a>
36         | {% include "registration/head_login.html" %} 
37         | Wersja: <span id="document-revision">{{ document.revision }}</span>
38         | 
39         <button style="margin-left: 6px" id="save-button">
40             Zapisz
41         </button>
42     </div>
43     <ol id="tabs">
44         <li id="HistoryPerspective-tab" 
45                         data-ui-related="history-viewer" 
46                         data-ui-jsclass="HistoryPerspective">           
47             Historia
48         </li>
49                 
50         <li id="VisualPerspective-tab" 
51                         data-ui-related="simple-editor" data-ui-jsclass="VisualPerspective">
52             <span id="document-name">{{ document.name }}</span>
53         </li>
54                         
55                 <li id="CodeMirrorPerspective-tab" 
56                         data-ui-related="source-editor" data-ui-jsclass="CodeMirrorPerspective">
57             Kod źródłowy
58         </li>
59     </ol>
60 </div>
61 <div id="splitter">
62     <div id="editor">
63         <div id="source-editor" class="editor">
64             {% toolbar %}
65             <textarea id="codemirror_placeholder">&lt;br/&gt;</textarea>
66             <input type="hidden" name="name" value="{{ document.name }}" /><input type="hidden" name="author" value="annonymous" /><input type="hidden" name="comment" value="no comment" /><input type="hidden" name="revision" value="{{ document.revision }}" />
67         </div>
68         <div id="simple-editor" class="editor" style="display: none">
69             <div id="html-view" class="htmlview">
70             </div>
71             <div class="toolbar">
72                 <button id="insert-theme-button">
73                     Wstaw motyw
74                 </button>
75                 <button id="insert-annotation-button">
76                     Wstaw przypis
77                 </button>
78                 <div class="toolbar-end">
79                 </div>
80             </div>
81         </div>
82                 {% include "wiki/history_panel.html" %}
83     </div>
84     <div class="vsplitbar" title="Klinknij aby (ro)zwinąć galerię."> </div>
85     <div id="sidebar">
86         <div class="toolbar">
87             <button class="previous-page">
88                 <img src="{{STATIC_URL}}icons/go-previous.png" alt="Poprzednia" title="Poprzednia"/>
89             </button><input type="text" size="3" maxlength="3" value="1" class="page-number" />
90             <button class="next-page">
91                 <img src="{{STATIC_URL}}icons/go-next.png" alt="Następna" title="Następna"/>
92             </button>
93             <button class="zoom-in">
94                 Powiększ
95             </button>
96             <button class="zoom-out">
97                 Pomniejsz
98             </button>
99             {% if request.user.is_staff %}
100             <button class="change-gallery">
101                 Opcje
102             </button>
103             {% endif %}
104             <div class="toolbar-end">
105             </div>
106         </div>
107         {% if request.user.is_staff %}
108         <div class="toolbar" id="change-gallery-toolbar">
109             <input type="text" value="" class="chosen-gallery" />
110             <button class="change-gallery-ok">
111                 Zmień galerię
112             </button>
113             <button class="change-gallery-cancel">
114                 Anuluj
115             </button>
116             <div class="toolbar-end">
117             </div>
118         </div>
119         {% endif %}
120         <div class="gallery-image"><img src="" /></div>
121     </div>
122 </div>
123 <div id="save-dialog" style="display: none; text-align: left">
124     <label for="komentarz" style="display: block">
125         Opis zmian:
126     </label>
127     <textarea name="komentarz" id="komentarz" style="display: block; width: 100%">
128     </textarea>
129     <button id="save-ok">
130         Zapisz
131     </button>
132     <button id="save-cancel">
133         Anuluj
134     </button>
135 </div>
136 {% endblock %}