markdown-komponents 0.3.0 → 0.3.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.
@@ -72,6 +72,15 @@ class BaseWebComponent extends HTMLElement {
72
72
  attributeChangedCallback(name, oldValue, newValue) {
73
73
  return this.dc(name, oldValue, newValue);
74
74
  }
75
+ upgradeProperty(name) {
76
+ // Inline function 'kotlin.js.asDynamic' call
77
+ var self_0 = this;
78
+ if (hasOwnProperty(self_0, name)) {
79
+ var value = self_0[name];
80
+ deleteOwnProperty(self_0, name);
81
+ self_0[name] = value;
82
+ }
83
+ }
75
84
  }
76
85
  class BoldToolbarButton extends BaseWebComponent {
77
86
  constructor() {
@@ -166,71 +175,77 @@ class StashedSelection {
166
175
  class BaseMarkdownDocument extends BaseWebComponent {
167
176
  constructor() {
168
177
  super();
169
- var tmp = this;
170
- tmp.parser = BaseMarkdownDocument$parser$lambda;
171
- this.toolbar = null;
172
- this.selectionRoot = document;
173
- this.onLinkClick = null;
174
- this.autoNormalize = true;
178
+ this.kl_1 = null;
179
+ this.ll_1 = null;
180
+ this.ml_1 = document;
181
+ this.nl_1 = null;
182
+ this.ol_1 = true;
175
183
  this.currentSelection = null;
176
184
  this.editable = false;
177
- this.kl_1 = null;
178
- this.ll_1 = 0;
179
- this.ml_1 = null;
180
- this.nl_1 = false;
181
- var tmp_0 = this;
185
+ this.pl_1 = null;
186
+ this.ql_1 = 0;
187
+ this.rl_1 = null;
188
+ this.sl_1 = false;
189
+ var tmp = this;
182
190
  // Inline function 'kotlin.js.asDynamic' call
183
- tmp_0.ol_1 = window.chrome != null;
191
+ tmp.tl_1 = window.chrome != null;
192
+ var tmp_0 = this;
193
+ tmp_0.ul_1 = BaseMarkdownDocument$onMouseDown$lambda(this);
184
194
  var tmp_1 = this;
185
- tmp_1.pl_1 = BaseMarkdownDocument$onMouseDown$lambda(this);
195
+ tmp_1.vl_1 = BaseMarkdownDocument$onMouseUp$lambda(this);
186
196
  var tmp_2 = this;
187
- tmp_2.ql_1 = BaseMarkdownDocument$onMouseUp$lambda(this);
197
+ tmp_2.wl_1 = BaseMarkdownDocument$onSelectStart$lambda(this);
188
198
  var tmp_3 = this;
189
- tmp_3.rl_1 = BaseMarkdownDocument$onSelectStart$lambda(this);
190
- var tmp_4 = this;
191
- tmp_4.sl_1 = BaseMarkdownDocument$onSelectionChange$lambda(this);
192
- this.tl_1 = false;
193
- }
194
- dm(_set____db54di) {
195
- this.parser = _set____db54di;
196
- }
197
- em() {
198
- return this.parser;
199
- }
200
- fm(value) {
199
+ tmp_3.xl_1 = BaseMarkdownDocument$onSelectionChange$lambda(this);
200
+ this.upgradeProperty('parser');
201
+ this.upgradeProperty('markdown');
202
+ this.upgradeProperty('toolbar');
203
+ this.upgradeProperty('selectionRoot');
204
+ this.upgradeProperty('onLinkClick');
205
+ this.upgradeProperty('autoNormalize');
206
+ this.yl_1 = false;
207
+ }
208
+ im(value) {
209
+ this.kl_1 = value;
210
+ }
211
+ jm() {
212
+ var tmp0_elvis_lhs = this.kl_1;
213
+ return tmp0_elvis_lhs == null ? get_defaultParser() : tmp0_elvis_lhs;
214
+ }
215
+ km(value) {
201
216
  return renderMarkdown(this, value);
202
217
  }
203
- gm() {
218
+ lm() {
204
219
  return this.getMarkdown();
205
220
  }
206
- hm(_set____db54di) {
207
- this.toolbar = _set____db54di;
221
+ mm(value) {
222
+ this.ll_1 = value;
208
223
  }
209
- im() {
210
- return this.toolbar;
224
+ nm() {
225
+ return this.ll_1;
211
226
  }
212
- jm(_set____db54di) {
213
- this.selectionRoot = _set____db54di;
227
+ om(value) {
228
+ this.ml_1 = value;
214
229
  }
215
- km() {
216
- return this.selectionRoot;
230
+ pm() {
231
+ return this.ml_1;
217
232
  }
218
- lm(_set____db54di) {
219
- this.onLinkClick = _set____db54di;
233
+ qm(value) {
234
+ this.nl_1 = value;
220
235
  }
221
- mm() {
222
- return this.onLinkClick;
236
+ rm() {
237
+ return this.nl_1;
223
238
  }
224
- nm(_set____db54di) {
225
- this.autoNormalize = _set____db54di;
239
+ sm(value) {
240
+ this.ol_1 = value;
226
241
  }
227
- om() {
228
- return this.autoNormalize;
242
+ tm() {
243
+ return this.ol_1;
229
244
  }
230
- pm() {
245
+ um() {
231
246
  return this.currentSelection;
232
247
  }
233
- qm() {
248
+ vm() {
234
249
  return this.editable;
235
250
  }
236
251
  renderStandardShadow() {
@@ -247,18 +262,18 @@ class BaseMarkdownDocument extends BaseWebComponent {
247
262
  }
248
263
  ac() {
249
264
  super.ac();
250
- if (!this.tl_1) {
251
- this.tl_1 = true;
265
+ if (!this.yl_1) {
266
+ this.yl_1 = true;
252
267
  firstUpdated(this);
253
268
  }
254
269
  this.setAttribute('contenteditable', this.getAttribute('readonly') === 'true' ? 'false' : 'true');
255
270
  if (this.getAttribute('spellcheck') == null) {
256
271
  this.setAttribute('spellcheck', 'false');
257
272
  }
258
- this.addEventListener('mousedown', this.pl_1);
259
- this.addEventListener('mouseup', this.ql_1);
260
- document.addEventListener('selectstart', this.rl_1);
261
- document.addEventListener('selectionchange', this.sl_1);
273
+ this.addEventListener('mousedown', this.ul_1);
274
+ this.addEventListener('mouseup', this.vl_1);
275
+ document.addEventListener('selectstart', this.wl_1);
276
+ document.addEventListener('selectionchange', this.xl_1);
262
277
  this.addEventListener('keydown', BaseMarkdownDocument$connectedCallback$lambda(this));
263
278
  this.addEventListener('input', BaseMarkdownDocument$connectedCallback$lambda_0(this));
264
279
  this.addEventListener('blur', BaseMarkdownDocument$connectedCallback$lambda_1(this));
@@ -270,8 +285,8 @@ class BaseMarkdownDocument extends BaseWebComponent {
270
285
  return this.ac();
271
286
  }
272
287
  bc() {
273
- document.removeEventListener('selectionchange', this.sl_1);
274
- document.removeEventListener('selectstart', this.rl_1);
288
+ document.removeEventListener('selectionchange', this.xl_1);
289
+ document.removeEventListener('selectstart', this.wl_1);
275
290
  }
276
291
  disconnectedCallback() {
277
292
  return this.bc();
@@ -313,7 +328,7 @@ class BaseMarkdownDocument extends BaseWebComponent {
313
328
  tmp.setTimeout(BaseMarkdownDocument$onChange$lambda(this), 0);
314
329
  }
315
330
  setToolbar(newToolbar) {
316
- this.toolbar = newToolbar;
331
+ this.mm(newToolbar);
317
332
  var tmp0_safe_receiver = newToolbar instanceof MarkdownToolbar ? newToolbar : null;
318
333
  if (tmp0_safe_receiver == null)
319
334
  null;
@@ -336,7 +351,7 @@ class BaseMarkdownDocument extends BaseWebComponent {
336
351
  return null;
337
352
  }
338
353
  getLastLeafBlock() {
339
- var element = this.kl_1;
354
+ var element = this.pl_1;
340
355
  while (!(element == null) && !equals(element, document) && !equals(element, this)) {
341
356
  if (element instanceof LeafElement)
342
357
  return element;
@@ -579,7 +594,7 @@ class BaseMarkdownDocument extends BaseWebComponent {
579
594
  image.title = text;
580
595
  }
581
596
  if (!(url == null)) {
582
- image.vl(url);
597
+ image.am(url);
583
598
  }
584
599
  var tmp2_safe_receiver = this.currentSelection;
585
600
  var anchorOffset = tmp2_safe_receiver == null ? null : tmp2_safe_receiver.anchorOffset;
@@ -598,7 +613,7 @@ class BaseMarkdownDocument extends BaseWebComponent {
598
613
  }
599
614
  }
600
615
  restoreStashedSelection() {
601
- var tmp0_elvis_lhs = this.ml_1;
616
+ var tmp0_elvis_lhs = this.rl_1;
602
617
  var tmp;
603
618
  if (tmp0_elvis_lhs == null) {
604
619
  return Unit_instance;
@@ -638,7 +653,7 @@ class BaseMarkdownDocument extends BaseWebComponent {
638
653
  link.textContent = 'http://';
639
654
  }
640
655
  var tmp1_elvis_lhs = link.textContent;
641
- link.vl(tmp1_elvis_lhs == null ? '' : tmp1_elvis_lhs);
656
+ link.am(tmp1_elvis_lhs == null ? '' : tmp1_elvis_lhs);
642
657
  link.classList.add('fresh');
643
658
  }
644
659
  header1Element() {
@@ -706,11 +721,41 @@ class BaseMarkdownDocument extends BaseWebComponent {
706
721
  this.dispatchEvent(new CustomEvent('markdown-inserted', o));
707
722
  this.onChange();
708
723
  }
724
+ get parser() {
725
+ return this.jm();
726
+ }
727
+ set parser(value) {
728
+ this.im(value);
729
+ }
709
730
  get markdown() {
710
- return this.gm();
731
+ return this.lm();
711
732
  }
712
733
  set markdown(value) {
713
- this.fm(value);
734
+ this.km(value);
735
+ }
736
+ get toolbar() {
737
+ return this.nm();
738
+ }
739
+ set toolbar(value) {
740
+ this.mm(value);
741
+ }
742
+ get selectionRoot() {
743
+ return this.pm();
744
+ }
745
+ set selectionRoot(value) {
746
+ this.om(value);
747
+ }
748
+ get onLinkClick() {
749
+ return this.rm();
750
+ }
751
+ set onLinkClick(value) {
752
+ this.qm(value);
753
+ }
754
+ get autoNormalize() {
755
+ return this.tm();
756
+ }
757
+ set autoNormalize(value) {
758
+ this.sm(value);
714
759
  }
715
760
  }
716
761
  class MarkdownDocument extends BaseMarkdownDocument {
@@ -737,7 +782,7 @@ class MarkdownEditor extends BaseMarkdownDocument {
737
782
  class MarkdownToolbar extends BaseWebComponent {
738
783
  constructor() {
739
784
  super();
740
- this.markdownDocument = null;
785
+ this.zm_1 = null;
741
786
  // Inline function 'org.w3c.dom.OPEN' call
742
787
  // Inline function 'kotlin.js.asDynamic' call
743
788
  // Inline function 'kotlin.js.unsafeCast' call
@@ -749,7 +794,7 @@ class MarkdownToolbar extends BaseWebComponent {
749
794
  var toolbarRow = element(shadow, 'div', MarkdownToolbar$lambda);
750
795
  var dropdown = element(toolbarRow, 'toolbar-dropdown');
751
796
  var tmp = this;
752
- tmp.xm_1 = element(dropdown, 'span', MarkdownToolbar$lambda_0);
797
+ tmp.dn_1 = element(dropdown, 'span', MarkdownToolbar$lambda_0);
753
798
  dropdown.appendChild(document.createTextNode(' \u25BE'));
754
799
  var dropdownElements = element(dropdown, 'dropdown-elements', MarkdownToolbar$lambda_1);
755
800
  headingOption(this, dropdownElements, 1, MarkdownToolbar$lambda_2(this));
@@ -761,11 +806,11 @@ class MarkdownToolbar extends BaseWebComponent {
761
806
  paragraphOption(this, dropdownElements, MarkdownToolbar$lambda_8(this));
762
807
  element(toolbarRow, 'toolbar-separator');
763
808
  var tmp_0 = this;
764
- tmp_0.um_1 = toggleButton(this, toolbarRow, 'bold', 'toggle bold', MarkdownToolbar$lambda_9(this));
809
+ tmp_0.an_1 = toggleButton(this, toolbarRow, 'bold', 'toggle bold', MarkdownToolbar$lambda_9(this));
765
810
  var tmp_1 = this;
766
- tmp_1.vm_1 = toggleButton(this, toolbarRow, 'italic', 'toggle italic', MarkdownToolbar$lambda_10(this));
811
+ tmp_1.bn_1 = toggleButton(this, toolbarRow, 'italic', 'toggle italic', MarkdownToolbar$lambda_10(this));
767
812
  var tmp_2 = this;
768
- tmp_2.wm_1 = toggleButton(this, toolbarRow, 'strikethrough', 'toggle strike', MarkdownToolbar$lambda_11(this));
813
+ tmp_2.cn_1 = toggleButton(this, toolbarRow, 'strikethrough', 'toggle strike', MarkdownToolbar$lambda_11(this));
769
814
  element(toolbarRow, 'toolbar-separator');
770
815
  actionButton(this, toolbarRow, 'list-bulleted', 'list', MarkdownToolbar$lambda_12(this));
771
816
  actionButton(this, toolbarRow, 'list-numbered', 'numbered list', MarkdownToolbar$lambda_13(this));
@@ -779,12 +824,13 @@ class MarkdownToolbar extends BaseWebComponent {
779
824
  element(toolbarRow, 'toolbar-separator');
780
825
  element(toolbarRow, 'slot', MarkdownToolbar$lambda_20);
781
826
  slot(shadow);
827
+ this.upgradeProperty('markdownDocument');
782
828
  }
783
- an(_set____db54di) {
784
- this.markdownDocument = _set____db54di;
829
+ gn(value) {
830
+ this.zm_1 = value;
785
831
  }
786
- bn() {
787
- return this.markdownDocument;
832
+ hn() {
833
+ return this.zm_1;
788
834
  }
789
835
  ac() {
790
836
  super.ac();
@@ -794,28 +840,34 @@ class MarkdownToolbar extends BaseWebComponent {
794
840
  return this.ac();
795
841
  }
796
842
  setMarkdownDocument(document) {
797
- this.markdownDocument = document;
843
+ this.gn(document);
798
844
  }
799
845
  highlightBoldButton() {
800
- this.um_1.fl(true);
846
+ this.an_1.fl(true);
801
847
  }
802
848
  removeBoldButtonHighlighting() {
803
- this.um_1.fl(false);
849
+ this.an_1.fl(false);
804
850
  }
805
851
  highlightItalicButton() {
806
- this.vm_1.fl(true);
852
+ this.bn_1.fl(true);
807
853
  }
808
854
  removeItalicButtonHighlighting() {
809
- this.vm_1.fl(false);
855
+ this.bn_1.fl(false);
810
856
  }
811
857
  highlightStrikeButton() {
812
- this.wm_1.fl(true);
858
+ this.cn_1.fl(true);
813
859
  }
814
860
  removeStrikeButtonHighlighting() {
815
- this.wm_1.fl(false);
861
+ this.cn_1.fl(false);
816
862
  }
817
863
  setDropdownTitle(title) {
818
- this.xm_1.textContent = title;
864
+ this.dn_1.textContent = title;
865
+ }
866
+ get markdownDocument() {
867
+ return this.hn();
868
+ }
869
+ set markdownDocument(value) {
870
+ this.gn(value);
819
871
  }
820
872
  }
821
873
  class ToggleToolbarButton extends BaseWebComponent {
@@ -830,10 +882,10 @@ class ToggleToolbarButton extends BaseWebComponent {
830
882
  var shadow = this.attachShadow(o);
831
883
  var tmp = this;
832
884
  var tmp_0 = element(shadow, 'toolbar-button', ToggleToolbarButton$lambda);
833
- tmp.ym_1 = tmp_0 instanceof ToolbarButton ? tmp_0 : THROW_CCE();
885
+ tmp.en_1 = tmp_0 instanceof ToolbarButton ? tmp_0 : THROW_CCE();
834
886
  var tmp_1 = this;
835
- var tmp_2 = element(this.ym_1, 'toolbar-icon', ToggleToolbarButton$lambda_0);
836
- tmp_1.zm_1 = tmp_2 instanceof ToolbarIcon ? tmp_2 : THROW_CCE();
887
+ var tmp_2 = element(this.en_1, 'toolbar-icon', ToggleToolbarButton$lambda_0);
888
+ tmp_1.fn_1 = tmp_2 instanceof ToolbarIcon ? tmp_2 : THROW_CCE();
837
889
  }
838
890
  fl(value) {
839
891
  var tmp;
@@ -851,9 +903,9 @@ class ToggleToolbarButton extends BaseWebComponent {
851
903
  }
852
904
  dc(name, oldValue, newValue) {
853
905
  if (name === 'highlighted') {
854
- this.ym_1.fl(this.dl());
906
+ this.en_1.fl(this.dl());
855
907
  } else if (name === 'icon') {
856
- this.zm_1.dn(newValue == null ? '' : newValue);
908
+ this.fn_1.jn(newValue == null ? '' : newValue);
857
909
  }
858
910
  }
859
911
  attributeChangedCallback(name, oldValue, newValue) {
@@ -902,7 +954,7 @@ class ToolbarDropdown extends BaseWebComponent {
902
954
  constructor() {
903
955
  super();
904
956
  var tmp = this;
905
- tmp.fn_1 = ToolbarDropdown$hideOnOutsideMouseDown$lambda(this);
957
+ tmp.ln_1 = ToolbarDropdown$hideOnOutsideMouseDown$lambda(this);
906
958
  // Inline function 'org.w3c.dom.OPEN' call
907
959
  // Inline function 'kotlin.js.asDynamic' call
908
960
  // Inline function 'kotlin.js.unsafeCast' call
@@ -914,17 +966,17 @@ class ToolbarDropdown extends BaseWebComponent {
914
966
  var button = element(shadow, 'toolbar-button', ToolbarDropdown$lambda);
915
967
  button.addEventListener('mousedown', ToolbarDropdown$lambda_0(this));
916
968
  var tmp_0 = this;
917
- tmp_0.en_1 = element(shadow, 'slot', ToolbarDropdown$lambda_1);
969
+ tmp_0.kn_1 = element(shadow, 'slot', ToolbarDropdown$lambda_1);
918
970
  }
919
971
  ac() {
920
972
  super.ac();
921
- document.addEventListener('mousedown', this.fn_1);
973
+ document.addEventListener('mousedown', this.ln_1);
922
974
  }
923
975
  connectedCallback() {
924
976
  return this.ac();
925
977
  }
926
978
  bc() {
927
- document.removeEventListener('mousedown', this.fn_1);
979
+ document.removeEventListener('mousedown', this.ln_1);
928
980
  }
929
981
  disconnectedCallback() {
930
982
  return this.bc();
@@ -941,14 +993,14 @@ class ToolbarIcon extends BaseWebComponent {
941
993
  o['mode'] = 'open';
942
994
  var shadow = this.attachShadow(o);
943
995
  style(shadow, ':host {\n display: inline-flex;\n width: 24px;\n height: 24px;\n align-items: center;\n justify-content: center;\n color: inherit;\n}\nspan, svg {\n display: block;\n width: 100%;\n height: 100%;\n}');
944
- this.cn_1 = element(shadow, 'span');
996
+ this.in_1 = element(shadow, 'span');
945
997
  }
946
- dn(value) {
998
+ jn(value) {
947
999
  return this.setAttribute('icon', value);
948
1000
  }
949
1001
  dc(name, oldValue, newValue) {
950
1002
  if (name === 'icon') {
951
- this.cn_1.innerHTML = svgFor(this, newValue == null ? '' : newValue);
1003
+ this.in_1.innerHTML = svgFor(this, newValue == null ? '' : newValue);
952
1004
  }
953
1005
  }
954
1006
  attributeChangedCallback(name, oldValue, newValue) {
@@ -1222,12 +1274,12 @@ class MarkdownComponent extends BaseWebComponent {
1222
1274
  return joinToString(tmp, '', VOID, VOID, VOID, VOID, MarkdownComponent$getMarkdown$lambda);
1223
1275
  }
1224
1276
  get mustBeDirectChildOfDocument() {
1225
- return this.gn();
1277
+ return this.mn();
1226
1278
  }
1227
1279
  }
1228
1280
  class BlockElement extends MarkdownComponent {
1229
1281
  get mustBeDirectChildOfDocument() {
1230
- return this.gn();
1282
+ return this.mn();
1231
1283
  }
1232
1284
  }
1233
1285
  class ContainerElement extends MarkdownComponent {
@@ -1261,7 +1313,7 @@ class ContainerElement extends MarkdownComponent {
1261
1313
  return this.children.length > 0;
1262
1314
  }
1263
1315
  get mustBeDirectChildOfDocument() {
1264
- return this.gn();
1316
+ return this.mn();
1265
1317
  }
1266
1318
  }
1267
1319
  class LeafElement extends BlockElement {
@@ -1373,16 +1425,16 @@ class LeafElement extends BlockElement {
1373
1425
  return tmp;
1374
1426
  }
1375
1427
  get mustBeDirectChildOfDocument() {
1376
- return this.gn();
1428
+ return this.mn();
1377
1429
  }
1378
1430
  }
1379
1431
  class Heading extends LeafElement {
1380
1432
  constructor() {
1381
1433
  super();
1382
- this.hn_1 = true;
1434
+ this.nn_1 = true;
1383
1435
  }
1384
- gn() {
1385
- return this.hn_1;
1436
+ mn() {
1437
+ return this.nn_1;
1386
1438
  }
1387
1439
  getMarkdown() {
1388
1440
  return repeat('#', this.depth) + ' ' + getMarkdownWithTextForElement(this) + '\n';
@@ -1407,19 +1459,19 @@ class Heading extends LeafElement {
1407
1459
  element(this_0, tmp, Heading$renderHeading$lambda);
1408
1460
  }
1409
1461
  get depth() {
1410
- return this.in();
1462
+ return this.on();
1411
1463
  }
1412
1464
  get mustBeDirectChildOfDocument() {
1413
- return this.gn();
1465
+ return this.mn();
1414
1466
  }
1415
1467
  }
1416
1468
  class InlineElement extends MarkdownComponent {
1417
1469
  constructor() {
1418
1470
  super();
1419
- this.jn_1 = false;
1471
+ this.pn_1 = false;
1420
1472
  }
1421
- gn() {
1422
- return this.jn_1;
1473
+ mn() {
1474
+ return this.pn_1;
1423
1475
  }
1424
1476
  normalizeContent() {
1425
1477
  var next = this.nextSibling;
@@ -1495,23 +1547,23 @@ class InlineElement extends MarkdownComponent {
1495
1547
  }
1496
1548
  }
1497
1549
  get mustBeDirectChildOfDocument() {
1498
- return this.gn();
1550
+ return this.mn();
1499
1551
  }
1500
1552
  }
1501
1553
  class TerminalInlineElement extends MarkdownComponent {
1502
1554
  get mustBeDirectChildOfDocument() {
1503
- return this.gn();
1555
+ return this.mn();
1504
1556
  }
1505
1557
  }
1506
1558
  class ListItem extends ContainerElement {
1507
1559
  constructor() {
1508
1560
  super();
1509
- this.kn_1 = false;
1561
+ this.qn_1 = false;
1510
1562
  }
1511
- gn() {
1512
- return this.kn_1;
1563
+ mn() {
1564
+ return this.qn_1;
1513
1565
  }
1514
- ln() {
1566
+ rn() {
1515
1567
  var depth = 0;
1516
1568
  var ancestor = this.parentNode;
1517
1569
  $l$loop: while (true) {
@@ -1544,12 +1596,12 @@ class ListItem extends ContainerElement {
1544
1596
  return depth;
1545
1597
  }
1546
1598
  getMarkdown() {
1547
- return repeat(' ', this.ln()) + '- ' + this.mn() + this.nn();
1599
+ return repeat(' ', this.rn()) + '- ' + this.sn() + this.tn();
1548
1600
  }
1549
- mn() {
1601
+ sn() {
1550
1602
  return '';
1551
1603
  }
1552
- nn() {
1604
+ tn() {
1553
1605
  var tmp = asList(this.childNodes);
1554
1606
  return joinToString(tmp, '', VOID, VOID, VOID, VOID, ListItem$getMarkdownWithTextForElement$lambda);
1555
1607
  }
@@ -1712,7 +1764,7 @@ class ListItem extends ContainerElement {
1712
1764
  return true;
1713
1765
  }
1714
1766
  get mustBeDirectChildOfDocument() {
1715
- return this.gn();
1767
+ return this.mn();
1716
1768
  }
1717
1769
  }
1718
1770
  class MarkdownElementWithLevel {}
@@ -1720,12 +1772,12 @@ class MarkdownElementEscapeByBackspace {}
1720
1772
  class TableCell extends ContainerElement {
1721
1773
  constructor() {
1722
1774
  super();
1723
- this.on_1 = false;
1775
+ this.un_1 = false;
1724
1776
  }
1725
- gn() {
1726
- return this.on_1;
1777
+ mn() {
1778
+ return this.un_1;
1727
1779
  }
1728
- pn(hostCss) {
1780
+ vn(hostCss) {
1729
1781
  // Inline function 'org.w3c.dom.OPEN' call
1730
1782
  // Inline function 'kotlin.js.asDynamic' call
1731
1783
  // Inline function 'kotlin.js.unsafeCast' call
@@ -1745,13 +1797,13 @@ class TableCell extends ContainerElement {
1745
1797
  return true;
1746
1798
  }
1747
1799
  get mustBeDirectChildOfDocument() {
1748
- return this.gn();
1800
+ return this.mn();
1749
1801
  }
1750
1802
  }
1751
1803
  class MarkdownBreak extends LeafElement {
1752
1804
  constructor() {
1753
1805
  super();
1754
- this.qn_1 = true;
1806
+ this.wn_1 = true;
1755
1807
  // Inline function 'org.w3c.dom.OPEN' call
1756
1808
  // Inline function 'kotlin.js.asDynamic' call
1757
1809
  // Inline function 'kotlin.js.unsafeCast' call
@@ -1760,8 +1812,8 @@ class MarkdownBreak extends LeafElement {
1760
1812
  o['mode'] = 'open';
1761
1813
  element(this.attachShadow(o), 'hr');
1762
1814
  }
1763
- gn() {
1764
- return this.qn_1;
1815
+ mn() {
1816
+ return this.wn_1;
1765
1817
  }
1766
1818
  getMarkdown() {
1767
1819
  return '-----------------------\n';
@@ -1773,13 +1825,13 @@ class MarkdownBreak extends LeafElement {
1773
1825
  return true;
1774
1826
  }
1775
1827
  get mustBeDirectChildOfDocument() {
1776
- return this.gn();
1828
+ return this.mn();
1777
1829
  }
1778
1830
  }
1779
1831
  class MarkdownCode extends LeafElement {
1780
1832
  constructor() {
1781
1833
  super();
1782
- this.rn_1 = true;
1834
+ this.xn_1 = true;
1783
1835
  // Inline function 'org.w3c.dom.OPEN' call
1784
1836
  // Inline function 'kotlin.js.asDynamic' call
1785
1837
  // Inline function 'kotlin.js.unsafeCast' call
@@ -1789,8 +1841,8 @@ class MarkdownCode extends LeafElement {
1789
1841
  var tmp = element(this.attachShadow(o), 'pre');
1790
1842
  element(tmp, 'code', MarkdownCode$lambda);
1791
1843
  }
1792
- gn() {
1793
- return this.rn_1;
1844
+ mn() {
1845
+ return this.xn_1;
1794
1846
  }
1795
1847
  getMarkdown() {
1796
1848
  var lang = this.getAttribute('lang');
@@ -1809,13 +1861,13 @@ class MarkdownCode extends LeafElement {
1809
1861
  return true;
1810
1862
  }
1811
1863
  get mustBeDirectChildOfDocument() {
1812
- return this.gn();
1864
+ return this.mn();
1813
1865
  }
1814
1866
  }
1815
1867
  class MarkdownCodeSpan extends TerminalInlineElement {
1816
1868
  constructor() {
1817
1869
  super();
1818
- this.sn_1 = false;
1870
+ this.yn_1 = false;
1819
1871
  // Inline function 'org.w3c.dom.OPEN' call
1820
1872
  // Inline function 'kotlin.js.asDynamic' call
1821
1873
  // Inline function 'kotlin.js.unsafeCast' call
@@ -1825,8 +1877,8 @@ class MarkdownCodeSpan extends TerminalInlineElement {
1825
1877
  var tmp = this.attachShadow(o);
1826
1878
  element(tmp, 'code', MarkdownCodeSpan$lambda);
1827
1879
  }
1828
- gn() {
1829
- return this.sn_1;
1880
+ mn() {
1881
+ return this.yn_1;
1830
1882
  }
1831
1883
  getMarkdown() {
1832
1884
  return '`' + getMarkdownWithTextForElement(this) + '`';
@@ -1835,7 +1887,7 @@ class MarkdownCodeSpan extends TerminalInlineElement {
1835
1887
  return true;
1836
1888
  }
1837
1889
  get mustBeDirectChildOfDocument() {
1838
- return this.gn();
1890
+ return this.mn();
1839
1891
  }
1840
1892
  }
1841
1893
  class MarkdownEmphasis extends InlineElement {
@@ -1862,67 +1914,67 @@ class MarkdownEmphasis extends InlineElement {
1862
1914
  class MarkdownHeading1 extends Heading {
1863
1915
  constructor() {
1864
1916
  super();
1865
- this.un_1 = 1;
1917
+ this.ao_1 = 1;
1866
1918
  this.renderHeading();
1867
1919
  }
1868
- in() {
1869
- return this.un_1;
1920
+ on() {
1921
+ return this.ao_1;
1870
1922
  }
1871
1923
  }
1872
1924
  class MarkdownHeading2 extends Heading {
1873
1925
  constructor() {
1874
1926
  super();
1875
- this.wn_1 = 2;
1927
+ this.co_1 = 2;
1876
1928
  this.renderHeading();
1877
1929
  }
1878
- in() {
1879
- return this.wn_1;
1930
+ on() {
1931
+ return this.co_1;
1880
1932
  }
1881
1933
  }
1882
1934
  class MarkdownHeading3 extends Heading {
1883
1935
  constructor() {
1884
1936
  super();
1885
- this.yn_1 = 3;
1937
+ this.eo_1 = 3;
1886
1938
  this.renderHeading();
1887
1939
  }
1888
- in() {
1889
- return this.yn_1;
1940
+ on() {
1941
+ return this.eo_1;
1890
1942
  }
1891
1943
  }
1892
1944
  class MarkdownHeading4 extends Heading {
1893
1945
  constructor() {
1894
1946
  super();
1895
- this.ao_1 = 4;
1947
+ this.go_1 = 4;
1896
1948
  this.renderHeading();
1897
1949
  }
1898
- in() {
1899
- return this.ao_1;
1950
+ on() {
1951
+ return this.go_1;
1900
1952
  }
1901
1953
  }
1902
1954
  class MarkdownHeading5 extends Heading {
1903
1955
  constructor() {
1904
1956
  super();
1905
- this.co_1 = 5;
1957
+ this.io_1 = 5;
1906
1958
  this.renderHeading();
1907
1959
  }
1908
- in() {
1909
- return this.co_1;
1960
+ on() {
1961
+ return this.io_1;
1910
1962
  }
1911
1963
  }
1912
1964
  class MarkdownHeading6 extends Heading {
1913
1965
  constructor() {
1914
1966
  super();
1915
- this.eo_1 = 6;
1967
+ this.ko_1 = 6;
1916
1968
  this.renderHeading();
1917
1969
  }
1918
- in() {
1919
- return this.eo_1;
1970
+ on() {
1971
+ return this.ko_1;
1920
1972
  }
1921
1973
  }
1922
1974
  class MarkdownHtml extends LeafElement {
1923
1975
  constructor() {
1924
1976
  super();
1925
- this.fo_1 = false;
1977
+ this.lo_1 = false;
1926
1978
  // Inline function 'org.w3c.dom.OPEN' call
1927
1979
  // Inline function 'kotlin.js.asDynamic' call
1928
1980
  // Inline function 'kotlin.js.unsafeCast' call
@@ -1931,8 +1983,8 @@ class MarkdownHtml extends LeafElement {
1931
1983
  o['mode'] = 'open';
1932
1984
  slot(this.attachShadow(o));
1933
1985
  }
1934
- gn() {
1935
- return this.fo_1;
1986
+ mn() {
1987
+ return this.lo_1;
1936
1988
  }
1937
1989
  isEditable() {
1938
1990
  return false;
@@ -1946,13 +1998,13 @@ class MarkdownHtml extends LeafElement {
1946
1998
  return true;
1947
1999
  }
1948
2000
  get mustBeDirectChildOfDocument() {
1949
- return this.gn();
2001
+ return this.mn();
1950
2002
  }
1951
2003
  }
1952
2004
  class MarkdownImage extends TerminalInlineElement {
1953
2005
  constructor() {
1954
2006
  super();
1955
- this.ul_1 = false;
2007
+ this.zl_1 = false;
1956
2008
  // Inline function 'org.w3c.dom.OPEN' call
1957
2009
  // Inline function 'kotlin.js.asDynamic' call
1958
2010
  // Inline function 'kotlin.js.unsafeCast' call
@@ -1970,20 +2022,21 @@ class MarkdownImage extends TerminalInlineElement {
1970
2022
  tmp_1.img = tmp_2 instanceof HTMLImageElement ? tmp_2 : THROW_CCE();
1971
2023
  this.img.addEventListener('error', MarkdownImage$lambda_2(this));
1972
2024
  element(shadow, 'slot', MarkdownImage$lambda_3);
2025
+ this.upgradeProperty('destination');
1973
2026
  }
1974
- gn() {
1975
- return this.ul_1;
2027
+ mn() {
2028
+ return this.zl_1;
1976
2029
  }
1977
- go() {
2030
+ mo() {
1978
2031
  return this.img;
1979
2032
  }
1980
- ho() {
2033
+ no() {
1981
2034
  return this.uploadInput;
1982
2035
  }
1983
- vl(value) {
2036
+ am(value) {
1984
2037
  return this.setAttribute('destination', value);
1985
2038
  }
1986
- io() {
2039
+ oo() {
1987
2040
  var tmp0_elvis_lhs = this.getAttribute('destination');
1988
2041
  return tmp0_elvis_lhs == null ? '' : tmp0_elvis_lhs;
1989
2042
  }
@@ -2020,19 +2073,19 @@ class MarkdownImage extends TerminalInlineElement {
2020
2073
  return true;
2021
2074
  }
2022
2075
  get mustBeDirectChildOfDocument() {
2023
- return this.gn();
2076
+ return this.mn();
2024
2077
  }
2025
2078
  get destination() {
2026
- return this.io();
2079
+ return this.oo();
2027
2080
  }
2028
2081
  set destination(value) {
2029
- this.vl(value);
2082
+ this.am(value);
2030
2083
  }
2031
2084
  }
2032
2085
  class MarkdownLink extends TerminalInlineElement {
2033
2086
  constructor() {
2034
2087
  super();
2035
- this.rm_1 = false;
2088
+ this.wm_1 = false;
2036
2089
  // Inline function 'org.w3c.dom.OPEN' call
2037
2090
  // Inline function 'kotlin.js.asDynamic' call
2038
2091
  // Inline function 'kotlin.js.unsafeCast' call
@@ -2046,23 +2099,23 @@ class MarkdownLink extends TerminalInlineElement {
2046
2099
  // Inline function 'kotlin.also' call
2047
2100
  var this_0 = tmp_0 instanceof HTMLAnchorElement ? tmp_0 : THROW_CCE();
2048
2101
  slot(this_0);
2049
- tmp.sm_1 = this_0;
2102
+ tmp.xm_1 = this_0;
2050
2103
  var showLink = element(shadow, 'span', MarkdownLink$lambda_0);
2051
2104
  showLink.addEventListener('click', MarkdownLink$lambda_1(this));
2052
2105
  var tmp_1 = this;
2053
2106
  var tmp_2 = element(shadow, 'input', MarkdownLink$lambda_2);
2054
- tmp_1.tm_1 = tmp_2 instanceof HTMLInputElement ? tmp_2 : THROW_CCE();
2055
- this.tm_1.addEventListener('input', MarkdownLink$lambda_3(this));
2056
- this.tm_1.addEventListener('blur', MarkdownLink$lambda_4(this));
2057
- this.tm_1.addEventListener('keydown', MarkdownLink$lambda_5(this));
2107
+ tmp_1.ym_1 = tmp_2 instanceof HTMLInputElement ? tmp_2 : THROW_CCE();
2108
+ this.ym_1.addEventListener('input', MarkdownLink$lambda_3(this));
2109
+ this.ym_1.addEventListener('blur', MarkdownLink$lambda_4(this));
2110
+ this.ym_1.addEventListener('keydown', MarkdownLink$lambda_5(this));
2058
2111
  }
2059
- gn() {
2060
- return this.rm_1;
2112
+ mn() {
2113
+ return this.wm_1;
2061
2114
  }
2062
- vl(value) {
2115
+ am(value) {
2063
2116
  return this.setAttribute('destination', value);
2064
2117
  }
2065
- io() {
2118
+ oo() {
2066
2119
  var tmp0_elvis_lhs = this.getAttribute('destination');
2067
2120
  return tmp0_elvis_lhs == null ? '' : tmp0_elvis_lhs;
2068
2121
  }
@@ -2091,9 +2144,9 @@ class MarkdownLink extends TerminalInlineElement {
2091
2144
  // Inline function 'kotlin.text.isNotEmpty' call
2092
2145
  var this_0 = this.title;
2093
2146
  if (charSequenceLength(this_0) > 0) {
2094
- tmp = '[' + this.innerText + '](' + this.io() + ' "' + this.title + '")';
2147
+ tmp = '[' + this.innerText + '](' + this.oo() + ' "' + this.title + '")';
2095
2148
  } else {
2096
- tmp = '[' + this.innerText + '](' + this.io() + ')';
2149
+ tmp = '[' + this.innerText + '](' + this.oo() + ')';
2097
2150
  }
2098
2151
  return tmp;
2099
2152
  }
@@ -2101,13 +2154,13 @@ class MarkdownLink extends TerminalInlineElement {
2101
2154
  return true;
2102
2155
  }
2103
2156
  get mustBeDirectChildOfDocument() {
2104
- return this.gn();
2157
+ return this.mn();
2105
2158
  }
2106
2159
  }
2107
2160
  class MarkdownList extends ContainerElement {
2108
2161
  constructor() {
2109
2162
  super();
2110
- this.jo_1 = false;
2163
+ this.po_1 = false;
2111
2164
  // Inline function 'org.w3c.dom.OPEN' call
2112
2165
  // Inline function 'kotlin.js.asDynamic' call
2113
2166
  // Inline function 'kotlin.js.unsafeCast' call
@@ -2119,8 +2172,8 @@ class MarkdownList extends ContainerElement {
2119
2172
  style(this_0, ":host {\n counter-reset: section;\n}\n:host ::slotted(*) {\n display: list-item;\n}\n:host([ordered='true']) ::slotted(*) {\n list-style-type: decimal;\n}");
2120
2173
  slot(this_0);
2121
2174
  }
2122
- gn() {
2123
- return this.jo_1;
2175
+ mn() {
2176
+ return this.po_1;
2124
2177
  }
2125
2178
  getMarkdown() {
2126
2179
  return super.getMarkdown() + '\n';
@@ -2128,7 +2181,7 @@ class MarkdownList extends ContainerElement {
2128
2181
  containsMarkdownTextContent() {
2129
2182
  return false;
2130
2183
  }
2131
- bm(child) {
2184
+ gm(child) {
2132
2185
  if (child == null)
2133
2186
  return Unit_instance;
2134
2187
  var list = document.createElement('markdown-list');
@@ -2138,7 +2191,7 @@ class MarkdownList extends ContainerElement {
2138
2191
  child.innerHTML = '&nbsp';
2139
2192
  child.appendChild(list);
2140
2193
  }
2141
- cm(child) {
2194
+ hm(child) {
2142
2195
  if (child == null)
2143
2196
  return Unit_instance;
2144
2197
  var tmp0_safe_receiver = this.parentElement;
@@ -2160,7 +2213,7 @@ class MarkdownList extends ContainerElement {
2160
2213
  }
2161
2214
  }
2162
2215
  get mustBeDirectChildOfDocument() {
2163
- return this.gn();
2216
+ return this.mn();
2164
2217
  }
2165
2218
  }
2166
2219
  class MarkdownListItem extends ListItem {
@@ -2181,7 +2234,7 @@ class MarkdownListItem extends ListItem {
2181
2234
  class MarkdownNumericList extends ContainerElement {
2182
2235
  constructor() {
2183
2236
  super();
2184
- this.ko_1 = false;
2237
+ this.qo_1 = false;
2185
2238
  // Inline function 'org.w3c.dom.OPEN' call
2186
2239
  // Inline function 'kotlin.js.asDynamic' call
2187
2240
  // Inline function 'kotlin.js.unsafeCast' call
@@ -2193,8 +2246,8 @@ class MarkdownNumericList extends ContainerElement {
2193
2246
  style(this_0, ":host {\n /* fallback for browsers without ::marker { content } support */\n list-style-type: decimal;\n /* a real <ol> gets a fresh counter scope per nesting level for free (it's baked\n into the UA stylesheet); a custom element doesn't, so this does it explicitly \u2014\n without it, nested lists just continue the outer count instead of showing 1.1 */\n counter-reset: numbered-item;\n}");
2194
2247
  slot(this_0);
2195
2248
  }
2196
- gn() {
2197
- return this.ko_1;
2249
+ mn() {
2250
+ return this.qo_1;
2198
2251
  }
2199
2252
  getMarkdown() {
2200
2253
  return super.getMarkdown() + '\n';
@@ -2202,7 +2255,7 @@ class MarkdownNumericList extends ContainerElement {
2202
2255
  containsMarkdownTextContent() {
2203
2256
  return false;
2204
2257
  }
2205
- bm(child) {
2258
+ gm(child) {
2206
2259
  if (child == null)
2207
2260
  return Unit_instance;
2208
2261
  var list = document.createElement('markdown-numeric-list');
@@ -2212,7 +2265,7 @@ class MarkdownNumericList extends ContainerElement {
2212
2265
  child.innerHTML = '&nbsp';
2213
2266
  child.appendChild(list);
2214
2267
  }
2215
- cm(child) {
2268
+ hm(child) {
2216
2269
  if (child == null)
2217
2270
  return Unit_instance;
2218
2271
  var tmp0_safe_receiver = this.parentElement;
@@ -2234,7 +2287,7 @@ class MarkdownNumericList extends ContainerElement {
2234
2287
  }
2235
2288
  }
2236
2289
  get mustBeDirectChildOfDocument() {
2237
- return this.gn();
2290
+ return this.mn();
2238
2291
  }
2239
2292
  }
2240
2293
  class MarkdownNumericListItem extends ListItem {
@@ -2255,7 +2308,7 @@ class MarkdownNumericListItem extends ListItem {
2255
2308
  class MarkdownParagraph extends LeafElement {
2256
2309
  constructor() {
2257
2310
  super();
2258
- this.lo_1 = true;
2311
+ this.ro_1 = true;
2259
2312
  // Inline function 'org.w3c.dom.OPEN' call
2260
2313
  // Inline function 'kotlin.js.asDynamic' call
2261
2314
  // Inline function 'kotlin.js.unsafeCast' call
@@ -2267,8 +2320,8 @@ class MarkdownParagraph extends LeafElement {
2267
2320
  style(this_0, ':host {\n position: relative;\n display: block;\n margin-block-start: 1em;\n margin-block-end: 1em;\n margin-inline-start: 0px;\n margin-inline-end: 0px;\n}');
2268
2321
  slot(this_0);
2269
2322
  }
2270
- gn() {
2271
- return this.lo_1;
2323
+ mn() {
2324
+ return this.ro_1;
2272
2325
  }
2273
2326
  getMarkdown() {
2274
2327
  var tmp = asList(this.childNodes);
@@ -2293,13 +2346,13 @@ class MarkdownParagraph extends LeafElement {
2293
2346
  return this.getMarkdown() === '\n\n';
2294
2347
  }
2295
2348
  get mustBeDirectChildOfDocument() {
2296
- return this.gn();
2349
+ return this.mn();
2297
2350
  }
2298
2351
  }
2299
2352
  class MarkdownQuote extends ContainerElement {
2300
2353
  constructor() {
2301
2354
  super();
2302
- this.mo_1 = true;
2355
+ this.so_1 = true;
2303
2356
  // Inline function 'org.w3c.dom.OPEN' call
2304
2357
  // Inline function 'kotlin.js.asDynamic' call
2305
2358
  // Inline function 'kotlin.js.unsafeCast' call
@@ -2311,8 +2364,8 @@ class MarkdownQuote extends ContainerElement {
2311
2364
  style(this_0, ":host {\n position: relative;\n}\nblockquote::before {\n position: absolute;\n width: 3px;\n height: 100%;\n left: 20px;\n background-color: lightgray;\n content: '';\n}");
2312
2365
  element(this_0, 'blockquote', MarkdownQuote$lambda);
2313
2366
  }
2314
- gn() {
2315
- return this.mo_1;
2367
+ mn() {
2368
+ return this.so_1;
2316
2369
  }
2317
2370
  getMarkdown() {
2318
2371
  var tmp = asList(this.childNodes);
@@ -2330,14 +2383,14 @@ class MarkdownQuote extends ContainerElement {
2330
2383
  this.before(tmp0_safe_receiver);
2331
2384
  }
2332
2385
  }
2333
- bm(child) {
2386
+ gm(child) {
2334
2387
  if (!(child == null)) {
2335
2388
  var quote = document.createElement('markdown-quote');
2336
2389
  child.replaceWith(quote);
2337
2390
  quote.append(child);
2338
2391
  }
2339
2392
  }
2340
- cm(child) {
2393
+ hm(child) {
2341
2394
  if (!(child == null) && this.childNodes.length > 1) {
2342
2395
  var nodes = asList(this.childNodes);
2343
2396
  var indexOfChild = nodes.n1(child);
@@ -2369,11 +2422,11 @@ class MarkdownQuote extends ContainerElement {
2369
2422
  this.remove();
2370
2423
  }
2371
2424
  }
2372
- am(child) {
2373
- this.cm(child);
2425
+ fm(child) {
2426
+ this.hm(child);
2374
2427
  }
2375
2428
  get mustBeDirectChildOfDocument() {
2376
- return this.gn();
2429
+ return this.mn();
2377
2430
  }
2378
2431
  }
2379
2432
  class MarkdownStrike extends InlineElement {
@@ -2426,7 +2479,7 @@ class MarkdownStrong extends InlineElement {
2426
2479
  class MarkdownTable extends ContainerElement {
2427
2480
  constructor() {
2428
2481
  super();
2429
- this.no_1 = true;
2482
+ this.to_1 = true;
2430
2483
  // Inline function 'org.w3c.dom.OPEN' call
2431
2484
  // Inline function 'kotlin.js.asDynamic' call
2432
2485
  // Inline function 'kotlin.js.unsafeCast' call
@@ -2438,8 +2491,8 @@ class MarkdownTable extends ContainerElement {
2438
2491
  style(this_0, ':host {\n display: table;\n border-collapse: collapse;\n}');
2439
2492
  slot(this_0);
2440
2493
  }
2441
- gn() {
2442
- return this.no_1;
2494
+ mn() {
2495
+ return this.to_1;
2443
2496
  }
2444
2497
  getMarkdown() {
2445
2498
  var tmp = asList(this.children);
@@ -2449,25 +2502,25 @@ class MarkdownTable extends ContainerElement {
2449
2502
  return false;
2450
2503
  }
2451
2504
  get mustBeDirectChildOfDocument() {
2452
- return this.gn();
2505
+ return this.mn();
2453
2506
  }
2454
2507
  }
2455
2508
  class MarkdownTableCell extends TableCell {
2456
2509
  constructor() {
2457
2510
  super();
2458
- this.pn('display: table-cell; border: lightgrey 1px solid;');
2511
+ this.vn('display: table-cell; border: lightgrey 1px solid;');
2459
2512
  }
2460
2513
  }
2461
2514
  class MarkdownTableHeaderCell extends TableCell {
2462
2515
  constructor() {
2463
2516
  super();
2464
- this.pn('display: table-cell; border: lightgrey 1px solid; background-color: lightgray;');
2517
+ this.vn('display: table-cell; border: lightgrey 1px solid; background-color: lightgray;');
2465
2518
  }
2466
2519
  }
2467
2520
  class MarkdownTableRow extends ContainerElement {
2468
2521
  constructor() {
2469
2522
  super();
2470
- this.oo_1 = false;
2523
+ this.uo_1 = false;
2471
2524
  // Inline function 'org.w3c.dom.OPEN' call
2472
2525
  // Inline function 'kotlin.js.asDynamic' call
2473
2526
  // Inline function 'kotlin.js.unsafeCast' call
@@ -2479,8 +2532,8 @@ class MarkdownTableRow extends ContainerElement {
2479
2532
  style(this_0, ':host {\n display: table-row;\n border: lightgrey 1px solid;\n}');
2480
2533
  slot(this_0);
2481
2534
  }
2482
- gn() {
2483
- return this.oo_1;
2535
+ mn() {
2536
+ return this.uo_1;
2484
2537
  }
2485
2538
  getMarkdown() {
2486
2539
  var tmp = asList(this.children);
@@ -2490,7 +2543,7 @@ class MarkdownTableRow extends ContainerElement {
2490
2543
  return false;
2491
2544
  }
2492
2545
  get mustBeDirectChildOfDocument() {
2493
- return this.gn();
2546
+ return this.mn();
2494
2547
  }
2495
2548
  }
2496
2549
  class MarkdownTableHeaderRow extends MarkdownTableRow {
@@ -2512,31 +2565,31 @@ class MarkdownTaskListItem extends ListItem {
2512
2565
  var container = element(shadow, 'div', MarkdownTaskListItem$lambda);
2513
2566
  var tmp = this;
2514
2567
  var tmp_0 = element(container, 'input', MarkdownTaskListItem$lambda_0);
2515
- tmp.qo_1 = tmp_0 instanceof HTMLInputElement ? tmp_0 : THROW_CCE();
2516
- this.qo_1.addEventListener('change', MarkdownTaskListItem$lambda_1(this));
2568
+ tmp.wo_1 = tmp_0 instanceof HTMLInputElement ? tmp_0 : THROW_CCE();
2569
+ this.wo_1.addEventListener('change', MarkdownTaskListItem$lambda_1(this));
2517
2570
  element(container, 'div', MarkdownTaskListItem$lambda_2);
2518
2571
  }
2519
- ro() {
2572
+ xo() {
2520
2573
  return this.getAttribute('checked') === 'true';
2521
2574
  }
2522
2575
  dc(name, oldValue, newValue) {
2523
2576
  if (name === 'checked') {
2524
- this.qo_1.checked = this.ro();
2577
+ this.wo_1.checked = this.xo();
2525
2578
  }
2526
2579
  }
2527
2580
  attributeChangedCallback(name, oldValue, newValue) {
2528
2581
  return this.dc(name, oldValue, newValue);
2529
2582
  }
2530
- mn() {
2531
- return '[' + (this.ro() ? 'x' : ' ') + '] ';
2583
+ sn() {
2584
+ return '[' + (this.xo() ? 'x' : ' ') + '] ';
2532
2585
  }
2533
2586
  }
2534
2587
  class MarkdownToc extends BaseWebComponent {
2535
2588
  constructor() {
2536
2589
  super();
2537
- this.wl_1 = false;
2538
- this.xl_1 = null;
2539
- this.yl_1 = null;
2590
+ this.bm_1 = false;
2591
+ this.cm_1 = null;
2592
+ this.dm_1 = null;
2540
2593
  // Inline function 'org.w3c.dom.OPEN' call
2541
2594
  // Inline function 'kotlin.js.asDynamic' call
2542
2595
  // Inline function 'kotlin.js.unsafeCast' call
@@ -2544,21 +2597,22 @@ class MarkdownToc extends BaseWebComponent {
2544
2597
  var o = {};
2545
2598
  o['mode'] = 'open';
2546
2599
  style(this.attachShadow(o), ':host {\n display: block;\n}\n@media screen {\n :host(.floating) {\n position: absolute;\n right: 0px;\n top: 0px;\n }\n :host(.floating) .level-2 {\n height: 0px;\n visibility: collapse;\n }\n :host(.floating:hover) .level-2 {\n height: auto;\n visibility: visible;\n }\n}\n.level {\n padding-left: 10px;\n font-size: 0.9em;\n}\n.level a {\n display: block;\n}\ndiv {\n display: flex;\n flex-direction: column;\n}');
2600
+ this.upgradeProperty('markdownDocument');
2547
2601
  }
2548
- gn() {
2549
- return this.wl_1;
2602
+ mn() {
2603
+ return this.bm_1;
2550
2604
  }
2551
- zl(value) {
2552
- this.yl_1 = value;
2605
+ em(value) {
2606
+ this.dm_1 = value;
2553
2607
  this.refresh();
2554
2608
  }
2555
- bn() {
2556
- return this.yl_1;
2609
+ hn() {
2610
+ return this.dm_1;
2557
2611
  }
2558
2612
  ac() {
2559
2613
  super.ac();
2560
- if (this.yl_1 == null) {
2561
- this.zl(this.closest('markdown-document'));
2614
+ if (this.dm_1 == null) {
2615
+ this.em(this.closest('markdown-document'));
2562
2616
  var tmp = window;
2563
2617
  tmp.setTimeout(MarkdownToc$connectedCallback$lambda(this), 1000);
2564
2618
  }
@@ -2567,7 +2621,7 @@ class MarkdownToc extends BaseWebComponent {
2567
2621
  return this.ac();
2568
2622
  }
2569
2623
  refresh() {
2570
- var tmp0_elvis_lhs = this.yl_1;
2624
+ var tmp0_elvis_lhs = this.dm_1;
2571
2625
  var tmp;
2572
2626
  if (tmp0_elvis_lhs == null) {
2573
2627
  return Unit_instance;
@@ -2583,7 +2637,7 @@ class MarkdownToc extends BaseWebComponent {
2583
2637
  tmp_0 = tmp1_elvis_lhs;
2584
2638
  }
2585
2639
  var shadow = tmp_0;
2586
- var tmp2_safe_receiver = this.xl_1;
2640
+ var tmp2_safe_receiver = this.cm_1;
2587
2641
  if (tmp2_safe_receiver == null)
2588
2642
  null;
2589
2643
  else {
@@ -2591,7 +2645,7 @@ class MarkdownToc extends BaseWebComponent {
2591
2645
  }
2592
2646
  var currentDepth = 1;
2593
2647
  var currentList = document.createElement('div');
2594
- this.xl_1 = currentList;
2648
+ this.cm_1 = currentList;
2595
2649
  shadow.appendChild(currentList);
2596
2650
  // Inline function 'kotlin.collections.filterIsInstance' call
2597
2651
  var tmp0 = asList(root.querySelectorAll('*'));
@@ -2633,30 +2687,30 @@ class MarkdownToc extends BaseWebComponent {
2633
2687
  return '${toc}';
2634
2688
  }
2635
2689
  get mustBeDirectChildOfDocument() {
2636
- return this.gn();
2690
+ return this.mn();
2637
2691
  }
2638
2692
  get markdownDocument() {
2639
- return this.bn();
2693
+ return this.hn();
2640
2694
  }
2641
2695
  set markdownDocument(value) {
2642
- this.zl(value);
2696
+ this.em(value);
2643
2697
  }
2644
2698
  }
2645
2699
  class HeadingAnchors {
2646
2700
  constructor() {
2647
2701
  HeadingAnchors_instance = this;
2648
- this.so_1 = Regex.k8('\\s*\\{([^}]+)\\}$');
2649
- this.to_1 = Regex.j8('[^\\w\u0430-\u044F\u0456\u0457\u0454]+', RegexOption_IGNORE_CASE_getInstance());
2702
+ this.yo_1 = Regex.k8('\\s*\\{([^}]+)\\}$');
2703
+ this.zo_1 = Regex.j8('[^\\w\u0430-\u044F\u0456\u0457\u0454]+', RegexOption_IGNORE_CASE_getInstance());
2650
2704
  }
2651
- uo(idPrefixForDefault, text, useTextInId) {
2652
- var match = this.so_1.n8(text);
2705
+ ap(idPrefixForDefault, text, useTextInId) {
2706
+ var match = this.yo_1.n8(text);
2653
2707
  var tmp;
2654
2708
  if (!(match == null)) {
2655
2709
  tmp = to(match.l9().s(1), substring(text, 0, match.q8().ua_1));
2656
2710
  } else {
2657
2711
  var tmp_0;
2658
2712
  if (useTextInId) {
2659
- tmp_0 = idPrefixForDefault + this.vo(text);
2713
+ tmp_0 = idPrefixForDefault + this.bp(text);
2660
2714
  } else {
2661
2715
  tmp_0 = idPrefixForDefault + ((new Date()).getTime() + Default_getInstance().ka());
2662
2716
  }
@@ -2665,12 +2719,12 @@ class HeadingAnchors {
2665
2719
  }
2666
2720
  return tmp;
2667
2721
  }
2668
- vo(text) {
2722
+ bp(text) {
2669
2723
  // Inline function 'kotlin.text.lowercase' call
2670
2724
  // Inline function 'kotlin.js.asDynamic' call
2671
2725
  var tmp0 = text.toLowerCase();
2672
2726
  // Inline function 'kotlin.text.replace' call
2673
- return this.to_1.o8(tmp0, '-');
2727
+ return this.zo_1.o8(tmp0, '-');
2674
2728
  }
2675
2729
  }
2676
2730
  class MarkdownRenderer {}
@@ -2786,17 +2840,17 @@ class TsStackMarkdownRenderer extends logic_tools_markdown_komponents_tsstack_Ts
2786
2840
  constructor(delegate) {
2787
2841
  delegate = delegate === VOID ? new MarkdownComponentsRenderer() : delegate;
2788
2842
  super();
2789
- this.wo_1 = delegate;
2790
- this.xo_1 = false;
2843
+ this.cp_1 = delegate;
2844
+ this.dp_1 = false;
2791
2845
  }
2792
- yo() {
2793
- return this.wo_1;
2846
+ ep() {
2847
+ return this.cp_1;
2794
2848
  }
2795
- zo(code, lang, escaped, meta) {
2849
+ fp(code, lang, escaped, meta) {
2796
2850
  var tmp;
2797
2851
  // Inline function 'kotlin.text.isNullOrEmpty' call
2798
2852
  if (!(meta == null || charSequenceLength(meta) === 0)) {
2799
- var _destruct__k2r9zo = HeadingAnchors_getInstance().uo('code-', meta, false);
2853
+ var _destruct__k2r9zo = HeadingAnchors_getInstance().ap('code-', meta, false);
2800
2854
  var id = _destruct__k2r9zo.mb();
2801
2855
  var newLang = _destruct__k2r9zo.nb();
2802
2856
  tmp = this.codeWithAnchor(code, newLang, id, escaped);
@@ -2806,9 +2860,9 @@ class TsStackMarkdownRenderer extends logic_tools_markdown_komponents_tsstack_Ts
2806
2860
  return tmp;
2807
2861
  }
2808
2862
  code(code, lang, escaped, meta) {
2809
- return this.zo(code, lang, escaped, meta);
2863
+ return this.fp(code, lang, escaped, meta);
2810
2864
  }
2811
- ap(code, lang, id, escaped) {
2865
+ gp(code, lang, id, escaped) {
2812
2866
  var tmp;
2813
2867
  if (!(escaped === true)) {
2814
2868
  var tmp0_safe_receiver = this.options.escape;
@@ -2818,119 +2872,119 @@ class TsStackMarkdownRenderer extends logic_tools_markdown_komponents_tsstack_Ts
2818
2872
  tmp = code;
2819
2873
  }
2820
2874
  var codeText = tmp;
2821
- return this.wo_1.code(codeText, lang, id);
2875
+ return this.cp_1.code(codeText, lang, id);
2822
2876
  }
2823
2877
  codeWithAnchor(code, lang, id, escaped, $super) {
2824
2878
  escaped = escaped === VOID ? null : escaped;
2825
- return $super === VOID ? this.ap(code, lang, id, escaped) : $super.ap.call(this, code, lang, id, escaped);
2879
+ return $super === VOID ? this.gp(code, lang, id, escaped) : $super.gp.call(this, code, lang, id, escaped);
2826
2880
  }
2827
- bp(quote) {
2828
- return this.wo_1.blockquote(quote);
2881
+ hp(quote) {
2882
+ return this.cp_1.blockquote(quote);
2829
2883
  }
2830
2884
  blockquote(quote) {
2831
- return this.bp(quote);
2885
+ return this.hp(quote);
2832
2886
  }
2833
- cp(html) {
2834
- return this.wo_1.html(html);
2887
+ ip(html) {
2888
+ return this.cp_1.html(html);
2835
2889
  }
2836
2890
  html(html) {
2837
- return this.cp(html);
2891
+ return this.ip(html);
2838
2892
  }
2839
- dp(text, level, raw) {
2840
- var _destruct__k2r9zo = HeadingAnchors_getInstance().uo('heading-', text, true);
2893
+ jp(text, level, raw) {
2894
+ var _destruct__k2r9zo = HeadingAnchors_getInstance().ap('heading-', text, true);
2841
2895
  var id = _destruct__k2r9zo.mb();
2842
2896
  var newText = _destruct__k2r9zo.nb();
2843
- return this.wo_1.heading(newText, level, id);
2897
+ return this.cp_1.heading(newText, level, id);
2844
2898
  }
2845
2899
  heading(text, level, raw) {
2846
- return this.dp(text, level, raw);
2900
+ return this.jp(text, level, raw);
2847
2901
  }
2848
- ep() {
2849
- return this.wo_1.hr();
2902
+ kp() {
2903
+ return this.cp_1.hr();
2850
2904
  }
2851
2905
  hr() {
2852
- return this.ep();
2906
+ return this.kp();
2853
2907
  }
2854
- fp(body, ordered) {
2855
- return this.wo_1.list(body, ordered === true);
2908
+ lp(body, ordered) {
2909
+ return this.cp_1.list(body, ordered === true);
2856
2910
  }
2857
2911
  list(body, ordered) {
2858
- return this.fp(body, ordered);
2912
+ return this.lp(body, ordered);
2859
2913
  }
2860
- gp(text) {
2861
- return startsWith(text, '<markdown-paragraph>[ ] ') ? this.wo_1.taskListItem(replacePrefixOnce(text, '<markdown-paragraph>[ ] ', '<markdown-paragraph>'), false) : startsWith(text, '<markdown-paragraph>[x] ') ? this.wo_1.taskListItem(replacePrefixOnce(text, '<markdown-paragraph>[x] ', '<markdown-paragraph>'), true) : startsWith(text, '[ ] ') ? this.wo_1.taskListItem(removePrefix(text, '[ ] '), false) : startsWith(text, '[x] ') ? this.wo_1.taskListItem(removePrefix(text, '[x] '), true) : this.wo_1.listItem(text);
2914
+ mp(text) {
2915
+ return startsWith(text, '<markdown-paragraph>[ ] ') ? this.cp_1.taskListItem(replacePrefixOnce(text, '<markdown-paragraph>[ ] ', '<markdown-paragraph>'), false) : startsWith(text, '<markdown-paragraph>[x] ') ? this.cp_1.taskListItem(replacePrefixOnce(text, '<markdown-paragraph>[x] ', '<markdown-paragraph>'), true) : startsWith(text, '[ ] ') ? this.cp_1.taskListItem(removePrefix(text, '[ ] '), false) : startsWith(text, '[x] ') ? this.cp_1.taskListItem(removePrefix(text, '[x] '), true) : this.cp_1.listItem(text);
2862
2916
  }
2863
2917
  listitem(text) {
2864
- return this.gp(text);
2918
+ return this.mp(text);
2865
2919
  }
2866
- hp(text) {
2867
- return this.wo_1.paragraph(text);
2920
+ np(text) {
2921
+ return this.cp_1.paragraph(text);
2868
2922
  }
2869
2923
  paragraph(text) {
2870
- return this.hp(text);
2924
+ return this.np(text);
2871
2925
  }
2872
- ip(header, body) {
2873
- return this.wo_1.table(header, body);
2926
+ op(header, body) {
2927
+ return this.cp_1.table(header, body);
2874
2928
  }
2875
2929
  table(header, body) {
2876
- return this.ip(header, body);
2930
+ return this.op(header, body);
2877
2931
  }
2878
- jp(content) {
2879
- var isHeaderRow = this.xo_1;
2880
- this.xo_1 = false;
2881
- return isHeaderRow ? this.wo_1.tableHeaderRow(content) : this.wo_1.tableRow(content);
2932
+ pp(content) {
2933
+ var isHeaderRow = this.dp_1;
2934
+ this.dp_1 = false;
2935
+ return isHeaderRow ? this.cp_1.tableHeaderRow(content) : this.cp_1.tableRow(content);
2882
2936
  }
2883
2937
  tablerow(content) {
2884
- return this.jp(content);
2938
+ return this.pp(content);
2885
2939
  }
2886
- kp(content, flags) {
2940
+ qp(content, flags) {
2887
2941
  var tmp;
2888
2942
  if (flags.header == true) {
2889
- this.xo_1 = true;
2890
- tmp = this.wo_1.tableHeaderCell(content);
2943
+ this.dp_1 = true;
2944
+ tmp = this.cp_1.tableHeaderCell(content);
2891
2945
  } else {
2892
- tmp = this.wo_1.tableCell(content);
2946
+ tmp = this.cp_1.tableCell(content);
2893
2947
  }
2894
2948
  return tmp;
2895
2949
  }
2896
2950
  tablecell(content, flags) {
2897
- return this.kp(content, flags);
2951
+ return this.qp(content, flags);
2898
2952
  }
2899
- lp(text) {
2900
- return this.wo_1.strong(text);
2953
+ rp(text) {
2954
+ return this.cp_1.strong(text);
2901
2955
  }
2902
2956
  strong(text) {
2903
- return this.lp(text);
2957
+ return this.rp(text);
2904
2958
  }
2905
- mp(text) {
2906
- return this.wo_1.emphasis(text);
2959
+ sp(text) {
2960
+ return this.cp_1.emphasis(text);
2907
2961
  }
2908
2962
  em(text) {
2909
- return this.mp(text);
2963
+ return this.sp(text);
2910
2964
  }
2911
- np(text) {
2912
- return this.wo_1.codeSpan(text);
2965
+ tp(text) {
2966
+ return this.cp_1.codeSpan(text);
2913
2967
  }
2914
2968
  codespan(text) {
2915
- return this.np(text);
2969
+ return this.tp(text);
2916
2970
  }
2917
- op(text) {
2918
- return this.wo_1.strikethrough(text);
2971
+ up(text) {
2972
+ return this.cp_1.strikethrough(text);
2919
2973
  }
2920
2974
  del(text) {
2921
- return this.op(text);
2975
+ return this.up(text);
2922
2976
  }
2923
- pp(href, title, text) {
2924
- return this.wo_1.link(href, title, text);
2977
+ vp(href, title, text) {
2978
+ return this.cp_1.link(href, title, text);
2925
2979
  }
2926
2980
  link(href, title, text) {
2927
- return this.pp(href, title, text);
2981
+ return this.vp(href, title, text);
2928
2982
  }
2929
- qp(href, title, text) {
2930
- return this.wo_1.image(href, title, text);
2983
+ wp(href, title, text) {
2984
+ return this.cp_1.image(href, title, text);
2931
2985
  }
2932
2986
  image(href, title, text) {
2933
- return this.qp(href, title, text);
2987
+ return this.wp(href, title, text);
2934
2988
  }
2935
2989
  }
2936
2990
  //endregion
@@ -3010,6 +3064,13 @@ function caretRangeFromPoint(_this__u8e3s4, x, y) {
3010
3064
  // Inline function 'kotlin.js.asDynamic' call
3011
3065
  return _this__u8e3s4.caretRangeFromPoint(x, y);
3012
3066
  }
3067
+ function hasOwnProperty(obj, key) {
3068
+ var tmp = Object.prototype.hasOwnProperty.call(obj, key);
3069
+ return (!(tmp == null) ? typeof tmp === 'boolean' : false) ? tmp : THROW_CCE();
3070
+ }
3071
+ function deleteOwnProperty(obj, key) {
3072
+ delete obj[key];
3073
+ }
3013
3074
  function define_0(_this__u8e3s4, name, elementClass, observedAttributes) {
3014
3075
  var tmp;
3015
3076
  if (observedAttributes === VOID) {
@@ -3042,6 +3103,11 @@ function DropdownElement$lambda($this$element) {
3042
3103
  slot($this$element);
3043
3104
  return Unit_instance;
3044
3105
  }
3106
+ function get_defaultParser() {
3107
+ _init_properties_MarkdownDocument_kt__r41r2i();
3108
+ return defaultParser;
3109
+ }
3110
+ var defaultParser;
3045
3111
  function onKeyDown($this, event) {
3046
3112
  if ($this.editable) {
3047
3113
  switch (event.code) {
@@ -3201,23 +3267,23 @@ function onPaste($this, event) {
3201
3267
  }
3202
3268
  }
3203
3269
  function onMouseSelection($this) {
3204
- if ($this.ol_1 && $this.getAttribute('contenteditable') === 'true') {
3270
+ if ($this.tl_1 && $this.getAttribute('contenteditable') === 'true') {
3205
3271
  $this.setAttribute('contenteditable', 'false');
3206
3272
  }
3207
3273
  }
3208
3274
  function onEndMouseSelection($this) {
3209
- if ($this.ol_1 && $this.getAttribute('contenteditable') === 'false') {
3275
+ if ($this.tl_1 && $this.getAttribute('contenteditable') === 'false') {
3210
3276
  $this.setAttribute('contenteditable', $this.getAttribute('readonly') === 'true' ? 'false' : 'true');
3211
3277
  $this.focus();
3212
3278
  }
3213
3279
  }
3214
3280
  function mousedown($this, event) {
3215
3281
  if ((event.buttons % 2 | 0) === 1) {
3216
- $this.nl_1 = true;
3282
+ $this.sl_1 = true;
3217
3283
  }
3218
3284
  }
3219
3285
  function mouseup($this) {
3220
- $this.nl_1 = false;
3286
+ $this.sl_1 = false;
3221
3287
  onEndMouseSelection($this);
3222
3288
  }
3223
3289
  function selectstart($this) {
@@ -3246,7 +3312,7 @@ function selectionchange($this) {
3246
3312
  tmp_0 = false;
3247
3313
  }
3248
3314
  if (tmp_0) {
3249
- if ($this.nl_1) {
3315
+ if ($this.sl_1) {
3250
3316
  onMouseSelection($this);
3251
3317
  }
3252
3318
  enableEditable($this);
@@ -3254,9 +3320,9 @@ function selectionchange($this) {
3254
3320
  disableEditable($this);
3255
3321
  }
3256
3322
  $this.currentSelection = selection;
3257
- $this.kl_1 = anchorNode;
3258
- $this.ll_1 = selection.anchorOffset;
3259
- $this.ml_1 = new StashedSelection(selection.anchorNode, selection.anchorOffset, selection.focusNode, selection.focusOffset);
3323
+ $this.pl_1 = anchorNode;
3324
+ $this.ql_1 = selection.anchorOffset;
3325
+ $this.rl_1 = new StashedSelection(selection.anchorNode, selection.anchorOffset, selection.focusNode, selection.focusOffset);
3260
3326
  affectToolbar($this);
3261
3327
  } else {
3262
3328
  disableEditable($this);
@@ -3513,14 +3579,14 @@ function normalizeDOM($this) {
3513
3579
  null;
3514
3580
  else {
3515
3581
  // Inline function 'kotlin.let' call
3516
- img.vl(tmp0_safe_receiver);
3582
+ img.am(tmp0_safe_receiver);
3517
3583
  }
3518
3584
  var tmp1_safe_receiver = child.getAttribute('title');
3519
3585
  if (tmp1_safe_receiver == null)
3520
3586
  null;
3521
3587
  else {
3522
3588
  // Inline function 'kotlin.let' call
3523
- img.vl(tmp1_safe_receiver);
3589
+ img.am(tmp1_safe_receiver);
3524
3590
  }
3525
3591
  var tmp2_safe_receiver = child.getAttribute('alt');
3526
3592
  if (tmp2_safe_receiver == null)
@@ -3578,9 +3644,11 @@ function normalizeDOM($this) {
3578
3644
  child.replaceWith(p);
3579
3645
  (p instanceof MarkdownComponent ? p : THROW_CCE()).normalizeContent();
3580
3646
  } else {
3581
- var html = document.createElement('markdown-html');
3582
- (!(child == null) ? child : THROW_CCE()).replaceWith(html);
3583
- html.appendChild(child);
3647
+ if (asMarkdownElement(child) == null) {
3648
+ var html = document.createElement('markdown-html');
3649
+ (!(child == null) ? child : THROW_CCE()).replaceWith(html);
3650
+ html.appendChild(child);
3651
+ }
3584
3652
  }
3585
3653
  }
3586
3654
  }
@@ -3614,7 +3682,7 @@ function firstUpdated($this) {
3614
3682
  var tmp = document.createElement('markdown-toc');
3615
3683
  var toc = tmp instanceof MarkdownToc ? tmp : THROW_CCE();
3616
3684
  toc.classList.add('floating');
3617
- toc.zl($this);
3685
+ toc.em($this);
3618
3686
  var tmp0_safe_receiver = $this.shadowRoot;
3619
3687
  var tmp1_safe_receiver = tmp0_safe_receiver == null ? null : tmp0_safe_receiver.querySelector('.toc');
3620
3688
  if (tmp1_safe_receiver == null)
@@ -3664,7 +3732,7 @@ function handleBackspaceKeyDown($this, event) {
3664
3732
  event.preventDefault();
3665
3733
  var grandparent = parent.parentElement;
3666
3734
  if (!(grandparent == null) ? isInterface(grandparent, MarkdownElementEscapeByBackspace) : false) {
3667
- grandparent.am(parent);
3735
+ grandparent.fm(parent);
3668
3736
  } else {
3669
3737
  parent.mergeWithPrevious($this.currentSelection);
3670
3738
  }
@@ -3750,9 +3818,9 @@ function handleTabKeyDown($this, shift) {
3750
3818
  }
3751
3819
  if (!(parent == null) ? isInterface(parent, MarkdownElementWithLevel) : false) {
3752
3820
  if (shift) {
3753
- parent.cm(child);
3821
+ parent.hm(child);
3754
3822
  } else {
3755
- parent.bm(child);
3823
+ parent.gm(child);
3756
3824
  }
3757
3825
  $this.onChange();
3758
3826
  }
@@ -3880,9 +3948,6 @@ function replaceCurrentLeafBlockWith($this, tagName) {
3880
3948
  oldElement.replaceWith(element);
3881
3949
  $this.onChange();
3882
3950
  }
3883
- function BaseMarkdownDocument$parser$lambda(md) {
3884
- return '<markdown-paragraph>' + md + '<\/markdown-paragraph>';
3885
- }
3886
3951
  function BaseMarkdownDocument$onMouseDown$lambda(this$0) {
3887
3952
  return (event) => {
3888
3953
  mousedown(this$0, event instanceof MouseEvent ? event : THROW_CCE());
@@ -3973,7 +4038,7 @@ function BaseMarkdownDocument$onDrop$lambda($reader, this$0, $event) {
3973
4038
  var dataUri = (!(tmp == null) ? typeof tmp === 'string' : false) ? tmp : THROW_CCE();
3974
4039
  var tmp_0 = document.createElement('markdown-image');
3975
4040
  var img = tmp_0 instanceof MarkdownImage ? tmp_0 : THROW_CCE();
3976
- img.vl(dataUri);
4041
+ img.am(dataUri);
3977
4042
  var pos = this$0.selectionRoot.caretPositionFromPoint($event.clientX, $event.clientY);
3978
4043
  var tmp_1;
3979
4044
  if (!(pos == null)) {
@@ -4014,13 +4079,9 @@ function BaseMarkdownDocument$onChange$lambda(this$0) {
4014
4079
  return () => this$0.dispatchEvent(new CustomEvent('change'));
4015
4080
  }
4016
4081
  function BaseMarkdownDocument$getMarkdown$lambda(it) {
4017
- var tmp;
4018
- if (it instanceof MarkdownComponent) {
4019
- tmp = it.getMarkdown();
4020
- } else {
4021
- tmp = '';
4022
- }
4023
- return tmp;
4082
+ var tmp0_safe_receiver = asMarkdownElement(it);
4083
+ var tmp1_elvis_lhs = tmp0_safe_receiver == null ? null : tmp0_safe_receiver.getMarkdown();
4084
+ return tmp1_elvis_lhs == null ? '' : tmp1_elvis_lhs;
4024
4085
  }
4025
4086
  function BaseMarkdownDocument$makeBold$lambda(this$0) {
4026
4087
  return () => {
@@ -4128,6 +4189,7 @@ function BaseMarkdownDocument$makeCodeInline$lambda(this$0) {
4128
4189
  };
4129
4190
  }
4130
4191
  function getWord(range) {
4192
+ _init_properties_MarkdownDocument_kt__r41r2i();
4131
4193
  var container = range.commonAncestorContainer;
4132
4194
  var tmp;
4133
4195
  if (range.collapsed) {
@@ -4152,6 +4214,7 @@ function getWord(range) {
4152
4214
  return null;
4153
4215
  }
4154
4216
  function allRangeUnderInline_0(tagName, range) {
4217
+ _init_properties_MarkdownDocument_kt__r41r2i();
4155
4218
  var container = range.commonAncestorContainer;
4156
4219
  if (container instanceof Text) {
4157
4220
  var tmp0_safe_receiver = container.parentElement;
@@ -4194,6 +4257,7 @@ function allRangeUnderInline_0(tagName, range) {
4194
4257
  return result;
4195
4258
  }
4196
4259
  function getAllTextNodesForRange(range) {
4260
+ _init_properties_MarkdownDocument_kt__r41r2i();
4197
4261
  var startNode = range.startContainer;
4198
4262
  var endNode = range.endContainer;
4199
4263
  var startOffset = range.startOffset;
@@ -4269,6 +4333,7 @@ function getAllTextNodesForRange(range) {
4269
4333
  return result;
4270
4334
  }
4271
4335
  function isMarkdownContentTextNode(node) {
4336
+ _init_properties_MarkdownDocument_kt__r41r2i();
4272
4337
  var parent = node.parentNode;
4273
4338
  var tmp;
4274
4339
  if (parent instanceof MarkdownComponent) {
@@ -4279,6 +4344,7 @@ function isMarkdownContentTextNode(node) {
4279
4344
  return tmp;
4280
4345
  }
4281
4346
  function surroundRangeIfNotYet(tagName, range) {
4347
+ _init_properties_MarkdownDocument_kt__r41r2i();
4282
4348
  if (range.collapsed) {
4283
4349
  var wordRange = getWord(range);
4284
4350
  if (!(wordRange == null)) {
@@ -4309,6 +4375,7 @@ function surroundRangeIfNotYet(tagName, range) {
4309
4375
  }
4310
4376
  }
4311
4377
  function dispatchToChildren(element) {
4378
+ _init_properties_MarkdownDocument_kt__r41r2i();
4312
4379
  var sibling = element.nextSibling;
4313
4380
  var parent = element.parentElement;
4314
4381
  element.remove();
@@ -4326,6 +4393,7 @@ function dispatchToChildren(element) {
4326
4393
  }
4327
4394
  }
4328
4395
  function unsurroundRange(tagName, range) {
4396
+ _init_properties_MarkdownDocument_kt__r41r2i();
4329
4397
  if (range.collapsed) {
4330
4398
  var wordRange = getWord(range);
4331
4399
  if (!(wordRange == null)) {
@@ -4382,6 +4450,17 @@ function unsurroundRange(tagName, range) {
4382
4450
  }
4383
4451
  while (surrounded);
4384
4452
  }
4453
+ function defaultParser$lambda(md) {
4454
+ _init_properties_MarkdownDocument_kt__r41r2i();
4455
+ return '<markdown-paragraph>' + md + '<\/markdown-paragraph>';
4456
+ }
4457
+ var properties_initialized_MarkdownDocument_kt_5xdlqs;
4458
+ function _init_properties_MarkdownDocument_kt__r41r2i() {
4459
+ if (!properties_initialized_MarkdownDocument_kt_5xdlqs) {
4460
+ properties_initialized_MarkdownDocument_kt_5xdlqs = true;
4461
+ defaultParser = defaultParser$lambda;
4462
+ }
4463
+ }
4385
4464
  function actionButton($this, parent, icon, titleText, onClick) {
4386
4465
  var button = element(parent, 'toolbar-button', MarkdownToolbar$actionButton$lambda(titleText));
4387
4466
  element(button, 'toolbar-icon', MarkdownToolbar$actionButton$lambda_0(icon));
@@ -4405,7 +4484,7 @@ function paragraphOption($this, parent, onClick) {
4405
4484
  item.addEventListener('mousedown', MarkdownToolbar$paragraphOption$lambda_0(onClick));
4406
4485
  }
4407
4486
  function onBoldClick($this) {
4408
- if ($this.um_1.dl()) {
4487
+ if ($this.an_1.dl()) {
4409
4488
  var tmp0_safe_receiver = $this.markdownDocument;
4410
4489
  if (tmp0_safe_receiver == null)
4411
4490
  null;
@@ -4422,7 +4501,7 @@ function onBoldClick($this) {
4422
4501
  }
4423
4502
  }
4424
4503
  function onItalicClick($this) {
4425
- if ($this.vm_1.dl()) {
4504
+ if ($this.bn_1.dl()) {
4426
4505
  var tmp0_safe_receiver = $this.markdownDocument;
4427
4506
  if (tmp0_safe_receiver == null)
4428
4507
  null;
@@ -4439,7 +4518,7 @@ function onItalicClick($this) {
4439
4518
  }
4440
4519
  }
4441
4520
  function onStrikeClick($this) {
4442
- if ($this.wm_1.dl()) {
4521
+ if ($this.cn_1.dl()) {
4443
4522
  var tmp0_safe_receiver = $this.markdownDocument;
4444
4523
  if (tmp0_safe_receiver == null)
4445
4524
  null;
@@ -4762,11 +4841,11 @@ function ToolbarButton$lambda($this$element) {
4762
4841
  }
4763
4842
  function showDropdown($this, event) {
4764
4843
  event.stopPropagation();
4765
- var tmp = $this.en_1;
4844
+ var tmp = $this.kn_1;
4766
4845
  (tmp instanceof HTMLElement ? tmp : THROW_CCE()).style.display = 'block';
4767
4846
  }
4768
4847
  function hideDropdown($this) {
4769
- var tmp = $this.en_1;
4848
+ var tmp = $this.kn_1;
4770
4849
  (tmp instanceof HTMLElement ? tmp : THROW_CCE()).style.display = 'none';
4771
4850
  }
4772
4851
  function ToolbarDropdown$hideOnOutsideMouseDown$lambda(this$0) {
@@ -5059,23 +5138,23 @@ function MarkdownImage$upload$lambda(this$0, $reader) {
5059
5138
  };
5060
5139
  }
5061
5140
  function updateLinkTarget($this) {
5062
- $this.sm_1.href = $this.io();
5063
- $this.sm_1.title = $this.title;
5064
- $this.sm_1.target = startsWith($this.io(), '#') ? '_self' : '_blank';
5065
- $this.sm_1.onclick = MarkdownLink$updateLinkTarget$lambda($this);
5141
+ $this.xm_1.href = $this.oo();
5142
+ $this.xm_1.title = $this.title;
5143
+ $this.xm_1.target = startsWith($this.oo(), '#') ? '_self' : '_blank';
5144
+ $this.xm_1.onclick = MarkdownLink$updateLinkTarget$lambda($this);
5066
5145
  }
5067
5146
  function onDestinationInput($this) {
5068
- $this.vl($this.tm_1.value);
5147
+ $this.am($this.ym_1.value);
5069
5148
  updateLinkTarget($this);
5070
5149
  }
5071
5150
  function hideDestinationInput($this) {
5072
5151
  $this.classList.remove('fresh');
5073
- $this.tm_1.classList.remove('visible');
5152
+ $this.ym_1.classList.remove('visible');
5074
5153
  }
5075
5154
  function showDestinationInput($this) {
5076
- $this.tm_1.classList.add('visible');
5077
- $this.tm_1.focus();
5078
- $this.tm_1.setSelectionRange($this.tm_1.value.length, $this.tm_1.value.length);
5155
+ $this.ym_1.classList.add('visible');
5156
+ $this.ym_1.focus();
5157
+ $this.ym_1.setSelectionRange($this.ym_1.value.length, $this.ym_1.value.length);
5079
5158
  }
5080
5159
  function onDestinationKey($this, event) {
5081
5160
  if (event.key === 'Enter') {
@@ -5135,7 +5214,7 @@ function MarkdownLink$connectedCallback$lambda(this$0) {
5135
5214
  function MarkdownLink$updateLinkTarget$lambda(this$0) {
5136
5215
  return (event) => {
5137
5216
  // Inline function 'org.w3c.dom.CustomEventInit' call
5138
- var detail = this$0.io();
5217
+ var detail = this$0.oo();
5139
5218
  var o = {};
5140
5219
  o['detail'] = detail;
5141
5220
  o['bubbles'] = true;
@@ -5243,7 +5322,7 @@ function MarkdownTaskListItem$lambda_0($this$element) {
5243
5322
  }
5244
5323
  function MarkdownTaskListItem$lambda_1(this$0) {
5245
5324
  return (it) => {
5246
- this$0.setAttribute('checked', this$0.qo_1.checked.toString());
5325
+ this$0.setAttribute('checked', this$0.wo_1.checked.toString());
5247
5326
  return Unit_instance;
5248
5327
  };
5249
5328
  }
@@ -5359,7 +5438,7 @@ function parseMarkdown$lambda($renderer) {
5359
5438
  function parseMarkdown$lambda_0($renderer) {
5360
5439
  return (execArr) => {
5361
5440
  var groups = ensureNotNull(execArr);
5362
- return $renderer.wo_1.custom(ensureNotNull(groups[1]), parseMarkdownWithTsStackRenderer(ensureNotNull(groups[2]), $renderer));
5441
+ return $renderer.cp_1.custom(ensureNotNull(groups[1]), parseMarkdownWithTsStackRenderer(ensureNotNull(groups[2]), $renderer));
5363
5442
  };
5364
5443
  }
5365
5444
  var properties_initialized_TsStackMarkdownRenderer_kt_6onrsl;