jekyll-theme-centos 2.52.0.beta.104 → 2.52.0.beta.106
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 +2 -2
- data/_data/base/accordion_schema.yml +6 -0
- data/_data/base/announcement_schema.yml +1 -1
- data/_data/base/artwork_schema.yml +17 -3
- data/_data/base/bits_schema.yml +9 -4
- data/_data/base/breadcrumb_schema.yml +14 -0
- data/_data/base/breakingnews_schema.yml +1 -1
- data/_data/base/calendar_schema.yml +17 -2
- data/_data/base/card_schema.yml +2 -2
- data/_data/base/copyright_schema.yml +7 -17
- data/_data/base/copyvalue_schema.yml +4 -1
- data/_data/base/datatable_schema.yml +3 -3
- data/_data/base/download_schema.yml +42 -16
- data/_data/base/event_schema.yml +1 -1
- data/_data/base/footer_schema.yml +7 -6
- data/_data/base/highlight_schema.yml +7 -5
- data/_data/base/image_schema.yml +1 -1
- data/_data/base/link_schema.yml +13 -19
- data/_data/base/navbar_schema.yml +6 -0
- data/_data/base/preview_schema.yml +8 -4
- data/_data/base/project_schema.yml +4 -2
- data/_data/base/script_schema.yml +4 -4
- data/_data/base/shortcut_schema.yml +2 -2
- data/_data/base/social_schema.yml +2 -2
- data/_data/base/sponsors.yml +3 -2
- data/_data/base/sponsors_schema.yml +20 -0
- data/_data/base/title_schema.yml +14 -0
- data/_data/base/toc_schema.yml +16 -2
- data/_includes/base/accordion-item.html.liquid +11 -32
- data/_includes/base/accordion.html.liquid +3 -29
- data/_includes/base/announcement.html.liquid +8 -35
- data/_includes/base/artwork.html.liquid +5 -38
- data/_includes/base/backtotop.html.liquid +3 -42
- data/_includes/base/bits.html.liquid +26 -74
- data/_includes/base/breadcrumb.html.liquid +15 -49
- data/_includes/base/breakingnews.html.liquid +6 -43
- data/_includes/base/calendar-events.html.liquid +3 -37
- data/_includes/base/calendar-init.html.liquid +7 -63
- data/_includes/base/calendar.html.liquid +3 -34
- data/_includes/base/card.html.liquid +4 -44
- data/_includes/base/color-table.html.liquid +18 -4
- data/_includes/base/configuration_variables-default-cell.html.liquid +6 -50
- data/_includes/base/configuration_variables-nested.html.liquid +6 -7
- data/_includes/base/configuration_variables.html.liquid +9 -11
- data/_includes/base/content.html.liquid +7 -4
- data/_includes/base/copyright.html.liquid +8 -39
- data/_includes/base/copyvalue.html.liquid +3 -70
- data/_includes/base/datatable.html.liquid +4 -40
- data/_includes/base/download.html.liquid +12 -66
- data/_includes/base/download_architecture.html.liquid +29 -117
- data/_includes/base/download_commands.html.liquid +2 -14
- data/_includes/base/download_documentation.html.liquid +13 -47
- data/_includes/base/download_eol.html.liquid +5 -15
- data/_includes/base/download_filevalue.html.liquid +9 -49
- data/_includes/base/download_screenshots.html.liquid +10 -65
- data/_includes/base/download_sections.html.liquid +2 -19
- data/_includes/base/event.html.liquid +8 -63
- data/_includes/base/fontawesome.html.liquid +4 -38
- data/_includes/base/footer.html.liquid +9 -2
- data/_includes/base/head.html.liquid +6 -47
- data/_includes/base/highlight.html.liquid +4 -37
- data/_includes/base/image.html.liquid +5 -22
- data/_includes/base/link.html.liquid +38 -57
- data/_includes/base/locales.html.liquid +6 -26
- data/_includes/base/navbar.html.liquid +16 -45
- data/_includes/base/navindex.html.liquid +40 -111
- data/_includes/base/ogp.html.liquid +17 -83
- data/_includes/base/preview.html.liquid +18 -57
- data/_includes/base/project.html.liquid +4 -29
- data/_includes/base/shortcut.html.liquid +7 -37
- data/_includes/base/social.html.liquid +4 -42
- data/_includes/base/sponsors-cards.html.liquid +4 -55
- data/_includes/base/sponsors-carousel.html.liquid +11 -59
- data/_includes/base/sponsors-data.html.liquid +32 -0
- data/_includes/base/title.html.liquid +5 -42
- data/_includes/base/toc-generator.html.liquid +4 -0
- data/_includes/base/toc.html.liquid +28 -81
- data/_sass/base/_customization.scss +18 -0
- data/_sass/base/_preview.scss +5 -9
- data/assets/icons/favicon.ico +0 -0
- data/assets/js/base/backtotop.js +3 -3
- data/assets/js/base/copyvalue.js +15 -11
- data/assets/js/base/datatable.js +6 -13
- data/assets/js/base/highlight.js +46 -31
- metadata +2 -1
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
{% comment %}
|
|
2
|
+
sponsors-data: renders nothing; it sets the sponsors gate, data, and each member's logo src for sponsors-cards and sponsors-carousel.
|
|
3
|
+
Data: include.data > page.with_sponsors_data > site.data.sponsors > site.data.base.sponsors
|
|
4
|
+
Schema: src/YAML/sponsors_schema.yml
|
|
5
|
+
{% endcomment %}
|
|
6
|
+
|
|
7
|
+
{%- comment %} Include assigns are global, so every value the callers read is reset here on each call. {% endcomment %}
|
|
8
|
+
{%- assign sponsors_member_srcs = "" | split: "" %}
|
|
9
|
+
|
|
10
|
+
{%- assign with_sponsors = include.with_sponsors
|
|
11
|
+
| default: page.with_sponsors
|
|
12
|
+
%}
|
|
13
|
+
|
|
14
|
+
{%- assign with_sponsors_data = include.data
|
|
15
|
+
| default: page.with_sponsors_data
|
|
16
|
+
| default: site.data.sponsors
|
|
17
|
+
| default: site.data.base.sponsors
|
|
18
|
+
%}
|
|
19
|
+
|
|
20
|
+
{%- assign with_sponsors_schema = site.data.base.sponsors_schema.properties.with_sponsors_data.properties %}
|
|
21
|
+
{%- assign sponsors_members = with_sponsors_data.members | default: with_sponsors_schema.members.default %}
|
|
22
|
+
{%- assign sponsors_image_base = with_sponsors_data.image_base_path | default: with_sponsors_schema.image_base_path.default %}
|
|
23
|
+
|
|
24
|
+
{%- comment %} sponsors_member_srcs lines up with sponsors_members by index, so callers read it with forloop.index0. {% endcomment %}
|
|
25
|
+
{%- for member in sponsors_members %}
|
|
26
|
+
{%- if member.image contains "://" %}
|
|
27
|
+
{%- assign sponsors_member_src = member.image %}
|
|
28
|
+
{%- else %}
|
|
29
|
+
{%- assign sponsors_member_src = site.baseurl | append: sponsors_image_base | append: member.image %}
|
|
30
|
+
{%- endif %}
|
|
31
|
+
{%- assign sponsors_member_srcs = sponsors_member_srcs | push: sponsors_member_src %}
|
|
32
|
+
{%- endfor -%}
|
|
@@ -1,42 +1,7 @@
|
|
|
1
1
|
{% comment %}
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
primary heading and descriptive lead with customizable styling.
|
|
6
|
-
================================================================================
|
|
7
|
-
|
|
8
|
-
Strategic Design Logic:
|
|
9
|
-
- Semantic headings: h1 primary, lead text for subtitle
|
|
10
|
-
- Data source hierarchy: flexible configuration
|
|
11
|
-
- Customizable styling: class overrides per element
|
|
12
|
-
- Optional lead text: subtitle/description support
|
|
13
|
-
- Schema-based defaults: consistent styling
|
|
14
|
-
- Responsive layout: bootstrap grid
|
|
15
|
-
|
|
16
|
-
Required Inputs (from data objects):
|
|
17
|
-
None - uses page.title as fallback
|
|
18
|
-
|
|
19
|
-
Optional Inputs (from data objects):
|
|
20
|
-
- title: Page heading text (defaults to page.title)
|
|
21
|
-
- title_lead: Subtitle/description text
|
|
22
|
-
|
|
23
|
-
Optional Inputs (from include):
|
|
24
|
-
- data: Title configuration object
|
|
25
|
-
- column_class: Bootstrap column class for the row wrapper (set by the layout to
|
|
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")
|
|
30
|
-
|
|
31
|
-
Data Source Hierarchy (in priority order):
|
|
32
|
-
1. include.data - Explicitly passed configuration
|
|
33
|
-
2. page.with_title_data - Page front matter
|
|
34
|
-
3. site.data.title - Site configuration
|
|
35
|
-
4. site.data.base.title - Theme defaults
|
|
36
|
-
|
|
37
|
-
Conditional Logic:
|
|
38
|
-
- title_lead present: Only renders subtitle if not empty
|
|
39
|
-
================================================================================
|
|
2
|
+
title: renders the page title and optional lead inside a row and column; content.html.liquid sets row_class and column_class.
|
|
3
|
+
Data: include.data > page.with_title_data > site.data.title > site.data.base.title
|
|
4
|
+
Schema: src/YAML/title_schema.yml
|
|
40
5
|
{% endcomment %}
|
|
41
6
|
|
|
42
7
|
{%- assign with_title = include.with_title
|
|
@@ -52,15 +17,13 @@ Conditional Logic:
|
|
|
52
17
|
{%- if with_title -%}
|
|
53
18
|
|
|
54
19
|
{%- assign with_title_schema = site.data.base.title_schema.properties.with_title_data.properties %}
|
|
55
|
-
|
|
56
|
-
{%- comment %} === Presentation === {% endcomment %}
|
|
57
20
|
{%- assign class = with_title_data.class | default: with_title_schema.class.default %}
|
|
58
21
|
{%- assign title = with_title_data.title | default: page.title %}
|
|
59
22
|
{%- assign title_class = with_title_data.title_class | default: with_title_schema.title_class.default %}
|
|
60
23
|
{%- assign title_lead = with_title_data.title_lead | default: page.title_lead %}
|
|
61
24
|
{%- assign title_lead_class = with_title_data.title_lead_class | default: with_title_schema.title_lead_class.default %}
|
|
62
|
-
{%- assign column_class = include.column_class | default:
|
|
63
|
-
{%- assign row_class = include.row_class | default:
|
|
25
|
+
{%- assign column_class = include.column_class | default: site.data.base.content_schema.properties.with_content_data.properties.col_class.default %}
|
|
26
|
+
{%- assign row_class = include.row_class | default: site.data.base.content_schema.properties.with_content_data.properties.row_class.default %}
|
|
64
27
|
|
|
65
28
|
<div class="{{ row_class }}">
|
|
66
29
|
<div class="{{ column_class }}">
|
|
@@ -1,3 +1,7 @@
|
|
|
1
|
+
{% comment %}
|
|
2
|
+
toc-generator: renders a nested list of links to the headings in include.html (vendored allejo/jekyll-toc, MIT license below).
|
|
3
|
+
{% endcomment %}
|
|
4
|
+
{%- comment %} trim leading output {% endcomment -%}
|
|
1
5
|
{% capture tocWorkspace %}
|
|
2
6
|
{% comment %}
|
|
3
7
|
Copyright (c) 2017 Vladimir "allejo" Jimenez
|
|
@@ -1,46 +1,7 @@
|
|
|
1
1
|
{% comment %}
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
using Jekyll-TOC generator. Displays in collapsible Bootstrap accordion.
|
|
6
|
-
================================================================================
|
|
7
|
-
|
|
8
|
-
Strategic Design Logic:
|
|
9
|
-
- Accordion wrapper: collapsible expandable container
|
|
10
|
-
- Heading extraction: automatic from page content
|
|
11
|
-
- Hierarchy support: nested outline structure
|
|
12
|
-
- Configuration-driven: customizable via data object
|
|
13
|
-
- Automatic anchor generation: heading IDs for linking
|
|
14
|
-
- Responsive: works on all screen sizes
|
|
15
|
-
|
|
16
|
-
Required Inputs (from page object):
|
|
17
|
-
- content: Page HTML content (automatically generated)
|
|
18
|
-
|
|
19
|
-
Optional Inputs (from data objects):
|
|
20
|
-
- class: Container CSS classes
|
|
21
|
-
- id: TOC wrapper ID (default: "page-toc")
|
|
22
|
-
- item_class: TOC item CSS classes (default: "my-2")
|
|
23
|
-
- anchor_class: Anchor link CSS classes
|
|
24
|
-
- h_min/h_max: Heading level range (h2-h4 typical)
|
|
25
|
-
- ordered: Use ordered list (true/false)
|
|
26
|
-
- submenu_class: Submenu CSS classes
|
|
27
|
-
- base_url: Base URL for anchors
|
|
28
|
-
- sanitize: Clean HTML in headings (boolean)
|
|
29
|
-
- skip_no_ids: Skip headings without IDs (boolean)
|
|
30
|
-
- flat_toc: Flatten hierarchy (boolean)
|
|
31
|
-
|
|
32
|
-
Optional Inputs (from include):
|
|
33
|
-
- data: TOC configuration object
|
|
34
|
-
- column_class: Bootstrap column class for the row wrapper (set by the layout to
|
|
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")
|
|
39
|
-
|
|
40
|
-
Data Source Hierarchy (in priority order):
|
|
41
|
-
- with_toc: include.with_toc → page.with_toc
|
|
42
|
-
- with_toc_data: include.data → page.with_toc_data → site.data.toc → site.data.base.toc
|
|
43
|
-
================================================================================
|
|
2
|
+
toc: renders a collapsible "On this page" accordion holding a table of contents built from the page content; content.html.liquid sets row_class and column_class.
|
|
3
|
+
Data: include.data > page.with_toc_data > site.data.toc > site.data.base.toc
|
|
4
|
+
Schema: src/YAML/toc_schema.yml
|
|
44
5
|
{% endcomment %}
|
|
45
6
|
|
|
46
7
|
{%- assign with_toc = include.with_toc
|
|
@@ -50,11 +11,9 @@ Data Source Hierarchy (in priority order):
|
|
|
50
11
|
{%- if with_toc -%}
|
|
51
12
|
{%- assign with_toc_data = include.data | default: page.with_toc_data | default: site.data.toc | default: site.data.base.toc %}
|
|
52
13
|
{%- assign with_toc_schema = site.data.base.toc_schema.properties["with_toc_data"].properties %}
|
|
53
|
-
|
|
54
|
-
{%- comment %} === Configuration properties === {% endcomment %}
|
|
55
14
|
{%- assign class = with_toc_data.class | default: with_toc_schema["class"].default %}
|
|
56
|
-
{%- assign id = with_toc_data.id | default: with_toc_schema["id"].default
|
|
57
|
-
{%- assign item_class = with_toc_data.item_class | default: with_toc_schema["item_class"].default
|
|
15
|
+
{%- assign id = with_toc_data.id | default: with_toc_schema["id"].default %}
|
|
16
|
+
{%- assign item_class = with_toc_data.item_class | default: with_toc_schema["item_class"].default %}
|
|
58
17
|
{%- assign anchor_class = with_toc_data.anchor_class | default: with_toc_schema["anchor_class"].default | default: site.with_link_decorator_data.default_link_classes %}
|
|
59
18
|
{%- assign h_min = with_toc_data.h_min | default: with_toc_schema["h_min"].default %}
|
|
60
19
|
{%- assign h_max = with_toc_data.h_max | default: with_toc_schema["h_max"].default %}
|
|
@@ -64,43 +23,31 @@ Data Source Hierarchy (in priority order):
|
|
|
64
23
|
{%- assign sanitize = with_toc_data.sanitize | default: with_toc_schema["sanitize"].default %}
|
|
65
24
|
{%- assign skip_no_ids = with_toc_data.skip_no_ids | default: with_toc_schema["skip_no_ids"].default %}
|
|
66
25
|
{%- assign flat_toc = with_toc_data.flat_toc | default: with_toc_schema["flat_toc"].default %}
|
|
67
|
-
{%- assign column_class = include.column_class | default:
|
|
68
|
-
{%- assign row_class = include.row_class | default:
|
|
69
|
-
|
|
70
|
-
{%- comment %} === Presentation === {% endcomment %}
|
|
71
|
-
|
|
72
|
-
{%- comment %} --- HTML --- {% endcomment %}
|
|
26
|
+
{%- assign column_class = include.column_class | default: site.data.base.content_schema.properties.with_content_data.properties.col_class.default %}
|
|
27
|
+
{%- assign row_class = include.row_class | default: site.data.base.content_schema.properties.with_content_data.properties.row_class.default %}
|
|
73
28
|
<div class="{{ row_class }}">
|
|
74
29
|
<div class="{{ column_class }}">
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
sanitize=sanitize
|
|
97
|
-
skip_no_ids=skip_no_ids
|
|
98
|
-
flat_toc=flat_toc
|
|
99
|
-
%}
|
|
100
|
-
</div>
|
|
101
|
-
</div>
|
|
102
|
-
</div>
|
|
103
|
-
</div>
|
|
30
|
+
{%- capture toc_body %}
|
|
31
|
+
{%- include base/toc-generator.html.liquid
|
|
32
|
+
id=id
|
|
33
|
+
html=content
|
|
34
|
+
class=class
|
|
35
|
+
item_class=item_class
|
|
36
|
+
anchor_class=anchor_class
|
|
37
|
+
h_min=h_min
|
|
38
|
+
h_max=h_max
|
|
39
|
+
ordered=ordered
|
|
40
|
+
submenu_class=submenu_class
|
|
41
|
+
base_url=base_url
|
|
42
|
+
sanitize=sanitize
|
|
43
|
+
skip_no_ids=skip_no_ids
|
|
44
|
+
flat_toc=flat_toc
|
|
45
|
+
%}
|
|
46
|
+
{%- endcapture %}
|
|
47
|
+
{%- capture toc_items %}
|
|
48
|
+
{%- include base/accordion-item.html.liquid icon="fa-solid fa-list" title="On this page" title_class="ms-2 fw-bold" header_class="" item_id="flush-collapseOne" accordion_id="pageToc" body_class="small" body=toc_body %}
|
|
49
|
+
{%- endcapture %}
|
|
50
|
+
{%- include base/accordion.html.liquid id="pageToc" class="shadow-sm" items=toc_items %}
|
|
104
51
|
</div>
|
|
105
52
|
</div>
|
|
106
53
|
{%- endif -%}
|
|
@@ -392,3 +392,21 @@ body.has-navbar main {
|
|
|
392
392
|
scroll-margin-top: 80px;
|
|
393
393
|
}
|
|
394
394
|
}
|
|
395
|
+
|
|
396
|
+
// --------------------------------------------------------------------------------
|
|
397
|
+
// Sponsor logos
|
|
398
|
+
// --------------------------------------------------------------------------------
|
|
399
|
+
// Caps logo size in sponsors-cards (card and image) and sponsors-carousel (image).
|
|
400
|
+
// Bootstrap has no max-height/max-width utilities beyond mh-100/mw-100, and a
|
|
401
|
+
// class keeps the size out of inline styles, which html-validate flags.
|
|
402
|
+
.sponsors-logo {
|
|
403
|
+
max-height: 60px;
|
|
404
|
+
max-width: 242px;
|
|
405
|
+
}
|
|
406
|
+
|
|
407
|
+
// Fixed slide box so the carousel keeps a stable height as logos of
|
|
408
|
+
// different sizes fade in and out.
|
|
409
|
+
.sponsors-carousel-slide {
|
|
410
|
+
height: 80px;
|
|
411
|
+
width: 262px;
|
|
412
|
+
}
|
data/_sass/base/_preview.scss
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
// Preview component: demo, toolbar, and code row layout
|
|
3
3
|
// ================================================================================
|
|
4
4
|
// Styles the three-row layout preview.html.liquid can render: a live demo,
|
|
5
|
-
// a toolbar (language name and copy button), and a code sample. The rows
|
|
5
|
+
// a toolbar (language name and/or copy button), and a code sample. The rows
|
|
6
6
|
// sit flush against each other and the box, with no gaps or padding of
|
|
7
7
|
// their own. The plain, single-row layout (just `content`, no `language`
|
|
8
8
|
// or `code`) uses none of these classes, so none of these rules apply.
|
|
@@ -13,20 +13,16 @@
|
|
|
13
13
|
// another row, so it never doubles up with the box's outer border.
|
|
14
14
|
//
|
|
15
15
|
// Every code block on the site — plain Markdown or built with the
|
|
16
|
-
// preview component — gets the same
|
|
17
|
-
//
|
|
18
|
-
// copyvalue.html.liquid
|
|
16
|
+
// preview component — gets the same frame and code row via highlight.js.
|
|
17
|
+
// The toolbar only renders when it has content: a declared language, or a
|
|
18
|
+
// copy button when copyvalue.html.liquid is on. Without a toolbar, the
|
|
19
|
+
// code row sits directly under the demo row or the box's top edge.
|
|
19
20
|
//
|
|
20
21
|
// Long code blocks are capped at 50vh with a scrollbar, so one long
|
|
21
22
|
// sample can't stretch the whole page.
|
|
22
23
|
// ================================================================================
|
|
23
24
|
|
|
24
25
|
.preview {
|
|
25
|
-
> .preview-content + .preview-toolbar,
|
|
26
|
-
> .preview-toolbar + .preview-code {
|
|
27
|
-
margin-top: $spacer * 0.75;
|
|
28
|
-
}
|
|
29
|
-
|
|
30
26
|
.preview-toolbar {
|
|
31
27
|
display: flex;
|
|
32
28
|
flex-wrap: wrap;
|
data/assets/icons/favicon.ico
CHANGED
|
Binary file
|
data/assets/js/base/backtotop.js
CHANGED
|
@@ -15,9 +15,9 @@ document.addEventListener('DOMContentLoaded', () => {
|
|
|
15
15
|
}
|
|
16
16
|
|
|
17
17
|
const config = {
|
|
18
|
-
diameter: parseInt(scriptTag.dataset.diameter
|
|
19
|
-
backgroundColor: scriptTag.dataset.backgroundColor
|
|
20
|
-
textColor: scriptTag.dataset.textColor
|
|
18
|
+
diameter: parseInt(scriptTag.dataset.diameter, 10),
|
|
19
|
+
backgroundColor: scriptTag.dataset.backgroundColor,
|
|
20
|
+
textColor: scriptTag.dataset.textColor
|
|
21
21
|
}
|
|
22
22
|
|
|
23
23
|
addBackToTop(config)
|
data/assets/js/base/copyvalue.js
CHANGED
|
@@ -3,13 +3,13 @@
|
|
|
3
3
|
|
|
4
4
|
(function () {
|
|
5
5
|
class CopyButtonHandler {
|
|
6
|
-
constructor (button, config
|
|
6
|
+
constructor (button, config) {
|
|
7
7
|
this.button = button
|
|
8
8
|
this.originalTitle = button.getAttribute('data-bs-title') || button.getAttribute('aria-label') || button.getAttribute('title')
|
|
9
|
-
this.resetDelay = config.resetDelay
|
|
10
|
-
this.checkmarkPath = config.checkmarkPath
|
|
11
|
-
this.checkmarkViewbox = config.checkmarkViewbox
|
|
12
|
-
this.successMessage = config.successMessage
|
|
9
|
+
this.resetDelay = config.resetDelay
|
|
10
|
+
this.checkmarkPath = config.checkmarkPath
|
|
11
|
+
this.checkmarkViewbox = config.checkmarkViewbox
|
|
12
|
+
this.successMessage = config.successMessage
|
|
13
13
|
this.originalIcon = this._captureIcon()
|
|
14
14
|
}
|
|
15
15
|
|
|
@@ -115,13 +115,17 @@ class CopyButtonHandler {
|
|
|
115
115
|
|
|
116
116
|
document.addEventListener('DOMContentLoaded', function () {
|
|
117
117
|
const scriptElement = document.getElementById('centos-copyvalue')
|
|
118
|
-
const config = {}
|
|
119
118
|
|
|
120
|
-
if (scriptElement) {
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
119
|
+
if (!scriptElement) {
|
|
120
|
+
console.warn('Copy Value: script tag with id "centos-copyvalue" not found')
|
|
121
|
+
return
|
|
122
|
+
}
|
|
123
|
+
|
|
124
|
+
const config = {
|
|
125
|
+
resetDelay: parseInt(scriptElement.dataset.resetDelay, 10),
|
|
126
|
+
checkmarkPath: scriptElement.dataset.checkmarkPath,
|
|
127
|
+
checkmarkViewbox: scriptElement.dataset.checkmarkViewbox,
|
|
128
|
+
successMessage: scriptElement.dataset.successMessage
|
|
125
129
|
}
|
|
126
130
|
|
|
127
131
|
const handlers = new WeakMap()
|
data/assets/js/base/datatable.js
CHANGED
|
@@ -18,15 +18,8 @@ document.addEventListener('DOMContentLoaded', () => {
|
|
|
18
18
|
return
|
|
19
19
|
}
|
|
20
20
|
|
|
21
|
-
const pageLength = parseInt(scriptTag.dataset.pageLength
|
|
22
|
-
const
|
|
23
|
-
|
|
24
|
-
let lengthMenu = [10, 25, 50, 100]
|
|
25
|
-
try {
|
|
26
|
-
lengthMenu = JSON.parse(lengthMenuStr)
|
|
27
|
-
} catch (e) {
|
|
28
|
-
console.warn('DataTables: Invalid lengthMenu format, using default:', e)
|
|
29
|
-
}
|
|
21
|
+
const pageLength = parseInt(scriptTag.dataset.pageLength, 10)
|
|
22
|
+
const lengthMenu = JSON.parse(scriptTag.dataset.lengthMenu)
|
|
30
23
|
|
|
31
24
|
document.querySelectorAll('table.dataTable').forEach(function (tableEl) {
|
|
32
25
|
const rowCount = tableEl.querySelectorAll('tbody tr').length
|
|
@@ -60,10 +53,10 @@ document.addEventListener('DOMContentLoaded', () => {
|
|
|
60
53
|
lengthMenu: lengthMenu,
|
|
61
54
|
language: {
|
|
62
55
|
paginate: {
|
|
63
|
-
first: '<i class="fa-solid fa-angles-left" aria-hidden="true"></i>',
|
|
64
|
-
previous: '<i class="fa-solid fa-chevron-left" aria-hidden="true"></i>',
|
|
65
|
-
next: '<i class="fa-solid fa-chevron-right" aria-hidden="true"></i>',
|
|
66
|
-
last: '<i class="fa-solid fa-angles-right" aria-hidden="true"></i>'
|
|
56
|
+
first: '<i class="fa-solid fa-angles-left fa-sm" aria-hidden="true"></i>',
|
|
57
|
+
previous: '<i class="fa-solid fa-chevron-left fa-sm" aria-hidden="true"></i>',
|
|
58
|
+
next: '<i class="fa-solid fa-chevron-right fa-sm" aria-hidden="true"></i>',
|
|
59
|
+
last: '<i class="fa-solid fa-angles-right fa-sm" aria-hidden="true"></i>'
|
|
67
60
|
}
|
|
68
61
|
},
|
|
69
62
|
// DataTables puts the keyboard-focusable sort trigger on a nested
|
data/assets/js/base/highlight.js
CHANGED
|
@@ -1,9 +1,14 @@
|
|
|
1
|
-
// Colorizes every <pre><code> block, then
|
|
2
|
-
// inside a preview component the same
|
|
3
|
-
//
|
|
4
|
-
//
|
|
5
|
-
//
|
|
6
|
-
//
|
|
1
|
+
// Colorizes every <pre><code> block, then wraps any block not already
|
|
2
|
+
// inside a preview component in the same frame and code row
|
|
3
|
+
// preview.html.liquid renders. This way every code sample looks the same,
|
|
4
|
+
// whether it's a plain fenced Markdown block or built with the preview
|
|
5
|
+
// component. A wrapped block has no demo row, since a plain fenced block
|
|
6
|
+
// has no demo to show.
|
|
7
|
+
//
|
|
8
|
+
// The toolbar above the code row only renders when it has content: a
|
|
9
|
+
// language label when the author declared one, and a copy button when
|
|
10
|
+
// copyvalue.html.liquid loaded its script. Without either, only the
|
|
11
|
+
// framed code block shows.
|
|
7
12
|
|
|
8
13
|
// Waits for DOMContentLoaded explicitly instead of relying on `defer`:
|
|
9
14
|
// this script tag lives in <head>, and a consumer that inlines the file
|
|
@@ -32,6 +37,11 @@ document.addEventListener('DOMContentLoaded', () => {
|
|
|
32
37
|
|
|
33
38
|
hljs.highlightAll()
|
|
34
39
|
|
|
40
|
+
// copyvalue.html.liquid writes this tag only when copyvalue is on, and a
|
|
41
|
+
// parsed <script> element is in the DOM before DOMContentLoaded fires,
|
|
42
|
+
// even though its deferred code may not have run yet.
|
|
43
|
+
const withCopy = document.getElementById('centos-copyvalue') !== null
|
|
44
|
+
|
|
35
45
|
document.querySelectorAll('pre code.hljs').forEach(codeEl => {
|
|
36
46
|
const preEl = codeEl.parentElement
|
|
37
47
|
if (!preEl || preEl.closest('.preview-code')) return
|
|
@@ -41,32 +51,38 @@ document.addEventListener('DOMContentLoaded', () => {
|
|
|
41
51
|
const wrapper = document.createElement('div')
|
|
42
52
|
wrapper.className = 'preview mb-3 border rounded overflow-hidden'
|
|
43
53
|
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
toolbar.appendChild(languageEl)
|
|
54
|
+
let copyBtn = null
|
|
55
|
+
if (withCopy) {
|
|
56
|
+
copyBtn = document.createElement('button')
|
|
57
|
+
copyBtn.setAttribute('type', 'button')
|
|
58
|
+
copyBtn.className = 'copy-btn focus-ring preview-copy'
|
|
59
|
+
copyBtn.setAttribute('data-bs-toggle', 'tooltip')
|
|
60
|
+
copyBtn.setAttribute('data-bs-title', 'Copy code')
|
|
61
|
+
copyBtn.setAttribute('data-copy-value', codeEl.textContent)
|
|
62
|
+
copyBtn.setAttribute('aria-label', 'Copy code')
|
|
63
|
+
copyBtn.innerHTML = '<i class="fa-regular fa-copy"></i>'
|
|
55
64
|
}
|
|
56
65
|
|
|
57
|
-
|
|
58
|
-
|
|
66
|
+
if (language || copyBtn) {
|
|
67
|
+
// No border-top: the toolbar is always the first row here (a wrapped
|
|
68
|
+
// block has no demo row above it), so a top border would double up
|
|
69
|
+
// against the outer .preview border.
|
|
70
|
+
const toolbar = document.createElement('div')
|
|
71
|
+
toolbar.className = 'preview-toolbar m-0 p-2 border-bottom border-centos-purple-100'
|
|
59
72
|
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
73
|
+
if (language) {
|
|
74
|
+
const languageEl = document.createElement('span')
|
|
75
|
+
languageEl.className = 'preview-language small font-monospace text-body-secondary text-uppercase'
|
|
76
|
+
languageEl.textContent = language
|
|
77
|
+
toolbar.appendChild(languageEl)
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
const actions = document.createElement('div')
|
|
81
|
+
actions.className = 'preview-actions'
|
|
82
|
+
if (copyBtn) actions.appendChild(copyBtn)
|
|
83
|
+
toolbar.appendChild(actions)
|
|
84
|
+
wrapper.appendChild(toolbar)
|
|
85
|
+
}
|
|
70
86
|
|
|
71
87
|
const codeRow = document.createElement('div')
|
|
72
88
|
codeRow.className = 'preview-code p-0 m-0'
|
|
@@ -77,14 +93,13 @@ document.addEventListener('DOMContentLoaded', () => {
|
|
|
77
93
|
preEl.classList.add('p-2')
|
|
78
94
|
|
|
79
95
|
preEl.replaceWith(wrapper)
|
|
80
|
-
wrapper.appendChild(toolbar)
|
|
81
96
|
codeRow.appendChild(preEl)
|
|
82
97
|
wrapper.appendChild(codeRow)
|
|
83
98
|
|
|
84
99
|
// init-tooltips.js already made its one-time pass before this button
|
|
85
100
|
// existed, so its tooltip has to be initialized here instead — the
|
|
86
101
|
// same thing preview.html.liquid's server-rendered copy buttons need.
|
|
87
|
-
if (typeof bootstrap !== 'undefined' && bootstrap.Tooltip) {
|
|
102
|
+
if (copyBtn && typeof bootstrap !== 'undefined' && bootstrap.Tooltip) {
|
|
88
103
|
new bootstrap.Tooltip(copyBtn)
|
|
89
104
|
}
|
|
90
105
|
})
|
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.106
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Alain Reguera Delgado
|
|
@@ -373,6 +373,7 @@ files:
|
|
|
373
373
|
- _includes/base/social.html.liquid
|
|
374
374
|
- _includes/base/sponsors-cards.html.liquid
|
|
375
375
|
- _includes/base/sponsors-carousel.html.liquid
|
|
376
|
+
- _includes/base/sponsors-data.html.liquid
|
|
376
377
|
- _includes/base/title.html.liquid
|
|
377
378
|
- _includes/base/toc-generator.html.liquid
|
|
378
379
|
- _includes/base/toc.html.liquid
|