Skip to content
This repository was archived by the owner on Nov 18, 2024. It is now read-only.

Add news blog and archive query loop pattern#284

Merged
carolinan merged 7 commits intoWordPress:trunkfrom
dballari:add-news-blog-and-archive-query-loop-pattern
Sep 14, 2024
Merged

Add news blog and archive query loop pattern#284
carolinan merged 7 commits intoWordPress:trunkfrom
dballari:add-news-blog-and-archive-query-loop-pattern

Conversation

@dballari
Copy link
Copy Markdown
Contributor

Description

This PR solves the issue #275

Screenshots

Captura de pantalla 2024-09-12 a las 13 19 30
Captura de pantalla 2024-09-12 a las 13 19 25

Testing Instructions

  1. Temporarily modify archive and search templates by templates that only contain the news blog archive pattern and the news blog search result pattern respectively
  2. This is achived by adding this code and respectively
  3. perform a search and visit an archive page
  4. Results must be like screenshots provided

@github-actions
Copy link
Copy Markdown

github-actions bot commented Sep 12, 2024

The following accounts have interacted with this PR and/or linked issues. I will continue to update these lists as activity occurs. You can also manually ask me to refresh this list by adding the props-bot label.

Unlinked Accounts

The following contributors have not linked their GitHub and WordPress.org accounts: @davidbp845@riseup.net.

Contributors, please read how to link your accounts to ensure your work is properly credited in WordPress releases.

If you're merging code through a pull request on GitHub, copy and paste the following into the bottom of the merge commit message.

Unlinked contributors: davidbp845@riseup.net.

Co-authored-by: dballari <dballari@git.wordpress.org>
Co-authored-by: carolinan <poena@git.wordpress.org>
Co-authored-by: KevinTaron <ktaron@git.wordpress.org>
Co-authored-by: beafialho <beafialho@git.wordpress.org>

To understand the WordPress project's expectations around crediting contributors, please review the Contributor Attribution page in the Core Handbook.

@juanfra juanfra added the [Type] Bug An existing feature does not function as intended. label Sep 12, 2024
@KevinTaron
Copy link
Copy Markdown
Contributor

Hey @dballari - I noticed the new footer-newsletter is not added to the theme.json - I think it should be added as a templatePart in theme.json

@dballari
Copy link
Copy Markdown
Contributor Author

Hi @KevinTaron yes you are right. Thanks a lot. I just added it.

@carolinan
Copy link
Copy Markdown
Contributor

Why is the template part needed instead of just using the correct pattern directly?

@carolinan
Copy link
Copy Markdown
Contributor

Ignore the question, I will assume it is for consistency with the other templates.

@dballari
Copy link
Copy Markdown
Contributor Author

Why is the template part needed instead of just using the correct pattern directly?

Hi @carolinan in the begining I did not think of it, I just did it for consistency, but now I'm thinking: we should be able to create new templates from the editor, right? not just from the code, and then for instance if we want a template for a certain category it will be nice to be able to add the footer newsletter template part as a template part, no just a pattern right? Anyway, there is something I'm missing here, I do not now how to retrieve the news blog templates from the editor ... I have a lot to learn here. I will be working on this until I fully understand how it works

@carolinan
Copy link
Copy Markdown
Contributor

I can help with that.

From the Site editor menu, -the dark grey sidebar, go to Templates.
To test the Archive, select archive, to test Home, select home, and so on.

While editing the template, you may first need to reset it: Because the editor does not actually show which pattern is currently used.
Open the settings sidebar.
Select the Template tab, not the block tab.
Next to the template name there is a menu with three dots. If there is anything to reset, it can be reset there.

Below the description is the Content panel. Skip this and open the next panel, Design.
All patterns for the selected template shows there.
Hover over them to see the pattern name, if needed (this may require Gutenberg, I don't remember for sure).
Click on the pattern you want to test.
This replaces the current content in the template with the selected pattern.
Save.
View the page on the front.

@carolinan
Copy link
Copy Markdown
Contributor

We have a design approval, the issue with the closing group block has been fixed, and all the templates have the footer updated, so lets merge this.

@carolinan carolinan merged commit ea32cf9 into WordPress:trunk Sep 14, 2024
@dballari dballari deleted the add-news-blog-and-archive-query-loop-pattern branch September 18, 2024 07:46
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

[Type] Bug An existing feature does not function as intended.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

News blog archive and News blog search results are referencing missing patterns.

4 participants