-
Notifications
You must be signed in to change notification settings - Fork 98
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
Implement Offline Commenting #87
Comments
See changes to Workbox background sync in v4: GoogleChrome/workbox#1710 |
Hi @westonruter @alcurrie - I've updated the ACs above based on our meeting today. |
@miina / @jwold - I added a link to the new - design of the Offline template story to this ticket as I think it makes sense to make sure that the design/functionality for the offline template work together with the user interface for the offline templating in AC-2 above. @miina what's the status of that part of the functionality. Do you already have clarity on how that interface will work and link to the Offline template, or would it make sense to AC-2 be broken out to follow-up up on how that interface and user message would appear? |
@alcurrie Thanks for adding the link. To add some background information for AC2: the AC2 in this ticket is for the PWA Plugin and will be part of what will be proposed to merge to WordPress Core. It will leverage the already existing Offline templating system and already existing default design and won't be influenced by the linked ticket for design of the Offline template story, however, the linked ticket will be based on what we're building within this ticket and is dependent on AC2. On status of the functionality part: yes, it's clear how to implement the ticket, no need to break AC-2 to follow-up, thank you for asking. Most of it is already built previously. What we're adding now is the comments-specific messaging for the users and possibility to override it -- overriding will be done by developers only and won't have any user interface. This is how the offline page template for comments is looking like by default -- within the child theme we're going to override this template to show a custom version of it: |
@miina Thanks so much for clarifying and for providing the background and context. It's great to have the details, and the screen shot example. So based on that it sounds like this issue will affect the 'AC2' and the Offline template story not the other way around. I'll update that issue with these details. cc. @jwold |
@miina - I just wanted to flag that @westonruter 's note from #90 (comment) re using the offline page could also to list out the URLs that have been cached for offline access. |
@alcurrie Thanks for bringing that out. Probably we could add listing out URLs as an optional addition if we have time, not as a requirement. Also, this seems to be more generally related to the offline page, not necessarily offline commenting. Or did you mean this specifically related to offline commenting, @westonruter? |
Right, my #90 (comment) is an optional addition, not a requirement. It's not directly related to offline commenting. |
As as WordPress developer, I would like to be able to allow site visitors and admin users add comments to posts even when offline
AC 1: Build comment offline sync functionality into PWA plugin. When viewing a page or post with commenting enabled, a user will be able to make a comment and have that comment saved and posted once the user is back online
AC 2: The user interface for offline commenting will be easy to use and include appropriate messaging. By default the plugin should show an offline page where submitting a comment when offline, with a message like “you are offline, but we will post your comment will be posted when your device comes back online.” This should integrate with the offline template to show custom messages similar to how the
500
page can show custom messages. (See related issue in the twentyseventeen-weston repo, Issue 4 Optimize the design of the Offline/500 page to be more engaging for the user)AC 3: A theme must be able to override the offline template and messaging for commenting failures.
AC 4: Site on Using our AMP and PWA plugins, enable this offline commenting support via a theme declaration.
AC 5: Intercept the amp-form action-xhr request (to submit the form) and when failed return a custom success message to be shown below the form
Offline Routing and messaging
For reference, here was the original PR from the AMP plugin:
ampproject/amp-wp#1028
The text was updated successfully, but these errors were encountered: