From f808a64e5203fa5529d77911aff775cdf798d266 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tom=C3=A1=C5=A1=20Bon=C4=8Do?= Date: Fri, 13 Jan 2017 11:12:59 +0100 Subject: [PATCH] Fixed opening of default file. --- manifest.json | 2 +- src/inject/inject.js | 21 ++++++++++++--------- src/inject/inject.js.map | 2 +- src/inject/inject.ts | 4 +--- 4 files changed, 15 insertions(+), 14 deletions(-) diff --git a/manifest.json b/manifest.json index 4204a1c..c654747 100644 --- a/manifest.json +++ b/manifest.json @@ -2,7 +2,7 @@ "name": "GitLab - Tree view for code", "homepage_url": "https://github.com/tomasbonco/gitlabtree", "author": "Tomáš Bončo", - "version": "0.0.4", + "version": "0.0.4.1", "manifest_version": 2, "description": "Provides folder structure view for code in GitLab.", "icons": { diff --git a/src/inject/inject.js b/src/inject/inject.js index e2b0f03..58d38cb 100644 --- a/src/inject/inject.js +++ b/src/inject/inject.js @@ -20,7 +20,7 @@ var GitLabTree = (function () { return; } // Detection if we have any files to generate tree from - var files = document.querySelector('.files'); + var files = document.querySelector('.files'), as = HTMLElement; if (!files) { return; } @@ -75,8 +75,8 @@ var GitLabTree = (function () { GitLabTree.prototype.obtainMetadata = function () { var metadata = []; var rawFilesMetadata = Array.prototype.slice.call(document.querySelectorAll('.file-stats li')); - for (var _i = 0, rawFilesMetadata_1 = rawFilesMetadata; _i < rawFilesMetadata_1.length; _i++) { - var rawFileMetadata = rawFilesMetadata_1[_i]; + for (var _i = 0; _i < rawFilesMetadata.length; _i++) { + var rawFileMetadata = rawFilesMetadata[_i]; var typeRaw = Array.prototype.slice.call(rawFileMetadata.querySelector('span:first-child').classList); var hash = rawFileMetadata.querySelector('a').getAttribute('href'); var filename = rawFileMetadata.querySelector('a').textContent.trim(); @@ -119,7 +119,7 @@ var GitLabTree = (function () { */ GitLabTree.prototype.copyAndHideFiles = function (files) { for (var i = 0; i < this.fileHolders.length; i++) { - var fileHolder = this.fileHolders[i]; + var fileHolder = this.fileHolders[i], as = HTMLElement; files.removeChild(fileHolder); this.rightElement.appendChild(fileHolder); fileHolder.classList.add(CSS_PREFIX + '-hidden'); @@ -166,8 +166,8 @@ var GitLabTree = (function () { return fileNames.slice(0); } var output = []; - for (var _i = 0, fileNames_1 = fileNames; _i < fileNames_1.length; _i++) { - var fileName = fileNames_1[_i]; + for (var _i = 0; _i < fileNames.length; _i++) { + var fileName = fileNames[_i]; output.push(fileName.substring((prefix + '/').length)); } return output; @@ -231,7 +231,6 @@ var GitLabTree = (function () { file.setAttribute('href', metadata.hash); file.classList.add('file'); file.textContent = name_1; - console.log(metadata); var fileStateClass = void 0; switch (metadata.type) { case EFileState.ADDED: @@ -280,19 +279,23 @@ var GitLabTree = (function () { this.getFileHolderByHash(this.lastActive).classList.add(CSS_PREFIX + '-hidden'); this.getFileLinkByHash(this.lastActive).classList.remove(CSS_PREFIX + '-file-active'); } - hash = this.metadata.filter(function (m) { return m.hash === hash; }) ? hash : this.metadata[0].hash; // if hash is invalid use default hash + hash = this.metadata.filter(function (m) { return m.hash === hash; }).length > 0 ? hash : this.metadata[0].hash; // if hash is invalid use default hash this.getFileHolderByHash(hash).classList.remove(CSS_PREFIX + '-hidden'); this.getFileLinkByHash(hash).classList.add(CSS_PREFIX + '-file-active'); this.lastActive = hash; }; GitLabTree.prototype.getFileHolderByHash = function (hash) { return this.rightElement.querySelector("[id='" + hash.substr(1) + "']"); + as; + HTMLElement; }; GitLabTree.prototype.getFileLinkByHash = function (hash) { return this.leftElement.querySelector("[href='" + hash + "']"); + as; + HTMLElement; }; return GitLabTree; -}()); +})(); var instance = new GitLabTree(); /** * This is for fake AJAX re-renders of the page. diff --git a/src/inject/inject.js.map b/src/inject/inject.js.map index f7d90ac..0dc1133 100644 --- a/src/inject/inject.js.map +++ b/src/inject/inject.js.map @@ -1 +1 @@ -{"version":3,"file":"inject.js","sourceRoot":"","sources":["inject.ts"],"names":[],"mappings":"AAAA,IAAM,UAAU,GAAG,oBAAoB,CAAC;AAExC,IA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,GAAG,cAAc,CAAE,CAAC;QAE5E,IAAI,CAAC,UAAU,GAAG,IAAI,CAAC;IACxB,CAAC;IAED,wCAAmB,GAAnB,UAAqB,IAAY;QAEhC,MAAM,CAAC,IAAI,CAAC,YAAY,CAAC,aAAa,CAAE,UAAS,IAAI,CAAC,MAAM,CAAC,CAAC,CAAC,OAAK,CAAiB,CAAC;IACvF,CAAC;IAED,sCAAiB,GAAjB,UAAmB,IAAY;QAE9B,MAAM,CAAC,IAAI,CAAC,WAAW,CAAC,aAAa,CAAE,YAAW,IAAI,OAAK,CAAiB,CAAC;IAC9E,CAAC;IACF,iBAAC;AAAD,CAAC,AAnZD,IAmZC;AAID,IAAI,QAAQ,GAAe,IAAI,UAAU,EAAE,CAAC;AAE5C;;GAEG;AACH;IAEC,IAAI,KAAK,GAAY,QAAQ,CAAC,aAAa,CAAE,QAAQ,CAAE,CAAC;IAExD,EAAE,CAAC,CAAE,KAAK,IAAI,CAAE,KAAK,CAAC,SAAS,CAAC,QAAQ,CAAE,UAAU,CAAG,CAAC,CACxD,CAAC;QACA,QAAQ,CAAC,QAAQ,EAAE,CAAC;QACpB,QAAQ,GAAG,IAAI,UAAU,EAAE,CAAC;IAC7B,CAAC;AACF,CAAC;AAED,WAAW,CAAE,cAAM,OAAA,eAAe,EAAE,EAAjB,CAAiB,EAAE,IAAI,CAAE,CAAA"} \ No newline at end of file +{"version":3,"file":"inject.js","sourceRoot":"","sources":["inject.ts"],"names":["EFileState","GitLabTree","GitLabTree.constructor","GitLabTree.teardown","GitLabTree.init","GitLabTree.obtainMetadata","GitLabTree.getMetadata","GitLabTree.copyAndHideFiles","GitLabTree.getPrefixPath","GitLabTree.removePathPrefix","GitLabTree.createFolderStructure","GitLabTree.convertFolderStructureToDOM","GitLabTree.hashChanged","GitLabTree.showFile","GitLabTree.getFileHolderByHash","GitLabTree.getFileLinkByHash","checkSiteChange"],"mappings":"AAAA,IAAM,UAAU,GAAG,oBAAoB,CAAC;AAExC,IAAK,UAA+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AW,CAAE,cAAM,OAAA,eAAe,EAAE,EAAjB,CAAiB,EAAE,IAAI,CAAE,CAAA"} \ No newline at end of file diff --git a/src/inject/inject.ts b/src/inject/inject.ts index f4e5894..6b2ff58 100644 --- a/src/inject/inject.ts +++ b/src/inject/inject.ts @@ -336,8 +336,6 @@ class GitLabTree file.classList.add( 'file' ); file.textContent = name; - console.log( metadata ) - let fileStateClass; switch ( metadata.type ) { @@ -395,7 +393,7 @@ class GitLabTree } - hash = this.metadata.filter( m => m.hash === hash ) ? hash : this.metadata[0].hash; // if hash is invalid use default hash + hash = this.metadata.filter( m => m.hash === hash ).length > 0 ? hash : this.metadata[0].hash; // if hash is invalid use default hash this.getFileHolderByHash( hash ).classList.remove( CSS_PREFIX + '-hidden' ); this.getFileLinkByHash( hash ).classList.add( CSS_PREFIX + '-file-active' );