ampproject / ampproject/amphtml

Share Button amp-story-player dispatch event click

Open
#35,223 6 comments 0 reactions 0 assignees View on GitHub
Components: amp-story-player Type: Feature Request WG: stories
Dominant language
JavaScript
Stars
14.9k
Forks
4.1k
PR merge metrics
No merged PRs in 30d

Description

### Description

I am trying to listen to a share button with a custom event, however, there's no click event associated with it.

Screen Shot 2021-07-14 at 10 25 23 AM

### Reproduction Steps

1. Click on the share button
2. Try to use an Custom Event like , navigation, storyNavigation
Example:

document.querySelectorAll('amp-story-player').addEventListener('navigation', (event) => {
console.log('click to share button');
})

### Relevant Logs

_No response_

### Browser(s) Affected

Chrome, Firefox, Safari, Edge, UC Browser

### OS(s) Affected

_No response_

### Device(s) Affected

_No response_

### AMP Version Affected

v0

Contributor guide

Open the contributing guide

Research direction

Start at the amp-story-player entry point and trace how the Share button is handled and which custom events are exposed. Reproduce the issue using the provided navigation and storyNavigation listener example; done means activating Share emits a documented event that listeners can receive across the listed browsers.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript
Domain
frontend
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.