Skip to content

Commit

Permalink
update docsy (#86)
Browse files Browse the repository at this point in the history
  • Loading branch information
fatedier committed Aug 29, 2024
1 parent b94256e commit 30ad042
Show file tree
Hide file tree
Showing 9 changed files with 29 additions and 27 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,4 +11,4 @@ hugo server

Notice that non-extended hugo can't build that doc, see [execute-as-template-of-sass-files-not-working](https://discourse.gohugo.io/t/execute-as-template-of-sass-files-not-working/17627/2).

If you have any build problems, please check your [hugo](https://github.com/gohugoio/hugo/releases) version, we are using [hugo_extended_0.119.0_Linux-64bit](https://github.com/gohugoio/hugo/releases/download/v0.119.0/hugo_extended_0.119.0_Linux-64bit.tar.gz).
If you have any build problems, please check your [hugo](https://github.com/gohugoio/hugo/releases) version, we are using [hugo_extended_0.133.1_Linux-64bit](https://github.com/gohugoio/hugo/releases/download/v0.133.1/hugo_extended_0.133.1_Linux-64bit.tar.gz).
1 change: 1 addition & 0 deletions assets/scss/_styles_project.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
@import 'td/code-dark'
3 changes: 3 additions & 0 deletions assets/scss/_variables_project_after_bs.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
a {
text-decoration: none;
}
14 changes: 6 additions & 8 deletions config.toml
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,7 @@ params.description = "frp official website"
[markup.highlight]
# See a complete list of available styles at https://xyproto.github.io/splash/docs/all.html
style = "tango"
noClasses = false
# Uncomment if you want your chosen highlight style used for code blocks without a specified language
# guessSyntax = "true"

Expand Down Expand Up @@ -139,10 +140,6 @@ github_branch= "master"
# Google Custom Search Engine ID. Remove or comment out to disable search.
# gcs_engine_id = "011737558837375720776:fsdu1nryfng"

# Enable Algolia DocSearch
[params.search]
algolia = false

# Enable Lunr.js offline search
offlineSearch = true

Expand All @@ -153,8 +150,8 @@ prism_syntax_highlighting = false
[params.ui]
# Set to true to disable breadcrumb navigation.
breadcrumb_disable = false
# Set to true to disable the About link in the site footer
footer_about_disable = false
# Set to true to enable the About link in the site footer
footer_about_enable = true
# Set to false if you don't want to display a logo (/assets/icons/logo.svg) in the top nav bar
navbar_logo = true
# Set to true if you don't want the top navbar to be translucent when over a `block/cover`, like on the homepage.
Expand All @@ -170,13 +167,14 @@ sidebar_menu_foldable = true
sidebar_cache_limit = 2000
# Set a desired menu depth to always be visible
ul_show = 1
showLightDarkModeMenu = true

# Adds a H2 section titled "Feedback" to the bottom of each doc. The responses are sent to Google Analytics as events.
# This feature depends on [services.googleAnalytics] and will be disabled if "services.googleAnalytics.id" is not set.
# If you want this feature, but occasionally need to remove the "Feedback" section from a single page,
# add "hide_feedback: true" to the page's front matter.
[params.ui.feedback]
enable = true
enable = false
# The responses that the user sees after clicking "yes" (the page was helpful) or "no" (the page was not helpful).
yes = 'Glad to hear it! Please <a href="https://github.com/gofrp/frp-doc/issues/new">tell us how we can improve</a>.'
no = 'Sorry to hear that. Please <a href="https://github.com/gofrp/frp-doc/issues/new">tell us how we can improve</a>.'
Expand Down Expand Up @@ -212,7 +210,7 @@ enable = false
[module.hugoVersion]
extended = true
min = "0.119.0"
max = "0.119.0"
max = "0.133.1"
[[module.imports]]
path = "github.com/google/docsy"
[[module.imports]]
Expand Down
5 changes: 4 additions & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,7 @@ module github.com/gofrp/frp-doc

go 1.20

require github.com/google/docsy v0.7.1 // indirect
require (
github.com/google/docsy v0.10.0 // indirect
github.com/google/docsy/dependencies v0.7.2 // indirect
)
14 changes: 6 additions & 8 deletions go.sum
Original file line number Diff line number Diff line change
@@ -1,10 +1,8 @@
github.com/FortAwesome/Font-Awesome v0.0.0-20220831210243-d3a7818c253f/go.mod h1:IUgezN/MFpCDIlFezw3L8j83oeiIuYoj28Miwr/KUYo=
github.com/FortAwesome/Font-Awesome v0.0.0-20230327165841-0698449d50f2/go.mod h1:IUgezN/MFpCDIlFezw3L8j83oeiIuYoj28Miwr/KUYo=
github.com/google/docsy v0.6.0 h1:43bVF18t2JihAamelQjjGzx1vO2ljCilVrBgetCA8oI=
github.com/google/docsy v0.6.0/go.mod h1:VKKLqD8PQ7AglJc98yBorATfW7GrNVsn0kGXVYF6G+M=
github.com/google/docsy v0.7.1 h1:DUriA7Nr3lJjNi9Ulev1SfiG1sUYmvyDeU4nTp7uDxY=
github.com/google/docsy v0.7.1/go.mod h1:JCmE+c+izhE0Rvzv3y+AzHhz1KdwlA9Oj5YBMklJcfc=
github.com/google/docsy/dependencies v0.6.0/go.mod h1:EDGc2znMbGUw0RW5kWwy2oGgLt0iVXBmoq4UOqstuNE=
github.com/google/docsy/dependencies v0.7.1/go.mod h1:gihhs5gmgeO+wuoay4FwOzob+jYJVyQbNaQOh788lD4=
github.com/twbs/bootstrap v4.6.2+incompatible/go.mod h1:fZTSrkpSf0/HkL0IIJzvVspTt1r9zuf7XlZau8kpcY0=
github.com/FortAwesome/Font-Awesome v0.0.0-20240402185447-c0f460dca7f7/go.mod h1:IUgezN/MFpCDIlFezw3L8j83oeiIuYoj28Miwr/KUYo=
github.com/google/docsy v0.10.0 h1:6tMDacPwAyRWNCfvsn/9qGOZDQ8b0aRzjRZvnZPY5dg=
github.com/google/docsy v0.10.0/go.mod h1:c0nIAqmRTOuJ01F85U/wJPQtc3Zj9N58Kea9bOT2AJc=
github.com/google/docsy/dependencies v0.7.2 h1:+t5ufoADQAj4XneFphz4A+UU0ICAxmNaRHVWtMYXPSI=
github.com/google/docsy/dependencies v0.7.2/go.mod h1:gihhs5gmgeO+wuoay4FwOzob+jYJVyQbNaQOh788lD4=
github.com/twbs/bootstrap v5.2.3+incompatible/go.mod h1:fZTSrkpSf0/HkL0IIJzvVspTt1r9zuf7XlZau8kpcY0=
github.com/twbs/bootstrap v5.3.3+incompatible/go.mod h1:fZTSrkpSf0/HkL0IIJzvVspTt1r9zuf7XlZau8kpcY0=
13 changes: 6 additions & 7 deletions layouts/partials/head.html
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
{{ hugo.Generator }}
{{ range .AlternativeOutputFormats -}}
<link rel="{{ .Rel }}" type="{{ .MediaType.Type }}" href="{{ .Permalink | safeURL }}">
{{ end -}}
Expand All @@ -27,8 +26,8 @@
{{ template "_internal/twitter_cards.html" . -}}
{{ partialCached "head-css.html" . "asdf" -}}
<script
src="/js/jquery-3.6.3.min.js"
integrity="sha384-Ft/vb48LwsAEtgltj7o+6vtS2esTU9PCpDqcXs4OCVQFZu5BqprHtUCZ4kjK+bpE"
src="/js/jquery-3.7.1.min.js"
integrity="sha512-v2CJ7UaYy4JwqLDIrZUI/4hqeoQieOmAZNXBeQyjo21dadnwR+8ZaIJVT8EE2iyI61OV8e6M8PP2/4hpQINQ/g=="
crossorigin="anonymous"></script>
{{ if .Site.Params.offlineSearch -}}
<script
Expand Down Expand Up @@ -59,18 +58,18 @@
{{/* To comply with GDPR, cookie consent scripts places in head-end must execute before Google Analytics is enabled */ -}}
{{ if hugo.IsProduction -}}
{{ $enableGtagForUniversalAnalytics := not .Site.Params.disableGtagForUniversalAnalytics -}}
{{ if (or $enableGtagForUniversalAnalytics (hasPrefix .Site.GoogleAnalytics "G-")) -}}
{{ if (or $enableGtagForUniversalAnalytics (hasPrefix .Site.Config.Services.GoogleAnalytics.ID "G-")) -}}
{{ template "_internal/google_analytics_gtag.html" . -}}
{{ else -}}
{{ template "_internal/google_analytics_async.html" . -}}
{{ template "_internal/google_analytics.html" . -}}
{{ end -}}
{{ end -}}

{{ define "algolia/head" -}}

{{ if and .Site.Params.search (isset .Site.Params.search "algolia") -}}
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/@docsearch/css@3"
integrity="sha512-O6ywtjtiV4QGgC6cD75C2Tf04SlTn9vvka8oV/dYpDL1JWM4lVP0QoZbdZt5RLtOWDpaP+MObzUrwl43ssqfvg=="
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/@docsearch/css@3.6.0"
integrity="sha512-AyDFDkYyALC5qoao077IqAOV7UC4oKCBTp+mJfjIt306AIRoBxoEZYDo0kAx/R7RbT+3EYEky1po/F1w1eQt7g=="
crossorigin="anonymous" />
{{ end -}}

Expand Down
2 changes: 0 additions & 2 deletions static/js/jquery-3.6.3.min.js

This file was deleted.

2 changes: 2 additions & 0 deletions static/js/jquery-3.7.1.min.js

Large diffs are not rendered by default.

0 comments on commit 30ad042

Please sign in to comment.