1. Matthew Turk
  2. yt.hub

Source

yt.hub / ythub / templates / index.html

{% extends "layout.html" %}
{% block subpage %} Welcome {% endblock %}

{% block mainbody %}
      <!-- Main hero unit for a primary marketing message or call to action -->
      <section id="home">
        <div class="hero-unit hero-border" style="padding-top:5.0em;">
          <a name="home" class="anchor"><h1>The yt Data Hub</h1></a>
          <p>&nbsp;</p>
          <p>This is the yt Data Hub, a place to upload and share data and
          images generated by and from <a href="http://yt-project.org/">yt</a>.</p>
          <p>Right now we have widgets for variable maps (projections,
          slices), 3D vertex exploration, simulation parameter display, and
          collections of images.</p>
          <p>To get started, <a href="/create_user">register a user</a> and
          follow the <a href="/getting_started.html">quickstart</a> to upload
          data.</p>
        </div>
      <section id="projects" style="padding-top:5.0em;">
        <div class="row">
          <div class="span12">
            <div class="row">
              <h1>Recent Projects</h1>
              <p>&nbsp;</p>
            </div>
            {% for u, d in projects[:3] %}
            <div class="row">
              <div class="span3">
                {% if d['image_url'] != "" %}
                <a href="{{d.project_url}}" style="text-decoration:none;">
                    <img src="{{ d['image_url'] }}" width="256">
                </a>
                {% else %}
                    <img src="https://s3.amazonaws.com/ythub_04ccdd136e464ea48d65a9129c0eebcd/oldhub_images/blank_project.png" width="256">
                {% endif %}
              </div>
              <div class="span8">
                <div class="row">
                  <div class="span8">
                    <h3><a style="text-decoration:none; color:#000000;" href="{{d.project_url}}">{{d.title}}</a></h3>
                  </div>
                  <div class="span8">
                    <p>By <a href="/users/{{u.username}}">{{ u.name }}</a>
                       in {{d.category}}.</p>
                    <p><a href="{{ d.project_url }}">Project Home</a> / 
                       {{ d.url() | safe }}</p>
                  </div>
                  <div class="span8">
                    <p>{{d.description}}</p>
                  </div>
                </div>
              </div>
            </div>
            <div class="row">
              <hr>
            </div>
            {% endfor %}
            <div class="row">
              <div class="span3">&nbsp;</div>
              <div class="span6">
                <h2><a href="/projects" style="text-decoration: none; color:#000000">All projects ...</a></h2>
              </div>
              <div class="span3">&nbsp;</div>
          </div>
        </div>
      </section>
      <section id="data" style="padding-top:5.0em;">
        <div class="row">
          <div class="span12">
            <h1>Recently Uploaded Data</h1>
            <p>&nbsp;</p>
            <table class="table table-bordered table-striped">
              <thead>
                <tr>
                  <th>#</th>
                  <th>Type</th>
                  <th>Descr</th>
                  <th>Context</th>
                  <th>View</th>
                </tr>
              </thead>
              <tbody>
                {% for u, d in data[:10] %}
                <tr><td><a href="/users/{{u.username}}">{{ u.name }}</a></td>
                    <td>{{ d.display_name }}</td>
                    <td>{{ d.descr() }}</td>
                    <td>{{ d.opt() | safe }}</td>
                    <td>{{ d.url() | safe }}</td>
                </tr>
                {% endfor %}
              </tbody>
            </table>
          </div>
        </div>
      </section>
{% endblock %}