mol_plot_all 1.2.455 → 1.2.456
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.test.js +35 -31
- package/node.test.js.map +1 -1
- package/package.json +1 -1
- package/web.test.js +42 -38
- package/web.test.js.map +1 -1
package/package.json
CHANGED
package/web.test.js
CHANGED
|
@@ -909,32 +909,6 @@ var $;
|
|
|
909
909
|
;
|
|
910
910
|
"use strict";
|
|
911
911
|
var $;
|
|
912
|
-
(function ($) {
|
|
913
|
-
function $mol_wire_sync(obj) {
|
|
914
|
-
return new Proxy(obj, {
|
|
915
|
-
get(obj, field) {
|
|
916
|
-
const val = obj[field];
|
|
917
|
-
if (typeof val !== 'function')
|
|
918
|
-
return val;
|
|
919
|
-
const temp = $mol_wire_task.getter(val);
|
|
920
|
-
return function $mol_wire_sync(...args) {
|
|
921
|
-
const fiber = temp(obj, args);
|
|
922
|
-
return fiber.sync();
|
|
923
|
-
};
|
|
924
|
-
},
|
|
925
|
-
apply(obj, self, args) {
|
|
926
|
-
const temp = $mol_wire_task.getter(obj);
|
|
927
|
-
const fiber = temp(self, args);
|
|
928
|
-
return fiber.sync();
|
|
929
|
-
},
|
|
930
|
-
});
|
|
931
|
-
}
|
|
932
|
-
$.$mol_wire_sync = $mol_wire_sync;
|
|
933
|
-
})($ || ($ = {}));
|
|
934
|
-
//mol/wire/sync/sync.ts
|
|
935
|
-
;
|
|
936
|
-
"use strict";
|
|
937
|
-
var $;
|
|
938
912
|
(function ($) {
|
|
939
913
|
function $mol_promise() {
|
|
940
914
|
let done;
|
|
@@ -963,6 +937,32 @@ var $;
|
|
|
963
937
|
;
|
|
964
938
|
"use strict";
|
|
965
939
|
var $;
|
|
940
|
+
(function ($) {
|
|
941
|
+
function $mol_wire_sync(obj) {
|
|
942
|
+
return new Proxy(obj, {
|
|
943
|
+
get(obj, field) {
|
|
944
|
+
const val = obj[field];
|
|
945
|
+
if (typeof val !== 'function')
|
|
946
|
+
return val;
|
|
947
|
+
const temp = $mol_wire_task.getter(val);
|
|
948
|
+
return function $mol_wire_sync(...args) {
|
|
949
|
+
const fiber = temp(obj, args);
|
|
950
|
+
return fiber.sync();
|
|
951
|
+
};
|
|
952
|
+
},
|
|
953
|
+
apply(obj, self, args) {
|
|
954
|
+
const temp = $mol_wire_task.getter(obj);
|
|
955
|
+
const fiber = temp(self, args);
|
|
956
|
+
return fiber.sync();
|
|
957
|
+
},
|
|
958
|
+
});
|
|
959
|
+
}
|
|
960
|
+
$.$mol_wire_sync = $mol_wire_sync;
|
|
961
|
+
})($ || ($ = {}));
|
|
962
|
+
//mol/wire/sync/sync.ts
|
|
963
|
+
;
|
|
964
|
+
"use strict";
|
|
965
|
+
var $;
|
|
966
966
|
(function ($) {
|
|
967
967
|
function $mol_wait_timeout_async(timeout) {
|
|
968
968
|
const promise = $mol_promise();
|
|
@@ -1149,21 +1149,17 @@ var $;
|
|
|
1149
1149
|
'Flow: Auto'($) {
|
|
1150
1150
|
class App extends $mol_object2 {
|
|
1151
1151
|
static get $() { return $; }
|
|
1152
|
-
static
|
|
1153
|
-
static second(next = 2) { return next; }
|
|
1152
|
+
static source(next = 1) { return next; }
|
|
1154
1153
|
static condition(next = true) { return next; }
|
|
1155
1154
|
static counter = 0;
|
|
1156
1155
|
static result() {
|
|
1157
|
-
const res = this.condition() ? this.
|
|
1156
|
+
const res = this.condition() ? this.source() : 0;
|
|
1158
1157
|
return res + this.counter++;
|
|
1159
1158
|
}
|
|
1160
1159
|
}
|
|
1161
1160
|
__decorate([
|
|
1162
1161
|
$mol_wire_solo
|
|
1163
|
-
], App, "
|
|
1164
|
-
__decorate([
|
|
1165
|
-
$mol_wire_solo
|
|
1166
|
-
], App, "second", null);
|
|
1162
|
+
], App, "source", null);
|
|
1167
1163
|
__decorate([
|
|
1168
1164
|
$mol_wire_solo
|
|
1169
1165
|
], App, "condition", null);
|
|
@@ -1172,12 +1168,20 @@ var $;
|
|
|
1172
1168
|
], App, "result", null);
|
|
1173
1169
|
$mol_assert_equal(App.result(), 1);
|
|
1174
1170
|
$mol_assert_equal(App.counter, 1);
|
|
1175
|
-
App.
|
|
1176
|
-
$mol_assert_equal(App.result(),
|
|
1177
|
-
$mol_assert_equal(App.counter, 2);
|
|
1178
|
-
App.first(10);
|
|
1179
|
-
$mol_assert_equal(App.result(), 3);
|
|
1171
|
+
App.source(10);
|
|
1172
|
+
$mol_assert_equal(App.result(), 11);
|
|
1180
1173
|
$mol_assert_equal(App.counter, 2);
|
|
1174
|
+
App.condition(false);
|
|
1175
|
+
$mol_assert_equal(App.result(), 2);
|
|
1176
|
+
$mol_assert_equal(App.counter, 3);
|
|
1177
|
+
$mol_wire_fiber.sync();
|
|
1178
|
+
$mol_assert_equal(App.source(), 1);
|
|
1179
|
+
App.source(20);
|
|
1180
|
+
$mol_assert_equal(App.result(), 2);
|
|
1181
|
+
$mol_assert_equal(App.counter, 3);
|
|
1182
|
+
App.condition(true);
|
|
1183
|
+
$mol_assert_equal(App.result(), 23);
|
|
1184
|
+
$mol_assert_equal(App.counter, 4);
|
|
1181
1185
|
},
|
|
1182
1186
|
'Dupes: Equality'($) {
|
|
1183
1187
|
let counter = 0;
|