Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Remove standalone classes
  • Loading branch information
mszylkowski committed Sep 22, 2021
commit 41575d69dfa5f07200335fd6e28fe4488f6217e8
7 changes: 3 additions & 4 deletions extensions/amp-story/1.0/amp-story.css
Original file line number Diff line number Diff line change
Expand Up @@ -76,12 +76,11 @@ amp-story {
touch-action: manipulation !important;
}

html.i-amphtml-story-standalone {
:root {
font-size: calc(2.5 * var(--story-page-vmax, 8px));
}

html.i-amphtml-story-standalone,
html.i-amphtml-story-standalone body {
:root, body {
font-size: calc(2.5 * var(--story-page-vh, 8px));
height: 100% !important;
margin: 0 !important;
Expand Down Expand Up @@ -119,7 +118,7 @@ h6 {
font-size: 0.67rem;
}

html.i-amphtml-story-standalone #i-amphtml-wrapper body {
#i-amphtml-wrapper body {
/** AMP runtime adds a 1px border on iOS iframes, causing the body to be
1px bigger than the viewport. */
border-top: none !important;
Expand Down
2 changes: 0 additions & 2 deletions extensions/amp-story/1.0/amp-story.js
Original file line number Diff line number Diff line change
Expand Up @@ -503,8 +503,6 @@ export class AmpStory extends AMP.BaseElement {
* @private
*/
initializeStandaloneStory_() {
const html = this.win.document.documentElement;
html.classList.add('i-amphtml-story-standalone');
// Lock body to prevent overflow.
this.lockBody_();
// Standalone CSS affects sizing of the entire page.
Expand Down