{"id":349,"date":"2012-07-09T09:56:08","date_gmt":"2012-07-09T09:56:08","guid":{"rendered":"https:\/\/www.frozenlogistic.com\/?p=349"},"modified":"2012-08-12T18:03:55","modified_gmt":"2012-08-12T18:03:55","slug":"color-styles","status":"publish","type":"post","link":"https:\/\/www.frozenlogistic.com\/?p=349","title":{"rendered":"Color Styles"},"content":{"rendered":"<p>GavernWP has an extensive mechanism allowing to create additional theme styles. We may distinguish two main groups of styles in this mechanism:<\/p>\n<ul>\n<li>style family<\/li>\n<li>styles included in style family given<\/li>\n<\/ul>\n<p>The whole configuration is included in <strong>styles.json<\/strong> file:<\/p>\n<p>[code][{<\/p>\n<p>\u00abfamily\u00bb: \u00abcolor\u00bb,<br \/>\n\u00abfamily_desc\u00bb: \u00abTheme color\u00bb,<br \/>\n\u00abfamily_tooltip\u00bb: \u00abYou can select one of the theme colors\u00bb,<br \/>\n\u00abstyles\u00bb: [<br \/>\n{<br \/>\n\u00abname\u00bb: \u00abColor I\u00bb,<br \/>\n\u00abvalue\u00bb: \u00abcolor1\u00bb,<br \/>\n\u00abfile\u00bb: \u00abstyle1.css\u00bb<br \/>\n},<br \/>\n{<br \/>\n\u00abname\u00bb: \u00abColor II\u00bb,<br \/>\n\u00abvalue\u00bb: \u00abcolor2\u00bb,<br \/>\n\u00abfile\u00bb: \u00abstyle2.css\u00bb<br \/>\n}<br \/>\n]<br \/>\n}][\/code]<\/p>\n<p>As you can see, it includes <strong>color<\/strong> style family which has two styles, namely: <strong>Color I<\/strong> and <strong>Color II<\/strong>.<\/p>\n<p>In order to create new style family or a style for style family given, it is enough to create a next object in <strong>styles.json<\/strong> file and then create CSS files connected with a family given &#8211; in the case of <strong>color<\/strong> family, these are <strong>style1.css<\/strong> and <strong>style2.css<\/strong> files.<\/p>\n<p>GavernWP will load CSS files of a style given in a <strong>head<\/strong> section &#8211; chosen in an administration panel or, if there is a tool for choosing user&#8217;s styles switched on, they will be loaded based on a Cookie file storing data about a style used by a user.<\/p>\n<p>You have to remember that for each style family there is at least one CSS file loaded. Therefore, creating coexisting style families like:<\/p>\n<ul>\n<li><strong>dark styles<\/strong> and <strong>light styles<\/strong><\/li>\n<li><strong>blue styles<\/strong> and <strong>green styles<\/strong><\/li>\n<\/ul>\n<p>is incorrect because at least one CSS style from each family will be loaded immediately. So the correct one is creating style families responsible for some elements of website styling, e.g. a separate family responsible for website coloring (<strong>colors<\/strong>) and a separate one for website background (<strong>patterns<\/strong>).<\/p>\n<p>Generally, you have to care about particular style families in order not to overwrite one another.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>GavernWP has an extensive mechanism allowing to create additional theme styles. We may distinguish two main groups of styles in this mechanism: style family styles included in style family given &#8230;<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[18],"tags":[43,39,28],"class_list":["post-349","post","type-post","status-publish","format-standard","hentry","category-theme-features","tag-colors","tag-css","tag-json"],"_links":{"self":[{"href":"https:\/\/www.frozenlogistic.com\/index.php?rest_route=\/wp\/v2\/posts\/349","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.frozenlogistic.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.frozenlogistic.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.frozenlogistic.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.frozenlogistic.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=349"}],"version-history":[{"count":6,"href":"https:\/\/www.frozenlogistic.com\/index.php?rest_route=\/wp\/v2\/posts\/349\/revisions"}],"predecessor-version":[{"id":440,"href":"https:\/\/www.frozenlogistic.com\/index.php?rest_route=\/wp\/v2\/posts\/349\/revisions\/440"}],"wp:attachment":[{"href":"https:\/\/www.frozenlogistic.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=349"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.frozenlogistic.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=349"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.frozenlogistic.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=349"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}