@t8/docsgen 0.1.68 → 0.1.69
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.
- package/dist/bin.js +17 -1
- package/dist/css/base.css +0 -3
- package/dist/css/index.css +6 -10
- package/dist/css/section.css +3 -0
- package/package.json +1 -1
- package/src/bin/getParsedContent.ts +7 -0
- package/src/bin/setContent.ts +11 -2
- package/src/css/base.css +0 -3
- package/src/css/index.css +6 -10
- package/src/css/section.css +3 -0
package/dist/bin.js
CHANGED
|
@@ -531,6 +531,7 @@ async function getParsedContent(ctx) {
|
|
|
531
531
|
let badges = [];
|
|
532
532
|
let title = "";
|
|
533
533
|
let description = [];
|
|
534
|
+
let descriptionNote = [];
|
|
534
535
|
let intro = [];
|
|
535
536
|
let features = [];
|
|
536
537
|
let note = [];
|
|
@@ -583,10 +584,15 @@ async function getParsedContent(ctx) {
|
|
|
583
584
|
description = [];
|
|
584
585
|
}
|
|
585
586
|
if (intro.at(-1) === "<hr>") intro.pop();
|
|
587
|
+
if (intro.length === 1) {
|
|
588
|
+
descriptionNote = intro;
|
|
589
|
+
intro = [];
|
|
590
|
+
}
|
|
586
591
|
return {
|
|
587
592
|
badges: postprocessBadges(joinLines(badges)),
|
|
588
593
|
title,
|
|
589
594
|
description: joinLines(description),
|
|
595
|
+
descriptionNote: joinLines(descriptionNote),
|
|
590
596
|
intro: joinLines(intro),
|
|
591
597
|
features: joinLines(features),
|
|
592
598
|
note: joinLines(note),
|
|
@@ -678,7 +684,16 @@ ${getInjectedContent(ctx, "redirect", "body")}
|
|
|
678
684
|
);
|
|
679
685
|
return;
|
|
680
686
|
}
|
|
681
|
-
let {
|
|
687
|
+
let {
|
|
688
|
+
badges,
|
|
689
|
+
description,
|
|
690
|
+
descriptionNote,
|
|
691
|
+
intro,
|
|
692
|
+
features,
|
|
693
|
+
installation,
|
|
694
|
+
sections,
|
|
695
|
+
nav
|
|
696
|
+
} = await getParsedContent(ctx);
|
|
682
697
|
let navContent = await getNav(ctx, nav);
|
|
683
698
|
let dirs = [contentDir];
|
|
684
699
|
await Promise.all(
|
|
@@ -772,6 +787,7 @@ ${getInjectedContent(ctx, "section", "body")}
|
|
|
772
787
|
<h1>${getTitle(ctx, { cover: true })}</h1>
|
|
773
788
|
<div class="description">
|
|
774
789
|
${description || (escapedPackageDescription ? `<p><em>${escapedPackageDescription}</em><p>` : "")}
|
|
790
|
+
${descriptionNote}
|
|
775
791
|
</div>
|
|
776
792
|
<p class="actions">
|
|
777
793
|
<a href="${root}start" class="primary button">Docs</a>
|
package/dist/css/base.css
CHANGED
package/dist/css/index.css
CHANGED
|
@@ -171,15 +171,15 @@ section.intro .section-content {
|
|
|
171
171
|
}
|
|
172
172
|
section .section-content {
|
|
173
173
|
max-width: auto;
|
|
174
|
-
padding:
|
|
174
|
+
padding: 1rem 1.35rem;
|
|
175
175
|
}
|
|
176
176
|
section.intro-title .section-content {
|
|
177
|
-
min-height:
|
|
178
|
-
padding-top:
|
|
179
|
-
padding-bottom: 1.
|
|
177
|
+
min-height: 60vh;
|
|
178
|
+
padding-top: 2rem;
|
|
179
|
+
padding-bottom: 1.5rem;
|
|
180
180
|
}
|
|
181
181
|
section.intro-title:last-child .section-content {
|
|
182
|
-
padding-bottom: 2.
|
|
182
|
+
padding-bottom: 2.5rem;
|
|
183
183
|
}
|
|
184
184
|
section.intro {
|
|
185
185
|
flex: auto;
|
|
@@ -187,7 +187,7 @@ section.intro .section-content {
|
|
|
187
187
|
align-items: center;
|
|
188
188
|
}
|
|
189
189
|
section.intro .section-content {
|
|
190
|
-
padding-top: 0.
|
|
190
|
+
padding-top: 0.5rem;
|
|
191
191
|
}
|
|
192
192
|
}
|
|
193
193
|
.features {
|
|
@@ -220,10 +220,6 @@ section.intro .section-content {
|
|
|
220
220
|
border-top: 0.15em solid var(--line-color);
|
|
221
221
|
}
|
|
222
222
|
@media (max-width: 840px) {
|
|
223
|
-
.features {
|
|
224
|
-
padding: 0 0.5em;
|
|
225
|
-
margin: 0;
|
|
226
|
-
}
|
|
227
223
|
.features h2 {
|
|
228
224
|
text-align: center;
|
|
229
225
|
}
|
package/dist/css/section.css
CHANGED
package/package.json
CHANGED
|
@@ -132,6 +132,7 @@ export async function getParsedContent(ctx: Context) {
|
|
|
132
132
|
let badges: string[] = [];
|
|
133
133
|
let title = "";
|
|
134
134
|
let description: string[] = [];
|
|
135
|
+
let descriptionNote: string[] = [];
|
|
135
136
|
let intro: string[] = [];
|
|
136
137
|
let features: string[] = [];
|
|
137
138
|
let note: string[] = [];
|
|
@@ -203,10 +204,16 @@ export async function getParsedContent(ctx: Context) {
|
|
|
203
204
|
|
|
204
205
|
if (intro.at(-1) === "<hr>") intro.pop();
|
|
205
206
|
|
|
207
|
+
if (intro.length === 1) {
|
|
208
|
+
descriptionNote = intro;
|
|
209
|
+
intro = [];
|
|
210
|
+
}
|
|
211
|
+
|
|
206
212
|
return {
|
|
207
213
|
badges: postprocessBadges(joinLines(badges)),
|
|
208
214
|
title,
|
|
209
215
|
description: joinLines(description),
|
|
216
|
+
descriptionNote: joinLines(descriptionNote),
|
|
210
217
|
intro: joinLines(intro),
|
|
211
218
|
features: joinLines(features),
|
|
212
219
|
note: joinLines(note),
|
package/src/bin/setContent.ts
CHANGED
|
@@ -89,8 +89,16 @@ ${getInjectedContent(ctx, "redirect", "body")}
|
|
|
89
89
|
return;
|
|
90
90
|
}
|
|
91
91
|
|
|
92
|
-
let {
|
|
93
|
-
|
|
92
|
+
let {
|
|
93
|
+
badges,
|
|
94
|
+
description,
|
|
95
|
+
descriptionNote,
|
|
96
|
+
intro,
|
|
97
|
+
features,
|
|
98
|
+
installation,
|
|
99
|
+
sections,
|
|
100
|
+
nav,
|
|
101
|
+
} = await getParsedContent(ctx);
|
|
94
102
|
|
|
95
103
|
let navContent = await getNav(ctx, nav);
|
|
96
104
|
let dirs = [contentDir];
|
|
@@ -192,6 +200,7 @@ ${getInjectedContent(ctx, "section", "body")}
|
|
|
192
200
|
<h1>${getTitle(ctx, { cover: true })}</h1>
|
|
193
201
|
<div class="description">
|
|
194
202
|
${description || (escapedPackageDescription ? `<p><em>${escapedPackageDescription}</em><p>` : "")}
|
|
203
|
+
${descriptionNote}
|
|
195
204
|
</div>
|
|
196
205
|
<p class="actions">
|
|
197
206
|
<a href="${root}start" class="primary button">Docs</a>
|
package/src/css/base.css
CHANGED
package/src/css/index.css
CHANGED
|
@@ -171,15 +171,15 @@ section.intro .section-content {
|
|
|
171
171
|
}
|
|
172
172
|
section .section-content {
|
|
173
173
|
max-width: auto;
|
|
174
|
-
padding:
|
|
174
|
+
padding: 1rem 1.35rem;
|
|
175
175
|
}
|
|
176
176
|
section.intro-title .section-content {
|
|
177
|
-
min-height:
|
|
178
|
-
padding-top:
|
|
179
|
-
padding-bottom: 1.
|
|
177
|
+
min-height: 60vh;
|
|
178
|
+
padding-top: 2rem;
|
|
179
|
+
padding-bottom: 1.5rem;
|
|
180
180
|
}
|
|
181
181
|
section.intro-title:last-child .section-content {
|
|
182
|
-
padding-bottom: 2.
|
|
182
|
+
padding-bottom: 2.5rem;
|
|
183
183
|
}
|
|
184
184
|
section.intro {
|
|
185
185
|
flex: auto;
|
|
@@ -187,7 +187,7 @@ section.intro .section-content {
|
|
|
187
187
|
align-items: center;
|
|
188
188
|
}
|
|
189
189
|
section.intro .section-content {
|
|
190
|
-
padding-top: 0.
|
|
190
|
+
padding-top: 0.5rem;
|
|
191
191
|
}
|
|
192
192
|
}
|
|
193
193
|
.features {
|
|
@@ -220,10 +220,6 @@ section.intro .section-content {
|
|
|
220
220
|
border-top: 0.15em solid var(--line-color);
|
|
221
221
|
}
|
|
222
222
|
@media (max-width: 840px) {
|
|
223
|
-
.features {
|
|
224
|
-
padding: 0 0.5em;
|
|
225
|
-
margin: 0;
|
|
226
|
-
}
|
|
227
223
|
.features h2 {
|
|
228
224
|
text-align: center;
|
|
229
225
|
}
|