From a1c2346c49675c7e7aa937acfc36af0c141fc33e Mon Sep 17 00:00:00 2001 From: Ammar Bandukwala Date: Tue, 2 Aug 2022 05:01:25 +0000 Subject: [PATCH] Fix docs links In the frontend, the docs website will usually be a better experience than the repo, even though there's a chance the version might be old. --- coder.service | 2 +- .../UserDropdownContent.test.tsx | 14 -------------- .../UserDropdownContent/UserDropdownContent.tsx | 2 +- 3 files changed, 2 insertions(+), 16 deletions(-) diff --git a/coder.service b/coder.service index 8c8f6a36428fb..697250bf8f993 100644 --- a/coder.service +++ b/coder.service @@ -1,6 +1,6 @@ [Unit] Description="Coder - Self-hosted developer workspaces on your infra" -Documentation=https://coder.com/docs/ +Documentation=https://coder.com/docs/coder-oss Requires=network-online.target After=network-online.target ConditionFileNotEmpty=/etc/coder.d/coder.env diff --git a/site/src/components/UserDropdownContent/UserDropdownContent.test.tsx b/site/src/components/UserDropdownContent/UserDropdownContent.test.tsx index 0a86647ff4fd8..48b123ebdd06c 100644 --- a/site/src/components/UserDropdownContent/UserDropdownContent.test.tsx +++ b/site/src/components/UserDropdownContent/UserDropdownContent.test.tsx @@ -29,20 +29,6 @@ describe("UserDropdownContent", () => { expect(screen.getByText(MockAdminRole.display_name)).toBeDefined() }) - it("has the correct link for the documentation item", () => { - process.env.CODER_VERSION = "v0.5.4" - render() - - const link = screen.getByText(Language.docsLabel).closest("a") - if (!link) { - throw new Error("Anchor tag not found for the documentation menu item") - } - - expect(link.getAttribute("href")).toBe( - `https://github.com/coder/coder/tree/${process.env.CODER_VERSION}/docs`, - ) - }) - it("has the correct link for the account item", () => { render() diff --git a/site/src/components/UserDropdownContent/UserDropdownContent.tsx b/site/src/components/UserDropdownContent/UserDropdownContent.tsx index 4d4a840c546b8..2d79b44c7771a 100644 --- a/site/src/components/UserDropdownContent/UserDropdownContent.tsx +++ b/site/src/components/UserDropdownContent/UserDropdownContent.tsx @@ -65,7 +65,7 @@ export const UserDropdownContent: FC = ({