0.2.0 - Mid migration

This commit is contained in:
Daniel Mason 2022-04-25 14:47:15 +12:00
parent 139e6a915e
commit 7e38fdbd7d
42393 changed files with 5358157 additions and 62 deletions

3
web/node_modules/immer/dist/core/current.d.ts generated vendored Normal file
View file

@ -0,0 +1,3 @@
/** Takes a snapshot of the current state of a draft and finalizes it (but without freezing). This is a great utility to print the current state during debugging (no Proxies in the way). The output of current can also be safely leaked outside the producer. */
export declare function current<T>(value: T): T;
//# sourceMappingURL=current.d.ts.map

1
web/node_modules/immer/dist/core/current.d.ts.map generated vendored Normal file
View file

@ -0,0 +1 @@
{"version":3,"file":"current.d.ts","sourceRoot":"","sources":["../src/core/current.ts"],"names":[],"mappings":"AAeA,mQAAmQ;AACnQ,wBAAgB,OAAO,CAAC,CAAC,EAAE,KAAK,EAAE,CAAC,GAAG,CAAC,CAAA"}

3
web/node_modules/immer/dist/core/finalize.d.ts generated vendored Normal file
View file

@ -0,0 +1,3 @@
import { ImmerScope } from "../internal";
export declare function processResult(result: any, scope: ImmerScope): any;
//# sourceMappingURL=finalize.d.ts.map

1
web/node_modules/immer/dist/core/finalize.d.ts.map generated vendored Normal file
View file

@ -0,0 +1 @@
{"version":3,"file":"finalize.d.ts","sourceRoot":"","sources":["../src/core/finalize.ts"],"names":[],"mappings":"AAAA,OAAO,EACN,UAAU,EAkBV,MAAM,aAAa,CAAA;AAEpB,wBAAgB,aAAa,CAAC,MAAM,EAAE,GAAG,EAAE,KAAK,EAAE,UAAU,OAiC3D"}

53
web/node_modules/immer/dist/core/immerClass.d.ts generated vendored Normal file
View file

@ -0,0 +1,53 @@
import { IProduceWithPatches, IProduce, ImmerState, Drafted, Patch, Objectish, Draft, PatchListener } from "../internal";
interface ProducersFns {
produce: IProduce;
produceWithPatches: IProduceWithPatches;
}
export declare class Immer implements ProducersFns {
useProxies_: boolean;
autoFreeze_: boolean;
constructor(config?: {
useProxies?: boolean;
autoFreeze?: boolean;
});
/**
* The `produce` function takes a value and a "recipe function" (whose
* return value often depends on the base state). The recipe function is
* free to mutate its first argument however it wants. All mutations are
* only ever applied to a __copy__ of the base state.
*
* Pass only a function to create a "curried producer" which relieves you
* from passing the recipe function every time.
*
* Only plain objects and arrays are made mutable. All other objects are
* considered uncopyable.
*
* Note: This function is __bound__ to its `Immer` instance.
*
* @param {any} base - the initial state
* @param {Function} producer - function that receives a proxy of the base state as first argument and which can be freely modified
* @param {Function} patchListener - optional function that will be called with all the patches produced here
* @returns {any} a new state, or the initial state if nothing was modified
*/
produce: IProduce;
produceWithPatches: IProduceWithPatches;
createDraft<T extends Objectish>(base: T): Draft<T>;
finishDraft<D extends Draft<any>>(draft: D, patchListener?: PatchListener): D extends Draft<infer T> ? T : never;
/**
* Pass true to automatically freeze all copies created by Immer.
*
* By default, auto-freezing is enabled.
*/
setAutoFreeze(value: boolean): void;
/**
* Pass true to use the ES2015 `Proxy` class when creating drafts, which is
* always faster than using ES5 proxies.
*
* By default, feature detection is used, so calling this is rarely necessary.
*/
setUseProxies(value: boolean): void;
applyPatches<T extends Objectish>(base: T, patches: Patch[]): T;
}
export declare function createProxy<T extends Objectish>(immer: Immer, value: T, parent?: ImmerState): Drafted<T, ImmerState>;
export {};
//# sourceMappingURL=immerClass.d.ts.map

1
web/node_modules/immer/dist/core/immerClass.d.ts.map generated vendored Normal file
View file

@ -0,0 +1 @@
{"version":3,"file":"immerClass.d.ts","sourceRoot":"","sources":["../src/core/immerClass.ts"],"names":[],"mappings":"AAAA,OAAO,EACN,mBAAmB,EACnB,QAAQ,EACR,UAAU,EACV,OAAO,EAGP,KAAK,EACL,SAAS,EAET,KAAK,EACL,aAAa,EAgBb,MAAM,aAAa,CAAA;AAEpB,UAAU,YAAY;IACrB,OAAO,EAAE,QAAQ,CAAA;IACjB,kBAAkB,EAAE,mBAAmB,CAAA;CACvC;AAED,qBAAa,KAAM,YAAW,YAAY;IACzC,WAAW,EAAE,OAAO,CAAa;IAEjC,WAAW,EAAE,OAAO,CAAO;gBAEf,MAAM,CAAC,EAAE;QAAC,UAAU,CAAC,EAAE,OAAO,CAAC;QAAC,UAAU,CAAC,EAAE,OAAO,CAAA;KAAC;IAOjE;;;;;;;;;;;;;;;;;;OAkBG;IACH,OAAO,EAAE,QAAQ,CAwDhB;IAED,kBAAkB,EAAE,mBAAmB,CAgBtC;IAED,WAAW,CAAC,CAAC,SAAS,SAAS,EAAE,IAAI,EAAE,CAAC,GAAG,KAAK,CAAC,CAAC,CAAC;IAUnD,WAAW,CAAC,CAAC,SAAS,KAAK,CAAC,GAAG,CAAC,EAC/B,KAAK,EAAE,CAAC,EACR,aAAa,CAAC,EAAE,aAAa,GAC3B,CAAC,SAAS,KAAK,CAAC,MAAM,CAAC,CAAC,GAAG,CAAC,GAAG,KAAK;IAWvC;;;;OAIG;IACH,aAAa,CAAC,KAAK,EAAE,OAAO;IAI5B;;;;;OAKG;IACH,aAAa,CAAC,KAAK,EAAE,OAAO;IAO5B,YAAY,CAAC,CAAC,SAAS,SAAS,EAAE,IAAI,EAAE,CAAC,EAAE,OAAO,EAAE,KAAK,EAAE,GAAG,CAAC;CAsB/D;AAED,wBAAgB,WAAW,CAAC,CAAC,SAAS,SAAS,EAC9C,KAAK,EAAE,KAAK,EACZ,KAAK,EAAE,CAAC,EACR,MAAM,CAAC,EAAE,UAAU,GACjB,OAAO,CAAC,CAAC,EAAE,UAAU,CAAC,CAaxB"}

