From 04343eda8c2f870b0da55cfdc8003c99fe1cc4de Mon Sep 17 00:00:00 2001 From: Kris Kowal Date: Fri, 6 Jul 2012 11:53:10 -0700 Subject: Remove trailing spaces --- js/document/mediators/template.js | 180 +++++++++++++++++++------------------- 1 file changed, 90 insertions(+), 90 deletions(-) (limited to 'js/document/mediators/template.js') diff --git a/js/document/mediators/template.js b/js/document/mediators/template.js index 6ab58e32..7451ffa2 100755 --- a/js/document/mediators/template.js +++ b/js/document/mediators/template.js @@ -35,7 +35,7 @@ var Montage = require("montage/core/core").Montage, TemplateCreator = require("node_modules/tools/template/template-creator").TemplateCreator, ClassUuid = require("js/components/core/class-uuid").ClassUuid; //////////////////////////////////////////////////////////////////////// -// +// exports.TemplateDocumentMediator = Montage.create(Component, { //////////////////////////////////////////////////////////////////// // @@ -167,7 +167,7 @@ exports.TemplateDocumentMediator = Montage.create(Component, { for (var n in template.body.attributes) { if (template.body.attributes[n].value) { template.file.content.document.body.setAttribute(template.body.attributes[n].name, template.body.attributes[n].value); - } + } } // if(template.template) { @@ -233,7 +233,7 @@ exports.TemplateDocumentMediator = Montage.create(Component, { for (var n in presentNodes) { // if (presentNodes[n].getAttribute && presentNodes[n].getAttribute('data-ninja-node') === null) { - toremovetags.push(presentNodes[n]); + toremovetags.push(presentNodes[n]); } else if (presentNodes[n].getAttribute && presentNodes[n].getAttribute('data-ninja-node') !== null) { //Removing attribute presentNodes[n].removeAttribute('data-ninja-node'); @@ -243,7 +243,7 @@ exports.TemplateDocumentMediator = Montage.create(Component, { var styletags = template.file.content.document.getElementsByTagName('style'), linktags = template.file.content.document.getElementsByTagName('link'), njtemplatetags = template.file.content.document.querySelectorAll('[data-ninja-template]'); - + //Adding to tags to be removed form template for (var f in njtemplatetags) { if (njtemplatetags[f].getAttribute) toremovetags.push(njtemplatetags[f]); @@ -266,7 +266,7 @@ exports.TemplateDocumentMediator = Montage.create(Component, { //Checking head first template.file.content.document.head.removeChild(toremovetags[h]); } catch (e) { - + } try { //Checking body if not in head @@ -287,23 +287,23 @@ exports.TemplateDocumentMediator = Montage.create(Component, { } } } - - - - - - - - - - - - - + + + + + + + + + + + + + //TODO: Make proper CSS method - - - + + + //Checking for type of save: styles =