Search by

drupal / saplings

Drupal-Infrastructure

Canvas-first Drupal site template for independent local businesses, with Saplings Nursery & Garden as demonstration content. No custom PHP required.

Package info

git.drupalcode.org/project/saplings.git

Homepage

Type:drupal-recipe

pkg:composer/drupal/saplings

Statistics

Installs: 1

Dependents: 0

Suggesters: 0

4.0.0 2026-11-17 13:31 UTC

This package is auto-updated.

Last update: 2026-11-17 23:16:44 UTC


README

Saplings 4.x is a Drupal 11 site template for independent local businesses: a nursery, a shop, a studio or any business with opening hours, a place to visit and things to ask about. It ships the content model, the pages and a full demo site for a fictional plant nursery, Saplings Nursery & Garden on Saltmarsh Island. The front end is the Arboretum theme (drupal/arboretum 2.x, a fork of Mercury), and every page is built in Drupal Canvas.

There is no custom PHP. A business adapts the template by editing one settings page, its logo and colors, and replacing the demo content.

Saplings is built on the Drupal CMS base. It applies no other recipe. It installs the modules and ships the config and config actions of drupal_cms_site_template_base and of the recipes the base applies (administrator and content editor roles, media types, Easy Email, forms and search) without the Utility page content type and its privacy policy node. Pages are Canvas pages; the privacy notice is the Canvas page at /privacy, and the Klaro consent dialog links to it. Editors use the Drupal CMS content editor role, with permissions for the five content types, the three vocabularies, Business settings (including opening hours), seasonal notices and form submissions. All five content types use the editorial workflow.

This branch holds the 4.0.x development line. Version 4.0.0 is not released yet; until it is, install from the repositories as described under "Installing before 4.0.0".

What ships

  • Content types (5): plant, service, workshop (event), garden note (article) and person. Plant is the one nursery-specific type; every other machine name fits any local business.
  • Taxonomies (3): plant type, growing condition and garden note topic.
  • Business settings: one Config Pages form holds the business name, address, phone, email, opening hours with dated exceptions and seasons, directions, parking, access, the map and the inquiry recipient. Every page that shows hours or contact details reads them from here.
  • Canvas: 15 pages, 10 content templates (full and card for each content type), and the header and footer as page regions.
  • Views (8): the plant catalog with filters, service, workshop, garden note and people listings, term pages, site search and an editorial dashboard, plus the Drupal CMS base's views.
  • Webforms (2): contact, where "Ask about this plant" and "Ask about this service" links preselect the topic and the item, and workshop interest. Both use an ALTCHA spam check, email the nursery's inquiry address from Business settings and send the visitor a short receipt. The contact form is the contact_form webform from Drupal CMS's forms recipe, changed by config actions.
  • Site search at /search: the Drupal CMS search index covers plants, services, workshops, garden notes, people and Canvas pages. Only published items are indexed, and each save is indexed at once, so unpublished content leaves the results as soon as it is saved. Canvas pages are searched by the words in their headings and text.
  • Seasonal notices from Site Alert, shown in a banner above the header.
  • A daily ECA model that marks past workshops as ended and saves Business settings, so cached pages drop yesterday's hours exceptions and move the "Today" row.
  • SEO: Drupal CMS's SEO title, description, image and keyword fields on every content type, Metatag and Open Graph defaults with a share image on every page (the page's own image, then the share image on Business settings, then the theme's share.png), Schema.org data (the business as a GardenStore with the id [site:base-url]/#organization, plus Event, Article, Person and Service), an XML sitemap, Pathauto patterns, redirects and breadcrumbs on detail pages.
  • Editorial: the editorial workflow, scheduled publishing on every content type, and edit forms in tabs with the SEO tab last and help text on every field. Image media has caption, credit and credit link fields.
  • Demo content: 3 people, 12 plants, 4 services, 3 workshops, 6 garden notes, 2 seasonal notices, 16 terms, 35 images, the sponsor logo and 22 menu links, plus the Drupal CMS base's Top tasks links and its "My privacy settings" footer link, which Klaro enables when a service needs consent.

Requirements

  • PHP 8.3 and Drupal core 11.4 or later, set up as a Drupal CMS 2.2 project (drupal/cms).
  • Drupal Canvas 1.11 or later.
  • The Arboretum theme (drupal/arboretum 2.x). A recipe cannot ship a theme, so Arboretum is a separate Composer package that this recipe requires.

Installing

Once 4.0.0 is published on drupal.org, with the Drupal CMS installer:

composer create-project drupal/cms my-site
cd my-site
composer require drupal/saplings

Open the site in a browser and choose Saplings on the "Choose a template" step.

With Drush:

drush site:install ../recipes/saplings --site-name="Saplings Nursery & Garden" -y

Pass --site-name. The recipe sets the site name, but drush site:install overwrites it with "Drush Site-Install" when the option is missing.

Search and the XML sitemap fill on the first page request after install. Drupal CMS includes Automated Cron, and a new site has never run cron, so the first visit runs it: cron indexes all demo content and writes the sitemap. On a site that already ran cron, run drush cron once.

Installing before 4.0.0

This is the setup of the verification site the versions below were checked on. It uses DDEV; the folder names are examples.

  1. Clone both repositories side by side, on their development branches:

    mkdir saplings-work && cd saplings-work
    git clone -b 4.x https://github.com/kanopi/saplings.git saplings
    git clone -b 2.x https://github.com/kanopi/arboretum.git arboretum
    mkdir site-cms && cd site-cms
    
  2. Create a DDEV project and a Drupal CMS codebase. drupal/cms ships its own .ddev/config.yaml, so set the project name in it afterwards and run ddev restart:

    ddev config --project-type=drupal11 --docroot=web
    ddev start
    ddev composer create-project drupal/cms
    
  3. Mount the clones into the web container, so Composer's relative path repositories resolve there as on the host. Save this as .ddev/docker-compose.sources.yaml, then run ddev restart:

    services:
      web:
        volumes:
          - "../..:/var/www/sources:cached"
          - "../../saplings:/var/www/saplings:cached"
          - "../../arboretum:/var/www/arboretum:cached"
    
  4. Add the clones as path repositories, before the drupal repository in composer.json, and require them:

    {"type": "path", "url": "../saplings", "options": {"symlink": true, "versions": {"drupal/saplings": "4.0.x-dev"}}},
    {"type": "path", "url": "../arboretum", "options": {"symlink": true, "versions": {"drupal/arboretum": "2.0.x-dev"}}}
    
    ddev composer require "drupal/saplings:@dev" "drupal/arboretum:2.0.x-dev as 2.0.0" -W
    

    Composer places the recipe at recipes/saplings and moves its requirements into the project.

  5. Install the site and log in:

    ddev drush site:install ../recipes/saplings --site-name="Saplings Nursery & Garden" -y
    ddev launch $(ddev drush user:login)
    

The demo site sends mail to DDEV's Mailpit (ddev mailpit).

Adapting it for another business

  1. Edit Business settings at /admin/structure/config_pages/business_settings/edit: name, address, phone, public email, inquiry recipient, opening hours, directions, parking, access and map. The hours panel, location panel, footer, contact page and structured data all read from it.
  2. Set the site name, slogan and email at /admin/config/system/site-information, and the time zone at /admin/config/regional/settings. Opening hours, workshop times and the "Today" row in the hours panel use the site time zone.
  3. Replace the logo at /admin/appearance/settings/arboretum. Leave "The logo includes the site name" checked for a wordmark.
  4. Rebrand the colors and fonts in Arboretum's src/theme.css and src/fonts.css. Copy either file next to index.php to override it for one site without rebuilding the theme. Arboretum's CUSTOMIZING.md explains the tokens.
  5. Decide what to do with the plant catalog. A nursery keeps it. Another business can relabel the Plant type and its two vocabularies (for example as products and categories), or delete them: remove the plant content, the Plants page and menu links, the plant_catalog view, the plant field on the contact form, the plant type and growing condition vocabularies and their Pathauto patterns, and then the content type with its two content templates.
  6. Rename the Workshop and Garden note labels and paths if they do not fit. The machine names (event, article) stay.
  7. Change the business type in the front page Metatag defaults at /admin/config/search/metatag. The recipe describes the business as a GardenStore; pick the closest schema.org LocalBusiness type. The Event, Article, Person and Service defaults point at the same business through its id, /#organization. Set the share image on the Business settings page (Sharing), 1200 by 630 pixels. Pages without their own image use it when shared; without it, they use share.png in the Arboretum theme folder.
  8. Replace the demo content: people, plants, services, workshops, garden notes, seasonal notices and images. Give every image alt text, a caption where it helps, and a credit with a credit link for anything you did not make. Rewrite the About, Accessibility, Privacy and Credits pages in Canvas.
  9. Edit the three menus at /admin/structure/menu: main (every header link, on desktop and in the mobile menu), footer (two groups under <nolink> headings, shown as columns) and utility.
  10. Set up mail delivery. The recipe sends through Easy Email and Symfony Mailer Lite with its default transport; a production site adds an SMTP or provider transport at /admin/config/system/symfony-mailer-lite/transport and makes it the default.

Before launch, add the services a host or the business needs, which the template leaves out: Google Tag (drupal/google_tag, with the site's own container ID), virus scanning of uploads (ClamAV), a launch checklist and HTTP header hardening.

Forms and JavaScript

ALTCHA needs JavaScript in the visitor's browser, so the forms cannot be submitted with JavaScript turned off. The visitor sees "The answer you entered for the CAPTCHA was not correct." If this matters for your audience, list another way to reach the nursery, such as the contact email or phone on the contact page.

Accounts and roles

Editors get the content_editor role. An account without an editor role sees the public site only: no admin sidebar, no Coffee search box and no admin theme. The five permissions behind those (access administration pages, access coffee, access contextual links, access navigation and view the administration theme) belong to content_editor, not to authenticated. Keep it that way when adding visitor accounts.

Images

Every photo and portrait in the demo was generated for the Saltmarsh site templates; none is a stock or licensed photo. Each one ships with alt text and a credit. The /credits page credits the people, the sponsor and the AI agents that made the site; each media item keeps its own credit field.

GroupCountUse
Nursery scenes10Home and interior page heroes, the story band and services
Plants12Plant cards and plant pages, one per species
Workshop covers3Workshop cards and pages
Garden note covers6Garden note cards and pages
Staff portraits3Person cards and pages; the people are fictional
Illustrated map1Visit page and location panel; drawn from the Saltmarsh Island atlas, not to scale
Logo1SVG, the sprout from the Saplings project logo beside the word "Saplings", sized to the sprout's height

The 34 generated images and the map are image media items (35 in all); the logo is a file set in theme settings, and the Kanopi Studios sponsor logo on the Credits page is an SVG media item. No image shows readable hours, prices or dates.

The plant images and plant facts have not been checked by a botanist. They ship marked as not reviewed, and the Credits page says so. Have each species and its native status checked before a real nursery publishes them.

Upgrading from 3.x

Saplings 4.x is a new site template, not an upgrade of 3.x.

  • The 3.x line (kanopi/saplings with its sub-recipes, Paragraphs and a Bootstrap theme) is frozen at the 4.0.0 release. There are no further 3.x releases. The code stays on the 3.x branch.
  • Recipes are applied once. A 3.x site already owns its config and content, so releasing 4.x changes nothing on it.
  • There is no automated upgrade path. Moving a 3.x site to Canvas and Arboretum is a per-site migration project: its Paragraphs content has to be rebuilt as Canvas pages and content templates.
  • The 4.x package name is drupal/saplings. The 3.x README documents kanopi/saplings:^1; that package keeps the 3.x code.

Known issues

  • A site that already ran cron has no first request to fill search and the sitemap. Run drush cron once after applying the recipe.
  • The workshop registration page, /workshops/register, is listed in the sitemap. Simple Sitemap keeps per-page exclusions outside config, so a site that wants it out sets that on the page.
  • The demo content has no dated hours exceptions (holiday closures or changed hours). Office Hours 1.29.0 logs the PHP warning Undefined array key "day_delta" when they import as default content, and the install test fails on it. They return to the demo content once Office Hours fixes it. Editors can still add exceptions on the business settings page.
  • The pricing card and testimonial card components ship turned off, because the nursery does not show prices or quotes in cards. Turn them on at /admin/structure/component to place them.

Demo business

Saplings Nursery & Garden is at 62 Pine Reach Road in Pine Reach, on the fictional Saltmarsh Island, Massachusetts. All names, people, phone numbers and email addresses are invented, and the .example domains do not resolve.

Verified versions

Checked on 12 November 2026 on a Drupal CMS verification site (clean install, every alias returns 200, every internal link resolves, zero watchdog errors):

PackageVersion
PHP8.4
Drupal core11.4.12
Drupal CMS base (drupal_cms_site_template_base)2.2.9
Drush13.8.1
Canvas1.12.0
Arboretum (Mercury 1.0.5 fork)2.x
Office Hours1.29.0
Config Pages4.0.1
Webform6.3.1
ALTCHA1.2.1
Search API1.43.0
Klaro3.1.2
Easy Email3.0.9
ECA3.1.11
Modeler1.0.9
Metatag2.2.7
Real-time SEO (Yoast SEO)2.2.0
Schema Metatag3.1.0
Pathauto1.16.0
Redirect1.13.0
Simple Sitemap4.2.3
Site Alert1.4.0
Symfony Mailer Lite2.0.4
Gin5.0.16