Tweak the template/css structure
This commit is contained in:
parent
1afffb0a73
commit
56fe115407
24 changed files with 10 additions and 7 deletions
266
templates/Apps/HeroSummaryCardV1/content.hbs
Normal file
266
templates/Apps/HeroSummaryCardV1/content.hbs
Normal file
|
|
@ -0,0 +1,266 @@
|
|||
<div class="HeroSummaryCardV1">
|
||||
{{!-- * Header --}}
|
||||
<div class="header">
|
||||
<div class="image">Logo Image</div>
|
||||
<label class="row-alt" for="{{meta.idp}}-name">
|
||||
Hero
|
||||
</label>
|
||||
<div>
|
||||
Player
|
||||
</div>
|
||||
</div>
|
||||
<input
|
||||
id="{{meta.idp}}-name"
|
||||
type="text"
|
||||
class="hero_name row-alt"
|
||||
value="{{actor.name}}"
|
||||
name="name"
|
||||
>
|
||||
|
||||
{{!-- * Armour --}}
|
||||
<div class="armour"></div>
|
||||
|
||||
{{!-- * Fate & Advancement --}}
|
||||
<div class="fate">
|
||||
<label for="{{meta.idp}}-fate-path" class="col-header">Fate</label>
|
||||
<select
|
||||
class="row-alt"
|
||||
id="{{meta.idp}}-fate-path"
|
||||
name="system.fate"
|
||||
>
|
||||
{{rc-options fate.selected fate.options localize=true}}
|
||||
</select>
|
||||
</div>
|
||||
{{#if meta.editable}}
|
||||
<label
|
||||
for="{{meta.idp}}-glory"
|
||||
class="glory-label col-header"
|
||||
>
|
||||
{{ rc-i18n "RipCrypt.common.glory" }}
|
||||
</label>
|
||||
<input
|
||||
id="{{meta.idp}}-glory"
|
||||
type="number"
|
||||
class="glory row-alt"
|
||||
name="system.level.glory"
|
||||
value="{{level.glory}}"
|
||||
min="0"
|
||||
>
|
||||
{{else}}
|
||||
<div
|
||||
id="{{meta.idp}}-glory-label"
|
||||
class="glory-label label col-header"
|
||||
>
|
||||
{{ rc-i18n "RipCrypt.common.glory" }}
|
||||
</div>
|
||||
<div
|
||||
class="glory row-alt input"
|
||||
aria-describedby="{{meta.idp}}-glory-label"
|
||||
>
|
||||
{{ level.glory }}
|
||||
</div>
|
||||
{{/if}}
|
||||
{{#if meta.editable}}
|
||||
<label
|
||||
for="{{meta.idp}}-step"
|
||||
class="step-label col-header"
|
||||
>
|
||||
{{ rc-i18n "RipCrypt.common.step" }}
|
||||
</label>
|
||||
<input
|
||||
id="{{meta.idp}}-step"
|
||||
type="number"
|
||||
class="step row-alt"
|
||||
name="system.level.step"
|
||||
value="{{level.step}}"
|
||||
min="1"
|
||||
max="3"
|
||||
>
|
||||
{{else}}
|
||||
<div
|
||||
id="{{meta.idp}}-step-label"
|
||||
class="step-label label col-header"
|
||||
>
|
||||
{{ rc-i18n "RipCrypt.common.step" }}
|
||||
</div>
|
||||
<div
|
||||
class="step row-alt input"
|
||||
aria-describedby="{{meta.idp}}-step-label"
|
||||
>
|
||||
{{ level.step }}
|
||||
</div>
|
||||
{{/if}}
|
||||
|
||||
<{{{ifThen meta.editable "label" "div"}}}
|
||||
id="{{meta.idp}}-rank-label"
|
||||
for="{{meta.idp}}-rank"
|
||||
class="rank-label label col-header"
|
||||
>
|
||||
{{ rc-i18n "RipCrypt.common.rank" }}
|
||||
</{{{ifThen meta.editable "label" "div"}}}>
|
||||
{{#if meta.editable}}
|
||||
<select
|
||||
id="{{meta.idp}}-rank"
|
||||
name="system.level.rank"
|
||||
class="rank row-alt"
|
||||
>
|
||||
{{ rc-options level.rank.selected level.rank.options }}
|
||||
</select>
|
||||
{{else}}
|
||||
<div
|
||||
aria-describedby="{{meta.idp}}-rank-label"
|
||||
class="rank row-alt input"
|
||||
>
|
||||
{{ level.rank.selected }}
|
||||
</div>
|
||||
{{/if}}
|
||||
|
||||
{{!-- * Weapons --}}
|
||||
<table class="weapons">
|
||||
<thead>
|
||||
<tr>
|
||||
<th class="label col-header">{{ rc-i18n "RipCrypt.common.weapon.plural" }}</th>
|
||||
<th class="label col-header">{{ rc-i18n "RipCrypt.Apps.traits-range" }}</th>
|
||||
<th class="label col-header">{{ rc-i18n "RipCrypt.common.wear" }}</th>
|
||||
<th class="label col-header">{{ rc-i18n "RipCrypt.common.damage" }}</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
{{#each weapons as | slot |}}
|
||||
{{#if slot.empty}}
|
||||
<tr
|
||||
data-row="{{slot.index}}"
|
||||
class="{{slot.class}}"
|
||||
aria-hidden="true"
|
||||
>
|
||||
<td>{{ rc-i18n "RipCrypt.common.empty" }}</td>
|
||||
<td></td>
|
||||
<td></td>
|
||||
<td></td>
|
||||
</tr>
|
||||
{{else}}
|
||||
<tr data-row="{{slot.index}}" class="{{slot.class}}">
|
||||
<td>{{ slot.data.name }}</td>
|
||||
<td>
|
||||
{{#if slot.data.system.traitString}}
|
||||
<span class="traits">{{ slot.data.system.traitString }}</span>
|
||||
{{/if}}
|
||||
{{#if slot.data.system.rangeString}}
|
||||
<span class="range">{{ slot.data.system.rangeString }}</span>
|
||||
{{/if}}
|
||||
</td>
|
||||
<td>
|
||||
{{ slot.data.system.wear.value }} / {{ slot.data.system.wear.max }}
|
||||
</td>
|
||||
<td>
|
||||
{{ slot.data.system.damage }}
|
||||
</td>
|
||||
</tr>
|
||||
{{/if}}
|
||||
{{/each}}
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
{{!-- * Abilities --}}
|
||||
<div class="abilities">
|
||||
{{!-- Actual Abilities --}}
|
||||
{{#each abilities as | ability |}}
|
||||
<div class="ability">
|
||||
<div class="compass">
|
||||
{{#unless ability.readonly}}
|
||||
<input
|
||||
type="number"
|
||||
id="{{@root.meta.idp}}-{{ability.id}}-input"
|
||||
class="value"
|
||||
value="{{ability.value}}"
|
||||
name="system.ability.{{ability.id}}"
|
||||
min=0
|
||||
>
|
||||
{{else}}
|
||||
<span>{{ability.value}}</span>
|
||||
{{/unless}}
|
||||
{{#if @root.meta.editable}}
|
||||
<button
|
||||
type="button"
|
||||
class="roll icon"
|
||||
data-action="roll"
|
||||
data-formula="{{ability.value}}d8rc4"
|
||||
data-flavor="{{ability.name}} Roll (Difficulty: 4)"
|
||||
>
|
||||
<rc-icon
|
||||
var:size="20px"
|
||||
var:fill="currentColor"
|
||||
name="icons/roll"
|
||||
></rc-icon>
|
||||
</button>
|
||||
{{/if}}
|
||||
</div>
|
||||
{{#unless ability.readonly}}
|
||||
<label
|
||||
class="col-header"
|
||||
for="{{@root.meta.idp}}-{{ability.id}}-input"
|
||||
>
|
||||
{{ ability.name }}
|
||||
</label>
|
||||
{{else}}
|
||||
<div class="col-header label">
|
||||
{{ ability.name }}
|
||||
</div>
|
||||
{{/unless}}
|
||||
</div>
|
||||
{{/each}}
|
||||
|
||||
{{!-- Health --}}
|
||||
<div class="ability">
|
||||
<div class="compass dual">
|
||||
{{#if meta.editable}}
|
||||
<input
|
||||
type="number"
|
||||
id="{{meta.idp}}-guts-value"
|
||||
class="value"
|
||||
name="system.guts.value"
|
||||
value="{{guts.value}}"
|
||||
min="0"
|
||||
>
|
||||
{{else}}
|
||||
<span
|
||||
class="value"
|
||||
aria-describedby="{{meta.idp}}-guts-value-label"
|
||||
{{!-- TODO: aria-label="{{ rc-i18n "RipCrypt.Apps.a11y.guts-value-readonly" }}" --}}
|
||||
>
|
||||
{{ guts.value }}
|
||||
</span>
|
||||
{{/if}}
|
||||
<span
|
||||
class="max"
|
||||
aria-hidden="true"
|
||||
{{!-- TODO: aria-label="{{ rc-i18n "RipCrypt.Apps.a11y.guts-max-readonly" }}" --}}
|
||||
>
|
||||
{{ guts.max }}
|
||||
</span>
|
||||
</div>
|
||||
{{#if meta.editable}}
|
||||
<label class="col-header" for="{{meta.idp}}-guts-value">
|
||||
{{ rc-i18n "RipCrypt.common.guts" }}
|
||||
</label>
|
||||
{{else}}
|
||||
<div class="col-header label" id="{{meta.idp}}-guts-value-label">
|
||||
{{ rc-i18n "RipCrypt.common.guts" }}
|
||||
</div>
|
||||
{{/if}}
|
||||
</div>
|
||||
|
||||
{{!-- Move & Run --}}
|
||||
<div class="ability">
|
||||
<div class="compass dual">
|
||||
<span class="value">{{speed.move}}</span>
|
||||
<span class="max">{{speed.run}}</span>
|
||||
</div>
|
||||
<div aria-hidden="true" class="col-header label">
|
||||
{{rc-i18n "RipCrypt.Apps.move-run"}}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{{!-- * Equipment --}}
|
||||
</div>
|
||||
Loading…
Add table
Add a link
Reference in a new issue