-
Notifications
You must be signed in to change notification settings - Fork 206
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
Tracking issue for further block editor and full site editing support #940
Comments
Notes regarding full site editing for author archives:
Here is an audit of the core blocks when used in an author archive template:
|
Stopping by with an updated as I continue working on this branch: I pushed things like:
Notes:
|
Since my last comment here I worked on:
I plan to work on avatars next. |
Here's a video where I add coauthor bylines to a query loop on the front page through full site editing. I tried to click around to all the current features. I plan to work on layout settings next. I'm happy for feedback if anyone wants to try out the branch here. cap-blocks-query-loop3.mp4 |
That's looking fantastic! |
@douglas-johnson Excellent demo! You've put a lot of work into customization in-editor and it looks amazing. |
Since my last update I worked on layout settings as planned and tried to figure out how to provide the correct context to blocks used on the author archive. I made a new branch when I started exploring the layout changes. It is available here: master...thoughtis:Co-Authors-Plus:issue#940/coauthor-blocks Using block layoutI this video I use FSE to add Co-Authors to the Post Meta template part within the Single template. It uses the block layout which supports vertical spacing between coauthors. cap-blocks-fse-single.mp4Author archive contextIn this video I add CAP blocks to the author archive template without wrapping them in the Co-Authors block. To support this I added a filter on
You can see that code here: cap-blocks-fse-archive.mp4Up Next
|
Looking amazing! Intuitive, flexible, and just what's been missing all this time! Thank you for doing this. |
Hi @GaryJones and @alecgeatches - I'm stopping by with one more demo. This time its for guest author feature images. master...thoughtis:Co-Authors-Plus:issue#940/coauthor-blocks With this working, I feel we have the intended features. There is still work I would like to do in documentation and developer experience as well as testing and fine tuning. I am out on vacation starting tomorrow and will be back on September 5th. Post editorcap-blocks-feature-image-post.mp4Author archive in site editorcap-blocks-feature-image-archive.mp4New Changes
Work before pull request
|
Amazing 🤩 What's the difference between the Co-Author Avatar and Co-Author Feature Image blocks? |
Avatar uses the avatar system. Its equivalent to calling get_avatar(). There are a limited number of sizes, they are always cropped square and will include Gravatars. Feature Image is for higher resolution images and doesn't have the Gravatar fallback. Since it starts with an attachment id, we can provide the size, cropping and border settings from the core Feature Image block. Its similar to calling wp_get_attachment_image(). |
How does the Co-Author Feature Image block differ from the core Feature Image block? |
The core block needs to be in a post context. The co-author block uses the author context I've set up. It supports resizing, aspect ratios, and border settings, but I didn't incorporate the overlay capability of the core block. |
When will these changes see the light of day? So missing working with the plugin in the block editor :( Very much waiting for the new version! |
Hi @IvanPigarev I'm happy to know someone else wants to use this. I can't promise when it will be released, but I will be back at work September 5th and working on the pull request as soon as possible after that. You are welcome to test with the current branch and provide any feedback. https://github.com/thoughtis/Co-Authors-Plus/tree/issue%23940/coauthor-blocks |
@douglas-johnson The blocks are looking great, and I'd very much like to use them on a project that's launching in a couple months. To that end, please let me know if there's anything specific you'd like to get feedback or thorough testing on, or if there's any other way I can help out! |
Hi @philcable thanks so much for the offer. I would be happy for your feedback on whatever use case is relevant to your project. If you could use the current branch to implement some portion of your project and let me know how it goes that would be great. I am espescially interested to have someone test the ability to make a custom block and extend the REST API data to support whatever unique data is in their custom block. But, I understand that would be an unnecessary time commitment if it's not relevant to your project. |
@philcable I want to send an update in case you are actually trying to add a custom block that uses author data. I just updated the pull request to address some feedback and there are three changes that would need to be reflected in a custom block.
|
Thank you for keeping me posted, @douglas-johnson! I haven't had a chance to test things out just yet, but I'll let you know when I do. |
Any more work happening on this? This is the exact functionality I need, but it seems on the wp.org site that this plugin is more or less abandonded for the last 8 months? I can't contribute with code, but if I can do anything else to help, please let me know. |
@audunmb Great question! @douglas-johnson's work in #997 is essentially done, and it's my fault that this hasn't been merged in yet. We'll get this tested and merged this week. |
@douglas-johnson The next release with your changes is very nearly ready to go in #1032! I'm going to wait until next week to check with @GaryJones and ensure the release is correct, but that should be straightforward. Thank you for all of your hard work and patience, we'll get this in shortly. |
@alecgeatches That's great! I'm looking forward to getting it into production. |
@alecgeatches I imagine we can close this issue. Before we say goodbye to it I wanted to gauge your interest in adding support for Social Icons. We needed this at work and I think I came up with something decent. It can be a separate issue though. Removed AIM, YahooIM and Jabber. Added TikTok, Instagram and Twitter. Kept the website input. Added functions to get URLs. They are forgiving so that either usernames / handles or URLs can be stored. Used those functions to add Added a filter on Now we can drop the Social Icons block into the Co-Authors block, select the services we want to display, and they will be filled in on render based on what data is available for that author. In my example video my Guest Author profile has several filled in, but the other author has none. co-authors-social-icons.mp4 |
Social Icons block is a great idea! +1. |
Continued from #932 cc @alecgeatches
Goal
Improve support for the block editor and full site editing by providing blocks to handle two use cases:
Features
Blocks
Block Editor
Full Site Editing
Layouts
Extensibility
coauthors_guest_author_fields
or should it go through the REST API framework?Features in consideration for future versions
Approach
API
Create two API endpoints intended to GET coauthor data.
GET CoAuthors by
:post-id
Use Case
Request
:post-id
in URLResponse
Authorization
GET CoAuthor by
:author-name
Use Case
Request
:author-name
in URL.cap-
prefix, same as author_name query_var available in author archive requests.Response
Authorization
CoAuthor Objects in API Responses
These objects should have the same shape as the objects returned by
get_coauthors()
, with some notable exceptions.Developer Experience
Use
wp-scripts
with the ability to run a single build command for all blocks and scripts in CAP.Compatibility considerations
The text was updated successfully, but these errors were encountered: