- DataModel : suppression 'description', ajout 'exemples' (HTMLField) - Template anomaly.hbs : suppression onglets, 3 sections éditables directement (sans bouton masqué), scroll interne - Styles : fond crème + titres de section Art Déco + éditeurs blancs avec texte sombre lisible (fix couleur jaune illisible) - item-sheets.mjs : contexte enrichedExemples + hauteur fenêtre 560px - lang/fr.json : clé CELESTOPOL.Item.exemples Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
82 lines
3.1 KiB
Handlebars
82 lines
3.1 KiB
Handlebars
<div class="item-sheet anomaly">
|
|
<header class="item-header">
|
|
<div class="item-portrait" data-action="editImage">
|
|
<img src="{{item.img}}" alt="{{item.name}}">
|
|
</div>
|
|
<div class="item-header-fields">
|
|
<input type="text" name="name" value="{{item.name}}" {{#unless isEditable}}disabled{{/unless}}>
|
|
<div class="item-meta">
|
|
<select name="system.subtype" {{#unless isEditable}}disabled{{/unless}}>
|
|
{{#each anomalyTypes as |atype key|}}
|
|
<option value="{{key}}" {{#if (eq key ../system.subtype)}}selected{{/if}}>{{localize atype.label}}</option>
|
|
{{/each}}
|
|
</select>
|
|
<div class="anomaly-level-field">
|
|
<label>{{localize "CELESTOPOL.Anomaly.level"}}</label>
|
|
{{#if isEditable}}
|
|
<input type="number" name="system.level" value="{{system.level}}" min="1" max="4" class="level-input">
|
|
{{else}}
|
|
<span class="anomaly-level-value">{{system.level}}</span>
|
|
{{/if}}
|
|
</div>
|
|
</div>
|
|
{{!-- Usages restants : dots visuels --}}
|
|
<div class="anomaly-uses-row">
|
|
<span class="anomaly-uses-label">{{localize "CELESTOPOL.Anomaly.usesRemaining"}} :</span>
|
|
<div class="anomaly-uses-dots">
|
|
{{#each (array 1 2 3 4) as |n|}}
|
|
{{#if (lte n ../system.usesRemaining)}}
|
|
<span class="anomaly-dot available"></span>
|
|
{{else}}
|
|
{{#if (lte n ../system.level)}}
|
|
<span class="anomaly-dot spent"></span>
|
|
{{else}}
|
|
<span class="anomaly-dot inactive"></span>
|
|
{{/if}}
|
|
{{/if}}
|
|
{{/each}}
|
|
</div>
|
|
{{#if isEditable}}
|
|
<input type="number" name="system.usesRemaining" value="{{system.usesRemaining}}" min="0" max="4" class="uses-number-input">
|
|
{{/if}}
|
|
</div>
|
|
</div>
|
|
</header>
|
|
|
|
{{!-- Domaines applicables --}}
|
|
{{#if applicableSkillLabels.length}}
|
|
<div class="anomaly-skills-bar">
|
|
<span class="anomaly-skills-label">{{localize "CELESTOPOL.Anomaly.applicableSkills"}} :</span>
|
|
{{#each applicableSkillLabels as |label|}}
|
|
<span class="anomaly-skill-chip">{{label}}</span>
|
|
{{/each}}
|
|
</div>
|
|
{{/if}}
|
|
|
|
{{!-- Corps principal : 3 sections sans onglets --}}
|
|
<div class="anomaly-body">
|
|
|
|
<div class="anomaly-section">
|
|
<div class="anomaly-section-title">{{localize "CELESTOPOL.Item.technique"}}</div>
|
|
<div class="anomaly-editor-wrap">
|
|
{{editor system.technique target="system.technique" button=false editable=isEditable}}
|
|
</div>
|
|
</div>
|
|
|
|
<div class="anomaly-section">
|
|
<div class="anomaly-section-title">{{localize "CELESTOPOL.Item.narratif"}}</div>
|
|
<div class="anomaly-editor-wrap">
|
|
{{editor system.narratif target="system.narratif" button=false editable=isEditable}}
|
|
</div>
|
|
</div>
|
|
|
|
<div class="anomaly-section">
|
|
<div class="anomaly-section-title">{{localize "CELESTOPOL.Item.exemples"}}</div>
|
|
<div class="anomaly-editor-wrap">
|
|
{{editor system.exemples target="system.exemples" button=false editable=isEditable}}
|
|
</div>
|
|
</div>
|
|
|
|
</div>
|
|
</div>
|