At the top of your Skin class, you may wish to include an optional $functionality
array to initiate certain types of functionality or override default behaviors in your Skin.
In short, this is the easiest way to add functionality to your Skin. Many $functionality
parameters are available; we’ll cover the most useful ones here:
css_preprocessor
β can be eitherscss
orless
;scss
is recommendedformatting_class
β set to your desired CSS formatting class, such asgrt
fonts_google
β set totrue
to add Google Fonts to your Skinheader_image
β set totrue
to add Header Image functionality to your Skinlauncher_position
β set toright
to move the Template launcher to the bottom right portion of the screen (this only displays on the front end when the admin is logged in)legacy_image_support
β set tofalse
to remove Thesis Post Image and Thesis Post Thumbnail Boxeslogo
β set totrue
to add Logo functionality to your Skinmeta_viewport
β set to your desired<meta viewport>
declaration
Given the parameters listed above, let’s try an example and add SCSS, Google Fonts, Header Image, and Logo functionality to a Skin. Here’s what the resulting $functionality
array would look like:
public $functionality = array( 'css_preprocessor' => 'scss', 'fonts_google' => true, 'header_image' => true, 'logo' => true);
Other $functionality
parameters can be used to change default Design Options Admin behavior.
Skin Functionality Tutorials
Deprecated Skin Functionality
editor_grt
has been replaced byformatting_class
, which allows Skin authors to specify a formatting class that is used in places like the WordPress post editor and also WooCommerce template output.