Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
赵月辉
/
fastgpt-migrated
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Members
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Unverified
Commit
add73aa2
authored
Oct 12, 2023
by
Carson Yang
Committed by
GitHub
Oct 12, 2023
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Docs: use docsearch (#391)
Signed-off-by: Carson Yang <yangchuansheng33@gmail.com>
parent
bcf94919
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
54 additions
and
5 deletions
+54
-5
docSite/hugo.toml
+5
-5
docSite/i18n/zh-cn.toml
+9
-0
docSite/layouts/partials/docs/footer/docsearch.html
+40
-0
No files found.
docSite/hugo.toml
View file @
add73aa2
...
@@ -110,8 +110,8 @@ defaultContentLanguage = 'zh-cn'
...
@@ -110,8 +110,8 @@ defaultContentLanguage = 'zh-cn'
listDescTrunc
=
100
# Number of characters by which to truncate the list card description
listDescTrunc
=
100
# Number of characters by which to truncate the list card description
[params.flexsearch]
# Parameters for FlexSearch
[params.flexsearch]
# Parameters for FlexSearch
enabled
=
true
#
enabled = true
tokenize
=
"full"
#
tokenize = "full"
# optimize = true
# optimize = true
# cache = 100
# cache = 100
# minQueryChar = 3 # default is 0 (disabled)
# minQueryChar = 3 # default is 0 (disabled)
...
@@ -119,9 +119,9 @@ defaultContentLanguage = 'zh-cn'
...
@@ -119,9 +119,9 @@ defaultContentLanguage = 'zh-cn'
# searchSectionsIndex = []
# searchSectionsIndex = []
[params.docsearch]
# Parameters for DocSearch
[params.docsearch]
# Parameters for DocSearch
# appID = "O2QIOCBDAK
" # Algolia Application ID
appID
=
"5BEWEMH0YA
"
# Algolia Application ID
# apiKey = "fdc60eee76a72a35d739b54521498b77
" # Algolia Search-Only API (Public) Key
apiKey
=
"14834e919a87217d919d6d881fcacac3
"
# Algolia Search-Only API (Public) Key
# indexName = "prod_lotusdocs.dev
" # Index Name to perform search on (or set env variable HUGO_PARAM_DOCSEARCH_indexName)
indexName
=
"fastgpt
"
# Index Name to perform search on (or set env variable HUGO_PARAM_DOCSEARCH_indexName)
[params.analytics]
# Parameters for Analytics (Google, Plausible)
[params.analytics]
# Parameters for Analytics (Google, Plausible)
# plausibleURL = "/docs/s" # (or set via env variable HUGO_PARAM_ANALYTICS_plausibleURL)
# plausibleURL = "/docs/s" # (or set via env variable HUGO_PARAM_ANALYTICS_plausibleURL)
...
...
docSite/i18n/zh-cn.toml
View file @
add73aa2
...
@@ -19,6 +19,15 @@
...
@@ -19,6 +19,15 @@
[search_no_results]
[search_no_results]
other
=
"没有结果:"
other
=
"没有结果:"
[search_no_recent_searches]
other
=
"没有最近搜索"
[search_try_search]
other
=
"试试搜索"
[search_search_by]
other
=
"搜索提供"
[feedback_yes]
[feedback_yes]
other
=
"Yes"
other
=
"Yes"
...
...
docSite/layouts/partials/docs/footer/docsearch.html
0 → 100644
View file @
add73aa2
<script>
window
.
addEventListener
(
'DOMContentLoaded'
,
function
()
{
// DocSearch Config
docsearch
({
container
:
'#docsearch'
,
appId
:
'{{ .Site.Params.docsearch.appID }}'
,
apiKey
:
'{{ .Site.Params.docsearch.apiKey }}'
,
indexName
:
'{{ .Site.Params.docsearch.indexName }}'
,
placeholder
:
'{{ i18n "search_title" }}'
,
translations
:
{
button
:
{
buttonText
:
'{{ i18n "search_title" }}'
,
buttonAriaLabel
:
'{{ i18n "search_title" }}'
,
},
modal
:
{
startScreen
:
{
noRecentSearchesText
:
'{{ i18n "search_no_recent_searches" }}'
,
},
footer
:
{
selectText
:
'{{ i18n "search_select" }}'
,
selectKeyAriaLabel
:
'Enter key'
,
navigateText
:
'{{ i18n "search_navigate" }}'
,
navigateUpKeyAriaLabel
:
'Arrow up'
,
navigateDownKeyAriaLabel
:
'Arrow down'
,
closeText
:
'{{ i18n "search_close" }}'
,
closeKeyAriaLabel
:
'Escape key'
,
searchByText
:
'{{ i18n "search_search_by" }}'
,
},
noResultsScreen
:
{
noResultsText
:
'{{ i18n "search_no_results" }}'
,
suggestedQueryText
:
'{{ i18n "search_try_search" }}'
,
reportMissingResultsText
:
'Believe this query should return results?'
,
reportMissingResultsLinkText
:
'Let us know.'
,
},
},
}
});
});
</script>
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment