@@ -155,13 +155,15 @@ export class SynchronizedFormImpl<
|
|||||||
Stream.drop(this.target.changes, 1),
|
Stream.drop(this.target.changes, 1),
|
||||||
targetValue => Schema.encode(this.schema, { errors: "all" })(targetValue).pipe(
|
targetValue => Schema.encode(this.schema, { errors: "all" })(targetValue).pipe(
|
||||||
Effect.flatMap(encodedValue => Effect.whenEffect(
|
Effect.flatMap(encodedValue => Effect.whenEffect(
|
||||||
|
Effect.andThen(
|
||||||
|
Lens.set(this.issues, Array.empty()),
|
||||||
Lens.set(this.internalEncodedValue, encodedValue),
|
Lens.set(this.internalEncodedValue, encodedValue),
|
||||||
|
),
|
||||||
Effect.map(
|
Effect.map(
|
||||||
Lens.get(this.internalEncodedValue),
|
Lens.get(this.internalEncodedValue),
|
||||||
currentEncodedValue => !Equal.equals(encodedValue, currentEncodedValue),
|
currentEncodedValue => !Equal.equals(encodedValue, currentEncodedValue),
|
||||||
),
|
),
|
||||||
)),
|
)),
|
||||||
Effect.andThen(Lens.set(this.issues, Array.empty())),
|
|
||||||
Effect.ignore,
|
Effect.ignore,
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
|||||||
Reference in New Issue
Block a user