Fix lit class attribute.
This commit is contained in:
parent
1cc6a68089
commit
4851e35fba
@ -6,6 +6,7 @@ import { LivechatElement } from '../../lib/elements/livechat'
|
|||||||
import { ptTr } from '../../lib/directives/translation'
|
import { ptTr } from '../../lib/directives/translation'
|
||||||
import { html, TemplateResult } from 'lit'
|
import { html, TemplateResult } from 'lit'
|
||||||
import { customElement, property } from 'lit/decorators.js'
|
import { customElement, property } from 'lit/decorators.js'
|
||||||
|
import { classMap } from 'lit/directives/class-map.js'
|
||||||
|
|
||||||
@customElement('livechat-channel-tabs')
|
@customElement('livechat-channel-tabs')
|
||||||
export class ChannelHomeElement extends LivechatElement {
|
export class ChannelHomeElement extends LivechatElement {
|
||||||
@ -18,13 +19,19 @@ export class ChannelHomeElement extends LivechatElement {
|
|||||||
protected override render = (): TemplateResult => {
|
protected override render = (): TemplateResult => {
|
||||||
return html`
|
return html`
|
||||||
<a
|
<a
|
||||||
class="sub-menu-entry ${this.active === 'configuration' ? 'active' : ''}"
|
class=${classMap({
|
||||||
|
'sub-menu-entry': true,
|
||||||
|
active: this.active === 'configuration'
|
||||||
|
})}
|
||||||
href=${'/p/livechat/configuration/channel?channelId=' + encodeURIComponent(this.channelId ?? '')}
|
href=${'/p/livechat/configuration/channel?channelId=' + encodeURIComponent(this.channelId ?? '')}
|
||||||
>
|
>
|
||||||
${ptTr(LOC_LIVECHAT_CONFIGURATION_CHANNEL_TITLE)}
|
${ptTr(LOC_LIVECHAT_CONFIGURATION_CHANNEL_TITLE)}
|
||||||
</a>
|
</a>
|
||||||
<a
|
<a
|
||||||
class="sub-menu-entry ${this.active === 'emojis' ? 'active' : ''}"
|
class=${classMap({
|
||||||
|
'sub-menu-entry': true,
|
||||||
|
active: this.active === 'emojis'
|
||||||
|
})}
|
||||||
href=${'/p/livechat/configuration/emojis?channelId=' + encodeURIComponent(this.channelId ?? '')}
|
href=${'/p/livechat/configuration/emojis?channelId=' + encodeURIComponent(this.channelId ?? '')}
|
||||||
>
|
>
|
||||||
${ptTr(LOC_LIVECHAT_CONFIGURATION_CHANNEL_EMOJIS_TITLE)}
|
${ptTr(LOC_LIVECHAT_CONFIGURATION_CHANNEL_EMOJIS_TITLE)}
|
||||||
|
Loading…
Reference in New Issue
Block a user