Add basic support for registering custom icons that override icons provided by the system/modules

This commit is contained in:
Oliver 2026-02-09 23:06:51 -07:00
parent c90137b18f
commit c7541db1d9
9 changed files with 279 additions and 6 deletions

View file

@ -0,0 +1,42 @@
<div class="scrollable">
{{#if effects}}
<ul class="effect-list">
{{#each effects as | effect |}}
<li class="effect" data-effect-id="{{ effect.id }}">
<div class="preview">
{{#if effect.preview}}
<img
src="{{effect.preview}}"
alt=""
>
{{/if}}
</div>
<h2>{{ effect.name }}</h2>
<file-picker
value="{{effect.img}}"
></file-picker>
{{#if @root.showImageTaggerButton}}
<button
type="button"
class="icon fa-solid fa-paintbrush"
aria-label="{{localize "OFT.apps.StatusEffectIconConfig.select-using-image-tagger"}}"
data-tooltip
data-action="pickViaImageTagger"
></button>
{{/if}}
{{#if effect.hasOverride}}
<button
type="button"
class="icon fa-solid fa-xmark"
aria-label="{{localize "OFT.apps.StatusEffectIconConfig.remove-override"}}"
data-tooltip
data-action="removeOverride"
></button>
{{/if}}
</li>
{{/each}}
</ul>
{{else}}
{{ localize "OFT.apps.StatusEffectIconConfig.no-status-effects" }}
{{/if}}
</div>