tinybase 8.3.0-beta.1 → 8.3.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.
@@ -46,6 +46,7 @@ const getIfNotFunction = (predicate) => (value, then, otherwise) =>
46
46
  otherwise?.()
47
47
  : then(value);
48
48
  const GLOBAL = globalThis;
49
+ const isNullish = (thing) => thing == null;
49
50
  const isUndefined = (thing) => thing === void 0;
50
51
  const hasWindow = () => !isUndefined(GLOBAL.window);
51
52
  const ifNotUndefined = getIfNotFunction(isUndefined);
@@ -1391,7 +1392,7 @@ function CurrentCheckpointView($$anchor, $$props) {
1391
1392
  $.append($$anchor, fragment_1);
1392
1393
  };
1393
1394
 
1394
- var d = $.derived(() => !isUndefined($.get(currentId)));
1395
+ var d = $.derived(() => !isNullish($.get(currentId)));
1395
1396
 
1396
1397
  $.if(node, ($$render) => {
1397
1398
  if ($.get(d)) $$render(consequent_1);
@@ -1553,8 +1554,10 @@ function SliceView($$anchor, $$props) {
1553
1554
  });
1554
1555
  };
1555
1556
 
1557
+ var d = $.derived(() => !isUndefined(tableId));
1558
+
1556
1559
  $.if(node, ($$render) => {
1557
- if (tableId) $$render(consequent);
1560
+ if ($.get(d)) $$render(consequent);
1558
1561
  });
1559
1562
  }
1560
1563
 
@@ -1685,8 +1688,10 @@ function LinkedRowsView($$anchor, $$props) {
1685
1688
  });
1686
1689
  };
1687
1690
 
1691
+ var d = $.derived(() => !isUndefined(localTableId));
1692
+
1688
1693
  $.if(node, ($$render) => {
1689
- if (localTableId) $$render(consequent);
1694
+ if ($.get(d)) $$render(consequent);
1690
1695
  });
1691
1696
  }
1692
1697
 
@@ -1760,8 +1765,10 @@ function LocalRowsView($$anchor, $$props) {
1760
1765
  });
1761
1766
  };
1762
1767
 
1768
+ var d = $.derived(() => !isUndefined(localTableId));
1769
+
1763
1770
  $.if(node, ($$render) => {
1764
- if (localTableId) $$render(consequent);
1771
+ if ($.get(d)) $$render(consequent);
1765
1772
  });
1766
1773
  }
1767
1774
 
@@ -46,6 +46,7 @@ const getIfNotFunction = (predicate) => (value, then, otherwise) =>
46
46
  otherwise?.()
47
47
  : then(value);
48
48
  const GLOBAL = globalThis;
49
+ const isNullish = (thing) => thing == null;
49
50
  const isUndefined = (thing) => thing === void 0;
50
51
  const hasWindow = () => !isUndefined(GLOBAL.window);
51
52
  const ifNotUndefined = getIfNotFunction(isUndefined);
@@ -1391,7 +1392,7 @@ function CurrentCheckpointView($$anchor, $$props) {
1391
1392
  $.append($$anchor, fragment_1);
1392
1393
  };
1393
1394
 
1394
- var d = $.derived(() => !isUndefined($.get(currentId)));
1395
+ var d = $.derived(() => !isNullish($.get(currentId)));
1395
1396
 
1396
1397
  $.if(node, ($$render) => {
1397
1398
  if ($.get(d)) $$render(consequent_1);
@@ -1553,8 +1554,10 @@ function SliceView($$anchor, $$props) {
1553
1554
  });
1554
1555
  };
1555
1556
 
1557
+ var d = $.derived(() => !isUndefined(tableId));
1558
+
1556
1559
  $.if(node, ($$render) => {
1557
- if (tableId) $$render(consequent);
1560
+ if ($.get(d)) $$render(consequent);
1558
1561
  });
1559
1562
  }
1560
1563
 
@@ -1685,8 +1688,10 @@ function LinkedRowsView($$anchor, $$props) {
1685
1688
  });
1686
1689
  };
1687
1690
 
1691
+ var d = $.derived(() => !isUndefined(localTableId));
1692
+
1688
1693
  $.if(node, ($$render) => {
1689
- if (localTableId) $$render(consequent);
1694
+ if ($.get(d)) $$render(consequent);
1690
1695
  });
1691
1696
  }
1692
1697
 
@@ -1760,8 +1765,10 @@ function LocalRowsView($$anchor, $$props) {
1760
1765
  });
1761
1766
  };
1762
1767
 
1768
+ var d = $.derived(() => !isUndefined(localTableId));
1769
+
1763
1770
  $.if(node, ($$render) => {
1764
- if (localTableId) $$render(consequent);
1771
+ if ($.get(d)) $$render(consequent);
1765
1772
  });
1766
1773
  }
1767
1774