Iss337 - Allow armor slots to be edited from the character sheet (#345)

* add armor slot input

* working progress bar

* fix label styling

* fix more styling

* fix styling issue on firefix

* Restored armorSlots when empty and added localization

---------

Co-authored-by: psitacus <walther.johnson@ucalgary.ca>
Co-authored-by: WBHarry <williambjrklund@gmail.com>
This commit is contained in:
Psitacus 2025-07-15 04:03:12 -06:00 committed by GitHub
parent 6b6f4e61d6
commit ef45cd71f8
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
4 changed files with 172 additions and 13 deletions

View file

@ -48,18 +48,32 @@
</div>
</div>
<div class="status-number">
<div class='status-value armor-slots'>
{{#if document.system.armor.system.marks}}
<p>{{document.system.armor.system.marks.value}}/{{document.system.armorScore}}</p>
{{else}}
{{#if document.system.armor.system.marks}}
<div class="status-bar armor-slots">
<div class='status-value'>
<p><input class="bar-input armor-marks-input" value="{{document.system.armor.system.marks.value}}" type="number"></p>
<p>/</p>
<p class="bar-label">{{document.system.armorScore}}</p>
</div>
<progress
class='progress-bar stress-color'
value='{{document.system.armor.system.marks.value}}'
max='{{document.system.armorScore}}'
></progress>
<div class="status-label">
<h4>{{localize "DAGGERHEART.GENERAL.armorSlots"}}</h4>
</div>
</div>
{{else}}
<div class="status-number armor-slots">
<div class='status-value'>
<p>-</p>
{{/if}}
</div>
<div class="status-label">
<h4>{{localize "DAGGERHEART.GENERAL.armorSlots"}}</h4>
</div>
</div>
<div class="status-label">
<h4>Armor Slots</h4>
</div>
</div>
{{/if}}
<div class="status-number">
<div class='status-value'>