solid-js 1.9.7 → 1.9.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/dist/dev.cjs +8 -7
- package/dist/dev.js +8 -7
- package/dist/server.cjs +3 -1
- package/dist/server.js +3 -1
- package/dist/solid.cjs +8 -7
- package/dist/solid.js +8 -7
- package/h/jsx-runtime/types/jsx.d.ts +246 -234
- package/package.json +1 -1
- package/store/dist/dev.cjs +9 -5
- package/store/dist/dev.js +9 -5
- package/store/dist/store.cjs +9 -5
- package/store/dist/store.js +9 -5
- package/types/index.d.ts +1 -1
- package/types/jsx.d.ts +245 -229
- package/universal/types/index.d.ts +1 -0
- package/universal/types/universal.d.ts +2 -2
- package/web/dist/dev.cjs +89 -6
- package/web/dist/dev.js +89 -7
- package/web/dist/server.cjs +89 -4
- package/web/dist/server.js +89 -5
- package/web/dist/web.cjs +89 -6
- package/web/dist/web.js +89 -7
package/package.json
CHANGED
package/store/dist/dev.cjs
CHANGED
|
@@ -284,9 +284,13 @@ function wrap(value) {
|
|
|
284
284
|
const proto = Object.getPrototypeOf(value);
|
|
285
285
|
const isClass = proto !== null && value !== null && typeof value === "object" && !Array.isArray(value) && proto !== Object.prototype;
|
|
286
286
|
if (isClass) {
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
287
|
+
let curProto = proto;
|
|
288
|
+
while (curProto != null) {
|
|
289
|
+
const descriptors = Object.getOwnPropertyDescriptors(curProto);
|
|
290
|
+
keys.push(...Object.keys(descriptors));
|
|
291
|
+
Object.assign(desc, descriptors);
|
|
292
|
+
curProto = Object.getPrototypeOf(curProto);
|
|
293
|
+
}
|
|
290
294
|
}
|
|
291
295
|
for (let i = 0, l = keys.length; i < l; i++) {
|
|
292
296
|
const prop = keys[i];
|
|
@@ -336,12 +340,12 @@ function applyState(target, parent, property, merge, key) {
|
|
|
336
340
|
if (isArray) {
|
|
337
341
|
if (target.length && previous.length && (!merge || key && target[0] && target[0][key] != null)) {
|
|
338
342
|
let i, j, start, end, newEnd, item, newIndicesNext, keyVal;
|
|
339
|
-
for (start = 0, end = Math.min(previous.length, target.length); start < end && (previous[start] === target[start] || key && previous[start] && target[start] && previous[start][key] === target[start][key]); start++) {
|
|
343
|
+
for (start = 0, end = Math.min(previous.length, target.length); start < end && (previous[start] === target[start] || key && previous[start] && target[start] && previous[start][key] && previous[start][key] === target[start][key]); start++) {
|
|
340
344
|
applyState(target[start], previous, start, merge, key);
|
|
341
345
|
}
|
|
342
346
|
const temp = new Array(target.length),
|
|
343
347
|
newIndices = new Map();
|
|
344
|
-
for (end = previous.length - 1, newEnd = target.length - 1; end >= start && newEnd >= start && (previous[end] === target[newEnd] || key && previous[end] && target[newEnd] && previous[end][key] === target[newEnd][key]); end--, newEnd--) {
|
|
348
|
+
for (end = previous.length - 1, newEnd = target.length - 1; end >= start && newEnd >= start && (previous[end] === target[newEnd] || key && previous[end] && target[newEnd] && previous[end][key] && previous[end][key] === target[newEnd][key]); end--, newEnd--) {
|
|
345
349
|
temp[newEnd] = previous[end];
|
|
346
350
|
}
|
|
347
351
|
if (start > newEnd || start > end) {
|
package/store/dist/dev.js
CHANGED
|
@@ -282,9 +282,13 @@ function wrap(value) {
|
|
|
282
282
|
const proto = Object.getPrototypeOf(value);
|
|
283
283
|
const isClass = proto !== null && value !== null && typeof value === "object" && !Array.isArray(value) && proto !== Object.prototype;
|
|
284
284
|
if (isClass) {
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
285
|
+
let curProto = proto;
|
|
286
|
+
while (curProto != null) {
|
|
287
|
+
const descriptors = Object.getOwnPropertyDescriptors(curProto);
|
|
288
|
+
keys.push(...Object.keys(descriptors));
|
|
289
|
+
Object.assign(desc, descriptors);
|
|
290
|
+
curProto = Object.getPrototypeOf(curProto);
|
|
291
|
+
}
|
|
288
292
|
}
|
|
289
293
|
for (let i = 0, l = keys.length; i < l; i++) {
|
|
290
294
|
const prop = keys[i];
|
|
@@ -334,12 +338,12 @@ function applyState(target, parent, property, merge, key) {
|
|
|
334
338
|
if (isArray) {
|
|
335
339
|
if (target.length && previous.length && (!merge || key && target[0] && target[0][key] != null)) {
|
|
336
340
|
let i, j, start, end, newEnd, item, newIndicesNext, keyVal;
|
|
337
|
-
for (start = 0, end = Math.min(previous.length, target.length); start < end && (previous[start] === target[start] || key && previous[start] && target[start] && previous[start][key] === target[start][key]); start++) {
|
|
341
|
+
for (start = 0, end = Math.min(previous.length, target.length); start < end && (previous[start] === target[start] || key && previous[start] && target[start] && previous[start][key] && previous[start][key] === target[start][key]); start++) {
|
|
338
342
|
applyState(target[start], previous, start, merge, key);
|
|
339
343
|
}
|
|
340
344
|
const temp = new Array(target.length),
|
|
341
345
|
newIndices = new Map();
|
|
342
|
-
for (end = previous.length - 1, newEnd = target.length - 1; end >= start && newEnd >= start && (previous[end] === target[newEnd] || key && previous[end] && target[newEnd] && previous[end][key] === target[newEnd][key]); end--, newEnd--) {
|
|
346
|
+
for (end = previous.length - 1, newEnd = target.length - 1; end >= start && newEnd >= start && (previous[end] === target[newEnd] || key && previous[end] && target[newEnd] && previous[end][key] && previous[end][key] === target[newEnd][key]); end--, newEnd--) {
|
|
343
347
|
temp[newEnd] = previous[end];
|
|
344
348
|
}
|
|
345
349
|
if (start > newEnd || start > end) {
|
package/store/dist/store.cjs
CHANGED
|
@@ -273,9 +273,13 @@ function wrap(value) {
|
|
|
273
273
|
const proto = Object.getPrototypeOf(value);
|
|
274
274
|
const isClass = proto !== null && value !== null && typeof value === "object" && !Array.isArray(value) && proto !== Object.prototype;
|
|
275
275
|
if (isClass) {
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
276
|
+
let curProto = proto;
|
|
277
|
+
while (curProto != null) {
|
|
278
|
+
const descriptors = Object.getOwnPropertyDescriptors(curProto);
|
|
279
|
+
keys.push(...Object.keys(descriptors));
|
|
280
|
+
Object.assign(desc, descriptors);
|
|
281
|
+
curProto = Object.getPrototypeOf(curProto);
|
|
282
|
+
}
|
|
279
283
|
}
|
|
280
284
|
for (let i = 0, l = keys.length; i < l; i++) {
|
|
281
285
|
const prop = keys[i];
|
|
@@ -320,12 +324,12 @@ function applyState(target, parent, property, merge, key) {
|
|
|
320
324
|
if (isArray) {
|
|
321
325
|
if (target.length && previous.length && (!merge || key && target[0] && target[0][key] != null)) {
|
|
322
326
|
let i, j, start, end, newEnd, item, newIndicesNext, keyVal;
|
|
323
|
-
for (start = 0, end = Math.min(previous.length, target.length); start < end && (previous[start] === target[start] || key && previous[start] && target[start] && previous[start][key] === target[start][key]); start++) {
|
|
327
|
+
for (start = 0, end = Math.min(previous.length, target.length); start < end && (previous[start] === target[start] || key && previous[start] && target[start] && previous[start][key] && previous[start][key] === target[start][key]); start++) {
|
|
324
328
|
applyState(target[start], previous, start, merge, key);
|
|
325
329
|
}
|
|
326
330
|
const temp = new Array(target.length),
|
|
327
331
|
newIndices = new Map();
|
|
328
|
-
for (end = previous.length - 1, newEnd = target.length - 1; end >= start && newEnd >= start && (previous[end] === target[newEnd] || key && previous[end] && target[newEnd] && previous[end][key] === target[newEnd][key]); end--, newEnd--) {
|
|
332
|
+
for (end = previous.length - 1, newEnd = target.length - 1; end >= start && newEnd >= start && (previous[end] === target[newEnd] || key && previous[end] && target[newEnd] && previous[end][key] && previous[end][key] === target[newEnd][key]); end--, newEnd--) {
|
|
329
333
|
temp[newEnd] = previous[end];
|
|
330
334
|
}
|
|
331
335
|
if (start > newEnd || start > end) {
|
package/store/dist/store.js
CHANGED
|
@@ -271,9 +271,13 @@ function wrap(value) {
|
|
|
271
271
|
const proto = Object.getPrototypeOf(value);
|
|
272
272
|
const isClass = proto !== null && value !== null && typeof value === "object" && !Array.isArray(value) && proto !== Object.prototype;
|
|
273
273
|
if (isClass) {
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
274
|
+
let curProto = proto;
|
|
275
|
+
while (curProto != null) {
|
|
276
|
+
const descriptors = Object.getOwnPropertyDescriptors(curProto);
|
|
277
|
+
keys.push(...Object.keys(descriptors));
|
|
278
|
+
Object.assign(desc, descriptors);
|
|
279
|
+
curProto = Object.getPrototypeOf(curProto);
|
|
280
|
+
}
|
|
277
281
|
}
|
|
278
282
|
for (let i = 0, l = keys.length; i < l; i++) {
|
|
279
283
|
const prop = keys[i];
|
|
@@ -318,12 +322,12 @@ function applyState(target, parent, property, merge, key) {
|
|
|
318
322
|
if (isArray) {
|
|
319
323
|
if (target.length && previous.length && (!merge || key && target[0] && target[0][key] != null)) {
|
|
320
324
|
let i, j, start, end, newEnd, item, newIndicesNext, keyVal;
|
|
321
|
-
for (start = 0, end = Math.min(previous.length, target.length); start < end && (previous[start] === target[start] || key && previous[start] && target[start] && previous[start][key] === target[start][key]); start++) {
|
|
325
|
+
for (start = 0, end = Math.min(previous.length, target.length); start < end && (previous[start] === target[start] || key && previous[start] && target[start] && previous[start][key] && previous[start][key] === target[start][key]); start++) {
|
|
322
326
|
applyState(target[start], previous, start, merge, key);
|
|
323
327
|
}
|
|
324
328
|
const temp = new Array(target.length),
|
|
325
329
|
newIndices = new Map();
|
|
326
|
-
for (end = previous.length - 1, newEnd = target.length - 1; end >= start && newEnd >= start && (previous[end] === target[newEnd] || key && previous[end] && target[newEnd] && previous[end][key] === target[newEnd][key]); end--, newEnd--) {
|
|
330
|
+
for (end = previous.length - 1, newEnd = target.length - 1; end >= start && newEnd >= start && (previous[end] === target[newEnd] || key && previous[end] && target[newEnd] && previous[end][key] && previous[end][key] === target[newEnd][key]); end--, newEnd--) {
|
|
327
331
|
temp[newEnd] = previous[end];
|
|
328
332
|
}
|
|
329
333
|
if (start > newEnd || start > end) {
|
package/types/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
export { $DEVCOMP, $PROXY, $TRACK, batch, catchError, children, createComputed, createContext, createDeferred, createEffect, createMemo, createReaction, createRenderEffect, createResource, createRoot, createSelector, createSignal, enableExternalSource, enableScheduling, equalFn, getListener, getOwner, on, onCleanup, onError, onMount, runWithOwner, startTransition, untrack, useContext, useTransition } from "./reactive/signal.js";
|
|
2
|
-
export type { Accessor, AccessorArray, ChildrenReturn, Context, ContextProviderComponent, EffectFunction, EffectOptions, InitializedResource, InitializedResourceOptions, InitializedResourceReturn, MemoOptions, NoInfer, OnEffectFunction, OnOptions, Owner, ResolvedChildren, ResolvedJSXElement, Resource, ResourceActions, ResourceFetcher, ResourceFetcherInfo, ResourceOptions, ResourceReturn, ResourceSource, ReturnTypes, Setter, Signal, SignalOptions } from "./reactive/signal.js";
|
|
2
|
+
export type { Accessor, AccessorArray, ChildrenReturn, Context, ContextProviderComponent, EffectFunction, EffectOptions, InitializedResource, InitializedResourceOptions, InitializedResourceReturn, MemoOptions, NoInfer, OnEffectFunction, OnOptions, Owner, ResolvedChildren, ResolvedJSXElement, Resource, ResourceActions, ResourceFetcher, ResourceFetcherInfo, ResourceOptions, ResourceReturn, ResourceSource, ReturnTypes, Setter, Signal, SignalOptions, Transition } from "./reactive/signal.js";
|
|
3
3
|
export * from "./reactive/observable.js";
|
|
4
4
|
export * from "./reactive/scheduler.js";
|
|
5
5
|
export * from "./reactive/array.js";
|