Skip to content

Commit 1237b1e

Browse files
committed
working pattern subtype viewall
1 parent 12672e3 commit 1237b1e

File tree

1 file changed

+8
-7
lines changed

1 file changed

+8
-7
lines changed

core/lib/ui_builder.js

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -301,17 +301,18 @@ var ui_builder = function () {
301301

302302
function buildViewAllHTML(patternlab, patterns, patternPartial, isPatternType) {
303303

304-
console.log('building viewall HTML for ', patternPartial);
304+
console.log(20, 'building viewall HTML for', patternPartial);
305+
306+
//if (isPatternType) {
307+
// patternPartial = patternPartial.substring(patternPartial.indexOf('viewall-'));
308+
// console.log(21, patternPartial);
309+
//}
305310

306-
if (isPatternType) {
307-
patternPartial = patternPartial.substring(patternPartial.indexOf('viewall-'));
308-
console.log(patternPartial);
309-
}
310311

311312
var viewAllHTML = pattern_assembler.renderPattern(patternlab.viewAll,
312313
{
313314
partials: patterns,
314-
patternPartial: patternPartial,
315+
patternPartial: 'viewall-' + patternPartial,
315316
cacheBuster: patternlab.cacheBuster
316317
}, {
317318
patternSection: patternlab.patternSection,
@@ -340,7 +341,7 @@ var ui_builder = function () {
340341
console.log(3, patternPartial);
341342

342343
//render the footer needed for the viewall template
343-
var footerHTML = buildFooterHTML(patternlab, patternPartial);
344+
var footerHTML = buildFooterHTML(patternlab, 'viewall-' + patternPartial);
344345

345346
//render the viewall template
346347
var subtypePatterns = _.values(patternSubtypes);

0 commit comments

Comments
 (0)