diff options
Diffstat (limited to 'design/templates/notes/notes_detail.html')
-rw-r--r-- | design/templates/notes/notes_detail.html | 34 |
1 files changed, 16 insertions, 18 deletions
diff --git a/design/templates/notes/notes_detail.html b/design/templates/notes/notes_detail.html index b2ddbc3..26bff03 100644 --- a/design/templates/notes/notes_detail.html +++ b/design/templates/notes/notes_detail.html @@ -2,16 +2,18 @@ {% block extrastyles %} <link rel="stylesheet" href="/media/quill.snow.css" /> {% endblock %} +{% block bodyclass %}note-detail{% endblock %} {% block content %} <main> <article class="note-container"> <form action="" method="post" id="note-edit-form">{% csrf_token %} <header class="note-header"> <div class="note-header-left"> - <div class="flex-wrapper"> <div class="notebook"> - <a id="n-link" href="{% url 'notebooks:detail' object.slug %}"><span id="n-box" class="color-box" style="background-color: {{object.notebook.color_rgb}}"></span><span id="n-name">{{object.notebook}}</span></a> + {% if object.notebook %}<a id="n-link" href="{{object.notebook.get_absolute_url}}"><span id="n-box" class="color-box" style="background-color: {{object.notebook.color_rgb}}"></span><span id="n-name">{{object.notebook}}</span></a> + {%else %}<span id="n-link" href="{{object.notebook.get_absolute_url}}"><span id="n-box" class="color-box" style="background-color: {{object.notebook.color_rgb}}"></span><span id="n-name">{{object.notebook}}</span></span> + {%endif%} <div id="notebook-edit" class="hide"> <span class="error">{{ form.notebook.errors }}</span> {{form.notebook}} @@ -24,7 +26,7 @@ <span class="tag-wrapper" data-bg-color="#{{tag.color_color_rgb}};" >{{tag}}</span> </a>{%endfor%} </div> - <div id="tags-edit" class="hide"> + <div id="t-edit" class="hide"> <span class="error">{{ form.notebook.errors }}</span> {{form.tags}} </div> @@ -40,12 +42,16 @@ </div> </header> <div class="edit-btn-wrapper"><button class="hide btn btn-hollow" id="edit-toggle-btn">Edit</button></div> + <fieldset id="fs-url" class="url-field hide"> + {{form.url.label_tag}} + {{form.url}} + </fieldset> <h1 id="note-title" class="note-title">{{object.title}}</h1> <div id="q-container" class="inactive"><div id="note-body">{% if object.body_html %}{{object.body_html|safe}}{%else%}{{object.body_text}}{%endif%}</div></div> <input id="btn-js-hide" type="submit" class="btn sm" value="Save" > </form> </article> - <aside class="note-list-container"> + <!--<aside class="note-list-container"> <div class="svg-wrapper"><svg class="svg-icon-arrow"> <svg viewBox="0 0 16 13" id="shape-double-arrow" width="100%" height="100%"><g stroke="none" stroke-width="1" fill="none" fill-rule="evenodd" stroke-linecap="square"><g id="Showing-post-info" transform="translate(-297.000000, -105.000000)" stroke="currentColor"><g transform="translate(305.000000, 111.500000) scale(-1, 1) rotate(-180.000000) translate(-305.000000, -111.500000) translate(297.000000, 105.000000)"><path d="M2.20710678,6.5 L6.85355339,1.85355339 L7.20710678,1.5 L6.5,0.792893219 L6.14644661,1.14644661 L1.14644661,6.14644661 L1.05805826,6.23483496 L0.792893219,6.5 L1.14644661,6.85355339 L6.14644661,11.8535534 L6.5,12.2071068 L7.20710678,11.5 L6.85355339,11.1464466 L2.20710678,6.5 Z" id="Combined-Shape"></path><path d="M10.2071068,6.5 L14.8535534,1.85355339 L15.2071068,1.5 L14.5,0.792893219 L14.1464466,1.14644661 L9.14644661,6.14644661 L9.05805826,6.23483496 L8.79289322,6.5 L9.14644661,6.85355339 L14.1464466,11.8535534 L14.5,12.2071068 L15.2071068,11.5 L14.8535534,11.1464466 L10.2071068,6.5 Z" id="Combined-Shape"></path></g></g></g></svg> </svg></div> @@ -59,26 +65,18 @@ </li> {% endfor %}</ul> </div> - </aside> - <div class="balance-container"> - </div> + </aside>--> </main> +<div class="overlay-content hide" id="js-overlay-notebook"> + {% include 'notes/partials/notebook_form.html' with form=notebook_form %} +</div> {% endblock %} {% block jsinclude %} +<script async src="/media/js/vanilla-picker.min.js"></script> <script src="/media/js/highlight.pack.js"></script> <script src="/media/js/quill.min.js"></script> -<script> -document.addEventListener('readystatechange', event => { - if (event.target.readyState === "interactive") { - //initLoader(); - } - else if (event.target.readyState === "complete") { - initQuill("#note-body"); - } -}); -</script> {% endblock %} {% block jsdomready %} -window.url = "{% url 'notes-api-detail' object.pk %}"; + {%endblock%} |