Module to replicate the SS3 dropdown for themes in SS4.
- SS4
- SiteConfig
composer require andrewandante/silverstripe-theme-picker
This generates the dropdown from the SSViewer::themes()
- so any theme you'd like to be selectable needs to be first present in something.yml
.
SilverStripe\View\SSViewer:
themes:
- 'simple'
- 'complicated'
- '$default'
Will result in the dropdown options 'simple' and 'complicated'.
- Currently hooks onto
PageController
. - Hooks out the theme from the list and sticks it at the top.