@grove-dev/core 0.16.0 → 0.18.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.
- package/dist/build-data.d.ts.map +1 -1
- package/dist/build-data.js +2 -0
- package/dist/build-data.js.map +1 -1
- package/dist/candidate-collector.d.ts +61 -0
- package/dist/candidate-collector.d.ts.map +1 -0
- package/dist/candidate-collector.js +545 -0
- package/dist/candidate-collector.js.map +1 -0
- package/dist/candidate-discovery.d.ts +92 -0
- package/dist/candidate-discovery.d.ts.map +1 -0
- package/dist/candidate-discovery.js +488 -0
- package/dist/candidate-discovery.js.map +1 -0
- package/dist/candidate-schema.d.ts +209 -0
- package/dist/candidate-schema.d.ts.map +1 -0
- package/dist/candidate-schema.js +84 -0
- package/dist/candidate-schema.js.map +1 -0
- package/dist/github-cache.d.ts +87 -1
- package/dist/github-cache.d.ts.map +1 -1
- package/dist/github-cache.js +19 -1
- package/dist/github-cache.js.map +1 -1
- package/dist/image-probe.d.ts +27 -0
- package/dist/image-probe.d.ts.map +1 -0
- package/dist/image-probe.js +124 -0
- package/dist/image-probe.js.map +1 -0
- package/dist/index-policy.d.ts +48 -0
- package/dist/index-policy.d.ts.map +1 -0
- package/dist/index-policy.js +58 -0
- package/dist/index-policy.js.map +1 -0
- package/dist/index.d.ts +18 -4
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +12 -2
- package/dist/index.js.map +1 -1
- package/dist/normalize-records.d.ts +4 -3
- package/dist/normalize-records.d.ts.map +1 -1
- package/dist/normalize-records.js +10 -3
- package/dist/normalize-records.js.map +1 -1
- package/dist/page-document.d.ts +48 -0
- package/dist/page-document.d.ts.map +1 -1
- package/dist/page-document.js +93 -8
- package/dist/page-document.js.map +1 -1
- package/dist/prepare.d.ts.map +1 -1
- package/dist/prepare.js +31 -10
- package/dist/prepare.js.map +1 -1
- package/dist/record-candidates.d.ts +61 -0
- package/dist/record-candidates.d.ts.map +1 -0
- package/dist/record-candidates.js +261 -0
- package/dist/record-candidates.js.map +1 -0
- package/dist/record-markdown.d.ts +67 -0
- package/dist/record-markdown.d.ts.map +1 -0
- package/dist/record-markdown.js +244 -0
- package/dist/record-markdown.js.map +1 -0
- package/dist/schema.d.ts +78 -18
- package/dist/schema.d.ts.map +1 -1
- package/dist/schema.js +55 -2
- package/dist/schema.js.map +1 -1
- package/dist/sitemap.d.ts +3 -0
- package/dist/sitemap.d.ts.map +1 -1
- package/dist/sitemap.js +2 -0
- package/dist/sitemap.js.map +1 -1
- package/dist/validate.d.ts.map +1 -1
- package/dist/validate.js +14 -2
- package/dist/validate.js.map +1 -1
- package/package.json +1 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"record-candidates.js","sourceRoot":"","sources":["../src/record-candidates.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAC;AAC5C,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AACpC,OAAO,EAAE,KAAK,IAAI,SAAS,EAAE,MAAM,MAAM,CAAC;AAS1C,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AACpD,OAAO,EAAE,iBAAiB,EAAE,MAAM,wBAAwB,CAAC;AAC3D,OAAO,EAAE,mBAAmB,EAAoB,sBAAsB,EAAE,MAAM,aAAa,CAAC;AAE5F,sEAAsE;AAEtE,+GAA+G;AAC/G,MAAM,iBAAiB,GAAoC;IACzD,QAAQ,EAAE,CAAC;IACX,SAAS,EAAE,CAAC;IACZ,cAAc,EAAE,CAAC;IACjB,YAAY,EAAE,CAAC;IACf,MAAM,EAAE,CAAC;IACT,OAAO,EAAE,CAAC;IACV,QAAQ,EAAE,CAAC;IACX,iBAAiB,EAAE,CAAC;CACrB,CAAC;AAEF,SAAS,WAAW,CAAC,CAAqB,EAAE,CAAqB;IAC/D,MAAM,CAAC,GAAG,CAAC,IAAI,EAAE,CAAC;IAClB,MAAM,CAAC,GAAG,CAAC,IAAI,EAAE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,EAAE,CAAC,CAAC,IAAI,EAAE,CAAC;IAC/C,KAAK,MAAM,IAAI,IAAI,KAAK,EAAE,CAAC;QACzB,IAAI,OAAO,CAAC,IAAI,IAAI,IAAI,KAAK,OAAO,CAAC,IAAI;YAAE,SAAS;QACpD,MAAM,KAAK,GAAG,KAAK,CAAC,OAAO,CAAC,GAAG,CAAC,IAAI,CAAC,CAAC;QACtC,IAAI,CAAC,KAAK,EAAE,UAAU;YAAE,SAAS;QACjC,qBAAqB,IAAI,CAAC,CAAC;QAC3B,KAAK,MAAM,GAAG,IAAI,aAAa,CAAC,IAAI,EAAE,KAAK,CAAC,UAAU,EAAE,OAAO,EAAE,OAAO,CAAC,GAAG,CAAC,IAAI,CAAC,CAAC,EAAE,CAAC;YACpF,IAAI,OAAO,CAAC,GAAG,IAAI,GAAG,CAAC,MAAM,KAAK,SAAS;gBAAE,IAAI,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;QAC9D,CAAC;IACH,CAAC;IACD,OAAO,EAAE,IAAI,EAAE,qBAAqB,EAAE,GAAG,CAAC,KAAK,CAAC,CAAC,CAAC,EAAE,cAAc,EAAE,KAAK,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC;AACtF,CAAC"}
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Codemod one YAML record into a Markdown record: YAML frontmatter
|
|
3
|
+
* followed by the record's review body. `grove migrate markdown-records`
|
|
4
|
+
* runs it over a whole site; the normalizer
|
|
5
|
+
* (`loadNormalizedRecords`) must read the result back to the same
|
|
6
|
+
* record, and {@link yamlRecordToMarkdown} refuses rather than write a
|
|
7
|
+
* file it would not.
|
|
8
|
+
*
|
|
9
|
+
* Every field is kept except the three the normalizer derives
|
|
10
|
+
* identically for a Markdown record:
|
|
11
|
+
*
|
|
12
|
+
* - `slug`, when it equals the file name (the file name is the slug);
|
|
13
|
+
* - `kind`, when it equals the blueprint's kind (filled in on read);
|
|
14
|
+
* - `content`, the pointer (a Markdown record is its own body).
|
|
15
|
+
*
|
|
16
|
+
* Each top-level field keeps its own text: its value, style, quoting
|
|
17
|
+
* and any `#` comments directly above it move with it. Only the order
|
|
18
|
+
* of the fields changes, to {@link MARKDOWN_RECORD_FIELD_ORDER}.
|
|
19
|
+
*/
|
|
20
|
+
/**
|
|
21
|
+
* Frontmatter field order. What a contributor writes comes first (what
|
|
22
|
+
* it is, what it runs on, where to get it, why it is listed), then the
|
|
23
|
+
* reviewer's fields. A field not listed here keeps its original
|
|
24
|
+
* relative order, after the contributor fields and before the reviewer
|
|
25
|
+
* ones.
|
|
26
|
+
*/
|
|
27
|
+
export declare const MARKDOWN_RECORD_FIELD_ORDER: {
|
|
28
|
+
readonly contributor: readonly ["name", "title", "repoUrl", "projectType", "type", "category", "topic", "stack", "stacks", "summary", "description", "sourceDescription", "platforms", "licenses", "links", "distribution", "logoUrl", "screenshots", "tags", "bestFor", "whyListed", "caveats", "difficulty", "codebaseSize", "author", "publishedAt", "founded", "location", "members", "parent", "related", "relations", "seo", "addedAt"];
|
|
29
|
+
readonly reviewer: readonly ["source", "curation", "scores", "visibility"];
|
|
30
|
+
};
|
|
31
|
+
export interface YamlRecordToMarkdownOptions {
|
|
32
|
+
/**
|
|
33
|
+
* The kind the blueprint gives every record (`project`, `resource`,
|
|
34
|
+
* `entity`); a `kind:` with this value is dropped.
|
|
35
|
+
*/
|
|
36
|
+
kind?: string;
|
|
37
|
+
/**
|
|
38
|
+
* The field that marks frontmatter as a record: `name`, or `title` on
|
|
39
|
+
* a resource hub. The loader ignores a Markdown file without it, so a
|
|
40
|
+
* record without it is refused.
|
|
41
|
+
*/
|
|
42
|
+
labelKey?: string;
|
|
43
|
+
/**
|
|
44
|
+
* The record's review body, verbatim, without frontmatter. Omitted or
|
|
45
|
+
* `''` for a record with no body.
|
|
46
|
+
*/
|
|
47
|
+
body?: string;
|
|
48
|
+
}
|
|
49
|
+
export type YamlRecordToMarkdownResult = {
|
|
50
|
+
ok: true;
|
|
51
|
+
/** The Markdown record: `---`, frontmatter, `---`, then the body byte-for-byte. */
|
|
52
|
+
text: string;
|
|
53
|
+
/** Top-level fields left out because the normalizer derives them. */
|
|
54
|
+
dropped: string[];
|
|
55
|
+
} | {
|
|
56
|
+
ok: false;
|
|
57
|
+
/** Why the record cannot be converted as it stands. */
|
|
58
|
+
reason: string;
|
|
59
|
+
};
|
|
60
|
+
/**
|
|
61
|
+
* Turn one YAML record's text (and its body) into a Markdown record.
|
|
62
|
+
* Refuses, with a reason, a record that is not a YAML mapping, still
|
|
63
|
+
* carries inline `github`/`health`, has no `labelKey`, or would not
|
|
64
|
+
* read back as the same fields and the same body.
|
|
65
|
+
*/
|
|
66
|
+
export declare function yamlRecordToMarkdown(slug: string, yamlText: string, options?: YamlRecordToMarkdownOptions): YamlRecordToMarkdownResult;
|
|
67
|
+
//# sourceMappingURL=record-markdown.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"record-markdown.d.ts","sourceRoot":"","sources":["../src/record-markdown.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAKH;;;;;;GAMG;AACH,eAAO,MAAM,2BAA2B;;;CAsC9B,CAAC;AAKX,MAAM,WAAW,2BAA2B;IAC1C;;;OAGG;IACH,IAAI,CAAC,EAAE,MAAM,CAAC;IACd;;;;OAIG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB;;;OAGG;IACH,IAAI,CAAC,EAAE,MAAM,CAAC;CACf;AAED,MAAM,MAAM,0BAA0B,GAClC;IACE,EAAE,EAAE,IAAI,CAAC;IACT,mFAAmF;IACnF,IAAI,EAAE,MAAM,CAAC;IACb,qEAAqE;IACrE,OAAO,EAAE,MAAM,EAAE,CAAC;CACnB,GACD;IACE,EAAE,EAAE,KAAK,CAAC;IACV,uDAAuD;IACvD,MAAM,EAAE,MAAM,CAAC;CAChB,CAAC;AA4GN;;;;;GAKG;AACH,wBAAgB,oBAAoB,CAClC,IAAI,EAAE,MAAM,EACZ,QAAQ,EAAE,MAAM,EAChB,OAAO,GAAE,2BAAgC,GACxC,0BAA0B,CA6D5B"}
|
|
@@ -0,0 +1,244 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Codemod one YAML record into a Markdown record: YAML frontmatter
|
|
3
|
+
* followed by the record's review body. `grove migrate markdown-records`
|
|
4
|
+
* runs it over a whole site; the normalizer
|
|
5
|
+
* (`loadNormalizedRecords`) must read the result back to the same
|
|
6
|
+
* record, and {@link yamlRecordToMarkdown} refuses rather than write a
|
|
7
|
+
* file it would not.
|
|
8
|
+
*
|
|
9
|
+
* Every field is kept except the three the normalizer derives
|
|
10
|
+
* identically for a Markdown record:
|
|
11
|
+
*
|
|
12
|
+
* - `slug`, when it equals the file name (the file name is the slug);
|
|
13
|
+
* - `kind`, when it equals the blueprint's kind (filled in on read);
|
|
14
|
+
* - `content`, the pointer (a Markdown record is its own body).
|
|
15
|
+
*
|
|
16
|
+
* Each top-level field keeps its own text: its value, style, quoting
|
|
17
|
+
* and any `#` comments directly above it move with it. Only the order
|
|
18
|
+
* of the fields changes, to {@link MARKDOWN_RECORD_FIELD_ORDER}.
|
|
19
|
+
*/
|
|
20
|
+
import { parseDocument, parse as parseYaml } from 'yaml';
|
|
21
|
+
import { splitFrontmatter } from './content-body.js';
|
|
22
|
+
/**
|
|
23
|
+
* Frontmatter field order. What a contributor writes comes first (what
|
|
24
|
+
* it is, what it runs on, where to get it, why it is listed), then the
|
|
25
|
+
* reviewer's fields. A field not listed here keeps its original
|
|
26
|
+
* relative order, after the contributor fields and before the reviewer
|
|
27
|
+
* ones.
|
|
28
|
+
*/
|
|
29
|
+
export const MARKDOWN_RECORD_FIELD_ORDER = {
|
|
30
|
+
contributor: [
|
|
31
|
+
'name',
|
|
32
|
+
'title',
|
|
33
|
+
'repoUrl',
|
|
34
|
+
'projectType',
|
|
35
|
+
'type',
|
|
36
|
+
'category',
|
|
37
|
+
'topic',
|
|
38
|
+
'stack',
|
|
39
|
+
'stacks',
|
|
40
|
+
'summary',
|
|
41
|
+
'description',
|
|
42
|
+
'sourceDescription',
|
|
43
|
+
'platforms',
|
|
44
|
+
'licenses',
|
|
45
|
+
'links',
|
|
46
|
+
'distribution',
|
|
47
|
+
'logoUrl',
|
|
48
|
+
'screenshots',
|
|
49
|
+
'tags',
|
|
50
|
+
'bestFor',
|
|
51
|
+
'whyListed',
|
|
52
|
+
'caveats',
|
|
53
|
+
'difficulty',
|
|
54
|
+
'codebaseSize',
|
|
55
|
+
'author',
|
|
56
|
+
'publishedAt',
|
|
57
|
+
'founded',
|
|
58
|
+
'location',
|
|
59
|
+
'members',
|
|
60
|
+
'parent',
|
|
61
|
+
'related',
|
|
62
|
+
'relations',
|
|
63
|
+
'seo',
|
|
64
|
+
'addedAt',
|
|
65
|
+
],
|
|
66
|
+
reviewer: ['source', 'curation', 'scores', 'visibility'],
|
|
67
|
+
};
|
|
68
|
+
/** Generated layers `grove migrate github-cache` moves out first. */
|
|
69
|
+
const GENERATED_KEYS = ['github', 'health'];
|
|
70
|
+
function isMapping(value) {
|
|
71
|
+
return value !== null && typeof value === 'object' && !Array.isArray(value);
|
|
72
|
+
}
|
|
73
|
+
/**
|
|
74
|
+
* JSON with the top level sorted: the frontmatter reorders top-level
|
|
75
|
+
* fields on purpose, but everything below them (a `links` map, the
|
|
76
|
+
* order of `distribution.channels`) must come back exactly as it was.
|
|
77
|
+
*/
|
|
78
|
+
function topLevelSorted(value) {
|
|
79
|
+
return JSON.stringify(Object.keys(value)
|
|
80
|
+
.sort()
|
|
81
|
+
.map((key) => [key, value[key]]));
|
|
82
|
+
}
|
|
83
|
+
function rank(key, index) {
|
|
84
|
+
const contributor = MARKDOWN_RECORD_FIELD_ORDER.contributor.indexOf(key);
|
|
85
|
+
if (contributor >= 0)
|
|
86
|
+
return [0, contributor];
|
|
87
|
+
const reviewer = MARKDOWN_RECORD_FIELD_ORDER.reviewer.indexOf(key);
|
|
88
|
+
if (reviewer >= 0)
|
|
89
|
+
return [2, reviewer];
|
|
90
|
+
return [1, index];
|
|
91
|
+
}
|
|
92
|
+
function sortFields(fields) {
|
|
93
|
+
return [...fields].sort((a, b) => {
|
|
94
|
+
const [groupA, orderA] = rank(a.key, a.index);
|
|
95
|
+
const [groupB, orderB] = rank(b.key, b.index);
|
|
96
|
+
return groupA - groupB || orderA - orderB;
|
|
97
|
+
});
|
|
98
|
+
}
|
|
99
|
+
/** Offset of the start of the line containing `offset`. */
|
|
100
|
+
function lineStart(text, offset) {
|
|
101
|
+
return text.lastIndexOf('\n', offset - 1) + 1;
|
|
102
|
+
}
|
|
103
|
+
/**
|
|
104
|
+
* Reorder a block mapping's top-level fields by moving text: each field
|
|
105
|
+
* runs from its key line (plus the `#` comment lines directly above it)
|
|
106
|
+
* to the next field. Returns `undefined` when the text is not a plain
|
|
107
|
+
* block mapping this can cut safely.
|
|
108
|
+
*/
|
|
109
|
+
function reorderByText(text, drop) {
|
|
110
|
+
const doc = parseDocument(text, { schema: 'core' });
|
|
111
|
+
const contents = doc.contents;
|
|
112
|
+
if (!contents || !Array.isArray(contents.items))
|
|
113
|
+
return undefined;
|
|
114
|
+
const fields = [];
|
|
115
|
+
for (const [index, item] of contents.items.entries()) {
|
|
116
|
+
const keyNode = item.key;
|
|
117
|
+
const key = keyNode?.value;
|
|
118
|
+
const at = keyNode?.range?.[0];
|
|
119
|
+
if (typeof key !== 'string' || at === undefined)
|
|
120
|
+
return undefined;
|
|
121
|
+
let start = lineStart(text, at);
|
|
122
|
+
// A key not at column zero means a flow mapping or odd layout.
|
|
123
|
+
if (start !== at)
|
|
124
|
+
return undefined;
|
|
125
|
+
// Comment lines directly above a field belong to it.
|
|
126
|
+
while (start > 0) {
|
|
127
|
+
const previous = lineStart(text, start - 1);
|
|
128
|
+
if (!text.slice(previous, start).startsWith('#'))
|
|
129
|
+
break;
|
|
130
|
+
start = previous;
|
|
131
|
+
}
|
|
132
|
+
fields.push({ key, index, start });
|
|
133
|
+
}
|
|
134
|
+
if (fields.length === 0)
|
|
135
|
+
return undefined;
|
|
136
|
+
// Leading comments that no field claimed (a file header) stay on top;
|
|
137
|
+
// a `---` document marker or directive does not.
|
|
138
|
+
const preamble = text
|
|
139
|
+
.slice(0, fields[0]?.start ?? 0)
|
|
140
|
+
.split('\n')
|
|
141
|
+
.filter((line) => line.startsWith('#'))
|
|
142
|
+
.map((line) => `${line}\n`)
|
|
143
|
+
.join('');
|
|
144
|
+
const blocks = fields.map((field, i) => {
|
|
145
|
+
const end = fields[i + 1]?.start ?? text.length;
|
|
146
|
+
// Blank lines between fields are dropped; each block ends in one newline.
|
|
147
|
+
const block = text.slice(field.start, end).replace(/\s+$/, '');
|
|
148
|
+
return { ...field, block: `${block}\n` };
|
|
149
|
+
});
|
|
150
|
+
return (preamble +
|
|
151
|
+
sortFields(blocks.filter((block) => !drop.has(block.key)))
|
|
152
|
+
.map((block) => block.block)
|
|
153
|
+
.join(''));
|
|
154
|
+
}
|
|
155
|
+
/** Reorder through the YAML document model; loses nothing but layout. */
|
|
156
|
+
function reorderByDocument(text, drop) {
|
|
157
|
+
const doc = parseDocument(text, { schema: 'core' });
|
|
158
|
+
const contents = doc.contents;
|
|
159
|
+
if (!contents || !Array.isArray(contents.items))
|
|
160
|
+
return undefined;
|
|
161
|
+
contents.flow = false;
|
|
162
|
+
const items = contents.items.map((item, index) => ({
|
|
163
|
+
item,
|
|
164
|
+
index,
|
|
165
|
+
key: String(item.key?.value ?? ''),
|
|
166
|
+
}));
|
|
167
|
+
contents.items = sortFields(items.filter((entry) => !drop.has(entry.key))).map((entry) => entry.item);
|
|
168
|
+
const out = doc.toString({ lineWidth: 0 });
|
|
169
|
+
return out.startsWith('---\n') ? out.slice(4) : out;
|
|
170
|
+
}
|
|
171
|
+
/**
|
|
172
|
+
* Turn one YAML record's text (and its body) into a Markdown record.
|
|
173
|
+
* Refuses, with a reason, a record that is not a YAML mapping, still
|
|
174
|
+
* carries inline `github`/`health`, has no `labelKey`, or would not
|
|
175
|
+
* read back as the same fields and the same body.
|
|
176
|
+
*/
|
|
177
|
+
export function yamlRecordToMarkdown(slug, yamlText, options = {}) {
|
|
178
|
+
const labelKey = options.labelKey ?? 'name';
|
|
179
|
+
const body = options.body ?? '';
|
|
180
|
+
const text = yamlText.replace(/\r\n/g, '\n');
|
|
181
|
+
let data;
|
|
182
|
+
try {
|
|
183
|
+
data = parseYaml(text, { schema: 'core' });
|
|
184
|
+
}
|
|
185
|
+
catch (err) {
|
|
186
|
+
return { ok: false, reason: `YAML does not parse: ${err.message}` };
|
|
187
|
+
}
|
|
188
|
+
if (!isMapping(data))
|
|
189
|
+
return { ok: false, reason: 'record file is empty or not a YAML mapping' };
|
|
190
|
+
const generated = GENERATED_KEYS.filter((key) => data[key] !== undefined);
|
|
191
|
+
if (generated.length > 0) {
|
|
192
|
+
return {
|
|
193
|
+
ok: false,
|
|
194
|
+
reason: `carries inline ${generated.join('/')}; run \`grove migrate github-cache\` first`,
|
|
195
|
+
};
|
|
196
|
+
}
|
|
197
|
+
if (data[labelKey] === undefined) {
|
|
198
|
+
return {
|
|
199
|
+
ok: false,
|
|
200
|
+
reason: `has no \`${labelKey}\`, so a Markdown file would not be a record`,
|
|
201
|
+
};
|
|
202
|
+
}
|
|
203
|
+
const dropped = [];
|
|
204
|
+
if (data.content !== undefined)
|
|
205
|
+
dropped.push('content');
|
|
206
|
+
if (data.slug === slug)
|
|
207
|
+
dropped.push('slug');
|
|
208
|
+
if (options.kind !== undefined && data.kind === options.kind)
|
|
209
|
+
dropped.push('kind');
|
|
210
|
+
const drop = new Set(dropped);
|
|
211
|
+
const expected = { ...data };
|
|
212
|
+
for (const key of dropped)
|
|
213
|
+
delete expected[key];
|
|
214
|
+
// Accept a frontmatter only if the loader reads it back as exactly
|
|
215
|
+
// these fields and this body.
|
|
216
|
+
const readsBack = (frontmatter) => {
|
|
217
|
+
if (frontmatter === undefined)
|
|
218
|
+
return undefined;
|
|
219
|
+
const candidate = `---\n${frontmatter}---\n${body}`;
|
|
220
|
+
const split = splitFrontmatter(candidate);
|
|
221
|
+
if (!split.hasFrontmatter || split.body !== body)
|
|
222
|
+
return undefined;
|
|
223
|
+
let parsed;
|
|
224
|
+
try {
|
|
225
|
+
parsed = parseYaml(split.frontmatter, { schema: 'core' });
|
|
226
|
+
}
|
|
227
|
+
catch {
|
|
228
|
+
return undefined;
|
|
229
|
+
}
|
|
230
|
+
if (!isMapping(parsed) || topLevelSorted(parsed) !== topLevelSorted(expected)) {
|
|
231
|
+
return undefined;
|
|
232
|
+
}
|
|
233
|
+
return candidate;
|
|
234
|
+
};
|
|
235
|
+
const out = readsBack(reorderByText(text, drop)) ?? readsBack(reorderByDocument(text, drop));
|
|
236
|
+
if (out === undefined) {
|
|
237
|
+
return {
|
|
238
|
+
ok: false,
|
|
239
|
+
reason: 'the Markdown file would not read back as the same record (frontmatter over 198 lines, a `---` line inside a value, or a body with CRLF line endings)',
|
|
240
|
+
};
|
|
241
|
+
}
|
|
242
|
+
return { ok: true, text: out, dropped };
|
|
243
|
+
}
|
|
244
|
+
//# sourceMappingURL=record-markdown.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"record-markdown.js","sourceRoot":"","sources":["../src/record-markdown.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAEH,OAAO,EAAE,aAAa,EAAE,KAAK,IAAI,SAAS,EAAE,MAAM,MAAM,CAAC;AACzD,OAAO,EAAE,gBAAgB,EAAE,MAAM,mBAAmB,CAAC;AAErD;;;;;;GAMG;AACH,MAAM,CAAC,MAAM,2BAA2B,GAAG;IACzC,WAAW,EAAE;QACX,MAAM;QACN,OAAO;QACP,SAAS;QACT,aAAa;QACb,MAAM;QACN,UAAU;QACV,OAAO;QACP,OAAO;QACP,QAAQ;QACR,SAAS;QACT,aAAa;QACb,mBAAmB;QACnB,WAAW;QACX,UAAU;QACV,OAAO;QACP,cAAc;QACd,SAAS;QACT,aAAa;QACb,MAAM;QACN,SAAS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AC,WAAW,EAAE,EAAE,MAAM,EAAE,MAAM,EAAE,CAAC,CAAC;QAC5D,CAAC;QAAC,MAAM,CAAC;YACP,OAAO,SAAS,CAAC;QACnB,CAAC;QACD,IAAI,CAAC,SAAS,CAAC,MAAM,CAAC,IAAI,cAAc,CAAC,MAAM,CAAC,KAAK,cAAc,CAAC,QAAQ,CAAC,EAAE,CAAC;YAC9E,OAAO,SAAS,CAAC;QACnB,CAAC;QACD,OAAO,SAAS,CAAC;IACnB,CAAC,CAAC;IAEF,MAAM,GAAG,GAAG,SAAS,CAAC,aAAa,CAAC,IAAI,EAAE,IAAI,CAAC,CAAC,IAAI,SAAS,CAAC,iBAAiB,CAAC,IAAI,EAAE,IAAI,CAAC,CAAC,CAAC;IAC7F,IAAI,GAAG,KAAK,SAAS,EAAE,CAAC;QACtB,OAAO;YACL,EAAE,EAAE,KAAK;YACT,MAAM,EACJ,sJAAsJ;SACzJ,CAAC;IACJ,CAAC;IACD,OAAO,EAAE,EAAE,EAAE,IAAI,EAAE,IAAI,EAAE,GAAG,EAAE,OAAO,EAAE,CAAC;AAC1C,CAAC"}
|
package/dist/schema.d.ts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
|
+
import { type CandidateReview } from './candidate-schema.js';
|
|
2
3
|
/**
|
|
3
4
|
* A blueprint defines the shape and behavior of a Grove site.
|
|
4
5
|
*
|
|
@@ -24,12 +25,12 @@ export declare const resourceKindSchema: z.ZodEnum<{
|
|
|
24
25
|
export type ResourceKind = z.infer<typeof resourceKindSchema>;
|
|
25
26
|
export declare const blueprintKind: Record<Blueprint, ResourceKind>;
|
|
26
27
|
export declare const healthStatusSchema: z.ZodEnum<{
|
|
28
|
+
unknown: "unknown";
|
|
27
29
|
active: "active";
|
|
28
30
|
mature: "mature";
|
|
29
31
|
stale: "stale";
|
|
30
32
|
inactive: "inactive";
|
|
31
33
|
archived: "archived";
|
|
32
|
-
unknown: "unknown";
|
|
33
34
|
historical: "historical";
|
|
34
35
|
needs_review: "needs_review";
|
|
35
36
|
quiet: "quiet";
|
|
@@ -182,20 +183,20 @@ export declare const githubMetadataSchema: z.ZodObject<{
|
|
|
182
183
|
}, z.core.$strip>;
|
|
183
184
|
export declare const healthBlockSchema: z.ZodObject<{
|
|
184
185
|
status: z.ZodDefault<z.ZodEnum<{
|
|
186
|
+
unknown: "unknown";
|
|
185
187
|
active: "active";
|
|
186
188
|
mature: "mature";
|
|
187
189
|
stale: "stale";
|
|
188
190
|
inactive: "inactive";
|
|
189
191
|
archived: "archived";
|
|
190
|
-
unknown: "unknown";
|
|
191
192
|
historical: "historical";
|
|
192
193
|
needs_review: "needs_review";
|
|
193
194
|
quiet: "quiet";
|
|
194
195
|
unavailable: "unavailable";
|
|
195
196
|
}>>;
|
|
196
197
|
maturity: z.ZodDefault<z.ZodEnum<{
|
|
197
|
-
mature: "mature";
|
|
198
198
|
unknown: "unknown";
|
|
199
|
+
mature: "mature";
|
|
199
200
|
experimental: "experimental";
|
|
200
201
|
useful: "useful";
|
|
201
202
|
}>>;
|
|
@@ -259,20 +260,20 @@ export declare const healthEntrySchema: z.ZodObject<{
|
|
|
259
260
|
}, z.core.$strip>>;
|
|
260
261
|
health: z.ZodObject<{
|
|
261
262
|
status: z.ZodDefault<z.ZodEnum<{
|
|
263
|
+
unknown: "unknown";
|
|
262
264
|
active: "active";
|
|
263
265
|
mature: "mature";
|
|
264
266
|
stale: "stale";
|
|
265
267
|
inactive: "inactive";
|
|
266
268
|
archived: "archived";
|
|
267
|
-
unknown: "unknown";
|
|
268
269
|
historical: "historical";
|
|
269
270
|
needs_review: "needs_review";
|
|
270
271
|
quiet: "quiet";
|
|
271
272
|
unavailable: "unavailable";
|
|
272
273
|
}>>;
|
|
273
274
|
maturity: z.ZodDefault<z.ZodEnum<{
|
|
274
|
-
mature: "mature";
|
|
275
275
|
unknown: "unknown";
|
|
276
|
+
mature: "mature";
|
|
276
277
|
experimental: "experimental";
|
|
277
278
|
useful: "useful";
|
|
278
279
|
}>>;
|
|
@@ -337,20 +338,20 @@ export declare const healthFileSchema: z.ZodUnion<readonly [z.ZodArray<z.ZodObje
|
|
|
337
338
|
}, z.core.$strip>>;
|
|
338
339
|
health: z.ZodObject<{
|
|
339
340
|
status: z.ZodDefault<z.ZodEnum<{
|
|
341
|
+
unknown: "unknown";
|
|
340
342
|
active: "active";
|
|
341
343
|
mature: "mature";
|
|
342
344
|
stale: "stale";
|
|
343
345
|
inactive: "inactive";
|
|
344
346
|
archived: "archived";
|
|
345
|
-
unknown: "unknown";
|
|
346
347
|
historical: "historical";
|
|
347
348
|
needs_review: "needs_review";
|
|
348
349
|
quiet: "quiet";
|
|
349
350
|
unavailable: "unavailable";
|
|
350
351
|
}>>;
|
|
351
352
|
maturity: z.ZodDefault<z.ZodEnum<{
|
|
352
|
-
mature: "mature";
|
|
353
353
|
unknown: "unknown";
|
|
354
|
+
mature: "mature";
|
|
354
355
|
experimental: "experimental";
|
|
355
356
|
useful: "useful";
|
|
356
357
|
}>>;
|
|
@@ -415,20 +416,20 @@ export declare const healthFileSchema: z.ZodUnion<readonly [z.ZodArray<z.ZodObje
|
|
|
415
416
|
}, z.core.$strip>>;
|
|
416
417
|
health: z.ZodObject<{
|
|
417
418
|
status: z.ZodDefault<z.ZodEnum<{
|
|
419
|
+
unknown: "unknown";
|
|
418
420
|
active: "active";
|
|
419
421
|
mature: "mature";
|
|
420
422
|
stale: "stale";
|
|
421
423
|
inactive: "inactive";
|
|
422
424
|
archived: "archived";
|
|
423
|
-
unknown: "unknown";
|
|
424
425
|
historical: "historical";
|
|
425
426
|
needs_review: "needs_review";
|
|
426
427
|
quiet: "quiet";
|
|
427
428
|
unavailable: "unavailable";
|
|
428
429
|
}>>;
|
|
429
430
|
maturity: z.ZodDefault<z.ZodEnum<{
|
|
430
|
-
mature: "mature";
|
|
431
431
|
unknown: "unknown";
|
|
432
|
+
mature: "mature";
|
|
432
433
|
experimental: "experimental";
|
|
433
434
|
useful: "useful";
|
|
434
435
|
}>>;
|
|
@@ -473,6 +474,11 @@ export declare const decisionSchema: z.ZodObject<{
|
|
|
473
474
|
reviewedAt: z.ZodOptional<z.ZodString>;
|
|
474
475
|
}, z.core.$strip>;
|
|
475
476
|
}, z.core.$strip>;
|
|
477
|
+
/**
|
|
478
|
+
* `paths.decisions`: a list of decisions, or an object with
|
|
479
|
+
* `decisions:` and, since candidates exist, `candidates:` — the
|
|
480
|
+
* reviewer's verdicts on channel and media candidates.
|
|
481
|
+
*/
|
|
476
482
|
export declare const decisionsFileSchema: z.ZodUnion<readonly [z.ZodArray<z.ZodObject<{
|
|
477
483
|
id: z.ZodString;
|
|
478
484
|
decision: z.ZodObject<{
|
|
@@ -489,7 +495,7 @@ export declare const decisionsFileSchema: z.ZodUnion<readonly [z.ZodArray<z.ZodO
|
|
|
489
495
|
reviewedAt: z.ZodOptional<z.ZodString>;
|
|
490
496
|
}, z.core.$strip>;
|
|
491
497
|
}, z.core.$strip>>, z.ZodObject<{
|
|
492
|
-
decisions: z.ZodArray<z.ZodObject<{
|
|
498
|
+
decisions: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
493
499
|
id: z.ZodString;
|
|
494
500
|
decision: z.ZodObject<{
|
|
495
501
|
visibility: z.ZodEnum<{
|
|
@@ -504,7 +510,37 @@ export declare const decisionsFileSchema: z.ZodUnion<readonly [z.ZodArray<z.ZodO
|
|
|
504
510
|
reviewedBy: z.ZodOptional<z.ZodString>;
|
|
505
511
|
reviewedAt: z.ZodOptional<z.ZodString>;
|
|
506
512
|
}, z.core.$strip>;
|
|
507
|
-
}, z.core.$strip
|
|
513
|
+
}, z.core.$strip>>>;
|
|
514
|
+
candidates: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
515
|
+
id: z.ZodString;
|
|
516
|
+
kind: z.ZodEnum<{
|
|
517
|
+
channel: "channel";
|
|
518
|
+
logo: "logo";
|
|
519
|
+
screenshot: "screenshot";
|
|
520
|
+
}>;
|
|
521
|
+
url: z.ZodString;
|
|
522
|
+
verdict: z.ZodEnum<{
|
|
523
|
+
approved: "approved";
|
|
524
|
+
rejected: "rejected";
|
|
525
|
+
}>;
|
|
526
|
+
reason: z.ZodOptional<z.ZodString>;
|
|
527
|
+
reviewedBy: z.ZodOptional<z.ZodString>;
|
|
528
|
+
reviewedAt: z.ZodOptional<z.ZodString>;
|
|
529
|
+
provenance: z.ZodObject<{
|
|
530
|
+
source: z.ZodEnum<{
|
|
531
|
+
fdroid: "fdroid";
|
|
532
|
+
flathub: "flathub";
|
|
533
|
+
repology: "repology";
|
|
534
|
+
"github-releases": "github-releases";
|
|
535
|
+
fastlane: "fastlane";
|
|
536
|
+
appstream: "appstream";
|
|
537
|
+
"web-manifest": "web-manifest";
|
|
538
|
+
"repo-asset": "repo-asset";
|
|
539
|
+
}>;
|
|
540
|
+
url: z.ZodString;
|
|
541
|
+
fetchedAt: z.ZodString;
|
|
542
|
+
}, z.core.$strip>;
|
|
543
|
+
}, z.core.$strip>>>;
|
|
508
544
|
}, z.core.$strip>]>;
|
|
509
545
|
export declare const overrideSchema: z.ZodObject<{
|
|
510
546
|
id: z.ZodString;
|
|
@@ -751,20 +787,20 @@ export declare const projectRecordSchema: z.ZodObject<{
|
|
|
751
787
|
}, z.core.$loose>>;
|
|
752
788
|
health: z.ZodOptional<z.ZodObject<{
|
|
753
789
|
status: z.ZodDefault<z.ZodEnum<{
|
|
790
|
+
unknown: "unknown";
|
|
754
791
|
active: "active";
|
|
755
792
|
mature: "mature";
|
|
756
793
|
stale: "stale";
|
|
757
794
|
inactive: "inactive";
|
|
758
795
|
archived: "archived";
|
|
759
|
-
unknown: "unknown";
|
|
760
796
|
historical: "historical";
|
|
761
797
|
needs_review: "needs_review";
|
|
762
798
|
quiet: "quiet";
|
|
763
799
|
unavailable: "unavailable";
|
|
764
800
|
}>>;
|
|
765
801
|
maturity: z.ZodDefault<z.ZodEnum<{
|
|
766
|
-
mature: "mature";
|
|
767
802
|
unknown: "unknown";
|
|
803
|
+
mature: "mature";
|
|
768
804
|
experimental: "experimental";
|
|
769
805
|
useful: "useful";
|
|
770
806
|
}>>;
|
|
@@ -1163,20 +1199,20 @@ export declare const resourceSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
1163
1199
|
}, z.core.$loose>>;
|
|
1164
1200
|
health: z.ZodOptional<z.ZodObject<{
|
|
1165
1201
|
status: z.ZodDefault<z.ZodEnum<{
|
|
1202
|
+
unknown: "unknown";
|
|
1166
1203
|
active: "active";
|
|
1167
1204
|
mature: "mature";
|
|
1168
1205
|
stale: "stale";
|
|
1169
1206
|
inactive: "inactive";
|
|
1170
1207
|
archived: "archived";
|
|
1171
|
-
unknown: "unknown";
|
|
1172
1208
|
historical: "historical";
|
|
1173
1209
|
needs_review: "needs_review";
|
|
1174
1210
|
quiet: "quiet";
|
|
1175
1211
|
unavailable: "unavailable";
|
|
1176
1212
|
}>>;
|
|
1177
1213
|
maturity: z.ZodDefault<z.ZodEnum<{
|
|
1178
|
-
mature: "mature";
|
|
1179
1214
|
unknown: "unknown";
|
|
1215
|
+
mature: "mature";
|
|
1180
1216
|
experimental: "experimental";
|
|
1181
1217
|
useful: "useful";
|
|
1182
1218
|
}>>;
|
|
@@ -1571,20 +1607,20 @@ export declare const recordsFileSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
1571
1607
|
}, z.core.$loose>>;
|
|
1572
1608
|
health: z.ZodOptional<z.ZodObject<{
|
|
1573
1609
|
status: z.ZodDefault<z.ZodEnum<{
|
|
1610
|
+
unknown: "unknown";
|
|
1574
1611
|
active: "active";
|
|
1575
1612
|
mature: "mature";
|
|
1576
1613
|
stale: "stale";
|
|
1577
1614
|
inactive: "inactive";
|
|
1578
1615
|
archived: "archived";
|
|
1579
|
-
unknown: "unknown";
|
|
1580
1616
|
historical: "historical";
|
|
1581
1617
|
needs_review: "needs_review";
|
|
1582
1618
|
quiet: "quiet";
|
|
1583
1619
|
unavailable: "unavailable";
|
|
1584
1620
|
}>>;
|
|
1585
1621
|
maturity: z.ZodDefault<z.ZodEnum<{
|
|
1586
|
-
mature: "mature";
|
|
1587
1622
|
unknown: "unknown";
|
|
1623
|
+
mature: "mature";
|
|
1588
1624
|
experimental: "experimental";
|
|
1589
1625
|
useful: "useful";
|
|
1590
1626
|
}>>;
|
|
@@ -1850,12 +1886,14 @@ export declare const githubIntegrationSchema: z.ZodUnion<readonly [z.ZodBoolean,
|
|
|
1850
1886
|
metadata: z.ZodDefault<z.ZodBoolean>;
|
|
1851
1887
|
contributors: z.ZodDefault<z.ZodBoolean>;
|
|
1852
1888
|
health: z.ZodDefault<z.ZodBoolean>;
|
|
1889
|
+
candidates: z.ZodDefault<z.ZodBoolean>;
|
|
1853
1890
|
}, z.core.$strip>]>;
|
|
1854
1891
|
/** Resolved per-feature GitHub integration flags. */
|
|
1855
1892
|
export interface GithubIntegrationFlags {
|
|
1856
1893
|
metadata: boolean;
|
|
1857
1894
|
contributors: boolean;
|
|
1858
1895
|
health: boolean;
|
|
1896
|
+
candidates: boolean;
|
|
1859
1897
|
}
|
|
1860
1898
|
/**
|
|
1861
1899
|
* Normalize the `integrations.github` config value — either a blanket
|
|
@@ -1919,6 +1957,10 @@ export declare const readmeConfigSchema: z.ZodObject<{
|
|
|
1919
1957
|
detail: "detail";
|
|
1920
1958
|
}>>;
|
|
1921
1959
|
}, z.core.$strip>;
|
|
1960
|
+
/** Values of `seo.recordIndexPolicy` — see `index-policy.ts`. */
|
|
1961
|
+
export declare const RECORD_INDEX_POLICIES: readonly ["all", "editorial", "editorial-and-reviewed"];
|
|
1962
|
+
/** Values of `seo.collectionIndexPolicy` / `seo.taxonomyIndexPolicy`. */
|
|
1963
|
+
export declare const LISTING_INDEX_POLICIES: readonly ["all", "editorial"];
|
|
1922
1964
|
export declare const groveConfigSchema: z.ZodObject<{
|
|
1923
1965
|
blueprint: z.ZodDefault<z.ZodEnum<{
|
|
1924
1966
|
"project-directory": "project-directory";
|
|
@@ -1936,6 +1978,21 @@ export declare const groveConfigSchema: z.ZodObject<{
|
|
|
1936
1978
|
locale: z.ZodDefault<z.ZodString>;
|
|
1937
1979
|
twitter: z.ZodOptional<z.ZodString>;
|
|
1938
1980
|
}, z.core.$strip>;
|
|
1981
|
+
seo: z.ZodPrefault<z.ZodObject<{
|
|
1982
|
+
recordIndexPolicy: z.ZodDefault<z.ZodEnum<{
|
|
1983
|
+
editorial: "editorial";
|
|
1984
|
+
all: "all";
|
|
1985
|
+
"editorial-and-reviewed": "editorial-and-reviewed";
|
|
1986
|
+
}>>;
|
|
1987
|
+
collectionIndexPolicy: z.ZodDefault<z.ZodEnum<{
|
|
1988
|
+
editorial: "editorial";
|
|
1989
|
+
all: "all";
|
|
1990
|
+
}>>;
|
|
1991
|
+
taxonomyIndexPolicy: z.ZodDefault<z.ZodEnum<{
|
|
1992
|
+
editorial: "editorial";
|
|
1993
|
+
all: "all";
|
|
1994
|
+
}>>;
|
|
1995
|
+
}, z.core.$strip>>;
|
|
1939
1996
|
analytics: z.ZodDefault<z.ZodObject<{
|
|
1940
1997
|
googleAnalyticsId: z.ZodOptional<z.ZodString>;
|
|
1941
1998
|
}, z.core.$strip>>;
|
|
@@ -1973,9 +2030,9 @@ export declare const groveConfigSchema: z.ZodObject<{
|
|
|
1973
2030
|
}, z.core.$strip>>;
|
|
1974
2031
|
browse: z.ZodPrefault<z.ZodObject<{
|
|
1975
2032
|
facets: z.ZodDefault<z.ZodArray<z.ZodEnum<{
|
|
2033
|
+
platform: "platform";
|
|
1976
2034
|
category: "category";
|
|
1977
2035
|
stack: "stack";
|
|
1978
|
-
platform: "platform";
|
|
1979
2036
|
tags: "tags";
|
|
1980
2037
|
license: "license";
|
|
1981
2038
|
}>>>;
|
|
@@ -1986,6 +2043,7 @@ export declare const groveConfigSchema: z.ZodObject<{
|
|
|
1986
2043
|
metadata: z.ZodDefault<z.ZodBoolean>;
|
|
1987
2044
|
contributors: z.ZodDefault<z.ZodBoolean>;
|
|
1988
2045
|
health: z.ZodDefault<z.ZodBoolean>;
|
|
2046
|
+
candidates: z.ZodDefault<z.ZodBoolean>;
|
|
1989
2047
|
}, z.core.$strip>]>>;
|
|
1990
2048
|
}, z.core.$strip>>;
|
|
1991
2049
|
sync: z.ZodPrefault<z.ZodObject<{
|
|
@@ -2087,6 +2145,8 @@ export type Links = z.infer<typeof linksSchema>;
|
|
|
2087
2145
|
export type ReadmeConfig = z.infer<typeof readmeConfigSchema>;
|
|
2088
2146
|
export declare function unwrapHealth(value: HealthFile): HealthEntry[];
|
|
2089
2147
|
export declare function unwrapDecisions(value: DecisionsFile): Decision[];
|
|
2148
|
+
/** Candidate verdicts from a decisions file; the list form has none. */
|
|
2149
|
+
export declare function unwrapCandidateReviews(value: DecisionsFile): CandidateReview[];
|
|
2090
2150
|
export declare function unwrapOverrides(value: OverridesFile): Override[];
|
|
2091
2151
|
/**
|
|
2092
2152
|
* Parse a single record YAML mapping into a typed Resource. The
|