Skip to content

feat(args): add the wrap-cols argument - #366

Merged
markdumay merged 1 commit into
mainfrom
feat/wrap-cols-arg
Aug 23, 2026
Merged

feat(args): add the wrap-cols argument#366
markdumay merged 1 commit into
mainfrom
feat/wrap-cols-arg

Conversation

@markdumay

Copy link
Copy Markdown
Collaborator

Summary

Adds wrap-cols to the global argument definitions.

Why

gethinode/hinode#2138 (released in v3.23.0) added wrap-cols to the table shortcode, folding a record into column groups on small devices rather than moving only its last column. It was declared inline in hinode's data/structures/table.yml, which is enough while there is one consumer.

mod-blocks' list component now forwards it. A bookshop blueprint carries no inline types — every key resolves against this file via the snake_case → kebab-case lookup in ArgsSchema.html — so without a definition here the build fails hard:

ERROR partial [.../list.hugo.html] - Invalid arguments: components/list.md
        schema: missing type for 'list.wrap_cols'

Exactly the shape of #365 for filter-responsive.

Compatibility

The type matches hinode's inline declaration (string, optional), so ArgsSchema.html takes the plain merge path rather than the redeclared-type path. Purely additive: a new optional argument, so no existing component changes behaviour.

Testing

  • pnpm test — golden check passed (14 groups), no snapshot movement.
  • Verified end-to-end by building mod-blocks' example site against this branch (via HUGO_MODULE_REPLACEMENTS) plus hinode v3.23.0: the list component's table emits data-table-wrap-cols=1,2,1. Without this branch the same build fails with the error above.

Blocks

gethinode/mod-blocks — the list forward cannot merge until this ships.

Hinode v3.23.0 added `wrap-cols` to the table shortcode, folding a record into
column groups on small devices instead of moving only its last column. It was
defined inline in hinode's own structure file, which is enough for one consumer.

mod-blocks' list component now forwards the same argument, and a bookshop
blueprint carries no inline types - every key resolves against this file through
the snake_case to kebab-case lookup. Without a definition here, `wrap_cols` fails
validation with "schema: missing type for 'list.wrap_cols'" and the build errors
out, the same way `filter-responsive` did.

The type matches hinode's inline declaration, so the two merge rather than
conflict.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 5 (1M context) <[email protected]>
@markdumay
markdumay merged commit 162b5d5 into main Aug 23, 2026
11 checks passed
@markdumay
markdumay deleted the feat/wrap-cols-arg branch August 23, 2026 16:47
@markdumay

Copy link
Copy Markdown
Collaborator Author

🎉 This PR is included in version 6.11.0 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

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

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant