@mark1russell7/site-pages 0.1.4 → 0.1.6
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/README.md +2 -1
- package/build/{build-BOMm-RGQ.js → build-Dr35nErd.js} +166 -65
- package/build/build-Dr35nErd.js.map +1 -0
- package/build/cli.js +2 -3
- package/build/index.d.ts +7 -32
- package/build/index.d.ts.map +1 -1
- package/build/index.js +1 -1
- package/package.json +2 -2
- package/build/build-BOMm-RGQ.js.map +0 -1
package/build/index.d.ts
CHANGED
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
//#region src/data/types.d.ts
|
|
2
1
|
/**
|
|
3
2
|
* The data shapes of `releases.json` and `status.json`. The standalone pages read them, and a site
|
|
4
3
|
* can read the same JSON with its own components.
|
|
@@ -143,8 +142,6 @@ interface StatusBoardData {
|
|
|
143
142
|
totals?: OpenWorkTotals;
|
|
144
143
|
};
|
|
145
144
|
}
|
|
146
|
-
//#endregion
|
|
147
|
-
//#region src/data/versions.d.ts
|
|
148
145
|
/** The parts of a SemVer 2.0.0 version. */
|
|
149
146
|
interface ParsedVersion {
|
|
150
147
|
major: number;
|
|
@@ -175,8 +172,6 @@ interface TagVersion {
|
|
|
175
172
|
* `name@1.2.3` and `@scope/name@1.2.3`. It gives null for another tag.
|
|
176
173
|
*/
|
|
177
174
|
export declare function versionOfTag(tag: string): TagVersion | null;
|
|
178
|
-
//#endregion
|
|
179
|
-
//#region src/data/changelog.d.ts
|
|
180
175
|
/**
|
|
181
176
|
* The changelog parser. Changesets writes a section for each version in the `CHANGELOG.md` of each
|
|
182
177
|
* package. The section has a `## 0.13.2` heading and a `###` heading for each kind of change. Each
|
|
@@ -221,8 +216,6 @@ export declare function releaseBodyEntries(body: string): ChangelogEntry[];
|
|
|
221
216
|
* for each space. The anchor of "0.13.2" is "0132".
|
|
222
217
|
*/
|
|
223
218
|
export declare function headingAnchor(heading: string): string;
|
|
224
|
-
//#endregion
|
|
225
|
-
//#region src/data/github.d.ts
|
|
226
219
|
/** The GraphQL endpoint of GitHub. */
|
|
227
220
|
export declare const GITHUB_GRAPHQL = "https://api.github.com/graphql";
|
|
228
221
|
/** The REST endpoint of GitHub. */
|
|
@@ -262,8 +255,6 @@ export declare function githubReleases(options: GitHubOptions & {
|
|
|
262
255
|
endpoint?: string;
|
|
263
256
|
maxPages?: number;
|
|
264
257
|
}): Promise<GitHubReleases>;
|
|
265
|
-
//#endregion
|
|
266
|
-
//#region src/data/npm.d.ts
|
|
267
258
|
/** The public npm registry. */
|
|
268
259
|
export declare const NPM_REGISTRY = "https://registry.npmjs.org";
|
|
269
260
|
/** The options of `npmPublishTimes`. */
|
|
@@ -282,8 +273,6 @@ interface NpmOptions {
|
|
|
282
273
|
* message in `problems`.
|
|
283
274
|
*/
|
|
284
275
|
export declare function npmPublishTimes(options: NpmOptions): Promise<NpmPublishTimes>;
|
|
285
|
-
//#endregion
|
|
286
|
-
//#region src/data/git.d.ts
|
|
287
276
|
/** A git tag and the ISO date of its creation. */
|
|
288
277
|
interface TagDate {
|
|
289
278
|
tag: string;
|
|
@@ -302,15 +291,11 @@ export declare function headingDate(repoDir: string, version: string, file: stri
|
|
|
302
291
|
export declare function headCommit(repoDir: string): string | null;
|
|
303
292
|
/** This function gives "owner/name" of the GitHub remote "origin", or null. */
|
|
304
293
|
export declare function originRepository(repoDir: string): string | null;
|
|
305
|
-
//#endregion
|
|
306
|
-
//#region src/data/glob.d.ts
|
|
307
294
|
/**
|
|
308
295
|
* This function gives the files under `root` that match a pattern, as paths with `/` that start at
|
|
309
296
|
* `root`, sorted. It does not go into `node_modules` or `.git`.
|
|
310
297
|
*/
|
|
311
298
|
export declare function globFiles(root: string, pattern: string): string[];
|
|
312
|
-
//#endregion
|
|
313
|
-
//#region src/data/releases.d.ts
|
|
314
299
|
/** An error in the release sources, for example a group without a changelog. */
|
|
315
300
|
export declare class ReleaseDataError extends Error {}
|
|
316
301
|
/** One changelog file and the npm name of its package. */
|
|
@@ -385,8 +370,6 @@ interface ReadReleasesOptions {
|
|
|
385
370
|
* @throws ReleaseDataError when `group` has no changelog and other changelogs exist
|
|
386
371
|
*/
|
|
387
372
|
export declare function readReleases(options: ReadReleasesOptions): Promise<Release[]>;
|
|
388
|
-
//#endregion
|
|
389
|
-
//#region src/data/status.d.ts
|
|
390
373
|
/** The classes of a status, in the sequence of the board. The open work comes first. */
|
|
391
374
|
export declare const STATUS_CLASSES: readonly StatusClass[];
|
|
392
375
|
/** The open classes, in the sequence of the board. */
|
|
@@ -462,6 +445,13 @@ interface StatusBoardInput {
|
|
|
462
445
|
commit?: string | null;
|
|
463
446
|
generatedAt?: string;
|
|
464
447
|
}
|
|
448
|
+
/**
|
|
449
|
+
* This function gives the items of a roadmap file, as the Status page reads them. It fails when the file has no item.
|
|
450
|
+
*
|
|
451
|
+
* @throws RoadmapParseError when the cells of a row do not match the header
|
|
452
|
+
* @throws RoadmapParseError when the roadmap has no item: no table with an ID and a Status column, and no item heading
|
|
453
|
+
*/
|
|
454
|
+
export declare function parseRoadmap(markdown: string, options?: LinkOptions): BoardItem[];
|
|
465
455
|
/** This function puts the roadmap items and the GitHub part into the shape of `status.json`. */
|
|
466
456
|
export declare function buildStatusBoard(input: StatusBoardInput): StatusBoardData;
|
|
467
457
|
/** The options of `readStatusBoard`. */
|
|
@@ -484,8 +474,6 @@ interface ReadStatusBoardOptions {
|
|
|
484
474
|
* and a Status column, and no item heading
|
|
485
475
|
*/
|
|
486
476
|
export declare function readStatusBoard(options: ReadStatusBoardOptions): Promise<StatusBoardData>;
|
|
487
|
-
//#endregion
|
|
488
|
-
//#region src/render/html.d.ts
|
|
489
477
|
/** This function escapes a text for HTML content and for an attribute value in double quotes. */
|
|
490
478
|
export declare function escapeHtml(text: string): string;
|
|
491
479
|
/**
|
|
@@ -502,8 +490,6 @@ export declare function safeUrl(url: string): string | null;
|
|
|
502
490
|
* escapes all other text, so the result is safe.
|
|
503
491
|
*/
|
|
504
492
|
export declare function inlineMarkdown(markdown: string): string;
|
|
505
|
-
//#endregion
|
|
506
|
-
//#region src/render/dates.d.ts
|
|
507
493
|
/** This function gives the start of the UTC day of a time. */
|
|
508
494
|
export declare function utcDay(time: number): number;
|
|
509
495
|
/** This function gives "Oct 18": the UTC day of a time or of an ISO date. */
|
|
@@ -512,8 +498,6 @@ export declare function shortDate(date: string | number): string;
|
|
|
512
498
|
export declare function longDate(date: string | number): string;
|
|
513
499
|
/** This function gives "Oct 13–15", or "Sep 30–Oct 2" over the end of a month. */
|
|
514
500
|
export declare function dayRange(start: number, end: number): string;
|
|
515
|
-
//#endregion
|
|
516
|
-
//#region src/render/theme.d.ts
|
|
517
501
|
/** The options of each page. */
|
|
518
502
|
interface PageOptions {
|
|
519
503
|
/** "owner/name" of the repository on GitHub. */
|
|
@@ -545,8 +529,6 @@ interface PageParts {
|
|
|
545
529
|
}
|
|
546
530
|
/** This function makes the complete HTML document of a page. */
|
|
547
531
|
export declare function pageShell(parts: PageParts, options: PageOptions): string;
|
|
548
|
-
//#endregion
|
|
549
|
-
//#region src/render/timeline.d.ts
|
|
550
532
|
/** What the timeline needs of a version. */
|
|
551
533
|
interface ReleasePoint {
|
|
552
534
|
version: string;
|
|
@@ -622,8 +604,6 @@ export declare function laneCenter(layout: {
|
|
|
622
604
|
}, lane: number): number;
|
|
623
605
|
/** This function calculates the layout of the timeline at a width. */
|
|
624
606
|
export declare function timelineLayout<T extends ReleasePoint>(releases: readonly T[], options: TimelineOptions): TimelineLayout<T>;
|
|
625
|
-
//#endregion
|
|
626
|
-
//#region src/render/releases.d.ts
|
|
627
607
|
/**
|
|
628
608
|
* This function gives the lead line of the releases page, for example "23 versions from Oct 12 to
|
|
629
609
|
* Oct 18, 2026. 7 MINOR releases and 15 PATCH releases came after the first release."
|
|
@@ -636,8 +616,6 @@ export declare function releasesLead(releases: readonly Release[]): string;
|
|
|
636
616
|
export declare const RELEASES_SCRIPT: string;
|
|
637
617
|
/** This function renders the complete releases page from the data of `releases.json`. */
|
|
638
618
|
export declare function renderReleasesPage(releases: readonly Release[], options: PageOptions): string;
|
|
639
|
-
//#endregion
|
|
640
|
-
//#region src/render/status.d.ts
|
|
641
619
|
/**
|
|
642
620
|
* This function gives the lead line of the status page, for example "12 open roadmap items, 9 open
|
|
643
621
|
* pull requests and 0 open issues, read at Oct 19, 2026, 14:05 UTC from abc1234."
|
|
@@ -670,8 +648,6 @@ export declare function classCounts(items: readonly BoardItem[]): Record<StatusC
|
|
|
670
648
|
export declare const STATUS_SCRIPT: string;
|
|
671
649
|
/** This function renders the complete status page from the data of `status.json`. */
|
|
672
650
|
export declare function renderStatusPage(data: StatusBoardData, options: PageOptions): string;
|
|
673
|
-
//#endregion
|
|
674
|
-
//#region src/build.d.ts
|
|
675
651
|
/** An error in the command line. The CLI shows the help and exits with code 2. */
|
|
676
652
|
export declare class UsageError extends Error {}
|
|
677
653
|
/** The options of `build`. */
|
|
@@ -742,6 +718,5 @@ export declare function parseBuildArgs(argv: readonly string[], io: Pick<CliIo,
|
|
|
742
718
|
* source is not correct, and 2 for an incorrect command line.
|
|
743
719
|
*/
|
|
744
720
|
export declare function runCli(argv: readonly string[], io: CliIo): Promise<number>;
|
|
745
|
-
//#endregion
|
|
746
721
|
export type { BoardIssue, BoardItem, BoardPullRequest, BoardSection, BuildOptions, BuildResult, ChangelogEntry, ChangelogSection, ChangelogSource, CheckState, CliIo, GitHubOpenWork, GitHubOptions, GitHubRelease, GitHubReleases, ItemGroup, Link, LinkOptions, MarkdownTable, NpmOptions, NpmPublishTimes, NpmVersionTime, OpenWorkTotals, PageOptions, PageParts, ParsedVersion, ReadReleasesOptions, ReadStatusBoardOptions, Release, ReleaseChange, ReleaseKind, ReleasePoint, ReleaseSources, ReleaseSummary, StatusBoardData, StatusBoardInput, StatusClass, TagDate, TagVersion, TimelineBand, TimelineLayout, TimelineMark, TimelineOptions };
|
|
747
722
|
//# sourceMappingURL=index.d.ts.map
|
package/build/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","names":[],"sources":["../src/data/types.ts","../src/data/versions.ts","../src/data/changelog.ts","../src/data/github.ts","../src/data/npm.ts","../src/data/git.ts","../src/data/glob.ts","../src/data/releases.ts","../src/data/status.ts","../src/render/html.ts","../src/render/dates.ts","../src/render/theme.ts","../src/render/timeline.ts","../src/render/releases.ts","../src/render/status.ts","../src/build.ts"],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.d.ts","names":[],"sources":["../src/data/types.ts","../src/data/versions.ts","../src/data/changelog.ts","../src/data/github.ts","../src/data/npm.ts","../src/data/git.ts","../src/data/glob.ts","../src/data/releases.ts","../src/data/status.ts","../src/render/html.ts","../src/render/dates.ts","../src/render/theme.ts","../src/render/timeline.ts","../src/render/releases.ts","../src/render/status.ts","../src/build.ts"],"mappings":";;;;;UAMiB;EACf;EACA;;;;;;KAWU;;UAGK;;EAEf;;EAEA;;EAEA;;;UAIe;EACf;;EAEA;EACA,MAAM;;EAEN,SAAS;;EAET,OAAO;;;UAIQ;EACf;EACA;;EAEA;;EAEA;EACA;EACA;;;KAIU;EAAmB;EAAiB,UAAU;;EAAsB;EAAkB;;;UAGjF;EACf;EACA;EACA;;;UAIe;EACf,OAAO;EACP;;;KAQU;;UAGK;EACf;EACA;;EAEA;EACA,aAAa;EACb;EACA;;EAEA;;EAEA;;EAEA;EACA,OAAO;;;KAIG;;UAGK;EACf;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA,QAAQ;;;UAIO;EACf;EACA;EACA;EACA;EACA;EACA;EACA;;;UAIe;EACf;EACA;;;KAIU;EACN;EAAiB,cAAc;EAAoB,QAAQ;EAAc,QAAQ;;EACjF;EAAkB;;;UAGP;;EAEf;;EAEA;;EAEA;IAAU;IAAwB;;EAClC,OAAO;EACP,cAAc;EACd,QAAQ;;EAER;IAAU;IAAoB;IAAiB,SAAS;;;;UC5IzC;EACf;EACA;EACA;EACA;;;wBAMc,aAAa,kBAAkB;;;;;;wBA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;;;qBAuJnC;;wBA2EG,mBAAmB,mBAAmB,WAAW,SAAS;;;;;wBCtO1D,WAAW,MAAM;;wBAcjB,OAAO;;UAWN;EACf;EACA;EACA;EACA;;;wBAIc,WAAW,gBAAgB,cAAc;;UAaxC;EACf,aAAa;EACb,OAAO;;;wBAIO,WAAW,gBAAgB,cAAc;;wBAOzC,YAAY,gBAAgB,cAAc,OAAO;;;;;qBAkMpD;;wBAiFG,iBAAiB,MAAM,iBAAiB,SAAS;;qBC5VpD,mBAAmB;;UAGf;;EAEf;;EAEA;;EAEA;;EAEA;;EAEA;;EAEA;;EAEA;;EAEA;EACA;;EAEA;;EAEA;;EAEA;;EAEA;EACA,eAAe;;EAEf;EACA,SAAS;;;UAIM;;EAEf;EACA,UAAU;EACV,QAAQ;;;;;;;;wBAeY,MAAM,SAAS,eAAe,QAAQ;;qBA0C/C;;UAqBI;EACf;EACA,KAAK;EACL,SAAS;EACT,SAAS;EACT,eAAe;EACf;;;;;;;wBAQc,eAAe,yBAAyB,IAAI,KAAK,wBAAwB;;;;;wBAiEnE,OAAO,yBAAyB,IAAI,QAAQ"}
|
package/build/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export { b as BASE_CSS,
|
|
1
|
+
export { b as BASE_CSS, V as DEFAULT_CHANGELOGS, et as GITHUB_API, tt as GITHUB_GRAPHQL, t as HELP, Q as NPM_REGISTRY, k as OPEN_CLASSES, p as RELEASES_SCRIPT, H as ReleaseDataError, A as RoadmapParseError, j as STATUS_CLASSES, o as STATUS_SCRIPT, n as UsageError, r as build, M as buildStatusBoard, nt as checkStateOf, s as classCounts, lt as compareVersions, S as dayRange, E as escapeHtml, at as firstSentence, q as gitTagDates, rt as githubOpenWork, it as githubReleases, K as globFiles, J as headCommit, ot as headingAnchor, Y as headingDate, D as inlineMarkdown, X as isShallow, ut as kindOf, g as laneCenter, N as linksOf, C as longDate, P as markdownTables, U as mergeReleases, $ as npmPublishTimes, _ as oldestFirst, c as openGroups, Z as originRepository, x as pageShell, i as parseBuildArgs, st as parseChangelog, F as parseRoadmap, dt as parseVersion, I as plainText, W as readChangelogs, G as readReleases, L as readStatusBoard, ct as releaseBodyEntries, v as releaseSummary, m as releasesLead, h as renderReleasesPage, l as renderStatusPage, R as roadmapItems, a as runCli, O as safeUrl, u as sectionsOf, w as shortDate, d as slugOf, z as splitRow, B as statusClassOf, f as statusLead, y as timelineLayout, T as utcDay, ft as versionOfTag } from "./build-Dr35nErd.js";
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"$schema": "https://json.schemastore.org/package",
|
|
3
3
|
"name": "@mark1russell7/site-pages",
|
|
4
|
-
"version": "0.1.
|
|
4
|
+
"version": "0.1.6",
|
|
5
5
|
"description": "A release timeline page and a live status page for the site of a GitHub repository: JSON data and standalone HTML, made at deploy time.",
|
|
6
6
|
"keywords": [
|
|
7
7
|
"github-pages",
|
|
@@ -39,7 +39,7 @@
|
|
|
39
39
|
"node": ">=22"
|
|
40
40
|
},
|
|
41
41
|
"devDependencies": {
|
|
42
|
-
"@mark1russell7/cue": "
|
|
42
|
+
"@mark1russell7/cue": "^1.0.2",
|
|
43
43
|
"@types/node": "^26.6.4",
|
|
44
44
|
"tsdown": "^0.23.1",
|
|
45
45
|
"typescript": "^7.0.2",
|