add contentEditUrl config url
All checks were successful
Deploy / deploy (ubuntu-latest, 2.44.0) (push) Successful in 1m54s
All checks were successful
Deploy / deploy (ubuntu-latest, 2.44.0) (push) Successful in 1m54s
Took 10 minutes
This commit is contained in:
parent
6a2c23229e
commit
adf898e3ef
@ -23,6 +23,7 @@
|
|||||||
"themeColor": "#A855F7"
|
"themeColor": "#A855F7"
|
||||||
},
|
},
|
||||||
"contentSource": "{process}/docs",
|
"contentSource": "{process}/docs",
|
||||||
|
"contentEditUrl": "https://git.rainnny.club/PulseApp/docs-content/src/branch/master/{slug}{ext}",
|
||||||
"socialLinks": [
|
"socialLinks": [
|
||||||
{
|
{
|
||||||
"name": "GitHub",
|
"name": "GitHub",
|
||||||
|
@ -23,6 +23,11 @@ export type Config = {
|
|||||||
*/
|
*/
|
||||||
contentSource: string;
|
contentSource: string;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The URL to link to for editing content of a page.
|
||||||
|
*/
|
||||||
|
contentEditUrl: string;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Social links for this app.
|
* Social links for this app.
|
||||||
*/
|
*/
|
||||||
|
@ -8,6 +8,7 @@ import { motion, useInView } from "framer-motion";
|
|||||||
import { Separator } from "@/components/ui/separator";
|
import { Separator } from "@/components/ui/separator";
|
||||||
import { Button } from "@/components/ui/button";
|
import { Button } from "@/components/ui/button";
|
||||||
import { AlignLeftIcon, ArrowUpFromDot, MoveRight } from "lucide-react";
|
import { AlignLeftIcon, ArrowUpFromDot, MoveRight } from "lucide-react";
|
||||||
|
import config from "@/config";
|
||||||
|
|
||||||
type Header = {
|
type Header = {
|
||||||
id: string;
|
id: string;
|
||||||
@ -148,7 +149,9 @@ const Footer = ({ page }: { page: DocsContentMetadata }): ReactElement => {
|
|||||||
{/* Edit on Git */}
|
{/* Edit on Git */}
|
||||||
<Link
|
<Link
|
||||||
className="flex gap-1.5 items-center text-xs hover:opacity-75 transition-all transform-gpu group"
|
className="flex gap-1.5 items-center text-xs hover:opacity-75 transition-all transform-gpu group"
|
||||||
href={`https://git.rainnny.club/PulseApp/docs/src/branch/master/docs/${page.slug}${page.extension}`}
|
href={config.contentEditUrl
|
||||||
|
.replace("{slug}", page.slug as string)
|
||||||
|
.replace("{ext}", page.extension as string)}
|
||||||
target="_blank"
|
target="_blank"
|
||||||
draggable={false}
|
draggable={false}
|
||||||
>
|
>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user