Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Campaigns + no AMP can cause CSS weirdness #1282

Closed
laurelfulford opened this issue Mar 2, 2021 · 1 comment
Closed

Campaigns + no AMP can cause CSS weirdness #1282

laurelfulford opened this issue Mar 2, 2021 · 1 comment
Labels
[Type] Bug Incorrect behavior or functionality

Comments

@laurelfulford
Copy link
Contributor

This issue may not be best fixed in the theme, but reporting it here to start so we have a record of it:

If you have AMP disabled, and the Campaigns plugin enabled, the Admin toolbar is not aligned at the top of the page on smaller screens. The following styles look to be the culprit:

html.i-amphtml-fie:not(.i-amphtml-inabox) > body, 
html.i-amphtml-singledoc:not(.i-amphtml-inabox) > body {
    position: relative !important;
}

This is similar to an issue that happens with the Homepage Posts blocks, when AMP adds these styles which end up reducing the space underneath the featured images:

.i-amphtml-layout-responsive, 
[layout="responsive"][width][height]:not(.i-amphtml-layout-responsive), 
[width][height][heights]:not([layout]):not(.i-amphtml-layout-responsive), 
[width][height][sizes]:not([layout]):not(.i-amphtml-layout-responsive) {
    display: block;
    position: relative;
}
@laurelfulford laurelfulford added the [Type] Bug Incorrect behavior or functionality label Mar 2, 2021
@adekbadek
Copy link
Member

Automattic/newspack-popups#959 removes loading of AMP runtime on non-AMP pages, so this should be resolved.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Type] Bug Incorrect behavior or functionality
Projects
None yet
Development

No branches or pull requests

2 participants