import { LightningElement, api } from "lwc"; import { track } from "dxUtils/analytics"; export default class FooterOption extends LightningElement { @api href: string | null = null; @api generalLabel: string | null = null; @api label: string | null = null; @api target: string | null = null; sendGtm(e: any) { track(e.currentTarget, "custEv_bottomNavLinkClick", { click_text: this.label || undefined, click_url: (this.href && this.href.includes("http") ? this.href : `${window.location.origin}${this.href}`) || undefined, nav_item: this.label || undefined, nav_level: "1", element_type: "link", nav_type: "footer" }); track(e.currentTarget!, "custEv_linkClick", { click_text: this.label, element_title: this.generalLabel, click_url: (this.href && this.href.includes("http") ? this.href : `${window.location.origin}${this.href}`) || undefined, element_type: "link", content_category: "cta" }); } }