Skip to content

Release v1.0.0 - #551

Merged
ViewFromTheBox merged 16 commits into
mainfrom
release/1.0
Jun 8, 2026
Merged

ViewFromTheBox merged 16 commits into
mainfrom
release/1.0

Conversation

@ViewFromTheBox

@ViewFromTheBox ViewFromTheBox commented Jun 8, 2026 •

Copy link
Copy Markdown
Member

Release Information

  • Release Version: v1.0.0
  • Release Date: 2026-06-08
  • Release Type: Major
  • Release Branch: release/1.0
  • Target Branch: main

Release Summary

First stable V1 release of artisanpack-ui/visual-editor. Promotes
1.0.0-beta1 to GA and ships four bug fixes that landed against the
release branch since beta1. The post editor, site editor,
artisanpack/* block fork, and first-class artisanpack-ui/cms-framework
pairing (introduced across 1.0.0-alpha.1 and 1.0.0-beta1) are now
considered stable.

Changelog

Added

  • Laravel 13 support. illuminate/support constraint expanded to
    ^11.0|^12.0|^13.0. PHP floor unchanged at ^8.2 (L13 enforces
    8.3+ transitively).

Fixed

Changed (release prep)

  • Normalized stale @since 1.1.0 / @since 2.0.0 PHPDoc/JSDoc tags
    to @since 1.0.0 across the V1 surface that actually shipped in
    1.0.0 (site editor, form block, comments, renderer-blade package).

Issues and Pull Requests

Issues Fixed:

Breaking Changes

  • No breaking changes (since 1.0.0-beta1)
  • Breaking changes documented below

Anyone upgrading directly from 1.0.0-alpha.1 should still consult
docs/migration.md §4 for the
core/* → artisanpack/* block-namespace migration that landed in beta1.

Testing Checklist

  • All automated tests passing — PHP: 880 tests (2,458 assertions),
    JS: 1,849 tests (231 files)
  • Manual testing completed (post editor + site editor smoke
    through dev app)
  • Accessibility tests passing
  • Performance tests passing (if applicable)
  • Security scan completed (see notes below)
  • Tested in staging environment
  • Database migrations tested (no new migrations in this release)

Testing notes:

Security audit results (see "Dependency Notes" below) — no blockers
identified. Most npm advisories are transitive through @wordpress/*
upstreams and resolve when those packages publish patched versions.

Documentation Checklist

  • CHANGELOG updated
  • README accurate (no changes needed — V1 surface unchanged since beta1)
  • API documentation verified (PHPDoc / JSDoc @since tags normalized)
  • Migration guide written (existing docs/migration.md covers
    alpha.1 → 1.0.0)
  • Release notes written (this PR)
  • Wiki updated (if applicable)

Pre-Release Checklist

  • Version number updated in all necessary files (package.json,
    package-lock.json)
  • Git tag prepared: v1.0.0
  • Release branch updated: release/1.0
  • Dependencies audited (composer + npm)
  • Build artifacts generated
  • Deployment plan reviewed
  • Rollback plan prepared
  • Stakeholders notified

Dependency Notes

Composer: composer audit reports 13 advisories across 9 packages.
All are transitive through dev dependencies (notably symfony/yaml and
related Symfony 7.x components pulled in by orchestra/testbench).
None affect the runtime surface of the package. Recommend a follow-up
composer update against Symfony patch releases after this release tag.

npm: npm audit reports 26 advisories (24 moderate, 1 high, 1 critical).
The vast majority are transitive through @wordpress/* packages pinned
at the 1.0.0-alpha.1 @wordpress/* table (see
docs/release-notes-inputs-1.0.0.md); they will clear when those
upstreams publish patched releases. The critical advisory is in a
transitive ws dependency reachable only through dev tooling.

Post-Release Tasks

  • Tag created: v1.0.0
  • Release notes published
  • Documentation deployed
  • Announcement sent
  • Monitoring verified
  • Previous version support documented

Notes

Paired version: artisanpack-ui/cms-framework ^2.0 (see
docs/release-notes-inputs-1.0.0.md for the pinned @wordpress/* table
and the visual-editor ↔ cms-framework version pair).

🤖 Generated with Claude Code


Release Manager: @jacobmartella

Summary by CodeRabbit

  • New Features

    • Added layout baseline CSS for consistent block spacing across flow, constrained, flex, and grid layouts
    • Added LayoutBaseline components to React and Vue renderers
    • Enabled live inline editing for post-title blocks
  • Bug Fixes

    • Fixed block spacing inheritance in layout-flow contexts
    • Prevented duplicate FontSizePicker keys via slug deduplication
    • Resolved TypeScript compilation errors
  • Improvements

    • Added Laravel 13 compatibility (PHP 8.3+)
    • Moved typography presets into a theme-origin structure for editor settings

ViewFromTheBox and others added 15 commits June 8, 2026 11:19
… spacing

The renderers did not implement WordPress's block-gap system for flow
containers, so consecutive paragraph blocks (and any flow-layout
children) rendered flush with zero spacing. Adds the canonical
`:where(.is-layout-flow) > * + * { margin-block-start:
var(--wp--style--block-gap, 24px) }` rule (and the constrained
equivalent) to all three renderers so theme.json `styles.spacing.blockGap`
is honored on the front end.

- Blade: extends the existing `<style data-ve-layout-baseline>` inline
  block in `<x-ve-blocks-styles />`
- React/Vue: new `<LayoutBaseline />` component sharing a single
  `LAYOUT_BASELINE_CSS` source-of-truth string for byte-identical output
- Per-block `--wp--style--block-gap` overrides emitted by
  ThemeJsonTokensCompiler cascade into the new rule via the
  `var(--wp--style--block-gap, …)` reference

Closes #539
…k-gap

fix: emit is-layout-flow block-gap rule for paragraph spacing
Widen the illuminate/support constraint from >=5.3 to
^11.0|^12.0|^13.0 so Laravel 13 (PHP 8.3+) resolves alongside the
existing L11/L12 support. The PHP floor stays at ^8.2 for users on
L11/L12; L13's own php constraint enforces 8.3+ transitively.

Closes #538
- Clarify CHANGELOG wording — the constraint change drops the
  effectively-unsupported L5.3-10 range as well as adding L13.
- Align the visual-editor-renderer-blade subpackage's illuminate/*
  constraints with the root package (^11.0|^12.0|^13.0).
…el-13-support

enhancement: add Laravel 13 support
- Guard `saveEditedEntityRecord` when `getEditedEntityRecord` returns null
  so the payload spread no longer trips strict `EntityRecord` typing.
- Drop the misused `useSelect<ReturnShape>` generic in `useEntityProp` —
  `useSelect`'s type parameter is the MapSelect callback, not the return
  shape — and type the `select` callback so it no longer falls back to
  `any`.
- In the companion test file, widen two `vi.fn` fetcher mocks to match
  `typeof fetch`, and split the tuple destructure from the type cast on
  two `useEntityBlockEditor` renderHook calls (the previous
  `as readonly Array<...>` applied to the tuple, not the blocks array,
  and used an invalid `readonly Array<>` modifier).

Closes #542
…e-data-shim-errors

fix(#542): resolve tsc --noEmit errors in core-data-shim
The post-title block edit was a readonly placeholder, so focusing it and
typing did nothing — the canvas displayed the loaded title (via
`useEntityRecord`) but offered no setter path. Replaces the placeholder
with a hybrid edit:

  1. Stamped `_resolvedTitle` attribute → readonly (unchanged).
  2. `artisanpack/postPreview` query-loop context → readonly preview
     (unchanged).
  3. Live entity in scope (`postType` + `postId`, no `queryId`) →
     editable `PlainText` wired through the core-data shim's
     `useEntityProp('postType', postType, 'title', postId)`. Typing
     stages an `editEntityRecord` edit, the canvas re-renders via
     `useSelect`'s subscription, and `editor-app`'s `stagedEntityEdits`
     watch re-arms the metadata-save debounce on the same cycle as
     sidebar edits.
  4. No entity in scope → placeholder label (unchanged).

Adds a single-mounted-Probe regression test for `useEntityProp` to
confirm the shim's setter does re-render the consumer, and updates the
live-entity test suite with a PlainText mock + a typing test that
asserts both the visible re-render and the staged
`getEntityRecordEdits` payload.

Closes #546

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
Inline comment explaining the editable-vs-placeholder branch on
`titleText !== '' || editedTitle !== undefined`.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
…t-updating-on-type

fix: make artisanpack/post-title editable inline against the live entity
Gutenberg's `TypographyPanel.getMergedFontSizes` concatenates
`[...custom, ...theme, ...default]` from
`__experimentalFeatures.typography.fontSizes`. Our defaults shipped under
`custom:` while `useThemedEditorSettings` adds the host theme under
`theme:` — slug overlaps (e.g. `small`, `large` from cms-framework's
`default-base.php`) stacked into duplicate React keys in
`FontSizePickerSelect`.

Move `DEFAULT_FONT_SIZES` / `DEFAULT_FONT_FAMILIES` to the `theme`
origin (mirroring the palette / spacingSizes pattern) so the themed
hook's `theme:` override replaces them cleanly. Add defensive slug
dedupe (first-wins) to every theme-extract helper as defense in depth
against malformed upstream payloads.

Closes #547
…-duplicate-keys

fix: dedupe font-size presets to silence FontSizePicker key warnings (#547)
Add a `### Fixed` entry under `[Unreleased]` documenting the
paragraph `is-layout-flow` block-gap fix from #540 / commit 9548317
so it isn't missed when 1.0.0 is tagged.

Closes #543
…graph-block-gap-fix

fix: add paragraph block-gap fix to changelog
- Bump package.json version 1.0.0-beta1 -> 1.0.0
- Sync package-lock.json
- Convert CHANGELOG [Unreleased] -> [1.0.0] 2026-06-08, add the
  post-title / FontSizePicker / core-data-shim fixes that landed
  since beta1
- Normalize stale @SInCE 1.1.0 / 2.0.0 tags to @SInCE 1.0.0 across
  the V1 surface that actually shipped in 1.0.0 (site editor, form
  block, comments, renderer-blade)

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
@coderabbitai

coderabbitai Bot commented Jun 8, 2026 •

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: 5167dfec-121a-4dc6-89f0-f068dac852a0

📥 Commits

Reviewing files that changed from the base of the PR and between 3114298 and af506a0.

📒 Files selected for processing (3)
  • CHANGELOG.md
  • packages/visual-editor-renderer-vue/src/LayoutBaseline.ts
  • resources/js/visual-editor/blocks/post-title/edit.tsx
✅ Files skipped from review due to trivial changes (1)
  • packages/visual-editor-renderer-vue/src/LayoutBaseline.ts
🚧 Files skipped from review as they are similar to previous changes (2)
  • CHANGELOG.md
  • resources/js/visual-editor/blocks/post-title/edit.tsx

📝 Walkthrough

Walkthrough

Release 1.0.0: package version and changelog updated, Composer constraints widened for Laravel 13, layout-baseline CSS added to Blade/React/Vue with tests, PostTitle replaced by live-editing component using useEntityProp and corresponding shim/test fixes, theme preset deduplication added, and many @since annotations normalized to 1.0.0.

Changes

Release Versioning and Documentation

Layer / File(s) Summary
Version and release notes
package.json, CHANGELOG.md
Package version bumped to 1.0.0; CHANGELOG now includes [Unreleased] and a 1.0.0 — 2026-06-08 entry documenting Laravel 13 compatibility and listed fixes.
Composer root constraint
composer.json
Root composer constraint for illuminate/support restricted to `^11.0
Blade renderer composer
packages/visual-editor-renderer-blade/composer.json
Blade renderer composer constraints updated to allow `^11.0

Cross-Renderer Layout Baseline CSS

Layer / File(s) Summary
Shared layout baseline CSS
packages/visual-editor-renderer-react/src/support/layoutBaselineCss.ts, packages/visual-editor-renderer-vue/src/support/layoutBaselineCss.ts
Adds LAYOUT_BASELINE_CSS constant containing canonical baseline CSS for flow, constrained, flex, and grid (uses var(--wp--style--block-gap, 24px) fallback).
Blade renderer layout baseline
packages/visual-editor-renderer-blade/resources/views/components/blocks-styles.blade.php, packages/visual-editor-renderer-blade/tests/Feature/BlocksStylesComponentTest.php
Blade emits data-ve-layout-baseline style block with :where(...) margin resets and sibling-spacing rules for .is-layout-flow and .is-layout-constrained; feature test verifies selectors and fallback variable.
React renderer layout baseline
packages/visual-editor-renderer-react/src/LayoutBaseline.tsx, packages/visual-editor-renderer-react/src/index.ts, packages/visual-editor-renderer-react/tests/LayoutBaseline.test.tsx
React LayoutBaseline component renders style[data-ve-layout-baseline] with LAYOUT_BASELINE_CSS; exported and tested.
Vue renderer layout baseline
packages/visual-editor-renderer-vue/src/LayoutBaseline.ts, packages/visual-editor-renderer-vue/src/index.ts, packages/visual-editor-renderer-vue/tests/LayoutBaseline.test.ts
Vue LayoutBaseline component renders the same baseline CSS and is exported; tested for presence and canonical rules.

Post Title Live Inline Editing & Core-Data Shim

Layer / File(s) Summary
PostTitleEdit component implementation
resources/js/visual-editor/blocks/post-title/edit.tsx
Replaces factory-based placeholder with PostTitleEdit: parses block context identity, detects query-loop, computes heading level, and uses useEntityProp for live inline editing with a clear resolution priority.
Core data shim runtime/type adjustments
resources/js/visual-editor/vendor/core-data-shim.ts
saveEditedEntityRecord returns early when edited record is null; useEntityProp selector typing adjusted without runtime behavior changes.
Post title and shim tests / mocks
resources/js/visual-editor/blocks/_shared/__tests__/*, resources/js/visual-editor/vendor/__tests__/core-data-shim.test.tsx
Extend @wordpress/block-editor PlainText mock to a controlled textarea, add tests for display-value updates, setter re-render, numeric-string postId handling, and update fetcher mocks to (input, init?) signatures where required.

Typography Deduplication and Editor Settings

Layer / File(s) Summary
Theme preset slug deduplication
resources/js/visual-editor/use-themed-editor-settings.ts
Extractors now dedupe entries by slug (palette, fontSizes, fontFamilies, spacing, gradients) to avoid duplicate React keys.
Editor settings typography structure
resources/js/visual-editor/editor-settings.ts
__experimentalFeatures.typography now seeds fontSizes and fontFamilies under theme with custom: [], aligning origins and preventing unexpected merges.
Deduplication tests
resources/js/visual-editor/__tests__/use-themed-editor-settings.test.ts
Adds tests verifying slug dedupe behavior and typography origin shape (theme populated, custom empty).

Docblock/JSDoc @since Normalization

Layer / File(s) Summary
Blade renderer and support PHPDoc updates
packages/visual-editor-renderer-blade/src/Services/*.php, packages/visual-editor-renderer-blade/src/Support/*.php, packages/visual-editor-renderer-blade/tests/Unit/*
Multiple @since tags adjusted from 1.1.0 to 1.0.0 across GlobalStylesEmissionResolver, NavigationOverlayTracker, ThemeJsonTokensCompiler, BlockSupports, and ElementsSupport.
Core PHP and site-editor annotations
src/**, src/Http/Controllers/SiteEditor/*, src/SiteEditor/*, src/Resources/*, src/VisualEditorServiceProvider.php
Numerous @since annotations updated to reflect 1.0.0 for controllers, bridges, resolvers, and service provider methods.
JS helper JSDoc
resources/js/visual-editor/site-editor/block-editor-boundary.tsx
@since JSDoc updated on resolveNavigationId.

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~25 minutes

Possibly related PRs

"🐰 A beta hops toward release day,
Layout gaps now fixed to stay,
Titles edit as you type with glee,
Typography tidy as can be,
Laravel Thirteen—hop, hooray!"

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 61.76% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The PR title 'Release v1.0.0' is clear, concise, and directly summarizes the primary change—promoting the package to a stable v1.0.0 release. It accurately reflects the main objective of the changeset.
Linked Issues check ✅ Passed All linked issues' objectives are met: #539 (layout block-gap spacing restored via layout-baseline CSS in Blade/React/Vue renderers and tests added), #546 (post-title live editing fixed via useEntityProp setter dispatch and re-render), #547 (FontSizePicker duplicate-key warnings eliminated via slug deduplication in themed editor settings), #543 (changelog updated with block-gap fix entry), and #538 (Laravel 13 support added via widened illuminate/* constraints).
Out of Scope Changes check ✅ Passed All changes are in-scope: version bumps (package.json, CHANGELOG.md), dependency updates (composer.json), @since tag normalization to 1.0.0, layout-baseline CSS implementation with tests, post-title live-edit fix, font-size deduplication, and core-data-shim adjustments—all directly tied to the five linked issues and release preparation.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch release/1.0

Comment @coderabbitai help to get the list of available commands and usage tips.

@ViewFromTheBox ViewFromTheBox moved this from Backlog to In Review in ArtisanPack UI Overview Jun 8, 2026

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Actionable comments posted: 3

🧹 Nitpick comments (2)
resources/js/visual-editor/blocks/post-title/edit.tsx (1)

136-143: 💤 Low value

Consider extracting the repeated boolean condition.

The expression identity !== null && ! inQueryLoop is evaluated four times. Extract it to a named constant for clarity and maintainability:

+    const canEditLiveEntity = identity !== null && ! inQueryLoop;
     const [ editedTitle, setTitle ] = useEntityProp<
         string | { raw?: string; rendered?: string }
     >(
-        identity !== null && ! inQueryLoop ? 'postType' : undefined,
-        identity !== null && ! inQueryLoop ? identity.postType : undefined,
-        identity !== null && ! inQueryLoop ? 'title' : undefined,
-        identity !== null && ! inQueryLoop ? identity.postId : null,
+        canEditLiveEntity ? 'postType' : undefined,
+        canEditLiveEntity ? identity.postType : undefined,
+        canEditLiveEntity ? 'title' : undefined,
+        canEditLiveEntity ? identity.postId : null,
     );
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@resources/js/visual-editor/blocks/post-title/edit.tsx` around lines 136 -
143, Extract the repeated condition `identity !== null && ! inQueryLoop` into a
well-named boolean constant (e.g., hasIdentityAndNotInQueryLoop) and use that
constant for all four arguments passed to useEntityProp (the call that returns
editedTitle and setTitle), replacing the repeated expression; update the call
sites referencing identity.postType and identity.postId to guard with that
constant to preserve the existing behavior when it's false.
packages/visual-editor-renderer-vue/src/LayoutBaseline.ts (1)

27-35: ⚡ Quick win

Prefer text content over innerHTML prop.

Setting innerHTML as a prop works in Vue 3, but for a <style> tag, passing the CSS as the third argument (children) to h() is more idiomatic and avoids direct DOM property manipulation.

♻️ Proposed refactor to use text content
         return (): VNode =>
             h(
                 'style',
                 {
                     'data-ve-layout-baseline': '',
-                    innerHTML: LAYOUT_BASELINE_CSS,
                 },
-                []
+                LAYOUT_BASELINE_CSS
             );
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@packages/visual-editor-renderer-vue/src/LayoutBaseline.ts` around lines 27 -
35, The current render function in LayoutBaseline (the returned arrow that calls
h('style', { 'data-ve-layout-baseline': '', innerHTML: LAYOUT_BASELINE_CSS },
[])) uses innerHTML; replace this by passing LAYOUT_BASELINE_CSS as the third
argument (children) to h() and remove the innerHTML prop so the <style> content
is provided as text children instead (keep the 'data-ve-layout-baseline'
attribute intact) — update the VNode creation in the LayoutBaseline return to
h('style', { 'data-ve-layout-baseline': '' }, LAYOUT_BASELINE_CSS).
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@CHANGELOG.md`:
- Around line 41-43: The changelog entry currently attributes the core-data shim
TypeScript fix to the wrong PR number (`#543`); update the text in CHANGELOG.md
where the paragraph "- **`tsc --noEmit` errors in the core-data shim.** ..."
references `#543` and replace that reference with the correct issue/PR number
`#542` so the entry correctly maps the core-data shim TS fixes to PR `#542`.

In `@resources/js/visual-editor/blocks/post-title/edit.tsx`:
- Line 176: The PlainText usage in edit.tsx sets the internal prop
__experimentalVersion={2}; remove this prop from the PlainText element (symbol:
PlainText in this file) if the block behaves correctly without it, otherwise add
a clear justification comment above the PlainText explaining why the
experimental flag is required and pin/document the compatible
`@wordpress/block-editor` version in package.json/CHANGELOG so future updates are
explicit; ensure any tests/manual checks verify the block still renders and
edits correctly after removing or documenting the flag.
- Line 172: The PlainText component is being passed an unsupported prop tagName
(via TagName as never); remove the tagName prop from PlainText in the PostTitle
edit component and either: 1) replace PlainText with RichText (e.g., use
RichText for the editable title and pass tagName={TagName}) if you need editable
heading levels, or 2) keep PlainText and render the semantic heading element
using TagName as the wrapper/output (wrap PlainText with the selected TagName or
render the value inside <TagName> for front-end output). Update references to
TagName, PlainText, and RichText in the edit component so no cast (as never) is
required and no unsupported prop is passed.

---

Nitpick comments:
In `@packages/visual-editor-renderer-vue/src/LayoutBaseline.ts`:
- Around line 27-35: The current render function in LayoutBaseline (the returned
arrow that calls h('style', { 'data-ve-layout-baseline': '', innerHTML:
LAYOUT_BASELINE_CSS }, [])) uses innerHTML; replace this by passing
LAYOUT_BASELINE_CSS as the third argument (children) to h() and remove the
innerHTML prop so the <style> content is provided as text children instead (keep
the 'data-ve-layout-baseline' attribute intact) — update the VNode creation in
the LayoutBaseline return to h('style', { 'data-ve-layout-baseline': '' },
LAYOUT_BASELINE_CSS).

In `@resources/js/visual-editor/blocks/post-title/edit.tsx`:
- Around line 136-143: Extract the repeated condition `identity !== null && !
inQueryLoop` into a well-named boolean constant (e.g.,
hasIdentityAndNotInQueryLoop) and use that constant for all four arguments
passed to useEntityProp (the call that returns editedTitle and setTitle),
replacing the repeated expression; update the call sites referencing
identity.postType and identity.postId to guard with that constant to preserve
the existing behavior when it's false.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: f63291fb-d48d-4365-9599-6325209aa6f9

📥 Commits

Reviewing files that changed from the base of the PR and between 4782008 and 3114298.

⛔ Files ignored due to path filters (1)
  • package-lock.json is excluded by !**/package-lock.json, !package-lock.json
