Payload CMS Release: 3.19.0

Tag Name: v3.19.0

Release Date: 1/23/2025

Payload CMS LogoPayload CMS

Payload CMS is a modern, self-hosted headless content management system built with TypeScript, Node.js, and MongoDB. It's designed specifically for developers who want full control over their content management system while maintaining a powerful admin interface for content editors.

TL;DR

Payload CMS v3.19.0 introduces significant UI enhancements and bug fixes. Key features include bulk editing for uploads and improved selection capabilities for rich text blocks. The release also addresses numerous issues with MongoDB queries, multi-tenant plugin functionality, and REST API behavior. Documentation has been reorganized for better discoverability, and several template improvements have been made.

Highlight of the Release

    • Bulk editing capabilities for uploads allow editing multiple files simultaneously
    • Rich text blocks and decorator nodes are now selectable with centralized selection and deletion logic
    • Fixed issues with MongoDB queries for polymorphic relationships and localized arrays
    • Improved multi-tenant plugin with better error handling and navigation
    • Reorganized documentation for better discoverability of field, collection, and global configurations

Migration Guide

Deprecations to Note

  1. The description property on tabs configuration is now deprecated in favor of admin.description, though both are still supported for backward compatibility.

  2. The public export of headersWithCors has been deprecated as CORS response headers are now applied automatically without requiring explicit use of this function.

For Multi-tenant Plugin Users

If you're using the multi-tenant plugin, this release includes several important fixes. When upgrading, be aware that tenant selection behavior has been improved when navigating between documents. The page will now refresh the cookie when navigating out of a document to ensure the tenant is set correctly.

Upgrade Recommendations

This release contains significant improvements to the UI, rich text editor, and fixes for several critical bugs. It's recommended for all users to upgrade to v3.19.0, especially if you:

  1. Work with uploads and would benefit from bulk editing capabilities
  2. Use the rich text editor extensively
  3. Have experienced issues with MongoDB queries, particularly with polymorphic relationships or localized arrays
  4. Use the multi-tenant plugin
  5. Have custom upload components in Next.js admin panels

The upgrade should be straightforward with no breaking changes reported. As always, test thoroughly in a development environment before deploying to production.

Bug Fixes

MongoDB and Query Fixes

  • Fixed handling of nullable minDistance and maxDistance parameters in near queries
  • Resolved issues with joining relationship fields inside localized arrays
  • Fixed REST API behavior when using ?locale=* to properly return full localized data
  • Corrected querying of polymorphic relationships with the all operator
  • Fixed v2-v3 migration versioning for collections and globals without relationship fields

UI and Component Fixes

  • Fixed incorrect table action menu placement in the rich text editor
  • Resolved issues with the thumbnail component crashing when images don't exist
  • Fixed admin descriptions not being respected on tabs and padding issues with tab descriptions
  • Improved URL regex matchers for more reliable autolinking in the rich text editor
  • Fixed browser validation errors when visiting the account page

Plugin Fixes

  • Multi-tenant Plugin: Fixed issues with tenant selection when navigating out of documents, corrected user type handling, and prevented errors when no user exists
  • Nested Docs Plugin: Fixed limitation that prevented updating more than 10 child documents
  • Next.js: Fixed admin panel UI not rendering custom upload components and ensured Next.js rewrites are respected for REST API

New Features

Bulk Editing for Uploads

Content editors can now select and edit multiple uploads simultaneously with the new "Edit Many" option. This feature allows selecting specific fields to update across all selected uploads in a single operation, significantly improving workflow efficiency when managing multiple files.

Rich Text Selection Improvements

The Lexical rich text editor now supports selecting blocks (previously only inline blocks were selectable) and any decorator nodes. The selection and deletion logic has been centralized, making the code more maintainable and performant by using event delegation instead of individual listeners for each decorator node. This implementation includes intelligent heuristics to exclude scenarios where node selection would be undesirable.

Security Updates

No significant security fixes were included in this release.

Performance Improvements

Rich Text Editor Performance

The rich text editor now uses event delegation for handling selection and deletion of decorator nodes, resulting in more performant code. Instead of attaching individual listeners to each decorator node, there is now a single listener that handles all nodes, reducing the overhead of event handling.

MongoDB Query Optimizations

