<!-- arguments -->
<!-- tag: tag inquestion -->
<!-- canBurn: allow burning of this tag -->

<div class="flex-row tag" data-tag-id="{{tag.id}}" data-owner-id="{{tag.parent.id}}" data-token-id="{{tag.parent.tokenId}}" data-scene-id="{{tag.parent.sceneId}}">
	<div class="flex-narrow flex-line flex-trash">
		{{#if (allowTagDelete tag)}}
		<a class="item-control tag-delete" title="Delete Tag" data-tag-id="{{tag.id}}"><i class="fas fa-trash shrink-icon"></i></a>
		{{else}}
		{{#if (eq tag.system.subtype "loadout")}}
		<a class="toggle-activation-loadout-tag activation-square" title="Activate Loadout Tag">
			{{#if (eq tag.system.activated_loadout true)}}
			<i class="fa-solid fa-square"></i>
			{{else}}
			<i class="fa-regular fa-square"></i>
			{{/if}}
		</a>
		{{/if}}
		{{/if}}
	</div>
	<div class="flex-wide flex-line">
		{{> "systems/city-of-mist/templates/parts/tag-name.html" activated=(hasActivatedItem tag) tagdirection=(getDirection tag) tag=tag}}
	</div>
	<div class="flex-narrow flex-line flex-burn-flame-cell">
		{{#if (not tag.parent.system.locked)}}
		{{#if (canTakeLoadoutWeakness tag)}}
		<a class="loadout-create-weakness-tag" title="Add WeaknessTag">
			<i class="fas fa-anchor" ></i>
		</a>
		{{/if}}
		{{else}}
		{{#if tag.parent.isOwner}}
		{{#if (eq tag.system.burn_state 0)}}
		{{#if canBurn}}
		{{#if tag.isBurnable}}
		<a class="tag-burn" title="Burn Tag" > <i class="fas fa-fire"></i> </a>
		{{/if}}
		{{/if}}
		{{else}}
		{{#if (eq tag.system.burn_state 1)}}
		<a class="tag-unburn" title="Unburn Tag" ><i class="fas fa-undo"></i> </a>
		{{/if}}
		{{/if}}
		{{/if}}
		{{/if}}
	</div>
</div>