38
web/node_modules/immer/dist/core/proxy.d.ts generated vendored Normal file
View file

@ -0,0 +1,38 @@
import { ImmerBaseState, ImmerState, Drafted, AnyObject, AnyArray, Objectish, ProxyType } from "../internal";
interface ProxyBaseState extends ImmerBaseState {
assigned_: {
[property: string]: boolean;
};
parent_?: ImmerState;
revoke_(): void;
}
export interface ProxyObjectState extends ProxyBaseState {
type_: ProxyType.ProxyObject;
base_: any;
copy_: any;
draft_: Drafted<AnyObject, ProxyObjectState>;
}
export interface ProxyArrayState extends ProxyBaseState {
type_: ProxyType.ProxyArray;
base_: AnyArray;
copy_: AnyArray | null;
draft_: Drafted<AnyArray, ProxyArrayState>;
}
declare type ProxyState = ProxyObjectState | ProxyArrayState;
/**
* Returns a new draft of the `base` object.
*
* The second argument is the parent draft-state (used internally).
*/
export declare function createProxyProxy<T extends Objectish>(base: T, parent?: ImmerState): Drafted<T, ProxyState>;
/**
* Object drafts
*/
export declare const objectTraps: ProxyHandler<ProxyState>;
export declare function markChanged(state: ImmerState): void;
export declare function prepareCopy(state: {
base_: any;
copy_: any;
}): void;
export {};
//# sourceMappingURL=proxy.d.ts.map

1
web/node_modules/immer/dist/core/proxy.d.ts.map generated vendored Normal file
View file

@ -0,0 +1 @@
{"version":3,"file":"proxy.d.ts","sourceRoot":"","sources":["../src/core/proxy.ts"],"names":[],"mappings":"AAAA,OAAO,EAON,cAAc,EACd,UAAU,EACV,OAAO,EACP,SAAS,EACT,QAAQ,EACR,SAAS,EAKT,SAAS,EACT,MAAM,aAAa,CAAA;AAEpB,UAAU,cAAe,SAAQ,cAAc;IAC9C,SAAS,EAAE;QACV,CAAC,QAAQ,EAAE,MAAM,GAAG,OAAO,CAAA;KAC3B,CAAA;IACD,OAAO,CAAC,EAAE,UAAU,CAAA;IACpB,OAAO,IAAI,IAAI,CAAA;CACf;AAED,MAAM,WAAW,gBAAiB,SAAQ,cAAc;IACvD,KAAK,EAAE,SAAS,CAAC,WAAW,CAAA;IAC5B,KAAK,EAAE,GAAG,CAAA;IACV,KAAK,EAAE,GAAG,CAAA;IACV,MAAM,EAAE,OAAO,CAAC,SAAS,EAAE,gBAAgB,CAAC,CAAA;CAC5C;AAED,MAAM,WAAW,eAAgB,SAAQ,cAAc;IACtD,KAAK,EAAE,SAAS,CAAC,UAAU,CAAA;IAC3B,KAAK,EAAE,QAAQ,CAAA;IACf,KAAK,EAAE,QAAQ,GAAG,IAAI,CAAA;IACtB,MAAM,EAAE,OAAO,CAAC,QAAQ,EAAE,eAAe,CAAC,CAAA;CAC1C;AAED,aAAK,UAAU,GAAG,gBAAgB,GAAG,eAAe,CAAA;AAEpD;;;;GAIG;AACH,wBAAgB,gBAAgB,CAAC,CAAC,SAAS,SAAS,EACnD,IAAI,EAAE,CAAC,EACP,MAAM,CAAC,EAAE,UAAU,GACjB,OAAO,CAAC,CAAC,EAAE,UAAU,CAAC,CA0CxB;AAED;;GAEG;AACH,eAAO,MAAM,WAAW,EAAE,YAAY,CAAC,UAAU,CA8GhD,CAAA;AAwDD,wBAAgB,WAAW,CAAC,KAAK,EAAE,UAAU,QAO5C;AAED,wBAAgB,WAAW,CAAC,KAAK,EAAE;IAAC,KAAK,EAAE,GAAG,CAAC;IAAC,KAAK,EAAE,GAAG,CAAA;CAAC,QAI1D"}

18
web/node_modules/immer/dist/core/scope.d.ts generated vendored Normal file
View file

@ -0,0 +1,18 @@
import { Patch, PatchListener, Immer } from "../internal";
/** Each scope represents a `produce` call. */
export interface ImmerScope {
patches_?: Patch[];
inversePatches_?: Patch[];
canAutoFreeze_: boolean;
drafts_: any[];
parent_?: ImmerScope;
patchListener_?: PatchListener;
immer_: Immer;
unfinalizedDrafts_: number;
}
export declare function getCurrentScope(): ImmerScope;
export declare function usePatchesInScope(scope: ImmerScope, patchListener?: PatchListener): void;
export declare function revokeScope(scope: ImmerScope): void;
export declare function leaveScope(scope: ImmerScope): void;
export declare function enterScope(immer: Immer): ImmerScope;
//# sourceMappingURL=scope.d.ts.map

1
web/node_modules/immer/dist/core/scope.d.ts.map generated vendored Normal file
View file