📒 Files selected for processing (38)
  • CHANGELOG.md
  • composer.json
  • package.json
  • packages/visual-editor-renderer-blade/composer.json
  • packages/visual-editor-renderer-blade/resources/views/components/blocks-styles.blade.php
  • packages/visual-editor-renderer-blade/src/Services/GlobalStylesEmissionResolver.php
  • packages/visual-editor-renderer-blade/src/Services/NavigationOverlayTracker.php
  • packages/visual-editor-renderer-blade/src/Services/ThemeJsonTokensCompiler.php
  • packages/visual-editor-renderer-blade/src/Support/BlockSupports.php
  • packages/visual-editor-renderer-blade/src/Support/ElementsSupport.php
  • packages/visual-editor-renderer-blade/tests/Feature/BlocksStylesComponentTest.php
  • packages/visual-editor-renderer-blade/tests/Unit/BlockSupportsTest.php
  • packages/visual-editor-renderer-blade/tests/Unit/ElementsSupportTest.php
  • packages/visual-editor-renderer-blade/tests/Unit/ThemeJsonTokensCompilerTest.php
  • packages/visual-editor-renderer-react/src/LayoutBaseline.tsx
  • packages/visual-editor-renderer-react/src/index.ts
  • packages/visual-editor-renderer-react/src/support/layoutBaselineCss.ts
  • packages/visual-editor-renderer-react/tests/LayoutBaseline.test.tsx
  • packages/visual-editor-renderer-vue/src/LayoutBaseline.ts
  • packages/visual-editor-renderer-vue/src/index.ts
  • packages/visual-editor-renderer-vue/src/support/layoutBaselineCss.ts
  • packages/visual-editor-renderer-vue/tests/LayoutBaseline.test.ts
  • resources/js/visual-editor/__tests__/use-themed-editor-settings.test.ts
  • resources/js/visual-editor/blocks/_shared/__tests__/entity-placeholder-live-entity.test.tsx
  • resources/js/visual-editor/blocks/_shared/__tests__/entity-placeholder-query-preview.test.tsx
  • resources/js/visual-editor/blocks/post-title/edit.tsx
  • resources/js/visual-editor/editor-settings.ts
  • resources/js/visual-editor/site-editor/block-editor-boundary.tsx
  • resources/js/visual-editor/use-themed-editor-settings.ts
  • resources/js/visual-editor/vendor/__tests__/core-data-shim.test.tsx
  • resources/js/visual-editor/vendor/core-data-shim.ts
  • src/Blocks/Forms/FormBlock.php
  • src/Http/Controllers/SiteEditor/GlobalStylesController.php
  • src/Http/Controllers/SiteEditor/MenuController.php
  • src/Resources/CommentInliner.php
  • src/SiteEditor/MenuItemBlockBridge.php
  • src/SiteEditor/NavigationBlockRefResolver.php
  • src/VisualEditorServiceProvider.php

