Blame
History
diff --git a/app/assets/javascripts/repo/repo_store.js b/app/assets/javascripts/repo/repo_store.js
index 1bd3f1b0b39..612b7b61158 100644
--- a/app/assets/javascripts/repo/repo_store.js
+++ b/app/assets/javascripts/repo/repo_store.js
@@ -55,7 +55,7 @@ const RepoStore = {
toggleRawPreview() {
this.activeFile.raw = !this.activeFile.raw;
- this.activeFileLabel = this.activeFile.raw ? 'Preview' : 'Raw';
+ this.activeFileLabel = this.activeFile.raw ? 'Display rendered file' : 'Display source';
},
setActiveFiles(file) {
@@ -92,7 +92,7 @@ const RepoStore = {
setActiveToRaw() {
this.activeFile.raw = false;
// can't get vue to listen to raw for some reason so this for now.
- this.activeFileLabel = 'Raw';
+ this.activeFileLabel = 'Display source';
},
/* eslint-disable no-param-reassign */
diff --git a/app/assets/javascripts/repo/repo_tab.js b/app/assets/javascripts/repo/repo_tab.js
index ace17b22ab2..40a81c63ef7 100644
--- a/app/assets/javascripts/repo/repo_tab.js
+++ b/app/assets/javascripts/repo/repo_tab.js
@@ -1,3 +1,4 @@
+import RepoHelper from './repo_helper';
import RepoStore from './repo_store';
const RepoTab = {
@@ -27,7 +28,7 @@ const RepoTab = {
},
methods: {
- tabClicked: RepoStore.setActiveFiles,
+ tabClicked: RepoStore.setActiveFiles.bind(RepoStore),
xClicked(file) {
if (file.changed) return;