@ -0,0 +1 @@
{"version":3,"file":"scope.d.ts","sourceRoot":"","sources":["../src/core/scope.ts"],"names":[],"mappings":"AAAA,OAAO,EACN,KAAK,EACL,aAAa,EAEb,KAAK,EAKL,MAAM,aAAa,CAAA;AAGpB,8CAA8C;AAE9C,MAAM,WAAW,UAAU;IAC1B,QAAQ,CAAC,EAAE,KAAK,EAAE,CAAA;IAClB,eAAe,CAAC,EAAE,KAAK,EAAE,CAAA;IACzB,cAAc,EAAE,OAAO,CAAA;IACvB,OAAO,EAAE,GAAG,EAAE,CAAA;IACd,OAAO,CAAC,EAAE,UAAU,CAAA;IACpB,cAAc,CAAC,EAAE,aAAa,CAAA;IAC9B,MAAM,EAAE,KAAK,CAAA;IACb,kBAAkB,EAAE,MAAM,CAAA;CAC1B;AAID,wBAAgB,eAAe,eAG9B;AAiBD,wBAAgB,iBAAiB,CAChC,KAAK,EAAE,UAAU,EACjB,aAAa,CAAC,EAAE,aAAa,QAQ7B;AAED,wBAAgB,WAAW,CAAC,KAAK,EAAE,UAAU,QAK5C;AAED,wBAAgB,UAAU,CAAC,KAAK,EAAE,UAAU,QAI3C;AAED,wBAAgB,UAAU,CAAC,KAAK,EAAE,KAAK,cAEtC"}

2029
web/node_modules/immer/dist/immer.cjs.development.js generated vendored Normal file

File diff suppressed because it is too large Load diff

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

80
web/node_modules/immer/dist/immer.d.ts generated vendored Normal file
View file

@ -0,0 +1,80 @@
import { IProduce, IProduceWithPatches, Immer, Draft, Immutable } from "./internal";
export { Draft, Immutable, Patch, PatchListener, original, current, isDraft, isDraftable, NOTHING as nothing, DRAFTABLE as immerable, freeze } from "./internal";
/**
* The `produce` function takes a value and a "recipe function" (whose
* return value often depends on the base state). The recipe function is
* free to mutate its first argument however it wants. All mutations are
* only ever applied to a __copy__ of the base state.
*
* Pass only a function to create a "curried producer" which relieves you
* from passing the recipe function every time.
*
* Only plain objects and arrays are made mutable. All other objects are
* considered uncopyable.
*
* Note: This function is __bound__ to its `Immer` instance.
*
* @param {any} base - the initial state
* @param {Function} producer - function that receives a proxy of the base state as first argument and which can be freely modified
* @param {Function} patchListener - optional function that will be called with all the patches produced here
* @returns {any} a new state, or the initial state if nothing was modified
*/
export declare const produce: IProduce;
export default produce;
/**
* Like `produce`, but `produceWithPatches` always returns a tuple
* [nextState, patches, inversePatches] (instead of just the next state)
*/
export declare const produceWithPatches: IProduceWithPatches;
/**
* Pass true to automatically freeze all copies created by Immer.
*
* Always freeze by default, even in production mode
*/
export declare const setAutoFreeze: (value: boolean) => void;
/**
* Pass true to use the ES2015 `Proxy` class when creating drafts, which is
* always faster than using ES5 proxies.
*
* By default, feature detection is used, so calling this is rarely necessary.
*/
export declare const setUseProxies: (value: boolean) => void;
/**
* Apply an array of Immer patches to the first argument.
*
* This function is a producer, which means copy-on-write is in effect.
*/
export declare const applyPatches: <T extends import("./internal").Objectish>(base: T, patches: import("./internal").Patch[]) => T;
/**
* Create an Immer draft from the given base state, which may be a draft itself.
* The draft can be modified until you finalize it with the `finishDraft` function.
*/
export declare const createDraft: <T extends import("./internal").Objectish>(base: T) => Draft<T>;
/**
* Finalize an Immer draft from a `createDraft` call, returning the base state
* (if no changes were made) or a modified copy. The draft must *not* be
* mutated afterwards.
*
* Pass a function as the 2nd argument to generate Immer patches based on the
* changes that were made.
*/
export declare const finishDraft: <D extends any>(draft: D, patchListener?: import("./internal").PatchListener | undefined) => D extends Draft<infer T> ? T : never;
/**
* This function is actually a no-op, but can be used to cast an immutable type
* to an draft type and make TypeScript happy
*
* @param value
*/
export declare function castDraft<T>(value: T): Draft<T>;
/**
* This function is actually a no-op, but can be used to cast a mutable type
* to an immutable type and make TypeScript happy
* @param value
*/
export declare function castImmutable<T>(value: T): Immutable<T>;
export { Immer };
export { enableES5 } from "./plugins/es5";
export { enablePatches } from "./plugins/patches";
export { enableMapSet } from "./plugins/mapset";
export { enableAllPlugins } from "./plugins/all";
//# sourceMappingURL=immer.d.ts.map

1
web/node_modules/immer/dist/immer.d.ts.map generated vendored Normal file
View file

@ -0,0 +1 @@
{"version":3,"file":"immer.d.ts","sourceRoot":"","sources":["src/immer.ts"],"names":[],"mappings":"AAAA,OAAO,EACN,QAAQ,EACR,mBAAmB,EACnB,KAAK,EACL,KAAK,EACL,SAAS,EACT,MAAM,YAAY,CAAA;AAEnB,OAAO,EACN,KAAK,EACL,SAAS,EACT,KAAK,EACL,aAAa,EACb,QAAQ,EACR,OAAO,EACP,OAAO,EACP,WAAW,EACX,OAAO,IAAI,OAAO,EAClB,SAAS,IAAI,SAAS,EACtB,MAAM,EACN,MAAM,YAAY,CAAA;AAInB;;;;;;;;;;;;;;;;;;GAkBG;AACH,eAAO,MAAM,OAAO,EAAE,QAAwB,CAAA;AAC9C,eAAe,OAAO,CAAA;AAEtB;;;GAGG;AACH,eAAO,MAAM,kBAAkB,EAAE,mBAEhC,CAAA;AAED;;;;GAIG;AACH,eAAO,MAAM,aAAa,0BAAkC,CAAA;AAE5D;;;;;GAKG;AACH,eAAO,MAAM,aAAa,0BAAkC,CAAA;AAE5D;;;;GAIG;AACH,eAAO,MAAM,YAAY,iGAAiC,CAAA;AAE1D;;;GAGG;AACH,eAAO,MAAM,WAAW,iEAAgC,CAAA;AAExD;;;;;;;GAOG;AACH,eAAO,MAAM,WAAW,mIAAgC,CAAA;AAExD;;;;;GAKG;AACH,wBAAgB,SAAS,CAAC,CAAC,EAAE,KAAK,EAAE,CAAC,GAAG,KAAK,CAAC,CAAC,CAAC,CAE/C;AAED;;;;GAIG;AACH,wBAAgB,aAAa,CAAC,CAAC,EAAE,KAAK,EAAE,CAAC,GAAG,SAAS,CAAC,CAAC,CAAC,CAEvD;AAED,OAAO,EAAC,KAAK,EAAC,CAAA;AAEd,OAAO,EAAC,SAAS,EAAC,MAAM,eAAe,CAAA;AACvC,OAAO,EAAC,aAAa,EAAC,MAAM,mBAAmB,CAAA;AAC/C,OAAO,EAAC,YAAY,EAAC,MAAM,kBAAkB,CAAA;AAC7C,OAAO,EAAC,gBAAgB,EAAC,MAAM,eAAe,CAAA"}

2
web/node_modules/immer/dist/immer.esm.js generated vendored Normal file

File diff suppressed because one or more lines are too long

1
web/node_modules/immer/dist/immer.esm.js.map generated vendored Normal file

File diff suppressed because one or more lines are too long

2035
web/node_modules/immer/dist/immer.umd.development.js generated vendored Normal file

File diff suppressed because it is too large Load diff

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

8
web/node_modules/immer/dist/index.js generated vendored Normal file
View file

@ -0,0 +1,8 @@
'use strict'
if (process.env.NODE_ENV === 'production') {
module.exports = require('./immer.cjs.production.min.js')
} else {
module.exports = require('./immer.cjs.development.js')
}

113
web/node_modules/immer/dist/index.js.flow generated vendored Normal file
View file

@ -0,0 +1,113 @@
// @flow
export interface Patch {
op: "replace" | "remove" | "add";
path: (string | number)[];
value?: any;
}
export type PatchListener = (patches: Patch[], inversePatches: Patch[]) => void
type Base = {...} | Array<any>
interface IProduce {
/**
* Immer takes a state, and runs a function against it.
* That function can freely mutate the state, as it will create copies-on-write.
* This means that the original state will stay unchanged, and once the function finishes, the modified state is returned.
*
* If the first argument is a function, this is interpreted as the recipe, and will create a curried function that will execute the recipe
* any time it is called with the current state.
*
* @param currentState - the state to start with
* @param recipe - function that receives a proxy of the current state as first argument and which can be freely modified
* @param initialState - if a curried function is created and this argument was given, it will be used as fallback if the curried function is called with a state of undefined
* @returns The next state: a new state, or the current state if nothing was modified
*/
<S: Base>(
currentState: S,
recipe: (draftState: S) => S | void,
patchListener?: PatchListener
): S;
// curried invocations with initial state
<S: Base, A = void, B = void, C = void>(
recipe: (draftState: S, a: A, b: B, c: C, ...extraArgs: any[]) => S | void,
initialState: S
): (currentState: S | void, a: A, b: B, c: C, ...extraArgs: any[]) => S;
// curried invocations without initial state
<S: Base, A = void, B = void, C = void>(
recipe: (draftState: S, a: A, b: B, c: C, ...extraArgs: any[]) => S | void
): (currentState: S, a: A, b: B, c: C, ...extraArgs: any[]) => S;
}
interface IProduceWithPatches {
/**
* Like `produce`, but instead of just returning the new state,
* a tuple is returned with [nextState, patches, inversePatches]
*
* Like produce, this function supports currying
*/
<S: Base>(
currentState: S,
recipe: (draftState: S) => S | void
): [S, Patch[], Patch[]];
// curried invocations with initial state
<S: Base, A = void, B = void, C = void>(
recipe: (draftState: S, a: A, b: B, c: C, ...extraArgs: any[]) => S | void,
initialState: S
): (currentState: S | void, a: A, b: B, c: C, ...extraArgs: any[]) => [S, Patch[], Patch[]];
// curried invocations without initial state
<S: Base, A = void, B = void, C = void>(
recipe: (draftState: S, a: A, b: B, c: C, ...extraArgs: any[]) => S | void
): (currentState: S, a: A, b: B, c: C, ...extraArgs: any[]) => [S, Patch[], Patch[]];
}
declare export var produce: IProduce
declare export default IProduce
declare export var produceWithPatches: IProduceWithPatches
declare export var nothing: typeof undefined
declare export var immerable: Symbol
/**
* Automatically freezes any state trees generated by immer.
* This protects against accidental modifications of the state tree outside of an immer function.
* This comes with a performance impact, so it is recommended to disable this option in production.
* By default it is turned on during local development, and turned off in production.
*/
declare export function setAutoFreeze(autoFreeze: boolean): void
/**
* Manually override whether proxies should be used.
* By default done by using feature detection
*/
declare export function setUseProxies(useProxies: boolean): void
declare export function applyPatches<S>(state: S, patches: Patch[]): S
declare export function original<S>(value: S): S
declare export function current<S>(value: S): S
declare export function isDraft(value: any): boolean
/**
* Creates a mutable draft from an (immutable) object / array.
* The draft can be modified until `finishDraft` is called
*/
declare export function createDraft<T>(base: T): T
/**
* Given a draft that was created using `createDraft`,
* finalizes the draft into a new immutable object.
* Optionally a patch-listener can be provided to gather the patches that are needed to construct the object.
*/
declare export function finishDraft<T>(base: T, listener?: PatchListener): T
declare export function enableES5(): void
declare export function enableMapSet(): void
declare export function enablePatches(): void
declare export function enableAllPlugins(): void
declare export function freeze<T>(obj: T, freeze?: boolean): T

12
web/node_modules/immer/dist/internal.d.ts generated vendored Normal file
View file

@ -0,0 +1,12 @@
export * from "./utils/env";
export * from "./utils/errors";
export * from "./types/types-external";
export * from "./types/types-internal";
export * from "./utils/common";
export * from "./utils/plugins";
export * from "./core/scope";
export * from "./core/finalize";
export * from "./core/proxy";
export * from "./core/immerClass";
export * from "./core/current";
//# sourceMappingURL=internal.d.ts.map

1
web/node_modules/immer/dist/internal.d.ts.map generated vendored Normal file
View file

@ -0,0 +1 @@
{"version":3,"file":"internal.d.ts","sourceRoot":"","sources":["src/internal.ts"],"names":[],"mappings":"AAAA,cAAc,aAAa,CAAA;AAC3B,cAAc,gBAAgB,CAAA;AAC9B,cAAc,wBAAwB,CAAA;AACtC,cAAc,wBAAwB,CAAA;AACtC,cAAc,gBAAgB,CAAA;AAC9B,cAAc,iBAAiB,CAAA;AAC/B,cAAc,cAAc,CAAA;AAC5B,cAAc,iBAAiB,CAAA;AAC/B,cAAc,cAAc,CAAA;AAC5B,cAAc,mBAAmB,CAAA;AACjC,cAAc,gBAAgB,CAAA"}

2
web/node_modules/immer/dist/plugins/all.d.ts generated vendored Normal file
View file

@ -0,0 +1,2 @@
export declare function enableAllPlugins(): void;
//# sourceMappingURL=all.d.ts.map

1
web/node_modules/immer/dist/plugins/all.d.ts.map generated vendored Normal file
View file

@ -0,0 +1 @@
{"version":3,"file":"all.d.ts","sourceRoot":"","sources":["../src/plugins/all.ts"],"names":[],"mappings":"AAIA,wBAAgB,gBAAgB,SAI/B"}

2
web/node_modules/immer/dist/plugins/es5.d.ts generated vendored Normal file
View file

@ -0,0 +1,2 @@
export declare function enableES5(): void;
//# sourceMappingURL=es5.d.ts.map

1
web/node_modules/immer/dist/plugins/es5.d.ts.map generated vendored Normal file
View file

@ -0,0 +1 @@
{"version":3,"file":"es5.d.ts","sourceRoot":"","sources":["../src/plugins/es5.ts"],"names":[],"mappings":"AAwBA,wBAAgB,SAAS,SAoPxB"}

2
web/node_modules/immer/dist/plugins/mapset.d.ts generated vendored Normal file
View file

@ -0,0 +1,2 @@
export declare function enableMapSet(): void;
//# sourceMappingURL=mapset.d.ts.map

1
web/node_modules/immer/dist/plugins/mapset.d.ts.map generated vendored Normal file
View file

@ -0,0 +1 @@
{"version":3,"file":"mapset.d.ts","sourceRoot":"","sources":["../src/plugins/mapset.ts"],"names":[],"mappings":"AAoBA,wBAAgB,YAAY,SAmU3B"}

2
web/node_modules/immer/dist/plugins/patches.d.ts generated vendored Normal file
View file

@ -0,0 +1,2 @@
export declare function enablePatches(): void;
//# sourceMappingURL=patches.d.ts.map

1
web/node_modules/immer/dist/plugins/patches.d.ts.map generated vendored Normal file
View file

@ -0,0 +1 @@
{"version":3,"file":"patches.d.ts","sourceRoot":"","sources":["../src/plugins/patches.ts"],"names":[],"mappings":"AA0BA,wBAAgB,aAAa,SAgR5B"}

102
web/node_modules/immer/dist/types/types-external.d.ts generated vendored Normal file
View file

@ -0,0 +1,102 @@
import { Nothing } from "../internal";
declare type AnyFunc = (...args: any[]) => any;
declare type PrimitiveType = number | string | boolean;
/** Object types that should never be mapped */
declare type AtomicObject = Function | Promise<any> | Date | RegExp;
/**
* If the lib "ES2105.collections" is not included in tsconfig.json,
* types like ReadonlyArray, WeakMap etc. fall back to `any` (specified nowhere)
* or `{}` (from the node types), in both cases entering an infite recursion in
* pattern matching type mappings
* This type can be used to cast these types to `void` in these cases.
*/
export declare type IfAvailable<T, Fallback = void> = true | false extends (T extends never ? true : false) ? Fallback : keyof T extends never ? Fallback : T;
/**
* These should also never be mapped but must be tested after regular Map and
* Set
*/
declare type WeakReferences = IfAvailable<WeakMap<any, any>> | IfAvailable<WeakSet<any>>;
export declare type WritableDraft<T> = {
-readonly [K in keyof T]: Draft<T[K]>;
};
export declare type Draft<T> = T extends PrimitiveType ? T : T extends AtomicObject ? T : T extends IfAvailable<ReadonlyMap<infer K, infer V>> ? Map<Draft<K>, Draft<V>> : T extends IfAvailable<ReadonlySet<infer V>> ? Set<Draft<V>> : T extends WeakReferences ? T : T extends object ? WritableDraft<T> : T;
/** Convert a mutable type into a readonly type */
export declare type Immutable<T> = T extends PrimitiveType ? T : T extends AtomicObject ? T : T extends IfAvailable<ReadonlyMap<infer K, infer V>> ? ReadonlyMap<Immutable<K>, Immutable<V>> : T extends IfAvailable<ReadonlySet<infer V>> ? ReadonlySet<Immutable<V>> : T extends WeakReferences ? T : T extends object ? {
readonly [K in keyof T]: Immutable<T[K]>;
} : T;
export interface Patch {
op: "replace" | "remove" | "add";
path: (string | number)[];
value?: any;
}
export declare type PatchListener = (patches: Patch[], inversePatches: Patch[]) => void;
/** Converts `nothing` into `undefined` */
declare type FromNothing<T> = T extends Nothing ? undefined : T;
/** The inferred return type of `produce` */
export declare type Produced<Base, Return> = Return extends void ? Base : Return extends Promise<infer Result> ? Promise<Result extends void ? Base : FromNothing<Result>> : FromNothing<Return>;
/**
* Utility types
*/
declare type PatchesTuple<T> = readonly [T, Patch[], Patch[]];
declare type ValidRecipeReturnType<State> = State | void | undefined | (State extends undefined ? Nothing : never);
declare type ValidRecipeReturnTypePossiblyPromise<State> = ValidRecipeReturnType<State> | Promise<ValidRecipeReturnType<State>>;
declare type PromisifyReturnIfNeeded<State, Recipe extends AnyFunc, UsePatches extends boolean> = ReturnType<Recipe> extends Promise<any> ? Promise<UsePatches extends true ? PatchesTuple<State> : State> : UsePatches extends true ? PatchesTuple<State> : State;
/**
* Core Producer inference
*/
declare type InferRecipeFromCurried<Curried> = Curried extends (base: infer State, ...rest: infer Args) => any ? ReturnType<Curried> extends State ? (draft: Draft<State>, ...rest: Args) => ValidRecipeReturnType<Draft<State>> : never : never;
declare type InferInitialStateFromCurried<Curried> = Curried extends (base: infer State, ...rest: any[]) => any ? State : never;
declare type InferCurriedFromRecipe<Recipe, UsePatches extends boolean> = Recipe extends (draft: infer DraftState, ...args: infer RestArgs) => any ? ReturnType<Recipe> extends ValidRecipeReturnTypePossiblyPromise<DraftState> ? (base: Immutable<DraftState>, ...args: RestArgs) => PromisifyReturnIfNeeded<DraftState, Recipe, UsePatches> : never : never;
declare type InferCurriedFromInitialStateAndRecipe<State, Recipe, UsePatches extends boolean> = Recipe extends (draft: Draft<State>, ...rest: infer RestArgs) => ValidRecipeReturnTypePossiblyPromise<State> ? (base?: State | undefined, ...args: RestArgs) => PromisifyReturnIfNeeded<State, Recipe, UsePatches> : never;
/**
* The `produce` function takes a value and a "recipe function" (whose
* return value often depends on the base state). The recipe function is
* free to mutate its first argument however it wants. All mutations are
* only ever applied to a __copy__ of the base state.
*
* Pass only a function to create a "curried producer" which relieves you
* from passing the recipe function every time.
*
* Only plain objects and arrays are made mutable. All other objects are
* considered uncopyable.
*
* Note: This function is __bound__ to its `Immer` instance.
*
* @param {any} base - the initial state
* @param {Function} producer - function that receives a proxy of the base state as first argument and which can be freely modified
* @param {Function} patchListener - optional function that will be called with all the patches produced here
* @returns {any} a new state, or the initial state if nothing was modified
*/
export interface IProduce {
/** Curried producer that infers the recipe from the curried output function (e.g. when passing to setState) */
<Curried>(recipe: InferRecipeFromCurried<Curried>, initialState?: InferInitialStateFromCurried<Curried>): Curried;
/** Curried producer that infers curried from the recipe */
<Recipe extends AnyFunc>(recipe: Recipe): InferCurriedFromRecipe<Recipe, false>;
/** Curried producer that infers curried from the State generic, which is explicitly passed in. */
<State>(recipe: (state: Draft<State>, initialState: State) => ValidRecipeReturnType<State>): (state?: State) => State;
<State, Args extends any[]>(recipe: (state: Draft<State>, ...args: Args) => ValidRecipeReturnType<State>, initialState: State): (state?: State, ...args: Args) => State;
<State>(recipe: (state: Draft<State>) => ValidRecipeReturnType<State>): (state: State) => State;
<State, Args extends any[]>(recipe: (state: Draft<State>, ...args: Args) => ValidRecipeReturnType<State>): (state: State, ...args: Args) => State;
/** Curried producer with initial state, infers recipe from initial state */
<State, Recipe extends Function>(recipe: Recipe, initialState: State): InferCurriedFromInitialStateAndRecipe<State, Recipe, false>;
/** Normal producer */
<Base, D = Draft<Base>>(// By using a default inferred D, rather than Draft<Base> in the recipe, we can override it.
base: Base, recipe: (draft: D) => ValidRecipeReturnType<D>, listener?: PatchListener): Base;
/** Promisified dormal producer */
<Base, D = Draft<Base>>(base: Base, recipe: (draft: D) => Promise<ValidRecipeReturnType<D>>, listener?: PatchListener): Promise<Base>;
}
/**
* Like `produce`, but instead of just returning the new state,
* a tuple is returned with [nextState, patches, inversePatches]
*
* Like produce, this function supports currying
*/
export interface IProduceWithPatches {
<Recipe extends AnyFunc>(recipe: Recipe): InferCurriedFromRecipe<Recipe, true>;
<State, Recipe extends Function>(recipe: Recipe, initialState: State): InferCurriedFromInitialStateAndRecipe<State, Recipe, true>;
<Base, D = Draft<Base>>(base: Base, recipe: (draft: D) => ValidRecipeReturnType<Base>, listener?: PatchListener): PatchesTuple<Immutable<Base>>;
<Base, D = Draft<Base>>(base: Base, recipe: (draft: D) => Promise<ValidRecipeReturnType<Base>>, listener?: PatchListener): PatchesTuple<Promise<Immutable<Base>>>;
}
export declare function never_used(): void;
export {};
//# sourceMappingURL=types-external.d.ts.map

File diff suppressed because one or more lines are too long

35
web/node_modules/immer/dist/types/types-internal.d.ts generated vendored Normal file
View file

@ -0,0 +1,35 @@
import { SetState, ImmerScope, ProxyObjectState, ProxyArrayState, ES5ObjectState, ES5ArrayState, MapState, DRAFT_STATE } from "../internal";
export declare type Objectish = AnyObject | AnyArray | AnyMap | AnySet;
export declare type ObjectishNoSet = AnyObject | AnyArray | AnyMap;
export declare type AnyObject = {
[key: string]: any;
};
export declare type AnyArray = Array<any>;
export declare type AnySet = Set<any>;
export declare type AnyMap = Map<any, any>;
export declare const enum Archtype {
Object = 0,
Array = 1,
Map = 2,
Set = 3
}
export declare const enum ProxyType {
ProxyObject = 0,
ProxyArray = 1,
Map = 2,
Set = 3,
ES5Object = 4,
ES5Array = 5
}
export interface ImmerBaseState {
parent_?: ImmerState;
scope_: ImmerScope;
modified_: boolean;
finalized_: boolean;
isManual_: boolean;
}
export declare type ImmerState = ProxyObjectState | ProxyArrayState | ES5ObjectState | ES5ArrayState | MapState | SetState;
export declare type Drafted<Base = any, T extends ImmerState = ImmerState> = {
[DRAFT_STATE]: T;
} & Base;
//# sourceMappingURL=types-internal.d.ts.map

View file

