Skip to content

[I2D&R] Tweet lightbox within Stories #36353

@gmajoulet

Description

@gmajoulet

Summary

Within a Web Story, publishers can embed tweets using amp-twitter.
There are several ways to embed a tweet:

  1. amp-twitter[interactive]
    The tweet is (a) displayed inside a Story page, (b) opens a tooltip on tap, and (c) is expanded inside a lightbox: example.
    We want to keep parts (a) and (b), but deprecate the lightbox (c) part, and replace it with a hard navigation to the URL of the tweet. This would be consistent with other links (<a) within Stories.

  2. amp-twitter
    No change: amp-twitter without the interactive attribute are unimpacted. The tweet loads and is visible but users can't interact with it.

  3. No change: amp-twitter within a page-attachment
    No change, tweets load within the page attachment and users can interact with them.

Motivation

The feature brought a lot of complexity to the codebase, and was built to support more embeds like videos (e.g. YouTube) or music (e.g. Spotify or SoundCloud). We have no plans to build these new embeds as they present various UX and/or technical limitations, and have very little to no adoption for amp-twitter[interactive].

Downgrading the lightbox to a hard navigation to the tweet would allow us to simplify a lot of code paths, and reduce bundle size.

Impact on Existing Users

Tweets configured with [interactive] will no longer open inside a lightbox in the Story, but will navigate to either the tweet web page, or the Twitter native app.

Alternative Implementation

To allow users to interact with amp-twitter directly within a Web Story, publishers can embed the tweet within a page attachment.

Additional Context

No response

Notifications

/cc @ampproject/wg-approvers @ampproject/wg-stories

Metadata

Metadata

Assignees

Labels

INTENT TO DEPRECATEProposes deprecating an existing AMP feature.INTENT TO REMOVEProposes removing a deprecated AMP feature. Use after the INTENT TO DEPRECATE.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions