mol_plot_all 1.2.814 → 1.2.816
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.deps.json +1 -1
- package/node.js +4 -0
- package/node.js.map +1 -1
- package/node.mjs +4 -0
- package/node.test.js +5 -0
- package/node.test.js.map +1 -1
- package/package.json +1 -1
- package/web.deps.json +1 -1
- package/web.js +4 -0
- package/web.js.map +1 -1
- package/web.mjs +4 -0
- package/web.test.js +13 -3
- package/web.test.js.map +1 -1
package/web.mjs
CHANGED
|
@@ -879,11 +879,15 @@ var $;
|
|
|
879
879
|
(function ($) {
|
|
880
880
|
$.$mol_key_store = new WeakMap();
|
|
881
881
|
function $mol_key(value) {
|
|
882
|
+
if (typeof value === 'bigint')
|
|
883
|
+
return value.toString() + 'n';
|
|
882
884
|
if (!value)
|
|
883
885
|
return JSON.stringify(value);
|
|
884
886
|
if (typeof value !== 'object' && typeof value !== 'function')
|
|
885
887
|
return JSON.stringify(value);
|
|
886
888
|
return JSON.stringify(value, (field, value) => {
|
|
889
|
+
if (typeof value === 'bigint')
|
|
890
|
+
return value.toString() + 'n';
|
|
887
891
|
if (!value)
|
|
888
892
|
return value;
|
|
889
893
|
if (typeof value !== 'object' && typeof value !== 'function')
|
package/web.test.js
CHANGED
|
@@ -2150,6 +2150,7 @@ var $;
|
|
|
2150
2150
|
$mol_assert_equal($mol_key(false), 'false');
|
|
2151
2151
|
$mol_assert_equal($mol_key(true), 'true');
|
|
2152
2152
|
$mol_assert_equal($mol_key(0), '0');
|
|
2153
|
+
$mol_assert_equal($mol_key(1n << 64n), '18446744073709551616n');
|
|
2153
2154
|
$mol_assert_equal($mol_key(''), '""');
|
|
2154
2155
|
},
|
|
2155
2156
|
'Array & POJO'() {
|
|
@@ -2993,11 +2994,20 @@ var $;
|
|
|
2993
2994
|
static native() {
|
|
2994
2995
|
return this.$.$mol_dom_context.navigator.storage;
|
|
2995
2996
|
}
|
|
2996
|
-
static persisted(next) {
|
|
2997
|
+
static persisted(next, cache) {
|
|
2997
2998
|
$mol_mem_persist();
|
|
2999
|
+
if (cache)
|
|
3000
|
+
return Boolean(next);
|
|
2998
3001
|
const native = this.native();
|
|
2999
|
-
if (next)
|
|
3000
|
-
native.persist()
|
|
3002
|
+
if (next && !$mol_mem_cached(() => this.persisted())) {
|
|
3003
|
+
native.persist().then(actual => {
|
|
3004
|
+
setTimeout(() => this.persisted(actual, 'cache'), 5000);
|
|
3005
|
+
if (actual)
|
|
3006
|
+
this.$.$mol_log3_rise({ place: this, message: `Persist` });
|
|
3007
|
+
else
|
|
3008
|
+
this.$.$mol_log3_fail({ place: this, message: `Non persist` });
|
|
3009
|
+
});
|
|
3010
|
+
}
|
|
3001
3011
|
return next ?? $mol_wire_sync(native).persisted();
|
|
3002
3012
|
}
|
|
3003
3013
|
static estimate() {
|