diff options
author | Bjørn Erik Pedersen <bjorn.erik.pedersen@gmail.com> | 2022-04-28 19:40:50 +0300 |
---|---|---|
committer | Bjørn Erik Pedersen <bjorn.erik.pedersen@gmail.com> | 2022-04-29 19:37:52 +0300 |
commit | 21420e463d8226be376f58457fe95cd38c9a4c4b (patch) | |
tree | 381c132174d7f469c134055e35c7030c776dcc6b | |
parent | 953fffb5d0f50b10a13b21ba03799bf27b05856c (diff) |
Styling etc.
28 files changed, 99 insertions, 83 deletions
diff --git a/assets/css/sections/documentation.css b/assets/css/sections/documentation.css index ab8c701..51cb6bd 100644 --- a/assets/css/sections/documentation.css +++ b/assets/css/sections/documentation.css @@ -10,4 +10,9 @@ @apply text-blue-700 hover:text-steel-500 no-underline; } +#TableOfContents ul ul { + @apply ml-0 pl-3; + +} + diff --git a/exampleSite/config/_default/markup.toml b/exampleSite/config/_default/markup.toml index ce50aee..5eb62d2 100644 --- a/exampleSite/config/_default/markup.toml +++ b/exampleSite/config/_default/markup.toml @@ -27,6 +27,6 @@ lineNumbersInTable = true noClasses = false [tableOfContents] -endLevel = 2 +endLevel = 3 ordered = false startLevel = 2 diff --git a/exampleSite/content/en/documentation/reference/functions/tpl/collections/collections/index.md b/exampleSite/content/en/documentation/reference/functions/tpl/collections/collections/index.md index 030e1e0..a0a43f4 100644 --- a/exampleSite/content/en/documentation/reference/functions/tpl/collections/collections/index.md +++ b/exampleSite/content/en/documentation/reference/functions/tpl/collections/collections/index.md @@ -30,7 +30,7 @@ hugoSymbol: TODO ## collections.After {#collections_namespace_after} -\([any](/documentation/reference/gotypes/#any)[any](/documentation/reference/gotypes/#any)\) → [any](/documentation/reference/gotypes/#any) +\([any](/documentation/reference/gotypes/#any),[any](/documentation/reference/gotypes/#any)\) → [any](/documentation/reference/gotypes/#any) {.funcsig} After returns all the items after the first N in a rangeable list. @@ -46,7 +46,7 @@ After returns all the items after the first N in a rangeable list. ## collections.Append {#collections_namespace_append} -\([](/documentation/reference/objects//)\) → [any](/documentation/reference/gotypes/#any) +\([...any](/documentation/reference/objects//...any)\) → [any](/documentation/reference/gotypes/#any) {.funcsig} Append appends the arguments up to the last one to the slice in the last argument. This construct allows template constructs like this: @@ -78,7 +78,7 @@ the first slice will be appended to the second: ## collections.Apply {#collections_namespace_apply} -\([any](/documentation/reference/gotypes/#any)[string](/documentation/reference/gotypes/#string)[](/documentation/reference/objects//)\) → [any](/documentation/reference/gotypes/#any) +\(,[any](/documentation/reference/gotypes/#any),[string](/documentation/reference/gotypes/#string),[...any](/documentation/reference/objects//...any)\) → [any](/documentation/reference/gotypes/#any) {.funcsig} Apply takes a map, array, or slice and returns a new slice with the function fname applied over it. @@ -94,7 +94,7 @@ Apply takes a map, array, or slice and returns a new slice with the function fna ## collections.Complement {#collections_namespace_complement} -\([](/documentation/reference/objects//)\) → [any](/documentation/reference/gotypes/#any) +\([...any](/documentation/reference/objects//...any)\) → [any](/documentation/reference/gotypes/#any) {.funcsig} Complement gives the elements in the last element of seqs that are not in any of the others. @@ -120,7 +120,7 @@ The reasoning behind this rather clumsy API is so we can do this in the template ## collections.Delimit {#collections_namespace_delimit} -\([any](/documentation/reference/gotypes/#any)[](/documentation/reference/objects//)\) → [HTML](/documentation/reference/objects/html/template/html) +\([any](/documentation/reference/gotypes/#any),[...any](/documentation/reference/objects//...any)\) → [HTML](/documentation/reference/objects/html/template/html) {.funcsig} Delimit takes a given sequence and returns a delimited HTML string. If last is passed to the function, it will be used as the final delimiter. @@ -137,7 +137,7 @@ If last is passed to the function, it will be used as the final delimiter. ## collections.Dictionary {#collections_namespace_dictionary} -\([](/documentation/reference/objects//)\) → [](/documentation/reference/objects//) +\([...any](/documentation/reference/objects//...any)\) → [map[string]any](/documentation/reference/objects//map[string]any) {.funcsig} Dictionary creates a map[string]interface{} from the given parameters by walking the parameters and treating them as key-value pairs. The number @@ -173,7 +173,7 @@ empty string. ## collections.First {#collections_namespace_first} -\([any](/documentation/reference/gotypes/#any)[any](/documentation/reference/gotypes/#any)\) → [any](/documentation/reference/gotypes/#any) +\([any](/documentation/reference/gotypes/#any),[any](/documentation/reference/gotypes/#any)\) → [any](/documentation/reference/gotypes/#any) {.funcsig} First returns the first N items in a rangeable list. @@ -189,7 +189,7 @@ First returns the first N items in a rangeable list. ## collections.Group {#collections_namespace_group} -\([any](/documentation/reference/gotypes/#any)[any](/documentation/reference/gotypes/#any)\) → [any](/documentation/reference/gotypes/#any) +\([any](/documentation/reference/gotypes/#any),[any](/documentation/reference/gotypes/#any)\) → [any](/documentation/reference/gotypes/#any) {.funcsig} Group groups a set of elements by the given key. This is currently only supported for [Pages](/documentation/reference/objects/resources/page/pages) . @@ -206,7 +206,7 @@ This is currently only supported for [Pages](/documentation/reference/objects/r ## collections.In {#collections_namespace_in} -\([any](/documentation/reference/gotypes/#any)[any](/documentation/reference/gotypes/#any)\) → [bool](/documentation/reference/gotypes/#bool) +\([any](/documentation/reference/gotypes/#any),[any](/documentation/reference/gotypes/#any)\) → [bool](/documentation/reference/gotypes/#bool) {.funcsig} In returns whether v is in the set l. l may be an array or slice. @@ -222,7 +222,7 @@ In returns whether v is in the set l. l may be an array or slice. ## collections.Index {#collections_namespace_index} -\([any](/documentation/reference/gotypes/#any)[](/documentation/reference/objects//)\) → [any](/documentation/reference/gotypes/#any) +\([any](/documentation/reference/gotypes/#any),[...any](/documentation/reference/objects//...any)\) → [any](/documentation/reference/gotypes/#any) {.funcsig} Index returns the result of indexing its first argument by the following arguments. Thus "index x 1 2 3" is, in Go syntax, x[1][2][3]. Each @@ -263,7 +263,7 @@ l2 must be of the same type and may be either arrays or slices. ## collections.IsSet {#collections_namespace_isset} -\([any](/documentation/reference/gotypes/#any)[any](/documentation/reference/gotypes/#any)\) → [bool](/documentation/reference/gotypes/#bool) +\([any](/documentation/reference/gotypes/#any),[any](/documentation/reference/gotypes/#any)\) → [bool](/documentation/reference/gotypes/#bool) {.funcsig} IsSet returns whether a given array, channel, slice, or map has a key defined. @@ -280,7 +280,7 @@ defined. ## collections.KeyVals {#collections_namespace_keyvals} -\([any](/documentation/reference/gotypes/#any)[](/documentation/reference/objects//)\) → [KeyValues](/documentation/reference/objects/common/types/keyvalues) +\([any](/documentation/reference/gotypes/#any),[...any](/documentation/reference/objects//...any)\) → [KeyValues](/documentation/reference/objects/common/types/keyvalues) {.funcsig} KeyVals creates a key and values wrapper. @@ -296,7 +296,7 @@ KeyVals creates a key and values wrapper. ## collections.Last {#collections_namespace_last} -\([any](/documentation/reference/gotypes/#any)[any](/documentation/reference/gotypes/#any)\) → [any](/documentation/reference/gotypes/#any) +\([any](/documentation/reference/gotypes/#any),[any](/documentation/reference/gotypes/#any)\) → [any](/documentation/reference/gotypes/#any) {.funcsig} Last returns the last N items in a rangeable list. @@ -312,7 +312,7 @@ Last returns the last N items in a rangeable list. ## collections.Merge {#collections_namespace_merge} -\([](/documentation/reference/objects//)\) → [any](/documentation/reference/gotypes/#any) +\([...any](/documentation/reference/objects//...any)\) → [any](/documentation/reference/gotypes/#any) {.funcsig} Merge creates a copy of the final parameter and merges the preceding parameters into it in reverse order. @@ -330,7 +330,7 @@ Currently only maps are supported. Key handling is case insensitive. ## collections.NewScratch {#collections_namespace_newscratch} -\(\) → [](/documentation/reference/objects//) +\(\) → [*maps.Scratch](/documentation/reference/objects//*maps.scratch) {.funcsig} NewScratch creates a new Scratch which can be used to store values in a thread safe way. @@ -347,7 +347,7 @@ thread safe way. ## collections.Querify {#collections_namespace_querify} -\([](/documentation/reference/objects//)\) → [string](/documentation/reference/gotypes/#string) +\([...any](/documentation/reference/objects//...any)\) → [string](/documentation/reference/gotypes/#string) {.funcsig} Querify encodes the given parameters in URL-encoded form ("bar=baz&foo=quux") sorted by key. @@ -379,7 +379,7 @@ Reverse creates a copy of slice and reverses it. ## collections.Seq {#collections_namespace_seq} -\([](/documentation/reference/objects//)\) → [](/documentation/reference/objects//) +\([...any](/documentation/reference/objects//...any)\) → [[]int](/documentation/reference/objects//[]int) {.funcsig} Seq creates a sequence of integers. It's named and used as GNU's seq. @@ -427,7 +427,7 @@ Shuffle returns the given rangeable list in a randomised order. ## collections.Slice {#collections_namespace_slice} -\([](/documentation/reference/objects//)\) → [any](/documentation/reference/gotypes/#any) +\([...any](/documentation/reference/objects//...any)\) → [any](/documentation/reference/gotypes/#any) {.funcsig} Slice returns a slice of all passed arguments. @@ -443,7 +443,7 @@ Slice returns a slice of all passed arguments. ## collections.Sort {#collections_namespace_sort} -\([any](/documentation/reference/gotypes/#any)[](/documentation/reference/objects//)\) → [any](/documentation/reference/gotypes/#any) +\([any](/documentation/reference/gotypes/#any),[...any](/documentation/reference/objects//...any)\) → [any](/documentation/reference/gotypes/#any) {.funcsig} Sort returns a sorted sequence. @@ -512,7 +512,7 @@ duplicate elements removed. ## collections.Where {#collections_namespace_where} -\([any](/documentation/reference/gotypes/#any)[](/documentation/reference/objects//)\) → [any](/documentation/reference/gotypes/#any) +\([any](/documentation/reference/gotypes/#any),[...any](/documentation/reference/objects//...any)\) → [any](/documentation/reference/gotypes/#any) {.funcsig} Where returns a filtered subset of a given data type. diff --git a/exampleSite/content/en/documentation/reference/functions/tpl/compare/compare/index.md b/exampleSite/content/en/documentation/reference/functions/tpl/compare/compare/index.md index 999714d..5ee6e93 100644 --- a/exampleSite/content/en/documentation/reference/functions/tpl/compare/compare/index.md +++ b/exampleSite/content/en/documentation/reference/functions/tpl/compare/compare/index.md @@ -30,7 +30,7 @@ hugoSymbol: TODO ## compare.Conditional {#compare_namespace_conditional} -\([bool](/documentation/reference/gotypes/#bool)[any](/documentation/reference/gotypes/#any)\) → [any](/documentation/reference/gotypes/#any) +\([bool](/documentation/reference/gotypes/#bool),[any](/documentation/reference/gotypes/#any)\) → [any](/documentation/reference/gotypes/#any) {.funcsig} Conditional can be used as a ternary operator. It returns a if condition, else b. @@ -47,7 +47,7 @@ It returns a if condition, else b. ## compare.Default {#compare_namespace_default} -\([any](/documentation/reference/gotypes/#any)[](/documentation/reference/objects//)\) → [any](/documentation/reference/gotypes/#any) +\([any](/documentation/reference/gotypes/#any),[...any](/documentation/reference/objects//...any)\) → [any](/documentation/reference/gotypes/#any) {.funcsig} Default checks whether a given value is set and returns a default value if it is not. "Set" in this context means non-zero for numeric types and times; @@ -66,7 +66,7 @@ any boolean or struct value; or non-nil for any other types. ## compare.Eq {#compare_namespace_eq} -\([any](/documentation/reference/gotypes/#any)[](/documentation/reference/objects//)\) → [bool](/documentation/reference/gotypes/#bool) +\([any](/documentation/reference/gotypes/#any),[...any](/documentation/reference/objects//...any)\) → [bool](/documentation/reference/gotypes/#bool) {.funcsig} Eq returns the boolean truth of arg1 == arg2 || arg1 == arg3 || arg1 == arg4. @@ -82,7 +82,7 @@ Eq returns the boolean truth of arg1 == arg2 || arg1 == arg3 || arg1 == arg4. ## compare.Ge {#compare_namespace_ge} -\([any](/documentation/reference/gotypes/#any)[](/documentation/reference/objects//)\) → [bool](/documentation/reference/gotypes/#bool) +\([any](/documentation/reference/gotypes/#any),[...any](/documentation/reference/objects//...any)\) → [bool](/documentation/reference/gotypes/#bool) {.funcsig} Ge returns the boolean truth of arg1 >= arg2 && arg1 >= arg3 && arg1 >= arg4. @@ -98,7 +98,7 @@ Ge returns the boolean truth of arg1 >= arg2 && arg1 >= arg3 && arg1 >= arg4. ## compare.Gt {#compare_namespace_gt} -\([any](/documentation/reference/gotypes/#any)[](/documentation/reference/objects//)\) → [bool](/documentation/reference/gotypes/#bool) +\([any](/documentation/reference/gotypes/#any),[...any](/documentation/reference/objects//...any)\) → [bool](/documentation/reference/gotypes/#bool) {.funcsig} Gt returns the boolean truth of arg1 > arg2 && arg1 > arg3 && arg1 > arg4. @@ -114,7 +114,7 @@ Gt returns the boolean truth of arg1 > arg2 && arg1 > arg3 && arg1 > arg4. ## compare.Le {#compare_namespace_le} -\([any](/documentation/reference/gotypes/#any)[](/documentation/reference/objects//)\) → [bool](/documentation/reference/gotypes/#bool) +\([any](/documentation/reference/gotypes/#any),[...any](/documentation/reference/objects//...any)\) → [bool](/documentation/reference/gotypes/#bool) {.funcsig} Le returns the boolean truth of arg1 <= arg2 && arg1 <= arg3 && arg1 <= arg4. @@ -130,7 +130,7 @@ Le returns the boolean truth of arg1 <= arg2 && arg1 <= arg3 && arg1 <= arg4. ## compare.Lt {#compare_namespace_lt} -\([any](/documentation/reference/gotypes/#any)[](/documentation/reference/objects//)\) → [bool](/documentation/reference/gotypes/#bool) +\([any](/documentation/reference/gotypes/#any),[...any](/documentation/reference/objects//...any)\) → [bool](/documentation/reference/gotypes/#bool) {.funcsig} Lt returns the boolean truth of arg1 < arg2 && arg1 < arg3 && arg1 < arg4. @@ -148,7 +148,7 @@ Lt returns the boolean truth of arg1 < arg2 && arg1 < arg3 && arg1 < arg4. ## compare.Ne {#compare_namespace_ne} -\([any](/documentation/reference/gotypes/#any)[](/documentation/reference/objects//)\) → [bool](/documentation/reference/gotypes/#bool) +\([any](/documentation/reference/gotypes/#any),[...any](/documentation/reference/objects//...any)\) → [bool](/documentation/reference/gotypes/#bool) {.funcsig} Ne returns the boolean truth of arg1 != arg2 && arg1 != arg3 && arg1 != arg4. diff --git a/exampleSite/content/en/documentation/reference/functions/tpl/crypto/crypto/index.md b/exampleSite/content/en/documentation/reference/functions/tpl/crypto/crypto/index.md index 10a2dda..68734ef 100644 --- a/exampleSite/content/en/documentation/reference/functions/tpl/crypto/crypto/index.md +++ b/exampleSite/content/en/documentation/reference/functions/tpl/crypto/crypto/index.md @@ -46,7 +46,7 @@ FNV32a hashes using fnv32a algorithm ## crypto.HMAC {#crypto_namespace_hmac} -\([any](/documentation/reference/gotypes/#any)[any](/documentation/reference/gotypes/#any)[any](/documentation/reference/gotypes/#any)[](/documentation/reference/objects//)\) → [string](/documentation/reference/gotypes/#string) +\([any](/documentation/reference/gotypes/#any),[any](/documentation/reference/gotypes/#any),[any](/documentation/reference/gotypes/#any),[...any](/documentation/reference/objects//...any)\) → [string](/documentation/reference/gotypes/#string) {.funcsig} HMAC returns a cryptographic hash that uses a key to sign a message. diff --git a/exampleSite/content/en/documentation/reference/functions/tpl/data/data/index.md b/exampleSite/content/en/documentation/reference/functions/tpl/data/data/index.md index 2c3cb29..07fe982 100644 --- a/exampleSite/content/en/documentation/reference/functions/tpl/data/data/index.md +++ b/exampleSite/content/en/documentation/reference/functions/tpl/data/data/index.md @@ -30,7 +30,7 @@ hugoSymbol: TODO ## data.GetCSV {#data_namespace_getcsv} -\([string](/documentation/reference/gotypes/#string)[](/documentation/reference/objects//)\) → [](/documentation/reference/objects//) +\([string](/documentation/reference/gotypes/#string),[...any](/documentation/reference/objects//...any)\) → [[][]string](/documentation/reference/objects//[][]string) {.funcsig} GetCSV expects a data separator and one or n-parts of a URL to a resource which can either be a local or a remote one. @@ -50,7 +50,7 @@ GetCSV returns nil or a slice slice to use in a short code. ## data.GetJSON {#data_namespace_getjson} -\([](/documentation/reference/objects//)\) → [any](/documentation/reference/gotypes/#any) +\([...any](/documentation/reference/objects//...any)\) → [any](/documentation/reference/gotypes/#any) {.funcsig} GetJSON expects one or n-parts of a URL to a resource which can either be a local or a remote one. If you provide multiple parts they will be joined together to the final URL. diff --git a/exampleSite/content/en/documentation/reference/functions/tpl/encoding/encoding/index.md b/exampleSite/content/en/documentation/reference/functions/tpl/encoding/encoding/index.md index b6f247d..84d1d27 100644 --- a/exampleSite/content/en/documentation/reference/functions/tpl/encoding/encoding/index.md +++ b/exampleSite/content/en/documentation/reference/functions/tpl/encoding/encoding/index.md @@ -62,7 +62,7 @@ Base64Encode returns the base64 encoding of the given content. ## encoding.Jsonify {#encoding_namespace_jsonify} -\([](/documentation/reference/objects//)\) → [HTML](/documentation/reference/objects/html/template/html) +\([...any](/documentation/reference/objects//...any)\) → [HTML](/documentation/reference/objects/html/template/html) {.funcsig} Jsonify encodes a given object to JSON. To pretty print the JSON, pass a map or dictionary of options as the first argument. Supported options are diff --git a/exampleSite/content/en/documentation/reference/functions/tpl/fmt/fmt/index.md b/exampleSite/content/en/documentation/reference/functions/tpl/fmt/fmt/index.md index be333e9..d27cf21 100644 --- a/exampleSite/content/en/documentation/reference/functions/tpl/fmt/fmt/index.md +++ b/exampleSite/content/en/documentation/reference/functions/tpl/fmt/fmt/index.md @@ -30,7 +30,7 @@ hugoSymbol: TODO ## fmt.Errorf {#fmt_namespace_errorf} -\([string](/documentation/reference/gotypes/#string)[](/documentation/reference/objects//)\) → [string](/documentation/reference/gotypes/#string) +\([string](/documentation/reference/gotypes/#string),[...any](/documentation/reference/objects//...any)\) → [string](/documentation/reference/gotypes/#string) {.funcsig} Errorf formats according to a format specifier and logs an ERROR. It returns an empty string. @@ -47,7 +47,7 @@ It returns an empty string. ## fmt.Erroridf {#fmt_namespace_erroridf} -\([string](/documentation/reference/gotypes/#string)[](/documentation/reference/objects//)\) → [string](/documentation/reference/gotypes/#string) +\([string](/documentation/reference/gotypes/#string),[...any](/documentation/reference/objects//...any)\) → [string](/documentation/reference/gotypes/#string) {.funcsig} Erroridf formats according to a format specifier and logs an ERROR and an information text that the error with the given ID can be suppressed in config. @@ -65,7 +65,7 @@ It returns an empty string. ## fmt.Print {#fmt_namespace_print} -\([](/documentation/reference/objects//)\) → [string](/documentation/reference/gotypes/#string) +\([...any](/documentation/reference/objects//...any)\) → [string](/documentation/reference/gotypes/#string) {.funcsig} Print returns string representation of the passed arguments. @@ -81,7 +81,7 @@ Print returns string representation of the passed arguments. ## fmt.Printf {#fmt_namespace_printf} -\([string](/documentation/reference/gotypes/#string)[](/documentation/reference/objects//)\) → [string](/documentation/reference/gotypes/#string) +\([string](/documentation/reference/gotypes/#string),[...any](/documentation/reference/objects//...any)\) → [string](/documentation/reference/gotypes/#string) {.funcsig} Printf returns a formatted string representation of the passed arguments. @@ -97,7 +97,7 @@ Printf returns a formatted string representation of the passed arguments. ## fmt.Println {#fmt_namespace_println} -\([](/documentation/reference/objects//)\) → [string](/documentation/reference/gotypes/#string) +\([...any](/documentation/reference/objects//...any)\) → [string](/documentation/reference/gotypes/#string) {.funcsig} Println returns string representation of the passed arguments ending with a newline. @@ -113,7 +113,7 @@ Println returns string representation of the passed arguments ending with a newl ## fmt.Warnf {#fmt_namespace_warnf} -\([string](/documentation/reference/gotypes/#string)[](/documentation/reference/objects//)\) → [string](/documentation/reference/gotypes/#string) +\([string](/documentation/reference/gotypes/#string),[...any](/documentation/reference/objects//...any)\) → [string](/documentation/reference/gotypes/#string) {.funcsig} Warnf formats according to a format specifier and logs a WARNING. It returns an empty string. diff --git a/exampleSite/content/en/documentation/reference/functions/tpl/images/images/index.md b/exampleSite/content/en/documentation/reference/functions/tpl/images/images/index.md index ce0b90e..55de507 100644 --- a/exampleSite/content/en/documentation/reference/functions/tpl/images/images/index.md +++ b/exampleSite/content/en/documentation/reference/functions/tpl/images/images/index.md @@ -51,7 +51,7 @@ working directory. ## images.Filter {#images_namespace_filter} -\([](/documentation/reference/objects//)\) → [ImageResource](/documentation/reference/objects/resources/images/imageresource) +\([...any](/documentation/reference/objects//...any)\) → [ImageResource](/documentation/reference/objects/resources/images/imageresource) {.funcsig} {{< docs/func-aliases "images.Filter" >}} diff --git a/exampleSite/content/en/documentation/reference/functions/tpl/js/js/index.md b/exampleSite/content/en/documentation/reference/functions/tpl/js/js/index.md index 45f0540..7eee27e 100644 --- a/exampleSite/content/en/documentation/reference/functions/tpl/js/js/index.md +++ b/exampleSite/content/en/documentation/reference/functions/tpl/js/js/index.md @@ -30,7 +30,7 @@ hugoSymbol: TODO ## js.Build {#js_namespace_build} -\([](/documentation/reference/objects//)\) → [Resource](/documentation/reference/objects/resources/resource/resource) +\([...any](/documentation/reference/objects//...any)\) → [Resource](/documentation/reference/objects/resources/resource/resource) {.funcsig} Build processes the given Resource with ESBuild. diff --git a/exampleSite/content/en/documentation/reference/functions/tpl/lang/lang/index.md b/exampleSite/content/en/documentation/reference/functions/tpl/lang/lang/index.md index cc34d31..58e2865 100644 --- a/exampleSite/content/en/documentation/reference/functions/tpl/lang/lang/index.md +++ b/exampleSite/content/en/documentation/reference/functions/tpl/lang/lang/index.md @@ -84,7 +84,7 @@ FormatNumber formats number with the given precision for the current language. ## lang.FormatNumberCustom {#lang_namespace_formatnumbercustom} -\([any](/documentation/reference/gotypes/#any)[](/documentation/reference/objects//)\) → [string](/documentation/reference/gotypes/#string) +\([any](/documentation/reference/gotypes/#any),[...any](/documentation/reference/objects//...any)\) → [string](/documentation/reference/gotypes/#string) {.funcsig} FormatNumberCustom formats a number with the given precision using the negative, decimal, and grouping options. The `options` @@ -143,7 +143,7 @@ Merge creates a union of pages from two languages. ## lang.Translate {#lang_namespace_translate} -\([any](/documentation/reference/gotypes/#any)[](/documentation/reference/objects//)\) → [string](/documentation/reference/gotypes/#string) +\([any](/documentation/reference/gotypes/#any),[...any](/documentation/reference/objects//...any)\) → [string](/documentation/reference/gotypes/#string) {.funcsig} Translate returns a translated string for id. diff --git a/exampleSite/content/en/documentation/reference/functions/tpl/openapi/openapi3/openapi/openapi3/index.md b/exampleSite/content/en/documentation/reference/functions/tpl/openapi/openapi3/openapi/openapi3/index.md index 1b49d47..21440a5 100644 --- a/exampleSite/content/en/documentation/reference/functions/tpl/openapi/openapi3/openapi/openapi3/index.md +++ b/exampleSite/content/en/documentation/reference/functions/tpl/openapi/openapi3/openapi/openapi3/index.md @@ -30,7 +30,7 @@ hugoSymbol: TODO ## openapi3.Unmarshal {#openapi3_namespace_unmarshal} -\([UnmarshableResource](/documentation/reference/objects/resources/resource/unmarshableresource)\) → [](/documentation/reference/objects//) +\([UnmarshableResource](/documentation/reference/objects/resources/resource/unmarshableresource)\) → [*kopenapi3.T](/documentation/reference/objects//*kopenapi3.t) {.funcsig} {{< docs/func-aliases "openapi3.Unmarshal" >}} diff --git a/exampleSite/content/en/documentation/reference/functions/tpl/os/os/index.md b/exampleSite/content/en/documentation/reference/functions/tpl/os/os/index.md index 3aac5e9..679774f 100644 --- a/exampleSite/content/en/documentation/reference/functions/tpl/os/os/index.md +++ b/exampleSite/content/en/documentation/reference/functions/tpl/os/os/index.md @@ -63,7 +63,7 @@ It returns the value, which will be empty if the variable is not present. ## os.ReadDir {#os_namespace_readdir} -\([any](/documentation/reference/gotypes/#any)\) → [](/documentation/reference/objects//) +\([any](/documentation/reference/gotypes/#any)\) → [[]_os.FileInfo](/documentation/reference/objects//[]_os.fileinfo) {.funcsig} ReadDir lists the directory contents relative to the configured WorkingDir. diff --git a/exampleSite/content/en/documentation/reference/functions/tpl/partials/partials/index.md b/exampleSite/content/en/documentation/reference/functions/tpl/partials/partials/index.md index 9d8a704..5039a94 100644 --- a/exampleSite/content/en/documentation/reference/functions/tpl/partials/partials/index.md +++ b/exampleSite/content/en/documentation/reference/functions/tpl/partials/partials/index.md @@ -30,7 +30,7 @@ hugoSymbol: TODO ## partials.Include {#partials_namespace_include} -\([string](/documentation/reference/gotypes/#string)[](/documentation/reference/objects//)\) → [any](/documentation/reference/gotypes/#any) +\(,[string](/documentation/reference/gotypes/#string),[...any](/documentation/reference/objects//...any)\) → [any](/documentation/reference/gotypes/#any) {.funcsig} Include executes the named partial. If the partial contains a return statement, that value will be returned. @@ -50,7 +50,7 @@ Note that ctx is provided by Hugo, not the end user. ## partials.IncludeCached {#partials_namespace_includecached} -\([string](/documentation/reference/gotypes/#string)[any](/documentation/reference/gotypes/#any)[](/documentation/reference/objects//)\) → [any](/documentation/reference/gotypes/#any) +\(,[string](/documentation/reference/gotypes/#string),[any](/documentation/reference/gotypes/#any),[...any](/documentation/reference/objects//...any)\) → [any](/documentation/reference/gotypes/#any) {.funcsig} IncludeCached executes and caches partial templates. The cache is created with name+variants as the key. Note that ctx is provided by Hugo, not the end user. diff --git a/exampleSite/content/en/documentation/reference/functions/tpl/path/path/index.md b/exampleSite/content/en/documentation/reference/functions/tpl/path/path/index.md index 235da08..d11a905 100644 --- a/exampleSite/content/en/documentation/reference/functions/tpl/path/path/index.md +++ b/exampleSite/content/en/documentation/reference/functions/tpl/path/path/index.md @@ -113,7 +113,7 @@ to forward slashes. ## path.Join {#path_namespace_join} -\([](/documentation/reference/objects//)\) → [string](/documentation/reference/gotypes/#string) +\([...any](/documentation/reference/objects//...any)\) → [string](/documentation/reference/gotypes/#string) {.funcsig} Join joins any number of path elements into a single path, adding a separating slash if necessary. All the input diff --git a/exampleSite/content/en/documentation/reference/functions/tpl/strings/strings/index.md b/exampleSite/content/en/documentation/reference/functions/tpl/strings/strings/index.md index 5b188ea..1b797dd 100644 --- a/exampleSite/content/en/documentation/reference/functions/tpl/strings/strings/index.md +++ b/exampleSite/content/en/documentation/reference/functions/tpl/strings/strings/index.md @@ -127,7 +127,7 @@ CountWords returns the approximate word count in s. ## strings.FindRE {#strings_namespace_findre} -\([string](/documentation/reference/gotypes/#string)[any](/documentation/reference/gotypes/#any)[](/documentation/reference/objects//)\) → [](/documentation/reference/objects//) +\([string](/documentation/reference/gotypes/#string),[any](/documentation/reference/gotypes/#any),[...any](/documentation/reference/objects//...any)\) → [[]string](/documentation/reference/objects//[]string) {.funcsig} FindRE returns a list of strings that match the regular expression. By default all matches will be included. The number of matches can be limited with an optional third parameter. @@ -208,7 +208,7 @@ Repeat returns a new string consisting of count copies of the string s. ## strings.Replace {#strings_namespace_replace} -\([any](/documentation/reference/gotypes/#any)[](/documentation/reference/objects//)\) → [string](/documentation/reference/gotypes/#string) +\([any](/documentation/reference/gotypes/#any),[...any](/documentation/reference/objects//...any)\) → [string](/documentation/reference/gotypes/#string) {.funcsig} Replace returns a copy of the string s with all occurrences of old replaced with new. The number of replacements can be limited with an optional fourth @@ -226,7 +226,7 @@ parameter. ## strings.ReplaceRE {#strings_namespace_replacere} -\([any](/documentation/reference/gotypes/#any)[](/documentation/reference/objects//)\) → [string](/documentation/reference/gotypes/#string) +\([any](/documentation/reference/gotypes/#any),[...any](/documentation/reference/objects//...any)\) → [string](/documentation/reference/gotypes/#string) {.funcsig} ReplaceRE returns a copy of s, replacing all matches of the regular expression pattern with the replacement text repl. The number of replacements @@ -260,7 +260,7 @@ RuneCount returns the number of runes in s. ## strings.SliceString {#strings_namespace_slicestring} -\([any](/documentation/reference/gotypes/#any)[](/documentation/reference/objects//)\) → [string](/documentation/reference/gotypes/#string) +\([any](/documentation/reference/gotypes/#any),[...any](/documentation/reference/objects//...any)\) → [string](/documentation/reference/gotypes/#string) {.funcsig} SliceString slices a string by specifying a half-open range with two indices, start and end. 1 and 4 creates a slice including elements 1 through 3. @@ -278,7 +278,7 @@ The end index can be omitted, it defaults to the string's length. ## strings.Split {#strings_namespace_split} -\([any](/documentation/reference/gotypes/#any)[string](/documentation/reference/gotypes/#string)\) → [](/documentation/reference/objects//) +\([any](/documentation/reference/gotypes/#any),[string](/documentation/reference/gotypes/#string)\) → [[]string](/documentation/reference/objects//[]string) {.funcsig} Split slices an input string into all substrings separated by delimiter. @@ -294,7 +294,7 @@ Split slices an input string into all substrings separated by delimiter. ## strings.Substr {#strings_namespace_substr} -\([any](/documentation/reference/gotypes/#any)[](/documentation/reference/objects//)\) → [string](/documentation/reference/gotypes/#string) +\([any](/documentation/reference/gotypes/#any),[...any](/documentation/reference/objects//...any)\) → [string](/documentation/reference/gotypes/#string) {.funcsig} Substr extracts parts of a string, beginning at the character at the specified position, and returns the specified number of characters. @@ -457,7 +457,7 @@ doesn't end with suffix, s is returned unchanged. ## strings.Truncate {#strings_namespace_truncate} -\([any](/documentation/reference/gotypes/#any)[](/documentation/reference/objects//)\) → [HTML](/documentation/reference/objects/html/template/html) +\([any](/documentation/reference/gotypes/#any),[...any](/documentation/reference/objects//...any)\) → [HTML](/documentation/reference/objects/html/template/html) {.funcsig} Truncate truncates a given string to the specified length. diff --git a/exampleSite/content/en/documentation/reference/functions/tpl/time/time/index.md b/exampleSite/content/en/documentation/reference/functions/tpl/time/time/index.md index 2774966..df66b1f 100644 --- a/exampleSite/content/en/documentation/reference/functions/tpl/time/time/index.md +++ b/exampleSite/content/en/documentation/reference/functions/tpl/time/time/index.md @@ -30,7 +30,7 @@ hugoSymbol: TODO ## time.AsTime {#time_namespace_astime} -\([any](/documentation/reference/gotypes/#any)[](/documentation/reference/objects//)\) → [any](/documentation/reference/gotypes/#any) +\([any](/documentation/reference/gotypes/#any),[...any](/documentation/reference/objects//...any)\) → [any](/documentation/reference/gotypes/#any) {.funcsig} AsTime converts the textual representation of the datetime string into a time.Time interface. @@ -47,7 +47,7 @@ a time.Time interface. ## time.Duration {#time_namespace_duration} -\([any](/documentation/reference/gotypes/#any)[any](/documentation/reference/gotypes/#any)\) → [Duration](/documentation/reference/objects/time/duration) +\([any](/documentation/reference/gotypes/#any),[any](/documentation/reference/gotypes/#any)\) → [Duration](/documentation/reference/objects/time/duration) {.funcsig} Duration converts the given number to a time.Duration. Unit is one of nanosecond/ns, microsecond/us/µs, millisecond/ms, second/s, minute/m or hour/h. @@ -64,7 +64,7 @@ Unit is one of nanosecond/ns, microsecond/us/µs, millisecond/ms, second/s, minu ## time.Format {#time_namespace_format} -\([string](/documentation/reference/gotypes/#string)[any](/documentation/reference/gotypes/#any)\) → [string](/documentation/reference/gotypes/#string) +\([string](/documentation/reference/gotypes/#string),[any](/documentation/reference/gotypes/#any)\) → [string](/documentation/reference/gotypes/#string) {.funcsig} Format converts the textual representation of the datetime string into the other form or returns it of the time.Time value. These are formatted diff --git a/exampleSite/content/en/documentation/reference/functions/tpl/transform/transform/index.md b/exampleSite/content/en/documentation/reference/functions/tpl/transform/transform/index.md index 6588ce0..c6517d1 100644 --- a/exampleSite/content/en/documentation/reference/functions/tpl/transform/transform/index.md +++ b/exampleSite/content/en/documentation/reference/functions/tpl/transform/transform/index.md @@ -97,7 +97,7 @@ text. ## transform.Highlight {#transform_namespace_highlight} -\([any](/documentation/reference/gotypes/#any)[string](/documentation/reference/gotypes/#string)[](/documentation/reference/objects//)\) → [HTML](/documentation/reference/objects/html/template/html) +\([any](/documentation/reference/gotypes/#any),[string](/documentation/reference/gotypes/#string),[...any](/documentation/reference/objects//...any)\) → [HTML](/documentation/reference/objects/html/template/html) {.funcsig} Highlight returns a copy of s as an HTML string with syntax highlighting applied. @@ -114,7 +114,7 @@ highlighting applied. ## transform.HighlightCodeBlock {#transform_namespace_highlightcodeblock} -\([CodeblockContext](/documentation/reference/objects/markup/converter/hooks/codeblockcontext)[](/documentation/reference/objects//)\) → [HightlightResult](/documentation/reference/objects/markup/highlight/hightlightresult) +\([CodeblockContext](/documentation/reference/objects/markup/converter/hooks/codeblockcontext),[...any](/documentation/reference/objects//...any)\) → [HightlightResult](/documentation/reference/objects/markup/highlight/hightlightresult) {.funcsig} HighlightCodeBlock highlights a code block on the form received in the codeblock render hooks. @@ -162,7 +162,7 @@ Plainify returns a copy of s with all HTML tags removed. ## transform.Remarshal {#transform_namespace_remarshal} -\([string](/documentation/reference/gotypes/#string)[any](/documentation/reference/gotypes/#any)\) → [string](/documentation/reference/gotypes/#string) +\([string](/documentation/reference/gotypes/#string),[any](/documentation/reference/gotypes/#any)\) → [string](/documentation/reference/gotypes/#string) {.funcsig} Remarshal is used in the Hugo documentation to convert configuration examples from YAML to JSON, TOML (and possibly the other way around). @@ -197,7 +197,7 @@ Format is one of json, yaml or toml. ## transform.Unmarshal {#transform_namespace_unmarshal} -\([](/documentation/reference/objects//)\) → [any](/documentation/reference/gotypes/#any) +\([...any](/documentation/reference/objects//...any)\) → [any](/documentation/reference/gotypes/#any) {.funcsig} Unmarshal unmarshals the data given, which can be either a string, json.RawMessage or a Resource. Supported formats are JSON, TOML, YAML, and CSV. diff --git a/exampleSite/content/en/documentation/reference/functions/tpl/urls/urls/index.md b/exampleSite/content/en/documentation/reference/functions/tpl/urls/urls/index.md index f93ca87..0033645 100644 --- a/exampleSite/content/en/documentation/reference/functions/tpl/urls/urls/index.md +++ b/exampleSite/content/en/documentation/reference/functions/tpl/urls/urls/index.md @@ -80,7 +80,7 @@ Anchorize creates sanitized anchor names that are compatible with Blackfriday. ## urls.Parse {#urls_namespace_parse} -\([any](/documentation/reference/gotypes/#any)\) → [](/documentation/reference/objects//) +\([any](/documentation/reference/gotypes/#any)\) → [*url.URL](/documentation/reference/objects//*url.url) {.funcsig} Parse parses rawurl into a URL structure. The rawurl may be relative or absolute. @@ -97,7 +97,7 @@ absolute. ## urls.Ref {#urls_namespace_ref} -\([any](/documentation/reference/gotypes/#any)[any](/documentation/reference/gotypes/#any)\) → [HTML](/documentation/reference/objects/html/template/html) +\([any](/documentation/reference/gotypes/#any),[any](/documentation/reference/gotypes/#any)\) → [HTML](/documentation/reference/objects/html/template/html) {.funcsig} Ref returns the absolute URL path to a given content item. @@ -130,7 +130,7 @@ page's position in the project directory structure and the current language. ## urls.RelRef {#urls_namespace_relref} -\([any](/documentation/reference/gotypes/#any)[any](/documentation/reference/gotypes/#any)\) → [HTML](/documentation/reference/objects/html/template/html) +\([any](/documentation/reference/gotypes/#any),[any](/documentation/reference/gotypes/#any)\) → [HTML](/documentation/reference/objects/html/template/html) {.funcsig} RelRef returns the relative URL path to a given content item. diff --git a/exampleSite/content/en/documentation/reference/objects/hugo/index.md b/exampleSite/content/en/documentation/reference/objects/hugo/index.md index 155d303..07d96f1 100644 --- a/exampleSite/content/en/documentation/reference/objects/hugo/index.md +++ b/exampleSite/content/en/documentation/reference/objects/hugo/index.md @@ -59,7 +59,7 @@ It can be any string, but it will be all lower case. ## Deps {#hugo_info_deps} -\(\) → [](/documentation/reference/objects//) +\(\) → [[]*Dependency](/documentation/reference/objects//[]*dependency) {.funcsig} Deps gets a list of dependencies for this Hugo build. diff --git a/exampleSite/content/en/documentation/reference/objects/media/type/index.md b/exampleSite/content/en/documentation/reference/objects/media/type/index.md index 80816a8..e310123 100644 --- a/exampleSite/content/en/documentation/reference/objects/media/type/index.md +++ b/exampleSite/content/en/documentation/reference/objects/media/type/index.md @@ -83,7 +83,7 @@ TODO(bep) improve ## Suffixes {#media_type_suffixes} -\(\) → [](/documentation/reference/objects//) +\(\) → [[]string](/documentation/reference/objects//[]string) {.funcsig} Suffixes returns all valid file suffixes for this type. diff --git a/exampleSite/content/en/documentation/reference/objects/navigation/menus/index.md b/exampleSite/content/en/documentation/reference/objects/navigation/menus/index.md index 0a8a776..0f210e9 100644 --- a/exampleSite/content/en/documentation/reference/objects/navigation/menus/index.md +++ b/exampleSite/content/en/documentation/reference/objects/navigation/menus/index.md @@ -242,7 +242,7 @@ HasChildren returns whether this menu item has any children. ## IsEqual {#navigation_menuentry_isequal} -\([](/documentation/reference/objects//)\) → [bool](/documentation/reference/gotypes/#bool) +\([*MenuEntry](/documentation/reference/objects//*menuentry)\) → [bool](/documentation/reference/gotypes/#bool) {.funcsig} IsEqual returns whether the two menu entries represents the same menu entry. @@ -255,7 +255,7 @@ IsEqual returns whether the two menu entries represents the same menu entry. ## IsSameResource {#navigation_menuentry_issameresource} -\([](/documentation/reference/objects//)\) → [bool](/documentation/reference/gotypes/#bool) +\([*MenuEntry](/documentation/reference/objects//*menuentry)\) → [bool](/documentation/reference/gotypes/#bool) {.funcsig} IsSameResource returns whether the two menu entries points to the same resource (URL). diff --git a/exampleSite/content/en/documentation/reference/objects/site/index.md b/exampleSite/content/en/documentation/reference/objects/site/index.md index 178e8a7..21f9472 100644 --- a/exampleSite/content/en/documentation/reference/objects/site/index.md +++ b/exampleSite/content/en/documentation/reference/objects/site/index.md @@ -22,7 +22,7 @@ weight: 10 ## Language {#page_site_language} -\(\) → [](/documentation/reference/objects//) +\(\) → [*langs.Language](/documentation/reference/objects//*langs.language) {.funcsig} Returns the `Language` configured for this Site. @@ -142,7 +142,7 @@ Returns the `Params` configured for this site. ## Data {#page_site_data} -\(\) → [](/documentation/reference/objects//) +\(\) → [map[string]any](/documentation/reference/objects//map[string]any) {.funcsig} Returns a map of all the data inside /data. diff --git a/exampleSite/content/en/documentation/tutorials/hosting-and-deployment/hosting-on-github.md b/exampleSite/content/en/documentation/tutorials/hosting-and-deployment/hosting-on-github.md index 2250d87..891d702 100644 --- a/exampleSite/content/en/documentation/tutorials/hosting-and-deployment/hosting-on-github.md +++ b/exampleSite/content/en/documentation/tutorials/hosting-and-deployment/hosting-on-github.md @@ -1,10 +1,11 @@ --- title: Host on GitHub linktitle: Host on GitHub -description: Deploy Hugo as a GitHub Pages project or personal/organizational site and automate the whole process with Github Action Workflow +description: Deploy Hugo as a GitHub Pages project or personal/organizational site and automate the whole process with Github Action Workflow. date: 2014-03-21 publishdate: 2014-03-21 categories: [hosting and deployment] +tags: [github, git] keywords: [github,git,deployment,hosting] authors: [Spencer Lyon, Gunnar Morling] @@ -79,7 +80,7 @@ jobs: publish_dir: ./public ``` -For more advanced settings https://github.com/marketplace/actions/hugo-setup +For more advanced settings https://github.com/marketplace/actions/hugo-setup ## Use a Custom Domain diff --git a/layouts/404.html b/layouts/404.html index 0e0414c..3fe137e 100644 --- a/layouts/404.html +++ b/layouts/404.html @@ -1,7 +1,7 @@ {{ define "main" }} <main class="clearfix p-5 lg:p-4 text-xl text-center mx-auto max-w-lg leading-normal text-gray-600"> - <h1 class="text-3xl sm:text-4xl"> + <h1 class="text-2xl sm:text-4xl"> The page you're looking for doesn't exist. Perhaps you'd like to gopher something else? Sorry. </h1> diff --git a/layouts/_default/list.html b/layouts/_default/list.html index 4961813..718a104 100644 --- a/layouts/_default/list.html +++ b/layouts/_default/list.html @@ -1,16 +1,16 @@ {{ define "main" }} {{ $pages := .Pages }} - <h1 class="text-3xl text-black font-semibold"> + <h1 class="text-2xl text-black font-semibold"> {{ .Title | title }} </h1> {{ if gt (len .Content) 20 }} - <div class="mt-6 text-lg text-black"> + <div class="mt-4 text-lg text-black"> {{ .Content }} </div> {{ end }} {{ if $pages }} {{ $interior_classes := site.Params.flex_box_interior_classes }} - <section class="grid grid-cols-1 sm:grid-cols-2 gap-4 mt-6"> + <section class="grid grid-cols-1 sm:grid-cols-2 gap-4 -mx-4 mt-8"> {{ range $pages }} {{ partial "boxes-section-summaries.html" (dict "context" . "classes" $interior_classes "fullcontent" true) }} {{ end }} diff --git a/layouts/_default/page.html b/layouts/_default/page.html index 09911b0..d81c668 100644 --- a/layouts/_default/page.html +++ b/layouts/_default/page.html @@ -4,20 +4,20 @@ {{ range $categories }} <a href="{{ .RelPermalink }}" - class="text-sm tracking-wider mb-0 link text-gray-500 dim mr-3"> + class="text-sm tracking-tight mb-0 text-green-600 hover:text-green-500"> {{ .Title | upper }} </a> {{ end }} </div> - <h1 class="text-3xl font-semibold leading-tight mb-3 my-0 text-black"> + <h1 class="text-2xl font-semibold leading-tight mb-3 my-0 text-black"> {{ .Title }} </h1> </header> <div class="mt-2 md:mt-4 prose lg:prose-lg" id="prose"> {{ with .Params.description }} - <div class="text-base leading-relaxed mb-5"> + <div class="text-lg leading-relaxed mb-5"> {{ . | $.RenderString }} </div> {{ end }} @@ -25,10 +25,10 @@ {{ $tags := .GetTerms "tags" }} {{ range $tags }} {{ $color := partial "helpers/funcs/color-from-string" .LinkTitle }} - {{ $class := printf "text-%s-600 bg-%s-200" $color $color }} + {{ $class := printf "text-%s-%d bg-%s-%d border border-%s-%d shadow-md" $color.color $color.shade1 $color.color $color.shade2 $color.color $color.shade1 }} <a href="{{ .RelPermalink }}" - class="{{ $class }} text-xs font-semibold no-underline inline-block py-1 px-2 uppercase rounded-full uppercase last:mr-0 mr-1 hover:opacity-75"> + class="{{ $class }} text-xs font-semibold no-underline inline-block py-1 px-2 uppercase rounded-full uppercase last:mr-0 mr-1 hover:opacity-75 hover:shadow-none"> {{ .LinkTitle | upper }} </a> {{ end }} diff --git a/layouts/partials/helpers/funcs/color-from-string.html b/layouts/partials/helpers/funcs/color-from-string.html index 5060812..322fffd 100644 --- a/layouts/partials/helpers/funcs/color-from-string.html +++ b/layouts/partials/helpers/funcs/color-from-string.html @@ -1,5 +1,15 @@ {{ $colors := slice "orange" "blue" "green" "steel" "hotpink" }} +{{ $shades := slice 100 200 300 400 500 600 700 800 900 }} {{ $hash := (crypto.FNV32a .) }} {{ $i := mod $hash (len $colors) }} +{{ $j := mod $hash (len $shades) }} {{ $color := index $colors $i }} -{{ return $color }} +{{ $shade1 := index $shades $j }} +{{ $shade2 := 0 }} +{{ if ge $shade1 500 }} + {{ $shade2 = sub $shade1 400 }} +{{ else }} + {{ $shade2 = add $shade1 400 }} +{{ end }} +{{ $res := dict "color" $color "shade1" $shade1 "shade2" $shade2 }} +{{ return $res }} |