@rpgjs/client 5.0.0-beta.6 → 5.0.0-beta.8
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/CHANGELOG.md +14 -0
- package/dist/Game/AnimationManager.d.ts +2 -2
- package/dist/Game/AnimationManager.js +18 -9
- package/dist/Game/AnimationManager.js.map +1 -1
- package/dist/Game/AnimationManager.spec.d.ts +1 -0
- package/dist/Game/Map.d.ts +7 -9
- package/dist/Game/Map.js +5 -4
- package/dist/Game/Map.js.map +1 -1
- package/dist/Game/Object.d.ts +44 -20
- package/dist/Game/Object.js +28 -14
- package/dist/Game/Object.js.map +1 -1
- package/dist/Gui/Gui.d.ts +19 -6
- package/dist/Gui/Gui.js +64 -34
- package/dist/Gui/Gui.js.map +1 -1
- package/dist/Gui/Gui.spec.d.ts +1 -0
- package/dist/Gui/NotificationManager.d.ts +1 -1
- package/dist/Gui/NotificationManager.js.map +1 -1
- package/dist/Resource.js +1 -1
- package/dist/Resource.js.map +1 -1
- package/dist/RpgClient.d.ts +57 -2
- package/dist/RpgClientEngine.d.ts +55 -16
- package/dist/RpgClientEngine.js +60 -5
- package/dist/RpgClientEngine.js.map +1 -1
- package/dist/Sound.js.map +1 -1
- package/dist/_virtual/{_@oxc-project_runtime@0.127.0 → _@oxc-project_runtime@0.128.0}/helpers/decorate.js +1 -1
- package/dist/_virtual/{_@oxc-project_runtime@0.127.0 → _@oxc-project_runtime@0.128.0}/helpers/decorateMetadata.js +1 -1
- package/dist/components/animations/animation.ce.js.map +1 -1
- package/dist/components/animations/hit.ce.js.map +1 -1
- package/dist/components/character.ce.js +280 -3
- package/dist/components/character.ce.js.map +1 -1
- package/dist/components/dynamics/bar.ce.js +96 -0
- package/dist/components/dynamics/bar.ce.js.map +1 -0
- package/dist/components/dynamics/image.ce.js +23 -0
- package/dist/components/dynamics/image.ce.js.map +1 -0
- package/dist/components/dynamics/parse-value.d.ts +4 -1
- package/dist/components/dynamics/parse-value.js +51 -35
- package/dist/components/dynamics/parse-value.js.map +1 -1
- package/dist/components/dynamics/parse-value.spec.d.ts +1 -0
- package/dist/components/dynamics/shape-utils.d.ts +16 -0
- package/dist/components/dynamics/shape-utils.js +73 -0
- package/dist/components/dynamics/shape-utils.js.map +1 -0
- package/dist/components/dynamics/shape-utils.spec.d.ts +1 -0
- package/dist/components/dynamics/shape.ce.js +83 -0
- package/dist/components/dynamics/shape.ce.js.map +1 -0
- package/dist/components/dynamics/text.ce.js +28 -41
- package/dist/components/dynamics/text.ce.js.map +1 -1
- package/dist/components/gui/box.ce.js.map +1 -1
- package/dist/components/gui/dialogbox/index.ce.js.map +1 -1
- package/dist/components/gui/gameover.ce.js.map +1 -1
- package/dist/components/gui/hud/hud.ce.js.map +1 -1
- package/dist/components/gui/menu/equip-menu.ce.js.map +1 -1
- package/dist/components/gui/menu/exit-menu.ce.js.map +1 -1
- package/dist/components/gui/menu/items-menu.ce.js.map +1 -1
- package/dist/components/gui/menu/main-menu.ce.js.map +1 -1
- package/dist/components/gui/menu/options-menu.ce.js.map +1 -1
- package/dist/components/gui/menu/skills-menu.ce.js.map +1 -1
- package/dist/components/gui/mobile/index.d.ts +1 -1
- package/dist/components/gui/mobile/index.js.map +1 -1
- package/dist/components/gui/mobile/mobile.ce.js.map +1 -1
- package/dist/components/gui/notification/notification.ce.js.map +1 -1
- package/dist/components/gui/save-load.ce.js.map +1 -1
- package/dist/components/gui/shop/shop.ce.js.map +1 -1
- package/dist/components/gui/title-screen.ce.js.map +1 -1
- package/dist/components/player-components-utils.d.ts +67 -0
- package/dist/components/player-components-utils.js +162 -0
- package/dist/components/player-components-utils.js.map +1 -0
- package/dist/components/player-components-utils.spec.d.ts +1 -0
- package/dist/components/player-components.ce.js +188 -0
- package/dist/components/player-components.ce.js.map +1 -0
- package/dist/components/prebuilt/hp-bar.ce.js.map +1 -1
- package/dist/components/prebuilt/light-halo.ce.js.map +1 -1
- package/dist/components/scenes/canvas.ce.js.map +1 -1
- package/dist/components/scenes/draw-map.ce.js.map +1 -1
- package/dist/components/scenes/event-layer.ce.js.map +1 -1
- package/dist/core/inject.js +1 -1
- package/dist/core/inject.js.map +1 -1
- package/dist/core/setup.js +1 -1
- package/dist/core/setup.js.map +1 -1
- package/dist/index.js +1 -1
- package/dist/module.js +4 -1
- package/dist/module.js.map +1 -1
- package/dist/node_modules/.pnpm/{@signe_di@2.9.0 → @signe_di@2.10.0}/node_modules/@signe/di/dist/index.js +7 -117
- package/dist/node_modules/.pnpm/@signe_di@2.10.0/node_modules/@signe/di/dist/index.js.map +1 -0
- package/dist/node_modules/.pnpm/@signe_reactive@2.10.0/node_modules/@signe/reactive/dist/index.js +239 -0
- package/dist/node_modules/.pnpm/@signe_reactive@2.10.0/node_modules/@signe/reactive/dist/index.js.map +1 -0
- package/dist/node_modules/.pnpm/@signe_room@2.10.0/node_modules/@signe/room/dist/index.js +611 -0
- package/dist/node_modules/.pnpm/@signe_room@2.10.0/node_modules/@signe/room/dist/index.js.map +1 -0
- package/dist/node_modules/.pnpm/@signe_sync@2.10.0/node_modules/@signe/sync/dist/client/index.js +44 -0
- package/dist/node_modules/.pnpm/@signe_sync@2.10.0/node_modules/@signe/sync/dist/client/index.js.map +1 -0
- package/dist/node_modules/.pnpm/{@signe_sync@2.9.0 → @signe_sync@2.10.0}/node_modules/@signe/sync/dist/index.js +29 -136
- package/dist/node_modules/.pnpm/@signe_sync@2.10.0/node_modules/@signe/sync/dist/index.js.map +1 -0
- package/dist/node_modules/.pnpm/partysocket@1.1.3/node_modules/partysocket/dist/chunk-HAC622V3.js.map +1 -1
- package/dist/node_modules/.pnpm/partysocket@1.1.3/node_modules/partysocket/dist/chunk-S74YV6PU.js.map +1 -1
- package/dist/node_modules/.pnpm/zod@3.24.2/node_modules/zod/lib/index.js.map +1 -1
- package/dist/presets/animation.js.map +1 -1
- package/dist/presets/faceset.js.map +1 -1
- package/dist/presets/icon.js.map +1 -1
- package/dist/presets/lpc.js.map +1 -1
- package/dist/presets/rmspritesheet.js.map +1 -1
- package/dist/services/AbstractSocket.js.map +1 -1
- package/dist/services/keyboardControls.js.map +1 -1
- package/dist/services/loadMap.d.ts +6 -0
- package/dist/services/loadMap.js +1 -1
- package/dist/services/loadMap.js.map +1 -1
- package/dist/services/mmorpg.js +1 -1
- package/dist/services/mmorpg.js.map +1 -1
- package/dist/services/save.js.map +1 -1
- package/dist/services/standalone.js +1 -1
- package/dist/services/standalone.js.map +1 -1
- package/dist/utils/getEntityProp.js.map +1 -1
- package/package.json +8 -8
- package/src/Game/AnimationManager.spec.ts +30 -0
- package/src/Game/AnimationManager.ts +22 -10
- package/src/Game/Map.ts +12 -2
- package/src/Game/Object.ts +68 -43
- package/src/Gui/Gui.spec.ts +273 -0
- package/src/Gui/Gui.ts +105 -50
- package/src/Resource.ts +1 -2
- package/src/RpgClient.ts +63 -2
- package/src/RpgClientEngine.ts +82 -12
- package/src/components/character.ce +353 -1
- package/src/components/dynamics/bar.ce +87 -0
- package/src/components/dynamics/image.ce +20 -0
- package/src/components/dynamics/parse-value.spec.ts +41 -0
- package/src/components/dynamics/parse-value.ts +102 -37
- package/src/components/dynamics/shape-utils.spec.ts +46 -0
- package/src/components/dynamics/shape-utils.ts +61 -0
- package/src/components/dynamics/shape.ce +89 -0
- package/src/components/dynamics/text.ce +34 -149
- package/src/components/player-components-utils.spec.ts +109 -0
- package/src/components/player-components-utils.ts +205 -0
- package/src/components/player-components.ce +221 -0
- package/src/core/setup.ts +2 -2
- package/src/module.ts +5 -1
- package/src/services/loadMap.ts +2 -0
- package/dist/node_modules/.pnpm/@signe_di@2.9.0/node_modules/@signe/di/dist/index.js.map +0 -1
- package/dist/node_modules/.pnpm/@signe_reactive@2.9.0/node_modules/@signe/reactive/dist/index.js +0 -463
- package/dist/node_modules/.pnpm/@signe_reactive@2.9.0/node_modules/@signe/reactive/dist/index.js.map +0 -1
- package/dist/node_modules/.pnpm/@signe_room@2.9.0/node_modules/@signe/room/dist/index.js +0 -2191
- package/dist/node_modules/.pnpm/@signe_room@2.9.0/node_modules/@signe/room/dist/index.js.map +0 -1
- package/dist/node_modules/.pnpm/@signe_sync@2.9.0/node_modules/@signe/sync/dist/chunk-7QVYU63E.js +0 -10
- package/dist/node_modules/.pnpm/@signe_sync@2.9.0/node_modules/@signe/sync/dist/chunk-7QVYU63E.js.map +0 -1
- package/dist/node_modules/.pnpm/@signe_sync@2.9.0/node_modules/@signe/sync/dist/client/index.js +0 -91
- package/dist/node_modules/.pnpm/@signe_sync@2.9.0/node_modules/@signe/sync/dist/client/index.js.map +0 -1
- package/dist/node_modules/.pnpm/@signe_sync@2.9.0/node_modules/@signe/sync/dist/index.js.map +0 -1
- package/dist/node_modules/.pnpm/dset@3.1.4/node_modules/dset/dist/index.js +0 -14
- package/dist/node_modules/.pnpm/dset@3.1.4/node_modules/dset/dist/index.js.map +0 -1
|
@@ -1,22 +1,14 @@
|
|
|
1
|
-
//#region ../../node_modules/.pnpm/@signe+di@2.
|
|
2
|
-
var __defProp = Object.defineProperty;
|
|
3
|
-
var __name = (target, value) => __defProp(target, "name", {
|
|
4
|
-
value,
|
|
5
|
-
configurable: true
|
|
6
|
-
});
|
|
1
|
+
//#region ../../node_modules/.pnpm/@signe+di@2.10.0/node_modules/@signe/di/dist/index.js
|
|
7
2
|
var DEFAULT_INSTANCE_KEY = "__default__";
|
|
8
3
|
function toTokenName(token) {
|
|
9
4
|
return typeof token === "function" ? token.name : token;
|
|
10
5
|
}
|
|
11
|
-
__name(toTokenName, "toTokenName");
|
|
12
6
|
function toInstanceKey(name) {
|
|
13
7
|
return name ?? DEFAULT_INSTANCE_KEY;
|
|
14
8
|
}
|
|
15
|
-
__name(toInstanceKey, "toInstanceKey");
|
|
16
9
|
function getRecord(context, token) {
|
|
17
10
|
return context.get("inject:" + toTokenName(token));
|
|
18
11
|
}
|
|
19
|
-
__name(getRecord, "getRecord");
|
|
20
12
|
function ensureRecord(context, token) {
|
|
21
13
|
const key = "inject:" + toTokenName(token);
|
|
22
14
|
let record = context.get(key);
|
|
@@ -28,7 +20,6 @@ function ensureRecord(context, token) {
|
|
|
28
20
|
context.set(key, record);
|
|
29
21
|
return record;
|
|
30
22
|
}
|
|
31
|
-
__name(ensureRecord, "ensureRecord");
|
|
32
23
|
function provide(context, token, value, options = {}) {
|
|
33
24
|
const record = ensureRecord(context, token);
|
|
34
25
|
const instanceKey = toInstanceKey(options.name);
|
|
@@ -37,41 +28,17 @@ function provide(context, token, value, options = {}) {
|
|
|
37
28
|
record.values.set(instanceKey, value);
|
|
38
29
|
return value;
|
|
39
30
|
}
|
|
40
|
-
__name(provide, "provide");
|
|
41
|
-
function isInjected(context, token, options = {}) {
|
|
42
|
-
const record = getRecord(context, token);
|
|
43
|
-
if (!record) return false;
|
|
44
|
-
if (options.name) return record.injected.has(toInstanceKey(options.name));
|
|
45
|
-
if (record.multi) return record.injected.size > 0;
|
|
46
|
-
return record.injected.has(DEFAULT_INSTANCE_KEY);
|
|
47
|
-
}
|
|
48
|
-
__name(isInjected, "isInjected");
|
|
49
|
-
function isProvided(context, token, options = {}) {
|
|
50
|
-
const record = getRecord(context, token);
|
|
51
|
-
if (!record) return false;
|
|
52
|
-
if (options.name) return record.values.has(toInstanceKey(options.name));
|
|
53
|
-
if (record.multi) return record.values.size > 0;
|
|
54
|
-
return record.values.has(DEFAULT_INSTANCE_KEY);
|
|
55
|
-
}
|
|
56
|
-
__name(isProvided, "isProvided");
|
|
57
|
-
function hasInstance(context, token, options = {}) {
|
|
58
|
-
return isProvided(context, token, options);
|
|
59
|
-
}
|
|
60
|
-
__name(hasInstance, "hasInstance");
|
|
61
31
|
function handleMissingInjection(token, options) {
|
|
62
32
|
const name = toTokenName(token);
|
|
63
33
|
if (options.name) throw new Error(`Injection provider ${name} with name ${options.name} not found`);
|
|
64
34
|
throw new Error(`Injection provider ${name} not found`);
|
|
65
35
|
}
|
|
66
|
-
__name(handleMissingInjection, "handleMissingInjection");
|
|
67
36
|
function markInjected(record, key) {
|
|
68
37
|
record.injected.add(key);
|
|
69
38
|
}
|
|
70
|
-
__name(markInjected, "markInjected");
|
|
71
39
|
function markAllInjected(record) {
|
|
72
40
|
for (const key of record.values.keys()) record.injected.add(key);
|
|
73
41
|
}
|
|
74
|
-
__name(markAllInjected, "markAllInjected");
|
|
75
42
|
function inject(context, token, options = {}) {
|
|
76
43
|
const record = getRecord(context, token);
|
|
77
44
|
if (!record) {
|
|
@@ -104,78 +71,6 @@ function inject(context, token, options = {}) {
|
|
|
104
71
|
markInjected(record, DEFAULT_INSTANCE_KEY);
|
|
105
72
|
return value;
|
|
106
73
|
}
|
|
107
|
-
__name(inject, "inject");
|
|
108
|
-
function override(providers, newProvider, options) {
|
|
109
|
-
let { upsert = false, key } = options ?? {};
|
|
110
|
-
if (!key) key = typeof newProvider === "function" ? newProvider.name : newProvider.provide;
|
|
111
|
-
const flatProviders = providers.flat();
|
|
112
|
-
const exists = flatProviders.some((provider) => {
|
|
113
|
-
if (typeof provider === "function") return provider.name === key;
|
|
114
|
-
else if (typeof provider === "object") return provider.provide === key;
|
|
115
|
-
return false;
|
|
116
|
-
});
|
|
117
|
-
const mappedProviders = flatProviders.map((provider) => {
|
|
118
|
-
if (typeof provider === "function" && provider.name === key) return newProvider;
|
|
119
|
-
else if (typeof provider === "object" && provider.provide === key) return newProvider;
|
|
120
|
-
return provider;
|
|
121
|
-
});
|
|
122
|
-
if (upsert && !exists) mappedProviders.push(newProvider);
|
|
123
|
-
return mappedProviders;
|
|
124
|
-
}
|
|
125
|
-
__name(override, "override");
|
|
126
|
-
function findProviders(providers, name) {
|
|
127
|
-
const results = [];
|
|
128
|
-
for (const provider of providers) if (Array.isArray(provider)) results.push(...findProviders(provider, name));
|
|
129
|
-
else if (findProvider(provider, name)) results.push(provider);
|
|
130
|
-
return results;
|
|
131
|
-
}
|
|
132
|
-
__name(findProviders, "findProviders");
|
|
133
|
-
function findProvider(providers, name) {
|
|
134
|
-
if (!Array.isArray(providers)) {
|
|
135
|
-
if (typeof providers === "object" && "provide" in providers) {
|
|
136
|
-
const provider = providers;
|
|
137
|
-
const providerName = typeof provider.provide === "function" ? provider.provide.name : provider.provide;
|
|
138
|
-
if (name instanceof RegExp) {
|
|
139
|
-
if (name.test(providerName)) return providers;
|
|
140
|
-
} else if (providerName === name) return providers;
|
|
141
|
-
}
|
|
142
|
-
return null;
|
|
143
|
-
}
|
|
144
|
-
for (const provider of providers) {
|
|
145
|
-
if (Array.isArray(provider)) {
|
|
146
|
-
const found = findProvider(provider, name);
|
|
147
|
-
if (found) return found;
|
|
148
|
-
continue;
|
|
149
|
-
}
|
|
150
|
-
if (typeof provider === "object" && "provide" in provider) {
|
|
151
|
-
const providerName = typeof provider.provide === "function" ? provider.provide.name : provider.provide;
|
|
152
|
-
if (name instanceof RegExp) {
|
|
153
|
-
if (name.test(providerName)) return provider;
|
|
154
|
-
} else if (providerName === name) return provider;
|
|
155
|
-
}
|
|
156
|
-
}
|
|
157
|
-
return null;
|
|
158
|
-
}
|
|
159
|
-
__name(findProvider, "findProvider");
|
|
160
|
-
function processProvider(mergedConfig, baseConfig, provider) {
|
|
161
|
-
if (Array.isArray(provider)) {
|
|
162
|
-
for (const nestedProvider of provider) processProvider(mergedConfig, baseConfig, nestedProvider);
|
|
163
|
-
return;
|
|
164
|
-
}
|
|
165
|
-
if (findProvider(baseConfig.providers, provider.provide)) mergedConfig.providers = override(mergedConfig.providers, provider);
|
|
166
|
-
else mergedConfig.providers.push(provider);
|
|
167
|
-
}
|
|
168
|
-
__name(processProvider, "processProvider");
|
|
169
|
-
function mergeConfig(baseConfig, config) {
|
|
170
|
-
const mergedConfig = {
|
|
171
|
-
...baseConfig,
|
|
172
|
-
...config,
|
|
173
|
-
providers: [...baseConfig.providers]
|
|
174
|
-
};
|
|
175
|
-
for (const provider of config.providers) processProvider(mergedConfig, baseConfig, provider);
|
|
176
|
-
return mergedConfig;
|
|
177
|
-
}
|
|
178
|
-
__name(mergeConfig, "mergeConfig");
|
|
179
74
|
function extractProvideOptions(source) {
|
|
180
75
|
if (!source) return;
|
|
181
76
|
const { multi, name } = source;
|
|
@@ -185,14 +80,12 @@ function extractProvideOptions(source) {
|
|
|
185
80
|
name
|
|
186
81
|
};
|
|
187
82
|
}
|
|
188
|
-
__name(extractProvideOptions, "extractProvideOptions");
|
|
189
83
|
function getDeps(provider) {
|
|
190
84
|
if (typeof provider === "function") return provider.deps ?? [];
|
|
191
85
|
return provider.deps ?? [];
|
|
192
86
|
}
|
|
193
|
-
__name(getDeps, "getDeps");
|
|
194
87
|
function sortProviders(providers) {
|
|
195
|
-
const tokenName =
|
|
88
|
+
const tokenName = (t) => typeof t === "function" ? t.name : t;
|
|
196
89
|
const map = /* @__PURE__ */ new Map();
|
|
197
90
|
for (const p of providers) {
|
|
198
91
|
const token = tokenName(typeof p === "function" ? p : p.provide);
|
|
@@ -203,7 +96,7 @@ function sortProviders(providers) {
|
|
|
203
96
|
const result = [];
|
|
204
97
|
const visited = /* @__PURE__ */ new Set();
|
|
205
98
|
const stack = /* @__PURE__ */ new Set();
|
|
206
|
-
const visit =
|
|
99
|
+
const visit = (token) => {
|
|
207
100
|
const name = tokenName(token);
|
|
208
101
|
if (visited.has(name)) return;
|
|
209
102
|
if (stack.has(name)) throw new Error(`Circular dependency detected for provider ${name}`);
|
|
@@ -217,11 +110,10 @@ function sortProviders(providers) {
|
|
|
217
110
|
visited.add(name);
|
|
218
111
|
}
|
|
219
112
|
stack.delete(name);
|
|
220
|
-
}
|
|
113
|
+
};
|
|
221
114
|
for (const p of providers) visit(typeof p === "function" ? p : p.provide);
|
|
222
115
|
return result;
|
|
223
116
|
}
|
|
224
|
-
__name(sortProviders, "sortProviders");
|
|
225
117
|
async function injector(context, providers) {
|
|
226
118
|
providers = providers.flat();
|
|
227
119
|
providers = sortProviders(providers);
|
|
@@ -247,13 +139,11 @@ async function injector(context, providers) {
|
|
|
247
139
|
provide(context, token, instance, options);
|
|
248
140
|
}
|
|
249
141
|
}
|
|
250
|
-
__name(injector, "injector");
|
|
251
142
|
var Context = class {
|
|
252
|
-
|
|
253
|
-
|
|
143
|
+
constructor() {
|
|
144
|
+
/** Internal storage for injected values */
|
|
145
|
+
this.values = {};
|
|
254
146
|
}
|
|
255
|
-
/** Internal storage for injected values */
|
|
256
|
-
values = {};
|
|
257
147
|
/**
|
|
258
148
|
* Sets a value in the context
|
|
259
149
|
* @param key - Unique identifier for the value
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","names":[],"sources":["../../../../../../../../../../node_modules/.pnpm/@signe+di@2.10.0/node_modules/@signe/di/dist/index.js"],"sourcesContent":["// src/inject.ts\nvar DEFAULT_INSTANCE_KEY = \"__default__\";\nfunction toTokenName(token) {\n return typeof token === \"function\" ? token.name : token;\n}\nfunction toInstanceKey(name) {\n return name ?? DEFAULT_INSTANCE_KEY;\n}\nfunction getRecord(context, token) {\n return context.get(\"inject:\" + toTokenName(token));\n}\nfunction ensureRecord(context, token) {\n const key = \"inject:\" + toTokenName(token);\n let record = context.get(key);\n if (!record) {\n record = {\n multi: false,\n values: /* @__PURE__ */ new Map(),\n injected: /* @__PURE__ */ new Set()\n };\n }\n context.set(key, record);\n return record;\n}\nfunction provide(context, token, value, options = {}) {\n const record = ensureRecord(context, token);\n const instanceKey = toInstanceKey(options.name);\n if (options.multi) {\n record.multi = true;\n }\n if (!record.multi && instanceKey !== DEFAULT_INSTANCE_KEY) {\n record.multi = true;\n }\n record.values.set(instanceKey, value);\n return value;\n}\nfunction isInjected(context, token, options = {}) {\n const record = getRecord(context, token);\n if (!record) {\n return false;\n }\n if (options.name) {\n return record.injected.has(toInstanceKey(options.name));\n }\n if (record.multi) {\n return record.injected.size > 0;\n }\n return record.injected.has(DEFAULT_INSTANCE_KEY);\n}\nfunction isProvided(context, token, options = {}) {\n const record = getRecord(context, token);\n if (!record) {\n return false;\n }\n if (options.name) {\n return record.values.has(toInstanceKey(options.name));\n }\n if (record.multi) {\n return record.values.size > 0;\n }\n return record.values.has(DEFAULT_INSTANCE_KEY);\n}\nfunction hasInstance(context, token, options = {}) {\n return isProvided(context, token, options);\n}\nfunction handleMissingInjection(token, options) {\n const name = toTokenName(token);\n if (options.name) {\n throw new Error(`Injection provider ${name} with name ${options.name} not found`);\n }\n throw new Error(`Injection provider ${name} not found`);\n}\nfunction markInjected(record, key) {\n record.injected.add(key);\n}\nfunction markAllInjected(record) {\n for (const key of record.values.keys()) {\n record.injected.add(key);\n }\n}\nfunction inject(context, token, options = {}) {\n const record = getRecord(context, token);\n if (!record) {\n if (options.optional) {\n return options.multi ? [] : void 0;\n }\n return handleMissingInjection(token, options);\n }\n if (options.name) {\n const instanceKey = toInstanceKey(options.name);\n if (!record.values.has(instanceKey)) {\n if (options.optional) {\n return void 0;\n }\n return handleMissingInjection(token, options);\n }\n const value2 = record.values.get(instanceKey);\n markInjected(record, instanceKey);\n return value2;\n }\n if (options.multi || record.multi) {\n if (record.values.size === 0) {\n if (options.optional) {\n return [];\n }\n return handleMissingInjection(token, options);\n }\n markAllInjected(record);\n return Array.from(record.values.values());\n }\n const value = record.values.get(DEFAULT_INSTANCE_KEY);\n if (value === void 0) {\n if (options.optional) {\n return void 0;\n }\n return handleMissingInjection(token, options);\n }\n markInjected(record, DEFAULT_INSTANCE_KEY);\n return value;\n}\nfunction override(providers, newProvider, options) {\n let { upsert = false, key } = options ?? {};\n if (!key) {\n key = typeof newProvider === \"function\" ? newProvider.name : newProvider.provide;\n }\n const flatProviders = providers.flat();\n const exists = flatProviders.some((provider) => {\n if (typeof provider === \"function\") {\n return provider.name === key;\n } else if (typeof provider === \"object\") {\n return provider.provide === key;\n }\n return false;\n });\n const mappedProviders = flatProviders.map((provider) => {\n if (typeof provider === \"function\" && provider.name === key) {\n return newProvider;\n } else if (typeof provider === \"object\" && provider.provide === key) {\n return newProvider;\n }\n return provider;\n });\n if (upsert && !exists) {\n mappedProviders.push(newProvider);\n }\n return mappedProviders;\n}\nfunction findProviders(providers, name) {\n const results = [];\n for (const provider of providers) {\n if (Array.isArray(provider)) {\n results.push(...findProviders(provider, name));\n } else if (findProvider(provider, name)) {\n results.push(provider);\n }\n }\n return results;\n}\nfunction findProvider(providers, name) {\n if (!Array.isArray(providers)) {\n if (typeof providers === \"object\" && \"provide\" in providers) {\n const provider = providers;\n const providerName = typeof provider.provide === \"function\" ? provider.provide.name : provider.provide;\n if (name instanceof RegExp) {\n if (name.test(providerName)) return providers;\n } else {\n if (providerName === name) return providers;\n }\n }\n return null;\n }\n for (const provider of providers) {\n if (Array.isArray(provider)) {\n const found = findProvider(provider, name);\n if (found) return found;\n continue;\n }\n if (typeof provider === \"object\" && \"provide\" in provider) {\n const providerName = typeof provider.provide === \"function\" ? provider.provide.name : provider.provide;\n if (name instanceof RegExp) {\n if (name.test(providerName)) return provider;\n } else {\n if (providerName === name) return provider;\n }\n }\n }\n return null;\n}\n\n// src/merge-config.ts\nfunction processProvider(mergedConfig, baseConfig, provider) {\n if (Array.isArray(provider)) {\n for (const nestedProvider of provider) {\n processProvider(mergedConfig, baseConfig, nestedProvider);\n }\n return;\n }\n const existingProvider = findProvider(baseConfig.providers, provider.provide);\n if (existingProvider) {\n mergedConfig.providers = override(mergedConfig.providers, provider);\n } else {\n mergedConfig.providers.push(provider);\n }\n}\nfunction mergeConfig(baseConfig, config) {\n const mergedConfig = {\n ...baseConfig,\n ...config,\n providers: [...baseConfig.providers]\n // Start with a copy of base providers\n };\n for (const provider of config.providers) {\n processProvider(mergedConfig, baseConfig, provider);\n }\n return mergedConfig;\n}\n\n// src/provider.ts\nfunction extractProvideOptions(source) {\n if (!source) {\n return void 0;\n }\n const { multi, name } = source;\n if (multi === void 0 && name === void 0) {\n return void 0;\n }\n return { multi, name };\n}\nfunction getDeps(provider) {\n if (typeof provider === \"function\") {\n return provider.deps ?? [];\n }\n return provider.deps ?? [];\n}\nfunction sortProviders(providers) {\n const tokenName = (t) => typeof t === \"function\" ? t.name : t;\n const map = /* @__PURE__ */ new Map();\n for (const p of providers) {\n const token = tokenName(typeof p === \"function\" ? p : p.provide);\n const list = map.get(token);\n if (list) {\n list.push(p);\n } else {\n map.set(token, [p]);\n }\n }\n const result = [];\n const visited = /* @__PURE__ */ new Set();\n const stack = /* @__PURE__ */ new Set();\n const visit = (token) => {\n const name = tokenName(token);\n if (visited.has(name)) return;\n if (stack.has(name)) {\n throw new Error(`Circular dependency detected for provider ${name}`);\n }\n stack.add(name);\n const providersForToken = map.get(name);\n if (providersForToken) {\n for (const provider of providersForToken) {\n for (const dep of getDeps(provider)) {\n visit(dep);\n }\n result.push(provider);\n }\n visited.add(name);\n }\n stack.delete(name);\n };\n for (const p of providers) {\n const token = typeof p === \"function\" ? p : p.provide;\n visit(token);\n }\n return result;\n}\nasync function injector(context, providers) {\n providers = providers.flat();\n providers = sortProviders(providers);\n for (const provider of providers) {\n let token;\n let instance;\n let options;\n if (typeof provider === \"function\") {\n token = provider;\n instance = new provider(context);\n const diOptions = extractProvideOptions(provider.diOptions ?? provider.di);\n options = diOptions;\n } else {\n token = provider.provide;\n options = extractProvideOptions(provider);\n const provideUserClass = provider.useClass;\n const isClass = typeof provideUserClass === \"function\";\n if (isClass) {\n instance = new provideUserClass(context);\n } else if (\"useValue\" in provider) {\n instance = provider.useValue;\n } else if (\"useFactory\" in provider) {\n instance = provider.useFactory?.(context);\n if (instance instanceof Promise) {\n instance = await instance;\n }\n } else if (\"useExisting\" in provider) {\n instance = inject(context, provider.useExisting);\n }\n }\n provide(context, token, instance, options);\n }\n}\n\n// src/context.ts\nvar Context = class {\n constructor() {\n /** Internal storage for injected values */\n this.values = {};\n }\n /**\n * Sets a value in the context\n * @param key - Unique identifier for the value\n * @param value - Value to store\n */\n set(key, value) {\n this.values[key] = value;\n }\n /**\n * Retrieves a value from the context\n * @param key - Unique identifier for the value\n * @returns The stored value or undefined if not found\n */\n get(key) {\n return this.values[key];\n }\n};\nexport {\n Context,\n findProvider,\n findProviders,\n hasInstance,\n inject,\n injector,\n isInjected,\n isProvided,\n mergeConfig,\n override,\n provide\n};\n//# sourceMapping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oBAAoB,SACtB,WAAW,MAAM;UAEd,IAAI,iBAAiB,UAC1B,WAAW,OAAO,SAAS,SAAS,YAAY;;EAGpD,QAAQ,SAAS,OAAO,UAAU,QAAQ;;;AAK9C,IAAI,UAAU,MAAM;CAClB,cAAc;;EAEZ,KAAK,SAAS,EAAE;;;;;;;CAOlB,IAAI,KAAK,OAAO;EACd,KAAK,OAAO,OAAO;;;;;;;CAOrB,IAAI,KAAK;EACP,OAAO,KAAK,OAAO"}
|
package/dist/node_modules/.pnpm/@signe_reactive@2.10.0/node_modules/@signe/reactive/dist/index.js
ADDED
|
@@ -0,0 +1,239 @@
|
|
|
1
|
+
import { BehaviorSubject, filter } from "rxjs";
|
|
2
|
+
//#region ../../node_modules/.pnpm/@signe+reactive@2.10.0/node_modules/@signe/reactive/dist/index.js
|
|
3
|
+
var ArraySubject = class extends BehaviorSubject {
|
|
4
|
+
constructor(items = []) {
|
|
5
|
+
super({
|
|
6
|
+
type: "init",
|
|
7
|
+
items
|
|
8
|
+
});
|
|
9
|
+
this._items = [];
|
|
10
|
+
this.createProxy(items);
|
|
11
|
+
}
|
|
12
|
+
createProxy(items) {
|
|
13
|
+
this._items = new Proxy(items, {
|
|
14
|
+
get: (target, prop, receiver) => {
|
|
15
|
+
const origMethod = target[prop];
|
|
16
|
+
if (typeof origMethod === "function") return (...args) => {
|
|
17
|
+
let changeType = "update";
|
|
18
|
+
let index = void 0;
|
|
19
|
+
let isMutateFn = false;
|
|
20
|
+
let itemsToEmit = [];
|
|
21
|
+
let changeSplice = true;
|
|
22
|
+
switch (prop) {
|
|
23
|
+
case "push":
|
|
24
|
+
index = target.length;
|
|
25
|
+
changeType = "add";
|
|
26
|
+
isMutateFn = true;
|
|
27
|
+
break;
|
|
28
|
+
case "pop":
|
|
29
|
+
index = target.length - 1;
|
|
30
|
+
changeType = "remove";
|
|
31
|
+
isMutateFn = true;
|
|
32
|
+
break;
|
|
33
|
+
case "unshift":
|
|
34
|
+
index = 0;
|
|
35
|
+
changeType = "add";
|
|
36
|
+
isMutateFn = true;
|
|
37
|
+
break;
|
|
38
|
+
case "shift":
|
|
39
|
+
index = 0;
|
|
40
|
+
changeType = "remove";
|
|
41
|
+
isMutateFn = true;
|
|
42
|
+
break;
|
|
43
|
+
case "splice":
|
|
44
|
+
index = args[0];
|
|
45
|
+
const deleteCount = args[1];
|
|
46
|
+
const newItems = args.slice(2);
|
|
47
|
+
itemsToEmit = newItems;
|
|
48
|
+
if (deleteCount > 0 && newItems.length === 0) changeType = "remove";
|
|
49
|
+
else if (deleteCount === 0 && newItems.length > 0) changeType = "add";
|
|
50
|
+
else if (deleteCount === 0 && newItems.length === 0) changeSplice = false;
|
|
51
|
+
else changeType = "update";
|
|
52
|
+
isMutateFn = true;
|
|
53
|
+
break;
|
|
54
|
+
}
|
|
55
|
+
const result = origMethod.apply(target, args);
|
|
56
|
+
if (isMutateFn && changeSplice) if (prop === "splice") this.next({
|
|
57
|
+
type: changeType,
|
|
58
|
+
index,
|
|
59
|
+
items: itemsToEmit
|
|
60
|
+
});
|
|
61
|
+
else this.next({
|
|
62
|
+
type: changeType,
|
|
63
|
+
index,
|
|
64
|
+
items: args
|
|
65
|
+
});
|
|
66
|
+
return result;
|
|
67
|
+
};
|
|
68
|
+
return Reflect.get(target, prop, receiver);
|
|
69
|
+
},
|
|
70
|
+
set: (target, prop, value) => {
|
|
71
|
+
const index = !isNaN(Number(prop)) ? Number(prop) : void 0;
|
|
72
|
+
target[prop] = value;
|
|
73
|
+
this.next({
|
|
74
|
+
type: "update",
|
|
75
|
+
index,
|
|
76
|
+
items: [value]
|
|
77
|
+
});
|
|
78
|
+
return true;
|
|
79
|
+
}
|
|
80
|
+
});
|
|
81
|
+
}
|
|
82
|
+
get items() {
|
|
83
|
+
return this._items;
|
|
84
|
+
}
|
|
85
|
+
set items(newItems) {
|
|
86
|
+
this.createProxy(newItems);
|
|
87
|
+
this.next({
|
|
88
|
+
type: "reset",
|
|
89
|
+
items: newItems
|
|
90
|
+
});
|
|
91
|
+
}
|
|
92
|
+
};
|
|
93
|
+
var isArraySubject = (value) => {
|
|
94
|
+
return "_items" in value;
|
|
95
|
+
};
|
|
96
|
+
var ObjectSubject = class extends BehaviorSubject {
|
|
97
|
+
constructor(obj = {}) {
|
|
98
|
+
super({
|
|
99
|
+
type: "init",
|
|
100
|
+
value: obj
|
|
101
|
+
});
|
|
102
|
+
this.createProxy(obj);
|
|
103
|
+
}
|
|
104
|
+
createProxy(obj) {
|
|
105
|
+
this._obj = new Proxy(obj, {
|
|
106
|
+
get: (target, prop, receiver) => {
|
|
107
|
+
return Reflect.get(target, prop, receiver);
|
|
108
|
+
},
|
|
109
|
+
set: (target, prop, value, receiver) => {
|
|
110
|
+
const key = prop;
|
|
111
|
+
const changeType = key in target ? "update" : "add";
|
|
112
|
+
target[key] = value;
|
|
113
|
+
this.next({
|
|
114
|
+
type: changeType,
|
|
115
|
+
key,
|
|
116
|
+
value
|
|
117
|
+
});
|
|
118
|
+
return true;
|
|
119
|
+
},
|
|
120
|
+
deleteProperty: (target, prop) => {
|
|
121
|
+
const key = prop;
|
|
122
|
+
if (key in target) {
|
|
123
|
+
const value = target[key];
|
|
124
|
+
delete target[key];
|
|
125
|
+
this.next({
|
|
126
|
+
type: "remove",
|
|
127
|
+
key,
|
|
128
|
+
value
|
|
129
|
+
});
|
|
130
|
+
return true;
|
|
131
|
+
}
|
|
132
|
+
return false;
|
|
133
|
+
}
|
|
134
|
+
});
|
|
135
|
+
}
|
|
136
|
+
get obj() {
|
|
137
|
+
return this._obj;
|
|
138
|
+
}
|
|
139
|
+
set obj(newObj) {
|
|
140
|
+
this.createProxy(newObj);
|
|
141
|
+
this.next({
|
|
142
|
+
type: "reset",
|
|
143
|
+
value: newObj
|
|
144
|
+
});
|
|
145
|
+
}
|
|
146
|
+
};
|
|
147
|
+
var isObjectSubject = (value) => {
|
|
148
|
+
return "_obj" in value;
|
|
149
|
+
};
|
|
150
|
+
var getGlobalReactiveStore = () => {
|
|
151
|
+
const globalKey = "__REACTIVE_STORE__";
|
|
152
|
+
if (typeof globalThis !== "undefined") {
|
|
153
|
+
if (!globalThis[globalKey]) globalThis[globalKey] = {
|
|
154
|
+
currentDependencyTracker: null,
|
|
155
|
+
currentSubscriptionsTracker: null
|
|
156
|
+
};
|
|
157
|
+
return globalThis[globalKey];
|
|
158
|
+
}
|
|
159
|
+
let globalObj;
|
|
160
|
+
if (typeof window !== "undefined") globalObj = window;
|
|
161
|
+
else if (typeof process !== "undefined" && process.versions && process.versions.node) globalObj = Function("return this")();
|
|
162
|
+
else if (typeof self !== "undefined") globalObj = self;
|
|
163
|
+
else {
|
|
164
|
+
console.warn("Unable to find global object, using local instance");
|
|
165
|
+
return {
|
|
166
|
+
currentDependencyTracker: null,
|
|
167
|
+
currentSubscriptionsTracker: null
|
|
168
|
+
};
|
|
169
|
+
}
|
|
170
|
+
if (!globalObj[globalKey]) globalObj[globalKey] = {
|
|
171
|
+
currentDependencyTracker: null,
|
|
172
|
+
currentSubscriptionsTracker: null
|
|
173
|
+
};
|
|
174
|
+
return globalObj[globalKey];
|
|
175
|
+
};
|
|
176
|
+
var reactiveStore = getGlobalReactiveStore();
|
|
177
|
+
var trackDependency = (signal2) => {
|
|
178
|
+
if (reactiveStore.currentDependencyTracker) reactiveStore.currentDependencyTracker(signal2);
|
|
179
|
+
};
|
|
180
|
+
function signal(defaultValue, options) {
|
|
181
|
+
let subject;
|
|
182
|
+
if (Array.isArray(defaultValue)) subject = new ArraySubject(defaultValue);
|
|
183
|
+
else if (typeof defaultValue === "object" && defaultValue !== null) subject = new ObjectSubject(defaultValue);
|
|
184
|
+
else subject = new BehaviorSubject(defaultValue);
|
|
185
|
+
const getValue = () => {
|
|
186
|
+
if (subject instanceof ArraySubject) return subject.items;
|
|
187
|
+
else if (subject instanceof ObjectSubject) return subject.obj;
|
|
188
|
+
return subject.value;
|
|
189
|
+
};
|
|
190
|
+
const fn = function() {
|
|
191
|
+
trackDependency(fn);
|
|
192
|
+
return getValue();
|
|
193
|
+
};
|
|
194
|
+
fn.set = (value) => {
|
|
195
|
+
const currentValue = getValue();
|
|
196
|
+
let shouldEmit = true;
|
|
197
|
+
if (options?.equal) shouldEmit = !options.equal(currentValue, value);
|
|
198
|
+
else shouldEmit = currentValue !== value;
|
|
199
|
+
if (shouldEmit) if (subject instanceof ArraySubject) subject.items = value;
|
|
200
|
+
else if (subject instanceof ObjectSubject) subject.obj = value;
|
|
201
|
+
else subject.next(value);
|
|
202
|
+
};
|
|
203
|
+
fn._isFrozen = false;
|
|
204
|
+
fn.freeze = () => {
|
|
205
|
+
fn._isFrozen = true;
|
|
206
|
+
};
|
|
207
|
+
fn.unfreeze = () => {
|
|
208
|
+
fn._isFrozen = false;
|
|
209
|
+
if (subject instanceof ArraySubject) subject.next({
|
|
210
|
+
type: "init",
|
|
211
|
+
items: subject.items
|
|
212
|
+
});
|
|
213
|
+
else if (subject instanceof ObjectSubject) subject.next({
|
|
214
|
+
type: "init",
|
|
215
|
+
value: subject.obj
|
|
216
|
+
});
|
|
217
|
+
else subject.next(subject.value);
|
|
218
|
+
};
|
|
219
|
+
fn.mutate = (mutateFn) => {
|
|
220
|
+
mutateFn(getValue());
|
|
221
|
+
};
|
|
222
|
+
fn.update = (updateFn) => {
|
|
223
|
+
const updatedValue = updateFn(getValue());
|
|
224
|
+
fn.set(updatedValue);
|
|
225
|
+
};
|
|
226
|
+
fn.observable = subject.asObservable().pipe(filter(() => !fn._isFrozen));
|
|
227
|
+
fn._subject = subject;
|
|
228
|
+
return fn;
|
|
229
|
+
}
|
|
230
|
+
function isSignal(value) {
|
|
231
|
+
return !!(value && value.observable);
|
|
232
|
+
}
|
|
233
|
+
function isComputed(value) {
|
|
234
|
+
return isSignal(value) && !!value.dependencies;
|
|
235
|
+
}
|
|
236
|
+
//#endregion
|
|
237
|
+
export { isArraySubject, isComputed, isObjectSubject, isSignal, signal };
|
|
238
|
+
|
|
239
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","names":["BehaviorSubject2","BehaviorSubject3"],"sources":["../../../../../../../../../../node_modules/.pnpm/@signe+reactive@2.10.0/node_modules/@signe/reactive/dist/index.js"],"sourcesContent":["// src/ArraySubject.ts\nimport { BehaviorSubject } from \"rxjs\";\nvar ArraySubject = class extends BehaviorSubject {\n constructor(items = []) {\n super({ type: \"init\", items });\n this._items = [];\n this.createProxy(items);\n }\n createProxy(items) {\n this._items = new Proxy(items, {\n get: (target, prop, receiver) => {\n const origMethod = target[prop];\n if (typeof origMethod === \"function\") {\n return (...args) => {\n let changeType = \"update\";\n let index = void 0;\n let isMutateFn = false;\n let itemsToEmit = [];\n let changeSplice = true;\n switch (prop) {\n case \"push\":\n index = target.length;\n changeType = \"add\";\n isMutateFn = true;\n break;\n case \"pop\":\n index = target.length - 1;\n changeType = \"remove\";\n isMutateFn = true;\n break;\n case \"unshift\":\n index = 0;\n changeType = \"add\";\n isMutateFn = true;\n break;\n case \"shift\":\n index = 0;\n changeType = \"remove\";\n isMutateFn = true;\n break;\n case \"splice\":\n index = args[0];\n const deleteCount = args[1];\n const newItems = args.slice(2);\n itemsToEmit = newItems;\n if (deleteCount > 0 && newItems.length === 0) {\n changeType = \"remove\";\n } else if (deleteCount === 0 && newItems.length > 0) {\n changeType = \"add\";\n } else if (deleteCount === 0 && newItems.length === 0) {\n changeSplice = false;\n } else {\n changeType = \"update\";\n }\n isMutateFn = true;\n break;\n }\n const result = origMethod.apply(target, args);\n if (isMutateFn && changeSplice) {\n if (prop === \"splice\") {\n this.next({ type: changeType, index, items: itemsToEmit });\n } else {\n this.next({ type: changeType, index, items: args });\n }\n }\n return result;\n };\n }\n return Reflect.get(target, prop, receiver);\n },\n set: (target, prop, value) => {\n const index = !isNaN(Number(prop)) ? Number(prop) : void 0;\n target[prop] = value;\n this.next({ type: \"update\", index, items: [value] });\n return true;\n }\n });\n }\n get items() {\n return this._items;\n }\n set items(newItems) {\n this.createProxy(newItems);\n this.next({ type: \"reset\", items: newItems });\n }\n};\nvar isArraySubject = (value) => {\n return \"_items\" in value;\n};\n\n// src/ObjectSubject.ts\nimport { BehaviorSubject as BehaviorSubject2 } from \"rxjs\";\nvar ObjectSubject = class extends BehaviorSubject2 {\n constructor(obj = {}) {\n super({ type: \"init\", value: obj });\n this.createProxy(obj);\n }\n createProxy(obj) {\n this._obj = new Proxy(obj, {\n get: (target, prop, receiver) => {\n return Reflect.get(target, prop, receiver);\n },\n set: (target, prop, value, receiver) => {\n const key = prop;\n const changeType = key in target ? \"update\" : \"add\";\n target[key] = value;\n this.next({ type: changeType, key, value });\n return true;\n },\n deleteProperty: (target, prop) => {\n const key = prop;\n if (key in target) {\n const value = target[key];\n delete target[key];\n this.next({ type: \"remove\", key, value });\n return true;\n }\n return false;\n }\n });\n }\n get obj() {\n return this._obj;\n }\n set obj(newObj) {\n this.createProxy(newObj);\n this.next({ type: \"reset\", value: newObj });\n }\n};\nvar isObjectSubject = (value) => {\n return \"_obj\" in value;\n};\n\n// src/signal.ts\nimport { BehaviorSubject as BehaviorSubject3, combineLatest, filter, finalize, map, Observable } from \"rxjs\";\nvar getGlobalReactiveStore = () => {\n const globalKey = \"__REACTIVE_STORE__\";\n if (typeof globalThis !== \"undefined\") {\n if (!globalThis[globalKey]) {\n globalThis[globalKey] = {\n currentDependencyTracker: null,\n currentSubscriptionsTracker: null\n };\n }\n return globalThis[globalKey];\n }\n let globalObj;\n if (typeof window !== \"undefined\") {\n globalObj = window;\n } else if (typeof process !== \"undefined\" && process.versions && process.versions.node) {\n globalObj = Function(\"return this\")();\n } else if (typeof self !== \"undefined\") {\n globalObj = self;\n } else {\n console.warn(\"Unable to find global object, using local instance\");\n return {\n currentDependencyTracker: null,\n currentSubscriptionsTracker: null\n };\n }\n if (!globalObj[globalKey]) {\n globalObj[globalKey] = {\n currentDependencyTracker: null,\n currentSubscriptionsTracker: null\n };\n }\n return globalObj[globalKey];\n};\nvar reactiveStore = getGlobalReactiveStore();\nvar trackDependency = (signal2) => {\n if (reactiveStore.currentDependencyTracker) {\n reactiveStore.currentDependencyTracker(signal2);\n }\n};\nfunction signal(defaultValue, options) {\n let subject;\n if (Array.isArray(defaultValue)) {\n subject = new ArraySubject(defaultValue);\n } else if (typeof defaultValue === \"object\" && defaultValue !== null) {\n subject = new ObjectSubject(defaultValue);\n } else {\n subject = new BehaviorSubject3(defaultValue);\n }\n const getValue = () => {\n if (subject instanceof ArraySubject) {\n return subject.items;\n } else if (subject instanceof ObjectSubject) {\n return subject.obj;\n }\n return subject.value;\n };\n const fn = function() {\n trackDependency(fn);\n return getValue();\n };\n fn.set = (value) => {\n const currentValue = getValue();\n let shouldEmit = true;\n if (options?.equal) {\n shouldEmit = !options.equal(currentValue, value);\n } else {\n shouldEmit = currentValue !== value;\n }\n if (shouldEmit) {\n if (subject instanceof ArraySubject) {\n subject.items = value;\n } else if (subject instanceof ObjectSubject) {\n subject.obj = value;\n } else {\n subject.next(value);\n }\n }\n };\n fn._isFrozen = false;\n fn.freeze = () => {\n fn._isFrozen = true;\n };\n fn.unfreeze = () => {\n fn._isFrozen = false;\n if (subject instanceof ArraySubject) {\n subject.next({ type: \"init\", items: subject.items });\n } else if (subject instanceof ObjectSubject) {\n subject.next({ type: \"init\", value: subject.obj });\n } else {\n subject.next(subject.value);\n }\n };\n fn.mutate = (mutateFn) => {\n const value = getValue();\n mutateFn(value);\n };\n fn.update = (updateFn) => {\n const updatedValue = updateFn(getValue());\n fn.set(updatedValue);\n };\n fn.observable = subject.asObservable().pipe(\n filter(() => !fn._isFrozen)\n );\n fn._subject = subject;\n return fn;\n}\nfunction isSignal(value) {\n return !!(value && value.observable);\n}\nfunction isComputed(value) {\n return isSignal(value) && !!value.dependencies;\n}\nfunction computed(computeFunction, disposableFn) {\n const dependencies = /* @__PURE__ */ new Set();\n let init = true;\n let lastComputedValue;\n const previousTracker = reactiveStore.currentDependencyTracker;\n reactiveStore.currentDependencyTracker = (signal2) => {\n dependencies.add(signal2);\n };\n lastComputedValue = computeFunction();\n if (computeFunction[\"isEffect\"]) {\n disposableFn = lastComputedValue;\n }\n reactiveStore.currentDependencyTracker = previousTracker;\n const observables = [...dependencies].map((dep) => {\n if (isComputed(dep) && \"dependencies\" in dep) {\n const computedDep = dep;\n if (computedDep.dependencies.size === 0) {\n return new BehaviorSubject3(computedDep()).asObservable();\n }\n }\n return dep.observable;\n });\n const computedObservable = combineLatest(observables).pipe(\n filter(() => !init),\n map(() => computeFunction()),\n finalize(() => disposableFn?.())\n );\n const fn = function() {\n trackDependency(fn);\n return lastComputedValue;\n };\n fn.observable = computedObservable;\n fn.subscription = computedObservable.subscribe((value) => {\n lastComputedValue = value;\n });\n fn.dependencies = dependencies;\n reactiveStore.currentSubscriptionsTracker?.(fn.subscription);\n init = false;\n return fn;\n}\nfunction linkedSignal(computationOrOptions, simpleOptions) {\n const dependencies = /* @__PURE__ */ new Set();\n let init = true;\n let lastComputedValue;\n let computeFunction;\n let sourceSignal;\n let computationFn;\n let equalFn;\n let previousValue;\n let isOverridden = false;\n let overriddenValue;\n let lastComputedBeforeOverride;\n let depVersion = 0;\n let overrideDepVersion = null;\n if (typeof computationOrOptions === \"function\") {\n computeFunction = computationOrOptions;\n equalFn = simpleOptions?.equal;\n } else {\n const options = computationOrOptions;\n sourceSignal = options.source;\n computationFn = options.computation;\n equalFn = options.equal;\n if (typeof sourceSignal === \"function\" && !isSignal(sourceSignal)) {\n const sourceFn = sourceSignal;\n computeFunction = () => {\n const sourceValue = sourceFn();\n if (computationFn.length > 1) {\n const result = computationFn(sourceValue, previousValue);\n previousValue = {\n source: sourceValue,\n value: result\n };\n return result;\n } else {\n const result = computationFn(sourceValue);\n previousValue = {\n source: sourceValue,\n value: result\n };\n return result;\n }\n };\n } else {\n const source = typeof sourceSignal === \"function\" ? sourceSignal : sourceSignal;\n computeFunction = () => {\n const sourceValue = source();\n if (computationFn.length > 1) {\n const result = computationFn(sourceValue, previousValue);\n previousValue = {\n source: sourceValue,\n value: result\n };\n return result;\n } else {\n const result = computationFn(sourceValue);\n previousValue = {\n source: sourceValue,\n value: result\n };\n return result;\n }\n };\n }\n }\n const previousTracker = reactiveStore.currentDependencyTracker;\n reactiveStore.currentDependencyTracker = (signal2) => {\n dependencies.add(signal2);\n };\n if (sourceSignal && typeof sourceSignal === \"function\" && !isSignal(sourceSignal)) {\n lastComputedValue = computeFunction();\n lastComputedBeforeOverride = lastComputedValue;\n } else if (sourceSignal && isSignal(sourceSignal)) {\n dependencies.add(sourceSignal);\n lastComputedValue = computeFunction();\n lastComputedBeforeOverride = lastComputedValue;\n } else {\n lastComputedValue = computeFunction();\n lastComputedBeforeOverride = lastComputedValue;\n }\n reactiveStore.currentDependencyTracker = previousTracker;\n const subject = new BehaviorSubject3(lastComputedValue);\n const observables = [...dependencies].map((dep) => {\n if (isComputed(dep) && \"dependencies\" in dep) {\n const computedDep = dep;\n if (computedDep.dependencies.size === 0) {\n return new BehaviorSubject3(computedDep()).asObservable();\n }\n }\n return dep.observable;\n });\n let linkedObservable;\n if (observables.length > 0) {\n linkedObservable = combineLatest(observables).pipe(\n filter(() => !init),\n map(() => {\n const computed2 = computeFunction();\n if (equalFn) {\n if (!equalFn(lastComputedValue, computed2)) {\n lastComputedValue = computed2;\n isOverridden = false;\n }\n } else {\n if (lastComputedValue !== computed2) {\n lastComputedValue = computed2;\n isOverridden = false;\n }\n }\n return lastComputedValue;\n })\n );\n } else {\n linkedObservable = subject.asObservable().pipe(\n filter(() => !init)\n );\n }\n const fn = function() {\n trackDependency(fn);\n if (isOverridden && dependencies.size > 0) {\n if (overrideDepVersion !== depVersion) {\n const computed2 = computeFunction();\n isOverridden = false;\n overriddenValue = void 0;\n lastComputedValue = computed2;\n lastComputedBeforeOverride = computed2;\n overrideDepVersion = null;\n return computed2;\n }\n return overriddenValue;\n }\n if (isOverridden) {\n return overriddenValue;\n }\n if (dependencies.size === 0) {\n const computed2 = computeFunction();\n lastComputedValue = computed2;\n lastComputedBeforeOverride = computed2;\n }\n return lastComputedValue;\n };\n fn.observable = new Observable((observer) => {\n const depSubscription = linkedObservable.subscribe((value) => {\n if (dependencies.size > 0) {\n depVersion++;\n isOverridden = false;\n overrideDepVersion = null;\n lastComputedValue = value;\n lastComputedBeforeOverride = value;\n } else {\n lastComputedValue = value;\n lastComputedBeforeOverride = value;\n }\n observer.next(value);\n });\n let subjectSubscription;\n if (dependencies.size === 0) {\n subjectSubscription = subject.pipe(\n filter(() => !init)\n ).subscribe((value) => {\n observer.next(value);\n });\n }\n observer.next(lastComputedValue);\n return () => {\n depSubscription.unsubscribe();\n if (subjectSubscription) {\n subjectSubscription.unsubscribe();\n }\n };\n });\n fn.subscription = fn.observable.subscribe(() => {\n });\n fn.dependencies = dependencies;\n fn._subject = subject;\n fn.set = (value) => {\n if (!isOverridden) {\n lastComputedBeforeOverride = lastComputedValue;\n overrideDepVersion = depVersion;\n if (computationFn && sourceSignal) {\n const sourceValue = untracked(() => {\n if (typeof sourceSignal === \"function\") {\n const source = sourceSignal;\n return isSignal(source) ? source() : sourceSignal();\n }\n return sourceSignal();\n });\n previousValue = {\n source: sourceValue,\n value\n };\n }\n }\n isOverridden = true;\n overriddenValue = value;\n lastComputedValue = value;\n subject.next(value);\n };\n reactiveStore.currentSubscriptionsTracker?.(fn.subscription);\n init = false;\n return fn;\n}\nfunction untracked(fn) {\n const prevDepTracker = reactiveStore.currentDependencyTracker;\n const prevSubTracker = reactiveStore.currentSubscriptionsTracker;\n reactiveStore.currentDependencyTracker = null;\n reactiveStore.currentSubscriptionsTracker = null;\n try {\n return fn();\n } finally {\n reactiveStore.currentDependencyTracker = prevDepTracker;\n reactiveStore.currentSubscriptionsTracker = prevSubTracker;\n }\n}\n\n// src/effect.ts\nfunction effect(fn) {\n fn[\"isEffect\"] = true;\n return computed(fn);\n}\nexport {\n ArraySubject,\n ObjectSubject,\n computed,\n effect,\n isArraySubject,\n isComputed,\n isObjectSubject,\n isSignal,\n linkedSignal,\n signal,\n untracked\n};\n//# sourceMappingURL=index.js.map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