import DOMPurify from 'dompurify'; import { __ } from 'i18n'; import { _converse, api } from "@converse/headless/core.js"; import { html } from "lit"; import { unsafeHTML } from 'lit/directives/unsafe-html.js'; const tplNavigation = (el) => { const i18n_about = __('About'); const i18n_commands = __('Commands'); return html`
`; } export default (el) => { const first_subtitle = __( '%1$s Open Source %2$s XMPP chat client brought to you by %3$s Opkode %2$s', '', '', '' ); const second_subtitle = __( '%1$s Translate %2$s it into your own language', '', '' ); const show_client_info = api.settings.get('show_client_info'); const allow_adhoc_commands = api.settings.get('allow_adhoc_commands'); const show_both_tabs = show_client_info && allow_adhoc_commands; return html` ${ show_both_tabs ? tplNavigation(el) : '' }${_converse.VERSION_NAME}
${unsafeHTML(DOMPurify.sanitize(first_subtitle))}
${unsafeHTML(DOMPurify.sanitize(second_subtitle))}