Amphtml: [amp-story-player] intrinsic layout option missing from validator spec

Created on 4 Dec 2020  路  3Comments  路  Source: ampproject/amphtml

What's the issue?

We realized that the amp-story-player component does not currently allow the intrinsic layout:

https://github.com/ampproject/amphtml/blob/fc76c7607e6aa64e9465527c37f342a105b00947/extensions/amp-story-player/validator-amp-story-player.protoascii#L32-L38

However, the component itself totally supports it and works fine with it:

https://github.com/ampproject/amphtml/blob/731a42a23321c3e6f0fe0208cb3050225a3ae903/extensions/amp-story-player/0.1/amp-story-player.js#L40-L42

https://github.com/ampproject/amphtml/blob/731a42a23321c3e6f0fe0208cb3050225a3ae903/src/layout.js#L153-L163

I could not find an explanation for this in #29327, so it might simply be an oversight.

If it's intended behavior though it would be good to know why, so that we could explore workarounds.

How do we reproduce the issue?

Try using amp-story-player with intrinsic layout and see that it fails AMP validation.

Example:

<amp-story-player width="360" height="600" layout="intrinsic">
    <a href="https://preview.amp.dev/documentation/examples/introduction/stories_in_amp">
        Hello World
    </a>
</amp-story-player>

What browsers are affected?

All browsers

Which AMP version is affected?

Current version (2011200012001 at the time of writing)

Bug stories

All 3 comments

/cc @Enriqe

Yep, I think this was an oversight. Will send out a PR to fix this.

/cc @ampproject/wg-stories

Related: The intrinsic layout was also originally omitted for amp-video, but it has since been added: https://github.com/ampproject/amphtml/pull/28349.

Was this page helpful?
0 / 5 - 0 ratings