text: (window.webpackJsonp=window.webpackJsonp||[]).push([[12],{167:function(t,e,a){"use strict";a.r(e);a(46),a(72),a(73);var s={props:["slot-key"],mounted:function(){this.$nextTick(function(){this.$vuepress.$emit("AsyncMarkdownContentMounted",this.slotKey)})}},n=a(6),r=Object(n.a)(s,function(){var t=this,e=t.$createElement,a=t._self._c||e;return a("ContentSlotsDistributor",{attrs:{"slot-key":t.slotKey}},[a("h1",{attrs:{id:"themes"}},[a("a",{staticClass:"header-anchor",attrs:{href:"#themes","aria-hidden":"true"}},[t._v("#")]),t._v(" Themes")]),t._v(" "),a("div",{staticClass:"badges"},[a("p",[a("a",{attrs:{href:"https://github.com/caffeinated/themes",target:"_blank",rel:"noopener noreferrer"}},[a("img",{attrs:{src:"https://img.shields.io/badge/source-caffeinated/themes-blue.svg?style=flat-square",alt:"Source"}}),a("OutboundLink")],1),t._v(" "),a("a",{attrs:{href:"https://packagist.org/packages/caffeinated/themes",target:"_blank",rel:"noopener noreferrer"}},[a("img",{attrs:{src:"https://poser.pugx.org/caffeinated/themes/v/stable?format=flat-square",alt:"Latest Stable Version"}}),a("OutboundLink")],1),t._v(" "),a("a",{attrs:{href:"https://tldrlegal.com/license/mit-license",target:"_blank",rel:"noopener noreferrer"}},[a("img",{attrs:{src:"https://img.shields.io/badge/license-MIT-brightgreen.svg?style=flat-square",alt:"License"}}),a("OutboundLink")],1),t._v(" "),a("a",{attrs:{href:"https://packagist.org/packages/caffeinated/themes",target:"_blank",rel:"noopener noreferrer"}},[a("img",{attrs:{src:"https://img.shields.io/packagist/dt/caffeinated/themes.svg?style=flat-square",alt:"Total Downloads"}}),a("OutboundLink")],1)])]),t._v(" "),a("p",[t._v("Gives your application the means to group together a set of views and assets. Giving you an easy way to further decouple the way your application looks from your code base.")]),t._v(" "),a("p"),a("div",{staticClass:"table-of-contents"},[a("ul",[a("li",[a("a",{attrs:{href:"#installation"}},[t._v("Installation")]),a("ul",[a("li",[a("a",{attrs:{href:"#config"}},[t._v("Config")])])])]),a("li",[a("a",{attrs:{href:"#basic-usage"}},[t._v("Basic Usage")]),a("ul",[a("li",[a("a",{attrs:{href:"#creating-themes"}},[t._v("Creating Themes")])]),a("li",[a("a",{attrs:{href:"#manifest"}},[t._v("Manifest")])]),a("li",[a("a",{attrs:{href:"#autoloading"}},[t._v("Autoloading")])]),a("li",[a("a",{attrs:{href:"#service-providers"}},[t._v("Service Providers")])])])]),a("li",[a("a",{attrs:{href:"#helpers"}},[t._v("Helpers")]),a("ul",[a("li",[a("a",{attrs:{href:"#theme-path"}},[t._v("theme_path")])])])]),a("li",[a("a",{attrs:{href:"#api-reference"}},[t._v("API Reference")]),a("ul",[a("li",[a("a",{attrs:{href:"#set"}},[t._v("set")])]),a("li",[a("a",{attrs:{href:"#path"}},[t._v("path")])]),a("li",[a("a",{attrs:{href:"#getlayout"}},[t._v("getLayout")])]),a("li",[a("a",{attrs:{href:"#setlayout"}},[t._v("setLayout")])]),a("li",[a("a",{attrs:{href:"#setcurrent"}},[t._v("setCurrent")])]),a("li",[a("a",{attrs:{href:"#getcurrent"}},[t._v("getCurrent")])]),a("li",[a("a",{attrs:{href:"#iscurrently"}},[t._v("isCurrently")])])])])])]),a("p"),t._v(" "),a("h2",{attrs:{id:"installation"}},[a("a",{staticClass:"header-anchor",attrs:{href:"#installation","aria-hidden":"true"}},[t._v("#")]),t._v(" Installation")]),t._v(" "),a("p",[t._v("Simply install the package through Composer. From here the package will automatically register its service provider and "),a("code",[t._v("Theme")]),t._v(" facade.")]),t._v(" "),a("div",{staticClass:"language- extra-class"},[a("pre",{pre:!0,attrs:{class:"language-text"}},[a("code",[t._v("composer require caffeinated/themes\n")])])]),a("h3",{attrs:{id:"config"}},[a("a",{staticClass:"header-anchor",attrs:{href:"#config","aria-hidden":"true"}},[t._v("#")]),t._v(" Config")]),t._v(" "),a("p",[t._v("To publish the config file, run the following:")]),t._v(" "),a("div",{staticClass:"language- extra-class"},[a("pre",{pre:!0,attrs:{class:"language-text"}},[a("code",[t._v('php artisan vendor:publish --provider="Caffeinated\\Themes\\ThemesServiceProvider" --tag="config"\n')])])]),a("p",[t._v("Below you will find the contents of the provided config file for reference.")]),t._v(" "),a("div",{staticClass:"language-php extra-class"},[a("pre",{pre:!0,attrs:{class:"language-php"}},[a("code",[a("span",{attrs:{class:"token php language-php"}},[a("span",{attrs:{class:"token delimiter important"}},[t._v("<?php")]),t._v("\n\n"),a("span",{attrs:{class:"token keyword"}},[t._v("return")]),t._v(" "),a("span",{attrs:{class:"token punctuation"}},[t._v("[")]),t._v("\n\n\t"),a("span",{attrs:{class:"token comment"}},[t._v("/*\n\t|--------------------------------------------------------------------------\n\t| Default Active Theme\n\t|--------------------------------------------------------------------------\n\t|\n\t| Assign the default active theme to be used if one is not set during\n\t| runtime. This is especially useful if you're developing a very basic\n\t| application that does not require dynamically changing the theme.\n\t|\n\t*/")]),t._v("\n\n\t"),a("span",{attrs:{class:"token single-quoted-string string"}},[t._v("'active'")]),t._v(" "),a("span",{attrs:{class:"token operator"}},[t._v("=")]),a("span",{attrs:{class:"token operator"}},[t._v(">")]),t._v(" "),a("span",{attrs:{class:"token single-quoted-string string"}},[t._v("'bootstrap'")]),a("span",{attrs:{class:"token punctuation"}},[t._v(",")]),t._v("\n\n\t"),a("span",{attrs:{class:"token comment"}},[t._v("/*\n\t|--------------------------------------------------------------------------\n\t| Default Author\n\t|--------------------------------------------------------------------------\n\t|\n\t| Define your default author name. This is used when generating themes.\n\t| We will use this value in the generated theme manifest file so that\n\t| you may reference the author of your themes in your application.\n\t|\n\t*/")]),t._v("\n\n\t"),a("span",{attrs:{class:"token single-quoted-string string"}},[t._v("'author'")]),t._v(" "),a("span",{attrs:{class:"token operator"}},[t._v("=")]),a("span",{attrs:{class:"token operator"}},[t._v(">")]),t._v(" "),a("span",{attrs:{class:"token single-quoted-string string"}},[t._v("''")]),a("span",{attrs:{class:"token punctuation"}},[t._v(",")]),t._v("\n\n\t"),a("span",{attrs:{class:"token comment"}},[t._v("/*\n\t|--------------------------------------------------------------------------\n\t| Default Vendor\n\t|--------------------------------------------------------------------------\n\t|\n\t| Define your default vendor name. This is used when generating themes.\n\t| We will use this value in the generated composer file so that you\n\t| may register your themes as a composer package as well.\n\t|\n\t*/")]),t._v("\n\t\n\t"),a("span",{attrs:{class:"token single-quoted-string string"}},[t._v("'vendor'")]),t._v(" "),a("span",{attrs:{class:"token operator"}},[t._v("=")]),a("span",{attrs:{class:"token operator"}},[t._v(">")]),t._v(" "),a("span",{attrs:{class:"token single-quoted-string string"}},[t._v("'vendor'")]),a("span",{attrs:{class:"token punctuation"}},[t._v(",")]),t._v("\n\n"),a("span",{attrs:{class:"token punctuation"}},[t._v("]")]),a("span",{attrs:{class:"token punctuation"}},[t._v(";")]),t._v("\n")])])])]),a("h2",{attrs:{id:"basic-usage"}},[a("a",{staticClass:"header-anchor",attrs:{href:"#basic-usage","aria-hidden":"true"}},[t._v("#")]),t._v(" Basic Usage")]),t._v(" "),a("h3",{attrs:{id:"creating-themes"}},[a("a",{staticClass:"header-anchor",attrs:{href:"#creating-themes","aria-hidden":"true"}},[t._v("#")]),t._v(" Creating Themes")]),t._v(" "),a("p",[t._v("Themes can be created by the use of the "),a("code",[t._v("make:theme")]),t._v(" Artisan command:")]),t._v(" "),a("div",{staticClass:"language- extra-class"},[a("pre",{pre:!0,attrs:{class:"language-text"}},[a("code",[t._v("php artisan make:theme Bootstrap\n")])])]),a("p",[t._v("This command will generate all the necessary files and folders to get you up and running quickly at "),a("code",[t._v("themes/Bootstrap")]),t._v(".")]),t._v(" "),a("p",[t._v("You'll notice that the structure of themes resemble that of Composer packages. This is intentional and should feel immediately familiar to you. Nothing too scary here!")]),t._v(" "),a("h3",{attrs:{id:"manifest"}},[a("a",{staticClass:"header-anchor",attrs:{href:"#manifest","aria-hidden":"true"}},[t._v("#")]),t._v(" Manifest")]),t._v(" "),a("p",[t._v("One of the important files that "),a("strong",[t._v("must")]),t._v(" be present at the root of every theme, is the theme's manifest file: "),a("code",[t._v("theme.json")]),t._v(". This file contains the info and identification of your theme. You may also use this to store theme-specific settings if you wish. Let's look at the contents provided out of the box and go over each in detail:")]),t._v(" "),a("div",{staticClass:"language-json extra-class"},[a("pre",{pre:!0,attrs:{class:"language-json"}},[a("code",[a("span",{attrs:{class:"token punctuation"}},[t._v("{")]),t._v("\n\t"),a("span",{attrs:{class:"token property"}},[t._v('"name"')]),a("span",{attrs:{class:"token operator"}},[t._v(":")]),t._v(" "),a("span",{attrs:{class:"token string"}},[t._v('"Bootstrap"')]),a("span",{attrs:{class:"token punctuation"}},[t._v(",")]),t._v("\n\t"),a("span",{attrs:{class:"token property"}},[t._v('"slug"')]),a("span",{attrs:{class:"token operator"}},[t._v(":")]),t._v(" "),a("span",{attrs:{class:"token string"}},[t._v('"bootstrap"')]),a("span",{attrs:{class:"token punctuation"}},[t._v(",")]),t._v("\n    "),a("span",{attrs:{class:"token property"}},[t._v('"description"')]),a("span",{attrs:{class:"token operator"}},[t._v(":")]),t._v(" "),a("span",{attrs:{class:"token string"}},[t._v('"Bootstrap your application with this awesome theme."')]),a("span",{attrs:{class:"token punctuation"}},[t._v(",")]),t._v("\n    "),a("span",{attrs:{class:"token property"}},[t._v('"author"')]),a("span",{attrs:{class:"token operator"}},[t._v(":")]),t._v(" "),a("span",{attrs:{class:"token string"}},[t._v('"John Doe"')]),a("span",{attrs:{class:"token punctuation"}},[t._v(",")]),t._v("\n\t"),a("span",{attrs:{class:"token property"}},[t._v('"version"')]),a("span",{attrs:{class:"token operator"}},[t._v(":")]),t._v(" "),a("span",{attrs:{class:"token string"}},[t._v('"1.0"')]),a("span",{attrs:{class:"token punctuation"}},[t._v(",")]),t._v("\n"),a("span",{attrs:{class:"token punctuation"}},[t._v("}")]),t._v("\n")])])]),a("table",[a("thead",[a("tr",[a("th",[t._v("Property")]),t._v(" "),a("th",[t._v("Description")])])]),t._v(" "),a("tbody",[a("tr",[a("td",[t._v("name "),a("strong",[t._v("*")])]),t._v(" "),a("td",[t._v("The human-readable name of your theme.")])]),t._v(" "),a("tr",[a("td",[t._v("slug "),a("strong",[t._v("*")])]),t._v(" "),a("td",[t._v("The slug of your theme used to reference in commands and code.")])]),t._v(" "),a("tr",[a("td",[t._v("version")]),t._v(" "),a("td",[t._v("The version of your theme.")])]),t._v(" "),a("tr",[a("td",[t._v("description")]),t._v(" "),a("td",[t._v("A simple description of your theme.")])]),t._v(" "),a("tr",[a("td",[t._v("author")]),t._v(" "),a("td",[t._v("The author of your theme.")])])])]),t._v(" "),a("p",[a("strong",[t._v("*")]),t._v(" These properties are required in every manifest.")]),t._v(" "),a("h3",{attrs:{id:"autoloading"}},[a("a",{staticClass:"header-anchor",attrs:{href:"#autoloading","aria-hidden":"true"}},[t._v("#")]),t._v(" Autoloading")]),t._v(" "),a("p",[t._v("When activating your theme, we will automatically register a PSR-4 reference to your theme for you. This ensures a smooth experience during development. And don't worry, we won't re-register your theme if your theme has been installed through Composer - that'd be just silly.")]),t._v(" "),a("h3",{attrs:{id:"service-providers"}},[a("a",{staticClass:"header-anchor",attrs:{href:"#service-providers","aria-hidden":"true"}},[t._v("#")]),t._v(" Service Providers")]),t._v(" "),a("p",[t._v("One of the cool things about themes, is their ability to provide their own set of resources and routes to your application. This is great for one-off application needs that may be tied directly to your theme. Keeps all the logic contained without muddying up your main application.")]),t._v(" "),a("p",[t._v("A "),a("code",[t._v("ThemeServiceProvider")]),t._v(" and "),a("code",[t._v("RouteServiceProvider")]),t._v(" is provided out of the box. Feel free to modify these files or create your own service providers as needed.")]),t._v(" "),a("div",{staticClass:"tip custom-block"},[a("p",{staticClass:"custom-block-title"},[t._v("NOTE")]),t._v(" "),a("p",[t._v("Be sure to register your custom service providers within your "),a("code",[t._v("ThemeServiceProvider")]),t._v(". Refer to Laravel's service provider "),a("a",{attrs:{href:"https://laravel.com/docs/5.7/providers",target:"_blank",rel:"noopener noreferrer"}},[t._v("documentation"),a("OutboundLink")],1),t._v(" as needed.")])]),t._v(" "),a("h2",{attrs:{id:"helpers"}},[a("a",{staticClass:"header-anchor",attrs:{href:"#helpers","aria-hidden":"true"}},[t._v("#")]),t._v(" Helpers")]),t._v(" "),a("p",[t._v('Caffeinated Themes includes a global "helper" PHP function. This is used by the package itself; however, you are free to use it in your own code if you find it convenient.')]),t._v(" "),a("hr"),t._v(" "),a("div",{staticClass:"collection-method-list"},[a("p",[a("a",{attrs:{href:"#theme-path"}},[t._v("theme_path")])])]),t._v(" "),a("h3",{attrs:{id:"theme-path"}},[a("a",{staticClass:"header-anchor",attrs:{href:"#theme-path","aria-hidden":"true"}},[t._v("#")]),t._v(" theme_path")]),t._v(" "),a("p",[t._v("The "),a("code",[t._v("theme_path")]),t._v(" function returns the fully qualified path to either the currently active or specified theme's directory (passed via the second parameter).")]),t._v(" "),a("div",{staticClass:"language-php extra-class"},[a("pre",{pre:!0,attrs:{class:"language-php"}},[a("code",[a("span",{attrs:{class:"token variable"}},[t._v("$path")]),t._v(" "),a("span",{attrs:{class:"token operator"}},[t._v("=")]),t._v(" "),a("span",{attrs:{class:"token function"}},[t._v("theme_path")]),a("span",{attrs:{class:"token punctuation"}},[t._v("(")]),a("span",{attrs:{class:"token single-quoted-string string"}},[t._v("'resources/js/bootstrap.js'")]),a("span",{attrs:{class:"token punctuation"}},[t._v(")")]),a("span",{attrs:{class:"token punctuation"}},[t._v(";")]),t._v("\n\n"),a("span",{attrs:{class:"token variable"}},[t._v("$path")]),t._v(" "),a("span",{attrs:{class:"token operator"}},[t._v("=")]),t._v(" "),a("span",{attrs:{class:"token function"}},[t._v("theme_path")]),a("span",{attrs:{class:"token punctuation"}},[t._v("(")]),a("span",{attrs:{class:"token single-quoted-string string"}},[t._v("'resources/js/bootstrap.js'")]),a("span",{attrs:{class:"token punctuation"}},[t._v(",")]),t._v(" "),a("span",{attrs:{class:"token single-quoted-string string"}},[t._v("'bootstrap'")]),a("span",{attrs:{class:"token punctuation"}},[t._v(")")]),a("span",{attrs:{class:"token punctuation"}},[t._v(";")]),t._v("\n")])])]),a("h2",{attrs:{id:"api-reference"}},[a("a",{staticClass:"header-anchor",attrs:{href:"#api-reference","aria-hidden":"true"}},[t._v("#")]),t._v(" API Reference")]),t._v(" "),a("p",[t._v("The base theme class is actually an extension of Laravel's Collection class. So, by proxy you will have access to all the methods provided by "),a("a",{attrs:{href:"https://laravel.com/docs/5.7/collections",target:"_blank",rel:"noopener noreferrer"}},[t._v("Collections"),a("OutboundLink")],1),t._v(" as well as the additions outlined below.")]),t._v(" "),a("div",{staticClass:"collection-method-list"},[a("p",[a("a",{attrs:{href:"#set"}},[t._v("set")]),t._v(" "),a("a",{attrs:{href:"#path"}},[t._v("path")]),t._v(" "),a("a",{attrs:{href:"#getLayout"}},[t._v("getLayout")]),t._v(" "),a("a",{attrs:{href:"#setLayout"}},[t._v("setLayout")]),t._v(" "),a("a",{attrs:{href:"#setCurrent"}},[t._v("setCurrent")]),t._v(" "),a("a",{attrs:{href:"#getCurrent"}},[t._v("getCurrent")]),t._v(" "),a("a",{attrs:{href:"#isCurrently"}},[t._v("isCurrently")])])]),t._v(" "),a("h3",{attrs:{id:"set"}},[a("a",{staticClass:"header-anchor",attrs:{href:"#set","aria-hidden":"true"}},[t._v("#")]),t._v(" set")]),t._v(" "),a("p",[t._v("Set the currently active theme.")]),t._v(" "),a("div",{staticClass:"language-php extra-class"},[a("pre",{pre:!0,attrs:{class:"language-php"}},[a("code",[t._v("Theme"),a("span",{attrs:{class:"token punctuation"}},[t._v(":")]),a("span",{attrs:{class:"token punctuation"}},[t._v(":")]),a("span",{attrs:{class:"token function"}},[t._v("set")]),a("span",{attrs:{class:"token punctuation"}},[t._v("(")]),a("span",{attrs:{class:"token single-quoted-string string"}},[t._v("'bootstrap'")]),a("span",{attrs:{class:"token punctuation"}},[t._v(")")]),a("span",{attrs:{class:"token punctuation"}},[t._v(";")]),t._v("\n")])])]),a("h3",{attrs:{id:"path"}},[a("a",{staticClass:"header-anchor",attrs:{href:"#path","aria-hidden":"true"}},[t._v("#")]),t._v(" path")]),t._v(" "),a("p",[t._v("Get the path of the given theme file. By default will reference the currently set theme. You may optionally pass the second parameter through with the slug of the theme you wish to target.")]),t._v(" "),a("div",{staticClass:"language-php extra-class"},[a("pre",{pre:!0,attrs:{class:"language-php"}},[a("code",[t._v("Theme"),a("span",{attrs:{class:"token punctuation"}},[t._v(":")]),a("span",{attrs:{class:"token punctuation"}},[t._v(":")]),a("span",{attrs:{class:"token function"}},[t._v("path")]),a("span",{attrs:{class:"token punctuation"}},[t._v("(")]),a("span",{attrs:{class:"token single-quoted-string string"}},[t._v("'resources/js/bootstrap.js'")]),a("span",{attrs:{class:"token punctuation"}},[t._v(")")]),a("span",{attrs:{class:"token punctuation"}},[t._v(";")]),t._v("\n\nTheme"),a("span",{attrs:{class:"token punctuation"}},[t._v(":")]),a("span",{attrs:{class:"token punctuation"}},[t._v(":")]),a("span",{attrs:{class:"token function"}},[t._v("path")]),a("span",{attrs:{class:"token punctuation"}},[t._v("(")]),a("span",{attrs:{class:"token single-quoted-string string"}},[t._v("'resources/js/bootstrap.js'")]),a("span",{attrs:{class:"token punctuation"}},[t._v(",")]),t._v(" "),a("span",{attrs:{class:"token single-quoted-string string"}},[t._v("'bootstrap'")]),a("span",{attrs:{class:"token punctuation"}},[t._v(")")]),a("span",{attrs:{class:"token punctuation"}},[t._v(";")]),t._v("\n")])])]),a("h3",{attrs:{id:"getlayout"}},[a("a",{staticClass:"header-anchor",attrs:{href:"#getlayout","aria-hidden":"true"}},[t._v("#")]),t._v(" getLayout")]),t._v(" "),a("p",[t._v("Return the currently set theme layout property.")]),t._v(" "),a("div",{staticClass:"language-php extra-class"},[a("pre",{pre:!0,attrs:{class:"language-php"}},[a("code",[t._v("Theme"),a("span",{attrs:{class:"token punctuation"}},[t._v(":")]),a("span",{attrs:{class:"token punctuation"}},[t._v(":")]),a("span",{attrs:{class:"token function"}},[t._v("getLayout")]),a("span",{attrs:{class:"token punctuation"}},[t._v("(")]),a("span",{attrs:{class:"token punctuation"}},[t._v(")")]),a("span",{attrs:{class:"token punctuation"}},[t._v(";")]),t._v("\n")])])]),a("h3",{attrs:{id:"setlayout"}},[a("a",{staticClass:"header-anchor",attrs:{href:"#setlayout","aria-hidden":"true"}},[t._v("#")]),t._v(" setLayout")]),t._v(" "),a("p",[t._v("Set the active theme layout property.")]),t._v(" "),a("div",{staticClass:"language-php extra-class"},[a("pre",{pre:!0,attrs:{class:"language-php"}},[a("code",[t._v("Theme"),a("span",{attrs:{class:"token punctuation"}},[t._v(":")]),a("span",{attrs:{class:"token punctuation"}},[t._v(":")]),a("span",{attrs:{class:"token function"}},[t._v("setLayout")]),a("span",{attrs:{class:"token punctuation"}},[t._v("(")]),a("span",{attrs:{class:"token single-quoted-string string"}},[t._v("'admin'")]),a("span",{attrs:{class:"token punctuation"}},[t._v(")")]),a("span",{attrs:{class:"token punctuation"}},[t._v(";")]),t._v("\n")])])]),a("h3",{attrs:{id:"setcurrent"}},[a("a",{staticClass:"header-anchor",attrs:{href:"#setcurrent","aria-hidden":"true"}},[t._v("#")]),t._v(" setCurrent")]),t._v(" "),a("p",[t._v("Manually set the currently active theme property. Recommended means of setting the currently active theme is through the "),a("code",[t._v("set")]),t._v(" method to properly resolve your theme resources.")]),t._v(" "),a("div",{staticClass:"language-php extra-class"},[a("pre",{pre:!0,attrs:{class:"language-php"}},[a("code",[t._v("Theme"),a("span",{attrs:{class:"token punctuation"}},[t._v(":")]),a("span",{attrs:{class:"token punctuation"}},[t._v(":")]),a("span",{attrs:{class:"token function"}},[t._v("setCurrent")]),a("span",{attrs:{class:"token punctuation"}},[t._v("(")]),a("span",{attrs:{class:"token single-quoted-string string"}},[t._v("'bootstrap'")]),a("span",{attrs:{class:"token punctuation"}},[t._v(")")]),a("span",{attrs:{class:"token punctuation"}},[t._v(";")]),t._v("\n")])])]),a("h3",{attrs:{id:"getcurrent"}},[a("a",{staticClass:"header-anchor",attrs:{href:"#getcurrent","aria-hidden":"true"}},[t._v("#")]),t._v(" getCurrent")]),t._v(" "),a("p",[t._v("Return the slug of the currently active theme.")]),t._v(" "),a("div",{staticClass:"language-php extra-class"},[a("pre",{pre:!0,attrs:{class:"language-php"}},[a("code",[t._v("Theme"),a("span",{attrs:{class:"token punctuation"}},[t._v(":")]),a("span",{attrs:{class:"token punctuation"}},[t._v(":")]),a("span",{attrs:{class:"token function"}},[t._v("getCurrent")]),a("span",{attrs:{class:"token punctuation"}},[t._v("(")]),a("span",{attrs:{class:"token punctuation"}},[t._v(")")]),a("span",{attrs:{class:"token punctuation"}},[t._v(";")]),t._v("\n")])])]),a("h3",{attrs:{id:"iscurrently"}},[a("a",{staticClass:"header-anchor",attrs:{href:"#iscurrently","aria-hidden":"true"}},[t._v("#")]),t._v(" isCurrently")]),t._v(" "),a("p",[t._v("Checks if the passed slug is the currently active theme. Returns a boolean value.")]),t._v(" "),a("div",{staticClass:"language-php extra-class"},[a("pre",{pre:!0,attrs:{class:"language-php"}},[a("code",[a("span",{attrs:{class:"token keyword"}},[t._v("if")]),t._v(" "),a("span",{attrs:{class:"token punctuation"}},[t._v("(")]),t._v("Theme"),a("span",{attrs:{class:"token punctuation"}},[t._v(":")]),a("span",{attrs:{class:"token punctuation"}},[t._v(":")]),a("span",{attrs:{class:"token function"}},[t._v("isCurrently")]),a("span",{attrs:{class:"token punctuation"}},[t._v("(")]),a("span",{attrs:{class:"token single-quoted-string string"}},[t._v("'bootstrap'")]),a("span",{attrs:{class:"token punctuation"}},[t._v(")")]),a("span",{attrs:{class:"token punctuation"}},[t._v(")")]),t._v(" "),a("span",{attrs:{class:"token punctuation"}},[t._v("{")]),t._v("\n    "),a("span",{attrs:{class:"token comment"}},[t._v("// Do something")]),t._v("\n"),a("span",{attrs:{class:"token punctuation"}},[t._v("}")]),t._v("\n")])])])])},[],!1,null,null,null);r.options.__file="themes.md";e.default=r.exports}}]);