diff --git a/config.js b/config.js
index 9e4ef27..0d02f8f 100644
--- a/config.js
+++ b/config.js
@@ -4,9 +4,9 @@
module.exports = exports = {
github: {
- repo: "lbryio/lbry.tech",
- docsBranch: "master/content",
- editLinkText: "Edit this page on GitHub"
+ branch: "new",
+ linkText: "Edit this page on GitHub",
+ repo: "lbryio/lbry.tech"
},
ga: "UA-60403362-1"
};
diff --git a/views/partials/edit-link.js b/views/partials/edit-link.js
index f8b2a51..daf58e5 100644
--- a/views/partials/edit-link.js
+++ b/views/partials/edit-link.js
@@ -16,13 +16,24 @@ const config = local("/config");
// P R O G R A M
const editLink = pagePath => {
- let githubUrl = `https://github.com/${config.github.repo}/edit`;
+ let githubUrl = `https://github.com/${config.github.repo}/edit/${config.github.branch}`;
- if (pagePath === "/") githubUrl = `${githubUrl}/master/README.md`;
- else githubUrl = `${githubUrl}/${config.github.docsBranch}${pagePath}.md`; // TODO: Update this to match new site structure
+ switch(pagePath) {
+ case "":
+ githubUrl = `${githubUrl}/views/pages/home.js`;
+ break;
+
+ case "/resources":
+ githubUrl = `${githubUrl}/views/pages/resources.js`;
+ break;
+
+ default:
+ githubUrl = `${githubUrl}/documents${pagePath}.md`;
+ break;
+ }
return html`
- ${config.github.editLinkText}
+ ${config.github.linkText}
`;
};