Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@kizahasi/flocon-core

Package Overview
Dependencies
Maintainers
1
Versions
74
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@kizahasi/flocon-core - npm Package Compare versions

Comparing version 0.15.1 to 0.15.2

4

dist/cjs/internal/ot/room/character/simpleValueParam/v1.js

@@ -117,3 +117,3 @@ "use strict";

}
return { ...resultType };
return resultType;
};

@@ -168,2 +168,2 @@ exports.diff = diff;

exports.clientTransform = clientTransform;
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoidjEuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi8uLi8uLi9zcmMvaW50ZXJuYWwvb3Qvcm9vbS9jaGFyYWN0ZXIvc2ltcGxlVmFsdWVQYXJhbS92MS50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiOzs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7O0FBUUEsc0ZBQXdFO0FBQ3hFLGlEQUFrRDtBQUNsRCxpRkFBbUU7QUFDbkUsNkNBQTBDO0FBOEJuQyxNQUFNLGFBQWEsR0FDdEIsQ0FBSSxZQUFxQixFQUFFLFlBQWUsRUFBRSxFQUFFLENBQzlDLENBQUMsTUFBZ0IsRUFBWSxFQUFFO0lBQzNCLE9BQU87UUFDSCxHQUFHLE1BQU07UUFDVCxLQUFLLEVBQUUsTUFBTSxDQUFDLGNBQWMsSUFBSSxDQUFDLFlBQVksQ0FBQyxDQUFDLENBQUMsWUFBWSxDQUFDLENBQUMsQ0FBQyxNQUFNLENBQUMsS0FBSztLQUM5RSxDQUFDO0FBQ04sQ0FBQyxDQUFDO0FBUE8sUUFBQSxhQUFhLGlCQU9wQjtBQUVDLE1BQU0sZUFBZSxHQUFHLENBQUksTUFBMEIsRUFBb0IsRUFBRTtJQUMvRSxPQUFPLE1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PiB7XHJcbiAgICAgICAgY29uc3QgcmVzdWx0OiBTdGF0ZTxUPiA9IHsgLi4uc3RhdGUgfTtcclxuICAgICAgICBpZiAob3BlcmF0aW9uLmlzVmFsdWVQcml2YXRlICE9IG51bGwpIHtcclxuICAgICAgICAgICAgcmVzdWx0LmlzVmFsdWVQcml2YXRlID0gb3BlcmF0aW9uLmlzVmFsdWVQcml2YXRlLm9sZFZhbHVlO1xyXG4gICAgICAgIH1cclxuICAgICAgICBpZiAob3BlcmF0aW9uLnZhbHVlICE9IG51bGwpIHtcclxuICAgICAgICAgICAgcmVzdWx0LnZhbHVlID0gb3BlcmF0aW9uLnZhbHVlLm9sZFZhbHVlO1xyXG4gICAgICAgIH1cclxuICAgICAgICByZXR1cm4gUmVzdWx0Lm9rKHJlc3VsdCk7XHJcbiAgICB9O1xyXG5cclxuZXhwb3J0IGNvbnN0IGNvbXBvc2VEb3duT3BlcmF0aW9uID1cclxuICAgIDxUPigpOiBDb21wb3NlPERvd25PcGVyYXRpb248VD4+ID0+XHJcbiAgICAoeyBmaXJzdCwgc2Vjb25kIH0pID0+IHtcclxuICAgICAgICBjb25zdCB2YWx1ZVByb3BzOiBEb3duT3BlcmF0aW9uPFQ+ID0ge1xyXG4gICAgICAgICAgICAkdmVyc2lvbjogMSxcclxuICAgICAgICAgICAgaXNWYWx1ZVByaXZhdGU6IFJlcGxhY2VWYWx1ZU9wZXJhdGlvbi5jb21wb3NlRG93bk9wZXJhdGlvbihcclxuICAgICAgICAgICAgICAgIGZpcnN0LmlzVmFsdWVQcml2YXRlLFxyXG4gICAgICAgICAgICAgICAgc2Vjb25kLmlzVmFsdWVQcml2YXRlXHJcbiAgICAgICAgICAgICksXHJcbiAgICAgICAgICAgIHZhbHVlOiBSZXBsYWNlVmFsdWVPcGVyYXRpb24uY29tcG9zZURvd25PcGVyYXRpb24oZmlyc3QudmFsdWUsIHNlY29uZC52YWx1ZSksXHJcbiAgICAgICAgfTtcclxuICAgICAgICByZXR1cm4gUm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uICAgICAgICB9KTtcclxuICAgIH07XHJcbiJdfQ==

@@ -154,3 +154,3 @@ "use strict";

}
return { ...resultType };
return resultType;
};

@@ -212,2 +212,2 @@ exports.diff = diff;

exports.clientTransform = clientTransform;
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoidjEuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi8uLi8uLi9zcmMvaW50ZXJuYWwvb3Qvcm9vbS9jaGFyYWN0ZXIvc3RyUGFyYW0vdjEudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6Ijs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7OztBQUFBLHlDQUEyQjtBQUMzQiwyRUFBNkQ7QUFDN0QsaUZBQW1FO0FBU25FLG1FQUFnRTtBQUNoRSxpREFBa0Q7QUFDbEQsNkNBQTBDO0FBRTdCLFFBQUEsS0FBSyxHQUFHLENBQUMsQ0FBQyxJQUFJLENBQUM7SUFDeEIsUUFBUSxFQUFFLENBQUMsQ0FBQyxPQUFPLENBQUMsQ0FBQyxDQUFDO0lBRXRCLGNBQWMsRUFBRSxDQUFDLENBQUMsT0FBTztJQUN6QixLQUFLLEVBQUUsQ0FBQyxDQUFDLE1BQU07Q0FDbEIsQ0FBQyxDQUFDO0FBSVUsUUFBQSxhQUFhLEdBQUcsaUNBQWUsQ0FBQyxDQUFDLEVBQUU7SUFDNUMsY0FBYyxFQUFFLENBQUMsQ0FBQyxJQUFJLENBQUMsRUFBRSxRQUFRLEVBQUUsQ0FBQyxDQUFDLE9BQU8sRUFBRSxDQUFDO0lBQy9DLEtBQUssRUFBRSxhQUFhLENBQUMsYUFBYTtDQUNyQyxDQUFDLENBQUM7QUFJVSxRQUFBLFdBQVcsR0FBRyxpQ0FBZSxDQUFDLENBQUMsRUFBRTtJQUMxQyxjQUFjLEVBQUUsQ0FBQyxDQUFDLElBQUksQ0FBQyxFQUFFLFFBQVEsRUFBRS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gICAgICAgZmlyc3Q6IHNlcnZlck9wZXJhdGlvbj8uaXNWYWx1ZVByaXZhdGUsXHJcbiAgICAgICAgICAgICAgICBzZWNvbmQ6IGNsaWVudE9wZXJhdGlvbi5pc1ZhbHVlUHJpdmF0ZSxcclxuICAgICAgICAgICAgICAgIHByZXZTdGF0ZTogcHJldlN0YXRlLmlzVmFsdWVQcml2YXRlLFxyXG4gICAgICAgICAgICB9KTtcclxuICAgICAgICB9XHJcbiAgICAgICAgaWYgKGlzQXV0aG9yaXplZCB8fCAhY3VycmVudFN0YXRlLmlzVmFsdWVQcml2YXRlKSB7XHJcbiAgICAgICAgICAgIGNvbnN0IHRyYW5zZm9ybWVkID0gVGV4dE9wZXJhdGlvbi5zZXJ2ZXJUcmFuc2Zvcm0oe1xyXG4gICAgICAgICAgICAgICAgZmlyc3Q6IHNlcnZlck9wZXJhdGlvbj8udmFsdWUsXHJcbiAgICAgICAgICAgICAgICBzZWNvbmQ6IGNsaWVudE9wZXJhdGlvbi52YWx1ZSxcclxuICAgICAgICAgICAgICAgIHByZXZTdGF0ZTogcHJldlN0YXRlLnZhbHVlLFxyXG4gICAgICAgICAgICB9KTtcclxuICAgICAgICAgICAgaWYgKHRyYW5zZm9ybWVkLmlzRXJyb3IpIHtcclxuICAgICAgICAgICAgICAgIHJldHVybiB0cmFuc2Zvcm1lZDtcclxuICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICB0d29XYXlPcGVyYXRpb24udmFsdWUgPSB0cmFuc2Zvcm1lZC52YWx1ZS5zZWNvbmRQcmltZTtcclxuICAgICAgICB9XHJcblxyXG4gICAgICAgIGlmIChpc0lkUmVjb3JkKHR3b1dheU9wZXJhdGlvbikpIHtcclxuICAgICAgICAgICAgcmV0dXJuIFJlc3VsdC5vayh1bmRlZmluZWQpO1xyXG4gICAgICAgIH1cclxuXHJcbiAgICAgICAgcmV0dXJuIFJlc3VsdC5vayh0d29XYXlPcGVyYXRpb24pO1xyXG4gICAgfTtcclxuXHJcbm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KHtcclxuICAgICAgICBmaXJzdFByaW1lOiBpc0lkUmVjb3JkKGZpcnN0UHJpbWUpID8gdW5kZWZpbmVkIDogZmlyc3RQcmltZSxcclxuICAgICAgICBzZWNvbmRQcmltZTogaXNJZFJlY29yZChzZWNvbmRQcmltZSkgPyB1bmRlZmluZWQgOiBzZWNvbmRQcmltZSxcclxuICAgIH0pO1xyXG59O1xyXG4iXX0=

@@ -82,2 +82,5 @@ "use strict";

}
if (operation.isPrivate != null) {
result.isPrivate = operation.isPrivate.newValue;
}
if (operation.memo != null) {

@@ -112,2 +115,5 @@ const valueResult = TextOperation.apply(state.memo, operation.memo);

}
if (operation.isPrivate != null) {
result.isPrivate = operation.isPrivate.oldValue;
}
if (operation.memo != null) {

@@ -155,5 +161,6 @@ const valueResult = TextOperation.applyBack(state.memo, operation.memo);

$version: 1,
image: ReplaceOperation.composeDownOperation(first.image, second.image),
isPrivate: ReplaceOperation.composeDownOperation(first.isPrivate, second.isPrivate),
memo: memo.value,
name: ReplaceOperation.composeDownOperation(first.name, second.name),
image: ReplaceOperation.composeDownOperation(first.image, second.image),
pieces: pieces.value,

@@ -165,3 +172,3 @@ };