@ -0,0 +1 @@
{"version":3,"file":"types-internal.d.ts","sourceRoot":"","sources":["../src/types/types-internal.ts"],"names":[],"mappings":"AAAA,OAAO,EACN,QAAQ,EACR,UAAU,EACV,gBAAgB,EAChB,eAAe,EACf,cAAc,EACd,aAAa,EACb,QAAQ,EACR,WAAW,EACX,MAAM,aAAa,CAAA;AAEpB,oBAAY,SAAS,GAAG,SAAS,GAAG,QAAQ,GAAG,MAAM,GAAG,MAAM,CAAA;AAC9D,oBAAY,cAAc,GAAG,SAAS,GAAG,QAAQ,GAAG,MAAM,CAAA;AAE1D,oBAAY,SAAS,GAAG;IAAC,CAAC,GAAG,EAAE,MAAM,GAAG,GAAG,CAAA;CAAC,CAAA;AAC5C,oBAAY,QAAQ,GAAG,KAAK,CAAC,GAAG,CAAC,CAAA;AACjC,oBAAY,MAAM,GAAG,GAAG,CAAC,GAAG,CAAC,CAAA;AAC7B,oBAAY,MAAM,GAAG,GAAG,CAAC,GAAG,EAAE,GAAG,CAAC,CAAA;AAElC,0BAAkB,QAAQ;IACzB,MAAM,IAAA;IACN,KAAK,IAAA;IACL,GAAG,IAAA;IACH,GAAG,IAAA;CACH;AAED,0BAAkB,SAAS;IAC1B,WAAW,IAAA;IACX,UAAU,IAAA;IACV,GAAG,IAAA;IACH,GAAG,IAAA;IACH,SAAS,IAAA;IACT,QAAQ,IAAA;CACR;AAED,MAAM,WAAW,cAAc;IAC9B,OAAO,CAAC,EAAE,UAAU,CAAA;IACpB,MAAM,EAAE,UAAU,CAAA;IAClB,SAAS,EAAE,OAAO,CAAA;IAClB,UAAU,EAAE,OAAO,CAAA;IACnB,SAAS,EAAE,OAAO,CAAA;CAClB;AAED,oBAAY,UAAU,GACnB,gBAAgB,GAChB,eAAe,GACf,cAAc,GACd,aAAa,GACb,QAAQ,GACR,QAAQ,CAAA;AAGX,oBAAY,OAAO,CAAC,IAAI,GAAG,GAAG,EAAE,CAAC,SAAS,UAAU,GAAG,UAAU,IAAI;IACpE,CAAC,WAAW,CAAC,EAAE,CAAC,CAAA;CAChB,GAAG,IAAI,CAAA"}

32
web/node_modules/immer/dist/utils/common.d.ts generated vendored Normal file
View file

@ -0,0 +1,32 @@
import { Objectish, AnyObject, AnyMap, AnySet, ImmerState, Archtype } from "../internal";
/** Returns true if the given value is an Immer draft */
export declare function isDraft(value: any): boolean;
/** Returns true if the given value can be drafted by Immer */
export declare function isDraftable(value: any): boolean;
export declare function isPlainObject(value: any): boolean;
/** Get the underlying object that is represented by the given draft */
export declare function original<T>(value: T): T | undefined;
export declare const ownKeys: (target: AnyObject) => PropertyKey[];
export declare const getOwnPropertyDescriptors: <T>(o: T) => { [P in keyof T]: TypedPropertyDescriptor<T[P]>; } & {
[x: string]: PropertyDescriptor;
};
export declare function each<T extends Objectish>(obj: T, iter: (key: string | number, value: any, source: T) => void, enumerableOnly?: boolean): void;
export declare function getArchtype(thing: any): Archtype;
export declare function has(thing: any, prop: PropertyKey): boolean;
export declare function get(thing: AnyMap | AnyObject, prop: PropertyKey): any;
export declare function set(thing: any, propOrOldValue: PropertyKey, value: any): void;
export declare function is(x: any, y: any): boolean;
export declare function isMap(target: any): target is AnyMap;
export declare function isSet(target: any): target is AnySet;
export declare function latest(state: ImmerState): any;
export declare function shallowCopy(base: any): any;
/**
* Freezes draftable objects. Returns the original object.
* By default freezes shallowly, but if the second argument is `true` it will freeze recursively.
*
* @param obj
* @param deep
*/
export declare function freeze<T>(obj: T, deep?: boolean): T;
export declare function isFrozen(obj: any): boolean;
//# sourceMappingURL=common.d.ts.map

1
web/node_modules/immer/dist/utils/common.d.ts.map generated vendored Normal file
View file

