mol_plot_all 1.2.863 → 1.2.865

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/node.js CHANGED
@@ -414,9 +414,6 @@ var $;
414
414
  function $mol_dev_format_auto(obj) {
415
415
  if (obj == null)
416
416
  return $.$mol_dev_format_shade(String(obj));
417
- if (typeof obj === 'object' && $.$mol_dev_format_head in obj) {
418
- return obj[$.$mol_dev_format_head]();
419
- }
420
417
  return [
421
418
  'object',
422
419
  {
@@ -750,7 +747,12 @@ var $;
750
747
  [$mol_wire_cursor.fresh]: '🟢',
751
748
  [$mol_wire_cursor.final]: '🔵',
752
749
  }[this.cursor] ?? this.cursor.toString();
753
- return $mol_dev_format_div({}, $mol_dev_format_native(this), $mol_dev_format_shade(cursor + ' '), $mol_dev_format_auto(this.cache));
750
+ return $mol_dev_format_div({}, $mol_owning_check(this, this.cache)
751
+ ? $mol_dev_format_auto({
752
+ [$mol_dev_format_head]: () => $mol_dev_format_shade(cursor),
753
+ [$mol_dev_format_body]: () => $mol_dev_format_native(this),
754
+ })
755
+ : $mol_dev_format_shade($mol_dev_format_native(this), cursor), $mol_dev_format_auto(this.cache));
754
756
  }
755
757
  get $() {
756
758
  return (this.host ?? this.task)['$'];
@@ -898,6 +900,8 @@ var $;
898
900
  function $mol_key(value) {
899
901
  if (typeof value === 'bigint')
900
902
  return value.toString() + 'n';
903
+ if (typeof value === 'symbol')
904
+ return value.description;
901
905
  if (!value)
902
906
  return JSON.stringify(value);
903
907
  if (typeof value !== 'object' && typeof value !== 'function')
@@ -905,6 +909,8 @@ var $;
905
909
  return JSON.stringify(value, (field, value) => {
906
910
  if (typeof value === 'bigint')
907
911
  return value.toString() + 'n';
912
+ if (typeof value === 'symbol')
913
+ return value.description;
908
914
  if (!value)
909
915
  return value;
910
916
  if (typeof value !== 'object' && typeof value !== 'function')
@@ -1731,17 +1737,18 @@ var $;
1731
1737
  const field = task.name + '()';
1732
1738
  let dict = Object.getOwnPropertyDescriptor(host ?? task, field)?.value;
1733
1739
  const prefix = host?.[Symbol.toStringTag] ?? (host instanceof Function ? $$.$mol_func_name(host) : host);
1734
- const id = `${prefix}.${task.name}(${$mol_key(key).replace(/^"|"$/g, "'")})`;
1740
+ const key_str = $mol_key(key);
1735
1741
  if (dict) {
1736
- const existen = dict.get(id);
1742
+ const existen = dict.get(key_str);
1737
1743
  if (existen)
1738
1744
  return existen;
1739
1745
  }
1740
1746
  else {
1741
1747
  dict = (host ?? task)[field] = new Map();
1742
1748
  }
1749
+ const id = `${prefix}.${task.name}(${key_str.replace(/^"|"$/g, "'")})`;
1743
1750
  const fiber = new $mol_wire_atom(id, task, host, [key]);
1744
- dict.set(id, fiber);
1751
+ dict.set(key_str, fiber);
1745
1752
  return fiber;
1746
1753
  }
1747
1754
  static watching = new Set();
@@ -1796,7 +1803,7 @@ var $;
1796
1803
  }
1797
1804
  else {
1798
1805
  ;
1799
- (this.host ?? this.task)[this.field()].delete(this[Symbol.toStringTag]);
1806
+ (this.host ?? this.task)[this.field()].delete($mol_key(this.args[0]));
1800
1807
  }
1801
1808
  }
1802
1809
  put(next) {