Skip to content

Commit

Permalink
fix(cc-invoice): move <template> inside unsafeHTML expression
Browse files Browse the repository at this point in the history
Lit does not allow expressions inside `<template>` tags.

Fixes #784
  • Loading branch information
florian-sanders-cc committed Jun 26, 2023
1 parent c8ca78b commit 92b20ec
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/components/cc-invoice/cc-invoice.js
Original file line number Diff line number Diff line change
Expand Up @@ -67,9 +67,9 @@ export class CcInvoice extends LitElement {
<div slot="button">${ccLink(invoice.downloadUrl, i18n('cc-invoice.download-pdf'), skeleton)}</div>
<div class="info"><em class=${classMap({ skeleton })}>${i18n('cc-invoice.info', { date, amount })}</em></div>
<cc-html-frame class="frame" ?loading="${skeleton}" iframe-title="${i18n('cc-invoice.title')} ${number}">
${!skeleton ? html`
<template>${unsafeHTML(this.invoice.invoiceHtml)}</template>
` : ''}
${!skeleton ? unsafeHTML(`
<template>${this.invoice.invoiceHtml}</template>
`) : ''}
</cc-html-frame>
` : ''}
${this.error ? html`
Expand Down

0 comments on commit 92b20ec

Please sign in to comment.