From 93848c7d8621ed237d1bece6fa942fd129d7b526 Mon Sep 17 00:00:00 2001 From: jeremyfelt Date: Sat, 1 Aug 2026 10:16:10 -0700 Subject: [PATCH 1/3] Use the consolidated PHP and JavaScript check workflows Replaces the single-purpose check workflows with the consolidated php-checks and js-checks workflows from happyprime/workflows. Co-Authored-By: Claude Opus 5 (1M context) --- .github/workflows/js-checks.yml | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) create mode 100644 .github/workflows/js-checks.yml diff --git a/.github/workflows/js-checks.yml b/.github/workflows/js-checks.yml new file mode 100644 index 0000000..2a5fcee --- /dev/null +++ b/.github/workflows/js-checks.yml @@ -0,0 +1,23 @@ +# Run ESLint, Stylelint, package.json linting, and unit tests in a single job. +# +# Each check runs only when the project defines an npm script for it, so this +# file is safe to sync to a repository that has only some of them. A check the +# project is half set up for is reported on the pull request rather than failed. +# +# This file is managed in https://github.com/happyprime/projects +name: JavaScript checks + +on: pull_request + +# The consolidated workflow comments on the pull request when a project is set +# up for a check it cannot run. A workflow level permissions block caps what a +# reusable workflow receives, so the write scope is granted here. +permissions: + contents: read + pull-requests: write + +jobs: + call-workflow: + uses: happyprime/workflows/.github/workflows/js-checks.yml@trunk + with: + node-version: 24 From f7f8b6aa223145ab27756b919dee9d72e4813deb Mon Sep 17 00:00:00 2001 From: jeremyfelt Date: Sat, 1 Aug 2026 12:07:06 -0700 Subject: [PATCH 2/3] Add package.json linting and refresh check tooling - version='1.0.0' - keywords=['wordpress', 'wordpress-plugin'] - homepage='https://github.com/happyprime/query-filter/' - repository='github' - bugs='https://github.com/happyprime/query-filter/issues' - lint:package added - devDeps: npm-package-json-lint, @wordpress/npm-package-json-lint-config - npmpackagejsonlint config added Co-Authored-By: Claude Opus 5 (1M context) --- package-lock.json | 107 ++++++++++++++++++++++++++++++++++++++-------- package.json | 33 +++++++++++--- 2 files changed, 116 insertions(+), 24 deletions(-) diff --git a/package-lock.json b/package-lock.json index 6e6203b..a4928a3 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,13 +1,19 @@ { "name": "query-loop-filter", + "version": "1.0.0", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "query-loop-filter", + "version": "1.0.0", "license": "GPL-2.0-or-later", "dependencies": { "@wordpress/scripts": "^28.6.0" + }, + "devDependencies": { + "@wordpress/npm-package-json-lint-config": "^5.10.0", + "npm-package-json-lint": "^8.0.0" } }, "node_modules/@ampproject/remapping": { @@ -4022,9 +4028,10 @@ } }, "node_modules/@wordpress/npm-package-json-lint-config": { - "version": "5.7.0", - "resolved": "https://registry.npmjs.org/@wordpress/npm-package-json-lint-config/-/npm-package-json-lint-config-5.7.0.tgz", - "integrity": "sha512-D2hjkL4lVgQ60JdyRY5od8PqiPquGaxHjk3MN0AyGcw42jYcuvN7+lDM/FHr4GVJpa0CGKey6Qe56UMiBBMUQw==", + "version": "5.52.0", + "resolved": "https://registry.npmjs.org/@wordpress/npm-package-json-lint-config/-/npm-package-json-lint-config-5.52.0.tgz", + "integrity": "sha512-+3fv1jmdmsvSIhlZ2PpYKVQ6VQ1zKJFMTbHoJKSSiUA0Os5ASgAAH6S/+s4B0EGHZ94G3SV3k8oaiOnwOghE5Q==", + "license": "GPL-2.0-or-later", "engines": { "node": ">=18.12.0", "npm": ">=8.19.2" @@ -4139,6 +4146,68 @@ "react-dom": "^18.0.0" } }, + "node_modules/@wordpress/scripts/node_modules/jsonc-parser": { + "version": "3.3.1", + "resolved": "https://registry.npmjs.org/jsonc-parser/-/jsonc-parser-3.3.1.tgz", + "integrity": "sha512-HUgH65KyejrUFPvHFPbqOY0rsFip3Bo5wb4ngvdi1EpCYWUQDC5V+Y7mZws+DLkr4M//zQJoanu1SP+87Dv1oQ==", + "license": "MIT" + }, + "node_modules/@wordpress/scripts/node_modules/npm-package-json-lint": { + "version": "6.4.0", + "resolved": "https://registry.npmjs.org/npm-package-json-lint/-/npm-package-json-lint-6.4.0.tgz", + "integrity": "sha512-cuXAJJB1Rdqz0UO6w524matlBqDBjcNt7Ru+RDIu4y6RI1gVqiWBnylrK8sPRk81gGBA0X8hJbDXolVOoTc+sA==", + "license": "MIT", + "dependencies": { + "ajv": "^6.12.6", + "ajv-errors": "^1.0.1", + "chalk": "^4.1.2", + "cosmiconfig": "^8.0.0", + "debug": "^4.3.4", + "globby": "^11.1.0", + "ignore": "^5.2.0", + "is-plain-obj": "^3.0.0", + "jsonc-parser": "^3.2.0", + "log-symbols": "^4.1.0", + "meow": "^9.0.0", + "plur": "^4.0.0", + "semver": "^7.3.8", + "slash": "^3.0.0", + "strip-json-comments": "^3.1.1", + "type-fest": "^3.2.0", + "validate-npm-package-name": "^5.0.0" + }, + "bin": { + "npmPkgJsonLint": "dist/cli.js" + }, + "engines": { + "node": ">=14.0.0", + "npm": ">=6.0.0" + } + }, + "node_modules/@wordpress/scripts/node_modules/semver": { + "version": "7.8.5", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.8.5.tgz", + "integrity": "sha512-Y7/KDsb8LjooZpwaqGyulO6DQlksgCncchHGk+sZIY4SBvUocMBEFH5Ur1fI4dV+Jvl0w6cjvucaIi40puRioA==", + "license": "ISC", + "bin": { + "semver": "bin/semver.js" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/@wordpress/scripts/node_modules/type-fest": { + "version": "3.13.1", + "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-3.13.1.tgz", + "integrity": "sha512-tLq3bSNx+xSpwvAJnzrK0Ep5CLNWjvFTOp71URMaAEWBfRb9nnJiBoUe0tF8bI4ZFO3omgBR6NvnbzVUT3Ly4g==", + "license": "(MIT OR CC0-1.0)", + "engines": { + "node": ">=14.16" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, "node_modules/@wordpress/stylelint-config": { "version": "22.7.0", "resolved": "https://registry.npmjs.org/@wordpress/stylelint-config/-/stylelint-config-22.7.0.tgz", @@ -11776,34 +11845,35 @@ "integrity": "sha512-EPfafl6JL5/rU+ot6P3gRSCpPDW5VmIzX959Ob1+ySFUuuYHWHekXpwdUZcKP5C+DS4GEtdJluwBjnsNDl+fSA==" }, "node_modules/npm-package-json-lint": { - "version": "6.4.0", - "resolved": "https://registry.npmjs.org/npm-package-json-lint/-/npm-package-json-lint-6.4.0.tgz", - "integrity": "sha512-cuXAJJB1Rdqz0UO6w524matlBqDBjcNt7Ru+RDIu4y6RI1gVqiWBnylrK8sPRk81gGBA0X8hJbDXolVOoTc+sA==", + "version": "8.0.0", + "resolved": "https://registry.npmjs.org/npm-package-json-lint/-/npm-package-json-lint-8.0.0.tgz", + "integrity": "sha512-44xqAKoV0nXnBYYLGUhMItGZb5tW3cLoW3UZxcsaCOX/YAkECrzOQA5F48oAA51vVE5CqAnsJB2CFvtolzMA3Q==", + "license": "MIT", "dependencies": { "ajv": "^6.12.6", "ajv-errors": "^1.0.1", "chalk": "^4.1.2", - "cosmiconfig": "^8.0.0", + "cosmiconfig": "^8.3.6", "debug": "^4.3.4", "globby": "^11.1.0", - "ignore": "^5.2.0", + "ignore": "^5.3.1", "is-plain-obj": "^3.0.0", - "jsonc-parser": "^3.2.0", + "jsonc-parser": "^3.2.1", "log-symbols": "^4.1.0", "meow": "^9.0.0", "plur": "^4.0.0", - "semver": "^7.3.8", + "semver": "^7.6.2", "slash": "^3.0.0", "strip-json-comments": "^3.1.1", - "type-fest": "^3.2.0", - "validate-npm-package-name": "^5.0.0" + "type-fest": "^4.20.0", + "validate-npm-package-name": "^5.0.1" }, "bin": { "npmPkgJsonLint": "dist/cli.js" }, "engines": { - "node": ">=14.0.0", - "npm": ">=6.0.0" + "node": ">=18.0.0", + "npm": ">=9.0.0" } }, "node_modules/npm-package-json-lint/node_modules/jsonc-parser": { @@ -11823,11 +11893,12 @@ } }, "node_modules/npm-package-json-lint/node_modules/type-fest": { - "version": "3.13.1", - "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-3.13.1.tgz", - "integrity": "sha512-tLq3bSNx+xSpwvAJnzrK0Ep5CLNWjvFTOp71URMaAEWBfRb9nnJiBoUe0tF8bI4ZFO3omgBR6NvnbzVUT3Ly4g==", + "version": "4.41.0", + "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-4.41.0.tgz", + "integrity": "sha512-TeTSQ6H5YHvpqVwBRcnLDCBnDOHWYu7IvGbHT6N8AOymcr9PJGjc1GTtiWZTYg0NCgYwvnYWEkVChQAr9bjfwA==", + "license": "(MIT OR CC0-1.0)", "engines": { - "node": ">=14.16" + "node": ">=16" }, "funding": { "url": "https://github.com/sponsors/sindresorhus" diff --git a/package.json b/package.json index 97bda5d..e885c03 100644 --- a/package.json +++ b/package.json @@ -1,18 +1,39 @@ { "name": "query-loop-filter", - "private": true, + "version": "1.0.0", "description": "Filter blocks for query loops", + "author": "Human Made Limited", + "license": "GPL-2.0-or-later", + "keywords": [ + "wordpress", + "wordpress-plugin" + ], + "homepage": "https://github.com/happyprime/query-filter/", + "repository": { + "type": "git", + "url": "git+https://github.com/happyprime/query-filter.git" + }, + "bugs": { + "url": "https://github.com/happyprime/query-filter/issues" + }, + "dependencies": { + "@wordpress/scripts": "^28.6.0" + }, + "devDependencies": { + "@wordpress/npm-package-json-lint-config": "^5.10.0", + "npm-package-json-lint": "^8.0.0" + }, "scripts": { "build": "wp-scripts build --experimental-modules", "start": "wp-scripts start --experimental-modules", "format": "wp-scripts format", "lint:css": "wp-scripts lint-style --fix", "lint:js": "wp-scripts lint-js", - "test": "echo \"Error: no test specified\" && exit 1" + "test": "echo \"Error: no test specified\" && exit 1", + "lint:package": "node ./node_modules/npm-package-json-lint/dist/cli.js ./package.json" }, - "author": "Human Made Limited", - "license": "GPL-2.0-or-later", - "dependencies": { - "@wordpress/scripts": "^28.6.0" + "private": true, + "npmpackagejsonlint": { + "extends": "@wordpress/npm-package-json-lint-config" } } From a7d43ef58cb58019601e94525d40d9cd335f7d05 Mon Sep 17 00:00:00 2001 From: jeremyfelt Date: Sat, 1 Aug 2026 14:09:23 -0700 Subject: [PATCH 3/3] Apply ESLint auto-fixes Formatting only, applied with the project's own fix script. Co-Authored-By: Claude Opus 5 (1M context) --- src/taxonomy/view.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/taxonomy/view.js b/src/taxonomy/view.js index 2438d11..fbb435b 100644 --- a/src/taxonomy/view.js +++ b/src/taxonomy/view.js @@ -36,7 +36,9 @@ const { state } = store( 'query-filter', { } // Don't navigate if the search didn't really change. - if ( value === state.searchValue ) return; + if ( value === state.searchValue ) { + return; + } state.searchValue = value;