@covalent/flavored-markdown 3.1.2 → 4.0.0-beta.2

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.
Files changed (35) hide show
  1. package/README.md +1 -1
  2. package/_flavored-markdown-theme.scss +1 -0
  3. package/cfm-list/cfm-list.component.d.ts +3 -0
  4. package/covalent-flavored-markdown.d.ts +1 -1
  5. package/esm2020/cfm-list/cfm-list.component.mjs +60 -0
  6. package/esm2020/covalent-flavored-markdown.mjs +5 -0
  7. package/esm2020/flavored-markdown-loader/flavored-markdown-loader.component.mjs +102 -0
  8. package/esm2020/flavored-markdown.component.mjs +476 -0
  9. package/esm2020/flavored-markdown.module.mjs +69 -0
  10. package/esm2020/index.mjs +2 -0
  11. package/esm2020/public_api.mjs +4 -0
  12. package/fesm2015/covalent-flavored-markdown.mjs +763 -0
  13. package/fesm2015/covalent-flavored-markdown.mjs.map +1 -0
  14. package/fesm2020/covalent-flavored-markdown.mjs +695 -0
  15. package/fesm2020/covalent-flavored-markdown.mjs.map +1 -0
  16. package/flavored-markdown-loader/flavored-markdown-loader.component.d.ts +3 -0
  17. package/flavored-markdown-loader/flavored-markdown-loader.component.scss +4 -2
  18. package/flavored-markdown.component.d.ts +26 -1
  19. package/flavored-markdown.component.scss +2 -0
  20. package/flavored-markdown.module.d.ts +16 -0
  21. package/package.json +35 -20
  22. package/bundles/covalent-flavored-markdown.umd.js +0 -1305
  23. package/bundles/covalent-flavored-markdown.umd.js.map +0 -1
  24. package/bundles/covalent-flavored-markdown.umd.min.js +0 -16
  25. package/bundles/covalent-flavored-markdown.umd.min.js.map +0 -1
  26. package/covalent-flavored-markdown.metadata.json +0 -1
  27. package/esm2015/cfm-list/cfm-list.component.js +0 -39
  28. package/esm2015/covalent-flavored-markdown.js +0 -11
  29. package/esm2015/flavored-markdown-loader/flavored-markdown-loader.component.js +0 -159
  30. package/esm2015/flavored-markdown.component.js +0 -741
  31. package/esm2015/flavored-markdown.module.js +0 -42
  32. package/esm2015/index.js +0 -7
  33. package/esm2015/public_api.js +0 -9
  34. package/fesm2015/covalent-flavored-markdown.js +0 -990
  35. package/fesm2015/covalent-flavored-markdown.js.map +0 -1
