Skip to content

Commit a32410b

Browse files
committed
feat: document list building block
1 parent 3b57408 commit a32410b

File tree

7 files changed

+196
-59
lines changed

7 files changed

+196
-59
lines changed

config/postcss.config.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@ const purgecss = purgeCSSPlugin({
2929
'./_vendor/github.com/gethinode/hinode/assets/scss/components/_table.scss',
3030
'./_vendor/github.com/gethinode/hinode/assets/scss/components/_video.scss',
3131
'./_vendor/github.com/gethinode/hinode/assets/scss/theme/fonts.scss',
32+
'./_vendor/github.com/gethinode/hinode/component-library/components/list/list.scss',
3233
'./_vendor/github.com/gethinode/mod-cookieyes/v2/assets/scss/cookieyes.scss',
3334
'./_vendor/github.com/gethinode/mod-flexsearch/v3/assets/scss/modules/flexsearch/flexsearch.scss',
3435
'./_vendor/github.com/gethinode/mod-katex/dist/katex.scss',
Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
---
2+
_schema: default
3+
title: List
4+
description: Use the list content block to show a list of articles.
5+
icon: fas list
6+
modules: ["simple-datatables"]
7+
---
8+
9+
## Overview
10+
11+
The `list` content block renders a list of articles. Add the following configuration to your page's frontmatter to enable data table features:
12+
13+
```yml
14+
---
15+
modules: ["simple-datatables"]
16+
---
17+
```
18+
19+
<!-- markdownlint-disable MD037 -->
20+
{{< example-bookshop lang="bookshop" >}}
21+
22+
```yml
23+
- _bookshop_name: list
24+
heading:
25+
title: Available Content Blocks
26+
align: start
27+
input:
28+
section: content-blocks
29+
reverse: false
30+
sort: title
31+
hide-empty: false
32+
background:
33+
color: primary
34+
subtle: true
35+
justify: start
36+
sortable: true
37+
paginate: true
38+
searchable: true
39+
```
40+
41+
{{< /example-bookshop >}}
42+
<!-- markdownlint-enable MD037 -->
43+
44+
## Arguments
45+
46+
The content block supports the following arguments:
47+
48+
{{< args bookshop-list >}}

content/en/docs/latest/content/tables.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -271,11 +271,11 @@ modules: ["simple-datatables"]
271271
---
272272
```
273273

274-
As an example, the following shortcode displays a responsive table that is `searchable`, is `sortable`, and enables `paging` with a page size (`pagingOptionPerPage`) of 5.
274+
As an example, the following shortcode displays a responsive table that is `searchable`, is `sortable`, and enables paging (`paginate`) with a page size (`pagination`) of 5.
275275

276276
<!-- markdownlint-disable MD037 MD058 -->
277277
{{< example lang="markdown" >}}
278-
{{</* table sortable="true" paging="true" searchable="true" pagingOptionPerPage=5 */>}}
278+
{{</* table sortable="true" paginate="true" searchable="true" pagination=5 */>}}
279279
| # | Heading |
280280
|-----|---------|
281281
| 1. | Item 1 |

data/docs.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,7 @@
5555
- title: CTA
5656
- title: FAQ
5757
- title: Hero
58+
- title: List
5859
- title: Panels
5960
- title: Releases
6061
- title: Separator

go.mod

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ go 1.20
55
require (
66
github.com/airbnb/lottie-web v5.13.0+incompatible // indirect
77
github.com/cloudcannon/bookshop/hugo/v3 v3.16.5 // indirect
8-
github.com/gethinode/hinode v1.22.1 // indirect
8+
github.com/gethinode/hinode v1.23.3 // indirect
99
github.com/gethinode/mod-bootstrap v1.3.4 // indirect
1010
github.com/gethinode/mod-cookieyes/v2 v2.2.5 // indirect
1111
github.com/gethinode/mod-csp v1.0.8 // indirect
@@ -14,14 +14,14 @@ require (
1414
github.com/gethinode/mod-google-analytics v1.3.3 // indirect
1515
github.com/gethinode/mod-katex v1.1.4 // indirect
1616
github.com/gethinode/mod-leaflet v1.3.1 // indirect
17-
github.com/gethinode/mod-lottie v1.6.1 // indirect
17+
github.com/gethinode/mod-lottie v1.6.3 // indirect
1818
github.com/gethinode/mod-mermaid v1.1.23 // indirect
1919
github.com/gethinode/mod-mermaid/v2 v2.0.3 // indirect
2020
github.com/gethinode/mod-mermaid/v3 v3.0.1 // indirect
2121
github.com/gethinode/mod-simple-datatables v1.1.7 // indirect
2222
github.com/gethinode/mod-simple-datatables/v2 v2.0.2 // indirect
2323
github.com/gethinode/mod-utils/v3 v3.3.1 // indirect
24-
github.com/gethinode/mod-utils/v4 v4.20.0 // indirect
24+
github.com/gethinode/mod-utils/v4 v4.21.1 // indirect
2525
github.com/nextapps-de/flexsearch v0.0.0-20250907103239-defb38b083f0 // indirect
2626
github.com/twbs/bootstrap v5.3.8+incompatible // indirect
2727
)

go.sum

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -400,6 +400,12 @@ github.com/gethinode/hinode v1.19.7 h1:Nj9Zn6Akwt8Tl6dLj10NtES6te1jRvJj/S/SxYWLY
400400
github.com/gethinode/hinode v1.19.7/go.mod h1:qm9X5FuEoIYstw6PwE9X97tM7Pm/mtajJ375wbC6ZK4=
401401
github.com/gethinode/hinode v1.22.1 h1:9Aa8DGJHRd4JW3VkWpTlCVTPxKGkPHgFq4P+WSPPNgg=
402402
github.com/gethinode/hinode v1.22.1/go.mod h1:vIrbzvvZKKR+zT0d3QUGf3wQJ7Zf2Z0Yuq03XH9rbxg=
403+
github.com/gethinode/hinode v1.23.0 h1:J5o0TCXuH1KRxB+Vk1RXm3vGRQmwjHMyOE1FH06q/P0=
404+
github.com/gethinode/hinode v1.23.0/go.mod h1:6tluB3VRlr+x5wei1MV2wR1Vcm+LiEyLwVj4z5rCjQM=
405+
github.com/gethinode/hinode v1.23.1 h1:9kmS/TTK9QXf3TV0vGq+wDGFvKKNiDylCA6J5cQRopc=
406+
github.com/gethinode/hinode v1.23.1/go.mod h1:6tluB3VRlr+x5wei1MV2wR1Vcm+LiEyLwVj4z5rCjQM=
407+
github.com/gethinode/hinode v1.23.3 h1:nvA6SCz3L1DiL1p9ZszvjdDYYd8C5SlXtGa8U627Mj8=
408+
github.com/gethinode/hinode v1.23.3/go.mod h1:6tluB3VRlr+x5wei1MV2wR1Vcm+LiEyLwVj4z5rCjQM=
403409
github.com/gethinode/mod-bootstrap v1.1.0 h1:BbalsW8kmFhv+J+dcc41TGcjIlM/p69AB0h0oGhAXIU=
404410
github.com/gethinode/mod-bootstrap v1.1.0/go.mod h1:DcpPc2cNaXUPGEvhD7npuEEPA7573NvakTlrwFbyjr8=
405411
github.com/gethinode/mod-bootstrap v1.1.1 h1:Tx4M5hGVOFrEaxnUONDAm6N9xuRi5UphKlT7F26HujU=
@@ -684,6 +690,8 @@ github.com/gethinode/mod-lottie v1.6.0 h1:O0ld9Q1rBWKb9HzuCuGPBfCegUcIqczMGNW2O/
684690
github.com/gethinode/mod-lottie v1.6.0/go.mod h1:jZy8EJ6ldLnOXhpzayJ2STZ4hzykqkguFHWpN4aHxMo=
685691
github.com/gethinode/mod-lottie v1.6.1 h1:0wkQ7yMiwFvkhzsBoO/RhfKJ7ru2EzoQfYrwnC6qoxg=
686692
github.com/gethinode/mod-lottie v1.6.1/go.mod h1:Buaa3A4fBIE4mkyQhnjMlassQQ5j8gRxQ4QnN7I1oGc=
693+
github.com/gethinode/mod-lottie v1.6.3 h1:oc6ts13A3F8mo0WcW7QlelwhVkOLD/GGybOjsyyLPOM=
694+
github.com/gethinode/mod-lottie v1.6.3/go.mod h1:63uyMY7jhFXDjqIePAnJZPR2QN9+3eb3E9fku3CJVng=
687695
github.com/gethinode/mod-mermaid v1.1.23 h1:DA5iIdopb7f3wC+bfZ7J5HhcRUuVI/2j1+W/j5L/wwQ=
688696
github.com/gethinode/mod-mermaid v1.1.23/go.mod h1:rw6vrY9DpdJblwFwLuXCdy2kBHxMf6gGKWeetwfTSfc=
689697
github.com/gethinode/mod-mermaid/v2 v2.0.1 h1:QcahIFCgmYAGsukQ0d+/L4IJtDwgXgv0WzilZ9poI9o=
@@ -827,6 +835,8 @@ github.com/gethinode/mod-utils/v4 v4.18.0 h1:CLxuPCbsQBGVgAM1x5nmh6V0HJoOcltIfKG
827835
github.com/gethinode/mod-utils/v4 v4.18.0/go.mod h1:bYmvRdAo4ICy5MpSGafDvO4p5bTDpsDKFCPL3bH0mN4=
828836
github.com/gethinode/mod-utils/v4 v4.20.0 h1:hGhx0qOzrIvOYrn8ozgo1X9tO/I2F8S2+6yyXK4Oj4c=
829837
github.com/gethinode/mod-utils/v4 v4.20.0/go.mod h1:bYmvRdAo4ICy5MpSGafDvO4p5bTDpsDKFCPL3bH0mN4=
838+
github.com/gethinode/mod-utils/v4 v4.21.1 h1:+YAAwD3yiVBO2ozajKgbxh4IKYhBJUHhKyIfBMz7x5A=
839+
github.com/gethinode/mod-utils/v4 v4.21.1/go.mod h1:bYmvRdAo4ICy5MpSGafDvO4p5bTDpsDKFCPL3bH0mN4=
830840
github.com/nextapps-de/flexsearch v0.0.0-20230711092928-1243fd883ec3 h1:H/qVR5O4BXjRjD+5PZB+r4ug2BSJ2Of4RtwOntd+OKo=
831841
github.com/nextapps-de/flexsearch v0.0.0-20230711092928-1243fd883ec3/go.mod h1:5GdMfPAXzbA2gXBqTjC6l27kioSYzHlqDMh0+wyx7sU=
832842
github.com/nextapps-de/flexsearch v0.0.0-20240108021025-afd75f742f22 h1:re7L8FxbXQpnX8BgzkdUnDpsUmloGNyLmiy2ZCln8pg=

0 commit comments

Comments
 (0)