hdoc-tools 0.60.1 → 0.62.0

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.
Files changed (55) hide show
  1. package/LICENSE +21 -21
  2. package/README.md +89 -75
  3. package/hdoc-build-db.js +275 -275
  4. package/hdoc-build-embeddings.js +202 -202
  5. package/hdoc-build-pdf.js +232 -232
  6. package/hdoc-build.js +14 -6
  7. package/hdoc-bump.js +4 -2
  8. package/hdoc-content-routes.js +143 -83
  9. package/hdoc-create.js +110 -108
  10. package/hdoc-db.js +114 -114
  11. package/hdoc-help.js +60 -60
  12. package/hdoc-init.js +103 -68
  13. package/hdoc-install-browser.js +145 -145
  14. package/hdoc-mermaid.js +204 -204
  15. package/hdoc-module.js +1102 -1079
  16. package/hdoc-serve.js +13 -7
  17. package/hdoc-stats.js +9 -9
  18. package/hdoc-validate-config.js +355 -329
  19. package/hdoc-validate-interbook.js +321 -0
  20. package/hdoc-validate.js +1231 -1158
  21. package/hdoc-ver.js +4 -2
  22. package/hdoc.js +12 -11
  23. package/npm-shrinkwrap.json +2 -2
  24. package/package.json +13 -2
  25. package/schemas/hdocbook-project.schema.json +20 -0
  26. package/schemas/hdocbook.schema.json +6 -2
  27. package/templates/doc-header-non-git.html +19 -19
  28. package/templates/doc-header.html +26 -26
  29. package/templates/init/.github/workflows/hdocbuild_onpull.yml +16 -16
  30. package/templates/init/.github/workflows/hdocbuild_onpush.yml +15 -15
  31. package/templates/init/LICENSE +21 -21
  32. package/templates/init/README.md +9 -9
  33. package/templates/init/_hdocbook/index.md +4 -4
  34. package/templates/init/gitignore +8 -8
  35. package/templates/init/resources/README.md +2 -2
  36. package/templates/pdf/css/custom-block.css +90 -90
  37. package/templates/pdf/css/fonts.css +221 -221
  38. package/templates/pdf/css/hdocs-pdf.css +495 -495
  39. package/templates/pdf/css/vars.css +404 -404
  40. package/templates/pdf/template-footer.html +19 -19
  41. package/templates/pdf/template-header.html +37 -37
  42. package/templates/pdf/template.html +20 -20
  43. package/templates/pdf-header-non-git.html +12 -12
  44. package/templates/pdf-header.html +16 -16
  45. package/ui/content/invalid-hdocbook-json.html +6 -6
  46. package/ui/content/invalid-hdocbook-json.md +7 -7
  47. package/ui/css/theme-default/styles/components/content.css +124 -124
  48. package/ui/css/theme-default/styles/components/sidebar.css +182 -182
  49. package/ui/css/theme-default/styles/htldoc.layouts.css +310 -310
  50. package/ui/index.html +419 -419
  51. package/ui/js/doc.hornbill.js +31 -44
  52. package/ui/js/mermaid-theme.json +27 -0
  53. package/hdoc-build-onyx.js +0 -134
  54. package/templates/mermaid-theme.yaml +0 -28
  55. package/templates/pdf/fonts/inter-cyrillic copy.woff2 +0 -0
@@ -1,20 +1,20 @@
1
- <style>
2
- .wrap {
3
- width: 100%;
4
- text-align: center;
5
- display:flex;
6
- justify-content:center;
7
- margin-right: 40px;
8
- margin-left: 40px;
9
- }
10
-
11
- .wrap h6 {
12
- float: left;
13
- font-size: 10px;
14
- margin-bottom: 6px;
15
- }
16
- </style>
17
-
18
- <div class="wrap">
19
- <h6><span class="pageNumber"></span> of <span class="totalPages"></span></h6>
1
+ <style>
2
+ .wrap {
3
+ width: 100%;
4
+ text-align: center;
5
+ display:flex;
6
+ justify-content:center;
7
+ margin-right: 40px;
8
+ margin-left: 40px;
9
+ }
10
+
11
+ .wrap h6 {
12
+ float: left;
13
+ font-size: 10px;
14
+ margin-bottom: 6px;
15
+ }
16
+ </style>
17
+
18
+ <div class="wrap">
19
+ <h6><span class="pageNumber"></span> of <span class="totalPages"></span></h6>
20
20
  </div>
@@ -1,38 +1,38 @@
1
- <style>
2
- .header {
3
- width: 100%;
4
- height: 60px;
5
- position: relative;
6
- margin-left: 28px;
7
- margin-right: 28px;
8
- margin-bottom: 20px;
9
- margin-top: -5px;
10
- }
11
-
12
- .header img {
13
- width: 140px;
14
- margin-right: 5px;
15
- margin-top: 6px;
16
- margin-bottom: 12px;
17
- float: right;
18
- }
19
-
20
- .header h3 {
21
- font-size: 12px;
22
- font-weight: light;
23
- margin-left: 5px;
24
- float: left;
25
- margin-top: 10px;
26
- }
27
- .header hr {
28
- border: none;
29
- border-top: 1px solid rgba(60, 60, 60, 0.29);
30
- }
31
- </style>
32
-
33
- <div class="header">
34
- <img src="{{hb_logo}}" />
35
- <h3>{{book_title}}</h3>
36
- <div style="clear: both;"></div>
37
- <hr/>
1
+ <style>
2
+ .header {
3
+ width: 100%;
4
+ height: 60px;
5
+ position: relative;
6
+ margin-left: 28px;
7
+ margin-right: 28px;
8
+ margin-bottom: 20px;
9
+ margin-top: -5px;
10
+ }
11
+
12
+ .header img {
13
+ width: 140px;
14
+ margin-right: 5px;
15
+ margin-top: 6px;
16
+ margin-bottom: 12px;
17
+ float: right;
18
+ }
19
+
20
+ .header h3 {
21
+ font-size: 12px;
22
+ font-weight: light;
23
+ margin-left: 5px;
24
+ float: left;
25
+ margin-top: 10px;
26
+ }
27
+ .header hr {
28
+ border: none;
29
+ border-top: 1px solid rgba(60, 60, 60, 0.29);
30
+ }
31
+ </style>
32
+
33
+ <div class="header">
34
+ <img src="{{hb_logo}}" />
35
+ <h3>{{book_title}}</h3>
36
+ <div style="clear: both;"></div>
37
+ <hr/>
38
38
  </div>
@@ -1,21 +1,21 @@
1
- <!DOCTYPE html>
2
- <html>
3
-
4
- <head>
5
- <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap-icons@1.9.1/font/bootstrap-icons.css" />
6
- <link rel="stylesheet"
7
- href="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/11.7.0/styles/base16/humanoid-light.min.css">
8
- <script src="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/11.7.0/highlight.min.js"></script>
9
- </head>
10
-
11
- <body>
12
- {{document_content}}
13
- </body>
14
- <script type="text/javascript">
15
-
16
- // Using highlightAll method to
17
- // highlight the code
18
- hljs.highlightAll();
19
- </script>
20
-
1
+ <!DOCTYPE html>
2
+ <html>
3
+
4
+ <head>
5
+ <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap-icons@1.9.1/font/bootstrap-icons.css" />
6
+ <link rel="stylesheet"
7
+ href="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/11.7.0/styles/base16/humanoid-light.min.css">
8
+ <script src="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/11.7.0/highlight.min.js"></script>
9
+ </head>
10
+
11
+ <body>
12
+ {{document_content}}
13
+ </body>
14
+ <script type="text/javascript">
15
+
16
+ // Using highlightAll method to
17
+ // highlight the code
18
+ hljs.highlightAll();
19
+ </script>
20
+
21
21
  </html>
@@ -1,13 +1,13 @@
1
- <div class="document-header">
2
-
3
- <h1>{{title}}</h1>
4
-
5
- <div class="hb-container-horizontal">
6
- <div class="hb-center-v hb-container-expand">
7
- <ul class="ps-0 nav-bar-nav-list noeffects after-bullets overflow-ellipsis text-light-2">
8
- <li class="ps-0 mt-0 nav-bar-item">{{doc-type}}</li>
9
- <li class="ps-0 mt-0 nav-bar-item">{{reading-time}} minutes to read</li>
10
- </ul>
11
- </div>
12
- </div>
1
+ <div class="document-header">
2
+
3
+ <h1>{{title}}</h1>
4
+
5
+ <div class="hb-container-horizontal">
6
+ <div class="hb-center-v hb-container-expand">
7
+ <ul class="ps-0 nav-bar-nav-list noeffects after-bullets overflow-ellipsis text-light-2">
8
+ <li class="ps-0 mt-0 nav-bar-item">{{doc-type}}</li>
9
+ <li class="ps-0 mt-0 nav-bar-item">{{reading-time}} minutes to read</li>
10
+ </ul>
11
+ </div>
12
+ </div>
13
13
  </div>
@@ -1,17 +1,17 @@
1
- <div class="document-header">
2
-
3
- <h1>{{title}}</h1>
4
-
5
- <div class="hb-container-horizontal">
6
- <div class="hb-center-v hb-container-expand">
7
- <ul class="ps-0 nav-bar-nav-list noeffects after-bullets overflow-ellipsis text-light-2">
8
- <li class="ps-0 mt-0 nav-bar-item">{{doc-type}}</li>
9
- <li class="ps-0 mt-0 nav-bar-item">{{last-update}}</li>
10
- <li class="ps-0 mt-0 nav-bar-item">{{reading-time}} minutes to read</li>
11
- <li class="ps-0 mt-0 nav-bar-item">
12
- <a class="link c-pointer" data-bs-toggle="modal" data-bs-target="#contributersModal">{{contributor-count}} contributors</a>
13
- </li>
14
- </ul>
15
- </div>
16
- </div>
1
+ <div class="document-header">
2
+
3
+ <h1>{{title}}</h1>
4
+
5
+ <div class="hb-container-horizontal">
6
+ <div class="hb-center-v hb-container-expand">
7
+ <ul class="ps-0 nav-bar-nav-list noeffects after-bullets overflow-ellipsis text-light-2">
8
+ <li class="ps-0 mt-0 nav-bar-item">{{doc-type}}</li>
9
+ <li class="ps-0 mt-0 nav-bar-item">{{last-update}}</li>
10
+ <li class="ps-0 mt-0 nav-bar-item">{{reading-time}} minutes to read</li>
11
+ <li class="ps-0 mt-0 nav-bar-item">
12
+ <a class="link c-pointer" data-bs-toggle="modal" data-bs-target="#contributersModal">{{contributor-count}} contributors</a>
13
+ </li>
14
+ </ul>
15
+ </div>
16
+ </div>
17
17
  </div>
@@ -1,6 +1,6 @@
1
- <h1>FAILED TO LOAD HDOC MENU</h1>
2
- <div class="alert alert-danger" role="alert">
3
- <strong>Warning!</strong>
4
- <p><strong>hdoc serve</strong> has failed to load the book navigation. This is due to invalid JSON in the <code>hdocbook.json</code> file in your book.</p>
5
- <p>Please fix the broken JSON, then refresh your browser to reload the book.</p>
6
- </div>
1
+ <h1>FAILED TO LOAD HDOC MENU</h1>
2
+ <div class="alert alert-danger" role="alert">
3
+ <strong>Warning!</strong>
4
+ <p><strong>hdoc serve</strong> has failed to load the book navigation. This is due to invalid JSON in the <code>hdocbook.json</code> file in your book.</p>
5
+ <p>Please fix the broken JSON, then refresh your browser to reload the book.</p>
6
+ </div>
@@ -1,7 +1,7 @@
1
- <h1>FAILED TO LOAD HDOC MENU</h1>
2
- <div class="alert alert-danger" role="alert">
3
- <p><code>hdoc serve</code> has failed to load the book navigation. This is due to invalid JSON in the <code>hdocbook.json</code> file in your book.</p>
4
- <p>Please fix the broken JSON, then refresh your browser to reload the book.</p>
5
- <p>{{docApp.error}}</p>
6
- </div>
7
- </div>
1
+ <h1>FAILED TO LOAD HDOC MENU</h1>
2
+ <div class="alert alert-danger" role="alert">
3
+ <p><code>hdoc serve</code> has failed to load the book navigation. This is due to invalid JSON in the <code>hdocbook.json</code> file in your book.</p>
4
+ <p>Please fix the broken JSON, then refresh your browser to reload the book.</p>
5
+ <p>{{docApp.error}}</p>
6
+ </div>
7
+ </div>
@@ -1,124 +1,124 @@
1
- /* base doc content classes*/
2
- .DocContent .content-wrapper
3
- {
4
- padding: 20px 0px;
5
- margin: 0 0;
6
- overflow: initial;
7
- max-width:1500px;
8
- }
9
-
10
- .DocContent .injected-document-container
11
- {
12
- padding: 0 40px;
13
- position:relative;
14
- }
15
-
16
- .DocContent .injected-document-content
17
- {
18
- width: 100%;
19
- }
20
-
21
- .DocContent .injected-document-toc
22
- {
23
- height: fit-content;
24
- display:none;
25
- margin:0 0 0 50px;
26
- width:400px;
27
- }
28
-
29
- .DocContent .injected-document-toc .H2{
30
-
31
- }
32
- .DocContent .injected-document-toc .H3{
33
- padding-left:10px;
34
-
35
- }
36
-
37
- /* nav tabs in doc content */
38
- .DocContent .nav-tabs
39
- {
40
- padding-left: 0!important;
41
- list-style: none!important;
42
- }
43
- .DocContent .nav-tabs li
44
- {
45
- margin-top: 0px !important
46
- }
47
-
48
-
49
- .DocContent .nav-tabs.codeblock
50
- {
51
- border-bottom: 1px solid #1E1E1E;
52
- margin-bottom: 0px
53
- }
54
- .DocContent .nav-tabs.codeblock .nav-link.active
55
- {
56
- background-color: #1E1E1E;
57
- color: #fff;
58
- border-color: #1E1E1E;
59
- }
60
- .DocContent .nav-tabs.codeblock .nav-link:hover
61
- {
62
- border-bottom-color: #1E1E1E;
63
- }
64
- /* eof nav tabs in doc content */
65
-
66
-
67
- .DocContent .code-badge-pre
68
- {
69
- max-width: 100%!important;
70
- min-width: 100%!important;
71
- }
72
-
73
- @media (min-width: 1000px) {
74
-
75
- .DocContent .injected-document-content
76
- {
77
- /*width: 900px;*/
78
- }
79
- }
80
-
81
-
82
- /* style overrides to apply on screens that are 1500px and wider */
83
- @media (min-width: 1500px) {
84
-
85
- .DocContent .injected-document-toc
86
- {
87
- display:inline-block;
88
- }
89
-
90
- /* if have toc layout and greater than 1500px then limit doc content to 900px to make room for toc */
91
- .DocContent.article-toc .injected-document-content
92
- {
93
- width: 900px;
94
- }
95
-
96
- }
97
-
98
- /* style overrides to apply on screens that are 1920px and wider */
99
- @media (min-width: 1790px) {
100
-
101
- .DocContent .content-wrapper
102
- {
103
- /*margin-left: 20px*/
104
- }
105
- }
106
-
107
-
108
-
109
- /* LAYOUT MODS */
110
-
111
- /* table-list*/
112
- .DocContent.article-wide .injected-document-content
113
- {
114
- /* take up max width - overrides max-width set in [.DocContent .injected-document-content] */
115
- max-width:100%;
116
- }
117
-
118
- .DocContent.article-wide .injected-document-content table
119
- {
120
- /* make all tables 100% */
121
- width:100%;
122
- display:table;
123
- }
124
-
1
+ /* base doc content classes*/
2
+ .DocContent .content-wrapper
3
+ {
4
+ padding: 20px 0px;
5
+ margin: 0 0;
6
+ overflow: initial;
7
+ max-width:1500px;
8
+ }
9
+
10
+ .DocContent .injected-document-container
11
+ {
12
+ padding: 0 40px;
13
+ position:relative;
14
+ }
15
+
16
+ .DocContent .injected-document-content
17
+ {
18
+ width: 100%;
19
+ }
20
+
21
+ .DocContent .injected-document-toc
22
+ {
23
+ height: fit-content;
24
+ display:none;
25
+ margin:0 0 0 50px;
26
+ width:400px;
27
+ }
28
+
29
+ .DocContent .injected-document-toc .H2{
30
+
31
+ }
32
+ .DocContent .injected-document-toc .H3{
33
+ padding-left:10px;
34
+
35
+ }
36
+
37
+ /* nav tabs in doc content */
38
+ .DocContent .nav-tabs
39
+ {
40
+ padding-left: 0!important;
41
+ list-style: none!important;
42
+ }
43
+ .DocContent .nav-tabs li
44
+ {
45
+ margin-top: 0px !important
46
+ }
47
+
48
+
49
+ .DocContent .nav-tabs.codeblock
50
+ {
51
+ border-bottom: 1px solid #1E1E1E;
52
+ margin-bottom: 0px
53
+ }
54
+ .DocContent .nav-tabs.codeblock .nav-link.active
55
+ {
56
+ background-color: #1E1E1E;
57
+ color: #fff;
58
+ border-color: #1E1E1E;
59
+ }
60
+ .DocContent .nav-tabs.codeblock .nav-link:hover
61
+ {
62
+ border-bottom-color: #1E1E1E;
63
+ }
64
+ /* eof nav tabs in doc content */
65
+
66
+
67
+ .DocContent .code-badge-pre
68
+ {
69
+ max-width: 100%!important;
70
+ min-width: 100%!important;
71
+ }
72
+
73
+ @media (min-width: 1000px) {
74
+
75
+ .DocContent .injected-document-content
76
+ {
77
+ /*width: 900px;*/
78
+ }
79
+ }
80
+
81
+
82
+ /* style overrides to apply on screens that are 1500px and wider */
83
+ @media (min-width: 1500px) {
84
+
85
+ .DocContent .injected-document-toc
86
+ {
87
+ display:inline-block;
88
+ }
89
+
90
+ /* if have toc layout and greater than 1500px then limit doc content to 900px to make room for toc */
91
+ .DocContent.article-toc .injected-document-content
92
+ {
93
+ width: 900px;
94
+ }
95
+
96
+ }
97
+
98
+ /* style overrides to apply on screens that are 1920px and wider */
99
+ @media (min-width: 1790px) {
100
+
101
+ .DocContent .content-wrapper
102
+ {
103
+ /*margin-left: 20px*/
104
+ }
105
+ }
106
+
107
+
108
+
109
+ /* LAYOUT MODS */
110
+
111
+ /* table-list*/
112
+ .DocContent.article-wide .injected-document-content
113
+ {
114
+ /* take up max width - overrides max-width set in [.DocContent .injected-document-content] */
115
+ max-width:100%;
116
+ }
117
+
118
+ .DocContent.article-wide .injected-document-content table
119
+ {
120
+ /* make all tables 100% */
121
+ width:100%;
122
+ display:table;
123
+ }
124
+