@@ -0,0 +1,763 @@
1
+ import * as i0 from '@angular/core';
2
+ import { Component, Input, ViewChild, EventEmitter, HostBinding, Output, Directive, ChangeDetectionStrategy, NgModule } from '@angular/core';
3
+ import { MatCheckbox, MatCheckboxModule } from '@angular/material/checkbox';
4
+ import * as i2$1 from '@angular/material/sort';
5
+ import { MatSort, MatSortModule } from '@angular/material/sort';
6
+ import * as i1$1 from '@angular/material/table';
7
+ import { MatTableDataSource, MatTableModule } from '@angular/material/table';
8
+ import * as i1 from '@angular/material/list';
9
+ import { MatListModule } from '@angular/material/list';
10
+ import * as i2 from '@angular/common';
11
+ import { CommonModule } from '@angular/common';
12
+ import * as i3 from '@angular/material/core';
13
+ import * as i4 from '@angular/material/divider';
14
+ import { TdHighlightComponent, CovalentHighlightModule } from '@covalent/highlight';
15
+ import * as i1$2 from '@covalent/markdown';
16
+ import { scrollToAnchor, TdMarkdownComponent, CovalentMarkdownModule } from '@covalent/markdown';
17
+ import * as i4$1 from '@angular/material/button';
18
+ import { MatButtonModule } from '@angular/material/button';
19
+ import * as i3$1 from '@angular/material/progress-bar';
20
+ import { MatProgressBarModule } from '@angular/material/progress-bar';
21
+ import { __awaiter } from 'tslib';
22
+
23
+ function TdFlavoredListComponent_ng_template_1_p_3_Template(rf, ctx) {
24
+ if (rf & 1) {
25
+ i0.ɵɵelementStart(0, "p", 1);
26
+ i0.ɵɵtext(1);
27
+ i0.ɵɵelementEnd();
28
+ }
29
+ if (rf & 2) {
30
+ const subline_r5 = ctx.$implicit;
31
+ i0.ɵɵadvance(1);
32
+ i0.ɵɵtextInterpolate1(" ", subline_r5, " ");
33
+ }
34
+ }
35
+ function TdFlavoredListComponent_ng_template_1_mat_divider_4_Template(rf, ctx) {
36
+ if (rf & 1) {
37
+ i0.ɵɵelement(0, "mat-divider");
38
+ }
39
+ }
40
+ function TdFlavoredListComponent_ng_template_1_Template(rf, ctx) {
41
+ if (rf & 1) {
42
+ i0.ɵɵelementStart(0, "mat-list-item");
43
+ i0.ɵɵelementStart(1, "h4", 1);
44
+ i0.ɵɵtext(2);
45
+ i0.ɵɵelementEnd();
46
+ i0.ɵɵtemplate(3, TdFlavoredListComponent_ng_template_1_p_3_Template, 2, 1, "p", 2);
47
+ i0.ɵɵtemplate(4, TdFlavoredListComponent_ng_template_1_mat_divider_4_Template, 1, 0, "mat-divider", 3);
48
+ i0.ɵɵelementEnd();
49
+ }
50
+ if (rf & 2) {
51
+ const line_r1 = ctx.$implicit;
52
+ const last_r2 = ctx.last;
53
+ i0.ɵɵadvance(2);
54
+ i0.ɵɵtextInterpolate1(" ", line_r1.line, " ");
55
+ i0.ɵɵadvance(1);
56
+ i0.ɵɵproperty("ngForOf", line_r1.sublines);
57
+ i0.ɵɵadvance(1);
58
+ i0.ɵɵproperty("ngIf", !last_r2);
59
+ }
60
+ }
61
+ class TdFlavoredListComponent {
62
+ constructor() {
63
+ this.dense = false;
64
+ }
65
+ }
66
+ /** @nocollapse */ /** @nocollapse */ TdFlavoredListComponent.ɵfac = function TdFlavoredListComponent_Factory(t) { return new (t || TdFlavoredListComponent)(); };
67
+ /** @nocollapse */ /** @nocollapse */ TdFlavoredListComponent.ɵcmp = /** @pureOrBreakMyCode */ i0.ɵɵdefineComponent({ type: TdFlavoredListComponent, selectors: [["cfm-list"]], inputs: { lines: "lines", dense: "dense" }, decls: 2, vars: 2, consts: [["ngFor", "", 3, "ngForOf"], ["matLine", ""], ["matLine", "", 4, "ngFor", "ngForOf"], [4, "ngIf"]], template: function TdFlavoredListComponent_Template(rf, ctx) {
68
+ if (rf & 1) {
69
+ i0.ɵɵelementStart(0, "mat-list");
70
+ i0.ɵɵtemplate(1, TdFlavoredListComponent_ng_template_1_Template, 5, 3, "ng-template", 0);
71
+ i0.ɵɵelementEnd();
72
+ }
73
+ if (rf & 2) {
74
+ i0.ɵɵattribute("dense", ctx.dense ? true : null);
75
+ i0.ɵɵadvance(1);
76
+ i0.ɵɵproperty("ngForOf", ctx.lines);
77
+ }
78
+ }, directives: [i1.MatList, i2.NgForOf, i1.MatListItem, i3.MatLine, i2.NgIf, i4.MatDivider], styles: [""] });
79
+ (function () {
80
+ (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(TdFlavoredListComponent, [{
81
+ type: Component,
82
+ args: [{ selector: 'cfm-list', template: "<mat-list [attr.dense]=\"dense ? true : null\">\n <ng-template let-line let-last=\"last\" ngFor [ngForOf]=\"lines\">\n <mat-list-item>\n <h4 matLine>\n {{ line.line }}\n </h4>\n <p *ngFor=\"let subline of line.sublines\" matLine>\n {{ subline }}\n </p>\n <mat-divider *ngIf=\"!last\"></mat-divider>\n </mat-list-item>\n </ng-template>\n</mat-list>\n", styles: [""] }]
83
+ }], null, { lines: [{
84
+ type: Input
85
+ }], dense: [{
86
+ type: Input
87
+ }] });
88
+ })();
89
+
90
+ function TdFlavoredMarkdownTableComponent_ng_template_1_mat_header_cell_1_Template(rf, ctx) {
91
+ if (rf & 1) {
92
+ i0.ɵɵelementStart(0, "mat-header-cell", 7);
93
+ i0.ɵɵtext(1);
94
+ i0.ɵɵelementEnd();
95
+ }
96
+ if (rf & 2) {
97
+ const column_r3 = i0.ɵɵnextContext().$implicit;
98
+ i0.ɵɵadvance(1);
99
+ i0.ɵɵtextInterpolate(column_r3.label);
100
+ }
101
+ }
102
+ function TdFlavoredMarkdownTableComponent_ng_template_1_mat_cell_2_Template(rf, ctx) {
103
+ if (rf & 1) {
104
+ i0.ɵɵelementStart(0, "mat-cell");
105
+ i0.ɵɵtext(1);
106
+ i0.ɵɵelementEnd();
107
+ }
108
+ if (rf & 2) {
109
+ const row_r7 = ctx.$implicit;
110
+ const column_r3 = i0.ɵɵnextContext().$implicit;
111
+ i0.ɵɵadvance(1);
112
+ i0.ɵɵtextInterpolate(row_r7[column_r3.name]);
113
+ }
114
+ }
115
+ function TdFlavoredMarkdownTableComponent_ng_template_1_Template(rf, ctx) {
116
+ if (rf & 1) {
117
+ i0.ɵɵelementContainerStart(0, 4);
118
+ i0.ɵɵtemplate(1, TdFlavoredMarkdownTableComponent_ng_template_1_mat_header_cell_1_Template, 2, 1, "mat-header-cell", 5);
119
+ i0.ɵɵtemplate(2, TdFlavoredMarkdownTableComponent_ng_template_1_mat_cell_2_Template, 2, 1, "mat-cell", 6);
120
+ i0.ɵɵelementContainerEnd();
121
+ }
122
+ if (rf & 2) {
123
+ const column_r3 = ctx.$implicit;
124
+ i0.ɵɵproperty("matColumnDef", column_r3.name);
125
+ }
126
+ }
127
+ function TdFlavoredMarkdownTableComponent_mat_header_row_2_Template(rf, ctx) {
128
+ if (rf & 1) {
129
+ i0.ɵɵelement(0, "mat-header-row");
130
+ }
131
+ }
132
+ function TdFlavoredMarkdownTableComponent_mat_row_3_Template(rf, ctx) {
133
+ if (rf & 1) {
134
+ i0.ɵɵelement(0, "mat-row");
135
+ }
136
+ }
137
+ const _c0 = ["*"];
138
+ class TdFlavoredMarkdownTableComponent {
139
+ constructor() {
140
+ this.columnDefs = [];
141
+ }
142
+ ngOnInit() {
143
+ this.displayedColumns = this.columnDefs.map((c) => c.name);
144
+ this.dataSource = new MatTableDataSource(this.data);
145
+ }
146
+ ngAfterViewInit() {
147
+ this.dataSource.sort = this.sort;
148
+ }
149
+ }
150
+ /** @nocollapse */ /** @nocollapse */ TdFlavoredMarkdownTableComponent.ɵfac = function TdFlavoredMarkdownTableComponent_Factory(t) { return new (t || TdFlavoredMarkdownTableComponent)(); };
151
+ /** @nocollapse */ /** @nocollapse */ TdFlavoredMarkdownTableComponent.ɵcmp = /** @pureOrBreakMyCode */ i0.ɵɵdefineComponent({ type: TdFlavoredMarkdownTableComponent, selectors: [["ng-component"]], viewQuery: function TdFlavoredMarkdownTableComponent_Query(rf, ctx) {
152
+ if (rf & 1) {
153
+ i0.ɵɵviewQuery(MatSort, 5);
154
+ }
155
+ if (rf & 2) {
156
+ let _t;
157
+ i0.ɵɵqueryRefresh(_t = i0.ɵɵloadQuery()) && (ctx.sort = _t.first);
158
+ }
159
+ }, inputs: { columnDefs: "columnDefs", data: "data" }, decls: 4, vars: 4, consts: [["matSort", "", 3, "dataSource"], ["ngFor", "", 3, "ngForOf"], [4, "matHeaderRowDef"], [4, "matRowDef", "matRowDefColumns"], [3, "matColumnDef"], ["mat-sort-header", "", 4, "matHeaderCellDef"], [4, "matCellDef"], ["mat-sort-header", ""]], template: function TdFlavoredMarkdownTableComponent_Template(rf, ctx) {
160
+ if (rf & 1) {
161
+ i0.ɵɵelementStart(0, "mat-table", 0);
162
+ i0.ɵɵtemplate(1, TdFlavoredMarkdownTableComponent_ng_template_1_Template, 3, 1, "ng-template", 1);
163
+ i0.ɵɵtemplate(2, TdFlavoredMarkdownTableComponent_mat_header_row_2_Template, 1, 0, "mat-header-row", 2);
164
+ i0.ɵɵtemplate(3, TdFlavoredMarkdownTableComponent_mat_row_3_Template, 1, 0, "mat-row", 3);
165
+ i0.ɵɵelementEnd();
166
+ }
167
+ if (rf & 2) {
168
+ i0.ɵɵproperty("dataSource", ctx.dataSource);
169
+ i0.ɵɵadvance(1);
170
+ i0.ɵɵproperty("ngForOf", ctx.columnDefs);
171
+ i0.ɵɵadvance(1);
172
+ i0.ɵɵproperty("matHeaderRowDef", ctx.displayedColumns);
173
+ i0.ɵɵadvance(1);
174
+ i0.ɵɵproperty("matRowDefColumns", ctx.displayedColumns);
175
+ }
176
+ }, directives: [i1$1.MatTable, i2$1.MatSort, i2.NgForOf, i1$1.MatColumnDef, i1$1.MatHeaderCellDef, i1$1.MatHeaderCell, i2$1.MatSortHeader, i1$1.MatCellDef, i1$1.MatCell, i1$1.MatHeaderRowDef, i1$1.MatHeaderRow, i1$1.MatRowDef, i1$1.MatRow], encapsulation: 2 });
177
+ (function () {
178
+ (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(TdFlavoredMarkdownTableComponent, [{
179
+ type: Component,
180
+ args: [{
181
+ template: `
182
+ <mat-table [dataSource]="dataSource" matSort>
183
+ <!-- Column Definition -->
184
+ <ng-template ngFor let-column [ngForOf]="columnDefs">
185
+ <ng-container [matColumnDef]="column.name">
186
+ <mat-header-cell *matHeaderCellDef mat-sort-header>{{ column.label }}</mat-header-cell>
187
+ <mat-cell *matCellDef="let row">{{ row[column.name] }}</mat-cell>
188
+ </ng-container>
189
+ </ng-template>
190
+ <!-- Header and Row Declarations -->
191
+ <mat-header-row *matHeaderRowDef="displayedColumns"></mat-header-row>
192
+ <mat-row *matRowDef="let row; columns: displayedColumns"></mat-row>
193
+ </mat-table>
194
+ `,
195
+ }]
196
+ }], null, { columnDefs: [{
197
+ type: Input
198
+ }], data: [{
199
+ type: Input
200
+ }], sort: [{
201
+ type: ViewChild,
202
+ args: [MatSort]
203
+ }] });
204
+ })();
205
+ class TdFlavoredMarkdownButtonComponent {
206
+ constructor() {
207
+ this.display = 'inline-block';
208
+ this.text = '';
209
+ this.data = '';
210
+ this.clicked = new EventEmitter();
211
+ }
212
+ emitClick() {
213
+ this.clicked.emit({ text: this.text, data: this.data });
214
+ }
215
+ }
216
+ /** @nocollapse */ /** @nocollapse */ TdFlavoredMarkdownButtonComponent.ɵfac = function TdFlavoredMarkdownButtonComponent_Factory(t) { return new (t || TdFlavoredMarkdownButtonComponent)(); };
217
+ /** @nocollapse */ /** @nocollapse */ TdFlavoredMarkdownButtonComponent.ɵcmp = /** @pureOrBreakMyCode */ i0.ɵɵdefineComponent({ type: TdFlavoredMarkdownButtonComponent, selectors: [["ng-component"]], hostVars: 2, hostBindings: function TdFlavoredMarkdownButtonComponent_HostBindings(rf, ctx) {
218
+ if (rf & 2) {
219
+ i0.ɵɵstyleProp("display", ctx.display);
220
+ }
221
+ }, inputs: { text: "text", data: "data" }, outputs: { clicked: "clicked" }, decls: 2, vars: 1, consts: [["mat-raised-button", "", 3, "click"]], template: function TdFlavoredMarkdownButtonComponent_Template(rf, ctx) {
222
+ if (rf & 1) {
223
+ i0.ɵɵelementStart(0, "button", 0);
224
+ i0.ɵɵlistener("click", function TdFlavoredMarkdownButtonComponent_Template_button_click_0_listener() { return ctx.emitClick(); });
225
+ i0.ɵɵtext(1);
226
+ i0.ɵɵelementEnd();
227
+ }
228
+ if (rf & 2) {
229
+ i0.ɵɵadvance(1);
230
+ i0.ɵɵtextInterpolate1(" ", ctx.text, " ");
231
+ }
232
+ }, directives: [i4$1.MatButton], encapsulation: 2 });
233
+ (function () {
234
+ (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(TdFlavoredMarkdownButtonComponent, [{
235
+ type: Component,
236
+ args: [{
237
+ template: `
238
+ <button mat-raised-button (click)="emitClick()">
239
+ {{ text }}
240
+ </button>
241
+ `,
242
+ }]
243
+ }], null, { display: [{
244
+ type: HostBinding,
245
+ args: ['style.display']
246
+ }], text: [{
247
+ type: Input
248
+ }], data: [{
249
+ type: Input
250
+ }], clicked: [{
251
+ type: Output
252
+ }] });
253
+ })();
254
+ class TdFlavoredMarkdownContainerDirective {
255
+ constructor(viewContainerRef, _renderer) {
256
+ this.viewContainerRef = viewContainerRef;
257
+ this._renderer = _renderer;
258
+ }
259
+ clear() {
260
+ this._renderer.setProperty(this.viewContainerRef.element.nativeElement, 'innerHTML', '');
261
+ this.viewContainerRef.clear();
262
+ }
263
+ }
264
+ /** @nocollapse */ /** @nocollapse */ TdFlavoredMarkdownContainerDirective.ɵfac = function TdFlavoredMarkdownContainerDirective_Factory(t) { return new (t || TdFlavoredMarkdownContainerDirective)(i0.ɵɵdirectiveInject(i0.ViewContainerRef), i0.ɵɵdirectiveInject(i0.Renderer2)); };
265
+ /** @nocollapse */ /** @nocollapse */ TdFlavoredMarkdownContainerDirective.ɵdir = /** @pureOrBreakMyCode */ i0.ɵɵdefineDirective({ type: TdFlavoredMarkdownContainerDirective, selectors: [["", "tdFlavoredMarkdownContainer", ""]] });
266
+ (function () {
267
+ (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(TdFlavoredMarkdownContainerDirective, [{
268
+ type: Directive,
269
+ args: [{
270
+ selector: '[tdFlavoredMarkdownContainer]',
271
+ }]
272
+ }], function () { return [{ type: i0.ViewContainerRef }, { type: i0.Renderer2 }]; }, null);
273
+ })();
274
+ class TdFlavoredMarkdownComponent {
275
+ constructor(_componentFactoryResolver, _renderer, _changeDetectorRef, _injector, _elementRef) {
276
+ this._componentFactoryResolver = _componentFactoryResolver;
277
+ this._renderer = _renderer;
278
+ this._changeDetectorRef = _changeDetectorRef;
279
+ this._injector = _injector;
280
+ this._elementRef = _elementRef;
281
+ this._simpleLineBreaks = false;
282
+ this._components = {};
283
+ this._viewInit = false;
284
+ /**
285
+ * copyCodeToClipboard?: boolean
286
+ *
287
+ * Display copy button on code snippets to copy code to clipboard.
288
+ *
289
+ */
290
+ this.copyCodeToClipboard = false;
291
+ /**
292
+ * copyCodeTooltips?: ICopyCodeTooltips
293
+ *
294
+ * Tooltips for copy button to copy and upon copying.
295
+ */
296
+ this.copyCodeTooltips = {};
297
+ /**
298
+ * contentReady?: function
299
+ * Event emitted after the markdown content rendering is finished.
300
+ */
301
+ this.contentReady = new EventEmitter();
302
+ /**
303
+ * buttonClicked?: ITdFlavoredMarkdownButtonClickEvent
304
+ * Event emitted when a button is clicked
305
+ * Is an object containing text and data of button
306
+ */
307
+ this.buttonClicked = new EventEmitter();
308
+ }
309
+ /**
310
+ * content?: string
311
+ *
312
+ * Markdown format content to be parsed as material/covalent markup.
313
+ *
314
+ * e.g. README.md content.
315
+ */
316
+ set content(content) {
317
+ this._content = content;
318
+ }
319
+ /**
320
+ * simpleLineBreaks?: string
321
+ *
322
+ * Sets whether newline characters inside paragraphs and spans are parsed as <br/>.
323
+ * Defaults to false.
324
+ */
325
+ set simpleLineBreaks(simpleLineBreaks) {
326
+ this._simpleLineBreaks = simpleLineBreaks;
327
+ }
328
+ /**
329
+ * hostedUrl?: string
330
+ *
331
+ * If markdown contains relative paths, this is required to generate correct urls
332
+ *
333
+ */
334
+ set hostedUrl(hostedUrl) {
335
+ this._hostedUrl = hostedUrl;
336
+ }
337
+ /**
338
+ * anchor?: string
339
+ *
340
+ * Anchor to jump to
341
+ *
342
+ */
343
+ set anchor(anchor) {
344
+ this._anchor = anchor;
345
+ }
346
+ ngOnChanges(changes) {
347
+ // only anchor changed
348
+ if (changes.anchor && !changes.content && !changes.simpleLineBreaks && !changes.hostedUrl) {
349
+ scrollToAnchor(this._elementRef.nativeElement, this._anchor, false);
350
+ }
351
+ else {
352
+ this.refresh();
353
+ }
354
+ }
355
+ ngAfterViewInit() {
356
+ if (!this._content) {
357
+ this._loadContent(this.container.viewContainerRef.element.nativeElement.textContent);
358
+ Promise.resolve().then(() => {
359
+ this._viewInit = true;
360
+ this._changeDetectorRef.markForCheck();
361
+ });
362
+ }
363
+ }
364
+ refresh() {
365
+ if (this._content) {
366
+ this._loadContent(this._content);
367
+ }
368
+ else if (this._viewInit) {
369
+ this._loadContent(this.container.viewContainerRef.element.nativeElement.textContent);
370
+ }
371
+ this._changeDetectorRef.markForCheck();
372
+ }
373
+ _loadContent(markdown) {
374
+ if (markdown && markdown.trim().length > 0) {
375
+ this.container.clear();
376
+ markdown = markdown.replace(/^(\s|\t)*\n+/g, '').replace(/(\s|\t)*\n+(\s|\t)*$/g, '');
377
+ // Split markdown by line characters
378
+ let lines = markdown.split('\n');
379
+ // check how much indentation is used by the first actual markdown line
380
+ const firstLineWhitespace = lines[0].match(/^(\s|\t)*/)[0];
381
+ // Remove all indentation spaces so markdown can be parsed correctly
382
+ const startingWhitespaceRegex = new RegExp('^' + firstLineWhitespace);
383
+ lines = lines.map(function (line) {
384
+ return line.replace(startingWhitespaceRegex, '');
385
+ });
386
+ // Join lines again with line characters
387
+ markdown = [...lines, '', ''].join('\n');
388
+ markdown = this._replaceCodeBlocks(markdown);
389
+ markdown = this._replaceCheckbox(markdown);
390
+ markdown = this._replaceTables(markdown);
391
+ markdown = this._replaceLists(markdown);
392
+ markdown = this._replaceButtons(markdown);
393
+ const keys = Object.keys(this._components);
394
+ // need to sort the placeholders in order of encounter in markdown content
395
+ keys.sort((compA, compB) => {
396
+ return markdown.indexOf(compA) > markdown.indexOf(compB) ? 1 : -1;
397
+ });
398
+ this._render(markdown, keys[0], keys);
399
+ // TODO: timeout required since resizing of html elements occurs which causes a change in the scroll position
400
+ setTimeout(() => scrollToAnchor(this._elementRef.nativeElement, this._anchor, false), 250);
401
+ this.contentReady.emit();
402
+ Promise.resolve().then(() => {
403
+ this._changeDetectorRef.markForCheck();
404
+ });
405
+ }
406
+ }
407
+ _render(markdown, key, keys) {
408
+ if (!markdown) {
409
+ return;
410
+ }
411
+ if (key && markdown.indexOf(key) > -1) {
412
+ const markdownParts = markdown.split(key);
413
+ keys.shift();
414
+ this._render(markdownParts[0], undefined, undefined);
415
+ this.container.viewContainerRef.insert(this._components[key].hostView, this.container.viewContainerRef.length);
416
+ this._components[key] = undefined;
417
+ delete this._components[key];
418
+ this._render(markdownParts[1], keys[0], keys);
419
+ }
420
+ else {
421
+ const contentRef = this._componentFactoryResolver
422
+ .resolveComponentFactory(TdMarkdownComponent)
423
+ .create(this._injector);
424
+ contentRef.instance.content = markdown;
425
+ contentRef.instance.hostedUrl = this._hostedUrl;
426
+ contentRef.instance.simpleLineBreaks = this._simpleLineBreaks;
427
+ contentRef.instance.refresh();
428
+ this.container.viewContainerRef.insert(contentRef.hostView, this.container.viewContainerRef.length);
429
+ }
430
+ }
431
+ _replaceComponent(markdown, type, regExp, replacerFunc) {
432
+ let componentIndex = 0;
433
+ return markdown.replace(regExp, (...args) => {
434
+ const componentFactory = this._componentFactoryResolver.resolveComponentFactory(type);
435
+ const componentRef = componentFactory.create(this._injector);
436
+ replacerFunc(componentRef, ...args);
437
+ const key = '[' + componentFactory.selector + '-placeholder-' + componentIndex++ + ']';
438
+ this._components[key] = componentRef;
439
+ return key;
440
+ });
441
+ }
442
+ _replaceCheckbox(markdown) {
443
+ const checkboxRegExp = /(?:^|\n)- \[(x| )\](.*)/gi;
444
+ return this._replaceComponent(markdown, MatCheckbox, checkboxRegExp, (componentRef, match, checked, label) => {
445
+ componentRef.instance.checked = !!checked.trim();
446
+ componentRef.instance.disabled = true;
447
+ componentRef.instance.labelPosition = 'after';
448
+ this._renderer.setProperty(componentRef.instance._elementRef.nativeElement.getElementsByClassName('mat-checkbox-label')[0], 'innerHTML', label);
449
+ });
450
+ }
451
+ _replaceButtons(markdown) {
452
+ const buttonRegExp = /\[([^\[]+)\](\(#data=(.*)\))/i;
453
+ const globalButtonRegExp = new RegExp(buttonRegExp.source, buttonRegExp.flags + 'g');
454
+ return this._replaceComponent(markdown, TdFlavoredMarkdownButtonComponent, globalButtonRegExp, (componentRef, match) => {
455
+ const matches = buttonRegExp.exec(match);
456
+ const text = matches[1];
457
+ const data = matches[3];
458
+ componentRef.instance.text = text;
459
+ componentRef.instance.data = data;
460
+ componentRef.instance.clicked.subscribe((clickEvent) => this.buttonClicked.emit(clickEvent));
461
+ });
462
+ }
463
+ _replaceCodeBlocks(markdown) {
464
+ const codeBlockRegExp = /(?:^|\n)```(.*)\n([\s\S]*?)\n```/g;
465
+ return this._replaceComponent(markdown, TdHighlightComponent, codeBlockRegExp, (componentRef, match, language, codeblock) => {
466
+ if (language) {
467
+ componentRef.instance.codeLang = language;
468
+ }
469
+ componentRef.instance.copyCodeToClipboard = this.copyCodeToClipboard;
470
+ componentRef.instance.copyCodeTooltips = this.copyCodeTooltips;
471
+ componentRef.instance.content = codeblock;
472
+ });
473
+ }
474
+ _replaceTables(markdown) {
475
+ const tableRgx = /^ {0,3}\|?.+\|.+\n[ \t]{0,3}\|?[ \t]*:?[ \t]*(?:-|=){2,}[ \t]*:?[ \t]*\|[ \t]*:?[ \t]*(?:-|=){2,}[\s\S]+?(?:\n\n|~0)/gm;
476
+ return this._replaceComponent(markdown, TdFlavoredMarkdownTableComponent, tableRgx, (componentRef, match) => {
477
+ const dataTableLines = match.replace(/(\s|\t)*\n+(\s|\t)*$/g, '').split('\n');
478
+ const columns = dataTableLines[0]
479
+ .split('|')
480
+ .filter((col) => {
481
+ return col;
482
+ })
483
+ .map((s) => {
484
+ return s.trim();
485
+ });
486
+ const alignment = dataTableLines[1]
487
+ .split('|')
488
+ .filter((v) => {
489
+ return v;
490
+ })
491
+ .map((s) => {
492
+ return s.trim();
493
+ });
494
+ const data = [];
495
+ for (let i = 2; i < dataTableLines.length; i++) {
496
+ const rowSplit = dataTableLines[i]
497
+ .split('|')
498
+ .filter((cell) => {
499
+ return cell;
500
+ })
501
+ .map((s) => {
502
+ return s.trim();
503
+ });
504
+ const row = {};
505
+ columns.forEach((col, index) => {
506
+ const rowSplitCell = rowSplit[index];
507
+ if (rowSplitCell) {
508
+ row[col.toLowerCase().trim()] = rowSplitCell.replace(/`(.*)`/, (m, value) => {
509
+ return value;
510
+ });
511
+ }
512
+ });
513
+ data.push(row);
514
+ }
515
+ componentRef.instance.columnDefs = columns.map((col, index) => {
516
+ return {
517
+ label: col,
518
+ name: col.toLowerCase().trim(),
519
+ numeric: /^--*[ \t]*:[ \t]*$/.test(alignment[index]),
520
+ };
521
+ });
522
+ componentRef.instance.data = data;
523
+ });
524
+ }
525
+ _replaceLists(markdown) {
526
+ const listRegExp = /(?:^|\n)(( *\+)[ |\t](.*)\n)+/g;
527
+ return this._replaceComponent(markdown, TdFlavoredListComponent, listRegExp, (componentRef, match) => {
528
+ const lineTexts = match.split(new RegExp('\\n {' + (match.indexOf('+') - 1).toString() + '}\\+[ |\\t]'));
529
+ lineTexts.shift();
530
+ const lines = [];
531
+ lineTexts.forEach((text, index) => {
532
+ const sublineTexts = text.split(/\n *\+ /);
533
+ lines.push({
534
+ line: sublineTexts.shift(),
535
+ sublines: sublineTexts.map((subline) => {
536
+ return subline.trim();
537
+ }),
538
+ });
539
+ });
540
+ componentRef.instance.lines = lines;
541
+ });
542
+ }
543
+ }
544
+ /** @nocollapse */ /** @nocollapse */ TdFlavoredMarkdownComponent.ɵfac = function TdFlavoredMarkdownComponent_Factory(t) { return new (t || TdFlavoredMarkdownComponent)(i0.ɵɵdirectiveInject(i0.ComponentFactoryResolver), i0.ɵɵdirectiveInject(i0.Renderer2), i0.ɵɵdirectiveInject(i0.ChangeDetectorRef), i0.ɵɵdirectiveInject(i0.Injector), i0.ɵɵdirectiveInject(i0.ElementRef)); };
545
+ /** @nocollapse */ /** @nocollapse */ TdFlavoredMarkdownComponent.ɵcmp = /** @pureOrBreakMyCode */ i0.ɵɵdefineComponent({ type: TdFlavoredMarkdownComponent, selectors: [["td-flavored-markdown"]], viewQuery: function TdFlavoredMarkdownComponent_Query(rf, ctx) {
546
+ if (rf & 1) {
547
+ i0.ɵɵviewQuery(TdFlavoredMarkdownContainerDirective, 7);
548
+ }
549
+ if (rf & 2) {
550
+ let _t;
551
+ i0.ɵɵqueryRefresh(_t = i0.ɵɵloadQuery()) && (ctx.container = _t.first);
552
+ }
553
+ }, inputs: { content: "content", simpleLineBreaks: "simpleLineBreaks", hostedUrl: "hostedUrl", anchor: "anchor", copyCodeToClipboard: "copyCodeToClipboard", copyCodeTooltips: "copyCodeTooltips" }, outputs: { contentReady: "contentReady", buttonClicked: "buttonClicked" }, features: [i0.ɵɵNgOnChangesFeature], ngContentSelectors: _c0, decls: 2, vars: 0, consts: [["tdFlavoredMarkdownContainer", ""]], template: function TdFlavoredMarkdownComponent_Template(rf, ctx) {
554
+ if (rf & 1) {
555
+ i0.ɵɵprojectionDef();
556
+ i0.ɵɵelementStart(0, "div", 0);
557
+ i0.ɵɵprojection(1);
558
+ i0.ɵɵelementEnd();
559
+ }
560
+ }, directives: [TdFlavoredMarkdownContainerDirective], styles: ["[_nghost-%COMP%] td-markdown:first-of-type>div:first-of-type>h1:first-of-type, [_nghost-%COMP%] td-markdown:first-of-type>div:first-of-type>h2:first-of-type{margin-top:0}[_nghost-%COMP%] td-data-table, [_nghost-%COMP%] mat-checkbox{display:block}[_nghost-%COMP%] td-data-table, [_nghost-%COMP%] td-highlight, [_nghost-%COMP%] mat-checkbox:last-of-type{margin-bottom:16px}[_nghost-%COMP%] :not(pre)>code{font-family:Menlo,Monaco,Andale Mono,lucida console,Courier New,monospace;padding-left:2px;padding-right:2px}[_nghost-%COMP%] td-highlight{display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row;-ms-flex-pack:justify;justify-content:space-between}"], changeDetection: 0 });
561
+ (function () {
562
+ (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(TdFlavoredMarkdownComponent, [{
563
+ type: Component,
564
+ args: [{ selector: 'td-flavored-markdown', changeDetection: ChangeDetectionStrategy.OnPush, template: "<div tdFlavoredMarkdownContainer>\n <ng-content></ng-content>\n</div>\n", styles: [":host ::ng-deep td-markdown:first-of-type>div:first-of-type>h1:first-of-type,:host ::ng-deep td-markdown:first-of-type>div:first-of-type>h2:first-of-type{margin-top:0}:host ::ng-deep td-data-table,:host ::ng-deep mat-checkbox{display:block}:host ::ng-deep td-data-table,:host ::ng-deep td-highlight,:host ::ng-deep mat-checkbox:last-of-type{margin-bottom:16px}:host ::ng-deep :not(pre)>code{font-family:Menlo,Monaco,Andale Mono,lucida console,Courier New,monospace;padding-left:2px;padding-right:2px}:host ::ng-deep td-highlight{display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row;-ms-flex-pack:justify;justify-content:space-between}\n"] }]
565
+ }], function () { return [{ type: i0.ComponentFactoryResolver }, { type: i0.Renderer2 }, { type: i0.ChangeDetectorRef }, { type: i0.Injector }, { type: i0.ElementRef }]; }, { content: [{
566
+ type: Input,
567
+ args: ['content']
568
+ }], simpleLineBreaks: [{
569
+ type: Input,
570
+ args: ['simpleLineBreaks']
571
+ }], hostedUrl: [{
572
+ type: Input,
573
+ args: ['hostedUrl']
574
+ }], anchor: [{
575
+ type: Input,
576
+ args: ['anchor']
577
+ }], copyCodeToClipboard: [{
578
+ type: Input
579
+ }], copyCodeTooltips: [{
580
+ type: Input
581
+ }], contentReady: [{
582
+ type: Output
583
+ }], buttonClicked: [{
584
+ type: Output
585
+ }], container: [{
586
+ type: ViewChild,
587
+ args: [TdFlavoredMarkdownContainerDirective, { static: true }]
588
+ }] });
589
+ })();
590
+
591
+ function TdFlavoredMarkdownLoaderComponent_mat_progress_bar_0_Template(rf, ctx) {
592
+ if (rf & 1) {
593
+ i0.ɵɵelement(0, "mat-progress-bar", 2);
594
+ }
595
+ if (rf & 2) {
596
+ i0.ɵɵproperty("ngClass", "delay");
597
+ }
598
+ }
599
+ function TdFlavoredMarkdownLoaderComponent_td_flavored_markdown_1_Template(rf, ctx) {
600
+ if (rf & 1) {
601
+ const _r3 = i0.ɵɵgetCurrentView();
602
+ i0.ɵɵelementStart(0, "td-flavored-markdown", 3);
603
+ i0.ɵɵlistener("contentReady", function TdFlavoredMarkdownLoaderComponent_td_flavored_markdown_1_Template_td_flavored_markdown_contentReady_0_listener() { i0.ɵɵrestoreView(_r3); const ctx_r2 = i0.ɵɵnextContext(); return ctx_r2.contentReady.emit(); })("buttonClicked", function TdFlavoredMarkdownLoaderComponent_td_flavored_markdown_1_Template_td_flavored_markdown_buttonClicked_0_listener($event) { i0.ɵɵrestoreView(_r3); const ctx_r4 = i0.ɵɵnextContext(); return ctx_r4.buttonClicked.emit($event); });
604
+ i0.ɵɵelementEnd();
605
+ }
606
+ if (rf & 2) {
607
+ const ctx_r1 = i0.ɵɵnextContext();
608
+ i0.ɵɵproperty("content", ctx_r1.content)("hostedUrl", ctx_r1.url)("anchor", ctx_r1.anchor)("copyCodeToClipboard", ctx_r1.copyCodeToClipboard)("copyCodeTooltips", ctx_r1.copyCodeTooltips);
609
+ }
610
+ }
611
+ // TODO: make a td-markdown-loader component
612
+ class TdFlavoredMarkdownLoaderComponent {
613
+ constructor(_changeDetectorRef, _markdownUrlLoaderService) {
614
+ this._changeDetectorRef = _changeDetectorRef;
615
+ this._markdownUrlLoaderService = _markdownUrlLoaderService;
616
+ /**
617
+ * copyCodeToClipboard?: boolean
618
+ *
619
+ * Display copy button on code snippets to copy code to clipboard.
620
+ *
621
+ */
622
+ this.copyCodeToClipboard = false;
623
+ /**
624
+ * copyCodeTooltips?: ICopyCodeTooltips
625
+ *
626
+ * Tooltips for copy button to copy and upon copying.
627
+ */
628
+ this.copyCodeTooltips = {};
629
+ /**
630
+ * contentReady: void
631
+ * Emitted when markdown rendering is finished.
632
+ */
633
+ this.contentReady = new EventEmitter();
634
+ /**
635
+ * loadFailed: Error
636
+ * Emitted when loading of markdown file fails.
637
+ */
638
+ this.loadFailed = new EventEmitter();
639
+ this.buttonClicked = new EventEmitter();
640
+ this.loading = true;
641
+ }
642
+ ngOnChanges(changes) {
643
+ if (changes.url || changes.httpOptions) {
644
+ this.loadMarkdown();
645
+ }
646
+ }
647
+ loadMarkdown() {
648
+ return __awaiter(this, void 0, void 0, function* () {
649
+ this.loading = true;
650
+ this._changeDetectorRef.markForCheck();
651
+ try {
652
+ this.content = yield this._markdownUrlLoaderService.load(this.url, this.httpOptions);
653
+ }
654
+ catch (error) {
655
+ this.loadFailed.emit(error);
656
+ }
657
+ finally {
658
+ this.loading = false;
659
+ this._changeDetectorRef.markForCheck();
660
+ }
661
+ });
662
+ }
663
+ }
664
+ /** @nocollapse */ /** @nocollapse */ TdFlavoredMarkdownLoaderComponent.ɵfac = function TdFlavoredMarkdownLoaderComponent_Factory(t) { return new (t || TdFlavoredMarkdownLoaderComponent)(i0.ɵɵdirectiveInject(i0.ChangeDetectorRef), i0.ɵɵdirectiveInject(i1$2.TdMarkdownLoaderService)); };
665
+ /** @nocollapse */ /** @nocollapse */ TdFlavoredMarkdownLoaderComponent.ɵcmp = /** @pureOrBreakMyCode */ i0.ɵɵdefineComponent({ type: TdFlavoredMarkdownLoaderComponent, selectors: [["td-flavored-markdown-loader"]], inputs: { url: "url", httpOptions: "httpOptions", anchor: "anchor", copyCodeToClipboard: "copyCodeToClipboard", copyCodeTooltips: "copyCodeTooltips" }, outputs: { contentReady: "contentReady", loadFailed: "loadFailed", buttonClicked: "buttonClicked" }, features: [i0.ɵɵNgOnChangesFeature], decls: 2, vars: 2, consts: [["mode", "indeterminate", "color", "accent", "class", "sticky", 3, "ngClass", 4, "ngIf"], [3, "content", "hostedUrl", "anchor", "copyCodeToClipboard", "copyCodeTooltips", "contentReady", "buttonClicked", 4, "ngIf"], ["mode", "indeterminate", "color", "accent", 1, "sticky", 3, "ngClass"], [3, "content", "hostedUrl", "anchor", "copyCodeToClipboard", "copyCodeTooltips", "contentReady", "buttonClicked"]], template: function TdFlavoredMarkdownLoaderComponent_Template(rf, ctx) {
666
+ if (rf & 1) {
667
+ i0.ɵɵtemplate(0, TdFlavoredMarkdownLoaderComponent_mat_progress_bar_0_Template, 1, 1, "mat-progress-bar", 0);
668
+ i0.ɵɵtemplate(1, TdFlavoredMarkdownLoaderComponent_td_flavored_markdown_1_Template, 1, 5, "td-flavored-markdown", 1);
669
+ }
670
+ if (rf & 2) {
671
+ i0.ɵɵproperty("ngIf", ctx.loading);
672
+ i0.ɵɵadvance(1);
673
+ i0.ɵɵproperty("ngIf", !ctx.loading);
674
+ }
675
+ }, directives: [i2.NgIf, i3$1.MatProgressBar, i2.NgClass, TdFlavoredMarkdownComponent], styles: ["[_nghost-%COMP%]{display:block}.sticky[_ngcontent-%COMP%]{position:absolute;top:0}.delay[_ngcontent-%COMP%]{-webkit-animation:delay-animation;animation:delay-animation;-webkit-animation-duration:.6s;animation-duration:.6s}@-webkit-keyframes delay-animation{0%{opacity:0}99%{opacity:0}to{opacity:1}}@keyframes delay-animation{0%{opacity:0}99%{opacity:0}to{opacity:1}}"], changeDetection: 0 });
676
+ (function () {
677
+ (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(TdFlavoredMarkdownLoaderComponent, [{
678
+ type: Component,
679
+ args: [{ selector: 'td-flavored-markdown-loader', changeDetection: ChangeDetectionStrategy.OnPush, template: "<mat-progress-bar\n [ngClass]=\"'delay'\"\n *ngIf=\"loading\"\n mode=\"indeterminate\"\n color=\"accent\"\n class=\"sticky\"\n></mat-progress-bar>\n<td-flavored-markdown\n *ngIf=\"!loading\"\n [content]=\"content\"\n [hostedUrl]=\"url\"\n [anchor]=\"anchor\"\n [copyCodeToClipboard]=\"copyCodeToClipboard\"\n [copyCodeTooltips]=\"copyCodeTooltips\"\n (contentReady)=\"contentReady.emit()\"\n (buttonClicked)=\"buttonClicked.emit($event)\"\n></td-flavored-markdown>\n", styles: [":host{display:block}.sticky{position:absolute;top:0}.delay{-webkit-animation:delay-animation;animation:delay-animation;-webkit-animation-duration:.6s;animation-duration:.6s}@-webkit-keyframes delay-animation{0%{opacity:0}99%{opacity:0}to{opacity:1}}@keyframes delay-animation{0%{opacity:0}99%{opacity:0}to{opacity:1}}\n"] }]
680
+ }], function () { return [{ type: i0.ChangeDetectorRef }, { type: i1$2.TdMarkdownLoaderService }]; }, { url: [{
681
+ type: Input
682
+ }], httpOptions: [{
683
+ type: Input
684
+ }], anchor: [{
685
+ type: Input
686
+ }], copyCodeToClipboard: [{
687
+ type: Input
688
+ }], copyCodeTooltips: [{
689
+ type: Input
690
+ }], contentReady: [{
691
+ type: Output
692
+ }], loadFailed: [{
693
+ type: Output
694
+ }], buttonClicked: [{
695
+ type: Output
696
+ }] });
697
+ })();
698
+
699
+ class CovalentFlavoredMarkdownModule {
700
+ }
701
+ /** @nocollapse */ /** @nocollapse */ CovalentFlavoredMarkdownModule.ɵfac = function CovalentFlavoredMarkdownModule_Factory(t) { return new (t || CovalentFlavoredMarkdownModule)(); };
702
+ /** @nocollapse */ /** @nocollapse */ CovalentFlavoredMarkdownModule.ɵmod = /** @pureOrBreakMyCode */ i0.ɵɵdefineNgModule({ type: CovalentFlavoredMarkdownModule });
703
+ /** @nocollapse */ /** @nocollapse */ CovalentFlavoredMarkdownModule.ɵinj = /** @pureOrBreakMyCode */ i0.ɵɵdefineInjector({ imports: [[
704
+ CommonModule,
705
+ MatCheckboxModule,
706
+ MatListModule,
707
+ MatProgressBarModule,
708
+ CovalentHighlightModule,
709
+ CovalentMarkdownModule,
710
+ MatButtonModule,
711
+ MatTableModule,
712
+ MatSortModule,
713
+ ]] });
714
+ (function () {
715
+ (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(CovalentFlavoredMarkdownModule, [{
716
+ type: NgModule,
717
+ args: [{
718
+ imports: [
719
+ CommonModule,
720
+ MatCheckboxModule,
721
+ MatListModule,
722
+ MatProgressBarModule,
723
+ CovalentHighlightModule,
724
+ CovalentMarkdownModule,
725
+ MatButtonModule,
726
+ MatTableModule,
727
+ MatSortModule,
728
+ ],
729
+ declarations: [
730
+ TdFlavoredListComponent,
731
+ TdFlavoredMarkdownComponent,
732
+ TdFlavoredMarkdownContainerDirective,
733
+ TdFlavoredMarkdownLoaderComponent,
734
+ TdFlavoredMarkdownButtonComponent,
735
+ TdFlavoredMarkdownTableComponent,
736
+ ],
737
+ exports: [TdFlavoredMarkdownComponent, TdFlavoredMarkdownLoaderComponent],
738
+ }]
739
+ }], null, null);
740
+ })();
741
+ (function () {
742
+ (typeof ngJitMode === "undefined" || ngJitMode) && i0.ɵɵsetNgModuleScope(CovalentFlavoredMarkdownModule, { declarations: [TdFlavoredListComponent,
743
+ TdFlavoredMarkdownComponent,
744
+ TdFlavoredMarkdownContainerDirective,
745
+ TdFlavoredMarkdownLoaderComponent,
746
+ TdFlavoredMarkdownButtonComponent,
747
+ TdFlavoredMarkdownTableComponent], imports: [CommonModule,
748
+ MatCheckboxModule,
749
+ MatListModule,
750
+ MatProgressBarModule,
751
+ CovalentHighlightModule,
752
+ CovalentMarkdownModule,
753
+ MatButtonModule,
754
+ MatTableModule,
755
+ MatSortModule], exports: [TdFlavoredMarkdownComponent, TdFlavoredMarkdownLoaderComponent] });
756
+ })();
757
+
758
+ /**
759
+ * Generated bundle index. Do not edit.
760
+ */
761
+
762
+ export { CovalentFlavoredMarkdownModule, TdFlavoredMarkdownButtonComponent, TdFlavoredMarkdownComponent, TdFlavoredMarkdownContainerDirective, TdFlavoredMarkdownLoaderComponent, TdFlavoredMarkdownTableComponent };
763
+ //# sourceMappingURL=covalent-flavored-markdown.mjs.map