@delta-comic/plugin 0.0.1 → 0.0.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.
- package/dist/index.js +39 -2
- package/dist/index.js.map +1 -1
- package/dist/lib/index.d.ts +1 -0
- package/dist/pack.tgz +0 -0
- package/package.json +4 -4
package/dist/index.js
CHANGED
|
@@ -3,6 +3,7 @@ import { useNativeStore } from "@delta-comic/db";
|
|
|
3
3
|
import { useGlobalVar } from "@delta-comic/utils";
|
|
4
4
|
import { computed, getCurrentInstance, getCurrentScope, hasInjectionContext, inject, onMounted, shallowReactive, shallowRef, toValue, unref, watch, watchEffect } from "vue";
|
|
5
5
|
import { defineStore } from "pinia";
|
|
6
|
+
import { SourcedKeyMap } from "@delta-comic/model";
|
|
6
7
|
function isLength(e) {
|
|
7
8
|
return Number.isSafeInteger(e) && e >= 0;
|
|
8
9
|
}
|
|
@@ -206,7 +207,43 @@ const appConfig = useGlobalVar(new ConfigPointer("core", {
|
|
|
206
207
|
});
|
|
207
208
|
}, "resignerConfig")
|
|
208
209
|
};
|
|
209
|
-
}), declareDepType = (e) => Symbol.for(`expose:${e}`), require = (e) => pluginExposes.get(e), pluginExposes = /* @__PURE__ */ new Map()
|
|
210
|
-
|
|
210
|
+
}), declareDepType = (e) => Symbol.for(`expose:${e}`), require = (e) => pluginExposes.get(e), pluginExposes = /* @__PURE__ */ new Map(), Global = useGlobalVar(new class {
|
|
211
|
+
share = shallowReactive(SourcedKeyMap.create());
|
|
212
|
+
shareToken = shallowReactive(SourcedKeyMap.create());
|
|
213
|
+
userActions = shallowReactive(SourcedKeyMap.create());
|
|
214
|
+
subscribes = shallowReactive(SourcedKeyMap.create());
|
|
215
|
+
globalNodes = shallowReactive([]);
|
|
216
|
+
tabbar = shallowReactive(/* @__PURE__ */ new Map());
|
|
217
|
+
addTabbar(e, ...t) {
|
|
218
|
+
let n = this.tabbar.get(e) ?? [];
|
|
219
|
+
this.tabbar.set(e, n.concat(t));
|
|
220
|
+
}
|
|
221
|
+
categories = shallowReactive(/* @__PURE__ */ new Map());
|
|
222
|
+
addCategories(e, ...t) {
|
|
223
|
+
let n = this.categories.get(e) ?? [];
|
|
224
|
+
this.categories.set(e, n.concat(t));
|
|
225
|
+
}
|
|
226
|
+
barcode = shallowReactive(/* @__PURE__ */ new Map());
|
|
227
|
+
addBarcode(e, ...t) {
|
|
228
|
+
let n = this.barcode.get(e) ?? [];
|
|
229
|
+
this.barcode.set(e, n.concat(t));
|
|
230
|
+
}
|
|
231
|
+
levelboard = shallowReactive(/* @__PURE__ */ new Map());
|
|
232
|
+
addLevelboard(e, ...t) {
|
|
233
|
+
let n = this.levelboard.get(e) ?? [];
|
|
234
|
+
this.levelboard.set(e, n.concat(t));
|
|
235
|
+
}
|
|
236
|
+
topButton = shallowReactive(/* @__PURE__ */ new Map());
|
|
237
|
+
addTopButton(e, ...t) {
|
|
238
|
+
let n = this.topButton.get(e) ?? [];
|
|
239
|
+
this.topButton.set(e, n.concat(t));
|
|
240
|
+
}
|
|
241
|
+
mainLists = shallowReactive(/* @__PURE__ */ new Map());
|
|
242
|
+
addMainList(e, ...t) {
|
|
243
|
+
let n = this.mainLists.get(e) ?? [];
|
|
244
|
+
this.mainLists.set(e, n.concat(t));
|
|
245
|
+
}
|
|
246
|
+
}(), "core/global");
|
|
247
|
+
export { ConfigPointer, Global, appConfig, declareDepType, decodePluginMeta, definePlugin, pluginExposes, require, useConfig };
|
|
211
248
|
|
|
212
249
|
//# sourceMappingURL=index.js.map
|