Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
131 commits
Select commit Hold shift + click to select a range
099db0a
WIP: issue-353
efuller Aug 12, 2025
fe7a56a
Only display selected post types when using PostPicker
efuller Aug 12, 2025
fe4953c
Ready for review
efuller Aug 12, 2025
65820d0
Remove a test custom post type
efuller Aug 12, 2025
f499476
WIP: issue-377
mogmarsh Sep 30, 2025
f0792f9
npm audit
mogmarsh Sep 30, 2025
096d1dc
adding SearchFilters
mogmarsh Sep 30, 2025
4e2c22c
Merge remote-tracking branch 'origin/feature/issue-353/postpicker-mod…
mogmarsh Sep 30, 2025
43eb14c
working in sidebar. not yet working in block
mogmarsh Sep 30, 2025
4856c87
fix post block filters
mogmarsh Oct 1, 2025
5aae737
fix backfill issue
mogmarsh Oct 1, 2025
4775479
merging in develop
mogmarsh Oct 8, 2025
08f302c
single checkbox - need to fix post types and TS for term
mogmarsh Oct 8, 2025
e2d4137
fix post types and typescript types
mogmarsh Oct 8, 2025
b18b526
fix shouldShowFilter logic
mogmarsh Oct 8, 2025
f99f028
Ready for review
mogmarsh Oct 8, 2025
f11f7c0
phpcs
mogmarsh Oct 8, 2025
cfb9b16
language change
mogmarsh Oct 8, 2025
303067f
phpcs and phpstan
mogmarsh Oct 8, 2025
bce6e14
WIP: TECH-208
mogmarsh Oct 8, 2025
ba9f2c0
building out layout selection
mogmarsh Oct 9, 2025
6a363ac
debugging previews
mogmarsh Oct 10, 2025
0804ee6
Bump ts-jest from 29.4.4 to 29.4.5
dependabot[bot] Oct 11, 2025
4bfac40
Merge pull request #397 from alleyinteractive/dependabot/npm_and_yarn…
github-actions[bot] Oct 11, 2025
b2bbdcb
Bump stefanzweifel/git-auto-commit-action from 6 to 7
dependabot[bot] Oct 13, 2025
21a42b6
Merge pull request #398 from alleyinteractive/dependabot/github_actio…
github-actions[bot] Oct 13, 2025
09f5d3b
Merge pull request #389 from alleyinteractive/feature/issue-377/postp…
mogmarsh Oct 13, 2025
c4d5b56
default query
mogmarsh Oct 13, 2025
8f72dd0
fix errors and preview display
mogmarsh Oct 13, 2025
fea6b61
fix pattern
mogmarsh Oct 13, 2025
38d63c3
merging in develop and updating packages
mogmarsh Oct 13, 2025
f20ede5
pattern selection working
mogmarsh Oct 13, 2025
d85f64a
linting
mogmarsh Oct 14, 2025
47f19e2
fix linting
mogmarsh Oct 14, 2025
3eb4244
adding files
mogmarsh Oct 14, 2025
7318658
some cleanup
mogmarsh Oct 14, 2025
803075c
more cleanup
mogmarsh Oct 14, 2025
23ab757
more cleanup
mogmarsh Oct 15, 2025
cdc8fcc
Ready for review
mogmarsh Oct 15, 2025
4e9ab31
phcps
mogmarsh Oct 15, 2025
3f159dc
phpstan
mogmarsh Oct 15, 2025
0cd8019
phpcs again
mogmarsh Oct 15, 2025
16fca37
remove layout
mogmarsh Oct 15, 2025
2355a40
add text align support to post title
kaitlinbolling Oct 15, 2025
044a7e6
Merge pull request #402 from alleyinteractive/feature/add-title-text-…
kaitlinbolling Oct 15, 2025
d216a1d
version and release notes
mogmarsh Oct 15, 2025
0affeb5
revise release notes
mogmarsh Oct 15, 2025
c384cd2
Merge pull request #403 from alleyinteractive/release/2.7.2
mogmarsh Oct 15, 2025
33cdb0a
added two real layouts
mogmarsh Oct 15, 2025
20290e9
Merge remote-tracking branch 'origin/develop' into feature/TECH-208/a…
mogmarsh Oct 15, 2025
4771cc2
useful patterns and variations
mogmarsh Oct 15, 2025
e14bfce
add another variation
mogmarsh Oct 16, 2025
3a5b119
basic functionality working in the editor
mogmarsh Oct 16, 2025
837d841
making post template and non-post template work together
mogmarsh Oct 17, 2025
53f600b
working in the editor
mogmarsh Oct 17, 2025
bc45c10
Bump dompurify from 3.2.7 to 3.3.0
dependabot[bot] Oct 18, 2025
298feb4
Merge pull request #404 from alleyinteractive/dependabot/npm_and_yarn…
github-actions[bot] Oct 18, 2025
9c6660a
fix admin post count. starting front end fixes
mogmarsh Oct 20, 2025
d23e165
fix index bugs
mogmarsh Oct 21, 2025
beed862
merging in develop
mogmarsh Oct 21, 2025
f8a8097
Merge remote-tracking branch 'origin/feature/TECH-208/add-layout-sele…
mogmarsh Oct 21, 2025
7876815
Merge remote-tracking branch 'origin/feature/TECH-208/add-real-layout…
mogmarsh Oct 21, 2025
26ab8df
still attempting rendering
mogmarsh Oct 21, 2025
e15e6e9
restoring php files
mogmarsh Oct 21, 2025
b8c95c0
switch patterns to use blocks not css
mogmarsh Oct 21, 2025
565d453
clean up stylesheet
mogmarsh Oct 21, 2025
87b1d61
front end rendering matches editor
mogmarsh Oct 22, 2025
4e76bab
phcps
mogmarsh Oct 22, 2025
85d33c1
Upgrading to PHPStan 2.0, adjusting tests
srtfisher Oct 23, 2025
c9b5461
CHANGELOG
srtfisher Oct 23, 2025
ef1dffa
fix click to move
mogmarsh Oct 24, 2025
5064b77
fix hover style
mogmarsh Oct 24, 2025
f07414c
fix subquery
mogmarsh Oct 24, 2025
2308b49
restore the parameters to mainDedupe)
mogmarsh Oct 24, 2025
98a3412
pass the right window context stuff to the mainDedupe function so it …
mogmarsh Oct 24, 2025
104e8ed
Bump @alleyinteractive/build-tool from 0.2.2 to 0.3.0
dependabot[bot] Oct 25, 2025
c771060
Bump @babel/preset-env from 7.28.3 to 7.28.5
dependabot[bot] Oct 25, 2025
afe11c3
Merge pull request #411 from alleyinteractive/dependabot/npm_and_yarn…
github-actions[bot] Oct 25, 2025
f7fb8a6
Merge pull request #412 from alleyinteractive/dependabot/npm_and_yarn…
github-actions[bot] Oct 25, 2025
0245e41
adjust number of posts in default query
mogmarsh Oct 27, 2025
dd5637a
fix block preview
mogmarsh Oct 27, 2025
5f0c439
Remove post meta
srtfisher Oct 27, 2025
f169287
Merge branch 'develop' into feature/168-phpstan-2-0
srtfisher Oct 27, 2025
b18c221
Merge pull request #407 from alleyinteractive/feature/168-phpstan-2-0
srtfisher Oct 27, 2025
303ffff
Apply suggestions from code review
mogmarsh Oct 27, 2025
d1acb62
merge in develop
mogmarsh Oct 27, 2025
6774aaf
updating npm and composer
mogmarsh Oct 27, 2025
da5aa40
code review feedback
mogmarsh Oct 27, 2025
47d2c2f
Merge remote-tracking branch 'origin/feature/TECH-208/add-layout-sele…
mogmarsh Oct 27, 2025
9c45fc9
Merge remote-tracking branch 'origin/feature/TECH-208/remove-post-tem…
mogmarsh Oct 27, 2025
fb492a6
Adding tests for existing functionality (#410)
srtfisher Oct 27, 2025
d23ea6e
Merge branch 'develop' into feature/TECH-208/add-layout-selection-to-…
srtfisher Oct 27, 2025
d17cdd6
fix passing blocks to dedupe. fix linting errors
mogmarsh Oct 27, 2025
c214cdb
type BlockEditorDispatch
mogmarsh Oct 28, 2025
6611c6d
Merge pull request #406 from alleyinteractive/feature/TECH-208/remove…
mogmarsh Oct 28, 2025
1aec0b4
Merge pull request #413 from alleyinteractive/feature/TECH-208/fix-pr…
mogmarsh Oct 28, 2025
784ead2
Merge remote-tracking branch 'origin/develop' into feature/TECH-208/a…
mogmarsh Oct 28, 2025
ac218ae
Merge remote-tracking branch 'origin/feature/TECH-208/add-layout-sele…
mogmarsh Oct 28, 2025
5ad1163
exclude class-block-index.php from phpstan
mogmarsh Oct 28, 2025
449084a
bump to version 3.0.0
mogmarsh Oct 28, 2025
3cbadeb
remove parameters from mainDedupe as they don't fix anything
mogmarsh Oct 29, 2025
3456888
put blocks back where it was
mogmarsh Oct 29, 2025
aa9747c
WIP: TECH-225
jakewrfoster Oct 30, 2025
eb8697f
Merge pull request #396 from alleyinteractive/feature/TECH-208/add-la…
mogmarsh Oct 31, 2025
1a470b6
add notices script and prevent unselecting last checkbox in post type…
jakewrfoster Oct 31, 2025
c935d26
udpte comment
jakewrfoster Oct 31, 2025
5fbaed5
Bump @alleyinteractive/build-tool from 0.1.6 to 0.3.0
dependabot[bot] Nov 1, 2025
af6e498
Bump wp-types from 4.68.1 to 4.68.3
dependabot[bot] Nov 1, 2025
810d0ba
Merge pull request #419 from alleyinteractive/dependabot/npm_and_yarn…
github-actions[bot] Nov 1, 2025
29eef04
Merge pull request #420 from alleyinteractive/dependabot/npm_and_yarn…
github-actions[bot] Nov 1, 2025
c6725ed
merge develop into 225
jakewrfoster Nov 3, 2025
391aeb9
update lock file
jakewrfoster Nov 4, 2025
122806c
Merge pull request #417 from alleyinteractive/feature/TECH-225/post-t…
jakewrfoster Nov 5, 2025
31a7374
Bump @types/wordpress__edit-post from 7.5.7 to 8.4.2
dependabot[bot] Nov 8, 2025
465553a
Merge pull request #422 from alleyinteractive/dependabot/npm_and_yarn…
github-actions[bot] Nov 8, 2025
bed2317
Bump @types/wordpress__block-editor from 11.5.17 to 14.21.2
dependabot[bot] Nov 8, 2025
339785f
Merge pull request #421 from alleyinteractive/dependabot/npm_and_yarn…
github-actions[bot] Nov 8, 2025
796c108
Add linting and tsc to test step
srtfisher Nov 11, 2025
28d53e9
Appeasing eslint
srtfisher Nov 11, 2025
76b78e2
Fixing stylelint
srtfisher Nov 11, 2025
4e87d55
Mirror cwp on deployignore
srtfisher Nov 11, 2025
990c920
Shuffle to dev
srtfisher Nov 11, 2025
fbc0cd3
Merge pull request #423 from alleyinteractive/hotfix/414-js-linting
srtfisher Nov 11, 2025
fc517b3
Allow pinning scheduled posts
dlh01 Nov 9, 2025
77d0440
Merge branch 'develop' into feature/GH-399/scheduled-posts
dlh01 Nov 12, 2025
ce700a5
Fix import
dlh01 Nov 12, 2025
8418afe
Spacin'
dlh01 Nov 12, 2025
1755b42
Merge pull request #426 from alleyinteractive/feature/GH-399/schedule…
dlh01 Nov 12, 2025
949046d
Bump @alleyinteractive/stylelint-config from 0.0.2 to 0.1.0
dependabot[bot] Nov 15, 2025
db9ffaf
Merge pull request #427 from alleyinteractive/dependabot/npm_and_yarn…
github-actions[bot] Nov 15, 2025
5e85ab8
Merge branch 'develop' into update-fam-latest
efuller Nov 17, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
33 changes: 21 additions & 12 deletions .deployignore
Original file line number Diff line number Diff line change
@@ -1,22 +1,31 @@
.DS_Store
Thumbs.db
wp-cli.local.yml
node_modules/
.github
.phpcs
.phpcs.xml
.phpunit.result.cache
.scaffolder
.scoper
.wp-env.json
*.sql
*.tar.gz
*.zip
.phpunit.result.cache
Dockerfile
output.log
.github
tests
babel.config.js
bin
composer.lock
.phpcs.xml
phpunit.xml
configure.php
DOCKER_ENV
Dockerfile
jest.config.js
Makefile
node_modules/
output.log
phpstan.neon
phpunit.xml
.phpunit-watcher.yml
rector.php
tests
.phpcs
Makefile
tests
Thumbs.db
tsconfig.eslint.json
tsconfig.json
wp-cli.local.yml
16 changes: 15 additions & 1 deletion .github/workflows/all-pr-tests.yml
Original file line number Diff line number Diff line change
@@ -1,25 +1,39 @@
name: "All Pull Request Tests"

on:
push:
branches:
- develop
pull_request:
branches:
- develop
types: [opened, synchronize, reopened, ready_for_review]

jobs:
find-wordpress-versions:
runs-on: ubuntu-latest
outputs:
versions: ${{ steps.get-versions.outputs.versions }}
steps:
- name: Get WordPress Versions
id: get-versions
run: echo "versions=$(curl -s https://api.wordpress.org/core/version-check/1.7/ | jq -r '.offers[] | select(.response == "autoupdate").version' | head -n 3 | sort -u | sed 's/\.[^.]*$//' | jq -R -s -c 'split("\n")[:-1]')" >> $GITHUB_OUTPUT

# We use a single job to ensure that all steps
# run in the same environment and reduce the number of minutes used.
pr-tests:
# Don't run on draft PRs
if: github.event.pull_request.draft == false
needs: find-wordpress-versions
runs-on: ubuntu-latest
# Timeout after 10 minutes
timeout-minutes: 10
# Define a matrix of PHP/WordPress versions to test against
strategy:
fail-fast: false
matrix:
php: [8.2, 8.3, 8.4]
wordpress: ["latest"]
wordpress: ${{fromJson(needs.find-wordpress-versions.outputs.versions)}}
# Cancel any existing runs of this workflow
concurrency:
group: ${{ github.workflow }}-${{ github.event_name }}-${{ github.event.pull_request.number || github.ref }}-P${{ matrix.php }}-WP${{ matrix.wordpress }}
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/update-changelog.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ jobs:
release-notes: ${{ github.event.release.body }}

- name: Commit updated CHANGELOG
uses: stefanzweifel/git-auto-commit-action@v6
uses: stefanzweifel/git-auto-commit-action@v7
with:
branch: main
commit_message: Update CHANGELOG
Expand Down
4 changes: 4 additions & 0 deletions .phpcs.xml
Original file line number Diff line number Diff line change
Expand Up @@ -61,4 +61,8 @@
<rule ref="WordPress.Files">
<exclude-pattern>tests/*</exclude-pattern>
</rule>

<rule ref="Squiz.PHP.DisallowMultipleAssignments.Found">
<exclude-pattern>tests/*</exclude-pattern>
</rule>
</ruleset>
5 changes: 5 additions & 0 deletions .stylelintignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
node_modules/

# Client build files
client/build/
/vendor
20 changes: 20 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,26 @@

All notable changes to `WP Curate` will be documented in this file.

## Unreleased

- Enhancement: Enable pinning scheduled posts via `wp_curate_include_future_posts` filter.

## 3.0.0 - 2025-10-31

- Support for previews of Query block and Patterns.
- Pattern/Variation picker when inserting a Query block.
- Post blocks can now exist outside of Post Template blocks, allowing for more complex layouts
and individual inner blocks on the Post block.
- Upgrade to PHPStan to 2.0.
- Added unit tests for existing plugin functionality.

## 2.7.2 - 2025-10-15

- Enhancement: Post Picker results filtered to match Query block parameters by default.
- Enhancement: Text alignment support in Post Title block.
- Bug fix: Fix issue where reducing number of posts caused some posts to be hidden in the editor.
- Bug fix: Fix PHP warnings.

## 2.7.1 - 2025-10-01

- Enhancement: Add option to "Pin This Post" so editors can pin the selected post.
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# WP Curate

[![All Pull Request Tests](https://github.com/alleyinteractive/wp-curate/actions/workflows/all-pr-tests.yml/badge.svg)](https://github.com/alleyinteractive/wp-curate/actions/workflows/all-pr-tests.yml)
[![All Pull Request Tests](https://github.com/alleyinteractive/wp-curate/actions/workflows/all-pr-tests.yml/badge.svg?branch=develop)](https://github.com/alleyinteractive/wp-curate/actions/workflows/all-pr-tests.yml)

A plugin for WordPress to build flexible, curatable layouts for homepages and landing pages.

Expand Down
5 changes: 4 additions & 1 deletion blocks/post-title/block.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,9 @@
},
"render": "file:render.php",
"supports": {
"inserter": false
"inserter": true,
"typography": {
"textAlign": true
}
}
}
12 changes: 8 additions & 4 deletions blocks/post-title/edit.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ interface PostTitleEditProps {
include?: string;
orderby?: string;
};
pinnedPosts?: Array<number>;
pinnedPosts?: Array<number | null>;
customPostTitles?: {
postId: number;
title: string;
Expand All @@ -46,13 +46,13 @@ export default function Edit({
const queryParentId = queryParentIds.length ? queryParentIds[queryParentIds.length - 1] : null;

const {
postId,
postId = null,
pinnedPosts = [],
query: { postType = 'post' },
query: { postType = 'post' } = {},
customPostTitles = [],
} = context;
const { level = 3, supportsLevel } = attributes;
const [rawTitle = '', , fullTitle] = useEntityProp('postType', postType, 'title', postId.toString());
const [rawTitle = '', , fullTitle] = useEntityProp('postType', postType, 'title', postId?.toString());
const isPinned = pinnedPosts.includes(postId);
const currentCustomPostTitle = customPostTitles.find((item) => item?.postId === postId);
const TagName = !supportsLevel || level === 0 ? 'p' : `h${level}`;
Expand All @@ -74,6 +74,10 @@ export default function Edit({
}, [isPinned, postId, customPostTitles, currentCustomPostTitle, setAttributes, queryParentId]);

const handleOnChange = (title: string) => {
if (!postId) {
return;
}

/**
* Handle case for removing custom title from the collection if a
* custom title no longer exists.
Expand Down
8 changes: 5 additions & 3 deletions blocks/post-title/render.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,13 +13,15 @@
* @package wp-curate
*/

$current_post_id = intval( $block->context['postId'] );
use function Mantle\Support\Helpers\mixed;

$current_post_id = mixed( $block->context['postId'] )->int();

if ( empty( $current_post_id ) ) {
return;
}

$custom_post_titles = ! empty( $block->context['customPostTitles'] ) ? $block->context['customPostTitles'] : [];
$custom_post_titles = ! empty( $block->context['customPostTitles'] ) && is_array( $block->context['customPostTitles'] ) ? $block->context['customPostTitles'] : [];
$post_title = get_the_title( $current_post_id );
$post_link = get_the_permalink( $current_post_id );
$level = is_int( $attributes['level'] ) ? intval( $attributes['level'] ) : 0;
Expand All @@ -32,7 +34,7 @@
// Use custom post title, if available.
if ( 0 < count( $custom_post_titles ) ) {
foreach ( $custom_post_titles as $value ) {
if ( $value['postId'] === $current_post_id ) {
if ( is_array( $value ) && isset( $value['postId'] ) && $value['postId'] === $current_post_id && is_string( $value['title'] ) ) {
$post_title = $value['title'];
break;
}
Expand Down
8 changes: 7 additions & 1 deletion blocks/post/block.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,13 +13,19 @@
"style": [
"file:style-index.css"
],
"attributes": {
"index": {
"type": "number"
}
},
"usesContext": [
"allPostIds",
"postId",
"query",
"moveData"
],
"render": "file:render.php",
"supports": {
"inserter": false
"inserter": true
}
}
Loading