<% #create %>
<h1><% response.title %></h1>
<div>
   <% gettext "To create a new site you need to fill out the form below." %>
</div>
<small>
   <p>
      <% gettext 'The name will be part of the URL of your site. E.g. if you enter “{0}” as the name your site will be reachable via this url: {1}' <% example.name %> <% example.href prefix="<pre><code>" suffix=</code></pre> %> %>
   </p>
   <p>
      <% gettext "Please note that you cannot change the name after the site was created." %> <% gettext "The title will appear in the header of every page of your site. You can change it anytime you want." %>
   </p>
</small>
<form class='uk-form uk-form-stacked' method="post" action="<% response.action %>">
   <div class='uk-form-row'>
      <label class='uk-form-label' for='name'>
         <% gettext Name %>
      </label>
      <div class='uk-form-controls'>
         <% newSite.input name class=uk-form-width-medium %>
      </div>
   </div>
   <div class='uk-form-row'>
      <label class='uk-form-label' for='title'>
         <% gettext Title %>
      </label>
      <div class='uk-form-controls'>
         <% newSite.input title class=uk-form-width-large %>
      </div>
   </div>
   <div class='uk-form-row'>
      <button class='uk-button uk-button-primary' type="submit" id="submit" name="create" value="1">
         <% gettext Create %>
      </button>
      <a href="" class="uk-button uk-button-link cancel"><% gettext Cancel %></a>
   </div>
</form>

<% #sites %>
<h1><% response.title %></h1>
<p><% gettext "This is the directory of public sites hosted here, in alphabetical order." %></p>
<% response.pager %>
<table class='uk-table uk-table-striped uk-table-hover uk-table-condensed'>
   <thead>
      <tr>
         <td><% gettext Title %></td>
         <td><% gettext 'Last Update' %></td>
      </tr>
   </thead>
   <tbody>
      <% response.list %>
   </tbody>
</table>
<% response.pager %>

<% #notfound %>
<p class="storyTitle"><% gettext Sorry! %></p>
<p><% gettext "The path you requested was not found:"  %></p>
<% param.path encoding="all" prefix=<code>/ suffix=</code> %>

<% #error %>
<p class="storyTitle"><% gettext Sorry! %></p>
<p><% gettext "An error occurred while processing your request:" %></p>
<% session.error default=<% param.error %> %>

<% #health %>
<h1><% response.title %></h1>
<div class='uk-panel uk-panel-header'>
   <h3 class='uk-panel-title'><% gettext Status %></h3>
   <% site.skin Root#status %>
</div>
<div class='uk-panel uk-panel-header'>
   <h3 class='uk-panel-title'><% gettext Details %></h3>
   <dl class='uk-description-list-horizontal'>
      <dt><% gettext Sessions %></dt>
      <dd><% param.sessions %></dd>
      <dt><% gettext Uptime %></dt>
      <dd><% ngettext '{0} day' '{0} days' <% param.uptime %> %></dd>
      <dt><% gettext Threads %></dt>
      <dd>
         <% gettext '{0} active' <% param.activeThreads %> %>,
         <% gettext '{0} free' <% param.freeThreads %> %>
      </dd>
      <dt><% gettext Requests %></dt>
      <dd>
         <% gettext '{0} total' <% param.requestCount %> %>,
         <% gettext '{0} last 5 min.' <% param.requestsPerUnit default=n.a. %> %>
      </dd>
      <dt><% gettext 'Errors' %></dt>
      <dd>
         <% gettext '{0} total' <% param.errorCount %> %>,
         <% gettext '{0} last 5 min.' <% param.errorsPerUnit default=n.a. %> %>
      </dd>
      <dt><% gettext 'Error Ratio' %></dt>
      <dd>
         <% gettext '{0}% total' <% param.errorRatio %> %>,
         <% gettext '{0}% last 5 min.' <% param.errorRatioPerUnit %> %>
      </dd>
      <dt><% gettext 'Xml-Rpc Count' %></dt>
      <dd><% ngettext '{0} request' '{0} requests' <% param.xmlrpcCount %> %></dd>
      <dt><% gettext 'Cache' %></dt>
      <dd><% gettext '{0} of {1} objects' <% param.cacheusage %> <% param.cacheSize %> %></dd>
      <dt><% gettext 'Memory' %></dt>
      <dd>
         <% gettext '{0} MB total'  <% param.totalMemory %> %>,
         <% gettext '{0} MB free' <% param.freeMemory %> %>
      </dd>
      <dt><% gettext 'Queue' %></dt>
      <dd>
         <% ngettext '{0} request' '{0} requests' <% param.requests %> %>,
         <% ngettext '{0} mail' '{0} mails' <% param.mails %> %>,
         <% ngettext '{0} callback' '{0} callbacks' <% param.callbacks %> %>,
      </dd>
      <dd></dd>
      <dd><% gettext '{0} log entries' <% param.entries %> %></dd>
      <dt><% gettext Version %></dt>
      <dd><% version %></dd>
      <dt><% gettext Build %></dt>
      <dd>
         <% link <% version hash prefix='https://code.google.com/p/antville/source/browse/?r=' %> <% version hash %> %> (<% version date | format date medium %>)
      </dd>
   </dl>
