Skip to content

Commit

Permalink
MWPW-141020: [Project PEP] Implement Analytics Enablement (#1951)
Browse files Browse the repository at this point in the history
* pep analytics

* hotfix

* hotfix

* hotfix

* removed capitalization from analytics label
  • Loading branch information
robert-bogos authored and overmyheadandbody committed Apr 8, 2024
1 parent 0692140 commit 55dd878
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions libs/features/webapp-prompt/webapp-prompt.js
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ class AppPrompt {
await this.getData(content);
// TODO: we might need to set this at the page level through metadata
// so that the same prompt can lead to different apps
if (!this.options['redirect-url']) return;
if (!this.options['redirect-url'] || !this.options['product-name']) return;

this.template = this.decorate();

Expand Down Expand Up @@ -108,8 +108,8 @@ class AppPrompt {

// TODO: should we allow for app icon to be set as SVG?
decorate = () => {
this.elements.closeIcon = toFragment`<button class="appPrompt-close"></button>`;
this.elements.cta = toFragment`<button class="appPrompt-cta appPrompt-cta--close">${this.cancelText}</button>`;
this.elements.closeIcon = toFragment`<button daa-ll="Close Modal" class="appPrompt-close"></button>`;
this.elements.cta = toFragment`<button daa-ll="Stay on this page" class="appPrompt-cta appPrompt-cta--close">${this.cancelText}</button>`;
this.elements.profile = Object.keys(this.profile).length
? toFragment`<div class="appPrompt-profile">
<div class="appPrompt-avatar">
Expand All @@ -122,7 +122,7 @@ class AppPrompt {
</div>`
: '';

return toFragment`<div class="appPrompt">
return toFragment`<div daa-state="true" daa-im="true" daa-lh="PEP Modal_${this.options['product-name']}" class="appPrompt">
${this.elements.closeIcon}
<div class="appPrompt-icon">
${this.image}
Expand Down

0 comments on commit 55dd878

Please sign in to comment.