const restore = ({ nextState, downOperation, }) => {
var _a, _b;
var _a, _b, _c, _d;
if (downOperation === undefined) {

@@ -194,2 +201,9 @@ return result_1.Result.ok({ prevState: nextState, twoWayOperation: undefined });

}
if (downOperation.isPrivate !== undefined) {
prevState.isPrivate = (_c = downOperation.isPrivate.oldValue) !== null && _c !== void 0 ? _c : undefined;
twoWayOperation.isPrivate = {
oldValue: (_d = downOperation.isPrivate.oldValue) !== null && _d !== void 0 ? _d : undefined,
newValue: nextState.isPrivate,
};
}
if (downOperation.memo !== undefined) {

@@ -229,2 +243,5 @@ const restored = TextOperation.restore({

}
if (prevState.isPrivate !== nextState.isPrivate) {
result.isPrivate = { oldValue: prevState.isPrivate, newValue: nextState.isPrivate };
}
if (prevState.memo !== nextState.memo) {

@@ -276,2 +293,7 @@ result.memo = TextOperation.diff({

});
twoWayOperation.isPrivate = ReplaceOperation.serverTransform({
first: serverOperation === null || serverOperation === void 0 ? void 0 : serverOperation.isPrivate,
second: clientOperation.isPrivate,
prevState: prevState.isPrivate,
});
const transformedMemo = TextOperation.serverTransform({

@@ -302,2 +324,6 @@ first: serverOperation === null || serverOperation === void 0 ? void 0 : serverOperation.memo,

});
const isPrivate = ReplaceOperation.clientTransform({
first: first.isPrivate,
second: second.isPrivate,
});
const memo = TextOperation.clientTransform({

@@ -326,2 +352,3 @@ first: first.memo,

image: image.firstPrime,
isPrivate: isPrivate.firstPrime,
memo: memo.value.firstPrime,

@@ -334,2 +361,3 @@ name: name.firstPrime,

image: image.secondPrime,
isPrivate: isPrivate.secondPrime,
memo: memo.value.firstPrime,

@@ -345,2 +373,2 @@ name: name.secondPrime,

exports.clientTransform = clientTransform;
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoidjEuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi8uLi8uLi9zcmMvaW50ZXJuYWwvb3Qvcm9vbS9wYXJ0aWNpcGFudC9pbWFnZVBpZWNlVmFsdWUvdjEudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6Ijs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7OztBQUFBLHlDQUEyQjtBQUMzQixpRkFBbUU7QUFVbkUsbUVBQWdFO0FBQ2hFLGlEQUEwRDtBQUMxRCw2Q0FBMEM7QUFFMUMsNkNBQTBEO0FBQzFELDJFQUE2RDtBQUM3RCx5REFBMkM7QUFDM0MsaUZBRzhDO0FBQzlDLDZGQUErRTtBQUUvRSwrQ0FBbUQ7QUFFdEMsUUFBQSxLQUFLLEdBQUcsQ0FBQyxDQUFDLElBQUksQ0FBQztJQUN4QixRQUFRLEVBQUUsQ0FBQyxDQUFDLE9BQU8sQ0FBQyxDQUFDLENBQUM7SUFDdEIsS0FBSyxFQUFFLGFBQUssQ0FBQyxh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UG9zaXRpdmVJbnQ+IHwgQ29tcG9zZUFuZFRyYW5zZm9ybUVycm9yXHJcbiAgICAgICAgPih7XHJcbiAgICAgICAgICAgIHByZXZTdGF0ZTogcHJldlN0YXRlLnBpZWNlcyxcclxuICAgICAgICAgICAgbmV4dFN0YXRlOiBjdXJyZW50U3RhdGUucGllY2VzLFxyXG4gICAgICAgICAgICBmaXJzdDogc2VydmVyT3BlcmF0aW9uPy5waWVjZXMsXHJcbiAgICAgICAgICAgIHNlY29uZDogY2xpZW50T3BlcmF0aW9uLnBpZWNlcyxcclxuICAgICAgICAgICAgaW5uZXJUcmFuc2Zvcm06ICh7IHByZXZTdGF0ZSwgbmV4dFN0YXRlLCBmaXJzdCwgc2Vjb25kIH0pID0+XHJcbiAgICAgICAgICAgICAgICBQaWVjZS5zZXJ2ZXJUcmFuc2Zvcm0oe1xyXG4gICAgICAgICAgICAgICAgICAgIHByZXZTdGF0ZSxcclxuICAgICAgICAgICAgICAgICAgICBjdXJyZW50U3RhdGU6IG5leHRTdGF0ZSxcclxuICAgICAgICAgICAgICAgICAgICBzZXJ2ZXJPcGVyYXRpb246IGZpcnN0LFxyXG4gICAgICAgICAgICAgICAgICAgIGNsaWVudE9wZXJhdGlvbjogc2Vjb25kLFxyXG4gICAgICAgICAgICAgICAgfSksXHJcbiAgICAgICAgICAgIHRvU2VydmVyU3RhdGU6IHN0YXRlID0+IHN0YXRlLFxyXG4gICAgICAgICAgICBjYW5jZWxsYXRpb25Qb2xpY3k6IHtcclxuICAgICAgICAgICAgICAgIGNhbmNlbENyZWF0ZTogKCkgPT4gIWlzQXV0aG9yaXplZCxcclxuICAgICAgICAgICAgICAgIGNhbmNlbFJlbW92ZTogcGFyYW1zID0+ICFpc0F1dGhvcml6ZWQgJiYgcGFyYW1zLm5leHRTdGF0ZS5pc1ByaXZhdGUsXHJcbiAgICAgICAgICAgICAgICBjYW5jZWxVcGRhdGU6IHBhcmFtcyA9PiAhaXNBdXRob3JpemVkICYmIHBhcmF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cmF0aW9uLCBVcE9wZXJhdGlvbj4gPT5cclxuICAgICh7IHByZXZTdGF0ZSwgY3VycmVudFN0YXRlLCBjbGllbnRPcGVyYXRpb24sIHNlcnZlck9wZXJhdGlvbiB9KSA9PiB7XHJcbiAgICAgICAgY29uc3QgcGllY2VzID0gRHVhbEtleVJlY29yZE9wZXJhdGlvbi5zZXJ2ZXJUcmFuc2Zvcm08XHJcbiAgICAgICAgICAgIFBpZWNlLlN0YXRlLFxyXG4gICAgICAgICAgICBQaWVjZS5TdGF0ZSxcclxuICAgICAgICAgICAgUGllY2UuVHdvV2F5T3BlcmF0aW9uLFxyXG4gICAgICAgICAgICBQaWVjZS5VcE9wZXJhdGlvbixcclxuICAgICAgICAgICAgc3RyaW5nIHwgQXBwbHlFcnJvcjxQb3NpdGl2ZUludD4gfCBDb21wb3NlQW5kVHJhbnNmb3JtRXJyb3JcclxuICAgICAgICA+KHtcclxuICAgICAgICAgICAgcHJldlN0YXRlOiBwcmV2U3RhdGUucGllY2VzLFxyXG4gICAgICAgICAgICBuZXh0U3RhdGU6IGN1cnJlbnRTdGF0ZS5waWVjZXMsXHJcbiAgICAgICAgICAgIGZpcnN0OiBzZXJ2ZXJPcGVyYXRpb24/LnBpZWNlcyxcclxuICAgICAgICAgICAgc2Vjb25kOiBjbGllbnRPcGVyYXRpb24ucGllY2VzLFxyXG4gICAgICAgICAgICBpbm5lclRyYW5zZm9ybTogKHsgcHJldlN0YXRlLCBuZXh0U3RhdGUsIGZpcnN0LCBzZWNvbmQgfSkgPT5cclxuICAgICAgICAgICAgICAgIFBpZWNlLnNlcnZlclRyYW5zZm9ybSh7XHJcbiAgICAgICAgICAgICAgICAgICAgcHJldlN0YXRlLFxyXG4gICAgICAgICAgICAgICAgICAgIGN1cnJlbnRTdGF0ZTogbmV4dFN0YXRlLFxyXG4gICAgICAgICAgICAgICAgICAgIHNlcnZlck9wZXJhdGlvbjogZmlyc3QsXHJcbiAgICAgICAgICAgICAgICAgICAgY2xpZW50T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WdlLnNlY29uZFByaW1lLFxyXG4gICAgICAgIGlzUHJpdmF0ZTogaXNQcml2YXRlLnNlY29uZFByaW1lLFxyXG4gICAgICAgIG1lbW86IG1lbW8udmFsdWUuZmlyc3RQcmltZSxcclxuICAgICAgICBuYW1lOiBuYW1lLnNlY29uZFByaW1lLFxyXG4gICAgICAgIHBpZWNlczogcGllY2VzLnZhbHVlLnNlY29uZFByaW1lLFxyXG4gICAgfTtcclxuXHJcbiAgICByZXR1cm4gUmVzdWx0Lm9rKHtcclxuICAgICAgICBmaXJzdFByaW1lOiBpc0lkUmVjb3JkKGZpcnN0UHJpbWUpID8gdW5kZWZpbmVkIDogZmlyc3RQcmltZSxcclxuICAgICAgICBzZWNvbmRQcmltZTogaXNJZFJlY29yZChzZWNvbmRQcmltZSkgPyB1bmRlZmluZWQgOiBzZWNvbmRQcmltZSxcclxuICAgIH0pO1xyXG59O1xyXG4iXX0=

@@ -36,3 +36,2 @@ "use strict";

}
break;
}

@@ -63,3 +62,2 @@ return result_1.Result.ok({

nextState.set(key, newValue.value);
break;
}

@@ -87,3 +85,2 @@ return result_1.Result.ok(util_1.mapToRecord(nextState));

prevState.set(key, oldValue.value);
break;
}

@@ -244,2 +241,2 @@ return result_1.Result.ok(util_1.mapToRecord(prevState));

exports.diff = diff;
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicGFyYW1SZWNvcmRPcGVyYXRpb24uanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi9zcmMvaW50ZXJuYWwvb3QvdXRpbC9wYXJhbVJlY29yZE9wZXJhdGlvbi50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiOzs7QUFBQSw2Q0FBd0Q7QUFDeEQseUNBQTJGO0FBZXBGLE1BQU0sT0FBTyxHQUFHLENBQWtFLEVBQ3JGLFNBQVMsRUFBRSxlQUFlLEVBQzFCLGFBQWEsRUFBRSxtQkFBbUIsR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ZXMgbm90IGhhdmUgc3VjaCBhIGtleWApO1xyXG4gICAgICAgIH1cclxuICAgICAgICBjb25zdCByZXN0b3JlZCA9IGlubmVyUmVzdG9yZSh7XHJcbiAgICAgICAgICAgIGRvd25PcGVyYXRpb246IHZhbHVlLFxyXG4gICAgICAgICAgICBuZXh0U3RhdGU6IG5leHRTdGF0ZUVsZW1lbnQsXHJcbiAgICAgICAgICAgIGtleSxcclxuICAgICAgICB9KTtcclxuICAgICAgICBpZiAocmVzdG9yZWQuaXNFcnJvcikge1xyXG4gICAgICAgICAgICByZXR1cm4gcmVzdG9yZWQ7XHJcbiAgICAgICAgfVxyXG4gICAgICAgIGlmIChyZXN0b3JlZC52YWx1ZSA9PT0gdW5kZWZpbmVkKSB7XHJcbiAgICAgICAgICAgIGNvbnRpbnVlO1xyXG4gICAgICAgIH1cclxuICAgICAgICBwcmV2U3RhdGUuc2V0KGtleSwgcmVzdG9yZWQudmFsdWUucHJldlN0YXRlKTtcclxuICAgICAgICBpZiAocmVzdG9yZWQudmFsdWUudHdvV2F5T3BlcmF0aW9uICE9PSB1bmRlZmluZWQpIHtcclxuICAgICAgICAgICAgdHdvV2F5T3BlcmF0aW9uLnNldChrZXksIHJlc3RvcmVkLnZhbHVlLnR3b1dheU9wZXJhdGlvbik7XHJcbiAgICAgICAgfVxyXG4gICAgICAgIGJyZWFrO1xyXG4gICAgfVxyXG5cclxuICAgIHJldHVybiBSZXN1bHQub2soe1xyXG4gICAgICAgIHByZXZTdGF0ZTogbWFwVG9SZWNvcmQocHJldlN0YXRlKSxcclxuICAgICAgICB0d29XYXlPcGVyYXRpb246IG1hcFRvUmVjb3JkKHR3b1dheU9wZXJhdGlvbiksXHJcbiAgICB9KTtcclxufTtcclxuXHJcbmV4cG9ydCBjb25zdCBhcHBseSA9IDxUU3RhdGUsIFRVcE9wZXJhdGlvbiwgVEN1c3RvbUVycm9yID0gc3RyaW5nPih7XHJcbiAgICBwcmV2U3RhdGU6IHVuc2FmZVByZXZTdG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3VwSm9pbmVkLmxlZnQpO1xyXG4gICAgICAgICAgICAgICAgY29udGludWU7XHJcbiAgICAgICAgICAgIGNhc2UgcmlnaHQ6XHJcbiAgICAgICAgICAgICAgICByZXN1bHQuc2V0KGtleSwgZ3JvdXBKb2luZWQucmlnaHQpO1xyXG4gICAgICAgICAgICAgICAgY29udGludWU7XHJcbiAgICAgICAgICAgIGNhc2UgYm90aDoge1xyXG4gICAgICAgICAgICAgICAgY29uc3QgdXBkYXRlID0gaW5uZXJDb21wb3NlKHtcclxuICAgICAgICAgICAgICAgICAgICBmaXJzdDogZ3JvdXBKb2luZWQubGVmdCxcclxuICAgICAgICAgICAgICAgICAgICBzZWNvbmQ6IGdyb3VwSm9pbmVkLnJpZ2h0LFxyXG4gICAgICAgICAgICAgICAgICAgIGtleSxcclxuICAgICAgICAgICAgICAgIH0pO1xyXG4gICAgICAgICAgICAgICAgaWYgKHVwZGF0ZS5pc0Vycm9yKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgcmV0dXJuIHVwZGF0ZTtcclxuICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgICAgIGlmICh1cGRhdGUudmFsdWUgIT09IHVuZGVmaW5lZCkge1xyXG4gICAgICAgICAgICAgICAgICAgIHJlc3VsdC5zZXQoa2V5LCB1cGRhdGUudmFsdWUpO1xyXG4gICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgY29udGludWU7XHJcbiAgICAgICAgICAgIH1cclxuICAgICAgICB9XHJcbiAgICB9XHJcbiAgICByZXR1cm4gUmVzdWx0Lm9rKG1hcFRvUmVjb3JkKHJlc3VsdCkpO1xyXG59O1xyXG5cclxuLy8gTWFrZSBzdXJlIHRoZXNlOlxyXG4vLyAtIGFwcGx5KHByZXZTdGF0ZSwgZmlyc3QpID0gbmV4dFN0YXRlXHJcbmV4cG9ydCBjb25zdCBzZXJ2ZXJUcmFuc2Zvcm0gPSA8XHJcbiAgICBUU2VydmVyU3RhdGUsXHJcbiAgIC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RjaCAoZ3JvdXAudHlwZSkge1xyXG4gICAgICAgICAgICBjYXNlIGxlZnQ6IHtcclxuICAgICAgICAgICAgICAgIGZpcnN0UHJpbWUuc2V0KGtleSwgZ3JvdXAubGVmdCk7XHJcbiAgICAgICAgICAgICAgICByZXR1cm47XHJcbiAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgY2FzZSByaWdodDoge1xyXG4gICAgICAgICAgICAgICAgc2Vjb25kUHJpbWUuc2V0KGtleSwgZ3JvdXAucmlnaHQpO1xyXG4gICAgICAgICAgICAgICAgcmV0dXJuO1xyXG4gICAgICAgICAgICB9XHJcbiAgICAgICAgICAgIGNhc2UgYm90aDoge1xyXG4gICAgICAgICAgICAgICAgY29uc3QgeGZvcm0gPSBpbm5lclRyYW5zZm9ybSh7XHJcbiAgICAgICAgICAgICAgICAgICAgZmlyc3Q6IGdyb3VwLmxlZnQsXHJcbiAgICAgICAgICAgICAgICAgICAgc2Vjb25kOiBncm91cC5yaWdodCxcclxuICAgICAgICAgICAgICAgIH0pO1xyXG4gICAgICAgICAgICAgICAgaWYgKHhmb3JtLmlzRXJyb3IpIHtcclxuICAgICAgICAgICAgICAgICAgICBlcnJvciA9IHsgZXJyb3I6IHhmb3JtLmVycm9yIH07XHJcbiAgICAgICAgICAgICAgICAgICAgcmV0dXJuO1xyXG4gICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgaWYgKHhmb3JtLnZhbHVlLmZpcnN0UHJpbWUgIT09IHVuZGVmaW5lZCkge1xyXG4gICAgICAgICAgICAgICAgICAgIGZpcnN0UHJpbWUuc2V0KGtleSwgeGZvcm0udmFsdWUuZmlyc3RQcmltZSk7XHJcbiAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgICAgICBpZiAoeGZvcm0udmFsdWUuc2Vjb25kUHJpbWUgIT09IHVuZGVmaW5lZCkge1xyXG4gICAgICAgICAgICAgICAgICAgIHNlY29uZFByaW1lLnNldChrZXksIHhmb3JtLnZhbHVlL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ID0gbmV3IE1hcDxzdHJpbmcsIFRPcGVyYXRpb24+KCk7XHJcbiAgICBmb3IgKGNvbnN0IFtrZXksIHZhbHVlXSBvZiBncm91cEpvaW5NYXAocmVjb3JkVG9NYXAocHJldlN0YXRlKSwgcmVjb3JkVG9NYXAobmV4dFN0YXRlKSkpIHtcclxuICAgICAgICBsZXQgcHJldlN0YXRlOiBUU3RhdGUgfCB1bmRlZmluZWQgPSB1bmRlZmluZWQ7XHJcbiAgICAgICAgbGV0IG5leHRTdGF0ZTogVFN0YXRlIHwgdW5kZWZpbmVkID0gdW5kZWZpbmVkO1xyXG5cclxuICAgICAgICBzd2l0Y2ggKHZhbHVlLnR5cGUpIHtcclxuICAgICAgICAgICAgY2FzZSBsZWZ0OlxyXG4gICAgICAgICAgICAgICAgcHJldlN0YXRlID0gdmFsdWUubGVmdDtcclxuICAgICAgICAgICAgICAgIGJyZWFrO1xyXG4gICAgICAgICAgICBjYXNlIHJpZ2h0OiB7XHJcbiAgICAgICAgICAgICAgICBuZXh0U3RhdGUgPSB2YWx1ZS5yaWdodDtcclxuICAgICAgICAgICAgICAgIGJyZWFrO1xyXG4gICAgICAgICAgICB9XHJcbiAgICAgICAgICAgIGNhc2UgYm90aDoge1xyXG4gICAgICAgICAgICAgICAgcHJldlN0YXRlID0gdmFsdWUubGVmdDtcclxuICAgICAgICAgICAgICAgIG5leHRTdGF0ZSA9IHZhbHVlLnJpZ2h0O1xyXG4gICAgICAgICAgICAgICAgYnJlYWs7XHJcbiAgICAgICAgICAgIH1cclxuICAgICAgICB9XHJcbiAgICAgICAgY29uc3QgZGlmZlJlc3VsdCA9IGlubmVyRGlmZih7IHByZXZTdGF0ZSwgbmV4dFN0YXRlLCBrZXkgfSk7XHJcbiAgICAgICAgaWYgKGRpZmZSZXN1bHQgPT09IHVuZGVmaW5lZCkge1xyXG4gICAgICAgICAgICBjb250aW51ZTtcclxuICAgICAgICB9XHJcbiAgICAgICAgcmVzdWx0LnNldChrZXksIGRpZmZS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Jlc3VsdC5vayhzZWNvbmQpO1xyXG4gICAgfVxyXG4gICAgaWYgKHNlY29uZCA9PSBudWxsKSB7XHJcbiAgICAgICAgcmV0dXJuIFJlc3VsdC5vayhmaXJzdCk7XHJcbiAgICB9XHJcblxyXG4gICAgY29uc3QgcmVzdWx0ID0gbmV3IE1hcDxzdHJpbmcsIFRPcGVyYXRpb24+KCk7XHJcblxyXG4gICAgZm9yIChjb25zdCBba2V5LCBncm91cEpvaW5lZF0gb2YgZ3JvdXBKb2luTWFwKHJlY29yZFRvTWFwKGZpcnN0KSwgcmVjb3JkVG9NYXAoc2Vjb25kKSkpIHtcclxuICAgICAgICBzd2l0Y2ggKGdyb3VwSm9pbmVkLnR5cGUpIHtcclxuICAgICAgICAgICAgY2FzZSBsZWZ0OlxyXG4gICAgICAgICAgICAgICAgcmVzdWx0LnNldChrZXksIGdyb3VwSm9pbmVkLmxlZnQpO1xyXG4gICAgICAgICAgICAgICAgY29udGludWU7XHJcbiAgICAgICAgICAgIGNhc2UgcmlnaHQ6XHJcbiAgICAgICAgICAgICAgICByZXN1bHQuc2V0KGtleSwgZ3JvdXBKb2luZWQucmlnaHQpO1xyXG4gICAgICAgICAgICAgICAgY29udGludWU7XHJcbiAgICAgICAgICAgIGNhc2UgYm90aDoge1xyXG4gICAgICAgICAgICAgICAgY29uc3QgdXBkYXRlID0gaW5uZXJDb21wb3NlKHtcclxuICAgICAgICAgICAgICAgICAgICBmaXJzdDogZ3JvdXBKb2luZWQubGVmdCxcclxuICAgICAgICAgICAgICAgICAgICBzZWNvbmQ6IGdyb3VwSm9pbmVkLnJpZ2h0LFxyXG4gICAgICAgICAgICAgICAgICAgIGtleSxcclxuICAgICAgICAgICAgICAgIH0pO1xyXG4gICAgICAgICAgICAgICAgaWYgKHVwZGF0ZS5pc0Vycm9yKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgcmV0dXJuIHVwZGF0ZTtcclxuICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgICAgI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TtcclxuICAgIH1cclxuXHJcbiAgICBjb25zdCBmaXJzdFByaW1lID0gbmV3IE1hcDxzdHJpbmcsIFRPcGVyYXRpb24+KCk7XHJcbiAgICBjb25zdCBzZWNvbmRQcmltZSA9IG5ldyBNYXA8c3RyaW5nLCBUT3BlcmF0aW9uPigpO1xyXG4gICAgbGV0IGVycm9yID0gdW5kZWZpbmVkIGFzIHsgZXJyb3I6IFRFcnJvciB9IHwgdW5kZWZpbmVkO1xyXG5cclxuICAgIGdyb3VwSm9pbk1hcChyZWNvcmRUb01hcChmaXJzdCksIHJlY29yZFRvTWFwKHNlY29uZCkpLmZvckVhY2goKGdyb3VwLCBrZXkpID0+IHtcclxuICAgICAgICBpZiAoZXJyb3IgIT0gbnVsbCkge1xyXG4gICAgICAgICAgICByZXR1cm47XHJcbiAgICAgICAgfVxyXG4gICAgICAgIHN3aXRjaCAoZ3JvdXAudHlwZSkge1xyXG4gICAgICAgICAgICBjYXNlIGxlZnQ6IHtcclxuICAgICAgICAgICAgICAgIGZpcnN0UHJpbWUuc2V0KGtleSwgZ3JvdXAubGVmdCk7XHJcbiAgICAgICAgICAgICAgICByZXR1cm47XHJcbiAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgY2FzZSByaWdodDoge1xyXG4gICAgICAgICAgICAgICAgc2Vjb25kUHJpbWUuc2V0KGtleSwgZ3JvdXAucmlnaHQpO1xyXG4gICAgICAgICAgICAgICAgcmV0dXJuO1xyXG4gICAgICAgICAgICB9XHJcbiAgICAgICAgICAgIGNhc2UgYm90aDoge1xyXG4gICAgICAgICAgICAgICAgY29uc3QgeGZvcm0gPSBpbm5lclRyYW5zZm9ybSh7XHJcbiAgICAgICAgICAgICAgICAgICAgZmlyc3Q6IGdyb3VwLmxlZnQsXHJcbiAgICAgICAgICAgICAgICAgICAgc2Vjb25kOiBncm91cC5yaWdodCxcclxuICAgICAgICAgICAgICAgIH0pO1xyXG4gICAgICAgICAgICAgICAgaWYgKHhmb3JtLmlzRXJyb3IpIHtcclxuICAgICAgICAgICAgICAgICAgICBlcnJvciA9IHsgZXJyb3I6IHhmb3JtLmVycm9yIH07XHJcbiAgICAgICAgICAgICAgICAgICAgcmV0dXJuO1xyXG4gICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgaWYgKHhmb3JtLnZhbHVlLmZpcnN0UHJpbWUgIT09IHVuZGVmaW5lZCkge1xyXG4gICAgICAgICAgICAgICAgICAgIGZpcnN0UHJpbWUuc2V0KGtleSwgeGZvcm0udmFsdWUuZmlyc3RQcmltZSk7XHJcbiAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgICAgICBpZiAoeGZvcm0udmFsdWUuc2Vjb25kUHJpbWUgIT09IHVuZGVmaW5lZCkge1xyXG4gICAgICAgICAgICAgICAgICAgIHNlY29uZFByaW1lLnNldChrZXksIHhmb3JtLnZhbHVlLnNlY29uZFByaW1lKTtcclxuICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgICAgIHJldHVybjtcclxuICAgICAgICAgICAgfVxyXG4gICAgICAgIH1cclxuICAgIH0pO1xyXG4gICAgaWYgKGVycm9yICE9IG51bGwpIHtcclxuICAgICAgICByZXR1cm4gUmVzdWx0LmVycm9yKGVycm9yLmVycm9yKTtcclxuICAgIH1cclxuICAgIHJldHVybiBSZXN1bHQub2soe1xyXG4gICAgICAgIGZpcnN0UHJpbWU6IGZpcnN0UHJpbWUuc2l6ZSA9PT0gMCA/IHVuZGVmaW5lZCA6IG1hcFRvUmVjb3JkKGZpcnN0UHJpbWUpLFxyXG4gICAgICAgIHNlY29uZFByaW1lOiBzZWNvbmRQcmltZS5zaXplID09PSAwID8gdW5kZWZpbmVkIDogbWFwVG9SZWNvcmQoc2Vjb25kUHJpbWUpLFxyXG4gICAgfSk7XHJcbn07XHJcblxyXG5leHBvcnQgY29uc3QgZGlmZiA9IDxUU3RhdGUsIFRPcGVyYXRpb24+KHtcclxuICAgIHByZXZTdGF0ZSxcclxuICAgIG5leHRTdGF0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yZWFrO1xyXG4gICAgICAgICAgICB9XHJcbiAgICAgICAgICAgIGNhc2UgYm90aDoge1xyXG4gICAgICAgICAgICAgICAgcHJldlN0YXRlID0gdmFsdWUubGVmdDtcclxuICAgICAgICAgICAgICAgIG5leHRTdGF0ZSA9IHZhbHVlLnJpZ2h0O1xyXG4gICAgICAgICAgICAgICAgYnJlYWs7XHJcbiAgICAgICAgICAgIH1cclxuICAgICAgICB9XHJcbiAgICAgICAgY29uc3QgZGlmZlJlc3VsdCA9IGlubmVyRGlmZih7IHByZXZTdGF0ZSwgbmV4dFN0YXRlLCBrZXkgfSk7XHJcbiAgICAgICAgaWYgKGRpZmZSZXN1bHQgPT09IHVuZGVmaW5lZCkge1xyXG4gICAgICAgICAgICBjb250aW51ZTtcclxuICAgICAgICB9XHJcbiAgICAgICAgcmVzdWx0LnNldChrZXksIGRpZmZSZXN1bHQpO1xyXG4gICAgICAgIGNvbnRpbnVlO1xyXG4gICAgfVxyXG4gICAgaWYgKHJlc3VsdC5zaXplID09PSAwKSB7XHJcbiAgICAgICAgcmV0dXJuIHVuZGVmaW5lZDtcclxuICAgIH1cclxuICAgIHJldHVybiBtYXBUb1JlY29yZChyZXN1bHQpO1xyXG59O1xyXG4iXX0=

@@ -25,2 +25,8 @@ "use strict";

const clientTransform = ({ first, second, }) => {
if (first == null) {
return {
firstPrime: undefined,
secondPrime: second,
};
}
return {

@@ -51,2 +57,2 @@ firstPrime: first,

exports.toPrivateClientOperation = toPrivateClientOperation;
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicmVwbGFjZU9wZXJhdGlvbi5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uLy4uL3NyYy9pbnRlcm5hbC9vdC91dGlsL3JlcGxhY2VPcGVyYXRpb24udHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6Ijs7O0FBc0JPLE1BQU0sb0JBQW9CLEdBQUcsQ0FD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XRlICYmICFpc0F1dGhvcml6ZWQpIHtcclxuICAgICAgICByZXR1cm4ge1xyXG4gICAgICAgICAgICBuZXdWYWx1ZTogZGVmYXVsdFN0YXRlLFxyXG4gICAgICAgIH07XHJcbiAgICB9XHJcbiAgICByZXR1cm4ge1xyXG4gICAgICAgIG5ld1ZhbHVlOiBuZXdWYWx1ZS52YWx1ZSxcclxuICAgIH07XHJcbn07XHJcbiJdfQ==

@@ -88,3 +88,3 @@ import * as ReplaceValueOperation from '../../../util/replaceOperation';

}
return { ...resultType };
return resultType;
};

@@ -136,2 +136,2 @@ export const serverTransform = (isAuthorized) => ({ prevState, currentState, clientOperation, serverOperation }) => {

};
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoidjEuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi8uLi8uLi9zcmMvaW50ZXJuYWwvb3Qvcm9vbS9jaGFyYWN0ZXIvc2ltcGxlVmFsdWVQYXJhbS92MS50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFRQSxPQUFPLEtBQUsscUJBQXFCLE1BQU0sZ0NBQWdDLENBQUM7QUFDeEUsT0FBTyxFQUFFLFVBQVUsRUFBRSxNQUFNLHNCQUFzQixDQUFDO0FBQ2xELE9BQU8sS0FBSyxnQkFBZ0IsTUFBTSxnQ0FBZ0MsQ0FBQztBQUNuRSxPQUFPLEVBQUUsTUFBTSxFQUFFLE1BQU0sa0JBQWtCLENBQUM7QUE4QjFDLE1BQU0sQ0FBQyxNQUFNLGFBQWEsR0FDdEIsQ0FBSSxZQUFxQixFQUFFLFlBQWUsRUFBRSxFQUFFLENBQzlDLENBQUMsTUFBZ0IsRUFBWSxFQUFFO0lBQzNCLE9BQU87UUFDSCxHQUFHLE1BQU07UUFDVCxLQUFLLEVBQUUsTUFBTSxDQUFDLGNBQWMsSUFBSSxDQUFDLFlBQVksQ0FBQyxDQUFDLENBQUMsWU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mV2U3RhdGUuaXNWYWx1ZVByaXZhdGUsXHJcbiAgICAgICAgICAgICAgICBuZXdWYWx1ZTogbmV4dFN0YXRlLmlzVmFsdWVQcml2YXRlLFxyXG4gICAgICAgICAgICB9O1xyXG4gICAgICAgIH1cclxuICAgICAgICBpZiAocHJldlN0YXRlLnZhbHVlICE9PSBuZXh0U3RhdGUudmFsdWUpIHtcclxuICAgICAgICAgICAgcmVzdWx0VHlwZS52YWx1ZSA9IHtcclxuICAgICAgICAgICAgICAgIG9sZFZhbHVlOiBwcmV2U3RhdGUudmFsdWUsXHJcbiAgICAgICAgICAgICAgICBuZXdWYWx1ZTogbmV4dFN0YXRlLnZhbHVlLFxyXG4gICAgICAgICAgICB9O1xyXG4gICAgICAgIH1cclxuICAgICAgICBpZiAoaXNJZFJlY29yZChyZXN1bHRUeXBlKSkge1xyXG4gICAgICAgICAgICByZXR1cm4gdW5kZWZpbmVkO1xyXG4gICAgICAgIH1cclxuICAgICAgICByZXR1cm4geyAuLi5yZXN1bHRUeXBlIH07XHJcbiAgICB9O1xyXG5cclxuZXhwb3J0IGNvbnN0IHNlcnZlclRyYW5zZm9ybSA9XHJcbiAgICA8VD4oaXNBdXRob3JpemVkOiBib29sZWFuKTogU2VydmVyVHJhbnNmb3JtPFN0YXRlPFQ+LCBUd29XYXlPcGVyYXRpb248VD4sIFVwT3BlcmF0aW9uPFQ+PiA9PlxyXG4gICAgKHsgcHJldlN0YXRlLCBjdXJyZW50U3RhdGUsIGNsaWVudE9wZXJhdGlvbiwgc2VydmVyT3BlcmF0aW9uIH0pID0+IHtcclxuICAgICAgICBjb25zdCB0d29XYXlPcGVyYXRpb246IFR3b1dheU9wZXJhdGlvbjxUPiA9IHsgJHZlcnNpb246IDEgfTtcclxuXHJcbiAgICAgICAgaWYgKGlzQXV0aG9yaXplZCkge1xyXG4gICAgICAgICAgICB0d29XYXlPcGVyYXRpb24uaXNWYWx1ZVByaXZhdGUgPSBSZXBsYWNlVmFsdWVPcGVyYXRp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gVHdvV2F5T3BlcmF0aW9uPFQ+PiA9PlxyXG4gICAgKHsgbmV4dFN0YXRlLCBkb3duT3BlcmF0aW9uIH0pID0+IHtcclxuICAgICAgICBpZiAoZG93bk9wZXJhdGlvbiA9PT0gdW5kZWZpbmVkKSB7XHJcbiAgICAgICAgICAgIHJldHVybiBSZXN1bHQub2soe1xyXG4gICAgICAgICAgICAgICAgcHJldlN0YXRlOiBuZXh0U3RhdGUsXHJcbiAgICAgICAgICAgICAgICBuZXh0U3RhdGUsXHJcbiAgICAgICAgICAgICAgICB0d29XYXlPcGVyYXRpb246IHVuZGVmaW5lZCxcclxuICAgICAgICAgICAgfSk7XHJcbiAgICAgICAgfVxyXG5cclxuICAgICAgICBjb25zdCBwcmV2U3RhdGU6IFN0YXRlPFQ+ID0geyAuLi5uZXh0U3RhdGUgfTtcclxuICAgICAgICBjb25zdCB0d29XYXlPcGVyYXRpb246IFR3b1dheU9wZXJhdGlvbjxUPiA9IHsgJHZlcnNpb246IDEgfTtcclxuXHJcbiAgICAgICAgaWYgKGRvd25PcGVyYXRpb24uaXNWYWx1ZVByaXZhdGUgIT09IHVuZGVmaW5lZCkge1xyXG4gICAgICAgICAgICBwcmV2U3RhdGUuaXNWYWx1ZVByaXZhdGUgPSBkb3duT3BlcmF0aW9uLmlzVmFsdWVQcml2YXRlLm9sZFZhbHVlO1xyXG4gICAgICAgICAgICB0d29XYXlPcGVyYXRpb24uaXNWYWx1ZVByaXZhdGUgPSB7XHJcbiAgICAgICAgICAgICAgICAuLi5kb3duT3BlcmF0aW9uLmlzVmFsdWVQcml2YXRlLFxyXG4gICAgICAgICAgICAgICAgbmV3VmFsdWU6IG5leHRTdGF0ZS5pc1ZhbHVlUHJpdmF0ZSxcclxuICAgICAgICAgICAgfTtcclxuICAgICAgICB9XHJcbiAgICAgICAgaWYgKGRvd25PcGVyYXRpb24udmFsdWUgIT09IHVuZGVmaW5lZCkge1xyXG4gICAgICAgICAgICBwcmV2U3RhdGUudmFsdWUgP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Y29uc3QgdmFsdWUgPSBSZXBsYWNlT3BlcmF0aW9uLmNsaWVudFRyYW5zZm9ybSh7XHJcbiAgICAgICAgICAgIGZpcnN0OiBmaXJzdC52YWx1ZSxcclxuICAgICAgICAgICAgc2Vjb25kOiBzZWNvbmQudmFsdWUsXHJcbiAgICAgICAgfSk7XHJcblxyXG4gICAgICAgIGNvbnN0IGZpcnN0UHJpbWU6IFVwT3BlcmF0aW9uPFQ+ID0ge1xyXG4gICAgICAgICAgICAkdmVyc2lvbjogMSxcclxuICAgICAgICAgICAgaXNWYWx1ZVByaXZhdGU6IGlzVmFsdWVQcml2YXRlLmZpcnN0UHJpbWUsXHJcbiAgICAgICAgICAgIHZhbHVlOiB2YWx1ZS5maXJzdFByaW1lLFxyXG4gICAgICAgIH07XHJcblxyXG4gICAgICAgIGNvbnN0IHNlY29uZFByaW1lOiBVcE9wZXJhdGlvbjxUPiA9IHtcclxuICAgICAgICAgICAgJHZlcnNpb246IDEsXHJcbiAgICAgICAgICAgIGlzVmFsdWVQcml2YXRlOiBpc1ZhbHVlUHJpdmF0ZS5zZWNvbmRQcmltZSxcclxuICAgICAgICAgICAgdmFsdWU6IHZhbHVlLnNlY29uZFByaW1lLFxyXG4gICAgICAgIH07XHJcblxyXG4gICAgICAgIHJldHVybiBSZXN1bHQub2soe1xyXG4gICAgICAgICAgICBmaXJzdFByaW1lOiBpc0lkUmVjb3JkKGZpcnN0UHJpbWUpID8gdW5kZWZpbmVkIDogZmlyc3RQcmltZSxcclxuICAgICAgICAgICAgc2Vjb25kUHJpbWU6IGlzSWRSZWNvcmQoc2Vjb25kUHJpbWUpID8gdW5kZWZpbmVkIDogc2Vjb25kUHJpbWUsXHJcbiAgICAgICAgfSk7XHJcbiAgICB9O1xyXG4iXX0=

@@ -125,3 +125,3 @@ import * as t from 'io-ts';

}
return { ...resultType };
return resultType;
};

@@ -180,2 +180,2 @@ export const serverTransform = (isAuthorized) => ({ prevState, currentState, clientOperation, serverOperation }) => {

};
//# sour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7XHJcbiAgICBjb25zdCB2YWx1ZSA9IFRleHRPcGVyYXRpb24uY29tcG9zZURvd25PcGVyYXRpb24oZmlyc3QudmFsdWUsIHNlY29uZC52YWx1ZSk7XHJcbiAgICBpZiAodmFsdWUuaXNFcnJvcikge1xyXG4gICAgICAgIHJldHVybiB2YWx1ZTtcclxuICAgIH1cclxuICAgIGNvbnN0IHZhbHVlUHJvcHM6IERvd25PcGVyYXRpb24gPSB7XHJcbiAgICAgICAgJHZlcnNpb246IDEsXHJcbiAgICAgICAgaXNWYWx1ZVByaXZhdGU6IFJlcGxhY2VPcGVyYXRpb24uY29tcG9zZURvd25PcGVyYXRpb24oXHJcbiAgICAgICAgICAgIGZpcnN0LmlzVmFsdWVQcml2YXRlLFxyXG4gICAgICAgICAgICBzZWNvbmQuaXNWYWx1ZVByaXZhdGVcclxuICAgICAgICApLFxyXG4gICAgICAgIHZhbHVlOiB2YWx1ZS52YWx1ZSxcclxuICAgIH07XHJcbiAgICByZXR1cm4gUmVzdWx0Lm9rKHZhbHVlUHJvcHMpO1xyXG59O1xyXG5cclxuZXhwb3J0IGNvbnN0IHJlc3RvcmU6IFJlc3RvcmU8U3RhdGUsIERvd25PcGVyYXRpb24sIFR3b1dheU9wZXJhdGlvbj4gPSAoe1xyXG4gICAgbmV4dFN0YXRlLFxyXG4gICAgZG93bk9wZXJhdGlvbixcclxufSkgPT4ge1xyXG4gICAgaWYgKGRvd25PcGVyYXRpb24gPT09IHVuZGVmaW5lZCkge1xyXG4gICAgICAgIHJldHVybiBSZXN1bHQub2soe1xyXG4gICAgICAgICAgICBwcmV2U3RhdGU6IG5leHRTdGF0ZSxcclxuICAgICAgICAgICAgbmV4dFN0YXRlLFxyXG4gICAgICAgICAgICB0d29XYXlPcGVyYXRpb246IHVuZGVmaW5lZCxcclxuICAgICAgICB9KTtcclxuICAgIH1cclxuXHJcbiAgICBjb25zdCBwcmV2U3RhdGU6IFN0YXRlID0geyAuLi5uZXh0U3RhdGUgfTtcclxuICA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AgICAgICAgICBzZWNvbmQ6IGNsaWVudE9wZXJhdGlvbi5pc1ZhbHVlUHJpdmF0ZSxcclxuICAgICAgICAgICAgICAgIHByZXZTdGF0ZTogcHJldlN0YXRlLmlzVmFsdWVQcml2YXRlLFxyXG4gICAgICAgICAgICB9KTtcclxuICAgICAgICB9XHJcbiAgICAgICAgaWYgKGlzQXV0aG9yaXplZCB8fCAhY3VycmVudFN0YXRlLmlzVmFsdWVQcml2YXRlKSB7XHJcbiAgICAgICAgICAgIGNvbnN0IHRyYW5zZm9ybWVkID0gVGV4dE9wZXJhdGlvbi5zZXJ2ZXJUcmFuc2Zvcm0oe1xyXG4gICAgICAgICAgICAgICAgZmlyc3Q6IHNlcnZlck9wZXJhdGlvbj8udmFsdWUsXHJcbiAgICAgICAgICAgICAgICBzZWNvbmQ6IGNsaWVudE9wZXJhdGlvbi52YWx1ZSxcclxuICAgICAgICAgICAgICAgIHByZXZTdGF0ZTogcHJldlN0YXRlLnZhbHVlLFxyXG4gICAgICAgICAgICB9KTtcclxuICAgICAgICAgICAgaWYgKHRyYW5zZm9ybWVkLmlzRXJyb3IpIHtcclxuICAgICAgICAgICAgICAgIHJldHVybiB0cmFuc2Zvcm1lZDtcclxuICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICB0d29XYXlPcGVyYXRpb24udmFsdWUgPSB0cmFuc2Zvcm1lZC52YWx1ZS5zZWNvbmRQcmltZTtcclxuICAgICAgICB9XHJcblxyXG4gICAgICAgIGlmIChpc0lkUmVjb3JkKHR3b1dheU9wZXJhdGlvbikpIHtcclxuICAgICAgICAgICAgcmV0dXJuIFJlc3VsdC5vayh1bmRlZmluZWQpO1xyXG4gICAgICAgIH1cclxuXHJcbiAgICAgICAgcmV0dXJuIFJlc3VsdC5vayh0d29XYXlPcGVyYXRpb24pO1xyXG4gICAgfTtcclxuXHJcbmV4cG9ydCBjb25zdCBjbGllbnRUcmFuc2Zvcm06IENsaWVudFRyYW5zZm9ybTxVcE9wZXJhdGlvb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mVkIDogZmlyc3RQcmltZSxcclxuICAgICAgICBzZWNvbmRQcmltZTogaXNJZFJlY29yZChzZWNvbmRQcmltZSkgPyB1bmRlZmluZWQgOiBzZWNvbmRQcmltZSxcclxuICAgIH0pO1xyXG59O1xyXG4iXX0=

@@ -57,2 +57,5 @@ import * as t from 'io-ts';

}
if (operation.isPrivate != null) {
result.isPrivate = operation.isPrivate.newValue;
}
if (operation.memo != null) {

@@ -86,2 +89,5 @@ const valueResult = TextOperation.apply(state.memo, operation.memo);

}
if (operation.isPrivate != null) {
result.isPrivate = operation.isPrivate.oldValue;
}
if (operation.memo != null) {

@@ -128,5 +134,6 @@ const valueResult = TextOperation.applyBack(state.memo, operation.memo);

$version: 1,
image: ReplaceOperation.composeDownOperation(first.image, second.image),
isPrivate: ReplaceOperation.composeDownOperation(first.isPrivate, second.isPrivate),
memo: memo.value,
name: ReplaceOperation.composeDownOperation(first.name, second.name),
image: ReplaceOperation.composeDownOperation(first.image, second.image),
pieces: pieces.value,

@@ -137,3 +144,3 @@ };

export const restore = ({ nextState, downOperation, }) => {
var _a, _b;
var _a, _b, _c, _d;
if (downOperation === undefined) {

@@ -166,2 +173,9 @@ return Result.ok({ prevState: nextState, twoWayOperation: undefined });

}
if (downOperation.isPrivate !== undefined) {
prevState.isPrivate = (_c = downOperation.isPrivate.oldValue) !== null && _c !== void 0 ? _c : undefined;
twoWayOperation.isPrivate = {
oldValue: (_d = downOperation.isPrivate.oldValue) !== null && _d !== void 0 ? _d : undefined,
newValue: nextState.isPrivate,
};
}
if (downOperation.memo !== undefined) {

@@ -200,2 +214,5 @@ const restored = TextOperation.restore({

}
if (prevState.isPrivate !== nextState.isPrivate) {
result.isPrivate = { oldValue: prevState.isPrivate, newValue: nextState.isPrivate };
}
if (prevState.memo !== nextState.memo) {

@@ -246,2 +263,7 @@ result.memo = TextOperation.diff({

});
twoWayOperation.isPrivate = ReplaceOperation.serverTransform({
first: serverOperation === null || serverOperation === void 0 ? void 0 : serverOperation.isPrivate,
second: clientOperation.isPrivate,
prevState: prevState.isPrivate,
});
const transformedMemo = TextOperation.serverTransform({

@@ -271,2 +293,6 @@ first: serverOperation === null || serverOperation === void 0 ? void 0 : serverOperation.memo,

});
const isPrivate = ReplaceOperation.clientTransform({
first: first.isPrivate,
second: second.isPrivate,
});
const memo = TextOperation.clientTransform({

@@ -295,2 +321,3 @@ first: first.memo,

image: image.firstPrime,
isPrivate: isPrivate.firstPrime,
memo: memo.value.firstPrime,

@@ -303,2 +330,3 @@ name: name.firstPrime,

image: image.secondPrime,
isPrivate: isPrivate.secondPrime,
memo: memo.value.firstPrime,

@@ -313,2 +341,2 @@ name: name.secondPrime,

};
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoidjEuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi8uLi8uLi9zcmMvaW50ZXJuYWwvb3Qvcm9vbS9wYXJ0aWNpcGFudC9pbWFnZVBpZWNlVmFsdWUvdjEudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEsT0FBTyxLQUFLLENBQUMsTUFBTSxPQUFPLENBQUM7QUFDM0IsT0FBTyxLQUFLLGdCQUFnQixNQUFNLGdDQUFnQyxDQUFDO0FBVW5FLE9BQU8sRUFBRSxlQUFlLEVBQUUsTUFBTSwrQkFBK0IsQ0FBQztBQUNoRSxPQUFPLEVBQUUsVUFBVSxFQUFFLE1BQU0sRUFBRSxNQUFNLHNCQUFzQixDQUFDO0FBQzFELE9BQU8sRUFBRSxNQUFNLEVBQUUsTUFBTSxrQkFBa0IsQ0FBQztBQUUxQyxPQUFPLEVBQVksUUFBUSxFQUFFLE1BQU0sc0JBQXNCLENBQUM7QUFDMUQsT0FBTyxLQUFLLGFBQWEsTUFBTSw2QkFBNkIsQ0FBQztBQUM3RCxPQUFPLEtBQUssS0FBSyxNQUFNLG1CQUFtQixDQUFDO0FBQzNDLE9BQU8sRUFDSCx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ZSxcclxuICAgICAgICAgICAgUGllY2UuU3RhdGUsXHJcbiAgICAgICAgICAgIFBpZWNlLlR3b1dheU9wZXJhdGlvbixcclxuICAgICAgICAgICAgUGllY2UuVXBPcGVyYXRpb24sXHJcbiAgICAgICAgICAgIHN0cmluZyB8IEFwcGx5RXJyb3I8UG9zaXRpdmVJbnQ+IHwgQ29tcG9zZUFuZFRyYW5zZm9ybUVycm9yXHJcbiAgICAgICAgPih7XHJcbiAgICAgICAgICAgIHByZXZTdGF0ZTogcHJldlN0YXRlLnBpZWNlcyxcclxuICAgICAgICAgICAgbmV4dFN0YXRlOiBjdXJyZW50U3RhdGUucGllY2VzLFxyXG4gICAgICAgICAgICBmaXJzdDogc2VydmVyT3BlcmF0aW9uPy5waWVjZXMsXHJcbiAgICAgICAgICAgIHNlY29uZDogY2xpZW50T3BlcmF0aW9uLnBpZWNlcyxcclxuICAgICAgICAgICAgaW5uZXJUcmFuc2Zvcm06ICh7IHByZXZTdGF0ZSwgbmV4dFN0YXRlLCBmaXJzdCwgc2Vjb25kIH0pID0+XHJcbiAgICAgICAgICAgICAgICBQaWVjZS5zZXJ2ZXJUcmFuc2Zvcm0oe1xyXG4gICAgICAgICAgICAgICAgICAgIHByZXZTdGF0ZSxcclxuICAgICAgICAgICAgICAgICAgICBjdXJyZW50U3RhdGU6IG5leHRTdGF0ZSxcclxuICAgICAgICAgICAgICAgICAgICBzZXJ2ZXJPcGVyYXRpb246IGZpcnN0LFxyXG4gICAgICAgICAgICAgICAgICAgIGNsaWVudE9wZXJhdGlvbjogc2Vjb25kLFxyXG4gICAgICAgICAgICAgICAgfSksXHJcbiAgICAgICAgICAgIHRvU2VydmVyU3RhdGU6IHN0YXRlID0+IHN0YXRlLFxyXG4gICAgICAgICAgICBjYW5jZWxsYXRpb25Qb2xpY3k6IHtcclxuICAgICAgICAgICAgICAgIGNhbmNlbENyZWF0ZTogKCkgPT4gIWlzQXV0aG9yaXplZCxcclxuICAgICAgICAgICAgICAgIGNhbm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ICAgIG1lbW86IG1lbW8udmFsdWUuZmlyc3RQcmltZSxcclxuICAgICAgICBuYW1lOiBuYW1lLmZpcnN0UHJpbWUsXHJcbiAgICAgICAgcGllY2VzOiBwaWVjZXMudmFsdWUuZmlyc3RQcmltZSxcclxuICAgIH07XHJcbiAgICBjb25zdCBzZWNvbmRQcmltZTogVXBPcGVyYXRpb24gPSB7XHJcbiAgICAgICAgJHZlcnNpb246IDEsXHJcbiAgICAgICAgaW1hZ2U6IGltYWdlLnNlY29uZFByaW1lLFxyXG4gICAgICAgIG1lbW86IG1lbW8udmFsdWUuZmlyc3RQcmltZSxcclxuICAgICAgICBuYW1lOiBuYW1lLnNlY29uZFByaW1lLFxyXG4gICAgICAgIHBpZWNlczogcGllY2VzLnZhbHVlLnNlY29uZFByaW1lLFxyXG4gICAgfTtcclxuXHJcbiAgICByZXR1cm4gUmVzdWx0Lm9rKHtcclxuICAgICAgICBmaXJzdFByaW1lOiBpc0lkUmVjb3JkKGZpcnN0UHJpbWUpID8gdW5kZWZpbmVkIDogZmlyc3RQcmltZSxcclxuICAgICAgICBzZWNvbmRQcmltZTogaXNJZFJlY29yZChzZWNvbmRQcmltZSkgPyB1bmRlZmluZWQgOiBzZWNvbmRQcmltZSxcclxuICAgIH0pO1xyXG59O1xyXG4iXX0=
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoidjEuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi8uLi8uLi9zcmMvaW50ZXJuYWwvb3Qvcm9vbS9wYXJ0aWNpcGFudC9pbWFnZVBpZWNlVmFsdWUvdjEudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEsT0FBTyxLQUFLLENBQUMsTUFBTSxPQUFPLENBQUM7QUFDM0IsT0FBTyxLQUFLLGdCQUFnQixNQUFNLGdDQUFnQyxDQUFDO0FBVW5FLE9BQU8sRUFBRSxlQUFlLEVBQUUsTU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cyxcclxuICAgICAgICAgICAgc2Vjb25kOiBjbGllbnRPcGVyYXRpb24ucGllY2VzLFxyXG4gICAgICAgICAgICBpbm5lclRyYW5zZm9ybTogKHsgcHJldlN0YXRlLCBuZXh0U3RhdGUsIGZpcnN0LCBzZWNvbmQgfSkgPT5cclxuICAgICAgICAgICAgICAgIFBpZWNlLnNlcnZlclRyYW5zZm9ybSh7XHJcbiAgICAgICAgICAgICAgICAgICAgcHJldlN0YXRlLFxyXG4gICAgICAgICAgICAgICAgICAgIGN1cnJlbnRTdGF0ZTogbmV4dFN0YXRlLFxyXG4gICAgICAgICAgICAgICAgICAgIHNlcnZlck9wZXJhdGlvbjogZmlyc3QsXHJcbiAgICAgICAgICAgICAgICAgICAgY2xpZW50T3BlcmF0aW9uOiBzZWNvbmQsXHJcbiAgICAgICAgICAgICAgICB9KSxcclxuICAgICAgICAgICAgdG9TZXJ2ZXJTdGF0ZTogc3RhdGUgPT4gc3RhdGUsXHJcbiAgICAgICAgICAgIGNhbmNlbGxhdGlvblBvbGljeToge1xyXG4gICAgICAgICAgICAgICAgY2FuY2VsQ3JlYXRlOiAoKSA9PiAhaXNBdXRob3JpemVkLFxyXG4gICAgICAgICAgICAgICAgY2FuY2VsUmVtb3ZlOiBwYXJhbXMgPT4gIWlzQXV0aG9yaXplZCAmJiBwYXJhbXMubmV4dFN0YXRlLmlzUHJpdmF0ZSxcclxuICAgICAgICAgICAgICAgIGNhbmNlbFVwZGF0ZTogcGFyYW1zID0+ICFpc0F1dGhvcml6ZWQgJiYgcGFyYW1zLm5leHRTdGF0ZS5pc1ByaXZhdGUsXHJcbiAgICAgICAgICAgIH0sXHJcbiAgICAgICAgfSk7XHJcbiAgICAgICAgaWYgKHBpZWNlcy5pc0Vycm9yKSB7XHJcbiAgICAgICAgICAgIHJldHVybiBwaWVjZXM7XHJcbiAgICAgICAgfVxyXG5cclxuICAgICAgICBjb25zdCB0d29XYXlPcGVyYXRpb246IFR3b1dheU9wZXJhdGlvbiA9IHtcclxuICAgICAgICAgICAgJHZlcnNpb246IDEsXHJcbiAgICAgICAgICAgIHBpZWNlczogcGllY2VzLnZhbHVlLFxyXG4gICAgICAgIH07XHJcblxyXG4gICAgICAgIHR3b1dheU9wZXJhdGlvbi5pbWFnZSA9IFJlcGxhY2VPcGVyYXRpb24uc2VydmVyVHJhbnNmb3JtKHtcclxuICAgICAgICAgICAgZmlyc3Q6IHNlcnZlck9wZXJhdGlvbj8uaW1hZ2UsXHJcbiAgICAgICAgICAgIHNlY29uZDogY2xpZW50T3BlcmF0aW9uLmltYWdlLFxyXG4gICAgICAgICAgICBwcmV2U3RhdGU6IHByZXZTdGF0ZS5pbWFnZSxcclxuICAgICAgICB9KTtcclxuICAgICAgICB0d29XYXlPcGVyYXRpb24uaXNQcml2YXRlID0gUmVwbGFjZU9wZXJhdGlvbi5zZXJ2ZXJUcmFuc2Zvcm0oe1xyXG4gICAgICAgICAgICBmaXJzdDogc2VydmVyT3BlcmF0aW9uPy5pc1ByaXZhdGUsXHJcbiAgICAgICAgICAgIHNlY29uZDogY2xpZW50T3BlcmF0aW9uLmlzUHJpdmF0ZSxcclxuICAgICAgICAgICAgcHJldlN0YXRlOiBwcmV2U3RhdGUuaXNQcml2YXRlLFxyXG4gICAgICAgIH0pO1xyXG4gICAgICAgIGNvbnN0IHRyYW5zZm9ybWVkTWVtbyA9IFRleHRPcGVyYXRpb24uc2VydmVyVHJhbnNmb3JtKHtcclxuICAgICAgICAgICAgZmlyc3Q6IHNlcnZlck9wZXJhdGlvbj8ubWVtbyxcclxuICAgICAgICAgICAgc2Vjb25kOiBjbGllbnRPcGVyYXRpb24ubWVtbyxcclxuICAgICAgICAgICAgcHJldlN0YXRlOiBwcmV2U3RhdGUubWVtbyxcclxuICAgICAgICB9KTtcclxuICAgICAgICBpZiAodHJhbnNmb3JtZWRNZW1vLmlzRXJyb3IpIHtcclxuICAgICAgICAgICAgcmV0dXJuIHRyYW5zZm9ybWVkTWVtbztcclxuICAgICAgICB9XHJ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9IHtcclxuICAgICAgICAkdmVyc2lvbjogMSxcclxuICAgICAgICBpbWFnZTogaW1hZ2UuZmlyc3RQcmltZSxcclxuICAgICAgICBpc1ByaXZhdGU6IGlzUHJpdmF0ZS5maXJzdFByaW1lLFxyXG4gICAgICAgIG1lbW86IG1lbW8udmFsdWUuZmlyc3RQcmltZSxcclxuICAgICAgICBuYW1lOiBuYW1lLmZpcnN0UHJpbWUsXHJcbiAgICAgICAgcGllY2VzOiBwaWVjZXMudmFsdWUuZmlyc3RQcmltZSxcclxuICAgIH07XHJcbiAgICBjb25zdCBzZWNvbmRQcmltZTogVXBPcGVyYXRpb24gPSB7XHJcbiAgICAgICAgJHZlcnNpb246IDEsXHJcbiAgICAgICAgaW1hZ2U6IGltYWdlLnNlY29uZFByaW1lLFxyXG4gICAgICAgIGlzUHJpdmF0ZTogaXNQcml2YXRlLnNlY29uZFByaW1lLFxyXG4gICAgICAgIG1lbW86IG1lbW8udmFsdWUuZmlyc3RQcmltZSxcclxuICAgICAgICBuYW1lOiBuYW1lLnNlY29uZFByaW1lLFxyXG4gICAgICAgIHBpZWNlczogcGllY2VzLnZhbHVlLnNlY29uZFByaW1lLFxyXG4gICAgfTtcclxuXHJcbiAgICByZXR1cm4gUmVzdWx0Lm9rKHtcclxuICAgICAgICBmaXJzdFByaW1lOiBpc0lkUmVjb3JkKGZpcnN0UHJpbWUpID8gdW5kZWZpbmVkIDogZmlyc3RQcmltZSxcclxuICAgICAgICBzZWNvbmRQcmltZTogaXNJZFJlY29yZChzZWNvbmRQcmltZSkgPyB1bmRlZmluZWQgOiBzZWNvbmRQcmltZSxcclxuICAgIH0pO1xyXG59O1xyXG4iXX0=

@@ -33,3 +33,2 @@ import { Result } from '@kizahasi/result';

}
break;
}

@@ -59,3 +58,2 @@ return Result.ok({

nextState.set(key, newValue.value);
break;
}

@@ -82,3 +80,2 @@ return Result.ok(mapToRecord(nextState));

prevState.set(key, oldValue.value);
break;
}

@@ -234,2 +231,2 @@ return Result.ok(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AgY29uc3QgdHdvV2F5T3BlcmF0aW9uID0gbmV3IE1hcDxzdHJpbmcsIFRUd29XYXlPcGVyYXRpb24+KCk7XHJcblxyXG4gICAgZm9yIChjb25zdCBba2V5LCB2YWx1ZV0gb2YgcmVjb3JkVG9NYXAodW5zYWZlRG93bk9wZXJhdGlvbikpIHtcclxuICAgICAgICBjb25zdCBuZXh0U3RhdGVFbGVtZW50ID0gbmV4dFN0YXRlLmdldChrZXkpO1xyXG4gICAgICAgIGlmIChuZXh0U3RhdGVFbGVtZW50ID09PSB1bmRlZmluZWQpIHtcclxuICAgICAgICAgICAgcmV0dXJuIFJlc3VsdC5lcnJvcihgdHJpZWQgdG8gdXBkYXRlIFwiJHtrZXl9XCIsIGJ1dCBuZXh0U3RhdGUgZG9lcyBub3QgaGF2ZSBzdWNoIGEga2V5YCk7XHJcbiAgICAgICAgfVxyXG4gICAgICAgIGNvbnN0IHJlc3RvcmVkID0gaW5uZXJSZXN0b3JlKHtcclxuICAgICAgICAgICAgZG93bk9wZXJhdGlvbjogdmFsdWUsXHJcbiAgICAgICAgICAgIG5leHRTdGF0ZTogbmV4dFN0YXRlRWxlbWVudCxcclxuICAgICAgICAgICAga2V5LFxyXG4gICAgICAgIH0pO1xyXG4gICAgICAgIGlmIChyZXN0b3JlZC5pc0Vycm9yKSB7XHJcbiAgICAgICAgICAgIHJldHVybiByZXN0b3JlZDtcclxuICAgICAgICB9XHJcbiAgICAgICAgaWYgKHJlc3RvcmVkLnZhbHVlID09PSB1bmRlZmluZWQpIHtcclxuICAgICAgICAgICAgY29udGludWU7XHJcbiAgICAgICAgfVxyXG4gICAgICAgIHByZXZTdGF0ZS5zZXQoa2V5LCByZXN0b3JlZC52YWx1ZS5wcmV2U3RhdGUpO1xyXG4gICAgICAgIGlmIChyZXN0b3JlZC52YWx1ZS50d29XYXlPcGVyYXRpb24gIT09IHVuZGVmaW5lZCkge1xyXG4gICAgICAgICAgICB0d29XYXlPcGVyYXRpb24uc2V0KGtleSwgc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25kID09IG51bGwpIHtcclxuICAgICAgICByZXR1cm4gUmVzdWx0Lm9rKGZpcnN0KTtcclxuICAgIH1cclxuXHJcbiAgICBjb25zdCByZXN1bHQgPSBuZXcgTWFwPHN0cmluZywgVE9wZXJhdGlvbj4oKTtcclxuXHJcbiAgICBmb3IgKGNvbnN0IFtrZXksIGdyb3VwSm9pbmVkXSBvZiBncm91cEpvaW5NYXAocmVjb3JkVG9NYXAoZmlyc3QpLCByZWNvcmRUb01hcChzZWNvbmQpKSkge1xyXG4gICAgICAgIHN3aXRjaCAoZ3JvdXBKb2luZWQudHlwZSkge1xyXG4gICAgICAgICAgICBjYXNlIGxlZnQ6XHJcbiAgICAgICAgICAgICAgICByZXN1bHQuc2V0KGtleSwgZ3JvdXBKb2luZWQubGVmdCk7XHJcbiAgICAgICAgICAgICAgICBjb250aW51ZTtcclxuICAgICAgICAgICAgY2FzZSByaWdodDpcclxuICAgICAgICAgICAgICAgIHJlc3VsdC5zZXQoa2V5LCBncm91cEpvaW5lZC5yaWdodCk7XHJcbiAgICAgICAgICAgICAgICBjb250aW51ZTtcclxuICAgICAgICAgICAgY2FzZSBib3RoOiB7XHJcbiAgICAgICAgICAgICAgICBjb25zdCB1cGRhdGUgPSBpbm5lckNvbXBvc2Uoe1xyXG4gICAgICAgICAgICAgICAgICAgIGZpcnN0OiBncm91cEpvaW5lZC5sZWZ0LFxyXG4gICAgICAgICAgICAgICAgICAgIHNlY29uZDogZ3JvdXBKb2luZWQucmlnaHQsXHJcbiAgICAgICAgICAgICAgICAgICAga2V5LFxyXG4gICAgICAgICAgICAgICAgfSk7XHJcbiAgICAgICAgICAgICAgICBpZiAodXBkYXRlLmlzRXJyb3IpIHtcclxuICAgICAgICAgICAgICAgICAgICByZXR1cm4gdXBkYXRlO1xyXG4gICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgaWYgKHVwZGF0ZS52YWx1ZSAhPT0gdW5kZWZpbmVkKSB7XHJcbiAgICAgICAgICAgICAg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vbj4oKTtcclxuICAgIGNvbnN0IHNlY29uZFByaW1lID0gbmV3IE1hcDxzdHJpbmcsIFRPcGVyYXRpb24+KCk7XHJcbiAgICBsZXQgZXJyb3IgPSB1bmRlZmluZWQgYXMgeyBlcnJvcjogVEVycm9yIH0gfCB1bmRlZmluZWQ7XHJcblxyXG4gICAgZ3JvdXBKb2luTWFwKHJlY29yZFRvTWFwKGZpcnN0KSwgcmVjb3JkVG9NYXAoc2Vjb25kKSkuZm9yRWFjaCgoZ3JvdXAsIGtleSkgPT4ge1xyXG4gICAgICAgIGlmIChlcnJvciAhPSBudWxsKSB7XHJcbiAgICAgICAgICAgIHJldHVybjtcclxuICAgICAgICB9XHJcbiAgICAgICAgc3dpdGNoIChncm91cC50eXBlKSB7XHJcbiAgICAgICAgICAgIGNhc2UgbGVmdDoge1xyXG4gICAgICAgICAgICAgICAgZmlyc3RQcmltZS5zZXQoa2V5LCBncm91cC5sZWZ0KTtcclxuICAgICAgICAgICAgICAgIHJldHVybjtcclxuICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICBjYXNlIHJpZ2h0OiB7XHJcbiAgICAgICAgICAgICAgICBzZWNvbmRQcmltZS5zZXQoa2V5LCBncm91cC5yaWdodCk7XHJcbiAgICAgICAgICAgICAgICByZXR1cm47XHJcbiAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgY2FzZSBib3RoOiB7XHJcbiAgICAgICAgICAgICAgICBjb25zdCB4Zm9ybSA9IGlubmVyVHJhbnNmb3JtKHtcclxuICAgICAgICAgICAgICAgICAgICBmaXJzdDogZ3JvdXAubGVmdCxcclxuICAgICAgICAgICAgICAgICAgICBzZWNvbmQ6IGdyb3VwLnJpZ2h0LFxyXG4gICAgICAgICAgICAgICAgfSk7XHJcbiAgICAgICAgICAgICAgICBpZiAoeGZvcm0uaXNFcnJvcikge1xyXG4gICAgICAgICAgICAgICAgICAgIGVycm9yID0geyBlcnJvcjogeGZvcm0uZXJyb3IgfTtcclxuICAgICAgICAgICAgICAgICAgICByZXR1cm47XHJcbiAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgICAgICBpZiAoeGZvcm0udmFsdWUuZmlyc3RQcmltZSAhPT0gdW5kZWZpbmVkKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgZmlyc3RQcmltZS5zZXQoa2V5LCB4Zm9ybS52YWx1ZS5maXJzdFByaW1lKTtcclxuICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgICAgIGlmICh4Zm9ybS52YWx1ZS5zZWNvbmRQcmltZSAhPT0gdW5kZWZpbmVkKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgc2Vjb25kUHJpbWUuc2V0KGtleSwgeGZvcm0udmFsdWUuc2Vjb25kUHJpbWUpO1xyXG4gICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgcmV0dXJuO1xyXG4gICAgICAgICAgICB9XHJcbiAgICAgICAgfVxyXG4gICAgfSk7XHJcbiAgICBpZiAoZXJyb3IgIT0gbnVsbCkge1xyXG4gICAgICAgIHJldHVybiBSZXN1bHQuZXJyb3IoZXJyb3IuZXJyb3IpO1xyXG4gICAgfVxyXG4gICAgcmV0dXJuIFJlc3VsdC5vayh7XHJcbiAgICAgICAgZmlyc3RQcmltZTogZmlyc3RQcmltZS5zaXplID09PSAwID8gdW5kZWZpbmVkIDogbWFwVG9SZWNvcmQoZmlyc3RQcmltZSksXHJcbiAgICAgICAgc2Vjb25kUHJpbWU6IHNlY29uZFByaW1lLnNpemUgPT09IDAgPyB1bmRlZmluZWQgOiBtYXBUb1JlY29yZChzZWNvbmRQcmltZSksXHJcbiAgICB9KTtcclxufTtcclxuXHJcbmV4cG9ydCBjb25zdCBkaWZmID0gPFRTdGF0ZSwgVE9wZXJhdGlvbj4oe1xyXG4gICAgcHJldlN0YXRlLFxyXG4gICAgbmV4dFN0YXRlLFxyXG4gICAgaW5uZXJEaWZmLFxyXG59OiB7XHJcbiAgICBwcmV2U3RhdGU6IFN0cmluZ0tleVJ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gICAgICAgICAgICAgICBwcmV2U3RhdGUgPSB2YWx1ZS5sZWZ0O1xyXG4gICAgICAgICAgICAgICAgbmV4dFN0YXRlID0gdmFsdWUucmlnaHQ7XHJcbiAgICAgICAgICAgICAgICBicmVhaztcclxuICAgICAgICAgICAgfVxyXG4gICAgICAgIH1cclxuICAgICAgICBjb25zdCBkaWZmUmVzdWx0ID0gaW5uZXJEaWZmKHsgcHJldlN0YXRlLCBuZXh0U3RhdGUsIGtleSB9KTtcclxuICAgICAgICBpZiAoZGlmZlJlc3VsdCA9PT0gdW5kZWZpbmVkKSB7XHJcbiAgICAgICAgICAgIGNvbnRpbnVlO1xyXG4gICAgICAgIH1cclxuICAgICAgICByZXN1bHQuc2V0KGtleSwgZGlmZlJlc3VsdCk7XHJcbiAgICAgICAgY29udGludWU7XHJcbiAgICB9XHJcbiAgICBpZiAocmVzdWx0LnNpemUgPT09IDApIHtcclxuICAgICAgICByZXR1cm4gdW5kZWZpbmVkO1xyXG4gICAgfVxyXG4gICAgcmV0dXJuIG1hcFRvUmVjb3JkKHJlc3VsdCk7XHJcbn07XHJcbiJdfQ==
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicGFyYW1SZWNvcmRPcGVyYXRpb24uanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi9zcmMvaW50ZXJuYWwvb3QvdXRpbC9wYXJhbVJlY29yZE9wZXJhdGlvbi50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQSxPQUFPLEVBQWdCLE1BQU0sRUFBRSxNQUFNLGtCQUFrQixDQUFDO0FBQ3hELE9BQU8sRUFBRSxJQUFJLEVBQUUsWUFBWSxFQUFFLElBQUksRUFBRSxXQUFXLEVBQUUsV0FBVyxFQUFFLEtBQUssRUFBRSxNQUFNLGdCQUFnQixDQUFDO0FBZTNGLE1BQU0sQ0FBQyxNQUFNLE9BQU8sR0FBRyxDQUFrR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cclxuICAgICAgICAgICAgZG93bk9wZXJhdGlvbjogdmFsdWUsXHJcbiAgICAgICAgICAgIG5leHRTdGF0ZTogbmV4dFN0YXRlRWxlbWVudCxcclxuICAgICAgICAgICAga2V5LFxyXG4gICAgICAgIH0pO1xyXG4gICAgICAgIGlmIChyZXN0b3JlZC5pc0Vycm9yKSB7XHJcbiAgICAgICAgICAgIHJldHVybiByZXN0b3JlZDtcclxuICAgICAgICB9XHJcbiAgICAgICAgaWYgKHJlc3RvcmVkLnZhbHVlID09PSB1bmRlZmluZWQpIHtcclxuICAgICAgICAgICAgY29udGludWU7XHJcbiAgICAgICAgfVxyXG4gICAgICAgIHByZXZTdGF0ZS5zZXQoa2V5LCByZXN0b3JlZC52YWx1ZS5wcmV2U3RhdGUpO1xyXG4gICAgICAgIGlmIChyZXN0b3JlZC52YWx1ZS50d29XYXlPcGVyYXRpb24gIT09IHVuZGVmaW5lZCkge1xyXG4gICAgICAgICAgICB0d29XYXlPcGVyYXRpb24uc2V0KGtleSwgcmVzdG9yZWQudmFsdWUudHdvV2F5T3BlcmF0aW9uKTtcclxuICAgICAgICB9XHJcbiAgICB9XHJcblxyXG4gICAgcmV0dXJuIFJlc3VsdC5vayh7XHJcbiAgICAgICAgcHJldlN0YXRlOiBtYXBUb1JlY29yZChwcmV2U3RhdGUpLFxyXG4gICAgICAgIHR3b1dheU9wZXJhdGlvbjogbWFwVG9SZWNvcmQodHdvV2F5T3BlcmF0aW9uKSxcclxuICAgIH0pO1xyXG59O1xyXG5cclxuZXhwb3J0IGNvbnN0IGFwcGx5ID0gPFRTdGF0ZSwgVFVwT3BlcmF0aW9uLCBUQ3VzdG9tRXJyb3IgPSBzdHJpbmc+KHtcclxuICAgIHByZXZTdGF0ZTogdW5zYWZlUHJldlN0YXRlLFxyXG4gICAgb3BlcmF0aW9uLFxyXG4gICAgaW5uZXJBcHBseSxcclxuICAgIGRlZmF1bHRTdGF0ZSxcclxufToge1xyXG4gICAgcHJldlN0YXRlOiBTdH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j47XHJcbiAgICBpbm5lckNvbXBvc2U6IChwYXJhbXM6IHtcclxuICAgICAgICBrZXk6IHN0cmluZztcclxuICAgICAgICBmaXJzdDogVE9wZXJhdGlvbjtcclxuICAgICAgICBzZWNvbmQ6IFRPcGVyYXRpb247XHJcbiAgICB9KSA9PiBDdXN0b21SZXN1bHQ8VE9wZXJhdGlvbiB8IHVuZGVmaW5lZCwgc3RyaW5nIHwgVEN1c3RvbUVycm9yPjtcclxufSk6IEN1c3RvbVJlc3VsdDxTdHJpbmdLZXlSZWNvcmQ8VE9wZXJhdGlvbj4gfCB1bmRlZmluZWQsIHN0cmluZyB8IFRDdXN0b21FcnJvcj4gPT4ge1xyXG4gICAgaWYgKGZpcnN0ID09IG51bGwpIHtcclxuICAgICAgICByZXR1cm4gUmVzdWx0Lm9rKHNlY29uZCk7XHJcbiAgICB9XHJcbiAgICBpZiAoc2Vjb25kID09IG51bGwpIHtcclxuICAgICAgICByZXR1cm4gUmVzdWx0Lm9rKGZpcnN0KTtcclxuICAgIH1cclxuXHJcbiAgICBjb25zdCByZXN1bHQgPSBuZXcgTWFwPHN0cmluZywgVE9wZXJhdGlvbj4oKTtcclxuXHJcbiAgICBmb3IgKGNvbnN0IFtrZXksIGdyb3VwSm9pbmVkXSBvZiBncm91cEpvaW5NYXAocmVjb3JkVG9NYXAoZmlyc3QpLCByZWNvcmRUb01hcChzZWNvbmQpKSkge1xyXG4gICAgICAgIHN3aXRjaCAoZ3JvdXBKb2luZWQudHlwZSkge1xyXG4gICAgICAgICAgICBjYXNlIGxlZnQ6XHJcbiAgICAgICAgICAgICAgICByZXN1bHQuc2V0KGtleSwgZ3JvdXBKb2luZWQubGVmdCk7XHJcbiAgICAgICAgICAgICAgICBjb250aW51ZTtcclxuICAgICAgICAgICAgY2FzZSByaWdodDpcclxuICAgICAgICAgICAgICAgIHJlc3VsdC5zZXQoa2V5LCBncm91cEpvaW5lZC5yaWdodCk7XHJcbiAgICAgICAgICAgICAgICBjb250aW51ZTtcclxuICAgICAgICAgICAgY2FzZSBib3RoOiB7XHJcbiAgICAgICAgICAgICAgICBjb25zdCB1cGRhdGUgPSBpbm5lckNvbXBvc2Uoe1xyXG4gICAgICAgICAgICAgICAgICAgIGZpcnN0OiBncm91cEpvaW5lZC5sZWZ0LFxyXG4gICAgICAgICAgICAgICAgICAgIHNlY29uZDogZ3JvdXBKb2luZWQucmlnaHQsXHJcbiAgICAgICAgICAgICAgICAgICAga2V5LFxyXG4gICAgICAgICAgICAgICAgfSk7XHJcbiAgICAgICAgICAgICAgICBpZiAodXBkYXRlLmlzRXJyb3IpIHtcclxuICAgICAgICAgICAgICAgICAgICByZXR1cm4gdXBkYXRlO1xyXG4gICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgaWYgKHVwZGF0ZS52YWx1ZSAhPT0gdW5kZWZpbmVkKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgcmVzdWx0LnNldChrZXksIHVwZGF0ZS52YWx1ZSk7XHJcbiAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgICAgICBjb250aW51ZTtcclxuICAgICAgICAgICAgfVxyXG4gICAgICAgIH1cclxuICAgIH1cclxuICAgIHJldHVybiBSZXN1bHQub2sobWFwVG9SZWNvcmQocmVzdWx0KSk7XHJcbn07XHJcblxyXG4vLyBNYWtlIHN1cmUgdGhlc2U6XHJcbi8vIC0gYXBwbHkocHJldlN0YXRlLCBmaXJzdCkgPSBuZXh0U3RhdGVcclxuZXhwb3J0IGNvbnN0IHNlcnZlclRyYW5zZm9ybSA9IDxcclxuICAgIFRTZXJ2ZXJTdGF0ZSxcclxuICAgIFRGaXJzdE9wZXJhdGlvbixcclxuICAgIFRTZWNvbmRPcGVyYXRpb24sXHJcbiAgICBUQ3VzdG9tRXJyb3IgPSBzdHJpbmdcclxuPih7XHJcbiAgICBmaXJzdDogdW5zYWZlRmlyc3QsXHJcbiAgICBzZWNvbmQ6IHVuc2FmZVNlY29uZCxcclxuICAgIHByZXZTdG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h0OiB7XHJcbiAgICAgICAgICAgICAgICBzZWNvbmRQcmltZS5zZXQoa2V5LCBncm91cC5yaWdodCk7XHJcbiAgICAgICAgICAgICAgICByZXR1cm47XHJcbiAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgY2FzZSBib3RoOiB7XHJcbiAgICAgICAgICAgICAgICBjb25zdCB4Zm9ybSA9IGlubmVyVHJhbnNmb3JtKHtcclxuICAgICAgICAgICAgICAgICAgICBmaXJzdDogZ3JvdXAubGVmdCxcclxuICAgICAgICAgICAgICAgICAgICBzZWNvbmQ6IGdyb3VwLnJpZ2h0LFxyXG4gICAgICAgICAgICAgICAgfSk7XHJcbiAgICAgICAgICAgICAgICBpZiAoeGZvcm0uaXNFcnJvcikge1xyXG4gICAgICAgICAgICAgICAgICAgIGVycm9yID0geyBlcnJvcjogeGZvcm0uZXJyb3IgfTtcclxuICAgICAgICAgICAgICAgICAgICByZXR1cm47XHJcbiAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgICAgICBpZiAoeGZvcm0udmFsdWUuZmlyc3RQcmltZSAhPT0gdW5kZWZpbmVkKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgZmlyc3RQcmltZS5zZXQoa2V5LCB4Zm9ybS52YWx1ZS5maXJzdFByaW1lKTtcclxuICAgICAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgICAgIGlmICh4Zm9ybS52YWx1ZS5zZWNvbmRQcmltZSAhPT0gdW5kZWZpbmVkKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgc2Vjb25kUHJpbWUuc2V0KGtleSwgeGZvcm0udmFsdWUuc2Vjb25kUHJpbWUpO1xyXG4gICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgcmV0dXJuO1xyXG4gICAgICAgICAgICB9XHJcbiAgICAgICAgfVxyXG4gICAgfSk7XHJcbiAgICBpZiAoZXJyb3IgIT0gbnVsbCkge1xyXG4gICAgICAgIHJldHVybiBSZXN1bHQuZXJyb3IoZXJy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U3RhdGU6IFRTdGF0ZSB8IHVuZGVmaW5lZCA9IHVuZGVmaW5lZDtcclxuICAgICAgICBsZXQgbmV4dFN0YXRlOiBUU3RhdGUgfCB1bmRlZmluZWQgPSB1bmRlZmluZWQ7XHJcblxyXG4gICAgICAgIHN3aXRjaCAodmFsdWUudHlwZSkge1xyXG4gICAgICAgICAgICBjYXNlIGxlZnQ6XHJcbiAgICAgICAgICAgICAgICBwcmV2U3RhdGUgPSB2YWx1ZS5sZWZ0O1xyXG4gICAgICAgICAgICAgICAgYnJlYWs7XHJcbiAgICAgICAgICAgIGNhc2UgcmlnaHQ6IHtcclxuICAgICAgICAgICAgICAgIG5leHRTdGF0ZSA9IHZhbHVlLnJpZ2h0O1xyXG4gICAgICAgICAgICAgICAgYnJlYWs7XHJcbiAgICAgICAgICAgIH1cclxuICAgICAgICAgICAgY2FzZSBib3RoOiB7XHJcbiAgICAgICAgICAgICAgICBwcmV2U3RhdGUgPSB2YWx1ZS5sZWZ0O1xyXG4gICAgICAgICAgICAgICAgbmV4dFN0YXRlID0gdmFsdWUucmlnaHQ7XHJcbiAgICAgICAgICAgICAgICBicmVhaztcclxuICAgICAgICAgICAgfVxyXG4gICAgICAgIH1cclxuICAgICAgICBjb25zdCBkaWZmUmVzdWx0ID0gaW5uZXJEaWZmKHsgcHJldlN0YXRlLCBuZXh0U3RhdGUsIGtleSB9KTtcclxuICAgICAgICBpZiAoZGlmZlJlc3VsdCA9PT0gdW5kZWZpbmVkKSB7XHJcbiAgICAgICAgICAgIGNvbnRpbnVlO1xyXG4gICAgICAgIH1cclxuICAgICAgICByZXN1bHQuc2V0KGtleSwgZGlmZlJlc3VsdCk7XHJcbiAgICAgICAgY29udGludWU7XHJcbiAgICB9XHJcbiAgICBpZiAocmVzdWx0LnNpemUgPT09IDApIHtcclxuICAgICAgICByZXR1cm4gdW5kZWZpbmVkO1xyXG4gICAgfVxyXG4gICAgcmV0dXJuIG1hcFRvUmVjb3JkKHJlc3VsdCk7XHJcbn07XHJcbiJdfQ==

@@ -20,2 +20,8 @@ export const composeDownOperation = (first, second) => {

export const clientTransform = ({ first, second, }) => {
if (first == null) {
return {
firstPrime: undefined,
secondPrime: second,
};
}
return {

@@ -44,2 +50,2 @@ firstPrime: first,

};
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicmVwbGFjZU9wZXJhdGlvbi5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uLy4uL3NyYy9pbnRlcm5hbC9vdC91dGlsL3JlcGxhY2VPcGVyYXRpb24udHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBc0JBLE1BQU0sQ0FBQyxNQUFNLG9CQUFvQixHQUFHLENBQ2hDLEtBQWtDLEVBQ2xDLE1BQW1DLEVBQ1IsRUFBRTtJQUM3QixJQUFJLEtBQUssS0FBSyxTQUFTLEVBQUU7UUFDckIsT0FBTyxNQUFNLENBQUM7S0FDakI7SUFDRCxJQUFJLE1BQU0sS0FBSyxTQUFTLEVBQUU7UUFDdEIsT0FBTyxLQUFLLENBQUM7S0FDaEI7SUFDRCxPQUFPLEVBQUUsUUFBUSxFQUFFLEtBQUssQ0FBQyxRQUFRLEVBQUUsQ0FBQztBQUN4QyxDQUFDLENBQUM7QUFFRixNQUFNLENBQUMsTUFBTSxlQUFlLEdBQUcsQ0FBSSxFQUMvQixLQUFLLEVBQ0wsTUFBTSxFQUNOLFNBQVMsR0FDa0IsRUFBNEIsRUFBRTtJQUN6RCxJQUFJLEtBQUssS0FBSyxTQUFTLElBQUksTUFBTSxLQUFLLFNBQVMsRUFBRTtRQUM3QyxNQUFNLFlBQVksR0FBRyxFQUFFLFFBQVEsRUFBRSxTQUFTLEVBQUUsUUFBUSxFQUFFLE1BQU0sQ0FBQyxRQUFRLEVBQUUsQ0FBQztRQUN4RSxJQUFJLFlBQVksQ0FBQyxRQUFRLEtBQUssWUFBWSxDQUFDLFFBQVEsRUFBRTt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pc1ZhbHVlUHJpdmF0ZSAmJiAhaXNBdXRob3JpemVkKSB7XHJcbiAgICAgICAgICAgIHJldHVybiB1bmRlZmluZWQ7XHJcbiAgICAgICAgfVxyXG4gICAgICAgIHJldHVybiB7XHJcbiAgICAgICAgICAgIG5ld1ZhbHVlOiBuZXdWYWx1ZS52YWx1ZSxcclxuICAgICAgICB9O1xyXG4gICAgfVxyXG4gICAgaWYgKG5ld1ZhbHVlLmlzVmFsdWVQcml2YXRlICYmICFpc0F1dGhvcml6ZWQpIHtcclxuICAgICAgICByZXR1cm4ge1xyXG4gICAgICAgICAgICBuZXdWYWx1ZTogZGVmYXVsdFN0YXRlLFxyXG4gICAgICAgIH07XHJcbiAgICB9XHJcbiAgICByZXR1cm4ge1xyXG4gICAgICAgIG5ld1ZhbHVlOiBuZXdWYWx1ZS52YWx1ZSxcclxuICAgIH07XHJcbn07XHJcbiJdfQ==
{
"version": "0.15.1",
"version": "0.15.2",
"license": "MIT",

@@ -43,2 +43,4 @@ "main": "dist/cjs/index.js",

"eslint-config-prettier": "^8.3.0",
"fast-check": "^2.17.0",
"fast-check-io-ts": "^0.5.0",
"jest": "^27.0.6",

@@ -45,0 +47,0 @@ "prettier": "^2.3.2",

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc