Problem/Motivation
Two related defects shipped in the initial recipe (#3622802), both of which invert the dependency between a generic Varbase base recipe and a site template.
1. The Canvas content templates bind this recipe to a site template's theme
All three canvas.content_template.node.podcast.* configs were bound to Vartheme BS5 RightUp, which is the theme of the RightUp site template. The full template alone carries 24 references to it. A generic Varbase base recipe cannot depend on a site template's theme: the site template depends on the base recipe, not the other way around.
For comparison, Varbase News Base binds its templates to Vartheme BS5, the generic starter kit theme, with 67 references, and never to a site template theme.
Re-pointing the templates at Vartheme BS5 is not a fix either. 8 of the 9 components they use (date, divider, heading, image, rich text, section, share, text) do exist there, but the 9th, the remote audio player, is RightUp's own. Adding it to Vartheme BS5 is out of scope, because nothing is to be added to Varbase for this.
2. The full view display rendered nothing on its own
core.entity_view_display.node.podcast.full.yml hid every field and rendered only links. That is workable only while a Canvas content template supplies the markup, so with the templates removed an episode page rendered an empty node. The display has to stand on its own.
This surfaced while adding the CI job in #3622806: that job had to install the RightUp theme and make it the default site theme before an episode would render at all, which is the smell that led to finding this.
Steps to reproduce
- Check out 1.0.x and grep the config directory for the site template theme name. The three Canvas content templates reference it throughout.
- Apply the recipe on a Varbase 11 site that does not have the RightUp site template installed.
- Create a Podcast episode and view it. The Canvas templates cannot resolve, and the full view display hides every field, so the page renders no episode content.
Proposed resolution
- Remove all three Canvas content templates (full, card, text card medium). They belong to the site template. This is the boundary the recipe's own AGENTS.md already states: theme components and styling are not this recipe's job. Configuration count goes from 23 to 20, and no reference to any site template theme remains anywhere in the recipe.
- Rewrite the full view display so it renders the episode from its own fields: featured image, episode number, duration, description, audio file, audio URL, transcript, tags and links. A site template that ships Canvas content templates still overrides it, which is exactly how the card and text card medium view modes already behaved.
The RightUp site template keeps its own Canvas content templates for podcasts, which is where they belong.
Remaining tasks
- Open the merge request from the issue fork for review.
- Verify an episode page renders on a stock theme with no site template installed.
- Land this before the test coverage in #3622806, so those tests are written against the corrected rendering rather than rewritten afterwards.
- Carry the Canvas content templates in the RightUp site template when RightUp is migrated onto this recipe.
User interface changes
- An episode page now renders from the field display rather than from a Canvas content template. On a site that ships its own Canvas templates for podcasts, nothing changes, because those override the field display.
API changes
- N/A
Data model changes
- N/A. No field, storage or bundle changes. Three view configuration files are removed and one is rewritten.
Release notes snippet
- Removed the Canvas content templates, which bound this recipe to a site template's theme, and rewrote the full view display so a podcast episode renders from its own fields on any theme. Canvas content templates for podcasts belong to the site template.
Checkpoints
- ✅ File an issue
- ❌ Addition/Change/Update/Fix
- ❌ Testing to ensure no regression
- ➖ Automated unit testing coverage
- ❌ Automated functional testing coverage
- ➖ UX/UI designer responsibilities
- ❌ Readability
- ➖ Accessibility
- ➖ Performance
- ➖ Security
- ❌ Developer Documentation
- ➖ User Guide Documentation
- ❌ Reviewed by a human
- ❌ Code review by maintainers
- ❌ Full testing and approval
- ❌ Credit contributors
- ❌ Review with the product owner
- ❌ Release notes snippet
- ❌ Release
Related: #3622802 shipped the recipe this corrects, and #3622806 adds the functional test coverage and CI that surfaced it. Both merge requests touch this repository, so this one lands first.
AI-Generated: Yes
Issue fork varbase_podcasts_base-3622810
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #4
rajab natshahFixed by MR !1 (28ed24c) and released in 1.0.0-alpha1: https://www.drupal.org/project/varbase_podcasts_base/releases/1.0.0-alpha1
The card and text card medium Canvas templates were dropped and the full template was re-pointed at Vartheme BS5, so nothing in the recipe references a site template theme any more, and the full view display renders an episode from its own fields.