CofD view character page parity with edit character page.

This commit is contained in:
projectmoon 2021-01-23 15:13:56 +00:00
parent dc354e5217
commit a8a37104a6
2 changed files with 105 additions and 61 deletions

View File

@ -33,8 +33,9 @@
margin: 0; margin: 0;
} }
.basics-entry input { .basics-entry span {
display: inline; width: 15em;
overflow: hidden;
padding: 8px; padding: 8px;
border: none; border: none;
background-color: lightgray; background-color: lightgray;
@ -164,19 +165,50 @@
} }
</style> </style>
<h1>Core Sheet</h1>
<div> <div>
<h1>Character {{name}}</h1> <div id="basics">
<h3>User: {{username}}</h3> <h1>
<p>System: {{data_type}}</h3> <span id="characterName" name="characterName">{{name}}</span>
</h1>
<div class="links">
<a href="/characters/{{username}}/{{id}}/edit">Edit Character</a> |
<a href="/characters/{{username}}/{{id}}/delete">Delete Character</a>
</div> </div>
<div> <h2>Basics</h2>
<h1>Core Sheet</h1> <div>System: {{data_type}}</div>
<div>
<h1>Name: <input type="text" value="{{name}}" /></h1> <div class="flex-container">
<p>System: {{data_type}}</p> <div class="basics-row">
<div class="basics-entry">
<label for="gender">Gender:</label>
<span id="gender" name="gender">{{sheet.gender}}</span>
</div>
<div class="basics-entry">
<label for="age">Age:</label>
<span id="age" name="age">{{sheet.age}}</span>
</div>
</div>
<div class="basics-row">
<div class="basics-entry">
<label for="concept">Concept:</label>
<span id="concept" name="concept">{{sheet.concept}}</span>
</div>
<div class="basics-entry">
<label for="chronicle">Chronicle:</label>
<span id="chronicle" name="chronicle">{{sheet.chronicle}}</span>
</div>
</div>
</div>
</div>
<div id="attributes"> <div id="attributes">
<h2>Attributes</h2>
<div class="flex-container"> <div class="flex-container">
<div class="attributes-section" id="mentalAttributes"> <div class="attributes-section" id="mentalAttributes">
{{ macros::attribute(name="Intelligence", value=sheet.intelligence) }} {{ macros::attribute(name="Intelligence", value=sheet.intelligence) }}
@ -220,9 +252,14 @@
</div> </div>
</div> </div>
</div> </div>
</div>
<div> <div id="merits">
<a href="/characters/{{username}}/{{id}}/edit">Edit Character</a> <h2>Merits</h2>
<div id="merit-list">
{% for merit in sheet.merits %}
{{ macros::merit(name=merit.name, value=merit.dots) }}
{% endfor %}
</div>
</div>
</div> </div>
{% endblock content %} {% endblock content %}

View File

@ -11,3 +11,10 @@
<span class="value" id="{{name}}">{{value}}</span> <span class="value" id="{{name}}">{{value}}</span>
</div> </div>
{% endmacro skill %} {% endmacro skill %}
{% macro merit(name, value) %}
<div class="merit">
<span class="merit-name">{{name}}</span>
<span class="merit-dots">{{value}}</span> <span>Dots</span>
</div>
{% endmacro merit %}