This repository has been archived on 2023-01-25. You can view files and clone it, but cannot push or open issues or pull requests.
fvtt-avd12/templates/items/item-module-sheet.hbs

87 lines
3.4 KiB
Handlebars

<form class="{{cssClass}}" autocomplete="off">
<header class="sheet-header">
<img class="item-sheet-img" src="{{img}}" data-edit="img" title="{{name}}"/>
<div class="header-fields">
<h1 class="charname"><input name="name" type="text" value="{{name}}" placeholder="Name"/></h1>
</div>
</header>
{{> systems/fvtt-avd12/templates/items/partial-item-nav.hbs builder=true}}
{{!-- Sheet Body --}}
<section class="sheet-body">
{{> systems/fvtt-avd12/templates/items/partial-item-description.hbs}}
<div class="tab details" data-group="primary" data-tab="details">
<div class="flexcol">
{{#each system.levels as |level index|}}
<div class="flexrow flex-center">
{{#each level.choices as |choice choiceIndex|}}
<span class="module-level-box {{#if choice.selected}}color-selected{{/if}}">
<ul>
{{#each choice.features as |feature id|}}
<li>{{feature.name}}</li>
{{/each}}
</ul>
</span>
{{/each}}
</div>
{{/each}}
</div>
</div>
{{#if isGM}}
<div class="tab builder" data-group="primary" data-tab="builder">
<div class="tab" data-group="primary">
<ul>
{{#each system.levels as |level index|}}
<hr>
<li class="flexrow">
<h2 class="item-field-label-long">Level {{add index 1}}</h2>
<span class="item-field-label-short">
<a class="item-control module-level-delete" data-level-index="{{index}}" title="Delete Level"><i class="fas fa-trash"></i></a>
</span>
</li>
<ul class="ul-level1">
{{#each level.choices as |choice choiceIndex|}}
<li class="item flexrow" data-level-index="{{@../index}}" data-choice-index="{{choiceIndex}}">
<h3 class="item-field-label-long">Level choice {{add choiceIndex 1}}</h3>
<div class="drop-module-step">
<label>Drop traits/actions/... here !</label>
</div>
<span class="item-field-label-short">&nbsp;</span>
<label class="item-field-label-short">Selected</label>
<input type="checkbox" class="item-field-label-short choice-level-selected" {{checked choice.selected}} />
</li>
{{#each choice.features as |feature id|}}
<li class="flexrow item" data-level-index="{{@../../index}}" data-choice-index="{{choiceIndex}}" data-feature-id="{{feature._id}}" >
<label class="item-field-label-long2">{{feature.name}}</label>
<div class="item-controls item-controls-fixed">
<a class="item-control module-feature-view" title="Edit Feature"><i class="fas fa-edit"></i></a>
<a class="item-control module-feature-delete" title="Delete Feature"><i class="fas fa-trash"></i></a>
</div>
</li>
{{/each}}
{{/each}}
</ul>
{{/each}}
<li class="flexrow item">
<button class="chat-card-button add-module-level">Add a level</button>
</li>
</ul>
</div>
{{/if}}
</div>
</section>
</form>