PHPackages                             humanmade/hm-gutenberg-tools - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. humanmade/hm-gutenberg-tools

ActiveWordpress-plugin[Utility &amp; Helpers](/categories/utility)

humanmade/hm-gutenberg-tools
============================

Human Made Gutenberg Tools

v1.7.4(2mo ago)188103.6k↓49.9%20[7 issues](https://github.com/humanmade/hm-gutenberg-tools/issues)[4 PRs](https://github.com/humanmade/hm-gutenberg-tools/pulls)GPL-2.0-or-laterJavaScript

Since Feb 22Pushed 2mo ago23 watchersCompare

[ Source](https://github.com/humanmade/hm-gutenberg-tools)[ Packagist](https://packagist.org/packages/humanmade/hm-gutenberg-tools)[ RSS](/packages/humanmade-hm-gutenberg-tools/feed)WikiDiscussions main Synced 2d ago

READMEChangelog (7)Dependencies (2)Versions (36)Used By (0)

Human Made Gutenberg Tools
==========================

[](#human-made-gutenberg-tools)

Warning

This project is no longer actively developed. It is recommended that you the components from our [Block Editor Components library instead](https://github.com/humanmade/block-editor-components).

A place to bundle useful reusable Gutenberg components and other tools.

What does this include?
-----------------------

[](#what-does-this-include)

- [Post Select button.](https://github.com/humanmade/hm-gutenberg-tools/wiki/Post-Select-Button) Provides a media modal like user experience for selecting single or multiple posts. It supports searching, filtering, sorting and custom post types (and taxonomies). stying to work better in the sidebar.
- More Sidebar controls. Other components wrapped up in as standardised sidebar control components.
    - [Link control.](https://github.com/humanmade/hm-gutenberg-tools/wiki/Link-Control) A wrapper for the core UrlInput, but with some style improvements.
    - [Image.](https://github.com/humanmade/hm-gutenberg-tools/wiki/Image-Control) Sidebar UI for selecting an image.
    - [Post.](https://github.com/humanmade/hm-gutenberg-tools/wiki/Post-Select-Button) A wrapper for the post select button component.

[![image](https://user-images.githubusercontent.com/494927/35505702-d334667e-04de-11e8-8afc-4e21b1f83138.png)](https://user-images.githubusercontent.com/494927/35505702-d334667e-04de-11e8-8afc-4e21b1f83138.png)

Installation Instructions
-------------------------

[](#installation-instructions)

It is reccomended to install as a plugin or mu-plugin using composer.

```
composer require humanmade/hm-gutenberg-tools

```

If you install using another method (e.g. git submodule), note that the `main` branch does not include built assets, but tagged releases and the `build` branch do include them. You should not need to build the assets for this plugin as part of your project build process.

### Bundling in a theme

[](#bundling-in-a-theme)

You can bundle the plugin in a theme (or anywhere outside of plugins/mu-plugins directories). In order to do this you need to define `HM_GB_TOOLS_DIR` and `HM_GB_TOOLS_URL`. For example

```
define( 'HM_GB_TOOLS_DIR', get_stylesheet_directory() . '/lib/hm-gutenberg-tools' );
define( 'HM_GB_TOOLS_URL', get_stylesheet_directory_uri() . '/lib/hm-gutenberg-tools' );

```

Using components from HM Gutenberg Tools
----------------------------------------

[](#using-components-from-hm-gutenberg-tools)

You should specify the script `hm-gb-tools-editor` as a dependency of the script in which you are using it.

```
wp_enqueue_script( 'my-custom-block', plugins_url( 'my-custom-block.js', dirname(__FILE__) ), [ 'hm-gb-tools-editor' ], '1.0' );
```

HM Gutenberg Tools then exposes all functionality globally as `window.hm`. You can then use reference this in your project in much the the same way that you would use any other components from Gutenberg.

```
const { PostSelectButton } = window.hm.components;

function Edit( { attributes, setAttributes } ) {
    return (
         setAttributes( { postIds: posts.map( p => p.id ) } ) }
            postType="page"
            btnProps={ { isLarge: true } }
        >
    );
}
```

[**Refer to the Wiki for usage instructions on individual components**](https://github.com/humanmade/hm-gutenberg-tools/wiki)

Development
-----------

[](#development)

- `npm run build` Builds a production version of the code.
- `npm run watch` Watches for changes and builds development versions of the code.
- `npm run lint` Lints your JS. Run `npm run lint -- --fix` to fix it too.
- `composer run lint` Lints your PHP code.

To assist with local development, you can define `define( 'HM_GB_TOOLS_DEV', true );` to enable the "HM Gutenberg Tools Dev" block, which includes examples of many of features offered by this plugin.

Releasing a new version.
------------------------

[](#releasing-a-new-version)

1. Update the version numbers in `plugin.php` and `package.json`.
2. Add the changelog to the readme for the new version.
3. Commit your changes to `main` and push.
4. Run the bash script: `./release.sh v1.2.3`

The script will sync the the build branch with main, build assets and commit the changes, and publish a new tagged version.

Changelog
---------

[](#changelog)

### v1.7.4

[](#v174)

- Fix post-select endpoint response, where the rendered title should be rendered with `get_the_title`

### v1.7.3

[](#v173)

- Restore built asset files not included in v1.7.2 due to release process error.

### v1.7.2

[](#v172)

- Upgraded dependencies for enhanced performance, security and stability.
- Audit fix dependency upgrade, improving code security.
- Enhanced security by introducing sanitization for `post.title.rendered` mitigating XSS attack risks.

### v1.7.1

[](#v171)

- Add filter for minimum search length for term select.
- Add filter for term select query.

### v1.7.0

[](#v170)

- Add post status field select.
- Allow to accept status from the Rest API endpoint.
- Add status field in the post list item.
- Update deprecated mediaUpload function.

### v1.6.3

[](#v163)

- Ignore sticky posts by default.

### v1.6.2

[](#v162)

- Fix date filter label not being cleared when both selected dates are unset.
- Switch from node-sass to sass and npm audit fix

### v1.6.1

[](#v161)

- Reset PostSelect current page when filters are changed

### v1.6.0

[](#v160)

- Adds date range filters for use when searching posts

### v1.5.0

[](#v150)

- Handle current selections across multiple post types
- Correctly handle post type filters in post selection modal
- Preserbe specified Post Type list when clearing Types token list

### v1.4.1

[](#v141)

- Adds a filter to allow the post select query to be modified

### v1.4.0

[](#v140)

- Support thumbnails in post select components

### v1.3.1

[](#v131)

- Switch selection when clicking off single-post selections

### v1.1.0

[](#v110)

- Support for i18n.

### v1.0.0

[](#v100)

- Refactor how it works for compatability with WordPress 5.0
    - Use core data store
    - Use custom endpoint to fetch content to handle multiple post types.

### v0.2.0

[](#v020)

- Deprecate EditableHTML. You can now just use the Gutenberg component `wp.editor.RichText` and set the `format` prop to `string`.
- Updates to work with the latest version of Gutenberg (3.5).

###  Health Score

62

—

FairBetter than 99% of packages

Maintenance83

Actively maintained with recent releases

Popularity49

Moderate usage in the ecosystem

Community30

Small or concentrated contributor base

Maturity75

Established project with proven stability

 Bus Factor1

Top contributor holds 55% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~135 days

Recently: every ~241 days

Total

23

Last Release

82d ago

Major Versions

v0.2.0 → v1.0.02018-12-12

### Community

Maintainers

![](https://www.gravatar.com/avatar/a498e093283b7b42aa63d5f75851cda7ec4c4e2137cb8482e02d3181b48eafa3?d=identicon)[kadamwhite](/maintainers/kadamwhite)

![](https://avatars.githubusercontent.com/u/58855?v=4)[Tom J Nowell](/maintainers/tomjn)[@tomjn](https://github.com/tomjn)

![](https://avatars.githubusercontent.com/u/494927?v=4)[Matthew Haines-Young](/maintainers/mattheu)[@mattheu](https://github.com/mattheu)

---

Top Contributors

[![mattheu](https://avatars.githubusercontent.com/u/494927?v=4)](https://github.com/mattheu "mattheu (149 commits)")[![kadamwhite](https://avatars.githubusercontent.com/u/442115?v=4)](https://github.com/kadamwhite "kadamwhite (22 commits)")[![dependabot[bot]](https://avatars.githubusercontent.com/in/29110?v=4)](https://github.com/dependabot[bot] "dependabot[bot] (21 commits)")[![ivankristianto](https://avatars.githubusercontent.com/u/656006?v=4)](https://github.com/ivankristianto "ivankristianto (15 commits)")[![abhishek-kaushik](https://avatars.githubusercontent.com/u/1883835?v=4)](https://github.com/abhishek-kaushik "abhishek-kaushik (9 commits)")[![tfrommen](https://avatars.githubusercontent.com/u/6049306?v=4)](https://github.com/tfrommen "tfrommen (8 commits)")[![alwaysblank](https://avatars.githubusercontent.com/u/23412884?v=4)](https://github.com/alwaysblank "alwaysblank (8 commits)")[![Rayhatron](https://avatars.githubusercontent.com/u/14850570?v=4)](https://github.com/Rayhatron "Rayhatron (7 commits)")[![MiguelAxcar](https://avatars.githubusercontent.com/u/90911997?v=4)](https://github.com/MiguelAxcar "MiguelAxcar (7 commits)")[![stuartshields](https://avatars.githubusercontent.com/u/15369210?v=4)](https://github.com/stuartshields "stuartshields (6 commits)")[![maugelves](https://avatars.githubusercontent.com/u/2919706?v=4)](https://github.com/maugelves "maugelves (4 commits)")[![sambulance](https://avatars.githubusercontent.com/u/5014023?v=4)](https://github.com/sambulance "sambulance (3 commits)")[![JockeTF](https://avatars.githubusercontent.com/u/532268?v=4)](https://github.com/JockeTF "JockeTF (2 commits)")[![mikelittle](https://avatars.githubusercontent.com/u/358499?v=4)](https://github.com/mikelittle "mikelittle (2 commits)")[![kucrut](https://avatars.githubusercontent.com/u/67838?v=4)](https://github.com/kucrut "kucrut (2 commits)")[![wwald](https://avatars.githubusercontent.com/u/92294047?v=4)](https://github.com/wwald "wwald (1 commits)")[![fk-hm](https://avatars.githubusercontent.com/u/197630894?v=4)](https://github.com/fk-hm "fk-hm (1 commits)")[![chetansatasiya](https://avatars.githubusercontent.com/u/7081284?v=4)](https://github.com/chetansatasiya "chetansatasiya (1 commits)")[![ntwb](https://avatars.githubusercontent.com/u/1016458?v=4)](https://github.com/ntwb "ntwb (1 commits)")[![svandragt](https://avatars.githubusercontent.com/u/594871?v=4)](https://github.com/svandragt "svandragt (1 commits)")

### Embed Badge

![Health badge](/badges/humanmade-hm-gutenberg-tools/health.svg)

```
[![Health](https://phpackages.com/badges/humanmade-hm-gutenberg-tools/health.svg)](https://phpackages.com/packages/humanmade-hm-gutenberg-tools)
```

###  Alternatives

[doublesecretagency/craft-cpbodyclasses

Adds special classes to the Control Panel's &lt;body&gt; tag.

2437.9k](/packages/doublesecretagency-craft-cpbodyclasses)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
