{{#>layout}}
{{#*inline "content"}}

{{#if title}}
<h1>{{title}}</h1>
{{else}}
<h1>{{metadata.actionName}} notification</h1>
{{/if}}

<p>Your <b>{{metadata.actionName}}</b> action on Forge triggered a notification.</p>

<blockquote>
{{#if title}}
<b>{{title}}</b>
<br>
{{/if}}
{{message}}
</blockquote>

<p><a href="{{APP_URL}}/dashboard/{{metadata.orgSlug}}/transactions/{{metadata.transactionId}}">View the transaction that sent this notification here</a>.</p>

<ul>
  <li><b>Action runner:</b> {{metadata.actionRunner}}</li>
  <li><b>Sent at:</b> {{metadata.createdAt}}</li>
</ul>

{{#unless_equals failedDetails.length 0}}
<div class='notification-failures'>
<p><code>⚠️  Delivery failed for this notification to the following destinations:</code></p>
<ul>
{{#each failedDetails}}
<li><code><b>{{this.to}} via {{this.method}}:</b> {{this.error}}</code></li>
{{/each}}
</ul>
</div>
{{/unless_equals}}

{{/inline}}
{{/layout}}