</div>

<% #stylesheet %>
/* CSS for protected skins (user interface elements etc.) */

ul { list-style: url(<% image /bullet.gif url %>) circle; }

ul.skinmgrTree {
   padding-left:15px;
   margin:20px 0px;
}

ul.skinmgrTree ul {
   padding-left:30px;
   margin:0px;
}

ul.skinmgrTree li {
   list-style:none;
   margin:7px 0px;
   padding:0px;
}

ul.skinmgrTree li.skinset {
   list-style:square;
   padding-left:0px;
}

ul.skinmgrTree a.selected {
   font-weight:bold;
}

ul.skinmgrTree li div {
   font-family:<% value "small font" %>;
   font-size:<% value "small font size" %>;
   color:<% value "base font color" %>;
}

div.skin {
   /*margin: 1px;
   border: 1px solid gray;*/
}

div.skin div.title {
   display: none;
   padding: 2px;
   color: gray;
   font: normal 8px verdana, sans-serif;
}

#prefs select {
   width: 200px;
}

.nowrap {
   white-space: nowrap;
}

.translated {
   font-weight: bold;
}

.pageTitle {
   font-family:<% value "big font" %>;
   font-size:<% value "big font size" %>;
   font-weight:bold;
   color:<% value "big font color" %>;
   padding-bottom:10pt;
}

.listItemSeparator {
   margin-top:15px;
   border-top:1px solid #dddddd;
}

.listItemFlag {
   padding: 1px;
   color: white;
   background-color: #cccccc;
   border: 1px solid white;
   font: 11px monospace;
   line-height: 10px;
}

.label {
   margin-right: 1px;
   padding: 2px 3px;
   color: white;
   font-family: sans-serif;
   font-size: 0.8em;
   letter-spacing: 1px;
   text-transform: uppercase;
}

.adminHighlight {
   margin-top: 5px;
   padding: 1px 10px;
   background-color: yellow;
   border: 1px solid <% value 'link color' %>;
}

.Root, .blocked {
   background-color: black;
}

.Site, .public, .privileged  {
   background-color: #006600;
}

.User, .trusted {
   background-color: #0000cc;
}

.regular {
   display: none;
}

.open {
   padding: 1px 2px;
   color: #0000cc;
   border: 1px solid #0000cc;
}

.restricted {
   padding: 1px 2px;
   color: #006600;
   border: 1px solid #006600;
}

.closed {
   background-color: #cc0000;
}

.deleted {
   padding: 1px 2px;
   color: #cc0000;
   border: 1px solid #cc0000;
}

.layout-sandbox {
   height: 22px;
}

.layout-sandbox div {
   position: fixed;
   top: 0;
   left: 0;
   right: 0;
   height: 22px;
   padding: 0 20px;
   background: url('<% root.static sandbox.png %>');
   background-position: 0 23px;
   text-align: left;
}

.av-skin-control {
   margin: 5px 0;
}

.av-skin-edit-link {
   padding: 2px;
   text-decoration: none !important;
}

.connect img {
   padding: 2px 0;
   vertical-align: middle;
   opacity: .3;
}

.helma-debug-line /*:has(script)*/ {
   border: none !important;
}