Several fixes to MongoDB queries improve the performance and reliability of database operations, particularly for complex queries involving polymorphic relationships and localized arrays.

Impact Summary

Payload CMS v3.19.0 delivers substantial improvements to content editing workflows with the introduction of bulk editing for uploads and enhanced rich text selection capabilities. These features significantly streamline content management tasks, especially when working with multiple files or complex rich text content.

The release also addresses numerous bugs across the platform, particularly in MongoDB query handling, multi-tenant plugin functionality, and Next.js integration. These fixes improve the overall stability and reliability of the CMS.

Documentation has been reorganized to improve discoverability, with field customization, collection, and global configuration docs moved to more intuitive locations. New examples for typed custom field components have been added to help developers implement custom UI elements more easily.

Overall, this release enhances both the developer and content editor experience with thoughtful improvements to workflows, better documentation, and increased system stability.

Full Release Notes

v3.19.0 (2025-01-23)

🚀 Features

  • richtext-lexical: make decoratorNodes and blocks selectable. Centralize selection and deletion logic (#10735) (4aaef5e)
  • ui: adds edit many option for bulk uploads (#10646) (be2c482)

🐛 Bug Fixes

  • next.js rewrites were not respected for rest api (#10759) (c0ae994)
  • browser validation error when visiting account page (#10717) (c1b912d)
  • custom blocks field label component missing from config (#10692) (a5695ba)
  • apply CORS response headers without headersWithCors (#10597) (be98eda)
  • rest api with ?locale=* doesn't return full localized data (#10619) (7f8f2f0)
  • join field with the target relationship inside localized array (#10621) (25a70ab)
  • properly handle nullable minDistance and maxDistance in near query (#10622) (46c1b37)
  • db-mongodb: v2-v3 migration versions docs of collections and globals without relationship fields (#10755) (2d8ff72)
  • db-mongodb: querying polymorphic relationships with the all operator (#10704) (d601300)
  • db-mongodb: beginTransaction invalid type without replicaset (#10690) (90f88f8)
  • next: admin panel UI not rendering custom upload components (#9925) (e4fa171)
  • plugin-multi-tenant: selected tenant could become incorrect when navigating out of doc (#10723) (e6d0260)
  • plugin-multi-tenant: corrects user type in userHasAccessToAllTenants fn (#10707) (2a98c84)
  • plugin-multi-tenant: prevent throwing when no user exists (#10699) (a9c0832)
  • plugin-nested-docs: cannot update more than 10 child docs (#10737) (3501d47)
  • richtext-lexical: improved regex matchers for absolute and relative URLs to make autolinking more reliable (#10725) (9bb27af)
  • richtext-lexical: incorrect table action menu placement (#10627) (9684d31)
  • ui: filters out upload specific fields for bulk editing (#10726) (f181f97)
  • ui: admin description not being respected on tabs and padding issues with tab descriptions (#10710) (67f7c95)
  • ui: issue with thumbnail component crashing the UI if the image didnt exist (#10689) (ddeb29f)

📚 Documentation

  • moves collection and globals admin docs to their respective config overviews (#10743) (e5b3da9)
  • moves customizing fields doc to fields overview (#10742) (0ca3736)
  • adds examples of typed custom field components (#10741) (8b3e2ff)
  • adds info on useSelection and useStepNav hooks (#10683) (d8682f2)
  • multi-tenant plugin - remove @beta and fix npm url (#10697) (6d43910)

📝 Templates

  • update website readmes for additional information on jobs and revalidation (#10758) (61a2a9c)
  • fix potential error in the initial form state caused by type mismatch (#10713) (5e4a1d4)

⚙️ CI

🏡 Chores

🤝 Contributors

Statistics:

File Changed300
Line Additions4,741
Line Deletions2,558
Line Changes7,299
Total Commits37

User Affected:

  • Can now bulk edit multiple uploads simultaneously, improving workflow efficiency
  • Benefit from improved rich text editing with better block selection capabilities
  • Will experience more reliable UI with fixes for thumbnail component crashes
  • Will see better tab descriptions and admin descriptions in the UI

Contributors:

denolferilromr1tsuupaulpopusDanRibbensjacobsfletchJarrodMFleschdsm23bratvanovakhrarovsaidAlessioGrPatrikKozakGermanJablo