otter 1.2.1

Otter game system; main data structures Rust crate.
Documentation
{# -*- HTML -*- -#}
<!-- Copyright 2020u Ian Jackson
     SPDX-License-Identifier: AGPL-3.0-or-later
     There is NO WARRANTY. -->

{% macro header() %}
<body id="main-body"
      data-ctoken="{{ctoken}}"
      data-us="{{player}}"
      data-gen="{{gen}}"
      data-sse-url-prefix="{{sse_url_prefix}}"
      data-load="{{ load | escape }}"
      style="transform-origin: top left;"
      >
<style>
  html {
    background-color: #eef;
  }
  .footer {
    background-color: #ddf;
  }
  div[id=infopane] {
    display: flex;
    flex-direction: column;
    background-color: white;
    overflow-y: scroll;
  }
  div[class=uos] {
    flex: initial;
  }
  div[id=uos] {
    flex: auto;
  }
  div[class=somepane] {
    flex: auto;
    display: flex;
    flex-direction: column;
  }
  div[id=player_list_columns] {
  }
</style>
{% endmacro header %}

{% macro nick() %}
Hi {{nick | escape}}
{% endmacro nick%}

{% macro wresting() %}
<span id="wresting-warning"></span>
{% endmacro wresting %}

{% macro status() %}
{%- if fake_rng %}<strong>FAKING RANDOMNESS!</strong>{% endif %}
{%- if fake_time %}<strong>FAKING TIME!</strong>{% endif %}
<span id="status">nothing</span>
{% endmacro status %}

{% macro zoom() %}
<span style="white-space: nowrap;"
><button id="zoom-btn" disabled
	 onclick="zoom_activate()"
>Zoom</button
><input id="zoom-val" 
	type="number" max="1000" min="10" step="5" size="4" value="100"
	oninput="zoom_enable()"
>%</span>
{% endmacro status %}

{% macro errors() %}
<pre id="error"></pre>
{% endmacro errors %}

{% macro space() %}
    <style id="space-cursor-style">
    </style>
    <svg xmlns="http://www.w3.org/2000/svg"
         id="space" {{ space_attrs }} >
      <rect fill="{{ table_colour }}" x="0" y="0"
	    id="table_rect" {{ rect_attrs }} />
      <g id="pieces_marker"></g>
{%- for piece in uses %}
      <use id="use{{ piece.id }}" href="#piece{{ piece.id }}"
	   x="{{ piece.pos[0] }}" y="{{ piece.pos[1] }}"
	   data-piece="{{ piece.id }}" data-info="{{ piece.info | escape }}" />
{%- endfor %}
      <g id="defs_marker"></g>
{%- for piece in defs %}
      <defs id="defs{{ piece.0 }}">{{ piece.1 }}</defs>
{%- endfor %}
      <g id="movehist_marker"></g>
      <g id="movehist_end"></g>
      <use href="#rectsel_path" stroke-width="1.0 "stroke="purple"/>
      <use href="#rectsel_path" stroke-width="0.5" stroke="#fcf"  />
      <defs id ="static_defs">
      <g id="rectsel_path"><path fill="none" stroke-dasharray="1 1" d=""/></g>
      </defs>
    </svg>
{% endmacro space %}

{% macro infopane() %}
<div id="infopane">

 <div id="pane_help" class="somepane">
  <div id="uos" class="uos">
    <div class="uos-mid" id="uos-mid"></div>
  </div>
  <div class="uos">
    <div class="uokey"><strong>Mouse</strong> select/deselect/drag
                       <strong>shift</strong> multiple selection</div>
    <div class="uokey"><strong>0-9</strong> special selection</div>
    <div class="uokey">Show
      <strong>H</strong> this help
      <strong>U</strong> players
      <strong>B</strong> bundles
    </div>
  </div>
 </div>

 <div id="pane_players" class="somepane" style="display:none">
  <div id="player_list_columns">
<div><strong>Players</strong> (<strong>H</strong>/<strong>U</strong>: return to help)</div>
  <div id="player_list">
{{ player_info_pane }}
  </div>
  </div>
 </div>

 <div id="pane_bundles" class="somepane" style="display:none">
  <div id="bundle_list_columns">
<div><strong>Bundles</strong> (<strong>H</strong>/<strong>B</strong>: return to help)</div>
  <div id="bundle_list">
{{ bundles_info_pane }}
  </div>
  </div>
 </div>

</div id="infopane">
{% endmacro infopane %}

{% macro footer() %}
  <div class="footer">
    <!--
         this affects the document's overall scrollbars
         which is not what we want.  so get rid of it for now
    <div class="footer"; style="
         height: 100vw;
         width: 200vw;
         left: -50vw;
         overflow-y: clip;
         position: absolute;
         z-index: -1;
     "><!-- this fills in the rest of the page, including the margins
         --x
    </div>
    -->
    <hr>
    <address style="max-height: 100vh;">
      This server is running Otter, the Online TableTop Environment
      Renderer.  Otter and its shape (piece picture) libraries
      are <a href="/_/libre">Free Software</a> and come with NO
      WARRANTY.
  </div>
{% endmacro footer %}