Canvas Override
Part of the Canvas ecosystem · 41 projects
This module allows site builders to enable Content Canvas editing for specific content types on their full content view. This provides per-node control over the layout editing using the Drupal Canvas module.
Canvas Override lets site builders turn on per-content layout editing, built on Drupal Canvas, for the content types they choose.
Canvas gives a content type one shared Content Template. Canvas Override adds the other half: any individual content item can depart from that template and keep its own layout, edited in the same Canvas editor. Content that has not been customised keeps following the shared template, so a change to the template still reaches everything that has not been overridden.
What you get
- A Canvas tab on content of the types you enable, opening the full Canvas editor for that one item.
- A per-item layout stored in its own
field_canvas_layoutfield, versioned with the node like any other field. - Reset Canvas layout, which drops the custom layout, restores the shared template, records a revision, and clears any pending Canvas auto-save.
- Per-content-type and per-bundle permissions: use Canvas Override, reset a layout, and edit the shared default template are separate grants.
- Components seeded from the Content Template keep their field bindings, so a heading bound to the title stays bound after you restyle it.
Requirements
- Drupal ~11.3
- Drupal Canvas ^1
Installation
composer require drupal/canvas_override drush en canvas_override
Then edit a content type, open the Canvas layout vertical tab, and enable it.
No Canvas patch needed
As of 1.0.1 this module runs on a stock Canvas release. Earlier versions needed the #3567225: Allow per-node override of Content Template via checkbox in node selector patch, because Canvas ships Drupal\canvas\Storage\ComponentTreeLoader as a final class and several Canvas services type-hint that concrete class.
When that patch is not applied, Canvas Override loads its own copy of that class under Canvas's class name through a prepended autoloader. This happens only while the installed Canvas actually declares the class final; on a patched Canvas, or any future Canvas release that drops final, the module stands aside and Canvas's real class is used.
Worth knowing:
- Install with Composer. The autoloader is registered through the package's
autoload.filesentry, so copying the module intoweb/modules/contrib/by hand skips it and per-content editing stays off. - Under
opcache.preloadCanvas's class is already in memory before Composer's autoloader runs, so the replacement stands aside and per-content editing stays off. It does not fail hard. - The copy is re-synced with Canvas's own file on each Canvas release.
- The durable fix is still upstream: land #3567225: Allow per-node override of Content Template via checkbox in node selector, ideally alongside a
ComponentTreeLoaderInterface.
Known limitation
The link-to-field control renders on a per-content layout and lists the item's real fields, but applying a link is blocked inside Canvas's compiled front end, which resolves that action through its content-template endpoint. That is upstream in Canvas and cannot be fixed from this module.
Depends on
Dependencies of the latest stable release
- Drupal Canvas
- field Drupal core
- node Drupal core
Required by
Tracked projects that depend on this one
No tracked projects depend on this one yet.
More in the Canvas ecosystem
Most installed first
Activity
Release Timeline
Releases
| Version | Type | Core | Release date | |
|---|---|---|---|---|
| 1.0.2 | Stable | 11 | Sep 25, 2026 | |
| 1.0.1 | Stable | 11 | Sep 12, 2026 | |
| 1.0.0 | Stable | 11 | Sep 8, 2026 | |
| 1.0.0-rc1 | Pre-release | 11 | Sep 7, 2026 | |
| 1.0.0-beta3 | Pre-release | 11 | Aug 13, 2026 | |
| 1.0.0-beta2 | Pre-release | 11 | Aug 9, 2026 | |
| 1.0.0-beta1 | Pre-release | 11 | Jul 9, 2026 | |
| 1.0.0-alpha2 | Pre-release | 11 | Apr 6, 2026 | |
| 1.0.0-alpha1 | Pre-release | 11 | Apr 5, 2026 | |
| 1.0.x-dev | Dev | 11 | Mar 29, 2026 |