@marcoappio/marco-config 2.0.530 → 2.0.531
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/zero/index.d.ts +11 -38
- package/dist/zero/index.d.ts.map +1 -1
- package/dist/zero/mutatorSchemas.d.ts +3 -30
- package/dist/zero/mutatorSchemas.d.ts.map +1 -1
- package/dist/zero/mutatorSchemas.js +1 -5
- package/dist/zero/mutators.d.ts +8 -8
- package/dist/zero/mutators.d.ts.map +1 -1
- package/dist/zero/mutators.js +3 -5
- package/dist/zero/mutators.test.js +343 -243
- package/package.json +1 -1
package/dist/zero/index.d.ts
CHANGED
|
@@ -272,38 +272,11 @@ export declare const marcoZero: {
|
|
|
272
272
|
}, undefined>;
|
|
273
273
|
updateView: import("valibot").ObjectSchema<{
|
|
274
274
|
readonly id: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<readonly [import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
|
|
275
|
-
readonly
|
|
275
|
+
readonly view: import("valibot").ObjectSchema<{
|
|
276
276
|
readonly aliasEmails: import("valibot").SchemaWithPipe<readonly [import("valibot").ArraySchema<import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<readonly [import("valibot").StringSchema<undefined>, import("valibot").RfcEmailAction<string, undefined>]>, undefined>, undefined>, import("valibot").MinLengthAction<string[], 1, undefined>, import("valibot").MaxLengthAction<string[], number, undefined>]>;
|
|
277
|
+
readonly id: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<readonly [import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
|
|
277
278
|
readonly name: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<readonly [import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
|
|
278
|
-
}, undefined
|
|
279
|
-
readonly entries: {
|
|
280
|
-
readonly aliasEmails: import("valibot").OptionalSchema<import("valibot").SchemaWithPipe<readonly [import("valibot").ArraySchema<import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<readonly [import("valibot").StringSchema<undefined>, import("valibot").RfcEmailAction<string, undefined>]>, undefined>, undefined>, import("valibot").MinLengthAction<string[], 1, undefined>, import("valibot").MaxLengthAction<string[], number, undefined>]>, undefined>;
|
|
281
|
-
readonly name: import("valibot").OptionalSchema<import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<readonly [import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>, undefined>;
|
|
282
|
-
};
|
|
283
|
-
readonly '~standard': import("valibot").StandardProps<{
|
|
284
|
-
aliasEmails?: string[] | undefined;
|
|
285
|
-
name?: string | undefined;
|
|
286
|
-
}, {
|
|
287
|
-
aliasEmails?: string[] | undefined;
|
|
288
|
-
name?: string | undefined;
|
|
289
|
-
}>;
|
|
290
|
-
readonly '~run': (dataset: import("valibot").UnknownDataset, config: import("valibot").Config<import("valibot").BaseIssue<unknown>>) => import("valibot").OutputDataset<{
|
|
291
|
-
aliasEmails?: string[] | undefined;
|
|
292
|
-
name?: string | undefined;
|
|
293
|
-
}, import("valibot").StringIssue | import("valibot").RfcEmailIssue<string> | import("valibot").NonEmptyIssue<string> | import("valibot").MaxLengthIssue<string, number> | import("valibot").ObjectIssue | import("valibot").ArrayIssue | import("valibot").NonOptionalIssue | import("valibot").MinLengthIssue<string[], 1> | import("valibot").MaxLengthIssue<string[], number>>;
|
|
294
|
-
readonly '~types'?: {
|
|
295
|
-
readonly input: {
|
|
296
|
-
aliasEmails?: string[] | undefined;
|
|
297
|
-
name?: string | undefined;
|
|
298
|
-
};
|
|
299
|
-
readonly output: {
|
|
300
|
-
aliasEmails?: string[] | undefined;
|
|
301
|
-
name?: string | undefined;
|
|
302
|
-
};
|
|
303
|
-
readonly issue: import("valibot").StringIssue | import("valibot").RfcEmailIssue<string> | import("valibot").NonEmptyIssue<string> | import("valibot").MaxLengthIssue<string, number> | import("valibot").ObjectIssue | import("valibot").ArrayIssue | import("valibot").NonOptionalIssue | import("valibot").MinLengthIssue<string[], 1> | import("valibot").MaxLengthIssue<string[], number>;
|
|
304
|
-
} | undefined;
|
|
305
|
-
};
|
|
306
|
-
readonly viewId: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<readonly [import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
|
|
279
|
+
}, undefined>;
|
|
307
280
|
}, undefined>;
|
|
308
281
|
};
|
|
309
282
|
};
|
|
@@ -829,18 +802,18 @@ export declare const marcoZero: {
|
|
|
829
802
|
}, unknown>;
|
|
830
803
|
readonly updateView: import("@rocicorp/zero").MutatorDefinition<{
|
|
831
804
|
id: string;
|
|
832
|
-
|
|
833
|
-
aliasEmails
|
|
834
|
-
|
|
805
|
+
view: {
|
|
806
|
+
aliasEmails: string[];
|
|
807
|
+
id: string;
|
|
808
|
+
name: string;
|
|
835
809
|
};
|
|
836
|
-
viewId: string;
|
|
837
810
|
}, {
|
|
838
811
|
id: string;
|
|
839
|
-
|
|
840
|
-
aliasEmails
|
|
841
|
-
|
|
812
|
+
view: {
|
|
813
|
+
aliasEmails: string[];
|
|
814
|
+
id: string;
|
|
815
|
+
name: string;
|
|
842
816
|
};
|
|
843
|
-
viewId: string;
|
|
844
817
|
}, {
|
|
845
818
|
userId: string;
|
|
846
819
|
}, unknown>;
|
package/dist/zero/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/zero/index.ts"],"names":[],"mappings":"AAKA,eAAO,MAAM,SAAS
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/zero/index.ts"],"names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emas: {
|
|
|
272
272
|
}, undefined>;
|
|
273
273
|
updateView: v.ObjectSchema<{
|
|
274
274
|
readonly id: v.NonOptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.NonEmptyAction<string, undefined>, v.MaxLengthAction<string, number, undefined>]>, undefined>;
|
|
275
|
-
readonly
|
|
275
|
+
readonly view: v.ObjectSchema<{
|
|
276
276
|
readonly aliasEmails: v.SchemaWithPipe<readonly [v.ArraySchema<v.NonOptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RfcEmailAction<string, undefined>]>, undefined>, undefined>, v.MinLengthAction<string[], 1, undefined>, v.MaxLengthAction<string[], number, undefined>]>;
|
|
277
|
+
readonly id: v.NonOptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.NonEmptyAction<string, undefined>, v.MaxLengthAction<string, number, undefined>]>, undefined>;
|
|
277
278
|
readonly name: v.NonOptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.NonEmptyAction<string, undefined>, v.MaxLengthAction<string, number, undefined>]>, undefined>;
|
|
278
|
-
}, undefined
|
|
279
|
-
readonly entries: {
|
|
280
|
-
readonly aliasEmails: v.OptionalSchema<v.SchemaWithPipe<readonly [v.ArraySchema<v.NonOptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RfcEmailAction<string, undefined>]>, undefined>, undefined>, v.MinLengthAction<string[], 1, undefined>, v.MaxLengthAction<string[], number, undefined>]>, undefined>;
|
|
281
|
-
readonly name: v.OptionalSchema<v.NonOptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.NonEmptyAction<string, undefined>, v.MaxLengthAction<string, number, undefined>]>, undefined>, undefined>;
|
|
282
|
-
};
|
|
283
|
-
readonly '~standard': v.StandardProps<{
|
|
284
|
-
aliasEmails?: string[] | undefined;
|
|
285
|
-
name?: string | undefined;
|
|
286
|
-
}, {
|
|
287
|
-
aliasEmails?: string[] | undefined;
|
|
288
|
-
name?: string | undefined;
|
|
289
|
-
}>;
|
|
290
|
-
readonly '~run': (dataset: v.UnknownDataset, config: v.Config<v.BaseIssue<unknown>>) => v.OutputDataset<{
|
|
291
|
-
aliasEmails?: string[] | undefined;
|
|
292
|
-
name?: string | undefined;
|
|
293
|
-
}, v.StringIssue | v.RfcEmailIssue<string> | v.NonEmptyIssue<string> | v.MaxLengthIssue<string, number> | v.ObjectIssue | v.ArrayIssue | v.NonOptionalIssue | v.MinLengthIssue<string[], 1> | v.MaxLengthIssue<string[], number>>;
|
|
294
|
-
readonly '~types'?: {
|
|
295
|
-
readonly input: {
|
|
296
|
-
aliasEmails?: string[] | undefined;
|
|
297
|
-
name?: string | undefined;
|
|
298
|
-
};
|
|
299
|
-
readonly output: {
|
|
300
|
-
aliasEmails?: string[] | undefined;
|
|
301
|
-
name?: string | undefined;
|
|
302
|
-
};
|
|
303
|
-
readonly issue: v.StringIssue | v.RfcEmailIssue<string> | v.NonEmptyIssue<string> | v.MaxLengthIssue<string, number> | v.ObjectIssue | v.ArrayIssue | v.NonOptionalIssue | v.MinLengthIssue<string[], 1> | v.MaxLengthIssue<string[], number>;
|
|
304
|
-
} | undefined;
|
|
305
|
-
};
|
|
306
|
-
readonly viewId: v.NonOptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.NonEmptyAction<string, undefined>, v.MaxLengthAction<string, number, undefined>]>, undefined>;
|
|
279
|
+
}, undefined>;
|
|
307
280
|
}, undefined>;
|
|
308
281
|
};
|
|
309
282
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"mutatorSchemas.d.ts","sourceRoot":"","sources":["../../src/zero/mutatorSchemas.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,CAAC,MAAM,SAAS,CAAA;AAgF5B,eAAO,MAAM,cAAc
|
|
1
|
+
{"version":3,"file":"mutatorSchemas.d.ts","sourceRoot":"","sources":["../../src/zero/mutatorSchemas.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,CAAC,MAAM,SAAS,CAAA;AAgF5B,eAAO,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAsJ1B,CAAA"}
|
|
@@ -206,11 +206,7 @@ export const mutatorSchemas = {
|
|
|
206
206
|
}),
|
|
207
207
|
updateView: v.object({
|
|
208
208
|
id: marcoSchemas.string.required(),
|
|
209
|
-
|
|
210
|
-
aliasEmails: v.pipe(v.array(marcoSchemas.string.email()), v.minLength(1), v.maxLength(marcoConstants.user.views.maxAliasEmailsPerView)),
|
|
211
|
-
name: marcoSchemas.string.required(),
|
|
212
|
-
})),
|
|
213
|
-
viewId: marcoSchemas.string.required(),
|
|
209
|
+
view: userViewSchema,
|
|
214
210
|
}),
|
|
215
211
|
},
|
|
216
212
|
};
|
package/dist/zero/mutators.d.ts
CHANGED
|
@@ -459,18 +459,18 @@ export declare const mutators: import("@rocicorp/zero").MutatorRegistry<{
|
|
|
459
459
|
}, Context, unknown>;
|
|
460
460
|
readonly updateView: import("@rocicorp/zero").MutatorDefinition<{
|
|
461
461
|
id: string;
|
|
462
|
-
|
|
463
|
-
aliasEmails
|
|
464
|
-
|
|
462
|
+
view: {
|
|
463
|
+
aliasEmails: string[];
|
|
464
|
+
id: string;
|
|
465
|
+
name: string;
|
|
465
466
|
};
|
|
466
|
-
viewId: string;
|
|
467
467
|
}, {
|
|
468
468
|
id: string;
|
|
469
|
-
|
|
470
|
-
aliasEmails
|
|
471
|
-
|
|
469
|
+
view: {
|
|
470
|
+
aliasEmails: string[];
|
|
471
|
+
id: string;
|
|
472
|
+
name: string;
|
|
472
473
|
};
|
|
473
|
-
viewId: string;
|
|
474
474
|
}, Context, unknown>;
|
|
475
475
|
};
|
|
476
476
|
}, {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"mutators.d.ts","sourceRoot":"","sources":["../../src/zero/mutators.ts"],"names":[],"mappings":"AASA,KAAK,OAAO,GAAG;IAAE,MAAM,EAAE,MAAM,CAAA;CAAE,CAAA;AAqGjC,eAAO,MAAM,QAAQ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAwiBnB,CAAA"}
|
package/dist/zero/mutators.js
CHANGED
|
@@ -535,14 +535,12 @@ export const mutators = defineMutators({
|
|
|
535
535
|
updateView: defineMutator(mutatorSchemas.user.updateView, async ({ tx, args }) => {
|
|
536
536
|
const user = await tx.run(zql.user.where('id', args.id).one());
|
|
537
537
|
if (user) {
|
|
538
|
-
const viewExists = (user.views ?? []).some(x => x.id === args.
|
|
538
|
+
const viewExists = (user.views ?? []).some(x => x.id === args.view.id);
|
|
539
539
|
if (viewExists) {
|
|
540
|
-
const deduplicatedEmails =
|
|
540
|
+
const deduplicatedEmails = [...new Set(args.view.aliasEmails)];
|
|
541
541
|
await tx.mutate.user.update({
|
|
542
542
|
id: args.id,
|
|
543
|
-
views: (user.views ?? []).map(x => x.id === args.
|
|
544
|
-
? { ...x, aliasEmails: deduplicatedEmails ?? x.aliasEmails, name: args.updates.name ?? x.name }
|
|
545
|
-
: x),
|
|
543
|
+
views: (user.views ?? []).map(x => x.id === args.view.id ? { ...args.view, aliasEmails: deduplicatedEmails } : x),
|
|
546
544
|
});
|
|
547
545
|
}
|
|
548
546
|
}
|