refactor: enhance block name resolution and schema mapping for WordPr…#1033
Merged
umeshmore45 merged 4 commits intodevfrom Apr 8, 2026
Merged
refactor: enhance block name resolution and schema mapping for WordPr…#1033umeshmore45 merged 4 commits intodevfrom
umeshmore45 merged 4 commits intodevfrom
Conversation
…to feature/cmg-705
vikrantraut-cstk
previously approved these changes
Apr 8, 2026
umeshmore45
requested changes
Apr 8, 2026
Contributor
There was a problem hiding this comment.
Pull request overview
This PR refactors WordPress block name resolution to better handle core/missing blocks (using originalName) and extends schema/value mapping to support additional block types (notably Jetpack Markdown) during WordPress migration ingestion.
Changes:
- Updated block-name resolution to prefer
metadata.name, thenoriginalNameforcore/missing, and normalize media blocks tomedia. - Added dedicated schema mapping for
core/missing(including amarkdownfield type forjetpack/markdown) and adjusted schema assembly for certain blocks (e.g.,core/search). - Updated WordPress service-side schema matching to consider both
otherCmsFieldandotherCmsType, and added formatting support formarkdown.
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 5 comments.
| File | Description |
|---|---|
| upload-api/migration-wordpress/libs/schemaMapper.ts | Refines block-name resolution and introduces/adjusts schema mapping for core/missing and core/search. |
| upload-api/migration-wordpress/libs/extractItems.ts | Improves core/missing resolution and structure comparison by incorporating originalName. |
| api/src/services/wordpress.service.ts | Adds shared block-name resolver, broadens matching rules, removes reliance on metadata.name alone, and adds markdown formatting support. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
umeshmore45
approved these changes
Apr 8, 2026
vikrantraut-cstk
approved these changes
Apr 8, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
…ess integration