Skip to content

Commit

Permalink
Merge pull request #561 from gethinode/develop
Browse files Browse the repository at this point in the history
Develop
  • Loading branch information
markdumay authored Dec 13, 2024
2 parents 81e9040 + b6f5054 commit 86cb927
Show file tree
Hide file tree
Showing 69 changed files with 599 additions and 581 deletions.
1 change: 1 addition & 0 deletions config/_default/params.toml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
tab = true
[main.build]
transpiler = "dartsass"
silenceDeprecations = true

[debugging]
showJS = false
Expand Down
2 changes: 1 addition & 1 deletion content/en/cookies.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ description: Cookie policy of gethinode.com
date: 2024-09-19
layout: docs
---
<!-- markdownlint-disable MD036 -->
{{% comment %}}<!-- markdownlint-disable MD036 -->{{% /comment %}}
*Effective Date 19-Sep-2024*

## What are cookies?
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -178,7 +178,7 @@ The workflow requires two secrets within your repository. Add them as `action se

Hugo modules have several constraints to work properly. The below overview provides some common challenges and how to overcome them.

<!-- markdownlint-disable MD037 -->
{{% comment %}}<!-- markdownlint-disable MD037 -->{{% /comment %}}
{{< accordion class="accordion-theme accordion-flush" >}}
{{< accordion-item header="The required distribution files are unavailable" >}}
Hugo modules use the latest available release on GitHub, or the most recent HEAD of the default branch otherwise. However, not all repositories maintain their distribution files as part of version control or their GitHub release assets. One such example is the {{</* link leaflet >}}Leaflet library{{< /link */>}}. The repository does not include the compiled JavaScript, but only its source files. As a workaround, the {{</* link repository_mod_leaflet >}}Leaflet module{{< /link */>}} downloads the npm package instead and copies the required files in a `postinstall` script.
Expand All @@ -202,4 +202,4 @@ Hugo modules have several constraints to work properly. The below overview provi
You might have an issue with your Hugo module cache. Certain operating systems such as macOS have a volatile cache system, that is modified when your machine has restarted or was recently suspended. Try running `hugo mod clean` to clear the Hugo module cache and then rerun `hugo mod get -u`.
{{< /accordion-item >}}
{{< /accordion >}}
<!-- markdownlint-enable MD037 -->
{{% comment %}}<!-- markdownlint-enable MD037 -->{{% /comment %}}
Original file line number Diff line number Diff line change
Expand Up @@ -58,13 +58,13 @@ Most shortcodes support multiple arguments to configure their behavior and to re

Let's consider the following example. The {{< link "docs/components/toast" />}} shortcode displays a dismissable message in the bottom-right corner of the screen. We can trigger it by assigning its unique identifier to a button.

<!-- markdownlint-disable MD037 -->
{{% comment %}}<!-- markdownlint-disable MD037 -->{{% /comment %}}
{{< example lang="hugo" >}}
{{</* button toast="toast-example-1" */>}}Show toast{{</* /button */>}}

{{</* toast id="toast-example-1" header="First title" */>}}This is a toast message{{</* /toast */>}}
{{< /example >}}
<!-- markdownlint-enable MD037 -->
{{% comment %}}<!-- markdownlint-enable MD037 -->{{% /comment %}}

The toast shortcode displays the message `This is a toast message` provided as inner input. Additionally, it supports the following arguments:

Expand Down
4 changes: 2 additions & 2 deletions content/en/docs/latest/advanced-settings/scripts.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ Hinodes bundles JavaScript files to optimize the page loading speed. By utilizin

Hinodes recognizes three types of integrations for JavaScript files. You can mount these files directly into Hugo's virtual file system, or use modules instead.

<!-- markdownlint-disable MD037 -->
{{% comment %}}<!-- markdownlint-disable MD037 -->{{% /comment %}}
{{< accordion class="accordion-theme accordion-flush" >}}
{{< accordion-item header="Critical" >}}
Critical scripts are loaded immediately as part of the page header. The included scripts are considered vital for the initial page to render correctly and are blocking. For example, Hinode includes a script to toggle the site's [color mode]({{% relref "color-modes" %}}). It should be loaded before the page is being displayed to reduce screen flickering.
Expand All @@ -26,7 +26,7 @@ Hinodes recognizes three types of integrations for JavaScript files. You can mou
Optional scripts are only included on the pages that require them. An example is the {{</* link leaflet >}}Leaflet{{< /link */>}} module, that renders an interactive map. Optional scripts are lazily loaded similarly to core scripts, unless specified otherwise.
{{< /accordion-item >}}
{{< /accordion >}}
<!-- markdownlint-enable MD037 -->
{{% comment %}}<!-- markdownlint-enable MD037 -->{{% /comment %}}

## Available script categories

Expand Down
4 changes: 2 additions & 2 deletions content/en/docs/latest/advanced-settings/styles.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ Hinode uses Sass files to take advantage of variables, maps, and functions to ge
Hinodes uses Hugo modules and mounted folders to create a flexible virtual file system that is automatically kept up to date. Review the [overview]({{% ref "overview" %}}) for a detailed explanation. The build pipeline of the stylesheet consists of six steps.

<!-- markdownlint-disable MD037 -->
{{% comment %}}<!-- markdownlint-disable MD037 -->{{% /comment %}}
{{< nav type="tabs" id="tabs-1" >}}
{{< nav-item header="libsass" show="true" >}}

Expand Down Expand Up @@ -77,7 +77,7 @@ Hinodes uses Hugo modules and mounted folders to create a flexible virtual file

{{< /nav-item >}}
{{< /nav >}}
<!-- markdownlint-enable MD037 -->
{{% comment %}}<!-- markdownlint-enable MD037 -->{{% /comment %}}

## Example

Expand Down
4 changes: 2 additions & 2 deletions content/en/docs/latest/components/abbr.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,12 @@ tags: component

Use the abbr shortcode to show the long form of an abbrevitation on hover. The abbreviation data is retrieved from a central data file. By default, the shortcode uses "data/abbr.yaml" with translation support.

<!-- markdownlint-disable MD037 -->
{{% comment %}}<!-- markdownlint-disable MD037 -->{{% /comment %}}
{{< example lang="hugo" >}}
{{</* abbr HTML */>}}
{{</* abbr key="html" class="initialism" */>}}
{{< /example >}}
<!-- markdownlint-enable MD037 -->
{{% comment %}}<!-- markdownlint-enable MD037 -->{{% /comment %}}

## Arguments

Expand Down
12 changes: 6 additions & 6 deletions content/en/docs/latest/components/accordion.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ tags: component

Use the `accordion` shortcode to show a group of vertically collapsing and expanding items. Add `accordion-item` inner elements for each accordion item.

<!-- markdownlint-disable MD037 -->
{{% comment %}}<!-- markdownlint-disable MD037 -->{{% /comment %}}
{{< example lang="hugo" >}}
{{</* accordion id="accordion-default" */>}}
{{</* accordion-item header="Accordion Item #1" show="true" */>}}
Expand All @@ -27,7 +27,7 @@ Use the `accordion` shortcode to show a group of vertically collapsing and expan
{{</* /accordion-item */>}}
{{</* /accordion */>}}
{{< /example >}}
<!-- markdownlint-enable MD037 -->
{{% comment %}}<!-- markdownlint-enable MD037 -->{{% /comment %}}

## Arguments

Expand All @@ -47,7 +47,7 @@ Change the style of your accordion with class attributes and arguments.

Add `.accordion-flush` to remove some borders and rounded corners to render accordions edge-to-edge with their parent container.

<!-- markdownlint-disable MD037 -->
{{% comment %}}<!-- markdownlint-disable MD037 -->{{% /comment %}}
{{< example lang="hugo" >}}
{{</* accordion id="accordion-flush" class="accordion-flush" */>}}
{{</* accordion-item header="Accordion Item #1" */>}}
Expand All @@ -62,13 +62,13 @@ Add `.accordion-flush` to remove some borders and rounded corners to render acco
{{</* /accordion-item */>}}
{{</* /accordion */>}}
{{< /example >}}
<!-- markdownlint-enable MD037 -->
{{% comment %}}<!-- markdownlint-enable MD037 -->{{% /comment %}}

### Always open

Set `always-open` to `true` to make accordion items stay open when another item is opened.

<!-- markdownlint-disable MD037 -->
{{% comment %}}<!-- markdownlint-disable MD037 -->{{% /comment %}}
{{< example lang="hugo" >}}
{{</* accordion id="accordion-always-open" always-open="true" */>}}
{{</* accordion-item header="Accordion Item #1" */>}}
Expand All @@ -83,4 +83,4 @@ Set `always-open` to `true` to make accordion items stay open when another item
{{</* /accordion-item */>}}
{{</* /accordion */>}}
{{< /example >}}
<!-- markdownlint-enable MD037 -->
{{% comment %}}<!-- markdownlint-enable MD037 -->{{% /comment %}}
24 changes: 12 additions & 12 deletions content/en/docs/latest/components/alert.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,13 @@ tags: component

Use the `alert` shortcode to display a contextual feedback message. The inner content is used as alert text.

<!-- markdownlint-disable MD037 -->
{{% comment %}}<!-- markdownlint-disable MD037 -->{{% /comment %}}
{{< example lang="hugo" >}}
{{</* alert color="danger" */>}}
A simple danger alert—check it out!
{{</* /alert */>}}
{{< /example >}}
<!-- markdownlint-enable MD037 -->
{{% comment %}}<!-- markdownlint-enable MD037 -->{{% /comment %}}

## Arguments

Expand All @@ -34,7 +34,7 @@ Change the style of your accordion with arguments.

As an example, the following shortcodes displays a simple alert for each theme color.

<!-- markdownlint-disable MD037 -->
{{% comment %}}<!-- markdownlint-disable MD037 -->{{% /comment %}}
{{< example lang="hugo" >}}
{{</* alert color="primary" */>}}
A simple primary alert—check it out!
Expand Down Expand Up @@ -68,37 +68,37 @@ As an example, the following shortcodes displays a simple alert for each theme c
A simple dark alert—check it out!
{{</* /alert */>}}
{{< /example >}}
<!-- markdownlint-enable MD037 -->
{{% comment %}}<!-- markdownlint-enable MD037 -->{{% /comment %}}

### Dismissible alert

As an example, the following shortcode displays a dismissible alert.

<!-- markdownlint-disable MD037 -->
{{% comment %}}<!-- markdownlint-disable MD037 -->{{% /comment %}}
{{< example lang="hugo" >}}
{{</* alert color="danger" dismissible="true" */>}}
A dismissible alert—check it out!
{{</* /alert */>}}
{{< /example >}}
<!-- markdownlint-enable MD037 -->
{{% comment %}}<!-- markdownlint-enable MD037 -->{{% /comment %}}

### Alert with icon

As an example, the following shortcode displays an alert with an icon. The icon is resized to size `2x` and pulled to the left by default.

<!-- markdownlint-disable MD037 -->
{{% comment %}}<!-- markdownlint-disable MD037 -->{{% /comment %}}
{{< example lang="hugo" >}}
{{</* alert color="danger" icon="fas triangle-exclamation" */>}}
An illustrated alert—check it out!
{{</* /alert */>}}
{{< /example >}}
<!-- markdownlint-enable MD037 -->
{{% comment %}}<!-- markdownlint-enable MD037 -->{{% /comment %}}

### Alert of specific type

As an example, the following shortcode displays an informative alert with an icon.

<!-- markdownlint-disable MD037 -->
{{% comment %}}<!-- markdownlint-disable MD037 -->{{% /comment %}}
{{< example lang="hugo" >}}
{{</* alert type="info" */>}}
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt
Expand All @@ -109,11 +109,11 @@ sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit
est laborum.
{{</* /alert */>}}
{{< /example >}}
<!-- markdownlint-enable MD037 -->
{{% comment %}}<!-- markdownlint-enable MD037 -->{{% /comment %}}

As an example, the following shortcode displays a warning with an icon.

<!-- markdownlint-disable MD037 -->
{{% comment %}}<!-- markdownlint-disable MD037 -->{{% /comment %}}
{{< example lang="hugo" >}}
{{</* alert type="danger" */>}}
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt
Expand All @@ -124,4 +124,4 @@ sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit
est laborum.
{{</* /alert */>}}
{{< /example >}}
<!-- markdownlint-enable MD037 -->
{{% comment %}}<!-- markdownlint-enable MD037 -->{{% /comment %}}
16 changes: 8 additions & 8 deletions content/en/docs/latest/components/animation.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,11 @@ modules: ["lottie"]

Use the animation shortcode to show an After Effects animation, powered by {{< link lottie >}}Lottie{{< /link >}}. The Lottie library supports animations that have been exported as JSON with Bodymovin. The animation uses vector graphics and is responsive. The shortcode is a simplified wrapper of the Lottie library that provides basic functionality. As an example, the following shortcode shows an animation that plays when hovering the mouse over it.

<!-- markdownlint-disable MD037 -->
{{% comment %}}<!-- markdownlint-disable MD037 -->{{% /comment %}}
{{< example lang="hugo" >}}
{{</* animation data="animation/gatin.json" auto=false hover=true class="col-6 mx-auto" */>}}
{{< /example >}}
<!-- markdownlint-enable MD037 -->
{{% comment %}}<!-- markdownlint-enable MD037 -->{{% /comment %}}

## Arguments

Expand All @@ -39,28 +39,28 @@ Change the behavior of your animation with shortcode arguments.

Assign a valid path to `data` to provide a JSON file that contains the animation as input. The file should be stored in the `static` folder, or in one of its subfolders.

<!-- markdownlint-disable MD037 -->
{{% comment %}}<!-- markdownlint-disable MD037 -->{{% /comment %}}
{{< example lang="hugo" >}}
{{</* animation data="animation/gatin.json" class="col-6 mx-auto" */>}}
{{< /example >}}
<!-- markdownlint-enable MD037 -->
{{% comment %}}<!-- markdownlint-enable MD037 -->{{% /comment %}}

### Animation on hover

Set `auto` to false and `hover` to true to trigger the animation when hovering the mouse over it.

<!-- markdownlint-disable MD037 -->
{{% comment %}}<!-- markdownlint-disable MD037 -->{{% /comment %}}
{{< example lang="hugo" >}}
{{</* animation data="animation/gatin.json" auto=false hover=true class="col-6 mx-auto" */>}}
{{< /example >}}
<!-- markdownlint-enable MD037 -->
{{% comment %}}<!-- markdownlint-enable MD037 -->{{% /comment %}}

### Identification

Assign a specific identified to the animation by setting the `id` argument. The following example assigns the id `gatin-animation` to the animation.

<!-- markdownlint-disable MD037 -->
{{% comment %}}<!-- markdownlint-disable MD037 -->{{% /comment %}}
{{< example lang="hugo" >}}
{{</* animation id="gatin-animation" data="animation/gatin.json" class="col-6 mx-auto" */>}}
{{< /example >}}
<!-- markdownlint-enable MD037 -->
{{% comment %}}<!-- markdownlint-enable MD037 -->{{% /comment %}}
12 changes: 6 additions & 6 deletions content/en/docs/latest/components/args.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,11 @@ tags: component

Use the args shortcode to generates a table of structured arguments. The argument definitions are expected to be defined in a data file identified by a provided structure name.

<!-- markdownlint-disable MD037 -->
{{% comment %}}<!-- markdownlint-disable MD037 -->{{% /comment %}}
{{< example lang="hugo" >}}
{{</* args "args" */>}}
{{< /example >}}
<!-- markdownlint-enable MD037 -->
{{% comment %}}<!-- markdownlint-enable MD037 -->{{% /comment %}}

## Arguments

Expand All @@ -28,14 +28,14 @@ The shortcode supports both unnamed and named arguments.

## Data format

<!-- TODO: add args data format -->
{{% comment %}}<!-- TODO: add args data format -->{{% /comment %}}
Define a file in the `data/structures` folder that contains the argument specifications.

### Supported attributes

The format supports the following attributes:

<!-- markdownlint-disable MD037 -->
{{% comment %}}<!-- markdownlint-disable MD037 MD058 -->{{% /comment %}}
| Name | Required | Description |
|-----------|----------|-------------|
| name | yes | Argument name. |
Expand All @@ -47,7 +47,7 @@ The format supports the following attributes:
| deprecated | | Points to the version in which the argument was deprecated. See the {{< link "release" />}} shortcode for more details. |
| comment | | Documentation about the argument. |
| options | | Conditional value requirements, pending data type. |
<!-- markdownlint-enable MD037 -->
{{% comment %}}<!-- markdownlint-enable MD037 MD058 -->{{% /comment %}}

### Supported primitive types

Expand All @@ -68,7 +68,7 @@ Several primitives are supported. The validation function uses these to test if

Any provided type not matching a primitive is considered a complex type. Type confirmation is tested with `printf "%T"`. For example, to validate if the page context is of the correct type, use `*hugolib.pageState`.

<!-- TODO: add example -->
{{% comment %}}<!-- TODO: add example -->{{% /comment %}}

### Example file

Expand Down
16 changes: 8 additions & 8 deletions content/en/docs/latest/components/badge.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,12 @@ tags: component

Badges can be added to headings and buttons. The badge for a button is part of a [custom shortcode]({{% ref "button" %}} "custom shortcode"). The example below illustrates the shortcode for a heading.

<!-- markdownlint-disable MD037 -->
{{% comment %}}<!-- markdownlint-disable MD037 -->{{% /comment %}}
{{< example >}}
Example heading of size four {{</* badge title="New" */>}}
{.h4}
{{< /example >}}
<!-- markdownlint-enable MD037 -->
{{% comment %}}<!-- markdownlint-enable MD037 -->{{% /comment %}}

## Arguments

Expand All @@ -35,7 +35,7 @@ Use the badge shortcode to display a badge for a heading. See the Bootstrap {{<

Badges scale to match the size of the immediate parent element by using relative font sizing and em units. Use Hugo's {{< link hugo_goldmark >}}curly brackets syntax{{< /link >}} to apply a heading class.

<!-- markdownlint-disable MD037 -->
{{% comment %}}<!-- markdownlint-disable MD037 -->{{% /comment %}}
{{< example >}}
Heading 1 {{</* badge title="New" */>}}
{.h1}
Expand All @@ -55,13 +55,13 @@ Heading 5 {{</* badge title="New" */>}}
Heading 6 {{</* badge title="New" */>}}
{.h6}
{{< /example >}}
<!-- markdownlint-enable MD037 -->
{{% comment %}}<!-- markdownlint-enable MD037 -->{{% /comment %}}

### Colored badges

Set a background color with contrasting foreground color with the `color` argument.

<!-- markdownlint-disable MD037 -->
{{% comment %}}<!-- markdownlint-disable MD037 -->{{% /comment %}}
{{< example >}}
{{</* badge title="primary" color="primary" */>}}
{{</* badge title="secondary" color="secondary" */>}}
Expand All @@ -72,13 +72,13 @@ Set a background color with contrasting foreground color with the `color` argume
{{</* badge title="light" color="light" */>}}
{{</* badge title="dark" color="dark" */>}}
{{< /example >}}
<!-- markdownlint-enable MD037 -->
{{% comment %}}<!-- markdownlint-enable MD037 -->{{% /comment %}}

### Pill badges

Use the `.rounded-pill` utility class to make badges more rounded with a larger `border-radius`.

<!-- markdownlint-disable MD037 -->
{{% comment %}}<!-- markdownlint-disable MD037 -->{{% /comment %}}
{{< example >}}
{{</* badge title="primary" color="primary" class="rounded-pill" */>}}
{{</* badge title="secondary" color="secondary" class="rounded-pill" */>}}
Expand All @@ -89,4 +89,4 @@ Use the `.rounded-pill` utility class to make badges more rounded with a larger
{{</* badge title="light" color="light" class="rounded-pill" */>}}
{{</* badge title="dark" color="dark" class="rounded-pill" */>}}
{{< /example >}}
<!-- markdownlint-enable MD037 -->
{{% comment %}}<!-- markdownlint-enable MD037 -->{{% /comment %}}
Loading

0 comments on commit 86cb927

Please sign in to comment.