mirror of
https://github.com/gethinode/hinode.git
synced 2025-10-15 14:03:19 +00:00
Compare commits
47 Commits
v0.22.0-be
...
v0.22.0-be
Author | SHA1 | Date | |
---|---|---|---|
![]() |
d27c04dc64 | ||
![]() |
b0c8326255 | ||
![]() |
99a35a3ffd | ||
![]() |
c5673efea2 | ||
![]() |
c3b48e0033 | ||
![]() |
5aa57dd402 | ||
![]() |
d919d3f068 | ||
![]() |
38ad418005 | ||
![]() |
ba50786118 | ||
![]() |
aee3cb3e03 | ||
![]() |
61430b07e2 | ||
![]() |
5d393598c5 | ||
![]() |
4b0c075b53 | ||
![]() |
2b5b6434da | ||
![]() |
ae0877037a | ||
![]() |
64a12da2e6 | ||
![]() |
6865fa40f7 | ||
![]() |
79632aeed0 | ||
![]() |
6f03f3e5fd | ||
![]() |
df53150972 | ||
![]() |
9282cd630d | ||
![]() |
a3eb2fc7cc | ||
![]() |
4e39d03240 | ||
![]() |
8cadb30179 | ||
![]() |
d2c02ca016 | ||
![]() |
1bbfba32a5 | ||
![]() |
cf59cc3a49 | ||
![]() |
897db61ee2 | ||
![]() |
ac14ac23fb | ||
![]() |
0f1bc34d37 | ||
![]() |
26d318356f | ||
![]() |
9f4a0d35b6 | ||
![]() |
a201be6487 | ||
![]() |
380ebcd1d8 | ||
![]() |
c06499033d | ||
![]() |
0874957993 | ||
![]() |
6019c7412f | ||
![]() |
30c300cabf | ||
![]() |
46f11f02ab | ||
![]() |
71e6029117 | ||
![]() |
5c67da7882 | ||
![]() |
af4f6de4b9 | ||
![]() |
9b173d6c68 | ||
![]() |
2f4fb5230d | ||
![]() |
9144a1fec3 | ||
![]() |
4192af1d46 | ||
![]() |
0e72124cdc |
@@ -21,6 +21,7 @@ const purgecss = require('@fullhuman/postcss-purgecss')({
|
||||
'./assets/scss/components/_syntax-dark.scss',
|
||||
'./assets/scss/components/_syntax-light.scss',
|
||||
'./assets/scss/components/_table.scss',
|
||||
'./assets/scss/components/_video.scss',
|
||||
'./assets/scss/theme/fonts.scss',
|
||||
'./assets/scss/theme/theme.scss',
|
||||
'./_vendor/github.com/gethinode/mod-flexsearch/assets/scss/modules/flexsearch/flexsearch.scss',
|
||||
|
@@ -6,7 +6,7 @@ arguments:
|
||||
type: string
|
||||
optional: true
|
||||
comment: >-
|
||||
ID of the accordion, defaults to “accordion-n” with a sequential number n.
|
||||
ID of the accordion, defaults to `accordion-n` with a sequential number n.
|
||||
always-open:
|
||||
type: bool
|
||||
optional: true
|
||||
@@ -15,4 +15,4 @@ arguments:
|
||||
class:
|
||||
type: string
|
||||
optional: true
|
||||
comment: Class attribute of the accordion, e.g. “w-50”.
|
||||
comment: Class attribute of the accordion, e.g. `w-50`.
|
||||
|
@@ -3,7 +3,7 @@ comment: >-
|
||||
arguments:
|
||||
title:
|
||||
type: string
|
||||
optional: true
|
||||
optional: false
|
||||
comment: >-
|
||||
Title of the badge.
|
||||
class:
|
||||
|
@@ -12,7 +12,7 @@ arguments:
|
||||
type: string
|
||||
optional: true
|
||||
comment: >-
|
||||
Class attribute of the button element, e.g. “p-5”.
|
||||
Class attribute of the button element, e.g. `p-5`.
|
||||
color:
|
||||
type: select
|
||||
optional: true
|
||||
@@ -48,7 +48,7 @@ arguments:
|
||||
id:
|
||||
type: string
|
||||
optional: true
|
||||
comment: ID of the button, to be used in the DOM.
|
||||
comment: Identifier of the button, to be used in the DOM.
|
||||
state:
|
||||
type: select
|
||||
optional: true
|
||||
@@ -61,7 +61,7 @@ arguments:
|
||||
- active
|
||||
- inactive
|
||||
size:
|
||||
type: string
|
||||
type: select
|
||||
optional: true
|
||||
default: md
|
||||
comment: Size of the button.
|
||||
@@ -85,7 +85,12 @@ arguments:
|
||||
comment: >-
|
||||
Assistive label for the button or badge. The label is applied
|
||||
to the badge instead of the button when a badge has been defined.
|
||||
The default value of the button aria-label is its title.
|
||||
The default value of the button's assistive label is its title.
|
||||
aria-label:
|
||||
type: string
|
||||
optional: true
|
||||
comment: Alias for label.
|
||||
group: shortcode
|
||||
tooltip:
|
||||
type: string
|
||||
optional: true
|
||||
@@ -108,7 +113,7 @@ arguments:
|
||||
- link
|
||||
- button
|
||||
placement:
|
||||
type: string
|
||||
type: select
|
||||
optional: true
|
||||
default: top
|
||||
comment: Position of the tooltip.
|
||||
@@ -134,7 +139,7 @@ arguments:
|
||||
- first
|
||||
- last
|
||||
justify:
|
||||
type: string
|
||||
type: select
|
||||
optional: true
|
||||
default: center
|
||||
comment: Justification of the button title and icon.
|
||||
@@ -149,7 +154,7 @@ arguments:
|
||||
toast:
|
||||
type: string
|
||||
optional: true
|
||||
comment: ID of the toast to display when the button is clicked.
|
||||
comment: Identifier (ID) of the toast to display when the button is clicked.
|
||||
clipboard:
|
||||
type:
|
||||
- string
|
||||
@@ -174,6 +179,7 @@ arguments:
|
||||
comment: >-
|
||||
Dictionary of key-value pairs added as custom attributes to the button
|
||||
element ('<a>').
|
||||
group: partial
|
||||
spacing:
|
||||
type: bool
|
||||
optional: true
|
||||
|
@@ -11,11 +11,11 @@ arguments:
|
||||
- '*hugolib.pageForShortcode'
|
||||
optional: true
|
||||
comment: Context of the current page.
|
||||
group: partial
|
||||
title:
|
||||
type: string
|
||||
optional: true
|
||||
comment: >-
|
||||
Title of the card, replaces the title of the referenced page (if any).
|
||||
comment: Title of the card group.
|
||||
gutter:
|
||||
type: int
|
||||
optional: true
|
||||
@@ -24,45 +24,58 @@ arguments:
|
||||
options:
|
||||
min: 0
|
||||
max: 5
|
||||
release: v0.19.0
|
||||
list:
|
||||
type:
|
||||
- page.Pages
|
||||
- resource.Resources
|
||||
optional: true
|
||||
comment: Array of pages to be rendered as cards.
|
||||
group: partial
|
||||
cards:
|
||||
type: string
|
||||
optional: true
|
||||
comment: String of rendered cards.
|
||||
group: partial
|
||||
max:
|
||||
type: int
|
||||
optional: true
|
||||
comment: Maximum number of cards to display.
|
||||
group: partial
|
||||
cols:
|
||||
type: int
|
||||
type: select
|
||||
optional: true
|
||||
default: 3
|
||||
default: "3"
|
||||
comment: Number of grid columns.
|
||||
options:
|
||||
min: 1
|
||||
max: 5
|
||||
values:
|
||||
- "1"
|
||||
- "2"
|
||||
- "3"
|
||||
- "4"
|
||||
- "5"
|
||||
- "auto"
|
||||
release: v0.19.0
|
||||
paginate:
|
||||
type: bool
|
||||
optional: true
|
||||
comment: >-
|
||||
Flag indicating if pagination should be added to the card group, if the
|
||||
list exceeds the maximum number of cards to display.
|
||||
group: partial
|
||||
href:
|
||||
type: string
|
||||
optional: true
|
||||
comment: >-
|
||||
address for the button or hyperlink. If set, a button is added if the
|
||||
Address for the button or hyperlink. If set, a button is added if the
|
||||
list exceeds the maximum number of cards to display.
|
||||
group: partial
|
||||
hrefTitle:
|
||||
type: string
|
||||
optional: true
|
||||
comment: >-
|
||||
Title of the button or hyperlink as companion to href.
|
||||
group: partial
|
||||
separator:
|
||||
type: bool
|
||||
optional: true
|
||||
|
@@ -108,15 +108,14 @@ arguments:
|
||||
- string
|
||||
- template.HTML
|
||||
optional: true
|
||||
parent: cascade
|
||||
comment: >-
|
||||
Description of the card.
|
||||
group: partial
|
||||
loading:
|
||||
type: select
|
||||
optional: true
|
||||
default: eager
|
||||
parent: cascade
|
||||
default: eager
|
||||
comment: >-
|
||||
Loading behavior of the image. The loading of lazily loaded images is
|
||||
deferred until the image is within scrolling range of the viewport. This
|
||||
@@ -130,7 +129,6 @@ arguments:
|
||||
thumbnail:
|
||||
type: path
|
||||
optional: true
|
||||
parent: cascade
|
||||
comment: >-
|
||||
Thumbnail image url, displayed on top or the left of the card.
|
||||
ratio:
|
||||
@@ -157,7 +155,6 @@ arguments:
|
||||
icon:
|
||||
type: string
|
||||
optional: true
|
||||
parent: cascade
|
||||
comment: >-
|
||||
Font Awesome icon, displayed on top or the left of the card.
|
||||
orientation:
|
||||
|
@@ -24,6 +24,7 @@ arguments:
|
||||
- 4x3
|
||||
- 16x9
|
||||
- 21x9
|
||||
group: partial
|
||||
portrait:
|
||||
type: bool
|
||||
optional: true
|
||||
@@ -32,6 +33,7 @@ arguments:
|
||||
Flag to adjust the ratio from landscape to portrait. The image itself
|
||||
is not rotated, only the crop area is adjusted. Not applicable to vector
|
||||
graphics.
|
||||
group: partial
|
||||
loading:
|
||||
type: select
|
||||
default: eager
|
||||
|
@@ -1,14 +1,14 @@
|
||||
comment: >-
|
||||
Displays a carousel of several responsive images (see the image shortcode for
|
||||
more details). Add inner <img> elements to define individual image slides.
|
||||
more details). Add inner `img` elements to define individual image slides.
|
||||
arguments:
|
||||
id:
|
||||
type: string
|
||||
optional: true
|
||||
comment: >-
|
||||
ID of the carousel, defaults to `carousel-` with a sequential number.
|
||||
ID of the carousel, defaults to `carousel-n` with a sequential number `n`.
|
||||
ratio:
|
||||
type: string
|
||||
type: select
|
||||
optional: true
|
||||
comment: >-
|
||||
Ratio of the images. If set, the images are resized and cropped to match the
|
||||
@@ -28,11 +28,12 @@ arguments:
|
||||
Flag to adjust the ratio from landscape to portrait. The images themselves
|
||||
are not rotated, only the crop area is adjusted. Not applicable to vector
|
||||
graphics.
|
||||
release: v0.18.3
|
||||
class:
|
||||
type: string
|
||||
optional: true
|
||||
comment: Class attribute of the carousel element, e.g. “w-75”.
|
||||
comment: Class attribute of the carousel element, e.g. `w-75`.
|
||||
body:
|
||||
type: string
|
||||
optional: false
|
||||
comment: Inner <img> elements that define the individual image slides.
|
||||
comment: Inner `img` elements that define the individual image slides.
|
@@ -18,7 +18,7 @@ arguments:
|
||||
type: select
|
||||
optional: true
|
||||
default: bash
|
||||
comment: Type of shell
|
||||
comment: Type of shell.
|
||||
options:
|
||||
values:
|
||||
- bash
|
||||
|
@@ -30,11 +30,15 @@ arguments:
|
||||
optional: true
|
||||
default: true
|
||||
comment: >-
|
||||
If unset, shows the filename only. By default, the full relative path is
|
||||
shown.
|
||||
If unset, shows the filename only. By default, the entire path (relative
|
||||
to the base path) is shown.
|
||||
id:
|
||||
type: string
|
||||
optional: true
|
||||
comment: >-
|
||||
ID of the collapse panel holding the code snippet, defaults to
|
||||
`docs-collapse-n` with a sequential number `n` starting at `1`.
|
||||
class:
|
||||
type: string
|
||||
optional: true
|
||||
comment: Class attribute of the tab control that wraps the docs element.
|
||||
|
@@ -2,11 +2,17 @@ comment: >-
|
||||
Display a code example and render a preview of the same input. The shortcode
|
||||
accepts the languages supported by Hugo's highlight function.
|
||||
arguments:
|
||||
id:
|
||||
type: string
|
||||
optional: true
|
||||
comment: Identifier of the element’s container.
|
||||
lang:
|
||||
type: string
|
||||
optional: true
|
||||
default: markdown
|
||||
comment: Language used to display the code.
|
||||
comment: >-
|
||||
Language used to display the code. Use `hugo` to process Hugo (escaped)
|
||||
shortcodes.
|
||||
show_markup:
|
||||
type: bool
|
||||
optional: true
|
||||
|
@@ -21,19 +21,20 @@ arguments:
|
||||
comment: >-
|
||||
If unset, shows the panel with the code in collapsed state. By default,
|
||||
the panel is expanded.
|
||||
full:
|
||||
type: string
|
||||
full:
|
||||
type: bool
|
||||
optional: true
|
||||
default: true
|
||||
comment: >-
|
||||
If unset, shows the filename only. By default, the full relative path is
|
||||
shown.
|
||||
If unset, shows the filename only. By default, the entire path (relative
|
||||
to the base path) is shown.
|
||||
id:
|
||||
type: string
|
||||
optional: true
|
||||
comment: >-
|
||||
ID of the collapse panel, defaults to `file-collapse-n` with a sequential
|
||||
number `n` starting at 1.
|
||||
Identifier of the collapse panel, defaults to `file-collapse-n` with a
|
||||
sequential number `n` starting at 1.
|
||||
class:
|
||||
type: string
|
||||
optional: true
|
||||
comment: Class argument of the tab control.
|
||||
comment: Class attribute of the tab control that wraps the file element.
|
||||
|
@@ -21,7 +21,10 @@ arguments:
|
||||
url:
|
||||
type: string
|
||||
optional: true
|
||||
comment: Path or url of the image, e.g. `img/example.jpg`.
|
||||
comment: >-
|
||||
Path or url of the image, e.g. `img/example.jpg`. Images with multiple
|
||||
color modes are expected to have a basename that ends with either `-dark`
|
||||
or `-light`.
|
||||
src:
|
||||
type: string
|
||||
optional: true
|
||||
@@ -39,9 +42,12 @@ arguments:
|
||||
type: bool
|
||||
default: false
|
||||
optional: true
|
||||
comment: Flag indicating if the image should support color modes.
|
||||
comment: >-
|
||||
Flag indicating if the image should support color modes. If set, the
|
||||
shortcode searches for images that having a matching color-mode suffix
|
||||
such as `-light` or `-dark`.
|
||||
ratio:
|
||||
type: string
|
||||
type: select
|
||||
optional: true
|
||||
comment: >-
|
||||
Ratio of the image. If set, the image is resized and cropped to match the
|
||||
@@ -62,6 +68,7 @@ arguments:
|
||||
Flag to adjust the ratio from landscape to portrait. The image itself is
|
||||
not rotated, only the crop area is adjusted. Not applicable to vector
|
||||
graphics.
|
||||
release: v0.18.3
|
||||
loading:
|
||||
type: select
|
||||
default: eager
|
||||
@@ -75,6 +82,7 @@ arguments:
|
||||
values:
|
||||
- eager
|
||||
- lazy
|
||||
release: v0.21.0
|
||||
priority:
|
||||
type: select
|
||||
default: auto
|
||||
@@ -102,6 +110,7 @@ arguments:
|
||||
type: string
|
||||
optional: true
|
||||
comment: Class attributes of the wrapper element, e.g. `mx-auto`.
|
||||
release: v0.18.3
|
||||
class:
|
||||
type: string
|
||||
optional: true
|
||||
|
@@ -25,8 +25,8 @@ arguments:
|
||||
position: 0
|
||||
optional: true
|
||||
comment: >-
|
||||
Reference to either an external link (if it starts with http), a named
|
||||
link (if it can be found in params.links), or internal reference.
|
||||
Reference to either an external link (if it starts with `http`), a named
|
||||
link (if it can be found in `params.links`), or internal reference.
|
||||
Both external and internal references may include an anchor `#`.
|
||||
name:
|
||||
type: string
|
||||
|
@@ -9,7 +9,7 @@ arguments:
|
||||
optional: true
|
||||
comment: >-
|
||||
Theme color of the highlight. By default, the highlight uses the color of
|
||||
the HTML mark function.
|
||||
the HTML mark function (usually yellow).
|
||||
options:
|
||||
values:
|
||||
- primary
|
||||
|
@@ -1,25 +1,25 @@
|
||||
comment: >-
|
||||
Defines an individual nav item.
|
||||
Defines an individual item.
|
||||
arguments:
|
||||
id:
|
||||
type: string
|
||||
optional: true
|
||||
comment: ID of the nav-item.
|
||||
parent: cascade
|
||||
comment: Identification of the item.
|
||||
group: partial
|
||||
parentID:
|
||||
type: string
|
||||
optional: false
|
||||
comment: ID of the parent (e.g. nav control).
|
||||
comment: Identification of the parent (e.g. nav control).
|
||||
group: partial
|
||||
header:
|
||||
type: string
|
||||
optional: false
|
||||
comment: Header of the nav item.
|
||||
comment: Header of the item.
|
||||
show:
|
||||
type: bool
|
||||
optional: true
|
||||
comment: >-
|
||||
Flag to indicate the nav item should be shown. Only one can be shown at a
|
||||
Flag to indicate if the item should be shown. Only one can be shown at a
|
||||
time.
|
||||
disabled:
|
||||
type: bool
|
||||
@@ -33,13 +33,13 @@ arguments:
|
||||
class:
|
||||
type: string
|
||||
optional: true
|
||||
comment: Class attribute of the nav item.
|
||||
comment: Class attribute of the item.
|
||||
body:
|
||||
type:
|
||||
- string
|
||||
- template.HTML
|
||||
optional: true
|
||||
comment: The body content of the nav-item, supports Markdown and HTML (if enabled).
|
||||
comment: The body content of the item, supports Markdown and HTML (if enabled).
|
||||
group: partial
|
||||
item_type:
|
||||
type: select
|
||||
@@ -52,5 +52,5 @@ arguments:
|
||||
group: partial
|
||||
body:
|
||||
optional: false
|
||||
comment: Content of the nav item.
|
||||
comment: Content of the item.
|
||||
group: shortcode
|
||||
|
@@ -44,7 +44,7 @@ arguments:
|
||||
class:
|
||||
type: string
|
||||
optional: true
|
||||
comment: Class attribute of the tab group, e.g. “nav-fill”.
|
||||
comment: Class attribute of the tab group, e.g. `nav-fill`.
|
||||
pane:
|
||||
type: select
|
||||
optional: true
|
||||
@@ -58,12 +58,12 @@ arguments:
|
||||
width:
|
||||
type: select
|
||||
optional: true
|
||||
default: 100
|
||||
default: "100"
|
||||
comment: Responsive width of the tab group.
|
||||
options:
|
||||
values:
|
||||
- 50
|
||||
- 100
|
||||
- "50"
|
||||
- "100"
|
||||
group: partial
|
||||
loading:
|
||||
type: select
|
||||
|
@@ -28,7 +28,12 @@ arguments:
|
||||
color:
|
||||
type: select
|
||||
optional: true
|
||||
comment: Background theme color of the navbar.
|
||||
comment: >-
|
||||
Background theme color of the navbar. Set the color to `body` or
|
||||
`body-tertiary` for the navbar to respond to color mode changes (e.g.
|
||||
switching between dark and light). The navigation bar is transparent when
|
||||
no color is set, but is set to the body color when scrolling to enhance
|
||||
the contrast.
|
||||
options:
|
||||
values:
|
||||
- primary
|
||||
@@ -47,9 +52,9 @@ arguments:
|
||||
type: string
|
||||
optional: true
|
||||
comment: >-
|
||||
ID of the navbar, defaults to `navbar-0`. The id is used by several child
|
||||
elements, including a color mode switcher, version switcher, and collapse
|
||||
panel.
|
||||
Identification of the navbar, defaults to `navbar-0`. The id is used by
|
||||
several child elements, including a color mode switcher, version switcher,
|
||||
and collapse panel.
|
||||
menus:
|
||||
type: string
|
||||
optional: true
|
||||
@@ -76,6 +81,7 @@ arguments:
|
||||
values:
|
||||
- light
|
||||
- dark
|
||||
group: partial
|
||||
mode:
|
||||
type: bool
|
||||
optional: true
|
||||
|
@@ -23,7 +23,7 @@ arguments:
|
||||
type: select
|
||||
optional: true
|
||||
default: md
|
||||
comment: Size of the button
|
||||
comment: Size of the button.
|
||||
options:
|
||||
values:
|
||||
- sm
|
||||
@@ -36,4 +36,5 @@ arguments:
|
||||
inline:
|
||||
type: bool
|
||||
optional: true
|
||||
comment: Flag to render the release button inline (defaults to false).
|
||||
default: false
|
||||
comment: Flag to render the release button inline.
|
||||
|
@@ -6,7 +6,7 @@ arguments:
|
||||
type: string
|
||||
optional: true
|
||||
comment: >-
|
||||
Class attribute of the wrapping element, e.g. “text-center”.
|
||||
Class attribute of the wrapping element, e.g. `text-center`.
|
||||
color:
|
||||
type: select
|
||||
optional: true
|
||||
|
@@ -5,4 +5,4 @@ arguments:
|
||||
type: string
|
||||
optional: false
|
||||
position: 0
|
||||
comment: Text to display in subscript.
|
||||
comment: Text to display in subscript. You can omit the argument name.
|
||||
|
@@ -5,4 +5,4 @@ arguments:
|
||||
type: string
|
||||
optional: false
|
||||
position: 0
|
||||
comment: Text to display in superscript.
|
||||
comment: Text to display in superscript. You can omit the argument name.
|
||||
|
@@ -18,7 +18,7 @@ arguments:
|
||||
type: string
|
||||
optional: false
|
||||
position: 0
|
||||
comment: ID of the video to be embedded.
|
||||
comment: Identifier of the video to be embedded.
|
||||
autoplay:
|
||||
type: bool
|
||||
optional: true
|
||||
|
@@ -21,6 +21,7 @@ const purgecss = require('@fullhuman/postcss-purgecss')({
|
||||
'./assets/scss/components/_syntax-dark.scss',
|
||||
'./assets/scss/components/_syntax-light.scss',
|
||||
'./assets/scss/components/_table.scss',
|
||||
'./assets/scss/components/_video.scss',
|
||||
'./assets/scss/theme/fonts.scss',
|
||||
'./assets/scss/theme/theme.scss',
|
||||
'./_vendor/github.com/gethinode/mod-flexsearch/assets/scss/modules/flexsearch/flexsearch.scss',
|
||||
|
@@ -39,14 +39,8 @@
|
||||
"sub",
|
||||
"sup",
|
||||
"svg",
|
||||
"table",
|
||||
"tbody",
|
||||
"td",
|
||||
"th",
|
||||
"thead",
|
||||
"time",
|
||||
"title",
|
||||
"tr",
|
||||
"ul",
|
||||
"use"
|
||||
],
|
||||
@@ -379,8 +373,6 @@
|
||||
"syntax-highlight",
|
||||
"tab-content",
|
||||
"tab-pane",
|
||||
"table",
|
||||
"table-responsive",
|
||||
"tag-link",
|
||||
"text-bg-body",
|
||||
"text-bg-body-tertiary",
|
||||
|
@@ -84,12 +84,13 @@
|
||||
{{- $params := (dict
|
||||
"class" (printf "h-100 %s" $class)
|
||||
"color" $color
|
||||
"padding" $padding
|
||||
"header" $header
|
||||
"footer" $footer
|
||||
"orientation" $orientation
|
||||
"ratio" $ratio
|
||||
"gutter" $gutter
|
||||
"header" $header
|
||||
"loading" $loading
|
||||
"orientation" $orientation
|
||||
"padding" $padding
|
||||
"ratio" $ratio
|
||||
) -}}
|
||||
{{- $params = merge $params $element }}
|
||||
|
||||
|
@@ -4,6 +4,8 @@
|
||||
Visit gethinode.com/license for more details.
|
||||
-->
|
||||
|
||||
<!-- TODO: consider to drop style arg -->
|
||||
|
||||
{{ $error := false }}
|
||||
|
||||
<!-- Validate arguments -->
|
||||
|
@@ -26,7 +26,7 @@
|
||||
{{- $content := .content -}}
|
||||
{{- $thumbnail := .thumbnail -}}
|
||||
|
||||
{{- $color := .color -}}
|
||||
{{- $color := .color | default "primary" -}}
|
||||
|
||||
{{- with $page -}}
|
||||
{{- if not $title }}{{ $title = .Title }}{{ end -}}
|
||||
|
@@ -32,7 +32,7 @@
|
||||
{{- $layout := "card" -}}
|
||||
{{- $pane := "none" -}}
|
||||
{{- $type := "pills" -}}
|
||||
{{- $vertical := "false" -}}
|
||||
{{- $vertical := false -}}
|
||||
{{- $width := 100 -}}
|
||||
{{- $ratio := "" -}}
|
||||
{{- $wrap := false -}}
|
||||
@@ -58,11 +58,11 @@
|
||||
{{- with index . "layout" }}{{ $layout = . }}{{ end -}}
|
||||
{{- with index . "pane" }}{{ $pane = . }}{{ end -}}
|
||||
{{- with index . "type" }}{{ $type = . }}{{ end -}}
|
||||
{{- with index . "vertical" }}{{ $vertical = . }}{{ end -}}
|
||||
{{- with index . "vertical" }}{{ $vertical = partial "utilities/CastBool.html" . }}{{ end -}}
|
||||
{{- with index . "width" }}{{ $width = . }}{{ end -}}
|
||||
{{- with index . "kind" }}{{ $kind = . }}{{ end -}}
|
||||
{{- with index . "ratio" }}{{ $ratio = . }}{{ end -}}
|
||||
{{- with index . "wrap" }}{{ $wrap = . }}{{ end -}}
|
||||
{{- with index . "wrap" }}{{ $wrap = partial "utilities/CastBool.html" . }}{{ end -}}
|
||||
{{- end -}}
|
||||
|
||||
{{ if isset $page.Params "nested" }}
|
||||
@@ -151,20 +151,17 @@
|
||||
{{- $params := (dict
|
||||
"page" $page
|
||||
"list" $list
|
||||
"title" $title
|
||||
"icon" $icon
|
||||
"thumbnail" $thumbnail
|
||||
"ratio" $ratio
|
||||
"description" $description
|
||||
"class" $style
|
||||
"color" $color
|
||||
"loading" $loading
|
||||
)
|
||||
-}}
|
||||
|
||||
{{ if eq $layout "card" }}
|
||||
{{- $partial = "assets/card-group.html" -}}
|
||||
{{- $params = merge $params (dict
|
||||
"title" $title
|
||||
"ratio" $ratio
|
||||
"color" $color
|
||||
"loading" $loading
|
||||
"max" $max
|
||||
"cols" $cols
|
||||
"href" $sectionURL
|
||||
@@ -180,7 +177,6 @@
|
||||
{{ else if eq $layout "nav" }}
|
||||
{{- $partial = "assets/nav.html" -}}
|
||||
{{- $params = merge $params (dict
|
||||
"layout" $layout
|
||||
"id" $section
|
||||
"pane" $pane
|
||||
"type" $type
|
||||
@@ -192,6 +188,13 @@
|
||||
{{- else -}}
|
||||
{{- $partial = "assets/list.html" -}}
|
||||
{{- $params = merge $params (dict
|
||||
"title" $title
|
||||
"icon" $icon
|
||||
"thumbnail" $thumbnail
|
||||
"ratio" $ratio
|
||||
"description" $description
|
||||
"color" $color
|
||||
"loading" $loading
|
||||
"layout" $layout
|
||||
)
|
||||
-}}
|
||||
|
@@ -86,8 +86,9 @@
|
||||
{{ $actual = "int" }}
|
||||
{{ else if and (in $expected "float") (findRE `^(?:[1-9]\d*|0)?(?:\.\d+)?$` $val) }}
|
||||
{{ $actual = "float" }}
|
||||
{{ else if and (in $expected "string") (in (slice "bool" "int" "float" "float64") $actual) }}
|
||||
{{ else if and (in $expected "string") (in (slice "bool" "int" "int64" "float" "float64") $actual) }}
|
||||
{{ $actual = "string" }}
|
||||
{{ $val = string $val }}
|
||||
{{ end }}
|
||||
|
||||
{{ if and $val (not (in $expected $actual)) }}
|
||||
|
@@ -16,7 +16,13 @@
|
||||
{{ $color := .Get "color" | default "danger" -}}
|
||||
{{ $icon := .Get "icon" | default "" }}
|
||||
{{ $type := .Get "type" | default "" -}}
|
||||
{{ if eq $type "danger" }}{{ $icon = "fas triangle-exclamation" }}{{ else if eq $type "info" }}{{ $icon = "fa lightbulb" }}{{ end }}
|
||||
{{ if eq $type "danger" }}
|
||||
{{ $icon = "fas triangle-exclamation" }}
|
||||
{{ $color = "danger" }}
|
||||
{{ else if eq $type "info" }}
|
||||
{{ $icon = "fa lightbulb" }}
|
||||
{{ $color = "info" }}
|
||||
{{ end }}
|
||||
{{ with $icon }}
|
||||
{{ $icon = partial "assets/icon.html" (dict "icon" (printf "%s fa-2x fa-fw" .)) }}
|
||||
{{ end }}
|
||||
|
@@ -63,16 +63,15 @@
|
||||
{{ $max := "" }}
|
||||
{{ if and $val.options.values (eq $type "select") }}
|
||||
{{ $comment = printf "%s %s: [%s]." $comment (T "supportedValues") (delimit $val.options.values ", ") }}
|
||||
{{ else if and $val.options.min (in (slice "int" "float" "float64") $type) }}
|
||||
{{ $min = $val.options.min }}
|
||||
{{ else if and $val.options.max (in (slice "int" "float" "float64") $type) }}
|
||||
{{ $max = $val.options.max }}
|
||||
{{ else if in (slice "int" "float" "float64") $type }}
|
||||
{{ if eq (printf "%T" $val.options.min) "int" }}{{ $min = int $val.options.min }}{{ end }}
|
||||
{{ if eq (printf "%T" $val.options.max) "int" }}{{ $max = int $val.options.max }}{{ end }}
|
||||
{{ end }}
|
||||
{{ if and $min $max }}
|
||||
{{ if and (eq (printf "%T" $min) "int") (eq (printf "%T" $max) "int") }}
|
||||
{{ $comment = printf "%s %s: [%d, %d]." $comment (T "supportedValues") $min $max }}
|
||||
{{ else if $min }}
|
||||
{{ else if (eq (printf "%T" $min) "int") }}
|
||||
{{ $comment = printf "%s %s: >=%d." $comment (T "supportedValues") $min }}
|
||||
{{ else if $max }}
|
||||
{{ else if (eq (printf "%T" $max) "int") }}
|
||||
{{ $comment = printf "%s %s: <=%d." $comment (T "supportedValues") $max }}
|
||||
{{ end }}
|
||||
|
||||
|
@@ -28,7 +28,7 @@
|
||||
{{ $outline := false -}}
|
||||
{{ with .Get "outline" }}{{ $outline = partial "utilities/CastBool.html" . }}{{ end -}}
|
||||
{{ $badge := .Get "badge" | default "" -}}
|
||||
{{ $label := .Get "label" | default "" -}}
|
||||
{{ $label := or (.Get "label") (.Get "aria-label") | default "" -}}
|
||||
{{ $tooltip := .Get "tooltip" | default "" -}}
|
||||
{{ $collapse := .Get "collapse" | default "" -}}
|
||||
{{ $href := .Get "href" | default "" -}}
|
||||
|
@@ -14,9 +14,11 @@
|
||||
{{- $gutter := .Get "gutter" | default "4" -}}
|
||||
{{- $title := .Get "title" | default "" -}}
|
||||
{{- $separator := .Get "separator" | default "" -}}
|
||||
{{- $class := .Get "class" | default "" -}}
|
||||
{{- $wrapper := .Get "wrapper" | default "" -}}
|
||||
{{- $responsive := .Get "responsive" | default true -}}
|
||||
|
||||
<!-- Initialize arguments passed to individual cards -->
|
||||
{{- $class := .Get "class" | default "" -}}
|
||||
{{- $color := .Get "color" | default "" -}}
|
||||
{{- $padding := .Get "padding" | default "auto" -}}
|
||||
{{- $header := .Get "header" | default "" -}}
|
||||
|
@@ -21,8 +21,10 @@
|
||||
{{- $gutter := partial "utilities/GetArgParent" (dict "page" . "arg" "gutter") | default "0" -}}
|
||||
{{- $header := partial "utilities/GetArgParent" (dict "page" . "arg" "header") | default "full" -}}
|
||||
{{- $icon := .Get "icon" -}}
|
||||
{{- $loading := .Get "loading" -}}
|
||||
{{- $orientation := partial "utilities/GetArgParent" (dict "page" . "arg" "orientation") | default "stacked" -}}
|
||||
{{- $padding := partial "utilities/GetArgParent" (dict "page" . "arg" "padding") | default "auto" -}}
|
||||
{{- $ratio := partial "utilities/GetArgParent" (dict "page" . "arg" "ratio") | default "" -}}
|
||||
{{- $page := .Page -}}
|
||||
{{- $path := .Get "path" -}}
|
||||
{{- $thumbnail := .Get "thumbnail" -}}
|
||||
@@ -55,8 +57,10 @@
|
||||
"footer" $footer
|
||||
"orientation" $orientation
|
||||
"description" $description
|
||||
"ratio" $ratio
|
||||
"icon" $icon
|
||||
"thumbnail" $thumbnail
|
||||
"loading" $loading
|
||||
"alt" $alt
|
||||
) -}}
|
||||
|
||||
|
@@ -24,9 +24,10 @@
|
||||
{{- end -}}
|
||||
|
||||
{{- $fade := false -}}
|
||||
{{- if eq (.Parent.Get "fade") "true" -}}
|
||||
{{- $fade = true -}}
|
||||
{{- end -}}
|
||||
{{ with .Get "fade" }}{{ $fade = partial "utilities/CastBool.html" . }}{{ end -}}
|
||||
{{- $parentFade := false }}
|
||||
{{ with .Parent.Get "fade" }}{{ $parentFade = partial "utilities/CastBool.html" . }}{{ end -}}
|
||||
{{ $fade = or $fade $parentFade }}
|
||||
{{- $header := .Get "header" | default "" -}}
|
||||
{{- $class := .Get "class" | default "" -}}
|
||||
{{- $body := trim .Inner " \r\n" | .Page.RenderString -}}
|
||||
|
@@ -18,7 +18,7 @@
|
||||
{{- $short := false -}}
|
||||
{{ with .Get "short" }}{{ $short = partial "utilities/CastBool.html" . }}{{ end -}}
|
||||
{{- $inline := false -}}
|
||||
{{ with .Get "inline" }}{{ $short = partial "utilities/CastBool.html" . }}{{ end -}}
|
||||
{{ with .Get "inline" }}{{ $inline = partial "utilities/CastBool.html" . }}{{ end -}}
|
||||
{{- $title := $version -}}
|
||||
{{- $color := "primary" -}}
|
||||
{{- if eq $state "deprecated" -}}
|
||||
|
19
package-lock.json
generated
19
package-lock.json
generated
@@ -1,12 +1,12 @@
|
||||
{
|
||||
"name": "@gethinode/hinode",
|
||||
"version": "0.22.0-beta2",
|
||||
"version": "0.22.0-beta5",
|
||||
"lockfileVersion": 3,
|
||||
"requires": true,
|
||||
"packages": {
|
||||
"": {
|
||||
"name": "@gethinode/hinode",
|
||||
"version": "0.22.0-beta2",
|
||||
"version": "0.22.0-beta5",
|
||||
"license": "MIT",
|
||||
"devDependencies": {
|
||||
"@fullhuman/postcss-purgecss": "^5.0.0",
|
||||
@@ -18,7 +18,7 @@
|
||||
"eslint": "^8.56.0",
|
||||
"eslint-config-standard": "^17.1.0",
|
||||
"eslint-plugin-import": "^2.29.1",
|
||||
"eslint-plugin-n": "^16.5.0",
|
||||
"eslint-plugin-n": "^16.6.0",
|
||||
"eslint-plugin-promise": "^6.1.1",
|
||||
"hugo-bin": "^0.118.0",
|
||||
"markdownlint-cli2": "^0.11.0",
|
||||
@@ -2986,15 +2986,16 @@
|
||||
"dev": true
|
||||
},
|
||||
"node_modules/eslint-plugin-n": {
|
||||
"version": "16.5.0",
|
||||
"resolved": "https://registry.npmjs.org/eslint-plugin-n/-/eslint-plugin-n-16.5.0.tgz",
|
||||
"integrity": "sha512-Hw02Bj1QrZIlKyj471Tb1jSReTl4ghIMHGuBGiMVmw+s0jOPbI4CBuYpGbZr+tdQ+VAvSK6FDSta3J4ib/SKHQ==",
|
||||
"version": "16.6.0",
|
||||
"resolved": "https://registry.npmjs.org/eslint-plugin-n/-/eslint-plugin-n-16.6.0.tgz",
|
||||
"integrity": "sha512-Ag3tYFF90lYU8JdHEl9qSSpeLYbVnO+Oj7sgPUarWUacv1mPL3d5h5yG4Bv3tLe71hrcxmgTi7oByYwKXaVatw==",
|
||||
"dev": true,
|
||||
"dependencies": {
|
||||
"@eslint-community/eslint-utils": "^4.4.0",
|
||||
"builtins": "^5.0.1",
|
||||
"eslint-plugin-es-x": "^7.5.0",
|
||||
"get-tsconfig": "^4.7.0",
|
||||
"globals": "^13.24.0",
|
||||
"ignore": "^5.2.4",
|
||||
"is-builtin-module": "^3.2.1",
|
||||
"is-core-module": "^2.12.1",
|
||||
@@ -4017,9 +4018,9 @@
|
||||
}
|
||||
},
|
||||
"node_modules/globals": {
|
||||
"version": "13.23.0",
|
||||
"resolved": "https://registry.npmjs.org/globals/-/globals-13.23.0.tgz",
|
||||
"integrity": "sha512-XAmF0RjlrjY23MA51q3HltdlGxUpXPvg0GioKiD9X6HD28iMjo2dKC8Vqwm7lne4GNr78+RHTfliktR6ZH09wA==",
|
||||
"version": "13.24.0",
|
||||
"resolved": "https://registry.npmjs.org/globals/-/globals-13.24.0.tgz",
|
||||
"integrity": "sha512-AhO5QUcj8llrbG09iWhPU2B204J1xnPeL8kQmVorSsy+Sjj1sk8gIyh6cUocGmH4L0UuhAJy+hJMRA4mgA4mFQ==",
|
||||
"dev": true,
|
||||
"dependencies": {
|
||||
"type-fest": "^0.20.2"
|
||||
|
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@gethinode/hinode",
|
||||
"version": "0.22.0-beta2",
|
||||
"version": "0.22.0-beta5",
|
||||
"description": "Hinode is a clean documentation and blog theme for Hugo, an open-source static site generator",
|
||||
"keywords": [
|
||||
"hugo",
|
||||
@@ -76,7 +76,7 @@
|
||||
"eslint": "^8.56.0",
|
||||
"eslint-config-standard": "^17.1.0",
|
||||
"eslint-plugin-import": "^2.29.1",
|
||||
"eslint-plugin-n": "^16.5.0",
|
||||
"eslint-plugin-n": "^16.6.0",
|
||||
"eslint-plugin-promise": "^6.1.1",
|
||||
"hugo-bin": "^0.118.0",
|
||||
"markdownlint-cli2": "^0.11.0",
|
||||
|
Reference in New Issue
Block a user