@usememos/editor 26.10.26 → 26.10.27
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/index.js +154 -111
- package/dist/index.js.map +3 -3
- package/dist/types/markdown/ast.d.ts +5 -1
- package/package.json +1 -1
|
@@ -129,7 +129,9 @@ export type BlockNode = ParagraphNode | HeadingNode | {
|
|
|
129
129
|
* text after the block's prefixes (quote markers, list indentation), followed
|
|
130
130
|
* by "\n". `at` is where it starts in that content, `line` its 1-based source
|
|
131
131
|
* line, `offset` where its text starts on that line, and `pad` the spaces that
|
|
132
|
-
* stand in for the rest of a tab the prefix consumed only partly.
|
|
132
|
+
* stand in for the rest of a tab the prefix consumed only partly. A table
|
|
133
|
+
* cell's content is pieces of one line instead: one entry per run of its text
|
|
134
|
+
* written as such, an escaped pipe (`\|`, read as `|`) starting a new one.
|
|
133
135
|
*/
|
|
134
136
|
export interface ContentLine {
|
|
135
137
|
readonly at: number;
|
|
@@ -214,6 +216,8 @@ export interface TableNode {
|
|
|
214
216
|
readonly align: TableAlign[];
|
|
215
217
|
/** `rows[0]` is the header row. Every row has `align.length` cells. */
|
|
216
218
|
readonly rows: InlineNode[][][];
|
|
219
|
+
/** Where each cell's content was written, by row and cell, for a table from the parser: the cell's inline nodes' `pos` count from its content's start. */
|
|
220
|
+
readonly sources?: readonly (readonly ContentSource[])[];
|
|
217
221
|
/** The table's source lines: the header row, the delimiter row and the body rows. */
|
|
218
222
|
readonly lines?: SourceLines;
|
|
219
223
|
}
|