Closed bph closed 4 months ago
Just wanted to say that I think this will be super useful. 🚀
I'm going to chip away at this in the coming weeks. Expect progress reports. 🕺
I had a pretty solid demo on my local, but then logged in today and saw there were WP Updates, including three default themes. So, I updated and then I realized I had my custom CSS in the TT4's functions.php
file, which was overwritten by the updates. 🤦 😢
Never mind - I think I've managed to get some of it back. Crisis averted thanks to VS Code's Timeline view
Here are general outline for post:
register_block_style()
and use inline CSS to apply animation. Here is the CSS so far (may need a bit of cleanup)https://github.com/user-attachments/assets/2671822a-7d3b-40eb-91df-360b1945eb05
Overall, this looks like a good plan of action, @colorful-tones.
The one thing I'd suggest is using a block stylesheet over PHP for the CSS, which I feel like would be more realistic for real projects where you'd want syntax highlighting in your code editor: https://developer.wordpress.org/themes/features/block-stylesheets/
I wasn't sure if that was the direction you were going or just using PHP to quickly show the example code via Gist.
This is ready for a first review. https://docs.google.com/document/d/1eVRZSE-d4l6akFNId6-ZzJW5nRvsVVwC-lTNl-Q4cws/edit?usp=sharing
Hey @colorful-tones, what a great tutorial! I'm gonna use this pattern the first chance I get :-)
I tested the code, and made what looks like a lot of suggestions, though it's mostly shifting things around.
Hope it all makes sense. Let me know if you have any questions.
First review done 🥳
@ironnysh thanks for the very thorough review. I've applied most of your feedback. However, there are a few items I left open for discussion. Would you mind taking a peak at the remaining items please, and let me know if we're good to move forward to 2nd draft or if you desire further collaboration? the draft
@bph this is ready for a 2nd review.
One thing I wanted to point out is that it might be good to consider having a code-style guide for writers/contributors to the Dev Blog. CSS nesting came up, and @ironnysh and I had a good discussion about whether we should nest our CSS examples. I also did some outreach on Twitter/X and a few different Slack spaces, and it seems clear that nesting CSS code examples have more potential for misleading and perhaps encouraging poor practices, and we should likely refrain from doing so in tutorials.
My pleasure, @colorful-tones! 💫 And thanks for mentioning the “code-style guide” discussion.
@bph, I thought we might add it to the next editorial meeting agenda, see how people feel about it.
I am done with the 2nd review with minimal comments.
It's a great tutorial. Thank you, Damon.
@colorful-tones Once you are through with the feedback on the reviews, here are the checklists. As a member of the repo, you should be able to check each line item off.
Copy for social post:
Learn to use the Grid block and Cover block to create cards with a 'hover reveal' effect. https://developer.wordpress.org/news/2024/07/30/building-a-card-layout-with-a-hover-reveal-effect
This is ready for pre-publish preview: https://developer.wordpress.org/news/?p=3934&preview=1&_ppp=0018834fc2
Final published resource: https://developer.wordpress.org/news/2024/07/30/building-a-card-layout-with-a-hover-reveal-effect/
Social schedule on Tue, Aug 13, 2024
Discussed in https://github.com/WordPress/developer-blog-content/discussions/203