laterite-web 0.9.16

Laterite CMF public web layer: themes, static-site generation, page metadata, canonical URLs, and sitemaps
Documentation
{% if locked %}<div class="lat-alert">{{ shell.t("This theme is locked: its config and templates cannot change until it is unlocked.") }}</div>{% endif %}
<div class="lat-split">
  {% include "_theme_nav.html" %}
  <div>
    <form class="lat-pane" method="post" action="{{ template_url }}/save">
      <div class="lat-pane__head">{{ shell.t("Markup") }}<span class="lat-code">{{ path }}</span></div>
      <div class="lat-pane__body">
        <input type="hidden" name="_csrf" value="{{ shell.csrf_token() }}">
        <textarea class="lat-input lat-editor" id="markup" name="markup" rows="26" spellcheck="false" aria-label='{{ shell.t("Markup") }}'{% if locked %} readonly{% endif %}>{{ markup }}</textarea>
      </div>
      {% if let Some(fields) = page_fields %}
      <div class="lat-pane__head">{{ shell.t("Page") }}</div>
      <div class="lat-pane__body">{{ fields|safe }}</div>
      {% else %}
      <div class="lat-pane__head">{{ shell.t("Settings") }}</div>
      <div class="lat-pane__body">
        <textarea class="lat-input lat-editor" id="settings" name="settings" rows="6" spellcheck="false" aria-label='{{ shell.t("Settings") }}'{% if locked %} readonly{% endif %}>{{ settings }}</textarea>
        <p class="lat-field__help" style="margin:8px 0 0">{{ shell.t("A JSON object, such as a layout's description.") }}</p>
      </div>
      {% endif %}
      {% if !locked %}
      <div class="lat-pane__foot">
        <a class="lat-btn lat-btn--ghost" href="{{ theme_url }}">{{ shell.t("Cancel") }}</a>
        <button class="lat-btn lat-btn--primary" type="submit">{{ shell.t("Save") }}</button>
      </div>
      {% endif %}
    </form>
    <div class="lat-pane">
      <div class="lat-pane__head">{{ shell.t("Revisions") }}</div>
      {% if revisions.is_empty() %}
      <div class="lat-nav__empty" style="padding:14px 16px">{{ shell.t("No earlier versions.") }}</div>
      {% else %}
      <table class="lat-table">
        <thead><tr><th>{{ shell.t("Saved") }}</th><th>{{ shell.t("By") }}</th><th></th></tr></thead>
        <tbody>
          {% for r in revisions %}
          <tr>
            <td>{{ r.saved_at }}</td>
            <td>{{ r.saved_by }}</td>
            <td class="lat-table__actions">
              {% if !locked %}
              <form method="post" action="{{ template_url }}/restore"><input type="hidden" name="_csrf" value="{{ shell.csrf_token() }}"><input type="hidden" name="revision" value="{{ r.id }}"><button class="lat-btn lat-btn--secondary lat-btn--sm" type="submit">{{ shell.t("Restore") }}</button></form>
              {% endif %}
            </td>
          </tr>
          {% endfor %}
        </tbody>
      </table>
      {% endif %}
    </div>
  </div>
</div>
{% include "_theme_dialogs.html" %}