Skip to content

Conversation

newmuis
Copy link
Contributor

@newmuis newmuis commented Sep 19, 2017

This adds the basic structure of a new amp-story extension, per the intent to implement in #11329.

css/amp.css Outdated

amp-story-page {
background-color: #757575;
}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: new line

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done

* amp-story
*/
amp-story, amp-story-page {
display: block;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Static positioning OK? Not relative or absolute? Or is this up to the actual extension amp-story.css?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Static positioning is okay here. Since the height is 100vh and the pages will lay out vertically, we'll start preloading resources for the first few viewports (based on whatever the runtime does by default). When amp-story.css is loaded, it will override this to style the story appropriately.

}

buildCallback() {
this.isExperimentOn_ = isExperimentOn(this.win, TAG);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We just usually do user().assert(isExperimentOn(...), 'enable X experiment'). No need for private vars and such.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done.

{
id: 'amp-story',
name: 'Visual storytelling in AMP',
spec: 'https://github.com/ampproject/amphtml/issues/11329',
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Create cleanup bug and include here as well.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done

@alanorozco alanorozco merged commit a889167 into ampproject:master Sep 28, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants