ds4/src/templates/item/talent-sheet.hbs

71 lines
3.4 KiB
Handlebars
Raw Normal View History

{{!-- ======================================================================== --}}
{{!-- INLINE PARTIAL DEFINITIONS --}}
{{!-- ======================================================================== --}}
{{#*inline "talentRankSideProperty" }}
<div class="side-property">
<label for="data.talentRank.{{property}}">{{localize localizeString}}</label>
<input type="number" min="0" step="1" data-dtype="Number" {{disabled}}
{{#if (eq property 'base') }}max="{{data.talentRank.max}}"{{/if}}
name="data.talentRank.{{property}}" value="{{lookup data.talentRank property}}" />
</div>
{{/inline}}
{{!-- ======================================================================== --}}
<form class="{{cssClass}}" autocomplete="off">
<header class="sheet-header">
<img class="profile-img" src="{{item.img}}" data-edit="img" title="{{item.name}}" />
<div class="header-fields flexrow">
<h1 class="charname"><input name="name" type="text" value="{{item.name}}" placeholder="Name" /></h1>
<h2 class="item-type">{{localize (lookup config.itemTypes item.type)}}</h2>
</div>
</header>
{{!-- Sheet Tab Navigation --}}
<nav class="sheet-tabs tabs" data-group="primary">
<a class="item" data-tab="description">{{localize "DS4.Description"}}</a>
<a class="item" data-tab="effects">{{localize "DS4.Effects"}}</a>
</nav>
{{!-- Sheet Body --}}
<section class="sheet-body">
{{!-- The item tab for details. --}}
<div class="tab flexrow" data-group="primary" data-tab="description">
{{!-- As you add new fields, add them in here! --}}
<div class="side-properties">
{{!-- TODO: remove duplication of isOwned section here and in description.hbs--}}
{{#if isOwned}}
{{#if (ne data.equipped undefined)}}<div class="side-property">
<label for="data.equipped">{{localize 'DS4.ItemEquipped'}}</label>
<input type="checkbox" name="data.equipped" data-dtype="Boolean" {{checked data.equipped}} title="{{localize 'DS4.ItemEquipped'}}">
</div>
{{/if}}
<div class="side-property">
<label for="data.actor">{{localize 'DS4.ItemOwner'}}</label>
<a class="entity-link" draggable="true" data-entity="Actor" data-id="{{actor._id}}"><i
class="fas fa-user"></i>{{actor.name}}</a>
</div>
{{else}}
<span>{{localize "DS4.NotOwned"}}</span>
{{/if}}
{{> talentRankSideProperty data=data property='base' localizeString='DS4.TalentRankBase' }}
{{> talentRankSideProperty data=data property='max' localizeString='DS4.TalentRankMax'}}
{{> talentRankSideProperty data=data property='mod' localizeString='DS4.TalentRankMod'}}
{{> talentRankSideProperty data=data property='total' localizeString='DS4.TalentRankTotal' disabled='disabled'}}
</div>
<div class="description" title="{{localize 'DS4.Description'}}">
{{editor content=data.description target="data.description" button=true owner=owner editable=editable}}
</div>
</div>
</section>
{{!-- Effects Tab --}}
{{> systems/ds4/templates/item/partials/effects.hbs}}
</form>