Skip to content

Conversation

@pokornyd
Copy link
Member

Motivation

Merges of default components with overrides were not done properly in re-exported toHTML function and PortableText component, resulting in not being able to resolve blocks (h1, p...) and everything else besides types and marks. Added missing object spreads and tests to ensure both explicit resolution and fallback are working properly.

Checklist

  • Code follows coding conventions held in this repo
  • Automated tests have been added
  • Tests are passing
  • Docs have been updated (if applicable)
  • Temporary settings (e.g. variables used during development and testing) have been reverted to defaults

How to test

Try to resolve something from block array, such as h1, while leaving h2 resolution unchanged, see that both headings are resolved as expected.

@pokornyd pokornyd requested review from a team and IvanKiral as code owners January 31, 2025 10:17
@codecov
Copy link

codecov bot commented Jan 31, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 88.62%. Comparing base (c62306f) to head (9ded3bc).
Report is 6 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main      #62      +/-   ##
==========================================
- Coverage   88.80%   88.62%   -0.19%     
==========================================
  Files          22       22              
  Lines         420      422       +2     
  Branches       85       85              
==========================================
+ Hits          373      374       +1     
- Misses         47       48       +1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@pokornyd pokornyd merged commit dbd9461 into main Jan 31, 2025
2 of 3 checks passed
@pokornyd pokornyd deleted the fix-default-fallbacks branch January 31, 2025 11:45
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.

3 participants