From 34582f9f65a0a1c778762d05bb5a4ddf97494982 Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Wed, 8 Feb 2017 20:21:18 -0800 Subject: [PATCH] Remove logs --- src/Linkifier.ts | 8 -------- 1 file changed, 8 deletions(-) diff --git a/src/Linkifier.ts b/src/Linkifier.ts index d97f4d14..07573421 100644 --- a/src/Linkifier.ts +++ b/src/Linkifier.ts @@ -74,24 +74,19 @@ export class Linkifier { return; } - console.log('found uri: ' + uri); const linkElement = this._createAnchorElement(uri); // TODO: Check if childNodes check is needed if (node.textContent.trim().length === uri.length) { // Matches entire string - console.log('match entire string'); if (node.nodeType === Node.TEXT_NODE) { - console.log('text node'); this._replaceNode(node, linkElement); } else { - console.log('element'); const element = (node); element.innerHTML = ''; element.appendChild(linkElement); } } else { // Matches part of string - console.log('part of string'); this._replaceNodeSubstringWithNode(node, linkElement, uri, searchIndex); } } @@ -167,19 +162,16 @@ export class Linkifier { if (substringIndex === 0) { // Replace with - console.log('Replace with '); const rightText = fullText.substring(substring.length); const rightTextNode = document.createTextNode(rightText); this._replaceNode(node, newNode, rightTextNode); } else if (substringIndex === targetNode.textContent.length - substring.length) { // Replace with - console.log('Replace with '); const leftText = fullText.substring(0, substringIndex); const leftTextNode = document.createTextNode(leftText); this._replaceNode(node, leftTextNode, newNode); } else { // Replace with - console.log('Replace with '); const leftText = fullText.substring(0, substringIndex); const leftTextNode = document.createTextNode(leftText); const rightText = fullText.substring(substringIndex + substring.length);