diff --git a/src/app/docs/[...slug]/PrevNextEditButtons.tsx b/src/app/docs/[...slug]/PrevNextEditButtons.tsx
index fb3eb0007..317c0d1d0 100644
--- a/src/app/docs/[...slug]/PrevNextEditButtons.tsx
+++ b/src/app/docs/[...slug]/PrevNextEditButtons.tsx
@@ -1,8 +1,27 @@
import { Group, Box, Button, Text, Stack } from "@mantine/core";
import Link from "next/link";
-import { IconArrowRight, IconArrowLeft, IconPencil } from "@tabler/icons-react";
+import {
+ IconArrowRight,
+ IconArrowLeft,
+ IconPencil,
+ IconBug,
+} from "@tabler/icons-react";
import { DocMetadata } from "@/docs-collection-types";
+function buildIssueUrl(currentPage: DocMetadata): string {
+ const repoBase =
+ currentPage.type === "local-doc"
+ ? "https://github.com/prometheus/docs"
+ : `https://github.com/${currentPage.owner}/${currentPage.repo}`;
+
+ const title = encodeURIComponent(`docs: Issue with "${currentPage.title}"`);
+ const body = encodeURIComponent(
+ `**Page:** https://prometheus.io/docs/${currentPage.slug}/\n\n**Describe the issue:**\n\n`
+ );
+
+ return `${repoBase}/issues/new?title=${title}&body=${body}`;
+}
+
export default function PrevNextEditButtons({
currentPage,
}: {
@@ -47,35 +66,53 @@ export default function PrevNextEditButtons({
)}
- }
- fw="normal"
- visibleFrom="xs"
- >
-
- Edit
-
-
- Edit this page
-
-
+
+ }
+ fw="normal"
+ visibleFrom="xs"
+ >
+
+ Edit
+
+
+ Edit this page
+
+
+ }
+ fw="normal"
+ visibleFrom="xs"
+ >
+
+ Issue
+
+
+ Report an issue
+
+
+
{currentPage.next && (