jekyll-theme-centos 2.52.0.beta.94 → 2.52.0.beta.96
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/_config.yml +0 -4
- data/_data/base/accordion_schema.yml +100 -0
- data/_data/base/content.yml +3 -1
- data/_data/base/content_schema.yml +32 -6
- data/_data/base/footer.yml +1 -0
- data/_data/base/footer_schema.yml +6 -0
- data/_data/base/heading_anchor.yml +1 -1
- data/_data/base/heading_anchor_schema.yml +7 -17
- data/_includes/base/accordion-item.html.liquid +55 -0
- data/_includes/base/accordion.html.liquid +40 -0
- data/_includes/base/artwork.html.liquid +5 -1
- data/_includes/base/bits.html.liquid +20 -3
- data/_includes/base/breadcrumb.html.liquid +6 -2
- data/_includes/base/color-table.html.liquid +2 -0
- data/_includes/base/content.html.liquid +41 -11
- data/_includes/base/download_commands.html.liquid +1 -1
- data/_includes/base/download_documentation.html.liquid +1 -1
- data/_includes/base/download_eol.html.liquid +1 -1
- data/_includes/base/download_screenshots.html.liquid +1 -1
- data/_includes/base/download_sections.html.liquid +3 -2
- data/_includes/base/footer.html.liquid +3 -2
- data/_includes/base/head.html.liquid +0 -2
- data/_includes/base/navindex.html.liquid +6 -2
- data/_includes/base/title.html.liquid +5 -1
- data/_includes/base/toc.html.liquid +5 -1
- data/_layouts/base/default.html +2 -29
- data/_sass/base/_customization.scss +6 -6
- metadata +4 -4
- data/_includes/base/accordion_item.html.liquid +0 -40
- data/_includes/base/heading_anchor.html.liquid +0 -67
- data/assets/js/base/heading-anchor.js +0 -109
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: f5d7826e37033ad225ba8f67091b714b4486821b56ddb41b7259c9593f6f777a
|
|
4
|
+
data.tar.gz: 859ec7818eee6e8fdba4f1d97e439c2ba2318422b864f43180b1ba1b0fb6e757
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 944084fc09f8ac08efc3e7d6d054b4f8e33d4a415cf2d534422dd3241c62298d132bf1e624002d0f4877ac03a189fceeb6fe5ae3cf3968af60f8741a450cbf08
|
|
7
|
+
data.tar.gz: 18e70fcc850b108ce04909d329475a2498eb77f78d07f72f17c225ce896ff34d5796d48bbf9474a24e87363b301e61ee01bab95c38946565adf627a2e65d18e0
|
data/_config.yml
CHANGED
|
@@ -0,0 +1,100 @@
|
|
|
1
|
+
title: Accordion Component Configuration
|
|
2
|
+
description: >-
|
|
3
|
+
Schema for configuring a Bootstrap accordion. `accordion.html.liquid`
|
|
4
|
+
renders the wrapper `<div class="accordion" id="...">`, given a
|
|
5
|
+
pre-rendered HTML string of one or more accordion-item includes built by
|
|
6
|
+
the caller. `accordion-item.html.liquid` renders one accordion-item
|
|
7
|
+
(header/button/collapse/body); its own defaults live under `item`, below.
|
|
8
|
+
All parameters are passed directly as include parameters when calling
|
|
9
|
+
either component.
|
|
10
|
+
type: object
|
|
11
|
+
properties:
|
|
12
|
+
id:
|
|
13
|
+
type: string
|
|
14
|
+
default: ""
|
|
15
|
+
description: >-
|
|
16
|
+
The wrapper's DOM id, referenced by every child accordion-item's
|
|
17
|
+
`data-bs-parent` scoping. This field is required.
|
|
18
|
+
class:
|
|
19
|
+
type: string
|
|
20
|
+
default: ""
|
|
21
|
+
description: >-
|
|
22
|
+
CSS classes applied to the wrapper `<div class="accordion ...">`
|
|
23
|
+
(e.g., `accordion-flush mt-3`, `w-100 mb-3`).
|
|
24
|
+
items:
|
|
25
|
+
type: string
|
|
26
|
+
default: ""
|
|
27
|
+
description: >-
|
|
28
|
+
Pre-rendered HTML string containing one or more `accordion-item`
|
|
29
|
+
includes, built by the caller via a `capture` tag (looping and
|
|
30
|
+
appending one accordion-item render per iteration, or capturing
|
|
31
|
+
several sibling includes together). This field is required.
|
|
32
|
+
item:
|
|
33
|
+
type: object
|
|
34
|
+
description: >-
|
|
35
|
+
Per-item defaults, used by accordion-item.html.liquid. Each accordion
|
|
36
|
+
item is rendered by its own include call — this component never
|
|
37
|
+
loops over structured item data itself.
|
|
38
|
+
properties:
|
|
39
|
+
icon:
|
|
40
|
+
type: string
|
|
41
|
+
default: ""
|
|
42
|
+
description: >-
|
|
43
|
+
Font Awesome icon class shown before the title (e.g., `fa-solid
|
|
44
|
+
fa-book`). This field is required.
|
|
45
|
+
title:
|
|
46
|
+
type: string
|
|
47
|
+
default: ""
|
|
48
|
+
description: Accordion button label text. This field is required.
|
|
49
|
+
title_class:
|
|
50
|
+
type: string
|
|
51
|
+
default: "ms-1"
|
|
52
|
+
description: >-
|
|
53
|
+
CSS classes applied to the title `<span>`, replacing the default
|
|
54
|
+
(e.g., `ms-1 fw-bold` for a bold title instead of the
|
|
55
|
+
regular-weight default).
|
|
56
|
+
item_id:
|
|
57
|
+
type: string
|
|
58
|
+
default: ""
|
|
59
|
+
description: >-
|
|
60
|
+
This item's unique collapse id, used for `data-bs-target`/`id`/
|
|
61
|
+
`aria-controls` wiring. Must be unique across the page. This
|
|
62
|
+
field is required.
|
|
63
|
+
accordion_id:
|
|
64
|
+
type: string
|
|
65
|
+
default: ""
|
|
66
|
+
description: >-
|
|
67
|
+
The parent accordion wrapper's id, used for `data-bs-parent`
|
|
68
|
+
scoping so this item collapses its siblings correctly. Must match
|
|
69
|
+
the `id` passed to accordion.html.liquid for the surrounding
|
|
70
|
+
wrapper. This field is required.
|
|
71
|
+
expanded:
|
|
72
|
+
type: boolean
|
|
73
|
+
default: false
|
|
74
|
+
description: >-
|
|
75
|
+
`true` starts this item open (`show` class,
|
|
76
|
+
`aria-expanded="true"`, button not collapsed); `false` (default)
|
|
77
|
+
starts it closed.
|
|
78
|
+
body:
|
|
79
|
+
type: string
|
|
80
|
+
default: ""
|
|
81
|
+
description: >-
|
|
82
|
+
Pre-rendered HTML string (built via a `capture` tag at the call
|
|
83
|
+
site) for the accordion-body's contents. This field is required.
|
|
84
|
+
body_class:
|
|
85
|
+
type: string
|
|
86
|
+
default: ""
|
|
87
|
+
description: >-
|
|
88
|
+
Extra CSS classes appended to `accordion-body` (e.g., `p-0` to
|
|
89
|
+
remove body padding when the content supplies its own).
|
|
90
|
+
required:
|
|
91
|
+
- icon
|
|
92
|
+
- title
|
|
93
|
+
- item_id
|
|
94
|
+
- accordion_id
|
|
95
|
+
- body
|
|
96
|
+
additionalProperties: false
|
|
97
|
+
required:
|
|
98
|
+
- id
|
|
99
|
+
- items
|
|
100
|
+
additionalProperties: false
|
data/_data/base/content.yml
CHANGED
|
@@ -1,15 +1,22 @@
|
|
|
1
1
|
title: Content Section Configuration
|
|
2
2
|
description: >-
|
|
3
|
-
Schema for configuring the
|
|
4
|
-
|
|
3
|
+
Schema for configuring the content component, which owns the <main>
|
|
4
|
+
element in the default layout. This controls the rendering of the entire
|
|
5
|
+
main page body — the announcement, bits, event, breadcrumb, title,
|
|
6
|
+
artwork, and table of contents components nested inside <main>, followed
|
|
7
|
+
by the page's own converted Markdown or HTML content — as well as the
|
|
8
|
+
layout of that content area.
|
|
5
9
|
type: object
|
|
6
10
|
properties:
|
|
7
11
|
with_content:
|
|
8
12
|
type: boolean
|
|
9
13
|
default: true
|
|
10
14
|
description: >-
|
|
11
|
-
Enables or disables the rendering of the
|
|
12
|
-
|
|
15
|
+
Enables or disables the rendering of the <main> element and every
|
|
16
|
+
component nested inside it (announcement, bits, event, breadcrumb,
|
|
17
|
+
title, artwork, toc, and the page's own content). Set to `true`
|
|
18
|
+
(default) to display the main content region; set to `false` to omit
|
|
19
|
+
`<main>` entirely from the rendered page.
|
|
13
20
|
with_content_data:
|
|
14
21
|
type: object
|
|
15
22
|
description: >-
|
|
@@ -17,10 +24,29 @@ properties:
|
|
|
17
24
|
rendered content section.
|
|
18
25
|
properties:
|
|
19
26
|
class:
|
|
27
|
+
type: string
|
|
28
|
+
default: "container py-3"
|
|
29
|
+
description: >-
|
|
30
|
+
Custom Bootstrap class(es) applied to the `<main>` element itself
|
|
31
|
+
— the outermost element owned by this component. Controls the
|
|
32
|
+
outer container behavior (max-width constraint, vertical padding)
|
|
33
|
+
for the entire main page body.
|
|
34
|
+
row_class:
|
|
35
|
+
type: string
|
|
36
|
+
default: "row mb-3"
|
|
37
|
+
description: >-
|
|
38
|
+
Custom Bootstrap class(es) applied to the `div.row` that wraps the
|
|
39
|
+
content section's `div.col` container. This same class is also
|
|
40
|
+
passed to the breadcrumb, title, artwork, and toc components, so
|
|
41
|
+
every row inside `<main>` shares the same spacing.
|
|
42
|
+
col_class:
|
|
20
43
|
type: string
|
|
21
44
|
default: col
|
|
22
45
|
description: >-
|
|
23
|
-
A Bootstrap column class used to control the width and
|
|
24
|
-
|
|
46
|
+
A Bootstrap column class used to control the width and
|
|
47
|
+
responsiveness of the content section's `div.col` container (e.g.,
|
|
48
|
+
`col`, `col-md-10`, `col-lg-8`). This same class is also passed to
|
|
49
|
+
the breadcrumb, title, artwork, and toc components, so the whole
|
|
50
|
+
page moves as one aligned column.
|
|
25
51
|
additionalProperties: false # Added to restrict unexpected properties in the data object
|
|
26
52
|
additionalProperties: false
|
data/_data/base/footer.yml
CHANGED
|
@@ -20,6 +20,12 @@ properties:
|
|
|
20
20
|
defined here (in the page's front matter) override any global `footer`
|
|
21
21
|
data defined in site-wide `_data` files.
|
|
22
22
|
properties:
|
|
23
|
+
class:
|
|
24
|
+
type: string
|
|
25
|
+
default: "footer small bg-dark text-centos-purple-100 pt-5"
|
|
26
|
+
description: >-
|
|
27
|
+
Custom Bootstrap class(es) applied to the `<footer>` element
|
|
28
|
+
itself — the outermost element owned by this component.
|
|
23
29
|
brand_image:
|
|
24
30
|
type: string
|
|
25
31
|
default: "centos-whitelogo.svg"
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
---
|
|
2
|
-
icon: "
|
|
2
|
+
icon: "heading-anchor-hash pe-1"
|
|
@@ -2,8 +2,8 @@
|
|
|
2
2
|
title: Heading Anchor Component Configuration
|
|
3
3
|
description: >
|
|
4
4
|
Configuration for the first-class heading anchor feature of jekyll-link-decorator.
|
|
5
|
-
Each heading (h1–h6) receives a
|
|
6
|
-
|
|
5
|
+
Each heading (h1–h6) receives a permalink: an anchor with a hover/focus-revealed
|
|
6
|
+
glyph, linking to the heading itself.
|
|
7
7
|
type: object
|
|
8
8
|
properties:
|
|
9
9
|
with_heading_anchor:
|
|
@@ -12,26 +12,16 @@ properties:
|
|
|
12
12
|
default: true
|
|
13
13
|
with_heading_anchor_data:
|
|
14
14
|
type: object
|
|
15
|
-
description: Configuration for heading anchor appearance
|
|
15
|
+
description: Configuration for heading anchor appearance.
|
|
16
16
|
properties:
|
|
17
17
|
icon:
|
|
18
18
|
type: string
|
|
19
|
-
description:
|
|
20
|
-
|
|
19
|
+
description: >
|
|
20
|
+
CSS classes applied to the anchor's glyph element. Defaults to a plain
|
|
21
|
+
"#" character rendered via the .heading-anchor-hash class.
|
|
22
|
+
default: "heading-anchor-hash pe-1"
|
|
21
23
|
icon_size:
|
|
22
24
|
type: string
|
|
23
25
|
description: Font Awesome size modifier appended after the icon classes.
|
|
24
|
-
copy_success_message:
|
|
25
|
-
type: string
|
|
26
|
-
description: >
|
|
27
|
-
Feedback message shown after a successful clipboard copy.
|
|
28
|
-
Consumed by heading-anchor.js via data-success-message on the script element.
|
|
29
|
-
default: "Copied!"
|
|
30
|
-
reset_delay:
|
|
31
|
-
type: integer
|
|
32
|
-
description: >
|
|
33
|
-
Milliseconds to wait before the icon resets to its original state
|
|
34
|
-
after a successful copy. Consumed by heading-anchor.js via data-reset-delay.
|
|
35
|
-
default: 2000
|
|
36
26
|
additionalProperties: false
|
|
37
27
|
additionalProperties: false
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
{% comment %}
|
|
2
|
+
================================================================================
|
|
3
|
+
Template: Accordion Item Component
|
|
4
|
+
Purpose: Renders a single Bootstrap accordion-item (header/button/collapse/
|
|
5
|
+
body), the shared shell for one collapsible entry within an accordion.
|
|
6
|
+
Pairs with accordion.html.liquid, which renders the surrounding wrapper —
|
|
7
|
+
this component only renders one item; callers loop/capture as many as they
|
|
8
|
+
need and pass the concatenated result to accordion.html.liquid as `items`.
|
|
9
|
+
|
|
10
|
+
Design Logic:
|
|
11
|
+
- Bootstrap's accordion-item/header/button/collapse/body markup, driven
|
|
12
|
+
entirely by include parameters — no data-source fallback chain
|
|
13
|
+
- `item_id`/`accordion_id` scope this item's collapse behavior to the
|
|
14
|
+
caller-supplied parent accordion via `data-bs-parent`
|
|
15
|
+
- `expanded` toggles the initial open/closed state across button, collapse
|
|
16
|
+
container, and ARIA attributes together
|
|
17
|
+
|
|
18
|
+
Optional Inputs:
|
|
19
|
+
- title_class: Classes for the title span, replacing the "ms-1" default
|
|
20
|
+
(e.g. "ms-1 fw-bold" for a bold title).
|
|
21
|
+
- body_class: Extra classes appended to "accordion-body" (e.g. "p-0" to
|
|
22
|
+
remove body padding when the content supplies its own).
|
|
23
|
+
|
|
24
|
+
Data Source:
|
|
25
|
+
- Derived from include parameters only
|
|
26
|
+
================================================================================
|
|
27
|
+
{% endcomment %}
|
|
28
|
+
|
|
29
|
+
{%- assign with_accordion_item_schema = site.data.base.accordion_schema.properties.item.properties %}
|
|
30
|
+
|
|
31
|
+
{%- assign accordion_item_icon = include.icon | default: with_accordion_item_schema.icon.default %}
|
|
32
|
+
{%- assign accordion_item_title = include.title | default: with_accordion_item_schema.title.default %}
|
|
33
|
+
{%- assign accordion_item_title_class = include.title_class | default: with_accordion_item_schema.title_class.default %}
|
|
34
|
+
{%- assign accordion_item_item_id = include.item_id | default: with_accordion_item_schema.item_id.default %}
|
|
35
|
+
{%- assign accordion_item_accordion_id = include.accordion_id | default: with_accordion_item_schema.accordion_id.default %}
|
|
36
|
+
{%- assign accordion_item_expanded = include.expanded | default: with_accordion_item_schema.expanded.default %}
|
|
37
|
+
{%- assign accordion_item_body = include.body | default: with_accordion_item_schema.body.default %}
|
|
38
|
+
{%- assign accordion_item_body_class = include.body_class | default: with_accordion_item_schema.body_class.default %}
|
|
39
|
+
|
|
40
|
+
{%- comment %} === Presentation === {% endcomment %}
|
|
41
|
+
{%- comment %} --- HTML --- {% endcomment -%}
|
|
42
|
+
<div class="accordion-item">
|
|
43
|
+
<div class="accordion-header h2">
|
|
44
|
+
<button class="accordion-button{% unless accordion_item_expanded %} collapsed{% endunless %}" type="button" data-bs-toggle="collapse" data-bs-target="#{{ accordion_item_item_id }}" aria-expanded="{{ accordion_item_expanded }}" aria-controls="{{ accordion_item_item_id }}">
|
|
45
|
+
<i class="{{ accordion_item_icon }} me-2"></i>
|
|
46
|
+
<span{% unless accordion_item_title_class == blank %} class="{{ accordion_item_title_class }}"{% endunless %}>{{ accordion_item_title }}</span>
|
|
47
|
+
</button>
|
|
48
|
+
</div>
|
|
49
|
+
<div id="{{ accordion_item_item_id }}" class="accordion-collapse collapse{% if accordion_item_expanded %} show{% endif %}" data-bs-parent="#{{ accordion_item_accordion_id }}">
|
|
50
|
+
<div class="accordion-body{% if accordion_item_body_class != "" %} {{ accordion_item_body_class }}{% endif %}">
|
|
51
|
+
{{ accordion_item_body }}
|
|
52
|
+
</div>
|
|
53
|
+
</div>
|
|
54
|
+
</div>
|
|
55
|
+
{%- comment %} trim trailing output {% endcomment -%}
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
{% comment %}
|
|
2
|
+
================================================================================
|
|
3
|
+
Template: Accordion Wrapper Component
|
|
4
|
+
Purpose: Renders the Bootstrap accordion wrapper `<div class="accordion"
|
|
5
|
+
id="...">`, given a pre-rendered HTML string of one or more accordion-item
|
|
6
|
+
includes. Pairs with accordion-item.html.liquid, which renders each
|
|
7
|
+
individual item — see that file for the item-level markup. Callers build
|
|
8
|
+
`items` via a capture tag: loop-and-append when the item count is dynamic
|
|
9
|
+
(see bits.html.liquid), or capture several sibling accordion-item includes
|
|
10
|
+
together when the items are fixed (see download_sections.html.liquid).
|
|
11
|
+
|
|
12
|
+
Design Logic:
|
|
13
|
+
- Wrapper only: no looping over structured item data — Jekyll's Liquid
|
|
14
|
+
include mechanism has no block/yield content-passing, so per-item body
|
|
15
|
+
content must already be caller-rendered HTML by the time it reaches this
|
|
16
|
+
component
|
|
17
|
+
- `id` is the scoping anchor every child accordion-item's `accordion_id`
|
|
18
|
+
parameter must match, via `data-bs-parent`
|
|
19
|
+
|
|
20
|
+
Optional Inputs:
|
|
21
|
+
- class: Extra classes appended to "accordion" (e.g. "accordion-flush
|
|
22
|
+
mt-3", "w-100 mb-3").
|
|
23
|
+
|
|
24
|
+
Data Source:
|
|
25
|
+
- Derived from include parameters only
|
|
26
|
+
================================================================================
|
|
27
|
+
{% endcomment %}
|
|
28
|
+
|
|
29
|
+
{%- assign with_accordion_schema = site.data.base.accordion_schema.properties %}
|
|
30
|
+
|
|
31
|
+
{%- assign accordion_id = include.id | default: with_accordion_schema.id.default %}
|
|
32
|
+
{%- assign accordion_class = include.class | default: with_accordion_schema.class.default %}
|
|
33
|
+
{%- assign accordion_items = include.items | default: with_accordion_schema.items.default %}
|
|
34
|
+
|
|
35
|
+
{%- comment %} === Presentation === {% endcomment %}
|
|
36
|
+
{%- comment %} --- HTML --- {% endcomment -%}
|
|
37
|
+
<div class="accordion{% if accordion_class != "" %} {{ accordion_class }}{% endif %}" id="{{ accordion_id }}">
|
|
38
|
+
{{- accordion_items -}}
|
|
39
|
+
</div>
|
|
40
|
+
{%- comment %} trim trailing output {% endcomment -%}
|
|
@@ -19,6 +19,9 @@ Optional Inputs:
|
|
|
19
19
|
- data: Artwork data object (overrides fallbacks)
|
|
20
20
|
- column_class: Bootstrap column class for the row wrapper (set by the layout to
|
|
21
21
|
keep this component aligned with the content column; defaults to "col")
|
|
22
|
+
- row_class: Bootstrap class(es) for the row wrapper (set by the layout to
|
|
23
|
+
keep this component's row aligned with breadcrumb, title, toc, and
|
|
24
|
+
content; defaults to "row mb-3")
|
|
22
25
|
|
|
23
26
|
Data Source Hierarchy (priority):
|
|
24
27
|
1. include.data
|
|
@@ -49,9 +52,10 @@ Data Source Hierarchy (priority):
|
|
|
49
52
|
{%- assign artwork_class = with_artwork_data.class | default: with_artwork_schema.class.default %}
|
|
50
53
|
{%- assign artwork_image_class = with_artwork_data.image_class | default: with_artwork_schema.image_class.default %}
|
|
51
54
|
{%- assign column_class = include.column_class | default: 'col' %}
|
|
55
|
+
{%- assign row_class = include.row_class | default: 'row mb-3' %}
|
|
52
56
|
|
|
53
57
|
{%- comment %} --- HTML --- {% endcomment %}
|
|
54
|
-
<div class="
|
|
58
|
+
<div class="{{ row_class }}">
|
|
55
59
|
<div class="{{ column_class }}">
|
|
56
60
|
<div class="{{ artwork_class }}">
|
|
57
61
|
<div class="{{ artwork_image_class }}" role="img" aria-label="{{ artwork_alt }}"></div>
|
|
@@ -167,20 +167,37 @@ Data Source Hierarchy (priority order):
|
|
|
167
167
|
{%- endcapture %}
|
|
168
168
|
|
|
169
169
|
{%- capture downstream_bit_media %}
|
|
170
|
+
{% if downstream_bit.screenshot and downstream_bit.screenshot != "" %}
|
|
170
171
|
<div class="bg-{{ upstream_bit_color }} rounded-top">
|
|
171
172
|
<img src="{{ site.baseurl }}/assets/img/{{ downstream_bit.screenshot }}" class="{{ downstream_item_img_class }}" alt="{{ downstream_bit.screenshot }}">
|
|
172
173
|
</div>
|
|
174
|
+
{% endif %}
|
|
173
175
|
{%- endcapture %}
|
|
174
176
|
|
|
175
177
|
{%- if upstream_bit_downstream_style == "accordion" %}
|
|
176
178
|
{%- assign downstream_bit_id = downstream_bit.name | replace: " ", "" | capitalize %}
|
|
177
179
|
{%- assign downstream_item_id = downstream_accordion_id | append: "-" | append: downstream_bit_id %}
|
|
180
|
+
{%- capture downstream_bit_actions_full %}
|
|
181
|
+
{%- if downstream_bit.actions.size > 0 %}
|
|
182
|
+
<div class="{{ upstream_bit_actions_class }}">
|
|
183
|
+
{%- for downstream_bit_action in downstream_bit.actions %}
|
|
184
|
+
{%- include base/link.html.liquid
|
|
185
|
+
name = downstream_bit_action.name
|
|
186
|
+
link = downstream_bit_action.link
|
|
187
|
+
class = upstream_bit_btn_class
|
|
188
|
+
icon = downstream_bit_action.icon
|
|
189
|
+
icon_position = downstream_bit_action.icon_position
|
|
190
|
+
-%}
|
|
191
|
+
{%- endfor %}
|
|
192
|
+
</div>
|
|
193
|
+
{%- endif %}
|
|
194
|
+
{%- endcapture %}
|
|
178
195
|
{%- capture downstream_bit_body %}
|
|
179
196
|
{{- downstream_bit_media | strip -}}
|
|
180
197
|
<p class="card-text mt-3">{{ downstream_bit.description }}</p>
|
|
181
|
-
{{
|
|
198
|
+
{{ downstream_bit_actions_full }}
|
|
182
199
|
{%- endcapture %}
|
|
183
|
-
{%- include base/
|
|
200
|
+
{%- include base/accordion-item.html.liquid
|
|
184
201
|
icon = downstream_bit.icon
|
|
185
202
|
title = downstream_bit.name
|
|
186
203
|
item_id = downstream_item_id
|
|
@@ -205,7 +222,7 @@ Data Source Hierarchy (priority order):
|
|
|
205
222
|
{%- endcapture %}
|
|
206
223
|
|
|
207
224
|
{%- if upstream_bit_downstream_style == "accordion" %}
|
|
208
|
-
|
|
225
|
+
{%- include base/accordion.html.liquid id=downstream_accordion_id class="w-100 mb-3" items=downstream_items_html -%}
|
|
209
226
|
{%- else %}
|
|
210
227
|
<div class="row w-100 mb-3 g-2">{{- downstream_items_html -}}</div>
|
|
211
228
|
{%- endif %}
|
|
@@ -22,6 +22,9 @@ Optional Inputs:
|
|
|
22
22
|
- with_breadcrumb_data.arialabel: aria-label for the <nav> element (default: "breadcrumb")
|
|
23
23
|
- column_class (include param): Bootstrap column class for the row wrapper (set by
|
|
24
24
|
the layout to keep this component aligned with the content column; defaults to "col")
|
|
25
|
+
- row_class (include param): Bootstrap class(es) for the row wrapper (set by
|
|
26
|
+
the layout to keep this component's row aligned with title, artwork, toc,
|
|
27
|
+
and content; defaults to "row mb-3")
|
|
25
28
|
|
|
26
29
|
Data Source Hierarchy:
|
|
27
30
|
- with_breadcrumb: include.with_breadcrumb → page.with_breadcrumb
|
|
@@ -50,10 +53,11 @@ Data Source Hierarchy:
|
|
|
50
53
|
{%- assign detected_locale = page.locale | default: 'en' %}
|
|
51
54
|
|
|
52
55
|
{%- assign column_class = include.column_class | default: 'col' %}
|
|
56
|
+
{%- assign row_class = include.row_class | default: 'row mb-3' %}
|
|
53
57
|
|
|
54
|
-
<div class="
|
|
58
|
+
<div class="{{ row_class }}">
|
|
55
59
|
<div class="{{ column_class }}">
|
|
56
|
-
<nav aria-label="{{ with_breadcrumb_data.arialabel | default: with_breadcrumb_schema.arialabel.default | default: 'breadcrumb' }}">
|
|
60
|
+
<nav class="small" aria-label="{{ with_breadcrumb_data.arialabel | default: with_breadcrumb_schema.arialabel.default | default: 'breadcrumb' }}">
|
|
57
61
|
<ol class="breadcrumb mb-0">
|
|
58
62
|
{%- comment %} Home link - adjust for locale {%- endcomment %}
|
|
59
63
|
{%- if detected_locale == 'en' or detected_locale == '' %}
|
|
@@ -8,19 +8,49 @@
|
|
|
8
8
|
| default: site.data.base.content
|
|
9
9
|
-%}
|
|
10
10
|
|
|
11
|
+
{%- assign content_schema_key = "content_schema" %}
|
|
12
|
+
{%- assign content_schema = include.schema
|
|
13
|
+
| default: site.data[content_schema_key]
|
|
14
|
+
| default: site.data.base[content_schema_key]
|
|
15
|
+
-%}
|
|
16
|
+
|
|
17
|
+
{%- assign class = include.class
|
|
18
|
+
| default: with_content_data.class
|
|
19
|
+
| default: content_schema.properties.with_content_data.properties.class.default
|
|
20
|
+
| default: 'container py-3' -%}
|
|
21
|
+
|
|
22
|
+
{%- assign row_class = include.row_class
|
|
23
|
+
| default: with_content_data.row_class
|
|
24
|
+
| default: content_schema.properties.with_content_data.properties.row_class.default
|
|
25
|
+
| default: 'row mb-3' -%}
|
|
26
|
+
|
|
27
|
+
{%- assign col_class = include.col_class
|
|
28
|
+
| default: with_content_data.col_class
|
|
29
|
+
| default: content_schema.properties.with_content_data.properties.col_class.default
|
|
30
|
+
| default: 'col' -%}
|
|
31
|
+
|
|
11
32
|
{%- if with_content -%}
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
33
|
+
<main class="{{ class }}">
|
|
34
|
+
|
|
35
|
+
{%- include base/announcement.html.liquid %}
|
|
36
|
+
|
|
37
|
+
{% include base/bits.html.liquid %}
|
|
38
|
+
|
|
39
|
+
{% include base/event.html.liquid %}
|
|
40
|
+
|
|
41
|
+
{% include base/breadcrumb.html.liquid column_class=col_class row_class=row_class %}
|
|
42
|
+
|
|
43
|
+
{% include base/title.html.liquid column_class=col_class row_class=row_class %}
|
|
44
|
+
|
|
45
|
+
{% include base/artwork.html.liquid column_class=col_class row_class=row_class %}
|
|
46
|
+
|
|
47
|
+
{% include base/toc.html.liquid column_class=col_class row_class=row_class %}
|
|
48
|
+
|
|
49
|
+
<div class="{{ row_class }}">
|
|
50
|
+
<div class="{{ col_class }} content">
|
|
23
51
|
{{ content }}
|
|
24
52
|
</div>
|
|
25
53
|
</div>
|
|
54
|
+
|
|
55
|
+
</main>
|
|
26
56
|
{%- endif -%}
|
|
@@ -24,4 +24,4 @@ Required Inputs:
|
|
|
24
24
|
{%- endif %}
|
|
25
25
|
{%- endfor %}
|
|
26
26
|
{%- endcapture -%}
|
|
27
|
-
{%- include base/
|
|
27
|
+
{%- include base/accordion-item.html.liquid icon="fa-solid fa-terminal" title="Migration" item_id=include.item_id accordion_id=include.accordion_id expanded=include.expanded body=download_commands_body -%}
|
|
@@ -55,4 +55,4 @@ kinds doesn't end up with paragraphs breaking up a button row.
|
|
|
55
55
|
{%- if download_documentation_prose_stripped != "" %}{{ download_documentation_prose }}{%- endif %}
|
|
56
56
|
{%- if download_documentation_buttons_stripped != "" %}<div class="d-flex flex-wrap gap-2">{{ download_documentation_buttons }}</div>{%- endif %}
|
|
57
57
|
{%- endcapture -%}
|
|
58
|
-
{%- include base/
|
|
58
|
+
{%- include base/accordion-item.html.liquid icon="fa-solid fa-book" title="Documentation" item_id=include.item_id accordion_id=include.accordion_id expanded=include.expanded body=download_documentation_body -%}
|
|
@@ -26,4 +26,4 @@ Required Inputs:
|
|
|
26
26
|
{%- endfor %}
|
|
27
27
|
</ul>
|
|
28
28
|
{%- endcapture -%}
|
|
29
|
-
{%- include base/
|
|
29
|
+
{%- include base/accordion-item.html.liquid icon="fa-solid fa-hourglass-end" title="End-of-life" item_id=include.item_id accordion_id=include.accordion_id expanded=include.expanded body=download_eol_body -%}
|
|
@@ -108,4 +108,4 @@ row too.
|
|
|
108
108
|
</div>
|
|
109
109
|
</div>
|
|
110
110
|
{%- endcapture -%}
|
|
111
|
-
{%- include base/
|
|
111
|
+
{%- include base/accordion-item.html.liquid icon="fa-solid fa-desktop" title="Screenshots" item_id=include.item_id accordion_id=include.accordion_id expanded=include.expanded body_class="p-0" body=download_screenshots_body -%}
|
|
@@ -31,7 +31,7 @@ Required Inputs:
|
|
|
31
31
|
{%- assign meta_eol_id = meta_accordion_id | append: "-eol" %}
|
|
32
32
|
|
|
33
33
|
{%- if include.release_data.documentation.size > 0 or include.release_data.commands.size > 0 or include.release_data.eol.size > 0 or include.release_data.screenshots.size > 0 %}
|
|
34
|
-
|
|
34
|
+
{%- capture meta_accordion_items %}
|
|
35
35
|
{%- if include.release_data.screenshots.size > 0 %}
|
|
36
36
|
{%- include base/download_screenshots.html.liquid screenshots=include.release_data.screenshots image_base_path=include.image_base_path release_id=include.release_id accordion_id=meta_accordion_id item_id=meta_screenshots_id expanded=false -%}
|
|
37
37
|
{%- endif %}
|
|
@@ -47,5 +47,6 @@ Required Inputs:
|
|
|
47
47
|
{%- if include.release_data.eol.size > 0 %}
|
|
48
48
|
{%- include base/download_eol.html.liquid eol=include.release_data.eol accordion_id=meta_accordion_id item_id=meta_eol_id expanded=false -%}
|
|
49
49
|
{%- endif %}
|
|
50
|
-
|
|
50
|
+
{%- endcapture %}
|
|
51
|
+
{%- include base/accordion.html.liquid id=meta_accordion_id class="accordion-flush mt-3" items=meta_accordion_items -%}
|
|
51
52
|
{%- endif %}
|
|
@@ -10,16 +10,17 @@
|
|
|
10
10
|
|
|
11
11
|
{%- if with_footer -%}
|
|
12
12
|
|
|
13
|
-
<footer class="footer small bg-dark text-centos-purple-100 pt-5">
|
|
14
|
-
|
|
15
13
|
{%- assign with_footer_schema = site.data.base.footer_schema.properties.with_footer_data.properties %}
|
|
16
14
|
|
|
15
|
+
{%- assign footer_class = with_footer_data.class | default: with_footer_schema.class.default %}
|
|
17
16
|
{%- assign footer_brand_image = with_footer_data.brand_image | default: with_footer_schema.brand_image.default %}
|
|
18
17
|
{%- assign footer_brand_image_class = with_footer_data.brand_image_class | default: with_footer_schema.brand_image_class.default %}
|
|
19
18
|
{%- assign footer_brand_image_height = with_footer_data.brand_image_height | default: with_footer_schema.brand_image_height.default %}
|
|
20
19
|
{%- assign footer_brand_manifestation = with_footer_data.brand_manifestation | default: with_footer_schema.brand_manifestation.default %}
|
|
21
20
|
{%- assign footer_brand_manifestation_class = with_footer_data.brand_manifestation_class | default: with_footer_schema.brand_manifestation_class.default %}
|
|
22
21
|
|
|
22
|
+
<footer class="{{ footer_class }}">
|
|
23
|
+
|
|
23
24
|
<div class="container">
|
|
24
25
|
<div class="row justify-content-between align-items-start gx-5">
|
|
25
26
|
<div class="col-sm-12 col-lg-4">
|
|
@@ -29,7 +29,6 @@ Optional Inputs:
|
|
|
29
29
|
- page.with_breakingnews_data: Array of breaking news items
|
|
30
30
|
- page.with_backtotop: Include back-to-top button (boolean)
|
|
31
31
|
- page.with_copyvalue: Include copy-to-clipboard behavior (boolean)
|
|
32
|
-
- page.with_heading_anchor: Include heading anchor copy behavior (boolean)
|
|
33
32
|
- page.theme_color, site.theme_color: Override browser chrome color (default: #A54C93)
|
|
34
33
|
================================================================================
|
|
35
34
|
{% endcomment %}
|
|
@@ -141,5 +140,4 @@ Uses CSS custom properties for cleaner, more maintainable dynamic styling.
|
|
|
141
140
|
{%- comment %} JavaScript UI behavior components — depend on Bootstrap and FontAwesome SVG+JS {%- endcomment %}
|
|
142
141
|
{%- include base/backtotop.html.liquid %}
|
|
143
142
|
{%- include base/copyvalue.html.liquid %}
|
|
144
|
-
{%- include base/heading_anchor.html.liquid %}
|
|
145
143
|
</head>
|
|
@@ -130,6 +130,7 @@ Data Object Properties:
|
|
|
130
130
|
|
|
131
131
|
{% capture table %}
|
|
132
132
|
{% assign show_page_filename = include.show_page_filename | default: "false" %}
|
|
133
|
+
<div class="table-responsive bg-light border rounded mb-3">
|
|
133
134
|
<table class="table dataTable">
|
|
134
135
|
<thead>
|
|
135
136
|
<tr>
|
|
@@ -148,14 +149,16 @@ Data Object Properties:
|
|
|
148
149
|
<td>{% include base/link.html.liquid name=item.title link=item.url %}</td>
|
|
149
150
|
{%- endif %}
|
|
150
151
|
{%- endif %}
|
|
151
|
-
<td>{{ item.title_lead | strip_newlines | markdownify }}</td>
|
|
152
|
+
<td>{{ item.title_lead | strip_newlines | markdownify | remove: "<p>" | remove: "</p>" | strip }}</td>
|
|
152
153
|
</tr>
|
|
153
154
|
{%- endfor %}
|
|
154
155
|
</tbody>
|
|
155
156
|
</table>
|
|
157
|
+
</div>
|
|
156
158
|
{%- endcapture %}
|
|
157
159
|
|
|
158
160
|
{% capture component_table %}
|
|
161
|
+
<div class="table-responsive bg-light border rounded mb-3">
|
|
159
162
|
<table class="table dataTable">
|
|
160
163
|
<thead>
|
|
161
164
|
<tr>
|
|
@@ -181,11 +184,12 @@ Data Object Properties:
|
|
|
181
184
|
<tr>
|
|
182
185
|
<td>{% include base/link.html.liquid name=item.component.name link=item.url %}</td>
|
|
183
186
|
<td class="text-nowrap">{{ status_icon }}</td>
|
|
184
|
-
<td>{{ item.title_lead | strip_newlines | markdownify }}</td>
|
|
187
|
+
<td>{{ item.title_lead | strip_newlines | markdownify | remove: "<p>" | remove: "</p>" | strip }}</td>
|
|
185
188
|
</tr>
|
|
186
189
|
{%- endfor %}
|
|
187
190
|
</tbody>
|
|
188
191
|
</table>
|
|
192
|
+
</div>
|
|
189
193
|
{% endcapture %}
|
|
190
194
|
|
|
191
195
|
{% case format %}
|
|
@@ -24,6 +24,9 @@ Optional Inputs (from include):
|
|
|
24
24
|
- data: Title configuration object
|
|
25
25
|
- column_class: Bootstrap column class for the row wrapper (set by the layout to
|
|
26
26
|
keep this component aligned with the content column; defaults to "col")
|
|
27
|
+
- row_class: Bootstrap class(es) for the row wrapper (set by the layout to
|
|
28
|
+
keep this component's row aligned with breadcrumb, artwork, toc, and
|
|
29
|
+
content; defaults to "row mb-3")
|
|
27
30
|
|
|
28
31
|
Data Source Hierarchy (in priority order):
|
|
29
32
|
1. include.data - Explicitly passed configuration
|
|
@@ -57,8 +60,9 @@ Conditional Logic:
|
|
|
57
60
|
{%- assign title_lead = with_title_data.title_lead | default: page.title_lead %}
|
|
58
61
|
{%- assign title_lead_class = with_title_data.title_lead_class | default: with_title_schema.title_lead_class.default %}
|
|
59
62
|
{%- assign column_class = include.column_class | default: 'col' %}
|
|
63
|
+
{%- assign row_class = include.row_class | default: 'row mb-3' %}
|
|
60
64
|
|
|
61
|
-
<div class="
|
|
65
|
+
<div class="{{ row_class }}">
|
|
62
66
|
<div class="{{ column_class }}">
|
|
63
67
|
<div class="{{ class }}">
|
|
64
68
|
<p class="{{ title_class }}">{{ title }}</p>
|
|
@@ -33,6 +33,9 @@ Optional Inputs (from include):
|
|
|
33
33
|
- data: TOC configuration object
|
|
34
34
|
- column_class: Bootstrap column class for the row wrapper (set by the layout to
|
|
35
35
|
keep this component aligned with the content column; defaults to "col")
|
|
36
|
+
- row_class: Bootstrap class(es) for the row wrapper (set by the layout to
|
|
37
|
+
keep this component's row aligned with breadcrumb, title, artwork, and
|
|
38
|
+
content; defaults to "row mb-3")
|
|
36
39
|
|
|
37
40
|
Data Source Hierarchy (in priority order):
|
|
38
41
|
- with_toc: include.with_toc → page.with_toc
|
|
@@ -62,11 +65,12 @@ Data Source Hierarchy (in priority order):
|
|
|
62
65
|
{%- assign skip_no_ids = with_toc_data.skip_no_ids | default: with_toc_schema["skip_no_ids"].default %}
|
|
63
66
|
{%- assign flat_toc = with_toc_data.flat_toc | default: with_toc_schema["flat_toc"].default %}
|
|
64
67
|
{%- assign column_class = include.column_class | default: 'col' %}
|
|
68
|
+
{%- assign row_class = include.row_class | default: 'row mb-3' %}
|
|
65
69
|
|
|
66
70
|
{%- comment %} === Presentation === {% endcomment %}
|
|
67
71
|
|
|
68
72
|
{%- comment %} --- HTML --- {% endcomment %}
|
|
69
|
-
<div class="
|
|
73
|
+
<div class="{{ row_class }}">
|
|
70
74
|
<div class="{{ column_class }}">
|
|
71
75
|
<div class="accordion shadow-sm" id="pageToc">
|
|
72
76
|
<div class="accordion-item">
|
data/_layouts/base/default.html
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
<!doctype html>
|
|
2
2
|
<html lang="{{ page.lang | default: 'en' }}"{% if page.with_ogp %} prefix="og: https://ogp.me/ns#"{% endif %}>
|
|
3
3
|
{% include base/head.html.liquid -%}
|
|
4
|
-
<body id="top" class="bg-body{% if page.with_navbar %} has-navbar{% endif %}">
|
|
4
|
+
<body id="top" class="{{ page.body_class | default: 'bg-body' }}{% if page.with_navbar %} has-navbar{% endif %}">
|
|
5
5
|
|
|
6
6
|
{% include base/navbar.html.liquid -%}
|
|
7
7
|
|
|
@@ -9,34 +9,7 @@
|
|
|
9
9
|
|
|
10
10
|
{% include base/breakingnews.html.liquid -%}
|
|
11
11
|
|
|
12
|
-
{
|
|
13
|
-
| default: site.data.content
|
|
14
|
-
| default: site.data.base.content
|
|
15
|
-
-%}
|
|
16
|
-
{%- assign content_schema = site.data.content_schema | default: site.data.base.content_schema -%}
|
|
17
|
-
{%- assign content_class = with_content_data.class
|
|
18
|
-
| default: content_schema.properties.with_content_data.properties.class.default
|
|
19
|
-
| default: 'col' -%}
|
|
20
|
-
|
|
21
|
-
<main class="container py-3">
|
|
22
|
-
|
|
23
|
-
{%- include base/announcement.html.liquid %}
|
|
24
|
-
|
|
25
|
-
{% include base/bits.html.liquid %}
|
|
26
|
-
|
|
27
|
-
{% include base/event.html.liquid %}
|
|
28
|
-
|
|
29
|
-
{% include base/breadcrumb.html.liquid column_class=content_class %}
|
|
30
|
-
|
|
31
|
-
{% include base/title.html.liquid column_class=content_class %}
|
|
32
|
-
|
|
33
|
-
{% include base/artwork.html.liquid column_class=content_class %}
|
|
34
|
-
|
|
35
|
-
{% include base/toc.html.liquid column_class=content_class %}
|
|
36
|
-
|
|
37
|
-
{% include base/content.html.liquid column_class=content_class %}
|
|
38
|
-
|
|
39
|
-
</main>
|
|
12
|
+
{% include base/content.html.liquid %}
|
|
40
13
|
|
|
41
14
|
{% include base/footer.html.liquid %}
|
|
42
15
|
</body>
|
|
@@ -281,13 +281,13 @@ main {
|
|
|
281
281
|
opacity: 1;
|
|
282
282
|
transform: translateX(-100%);
|
|
283
283
|
}
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
284
|
+
// Plain "#" glyph — replaces the Font Awesome icon so this component has no
|
|
285
|
+
// icon-font dependency; font-style reset since it's text, not an icon glyph.
|
|
286
|
+
.heading-anchor-hash {
|
|
287
|
+
font-style: normal;
|
|
288
288
|
}
|
|
289
|
-
.heading-anchor
|
|
290
|
-
|
|
289
|
+
.heading-anchor-hash::before {
|
|
290
|
+
content: "#";
|
|
291
291
|
}
|
|
292
292
|
|
|
293
293
|
// Accordion containers' bottom clearance — same as the headings/figure
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: jekyll-theme-centos
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 2.52.0.beta.
|
|
4
|
+
version: 2.52.0.beta.96
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Alain Reguera Delgado
|
|
@@ -280,6 +280,7 @@ extensions: []
|
|
|
280
280
|
extra_rdoc_files: []
|
|
281
281
|
files:
|
|
282
282
|
- _config.yml
|
|
283
|
+
- _data/base/accordion_schema.yml
|
|
283
284
|
- _data/base/announcement_schema.yml
|
|
284
285
|
- _data/base/artwork_schema.yml
|
|
285
286
|
- _data/base/backtotop_schema.yml
|
|
@@ -326,7 +327,8 @@ files:
|
|
|
326
327
|
- _data/base/sponsors_schema.yml
|
|
327
328
|
- _data/base/title_schema.yml
|
|
328
329
|
- _data/base/toc_schema.yml
|
|
329
|
-
- _includes/base/
|
|
330
|
+
- _includes/base/accordion-item.html.liquid
|
|
331
|
+
- _includes/base/accordion.html.liquid
|
|
330
332
|
- _includes/base/announcement.html.liquid
|
|
331
333
|
- _includes/base/artwork.html.liquid
|
|
332
334
|
- _includes/base/backtotop.html.liquid
|
|
@@ -356,7 +358,6 @@ files:
|
|
|
356
358
|
- _includes/base/fontawesome.html.liquid
|
|
357
359
|
- _includes/base/footer.html.liquid
|
|
358
360
|
- _includes/base/head.html.liquid
|
|
359
|
-
- _includes/base/heading_anchor.html.liquid
|
|
360
361
|
- _includes/base/highlight.html.liquid
|
|
361
362
|
- _includes/base/image.html.liquid
|
|
362
363
|
- _includes/base/link.html.liquid
|
|
@@ -516,7 +517,6 @@ files:
|
|
|
516
517
|
- assets/js/base/backtotop.js
|
|
517
518
|
- assets/js/base/copyvalue.js
|
|
518
519
|
- assets/js/base/datatable.js
|
|
519
|
-
- assets/js/base/heading-anchor.js
|
|
520
520
|
- assets/js/base/highlight.js
|
|
521
521
|
- assets/js/base/init-tooltips.js
|
|
522
522
|
- assets/js/bootstrap.bundle.js
|
|
@@ -1,40 +0,0 @@
|
|
|
1
|
-
{% comment %}
|
|
2
|
-
================================================================================
|
|
3
|
-
Utility: Accordion Item
|
|
4
|
-
Purpose: The Bootstrap accordion-item/header/button/collapse/body shell,
|
|
5
|
-
shared across components. Used by the four sibling sections below a
|
|
6
|
-
release's architecture grid (Screenshots, Documentation, Migration,
|
|
7
|
-
End-of-life — see download_sections.html.liquid for how these compose into
|
|
8
|
-
one shared accordion) and by the bits component's accordion downstream
|
|
9
|
-
style (see bits.html.liquid). Body content is built by the caller via a
|
|
10
|
-
capture tag and passed in as a pre-rendered HTML string, since Jekyll's
|
|
11
|
-
Liquid include mechanism has no block/yield content-passing.
|
|
12
|
-
|
|
13
|
-
Required Inputs:
|
|
14
|
-
- icon: Font Awesome icon class shown before the title.
|
|
15
|
-
- title: Accordion button label text.
|
|
16
|
-
- item_id: This item's unique collapse id.
|
|
17
|
-
- accordion_id: Parent accordion's id, for data-bs-parent scoping.
|
|
18
|
-
- expanded: true starts this item open; false starts it closed.
|
|
19
|
-
- body: Pre-rendered HTML string (built via a capture tag at the
|
|
20
|
-
call site) for the accordion-body's contents.
|
|
21
|
-
|
|
22
|
-
Optional Inputs:
|
|
23
|
-
- body_class: Extra classes appended to "accordion-body" (e.g.
|
|
24
|
-
"d-flex flex-wrap gap-2", "p-0"). Omit for a plain
|
|
25
|
-
accordion-body.
|
|
26
|
-
================================================================================
|
|
27
|
-
{% endcomment %}
|
|
28
|
-
<div class="accordion-item">
|
|
29
|
-
<div class="accordion-header h2">
|
|
30
|
-
<button class="accordion-button{% unless include.expanded %} collapsed{% endunless %}" type="button" data-bs-toggle="collapse" data-bs-target="#{{ include.item_id }}" aria-expanded="{{ include.expanded }}" aria-controls="{{ include.item_id }}">
|
|
31
|
-
<i class="{{ include.icon }} me-2"></i>
|
|
32
|
-
<span class="ms-1 fw-bold">{{ include.title }}</span>
|
|
33
|
-
</button>
|
|
34
|
-
</div>
|
|
35
|
-
<div id="{{ include.item_id }}" class="accordion-collapse collapse{% if include.expanded %} show{% endif %}" data-bs-parent="#{{ include.accordion_id }}">
|
|
36
|
-
<div class="accordion-body{% if include.body_class and include.body_class != "" %} {{ include.body_class }}{% endif %}">
|
|
37
|
-
{{ include.body }}
|
|
38
|
-
</div>
|
|
39
|
-
</div>
|
|
40
|
-
</div>
|
|
@@ -1,67 +0,0 @@
|
|
|
1
|
-
{% comment %}
|
|
2
|
-
================================================================================
|
|
3
|
-
Template: Heading Anchor Component
|
|
4
|
-
Purpose: Loads heading-anchor.js which wires click-to-copy behaviour on anchor
|
|
5
|
-
icons that jekyll-link-decorator injects inside h1–h6 elements. Clicking an
|
|
6
|
-
anchor icon copies the full page URL (origin + pathname + fragment) to the
|
|
7
|
-
clipboard, with a transient fa-check icon as visual feedback.
|
|
8
|
-
|
|
9
|
-
Recommended Usage (in head.html.liquid):
|
|
10
|
-
{%- include base/heading_anchor.html.liquid %}
|
|
11
|
-
|
|
12
|
-
The heading anchor icons themselves are injected by the jekyll-link-decorator
|
|
13
|
-
Ruby plugin. This include only loads the JavaScript that powers copy behaviour.
|
|
14
|
-
|
|
15
|
-
Required Inputs (from HTML elements produced by the plugin):
|
|
16
|
-
- class="heading-anchor" : Selector used to attach click handlers
|
|
17
|
-
- data-copy-anchor="#id" : Fragment to append to the current page URL
|
|
18
|
-
|
|
19
|
-
Optional Inputs (from data objects):
|
|
20
|
-
- reset_delay : Milliseconds before icon resets (default from schema)
|
|
21
|
-
- copy_success_message : Not consumed by JS directly; available for reference
|
|
22
|
-
|
|
23
|
-
Data Source Hierarchy (in priority order):
|
|
24
|
-
1. include.data - Explicitly passed configuration
|
|
25
|
-
2. page.with_heading_anchor_data - Page front matter
|
|
26
|
-
3. site.data.heading_anchor - Site configuration
|
|
27
|
-
4. site.data.base.heading_anchor - Theme defaults
|
|
28
|
-
|
|
29
|
-
Dependencies:
|
|
30
|
-
jekyll-link-decorator gem, FontAwesome 6+, Clipboard API (modern browsers)
|
|
31
|
-
================================================================================
|
|
32
|
-
{% endcomment %}
|
|
33
|
-
|
|
34
|
-
{%- assign with_heading_anchor = include.with_heading_anchor
|
|
35
|
-
| default: page.with_heading_anchor
|
|
36
|
-
| default: site.with_heading_anchor
|
|
37
|
-
-%}
|
|
38
|
-
|
|
39
|
-
{%- assign with_heading_anchor_data = include.data
|
|
40
|
-
| default: page.with_heading_anchor_data
|
|
41
|
-
| default: site.data.heading_anchor
|
|
42
|
-
| default: site.data.base.heading_anchor
|
|
43
|
-
-%}
|
|
44
|
-
|
|
45
|
-
{%- assign with_heading_anchor_schema = site.data.base.heading_anchor_schema.properties.with_heading_anchor_data.properties -%}
|
|
46
|
-
|
|
47
|
-
{%- if with_heading_anchor -%}
|
|
48
|
-
|
|
49
|
-
{%- comment %} === Presentation === {% endcomment %}
|
|
50
|
-
|
|
51
|
-
{%- comment %} --- Defaults --- {% endcomment %}
|
|
52
|
-
{%- assign heading_anchor_reset_delay = with_heading_anchor_data.reset_delay | default: with_heading_anchor_schema.reset_delay.default -%}
|
|
53
|
-
{%- assign heading_anchor_success_message = with_heading_anchor_data.copy_success_message | default: with_heading_anchor_schema.copy_success_message.default -%}
|
|
54
|
-
|
|
55
|
-
{%- comment %} --- HTML --- {% endcomment %}
|
|
56
|
-
<!-- Load Heading Anchor functionality with configuration via data attributes -->
|
|
57
|
-
<script id="centos-heading-anchor"
|
|
58
|
-
{%- if with_heading_anchor_data.reset_delay %}
|
|
59
|
-
data-reset-delay="{{ heading_anchor_reset_delay }}"
|
|
60
|
-
{%- endif %}
|
|
61
|
-
{%- if with_heading_anchor_data.copy_success_message %}
|
|
62
|
-
data-success-message="{{ heading_anchor_success_message }}"
|
|
63
|
-
{%- endif %}
|
|
64
|
-
src="{{ site.baseurl }}/assets/js/base/heading-anchor.min.js"
|
|
65
|
-
defer></script>
|
|
66
|
-
|
|
67
|
-
{%- endif -%}
|
|
@@ -1,109 +0,0 @@
|
|
|
1
|
-
// Heading Anchor Component — requires Bootstrap >= 5.3 (tooltip.setContent) and Font Awesome 6+
|
|
2
|
-
|
|
3
|
-
document.addEventListener('DOMContentLoaded', () => {
|
|
4
|
-
if (typeof bootstrap === 'undefined') {
|
|
5
|
-
console.warn('heading-anchor: Bootstrap not available')
|
|
6
|
-
return
|
|
7
|
-
}
|
|
8
|
-
|
|
9
|
-
const DEFAULT_TEXT = 'Copy link'
|
|
10
|
-
const scriptEl = document.getElementById('centos-heading-anchor')
|
|
11
|
-
const RESET_DELAY = scriptEl?.dataset.resetDelay
|
|
12
|
-
? parseInt(scriptEl.dataset.resetDelay, 10) : 2000
|
|
13
|
-
const SUCCESS_TEXT = scriptEl?.dataset.successMessage || 'Copied!'
|
|
14
|
-
|
|
15
|
-
// One shared region: multiple regions would cause simultaneous AT announcements per anchor.
|
|
16
|
-
let liveRegion = document.getElementById('centos-heading-anchor-live')
|
|
17
|
-
if (!liveRegion) {
|
|
18
|
-
liveRegion = document.createElement('div')
|
|
19
|
-
liveRegion.id = 'centos-heading-anchor-live'
|
|
20
|
-
liveRegion.setAttribute('aria-live', 'polite')
|
|
21
|
-
liveRegion.setAttribute('aria-atomic', 'true')
|
|
22
|
-
liveRegion.className = 'visually-hidden'
|
|
23
|
-
document.body.appendChild(liveRegion)
|
|
24
|
-
}
|
|
25
|
-
|
|
26
|
-
document.querySelectorAll('.heading-anchor[data-copy-anchor]').forEach(anchor => {
|
|
27
|
-
// FA SVG+JS replaces <i> with <svg> before this DOMContentLoaded fires.
|
|
28
|
-
// Cache innerHTML after FA has processed so it can be restored on reset.
|
|
29
|
-
const originalIconHTML = anchor.innerHTML
|
|
30
|
-
// Guards blur/mouseenter handlers from collapsing the tooltip during the success window.
|
|
31
|
-
let isLocked = false
|
|
32
|
-
|
|
33
|
-
const tooltip = new bootstrap.Tooltip(anchor, {
|
|
34
|
-
title: DEFAULT_TEXT,
|
|
35
|
-
trigger: 'manual', // CSS sets pointer-events:none on hidden anchors, defeating Bootstrap's auto hover/focus triggers.
|
|
36
|
-
placement: 'top',
|
|
37
|
-
animation: false // Prevents Bootstrap's fade and the CSS opacity transition from desyncing.
|
|
38
|
-
})
|
|
39
|
-
|
|
40
|
-
const updateUI = (isSuccess) => {
|
|
41
|
-
tooltip.setContent({ '.tooltip-inner': isSuccess ? SUCCESS_TEXT : DEFAULT_TEXT })
|
|
42
|
-
if (isSuccess) {
|
|
43
|
-
// FA SVG+JS mode: <i> has been replaced by <svg>; swap the path to a checkmark.
|
|
44
|
-
const svg = anchor.querySelector('svg')
|
|
45
|
-
if (svg) {
|
|
46
|
-
const path = svg.querySelector('path')
|
|
47
|
-
if (path) {
|
|
48
|
-
svg.setAttribute('viewBox', '0 0 448 512')
|
|
49
|
-
path.setAttribute('d', 'M434.8 70.1c14.3 10.4 17.5 30.4 7.1 44.7l-256 352c-5.5 7.6-14 12.3-23.4 13.1s-18.5-2.7-25.1-9.3l-128-128c-12.5-12.5-12.5-32.8 0-45.3s32.8-12.5 45.3 0l101.5 101.5 234-321.7c10.4-14.3 30.4-17.5 44.7-7.1z')
|
|
50
|
-
}
|
|
51
|
-
} else {
|
|
52
|
-
// FA webfont mode: <i> is still in the DOM; toggle classes normally.
|
|
53
|
-
const icon = anchor.querySelector('i')
|
|
54
|
-
if (icon) { icon.classList.remove('fa-hashtag'); icon.classList.add('fa-check') }
|
|
55
|
-
}
|
|
56
|
-
} else {
|
|
57
|
-
anchor.innerHTML = originalIconHTML
|
|
58
|
-
}
|
|
59
|
-
anchor.classList.toggle('is-active', isSuccess)
|
|
60
|
-
// Empty string on reset prevents AT from re-announcing stale text on DOM inspection.
|
|
61
|
-
liveRegion.textContent = isSuccess ? SUCCESS_TEXT : ''
|
|
62
|
-
if (isSuccess) tooltip.show()
|
|
63
|
-
}
|
|
64
|
-
|
|
65
|
-
const handleInteraction = (show) => {
|
|
66
|
-
if (!isLocked) show ? tooltip.show() : tooltip.hide()
|
|
67
|
-
}
|
|
68
|
-
|
|
69
|
-
anchor.addEventListener('mouseenter', () => handleInteraction(true))
|
|
70
|
-
anchor.addEventListener('mouseleave', () => handleInteraction(false))
|
|
71
|
-
anchor.addEventListener('focus', () => handleInteraction(true))
|
|
72
|
-
anchor.addEventListener('blur', () => handleInteraction(false))
|
|
73
|
-
|
|
74
|
-
anchor.addEventListener('click', async (e) => {
|
|
75
|
-
e.preventDefault()
|
|
76
|
-
anchor.closest('h1, h2, h3, h4, h5, h6')?.scrollIntoView()
|
|
77
|
-
if (isLocked) return
|
|
78
|
-
|
|
79
|
-
if (!navigator.clipboard) {
|
|
80
|
-
console.warn('heading-anchor: Clipboard API unavailable')
|
|
81
|
-
return
|
|
82
|
-
}
|
|
83
|
-
|
|
84
|
-
const url = window.location.origin + window.location.pathname + anchor.dataset.copyAnchor
|
|
85
|
-
|
|
86
|
-
try {
|
|
87
|
-
await navigator.clipboard.writeText(url)
|
|
88
|
-
isLocked = true
|
|
89
|
-
// isLocked must be true before blur() so the resulting blur event is suppressed
|
|
90
|
-
// and does not hide the tooltip before the success state has been rendered.
|
|
91
|
-
anchor.blur()
|
|
92
|
-
updateUI(true)
|
|
93
|
-
|
|
94
|
-
setTimeout(() => {
|
|
95
|
-
isLocked = false
|
|
96
|
-
updateUI(false)
|
|
97
|
-
// mouseleave/blur events fired while isLocked was true were suppressed;
|
|
98
|
-
// hide now if the user already moved away during the success window.
|
|
99
|
-
if (!anchor.matches(':hover')) tooltip.hide()
|
|
100
|
-
}, RESET_DELAY)
|
|
101
|
-
|
|
102
|
-
} catch (err) {
|
|
103
|
-
console.warn('heading-anchor: clipboard write failed', err)
|
|
104
|
-
isLocked = false
|
|
105
|
-
anchor.innerHTML = originalIconHTML
|
|
106
|
-
}
|
|
107
|
-
})
|
|
108
|
-
})
|
|
109
|
-
})
|