Pluggable themes for Yii2
This Yii2 plugin provides easy theming for Yii2 projects.
And allows to create and use themes as composer packages.
So changing a theme on a site becomes as simple as changing
a single require line in composer.json
.
At the moment there are several themes available:
This package is not intended to be required directly in your project. Instead you should require theme(s) you've chosen and this package will get required as a dependency.
Please see hiqdev/hisite-template as example of project using this theming library.
The main goal of this theming library is to allow creation and use of easy
pluggable themes: to change a theme on a site it is enough just to require
other theme package in project's composer.json
.
To achieve this goal several technologies were used:
pathMap
auto assembling;This package provides:
ThemeManager
component that collects and setups in application view
proper Theme
object with proper pathMap
;DebugPanel
showing actual pathMap
.This extension is supposed to be used with composer-config-plugin.
Also you can use it usual way by copy-pasting config. See src/config/web.php for configuration example.
Available configuration parameters:
themeManager.defaultTheme
- default themecopyright.year
- CopyrightYears widgetcopyright.years
logo.url
- LogoLink widgetlogo.name
logo.options
logo.image
logo.imageOptions
logo.smallImage
logo.smallImageOptions
organization.url
- OrganizationLink widgetorganization.name
organization.options
poweredBy.url
- PoweredBy widgetpoweredBy.name
poweredBy.version
poweredBy.options
socialLinks.links
- SocialLinks widgetFor more details please see src/config/params.php.
This project is released under the terms of the BSD-3-Clause license. Read more here.
Copyright © 2015-2017, HiQDev (http://hiqdev.com/)