Skip to content

Docs: Align @param tag columns in block editor docblocks - #13311

Open
mukeshpanchal27 wants to merge 1 commit into
WordPress:trunkfrom
mukeshpanchal27:docs/align-param-columns-editor
Open

Docs: Align @param tag columns in block editor docblocks#13311
mukeshpanchal27 wants to merge 1 commit into
WordPress:trunkfrom
mukeshpanchal27:docs/align-param-columns-editor

Conversation

@mukeshpanchal27

@mukeshpanchal27 mukeshpanchal27 commented Aug 29, 2026

Copy link
Copy Markdown
Member

Trac ticket: https://core.trac.wordpress.org/ticket/65818

The PHP inline documentation standards call for @param tags in a docblock to line up in columns — types, variable names, and descriptions each starting at the same offset — with wrapped descriptions indented to the description column:

/**
 * Summary.
 *
 * @since x.x.x
 *
 * @param string $var       Description.
 * @param bool   $other_var Description that wraps
 *                          onto a second line.
 */

This corrects 58 @param lines across 16 files in the block editor, block supports, and theme.json classes.

Example

src/wp-admin/widgets-form-blocks.php — before:

 * @param string $message The message being displayed.
 * @param bool   $installed Whether the Classic Widget plugin is installed.

after:

 * @param string $message   The message being displayed.
 * @param bool   $installed Whether the Classic Widget plugin is installed.
Files changed (16)
  • src/wp-includes/blocks.php
  • src/wp-includes/blocks/accordion.php
  • src/wp-includes/blocks/heading.php
  • src/wp-includes/blocks/list.php
  • src/wp-includes/blocks/navigation-link.php
  • src/wp-includes/blocks/navigation.php
  • src/wp-includes/blocks/page-list.php
  • src/wp-includes/blocks/social-link.php
  • src/wp-includes/blocks/widget-group.php
  • src/wp-includes/block-supports/layout.php
  • src/wp-includes/block-supports/settings.php
  • src/wp-includes/block-template-utils.php
  • src/wp-includes/class-wp-theme-json.php
  • src/wp-includes/class-wp-theme-json-schema.php
  • src/wp-includes/style-engine/class-wp-style-engine-css-rules-store.php
  • src/wp-admin/widgets-form-blocks.php

Part of a series

The original work was a single branch touching 80 files. It is split by component so each can be reviewed and committed independently:

This is a whitespace-only change: git diff -w against trunk is empty, so there is no functional change and no change to any generated documentation output beyond the alignment itself.

Use of AI Tools

AI assistance: Yes
Tool(s): Claude Code
Model(s): Claude Opus 5
Used for: Grouping a single large docblock alignment branch into per-component pull requests, verifying that the split is whitespace-only and that the seven branches together reproduce the original diff line for line, and drafting this description. I reviewed the alignment changes before submitting.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_018AyprpqvcyKGrDdYmcnQnD
@github-actions

github-actions Bot commented Aug 29, 2026

Copy link
Copy Markdown

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.

Core Committers: Use this line as a base for the props when committing in SVN:

Props mukesh27, wildworks.

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

@mukeshpanchal27

Copy link
Copy Markdown
Member Author

GB changes PR WordPress/gutenberg#81903

@t-hamano t-hamano left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the PR. This PR includes files that are automatically updated by syncing with Gutenberg. The files in src/wp-includes/blocks/ should not be updated.

@t-hamano

Copy link
Copy Markdown
Contributor

This needs to be fixed, similar to GutenbergPR.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants