@memorysmithapp/markdown-renderer 0.9.0 → 0.10.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.
@@ -0,0 +1,553 @@
1
+ /**
2
+ * The `table` block (§7.15, #137) and the query language its `where` is written in (§6.9).
3
+ *
4
+ * A block holds a question about a table of the notebook and never its rows: which table, which
5
+ * columns, which rows, in which order, how many to a page, and which column to sum. This module
6
+ * reads the question — the lines of the block, and the filter as a tree — and says what is wrong
7
+ * with it, alone or against the columns of the table the host keeps. It fetches nothing and knows
8
+ * no React, so `diagnose` runs it on a server as the page does in a browser.
9
+ *
10
+ * The query language is MemorySmith's search (§2), with what the specification adds for a table:
11
+ * a field is a column, a bare term looks in every text and list column, and an interval compares
12
+ * a number as well as a date.
13
+ */
14
+ /** The six keys, in English in every notebook (§7.15). */
15
+ export const TABLE_KEYS = ['table', 'columns', 'where', 'sort', 'page', 'total'];
16
+ /** Rows to a page when the block says nothing, and the most it may ask for. */
17
+ export const DEFAULT_PAGE = 25;
18
+ export const MAX_PAGE = 100;
19
+ /** Whether a fenced code block is a `table` block: its info string is the word `table` and nothing else. */
20
+ export function isTableBlock(lang, meta) {
21
+ return lang === 'table' && (meta ?? '').trim() === '';
22
+ }
23
+ /**
24
+ * Text as a query compares it (§6.9): case folded and combining marks stripped. A character keeps
25
+ * its length where it can, as MemorySmith's search folds it.
26
+ */
27
+ export function fold(raw) {
28
+ let out = '';
29
+ for (const character of raw) {
30
+ const folded = character.normalize('NFD').replace(/\p{M}/gu, '').toLowerCase();
31
+ out += folded.length === character.length ? folded : character.toLowerCase();
32
+ }
33
+ return out;
34
+ }
35
+ /** A table's name as it is compared (§5.9): in NFC, with case folded. */
36
+ export function tableKey(name) {
37
+ return name.normalize('NFC').toLowerCase();
38
+ }
39
+ /** A column's name: one word, with none of the characters a block and a query separate with (§5.9). */
40
+ const COLUMN_NAME = /^[^\s,:"()]+$/;
41
+ const PAGE = /^\d+$/;
42
+ const NUMBER = /^-?\d+(?:\.\d+)?$/;
43
+ /**
44
+ * Reads the lines of a block. `value` is the content of the fence, without the fences, one line of
45
+ * the block to each line of it.
46
+ */
47
+ export function readTableBlock(value) {
48
+ const problems = [];
49
+ const lines = {};
50
+ const values = {};
51
+ const tableLines = [];
52
+ value.split('\n').forEach((raw, index) => {
53
+ const line = index + 1;
54
+ if (raw.trim() === '')
55
+ return;
56
+ const colon = raw.indexOf(':');
57
+ const key = colon === -1 ? null : raw.slice(0, colon).trim();
58
+ if (key === null || !TABLE_KEYS.includes(key)) {
59
+ problems.push({ code: 'table-key-unknown', line, detail: key ?? raw.trim() });
60
+ return;
61
+ }
62
+ const known = key;
63
+ const text = raw.slice(colon + 1).trim();
64
+ if (known === 'table') {
65
+ tableLines.push(line);
66
+ if (text !== '')
67
+ values.table = text;
68
+ lines.table ??= line;
69
+ return;
70
+ }
71
+ if (known in lines) {
72
+ problems.push({ code: 'table-key-invalid', line, detail: `${known} is written twice` });
73
+ return;
74
+ }
75
+ lines[known] = line;
76
+ // A key with an empty value is absent.
77
+ if (text !== '')
78
+ values[known] = text;
79
+ });
80
+ const named = tableLines.length === 1 && values.table !== undefined;
81
+ if (!named)
82
+ problems.push({ code: 'table-unnamed', line: 0 });
83
+ const invalid = (key, detail) => {
84
+ problems.push({ code: 'table-key-invalid', line: lines[key] ?? 0, detail });
85
+ return null;
86
+ };
87
+ const columns = values.columns === undefined ? null : readNames(values.columns, 'columns', invalid);
88
+ let sort = null;
89
+ if (values.sort !== undefined) {
90
+ const keys = [];
91
+ const seen = new Set();
92
+ for (const item of values.sort.split(',').map((part) => part.trim())) {
93
+ const words = item.split(/\s+/);
94
+ const [column, direction, ...rest] = words;
95
+ if (!column || !COLUMN_NAME.test(column) || rest.length > 0 || (direction !== undefined && direction !== 'asc' && direction !== 'desc')) {
96
+ sort = invalid('sort', item === '' ? 'a column is missing' : `${item} is not a column followed by asc or desc`);
97
+ break;
98
+ }
99
+ if (seen.has(fold(column))) {
100
+ sort = invalid('sort', `${column} is listed twice`);
101
+ break;
102
+ }
103
+ seen.add(fold(column));
104
+ keys.push({ column, descending: direction === 'desc' });
105
+ sort = keys;
106
+ }
107
+ }
108
+ let page = DEFAULT_PAGE;
109
+ if (values.page !== undefined) {
110
+ const count = PAGE.test(values.page) ? Number(values.page) : NaN;
111
+ if (count >= 1 && count <= MAX_PAGE)
112
+ page = count;
113
+ else
114
+ invalid('page', `${values.page} is not a whole number from 1 to ${MAX_PAGE}`);
115
+ }
116
+ let total = null;
117
+ if (values.total !== undefined) {
118
+ if (COLUMN_NAME.test(values.total))
119
+ total = values.total;
120
+ else
121
+ invalid('total', `${values.total} is not one column`);
122
+ }
123
+ let where = null;
124
+ if (values.where !== undefined) {
125
+ try {
126
+ where = parseQuery(values.where);
127
+ }
128
+ catch (error) {
129
+ if (!(error instanceof QuerySyntaxError))
130
+ throw error;
131
+ problems.push({ code: 'table-filter-invalid', line: lines.where ?? 0, detail: error.message });
132
+ }
133
+ }
134
+ return {
135
+ table: named ? values.table.normalize('NFC') : null,
136
+ columns,
137
+ where,
138
+ whereText: values.where ?? null,
139
+ sort,
140
+ page,
141
+ total,
142
+ problems: problems.sort((a, b) => a.line - b.line),
143
+ lines,
144
+ };
145
+ }
146
+ function readNames(text, key, invalid) {
147
+ const names = [];
148
+ const seen = new Set();
149
+ for (const name of text.split(',').map((part) => part.trim())) {
150
+ if (name === '')
151
+ return invalid(key, 'a column is missing');
152
+ if (!COLUMN_NAME.test(name))
153
+ return invalid(key, `${name} is not one word`);
154
+ if (seen.has(fold(name)))
155
+ return invalid(key, `${name} is listed twice`);
156
+ seen.add(fold(name));
157
+ names.push(name);
158
+ }
159
+ return names;
160
+ }
161
+ /**
162
+ * The mistakes a block makes against the table it names: the ones it makes alone, then a pending
163
+ * table, a column the table does not have, a `total` that is not a drawn number, and a filter its
164
+ * columns cannot answer. `schema` is `undefined` when nothing is known of the notebook's tables,
165
+ * and `null` when the notebook keeps no table of that name. A line raises one mistake at most.
166
+ */
167
+ export function checkTableBlock(block, schema) {
168
+ const problems = [...block.problems];
169
+ if (block.table === null || schema === undefined)
170
+ return problems;
171
+ if (schema === null) {
172
+ problems.push({ code: 'table-pending', line: block.lines.table ?? 0, detail: block.table });
173
+ return problems;
174
+ }
175
+ const taken = new Set(problems.map((problem) => problem.line));
176
+ const add = (key, code, detail) => {
177
+ const line = block.lines[key] ?? 0;
178
+ if (taken.has(line))
179
+ return;
180
+ taken.add(line);
181
+ problems.push({ code, line, detail });
182
+ };
183
+ const byName = new Map(schema.columns.map((column) => [fold(column.name), column]));
184
+ const column = (name) => byName.get(fold(name));
185
+ for (const name of block.columns ?? [])
186
+ if (!column(name))
187
+ add('columns', 'table-column-unknown', name);
188
+ for (const key of block.sort ?? [])
189
+ if (!column(key.column))
190
+ add('sort', 'table-column-unknown', key.column);
191
+ if (block.total !== null) {
192
+ const summed = column(block.total);
193
+ if (!summed)
194
+ add('total', 'table-column-unknown', block.total);
195
+ else if (summed.kind !== 'number')
196
+ add('total', 'table-key-invalid', `${block.total} is not a number column`);
197
+ else if (block.columns && !block.columns.some((name) => fold(name) === fold(block.total))) {
198
+ add('total', 'table-key-invalid', `${block.total} is not drawn`);
199
+ }
200
+ }
201
+ if (block.where) {
202
+ const unknown = fields(block.where).find((field) => !byName.has(field));
203
+ if (unknown !== undefined)
204
+ add('where', 'table-column-unknown', unknown);
205
+ else {
206
+ const wrong = kindMistake(block.where, byName);
207
+ if (wrong)
208
+ add('where', 'table-filter-invalid', wrong);
209
+ }
210
+ }
211
+ return problems.sort((a, b) => a.line - b.line);
212
+ }
213
+ /** A query that cannot be read, whatever it is asked of (§6.9). */
214
+ export class QuerySyntaxError extends Error {
215
+ }
216
+ const MAX_QUERY_LENGTH = 500;
217
+ function tokenize(raw) {
218
+ if (raw.length > MAX_QUERY_LENGTH)
219
+ throw new QuerySyntaxError(`A query is limited to ${MAX_QUERY_LENGTH} characters`);
220
+ const tokens = [];
221
+ let index = 0;
222
+ while (index < raw.length) {
223
+ const char = raw[index];
224
+ if (/\s/.test(char)) {
225
+ index++;
226
+ }
227
+ else if (char === '(') {
228
+ tokens.push({ kind: 'open' });
229
+ index++;
230
+ }
231
+ else if (char === ')') {
232
+ tokens.push({ kind: 'close' });
233
+ index++;
234
+ }
235
+ else if (char === '-' && (index === 0 || /[\s(]/.test(raw[index - 1]))) {
236
+ // A dash negates only where a term starts, so `lei-14133` stays one word.
237
+ tokens.push({ kind: 'not' });
238
+ index++;
239
+ }
240
+ else if (char === '"') {
241
+ const end = raw.indexOf('"', index + 1);
242
+ if (end === -1)
243
+ throw new QuerySyntaxError('A phrase is never closed');
244
+ tokens.push({ kind: 'word', value: raw.slice(index + 1, end), quoted: 'phrase' });
245
+ index = end + 1;
246
+ }
247
+ else {
248
+ let end = index;
249
+ while (end < raw.length && !/[\s()"]/.test(raw[end]))
250
+ end++;
251
+ const value = raw.slice(index, end);
252
+ index = end;
253
+ // `field:"two words"` keeps its field and reads the phrase as its value.
254
+ if (raw[index] === '"' && value.endsWith(':') && value.length > 1) {
255
+ const close = raw.indexOf('"', index + 1);
256
+ if (close === -1)
257
+ throw new QuerySyntaxError('A phrase is never closed');
258
+ tokens.push({ kind: 'word', value: value + raw.slice(index + 1, close), quoted: 'value' });
259
+ index = close + 1;
260
+ }
261
+ else if (value === 'OR') {
262
+ tokens.push({ kind: 'or' });
263
+ }
264
+ else {
265
+ tokens.push({ kind: 'word', value, quoted: 'none' });
266
+ }
267
+ }
268
+ }
269
+ return tokens;
270
+ }
271
+ /** Reads a query: `OR` binds loosest, then the implicit *and*, then `-`, then a term or a group. */
272
+ export function parseQuery(raw) {
273
+ const tokens = tokenize(raw);
274
+ if (tokens.length === 0)
275
+ throw new QuerySyntaxError('A query asks nothing');
276
+ let position = 0;
277
+ const peek = () => tokens[position];
278
+ const or = () => {
279
+ const nodes = [and()];
280
+ while (peek()?.kind === 'or') {
281
+ position++;
282
+ nodes.push(and());
283
+ }
284
+ return nodes.length === 1 ? nodes[0] : { kind: 'or', nodes };
285
+ };
286
+ const and = () => {
287
+ const nodes = [];
288
+ for (let token = peek(); token && token.kind !== 'or' && token.kind !== 'close'; token = peek())
289
+ nodes.push(not());
290
+ if (nodes.length === 0)
291
+ throw new QuerySyntaxError('An operator is missing its term');
292
+ return nodes.length === 1 ? nodes[0] : { kind: 'and', nodes };
293
+ };
294
+ const not = () => {
295
+ if (peek()?.kind !== 'not')
296
+ return atom();
297
+ position++;
298
+ return { kind: 'not', node: not() };
299
+ };
300
+ const atom = () => {
301
+ const token = peek();
302
+ if (token?.kind === 'open') {
303
+ position++;
304
+ const inner = or();
305
+ if (peek()?.kind !== 'close')
306
+ throw new QuerySyntaxError('A group is never closed');
307
+ position++;
308
+ return inner;
309
+ }
310
+ if (token?.kind !== 'word')
311
+ throw new QuerySyntaxError('An operator is missing its term');
312
+ position++;
313
+ return termOf(token);
314
+ };
315
+ const tree = or();
316
+ if (position < tokens.length)
317
+ throw new QuerySyntaxError('A group is closed that was never opened');
318
+ return tree;
319
+ }
320
+ const COMPARISON = /^(>=|<=|>|<)(.*)$/;
321
+ function termOf(token) {
322
+ // A phrase is text, whatever it holds; a word is a field when a colon stands inside it.
323
+ const colon = token.quoted === 'phrase' ? -1 : token.value.indexOf(':');
324
+ if (colon > 0 && colon < token.value.length - 1) {
325
+ const field = fold(token.value.slice(0, colon));
326
+ const raw = token.value.slice(colon + 1);
327
+ if (token.quoted === 'value')
328
+ return { kind: 'term', field, value: fold(raw) };
329
+ const comparison = COMPARISON.exec(raw);
330
+ if (comparison) {
331
+ const value = fold(comparison[2] ?? '');
332
+ if (value === '')
333
+ throw new QuerySyntaxError('A comparison is missing its operand');
334
+ return { kind: 'compare', field, op: comparison[1], value };
335
+ }
336
+ const separator = raw.indexOf('..');
337
+ if (separator !== -1) {
338
+ const from = fold(raw.slice(0, separator));
339
+ const to = fold(raw.slice(separator + 2));
340
+ if (from === '' || to === '')
341
+ throw new QuerySyntaxError('A range needs both ends');
342
+ return { kind: 'range', field, from, to };
343
+ }
344
+ return { kind: 'term', field, value: fold(raw) };
345
+ }
346
+ const value = fold(token.value);
347
+ if (value === '')
348
+ throw new QuerySyntaxError('A phrase holds nothing');
349
+ return { kind: 'term', field: null, value };
350
+ }
351
+ /** Every field a query names, folded, in the order it names them. */
352
+ export function fields(node) {
353
+ switch (node.kind) {
354
+ case 'term':
355
+ return node.field === null ? [] : [node.field];
356
+ case 'compare':
357
+ case 'range':
358
+ return [node.field];
359
+ case 'not':
360
+ return fields(node.node);
361
+ case 'and':
362
+ case 'or':
363
+ return node.nodes.flatMap(fields);
364
+ }
365
+ }
366
+ /**
367
+ * What a query asks that the kinds of its columns cannot answer (§6.9), or `null`: an interval over
368
+ * a column that is neither a date nor a number, a number column given a value that is not a number,
369
+ * and a range whose ends are inverted as that kind compares them.
370
+ */
371
+ function kindMistake(node, columns) {
372
+ switch (node.kind) {
373
+ case 'not':
374
+ return kindMistake(node.node, columns);
375
+ case 'and':
376
+ case 'or':
377
+ for (const each of node.nodes) {
378
+ const mistake = kindMistake(each, columns);
379
+ if (mistake)
380
+ return mistake;
381
+ }
382
+ return null;
383
+ case 'term': {
384
+ if (node.field === null)
385
+ return null;
386
+ const column = columns.get(node.field);
387
+ return column?.kind === 'number' && !NUMBER.test(node.value) ? `${node.value} is not a number` : null;
388
+ }
389
+ case 'compare':
390
+ case 'range': {
391
+ const column = columns.get(node.field);
392
+ if (!column)
393
+ return null;
394
+ if (column.kind !== 'number' && column.kind !== 'date')
395
+ return `${column.name} is neither a date nor a number`;
396
+ const ends = node.kind === 'compare' ? [node.value] : [node.from, node.to];
397
+ if (column.kind === 'number') {
398
+ const wrong = ends.find((end) => !NUMBER.test(end));
399
+ if (wrong !== undefined)
400
+ return `${wrong} is not a number`;
401
+ }
402
+ if (node.kind === 'range') {
403
+ const inverted = column.kind === 'number' ? Number(node.from) > Number(node.to) : node.from > node.to;
404
+ if (inverted)
405
+ return `the range ${node.from}..${node.to} is inverted`;
406
+ }
407
+ return null;
408
+ }
409
+ }
410
+ }
411
+ /**
412
+ * Answers a request from a table held in memory, as `SPEC.md` §6.9 and §7.15 say a query is
413
+ * answered: the filter, the order, the page and the total. A host that keeps its tables elsewhere
414
+ * answers in its own store; this is the reference its answers can be compared with, and what the
415
+ * playground answers with. A filter that cannot be read throws `QuerySyntaxError`.
416
+ */
417
+ export function runTableQuery(table, request, readAt = new Date().toISOString()) {
418
+ const byName = new Map(table.schema.columns.map((column) => [fold(column.name), column]));
419
+ const where = request.where === null || request.where.trim() === '' ? null : parseQuery(request.where);
420
+ const matching = where === null ? [...table.rows] : table.rows.filter((row) => matches(where, row, byName));
421
+ const keys = request.sort
422
+ .map((key) => ({ column: byName.get(fold(key.column)), descending: key.descending }))
423
+ .filter((key) => key.column !== undefined);
424
+ const ordered = matching
425
+ .map((row, index) => ({ row, index }))
426
+ .sort((a, b) => {
427
+ for (const key of keys) {
428
+ const order = compareValues(a.row[key.column.name] ?? null, b.row[key.column.name] ?? null, key.column.kind, key.descending);
429
+ if (order !== 0)
430
+ return order;
431
+ }
432
+ return a.index - b.index;
433
+ })
434
+ .map(({ row }) => row);
435
+ const size = request.size === 'all' ? Math.max(ordered.length, 1) : request.size;
436
+ const start = request.size === 'all' ? 0 : (Math.max(request.page, 1) - 1) * size;
437
+ const summed = request.total === null ? undefined : byName.get(fold(request.total));
438
+ return {
439
+ schema: table.schema,
440
+ rows: ordered.slice(start, start + size),
441
+ count: ordered.length,
442
+ total: summed ? sumDecimals(matching.map((row) => row[summed.name]).filter((value) => typeof value === 'string')) : null,
443
+ readAt,
444
+ };
445
+ }
446
+ /** Whether a row answers a query, by the kinds of its columns (§6.9). */
447
+ function matches(node, row, columns) {
448
+ switch (node.kind) {
449
+ case 'and':
450
+ return node.nodes.every((each) => matches(each, row, columns));
451
+ case 'or':
452
+ return node.nodes.some((each) => matches(each, row, columns));
453
+ case 'not':
454
+ return !matches(node.node, row, columns);
455
+ case 'term': {
456
+ if (node.field === null) {
457
+ return [...columns.values()]
458
+ .filter((column) => column.kind === 'text' || column.kind === 'list')
459
+ .some((column) => textsOf(row[column.name] ?? null).some((text) => fold(text).includes(node.value)));
460
+ }
461
+ const column = columns.get(node.field);
462
+ if (!column)
463
+ return false;
464
+ const value = row[column.name] ?? null;
465
+ if (value === null)
466
+ return false;
467
+ if (column.kind === 'date')
468
+ return String(value).startsWith(node.value);
469
+ if (column.kind === 'number')
470
+ return compareDecimals(String(value), node.value) === 0;
471
+ return textsOf(value).some((text) => fold(text).includes(node.value));
472
+ }
473
+ case 'compare':
474
+ case 'range': {
475
+ const column = columns.get(node.field);
476
+ const value = column ? (row[column.name] ?? null) : null;
477
+ if (!column || typeof value !== 'string')
478
+ return false;
479
+ const bounds = node.kind === 'compare' ? [[node.op, node.value]] : [['>=', node.from], ['<=', node.to]];
480
+ return bounds.every(([op, bound]) => {
481
+ // A date is cut to the length of its bound, so a month is a legal end (§6.8).
482
+ const order = column.kind === 'number' ? compareDecimals(value, bound) : compareText(value.slice(0, bound.length), bound);
483
+ return op === '>=' ? order >= 0 : op === '>' ? order > 0 : op === '<=' ? order <= 0 : order < 0;
484
+ });
485
+ }
486
+ }
487
+ }
488
+ function textsOf(value) {
489
+ if (value === null)
490
+ return [];
491
+ if (Array.isArray(value))
492
+ return [...value];
493
+ return [String(value)];
494
+ }
495
+ const compareText = (a, b) => (a < b ? -1 : a > b ? 1 : 0);
496
+ /**
497
+ * The order of two values of one kind (§7.15): numbers as numbers, dates in ISO 8601, which orders
498
+ * as text, booleans `false` first, text and lists by their folded text. An empty value comes last
499
+ * in either direction.
500
+ */
501
+ export function compareValues(a, b, kind, descending = false) {
502
+ const emptyA = a === null || (Array.isArray(a) && a.length === 0) || a === '';
503
+ const emptyB = b === null || (Array.isArray(b) && b.length === 0) || b === '';
504
+ if (emptyA || emptyB)
505
+ return emptyA === emptyB ? 0 : emptyA ? 1 : -1;
506
+ let order;
507
+ if (kind === 'number')
508
+ order = compareDecimals(String(a), String(b));
509
+ else if (kind === 'boolean')
510
+ order = Number(a === true || a === 'true') - Number(b === true || b === 'true');
511
+ else if (kind === 'date')
512
+ order = compareText(String(a), String(b));
513
+ else
514
+ order = compareText(fold(textsOf(a).join(', ')), fold(textsOf(b).join(', ')));
515
+ return descending ? -order : order;
516
+ }
517
+ /** A decimal written in digits, as a whole number and the power of ten it is divided by. */
518
+ function decimal(text) {
519
+ const match = /^(-?)(\d+)(?:\.(\d+))?$/.exec(text.trim());
520
+ if (!match)
521
+ return null;
522
+ const fraction = match[3] ?? '';
523
+ return { units: BigInt(`${match[1]}${match[2]}${fraction}`), scale: fraction.length };
524
+ }
525
+ function aligned(a, b) {
526
+ const scale = Math.max(a.scale, b.scale);
527
+ return [a.units * 10n ** BigInt(scale - a.scale), b.units * 10n ** BigInt(scale - b.scale), scale];
528
+ }
529
+ /** Two decimals compared exactly, with no floating point; what is not a number sorts after one. */
530
+ function compareDecimals(a, b) {
531
+ const x = decimal(a);
532
+ const y = decimal(b);
533
+ if (!x || !y)
534
+ return x ? -1 : y ? 1 : 0;
535
+ const [left, right] = aligned(x, y);
536
+ return left < right ? -1 : left > right ? 1 : 0;
537
+ }
538
+ /** The exact sum of decimals, written in digits. */
539
+ export function sumDecimals(values) {
540
+ let sum = { units: 0n, scale: 0 };
541
+ for (const value of values) {
542
+ const next = decimal(value);
543
+ if (!next)
544
+ continue;
545
+ const [left, right, scale] = aligned(sum, next);
546
+ sum = { units: left + right, scale };
547
+ }
548
+ const negative = sum.units < 0n;
549
+ const digits = (negative ? -sum.units : sum.units).toString().padStart(sum.scale + 1, '0');
550
+ const whole = digits.slice(0, digits.length - sum.scale);
551
+ const fraction = digits.slice(digits.length - sum.scale);
552
+ return `${negative ? '-' : ''}${whole}${fraction ? `.${fraction}` : ''}`;
553
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@memorysmithapp/markdown-renderer",
3
- "version": "0.9.0",
3
+ "version": "0.10.0",
4
4
  "description": "A React component that draws a MemorySmith note exactly as MemorySmith's reading page does.",
5
5
  "keywords": [
6
6
  "markdown",
@@ -80,7 +80,7 @@
80
80
  "unified": "11.0.5"
81
81
  },
82
82
  "devDependencies": {
83
- "@memorysmithapp/markdown-spec": "0.9.0",
83
+ "@memorysmithapp/markdown-spec": "0.10.0",
84
84
  "@types/hast": "3.0.5",
85
85
  "@types/react": "19.2.18",
86
86
  "@types/react-dom": "19.2.4",