Skip to content

Commit

Permalink
Fix web share api
Browse files Browse the repository at this point in the history
Signed-off-by: Jay Wang <[email protected]>
  • Loading branch information
xiaohk committed Jan 10, 2024
1 parent 0638517 commit 6222283
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions src/components/prompt-viewer/prompt-viewer.ts
Original file line number Diff line number Diff line change
Expand Up @@ -115,10 +115,7 @@ export class WordflowPromptViewer extends LitElement {
text: this.promptData.title,
url: `https://poloclub.github.io/wordflow?prompt=${promptID}`
};
console.log(shareData.url);
if (navigator.canShare()) {
navigator.share(shareData);
}
navigator.share(shareData);
}

//==========================================================================||
Expand Down Expand Up @@ -208,7 +205,7 @@ export class WordflowPromptViewer extends LitElement {
<span></span>
<span class="value"
><span class="text-button" @click=${() => this.shareButtonClicked()}
>Send prompt to a friend</span
>Share with a friend</span
></span
> `;

Expand Down

0 comments on commit 6222283

Please sign in to comment.