-
Notifications
You must be signed in to change notification settings - Fork 384
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
Let amp-live-list for comments be opt-in #1028
Comments
Naturally the |
Thanks @westonruter . |
To test without opt-in, making a comment at: https://paired-ampconfdemo.pantheonsite.io/2018/02/06/are-you-there-lebron-its-me-lebron-a-superstars-ultimate-pep-talk/amp/ Should result in a page refresh with a URL like https://paired-ampconfdemo.pantheonsite.io/2018/02/06/are-you-there-lebron-its-me-lebron-a-superstars-ultimate-pep-talk/amp/?comment=34#comment-34 For a native AMP site where the flag is present, there should be no refresh and instead the Update Comments button should appear to update the live list: https://dev-ampconfdemo.pantheonsite.io/2018/02/06/are-you-there-lebron-its-me-lebron-a-superstars-ultimate-pep-talk/ |
Three issues I see:
|
To test, try commenting on AMP article in paired mode: https://paired-ampconfdemo.pantheonsite.io/2018/02/06/are-you-there-lebron-its-me-lebron-a-superstars-ultimate-pep-talk/amp/ And try commenting on the non-AMP version of the article: https://paired-ampconfdemo.pantheonsite.io/2018/02/06/are-you-there-lebron-its-me-lebron-a-superstars-ultimate-pep-talk/ In both cases, the page should reload after submitting with the comment scrolled into view. Also try commenting on AMP article in native mode: https://dev-ampconfdemo.pantheonsite.io/2018/02/06/are-you-there-lebron-its-me-lebron-a-superstars-ultimate-pep-talk/ |
Request For Testing Hi @csossi, |
yes, will be on this today/tomorrow @kienstra @westonruter |
|
@csossi After submitting the comment, it should look like this with the New Comment(s) button momentarily appearing (within 15 seconds) above the form: Upon clicking the New Comments button it should scroll you up to your posted comment, and look like this: |
We should add a theme support flag for
comments_live_list
to control whether or not comment submission is intercepted. Without flag, default full-page-reload behavior should be retained to allow themes withoutamp-live-list
in comments to work normally.The theme can do:
And then the plugin can read it like this:
This will allow
amp
support to be added to an existing theme without requiring its comments template to be retrofitted withamp-live-list
.Alternatively, if we think that
amp-live-list
should really be the default we want to always be used, then there could instead be an opt-out flag.The text was updated successfully, but these errors were encountered: