@@ -50,6 +50,7 @@ class Builder {
50
50
protected $ mainPageFoot ; // the footer to be included on main pages
51
51
protected $ addPatternHF ; // should the pattern header and footer be added
52
52
protected $ cleanPublic ; // whether the public directory should be cleaned out or not on generate
53
+ protected $ styleGuideExcludes ;// which pattern types to exclude from the style guide
53
54
54
55
/**
55
56
* When initializing the Builder class or the sub-classes make sure the base properties are configured
@@ -67,7 +68,8 @@ public function __construct($config = array()) {
67
68
foreach ($ config as $ key => $ value ) {
68
69
69
70
// if the variables are array-like make sure the properties are validated/trimmed/lowercased before saving
70
- if (($ key == "ie " ) || ($ key == "id " ) || ($ key == "patternStates " )) {
71
+ $ arrayKeys = array ("ie " ,"id " ,"patternStates " ,"styleGuideExcludes " );
72
+ if (in_array ($ key ,$ arrayKeys )) {
71
73
$ values = explode (", " ,$ value );
72
74
array_walk ($ values ,'PatternLab\Builder::trim ' );
73
75
$ this ->$ key = $ values ;
@@ -886,7 +888,7 @@ protected function gatherPatternInfo() {
886
888
$ patternTypeDash = $ patternTypeValues ["patternTypeDash " ];
887
889
888
890
// if this has a second level of patterns check them out (means we don't process pages & templates)
889
- if (isset ($ patternTypeValues ["patternTypeItems " ])) {
891
+ if (isset ($ patternTypeValues ["patternTypeItems " ]) && (! in_array ( $ patternType , $ this -> styleGuideExcludes )) ) {
890
892
891
893
$ arrayReset = false ;
892
894
0 commit comments