Home

>

Tools

>

Payload CMS

>

Releases

>

Release 2.0.8

Payload CMS Release: Release 2.0.8

Tag Name: v2.0.8

Release Date: 10/17/2023

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 v2.0.8 brings important improvements to the Live Preview feature, fixes for rich text editors, and resolves several bugs in the admin UI and database operations. This release enhances performance and stability across the platform with particular focus on PostgreSQL compatibility and rich text editing experience.

Highlight of the Release

    • Live Preview performance improvements with field schema caching
    • Enhanced PostgreSQL compatibility for blocks within groups
    • Fixed rich text editor issues including link drawer forms and z-index problems
    • Improved mobile document controls for better editing on smaller screens
    • Added ability to return null from filterOptions functions

Migration Guide

No breaking changes were introduced in this release, so no migration is required.

If you're using PostgreSQL with blocks within groups, this release fixes compatibility issues, so upgrading is recommended.

For users of the rich text editors (both Lexical and Slate), this release fixes several issues with link drawers and field handling, providing a more stable editing experience.

Upgrade Recommendations

This release is recommended for all users, especially those who:

  • Use PostgreSQL as their database
  • Rely on the Live Preview feature
  • Use rich text editors extensively
  • Work with blocks within groups
  • Have content editors working on mobile devices

The upgrade process should be straightforward as there are no breaking changes. Simply update your Payload CMS version to 2.0.8 using your package manager:

npm install [email protected]
# or
yarn upgrade [email protected]
# or
pnpm update [email protected]

If you're using related packages like richtext-lexical or db-postgres, make sure to update those as well to their latest compatible versions.

Bug Fixes

Admin UI Fixes

  • Fixed autosave time display to properly show minutes instead of only seconds
  • Corrected add block index functionality to properly place new blocks
  • Fixed mobile document controls rendering for better small screen experience
  • Refined main navigation for improved usability

Rich Text Editor Fixes

  • Fixed issues with extra fields not being iterated correctly in both Lexical and Slate editors
  • Resolved link drawer form receiving incorrect field schema
  • Fixed z-index issues with isolated editor container in Lexical editor
  • Prevented unnecessary re-renders in Lexical Blocks Field sub-forms

Database and Data Handling

  • Fixed blocks within groups in PostgreSQL database adapter
  • Added proper transaction IDs to local operations
  • Fixed issues with upload crop and focal point functionality
  • Resolved bug with seeding in e-commerce template

Template Improvements

  • Fixed user access control in templates
  • Improved template compatibility with both PostgreSQL and MongoDB

New Features

Live Preview Enhancements

  • Added field schema caching to improve Live Preview performance
  • Optimized Live Preview rendering and reduced unnecessary re-renders
  • Enhanced shadow and background styling for better visual experience

Developer API Improvements

  • filterOptions functions can now return null, providing more flexibility in controlling field options

Security Updates

No specific security fixes were mentioned in this release.

Performance Improvements

Live Preview Performance

  • Added field schema caching to significantly improve Live Preview performance
  • Optimized Live Preview to reduce unnecessary re-renders
  • Enabled forceRender for richtext-lexical's Blocks feature form and sub-forms to prevent unnecessary re-renders
  • Ensured IntersectionObserver does not cause re-renders when forceRender is enabled

Build and Development

  • Added retries to end-to-end tests for more stable CI/CD pipelines
  • Improved template compatibility with both PostgreSQL and MongoDB databases

Impact Summary

Payload CMS 2.0.8 delivers important quality-of-life improvements for both developers and content editors. The release focuses on enhancing stability and performance, particularly for the Live Preview feature and rich text editors.

For developers, the PostgreSQL compatibility improvements and the ability to return null from filterOptions functions provide more flexibility and reliability. Content editors will benefit from fixed mobile controls, improved autosave time display, and better rich text editing experience.

The performance optimizations for Live Preview are particularly notable, with field schema caching reducing unnecessary re-renders and improving the overall editing experience. These changes make Payload CMS more efficient and responsive, especially when working with complex content structures.

Overall, this release represents a solid maintenance update that addresses several pain points reported by the community while adding subtle but useful new capabilities.

Full Release Notes

2.0.8 (2023-10-17)

Features

  • allows filterOptions to return null (c4cac99)
  • live-preview: caches field schema (#3711) (dd0ac06)

Bug Fixes

  • autosave time shown minutes only (#3492) (e311e8f)
  • blocks within groups in postgres (45a62ba)
  • bug with seeding ecommerce (993568a)
  • corrects add block index (#3681) (3c50443)
  • misc upload crop/focal point updates (#3580) (d616772)
  • renders mobile document controls (#3695) (1625ff2)
  • some local operations missing req.transactionID (#3651) (150799e)
  • richtext-*: extra fields not being iterated correctly (#3693) (b8a5866)
  • richtext-*: link drawer form receiving incorrect field schema (#3696) (cb39354)
  • richtext-lexical: #3682 isolated editor container causing z-index issues (24918fe)
  • templates: user access control (#3712) (8b8ceab)

Statistics:

File Changed300
Line Additions12,376
Line Deletions14,222
Line Changes26,598
Total Commits250

User Affected:

  • Benefit from improved PostgreSQL compatibility with blocks within groups
  • Can now return `null` from `filterOptions` functions for more control
  • Transaction IDs are now properly included in local operations
  • Better compatibility with templates across database types

Contributors:

denolfejacobsfletchjmikrutAlessioGrTerraxel99JarrodMFleschmrobsttylandavisjessrynkarArctomachineDanRibbensleonardstrucknathanclevengerNikolaGanchevPatrikKozakdependabot[bot]craigrdanielsdiesieben07