mol_dump_lib 0.0.3 → 0.0.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/web.mjs CHANGED
@@ -1772,6 +1772,15 @@ var $;
1772
1772
  let all = [];
1773
1773
  let el = null;
1774
1774
  let timer = null;
1775
+ function $mol_style_attach_force() {
1776
+ if (all.length) {
1777
+ el.innerHTML += '\n' + all.join('\n\n');
1778
+ all = [];
1779
+ }
1780
+ timer = null;
1781
+ return el;
1782
+ }
1783
+ $.$mol_style_attach_force = $mol_style_attach_force;
1775
1784
  function $mol_style_attach(id, text) {
1776
1785
  all.push(`/* ${id} */\n\n${text}`);
1777
1786
  if (timer)
@@ -1782,12 +1791,7 @@ var $;
1782
1791
  el = doc.createElement('style');
1783
1792
  el.id = `$mol_style_attach`;
1784
1793
  doc.head.appendChild(el);
1785
- timer = new $mol_after_tick(() => {
1786
- el.innerHTML = '\n' + all.join('\n\n');
1787
- all = [];
1788
- el = null;
1789
- timer = null;
1790
- });
1794
+ timer = new $mol_after_tick($mol_style_attach_force);
1791
1795
  return el;
1792
1796
  }
1793
1797
  $.$mol_style_attach = $mol_style_attach;
@@ -2456,7 +2460,7 @@ var $;
2456
2460
  this.attachShadow({ mode: 'open' });
2457
2461
  const node = this.view.dom_node();
2458
2462
  node.setAttribute('mol_view_root', '');
2459
- this.shadowRoot.append(document.getElementById(`$mol_style_attach`).cloneNode(true), node);
2463
+ this.shadowRoot.append($mol_style_attach_force().cloneNode(true), node);
2460
2464
  }
2461
2465
  this.root = $mol_wire_auto();
2462
2466
  try {
@@ -5733,10 +5737,14 @@ var $;
5733
5737
  var $;
5734
5738
  (function ($) {
5735
5739
  class $mol_dump_value extends $mol_view {
5736
- value() {
5740
+ value(next) {
5741
+ if (next !== undefined)
5742
+ return next;
5737
5743
  return null;
5738
5744
  }
5739
- preview_show() {
5745
+ preview_show(next) {
5746
+ if (next !== undefined)
5747
+ return next;
5740
5748
  return true;
5741
5749
  }
5742
5750
  sub() {
@@ -5832,6 +5840,12 @@ var $;
5832
5840
  return obj;
5833
5841
  }
5834
5842
  }
5843
+ __decorate([
5844
+ $mol_mem
5845
+ ], $mol_dump_value.prototype, "value", null);
5846
+ __decorate([
5847
+ $mol_mem
5848
+ ], $mol_dump_value.prototype, "preview_show", null);
5835
5849
  __decorate([
5836
5850
  $mol_mem
5837
5851
  ], $mol_dump_value.prototype, "Simple", null);
package/web.view.tree CHANGED
@@ -214,8 +214,8 @@ $mol_expander $mol_list
214
214
  rows <= content /
215
215
 
216
216
  $mol_dump_value $mol_view
217
- value null
218
- preview_show true
217
+ value? null
218
+ preview_show? true
219
219
  sub /
220
220
  <= Simple $mol_text_code
221
221
  text <= simple \