@mdsvex/render 1.0.0-next.0 → 1.0.0-next.1
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/CHANGELOG.md +294 -0
- package/dist/component.js +6 -6
- package/dist/html_cursor.js +3860 -434
- package/dist/index.js +24 -18
- package/dist/mappings.js +151 -8
- package/dist/sourcemap.js +832 -68
- package/package.json +2 -2
- package/src/Node.svelte +158 -99
- package/src/component.ts +8 -8
- package/src/entities.ts +226 -0
- package/src/html_cursor.ts +5457 -523
- package/src/index.ts +33 -9
- package/src/mappings.ts +239 -4
- package/src/scope.ts +127 -0
- package/src/sourcemap.ts +1708 -99
- package/test/component.spec.ts +3 -3
- package/test/escape_text.spec.ts +90 -0
- package/test/highlight.spec.ts +242 -0
- package/test/html_cursor.spec.ts +415 -6
- package/test/mappings.spec.ts +294 -27
- package/test/scripts.spec.ts +225 -0
- package/test/trace.spec.ts +247 -0
- package/test/wire_tree_builder.spec.ts +17 -0
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mdsvex/render",
|
|
3
|
-
"version": "1.0.0-next.
|
|
3
|
+
"version": "1.0.0-next.1",
|
|
4
4
|
"repository": {
|
|
5
5
|
"type": "git",
|
|
6
6
|
"url": "git+https://github.com/pngwn/MDsveX.git",
|
|
@@ -44,7 +44,7 @@
|
|
|
44
44
|
}
|
|
45
45
|
},
|
|
46
46
|
"dependencies": {
|
|
47
|
-
"@mdsvex/parse": "1.0.0-next.
|
|
47
|
+
"@mdsvex/parse": "1.0.0-next.1"
|
|
48
48
|
},
|
|
49
49
|
"author": "pngwn <hello@pngwn.io>",
|
|
50
50
|
"license": "MIT",
|
package/src/Node.svelte
CHANGED
|
@@ -1,105 +1,119 @@
|
|
|
1
1
|
<script lang="ts">
|
|
2
|
-
import type { NodeBuffer } from
|
|
3
|
-
import {
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
} from
|
|
8
|
-
import type { Component } from
|
|
9
|
-
import Node from
|
|
2
|
+
import type { NodeBuffer } from '@mdsvex/parse/utils';
|
|
3
|
+
import {
|
|
4
|
+
buf_children,
|
|
5
|
+
buf_text,
|
|
6
|
+
buf_text_content,
|
|
7
|
+
} from '@mdsvex/parse/buf-utils';
|
|
8
|
+
import type { Component } from 'svelte';
|
|
9
|
+
import Node from './Node.svelte';
|
|
10
10
|
|
|
11
|
-
type ComponentMap = Record<string, Component<any>>;
|
|
11
|
+
type ComponentMap = Record<string, Component<any>>;
|
|
12
12
|
|
|
13
|
-
let {
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
}: {
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
} = $props();
|
|
13
|
+
let {
|
|
14
|
+
buf,
|
|
15
|
+
idx,
|
|
16
|
+
source,
|
|
17
|
+
components,
|
|
18
|
+
}: {
|
|
19
|
+
buf: NodeBuffer;
|
|
20
|
+
idx: number;
|
|
21
|
+
source: string;
|
|
22
|
+
components?: ComponentMap;
|
|
23
|
+
} = $props();
|
|
24
24
|
|
|
25
|
-
const NONE = 0xffffffff;
|
|
25
|
+
const NONE = 0xffffffff;
|
|
26
26
|
|
|
27
|
-
// kind constants
|
|
28
|
-
const K_ROOT = 0;
|
|
29
|
-
const K_TEXT = 1;
|
|
30
|
-
const K_HTML = 2;
|
|
31
|
-
const K_HEADING = 3;
|
|
32
|
-
const K_CODE_FENCE = 5;
|
|
33
|
-
const K_LINE_BREAK = 6;
|
|
34
|
-
const K_PARAGRAPH = 7;
|
|
35
|
-
const K_CODE_SPAN = 8;
|
|
36
|
-
const K_EMPHASIS = 9;
|
|
37
|
-
const K_STRONG = 10;
|
|
38
|
-
const K_THEMATIC_BREAK = 11;
|
|
39
|
-
const K_LINK = 12;
|
|
40
|
-
const K_IMAGE = 13;
|
|
41
|
-
const K_BLOCK_QUOTE = 14;
|
|
42
|
-
const K_LIST = 15;
|
|
43
|
-
const K_LIST_ITEM = 16;
|
|
44
|
-
const K_HARD_BREAK = 17;
|
|
45
|
-
const K_SOFT_BREAK = 18;
|
|
46
|
-
const K_STRIKETHROUGH = 19;
|
|
47
|
-
const K_SUPERSCRIPT = 20;
|
|
48
|
-
const K_SUBSCRIPT = 21;
|
|
49
|
-
const K_TABLE = 22;
|
|
50
|
-
const K_TABLE_HEADER = 23;
|
|
51
|
-
const K_TABLE_ROW = 24;
|
|
52
|
-
|
|
53
|
-
const
|
|
27
|
+
// kind constants
|
|
28
|
+
const K_ROOT = 0;
|
|
29
|
+
const K_TEXT = 1;
|
|
30
|
+
const K_HTML = 2;
|
|
31
|
+
const K_HEADING = 3;
|
|
32
|
+
const K_CODE_FENCE = 5;
|
|
33
|
+
const K_LINE_BREAK = 6;
|
|
34
|
+
const K_PARAGRAPH = 7;
|
|
35
|
+
const K_CODE_SPAN = 8;
|
|
36
|
+
const K_EMPHASIS = 9;
|
|
37
|
+
const K_STRONG = 10;
|
|
38
|
+
const K_THEMATIC_BREAK = 11;
|
|
39
|
+
const K_LINK = 12;
|
|
40
|
+
const K_IMAGE = 13;
|
|
41
|
+
const K_BLOCK_QUOTE = 14;
|
|
42
|
+
const K_LIST = 15;
|
|
43
|
+
const K_LIST_ITEM = 16;
|
|
44
|
+
const K_HARD_BREAK = 17;
|
|
45
|
+
const K_SOFT_BREAK = 18;
|
|
46
|
+
const K_STRIKETHROUGH = 19;
|
|
47
|
+
const K_SUPERSCRIPT = 20;
|
|
48
|
+
const K_SUBSCRIPT = 21;
|
|
49
|
+
const K_TABLE = 22;
|
|
50
|
+
const K_TABLE_HEADER = 23;
|
|
51
|
+
const K_TABLE_ROW = 24;
|
|
52
|
+
// a cell extra is its grid column, merged cells leave gaps in a row
|
|
53
|
+
const K_TABLE_CELL = 25;
|
|
54
|
+
const K_HTML_COMMENT = 26;
|
|
55
|
+
const K_DIRECTIVE_LABEL = 35;
|
|
54
56
|
|
|
55
|
-
const NEWLINE =
|
|
57
|
+
const NEWLINE = '\n';
|
|
56
58
|
|
|
57
|
-
/** metadata keys that are structural and should not become html attributes. */
|
|
58
|
-
const INTERNAL_KEYS = new Set([
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
59
|
+
/** metadata keys that are structural and should not become html attributes. */
|
|
60
|
+
const INTERNAL_KEYS = new Set([
|
|
61
|
+
'ordered',
|
|
62
|
+
'tight',
|
|
63
|
+
'start',
|
|
64
|
+
'info',
|
|
65
|
+
'info_start',
|
|
66
|
+
'info_end',
|
|
67
|
+
'tag',
|
|
68
|
+
'attributes',
|
|
69
|
+
'self_closing',
|
|
70
|
+
'alignments',
|
|
71
|
+
'col_count',
|
|
72
|
+
'header_columns',
|
|
73
|
+
'spans',
|
|
74
|
+
'src',
|
|
75
|
+
]);
|
|
76
|
+
const LINK_SKIP = new Set(['href', 'title']);
|
|
77
|
+
const IMAGE_SKIP = new Set(['title']);
|
|
67
78
|
|
|
68
|
-
/** extract plugin-set attrs from metadata as a spreadable object. */
|
|
69
|
-
function get_attrs(
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
if (
|
|
74
|
-
|
|
75
|
-
const
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
79
|
+
/** extract plugin-set attrs from metadata as a spreadable object. */
|
|
80
|
+
function get_attrs(
|
|
81
|
+
meta: Record<string, unknown> | undefined,
|
|
82
|
+
skip?: Set<string>
|
|
83
|
+
): Record<string, any> {
|
|
84
|
+
if (!meta) return {};
|
|
85
|
+
const result: Record<string, any> = {};
|
|
86
|
+
for (const key in meta) {
|
|
87
|
+
if (INTERNAL_KEYS.has(key)) continue;
|
|
88
|
+
if (skip !== undefined && skip.has(key)) continue;
|
|
89
|
+
const val = meta[key];
|
|
90
|
+
if (val === true) {
|
|
91
|
+
result[key] = true;
|
|
92
|
+
} else if (val !== false && val != null) {
|
|
93
|
+
result[key] = String(val);
|
|
94
|
+
}
|
|
80
95
|
}
|
|
96
|
+
return result;
|
|
81
97
|
}
|
|
82
|
-
return result;
|
|
83
|
-
}
|
|
84
98
|
|
|
85
|
-
let kind = $derived(buf.
|
|
86
|
-
let extra = $derived(buf.
|
|
87
|
-
let meta = $derived(buf.metadata_at(idx));
|
|
99
|
+
let kind = $derived(buf.kind_at(idx));
|
|
100
|
+
let extra = $derived(buf.extra_at(idx));
|
|
101
|
+
let meta = $derived(buf.metadata_at(idx));
|
|
88
102
|
|
|
89
|
-
// a pending paragraph inside a list_item is a speculative wrapper for
|
|
90
|
-
// a list that may still become loose. render its children transparently
|
|
91
|
-
// so the tight-list default matches the common case and avoids a
|
|
92
|
-
// <p> flash before the list closes.
|
|
93
|
-
let skip_list_item_paragraph_wrapper = $derived(
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
);
|
|
103
|
+
// a pending paragraph inside a list_item is a speculative wrapper for
|
|
104
|
+
// a list that may still become loose. render its children transparently
|
|
105
|
+
// so the tight-list default matches the common case and avoids a
|
|
106
|
+
// <p> flash before the list closes.
|
|
107
|
+
let skip_list_item_paragraph_wrapper = $derived(
|
|
108
|
+
kind === K_PARAGRAPH &&
|
|
109
|
+
buf.pending_at(idx) === 1 &&
|
|
110
|
+
buf.kind_at(buf.parent_at(idx)) === K_LIST_ITEM
|
|
111
|
+
);
|
|
98
112
|
</script>
|
|
99
113
|
|
|
100
114
|
{#snippet child_nodes(parent_idx: number)}
|
|
101
115
|
{#each buf_children(buf, parent_idx) as child_idx (child_idx)}
|
|
102
|
-
{@const kind = buf.
|
|
116
|
+
{@const kind = buf.kind_at(child_idx)}
|
|
103
117
|
{#if kind === K_TEXT}
|
|
104
118
|
{buf_text(buf, child_idx, source)}
|
|
105
119
|
{:else if kind === K_LINE_BREAK}
|
|
@@ -113,15 +127,25 @@ let skip_list_item_paragraph_wrapper = $derived(
|
|
|
113
127
|
{#snippet table_body(table_idx: number)}
|
|
114
128
|
{@const meta = buf.metadata_at(table_idx)}
|
|
115
129
|
{@const alignments = (meta?.alignments as string[]) ?? []}
|
|
130
|
+
{@const header_columns = meta?.header_columns as number[] | undefined}
|
|
131
|
+
{@const spans = meta?.spans === true}
|
|
132
|
+
{@const col_count = (meta?.col_count as number | undefined) ?? alignments.length}
|
|
133
|
+
{@const row_l = header_columns ? header_columns[0] : 0}
|
|
134
|
+
{@const row_r = header_columns ? col_count - header_columns[1] : col_count}
|
|
116
135
|
{@const rows = buf_children(buf, table_idx)}
|
|
117
136
|
<table>
|
|
118
137
|
{#each rows as row_idx (row_idx)}
|
|
119
|
-
{#if buf.
|
|
138
|
+
{#if buf.kind_at(row_idx) === K_TABLE_HEADER}
|
|
120
139
|
<thead>
|
|
121
140
|
<tr>
|
|
122
|
-
{#each buf_children(buf, row_idx).filter((c) => buf.
|
|
123
|
-
{@const align = alignments[
|
|
124
|
-
|
|
141
|
+
{#each buf_children(buf, row_idx).filter((c) => buf.kind_at(c) === K_TABLE_CELL) as cell_idx (cell_idx)}
|
|
142
|
+
{@const align = alignments[buf.extra_at(cell_idx)]}
|
|
143
|
+
{@const cell_meta = spans ? buf.metadata_at(cell_idx) : undefined}
|
|
144
|
+
<th
|
|
145
|
+
align={align && align !== 'none' ? align : undefined}
|
|
146
|
+
colspan={cell_meta?.colspan as number | undefined}
|
|
147
|
+
rowspan={cell_meta?.rowspan as number | undefined}
|
|
148
|
+
>
|
|
125
149
|
{@render child_nodes(cell_idx)}
|
|
126
150
|
</th>
|
|
127
151
|
{/each}
|
|
@@ -131,13 +155,30 @@ let skip_list_item_paragraph_wrapper = $derived(
|
|
|
131
155
|
{/each}
|
|
132
156
|
<tbody>
|
|
133
157
|
{#each rows as row_idx (row_idx)}
|
|
134
|
-
{#if buf.
|
|
158
|
+
{#if buf.kind_at(row_idx) === K_TABLE_ROW}
|
|
135
159
|
<tr>
|
|
136
|
-
{#each buf_children(buf, row_idx).filter((c) => buf.
|
|
160
|
+
{#each buf_children(buf, row_idx).filter((c) => buf.kind_at(c) === K_TABLE_CELL) as cell_idx (cell_idx)}
|
|
161
|
+
{@const col = buf.extra_at(cell_idx)}
|
|
137
162
|
{@const align = alignments[col]}
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
163
|
+
{@const cell_meta = spans ? buf.metadata_at(cell_idx) : undefined}
|
|
164
|
+
{#if col < row_l || col >= row_r}
|
|
165
|
+
<th
|
|
166
|
+
scope="row"
|
|
167
|
+
align={align && align !== 'none' ? align : undefined}
|
|
168
|
+
colspan={cell_meta?.colspan as number | undefined}
|
|
169
|
+
rowspan={cell_meta?.rowspan as number | undefined}
|
|
170
|
+
>
|
|
171
|
+
{@render child_nodes(cell_idx)}
|
|
172
|
+
</th>
|
|
173
|
+
{:else}
|
|
174
|
+
<td
|
|
175
|
+
align={align && align !== 'none' ? align : undefined}
|
|
176
|
+
colspan={cell_meta?.colspan as number | undefined}
|
|
177
|
+
rowspan={cell_meta?.rowspan as number | undefined}
|
|
178
|
+
>
|
|
179
|
+
{@render child_nodes(cell_idx)}
|
|
180
|
+
</td>
|
|
181
|
+
{/if}
|
|
141
182
|
{/each}
|
|
142
183
|
</tr>
|
|
143
184
|
{/if}
|
|
@@ -163,7 +204,9 @@ let skip_list_item_paragraph_wrapper = $derived(
|
|
|
163
204
|
{:else if kind === K_STRONG}
|
|
164
205
|
<strong {...get_attrs(meta)}>{@render child_nodes(idx)}</strong>
|
|
165
206
|
{:else if kind === K_CODE_SPAN}
|
|
166
|
-
<code {...get_attrs(meta)}
|
|
207
|
+
<code {...get_attrs(meta)}
|
|
208
|
+
>{buf_text(buf, idx, source).replace(/\n/g, ' ')}</code
|
|
209
|
+
>
|
|
167
210
|
{:else if kind === K_CODE_FENCE}
|
|
168
211
|
{@const info =
|
|
169
212
|
(meta?.info as string | undefined) ??
|
|
@@ -176,7 +219,11 @@ let skip_list_item_paragraph_wrapper = $derived(
|
|
|
176
219
|
{:else if kind === K_BLOCK_QUOTE}
|
|
177
220
|
<blockquote {...get_attrs(meta)}>{@render child_nodes(idx)}</blockquote>
|
|
178
221
|
{:else if kind === K_LINK}
|
|
179
|
-
<a
|
|
222
|
+
<a
|
|
223
|
+
href={meta?.href as string}
|
|
224
|
+
title={(meta?.title as string) || undefined}
|
|
225
|
+
{...get_attrs(meta, LINK_SKIP)}
|
|
226
|
+
>
|
|
180
227
|
{@render child_nodes(idx)}
|
|
181
228
|
</a>
|
|
182
229
|
{:else if kind === K_IMAGE}
|
|
@@ -189,7 +236,10 @@ let skip_list_item_paragraph_wrapper = $derived(
|
|
|
189
236
|
{:else if kind === K_LIST}
|
|
190
237
|
{#if meta?.ordered}
|
|
191
238
|
{@const start = meta?.start as number | undefined}
|
|
192
|
-
<ol
|
|
239
|
+
<ol
|
|
240
|
+
start={start != null && start !== 1 ? start : undefined}
|
|
241
|
+
{...get_attrs(meta)}
|
|
242
|
+
>
|
|
193
243
|
{@render child_nodes(idx)}
|
|
194
244
|
</ol>
|
|
195
245
|
{:else}
|
|
@@ -214,7 +264,14 @@ let skip_list_item_paragraph_wrapper = $derived(
|
|
|
214
264
|
{@const attrs = meta?.attributes as Record | undefined}
|
|
215
265
|
{@const spread = attrs
|
|
216
266
|
? Object.fromEntries(
|
|
217
|
-
Object.entries(attrs).map(([k, v]) => [
|
|
267
|
+
Object.entries(attrs).map(([k, v]) => [
|
|
268
|
+
k,
|
|
269
|
+
v === true
|
|
270
|
+
? true
|
|
271
|
+
: typeof v === 'object' && v?.type === 'expression'
|
|
272
|
+
? v.value
|
|
273
|
+
: v,
|
|
274
|
+
])
|
|
218
275
|
)
|
|
219
276
|
: {}}
|
|
220
277
|
{@const CustomComponent = components?.[tag]}
|
|
@@ -240,6 +297,8 @@ let skip_list_item_paragraph_wrapper = $derived(
|
|
|
240
297
|
<!-- {buf_text(buf, idx, source)} -->
|
|
241
298
|
{:else if kind === K_TABLE}
|
|
242
299
|
{@render table_body(idx)}
|
|
300
|
+
{:else if kind === K_DIRECTIVE_LABEL}
|
|
301
|
+
<!-- a directive renders as its children, its label is not one of them -->
|
|
243
302
|
{:else}
|
|
244
303
|
{@render child_nodes(idx)}
|
|
245
304
|
{/if}
|
package/src/component.ts
CHANGED
|
@@ -17,7 +17,7 @@
|
|
|
17
17
|
* with fresh content.
|
|
18
18
|
*/
|
|
19
19
|
|
|
20
|
-
import type { NodeBuffer } from
|
|
20
|
+
import type { NodeBuffer } from '@mdsvex/parse/utils';
|
|
21
21
|
|
|
22
22
|
const NONE = 0xffffffff;
|
|
23
23
|
const K_LINE_BREAK = 6;
|
|
@@ -38,7 +38,7 @@ export class ComponentRenderer {
|
|
|
38
38
|
/** The current buffer reference (for passing to Node.svelte). */
|
|
39
39
|
buf: NodeBuffer | null = null;
|
|
40
40
|
/** The current source/text string (for passing to Node.svelte). */
|
|
41
|
-
source =
|
|
41
|
+
source = '';
|
|
42
42
|
private closed: Set<number> = new Set();
|
|
43
43
|
|
|
44
44
|
update(buf: NodeBuffer, source: string): ComponentBlock[] {
|
|
@@ -49,14 +49,14 @@ export class ComponentRenderer {
|
|
|
49
49
|
let changed = false;
|
|
50
50
|
|
|
51
51
|
// walk root's children via sibling chain
|
|
52
|
-
let child = buf.
|
|
52
|
+
let child = buf.first_child_at(0);
|
|
53
53
|
while (child !== NONE) {
|
|
54
|
-
const kind = buf.
|
|
55
|
-
const next = buf.
|
|
56
|
-
const is_sibling = next !== NONE && buf.
|
|
54
|
+
const kind = buf.kind_at(child);
|
|
55
|
+
const next = buf.next_at(child);
|
|
56
|
+
const is_sibling = next !== NONE && buf.parent_at(next) === 0;
|
|
57
57
|
|
|
58
58
|
if (kind !== K_LINE_BREAK) {
|
|
59
|
-
const closed = buf.
|
|
59
|
+
const closed = buf.end_at(child) !== NONE;
|
|
60
60
|
|
|
61
61
|
if (block_idx >= this.blocks.length) {
|
|
62
62
|
this.blocks.push({ idx: child, v: 0 });
|
|
@@ -82,7 +82,7 @@ export class ComponentRenderer {
|
|
|
82
82
|
reset(): void {
|
|
83
83
|
this.blocks = [];
|
|
84
84
|
this.buf = null;
|
|
85
|
-
this.source =
|
|
85
|
+
this.source = '';
|
|
86
86
|
this.closed.clear();
|
|
87
87
|
}
|
|
88
88
|
}
|
package/src/entities.ts
ADDED
|
@@ -0,0 +1,226 @@
|
|
|
1
|
+
// the html5 named character references that end in a semicolon, as commonmark
|
|
2
|
+
// accepts them in text, from character-entities 2.0.2
|
|
3
|
+
const NAMES = `
|
|
4
|
+
AElig AMP Aacute Abreve Acirc Acy Afr Agrave Alpha Amacr And Aogon Aopf
|
|
5
|
+
ApplyFunction Aring Ascr Assign Atilde Auml Backslash Barv Barwed Bcy Because
|
|
6
|
+
Bernoullis Beta Bfr Bopf Breve Bscr Bumpeq CHcy COPY Cacute Cap
|
|
7
|
+
CapitalDifferentialD Cayleys Ccaron Ccedil Ccirc Cconint Cdot Cedilla CenterDot
|
|
8
|
+
Cfr Chi CircleDot CircleMinus CirclePlus CircleTimes ClockwiseContourIntegral
|
|
9
|
+
CloseCurlyDoubleQuote CloseCurlyQuote Colon Colone Congruent Conint
|
|
10
|
+
ContourIntegral Copf Coproduct CounterClockwiseContourIntegral Cross Cscr Cup
|
|
11
|
+
CupCap DD DDotrahd DJcy DScy DZcy Dagger Darr Dashv Dcaron Dcy Del Delta Dfr
|
|
12
|
+
DiacriticalAcute DiacriticalDot DiacriticalDoubleAcute DiacriticalGrave
|
|
13
|
+
DiacriticalTilde Diamond DifferentialD Dopf Dot DotDot DotEqual
|
|
14
|
+
DoubleContourIntegral DoubleDot DoubleDownArrow DoubleLeftArrow
|
|
15
|
+
DoubleLeftRightArrow DoubleLeftTee DoubleLongLeftArrow DoubleLongLeftRightArrow
|
|
16
|
+
DoubleLongRightArrow DoubleRightArrow DoubleRightTee DoubleUpArrow
|
|
17
|
+
DoubleUpDownArrow DoubleVerticalBar DownArrow DownArrowBar DownArrowUpArrow
|
|
18
|
+
DownBreve DownLeftRightVector DownLeftTeeVector DownLeftVector
|
|
19
|
+
DownLeftVectorBar DownRightTeeVector DownRightVector DownRightVectorBar DownTee
|
|
20
|
+
DownTeeArrow Downarrow Dscr Dstrok ENG ETH Eacute Ecaron Ecirc Ecy Edot Efr
|
|
21
|
+
Egrave Element Emacr EmptySmallSquare EmptyVerySmallSquare Eogon Eopf Epsilon
|
|
22
|
+
Equal EqualTilde Equilibrium Escr Esim Eta Euml Exists ExponentialE Fcy Ffr
|
|
23
|
+
FilledSmallSquare FilledVerySmallSquare Fopf ForAll Fouriertrf Fscr GJcy GT
|
|
24
|
+
Gamma Gammad Gbreve Gcedil Gcirc Gcy Gdot Gfr Gg Gopf GreaterEqual
|
|
25
|
+
GreaterEqualLess GreaterFullEqual GreaterGreater GreaterLess GreaterSlantEqual
|
|
26
|
+
GreaterTilde Gscr Gt HARDcy Hacek Hat Hcirc Hfr HilbertSpace Hopf
|
|
27
|
+
HorizontalLine Hscr Hstrok HumpDownHump HumpEqual IEcy IJlig IOcy Iacute Icirc
|
|
28
|
+
Icy Idot Ifr Igrave Im Imacr ImaginaryI Implies Int Integral Intersection
|
|
29
|
+
InvisibleComma InvisibleTimes Iogon Iopf Iota Iscr Itilde Iukcy Iuml Jcirc Jcy
|
|
30
|
+
Jfr Jopf Jscr Jsercy Jukcy KHcy KJcy Kappa Kcedil Kcy Kfr Kopf Kscr LJcy LT
|
|
31
|
+
Lacute Lambda Lang Laplacetrf Larr Lcaron Lcedil Lcy LeftAngleBracket LeftArrow
|
|
32
|
+
LeftArrowBar LeftArrowRightArrow LeftCeiling LeftDoubleBracket
|
|
33
|
+
LeftDownTeeVector LeftDownVector LeftDownVectorBar LeftFloor LeftRightArrow
|
|
34
|
+
LeftRightVector LeftTee LeftTeeArrow LeftTeeVector LeftTriangle LeftTriangleBar
|
|
35
|
+
LeftTriangleEqual LeftUpDownVector LeftUpTeeVector LeftUpVector LeftUpVectorBar
|
|
36
|
+
LeftVector LeftVectorBar Leftarrow Leftrightarrow LessEqualGreater
|
|
37
|
+
LessFullEqual LessGreater LessLess LessSlantEqual LessTilde Lfr Ll Lleftarrow
|
|
38
|
+
Lmidot LongLeftArrow LongLeftRightArrow LongRightArrow Longleftarrow
|
|
39
|
+
Longleftrightarrow Longrightarrow Lopf LowerLeftArrow LowerRightArrow Lscr Lsh
|
|
40
|
+
Lstrok Lt Map Mcy MediumSpace Mellintrf Mfr MinusPlus Mopf Mscr Mu NJcy Nacute
|
|
41
|
+
Ncaron Ncedil Ncy NegativeMediumSpace NegativeThickSpace NegativeThinSpace
|
|
42
|
+
NegativeVeryThinSpace NestedGreaterGreater NestedLessLess NewLine Nfr NoBreak
|
|
43
|
+
NonBreakingSpace Nopf Not NotCongruent NotCupCap NotDoubleVerticalBar
|
|
44
|
+
NotElement NotEqual NotEqualTilde NotExists NotGreater NotGreaterEqual
|
|
45
|
+
NotGreaterFullEqual NotGreaterGreater NotGreaterLess NotGreaterSlantEqual
|
|
46
|
+
NotGreaterTilde NotHumpDownHump NotHumpEqual NotLeftTriangle NotLeftTriangleBar
|
|
47
|
+
NotLeftTriangleEqual NotLess NotLessEqual NotLessGreater NotLessLess
|
|
48
|
+
NotLessSlantEqual NotLessTilde NotNestedGreaterGreater NotNestedLessLess
|
|
49
|
+
NotPrecedes NotPrecedesEqual NotPrecedesSlantEqual NotReverseElement
|
|
50
|
+
NotRightTriangle NotRightTriangleBar NotRightTriangleEqual NotSquareSubset
|
|
51
|
+
NotSquareSubsetEqual NotSquareSuperset NotSquareSupersetEqual NotSubset
|
|
52
|
+
NotSubsetEqual NotSucceeds NotSucceedsEqual NotSucceedsSlantEqual
|
|
53
|
+
NotSucceedsTilde NotSuperset NotSupersetEqual NotTilde NotTildeEqual
|
|
54
|
+
NotTildeFullEqual NotTildeTilde NotVerticalBar Nscr Ntilde Nu OElig Oacute
|
|
55
|
+
Ocirc Ocy Odblac Ofr Ograve Omacr Omega Omicron Oopf OpenCurlyDoubleQuote
|
|
56
|
+
OpenCurlyQuote Or Oscr Oslash Otilde Otimes Ouml OverBar OverBrace OverBracket
|
|
57
|
+
OverParenthesis PartialD Pcy Pfr Phi Pi PlusMinus Poincareplane Popf Pr
|
|
58
|
+
Precedes PrecedesEqual PrecedesSlantEqual PrecedesTilde Prime Product
|
|
59
|
+
Proportion Proportional Pscr Psi QUOT Qfr Qopf Qscr RBarr REG Racute Rang Rarr
|
|
60
|
+
Rarrtl Rcaron Rcedil Rcy Re ReverseElement ReverseEquilibrium
|
|
61
|
+
ReverseUpEquilibrium Rfr Rho RightAngleBracket RightArrow RightArrowBar
|
|
62
|
+
RightArrowLeftArrow RightCeiling RightDoubleBracket RightDownTeeVector
|
|
63
|
+
RightDownVector RightDownVectorBar RightFloor RightTee RightTeeArrow
|
|
64
|
+
RightTeeVector RightTriangle RightTriangleBar RightTriangleEqual
|
|
65
|
+
RightUpDownVector RightUpTeeVector RightUpVector RightUpVectorBar RightVector
|
|
66
|
+
RightVectorBar Rightarrow Ropf RoundImplies Rrightarrow Rscr Rsh RuleDelayed
|
|
67
|
+
SHCHcy SHcy SOFTcy Sacute Sc Scaron Scedil Scirc Scy Sfr ShortDownArrow
|
|
68
|
+
ShortLeftArrow ShortRightArrow ShortUpArrow Sigma SmallCircle Sopf Sqrt Square
|
|
69
|
+
SquareIntersection SquareSubset SquareSubsetEqual SquareSuperset
|
|
70
|
+
SquareSupersetEqual SquareUnion Sscr Star Sub Subset SubsetEqual Succeeds
|
|
71
|
+
SucceedsEqual SucceedsSlantEqual SucceedsTilde SuchThat Sum Sup Superset
|
|
72
|
+
SupersetEqual Supset THORN TRADE TSHcy TScy Tab Tau Tcaron Tcedil Tcy Tfr
|
|
73
|
+
Therefore Theta ThickSpace ThinSpace Tilde TildeEqual TildeFullEqual TildeTilde
|
|
74
|
+
Topf TripleDot Tscr Tstrok Uacute Uarr Uarrocir Ubrcy Ubreve Ucirc Ucy Udblac
|
|
75
|
+
Ufr Ugrave Umacr UnderBar UnderBrace UnderBracket UnderParenthesis Union
|
|
76
|
+
UnionPlus Uogon Uopf UpArrow UpArrowBar UpArrowDownArrow UpDownArrow
|
|
77
|
+
UpEquilibrium UpTee UpTeeArrow Uparrow Updownarrow UpperLeftArrow
|
|
78
|
+
UpperRightArrow Upsi Upsilon Uring Uscr Utilde Uuml VDash Vbar Vcy Vdash Vdashl
|
|
79
|
+
Vee Verbar Vert VerticalBar VerticalLine VerticalSeparator VerticalTilde
|
|
80
|
+
VeryThinSpace Vfr Vopf Vscr Vvdash Wcirc Wedge Wfr Wopf Wscr Xfr Xi Xopf Xscr
|
|
81
|
+
YAcy YIcy YUcy Yacute Ycirc Ycy Yfr Yopf Yscr Yuml ZHcy Zacute Zcaron Zcy Zdot
|
|
82
|
+
ZeroWidthSpace Zeta Zfr Zopf Zscr aacute abreve ac acE acd acirc acute acy
|
|
83
|
+
aelig af afr agrave alefsym aleph alpha amacr amalg amp and andand andd
|
|
84
|
+
andslope andv ang ange angle angmsd angmsdaa angmsdab angmsdac angmsdad
|
|
85
|
+
angmsdae angmsdaf angmsdag angmsdah angrt angrtvb angrtvbd angsph angst angzarr
|
|
86
|
+
aogon aopf ap apE apacir ape apid apos approx approxeq aring ascr ast asymp
|
|
87
|
+
asympeq atilde auml awconint awint bNot backcong backepsilon backprime backsim
|
|
88
|
+
backsimeq barvee barwed barwedge bbrk bbrktbrk bcong bcy bdquo becaus because
|
|
89
|
+
bemptyv bepsi bernou beta beth between bfr bigcap bigcirc bigcup bigodot
|
|
90
|
+
bigoplus bigotimes bigsqcup bigstar bigtriangledown bigtriangleup biguplus
|
|
91
|
+
bigvee bigwedge bkarow blacklozenge blacksquare blacktriangle blacktriangledown
|
|
92
|
+
blacktriangleleft blacktriangleright blank blk12 blk14 blk34 block bne bnequiv
|
|
93
|
+
bnot bopf bot bottom bowtie boxDL boxDR boxDl boxDr boxH boxHD boxHU boxHd
|
|
94
|
+
boxHu boxUL boxUR boxUl boxUr boxV boxVH boxVL boxVR boxVh boxVl boxVr boxbox
|
|
95
|
+
boxdL boxdR boxdl boxdr boxh boxhD boxhU boxhd boxhu boxminus boxplus boxtimes
|
|
96
|
+
boxuL boxuR boxul boxur boxv boxvH boxvL boxvR boxvh boxvl boxvr bprime breve
|
|
97
|
+
brvbar bscr bsemi bsim bsime bsol bsolb bsolhsub bull bullet bump bumpE bumpe
|
|
98
|
+
bumpeq cacute cap capand capbrcup capcap capcup capdot caps caret caron ccaps
|
|
99
|
+
ccaron ccedil ccirc ccups ccupssm cdot cedil cemptyv cent centerdot cfr chcy
|
|
100
|
+
check checkmark chi cir cirE circ circeq circlearrowleft circlearrowright
|
|
101
|
+
circledR circledS circledast circledcirc circleddash cire cirfnint cirmid
|
|
102
|
+
cirscir clubs clubsuit colon colone coloneq comma commat comp compfn complement
|
|
103
|
+
complexes cong congdot conint copf coprod copy copysr crarr cross cscr csub
|
|
104
|
+
csube csup csupe ctdot cudarrl cudarrr cuepr cuesc cularr cularrp cup cupbrcap
|
|
105
|
+
cupcap cupcup cupdot cupor cups curarr curarrm curlyeqprec curlyeqsucc curlyvee
|
|
106
|
+
curlywedge curren curvearrowleft curvearrowright cuvee cuwed cwconint cwint
|
|
107
|
+
cylcty dArr dHar dagger daleth darr dash dashv dbkarow dblac dcaron dcy dd
|
|
108
|
+
ddagger ddarr ddotseq deg delta demptyv dfisht dfr dharl dharr diam diamond
|
|
109
|
+
diamondsuit diams die digamma disin div divide divideontimes divonx djcy dlcorn
|
|
110
|
+
dlcrop dollar dopf dot doteq doteqdot dotminus dotplus dotsquare doublebarwedge
|
|
111
|
+
downarrow downdownarrows downharpoonleft downharpoonright drbkarow drcorn
|
|
112
|
+
drcrop dscr dscy dsol dstrok dtdot dtri dtrif duarr duhar dwangle dzcy dzigrarr
|
|
113
|
+
eDDot eDot eacute easter ecaron ecir ecirc ecolon ecy edot ee efDot efr eg
|
|
114
|
+
egrave egs egsdot el elinters ell els elsdot emacr empty emptyset emptyv emsp
|
|
115
|
+
emsp13 emsp14 eng ensp eogon eopf epar eparsl eplus epsi epsilon epsiv eqcirc
|
|
116
|
+
eqcolon eqsim eqslantgtr eqslantless equals equest equiv equivDD eqvparsl erDot
|
|
117
|
+
erarr escr esdot esim eta eth euml euro excl exist expectation exponentiale
|
|
118
|
+
fallingdotseq fcy female ffilig fflig ffllig ffr filig fjlig flat fllig fltns
|
|
119
|
+
fnof fopf forall fork forkv fpartint frac12 frac13 frac14 frac15 frac16 frac18
|
|
120
|
+
frac23 frac25 frac34 frac35 frac38 frac45 frac56 frac58 frac78 frasl frown fscr
|
|
121
|
+
gE gEl gacute gamma gammad gap gbreve gcirc gcy gdot ge gel geq geqq geqslant
|
|
122
|
+
ges gescc gesdot gesdoto gesdotol gesl gesles gfr gg ggg gimel gjcy gl glE gla
|
|
123
|
+
glj gnE gnap gnapprox gne gneq gneqq gnsim gopf grave gscr gsim gsime gsiml gt
|
|
124
|
+
gtcc gtcir gtdot gtlPar gtquest gtrapprox gtrarr gtrdot gtreqless gtreqqless
|
|
125
|
+
gtrless gtrsim gvertneqq gvnE hArr hairsp half hamilt hardcy harr harrcir harrw
|
|
126
|
+
hbar hcirc hearts heartsuit hellip hercon hfr hksearow hkswarow hoarr homtht
|
|
127
|
+
hookleftarrow hookrightarrow hopf horbar hscr hslash hstrok hybull hyphen
|
|
128
|
+
iacute ic icirc icy iecy iexcl iff ifr igrave ii iiiint iiint iinfin iiota
|
|
129
|
+
ijlig imacr image imagline imagpart imath imof imped in incare infin infintie
|
|
130
|
+
inodot int intcal integers intercal intlarhk intprod iocy iogon iopf iota iprod
|
|
131
|
+
iquest iscr isin isinE isindot isins isinsv isinv it itilde iukcy iuml jcirc
|
|
132
|
+
jcy jfr jmath jopf jscr jsercy jukcy kappa kappav kcedil kcy kfr kgreen khcy
|
|
133
|
+
kjcy kopf kscr lAarr lArr lAtail lBarr lE lEg lHar lacute laemptyv lagran
|
|
134
|
+
lambda lang langd langle lap laquo larr larrb larrbfs larrfs larrhk larrlp
|
|
135
|
+
larrpl larrsim larrtl lat latail late lates lbarr lbbrk lbrace lbrack lbrke
|
|
136
|
+
lbrksld lbrkslu lcaron lcedil lceil lcub lcy ldca ldquo ldquor ldrdhar ldrushar
|
|
137
|
+
ldsh le leftarrow leftarrowtail leftharpoondown leftharpoonup leftleftarrows
|
|
138
|
+
leftrightarrow leftrightarrows leftrightharpoons leftrightsquigarrow
|
|
139
|
+
leftthreetimes leg leq leqq leqslant les lescc lesdot lesdoto lesdotor lesg
|
|
140
|
+
lesges lessapprox lessdot lesseqgtr lesseqqgtr lessgtr lesssim lfisht lfloor
|
|
141
|
+
lfr lg lgE lhard lharu lharul lhblk ljcy ll llarr llcorner llhard lltri lmidot
|
|
142
|
+
lmoust lmoustache lnE lnap lnapprox lne lneq lneqq lnsim loang loarr lobrk
|
|
143
|
+
longleftarrow longleftrightarrow longmapsto longrightarrow looparrowleft
|
|
144
|
+
looparrowright lopar lopf loplus lotimes lowast lowbar loz lozenge lozf lpar
|
|
145
|
+
lparlt lrarr lrcorner lrhar lrhard lrm lrtri lsaquo lscr lsh lsim lsime lsimg
|
|
146
|
+
lsqb lsquo lsquor lstrok lt ltcc ltcir ltdot lthree ltimes ltlarr ltquest
|
|
147
|
+
ltrPar ltri ltrie ltrif lurdshar luruhar lvertneqq lvnE mDDot macr male malt
|
|
148
|
+
maltese map mapsto mapstodown mapstoleft mapstoup marker mcomma mcy mdash
|
|
149
|
+
measuredangle mfr mho micro mid midast midcir middot minus minusb minusd
|
|
150
|
+
minusdu mlcp mldr mnplus models mopf mp mscr mstpos mu multimap mumap nGg nGt
|
|
151
|
+
nGtv nLeftarrow nLeftrightarrow nLl nLt nLtv nRightarrow nVDash nVdash nabla
|
|
152
|
+
nacute nang nap napE napid napos napprox natur natural naturals nbsp nbump
|
|
153
|
+
nbumpe ncap ncaron ncedil ncong ncongdot ncup ncy ndash ne neArr nearhk nearr
|
|
154
|
+
nearrow nedot nequiv nesear nesim nexist nexists nfr ngE nge ngeq ngeqq
|
|
155
|
+
ngeqslant nges ngsim ngt ngtr nhArr nharr nhpar ni nis nisd niv njcy nlArr nlE
|
|
156
|
+
nlarr nldr nle nleftarrow nleftrightarrow nleq nleqq nleqslant nles nless nlsim
|
|
157
|
+
nlt nltri nltrie nmid nopf not notin notinE notindot notinva notinvb notinvc
|
|
158
|
+
notni notniva notnivb notnivc npar nparallel nparsl npart npolint npr nprcue
|
|
159
|
+
npre nprec npreceq nrArr nrarr nrarrc nrarrw nrightarrow nrtri nrtrie nsc
|
|
160
|
+
nsccue nsce nscr nshortmid nshortparallel nsim nsime nsimeq nsmid nspar nsqsube
|
|
161
|
+
nsqsupe nsub nsubE nsube nsubset nsubseteq nsubseteqq nsucc nsucceq nsup nsupE
|
|
162
|
+
nsupe nsupset nsupseteq nsupseteqq ntgl ntilde ntlg ntriangleleft
|
|
163
|
+
ntrianglelefteq ntriangleright ntrianglerighteq nu num numero numsp nvDash
|
|
164
|
+
nvHarr nvap nvdash nvge nvgt nvinfin nvlArr nvle nvlt nvltrie nvrArr nvrtrie
|
|
165
|
+
nvsim nwArr nwarhk nwarr nwarrow nwnear oS oacute oast ocir ocirc ocy odash
|
|
166
|
+
odblac odiv odot odsold oelig ofcir ofr ogon ograve ogt ohbar ohm oint olarr
|
|
167
|
+
olcir olcross oline olt omacr omega omicron omid ominus oopf opar operp oplus
|
|
168
|
+
or orarr ord order orderof ordf ordm origof oror orslope orv oscr oslash osol
|
|
169
|
+
otilde otimes otimesas ouml ovbar par para parallel parsim parsl part pcy
|
|
170
|
+
percnt period permil perp pertenk pfr phi phiv phmmat phone pi pitchfork piv
|
|
171
|
+
planck planckh plankv plus plusacir plusb pluscir plusdo plusdu pluse plusmn
|
|
172
|
+
plussim plustwo pm pointint popf pound pr prE prap prcue pre prec precapprox
|
|
173
|
+
preccurlyeq preceq precnapprox precneqq precnsim precsim prime primes prnE
|
|
174
|
+
prnap prnsim prod profalar profline profsurf prop propto prsim prurel pscr psi
|
|
175
|
+
puncsp qfr qint qopf qprime qscr quaternions quatint quest questeq quot rAarr
|
|
176
|
+
rArr rAtail rBarr rHar race racute radic raemptyv rang rangd range rangle raquo
|
|
177
|
+
rarr rarrap rarrb rarrbfs rarrc rarrfs rarrhk rarrlp rarrpl rarrsim rarrtl
|
|
178
|
+
rarrw ratail ratio rationals rbarr rbbrk rbrace rbrack rbrke rbrksld rbrkslu
|
|
179
|
+
rcaron rcedil rceil rcub rcy rdca rdldhar rdquo rdquor rdsh real realine
|
|
180
|
+
realpart reals rect reg rfisht rfloor rfr rhard rharu rharul rho rhov
|
|
181
|
+
rightarrow rightarrowtail rightharpoondown rightharpoonup rightleftarrows
|
|
182
|
+
rightleftharpoons rightrightarrows rightsquigarrow rightthreetimes ring
|
|
183
|
+
risingdotseq rlarr rlhar rlm rmoust rmoustache rnmid roang roarr robrk ropar
|
|
184
|
+
ropf roplus rotimes rpar rpargt rppolint rrarr rsaquo rscr rsh rsqb rsquo
|
|
185
|
+
rsquor rthree rtimes rtri rtrie rtrif rtriltri ruluhar rx sacute sbquo sc scE
|
|
186
|
+
scap scaron sccue sce scedil scirc scnE scnap scnsim scpolint scsim scy sdot
|
|
187
|
+
sdotb sdote seArr searhk searr searrow sect semi seswar setminus setmn sext sfr
|
|
188
|
+
sfrown sharp shchcy shcy shortmid shortparallel shy sigma sigmaf sigmav sim
|
|
189
|
+
simdot sime simeq simg simgE siml simlE simne simplus simrarr slarr
|
|
190
|
+
smallsetminus smashp smeparsl smid smile smt smte smtes softcy sol solb solbar
|
|
191
|
+
sopf spades spadesuit spar sqcap sqcaps sqcup sqcups sqsub sqsube sqsubset
|
|
192
|
+
sqsubseteq sqsup sqsupe sqsupset sqsupseteq squ square squarf squf srarr sscr
|
|
193
|
+
ssetmn ssmile sstarf star starf straightepsilon straightphi strns sub subE
|
|
194
|
+
subdot sube subedot submult subnE subne subplus subrarr subset subseteq
|
|
195
|
+
subseteqq subsetneq subsetneqq subsim subsub subsup succ succapprox succcurlyeq
|
|
196
|
+
succeq succnapprox succneqq succnsim succsim sum sung sup sup1 sup2 sup3 supE
|
|
197
|
+
supdot supdsub supe supedot suphsol suphsub suplarr supmult supnE supne supplus
|
|
198
|
+
supset supseteq supseteqq supsetneq supsetneqq supsim supsub supsup swArr
|
|
199
|
+
swarhk swarr swarrow swnwar szlig target tau tbrk tcaron tcedil tcy tdot telrec
|
|
200
|
+
tfr there4 therefore theta thetasym thetav thickapprox thicksim thinsp thkap
|
|
201
|
+
thksim thorn tilde times timesb timesbar timesd tint toea top topbot topcir
|
|
202
|
+
topf topfork tosa tprime trade triangle triangledown triangleleft
|
|
203
|
+
trianglelefteq triangleq triangleright trianglerighteq tridot trie triminus
|
|
204
|
+
triplus trisb tritime trpezium tscr tscy tshcy tstrok twixt twoheadleftarrow
|
|
205
|
+
twoheadrightarrow uArr uHar uacute uarr ubrcy ubreve ucirc ucy udarr udblac
|
|
206
|
+
udhar ufisht ufr ugrave uharl uharr uhblk ulcorn ulcorner ulcrop ultri umacr
|
|
207
|
+
uml uogon uopf uparrow updownarrow upharpoonleft upharpoonright uplus upsi
|
|
208
|
+
upsih upsilon upuparrows urcorn urcorner urcrop uring urtri uscr utdot utilde
|
|
209
|
+
utri utrif uuarr uuml uwangle vArr vBar vBarv vDash vangrt varepsilon varkappa
|
|
210
|
+
varnothing varphi varpi varpropto varr varrho varsigma varsubsetneq
|
|
211
|
+
varsubsetneqq varsupsetneq varsupsetneqq vartheta vartriangleleft
|
|
212
|
+
vartriangleright vcy vdash vee veebar veeeq vellip verbar vert vfr vltri vnsub
|
|
213
|
+
vnsup vopf vprop vrtri vscr vsubnE vsubne vsupnE vsupne vzigzag wcirc wedbar
|
|
214
|
+
wedge wedgeq weierp wfr wopf wp wr wreath wscr xcap xcirc xcup xdtri xfr xhArr
|
|
215
|
+
xharr xi xlArr xlarr xmap xnis xodot xopf xoplus xotime xrArr xrarr xscr xsqcup
|
|
216
|
+
xuplus xutri xvee xwedge yacute yacy ycirc ycy yen yfr yicy yopf yscr yucy yuml
|
|
217
|
+
zacute zcaron zcy zdot zeetrf zeta zfr zhcy zigrarr zopf zscr zwj zwnj
|
|
218
|
+
`;
|
|
219
|
+
|
|
220
|
+
let names: Set<string> | null = null;
|
|
221
|
+
|
|
222
|
+
/** whether name is a named character reference */
|
|
223
|
+
export function is_entity_name(name: string): boolean {
|
|
224
|
+
if (names === null) names = new Set(NAMES.trim().split(/\s+/));
|
|
225
|
+
return names.has(name);
|
|
226
|
+
}
|