Comment thread CHANGELOG.md Outdated
return (
// eslint-disable-next-line @typescript-eslint/no-explicit-any
<PlainText
tagName={ TagName as never }

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟠 Major

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
# Check PlainText's tagName prop type definition
rg -A5 -B2 'tagName.*:.*string' node_modules/@wordpress/block-editor --type=ts

Repository: ArtisanPack-UI/visual-editor

Length of output: 149


🏁 Script executed:

#!/bin/bash
set -euo pipefail

# 1) Inspect the local file around the reported line
FILE="resources/js/visual-editor/blocks/post-title/edit.tsx"
echo "== $FILE =="
nl -ba "$FILE" | sed -n '130,220p'

# 2) Find the exact `as never` usage(s)
rg -n "tagName=\{[^}]*as never\}" resources/js/visual-editor/blocks/post-title/edit.tsx

# 3) Locate where TagName/tagNameForLevel are defined
rg -n "tagNameForLevel|TagName" resources/js/visual-editor/blocks/post-title/edit.tsx

Repository: ArtisanPack-UI/visual-editor

Length of output: 193


🏁 Script executed:

#!/bin/bash
set -euo pipefail

# Identify the wp/block-editor package version used by this repo
if [ -f package.json ]; then
  echo "== package.json =="
  cat package.json
fi

# Search for `@wordpress/block-editor` in lockfiles/manifests
rg -n "`@wordpress/block-editor`" package-lock.json yarn.lock pnpm-lock.yaml 2>/dev/null || true

Repository: ArtisanPack-UI/visual-editor

Length of output: 3890


🌐 Web query:

@wordpress/block-editor PlainText tagName prop type PlainTextProps interface

💡 Result:

The @wordpress/block-editor PlainText component does not accept a tagName prop [1][2][3]. Unlike the RichText component, which uses a tagName prop to define the underlying HTML element (defaulting to div) [4], the PlainText component is specifically designed to render an auto-growing textarea element [1][2]. There is no formal PlainTextProps interface exported by the @wordpress/block-editor package [5]. According to WordPress development best practices, if you need to determine the type for the props of this component, you should use React.ComponentProps [5]. For example, you can extract the type as follows: import { PlainText } from '@wordpress/block-editor'; type PlainTextProps = React.ComponentProps; The PlainText component supports the following primary props [1][2]: - value (string, required): The string value of the textarea [1][2]. - onChange (function, required): A callback function triggered when the text value changes [1][2]. - ref (object, optional): A ref forwarded to the underlying TextareaAutosize component [1][2]. - Additional props: You can pass any standard HTML textarea attributes as additional props, which the component will apply to the rendered textarea [1][3].

Citations:


🌐 Web query:

PlainText tagName type "keyof JSX.IntrinsicElements" "@wordpress/block-editor"

💡 Result:

The PlainText component in the @wordpress/block-editor package is an auto-growing textarea used to capture textual content [1][2][3]. It does not have an official tagName property in its public API; it functions as a wrapper around an auto-resizing textarea component [1][2]. Regarding the technical context of your query: 1. JSX.IntrinsicElements: The use of keyof JSX.IntrinsicElements (or more recently, keyof React.JSX.IntrinsicElements) is a common pattern in the WordPress/Gutenberg codebase for defining polymorphic component props (often via an as property) [4]. This allows components to accept any valid HTML tag name as a prop, ensuring type safety when rendering dynamic elements [4]. 2. @wordpress/block-editor: Recent updates to the Gutenberg codebase have migrated JSX type references from the global JSX namespace to React.JSX to maintain compatibility with React 19 standards [4][5]. If you are encountering a type error or requirement involving these terms, it is likely related to defining a custom wrapper or extending existing WordPress components to support polymorphic behavior (using the as pattern) [4]. The PlainText component itself is designed for standard textarea usage and does not expose a tagName prop for external configuration [1][2].

Citations:


🏁 Script executed:

#!/bin/bash
set -euo pipefail
FILE="resources/js/visual-editor/blocks/post-title/edit.tsx"
echo "== file exists? =="
test -f "$FILE" && echo "yes" || (echo "no"; exit 1)

echo "== $FILE (around 160-190) =="
# cat -n is usually available; avoids nl dependency
cat -n "$FILE" | sed -n '150,200p'

echo "== search: tagNameForLevel / TagName definitions =="
rg -n "tagNameForLevel|type\s+TagName|const\s+TagName|enum\s+TagName|TagName" "$FILE"

echo "== search: PlainText usage around tagName =="
rg -n "PlainText|tagName=\{.*\}" "$FILE"

echo "== search: any other tagName props on PlainText in repo =="
rg -n "PlainText[\s\S]{0,200}tagName=" resources/js/visual-editor -S || true

Repository: ArtisanPack-UI/visual-editor

Length of output: 2759


🏁 Script executed:

#!/bin/bash
set -euo pipefail
FILE="resources/js/visual-editor/blocks/post-title/edit.tsx"

echo "== $FILE (around tagNameForLevel + TagName) =="
cat -n "$FILE" | sed -n '80,160p'

echo "== $FILE (imports for PlainText) =="
rg -n "import\s+\{[^}]*PlainText" "$FILE"

Repository: ArtisanPack-UI/visual-editor

Length of output: 3641


🌐 Web query:

@wordpress/block-editor@15.16.0 PlainText tagName prop types

💡 Result:

The PlainText component in @wordpress/block-editor does not support or use a tagName prop [1][2][3][4]. The PlainText component is designed specifically to render an auto-growing textarea [1][2][4]. Because it is hardcoded to use a textarea element, it does not provide a mechanism to change the underlying HTML tag, unlike the RichText component, which does support a tagName prop [5][6]. If you require a component that allows specifying the HTML tag (such as h1, p, or div), you should use the RichText component instead [5][6]. For the PlainText component, the supported props are [1][2][3][4]: - value: string (Required) - onChange: Function (Required) - ref: Object (Optional) - Any other standard textarea attributes (e.g., placeholder, className) are generally passed through to the underlying textarea element [1].

Citations:


🌐 Web query:

gutenberg PlainText component props tagName

💡 Result:

The WordPress Gutenberg PlainText component does not support a tagName prop [1][2]. The PlainText component is designed specifically to render an auto-growing textarea [1][2], which is a form control element that does not accept a tag name to change its underlying HTML element (unlike the RichText component, which uses a tagName prop to specify the tag, such as 'p' or 'h2', that the editable content should be wrapped in) [3][4]. If you require editable content that supports custom HTML tags, you should use the RichText component instead [3][4]. PlainText is intended for raw text input where a textarea is the appropriate UI element [5][6].

Citations:


🌐 Web query:

site:github.com WordPress gutenberg packages/block-editor src/components/plain-text tagName

💡 Result:

The PlainText component in the WordPress @wordpress/block-editor package does not support a tagName property [1][2][3]. The PlainText component is specifically designed to render an auto-growing textarea [1][3]. Because it is fundamentally based on a textarea element, it does not provide the ability to change the underlying HTML tag, unlike the RichText component, which does support a tagName property to define the editable element (defaulting to a div) [4][5]. If your requirements necessitate the use of a specific HTML tag (e.g., h1, p, span) for editable content, you should use the RichText component instead [4][6]. If you require simple, non-formatted text input while needing semantic tag control, you may need to configure RichText to disable formatting tools or implement a custom component that meets your specific needs.

Citations:


Remove invalid tagName usage on PlainText (drop as never)

resources/js/visual-editor/blocks/post-title/edit.tsx passes tagName={ TagName as never } to PlainText, but PlainText is a textarea-based component and doesn’t support a tagName prop—so this cast hides a real API mismatch. Use RichText for heading/tag selection (or apply semantic heading output outside PlainText) and stop passing tagName to PlainText.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@resources/js/visual-editor/blocks/post-title/edit.tsx` at line 172, The
PlainText component is being passed an unsupported prop tagName (via TagName as
never); remove the tagName prop from PlainText in the PostTitle edit component
and either: 1) replace PlainText with RichText (e.g., use RichText for the
editable title and pass tagName={TagName}) if you need editable heading levels,
or 2) keep PlainText and render the semantic heading element using TagName as
the wrapper/output (wrap PlainText with the selected TagName or render the value
inside <TagName> for front-end output). Update references to TagName, PlainText,
and RichText in the edit component so no cast (as never) is required and no
unsupported prop is passed.

Comment thread resources/js/visual-editor/blocks/post-title/edit.tsx
- CHANGELOG: correct core-data-shim fix reference #543 -> #542
- post-title/edit.tsx: extract repeated `identity !== null && ! inQueryLoop`
  into `hasLiveEntity` so the four useEntityProp args + the live-entity
  branch all read off one boolean
- post-title/edit.tsx: document why PlainText carries `tagName` +
  `__experimentalVersion={2}` (runtime-supported by
  @wordpress/block-editor >= 14; types lag; RichText would allow
  inline formatting we deliberately want to suppress on titles)
- visual-editor-renderer-vue/LayoutBaseline: pass CSS as h() children
  instead of `innerHTML` prop

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
@ViewFromTheBox
ViewFromTheBox merged commit c9b1fda into main Jun 8, 2026
11 checks passed
@ViewFromTheBox
ViewFromTheBox deleted the release/1.0 branch June 8, 2026 23:05
@github-project-automation github-project-automation Bot moved this from In Review to Done in ArtisanPack UI Overview Jun 8, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment