Problem/Motivation

At the moment, SiteTemplateForm makes no assumptions about the recipes having, or not having, screenshots. That is handled entirely by the installer's theme.

Now that SiteTemplateForm can load externally-provided information about available site templates, it needs to be able to figure out where the screenshots might live, and how to surface them to the form (and thence to the theme).

Proposed resolution

SiteTemplateForm::getChoices() will set a $choices[$name]['extra']['screenshot'] key, which is the absolute path of screenshot.yml, if it exists.

Command icon 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

phenaproxima created an issue. See original summary.

phenaproxima’s picture

Issue summary: View changes
phenaproxima’s picture

Issue summary: View changes

phenaproxima’s picture

Title: SiteTemplateForm::getChoices() should compute a screenshot from the recipe's `extra` section » SiteTemplateForm::getChoices() should resolve the site templates' screenshots

  • phenaproxima committed e163dd22 on 1.x
    feat: #3574322 SiteTemplateForm::getChoices() should resolve the site...
phenaproxima’s picture

Status: Active » Fixed

Manually tested and this worked well (albeit requiring a few small changes in the theme). In the name of keeping this moving, merged into 1.x.

Now that this issue is closed, review the contribution record.

As a contributor, attribute any organization that helped you, or if you volunteered your own time.

Maintainers, credit people who helped resolve this issue.

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.