docs: change report issue link (#10160)
This commit is contained in:
@@ -9,7 +9,6 @@ export type MainNavContext = {
|
||||
navItems: NavigationItem[]
|
||||
activeItemIndex?: number
|
||||
activeItem?: NavigationItem
|
||||
reportIssueLink: string
|
||||
editDate?: string
|
||||
}
|
||||
|
||||
@@ -17,14 +16,12 @@ const MainNavContext = createContext<MainNavContext | null>(null)
|
||||
|
||||
export type MainNavProviderProps = {
|
||||
navItems: NavigationItem[]
|
||||
reportIssueLink: string
|
||||
editDate?: string
|
||||
children?: React.ReactNode
|
||||
}
|
||||
|
||||
export const MainNavProvider = ({
|
||||
navItems,
|
||||
reportIssueLink,
|
||||
children,
|
||||
editDate,
|
||||
}: MainNavProviderProps) => {
|
||||
@@ -90,7 +87,6 @@ export const MainNavProvider = ({
|
||||
value={{
|
||||
navItems,
|
||||
activeItemIndex,
|
||||
reportIssueLink,
|
||||
editDate,
|
||||
activeItem,
|
||||
}}
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
import React, { createContext, useContext, useState } from "react"
|
||||
import { DocsConfig } from "types"
|
||||
import { globalConfig } from "../../global-config"
|
||||
import { GITHUB_ISSUES_LINK } from "../.."
|
||||
|
||||
export type SiteConfigContextType = {
|
||||
config: DocsConfig
|
||||
@@ -21,21 +22,25 @@ export const SiteConfigProvider = ({
|
||||
children,
|
||||
}: SiteConfigProviderProps) => {
|
||||
const [config, setConfig] = useState<DocsConfig>(
|
||||
initConfig || {
|
||||
baseUrl: "",
|
||||
sidebar: {
|
||||
default: [],
|
||||
mobile: [],
|
||||
Object.assign(
|
||||
{
|
||||
baseUrl: "",
|
||||
sidebar: {
|
||||
default: [],
|
||||
mobile: [],
|
||||
},
|
||||
project: {
|
||||
title: "",
|
||||
key: "",
|
||||
},
|
||||
breadcrumbOptions: {
|
||||
showCategories: true,
|
||||
},
|
||||
reportIssueLink: GITHUB_ISSUES_LINK,
|
||||
},
|
||||
project: {
|
||||
title: "",
|
||||
key: "",
|
||||
},
|
||||
breadcrumbOptions: {
|
||||
showCategories: true,
|
||||
},
|
||||
...globalConfig,
|
||||
}
|
||||
globalConfig,
|
||||
initConfig || {}
|
||||
)
|
||||
)
|
||||
|
||||
return (
|
||||
|
||||
Reference in New Issue
Block a user