@ -0,0 +1 @@
{"version":3,"file":"common.d.ts","sourceRoot":"","sources":["../src/utils/common.ts"],"names":[],"mappings":"AAAA,OAAO,EAIN,SAAS,EAET,SAAS,EACT,MAAM,EACN,MAAM,EACN,UAAU,EAEV,QAAQ,EAER,MAAM,aAAa,CAAA;AAEpB,wDAAwD;AAExD,wBAAgB,OAAO,CAAC,KAAK,EAAE,GAAG,GAAG,OAAO,CAE3C;AAED,8DAA8D;AAE9D,wBAAgB,WAAW,CAAC,KAAK,EAAE,GAAG,GAAG,OAAO,CAU/C;AAID,wBAAgB,aAAa,CAAC,KAAK,EAAE,GAAG,GAAG,OAAO,CAejD;AAED,uEAAuE;AAEvE,wBAAgB,QAAQ,CAAC,CAAC,EAAE,KAAK,EAAE,CAAC,GAAG,CAAC,GAAG,SAAS,CAAA;AAOpD,eAAO,MAAM,OAAO,EAAE,CAAC,MAAM,EAAE,SAAS,KAAK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-0,0 +1,23 @@
export declare const hasMap: boolean;
export declare const hasSet: boolean;
export declare const hasProxies: boolean;
/**
* The sentinel value returned by producers to replace the draft with undefined.
*/
export declare const NOTHING: Nothing;
/**
* To let Immer treat your class instances as plain immutable objects
* (albeit with a custom prototype), you must define either an instance property
* or a static property on each of your custom classes.
*
* Otherwise, your class instance will never be drafted, which means it won't be
* safe to mutate in a produce callback.
*/
export declare const DRAFTABLE: unique symbol;
export declare const DRAFT_STATE: unique symbol;
export declare const iteratorSymbol: typeof Symbol.iterator;
/** Use a class type for `nothing` so its type is unique */
export declare class Nothing {
private _;
}
//# sourceMappingURL=env.d.ts.map

1
web/node_modules/immer/dist/utils/env.d.ts.map generated vendored Normal file
View file

@ -0,0 +1 @@
{"version":3,"file":"env.d.ts","sourceRoot":"","sources":["../src/utils/env.ts"],"names":[],"mappings":"AAOA,eAAO,MAAM,MAAM,SAA6B,CAAA;AAChD,eAAO,MAAM,MAAM,SAA6B,CAAA;AAChD,eAAO,MAAM,UAAU,SAGQ,CAAA;AAE/B;;GAEG;AACH,eAAO,MAAM,OAAO,EAAE,OAEe,CAAA;AAErC;;;;;;;GAOG;AACH,eAAO,MAAM,SAAS,EAAE,OAAO,MAEC,CAAA;AAEhC,eAAO,MAAM,WAAW,EAAE,OAAO,MAEL,CAAA;AAG5B,eAAO,MAAM,cAAc,EAAE,OAAO,MAAM,CAAC,QACgC,CAAA;AAE3E,2DAA2D;AAC3D,qBAAa,OAAO;IAGnB,OAAO,CAAC,CAAC,CAAgB;CACzB"}

29
web/node_modules/immer/dist/utils/errors.d.ts generated vendored Normal file
View file

@ -0,0 +1,29 @@
declare const errors: {
readonly 0: "Illegal state";
readonly 1: "Immer drafts cannot have computed properties";
readonly 2: "This object has been frozen and should not be mutated";
readonly 3: (data: any) => string;
readonly 4: "An immer producer returned a new value *and* modified its draft. Either return a new value *or* modify the draft.";
readonly 5: "Immer forbids circular references";
readonly 6: "The first or second argument to `produce` must be a function";
readonly 7: "The third argument to `produce` must be a function or undefined";
readonly 8: "First argument to `createDraft` must be a plain object, an array, or an immerable object";
readonly 9: "First argument to `finishDraft` must be a draft returned by `createDraft`";
readonly 10: "The given draft is already finalized";
readonly 11: "Object.defineProperty() cannot be used on an Immer draft";
readonly 12: "Object.setPrototypeOf() cannot be used on an Immer draft";
readonly 13: "Immer only supports deleting array indices";
readonly 14: "Immer only supports setting array indices and the 'length' property";
readonly 15: (path: string) => string;
readonly 16: "Sets cannot have \"replace\" patches.";
readonly 17: (op: string) => string;
readonly 18: (plugin: string) => string;
readonly 20: "Cannot use proxies if Proxy, Proxy.revocable or Reflect are not available";
readonly 21: (thing: string) => string;
readonly 22: (thing: string) => string;
readonly 23: (thing: string) => string;
readonly 24: "Patching reserved attributes like __proto__, prototype and constructor is not allowed";
};
export declare function die(error: keyof typeof errors, ...args: any[]): never;
export {};
//# sourceMappingURL=errors.d.ts.map

1
web/node_modules/immer/dist/utils/errors.d.ts.map generated vendored Normal file
View file

@ -0,0 +1 @@
{"version":3,"file":"errors.d.ts","sourceRoot":"","sources":["../src/utils/errors.ts"],"names":[],"mappings":"AAAA,QAAA,MAAM,MAAM;;;;;;;;;;;;;;;;;;;;;;;;;CA0CF,CAAA;AAEV,wBAAgB,GAAG,CAAC,KAAK,EAAE,MAAM,OAAO,MAAM,EAAE,GAAG,IAAI,EAAE,GAAG,EAAE,GAAG,KAAK,CAerE"}

62
web/node_modules/immer/dist/utils/plugins.d.ts generated vendored Normal file
View file

@ -0,0 +1,62 @@
import { ImmerState, Patch, ImmerScope, Drafted, AnyObject, ImmerBaseState, AnyMap, AnySet, ProxyType } from "../internal";
/** Plugin utilities */
declare const plugins: {
Patches?: {
generatePatches_(state: ImmerState, basePath: PatchPath, patches: Patch[], inversePatches: Patch[]): void;
generateReplacementPatches_(rootState: ImmerState, replacement: any, patches: Patch[], inversePatches: Patch[]): void;
applyPatches_<T>(draft: T, patches: Patch[]): T;
};
ES5?: {
willFinalizeES5_(scope: ImmerScope, result: any, isReplaced: boolean): void;
createES5Proxy_<T>(base: T, parent?: ImmerState): Drafted<T, ES5ObjectState | ES5ArrayState>;
hasChanges_(state: ES5ArrayState | ES5ObjectState): boolean;
};
MapSet?: {
proxyMap_<T extends AnyMap>(target: T, parent?: ImmerState): T;
proxySet_<T extends AnySet>(target: T, parent?: ImmerState): T;
};
};
declare type Plugins = typeof plugins;
export declare function getPlugin<K extends keyof Plugins>(pluginKey: K): Exclude<Plugins[K], undefined>;
export declare function loadPlugin<K extends keyof Plugins>(pluginKey: K, implementation: Plugins[K]): void;
/** ES5 Plugin */
interface ES5BaseState extends ImmerBaseState {
assigned_: {
[key: string]: any;
};
parent_?: ImmerState;
revoked_: boolean;
}
export interface ES5ObjectState extends ES5BaseState {
type_: ProxyType.ES5Object;
draft_: Drafted<AnyObject, ES5ObjectState>;
base_: AnyObject;
copy_: AnyObject | null;
}
export interface ES5ArrayState extends ES5BaseState {
type_: ProxyType.ES5Array;
draft_: Drafted<AnyObject, ES5ArrayState>;
base_: any;
copy_: any;
}
/** Map / Set plugin */
export interface MapState extends ImmerBaseState {
type_: ProxyType.Map;
copy_: AnyMap | undefined;
assigned_: Map<any, boolean> | undefined;
base_: AnyMap;
revoked_: boolean;
draft_: Drafted<AnyMap, MapState>;
}
export interface SetState extends ImmerBaseState {
type_: ProxyType.Set;
copy_: AnySet | undefined;
base_: AnySet;
drafts_: Map<any, Drafted>;
revoked_: boolean;
draft_: Drafted<AnySet, SetState>;
}
/** Patches plugin */
export declare type PatchPath = (string | number)[];
export {};
//# sourceMappingURL=plugins.d.ts.map

1
web/node_modules/immer/dist/utils/plugins.d.ts.map generated vendored Normal file
View file

@ -0,0 +1 @@
{"version":3,"file":"plugins.d.ts","sourceRoot":"","sources":["../src/utils/plugins.ts"],"names":[],"mappings":"AAAA,OAAO,EACN,UAAU,EACV,KAAK,EACL,UAAU,EACV,OAAO,EACP,SAAS,EACT,cAAc,EACd,MAAM,EACN,MAAM,EACN,SAAS,EAET,MAAM,aAAa,CAAA;A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