@keyban/cli 0.2.0 → 0.2.1
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/SKILL.md +137 -65
- package/dist/index.mjs +891 -377
- package/dist/index.mjs.map +4 -4
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -3207,9 +3207,9 @@ Expecting one of '${allowedValues.join("', '")}'`);
|
|
|
3207
3207
|
helpWidth: context.helpWidth,
|
|
3208
3208
|
outputHasColors: context.hasColors
|
|
3209
3209
|
});
|
|
3210
|
-
const
|
|
3211
|
-
if (context.hasColors) return
|
|
3212
|
-
return this._outputConfiguration.stripColor(
|
|
3210
|
+
const text5 = helper.formatHelp(this, helper);
|
|
3211
|
+
if (context.hasColors) return text5;
|
|
3212
|
+
return this._outputConfiguration.stripColor(text5);
|
|
3213
3213
|
}
|
|
3214
3214
|
/**
|
|
3215
3215
|
* @typedef HelpContext
|
|
@@ -3369,7 +3369,7 @@ Expecting one of '${allowedValues.join("', '")}'`);
|
|
|
3369
3369
|
* @param {(string | Function)} text - string to add, or a function returning a string
|
|
3370
3370
|
* @return {Command} `this` command for chaining
|
|
3371
3371
|
*/
|
|
3372
|
-
addHelpText(position,
|
|
3372
|
+
addHelpText(position, text5) {
|
|
3373
3373
|
const allowedValues = ["beforeAll", "before", "after", "afterAll"];
|
|
3374
3374
|
if (!allowedValues.includes(position)) {
|
|
3375
3375
|
throw new Error(`Unexpected value for position to addHelpText.
|
|
@@ -3378,10 +3378,10 @@ Expecting one of '${allowedValues.join("', '")}'`);
|
|
|
3378
3378
|
const helpEvent = `${position}Help`;
|
|
3379
3379
|
this.on(helpEvent, (context) => {
|
|
3380
3380
|
let helpStr;
|
|
3381
|
-
if (typeof
|
|
3382
|
-
helpStr =
|
|
3381
|
+
if (typeof text5 === "function") {
|
|
3382
|
+
helpStr = text5({ error: context.error, command: context.command });
|
|
3383
3383
|
} else {
|
|
3384
|
-
helpStr =
|
|
3384
|
+
helpStr = text5;
|
|
3385
3385
|
}
|
|
3386
3386
|
if (helpStr) {
|
|
3387
3387
|
context.write(`${helpStr}
|
|
@@ -15113,9 +15113,9 @@ var require_instructions_service = __commonJS({
|
|
|
15113
15113
|
const cached2 = this.cache.get(name);
|
|
15114
15114
|
if (cached2 !== void 0)
|
|
15115
15115
|
return cached2;
|
|
15116
|
-
const
|
|
15117
|
-
this.cache.set(name,
|
|
15118
|
-
return
|
|
15116
|
+
const text5 = await this.readSkill(name);
|
|
15117
|
+
this.cache.set(name, text5);
|
|
15118
|
+
return text5;
|
|
15119
15119
|
}
|
|
15120
15120
|
};
|
|
15121
15121
|
exports.InstructionsService = InstructionsService;
|
|
@@ -26776,7 +26776,7 @@ var require_core = __commonJS({
|
|
|
26776
26776
|
errorsText(errors = this.errors, { separator = ", ", dataVar = "data" } = {}) {
|
|
26777
26777
|
if (!errors || errors.length === 0)
|
|
26778
26778
|
return "No errors";
|
|
26779
|
-
return errors.map((e5) => `${dataVar}${e5.instancePath} ${e5.message}`).reduce((
|
|
26779
|
+
return errors.map((e5) => `${dataVar}${e5.instancePath} ${e5.message}`).reduce((text5, msg) => text5 + separator + msg);
|
|
26780
26780
|
}
|
|
26781
26781
|
$dataMetaSchema(metaSchema, keywordsJsonPointers) {
|
|
26782
26782
|
const rules = this.RULES.all;
|
|
@@ -36130,7 +36130,7 @@ ${prettyStateOverride(stateOverride)}`;
|
|
|
36130
36130
|
}
|
|
36131
36131
|
};
|
|
36132
36132
|
ContractFunctionExecutionError = class extends BaseError2 {
|
|
36133
|
-
constructor(cause, { abi: abi2, args, contractAddress, docsPath: docsPath8, functionName, sender }) {
|
|
36133
|
+
constructor(cause, { abi: abi2, args, contractAddress, docsPath: docsPath8, functionName, sender: sender2 }) {
|
|
36134
36134
|
const abiItem = getAbiItem({ abi: abi2, args, name: functionName });
|
|
36135
36135
|
const formattedArgs = abiItem ? formatAbiItemWithArgs({
|
|
36136
36136
|
abiItem,
|
|
@@ -36143,7 +36143,7 @@ ${prettyStateOverride(stateOverride)}`;
|
|
|
36143
36143
|
address: contractAddress && getContractAddress(contractAddress),
|
|
36144
36144
|
function: functionWithParams,
|
|
36145
36145
|
args: formattedArgs && formattedArgs !== "()" && `${[...Array(functionName?.length ?? 0).keys()].map(() => " ").join("")}${formattedArgs}`,
|
|
36146
|
-
sender
|
|
36146
|
+
sender: sender2
|
|
36147
36147
|
});
|
|
36148
36148
|
super(cause.shortMessage || `An unknown error occurred while executing the contract function "${functionName}".`, {
|
|
36149
36149
|
cause,
|
|
@@ -36202,7 +36202,7 @@ ${prettyStateOverride(stateOverride)}`;
|
|
|
36202
36202
|
this.cause = cause;
|
|
36203
36203
|
this.contractAddress = contractAddress;
|
|
36204
36204
|
this.functionName = functionName;
|
|
36205
|
-
this.sender =
|
|
36205
|
+
this.sender = sender2;
|
|
36206
36206
|
}
|
|
36207
36207
|
};
|
|
36208
36208
|
ContractFunctionRevertedError = class extends BaseError2 {
|
|
@@ -41513,7 +41513,7 @@ var init_ccip = __esm({
|
|
|
41513
41513
|
init_base();
|
|
41514
41514
|
init_utils3();
|
|
41515
41515
|
OffchainLookupError = class extends BaseError2 {
|
|
41516
|
-
constructor({ callbackSelector, cause, data, extraData, sender, urls }) {
|
|
41516
|
+
constructor({ callbackSelector, cause, data, extraData, sender: sender2, urls }) {
|
|
41517
41517
|
super(cause.shortMessage || "An error occurred while fetching for an offchain result.", {
|
|
41518
41518
|
cause,
|
|
41519
41519
|
metaMessages: [
|
|
@@ -41524,7 +41524,7 @@ var init_ccip = __esm({
|
|
|
41524
41524
|
" Gateway URL(s):",
|
|
41525
41525
|
...urls.map((url2) => ` ${getUrl(url2)}`)
|
|
41526
41526
|
],
|
|
41527
|
-
` Sender: ${
|
|
41527
|
+
` Sender: ${sender2}`,
|
|
41528
41528
|
` Data: ${data}`,
|
|
41529
41529
|
` Callback selector: ${callbackSelector}`,
|
|
41530
41530
|
` Extra data: ${extraData}`
|
|
@@ -41545,11 +41545,11 @@ var init_ccip = __esm({
|
|
|
41545
41545
|
}
|
|
41546
41546
|
};
|
|
41547
41547
|
OffchainLookupSenderMismatchError = class extends BaseError2 {
|
|
41548
|
-
constructor({ sender, to }) {
|
|
41548
|
+
constructor({ sender: sender2, to }) {
|
|
41549
41549
|
super("Reverted sender address does not match target contract address (`to`).", {
|
|
41550
41550
|
metaMessages: [
|
|
41551
41551
|
`Contract address: ${to}`,
|
|
41552
|
-
`OffchainLookup sender address: ${
|
|
41552
|
+
`OffchainLookup sender address: ${sender2}`
|
|
41553
41553
|
],
|
|
41554
41554
|
name: "OffchainLookupSenderMismatchError"
|
|
41555
41555
|
});
|
|
@@ -41711,16 +41711,16 @@ async function offchainLookup(client2, { blockNumber, blockTag, data, requestOpt
|
|
|
41711
41711
|
data,
|
|
41712
41712
|
abi: [offchainLookupAbiItem]
|
|
41713
41713
|
});
|
|
41714
|
-
const [
|
|
41714
|
+
const [sender2, urls, callData, callbackSelector, extraData] = args;
|
|
41715
41715
|
const { ccipRead } = client2;
|
|
41716
41716
|
const ccipRequest_ = ccipRead && typeof ccipRead?.request === "function" ? ccipRead.request : ccipRequest;
|
|
41717
41717
|
try {
|
|
41718
|
-
if (!isAddressEqual(to,
|
|
41719
|
-
throw new OffchainLookupSenderMismatchError({ sender, to });
|
|
41718
|
+
if (!isAddressEqual(to, sender2))
|
|
41719
|
+
throw new OffchainLookupSenderMismatchError({ sender: sender2, to });
|
|
41720
41720
|
const result = urls.includes(localBatchGatewayUrl) ? await localBatchGatewayRequest({
|
|
41721
41721
|
data: callData,
|
|
41722
41722
|
ccipRequest: (parameters) => ccipRequest_({ ...parameters, requestOptions })
|
|
41723
|
-
}) : await ccipRequest_({ data: callData, requestOptions, sender, urls });
|
|
41723
|
+
}) : await ccipRequest_({ data: callData, requestOptions, sender: sender2, urls });
|
|
41724
41724
|
const { data: data_ } = await call(client2, {
|
|
41725
41725
|
blockNumber,
|
|
41726
41726
|
blockTag,
|
|
@@ -41742,22 +41742,22 @@ async function offchainLookup(client2, { blockNumber, blockTag, data, requestOpt
|
|
|
41742
41742
|
cause: err,
|
|
41743
41743
|
data,
|
|
41744
41744
|
extraData,
|
|
41745
|
-
sender,
|
|
41745
|
+
sender: sender2,
|
|
41746
41746
|
urls
|
|
41747
41747
|
});
|
|
41748
41748
|
}
|
|
41749
41749
|
}
|
|
41750
|
-
async function ccipRequest({ data, requestOptions, sender, urls }) {
|
|
41750
|
+
async function ccipRequest({ data, requestOptions, sender: sender2, urls }) {
|
|
41751
41751
|
let error3 = new Error("An unknown error occurred.");
|
|
41752
41752
|
for (let i5 = 0; i5 < urls.length; i5++) {
|
|
41753
41753
|
if (requestOptions?.signal?.aborted)
|
|
41754
41754
|
throw getAbortError(requestOptions.signal);
|
|
41755
41755
|
const url2 = urls[i5];
|
|
41756
41756
|
const method = url2.includes("{data}") ? "GET" : "POST";
|
|
41757
|
-
const body = method === "POST" ? { data, sender } : void 0;
|
|
41757
|
+
const body = method === "POST" ? { data, sender: sender2 } : void 0;
|
|
41758
41758
|
const headers = method === "POST" ? { "Content-Type": "application/json" } : {};
|
|
41759
41759
|
try {
|
|
41760
|
-
const response = await fetch(url2.replace("{sender}",
|
|
41760
|
+
const response = await fetch(url2.replace("{sender}", sender2.toLowerCase()).replace("{data}", data), {
|
|
41761
41761
|
body: JSON.stringify(body),
|
|
41762
41762
|
headers,
|
|
41763
41763
|
method,
|
|
@@ -46887,7 +46887,7 @@ ${(0, stateOverride_js_1.prettyStateOverride)(stateOverride)}`;
|
|
|
46887
46887
|
};
|
|
46888
46888
|
exports.CallExecutionError = CallExecutionError2;
|
|
46889
46889
|
var ContractFunctionExecutionError2 = class extends base_js_1.BaseError {
|
|
46890
|
-
constructor(cause, { abi: abi2, args, contractAddress, docsPath: docsPath8, functionName, sender }) {
|
|
46890
|
+
constructor(cause, { abi: abi2, args, contractAddress, docsPath: docsPath8, functionName, sender: sender2 }) {
|
|
46891
46891
|
const abiItem = (0, getAbiItem_js_1.getAbiItem)({ abi: abi2, args, name: functionName });
|
|
46892
46892
|
const formattedArgs = abiItem ? (0, formatAbiItemWithArgs_js_1.formatAbiItemWithArgs)({
|
|
46893
46893
|
abiItem,
|
|
@@ -46900,7 +46900,7 @@ ${(0, stateOverride_js_1.prettyStateOverride)(stateOverride)}`;
|
|
|
46900
46900
|
address: contractAddress && (0, utils_js_1.getContractAddress)(contractAddress),
|
|
46901
46901
|
function: functionWithParams,
|
|
46902
46902
|
args: formattedArgs && formattedArgs !== "()" && `${[...Array(functionName?.length ?? 0).keys()].map(() => " ").join("")}${formattedArgs}`,
|
|
46903
|
-
sender
|
|
46903
|
+
sender: sender2
|
|
46904
46904
|
});
|
|
46905
46905
|
super(cause.shortMessage || `An unknown error occurred while executing the contract function "${functionName}".`, {
|
|
46906
46906
|
cause,
|
|
@@ -46959,7 +46959,7 @@ ${(0, stateOverride_js_1.prettyStateOverride)(stateOverride)}`;
|
|
|
46959
46959
|
this.cause = cause;
|
|
46960
46960
|
this.contractAddress = contractAddress;
|
|
46961
46961
|
this.functionName = functionName;
|
|
46962
|
-
this.sender =
|
|
46962
|
+
this.sender = sender2;
|
|
46963
46963
|
}
|
|
46964
46964
|
};
|
|
46965
46965
|
exports.ContractFunctionExecutionError = ContractFunctionExecutionError2;
|
|
@@ -47751,7 +47751,7 @@ var require_getContractError = __commonJS({
|
|
|
47751
47751
|
var request_js_1 = require_request();
|
|
47752
47752
|
var rpc_js_1 = require_rpc();
|
|
47753
47753
|
var EXECUTION_REVERTED_ERROR_CODE2 = 3;
|
|
47754
|
-
function getContractError2(err, { abi: abi2, address, args, docsPath: docsPath8, functionName, sender }) {
|
|
47754
|
+
function getContractError2(err, { abi: abi2, address, args, docsPath: docsPath8, functionName, sender: sender2 }) {
|
|
47755
47755
|
const error3 = err instanceof contract_js_1.RawContractError ? err : err instanceof base_js_1.BaseError ? err.walk((err2) => typeof err2 === "object" && err2 !== null && "data" in err2) || err.walk() : {};
|
|
47756
47756
|
const { code, data, details, message, shortMessage } = error3;
|
|
47757
47757
|
const cause = (() => {
|
|
@@ -47774,7 +47774,7 @@ var require_getContractError = __commonJS({
|
|
|
47774
47774
|
contractAddress: address,
|
|
47775
47775
|
docsPath: docsPath8,
|
|
47776
47776
|
functionName,
|
|
47777
|
-
sender
|
|
47777
|
+
sender: sender2
|
|
47778
47778
|
});
|
|
47779
47779
|
}
|
|
47780
47780
|
}
|
|
@@ -52616,8 +52616,8 @@ var require_prepareTransactionRequest = __commonJS({
|
|
|
52616
52616
|
phase: "beforeFillTransaction"
|
|
52617
52617
|
});
|
|
52618
52618
|
nonce ??= request.nonce;
|
|
52619
|
-
const
|
|
52620
|
-
account =
|
|
52619
|
+
const sender2 = request.account ?? request.from;
|
|
52620
|
+
account = sender2 ? (0, parseAccount_js_1.parseAccount)(sender2) : void 0;
|
|
52621
52621
|
}
|
|
52622
52622
|
if (parameters.includes("nonce") && typeof nonce === "undefined" && account && nonceManager) {
|
|
52623
52623
|
const chainId2 = await getChainId2();
|
|
@@ -56554,7 +56554,7 @@ var require_ccip = __commonJS({
|
|
|
56554
56554
|
var base_js_1 = require_base();
|
|
56555
56555
|
var utils_js_1 = require_utils4();
|
|
56556
56556
|
var OffchainLookupError2 = class extends base_js_1.BaseError {
|
|
56557
|
-
constructor({ callbackSelector, cause, data, extraData, sender, urls }) {
|
|
56557
|
+
constructor({ callbackSelector, cause, data, extraData, sender: sender2, urls }) {
|
|
56558
56558
|
super(cause.shortMessage || "An error occurred while fetching for an offchain result.", {
|
|
56559
56559
|
cause,
|
|
56560
56560
|
metaMessages: [
|
|
@@ -56565,7 +56565,7 @@ var require_ccip = __commonJS({
|
|
|
56565
56565
|
" Gateway URL(s):",
|
|
56566
56566
|
...urls.map((url2) => ` ${(0, utils_js_1.getUrl)(url2)}`)
|
|
56567
56567
|
],
|
|
56568
|
-
` Sender: ${
|
|
56568
|
+
` Sender: ${sender2}`,
|
|
56569
56569
|
` Data: ${data}`,
|
|
56570
56570
|
` Callback selector: ${callbackSelector}`,
|
|
56571
56571
|
` Extra data: ${extraData}`
|
|
@@ -56588,11 +56588,11 @@ var require_ccip = __commonJS({
|
|
|
56588
56588
|
};
|
|
56589
56589
|
exports.OffchainLookupResponseMalformedError = OffchainLookupResponseMalformedError2;
|
|
56590
56590
|
var OffchainLookupSenderMismatchError2 = class extends base_js_1.BaseError {
|
|
56591
|
-
constructor({ sender, to }) {
|
|
56591
|
+
constructor({ sender: sender2, to }) {
|
|
56592
56592
|
super("Reverted sender address does not match target contract address (`to`).", {
|
|
56593
56593
|
metaMessages: [
|
|
56594
56594
|
`Contract address: ${to}`,
|
|
56595
|
-
`OffchainLookup sender address: ${
|
|
56595
|
+
`OffchainLookup sender address: ${sender2}`
|
|
56596
56596
|
],
|
|
56597
56597
|
name: "OffchainLookupSenderMismatchError"
|
|
56598
56598
|
});
|
|
@@ -56803,16 +56803,16 @@ var require_ccip2 = __commonJS({
|
|
|
56803
56803
|
data,
|
|
56804
56804
|
abi: [exports.offchainLookupAbiItem]
|
|
56805
56805
|
});
|
|
56806
|
-
const [
|
|
56806
|
+
const [sender2, urls, callData, callbackSelector, extraData] = args;
|
|
56807
56807
|
const { ccipRead } = client2;
|
|
56808
56808
|
const ccipRequest_ = ccipRead && typeof ccipRead?.request === "function" ? ccipRead.request : ccipRequest2;
|
|
56809
56809
|
try {
|
|
56810
|
-
if (!(0, isAddressEqual_js_1.isAddressEqual)(to,
|
|
56811
|
-
throw new ccip_js_1.OffchainLookupSenderMismatchError({ sender, to });
|
|
56810
|
+
if (!(0, isAddressEqual_js_1.isAddressEqual)(to, sender2))
|
|
56811
|
+
throw new ccip_js_1.OffchainLookupSenderMismatchError({ sender: sender2, to });
|
|
56812
56812
|
const result = urls.includes(localBatchGatewayRequest_js_1.localBatchGatewayUrl) ? await (0, localBatchGatewayRequest_js_1.localBatchGatewayRequest)({
|
|
56813
56813
|
data: callData,
|
|
56814
56814
|
ccipRequest: (parameters) => ccipRequest_({ ...parameters, requestOptions })
|
|
56815
|
-
}) : await ccipRequest_({ data: callData, requestOptions, sender, urls });
|
|
56815
|
+
}) : await ccipRequest_({ data: callData, requestOptions, sender: sender2, urls });
|
|
56816
56816
|
const { data: data_ } = await (0, call_js_1.call)(client2, {
|
|
56817
56817
|
blockNumber,
|
|
56818
56818
|
blockTag,
|
|
@@ -56834,22 +56834,22 @@ var require_ccip2 = __commonJS({
|
|
|
56834
56834
|
cause: err,
|
|
56835
56835
|
data,
|
|
56836
56836
|
extraData,
|
|
56837
|
-
sender,
|
|
56837
|
+
sender: sender2,
|
|
56838
56838
|
urls
|
|
56839
56839
|
});
|
|
56840
56840
|
}
|
|
56841
56841
|
}
|
|
56842
|
-
async function ccipRequest2({ data, requestOptions, sender, urls }) {
|
|
56842
|
+
async function ccipRequest2({ data, requestOptions, sender: sender2, urls }) {
|
|
56843
56843
|
let error3 = new Error("An unknown error occurred.");
|
|
56844
56844
|
for (let i5 = 0; i5 < urls.length; i5++) {
|
|
56845
56845
|
if (requestOptions?.signal?.aborted)
|
|
56846
56846
|
throw (0, utils_js_1.getAbortError)(requestOptions.signal);
|
|
56847
56847
|
const url2 = urls[i5];
|
|
56848
56848
|
const method = url2.includes("{data}") ? "GET" : "POST";
|
|
56849
|
-
const body = method === "POST" ? { data, sender } : void 0;
|
|
56849
|
+
const body = method === "POST" ? { data, sender: sender2 } : void 0;
|
|
56850
56850
|
const headers = method === "POST" ? { "Content-Type": "application/json" } : {};
|
|
56851
56851
|
try {
|
|
56852
|
-
const response = await fetch(url2.replace("{sender}",
|
|
56852
|
+
const response = await fetch(url2.replace("{sender}", sender2.toLowerCase()).replace("{data}", data), {
|
|
56853
56853
|
body: JSON.stringify(body),
|
|
56854
56854
|
headers,
|
|
56855
56855
|
method,
|
|
@@ -60651,11 +60651,11 @@ var require_ccipTunnel = __commonJS({
|
|
|
60651
60651
|
var localBatchGatewayRequest_js_1 = require_localBatchGatewayRequest();
|
|
60652
60652
|
function ccipReadTunnel({ batchGateways, ccipRequest: ccipRequest2 = ccip_js_1.ccipRequest }) {
|
|
60653
60653
|
return {
|
|
60654
|
-
async request({ data, sender, urls }) {
|
|
60654
|
+
async request({ data, sender: sender2, urls }) {
|
|
60655
60655
|
if (urls.includes(localBatchGatewayRequest_js_1.localBatchGatewayUrl)) {
|
|
60656
60656
|
return ccipRequest2({
|
|
60657
60657
|
data,
|
|
60658
|
-
sender,
|
|
60658
|
+
sender: sender2,
|
|
60659
60659
|
urls: batchGateways
|
|
60660
60660
|
});
|
|
60661
60661
|
} else {
|
|
@@ -60666,9 +60666,9 @@ var require_ccipTunnel = __commonJS({
|
|
|
60666
60666
|
data: (0, encodeFunctionData_js_1.encodeFunctionData)({
|
|
60667
60667
|
abi: abis_js_1.batchGatewayAbi,
|
|
60668
60668
|
functionName: "query",
|
|
60669
|
-
args: [[{ sender, data, urls }]]
|
|
60669
|
+
args: [[{ sender: sender2, data, urls }]]
|
|
60670
60670
|
}),
|
|
60671
|
-
sender,
|
|
60671
|
+
sender: sender2,
|
|
60672
60672
|
urls: batchGateways
|
|
60673
60673
|
})
|
|
60674
60674
|
});
|
|
@@ -69366,7 +69366,7 @@ var require_getTransaction = __commonJS({
|
|
|
69366
69366
|
var transaction_js_1 = require_transaction();
|
|
69367
69367
|
var toHex_js_1 = require_toHex();
|
|
69368
69368
|
var transaction_js_2 = require_transaction2();
|
|
69369
|
-
async function getTransaction2(client2, { blockHash, blockNumber, blockTag: blockTag_, hash: hash3, index: index2, sender, nonce }) {
|
|
69369
|
+
async function getTransaction2(client2, { blockHash, blockNumber, blockTag: blockTag_, hash: hash3, index: index2, sender: sender2, nonce }) {
|
|
69370
69370
|
const blockTag = blockTag_ || "latest";
|
|
69371
69371
|
const blockNumberHex = blockNumber !== void 0 ? (0, toHex_js_1.numberToHex)(blockNumber) : void 0;
|
|
69372
69372
|
let transaction = null;
|
|
@@ -69385,10 +69385,10 @@ var require_getTransaction = __commonJS({
|
|
|
69385
69385
|
method: "eth_getTransactionByBlockNumberAndIndex",
|
|
69386
69386
|
params: [blockNumberHex || blockTag, (0, toHex_js_1.numberToHex)(index2)]
|
|
69387
69387
|
}, { dedupe: Boolean(blockNumberHex) });
|
|
69388
|
-
} else if (
|
|
69388
|
+
} else if (sender2 && typeof nonce === "number") {
|
|
69389
69389
|
transaction = await client2.request({
|
|
69390
69390
|
method: "eth_getTransactionBySenderAndNonce",
|
|
69391
|
-
params: [
|
|
69391
|
+
params: [sender2, (0, toHex_js_1.numberToHex)(nonce)]
|
|
69392
69392
|
}, { dedupe: true });
|
|
69393
69393
|
}
|
|
69394
69394
|
if (!transaction)
|
|
@@ -103095,82 +103095,82 @@ ${problems.map((e5) => ` - ${e5}`).join("\n")}`);
|
|
|
103095
103095
|
}
|
|
103096
103096
|
};
|
|
103097
103097
|
}
|
|
103098
|
-
var import_zod26 = require_zod();
|
|
103099
103098
|
var import_zod27 = require_zod();
|
|
103100
|
-
var
|
|
103101
|
-
var
|
|
103102
|
-
var
|
|
103099
|
+
var import_zod28 = require_zod();
|
|
103100
|
+
var NonEmptyString2 = import_zod27.z.string().min(1);
|
|
103101
|
+
var Any2 = import_zod27.z.record(import_zod27.z.unknown());
|
|
103102
|
+
var OptionalAny2 = import_zod27.z.record(import_zod27.z.unknown()).optional().nullable();
|
|
103103
103103
|
var NetworkSchemaV12 = NonEmptyString2;
|
|
103104
|
-
var NetworkSchemaV22 =
|
|
103104
|
+
var NetworkSchemaV22 = import_zod27.z.string().min(3).refine((val) => val.includes(":"), {
|
|
103105
103105
|
message: "Network must be in CAIP-2 format (e.g., 'eip155:84532')"
|
|
103106
103106
|
});
|
|
103107
|
-
var NetworkSchema2 =
|
|
103107
|
+
var NetworkSchema2 = import_zod27.z.union([NetworkSchemaV12, NetworkSchemaV22]);
|
|
103108
103108
|
var PRINTABLE_ASCII_REGEX2 = /^[\x20-\x7e]+$/;
|
|
103109
|
-
var ResourceInfoSchema2 =
|
|
103109
|
+
var ResourceInfoSchema2 = import_zod27.z.object({
|
|
103110
103110
|
url: NonEmptyString2,
|
|
103111
|
-
description:
|
|
103112
|
-
mimeType:
|
|
103113
|
-
serviceName:
|
|
103114
|
-
tags:
|
|
103115
|
-
iconUrl:
|
|
103111
|
+
description: import_zod27.z.string().nullish().transform((v) => v ?? void 0),
|
|
103112
|
+
mimeType: import_zod27.z.string().nullish().transform((v) => v ?? void 0),
|
|
103113
|
+
serviceName: import_zod27.z.string().min(1).max(32).regex(PRINTABLE_ASCII_REGEX2).nullish().transform((v) => v ?? void 0),
|
|
103114
|
+
tags: import_zod27.z.array(import_zod27.z.string().min(1).max(32).regex(PRINTABLE_ASCII_REGEX2)).max(5).nullish().transform((v) => v ?? void 0),
|
|
103115
|
+
iconUrl: import_zod27.z.string().max(2048).nullish().transform((v) => v ?? void 0)
|
|
103116
103116
|
});
|
|
103117
|
-
var PaymentRequirementsV1Schema2 =
|
|
103117
|
+
var PaymentRequirementsV1Schema2 = import_zod27.z.object({
|
|
103118
103118
|
scheme: NonEmptyString2,
|
|
103119
103119
|
network: NetworkSchemaV12,
|
|
103120
103120
|
maxAmountRequired: NonEmptyString2,
|
|
103121
103121
|
resource: NonEmptyString2,
|
|
103122
103122
|
// URL string in V1
|
|
103123
|
-
description:
|
|
103124
|
-
mimeType:
|
|
103123
|
+
description: import_zod27.z.string(),
|
|
103124
|
+
mimeType: import_zod27.z.string().optional(),
|
|
103125
103125
|
outputSchema: Any2.optional().nullable(),
|
|
103126
103126
|
payTo: NonEmptyString2,
|
|
103127
|
-
maxTimeoutSeconds:
|
|
103127
|
+
maxTimeoutSeconds: import_zod27.z.number().positive(),
|
|
103128
103128
|
asset: NonEmptyString2,
|
|
103129
103129
|
extra: OptionalAny2
|
|
103130
103130
|
});
|
|
103131
|
-
var PaymentRequiredV1Schema2 =
|
|
103132
|
-
x402Version:
|
|
103133
|
-
error:
|
|
103134
|
-
accepts:
|
|
103131
|
+
var PaymentRequiredV1Schema2 = import_zod27.z.object({
|
|
103132
|
+
x402Version: import_zod27.z.literal(1),
|
|
103133
|
+
error: import_zod27.z.string().optional(),
|
|
103134
|
+
accepts: import_zod27.z.array(PaymentRequirementsV1Schema2).min(1)
|
|
103135
103135
|
});
|
|
103136
|
-
var PaymentPayloadV1Schema2 =
|
|
103137
|
-
x402Version:
|
|
103136
|
+
var PaymentPayloadV1Schema2 = import_zod27.z.object({
|
|
103137
|
+
x402Version: import_zod27.z.literal(1),
|
|
103138
103138
|
scheme: NonEmptyString2,
|
|
103139
103139
|
network: NetworkSchemaV12,
|
|
103140
103140
|
payload: Any2
|
|
103141
103141
|
});
|
|
103142
|
-
var PaymentRequirementsV2Schema2 =
|
|
103142
|
+
var PaymentRequirementsV2Schema2 = import_zod27.z.object({
|
|
103143
103143
|
scheme: NonEmptyString2,
|
|
103144
103144
|
network: NetworkSchemaV22,
|
|
103145
103145
|
amount: NonEmptyString2,
|
|
103146
103146
|
asset: NonEmptyString2,
|
|
103147
103147
|
payTo: NonEmptyString2,
|
|
103148
|
-
maxTimeoutSeconds:
|
|
103148
|
+
maxTimeoutSeconds: import_zod27.z.number().positive(),
|
|
103149
103149
|
extra: OptionalAny2
|
|
103150
103150
|
});
|
|
103151
|
-
var PaymentRequiredV2Schema2 =
|
|
103152
|
-
x402Version:
|
|
103153
|
-
error:
|
|
103151
|
+
var PaymentRequiredV2Schema2 = import_zod27.z.object({
|
|
103152
|
+
x402Version: import_zod27.z.literal(2),
|
|
103153
|
+
error: import_zod27.z.string().nullish().transform((v) => v ?? void 0),
|
|
103154
103154
|
resource: ResourceInfoSchema2,
|
|
103155
|
-
accepts:
|
|
103155
|
+
accepts: import_zod27.z.array(PaymentRequirementsV2Schema2).min(1),
|
|
103156
103156
|
extensions: OptionalAny2
|
|
103157
103157
|
});
|
|
103158
|
-
var PaymentPayloadV2Schema2 =
|
|
103159
|
-
x402Version:
|
|
103158
|
+
var PaymentPayloadV2Schema2 = import_zod27.z.object({
|
|
103159
|
+
x402Version: import_zod27.z.literal(2),
|
|
103160
103160
|
resource: ResourceInfoSchema2.nullish().transform((v) => v ?? void 0),
|
|
103161
103161
|
accepted: PaymentRequirementsV2Schema2,
|
|
103162
103162
|
payload: Any2,
|
|
103163
103163
|
extensions: OptionalAny2
|
|
103164
103164
|
});
|
|
103165
|
-
var PaymentRequirementsSchema2 =
|
|
103165
|
+
var PaymentRequirementsSchema2 = import_zod27.z.union([
|
|
103166
103166
|
PaymentRequirementsV1Schema2,
|
|
103167
103167
|
PaymentRequirementsV2Schema2
|
|
103168
103168
|
]);
|
|
103169
|
-
var PaymentRequiredSchema2 =
|
|
103169
|
+
var PaymentRequiredSchema2 = import_zod27.z.discriminatedUnion("x402Version", [
|
|
103170
103170
|
PaymentRequiredV1Schema2,
|
|
103171
103171
|
PaymentRequiredV2Schema2
|
|
103172
103172
|
]);
|
|
103173
|
-
var PaymentPayloadSchema2 =
|
|
103173
|
+
var PaymentPayloadSchema2 = import_zod27.z.discriminatedUnion("x402Version", [
|
|
103174
103174
|
PaymentPayloadV1Schema2,
|
|
103175
103175
|
PaymentPayloadV2Schema2
|
|
103176
103176
|
]);
|
|
@@ -103198,40 +103198,40 @@ ${problems.map((e5) => ` - ${e5}`).join("\n")}`);
|
|
|
103198
103198
|
}
|
|
103199
103199
|
return Math.min(delay, MAX_RETRY_DELAY_MS);
|
|
103200
103200
|
}
|
|
103201
|
-
var verifyResponseSchema2 =
|
|
103202
|
-
isValid:
|
|
103203
|
-
invalidReason:
|
|
103204
|
-
invalidMessage:
|
|
103205
|
-
payer:
|
|
103206
|
-
extensions:
|
|
103207
|
-
extra:
|
|
103208
|
-
});
|
|
103209
|
-
var settleResponseSchema2 =
|
|
103210
|
-
success:
|
|
103211
|
-
errorReason:
|
|
103212
|
-
errorMessage:
|
|
103213
|
-
payer:
|
|
103214
|
-
transaction:
|
|
103215
|
-
network:
|
|
103216
|
-
amount:
|
|
103217
|
-
extensions:
|
|
103218
|
-
extra:
|
|
103219
|
-
});
|
|
103220
|
-
var supportedKindSchema2 =
|
|
103221
|
-
x402Version:
|
|
103222
|
-
scheme:
|
|
103223
|
-
network:
|
|
103201
|
+
var verifyResponseSchema2 = import_zod28.z.object({
|
|
103202
|
+
isValid: import_zod28.z.boolean(),
|
|
103203
|
+
invalidReason: import_zod28.z.string().nullish().transform((v) => v ?? void 0),
|
|
103204
|
+
invalidMessage: import_zod28.z.string().nullish().transform((v) => v ?? void 0),
|
|
103205
|
+
payer: import_zod28.z.string().nullish().transform((v) => v ?? void 0),
|
|
103206
|
+
extensions: import_zod28.z.record(import_zod28.z.string(), import_zod28.z.unknown()).nullish().transform((v) => v ?? void 0),
|
|
103207
|
+
extra: import_zod28.z.record(import_zod28.z.string(), import_zod28.z.unknown()).nullish().transform((v) => v ?? void 0)
|
|
103208
|
+
});
|
|
103209
|
+
var settleResponseSchema2 = import_zod28.z.object({
|
|
103210
|
+
success: import_zod28.z.boolean(),
|
|
103211
|
+
errorReason: import_zod28.z.string().nullish().transform((v) => v ?? void 0),
|
|
103212
|
+
errorMessage: import_zod28.z.string().nullish().transform((v) => v ?? void 0),
|
|
103213
|
+
payer: import_zod28.z.string().nullish().transform((v) => v ?? void 0),
|
|
103214
|
+
transaction: import_zod28.z.string(),
|
|
103215
|
+
network: import_zod28.z.custom((value) => typeof value === "string"),
|
|
103216
|
+
amount: import_zod28.z.string().nullish().transform((v) => v ?? void 0),
|
|
103217
|
+
extensions: import_zod28.z.record(import_zod28.z.string(), import_zod28.z.unknown()).nullish().transform((v) => v ?? void 0),
|
|
103218
|
+
extra: import_zod28.z.record(import_zod28.z.string(), import_zod28.z.unknown()).nullish().transform((v) => v ?? void 0)
|
|
103219
|
+
});
|
|
103220
|
+
var supportedKindSchema2 = import_zod28.z.object({
|
|
103221
|
+
x402Version: import_zod28.z.number(),
|
|
103222
|
+
scheme: import_zod28.z.string(),
|
|
103223
|
+
network: import_zod28.z.custom(
|
|
103224
103224
|
(value) => typeof value === "string"
|
|
103225
103225
|
),
|
|
103226
|
-
extra:
|
|
103226
|
+
extra: import_zod28.z.record(import_zod28.z.string(), import_zod28.z.unknown()).nullish().transform((v) => v ?? void 0)
|
|
103227
103227
|
});
|
|
103228
|
-
var supportedResponseSchema2 =
|
|
103229
|
-
kinds:
|
|
103230
|
-
extensions:
|
|
103231
|
-
signers:
|
|
103228
|
+
var supportedResponseSchema2 = import_zod28.z.object({
|
|
103229
|
+
kinds: import_zod28.z.array(supportedKindSchema2),
|
|
103230
|
+
extensions: import_zod28.z.array(import_zod28.z.string()).default([]),
|
|
103231
|
+
signers: import_zod28.z.record(import_zod28.z.string(), import_zod28.z.array(import_zod28.z.string())).default({})
|
|
103232
103232
|
});
|
|
103233
|
-
function responseExcerpt(
|
|
103234
|
-
const compact =
|
|
103233
|
+
function responseExcerpt(text5, limit = 200) {
|
|
103234
|
+
const compact = text5.trim().replace(/\s+/g, " ");
|
|
103235
103235
|
if (!compact) {
|
|
103236
103236
|
return "<empty response>";
|
|
103237
103237
|
}
|
|
@@ -103293,19 +103293,19 @@ ${problems.map((e5) => ` - ${e5}`).join("\n")}`);
|
|
|
103293
103293
|
return result;
|
|
103294
103294
|
}
|
|
103295
103295
|
async function parseSuccessResponse(response, schema, operation2) {
|
|
103296
|
-
const
|
|
103296
|
+
const text5 = await response.text();
|
|
103297
103297
|
let data;
|
|
103298
103298
|
try {
|
|
103299
|
-
data = JSON.parse(
|
|
103299
|
+
data = JSON.parse(text5);
|
|
103300
103300
|
} catch {
|
|
103301
103301
|
throw new FacilitatorResponseError2(
|
|
103302
|
-
`Facilitator ${operation2} returned invalid JSON: ${responseExcerpt(
|
|
103302
|
+
`Facilitator ${operation2} returned invalid JSON: ${responseExcerpt(text5)}`
|
|
103303
103303
|
);
|
|
103304
103304
|
}
|
|
103305
103305
|
const parsed = schema.safeParse(data);
|
|
103306
103306
|
if (!parsed.success) {
|
|
103307
103307
|
throw new FacilitatorResponseError2(
|
|
103308
|
-
`Facilitator ${operation2} returned invalid data: ${responseExcerpt(
|
|
103308
|
+
`Facilitator ${operation2} returned invalid data: ${responseExcerpt(text5)}`
|
|
103309
103309
|
);
|
|
103310
103310
|
}
|
|
103311
103311
|
return parsed.data;
|
|
@@ -103355,13 +103355,13 @@ ${problems.map((e5) => ` - ${e5}`).join("\n")}`);
|
|
|
103355
103355
|
signal
|
|
103356
103356
|
});
|
|
103357
103357
|
if (!response.ok) {
|
|
103358
|
-
const
|
|
103358
|
+
const text5 = await response.text();
|
|
103359
103359
|
let data;
|
|
103360
103360
|
try {
|
|
103361
|
-
data = JSON.parse(
|
|
103361
|
+
data = JSON.parse(text5);
|
|
103362
103362
|
} catch {
|
|
103363
103363
|
throw new Error(
|
|
103364
|
-
`Facilitator verify failed (${response.status}): ${responseExcerpt(
|
|
103364
|
+
`Facilitator verify failed (${response.status}): ${responseExcerpt(text5)}`
|
|
103365
103365
|
);
|
|
103366
103366
|
}
|
|
103367
103367
|
if (typeof data === "object" && data !== null && "isValid" in data) {
|
|
@@ -103403,13 +103403,13 @@ ${problems.map((e5) => ` - ${e5}`).join("\n")}`);
|
|
|
103403
103403
|
signal
|
|
103404
103404
|
});
|
|
103405
103405
|
if (!response.ok) {
|
|
103406
|
-
const
|
|
103406
|
+
const text5 = await response.text();
|
|
103407
103407
|
let data;
|
|
103408
103408
|
try {
|
|
103409
|
-
data = JSON.parse(
|
|
103409
|
+
data = JSON.parse(text5);
|
|
103410
103410
|
} catch {
|
|
103411
103411
|
throw new Error(
|
|
103412
|
-
`Facilitator settle failed (${response.status}): ${responseExcerpt(
|
|
103412
|
+
`Facilitator settle failed (${response.status}): ${responseExcerpt(text5)}`
|
|
103413
103413
|
);
|
|
103414
103414
|
}
|
|
103415
103415
|
if (typeof data === "object" && data !== null && "success" in data) {
|
|
@@ -104766,85 +104766,85 @@ var require_schemas = __commonJS({
|
|
|
104766
104766
|
validatePaymentPayload: () => validatePaymentPayload,
|
|
104767
104767
|
validatePaymentRequired: () => validatePaymentRequired,
|
|
104768
104768
|
validatePaymentRequirements: () => validatePaymentRequirements,
|
|
104769
|
-
z: () =>
|
|
104769
|
+
z: () => import_zod28.z
|
|
104770
104770
|
});
|
|
104771
104771
|
module.exports = __toCommonJS2(schemas_exports2);
|
|
104772
|
-
var import_zod26 = require_zod();
|
|
104773
104772
|
var import_zod27 = require_zod();
|
|
104774
|
-
var
|
|
104775
|
-
var
|
|
104776
|
-
var
|
|
104773
|
+
var import_zod28 = require_zod();
|
|
104774
|
+
var NonEmptyString2 = import_zod27.z.string().min(1);
|
|
104775
|
+
var Any2 = import_zod27.z.record(import_zod27.z.unknown());
|
|
104776
|
+
var OptionalAny2 = import_zod27.z.record(import_zod27.z.unknown()).optional().nullable();
|
|
104777
104777
|
var NetworkSchemaV12 = NonEmptyString2;
|
|
104778
|
-
var NetworkSchemaV22 =
|
|
104778
|
+
var NetworkSchemaV22 = import_zod27.z.string().min(3).refine((val) => val.includes(":"), {
|
|
104779
104779
|
message: "Network must be in CAIP-2 format (e.g., 'eip155:84532')"
|
|
104780
104780
|
});
|
|
104781
|
-
var NetworkSchema2 =
|
|
104781
|
+
var NetworkSchema2 = import_zod27.z.union([NetworkSchemaV12, NetworkSchemaV22]);
|
|
104782
104782
|
var PRINTABLE_ASCII_REGEX2 = /^[\x20-\x7e]+$/;
|
|
104783
|
-
var ResourceInfoSchema2 =
|
|
104783
|
+
var ResourceInfoSchema2 = import_zod27.z.object({
|
|
104784
104784
|
url: NonEmptyString2,
|
|
104785
|
-
description:
|
|
104786
|
-
mimeType:
|
|
104787
|
-
serviceName:
|
|
104788
|
-
tags:
|
|
104789
|
-
iconUrl:
|
|
104785
|
+
description: import_zod27.z.string().nullish().transform((v) => v ?? void 0),
|
|
104786
|
+
mimeType: import_zod27.z.string().nullish().transform((v) => v ?? void 0),
|
|
104787
|
+
serviceName: import_zod27.z.string().min(1).max(32).regex(PRINTABLE_ASCII_REGEX2).nullish().transform((v) => v ?? void 0),
|
|
104788
|
+
tags: import_zod27.z.array(import_zod27.z.string().min(1).max(32).regex(PRINTABLE_ASCII_REGEX2)).max(5).nullish().transform((v) => v ?? void 0),
|
|
104789
|
+
iconUrl: import_zod27.z.string().max(2048).nullish().transform((v) => v ?? void 0)
|
|
104790
104790
|
});
|
|
104791
|
-
var PaymentRequirementsV1Schema2 =
|
|
104791
|
+
var PaymentRequirementsV1Schema2 = import_zod27.z.object({
|
|
104792
104792
|
scheme: NonEmptyString2,
|
|
104793
104793
|
network: NetworkSchemaV12,
|
|
104794
104794
|
maxAmountRequired: NonEmptyString2,
|
|
104795
104795
|
resource: NonEmptyString2,
|
|
104796
104796
|
// URL string in V1
|
|
104797
|
-
description:
|
|
104798
|
-
mimeType:
|
|
104797
|
+
description: import_zod27.z.string(),
|
|
104798
|
+
mimeType: import_zod27.z.string().optional(),
|
|
104799
104799
|
outputSchema: Any2.optional().nullable(),
|
|
104800
104800
|
payTo: NonEmptyString2,
|
|
104801
|
-
maxTimeoutSeconds:
|
|
104801
|
+
maxTimeoutSeconds: import_zod27.z.number().positive(),
|
|
104802
104802
|
asset: NonEmptyString2,
|
|
104803
104803
|
extra: OptionalAny2
|
|
104804
104804
|
});
|
|
104805
|
-
var PaymentRequiredV1Schema2 =
|
|
104806
|
-
x402Version:
|
|
104807
|
-
error:
|
|
104808
|
-
accepts:
|
|
104805
|
+
var PaymentRequiredV1Schema2 = import_zod27.z.object({
|
|
104806
|
+
x402Version: import_zod27.z.literal(1),
|
|
104807
|
+
error: import_zod27.z.string().optional(),
|
|
104808
|
+
accepts: import_zod27.z.array(PaymentRequirementsV1Schema2).min(1)
|
|
104809
104809
|
});
|
|
104810
|
-
var PaymentPayloadV1Schema2 =
|
|
104811
|
-
x402Version:
|
|
104810
|
+
var PaymentPayloadV1Schema2 = import_zod27.z.object({
|
|
104811
|
+
x402Version: import_zod27.z.literal(1),
|
|
104812
104812
|
scheme: NonEmptyString2,
|
|
104813
104813
|
network: NetworkSchemaV12,
|
|
104814
104814
|
payload: Any2
|
|
104815
104815
|
});
|
|
104816
|
-
var PaymentRequirementsV2Schema2 =
|
|
104816
|
+
var PaymentRequirementsV2Schema2 = import_zod27.z.object({
|
|
104817
104817
|
scheme: NonEmptyString2,
|
|
104818
104818
|
network: NetworkSchemaV22,
|
|
104819
104819
|
amount: NonEmptyString2,
|
|
104820
104820
|
asset: NonEmptyString2,
|
|
104821
104821
|
payTo: NonEmptyString2,
|
|
104822
|
-
maxTimeoutSeconds:
|
|
104822
|
+
maxTimeoutSeconds: import_zod27.z.number().positive(),
|
|
104823
104823
|
extra: OptionalAny2
|
|
104824
104824
|
});
|
|
104825
|
-
var PaymentRequiredV2Schema2 =
|
|
104826
|
-
x402Version:
|
|
104827
|
-
error:
|
|
104825
|
+
var PaymentRequiredV2Schema2 = import_zod27.z.object({
|
|
104826
|
+
x402Version: import_zod27.z.literal(2),
|
|
104827
|
+
error: import_zod27.z.string().nullish().transform((v) => v ?? void 0),
|
|
104828
104828
|
resource: ResourceInfoSchema2,
|
|
104829
|
-
accepts:
|
|
104829
|
+
accepts: import_zod27.z.array(PaymentRequirementsV2Schema2).min(1),
|
|
104830
104830
|
extensions: OptionalAny2
|
|
104831
104831
|
});
|
|
104832
|
-
var PaymentPayloadV2Schema2 =
|
|
104833
|
-
x402Version:
|
|
104832
|
+
var PaymentPayloadV2Schema2 = import_zod27.z.object({
|
|
104833
|
+
x402Version: import_zod27.z.literal(2),
|
|
104834
104834
|
resource: ResourceInfoSchema2.nullish().transform((v) => v ?? void 0),
|
|
104835
104835
|
accepted: PaymentRequirementsV2Schema2,
|
|
104836
104836
|
payload: Any2,
|
|
104837
104837
|
extensions: OptionalAny2
|
|
104838
104838
|
});
|
|
104839
|
-
var PaymentRequirementsSchema2 =
|
|
104839
|
+
var PaymentRequirementsSchema2 = import_zod27.z.union([
|
|
104840
104840
|
PaymentRequirementsV1Schema2,
|
|
104841
104841
|
PaymentRequirementsV2Schema2
|
|
104842
104842
|
]);
|
|
104843
|
-
var PaymentRequiredSchema2 =
|
|
104843
|
+
var PaymentRequiredSchema2 = import_zod27.z.discriminatedUnion("x402Version", [
|
|
104844
104844
|
PaymentRequiredV1Schema2,
|
|
104845
104845
|
PaymentRequiredV2Schema2
|
|
104846
104846
|
]);
|
|
104847
|
-
var PaymentPayloadSchema2 =
|
|
104847
|
+
var PaymentPayloadSchema2 = import_zod27.z.discriminatedUnion("x402Version", [
|
|
104848
104848
|
PaymentPayloadV1Schema2,
|
|
104849
104849
|
PaymentPayloadV2Schema2
|
|
104850
104850
|
]);
|
|
@@ -104902,6 +104902,7 @@ var require_network = __commonJS({
|
|
|
104902
104902
|
"use strict";
|
|
104903
104903
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
104904
104904
|
exports.networkToChainId = networkToChainId2;
|
|
104905
|
+
exports.evmChainIdForNetwork = evmChainIdForNetwork;
|
|
104905
104906
|
var X402_NETWORK_TO_CHAIN_ID = {
|
|
104906
104907
|
base: 8453,
|
|
104907
104908
|
"base-sepolia": 84532,
|
|
@@ -104925,6 +104926,16 @@ var require_network = __commonJS({
|
|
|
104925
104926
|
}
|
|
104926
104927
|
return chainId;
|
|
104927
104928
|
}
|
|
104929
|
+
var EVM_NETWORK_TO_CHAIN_ID = {
|
|
104930
|
+
EthereumAnvil: 31337,
|
|
104931
|
+
BaseSepolia: 84532,
|
|
104932
|
+
BaseMainnet: 8453,
|
|
104933
|
+
XdcApothem: 51,
|
|
104934
|
+
XdcMainnet: 50
|
|
104935
|
+
};
|
|
104936
|
+
function evmChainIdForNetwork(network) {
|
|
104937
|
+
return Object.hasOwn(EVM_NETWORK_TO_CHAIN_ID, network) ? EVM_NETWORK_TO_CHAIN_ID[network] : null;
|
|
104938
|
+
}
|
|
104928
104939
|
}
|
|
104929
104940
|
});
|
|
104930
104941
|
|
|
@@ -115787,8 +115798,8 @@ var require_lt = __commonJS({
|
|
|
115787
115798
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
115788
115799
|
exports.default = default_1;
|
|
115789
115800
|
var util2 = __importStar(require_util3());
|
|
115790
|
-
var capitalizeFirstCharacter = (
|
|
115791
|
-
return
|
|
115801
|
+
var capitalizeFirstCharacter = (text5) => {
|
|
115802
|
+
return text5.charAt(0).toUpperCase() + text5.slice(1);
|
|
115792
115803
|
};
|
|
115793
115804
|
function getUnitTypeFromNumber(number4) {
|
|
115794
115805
|
const abs = Math.abs(number4);
|
|
@@ -128170,21 +128181,21 @@ var require_visit = __commonJS({
|
|
|
128170
128181
|
case "object": {
|
|
128171
128182
|
const oldShape = def.shape;
|
|
128172
128183
|
const keys = Object.keys(oldShape);
|
|
128173
|
-
let
|
|
128184
|
+
let changed2 = false;
|
|
128174
128185
|
const newShape = {};
|
|
128175
128186
|
for (const k5 of keys) {
|
|
128176
128187
|
const mapped = run(oldShape[k5]);
|
|
128177
128188
|
if (mapped !== oldShape[k5])
|
|
128178
|
-
|
|
128189
|
+
changed2 = true;
|
|
128179
128190
|
newShape[k5] = mapped;
|
|
128180
128191
|
}
|
|
128181
128192
|
let newCatchall = def.catchall;
|
|
128182
128193
|
if (def.catchall) {
|
|
128183
128194
|
newCatchall = run(def.catchall);
|
|
128184
128195
|
if (newCatchall !== def.catchall)
|
|
128185
|
-
|
|
128196
|
+
changed2 = true;
|
|
128186
128197
|
}
|
|
128187
|
-
return
|
|
128198
|
+
return changed2 ? (0, util_js_1.clone)(s2, { ...def, shape: newShape, catchall: newCatchall }) : s2;
|
|
128188
128199
|
}
|
|
128189
128200
|
case "array": {
|
|
128190
128201
|
const mapped = run(def.element);
|
|
@@ -128192,21 +128203,21 @@ var require_visit = __commonJS({
|
|
|
128192
128203
|
}
|
|
128193
128204
|
case "tuple": {
|
|
128194
128205
|
const oldItems = def.items;
|
|
128195
|
-
let
|
|
128206
|
+
let changed2 = false;
|
|
128196
128207
|
const newItems = [];
|
|
128197
128208
|
for (const item of oldItems) {
|
|
128198
128209
|
const mapped = run(item);
|
|
128199
128210
|
if (mapped !== item)
|
|
128200
|
-
|
|
128211
|
+
changed2 = true;
|
|
128201
128212
|
newItems.push(mapped);
|
|
128202
128213
|
}
|
|
128203
128214
|
let newRest = def.rest;
|
|
128204
128215
|
if (def.rest) {
|
|
128205
128216
|
newRest = run(def.rest);
|
|
128206
128217
|
if (newRest !== def.rest)
|
|
128207
|
-
|
|
128218
|
+
changed2 = true;
|
|
128208
128219
|
}
|
|
128209
|
-
return
|
|
128220
|
+
return changed2 ? (0, util_js_1.clone)(s2, { ...def, items: newItems, rest: newRest }) : s2;
|
|
128210
128221
|
}
|
|
128211
128222
|
case "record":
|
|
128212
128223
|
case "map": {
|
|
@@ -128220,15 +128231,15 @@ var require_visit = __commonJS({
|
|
|
128220
128231
|
}
|
|
128221
128232
|
case "union": {
|
|
128222
128233
|
const oldOptions = def.options;
|
|
128223
|
-
let
|
|
128234
|
+
let changed2 = false;
|
|
128224
128235
|
const newOptions = [];
|
|
128225
128236
|
for (const opt of oldOptions) {
|
|
128226
128237
|
const mapped = run(opt);
|
|
128227
128238
|
if (mapped !== opt)
|
|
128228
|
-
|
|
128239
|
+
changed2 = true;
|
|
128229
128240
|
newOptions.push(mapped);
|
|
128230
128241
|
}
|
|
128231
|
-
return
|
|
128242
|
+
return changed2 ? (0, util_js_1.clone)(s2, { ...def, options: newOptions }) : s2;
|
|
128232
128243
|
}
|
|
128233
128244
|
case "intersection": {
|
|
128234
128245
|
const newLeft = run(def.left);
|
|
@@ -128897,7 +128908,7 @@ var require_dist3 = __commonJS({
|
|
|
128897
128908
|
"node_modules/.pnpm/@keyban+agent-wallet-protocol@file+..+sdk+libs+keyban-agent-wallet-protocol_viem@2.57.4_typescript@5.9.3_zod@3.25.76_/node_modules/@keyban/agent-wallet-protocol/dist/index.js"(exports) {
|
|
128898
128909
|
"use strict";
|
|
128899
128910
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
128900
|
-
exports.networkToChainId = exports.x402RequestSchema = exports.x402AuthorizationSchema = exports.relayPreimageSchema = exports.policyInputSchema = exports.policyDecisionSchema = exports.normalizeFrostSig = exports.encodeMultiSignerSignature = exports.decompressPoint = exports.selectExactUsdcAccept = exports.extractPayTos = exports.decodeX402 = exports.x402ToCanonical = exports.relayToCanonical = exports.extractRelayPayment = exports.computeRelayHash = exports.computeLotRelayHash = exports.computeBatchRelayHash = exports.recomputeErc7739Hash = exports.buildEip3009TypedData = exports.EIP3009_PRIMARY_TYPES = exports.EIP3009_FIELDS = exports.webAuthnSignerFromPrivateKey = exports.webAuthnChallenge = exports.verifyWebAuthnAssertion = exports.toLowS = exports.signWebAuthnAssertion = exports.encodeWebAuthnSigner = exports.encodeWebAuthnSignature = exports.encodeAuthenticatorAssertion = exports.decodeWebAuthnSignature = exports.decodeP256PublicKey = exports.base64UrlToBytes = exports.P256_N = exports.encodeMultiSignerEnvelope = exports.verifyEnrollmentCommitment = exports.sasMatches = exports.deriveSas = exports.commitEnrollment = exports.getUsdcChainEntry = void 0;
|
|
128911
|
+
exports.networkToChainId = exports.evmChainIdForNetwork = exports.x402RequestSchema = exports.x402AuthorizationSchema = exports.relayPreimageSchema = exports.policyInputSchema = exports.policyDecisionSchema = exports.normalizeFrostSig = exports.encodeMultiSignerSignature = exports.decompressPoint = exports.selectExactUsdcAccept = exports.extractPayTos = exports.decodeX402 = exports.x402ToCanonical = exports.relayToCanonical = exports.extractRelayPayment = exports.computeRelayHash = exports.computeLotRelayHash = exports.computeBatchRelayHash = exports.recomputeErc7739Hash = exports.buildEip3009TypedData = exports.EIP3009_PRIMARY_TYPES = exports.EIP3009_FIELDS = exports.webAuthnSignerFromPrivateKey = exports.webAuthnChallenge = exports.verifyWebAuthnAssertion = exports.toLowS = exports.signWebAuthnAssertion = exports.encodeWebAuthnSigner = exports.encodeWebAuthnSignature = exports.encodeAuthenticatorAssertion = exports.decodeWebAuthnSignature = exports.decodeP256PublicKey = exports.base64UrlToBytes = exports.P256_N = exports.encodeMultiSignerEnvelope = exports.verifyEnrollmentCommitment = exports.sasMatches = exports.deriveSas = exports.commitEnrollment = exports.getUsdcChainEntry = void 0;
|
|
128901
128912
|
var usdc_registry_1 = require_usdc_registry();
|
|
128902
128913
|
Object.defineProperty(exports, "getUsdcChainEntry", { enumerable: true, get: function() {
|
|
128903
128914
|
return usdc_registry_1.getUsdcChainEntry;
|
|
@@ -129027,6 +129038,9 @@ var require_dist3 = __commonJS({
|
|
|
129027
129038
|
return wire_schemas_1.x402RequestSchema;
|
|
129028
129039
|
} });
|
|
129029
129040
|
var network_1 = require_network();
|
|
129041
|
+
Object.defineProperty(exports, "evmChainIdForNetwork", { enumerable: true, get: function() {
|
|
129042
|
+
return network_1.evmChainIdForNetwork;
|
|
129043
|
+
} });
|
|
129030
129044
|
Object.defineProperty(exports, "networkToChainId", { enumerable: true, get: function() {
|
|
129031
129045
|
return network_1.networkToChainId;
|
|
129032
129046
|
} });
|
|
@@ -137452,7 +137466,7 @@ import { Readable as Readable6 } from "node:stream";
|
|
|
137452
137466
|
async function* readableToIterable(readStream) {
|
|
137453
137467
|
let streamEnded = false;
|
|
137454
137468
|
let generationEnded = false;
|
|
137455
|
-
const
|
|
137469
|
+
const records3 = new Array();
|
|
137456
137470
|
readStream.on("error", (err) => {
|
|
137457
137471
|
if (!streamEnded) {
|
|
137458
137472
|
streamEnded = true;
|
|
@@ -137462,17 +137476,17 @@ async function* readableToIterable(readStream) {
|
|
|
137462
137476
|
}
|
|
137463
137477
|
});
|
|
137464
137478
|
readStream.on("data", (data) => {
|
|
137465
|
-
|
|
137479
|
+
records3.push(data);
|
|
137466
137480
|
});
|
|
137467
137481
|
readStream.on("end", () => {
|
|
137468
137482
|
streamEnded = true;
|
|
137469
137483
|
});
|
|
137470
137484
|
while (!generationEnded) {
|
|
137471
|
-
const value = await new Promise((resolve) => setTimeout(() => resolve(
|
|
137485
|
+
const value = await new Promise((resolve) => setTimeout(() => resolve(records3.shift()), 0));
|
|
137472
137486
|
if (value) {
|
|
137473
137487
|
yield value;
|
|
137474
137488
|
}
|
|
137475
|
-
generationEnded = streamEnded &&
|
|
137489
|
+
generationEnded = streamEnded && records3.length === 0;
|
|
137476
137490
|
}
|
|
137477
137491
|
}
|
|
137478
137492
|
var EventStreamMarshaller2, eventStreamSerdeProvider2;
|
|
@@ -148961,11 +148975,11 @@ var require_dist_cjs7 = __commonJS({
|
|
|
148961
148975
|
childTags.push(p3.parseTag());
|
|
148962
148976
|
}
|
|
148963
148977
|
} else {
|
|
148964
|
-
let
|
|
148978
|
+
let text5 = "";
|
|
148965
148979
|
while (p3.i < p3.z && p3.x[p3.i] !== "<") {
|
|
148966
|
-
|
|
148980
|
+
text5 += p3.x[p3.i++];
|
|
148967
148981
|
}
|
|
148968
|
-
textParts.push(p3.decodeEntities(
|
|
148982
|
+
textParts.push(p3.decodeEntities(text5));
|
|
148969
148983
|
}
|
|
148970
148984
|
}
|
|
148971
148985
|
if (!p3.isNext("</")) {
|
|
@@ -148980,18 +148994,18 @@ var require_dist_cjs7 = __commonJS({
|
|
|
148980
148994
|
return { tag, value: "" };
|
|
148981
148995
|
}
|
|
148982
148996
|
if (!hasAttrs && !hasElementChild) {
|
|
148983
|
-
const
|
|
148984
|
-
if (
|
|
148997
|
+
const text5 = textParts.length === 1 ? textParts[0] : textParts.join("");
|
|
148998
|
+
if (text5.trim() === "" && text5.includes("\n")) {
|
|
148985
148999
|
return { tag, value: "" };
|
|
148986
149000
|
}
|
|
148987
|
-
return { tag, value:
|
|
149001
|
+
return { tag, value: text5 };
|
|
148988
149002
|
}
|
|
148989
149003
|
const obj = {};
|
|
148990
|
-
for (const
|
|
148991
|
-
if (
|
|
149004
|
+
for (const text5 of textParts) {
|
|
149005
|
+
if (text5.trim() === "" && text5.includes("\n")) {
|
|
148992
149006
|
continue;
|
|
148993
149007
|
}
|
|
148994
|
-
obj["#text"] = "#text" in obj ? obj["#text"] +
|
|
149008
|
+
obj["#text"] = "#text" in obj ? obj["#text"] + text5 : text5;
|
|
148995
149009
|
}
|
|
148996
149010
|
for (const child of childTags) {
|
|
148997
149011
|
if (child.tag === "__proto__") {
|
|
@@ -159016,9 +159030,9 @@ function jsonToolCommand(tool, call2) {
|
|
|
159016
159030
|
return command5.action(async (options, self2) => {
|
|
159017
159031
|
try {
|
|
159018
159032
|
const result = await call2(mergeArgs(options, targets), self2);
|
|
159019
|
-
const
|
|
159020
|
-
if (result.isError) throw new Error(
|
|
159021
|
-
process.stdout.write(`${
|
|
159033
|
+
const text5 = resultText(result);
|
|
159034
|
+
if (result.isError) throw new Error(text5);
|
|
159035
|
+
process.stdout.write(`${text5}
|
|
159022
159036
|
`);
|
|
159023
159037
|
} catch (error3) {
|
|
159024
159038
|
process.stderr.write(`Error: ${error3 instanceof Error ? error3.message : String(error3)}
|
|
@@ -159140,8 +159154,8 @@ function candidates(program2, words) {
|
|
|
159140
159154
|
const pool = typed.startsWith("-") || subcommands.length === 0 ? options : subcommands;
|
|
159141
159155
|
return pool.filter((name) => name.startsWith(typed));
|
|
159142
159156
|
}
|
|
159143
|
-
function print(
|
|
159144
|
-
return new Promise(() => process.stdout.write(
|
|
159157
|
+
function print(text5) {
|
|
159158
|
+
return new Promise(() => process.stdout.write(text5, () => process.exit(0)));
|
|
159145
159159
|
}
|
|
159146
159160
|
function addCompletion(program2) {
|
|
159147
159161
|
program2.command("completion").description("Print the shell completion script: source <(keyban completion bash)").argument("<shell>", `one of ${Object.keys(SCRIPTS).join(", ")}`).action(async (shell) => {
|
|
@@ -159196,6 +159210,8 @@ function createSession() {
|
|
|
159196
159210
|
prepaidContext: null,
|
|
159197
159211
|
pendingX402: /* @__PURE__ */ new Map(),
|
|
159198
159212
|
signedX402: /* @__PURE__ */ new Map(),
|
|
159213
|
+
runPayments: /* @__PURE__ */ new Map(),
|
|
159214
|
+
intentRuns: /* @__PURE__ */ new Map(),
|
|
159199
159215
|
rendersApps: false,
|
|
159200
159216
|
openUrl: null,
|
|
159201
159217
|
openedApprovals: /* @__PURE__ */ new Map(),
|
|
@@ -159473,11 +159489,13 @@ function walletFilePath(env2 = process.env) {
|
|
|
159473
159489
|
const configHome = env2.XDG_CONFIG_HOME || join2(homedir2(), ".config");
|
|
159474
159490
|
return join2(configHome, "keyban", "wallets", `${env2.KEYBAN_WALLET || "default"}.json`);
|
|
159475
159491
|
}
|
|
159492
|
+
var UPLOADED_WALLET_FILE = "/mnt/session/uploads/keyban.json";
|
|
159476
159493
|
function loadWalletFile(env2 = process.env) {
|
|
159477
|
-
|
|
159494
|
+
let file = walletFilePath(env2);
|
|
159478
159495
|
if (!existsSync(file)) {
|
|
159479
159496
|
if (env2.KEYBAN_WALLET) throw new Error(`No keyban wallet at ${file}.`);
|
|
159480
|
-
return;
|
|
159497
|
+
if (!existsSync(UPLOADED_WALLET_FILE)) return;
|
|
159498
|
+
file = UPLOADED_WALLET_FILE;
|
|
159481
159499
|
}
|
|
159482
159500
|
let parsed;
|
|
159483
159501
|
try {
|
|
@@ -159639,7 +159657,7 @@ init_contract();
|
|
|
159639
159657
|
init_request();
|
|
159640
159658
|
init_rpc();
|
|
159641
159659
|
var EXECUTION_REVERTED_ERROR_CODE = 3;
|
|
159642
|
-
function getContractError(err, { abi: abi2, address, args, docsPath: docsPath8, functionName, sender }) {
|
|
159660
|
+
function getContractError(err, { abi: abi2, address, args, docsPath: docsPath8, functionName, sender: sender2 }) {
|
|
159643
159661
|
const error3 = err instanceof RawContractError ? err : err instanceof BaseError2 ? err.walk((err2) => typeof err2 === "object" && err2 !== null && "data" in err2) || err.walk() : {};
|
|
159644
159662
|
const { code, data, details, message, shortMessage } = error3;
|
|
159645
159663
|
const cause = (() => {
|
|
@@ -159662,7 +159680,7 @@ function getContractError(err, { abi: abi2, address, args, docsPath: docsPath8,
|
|
|
159662
159680
|
contractAddress: address,
|
|
159663
159681
|
docsPath: docsPath8,
|
|
159664
159682
|
functionName,
|
|
159665
|
-
sender
|
|
159683
|
+
sender: sender2
|
|
159666
159684
|
});
|
|
159667
159685
|
}
|
|
159668
159686
|
|
|
@@ -160594,8 +160612,8 @@ async function prepareTransactionRequest(client2, args) {
|
|
|
160594
160612
|
phase: "beforeFillTransaction"
|
|
160595
160613
|
});
|
|
160596
160614
|
nonce ??= request.nonce;
|
|
160597
|
-
const
|
|
160598
|
-
account =
|
|
160615
|
+
const sender2 = request.account ?? request.from;
|
|
160616
|
+
account = sender2 ? parseAccount(sender2) : void 0;
|
|
160599
160617
|
}
|
|
160600
160618
|
if (parameters.includes("nonce") && typeof nonce === "undefined" && account && nonceManager) {
|
|
160601
160619
|
const chainId2 = await getChainId2();
|
|
@@ -167428,7 +167446,7 @@ async function getStorageValues(client2, { blockHash, blockNumber, blockTag = "l
|
|
|
167428
167446
|
// node_modules/.pnpm/viem@2.57.4_typescript@5.9.3_zod@3.25.76/node_modules/viem/_esm/actions/public/getTransaction.js
|
|
167429
167447
|
init_transaction();
|
|
167430
167448
|
init_toHex();
|
|
167431
|
-
async function getTransaction(client2, { blockHash, blockNumber, blockTag: blockTag_, hash: hash3, index: index2, sender, nonce }) {
|
|
167449
|
+
async function getTransaction(client2, { blockHash, blockNumber, blockTag: blockTag_, hash: hash3, index: index2, sender: sender2, nonce }) {
|
|
167432
167450
|
const blockTag = blockTag_ || "latest";
|
|
167433
167451
|
const blockNumberHex = blockNumber !== void 0 ? numberToHex(blockNumber) : void 0;
|
|
167434
167452
|
let transaction = null;
|
|
@@ -167447,10 +167465,10 @@ async function getTransaction(client2, { blockHash, blockNumber, blockTag: block
|
|
|
167447
167465
|
method: "eth_getTransactionByBlockNumberAndIndex",
|
|
167448
167466
|
params: [blockNumberHex || blockTag, numberToHex(index2)]
|
|
167449
167467
|
}, { dedupe: Boolean(blockNumberHex) });
|
|
167450
|
-
} else if (
|
|
167468
|
+
} else if (sender2 && typeof nonce === "number") {
|
|
167451
167469
|
transaction = await client2.request({
|
|
167452
167470
|
method: "eth_getTransactionBySenderAndNonce",
|
|
167453
|
-
params: [
|
|
167471
|
+
params: [sender2, numberToHex(nonce)]
|
|
167454
167472
|
}, { dedupe: true });
|
|
167455
167473
|
}
|
|
167456
167474
|
if (!transaction)
|
|
@@ -170280,8 +170298,8 @@ async function fetchRpcUrl(session) {
|
|
|
170280
170298
|
const url2 = `${session.baseURL}/v1/metadata?network=${encodeURIComponent(session.network)}`;
|
|
170281
170299
|
const res = await fetch(url2, { headers: buildApiKeyHeaders(session) });
|
|
170282
170300
|
if (!res.ok) {
|
|
170283
|
-
const
|
|
170284
|
-
throw new Error(`metadata request failed (${res.status}): ${
|
|
170301
|
+
const text5 = await res.text();
|
|
170302
|
+
throw new Error(`metadata request failed (${res.status}): ${text5}`);
|
|
170285
170303
|
}
|
|
170286
170304
|
const json2 = await res.json();
|
|
170287
170305
|
const rpcUrl = json2?.network?.rpcUrl;
|
|
@@ -170550,8 +170568,8 @@ function intentsStreamUrl(session, intentId) {
|
|
|
170550
170568
|
}
|
|
170551
170569
|
var RECONNECT_PAUSE_MS = 1e3;
|
|
170552
170570
|
var pause = (ms) => new Promise((resolve) => setTimeout(resolve, Math.max(0, ms)));
|
|
170553
|
-
async function openIntentsStream(session, signal,
|
|
170554
|
-
const res = await fetch(
|
|
170571
|
+
async function openIntentsStream(session, signal, url2) {
|
|
170572
|
+
const res = await fetch(url2, {
|
|
170555
170573
|
headers: { ...buildApiKeyHeaders(session), Accept: "text/event-stream" },
|
|
170556
170574
|
signal
|
|
170557
170575
|
}).catch(() => null);
|
|
@@ -170575,7 +170593,7 @@ async function readDecision(body, intentId) {
|
|
|
170575
170593
|
return null;
|
|
170576
170594
|
}
|
|
170577
170595
|
async function decisionOnOneStream(session, intentId, signal) {
|
|
170578
|
-
const body = await openIntentsStream(session, signal, intentId);
|
|
170596
|
+
const body = await openIntentsStream(session, signal, intentsStreamUrl(session, intentId));
|
|
170579
170597
|
return body ? readDecision(body, intentId).catch(() => null) : null;
|
|
170580
170598
|
}
|
|
170581
170599
|
async function watchIntent(session, intentId, timeoutMs) {
|
|
@@ -172478,6 +172496,47 @@ function createSignMessageTool(session) {
|
|
|
172478
172496
|
var import_agent_wallet_protocol5 = __toESM(require_dist3(), 1);
|
|
172479
172497
|
init_zod();
|
|
172480
172498
|
|
|
172499
|
+
// src/lib/mission-payment.ts
|
|
172500
|
+
function cardlessSession(session) {
|
|
172501
|
+
return new Proxy(session, {
|
|
172502
|
+
get: (target, key, receiver) => {
|
|
172503
|
+
if (key === "rendersApps") return false;
|
|
172504
|
+
if (key === "openUrl") return null;
|
|
172505
|
+
return Reflect.get(target, key, receiver);
|
|
172506
|
+
}
|
|
172507
|
+
});
|
|
172508
|
+
}
|
|
172509
|
+
async function answerInMission(pay, tool, inMissionTool, missionRunId) {
|
|
172510
|
+
const pattern = new RegExp(`\\b${tool}\\b`, "g");
|
|
172511
|
+
const retell = (text5) => text5.replace(pattern, `${inMissionTool} (missionRunId=${missionRunId})`);
|
|
172512
|
+
try {
|
|
172513
|
+
const answer = await pay();
|
|
172514
|
+
return typeof answer === "string" ? retell(answer) : { ...answer, text: retell(answer.text) };
|
|
172515
|
+
} catch (error3) {
|
|
172516
|
+
if (error3 instanceof PaymentHeld) throw new PaymentHeld({ ...error3.output, text: retell(error3.output.text) });
|
|
172517
|
+
if (error3 instanceof PendingAnswer) throw new PendingAnswer({ ...error3.output, text: retell(error3.output.text) });
|
|
172518
|
+
if (error3 instanceof Error) error3.message = retell(error3.message);
|
|
172519
|
+
throw error3;
|
|
172520
|
+
}
|
|
172521
|
+
}
|
|
172522
|
+
function refuseMissionPayment(missionRunId, inMissionTool) {
|
|
172523
|
+
if (!missionRunId) return;
|
|
172524
|
+
throw new Error(
|
|
172525
|
+
`This payment belongs to mission run ${missionRunId}: call ${inMissionTool} with missionRunId=${missionRunId} and the same arguments. This tool is for payments outside a mission.`
|
|
172526
|
+
);
|
|
172527
|
+
}
|
|
172528
|
+
|
|
172529
|
+
// src/lib/mission-run-payments.ts
|
|
172530
|
+
function recordRunPayment(session, runId, payment) {
|
|
172531
|
+
session.runPayments.set(runId, [...session.runPayments.get(runId) ?? [], payment]);
|
|
172532
|
+
}
|
|
172533
|
+
function runPayments(session, runId) {
|
|
172534
|
+
return [...session.runPayments.get(runId) ?? []];
|
|
172535
|
+
}
|
|
172536
|
+
function forgetRunPayments(session, runId) {
|
|
172537
|
+
session.runPayments.delete(runId);
|
|
172538
|
+
}
|
|
172539
|
+
|
|
172481
172540
|
// src/lib/relay.ts
|
|
172482
172541
|
var import_agent_wallet_protocol3 = __toESM(require_dist3(), 1);
|
|
172483
172542
|
var RelayHeld = class extends Error {
|
|
@@ -172488,7 +172547,7 @@ var RelayHeld = class extends Error {
|
|
|
172488
172547
|
this.name = "RelayHeld";
|
|
172489
172548
|
}
|
|
172490
172549
|
};
|
|
172491
|
-
async function
|
|
172550
|
+
async function executeRelayedWithIntent(publicClient, signer, dkgBlob, accountAddress, dest, value, publicKeyHex, frostVerifierAddress, data = "0x", missionRunId) {
|
|
172492
172551
|
const chainId = await publicClient.getChainId();
|
|
172493
172552
|
const code = await publicClient.getCode({ address: accountAddress });
|
|
172494
172553
|
if (!code || code === "0x") {
|
|
@@ -172537,13 +172596,14 @@ async function executeRelayed(publicClient, signer, dkgBlob, accountAddress, des
|
|
|
172537
172596
|
(0, import_agent_wallet_protocol3.normalizeFrostSig)(publicKeyHex),
|
|
172538
172597
|
frostVerifierAddress
|
|
172539
172598
|
);
|
|
172540
|
-
|
|
172599
|
+
const txHash = await signer.relay(
|
|
172541
172600
|
accountAddress,
|
|
172542
172601
|
dest,
|
|
172543
172602
|
value.toString(),
|
|
172544
172603
|
data,
|
|
172545
172604
|
multiSignerSig
|
|
172546
172605
|
);
|
|
172606
|
+
return { txHash, intentId: policyDecision.intentId };
|
|
172547
172607
|
}
|
|
172548
172608
|
|
|
172549
172609
|
// src/lib/ui-pages.ts
|
|
@@ -172557,7 +172617,7 @@ var UI_PAGES = {
|
|
|
172557
172617
|
},
|
|
172558
172618
|
[MISSION_CARD_URI]: {
|
|
172559
172619
|
name: "Mission approval",
|
|
172560
|
-
html: true ? '<!doctype html>\n<html lang="en">\n<head>\n<meta charset="utf-8">\n<meta name="viewport" content="width=device-width, initial-scale=1">\n<meta name="color-scheme" content="light dark">\n<title>Mission approval</title>\n<link rel="preconnect" href="https://fonts.googleapis.com">\n<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>\n<link rel="stylesheet" href="https://fonts.googleapis.com/css2?family=Inter:wght@400..600&display=swap">\n<style>\n:root {\n color-scheme: light;\n --radius: 0.625rem;\n --card: oklch(1 0 0);\n --foreground: oklch(0.145 0 0);\n --muted: oklch(0.97 0 0);\n --muted-foreground: oklch(0.54 0 0);\n --border: oklch(0.922 0 0);\n --outline-bg: var(--card);\n --outline-border: var(--border);\n --outline-hover: var(--muted);\n --primary: hsl(221 83% 53%);\n --primary-foreground: hsl(210 40% 98%);\n --ring: oklch(0.708 0 0);\n --destructive: oklch(0.577 0.245 27.325);\n --amber-500: oklch(76.9% 0.188 70.08);\n --emerald-500: oklch(69.6% 0.17 162.48);\n --red-500: oklch(63.7% 0.237 25.331);\n --orange-500: oklch(70.5% 0.213 47.604);\n --slate-500: oklch(55.4% 0.046 257.417);\n --slate-400: oklch(70.4% 0.04 256.788);\n --shadow-xs: 0 1px 2px 0 rgb(0 0 0 / 0.05);\n --shadow-sm: 0 1px 3px 0 rgb(0 0 0 / 0.1), 0 1px 2px -1px rgb(0 0 0 / 0.1);\n}\n:root[data-theme="dark"] {\n color-scheme: dark;\n --card: oklch(0.205 0 0);\n --foreground: oklch(0.985 0 0);\n --muted: oklch(0.269 0 0);\n --muted-foreground: oklch(0.708 0 0);\n --border: oklch(1 0 0 / 10%);\n --outline-bg: oklch(1 0 0 / 4.5%);\n --outline-border: oklch(1 0 0 / 15%);\n --outline-hover: oklch(1 0 0 / 7.5%);\n --ring: oklch(0.556 0 0);\n --destructive: oklch(0.704 0.191 22.216);\n}\n* { box-sizing: border-box; }\nhtml, body { margin: 0; background: transparent; }\nbody {\n padding: 1px 1px 4px;\n font-family: "Inter", "Inter Variable", ui-sans-serif, system-ui, sans-serif;\n font-size: 14px;\n line-height: 20px;\n color: var(--foreground);\n -webkit-font-smoothing: antialiased;\n}\n[hidden] { display: none !important; }\np { margin: 0; }\n.icon {\n width: 12px;\n height: 12px;\n flex: none;\n fill: none;\n stroke: currentColor;\n stroke-width: 2;\n stroke-linecap: round;\n stroke-linejoin: round;\n}\n.card {\n max-width: 36rem;\n overflow: hidden;\n background: var(--card);\n border: 1px solid var(--border);\n border-radius: calc(var(--radius) + 4px);\n box-shadow: var(--shadow-sm);\n}\n.head {\n display: flex;\n align-items: center;\n gap: 8px;\n padding: 10px 14px;\n background: color-mix(in oklch, var(--muted) 50%, var(--card));\n border-bottom: 1px solid var(--border);\n}\n.logo { width: 20px; height: 20px; flex: none; border-radius: 5px; }\n.title {\n flex: 1;\n min-width: 0;\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n color: var(--muted-foreground);\n font-weight: 500;\n}\n.brand { color: var(--foreground); font-weight: 600; }\n.badge {\n display: inline-flex;\n align-items: center;\n gap: 4px;\n padding: 2px 8px;\n border: 1px solid transparent;\n border-radius: calc(var(--radius) - 2px);\n background: var(--muted);\n color: var(--foreground);\n font-size: 12px;\n line-height: 16px;\n font-weight: 500;\n white-space: nowrap;\n}\n[data-state="pending_approval"] .state .icon,\n[data-state="pending_publication"] .state .icon { color: var(--amber-500); }\n[data-state="draft_changed"] .state .icon { color: var(--orange-500); }\n[data-state="active"] .state .icon,\n[data-state="published"] .state .icon { color: var(--emerald-500); }\n[data-state="completed"] .state .icon { color: var(--muted-foreground); }\n[data-state="declined"] .state .icon { color: var(--red-500); }\n[data-state="abandoned"] .state .icon,\n[data-state="cancelled"] .state .icon { color: var(--slate-500); }\n[data-state="expired"] .state .icon,\n[data-state="discarded"] .state .icon { color: var(--slate-400); }\n.body { display: grid; gap: 2px; padding: 14px; }\n.figure {\n display: flex;\n flex-wrap: wrap;\n align-items: center;\n justify-content: space-between;\n gap: 4px 12px;\n}\n.amount {\n font-size: 24px;\n line-height: 32px;\n font-weight: 600;\n letter-spacing: -0.01em;\n font-variant-numeric: tabular-nums;\n}\n.detail,\n.recipient { color: var(--muted-foreground); overflow-wrap: anywhere; }\n.status { margin-top: 8px; }\n.error { margin-top: 8px; color: var(--destructive); overflow-wrap: anywhere; }\n[data-tone="danger"] .amount,\n[data-tone="neutral"] .amount {\n color: var(--muted-foreground);\n text-decoration: line-through;\n text-decoration-thickness: 2px;\n}\n[data-tone="loading"] .body { display: none; }\n[data-tone="loading"] .head { border-bottom: 0; }\n[data-tone="empty"] .figure,\n[data-tone="empty"] .detail,\n[data-tone="empty"] .recipient { display: none; }\n.foot {\n display: flex;\n flex-wrap: wrap;\n align-items: center;\n gap: 10px 12px;\n padding: 10px 14px;\n border-top: 1px solid var(--border);\n}\n.note {\n flex: 1 1 16rem;\n color: var(--muted-foreground);\n font-size: 12px;\n line-height: 16px;\n overflow-wrap: anywhere;\n}\n.actions { display: flex; flex-wrap: wrap; gap: 8px; margin-left: auto; }\nbutton {\n display: inline-flex;\n align-items: center;\n gap: 6px;\n height: 32px;\n padding: 0 12px;\n border: 1px solid transparent;\n border-radius: calc(var(--radius) - 2px);\n font: inherit;\n font-weight: 500;\n white-space: nowrap;\n cursor: pointer;\n transition: background-color 0.15s, color 0.15s;\n}\nbutton .icon { width: 16px; height: 16px; }\n.primary { background: var(--primary); color: var(--primary-foreground); box-shadow: var(--shadow-xs); }\n.primary:hover { background: color-mix(in oklch, var(--primary) 90%, transparent); }\n.outline {\n background: var(--outline-bg);\n color: var(--foreground);\n border-color: var(--outline-border);\n box-shadow: var(--shadow-xs);\n}\n.outline:hover { background: var(--outline-hover); }\nbutton:focus-visible {\n outline: none;\n box-shadow: 0 0 0 3px color-mix(in oklch, var(--ring) 50%, transparent);\n}\nbutton:disabled { opacity: 0.5; cursor: default; pointer-events: none; }\n@media (prefers-reduced-motion: reduce) {\n button { transition: none; }\n}\n</style>\n</head>\n<body>\n<svg width="0" height="0" style="position: absolute" aria-hidden="true">\n <symbol id="i-clock" viewBox="0 0 24 24"><circle cx="12" cy="12" r="10"/><path d="M12 6v6l4 2"/></symbol>\n <symbol id="i-pen-line" viewBox="0 0 24 24"><path d="M13 21h8"/><path d="M21.174 6.812a1 1 0 0 0-3.986-3.987L3.842 16.174a2 2 0 0 0-.5.83l-1.321 4.352a.5.5 0 0 0 .623.622l4.353-1.32a2 2 0 0 0 .83-.497z"/></symbol>\n <symbol id="i-circle-check" viewBox="0 0 24 24"><circle cx="12" cy="12" r="10"/><path d="m9 12 2 2 4-4"/></symbol>\n <symbol id="i-circle-x" viewBox="0 0 24 24"><circle cx="12" cy="12" r="10"/><path d="m15 9-6 6"/><path d="m9 9 6 6"/></symbol>\n <symbol id="i-ban" viewBox="0 0 24 24"><circle cx="12" cy="12" r="10"/><path d="M4.929 4.929 19.07 19.071"/></symbol>\n <symbol id="i-triangle-alert" viewBox="0 0 24 24"><path d="m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3"/><path d="M12 9v4"/><path d="M12 17h.01"/></symbol>\n <symbol id="i-external-link" viewBox="0 0 24 24"><path d="M15 3h6v6"/><path d="M10 14 21 3"/><path d="M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6"/></symbol>\n</svg>\n<main id="card" class="card" data-tone="loading">\n <header class="head">\n <svg class="logo" viewBox="0 0 236 236" aria-hidden="true">\n <rect width="236" height="236" rx="10" fill="#a2d5f2"/>\n <g transform="matrix(.1 0 0 -.1 2.2922 220.5)"><path fill="#07689f" d="m320 1025v-775h660l-92 85-93 85h-305v1210h170l2-311 3-311 320 311 320 310h123c67 1 122-2 122-6 0-5-198-194-440-422s-439-418-438-423c2-4 131-125 287-268l284-260h380c210 0 377 4 371 8-15 14-626 573-664 608l-35 33-126-114 195-179c108-98 196-180 196-182s-57-4-127-4l-128 1-190 174c-104 96-190 181-190 188 0 9 843 812 1059 1008 6 5-154 9-365 9h-376l-204-191-204-190-3 190-2 191h-510z"/></g>\n </svg>\n <p class="title"><span class="brand">Keyban</span> \xB7 <span id="heading">Mission</span></p>\n <span id="state" class="badge state" hidden><svg class="icon" aria-hidden="true"><use id="state-icon" href="#i-clock"/></svg><span id="state-label" aria-live="polite"></span></span>\n </header>\n <section class="body">\n <p id="mission" class="recipient"></p>\n <div class="figure">\n <p id="amount" class="amount"> </p>\n </div>\n <p id="detail" class="detail" hidden></p>\n <p id="meta" class="detail" hidden></p>\n <p id="status" class="status" role="status" aria-live="polite" hidden></p>\n <p id="error" class="error" role="alert" hidden></p>\n </section>\n <footer id="foot" class="foot" hidden>\n <p id="note" class="note" hidden></p>\n <div id="actions" class="actions" hidden>\n <button id="open" class="primary" type="button"><svg class="icon" aria-hidden="true"><use href="#i-external-link"/></svg><span id="open-label"></span></button>\n </div>\n </footer>\n</main>\n<script type="module">var Np=Object.defineProperty;var Ne=(e=>typeof require<"u"?require:typeof Proxy<"u"?new Proxy(e,{get:(r,n)=>(typeof require<"u"?require:r)[n]}):e)(function(e){if(typeof require<"u")return require.apply(this,arguments);throw Error(\'Dynamic require of "\'+e+\'" is not supported\')});var S=(e,r)=>()=>(e&&(r=e(e=0)),r);var ke=(e,r)=>{for(var n in r)Np(e,n,{get:r[n],enumerable:!0})};function u(e,r,n){function i(c,p){var g;Object.defineProperty(c,"_zod",{value:c._zod??{},enumerable:!1}),(g=c._zod).traits??(g.traits=new Set),c._zod.traits.add(e),r(c,p);for(let h in a.prototype)h in c||Object.defineProperty(c,h,{value:a.prototype[h].bind(c)});c._zod.constr=a,c._zod.def=p}let t=n?.Parent??Object;class o extends t{}Object.defineProperty(o,"name",{value:e});function a(c){var p;let g=n?.Parent?new o:this;i(g,c),(p=g._zod).deferred??(p.deferred=[]);for(let h of g._zod.deferred)h();return g}return Object.defineProperty(a,"init",{value:i}),Object.defineProperty(a,Symbol.hasInstance,{value:c=>n?.Parent&&c instanceof n.Parent?!0:c?._zod?.traits?.has(e)}),Object.defineProperty(a,"name",{value:e}),a}function K(e){return e&&Object.assign(It,e),It}var zr,kr,fe,It,Ve=S(()=>{zr=Object.freeze({status:"aborted"});kr=Symbol("zod_brand"),fe=class extends Error{constructor(){super("Encountered Promise during synchronous parse. Use .parseAsync() instead.")}},It={}});var x={};ke(x,{BIGINT_FORMAT_RANGES:()=>Do,Class:()=>Io,NUMBER_FORMAT_RANGES:()=>Eo,aborted:()=>Ee,allowsEval:()=>Oo,assert:()=>Zp,assertEqual:()=>Up,assertIs:()=>Dp,assertNever:()=>Rp,assertNotEqual:()=>Ep,assignProp:()=>To,cached:()=>Tt,captureStackTrace:()=>Sr,cleanEnum:()=>Gp,cleanRegex:()=>Ot,clone:()=>ie,createTransparentProxy:()=>Fp,defineLazy:()=>A,esc:()=>Ue,escapeRegex:()=>_e,extend:()=>Jp,finalizeIssue:()=>ce,floatSafeRemainder:()=>Po,getElementAtPath:()=>Ap,getEnumValues:()=>Pt,getLengthableOrigin:()=>Et,getParsedType:()=>qp,getSizableOrigin:()=>Ut,isObject:()=>Je,isPlainObject:()=>Be,issue:()=>Ro,joinValues:()=>f,jsonStringifyReplacer:()=>jo,merge:()=>Bp,normalizeParams:()=>b,nullish:()=>Se,numKeys:()=>Mp,omit:()=>Vp,optionalKeys:()=>Uo,partial:()=>Kp,pick:()=>Hp,prefixIssues:()=>ae,primitiveTypes:()=>No,promiseAllObject:()=>Cp,propertyKeyTypes:()=>Nt,randomString:()=>Lp,required:()=>Wp,stringifyPrimitive:()=>_,unwrapMessage:()=>jt});function Up(e){return e}function Ep(e){return e}function Dp(e){}function Rp(e){throw new Error}function Zp(e){}function Pt(e){let r=Object.values(e).filter(i=>typeof i=="number");return Object.entries(e).filter(([i,t])=>r.indexOf(+i)===-1).map(([i,t])=>t)}function f(e,r="|"){return e.map(n=>_(n)).join(r)}function jo(e,r){return typeof r=="bigint"?r.toString():r}function Tt(e){return{get value(){{let n=e();return Object.defineProperty(this,"value",{value:n}),n}throw new Error("cached value already set")}}}function Se(e){return e==null}function Ot(e){let r=e.startsWith("^")?1:0,n=e.endsWith("$")?e.length-1:e.length;return e.slice(r,n)}function Po(e,r){let n=(e.toString().split(".")[1]||"").length,i=(r.toString().split(".")[1]||"").length,t=n>i?n:i,o=Number.parseInt(e.toFixed(t).replace(".","")),a=Number.parseInt(r.toFixed(t).replace(".",""));return o%a/10**t}function A(e,r,n){Object.defineProperty(e,r,{get(){{let t=n();return e[r]=t,t}throw new Error("cached value already set")},set(t){Object.defineProperty(e,r,{value:t})},configurable:!0})}function To(e,r,n){Object.defineProperty(e,r,{value:n,writable:!0,enumerable:!0,configurable:!0})}function Ap(e,r){return r?r.reduce((n,i)=>n?.[i],e):e}function Cp(e){let r=Object.keys(e),n=r.map(i=>e[i]);return Promise.all(n).then(i=>{let t={};for(let o=0;o<r.length;o++)t[r[o]]=i[o];return t})}function Lp(e=10){let r="abcdefghijklmnopqrstuvwxyz",n="";for(let i=0;i<e;i++)n+=r[Math.floor(Math.random()*r.length)];return n}function Ue(e){return JSON.stringify(e)}function Je(e){return typeof e=="object"&&e!==null&&!Array.isArray(e)}function Be(e){if(Je(e)===!1)return!1;let r=e.constructor;if(r===void 0)return!0;let n=r.prototype;return!(Je(n)===!1||Object.prototype.hasOwnProperty.call(n,"isPrototypeOf")===!1)}function Mp(e){let r=0;for(let n in e)Object.prototype.hasOwnProperty.call(e,n)&&r++;return r}function _e(e){return e.replace(/[.*+?^${}()|[\\]\\\\]/g,"\\\\$&")}function ie(e,r,n){let i=new e._zod.constr(r??e._zod.def);return(!r||n?.parent)&&(i._zod.parent=e),i}function b(e){let r=e;if(!r)return{};if(typeof r=="string")return{error:()=>r};if(r?.message!==void 0){if(r?.error!==void 0)throw new Error("Cannot specify both `message` and `error` params");r.error=r.message}return delete r.message,typeof r.error=="string"?{...r,error:()=>r.error}:r}function Fp(e){let r;return new Proxy({},{get(n,i,t){return r??(r=e()),Reflect.get(r,i,t)},set(n,i,t,o){return r??(r=e()),Reflect.set(r,i,t,o)},has(n,i){return r??(r=e()),Reflect.has(r,i)},deleteProperty(n,i){return r??(r=e()),Reflect.deleteProperty(r,i)},ownKeys(n){return r??(r=e()),Reflect.ownKeys(r)},getOwnPropertyDescriptor(n,i){return r??(r=e()),Reflect.getOwnPropertyDescriptor(r,i)},defineProperty(n,i,t){return r??(r=e()),Reflect.defineProperty(r,i,t)}})}function _(e){return typeof e=="bigint"?e.toString()+"n":typeof e=="string"?`"${e}"`:`${e}`}function Uo(e){return Object.keys(e).filter(r=>e[r]._zod.optin==="optional"&&e[r]._zod.optout==="optional")}function Hp(e,r){let n={},i=e._zod.def;for(let t in r){if(!(t in i.shape))throw new Error(`Unrecognized key: "${t}"`);r[t]&&(n[t]=i.shape[t])}return ie(e,{...e._zod.def,shape:n,checks:[]})}function Vp(e,r){let n={...e._zod.def.shape},i=e._zod.def;for(let t in r){if(!(t in i.shape))throw new Error(`Unrecognized key: "${t}"`);r[t]&&delete n[t]}return ie(e,{...e._zod.def,shape:n,checks:[]})}function Jp(e,r){if(!Be(r))throw new Error("Invalid input to extend: expected a plain object");let n={...e._zod.def,get shape(){let i={...e._zod.def.shape,...r};return To(this,"shape",i),i},checks:[]};return ie(e,n)}function Bp(e,r){return ie(e,{...e._zod.def,get shape(){let n={...e._zod.def.shape,...r._zod.def.shape};return To(this,"shape",n),n},catchall:r._zod.def.catchall,checks:[]})}function Kp(e,r,n){let i=r._zod.def.shape,t={...i};if(n)for(let o in n){if(!(o in i))throw new Error(`Unrecognized key: "${o}"`);n[o]&&(t[o]=e?new e({type:"optional",innerType:i[o]}):i[o])}else for(let o in i)t[o]=e?new e({type:"optional",innerType:i[o]}):i[o];return ie(r,{...r._zod.def,shape:t,checks:[]})}function Wp(e,r,n){let i=r._zod.def.shape,t={...i};if(n)for(let o in n){if(!(o in t))throw new Error(`Unrecognized key: "${o}"`);n[o]&&(t[o]=new e({type:"nonoptional",innerType:i[o]}))}else for(let o in i)t[o]=new e({type:"nonoptional",innerType:i[o]});return ie(r,{...r._zod.def,shape:t,checks:[]})}function Ee(e,r=0){for(let n=r;n<e.issues.length;n++)if(e.issues[n]?.continue!==!0)return!0;return!1}function ae(e,r){return r.map(n=>{var i;return(i=n).path??(i.path=[]),n.path.unshift(e),n})}function jt(e){return typeof e=="string"?e:e?.message}function ce(e,r,n){let i={...e,path:e.path??[]};if(!e.message){let t=jt(e.inst?._zod.def?.error?.(e))??jt(r?.error?.(e))??jt(n.customError?.(e))??jt(n.localeError?.(e))??"Invalid input";i.message=t}return delete i.inst,delete i.continue,r?.reportInput||delete i.input,i}function Ut(e){return e instanceof Set?"set":e instanceof Map?"map":e instanceof File?"file":"unknown"}function Et(e){return Array.isArray(e)?"array":typeof e=="string"?"string":"unknown"}function Ro(...e){let[r,n,i]=e;return typeof r=="string"?{message:r,code:"custom",input:n,inst:i}:{...r}}function Gp(e){return Object.entries(e).filter(([r,n])=>Number.isNaN(Number.parseInt(r,10))).map(r=>r[1])}var Sr,Oo,qp,Nt,No,Eo,Do,Io,P=S(()=>{Sr=Error.captureStackTrace?Error.captureStackTrace:(...e)=>{};Oo=Tt(()=>{if(typeof navigator<"u"&&navigator?.userAgent?.includes("Cloudflare"))return!1;try{let e=Function;return new e(""),!0}catch{return!1}});qp=e=>{let r=typeof e;switch(r){case"undefined":return"undefined";case"string":return"string";case"number":return Number.isNaN(e)?"nan":"number";case"boolean":return"boolean";case"function":return"function";case"bigint":return"bigint";case"symbol":return"symbol";case"object":return Array.isArray(e)?"array":e===null?"null":e.then&&typeof e.then=="function"&&e.catch&&typeof e.catch=="function"?"promise":typeof Map<"u"&&e instanceof Map?"map":typeof Set<"u"&&e instanceof Set?"set":typeof Date<"u"&&e instanceof Date?"date":typeof File<"u"&&e instanceof File?"file":"object";default:throw new Error(`Unknown data type: ${r}`)}},Nt=new Set(["string","number","symbol"]),No=new Set(["string","number","bigint","boolean","symbol","undefined"]);Eo={safeint:[Number.MIN_SAFE_INTEGER,Number.MAX_SAFE_INTEGER],int32:[-2147483648,2147483647],uint32:[0,4294967295],float32:[-34028234663852886e22,34028234663852886e22],float64:[-Number.MAX_VALUE,Number.MAX_VALUE]},Do={int64:[BigInt("-9223372036854775808"),BigInt("9223372036854775807")],uint64:[BigInt(0),BigInt("18446744073709551615")]};Io=class{constructor(...r){}}});function We(e,r=n=>n.message){let n={},i=[];for(let t of e.issues)t.path.length>0?(n[t.path[0]]=n[t.path[0]]||[],n[t.path[0]].push(r(t))):i.push(r(t));return{formErrors:i,fieldErrors:n}}function Ge(e,r){let n=r||function(o){return o.message},i={_errors:[]},t=o=>{for(let a of o.issues)if(a.code==="invalid_union"&&a.errors.length)a.errors.map(c=>t({issues:c}));else if(a.code==="invalid_key")t({issues:a.issues});else if(a.code==="invalid_element")t({issues:a.issues});else if(a.path.length===0)i._errors.push(n(a));else{let c=i,p=0;for(;p<a.path.length;){let g=a.path[p];p===a.path.length-1?(c[g]=c[g]||{_errors:[]},c[g]._errors.push(n(a))):c[g]=c[g]||{_errors:[]},c=c[g],p++}}};return t(e),i}function wr(e,r){let n=r||function(o){return o.message},i={errors:[]},t=(o,a=[])=>{var c,p;for(let g of o.issues)if(g.code==="invalid_union"&&g.errors.length)g.errors.map(h=>t({issues:h},g.path));else if(g.code==="invalid_key")t({issues:g.issues},g.path);else if(g.code==="invalid_element")t({issues:g.issues},g.path);else{let h=[...a,...g.path];if(h.length===0){i.errors.push(n(g));continue}let m=i,$=0;for(;$<h.length;){let y=h[$],l=$===h.length-1;typeof y=="string"?(m.properties??(m.properties={}),(c=m.properties)[y]??(c[y]={errors:[]}),m=m.properties[y]):(m.items??(m.items=[]),(p=m.items)[y]??(p[y]={errors:[]}),m=m.items[y]),l&&m.errors.push(n(g)),$++}}};return t(e),i}function Vc(e){let r=[];for(let n of e)typeof n=="number"?r.push(`[${n}]`):typeof n=="symbol"?r.push(`[${JSON.stringify(String(n))}]`):/[^\\w$]/.test(n)?r.push(`[${JSON.stringify(n)}]`):(r.length&&r.push("."),r.push(n));return r.join("")}function Ir(e){let r=[],n=[...e.issues].sort((i,t)=>i.path.length-t.path.length);for(let i of n)r.push(`\\u2716 ${i.message}`),i.path?.length&&r.push(` \\u2192 at ${Vc(i.path)}`);return r.join(`\n`)}var Hc,Dt,Ke,Zo=S(()=>{Ve();P();Hc=(e,r)=>{e.name="$ZodError",Object.defineProperty(e,"_zod",{value:e._zod,enumerable:!1}),Object.defineProperty(e,"issues",{value:r,enumerable:!1}),Object.defineProperty(e,"message",{get(){return JSON.stringify(r,jo,2)},enumerable:!0}),Object.defineProperty(e,"toString",{value:()=>e.message,enumerable:!1})},Dt=u("$ZodError",Hc),Ke=u("$ZodError",Hc,{Parent:Error})});var jr,Rt,Pr,Zt,Tr,Qe,Or,At,Nr=S(()=>{Ve();Zo();P();jr=e=>(r,n,i,t)=>{let o=i?Object.assign(i,{async:!1}):{async:!1},a=r._zod.run({value:n,issues:[]},o);if(a instanceof Promise)throw new fe;if(a.issues.length){let c=new(t?.Err??e)(a.issues.map(p=>ce(p,o,K())));throw Sr(c,t?.callee),c}return a.value},Rt=jr(Ke),Pr=e=>async(r,n,i,t)=>{let o=i?Object.assign(i,{async:!0}):{async:!0},a=r._zod.run({value:n,issues:[]},o);if(a instanceof Promise&&(a=await a),a.issues.length){let c=new(t?.Err??e)(a.issues.map(p=>ce(p,o,K())));throw Sr(c,t?.callee),c}return a.value},Zt=Pr(Ke),Tr=e=>(r,n,i)=>{let t=i?{...i,async:!1}:{async:!1},o=r._zod.run({value:n,issues:[]},t);if(o instanceof Promise)throw new fe;return o.issues.length?{success:!1,error:new(e??Dt)(o.issues.map(a=>ce(a,t,K())))}:{success:!0,data:o.value}},Qe=Tr(Ke),Or=e=>async(r,n,i)=>{let t=i?Object.assign(i,{async:!0}):{async:!0},o=r._zod.run({value:n,issues:[]},t);return o instanceof Promise&&(o=await o),o.issues.length?{success:!1,error:new e(o.issues.map(a=>ce(a,t,K())))}:{success:!0,data:o.value}},At=Or(Ke)});var we={};ke(we,{_emoji:()=>Jc,base64:()=>Yo,base64url:()=>Ur,bigint:()=>ii,boolean:()=>ci,browserEmail:()=>im,cidrv4:()=>Go,cidrv6:()=>Qo,cuid:()=>Ao,cuid2:()=>Co,date:()=>ti,datetime:()=>ni,domain:()=>am,duration:()=>Ho,e164:()=>ei,email:()=>Jo,emoji:()=>Bo,extendedDuration:()=>Yp,guid:()=>Vo,hostname:()=>Xo,html5Email:()=>rm,integer:()=>ai,ipv4:()=>Ko,ipv6:()=>Wo,ksuid:()=>qo,lowercase:()=>di,nanoid:()=>Fo,null:()=>ui,number:()=>si,rfc5322Email:()=>nm,string:()=>oi,time:()=>ri,ulid:()=>Lo,undefined:()=>li,unicodeEmail:()=>om,uppercase:()=>pi,uuid:()=>De,uuid4:()=>Xp,uuid6:()=>em,uuid7:()=>tm,xid:()=>Mo});function Bo(){return new RegExp(Jc,"u")}function Kc(e){let r="(?:[01]\\\\d|2[0-3]):[0-5]\\\\d";return typeof e.precision=="number"?e.precision===-1?`${r}`:e.precision===0?`${r}:[0-5]\\\\d`:`${r}:[0-5]\\\\d\\\\.\\\\d{${e.precision}}`:`${r}(?::[0-5]\\\\d(?:\\\\.\\\\d+)?)?`}function ri(e){return new RegExp(`^${Kc(e)}$`)}function ni(e){let r=Kc({precision:e.precision}),n=["Z"];e.local&&n.push(""),e.offset&&n.push("([+-]\\\\d{2}:\\\\d{2})");let i=`${r}(?:${n.join("|")})`;return new RegExp(`^${Bc}T(?:${i})$`)}var Ao,Co,Lo,Mo,qo,Fo,Ho,Yp,Vo,De,Xp,em,tm,Jo,rm,nm,om,im,Jc,Ko,Wo,Go,Qo,Yo,Ur,Xo,am,ei,Bc,ti,oi,ii,ai,si,ci,ui,li,di,pi,Er=S(()=>{Ao=/^[cC][^\\s-]{8,}$/,Co=/^[0-9a-z]+$/,Lo=/^[0-9A-HJKMNP-TV-Za-hjkmnp-tv-z]{26}$/,Mo=/^[0-9a-vA-V]{20}$/,qo=/^[A-Za-z0-9]{27}$/,Fo=/^[a-zA-Z0-9_-]{21}$/,Ho=/^P(?:(\\d+W)|(?!.*W)(?=\\d|T\\d)(\\d+Y)?(\\d+M)?(\\d+D)?(T(?=\\d)(\\d+H)?(\\d+M)?(\\d+([.,]\\d+)?S)?)?)$/,Yp=/^[-+]?P(?!$)(?:(?:[-+]?\\d+Y)|(?:[-+]?\\d+[.,]\\d+Y$))?(?:(?:[-+]?\\d+M)|(?:[-+]?\\d+[.,]\\d+M$))?(?:(?:[-+]?\\d+W)|(?:[-+]?\\d+[.,]\\d+W$))?(?:(?:[-+]?\\d+D)|(?:[-+]?\\d+[.,]\\d+D$))?(?:T(?=[\\d+-])(?:(?:[-+]?\\d+H)|(?:[-+]?\\d+[.,]\\d+H$))?(?:(?:[-+]?\\d+M)|(?:[-+]?\\d+[.,]\\d+M$))?(?:[-+]?\\d+(?:[.,]\\d+)?S)?)??$/,Vo=/^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$/,De=e=>e?new RegExp(`^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-${e}[0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12})$`):/^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000)$/,Xp=De(4),em=De(6),tm=De(7),Jo=/^(?!\\.)(?!.*\\.\\.)([A-Za-z0-9_\'+\\-\\.]*)[A-Za-z0-9_+-]@([A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$/,rm=/^[a-zA-Z0-9.!#$%&\'*+/=?^_`{|}~-]+@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/,nm=/^(([^<>()\\[\\]\\\\.,;:\\s@"]+(\\.[^<>()\\[\\]\\\\.,;:\\s@"]+)*)|(".+"))@((\\[[0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}])|(([a-zA-Z\\-0-9]+\\.)+[a-zA-Z]{2,}))$/,om=/^[^\\s@"]{1,64}@[^\\s@]{1,255}$/u,im=/^[a-zA-Z0-9.!#$%&\'*+/=?^_`{|}~-]+@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/,Jc="^(\\\\p{Extended_Pictographic}|\\\\p{Emoji_Component})+$";Ko=/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])$/,Wo=/^(([0-9a-fA-F]{1,4}:){7}[0-9a-fA-F]{1,4}|::|([0-9a-fA-F]{1,4})?::([0-9a-fA-F]{1,4}:?){0,6})$/,Go=/^((25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\\.){3}(25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\\/([0-9]|[1-2][0-9]|3[0-2])$/,Qo=/^(([0-9a-fA-F]{1,4}:){7}[0-9a-fA-F]{1,4}|::|([0-9a-fA-F]{1,4})?::([0-9a-fA-F]{1,4}:?){0,6})\\/(12[0-8]|1[01][0-9]|[1-9]?[0-9])$/,Yo=/^$|^(?:[0-9a-zA-Z+/]{4})*(?:(?:[0-9a-zA-Z+/]{2}==)|(?:[0-9a-zA-Z+/]{3}=))?$/,Ur=/^[A-Za-z0-9_-]*$/,Xo=/^([a-zA-Z0-9-]+\\.)*[a-zA-Z0-9-]+$/,am=/^([a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?\\.)+[a-zA-Z]{2,}$/,ei=/^\\+(?:[0-9]){6,14}[0-9]$/,Bc="(?:(?:\\\\d\\\\d[2468][048]|\\\\d\\\\d[13579][26]|\\\\d\\\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\\\d|30)|(?:02)-(?:0[1-9]|1\\\\d|2[0-8])))",ti=new RegExp(`^${Bc}$`);oi=e=>{let r=e?`[\\\\s\\\\S]{${e?.minimum??0},${e?.maximum??""}}`:"[\\\\s\\\\S]*";return new RegExp(`^${r}$`)},ii=/^\\d+n?$/,ai=/^\\d+$/,si=/^-?\\d+(?:\\.\\d+)?/i,ci=/true|false/i,ui=/null/i,li=/undefined/i,di=/^[^A-Z]*$/,pi=/^[^a-z]*$/});function Wc(e,r,n){e.issues.length&&r.issues.push(...ae(n,e.issues))}var J,Gc,Dr,Rr,mi,fi,gi,hi,vi,bi,yi,_i,xi,Ye,$i,zi,ki,Si,wi,Ii,ji,Pi,Ti,Zr=S(()=>{Ve();Er();P();J=u("$ZodCheck",(e,r)=>{var n;e._zod??(e._zod={}),e._zod.def=r,(n=e._zod).onattach??(n.onattach=[])}),Gc={number:"number",bigint:"bigint",object:"date"},Dr=u("$ZodCheckLessThan",(e,r)=>{J.init(e,r);let n=Gc[typeof r.value];e._zod.onattach.push(i=>{let t=i._zod.bag,o=(r.inclusive?t.maximum:t.exclusiveMaximum)??Number.POSITIVE_INFINITY;r.value<o&&(r.inclusive?t.maximum=r.value:t.exclusiveMaximum=r.value)}),e._zod.check=i=>{(r.inclusive?i.value<=r.value:i.value<r.value)||i.issues.push({origin:n,code:"too_big",maximum:r.value,input:i.value,inclusive:r.inclusive,inst:e,continue:!r.abort})}}),Rr=u("$ZodCheckGreaterThan",(e,r)=>{J.init(e,r);let n=Gc[typeof r.value];e._zod.onattach.push(i=>{let t=i._zod.bag,o=(r.inclusive?t.minimum:t.exclusiveMinimum)??Number.NEGATIVE_INFINITY;r.value>o&&(r.inclusive?t.minimum=r.value:t.exclusiveMinimum=r.value)}),e._zod.check=i=>{(r.inclusive?i.value>=r.value:i.value>r.value)||i.issues.push({origin:n,code:"too_small",minimum:r.value,input:i.value,inclusive:r.inclusive,inst:e,continue:!r.abort})}}),mi=u("$ZodCheckMultipleOf",(e,r)=>{J.init(e,r),e._zod.onattach.push(n=>{var i;(i=n._zod.bag).multipleOf??(i.multipleOf=r.value)}),e._zod.check=n=>{if(typeof n.value!=typeof r.value)throw new Error("Cannot mix number and bigint in multiple_of check.");(typeof n.value=="bigint"?n.value%r.value===BigInt(0):Po(n.value,r.value)===0)||n.issues.push({origin:typeof n.value,code:"not_multiple_of",divisor:r.value,input:n.value,inst:e,continue:!r.abort})}}),fi=u("$ZodCheckNumberFormat",(e,r)=>{J.init(e,r),r.format=r.format||"float64";let n=r.format?.includes("int"),i=n?"int":"number",[t,o]=Eo[r.format];e._zod.onattach.push(a=>{let c=a._zod.bag;c.format=r.format,c.minimum=t,c.maximum=o,n&&(c.pattern=ai)}),e._zod.check=a=>{let c=a.value;if(n){if(!Number.isInteger(c)){a.issues.push({expected:i,format:r.format,code:"invalid_type",input:c,inst:e});return}if(!Number.isSafeInteger(c)){c>0?a.issues.push({input:c,code:"too_big",maximum:Number.MAX_SAFE_INTEGER,note:"Integers must be within the safe integer range.",inst:e,origin:i,continue:!r.abort}):a.issues.push({input:c,code:"too_small",minimum:Number.MIN_SAFE_INTEGER,note:"Integers must be within the safe integer range.",inst:e,origin:i,continue:!r.abort});return}}c<t&&a.issues.push({origin:"number",input:c,code:"too_small",minimum:t,inclusive:!0,inst:e,continue:!r.abort}),c>o&&a.issues.push({origin:"number",input:c,code:"too_big",maximum:o,inst:e})}}),gi=u("$ZodCheckBigIntFormat",(e,r)=>{J.init(e,r);let[n,i]=Do[r.format];e._zod.onattach.push(t=>{let o=t._zod.bag;o.format=r.format,o.minimum=n,o.maximum=i}),e._zod.check=t=>{let o=t.value;o<n&&t.issues.push({origin:"bigint",input:o,code:"too_small",minimum:n,inclusive:!0,inst:e,continue:!r.abort}),o>i&&t.issues.push({origin:"bigint",input:o,code:"too_big",maximum:i,inst:e})}}),hi=u("$ZodCheckMaxSize",(e,r)=>{var n;J.init(e,r),(n=e._zod.def).when??(n.when=i=>{let t=i.value;return!Se(t)&&t.size!==void 0}),e._zod.onattach.push(i=>{let t=i._zod.bag.maximum??Number.POSITIVE_INFINITY;r.maximum<t&&(i._zod.bag.maximum=r.maximum)}),e._zod.check=i=>{let t=i.value;t.size<=r.maximum||i.issues.push({origin:Ut(t),code:"too_big",maximum:r.maximum,input:t,inst:e,continue:!r.abort})}}),vi=u("$ZodCheckMinSize",(e,r)=>{var n;J.init(e,r),(n=e._zod.def).when??(n.when=i=>{let t=i.value;return!Se(t)&&t.size!==void 0}),e._zod.onattach.push(i=>{let t=i._zod.bag.minimum??Number.NEGATIVE_INFINITY;r.minimum>t&&(i._zod.bag.minimum=r.minimum)}),e._zod.check=i=>{let t=i.value;t.size>=r.minimum||i.issues.push({origin:Ut(t),code:"too_small",minimum:r.minimum,input:t,inst:e,continue:!r.abort})}}),bi=u("$ZodCheckSizeEquals",(e,r)=>{var n;J.init(e,r),(n=e._zod.def).when??(n.when=i=>{let t=i.value;return!Se(t)&&t.size!==void 0}),e._zod.onattach.push(i=>{let t=i._zod.bag;t.minimum=r.size,t.maximum=r.size,t.size=r.size}),e._zod.check=i=>{let t=i.value,o=t.size;if(o===r.size)return;let a=o>r.size;i.issues.push({origin:Ut(t),...a?{code:"too_big",maximum:r.size}:{code:"too_small",minimum:r.size},inclusive:!0,exact:!0,input:i.value,inst:e,continue:!r.abort})}}),yi=u("$ZodCheckMaxLength",(e,r)=>{var n;J.init(e,r),(n=e._zod.def).when??(n.when=i=>{let t=i.value;return!Se(t)&&t.length!==void 0}),e._zod.onattach.push(i=>{let t=i._zod.bag.maximum??Number.POSITIVE_INFINITY;r.maximum<t&&(i._zod.bag.maximum=r.maximum)}),e._zod.check=i=>{let t=i.value;if(t.length<=r.maximum)return;let a=Et(t);i.issues.push({origin:a,code:"too_big",maximum:r.maximum,inclusive:!0,input:t,inst:e,continue:!r.abort})}}),_i=u("$ZodCheckMinLength",(e,r)=>{var n;J.init(e,r),(n=e._zod.def).when??(n.when=i=>{let t=i.value;return!Se(t)&&t.length!==void 0}),e._zod.onattach.push(i=>{let t=i._zod.bag.minimum??Number.NEGATIVE_INFINITY;r.minimum>t&&(i._zod.bag.minimum=r.minimum)}),e._zod.check=i=>{let t=i.value;if(t.length>=r.minimum)return;let a=Et(t);i.issues.push({origin:a,code:"too_small",minimum:r.minimum,inclusive:!0,input:t,inst:e,continue:!r.abort})}}),xi=u("$ZodCheckLengthEquals",(e,r)=>{var n;J.init(e,r),(n=e._zod.def).when??(n.when=i=>{let t=i.value;return!Se(t)&&t.length!==void 0}),e._zod.onattach.push(i=>{let t=i._zod.bag;t.minimum=r.length,t.maximum=r.length,t.length=r.length}),e._zod.check=i=>{let t=i.value,o=t.length;if(o===r.length)return;let a=Et(t),c=o>r.length;i.issues.push({origin:a,...c?{code:"too_big",maximum:r.length}:{code:"too_small",minimum:r.length},inclusive:!0,exact:!0,input:i.value,inst:e,continue:!r.abort})}}),Ye=u("$ZodCheckStringFormat",(e,r)=>{var n,i;J.init(e,r),e._zod.onattach.push(t=>{let o=t._zod.bag;o.format=r.format,r.pattern&&(o.patterns??(o.patterns=new Set),o.patterns.add(r.pattern))}),r.pattern?(n=e._zod).check??(n.check=t=>{r.pattern.lastIndex=0,!r.pattern.test(t.value)&&t.issues.push({origin:"string",code:"invalid_format",format:r.format,input:t.value,...r.pattern?{pattern:r.pattern.toString()}:{},inst:e,continue:!r.abort})}):(i=e._zod).check??(i.check=()=>{})}),$i=u("$ZodCheckRegex",(e,r)=>{Ye.init(e,r),e._zod.check=n=>{r.pattern.lastIndex=0,!r.pattern.test(n.value)&&n.issues.push({origin:"string",code:"invalid_format",format:"regex",input:n.value,pattern:r.pattern.toString(),inst:e,continue:!r.abort})}}),zi=u("$ZodCheckLowerCase",(e,r)=>{r.pattern??(r.pattern=di),Ye.init(e,r)}),ki=u("$ZodCheckUpperCase",(e,r)=>{r.pattern??(r.pattern=pi),Ye.init(e,r)}),Si=u("$ZodCheckIncludes",(e,r)=>{J.init(e,r);let n=_e(r.includes),i=new RegExp(typeof r.position=="number"?`^.{${r.position}}${n}`:n);r.pattern=i,e._zod.onattach.push(t=>{let o=t._zod.bag;o.patterns??(o.patterns=new Set),o.patterns.add(i)}),e._zod.check=t=>{t.value.includes(r.includes,r.position)||t.issues.push({origin:"string",code:"invalid_format",format:"includes",includes:r.includes,input:t.value,inst:e,continue:!r.abort})}}),wi=u("$ZodCheckStartsWith",(e,r)=>{J.init(e,r);let n=new RegExp(`^${_e(r.prefix)}.*`);r.pattern??(r.pattern=n),e._zod.onattach.push(i=>{let t=i._zod.bag;t.patterns??(t.patterns=new Set),t.patterns.add(n)}),e._zod.check=i=>{i.value.startsWith(r.prefix)||i.issues.push({origin:"string",code:"invalid_format",format:"starts_with",prefix:r.prefix,input:i.value,inst:e,continue:!r.abort})}}),Ii=u("$ZodCheckEndsWith",(e,r)=>{J.init(e,r);let n=new RegExp(`.*${_e(r.suffix)}$`);r.pattern??(r.pattern=n),e._zod.onattach.push(i=>{let t=i._zod.bag;t.patterns??(t.patterns=new Set),t.patterns.add(n)}),e._zod.check=i=>{i.value.endsWith(r.suffix)||i.issues.push({origin:"string",code:"invalid_format",format:"ends_with",suffix:r.suffix,input:i.value,inst:e,continue:!r.abort})}});ji=u("$ZodCheckProperty",(e,r)=>{J.init(e,r),e._zod.check=n=>{let i=r.schema._zod.run({value:n.value[r.property],issues:[]},{});if(i instanceof Promise)return i.then(t=>Wc(t,n,r.property));Wc(i,n,r.property)}}),Pi=u("$ZodCheckMimeType",(e,r)=>{J.init(e,r);let n=new Set(r.mime);e._zod.onattach.push(i=>{i._zod.bag.mime=r.mime}),e._zod.check=i=>{n.has(i.value.type)||i.issues.push({code:"invalid_value",values:r.mime,input:i.value.type,inst:e})}}),Ti=u("$ZodCheckOverwrite",(e,r)=>{J.init(e,r),e._zod.check=n=>{n.value=r.tx(n.value)}})});var Ct,Oi=S(()=>{Ct=class{constructor(r=[]){this.content=[],this.indent=0,this&&(this.args=r)}indented(r){this.indent+=1,r(this),this.indent-=1}write(r){if(typeof r=="function"){r(this,{execution:"sync"}),r(this,{execution:"async"});return}let i=r.split(`\n`).filter(a=>a),t=Math.min(...i.map(a=>a.length-a.trimStart().length)),o=i.map(a=>a.slice(t)).map(a=>" ".repeat(this.indent*2)+a);for(let a of o)this.content.push(a)}compile(){let r=Function,n=this?.args,t=[...(this?.content??[""]).map(o=>` ${o}`)];return new r(...n,t.join(`\n`))}}});var Ni,Ui=S(()=>{Ni={major:4,minor:0,patch:0}});function ea(e){if(e==="")return!0;if(e.length%4!==0)return!1;try{return atob(e),!0}catch{return!1}}function uu(e){if(!Ur.test(e))return!1;let r=e.replace(/[-_]/g,i=>i==="-"?"+":"/"),n=r.padEnd(Math.ceil(r.length/4)*4,"=");return ea(n)}function lu(e,r=null){try{let n=e.split(".");if(n.length!==3)return!1;let[i]=n;if(!i)return!1;let t=JSON.parse(atob(i));return!("typ"in t&&t?.typ!=="JWT"||!t.alg||r&&(!("alg"in t)||t.alg!==r))}catch{return!1}}function Yc(e,r,n){e.issues.length&&r.issues.push(...ae(n,e.issues)),r.value[n]=e.value}function Ar(e,r,n){e.issues.length&&r.issues.push(...ae(n,e.issues)),r.value[n]=e.value}function Xc(e,r,n,i){e.issues.length?i[n]===void 0?n in i?r.value[n]=void 0:r.value[n]=e.value:r.issues.push(...ae(n,e.issues)):e.value===void 0?n in i&&(r.value[n]=void 0):r.value[n]=e.value}function eu(e,r,n,i){for(let t of e)if(t.issues.length===0)return r.value=t.value,r;return r.issues.push({code:"invalid_union",input:r.value,inst:n,errors:e.map(t=>t.issues.map(o=>ce(o,i,K())))}),r}function Ei(e,r){if(e===r)return{valid:!0,data:e};if(e instanceof Date&&r instanceof Date&&+e==+r)return{valid:!0,data:e};if(Be(e)&&Be(r)){let n=Object.keys(r),i=Object.keys(e).filter(o=>n.indexOf(o)!==-1),t={...e,...r};for(let o of i){let a=Ei(e[o],r[o]);if(!a.valid)return{valid:!1,mergeErrorPath:[o,...a.mergeErrorPath]};t[o]=a.data}return{valid:!0,data:t}}if(Array.isArray(e)&&Array.isArray(r)){if(e.length!==r.length)return{valid:!1,mergeErrorPath:[]};let n=[];for(let i=0;i<e.length;i++){let t=e[i],o=r[i],a=Ei(t,o);if(!a.valid)return{valid:!1,mergeErrorPath:[i,...a.mergeErrorPath]};n.push(a.data)}return{valid:!0,data:n}}return{valid:!1,mergeErrorPath:[]}}function tu(e,r,n){if(r.issues.length&&e.issues.push(...r.issues),n.issues.length&&e.issues.push(...n.issues),Ee(e))return e;let i=Ei(r.value,n.value);if(!i.valid)throw new Error(`Unmergable intersection. Error path: ${JSON.stringify(i.mergeErrorPath)}`);return e.value=i.data,e}function Cr(e,r,n){e.issues.length&&r.issues.push(...ae(n,e.issues)),r.value[n]=e.value}function ru(e,r,n,i,t,o,a){e.issues.length&&(Nt.has(typeof i)?n.issues.push(...ae(i,e.issues)):n.issues.push({origin:"map",code:"invalid_key",input:t,inst:o,issues:e.issues.map(c=>ce(c,a,K()))})),r.issues.length&&(Nt.has(typeof i)?n.issues.push(...ae(i,r.issues)):n.issues.push({origin:"map",code:"invalid_element",input:t,inst:o,key:i,issues:r.issues.map(c=>ce(c,a,K()))})),n.value.set(e.value,r.value)}function nu(e,r){e.issues.length&&r.issues.push(...e.issues),r.value.add(e.value)}function ou(e,r){return e.value===void 0&&(e.value=r.defaultValue),e}function iu(e,r){return!e.issues.length&&e.value===void 0&&e.issues.push({code:"invalid_type",expected:"nonoptional",input:e.value,inst:r}),e}function au(e,r,n){return Ee(e)?e:r.out._zod.run({value:e.value,issues:e.issues},n)}function su(e){return e.value=Object.freeze(e.value),e}function cu(e,r,n,i){if(!e){let t={code:"custom",input:n,inst:i,path:[...i._zod.def.path??[]],continue:!i._zod.def.abort};i._zod.def.params&&(t.params=i._zod.def.params),r.issues.push(Ro(t))}}var T,Re,q,Di,Ri,Zi,Ai,Ci,Li,Mi,qi,Fi,Hi,Vi,Ji,Bi,Ki,Wi,Gi,Qi,Yi,Xi,ta,ra,na,oa,ia,Lr,aa,Lt,Mr,sa,ca,ua,la,da,Xe,pa,ma,fa,Mt,ga,qr,ha,va,Ze,ba,ya,_a,xa,$a,za,qt,ka,Sa,wa,Ia,ja,Pa,Ta,Oa,Ft,Na,Ua,Ea,Da,Ra,Ht=S(()=>{Zr();Ve();Oi();Nr();Er();P();Ui();P();T=u("$ZodType",(e,r)=>{var n;e??(e={}),e._zod.def=r,e._zod.bag=e._zod.bag||{},e._zod.version=Ni;let i=[...e._zod.def.checks??[]];e._zod.traits.has("$ZodCheck")&&i.unshift(e);for(let t of i)for(let o of t._zod.onattach)o(e);if(i.length===0)(n=e._zod).deferred??(n.deferred=[]),e._zod.deferred?.push(()=>{e._zod.run=e._zod.parse});else{let t=(o,a,c)=>{let p=Ee(o),g;for(let h of a){if(h._zod.def.when){if(!h._zod.def.when(o))continue}else if(p)continue;let m=o.issues.length,$=h._zod.check(o);if($ instanceof Promise&&c?.async===!1)throw new fe;if(g||$ instanceof Promise)g=(g??Promise.resolve()).then(async()=>{await $,o.issues.length!==m&&(p||(p=Ee(o,m)))});else{if(o.issues.length===m)continue;p||(p=Ee(o,m))}}return g?g.then(()=>o):o};e._zod.run=(o,a)=>{let c=e._zod.parse(o,a);if(c instanceof Promise){if(a.async===!1)throw new fe;return c.then(p=>t(p,i,a))}return t(c,i,a)}}e["~standard"]={validate:t=>{try{let o=Qe(e,t);return o.success?{value:o.data}:{issues:o.error?.issues}}catch{return At(e,t).then(a=>a.success?{value:a.data}:{issues:a.error?.issues})}},vendor:"zod",version:1}}),Re=u("$ZodString",(e,r)=>{T.init(e,r),e._zod.pattern=[...e?._zod.bag?.patterns??[]].pop()??oi(e._zod.bag),e._zod.parse=(n,i)=>{if(r.coerce)try{n.value=String(n.value)}catch{}return typeof n.value=="string"||n.issues.push({expected:"string",code:"invalid_type",input:n.value,inst:e}),n}}),q=u("$ZodStringFormat",(e,r)=>{Ye.init(e,r),Re.init(e,r)}),Di=u("$ZodGUID",(e,r)=>{r.pattern??(r.pattern=Vo),q.init(e,r)}),Ri=u("$ZodUUID",(e,r)=>{if(r.version){let i={v1:1,v2:2,v3:3,v4:4,v5:5,v6:6,v7:7,v8:8}[r.version];if(i===void 0)throw new Error(`Invalid UUID version: "${r.version}"`);r.pattern??(r.pattern=De(i))}else r.pattern??(r.pattern=De());q.init(e,r)}),Zi=u("$ZodEmail",(e,r)=>{r.pattern??(r.pattern=Jo),q.init(e,r)}),Ai=u("$ZodURL",(e,r)=>{q.init(e,r),e._zod.check=n=>{try{let i=n.value,t=new URL(i),o=t.href;r.hostname&&(r.hostname.lastIndex=0,r.hostname.test(t.hostname)||n.issues.push({code:"invalid_format",format:"url",note:"Invalid hostname",pattern:Xo.source,input:n.value,inst:e,continue:!r.abort})),r.protocol&&(r.protocol.lastIndex=0,r.protocol.test(t.protocol.endsWith(":")?t.protocol.slice(0,-1):t.protocol)||n.issues.push({code:"invalid_format",format:"url",note:"Invalid protocol",pattern:r.protocol.source,input:n.value,inst:e,continue:!r.abort})),!i.endsWith("/")&&o.endsWith("/")?n.value=o.slice(0,-1):n.value=o;return}catch{n.issues.push({code:"invalid_format",format:"url",input:n.value,inst:e,continue:!r.abort})}}}),Ci=u("$ZodEmoji",(e,r)=>{r.pattern??(r.pattern=Bo()),q.init(e,r)}),Li=u("$ZodNanoID",(e,r)=>{r.pattern??(r.pattern=Fo),q.init(e,r)}),Mi=u("$ZodCUID",(e,r)=>{r.pattern??(r.pattern=Ao),q.init(e,r)}),qi=u("$ZodCUID2",(e,r)=>{r.pattern??(r.pattern=Co),q.init(e,r)}),Fi=u("$ZodULID",(e,r)=>{r.pattern??(r.pattern=Lo),q.init(e,r)}),Hi=u("$ZodXID",(e,r)=>{r.pattern??(r.pattern=Mo),q.init(e,r)}),Vi=u("$ZodKSUID",(e,r)=>{r.pattern??(r.pattern=qo),q.init(e,r)}),Ji=u("$ZodISODateTime",(e,r)=>{r.pattern??(r.pattern=ni(r)),q.init(e,r)}),Bi=u("$ZodISODate",(e,r)=>{r.pattern??(r.pattern=ti),q.init(e,r)}),Ki=u("$ZodISOTime",(e,r)=>{r.pattern??(r.pattern=ri(r)),q.init(e,r)}),Wi=u("$ZodISODuration",(e,r)=>{r.pattern??(r.pattern=Ho),q.init(e,r)}),Gi=u("$ZodIPv4",(e,r)=>{r.pattern??(r.pattern=Ko),q.init(e,r),e._zod.onattach.push(n=>{let i=n._zod.bag;i.format="ipv4"})}),Qi=u("$ZodIPv6",(e,r)=>{r.pattern??(r.pattern=Wo),q.init(e,r),e._zod.onattach.push(n=>{let i=n._zod.bag;i.format="ipv6"}),e._zod.check=n=>{try{new URL(`http://[${n.value}]`)}catch{n.issues.push({code:"invalid_format",format:"ipv6",input:n.value,inst:e,continue:!r.abort})}}}),Yi=u("$ZodCIDRv4",(e,r)=>{r.pattern??(r.pattern=Go),q.init(e,r)}),Xi=u("$ZodCIDRv6",(e,r)=>{r.pattern??(r.pattern=Qo),q.init(e,r),e._zod.check=n=>{let[i,t]=n.value.split("/");try{if(!t)throw new Error;let o=Number(t);if(`${o}`!==t)throw new Error;if(o<0||o>128)throw new Error;new URL(`http://[${i}]`)}catch{n.issues.push({code:"invalid_format",format:"cidrv6",input:n.value,inst:e,continue:!r.abort})}}});ta=u("$ZodBase64",(e,r)=>{r.pattern??(r.pattern=Yo),q.init(e,r),e._zod.onattach.push(n=>{n._zod.bag.contentEncoding="base64"}),e._zod.check=n=>{ea(n.value)||n.issues.push({code:"invalid_format",format:"base64",input:n.value,inst:e,continue:!r.abort})}});ra=u("$ZodBase64URL",(e,r)=>{r.pattern??(r.pattern=Ur),q.init(e,r),e._zod.onattach.push(n=>{n._zod.bag.contentEncoding="base64url"}),e._zod.check=n=>{uu(n.value)||n.issues.push({code:"invalid_format",format:"base64url",input:n.value,inst:e,continue:!r.abort})}}),na=u("$ZodE164",(e,r)=>{r.pattern??(r.pattern=ei),q.init(e,r)});oa=u("$ZodJWT",(e,r)=>{q.init(e,r),e._zod.check=n=>{lu(n.value,r.alg)||n.issues.push({code:"invalid_format",format:"jwt",input:n.value,inst:e,continue:!r.abort})}}),ia=u("$ZodCustomStringFormat",(e,r)=>{q.init(e,r),e._zod.check=n=>{r.fn(n.value)||n.issues.push({code:"invalid_format",format:r.format,input:n.value,inst:e,continue:!r.abort})}}),Lr=u("$ZodNumber",(e,r)=>{T.init(e,r),e._zod.pattern=e._zod.bag.pattern??si,e._zod.parse=(n,i)=>{if(r.coerce)try{n.value=Number(n.value)}catch{}let t=n.value;if(typeof t=="number"&&!Number.isNaN(t)&&Number.isFinite(t))return n;let o=typeof t=="number"?Number.isNaN(t)?"NaN":Number.isFinite(t)?void 0:"Infinity":void 0;return n.issues.push({expected:"number",code:"invalid_type",input:t,inst:e,...o?{received:o}:{}}),n}}),aa=u("$ZodNumber",(e,r)=>{fi.init(e,r),Lr.init(e,r)}),Lt=u("$ZodBoolean",(e,r)=>{T.init(e,r),e._zod.pattern=ci,e._zod.parse=(n,i)=>{if(r.coerce)try{n.value=!!n.value}catch{}let t=n.value;return typeof t=="boolean"||n.issues.push({expected:"boolean",code:"invalid_type",input:t,inst:e}),n}}),Mr=u("$ZodBigInt",(e,r)=>{T.init(e,r),e._zod.pattern=ii,e._zod.parse=(n,i)=>{if(r.coerce)try{n.value=BigInt(n.value)}catch{}return typeof n.value=="bigint"||n.issues.push({expected:"bigint",code:"invalid_type",input:n.value,inst:e}),n}}),sa=u("$ZodBigInt",(e,r)=>{gi.init(e,r),Mr.init(e,r)}),ca=u("$ZodSymbol",(e,r)=>{T.init(e,r),e._zod.parse=(n,i)=>{let t=n.value;return typeof t=="symbol"||n.issues.push({expected:"symbol",code:"invalid_type",input:t,inst:e}),n}}),ua=u("$ZodUndefined",(e,r)=>{T.init(e,r),e._zod.pattern=li,e._zod.values=new Set([void 0]),e._zod.optin="optional",e._zod.optout="optional",e._zod.parse=(n,i)=>{let t=n.value;return typeof t>"u"||n.issues.push({expected:"undefined",code:"invalid_type",input:t,inst:e}),n}}),la=u("$ZodNull",(e,r)=>{T.init(e,r),e._zod.pattern=ui,e._zod.values=new Set([null]),e._zod.parse=(n,i)=>{let t=n.value;return t===null||n.issues.push({expected:"null",code:"invalid_type",input:t,inst:e}),n}}),da=u("$ZodAny",(e,r)=>{T.init(e,r),e._zod.parse=n=>n}),Xe=u("$ZodUnknown",(e,r)=>{T.init(e,r),e._zod.parse=n=>n}),pa=u("$ZodNever",(e,r)=>{T.init(e,r),e._zod.parse=(n,i)=>(n.issues.push({expected:"never",code:"invalid_type",input:n.value,inst:e}),n)}),ma=u("$ZodVoid",(e,r)=>{T.init(e,r),e._zod.parse=(n,i)=>{let t=n.value;return typeof t>"u"||n.issues.push({expected:"void",code:"invalid_type",input:t,inst:e}),n}}),fa=u("$ZodDate",(e,r)=>{T.init(e,r),e._zod.parse=(n,i)=>{if(r.coerce)try{n.value=new Date(n.value)}catch{}let t=n.value,o=t instanceof Date;return o&&!Number.isNaN(t.getTime())||n.issues.push({expected:"date",code:"invalid_type",input:t,...o?{received:"Invalid Date"}:{},inst:e}),n}});Mt=u("$ZodArray",(e,r)=>{T.init(e,r),e._zod.parse=(n,i)=>{let t=n.value;if(!Array.isArray(t))return n.issues.push({expected:"array",code:"invalid_type",input:t,inst:e}),n;n.value=Array(t.length);let o=[];for(let a=0;a<t.length;a++){let c=t[a],p=r.element._zod.run({value:c,issues:[]},i);p instanceof Promise?o.push(p.then(g=>Yc(g,n,a))):Yc(p,n,a)}return o.length?Promise.all(o).then(()=>n):n}});ga=u("$ZodObject",(e,r)=>{T.init(e,r);let n=Tt(()=>{let m=Object.keys(r.shape);for(let y of m)if(!(r.shape[y]instanceof T))throw new Error(`Invalid element at key "${y}": expected a Zod schema`);let $=Uo(r.shape);return{shape:r.shape,keys:m,keySet:new Set(m),numKeys:m.length,optionalKeys:new Set($)}});A(e._zod,"propValues",()=>{let m=r.shape,$={};for(let y in m){let l=m[y]._zod;if(l.values){$[y]??($[y]=new Set);for(let v of l.values)$[y].add(v)}}return $});let i=m=>{let $=new Ct(["shape","payload","ctx"]),y=n.value,l=w=>{let j=Ue(w);return`shape[${j}]._zod.run({ value: input[${j}], issues: [] }, ctx)`};$.write("const input = payload.value;");let v=Object.create(null),k=0;for(let w of y.keys)v[w]=`key_${k++}`;$.write("const newResult = {}");for(let w of y.keys)if(y.optionalKeys.has(w)){let j=v[w];$.write(`const ${j} = ${l(w)};`);let D=Ue(w);$.write(`\n if (${j}.issues.length) {\n if (input[${D}] === undefined) {\n if (${D} in input) {\n newResult[${D}] = undefined;\n }\n } else {\n payload.issues = payload.issues.concat(\n ${j}.issues.map((iss) => ({\n ...iss,\n path: iss.path ? [${D}, ...iss.path] : [${D}],\n }))\n );\n }\n } else if (${j}.value === undefined) {\n if (${D} in input) newResult[${D}] = undefined;\n } else {\n newResult[${D}] = ${j}.value;\n }\n `)}else{let j=v[w];$.write(`const ${j} = ${l(w)};`),$.write(`\n if (${j}.issues.length) payload.issues = payload.issues.concat(${j}.issues.map(iss => ({\n ...iss,\n path: iss.path ? [${Ue(w)}, ...iss.path] : [${Ue(w)}]\n })));`),$.write(`newResult[${Ue(w)}] = ${j}.value`)}$.write("payload.value = newResult;"),$.write("return payload;");let E=$.compile();return(w,j)=>E(m,w,j)},t,o=Je,a=!It.jitless,p=a&&Oo.value,g=r.catchall,h;e._zod.parse=(m,$)=>{h??(h=n.value);let y=m.value;if(!o(y))return m.issues.push({expected:"object",code:"invalid_type",input:y,inst:e}),m;let l=[];if(a&&p&&$?.async===!1&&$.jitless!==!0)t||(t=i(r.shape)),m=t(m,$);else{m.value={};let j=h.shape;for(let D of h.keys){let Oe=j[D],$r=Oe._zod.run({value:y[D],issues:[]},$),qc=Oe._zod.optin==="optional"&&Oe._zod.optout==="optional";$r instanceof Promise?l.push($r.then(Fc=>qc?Xc(Fc,m,D,y):Ar(Fc,m,D))):qc?Xc($r,m,D,y):Ar($r,m,D)}}if(!g)return l.length?Promise.all(l).then(()=>m):m;let v=[],k=h.keySet,E=g._zod,w=E.def.type;for(let j of Object.keys(y)){if(k.has(j))continue;if(w==="never"){v.push(j);continue}let D=E.run({value:y[j],issues:[]},$);D instanceof Promise?l.push(D.then(Oe=>Ar(Oe,m,j))):Ar(D,m,j)}return v.length&&m.issues.push({code:"unrecognized_keys",keys:v,input:y,inst:e}),l.length?Promise.all(l).then(()=>m):m}});qr=u("$ZodUnion",(e,r)=>{T.init(e,r),A(e._zod,"optin",()=>r.options.some(n=>n._zod.optin==="optional")?"optional":void 0),A(e._zod,"optout",()=>r.options.some(n=>n._zod.optout==="optional")?"optional":void 0),A(e._zod,"values",()=>{if(r.options.every(n=>n._zod.values))return new Set(r.options.flatMap(n=>Array.from(n._zod.values)))}),A(e._zod,"pattern",()=>{if(r.options.every(n=>n._zod.pattern)){let n=r.options.map(i=>i._zod.pattern);return new RegExp(`^(${n.map(i=>Ot(i.source)).join("|")})$`)}}),e._zod.parse=(n,i)=>{let t=!1,o=[];for(let a of r.options){let c=a._zod.run({value:n.value,issues:[]},i);if(c instanceof Promise)o.push(c),t=!0;else{if(c.issues.length===0)return c;o.push(c)}}return t?Promise.all(o).then(a=>eu(a,n,e,i)):eu(o,n,e,i)}}),ha=u("$ZodDiscriminatedUnion",(e,r)=>{qr.init(e,r);let n=e._zod.parse;A(e._zod,"propValues",()=>{let t={};for(let o of r.options){let a=o._zod.propValues;if(!a||Object.keys(a).length===0)throw new Error(`Invalid discriminated union option at index "${r.options.indexOf(o)}"`);for(let[c,p]of Object.entries(a)){t[c]||(t[c]=new Set);for(let g of p)t[c].add(g)}}return t});let i=Tt(()=>{let t=r.options,o=new Map;for(let a of t){let c=a._zod.propValues[r.discriminator];if(!c||c.size===0)throw new Error(`Invalid discriminated union option at index "${r.options.indexOf(a)}"`);for(let p of c){if(o.has(p))throw new Error(`Duplicate discriminator value "${String(p)}"`);o.set(p,a)}}return o});e._zod.parse=(t,o)=>{let a=t.value;if(!Je(a))return t.issues.push({code:"invalid_type",expected:"object",input:a,inst:e}),t;let c=i.value.get(a?.[r.discriminator]);return c?c._zod.run(t,o):r.unionFallback?n(t,o):(t.issues.push({code:"invalid_union",errors:[],note:"No matching discriminator",input:a,path:[r.discriminator],inst:e}),t)}}),va=u("$ZodIntersection",(e,r)=>{T.init(e,r),e._zod.parse=(n,i)=>{let t=n.value,o=r.left._zod.run({value:t,issues:[]},i),a=r.right._zod.run({value:t,issues:[]},i);return o instanceof Promise||a instanceof Promise?Promise.all([o,a]).then(([p,g])=>tu(n,p,g)):tu(n,o,a)}});Ze=u("$ZodTuple",(e,r)=>{T.init(e,r);let n=r.items,i=n.length-[...n].reverse().findIndex(t=>t._zod.optin!=="optional");e._zod.parse=(t,o)=>{let a=t.value;if(!Array.isArray(a))return t.issues.push({input:a,inst:e,expected:"tuple",code:"invalid_type"}),t;t.value=[];let c=[];if(!r.rest){let g=a.length>n.length,h=a.length<i-1;if(g||h)return t.issues.push({input:a,inst:e,origin:"array",...g?{code:"too_big",maximum:n.length}:{code:"too_small",minimum:n.length}}),t}let p=-1;for(let g of n){if(p++,p>=a.length&&p>=i)continue;let h=g._zod.run({value:a[p],issues:[]},o);h instanceof Promise?c.push(h.then(m=>Cr(m,t,p))):Cr(h,t,p)}if(r.rest){let g=a.slice(n.length);for(let h of g){p++;let m=r.rest._zod.run({value:h,issues:[]},o);m instanceof Promise?c.push(m.then($=>Cr($,t,p))):Cr(m,t,p)}}return c.length?Promise.all(c).then(()=>t):t}});ba=u("$ZodRecord",(e,r)=>{T.init(e,r),e._zod.parse=(n,i)=>{let t=n.value;if(!Be(t))return n.issues.push({expected:"record",code:"invalid_type",input:t,inst:e}),n;let o=[];if(r.keyType._zod.values){let a=r.keyType._zod.values;n.value={};for(let p of a)if(typeof p=="string"||typeof p=="number"||typeof p=="symbol"){let g=r.valueType._zod.run({value:t[p],issues:[]},i);g instanceof Promise?o.push(g.then(h=>{h.issues.length&&n.issues.push(...ae(p,h.issues)),n.value[p]=h.value})):(g.issues.length&&n.issues.push(...ae(p,g.issues)),n.value[p]=g.value)}let c;for(let p in t)a.has(p)||(c=c??[],c.push(p));c&&c.length>0&&n.issues.push({code:"unrecognized_keys",input:t,inst:e,keys:c})}else{n.value={};for(let a of Reflect.ownKeys(t)){if(a==="__proto__")continue;let c=r.keyType._zod.run({value:a,issues:[]},i);if(c instanceof Promise)throw new Error("Async schemas not supported in object keys currently");if(c.issues.length){n.issues.push({origin:"record",code:"invalid_key",issues:c.issues.map(g=>ce(g,i,K())),input:a,path:[a],inst:e}),n.value[c.value]=c.value;continue}let p=r.valueType._zod.run({value:t[a],issues:[]},i);p instanceof Promise?o.push(p.then(g=>{g.issues.length&&n.issues.push(...ae(a,g.issues)),n.value[c.value]=g.value})):(p.issues.length&&n.issues.push(...ae(a,p.issues)),n.value[c.value]=p.value)}}return o.length?Promise.all(o).then(()=>n):n}}),ya=u("$ZodMap",(e,r)=>{T.init(e,r),e._zod.parse=(n,i)=>{let t=n.value;if(!(t instanceof Map))return n.issues.push({expected:"map",code:"invalid_type",input:t,inst:e}),n;let o=[];n.value=new Map;for(let[a,c]of t){let p=r.keyType._zod.run({value:a,issues:[]},i),g=r.valueType._zod.run({value:c,issues:[]},i);p instanceof Promise||g instanceof Promise?o.push(Promise.all([p,g]).then(([h,m])=>{ru(h,m,n,a,t,e,i)})):ru(p,g,n,a,t,e,i)}return o.length?Promise.all(o).then(()=>n):n}});_a=u("$ZodSet",(e,r)=>{T.init(e,r),e._zod.parse=(n,i)=>{let t=n.value;if(!(t instanceof Set))return n.issues.push({input:t,inst:e,expected:"set",code:"invalid_type"}),n;let o=[];n.value=new Set;for(let a of t){let c=r.valueType._zod.run({value:a,issues:[]},i);c instanceof Promise?o.push(c.then(p=>nu(p,n))):nu(c,n)}return o.length?Promise.all(o).then(()=>n):n}});xa=u("$ZodEnum",(e,r)=>{T.init(e,r);let n=Pt(r.entries);e._zod.values=new Set(n),e._zod.pattern=new RegExp(`^(${n.filter(i=>Nt.has(typeof i)).map(i=>typeof i=="string"?_e(i):i.toString()).join("|")})$`),e._zod.parse=(i,t)=>{let o=i.value;return e._zod.values.has(o)||i.issues.push({code:"invalid_value",values:n,input:o,inst:e}),i}}),$a=u("$ZodLiteral",(e,r)=>{T.init(e,r),e._zod.values=new Set(r.values),e._zod.pattern=new RegExp(`^(${r.values.map(n=>typeof n=="string"?_e(n):n?n.toString():String(n)).join("|")})$`),e._zod.parse=(n,i)=>{let t=n.value;return e._zod.values.has(t)||n.issues.push({code:"invalid_value",values:r.values,input:t,inst:e}),n}}),za=u("$ZodFile",(e,r)=>{T.init(e,r),e._zod.parse=(n,i)=>{let t=n.value;return t instanceof File||n.issues.push({expected:"file",code:"invalid_type",input:t,inst:e}),n}}),qt=u("$ZodTransform",(e,r)=>{T.init(e,r),e._zod.parse=(n,i)=>{let t=r.transform(n.value,n);if(i.async)return(t instanceof Promise?t:Promise.resolve(t)).then(a=>(n.value=a,n));if(t instanceof Promise)throw new fe;return n.value=t,n}}),ka=u("$ZodOptional",(e,r)=>{T.init(e,r),e._zod.optin="optional",e._zod.optout="optional",A(e._zod,"values",()=>r.innerType._zod.values?new Set([...r.innerType._zod.values,void 0]):void 0),A(e._zod,"pattern",()=>{let n=r.innerType._zod.pattern;return n?new RegExp(`^(${Ot(n.source)})?$`):void 0}),e._zod.parse=(n,i)=>r.innerType._zod.optin==="optional"?r.innerType._zod.run(n,i):n.value===void 0?n:r.innerType._zod.run(n,i)}),Sa=u("$ZodNullable",(e,r)=>{T.init(e,r),A(e._zod,"optin",()=>r.innerType._zod.optin),A(e._zod,"optout",()=>r.innerType._zod.optout),A(e._zod,"pattern",()=>{let n=r.innerType._zod.pattern;return n?new RegExp(`^(${Ot(n.source)}|null)$`):void 0}),A(e._zod,"values",()=>r.innerType._zod.values?new Set([...r.innerType._zod.values,null]):void 0),e._zod.parse=(n,i)=>n.value===null?n:r.innerType._zod.run(n,i)}),wa=u("$ZodDefault",(e,r)=>{T.init(e,r),e._zod.optin="optional",A(e._zod,"values",()=>r.innerType._zod.values),e._zod.parse=(n,i)=>{if(n.value===void 0)return n.value=r.defaultValue,n;let t=r.innerType._zod.run(n,i);return t instanceof Promise?t.then(o=>ou(o,r)):ou(t,r)}});Ia=u("$ZodPrefault",(e,r)=>{T.init(e,r),e._zod.optin="optional",A(e._zod,"values",()=>r.innerType._zod.values),e._zod.parse=(n,i)=>(n.value===void 0&&(n.value=r.defaultValue),r.innerType._zod.run(n,i))}),ja=u("$ZodNonOptional",(e,r)=>{T.init(e,r),A(e._zod,"values",()=>{let n=r.innerType._zod.values;return n?new Set([...n].filter(i=>i!==void 0)):void 0}),e._zod.parse=(n,i)=>{let t=r.innerType._zod.run(n,i);return t instanceof Promise?t.then(o=>iu(o,e)):iu(t,e)}});Pa=u("$ZodSuccess",(e,r)=>{T.init(e,r),e._zod.parse=(n,i)=>{let t=r.innerType._zod.run(n,i);return t instanceof Promise?t.then(o=>(n.value=o.issues.length===0,n)):(n.value=t.issues.length===0,n)}}),Ta=u("$ZodCatch",(e,r)=>{T.init(e,r),e._zod.optin="optional",A(e._zod,"optout",()=>r.innerType._zod.optout),A(e._zod,"values",()=>r.innerType._zod.values),e._zod.parse=(n,i)=>{let t=r.innerType._zod.run(n,i);return t instanceof Promise?t.then(o=>(n.value=o.value,o.issues.length&&(n.value=r.catchValue({...n,error:{issues:o.issues.map(a=>ce(a,i,K()))},input:n.value}),n.issues=[]),n)):(n.value=t.value,t.issues.length&&(n.value=r.catchValue({...n,error:{issues:t.issues.map(o=>ce(o,i,K()))},input:n.value}),n.issues=[]),n)}}),Oa=u("$ZodNaN",(e,r)=>{T.init(e,r),e._zod.parse=(n,i)=>((typeof n.value!="number"||!Number.isNaN(n.value))&&n.issues.push({input:n.value,inst:e,expected:"nan",code:"invalid_type"}),n)}),Ft=u("$ZodPipe",(e,r)=>{T.init(e,r),A(e._zod,"values",()=>r.in._zod.values),A(e._zod,"optin",()=>r.in._zod.optin),A(e._zod,"optout",()=>r.out._zod.optout),e._zod.parse=(n,i)=>{let t=r.in._zod.run(n,i);return t instanceof Promise?t.then(o=>au(o,r,i)):au(t,r,i)}});Na=u("$ZodReadonly",(e,r)=>{T.init(e,r),A(e._zod,"propValues",()=>r.innerType._zod.propValues),A(e._zod,"values",()=>r.innerType._zod.values),A(e._zod,"optin",()=>r.innerType._zod.optin),A(e._zod,"optout",()=>r.innerType._zod.optout),e._zod.parse=(n,i)=>{let t=r.innerType._zod.run(n,i);return t instanceof Promise?t.then(su):su(t)}});Ua=u("$ZodTemplateLiteral",(e,r)=>{T.init(e,r);let n=[];for(let i of r.parts)if(i instanceof T){if(!i._zod.pattern)throw new Error(`Invalid template literal part, no pattern found: ${[...i._zod.traits].shift()}`);let t=i._zod.pattern instanceof RegExp?i._zod.pattern.source:i._zod.pattern;if(!t)throw new Error(`Invalid template literal part: ${i._zod.traits}`);let o=t.startsWith("^")?1:0,a=t.endsWith("$")?t.length-1:t.length;n.push(t.slice(o,a))}else if(i===null||No.has(typeof i))n.push(_e(`${i}`));else throw new Error(`Invalid template literal part: ${i}`);e._zod.pattern=new RegExp(`^${n.join("")}$`),e._zod.parse=(i,t)=>typeof i.value!="string"?(i.issues.push({input:i.value,inst:e,expected:"template_literal",code:"invalid_type"}),i):(e._zod.pattern.lastIndex=0,e._zod.pattern.test(i.value)||i.issues.push({input:i.value,inst:e,code:"invalid_format",format:"template_literal",pattern:e._zod.pattern.source}),i)}),Ea=u("$ZodPromise",(e,r)=>{T.init(e,r),e._zod.parse=(n,i)=>Promise.resolve(n.value).then(t=>r.innerType._zod.run({value:t,issues:[]},i))}),Da=u("$ZodLazy",(e,r)=>{T.init(e,r),A(e._zod,"innerType",()=>r.getter()),A(e._zod,"pattern",()=>e._zod.innerType._zod.pattern),A(e._zod,"propValues",()=>e._zod.innerType._zod.propValues),A(e._zod,"optin",()=>e._zod.innerType._zod.optin),A(e._zod,"optout",()=>e._zod.innerType._zod.optout),e._zod.parse=(n,i)=>e._zod.innerType._zod.run(n,i)}),Ra=u("$ZodCustom",(e,r)=>{J.init(e,r),T.init(e,r),e._zod.parse=(n,i)=>n,e._zod.check=n=>{let i=n.value,t=r.fn(i);if(t instanceof Promise)return t.then(o=>cu(o,n,i,e));cu(t,n,i,e)}})});function pu(){return{localeError:sm()}}var sm,mu=S(()=>{P();sm=()=>{let e={string:{unit:"\\u062D\\u0631\\u0641",verb:"\\u0623\\u0646 \\u064A\\u062D\\u0648\\u064A"},file:{unit:"\\u0628\\u0627\\u064A\\u062A",verb:"\\u0623\\u0646 \\u064A\\u062D\\u0648\\u064A"},array:{unit:"\\u0639\\u0646\\u0635\\u0631",verb:"\\u0623\\u0646 \\u064A\\u062D\\u0648\\u064A"},set:{unit:"\\u0639\\u0646\\u0635\\u0631",verb:"\\u0623\\u0646 \\u064A\\u062D\\u0648\\u064A"}};function r(t){return e[t]??null}let n=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"number";case"object":{if(Array.isArray(t))return"array";if(t===null)return"null";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"\\u0645\\u062F\\u062E\\u0644",email:"\\u0628\\u0631\\u064A\\u062F \\u0625\\u0644\\u0643\\u062A\\u0631\\u0648\\u0646\\u064A",url:"\\u0631\\u0627\\u0628\\u0637",emoji:"\\u0625\\u064A\\u0645\\u0648\\u062C\\u064A",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"\\u062A\\u0627\\u0631\\u064A\\u062E \\u0648\\u0648\\u0642\\u062A \\u0628\\u0645\\u0639\\u064A\\u0627\\u0631 ISO",date:"\\u062A\\u0627\\u0631\\u064A\\u062E \\u0628\\u0645\\u0639\\u064A\\u0627\\u0631 ISO",time:"\\u0648\\u0642\\u062A \\u0628\\u0645\\u0639\\u064A\\u0627\\u0631 ISO",duration:"\\u0645\\u062F\\u0629 \\u0628\\u0645\\u0639\\u064A\\u0627\\u0631 ISO",ipv4:"\\u0639\\u0646\\u0648\\u0627\\u0646 IPv4",ipv6:"\\u0639\\u0646\\u0648\\u0627\\u0646 IPv6",cidrv4:"\\u0645\\u062F\\u0649 \\u0639\\u0646\\u0627\\u0648\\u064A\\u0646 \\u0628\\u0635\\u064A\\u063A\\u0629 IPv4",cidrv6:"\\u0645\\u062F\\u0649 \\u0639\\u0646\\u0627\\u0648\\u064A\\u0646 \\u0628\\u0635\\u064A\\u063A\\u0629 IPv6",base64:"\\u0646\\u064E\\u0635 \\u0628\\u062A\\u0631\\u0645\\u064A\\u0632 base64-encoded",base64url:"\\u0646\\u064E\\u0635 \\u0628\\u062A\\u0631\\u0645\\u064A\\u0632 base64url-encoded",json_string:"\\u0646\\u064E\\u0635 \\u0639\\u0644\\u0649 \\u0647\\u064A\\u0626\\u0629 JSON",e164:"\\u0631\\u0642\\u0645 \\u0647\\u0627\\u062A\\u0641 \\u0628\\u0645\\u0639\\u064A\\u0627\\u0631 E.164",jwt:"JWT",template_literal:"\\u0645\\u062F\\u062E\\u0644"};return t=>{switch(t.code){case"invalid_type":return`\\u0645\\u062F\\u062E\\u0644\\u0627\\u062A \\u063A\\u064A\\u0631 \\u0645\\u0642\\u0628\\u0648\\u0644\\u0629: \\u064A\\u0641\\u062A\\u0631\\u0636 \\u0625\\u062F\\u062E\\u0627\\u0644 ${t.expected}\\u060C \\u0648\\u0644\\u0643\\u0646 \\u062A\\u0645 \\u0625\\u062F\\u062E\\u0627\\u0644 ${n(t.input)}`;case"invalid_value":return t.values.length===1?`\\u0645\\u062F\\u062E\\u0644\\u0627\\u062A \\u063A\\u064A\\u0631 \\u0645\\u0642\\u0628\\u0648\\u0644\\u0629: \\u064A\\u0641\\u062A\\u0631\\u0636 \\u0625\\u062F\\u062E\\u0627\\u0644 ${_(t.values[0])}`:`\\u0627\\u062E\\u062A\\u064A\\u0627\\u0631 \\u063A\\u064A\\u0631 \\u0645\\u0642\\u0628\\u0648\\u0644: \\u064A\\u062A\\u0648\\u0642\\u0639 \\u0627\\u0646\\u062A\\u0642\\u0627\\u0621 \\u0623\\u062D\\u062F \\u0647\\u0630\\u0647 \\u0627\\u0644\\u062E\\u064A\\u0627\\u0631\\u0627\\u062A: ${f(t.values,"|")}`;case"too_big":{let o=t.inclusive?"<=":"<",a=r(t.origin);return a?` \\u0623\\u0643\\u0628\\u0631 \\u0645\\u0646 \\u0627\\u0644\\u0644\\u0627\\u0632\\u0645: \\u064A\\u0641\\u062A\\u0631\\u0636 \\u0623\\u0646 \\u062A\\u0643\\u0648\\u0646 ${t.origin??"\\u0627\\u0644\\u0642\\u064A\\u0645\\u0629"} ${o} ${t.maximum.toString()} ${a.unit??"\\u0639\\u0646\\u0635\\u0631"}`:`\\u0623\\u0643\\u0628\\u0631 \\u0645\\u0646 \\u0627\\u0644\\u0644\\u0627\\u0632\\u0645: \\u064A\\u0641\\u062A\\u0631\\u0636 \\u0623\\u0646 \\u062A\\u0643\\u0648\\u0646 ${t.origin??"\\u0627\\u0644\\u0642\\u064A\\u0645\\u0629"} ${o} ${t.maximum.toString()}`}case"too_small":{let o=t.inclusive?">=":">",a=r(t.origin);return a?`\\u0623\\u0635\\u063A\\u0631 \\u0645\\u0646 \\u0627\\u0644\\u0644\\u0627\\u0632\\u0645: \\u064A\\u0641\\u062A\\u0631\\u0636 \\u0644\\u0640 ${t.origin} \\u0623\\u0646 \\u064A\\u0643\\u0648\\u0646 ${o} ${t.minimum.toString()} ${a.unit}`:`\\u0623\\u0635\\u063A\\u0631 \\u0645\\u0646 \\u0627\\u0644\\u0644\\u0627\\u0632\\u0645: \\u064A\\u0641\\u062A\\u0631\\u0636 \\u0644\\u0640 ${t.origin} \\u0623\\u0646 \\u064A\\u0643\\u0648\\u0646 ${o} ${t.minimum.toString()}`}case"invalid_format":{let o=t;return o.format==="starts_with"?`\\u0646\\u064E\\u0635 \\u063A\\u064A\\u0631 \\u0645\\u0642\\u0628\\u0648\\u0644: \\u064A\\u062C\\u0628 \\u0623\\u0646 \\u064A\\u0628\\u062F\\u0623 \\u0628\\u0640 "${t.prefix}"`:o.format==="ends_with"?`\\u0646\\u064E\\u0635 \\u063A\\u064A\\u0631 \\u0645\\u0642\\u0628\\u0648\\u0644: \\u064A\\u062C\\u0628 \\u0623\\u0646 \\u064A\\u0646\\u062A\\u0647\\u064A \\u0628\\u0640 "${o.suffix}"`:o.format==="includes"?`\\u0646\\u064E\\u0635 \\u063A\\u064A\\u0631 \\u0645\\u0642\\u0628\\u0648\\u0644: \\u064A\\u062C\\u0628 \\u0623\\u0646 \\u064A\\u062A\\u0636\\u0645\\u0651\\u064E\\u0646 "${o.includes}"`:o.format==="regex"?`\\u0646\\u064E\\u0635 \\u063A\\u064A\\u0631 \\u0645\\u0642\\u0628\\u0648\\u0644: \\u064A\\u062C\\u0628 \\u0623\\u0646 \\u064A\\u0637\\u0627\\u0628\\u0642 \\u0627\\u0644\\u0646\\u0645\\u0637 ${o.pattern}`:`${i[o.format]??t.format} \\u063A\\u064A\\u0631 \\u0645\\u0642\\u0628\\u0648\\u0644`}case"not_multiple_of":return`\\u0631\\u0642\\u0645 \\u063A\\u064A\\u0631 \\u0645\\u0642\\u0628\\u0648\\u0644: \\u064A\\u062C\\u0628 \\u0623\\u0646 \\u064A\\u0643\\u0648\\u0646 \\u0645\\u0646 \\u0645\\u0636\\u0627\\u0639\\u0641\\u0627\\u062A ${t.divisor}`;case"unrecognized_keys":return`\\u0645\\u0639\\u0631\\u0641${t.keys.length>1?"\\u0627\\u062A":""} \\u063A\\u0631\\u064A\\u0628${t.keys.length>1?"\\u0629":""}: ${f(t.keys,"\\u060C ")}`;case"invalid_key":return`\\u0645\\u0639\\u0631\\u0641 \\u063A\\u064A\\u0631 \\u0645\\u0642\\u0628\\u0648\\u0644 \\u0641\\u064A ${t.origin}`;case"invalid_union":return"\\u0645\\u062F\\u062E\\u0644 \\u063A\\u064A\\u0631 \\u0645\\u0642\\u0628\\u0648\\u0644";case"invalid_element":return`\\u0645\\u062F\\u062E\\u0644 \\u063A\\u064A\\u0631 \\u0645\\u0642\\u0628\\u0648\\u0644 \\u0641\\u064A ${t.origin}`;default:return"\\u0645\\u062F\\u062E\\u0644 \\u063A\\u064A\\u0631 \\u0645\\u0642\\u0628\\u0648\\u0644"}}}});function fu(){return{localeError:cm()}}var cm,gu=S(()=>{P();cm=()=>{let e={string:{unit:"simvol",verb:"olmal\\u0131d\\u0131r"},file:{unit:"bayt",verb:"olmal\\u0131d\\u0131r"},array:{unit:"element",verb:"olmal\\u0131d\\u0131r"},set:{unit:"element",verb:"olmal\\u0131d\\u0131r"}};function r(t){return e[t]??null}let n=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"number";case"object":{if(Array.isArray(t))return"array";if(t===null)return"null";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"input",email:"email address",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO datetime",date:"ISO date",time:"ISO time",duration:"ISO duration",ipv4:"IPv4 address",ipv6:"IPv6 address",cidrv4:"IPv4 range",cidrv6:"IPv6 range",base64:"base64-encoded string",base64url:"base64url-encoded string",json_string:"JSON string",e164:"E.164 number",jwt:"JWT",template_literal:"input"};return t=>{switch(t.code){case"invalid_type":return`Yanl\\u0131\\u015F d\\u0259y\\u0259r: g\\xF6zl\\u0259nil\\u0259n ${t.expected}, daxil olan ${n(t.input)}`;case"invalid_value":return t.values.length===1?`Yanl\\u0131\\u015F d\\u0259y\\u0259r: g\\xF6zl\\u0259nil\\u0259n ${_(t.values[0])}`:`Yanl\\u0131\\u015F se\\xE7im: a\\u015Fa\\u011F\\u0131dak\\u0131lardan biri olmal\\u0131d\\u0131r: ${f(t.values,"|")}`;case"too_big":{let o=t.inclusive?"<=":"<",a=r(t.origin);return a?`\\xC7ox b\\xF6y\\xFCk: g\\xF6zl\\u0259nil\\u0259n ${t.origin??"d\\u0259y\\u0259r"} ${o}${t.maximum.toString()} ${a.unit??"element"}`:`\\xC7ox b\\xF6y\\xFCk: g\\xF6zl\\u0259nil\\u0259n ${t.origin??"d\\u0259y\\u0259r"} ${o}${t.maximum.toString()}`}case"too_small":{let o=t.inclusive?">=":">",a=r(t.origin);return a?`\\xC7ox ki\\xE7ik: g\\xF6zl\\u0259nil\\u0259n ${t.origin} ${o}${t.minimum.toString()} ${a.unit}`:`\\xC7ox ki\\xE7ik: g\\xF6zl\\u0259nil\\u0259n ${t.origin} ${o}${t.minimum.toString()}`}case"invalid_format":{let o=t;return o.format==="starts_with"?`Yanl\\u0131\\u015F m\\u0259tn: "${o.prefix}" il\\u0259 ba\\u015Flamal\\u0131d\\u0131r`:o.format==="ends_with"?`Yanl\\u0131\\u015F m\\u0259tn: "${o.suffix}" il\\u0259 bitm\\u0259lidir`:o.format==="includes"?`Yanl\\u0131\\u015F m\\u0259tn: "${o.includes}" daxil olmal\\u0131d\\u0131r`:o.format==="regex"?`Yanl\\u0131\\u015F m\\u0259tn: ${o.pattern} \\u015Fablonuna uy\\u011Fun olmal\\u0131d\\u0131r`:`Yanl\\u0131\\u015F ${i[o.format]??t.format}`}case"not_multiple_of":return`Yanl\\u0131\\u015F \\u0259d\\u0259d: ${t.divisor} il\\u0259 b\\xF6l\\xFCn\\u0259 bil\\u0259n olmal\\u0131d\\u0131r`;case"unrecognized_keys":return`Tan\\u0131nmayan a\\xE7ar${t.keys.length>1?"lar":""}: ${f(t.keys,", ")}`;case"invalid_key":return`${t.origin} daxilind\\u0259 yanl\\u0131\\u015F a\\xE7ar`;case"invalid_union":return"Yanl\\u0131\\u015F d\\u0259y\\u0259r";case"invalid_element":return`${t.origin} daxilind\\u0259 yanl\\u0131\\u015F d\\u0259y\\u0259r`;default:return"Yanl\\u0131\\u015F d\\u0259y\\u0259r"}}}});function hu(e,r,n,i){let t=Math.abs(e),o=t%10,a=t%100;return a>=11&&a<=19?i:o===1?r:o>=2&&o<=4?n:i}function vu(){return{localeError:um()}}var um,bu=S(()=>{P();um=()=>{let e={string:{unit:{one:"\\u0441\\u0456\\u043C\\u0432\\u0430\\u043B",few:"\\u0441\\u0456\\u043C\\u0432\\u0430\\u043B\\u044B",many:"\\u0441\\u0456\\u043C\\u0432\\u0430\\u043B\\u0430\\u045E"},verb:"\\u043C\\u0435\\u0446\\u044C"},array:{unit:{one:"\\u044D\\u043B\\u0435\\u043C\\u0435\\u043D\\u0442",few:"\\u044D\\u043B\\u0435\\u043C\\u0435\\u043D\\u0442\\u044B",many:"\\u044D\\u043B\\u0435\\u043C\\u0435\\u043D\\u0442\\u0430\\u045E"},verb:"\\u043C\\u0435\\u0446\\u044C"},set:{unit:{one:"\\u044D\\u043B\\u0435\\u043C\\u0435\\u043D\\u0442",few:"\\u044D\\u043B\\u0435\\u043C\\u0435\\u043D\\u0442\\u044B",many:"\\u044D\\u043B\\u0435\\u043C\\u0435\\u043D\\u0442\\u0430\\u045E"},verb:"\\u043C\\u0435\\u0446\\u044C"},file:{unit:{one:"\\u0431\\u0430\\u0439\\u0442",few:"\\u0431\\u0430\\u0439\\u0442\\u044B",many:"\\u0431\\u0430\\u0439\\u0442\\u0430\\u045E"},verb:"\\u043C\\u0435\\u0446\\u044C"}};function r(t){return e[t]??null}let n=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"\\u043B\\u0456\\u043A";case"object":{if(Array.isArray(t))return"\\u043C\\u0430\\u0441\\u0456\\u045E";if(t===null)return"null";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"\\u0443\\u0432\\u043E\\u0434",email:"email \\u0430\\u0434\\u0440\\u0430\\u0441",url:"URL",emoji:"\\u044D\\u043C\\u043E\\u0434\\u0437\\u0456",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO \\u0434\\u0430\\u0442\\u0430 \\u0456 \\u0447\\u0430\\u0441",date:"ISO \\u0434\\u0430\\u0442\\u0430",time:"ISO \\u0447\\u0430\\u0441",duration:"ISO \\u043F\\u0440\\u0430\\u0446\\u044F\\u0433\\u043B\\u0430\\u0441\\u0446\\u044C",ipv4:"IPv4 \\u0430\\u0434\\u0440\\u0430\\u0441",ipv6:"IPv6 \\u0430\\u0434\\u0440\\u0430\\u0441",cidrv4:"IPv4 \\u0434\\u044B\\u044F\\u043F\\u0430\\u0437\\u043E\\u043D",cidrv6:"IPv6 \\u0434\\u044B\\u044F\\u043F\\u0430\\u0437\\u043E\\u043D",base64:"\\u0440\\u0430\\u0434\\u043E\\u043A \\u0443 \\u0444\\u0430\\u0440\\u043C\\u0430\\u0446\\u0435 base64",base64url:"\\u0440\\u0430\\u0434\\u043E\\u043A \\u0443 \\u0444\\u0430\\u0440\\u043C\\u0430\\u0446\\u0435 base64url",json_string:"JSON \\u0440\\u0430\\u0434\\u043E\\u043A",e164:"\\u043D\\u0443\\u043C\\u0430\\u0440 E.164",jwt:"JWT",template_literal:"\\u0443\\u0432\\u043E\\u0434"};return t=>{switch(t.code){case"invalid_type":return`\\u041D\\u044F\\u043F\\u0440\\u0430\\u0432\\u0456\\u043B\\u044C\\u043D\\u044B \\u045E\\u0432\\u043E\\u0434: \\u0447\\u0430\\u043A\\u0430\\u045E\\u0441\\u044F ${t.expected}, \\u0430\\u0442\\u0440\\u044B\\u043C\\u0430\\u043D\\u0430 ${n(t.input)}`;case"invalid_value":return t.values.length===1?`\\u041D\\u044F\\u043F\\u0440\\u0430\\u0432\\u0456\\u043B\\u044C\\u043D\\u044B \\u045E\\u0432\\u043E\\u0434: \\u0447\\u0430\\u043A\\u0430\\u043B\\u0430\\u0441\\u044F ${_(t.values[0])}`:`\\u041D\\u044F\\u043F\\u0440\\u0430\\u0432\\u0456\\u043B\\u044C\\u043D\\u044B \\u0432\\u0430\\u0440\\u044B\\u044F\\u043D\\u0442: \\u0447\\u0430\\u043A\\u0430\\u045E\\u0441\\u044F \\u0430\\u0434\\u0437\\u0456\\u043D \\u0437 ${f(t.values,"|")}`;case"too_big":{let o=t.inclusive?"<=":"<",a=r(t.origin);if(a){let c=Number(t.maximum),p=hu(c,a.unit.one,a.unit.few,a.unit.many);return`\\u0417\\u0430\\u043D\\u0430\\u0434\\u0442\\u0430 \\u0432\\u044F\\u043B\\u0456\\u043A\\u0456: \\u0447\\u0430\\u043A\\u0430\\u043B\\u0430\\u0441\\u044F, \\u0448\\u0442\\u043E ${t.origin??"\\u0437\\u043D\\u0430\\u0447\\u044D\\u043D\\u043D\\u0435"} \\u043F\\u0430\\u0432\\u0456\\u043D\\u043D\\u0430 ${a.verb} ${o}${t.maximum.toString()} ${p}`}return`\\u0417\\u0430\\u043D\\u0430\\u0434\\u0442\\u0430 \\u0432\\u044F\\u043B\\u0456\\u043A\\u0456: \\u0447\\u0430\\u043A\\u0430\\u043B\\u0430\\u0441\\u044F, \\u0448\\u0442\\u043E ${t.origin??"\\u0437\\u043D\\u0430\\u0447\\u044D\\u043D\\u043D\\u0435"} \\u043F\\u0430\\u0432\\u0456\\u043D\\u043D\\u0430 \\u0431\\u044B\\u0446\\u044C ${o}${t.maximum.toString()}`}case"too_small":{let o=t.inclusive?">=":">",a=r(t.origin);if(a){let c=Number(t.minimum),p=hu(c,a.unit.one,a.unit.few,a.unit.many);return`\\u0417\\u0430\\u043D\\u0430\\u0434\\u0442\\u0430 \\u043C\\u0430\\u043B\\u044B: \\u0447\\u0430\\u043A\\u0430\\u043B\\u0430\\u0441\\u044F, \\u0448\\u0442\\u043E ${t.origin} \\u043F\\u0430\\u0432\\u0456\\u043D\\u043D\\u0430 ${a.verb} ${o}${t.minimum.toString()} ${p}`}return`\\u0417\\u0430\\u043D\\u0430\\u0434\\u0442\\u0430 \\u043C\\u0430\\u043B\\u044B: \\u0447\\u0430\\u043A\\u0430\\u043B\\u0430\\u0441\\u044F, \\u0448\\u0442\\u043E ${t.origin} \\u043F\\u0430\\u0432\\u0456\\u043D\\u043D\\u0430 \\u0431\\u044B\\u0446\\u044C ${o}${t.minimum.toString()}`}case"invalid_format":{let o=t;return o.format==="starts_with"?`\\u041D\\u044F\\u043F\\u0440\\u0430\\u0432\\u0456\\u043B\\u044C\\u043D\\u044B \\u0440\\u0430\\u0434\\u043E\\u043A: \\u043F\\u0430\\u0432\\u0456\\u043D\\u0435\\u043D \\u043F\\u0430\\u0447\\u044B\\u043D\\u0430\\u0446\\u0446\\u0430 \\u0437 "${o.prefix}"`:o.format==="ends_with"?`\\u041D\\u044F\\u043F\\u0440\\u0430\\u0432\\u0456\\u043B\\u044C\\u043D\\u044B \\u0440\\u0430\\u0434\\u043E\\u043A: \\u043F\\u0430\\u0432\\u0456\\u043D\\u0435\\u043D \\u0437\\u0430\\u043A\\u0430\\u043D\\u0447\\u0432\\u0430\\u0446\\u0446\\u0430 \\u043D\\u0430 "${o.suffix}"`:o.format==="includes"?`\\u041D\\u044F\\u043F\\u0440\\u0430\\u0432\\u0456\\u043B\\u044C\\u043D\\u044B \\u0440\\u0430\\u0434\\u043E\\u043A: \\u043F\\u0430\\u0432\\u0456\\u043D\\u0435\\u043D \\u0437\\u043C\\u044F\\u0448\\u0447\\u0430\\u0446\\u044C "${o.includes}"`:o.format==="regex"?`\\u041D\\u044F\\u043F\\u0440\\u0430\\u0432\\u0456\\u043B\\u044C\\u043D\\u044B \\u0440\\u0430\\u0434\\u043E\\u043A: \\u043F\\u0430\\u0432\\u0456\\u043D\\u0435\\u043D \\u0430\\u0434\\u043F\\u0430\\u0432\\u044F\\u0434\\u0430\\u0446\\u044C \\u0448\\u0430\\u0431\\u043B\\u043E\\u043D\\u0443 ${o.pattern}`:`\\u041D\\u044F\\u043F\\u0440\\u0430\\u0432\\u0456\\u043B\\u044C\\u043D\\u044B ${i[o.format]??t.format}`}case"not_multiple_of":return`\\u041D\\u044F\\u043F\\u0440\\u0430\\u0432\\u0456\\u043B\\u044C\\u043D\\u044B \\u043B\\u0456\\u043A: \\u043F\\u0430\\u0432\\u0456\\u043D\\u0435\\u043D \\u0431\\u044B\\u0446\\u044C \\u043A\\u0440\\u0430\\u0442\\u043D\\u044B\\u043C ${t.divisor}`;case"unrecognized_keys":return`\\u041D\\u0435\\u0440\\u0430\\u0441\\u043F\\u0430\\u0437\\u043D\\u0430\\u043D\\u044B ${t.keys.length>1?"\\u043A\\u043B\\u044E\\u0447\\u044B":"\\u043A\\u043B\\u044E\\u0447"}: ${f(t.keys,", ")}`;case"invalid_key":return`\\u041D\\u044F\\u043F\\u0440\\u0430\\u0432\\u0456\\u043B\\u044C\\u043D\\u044B \\u043A\\u043B\\u044E\\u0447 \\u0443 ${t.origin}`;case"invalid_union":return"\\u041D\\u044F\\u043F\\u0440\\u0430\\u0432\\u0456\\u043B\\u044C\\u043D\\u044B \\u045E\\u0432\\u043E\\u0434";case"invalid_element":return`\\u041D\\u044F\\u043F\\u0440\\u0430\\u0432\\u0456\\u043B\\u044C\\u043D\\u0430\\u0435 \\u0437\\u043D\\u0430\\u0447\\u044D\\u043D\\u043D\\u0435 \\u045E ${t.origin}`;default:return"\\u041D\\u044F\\u043F\\u0440\\u0430\\u0432\\u0456\\u043B\\u044C\\u043D\\u044B \\u045E\\u0432\\u043E\\u0434"}}}});function yu(){return{localeError:lm()}}var lm,_u=S(()=>{P();lm=()=>{let e={string:{unit:"car\\xE0cters",verb:"contenir"},file:{unit:"bytes",verb:"contenir"},array:{unit:"elements",verb:"contenir"},set:{unit:"elements",verb:"contenir"}};function r(t){return e[t]??null}let n=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"number";case"object":{if(Array.isArray(t))return"array";if(t===null)return"null";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"entrada",email:"adre\\xE7a electr\\xF2nica",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"data i hora ISO",date:"data ISO",time:"hora ISO",duration:"durada ISO",ipv4:"adre\\xE7a IPv4",ipv6:"adre\\xE7a IPv6",cidrv4:"rang IPv4",cidrv6:"rang IPv6",base64:"cadena codificada en base64",base64url:"cadena codificada en base64url",json_string:"cadena JSON",e164:"n\\xFAmero E.164",jwt:"JWT",template_literal:"entrada"};return t=>{switch(t.code){case"invalid_type":return`Tipus inv\\xE0lid: s\'esperava ${t.expected}, s\'ha rebut ${n(t.input)}`;case"invalid_value":return t.values.length===1?`Valor inv\\xE0lid: s\'esperava ${_(t.values[0])}`:`Opci\\xF3 inv\\xE0lida: s\'esperava una de ${f(t.values," o ")}`;case"too_big":{let o=t.inclusive?"com a m\\xE0xim":"menys de",a=r(t.origin);return a?`Massa gran: s\'esperava que ${t.origin??"el valor"} contingu\\xE9s ${o} ${t.maximum.toString()} ${a.unit??"elements"}`:`Massa gran: s\'esperava que ${t.origin??"el valor"} fos ${o} ${t.maximum.toString()}`}case"too_small":{let o=t.inclusive?"com a m\\xEDnim":"m\\xE9s de",a=r(t.origin);return a?`Massa petit: s\'esperava que ${t.origin} contingu\\xE9s ${o} ${t.minimum.toString()} ${a.unit}`:`Massa petit: s\'esperava que ${t.origin} fos ${o} ${t.minimum.toString()}`}case"invalid_format":{let o=t;return o.format==="starts_with"?`Format inv\\xE0lid: ha de comen\\xE7ar amb "${o.prefix}"`:o.format==="ends_with"?`Format inv\\xE0lid: ha d\'acabar amb "${o.suffix}"`:o.format==="includes"?`Format inv\\xE0lid: ha d\'incloure "${o.includes}"`:o.format==="regex"?`Format inv\\xE0lid: ha de coincidir amb el patr\\xF3 ${o.pattern}`:`Format inv\\xE0lid per a ${i[o.format]??t.format}`}case"not_multiple_of":return`N\\xFAmero inv\\xE0lid: ha de ser m\\xFAltiple de ${t.divisor}`;case"unrecognized_keys":return`Clau${t.keys.length>1?"s":""} no reconeguda${t.keys.length>1?"s":""}: ${f(t.keys,", ")}`;case"invalid_key":return`Clau inv\\xE0lida a ${t.origin}`;case"invalid_union":return"Entrada inv\\xE0lida";case"invalid_element":return`Element inv\\xE0lid a ${t.origin}`;default:return"Entrada inv\\xE0lida"}}}});function xu(){return{localeError:dm()}}var dm,$u=S(()=>{P();dm=()=>{let e={string:{unit:"znak\\u016F",verb:"m\\xEDt"},file:{unit:"bajt\\u016F",verb:"m\\xEDt"},array:{unit:"prvk\\u016F",verb:"m\\xEDt"},set:{unit:"prvk\\u016F",verb:"m\\xEDt"}};function r(t){return e[t]??null}let n=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"\\u010D\\xEDslo";case"string":return"\\u0159et\\u011Bzec";case"boolean":return"boolean";case"bigint":return"bigint";case"function":return"funkce";case"symbol":return"symbol";case"undefined":return"undefined";case"object":{if(Array.isArray(t))return"pole";if(t===null)return"null";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"regul\\xE1rn\\xED v\\xFDraz",email:"e-mailov\\xE1 adresa",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"datum a \\u010Das ve form\\xE1tu ISO",date:"datum ve form\\xE1tu ISO",time:"\\u010Das ve form\\xE1tu ISO",duration:"doba trv\\xE1n\\xED ISO",ipv4:"IPv4 adresa",ipv6:"IPv6 adresa",cidrv4:"rozsah IPv4",cidrv6:"rozsah IPv6",base64:"\\u0159et\\u011Bzec zak\\xF3dovan\\xFD ve form\\xE1tu base64",base64url:"\\u0159et\\u011Bzec zak\\xF3dovan\\xFD ve form\\xE1tu base64url",json_string:"\\u0159et\\u011Bzec ve form\\xE1tu JSON",e164:"\\u010D\\xEDslo E.164",jwt:"JWT",template_literal:"vstup"};return t=>{switch(t.code){case"invalid_type":return`Neplatn\\xFD vstup: o\\u010Dek\\xE1v\\xE1no ${t.expected}, obdr\\u017Eeno ${n(t.input)}`;case"invalid_value":return t.values.length===1?`Neplatn\\xFD vstup: o\\u010Dek\\xE1v\\xE1no ${_(t.values[0])}`:`Neplatn\\xE1 mo\\u017Enost: o\\u010Dek\\xE1v\\xE1na jedna z hodnot ${f(t.values,"|")}`;case"too_big":{let o=t.inclusive?"<=":"<",a=r(t.origin);return a?`Hodnota je p\\u0159\\xEDli\\u0161 velk\\xE1: ${t.origin??"hodnota"} mus\\xED m\\xEDt ${o}${t.maximum.toString()} ${a.unit??"prvk\\u016F"}`:`Hodnota je p\\u0159\\xEDli\\u0161 velk\\xE1: ${t.origin??"hodnota"} mus\\xED b\\xFDt ${o}${t.maximum.toString()}`}case"too_small":{let o=t.inclusive?">=":">",a=r(t.origin);return a?`Hodnota je p\\u0159\\xEDli\\u0161 mal\\xE1: ${t.origin??"hodnota"} mus\\xED m\\xEDt ${o}${t.minimum.toString()} ${a.unit??"prvk\\u016F"}`:`Hodnota je p\\u0159\\xEDli\\u0161 mal\\xE1: ${t.origin??"hodnota"} mus\\xED b\\xFDt ${o}${t.minimum.toString()}`}case"invalid_format":{let o=t;return o.format==="starts_with"?`Neplatn\\xFD \\u0159et\\u011Bzec: mus\\xED za\\u010D\\xEDnat na "${o.prefix}"`:o.format==="ends_with"?`Neplatn\\xFD \\u0159et\\u011Bzec: mus\\xED kon\\u010Dit na "${o.suffix}"`:o.format==="includes"?`Neplatn\\xFD \\u0159et\\u011Bzec: mus\\xED obsahovat "${o.includes}"`:o.format==="regex"?`Neplatn\\xFD \\u0159et\\u011Bzec: mus\\xED odpov\\xEDdat vzoru ${o.pattern}`:`Neplatn\\xFD form\\xE1t ${i[o.format]??t.format}`}case"not_multiple_of":return`Neplatn\\xE9 \\u010D\\xEDslo: mus\\xED b\\xFDt n\\xE1sobkem ${t.divisor}`;case"unrecognized_keys":return`Nezn\\xE1m\\xE9 kl\\xED\\u010De: ${f(t.keys,", ")}`;case"invalid_key":return`Neplatn\\xFD kl\\xED\\u010D v ${t.origin}`;case"invalid_union":return"Neplatn\\xFD vstup";case"invalid_element":return`Neplatn\\xE1 hodnota v ${t.origin}`;default:return"Neplatn\\xFD vstup"}}}});function zu(){return{localeError:pm()}}var pm,ku=S(()=>{P();pm=()=>{let e={string:{unit:"Zeichen",verb:"zu haben"},file:{unit:"Bytes",verb:"zu haben"},array:{unit:"Elemente",verb:"zu haben"},set:{unit:"Elemente",verb:"zu haben"}};function r(t){return e[t]??null}let n=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"Zahl";case"object":{if(Array.isArray(t))return"Array";if(t===null)return"null";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"Eingabe",email:"E-Mail-Adresse",url:"URL",emoji:"Emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO-Datum und -Uhrzeit",date:"ISO-Datum",time:"ISO-Uhrzeit",duration:"ISO-Dauer",ipv4:"IPv4-Adresse",ipv6:"IPv6-Adresse",cidrv4:"IPv4-Bereich",cidrv6:"IPv6-Bereich",base64:"Base64-codierter String",base64url:"Base64-URL-codierter String",json_string:"JSON-String",e164:"E.164-Nummer",jwt:"JWT",template_literal:"Eingabe"};return t=>{switch(t.code){case"invalid_type":return`Ung\\xFCltige Eingabe: erwartet ${t.expected}, erhalten ${n(t.input)}`;case"invalid_value":return t.values.length===1?`Ung\\xFCltige Eingabe: erwartet ${_(t.values[0])}`:`Ung\\xFCltige Option: erwartet eine von ${f(t.values,"|")}`;case"too_big":{let o=t.inclusive?"<=":"<",a=r(t.origin);return a?`Zu gro\\xDF: erwartet, dass ${t.origin??"Wert"} ${o}${t.maximum.toString()} ${a.unit??"Elemente"} hat`:`Zu gro\\xDF: erwartet, dass ${t.origin??"Wert"} ${o}${t.maximum.toString()} ist`}case"too_small":{let o=t.inclusive?">=":">",a=r(t.origin);return a?`Zu klein: erwartet, dass ${t.origin} ${o}${t.minimum.toString()} ${a.unit} hat`:`Zu klein: erwartet, dass ${t.origin} ${o}${t.minimum.toString()} ist`}case"invalid_format":{let o=t;return o.format==="starts_with"?`Ung\\xFCltiger String: muss mit "${o.prefix}" beginnen`:o.format==="ends_with"?`Ung\\xFCltiger String: muss mit "${o.suffix}" enden`:o.format==="includes"?`Ung\\xFCltiger String: muss "${o.includes}" enthalten`:o.format==="regex"?`Ung\\xFCltiger String: muss dem Muster ${o.pattern} entsprechen`:`Ung\\xFCltig: ${i[o.format]??t.format}`}case"not_multiple_of":return`Ung\\xFCltige Zahl: muss ein Vielfaches von ${t.divisor} sein`;case"unrecognized_keys":return`${t.keys.length>1?"Unbekannte Schl\\xFCssel":"Unbekannter Schl\\xFCssel"}: ${f(t.keys,", ")}`;case"invalid_key":return`Ung\\xFCltiger Schl\\xFCssel in ${t.origin}`;case"invalid_union":return"Ung\\xFCltige Eingabe";case"invalid_element":return`Ung\\xFCltiger Wert in ${t.origin}`;default:return"Ung\\xFCltige Eingabe"}}}});function Fr(){return{localeError:fm()}}var mm,fm,Za=S(()=>{P();mm=e=>{let r=typeof e;switch(r){case"number":return Number.isNaN(e)?"NaN":"number";case"object":{if(Array.isArray(e))return"array";if(e===null)return"null";if(Object.getPrototypeOf(e)!==Object.prototype&&e.constructor)return e.constructor.name}}return r},fm=()=>{let e={string:{unit:"characters",verb:"to have"},file:{unit:"bytes",verb:"to have"},array:{unit:"items",verb:"to have"},set:{unit:"items",verb:"to have"}};function r(i){return e[i]??null}let n={regex:"input",email:"email address",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO datetime",date:"ISO date",time:"ISO time",duration:"ISO duration",ipv4:"IPv4 address",ipv6:"IPv6 address",cidrv4:"IPv4 range",cidrv6:"IPv6 range",base64:"base64-encoded string",base64url:"base64url-encoded string",json_string:"JSON string",e164:"E.164 number",jwt:"JWT",template_literal:"input"};return i=>{switch(i.code){case"invalid_type":return`Invalid input: expected ${i.expected}, received ${mm(i.input)}`;case"invalid_value":return i.values.length===1?`Invalid input: expected ${_(i.values[0])}`:`Invalid option: expected one of ${f(i.values,"|")}`;case"too_big":{let t=i.inclusive?"<=":"<",o=r(i.origin);return o?`Too big: expected ${i.origin??"value"} to have ${t}${i.maximum.toString()} ${o.unit??"elements"}`:`Too big: expected ${i.origin??"value"} to be ${t}${i.maximum.toString()}`}case"too_small":{let t=i.inclusive?">=":">",o=r(i.origin);return o?`Too small: expected ${i.origin} to have ${t}${i.minimum.toString()} ${o.unit}`:`Too small: expected ${i.origin} to be ${t}${i.minimum.toString()}`}case"invalid_format":{let t=i;return t.format==="starts_with"?`Invalid string: must start with "${t.prefix}"`:t.format==="ends_with"?`Invalid string: must end with "${t.suffix}"`:t.format==="includes"?`Invalid string: must include "${t.includes}"`:t.format==="regex"?`Invalid string: must match pattern ${t.pattern}`:`Invalid ${n[t.format]??i.format}`}case"not_multiple_of":return`Invalid number: must be a multiple of ${i.divisor}`;case"unrecognized_keys":return`Unrecognized key${i.keys.length>1?"s":""}: ${f(i.keys,", ")}`;case"invalid_key":return`Invalid key in ${i.origin}`;case"invalid_union":return"Invalid input";case"invalid_element":return`Invalid value in ${i.origin}`;default:return"Invalid input"}}}});function Su(){return{localeError:hm()}}var gm,hm,wu=S(()=>{P();gm=e=>{let r=typeof e;switch(r){case"number":return Number.isNaN(e)?"NaN":"nombro";case"object":{if(Array.isArray(e))return"tabelo";if(e===null)return"senvalora";if(Object.getPrototypeOf(e)!==Object.prototype&&e.constructor)return e.constructor.name}}return r},hm=()=>{let e={string:{unit:"karaktrojn",verb:"havi"},file:{unit:"bajtojn",verb:"havi"},array:{unit:"elementojn",verb:"havi"},set:{unit:"elementojn",verb:"havi"}};function r(i){return e[i]??null}let n={regex:"enigo",email:"retadreso",url:"URL",emoji:"emo\\u011Dio",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO-datotempo",date:"ISO-dato",time:"ISO-tempo",duration:"ISO-da\\u016Dro",ipv4:"IPv4-adreso",ipv6:"IPv6-adreso",cidrv4:"IPv4-rango",cidrv6:"IPv6-rango",base64:"64-ume kodita karaktraro",base64url:"URL-64-ume kodita karaktraro",json_string:"JSON-karaktraro",e164:"E.164-nombro",jwt:"JWT",template_literal:"enigo"};return i=>{switch(i.code){case"invalid_type":return`Nevalida enigo: atendi\\u011Dis ${i.expected}, ricevi\\u011Dis ${gm(i.input)}`;case"invalid_value":return i.values.length===1?`Nevalida enigo: atendi\\u011Dis ${_(i.values[0])}`:`Nevalida opcio: atendi\\u011Dis unu el ${f(i.values,"|")}`;case"too_big":{let t=i.inclusive?"<=":"<",o=r(i.origin);return o?`Tro granda: atendi\\u011Dis ke ${i.origin??"valoro"} havu ${t}${i.maximum.toString()} ${o.unit??"elementojn"}`:`Tro granda: atendi\\u011Dis ke ${i.origin??"valoro"} havu ${t}${i.maximum.toString()}`}case"too_small":{let t=i.inclusive?">=":">",o=r(i.origin);return o?`Tro malgranda: atendi\\u011Dis ke ${i.origin} havu ${t}${i.minimum.toString()} ${o.unit}`:`Tro malgranda: atendi\\u011Dis ke ${i.origin} estu ${t}${i.minimum.toString()}`}case"invalid_format":{let t=i;return t.format==="starts_with"?`Nevalida karaktraro: devas komenci\\u011Di per "${t.prefix}"`:t.format==="ends_with"?`Nevalida karaktraro: devas fini\\u011Di per "${t.suffix}"`:t.format==="includes"?`Nevalida karaktraro: devas inkluzivi "${t.includes}"`:t.format==="regex"?`Nevalida karaktraro: devas kongrui kun la modelo ${t.pattern}`:`Nevalida ${n[t.format]??i.format}`}case"not_multiple_of":return`Nevalida nombro: devas esti oblo de ${i.divisor}`;case"unrecognized_keys":return`Nekonata${i.keys.length>1?"j":""} \\u015Dlosilo${i.keys.length>1?"j":""}: ${f(i.keys,", ")}`;case"invalid_key":return`Nevalida \\u015Dlosilo en ${i.origin}`;case"invalid_union":return"Nevalida enigo";case"invalid_element":return`Nevalida valoro en ${i.origin}`;default:return"Nevalida enigo"}}}});function Iu(){return{localeError:vm()}}var vm,ju=S(()=>{P();vm=()=>{let e={string:{unit:"caracteres",verb:"tener"},file:{unit:"bytes",verb:"tener"},array:{unit:"elementos",verb:"tener"},set:{unit:"elementos",verb:"tener"}};function r(t){return e[t]??null}let n=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"n\\xFAmero";case"object":{if(Array.isArray(t))return"arreglo";if(t===null)return"nulo";if(Object.getPrototypeOf(t)!==Object.prototype)return t.constructor.name}}return o},i={regex:"entrada",email:"direcci\\xF3n de correo electr\\xF3nico",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"fecha y hora ISO",date:"fecha ISO",time:"hora ISO",duration:"duraci\\xF3n ISO",ipv4:"direcci\\xF3n IPv4",ipv6:"direcci\\xF3n IPv6",cidrv4:"rango IPv4",cidrv6:"rango IPv6",base64:"cadena codificada en base64",base64url:"URL codificada en base64",json_string:"cadena JSON",e164:"n\\xFAmero E.164",jwt:"JWT",template_literal:"entrada"};return t=>{switch(t.code){case"invalid_type":return`Entrada inv\\xE1lida: se esperaba ${t.expected}, recibido ${n(t.input)}`;case"invalid_value":return t.values.length===1?`Entrada inv\\xE1lida: se esperaba ${_(t.values[0])}`:`Opci\\xF3n inv\\xE1lida: se esperaba una de ${f(t.values,"|")}`;case"too_big":{let o=t.inclusive?"<=":"<",a=r(t.origin);return a?`Demasiado grande: se esperaba que ${t.origin??"valor"} tuviera ${o}${t.maximum.toString()} ${a.unit??"elementos"}`:`Demasiado grande: se esperaba que ${t.origin??"valor"} fuera ${o}${t.maximum.toString()}`}case"too_small":{let o=t.inclusive?">=":">",a=r(t.origin);return a?`Demasiado peque\\xF1o: se esperaba que ${t.origin} tuviera ${o}${t.minimum.toString()} ${a.unit}`:`Demasiado peque\\xF1o: se esperaba que ${t.origin} fuera ${o}${t.minimum.toString()}`}case"invalid_format":{let o=t;return o.format==="starts_with"?`Cadena inv\\xE1lida: debe comenzar con "${o.prefix}"`:o.format==="ends_with"?`Cadena inv\\xE1lida: debe terminar en "${o.suffix}"`:o.format==="includes"?`Cadena inv\\xE1lida: debe incluir "${o.includes}"`:o.format==="regex"?`Cadena inv\\xE1lida: debe coincidir con el patr\\xF3n ${o.pattern}`:`Inv\\xE1lido ${i[o.format]??t.format}`}case"not_multiple_of":return`N\\xFAmero inv\\xE1lido: debe ser m\\xFAltiplo de ${t.divisor}`;case"unrecognized_keys":return`Llave${t.keys.length>1?"s":""} desconocida${t.keys.length>1?"s":""}: ${f(t.keys,", ")}`;case"invalid_key":return`Llave inv\\xE1lida en ${t.origin}`;case"invalid_union":return"Entrada inv\\xE1lida";case"invalid_element":return`Valor inv\\xE1lido en ${t.origin}`;default:return"Entrada inv\\xE1lida"}}}});function Pu(){return{localeError:bm()}}var bm,Tu=S(()=>{P();bm=()=>{let e={string:{unit:"\\u06A9\\u0627\\u0631\\u0627\\u06A9\\u062A\\u0631",verb:"\\u062F\\u0627\\u0634\\u062A\\u0647 \\u0628\\u0627\\u0634\\u062F"},file:{unit:"\\u0628\\u0627\\u06CC\\u062A",verb:"\\u062F\\u0627\\u0634\\u062A\\u0647 \\u0628\\u0627\\u0634\\u062F"},array:{unit:"\\u0622\\u06CC\\u062A\\u0645",verb:"\\u062F\\u0627\\u0634\\u062A\\u0647 \\u0628\\u0627\\u0634\\u062F"},set:{unit:"\\u0622\\u06CC\\u062A\\u0645",verb:"\\u062F\\u0627\\u0634\\u062A\\u0647 \\u0628\\u0627\\u0634\\u062F"}};function r(t){return e[t]??null}let n=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"\\u0639\\u062F\\u062F";case"object":{if(Array.isArray(t))return"\\u0622\\u0631\\u0627\\u06CC\\u0647";if(t===null)return"null";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"\\u0648\\u0631\\u0648\\u062F\\u06CC",email:"\\u0622\\u062F\\u0631\\u0633 \\u0627\\u06CC\\u0645\\u06CC\\u0644",url:"URL",emoji:"\\u0627\\u06CC\\u0645\\u0648\\u062C\\u06CC",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"\\u062A\\u0627\\u0631\\u06CC\\u062E \\u0648 \\u0632\\u0645\\u0627\\u0646 \\u0627\\u06CC\\u0632\\u0648",date:"\\u062A\\u0627\\u0631\\u06CC\\u062E \\u0627\\u06CC\\u0632\\u0648",time:"\\u0632\\u0645\\u0627\\u0646 \\u0627\\u06CC\\u0632\\u0648",duration:"\\u0645\\u062F\\u062A \\u0632\\u0645\\u0627\\u0646 \\u0627\\u06CC\\u0632\\u0648",ipv4:"IPv4 \\u0622\\u062F\\u0631\\u0633",ipv6:"IPv6 \\u0622\\u062F\\u0631\\u0633",cidrv4:"IPv4 \\u062F\\u0627\\u0645\\u0646\\u0647",cidrv6:"IPv6 \\u062F\\u0627\\u0645\\u0646\\u0647",base64:"base64-encoded \\u0631\\u0634\\u062A\\u0647",base64url:"base64url-encoded \\u0631\\u0634\\u062A\\u0647",json_string:"JSON \\u0631\\u0634\\u062A\\u0647",e164:"E.164 \\u0639\\u062F\\u062F",jwt:"JWT",template_literal:"\\u0648\\u0631\\u0648\\u062F\\u06CC"};return t=>{switch(t.code){case"invalid_type":return`\\u0648\\u0631\\u0648\\u062F\\u06CC \\u0646\\u0627\\u0645\\u0639\\u062A\\u0628\\u0631: \\u0645\\u06CC\\u200C\\u0628\\u0627\\u06CC\\u0633\\u062A ${t.expected} \\u0645\\u06CC\\u200C\\u0628\\u0648\\u062F\\u060C ${n(t.input)} \\u062F\\u0631\\u06CC\\u0627\\u0641\\u062A \\u0634\\u062F`;case"invalid_value":return t.values.length===1?`\\u0648\\u0631\\u0648\\u062F\\u06CC \\u0646\\u0627\\u0645\\u0639\\u062A\\u0628\\u0631: \\u0645\\u06CC\\u200C\\u0628\\u0627\\u06CC\\u0633\\u062A ${_(t.values[0])} \\u0645\\u06CC\\u200C\\u0628\\u0648\\u062F`:`\\u06AF\\u0632\\u06CC\\u0646\\u0647 \\u0646\\u0627\\u0645\\u0639\\u062A\\u0628\\u0631: \\u0645\\u06CC\\u200C\\u0628\\u0627\\u06CC\\u0633\\u062A \\u06CC\\u06A9\\u06CC \\u0627\\u0632 ${f(t.values,"|")} \\u0645\\u06CC\\u200C\\u0628\\u0648\\u062F`;case"too_big":{let o=t.inclusive?"<=":"<",a=r(t.origin);return a?`\\u062E\\u06CC\\u0644\\u06CC \\u0628\\u0632\\u0631\\u06AF: ${t.origin??"\\u0645\\u0642\\u062F\\u0627\\u0631"} \\u0628\\u0627\\u06CC\\u062F ${o}${t.maximum.toString()} ${a.unit??"\\u0639\\u0646\\u0635\\u0631"} \\u0628\\u0627\\u0634\\u062F`:`\\u062E\\u06CC\\u0644\\u06CC \\u0628\\u0632\\u0631\\u06AF: ${t.origin??"\\u0645\\u0642\\u062F\\u0627\\u0631"} \\u0628\\u0627\\u06CC\\u062F ${o}${t.maximum.toString()} \\u0628\\u0627\\u0634\\u062F`}case"too_small":{let o=t.inclusive?">=":">",a=r(t.origin);return a?`\\u062E\\u06CC\\u0644\\u06CC \\u06A9\\u0648\\u0686\\u06A9: ${t.origin} \\u0628\\u0627\\u06CC\\u062F ${o}${t.minimum.toString()} ${a.unit} \\u0628\\u0627\\u0634\\u062F`:`\\u062E\\u06CC\\u0644\\u06CC \\u06A9\\u0648\\u0686\\u06A9: ${t.origin} \\u0628\\u0627\\u06CC\\u062F ${o}${t.minimum.toString()} \\u0628\\u0627\\u0634\\u062F`}case"invalid_format":{let o=t;return o.format==="starts_with"?`\\u0631\\u0634\\u062A\\u0647 \\u0646\\u0627\\u0645\\u0639\\u062A\\u0628\\u0631: \\u0628\\u0627\\u06CC\\u062F \\u0628\\u0627 "${o.prefix}" \\u0634\\u0631\\u0648\\u0639 \\u0634\\u0648\\u062F`:o.format==="ends_with"?`\\u0631\\u0634\\u062A\\u0647 \\u0646\\u0627\\u0645\\u0639\\u062A\\u0628\\u0631: \\u0628\\u0627\\u06CC\\u062F \\u0628\\u0627 "${o.suffix}" \\u062A\\u0645\\u0627\\u0645 \\u0634\\u0648\\u062F`:o.format==="includes"?`\\u0631\\u0634\\u062A\\u0647 \\u0646\\u0627\\u0645\\u0639\\u062A\\u0628\\u0631: \\u0628\\u0627\\u06CC\\u062F \\u0634\\u0627\\u0645\\u0644 "${o.includes}" \\u0628\\u0627\\u0634\\u062F`:o.format==="regex"?`\\u0631\\u0634\\u062A\\u0647 \\u0646\\u0627\\u0645\\u0639\\u062A\\u0628\\u0631: \\u0628\\u0627\\u06CC\\u062F \\u0628\\u0627 \\u0627\\u0644\\u06AF\\u0648\\u06CC ${o.pattern} \\u0645\\u0637\\u0627\\u0628\\u0642\\u062A \\u062F\\u0627\\u0634\\u062A\\u0647 \\u0628\\u0627\\u0634\\u062F`:`${i[o.format]??t.format} \\u0646\\u0627\\u0645\\u0639\\u062A\\u0628\\u0631`}case"not_multiple_of":return`\\u0639\\u062F\\u062F \\u0646\\u0627\\u0645\\u0639\\u062A\\u0628\\u0631: \\u0628\\u0627\\u06CC\\u062F \\u0645\\u0636\\u0631\\u0628 ${t.divisor} \\u0628\\u0627\\u0634\\u062F`;case"unrecognized_keys":return`\\u06A9\\u0644\\u06CC\\u062F${t.keys.length>1?"\\u0647\\u0627\\u06CC":""} \\u0646\\u0627\\u0634\\u0646\\u0627\\u0633: ${f(t.keys,", ")}`;case"invalid_key":return`\\u06A9\\u0644\\u06CC\\u062F \\u0646\\u0627\\u0634\\u0646\\u0627\\u0633 \\u062F\\u0631 ${t.origin}`;case"invalid_union":return"\\u0648\\u0631\\u0648\\u062F\\u06CC \\u0646\\u0627\\u0645\\u0639\\u062A\\u0628\\u0631";case"invalid_element":return`\\u0645\\u0642\\u062F\\u0627\\u0631 \\u0646\\u0627\\u0645\\u0639\\u062A\\u0628\\u0631 \\u062F\\u0631 ${t.origin}`;default:return"\\u0648\\u0631\\u0648\\u062F\\u06CC \\u0646\\u0627\\u0645\\u0639\\u062A\\u0628\\u0631"}}}});function Ou(){return{localeError:ym()}}var ym,Nu=S(()=>{P();ym=()=>{let e={string:{unit:"merkki\\xE4",subject:"merkkijonon"},file:{unit:"tavua",subject:"tiedoston"},array:{unit:"alkiota",subject:"listan"},set:{unit:"alkiota",subject:"joukon"},number:{unit:"",subject:"luvun"},bigint:{unit:"",subject:"suuren kokonaisluvun"},int:{unit:"",subject:"kokonaisluvun"},date:{unit:"",subject:"p\\xE4iv\\xE4m\\xE4\\xE4r\\xE4n"}};function r(t){return e[t]??null}let n=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"number";case"object":{if(Array.isArray(t))return"array";if(t===null)return"null";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"s\\xE4\\xE4nn\\xF6llinen lauseke",email:"s\\xE4hk\\xF6postiosoite",url:"URL-osoite",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO-aikaleima",date:"ISO-p\\xE4iv\\xE4m\\xE4\\xE4r\\xE4",time:"ISO-aika",duration:"ISO-kesto",ipv4:"IPv4-osoite",ipv6:"IPv6-osoite",cidrv4:"IPv4-alue",cidrv6:"IPv6-alue",base64:"base64-koodattu merkkijono",base64url:"base64url-koodattu merkkijono",json_string:"JSON-merkkijono",e164:"E.164-luku",jwt:"JWT",template_literal:"templaattimerkkijono"};return t=>{switch(t.code){case"invalid_type":return`Virheellinen tyyppi: odotettiin ${t.expected}, oli ${n(t.input)}`;case"invalid_value":return t.values.length===1?`Virheellinen sy\\xF6te: t\\xE4ytyy olla ${_(t.values[0])}`:`Virheellinen valinta: t\\xE4ytyy olla yksi seuraavista: ${f(t.values,"|")}`;case"too_big":{let o=t.inclusive?"<=":"<",a=r(t.origin);return a?`Liian suuri: ${a.subject} t\\xE4ytyy olla ${o}${t.maximum.toString()} ${a.unit}`.trim():`Liian suuri: arvon t\\xE4ytyy olla ${o}${t.maximum.toString()}`}case"too_small":{let o=t.inclusive?">=":">",a=r(t.origin);return a?`Liian pieni: ${a.subject} t\\xE4ytyy olla ${o}${t.minimum.toString()} ${a.unit}`.trim():`Liian pieni: arvon t\\xE4ytyy olla ${o}${t.minimum.toString()}`}case"invalid_format":{let o=t;return o.format==="starts_with"?`Virheellinen sy\\xF6te: t\\xE4ytyy alkaa "${o.prefix}"`:o.format==="ends_with"?`Virheellinen sy\\xF6te: t\\xE4ytyy loppua "${o.suffix}"`:o.format==="includes"?`Virheellinen sy\\xF6te: t\\xE4ytyy sis\\xE4lt\\xE4\\xE4 "${o.includes}"`:o.format==="regex"?`Virheellinen sy\\xF6te: t\\xE4ytyy vastata s\\xE4\\xE4nn\\xF6llist\\xE4 lauseketta ${o.pattern}`:`Virheellinen ${i[o.format]??t.format}`}case"not_multiple_of":return`Virheellinen luku: t\\xE4ytyy olla luvun ${t.divisor} monikerta`;case"unrecognized_keys":return`${t.keys.length>1?"Tuntemattomat avaimet":"Tuntematon avain"}: ${f(t.keys,", ")}`;case"invalid_key":return"Virheellinen avain tietueessa";case"invalid_union":return"Virheellinen unioni";case"invalid_element":return"Virheellinen arvo joukossa";default:return"Virheellinen sy\\xF6te"}}}});function Uu(){return{localeError:_m()}}var _m,Eu=S(()=>{P();_m=()=>{let e={string:{unit:"caract\\xE8res",verb:"avoir"},file:{unit:"octets",verb:"avoir"},array:{unit:"\\xE9l\\xE9ments",verb:"avoir"},set:{unit:"\\xE9l\\xE9ments",verb:"avoir"}};function r(t){return e[t]??null}let n=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"nombre";case"object":{if(Array.isArray(t))return"tableau";if(t===null)return"null";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"entr\\xE9e",email:"adresse e-mail",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"date et heure ISO",date:"date ISO",time:"heure ISO",duration:"dur\\xE9e ISO",ipv4:"adresse IPv4",ipv6:"adresse IPv6",cidrv4:"plage IPv4",cidrv6:"plage IPv6",base64:"cha\\xEEne encod\\xE9e en base64",base64url:"cha\\xEEne encod\\xE9e en base64url",json_string:"cha\\xEEne JSON",e164:"num\\xE9ro E.164",jwt:"JWT",template_literal:"entr\\xE9e"};return t=>{switch(t.code){case"invalid_type":return`Entr\\xE9e invalide : ${t.expected} attendu, ${n(t.input)} re\\xE7u`;case"invalid_value":return t.values.length===1?`Entr\\xE9e invalide : ${_(t.values[0])} attendu`:`Option invalide : une valeur parmi ${f(t.values,"|")} attendue`;case"too_big":{let o=t.inclusive?"<=":"<",a=r(t.origin);return a?`Trop grand : ${t.origin??"valeur"} doit ${a.verb} ${o}${t.maximum.toString()} ${a.unit??"\\xE9l\\xE9ment(s)"}`:`Trop grand : ${t.origin??"valeur"} doit \\xEAtre ${o}${t.maximum.toString()}`}case"too_small":{let o=t.inclusive?">=":">",a=r(t.origin);return a?`Trop petit : ${t.origin} doit ${a.verb} ${o}${t.minimum.toString()} ${a.unit}`:`Trop petit : ${t.origin} doit \\xEAtre ${o}${t.minimum.toString()}`}case"invalid_format":{let o=t;return o.format==="starts_with"?`Cha\\xEEne invalide : doit commencer par "${o.prefix}"`:o.format==="ends_with"?`Cha\\xEEne invalide : doit se terminer par "${o.suffix}"`:o.format==="includes"?`Cha\\xEEne invalide : doit inclure "${o.includes}"`:o.format==="regex"?`Cha\\xEEne invalide : doit correspondre au mod\\xE8le ${o.pattern}`:`${i[o.format]??t.format} invalide`}case"not_multiple_of":return`Nombre invalide : doit \\xEAtre un multiple de ${t.divisor}`;case"unrecognized_keys":return`Cl\\xE9${t.keys.length>1?"s":""} non reconnue${t.keys.length>1?"s":""} : ${f(t.keys,", ")}`;case"invalid_key":return`Cl\\xE9 invalide dans ${t.origin}`;case"invalid_union":return"Entr\\xE9e invalide";case"invalid_element":return`Valeur invalide dans ${t.origin}`;default:return"Entr\\xE9e invalide"}}}});function Du(){return{localeError:xm()}}var xm,Ru=S(()=>{P();xm=()=>{let e={string:{unit:"caract\\xE8res",verb:"avoir"},file:{unit:"octets",verb:"avoir"},array:{unit:"\\xE9l\\xE9ments",verb:"avoir"},set:{unit:"\\xE9l\\xE9ments",verb:"avoir"}};function r(t){return e[t]??null}let n=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"number";case"object":{if(Array.isArray(t))return"array";if(t===null)return"null";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"entr\\xE9e",email:"adresse courriel",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"date-heure ISO",date:"date ISO",time:"heure ISO",duration:"dur\\xE9e ISO",ipv4:"adresse IPv4",ipv6:"adresse IPv6",cidrv4:"plage IPv4",cidrv6:"plage IPv6",base64:"cha\\xEEne encod\\xE9e en base64",base64url:"cha\\xEEne encod\\xE9e en base64url",json_string:"cha\\xEEne JSON",e164:"num\\xE9ro E.164",jwt:"JWT",template_literal:"entr\\xE9e"};return t=>{switch(t.code){case"invalid_type":return`Entr\\xE9e invalide : attendu ${t.expected}, re\\xE7u ${n(t.input)}`;case"invalid_value":return t.values.length===1?`Entr\\xE9e invalide : attendu ${_(t.values[0])}`:`Option invalide : attendu l\'une des valeurs suivantes ${f(t.values,"|")}`;case"too_big":{let o=t.inclusive?"\\u2264":"<",a=r(t.origin);return a?`Trop grand : attendu que ${t.origin??"la valeur"} ait ${o}${t.maximum.toString()} ${a.unit}`:`Trop grand : attendu que ${t.origin??"la valeur"} soit ${o}${t.maximum.toString()}`}case"too_small":{let o=t.inclusive?"\\u2265":">",a=r(t.origin);return a?`Trop petit : attendu que ${t.origin} ait ${o}${t.minimum.toString()} ${a.unit}`:`Trop petit : attendu que ${t.origin} soit ${o}${t.minimum.toString()}`}case"invalid_format":{let o=t;return o.format==="starts_with"?`Cha\\xEEne invalide : doit commencer par "${o.prefix}"`:o.format==="ends_with"?`Cha\\xEEne invalide : doit se terminer par "${o.suffix}"`:o.format==="includes"?`Cha\\xEEne invalide : doit inclure "${o.includes}"`:o.format==="regex"?`Cha\\xEEne invalide : doit correspondre au motif ${o.pattern}`:`${i[o.format]??t.format} invalide`}case"not_multiple_of":return`Nombre invalide : doit \\xEAtre un multiple de ${t.divisor}`;case"unrecognized_keys":return`Cl\\xE9${t.keys.length>1?"s":""} non reconnue${t.keys.length>1?"s":""} : ${f(t.keys,", ")}`;case"invalid_key":return`Cl\\xE9 invalide dans ${t.origin}`;case"invalid_union":return"Entr\\xE9e invalide";case"invalid_element":return`Valeur invalide dans ${t.origin}`;default:return"Entr\\xE9e invalide"}}}});function Zu(){return{localeError:$m()}}var $m,Au=S(()=>{P();$m=()=>{let e={string:{unit:"\\u05D0\\u05D5\\u05EA\\u05D9\\u05D5\\u05EA",verb:"\\u05DC\\u05DB\\u05DC\\u05D5\\u05DC"},file:{unit:"\\u05D1\\u05D9\\u05D9\\u05D8\\u05D9\\u05DD",verb:"\\u05DC\\u05DB\\u05DC\\u05D5\\u05DC"},array:{unit:"\\u05E4\\u05E8\\u05D9\\u05D8\\u05D9\\u05DD",verb:"\\u05DC\\u05DB\\u05DC\\u05D5\\u05DC"},set:{unit:"\\u05E4\\u05E8\\u05D9\\u05D8\\u05D9\\u05DD",verb:"\\u05DC\\u05DB\\u05DC\\u05D5\\u05DC"}};function r(t){return e[t]??null}let n=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"number";case"object":{if(Array.isArray(t))return"array";if(t===null)return"null";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"\\u05E7\\u05DC\\u05D8",email:"\\u05DB\\u05EA\\u05D5\\u05D1\\u05EA \\u05D0\\u05D9\\u05DE\\u05D9\\u05D9\\u05DC",url:"\\u05DB\\u05EA\\u05D5\\u05D1\\u05EA \\u05E8\\u05E9\\u05EA",emoji:"\\u05D0\\u05D9\\u05DE\\u05D5\\u05D2\'\\u05D9",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"\\u05EA\\u05D0\\u05E8\\u05D9\\u05DA \\u05D5\\u05D6\\u05DE\\u05DF ISO",date:"\\u05EA\\u05D0\\u05E8\\u05D9\\u05DA ISO",time:"\\u05D6\\u05DE\\u05DF ISO",duration:"\\u05DE\\u05E9\\u05DA \\u05D6\\u05DE\\u05DF ISO",ipv4:"\\u05DB\\u05EA\\u05D5\\u05D1\\u05EA IPv4",ipv6:"\\u05DB\\u05EA\\u05D5\\u05D1\\u05EA IPv6",cidrv4:"\\u05D8\\u05D5\\u05D5\\u05D7 IPv4",cidrv6:"\\u05D8\\u05D5\\u05D5\\u05D7 IPv6",base64:"\\u05DE\\u05D7\\u05E8\\u05D5\\u05D6\\u05EA \\u05D1\\u05D1\\u05E1\\u05D9\\u05E1 64",base64url:"\\u05DE\\u05D7\\u05E8\\u05D5\\u05D6\\u05EA \\u05D1\\u05D1\\u05E1\\u05D9\\u05E1 64 \\u05DC\\u05DB\\u05EA\\u05D5\\u05D1\\u05D5\\u05EA \\u05E8\\u05E9\\u05EA",json_string:"\\u05DE\\u05D7\\u05E8\\u05D5\\u05D6\\u05EA JSON",e164:"\\u05DE\\u05E1\\u05E4\\u05E8 E.164",jwt:"JWT",template_literal:"\\u05E7\\u05DC\\u05D8"};return t=>{switch(t.code){case"invalid_type":return`\\u05E7\\u05DC\\u05D8 \\u05DC\\u05D0 \\u05EA\\u05E7\\u05D9\\u05DF: \\u05E6\\u05E8\\u05D9\\u05DA ${t.expected}, \\u05D4\\u05EA\\u05E7\\u05D1\\u05DC ${n(t.input)}`;case"invalid_value":return t.values.length===1?`\\u05E7\\u05DC\\u05D8 \\u05DC\\u05D0 \\u05EA\\u05E7\\u05D9\\u05DF: \\u05E6\\u05E8\\u05D9\\u05DA ${_(t.values[0])}`:`\\u05E7\\u05DC\\u05D8 \\u05DC\\u05D0 \\u05EA\\u05E7\\u05D9\\u05DF: \\u05E6\\u05E8\\u05D9\\u05DA \\u05D0\\u05D7\\u05EA \\u05DE\\u05D4\\u05D0\\u05E4\\u05E9\\u05E8\\u05D5\\u05D9\\u05D5\\u05EA ${f(t.values,"|")}`;case"too_big":{let o=t.inclusive?"<=":"<",a=r(t.origin);return a?`\\u05D2\\u05D3\\u05D5\\u05DC \\u05DE\\u05D3\\u05D9: ${t.origin??"value"} \\u05E6\\u05E8\\u05D9\\u05DA \\u05DC\\u05D4\\u05D9\\u05D5\\u05EA ${o}${t.maximum.toString()} ${a.unit??"elements"}`:`\\u05D2\\u05D3\\u05D5\\u05DC \\u05DE\\u05D3\\u05D9: ${t.origin??"value"} \\u05E6\\u05E8\\u05D9\\u05DA \\u05DC\\u05D4\\u05D9\\u05D5\\u05EA ${o}${t.maximum.toString()}`}case"too_small":{let o=t.inclusive?">=":">",a=r(t.origin);return a?`\\u05E7\\u05D8\\u05DF \\u05DE\\u05D3\\u05D9: ${t.origin} \\u05E6\\u05E8\\u05D9\\u05DA \\u05DC\\u05D4\\u05D9\\u05D5\\u05EA ${o}${t.minimum.toString()} ${a.unit}`:`\\u05E7\\u05D8\\u05DF \\u05DE\\u05D3\\u05D9: ${t.origin} \\u05E6\\u05E8\\u05D9\\u05DA \\u05DC\\u05D4\\u05D9\\u05D5\\u05EA ${o}${t.minimum.toString()}`}case"invalid_format":{let o=t;return o.format==="starts_with"?`\\u05DE\\u05D7\\u05E8\\u05D5\\u05D6\\u05EA \\u05DC\\u05D0 \\u05EA\\u05E7\\u05D9\\u05E0\\u05D4: \\u05D7\\u05D9\\u05D9\\u05D1\\u05EA \\u05DC\\u05D4\\u05EA\\u05D7\\u05D9\\u05DC \\u05D1"${o.prefix}"`:o.format==="ends_with"?`\\u05DE\\u05D7\\u05E8\\u05D5\\u05D6\\u05EA \\u05DC\\u05D0 \\u05EA\\u05E7\\u05D9\\u05E0\\u05D4: \\u05D7\\u05D9\\u05D9\\u05D1\\u05EA \\u05DC\\u05D4\\u05E1\\u05EA\\u05D9\\u05D9\\u05DD \\u05D1 "${o.suffix}"`:o.format==="includes"?`\\u05DE\\u05D7\\u05E8\\u05D5\\u05D6\\u05EA \\u05DC\\u05D0 \\u05EA\\u05E7\\u05D9\\u05E0\\u05D4: \\u05D7\\u05D9\\u05D9\\u05D1\\u05EA \\u05DC\\u05DB\\u05DC\\u05D5\\u05DC "${o.includes}"`:o.format==="regex"?`\\u05DE\\u05D7\\u05E8\\u05D5\\u05D6\\u05EA \\u05DC\\u05D0 \\u05EA\\u05E7\\u05D9\\u05E0\\u05D4: \\u05D7\\u05D9\\u05D9\\u05D1\\u05EA \\u05DC\\u05D4\\u05EA\\u05D0\\u05D9\\u05DD \\u05DC\\u05EA\\u05D1\\u05E0\\u05D9\\u05EA ${o.pattern}`:`${i[o.format]??t.format} \\u05DC\\u05D0 \\u05EA\\u05E7\\u05D9\\u05DF`}case"not_multiple_of":return`\\u05DE\\u05E1\\u05E4\\u05E8 \\u05DC\\u05D0 \\u05EA\\u05E7\\u05D9\\u05DF: \\u05D7\\u05D9\\u05D9\\u05D1 \\u05DC\\u05D4\\u05D9\\u05D5\\u05EA \\u05DE\\u05DB\\u05E4\\u05DC\\u05D4 \\u05E9\\u05DC ${t.divisor}`;case"unrecognized_keys":return`\\u05DE\\u05E4\\u05EA\\u05D7${t.keys.length>1?"\\u05D5\\u05EA":""} \\u05DC\\u05D0 \\u05DE\\u05D6\\u05D5\\u05D4${t.keys.length>1?"\\u05D9\\u05DD":"\\u05D4"}: ${f(t.keys,", ")}`;case"invalid_key":return`\\u05DE\\u05E4\\u05EA\\u05D7 \\u05DC\\u05D0 \\u05EA\\u05E7\\u05D9\\u05DF \\u05D1${t.origin}`;case"invalid_union":return"\\u05E7\\u05DC\\u05D8 \\u05DC\\u05D0 \\u05EA\\u05E7\\u05D9\\u05DF";case"invalid_element":return`\\u05E2\\u05E8\\u05DA \\u05DC\\u05D0 \\u05EA\\u05E7\\u05D9\\u05DF \\u05D1${t.origin}`;default:return"\\u05E7\\u05DC\\u05D8 \\u05DC\\u05D0 \\u05EA\\u05E7\\u05D9\\u05DF"}}}});function Cu(){return{localeError:zm()}}var zm,Lu=S(()=>{P();zm=()=>{let e={string:{unit:"karakter",verb:"legyen"},file:{unit:"byte",verb:"legyen"},array:{unit:"elem",verb:"legyen"},set:{unit:"elem",verb:"legyen"}};function r(t){return e[t]??null}let n=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"sz\\xE1m";case"object":{if(Array.isArray(t))return"t\\xF6mb";if(t===null)return"null";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"bemenet",email:"email c\\xEDm",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO id\\u0151b\\xE9lyeg",date:"ISO d\\xE1tum",time:"ISO id\\u0151",duration:"ISO id\\u0151intervallum",ipv4:"IPv4 c\\xEDm",ipv6:"IPv6 c\\xEDm",cidrv4:"IPv4 tartom\\xE1ny",cidrv6:"IPv6 tartom\\xE1ny",base64:"base64-k\\xF3dolt string",base64url:"base64url-k\\xF3dolt string",json_string:"JSON string",e164:"E.164 sz\\xE1m",jwt:"JWT",template_literal:"bemenet"};return t=>{switch(t.code){case"invalid_type":return`\\xC9rv\\xE9nytelen bemenet: a v\\xE1rt \\xE9rt\\xE9k ${t.expected}, a kapott \\xE9rt\\xE9k ${n(t.input)}`;case"invalid_value":return t.values.length===1?`\\xC9rv\\xE9nytelen bemenet: a v\\xE1rt \\xE9rt\\xE9k ${_(t.values[0])}`:`\\xC9rv\\xE9nytelen opci\\xF3: valamelyik \\xE9rt\\xE9k v\\xE1rt ${f(t.values,"|")}`;case"too_big":{let o=t.inclusive?"<=":"<",a=r(t.origin);return a?`T\\xFAl nagy: ${t.origin??"\\xE9rt\\xE9k"} m\\xE9rete t\\xFAl nagy ${o}${t.maximum.toString()} ${a.unit??"elem"}`:`T\\xFAl nagy: a bemeneti \\xE9rt\\xE9k ${t.origin??"\\xE9rt\\xE9k"} t\\xFAl nagy: ${o}${t.maximum.toString()}`}case"too_small":{let o=t.inclusive?">=":">",a=r(t.origin);return a?`T\\xFAl kicsi: a bemeneti \\xE9rt\\xE9k ${t.origin} m\\xE9rete t\\xFAl kicsi ${o}${t.minimum.toString()} ${a.unit}`:`T\\xFAl kicsi: a bemeneti \\xE9rt\\xE9k ${t.origin} t\\xFAl kicsi ${o}${t.minimum.toString()}`}case"invalid_format":{let o=t;return o.format==="starts_with"?`\\xC9rv\\xE9nytelen string: "${o.prefix}" \\xE9rt\\xE9kkel kell kezd\\u0151dnie`:o.format==="ends_with"?`\\xC9rv\\xE9nytelen string: "${o.suffix}" \\xE9rt\\xE9kkel kell v\\xE9gz\\u0151dnie`:o.format==="includes"?`\\xC9rv\\xE9nytelen string: "${o.includes}" \\xE9rt\\xE9ket kell tartalmaznia`:o.format==="regex"?`\\xC9rv\\xE9nytelen string: ${o.pattern} mint\\xE1nak kell megfelelnie`:`\\xC9rv\\xE9nytelen ${i[o.format]??t.format}`}case"not_multiple_of":return`\\xC9rv\\xE9nytelen sz\\xE1m: ${t.divisor} t\\xF6bbsz\\xF6r\\xF6s\\xE9nek kell lennie`;case"unrecognized_keys":return`Ismeretlen kulcs${t.keys.length>1?"s":""}: ${f(t.keys,", ")}`;case"invalid_key":return`\\xC9rv\\xE9nytelen kulcs ${t.origin}`;case"invalid_union":return"\\xC9rv\\xE9nytelen bemenet";case"invalid_element":return`\\xC9rv\\xE9nytelen \\xE9rt\\xE9k: ${t.origin}`;default:return"\\xC9rv\\xE9nytelen bemenet"}}}});function Mu(){return{localeError:km()}}var km,qu=S(()=>{P();km=()=>{let e={string:{unit:"karakter",verb:"memiliki"},file:{unit:"byte",verb:"memiliki"},array:{unit:"item",verb:"memiliki"},set:{unit:"item",verb:"memiliki"}};function r(t){return e[t]??null}let n=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"number";case"object":{if(Array.isArray(t))return"array";if(t===null)return"null";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"input",email:"alamat email",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"tanggal dan waktu format ISO",date:"tanggal format ISO",time:"jam format ISO",duration:"durasi format ISO",ipv4:"alamat IPv4",ipv6:"alamat IPv6",cidrv4:"rentang alamat IPv4",cidrv6:"rentang alamat IPv6",base64:"string dengan enkode base64",base64url:"string dengan enkode base64url",json_string:"string JSON",e164:"angka E.164",jwt:"JWT",template_literal:"input"};return t=>{switch(t.code){case"invalid_type":return`Input tidak valid: diharapkan ${t.expected}, diterima ${n(t.input)}`;case"invalid_value":return t.values.length===1?`Input tidak valid: diharapkan ${_(t.values[0])}`:`Pilihan tidak valid: diharapkan salah satu dari ${f(t.values,"|")}`;case"too_big":{let o=t.inclusive?"<=":"<",a=r(t.origin);return a?`Terlalu besar: diharapkan ${t.origin??"value"} memiliki ${o}${t.maximum.toString()} ${a.unit??"elemen"}`:`Terlalu besar: diharapkan ${t.origin??"value"} menjadi ${o}${t.maximum.toString()}`}case"too_small":{let o=t.inclusive?">=":">",a=r(t.origin);return a?`Terlalu kecil: diharapkan ${t.origin} memiliki ${o}${t.minimum.toString()} ${a.unit}`:`Terlalu kecil: diharapkan ${t.origin} menjadi ${o}${t.minimum.toString()}`}case"invalid_format":{let o=t;return o.format==="starts_with"?`String tidak valid: harus dimulai dengan "${o.prefix}"`:o.format==="ends_with"?`String tidak valid: harus berakhir dengan "${o.suffix}"`:o.format==="includes"?`String tidak valid: harus menyertakan "${o.includes}"`:o.format==="regex"?`String tidak valid: harus sesuai pola ${o.pattern}`:`${i[o.format]??t.format} tidak valid`}case"not_multiple_of":return`Angka tidak valid: harus kelipatan dari ${t.divisor}`;case"unrecognized_keys":return`Kunci tidak dikenali ${t.keys.length>1?"s":""}: ${f(t.keys,", ")}`;case"invalid_key":return`Kunci tidak valid di ${t.origin}`;case"invalid_union":return"Input tidak valid";case"invalid_element":return`Nilai tidak valid di ${t.origin}`;default:return"Input tidak valid"}}}});function Fu(){return{localeError:Sm()}}var Sm,Hu=S(()=>{P();Sm=()=>{let e={string:{unit:"caratteri",verb:"avere"},file:{unit:"byte",verb:"avere"},array:{unit:"elementi",verb:"avere"},set:{unit:"elementi",verb:"avere"}};function r(t){return e[t]??null}let n=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"numero";case"object":{if(Array.isArray(t))return"vettore";if(t===null)return"null";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"input",email:"indirizzo email",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"data e ora ISO",date:"data ISO",time:"ora ISO",duration:"durata ISO",ipv4:"indirizzo IPv4",ipv6:"indirizzo IPv6",cidrv4:"intervallo IPv4",cidrv6:"intervallo IPv6",base64:"stringa codificata in base64",base64url:"URL codificata in base64",json_string:"stringa JSON",e164:"numero E.164",jwt:"JWT",template_literal:"input"};return t=>{switch(t.code){case"invalid_type":return`Input non valido: atteso ${t.expected}, ricevuto ${n(t.input)}`;case"invalid_value":return t.values.length===1?`Input non valido: atteso ${_(t.values[0])}`:`Opzione non valida: atteso uno tra ${f(t.values,"|")}`;case"too_big":{let o=t.inclusive?"<=":"<",a=r(t.origin);return a?`Troppo grande: ${t.origin??"valore"} deve avere ${o}${t.maximum.toString()} ${a.unit??"elementi"}`:`Troppo grande: ${t.origin??"valore"} deve essere ${o}${t.maximum.toString()}`}case"too_small":{let o=t.inclusive?">=":">",a=r(t.origin);return a?`Troppo piccolo: ${t.origin} deve avere ${o}${t.minimum.toString()} ${a.unit}`:`Troppo piccolo: ${t.origin} deve essere ${o}${t.minimum.toString()}`}case"invalid_format":{let o=t;return o.format==="starts_with"?`Stringa non valida: deve iniziare con "${o.prefix}"`:o.format==="ends_with"?`Stringa non valida: deve terminare con "${o.suffix}"`:o.format==="includes"?`Stringa non valida: deve includere "${o.includes}"`:o.format==="regex"?`Stringa non valida: deve corrispondere al pattern ${o.pattern}`:`Invalid ${i[o.format]??t.format}`}case"not_multiple_of":return`Numero non valido: deve essere un multiplo di ${t.divisor}`;case"unrecognized_keys":return`Chiav${t.keys.length>1?"i":"e"} non riconosciut${t.keys.length>1?"e":"a"}: ${f(t.keys,", ")}`;case"invalid_key":return`Chiave non valida in ${t.origin}`;case"invalid_union":return"Input non valido";case"invalid_element":return`Valore non valido in ${t.origin}`;default:return"Input non valido"}}}});function Vu(){return{localeError:wm()}}var wm,Ju=S(()=>{P();wm=()=>{let e={string:{unit:"\\u6587\\u5B57",verb:"\\u3067\\u3042\\u308B"},file:{unit:"\\u30D0\\u30A4\\u30C8",verb:"\\u3067\\u3042\\u308B"},array:{unit:"\\u8981\\u7D20",verb:"\\u3067\\u3042\\u308B"},set:{unit:"\\u8981\\u7D20",verb:"\\u3067\\u3042\\u308B"}};function r(t){return e[t]??null}let n=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"\\u6570\\u5024";case"object":{if(Array.isArray(t))return"\\u914D\\u5217";if(t===null)return"null";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"\\u5165\\u529B\\u5024",email:"\\u30E1\\u30FC\\u30EB\\u30A2\\u30C9\\u30EC\\u30B9",url:"URL",emoji:"\\u7D75\\u6587\\u5B57",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO\\u65E5\\u6642",date:"ISO\\u65E5\\u4ED8",time:"ISO\\u6642\\u523B",duration:"ISO\\u671F\\u9593",ipv4:"IPv4\\u30A2\\u30C9\\u30EC\\u30B9",ipv6:"IPv6\\u30A2\\u30C9\\u30EC\\u30B9",cidrv4:"IPv4\\u7BC4\\u56F2",cidrv6:"IPv6\\u7BC4\\u56F2",base64:"base64\\u30A8\\u30F3\\u30B3\\u30FC\\u30C9\\u6587\\u5B57\\u5217",base64url:"base64url\\u30A8\\u30F3\\u30B3\\u30FC\\u30C9\\u6587\\u5B57\\u5217",json_string:"JSON\\u6587\\u5B57\\u5217",e164:"E.164\\u756A\\u53F7",jwt:"JWT",template_literal:"\\u5165\\u529B\\u5024"};return t=>{switch(t.code){case"invalid_type":return`\\u7121\\u52B9\\u306A\\u5165\\u529B: ${t.expected}\\u304C\\u671F\\u5F85\\u3055\\u308C\\u307E\\u3057\\u305F\\u304C\\u3001${n(t.input)}\\u304C\\u5165\\u529B\\u3055\\u308C\\u307E\\u3057\\u305F`;case"invalid_value":return t.values.length===1?`\\u7121\\u52B9\\u306A\\u5165\\u529B: ${_(t.values[0])}\\u304C\\u671F\\u5F85\\u3055\\u308C\\u307E\\u3057\\u305F`:`\\u7121\\u52B9\\u306A\\u9078\\u629E: ${f(t.values,"\\u3001")}\\u306E\\u3044\\u305A\\u308C\\u304B\\u3067\\u3042\\u308B\\u5FC5\\u8981\\u304C\\u3042\\u308A\\u307E\\u3059`;case"too_big":{let o=t.inclusive?"\\u4EE5\\u4E0B\\u3067\\u3042\\u308B":"\\u3088\\u308A\\u5C0F\\u3055\\u3044",a=r(t.origin);return a?`\\u5927\\u304D\\u3059\\u304E\\u308B\\u5024: ${t.origin??"\\u5024"}\\u306F${t.maximum.toString()}${a.unit??"\\u8981\\u7D20"}${o}\\u5FC5\\u8981\\u304C\\u3042\\u308A\\u307E\\u3059`:`\\u5927\\u304D\\u3059\\u304E\\u308B\\u5024: ${t.origin??"\\u5024"}\\u306F${t.maximum.toString()}${o}\\u5FC5\\u8981\\u304C\\u3042\\u308A\\u307E\\u3059`}case"too_small":{let o=t.inclusive?"\\u4EE5\\u4E0A\\u3067\\u3042\\u308B":"\\u3088\\u308A\\u5927\\u304D\\u3044",a=r(t.origin);return a?`\\u5C0F\\u3055\\u3059\\u304E\\u308B\\u5024: ${t.origin}\\u306F${t.minimum.toString()}${a.unit}${o}\\u5FC5\\u8981\\u304C\\u3042\\u308A\\u307E\\u3059`:`\\u5C0F\\u3055\\u3059\\u304E\\u308B\\u5024: ${t.origin}\\u306F${t.minimum.toString()}${o}\\u5FC5\\u8981\\u304C\\u3042\\u308A\\u307E\\u3059`}case"invalid_format":{let o=t;return o.format==="starts_with"?`\\u7121\\u52B9\\u306A\\u6587\\u5B57\\u5217: "${o.prefix}"\\u3067\\u59CB\\u307E\\u308B\\u5FC5\\u8981\\u304C\\u3042\\u308A\\u307E\\u3059`:o.format==="ends_with"?`\\u7121\\u52B9\\u306A\\u6587\\u5B57\\u5217: "${o.suffix}"\\u3067\\u7D42\\u308F\\u308B\\u5FC5\\u8981\\u304C\\u3042\\u308A\\u307E\\u3059`:o.format==="includes"?`\\u7121\\u52B9\\u306A\\u6587\\u5B57\\u5217: "${o.includes}"\\u3092\\u542B\\u3080\\u5FC5\\u8981\\u304C\\u3042\\u308A\\u307E\\u3059`:o.format==="regex"?`\\u7121\\u52B9\\u306A\\u6587\\u5B57\\u5217: \\u30D1\\u30BF\\u30FC\\u30F3${o.pattern}\\u306B\\u4E00\\u81F4\\u3059\\u308B\\u5FC5\\u8981\\u304C\\u3042\\u308A\\u307E\\u3059`:`\\u7121\\u52B9\\u306A${i[o.format]??t.format}`}case"not_multiple_of":return`\\u7121\\u52B9\\u306A\\u6570\\u5024: ${t.divisor}\\u306E\\u500D\\u6570\\u3067\\u3042\\u308B\\u5FC5\\u8981\\u304C\\u3042\\u308A\\u307E\\u3059`;case"unrecognized_keys":return`\\u8A8D\\u8B58\\u3055\\u308C\\u3066\\u3044\\u306A\\u3044\\u30AD\\u30FC${t.keys.length>1?"\\u7FA4":""}: ${f(t.keys,"\\u3001")}`;case"invalid_key":return`${t.origin}\\u5185\\u306E\\u7121\\u52B9\\u306A\\u30AD\\u30FC`;case"invalid_union":return"\\u7121\\u52B9\\u306A\\u5165\\u529B";case"invalid_element":return`${t.origin}\\u5185\\u306E\\u7121\\u52B9\\u306A\\u5024`;default:return"\\u7121\\u52B9\\u306A\\u5165\\u529B"}}}});function Bu(){return{localeError:Im()}}var Im,Ku=S(()=>{P();Im=()=>{let e={string:{unit:"\\u178F\\u17BD\\u17A2\\u1780\\u17D2\\u179F\\u179A",verb:"\\u1782\\u17BD\\u179A\\u1798\\u17B6\\u1793"},file:{unit:"\\u1794\\u17C3",verb:"\\u1782\\u17BD\\u179A\\u1798\\u17B6\\u1793"},array:{unit:"\\u1792\\u17B6\\u178F\\u17BB",verb:"\\u1782\\u17BD\\u179A\\u1798\\u17B6\\u1793"},set:{unit:"\\u1792\\u17B6\\u178F\\u17BB",verb:"\\u1782\\u17BD\\u179A\\u1798\\u17B6\\u1793"}};function r(t){return e[t]??null}let n=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"\\u1798\\u17B7\\u1793\\u1798\\u17C2\\u1793\\u1787\\u17B6\\u179B\\u17C1\\u1781 (NaN)":"\\u179B\\u17C1\\u1781";case"object":{if(Array.isArray(t))return"\\u17A2\\u17B6\\u179A\\u17C1 (Array)";if(t===null)return"\\u1782\\u17D2\\u1798\\u17B6\\u1793\\u178F\\u1798\\u17D2\\u179B\\u17C3 (null)";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"\\u1791\\u17B7\\u1793\\u17D2\\u1793\\u1793\\u17D0\\u1799\\u1794\\u1789\\u17D2\\u1785\\u17BC\\u179B",email:"\\u17A2\\u17B6\\u179F\\u1799\\u178A\\u17D2\\u178B\\u17B6\\u1793\\u17A2\\u17CA\\u17B8\\u1798\\u17C2\\u179B",url:"URL",emoji:"\\u179F\\u1789\\u17D2\\u1789\\u17B6\\u17A2\\u17B6\\u179A\\u1798\\u17D2\\u1798\\u178E\\u17CD",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"\\u1780\\u17B6\\u179B\\u1794\\u179A\\u17B7\\u1785\\u17D2\\u1786\\u17C1\\u1791 \\u1793\\u17B7\\u1784\\u1798\\u17C9\\u17C4\\u1784 ISO",date:"\\u1780\\u17B6\\u179B\\u1794\\u179A\\u17B7\\u1785\\u17D2\\u1786\\u17C1\\u1791 ISO",time:"\\u1798\\u17C9\\u17C4\\u1784 ISO",duration:"\\u179A\\u1799\\u17C8\\u1796\\u17C1\\u179B ISO",ipv4:"\\u17A2\\u17B6\\u179F\\u1799\\u178A\\u17D2\\u178B\\u17B6\\u1793 IPv4",ipv6:"\\u17A2\\u17B6\\u179F\\u1799\\u178A\\u17D2\\u178B\\u17B6\\u1793 IPv6",cidrv4:"\\u178A\\u17C2\\u1793\\u17A2\\u17B6\\u179F\\u1799\\u178A\\u17D2\\u178B\\u17B6\\u1793 IPv4",cidrv6:"\\u178A\\u17C2\\u1793\\u17A2\\u17B6\\u179F\\u1799\\u178A\\u17D2\\u178B\\u17B6\\u1793 IPv6",base64:"\\u1781\\u17D2\\u179F\\u17C2\\u17A2\\u1780\\u17D2\\u179F\\u179A\\u17A2\\u17CA\\u17B7\\u1780\\u17BC\\u178A base64",base64url:"\\u1781\\u17D2\\u179F\\u17C2\\u17A2\\u1780\\u17D2\\u179F\\u179A\\u17A2\\u17CA\\u17B7\\u1780\\u17BC\\u178A base64url",json_string:"\\u1781\\u17D2\\u179F\\u17C2\\u17A2\\u1780\\u17D2\\u179F\\u179A JSON",e164:"\\u179B\\u17C1\\u1781 E.164",jwt:"JWT",template_literal:"\\u1791\\u17B7\\u1793\\u17D2\\u1793\\u1793\\u17D0\\u1799\\u1794\\u1789\\u17D2\\u1785\\u17BC\\u179B"};return t=>{switch(t.code){case"invalid_type":return`\\u1791\\u17B7\\u1793\\u17D2\\u1793\\u1793\\u17D0\\u1799\\u1794\\u1789\\u17D2\\u1785\\u17BC\\u179B\\u1798\\u17B7\\u1793\\u178F\\u17D2\\u179A\\u17B9\\u1798\\u178F\\u17D2\\u179A\\u17BC\\u179C\\u17D6 \\u178F\\u17D2\\u179A\\u17BC\\u179C\\u1780\\u17B6\\u179A ${t.expected} \\u1794\\u17C9\\u17BB\\u1793\\u17D2\\u178F\\u17C2\\u1791\\u1791\\u17BD\\u179B\\u1794\\u17B6\\u1793 ${n(t.input)}`;case"invalid_value":return t.values.length===1?`\\u1791\\u17B7\\u1793\\u17D2\\u1793\\u1793\\u17D0\\u1799\\u1794\\u1789\\u17D2\\u1785\\u17BC\\u179B\\u1798\\u17B7\\u1793\\u178F\\u17D2\\u179A\\u17B9\\u1798\\u178F\\u17D2\\u179A\\u17BC\\u179C\\u17D6 \\u178F\\u17D2\\u179A\\u17BC\\u179C\\u1780\\u17B6\\u179A ${_(t.values[0])}`:`\\u1787\\u1798\\u17D2\\u179A\\u17BE\\u179F\\u1798\\u17B7\\u1793\\u178F\\u17D2\\u179A\\u17B9\\u1798\\u178F\\u17D2\\u179A\\u17BC\\u179C\\u17D6 \\u178F\\u17D2\\u179A\\u17BC\\u179C\\u1787\\u17B6\\u1798\\u17BD\\u1799\\u1780\\u17D2\\u1793\\u17BB\\u1784\\u1785\\u17C6\\u178E\\u17C4\\u1798 ${f(t.values,"|")}`;case"too_big":{let o=t.inclusive?"<=":"<",a=r(t.origin);return a?`\\u1792\\u17C6\\u1796\\u17C1\\u1780\\u17D6 \\u178F\\u17D2\\u179A\\u17BC\\u179C\\u1780\\u17B6\\u179A ${t.origin??"\\u178F\\u1798\\u17D2\\u179B\\u17C3"} ${o} ${t.maximum.toString()} ${a.unit??"\\u1792\\u17B6\\u178F\\u17BB"}`:`\\u1792\\u17C6\\u1796\\u17C1\\u1780\\u17D6 \\u178F\\u17D2\\u179A\\u17BC\\u179C\\u1780\\u17B6\\u179A ${t.origin??"\\u178F\\u1798\\u17D2\\u179B\\u17C3"} ${o} ${t.maximum.toString()}`}case"too_small":{let o=t.inclusive?">=":">",a=r(t.origin);return a?`\\u178F\\u17BC\\u1785\\u1796\\u17C1\\u1780\\u17D6 \\u178F\\u17D2\\u179A\\u17BC\\u179C\\u1780\\u17B6\\u179A ${t.origin} ${o} ${t.minimum.toString()} ${a.unit}`:`\\u178F\\u17BC\\u1785\\u1796\\u17C1\\u1780\\u17D6 \\u178F\\u17D2\\u179A\\u17BC\\u179C\\u1780\\u17B6\\u179A ${t.origin} ${o} ${t.minimum.toString()}`}case"invalid_format":{let o=t;return o.format==="starts_with"?`\\u1781\\u17D2\\u179F\\u17C2\\u17A2\\u1780\\u17D2\\u179F\\u179A\\u1798\\u17B7\\u1793\\u178F\\u17D2\\u179A\\u17B9\\u1798\\u178F\\u17D2\\u179A\\u17BC\\u179C\\u17D6 \\u178F\\u17D2\\u179A\\u17BC\\u179C\\u1785\\u17B6\\u1794\\u17CB\\u1795\\u17D2\\u178F\\u17BE\\u1798\\u178A\\u17C4\\u1799 "${o.prefix}"`:o.format==="ends_with"?`\\u1781\\u17D2\\u179F\\u17C2\\u17A2\\u1780\\u17D2\\u179F\\u179A\\u1798\\u17B7\\u1793\\u178F\\u17D2\\u179A\\u17B9\\u1798\\u178F\\u17D2\\u179A\\u17BC\\u179C\\u17D6 \\u178F\\u17D2\\u179A\\u17BC\\u179C\\u1794\\u1789\\u17D2\\u1785\\u1794\\u17CB\\u178A\\u17C4\\u1799 "${o.suffix}"`:o.format==="includes"?`\\u1781\\u17D2\\u179F\\u17C2\\u17A2\\u1780\\u17D2\\u179F\\u179A\\u1798\\u17B7\\u1793\\u178F\\u17D2\\u179A\\u17B9\\u1798\\u178F\\u17D2\\u179A\\u17BC\\u179C\\u17D6 \\u178F\\u17D2\\u179A\\u17BC\\u179C\\u1798\\u17B6\\u1793 "${o.includes}"`:o.format==="regex"?`\\u1781\\u17D2\\u179F\\u17C2\\u17A2\\u1780\\u17D2\\u179F\\u179A\\u1798\\u17B7\\u1793\\u178F\\u17D2\\u179A\\u17B9\\u1798\\u178F\\u17D2\\u179A\\u17BC\\u179C\\u17D6 \\u178F\\u17D2\\u179A\\u17BC\\u179C\\u178F\\u17C2\\u1795\\u17D2\\u1782\\u17BC\\u1795\\u17D2\\u1782\\u1784\\u1793\\u17B9\\u1784\\u1791\\u1798\\u17D2\\u179A\\u1784\\u17CB\\u178A\\u17C2\\u179B\\u1794\\u17B6\\u1793\\u1780\\u17C6\\u178E\\u178F\\u17CB ${o.pattern}`:`\\u1798\\u17B7\\u1793\\u178F\\u17D2\\u179A\\u17B9\\u1798\\u178F\\u17D2\\u179A\\u17BC\\u179C\\u17D6 ${i[o.format]??t.format}`}case"not_multiple_of":return`\\u179B\\u17C1\\u1781\\u1798\\u17B7\\u1793\\u178F\\u17D2\\u179A\\u17B9\\u1798\\u178F\\u17D2\\u179A\\u17BC\\u179C\\u17D6 \\u178F\\u17D2\\u179A\\u17BC\\u179C\\u178F\\u17C2\\u1787\\u17B6\\u1796\\u17A0\\u17BB\\u1782\\u17BB\\u178E\\u1793\\u17C3 ${t.divisor}`;case"unrecognized_keys":return`\\u179A\\u1780\\u1783\\u17BE\\u1789\\u179F\\u17C4\\u1798\\u17B7\\u1793\\u179F\\u17D2\\u1782\\u17B6\\u179B\\u17CB\\u17D6 ${f(t.keys,", ")}`;case"invalid_key":return`\\u179F\\u17C4\\u1798\\u17B7\\u1793\\u178F\\u17D2\\u179A\\u17B9\\u1798\\u178F\\u17D2\\u179A\\u17BC\\u179C\\u1793\\u17C5\\u1780\\u17D2\\u1793\\u17BB\\u1784 ${t.origin}`;case"invalid_union":return"\\u1791\\u17B7\\u1793\\u17D2\\u1793\\u1793\\u17D0\\u1799\\u1798\\u17B7\\u1793\\u178F\\u17D2\\u179A\\u17B9\\u1798\\u178F\\u17D2\\u179A\\u17BC\\u179C";case"invalid_element":return`\\u1791\\u17B7\\u1793\\u17D2\\u1793\\u1793\\u17D0\\u1799\\u1798\\u17B7\\u1793\\u178F\\u17D2\\u179A\\u17B9\\u1798\\u178F\\u17D2\\u179A\\u17BC\\u179C\\u1793\\u17C5\\u1780\\u17D2\\u1793\\u17BB\\u1784 ${t.origin}`;default:return"\\u1791\\u17B7\\u1793\\u17D2\\u1793\\u1793\\u17D0\\u1799\\u1798\\u17B7\\u1793\\u178F\\u17D2\\u179A\\u17B9\\u1798\\u178F\\u17D2\\u179A\\u17BC\\u179C"}}}});function Wu(){return{localeError:jm()}}var jm,Gu=S(()=>{P();jm=()=>{let e={string:{unit:"\\uBB38\\uC790",verb:"to have"},file:{unit:"\\uBC14\\uC774\\uD2B8",verb:"to have"},array:{unit:"\\uAC1C",verb:"to have"},set:{unit:"\\uAC1C",verb:"to have"}};function r(t){return e[t]??null}let n=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"number";case"object":{if(Array.isArray(t))return"array";if(t===null)return"null";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"\\uC785\\uB825",email:"\\uC774\\uBA54\\uC77C \\uC8FC\\uC18C",url:"URL",emoji:"\\uC774\\uBAA8\\uC9C0",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO \\uB0A0\\uC9DC\\uC2DC\\uAC04",date:"ISO \\uB0A0\\uC9DC",time:"ISO \\uC2DC\\uAC04",duration:"ISO \\uAE30\\uAC04",ipv4:"IPv4 \\uC8FC\\uC18C",ipv6:"IPv6 \\uC8FC\\uC18C",cidrv4:"IPv4 \\uBC94\\uC704",cidrv6:"IPv6 \\uBC94\\uC704",base64:"base64 \\uC778\\uCF54\\uB529 \\uBB38\\uC790\\uC5F4",base64url:"base64url \\uC778\\uCF54\\uB529 \\uBB38\\uC790\\uC5F4",json_string:"JSON \\uBB38\\uC790\\uC5F4",e164:"E.164 \\uBC88\\uD638",jwt:"JWT",template_literal:"\\uC785\\uB825"};return t=>{switch(t.code){case"invalid_type":return`\\uC798\\uBABB\\uB41C \\uC785\\uB825: \\uC608\\uC0C1 \\uD0C0\\uC785\\uC740 ${t.expected}, \\uBC1B\\uC740 \\uD0C0\\uC785\\uC740 ${n(t.input)}\\uC785\\uB2C8\\uB2E4`;case"invalid_value":return t.values.length===1?`\\uC798\\uBABB\\uB41C \\uC785\\uB825: \\uAC12\\uC740 ${_(t.values[0])} \\uC774\\uC5B4\\uC57C \\uD569\\uB2C8\\uB2E4`:`\\uC798\\uBABB\\uB41C \\uC635\\uC158: ${f(t.values,"\\uB610\\uB294 ")} \\uC911 \\uD558\\uB098\\uC5EC\\uC57C \\uD569\\uB2C8\\uB2E4`;case"too_big":{let o=t.inclusive?"\\uC774\\uD558":"\\uBBF8\\uB9CC",a=o==="\\uBBF8\\uB9CC"?"\\uC774\\uC5B4\\uC57C \\uD569\\uB2C8\\uB2E4":"\\uC5EC\\uC57C \\uD569\\uB2C8\\uB2E4",c=r(t.origin),p=c?.unit??"\\uC694\\uC18C";return c?`${t.origin??"\\uAC12"}\\uC774 \\uB108\\uBB34 \\uD07D\\uB2C8\\uB2E4: ${t.maximum.toString()}${p} ${o}${a}`:`${t.origin??"\\uAC12"}\\uC774 \\uB108\\uBB34 \\uD07D\\uB2C8\\uB2E4: ${t.maximum.toString()} ${o}${a}`}case"too_small":{let o=t.inclusive?"\\uC774\\uC0C1":"\\uCD08\\uACFC",a=o==="\\uC774\\uC0C1"?"\\uC774\\uC5B4\\uC57C \\uD569\\uB2C8\\uB2E4":"\\uC5EC\\uC57C \\uD569\\uB2C8\\uB2E4",c=r(t.origin),p=c?.unit??"\\uC694\\uC18C";return c?`${t.origin??"\\uAC12"}\\uC774 \\uB108\\uBB34 \\uC791\\uC2B5\\uB2C8\\uB2E4: ${t.minimum.toString()}${p} ${o}${a}`:`${t.origin??"\\uAC12"}\\uC774 \\uB108\\uBB34 \\uC791\\uC2B5\\uB2C8\\uB2E4: ${t.minimum.toString()} ${o}${a}`}case"invalid_format":{let o=t;return o.format==="starts_with"?`\\uC798\\uBABB\\uB41C \\uBB38\\uC790\\uC5F4: "${o.prefix}"(\\uC73C)\\uB85C \\uC2DC\\uC791\\uD574\\uC57C \\uD569\\uB2C8\\uB2E4`:o.format==="ends_with"?`\\uC798\\uBABB\\uB41C \\uBB38\\uC790\\uC5F4: "${o.suffix}"(\\uC73C)\\uB85C \\uB05D\\uB098\\uC57C \\uD569\\uB2C8\\uB2E4`:o.format==="includes"?`\\uC798\\uBABB\\uB41C \\uBB38\\uC790\\uC5F4: "${o.includes}"\\uC744(\\uB97C) \\uD3EC\\uD568\\uD574\\uC57C \\uD569\\uB2C8\\uB2E4`:o.format==="regex"?`\\uC798\\uBABB\\uB41C \\uBB38\\uC790\\uC5F4: \\uC815\\uADDC\\uC2DD ${o.pattern} \\uD328\\uD134\\uACFC \\uC77C\\uCE58\\uD574\\uC57C \\uD569\\uB2C8\\uB2E4`:`\\uC798\\uBABB\\uB41C ${i[o.format]??t.format}`}case"not_multiple_of":return`\\uC798\\uBABB\\uB41C \\uC22B\\uC790: ${t.divisor}\\uC758 \\uBC30\\uC218\\uC5EC\\uC57C \\uD569\\uB2C8\\uB2E4`;case"unrecognized_keys":return`\\uC778\\uC2DD\\uD560 \\uC218 \\uC5C6\\uB294 \\uD0A4: ${f(t.keys,", ")}`;case"invalid_key":return`\\uC798\\uBABB\\uB41C \\uD0A4: ${t.origin}`;case"invalid_union":return"\\uC798\\uBABB\\uB41C \\uC785\\uB825";case"invalid_element":return`\\uC798\\uBABB\\uB41C \\uAC12: ${t.origin}`;default:return"\\uC798\\uBABB\\uB41C \\uC785\\uB825"}}}});function Qu(){return{localeError:Pm()}}var Pm,Yu=S(()=>{P();Pm=()=>{let e={string:{unit:"\\u0437\\u043D\\u0430\\u0446\\u0438",verb:"\\u0434\\u0430 \\u0438\\u043C\\u0430\\u0430\\u0442"},file:{unit:"\\u0431\\u0430\\u0458\\u0442\\u0438",verb:"\\u0434\\u0430 \\u0438\\u043C\\u0430\\u0430\\u0442"},array:{unit:"\\u0441\\u0442\\u0430\\u0432\\u043A\\u0438",verb:"\\u0434\\u0430 \\u0438\\u043C\\u0430\\u0430\\u0442"},set:{unit:"\\u0441\\u0442\\u0430\\u0432\\u043A\\u0438",verb:"\\u0434\\u0430 \\u0438\\u043C\\u0430\\u0430\\u0442"}};function r(t){return e[t]??null}let n=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"\\u0431\\u0440\\u043E\\u0458";case"object":{if(Array.isArray(t))return"\\u043D\\u0438\\u0437\\u0430";if(t===null)return"null";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"\\u0432\\u043D\\u0435\\u0441",email:"\\u0430\\u0434\\u0440\\u0435\\u0441\\u0430 \\u043D\\u0430 \\u0435-\\u043F\\u043E\\u0448\\u0442\\u0430",url:"URL",emoji:"\\u0435\\u043C\\u043E\\u045F\\u0438",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO \\u0434\\u0430\\u0442\\u0443\\u043C \\u0438 \\u0432\\u0440\\u0435\\u043C\\u0435",date:"ISO \\u0434\\u0430\\u0442\\u0443\\u043C",time:"ISO \\u0432\\u0440\\u0435\\u043C\\u0435",duration:"ISO \\u0432\\u0440\\u0435\\u043C\\u0435\\u0442\\u0440\\u0430\\u0435\\u045A\\u0435",ipv4:"IPv4 \\u0430\\u0434\\u0440\\u0435\\u0441\\u0430",ipv6:"IPv6 \\u0430\\u0434\\u0440\\u0435\\u0441\\u0430",cidrv4:"IPv4 \\u043E\\u043F\\u0441\\u0435\\u0433",cidrv6:"IPv6 \\u043E\\u043F\\u0441\\u0435\\u0433",base64:"base64-\\u0435\\u043D\\u043A\\u043E\\u0434\\u0438\\u0440\\u0430\\u043D\\u0430 \\u043D\\u0438\\u0437\\u0430",base64url:"base64url-\\u0435\\u043D\\u043A\\u043E\\u0434\\u0438\\u0440\\u0430\\u043D\\u0430 \\u043D\\u0438\\u0437\\u0430",json_string:"JSON \\u043D\\u0438\\u0437\\u0430",e164:"E.164 \\u0431\\u0440\\u043E\\u0458",jwt:"JWT",template_literal:"\\u0432\\u043D\\u0435\\u0441"};return t=>{switch(t.code){case"invalid_type":return`\\u0413\\u0440\\u0435\\u0448\\u0435\\u043D \\u0432\\u043D\\u0435\\u0441: \\u0441\\u0435 \\u043E\\u0447\\u0435\\u043A\\u0443\\u0432\\u0430 ${t.expected}, \\u043F\\u0440\\u0438\\u043C\\u0435\\u043D\\u043E ${n(t.input)}`;case"invalid_value":return t.values.length===1?`Invalid input: expected ${_(t.values[0])}`:`\\u0413\\u0440\\u0435\\u0448\\u0430\\u043D\\u0430 \\u043E\\u043F\\u0446\\u0438\\u0458\\u0430: \\u0441\\u0435 \\u043E\\u0447\\u0435\\u043A\\u0443\\u0432\\u0430 \\u0435\\u0434\\u043D\\u0430 ${f(t.values,"|")}`;case"too_big":{let o=t.inclusive?"<=":"<",a=r(t.origin);return a?`\\u041F\\u0440\\u0435\\u043C\\u043D\\u043E\\u0433\\u0443 \\u0433\\u043E\\u043B\\u0435\\u043C: \\u0441\\u0435 \\u043E\\u0447\\u0435\\u043A\\u0443\\u0432\\u0430 ${t.origin??"\\u0432\\u0440\\u0435\\u0434\\u043D\\u043E\\u0441\\u0442\\u0430"} \\u0434\\u0430 \\u0438\\u043C\\u0430 ${o}${t.maximum.toString()} ${a.unit??"\\u0435\\u043B\\u0435\\u043C\\u0435\\u043D\\u0442\\u0438"}`:`\\u041F\\u0440\\u0435\\u043C\\u043D\\u043E\\u0433\\u0443 \\u0433\\u043E\\u043B\\u0435\\u043C: \\u0441\\u0435 \\u043E\\u0447\\u0435\\u043A\\u0443\\u0432\\u0430 ${t.origin??"\\u0432\\u0440\\u0435\\u0434\\u043D\\u043E\\u0441\\u0442\\u0430"} \\u0434\\u0430 \\u0431\\u0438\\u0434\\u0435 ${o}${t.maximum.toString()}`}case"too_small":{let o=t.inclusive?">=":">",a=r(t.origin);return a?`\\u041F\\u0440\\u0435\\u043C\\u043D\\u043E\\u0433\\u0443 \\u043C\\u0430\\u043B: \\u0441\\u0435 \\u043E\\u0447\\u0435\\u043A\\u0443\\u0432\\u0430 ${t.origin} \\u0434\\u0430 \\u0438\\u043C\\u0430 ${o}${t.minimum.toString()} ${a.unit}`:`\\u041F\\u0440\\u0435\\u043C\\u043D\\u043E\\u0433\\u0443 \\u043C\\u0430\\u043B: \\u0441\\u0435 \\u043E\\u0447\\u0435\\u043A\\u0443\\u0432\\u0430 ${t.origin} \\u0434\\u0430 \\u0431\\u0438\\u0434\\u0435 ${o}${t.minimum.toString()}`}case"invalid_format":{let o=t;return o.format==="starts_with"?`\\u041D\\u0435\\u0432\\u0430\\u0436\\u0435\\u0447\\u043A\\u0430 \\u043D\\u0438\\u0437\\u0430: \\u043C\\u043E\\u0440\\u0430 \\u0434\\u0430 \\u0437\\u0430\\u043F\\u043E\\u0447\\u043D\\u0443\\u0432\\u0430 \\u0441\\u043E "${o.prefix}"`:o.format==="ends_with"?`\\u041D\\u0435\\u0432\\u0430\\u0436\\u0435\\u0447\\u043A\\u0430 \\u043D\\u0438\\u0437\\u0430: \\u043C\\u043E\\u0440\\u0430 \\u0434\\u0430 \\u0437\\u0430\\u0432\\u0440\\u0448\\u0443\\u0432\\u0430 \\u0441\\u043E "${o.suffix}"`:o.format==="includes"?`\\u041D\\u0435\\u0432\\u0430\\u0436\\u0435\\u0447\\u043A\\u0430 \\u043D\\u0438\\u0437\\u0430: \\u043C\\u043E\\u0440\\u0430 \\u0434\\u0430 \\u0432\\u043A\\u043B\\u0443\\u0447\\u0443\\u0432\\u0430 "${o.includes}"`:o.format==="regex"?`\\u041D\\u0435\\u0432\\u0430\\u0436\\u0435\\u0447\\u043A\\u0430 \\u043D\\u0438\\u0437\\u0430: \\u043C\\u043E\\u0440\\u0430 \\u0434\\u0430 \\u043E\\u0434\\u0433\\u043E\\u0430\\u0440\\u0430 \\u043D\\u0430 \\u043F\\u0430\\u0442\\u0435\\u0440\\u043D\\u043E\\u0442 ${o.pattern}`:`Invalid ${i[o.format]??t.format}`}case"not_multiple_of":return`\\u0413\\u0440\\u0435\\u0448\\u0435\\u043D \\u0431\\u0440\\u043E\\u0458: \\u043C\\u043E\\u0440\\u0430 \\u0434\\u0430 \\u0431\\u0438\\u0434\\u0435 \\u0434\\u0435\\u043B\\u0438\\u0432 \\u0441\\u043E ${t.divisor}`;case"unrecognized_keys":return`${t.keys.length>1?"\\u041D\\u0435\\u043F\\u0440\\u0435\\u043F\\u043E\\u0437\\u043D\\u0430\\u0435\\u043D\\u0438 \\u043A\\u043B\\u0443\\u0447\\u0435\\u0432\\u0438":"\\u041D\\u0435\\u043F\\u0440\\u0435\\u043F\\u043E\\u0437\\u043D\\u0430\\u0435\\u043D \\u043A\\u043B\\u0443\\u0447"}: ${f(t.keys,", ")}`;case"invalid_key":return`\\u0413\\u0440\\u0435\\u0448\\u0435\\u043D \\u043A\\u043B\\u0443\\u0447 \\u0432\\u043E ${t.origin}`;case"invalid_union":return"\\u0413\\u0440\\u0435\\u0448\\u0435\\u043D \\u0432\\u043D\\u0435\\u0441";case"invalid_element":return`\\u0413\\u0440\\u0435\\u0448\\u043D\\u0430 \\u0432\\u0440\\u0435\\u0434\\u043D\\u043E\\u0441\\u0442 \\u0432\\u043E ${t.origin}`;default:return"\\u0413\\u0440\\u0435\\u0448\\u0435\\u043D \\u0432\\u043D\\u0435\\u0441"}}}});function Xu(){return{localeError:Tm()}}var Tm,el=S(()=>{P();Tm=()=>{let e={string:{unit:"aksara",verb:"mempunyai"},file:{unit:"bait",verb:"mempunyai"},array:{unit:"elemen",verb:"mempunyai"},set:{unit:"elemen",verb:"mempunyai"}};function r(t){return e[t]??null}let n=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"nombor";case"object":{if(Array.isArray(t))return"array";if(t===null)return"null";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"input",email:"alamat e-mel",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"tarikh masa ISO",date:"tarikh ISO",time:"masa ISO",duration:"tempoh ISO",ipv4:"alamat IPv4",ipv6:"alamat IPv6",cidrv4:"julat IPv4",cidrv6:"julat IPv6",base64:"string dikodkan base64",base64url:"string dikodkan base64url",json_string:"string JSON",e164:"nombor E.164",jwt:"JWT",template_literal:"input"};return t=>{switch(t.code){case"invalid_type":return`Input tidak sah: dijangka ${t.expected}, diterima ${n(t.input)}`;case"invalid_value":return t.values.length===1?`Input tidak sah: dijangka ${_(t.values[0])}`:`Pilihan tidak sah: dijangka salah satu daripada ${f(t.values,"|")}`;case"too_big":{let o=t.inclusive?"<=":"<",a=r(t.origin);return a?`Terlalu besar: dijangka ${t.origin??"nilai"} ${a.verb} ${o}${t.maximum.toString()} ${a.unit??"elemen"}`:`Terlalu besar: dijangka ${t.origin??"nilai"} adalah ${o}${t.maximum.toString()}`}case"too_small":{let o=t.inclusive?">=":">",a=r(t.origin);return a?`Terlalu kecil: dijangka ${t.origin} ${a.verb} ${o}${t.minimum.toString()} ${a.unit}`:`Terlalu kecil: dijangka ${t.origin} adalah ${o}${t.minimum.toString()}`}case"invalid_format":{let o=t;return o.format==="starts_with"?`String tidak sah: mesti bermula dengan "${o.prefix}"`:o.format==="ends_with"?`String tidak sah: mesti berakhir dengan "${o.suffix}"`:o.format==="includes"?`String tidak sah: mesti mengandungi "${o.includes}"`:o.format==="regex"?`String tidak sah: mesti sepadan dengan corak ${o.pattern}`:`${i[o.format]??t.format} tidak sah`}case"not_multiple_of":return`Nombor tidak sah: perlu gandaan ${t.divisor}`;case"unrecognized_keys":return`Kunci tidak dikenali: ${f(t.keys,", ")}`;case"invalid_key":return`Kunci tidak sah dalam ${t.origin}`;case"invalid_union":return"Input tidak sah";case"invalid_element":return`Nilai tidak sah dalam ${t.origin}`;default:return"Input tidak sah"}}}});function tl(){return{localeError:Om()}}var Om,rl=S(()=>{P();Om=()=>{let e={string:{unit:"tekens"},file:{unit:"bytes"},array:{unit:"elementen"},set:{unit:"elementen"}};function r(t){return e[t]??null}let n=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"getal";case"object":{if(Array.isArray(t))return"array";if(t===null)return"null";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"invoer",email:"emailadres",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO datum en tijd",date:"ISO datum",time:"ISO tijd",duration:"ISO duur",ipv4:"IPv4-adres",ipv6:"IPv6-adres",cidrv4:"IPv4-bereik",cidrv6:"IPv6-bereik",base64:"base64-gecodeerde tekst",base64url:"base64 URL-gecodeerde tekst",json_string:"JSON string",e164:"E.164-nummer",jwt:"JWT",template_literal:"invoer"};return t=>{switch(t.code){case"invalid_type":return`Ongeldige invoer: verwacht ${t.expected}, ontving ${n(t.input)}`;case"invalid_value":return t.values.length===1?`Ongeldige invoer: verwacht ${_(t.values[0])}`:`Ongeldige optie: verwacht \\xE9\\xE9n van ${f(t.values,"|")}`;case"too_big":{let o=t.inclusive?"<=":"<",a=r(t.origin);return a?`Te lang: verwacht dat ${t.origin??"waarde"} ${o}${t.maximum.toString()} ${a.unit??"elementen"} bevat`:`Te lang: verwacht dat ${t.origin??"waarde"} ${o}${t.maximum.toString()} is`}case"too_small":{let o=t.inclusive?">=":">",a=r(t.origin);return a?`Te kort: verwacht dat ${t.origin} ${o}${t.minimum.toString()} ${a.unit} bevat`:`Te kort: verwacht dat ${t.origin} ${o}${t.minimum.toString()} is`}case"invalid_format":{let o=t;return o.format==="starts_with"?`Ongeldige tekst: moet met "${o.prefix}" beginnen`:o.format==="ends_with"?`Ongeldige tekst: moet op "${o.suffix}" eindigen`:o.format==="includes"?`Ongeldige tekst: moet "${o.includes}" bevatten`:o.format==="regex"?`Ongeldige tekst: moet overeenkomen met patroon ${o.pattern}`:`Ongeldig: ${i[o.format]??t.format}`}case"not_multiple_of":return`Ongeldig getal: moet een veelvoud van ${t.divisor} zijn`;case"unrecognized_keys":return`Onbekende key${t.keys.length>1?"s":""}: ${f(t.keys,", ")}`;case"invalid_key":return`Ongeldige key in ${t.origin}`;case"invalid_union":return"Ongeldige invoer";case"invalid_element":return`Ongeldige waarde in ${t.origin}`;default:return"Ongeldige invoer"}}}});function nl(){return{localeError:Nm()}}var Nm,ol=S(()=>{P();Nm=()=>{let e={string:{unit:"tegn",verb:"\\xE5 ha"},file:{unit:"bytes",verb:"\\xE5 ha"},array:{unit:"elementer",verb:"\\xE5 inneholde"},set:{unit:"elementer",verb:"\\xE5 inneholde"}};function r(t){return e[t]??null}let n=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"tall";case"object":{if(Array.isArray(t))return"liste";if(t===null)return"null";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"input",email:"e-postadresse",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO dato- og klokkeslett",date:"ISO-dato",time:"ISO-klokkeslett",duration:"ISO-varighet",ipv4:"IPv4-omr\\xE5de",ipv6:"IPv6-omr\\xE5de",cidrv4:"IPv4-spekter",cidrv6:"IPv6-spekter",base64:"base64-enkodet streng",base64url:"base64url-enkodet streng",json_string:"JSON-streng",e164:"E.164-nummer",jwt:"JWT",template_literal:"input"};return t=>{switch(t.code){case"invalid_type":return`Ugyldig input: forventet ${t.expected}, fikk ${n(t.input)}`;case"invalid_value":return t.values.length===1?`Ugyldig verdi: forventet ${_(t.values[0])}`:`Ugyldig valg: forventet en av ${f(t.values,"|")}`;case"too_big":{let o=t.inclusive?"<=":"<",a=r(t.origin);return a?`For stor(t): forventet ${t.origin??"value"} til \\xE5 ha ${o}${t.maximum.toString()} ${a.unit??"elementer"}`:`For stor(t): forventet ${t.origin??"value"} til \\xE5 ha ${o}${t.maximum.toString()}`}case"too_small":{let o=t.inclusive?">=":">",a=r(t.origin);return a?`For lite(n): forventet ${t.origin} til \\xE5 ha ${o}${t.minimum.toString()} ${a.unit}`:`For lite(n): forventet ${t.origin} til \\xE5 ha ${o}${t.minimum.toString()}`}case"invalid_format":{let o=t;return o.format==="starts_with"?`Ugyldig streng: m\\xE5 starte med "${o.prefix}"`:o.format==="ends_with"?`Ugyldig streng: m\\xE5 ende med "${o.suffix}"`:o.format==="includes"?`Ugyldig streng: m\\xE5 inneholde "${o.includes}"`:o.format==="regex"?`Ugyldig streng: m\\xE5 matche m\\xF8nsteret ${o.pattern}`:`Ugyldig ${i[o.format]??t.format}`}case"not_multiple_of":return`Ugyldig tall: m\\xE5 v\\xE6re et multiplum av ${t.divisor}`;case"unrecognized_keys":return`${t.keys.length>1?"Ukjente n\\xF8kler":"Ukjent n\\xF8kkel"}: ${f(t.keys,", ")}`;case"invalid_key":return`Ugyldig n\\xF8kkel i ${t.origin}`;case"invalid_union":return"Ugyldig input";case"invalid_element":return`Ugyldig verdi i ${t.origin}`;default:return"Ugyldig input"}}}});function il(){return{localeError:Um()}}var Um,al=S(()=>{P();Um=()=>{let e={string:{unit:"harf",verb:"olmal\\u0131d\\u0131r"},file:{unit:"bayt",verb:"olmal\\u0131d\\u0131r"},array:{unit:"unsur",verb:"olmal\\u0131d\\u0131r"},set:{unit:"unsur",verb:"olmal\\u0131d\\u0131r"}};function r(t){return e[t]??null}let n=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"numara";case"object":{if(Array.isArray(t))return"saf";if(t===null)return"gayb";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"giren",email:"epostag\\xE2h",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO heng\\xE2m\\u0131",date:"ISO tarihi",time:"ISO zaman\\u0131",duration:"ISO m\\xFCddeti",ipv4:"IPv4 ni\\u015F\\xE2n\\u0131",ipv6:"IPv6 ni\\u015F\\xE2n\\u0131",cidrv4:"IPv4 menzili",cidrv6:"IPv6 menzili",base64:"base64-\\u015Fifreli metin",base64url:"base64url-\\u015Fifreli metin",json_string:"JSON metin",e164:"E.164 say\\u0131s\\u0131",jwt:"JWT",template_literal:"giren"};return t=>{switch(t.code){case"invalid_type":return`F\\xE2sit giren: umulan ${t.expected}, al\\u0131nan ${n(t.input)}`;case"invalid_value":return t.values.length===1?`F\\xE2sit giren: umulan ${_(t.values[0])}`:`F\\xE2sit tercih: m\\xFBteberler ${f(t.values,"|")}`;case"too_big":{let o=t.inclusive?"<=":"<",a=r(t.origin);return a?`Fazla b\\xFCy\\xFCk: ${t.origin??"value"}, ${o}${t.maximum.toString()} ${a.unit??"elements"} sahip olmal\\u0131yd\\u0131.`:`Fazla b\\xFCy\\xFCk: ${t.origin??"value"}, ${o}${t.maximum.toString()} olmal\\u0131yd\\u0131.`}case"too_small":{let o=t.inclusive?">=":">",a=r(t.origin);return a?`Fazla k\\xFC\\xE7\\xFCk: ${t.origin}, ${o}${t.minimum.toString()} ${a.unit} sahip olmal\\u0131yd\\u0131.`:`Fazla k\\xFC\\xE7\\xFCk: ${t.origin}, ${o}${t.minimum.toString()} olmal\\u0131yd\\u0131.`}case"invalid_format":{let o=t;return o.format==="starts_with"?`F\\xE2sit metin: "${o.prefix}" ile ba\\u015Flamal\\u0131.`:o.format==="ends_with"?`F\\xE2sit metin: "${o.suffix}" ile bitmeli.`:o.format==="includes"?`F\\xE2sit metin: "${o.includes}" ihtiv\\xE2 etmeli.`:o.format==="regex"?`F\\xE2sit metin: ${o.pattern} nak\\u015F\\u0131na uymal\\u0131.`:`F\\xE2sit ${i[o.format]??t.format}`}case"not_multiple_of":return`F\\xE2sit say\\u0131: ${t.divisor} kat\\u0131 olmal\\u0131yd\\u0131.`;case"unrecognized_keys":return`Tan\\u0131nmayan anahtar ${t.keys.length>1?"s":""}: ${f(t.keys,", ")}`;case"invalid_key":return`${t.origin} i\\xE7in tan\\u0131nmayan anahtar var.`;case"invalid_union":return"Giren tan\\u0131namad\\u0131.";case"invalid_element":return`${t.origin} i\\xE7in tan\\u0131nmayan k\\u0131ymet var.`;default:return"K\\u0131ymet tan\\u0131namad\\u0131."}}}});function sl(){return{localeError:Em()}}var Em,cl=S(()=>{P();Em=()=>{let e={string:{unit:"\\u062A\\u0648\\u06A9\\u064A",verb:"\\u0648\\u0644\\u0631\\u064A"},file:{unit:"\\u0628\\u0627\\u06CC\\u067C\\u0633",verb:"\\u0648\\u0644\\u0631\\u064A"},array:{unit:"\\u062A\\u0648\\u06A9\\u064A",verb:"\\u0648\\u0644\\u0631\\u064A"},set:{unit:"\\u062A\\u0648\\u06A9\\u064A",verb:"\\u0648\\u0644\\u0631\\u064A"}};function r(t){return e[t]??null}let n=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"\\u0639\\u062F\\u062F";case"object":{if(Array.isArray(t))return"\\u0627\\u0631\\u06D0";if(t===null)return"null";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"\\u0648\\u0631\\u0648\\u062F\\u064A",email:"\\u0628\\u0631\\u06CC\\u069A\\u0646\\u0627\\u0644\\u06CC\\u06A9",url:"\\u06CC\\u0648 \\u0622\\u0631 \\u0627\\u0644",emoji:"\\u0627\\u06CC\\u0645\\u0648\\u062C\\u064A",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"\\u0646\\u06CC\\u067C\\u0647 \\u0627\\u0648 \\u0648\\u062E\\u062A",date:"\\u0646\\u06D0\\u067C\\u0647",time:"\\u0648\\u062E\\u062A",duration:"\\u0645\\u0648\\u062F\\u0647",ipv4:"\\u062F IPv4 \\u067E\\u062A\\u0647",ipv6:"\\u062F IPv6 \\u067E\\u062A\\u0647",cidrv4:"\\u062F IPv4 \\u0633\\u0627\\u062D\\u0647",cidrv6:"\\u062F IPv6 \\u0633\\u0627\\u062D\\u0647",base64:"base64-encoded \\u0645\\u062A\\u0646",base64url:"base64url-encoded \\u0645\\u062A\\u0646",json_string:"JSON \\u0645\\u062A\\u0646",e164:"\\u062F E.164 \\u0634\\u0645\\u06D0\\u0631\\u0647",jwt:"JWT",template_literal:"\\u0648\\u0631\\u0648\\u062F\\u064A"};return t=>{switch(t.code){case"invalid_type":return`\\u0646\\u0627\\u0633\\u0645 \\u0648\\u0631\\u0648\\u062F\\u064A: \\u0628\\u0627\\u06CC\\u062F ${t.expected} \\u0648\\u0627\\u06CC, \\u0645\\u06AB\\u0631 ${n(t.input)} \\u062A\\u0631\\u0644\\u0627\\u0633\\u0647 \\u0634\\u0648`;case"invalid_value":return t.values.length===1?`\\u0646\\u0627\\u0633\\u0645 \\u0648\\u0631\\u0648\\u062F\\u064A: \\u0628\\u0627\\u06CC\\u062F ${_(t.values[0])} \\u0648\\u0627\\u06CC`:`\\u0646\\u0627\\u0633\\u0645 \\u0627\\u0646\\u062A\\u062E\\u0627\\u0628: \\u0628\\u0627\\u06CC\\u062F \\u06CC\\u0648 \\u0644\\u0647 ${f(t.values,"|")} \\u0685\\u062E\\u0647 \\u0648\\u0627\\u06CC`;case"too_big":{let o=t.inclusive?"<=":"<",a=r(t.origin);return a?`\\u0689\\u06CC\\u0631 \\u0644\\u0648\\u06CC: ${t.origin??"\\u0627\\u0631\\u0632\\u069A\\u062A"} \\u0628\\u0627\\u06CC\\u062F ${o}${t.maximum.toString()} ${a.unit??"\\u0639\\u0646\\u0635\\u0631\\u0648\\u0646\\u0647"} \\u0648\\u0644\\u0631\\u064A`:`\\u0689\\u06CC\\u0631 \\u0644\\u0648\\u06CC: ${t.origin??"\\u0627\\u0631\\u0632\\u069A\\u062A"} \\u0628\\u0627\\u06CC\\u062F ${o}${t.maximum.toString()} \\u0648\\u064A`}case"too_small":{let o=t.inclusive?">=":">",a=r(t.origin);return a?`\\u0689\\u06CC\\u0631 \\u06A9\\u0648\\u0686\\u0646\\u06CC: ${t.origin} \\u0628\\u0627\\u06CC\\u062F ${o}${t.minimum.toString()} ${a.unit} \\u0648\\u0644\\u0631\\u064A`:`\\u0689\\u06CC\\u0631 \\u06A9\\u0648\\u0686\\u0646\\u06CC: ${t.origin} \\u0628\\u0627\\u06CC\\u062F ${o}${t.minimum.toString()} \\u0648\\u064A`}case"invalid_format":{let o=t;return o.format==="starts_with"?`\\u0646\\u0627\\u0633\\u0645 \\u0645\\u062A\\u0646: \\u0628\\u0627\\u06CC\\u062F \\u062F "${o.prefix}" \\u0633\\u0631\\u0647 \\u067E\\u06CC\\u0644 \\u0634\\u064A`:o.format==="ends_with"?`\\u0646\\u0627\\u0633\\u0645 \\u0645\\u062A\\u0646: \\u0628\\u0627\\u06CC\\u062F \\u062F "${o.suffix}" \\u0633\\u0631\\u0647 \\u067E\\u0627\\u06CC \\u062A\\u0647 \\u0648\\u0631\\u0633\\u064A\\u0696\\u064A`:o.format==="includes"?`\\u0646\\u0627\\u0633\\u0645 \\u0645\\u062A\\u0646: \\u0628\\u0627\\u06CC\\u062F "${o.includes}" \\u0648\\u0644\\u0631\\u064A`:o.format==="regex"?`\\u0646\\u0627\\u0633\\u0645 \\u0645\\u062A\\u0646: \\u0628\\u0627\\u06CC\\u062F \\u062F ${o.pattern} \\u0633\\u0631\\u0647 \\u0645\\u0637\\u0627\\u0628\\u0642\\u062A \\u0648\\u0644\\u0631\\u064A`:`${i[o.format]??t.format} \\u0646\\u0627\\u0633\\u0645 \\u062F\\u06CC`}case"not_multiple_of":return`\\u0646\\u0627\\u0633\\u0645 \\u0639\\u062F\\u062F: \\u0628\\u0627\\u06CC\\u062F \\u062F ${t.divisor} \\u0645\\u0636\\u0631\\u0628 \\u0648\\u064A`;case"unrecognized_keys":return`\\u0646\\u0627\\u0633\\u0645 ${t.keys.length>1?"\\u06A9\\u0644\\u06CC\\u0689\\u0648\\u0646\\u0647":"\\u06A9\\u0644\\u06CC\\u0689"}: ${f(t.keys,", ")}`;case"invalid_key":return`\\u0646\\u0627\\u0633\\u0645 \\u06A9\\u0644\\u06CC\\u0689 \\u067E\\u0647 ${t.origin} \\u06A9\\u06D0`;case"invalid_union":return"\\u0646\\u0627\\u0633\\u0645\\u0647 \\u0648\\u0631\\u0648\\u062F\\u064A";case"invalid_element":return`\\u0646\\u0627\\u0633\\u0645 \\u0639\\u0646\\u0635\\u0631 \\u067E\\u0647 ${t.origin} \\u06A9\\u06D0`;default:return"\\u0646\\u0627\\u0633\\u0645\\u0647 \\u0648\\u0631\\u0648\\u062F\\u064A"}}}});function ul(){return{localeError:Dm()}}var Dm,ll=S(()=>{P();Dm=()=>{let e={string:{unit:"znak\\xF3w",verb:"mie\\u0107"},file:{unit:"bajt\\xF3w",verb:"mie\\u0107"},array:{unit:"element\\xF3w",verb:"mie\\u0107"},set:{unit:"element\\xF3w",verb:"mie\\u0107"}};function r(t){return e[t]??null}let n=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"liczba";case"object":{if(Array.isArray(t))return"tablica";if(t===null)return"null";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"wyra\\u017Cenie",email:"adres email",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"data i godzina w formacie ISO",date:"data w formacie ISO",time:"godzina w formacie ISO",duration:"czas trwania ISO",ipv4:"adres IPv4",ipv6:"adres IPv6",cidrv4:"zakres IPv4",cidrv6:"zakres IPv6",base64:"ci\\u0105g znak\\xF3w zakodowany w formacie base64",base64url:"ci\\u0105g znak\\xF3w zakodowany w formacie base64url",json_string:"ci\\u0105g znak\\xF3w w formacie JSON",e164:"liczba E.164",jwt:"JWT",template_literal:"wej\\u015Bcie"};return t=>{switch(t.code){case"invalid_type":return`Nieprawid\\u0142owe dane wej\\u015Bciowe: oczekiwano ${t.expected}, otrzymano ${n(t.input)}`;case"invalid_value":return t.values.length===1?`Nieprawid\\u0142owe dane wej\\u015Bciowe: oczekiwano ${_(t.values[0])}`:`Nieprawid\\u0142owa opcja: oczekiwano jednej z warto\\u015Bci ${f(t.values,"|")}`;case"too_big":{let o=t.inclusive?"<=":"<",a=r(t.origin);return a?`Za du\\u017Ca warto\\u015B\\u0107: oczekiwano, \\u017Ce ${t.origin??"warto\\u015B\\u0107"} b\\u0119dzie mie\\u0107 ${o}${t.maximum.toString()} ${a.unit??"element\\xF3w"}`:`Zbyt du\\u017C(y/a/e): oczekiwano, \\u017Ce ${t.origin??"warto\\u015B\\u0107"} b\\u0119dzie wynosi\\u0107 ${o}${t.maximum.toString()}`}case"too_small":{let o=t.inclusive?">=":">",a=r(t.origin);return a?`Za ma\\u0142a warto\\u015B\\u0107: oczekiwano, \\u017Ce ${t.origin??"warto\\u015B\\u0107"} b\\u0119dzie mie\\u0107 ${o}${t.minimum.toString()} ${a.unit??"element\\xF3w"}`:`Zbyt ma\\u0142(y/a/e): oczekiwano, \\u017Ce ${t.origin??"warto\\u015B\\u0107"} b\\u0119dzie wynosi\\u0107 ${o}${t.minimum.toString()}`}case"invalid_format":{let o=t;return o.format==="starts_with"?`Nieprawid\\u0142owy ci\\u0105g znak\\xF3w: musi zaczyna\\u0107 si\\u0119 od "${o.prefix}"`:o.format==="ends_with"?`Nieprawid\\u0142owy ci\\u0105g znak\\xF3w: musi ko\\u0144czy\\u0107 si\\u0119 na "${o.suffix}"`:o.format==="includes"?`Nieprawid\\u0142owy ci\\u0105g znak\\xF3w: musi zawiera\\u0107 "${o.includes}"`:o.format==="regex"?`Nieprawid\\u0142owy ci\\u0105g znak\\xF3w: musi odpowiada\\u0107 wzorcowi ${o.pattern}`:`Nieprawid\\u0142ow(y/a/e) ${i[o.format]??t.format}`}case"not_multiple_of":return`Nieprawid\\u0142owa liczba: musi by\\u0107 wielokrotno\\u015Bci\\u0105 ${t.divisor}`;case"unrecognized_keys":return`Nierozpoznane klucze${t.keys.length>1?"s":""}: ${f(t.keys,", ")}`;case"invalid_key":return`Nieprawid\\u0142owy klucz w ${t.origin}`;case"invalid_union":return"Nieprawid\\u0142owe dane wej\\u015Bciowe";case"invalid_element":return`Nieprawid\\u0142owa warto\\u015B\\u0107 w ${t.origin}`;default:return"Nieprawid\\u0142owe dane wej\\u015Bciowe"}}}});function dl(){return{localeError:Rm()}}var Rm,pl=S(()=>{P();Rm=()=>{let e={string:{unit:"caracteres",verb:"ter"},file:{unit:"bytes",verb:"ter"},array:{unit:"itens",verb:"ter"},set:{unit:"itens",verb:"ter"}};function r(t){return e[t]??null}let n=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"n\\xFAmero";case"object":{if(Array.isArray(t))return"array";if(t===null)return"nulo";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"padr\\xE3o",email:"endere\\xE7o de e-mail",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"data e hora ISO",date:"data ISO",time:"hora ISO",duration:"dura\\xE7\\xE3o ISO",ipv4:"endere\\xE7o IPv4",ipv6:"endere\\xE7o IPv6",cidrv4:"faixa de IPv4",cidrv6:"faixa de IPv6",base64:"texto codificado em base64",base64url:"URL codificada em base64",json_string:"texto JSON",e164:"n\\xFAmero E.164",jwt:"JWT",template_literal:"entrada"};return t=>{switch(t.code){case"invalid_type":return`Tipo inv\\xE1lido: esperado ${t.expected}, recebido ${n(t.input)}`;case"invalid_value":return t.values.length===1?`Entrada inv\\xE1lida: esperado ${_(t.values[0])}`:`Op\\xE7\\xE3o inv\\xE1lida: esperada uma das ${f(t.values,"|")}`;case"too_big":{let o=t.inclusive?"<=":"<",a=r(t.origin);return a?`Muito grande: esperado que ${t.origin??"valor"} tivesse ${o}${t.maximum.toString()} ${a.unit??"elementos"}`:`Muito grande: esperado que ${t.origin??"valor"} fosse ${o}${t.maximum.toString()}`}case"too_small":{let o=t.inclusive?">=":">",a=r(t.origin);return a?`Muito pequeno: esperado que ${t.origin} tivesse ${o}${t.minimum.toString()} ${a.unit}`:`Muito pequeno: esperado que ${t.origin} fosse ${o}${t.minimum.toString()}`}case"invalid_format":{let o=t;return o.format==="starts_with"?`Texto inv\\xE1lido: deve come\\xE7ar com "${o.prefix}"`:o.format==="ends_with"?`Texto inv\\xE1lido: deve terminar com "${o.suffix}"`:o.format==="includes"?`Texto inv\\xE1lido: deve incluir "${o.includes}"`:o.format==="regex"?`Texto inv\\xE1lido: deve corresponder ao padr\\xE3o ${o.pattern}`:`${i[o.format]??t.format} inv\\xE1lido`}case"not_multiple_of":return`N\\xFAmero inv\\xE1lido: deve ser m\\xFAltiplo de ${t.divisor}`;case"unrecognized_keys":return`Chave${t.keys.length>1?"s":""} desconhecida${t.keys.length>1?"s":""}: ${f(t.keys,", ")}`;case"invalid_key":return`Chave inv\\xE1lida em ${t.origin}`;case"invalid_union":return"Entrada inv\\xE1lida";case"invalid_element":return`Valor inv\\xE1lido em ${t.origin}`;default:return"Campo inv\\xE1lido"}}}});function ml(e,r,n,i){let t=Math.abs(e),o=t%10,a=t%100;return a>=11&&a<=19?i:o===1?r:o>=2&&o<=4?n:i}function fl(){return{localeError:Zm()}}var Zm,gl=S(()=>{P();Zm=()=>{let e={string:{unit:{one:"\\u0441\\u0438\\u043C\\u0432\\u043E\\u043B",few:"\\u0441\\u0438\\u043C\\u0432\\u043E\\u043B\\u0430",many:"\\u0441\\u0438\\u043C\\u0432\\u043E\\u043B\\u043E\\u0432"},verb:"\\u0438\\u043C\\u0435\\u0442\\u044C"},file:{unit:{one:"\\u0431\\u0430\\u0439\\u0442",few:"\\u0431\\u0430\\u0439\\u0442\\u0430",many:"\\u0431\\u0430\\u0439\\u0442"},verb:"\\u0438\\u043C\\u0435\\u0442\\u044C"},array:{unit:{one:"\\u044D\\u043B\\u0435\\u043C\\u0435\\u043D\\u0442",few:"\\u044D\\u043B\\u0435\\u043C\\u0435\\u043D\\u0442\\u0430",many:"\\u044D\\u043B\\u0435\\u043C\\u0435\\u043D\\u0442\\u043E\\u0432"},verb:"\\u0438\\u043C\\u0435\\u0442\\u044C"},set:{unit:{one:"\\u044D\\u043B\\u0435\\u043C\\u0435\\u043D\\u0442",few:"\\u044D\\u043B\\u0435\\u043C\\u0435\\u043D\\u0442\\u0430",many:"\\u044D\\u043B\\u0435\\u043C\\u0435\\u043D\\u0442\\u043E\\u0432"},verb:"\\u0438\\u043C\\u0435\\u0442\\u044C"}};function r(t){return e[t]??null}let n=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"\\u0447\\u0438\\u0441\\u043B\\u043E";case"object":{if(Array.isArray(t))return"\\u043C\\u0430\\u0441\\u0441\\u0438\\u0432";if(t===null)return"null";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"\\u0432\\u0432\\u043E\\u0434",email:"email \\u0430\\u0434\\u0440\\u0435\\u0441",url:"URL",emoji:"\\u044D\\u043C\\u043E\\u0434\\u0437\\u0438",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO \\u0434\\u0430\\u0442\\u0430 \\u0438 \\u0432\\u0440\\u0435\\u043C\\u044F",date:"ISO \\u0434\\u0430\\u0442\\u0430",time:"ISO \\u0432\\u0440\\u0435\\u043C\\u044F",duration:"ISO \\u0434\\u043B\\u0438\\u0442\\u0435\\u043B\\u044C\\u043D\\u043E\\u0441\\u0442\\u044C",ipv4:"IPv4 \\u0430\\u0434\\u0440\\u0435\\u0441",ipv6:"IPv6 \\u0430\\u0434\\u0440\\u0435\\u0441",cidrv4:"IPv4 \\u0434\\u0438\\u0430\\u043F\\u0430\\u0437\\u043E\\u043D",cidrv6:"IPv6 \\u0434\\u0438\\u0430\\u043F\\u0430\\u0437\\u043E\\u043D",base64:"\\u0441\\u0442\\u0440\\u043E\\u043A\\u0430 \\u0432 \\u0444\\u043E\\u0440\\u043C\\u0430\\u0442\\u0435 base64",base64url:"\\u0441\\u0442\\u0440\\u043E\\u043A\\u0430 \\u0432 \\u0444\\u043E\\u0440\\u043C\\u0430\\u0442\\u0435 base64url",json_string:"JSON \\u0441\\u0442\\u0440\\u043E\\u043A\\u0430",e164:"\\u043D\\u043E\\u043C\\u0435\\u0440 E.164",jwt:"JWT",template_literal:"\\u0432\\u0432\\u043E\\u0434"};return t=>{switch(t.code){case"invalid_type":return`\\u041D\\u0435\\u0432\\u0435\\u0440\\u043D\\u044B\\u0439 \\u0432\\u0432\\u043E\\u0434: \\u043E\\u0436\\u0438\\u0434\\u0430\\u043B\\u043E\\u0441\\u044C ${t.expected}, \\u043F\\u043E\\u043B\\u0443\\u0447\\u0435\\u043D\\u043E ${n(t.input)}`;case"invalid_value":return t.values.length===1?`\\u041D\\u0435\\u0432\\u0435\\u0440\\u043D\\u044B\\u0439 \\u0432\\u0432\\u043E\\u0434: \\u043E\\u0436\\u0438\\u0434\\u0430\\u043B\\u043E\\u0441\\u044C ${_(t.values[0])}`:`\\u041D\\u0435\\u0432\\u0435\\u0440\\u043D\\u044B\\u0439 \\u0432\\u0430\\u0440\\u0438\\u0430\\u043D\\u0442: \\u043E\\u0436\\u0438\\u0434\\u0430\\u043B\\u043E\\u0441\\u044C \\u043E\\u0434\\u043D\\u043E \\u0438\\u0437 ${f(t.values,"|")}`;case"too_big":{let o=t.inclusive?"<=":"<",a=r(t.origin);if(a){let c=Number(t.maximum),p=ml(c,a.unit.one,a.unit.few,a.unit.many);return`\\u0421\\u043B\\u0438\\u0448\\u043A\\u043E\\u043C \\u0431\\u043E\\u043B\\u044C\\u0448\\u043E\\u0435 \\u0437\\u043D\\u0430\\u0447\\u0435\\u043D\\u0438\\u0435: \\u043E\\u0436\\u0438\\u0434\\u0430\\u043B\\u043E\\u0441\\u044C, \\u0447\\u0442\\u043E ${t.origin??"\\u0437\\u043D\\u0430\\u0447\\u0435\\u043D\\u0438\\u0435"} \\u0431\\u0443\\u0434\\u0435\\u0442 \\u0438\\u043C\\u0435\\u0442\\u044C ${o}${t.maximum.toString()} ${p}`}return`\\u0421\\u043B\\u0438\\u0448\\u043A\\u043E\\u043C \\u0431\\u043E\\u043B\\u044C\\u0448\\u043E\\u0435 \\u0437\\u043D\\u0430\\u0447\\u0435\\u043D\\u0438\\u0435: \\u043E\\u0436\\u0438\\u0434\\u0430\\u043B\\u043E\\u0441\\u044C, \\u0447\\u0442\\u043E ${t.origin??"\\u0437\\u043D\\u0430\\u0447\\u0435\\u043D\\u0438\\u0435"} \\u0431\\u0443\\u0434\\u0435\\u0442 ${o}${t.maximum.toString()}`}case"too_small":{let o=t.inclusive?">=":">",a=r(t.origin);if(a){let c=Number(t.minimum),p=ml(c,a.unit.one,a.unit.few,a.unit.many);return`\\u0421\\u043B\\u0438\\u0448\\u043A\\u043E\\u043C \\u043C\\u0430\\u043B\\u0435\\u043D\\u044C\\u043A\\u043E\\u0435 \\u0437\\u043D\\u0430\\u0447\\u0435\\u043D\\u0438\\u0435: \\u043E\\u0436\\u0438\\u0434\\u0430\\u043B\\u043E\\u0441\\u044C, \\u0447\\u0442\\u043E ${t.origin} \\u0431\\u0443\\u0434\\u0435\\u0442 \\u0438\\u043C\\u0435\\u0442\\u044C ${o}${t.minimum.toString()} ${p}`}return`\\u0421\\u043B\\u0438\\u0448\\u043A\\u043E\\u043C \\u043C\\u0430\\u043B\\u0435\\u043D\\u044C\\u043A\\u043E\\u0435 \\u0437\\u043D\\u0430\\u0447\\u0435\\u043D\\u0438\\u0435: \\u043E\\u0436\\u0438\\u0434\\u0430\\u043B\\u043E\\u0441\\u044C, \\u0447\\u0442\\u043E ${t.origin} \\u0431\\u0443\\u0434\\u0435\\u0442 ${o}${t.minimum.toString()}`}case"invalid_format":{let o=t;return o.format==="starts_with"?`\\u041D\\u0435\\u0432\\u0435\\u0440\\u043D\\u0430\\u044F \\u0441\\u0442\\u0440\\u043E\\u043A\\u0430: \\u0434\\u043E\\u043B\\u0436\\u043D\\u0430 \\u043D\\u0430\\u0447\\u0438\\u043D\\u0430\\u0442\\u044C\\u0441\\u044F \\u0441 "${o.prefix}"`:o.format==="ends_with"?`\\u041D\\u0435\\u0432\\u0435\\u0440\\u043D\\u0430\\u044F \\u0441\\u0442\\u0440\\u043E\\u043A\\u0430: \\u0434\\u043E\\u043B\\u0436\\u043D\\u0430 \\u0437\\u0430\\u043A\\u0430\\u043D\\u0447\\u0438\\u0432\\u0430\\u0442\\u044C\\u0441\\u044F \\u043D\\u0430 "${o.suffix}"`:o.format==="includes"?`\\u041D\\u0435\\u0432\\u0435\\u0440\\u043D\\u0430\\u044F \\u0441\\u0442\\u0440\\u043E\\u043A\\u0430: \\u0434\\u043E\\u043B\\u0436\\u043D\\u0430 \\u0441\\u043E\\u0434\\u0435\\u0440\\u0436\\u0430\\u0442\\u044C "${o.includes}"`:o.format==="regex"?`\\u041D\\u0435\\u0432\\u0435\\u0440\\u043D\\u0430\\u044F \\u0441\\u0442\\u0440\\u043E\\u043A\\u0430: \\u0434\\u043E\\u043B\\u0436\\u043D\\u0430 \\u0441\\u043E\\u043E\\u0442\\u0432\\u0435\\u0442\\u0441\\u0442\\u0432\\u043E\\u0432\\u0430\\u0442\\u044C \\u0448\\u0430\\u0431\\u043B\\u043E\\u043D\\u0443 ${o.pattern}`:`\\u041D\\u0435\\u0432\\u0435\\u0440\\u043D\\u044B\\u0439 ${i[o.format]??t.format}`}case"not_multiple_of":return`\\u041D\\u0435\\u0432\\u0435\\u0440\\u043D\\u043E\\u0435 \\u0447\\u0438\\u0441\\u043B\\u043E: \\u0434\\u043E\\u043B\\u0436\\u043D\\u043E \\u0431\\u044B\\u0442\\u044C \\u043A\\u0440\\u0430\\u0442\\u043D\\u044B\\u043C ${t.divisor}`;case"unrecognized_keys":return`\\u041D\\u0435\\u0440\\u0430\\u0441\\u043F\\u043E\\u0437\\u043D\\u0430\\u043D\\u043D${t.keys.length>1?"\\u044B\\u0435":"\\u044B\\u0439"} \\u043A\\u043B\\u044E\\u0447${t.keys.length>1?"\\u0438":""}: ${f(t.keys,", ")}`;case"invalid_key":return`\\u041D\\u0435\\u0432\\u0435\\u0440\\u043D\\u044B\\u0439 \\u043A\\u043B\\u044E\\u0447 \\u0432 ${t.origin}`;case"invalid_union":return"\\u041D\\u0435\\u0432\\u0435\\u0440\\u043D\\u044B\\u0435 \\u0432\\u0445\\u043E\\u0434\\u043D\\u044B\\u0435 \\u0434\\u0430\\u043D\\u043D\\u044B\\u0435";case"invalid_element":return`\\u041D\\u0435\\u0432\\u0435\\u0440\\u043D\\u043E\\u0435 \\u0437\\u043D\\u0430\\u0447\\u0435\\u043D\\u0438\\u0435 \\u0432 ${t.origin}`;default:return"\\u041D\\u0435\\u0432\\u0435\\u0440\\u043D\\u044B\\u0435 \\u0432\\u0445\\u043E\\u0434\\u043D\\u044B\\u0435 \\u0434\\u0430\\u043D\\u043D\\u044B\\u0435"}}}});function hl(){return{localeError:Am()}}var Am,vl=S(()=>{P();Am=()=>{let e={string:{unit:"znakov",verb:"imeti"},file:{unit:"bajtov",verb:"imeti"},array:{unit:"elementov",verb:"imeti"},set:{unit:"elementov",verb:"imeti"}};function r(t){return e[t]??null}let n=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"\\u0161tevilo";case"object":{if(Array.isArray(t))return"tabela";if(t===null)return"null";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"vnos",email:"e-po\\u0161tni naslov",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO datum in \\u010Das",date:"ISO datum",time:"ISO \\u010Das",duration:"ISO trajanje",ipv4:"IPv4 naslov",ipv6:"IPv6 naslov",cidrv4:"obseg IPv4",cidrv6:"obseg IPv6",base64:"base64 kodiran niz",base64url:"base64url kodiran niz",json_string:"JSON niz",e164:"E.164 \\u0161tevilka",jwt:"JWT",template_literal:"vnos"};return t=>{switch(t.code){case"invalid_type":return`Neveljaven vnos: pri\\u010Dakovano ${t.expected}, prejeto ${n(t.input)}`;case"invalid_value":return t.values.length===1?`Neveljaven vnos: pri\\u010Dakovano ${_(t.values[0])}`:`Neveljavna mo\\u017Enost: pri\\u010Dakovano eno izmed ${f(t.values,"|")}`;case"too_big":{let o=t.inclusive?"<=":"<",a=r(t.origin);return a?`Preveliko: pri\\u010Dakovano, da bo ${t.origin??"vrednost"} imelo ${o}${t.maximum.toString()} ${a.unit??"elementov"}`:`Preveliko: pri\\u010Dakovano, da bo ${t.origin??"vrednost"} ${o}${t.maximum.toString()}`}case"too_small":{let o=t.inclusive?">=":">",a=r(t.origin);return a?`Premajhno: pri\\u010Dakovano, da bo ${t.origin} imelo ${o}${t.minimum.toString()} ${a.unit}`:`Premajhno: pri\\u010Dakovano, da bo ${t.origin} ${o}${t.minimum.toString()}`}case"invalid_format":{let o=t;return o.format==="starts_with"?`Neveljaven niz: mora se za\\u010Deti z "${o.prefix}"`:o.format==="ends_with"?`Neveljaven niz: mora se kon\\u010Dati z "${o.suffix}"`:o.format==="includes"?`Neveljaven niz: mora vsebovati "${o.includes}"`:o.format==="regex"?`Neveljaven niz: mora ustrezati vzorcu ${o.pattern}`:`Neveljaven ${i[o.format]??t.format}`}case"not_multiple_of":return`Neveljavno \\u0161tevilo: mora biti ve\\u010Dkratnik ${t.divisor}`;case"unrecognized_keys":return`Neprepoznan${t.keys.length>1?"i klju\\u010Di":" klju\\u010D"}: ${f(t.keys,", ")}`;case"invalid_key":return`Neveljaven klju\\u010D v ${t.origin}`;case"invalid_union":return"Neveljaven vnos";case"invalid_element":return`Neveljavna vrednost v ${t.origin}`;default:return"Neveljaven vnos"}}}});function bl(){return{localeError:Cm()}}var Cm,yl=S(()=>{P();Cm=()=>{let e={string:{unit:"tecken",verb:"att ha"},file:{unit:"bytes",verb:"att ha"},array:{unit:"objekt",verb:"att inneh\\xE5lla"},set:{unit:"objekt",verb:"att inneh\\xE5lla"}};function r(t){return e[t]??null}let n=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"antal";case"object":{if(Array.isArray(t))return"lista";if(t===null)return"null";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"regulj\\xE4rt uttryck",email:"e-postadress",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO-datum och tid",date:"ISO-datum",time:"ISO-tid",duration:"ISO-varaktighet",ipv4:"IPv4-intervall",ipv6:"IPv6-intervall",cidrv4:"IPv4-spektrum",cidrv6:"IPv6-spektrum",base64:"base64-kodad str\\xE4ng",base64url:"base64url-kodad str\\xE4ng",json_string:"JSON-str\\xE4ng",e164:"E.164-nummer",jwt:"JWT",template_literal:"mall-literal"};return t=>{switch(t.code){case"invalid_type":return`Ogiltig inmatning: f\\xF6rv\\xE4ntat ${t.expected}, fick ${n(t.input)}`;case"invalid_value":return t.values.length===1?`Ogiltig inmatning: f\\xF6rv\\xE4ntat ${_(t.values[0])}`:`Ogiltigt val: f\\xF6rv\\xE4ntade en av ${f(t.values,"|")}`;case"too_big":{let o=t.inclusive?"<=":"<",a=r(t.origin);return a?`F\\xF6r stor(t): f\\xF6rv\\xE4ntade ${t.origin??"v\\xE4rdet"} att ha ${o}${t.maximum.toString()} ${a.unit??"element"}`:`F\\xF6r stor(t): f\\xF6rv\\xE4ntat ${t.origin??"v\\xE4rdet"} att ha ${o}${t.maximum.toString()}`}case"too_small":{let o=t.inclusive?">=":">",a=r(t.origin);return a?`F\\xF6r lite(t): f\\xF6rv\\xE4ntade ${t.origin??"v\\xE4rdet"} att ha ${o}${t.minimum.toString()} ${a.unit}`:`F\\xF6r lite(t): f\\xF6rv\\xE4ntade ${t.origin??"v\\xE4rdet"} att ha ${o}${t.minimum.toString()}`}case"invalid_format":{let o=t;return o.format==="starts_with"?`Ogiltig str\\xE4ng: m\\xE5ste b\\xF6rja med "${o.prefix}"`:o.format==="ends_with"?`Ogiltig str\\xE4ng: m\\xE5ste sluta med "${o.suffix}"`:o.format==="includes"?`Ogiltig str\\xE4ng: m\\xE5ste inneh\\xE5lla "${o.includes}"`:o.format==="regex"?`Ogiltig str\\xE4ng: m\\xE5ste matcha m\\xF6nstret "${o.pattern}"`:`Ogiltig(t) ${i[o.format]??t.format}`}case"not_multiple_of":return`Ogiltigt tal: m\\xE5ste vara en multipel av ${t.divisor}`;case"unrecognized_keys":return`${t.keys.length>1?"Ok\\xE4nda nycklar":"Ok\\xE4nd nyckel"}: ${f(t.keys,", ")}`;case"invalid_key":return`Ogiltig nyckel i ${t.origin??"v\\xE4rdet"}`;case"invalid_union":return"Ogiltig input";case"invalid_element":return`Ogiltigt v\\xE4rde i ${t.origin??"v\\xE4rdet"}`;default:return"Ogiltig input"}}}});function _l(){return{localeError:Lm()}}var Lm,xl=S(()=>{P();Lm=()=>{let e={string:{unit:"\\u0B8E\\u0BB4\\u0BC1\\u0BA4\\u0BCD\\u0BA4\\u0BC1\\u0B95\\u0BCD\\u0B95\\u0BB3\\u0BCD",verb:"\\u0B95\\u0BCA\\u0BA3\\u0BCD\\u0B9F\\u0BBF\\u0BB0\\u0BC1\\u0B95\\u0BCD\\u0B95 \\u0BB5\\u0BC7\\u0BA3\\u0BCD\\u0B9F\\u0BC1\\u0BAE\\u0BCD"},file:{unit:"\\u0BAA\\u0BC8\\u0B9F\\u0BCD\\u0B9F\\u0BC1\\u0B95\\u0BB3\\u0BCD",verb:"\\u0B95\\u0BCA\\u0BA3\\u0BCD\\u0B9F\\u0BBF\\u0BB0\\u0BC1\\u0B95\\u0BCD\\u0B95 \\u0BB5\\u0BC7\\u0BA3\\u0BCD\\u0B9F\\u0BC1\\u0BAE\\u0BCD"},array:{unit:"\\u0B89\\u0BB1\\u0BC1\\u0BAA\\u0BCD\\u0BAA\\u0BC1\\u0B95\\u0BB3\\u0BCD",verb:"\\u0B95\\u0BCA\\u0BA3\\u0BCD\\u0B9F\\u0BBF\\u0BB0\\u0BC1\\u0B95\\u0BCD\\u0B95 \\u0BB5\\u0BC7\\u0BA3\\u0BCD\\u0B9F\\u0BC1\\u0BAE\\u0BCD"},set:{unit:"\\u0B89\\u0BB1\\u0BC1\\u0BAA\\u0BCD\\u0BAA\\u0BC1\\u0B95\\u0BB3\\u0BCD",verb:"\\u0B95\\u0BCA\\u0BA3\\u0BCD\\u0B9F\\u0BBF\\u0BB0\\u0BC1\\u0B95\\u0BCD\\u0B95 \\u0BB5\\u0BC7\\u0BA3\\u0BCD\\u0B9F\\u0BC1\\u0BAE\\u0BCD"}};function r(t){return e[t]??null}let n=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"\\u0B8E\\u0BA3\\u0BCD \\u0B85\\u0BB2\\u0BCD\\u0BB2\\u0BBE\\u0BA4\\u0BA4\\u0BC1":"\\u0B8E\\u0BA3\\u0BCD";case"object":{if(Array.isArray(t))return"\\u0B85\\u0BA3\\u0BBF";if(t===null)return"\\u0BB5\\u0BC6\\u0BB1\\u0BC1\\u0BAE\\u0BC8";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"\\u0B89\\u0BB3\\u0BCD\\u0BB3\\u0BC0\\u0B9F\\u0BC1",email:"\\u0BAE\\u0BBF\\u0BA9\\u0BCD\\u0BA9\\u0B9E\\u0BCD\\u0B9A\\u0BB2\\u0BCD \\u0BAE\\u0BC1\\u0B95\\u0BB5\\u0BB0\\u0BBF",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO \\u0BA4\\u0BC7\\u0BA4\\u0BBF \\u0BA8\\u0BC7\\u0BB0\\u0BAE\\u0BCD",date:"ISO \\u0BA4\\u0BC7\\u0BA4\\u0BBF",time:"ISO \\u0BA8\\u0BC7\\u0BB0\\u0BAE\\u0BCD",duration:"ISO \\u0B95\\u0BBE\\u0BB2 \\u0B85\\u0BB3\\u0BB5\\u0BC1",ipv4:"IPv4 \\u0BAE\\u0BC1\\u0B95\\u0BB5\\u0BB0\\u0BBF",ipv6:"IPv6 \\u0BAE\\u0BC1\\u0B95\\u0BB5\\u0BB0\\u0BBF",cidrv4:"IPv4 \\u0BB5\\u0BB0\\u0BAE\\u0BCD\\u0BAA\\u0BC1",cidrv6:"IPv6 \\u0BB5\\u0BB0\\u0BAE\\u0BCD\\u0BAA\\u0BC1",base64:"base64-encoded \\u0B9A\\u0BB0\\u0BAE\\u0BCD",base64url:"base64url-encoded \\u0B9A\\u0BB0\\u0BAE\\u0BCD",json_string:"JSON \\u0B9A\\u0BB0\\u0BAE\\u0BCD",e164:"E.164 \\u0B8E\\u0BA3\\u0BCD",jwt:"JWT",template_literal:"input"};return t=>{switch(t.code){case"invalid_type":return`\\u0BA4\\u0BB5\\u0BB1\\u0BBE\\u0BA9 \\u0B89\\u0BB3\\u0BCD\\u0BB3\\u0BC0\\u0B9F\\u0BC1: \\u0B8E\\u0BA4\\u0BBF\\u0BB0\\u0BCD\\u0BAA\\u0BBE\\u0BB0\\u0BCD\\u0B95\\u0BCD\\u0B95\\u0BAA\\u0BCD\\u0BAA\\u0B9F\\u0BCD\\u0B9F\\u0BA4\\u0BC1 ${t.expected}, \\u0BAA\\u0BC6\\u0BB1\\u0BAA\\u0BCD\\u0BAA\\u0B9F\\u0BCD\\u0B9F\\u0BA4\\u0BC1 ${n(t.input)}`;case"invalid_value":return t.values.length===1?`\\u0BA4\\u0BB5\\u0BB1\\u0BBE\\u0BA9 \\u0B89\\u0BB3\\u0BCD\\u0BB3\\u0BC0\\u0B9F\\u0BC1: \\u0B8E\\u0BA4\\u0BBF\\u0BB0\\u0BCD\\u0BAA\\u0BBE\\u0BB0\\u0BCD\\u0B95\\u0BCD\\u0B95\\u0BAA\\u0BCD\\u0BAA\\u0B9F\\u0BCD\\u0B9F\\u0BA4\\u0BC1 ${_(t.values[0])}`:`\\u0BA4\\u0BB5\\u0BB1\\u0BBE\\u0BA9 \\u0BB5\\u0BBF\\u0BB0\\u0BC1\\u0BAA\\u0BCD\\u0BAA\\u0BAE\\u0BCD: \\u0B8E\\u0BA4\\u0BBF\\u0BB0\\u0BCD\\u0BAA\\u0BBE\\u0BB0\\u0BCD\\u0B95\\u0BCD\\u0B95\\u0BAA\\u0BCD\\u0BAA\\u0B9F\\u0BCD\\u0B9F\\u0BA4\\u0BC1 ${f(t.values,"|")} \\u0B87\\u0BB2\\u0BCD \\u0B92\\u0BA9\\u0BCD\\u0BB1\\u0BC1`;case"too_big":{let o=t.inclusive?"<=":"<",a=r(t.origin);return a?`\\u0BAE\\u0BBF\\u0B95 \\u0BAA\\u0BC6\\u0BB0\\u0BBF\\u0BAF\\u0BA4\\u0BC1: \\u0B8E\\u0BA4\\u0BBF\\u0BB0\\u0BCD\\u0BAA\\u0BBE\\u0BB0\\u0BCD\\u0B95\\u0BCD\\u0B95\\u0BAA\\u0BCD\\u0BAA\\u0B9F\\u0BCD\\u0B9F\\u0BA4\\u0BC1 ${t.origin??"\\u0BAE\\u0BA4\\u0BBF\\u0BAA\\u0BCD\\u0BAA\\u0BC1"} ${o}${t.maximum.toString()} ${a.unit??"\\u0B89\\u0BB1\\u0BC1\\u0BAA\\u0BCD\\u0BAA\\u0BC1\\u0B95\\u0BB3\\u0BCD"} \\u0B86\\u0B95 \\u0B87\\u0BB0\\u0BC1\\u0B95\\u0BCD\\u0B95 \\u0BB5\\u0BC7\\u0BA3\\u0BCD\\u0B9F\\u0BC1\\u0BAE\\u0BCD`:`\\u0BAE\\u0BBF\\u0B95 \\u0BAA\\u0BC6\\u0BB0\\u0BBF\\u0BAF\\u0BA4\\u0BC1: \\u0B8E\\u0BA4\\u0BBF\\u0BB0\\u0BCD\\u0BAA\\u0BBE\\u0BB0\\u0BCD\\u0B95\\u0BCD\\u0B95\\u0BAA\\u0BCD\\u0BAA\\u0B9F\\u0BCD\\u0B9F\\u0BA4\\u0BC1 ${t.origin??"\\u0BAE\\u0BA4\\u0BBF\\u0BAA\\u0BCD\\u0BAA\\u0BC1"} ${o}${t.maximum.toString()} \\u0B86\\u0B95 \\u0B87\\u0BB0\\u0BC1\\u0B95\\u0BCD\\u0B95 \\u0BB5\\u0BC7\\u0BA3\\u0BCD\\u0B9F\\u0BC1\\u0BAE\\u0BCD`}case"too_small":{let o=t.inclusive?">=":">",a=r(t.origin);return a?`\\u0BAE\\u0BBF\\u0B95\\u0B9A\\u0BCD \\u0B9A\\u0BBF\\u0BB1\\u0BBF\\u0BAF\\u0BA4\\u0BC1: \\u0B8E\\u0BA4\\u0BBF\\u0BB0\\u0BCD\\u0BAA\\u0BBE\\u0BB0\\u0BCD\\u0B95\\u0BCD\\u0B95\\u0BAA\\u0BCD\\u0BAA\\u0B9F\\u0BCD\\u0B9F\\u0BA4\\u0BC1 ${t.origin} ${o}${t.minimum.toString()} ${a.unit} \\u0B86\\u0B95 \\u0B87\\u0BB0\\u0BC1\\u0B95\\u0BCD\\u0B95 \\u0BB5\\u0BC7\\u0BA3\\u0BCD\\u0B9F\\u0BC1\\u0BAE\\u0BCD`:`\\u0BAE\\u0BBF\\u0B95\\u0B9A\\u0BCD \\u0B9A\\u0BBF\\u0BB1\\u0BBF\\u0BAF\\u0BA4\\u0BC1: \\u0B8E\\u0BA4\\u0BBF\\u0BB0\\u0BCD\\u0BAA\\u0BBE\\u0BB0\\u0BCD\\u0B95\\u0BCD\\u0B95\\u0BAA\\u0BCD\\u0BAA\\u0B9F\\u0BCD\\u0B9F\\u0BA4\\u0BC1 ${t.origin} ${o}${t.minimum.toString()} \\u0B86\\u0B95 \\u0B87\\u0BB0\\u0BC1\\u0B95\\u0BCD\\u0B95 \\u0BB5\\u0BC7\\u0BA3\\u0BCD\\u0B9F\\u0BC1\\u0BAE\\u0BCD`}case"invalid_format":{let o=t;return o.format==="starts_with"?`\\u0BA4\\u0BB5\\u0BB1\\u0BBE\\u0BA9 \\u0B9A\\u0BB0\\u0BAE\\u0BCD: "${o.prefix}" \\u0B87\\u0BB2\\u0BCD \\u0BA4\\u0BCA\\u0B9F\\u0B99\\u0BCD\\u0B95 \\u0BB5\\u0BC7\\u0BA3\\u0BCD\\u0B9F\\u0BC1\\u0BAE\\u0BCD`:o.format==="ends_with"?`\\u0BA4\\u0BB5\\u0BB1\\u0BBE\\u0BA9 \\u0B9A\\u0BB0\\u0BAE\\u0BCD: "${o.suffix}" \\u0B87\\u0BB2\\u0BCD \\u0BAE\\u0BC1\\u0B9F\\u0BBF\\u0BB5\\u0B9F\\u0BC8\\u0BAF \\u0BB5\\u0BC7\\u0BA3\\u0BCD\\u0B9F\\u0BC1\\u0BAE\\u0BCD`:o.format==="includes"?`\\u0BA4\\u0BB5\\u0BB1\\u0BBE\\u0BA9 \\u0B9A\\u0BB0\\u0BAE\\u0BCD: "${o.includes}" \\u0B90 \\u0B89\\u0BB3\\u0BCD\\u0BB3\\u0B9F\\u0B95\\u0BCD\\u0B95 \\u0BB5\\u0BC7\\u0BA3\\u0BCD\\u0B9F\\u0BC1\\u0BAE\\u0BCD`:o.format==="regex"?`\\u0BA4\\u0BB5\\u0BB1\\u0BBE\\u0BA9 \\u0B9A\\u0BB0\\u0BAE\\u0BCD: ${o.pattern} \\u0BAE\\u0BC1\\u0BB1\\u0BC8\\u0BAA\\u0BBE\\u0B9F\\u0BCD\\u0B9F\\u0BC1\\u0B9F\\u0BA9\\u0BCD \\u0BAA\\u0BCA\\u0BB0\\u0BC1\\u0BA8\\u0BCD\\u0BA4 \\u0BB5\\u0BC7\\u0BA3\\u0BCD\\u0B9F\\u0BC1\\u0BAE\\u0BCD`:`\\u0BA4\\u0BB5\\u0BB1\\u0BBE\\u0BA9 ${i[o.format]??t.format}`}case"not_multiple_of":return`\\u0BA4\\u0BB5\\u0BB1\\u0BBE\\u0BA9 \\u0B8E\\u0BA3\\u0BCD: ${t.divisor} \\u0B87\\u0BA9\\u0BCD \\u0BAA\\u0BB2\\u0BAE\\u0BBE\\u0B95 \\u0B87\\u0BB0\\u0BC1\\u0B95\\u0BCD\\u0B95 \\u0BB5\\u0BC7\\u0BA3\\u0BCD\\u0B9F\\u0BC1\\u0BAE\\u0BCD`;case"unrecognized_keys":return`\\u0B85\\u0B9F\\u0BC8\\u0BAF\\u0BBE\\u0BB3\\u0BAE\\u0BCD \\u0BA4\\u0BC6\\u0BB0\\u0BBF\\u0BAF\\u0BBE\\u0BA4 \\u0BB5\\u0BBF\\u0B9A\\u0BC8${t.keys.length>1?"\\u0B95\\u0BB3\\u0BCD":""}: ${f(t.keys,", ")}`;case"invalid_key":return`${t.origin} \\u0B87\\u0BB2\\u0BCD \\u0BA4\\u0BB5\\u0BB1\\u0BBE\\u0BA9 \\u0BB5\\u0BBF\\u0B9A\\u0BC8`;case"invalid_union":return"\\u0BA4\\u0BB5\\u0BB1\\u0BBE\\u0BA9 \\u0B89\\u0BB3\\u0BCD\\u0BB3\\u0BC0\\u0B9F\\u0BC1";case"invalid_element":return`${t.origin} \\u0B87\\u0BB2\\u0BCD \\u0BA4\\u0BB5\\u0BB1\\u0BBE\\u0BA9 \\u0BAE\\u0BA4\\u0BBF\\u0BAA\\u0BCD\\u0BAA\\u0BC1`;default:return"\\u0BA4\\u0BB5\\u0BB1\\u0BBE\\u0BA9 \\u0B89\\u0BB3\\u0BCD\\u0BB3\\u0BC0\\u0B9F\\u0BC1"}}}});function $l(){return{localeError:Mm()}}var Mm,zl=S(()=>{P();Mm=()=>{let e={string:{unit:"\\u0E15\\u0E31\\u0E27\\u0E2D\\u0E31\\u0E01\\u0E29\\u0E23",verb:"\\u0E04\\u0E27\\u0E23\\u0E21\\u0E35"},file:{unit:"\\u0E44\\u0E1A\\u0E15\\u0E4C",verb:"\\u0E04\\u0E27\\u0E23\\u0E21\\u0E35"},array:{unit:"\\u0E23\\u0E32\\u0E22\\u0E01\\u0E32\\u0E23",verb:"\\u0E04\\u0E27\\u0E23\\u0E21\\u0E35"},set:{unit:"\\u0E23\\u0E32\\u0E22\\u0E01\\u0E32\\u0E23",verb:"\\u0E04\\u0E27\\u0E23\\u0E21\\u0E35"}};function r(t){return e[t]??null}let n=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"\\u0E44\\u0E21\\u0E48\\u0E43\\u0E0A\\u0E48\\u0E15\\u0E31\\u0E27\\u0E40\\u0E25\\u0E02 (NaN)":"\\u0E15\\u0E31\\u0E27\\u0E40\\u0E25\\u0E02";case"object":{if(Array.isArray(t))return"\\u0E2D\\u0E32\\u0E23\\u0E4C\\u0E40\\u0E23\\u0E22\\u0E4C (Array)";if(t===null)return"\\u0E44\\u0E21\\u0E48\\u0E21\\u0E35\\u0E04\\u0E48\\u0E32 (null)";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"\\u0E02\\u0E49\\u0E2D\\u0E21\\u0E39\\u0E25\\u0E17\\u0E35\\u0E48\\u0E1B\\u0E49\\u0E2D\\u0E19",email:"\\u0E17\\u0E35\\u0E48\\u0E2D\\u0E22\\u0E39\\u0E48\\u0E2D\\u0E35\\u0E40\\u0E21\\u0E25",url:"URL",emoji:"\\u0E2D\\u0E34\\u0E42\\u0E21\\u0E08\\u0E34",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"\\u0E27\\u0E31\\u0E19\\u0E17\\u0E35\\u0E48\\u0E40\\u0E27\\u0E25\\u0E32\\u0E41\\u0E1A\\u0E1A ISO",date:"\\u0E27\\u0E31\\u0E19\\u0E17\\u0E35\\u0E48\\u0E41\\u0E1A\\u0E1A ISO",time:"\\u0E40\\u0E27\\u0E25\\u0E32\\u0E41\\u0E1A\\u0E1A ISO",duration:"\\u0E0A\\u0E48\\u0E27\\u0E07\\u0E40\\u0E27\\u0E25\\u0E32\\u0E41\\u0E1A\\u0E1A ISO",ipv4:"\\u0E17\\u0E35\\u0E48\\u0E2D\\u0E22\\u0E39\\u0E48 IPv4",ipv6:"\\u0E17\\u0E35\\u0E48\\u0E2D\\u0E22\\u0E39\\u0E48 IPv6",cidrv4:"\\u0E0A\\u0E48\\u0E27\\u0E07 IP \\u0E41\\u0E1A\\u0E1A IPv4",cidrv6:"\\u0E0A\\u0E48\\u0E27\\u0E07 IP \\u0E41\\u0E1A\\u0E1A IPv6",base64:"\\u0E02\\u0E49\\u0E2D\\u0E04\\u0E27\\u0E32\\u0E21\\u0E41\\u0E1A\\u0E1A Base64",base64url:"\\u0E02\\u0E49\\u0E2D\\u0E04\\u0E27\\u0E32\\u0E21\\u0E41\\u0E1A\\u0E1A Base64 \\u0E2A\\u0E33\\u0E2B\\u0E23\\u0E31\\u0E1A URL",json_string:"\\u0E02\\u0E49\\u0E2D\\u0E04\\u0E27\\u0E32\\u0E21\\u0E41\\u0E1A\\u0E1A JSON",e164:"\\u0E40\\u0E1A\\u0E2D\\u0E23\\u0E4C\\u0E42\\u0E17\\u0E23\\u0E28\\u0E31\\u0E1E\\u0E17\\u0E4C\\u0E23\\u0E30\\u0E2B\\u0E27\\u0E48\\u0E32\\u0E07\\u0E1B\\u0E23\\u0E30\\u0E40\\u0E17\\u0E28 (E.164)",jwt:"\\u0E42\\u0E17\\u0E40\\u0E04\\u0E19 JWT",template_literal:"\\u0E02\\u0E49\\u0E2D\\u0E21\\u0E39\\u0E25\\u0E17\\u0E35\\u0E48\\u0E1B\\u0E49\\u0E2D\\u0E19"};return t=>{switch(t.code){case"invalid_type":return`\\u0E1B\\u0E23\\u0E30\\u0E40\\u0E20\\u0E17\\u0E02\\u0E49\\u0E2D\\u0E21\\u0E39\\u0E25\\u0E44\\u0E21\\u0E48\\u0E16\\u0E39\\u0E01\\u0E15\\u0E49\\u0E2D\\u0E07: \\u0E04\\u0E27\\u0E23\\u0E40\\u0E1B\\u0E47\\u0E19 ${t.expected} \\u0E41\\u0E15\\u0E48\\u0E44\\u0E14\\u0E49\\u0E23\\u0E31\\u0E1A ${n(t.input)}`;case"invalid_value":return t.values.length===1?`\\u0E04\\u0E48\\u0E32\\u0E44\\u0E21\\u0E48\\u0E16\\u0E39\\u0E01\\u0E15\\u0E49\\u0E2D\\u0E07: \\u0E04\\u0E27\\u0E23\\u0E40\\u0E1B\\u0E47\\u0E19 ${_(t.values[0])}`:`\\u0E15\\u0E31\\u0E27\\u0E40\\u0E25\\u0E37\\u0E2D\\u0E01\\u0E44\\u0E21\\u0E48\\u0E16\\u0E39\\u0E01\\u0E15\\u0E49\\u0E2D\\u0E07: \\u0E04\\u0E27\\u0E23\\u0E40\\u0E1B\\u0E47\\u0E19\\u0E2B\\u0E19\\u0E36\\u0E48\\u0E07\\u0E43\\u0E19 ${f(t.values,"|")}`;case"too_big":{let o=t.inclusive?"\\u0E44\\u0E21\\u0E48\\u0E40\\u0E01\\u0E34\\u0E19":"\\u0E19\\u0E49\\u0E2D\\u0E22\\u0E01\\u0E27\\u0E48\\u0E32",a=r(t.origin);return a?`\\u0E40\\u0E01\\u0E34\\u0E19\\u0E01\\u0E33\\u0E2B\\u0E19\\u0E14: ${t.origin??"\\u0E04\\u0E48\\u0E32"} \\u0E04\\u0E27\\u0E23\\u0E21\\u0E35${o} ${t.maximum.toString()} ${a.unit??"\\u0E23\\u0E32\\u0E22\\u0E01\\u0E32\\u0E23"}`:`\\u0E40\\u0E01\\u0E34\\u0E19\\u0E01\\u0E33\\u0E2B\\u0E19\\u0E14: ${t.origin??"\\u0E04\\u0E48\\u0E32"} \\u0E04\\u0E27\\u0E23\\u0E21\\u0E35${o} ${t.maximum.toString()}`}case"too_small":{let o=t.inclusive?"\\u0E2D\\u0E22\\u0E48\\u0E32\\u0E07\\u0E19\\u0E49\\u0E2D\\u0E22":"\\u0E21\\u0E32\\u0E01\\u0E01\\u0E27\\u0E48\\u0E32",a=r(t.origin);return a?`\\u0E19\\u0E49\\u0E2D\\u0E22\\u0E01\\u0E27\\u0E48\\u0E32\\u0E01\\u0E33\\u0E2B\\u0E19\\u0E14: ${t.origin} \\u0E04\\u0E27\\u0E23\\u0E21\\u0E35${o} ${t.minimum.toString()} ${a.unit}`:`\\u0E19\\u0E49\\u0E2D\\u0E22\\u0E01\\u0E27\\u0E48\\u0E32\\u0E01\\u0E33\\u0E2B\\u0E19\\u0E14: ${t.origin} \\u0E04\\u0E27\\u0E23\\u0E21\\u0E35${o} ${t.minimum.toString()}`}case"invalid_format":{let o=t;return o.format==="starts_with"?`\\u0E23\\u0E39\\u0E1B\\u0E41\\u0E1A\\u0E1A\\u0E44\\u0E21\\u0E48\\u0E16\\u0E39\\u0E01\\u0E15\\u0E49\\u0E2D\\u0E07: \\u0E02\\u0E49\\u0E2D\\u0E04\\u0E27\\u0E32\\u0E21\\u0E15\\u0E49\\u0E2D\\u0E07\\u0E02\\u0E36\\u0E49\\u0E19\\u0E15\\u0E49\\u0E19\\u0E14\\u0E49\\u0E27\\u0E22 "${o.prefix}"`:o.format==="ends_with"?`\\u0E23\\u0E39\\u0E1B\\u0E41\\u0E1A\\u0E1A\\u0E44\\u0E21\\u0E48\\u0E16\\u0E39\\u0E01\\u0E15\\u0E49\\u0E2D\\u0E07: \\u0E02\\u0E49\\u0E2D\\u0E04\\u0E27\\u0E32\\u0E21\\u0E15\\u0E49\\u0E2D\\u0E07\\u0E25\\u0E07\\u0E17\\u0E49\\u0E32\\u0E22\\u0E14\\u0E49\\u0E27\\u0E22 "${o.suffix}"`:o.format==="includes"?`\\u0E23\\u0E39\\u0E1B\\u0E41\\u0E1A\\u0E1A\\u0E44\\u0E21\\u0E48\\u0E16\\u0E39\\u0E01\\u0E15\\u0E49\\u0E2D\\u0E07: \\u0E02\\u0E49\\u0E2D\\u0E04\\u0E27\\u0E32\\u0E21\\u0E15\\u0E49\\u0E2D\\u0E07\\u0E21\\u0E35 "${o.includes}" \\u0E2D\\u0E22\\u0E39\\u0E48\\u0E43\\u0E19\\u0E02\\u0E49\\u0E2D\\u0E04\\u0E27\\u0E32\\u0E21`:o.format==="regex"?`\\u0E23\\u0E39\\u0E1B\\u0E41\\u0E1A\\u0E1A\\u0E44\\u0E21\\u0E48\\u0E16\\u0E39\\u0E01\\u0E15\\u0E49\\u0E2D\\u0E07: \\u0E15\\u0E49\\u0E2D\\u0E07\\u0E15\\u0E23\\u0E07\\u0E01\\u0E31\\u0E1A\\u0E23\\u0E39\\u0E1B\\u0E41\\u0E1A\\u0E1A\\u0E17\\u0E35\\u0E48\\u0E01\\u0E33\\u0E2B\\u0E19\\u0E14 ${o.pattern}`:`\\u0E23\\u0E39\\u0E1B\\u0E41\\u0E1A\\u0E1A\\u0E44\\u0E21\\u0E48\\u0E16\\u0E39\\u0E01\\u0E15\\u0E49\\u0E2D\\u0E07: ${i[o.format]??t.format}`}case"not_multiple_of":return`\\u0E15\\u0E31\\u0E27\\u0E40\\u0E25\\u0E02\\u0E44\\u0E21\\u0E48\\u0E16\\u0E39\\u0E01\\u0E15\\u0E49\\u0E2D\\u0E07: \\u0E15\\u0E49\\u0E2D\\u0E07\\u0E40\\u0E1B\\u0E47\\u0E19\\u0E08\\u0E33\\u0E19\\u0E27\\u0E19\\u0E17\\u0E35\\u0E48\\u0E2B\\u0E32\\u0E23\\u0E14\\u0E49\\u0E27\\u0E22 ${t.divisor} \\u0E44\\u0E14\\u0E49\\u0E25\\u0E07\\u0E15\\u0E31\\u0E27`;case"unrecognized_keys":return`\\u0E1E\\u0E1A\\u0E04\\u0E35\\u0E22\\u0E4C\\u0E17\\u0E35\\u0E48\\u0E44\\u0E21\\u0E48\\u0E23\\u0E39\\u0E49\\u0E08\\u0E31\\u0E01: ${f(t.keys,", ")}`;case"invalid_key":return`\\u0E04\\u0E35\\u0E22\\u0E4C\\u0E44\\u0E21\\u0E48\\u0E16\\u0E39\\u0E01\\u0E15\\u0E49\\u0E2D\\u0E07\\u0E43\\u0E19 ${t.origin}`;case"invalid_union":return"\\u0E02\\u0E49\\u0E2D\\u0E21\\u0E39\\u0E25\\u0E44\\u0E21\\u0E48\\u0E16\\u0E39\\u0E01\\u0E15\\u0E49\\u0E2D\\u0E07: \\u0E44\\u0E21\\u0E48\\u0E15\\u0E23\\u0E07\\u0E01\\u0E31\\u0E1A\\u0E23\\u0E39\\u0E1B\\u0E41\\u0E1A\\u0E1A\\u0E22\\u0E39\\u0E40\\u0E19\\u0E35\\u0E22\\u0E19\\u0E17\\u0E35\\u0E48\\u0E01\\u0E33\\u0E2B\\u0E19\\u0E14\\u0E44\\u0E27\\u0E49";case"invalid_element":return`\\u0E02\\u0E49\\u0E2D\\u0E21\\u0E39\\u0E25\\u0E44\\u0E21\\u0E48\\u0E16\\u0E39\\u0E01\\u0E15\\u0E49\\u0E2D\\u0E07\\u0E43\\u0E19 ${t.origin}`;default:return"\\u0E02\\u0E49\\u0E2D\\u0E21\\u0E39\\u0E25\\u0E44\\u0E21\\u0E48\\u0E16\\u0E39\\u0E01\\u0E15\\u0E49\\u0E2D\\u0E07"}}}});function kl(){return{localeError:Fm()}}var qm,Fm,Sl=S(()=>{P();qm=e=>{let r=typeof e;switch(r){case"number":return Number.isNaN(e)?"NaN":"number";case"object":{if(Array.isArray(e))return"array";if(e===null)return"null";if(Object.getPrototypeOf(e)!==Object.prototype&&e.constructor)return e.constructor.name}}return r},Fm=()=>{let e={string:{unit:"karakter",verb:"olmal\\u0131"},file:{unit:"bayt",verb:"olmal\\u0131"},array:{unit:"\\xF6\\u011Fe",verb:"olmal\\u0131"},set:{unit:"\\xF6\\u011Fe",verb:"olmal\\u0131"}};function r(i){return e[i]??null}let n={regex:"girdi",email:"e-posta adresi",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO tarih ve saat",date:"ISO tarih",time:"ISO saat",duration:"ISO s\\xFCre",ipv4:"IPv4 adresi",ipv6:"IPv6 adresi",cidrv4:"IPv4 aral\\u0131\\u011F\\u0131",cidrv6:"IPv6 aral\\u0131\\u011F\\u0131",base64:"base64 ile \\u015Fifrelenmi\\u015F metin",base64url:"base64url ile \\u015Fifrelenmi\\u015F metin",json_string:"JSON dizesi",e164:"E.164 say\\u0131s\\u0131",jwt:"JWT",template_literal:"\\u015Eablon dizesi"};return i=>{switch(i.code){case"invalid_type":return`Ge\\xE7ersiz de\\u011Fer: beklenen ${i.expected}, al\\u0131nan ${qm(i.input)}`;case"invalid_value":return i.values.length===1?`Ge\\xE7ersiz de\\u011Fer: beklenen ${_(i.values[0])}`:`Ge\\xE7ersiz se\\xE7enek: a\\u015Fa\\u011F\\u0131dakilerden biri olmal\\u0131: ${f(i.values,"|")}`;case"too_big":{let t=i.inclusive?"<=":"<",o=r(i.origin);return o?`\\xC7ok b\\xFCy\\xFCk: beklenen ${i.origin??"de\\u011Fer"} ${t}${i.maximum.toString()} ${o.unit??"\\xF6\\u011Fe"}`:`\\xC7ok b\\xFCy\\xFCk: beklenen ${i.origin??"de\\u011Fer"} ${t}${i.maximum.toString()}`}case"too_small":{let t=i.inclusive?">=":">",o=r(i.origin);return o?`\\xC7ok k\\xFC\\xE7\\xFCk: beklenen ${i.origin} ${t}${i.minimum.toString()} ${o.unit}`:`\\xC7ok k\\xFC\\xE7\\xFCk: beklenen ${i.origin} ${t}${i.minimum.toString()}`}case"invalid_format":{let t=i;return t.format==="starts_with"?`Ge\\xE7ersiz metin: "${t.prefix}" ile ba\\u015Flamal\\u0131`:t.format==="ends_with"?`Ge\\xE7ersiz metin: "${t.suffix}" ile bitmeli`:t.format==="includes"?`Ge\\xE7ersiz metin: "${t.includes}" i\\xE7ermeli`:t.format==="regex"?`Ge\\xE7ersiz metin: ${t.pattern} desenine uymal\\u0131`:`Ge\\xE7ersiz ${n[t.format]??i.format}`}case"not_multiple_of":return`Ge\\xE7ersiz say\\u0131: ${i.divisor} ile tam b\\xF6l\\xFCnebilmeli`;case"unrecognized_keys":return`Tan\\u0131nmayan anahtar${i.keys.length>1?"lar":""}: ${f(i.keys,", ")}`;case"invalid_key":return`${i.origin} i\\xE7inde ge\\xE7ersiz anahtar`;case"invalid_union":return"Ge\\xE7ersiz de\\u011Fer";case"invalid_element":return`${i.origin} i\\xE7inde ge\\xE7ersiz de\\u011Fer`;default:return"Ge\\xE7ersiz de\\u011Fer"}}}});function wl(){return{localeError:Hm()}}var Hm,Il=S(()=>{P();Hm=()=>{let e={string:{unit:"\\u0441\\u0438\\u043C\\u0432\\u043E\\u043B\\u0456\\u0432",verb:"\\u043C\\u0430\\u0442\\u0438\\u043C\\u0435"},file:{unit:"\\u0431\\u0430\\u0439\\u0442\\u0456\\u0432",verb:"\\u043C\\u0430\\u0442\\u0438\\u043C\\u0435"},array:{unit:"\\u0435\\u043B\\u0435\\u043C\\u0435\\u043D\\u0442\\u0456\\u0432",verb:"\\u043C\\u0430\\u0442\\u0438\\u043C\\u0435"},set:{unit:"\\u0435\\u043B\\u0435\\u043C\\u0435\\u043D\\u0442\\u0456\\u0432",verb:"\\u043C\\u0430\\u0442\\u0438\\u043C\\u0435"}};function r(t){return e[t]??null}let n=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"\\u0447\\u0438\\u0441\\u043B\\u043E";case"object":{if(Array.isArray(t))return"\\u043C\\u0430\\u0441\\u0438\\u0432";if(t===null)return"null";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"\\u0432\\u0445\\u0456\\u0434\\u043D\\u0456 \\u0434\\u0430\\u043D\\u0456",email:"\\u0430\\u0434\\u0440\\u0435\\u0441\\u0430 \\u0435\\u043B\\u0435\\u043A\\u0442\\u0440\\u043E\\u043D\\u043D\\u043E\\u0457 \\u043F\\u043E\\u0448\\u0442\\u0438",url:"URL",emoji:"\\u0435\\u043C\\u043E\\u0434\\u0437\\u0456",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"\\u0434\\u0430\\u0442\\u0430 \\u0442\\u0430 \\u0447\\u0430\\u0441 ISO",date:"\\u0434\\u0430\\u0442\\u0430 ISO",time:"\\u0447\\u0430\\u0441 ISO",duration:"\\u0442\\u0440\\u0438\\u0432\\u0430\\u043B\\u0456\\u0441\\u0442\\u044C ISO",ipv4:"\\u0430\\u0434\\u0440\\u0435\\u0441\\u0430 IPv4",ipv6:"\\u0430\\u0434\\u0440\\u0435\\u0441\\u0430 IPv6",cidrv4:"\\u0434\\u0456\\u0430\\u043F\\u0430\\u0437\\u043E\\u043D IPv4",cidrv6:"\\u0434\\u0456\\u0430\\u043F\\u0430\\u0437\\u043E\\u043D IPv6",base64:"\\u0440\\u044F\\u0434\\u043E\\u043A \\u0443 \\u043A\\u043E\\u0434\\u0443\\u0432\\u0430\\u043D\\u043D\\u0456 base64",base64url:"\\u0440\\u044F\\u0434\\u043E\\u043A \\u0443 \\u043A\\u043E\\u0434\\u0443\\u0432\\u0430\\u043D\\u043D\\u0456 base64url",json_string:"\\u0440\\u044F\\u0434\\u043E\\u043A JSON",e164:"\\u043D\\u043E\\u043C\\u0435\\u0440 E.164",jwt:"JWT",template_literal:"\\u0432\\u0445\\u0456\\u0434\\u043D\\u0456 \\u0434\\u0430\\u043D\\u0456"};return t=>{switch(t.code){case"invalid_type":return`\\u041D\\u0435\\u043F\\u0440\\u0430\\u0432\\u0438\\u043B\\u044C\\u043D\\u0456 \\u0432\\u0445\\u0456\\u0434\\u043D\\u0456 \\u0434\\u0430\\u043D\\u0456: \\u043E\\u0447\\u0456\\u043A\\u0443\\u0454\\u0442\\u044C\\u0441\\u044F ${t.expected}, \\u043E\\u0442\\u0440\\u0438\\u043C\\u0430\\u043D\\u043E ${n(t.input)}`;case"invalid_value":return t.values.length===1?`\\u041D\\u0435\\u043F\\u0440\\u0430\\u0432\\u0438\\u043B\\u044C\\u043D\\u0456 \\u0432\\u0445\\u0456\\u0434\\u043D\\u0456 \\u0434\\u0430\\u043D\\u0456: \\u043E\\u0447\\u0456\\u043A\\u0443\\u0454\\u0442\\u044C\\u0441\\u044F ${_(t.values[0])}`:`\\u041D\\u0435\\u043F\\u0440\\u0430\\u0432\\u0438\\u043B\\u044C\\u043D\\u0430 \\u043E\\u043F\\u0446\\u0456\\u044F: \\u043E\\u0447\\u0456\\u043A\\u0443\\u0454\\u0442\\u044C\\u0441\\u044F \\u043E\\u0434\\u043D\\u0435 \\u0437 ${f(t.values,"|")}`;case"too_big":{let o=t.inclusive?"<=":"<",a=r(t.origin);return a?`\\u0417\\u0430\\u043D\\u0430\\u0434\\u0442\\u043E \\u0432\\u0435\\u043B\\u0438\\u043A\\u0435: \\u043E\\u0447\\u0456\\u043A\\u0443\\u0454\\u0442\\u044C\\u0441\\u044F, \\u0449\\u043E ${t.origin??"\\u0437\\u043D\\u0430\\u0447\\u0435\\u043D\\u043D\\u044F"} ${a.verb} ${o}${t.maximum.toString()} ${a.unit??"\\u0435\\u043B\\u0435\\u043C\\u0435\\u043D\\u0442\\u0456\\u0432"}`:`\\u0417\\u0430\\u043D\\u0430\\u0434\\u0442\\u043E \\u0432\\u0435\\u043B\\u0438\\u043A\\u0435: \\u043E\\u0447\\u0456\\u043A\\u0443\\u0454\\u0442\\u044C\\u0441\\u044F, \\u0449\\u043E ${t.origin??"\\u0437\\u043D\\u0430\\u0447\\u0435\\u043D\\u043D\\u044F"} \\u0431\\u0443\\u0434\\u0435 ${o}${t.maximum.toString()}`}case"too_small":{let o=t.inclusive?">=":">",a=r(t.origin);return a?`\\u0417\\u0430\\u043D\\u0430\\u0434\\u0442\\u043E \\u043C\\u0430\\u043B\\u0435: \\u043E\\u0447\\u0456\\u043A\\u0443\\u0454\\u0442\\u044C\\u0441\\u044F, \\u0449\\u043E ${t.origin} ${a.verb} ${o}${t.minimum.toString()} ${a.unit}`:`\\u0417\\u0430\\u043D\\u0430\\u0434\\u0442\\u043E \\u043C\\u0430\\u043B\\u0435: \\u043E\\u0447\\u0456\\u043A\\u0443\\u0454\\u0442\\u044C\\u0441\\u044F, \\u0449\\u043E ${t.origin} \\u0431\\u0443\\u0434\\u0435 ${o}${t.minimum.toString()}`}case"invalid_format":{let o=t;return o.format==="starts_with"?`\\u041D\\u0435\\u043F\\u0440\\u0430\\u0432\\u0438\\u043B\\u044C\\u043D\\u0438\\u0439 \\u0440\\u044F\\u0434\\u043E\\u043A: \\u043F\\u043E\\u0432\\u0438\\u043D\\u0435\\u043D \\u043F\\u043E\\u0447\\u0438\\u043D\\u0430\\u0442\\u0438\\u0441\\u044F \\u0437 "${o.prefix}"`:o.format==="ends_with"?`\\u041D\\u0435\\u043F\\u0440\\u0430\\u0432\\u0438\\u043B\\u044C\\u043D\\u0438\\u0439 \\u0440\\u044F\\u0434\\u043E\\u043A: \\u043F\\u043E\\u0432\\u0438\\u043D\\u0435\\u043D \\u0437\\u0430\\u043A\\u0456\\u043D\\u0447\\u0443\\u0432\\u0430\\u0442\\u0438\\u0441\\u044F \\u043D\\u0430 "${o.suffix}"`:o.format==="includes"?`\\u041D\\u0435\\u043F\\u0440\\u0430\\u0432\\u0438\\u043B\\u044C\\u043D\\u0438\\u0439 \\u0440\\u044F\\u0434\\u043E\\u043A: \\u043F\\u043E\\u0432\\u0438\\u043D\\u0435\\u043D \\u043C\\u0456\\u0441\\u0442\\u0438\\u0442\\u0438 "${o.includes}"`:o.format==="regex"?`\\u041D\\u0435\\u043F\\u0440\\u0430\\u0432\\u0438\\u043B\\u044C\\u043D\\u0438\\u0439 \\u0440\\u044F\\u0434\\u043E\\u043A: \\u043F\\u043E\\u0432\\u0438\\u043D\\u0435\\u043D \\u0432\\u0456\\u0434\\u043F\\u043E\\u0432\\u0456\\u0434\\u0430\\u0442\\u0438 \\u0448\\u0430\\u0431\\u043B\\u043E\\u043D\\u0443 ${o.pattern}`:`\\u041D\\u0435\\u043F\\u0440\\u0430\\u0432\\u0438\\u043B\\u044C\\u043D\\u0438\\u0439 ${i[o.format]??t.format}`}case"not_multiple_of":return`\\u041D\\u0435\\u043F\\u0440\\u0430\\u0432\\u0438\\u043B\\u044C\\u043D\\u0435 \\u0447\\u0438\\u0441\\u043B\\u043E: \\u043F\\u043E\\u0432\\u0438\\u043D\\u043D\\u043E \\u0431\\u0443\\u0442\\u0438 \\u043A\\u0440\\u0430\\u0442\\u043D\\u0438\\u043C ${t.divisor}`;case"unrecognized_keys":return`\\u041D\\u0435\\u0440\\u043E\\u0437\\u043F\\u0456\\u0437\\u043D\\u0430\\u043D\\u0438\\u0439 \\u043A\\u043B\\u044E\\u0447${t.keys.length>1?"\\u0456":""}: ${f(t.keys,", ")}`;case"invalid_key":return`\\u041D\\u0435\\u043F\\u0440\\u0430\\u0432\\u0438\\u043B\\u044C\\u043D\\u0438\\u0439 \\u043A\\u043B\\u044E\\u0447 \\u0443 ${t.origin}`;case"invalid_union":return"\\u041D\\u0435\\u043F\\u0440\\u0430\\u0432\\u0438\\u043B\\u044C\\u043D\\u0456 \\u0432\\u0445\\u0456\\u0434\\u043D\\u0456 \\u0434\\u0430\\u043D\\u0456";case"invalid_element":return`\\u041D\\u0435\\u043F\\u0440\\u0430\\u0432\\u0438\\u043B\\u044C\\u043D\\u0435 \\u0437\\u043D\\u0430\\u0447\\u0435\\u043D\\u043D\\u044F \\u0443 ${t.origin}`;default:return"\\u041D\\u0435\\u043F\\u0440\\u0430\\u0432\\u0438\\u043B\\u044C\\u043D\\u0456 \\u0432\\u0445\\u0456\\u0434\\u043D\\u0456 \\u0434\\u0430\\u043D\\u0456"}}}});function jl(){return{localeError:Vm()}}var Vm,Pl=S(()=>{P();Vm=()=>{let e={string:{unit:"\\u062D\\u0631\\u0648\\u0641",verb:"\\u06C1\\u0648\\u0646\\u0627"},file:{unit:"\\u0628\\u0627\\u0626\\u0679\\u0633",verb:"\\u06C1\\u0648\\u0646\\u0627"},array:{unit:"\\u0622\\u0626\\u0679\\u0645\\u0632",verb:"\\u06C1\\u0648\\u0646\\u0627"},set:{unit:"\\u0622\\u0626\\u0679\\u0645\\u0632",verb:"\\u06C1\\u0648\\u0646\\u0627"}};function r(t){return e[t]??null}let n=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"\\u0646\\u0645\\u0628\\u0631";case"object":{if(Array.isArray(t))return"\\u0622\\u0631\\u06D2";if(t===null)return"\\u0646\\u0644";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"\\u0627\\u0646 \\u067E\\u0679",email:"\\u0627\\u06CC \\u0645\\u06CC\\u0644 \\u0627\\u06CC\\u0688\\u0631\\u06CC\\u0633",url:"\\u06CC\\u0648 \\u0622\\u0631 \\u0627\\u06CC\\u0644",emoji:"\\u0627\\u06CC\\u0645\\u0648\\u062C\\u06CC",uuid:"\\u06CC\\u0648 \\u06CC\\u0648 \\u0622\\u0626\\u06CC \\u0688\\u06CC",uuidv4:"\\u06CC\\u0648 \\u06CC\\u0648 \\u0622\\u0626\\u06CC \\u0688\\u06CC \\u0648\\u06CC 4",uuidv6:"\\u06CC\\u0648 \\u06CC\\u0648 \\u0622\\u0626\\u06CC \\u0688\\u06CC \\u0648\\u06CC 6",nanoid:"\\u0646\\u06CC\\u0646\\u0648 \\u0622\\u0626\\u06CC \\u0688\\u06CC",guid:"\\u062C\\u06CC \\u06CC\\u0648 \\u0622\\u0626\\u06CC \\u0688\\u06CC",cuid:"\\u0633\\u06CC \\u06CC\\u0648 \\u0622\\u0626\\u06CC \\u0688\\u06CC",cuid2:"\\u0633\\u06CC \\u06CC\\u0648 \\u0622\\u0626\\u06CC \\u0688\\u06CC 2",ulid:"\\u06CC\\u0648 \\u0627\\u06CC\\u0644 \\u0622\\u0626\\u06CC \\u0688\\u06CC",xid:"\\u0627\\u06CC\\u06A9\\u0633 \\u0622\\u0626\\u06CC \\u0688\\u06CC",ksuid:"\\u06A9\\u06D2 \\u0627\\u06CC\\u0633 \\u06CC\\u0648 \\u0622\\u0626\\u06CC \\u0688\\u06CC",datetime:"\\u0622\\u0626\\u06CC \\u0627\\u06CC\\u0633 \\u0627\\u0648 \\u0688\\u06CC\\u0679 \\u0679\\u0627\\u0626\\u0645",date:"\\u0622\\u0626\\u06CC \\u0627\\u06CC\\u0633 \\u0627\\u0648 \\u062A\\u0627\\u0631\\u06CC\\u062E",time:"\\u0622\\u0626\\u06CC \\u0627\\u06CC\\u0633 \\u0627\\u0648 \\u0648\\u0642\\u062A",duration:"\\u0622\\u0626\\u06CC \\u0627\\u06CC\\u0633 \\u0627\\u0648 \\u0645\\u062F\\u062A",ipv4:"\\u0622\\u0626\\u06CC \\u067E\\u06CC \\u0648\\u06CC 4 \\u0627\\u06CC\\u0688\\u0631\\u06CC\\u0633",ipv6:"\\u0622\\u0626\\u06CC \\u067E\\u06CC \\u0648\\u06CC 6 \\u0627\\u06CC\\u0688\\u0631\\u06CC\\u0633",cidrv4:"\\u0622\\u0626\\u06CC \\u067E\\u06CC \\u0648\\u06CC 4 \\u0631\\u06CC\\u0646\\u062C",cidrv6:"\\u0622\\u0626\\u06CC \\u067E\\u06CC \\u0648\\u06CC 6 \\u0631\\u06CC\\u0646\\u062C",base64:"\\u0628\\u06CC\\u0633 64 \\u0627\\u0646 \\u06A9\\u0648\\u0688\\u0688 \\u0633\\u0679\\u0631\\u0646\\u06AF",base64url:"\\u0628\\u06CC\\u0633 64 \\u06CC\\u0648 \\u0622\\u0631 \\u0627\\u06CC\\u0644 \\u0627\\u0646 \\u06A9\\u0648\\u0688\\u0688 \\u0633\\u0679\\u0631\\u0646\\u06AF",json_string:"\\u062C\\u06D2 \\u0627\\u06CC\\u0633 \\u0627\\u0648 \\u0627\\u06CC\\u0646 \\u0633\\u0679\\u0631\\u0646\\u06AF",e164:"\\u0627\\u06CC 164 \\u0646\\u0645\\u0628\\u0631",jwt:"\\u062C\\u06D2 \\u0688\\u0628\\u0644\\u06CC\\u0648 \\u0679\\u06CC",template_literal:"\\u0627\\u0646 \\u067E\\u0679"};return t=>{switch(t.code){case"invalid_type":return`\\u063A\\u0644\\u0637 \\u0627\\u0646 \\u067E\\u0679: ${t.expected} \\u0645\\u062A\\u0648\\u0642\\u0639 \\u062A\\u06BE\\u0627\\u060C ${n(t.input)} \\u0645\\u0648\\u0635\\u0648\\u0644 \\u06C1\\u0648\\u0627`;case"invalid_value":return t.values.length===1?`\\u063A\\u0644\\u0637 \\u0627\\u0646 \\u067E\\u0679: ${_(t.values[0])} \\u0645\\u062A\\u0648\\u0642\\u0639 \\u062A\\u06BE\\u0627`:`\\u063A\\u0644\\u0637 \\u0622\\u067E\\u0634\\u0646: ${f(t.values,"|")} \\u0645\\u06CC\\u06BA \\u0633\\u06D2 \\u0627\\u06CC\\u06A9 \\u0645\\u062A\\u0648\\u0642\\u0639 \\u062A\\u06BE\\u0627`;case"too_big":{let o=t.inclusive?"<=":"<",a=r(t.origin);return a?`\\u0628\\u06C1\\u062A \\u0628\\u0691\\u0627: ${t.origin??"\\u0648\\u06CC\\u0644\\u06CC\\u0648"} \\u06A9\\u06D2 ${o}${t.maximum.toString()} ${a.unit??"\\u0639\\u0646\\u0627\\u0635\\u0631"} \\u06C1\\u0648\\u0646\\u06D2 \\u0645\\u062A\\u0648\\u0642\\u0639 \\u062A\\u06BE\\u06D2`:`\\u0628\\u06C1\\u062A \\u0628\\u0691\\u0627: ${t.origin??"\\u0648\\u06CC\\u0644\\u06CC\\u0648"} \\u06A9\\u0627 ${o}${t.maximum.toString()} \\u06C1\\u0648\\u0646\\u0627 \\u0645\\u062A\\u0648\\u0642\\u0639 \\u062A\\u06BE\\u0627`}case"too_small":{let o=t.inclusive?">=":">",a=r(t.origin);return a?`\\u0628\\u06C1\\u062A \\u0686\\u06BE\\u0648\\u0679\\u0627: ${t.origin} \\u06A9\\u06D2 ${o}${t.minimum.toString()} ${a.unit} \\u06C1\\u0648\\u0646\\u06D2 \\u0645\\u062A\\u0648\\u0642\\u0639 \\u062A\\u06BE\\u06D2`:`\\u0628\\u06C1\\u062A \\u0686\\u06BE\\u0648\\u0679\\u0627: ${t.origin} \\u06A9\\u0627 ${o}${t.minimum.toString()} \\u06C1\\u0648\\u0646\\u0627 \\u0645\\u062A\\u0648\\u0642\\u0639 \\u062A\\u06BE\\u0627`}case"invalid_format":{let o=t;return o.format==="starts_with"?`\\u063A\\u0644\\u0637 \\u0633\\u0679\\u0631\\u0646\\u06AF: "${o.prefix}" \\u0633\\u06D2 \\u0634\\u0631\\u0648\\u0639 \\u06C1\\u0648\\u0646\\u0627 \\u0686\\u0627\\u06C1\\u06CC\\u06D2`:o.format==="ends_with"?`\\u063A\\u0644\\u0637 \\u0633\\u0679\\u0631\\u0646\\u06AF: "${o.suffix}" \\u067E\\u0631 \\u062E\\u062A\\u0645 \\u06C1\\u0648\\u0646\\u0627 \\u0686\\u0627\\u06C1\\u06CC\\u06D2`:o.format==="includes"?`\\u063A\\u0644\\u0637 \\u0633\\u0679\\u0631\\u0646\\u06AF: "${o.includes}" \\u0634\\u0627\\u0645\\u0644 \\u06C1\\u0648\\u0646\\u0627 \\u0686\\u0627\\u06C1\\u06CC\\u06D2`:o.format==="regex"?`\\u063A\\u0644\\u0637 \\u0633\\u0679\\u0631\\u0646\\u06AF: \\u067E\\u06CC\\u0679\\u0631\\u0646 ${o.pattern} \\u0633\\u06D2 \\u0645\\u06CC\\u0686 \\u06C1\\u0648\\u0646\\u0627 \\u0686\\u0627\\u06C1\\u06CC\\u06D2`:`\\u063A\\u0644\\u0637 ${i[o.format]??t.format}`}case"not_multiple_of":return`\\u063A\\u0644\\u0637 \\u0646\\u0645\\u0628\\u0631: ${t.divisor} \\u06A9\\u0627 \\u0645\\u0636\\u0627\\u0639\\u0641 \\u06C1\\u0648\\u0646\\u0627 \\u0686\\u0627\\u06C1\\u06CC\\u06D2`;case"unrecognized_keys":return`\\u063A\\u06CC\\u0631 \\u062A\\u0633\\u0644\\u06CC\\u0645 \\u0634\\u062F\\u06C1 \\u06A9\\u06CC${t.keys.length>1?"\\u0632":""}: ${f(t.keys,"\\u060C ")}`;case"invalid_key":return`${t.origin} \\u0645\\u06CC\\u06BA \\u063A\\u0644\\u0637 \\u06A9\\u06CC`;case"invalid_union":return"\\u063A\\u0644\\u0637 \\u0627\\u0646 \\u067E\\u0679";case"invalid_element":return`${t.origin} \\u0645\\u06CC\\u06BA \\u063A\\u0644\\u0637 \\u0648\\u06CC\\u0644\\u06CC\\u0648`;default:return"\\u063A\\u0644\\u0637 \\u0627\\u0646 \\u067E\\u0679"}}}});function Tl(){return{localeError:Jm()}}var Jm,Ol=S(()=>{P();Jm=()=>{let e={string:{unit:"k\\xFD t\\u1EF1",verb:"c\\xF3"},file:{unit:"byte",verb:"c\\xF3"},array:{unit:"ph\\u1EA7n t\\u1EED",verb:"c\\xF3"},set:{unit:"ph\\u1EA7n t\\u1EED",verb:"c\\xF3"}};function r(t){return e[t]??null}let n=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"s\\u1ED1";case"object":{if(Array.isArray(t))return"m\\u1EA3ng";if(t===null)return"null";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"\\u0111\\u1EA7u v\\xE0o",email:"\\u0111\\u1ECBa ch\\u1EC9 email",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ng\\xE0y gi\\u1EDD ISO",date:"ng\\xE0y ISO",time:"gi\\u1EDD ISO",duration:"kho\\u1EA3ng th\\u1EDDi gian ISO",ipv4:"\\u0111\\u1ECBa ch\\u1EC9 IPv4",ipv6:"\\u0111\\u1ECBa ch\\u1EC9 IPv6",cidrv4:"d\\u1EA3i IPv4",cidrv6:"d\\u1EA3i IPv6",base64:"chu\\u1ED7i m\\xE3 h\\xF3a base64",base64url:"chu\\u1ED7i m\\xE3 h\\xF3a base64url",json_string:"chu\\u1ED7i JSON",e164:"s\\u1ED1 E.164",jwt:"JWT",template_literal:"\\u0111\\u1EA7u v\\xE0o"};return t=>{switch(t.code){case"invalid_type":return`\\u0110\\u1EA7u v\\xE0o kh\\xF4ng h\\u1EE3p l\\u1EC7: mong \\u0111\\u1EE3i ${t.expected}, nh\\u1EADn \\u0111\\u01B0\\u1EE3c ${n(t.input)}`;case"invalid_value":return t.values.length===1?`\\u0110\\u1EA7u v\\xE0o kh\\xF4ng h\\u1EE3p l\\u1EC7: mong \\u0111\\u1EE3i ${_(t.values[0])}`:`T\\xF9y ch\\u1ECDn kh\\xF4ng h\\u1EE3p l\\u1EC7: mong \\u0111\\u1EE3i m\\u1ED9t trong c\\xE1c gi\\xE1 tr\\u1ECB ${f(t.values,"|")}`;case"too_big":{let o=t.inclusive?"<=":"<",a=r(t.origin);return a?`Qu\\xE1 l\\u1EDBn: mong \\u0111\\u1EE3i ${t.origin??"gi\\xE1 tr\\u1ECB"} ${a.verb} ${o}${t.maximum.toString()} ${a.unit??"ph\\u1EA7n t\\u1EED"}`:`Qu\\xE1 l\\u1EDBn: mong \\u0111\\u1EE3i ${t.origin??"gi\\xE1 tr\\u1ECB"} ${o}${t.maximum.toString()}`}case"too_small":{let o=t.inclusive?">=":">",a=r(t.origin);return a?`Qu\\xE1 nh\\u1ECF: mong \\u0111\\u1EE3i ${t.origin} ${a.verb} ${o}${t.minimum.toString()} ${a.unit}`:`Qu\\xE1 nh\\u1ECF: mong \\u0111\\u1EE3i ${t.origin} ${o}${t.minimum.toString()}`}case"invalid_format":{let o=t;return o.format==="starts_with"?`Chu\\u1ED7i kh\\xF4ng h\\u1EE3p l\\u1EC7: ph\\u1EA3i b\\u1EAFt \\u0111\\u1EA7u b\\u1EB1ng "${o.prefix}"`:o.format==="ends_with"?`Chu\\u1ED7i kh\\xF4ng h\\u1EE3p l\\u1EC7: ph\\u1EA3i k\\u1EBFt th\\xFAc b\\u1EB1ng "${o.suffix}"`:o.format==="includes"?`Chu\\u1ED7i kh\\xF4ng h\\u1EE3p l\\u1EC7: ph\\u1EA3i bao g\\u1ED3m "${o.includes}"`:o.format==="regex"?`Chu\\u1ED7i kh\\xF4ng h\\u1EE3p l\\u1EC7: ph\\u1EA3i kh\\u1EDBp v\\u1EDBi m\\u1EABu ${o.pattern}`:`${i[o.format]??t.format} kh\\xF4ng h\\u1EE3p l\\u1EC7`}case"not_multiple_of":return`S\\u1ED1 kh\\xF4ng h\\u1EE3p l\\u1EC7: ph\\u1EA3i l\\xE0 b\\u1ED9i s\\u1ED1 c\\u1EE7a ${t.divisor}`;case"unrecognized_keys":return`Kh\\xF3a kh\\xF4ng \\u0111\\u01B0\\u1EE3c nh\\u1EADn d\\u1EA1ng: ${f(t.keys,", ")}`;case"invalid_key":return`Kh\\xF3a kh\\xF4ng h\\u1EE3p l\\u1EC7 trong ${t.origin}`;case"invalid_union":return"\\u0110\\u1EA7u v\\xE0o kh\\xF4ng h\\u1EE3p l\\u1EC7";case"invalid_element":return`Gi\\xE1 tr\\u1ECB kh\\xF4ng h\\u1EE3p l\\u1EC7 trong ${t.origin}`;default:return"\\u0110\\u1EA7u v\\xE0o kh\\xF4ng h\\u1EE3p l\\u1EC7"}}}});function Nl(){return{localeError:Bm()}}var Bm,Ul=S(()=>{P();Bm=()=>{let e={string:{unit:"\\u5B57\\u7B26",verb:"\\u5305\\u542B"},file:{unit:"\\u5B57\\u8282",verb:"\\u5305\\u542B"},array:{unit:"\\u9879",verb:"\\u5305\\u542B"},set:{unit:"\\u9879",verb:"\\u5305\\u542B"}};function r(t){return e[t]??null}let n=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"\\u975E\\u6570\\u5B57(NaN)":"\\u6570\\u5B57";case"object":{if(Array.isArray(t))return"\\u6570\\u7EC4";if(t===null)return"\\u7A7A\\u503C(null)";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"\\u8F93\\u5165",email:"\\u7535\\u5B50\\u90AE\\u4EF6",url:"URL",emoji:"\\u8868\\u60C5\\u7B26\\u53F7",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO\\u65E5\\u671F\\u65F6\\u95F4",date:"ISO\\u65E5\\u671F",time:"ISO\\u65F6\\u95F4",duration:"ISO\\u65F6\\u957F",ipv4:"IPv4\\u5730\\u5740",ipv6:"IPv6\\u5730\\u5740",cidrv4:"IPv4\\u7F51\\u6BB5",cidrv6:"IPv6\\u7F51\\u6BB5",base64:"base64\\u7F16\\u7801\\u5B57\\u7B26\\u4E32",base64url:"base64url\\u7F16\\u7801\\u5B57\\u7B26\\u4E32",json_string:"JSON\\u5B57\\u7B26\\u4E32",e164:"E.164\\u53F7\\u7801",jwt:"JWT",template_literal:"\\u8F93\\u5165"};return t=>{switch(t.code){case"invalid_type":return`\\u65E0\\u6548\\u8F93\\u5165\\uFF1A\\u671F\\u671B ${t.expected}\\uFF0C\\u5B9E\\u9645\\u63A5\\u6536 ${n(t.input)}`;case"invalid_value":return t.values.length===1?`\\u65E0\\u6548\\u8F93\\u5165\\uFF1A\\u671F\\u671B ${_(t.values[0])}`:`\\u65E0\\u6548\\u9009\\u9879\\uFF1A\\u671F\\u671B\\u4EE5\\u4E0B\\u4E4B\\u4E00 ${f(t.values,"|")}`;case"too_big":{let o=t.inclusive?"<=":"<",a=r(t.origin);return a?`\\u6570\\u503C\\u8FC7\\u5927\\uFF1A\\u671F\\u671B ${t.origin??"\\u503C"} ${o}${t.maximum.toString()} ${a.unit??"\\u4E2A\\u5143\\u7D20"}`:`\\u6570\\u503C\\u8FC7\\u5927\\uFF1A\\u671F\\u671B ${t.origin??"\\u503C"} ${o}${t.maximum.toString()}`}case"too_small":{let o=t.inclusive?">=":">",a=r(t.origin);return a?`\\u6570\\u503C\\u8FC7\\u5C0F\\uFF1A\\u671F\\u671B ${t.origin} ${o}${t.minimum.toString()} ${a.unit}`:`\\u6570\\u503C\\u8FC7\\u5C0F\\uFF1A\\u671F\\u671B ${t.origin} ${o}${t.minimum.toString()}`}case"invalid_format":{let o=t;return o.format==="starts_with"?`\\u65E0\\u6548\\u5B57\\u7B26\\u4E32\\uFF1A\\u5FC5\\u987B\\u4EE5 "${o.prefix}" \\u5F00\\u5934`:o.format==="ends_with"?`\\u65E0\\u6548\\u5B57\\u7B26\\u4E32\\uFF1A\\u5FC5\\u987B\\u4EE5 "${o.suffix}" \\u7ED3\\u5C3E`:o.format==="includes"?`\\u65E0\\u6548\\u5B57\\u7B26\\u4E32\\uFF1A\\u5FC5\\u987B\\u5305\\u542B "${o.includes}"`:o.format==="regex"?`\\u65E0\\u6548\\u5B57\\u7B26\\u4E32\\uFF1A\\u5FC5\\u987B\\u6EE1\\u8DB3\\u6B63\\u5219\\u8868\\u8FBE\\u5F0F ${o.pattern}`:`\\u65E0\\u6548${i[o.format]??t.format}`}case"not_multiple_of":return`\\u65E0\\u6548\\u6570\\u5B57\\uFF1A\\u5FC5\\u987B\\u662F ${t.divisor} \\u7684\\u500D\\u6570`;case"unrecognized_keys":return`\\u51FA\\u73B0\\u672A\\u77E5\\u7684\\u952E(key): ${f(t.keys,", ")}`;case"invalid_key":return`${t.origin} \\u4E2D\\u7684\\u952E(key)\\u65E0\\u6548`;case"invalid_union":return"\\u65E0\\u6548\\u8F93\\u5165";case"invalid_element":return`${t.origin} \\u4E2D\\u5305\\u542B\\u65E0\\u6548\\u503C(value)`;default:return"\\u65E0\\u6548\\u8F93\\u5165"}}}});function El(){return{localeError:Km()}}var Km,Dl=S(()=>{P();Km=()=>{let e={string:{unit:"\\u5B57\\u5143",verb:"\\u64C1\\u6709"},file:{unit:"\\u4F4D\\u5143\\u7D44",verb:"\\u64C1\\u6709"},array:{unit:"\\u9805\\u76EE",verb:"\\u64C1\\u6709"},set:{unit:"\\u9805\\u76EE",verb:"\\u64C1\\u6709"}};function r(t){return e[t]??null}let n=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"number";case"object":{if(Array.isArray(t))return"array";if(t===null)return"null";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"\\u8F38\\u5165",email:"\\u90F5\\u4EF6\\u5730\\u5740",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO \\u65E5\\u671F\\u6642\\u9593",date:"ISO \\u65E5\\u671F",time:"ISO \\u6642\\u9593",duration:"ISO \\u671F\\u9593",ipv4:"IPv4 \\u4F4D\\u5740",ipv6:"IPv6 \\u4F4D\\u5740",cidrv4:"IPv4 \\u7BC4\\u570D",cidrv6:"IPv6 \\u7BC4\\u570D",base64:"base64 \\u7DE8\\u78BC\\u5B57\\u4E32",base64url:"base64url \\u7DE8\\u78BC\\u5B57\\u4E32",json_string:"JSON \\u5B57\\u4E32",e164:"E.164 \\u6578\\u503C",jwt:"JWT",template_literal:"\\u8F38\\u5165"};return t=>{switch(t.code){case"invalid_type":return`\\u7121\\u6548\\u7684\\u8F38\\u5165\\u503C\\uFF1A\\u9810\\u671F\\u70BA ${t.expected}\\uFF0C\\u4F46\\u6536\\u5230 ${n(t.input)}`;case"invalid_value":return t.values.length===1?`\\u7121\\u6548\\u7684\\u8F38\\u5165\\u503C\\uFF1A\\u9810\\u671F\\u70BA ${_(t.values[0])}`:`\\u7121\\u6548\\u7684\\u9078\\u9805\\uFF1A\\u9810\\u671F\\u70BA\\u4EE5\\u4E0B\\u5176\\u4E2D\\u4E4B\\u4E00 ${f(t.values,"|")}`;case"too_big":{let o=t.inclusive?"<=":"<",a=r(t.origin);return a?`\\u6578\\u503C\\u904E\\u5927\\uFF1A\\u9810\\u671F ${t.origin??"\\u503C"} \\u61C9\\u70BA ${o}${t.maximum.toString()} ${a.unit??"\\u500B\\u5143\\u7D20"}`:`\\u6578\\u503C\\u904E\\u5927\\uFF1A\\u9810\\u671F ${t.origin??"\\u503C"} \\u61C9\\u70BA ${o}${t.maximum.toString()}`}case"too_small":{let o=t.inclusive?">=":">",a=r(t.origin);return a?`\\u6578\\u503C\\u904E\\u5C0F\\uFF1A\\u9810\\u671F ${t.origin} \\u61C9\\u70BA ${o}${t.minimum.toString()} ${a.unit}`:`\\u6578\\u503C\\u904E\\u5C0F\\uFF1A\\u9810\\u671F ${t.origin} \\u61C9\\u70BA ${o}${t.minimum.toString()}`}case"invalid_format":{let o=t;return o.format==="starts_with"?`\\u7121\\u6548\\u7684\\u5B57\\u4E32\\uFF1A\\u5FC5\\u9808\\u4EE5 "${o.prefix}" \\u958B\\u982D`:o.format==="ends_with"?`\\u7121\\u6548\\u7684\\u5B57\\u4E32\\uFF1A\\u5FC5\\u9808\\u4EE5 "${o.suffix}" \\u7D50\\u5C3E`:o.format==="includes"?`\\u7121\\u6548\\u7684\\u5B57\\u4E32\\uFF1A\\u5FC5\\u9808\\u5305\\u542B "${o.includes}"`:o.format==="regex"?`\\u7121\\u6548\\u7684\\u5B57\\u4E32\\uFF1A\\u5FC5\\u9808\\u7B26\\u5408\\u683C\\u5F0F ${o.pattern}`:`\\u7121\\u6548\\u7684 ${i[o.format]??t.format}`}case"not_multiple_of":return`\\u7121\\u6548\\u7684\\u6578\\u5B57\\uFF1A\\u5FC5\\u9808\\u70BA ${t.divisor} \\u7684\\u500D\\u6578`;case"unrecognized_keys":return`\\u7121\\u6CD5\\u8B58\\u5225\\u7684\\u9375\\u503C${t.keys.length>1?"\\u5011":""}\\uFF1A${f(t.keys,"\\u3001")}`;case"invalid_key":return`${t.origin} \\u4E2D\\u6709\\u7121\\u6548\\u7684\\u9375\\u503C`;case"invalid_union":return"\\u7121\\u6548\\u7684\\u8F38\\u5165\\u503C";case"invalid_element":return`${t.origin} \\u4E2D\\u6709\\u7121\\u6548\\u7684\\u503C`;default:return"\\u7121\\u6548\\u7684\\u8F38\\u5165\\u503C"}}}});var et={};ke(et,{ar:()=>pu,az:()=>fu,be:()=>vu,ca:()=>yu,cs:()=>xu,de:()=>zu,en:()=>Fr,eo:()=>Su,es:()=>Iu,fa:()=>Pu,fi:()=>Ou,fr:()=>Uu,frCA:()=>Du,he:()=>Zu,hu:()=>Cu,id:()=>Mu,it:()=>Fu,ja:()=>Vu,kh:()=>Bu,ko:()=>Wu,mk:()=>Qu,ms:()=>Xu,nl:()=>tl,no:()=>nl,ota:()=>il,pl:()=>ul,ps:()=>sl,pt:()=>dl,ru:()=>fl,sl:()=>hl,sv:()=>bl,ta:()=>_l,th:()=>$l,tr:()=>kl,ua:()=>wl,ur:()=>jl,vi:()=>Tl,zhCN:()=>Nl,zhTW:()=>El});var Aa=S(()=>{mu();gu();bu();_u();$u();ku();Za();wu();ju();Tu();Nu();Eu();Ru();Au();Lu();qu();Hu();Ju();Ku();Gu();Yu();el();rl();ol();al();cl();ll();pl();gl();vl();yl();xl();zl();Sl();Il();Pl();Ol();Ul();Dl()});function Vt(){return new tt}var Hr,Vr,tt,me,Ca=S(()=>{Hr=Symbol("ZodOutput"),Vr=Symbol("ZodInput"),tt=class{constructor(){this._map=new Map,this._idmap=new Map}add(r,...n){let i=n[0];if(this._map.set(r,i),i&&typeof i=="object"&&"id"in i){if(this._idmap.has(i.id))throw new Error(`ID ${i.id} already exists in the registry`);this._idmap.set(i.id,r)}return this}clear(){return this._map=new Map,this._idmap=new Map,this}remove(r){let n=this._map.get(r);return n&&typeof n=="object"&&"id"in n&&this._idmap.delete(n.id),this._map.delete(r),this}get(r){let n=r._zod.parent;if(n){let i={...this.get(n)??{}};return delete i.id,{...i,...this._map.get(r)}}return this._map.get(r)}has(r){return this._map.has(r)}};me=Vt()});function La(e,r){return new e({type:"string",...b(r)})}function Ma(e,r){return new e({type:"string",coerce:!0,...b(r)})}function Jr(e,r){return new e({type:"string",format:"email",check:"string_format",abort:!1,...b(r)})}function Jt(e,r){return new e({type:"string",format:"guid",check:"string_format",abort:!1,...b(r)})}function Br(e,r){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,...b(r)})}function Kr(e,r){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,version:"v4",...b(r)})}function Wr(e,r){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,version:"v6",...b(r)})}function Gr(e,r){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,version:"v7",...b(r)})}function Qr(e,r){return new e({type:"string",format:"url",check:"string_format",abort:!1,...b(r)})}function Yr(e,r){return new e({type:"string",format:"emoji",check:"string_format",abort:!1,...b(r)})}function Xr(e,r){return new e({type:"string",format:"nanoid",check:"string_format",abort:!1,...b(r)})}function en(e,r){return new e({type:"string",format:"cuid",check:"string_format",abort:!1,...b(r)})}function tn(e,r){return new e({type:"string",format:"cuid2",check:"string_format",abort:!1,...b(r)})}function rn(e,r){return new e({type:"string",format:"ulid",check:"string_format",abort:!1,...b(r)})}function nn(e,r){return new e({type:"string",format:"xid",check:"string_format",abort:!1,...b(r)})}function on(e,r){return new e({type:"string",format:"ksuid",check:"string_format",abort:!1,...b(r)})}function an(e,r){return new e({type:"string",format:"ipv4",check:"string_format",abort:!1,...b(r)})}function sn(e,r){return new e({type:"string",format:"ipv6",check:"string_format",abort:!1,...b(r)})}function cn(e,r){return new e({type:"string",format:"cidrv4",check:"string_format",abort:!1,...b(r)})}function un(e,r){return new e({type:"string",format:"cidrv6",check:"string_format",abort:!1,...b(r)})}function ln(e,r){return new e({type:"string",format:"base64",check:"string_format",abort:!1,...b(r)})}function dn(e,r){return new e({type:"string",format:"base64url",check:"string_format",abort:!1,...b(r)})}function pn(e,r){return new e({type:"string",format:"e164",check:"string_format",abort:!1,...b(r)})}function mn(e,r){return new e({type:"string",format:"jwt",check:"string_format",abort:!1,...b(r)})}function qa(e,r){return new e({type:"string",format:"datetime",check:"string_format",offset:!1,local:!1,precision:null,...b(r)})}function Fa(e,r){return new e({type:"string",format:"date",check:"string_format",...b(r)})}function Ha(e,r){return new e({type:"string",format:"time",check:"string_format",precision:null,...b(r)})}function Va(e,r){return new e({type:"string",format:"duration",check:"string_format",...b(r)})}function Ja(e,r){return new e({type:"number",checks:[],...b(r)})}function Ba(e,r){return new e({type:"number",coerce:!0,checks:[],...b(r)})}function Ka(e,r){return new e({type:"number",check:"number_format",abort:!1,format:"safeint",...b(r)})}function Wa(e,r){return new e({type:"number",check:"number_format",abort:!1,format:"float32",...b(r)})}function Ga(e,r){return new e({type:"number",check:"number_format",abort:!1,format:"float64",...b(r)})}function Qa(e,r){return new e({type:"number",check:"number_format",abort:!1,format:"int32",...b(r)})}function Ya(e,r){return new e({type:"number",check:"number_format",abort:!1,format:"uint32",...b(r)})}function Xa(e,r){return new e({type:"boolean",...b(r)})}function es(e,r){return new e({type:"boolean",coerce:!0,...b(r)})}function ts(e,r){return new e({type:"bigint",...b(r)})}function rs(e,r){return new e({type:"bigint",coerce:!0,...b(r)})}function ns(e,r){return new e({type:"bigint",check:"bigint_format",abort:!1,format:"int64",...b(r)})}function os(e,r){return new e({type:"bigint",check:"bigint_format",abort:!1,format:"uint64",...b(r)})}function is(e,r){return new e({type:"symbol",...b(r)})}function as(e,r){return new e({type:"undefined",...b(r)})}function ss(e,r){return new e({type:"null",...b(r)})}function cs(e){return new e({type:"any"})}function rt(e){return new e({type:"unknown"})}function us(e,r){return new e({type:"never",...b(r)})}function ls(e,r){return new e({type:"void",...b(r)})}function ds(e,r){return new e({type:"date",...b(r)})}function ps(e,r){return new e({type:"date",coerce:!0,...b(r)})}function ms(e,r){return new e({type:"nan",...b(r)})}function ge(e,r){return new Dr({check:"less_than",...b(r),value:e,inclusive:!1})}function ue(e,r){return new Dr({check:"less_than",...b(r),value:e,inclusive:!0})}function he(e,r){return new Rr({check:"greater_than",...b(r),value:e,inclusive:!1})}function oe(e,r){return new Rr({check:"greater_than",...b(r),value:e,inclusive:!0})}function gn(e){return he(0,e)}function hn(e){return ge(0,e)}function vn(e){return ue(0,e)}function bn(e){return oe(0,e)}function Ie(e,r){return new mi({check:"multiple_of",...b(r),value:e})}function Ae(e,r){return new hi({check:"max_size",...b(r),maximum:e})}function je(e,r){return new vi({check:"min_size",...b(r),minimum:e})}function nt(e,r){return new bi({check:"size_equals",...b(r),size:e})}function Ce(e,r){return new yi({check:"max_length",...b(r),maximum:e})}function xe(e,r){return new _i({check:"min_length",...b(r),minimum:e})}function Le(e,r){return new xi({check:"length_equals",...b(r),length:e})}function ot(e,r){return new $i({check:"string_format",format:"regex",...b(r),pattern:e})}function it(e){return new zi({check:"string_format",format:"lowercase",...b(e)})}function at(e){return new ki({check:"string_format",format:"uppercase",...b(e)})}function st(e,r){return new Si({check:"string_format",format:"includes",...b(r),includes:e})}function ct(e,r){return new wi({check:"string_format",format:"starts_with",...b(r),prefix:e})}function ut(e,r){return new Ii({check:"string_format",format:"ends_with",...b(r),suffix:e})}function yn(e,r,n){return new ji({check:"property",property:e,schema:r,...b(n)})}function lt(e,r){return new Pi({check:"mime_type",mime:e,...b(r)})}function ve(e){return new Ti({check:"overwrite",tx:e})}function dt(e){return ve(r=>r.normalize(e))}function pt(){return ve(e=>e.trim())}function mt(){return ve(e=>e.toLowerCase())}function ft(){return ve(e=>e.toUpperCase())}function Bt(e,r,n){return new e({type:"array",element:r,...b(n)})}function Wm(e,r,n){return new e({type:"union",options:r,...b(n)})}function Gm(e,r,n,i){return new e({type:"union",options:n,discriminator:r,...b(i)})}function Qm(e,r,n){return new e({type:"intersection",left:r,right:n})}function fs(e,r,n,i){let t=n instanceof T,o=t?i:n,a=t?n:null;return new e({type:"tuple",items:r,rest:a,...b(o)})}function Ym(e,r,n,i){return new e({type:"record",keyType:r,valueType:n,...b(i)})}function Xm(e,r,n,i){return new e({type:"map",keyType:r,valueType:n,...b(i)})}function ef(e,r,n){return new e({type:"set",valueType:r,...b(n)})}function tf(e,r,n){let i=Array.isArray(r)?Object.fromEntries(r.map(t=>[t,t])):r;return new e({type:"enum",entries:i,...b(n)})}function rf(e,r,n){return new e({type:"enum",entries:r,...b(n)})}function nf(e,r,n){return new e({type:"literal",values:Array.isArray(r)?r:[r],...b(n)})}function gs(e,r){return new e({type:"file",...b(r)})}function of(e,r){return new e({type:"transform",transform:r})}function af(e,r){return new e({type:"optional",innerType:r})}function sf(e,r){return new e({type:"nullable",innerType:r})}function cf(e,r,n){return new e({type:"default",innerType:r,get defaultValue(){return typeof n=="function"?n():n}})}function uf(e,r,n){return new e({type:"nonoptional",innerType:r,...b(n)})}function lf(e,r){return new e({type:"success",innerType:r})}function df(e,r,n){return new e({type:"catch",innerType:r,catchValue:typeof n=="function"?n:()=>n})}function pf(e,r,n){return new e({type:"pipe",in:r,out:n})}function mf(e,r){return new e({type:"readonly",innerType:r})}function ff(e,r,n){return new e({type:"template_literal",parts:r,...b(n)})}function gf(e,r){return new e({type:"lazy",getter:r})}function hf(e,r){return new e({type:"promise",innerType:r})}function hs(e,r,n){let i=b(n);return i.abort??(i.abort=!0),new e({type:"custom",check:"custom",fn:r,...i})}function vs(e,r,n){return new e({type:"custom",check:"custom",fn:r,...b(n)})}function bs(e,r){let n=b(r),i=n.truthy??["true","1","yes","on","y","enabled"],t=n.falsy??["false","0","no","off","n","disabled"];n.case!=="sensitive"&&(i=i.map(l=>typeof l=="string"?l.toLowerCase():l),t=t.map(l=>typeof l=="string"?l.toLowerCase():l));let o=new Set(i),a=new Set(t),c=e.Pipe??Ft,p=e.Boolean??Lt,g=e.String??Re,h=e.Transform??qt,m=new h({type:"transform",transform:(l,v)=>{let k=l;return n.case!=="sensitive"&&(k=k.toLowerCase()),o.has(k)?!0:a.has(k)?!1:(v.issues.push({code:"invalid_value",expected:"stringbool",values:[...o,...a],input:v.value,inst:m}),{})},error:n.error}),$=new c({type:"pipe",in:new g({type:"string",error:n.error}),out:m,error:n.error});return new c({type:"pipe",in:$,out:new p({type:"boolean",error:n.error}),error:n.error})}function ys(e,r,n,i={}){let t=b(i),o={...b(i),check:"string_format",type:"string",format:r,fn:typeof n=="function"?n:c=>n.test(c),...t};return n instanceof RegExp&&(o.pattern=n),new e(o)}var fn,_s=S(()=>{Zr();Ht();P();fn={Any:null,Minute:-1,Second:0,Millisecond:3,Microsecond:6}});function xn(e){return new _n({type:"function",input:Array.isArray(e?.input)?fs(Ze,e?.input):e?.input??Bt(Mt,rt(Xe)),output:e?.output??rt(Xe)})}var _n,Rl=S(()=>{_s();Nr();Ht();Ht();_n=class{constructor(r){this._def=r,this.def=r}implement(r){if(typeof r!="function")throw new Error("implement() must be called with a function");let n=((...i)=>{let t=this._def.input?Rt(this._def.input,i,void 0,{callee:n}):i;if(!Array.isArray(t))throw new Error("Invalid arguments schema: not an array or tuple schema.");let o=r(...t);return this._def.output?Rt(this._def.output,o,void 0,{callee:n}):o});return n}implementAsync(r){if(typeof r!="function")throw new Error("implement() must be called with a function");let n=(async(...i)=>{let t=this._def.input?await Zt(this._def.input,i,void 0,{callee:n}):i;if(!Array.isArray(t))throw new Error("Invalid arguments schema: not an array or tuple schema.");let o=await r(...t);return this._def.output?Zt(this._def.output,o,void 0,{callee:n}):o});return n}input(...r){let n=this.constructor;return Array.isArray(r[0])?new n({type:"function",input:new Ze({type:"tuple",items:r[0],rest:r[1]}),output:this._def.output}):new n({type:"function",input:r[0],output:this._def.output})}output(r){let n=this.constructor;return new n({type:"function",input:this._def.input,output:r})}}});function $n(e,r){if(e instanceof tt){let i=new Kt(r),t={};for(let c of e._idmap.entries()){let[p,g]=c;i.process(g)}let o={},a={registry:e,uri:r?.uri,defs:t};for(let c of e._idmap.entries()){let[p,g]=c;o[p]=i.emit(g,{...r,external:a})}if(Object.keys(t).length>0){let c=i.target==="draft-2020-12"?"$defs":"definitions";o.__shared={[c]:t}}return{schemas:o}}let n=new Kt(r);return n.process(e),n.emit(e,r)}function G(e,r){let n=r??{seen:new Set};if(n.seen.has(e))return!1;n.seen.add(e);let t=e._zod.def;switch(t.type){case"string":case"number":case"bigint":case"boolean":case"date":case"symbol":case"undefined":case"null":case"any":case"unknown":case"never":case"void":case"literal":case"enum":case"nan":case"file":case"template_literal":return!1;case"array":return G(t.element,n);case"object":{for(let o in t.shape)if(G(t.shape[o],n))return!0;return!1}case"union":{for(let o of t.options)if(G(o,n))return!0;return!1}case"intersection":return G(t.left,n)||G(t.right,n);case"tuple":{for(let o of t.items)if(G(o,n))return!0;return!!(t.rest&&G(t.rest,n))}case"record":return G(t.keyType,n)||G(t.valueType,n);case"map":return G(t.keyType,n)||G(t.valueType,n);case"set":return G(t.valueType,n);case"promise":case"optional":case"nonoptional":case"nullable":case"readonly":return G(t.innerType,n);case"lazy":return G(t.getter(),n);case"default":return G(t.innerType,n);case"prefault":return G(t.innerType,n);case"custom":return!1;case"transform":return!0;case"pipe":return G(t.in,n)||G(t.out,n);case"success":return!1;case"catch":return!1;default:}throw new Error(`Unknown schema type: ${t.type}`)}var Kt,Zl=S(()=>{Ca();P();Kt=class{constructor(r){this.counter=0,this.metadataRegistry=r?.metadata??me,this.target=r?.target??"draft-2020-12",this.unrepresentable=r?.unrepresentable??"throw",this.override=r?.override??(()=>{}),this.io=r?.io??"output",this.seen=new Map}process(r,n={path:[],schemaPath:[]}){var i;let t=r._zod.def,o={guid:"uuid",url:"uri",datetime:"date-time",json_string:"json-string",regex:""},a=this.seen.get(r);if(a)return a.count++,n.schemaPath.includes(r)&&(a.cycle=n.path),a.schema;let c={schema:{},count:1,cycle:void 0,path:n.path};this.seen.set(r,c);let p=r._zod.toJSONSchema?.();if(p)c.schema=p;else{let m={...n,schemaPath:[...n.schemaPath,r],path:n.path},$=r._zod.parent;if($)c.ref=$,this.process($,m),this.seen.get($).isParent=!0;else{let y=c.schema;switch(t.type){case"string":{let l=y;l.type="string";let{minimum:v,maximum:k,format:E,patterns:w,contentEncoding:j}=r._zod.bag;if(typeof v=="number"&&(l.minLength=v),typeof k=="number"&&(l.maxLength=k),E&&(l.format=o[E]??E,l.format===""&&delete l.format),j&&(l.contentEncoding=j),w&&w.size>0){let D=[...w];D.length===1?l.pattern=D[0].source:D.length>1&&(c.schema.allOf=[...D.map(Oe=>({...this.target==="draft-7"?{type:"string"}:{},pattern:Oe.source}))])}break}case"number":{let l=y,{minimum:v,maximum:k,format:E,multipleOf:w,exclusiveMaximum:j,exclusiveMinimum:D}=r._zod.bag;typeof E=="string"&&E.includes("int")?l.type="integer":l.type="number",typeof D=="number"&&(l.exclusiveMinimum=D),typeof v=="number"&&(l.minimum=v,typeof D=="number"&&(D>=v?delete l.minimum:delete l.exclusiveMinimum)),typeof j=="number"&&(l.exclusiveMaximum=j),typeof k=="number"&&(l.maximum=k,typeof j=="number"&&(j<=k?delete l.maximum:delete l.exclusiveMaximum)),typeof w=="number"&&(l.multipleOf=w);break}case"boolean":{let l=y;l.type="boolean";break}case"bigint":{if(this.unrepresentable==="throw")throw new Error("BigInt cannot be represented in JSON Schema");break}case"symbol":{if(this.unrepresentable==="throw")throw new Error("Symbols cannot be represented in JSON Schema");break}case"null":{y.type="null";break}case"any":break;case"unknown":break;case"undefined":{if(this.unrepresentable==="throw")throw new Error("Undefined cannot be represented in JSON Schema");break}case"void":{if(this.unrepresentable==="throw")throw new Error("Void cannot be represented in JSON Schema");break}case"never":{y.not={};break}case"date":{if(this.unrepresentable==="throw")throw new Error("Date cannot be represented in JSON Schema");break}case"array":{let l=y,{minimum:v,maximum:k}=r._zod.bag;typeof v=="number"&&(l.minItems=v),typeof k=="number"&&(l.maxItems=k),l.type="array",l.items=this.process(t.element,{...m,path:[...m.path,"items"]});break}case"object":{let l=y;l.type="object",l.properties={};let v=t.shape;for(let w in v)l.properties[w]=this.process(v[w],{...m,path:[...m.path,"properties",w]});let k=new Set(Object.keys(v)),E=new Set([...k].filter(w=>{let j=t.shape[w]._zod;return this.io==="input"?j.optin===void 0:j.optout===void 0}));E.size>0&&(l.required=Array.from(E)),t.catchall?._zod.def.type==="never"?l.additionalProperties=!1:t.catchall?t.catchall&&(l.additionalProperties=this.process(t.catchall,{...m,path:[...m.path,"additionalProperties"]})):this.io==="output"&&(l.additionalProperties=!1);break}case"union":{let l=y;l.anyOf=t.options.map((v,k)=>this.process(v,{...m,path:[...m.path,"anyOf",k]}));break}case"intersection":{let l=y,v=this.process(t.left,{...m,path:[...m.path,"allOf",0]}),k=this.process(t.right,{...m,path:[...m.path,"allOf",1]}),E=j=>"allOf"in j&&Object.keys(j).length===1,w=[...E(v)?v.allOf:[v],...E(k)?k.allOf:[k]];l.allOf=w;break}case"tuple":{let l=y;l.type="array";let v=t.items.map((w,j)=>this.process(w,{...m,path:[...m.path,"prefixItems",j]}));if(this.target==="draft-2020-12"?l.prefixItems=v:l.items=v,t.rest){let w=this.process(t.rest,{...m,path:[...m.path,"items"]});this.target==="draft-2020-12"?l.items=w:l.additionalItems=w}t.rest&&(l.items=this.process(t.rest,{...m,path:[...m.path,"items"]}));let{minimum:k,maximum:E}=r._zod.bag;typeof k=="number"&&(l.minItems=k),typeof E=="number"&&(l.maxItems=E);break}case"record":{let l=y;l.type="object",l.propertyNames=this.process(t.keyType,{...m,path:[...m.path,"propertyNames"]}),l.additionalProperties=this.process(t.valueType,{...m,path:[...m.path,"additionalProperties"]});break}case"map":{if(this.unrepresentable==="throw")throw new Error("Map cannot be represented in JSON Schema");break}case"set":{if(this.unrepresentable==="throw")throw new Error("Set cannot be represented in JSON Schema");break}case"enum":{let l=y,v=Pt(t.entries);v.every(k=>typeof k=="number")&&(l.type="number"),v.every(k=>typeof k=="string")&&(l.type="string"),l.enum=v;break}case"literal":{let l=y,v=[];for(let k of t.values)if(k===void 0){if(this.unrepresentable==="throw")throw new Error("Literal `undefined` cannot be represented in JSON Schema")}else if(typeof k=="bigint"){if(this.unrepresentable==="throw")throw new Error("BigInt literals cannot be represented in JSON Schema");v.push(Number(k))}else v.push(k);if(v.length!==0)if(v.length===1){let k=v[0];l.type=k===null?"null":typeof k,l.const=k}else v.every(k=>typeof k=="number")&&(l.type="number"),v.every(k=>typeof k=="string")&&(l.type="string"),v.every(k=>typeof k=="boolean")&&(l.type="string"),v.every(k=>k===null)&&(l.type="null"),l.enum=v;break}case"file":{let l=y,v={type:"string",format:"binary",contentEncoding:"binary"},{minimum:k,maximum:E,mime:w}=r._zod.bag;k!==void 0&&(v.minLength=k),E!==void 0&&(v.maxLength=E),w?w.length===1?(v.contentMediaType=w[0],Object.assign(l,v)):l.anyOf=w.map(j=>({...v,contentMediaType:j})):Object.assign(l,v);break}case"transform":{if(this.unrepresentable==="throw")throw new Error("Transforms cannot be represented in JSON Schema");break}case"nullable":{let l=this.process(t.innerType,m);y.anyOf=[l,{type:"null"}];break}case"nonoptional":{this.process(t.innerType,m),c.ref=t.innerType;break}case"success":{let l=y;l.type="boolean";break}case"default":{this.process(t.innerType,m),c.ref=t.innerType,y.default=JSON.parse(JSON.stringify(t.defaultValue));break}case"prefault":{this.process(t.innerType,m),c.ref=t.innerType,this.io==="input"&&(y._prefault=JSON.parse(JSON.stringify(t.defaultValue)));break}case"catch":{this.process(t.innerType,m),c.ref=t.innerType;let l;try{l=t.catchValue(void 0)}catch{throw new Error("Dynamic catch values are not supported in JSON Schema")}y.default=l;break}case"nan":{if(this.unrepresentable==="throw")throw new Error("NaN cannot be represented in JSON Schema");break}case"template_literal":{let l=y,v=r._zod.pattern;if(!v)throw new Error("Pattern not found in template literal");l.type="string",l.pattern=v.source;break}case"pipe":{let l=this.io==="input"?t.in._zod.def.type==="transform"?t.out:t.in:t.out;this.process(l,m),c.ref=l;break}case"readonly":{this.process(t.innerType,m),c.ref=t.innerType,y.readOnly=!0;break}case"promise":{this.process(t.innerType,m),c.ref=t.innerType;break}case"optional":{this.process(t.innerType,m),c.ref=t.innerType;break}case"lazy":{let l=r._zod.innerType;this.process(l,m),c.ref=l;break}case"custom":{if(this.unrepresentable==="throw")throw new Error("Custom types cannot be represented in JSON Schema");break}default:}}}let g=this.metadataRegistry.get(r);return g&&Object.assign(c.schema,g),this.io==="input"&&G(r)&&(delete c.schema.examples,delete c.schema.default),this.io==="input"&&c.schema._prefault&&((i=c.schema).default??(i.default=c.schema._prefault)),delete c.schema._prefault,this.seen.get(r).schema}emit(r,n){let i={cycles:n?.cycles??"ref",reused:n?.reused??"inline",external:n?.external??void 0},t=this.seen.get(r);if(!t)throw new Error("Unprocessed schema. This is a bug in Zod.");let o=h=>{let m=this.target==="draft-2020-12"?"$defs":"definitions";if(i.external){let v=i.external.registry.get(h[0])?.id,k=i.external.uri??(w=>w);if(v)return{ref:k(v)};let E=h[1].defId??h[1].schema.id??`schema${this.counter++}`;return h[1].defId=E,{defId:E,ref:`${k("__shared")}#/${m}/${E}`}}if(h[1]===t)return{ref:"#"};let y=`#/${m}/`,l=h[1].schema.id??`__schema${this.counter++}`;return{defId:l,ref:y+l}},a=h=>{if(h[1].schema.$ref)return;let m=h[1],{ref:$,defId:y}=o(h);m.def={...m.schema},y&&(m.defId=y);let l=m.schema;for(let v in l)delete l[v];l.$ref=$};if(i.cycles==="throw")for(let h of this.seen.entries()){let m=h[1];if(m.cycle)throw new Error(`Cycle detected: #/${m.cycle?.join("/")}/<root>\n\nSet the \\`cycles\\` parameter to \\`"ref"\\` to resolve cyclical schemas with defs.`)}for(let h of this.seen.entries()){let m=h[1];if(r===h[0]){a(h);continue}if(i.external){let y=i.external.registry.get(h[0])?.id;if(r!==h[0]&&y){a(h);continue}}if(this.metadataRegistry.get(h[0])?.id){a(h);continue}if(m.cycle){a(h);continue}if(m.count>1&&i.reused==="ref"){a(h);continue}}let c=(h,m)=>{let $=this.seen.get(h),y=$.def??$.schema,l={...y};if($.ref===null)return;let v=$.ref;if($.ref=null,v){c(v,m);let k=this.seen.get(v).schema;k.$ref&&m.target==="draft-7"?(y.allOf=y.allOf??[],y.allOf.push(k)):(Object.assign(y,k),Object.assign(y,l))}$.isParent||this.override({zodSchema:h,jsonSchema:y,path:$.path??[]})};for(let h of[...this.seen.entries()].reverse())c(h[0],{target:this.target});let p={};if(this.target==="draft-2020-12"?p.$schema="https://json-schema.org/draft/2020-12/schema":this.target==="draft-7"?p.$schema="http://json-schema.org/draft-07/schema#":console.warn(`Invalid target: ${this.target}`),i.external?.uri){let h=i.external.registry.get(r)?.id;if(!h)throw new Error("Schema is missing an `id` property");p.$id=i.external.uri(h)}Object.assign(p,t.def);let g=i.external?.defs??{};for(let h of this.seen.entries()){let m=h[1];m.def&&m.defId&&(g[m.defId]=m.def)}i.external||Object.keys(g).length>0&&(this.target==="draft-2020-12"?p.$defs=g:p.definitions=g);try{return JSON.parse(JSON.stringify(p))}catch{throw new Error("Error converting schema to JSON.")}}}});var Al={};var Cl=S(()=>{});var be={};ke(be,{$ZodAny:()=>da,$ZodArray:()=>Mt,$ZodAsyncError:()=>fe,$ZodBase64:()=>ta,$ZodBase64URL:()=>ra,$ZodBigInt:()=>Mr,$ZodBigIntFormat:()=>sa,$ZodBoolean:()=>Lt,$ZodCIDRv4:()=>Yi,$ZodCIDRv6:()=>Xi,$ZodCUID:()=>Mi,$ZodCUID2:()=>qi,$ZodCatch:()=>Ta,$ZodCheck:()=>J,$ZodCheckBigIntFormat:()=>gi,$ZodCheckEndsWith:()=>Ii,$ZodCheckGreaterThan:()=>Rr,$ZodCheckIncludes:()=>Si,$ZodCheckLengthEquals:()=>xi,$ZodCheckLessThan:()=>Dr,$ZodCheckLowerCase:()=>zi,$ZodCheckMaxLength:()=>yi,$ZodCheckMaxSize:()=>hi,$ZodCheckMimeType:()=>Pi,$ZodCheckMinLength:()=>_i,$ZodCheckMinSize:()=>vi,$ZodCheckMultipleOf:()=>mi,$ZodCheckNumberFormat:()=>fi,$ZodCheckOverwrite:()=>Ti,$ZodCheckProperty:()=>ji,$ZodCheckRegex:()=>$i,$ZodCheckSizeEquals:()=>bi,$ZodCheckStartsWith:()=>wi,$ZodCheckStringFormat:()=>Ye,$ZodCheckUpperCase:()=>ki,$ZodCustom:()=>Ra,$ZodCustomStringFormat:()=>ia,$ZodDate:()=>fa,$ZodDefault:()=>wa,$ZodDiscriminatedUnion:()=>ha,$ZodE164:()=>na,$ZodEmail:()=>Zi,$ZodEmoji:()=>Ci,$ZodEnum:()=>xa,$ZodError:()=>Dt,$ZodFile:()=>za,$ZodFunction:()=>_n,$ZodGUID:()=>Di,$ZodIPv4:()=>Gi,$ZodIPv6:()=>Qi,$ZodISODate:()=>Bi,$ZodISODateTime:()=>Ji,$ZodISODuration:()=>Wi,$ZodISOTime:()=>Ki,$ZodIntersection:()=>va,$ZodJWT:()=>oa,$ZodKSUID:()=>Vi,$ZodLazy:()=>Da,$ZodLiteral:()=>$a,$ZodMap:()=>ya,$ZodNaN:()=>Oa,$ZodNanoID:()=>Li,$ZodNever:()=>pa,$ZodNonOptional:()=>ja,$ZodNull:()=>la,$ZodNullable:()=>Sa,$ZodNumber:()=>Lr,$ZodNumberFormat:()=>aa,$ZodObject:()=>ga,$ZodOptional:()=>ka,$ZodPipe:()=>Ft,$ZodPrefault:()=>Ia,$ZodPromise:()=>Ea,$ZodReadonly:()=>Na,$ZodRealError:()=>Ke,$ZodRecord:()=>ba,$ZodRegistry:()=>tt,$ZodSet:()=>_a,$ZodString:()=>Re,$ZodStringFormat:()=>q,$ZodSuccess:()=>Pa,$ZodSymbol:()=>ca,$ZodTemplateLiteral:()=>Ua,$ZodTransform:()=>qt,$ZodTuple:()=>Ze,$ZodType:()=>T,$ZodULID:()=>Fi,$ZodURL:()=>Ai,$ZodUUID:()=>Ri,$ZodUndefined:()=>ua,$ZodUnion:()=>qr,$ZodUnknown:()=>Xe,$ZodVoid:()=>ma,$ZodXID:()=>Hi,$brand:()=>kr,$constructor:()=>u,$input:()=>Vr,$output:()=>Hr,Doc:()=>Ct,JSONSchema:()=>Al,JSONSchemaGenerator:()=>Kt,NEVER:()=>zr,TimePrecision:()=>fn,_any:()=>cs,_array:()=>Bt,_base64:()=>ln,_base64url:()=>dn,_bigint:()=>ts,_boolean:()=>Xa,_catch:()=>df,_cidrv4:()=>cn,_cidrv6:()=>un,_coercedBigint:()=>rs,_coercedBoolean:()=>es,_coercedDate:()=>ps,_coercedNumber:()=>Ba,_coercedString:()=>Ma,_cuid:()=>en,_cuid2:()=>tn,_custom:()=>hs,_date:()=>ds,_default:()=>cf,_discriminatedUnion:()=>Gm,_e164:()=>pn,_email:()=>Jr,_emoji:()=>Yr,_endsWith:()=>ut,_enum:()=>tf,_file:()=>gs,_float32:()=>Wa,_float64:()=>Ga,_gt:()=>he,_gte:()=>oe,_guid:()=>Jt,_includes:()=>st,_int:()=>Ka,_int32:()=>Qa,_int64:()=>ns,_intersection:()=>Qm,_ipv4:()=>an,_ipv6:()=>sn,_isoDate:()=>Fa,_isoDateTime:()=>qa,_isoDuration:()=>Va,_isoTime:()=>Ha,_jwt:()=>mn,_ksuid:()=>on,_lazy:()=>gf,_length:()=>Le,_literal:()=>nf,_lowercase:()=>it,_lt:()=>ge,_lte:()=>ue,_map:()=>Xm,_max:()=>ue,_maxLength:()=>Ce,_maxSize:()=>Ae,_mime:()=>lt,_min:()=>oe,_minLength:()=>xe,_minSize:()=>je,_multipleOf:()=>Ie,_nan:()=>ms,_nanoid:()=>Xr,_nativeEnum:()=>rf,_negative:()=>hn,_never:()=>us,_nonnegative:()=>bn,_nonoptional:()=>uf,_nonpositive:()=>vn,_normalize:()=>dt,_null:()=>ss,_nullable:()=>sf,_number:()=>Ja,_optional:()=>af,_overwrite:()=>ve,_parse:()=>jr,_parseAsync:()=>Pr,_pipe:()=>pf,_positive:()=>gn,_promise:()=>hf,_property:()=>yn,_readonly:()=>mf,_record:()=>Ym,_refine:()=>vs,_regex:()=>ot,_safeParse:()=>Tr,_safeParseAsync:()=>Or,_set:()=>ef,_size:()=>nt,_startsWith:()=>ct,_string:()=>La,_stringFormat:()=>ys,_stringbool:()=>bs,_success:()=>lf,_symbol:()=>is,_templateLiteral:()=>ff,_toLowerCase:()=>mt,_toUpperCase:()=>ft,_transform:()=>of,_trim:()=>pt,_tuple:()=>fs,_uint32:()=>Ya,_uint64:()=>os,_ulid:()=>rn,_undefined:()=>as,_union:()=>Wm,_unknown:()=>rt,_uppercase:()=>at,_url:()=>Qr,_uuid:()=>Br,_uuidv4:()=>Kr,_uuidv6:()=>Wr,_uuidv7:()=>Gr,_void:()=>ls,_xid:()=>nn,clone:()=>ie,config:()=>K,flattenError:()=>We,formatError:()=>Ge,function:()=>xn,globalConfig:()=>It,globalRegistry:()=>me,isValidBase64:()=>ea,isValidBase64URL:()=>uu,isValidJWT:()=>lu,locales:()=>et,parse:()=>Rt,parseAsync:()=>Zt,prettifyError:()=>Ir,regexes:()=>we,registry:()=>Vt,safeParse:()=>Qe,safeParseAsync:()=>At,toDotPath:()=>Vc,toJSONSchema:()=>$n,treeifyError:()=>wr,util:()=>x,version:()=>Ni});var se=S(()=>{Ve();Nr();Zo();Ht();Zr();Ui();P();Er();Aa();Ca();Oi();Rl();_s();Zl();Cl()});var xs=S(()=>{se()});var Me={};ke(Me,{ZodISODate:()=>Gt,ZodISODateTime:()=>Wt,ZodISODuration:()=>Yt,ZodISOTime:()=>Qt,date:()=>zs,datetime:()=>$s,duration:()=>Ss,time:()=>ks});function $s(e){return qa(Wt,e)}function zs(e){return Fa(Gt,e)}function ks(e){return Ha(Qt,e)}function Ss(e){return Va(Yt,e)}var Wt,Gt,Qt,Yt,Sn=S(()=>{se();wn();Wt=u("ZodISODateTime",(e,r)=>{Ji.init(e,r),F.init(e,r)});Gt=u("ZodISODate",(e,r)=>{Bi.init(e,r),F.init(e,r)});Qt=u("ZodISOTime",(e,r)=>{Ki.init(e,r),F.init(e,r)});Yt=u("ZodISODuration",(e,r)=>{Wi.init(e,r),F.init(e,r)})});var Fl,Hl,qe,ws=S(()=>{se();se();Fl=(e,r)=>{Dt.init(e,r),e.name="ZodError",Object.defineProperties(e,{format:{value:n=>Ge(e,n)},flatten:{value:n=>We(e,n)},addIssue:{value:n=>e.issues.push(n)},addIssues:{value:n=>e.issues.push(...n)},isEmpty:{get(){return e.issues.length===0}}})},Hl=u("ZodError",Fl),qe=u("ZodError",Fl,{Parent:Error})});var In,jn,Pn,Tn,Is=S(()=>{se();ws();In=jr(qe),jn=Pr(qe),Pn=Tr(qe),Tn=Or(qe)});function d(e){return La(ht,e)}function Vl(e){return Jr(Un,e)}function Jl(e){return Jt(Xt,e)}function Bl(e){return Br(ye,e)}function Kl(e){return Kr(ye,e)}function Wl(e){return Wr(ye,e)}function Gl(e){return Gr(ye,e)}function Ql(e){return Qr(En,e)}function Yl(e){return Yr(Dn,e)}function Xl(e){return Xr(Rn,e)}function ed(e){return en(Zn,e)}function td(e){return tn(An,e)}function rd(e){return rn(Cn,e)}function nd(e){return nn(Ln,e)}function od(e){return on(Mn,e)}function id(e){return an(qn,e)}function ad(e){return sn(Fn,e)}function sd(e){return cn(Hn,e)}function cd(e){return un(Vn,e)}function ud(e){return ln(Jn,e)}function ld(e){return dn(Bn,e)}function dd(e){return pn(Kn,e)}function pd(e){return mn(Wn,e)}function md(e,r,n={}){return ys(js,e,r,n)}function R(e){return Ja(vt,e)}function On(e){return Ka(Fe,e)}function fd(e){return Wa(Fe,e)}function gd(e){return Ga(Fe,e)}function hd(e){return Qa(Fe,e)}function vd(e){return Ya(Fe,e)}function W(e){return Xa(bt,e)}function bd(e){return ts(yt,e)}function yd(e){return ns(Gn,e)}function _d(e){return os(Gn,e)}function xd(e){return is(Ps,e)}function $d(e){return as(Ts,e)}function rr(e){return ss(Os,e)}function zd(){return cs(Ns)}function V(){return rt(Us)}function nr(e){return us(Es,e)}function kd(e){return ls(Ds,e)}function Sd(e){return ds(or,e)}function N(e,r){return Bt(Rs,e,r)}function wd(e){let r=e._zod.def.shape;return I(Object.keys(r))}function z(e,r){let n={type:"object",get shape(){return x.assignProp(this,"shape",{...e}),this.shape},...x.normalizeParams(r)};return new ir(n)}function Id(e,r){return new ir({type:"object",get shape(){return x.assignProp(this,"shape",{...e}),this.shape},catchall:nr(),...x.normalizeParams(r)})}function Y(e,r){return new ir({type:"object",get shape(){return x.assignProp(this,"shape",{...e}),this.shape},catchall:V(),...x.normalizeParams(r)})}function C(e,r){return new Qn({type:"union",options:e,...x.normalizeParams(r)})}function ar(e,r,n){return new Zs({type:"union",options:r,discriminator:e,...x.normalizeParams(n)})}function _t(e,r){return new As({type:"intersection",left:e,right:r})}function jd(e,r,n){let i=r instanceof T,t=i?n:r,o=i?r:null;return new Cs({type:"tuple",items:e,rest:o,...x.normalizeParams(t)})}function L(e,r,n){return new Yn({type:"record",keyType:e,valueType:r,...x.normalizeParams(n)})}function Pd(e,r,n){return new Yn({type:"record",keyType:C([e,nr()]),valueType:r,...x.normalizeParams(n)})}function Td(e,r,n){return new Ls({type:"map",keyType:e,valueType:r,...x.normalizeParams(n)})}function Od(e,r){return new Ms({type:"set",valueType:e,...x.normalizeParams(r)})}function re(e,r){let n=Array.isArray(e)?Object.fromEntries(e.map(i=>[i,i])):e;return new gt({type:"enum",entries:n,...x.normalizeParams(r)})}function Nd(e,r){return new gt({type:"enum",entries:e,...x.normalizeParams(r)})}function I(e,r){return new qs({type:"literal",values:Array.isArray(e)?e:[e],...x.normalizeParams(r)})}function Ud(e){return gs(Fs,e)}function eo(e){return new Xn({type:"transform",transform:e})}function H(e){return new to({type:"optional",innerType:e})}function er(e){return new Hs({type:"nullable",innerType:e})}function Ed(e){return H(er(e))}function Js(e,r){return new Vs({type:"default",innerType:e,get defaultValue(){return typeof r=="function"?r():r}})}function Ks(e,r){return new Bs({type:"prefault",innerType:e,get defaultValue(){return typeof r=="function"?r():r}})}function Ws(e,r){return new ro({type:"nonoptional",innerType:e,...x.normalizeParams(r)})}function Dd(e){return new Gs({type:"success",innerType:e})}function Ys(e,r){return new Qs({type:"catch",innerType:e,catchValue:typeof r=="function"?r:()=>r})}function Rd(e){return ms(Xs,e)}function tr(e,r){return new no({type:"pipe",in:e,out:r})}function tc(e){return new ec({type:"readonly",innerType:e})}function Zd(e,r){return new rc({type:"template_literal",parts:e,...x.normalizeParams(r)})}function oc(e){return new nc({type:"lazy",getter:e})}function Ad(e){return new ic({type:"promise",innerType:e})}function ac(e){let r=new J({check:"custom"});return r._zod.check=e,r}function oo(e,r){return hs(sr,e??(()=>!0),r)}function sc(e,r={}){return vs(sr,e,r)}function cc(e){let r=ac(n=>(n.addIssue=i=>{if(typeof i=="string")n.issues.push(x.issue(i,n.value,r._zod.def));else{let t=i;t.fatal&&(t.continue=!1),t.code??(t.code="custom"),t.input??(t.input=n.value),t.inst??(t.inst=r),t.continue??(t.continue=!r._zod.def.abort),n.issues.push(x.issue(t))}},e(n.value,n)));return r}function Cd(e,r={error:`Input not instance of ${e.name}`}){let n=new sr({type:"custom",check:"custom",fn:i=>i instanceof e,abort:!0,...x.normalizeParams(r)});return n._zod.bag.Class=e,n}function Md(e){let r=oc(()=>C([d(e),R(),W(),rr(),N(r),L(d(),r)]));return r}function cr(e,r){return tr(eo(e),r)}var O,Nn,ht,F,Un,Xt,ye,En,Dn,Rn,Zn,An,Cn,Ln,Mn,qn,Fn,Hn,Vn,Jn,Bn,Kn,Wn,js,vt,Fe,bt,yt,Gn,Ps,Ts,Os,Ns,Us,Es,Ds,or,Rs,ir,Qn,Zs,As,Cs,Yn,Ls,Ms,gt,qs,Fs,Xn,to,Hs,Vs,Bs,ro,Gs,Qs,Xs,no,ec,rc,nc,ic,sr,Ld,wn=S(()=>{se();se();xs();Sn();Is();O=u("ZodType",(e,r)=>(T.init(e,r),e.def=r,Object.defineProperty(e,"_def",{value:r}),e.check=(...n)=>e.clone({...r,checks:[...r.checks??[],...n.map(i=>typeof i=="function"?{_zod:{check:i,def:{check:"custom"},onattach:[]}}:i)]}),e.clone=(n,i)=>ie(e,n,i),e.brand=()=>e,e.register=((n,i)=>(n.add(e,i),e)),e.parse=(n,i)=>In(e,n,i,{callee:e.parse}),e.safeParse=(n,i)=>Pn(e,n,i),e.parseAsync=async(n,i)=>jn(e,n,i,{callee:e.parseAsync}),e.safeParseAsync=async(n,i)=>Tn(e,n,i),e.spa=e.safeParseAsync,e.refine=(n,i)=>e.check(sc(n,i)),e.superRefine=n=>e.check(cc(n)),e.overwrite=n=>e.check(ve(n)),e.optional=()=>H(e),e.nullable=()=>er(e),e.nullish=()=>H(er(e)),e.nonoptional=n=>Ws(e,n),e.array=()=>N(e),e.or=n=>C([e,n]),e.and=n=>_t(e,n),e.transform=n=>tr(e,eo(n)),e.default=n=>Js(e,n),e.prefault=n=>Ks(e,n),e.catch=n=>Ys(e,n),e.pipe=n=>tr(e,n),e.readonly=()=>tc(e),e.describe=n=>{let i=e.clone();return me.add(i,{description:n}),i},Object.defineProperty(e,"description",{get(){return me.get(e)?.description},configurable:!0}),e.meta=(...n)=>{if(n.length===0)return me.get(e);let i=e.clone();return me.add(i,n[0]),i},e.isOptional=()=>e.safeParse(void 0).success,e.isNullable=()=>e.safeParse(null).success,e)),Nn=u("_ZodString",(e,r)=>{Re.init(e,r),O.init(e,r);let n=e._zod.bag;e.format=n.format??null,e.minLength=n.minimum??null,e.maxLength=n.maximum??null,e.regex=(...i)=>e.check(ot(...i)),e.includes=(...i)=>e.check(st(...i)),e.startsWith=(...i)=>e.check(ct(...i)),e.endsWith=(...i)=>e.check(ut(...i)),e.min=(...i)=>e.check(xe(...i)),e.max=(...i)=>e.check(Ce(...i)),e.length=(...i)=>e.check(Le(...i)),e.nonempty=(...i)=>e.check(xe(1,...i)),e.lowercase=i=>e.check(it(i)),e.uppercase=i=>e.check(at(i)),e.trim=()=>e.check(pt()),e.normalize=(...i)=>e.check(dt(...i)),e.toLowerCase=()=>e.check(mt()),e.toUpperCase=()=>e.check(ft())}),ht=u("ZodString",(e,r)=>{Re.init(e,r),Nn.init(e,r),e.email=n=>e.check(Jr(Un,n)),e.url=n=>e.check(Qr(En,n)),e.jwt=n=>e.check(mn(Wn,n)),e.emoji=n=>e.check(Yr(Dn,n)),e.guid=n=>e.check(Jt(Xt,n)),e.uuid=n=>e.check(Br(ye,n)),e.uuidv4=n=>e.check(Kr(ye,n)),e.uuidv6=n=>e.check(Wr(ye,n)),e.uuidv7=n=>e.check(Gr(ye,n)),e.nanoid=n=>e.check(Xr(Rn,n)),e.guid=n=>e.check(Jt(Xt,n)),e.cuid=n=>e.check(en(Zn,n)),e.cuid2=n=>e.check(tn(An,n)),e.ulid=n=>e.check(rn(Cn,n)),e.base64=n=>e.check(ln(Jn,n)),e.base64url=n=>e.check(dn(Bn,n)),e.xid=n=>e.check(nn(Ln,n)),e.ksuid=n=>e.check(on(Mn,n)),e.ipv4=n=>e.check(an(qn,n)),e.ipv6=n=>e.check(sn(Fn,n)),e.cidrv4=n=>e.check(cn(Hn,n)),e.cidrv6=n=>e.check(un(Vn,n)),e.e164=n=>e.check(pn(Kn,n)),e.datetime=n=>e.check($s(n)),e.date=n=>e.check(zs(n)),e.time=n=>e.check(ks(n)),e.duration=n=>e.check(Ss(n))});F=u("ZodStringFormat",(e,r)=>{q.init(e,r),Nn.init(e,r)}),Un=u("ZodEmail",(e,r)=>{Zi.init(e,r),F.init(e,r)});Xt=u("ZodGUID",(e,r)=>{Di.init(e,r),F.init(e,r)});ye=u("ZodUUID",(e,r)=>{Ri.init(e,r),F.init(e,r)});En=u("ZodURL",(e,r)=>{Ai.init(e,r),F.init(e,r)});Dn=u("ZodEmoji",(e,r)=>{Ci.init(e,r),F.init(e,r)});Rn=u("ZodNanoID",(e,r)=>{Li.init(e,r),F.init(e,r)});Zn=u("ZodCUID",(e,r)=>{Mi.init(e,r),F.init(e,r)});An=u("ZodCUID2",(e,r)=>{qi.init(e,r),F.init(e,r)});Cn=u("ZodULID",(e,r)=>{Fi.init(e,r),F.init(e,r)});Ln=u("ZodXID",(e,r)=>{Hi.init(e,r),F.init(e,r)});Mn=u("ZodKSUID",(e,r)=>{Vi.init(e,r),F.init(e,r)});qn=u("ZodIPv4",(e,r)=>{Gi.init(e,r),F.init(e,r)});Fn=u("ZodIPv6",(e,r)=>{Qi.init(e,r),F.init(e,r)});Hn=u("ZodCIDRv4",(e,r)=>{Yi.init(e,r),F.init(e,r)});Vn=u("ZodCIDRv6",(e,r)=>{Xi.init(e,r),F.init(e,r)});Jn=u("ZodBase64",(e,r)=>{ta.init(e,r),F.init(e,r)});Bn=u("ZodBase64URL",(e,r)=>{ra.init(e,r),F.init(e,r)});Kn=u("ZodE164",(e,r)=>{na.init(e,r),F.init(e,r)});Wn=u("ZodJWT",(e,r)=>{oa.init(e,r),F.init(e,r)});js=u("ZodCustomStringFormat",(e,r)=>{ia.init(e,r),F.init(e,r)});vt=u("ZodNumber",(e,r)=>{Lr.init(e,r),O.init(e,r),e.gt=(i,t)=>e.check(he(i,t)),e.gte=(i,t)=>e.check(oe(i,t)),e.min=(i,t)=>e.check(oe(i,t)),e.lt=(i,t)=>e.check(ge(i,t)),e.lte=(i,t)=>e.check(ue(i,t)),e.max=(i,t)=>e.check(ue(i,t)),e.int=i=>e.check(On(i)),e.safe=i=>e.check(On(i)),e.positive=i=>e.check(he(0,i)),e.nonnegative=i=>e.check(oe(0,i)),e.negative=i=>e.check(ge(0,i)),e.nonpositive=i=>e.check(ue(0,i)),e.multipleOf=(i,t)=>e.check(Ie(i,t)),e.step=(i,t)=>e.check(Ie(i,t)),e.finite=()=>e;let n=e._zod.bag;e.minValue=Math.max(n.minimum??Number.NEGATIVE_INFINITY,n.exclusiveMinimum??Number.NEGATIVE_INFINITY)??null,e.maxValue=Math.min(n.maximum??Number.POSITIVE_INFINITY,n.exclusiveMaximum??Number.POSITIVE_INFINITY)??null,e.isInt=(n.format??"").includes("int")||Number.isSafeInteger(n.multipleOf??.5),e.isFinite=!0,e.format=n.format??null});Fe=u("ZodNumberFormat",(e,r)=>{aa.init(e,r),vt.init(e,r)});bt=u("ZodBoolean",(e,r)=>{Lt.init(e,r),O.init(e,r)});yt=u("ZodBigInt",(e,r)=>{Mr.init(e,r),O.init(e,r),e.gte=(i,t)=>e.check(oe(i,t)),e.min=(i,t)=>e.check(oe(i,t)),e.gt=(i,t)=>e.check(he(i,t)),e.gte=(i,t)=>e.check(oe(i,t)),e.min=(i,t)=>e.check(oe(i,t)),e.lt=(i,t)=>e.check(ge(i,t)),e.lte=(i,t)=>e.check(ue(i,t)),e.max=(i,t)=>e.check(ue(i,t)),e.positive=i=>e.check(he(BigInt(0),i)),e.negative=i=>e.check(ge(BigInt(0),i)),e.nonpositive=i=>e.check(ue(BigInt(0),i)),e.nonnegative=i=>e.check(oe(BigInt(0),i)),e.multipleOf=(i,t)=>e.check(Ie(i,t));let n=e._zod.bag;e.minValue=n.minimum??null,e.maxValue=n.maximum??null,e.format=n.format??null});Gn=u("ZodBigIntFormat",(e,r)=>{sa.init(e,r),yt.init(e,r)});Ps=u("ZodSymbol",(e,r)=>{ca.init(e,r),O.init(e,r)});Ts=u("ZodUndefined",(e,r)=>{ua.init(e,r),O.init(e,r)});Os=u("ZodNull",(e,r)=>{la.init(e,r),O.init(e,r)});Ns=u("ZodAny",(e,r)=>{da.init(e,r),O.init(e,r)});Us=u("ZodUnknown",(e,r)=>{Xe.init(e,r),O.init(e,r)});Es=u("ZodNever",(e,r)=>{pa.init(e,r),O.init(e,r)});Ds=u("ZodVoid",(e,r)=>{ma.init(e,r),O.init(e,r)});or=u("ZodDate",(e,r)=>{fa.init(e,r),O.init(e,r),e.min=(i,t)=>e.check(oe(i,t)),e.max=(i,t)=>e.check(ue(i,t));let n=e._zod.bag;e.minDate=n.minimum?new Date(n.minimum):null,e.maxDate=n.maximum?new Date(n.maximum):null});Rs=u("ZodArray",(e,r)=>{Mt.init(e,r),O.init(e,r),e.element=r.element,e.min=(n,i)=>e.check(xe(n,i)),e.nonempty=n=>e.check(xe(1,n)),e.max=(n,i)=>e.check(Ce(n,i)),e.length=(n,i)=>e.check(Le(n,i)),e.unwrap=()=>e.element});ir=u("ZodObject",(e,r)=>{ga.init(e,r),O.init(e,r),x.defineLazy(e,"shape",()=>r.shape),e.keyof=()=>re(Object.keys(e._zod.def.shape)),e.catchall=n=>e.clone({...e._zod.def,catchall:n}),e.passthrough=()=>e.clone({...e._zod.def,catchall:V()}),e.loose=()=>e.clone({...e._zod.def,catchall:V()}),e.strict=()=>e.clone({...e._zod.def,catchall:nr()}),e.strip=()=>e.clone({...e._zod.def,catchall:void 0}),e.extend=n=>x.extend(e,n),e.merge=n=>x.merge(e,n),e.pick=n=>x.pick(e,n),e.omit=n=>x.omit(e,n),e.partial=(...n)=>x.partial(to,e,n[0]),e.required=(...n)=>x.required(ro,e,n[0])});Qn=u("ZodUnion",(e,r)=>{qr.init(e,r),O.init(e,r),e.options=r.options});Zs=u("ZodDiscriminatedUnion",(e,r)=>{Qn.init(e,r),ha.init(e,r)});As=u("ZodIntersection",(e,r)=>{va.init(e,r),O.init(e,r)});Cs=u("ZodTuple",(e,r)=>{Ze.init(e,r),O.init(e,r),e.rest=n=>e.clone({...e._zod.def,rest:n})});Yn=u("ZodRecord",(e,r)=>{ba.init(e,r),O.init(e,r),e.keyType=r.keyType,e.valueType=r.valueType});Ls=u("ZodMap",(e,r)=>{ya.init(e,r),O.init(e,r),e.keyType=r.keyType,e.valueType=r.valueType});Ms=u("ZodSet",(e,r)=>{_a.init(e,r),O.init(e,r),e.min=(...n)=>e.check(je(...n)),e.nonempty=n=>e.check(je(1,n)),e.max=(...n)=>e.check(Ae(...n)),e.size=(...n)=>e.check(nt(...n))});gt=u("ZodEnum",(e,r)=>{xa.init(e,r),O.init(e,r),e.enum=r.entries,e.options=Object.values(r.entries);let n=new Set(Object.keys(r.entries));e.extract=(i,t)=>{let o={};for(let a of i)if(n.has(a))o[a]=r.entries[a];else throw new Error(`Key ${a} not found in enum`);return new gt({...r,checks:[],...x.normalizeParams(t),entries:o})},e.exclude=(i,t)=>{let o={...r.entries};for(let a of i)if(n.has(a))delete o[a];else throw new Error(`Key ${a} not found in enum`);return new gt({...r,checks:[],...x.normalizeParams(t),entries:o})}});qs=u("ZodLiteral",(e,r)=>{$a.init(e,r),O.init(e,r),e.values=new Set(r.values),Object.defineProperty(e,"value",{get(){if(r.values.length>1)throw new Error("This schema contains multiple valid literal values. Use `.values` instead.");return r.values[0]}})});Fs=u("ZodFile",(e,r)=>{za.init(e,r),O.init(e,r),e.min=(n,i)=>e.check(je(n,i)),e.max=(n,i)=>e.check(Ae(n,i)),e.mime=(n,i)=>e.check(lt(Array.isArray(n)?n:[n],i))});Xn=u("ZodTransform",(e,r)=>{qt.init(e,r),O.init(e,r),e._zod.parse=(n,i)=>{n.addIssue=o=>{if(typeof o=="string")n.issues.push(x.issue(o,n.value,r));else{let a=o;a.fatal&&(a.continue=!1),a.code??(a.code="custom"),a.input??(a.input=n.value),a.inst??(a.inst=e),a.continue??(a.continue=!0),n.issues.push(x.issue(a))}};let t=r.transform(n.value,n);return t instanceof Promise?t.then(o=>(n.value=o,n)):(n.value=t,n)}});to=u("ZodOptional",(e,r)=>{ka.init(e,r),O.init(e,r),e.unwrap=()=>e._zod.def.innerType});Hs=u("ZodNullable",(e,r)=>{Sa.init(e,r),O.init(e,r),e.unwrap=()=>e._zod.def.innerType});Vs=u("ZodDefault",(e,r)=>{wa.init(e,r),O.init(e,r),e.unwrap=()=>e._zod.def.innerType,e.removeDefault=e.unwrap});Bs=u("ZodPrefault",(e,r)=>{Ia.init(e,r),O.init(e,r),e.unwrap=()=>e._zod.def.innerType});ro=u("ZodNonOptional",(e,r)=>{ja.init(e,r),O.init(e,r),e.unwrap=()=>e._zod.def.innerType});Gs=u("ZodSuccess",(e,r)=>{Pa.init(e,r),O.init(e,r),e.unwrap=()=>e._zod.def.innerType});Qs=u("ZodCatch",(e,r)=>{Ta.init(e,r),O.init(e,r),e.unwrap=()=>e._zod.def.innerType,e.removeCatch=e.unwrap});Xs=u("ZodNaN",(e,r)=>{Oa.init(e,r),O.init(e,r)});no=u("ZodPipe",(e,r)=>{Ft.init(e,r),O.init(e,r),e.in=r.in,e.out=r.out});ec=u("ZodReadonly",(e,r)=>{Na.init(e,r),O.init(e,r)});rc=u("ZodTemplateLiteral",(e,r)=>{Ua.init(e,r),O.init(e,r)});nc=u("ZodLazy",(e,r)=>{Da.init(e,r),O.init(e,r),e.unwrap=()=>e._zod.def.getter()});ic=u("ZodPromise",(e,r)=>{Ea.init(e,r),O.init(e,r),e.unwrap=()=>e._zod.def.innerType});sr=u("ZodCustom",(e,r)=>{Ra.init(e,r),O.init(e,r)});Ld=(...e)=>bs({Pipe:no,Boolean:bt,String:ht,Transform:Xn},...e)});function Fd(e){K({customError:e})}function Hd(){return K().customError}var qd,Vd=S(()=>{se();qd={invalid_type:"invalid_type",too_big:"too_big",too_small:"too_small",invalid_format:"invalid_format",not_multiple_of:"not_multiple_of",unrecognized_keys:"unrecognized_keys",invalid_union:"invalid_union",invalid_key:"invalid_key",invalid_element:"invalid_element",invalid_value:"invalid_value",custom:"custom"}});var io={};ke(io,{bigint:()=>$f,boolean:()=>xf,date:()=>zf,number:()=>_f,string:()=>yf});function yf(e){return Ma(ht,e)}function _f(e){return Ba(vt,e)}function xf(e){return es(bt,e)}function $f(e){return rs(yt,e)}function zf(e){return ps(or,e)}var Jd=S(()=>{se();wn()});var s={};ke(s,{$brand:()=>kr,$input:()=>Vr,$output:()=>Hr,NEVER:()=>zr,TimePrecision:()=>fn,ZodAny:()=>Ns,ZodArray:()=>Rs,ZodBase64:()=>Jn,ZodBase64URL:()=>Bn,ZodBigInt:()=>yt,ZodBigIntFormat:()=>Gn,ZodBoolean:()=>bt,ZodCIDRv4:()=>Hn,ZodCIDRv6:()=>Vn,ZodCUID:()=>Zn,ZodCUID2:()=>An,ZodCatch:()=>Qs,ZodCustom:()=>sr,ZodCustomStringFormat:()=>js,ZodDate:()=>or,ZodDefault:()=>Vs,ZodDiscriminatedUnion:()=>Zs,ZodE164:()=>Kn,ZodEmail:()=>Un,ZodEmoji:()=>Dn,ZodEnum:()=>gt,ZodError:()=>Hl,ZodFile:()=>Fs,ZodGUID:()=>Xt,ZodIPv4:()=>qn,ZodIPv6:()=>Fn,ZodISODate:()=>Gt,ZodISODateTime:()=>Wt,ZodISODuration:()=>Yt,ZodISOTime:()=>Qt,ZodIntersection:()=>As,ZodIssueCode:()=>qd,ZodJWT:()=>Wn,ZodKSUID:()=>Mn,ZodLazy:()=>nc,ZodLiteral:()=>qs,ZodMap:()=>Ls,ZodNaN:()=>Xs,ZodNanoID:()=>Rn,ZodNever:()=>Es,ZodNonOptional:()=>ro,ZodNull:()=>Os,ZodNullable:()=>Hs,ZodNumber:()=>vt,ZodNumberFormat:()=>Fe,ZodObject:()=>ir,ZodOptional:()=>to,ZodPipe:()=>no,ZodPrefault:()=>Bs,ZodPromise:()=>ic,ZodReadonly:()=>ec,ZodRealError:()=>qe,ZodRecord:()=>Yn,ZodSet:()=>Ms,ZodString:()=>ht,ZodStringFormat:()=>F,ZodSuccess:()=>Gs,ZodSymbol:()=>Ps,ZodTemplateLiteral:()=>rc,ZodTransform:()=>Xn,ZodTuple:()=>Cs,ZodType:()=>O,ZodULID:()=>Cn,ZodURL:()=>En,ZodUUID:()=>ye,ZodUndefined:()=>Ts,ZodUnion:()=>Qn,ZodUnknown:()=>Us,ZodVoid:()=>Ds,ZodXID:()=>Ln,_ZodString:()=>Nn,_default:()=>Js,any:()=>zd,array:()=>N,base64:()=>ud,base64url:()=>ld,bigint:()=>bd,boolean:()=>W,catch:()=>Ys,check:()=>ac,cidrv4:()=>sd,cidrv6:()=>cd,clone:()=>ie,coerce:()=>io,config:()=>K,core:()=>be,cuid:()=>ed,cuid2:()=>td,custom:()=>oo,date:()=>Sd,discriminatedUnion:()=>ar,e164:()=>dd,email:()=>Vl,emoji:()=>Yl,endsWith:()=>ut,enum:()=>re,file:()=>Ud,flattenError:()=>We,float32:()=>fd,float64:()=>gd,formatError:()=>Ge,function:()=>xn,getErrorMap:()=>Hd,globalRegistry:()=>me,gt:()=>he,gte:()=>oe,guid:()=>Jl,includes:()=>st,instanceof:()=>Cd,int:()=>On,int32:()=>hd,int64:()=>yd,intersection:()=>_t,ipv4:()=>id,ipv6:()=>ad,iso:()=>Me,json:()=>Md,jwt:()=>pd,keyof:()=>wd,ksuid:()=>od,lazy:()=>oc,length:()=>Le,literal:()=>I,locales:()=>et,looseObject:()=>Y,lowercase:()=>it,lt:()=>ge,lte:()=>ue,map:()=>Td,maxLength:()=>Ce,maxSize:()=>Ae,mime:()=>lt,minLength:()=>xe,minSize:()=>je,multipleOf:()=>Ie,nan:()=>Rd,nanoid:()=>Xl,nativeEnum:()=>Nd,negative:()=>hn,never:()=>nr,nonnegative:()=>bn,nonoptional:()=>Ws,nonpositive:()=>vn,normalize:()=>dt,null:()=>rr,nullable:()=>er,nullish:()=>Ed,number:()=>R,object:()=>z,optional:()=>H,overwrite:()=>ve,parse:()=>In,parseAsync:()=>jn,partialRecord:()=>Pd,pipe:()=>tr,positive:()=>gn,prefault:()=>Ks,preprocess:()=>cr,prettifyError:()=>Ir,promise:()=>Ad,property:()=>yn,readonly:()=>tc,record:()=>L,refine:()=>sc,regex:()=>ot,regexes:()=>we,registry:()=>Vt,safeParse:()=>Pn,safeParseAsync:()=>Tn,set:()=>Od,setErrorMap:()=>Fd,size:()=>nt,startsWith:()=>ct,strictObject:()=>Id,string:()=>d,stringFormat:()=>md,stringbool:()=>Ld,success:()=>Dd,superRefine:()=>cc,symbol:()=>xd,templateLiteral:()=>Zd,toJSONSchema:()=>$n,toLowerCase:()=>mt,toUpperCase:()=>ft,transform:()=>eo,treeifyError:()=>wr,trim:()=>pt,tuple:()=>jd,uint32:()=>vd,uint64:()=>_d,ulid:()=>rd,undefined:()=>$d,union:()=>C,unknown:()=>V,uppercase:()=>at,url:()=>Ql,uuid:()=>Bl,uuidv4:()=>Kl,uuidv6:()=>Wl,uuidv7:()=>Gl,void:()=>kd,xid:()=>nd});var uc=S(()=>{se();wn();xs();ws();Is();Vd();se();Za();se();Aa();Sn();Sn();Jd();K(Fr())});var Bd,lc=S(()=>{uc();uc();Bd=s});var dc={};ke(dc,{$brand:()=>kr,$input:()=>Vr,$output:()=>Hr,NEVER:()=>zr,TimePrecision:()=>fn,ZodAny:()=>Ns,ZodArray:()=>Rs,ZodBase64:()=>Jn,ZodBase64URL:()=>Bn,ZodBigInt:()=>yt,ZodBigIntFormat:()=>Gn,ZodBoolean:()=>bt,ZodCIDRv4:()=>Hn,ZodCIDRv6:()=>Vn,ZodCUID:()=>Zn,ZodCUID2:()=>An,ZodCatch:()=>Qs,ZodCustom:()=>sr,ZodCustomStringFormat:()=>js,ZodDate:()=>or,ZodDefault:()=>Vs,ZodDiscriminatedUnion:()=>Zs,ZodE164:()=>Kn,ZodEmail:()=>Un,ZodEmoji:()=>Dn,ZodEnum:()=>gt,ZodError:()=>Hl,ZodFile:()=>Fs,ZodGUID:()=>Xt,ZodIPv4:()=>qn,ZodIPv6:()=>Fn,ZodISODate:()=>Gt,ZodISODateTime:()=>Wt,ZodISODuration:()=>Yt,ZodISOTime:()=>Qt,ZodIntersection:()=>As,ZodIssueCode:()=>qd,ZodJWT:()=>Wn,ZodKSUID:()=>Mn,ZodLazy:()=>nc,ZodLiteral:()=>qs,ZodMap:()=>Ls,ZodNaN:()=>Xs,ZodNanoID:()=>Rn,ZodNever:()=>Es,ZodNonOptional:()=>ro,ZodNull:()=>Os,ZodNullable:()=>Hs,ZodNumber:()=>vt,ZodNumberFormat:()=>Fe,ZodObject:()=>ir,ZodOptional:()=>to,ZodPipe:()=>no,ZodPrefault:()=>Bs,ZodPromise:()=>ic,ZodReadonly:()=>ec,ZodRealError:()=>qe,ZodRecord:()=>Yn,ZodSet:()=>Ms,ZodString:()=>ht,ZodStringFormat:()=>F,ZodSuccess:()=>Gs,ZodSymbol:()=>Ps,ZodTemplateLiteral:()=>rc,ZodTransform:()=>Xn,ZodTuple:()=>Cs,ZodType:()=>O,ZodULID:()=>Cn,ZodURL:()=>En,ZodUUID:()=>ye,ZodUndefined:()=>Ts,ZodUnion:()=>Qn,ZodUnknown:()=>Us,ZodVoid:()=>Ds,ZodXID:()=>Ln,_ZodString:()=>Nn,_default:()=>Js,any:()=>zd,array:()=>N,base64:()=>ud,base64url:()=>ld,bigint:()=>bd,boolean:()=>W,catch:()=>Ys,check:()=>ac,cidrv4:()=>sd,cidrv6:()=>cd,clone:()=>ie,coerce:()=>io,config:()=>K,core:()=>be,cuid:()=>ed,cuid2:()=>td,custom:()=>oo,date:()=>Sd,default:()=>kf,discriminatedUnion:()=>ar,e164:()=>dd,email:()=>Vl,emoji:()=>Yl,endsWith:()=>ut,enum:()=>re,file:()=>Ud,flattenError:()=>We,float32:()=>fd,float64:()=>gd,formatError:()=>Ge,function:()=>xn,getErrorMap:()=>Hd,globalRegistry:()=>me,gt:()=>he,gte:()=>oe,guid:()=>Jl,includes:()=>st,instanceof:()=>Cd,int:()=>On,int32:()=>hd,int64:()=>yd,intersection:()=>_t,ipv4:()=>id,ipv6:()=>ad,iso:()=>Me,json:()=>Md,jwt:()=>pd,keyof:()=>wd,ksuid:()=>od,lazy:()=>oc,length:()=>Le,literal:()=>I,locales:()=>et,looseObject:()=>Y,lowercase:()=>it,lt:()=>ge,lte:()=>ue,map:()=>Td,maxLength:()=>Ce,maxSize:()=>Ae,mime:()=>lt,minLength:()=>xe,minSize:()=>je,multipleOf:()=>Ie,nan:()=>Rd,nanoid:()=>Xl,nativeEnum:()=>Nd,negative:()=>hn,never:()=>nr,nonnegative:()=>bn,nonoptional:()=>Ws,nonpositive:()=>vn,normalize:()=>dt,null:()=>rr,nullable:()=>er,nullish:()=>Ed,number:()=>R,object:()=>z,optional:()=>H,overwrite:()=>ve,parse:()=>In,parseAsync:()=>jn,partialRecord:()=>Pd,pipe:()=>tr,positive:()=>gn,prefault:()=>Ks,preprocess:()=>cr,prettifyError:()=>Ir,promise:()=>Ad,property:()=>yn,readonly:()=>tc,record:()=>L,refine:()=>sc,regex:()=>ot,regexes:()=>we,registry:()=>Vt,safeParse:()=>Pn,safeParseAsync:()=>Tn,set:()=>Od,setErrorMap:()=>Fd,size:()=>nt,startsWith:()=>ct,strictObject:()=>Id,string:()=>d,stringFormat:()=>md,stringbool:()=>Ld,success:()=>Dd,superRefine:()=>cc,symbol:()=>xd,templateLiteral:()=>Zd,toJSONSchema:()=>$n,toLowerCase:()=>mt,toUpperCase:()=>ft,transform:()=>eo,treeifyError:()=>wr,trim:()=>pt,tuple:()=>jd,uint32:()=>vd,uint64:()=>_d,ulid:()=>rd,undefined:()=>$d,union:()=>C,unknown:()=>V,uppercase:()=>at,url:()=>Ql,uuid:()=>Bl,uuidv4:()=>Kl,uuidv6:()=>Wl,uuidv7:()=>Gl,void:()=>kd,xid:()=>nd,z:()=>s});var kf,ur=S(()=>{lc();lc();kf=Bd});se();function zn(e){return!!e._zod}function kn(e,r){return zn(e)?Qe(e,r):e.safeParse(r)}function Ll(e){if(!e)return;let r;if(zn(e)?r=e._zod?.def?.shape:r=e.shape,!!r){if(typeof r=="function")try{return r()}catch{return}return r}}function Ml(e){if(zn(e)){let o=e._zod?.def;if(o){if(o.value!==void 0)return o.value;if(Array.isArray(o.values)&&o.values.length>0)return o.values[0]}}let n=e._def;if(n){if(n.value!==void 0)return n.value;if(Array.isArray(n.values)&&n.values.length>0)return n.values[0]}let i=e.value;if(i!==void 0)return i}ur();var Pe="io.modelcontextprotocol/related-task",so="2.0",Q=oo(e=>e!==null&&(typeof e=="object"||typeof e=="function")),Kd=C([d(),R().int()]),Wd=d(),hy=Y({ttl:R().optional(),pollInterval:R().optional()}),Sf=z({ttl:R().optional()}),wf=z({taskId:d()}),mc=Y({progressToken:Kd.optional(),[Pe]:wf.optional()}),le=z({_meta:mc.optional()}),lr=le.extend({task:Sf.optional()}),Gd=e=>lr.safeParse(e).success,X=z({method:d(),params:le.loose().optional()}),de=z({_meta:mc.optional()}),pe=z({method:d(),params:de.loose().optional()}),ee=Y({_meta:mc.optional()}),$t=C([d(),R().int()]),Qd=z({jsonrpc:I(so),id:$t,...X.shape}).strict(),fc=e=>Qd.safeParse(e).success,Yd=z({jsonrpc:I(so),...pe.shape}).strict(),Xd=e=>Yd.safeParse(e).success,gc=z({jsonrpc:I(so),id:$t,result:ee}).strict(),dr=e=>gc.safeParse(e).success;var Z;(function(e){e[e.ConnectionClosed=-32e3]="ConnectionClosed",e[e.RequestTimeout=-32001]="RequestTimeout",e[e.ParseError=-32700]="ParseError",e[e.InvalidRequest=-32600]="InvalidRequest",e[e.MethodNotFound=-32601]="MethodNotFound",e[e.InvalidParams=-32602]="InvalidParams",e[e.InternalError=-32603]="InternalError",e[e.UrlElicitationRequired=-32042]="UrlElicitationRequired"})(Z||(Z={}));var hc=z({jsonrpc:I(so),id:$t.optional(),error:z({code:R().int(),message:d(),data:V().optional()})}).strict();var ep=e=>hc.safeParse(e).success;var tp=C([Qd,Yd,gc,hc]),vy=C([gc,hc]),co=ee.strict(),If=de.extend({requestId:$t.optional(),reason:d().optional()}),uo=pe.extend({method:I("notifications/cancelled"),params:If}),jf=z({src:d(),mimeType:d().optional(),sizes:N(d()).optional(),theme:re(["light","dark"]).optional()}),pr=z({icons:N(jf).optional()}),xt=z({name:d(),title:d().optional()}),mr=xt.extend({...xt.shape,...pr.shape,version:d(),websiteUrl:d().optional(),description:d().optional()}),Pf=_t(z({applyDefaults:W().optional()}),L(d(),V())),Tf=cr(e=>e&&typeof e=="object"&&!Array.isArray(e)&&Object.keys(e).length===0?{form:{}}:e,_t(z({form:Pf.optional(),url:Q.optional()}),L(d(),V()).optional())),Of=Y({list:Q.optional(),cancel:Q.optional(),requests:Y({sampling:Y({createMessage:Q.optional()}).optional(),elicitation:Y({create:Q.optional()}).optional()}).optional()}),Nf=Y({list:Q.optional(),cancel:Q.optional(),requests:Y({tools:Y({call:Q.optional()}).optional()}).optional()}),Uf=z({experimental:L(d(),Q).optional(),sampling:z({context:Q.optional(),tools:Q.optional()}).optional(),elicitation:Tf.optional(),roots:z({listChanged:W().optional()}).optional(),tasks:Of.optional(),extensions:L(d(),Q).optional()}),Ef=le.extend({protocolVersion:d(),capabilities:Uf,clientInfo:mr}),Df=X.extend({method:I("initialize"),params:Ef});var Rf=z({experimental:L(d(),Q).optional(),logging:Q.optional(),completions:Q.optional(),prompts:z({listChanged:W().optional()}).optional(),resources:z({subscribe:W().optional(),listChanged:W().optional()}).optional(),tools:z({listChanged:W().optional()}).optional(),tasks:Nf.optional(),extensions:L(d(),Q).optional()}),Zf=ee.extend({protocolVersion:d(),capabilities:Rf,serverInfo:mr,instructions:d().optional()}),Af=pe.extend({method:I("notifications/initialized"),params:de.optional()});var zt=X.extend({method:I("ping"),params:le.optional()}),Cf=z({progress:R(),total:H(R()),message:H(d())}),Lf=z({...de.shape,...Cf.shape,progressToken:Kd}),lo=pe.extend({method:I("notifications/progress"),params:Lf}),Mf=le.extend({cursor:Wd.optional()}),fr=X.extend({params:Mf.optional()}),gr=ee.extend({nextCursor:Wd.optional()}),qf=re(["working","input_required","completed","failed","cancelled"]),hr=z({taskId:d(),status:qf,ttl:C([R(),rr()]),createdAt:d(),lastUpdatedAt:d(),pollInterval:H(R()),statusMessage:H(d())}),po=ee.extend({task:hr}),Ff=de.merge(hr),vr=pe.extend({method:I("notifications/tasks/status"),params:Ff}),mo=X.extend({method:I("tasks/get"),params:le.extend({taskId:d()})}),fo=ee.merge(hr),go=X.extend({method:I("tasks/result"),params:le.extend({taskId:d()})}),by=ee.loose(),ho=fr.extend({method:I("tasks/list")}),vo=gr.extend({tasks:N(hr)}),bo=X.extend({method:I("tasks/cancel"),params:le.extend({taskId:d()})}),rp=ee.merge(hr),np=z({uri:d(),mimeType:H(d()),_meta:L(d(),V()).optional()}),op=np.extend({text:d()}),vc=d().refine(e=>{try{return atob(e),!0}catch{return!1}},{message:"Invalid Base64 string"}),ip=np.extend({blob:vc}),br=re(["user","assistant"]),kt=z({audience:N(br).optional(),priority:R().min(0).max(1).optional(),lastModified:Me.datetime({offset:!0}).optional()}),ap=z({...xt.shape,...pr.shape,uri:d(),description:H(d()),mimeType:H(d()),size:H(R()),annotations:kt.optional(),_meta:H(Y({}))}),Hf=z({...xt.shape,...pr.shape,uriTemplate:d(),description:H(d()),mimeType:H(d()),annotations:kt.optional(),_meta:H(Y({}))}),Vf=fr.extend({method:I("resources/list")}),bc=gr.extend({resources:N(ap)}),Jf=fr.extend({method:I("resources/templates/list")}),Bf=gr.extend({resourceTemplates:N(Hf)}),yc=le.extend({uri:d()}),Kf=yc,Wf=X.extend({method:I("resources/read"),params:Kf}),_c=ee.extend({contents:N(C([op,ip]))}),Gf=pe.extend({method:I("notifications/resources/list_changed"),params:de.optional()}),Qf=yc,Yf=X.extend({method:I("resources/subscribe"),params:Qf}),Xf=yc,eg=X.extend({method:I("resources/unsubscribe"),params:Xf}),tg=de.extend({uri:d()}),rg=pe.extend({method:I("notifications/resources/updated"),params:tg}),ng=z({name:d(),description:H(d()),required:H(W())}),og=z({...xt.shape,...pr.shape,description:H(d()),arguments:H(N(ng)),_meta:H(Y({}))}),ig=fr.extend({method:I("prompts/list")}),ag=gr.extend({prompts:N(og)}),sg=le.extend({name:d(),arguments:L(d(),d()).optional()}),cg=X.extend({method:I("prompts/get"),params:sg}),xc=z({type:I("text"),text:d(),annotations:kt.optional(),_meta:L(d(),V()).optional()}),$c=z({type:I("image"),data:vc,mimeType:d(),annotations:kt.optional(),_meta:L(d(),V()).optional()}),zc=z({type:I("audio"),data:vc,mimeType:d(),annotations:kt.optional(),_meta:L(d(),V()).optional()}),ug=z({type:I("tool_use"),name:d(),id:d(),input:L(d(),V()),_meta:L(d(),V()).optional()}),kc=z({type:I("resource"),resource:C([op,ip]),annotations:kt.optional(),_meta:L(d(),V()).optional()}),Sc=ap.extend({type:I("resource_link")}),St=C([xc,$c,zc,Sc,kc]),lg=z({role:br,content:St}),dg=ee.extend({description:d().optional(),messages:N(lg)}),pg=pe.extend({method:I("notifications/prompts/list_changed"),params:de.optional()}),mg=z({title:d().optional(),readOnlyHint:W().optional(),destructiveHint:W().optional(),idempotentHint:W().optional(),openWorldHint:W().optional()}),fg=z({taskSupport:re(["required","optional","forbidden"]).optional()}),yo=z({...xt.shape,...pr.shape,description:d().optional(),inputSchema:z({type:I("object"),properties:L(d(),Q).optional(),required:N(d()).optional()}).catchall(V()),outputSchema:z({type:I("object"),properties:L(d(),Q).optional(),required:N(d()).optional()}).catchall(V()).optional(),annotations:mg.optional(),execution:fg.optional(),_meta:L(d(),V()).optional()}),wc=fr.extend({method:I("tools/list")}),gg=gr.extend({tools:N(yo)}),wt=ee.extend({content:N(St).default([]),structuredContent:L(d(),V()).optional(),isError:W().optional()}),yy=wt.or(ee.extend({toolResult:V()})),hg=lr.extend({name:d(),arguments:L(d(),V()).optional()}),Ic=X.extend({method:I("tools/call"),params:hg}),vg=pe.extend({method:I("notifications/tools/list_changed"),params:de.optional()}),_y=z({autoRefresh:W().default(!0),debounceMs:R().int().nonnegative().default(300)}),sp=re(["debug","info","notice","warning","error","critical","alert","emergency"]),bg=le.extend({level:sp}),yg=X.extend({method:I("logging/setLevel"),params:bg}),_g=de.extend({level:sp,logger:d().optional(),data:V()}),xg=pe.extend({method:I("notifications/message"),params:_g}),$g=z({name:d().optional()}),zg=z({hints:N($g).optional(),costPriority:R().min(0).max(1).optional(),speedPriority:R().min(0).max(1).optional(),intelligencePriority:R().min(0).max(1).optional()}),kg=z({mode:re(["auto","required","none"]).optional()}),Sg=z({type:I("tool_result"),toolUseId:d().describe("The unique identifier for the corresponding tool call."),content:N(St).default([]),structuredContent:z({}).loose().optional(),isError:W().optional(),_meta:L(d(),V()).optional()}),wg=ar("type",[xc,$c,zc]),ao=ar("type",[xc,$c,zc,ug,Sg]),Ig=z({role:br,content:C([ao,N(ao)]),_meta:L(d(),V()).optional()}),jg=lr.extend({messages:N(Ig),modelPreferences:zg.optional(),systemPrompt:d().optional(),includeContext:re(["none","thisServer","allServers"]).optional(),temperature:R().optional(),maxTokens:R().int(),stopSequences:N(d()).optional(),metadata:Q.optional(),tools:N(yo).optional(),toolChoice:kg.optional()}),Pg=X.extend({method:I("sampling/createMessage"),params:jg}),jc=ee.extend({model:d(),stopReason:H(re(["endTurn","stopSequence","maxTokens"]).or(d())),role:br,content:wg}),Pc=ee.extend({model:d(),stopReason:H(re(["endTurn","stopSequence","maxTokens","toolUse"]).or(d())),role:br,content:C([ao,N(ao)])}),Tg=z({type:I("boolean"),title:d().optional(),description:d().optional(),default:W().optional()}),Og=z({type:I("string"),title:d().optional(),description:d().optional(),minLength:R().optional(),maxLength:R().optional(),format:re(["email","uri","date","date-time"]).optional(),default:d().optional()}),Ng=z({type:re(["number","integer"]),title:d().optional(),description:d().optional(),minimum:R().optional(),maximum:R().optional(),default:R().optional()}),Ug=z({type:I("string"),title:d().optional(),description:d().optional(),enum:N(d()),default:d().optional()}),Eg=z({type:I("string"),title:d().optional(),description:d().optional(),oneOf:N(z({const:d(),title:d()})),default:d().optional()}),Dg=z({type:I("string"),title:d().optional(),description:d().optional(),enum:N(d()),enumNames:N(d()).optional(),default:d().optional()}),Rg=C([Ug,Eg]),Zg=z({type:I("array"),title:d().optional(),description:d().optional(),minItems:R().optional(),maxItems:R().optional(),items:z({type:I("string"),enum:N(d())}),default:N(d()).optional()}),Ag=z({type:I("array"),title:d().optional(),description:d().optional(),minItems:R().optional(),maxItems:R().optional(),items:z({anyOf:N(z({const:d(),title:d()}))}),default:N(d()).optional()}),Cg=C([Zg,Ag]),Lg=C([Dg,Rg,Cg]),Mg=C([Lg,Tg,Og,Ng]),qg=lr.extend({mode:I("form").optional(),message:d(),requestedSchema:z({type:I("object"),properties:L(d(),Mg),required:N(d()).optional()})}),Fg=lr.extend({mode:I("url"),message:d(),elicitationId:d(),url:d().url()}),Hg=C([qg,Fg]),Vg=X.extend({method:I("elicitation/create"),params:Hg}),Jg=de.extend({elicitationId:d()}),Bg=pe.extend({method:I("notifications/elicitation/complete"),params:Jg}),Kg=ee.extend({action:re(["accept","decline","cancel"]),content:cr(e=>e===null?void 0:e,L(d(),C([d(),R(),W(),N(d())])).optional())}),Wg=z({type:I("ref/resource"),uri:d()});var Gg=z({type:I("ref/prompt"),name:d()}),Qg=le.extend({ref:C([Gg,Wg]),argument:z({name:d(),value:d()}),context:z({arguments:L(d(),d()).optional()}).optional()}),Yg=X.extend({method:I("completion/complete"),params:Qg});var Xg=ee.extend({completion:Y({values:N(d()).max(100),total:H(R().int()),hasMore:H(W())})}),eh=z({uri:d().startsWith("file://"),name:d().optional(),_meta:L(d(),V()).optional()}),th=X.extend({method:I("roots/list"),params:le.optional()}),rh=ee.extend({roots:N(eh)}),nh=pe.extend({method:I("notifications/roots/list_changed"),params:de.optional()}),xy=C([zt,Df,Yg,yg,cg,ig,Vf,Jf,Wf,Yf,eg,Ic,wc,mo,go,ho,bo]),$y=C([uo,lo,Af,nh,vr]),zy=C([co,jc,Pc,Kg,rh,fo,vo,po]),ky=C([zt,Pg,Vg,th,mo,go,ho,bo]),Sy=C([uo,lo,xg,rg,Gf,vg,pg,vr,Bg]),wy=C([co,Zf,Xg,dg,ag,bc,Bf,_c,wt,gg,fo,vo,po]),U=class e extends Error{constructor(r,n,i){super(`MCP error ${r}: ${n}`),this.code=r,this.data=i,this.name="McpError"}static fromError(r,n,i){if(r===Z.UrlElicitationRequired&&i){let t=i;if(t.elicitations)return new pc(t.elicitations,n)}return new e(r,n,i)}},pc=class extends U{constructor(r,n=`URL elicitation${r.length>1?"s":""} required`){super(Z.UrlElicitationRequired,n,{elicitations:r})}get elicitations(){return this.data?.elicitations??[]}};function Te(e){return e==="completed"||e==="failed"||e==="cancelled"}var oh=Symbol("Let zodToJsonSchema decide on which parser to use");var i_=new Set("ABCDEFGHIJKLMNOPQRSTUVXYZabcdefghijklmnopqrstuvxyz0123456789");function Tc(e){let n=Ll(e)?.method;if(!n)throw new Error("Schema is missing a method literal");let i=Ml(n);if(typeof i!="string")throw new Error("Schema method literal must be a string");return i}function Oc(e,r){let n=kn(e,r);if(!n.success)throw n.error;return n.data}var lh=6e4,_o=class{constructor(r){this._options=r,this._requestMessageId=0,this._requestHandlers=new Map,this._requestHandlerAbortControllers=new Map,this._notificationHandlers=new Map,this._responseHandlers=new Map,this._progressHandlers=new Map,this._timeoutInfo=new Map,this._pendingDebouncedNotifications=new Set,this._taskProgressTokens=new Map,this._requestResolvers=new Map,this.setNotificationHandler(uo,n=>{this._oncancel(n)}),this.setNotificationHandler(lo,n=>{this._onprogress(n)}),this.setRequestHandler(zt,n=>({})),this._taskStore=r?.taskStore,this._taskMessageQueue=r?.taskMessageQueue,this._taskStore&&(this.setRequestHandler(mo,async(n,i)=>{let t=await this._taskStore.getTask(n.params.taskId,i.sessionId);if(!t)throw new U(Z.InvalidParams,"Failed to retrieve task: Task not found");return{...t}}),this.setRequestHandler(go,async(n,i)=>{let t=async()=>{let o=n.params.taskId;if(!await this._taskStore.getTask(o,i.sessionId))throw new U(Z.InvalidParams,`Task not found: ${o}`);if(this._taskMessageQueue){let c;for(;c=await this._taskMessageQueue.dequeue(o,i.sessionId);){if(c.type==="response"||c.type==="error"){let p=c.message,g=p.id,h=this._requestResolvers.get(g);if(h)if(this._requestResolvers.delete(g),c.type==="response")h(p);else{let m=p,$=new U(m.error.code,m.error.message,m.error.data);h($)}else{let m=c.type==="response"?"Response":"Error";this._onerror(new Error(`${m} handler missing for request ${g}`))}continue}await this._transport?.send(c.message,{relatedRequestId:i.requestId})}}let a=await this._taskStore.getTask(o,i.sessionId);if(!a)throw new U(Z.InvalidParams,`Task not found: ${o}`);if(!Te(a.status))return await this._waitForTaskUpdate(o,i.signal,i.sessionId),await t();if(Te(a.status)){let c=await this._taskStore.getTaskResult(o,i.sessionId);return this._clearTaskQueue(o,i.sessionId),{...c,_meta:{...c._meta,[Pe]:{taskId:o}}}}return await t()};return await t()}),this.setRequestHandler(ho,async(n,i)=>{try{let{tasks:t,nextCursor:o}=await this._taskStore.listTasks(n.params?.cursor,i.sessionId);return{tasks:t,nextCursor:o,_meta:{}}}catch(t){throw new U(Z.InvalidParams,`Failed to list tasks: ${t instanceof Error?t.message:String(t)}`)}}),this.setRequestHandler(bo,async(n,i)=>{try{let t=await this._taskStore.getTask(n.params.taskId,i.sessionId);if(!t)throw new U(Z.InvalidParams,`Task not found: ${n.params.taskId}`);if(Te(t.status))throw new U(Z.InvalidParams,`Cannot cancel task in terminal status: ${t.status}`);await this._taskStore.updateTaskStatus(n.params.taskId,"cancelled","Client cancelled task execution.",i.sessionId),this._clearTaskQueue(n.params.taskId,i.sessionId);let o=await this._taskStore.getTask(n.params.taskId,i.sessionId);if(!o)throw new U(Z.InvalidParams,`Task not found after cancellation: ${n.params.taskId}`);return{_meta:{},...o}}catch(t){throw t instanceof U?t:new U(Z.InvalidRequest,`Failed to cancel task: ${t instanceof Error?t.message:String(t)}`)}}))}async _oncancel(r){if(!r.params.requestId)return;this._requestHandlerAbortControllers.get(r.params.requestId)?.abort(r.params.reason)}_setupTimeout(r,n,i,t,o=!1){this._timeoutInfo.set(r,{timeoutId:setTimeout(t,n),startTime:Date.now(),timeout:n,maxTotalTimeout:i,resetTimeoutOnProgress:o,onTimeout:t})}_resetTimeout(r){let n=this._timeoutInfo.get(r);if(!n)return!1;let i=Date.now()-n.startTime;if(n.maxTotalTimeout&&i>=n.maxTotalTimeout)throw this._timeoutInfo.delete(r),U.fromError(Z.RequestTimeout,"Maximum total timeout exceeded",{maxTotalTimeout:n.maxTotalTimeout,totalElapsed:i});return clearTimeout(n.timeoutId),n.timeoutId=setTimeout(n.onTimeout,n.timeout),!0}_cleanupTimeout(r){let n=this._timeoutInfo.get(r);n&&(clearTimeout(n.timeoutId),this._timeoutInfo.delete(r))}async connect(r){if(this._transport)throw new Error("Already connected to a transport. Call close() before connecting to a new transport, or use a separate Protocol instance per connection.");this._transport=r;let n=this.transport?.onclose;this._transport.onclose=()=>{n?.(),this._onclose()};let i=this.transport?.onerror;this._transport.onerror=o=>{i?.(o),this._onerror(o)};let t=this._transport?.onmessage;this._transport.onmessage=(o,a)=>{t?.(o,a),dr(o)||ep(o)?this._onresponse(o):fc(o)?this._onrequest(o,a):Xd(o)?this._onnotification(o):this._onerror(new Error(`Unknown message type: ${JSON.stringify(o)}`))},await this._transport.start()}_onclose(){let r=this._responseHandlers;this._responseHandlers=new Map,this._progressHandlers.clear(),this._taskProgressTokens.clear(),this._pendingDebouncedNotifications.clear();for(let i of this._timeoutInfo.values())clearTimeout(i.timeoutId);this._timeoutInfo.clear();for(let i of this._requestHandlerAbortControllers.values())i.abort();this._requestHandlerAbortControllers.clear();let n=U.fromError(Z.ConnectionClosed,"Connection closed");this._transport=void 0,this.onclose?.();for(let i of r.values())i(n)}_onerror(r){this.onerror?.(r)}_onnotification(r){let n=this._notificationHandlers.get(r.method)??this.fallbackNotificationHandler;n!==void 0&&Promise.resolve().then(()=>n(r)).catch(i=>this._onerror(new Error(`Uncaught error in notification handler: ${i}`)))}_onrequest(r,n){let i=this._requestHandlers.get(r.method)??this.fallbackRequestHandler,t=this._transport,o=r.params?._meta?.[Pe]?.taskId,a=t?.sessionId,c=this._taskStore,p=!0,g;if(o&&c&&this._taskMessageQueue&&a!==void 0&&(p=!1,g=(async()=>{if(!await c.getTask(o,a))throw new U(Z.InvalidParams,`Task not found: ${o}`);p=!0})()),i===void 0){let l={jsonrpc:"2.0",id:r.id,error:{code:Z.MethodNotFound,message:"Method not found"}};if(o&&g){let v={type:"error",message:l,timestamp:Date.now()};g.then(()=>this._enqueueTaskMessage(o,v,a),()=>t?.send(l)).catch(k=>this._onerror(new Error(`Failed to send an error response: ${k}`)))}else o&&this._taskMessageQueue?this._enqueueTaskMessage(o,{type:"error",message:l,timestamp:Date.now()},t?.sessionId).catch(v=>this._onerror(new Error(`Failed to enqueue error response: ${v}`))):t?.send(l).catch(v=>this._onerror(new Error(`Failed to send an error response: ${v}`)));return}let h=new AbortController;this._requestHandlerAbortControllers.set(r.id,h);let m=Gd(r.params)?r.params.task:void 0,$=this._taskStore?this.requestTaskStore(r,t?.sessionId):void 0,y={signal:h.signal,sessionId:t?.sessionId,_meta:r.params?._meta,sendNotification:async l=>{if(h.signal.aborted)return;let v={relatedRequestId:r.id};o&&(v.relatedTask={taskId:o}),await this.notification(l,v)},sendRequest:async(l,v,k)=>{if(h.signal.aborted)throw new U(Z.ConnectionClosed,"Request was cancelled");let E={...k,relatedRequestId:r.id};o&&!E.relatedTask&&(E.relatedTask={taskId:o});let w=E.relatedTask?.taskId??o;return w&&$&&await $.updateTaskStatus(w,"input_required"),await this.request(l,v,E)},authInfo:n?.authInfo,requestId:r.id,requestInfo:n?.requestInfo,taskId:o,taskStore:$,taskRequestedTtl:m?.ttl,closeSSEStream:n?.closeSSEStream,closeStandaloneSSEStream:n?.closeStandaloneSSEStream};(g??Promise.resolve()).then(()=>{if(g&&h.signal.aborted)throw new U(Z.ConnectionClosed,"Request was cancelled");m&&this.assertTaskHandlerCapability(r.method)}).then(()=>i(r,y)).then(async l=>{if(h.signal.aborted)return;let v={result:l,jsonrpc:"2.0",id:r.id};o&&this._taskMessageQueue?await this._enqueueTaskMessage(o,{type:"response",message:v,timestamp:Date.now()},t?.sessionId):await t?.send(v)},async l=>{if(h.signal.aborted)return;let v={jsonrpc:"2.0",id:r.id,error:{code:Number.isSafeInteger(l.code)?l.code:Z.InternalError,message:l.message??"Internal error",...l.data!==void 0&&{data:l.data}}};o&&this._taskMessageQueue&&p?await this._enqueueTaskMessage(o,{type:"error",message:v,timestamp:Date.now()},t?.sessionId):await t?.send(v)}).catch(l=>this._onerror(new Error(`Failed to send response: ${l}`))).finally(()=>{this._requestHandlerAbortControllers.get(r.id)===h&&this._requestHandlerAbortControllers.delete(r.id)})}_onprogress(r){let{progressToken:n,...i}=r.params,t=Number(n),o=this._progressHandlers.get(t);if(!o){this._onerror(new Error(`Received a progress notification for an unknown token: ${JSON.stringify(r)}`));return}let a=this._responseHandlers.get(t),c=this._timeoutInfo.get(t);if(c&&a&&c.resetTimeoutOnProgress)try{this._resetTimeout(t)}catch(p){this._responseHandlers.delete(t),this._progressHandlers.delete(t),this._cleanupTimeout(t),a(p);return}o(i)}_onresponse(r){let n=Number(r.id),i=this._requestResolvers.get(n);if(i){if(this._requestResolvers.delete(n),dr(r))i(r);else{let a=new U(r.error.code,r.error.message,r.error.data);i(a)}return}let t=this._responseHandlers.get(n);if(t===void 0){this._onerror(new Error(`Received a response for an unknown message ID: ${JSON.stringify(r)}`));return}this._responseHandlers.delete(n),this._cleanupTimeout(n);let o=!1;if(dr(r)&&r.result&&typeof r.result=="object"){let a=r.result;if(a.task&&typeof a.task=="object"){let c=a.task;typeof c.taskId=="string"&&(o=!0,this._taskProgressTokens.set(c.taskId,n))}}if(o||this._progressHandlers.delete(n),dr(r))t(r);else{let a=U.fromError(r.error.code,r.error.message,r.error.data);t(a)}}get transport(){return this._transport}async close(){await this._transport?.close()}async*requestStream(r,n,i){let{task:t}=i??{};if(!t){try{yield{type:"result",result:await this.request(r,n,i)}}catch(a){yield{type:"error",error:a instanceof U?a:new U(Z.InternalError,String(a))}}return}let o;try{let a=await this.request(r,po,i);if(a.task)o=a.task.taskId,yield{type:"taskCreated",task:a.task};else throw new U(Z.InternalError,"Task creation did not return a task");for(;;){let c=await this.getTask({taskId:o},i);if(yield{type:"taskStatus",task:c},Te(c.status)){c.status==="completed"?yield{type:"result",result:await this.getTaskResult({taskId:o},n,i)}:c.status==="failed"?yield{type:"error",error:new U(Z.InternalError,`Task ${o} failed`)}:c.status==="cancelled"&&(yield{type:"error",error:new U(Z.InternalError,`Task ${o} was cancelled`)});return}if(c.status==="input_required"){yield{type:"result",result:await this.getTaskResult({taskId:o},n,i)};return}let p=c.pollInterval??this._options?.defaultTaskPollInterval??1e3;await new Promise(g=>setTimeout(g,p)),i?.signal?.throwIfAborted()}}catch(a){yield{type:"error",error:a instanceof U?a:new U(Z.InternalError,String(a))}}}request(r,n,i){let{relatedRequestId:t,resumptionToken:o,onresumptiontoken:a,task:c,relatedTask:p}=i??{};return new Promise((g,h)=>{let m=w=>{h(w)};if(!this._transport){m(new Error("Not connected"));return}if(this._options?.enforceStrictCapabilities===!0)try{this.assertCapabilityForMethod(r.method),c&&this.assertTaskCapability(r.method)}catch(w){m(w);return}i?.signal?.throwIfAborted();let $=this._requestMessageId++,y={...r,jsonrpc:"2.0",id:$};i?.onprogress&&(this._progressHandlers.set($,i.onprogress),y.params={...r.params,_meta:{...r.params?._meta||{},progressToken:$}}),c&&(y.params={...y.params,task:c}),p&&(y.params={...y.params,_meta:{...y.params?._meta||{},[Pe]:p}});let l=w=>{this._responseHandlers.delete($),this._progressHandlers.delete($),this._cleanupTimeout($),this._transport?.send({jsonrpc:"2.0",method:"notifications/cancelled",params:{requestId:$,reason:String(w)}},{relatedRequestId:t,resumptionToken:o,onresumptiontoken:a}).catch(D=>this._onerror(new Error(`Failed to send cancellation: ${D}`)));let j=w instanceof U?w:new U(Z.RequestTimeout,String(w));h(j)};this._responseHandlers.set($,w=>{if(!i?.signal?.aborted){if(w instanceof Error)return h(w);try{let j=kn(n,w.result);j.success?g(j.data):h(j.error)}catch(j){h(j)}}}),i?.signal?.addEventListener("abort",()=>{l(i?.signal?.reason)});let v=i?.timeout??lh,k=()=>l(U.fromError(Z.RequestTimeout,"Request timed out",{timeout:v}));this._setupTimeout($,v,i?.maxTotalTimeout,k,i?.resetTimeoutOnProgress??!1);let E=p?.taskId;if(E){let w=j=>{let D=this._responseHandlers.get($);D?D(j):this._onerror(new Error(`Response handler missing for side-channeled request ${$}`))};this._requestResolvers.set($,w),this._enqueueTaskMessage(E,{type:"request",message:y,timestamp:Date.now()}).catch(j=>{this._cleanupTimeout($),h(j)})}else this._transport.send(y,{relatedRequestId:t,resumptionToken:o,onresumptiontoken:a}).catch(w=>{this._cleanupTimeout($),h(w)})})}async getTask(r,n){return this.request({method:"tasks/get",params:r},fo,n)}async getTaskResult(r,n,i){return this.request({method:"tasks/result",params:r},n,i)}async listTasks(r,n){return this.request({method:"tasks/list",params:r},vo,n)}async cancelTask(r,n){return this.request({method:"tasks/cancel",params:r},rp,n)}async notification(r,n){if(!this._transport)throw new Error("Not connected");this.assertNotificationCapability(r.method);let i=n?.relatedTask?.taskId;if(i){let c={...r,jsonrpc:"2.0",params:{...r.params,_meta:{...r.params?._meta||{},[Pe]:n.relatedTask}}};await this._enqueueTaskMessage(i,{type:"notification",message:c,timestamp:Date.now()});return}if((this._options?.debouncedNotificationMethods??[]).includes(r.method)&&!r.params&&!n?.relatedRequestId&&!n?.relatedTask){if(this._pendingDebouncedNotifications.has(r.method))return;this._pendingDebouncedNotifications.add(r.method),Promise.resolve().then(()=>{if(this._pendingDebouncedNotifications.delete(r.method),!this._transport)return;let c={...r,jsonrpc:"2.0"};n?.relatedTask&&(c={...c,params:{...c.params,_meta:{...c.params?._meta||{},[Pe]:n.relatedTask}}}),this._transport?.send(c,n).catch(p=>this._onerror(p))});return}let a={...r,jsonrpc:"2.0"};n?.relatedTask&&(a={...a,params:{...a.params,_meta:{...a.params?._meta||{},[Pe]:n.relatedTask}}}),await this._transport.send(a,n)}setRequestHandler(r,n){let i=Tc(r);this.assertRequestHandlerCapability(i),this._requestHandlers.set(i,(t,o)=>{let a=Oc(r,t);return Promise.resolve(n(a,o))})}removeRequestHandler(r){this._requestHandlers.delete(r)}assertCanSetRequestHandler(r){if(this._requestHandlers.has(r))throw new Error(`A request handler for ${r} already exists, which would be overridden`)}setNotificationHandler(r,n){let i=Tc(r);this._notificationHandlers.set(i,t=>{let o=Oc(r,t);return Promise.resolve(n(o))})}removeNotificationHandler(r){this._notificationHandlers.delete(r)}_cleanupTaskProgressHandler(r){let n=this._taskProgressTokens.get(r);n!==void 0&&(this._progressHandlers.delete(n),this._taskProgressTokens.delete(r))}async _enqueueTaskMessage(r,n,i){if(!this._taskStore||!this._taskMessageQueue)throw new Error("Cannot enqueue task message: taskStore and taskMessageQueue are not configured");let t=this._options?.maxTaskQueueSize;await this._taskMessageQueue.enqueue(r,n,i??this._transport?.sessionId,t)}async _clearTaskQueue(r,n){if(this._taskMessageQueue){let i=await this._taskMessageQueue.dequeueAll(r,n);for(let t of i)if(t.type==="request"&&fc(t.message)){let o=t.message.id,a=this._requestResolvers.get(o);a?(a(new U(Z.InternalError,"Task cancelled or completed")),this._requestResolvers.delete(o)):this._onerror(new Error(`Resolver missing for request ${o} during task ${r} cleanup`))}}}async _waitForTaskUpdate(r,n,i){let t=this._options?.defaultTaskPollInterval??1e3;try{let o=await this._taskStore?.getTask(r,i);o?.pollInterval&&(t=o.pollInterval)}catch{}return new Promise((o,a)=>{if(n.aborted){a(new U(Z.InvalidRequest,"Request cancelled"));return}let c=setTimeout(o,t);n.addEventListener("abort",()=>{clearTimeout(c),a(new U(Z.InvalidRequest,"Request cancelled"))},{once:!0})})}requestTaskStore(r,n){let i=this._taskStore;if(!i)throw new Error("No task store configured");return{createTask:async t=>{if(!r)throw new Error("No request provided");return await i.createTask(t,r.id,{method:r.method,params:r.params},n)},getTask:async t=>{let o=await i.getTask(t,n);if(!o)throw new U(Z.InvalidParams,"Failed to retrieve task: Task not found");return o},storeTaskResult:async(t,o,a)=>{await i.storeTaskResult(t,o,a,n);let c=await i.getTask(t,n);if(c){let p=vr.parse({method:"notifications/tasks/status",params:c});await this.notification(p),Te(c.status)&&this._cleanupTaskProgressHandler(t)}},getTaskResult:t=>i.getTaskResult(t,n),updateTaskStatus:async(t,o,a)=>{let c=await i.getTask(t,n);if(!c)throw new U(Z.InvalidParams,`Task "${t}" not found - it may have been cleaned up`);if(Te(c.status))throw new U(Z.InvalidParams,`Cannot update task "${t}" from terminal status "${c.status}" to "${o}". Terminal states (completed, failed, cancelled) cannot transition to other states.`);await i.updateTaskStatus(t,o,a,n);let p=await i.getTask(t,n);if(p){let g=vr.parse({method:"notifications/tasks/status",params:p});await this.notification(g),Te(p.status)&&this._cleanupTaskProgressHandler(t)}},listTasks:t=>i.listTasks(t,n)}}};function cp(e){return e!==null&&typeof e=="object"&&!Array.isArray(e)}function up(e,r){let n={...e};for(let i in r){let t=i,o=r[t];if(o===void 0)continue;let a=n[t];cp(a)&&cp(o)?n[t]={...a,...o}:n[t]=o}return n}ur();ur();var nz=(e=>typeof Ne<"u"?Ne:typeof Proxy<"u"?new Proxy(e,{get:(r,n)=>(typeof Ne<"u"?Ne:r)[n]}):e)(function(e){if(typeof Ne<"u")return Ne.apply(this,arguments);throw Error(\'Dynamic require of "\'+e+\'" is not supported\')}),Nc=class extends _o{_registeredMethods=new Set;_eventSlots=new Map;onEventDispatch(r,n){}_ensureEventSlot(r){let n=this._eventSlots.get(r);if(!n){let i=this.eventSchemas[r];if(!i)throw Error(`Unknown event: ${String(r)}`);n={listeners:[]},this._eventSlots.set(r,n);let t=i.shape.method.value;this._registeredMethods.add(t);let o=n;super.setNotificationHandler(i,a=>{let c=a.params;this.onEventDispatch(r,c),o.onHandler?.(c);for(let p of[...o.listeners])p(c)})}return n}setEventHandler(r,n){let i=this._ensureEventSlot(r);i.onHandler&&n&&console.warn(`[MCP Apps] on${String(r)} handler replaced. Use addEventListener("${String(r)}", \\u2026) to add multiple listeners without replacing.`),i.onHandler=n}getEventHandler(r){return this._eventSlots.get(r)?.onHandler}addEventListener(r,n){this._ensureEventSlot(r).listeners.push(n)}removeEventListener(r,n){let i=this._eventSlots.get(r);if(!i)return;let t=i.listeners.indexOf(n);t!==-1&&i.listeners.splice(t,1)}setRequestHandler=(r,n)=>{this._assertMethodNotRegistered(r,"setRequestHandler"),super.setRequestHandler(r,n)};setNotificationHandler=(r,n)=>{this._assertMethodNotRegistered(r,"setNotificationHandler"),super.setNotificationHandler(r,n)};warnIfRequestHandlerReplaced(r,n,i){n&&i&&console.warn(`[MCP Apps] ${r} handler replaced. Previous handler will no longer be called.`)}replaceRequestHandler=(r,n)=>{let i=r.shape.method.value;this._registeredMethods.add(i),super.setRequestHandler(r,n)};_assertMethodNotRegistered(r,n){let i=r.shape.method.value;if(this._registeredMethods.has(i))throw Error(`Handler for "${i}" already registered (via ${n}). Use addEventListener() to attach multiple listeners, or the on* setter for replace semantics.`);this._registeredMethods.add(i)}},dh="2026-01-26";var ph="ui/notifications/tool-input-partial";var Uc=class{eventTarget;eventSource;messageListener;constructor(r=window.parent,n){this.eventTarget=r,this.eventSource=n,this.messageListener=i=>{if(n&&i.source!==this.eventSource){console.debug("Ignoring message from unknown source",i);return}let t=tp.safeParse(i.data);t.success?(console.debug("Parsed message",t.data),this.onmessage?.(t.data)):i.data?.jsonrpc!=="2.0"?console.debug("Ignoring non-JSON-RPC message",t.error.message,i):(console.error("Failed to parse message",t.error.message,i),this.onerror?.(Error("Invalid JSON-RPC message received: "+t.error.message)))}}async start(){window.addEventListener("message",this.messageListener)}async send(r,n){r.method!==ph&&console.debug("Sending message",r),this.eventTarget.postMessage(r,"*")}async close(){window.removeEventListener("message",this.messageListener),this.onclose?.()}onclose;onerror;onmessage;sessionId;setProtocolVersion},mh=s.union([s.literal("light"),s.literal("dark")]).describe("Color theme preference for the host environment."),_r=s.union([s.literal("inline"),s.literal("fullscreen"),s.literal("pip")]).describe("Display mode for UI presentation."),fh=s.union([s.literal("--color-background-primary"),s.literal("--color-background-secondary"),s.literal("--color-background-tertiary"),s.literal("--color-background-inverse"),s.literal("--color-background-ghost"),s.literal("--color-background-info"),s.literal("--color-background-danger"),s.literal("--color-background-success"),s.literal("--color-background-warning"),s.literal("--color-background-disabled"),s.literal("--color-text-primary"),s.literal("--color-text-secondary"),s.literal("--color-text-tertiary"),s.literal("--color-text-inverse"),s.literal("--color-text-ghost"),s.literal("--color-text-info"),s.literal("--color-text-danger"),s.literal("--color-text-success"),s.literal("--color-text-warning"),s.literal("--color-text-disabled"),s.literal("--color-border-primary"),s.literal("--color-border-secondary"),s.literal("--color-border-tertiary"),s.literal("--color-border-inverse"),s.literal("--color-border-ghost"),s.literal("--color-border-info"),s.literal("--color-border-danger"),s.literal("--color-border-success"),s.literal("--color-border-warning"),s.literal("--color-border-disabled"),s.literal("--color-ring-primary"),s.literal("--color-ring-secondary"),s.literal("--color-ring-inverse"),s.literal("--color-ring-info"),s.literal("--color-ring-danger"),s.literal("--color-ring-success"),s.literal("--color-ring-warning"),s.literal("--font-sans"),s.literal("--font-mono"),s.literal("--font-weight-normal"),s.literal("--font-weight-medium"),s.literal("--font-weight-semibold"),s.literal("--font-weight-bold"),s.literal("--font-text-xs-size"),s.literal("--font-text-sm-size"),s.literal("--font-text-md-size"),s.literal("--font-text-lg-size"),s.literal("--font-heading-xs-size"),s.literal("--font-heading-sm-size"),s.literal("--font-heading-md-size"),s.literal("--font-heading-lg-size"),s.literal("--font-heading-xl-size"),s.literal("--font-heading-2xl-size"),s.literal("--font-heading-3xl-size"),s.literal("--font-text-xs-line-height"),s.literal("--font-text-sm-line-height"),s.literal("--font-text-md-line-height"),s.literal("--font-text-lg-line-height"),s.literal("--font-heading-xs-line-height"),s.literal("--font-heading-sm-line-height"),s.literal("--font-heading-md-line-height"),s.literal("--font-heading-lg-line-height"),s.literal("--font-heading-xl-line-height"),s.literal("--font-heading-2xl-line-height"),s.literal("--font-heading-3xl-line-height"),s.literal("--border-radius-xs"),s.literal("--border-radius-sm"),s.literal("--border-radius-md"),s.literal("--border-radius-lg"),s.literal("--border-radius-xl"),s.literal("--border-radius-full"),s.literal("--border-width-regular"),s.literal("--shadow-hairline"),s.literal("--shadow-sm"),s.literal("--shadow-md"),s.literal("--shadow-lg")]).describe("CSS variable keys available to MCP apps for theming."),gh=s.record(fh.describe(`Style variables for theming MCP apps.\n\nIndividual style keys are optional - hosts may provide any subset of these values.\nValues are strings containing CSS values (colors, sizes, font stacks, etc.).\n\nNote: This type uses \\`Record<K, string | undefined>\\` rather than \\`Partial<Record<K, string>>\\`\nfor compatibility with Zod schema generation. Both are functionally equivalent for validation.`),s.union([s.string(),s.undefined()]).describe(`Style variables for theming MCP apps.\n\nIndividual style keys are optional - hosts may provide any subset of these values.\nValues are strings containing CSS values (colors, sizes, font stacks, etc.).\n\nNote: This type uses \\`Record<K, string | undefined>\\` rather than \\`Partial<Record<K, string>>\\`\nfor compatibility with Zod schema generation. Both are functionally equivalent for validation.`)).describe(`Style variables for theming MCP apps.\n\nIndividual style keys are optional - hosts may provide any subset of these values.\nValues are strings containing CSS values (colors, sizes, font stacks, etc.).\n\nNote: This type uses \\`Record<K, string | undefined>\\` rather than \\`Partial<Record<K, string>>\\`\nfor compatibility with Zod schema generation. Both are functionally equivalent for validation.`),lz=s.object({method:s.literal("ui/open-link"),params:s.object({url:s.string().describe("URL to open in the host\'s browser")})}),hh=s.object({isError:s.boolean().optional().describe("True if the host failed to open the URL (e.g., due to security policy).")}).passthrough(),vh=s.object({isError:s.boolean().optional().describe("True if the download failed (e.g., user cancelled or host denied).")}).passthrough(),bh=s.object({isError:s.boolean().optional().describe("True if the host rejected or failed to deliver the message.")}).passthrough(),dz=s.object({method:s.literal("ui/notifications/sandbox-proxy-ready"),params:s.object({})}),Ec=s.object({connectDomains:s.array(s.string()).optional().describe(`Origins for network requests (fetch/XHR/WebSocket).\n\n- Maps to CSP \\`connect-src\\` directive\n- Empty or omitted \\u2192 no network connections (secure default)`),resourceDomains:s.array(s.string()).optional().describe("Origins for static resources (images, scripts, stylesheets, fonts, media).\\n\\n- Maps to CSP `img-src`, `script-src`, `style-src`, `font-src`, `media-src` directives\\n- Wildcard subdomains supported: `https://*.example.com`\\n- Empty or omitted \\u2192 no network resources (secure default)"),frameDomains:s.array(s.string()).optional().describe("Origins for nested iframes.\\n\\n- Maps to CSP `frame-src` directive\\n- Empty or omitted \\u2192 no nested iframes allowed (`frame-src \'none\'`)"),baseUriDomains:s.array(s.string()).optional().describe("Allowed base URIs for the document.\\n\\n- Maps to CSP `base-uri` directive\\n- Empty or omitted \\u2192 only same origin allowed (`base-uri \'self\'`)")}),Dc=s.object({camera:s.object({}).optional().describe("Request camera access.\\n\\nMaps to Permission Policy `camera` feature."),microphone:s.object({}).optional().describe("Request microphone access.\\n\\nMaps to Permission Policy `microphone` feature."),geolocation:s.object({}).optional().describe("Request geolocation access.\\n\\nMaps to Permission Policy `geolocation` feature."),clipboardWrite:s.object({}).optional().describe("Request clipboard write access.\\n\\nMaps to Permission Policy `clipboard-write` feature.")}),pz=s.object({method:s.literal("ui/notifications/size-changed"),params:s.object({width:s.number().optional().describe("New width in pixels."),height:s.number().optional().describe("New height in pixels.")})}),yh=s.object({method:s.literal("ui/notifications/tool-input"),params:s.object({arguments:s.record(s.string(),s.unknown().describe("Complete tool call arguments as key-value pairs.")).optional().describe("Complete tool call arguments as key-value pairs.")})}),_h=s.object({method:s.literal("ui/notifications/tool-input-partial"),params:s.object({arguments:s.record(s.string(),s.unknown().describe("Partial tool call arguments (incomplete, may change).")).optional().describe("Partial tool call arguments (incomplete, may change).")})}),xh=s.object({method:s.literal("ui/notifications/tool-cancelled"),params:s.object({reason:s.string().optional().describe(\'Optional reason for the cancellation (e.g., "user action", "timeout").\')})}),$h=s.object({fonts:s.string().optional()}),zh=s.object({variables:gh.optional().describe("CSS variables for theming the app."),css:$h.optional().describe("CSS blocks that apps can inject.")}),kh=s.object({method:s.literal("ui/resource-teardown"),params:s.object({})}),mz=s.record(s.string(),s.unknown()),lp=s.object({text:s.object({}).optional().describe("Host supports text content blocks."),image:s.object({}).optional().describe("Host supports image content blocks."),audio:s.object({}).optional().describe("Host supports audio content blocks."),resource:s.object({}).optional().describe("Host supports resource content blocks."),resourceLink:s.object({}).optional().describe("Host supports resource link content blocks."),structuredContent:s.object({}).optional().describe("Host supports structured content.")}),fz=s.object({method:s.literal("ui/notifications/request-teardown"),params:s.object({}).optional()}),Sh=s.object({experimental:s.record(s.string(),s.record(s.string(),s.any()).describe("Experimental features keyed by identifier.")).optional().describe("Experimental features keyed by identifier."),openLinks:s.object({}).optional().describe("Host supports opening external URLs."),downloadFile:s.object({}).optional().describe("Host supports file downloads via ui/download-file."),serverTools:s.object({listChanged:s.boolean().optional().describe("Host supports tools/list_changed notifications.")}).optional().describe("Host can proxy tool calls to the MCP server."),serverResources:s.object({listChanged:s.boolean().optional().describe("Host supports resources/list_changed notifications.")}).optional().describe("Host can proxy resource reads to the MCP server."),logging:s.object({}).optional().describe("Host accepts log messages."),sandbox:s.object({permissions:Dc.optional().describe("Permissions granted by the host (camera, microphone, geolocation)."),csp:Ec.optional().describe("CSP domains approved by the host.")}).optional().describe("Sandbox configuration applied by the host."),updateModelContext:lp.optional().describe("Host accepts context updates (ui/update-model-context) to be included in the model\'s context for future turns."),message:lp.optional().describe("Host supports receiving content messages (ui/message) from the view."),sampling:s.object({tools:s.object({}).optional().describe("Host supports tool use via `tools` and `toolChoice` parameters.")}).optional().describe("Host supports LLM sampling (sampling/createMessage) from the view.\\nMirrors the MCP `ClientCapabilities.sampling` shape so hosts can pass it through.")}),wh=s.object({experimental:s.record(s.string(),s.record(s.string(),s.any()).describe("Experimental features keyed by identifier.")).optional().describe("Experimental features keyed by identifier."),tools:s.object({listChanged:s.boolean().optional().describe("App supports tools/list_changed notifications.")}).optional().describe("App exposes MCP-style tools that the host can call."),availableDisplayModes:s.array(_r).optional().describe("Display modes the app supports.")}),gz=s.object({method:s.literal("ui/notifications/initialized"),params:s.object({}).optional()}),hz=s.object({csp:Ec.optional().describe("Content Security Policy configuration for UI resources."),permissions:Dc.optional().describe("Sandbox permissions requested by the UI resource."),domain:s.string().optional().describe(`Dedicated origin for view sandbox.\n\nUseful when views need stable, dedicated origins for OAuth callbacks, CORS policies, or API key allowlists.\n\n**Host-dependent:** The format and validation rules for this field are determined by each host. Servers MUST consult host-specific documentation for the expected domain format. Common patterns include:\n- Hash-based subdomains (e.g., \\`{hash}.claudemcpcontent.com\\`)\n- URL-derived subdomains (e.g., \\`www-example-com.oaiusercontent.com\\`)\n\nIf omitted, host uses default sandbox origin (typically per-conversation).`),prefersBorder:s.boolean().optional().describe(`Visual boundary preference - true if view prefers a visible border.\n\nBoolean requesting whether a visible border and background is provided by the host. Specifying an explicit value for this is recommended because hosts\' defaults may vary.\n\n- \\`true\\`: request visible border + background\n- \\`false\\`: request no visible border + background\n- omitted: host decides border`)}),vz=s.object({method:s.literal("ui/request-display-mode"),params:s.object({mode:_r.describe("The display mode being requested.")})}),Ih=s.object({mode:_r.describe("The display mode that was actually set. May differ from requested if not supported.")}).passthrough(),jh=s.union([s.literal("model"),s.literal("app")]).describe("Tool visibility scope - who can access the tool."),bz=s.object({resourceUri:s.string().optional(),visibility:s.array(jh).optional().describe(`Who can access this tool. Default: ["model", "app"]\n- "model": Tool visible to and callable by the agent\n- "app": Tool callable by the app from this server only`),csp:s.never().optional(),permissions:s.never().optional()}),yz=s.object({mimeTypes:s.array(s.string()).optional().describe(\'Array of supported MIME types for UI resources.\\nMust include `"text/html;profile=mcp-app"` for MCP Apps support.\')}),_z=s.object({method:s.literal("ui/download-file"),params:s.object({contents:s.array(s.union([kc,Sc])).describe("Resource contents to download \\u2014 embedded (inline data) or linked (host fetches). Uses standard MCP resource types.")})}),xz=s.object({method:s.literal("ui/message"),params:s.object({role:s.literal("user").describe(\'Message role, currently only "user" is supported.\'),content:s.array(St).describe("Message content blocks (text, image, etc.).")})}),$z=s.object({method:s.literal("ui/notifications/sandbox-resource-ready"),params:s.object({html:s.string().describe("HTML content to load into the inner iframe."),sandbox:s.string().optional().describe("Optional override for the inner iframe\'s sandbox attribute."),csp:Ec.optional().describe("CSP configuration from resource metadata."),permissions:Dc.optional().describe("Sandbox permissions from resource metadata.")})}),Ph=s.object({method:s.literal("ui/notifications/tool-result"),params:wt.describe("Standard MCP tool execution result.")}),mp=s.object({toolInfo:s.object({id:$t.optional().describe("JSON-RPC id of the tools/call request."),tool:yo.describe("Tool definition including name, inputSchema, etc.")}).optional().describe("Metadata of the tool call that instantiated this App."),theme:mh.optional().describe("Current color theme preference."),styles:zh.optional().describe("Style configuration for theming the app."),displayMode:_r.optional().describe("How the UI is currently displayed."),availableDisplayModes:s.array(_r).optional().describe("Display modes the host supports."),containerDimensions:s.union([s.object({height:s.number().describe("Fixed container height in pixels.")}),s.object({maxHeight:s.union([s.number(),s.undefined()]).optional().describe("Maximum container height in pixels.")})]).and(s.union([s.object({width:s.number().describe("Fixed container width in pixels.")}),s.object({maxWidth:s.union([s.number(),s.undefined()]).optional().describe("Maximum container width in pixels.")})])).optional().describe(`Container dimensions. Represents the dimensions of the iframe or other\ncontainer holding the app. Specify either width or maxWidth, and either height or maxHeight.`),locale:s.string().optional().describe("User\'s language and region preference in BCP 47 format."),timeZone:s.string().optional().describe("User\'s timezone in IANA format."),userAgent:s.string().optional().describe("Host application identifier."),platform:s.union([s.literal("web"),s.literal("desktop"),s.literal("mobile")]).optional().describe("Platform type for responsive design decisions."),deviceCapabilities:s.object({touch:s.boolean().optional().describe("Whether the device supports touch input."),hover:s.boolean().optional().describe("Whether the device supports hover interactions.")}).optional().describe("Device input capabilities."),safeAreaInsets:s.object({top:s.number().describe("Top safe area inset in pixels."),right:s.number().describe("Right safe area inset in pixels."),bottom:s.number().describe("Bottom safe area inset in pixels."),left:s.number().describe("Left safe area inset in pixels.")}).optional().describe("Mobile safe area boundaries in pixels.")}).passthrough(),Th=s.object({method:s.literal("ui/notifications/host-context-changed"),params:mp.describe("Partial context update containing only changed fields.")}),zz=s.object({method:s.literal("ui/update-model-context"),params:s.object({content:s.array(St).optional().describe("Context content blocks (text, image, etc.)."),structuredContent:s.record(s.string(),s.unknown().describe("Structured content for machine-readable context data.")).optional().describe("Structured content for machine-readable context data.")})}),kz=s.object({method:s.literal("ui/initialize"),params:s.object({appInfo:mr.describe("App identification (name and version)."),appCapabilities:wh.describe("Features and capabilities this app provides."),protocolVersion:s.string().describe("Protocol version this app supports.")})}),Oh=s.object({protocolVersion:s.string().describe(\'Negotiated protocol version string (e.g., "2025-11-21").\'),hostInfo:mr.describe("Host application identification and version."),hostCapabilities:Sh.describe("Features and capabilities provided by the host."),hostContext:mp.describe("Rich context about the host environment.")}).passthrough(),Nh={target:"draft-2020-12"};async function dp(e,r){let n=e["~standard"];if(n.jsonSchema)return n.jsonSchema[r](Nh);if(n.vendor==="zod"){let{z:i}=await Promise.resolve().then(()=>(ur(),dc));return i.toJSONSchema(e,{io:r})}throw Error(`Schema (vendor: ${n.vendor}) does not implement Standard JSON Schema (~standard.jsonSchema). Use a library that does (zod v4, ArkType, Valibot) or wrap your schema accordingly.`)}async function pp(e,r,n=""){let i=await e["~standard"].validate(r);if(i.issues){let t=i.issues.map(o=>{let a=o.path?.map(c=>typeof c=="object"?c.key:c).join(".");return a?`${a}: ${o.message}`:o.message}).join("; ");throw Error(n+t)}return i.value}function Rc(e){let r=document.documentElement;r.setAttribute("data-theme",e),r.style.colorScheme=e}var xo=class e extends Nc{_appInfo;_capabilities;options;_hostCapabilities;_hostInfo;_hostContext;_registeredTools={};_initializedSent=!1;_assertInitialized(r){if(this._initializedSent)return;let n=`[ext-apps] App.${r}() called before connect() completed the ui/initialize handshake. Await app.connect() before calling this method, or move data loading to an ontoolresult handler.`;if(this.options?.strict)throw Error(n);console.warn(`${n}. This will throw in a future release.`)}eventSchemas={toolinput:yh,toolinputpartial:_h,toolresult:Ph,toolcancelled:xh,hostcontextchanged:Th};static ONE_SHOT_EVENTS=new Set(["toolinput","toolinputpartial","toolresult","toolcancelled"]);_everHadListener=new Set;_assertHandlerTiming(r){if(!e.ONE_SHOT_EVENTS.has(r)||this._everHadListener.has(r)||(this._everHadListener.add(r),!this._initializedSent))return;let n=`[ext-apps] "${String(r)}" handler registered after connect() completed the ui/initialize handshake. The host may have already sent this notification. Register handlers before calling app.connect().`;if(this.options?.strict)throw Error(n);console.warn(n)}setEventHandler(r,n){n&&this._assertHandlerTiming(r),super.setEventHandler(r,n)}addEventListener(r,n){this._assertHandlerTiming(r),super.addEventListener(r,n)}onEventDispatch(r,n){r==="hostcontextchanged"&&(this._hostContext={...this._hostContext,...n})}constructor(r,n={},i={autoResize:!0}){super(i),this._appInfo=r,this._capabilities=n,this.options=i,i.allowUnsafeEval||s.config({jitless:!0}),this.setRequestHandler(zt,t=>(console.log("Received ping:",t.params),{})),this.setEventHandler("hostcontextchanged",void 0)}registerCapabilities(r){if(this.transport)throw Error("Cannot register capabilities after transport is established");this._capabilities=up(this._capabilities,r)}registerTool(r,n,i){if(this._registeredTools[r])throw Error(`Tool ${r} is already registered`);let t=this,o=()=>{t._initializedSent&&t._capabilities.tools?.listChanged&&t.sendToolListChanged()},a=n.inputSchema!==void 0,c={title:n.title,description:n.description,inputSchema:n.inputSchema,outputSchema:n.outputSchema,annotations:n.annotations,_meta:n._meta,enabled:!0,enable(){this.enabled=!0,o()},disable(){this.enabled=!1,o()},update(p){Object.assign(this,p),o()},remove(){t._registeredTools[r]===c&&(delete t._registeredTools[r],o())},handler:async(p,g)=>{if(!c.enabled)throw Error(`Tool ${r} is disabled`);let h;if(a){let m=c.inputSchema,$=m?await pp(m,p??{},`Invalid input for tool ${r}: `):p??{};h=await i($,g)}else h=await i(g);return c.outputSchema&&!h.isError&&(h.structuredContent=await pp(c.outputSchema,h.structuredContent,`Invalid output for tool ${r}: `)),h}};return this._registeredTools[r]=c,!this._capabilities.tools&&!this.transport&&this.registerCapabilities({tools:{listChanged:!0}}),this.ensureToolHandlersInitialized(),o(),c}_toolHandlersInitialized=!1;ensureToolHandlersInitialized(){this._toolHandlersInitialized||(this._toolHandlersInitialized=!0,this.oncalltool=async(r,n)=>{let i=this._registeredTools[r.name];if(!i)throw Error(`Tool ${r.name} not found`);return i.handler(r.arguments,n)},this.onlisttools=async(r,n)=>({tools:await Promise.all(Object.entries(this._registeredTools).filter(([i,t])=>t.enabled).map(async([i,t])=>{let o={name:i,title:t.title,description:t.description,inputSchema:t.inputSchema?await dp(t.inputSchema,"input"):{type:"object",properties:{}}};return t.outputSchema&&(o.outputSchema=await dp(t.outputSchema,"output")),t.annotations&&(o.annotations=t.annotations),t._meta&&(o._meta=t._meta),o}))}))}async sendToolListChanged(r={}){this._assertInitialized("sendToolListChanged"),await this.notification({method:"notifications/tools/list_changed",params:r})}getHostCapabilities(){return this._hostCapabilities}getHostVersion(){return this._hostInfo}getHostContext(){return this._hostContext}get ontoolinput(){return this.getEventHandler("toolinput")}set ontoolinput(r){this.setEventHandler("toolinput",r)}get ontoolinputpartial(){return this.getEventHandler("toolinputpartial")}set ontoolinputpartial(r){this.setEventHandler("toolinputpartial",r)}get ontoolresult(){return this.getEventHandler("toolresult")}set ontoolresult(r){this.setEventHandler("toolresult",r)}get ontoolcancelled(){return this.getEventHandler("toolcancelled")}set ontoolcancelled(r){this.setEventHandler("toolcancelled",r)}get onhostcontextchanged(){return this.getEventHandler("hostcontextchanged")}set onhostcontextchanged(r){this.setEventHandler("hostcontextchanged",r)}_onteardown;get onteardown(){return this._onteardown}set onteardown(r){this.warnIfRequestHandlerReplaced("onteardown",this._onteardown,r),this._onteardown=r,this.replaceRequestHandler(kh,(n,i)=>{if(!this._onteardown)throw Error("No onteardown handler set");return this._onteardown(n.params,i)})}_oncalltool;get oncalltool(){return this._oncalltool}set oncalltool(r){this.warnIfRequestHandlerReplaced("oncalltool",this._oncalltool,r),this._oncalltool=r,this.replaceRequestHandler(Ic,(n,i)=>{if(!this._oncalltool)throw Error("No oncalltool handler set");return this._oncalltool(n.params,i)})}_onlisttools;get onlisttools(){return this._onlisttools}set onlisttools(r){this.warnIfRequestHandlerReplaced("onlisttools",this._onlisttools,r),this._onlisttools=r,this.replaceRequestHandler(wc,(n,i)=>{if(!this._onlisttools)throw Error("No onlisttools handler set");return this._onlisttools(n.params,i)})}assertCapabilityForMethod(r){switch(r){case"sampling/createMessage":if(!this._hostCapabilities?.sampling)throw Error(`Host does not support sampling (required for ${r})`);break}}assertRequestHandlerCapability(r){switch(r){case"tools/call":case"tools/list":if(!this._capabilities.tools)throw Error(`Client does not support tool capability (required for ${r})`);return;case"ping":case"ui/resource-teardown":return;default:throw Error(`No handler for method ${r} registered`)}}assertNotificationCapability(r){}assertTaskCapability(r){throw Error("Tasks are not supported in MCP Apps")}assertTaskHandlerCapability(r){throw Error("Task handlers are not supported in MCP Apps")}async callServerTool(r,n){if(this._assertInitialized("callServerTool"),typeof r=="string")throw Error(`callServerTool() expects an object as its first argument, but received a string ("${r}"). Did you mean: callServerTool({ name: "${r}", arguments: { ... } })?`);return await this.request({method:"tools/call",params:r},wt,{onprogress:()=>{},resetTimeoutOnProgress:!0,...n})}async readServerResource(r,n){return this._assertInitialized("readServerResource"),await this.request({method:"resources/read",params:r},_c,n)}async listServerResources(r,n){return this._assertInitialized("listServerResources"),await this.request({method:"resources/list",params:r},bc,n)}async createSamplingMessage(r,n){this._assertInitialized("createSamplingMessage");let i=r.tools?Pc:jc;return await this.request({method:"sampling/createMessage",params:r},i,n)}sendMessage(r,n){return this._assertInitialized("sendMessage"),this.request({method:"ui/message",params:r},bh,n)}sendLog(r){return this.notification({method:"notifications/message",params:r})}updateModelContext(r,n){return this._assertInitialized("updateModelContext"),this.request({method:"ui/update-model-context",params:r},co,n)}openLink(r,n){return this._assertInitialized("openLink"),this.request({method:"ui/open-link",params:r},hh,n)}sendOpenLink=this.openLink;downloadFile(r,n){return this._assertInitialized("downloadFile"),this.request({method:"ui/download-file",params:r},vh,n)}requestTeardown(r={}){return this.notification({method:"ui/notifications/request-teardown",params:r})}requestDisplayMode(r,n){return this._assertInitialized("requestDisplayMode"),this.request({method:"ui/request-display-mode",params:r},Ih,n)}sendSizeChanged(r){return this.notification({method:"ui/notifications/size-changed",params:r})}setupSizeChangedNotifications(){let r=!1,n=0,i=0,t=()=>{r||(r=!0,requestAnimationFrame(()=>{r=!1;let a=document.documentElement,c=a.style.height;a.style.height="max-content";let p=Math.ceil(a.getBoundingClientRect().height);a.style.height=c;let g=Math.ceil(window.innerWidth);(g!==n||p!==i)&&(n=g,i=p,this.sendSizeChanged({width:g,height:p}))}))};t();let o=new ResizeObserver(t);return o.observe(document.documentElement),o.observe(document.body),()=>o.disconnect()}async connect(r=new Uc(window.parent,window.parent),n){if(this.transport)throw Error("App is already connected. Call close() before connecting again.");this._initializedSent=!1,await super.connect(r);try{let i=await this.request({method:"ui/initialize",params:{appCapabilities:this._capabilities,appInfo:this._appInfo,protocolVersion:dh}},Oh,n);if(i===void 0)throw Error(`Server sent invalid initialize result: ${i}`);this._hostCapabilities=i.hostCapabilities,this._hostInfo=i.hostInfo,this._hostContext=i.hostContext,await this.notification({method:"ui/notifications/initialized"}),this._initializedSent=!0,this.options?.autoResize&&this.setupSizeChangedNotifications()}catch(i){throw this.close(),i}}};function Uh(e){return e>=3?null:5e3*e}async function Zc(e,r,n){let i=0;for(;r();)try{await e(),i=0}catch{i+=1;let t=Uh(i);if(t===null)return"gave-up";await n(t)}return"stopped"}function $o(e){return(e.content??[]).map(r=>r.text??"").join(`\n`).trim()}var Eh=30*6e4,Dh=new Set(["trial","run","publication"]),Rh=new Set(["pending_approval","pending_publication","draft_changed"]),Ac=e=>typeof e=="object"&&e!==null&&!Array.isArray(e)?e:null;function Zh(e){let r=Ac(e);return r!==null&&typeof r.kind=="string"&&Dh.has(r.kind)&&typeof r.missionId=="string"&&typeof r.status=="string"&&typeof r.versionNumber=="number"&&typeof r.envelopeRef=="string"&&typeof r.currency=="string"}function Cc(e){let r=Ac(e)?.card;return Zh(r)?r:null}function fp(e){let r=Ac(e)?.state;return typeof r=="string"?r:null}function zo(e){return e!==null&&Rh.has(e.status)}function gp(e,r){return r-e>=Eh}function hp(e){return e?"empty":"loading"}function vp(e){return e.runId?{runId:e.runId,known:e.status}:{missionId:e.missionId,versionNumber:e.versionNumber,digest:e.digest,known:e.status}}function Lc(e,r){return e||r||void 0}var Ah={headings:{trial:"Trial request",run:"Run request",publication:"Mission publication"},badges:{pending_approval:"Pending approval",active:"Approved",declined:"Declined",abandoned:"Withdrawn",completed:"Completed",cancelled:"Cancelled",expired:"Expired",pending_publication:"Ready to publish",draft_changed:"Draft changed",published:"Published",discarded:"Draft discarded"},notes:{active:"The agent can pay inside this run.",declined:"The agent will not run it.",abandoned:"The request is withdrawn.",cancelled:"An operator cancelled the run.",expired:"The request expired before a decision.",draft_changed:"The draft changed since this card: what you publish is the draft as it is now.",published:"The mission is published: the wallets it is shared with can run it.",discarded:"The draft was discarded without being published."},validate:"Validate in Keyban",publish:"Publish in Keyban",note:"The agent can neither validate nor publish for you: it is done in your own Keyban session.",noLink:"Do it from the Keyban dashboard.",units:(e,r,n)=>`${e} ${r??"units"} \\xD7 ${n}`,perUnit:(e,r)=>`${e} per ${r??"unit"}`,onDemand:"Each run waits for an operator",auto:"Runs start without approval",frequency:(e,r)=>`Runs start without approval, ${e===1?"once":`${e} times`} a ${r}`,sharing:{wallet:"Shared with this wallet only",application:"Shared with the wallets of this application",organization:"Shared with the whole organization"},totalBudget:e=>`Total budget ${e}`,expires:e=>`expires ${e}`,overrides:e=>`${e} ${e===1?"override":"overrides"} of the CFO\'s rules`,watchFailed:"Live updates stopped: the state shown may be out of date.",watchStopped:"The card stopped following this request: open it in Keyban to see where it stands."},Ch={day:"jour",week:"semaine",month:"mois"},Lh={headings:{trial:"Demande d\'essai",run:"Demande d\'ex\\xE9cution",publication:"Publication de mission"},badges:{pending_approval:"En attente de validation",active:"Valid\\xE9e",declined:"Refus\\xE9e",abandoned:"Retir\\xE9e",completed:"Termin\\xE9e",cancelled:"Annul\\xE9e",expired:"Expir\\xE9e",pending_publication:"Pr\\xEAte \\xE0 publier",draft_changed:"Brouillon modifi\\xE9",published:"Publi\\xE9e",discarded:"Brouillon abandonn\\xE9"},notes:{active:"L\'agent peut payer dans cette ex\\xE9cution.",declined:"L\'agent ne la lancera pas.",abandoned:"La demande est retir\\xE9e.",cancelled:"Un op\\xE9rateur a annul\\xE9 l\'ex\\xE9cution.",expired:"La demande a expir\\xE9 avant une d\\xE9cision.",draft_changed:"Le brouillon a chang\\xE9 depuis cette carte : vous publiez le brouillon tel qu\'il est maintenant.",published:"La mission est publi\\xE9e : les wallets avec qui elle est partag\\xE9e peuvent la lancer.",discarded:"Le brouillon a \\xE9t\\xE9 abandonn\\xE9 sans \\xEAtre publi\\xE9."},validate:"Valider dans Keyban",publish:"Publier dans Keyban",note:"L\'agent ne peut ni valider ni publier \\xE0 votre place : cela se fait dans votre session Keyban.",noLink:"Faites-le depuis le tableau de bord Keyban.",units:(e,r,n)=>`${e} ${r??"unit\\xE9s"} \\xD7 ${n}`,perUnit:(e,r)=>`${e} par ${r??"unit\\xE9"}`,onDemand:"Chaque ex\\xE9cution attend un op\\xE9rateur",auto:"Les ex\\xE9cutions d\\xE9marrent sans validation",frequency:(e,r)=>`Les ex\\xE9cutions d\\xE9marrent sans validation, ${e===1?"une fois":`${e} fois`} par ${Ch[r]}`,sharing:{wallet:"Partag\\xE9e avec ce wallet seulement",application:"Partag\\xE9e avec les wallets de cette application",organization:"Partag\\xE9e avec toute l\'organisation"},totalBudget:e=>`Budget total ${e}`,expires:e=>`expire le ${e}`,overrides:e=>`${e} ${e===1?"d\\xE9rogation":"d\\xE9rogations"} aux r\\xE8gles du CFO`,watchFailed:"Le suivi en direct s\'est interrompu : l\'\\xE9tat affich\\xE9 peut dater.",watchStopped:"La carte ne suit plus cette demande : ouvrez-la dans Keyban pour voir o\\xF9 elle en est."};function ko(e){return e?.toLowerCase().startsWith("fr")?Lh:Ah}var Mh={pending_approval:{tone:"waiting",icon:"clock",final:!1},pending_publication:{tone:"waiting",icon:"clock",final:!1},draft_changed:{tone:"waiting",icon:"triangle-alert",final:!1},active:{tone:"success",icon:"circle-check",final:!0},published:{tone:"success",icon:"circle-check",final:!0},completed:{tone:"neutral",icon:"circle-check",final:!0},declined:{tone:"danger",icon:"circle-x",final:!0},abandoned:{tone:"neutral",icon:"ban",final:!0},cancelled:{tone:"neutral",icon:"ban",final:!0},expired:{tone:"neutral",icon:"ban",final:!0},discarded:{tone:"neutral",icon:"ban",final:!0}};function bp(e,r){return{...Mh[e]??{tone:"neutral",icon:"triangle-alert",final:!0},badge:r.badges[e]??e,note:r.notes[e]??null}}function yp(e,r){return r.headings[e.kind]}function _p(e,r){return e.kind==="publication"?r.publish:r.validate}function xp(e,r){try{let n=new Intl.NumberFormat(r,{style:"currency",currency:e}),i=n.resolvedOptions().maximumFractionDigits??2;return t=>n.format(Number(t)/10**i)}catch{return n=>`${n} ${e}`.trim()}}function $p(e,r){let n=xp(e.currency,r),i=ko(r),t=e.unitPriceRef===null?null:n(e.unitPriceRef),o=t===null?null:e.unitCount===null?i.perUnit(t,e.unitLabel):i.units(e.unitCount,e.unitLabel,t);return{primary:n(e.envelopeRef),secondary:o}}function qh(e,r){if(e.mode==="on_demand")return r.onDemand;if(e.mode==="auto")return r.auto;let n=e.frequency?.period;return e.mode==="frequency"&&e.frequency&&(n==="day"||n==="week"||n==="month")?r.frequency(e.frequency.count,n):null}function Fh(e,r,n){if(e.kind==="publication"||e.status!=="pending_approval"||!e.expiresAt)return null;let i=new Date(e.expiresAt);return Number.isNaN(i.getTime())?null:r.expires(new Intl.DateTimeFormat(n,{dateStyle:"medium",timeStyle:"short"}).format(i))}function zp(e,r,n){let i=xp(e.currency,n);return[qh(e,r),e.sharing?r.sharing[e.sharing]??null:null,e.totalBudgetRef===null?null:r.totalBudget(i(e.totalBudgetRef)),e.overrides>0?r.overrides(e.overrides):null,Fh(e,r,n)].filter(t=>t!==null)}function ne(e){let r=document.getElementById(e);if(!r)throw new Error(`#${e} is missing from the card`);return r}var M={card:ne("card"),heading:ne("heading"),state:ne("state"),stateIcon:ne("state-icon"),stateLabel:ne("state-label"),mission:ne("mission"),amount:ne("amount"),detail:ne("detail"),meta:ne("meta"),status:ne("status"),error:ne("error"),foot:ne("foot"),note:ne("note"),actions:ne("actions"),open:ne("open"),openLabel:ne("open-label")},xr,ze=ko(void 0),B=null,kp=null,Sp=!1,wp=!1,Ip=!1,Mc=!1,jp=!1,Hh=e=>new Promise(r=>setTimeout(r,e));function Pp(e){xr=Lc(e,navigator.language),ze=ko(xr),document.documentElement.lang=xr??"en"}function Tp(){let e=wp?ze.watchFailed:Ip?ze.watchStopped:kp;M.error.hidden=!e,M.error.textContent=e??""}function So(){if(Tp(),!B){M.card.dataset.tone=hp(Sp),M.state.hidden=!0,M.foot.hidden=!0;return}let e=bp(B.status,ze),r=$p(B,xr),n=zp(B,ze,xr);M.card.dataset.tone=e.tone,M.card.dataset.state=B.status,M.heading.textContent=yp(B,ze),M.state.hidden=!1,M.stateIcon.setAttribute("href",`#i-${e.icon}`),M.stateLabel.textContent=e.badge,M.mission.textContent=`${B.missionTitle} \\xB7 v${B.versionNumber}`,M.amount.textContent=r.primary,M.detail.hidden=!r.secondary,M.detail.textContent=r.secondary??"",M.meta.hidden=n.length===0,M.meta.textContent=n.join(" \\xB7 "),M.status.hidden=!e.note,M.status.textContent=e.note??"",M.actions.hidden=e.final,M.open.disabled=!B.approvalUrl,M.openLabel.textContent=_p(B,ze),M.note.hidden=e.final,M.note.textContent=B.approvalUrl?ze.note:ze.noLink,M.foot.hidden=e.final}async function Vh(){if(Mc)return;Mc=!0;let e=Date.now();await Zc(async()=>{if(!B)return;let n=await He.callServerTool({name:"watch_mission_approval",arguments:vp(B)});if(n.isError)throw new Error($o(n));let i=Cc(n.structuredContent),t=fp(n.structuredContent);i?B=i:t&&B&&(B={...B,status:t}),So()},()=>!jp&&zo(B)&&!gp(e,Date.now()),Hh)==="gave-up"?wp=!0:zo(B)&&(Ip=!0),Tp(),Mc=!1}async function Jh(e){try{let{isError:r}=await He.openLink({url:e});r&&(M.note.textContent=e)}catch{M.note.textContent=e}}function Op(e){e&&(e.theme&&Rc(e.theme),e.locale&&Pp(e.locale),So())}var He=new xo({name:"Keyban mission card",version:"1.0.0"});He.ontoolresult=e=>{Sp=!0,B=Cc(e.structuredContent),kp=e.isError?$o(e):null,So(),zo(B)&&Vh()};He.onhostcontextchanged=e=>Op(e);He.onteardown=async()=>(jp=!0,{});M.open.addEventListener("click",()=>{B?.approvalUrl&&Jh(B.approvalUrl)});Pp(void 0);Rc(matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light");So();await He.connect();Op(He.getHostContext());\n</script>\n</body>\n</html>\n' : UNBUILT_PAGE,
|
|
172620
|
+
html: true ? '<!doctype html>\n<html lang="en">\n<head>\n<meta charset="utf-8">\n<meta name="viewport" content="width=device-width, initial-scale=1">\n<meta name="color-scheme" content="light dark">\n<title>Mission approval</title>\n<link rel="preconnect" href="https://fonts.googleapis.com">\n<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>\n<link rel="stylesheet" href="https://fonts.googleapis.com/css2?family=Inter:wght@400..600&display=swap">\n<style>\n:root {\n color-scheme: light;\n --radius: 0.625rem;\n --card: oklch(1 0 0);\n --foreground: oklch(0.145 0 0);\n --muted: oklch(0.97 0 0);\n --muted-foreground: oklch(0.54 0 0);\n --border: oklch(0.922 0 0);\n --outline-bg: var(--card);\n --outline-border: var(--border);\n --outline-hover: var(--muted);\n --primary: hsl(221 83% 53%);\n --primary-foreground: hsl(210 40% 98%);\n --ring: oklch(0.708 0 0);\n --destructive: oklch(0.577 0.245 27.325);\n --amber-500: oklch(76.9% 0.188 70.08);\n --emerald-500: oklch(69.6% 0.17 162.48);\n --red-500: oklch(63.7% 0.237 25.331);\n --orange-500: oklch(70.5% 0.213 47.604);\n --slate-500: oklch(55.4% 0.046 257.417);\n --slate-400: oklch(70.4% 0.04 256.788);\n --better: oklch(0.55 0.16 150);\n --shadow-xs: 0 1px 2px 0 rgb(0 0 0 / 0.05);\n --shadow-sm: 0 1px 3px 0 rgb(0 0 0 / 0.1), 0 1px 2px -1px rgb(0 0 0 / 0.1);\n}\n:root[data-theme="dark"] {\n color-scheme: dark;\n --card: oklch(0.205 0 0);\n --foreground: oklch(0.985 0 0);\n --muted: oklch(0.269 0 0);\n --muted-foreground: oklch(0.708 0 0);\n --border: oklch(1 0 0 / 10%);\n --outline-bg: oklch(1 0 0 / 4.5%);\n --outline-border: oklch(1 0 0 / 15%);\n --outline-hover: oklch(1 0 0 / 7.5%);\n --ring: oklch(0.556 0 0);\n --destructive: oklch(0.704 0.191 22.216);\n --better: oklch(0.78 0.15 150);\n}\n* { box-sizing: border-box; }\nhtml, body { margin: 0; background: transparent; }\nbody {\n padding: 1px 1px 4px;\n font-family: "Inter", "Inter Variable", ui-sans-serif, system-ui, sans-serif;\n font-size: 14px;\n line-height: 20px;\n color: var(--foreground);\n -webkit-font-smoothing: antialiased;\n}\n[hidden] { display: none !important; }\np { margin: 0; }\n.icon {\n width: 12px;\n height: 12px;\n flex: none;\n fill: none;\n stroke: currentColor;\n stroke-width: 2;\n stroke-linecap: round;\n stroke-linejoin: round;\n}\n.card {\n max-width: 36rem;\n overflow: hidden;\n background: var(--card);\n border: 1px solid var(--border);\n border-radius: calc(var(--radius) + 4px);\n box-shadow: var(--shadow-sm);\n}\n.head {\n display: flex;\n align-items: center;\n gap: 8px;\n padding: 10px 14px;\n background: color-mix(in oklch, var(--muted) 50%, var(--card));\n border-bottom: 1px solid var(--border);\n}\n.logo { width: 20px; height: 20px; flex: none; border-radius: 5px; }\n.title {\n flex: 1;\n min-width: 0;\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n color: var(--muted-foreground);\n font-weight: 500;\n}\n.brand { color: var(--foreground); font-weight: 600; }\n.badge {\n display: inline-flex;\n align-items: center;\n gap: 4px;\n padding: 2px 8px;\n border: 1px solid transparent;\n border-radius: calc(var(--radius) - 2px);\n background: var(--muted);\n color: var(--foreground);\n font-size: 12px;\n line-height: 16px;\n font-weight: 500;\n white-space: nowrap;\n}\n[data-state="pending_approval"] .state .icon,\n[data-state="pending_publication"] .state .icon { color: var(--amber-500); }\n[data-state="draft_changed"] .state .icon { color: var(--orange-500); }\n[data-state="active"] .state .icon,\n[data-state="published"] .state .icon,\n[data-state="completed"] .state .icon { color: var(--emerald-500); }\n[data-state="declined"] .state .icon { color: var(--red-500); }\n[data-state="active"] .state .icon { animation: spin 1s linear infinite; }\n@keyframes spin { to { transform: rotate(360deg); } }\n[data-state="abandoned"] .state .icon,\n[data-state="cancelled"] .state .icon { color: var(--slate-500); }\n[data-state="expired"] .state .icon,\n[data-state="discarded"] .state .icon { color: var(--slate-400); }\n.body { display: grid; gap: 2px; padding: 14px; }\n.figure {\n display: flex;\n flex-wrap: wrap;\n align-items: baseline;\n justify-content: space-between;\n gap: 4px 12px;\n}\n.amount {\n margin: 0;\n text-decoration: none;\n font-size: 28px;\n line-height: 34px;\n font-weight: 700;\n letter-spacing: -0.01em;\n font-variant-numeric: tabular-nums;\n}\n.mission-title { font-size: 18px; line-height: 24px; font-weight: 700; overflow-wrap: anywhere; }\n.mission-title .version { color: var(--muted-foreground); font-size: 14px; font-weight: 500; }\n.amount .was { margin-right: 6px; color: var(--muted-foreground); font-size: 16px; font-weight: 400; text-decoration: line-through; }\n.amount .arrow { margin-right: 6px; color: var(--muted-foreground); font-size: 16px; font-weight: 400; }\n.delta {\n padding: 2px 8px;\n border-radius: 999px;\n background: var(--muted);\n font-size: 13px;\n line-height: 18px;\n font-weight: 600;\n font-variant-numeric: tabular-nums;\n white-space: nowrap;\n}\n.delta.better { color: var(--better); background: color-mix(in oklch, var(--better) 14%, transparent); }\n.delta.worse { color: var(--destructive); background: color-mix(in oklch, var(--destructive) 12%, transparent); }\n.sample { margin-top: 6px; font-size: 13px; }\n.sources .tag {\n display: inline-block; margin-left: 6px; padding: 0 6px; border-radius: 999px; vertical-align: middle;\n font-size: 10px; font-weight: 600; line-height: 16px; text-transform: uppercase; letter-spacing: 0.02em;\n background: color-mix(in oklch, var(--primary) 14%, transparent); color: var(--primary);\n}\n.sources .tag.removed { background: var(--muted); color: var(--muted-foreground); text-transform: none; }\n.sources tr.strike .label { text-decoration: line-through; color: var(--muted-foreground); }\n.sources .was { color: var(--muted-foreground); font-size: 11px; }\n.plan-foot { display: grid; gap: 4px; margin-top: 10px; padding-top: 10px; border-top: 1px solid var(--border); font-size: 13px; }\n.plan-foot .line { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 2px 12px; }\n.plan-foot .label,\n.plan-foot .of { color: var(--muted-foreground); }\n.plan-foot .figures { margin-left: auto; font-variant-numeric: tabular-nums; white-space: nowrap; }\n.plan-foot b { font-weight: 600; }\n.plan-foot .unplanned { flex-basis: 100%; color: var(--muted-foreground); text-align: right; }\n.plan-foot .was { margin-right: 6px; color: var(--muted-foreground); text-decoration: line-through; }\n.plan-foot .change { margin-left: 6px; font-weight: 600; }\n.plan-foot .change.better { color: var(--better); }\n.plan-foot .change.worse,\n.plan-foot .alert .value { color: var(--destructive); }\n.block-title { margin-top: 10px; font-size: 13px; font-weight: 600; }\n.summary { margin-top: 4px; }\n.visually-hidden {\n position: absolute;\n width: 1px;\n height: 1px;\n margin: -1px;\n padding: 0;\n overflow: hidden;\n clip-path: inset(50%);\n white-space: nowrap;\n border: 0;\n}\n.suffix { color: var(--muted-foreground); font-size: 13px; font-weight: 400; letter-spacing: 0; }\n.native {\n color: var(--muted-foreground);\n font-size: 11px;\n line-height: 14px;\n font-weight: 400;\n font-variant-numeric: tabular-nums;\n}\n.sources { width: 100%; margin-top: 10px; border-collapse: collapse; font-size: 13px; }\n.sources th { padding: 4px 0; border-bottom: 1px solid var(--border); color: var(--muted-foreground); font-weight: 500; text-align: left; }\n.sources td { padding: 6px 0; border-bottom: 1px solid var(--border); vertical-align: top; }\n.sources .num { text-align: right; white-space: nowrap; padding-left: 8px; }\n.sources .label { font-weight: 600; overflow-wrap: anywhere; }\n.sources .ep { color: var(--muted-foreground); font-size: 11px; overflow-wrap: anywhere; }\n.sources tr.strike .ep { text-decoration: line-through; }\n.sources .note { color: var(--muted-foreground); font-size: 12px; }\n.sources tbody tr:last-child td { border-bottom: 0; }\n.rows a { color: var(--primary); text-decoration: none; margin-right: 8px; }\n.sources .native { margin-top: 1px; }\n.body:has(.folded:not([hidden])) { padding-bottom: 10px; }\n.folded { margin-top: 6px; }\n.folded summary {\n display: inline-flex;\n align-items: center;\n gap: 4px;\n width: fit-content;\n border-radius: calc(var(--radius) - 4px);\n color: var(--muted-foreground);\n font-size: 12px;\n line-height: 16px;\n cursor: pointer;\n list-style: none;\n}\n.folded summary::-webkit-details-marker { display: none; }\n.folded summary:hover { color: var(--foreground); }\n.folded summary:focus-visible { outline: 2px solid var(--ring); outline-offset: 2px; }\n.folded .chevron { width: 14px; height: 14px; transition: transform 150ms ease-out; }\n.folded[open] .chevron { transform: rotate(90deg); }\n.rows { display: grid; grid-template-columns: auto 1fr; gap: 4px 14px; margin-top: 6px; font-size: 13px; }\n.rows dt { color: var(--muted-foreground); }\n.rows dd { margin: 0; }\n.detail,\n.recipient { color: var(--muted-foreground); overflow-wrap: anywhere; }\n.status { margin-top: 8px; }\n.error { margin-top: 8px; color: var(--destructive); overflow-wrap: anywhere; }\n[data-state="declined"] .amount,\n[data-state="abandoned"] .amount,\n[data-state="cancelled"] .amount,\n[data-state="expired"] .amount,\n[data-state="discarded"] .amount {\n color: var(--muted-foreground);\n text-decoration: line-through;\n text-decoration-thickness: 2px;\n}\n[data-tone="loading"] .body { display: none; }\n[data-tone="loading"] .head { border-bottom: 0; }\n[data-tone="empty"] .figure,\n[data-tone="empty"] .native,\n[data-tone="empty"] .detail,\n[data-tone="empty"] .recipient { display: none; }\n.foot {\n display: flex;\n flex-wrap: wrap;\n align-items: center;\n gap: 10px 12px;\n padding: 10px 14px;\n border-top: 1px solid var(--border);\n}\n.actions { display: flex; flex-wrap: wrap; gap: 8px; margin-left: auto; }\nbutton {\n display: inline-flex;\n align-items: center;\n gap: 6px;\n height: 32px;\n padding: 0 12px;\n border: 1px solid transparent;\n border-radius: calc(var(--radius) - 2px);\n font: inherit;\n font-weight: 500;\n white-space: nowrap;\n cursor: pointer;\n transition: background-color 0.15s, color 0.15s;\n}\nbutton .icon { width: 16px; height: 16px; }\n.primary { background: var(--primary); color: var(--primary-foreground); box-shadow: var(--shadow-xs); }\n.primary:hover { background: color-mix(in oklch, var(--primary) 90%, transparent); }\n.outline {\n background: var(--outline-bg);\n color: var(--foreground);\n border-color: var(--outline-border);\n box-shadow: var(--shadow-xs);\n}\n.outline:hover { background: var(--outline-hover); }\nbutton:focus-visible {\n outline: none;\n box-shadow: 0 0 0 3px color-mix(in oklch, var(--ring) 50%, transparent);\n}\nbutton:disabled { opacity: 0.5; cursor: default; pointer-events: none; }\n@media (prefers-reduced-motion: reduce) {\n button { transition: none; }\n .folded .chevron { transition: none; }\n [data-state="active"] .state .icon { animation: none; }\n}\n</style>\n</head>\n<body>\n<svg width="0" height="0" style="position: absolute" aria-hidden="true">\n <symbol id="i-clock" viewBox="0 0 24 24"><circle cx="12" cy="12" r="10"/><path d="M12 6v6l4 2"/></symbol>\n <symbol id="i-loader" viewBox="0 0 24 24"><path d="M21 12a9 9 0 1 1-6.219-8.56"/></symbol>\n <symbol id="i-circle-check" viewBox="0 0 24 24"><circle cx="12" cy="12" r="10"/><path d="m9 12 2 2 4-4"/></symbol>\n <symbol id="i-circle-x" viewBox="0 0 24 24"><circle cx="12" cy="12" r="10"/><path d="m15 9-6 6"/><path d="m9 9 6 6"/></symbol>\n <symbol id="i-ban" viewBox="0 0 24 24"><circle cx="12" cy="12" r="10"/><path d="M4.929 4.929 19.07 19.071"/></symbol>\n <symbol id="i-triangle-alert" viewBox="0 0 24 24"><path d="m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3"/><path d="M12 9v4"/><path d="M12 17h.01"/></symbol>\n <symbol id="i-chevron-right" viewBox="0 0 24 24"><path d="m9 18 6-6-6-6"/></symbol>\n <symbol id="i-external-link" viewBox="0 0 24 24"><path d="M15 3h6v6"/><path d="M10 14 21 3"/><path d="M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6"/></symbol>\n</svg>\n<main id="card" class="card" data-tone="loading">\n <header class="head">\n <svg class="logo" viewBox="0 0 236 236" aria-hidden="true">\n <rect width="236" height="236" rx="10" fill="#a2d5f2"/>\n <g transform="matrix(.1 0 0 -.1 2.2922 220.5)"><path fill="#07689f" d="m320 1025v-775h660l-92 85-93 85h-305v1210h170l2-311 3-311 320 311 320 310h123c67 1 122-2 122-6 0-5-198-194-440-422s-439-418-438-423c2-4 131-125 287-268l284-260h380c210 0 377 4 371 8-15 14-626 573-664 608l-35 33-126-114 195-179c108-98 196-180 196-182s-57-4-127-4l-128 1-190 174c-104 96-190 181-190 188 0 9 843 812 1059 1008 6 5-154 9-365 9h-376l-204-191-204-190-3 190-2 191h-510z"/></g>\n </svg>\n <p class="title"><span class="brand">Keyban</span> \xB7 <span id="heading">Mission</span></p>\n <span id="state" class="badge state" hidden><svg class="icon" aria-hidden="true"><use id="state-icon" href="#i-clock"/></svg><span id="state-label" aria-live="polite"></span></span>\n </header>\n <section class="body">\n <p class="mission-title"><span id="mission"></span> <span id="version" class="version"></span></p>\n <div class="figure">\n <p class="amount"><span id="was-label" class="visually-hidden" hidden></span><span id="was" class="was" hidden></span><span id="arrow" class="arrow" aria-hidden="true" hidden>\u2192</span><span id="amount"> </span> <span id="suffix" class="suffix"></span></p>\n <span id="delta" class="delta" hidden></span>\n </div>\n <p id="progress" class="detail" hidden></p>\n <p id="units" class="detail" hidden></p>\n <p id="sample" class="sample" hidden></p>\n <p id="paid-title" class="block-title" hidden></p>\n <dl id="summary" class="rows summary" hidden></dl>\n <table id="sources" class="sources" hidden>\n <thead><tr id="sources-head"></tr></thead>\n <tbody id="sources-body"></tbody>\n </table>\n <div id="plan-foot" class="plan-foot" hidden>\n <div id="estimate" class="line" hidden><span id="estimate-label" class="label"></span><span class="figures"><b id="estimate-value" class="value"></b> <span id="estimate-of" class="of"></span></span><span id="estimate-unplanned" class="unplanned" hidden></span></div>\n <div id="total" class="line" hidden><span id="total-label" class="label"></span><span class="figures"><b id="total-value" class="value"></b> <span id="total-of" class="of"></span></span></div>\n <div id="envelope" class="line" hidden><span id="envelope-label" class="label"></span><span class="figures"><span id="envelope-was" class="was" hidden></span><b id="envelope-now"></b><span id="envelope-diff" class="change" hidden></span></span></div>\n </div>\n <details id="folded" class="folded" hidden>\n <summary><svg class="icon chevron" aria-hidden="true"><use href="#i-chevron-right"/></svg><span id="folded-title"></span></summary>\n <dl id="rows" class="rows"></dl>\n </details>\n <p id="status" class="status" role="status" aria-live="polite" hidden></p>\n <p id="error" class="error" role="alert" hidden></p>\n </section>\n <footer id="foot" class="foot" hidden>\n <div id="actions" class="actions" hidden>\n <button id="open" class="primary" type="button"><svg class="icon" aria-hidden="true"><use href="#i-external-link"/></svg><span id="open-label"></span></button>\n </div>\n </footer>\n</main>\n<script type="module">var km=Object.defineProperty;var De=(e=>typeof require<"u"?require:typeof Proxy<"u"?new Proxy(e,{get:(n,r)=>(typeof require<"u"?require:n)[r]}):e)(function(e){if(typeof require<"u")return require.apply(this,arguments);throw Error(\'Dynamic require of "\'+e+\'" is not supported\')});var S=(e,n)=>()=>(e&&(n=e(e=0)),n);var Pe=(e,n)=>{for(var r in n)km(e,r,{get:n[r],enumerable:!0})};function l(e,n,r){function i(u,c){var g;Object.defineProperty(u,"_zod",{value:u._zod??{},enumerable:!1}),(g=u._zod).traits??(g.traits=new Set),u._zod.traits.add(e),n(u,c);for(let f in a.prototype)f in u||Object.defineProperty(u,f,{value:a.prototype[f].bind(u)});u._zod.constr=a,u._zod.def=c}let t=r?.Parent??Object;class o extends t{}Object.defineProperty(o,"name",{value:e});function a(u){var c;let g=r?.Parent?new o:this;i(g,u),(c=g._zod).deferred??(c.deferred=[]);for(let f of g._zod.deferred)f();return g}return Object.defineProperty(a,"init",{value:i}),Object.defineProperty(a,Symbol.hasInstance,{value:u=>r?.Parent&&u instanceof r.Parent?!0:u?._zod?.traits?.has(e)}),Object.defineProperty(a,"name",{value:e}),a}function G(e){return e&&Object.assign(Rt,e),Rt}var On,Nn,ve,Rt,Ge=S(()=>{On=Object.freeze({status:"aborted"});Nn=Symbol("zod_brand"),ve=class extends Error{constructor(){super("Encountered Promise during synchronous parse. Use .parseAsync() instead.")}},Rt={}});var _={};Pe(_,{BIGINT_FORMAT_RANGES:()=>Fo,Class:()=>Uo,NUMBER_FORMAT_RANGES:()=>qo,aborted:()=>Ae,allowsEval:()=>Ao,assert:()=>Pm,assertEqual:()=>zm,assertIs:()=>wm,assertNever:()=>Im,assertNotEqual:()=>Sm,assignProp:()=>Zo,cached:()=>Dt,captureStackTrace:()=>En,cleanEnum:()=>Lm,cleanRegex:()=>Zt,clone:()=>se,createTransparentProxy:()=>Rm,defineLazy:()=>M,esc:()=>Ze,escapeRegex:()=>Se,extend:()=>Dm,finalizeIssue:()=>ce,floatSafeRemainder:()=>Do,getElementAtPath:()=>jm,getEnumValues:()=>Ct,getLengthableOrigin:()=>Lt,getParsedType:()=>Em,getSizableOrigin:()=>Mt,isObject:()=>Qe,isPlainObject:()=>Ye,issue:()=>Ho,joinValues:()=>h,jsonStringifyReplacer:()=>Co,merge:()=>Zm,normalizeParams:()=>b,nullish:()=>je,numKeys:()=>Nm,omit:()=>Cm,optionalKeys:()=>Lo,partial:()=>Am,pick:()=>Um,prefixIssues:()=>ue,primitiveTypes:()=>Mo,promiseAllObject:()=>Tm,propertyKeyTypes:()=>At,randomString:()=>Om,required:()=>Mm,stringifyPrimitive:()=>x,unwrapMessage:()=>Ut});function zm(e){return e}function Sm(e){return e}function wm(e){}function Im(e){throw new Error}function Pm(e){}function Ct(e){let n=Object.values(e).filter(i=>typeof i=="number");return Object.entries(e).filter(([i,t])=>n.indexOf(+i)===-1).map(([i,t])=>t)}function h(e,n="|"){return e.map(r=>x(r)).join(n)}function Co(e,n){return typeof n=="bigint"?n.toString():n}function Dt(e){return{get value(){{let r=e();return Object.defineProperty(this,"value",{value:r}),r}throw new Error("cached value already set")}}}function je(e){return e==null}function Zt(e){let n=e.startsWith("^")?1:0,r=e.endsWith("$")?e.length-1:e.length;return e.slice(n,r)}function Do(e,n){let r=(e.toString().split(".")[1]||"").length,i=(n.toString().split(".")[1]||"").length,t=r>i?r:i,o=Number.parseInt(e.toFixed(t).replace(".","")),a=Number.parseInt(n.toFixed(t).replace(".",""));return o%a/10**t}function M(e,n,r){Object.defineProperty(e,n,{get(){{let t=r();return e[n]=t,t}throw new Error("cached value already set")},set(t){Object.defineProperty(e,n,{value:t})},configurable:!0})}function Zo(e,n,r){Object.defineProperty(e,n,{value:r,writable:!0,enumerable:!0,configurable:!0})}function jm(e,n){return n?n.reduce((r,i)=>r?.[i],e):e}function Tm(e){let n=Object.keys(e),r=n.map(i=>e[i]);return Promise.all(r).then(i=>{let t={};for(let o=0;o<n.length;o++)t[n[o]]=i[o];return t})}function Om(e=10){let n="abcdefghijklmnopqrstuvwxyz",r="";for(let i=0;i<e;i++)r+=n[Math.floor(Math.random()*n.length)];return r}function Ze(e){return JSON.stringify(e)}function Qe(e){return typeof e=="object"&&e!==null&&!Array.isArray(e)}function Ye(e){if(Qe(e)===!1)return!1;let n=e.constructor;if(n===void 0)return!0;let r=n.prototype;return!(Qe(r)===!1||Object.prototype.hasOwnProperty.call(r,"isPrototypeOf")===!1)}function Nm(e){let n=0;for(let r in e)Object.prototype.hasOwnProperty.call(e,r)&&n++;return n}function Se(e){return e.replace(/[.*+?^${}()|[\\]\\\\]/g,"\\\\$&")}function se(e,n,r){let i=new e._zod.constr(n??e._zod.def);return(!n||r?.parent)&&(i._zod.parent=e),i}function b(e){let n=e;if(!n)return{};if(typeof n=="string")return{error:()=>n};if(n?.message!==void 0){if(n?.error!==void 0)throw new Error("Cannot specify both `message` and `error` params");n.error=n.message}return delete n.message,typeof n.error=="string"?{...n,error:()=>n.error}:n}function Rm(e){let n;return new Proxy({},{get(r,i,t){return n??(n=e()),Reflect.get(n,i,t)},set(r,i,t,o){return n??(n=e()),Reflect.set(n,i,t,o)},has(r,i){return n??(n=e()),Reflect.has(n,i)},deleteProperty(r,i){return n??(n=e()),Reflect.deleteProperty(n,i)},ownKeys(r){return n??(n=e()),Reflect.ownKeys(n)},getOwnPropertyDescriptor(r,i){return n??(n=e()),Reflect.getOwnPropertyDescriptor(n,i)},defineProperty(r,i,t){return n??(n=e()),Reflect.defineProperty(n,i,t)}})}function x(e){return typeof e=="bigint"?e.toString()+"n":typeof e=="string"?`"${e}"`:`${e}`}function Lo(e){return Object.keys(e).filter(n=>e[n]._zod.optin==="optional"&&e[n]._zod.optout==="optional")}function Um(e,n){let r={},i=e._zod.def;for(let t in n){if(!(t in i.shape))throw new Error(`Unrecognized key: "${t}"`);n[t]&&(r[t]=i.shape[t])}return se(e,{...e._zod.def,shape:r,checks:[]})}function Cm(e,n){let r={...e._zod.def.shape},i=e._zod.def;for(let t in n){if(!(t in i.shape))throw new Error(`Unrecognized key: "${t}"`);n[t]&&delete r[t]}return se(e,{...e._zod.def,shape:r,checks:[]})}function Dm(e,n){if(!Ye(n))throw new Error("Invalid input to extend: expected a plain object");let r={...e._zod.def,get shape(){let i={...e._zod.def.shape,...n};return Zo(this,"shape",i),i},checks:[]};return se(e,r)}function Zm(e,n){return se(e,{...e._zod.def,get shape(){let r={...e._zod.def.shape,...n._zod.def.shape};return Zo(this,"shape",r),r},catchall:n._zod.def.catchall,checks:[]})}function Am(e,n,r){let i=n._zod.def.shape,t={...i};if(r)for(let o in r){if(!(o in i))throw new Error(`Unrecognized key: "${o}"`);r[o]&&(t[o]=e?new e({type:"optional",innerType:i[o]}):i[o])}else for(let o in i)t[o]=e?new e({type:"optional",innerType:i[o]}):i[o];return se(n,{...n._zod.def,shape:t,checks:[]})}function Mm(e,n,r){let i=n._zod.def.shape,t={...i};if(r)for(let o in r){if(!(o in t))throw new Error(`Unrecognized key: "${o}"`);r[o]&&(t[o]=new e({type:"nonoptional",innerType:i[o]}))}else for(let o in i)t[o]=new e({type:"nonoptional",innerType:i[o]});return se(n,{...n._zod.def,shape:t,checks:[]})}function Ae(e,n=0){for(let r=n;r<e.issues.length;r++)if(e.issues[r]?.continue!==!0)return!0;return!1}function ue(e,n){return n.map(r=>{var i;return(i=r).path??(i.path=[]),r.path.unshift(e),r})}function Ut(e){return typeof e=="string"?e:e?.message}function ce(e,n,r){let i={...e,path:e.path??[]};if(!e.message){let t=Ut(e.inst?._zod.def?.error?.(e))??Ut(n?.error?.(e))??Ut(r.customError?.(e))??Ut(r.localeError?.(e))??"Invalid input";i.message=t}return delete i.inst,delete i.continue,n?.reportInput||delete i.input,i}function Mt(e){return e instanceof Set?"set":e instanceof Map?"map":e instanceof File?"file":"unknown"}function Lt(e){return Array.isArray(e)?"array":typeof e=="string"?"string":"unknown"}function Ho(...e){let[n,r,i]=e;return typeof n=="string"?{message:n,code:"custom",input:r,inst:i}:{...n}}function Lm(e){return Object.entries(e).filter(([n,r])=>Number.isNaN(Number.parseInt(n,10))).map(n=>n[1])}var En,Ao,Em,At,Mo,qo,Fo,Uo,T=S(()=>{En=Error.captureStackTrace?Error.captureStackTrace:(...e)=>{};Ao=Dt(()=>{if(typeof navigator<"u"&&navigator?.userAgent?.includes("Cloudflare"))return!1;try{let e=Function;return new e(""),!0}catch{return!1}});Em=e=>{let n=typeof e;switch(n){case"undefined":return"undefined";case"string":return"string";case"number":return Number.isNaN(e)?"nan":"number";case"boolean":return"boolean";case"function":return"function";case"bigint":return"bigint";case"symbol":return"symbol";case"object":return Array.isArray(e)?"array":e===null?"null":e.then&&typeof e.then=="function"&&e.catch&&typeof e.catch=="function"?"promise":typeof Map<"u"&&e instanceof Map?"map":typeof Set<"u"&&e instanceof Set?"set":typeof Date<"u"&&e instanceof Date?"date":typeof File<"u"&&e instanceof File?"file":"object";default:throw new Error(`Unknown data type: ${n}`)}},At=new Set(["string","number","symbol"]),Mo=new Set(["string","number","bigint","boolean","symbol","undefined"]);qo={safeint:[Number.MIN_SAFE_INTEGER,Number.MAX_SAFE_INTEGER],int32:[-2147483648,2147483647],uint32:[0,4294967295],float32:[-34028234663852886e22,34028234663852886e22],float64:[-Number.MAX_VALUE,Number.MAX_VALUE]},Fo={int64:[BigInt("-9223372036854775808"),BigInt("9223372036854775807")],uint64:[BigInt(0),BigInt("18446744073709551615")]};Uo=class{constructor(...n){}}});function et(e,n=r=>r.message){let r={},i=[];for(let t of e.issues)t.path.length>0?(r[t.path[0]]=r[t.path[0]]||[],r[t.path[0]].push(n(t))):i.push(n(t));return{formErrors:i,fieldErrors:r}}function tt(e,n){let r=n||function(o){return o.message},i={_errors:[]},t=o=>{for(let a of o.issues)if(a.code==="invalid_union"&&a.errors.length)a.errors.map(u=>t({issues:u}));else if(a.code==="invalid_key")t({issues:a.issues});else if(a.code==="invalid_element")t({issues:a.issues});else if(a.path.length===0)i._errors.push(r(a));else{let u=i,c=0;for(;c<a.path.length;){let g=a.path[c];c===a.path.length-1?(u[g]=u[g]||{_errors:[]},u[g]._errors.push(r(a))):u[g]=u[g]||{_errors:[]},u=u[g],c++}}};return t(e),i}function Rn(e,n){let r=n||function(o){return o.message},i={errors:[]},t=(o,a=[])=>{var u,c;for(let g of o.issues)if(g.code==="invalid_union"&&g.errors.length)g.errors.map(f=>t({issues:f},g.path));else if(g.code==="invalid_key")t({issues:g.issues},g.path);else if(g.code==="invalid_element")t({issues:g.issues},g.path);else{let f=[...a,...g.path];if(f.length===0){i.errors.push(r(g));continue}let m=i,$=0;for(;$<f.length;){let y=f[$],d=$===f.length-1;typeof y=="string"?(m.properties??(m.properties={}),(u=m.properties)[y]??(u[y]={errors:[]}),m=m.properties[y]):(m.items??(m.items=[]),(c=m.items)[y]??(c[y]={errors:[]}),m=m.items[y]),d&&m.errors.push(r(g)),$++}}};return t(e),i}function ml(e){let n=[];for(let r of e)typeof r=="number"?n.push(`[${r}]`):typeof r=="symbol"?n.push(`[${JSON.stringify(String(r))}]`):/[^\\w$]/.test(r)?n.push(`[${JSON.stringify(r)}]`):(n.length&&n.push("."),n.push(r));return n.join("")}function Un(e){let n=[],r=[...e.issues].sort((i,t)=>i.path.length-t.path.length);for(let i of r)n.push(`\\u2716 ${i.message}`),i.path?.length&&n.push(` \\u2192 at ${ml(i.path)}`);return n.join(`\n`)}var pl,qt,Xe,Vo=S(()=>{Ge();T();pl=(e,n)=>{e.name="$ZodError",Object.defineProperty(e,"_zod",{value:e._zod,enumerable:!1}),Object.defineProperty(e,"issues",{value:n,enumerable:!1}),Object.defineProperty(e,"message",{get(){return JSON.stringify(n,Co,2)},enumerable:!0}),Object.defineProperty(e,"toString",{value:()=>e.message,enumerable:!1})},qt=l("$ZodError",pl),Xe=l("$ZodError",pl,{Parent:Error})});var Cn,Ft,Dn,Ht,Zn,nt,An,Vt,Mn=S(()=>{Ge();Vo();T();Cn=e=>(n,r,i,t)=>{let o=i?Object.assign(i,{async:!1}):{async:!1},a=n._zod.run({value:r,issues:[]},o);if(a instanceof Promise)throw new ve;if(a.issues.length){let u=new(t?.Err??e)(a.issues.map(c=>ce(c,o,G())));throw En(u,t?.callee),u}return a.value},Ft=Cn(Xe),Dn=e=>async(n,r,i,t)=>{let o=i?Object.assign(i,{async:!0}):{async:!0},a=n._zod.run({value:r,issues:[]},o);if(a instanceof Promise&&(a=await a),a.issues.length){let u=new(t?.Err??e)(a.issues.map(c=>ce(c,o,G())));throw En(u,t?.callee),u}return a.value},Ht=Dn(Xe),Zn=e=>(n,r,i)=>{let t=i?{...i,async:!1}:{async:!1},o=n._zod.run({value:r,issues:[]},t);if(o instanceof Promise)throw new ve;return o.issues.length?{success:!1,error:new(e??qt)(o.issues.map(a=>ce(a,t,G())))}:{success:!0,data:o.value}},nt=Zn(Xe),An=e=>async(n,r,i)=>{let t=i?Object.assign(i,{async:!0}):{async:!0},o=n._zod.run({value:r,issues:[]},t);return o instanceof Promise&&(o=await o),o.issues.length?{success:!1,error:new e(o.issues.map(a=>ce(a,t,G())))}:{success:!0,data:o.value}},Vt=An(Xe)});var Te={};Pe(Te,{_emoji:()=>fl,base64:()=>ai,base64url:()=>Ln,bigint:()=>mi,boolean:()=>hi,browserEmail:()=>Gm,cidrv4:()=>oi,cidrv6:()=>ii,cuid:()=>Jo,cuid2:()=>Wo,date:()=>li,datetime:()=>di,domain:()=>Qm,duration:()=>Yo,e164:()=>ui,email:()=>ei,emoji:()=>ti,extendedDuration:()=>Fm,guid:()=>Xo,hostname:()=>si,html5Email:()=>Wm,integer:()=>fi,ipv4:()=>ni,ipv6:()=>ri,ksuid:()=>Go,lowercase:()=>yi,nanoid:()=>Qo,null:()=>vi,number:()=>gi,rfc5322Email:()=>Km,string:()=>pi,time:()=>ci,ulid:()=>Ko,undefined:()=>bi,unicodeEmail:()=>Bm,uppercase:()=>xi,uuid:()=>Me,uuid4:()=>Hm,uuid6:()=>Vm,uuid7:()=>Jm,xid:()=>Bo});function ti(){return new RegExp(fl,"u")}function hl(e){let n="(?:[01]\\\\d|2[0-3]):[0-5]\\\\d";return typeof e.precision=="number"?e.precision===-1?`${n}`:e.precision===0?`${n}:[0-5]\\\\d`:`${n}:[0-5]\\\\d\\\\.\\\\d{${e.precision}}`:`${n}(?::[0-5]\\\\d(?:\\\\.\\\\d+)?)?`}function ci(e){return new RegExp(`^${hl(e)}$`)}function di(e){let n=hl({precision:e.precision}),r=["Z"];e.local&&r.push(""),e.offset&&r.push("([+-]\\\\d{2}:\\\\d{2})");let i=`${n}(?:${r.join("|")})`;return new RegExp(`^${gl}T(?:${i})$`)}var Jo,Wo,Ko,Bo,Go,Qo,Yo,Fm,Xo,Me,Hm,Vm,Jm,ei,Wm,Km,Bm,Gm,fl,ni,ri,oi,ii,ai,Ln,si,Qm,ui,gl,li,pi,mi,fi,gi,hi,vi,bi,yi,xi,qn=S(()=>{Jo=/^[cC][^\\s-]{8,}$/,Wo=/^[0-9a-z]+$/,Ko=/^[0-9A-HJKMNP-TV-Za-hjkmnp-tv-z]{26}$/,Bo=/^[0-9a-vA-V]{20}$/,Go=/^[A-Za-z0-9]{27}$/,Qo=/^[a-zA-Z0-9_-]{21}$/,Yo=/^P(?:(\\d+W)|(?!.*W)(?=\\d|T\\d)(\\d+Y)?(\\d+M)?(\\d+D)?(T(?=\\d)(\\d+H)?(\\d+M)?(\\d+([.,]\\d+)?S)?)?)$/,Fm=/^[-+]?P(?!$)(?:(?:[-+]?\\d+Y)|(?:[-+]?\\d+[.,]\\d+Y$))?(?:(?:[-+]?\\d+M)|(?:[-+]?\\d+[.,]\\d+M$))?(?:(?:[-+]?\\d+W)|(?:[-+]?\\d+[.,]\\d+W$))?(?:(?:[-+]?\\d+D)|(?:[-+]?\\d+[.,]\\d+D$))?(?:T(?=[\\d+-])(?:(?:[-+]?\\d+H)|(?:[-+]?\\d+[.,]\\d+H$))?(?:(?:[-+]?\\d+M)|(?:[-+]?\\d+[.,]\\d+M$))?(?:[-+]?\\d+(?:[.,]\\d+)?S)?)??$/,Xo=/^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$/,Me=e=>e?new RegExp(`^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-${e}[0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12})$`):/^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000)$/,Hm=Me(4),Vm=Me(6),Jm=Me(7),ei=/^(?!\\.)(?!.*\\.\\.)([A-Za-z0-9_\'+\\-\\.]*)[A-Za-z0-9_+-]@([A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$/,Wm=/^[a-zA-Z0-9.!#$%&\'*+/=?^_`{|}~-]+@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/,Km=/^(([^<>()\\[\\]\\\\.,;:\\s@"]+(\\.[^<>()\\[\\]\\\\.,;:\\s@"]+)*)|(".+"))@((\\[[0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}])|(([a-zA-Z\\-0-9]+\\.)+[a-zA-Z]{2,}))$/,Bm=/^[^\\s@"]{1,64}@[^\\s@]{1,255}$/u,Gm=/^[a-zA-Z0-9.!#$%&\'*+/=?^_`{|}~-]+@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/,fl="^(\\\\p{Extended_Pictographic}|\\\\p{Emoji_Component})+$";ni=/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])$/,ri=/^(([0-9a-fA-F]{1,4}:){7}[0-9a-fA-F]{1,4}|::|([0-9a-fA-F]{1,4})?::([0-9a-fA-F]{1,4}:?){0,6})$/,oi=/^((25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\\.){3}(25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\\/([0-9]|[1-2][0-9]|3[0-2])$/,ii=/^(([0-9a-fA-F]{1,4}:){7}[0-9a-fA-F]{1,4}|::|([0-9a-fA-F]{1,4})?::([0-9a-fA-F]{1,4}:?){0,6})\\/(12[0-8]|1[01][0-9]|[1-9]?[0-9])$/,ai=/^$|^(?:[0-9a-zA-Z+/]{4})*(?:(?:[0-9a-zA-Z+/]{2}==)|(?:[0-9a-zA-Z+/]{3}=))?$/,Ln=/^[A-Za-z0-9_-]*$/,si=/^([a-zA-Z0-9-]+\\.)*[a-zA-Z0-9-]+$/,Qm=/^([a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?\\.)+[a-zA-Z]{2,}$/,ui=/^\\+(?:[0-9]){6,14}[0-9]$/,gl="(?:(?:\\\\d\\\\d[2468][048]|\\\\d\\\\d[13579][26]|\\\\d\\\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\\\d|30)|(?:02)-(?:0[1-9]|1\\\\d|2[0-8])))",li=new RegExp(`^${gl}$`);pi=e=>{let n=e?`[\\\\s\\\\S]{${e?.minimum??0},${e?.maximum??""}}`:"[\\\\s\\\\S]*";return new RegExp(`^${n}$`)},mi=/^\\d+n?$/,fi=/^\\d+$/,gi=/^-?\\d+(?:\\.\\d+)?/i,hi=/true|false/i,vi=/null/i,bi=/undefined/i,yi=/^[^A-Z]*$/,xi=/^[^a-z]*$/});function vl(e,n,r){e.issues.length&&n.issues.push(...ue(r,e.issues))}var B,bl,Fn,Hn,_i,$i,ki,zi,Si,wi,Ii,Pi,ji,rt,Ti,Oi,Ni,Ei,Ri,Ui,Ci,Di,Zi,Vn=S(()=>{Ge();qn();T();B=l("$ZodCheck",(e,n)=>{var r;e._zod??(e._zod={}),e._zod.def=n,(r=e._zod).onattach??(r.onattach=[])}),bl={number:"number",bigint:"bigint",object:"date"},Fn=l("$ZodCheckLessThan",(e,n)=>{B.init(e,n);let r=bl[typeof n.value];e._zod.onattach.push(i=>{let t=i._zod.bag,o=(n.inclusive?t.maximum:t.exclusiveMaximum)??Number.POSITIVE_INFINITY;n.value<o&&(n.inclusive?t.maximum=n.value:t.exclusiveMaximum=n.value)}),e._zod.check=i=>{(n.inclusive?i.value<=n.value:i.value<n.value)||i.issues.push({origin:r,code:"too_big",maximum:n.value,input:i.value,inclusive:n.inclusive,inst:e,continue:!n.abort})}}),Hn=l("$ZodCheckGreaterThan",(e,n)=>{B.init(e,n);let r=bl[typeof n.value];e._zod.onattach.push(i=>{let t=i._zod.bag,o=(n.inclusive?t.minimum:t.exclusiveMinimum)??Number.NEGATIVE_INFINITY;n.value>o&&(n.inclusive?t.minimum=n.value:t.exclusiveMinimum=n.value)}),e._zod.check=i=>{(n.inclusive?i.value>=n.value:i.value>n.value)||i.issues.push({origin:r,code:"too_small",minimum:n.value,input:i.value,inclusive:n.inclusive,inst:e,continue:!n.abort})}}),_i=l("$ZodCheckMultipleOf",(e,n)=>{B.init(e,n),e._zod.onattach.push(r=>{var i;(i=r._zod.bag).multipleOf??(i.multipleOf=n.value)}),e._zod.check=r=>{if(typeof r.value!=typeof n.value)throw new Error("Cannot mix number and bigint in multiple_of check.");(typeof r.value=="bigint"?r.value%n.value===BigInt(0):Do(r.value,n.value)===0)||r.issues.push({origin:typeof r.value,code:"not_multiple_of",divisor:n.value,input:r.value,inst:e,continue:!n.abort})}}),$i=l("$ZodCheckNumberFormat",(e,n)=>{B.init(e,n),n.format=n.format||"float64";let r=n.format?.includes("int"),i=r?"int":"number",[t,o]=qo[n.format];e._zod.onattach.push(a=>{let u=a._zod.bag;u.format=n.format,u.minimum=t,u.maximum=o,r&&(u.pattern=fi)}),e._zod.check=a=>{let u=a.value;if(r){if(!Number.isInteger(u)){a.issues.push({expected:i,format:n.format,code:"invalid_type",input:u,inst:e});return}if(!Number.isSafeInteger(u)){u>0?a.issues.push({input:u,code:"too_big",maximum:Number.MAX_SAFE_INTEGER,note:"Integers must be within the safe integer range.",inst:e,origin:i,continue:!n.abort}):a.issues.push({input:u,code:"too_small",minimum:Number.MIN_SAFE_INTEGER,note:"Integers must be within the safe integer range.",inst:e,origin:i,continue:!n.abort});return}}u<t&&a.issues.push({origin:"number",input:u,code:"too_small",minimum:t,inclusive:!0,inst:e,continue:!n.abort}),u>o&&a.issues.push({origin:"number",input:u,code:"too_big",maximum:o,inst:e})}}),ki=l("$ZodCheckBigIntFormat",(e,n)=>{B.init(e,n);let[r,i]=Fo[n.format];e._zod.onattach.push(t=>{let o=t._zod.bag;o.format=n.format,o.minimum=r,o.maximum=i}),e._zod.check=t=>{let o=t.value;o<r&&t.issues.push({origin:"bigint",input:o,code:"too_small",minimum:r,inclusive:!0,inst:e,continue:!n.abort}),o>i&&t.issues.push({origin:"bigint",input:o,code:"too_big",maximum:i,inst:e})}}),zi=l("$ZodCheckMaxSize",(e,n)=>{var r;B.init(e,n),(r=e._zod.def).when??(r.when=i=>{let t=i.value;return!je(t)&&t.size!==void 0}),e._zod.onattach.push(i=>{let t=i._zod.bag.maximum??Number.POSITIVE_INFINITY;n.maximum<t&&(i._zod.bag.maximum=n.maximum)}),e._zod.check=i=>{let t=i.value;t.size<=n.maximum||i.issues.push({origin:Mt(t),code:"too_big",maximum:n.maximum,input:t,inst:e,continue:!n.abort})}}),Si=l("$ZodCheckMinSize",(e,n)=>{var r;B.init(e,n),(r=e._zod.def).when??(r.when=i=>{let t=i.value;return!je(t)&&t.size!==void 0}),e._zod.onattach.push(i=>{let t=i._zod.bag.minimum??Number.NEGATIVE_INFINITY;n.minimum>t&&(i._zod.bag.minimum=n.minimum)}),e._zod.check=i=>{let t=i.value;t.size>=n.minimum||i.issues.push({origin:Mt(t),code:"too_small",minimum:n.minimum,input:t,inst:e,continue:!n.abort})}}),wi=l("$ZodCheckSizeEquals",(e,n)=>{var r;B.init(e,n),(r=e._zod.def).when??(r.when=i=>{let t=i.value;return!je(t)&&t.size!==void 0}),e._zod.onattach.push(i=>{let t=i._zod.bag;t.minimum=n.size,t.maximum=n.size,t.size=n.size}),e._zod.check=i=>{let t=i.value,o=t.size;if(o===n.size)return;let a=o>n.size;i.issues.push({origin:Mt(t),...a?{code:"too_big",maximum:n.size}:{code:"too_small",minimum:n.size},inclusive:!0,exact:!0,input:i.value,inst:e,continue:!n.abort})}}),Ii=l("$ZodCheckMaxLength",(e,n)=>{var r;B.init(e,n),(r=e._zod.def).when??(r.when=i=>{let t=i.value;return!je(t)&&t.length!==void 0}),e._zod.onattach.push(i=>{let t=i._zod.bag.maximum??Number.POSITIVE_INFINITY;n.maximum<t&&(i._zod.bag.maximum=n.maximum)}),e._zod.check=i=>{let t=i.value;if(t.length<=n.maximum)return;let a=Lt(t);i.issues.push({origin:a,code:"too_big",maximum:n.maximum,inclusive:!0,input:t,inst:e,continue:!n.abort})}}),Pi=l("$ZodCheckMinLength",(e,n)=>{var r;B.init(e,n),(r=e._zod.def).when??(r.when=i=>{let t=i.value;return!je(t)&&t.length!==void 0}),e._zod.onattach.push(i=>{let t=i._zod.bag.minimum??Number.NEGATIVE_INFINITY;n.minimum>t&&(i._zod.bag.minimum=n.minimum)}),e._zod.check=i=>{let t=i.value;if(t.length>=n.minimum)return;let a=Lt(t);i.issues.push({origin:a,code:"too_small",minimum:n.minimum,inclusive:!0,input:t,inst:e,continue:!n.abort})}}),ji=l("$ZodCheckLengthEquals",(e,n)=>{var r;B.init(e,n),(r=e._zod.def).when??(r.when=i=>{let t=i.value;return!je(t)&&t.length!==void 0}),e._zod.onattach.push(i=>{let t=i._zod.bag;t.minimum=n.length,t.maximum=n.length,t.length=n.length}),e._zod.check=i=>{let t=i.value,o=t.length;if(o===n.length)return;let a=Lt(t),u=o>n.length;i.issues.push({origin:a,...u?{code:"too_big",maximum:n.length}:{code:"too_small",minimum:n.length},inclusive:!0,exact:!0,input:i.value,inst:e,continue:!n.abort})}}),rt=l("$ZodCheckStringFormat",(e,n)=>{var r,i;B.init(e,n),e._zod.onattach.push(t=>{let o=t._zod.bag;o.format=n.format,n.pattern&&(o.patterns??(o.patterns=new Set),o.patterns.add(n.pattern))}),n.pattern?(r=e._zod).check??(r.check=t=>{n.pattern.lastIndex=0,!n.pattern.test(t.value)&&t.issues.push({origin:"string",code:"invalid_format",format:n.format,input:t.value,...n.pattern?{pattern:n.pattern.toString()}:{},inst:e,continue:!n.abort})}):(i=e._zod).check??(i.check=()=>{})}),Ti=l("$ZodCheckRegex",(e,n)=>{rt.init(e,n),e._zod.check=r=>{n.pattern.lastIndex=0,!n.pattern.test(r.value)&&r.issues.push({origin:"string",code:"invalid_format",format:"regex",input:r.value,pattern:n.pattern.toString(),inst:e,continue:!n.abort})}}),Oi=l("$ZodCheckLowerCase",(e,n)=>{n.pattern??(n.pattern=yi),rt.init(e,n)}),Ni=l("$ZodCheckUpperCase",(e,n)=>{n.pattern??(n.pattern=xi),rt.init(e,n)}),Ei=l("$ZodCheckIncludes",(e,n)=>{B.init(e,n);let r=Se(n.includes),i=new RegExp(typeof n.position=="number"?`^.{${n.position}}${r}`:r);n.pattern=i,e._zod.onattach.push(t=>{let o=t._zod.bag;o.patterns??(o.patterns=new Set),o.patterns.add(i)}),e._zod.check=t=>{t.value.includes(n.includes,n.position)||t.issues.push({origin:"string",code:"invalid_format",format:"includes",includes:n.includes,input:t.value,inst:e,continue:!n.abort})}}),Ri=l("$ZodCheckStartsWith",(e,n)=>{B.init(e,n);let r=new RegExp(`^${Se(n.prefix)}.*`);n.pattern??(n.pattern=r),e._zod.onattach.push(i=>{let t=i._zod.bag;t.patterns??(t.patterns=new Set),t.patterns.add(r)}),e._zod.check=i=>{i.value.startsWith(n.prefix)||i.issues.push({origin:"string",code:"invalid_format",format:"starts_with",prefix:n.prefix,input:i.value,inst:e,continue:!n.abort})}}),Ui=l("$ZodCheckEndsWith",(e,n)=>{B.init(e,n);let r=new RegExp(`.*${Se(n.suffix)}$`);n.pattern??(n.pattern=r),e._zod.onattach.push(i=>{let t=i._zod.bag;t.patterns??(t.patterns=new Set),t.patterns.add(r)}),e._zod.check=i=>{i.value.endsWith(n.suffix)||i.issues.push({origin:"string",code:"invalid_format",format:"ends_with",suffix:n.suffix,input:i.value,inst:e,continue:!n.abort})}});Ci=l("$ZodCheckProperty",(e,n)=>{B.init(e,n),e._zod.check=r=>{let i=n.schema._zod.run({value:r.value[n.property],issues:[]},{});if(i instanceof Promise)return i.then(t=>vl(t,r,n.property));vl(i,r,n.property)}}),Di=l("$ZodCheckMimeType",(e,n)=>{B.init(e,n);let r=new Set(n.mime);e._zod.onattach.push(i=>{i._zod.bag.mime=n.mime}),e._zod.check=i=>{r.has(i.value.type)||i.issues.push({code:"invalid_value",values:n.mime,input:i.value.type,inst:e})}}),Zi=l("$ZodCheckOverwrite",(e,n)=>{B.init(e,n),e._zod.check=r=>{r.value=n.tx(r.value)}})});var Jt,Ai=S(()=>{Jt=class{constructor(n=[]){this.content=[],this.indent=0,this&&(this.args=n)}indented(n){this.indent+=1,n(this),this.indent-=1}write(n){if(typeof n=="function"){n(this,{execution:"sync"}),n(this,{execution:"async"});return}let i=n.split(`\n`).filter(a=>a),t=Math.min(...i.map(a=>a.length-a.trimStart().length)),o=i.map(a=>a.slice(t)).map(a=>" ".repeat(this.indent*2)+a);for(let a of o)this.content.push(a)}compile(){let n=Function,r=this?.args,t=[...(this?.content??[""]).map(o=>` ${o}`)];return new n(...r,t.join(`\n`))}}});var Mi,Li=S(()=>{Mi={major:4,minor:0,patch:0}});function ua(e){if(e==="")return!0;if(e.length%4!==0)return!1;try{return atob(e),!0}catch{return!1}}function Ol(e){if(!Ln.test(e))return!1;let n=e.replace(/[-_]/g,i=>i==="-"?"+":"/"),r=n.padEnd(Math.ceil(n.length/4)*4,"=");return ua(r)}function Nl(e,n=null){try{let r=e.split(".");if(r.length!==3)return!1;let[i]=r;if(!i)return!1;let t=JSON.parse(atob(i));return!("typ"in t&&t?.typ!=="JWT"||!t.alg||n&&(!("alg"in t)||t.alg!==n))}catch{return!1}}function xl(e,n,r){e.issues.length&&n.issues.push(...ue(r,e.issues)),n.value[r]=e.value}function Jn(e,n,r){e.issues.length&&n.issues.push(...ue(r,e.issues)),n.value[r]=e.value}function _l(e,n,r,i){e.issues.length?i[r]===void 0?r in i?n.value[r]=void 0:n.value[r]=e.value:n.issues.push(...ue(r,e.issues)):e.value===void 0?r in i&&(n.value[r]=void 0):n.value[r]=e.value}function $l(e,n,r,i){for(let t of e)if(t.issues.length===0)return n.value=t.value,n;return n.issues.push({code:"invalid_union",input:n.value,inst:r,errors:e.map(t=>t.issues.map(o=>ce(o,i,G())))}),n}function qi(e,n){if(e===n)return{valid:!0,data:e};if(e instanceof Date&&n instanceof Date&&+e==+n)return{valid:!0,data:e};if(Ye(e)&&Ye(n)){let r=Object.keys(n),i=Object.keys(e).filter(o=>r.indexOf(o)!==-1),t={...e,...n};for(let o of i){let a=qi(e[o],n[o]);if(!a.valid)return{valid:!1,mergeErrorPath:[o,...a.mergeErrorPath]};t[o]=a.data}return{valid:!0,data:t}}if(Array.isArray(e)&&Array.isArray(n)){if(e.length!==n.length)return{valid:!1,mergeErrorPath:[]};let r=[];for(let i=0;i<e.length;i++){let t=e[i],o=n[i],a=qi(t,o);if(!a.valid)return{valid:!1,mergeErrorPath:[i,...a.mergeErrorPath]};r.push(a.data)}return{valid:!0,data:r}}return{valid:!1,mergeErrorPath:[]}}function kl(e,n,r){if(n.issues.length&&e.issues.push(...n.issues),r.issues.length&&e.issues.push(...r.issues),Ae(e))return e;let i=qi(n.value,r.value);if(!i.valid)throw new Error(`Unmergable intersection. Error path: ${JSON.stringify(i.mergeErrorPath)}`);return e.value=i.data,e}function Wn(e,n,r){e.issues.length&&n.issues.push(...ue(r,e.issues)),n.value[r]=e.value}function zl(e,n,r,i,t,o,a){e.issues.length&&(At.has(typeof i)?r.issues.push(...ue(i,e.issues)):r.issues.push({origin:"map",code:"invalid_key",input:t,inst:o,issues:e.issues.map(u=>ce(u,a,G()))})),n.issues.length&&(At.has(typeof i)?r.issues.push(...ue(i,n.issues)):r.issues.push({origin:"map",code:"invalid_element",input:t,inst:o,key:i,issues:n.issues.map(u=>ce(u,a,G()))})),r.value.set(e.value,n.value)}function Sl(e,n){e.issues.length&&n.issues.push(...e.issues),n.value.add(e.value)}function wl(e,n){return e.value===void 0&&(e.value=n.defaultValue),e}function Il(e,n){return!e.issues.length&&e.value===void 0&&e.issues.push({code:"invalid_type",expected:"nonoptional",input:e.value,inst:n}),e}function Pl(e,n,r){return Ae(e)?e:n.out._zod.run({value:e.value,issues:e.issues},r)}function jl(e){return e.value=Object.freeze(e.value),e}function Tl(e,n,r,i){if(!e){let t={code:"custom",input:r,inst:i,path:[...i._zod.def.path??[]],continue:!i._zod.def.abort};i._zod.def.params&&(t.params=i._zod.def.params),n.issues.push(Ho(t))}}var O,Le,H,Fi,Hi,Vi,Ji,Wi,Ki,Bi,Gi,Qi,Yi,Xi,ea,ta,na,ra,oa,ia,aa,sa,la,ca,da,pa,ma,Kn,fa,Wt,Bn,ga,ha,va,ba,ya,ot,xa,_a,$a,Kt,ka,Gn,za,Sa,qe,wa,Ia,Pa,ja,Ta,Oa,Bt,Na,Ea,Ra,Ua,Ca,Da,Za,Aa,Gt,Ma,La,qa,Fa,Ha,Qt=S(()=>{Vn();Ge();Ai();Mn();qn();T();Li();T();O=l("$ZodType",(e,n)=>{var r;e??(e={}),e._zod.def=n,e._zod.bag=e._zod.bag||{},e._zod.version=Mi;let i=[...e._zod.def.checks??[]];e._zod.traits.has("$ZodCheck")&&i.unshift(e);for(let t of i)for(let o of t._zod.onattach)o(e);if(i.length===0)(r=e._zod).deferred??(r.deferred=[]),e._zod.deferred?.push(()=>{e._zod.run=e._zod.parse});else{let t=(o,a,u)=>{let c=Ae(o),g;for(let f of a){if(f._zod.def.when){if(!f._zod.def.when(o))continue}else if(c)continue;let m=o.issues.length,$=f._zod.check(o);if($ instanceof Promise&&u?.async===!1)throw new ve;if(g||$ instanceof Promise)g=(g??Promise.resolve()).then(async()=>{await $,o.issues.length!==m&&(c||(c=Ae(o,m)))});else{if(o.issues.length===m)continue;c||(c=Ae(o,m))}}return g?g.then(()=>o):o};e._zod.run=(o,a)=>{let u=e._zod.parse(o,a);if(u instanceof Promise){if(a.async===!1)throw new ve;return u.then(c=>t(c,i,a))}return t(u,i,a)}}e["~standard"]={validate:t=>{try{let o=nt(e,t);return o.success?{value:o.data}:{issues:o.error?.issues}}catch{return Vt(e,t).then(a=>a.success?{value:a.data}:{issues:a.error?.issues})}},vendor:"zod",version:1}}),Le=l("$ZodString",(e,n)=>{O.init(e,n),e._zod.pattern=[...e?._zod.bag?.patterns??[]].pop()??pi(e._zod.bag),e._zod.parse=(r,i)=>{if(n.coerce)try{r.value=String(r.value)}catch{}return typeof r.value=="string"||r.issues.push({expected:"string",code:"invalid_type",input:r.value,inst:e}),r}}),H=l("$ZodStringFormat",(e,n)=>{rt.init(e,n),Le.init(e,n)}),Fi=l("$ZodGUID",(e,n)=>{n.pattern??(n.pattern=Xo),H.init(e,n)}),Hi=l("$ZodUUID",(e,n)=>{if(n.version){let i={v1:1,v2:2,v3:3,v4:4,v5:5,v6:6,v7:7,v8:8}[n.version];if(i===void 0)throw new Error(`Invalid UUID version: "${n.version}"`);n.pattern??(n.pattern=Me(i))}else n.pattern??(n.pattern=Me());H.init(e,n)}),Vi=l("$ZodEmail",(e,n)=>{n.pattern??(n.pattern=ei),H.init(e,n)}),Ji=l("$ZodURL",(e,n)=>{H.init(e,n),e._zod.check=r=>{try{let i=r.value,t=new URL(i),o=t.href;n.hostname&&(n.hostname.lastIndex=0,n.hostname.test(t.hostname)||r.issues.push({code:"invalid_format",format:"url",note:"Invalid hostname",pattern:si.source,input:r.value,inst:e,continue:!n.abort})),n.protocol&&(n.protocol.lastIndex=0,n.protocol.test(t.protocol.endsWith(":")?t.protocol.slice(0,-1):t.protocol)||r.issues.push({code:"invalid_format",format:"url",note:"Invalid protocol",pattern:n.protocol.source,input:r.value,inst:e,continue:!n.abort})),!i.endsWith("/")&&o.endsWith("/")?r.value=o.slice(0,-1):r.value=o;return}catch{r.issues.push({code:"invalid_format",format:"url",input:r.value,inst:e,continue:!n.abort})}}}),Wi=l("$ZodEmoji",(e,n)=>{n.pattern??(n.pattern=ti()),H.init(e,n)}),Ki=l("$ZodNanoID",(e,n)=>{n.pattern??(n.pattern=Qo),H.init(e,n)}),Bi=l("$ZodCUID",(e,n)=>{n.pattern??(n.pattern=Jo),H.init(e,n)}),Gi=l("$ZodCUID2",(e,n)=>{n.pattern??(n.pattern=Wo),H.init(e,n)}),Qi=l("$ZodULID",(e,n)=>{n.pattern??(n.pattern=Ko),H.init(e,n)}),Yi=l("$ZodXID",(e,n)=>{n.pattern??(n.pattern=Bo),H.init(e,n)}),Xi=l("$ZodKSUID",(e,n)=>{n.pattern??(n.pattern=Go),H.init(e,n)}),ea=l("$ZodISODateTime",(e,n)=>{n.pattern??(n.pattern=di(n)),H.init(e,n)}),ta=l("$ZodISODate",(e,n)=>{n.pattern??(n.pattern=li),H.init(e,n)}),na=l("$ZodISOTime",(e,n)=>{n.pattern??(n.pattern=ci(n)),H.init(e,n)}),ra=l("$ZodISODuration",(e,n)=>{n.pattern??(n.pattern=Yo),H.init(e,n)}),oa=l("$ZodIPv4",(e,n)=>{n.pattern??(n.pattern=ni),H.init(e,n),e._zod.onattach.push(r=>{let i=r._zod.bag;i.format="ipv4"})}),ia=l("$ZodIPv6",(e,n)=>{n.pattern??(n.pattern=ri),H.init(e,n),e._zod.onattach.push(r=>{let i=r._zod.bag;i.format="ipv6"}),e._zod.check=r=>{try{new URL(`http://[${r.value}]`)}catch{r.issues.push({code:"invalid_format",format:"ipv6",input:r.value,inst:e,continue:!n.abort})}}}),aa=l("$ZodCIDRv4",(e,n)=>{n.pattern??(n.pattern=oi),H.init(e,n)}),sa=l("$ZodCIDRv6",(e,n)=>{n.pattern??(n.pattern=ii),H.init(e,n),e._zod.check=r=>{let[i,t]=r.value.split("/");try{if(!t)throw new Error;let o=Number(t);if(`${o}`!==t)throw new Error;if(o<0||o>128)throw new Error;new URL(`http://[${i}]`)}catch{r.issues.push({code:"invalid_format",format:"cidrv6",input:r.value,inst:e,continue:!n.abort})}}});la=l("$ZodBase64",(e,n)=>{n.pattern??(n.pattern=ai),H.init(e,n),e._zod.onattach.push(r=>{r._zod.bag.contentEncoding="base64"}),e._zod.check=r=>{ua(r.value)||r.issues.push({code:"invalid_format",format:"base64",input:r.value,inst:e,continue:!n.abort})}});ca=l("$ZodBase64URL",(e,n)=>{n.pattern??(n.pattern=Ln),H.init(e,n),e._zod.onattach.push(r=>{r._zod.bag.contentEncoding="base64url"}),e._zod.check=r=>{Ol(r.value)||r.issues.push({code:"invalid_format",format:"base64url",input:r.value,inst:e,continue:!n.abort})}}),da=l("$ZodE164",(e,n)=>{n.pattern??(n.pattern=ui),H.init(e,n)});pa=l("$ZodJWT",(e,n)=>{H.init(e,n),e._zod.check=r=>{Nl(r.value,n.alg)||r.issues.push({code:"invalid_format",format:"jwt",input:r.value,inst:e,continue:!n.abort})}}),ma=l("$ZodCustomStringFormat",(e,n)=>{H.init(e,n),e._zod.check=r=>{n.fn(r.value)||r.issues.push({code:"invalid_format",format:n.format,input:r.value,inst:e,continue:!n.abort})}}),Kn=l("$ZodNumber",(e,n)=>{O.init(e,n),e._zod.pattern=e._zod.bag.pattern??gi,e._zod.parse=(r,i)=>{if(n.coerce)try{r.value=Number(r.value)}catch{}let t=r.value;if(typeof t=="number"&&!Number.isNaN(t)&&Number.isFinite(t))return r;let o=typeof t=="number"?Number.isNaN(t)?"NaN":Number.isFinite(t)?void 0:"Infinity":void 0;return r.issues.push({expected:"number",code:"invalid_type",input:t,inst:e,...o?{received:o}:{}}),r}}),fa=l("$ZodNumber",(e,n)=>{$i.init(e,n),Kn.init(e,n)}),Wt=l("$ZodBoolean",(e,n)=>{O.init(e,n),e._zod.pattern=hi,e._zod.parse=(r,i)=>{if(n.coerce)try{r.value=!!r.value}catch{}let t=r.value;return typeof t=="boolean"||r.issues.push({expected:"boolean",code:"invalid_type",input:t,inst:e}),r}}),Bn=l("$ZodBigInt",(e,n)=>{O.init(e,n),e._zod.pattern=mi,e._zod.parse=(r,i)=>{if(n.coerce)try{r.value=BigInt(r.value)}catch{}return typeof r.value=="bigint"||r.issues.push({expected:"bigint",code:"invalid_type",input:r.value,inst:e}),r}}),ga=l("$ZodBigInt",(e,n)=>{ki.init(e,n),Bn.init(e,n)}),ha=l("$ZodSymbol",(e,n)=>{O.init(e,n),e._zod.parse=(r,i)=>{let t=r.value;return typeof t=="symbol"||r.issues.push({expected:"symbol",code:"invalid_type",input:t,inst:e}),r}}),va=l("$ZodUndefined",(e,n)=>{O.init(e,n),e._zod.pattern=bi,e._zod.values=new Set([void 0]),e._zod.optin="optional",e._zod.optout="optional",e._zod.parse=(r,i)=>{let t=r.value;return typeof t>"u"||r.issues.push({expected:"undefined",code:"invalid_type",input:t,inst:e}),r}}),ba=l("$ZodNull",(e,n)=>{O.init(e,n),e._zod.pattern=vi,e._zod.values=new Set([null]),e._zod.parse=(r,i)=>{let t=r.value;return t===null||r.issues.push({expected:"null",code:"invalid_type",input:t,inst:e}),r}}),ya=l("$ZodAny",(e,n)=>{O.init(e,n),e._zod.parse=r=>r}),ot=l("$ZodUnknown",(e,n)=>{O.init(e,n),e._zod.parse=r=>r}),xa=l("$ZodNever",(e,n)=>{O.init(e,n),e._zod.parse=(r,i)=>(r.issues.push({expected:"never",code:"invalid_type",input:r.value,inst:e}),r)}),_a=l("$ZodVoid",(e,n)=>{O.init(e,n),e._zod.parse=(r,i)=>{let t=r.value;return typeof t>"u"||r.issues.push({expected:"void",code:"invalid_type",input:t,inst:e}),r}}),$a=l("$ZodDate",(e,n)=>{O.init(e,n),e._zod.parse=(r,i)=>{if(n.coerce)try{r.value=new Date(r.value)}catch{}let t=r.value,o=t instanceof Date;return o&&!Number.isNaN(t.getTime())||r.issues.push({expected:"date",code:"invalid_type",input:t,...o?{received:"Invalid Date"}:{},inst:e}),r}});Kt=l("$ZodArray",(e,n)=>{O.init(e,n),e._zod.parse=(r,i)=>{let t=r.value;if(!Array.isArray(t))return r.issues.push({expected:"array",code:"invalid_type",input:t,inst:e}),r;r.value=Array(t.length);let o=[];for(let a=0;a<t.length;a++){let u=t[a],c=n.element._zod.run({value:u,issues:[]},i);c instanceof Promise?o.push(c.then(g=>xl(g,r,a))):xl(c,r,a)}return o.length?Promise.all(o).then(()=>r):r}});ka=l("$ZodObject",(e,n)=>{O.init(e,n);let r=Dt(()=>{let m=Object.keys(n.shape);for(let y of m)if(!(n.shape[y]instanceof O))throw new Error(`Invalid element at key "${y}": expected a Zod schema`);let $=Lo(n.shape);return{shape:n.shape,keys:m,keySet:new Set(m),numKeys:m.length,optionalKeys:new Set($)}});M(e._zod,"propValues",()=>{let m=n.shape,$={};for(let y in m){let d=m[y]._zod;if(d.values){$[y]??($[y]=new Set);for(let v of d.values)$[y].add(v)}}return $});let i=m=>{let $=new Jt(["shape","payload","ctx"]),y=r.value,d=w=>{let j=Ze(w);return`shape[${j}]._zod.run({ value: input[${j}], issues: [] }, ctx)`};$.write("const input = payload.value;");let v=Object.create(null),z=0;for(let w of y.keys)v[w]=`key_${z++}`;$.write("const newResult = {}");for(let w of y.keys)if(y.optionalKeys.has(w)){let j=v[w];$.write(`const ${j} = ${d(w)};`);let D=Ze(w);$.write(`\n if (${j}.issues.length) {\n if (input[${D}] === undefined) {\n if (${D} in input) {\n newResult[${D}] = undefined;\n }\n } else {\n payload.issues = payload.issues.concat(\n ${j}.issues.map((iss) => ({\n ...iss,\n path: iss.path ? [${D}, ...iss.path] : [${D}],\n }))\n );\n }\n } else if (${j}.value === undefined) {\n if (${D} in input) newResult[${D}] = undefined;\n } else {\n newResult[${D}] = ${j}.value;\n }\n `)}else{let j=v[w];$.write(`const ${j} = ${d(w)};`),$.write(`\n if (${j}.issues.length) payload.issues = payload.issues.concat(${j}.issues.map(iss => ({\n ...iss,\n path: iss.path ? [${Ze(w)}, ...iss.path] : [${Ze(w)}]\n })));`),$.write(`newResult[${Ze(w)}] = ${j}.value`)}$.write("payload.value = newResult;"),$.write("return payload;");let C=$.compile();return(w,j)=>C(m,w,j)},t,o=Qe,a=!Rt.jitless,c=a&&Ao.value,g=n.catchall,f;e._zod.parse=(m,$)=>{f??(f=r.value);let y=m.value;if(!o(y))return m.issues.push({expected:"object",code:"invalid_type",input:y,inst:e}),m;let d=[];if(a&&c&&$?.async===!1&&$.jitless!==!0)t||(t=i(n.shape)),m=t(m,$);else{m.value={};let j=f.shape;for(let D of f.keys){let Ce=j[D],Tn=Ce._zod.run({value:y[D],issues:[]},$),cl=Ce._zod.optin==="optional"&&Ce._zod.optout==="optional";Tn instanceof Promise?d.push(Tn.then(dl=>cl?_l(dl,m,D,y):Jn(dl,m,D))):cl?_l(Tn,m,D,y):Jn(Tn,m,D)}}if(!g)return d.length?Promise.all(d).then(()=>m):m;let v=[],z=f.keySet,C=g._zod,w=C.def.type;for(let j of Object.keys(y)){if(z.has(j))continue;if(w==="never"){v.push(j);continue}let D=C.run({value:y[j],issues:[]},$);D instanceof Promise?d.push(D.then(Ce=>Jn(Ce,m,j))):Jn(D,m,j)}return v.length&&m.issues.push({code:"unrecognized_keys",keys:v,input:y,inst:e}),d.length?Promise.all(d).then(()=>m):m}});Gn=l("$ZodUnion",(e,n)=>{O.init(e,n),M(e._zod,"optin",()=>n.options.some(r=>r._zod.optin==="optional")?"optional":void 0),M(e._zod,"optout",()=>n.options.some(r=>r._zod.optout==="optional")?"optional":void 0),M(e._zod,"values",()=>{if(n.options.every(r=>r._zod.values))return new Set(n.options.flatMap(r=>Array.from(r._zod.values)))}),M(e._zod,"pattern",()=>{if(n.options.every(r=>r._zod.pattern)){let r=n.options.map(i=>i._zod.pattern);return new RegExp(`^(${r.map(i=>Zt(i.source)).join("|")})$`)}}),e._zod.parse=(r,i)=>{let t=!1,o=[];for(let a of n.options){let u=a._zod.run({value:r.value,issues:[]},i);if(u instanceof Promise)o.push(u),t=!0;else{if(u.issues.length===0)return u;o.push(u)}}return t?Promise.all(o).then(a=>$l(a,r,e,i)):$l(o,r,e,i)}}),za=l("$ZodDiscriminatedUnion",(e,n)=>{Gn.init(e,n);let r=e._zod.parse;M(e._zod,"propValues",()=>{let t={};for(let o of n.options){let a=o._zod.propValues;if(!a||Object.keys(a).length===0)throw new Error(`Invalid discriminated union option at index "${n.options.indexOf(o)}"`);for(let[u,c]of Object.entries(a)){t[u]||(t[u]=new Set);for(let g of c)t[u].add(g)}}return t});let i=Dt(()=>{let t=n.options,o=new Map;for(let a of t){let u=a._zod.propValues[n.discriminator];if(!u||u.size===0)throw new Error(`Invalid discriminated union option at index "${n.options.indexOf(a)}"`);for(let c of u){if(o.has(c))throw new Error(`Duplicate discriminator value "${String(c)}"`);o.set(c,a)}}return o});e._zod.parse=(t,o)=>{let a=t.value;if(!Qe(a))return t.issues.push({code:"invalid_type",expected:"object",input:a,inst:e}),t;let u=i.value.get(a?.[n.discriminator]);return u?u._zod.run(t,o):n.unionFallback?r(t,o):(t.issues.push({code:"invalid_union",errors:[],note:"No matching discriminator",input:a,path:[n.discriminator],inst:e}),t)}}),Sa=l("$ZodIntersection",(e,n)=>{O.init(e,n),e._zod.parse=(r,i)=>{let t=r.value,o=n.left._zod.run({value:t,issues:[]},i),a=n.right._zod.run({value:t,issues:[]},i);return o instanceof Promise||a instanceof Promise?Promise.all([o,a]).then(([c,g])=>kl(r,c,g)):kl(r,o,a)}});qe=l("$ZodTuple",(e,n)=>{O.init(e,n);let r=n.items,i=r.length-[...r].reverse().findIndex(t=>t._zod.optin!=="optional");e._zod.parse=(t,o)=>{let a=t.value;if(!Array.isArray(a))return t.issues.push({input:a,inst:e,expected:"tuple",code:"invalid_type"}),t;t.value=[];let u=[];if(!n.rest){let g=a.length>r.length,f=a.length<i-1;if(g||f)return t.issues.push({input:a,inst:e,origin:"array",...g?{code:"too_big",maximum:r.length}:{code:"too_small",minimum:r.length}}),t}let c=-1;for(let g of r){if(c++,c>=a.length&&c>=i)continue;let f=g._zod.run({value:a[c],issues:[]},o);f instanceof Promise?u.push(f.then(m=>Wn(m,t,c))):Wn(f,t,c)}if(n.rest){let g=a.slice(r.length);for(let f of g){c++;let m=n.rest._zod.run({value:f,issues:[]},o);m instanceof Promise?u.push(m.then($=>Wn($,t,c))):Wn(m,t,c)}}return u.length?Promise.all(u).then(()=>t):t}});wa=l("$ZodRecord",(e,n)=>{O.init(e,n),e._zod.parse=(r,i)=>{let t=r.value;if(!Ye(t))return r.issues.push({expected:"record",code:"invalid_type",input:t,inst:e}),r;let o=[];if(n.keyType._zod.values){let a=n.keyType._zod.values;r.value={};for(let c of a)if(typeof c=="string"||typeof c=="number"||typeof c=="symbol"){let g=n.valueType._zod.run({value:t[c],issues:[]},i);g instanceof Promise?o.push(g.then(f=>{f.issues.length&&r.issues.push(...ue(c,f.issues)),r.value[c]=f.value})):(g.issues.length&&r.issues.push(...ue(c,g.issues)),r.value[c]=g.value)}let u;for(let c in t)a.has(c)||(u=u??[],u.push(c));u&&u.length>0&&r.issues.push({code:"unrecognized_keys",input:t,inst:e,keys:u})}else{r.value={};for(let a of Reflect.ownKeys(t)){if(a==="__proto__")continue;let u=n.keyType._zod.run({value:a,issues:[]},i);if(u instanceof Promise)throw new Error("Async schemas not supported in object keys currently");if(u.issues.length){r.issues.push({origin:"record",code:"invalid_key",issues:u.issues.map(g=>ce(g,i,G())),input:a,path:[a],inst:e}),r.value[u.value]=u.value;continue}let c=n.valueType._zod.run({value:t[a],issues:[]},i);c instanceof Promise?o.push(c.then(g=>{g.issues.length&&r.issues.push(...ue(a,g.issues)),r.value[u.value]=g.value})):(c.issues.length&&r.issues.push(...ue(a,c.issues)),r.value[u.value]=c.value)}}return o.length?Promise.all(o).then(()=>r):r}}),Ia=l("$ZodMap",(e,n)=>{O.init(e,n),e._zod.parse=(r,i)=>{let t=r.value;if(!(t instanceof Map))return r.issues.push({expected:"map",code:"invalid_type",input:t,inst:e}),r;let o=[];r.value=new Map;for(let[a,u]of t){let c=n.keyType._zod.run({value:a,issues:[]},i),g=n.valueType._zod.run({value:u,issues:[]},i);c instanceof Promise||g instanceof Promise?o.push(Promise.all([c,g]).then(([f,m])=>{zl(f,m,r,a,t,e,i)})):zl(c,g,r,a,t,e,i)}return o.length?Promise.all(o).then(()=>r):r}});Pa=l("$ZodSet",(e,n)=>{O.init(e,n),e._zod.parse=(r,i)=>{let t=r.value;if(!(t instanceof Set))return r.issues.push({input:t,inst:e,expected:"set",code:"invalid_type"}),r;let o=[];r.value=new Set;for(let a of t){let u=n.valueType._zod.run({value:a,issues:[]},i);u instanceof Promise?o.push(u.then(c=>Sl(c,r))):Sl(u,r)}return o.length?Promise.all(o).then(()=>r):r}});ja=l("$ZodEnum",(e,n)=>{O.init(e,n);let r=Ct(n.entries);e._zod.values=new Set(r),e._zod.pattern=new RegExp(`^(${r.filter(i=>At.has(typeof i)).map(i=>typeof i=="string"?Se(i):i.toString()).join("|")})$`),e._zod.parse=(i,t)=>{let o=i.value;return e._zod.values.has(o)||i.issues.push({code:"invalid_value",values:r,input:o,inst:e}),i}}),Ta=l("$ZodLiteral",(e,n)=>{O.init(e,n),e._zod.values=new Set(n.values),e._zod.pattern=new RegExp(`^(${n.values.map(r=>typeof r=="string"?Se(r):r?r.toString():String(r)).join("|")})$`),e._zod.parse=(r,i)=>{let t=r.value;return e._zod.values.has(t)||r.issues.push({code:"invalid_value",values:n.values,input:t,inst:e}),r}}),Oa=l("$ZodFile",(e,n)=>{O.init(e,n),e._zod.parse=(r,i)=>{let t=r.value;return t instanceof File||r.issues.push({expected:"file",code:"invalid_type",input:t,inst:e}),r}}),Bt=l("$ZodTransform",(e,n)=>{O.init(e,n),e._zod.parse=(r,i)=>{let t=n.transform(r.value,r);if(i.async)return(t instanceof Promise?t:Promise.resolve(t)).then(a=>(r.value=a,r));if(t instanceof Promise)throw new ve;return r.value=t,r}}),Na=l("$ZodOptional",(e,n)=>{O.init(e,n),e._zod.optin="optional",e._zod.optout="optional",M(e._zod,"values",()=>n.innerType._zod.values?new Set([...n.innerType._zod.values,void 0]):void 0),M(e._zod,"pattern",()=>{let r=n.innerType._zod.pattern;return r?new RegExp(`^(${Zt(r.source)})?$`):void 0}),e._zod.parse=(r,i)=>n.innerType._zod.optin==="optional"?n.innerType._zod.run(r,i):r.value===void 0?r:n.innerType._zod.run(r,i)}),Ea=l("$ZodNullable",(e,n)=>{O.init(e,n),M(e._zod,"optin",()=>n.innerType._zod.optin),M(e._zod,"optout",()=>n.innerType._zod.optout),M(e._zod,"pattern",()=>{let r=n.innerType._zod.pattern;return r?new RegExp(`^(${Zt(r.source)}|null)$`):void 0}),M(e._zod,"values",()=>n.innerType._zod.values?new Set([...n.innerType._zod.values,null]):void 0),e._zod.parse=(r,i)=>r.value===null?r:n.innerType._zod.run(r,i)}),Ra=l("$ZodDefault",(e,n)=>{O.init(e,n),e._zod.optin="optional",M(e._zod,"values",()=>n.innerType._zod.values),e._zod.parse=(r,i)=>{if(r.value===void 0)return r.value=n.defaultValue,r;let t=n.innerType._zod.run(r,i);return t instanceof Promise?t.then(o=>wl(o,n)):wl(t,n)}});Ua=l("$ZodPrefault",(e,n)=>{O.init(e,n),e._zod.optin="optional",M(e._zod,"values",()=>n.innerType._zod.values),e._zod.parse=(r,i)=>(r.value===void 0&&(r.value=n.defaultValue),n.innerType._zod.run(r,i))}),Ca=l("$ZodNonOptional",(e,n)=>{O.init(e,n),M(e._zod,"values",()=>{let r=n.innerType._zod.values;return r?new Set([...r].filter(i=>i!==void 0)):void 0}),e._zod.parse=(r,i)=>{let t=n.innerType._zod.run(r,i);return t instanceof Promise?t.then(o=>Il(o,e)):Il(t,e)}});Da=l("$ZodSuccess",(e,n)=>{O.init(e,n),e._zod.parse=(r,i)=>{let t=n.innerType._zod.run(r,i);return t instanceof Promise?t.then(o=>(r.value=o.issues.length===0,r)):(r.value=t.issues.length===0,r)}}),Za=l("$ZodCatch",(e,n)=>{O.init(e,n),e._zod.optin="optional",M(e._zod,"optout",()=>n.innerType._zod.optout),M(e._zod,"values",()=>n.innerType._zod.values),e._zod.parse=(r,i)=>{let t=n.innerType._zod.run(r,i);return t instanceof Promise?t.then(o=>(r.value=o.value,o.issues.length&&(r.value=n.catchValue({...r,error:{issues:o.issues.map(a=>ce(a,i,G()))},input:r.value}),r.issues=[]),r)):(r.value=t.value,t.issues.length&&(r.value=n.catchValue({...r,error:{issues:t.issues.map(o=>ce(o,i,G()))},input:r.value}),r.issues=[]),r)}}),Aa=l("$ZodNaN",(e,n)=>{O.init(e,n),e._zod.parse=(r,i)=>((typeof r.value!="number"||!Number.isNaN(r.value))&&r.issues.push({input:r.value,inst:e,expected:"nan",code:"invalid_type"}),r)}),Gt=l("$ZodPipe",(e,n)=>{O.init(e,n),M(e._zod,"values",()=>n.in._zod.values),M(e._zod,"optin",()=>n.in._zod.optin),M(e._zod,"optout",()=>n.out._zod.optout),e._zod.parse=(r,i)=>{let t=n.in._zod.run(r,i);return t instanceof Promise?t.then(o=>Pl(o,n,i)):Pl(t,n,i)}});Ma=l("$ZodReadonly",(e,n)=>{O.init(e,n),M(e._zod,"propValues",()=>n.innerType._zod.propValues),M(e._zod,"values",()=>n.innerType._zod.values),M(e._zod,"optin",()=>n.innerType._zod.optin),M(e._zod,"optout",()=>n.innerType._zod.optout),e._zod.parse=(r,i)=>{let t=n.innerType._zod.run(r,i);return t instanceof Promise?t.then(jl):jl(t)}});La=l("$ZodTemplateLiteral",(e,n)=>{O.init(e,n);let r=[];for(let i of n.parts)if(i instanceof O){if(!i._zod.pattern)throw new Error(`Invalid template literal part, no pattern found: ${[...i._zod.traits].shift()}`);let t=i._zod.pattern instanceof RegExp?i._zod.pattern.source:i._zod.pattern;if(!t)throw new Error(`Invalid template literal part: ${i._zod.traits}`);let o=t.startsWith("^")?1:0,a=t.endsWith("$")?t.length-1:t.length;r.push(t.slice(o,a))}else if(i===null||Mo.has(typeof i))r.push(Se(`${i}`));else throw new Error(`Invalid template literal part: ${i}`);e._zod.pattern=new RegExp(`^${r.join("")}$`),e._zod.parse=(i,t)=>typeof i.value!="string"?(i.issues.push({input:i.value,inst:e,expected:"template_literal",code:"invalid_type"}),i):(e._zod.pattern.lastIndex=0,e._zod.pattern.test(i.value)||i.issues.push({input:i.value,inst:e,code:"invalid_format",format:"template_literal",pattern:e._zod.pattern.source}),i)}),qa=l("$ZodPromise",(e,n)=>{O.init(e,n),e._zod.parse=(r,i)=>Promise.resolve(r.value).then(t=>n.innerType._zod.run({value:t,issues:[]},i))}),Fa=l("$ZodLazy",(e,n)=>{O.init(e,n),M(e._zod,"innerType",()=>n.getter()),M(e._zod,"pattern",()=>e._zod.innerType._zod.pattern),M(e._zod,"propValues",()=>e._zod.innerType._zod.propValues),M(e._zod,"optin",()=>e._zod.innerType._zod.optin),M(e._zod,"optout",()=>e._zod.innerType._zod.optout),e._zod.parse=(r,i)=>e._zod.innerType._zod.run(r,i)}),Ha=l("$ZodCustom",(e,n)=>{B.init(e,n),O.init(e,n),e._zod.parse=(r,i)=>r,e._zod.check=r=>{let i=r.value,t=n.fn(i);if(t instanceof Promise)return t.then(o=>Tl(o,r,i,e));Tl(t,r,i,e)}})});function Rl(){return{localeError:Ym()}}var Ym,Ul=S(()=>{T();Ym=()=>{let e={string:{unit:"\\u062D\\u0631\\u0641",verb:"\\u0623\\u0646 \\u064A\\u062D\\u0648\\u064A"},file:{unit:"\\u0628\\u0627\\u064A\\u062A",verb:"\\u0623\\u0646 \\u064A\\u062D\\u0648\\u064A"},array:{unit:"\\u0639\\u0646\\u0635\\u0631",verb:"\\u0623\\u0646 \\u064A\\u062D\\u0648\\u064A"},set:{unit:"\\u0639\\u0646\\u0635\\u0631",verb:"\\u0623\\u0646 \\u064A\\u062D\\u0648\\u064A"}};function n(t){return e[t]??null}let r=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"number";case"object":{if(Array.isArray(t))return"array";if(t===null)return"null";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"\\u0645\\u062F\\u062E\\u0644",email:"\\u0628\\u0631\\u064A\\u062F \\u0625\\u0644\\u0643\\u062A\\u0631\\u0648\\u0646\\u064A",url:"\\u0631\\u0627\\u0628\\u0637",emoji:"\\u0625\\u064A\\u0645\\u0648\\u062C\\u064A",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"\\u062A\\u0627\\u0631\\u064A\\u062E \\u0648\\u0648\\u0642\\u062A \\u0628\\u0645\\u0639\\u064A\\u0627\\u0631 ISO",date:"\\u062A\\u0627\\u0631\\u064A\\u062E \\u0628\\u0645\\u0639\\u064A\\u0627\\u0631 ISO",time:"\\u0648\\u0642\\u062A \\u0628\\u0645\\u0639\\u064A\\u0627\\u0631 ISO",duration:"\\u0645\\u062F\\u0629 \\u0628\\u0645\\u0639\\u064A\\u0627\\u0631 ISO",ipv4:"\\u0639\\u0646\\u0648\\u0627\\u0646 IPv4",ipv6:"\\u0639\\u0646\\u0648\\u0627\\u0646 IPv6",cidrv4:"\\u0645\\u062F\\u0649 \\u0639\\u0646\\u0627\\u0648\\u064A\\u0646 \\u0628\\u0635\\u064A\\u063A\\u0629 IPv4",cidrv6:"\\u0645\\u062F\\u0649 \\u0639\\u0646\\u0627\\u0648\\u064A\\u0646 \\u0628\\u0635\\u064A\\u063A\\u0629 IPv6",base64:"\\u0646\\u064E\\u0635 \\u0628\\u062A\\u0631\\u0645\\u064A\\u0632 base64-encoded",base64url:"\\u0646\\u064E\\u0635 \\u0628\\u062A\\u0631\\u0645\\u064A\\u0632 base64url-encoded",json_string:"\\u0646\\u064E\\u0635 \\u0639\\u0644\\u0649 \\u0647\\u064A\\u0626\\u0629 JSON",e164:"\\u0631\\u0642\\u0645 \\u0647\\u0627\\u062A\\u0641 \\u0628\\u0645\\u0639\\u064A\\u0627\\u0631 E.164",jwt:"JWT",template_literal:"\\u0645\\u062F\\u062E\\u0644"};return t=>{switch(t.code){case"invalid_type":return`\\u0645\\u062F\\u062E\\u0644\\u0627\\u062A \\u063A\\u064A\\u0631 \\u0645\\u0642\\u0628\\u0648\\u0644\\u0629: \\u064A\\u0641\\u062A\\u0631\\u0636 \\u0625\\u062F\\u062E\\u0627\\u0644 ${t.expected}\\u060C \\u0648\\u0644\\u0643\\u0646 \\u062A\\u0645 \\u0625\\u062F\\u062E\\u0627\\u0644 ${r(t.input)}`;case"invalid_value":return t.values.length===1?`\\u0645\\u062F\\u062E\\u0644\\u0627\\u062A \\u063A\\u064A\\u0631 \\u0645\\u0642\\u0628\\u0648\\u0644\\u0629: \\u064A\\u0641\\u062A\\u0631\\u0636 \\u0625\\u062F\\u062E\\u0627\\u0644 ${x(t.values[0])}`:`\\u0627\\u062E\\u062A\\u064A\\u0627\\u0631 \\u063A\\u064A\\u0631 \\u0645\\u0642\\u0628\\u0648\\u0644: \\u064A\\u062A\\u0648\\u0642\\u0639 \\u0627\\u0646\\u062A\\u0642\\u0627\\u0621 \\u0623\\u062D\\u062F \\u0647\\u0630\\u0647 \\u0627\\u0644\\u062E\\u064A\\u0627\\u0631\\u0627\\u062A: ${h(t.values,"|")}`;case"too_big":{let o=t.inclusive?"<=":"<",a=n(t.origin);return a?` \\u0623\\u0643\\u0628\\u0631 \\u0645\\u0646 \\u0627\\u0644\\u0644\\u0627\\u0632\\u0645: \\u064A\\u0641\\u062A\\u0631\\u0636 \\u0623\\u0646 \\u062A\\u0643\\u0648\\u0646 ${t.origin??"\\u0627\\u0644\\u0642\\u064A\\u0645\\u0629"} ${o} ${t.maximum.toString()} ${a.unit??"\\u0639\\u0646\\u0635\\u0631"}`:`\\u0623\\u0643\\u0628\\u0631 \\u0645\\u0646 \\u0627\\u0644\\u0644\\u0627\\u0632\\u0645: \\u064A\\u0641\\u062A\\u0631\\u0636 \\u0623\\u0646 \\u062A\\u0643\\u0648\\u0646 ${t.origin??"\\u0627\\u0644\\u0642\\u064A\\u0645\\u0629"} ${o} ${t.maximum.toString()}`}case"too_small":{let o=t.inclusive?">=":">",a=n(t.origin);return a?`\\u0623\\u0635\\u063A\\u0631 \\u0645\\u0646 \\u0627\\u0644\\u0644\\u0627\\u0632\\u0645: \\u064A\\u0641\\u062A\\u0631\\u0636 \\u0644\\u0640 ${t.origin} \\u0623\\u0646 \\u064A\\u0643\\u0648\\u0646 ${o} ${t.minimum.toString()} ${a.unit}`:`\\u0623\\u0635\\u063A\\u0631 \\u0645\\u0646 \\u0627\\u0644\\u0644\\u0627\\u0632\\u0645: \\u064A\\u0641\\u062A\\u0631\\u0636 \\u0644\\u0640 ${t.origin} \\u0623\\u0646 \\u064A\\u0643\\u0648\\u0646 ${o} ${t.minimum.toString()}`}case"invalid_format":{let o=t;return o.format==="starts_with"?`\\u0646\\u064E\\u0635 \\u063A\\u064A\\u0631 \\u0645\\u0642\\u0628\\u0648\\u0644: \\u064A\\u062C\\u0628 \\u0623\\u0646 \\u064A\\u0628\\u062F\\u0623 \\u0628\\u0640 "${t.prefix}"`:o.format==="ends_with"?`\\u0646\\u064E\\u0635 \\u063A\\u064A\\u0631 \\u0645\\u0642\\u0628\\u0648\\u0644: \\u064A\\u062C\\u0628 \\u0623\\u0646 \\u064A\\u0646\\u062A\\u0647\\u064A \\u0628\\u0640 "${o.suffix}"`:o.format==="includes"?`\\u0646\\u064E\\u0635 \\u063A\\u064A\\u0631 \\u0645\\u0642\\u0628\\u0648\\u0644: \\u064A\\u062C\\u0628 \\u0623\\u0646 \\u064A\\u062A\\u0636\\u0645\\u0651\\u064E\\u0646 "${o.includes}"`:o.format==="regex"?`\\u0646\\u064E\\u0635 \\u063A\\u064A\\u0631 \\u0645\\u0642\\u0628\\u0648\\u0644: \\u064A\\u062C\\u0628 \\u0623\\u0646 \\u064A\\u0637\\u0627\\u0628\\u0642 \\u0627\\u0644\\u0646\\u0645\\u0637 ${o.pattern}`:`${i[o.format]??t.format} \\u063A\\u064A\\u0631 \\u0645\\u0642\\u0628\\u0648\\u0644`}case"not_multiple_of":return`\\u0631\\u0642\\u0645 \\u063A\\u064A\\u0631 \\u0645\\u0642\\u0628\\u0648\\u0644: \\u064A\\u062C\\u0628 \\u0623\\u0646 \\u064A\\u0643\\u0648\\u0646 \\u0645\\u0646 \\u0645\\u0636\\u0627\\u0639\\u0641\\u0627\\u062A ${t.divisor}`;case"unrecognized_keys":return`\\u0645\\u0639\\u0631\\u0641${t.keys.length>1?"\\u0627\\u062A":""} \\u063A\\u0631\\u064A\\u0628${t.keys.length>1?"\\u0629":""}: ${h(t.keys,"\\u060C ")}`;case"invalid_key":return`\\u0645\\u0639\\u0631\\u0641 \\u063A\\u064A\\u0631 \\u0645\\u0642\\u0628\\u0648\\u0644 \\u0641\\u064A ${t.origin}`;case"invalid_union":return"\\u0645\\u062F\\u062E\\u0644 \\u063A\\u064A\\u0631 \\u0645\\u0642\\u0628\\u0648\\u0644";case"invalid_element":return`\\u0645\\u062F\\u062E\\u0644 \\u063A\\u064A\\u0631 \\u0645\\u0642\\u0628\\u0648\\u0644 \\u0641\\u064A ${t.origin}`;default:return"\\u0645\\u062F\\u062E\\u0644 \\u063A\\u064A\\u0631 \\u0645\\u0642\\u0628\\u0648\\u0644"}}}});function Cl(){return{localeError:Xm()}}var Xm,Dl=S(()=>{T();Xm=()=>{let e={string:{unit:"simvol",verb:"olmal\\u0131d\\u0131r"},file:{unit:"bayt",verb:"olmal\\u0131d\\u0131r"},array:{unit:"element",verb:"olmal\\u0131d\\u0131r"},set:{unit:"element",verb:"olmal\\u0131d\\u0131r"}};function n(t){return e[t]??null}let r=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"number";case"object":{if(Array.isArray(t))return"array";if(t===null)return"null";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"input",email:"email address",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO datetime",date:"ISO date",time:"ISO time",duration:"ISO duration",ipv4:"IPv4 address",ipv6:"IPv6 address",cidrv4:"IPv4 range",cidrv6:"IPv6 range",base64:"base64-encoded string",base64url:"base64url-encoded string",json_string:"JSON string",e164:"E.164 number",jwt:"JWT",template_literal:"input"};return t=>{switch(t.code){case"invalid_type":return`Yanl\\u0131\\u015F d\\u0259y\\u0259r: g\\xF6zl\\u0259nil\\u0259n ${t.expected}, daxil olan ${r(t.input)}`;case"invalid_value":return t.values.length===1?`Yanl\\u0131\\u015F d\\u0259y\\u0259r: g\\xF6zl\\u0259nil\\u0259n ${x(t.values[0])}`:`Yanl\\u0131\\u015F se\\xE7im: a\\u015Fa\\u011F\\u0131dak\\u0131lardan biri olmal\\u0131d\\u0131r: ${h(t.values,"|")}`;case"too_big":{let o=t.inclusive?"<=":"<",a=n(t.origin);return a?`\\xC7ox b\\xF6y\\xFCk: g\\xF6zl\\u0259nil\\u0259n ${t.origin??"d\\u0259y\\u0259r"} ${o}${t.maximum.toString()} ${a.unit??"element"}`:`\\xC7ox b\\xF6y\\xFCk: g\\xF6zl\\u0259nil\\u0259n ${t.origin??"d\\u0259y\\u0259r"} ${o}${t.maximum.toString()}`}case"too_small":{let o=t.inclusive?">=":">",a=n(t.origin);return a?`\\xC7ox ki\\xE7ik: g\\xF6zl\\u0259nil\\u0259n ${t.origin} ${o}${t.minimum.toString()} ${a.unit}`:`\\xC7ox ki\\xE7ik: g\\xF6zl\\u0259nil\\u0259n ${t.origin} ${o}${t.minimum.toString()}`}case"invalid_format":{let o=t;return o.format==="starts_with"?`Yanl\\u0131\\u015F m\\u0259tn: "${o.prefix}" il\\u0259 ba\\u015Flamal\\u0131d\\u0131r`:o.format==="ends_with"?`Yanl\\u0131\\u015F m\\u0259tn: "${o.suffix}" il\\u0259 bitm\\u0259lidir`:o.format==="includes"?`Yanl\\u0131\\u015F m\\u0259tn: "${o.includes}" daxil olmal\\u0131d\\u0131r`:o.format==="regex"?`Yanl\\u0131\\u015F m\\u0259tn: ${o.pattern} \\u015Fablonuna uy\\u011Fun olmal\\u0131d\\u0131r`:`Yanl\\u0131\\u015F ${i[o.format]??t.format}`}case"not_multiple_of":return`Yanl\\u0131\\u015F \\u0259d\\u0259d: ${t.divisor} il\\u0259 b\\xF6l\\xFCn\\u0259 bil\\u0259n olmal\\u0131d\\u0131r`;case"unrecognized_keys":return`Tan\\u0131nmayan a\\xE7ar${t.keys.length>1?"lar":""}: ${h(t.keys,", ")}`;case"invalid_key":return`${t.origin} daxilind\\u0259 yanl\\u0131\\u015F a\\xE7ar`;case"invalid_union":return"Yanl\\u0131\\u015F d\\u0259y\\u0259r";case"invalid_element":return`${t.origin} daxilind\\u0259 yanl\\u0131\\u015F d\\u0259y\\u0259r`;default:return"Yanl\\u0131\\u015F d\\u0259y\\u0259r"}}}});function Zl(e,n,r,i){let t=Math.abs(e),o=t%10,a=t%100;return a>=11&&a<=19?i:o===1?n:o>=2&&o<=4?r:i}function Al(){return{localeError:ef()}}var ef,Ml=S(()=>{T();ef=()=>{let e={string:{unit:{one:"\\u0441\\u0456\\u043C\\u0432\\u0430\\u043B",few:"\\u0441\\u0456\\u043C\\u0432\\u0430\\u043B\\u044B",many:"\\u0441\\u0456\\u043C\\u0432\\u0430\\u043B\\u0430\\u045E"},verb:"\\u043C\\u0435\\u0446\\u044C"},array:{unit:{one:"\\u044D\\u043B\\u0435\\u043C\\u0435\\u043D\\u0442",few:"\\u044D\\u043B\\u0435\\u043C\\u0435\\u043D\\u0442\\u044B",many:"\\u044D\\u043B\\u0435\\u043C\\u0435\\u043D\\u0442\\u0430\\u045E"},verb:"\\u043C\\u0435\\u0446\\u044C"},set:{unit:{one:"\\u044D\\u043B\\u0435\\u043C\\u0435\\u043D\\u0442",few:"\\u044D\\u043B\\u0435\\u043C\\u0435\\u043D\\u0442\\u044B",many:"\\u044D\\u043B\\u0435\\u043C\\u0435\\u043D\\u0442\\u0430\\u045E"},verb:"\\u043C\\u0435\\u0446\\u044C"},file:{unit:{one:"\\u0431\\u0430\\u0439\\u0442",few:"\\u0431\\u0430\\u0439\\u0442\\u044B",many:"\\u0431\\u0430\\u0439\\u0442\\u0430\\u045E"},verb:"\\u043C\\u0435\\u0446\\u044C"}};function n(t){return e[t]??null}let r=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"\\u043B\\u0456\\u043A";case"object":{if(Array.isArray(t))return"\\u043C\\u0430\\u0441\\u0456\\u045E";if(t===null)return"null";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"\\u0443\\u0432\\u043E\\u0434",email:"email \\u0430\\u0434\\u0440\\u0430\\u0441",url:"URL",emoji:"\\u044D\\u043C\\u043E\\u0434\\u0437\\u0456",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO \\u0434\\u0430\\u0442\\u0430 \\u0456 \\u0447\\u0430\\u0441",date:"ISO \\u0434\\u0430\\u0442\\u0430",time:"ISO \\u0447\\u0430\\u0441",duration:"ISO \\u043F\\u0440\\u0430\\u0446\\u044F\\u0433\\u043B\\u0430\\u0441\\u0446\\u044C",ipv4:"IPv4 \\u0430\\u0434\\u0440\\u0430\\u0441",ipv6:"IPv6 \\u0430\\u0434\\u0440\\u0430\\u0441",cidrv4:"IPv4 \\u0434\\u044B\\u044F\\u043F\\u0430\\u0437\\u043E\\u043D",cidrv6:"IPv6 \\u0434\\u044B\\u044F\\u043F\\u0430\\u0437\\u043E\\u043D",base64:"\\u0440\\u0430\\u0434\\u043E\\u043A \\u0443 \\u0444\\u0430\\u0440\\u043C\\u0430\\u0446\\u0435 base64",base64url:"\\u0440\\u0430\\u0434\\u043E\\u043A \\u0443 \\u0444\\u0430\\u0440\\u043C\\u0430\\u0446\\u0435 base64url",json_string:"JSON \\u0440\\u0430\\u0434\\u043E\\u043A",e164:"\\u043D\\u0443\\u043C\\u0430\\u0440 E.164",jwt:"JWT",template_literal:"\\u0443\\u0432\\u043E\\u0434"};return t=>{switch(t.code){case"invalid_type":return`\\u041D\\u044F\\u043F\\u0440\\u0430\\u0432\\u0456\\u043B\\u044C\\u043D\\u044B \\u045E\\u0432\\u043E\\u0434: \\u0447\\u0430\\u043A\\u0430\\u045E\\u0441\\u044F ${t.expected}, \\u0430\\u0442\\u0440\\u044B\\u043C\\u0430\\u043D\\u0430 ${r(t.input)}`;case"invalid_value":return t.values.length===1?`\\u041D\\u044F\\u043F\\u0440\\u0430\\u0432\\u0456\\u043B\\u044C\\u043D\\u044B \\u045E\\u0432\\u043E\\u0434: \\u0447\\u0430\\u043A\\u0430\\u043B\\u0430\\u0441\\u044F ${x(t.values[0])}`:`\\u041D\\u044F\\u043F\\u0440\\u0430\\u0432\\u0456\\u043B\\u044C\\u043D\\u044B \\u0432\\u0430\\u0440\\u044B\\u044F\\u043D\\u0442: \\u0447\\u0430\\u043A\\u0430\\u045E\\u0441\\u044F \\u0430\\u0434\\u0437\\u0456\\u043D \\u0437 ${h(t.values,"|")}`;case"too_big":{let o=t.inclusive?"<=":"<",a=n(t.origin);if(a){let u=Number(t.maximum),c=Zl(u,a.unit.one,a.unit.few,a.unit.many);return`\\u0417\\u0430\\u043D\\u0430\\u0434\\u0442\\u0430 \\u0432\\u044F\\u043B\\u0456\\u043A\\u0456: \\u0447\\u0430\\u043A\\u0430\\u043B\\u0430\\u0441\\u044F, \\u0448\\u0442\\u043E ${t.origin??"\\u0437\\u043D\\u0430\\u0447\\u044D\\u043D\\u043D\\u0435"} \\u043F\\u0430\\u0432\\u0456\\u043D\\u043D\\u0430 ${a.verb} ${o}${t.maximum.toString()} ${c}`}return`\\u0417\\u0430\\u043D\\u0430\\u0434\\u0442\\u0430 \\u0432\\u044F\\u043B\\u0456\\u043A\\u0456: \\u0447\\u0430\\u043A\\u0430\\u043B\\u0430\\u0441\\u044F, \\u0448\\u0442\\u043E ${t.origin??"\\u0437\\u043D\\u0430\\u0447\\u044D\\u043D\\u043D\\u0435"} \\u043F\\u0430\\u0432\\u0456\\u043D\\u043D\\u0430 \\u0431\\u044B\\u0446\\u044C ${o}${t.maximum.toString()}`}case"too_small":{let o=t.inclusive?">=":">",a=n(t.origin);if(a){let u=Number(t.minimum),c=Zl(u,a.unit.one,a.unit.few,a.unit.many);return`\\u0417\\u0430\\u043D\\u0430\\u0434\\u0442\\u0430 \\u043C\\u0430\\u043B\\u044B: \\u0447\\u0430\\u043A\\u0430\\u043B\\u0430\\u0441\\u044F, \\u0448\\u0442\\u043E ${t.origin} \\u043F\\u0430\\u0432\\u0456\\u043D\\u043D\\u0430 ${a.verb} ${o}${t.minimum.toString()} ${c}`}return`\\u0417\\u0430\\u043D\\u0430\\u0434\\u0442\\u0430 \\u043C\\u0430\\u043B\\u044B: \\u0447\\u0430\\u043A\\u0430\\u043B\\u0430\\u0441\\u044F, \\u0448\\u0442\\u043E ${t.origin} \\u043F\\u0430\\u0432\\u0456\\u043D\\u043D\\u0430 \\u0431\\u044B\\u0446\\u044C ${o}${t.minimum.toString()}`}case"invalid_format":{let o=t;return o.format==="starts_with"?`\\u041D\\u044F\\u043F\\u0440\\u0430\\u0432\\u0456\\u043B\\u044C\\u043D\\u044B \\u0440\\u0430\\u0434\\u043E\\u043A: \\u043F\\u0430\\u0432\\u0456\\u043D\\u0435\\u043D \\u043F\\u0430\\u0447\\u044B\\u043D\\u0430\\u0446\\u0446\\u0430 \\u0437 "${o.prefix}"`:o.format==="ends_with"?`\\u041D\\u044F\\u043F\\u0440\\u0430\\u0432\\u0456\\u043B\\u044C\\u043D\\u044B \\u0440\\u0430\\u0434\\u043E\\u043A: \\u043F\\u0430\\u0432\\u0456\\u043D\\u0435\\u043D \\u0437\\u0430\\u043A\\u0430\\u043D\\u0447\\u0432\\u0430\\u0446\\u0446\\u0430 \\u043D\\u0430 "${o.suffix}"`:o.format==="includes"?`\\u041D\\u044F\\u043F\\u0440\\u0430\\u0432\\u0456\\u043B\\u044C\\u043D\\u044B \\u0440\\u0430\\u0434\\u043E\\u043A: \\u043F\\u0430\\u0432\\u0456\\u043D\\u0435\\u043D \\u0437\\u043C\\u044F\\u0448\\u0447\\u0430\\u0446\\u044C "${o.includes}"`:o.format==="regex"?`\\u041D\\u044F\\u043F\\u0440\\u0430\\u0432\\u0456\\u043B\\u044C\\u043D\\u044B \\u0440\\u0430\\u0434\\u043E\\u043A: \\u043F\\u0430\\u0432\\u0456\\u043D\\u0435\\u043D \\u0430\\u0434\\u043F\\u0430\\u0432\\u044F\\u0434\\u0430\\u0446\\u044C \\u0448\\u0430\\u0431\\u043B\\u043E\\u043D\\u0443 ${o.pattern}`:`\\u041D\\u044F\\u043F\\u0440\\u0430\\u0432\\u0456\\u043B\\u044C\\u043D\\u044B ${i[o.format]??t.format}`}case"not_multiple_of":return`\\u041D\\u044F\\u043F\\u0440\\u0430\\u0432\\u0456\\u043B\\u044C\\u043D\\u044B \\u043B\\u0456\\u043A: \\u043F\\u0430\\u0432\\u0456\\u043D\\u0435\\u043D \\u0431\\u044B\\u0446\\u044C \\u043A\\u0440\\u0430\\u0442\\u043D\\u044B\\u043C ${t.divisor}`;case"unrecognized_keys":return`\\u041D\\u0435\\u0440\\u0430\\u0441\\u043F\\u0430\\u0437\\u043D\\u0430\\u043D\\u044B ${t.keys.length>1?"\\u043A\\u043B\\u044E\\u0447\\u044B":"\\u043A\\u043B\\u044E\\u0447"}: ${h(t.keys,", ")}`;case"invalid_key":return`\\u041D\\u044F\\u043F\\u0440\\u0430\\u0432\\u0456\\u043B\\u044C\\u043D\\u044B \\u043A\\u043B\\u044E\\u0447 \\u0443 ${t.origin}`;case"invalid_union":return"\\u041D\\u044F\\u043F\\u0440\\u0430\\u0432\\u0456\\u043B\\u044C\\u043D\\u044B \\u045E\\u0432\\u043E\\u0434";case"invalid_element":return`\\u041D\\u044F\\u043F\\u0440\\u0430\\u0432\\u0456\\u043B\\u044C\\u043D\\u0430\\u0435 \\u0437\\u043D\\u0430\\u0447\\u044D\\u043D\\u043D\\u0435 \\u045E ${t.origin}`;default:return"\\u041D\\u044F\\u043F\\u0440\\u0430\\u0432\\u0456\\u043B\\u044C\\u043D\\u044B \\u045E\\u0432\\u043E\\u0434"}}}});function Ll(){return{localeError:tf()}}var tf,ql=S(()=>{T();tf=()=>{let e={string:{unit:"car\\xE0cters",verb:"contenir"},file:{unit:"bytes",verb:"contenir"},array:{unit:"elements",verb:"contenir"},set:{unit:"elements",verb:"contenir"}};function n(t){return e[t]??null}let r=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"number";case"object":{if(Array.isArray(t))return"array";if(t===null)return"null";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"entrada",email:"adre\\xE7a electr\\xF2nica",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"data i hora ISO",date:"data ISO",time:"hora ISO",duration:"durada ISO",ipv4:"adre\\xE7a IPv4",ipv6:"adre\\xE7a IPv6",cidrv4:"rang IPv4",cidrv6:"rang IPv6",base64:"cadena codificada en base64",base64url:"cadena codificada en base64url",json_string:"cadena JSON",e164:"n\\xFAmero E.164",jwt:"JWT",template_literal:"entrada"};return t=>{switch(t.code){case"invalid_type":return`Tipus inv\\xE0lid: s\'esperava ${t.expected}, s\'ha rebut ${r(t.input)}`;case"invalid_value":return t.values.length===1?`Valor inv\\xE0lid: s\'esperava ${x(t.values[0])}`:`Opci\\xF3 inv\\xE0lida: s\'esperava una de ${h(t.values," o ")}`;case"too_big":{let o=t.inclusive?"com a m\\xE0xim":"menys de",a=n(t.origin);return a?`Massa gran: s\'esperava que ${t.origin??"el valor"} contingu\\xE9s ${o} ${t.maximum.toString()} ${a.unit??"elements"}`:`Massa gran: s\'esperava que ${t.origin??"el valor"} fos ${o} ${t.maximum.toString()}`}case"too_small":{let o=t.inclusive?"com a m\\xEDnim":"m\\xE9s de",a=n(t.origin);return a?`Massa petit: s\'esperava que ${t.origin} contingu\\xE9s ${o} ${t.minimum.toString()} ${a.unit}`:`Massa petit: s\'esperava que ${t.origin} fos ${o} ${t.minimum.toString()}`}case"invalid_format":{let o=t;return o.format==="starts_with"?`Format inv\\xE0lid: ha de comen\\xE7ar amb "${o.prefix}"`:o.format==="ends_with"?`Format inv\\xE0lid: ha d\'acabar amb "${o.suffix}"`:o.format==="includes"?`Format inv\\xE0lid: ha d\'incloure "${o.includes}"`:o.format==="regex"?`Format inv\\xE0lid: ha de coincidir amb el patr\\xF3 ${o.pattern}`:`Format inv\\xE0lid per a ${i[o.format]??t.format}`}case"not_multiple_of":return`N\\xFAmero inv\\xE0lid: ha de ser m\\xFAltiple de ${t.divisor}`;case"unrecognized_keys":return`Clau${t.keys.length>1?"s":""} no reconeguda${t.keys.length>1?"s":""}: ${h(t.keys,", ")}`;case"invalid_key":return`Clau inv\\xE0lida a ${t.origin}`;case"invalid_union":return"Entrada inv\\xE0lida";case"invalid_element":return`Element inv\\xE0lid a ${t.origin}`;default:return"Entrada inv\\xE0lida"}}}});function Fl(){return{localeError:nf()}}var nf,Hl=S(()=>{T();nf=()=>{let e={string:{unit:"znak\\u016F",verb:"m\\xEDt"},file:{unit:"bajt\\u016F",verb:"m\\xEDt"},array:{unit:"prvk\\u016F",verb:"m\\xEDt"},set:{unit:"prvk\\u016F",verb:"m\\xEDt"}};function n(t){return e[t]??null}let r=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"\\u010D\\xEDslo";case"string":return"\\u0159et\\u011Bzec";case"boolean":return"boolean";case"bigint":return"bigint";case"function":return"funkce";case"symbol":return"symbol";case"undefined":return"undefined";case"object":{if(Array.isArray(t))return"pole";if(t===null)return"null";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"regul\\xE1rn\\xED v\\xFDraz",email:"e-mailov\\xE1 adresa",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"datum a \\u010Das ve form\\xE1tu ISO",date:"datum ve form\\xE1tu ISO",time:"\\u010Das ve form\\xE1tu ISO",duration:"doba trv\\xE1n\\xED ISO",ipv4:"IPv4 adresa",ipv6:"IPv6 adresa",cidrv4:"rozsah IPv4",cidrv6:"rozsah IPv6",base64:"\\u0159et\\u011Bzec zak\\xF3dovan\\xFD ve form\\xE1tu base64",base64url:"\\u0159et\\u011Bzec zak\\xF3dovan\\xFD ve form\\xE1tu base64url",json_string:"\\u0159et\\u011Bzec ve form\\xE1tu JSON",e164:"\\u010D\\xEDslo E.164",jwt:"JWT",template_literal:"vstup"};return t=>{switch(t.code){case"invalid_type":return`Neplatn\\xFD vstup: o\\u010Dek\\xE1v\\xE1no ${t.expected}, obdr\\u017Eeno ${r(t.input)}`;case"invalid_value":return t.values.length===1?`Neplatn\\xFD vstup: o\\u010Dek\\xE1v\\xE1no ${x(t.values[0])}`:`Neplatn\\xE1 mo\\u017Enost: o\\u010Dek\\xE1v\\xE1na jedna z hodnot ${h(t.values,"|")}`;case"too_big":{let o=t.inclusive?"<=":"<",a=n(t.origin);return a?`Hodnota je p\\u0159\\xEDli\\u0161 velk\\xE1: ${t.origin??"hodnota"} mus\\xED m\\xEDt ${o}${t.maximum.toString()} ${a.unit??"prvk\\u016F"}`:`Hodnota je p\\u0159\\xEDli\\u0161 velk\\xE1: ${t.origin??"hodnota"} mus\\xED b\\xFDt ${o}${t.maximum.toString()}`}case"too_small":{let o=t.inclusive?">=":">",a=n(t.origin);return a?`Hodnota je p\\u0159\\xEDli\\u0161 mal\\xE1: ${t.origin??"hodnota"} mus\\xED m\\xEDt ${o}${t.minimum.toString()} ${a.unit??"prvk\\u016F"}`:`Hodnota je p\\u0159\\xEDli\\u0161 mal\\xE1: ${t.origin??"hodnota"} mus\\xED b\\xFDt ${o}${t.minimum.toString()}`}case"invalid_format":{let o=t;return o.format==="starts_with"?`Neplatn\\xFD \\u0159et\\u011Bzec: mus\\xED za\\u010D\\xEDnat na "${o.prefix}"`:o.format==="ends_with"?`Neplatn\\xFD \\u0159et\\u011Bzec: mus\\xED kon\\u010Dit na "${o.suffix}"`:o.format==="includes"?`Neplatn\\xFD \\u0159et\\u011Bzec: mus\\xED obsahovat "${o.includes}"`:o.format==="regex"?`Neplatn\\xFD \\u0159et\\u011Bzec: mus\\xED odpov\\xEDdat vzoru ${o.pattern}`:`Neplatn\\xFD form\\xE1t ${i[o.format]??t.format}`}case"not_multiple_of":return`Neplatn\\xE9 \\u010D\\xEDslo: mus\\xED b\\xFDt n\\xE1sobkem ${t.divisor}`;case"unrecognized_keys":return`Nezn\\xE1m\\xE9 kl\\xED\\u010De: ${h(t.keys,", ")}`;case"invalid_key":return`Neplatn\\xFD kl\\xED\\u010D v ${t.origin}`;case"invalid_union":return"Neplatn\\xFD vstup";case"invalid_element":return`Neplatn\\xE1 hodnota v ${t.origin}`;default:return"Neplatn\\xFD vstup"}}}});function Vl(){return{localeError:rf()}}var rf,Jl=S(()=>{T();rf=()=>{let e={string:{unit:"Zeichen",verb:"zu haben"},file:{unit:"Bytes",verb:"zu haben"},array:{unit:"Elemente",verb:"zu haben"},set:{unit:"Elemente",verb:"zu haben"}};function n(t){return e[t]??null}let r=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"Zahl";case"object":{if(Array.isArray(t))return"Array";if(t===null)return"null";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"Eingabe",email:"E-Mail-Adresse",url:"URL",emoji:"Emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO-Datum und -Uhrzeit",date:"ISO-Datum",time:"ISO-Uhrzeit",duration:"ISO-Dauer",ipv4:"IPv4-Adresse",ipv6:"IPv6-Adresse",cidrv4:"IPv4-Bereich",cidrv6:"IPv6-Bereich",base64:"Base64-codierter String",base64url:"Base64-URL-codierter String",json_string:"JSON-String",e164:"E.164-Nummer",jwt:"JWT",template_literal:"Eingabe"};return t=>{switch(t.code){case"invalid_type":return`Ung\\xFCltige Eingabe: erwartet ${t.expected}, erhalten ${r(t.input)}`;case"invalid_value":return t.values.length===1?`Ung\\xFCltige Eingabe: erwartet ${x(t.values[0])}`:`Ung\\xFCltige Option: erwartet eine von ${h(t.values,"|")}`;case"too_big":{let o=t.inclusive?"<=":"<",a=n(t.origin);return a?`Zu gro\\xDF: erwartet, dass ${t.origin??"Wert"} ${o}${t.maximum.toString()} ${a.unit??"Elemente"} hat`:`Zu gro\\xDF: erwartet, dass ${t.origin??"Wert"} ${o}${t.maximum.toString()} ist`}case"too_small":{let o=t.inclusive?">=":">",a=n(t.origin);return a?`Zu klein: erwartet, dass ${t.origin} ${o}${t.minimum.toString()} ${a.unit} hat`:`Zu klein: erwartet, dass ${t.origin} ${o}${t.minimum.toString()} ist`}case"invalid_format":{let o=t;return o.format==="starts_with"?`Ung\\xFCltiger String: muss mit "${o.prefix}" beginnen`:o.format==="ends_with"?`Ung\\xFCltiger String: muss mit "${o.suffix}" enden`:o.format==="includes"?`Ung\\xFCltiger String: muss "${o.includes}" enthalten`:o.format==="regex"?`Ung\\xFCltiger String: muss dem Muster ${o.pattern} entsprechen`:`Ung\\xFCltig: ${i[o.format]??t.format}`}case"not_multiple_of":return`Ung\\xFCltige Zahl: muss ein Vielfaches von ${t.divisor} sein`;case"unrecognized_keys":return`${t.keys.length>1?"Unbekannte Schl\\xFCssel":"Unbekannter Schl\\xFCssel"}: ${h(t.keys,", ")}`;case"invalid_key":return`Ung\\xFCltiger Schl\\xFCssel in ${t.origin}`;case"invalid_union":return"Ung\\xFCltige Eingabe";case"invalid_element":return`Ung\\xFCltiger Wert in ${t.origin}`;default:return"Ung\\xFCltige Eingabe"}}}});function Qn(){return{localeError:af()}}var of,af,Va=S(()=>{T();of=e=>{let n=typeof e;switch(n){case"number":return Number.isNaN(e)?"NaN":"number";case"object":{if(Array.isArray(e))return"array";if(e===null)return"null";if(Object.getPrototypeOf(e)!==Object.prototype&&e.constructor)return e.constructor.name}}return n},af=()=>{let e={string:{unit:"characters",verb:"to have"},file:{unit:"bytes",verb:"to have"},array:{unit:"items",verb:"to have"},set:{unit:"items",verb:"to have"}};function n(i){return e[i]??null}let r={regex:"input",email:"email address",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO datetime",date:"ISO date",time:"ISO time",duration:"ISO duration",ipv4:"IPv4 address",ipv6:"IPv6 address",cidrv4:"IPv4 range",cidrv6:"IPv6 range",base64:"base64-encoded string",base64url:"base64url-encoded string",json_string:"JSON string",e164:"E.164 number",jwt:"JWT",template_literal:"input"};return i=>{switch(i.code){case"invalid_type":return`Invalid input: expected ${i.expected}, received ${of(i.input)}`;case"invalid_value":return i.values.length===1?`Invalid input: expected ${x(i.values[0])}`:`Invalid option: expected one of ${h(i.values,"|")}`;case"too_big":{let t=i.inclusive?"<=":"<",o=n(i.origin);return o?`Too big: expected ${i.origin??"value"} to have ${t}${i.maximum.toString()} ${o.unit??"elements"}`:`Too big: expected ${i.origin??"value"} to be ${t}${i.maximum.toString()}`}case"too_small":{let t=i.inclusive?">=":">",o=n(i.origin);return o?`Too small: expected ${i.origin} to have ${t}${i.minimum.toString()} ${o.unit}`:`Too small: expected ${i.origin} to be ${t}${i.minimum.toString()}`}case"invalid_format":{let t=i;return t.format==="starts_with"?`Invalid string: must start with "${t.prefix}"`:t.format==="ends_with"?`Invalid string: must end with "${t.suffix}"`:t.format==="includes"?`Invalid string: must include "${t.includes}"`:t.format==="regex"?`Invalid string: must match pattern ${t.pattern}`:`Invalid ${r[t.format]??i.format}`}case"not_multiple_of":return`Invalid number: must be a multiple of ${i.divisor}`;case"unrecognized_keys":return`Unrecognized key${i.keys.length>1?"s":""}: ${h(i.keys,", ")}`;case"invalid_key":return`Invalid key in ${i.origin}`;case"invalid_union":return"Invalid input";case"invalid_element":return`Invalid value in ${i.origin}`;default:return"Invalid input"}}}});function Wl(){return{localeError:uf()}}var sf,uf,Kl=S(()=>{T();sf=e=>{let n=typeof e;switch(n){case"number":return Number.isNaN(e)?"NaN":"nombro";case"object":{if(Array.isArray(e))return"tabelo";if(e===null)return"senvalora";if(Object.getPrototypeOf(e)!==Object.prototype&&e.constructor)return e.constructor.name}}return n},uf=()=>{let e={string:{unit:"karaktrojn",verb:"havi"},file:{unit:"bajtojn",verb:"havi"},array:{unit:"elementojn",verb:"havi"},set:{unit:"elementojn",verb:"havi"}};function n(i){return e[i]??null}let r={regex:"enigo",email:"retadreso",url:"URL",emoji:"emo\\u011Dio",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO-datotempo",date:"ISO-dato",time:"ISO-tempo",duration:"ISO-da\\u016Dro",ipv4:"IPv4-adreso",ipv6:"IPv6-adreso",cidrv4:"IPv4-rango",cidrv6:"IPv6-rango",base64:"64-ume kodita karaktraro",base64url:"URL-64-ume kodita karaktraro",json_string:"JSON-karaktraro",e164:"E.164-nombro",jwt:"JWT",template_literal:"enigo"};return i=>{switch(i.code){case"invalid_type":return`Nevalida enigo: atendi\\u011Dis ${i.expected}, ricevi\\u011Dis ${sf(i.input)}`;case"invalid_value":return i.values.length===1?`Nevalida enigo: atendi\\u011Dis ${x(i.values[0])}`:`Nevalida opcio: atendi\\u011Dis unu el ${h(i.values,"|")}`;case"too_big":{let t=i.inclusive?"<=":"<",o=n(i.origin);return o?`Tro granda: atendi\\u011Dis ke ${i.origin??"valoro"} havu ${t}${i.maximum.toString()} ${o.unit??"elementojn"}`:`Tro granda: atendi\\u011Dis ke ${i.origin??"valoro"} havu ${t}${i.maximum.toString()}`}case"too_small":{let t=i.inclusive?">=":">",o=n(i.origin);return o?`Tro malgranda: atendi\\u011Dis ke ${i.origin} havu ${t}${i.minimum.toString()} ${o.unit}`:`Tro malgranda: atendi\\u011Dis ke ${i.origin} estu ${t}${i.minimum.toString()}`}case"invalid_format":{let t=i;return t.format==="starts_with"?`Nevalida karaktraro: devas komenci\\u011Di per "${t.prefix}"`:t.format==="ends_with"?`Nevalida karaktraro: devas fini\\u011Di per "${t.suffix}"`:t.format==="includes"?`Nevalida karaktraro: devas inkluzivi "${t.includes}"`:t.format==="regex"?`Nevalida karaktraro: devas kongrui kun la modelo ${t.pattern}`:`Nevalida ${r[t.format]??i.format}`}case"not_multiple_of":return`Nevalida nombro: devas esti oblo de ${i.divisor}`;case"unrecognized_keys":return`Nekonata${i.keys.length>1?"j":""} \\u015Dlosilo${i.keys.length>1?"j":""}: ${h(i.keys,", ")}`;case"invalid_key":return`Nevalida \\u015Dlosilo en ${i.origin}`;case"invalid_union":return"Nevalida enigo";case"invalid_element":return`Nevalida valoro en ${i.origin}`;default:return"Nevalida enigo"}}}});function Bl(){return{localeError:lf()}}var lf,Gl=S(()=>{T();lf=()=>{let e={string:{unit:"caracteres",verb:"tener"},file:{unit:"bytes",verb:"tener"},array:{unit:"elementos",verb:"tener"},set:{unit:"elementos",verb:"tener"}};function n(t){return e[t]??null}let r=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"n\\xFAmero";case"object":{if(Array.isArray(t))return"arreglo";if(t===null)return"nulo";if(Object.getPrototypeOf(t)!==Object.prototype)return t.constructor.name}}return o},i={regex:"entrada",email:"direcci\\xF3n de correo electr\\xF3nico",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"fecha y hora ISO",date:"fecha ISO",time:"hora ISO",duration:"duraci\\xF3n ISO",ipv4:"direcci\\xF3n IPv4",ipv6:"direcci\\xF3n IPv6",cidrv4:"rango IPv4",cidrv6:"rango IPv6",base64:"cadena codificada en base64",base64url:"URL codificada en base64",json_string:"cadena JSON",e164:"n\\xFAmero E.164",jwt:"JWT",template_literal:"entrada"};return t=>{switch(t.code){case"invalid_type":return`Entrada inv\\xE1lida: se esperaba ${t.expected}, recibido ${r(t.input)}`;case"invalid_value":return t.values.length===1?`Entrada inv\\xE1lida: se esperaba ${x(t.values[0])}`:`Opci\\xF3n inv\\xE1lida: se esperaba una de ${h(t.values,"|")}`;case"too_big":{let o=t.inclusive?"<=":"<",a=n(t.origin);return a?`Demasiado grande: se esperaba que ${t.origin??"valor"} tuviera ${o}${t.maximum.toString()} ${a.unit??"elementos"}`:`Demasiado grande: se esperaba que ${t.origin??"valor"} fuera ${o}${t.maximum.toString()}`}case"too_small":{let o=t.inclusive?">=":">",a=n(t.origin);return a?`Demasiado peque\\xF1o: se esperaba que ${t.origin} tuviera ${o}${t.minimum.toString()} ${a.unit}`:`Demasiado peque\\xF1o: se esperaba que ${t.origin} fuera ${o}${t.minimum.toString()}`}case"invalid_format":{let o=t;return o.format==="starts_with"?`Cadena inv\\xE1lida: debe comenzar con "${o.prefix}"`:o.format==="ends_with"?`Cadena inv\\xE1lida: debe terminar en "${o.suffix}"`:o.format==="includes"?`Cadena inv\\xE1lida: debe incluir "${o.includes}"`:o.format==="regex"?`Cadena inv\\xE1lida: debe coincidir con el patr\\xF3n ${o.pattern}`:`Inv\\xE1lido ${i[o.format]??t.format}`}case"not_multiple_of":return`N\\xFAmero inv\\xE1lido: debe ser m\\xFAltiplo de ${t.divisor}`;case"unrecognized_keys":return`Llave${t.keys.length>1?"s":""} desconocida${t.keys.length>1?"s":""}: ${h(t.keys,", ")}`;case"invalid_key":return`Llave inv\\xE1lida en ${t.origin}`;case"invalid_union":return"Entrada inv\\xE1lida";case"invalid_element":return`Valor inv\\xE1lido en ${t.origin}`;default:return"Entrada inv\\xE1lida"}}}});function Ql(){return{localeError:cf()}}var cf,Yl=S(()=>{T();cf=()=>{let e={string:{unit:"\\u06A9\\u0627\\u0631\\u0627\\u06A9\\u062A\\u0631",verb:"\\u062F\\u0627\\u0634\\u062A\\u0647 \\u0628\\u0627\\u0634\\u062F"},file:{unit:"\\u0628\\u0627\\u06CC\\u062A",verb:"\\u062F\\u0627\\u0634\\u062A\\u0647 \\u0628\\u0627\\u0634\\u062F"},array:{unit:"\\u0622\\u06CC\\u062A\\u0645",verb:"\\u062F\\u0627\\u0634\\u062A\\u0647 \\u0628\\u0627\\u0634\\u062F"},set:{unit:"\\u0622\\u06CC\\u062A\\u0645",verb:"\\u062F\\u0627\\u0634\\u062A\\u0647 \\u0628\\u0627\\u0634\\u062F"}};function n(t){return e[t]??null}let r=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"\\u0639\\u062F\\u062F";case"object":{if(Array.isArray(t))return"\\u0622\\u0631\\u0627\\u06CC\\u0647";if(t===null)return"null";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"\\u0648\\u0631\\u0648\\u062F\\u06CC",email:"\\u0622\\u062F\\u0631\\u0633 \\u0627\\u06CC\\u0645\\u06CC\\u0644",url:"URL",emoji:"\\u0627\\u06CC\\u0645\\u0648\\u062C\\u06CC",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"\\u062A\\u0627\\u0631\\u06CC\\u062E \\u0648 \\u0632\\u0645\\u0627\\u0646 \\u0627\\u06CC\\u0632\\u0648",date:"\\u062A\\u0627\\u0631\\u06CC\\u062E \\u0627\\u06CC\\u0632\\u0648",time:"\\u0632\\u0645\\u0627\\u0646 \\u0627\\u06CC\\u0632\\u0648",duration:"\\u0645\\u062F\\u062A \\u0632\\u0645\\u0627\\u0646 \\u0627\\u06CC\\u0632\\u0648",ipv4:"IPv4 \\u0622\\u062F\\u0631\\u0633",ipv6:"IPv6 \\u0622\\u062F\\u0631\\u0633",cidrv4:"IPv4 \\u062F\\u0627\\u0645\\u0646\\u0647",cidrv6:"IPv6 \\u062F\\u0627\\u0645\\u0646\\u0647",base64:"base64-encoded \\u0631\\u0634\\u062A\\u0647",base64url:"base64url-encoded \\u0631\\u0634\\u062A\\u0647",json_string:"JSON \\u0631\\u0634\\u062A\\u0647",e164:"E.164 \\u0639\\u062F\\u062F",jwt:"JWT",template_literal:"\\u0648\\u0631\\u0648\\u062F\\u06CC"};return t=>{switch(t.code){case"invalid_type":return`\\u0648\\u0631\\u0648\\u062F\\u06CC \\u0646\\u0627\\u0645\\u0639\\u062A\\u0628\\u0631: \\u0645\\u06CC\\u200C\\u0628\\u0627\\u06CC\\u0633\\u062A ${t.expected} \\u0645\\u06CC\\u200C\\u0628\\u0648\\u062F\\u060C ${r(t.input)} \\u062F\\u0631\\u06CC\\u0627\\u0641\\u062A \\u0634\\u062F`;case"invalid_value":return t.values.length===1?`\\u0648\\u0631\\u0648\\u062F\\u06CC \\u0646\\u0627\\u0645\\u0639\\u062A\\u0628\\u0631: \\u0645\\u06CC\\u200C\\u0628\\u0627\\u06CC\\u0633\\u062A ${x(t.values[0])} \\u0645\\u06CC\\u200C\\u0628\\u0648\\u062F`:`\\u06AF\\u0632\\u06CC\\u0646\\u0647 \\u0646\\u0627\\u0645\\u0639\\u062A\\u0628\\u0631: \\u0645\\u06CC\\u200C\\u0628\\u0627\\u06CC\\u0633\\u062A \\u06CC\\u06A9\\u06CC \\u0627\\u0632 ${h(t.values,"|")} \\u0645\\u06CC\\u200C\\u0628\\u0648\\u062F`;case"too_big":{let o=t.inclusive?"<=":"<",a=n(t.origin);return a?`\\u062E\\u06CC\\u0644\\u06CC \\u0628\\u0632\\u0631\\u06AF: ${t.origin??"\\u0645\\u0642\\u062F\\u0627\\u0631"} \\u0628\\u0627\\u06CC\\u062F ${o}${t.maximum.toString()} ${a.unit??"\\u0639\\u0646\\u0635\\u0631"} \\u0628\\u0627\\u0634\\u062F`:`\\u062E\\u06CC\\u0644\\u06CC \\u0628\\u0632\\u0631\\u06AF: ${t.origin??"\\u0645\\u0642\\u062F\\u0627\\u0631"} \\u0628\\u0627\\u06CC\\u062F ${o}${t.maximum.toString()} \\u0628\\u0627\\u0634\\u062F`}case"too_small":{let o=t.inclusive?">=":">",a=n(t.origin);return a?`\\u062E\\u06CC\\u0644\\u06CC \\u06A9\\u0648\\u0686\\u06A9: ${t.origin} \\u0628\\u0627\\u06CC\\u062F ${o}${t.minimum.toString()} ${a.unit} \\u0628\\u0627\\u0634\\u062F`:`\\u062E\\u06CC\\u0644\\u06CC \\u06A9\\u0648\\u0686\\u06A9: ${t.origin} \\u0628\\u0627\\u06CC\\u062F ${o}${t.minimum.toString()} \\u0628\\u0627\\u0634\\u062F`}case"invalid_format":{let o=t;return o.format==="starts_with"?`\\u0631\\u0634\\u062A\\u0647 \\u0646\\u0627\\u0645\\u0639\\u062A\\u0628\\u0631: \\u0628\\u0627\\u06CC\\u062F \\u0628\\u0627 "${o.prefix}" \\u0634\\u0631\\u0648\\u0639 \\u0634\\u0648\\u062F`:o.format==="ends_with"?`\\u0631\\u0634\\u062A\\u0647 \\u0646\\u0627\\u0645\\u0639\\u062A\\u0628\\u0631: \\u0628\\u0627\\u06CC\\u062F \\u0628\\u0627 "${o.suffix}" \\u062A\\u0645\\u0627\\u0645 \\u0634\\u0648\\u062F`:o.format==="includes"?`\\u0631\\u0634\\u062A\\u0647 \\u0646\\u0627\\u0645\\u0639\\u062A\\u0628\\u0631: \\u0628\\u0627\\u06CC\\u062F \\u0634\\u0627\\u0645\\u0644 "${o.includes}" \\u0628\\u0627\\u0634\\u062F`:o.format==="regex"?`\\u0631\\u0634\\u062A\\u0647 \\u0646\\u0627\\u0645\\u0639\\u062A\\u0628\\u0631: \\u0628\\u0627\\u06CC\\u062F \\u0628\\u0627 \\u0627\\u0644\\u06AF\\u0648\\u06CC ${o.pattern} \\u0645\\u0637\\u0627\\u0628\\u0642\\u062A \\u062F\\u0627\\u0634\\u062A\\u0647 \\u0628\\u0627\\u0634\\u062F`:`${i[o.format]??t.format} \\u0646\\u0627\\u0645\\u0639\\u062A\\u0628\\u0631`}case"not_multiple_of":return`\\u0639\\u062F\\u062F \\u0646\\u0627\\u0645\\u0639\\u062A\\u0628\\u0631: \\u0628\\u0627\\u06CC\\u062F \\u0645\\u0636\\u0631\\u0628 ${t.divisor} \\u0628\\u0627\\u0634\\u062F`;case"unrecognized_keys":return`\\u06A9\\u0644\\u06CC\\u062F${t.keys.length>1?"\\u0647\\u0627\\u06CC":""} \\u0646\\u0627\\u0634\\u0646\\u0627\\u0633: ${h(t.keys,", ")}`;case"invalid_key":return`\\u06A9\\u0644\\u06CC\\u062F \\u0646\\u0627\\u0634\\u0646\\u0627\\u0633 \\u062F\\u0631 ${t.origin}`;case"invalid_union":return"\\u0648\\u0631\\u0648\\u062F\\u06CC \\u0646\\u0627\\u0645\\u0639\\u062A\\u0628\\u0631";case"invalid_element":return`\\u0645\\u0642\\u062F\\u0627\\u0631 \\u0646\\u0627\\u0645\\u0639\\u062A\\u0628\\u0631 \\u062F\\u0631 ${t.origin}`;default:return"\\u0648\\u0631\\u0648\\u062F\\u06CC \\u0646\\u0627\\u0645\\u0639\\u062A\\u0628\\u0631"}}}});function Xl(){return{localeError:df()}}var df,ec=S(()=>{T();df=()=>{let e={string:{unit:"merkki\\xE4",subject:"merkkijonon"},file:{unit:"tavua",subject:"tiedoston"},array:{unit:"alkiota",subject:"listan"},set:{unit:"alkiota",subject:"joukon"},number:{unit:"",subject:"luvun"},bigint:{unit:"",subject:"suuren kokonaisluvun"},int:{unit:"",subject:"kokonaisluvun"},date:{unit:"",subject:"p\\xE4iv\\xE4m\\xE4\\xE4r\\xE4n"}};function n(t){return e[t]??null}let r=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"number";case"object":{if(Array.isArray(t))return"array";if(t===null)return"null";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"s\\xE4\\xE4nn\\xF6llinen lauseke",email:"s\\xE4hk\\xF6postiosoite",url:"URL-osoite",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO-aikaleima",date:"ISO-p\\xE4iv\\xE4m\\xE4\\xE4r\\xE4",time:"ISO-aika",duration:"ISO-kesto",ipv4:"IPv4-osoite",ipv6:"IPv6-osoite",cidrv4:"IPv4-alue",cidrv6:"IPv6-alue",base64:"base64-koodattu merkkijono",base64url:"base64url-koodattu merkkijono",json_string:"JSON-merkkijono",e164:"E.164-luku",jwt:"JWT",template_literal:"templaattimerkkijono"};return t=>{switch(t.code){case"invalid_type":return`Virheellinen tyyppi: odotettiin ${t.expected}, oli ${r(t.input)}`;case"invalid_value":return t.values.length===1?`Virheellinen sy\\xF6te: t\\xE4ytyy olla ${x(t.values[0])}`:`Virheellinen valinta: t\\xE4ytyy olla yksi seuraavista: ${h(t.values,"|")}`;case"too_big":{let o=t.inclusive?"<=":"<",a=n(t.origin);return a?`Liian suuri: ${a.subject} t\\xE4ytyy olla ${o}${t.maximum.toString()} ${a.unit}`.trim():`Liian suuri: arvon t\\xE4ytyy olla ${o}${t.maximum.toString()}`}case"too_small":{let o=t.inclusive?">=":">",a=n(t.origin);return a?`Liian pieni: ${a.subject} t\\xE4ytyy olla ${o}${t.minimum.toString()} ${a.unit}`.trim():`Liian pieni: arvon t\\xE4ytyy olla ${o}${t.minimum.toString()}`}case"invalid_format":{let o=t;return o.format==="starts_with"?`Virheellinen sy\\xF6te: t\\xE4ytyy alkaa "${o.prefix}"`:o.format==="ends_with"?`Virheellinen sy\\xF6te: t\\xE4ytyy loppua "${o.suffix}"`:o.format==="includes"?`Virheellinen sy\\xF6te: t\\xE4ytyy sis\\xE4lt\\xE4\\xE4 "${o.includes}"`:o.format==="regex"?`Virheellinen sy\\xF6te: t\\xE4ytyy vastata s\\xE4\\xE4nn\\xF6llist\\xE4 lauseketta ${o.pattern}`:`Virheellinen ${i[o.format]??t.format}`}case"not_multiple_of":return`Virheellinen luku: t\\xE4ytyy olla luvun ${t.divisor} monikerta`;case"unrecognized_keys":return`${t.keys.length>1?"Tuntemattomat avaimet":"Tuntematon avain"}: ${h(t.keys,", ")}`;case"invalid_key":return"Virheellinen avain tietueessa";case"invalid_union":return"Virheellinen unioni";case"invalid_element":return"Virheellinen arvo joukossa";default:return"Virheellinen sy\\xF6te"}}}});function tc(){return{localeError:pf()}}var pf,nc=S(()=>{T();pf=()=>{let e={string:{unit:"caract\\xE8res",verb:"avoir"},file:{unit:"octets",verb:"avoir"},array:{unit:"\\xE9l\\xE9ments",verb:"avoir"},set:{unit:"\\xE9l\\xE9ments",verb:"avoir"}};function n(t){return e[t]??null}let r=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"nombre";case"object":{if(Array.isArray(t))return"tableau";if(t===null)return"null";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"entr\\xE9e",email:"adresse e-mail",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"date et heure ISO",date:"date ISO",time:"heure ISO",duration:"dur\\xE9e ISO",ipv4:"adresse IPv4",ipv6:"adresse IPv6",cidrv4:"plage IPv4",cidrv6:"plage IPv6",base64:"cha\\xEEne encod\\xE9e en base64",base64url:"cha\\xEEne encod\\xE9e en base64url",json_string:"cha\\xEEne JSON",e164:"num\\xE9ro E.164",jwt:"JWT",template_literal:"entr\\xE9e"};return t=>{switch(t.code){case"invalid_type":return`Entr\\xE9e invalide : ${t.expected} attendu, ${r(t.input)} re\\xE7u`;case"invalid_value":return t.values.length===1?`Entr\\xE9e invalide : ${x(t.values[0])} attendu`:`Option invalide : une valeur parmi ${h(t.values,"|")} attendue`;case"too_big":{let o=t.inclusive?"<=":"<",a=n(t.origin);return a?`Trop grand : ${t.origin??"valeur"} doit ${a.verb} ${o}${t.maximum.toString()} ${a.unit??"\\xE9l\\xE9ment(s)"}`:`Trop grand : ${t.origin??"valeur"} doit \\xEAtre ${o}${t.maximum.toString()}`}case"too_small":{let o=t.inclusive?">=":">",a=n(t.origin);return a?`Trop petit : ${t.origin} doit ${a.verb} ${o}${t.minimum.toString()} ${a.unit}`:`Trop petit : ${t.origin} doit \\xEAtre ${o}${t.minimum.toString()}`}case"invalid_format":{let o=t;return o.format==="starts_with"?`Cha\\xEEne invalide : doit commencer par "${o.prefix}"`:o.format==="ends_with"?`Cha\\xEEne invalide : doit se terminer par "${o.suffix}"`:o.format==="includes"?`Cha\\xEEne invalide : doit inclure "${o.includes}"`:o.format==="regex"?`Cha\\xEEne invalide : doit correspondre au mod\\xE8le ${o.pattern}`:`${i[o.format]??t.format} invalide`}case"not_multiple_of":return`Nombre invalide : doit \\xEAtre un multiple de ${t.divisor}`;case"unrecognized_keys":return`Cl\\xE9${t.keys.length>1?"s":""} non reconnue${t.keys.length>1?"s":""} : ${h(t.keys,", ")}`;case"invalid_key":return`Cl\\xE9 invalide dans ${t.origin}`;case"invalid_union":return"Entr\\xE9e invalide";case"invalid_element":return`Valeur invalide dans ${t.origin}`;default:return"Entr\\xE9e invalide"}}}});function rc(){return{localeError:mf()}}var mf,oc=S(()=>{T();mf=()=>{let e={string:{unit:"caract\\xE8res",verb:"avoir"},file:{unit:"octets",verb:"avoir"},array:{unit:"\\xE9l\\xE9ments",verb:"avoir"},set:{unit:"\\xE9l\\xE9ments",verb:"avoir"}};function n(t){return e[t]??null}let r=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"number";case"object":{if(Array.isArray(t))return"array";if(t===null)return"null";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"entr\\xE9e",email:"adresse courriel",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"date-heure ISO",date:"date ISO",time:"heure ISO",duration:"dur\\xE9e ISO",ipv4:"adresse IPv4",ipv6:"adresse IPv6",cidrv4:"plage IPv4",cidrv6:"plage IPv6",base64:"cha\\xEEne encod\\xE9e en base64",base64url:"cha\\xEEne encod\\xE9e en base64url",json_string:"cha\\xEEne JSON",e164:"num\\xE9ro E.164",jwt:"JWT",template_literal:"entr\\xE9e"};return t=>{switch(t.code){case"invalid_type":return`Entr\\xE9e invalide : attendu ${t.expected}, re\\xE7u ${r(t.input)}`;case"invalid_value":return t.values.length===1?`Entr\\xE9e invalide : attendu ${x(t.values[0])}`:`Option invalide : attendu l\'une des valeurs suivantes ${h(t.values,"|")}`;case"too_big":{let o=t.inclusive?"\\u2264":"<",a=n(t.origin);return a?`Trop grand : attendu que ${t.origin??"la valeur"} ait ${o}${t.maximum.toString()} ${a.unit}`:`Trop grand : attendu que ${t.origin??"la valeur"} soit ${o}${t.maximum.toString()}`}case"too_small":{let o=t.inclusive?"\\u2265":">",a=n(t.origin);return a?`Trop petit : attendu que ${t.origin} ait ${o}${t.minimum.toString()} ${a.unit}`:`Trop petit : attendu que ${t.origin} soit ${o}${t.minimum.toString()}`}case"invalid_format":{let o=t;return o.format==="starts_with"?`Cha\\xEEne invalide : doit commencer par "${o.prefix}"`:o.format==="ends_with"?`Cha\\xEEne invalide : doit se terminer par "${o.suffix}"`:o.format==="includes"?`Cha\\xEEne invalide : doit inclure "${o.includes}"`:o.format==="regex"?`Cha\\xEEne invalide : doit correspondre au motif ${o.pattern}`:`${i[o.format]??t.format} invalide`}case"not_multiple_of":return`Nombre invalide : doit \\xEAtre un multiple de ${t.divisor}`;case"unrecognized_keys":return`Cl\\xE9${t.keys.length>1?"s":""} non reconnue${t.keys.length>1?"s":""} : ${h(t.keys,", ")}`;case"invalid_key":return`Cl\\xE9 invalide dans ${t.origin}`;case"invalid_union":return"Entr\\xE9e invalide";case"invalid_element":return`Valeur invalide dans ${t.origin}`;default:return"Entr\\xE9e invalide"}}}});function ic(){return{localeError:ff()}}var ff,ac=S(()=>{T();ff=()=>{let e={string:{unit:"\\u05D0\\u05D5\\u05EA\\u05D9\\u05D5\\u05EA",verb:"\\u05DC\\u05DB\\u05DC\\u05D5\\u05DC"},file:{unit:"\\u05D1\\u05D9\\u05D9\\u05D8\\u05D9\\u05DD",verb:"\\u05DC\\u05DB\\u05DC\\u05D5\\u05DC"},array:{unit:"\\u05E4\\u05E8\\u05D9\\u05D8\\u05D9\\u05DD",verb:"\\u05DC\\u05DB\\u05DC\\u05D5\\u05DC"},set:{unit:"\\u05E4\\u05E8\\u05D9\\u05D8\\u05D9\\u05DD",verb:"\\u05DC\\u05DB\\u05DC\\u05D5\\u05DC"}};function n(t){return e[t]??null}let r=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"number";case"object":{if(Array.isArray(t))return"array";if(t===null)return"null";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"\\u05E7\\u05DC\\u05D8",email:"\\u05DB\\u05EA\\u05D5\\u05D1\\u05EA \\u05D0\\u05D9\\u05DE\\u05D9\\u05D9\\u05DC",url:"\\u05DB\\u05EA\\u05D5\\u05D1\\u05EA \\u05E8\\u05E9\\u05EA",emoji:"\\u05D0\\u05D9\\u05DE\\u05D5\\u05D2\'\\u05D9",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"\\u05EA\\u05D0\\u05E8\\u05D9\\u05DA \\u05D5\\u05D6\\u05DE\\u05DF ISO",date:"\\u05EA\\u05D0\\u05E8\\u05D9\\u05DA ISO",time:"\\u05D6\\u05DE\\u05DF ISO",duration:"\\u05DE\\u05E9\\u05DA \\u05D6\\u05DE\\u05DF ISO",ipv4:"\\u05DB\\u05EA\\u05D5\\u05D1\\u05EA IPv4",ipv6:"\\u05DB\\u05EA\\u05D5\\u05D1\\u05EA IPv6",cidrv4:"\\u05D8\\u05D5\\u05D5\\u05D7 IPv4",cidrv6:"\\u05D8\\u05D5\\u05D5\\u05D7 IPv6",base64:"\\u05DE\\u05D7\\u05E8\\u05D5\\u05D6\\u05EA \\u05D1\\u05D1\\u05E1\\u05D9\\u05E1 64",base64url:"\\u05DE\\u05D7\\u05E8\\u05D5\\u05D6\\u05EA \\u05D1\\u05D1\\u05E1\\u05D9\\u05E1 64 \\u05DC\\u05DB\\u05EA\\u05D5\\u05D1\\u05D5\\u05EA \\u05E8\\u05E9\\u05EA",json_string:"\\u05DE\\u05D7\\u05E8\\u05D5\\u05D6\\u05EA JSON",e164:"\\u05DE\\u05E1\\u05E4\\u05E8 E.164",jwt:"JWT",template_literal:"\\u05E7\\u05DC\\u05D8"};return t=>{switch(t.code){case"invalid_type":return`\\u05E7\\u05DC\\u05D8 \\u05DC\\u05D0 \\u05EA\\u05E7\\u05D9\\u05DF: \\u05E6\\u05E8\\u05D9\\u05DA ${t.expected}, \\u05D4\\u05EA\\u05E7\\u05D1\\u05DC ${r(t.input)}`;case"invalid_value":return t.values.length===1?`\\u05E7\\u05DC\\u05D8 \\u05DC\\u05D0 \\u05EA\\u05E7\\u05D9\\u05DF: \\u05E6\\u05E8\\u05D9\\u05DA ${x(t.values[0])}`:`\\u05E7\\u05DC\\u05D8 \\u05DC\\u05D0 \\u05EA\\u05E7\\u05D9\\u05DF: \\u05E6\\u05E8\\u05D9\\u05DA \\u05D0\\u05D7\\u05EA \\u05DE\\u05D4\\u05D0\\u05E4\\u05E9\\u05E8\\u05D5\\u05D9\\u05D5\\u05EA ${h(t.values,"|")}`;case"too_big":{let o=t.inclusive?"<=":"<",a=n(t.origin);return a?`\\u05D2\\u05D3\\u05D5\\u05DC \\u05DE\\u05D3\\u05D9: ${t.origin??"value"} \\u05E6\\u05E8\\u05D9\\u05DA \\u05DC\\u05D4\\u05D9\\u05D5\\u05EA ${o}${t.maximum.toString()} ${a.unit??"elements"}`:`\\u05D2\\u05D3\\u05D5\\u05DC \\u05DE\\u05D3\\u05D9: ${t.origin??"value"} \\u05E6\\u05E8\\u05D9\\u05DA \\u05DC\\u05D4\\u05D9\\u05D5\\u05EA ${o}${t.maximum.toString()}`}case"too_small":{let o=t.inclusive?">=":">",a=n(t.origin);return a?`\\u05E7\\u05D8\\u05DF \\u05DE\\u05D3\\u05D9: ${t.origin} \\u05E6\\u05E8\\u05D9\\u05DA \\u05DC\\u05D4\\u05D9\\u05D5\\u05EA ${o}${t.minimum.toString()} ${a.unit}`:`\\u05E7\\u05D8\\u05DF \\u05DE\\u05D3\\u05D9: ${t.origin} \\u05E6\\u05E8\\u05D9\\u05DA \\u05DC\\u05D4\\u05D9\\u05D5\\u05EA ${o}${t.minimum.toString()}`}case"invalid_format":{let o=t;return o.format==="starts_with"?`\\u05DE\\u05D7\\u05E8\\u05D5\\u05D6\\u05EA \\u05DC\\u05D0 \\u05EA\\u05E7\\u05D9\\u05E0\\u05D4: \\u05D7\\u05D9\\u05D9\\u05D1\\u05EA \\u05DC\\u05D4\\u05EA\\u05D7\\u05D9\\u05DC \\u05D1"${o.prefix}"`:o.format==="ends_with"?`\\u05DE\\u05D7\\u05E8\\u05D5\\u05D6\\u05EA \\u05DC\\u05D0 \\u05EA\\u05E7\\u05D9\\u05E0\\u05D4: \\u05D7\\u05D9\\u05D9\\u05D1\\u05EA \\u05DC\\u05D4\\u05E1\\u05EA\\u05D9\\u05D9\\u05DD \\u05D1 "${o.suffix}"`:o.format==="includes"?`\\u05DE\\u05D7\\u05E8\\u05D5\\u05D6\\u05EA \\u05DC\\u05D0 \\u05EA\\u05E7\\u05D9\\u05E0\\u05D4: \\u05D7\\u05D9\\u05D9\\u05D1\\u05EA \\u05DC\\u05DB\\u05DC\\u05D5\\u05DC "${o.includes}"`:o.format==="regex"?`\\u05DE\\u05D7\\u05E8\\u05D5\\u05D6\\u05EA \\u05DC\\u05D0 \\u05EA\\u05E7\\u05D9\\u05E0\\u05D4: \\u05D7\\u05D9\\u05D9\\u05D1\\u05EA \\u05DC\\u05D4\\u05EA\\u05D0\\u05D9\\u05DD \\u05DC\\u05EA\\u05D1\\u05E0\\u05D9\\u05EA ${o.pattern}`:`${i[o.format]??t.format} \\u05DC\\u05D0 \\u05EA\\u05E7\\u05D9\\u05DF`}case"not_multiple_of":return`\\u05DE\\u05E1\\u05E4\\u05E8 \\u05DC\\u05D0 \\u05EA\\u05E7\\u05D9\\u05DF: \\u05D7\\u05D9\\u05D9\\u05D1 \\u05DC\\u05D4\\u05D9\\u05D5\\u05EA \\u05DE\\u05DB\\u05E4\\u05DC\\u05D4 \\u05E9\\u05DC ${t.divisor}`;case"unrecognized_keys":return`\\u05DE\\u05E4\\u05EA\\u05D7${t.keys.length>1?"\\u05D5\\u05EA":""} \\u05DC\\u05D0 \\u05DE\\u05D6\\u05D5\\u05D4${t.keys.length>1?"\\u05D9\\u05DD":"\\u05D4"}: ${h(t.keys,", ")}`;case"invalid_key":return`\\u05DE\\u05E4\\u05EA\\u05D7 \\u05DC\\u05D0 \\u05EA\\u05E7\\u05D9\\u05DF \\u05D1${t.origin}`;case"invalid_union":return"\\u05E7\\u05DC\\u05D8 \\u05DC\\u05D0 \\u05EA\\u05E7\\u05D9\\u05DF";case"invalid_element":return`\\u05E2\\u05E8\\u05DA \\u05DC\\u05D0 \\u05EA\\u05E7\\u05D9\\u05DF \\u05D1${t.origin}`;default:return"\\u05E7\\u05DC\\u05D8 \\u05DC\\u05D0 \\u05EA\\u05E7\\u05D9\\u05DF"}}}});function sc(){return{localeError:gf()}}var gf,uc=S(()=>{T();gf=()=>{let e={string:{unit:"karakter",verb:"legyen"},file:{unit:"byte",verb:"legyen"},array:{unit:"elem",verb:"legyen"},set:{unit:"elem",verb:"legyen"}};function n(t){return e[t]??null}let r=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"sz\\xE1m";case"object":{if(Array.isArray(t))return"t\\xF6mb";if(t===null)return"null";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"bemenet",email:"email c\\xEDm",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO id\\u0151b\\xE9lyeg",date:"ISO d\\xE1tum",time:"ISO id\\u0151",duration:"ISO id\\u0151intervallum",ipv4:"IPv4 c\\xEDm",ipv6:"IPv6 c\\xEDm",cidrv4:"IPv4 tartom\\xE1ny",cidrv6:"IPv6 tartom\\xE1ny",base64:"base64-k\\xF3dolt string",base64url:"base64url-k\\xF3dolt string",json_string:"JSON string",e164:"E.164 sz\\xE1m",jwt:"JWT",template_literal:"bemenet"};return t=>{switch(t.code){case"invalid_type":return`\\xC9rv\\xE9nytelen bemenet: a v\\xE1rt \\xE9rt\\xE9k ${t.expected}, a kapott \\xE9rt\\xE9k ${r(t.input)}`;case"invalid_value":return t.values.length===1?`\\xC9rv\\xE9nytelen bemenet: a v\\xE1rt \\xE9rt\\xE9k ${x(t.values[0])}`:`\\xC9rv\\xE9nytelen opci\\xF3: valamelyik \\xE9rt\\xE9k v\\xE1rt ${h(t.values,"|")}`;case"too_big":{let o=t.inclusive?"<=":"<",a=n(t.origin);return a?`T\\xFAl nagy: ${t.origin??"\\xE9rt\\xE9k"} m\\xE9rete t\\xFAl nagy ${o}${t.maximum.toString()} ${a.unit??"elem"}`:`T\\xFAl nagy: a bemeneti \\xE9rt\\xE9k ${t.origin??"\\xE9rt\\xE9k"} t\\xFAl nagy: ${o}${t.maximum.toString()}`}case"too_small":{let o=t.inclusive?">=":">",a=n(t.origin);return a?`T\\xFAl kicsi: a bemeneti \\xE9rt\\xE9k ${t.origin} m\\xE9rete t\\xFAl kicsi ${o}${t.minimum.toString()} ${a.unit}`:`T\\xFAl kicsi: a bemeneti \\xE9rt\\xE9k ${t.origin} t\\xFAl kicsi ${o}${t.minimum.toString()}`}case"invalid_format":{let o=t;return o.format==="starts_with"?`\\xC9rv\\xE9nytelen string: "${o.prefix}" \\xE9rt\\xE9kkel kell kezd\\u0151dnie`:o.format==="ends_with"?`\\xC9rv\\xE9nytelen string: "${o.suffix}" \\xE9rt\\xE9kkel kell v\\xE9gz\\u0151dnie`:o.format==="includes"?`\\xC9rv\\xE9nytelen string: "${o.includes}" \\xE9rt\\xE9ket kell tartalmaznia`:o.format==="regex"?`\\xC9rv\\xE9nytelen string: ${o.pattern} mint\\xE1nak kell megfelelnie`:`\\xC9rv\\xE9nytelen ${i[o.format]??t.format}`}case"not_multiple_of":return`\\xC9rv\\xE9nytelen sz\\xE1m: ${t.divisor} t\\xF6bbsz\\xF6r\\xF6s\\xE9nek kell lennie`;case"unrecognized_keys":return`Ismeretlen kulcs${t.keys.length>1?"s":""}: ${h(t.keys,", ")}`;case"invalid_key":return`\\xC9rv\\xE9nytelen kulcs ${t.origin}`;case"invalid_union":return"\\xC9rv\\xE9nytelen bemenet";case"invalid_element":return`\\xC9rv\\xE9nytelen \\xE9rt\\xE9k: ${t.origin}`;default:return"\\xC9rv\\xE9nytelen bemenet"}}}});function lc(){return{localeError:hf()}}var hf,cc=S(()=>{T();hf=()=>{let e={string:{unit:"karakter",verb:"memiliki"},file:{unit:"byte",verb:"memiliki"},array:{unit:"item",verb:"memiliki"},set:{unit:"item",verb:"memiliki"}};function n(t){return e[t]??null}let r=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"number";case"object":{if(Array.isArray(t))return"array";if(t===null)return"null";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"input",email:"alamat email",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"tanggal dan waktu format ISO",date:"tanggal format ISO",time:"jam format ISO",duration:"durasi format ISO",ipv4:"alamat IPv4",ipv6:"alamat IPv6",cidrv4:"rentang alamat IPv4",cidrv6:"rentang alamat IPv6",base64:"string dengan enkode base64",base64url:"string dengan enkode base64url",json_string:"string JSON",e164:"angka E.164",jwt:"JWT",template_literal:"input"};return t=>{switch(t.code){case"invalid_type":return`Input tidak valid: diharapkan ${t.expected}, diterima ${r(t.input)}`;case"invalid_value":return t.values.length===1?`Input tidak valid: diharapkan ${x(t.values[0])}`:`Pilihan tidak valid: diharapkan salah satu dari ${h(t.values,"|")}`;case"too_big":{let o=t.inclusive?"<=":"<",a=n(t.origin);return a?`Terlalu besar: diharapkan ${t.origin??"value"} memiliki ${o}${t.maximum.toString()} ${a.unit??"elemen"}`:`Terlalu besar: diharapkan ${t.origin??"value"} menjadi ${o}${t.maximum.toString()}`}case"too_small":{let o=t.inclusive?">=":">",a=n(t.origin);return a?`Terlalu kecil: diharapkan ${t.origin} memiliki ${o}${t.minimum.toString()} ${a.unit}`:`Terlalu kecil: diharapkan ${t.origin} menjadi ${o}${t.minimum.toString()}`}case"invalid_format":{let o=t;return o.format==="starts_with"?`String tidak valid: harus dimulai dengan "${o.prefix}"`:o.format==="ends_with"?`String tidak valid: harus berakhir dengan "${o.suffix}"`:o.format==="includes"?`String tidak valid: harus menyertakan "${o.includes}"`:o.format==="regex"?`String tidak valid: harus sesuai pola ${o.pattern}`:`${i[o.format]??t.format} tidak valid`}case"not_multiple_of":return`Angka tidak valid: harus kelipatan dari ${t.divisor}`;case"unrecognized_keys":return`Kunci tidak dikenali ${t.keys.length>1?"s":""}: ${h(t.keys,", ")}`;case"invalid_key":return`Kunci tidak valid di ${t.origin}`;case"invalid_union":return"Input tidak valid";case"invalid_element":return`Nilai tidak valid di ${t.origin}`;default:return"Input tidak valid"}}}});function dc(){return{localeError:vf()}}var vf,pc=S(()=>{T();vf=()=>{let e={string:{unit:"caratteri",verb:"avere"},file:{unit:"byte",verb:"avere"},array:{unit:"elementi",verb:"avere"},set:{unit:"elementi",verb:"avere"}};function n(t){return e[t]??null}let r=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"numero";case"object":{if(Array.isArray(t))return"vettore";if(t===null)return"null";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"input",email:"indirizzo email",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"data e ora ISO",date:"data ISO",time:"ora ISO",duration:"durata ISO",ipv4:"indirizzo IPv4",ipv6:"indirizzo IPv6",cidrv4:"intervallo IPv4",cidrv6:"intervallo IPv6",base64:"stringa codificata in base64",base64url:"URL codificata in base64",json_string:"stringa JSON",e164:"numero E.164",jwt:"JWT",template_literal:"input"};return t=>{switch(t.code){case"invalid_type":return`Input non valido: atteso ${t.expected}, ricevuto ${r(t.input)}`;case"invalid_value":return t.values.length===1?`Input non valido: atteso ${x(t.values[0])}`:`Opzione non valida: atteso uno tra ${h(t.values,"|")}`;case"too_big":{let o=t.inclusive?"<=":"<",a=n(t.origin);return a?`Troppo grande: ${t.origin??"valore"} deve avere ${o}${t.maximum.toString()} ${a.unit??"elementi"}`:`Troppo grande: ${t.origin??"valore"} deve essere ${o}${t.maximum.toString()}`}case"too_small":{let o=t.inclusive?">=":">",a=n(t.origin);return a?`Troppo piccolo: ${t.origin} deve avere ${o}${t.minimum.toString()} ${a.unit}`:`Troppo piccolo: ${t.origin} deve essere ${o}${t.minimum.toString()}`}case"invalid_format":{let o=t;return o.format==="starts_with"?`Stringa non valida: deve iniziare con "${o.prefix}"`:o.format==="ends_with"?`Stringa non valida: deve terminare con "${o.suffix}"`:o.format==="includes"?`Stringa non valida: deve includere "${o.includes}"`:o.format==="regex"?`Stringa non valida: deve corrispondere al pattern ${o.pattern}`:`Invalid ${i[o.format]??t.format}`}case"not_multiple_of":return`Numero non valido: deve essere un multiplo di ${t.divisor}`;case"unrecognized_keys":return`Chiav${t.keys.length>1?"i":"e"} non riconosciut${t.keys.length>1?"e":"a"}: ${h(t.keys,", ")}`;case"invalid_key":return`Chiave non valida in ${t.origin}`;case"invalid_union":return"Input non valido";case"invalid_element":return`Valore non valido in ${t.origin}`;default:return"Input non valido"}}}});function mc(){return{localeError:bf()}}var bf,fc=S(()=>{T();bf=()=>{let e={string:{unit:"\\u6587\\u5B57",verb:"\\u3067\\u3042\\u308B"},file:{unit:"\\u30D0\\u30A4\\u30C8",verb:"\\u3067\\u3042\\u308B"},array:{unit:"\\u8981\\u7D20",verb:"\\u3067\\u3042\\u308B"},set:{unit:"\\u8981\\u7D20",verb:"\\u3067\\u3042\\u308B"}};function n(t){return e[t]??null}let r=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"\\u6570\\u5024";case"object":{if(Array.isArray(t))return"\\u914D\\u5217";if(t===null)return"null";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"\\u5165\\u529B\\u5024",email:"\\u30E1\\u30FC\\u30EB\\u30A2\\u30C9\\u30EC\\u30B9",url:"URL",emoji:"\\u7D75\\u6587\\u5B57",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO\\u65E5\\u6642",date:"ISO\\u65E5\\u4ED8",time:"ISO\\u6642\\u523B",duration:"ISO\\u671F\\u9593",ipv4:"IPv4\\u30A2\\u30C9\\u30EC\\u30B9",ipv6:"IPv6\\u30A2\\u30C9\\u30EC\\u30B9",cidrv4:"IPv4\\u7BC4\\u56F2",cidrv6:"IPv6\\u7BC4\\u56F2",base64:"base64\\u30A8\\u30F3\\u30B3\\u30FC\\u30C9\\u6587\\u5B57\\u5217",base64url:"base64url\\u30A8\\u30F3\\u30B3\\u30FC\\u30C9\\u6587\\u5B57\\u5217",json_string:"JSON\\u6587\\u5B57\\u5217",e164:"E.164\\u756A\\u53F7",jwt:"JWT",template_literal:"\\u5165\\u529B\\u5024"};return t=>{switch(t.code){case"invalid_type":return`\\u7121\\u52B9\\u306A\\u5165\\u529B: ${t.expected}\\u304C\\u671F\\u5F85\\u3055\\u308C\\u307E\\u3057\\u305F\\u304C\\u3001${r(t.input)}\\u304C\\u5165\\u529B\\u3055\\u308C\\u307E\\u3057\\u305F`;case"invalid_value":return t.values.length===1?`\\u7121\\u52B9\\u306A\\u5165\\u529B: ${x(t.values[0])}\\u304C\\u671F\\u5F85\\u3055\\u308C\\u307E\\u3057\\u305F`:`\\u7121\\u52B9\\u306A\\u9078\\u629E: ${h(t.values,"\\u3001")}\\u306E\\u3044\\u305A\\u308C\\u304B\\u3067\\u3042\\u308B\\u5FC5\\u8981\\u304C\\u3042\\u308A\\u307E\\u3059`;case"too_big":{let o=t.inclusive?"\\u4EE5\\u4E0B\\u3067\\u3042\\u308B":"\\u3088\\u308A\\u5C0F\\u3055\\u3044",a=n(t.origin);return a?`\\u5927\\u304D\\u3059\\u304E\\u308B\\u5024: ${t.origin??"\\u5024"}\\u306F${t.maximum.toString()}${a.unit??"\\u8981\\u7D20"}${o}\\u5FC5\\u8981\\u304C\\u3042\\u308A\\u307E\\u3059`:`\\u5927\\u304D\\u3059\\u304E\\u308B\\u5024: ${t.origin??"\\u5024"}\\u306F${t.maximum.toString()}${o}\\u5FC5\\u8981\\u304C\\u3042\\u308A\\u307E\\u3059`}case"too_small":{let o=t.inclusive?"\\u4EE5\\u4E0A\\u3067\\u3042\\u308B":"\\u3088\\u308A\\u5927\\u304D\\u3044",a=n(t.origin);return a?`\\u5C0F\\u3055\\u3059\\u304E\\u308B\\u5024: ${t.origin}\\u306F${t.minimum.toString()}${a.unit}${o}\\u5FC5\\u8981\\u304C\\u3042\\u308A\\u307E\\u3059`:`\\u5C0F\\u3055\\u3059\\u304E\\u308B\\u5024: ${t.origin}\\u306F${t.minimum.toString()}${o}\\u5FC5\\u8981\\u304C\\u3042\\u308A\\u307E\\u3059`}case"invalid_format":{let o=t;return o.format==="starts_with"?`\\u7121\\u52B9\\u306A\\u6587\\u5B57\\u5217: "${o.prefix}"\\u3067\\u59CB\\u307E\\u308B\\u5FC5\\u8981\\u304C\\u3042\\u308A\\u307E\\u3059`:o.format==="ends_with"?`\\u7121\\u52B9\\u306A\\u6587\\u5B57\\u5217: "${o.suffix}"\\u3067\\u7D42\\u308F\\u308B\\u5FC5\\u8981\\u304C\\u3042\\u308A\\u307E\\u3059`:o.format==="includes"?`\\u7121\\u52B9\\u306A\\u6587\\u5B57\\u5217: "${o.includes}"\\u3092\\u542B\\u3080\\u5FC5\\u8981\\u304C\\u3042\\u308A\\u307E\\u3059`:o.format==="regex"?`\\u7121\\u52B9\\u306A\\u6587\\u5B57\\u5217: \\u30D1\\u30BF\\u30FC\\u30F3${o.pattern}\\u306B\\u4E00\\u81F4\\u3059\\u308B\\u5FC5\\u8981\\u304C\\u3042\\u308A\\u307E\\u3059`:`\\u7121\\u52B9\\u306A${i[o.format]??t.format}`}case"not_multiple_of":return`\\u7121\\u52B9\\u306A\\u6570\\u5024: ${t.divisor}\\u306E\\u500D\\u6570\\u3067\\u3042\\u308B\\u5FC5\\u8981\\u304C\\u3042\\u308A\\u307E\\u3059`;case"unrecognized_keys":return`\\u8A8D\\u8B58\\u3055\\u308C\\u3066\\u3044\\u306A\\u3044\\u30AD\\u30FC${t.keys.length>1?"\\u7FA4":""}: ${h(t.keys,"\\u3001")}`;case"invalid_key":return`${t.origin}\\u5185\\u306E\\u7121\\u52B9\\u306A\\u30AD\\u30FC`;case"invalid_union":return"\\u7121\\u52B9\\u306A\\u5165\\u529B";case"invalid_element":return`${t.origin}\\u5185\\u306E\\u7121\\u52B9\\u306A\\u5024`;default:return"\\u7121\\u52B9\\u306A\\u5165\\u529B"}}}});function gc(){return{localeError:yf()}}var yf,hc=S(()=>{T();yf=()=>{let e={string:{unit:"\\u178F\\u17BD\\u17A2\\u1780\\u17D2\\u179F\\u179A",verb:"\\u1782\\u17BD\\u179A\\u1798\\u17B6\\u1793"},file:{unit:"\\u1794\\u17C3",verb:"\\u1782\\u17BD\\u179A\\u1798\\u17B6\\u1793"},array:{unit:"\\u1792\\u17B6\\u178F\\u17BB",verb:"\\u1782\\u17BD\\u179A\\u1798\\u17B6\\u1793"},set:{unit:"\\u1792\\u17B6\\u178F\\u17BB",verb:"\\u1782\\u17BD\\u179A\\u1798\\u17B6\\u1793"}};function n(t){return e[t]??null}let r=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"\\u1798\\u17B7\\u1793\\u1798\\u17C2\\u1793\\u1787\\u17B6\\u179B\\u17C1\\u1781 (NaN)":"\\u179B\\u17C1\\u1781";case"object":{if(Array.isArray(t))return"\\u17A2\\u17B6\\u179A\\u17C1 (Array)";if(t===null)return"\\u1782\\u17D2\\u1798\\u17B6\\u1793\\u178F\\u1798\\u17D2\\u179B\\u17C3 (null)";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"\\u1791\\u17B7\\u1793\\u17D2\\u1793\\u1793\\u17D0\\u1799\\u1794\\u1789\\u17D2\\u1785\\u17BC\\u179B",email:"\\u17A2\\u17B6\\u179F\\u1799\\u178A\\u17D2\\u178B\\u17B6\\u1793\\u17A2\\u17CA\\u17B8\\u1798\\u17C2\\u179B",url:"URL",emoji:"\\u179F\\u1789\\u17D2\\u1789\\u17B6\\u17A2\\u17B6\\u179A\\u1798\\u17D2\\u1798\\u178E\\u17CD",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"\\u1780\\u17B6\\u179B\\u1794\\u179A\\u17B7\\u1785\\u17D2\\u1786\\u17C1\\u1791 \\u1793\\u17B7\\u1784\\u1798\\u17C9\\u17C4\\u1784 ISO",date:"\\u1780\\u17B6\\u179B\\u1794\\u179A\\u17B7\\u1785\\u17D2\\u1786\\u17C1\\u1791 ISO",time:"\\u1798\\u17C9\\u17C4\\u1784 ISO",duration:"\\u179A\\u1799\\u17C8\\u1796\\u17C1\\u179B ISO",ipv4:"\\u17A2\\u17B6\\u179F\\u1799\\u178A\\u17D2\\u178B\\u17B6\\u1793 IPv4",ipv6:"\\u17A2\\u17B6\\u179F\\u1799\\u178A\\u17D2\\u178B\\u17B6\\u1793 IPv6",cidrv4:"\\u178A\\u17C2\\u1793\\u17A2\\u17B6\\u179F\\u1799\\u178A\\u17D2\\u178B\\u17B6\\u1793 IPv4",cidrv6:"\\u178A\\u17C2\\u1793\\u17A2\\u17B6\\u179F\\u1799\\u178A\\u17D2\\u178B\\u17B6\\u1793 IPv6",base64:"\\u1781\\u17D2\\u179F\\u17C2\\u17A2\\u1780\\u17D2\\u179F\\u179A\\u17A2\\u17CA\\u17B7\\u1780\\u17BC\\u178A base64",base64url:"\\u1781\\u17D2\\u179F\\u17C2\\u17A2\\u1780\\u17D2\\u179F\\u179A\\u17A2\\u17CA\\u17B7\\u1780\\u17BC\\u178A base64url",json_string:"\\u1781\\u17D2\\u179F\\u17C2\\u17A2\\u1780\\u17D2\\u179F\\u179A JSON",e164:"\\u179B\\u17C1\\u1781 E.164",jwt:"JWT",template_literal:"\\u1791\\u17B7\\u1793\\u17D2\\u1793\\u1793\\u17D0\\u1799\\u1794\\u1789\\u17D2\\u1785\\u17BC\\u179B"};return t=>{switch(t.code){case"invalid_type":return`\\u1791\\u17B7\\u1793\\u17D2\\u1793\\u1793\\u17D0\\u1799\\u1794\\u1789\\u17D2\\u1785\\u17BC\\u179B\\u1798\\u17B7\\u1793\\u178F\\u17D2\\u179A\\u17B9\\u1798\\u178F\\u17D2\\u179A\\u17BC\\u179C\\u17D6 \\u178F\\u17D2\\u179A\\u17BC\\u179C\\u1780\\u17B6\\u179A ${t.expected} \\u1794\\u17C9\\u17BB\\u1793\\u17D2\\u178F\\u17C2\\u1791\\u1791\\u17BD\\u179B\\u1794\\u17B6\\u1793 ${r(t.input)}`;case"invalid_value":return t.values.length===1?`\\u1791\\u17B7\\u1793\\u17D2\\u1793\\u1793\\u17D0\\u1799\\u1794\\u1789\\u17D2\\u1785\\u17BC\\u179B\\u1798\\u17B7\\u1793\\u178F\\u17D2\\u179A\\u17B9\\u1798\\u178F\\u17D2\\u179A\\u17BC\\u179C\\u17D6 \\u178F\\u17D2\\u179A\\u17BC\\u179C\\u1780\\u17B6\\u179A ${x(t.values[0])}`:`\\u1787\\u1798\\u17D2\\u179A\\u17BE\\u179F\\u1798\\u17B7\\u1793\\u178F\\u17D2\\u179A\\u17B9\\u1798\\u178F\\u17D2\\u179A\\u17BC\\u179C\\u17D6 \\u178F\\u17D2\\u179A\\u17BC\\u179C\\u1787\\u17B6\\u1798\\u17BD\\u1799\\u1780\\u17D2\\u1793\\u17BB\\u1784\\u1785\\u17C6\\u178E\\u17C4\\u1798 ${h(t.values,"|")}`;case"too_big":{let o=t.inclusive?"<=":"<",a=n(t.origin);return a?`\\u1792\\u17C6\\u1796\\u17C1\\u1780\\u17D6 \\u178F\\u17D2\\u179A\\u17BC\\u179C\\u1780\\u17B6\\u179A ${t.origin??"\\u178F\\u1798\\u17D2\\u179B\\u17C3"} ${o} ${t.maximum.toString()} ${a.unit??"\\u1792\\u17B6\\u178F\\u17BB"}`:`\\u1792\\u17C6\\u1796\\u17C1\\u1780\\u17D6 \\u178F\\u17D2\\u179A\\u17BC\\u179C\\u1780\\u17B6\\u179A ${t.origin??"\\u178F\\u1798\\u17D2\\u179B\\u17C3"} ${o} ${t.maximum.toString()}`}case"too_small":{let o=t.inclusive?">=":">",a=n(t.origin);return a?`\\u178F\\u17BC\\u1785\\u1796\\u17C1\\u1780\\u17D6 \\u178F\\u17D2\\u179A\\u17BC\\u179C\\u1780\\u17B6\\u179A ${t.origin} ${o} ${t.minimum.toString()} ${a.unit}`:`\\u178F\\u17BC\\u1785\\u1796\\u17C1\\u1780\\u17D6 \\u178F\\u17D2\\u179A\\u17BC\\u179C\\u1780\\u17B6\\u179A ${t.origin} ${o} ${t.minimum.toString()}`}case"invalid_format":{let o=t;return o.format==="starts_with"?`\\u1781\\u17D2\\u179F\\u17C2\\u17A2\\u1780\\u17D2\\u179F\\u179A\\u1798\\u17B7\\u1793\\u178F\\u17D2\\u179A\\u17B9\\u1798\\u178F\\u17D2\\u179A\\u17BC\\u179C\\u17D6 \\u178F\\u17D2\\u179A\\u17BC\\u179C\\u1785\\u17B6\\u1794\\u17CB\\u1795\\u17D2\\u178F\\u17BE\\u1798\\u178A\\u17C4\\u1799 "${o.prefix}"`:o.format==="ends_with"?`\\u1781\\u17D2\\u179F\\u17C2\\u17A2\\u1780\\u17D2\\u179F\\u179A\\u1798\\u17B7\\u1793\\u178F\\u17D2\\u179A\\u17B9\\u1798\\u178F\\u17D2\\u179A\\u17BC\\u179C\\u17D6 \\u178F\\u17D2\\u179A\\u17BC\\u179C\\u1794\\u1789\\u17D2\\u1785\\u1794\\u17CB\\u178A\\u17C4\\u1799 "${o.suffix}"`:o.format==="includes"?`\\u1781\\u17D2\\u179F\\u17C2\\u17A2\\u1780\\u17D2\\u179F\\u179A\\u1798\\u17B7\\u1793\\u178F\\u17D2\\u179A\\u17B9\\u1798\\u178F\\u17D2\\u179A\\u17BC\\u179C\\u17D6 \\u178F\\u17D2\\u179A\\u17BC\\u179C\\u1798\\u17B6\\u1793 "${o.includes}"`:o.format==="regex"?`\\u1781\\u17D2\\u179F\\u17C2\\u17A2\\u1780\\u17D2\\u179F\\u179A\\u1798\\u17B7\\u1793\\u178F\\u17D2\\u179A\\u17B9\\u1798\\u178F\\u17D2\\u179A\\u17BC\\u179C\\u17D6 \\u178F\\u17D2\\u179A\\u17BC\\u179C\\u178F\\u17C2\\u1795\\u17D2\\u1782\\u17BC\\u1795\\u17D2\\u1782\\u1784\\u1793\\u17B9\\u1784\\u1791\\u1798\\u17D2\\u179A\\u1784\\u17CB\\u178A\\u17C2\\u179B\\u1794\\u17B6\\u1793\\u1780\\u17C6\\u178E\\u178F\\u17CB ${o.pattern}`:`\\u1798\\u17B7\\u1793\\u178F\\u17D2\\u179A\\u17B9\\u1798\\u178F\\u17D2\\u179A\\u17BC\\u179C\\u17D6 ${i[o.format]??t.format}`}case"not_multiple_of":return`\\u179B\\u17C1\\u1781\\u1798\\u17B7\\u1793\\u178F\\u17D2\\u179A\\u17B9\\u1798\\u178F\\u17D2\\u179A\\u17BC\\u179C\\u17D6 \\u178F\\u17D2\\u179A\\u17BC\\u179C\\u178F\\u17C2\\u1787\\u17B6\\u1796\\u17A0\\u17BB\\u1782\\u17BB\\u178E\\u1793\\u17C3 ${t.divisor}`;case"unrecognized_keys":return`\\u179A\\u1780\\u1783\\u17BE\\u1789\\u179F\\u17C4\\u1798\\u17B7\\u1793\\u179F\\u17D2\\u1782\\u17B6\\u179B\\u17CB\\u17D6 ${h(t.keys,", ")}`;case"invalid_key":return`\\u179F\\u17C4\\u1798\\u17B7\\u1793\\u178F\\u17D2\\u179A\\u17B9\\u1798\\u178F\\u17D2\\u179A\\u17BC\\u179C\\u1793\\u17C5\\u1780\\u17D2\\u1793\\u17BB\\u1784 ${t.origin}`;case"invalid_union":return"\\u1791\\u17B7\\u1793\\u17D2\\u1793\\u1793\\u17D0\\u1799\\u1798\\u17B7\\u1793\\u178F\\u17D2\\u179A\\u17B9\\u1798\\u178F\\u17D2\\u179A\\u17BC\\u179C";case"invalid_element":return`\\u1791\\u17B7\\u1793\\u17D2\\u1793\\u1793\\u17D0\\u1799\\u1798\\u17B7\\u1793\\u178F\\u17D2\\u179A\\u17B9\\u1798\\u178F\\u17D2\\u179A\\u17BC\\u179C\\u1793\\u17C5\\u1780\\u17D2\\u1793\\u17BB\\u1784 ${t.origin}`;default:return"\\u1791\\u17B7\\u1793\\u17D2\\u1793\\u1793\\u17D0\\u1799\\u1798\\u17B7\\u1793\\u178F\\u17D2\\u179A\\u17B9\\u1798\\u178F\\u17D2\\u179A\\u17BC\\u179C"}}}});function vc(){return{localeError:xf()}}var xf,bc=S(()=>{T();xf=()=>{let e={string:{unit:"\\uBB38\\uC790",verb:"to have"},file:{unit:"\\uBC14\\uC774\\uD2B8",verb:"to have"},array:{unit:"\\uAC1C",verb:"to have"},set:{unit:"\\uAC1C",verb:"to have"}};function n(t){return e[t]??null}let r=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"number";case"object":{if(Array.isArray(t))return"array";if(t===null)return"null";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"\\uC785\\uB825",email:"\\uC774\\uBA54\\uC77C \\uC8FC\\uC18C",url:"URL",emoji:"\\uC774\\uBAA8\\uC9C0",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO \\uB0A0\\uC9DC\\uC2DC\\uAC04",date:"ISO \\uB0A0\\uC9DC",time:"ISO \\uC2DC\\uAC04",duration:"ISO \\uAE30\\uAC04",ipv4:"IPv4 \\uC8FC\\uC18C",ipv6:"IPv6 \\uC8FC\\uC18C",cidrv4:"IPv4 \\uBC94\\uC704",cidrv6:"IPv6 \\uBC94\\uC704",base64:"base64 \\uC778\\uCF54\\uB529 \\uBB38\\uC790\\uC5F4",base64url:"base64url \\uC778\\uCF54\\uB529 \\uBB38\\uC790\\uC5F4",json_string:"JSON \\uBB38\\uC790\\uC5F4",e164:"E.164 \\uBC88\\uD638",jwt:"JWT",template_literal:"\\uC785\\uB825"};return t=>{switch(t.code){case"invalid_type":return`\\uC798\\uBABB\\uB41C \\uC785\\uB825: \\uC608\\uC0C1 \\uD0C0\\uC785\\uC740 ${t.expected}, \\uBC1B\\uC740 \\uD0C0\\uC785\\uC740 ${r(t.input)}\\uC785\\uB2C8\\uB2E4`;case"invalid_value":return t.values.length===1?`\\uC798\\uBABB\\uB41C \\uC785\\uB825: \\uAC12\\uC740 ${x(t.values[0])} \\uC774\\uC5B4\\uC57C \\uD569\\uB2C8\\uB2E4`:`\\uC798\\uBABB\\uB41C \\uC635\\uC158: ${h(t.values,"\\uB610\\uB294 ")} \\uC911 \\uD558\\uB098\\uC5EC\\uC57C \\uD569\\uB2C8\\uB2E4`;case"too_big":{let o=t.inclusive?"\\uC774\\uD558":"\\uBBF8\\uB9CC",a=o==="\\uBBF8\\uB9CC"?"\\uC774\\uC5B4\\uC57C \\uD569\\uB2C8\\uB2E4":"\\uC5EC\\uC57C \\uD569\\uB2C8\\uB2E4",u=n(t.origin),c=u?.unit??"\\uC694\\uC18C";return u?`${t.origin??"\\uAC12"}\\uC774 \\uB108\\uBB34 \\uD07D\\uB2C8\\uB2E4: ${t.maximum.toString()}${c} ${o}${a}`:`${t.origin??"\\uAC12"}\\uC774 \\uB108\\uBB34 \\uD07D\\uB2C8\\uB2E4: ${t.maximum.toString()} ${o}${a}`}case"too_small":{let o=t.inclusive?"\\uC774\\uC0C1":"\\uCD08\\uACFC",a=o==="\\uC774\\uC0C1"?"\\uC774\\uC5B4\\uC57C \\uD569\\uB2C8\\uB2E4":"\\uC5EC\\uC57C \\uD569\\uB2C8\\uB2E4",u=n(t.origin),c=u?.unit??"\\uC694\\uC18C";return u?`${t.origin??"\\uAC12"}\\uC774 \\uB108\\uBB34 \\uC791\\uC2B5\\uB2C8\\uB2E4: ${t.minimum.toString()}${c} ${o}${a}`:`${t.origin??"\\uAC12"}\\uC774 \\uB108\\uBB34 \\uC791\\uC2B5\\uB2C8\\uB2E4: ${t.minimum.toString()} ${o}${a}`}case"invalid_format":{let o=t;return o.format==="starts_with"?`\\uC798\\uBABB\\uB41C \\uBB38\\uC790\\uC5F4: "${o.prefix}"(\\uC73C)\\uB85C \\uC2DC\\uC791\\uD574\\uC57C \\uD569\\uB2C8\\uB2E4`:o.format==="ends_with"?`\\uC798\\uBABB\\uB41C \\uBB38\\uC790\\uC5F4: "${o.suffix}"(\\uC73C)\\uB85C \\uB05D\\uB098\\uC57C \\uD569\\uB2C8\\uB2E4`:o.format==="includes"?`\\uC798\\uBABB\\uB41C \\uBB38\\uC790\\uC5F4: "${o.includes}"\\uC744(\\uB97C) \\uD3EC\\uD568\\uD574\\uC57C \\uD569\\uB2C8\\uB2E4`:o.format==="regex"?`\\uC798\\uBABB\\uB41C \\uBB38\\uC790\\uC5F4: \\uC815\\uADDC\\uC2DD ${o.pattern} \\uD328\\uD134\\uACFC \\uC77C\\uCE58\\uD574\\uC57C \\uD569\\uB2C8\\uB2E4`:`\\uC798\\uBABB\\uB41C ${i[o.format]??t.format}`}case"not_multiple_of":return`\\uC798\\uBABB\\uB41C \\uC22B\\uC790: ${t.divisor}\\uC758 \\uBC30\\uC218\\uC5EC\\uC57C \\uD569\\uB2C8\\uB2E4`;case"unrecognized_keys":return`\\uC778\\uC2DD\\uD560 \\uC218 \\uC5C6\\uB294 \\uD0A4: ${h(t.keys,", ")}`;case"invalid_key":return`\\uC798\\uBABB\\uB41C \\uD0A4: ${t.origin}`;case"invalid_union":return"\\uC798\\uBABB\\uB41C \\uC785\\uB825";case"invalid_element":return`\\uC798\\uBABB\\uB41C \\uAC12: ${t.origin}`;default:return"\\uC798\\uBABB\\uB41C \\uC785\\uB825"}}}});function yc(){return{localeError:_f()}}var _f,xc=S(()=>{T();_f=()=>{let e={string:{unit:"\\u0437\\u043D\\u0430\\u0446\\u0438",verb:"\\u0434\\u0430 \\u0438\\u043C\\u0430\\u0430\\u0442"},file:{unit:"\\u0431\\u0430\\u0458\\u0442\\u0438",verb:"\\u0434\\u0430 \\u0438\\u043C\\u0430\\u0430\\u0442"},array:{unit:"\\u0441\\u0442\\u0430\\u0432\\u043A\\u0438",verb:"\\u0434\\u0430 \\u0438\\u043C\\u0430\\u0430\\u0442"},set:{unit:"\\u0441\\u0442\\u0430\\u0432\\u043A\\u0438",verb:"\\u0434\\u0430 \\u0438\\u043C\\u0430\\u0430\\u0442"}};function n(t){return e[t]??null}let r=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"\\u0431\\u0440\\u043E\\u0458";case"object":{if(Array.isArray(t))return"\\u043D\\u0438\\u0437\\u0430";if(t===null)return"null";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"\\u0432\\u043D\\u0435\\u0441",email:"\\u0430\\u0434\\u0440\\u0435\\u0441\\u0430 \\u043D\\u0430 \\u0435-\\u043F\\u043E\\u0448\\u0442\\u0430",url:"URL",emoji:"\\u0435\\u043C\\u043E\\u045F\\u0438",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO \\u0434\\u0430\\u0442\\u0443\\u043C \\u0438 \\u0432\\u0440\\u0435\\u043C\\u0435",date:"ISO \\u0434\\u0430\\u0442\\u0443\\u043C",time:"ISO \\u0432\\u0440\\u0435\\u043C\\u0435",duration:"ISO \\u0432\\u0440\\u0435\\u043C\\u0435\\u0442\\u0440\\u0430\\u0435\\u045A\\u0435",ipv4:"IPv4 \\u0430\\u0434\\u0440\\u0435\\u0441\\u0430",ipv6:"IPv6 \\u0430\\u0434\\u0440\\u0435\\u0441\\u0430",cidrv4:"IPv4 \\u043E\\u043F\\u0441\\u0435\\u0433",cidrv6:"IPv6 \\u043E\\u043F\\u0441\\u0435\\u0433",base64:"base64-\\u0435\\u043D\\u043A\\u043E\\u0434\\u0438\\u0440\\u0430\\u043D\\u0430 \\u043D\\u0438\\u0437\\u0430",base64url:"base64url-\\u0435\\u043D\\u043A\\u043E\\u0434\\u0438\\u0440\\u0430\\u043D\\u0430 \\u043D\\u0438\\u0437\\u0430",json_string:"JSON \\u043D\\u0438\\u0437\\u0430",e164:"E.164 \\u0431\\u0440\\u043E\\u0458",jwt:"JWT",template_literal:"\\u0432\\u043D\\u0435\\u0441"};return t=>{switch(t.code){case"invalid_type":return`\\u0413\\u0440\\u0435\\u0448\\u0435\\u043D \\u0432\\u043D\\u0435\\u0441: \\u0441\\u0435 \\u043E\\u0447\\u0435\\u043A\\u0443\\u0432\\u0430 ${t.expected}, \\u043F\\u0440\\u0438\\u043C\\u0435\\u043D\\u043E ${r(t.input)}`;case"invalid_value":return t.values.length===1?`Invalid input: expected ${x(t.values[0])}`:`\\u0413\\u0440\\u0435\\u0448\\u0430\\u043D\\u0430 \\u043E\\u043F\\u0446\\u0438\\u0458\\u0430: \\u0441\\u0435 \\u043E\\u0447\\u0435\\u043A\\u0443\\u0432\\u0430 \\u0435\\u0434\\u043D\\u0430 ${h(t.values,"|")}`;case"too_big":{let o=t.inclusive?"<=":"<",a=n(t.origin);return a?`\\u041F\\u0440\\u0435\\u043C\\u043D\\u043E\\u0433\\u0443 \\u0433\\u043E\\u043B\\u0435\\u043C: \\u0441\\u0435 \\u043E\\u0447\\u0435\\u043A\\u0443\\u0432\\u0430 ${t.origin??"\\u0432\\u0440\\u0435\\u0434\\u043D\\u043E\\u0441\\u0442\\u0430"} \\u0434\\u0430 \\u0438\\u043C\\u0430 ${o}${t.maximum.toString()} ${a.unit??"\\u0435\\u043B\\u0435\\u043C\\u0435\\u043D\\u0442\\u0438"}`:`\\u041F\\u0440\\u0435\\u043C\\u043D\\u043E\\u0433\\u0443 \\u0433\\u043E\\u043B\\u0435\\u043C: \\u0441\\u0435 \\u043E\\u0447\\u0435\\u043A\\u0443\\u0432\\u0430 ${t.origin??"\\u0432\\u0440\\u0435\\u0434\\u043D\\u043E\\u0441\\u0442\\u0430"} \\u0434\\u0430 \\u0431\\u0438\\u0434\\u0435 ${o}${t.maximum.toString()}`}case"too_small":{let o=t.inclusive?">=":">",a=n(t.origin);return a?`\\u041F\\u0440\\u0435\\u043C\\u043D\\u043E\\u0433\\u0443 \\u043C\\u0430\\u043B: \\u0441\\u0435 \\u043E\\u0447\\u0435\\u043A\\u0443\\u0432\\u0430 ${t.origin} \\u0434\\u0430 \\u0438\\u043C\\u0430 ${o}${t.minimum.toString()} ${a.unit}`:`\\u041F\\u0440\\u0435\\u043C\\u043D\\u043E\\u0433\\u0443 \\u043C\\u0430\\u043B: \\u0441\\u0435 \\u043E\\u0447\\u0435\\u043A\\u0443\\u0432\\u0430 ${t.origin} \\u0434\\u0430 \\u0431\\u0438\\u0434\\u0435 ${o}${t.minimum.toString()}`}case"invalid_format":{let o=t;return o.format==="starts_with"?`\\u041D\\u0435\\u0432\\u0430\\u0436\\u0435\\u0447\\u043A\\u0430 \\u043D\\u0438\\u0437\\u0430: \\u043C\\u043E\\u0440\\u0430 \\u0434\\u0430 \\u0437\\u0430\\u043F\\u043E\\u0447\\u043D\\u0443\\u0432\\u0430 \\u0441\\u043E "${o.prefix}"`:o.format==="ends_with"?`\\u041D\\u0435\\u0432\\u0430\\u0436\\u0435\\u0447\\u043A\\u0430 \\u043D\\u0438\\u0437\\u0430: \\u043C\\u043E\\u0440\\u0430 \\u0434\\u0430 \\u0437\\u0430\\u0432\\u0440\\u0448\\u0443\\u0432\\u0430 \\u0441\\u043E "${o.suffix}"`:o.format==="includes"?`\\u041D\\u0435\\u0432\\u0430\\u0436\\u0435\\u0447\\u043A\\u0430 \\u043D\\u0438\\u0437\\u0430: \\u043C\\u043E\\u0440\\u0430 \\u0434\\u0430 \\u0432\\u043A\\u043B\\u0443\\u0447\\u0443\\u0432\\u0430 "${o.includes}"`:o.format==="regex"?`\\u041D\\u0435\\u0432\\u0430\\u0436\\u0435\\u0447\\u043A\\u0430 \\u043D\\u0438\\u0437\\u0430: \\u043C\\u043E\\u0440\\u0430 \\u0434\\u0430 \\u043E\\u0434\\u0433\\u043E\\u0430\\u0440\\u0430 \\u043D\\u0430 \\u043F\\u0430\\u0442\\u0435\\u0440\\u043D\\u043E\\u0442 ${o.pattern}`:`Invalid ${i[o.format]??t.format}`}case"not_multiple_of":return`\\u0413\\u0440\\u0435\\u0448\\u0435\\u043D \\u0431\\u0440\\u043E\\u0458: \\u043C\\u043E\\u0440\\u0430 \\u0434\\u0430 \\u0431\\u0438\\u0434\\u0435 \\u0434\\u0435\\u043B\\u0438\\u0432 \\u0441\\u043E ${t.divisor}`;case"unrecognized_keys":return`${t.keys.length>1?"\\u041D\\u0435\\u043F\\u0440\\u0435\\u043F\\u043E\\u0437\\u043D\\u0430\\u0435\\u043D\\u0438 \\u043A\\u043B\\u0443\\u0447\\u0435\\u0432\\u0438":"\\u041D\\u0435\\u043F\\u0440\\u0435\\u043F\\u043E\\u0437\\u043D\\u0430\\u0435\\u043D \\u043A\\u043B\\u0443\\u0447"}: ${h(t.keys,", ")}`;case"invalid_key":return`\\u0413\\u0440\\u0435\\u0448\\u0435\\u043D \\u043A\\u043B\\u0443\\u0447 \\u0432\\u043E ${t.origin}`;case"invalid_union":return"\\u0413\\u0440\\u0435\\u0448\\u0435\\u043D \\u0432\\u043D\\u0435\\u0441";case"invalid_element":return`\\u0413\\u0440\\u0435\\u0448\\u043D\\u0430 \\u0432\\u0440\\u0435\\u0434\\u043D\\u043E\\u0441\\u0442 \\u0432\\u043E ${t.origin}`;default:return"\\u0413\\u0440\\u0435\\u0448\\u0435\\u043D \\u0432\\u043D\\u0435\\u0441"}}}});function _c(){return{localeError:$f()}}var $f,$c=S(()=>{T();$f=()=>{let e={string:{unit:"aksara",verb:"mempunyai"},file:{unit:"bait",verb:"mempunyai"},array:{unit:"elemen",verb:"mempunyai"},set:{unit:"elemen",verb:"mempunyai"}};function n(t){return e[t]??null}let r=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"nombor";case"object":{if(Array.isArray(t))return"array";if(t===null)return"null";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"input",email:"alamat e-mel",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"tarikh masa ISO",date:"tarikh ISO",time:"masa ISO",duration:"tempoh ISO",ipv4:"alamat IPv4",ipv6:"alamat IPv6",cidrv4:"julat IPv4",cidrv6:"julat IPv6",base64:"string dikodkan base64",base64url:"string dikodkan base64url",json_string:"string JSON",e164:"nombor E.164",jwt:"JWT",template_literal:"input"};return t=>{switch(t.code){case"invalid_type":return`Input tidak sah: dijangka ${t.expected}, diterima ${r(t.input)}`;case"invalid_value":return t.values.length===1?`Input tidak sah: dijangka ${x(t.values[0])}`:`Pilihan tidak sah: dijangka salah satu daripada ${h(t.values,"|")}`;case"too_big":{let o=t.inclusive?"<=":"<",a=n(t.origin);return a?`Terlalu besar: dijangka ${t.origin??"nilai"} ${a.verb} ${o}${t.maximum.toString()} ${a.unit??"elemen"}`:`Terlalu besar: dijangka ${t.origin??"nilai"} adalah ${o}${t.maximum.toString()}`}case"too_small":{let o=t.inclusive?">=":">",a=n(t.origin);return a?`Terlalu kecil: dijangka ${t.origin} ${a.verb} ${o}${t.minimum.toString()} ${a.unit}`:`Terlalu kecil: dijangka ${t.origin} adalah ${o}${t.minimum.toString()}`}case"invalid_format":{let o=t;return o.format==="starts_with"?`String tidak sah: mesti bermula dengan "${o.prefix}"`:o.format==="ends_with"?`String tidak sah: mesti berakhir dengan "${o.suffix}"`:o.format==="includes"?`String tidak sah: mesti mengandungi "${o.includes}"`:o.format==="regex"?`String tidak sah: mesti sepadan dengan corak ${o.pattern}`:`${i[o.format]??t.format} tidak sah`}case"not_multiple_of":return`Nombor tidak sah: perlu gandaan ${t.divisor}`;case"unrecognized_keys":return`Kunci tidak dikenali: ${h(t.keys,", ")}`;case"invalid_key":return`Kunci tidak sah dalam ${t.origin}`;case"invalid_union":return"Input tidak sah";case"invalid_element":return`Nilai tidak sah dalam ${t.origin}`;default:return"Input tidak sah"}}}});function kc(){return{localeError:kf()}}var kf,zc=S(()=>{T();kf=()=>{let e={string:{unit:"tekens"},file:{unit:"bytes"},array:{unit:"elementen"},set:{unit:"elementen"}};function n(t){return e[t]??null}let r=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"getal";case"object":{if(Array.isArray(t))return"array";if(t===null)return"null";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"invoer",email:"emailadres",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO datum en tijd",date:"ISO datum",time:"ISO tijd",duration:"ISO duur",ipv4:"IPv4-adres",ipv6:"IPv6-adres",cidrv4:"IPv4-bereik",cidrv6:"IPv6-bereik",base64:"base64-gecodeerde tekst",base64url:"base64 URL-gecodeerde tekst",json_string:"JSON string",e164:"E.164-nummer",jwt:"JWT",template_literal:"invoer"};return t=>{switch(t.code){case"invalid_type":return`Ongeldige invoer: verwacht ${t.expected}, ontving ${r(t.input)}`;case"invalid_value":return t.values.length===1?`Ongeldige invoer: verwacht ${x(t.values[0])}`:`Ongeldige optie: verwacht \\xE9\\xE9n van ${h(t.values,"|")}`;case"too_big":{let o=t.inclusive?"<=":"<",a=n(t.origin);return a?`Te lang: verwacht dat ${t.origin??"waarde"} ${o}${t.maximum.toString()} ${a.unit??"elementen"} bevat`:`Te lang: verwacht dat ${t.origin??"waarde"} ${o}${t.maximum.toString()} is`}case"too_small":{let o=t.inclusive?">=":">",a=n(t.origin);return a?`Te kort: verwacht dat ${t.origin} ${o}${t.minimum.toString()} ${a.unit} bevat`:`Te kort: verwacht dat ${t.origin} ${o}${t.minimum.toString()} is`}case"invalid_format":{let o=t;return o.format==="starts_with"?`Ongeldige tekst: moet met "${o.prefix}" beginnen`:o.format==="ends_with"?`Ongeldige tekst: moet op "${o.suffix}" eindigen`:o.format==="includes"?`Ongeldige tekst: moet "${o.includes}" bevatten`:o.format==="regex"?`Ongeldige tekst: moet overeenkomen met patroon ${o.pattern}`:`Ongeldig: ${i[o.format]??t.format}`}case"not_multiple_of":return`Ongeldig getal: moet een veelvoud van ${t.divisor} zijn`;case"unrecognized_keys":return`Onbekende key${t.keys.length>1?"s":""}: ${h(t.keys,", ")}`;case"invalid_key":return`Ongeldige key in ${t.origin}`;case"invalid_union":return"Ongeldige invoer";case"invalid_element":return`Ongeldige waarde in ${t.origin}`;default:return"Ongeldige invoer"}}}});function Sc(){return{localeError:zf()}}var zf,wc=S(()=>{T();zf=()=>{let e={string:{unit:"tegn",verb:"\\xE5 ha"},file:{unit:"bytes",verb:"\\xE5 ha"},array:{unit:"elementer",verb:"\\xE5 inneholde"},set:{unit:"elementer",verb:"\\xE5 inneholde"}};function n(t){return e[t]??null}let r=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"tall";case"object":{if(Array.isArray(t))return"liste";if(t===null)return"null";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"input",email:"e-postadresse",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO dato- og klokkeslett",date:"ISO-dato",time:"ISO-klokkeslett",duration:"ISO-varighet",ipv4:"IPv4-omr\\xE5de",ipv6:"IPv6-omr\\xE5de",cidrv4:"IPv4-spekter",cidrv6:"IPv6-spekter",base64:"base64-enkodet streng",base64url:"base64url-enkodet streng",json_string:"JSON-streng",e164:"E.164-nummer",jwt:"JWT",template_literal:"input"};return t=>{switch(t.code){case"invalid_type":return`Ugyldig input: forventet ${t.expected}, fikk ${r(t.input)}`;case"invalid_value":return t.values.length===1?`Ugyldig verdi: forventet ${x(t.values[0])}`:`Ugyldig valg: forventet en av ${h(t.values,"|")}`;case"too_big":{let o=t.inclusive?"<=":"<",a=n(t.origin);return a?`For stor(t): forventet ${t.origin??"value"} til \\xE5 ha ${o}${t.maximum.toString()} ${a.unit??"elementer"}`:`For stor(t): forventet ${t.origin??"value"} til \\xE5 ha ${o}${t.maximum.toString()}`}case"too_small":{let o=t.inclusive?">=":">",a=n(t.origin);return a?`For lite(n): forventet ${t.origin} til \\xE5 ha ${o}${t.minimum.toString()} ${a.unit}`:`For lite(n): forventet ${t.origin} til \\xE5 ha ${o}${t.minimum.toString()}`}case"invalid_format":{let o=t;return o.format==="starts_with"?`Ugyldig streng: m\\xE5 starte med "${o.prefix}"`:o.format==="ends_with"?`Ugyldig streng: m\\xE5 ende med "${o.suffix}"`:o.format==="includes"?`Ugyldig streng: m\\xE5 inneholde "${o.includes}"`:o.format==="regex"?`Ugyldig streng: m\\xE5 matche m\\xF8nsteret ${o.pattern}`:`Ugyldig ${i[o.format]??t.format}`}case"not_multiple_of":return`Ugyldig tall: m\\xE5 v\\xE6re et multiplum av ${t.divisor}`;case"unrecognized_keys":return`${t.keys.length>1?"Ukjente n\\xF8kler":"Ukjent n\\xF8kkel"}: ${h(t.keys,", ")}`;case"invalid_key":return`Ugyldig n\\xF8kkel i ${t.origin}`;case"invalid_union":return"Ugyldig input";case"invalid_element":return`Ugyldig verdi i ${t.origin}`;default:return"Ugyldig input"}}}});function Ic(){return{localeError:Sf()}}var Sf,Pc=S(()=>{T();Sf=()=>{let e={string:{unit:"harf",verb:"olmal\\u0131d\\u0131r"},file:{unit:"bayt",verb:"olmal\\u0131d\\u0131r"},array:{unit:"unsur",verb:"olmal\\u0131d\\u0131r"},set:{unit:"unsur",verb:"olmal\\u0131d\\u0131r"}};function n(t){return e[t]??null}let r=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"numara";case"object":{if(Array.isArray(t))return"saf";if(t===null)return"gayb";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"giren",email:"epostag\\xE2h",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO heng\\xE2m\\u0131",date:"ISO tarihi",time:"ISO zaman\\u0131",duration:"ISO m\\xFCddeti",ipv4:"IPv4 ni\\u015F\\xE2n\\u0131",ipv6:"IPv6 ni\\u015F\\xE2n\\u0131",cidrv4:"IPv4 menzili",cidrv6:"IPv6 menzili",base64:"base64-\\u015Fifreli metin",base64url:"base64url-\\u015Fifreli metin",json_string:"JSON metin",e164:"E.164 say\\u0131s\\u0131",jwt:"JWT",template_literal:"giren"};return t=>{switch(t.code){case"invalid_type":return`F\\xE2sit giren: umulan ${t.expected}, al\\u0131nan ${r(t.input)}`;case"invalid_value":return t.values.length===1?`F\\xE2sit giren: umulan ${x(t.values[0])}`:`F\\xE2sit tercih: m\\xFBteberler ${h(t.values,"|")}`;case"too_big":{let o=t.inclusive?"<=":"<",a=n(t.origin);return a?`Fazla b\\xFCy\\xFCk: ${t.origin??"value"}, ${o}${t.maximum.toString()} ${a.unit??"elements"} sahip olmal\\u0131yd\\u0131.`:`Fazla b\\xFCy\\xFCk: ${t.origin??"value"}, ${o}${t.maximum.toString()} olmal\\u0131yd\\u0131.`}case"too_small":{let o=t.inclusive?">=":">",a=n(t.origin);return a?`Fazla k\\xFC\\xE7\\xFCk: ${t.origin}, ${o}${t.minimum.toString()} ${a.unit} sahip olmal\\u0131yd\\u0131.`:`Fazla k\\xFC\\xE7\\xFCk: ${t.origin}, ${o}${t.minimum.toString()} olmal\\u0131yd\\u0131.`}case"invalid_format":{let o=t;return o.format==="starts_with"?`F\\xE2sit metin: "${o.prefix}" ile ba\\u015Flamal\\u0131.`:o.format==="ends_with"?`F\\xE2sit metin: "${o.suffix}" ile bitmeli.`:o.format==="includes"?`F\\xE2sit metin: "${o.includes}" ihtiv\\xE2 etmeli.`:o.format==="regex"?`F\\xE2sit metin: ${o.pattern} nak\\u015F\\u0131na uymal\\u0131.`:`F\\xE2sit ${i[o.format]??t.format}`}case"not_multiple_of":return`F\\xE2sit say\\u0131: ${t.divisor} kat\\u0131 olmal\\u0131yd\\u0131.`;case"unrecognized_keys":return`Tan\\u0131nmayan anahtar ${t.keys.length>1?"s":""}: ${h(t.keys,", ")}`;case"invalid_key":return`${t.origin} i\\xE7in tan\\u0131nmayan anahtar var.`;case"invalid_union":return"Giren tan\\u0131namad\\u0131.";case"invalid_element":return`${t.origin} i\\xE7in tan\\u0131nmayan k\\u0131ymet var.`;default:return"K\\u0131ymet tan\\u0131namad\\u0131."}}}});function jc(){return{localeError:wf()}}var wf,Tc=S(()=>{T();wf=()=>{let e={string:{unit:"\\u062A\\u0648\\u06A9\\u064A",verb:"\\u0648\\u0644\\u0631\\u064A"},file:{unit:"\\u0628\\u0627\\u06CC\\u067C\\u0633",verb:"\\u0648\\u0644\\u0631\\u064A"},array:{unit:"\\u062A\\u0648\\u06A9\\u064A",verb:"\\u0648\\u0644\\u0631\\u064A"},set:{unit:"\\u062A\\u0648\\u06A9\\u064A",verb:"\\u0648\\u0644\\u0631\\u064A"}};function n(t){return e[t]??null}let r=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"\\u0639\\u062F\\u062F";case"object":{if(Array.isArray(t))return"\\u0627\\u0631\\u06D0";if(t===null)return"null";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"\\u0648\\u0631\\u0648\\u062F\\u064A",email:"\\u0628\\u0631\\u06CC\\u069A\\u0646\\u0627\\u0644\\u06CC\\u06A9",url:"\\u06CC\\u0648 \\u0622\\u0631 \\u0627\\u0644",emoji:"\\u0627\\u06CC\\u0645\\u0648\\u062C\\u064A",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"\\u0646\\u06CC\\u067C\\u0647 \\u0627\\u0648 \\u0648\\u062E\\u062A",date:"\\u0646\\u06D0\\u067C\\u0647",time:"\\u0648\\u062E\\u062A",duration:"\\u0645\\u0648\\u062F\\u0647",ipv4:"\\u062F IPv4 \\u067E\\u062A\\u0647",ipv6:"\\u062F IPv6 \\u067E\\u062A\\u0647",cidrv4:"\\u062F IPv4 \\u0633\\u0627\\u062D\\u0647",cidrv6:"\\u062F IPv6 \\u0633\\u0627\\u062D\\u0647",base64:"base64-encoded \\u0645\\u062A\\u0646",base64url:"base64url-encoded \\u0645\\u062A\\u0646",json_string:"JSON \\u0645\\u062A\\u0646",e164:"\\u062F E.164 \\u0634\\u0645\\u06D0\\u0631\\u0647",jwt:"JWT",template_literal:"\\u0648\\u0631\\u0648\\u062F\\u064A"};return t=>{switch(t.code){case"invalid_type":return`\\u0646\\u0627\\u0633\\u0645 \\u0648\\u0631\\u0648\\u062F\\u064A: \\u0628\\u0627\\u06CC\\u062F ${t.expected} \\u0648\\u0627\\u06CC, \\u0645\\u06AB\\u0631 ${r(t.input)} \\u062A\\u0631\\u0644\\u0627\\u0633\\u0647 \\u0634\\u0648`;case"invalid_value":return t.values.length===1?`\\u0646\\u0627\\u0633\\u0645 \\u0648\\u0631\\u0648\\u062F\\u064A: \\u0628\\u0627\\u06CC\\u062F ${x(t.values[0])} \\u0648\\u0627\\u06CC`:`\\u0646\\u0627\\u0633\\u0645 \\u0627\\u0646\\u062A\\u062E\\u0627\\u0628: \\u0628\\u0627\\u06CC\\u062F \\u06CC\\u0648 \\u0644\\u0647 ${h(t.values,"|")} \\u0685\\u062E\\u0647 \\u0648\\u0627\\u06CC`;case"too_big":{let o=t.inclusive?"<=":"<",a=n(t.origin);return a?`\\u0689\\u06CC\\u0631 \\u0644\\u0648\\u06CC: ${t.origin??"\\u0627\\u0631\\u0632\\u069A\\u062A"} \\u0628\\u0627\\u06CC\\u062F ${o}${t.maximum.toString()} ${a.unit??"\\u0639\\u0646\\u0635\\u0631\\u0648\\u0646\\u0647"} \\u0648\\u0644\\u0631\\u064A`:`\\u0689\\u06CC\\u0631 \\u0644\\u0648\\u06CC: ${t.origin??"\\u0627\\u0631\\u0632\\u069A\\u062A"} \\u0628\\u0627\\u06CC\\u062F ${o}${t.maximum.toString()} \\u0648\\u064A`}case"too_small":{let o=t.inclusive?">=":">",a=n(t.origin);return a?`\\u0689\\u06CC\\u0631 \\u06A9\\u0648\\u0686\\u0646\\u06CC: ${t.origin} \\u0628\\u0627\\u06CC\\u062F ${o}${t.minimum.toString()} ${a.unit} \\u0648\\u0644\\u0631\\u064A`:`\\u0689\\u06CC\\u0631 \\u06A9\\u0648\\u0686\\u0646\\u06CC: ${t.origin} \\u0628\\u0627\\u06CC\\u062F ${o}${t.minimum.toString()} \\u0648\\u064A`}case"invalid_format":{let o=t;return o.format==="starts_with"?`\\u0646\\u0627\\u0633\\u0645 \\u0645\\u062A\\u0646: \\u0628\\u0627\\u06CC\\u062F \\u062F "${o.prefix}" \\u0633\\u0631\\u0647 \\u067E\\u06CC\\u0644 \\u0634\\u064A`:o.format==="ends_with"?`\\u0646\\u0627\\u0633\\u0645 \\u0645\\u062A\\u0646: \\u0628\\u0627\\u06CC\\u062F \\u062F "${o.suffix}" \\u0633\\u0631\\u0647 \\u067E\\u0627\\u06CC \\u062A\\u0647 \\u0648\\u0631\\u0633\\u064A\\u0696\\u064A`:o.format==="includes"?`\\u0646\\u0627\\u0633\\u0645 \\u0645\\u062A\\u0646: \\u0628\\u0627\\u06CC\\u062F "${o.includes}" \\u0648\\u0644\\u0631\\u064A`:o.format==="regex"?`\\u0646\\u0627\\u0633\\u0645 \\u0645\\u062A\\u0646: \\u0628\\u0627\\u06CC\\u062F \\u062F ${o.pattern} \\u0633\\u0631\\u0647 \\u0645\\u0637\\u0627\\u0628\\u0642\\u062A \\u0648\\u0644\\u0631\\u064A`:`${i[o.format]??t.format} \\u0646\\u0627\\u0633\\u0645 \\u062F\\u06CC`}case"not_multiple_of":return`\\u0646\\u0627\\u0633\\u0645 \\u0639\\u062F\\u062F: \\u0628\\u0627\\u06CC\\u062F \\u062F ${t.divisor} \\u0645\\u0636\\u0631\\u0628 \\u0648\\u064A`;case"unrecognized_keys":return`\\u0646\\u0627\\u0633\\u0645 ${t.keys.length>1?"\\u06A9\\u0644\\u06CC\\u0689\\u0648\\u0646\\u0647":"\\u06A9\\u0644\\u06CC\\u0689"}: ${h(t.keys,", ")}`;case"invalid_key":return`\\u0646\\u0627\\u0633\\u0645 \\u06A9\\u0644\\u06CC\\u0689 \\u067E\\u0647 ${t.origin} \\u06A9\\u06D0`;case"invalid_union":return"\\u0646\\u0627\\u0633\\u0645\\u0647 \\u0648\\u0631\\u0648\\u062F\\u064A";case"invalid_element":return`\\u0646\\u0627\\u0633\\u0645 \\u0639\\u0646\\u0635\\u0631 \\u067E\\u0647 ${t.origin} \\u06A9\\u06D0`;default:return"\\u0646\\u0627\\u0633\\u0645\\u0647 \\u0648\\u0631\\u0648\\u062F\\u064A"}}}});function Oc(){return{localeError:If()}}var If,Nc=S(()=>{T();If=()=>{let e={string:{unit:"znak\\xF3w",verb:"mie\\u0107"},file:{unit:"bajt\\xF3w",verb:"mie\\u0107"},array:{unit:"element\\xF3w",verb:"mie\\u0107"},set:{unit:"element\\xF3w",verb:"mie\\u0107"}};function n(t){return e[t]??null}let r=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"liczba";case"object":{if(Array.isArray(t))return"tablica";if(t===null)return"null";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"wyra\\u017Cenie",email:"adres email",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"data i godzina w formacie ISO",date:"data w formacie ISO",time:"godzina w formacie ISO",duration:"czas trwania ISO",ipv4:"adres IPv4",ipv6:"adres IPv6",cidrv4:"zakres IPv4",cidrv6:"zakres IPv6",base64:"ci\\u0105g znak\\xF3w zakodowany w formacie base64",base64url:"ci\\u0105g znak\\xF3w zakodowany w formacie base64url",json_string:"ci\\u0105g znak\\xF3w w formacie JSON",e164:"liczba E.164",jwt:"JWT",template_literal:"wej\\u015Bcie"};return t=>{switch(t.code){case"invalid_type":return`Nieprawid\\u0142owe dane wej\\u015Bciowe: oczekiwano ${t.expected}, otrzymano ${r(t.input)}`;case"invalid_value":return t.values.length===1?`Nieprawid\\u0142owe dane wej\\u015Bciowe: oczekiwano ${x(t.values[0])}`:`Nieprawid\\u0142owa opcja: oczekiwano jednej z warto\\u015Bci ${h(t.values,"|")}`;case"too_big":{let o=t.inclusive?"<=":"<",a=n(t.origin);return a?`Za du\\u017Ca warto\\u015B\\u0107: oczekiwano, \\u017Ce ${t.origin??"warto\\u015B\\u0107"} b\\u0119dzie mie\\u0107 ${o}${t.maximum.toString()} ${a.unit??"element\\xF3w"}`:`Zbyt du\\u017C(y/a/e): oczekiwano, \\u017Ce ${t.origin??"warto\\u015B\\u0107"} b\\u0119dzie wynosi\\u0107 ${o}${t.maximum.toString()}`}case"too_small":{let o=t.inclusive?">=":">",a=n(t.origin);return a?`Za ma\\u0142a warto\\u015B\\u0107: oczekiwano, \\u017Ce ${t.origin??"warto\\u015B\\u0107"} b\\u0119dzie mie\\u0107 ${o}${t.minimum.toString()} ${a.unit??"element\\xF3w"}`:`Zbyt ma\\u0142(y/a/e): oczekiwano, \\u017Ce ${t.origin??"warto\\u015B\\u0107"} b\\u0119dzie wynosi\\u0107 ${o}${t.minimum.toString()}`}case"invalid_format":{let o=t;return o.format==="starts_with"?`Nieprawid\\u0142owy ci\\u0105g znak\\xF3w: musi zaczyna\\u0107 si\\u0119 od "${o.prefix}"`:o.format==="ends_with"?`Nieprawid\\u0142owy ci\\u0105g znak\\xF3w: musi ko\\u0144czy\\u0107 si\\u0119 na "${o.suffix}"`:o.format==="includes"?`Nieprawid\\u0142owy ci\\u0105g znak\\xF3w: musi zawiera\\u0107 "${o.includes}"`:o.format==="regex"?`Nieprawid\\u0142owy ci\\u0105g znak\\xF3w: musi odpowiada\\u0107 wzorcowi ${o.pattern}`:`Nieprawid\\u0142ow(y/a/e) ${i[o.format]??t.format}`}case"not_multiple_of":return`Nieprawid\\u0142owa liczba: musi by\\u0107 wielokrotno\\u015Bci\\u0105 ${t.divisor}`;case"unrecognized_keys":return`Nierozpoznane klucze${t.keys.length>1?"s":""}: ${h(t.keys,", ")}`;case"invalid_key":return`Nieprawid\\u0142owy klucz w ${t.origin}`;case"invalid_union":return"Nieprawid\\u0142owe dane wej\\u015Bciowe";case"invalid_element":return`Nieprawid\\u0142owa warto\\u015B\\u0107 w ${t.origin}`;default:return"Nieprawid\\u0142owe dane wej\\u015Bciowe"}}}});function Ec(){return{localeError:Pf()}}var Pf,Rc=S(()=>{T();Pf=()=>{let e={string:{unit:"caracteres",verb:"ter"},file:{unit:"bytes",verb:"ter"},array:{unit:"itens",verb:"ter"},set:{unit:"itens",verb:"ter"}};function n(t){return e[t]??null}let r=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"n\\xFAmero";case"object":{if(Array.isArray(t))return"array";if(t===null)return"nulo";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"padr\\xE3o",email:"endere\\xE7o de e-mail",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"data e hora ISO",date:"data ISO",time:"hora ISO",duration:"dura\\xE7\\xE3o ISO",ipv4:"endere\\xE7o IPv4",ipv6:"endere\\xE7o IPv6",cidrv4:"faixa de IPv4",cidrv6:"faixa de IPv6",base64:"texto codificado em base64",base64url:"URL codificada em base64",json_string:"texto JSON",e164:"n\\xFAmero E.164",jwt:"JWT",template_literal:"entrada"};return t=>{switch(t.code){case"invalid_type":return`Tipo inv\\xE1lido: esperado ${t.expected}, recebido ${r(t.input)}`;case"invalid_value":return t.values.length===1?`Entrada inv\\xE1lida: esperado ${x(t.values[0])}`:`Op\\xE7\\xE3o inv\\xE1lida: esperada uma das ${h(t.values,"|")}`;case"too_big":{let o=t.inclusive?"<=":"<",a=n(t.origin);return a?`Muito grande: esperado que ${t.origin??"valor"} tivesse ${o}${t.maximum.toString()} ${a.unit??"elementos"}`:`Muito grande: esperado que ${t.origin??"valor"} fosse ${o}${t.maximum.toString()}`}case"too_small":{let o=t.inclusive?">=":">",a=n(t.origin);return a?`Muito pequeno: esperado que ${t.origin} tivesse ${o}${t.minimum.toString()} ${a.unit}`:`Muito pequeno: esperado que ${t.origin} fosse ${o}${t.minimum.toString()}`}case"invalid_format":{let o=t;return o.format==="starts_with"?`Texto inv\\xE1lido: deve come\\xE7ar com "${o.prefix}"`:o.format==="ends_with"?`Texto inv\\xE1lido: deve terminar com "${o.suffix}"`:o.format==="includes"?`Texto inv\\xE1lido: deve incluir "${o.includes}"`:o.format==="regex"?`Texto inv\\xE1lido: deve corresponder ao padr\\xE3o ${o.pattern}`:`${i[o.format]??t.format} inv\\xE1lido`}case"not_multiple_of":return`N\\xFAmero inv\\xE1lido: deve ser m\\xFAltiplo de ${t.divisor}`;case"unrecognized_keys":return`Chave${t.keys.length>1?"s":""} desconhecida${t.keys.length>1?"s":""}: ${h(t.keys,", ")}`;case"invalid_key":return`Chave inv\\xE1lida em ${t.origin}`;case"invalid_union":return"Entrada inv\\xE1lida";case"invalid_element":return`Valor inv\\xE1lido em ${t.origin}`;default:return"Campo inv\\xE1lido"}}}});function Uc(e,n,r,i){let t=Math.abs(e),o=t%10,a=t%100;return a>=11&&a<=19?i:o===1?n:o>=2&&o<=4?r:i}function Cc(){return{localeError:jf()}}var jf,Dc=S(()=>{T();jf=()=>{let e={string:{unit:{one:"\\u0441\\u0438\\u043C\\u0432\\u043E\\u043B",few:"\\u0441\\u0438\\u043C\\u0432\\u043E\\u043B\\u0430",many:"\\u0441\\u0438\\u043C\\u0432\\u043E\\u043B\\u043E\\u0432"},verb:"\\u0438\\u043C\\u0435\\u0442\\u044C"},file:{unit:{one:"\\u0431\\u0430\\u0439\\u0442",few:"\\u0431\\u0430\\u0439\\u0442\\u0430",many:"\\u0431\\u0430\\u0439\\u0442"},verb:"\\u0438\\u043C\\u0435\\u0442\\u044C"},array:{unit:{one:"\\u044D\\u043B\\u0435\\u043C\\u0435\\u043D\\u0442",few:"\\u044D\\u043B\\u0435\\u043C\\u0435\\u043D\\u0442\\u0430",many:"\\u044D\\u043B\\u0435\\u043C\\u0435\\u043D\\u0442\\u043E\\u0432"},verb:"\\u0438\\u043C\\u0435\\u0442\\u044C"},set:{unit:{one:"\\u044D\\u043B\\u0435\\u043C\\u0435\\u043D\\u0442",few:"\\u044D\\u043B\\u0435\\u043C\\u0435\\u043D\\u0442\\u0430",many:"\\u044D\\u043B\\u0435\\u043C\\u0435\\u043D\\u0442\\u043E\\u0432"},verb:"\\u0438\\u043C\\u0435\\u0442\\u044C"}};function n(t){return e[t]??null}let r=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"\\u0447\\u0438\\u0441\\u043B\\u043E";case"object":{if(Array.isArray(t))return"\\u043C\\u0430\\u0441\\u0441\\u0438\\u0432";if(t===null)return"null";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"\\u0432\\u0432\\u043E\\u0434",email:"email \\u0430\\u0434\\u0440\\u0435\\u0441",url:"URL",emoji:"\\u044D\\u043C\\u043E\\u0434\\u0437\\u0438",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO \\u0434\\u0430\\u0442\\u0430 \\u0438 \\u0432\\u0440\\u0435\\u043C\\u044F",date:"ISO \\u0434\\u0430\\u0442\\u0430",time:"ISO \\u0432\\u0440\\u0435\\u043C\\u044F",duration:"ISO \\u0434\\u043B\\u0438\\u0442\\u0435\\u043B\\u044C\\u043D\\u043E\\u0441\\u0442\\u044C",ipv4:"IPv4 \\u0430\\u0434\\u0440\\u0435\\u0441",ipv6:"IPv6 \\u0430\\u0434\\u0440\\u0435\\u0441",cidrv4:"IPv4 \\u0434\\u0438\\u0430\\u043F\\u0430\\u0437\\u043E\\u043D",cidrv6:"IPv6 \\u0434\\u0438\\u0430\\u043F\\u0430\\u0437\\u043E\\u043D",base64:"\\u0441\\u0442\\u0440\\u043E\\u043A\\u0430 \\u0432 \\u0444\\u043E\\u0440\\u043C\\u0430\\u0442\\u0435 base64",base64url:"\\u0441\\u0442\\u0440\\u043E\\u043A\\u0430 \\u0432 \\u0444\\u043E\\u0440\\u043C\\u0430\\u0442\\u0435 base64url",json_string:"JSON \\u0441\\u0442\\u0440\\u043E\\u043A\\u0430",e164:"\\u043D\\u043E\\u043C\\u0435\\u0440 E.164",jwt:"JWT",template_literal:"\\u0432\\u0432\\u043E\\u0434"};return t=>{switch(t.code){case"invalid_type":return`\\u041D\\u0435\\u0432\\u0435\\u0440\\u043D\\u044B\\u0439 \\u0432\\u0432\\u043E\\u0434: \\u043E\\u0436\\u0438\\u0434\\u0430\\u043B\\u043E\\u0441\\u044C ${t.expected}, \\u043F\\u043E\\u043B\\u0443\\u0447\\u0435\\u043D\\u043E ${r(t.input)}`;case"invalid_value":return t.values.length===1?`\\u041D\\u0435\\u0432\\u0435\\u0440\\u043D\\u044B\\u0439 \\u0432\\u0432\\u043E\\u0434: \\u043E\\u0436\\u0438\\u0434\\u0430\\u043B\\u043E\\u0441\\u044C ${x(t.values[0])}`:`\\u041D\\u0435\\u0432\\u0435\\u0440\\u043D\\u044B\\u0439 \\u0432\\u0430\\u0440\\u0438\\u0430\\u043D\\u0442: \\u043E\\u0436\\u0438\\u0434\\u0430\\u043B\\u043E\\u0441\\u044C \\u043E\\u0434\\u043D\\u043E \\u0438\\u0437 ${h(t.values,"|")}`;case"too_big":{let o=t.inclusive?"<=":"<",a=n(t.origin);if(a){let u=Number(t.maximum),c=Uc(u,a.unit.one,a.unit.few,a.unit.many);return`\\u0421\\u043B\\u0438\\u0448\\u043A\\u043E\\u043C \\u0431\\u043E\\u043B\\u044C\\u0448\\u043E\\u0435 \\u0437\\u043D\\u0430\\u0447\\u0435\\u043D\\u0438\\u0435: \\u043E\\u0436\\u0438\\u0434\\u0430\\u043B\\u043E\\u0441\\u044C, \\u0447\\u0442\\u043E ${t.origin??"\\u0437\\u043D\\u0430\\u0447\\u0435\\u043D\\u0438\\u0435"} \\u0431\\u0443\\u0434\\u0435\\u0442 \\u0438\\u043C\\u0435\\u0442\\u044C ${o}${t.maximum.toString()} ${c}`}return`\\u0421\\u043B\\u0438\\u0448\\u043A\\u043E\\u043C \\u0431\\u043E\\u043B\\u044C\\u0448\\u043E\\u0435 \\u0437\\u043D\\u0430\\u0447\\u0435\\u043D\\u0438\\u0435: \\u043E\\u0436\\u0438\\u0434\\u0430\\u043B\\u043E\\u0441\\u044C, \\u0447\\u0442\\u043E ${t.origin??"\\u0437\\u043D\\u0430\\u0447\\u0435\\u043D\\u0438\\u0435"} \\u0431\\u0443\\u0434\\u0435\\u0442 ${o}${t.maximum.toString()}`}case"too_small":{let o=t.inclusive?">=":">",a=n(t.origin);if(a){let u=Number(t.minimum),c=Uc(u,a.unit.one,a.unit.few,a.unit.many);return`\\u0421\\u043B\\u0438\\u0448\\u043A\\u043E\\u043C \\u043C\\u0430\\u043B\\u0435\\u043D\\u044C\\u043A\\u043E\\u0435 \\u0437\\u043D\\u0430\\u0447\\u0435\\u043D\\u0438\\u0435: \\u043E\\u0436\\u0438\\u0434\\u0430\\u043B\\u043E\\u0441\\u044C, \\u0447\\u0442\\u043E ${t.origin} \\u0431\\u0443\\u0434\\u0435\\u0442 \\u0438\\u043C\\u0435\\u0442\\u044C ${o}${t.minimum.toString()} ${c}`}return`\\u0421\\u043B\\u0438\\u0448\\u043A\\u043E\\u043C \\u043C\\u0430\\u043B\\u0435\\u043D\\u044C\\u043A\\u043E\\u0435 \\u0437\\u043D\\u0430\\u0447\\u0435\\u043D\\u0438\\u0435: \\u043E\\u0436\\u0438\\u0434\\u0430\\u043B\\u043E\\u0441\\u044C, \\u0447\\u0442\\u043E ${t.origin} \\u0431\\u0443\\u0434\\u0435\\u0442 ${o}${t.minimum.toString()}`}case"invalid_format":{let o=t;return o.format==="starts_with"?`\\u041D\\u0435\\u0432\\u0435\\u0440\\u043D\\u0430\\u044F \\u0441\\u0442\\u0440\\u043E\\u043A\\u0430: \\u0434\\u043E\\u043B\\u0436\\u043D\\u0430 \\u043D\\u0430\\u0447\\u0438\\u043D\\u0430\\u0442\\u044C\\u0441\\u044F \\u0441 "${o.prefix}"`:o.format==="ends_with"?`\\u041D\\u0435\\u0432\\u0435\\u0440\\u043D\\u0430\\u044F \\u0441\\u0442\\u0440\\u043E\\u043A\\u0430: \\u0434\\u043E\\u043B\\u0436\\u043D\\u0430 \\u0437\\u0430\\u043A\\u0430\\u043D\\u0447\\u0438\\u0432\\u0430\\u0442\\u044C\\u0441\\u044F \\u043D\\u0430 "${o.suffix}"`:o.format==="includes"?`\\u041D\\u0435\\u0432\\u0435\\u0440\\u043D\\u0430\\u044F \\u0441\\u0442\\u0440\\u043E\\u043A\\u0430: \\u0434\\u043E\\u043B\\u0436\\u043D\\u0430 \\u0441\\u043E\\u0434\\u0435\\u0440\\u0436\\u0430\\u0442\\u044C "${o.includes}"`:o.format==="regex"?`\\u041D\\u0435\\u0432\\u0435\\u0440\\u043D\\u0430\\u044F \\u0441\\u0442\\u0440\\u043E\\u043A\\u0430: \\u0434\\u043E\\u043B\\u0436\\u043D\\u0430 \\u0441\\u043E\\u043E\\u0442\\u0432\\u0435\\u0442\\u0441\\u0442\\u0432\\u043E\\u0432\\u0430\\u0442\\u044C \\u0448\\u0430\\u0431\\u043B\\u043E\\u043D\\u0443 ${o.pattern}`:`\\u041D\\u0435\\u0432\\u0435\\u0440\\u043D\\u044B\\u0439 ${i[o.format]??t.format}`}case"not_multiple_of":return`\\u041D\\u0435\\u0432\\u0435\\u0440\\u043D\\u043E\\u0435 \\u0447\\u0438\\u0441\\u043B\\u043E: \\u0434\\u043E\\u043B\\u0436\\u043D\\u043E \\u0431\\u044B\\u0442\\u044C \\u043A\\u0440\\u0430\\u0442\\u043D\\u044B\\u043C ${t.divisor}`;case"unrecognized_keys":return`\\u041D\\u0435\\u0440\\u0430\\u0441\\u043F\\u043E\\u0437\\u043D\\u0430\\u043D\\u043D${t.keys.length>1?"\\u044B\\u0435":"\\u044B\\u0439"} \\u043A\\u043B\\u044E\\u0447${t.keys.length>1?"\\u0438":""}: ${h(t.keys,", ")}`;case"invalid_key":return`\\u041D\\u0435\\u0432\\u0435\\u0440\\u043D\\u044B\\u0439 \\u043A\\u043B\\u044E\\u0447 \\u0432 ${t.origin}`;case"invalid_union":return"\\u041D\\u0435\\u0432\\u0435\\u0440\\u043D\\u044B\\u0435 \\u0432\\u0445\\u043E\\u0434\\u043D\\u044B\\u0435 \\u0434\\u0430\\u043D\\u043D\\u044B\\u0435";case"invalid_element":return`\\u041D\\u0435\\u0432\\u0435\\u0440\\u043D\\u043E\\u0435 \\u0437\\u043D\\u0430\\u0447\\u0435\\u043D\\u0438\\u0435 \\u0432 ${t.origin}`;default:return"\\u041D\\u0435\\u0432\\u0435\\u0440\\u043D\\u044B\\u0435 \\u0432\\u0445\\u043E\\u0434\\u043D\\u044B\\u0435 \\u0434\\u0430\\u043D\\u043D\\u044B\\u0435"}}}});function Zc(){return{localeError:Tf()}}var Tf,Ac=S(()=>{T();Tf=()=>{let e={string:{unit:"znakov",verb:"imeti"},file:{unit:"bajtov",verb:"imeti"},array:{unit:"elementov",verb:"imeti"},set:{unit:"elementov",verb:"imeti"}};function n(t){return e[t]??null}let r=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"\\u0161tevilo";case"object":{if(Array.isArray(t))return"tabela";if(t===null)return"null";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"vnos",email:"e-po\\u0161tni naslov",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO datum in \\u010Das",date:"ISO datum",time:"ISO \\u010Das",duration:"ISO trajanje",ipv4:"IPv4 naslov",ipv6:"IPv6 naslov",cidrv4:"obseg IPv4",cidrv6:"obseg IPv6",base64:"base64 kodiran niz",base64url:"base64url kodiran niz",json_string:"JSON niz",e164:"E.164 \\u0161tevilka",jwt:"JWT",template_literal:"vnos"};return t=>{switch(t.code){case"invalid_type":return`Neveljaven vnos: pri\\u010Dakovano ${t.expected}, prejeto ${r(t.input)}`;case"invalid_value":return t.values.length===1?`Neveljaven vnos: pri\\u010Dakovano ${x(t.values[0])}`:`Neveljavna mo\\u017Enost: pri\\u010Dakovano eno izmed ${h(t.values,"|")}`;case"too_big":{let o=t.inclusive?"<=":"<",a=n(t.origin);return a?`Preveliko: pri\\u010Dakovano, da bo ${t.origin??"vrednost"} imelo ${o}${t.maximum.toString()} ${a.unit??"elementov"}`:`Preveliko: pri\\u010Dakovano, da bo ${t.origin??"vrednost"} ${o}${t.maximum.toString()}`}case"too_small":{let o=t.inclusive?">=":">",a=n(t.origin);return a?`Premajhno: pri\\u010Dakovano, da bo ${t.origin} imelo ${o}${t.minimum.toString()} ${a.unit}`:`Premajhno: pri\\u010Dakovano, da bo ${t.origin} ${o}${t.minimum.toString()}`}case"invalid_format":{let o=t;return o.format==="starts_with"?`Neveljaven niz: mora se za\\u010Deti z "${o.prefix}"`:o.format==="ends_with"?`Neveljaven niz: mora se kon\\u010Dati z "${o.suffix}"`:o.format==="includes"?`Neveljaven niz: mora vsebovati "${o.includes}"`:o.format==="regex"?`Neveljaven niz: mora ustrezati vzorcu ${o.pattern}`:`Neveljaven ${i[o.format]??t.format}`}case"not_multiple_of":return`Neveljavno \\u0161tevilo: mora biti ve\\u010Dkratnik ${t.divisor}`;case"unrecognized_keys":return`Neprepoznan${t.keys.length>1?"i klju\\u010Di":" klju\\u010D"}: ${h(t.keys,", ")}`;case"invalid_key":return`Neveljaven klju\\u010D v ${t.origin}`;case"invalid_union":return"Neveljaven vnos";case"invalid_element":return`Neveljavna vrednost v ${t.origin}`;default:return"Neveljaven vnos"}}}});function Mc(){return{localeError:Of()}}var Of,Lc=S(()=>{T();Of=()=>{let e={string:{unit:"tecken",verb:"att ha"},file:{unit:"bytes",verb:"att ha"},array:{unit:"objekt",verb:"att inneh\\xE5lla"},set:{unit:"objekt",verb:"att inneh\\xE5lla"}};function n(t){return e[t]??null}let r=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"antal";case"object":{if(Array.isArray(t))return"lista";if(t===null)return"null";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"regulj\\xE4rt uttryck",email:"e-postadress",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO-datum och tid",date:"ISO-datum",time:"ISO-tid",duration:"ISO-varaktighet",ipv4:"IPv4-intervall",ipv6:"IPv6-intervall",cidrv4:"IPv4-spektrum",cidrv6:"IPv6-spektrum",base64:"base64-kodad str\\xE4ng",base64url:"base64url-kodad str\\xE4ng",json_string:"JSON-str\\xE4ng",e164:"E.164-nummer",jwt:"JWT",template_literal:"mall-literal"};return t=>{switch(t.code){case"invalid_type":return`Ogiltig inmatning: f\\xF6rv\\xE4ntat ${t.expected}, fick ${r(t.input)}`;case"invalid_value":return t.values.length===1?`Ogiltig inmatning: f\\xF6rv\\xE4ntat ${x(t.values[0])}`:`Ogiltigt val: f\\xF6rv\\xE4ntade en av ${h(t.values,"|")}`;case"too_big":{let o=t.inclusive?"<=":"<",a=n(t.origin);return a?`F\\xF6r stor(t): f\\xF6rv\\xE4ntade ${t.origin??"v\\xE4rdet"} att ha ${o}${t.maximum.toString()} ${a.unit??"element"}`:`F\\xF6r stor(t): f\\xF6rv\\xE4ntat ${t.origin??"v\\xE4rdet"} att ha ${o}${t.maximum.toString()}`}case"too_small":{let o=t.inclusive?">=":">",a=n(t.origin);return a?`F\\xF6r lite(t): f\\xF6rv\\xE4ntade ${t.origin??"v\\xE4rdet"} att ha ${o}${t.minimum.toString()} ${a.unit}`:`F\\xF6r lite(t): f\\xF6rv\\xE4ntade ${t.origin??"v\\xE4rdet"} att ha ${o}${t.minimum.toString()}`}case"invalid_format":{let o=t;return o.format==="starts_with"?`Ogiltig str\\xE4ng: m\\xE5ste b\\xF6rja med "${o.prefix}"`:o.format==="ends_with"?`Ogiltig str\\xE4ng: m\\xE5ste sluta med "${o.suffix}"`:o.format==="includes"?`Ogiltig str\\xE4ng: m\\xE5ste inneh\\xE5lla "${o.includes}"`:o.format==="regex"?`Ogiltig str\\xE4ng: m\\xE5ste matcha m\\xF6nstret "${o.pattern}"`:`Ogiltig(t) ${i[o.format]??t.format}`}case"not_multiple_of":return`Ogiltigt tal: m\\xE5ste vara en multipel av ${t.divisor}`;case"unrecognized_keys":return`${t.keys.length>1?"Ok\\xE4nda nycklar":"Ok\\xE4nd nyckel"}: ${h(t.keys,", ")}`;case"invalid_key":return`Ogiltig nyckel i ${t.origin??"v\\xE4rdet"}`;case"invalid_union":return"Ogiltig input";case"invalid_element":return`Ogiltigt v\\xE4rde i ${t.origin??"v\\xE4rdet"}`;default:return"Ogiltig input"}}}});function qc(){return{localeError:Nf()}}var Nf,Fc=S(()=>{T();Nf=()=>{let e={string:{unit:"\\u0B8E\\u0BB4\\u0BC1\\u0BA4\\u0BCD\\u0BA4\\u0BC1\\u0B95\\u0BCD\\u0B95\\u0BB3\\u0BCD",verb:"\\u0B95\\u0BCA\\u0BA3\\u0BCD\\u0B9F\\u0BBF\\u0BB0\\u0BC1\\u0B95\\u0BCD\\u0B95 \\u0BB5\\u0BC7\\u0BA3\\u0BCD\\u0B9F\\u0BC1\\u0BAE\\u0BCD"},file:{unit:"\\u0BAA\\u0BC8\\u0B9F\\u0BCD\\u0B9F\\u0BC1\\u0B95\\u0BB3\\u0BCD",verb:"\\u0B95\\u0BCA\\u0BA3\\u0BCD\\u0B9F\\u0BBF\\u0BB0\\u0BC1\\u0B95\\u0BCD\\u0B95 \\u0BB5\\u0BC7\\u0BA3\\u0BCD\\u0B9F\\u0BC1\\u0BAE\\u0BCD"},array:{unit:"\\u0B89\\u0BB1\\u0BC1\\u0BAA\\u0BCD\\u0BAA\\u0BC1\\u0B95\\u0BB3\\u0BCD",verb:"\\u0B95\\u0BCA\\u0BA3\\u0BCD\\u0B9F\\u0BBF\\u0BB0\\u0BC1\\u0B95\\u0BCD\\u0B95 \\u0BB5\\u0BC7\\u0BA3\\u0BCD\\u0B9F\\u0BC1\\u0BAE\\u0BCD"},set:{unit:"\\u0B89\\u0BB1\\u0BC1\\u0BAA\\u0BCD\\u0BAA\\u0BC1\\u0B95\\u0BB3\\u0BCD",verb:"\\u0B95\\u0BCA\\u0BA3\\u0BCD\\u0B9F\\u0BBF\\u0BB0\\u0BC1\\u0B95\\u0BCD\\u0B95 \\u0BB5\\u0BC7\\u0BA3\\u0BCD\\u0B9F\\u0BC1\\u0BAE\\u0BCD"}};function n(t){return e[t]??null}let r=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"\\u0B8E\\u0BA3\\u0BCD \\u0B85\\u0BB2\\u0BCD\\u0BB2\\u0BBE\\u0BA4\\u0BA4\\u0BC1":"\\u0B8E\\u0BA3\\u0BCD";case"object":{if(Array.isArray(t))return"\\u0B85\\u0BA3\\u0BBF";if(t===null)return"\\u0BB5\\u0BC6\\u0BB1\\u0BC1\\u0BAE\\u0BC8";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"\\u0B89\\u0BB3\\u0BCD\\u0BB3\\u0BC0\\u0B9F\\u0BC1",email:"\\u0BAE\\u0BBF\\u0BA9\\u0BCD\\u0BA9\\u0B9E\\u0BCD\\u0B9A\\u0BB2\\u0BCD \\u0BAE\\u0BC1\\u0B95\\u0BB5\\u0BB0\\u0BBF",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO \\u0BA4\\u0BC7\\u0BA4\\u0BBF \\u0BA8\\u0BC7\\u0BB0\\u0BAE\\u0BCD",date:"ISO \\u0BA4\\u0BC7\\u0BA4\\u0BBF",time:"ISO \\u0BA8\\u0BC7\\u0BB0\\u0BAE\\u0BCD",duration:"ISO \\u0B95\\u0BBE\\u0BB2 \\u0B85\\u0BB3\\u0BB5\\u0BC1",ipv4:"IPv4 \\u0BAE\\u0BC1\\u0B95\\u0BB5\\u0BB0\\u0BBF",ipv6:"IPv6 \\u0BAE\\u0BC1\\u0B95\\u0BB5\\u0BB0\\u0BBF",cidrv4:"IPv4 \\u0BB5\\u0BB0\\u0BAE\\u0BCD\\u0BAA\\u0BC1",cidrv6:"IPv6 \\u0BB5\\u0BB0\\u0BAE\\u0BCD\\u0BAA\\u0BC1",base64:"base64-encoded \\u0B9A\\u0BB0\\u0BAE\\u0BCD",base64url:"base64url-encoded \\u0B9A\\u0BB0\\u0BAE\\u0BCD",json_string:"JSON \\u0B9A\\u0BB0\\u0BAE\\u0BCD",e164:"E.164 \\u0B8E\\u0BA3\\u0BCD",jwt:"JWT",template_literal:"input"};return t=>{switch(t.code){case"invalid_type":return`\\u0BA4\\u0BB5\\u0BB1\\u0BBE\\u0BA9 \\u0B89\\u0BB3\\u0BCD\\u0BB3\\u0BC0\\u0B9F\\u0BC1: \\u0B8E\\u0BA4\\u0BBF\\u0BB0\\u0BCD\\u0BAA\\u0BBE\\u0BB0\\u0BCD\\u0B95\\u0BCD\\u0B95\\u0BAA\\u0BCD\\u0BAA\\u0B9F\\u0BCD\\u0B9F\\u0BA4\\u0BC1 ${t.expected}, \\u0BAA\\u0BC6\\u0BB1\\u0BAA\\u0BCD\\u0BAA\\u0B9F\\u0BCD\\u0B9F\\u0BA4\\u0BC1 ${r(t.input)}`;case"invalid_value":return t.values.length===1?`\\u0BA4\\u0BB5\\u0BB1\\u0BBE\\u0BA9 \\u0B89\\u0BB3\\u0BCD\\u0BB3\\u0BC0\\u0B9F\\u0BC1: \\u0B8E\\u0BA4\\u0BBF\\u0BB0\\u0BCD\\u0BAA\\u0BBE\\u0BB0\\u0BCD\\u0B95\\u0BCD\\u0B95\\u0BAA\\u0BCD\\u0BAA\\u0B9F\\u0BCD\\u0B9F\\u0BA4\\u0BC1 ${x(t.values[0])}`:`\\u0BA4\\u0BB5\\u0BB1\\u0BBE\\u0BA9 \\u0BB5\\u0BBF\\u0BB0\\u0BC1\\u0BAA\\u0BCD\\u0BAA\\u0BAE\\u0BCD: \\u0B8E\\u0BA4\\u0BBF\\u0BB0\\u0BCD\\u0BAA\\u0BBE\\u0BB0\\u0BCD\\u0B95\\u0BCD\\u0B95\\u0BAA\\u0BCD\\u0BAA\\u0B9F\\u0BCD\\u0B9F\\u0BA4\\u0BC1 ${h(t.values,"|")} \\u0B87\\u0BB2\\u0BCD \\u0B92\\u0BA9\\u0BCD\\u0BB1\\u0BC1`;case"too_big":{let o=t.inclusive?"<=":"<",a=n(t.origin);return a?`\\u0BAE\\u0BBF\\u0B95 \\u0BAA\\u0BC6\\u0BB0\\u0BBF\\u0BAF\\u0BA4\\u0BC1: \\u0B8E\\u0BA4\\u0BBF\\u0BB0\\u0BCD\\u0BAA\\u0BBE\\u0BB0\\u0BCD\\u0B95\\u0BCD\\u0B95\\u0BAA\\u0BCD\\u0BAA\\u0B9F\\u0BCD\\u0B9F\\u0BA4\\u0BC1 ${t.origin??"\\u0BAE\\u0BA4\\u0BBF\\u0BAA\\u0BCD\\u0BAA\\u0BC1"} ${o}${t.maximum.toString()} ${a.unit??"\\u0B89\\u0BB1\\u0BC1\\u0BAA\\u0BCD\\u0BAA\\u0BC1\\u0B95\\u0BB3\\u0BCD"} \\u0B86\\u0B95 \\u0B87\\u0BB0\\u0BC1\\u0B95\\u0BCD\\u0B95 \\u0BB5\\u0BC7\\u0BA3\\u0BCD\\u0B9F\\u0BC1\\u0BAE\\u0BCD`:`\\u0BAE\\u0BBF\\u0B95 \\u0BAA\\u0BC6\\u0BB0\\u0BBF\\u0BAF\\u0BA4\\u0BC1: \\u0B8E\\u0BA4\\u0BBF\\u0BB0\\u0BCD\\u0BAA\\u0BBE\\u0BB0\\u0BCD\\u0B95\\u0BCD\\u0B95\\u0BAA\\u0BCD\\u0BAA\\u0B9F\\u0BCD\\u0B9F\\u0BA4\\u0BC1 ${t.origin??"\\u0BAE\\u0BA4\\u0BBF\\u0BAA\\u0BCD\\u0BAA\\u0BC1"} ${o}${t.maximum.toString()} \\u0B86\\u0B95 \\u0B87\\u0BB0\\u0BC1\\u0B95\\u0BCD\\u0B95 \\u0BB5\\u0BC7\\u0BA3\\u0BCD\\u0B9F\\u0BC1\\u0BAE\\u0BCD`}case"too_small":{let o=t.inclusive?">=":">",a=n(t.origin);return a?`\\u0BAE\\u0BBF\\u0B95\\u0B9A\\u0BCD \\u0B9A\\u0BBF\\u0BB1\\u0BBF\\u0BAF\\u0BA4\\u0BC1: \\u0B8E\\u0BA4\\u0BBF\\u0BB0\\u0BCD\\u0BAA\\u0BBE\\u0BB0\\u0BCD\\u0B95\\u0BCD\\u0B95\\u0BAA\\u0BCD\\u0BAA\\u0B9F\\u0BCD\\u0B9F\\u0BA4\\u0BC1 ${t.origin} ${o}${t.minimum.toString()} ${a.unit} \\u0B86\\u0B95 \\u0B87\\u0BB0\\u0BC1\\u0B95\\u0BCD\\u0B95 \\u0BB5\\u0BC7\\u0BA3\\u0BCD\\u0B9F\\u0BC1\\u0BAE\\u0BCD`:`\\u0BAE\\u0BBF\\u0B95\\u0B9A\\u0BCD \\u0B9A\\u0BBF\\u0BB1\\u0BBF\\u0BAF\\u0BA4\\u0BC1: \\u0B8E\\u0BA4\\u0BBF\\u0BB0\\u0BCD\\u0BAA\\u0BBE\\u0BB0\\u0BCD\\u0B95\\u0BCD\\u0B95\\u0BAA\\u0BCD\\u0BAA\\u0B9F\\u0BCD\\u0B9F\\u0BA4\\u0BC1 ${t.origin} ${o}${t.minimum.toString()} \\u0B86\\u0B95 \\u0B87\\u0BB0\\u0BC1\\u0B95\\u0BCD\\u0B95 \\u0BB5\\u0BC7\\u0BA3\\u0BCD\\u0B9F\\u0BC1\\u0BAE\\u0BCD`}case"invalid_format":{let o=t;return o.format==="starts_with"?`\\u0BA4\\u0BB5\\u0BB1\\u0BBE\\u0BA9 \\u0B9A\\u0BB0\\u0BAE\\u0BCD: "${o.prefix}" \\u0B87\\u0BB2\\u0BCD \\u0BA4\\u0BCA\\u0B9F\\u0B99\\u0BCD\\u0B95 \\u0BB5\\u0BC7\\u0BA3\\u0BCD\\u0B9F\\u0BC1\\u0BAE\\u0BCD`:o.format==="ends_with"?`\\u0BA4\\u0BB5\\u0BB1\\u0BBE\\u0BA9 \\u0B9A\\u0BB0\\u0BAE\\u0BCD: "${o.suffix}" \\u0B87\\u0BB2\\u0BCD \\u0BAE\\u0BC1\\u0B9F\\u0BBF\\u0BB5\\u0B9F\\u0BC8\\u0BAF \\u0BB5\\u0BC7\\u0BA3\\u0BCD\\u0B9F\\u0BC1\\u0BAE\\u0BCD`:o.format==="includes"?`\\u0BA4\\u0BB5\\u0BB1\\u0BBE\\u0BA9 \\u0B9A\\u0BB0\\u0BAE\\u0BCD: "${o.includes}" \\u0B90 \\u0B89\\u0BB3\\u0BCD\\u0BB3\\u0B9F\\u0B95\\u0BCD\\u0B95 \\u0BB5\\u0BC7\\u0BA3\\u0BCD\\u0B9F\\u0BC1\\u0BAE\\u0BCD`:o.format==="regex"?`\\u0BA4\\u0BB5\\u0BB1\\u0BBE\\u0BA9 \\u0B9A\\u0BB0\\u0BAE\\u0BCD: ${o.pattern} \\u0BAE\\u0BC1\\u0BB1\\u0BC8\\u0BAA\\u0BBE\\u0B9F\\u0BCD\\u0B9F\\u0BC1\\u0B9F\\u0BA9\\u0BCD \\u0BAA\\u0BCA\\u0BB0\\u0BC1\\u0BA8\\u0BCD\\u0BA4 \\u0BB5\\u0BC7\\u0BA3\\u0BCD\\u0B9F\\u0BC1\\u0BAE\\u0BCD`:`\\u0BA4\\u0BB5\\u0BB1\\u0BBE\\u0BA9 ${i[o.format]??t.format}`}case"not_multiple_of":return`\\u0BA4\\u0BB5\\u0BB1\\u0BBE\\u0BA9 \\u0B8E\\u0BA3\\u0BCD: ${t.divisor} \\u0B87\\u0BA9\\u0BCD \\u0BAA\\u0BB2\\u0BAE\\u0BBE\\u0B95 \\u0B87\\u0BB0\\u0BC1\\u0B95\\u0BCD\\u0B95 \\u0BB5\\u0BC7\\u0BA3\\u0BCD\\u0B9F\\u0BC1\\u0BAE\\u0BCD`;case"unrecognized_keys":return`\\u0B85\\u0B9F\\u0BC8\\u0BAF\\u0BBE\\u0BB3\\u0BAE\\u0BCD \\u0BA4\\u0BC6\\u0BB0\\u0BBF\\u0BAF\\u0BBE\\u0BA4 \\u0BB5\\u0BBF\\u0B9A\\u0BC8${t.keys.length>1?"\\u0B95\\u0BB3\\u0BCD":""}: ${h(t.keys,", ")}`;case"invalid_key":return`${t.origin} \\u0B87\\u0BB2\\u0BCD \\u0BA4\\u0BB5\\u0BB1\\u0BBE\\u0BA9 \\u0BB5\\u0BBF\\u0B9A\\u0BC8`;case"invalid_union":return"\\u0BA4\\u0BB5\\u0BB1\\u0BBE\\u0BA9 \\u0B89\\u0BB3\\u0BCD\\u0BB3\\u0BC0\\u0B9F\\u0BC1";case"invalid_element":return`${t.origin} \\u0B87\\u0BB2\\u0BCD \\u0BA4\\u0BB5\\u0BB1\\u0BBE\\u0BA9 \\u0BAE\\u0BA4\\u0BBF\\u0BAA\\u0BCD\\u0BAA\\u0BC1`;default:return"\\u0BA4\\u0BB5\\u0BB1\\u0BBE\\u0BA9 \\u0B89\\u0BB3\\u0BCD\\u0BB3\\u0BC0\\u0B9F\\u0BC1"}}}});function Hc(){return{localeError:Ef()}}var Ef,Vc=S(()=>{T();Ef=()=>{let e={string:{unit:"\\u0E15\\u0E31\\u0E27\\u0E2D\\u0E31\\u0E01\\u0E29\\u0E23",verb:"\\u0E04\\u0E27\\u0E23\\u0E21\\u0E35"},file:{unit:"\\u0E44\\u0E1A\\u0E15\\u0E4C",verb:"\\u0E04\\u0E27\\u0E23\\u0E21\\u0E35"},array:{unit:"\\u0E23\\u0E32\\u0E22\\u0E01\\u0E32\\u0E23",verb:"\\u0E04\\u0E27\\u0E23\\u0E21\\u0E35"},set:{unit:"\\u0E23\\u0E32\\u0E22\\u0E01\\u0E32\\u0E23",verb:"\\u0E04\\u0E27\\u0E23\\u0E21\\u0E35"}};function n(t){return e[t]??null}let r=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"\\u0E44\\u0E21\\u0E48\\u0E43\\u0E0A\\u0E48\\u0E15\\u0E31\\u0E27\\u0E40\\u0E25\\u0E02 (NaN)":"\\u0E15\\u0E31\\u0E27\\u0E40\\u0E25\\u0E02";case"object":{if(Array.isArray(t))return"\\u0E2D\\u0E32\\u0E23\\u0E4C\\u0E40\\u0E23\\u0E22\\u0E4C (Array)";if(t===null)return"\\u0E44\\u0E21\\u0E48\\u0E21\\u0E35\\u0E04\\u0E48\\u0E32 (null)";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"\\u0E02\\u0E49\\u0E2D\\u0E21\\u0E39\\u0E25\\u0E17\\u0E35\\u0E48\\u0E1B\\u0E49\\u0E2D\\u0E19",email:"\\u0E17\\u0E35\\u0E48\\u0E2D\\u0E22\\u0E39\\u0E48\\u0E2D\\u0E35\\u0E40\\u0E21\\u0E25",url:"URL",emoji:"\\u0E2D\\u0E34\\u0E42\\u0E21\\u0E08\\u0E34",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"\\u0E27\\u0E31\\u0E19\\u0E17\\u0E35\\u0E48\\u0E40\\u0E27\\u0E25\\u0E32\\u0E41\\u0E1A\\u0E1A ISO",date:"\\u0E27\\u0E31\\u0E19\\u0E17\\u0E35\\u0E48\\u0E41\\u0E1A\\u0E1A ISO",time:"\\u0E40\\u0E27\\u0E25\\u0E32\\u0E41\\u0E1A\\u0E1A ISO",duration:"\\u0E0A\\u0E48\\u0E27\\u0E07\\u0E40\\u0E27\\u0E25\\u0E32\\u0E41\\u0E1A\\u0E1A ISO",ipv4:"\\u0E17\\u0E35\\u0E48\\u0E2D\\u0E22\\u0E39\\u0E48 IPv4",ipv6:"\\u0E17\\u0E35\\u0E48\\u0E2D\\u0E22\\u0E39\\u0E48 IPv6",cidrv4:"\\u0E0A\\u0E48\\u0E27\\u0E07 IP \\u0E41\\u0E1A\\u0E1A IPv4",cidrv6:"\\u0E0A\\u0E48\\u0E27\\u0E07 IP \\u0E41\\u0E1A\\u0E1A IPv6",base64:"\\u0E02\\u0E49\\u0E2D\\u0E04\\u0E27\\u0E32\\u0E21\\u0E41\\u0E1A\\u0E1A Base64",base64url:"\\u0E02\\u0E49\\u0E2D\\u0E04\\u0E27\\u0E32\\u0E21\\u0E41\\u0E1A\\u0E1A Base64 \\u0E2A\\u0E33\\u0E2B\\u0E23\\u0E31\\u0E1A URL",json_string:"\\u0E02\\u0E49\\u0E2D\\u0E04\\u0E27\\u0E32\\u0E21\\u0E41\\u0E1A\\u0E1A JSON",e164:"\\u0E40\\u0E1A\\u0E2D\\u0E23\\u0E4C\\u0E42\\u0E17\\u0E23\\u0E28\\u0E31\\u0E1E\\u0E17\\u0E4C\\u0E23\\u0E30\\u0E2B\\u0E27\\u0E48\\u0E32\\u0E07\\u0E1B\\u0E23\\u0E30\\u0E40\\u0E17\\u0E28 (E.164)",jwt:"\\u0E42\\u0E17\\u0E40\\u0E04\\u0E19 JWT",template_literal:"\\u0E02\\u0E49\\u0E2D\\u0E21\\u0E39\\u0E25\\u0E17\\u0E35\\u0E48\\u0E1B\\u0E49\\u0E2D\\u0E19"};return t=>{switch(t.code){case"invalid_type":return`\\u0E1B\\u0E23\\u0E30\\u0E40\\u0E20\\u0E17\\u0E02\\u0E49\\u0E2D\\u0E21\\u0E39\\u0E25\\u0E44\\u0E21\\u0E48\\u0E16\\u0E39\\u0E01\\u0E15\\u0E49\\u0E2D\\u0E07: \\u0E04\\u0E27\\u0E23\\u0E40\\u0E1B\\u0E47\\u0E19 ${t.expected} \\u0E41\\u0E15\\u0E48\\u0E44\\u0E14\\u0E49\\u0E23\\u0E31\\u0E1A ${r(t.input)}`;case"invalid_value":return t.values.length===1?`\\u0E04\\u0E48\\u0E32\\u0E44\\u0E21\\u0E48\\u0E16\\u0E39\\u0E01\\u0E15\\u0E49\\u0E2D\\u0E07: \\u0E04\\u0E27\\u0E23\\u0E40\\u0E1B\\u0E47\\u0E19 ${x(t.values[0])}`:`\\u0E15\\u0E31\\u0E27\\u0E40\\u0E25\\u0E37\\u0E2D\\u0E01\\u0E44\\u0E21\\u0E48\\u0E16\\u0E39\\u0E01\\u0E15\\u0E49\\u0E2D\\u0E07: \\u0E04\\u0E27\\u0E23\\u0E40\\u0E1B\\u0E47\\u0E19\\u0E2B\\u0E19\\u0E36\\u0E48\\u0E07\\u0E43\\u0E19 ${h(t.values,"|")}`;case"too_big":{let o=t.inclusive?"\\u0E44\\u0E21\\u0E48\\u0E40\\u0E01\\u0E34\\u0E19":"\\u0E19\\u0E49\\u0E2D\\u0E22\\u0E01\\u0E27\\u0E48\\u0E32",a=n(t.origin);return a?`\\u0E40\\u0E01\\u0E34\\u0E19\\u0E01\\u0E33\\u0E2B\\u0E19\\u0E14: ${t.origin??"\\u0E04\\u0E48\\u0E32"} \\u0E04\\u0E27\\u0E23\\u0E21\\u0E35${o} ${t.maximum.toString()} ${a.unit??"\\u0E23\\u0E32\\u0E22\\u0E01\\u0E32\\u0E23"}`:`\\u0E40\\u0E01\\u0E34\\u0E19\\u0E01\\u0E33\\u0E2B\\u0E19\\u0E14: ${t.origin??"\\u0E04\\u0E48\\u0E32"} \\u0E04\\u0E27\\u0E23\\u0E21\\u0E35${o} ${t.maximum.toString()}`}case"too_small":{let o=t.inclusive?"\\u0E2D\\u0E22\\u0E48\\u0E32\\u0E07\\u0E19\\u0E49\\u0E2D\\u0E22":"\\u0E21\\u0E32\\u0E01\\u0E01\\u0E27\\u0E48\\u0E32",a=n(t.origin);return a?`\\u0E19\\u0E49\\u0E2D\\u0E22\\u0E01\\u0E27\\u0E48\\u0E32\\u0E01\\u0E33\\u0E2B\\u0E19\\u0E14: ${t.origin} \\u0E04\\u0E27\\u0E23\\u0E21\\u0E35${o} ${t.minimum.toString()} ${a.unit}`:`\\u0E19\\u0E49\\u0E2D\\u0E22\\u0E01\\u0E27\\u0E48\\u0E32\\u0E01\\u0E33\\u0E2B\\u0E19\\u0E14: ${t.origin} \\u0E04\\u0E27\\u0E23\\u0E21\\u0E35${o} ${t.minimum.toString()}`}case"invalid_format":{let o=t;return o.format==="starts_with"?`\\u0E23\\u0E39\\u0E1B\\u0E41\\u0E1A\\u0E1A\\u0E44\\u0E21\\u0E48\\u0E16\\u0E39\\u0E01\\u0E15\\u0E49\\u0E2D\\u0E07: \\u0E02\\u0E49\\u0E2D\\u0E04\\u0E27\\u0E32\\u0E21\\u0E15\\u0E49\\u0E2D\\u0E07\\u0E02\\u0E36\\u0E49\\u0E19\\u0E15\\u0E49\\u0E19\\u0E14\\u0E49\\u0E27\\u0E22 "${o.prefix}"`:o.format==="ends_with"?`\\u0E23\\u0E39\\u0E1B\\u0E41\\u0E1A\\u0E1A\\u0E44\\u0E21\\u0E48\\u0E16\\u0E39\\u0E01\\u0E15\\u0E49\\u0E2D\\u0E07: \\u0E02\\u0E49\\u0E2D\\u0E04\\u0E27\\u0E32\\u0E21\\u0E15\\u0E49\\u0E2D\\u0E07\\u0E25\\u0E07\\u0E17\\u0E49\\u0E32\\u0E22\\u0E14\\u0E49\\u0E27\\u0E22 "${o.suffix}"`:o.format==="includes"?`\\u0E23\\u0E39\\u0E1B\\u0E41\\u0E1A\\u0E1A\\u0E44\\u0E21\\u0E48\\u0E16\\u0E39\\u0E01\\u0E15\\u0E49\\u0E2D\\u0E07: \\u0E02\\u0E49\\u0E2D\\u0E04\\u0E27\\u0E32\\u0E21\\u0E15\\u0E49\\u0E2D\\u0E07\\u0E21\\u0E35 "${o.includes}" \\u0E2D\\u0E22\\u0E39\\u0E48\\u0E43\\u0E19\\u0E02\\u0E49\\u0E2D\\u0E04\\u0E27\\u0E32\\u0E21`:o.format==="regex"?`\\u0E23\\u0E39\\u0E1B\\u0E41\\u0E1A\\u0E1A\\u0E44\\u0E21\\u0E48\\u0E16\\u0E39\\u0E01\\u0E15\\u0E49\\u0E2D\\u0E07: \\u0E15\\u0E49\\u0E2D\\u0E07\\u0E15\\u0E23\\u0E07\\u0E01\\u0E31\\u0E1A\\u0E23\\u0E39\\u0E1B\\u0E41\\u0E1A\\u0E1A\\u0E17\\u0E35\\u0E48\\u0E01\\u0E33\\u0E2B\\u0E19\\u0E14 ${o.pattern}`:`\\u0E23\\u0E39\\u0E1B\\u0E41\\u0E1A\\u0E1A\\u0E44\\u0E21\\u0E48\\u0E16\\u0E39\\u0E01\\u0E15\\u0E49\\u0E2D\\u0E07: ${i[o.format]??t.format}`}case"not_multiple_of":return`\\u0E15\\u0E31\\u0E27\\u0E40\\u0E25\\u0E02\\u0E44\\u0E21\\u0E48\\u0E16\\u0E39\\u0E01\\u0E15\\u0E49\\u0E2D\\u0E07: \\u0E15\\u0E49\\u0E2D\\u0E07\\u0E40\\u0E1B\\u0E47\\u0E19\\u0E08\\u0E33\\u0E19\\u0E27\\u0E19\\u0E17\\u0E35\\u0E48\\u0E2B\\u0E32\\u0E23\\u0E14\\u0E49\\u0E27\\u0E22 ${t.divisor} \\u0E44\\u0E14\\u0E49\\u0E25\\u0E07\\u0E15\\u0E31\\u0E27`;case"unrecognized_keys":return`\\u0E1E\\u0E1A\\u0E04\\u0E35\\u0E22\\u0E4C\\u0E17\\u0E35\\u0E48\\u0E44\\u0E21\\u0E48\\u0E23\\u0E39\\u0E49\\u0E08\\u0E31\\u0E01: ${h(t.keys,", ")}`;case"invalid_key":return`\\u0E04\\u0E35\\u0E22\\u0E4C\\u0E44\\u0E21\\u0E48\\u0E16\\u0E39\\u0E01\\u0E15\\u0E49\\u0E2D\\u0E07\\u0E43\\u0E19 ${t.origin}`;case"invalid_union":return"\\u0E02\\u0E49\\u0E2D\\u0E21\\u0E39\\u0E25\\u0E44\\u0E21\\u0E48\\u0E16\\u0E39\\u0E01\\u0E15\\u0E49\\u0E2D\\u0E07: \\u0E44\\u0E21\\u0E48\\u0E15\\u0E23\\u0E07\\u0E01\\u0E31\\u0E1A\\u0E23\\u0E39\\u0E1B\\u0E41\\u0E1A\\u0E1A\\u0E22\\u0E39\\u0E40\\u0E19\\u0E35\\u0E22\\u0E19\\u0E17\\u0E35\\u0E48\\u0E01\\u0E33\\u0E2B\\u0E19\\u0E14\\u0E44\\u0E27\\u0E49";case"invalid_element":return`\\u0E02\\u0E49\\u0E2D\\u0E21\\u0E39\\u0E25\\u0E44\\u0E21\\u0E48\\u0E16\\u0E39\\u0E01\\u0E15\\u0E49\\u0E2D\\u0E07\\u0E43\\u0E19 ${t.origin}`;default:return"\\u0E02\\u0E49\\u0E2D\\u0E21\\u0E39\\u0E25\\u0E44\\u0E21\\u0E48\\u0E16\\u0E39\\u0E01\\u0E15\\u0E49\\u0E2D\\u0E07"}}}});function Jc(){return{localeError:Uf()}}var Rf,Uf,Wc=S(()=>{T();Rf=e=>{let n=typeof e;switch(n){case"number":return Number.isNaN(e)?"NaN":"number";case"object":{if(Array.isArray(e))return"array";if(e===null)return"null";if(Object.getPrototypeOf(e)!==Object.prototype&&e.constructor)return e.constructor.name}}return n},Uf=()=>{let e={string:{unit:"karakter",verb:"olmal\\u0131"},file:{unit:"bayt",verb:"olmal\\u0131"},array:{unit:"\\xF6\\u011Fe",verb:"olmal\\u0131"},set:{unit:"\\xF6\\u011Fe",verb:"olmal\\u0131"}};function n(i){return e[i]??null}let r={regex:"girdi",email:"e-posta adresi",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO tarih ve saat",date:"ISO tarih",time:"ISO saat",duration:"ISO s\\xFCre",ipv4:"IPv4 adresi",ipv6:"IPv6 adresi",cidrv4:"IPv4 aral\\u0131\\u011F\\u0131",cidrv6:"IPv6 aral\\u0131\\u011F\\u0131",base64:"base64 ile \\u015Fifrelenmi\\u015F metin",base64url:"base64url ile \\u015Fifrelenmi\\u015F metin",json_string:"JSON dizesi",e164:"E.164 say\\u0131s\\u0131",jwt:"JWT",template_literal:"\\u015Eablon dizesi"};return i=>{switch(i.code){case"invalid_type":return`Ge\\xE7ersiz de\\u011Fer: beklenen ${i.expected}, al\\u0131nan ${Rf(i.input)}`;case"invalid_value":return i.values.length===1?`Ge\\xE7ersiz de\\u011Fer: beklenen ${x(i.values[0])}`:`Ge\\xE7ersiz se\\xE7enek: a\\u015Fa\\u011F\\u0131dakilerden biri olmal\\u0131: ${h(i.values,"|")}`;case"too_big":{let t=i.inclusive?"<=":"<",o=n(i.origin);return o?`\\xC7ok b\\xFCy\\xFCk: beklenen ${i.origin??"de\\u011Fer"} ${t}${i.maximum.toString()} ${o.unit??"\\xF6\\u011Fe"}`:`\\xC7ok b\\xFCy\\xFCk: beklenen ${i.origin??"de\\u011Fer"} ${t}${i.maximum.toString()}`}case"too_small":{let t=i.inclusive?">=":">",o=n(i.origin);return o?`\\xC7ok k\\xFC\\xE7\\xFCk: beklenen ${i.origin} ${t}${i.minimum.toString()} ${o.unit}`:`\\xC7ok k\\xFC\\xE7\\xFCk: beklenen ${i.origin} ${t}${i.minimum.toString()}`}case"invalid_format":{let t=i;return t.format==="starts_with"?`Ge\\xE7ersiz metin: "${t.prefix}" ile ba\\u015Flamal\\u0131`:t.format==="ends_with"?`Ge\\xE7ersiz metin: "${t.suffix}" ile bitmeli`:t.format==="includes"?`Ge\\xE7ersiz metin: "${t.includes}" i\\xE7ermeli`:t.format==="regex"?`Ge\\xE7ersiz metin: ${t.pattern} desenine uymal\\u0131`:`Ge\\xE7ersiz ${r[t.format]??i.format}`}case"not_multiple_of":return`Ge\\xE7ersiz say\\u0131: ${i.divisor} ile tam b\\xF6l\\xFCnebilmeli`;case"unrecognized_keys":return`Tan\\u0131nmayan anahtar${i.keys.length>1?"lar":""}: ${h(i.keys,", ")}`;case"invalid_key":return`${i.origin} i\\xE7inde ge\\xE7ersiz anahtar`;case"invalid_union":return"Ge\\xE7ersiz de\\u011Fer";case"invalid_element":return`${i.origin} i\\xE7inde ge\\xE7ersiz de\\u011Fer`;default:return"Ge\\xE7ersiz de\\u011Fer"}}}});function Kc(){return{localeError:Cf()}}var Cf,Bc=S(()=>{T();Cf=()=>{let e={string:{unit:"\\u0441\\u0438\\u043C\\u0432\\u043E\\u043B\\u0456\\u0432",verb:"\\u043C\\u0430\\u0442\\u0438\\u043C\\u0435"},file:{unit:"\\u0431\\u0430\\u0439\\u0442\\u0456\\u0432",verb:"\\u043C\\u0430\\u0442\\u0438\\u043C\\u0435"},array:{unit:"\\u0435\\u043B\\u0435\\u043C\\u0435\\u043D\\u0442\\u0456\\u0432",verb:"\\u043C\\u0430\\u0442\\u0438\\u043C\\u0435"},set:{unit:"\\u0435\\u043B\\u0435\\u043C\\u0435\\u043D\\u0442\\u0456\\u0432",verb:"\\u043C\\u0430\\u0442\\u0438\\u043C\\u0435"}};function n(t){return e[t]??null}let r=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"\\u0447\\u0438\\u0441\\u043B\\u043E";case"object":{if(Array.isArray(t))return"\\u043C\\u0430\\u0441\\u0438\\u0432";if(t===null)return"null";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"\\u0432\\u0445\\u0456\\u0434\\u043D\\u0456 \\u0434\\u0430\\u043D\\u0456",email:"\\u0430\\u0434\\u0440\\u0435\\u0441\\u0430 \\u0435\\u043B\\u0435\\u043A\\u0442\\u0440\\u043E\\u043D\\u043D\\u043E\\u0457 \\u043F\\u043E\\u0448\\u0442\\u0438",url:"URL",emoji:"\\u0435\\u043C\\u043E\\u0434\\u0437\\u0456",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"\\u0434\\u0430\\u0442\\u0430 \\u0442\\u0430 \\u0447\\u0430\\u0441 ISO",date:"\\u0434\\u0430\\u0442\\u0430 ISO",time:"\\u0447\\u0430\\u0441 ISO",duration:"\\u0442\\u0440\\u0438\\u0432\\u0430\\u043B\\u0456\\u0441\\u0442\\u044C ISO",ipv4:"\\u0430\\u0434\\u0440\\u0435\\u0441\\u0430 IPv4",ipv6:"\\u0430\\u0434\\u0440\\u0435\\u0441\\u0430 IPv6",cidrv4:"\\u0434\\u0456\\u0430\\u043F\\u0430\\u0437\\u043E\\u043D IPv4",cidrv6:"\\u0434\\u0456\\u0430\\u043F\\u0430\\u0437\\u043E\\u043D IPv6",base64:"\\u0440\\u044F\\u0434\\u043E\\u043A \\u0443 \\u043A\\u043E\\u0434\\u0443\\u0432\\u0430\\u043D\\u043D\\u0456 base64",base64url:"\\u0440\\u044F\\u0434\\u043E\\u043A \\u0443 \\u043A\\u043E\\u0434\\u0443\\u0432\\u0430\\u043D\\u043D\\u0456 base64url",json_string:"\\u0440\\u044F\\u0434\\u043E\\u043A JSON",e164:"\\u043D\\u043E\\u043C\\u0435\\u0440 E.164",jwt:"JWT",template_literal:"\\u0432\\u0445\\u0456\\u0434\\u043D\\u0456 \\u0434\\u0430\\u043D\\u0456"};return t=>{switch(t.code){case"invalid_type":return`\\u041D\\u0435\\u043F\\u0440\\u0430\\u0432\\u0438\\u043B\\u044C\\u043D\\u0456 \\u0432\\u0445\\u0456\\u0434\\u043D\\u0456 \\u0434\\u0430\\u043D\\u0456: \\u043E\\u0447\\u0456\\u043A\\u0443\\u0454\\u0442\\u044C\\u0441\\u044F ${t.expected}, \\u043E\\u0442\\u0440\\u0438\\u043C\\u0430\\u043D\\u043E ${r(t.input)}`;case"invalid_value":return t.values.length===1?`\\u041D\\u0435\\u043F\\u0440\\u0430\\u0432\\u0438\\u043B\\u044C\\u043D\\u0456 \\u0432\\u0445\\u0456\\u0434\\u043D\\u0456 \\u0434\\u0430\\u043D\\u0456: \\u043E\\u0447\\u0456\\u043A\\u0443\\u0454\\u0442\\u044C\\u0441\\u044F ${x(t.values[0])}`:`\\u041D\\u0435\\u043F\\u0440\\u0430\\u0432\\u0438\\u043B\\u044C\\u043D\\u0430 \\u043E\\u043F\\u0446\\u0456\\u044F: \\u043E\\u0447\\u0456\\u043A\\u0443\\u0454\\u0442\\u044C\\u0441\\u044F \\u043E\\u0434\\u043D\\u0435 \\u0437 ${h(t.values,"|")}`;case"too_big":{let o=t.inclusive?"<=":"<",a=n(t.origin);return a?`\\u0417\\u0430\\u043D\\u0430\\u0434\\u0442\\u043E \\u0432\\u0435\\u043B\\u0438\\u043A\\u0435: \\u043E\\u0447\\u0456\\u043A\\u0443\\u0454\\u0442\\u044C\\u0441\\u044F, \\u0449\\u043E ${t.origin??"\\u0437\\u043D\\u0430\\u0447\\u0435\\u043D\\u043D\\u044F"} ${a.verb} ${o}${t.maximum.toString()} ${a.unit??"\\u0435\\u043B\\u0435\\u043C\\u0435\\u043D\\u0442\\u0456\\u0432"}`:`\\u0417\\u0430\\u043D\\u0430\\u0434\\u0442\\u043E \\u0432\\u0435\\u043B\\u0438\\u043A\\u0435: \\u043E\\u0447\\u0456\\u043A\\u0443\\u0454\\u0442\\u044C\\u0441\\u044F, \\u0449\\u043E ${t.origin??"\\u0437\\u043D\\u0430\\u0447\\u0435\\u043D\\u043D\\u044F"} \\u0431\\u0443\\u0434\\u0435 ${o}${t.maximum.toString()}`}case"too_small":{let o=t.inclusive?">=":">",a=n(t.origin);return a?`\\u0417\\u0430\\u043D\\u0430\\u0434\\u0442\\u043E \\u043C\\u0430\\u043B\\u0435: \\u043E\\u0447\\u0456\\u043A\\u0443\\u0454\\u0442\\u044C\\u0441\\u044F, \\u0449\\u043E ${t.origin} ${a.verb} ${o}${t.minimum.toString()} ${a.unit}`:`\\u0417\\u0430\\u043D\\u0430\\u0434\\u0442\\u043E \\u043C\\u0430\\u043B\\u0435: \\u043E\\u0447\\u0456\\u043A\\u0443\\u0454\\u0442\\u044C\\u0441\\u044F, \\u0449\\u043E ${t.origin} \\u0431\\u0443\\u0434\\u0435 ${o}${t.minimum.toString()}`}case"invalid_format":{let o=t;return o.format==="starts_with"?`\\u041D\\u0435\\u043F\\u0440\\u0430\\u0432\\u0438\\u043B\\u044C\\u043D\\u0438\\u0439 \\u0440\\u044F\\u0434\\u043E\\u043A: \\u043F\\u043E\\u0432\\u0438\\u043D\\u0435\\u043D \\u043F\\u043E\\u0447\\u0438\\u043D\\u0430\\u0442\\u0438\\u0441\\u044F \\u0437 "${o.prefix}"`:o.format==="ends_with"?`\\u041D\\u0435\\u043F\\u0440\\u0430\\u0432\\u0438\\u043B\\u044C\\u043D\\u0438\\u0439 \\u0440\\u044F\\u0434\\u043E\\u043A: \\u043F\\u043E\\u0432\\u0438\\u043D\\u0435\\u043D \\u0437\\u0430\\u043A\\u0456\\u043D\\u0447\\u0443\\u0432\\u0430\\u0442\\u0438\\u0441\\u044F \\u043D\\u0430 "${o.suffix}"`:o.format==="includes"?`\\u041D\\u0435\\u043F\\u0440\\u0430\\u0432\\u0438\\u043B\\u044C\\u043D\\u0438\\u0439 \\u0440\\u044F\\u0434\\u043E\\u043A: \\u043F\\u043E\\u0432\\u0438\\u043D\\u0435\\u043D \\u043C\\u0456\\u0441\\u0442\\u0438\\u0442\\u0438 "${o.includes}"`:o.format==="regex"?`\\u041D\\u0435\\u043F\\u0440\\u0430\\u0432\\u0438\\u043B\\u044C\\u043D\\u0438\\u0439 \\u0440\\u044F\\u0434\\u043E\\u043A: \\u043F\\u043E\\u0432\\u0438\\u043D\\u0435\\u043D \\u0432\\u0456\\u0434\\u043F\\u043E\\u0432\\u0456\\u0434\\u0430\\u0442\\u0438 \\u0448\\u0430\\u0431\\u043B\\u043E\\u043D\\u0443 ${o.pattern}`:`\\u041D\\u0435\\u043F\\u0440\\u0430\\u0432\\u0438\\u043B\\u044C\\u043D\\u0438\\u0439 ${i[o.format]??t.format}`}case"not_multiple_of":return`\\u041D\\u0435\\u043F\\u0440\\u0430\\u0432\\u0438\\u043B\\u044C\\u043D\\u0435 \\u0447\\u0438\\u0441\\u043B\\u043E: \\u043F\\u043E\\u0432\\u0438\\u043D\\u043D\\u043E \\u0431\\u0443\\u0442\\u0438 \\u043A\\u0440\\u0430\\u0442\\u043D\\u0438\\u043C ${t.divisor}`;case"unrecognized_keys":return`\\u041D\\u0435\\u0440\\u043E\\u0437\\u043F\\u0456\\u0437\\u043D\\u0430\\u043D\\u0438\\u0439 \\u043A\\u043B\\u044E\\u0447${t.keys.length>1?"\\u0456":""}: ${h(t.keys,", ")}`;case"invalid_key":return`\\u041D\\u0435\\u043F\\u0440\\u0430\\u0432\\u0438\\u043B\\u044C\\u043D\\u0438\\u0439 \\u043A\\u043B\\u044E\\u0447 \\u0443 ${t.origin}`;case"invalid_union":return"\\u041D\\u0435\\u043F\\u0440\\u0430\\u0432\\u0438\\u043B\\u044C\\u043D\\u0456 \\u0432\\u0445\\u0456\\u0434\\u043D\\u0456 \\u0434\\u0430\\u043D\\u0456";case"invalid_element":return`\\u041D\\u0435\\u043F\\u0440\\u0430\\u0432\\u0438\\u043B\\u044C\\u043D\\u0435 \\u0437\\u043D\\u0430\\u0447\\u0435\\u043D\\u043D\\u044F \\u0443 ${t.origin}`;default:return"\\u041D\\u0435\\u043F\\u0440\\u0430\\u0432\\u0438\\u043B\\u044C\\u043D\\u0456 \\u0432\\u0445\\u0456\\u0434\\u043D\\u0456 \\u0434\\u0430\\u043D\\u0456"}}}});function Gc(){return{localeError:Df()}}var Df,Qc=S(()=>{T();Df=()=>{let e={string:{unit:"\\u062D\\u0631\\u0648\\u0641",verb:"\\u06C1\\u0648\\u0646\\u0627"},file:{unit:"\\u0628\\u0627\\u0626\\u0679\\u0633",verb:"\\u06C1\\u0648\\u0646\\u0627"},array:{unit:"\\u0622\\u0626\\u0679\\u0645\\u0632",verb:"\\u06C1\\u0648\\u0646\\u0627"},set:{unit:"\\u0622\\u0626\\u0679\\u0645\\u0632",verb:"\\u06C1\\u0648\\u0646\\u0627"}};function n(t){return e[t]??null}let r=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"\\u0646\\u0645\\u0628\\u0631";case"object":{if(Array.isArray(t))return"\\u0622\\u0631\\u06D2";if(t===null)return"\\u0646\\u0644";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"\\u0627\\u0646 \\u067E\\u0679",email:"\\u0627\\u06CC \\u0645\\u06CC\\u0644 \\u0627\\u06CC\\u0688\\u0631\\u06CC\\u0633",url:"\\u06CC\\u0648 \\u0622\\u0631 \\u0627\\u06CC\\u0644",emoji:"\\u0627\\u06CC\\u0645\\u0648\\u062C\\u06CC",uuid:"\\u06CC\\u0648 \\u06CC\\u0648 \\u0622\\u0626\\u06CC \\u0688\\u06CC",uuidv4:"\\u06CC\\u0648 \\u06CC\\u0648 \\u0622\\u0626\\u06CC \\u0688\\u06CC \\u0648\\u06CC 4",uuidv6:"\\u06CC\\u0648 \\u06CC\\u0648 \\u0622\\u0626\\u06CC \\u0688\\u06CC \\u0648\\u06CC 6",nanoid:"\\u0646\\u06CC\\u0646\\u0648 \\u0622\\u0626\\u06CC \\u0688\\u06CC",guid:"\\u062C\\u06CC \\u06CC\\u0648 \\u0622\\u0626\\u06CC \\u0688\\u06CC",cuid:"\\u0633\\u06CC \\u06CC\\u0648 \\u0622\\u0626\\u06CC \\u0688\\u06CC",cuid2:"\\u0633\\u06CC \\u06CC\\u0648 \\u0622\\u0626\\u06CC \\u0688\\u06CC 2",ulid:"\\u06CC\\u0648 \\u0627\\u06CC\\u0644 \\u0622\\u0626\\u06CC \\u0688\\u06CC",xid:"\\u0627\\u06CC\\u06A9\\u0633 \\u0622\\u0626\\u06CC \\u0688\\u06CC",ksuid:"\\u06A9\\u06D2 \\u0627\\u06CC\\u0633 \\u06CC\\u0648 \\u0622\\u0626\\u06CC \\u0688\\u06CC",datetime:"\\u0622\\u0626\\u06CC \\u0627\\u06CC\\u0633 \\u0627\\u0648 \\u0688\\u06CC\\u0679 \\u0679\\u0627\\u0626\\u0645",date:"\\u0622\\u0626\\u06CC \\u0627\\u06CC\\u0633 \\u0627\\u0648 \\u062A\\u0627\\u0631\\u06CC\\u062E",time:"\\u0622\\u0626\\u06CC \\u0627\\u06CC\\u0633 \\u0627\\u0648 \\u0648\\u0642\\u062A",duration:"\\u0622\\u0626\\u06CC \\u0627\\u06CC\\u0633 \\u0627\\u0648 \\u0645\\u062F\\u062A",ipv4:"\\u0622\\u0626\\u06CC \\u067E\\u06CC \\u0648\\u06CC 4 \\u0627\\u06CC\\u0688\\u0631\\u06CC\\u0633",ipv6:"\\u0622\\u0626\\u06CC \\u067E\\u06CC \\u0648\\u06CC 6 \\u0627\\u06CC\\u0688\\u0631\\u06CC\\u0633",cidrv4:"\\u0622\\u0626\\u06CC \\u067E\\u06CC \\u0648\\u06CC 4 \\u0631\\u06CC\\u0646\\u062C",cidrv6:"\\u0622\\u0626\\u06CC \\u067E\\u06CC \\u0648\\u06CC 6 \\u0631\\u06CC\\u0646\\u062C",base64:"\\u0628\\u06CC\\u0633 64 \\u0627\\u0646 \\u06A9\\u0648\\u0688\\u0688 \\u0633\\u0679\\u0631\\u0646\\u06AF",base64url:"\\u0628\\u06CC\\u0633 64 \\u06CC\\u0648 \\u0622\\u0631 \\u0627\\u06CC\\u0644 \\u0627\\u0646 \\u06A9\\u0648\\u0688\\u0688 \\u0633\\u0679\\u0631\\u0646\\u06AF",json_string:"\\u062C\\u06D2 \\u0627\\u06CC\\u0633 \\u0627\\u0648 \\u0627\\u06CC\\u0646 \\u0633\\u0679\\u0631\\u0646\\u06AF",e164:"\\u0627\\u06CC 164 \\u0646\\u0645\\u0628\\u0631",jwt:"\\u062C\\u06D2 \\u0688\\u0628\\u0644\\u06CC\\u0648 \\u0679\\u06CC",template_literal:"\\u0627\\u0646 \\u067E\\u0679"};return t=>{switch(t.code){case"invalid_type":return`\\u063A\\u0644\\u0637 \\u0627\\u0646 \\u067E\\u0679: ${t.expected} \\u0645\\u062A\\u0648\\u0642\\u0639 \\u062A\\u06BE\\u0627\\u060C ${r(t.input)} \\u0645\\u0648\\u0635\\u0648\\u0644 \\u06C1\\u0648\\u0627`;case"invalid_value":return t.values.length===1?`\\u063A\\u0644\\u0637 \\u0627\\u0646 \\u067E\\u0679: ${x(t.values[0])} \\u0645\\u062A\\u0648\\u0642\\u0639 \\u062A\\u06BE\\u0627`:`\\u063A\\u0644\\u0637 \\u0622\\u067E\\u0634\\u0646: ${h(t.values,"|")} \\u0645\\u06CC\\u06BA \\u0633\\u06D2 \\u0627\\u06CC\\u06A9 \\u0645\\u062A\\u0648\\u0642\\u0639 \\u062A\\u06BE\\u0627`;case"too_big":{let o=t.inclusive?"<=":"<",a=n(t.origin);return a?`\\u0628\\u06C1\\u062A \\u0628\\u0691\\u0627: ${t.origin??"\\u0648\\u06CC\\u0644\\u06CC\\u0648"} \\u06A9\\u06D2 ${o}${t.maximum.toString()} ${a.unit??"\\u0639\\u0646\\u0627\\u0635\\u0631"} \\u06C1\\u0648\\u0646\\u06D2 \\u0645\\u062A\\u0648\\u0642\\u0639 \\u062A\\u06BE\\u06D2`:`\\u0628\\u06C1\\u062A \\u0628\\u0691\\u0627: ${t.origin??"\\u0648\\u06CC\\u0644\\u06CC\\u0648"} \\u06A9\\u0627 ${o}${t.maximum.toString()} \\u06C1\\u0648\\u0646\\u0627 \\u0645\\u062A\\u0648\\u0642\\u0639 \\u062A\\u06BE\\u0627`}case"too_small":{let o=t.inclusive?">=":">",a=n(t.origin);return a?`\\u0628\\u06C1\\u062A \\u0686\\u06BE\\u0648\\u0679\\u0627: ${t.origin} \\u06A9\\u06D2 ${o}${t.minimum.toString()} ${a.unit} \\u06C1\\u0648\\u0646\\u06D2 \\u0645\\u062A\\u0648\\u0642\\u0639 \\u062A\\u06BE\\u06D2`:`\\u0628\\u06C1\\u062A \\u0686\\u06BE\\u0648\\u0679\\u0627: ${t.origin} \\u06A9\\u0627 ${o}${t.minimum.toString()} \\u06C1\\u0648\\u0646\\u0627 \\u0645\\u062A\\u0648\\u0642\\u0639 \\u062A\\u06BE\\u0627`}case"invalid_format":{let o=t;return o.format==="starts_with"?`\\u063A\\u0644\\u0637 \\u0633\\u0679\\u0631\\u0646\\u06AF: "${o.prefix}" \\u0633\\u06D2 \\u0634\\u0631\\u0648\\u0639 \\u06C1\\u0648\\u0646\\u0627 \\u0686\\u0627\\u06C1\\u06CC\\u06D2`:o.format==="ends_with"?`\\u063A\\u0644\\u0637 \\u0633\\u0679\\u0631\\u0646\\u06AF: "${o.suffix}" \\u067E\\u0631 \\u062E\\u062A\\u0645 \\u06C1\\u0648\\u0646\\u0627 \\u0686\\u0627\\u06C1\\u06CC\\u06D2`:o.format==="includes"?`\\u063A\\u0644\\u0637 \\u0633\\u0679\\u0631\\u0646\\u06AF: "${o.includes}" \\u0634\\u0627\\u0645\\u0644 \\u06C1\\u0648\\u0646\\u0627 \\u0686\\u0627\\u06C1\\u06CC\\u06D2`:o.format==="regex"?`\\u063A\\u0644\\u0637 \\u0633\\u0679\\u0631\\u0646\\u06AF: \\u067E\\u06CC\\u0679\\u0631\\u0646 ${o.pattern} \\u0633\\u06D2 \\u0645\\u06CC\\u0686 \\u06C1\\u0648\\u0646\\u0627 \\u0686\\u0627\\u06C1\\u06CC\\u06D2`:`\\u063A\\u0644\\u0637 ${i[o.format]??t.format}`}case"not_multiple_of":return`\\u063A\\u0644\\u0637 \\u0646\\u0645\\u0628\\u0631: ${t.divisor} \\u06A9\\u0627 \\u0645\\u0636\\u0627\\u0639\\u0641 \\u06C1\\u0648\\u0646\\u0627 \\u0686\\u0627\\u06C1\\u06CC\\u06D2`;case"unrecognized_keys":return`\\u063A\\u06CC\\u0631 \\u062A\\u0633\\u0644\\u06CC\\u0645 \\u0634\\u062F\\u06C1 \\u06A9\\u06CC${t.keys.length>1?"\\u0632":""}: ${h(t.keys,"\\u060C ")}`;case"invalid_key":return`${t.origin} \\u0645\\u06CC\\u06BA \\u063A\\u0644\\u0637 \\u06A9\\u06CC`;case"invalid_union":return"\\u063A\\u0644\\u0637 \\u0627\\u0646 \\u067E\\u0679";case"invalid_element":return`${t.origin} \\u0645\\u06CC\\u06BA \\u063A\\u0644\\u0637 \\u0648\\u06CC\\u0644\\u06CC\\u0648`;default:return"\\u063A\\u0644\\u0637 \\u0627\\u0646 \\u067E\\u0679"}}}});function Yc(){return{localeError:Zf()}}var Zf,Xc=S(()=>{T();Zf=()=>{let e={string:{unit:"k\\xFD t\\u1EF1",verb:"c\\xF3"},file:{unit:"byte",verb:"c\\xF3"},array:{unit:"ph\\u1EA7n t\\u1EED",verb:"c\\xF3"},set:{unit:"ph\\u1EA7n t\\u1EED",verb:"c\\xF3"}};function n(t){return e[t]??null}let r=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"s\\u1ED1";case"object":{if(Array.isArray(t))return"m\\u1EA3ng";if(t===null)return"null";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"\\u0111\\u1EA7u v\\xE0o",email:"\\u0111\\u1ECBa ch\\u1EC9 email",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ng\\xE0y gi\\u1EDD ISO",date:"ng\\xE0y ISO",time:"gi\\u1EDD ISO",duration:"kho\\u1EA3ng th\\u1EDDi gian ISO",ipv4:"\\u0111\\u1ECBa ch\\u1EC9 IPv4",ipv6:"\\u0111\\u1ECBa ch\\u1EC9 IPv6",cidrv4:"d\\u1EA3i IPv4",cidrv6:"d\\u1EA3i IPv6",base64:"chu\\u1ED7i m\\xE3 h\\xF3a base64",base64url:"chu\\u1ED7i m\\xE3 h\\xF3a base64url",json_string:"chu\\u1ED7i JSON",e164:"s\\u1ED1 E.164",jwt:"JWT",template_literal:"\\u0111\\u1EA7u v\\xE0o"};return t=>{switch(t.code){case"invalid_type":return`\\u0110\\u1EA7u v\\xE0o kh\\xF4ng h\\u1EE3p l\\u1EC7: mong \\u0111\\u1EE3i ${t.expected}, nh\\u1EADn \\u0111\\u01B0\\u1EE3c ${r(t.input)}`;case"invalid_value":return t.values.length===1?`\\u0110\\u1EA7u v\\xE0o kh\\xF4ng h\\u1EE3p l\\u1EC7: mong \\u0111\\u1EE3i ${x(t.values[0])}`:`T\\xF9y ch\\u1ECDn kh\\xF4ng h\\u1EE3p l\\u1EC7: mong \\u0111\\u1EE3i m\\u1ED9t trong c\\xE1c gi\\xE1 tr\\u1ECB ${h(t.values,"|")}`;case"too_big":{let o=t.inclusive?"<=":"<",a=n(t.origin);return a?`Qu\\xE1 l\\u1EDBn: mong \\u0111\\u1EE3i ${t.origin??"gi\\xE1 tr\\u1ECB"} ${a.verb} ${o}${t.maximum.toString()} ${a.unit??"ph\\u1EA7n t\\u1EED"}`:`Qu\\xE1 l\\u1EDBn: mong \\u0111\\u1EE3i ${t.origin??"gi\\xE1 tr\\u1ECB"} ${o}${t.maximum.toString()}`}case"too_small":{let o=t.inclusive?">=":">",a=n(t.origin);return a?`Qu\\xE1 nh\\u1ECF: mong \\u0111\\u1EE3i ${t.origin} ${a.verb} ${o}${t.minimum.toString()} ${a.unit}`:`Qu\\xE1 nh\\u1ECF: mong \\u0111\\u1EE3i ${t.origin} ${o}${t.minimum.toString()}`}case"invalid_format":{let o=t;return o.format==="starts_with"?`Chu\\u1ED7i kh\\xF4ng h\\u1EE3p l\\u1EC7: ph\\u1EA3i b\\u1EAFt \\u0111\\u1EA7u b\\u1EB1ng "${o.prefix}"`:o.format==="ends_with"?`Chu\\u1ED7i kh\\xF4ng h\\u1EE3p l\\u1EC7: ph\\u1EA3i k\\u1EBFt th\\xFAc b\\u1EB1ng "${o.suffix}"`:o.format==="includes"?`Chu\\u1ED7i kh\\xF4ng h\\u1EE3p l\\u1EC7: ph\\u1EA3i bao g\\u1ED3m "${o.includes}"`:o.format==="regex"?`Chu\\u1ED7i kh\\xF4ng h\\u1EE3p l\\u1EC7: ph\\u1EA3i kh\\u1EDBp v\\u1EDBi m\\u1EABu ${o.pattern}`:`${i[o.format]??t.format} kh\\xF4ng h\\u1EE3p l\\u1EC7`}case"not_multiple_of":return`S\\u1ED1 kh\\xF4ng h\\u1EE3p l\\u1EC7: ph\\u1EA3i l\\xE0 b\\u1ED9i s\\u1ED1 c\\u1EE7a ${t.divisor}`;case"unrecognized_keys":return`Kh\\xF3a kh\\xF4ng \\u0111\\u01B0\\u1EE3c nh\\u1EADn d\\u1EA1ng: ${h(t.keys,", ")}`;case"invalid_key":return`Kh\\xF3a kh\\xF4ng h\\u1EE3p l\\u1EC7 trong ${t.origin}`;case"invalid_union":return"\\u0110\\u1EA7u v\\xE0o kh\\xF4ng h\\u1EE3p l\\u1EC7";case"invalid_element":return`Gi\\xE1 tr\\u1ECB kh\\xF4ng h\\u1EE3p l\\u1EC7 trong ${t.origin}`;default:return"\\u0110\\u1EA7u v\\xE0o kh\\xF4ng h\\u1EE3p l\\u1EC7"}}}});function ed(){return{localeError:Af()}}var Af,td=S(()=>{T();Af=()=>{let e={string:{unit:"\\u5B57\\u7B26",verb:"\\u5305\\u542B"},file:{unit:"\\u5B57\\u8282",verb:"\\u5305\\u542B"},array:{unit:"\\u9879",verb:"\\u5305\\u542B"},set:{unit:"\\u9879",verb:"\\u5305\\u542B"}};function n(t){return e[t]??null}let r=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"\\u975E\\u6570\\u5B57(NaN)":"\\u6570\\u5B57";case"object":{if(Array.isArray(t))return"\\u6570\\u7EC4";if(t===null)return"\\u7A7A\\u503C(null)";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"\\u8F93\\u5165",email:"\\u7535\\u5B50\\u90AE\\u4EF6",url:"URL",emoji:"\\u8868\\u60C5\\u7B26\\u53F7",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO\\u65E5\\u671F\\u65F6\\u95F4",date:"ISO\\u65E5\\u671F",time:"ISO\\u65F6\\u95F4",duration:"ISO\\u65F6\\u957F",ipv4:"IPv4\\u5730\\u5740",ipv6:"IPv6\\u5730\\u5740",cidrv4:"IPv4\\u7F51\\u6BB5",cidrv6:"IPv6\\u7F51\\u6BB5",base64:"base64\\u7F16\\u7801\\u5B57\\u7B26\\u4E32",base64url:"base64url\\u7F16\\u7801\\u5B57\\u7B26\\u4E32",json_string:"JSON\\u5B57\\u7B26\\u4E32",e164:"E.164\\u53F7\\u7801",jwt:"JWT",template_literal:"\\u8F93\\u5165"};return t=>{switch(t.code){case"invalid_type":return`\\u65E0\\u6548\\u8F93\\u5165\\uFF1A\\u671F\\u671B ${t.expected}\\uFF0C\\u5B9E\\u9645\\u63A5\\u6536 ${r(t.input)}`;case"invalid_value":return t.values.length===1?`\\u65E0\\u6548\\u8F93\\u5165\\uFF1A\\u671F\\u671B ${x(t.values[0])}`:`\\u65E0\\u6548\\u9009\\u9879\\uFF1A\\u671F\\u671B\\u4EE5\\u4E0B\\u4E4B\\u4E00 ${h(t.values,"|")}`;case"too_big":{let o=t.inclusive?"<=":"<",a=n(t.origin);return a?`\\u6570\\u503C\\u8FC7\\u5927\\uFF1A\\u671F\\u671B ${t.origin??"\\u503C"} ${o}${t.maximum.toString()} ${a.unit??"\\u4E2A\\u5143\\u7D20"}`:`\\u6570\\u503C\\u8FC7\\u5927\\uFF1A\\u671F\\u671B ${t.origin??"\\u503C"} ${o}${t.maximum.toString()}`}case"too_small":{let o=t.inclusive?">=":">",a=n(t.origin);return a?`\\u6570\\u503C\\u8FC7\\u5C0F\\uFF1A\\u671F\\u671B ${t.origin} ${o}${t.minimum.toString()} ${a.unit}`:`\\u6570\\u503C\\u8FC7\\u5C0F\\uFF1A\\u671F\\u671B ${t.origin} ${o}${t.minimum.toString()}`}case"invalid_format":{let o=t;return o.format==="starts_with"?`\\u65E0\\u6548\\u5B57\\u7B26\\u4E32\\uFF1A\\u5FC5\\u987B\\u4EE5 "${o.prefix}" \\u5F00\\u5934`:o.format==="ends_with"?`\\u65E0\\u6548\\u5B57\\u7B26\\u4E32\\uFF1A\\u5FC5\\u987B\\u4EE5 "${o.suffix}" \\u7ED3\\u5C3E`:o.format==="includes"?`\\u65E0\\u6548\\u5B57\\u7B26\\u4E32\\uFF1A\\u5FC5\\u987B\\u5305\\u542B "${o.includes}"`:o.format==="regex"?`\\u65E0\\u6548\\u5B57\\u7B26\\u4E32\\uFF1A\\u5FC5\\u987B\\u6EE1\\u8DB3\\u6B63\\u5219\\u8868\\u8FBE\\u5F0F ${o.pattern}`:`\\u65E0\\u6548${i[o.format]??t.format}`}case"not_multiple_of":return`\\u65E0\\u6548\\u6570\\u5B57\\uFF1A\\u5FC5\\u987B\\u662F ${t.divisor} \\u7684\\u500D\\u6570`;case"unrecognized_keys":return`\\u51FA\\u73B0\\u672A\\u77E5\\u7684\\u952E(key): ${h(t.keys,", ")}`;case"invalid_key":return`${t.origin} \\u4E2D\\u7684\\u952E(key)\\u65E0\\u6548`;case"invalid_union":return"\\u65E0\\u6548\\u8F93\\u5165";case"invalid_element":return`${t.origin} \\u4E2D\\u5305\\u542B\\u65E0\\u6548\\u503C(value)`;default:return"\\u65E0\\u6548\\u8F93\\u5165"}}}});function nd(){return{localeError:Mf()}}var Mf,rd=S(()=>{T();Mf=()=>{let e={string:{unit:"\\u5B57\\u5143",verb:"\\u64C1\\u6709"},file:{unit:"\\u4F4D\\u5143\\u7D44",verb:"\\u64C1\\u6709"},array:{unit:"\\u9805\\u76EE",verb:"\\u64C1\\u6709"},set:{unit:"\\u9805\\u76EE",verb:"\\u64C1\\u6709"}};function n(t){return e[t]??null}let r=t=>{let o=typeof t;switch(o){case"number":return Number.isNaN(t)?"NaN":"number";case"object":{if(Array.isArray(t))return"array";if(t===null)return"null";if(Object.getPrototypeOf(t)!==Object.prototype&&t.constructor)return t.constructor.name}}return o},i={regex:"\\u8F38\\u5165",email:"\\u90F5\\u4EF6\\u5730\\u5740",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO \\u65E5\\u671F\\u6642\\u9593",date:"ISO \\u65E5\\u671F",time:"ISO \\u6642\\u9593",duration:"ISO \\u671F\\u9593",ipv4:"IPv4 \\u4F4D\\u5740",ipv6:"IPv6 \\u4F4D\\u5740",cidrv4:"IPv4 \\u7BC4\\u570D",cidrv6:"IPv6 \\u7BC4\\u570D",base64:"base64 \\u7DE8\\u78BC\\u5B57\\u4E32",base64url:"base64url \\u7DE8\\u78BC\\u5B57\\u4E32",json_string:"JSON \\u5B57\\u4E32",e164:"E.164 \\u6578\\u503C",jwt:"JWT",template_literal:"\\u8F38\\u5165"};return t=>{switch(t.code){case"invalid_type":return`\\u7121\\u6548\\u7684\\u8F38\\u5165\\u503C\\uFF1A\\u9810\\u671F\\u70BA ${t.expected}\\uFF0C\\u4F46\\u6536\\u5230 ${r(t.input)}`;case"invalid_value":return t.values.length===1?`\\u7121\\u6548\\u7684\\u8F38\\u5165\\u503C\\uFF1A\\u9810\\u671F\\u70BA ${x(t.values[0])}`:`\\u7121\\u6548\\u7684\\u9078\\u9805\\uFF1A\\u9810\\u671F\\u70BA\\u4EE5\\u4E0B\\u5176\\u4E2D\\u4E4B\\u4E00 ${h(t.values,"|")}`;case"too_big":{let o=t.inclusive?"<=":"<",a=n(t.origin);return a?`\\u6578\\u503C\\u904E\\u5927\\uFF1A\\u9810\\u671F ${t.origin??"\\u503C"} \\u61C9\\u70BA ${o}${t.maximum.toString()} ${a.unit??"\\u500B\\u5143\\u7D20"}`:`\\u6578\\u503C\\u904E\\u5927\\uFF1A\\u9810\\u671F ${t.origin??"\\u503C"} \\u61C9\\u70BA ${o}${t.maximum.toString()}`}case"too_small":{let o=t.inclusive?">=":">",a=n(t.origin);return a?`\\u6578\\u503C\\u904E\\u5C0F\\uFF1A\\u9810\\u671F ${t.origin} \\u61C9\\u70BA ${o}${t.minimum.toString()} ${a.unit}`:`\\u6578\\u503C\\u904E\\u5C0F\\uFF1A\\u9810\\u671F ${t.origin} \\u61C9\\u70BA ${o}${t.minimum.toString()}`}case"invalid_format":{let o=t;return o.format==="starts_with"?`\\u7121\\u6548\\u7684\\u5B57\\u4E32\\uFF1A\\u5FC5\\u9808\\u4EE5 "${o.prefix}" \\u958B\\u982D`:o.format==="ends_with"?`\\u7121\\u6548\\u7684\\u5B57\\u4E32\\uFF1A\\u5FC5\\u9808\\u4EE5 "${o.suffix}" \\u7D50\\u5C3E`:o.format==="includes"?`\\u7121\\u6548\\u7684\\u5B57\\u4E32\\uFF1A\\u5FC5\\u9808\\u5305\\u542B "${o.includes}"`:o.format==="regex"?`\\u7121\\u6548\\u7684\\u5B57\\u4E32\\uFF1A\\u5FC5\\u9808\\u7B26\\u5408\\u683C\\u5F0F ${o.pattern}`:`\\u7121\\u6548\\u7684 ${i[o.format]??t.format}`}case"not_multiple_of":return`\\u7121\\u6548\\u7684\\u6578\\u5B57\\uFF1A\\u5FC5\\u9808\\u70BA ${t.divisor} \\u7684\\u500D\\u6578`;case"unrecognized_keys":return`\\u7121\\u6CD5\\u8B58\\u5225\\u7684\\u9375\\u503C${t.keys.length>1?"\\u5011":""}\\uFF1A${h(t.keys,"\\u3001")}`;case"invalid_key":return`${t.origin} \\u4E2D\\u6709\\u7121\\u6548\\u7684\\u9375\\u503C`;case"invalid_union":return"\\u7121\\u6548\\u7684\\u8F38\\u5165\\u503C";case"invalid_element":return`${t.origin} \\u4E2D\\u6709\\u7121\\u6548\\u7684\\u503C`;default:return"\\u7121\\u6548\\u7684\\u8F38\\u5165\\u503C"}}}});var it={};Pe(it,{ar:()=>Rl,az:()=>Cl,be:()=>Al,ca:()=>Ll,cs:()=>Fl,de:()=>Vl,en:()=>Qn,eo:()=>Wl,es:()=>Bl,fa:()=>Ql,fi:()=>Xl,fr:()=>tc,frCA:()=>rc,he:()=>ic,hu:()=>sc,id:()=>lc,it:()=>dc,ja:()=>mc,kh:()=>gc,ko:()=>vc,mk:()=>yc,ms:()=>_c,nl:()=>kc,no:()=>Sc,ota:()=>Ic,pl:()=>Oc,ps:()=>jc,pt:()=>Ec,ru:()=>Cc,sl:()=>Zc,sv:()=>Mc,ta:()=>qc,th:()=>Hc,tr:()=>Jc,ua:()=>Kc,ur:()=>Gc,vi:()=>Yc,zhCN:()=>ed,zhTW:()=>nd});var Ja=S(()=>{Ul();Dl();Ml();ql();Hl();Jl();Va();Kl();Gl();Yl();ec();nc();oc();ac();uc();cc();pc();fc();hc();bc();xc();$c();zc();wc();Pc();Tc();Nc();Rc();Dc();Ac();Lc();Fc();Vc();Wc();Bc();Qc();Xc();td();rd()});function Yt(){return new at}var Yn,Xn,at,he,Wa=S(()=>{Yn=Symbol("ZodOutput"),Xn=Symbol("ZodInput"),at=class{constructor(){this._map=new Map,this._idmap=new Map}add(n,...r){let i=r[0];if(this._map.set(n,i),i&&typeof i=="object"&&"id"in i){if(this._idmap.has(i.id))throw new Error(`ID ${i.id} already exists in the registry`);this._idmap.set(i.id,n)}return this}clear(){return this._map=new Map,this._idmap=new Map,this}remove(n){let r=this._map.get(n);return r&&typeof r=="object"&&"id"in r&&this._idmap.delete(r.id),this._map.delete(n),this}get(n){let r=n._zod.parent;if(r){let i={...this.get(r)??{}};return delete i.id,{...i,...this._map.get(n)}}return this._map.get(n)}has(n){return this._map.has(n)}};he=Yt()});function Ka(e,n){return new e({type:"string",...b(n)})}function Ba(e,n){return new e({type:"string",coerce:!0,...b(n)})}function er(e,n){return new e({type:"string",format:"email",check:"string_format",abort:!1,...b(n)})}function Xt(e,n){return new e({type:"string",format:"guid",check:"string_format",abort:!1,...b(n)})}function tr(e,n){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,...b(n)})}function nr(e,n){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,version:"v4",...b(n)})}function rr(e,n){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,version:"v6",...b(n)})}function or(e,n){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,version:"v7",...b(n)})}function ir(e,n){return new e({type:"string",format:"url",check:"string_format",abort:!1,...b(n)})}function ar(e,n){return new e({type:"string",format:"emoji",check:"string_format",abort:!1,...b(n)})}function sr(e,n){return new e({type:"string",format:"nanoid",check:"string_format",abort:!1,...b(n)})}function ur(e,n){return new e({type:"string",format:"cuid",check:"string_format",abort:!1,...b(n)})}function lr(e,n){return new e({type:"string",format:"cuid2",check:"string_format",abort:!1,...b(n)})}function cr(e,n){return new e({type:"string",format:"ulid",check:"string_format",abort:!1,...b(n)})}function dr(e,n){return new e({type:"string",format:"xid",check:"string_format",abort:!1,...b(n)})}function pr(e,n){return new e({type:"string",format:"ksuid",check:"string_format",abort:!1,...b(n)})}function mr(e,n){return new e({type:"string",format:"ipv4",check:"string_format",abort:!1,...b(n)})}function fr(e,n){return new e({type:"string",format:"ipv6",check:"string_format",abort:!1,...b(n)})}function gr(e,n){return new e({type:"string",format:"cidrv4",check:"string_format",abort:!1,...b(n)})}function hr(e,n){return new e({type:"string",format:"cidrv6",check:"string_format",abort:!1,...b(n)})}function vr(e,n){return new e({type:"string",format:"base64",check:"string_format",abort:!1,...b(n)})}function br(e,n){return new e({type:"string",format:"base64url",check:"string_format",abort:!1,...b(n)})}function yr(e,n){return new e({type:"string",format:"e164",check:"string_format",abort:!1,...b(n)})}function xr(e,n){return new e({type:"string",format:"jwt",check:"string_format",abort:!1,...b(n)})}function Ga(e,n){return new e({type:"string",format:"datetime",check:"string_format",offset:!1,local:!1,precision:null,...b(n)})}function Qa(e,n){return new e({type:"string",format:"date",check:"string_format",...b(n)})}function Ya(e,n){return new e({type:"string",format:"time",check:"string_format",precision:null,...b(n)})}function Xa(e,n){return new e({type:"string",format:"duration",check:"string_format",...b(n)})}function es(e,n){return new e({type:"number",checks:[],...b(n)})}function ts(e,n){return new e({type:"number",coerce:!0,checks:[],...b(n)})}function ns(e,n){return new e({type:"number",check:"number_format",abort:!1,format:"safeint",...b(n)})}function rs(e,n){return new e({type:"number",check:"number_format",abort:!1,format:"float32",...b(n)})}function os(e,n){return new e({type:"number",check:"number_format",abort:!1,format:"float64",...b(n)})}function is(e,n){return new e({type:"number",check:"number_format",abort:!1,format:"int32",...b(n)})}function as(e,n){return new e({type:"number",check:"number_format",abort:!1,format:"uint32",...b(n)})}function ss(e,n){return new e({type:"boolean",...b(n)})}function us(e,n){return new e({type:"boolean",coerce:!0,...b(n)})}function ls(e,n){return new e({type:"bigint",...b(n)})}function cs(e,n){return new e({type:"bigint",coerce:!0,...b(n)})}function ds(e,n){return new e({type:"bigint",check:"bigint_format",abort:!1,format:"int64",...b(n)})}function ps(e,n){return new e({type:"bigint",check:"bigint_format",abort:!1,format:"uint64",...b(n)})}function ms(e,n){return new e({type:"symbol",...b(n)})}function fs(e,n){return new e({type:"undefined",...b(n)})}function gs(e,n){return new e({type:"null",...b(n)})}function hs(e){return new e({type:"any"})}function st(e){return new e({type:"unknown"})}function vs(e,n){return new e({type:"never",...b(n)})}function bs(e,n){return new e({type:"void",...b(n)})}function ys(e,n){return new e({type:"date",...b(n)})}function xs(e,n){return new e({type:"date",coerce:!0,...b(n)})}function _s(e,n){return new e({type:"nan",...b(n)})}function be(e,n){return new Fn({check:"less_than",...b(n),value:e,inclusive:!1})}function de(e,n){return new Fn({check:"less_than",...b(n),value:e,inclusive:!0})}function ye(e,n){return new Hn({check:"greater_than",...b(n),value:e,inclusive:!1})}function ae(e,n){return new Hn({check:"greater_than",...b(n),value:e,inclusive:!0})}function $r(e){return ye(0,e)}function kr(e){return be(0,e)}function zr(e){return de(0,e)}function Sr(e){return ae(0,e)}function Oe(e,n){return new _i({check:"multiple_of",...b(n),value:e})}function Fe(e,n){return new zi({check:"max_size",...b(n),maximum:e})}function Ne(e,n){return new Si({check:"min_size",...b(n),minimum:e})}function ut(e,n){return new wi({check:"size_equals",...b(n),size:e})}function He(e,n){return new Ii({check:"max_length",...b(n),maximum:e})}function we(e,n){return new Pi({check:"min_length",...b(n),minimum:e})}function Ve(e,n){return new ji({check:"length_equals",...b(n),length:e})}function lt(e,n){return new Ti({check:"string_format",format:"regex",...b(n),pattern:e})}function ct(e){return new Oi({check:"string_format",format:"lowercase",...b(e)})}function dt(e){return new Ni({check:"string_format",format:"uppercase",...b(e)})}function pt(e,n){return new Ei({check:"string_format",format:"includes",...b(n),includes:e})}function mt(e,n){return new Ri({check:"string_format",format:"starts_with",...b(n),prefix:e})}function ft(e,n){return new Ui({check:"string_format",format:"ends_with",...b(n),suffix:e})}function wr(e,n,r){return new Ci({check:"property",property:e,schema:n,...b(r)})}function gt(e,n){return new Di({check:"mime_type",mime:e,...b(n)})}function xe(e){return new Zi({check:"overwrite",tx:e})}function ht(e){return xe(n=>n.normalize(e))}function vt(){return xe(e=>e.trim())}function bt(){return xe(e=>e.toLowerCase())}function yt(){return xe(e=>e.toUpperCase())}function en(e,n,r){return new e({type:"array",element:n,...b(r)})}function Lf(e,n,r){return new e({type:"union",options:n,...b(r)})}function qf(e,n,r,i){return new e({type:"union",options:r,discriminator:n,...b(i)})}function Ff(e,n,r){return new e({type:"intersection",left:n,right:r})}function $s(e,n,r,i){let t=r instanceof O,o=t?i:r,a=t?r:null;return new e({type:"tuple",items:n,rest:a,...b(o)})}function Hf(e,n,r,i){return new e({type:"record",keyType:n,valueType:r,...b(i)})}function Vf(e,n,r,i){return new e({type:"map",keyType:n,valueType:r,...b(i)})}function Jf(e,n,r){return new e({type:"set",valueType:n,...b(r)})}function Wf(e,n,r){let i=Array.isArray(n)?Object.fromEntries(n.map(t=>[t,t])):n;return new e({type:"enum",entries:i,...b(r)})}function Kf(e,n,r){return new e({type:"enum",entries:n,...b(r)})}function Bf(e,n,r){return new e({type:"literal",values:Array.isArray(n)?n:[n],...b(r)})}function ks(e,n){return new e({type:"file",...b(n)})}function Gf(e,n){return new e({type:"transform",transform:n})}function Qf(e,n){return new e({type:"optional",innerType:n})}function Yf(e,n){return new e({type:"nullable",innerType:n})}function Xf(e,n,r){return new e({type:"default",innerType:n,get defaultValue(){return typeof r=="function"?r():r}})}function eg(e,n,r){return new e({type:"nonoptional",innerType:n,...b(r)})}function tg(e,n){return new e({type:"success",innerType:n})}function ng(e,n,r){return new e({type:"catch",innerType:n,catchValue:typeof r=="function"?r:()=>r})}function rg(e,n,r){return new e({type:"pipe",in:n,out:r})}function og(e,n){return new e({type:"readonly",innerType:n})}function ig(e,n,r){return new e({type:"template_literal",parts:n,...b(r)})}function ag(e,n){return new e({type:"lazy",getter:n})}function sg(e,n){return new e({type:"promise",innerType:n})}function zs(e,n,r){let i=b(r);return i.abort??(i.abort=!0),new e({type:"custom",check:"custom",fn:n,...i})}function Ss(e,n,r){return new e({type:"custom",check:"custom",fn:n,...b(r)})}function ws(e,n){let r=b(n),i=r.truthy??["true","1","yes","on","y","enabled"],t=r.falsy??["false","0","no","off","n","disabled"];r.case!=="sensitive"&&(i=i.map(d=>typeof d=="string"?d.toLowerCase():d),t=t.map(d=>typeof d=="string"?d.toLowerCase():d));let o=new Set(i),a=new Set(t),u=e.Pipe??Gt,c=e.Boolean??Wt,g=e.String??Le,f=e.Transform??Bt,m=new f({type:"transform",transform:(d,v)=>{let z=d;return r.case!=="sensitive"&&(z=z.toLowerCase()),o.has(z)?!0:a.has(z)?!1:(v.issues.push({code:"invalid_value",expected:"stringbool",values:[...o,...a],input:v.value,inst:m}),{})},error:r.error}),$=new u({type:"pipe",in:new g({type:"string",error:r.error}),out:m,error:r.error});return new u({type:"pipe",in:$,out:new c({type:"boolean",error:r.error}),error:r.error})}function Is(e,n,r,i={}){let t=b(i),o={...b(i),check:"string_format",type:"string",format:n,fn:typeof r=="function"?r:u=>r.test(u),...t};return r instanceof RegExp&&(o.pattern=r),new e(o)}var _r,Ps=S(()=>{Vn();Qt();T();_r={Any:null,Minute:-1,Second:0,Millisecond:3,Microsecond:6}});function Pr(e){return new Ir({type:"function",input:Array.isArray(e?.input)?$s(qe,e?.input):e?.input??en(Kt,st(ot)),output:e?.output??st(ot)})}var Ir,od=S(()=>{Ps();Mn();Qt();Qt();Ir=class{constructor(n){this._def=n,this.def=n}implement(n){if(typeof n!="function")throw new Error("implement() must be called with a function");let r=((...i)=>{let t=this._def.input?Ft(this._def.input,i,void 0,{callee:r}):i;if(!Array.isArray(t))throw new Error("Invalid arguments schema: not an array or tuple schema.");let o=n(...t);return this._def.output?Ft(this._def.output,o,void 0,{callee:r}):o});return r}implementAsync(n){if(typeof n!="function")throw new Error("implement() must be called with a function");let r=(async(...i)=>{let t=this._def.input?await Ht(this._def.input,i,void 0,{callee:r}):i;if(!Array.isArray(t))throw new Error("Invalid arguments schema: not an array or tuple schema.");let o=await n(...t);return this._def.output?Ht(this._def.output,o,void 0,{callee:r}):o});return r}input(...n){let r=this.constructor;return Array.isArray(n[0])?new r({type:"function",input:new qe({type:"tuple",items:n[0],rest:n[1]}),output:this._def.output}):new r({type:"function",input:n[0],output:this._def.output})}output(n){let r=this.constructor;return new r({type:"function",input:this._def.input,output:n})}}});function jr(e,n){if(e instanceof at){let i=new tn(n),t={};for(let u of e._idmap.entries()){let[c,g]=u;i.process(g)}let o={},a={registry:e,uri:n?.uri,defs:t};for(let u of e._idmap.entries()){let[c,g]=u;o[c]=i.emit(g,{...n,external:a})}if(Object.keys(t).length>0){let u=i.target==="draft-2020-12"?"$defs":"definitions";o.__shared={[u]:t}}return{schemas:o}}let r=new tn(n);return r.process(e),r.emit(e,n)}function Y(e,n){let r=n??{seen:new Set};if(r.seen.has(e))return!1;r.seen.add(e);let t=e._zod.def;switch(t.type){case"string":case"number":case"bigint":case"boolean":case"date":case"symbol":case"undefined":case"null":case"any":case"unknown":case"never":case"void":case"literal":case"enum":case"nan":case"file":case"template_literal":return!1;case"array":return Y(t.element,r);case"object":{for(let o in t.shape)if(Y(t.shape[o],r))return!0;return!1}case"union":{for(let o of t.options)if(Y(o,r))return!0;return!1}case"intersection":return Y(t.left,r)||Y(t.right,r);case"tuple":{for(let o of t.items)if(Y(o,r))return!0;return!!(t.rest&&Y(t.rest,r))}case"record":return Y(t.keyType,r)||Y(t.valueType,r);case"map":return Y(t.keyType,r)||Y(t.valueType,r);case"set":return Y(t.valueType,r);case"promise":case"optional":case"nonoptional":case"nullable":case"readonly":return Y(t.innerType,r);case"lazy":return Y(t.getter(),r);case"default":return Y(t.innerType,r);case"prefault":return Y(t.innerType,r);case"custom":return!1;case"transform":return!0;case"pipe":return Y(t.in,r)||Y(t.out,r);case"success":return!1;case"catch":return!1;default:}throw new Error(`Unknown schema type: ${t.type}`)}var tn,id=S(()=>{Wa();T();tn=class{constructor(n){this.counter=0,this.metadataRegistry=n?.metadata??he,this.target=n?.target??"draft-2020-12",this.unrepresentable=n?.unrepresentable??"throw",this.override=n?.override??(()=>{}),this.io=n?.io??"output",this.seen=new Map}process(n,r={path:[],schemaPath:[]}){var i;let t=n._zod.def,o={guid:"uuid",url:"uri",datetime:"date-time",json_string:"json-string",regex:""},a=this.seen.get(n);if(a)return a.count++,r.schemaPath.includes(n)&&(a.cycle=r.path),a.schema;let u={schema:{},count:1,cycle:void 0,path:r.path};this.seen.set(n,u);let c=n._zod.toJSONSchema?.();if(c)u.schema=c;else{let m={...r,schemaPath:[...r.schemaPath,n],path:r.path},$=n._zod.parent;if($)u.ref=$,this.process($,m),this.seen.get($).isParent=!0;else{let y=u.schema;switch(t.type){case"string":{let d=y;d.type="string";let{minimum:v,maximum:z,format:C,patterns:w,contentEncoding:j}=n._zod.bag;if(typeof v=="number"&&(d.minLength=v),typeof z=="number"&&(d.maxLength=z),C&&(d.format=o[C]??C,d.format===""&&delete d.format),j&&(d.contentEncoding=j),w&&w.size>0){let D=[...w];D.length===1?d.pattern=D[0].source:D.length>1&&(u.schema.allOf=[...D.map(Ce=>({...this.target==="draft-7"?{type:"string"}:{},pattern:Ce.source}))])}break}case"number":{let d=y,{minimum:v,maximum:z,format:C,multipleOf:w,exclusiveMaximum:j,exclusiveMinimum:D}=n._zod.bag;typeof C=="string"&&C.includes("int")?d.type="integer":d.type="number",typeof D=="number"&&(d.exclusiveMinimum=D),typeof v=="number"&&(d.minimum=v,typeof D=="number"&&(D>=v?delete d.minimum:delete d.exclusiveMinimum)),typeof j=="number"&&(d.exclusiveMaximum=j),typeof z=="number"&&(d.maximum=z,typeof j=="number"&&(j<=z?delete d.maximum:delete d.exclusiveMaximum)),typeof w=="number"&&(d.multipleOf=w);break}case"boolean":{let d=y;d.type="boolean";break}case"bigint":{if(this.unrepresentable==="throw")throw new Error("BigInt cannot be represented in JSON Schema");break}case"symbol":{if(this.unrepresentable==="throw")throw new Error("Symbols cannot be represented in JSON Schema");break}case"null":{y.type="null";break}case"any":break;case"unknown":break;case"undefined":{if(this.unrepresentable==="throw")throw new Error("Undefined cannot be represented in JSON Schema");break}case"void":{if(this.unrepresentable==="throw")throw new Error("Void cannot be represented in JSON Schema");break}case"never":{y.not={};break}case"date":{if(this.unrepresentable==="throw")throw new Error("Date cannot be represented in JSON Schema");break}case"array":{let d=y,{minimum:v,maximum:z}=n._zod.bag;typeof v=="number"&&(d.minItems=v),typeof z=="number"&&(d.maxItems=z),d.type="array",d.items=this.process(t.element,{...m,path:[...m.path,"items"]});break}case"object":{let d=y;d.type="object",d.properties={};let v=t.shape;for(let w in v)d.properties[w]=this.process(v[w],{...m,path:[...m.path,"properties",w]});let z=new Set(Object.keys(v)),C=new Set([...z].filter(w=>{let j=t.shape[w]._zod;return this.io==="input"?j.optin===void 0:j.optout===void 0}));C.size>0&&(d.required=Array.from(C)),t.catchall?._zod.def.type==="never"?d.additionalProperties=!1:t.catchall?t.catchall&&(d.additionalProperties=this.process(t.catchall,{...m,path:[...m.path,"additionalProperties"]})):this.io==="output"&&(d.additionalProperties=!1);break}case"union":{let d=y;d.anyOf=t.options.map((v,z)=>this.process(v,{...m,path:[...m.path,"anyOf",z]}));break}case"intersection":{let d=y,v=this.process(t.left,{...m,path:[...m.path,"allOf",0]}),z=this.process(t.right,{...m,path:[...m.path,"allOf",1]}),C=j=>"allOf"in j&&Object.keys(j).length===1,w=[...C(v)?v.allOf:[v],...C(z)?z.allOf:[z]];d.allOf=w;break}case"tuple":{let d=y;d.type="array";let v=t.items.map((w,j)=>this.process(w,{...m,path:[...m.path,"prefixItems",j]}));if(this.target==="draft-2020-12"?d.prefixItems=v:d.items=v,t.rest){let w=this.process(t.rest,{...m,path:[...m.path,"items"]});this.target==="draft-2020-12"?d.items=w:d.additionalItems=w}t.rest&&(d.items=this.process(t.rest,{...m,path:[...m.path,"items"]}));let{minimum:z,maximum:C}=n._zod.bag;typeof z=="number"&&(d.minItems=z),typeof C=="number"&&(d.maxItems=C);break}case"record":{let d=y;d.type="object",d.propertyNames=this.process(t.keyType,{...m,path:[...m.path,"propertyNames"]}),d.additionalProperties=this.process(t.valueType,{...m,path:[...m.path,"additionalProperties"]});break}case"map":{if(this.unrepresentable==="throw")throw new Error("Map cannot be represented in JSON Schema");break}case"set":{if(this.unrepresentable==="throw")throw new Error("Set cannot be represented in JSON Schema");break}case"enum":{let d=y,v=Ct(t.entries);v.every(z=>typeof z=="number")&&(d.type="number"),v.every(z=>typeof z=="string")&&(d.type="string"),d.enum=v;break}case"literal":{let d=y,v=[];for(let z of t.values)if(z===void 0){if(this.unrepresentable==="throw")throw new Error("Literal `undefined` cannot be represented in JSON Schema")}else if(typeof z=="bigint"){if(this.unrepresentable==="throw")throw new Error("BigInt literals cannot be represented in JSON Schema");v.push(Number(z))}else v.push(z);if(v.length!==0)if(v.length===1){let z=v[0];d.type=z===null?"null":typeof z,d.const=z}else v.every(z=>typeof z=="number")&&(d.type="number"),v.every(z=>typeof z=="string")&&(d.type="string"),v.every(z=>typeof z=="boolean")&&(d.type="string"),v.every(z=>z===null)&&(d.type="null"),d.enum=v;break}case"file":{let d=y,v={type:"string",format:"binary",contentEncoding:"binary"},{minimum:z,maximum:C,mime:w}=n._zod.bag;z!==void 0&&(v.minLength=z),C!==void 0&&(v.maxLength=C),w?w.length===1?(v.contentMediaType=w[0],Object.assign(d,v)):d.anyOf=w.map(j=>({...v,contentMediaType:j})):Object.assign(d,v);break}case"transform":{if(this.unrepresentable==="throw")throw new Error("Transforms cannot be represented in JSON Schema");break}case"nullable":{let d=this.process(t.innerType,m);y.anyOf=[d,{type:"null"}];break}case"nonoptional":{this.process(t.innerType,m),u.ref=t.innerType;break}case"success":{let d=y;d.type="boolean";break}case"default":{this.process(t.innerType,m),u.ref=t.innerType,y.default=JSON.parse(JSON.stringify(t.defaultValue));break}case"prefault":{this.process(t.innerType,m),u.ref=t.innerType,this.io==="input"&&(y._prefault=JSON.parse(JSON.stringify(t.defaultValue)));break}case"catch":{this.process(t.innerType,m),u.ref=t.innerType;let d;try{d=t.catchValue(void 0)}catch{throw new Error("Dynamic catch values are not supported in JSON Schema")}y.default=d;break}case"nan":{if(this.unrepresentable==="throw")throw new Error("NaN cannot be represented in JSON Schema");break}case"template_literal":{let d=y,v=n._zod.pattern;if(!v)throw new Error("Pattern not found in template literal");d.type="string",d.pattern=v.source;break}case"pipe":{let d=this.io==="input"?t.in._zod.def.type==="transform"?t.out:t.in:t.out;this.process(d,m),u.ref=d;break}case"readonly":{this.process(t.innerType,m),u.ref=t.innerType,y.readOnly=!0;break}case"promise":{this.process(t.innerType,m),u.ref=t.innerType;break}case"optional":{this.process(t.innerType,m),u.ref=t.innerType;break}case"lazy":{let d=n._zod.innerType;this.process(d,m),u.ref=d;break}case"custom":{if(this.unrepresentable==="throw")throw new Error("Custom types cannot be represented in JSON Schema");break}default:}}}let g=this.metadataRegistry.get(n);return g&&Object.assign(u.schema,g),this.io==="input"&&Y(n)&&(delete u.schema.examples,delete u.schema.default),this.io==="input"&&u.schema._prefault&&((i=u.schema).default??(i.default=u.schema._prefault)),delete u.schema._prefault,this.seen.get(n).schema}emit(n,r){let i={cycles:r?.cycles??"ref",reused:r?.reused??"inline",external:r?.external??void 0},t=this.seen.get(n);if(!t)throw new Error("Unprocessed schema. This is a bug in Zod.");let o=f=>{let m=this.target==="draft-2020-12"?"$defs":"definitions";if(i.external){let v=i.external.registry.get(f[0])?.id,z=i.external.uri??(w=>w);if(v)return{ref:z(v)};let C=f[1].defId??f[1].schema.id??`schema${this.counter++}`;return f[1].defId=C,{defId:C,ref:`${z("__shared")}#/${m}/${C}`}}if(f[1]===t)return{ref:"#"};let y=`#/${m}/`,d=f[1].schema.id??`__schema${this.counter++}`;return{defId:d,ref:y+d}},a=f=>{if(f[1].schema.$ref)return;let m=f[1],{ref:$,defId:y}=o(f);m.def={...m.schema},y&&(m.defId=y);let d=m.schema;for(let v in d)delete d[v];d.$ref=$};if(i.cycles==="throw")for(let f of this.seen.entries()){let m=f[1];if(m.cycle)throw new Error(`Cycle detected: #/${m.cycle?.join("/")}/<root>\n\nSet the \\`cycles\\` parameter to \\`"ref"\\` to resolve cyclical schemas with defs.`)}for(let f of this.seen.entries()){let m=f[1];if(n===f[0]){a(f);continue}if(i.external){let y=i.external.registry.get(f[0])?.id;if(n!==f[0]&&y){a(f);continue}}if(this.metadataRegistry.get(f[0])?.id){a(f);continue}if(m.cycle){a(f);continue}if(m.count>1&&i.reused==="ref"){a(f);continue}}let u=(f,m)=>{let $=this.seen.get(f),y=$.def??$.schema,d={...y};if($.ref===null)return;let v=$.ref;if($.ref=null,v){u(v,m);let z=this.seen.get(v).schema;z.$ref&&m.target==="draft-7"?(y.allOf=y.allOf??[],y.allOf.push(z)):(Object.assign(y,z),Object.assign(y,d))}$.isParent||this.override({zodSchema:f,jsonSchema:y,path:$.path??[]})};for(let f of[...this.seen.entries()].reverse())u(f[0],{target:this.target});let c={};if(this.target==="draft-2020-12"?c.$schema="https://json-schema.org/draft/2020-12/schema":this.target==="draft-7"?c.$schema="http://json-schema.org/draft-07/schema#":console.warn(`Invalid target: ${this.target}`),i.external?.uri){let f=i.external.registry.get(n)?.id;if(!f)throw new Error("Schema is missing an `id` property");c.$id=i.external.uri(f)}Object.assign(c,t.def);let g=i.external?.defs??{};for(let f of this.seen.entries()){let m=f[1];m.def&&m.defId&&(g[m.defId]=m.def)}i.external||Object.keys(g).length>0&&(this.target==="draft-2020-12"?c.$defs=g:c.definitions=g);try{return JSON.parse(JSON.stringify(c))}catch{throw new Error("Error converting schema to JSON.")}}}});var ad={};var sd=S(()=>{});var _e={};Pe(_e,{$ZodAny:()=>ya,$ZodArray:()=>Kt,$ZodAsyncError:()=>ve,$ZodBase64:()=>la,$ZodBase64URL:()=>ca,$ZodBigInt:()=>Bn,$ZodBigIntFormat:()=>ga,$ZodBoolean:()=>Wt,$ZodCIDRv4:()=>aa,$ZodCIDRv6:()=>sa,$ZodCUID:()=>Bi,$ZodCUID2:()=>Gi,$ZodCatch:()=>Za,$ZodCheck:()=>B,$ZodCheckBigIntFormat:()=>ki,$ZodCheckEndsWith:()=>Ui,$ZodCheckGreaterThan:()=>Hn,$ZodCheckIncludes:()=>Ei,$ZodCheckLengthEquals:()=>ji,$ZodCheckLessThan:()=>Fn,$ZodCheckLowerCase:()=>Oi,$ZodCheckMaxLength:()=>Ii,$ZodCheckMaxSize:()=>zi,$ZodCheckMimeType:()=>Di,$ZodCheckMinLength:()=>Pi,$ZodCheckMinSize:()=>Si,$ZodCheckMultipleOf:()=>_i,$ZodCheckNumberFormat:()=>$i,$ZodCheckOverwrite:()=>Zi,$ZodCheckProperty:()=>Ci,$ZodCheckRegex:()=>Ti,$ZodCheckSizeEquals:()=>wi,$ZodCheckStartsWith:()=>Ri,$ZodCheckStringFormat:()=>rt,$ZodCheckUpperCase:()=>Ni,$ZodCustom:()=>Ha,$ZodCustomStringFormat:()=>ma,$ZodDate:()=>$a,$ZodDefault:()=>Ra,$ZodDiscriminatedUnion:()=>za,$ZodE164:()=>da,$ZodEmail:()=>Vi,$ZodEmoji:()=>Wi,$ZodEnum:()=>ja,$ZodError:()=>qt,$ZodFile:()=>Oa,$ZodFunction:()=>Ir,$ZodGUID:()=>Fi,$ZodIPv4:()=>oa,$ZodIPv6:()=>ia,$ZodISODate:()=>ta,$ZodISODateTime:()=>ea,$ZodISODuration:()=>ra,$ZodISOTime:()=>na,$ZodIntersection:()=>Sa,$ZodJWT:()=>pa,$ZodKSUID:()=>Xi,$ZodLazy:()=>Fa,$ZodLiteral:()=>Ta,$ZodMap:()=>Ia,$ZodNaN:()=>Aa,$ZodNanoID:()=>Ki,$ZodNever:()=>xa,$ZodNonOptional:()=>Ca,$ZodNull:()=>ba,$ZodNullable:()=>Ea,$ZodNumber:()=>Kn,$ZodNumberFormat:()=>fa,$ZodObject:()=>ka,$ZodOptional:()=>Na,$ZodPipe:()=>Gt,$ZodPrefault:()=>Ua,$ZodPromise:()=>qa,$ZodReadonly:()=>Ma,$ZodRealError:()=>Xe,$ZodRecord:()=>wa,$ZodRegistry:()=>at,$ZodSet:()=>Pa,$ZodString:()=>Le,$ZodStringFormat:()=>H,$ZodSuccess:()=>Da,$ZodSymbol:()=>ha,$ZodTemplateLiteral:()=>La,$ZodTransform:()=>Bt,$ZodTuple:()=>qe,$ZodType:()=>O,$ZodULID:()=>Qi,$ZodURL:()=>Ji,$ZodUUID:()=>Hi,$ZodUndefined:()=>va,$ZodUnion:()=>Gn,$ZodUnknown:()=>ot,$ZodVoid:()=>_a,$ZodXID:()=>Yi,$brand:()=>Nn,$constructor:()=>l,$input:()=>Xn,$output:()=>Yn,Doc:()=>Jt,JSONSchema:()=>ad,JSONSchemaGenerator:()=>tn,NEVER:()=>On,TimePrecision:()=>_r,_any:()=>hs,_array:()=>en,_base64:()=>vr,_base64url:()=>br,_bigint:()=>ls,_boolean:()=>ss,_catch:()=>ng,_cidrv4:()=>gr,_cidrv6:()=>hr,_coercedBigint:()=>cs,_coercedBoolean:()=>us,_coercedDate:()=>xs,_coercedNumber:()=>ts,_coercedString:()=>Ba,_cuid:()=>ur,_cuid2:()=>lr,_custom:()=>zs,_date:()=>ys,_default:()=>Xf,_discriminatedUnion:()=>qf,_e164:()=>yr,_email:()=>er,_emoji:()=>ar,_endsWith:()=>ft,_enum:()=>Wf,_file:()=>ks,_float32:()=>rs,_float64:()=>os,_gt:()=>ye,_gte:()=>ae,_guid:()=>Xt,_includes:()=>pt,_int:()=>ns,_int32:()=>is,_int64:()=>ds,_intersection:()=>Ff,_ipv4:()=>mr,_ipv6:()=>fr,_isoDate:()=>Qa,_isoDateTime:()=>Ga,_isoDuration:()=>Xa,_isoTime:()=>Ya,_jwt:()=>xr,_ksuid:()=>pr,_lazy:()=>ag,_length:()=>Ve,_literal:()=>Bf,_lowercase:()=>ct,_lt:()=>be,_lte:()=>de,_map:()=>Vf,_max:()=>de,_maxLength:()=>He,_maxSize:()=>Fe,_mime:()=>gt,_min:()=>ae,_minLength:()=>we,_minSize:()=>Ne,_multipleOf:()=>Oe,_nan:()=>_s,_nanoid:()=>sr,_nativeEnum:()=>Kf,_negative:()=>kr,_never:()=>vs,_nonnegative:()=>Sr,_nonoptional:()=>eg,_nonpositive:()=>zr,_normalize:()=>ht,_null:()=>gs,_nullable:()=>Yf,_number:()=>es,_optional:()=>Qf,_overwrite:()=>xe,_parse:()=>Cn,_parseAsync:()=>Dn,_pipe:()=>rg,_positive:()=>$r,_promise:()=>sg,_property:()=>wr,_readonly:()=>og,_record:()=>Hf,_refine:()=>Ss,_regex:()=>lt,_safeParse:()=>Zn,_safeParseAsync:()=>An,_set:()=>Jf,_size:()=>ut,_startsWith:()=>mt,_string:()=>Ka,_stringFormat:()=>Is,_stringbool:()=>ws,_success:()=>tg,_symbol:()=>ms,_templateLiteral:()=>ig,_toLowerCase:()=>bt,_toUpperCase:()=>yt,_transform:()=>Gf,_trim:()=>vt,_tuple:()=>$s,_uint32:()=>as,_uint64:()=>ps,_ulid:()=>cr,_undefined:()=>fs,_union:()=>Lf,_unknown:()=>st,_uppercase:()=>dt,_url:()=>ir,_uuid:()=>tr,_uuidv4:()=>nr,_uuidv6:()=>rr,_uuidv7:()=>or,_void:()=>bs,_xid:()=>dr,clone:()=>se,config:()=>G,flattenError:()=>et,formatError:()=>tt,function:()=>Pr,globalConfig:()=>Rt,globalRegistry:()=>he,isValidBase64:()=>ua,isValidBase64URL:()=>Ol,isValidJWT:()=>Nl,locales:()=>it,parse:()=>Ft,parseAsync:()=>Ht,prettifyError:()=>Un,regexes:()=>Te,registry:()=>Yt,safeParse:()=>nt,safeParseAsync:()=>Vt,toDotPath:()=>ml,toJSONSchema:()=>jr,treeifyError:()=>Rn,util:()=>_,version:()=>Mi});var le=S(()=>{Ge();Mn();Vo();Qt();Vn();Li();T();qn();Ja();Wa();Ai();od();Ps();id();sd()});var js=S(()=>{le()});var Je={};Pe(Je,{ZodISODate:()=>rn,ZodISODateTime:()=>nn,ZodISODuration:()=>an,ZodISOTime:()=>on,date:()=>Os,datetime:()=>Ts,duration:()=>Es,time:()=>Ns});function Ts(e){return Ga(nn,e)}function Os(e){return Qa(rn,e)}function Ns(e){return Ya(on,e)}function Es(e){return Xa(an,e)}var nn,rn,on,an,Nr=S(()=>{le();Er();nn=l("ZodISODateTime",(e,n)=>{ea.init(e,n),V.init(e,n)});rn=l("ZodISODate",(e,n)=>{ta.init(e,n),V.init(e,n)});on=l("ZodISOTime",(e,n)=>{na.init(e,n),V.init(e,n)});an=l("ZodISODuration",(e,n)=>{ra.init(e,n),V.init(e,n)})});var dd,pd,We,Rs=S(()=>{le();le();dd=(e,n)=>{qt.init(e,n),e.name="ZodError",Object.defineProperties(e,{format:{value:r=>tt(e,r)},flatten:{value:r=>et(e,r)},addIssue:{value:r=>e.issues.push(r)},addIssues:{value:r=>e.issues.push(...r)},isEmpty:{get(){return e.issues.length===0}}})},pd=l("ZodError",dd),We=l("ZodError",dd,{Parent:Error})});var Rr,Ur,Cr,Dr,Us=S(()=>{le();Rs();Rr=Cn(We),Ur=Dn(We),Cr=Zn(We),Dr=An(We)});function p(e){return Ka(_t,e)}function md(e){return er(Mr,e)}function fd(e){return Xt(sn,e)}function gd(e){return tr($e,e)}function hd(e){return nr($e,e)}function vd(e){return rr($e,e)}function bd(e){return or($e,e)}function yd(e){return ir(Lr,e)}function xd(e){return ar(qr,e)}function _d(e){return sr(Fr,e)}function $d(e){return ur(Hr,e)}function kd(e){return lr(Vr,e)}function zd(e){return cr(Jr,e)}function Sd(e){return dr(Wr,e)}function wd(e){return pr(Kr,e)}function Id(e){return mr(Br,e)}function Pd(e){return fr(Gr,e)}function jd(e){return gr(Qr,e)}function Td(e){return hr(Yr,e)}function Od(e){return vr(Xr,e)}function Nd(e){return br(eo,e)}function Ed(e){return yr(to,e)}function Rd(e){return xr(no,e)}function Ud(e,n,r={}){return Is(Cs,e,n,r)}function Z(e){return es($t,e)}function Zr(e){return ns(Ke,e)}function Cd(e){return rs(Ke,e)}function Dd(e){return os(Ke,e)}function Zd(e){return is(Ke,e)}function Ad(e){return as(Ke,e)}function Q(e){return ss(kt,e)}function Md(e){return ls(zt,e)}function Ld(e){return ds(ro,e)}function qd(e){return ps(ro,e)}function Fd(e){return ms(Ds,e)}function Hd(e){return fs(Zs,e)}function cn(e){return gs(As,e)}function Vd(){return hs(Ms)}function W(){return st(Ls)}function dn(e){return vs(qs,e)}function Jd(e){return bs(Fs,e)}function Wd(e){return ys(pn,e)}function R(e,n){return en(Hs,e,n)}function Kd(e){let n=e._zod.def.shape;return I(Object.keys(n))}function k(e,n){let r={type:"object",get shape(){return _.assignProp(this,"shape",{...e}),this.shape},..._.normalizeParams(n)};return new mn(r)}function Bd(e,n){return new mn({type:"object",get shape(){return _.assignProp(this,"shape",{...e}),this.shape},catchall:dn(),..._.normalizeParams(n)})}function ee(e,n){return new mn({type:"object",get shape(){return _.assignProp(this,"shape",{...e}),this.shape},catchall:W(),..._.normalizeParams(n)})}function q(e,n){return new oo({type:"union",options:e,..._.normalizeParams(n)})}function fn(e,n,r){return new Vs({type:"union",options:n,discriminator:e,..._.normalizeParams(r)})}function St(e,n){return new Js({type:"intersection",left:e,right:n})}function Gd(e,n,r){let i=n instanceof O,t=i?r:n,o=i?n:null;return new Ws({type:"tuple",items:e,rest:o,..._.normalizeParams(t)})}function F(e,n,r){return new io({type:"record",keyType:e,valueType:n,..._.normalizeParams(r)})}function Qd(e,n,r){return new io({type:"record",keyType:q([e,dn()]),valueType:n,..._.normalizeParams(r)})}function Yd(e,n,r){return new Ks({type:"map",keyType:e,valueType:n,..._.normalizeParams(r)})}function Xd(e,n){return new Bs({type:"set",valueType:e,..._.normalizeParams(n)})}function ie(e,n){let r=Array.isArray(e)?Object.fromEntries(e.map(i=>[i,i])):e;return new xt({type:"enum",entries:r,..._.normalizeParams(n)})}function ep(e,n){return new xt({type:"enum",entries:e,..._.normalizeParams(n)})}function I(e,n){return new Gs({type:"literal",values:Array.isArray(e)?e:[e],..._.normalizeParams(n)})}function tp(e){return ks(Qs,e)}function so(e){return new ao({type:"transform",transform:e})}function J(e){return new uo({type:"optional",innerType:e})}function un(e){return new Ys({type:"nullable",innerType:e})}function np(e){return J(un(e))}function eu(e,n){return new Xs({type:"default",innerType:e,get defaultValue(){return typeof n=="function"?n():n}})}function nu(e,n){return new tu({type:"prefault",innerType:e,get defaultValue(){return typeof n=="function"?n():n}})}function ru(e,n){return new lo({type:"nonoptional",innerType:e,..._.normalizeParams(n)})}function rp(e){return new ou({type:"success",innerType:e})}function au(e,n){return new iu({type:"catch",innerType:e,catchValue:typeof n=="function"?n:()=>n})}function op(e){return _s(su,e)}function ln(e,n){return new co({type:"pipe",in:e,out:n})}function lu(e){return new uu({type:"readonly",innerType:e})}function ip(e,n){return new cu({type:"template_literal",parts:e,..._.normalizeParams(n)})}function pu(e){return new du({type:"lazy",getter:e})}function ap(e){return new mu({type:"promise",innerType:e})}function fu(e){let n=new B({check:"custom"});return n._zod.check=e,n}function po(e,n){return zs(gn,e??(()=>!0),n)}function gu(e,n={}){return Ss(gn,e,n)}function hu(e){let n=fu(r=>(r.addIssue=i=>{if(typeof i=="string")r.issues.push(_.issue(i,r.value,n._zod.def));else{let t=i;t.fatal&&(t.continue=!1),t.code??(t.code="custom"),t.input??(t.input=r.value),t.inst??(t.inst=n),t.continue??(t.continue=!n._zod.def.abort),r.issues.push(_.issue(t))}},e(r.value,r)));return n}function sp(e,n={error:`Input not instance of ${e.name}`}){let r=new gn({type:"custom",check:"custom",fn:i=>i instanceof e,abort:!0,..._.normalizeParams(n)});return r._zod.bag.Class=e,r}function lp(e){let n=pu(()=>q([p(e),Z(),Q(),cn(),R(n),F(p(),n)]));return n}function hn(e,n){return ln(so(e),n)}var E,Ar,_t,V,Mr,sn,$e,Lr,qr,Fr,Hr,Vr,Jr,Wr,Kr,Br,Gr,Qr,Yr,Xr,eo,to,no,Cs,$t,Ke,kt,zt,ro,Ds,Zs,As,Ms,Ls,qs,Fs,pn,Hs,mn,oo,Vs,Js,Ws,io,Ks,Bs,xt,Gs,Qs,ao,uo,Ys,Xs,tu,lo,ou,iu,su,co,uu,cu,du,mu,gn,up,Er=S(()=>{le();le();js();Nr();Us();E=l("ZodType",(e,n)=>(O.init(e,n),e.def=n,Object.defineProperty(e,"_def",{value:n}),e.check=(...r)=>e.clone({...n,checks:[...n.checks??[],...r.map(i=>typeof i=="function"?{_zod:{check:i,def:{check:"custom"},onattach:[]}}:i)]}),e.clone=(r,i)=>se(e,r,i),e.brand=()=>e,e.register=((r,i)=>(r.add(e,i),e)),e.parse=(r,i)=>Rr(e,r,i,{callee:e.parse}),e.safeParse=(r,i)=>Cr(e,r,i),e.parseAsync=async(r,i)=>Ur(e,r,i,{callee:e.parseAsync}),e.safeParseAsync=async(r,i)=>Dr(e,r,i),e.spa=e.safeParseAsync,e.refine=(r,i)=>e.check(gu(r,i)),e.superRefine=r=>e.check(hu(r)),e.overwrite=r=>e.check(xe(r)),e.optional=()=>J(e),e.nullable=()=>un(e),e.nullish=()=>J(un(e)),e.nonoptional=r=>ru(e,r),e.array=()=>R(e),e.or=r=>q([e,r]),e.and=r=>St(e,r),e.transform=r=>ln(e,so(r)),e.default=r=>eu(e,r),e.prefault=r=>nu(e,r),e.catch=r=>au(e,r),e.pipe=r=>ln(e,r),e.readonly=()=>lu(e),e.describe=r=>{let i=e.clone();return he.add(i,{description:r}),i},Object.defineProperty(e,"description",{get(){return he.get(e)?.description},configurable:!0}),e.meta=(...r)=>{if(r.length===0)return he.get(e);let i=e.clone();return he.add(i,r[0]),i},e.isOptional=()=>e.safeParse(void 0).success,e.isNullable=()=>e.safeParse(null).success,e)),Ar=l("_ZodString",(e,n)=>{Le.init(e,n),E.init(e,n);let r=e._zod.bag;e.format=r.format??null,e.minLength=r.minimum??null,e.maxLength=r.maximum??null,e.regex=(...i)=>e.check(lt(...i)),e.includes=(...i)=>e.check(pt(...i)),e.startsWith=(...i)=>e.check(mt(...i)),e.endsWith=(...i)=>e.check(ft(...i)),e.min=(...i)=>e.check(we(...i)),e.max=(...i)=>e.check(He(...i)),e.length=(...i)=>e.check(Ve(...i)),e.nonempty=(...i)=>e.check(we(1,...i)),e.lowercase=i=>e.check(ct(i)),e.uppercase=i=>e.check(dt(i)),e.trim=()=>e.check(vt()),e.normalize=(...i)=>e.check(ht(...i)),e.toLowerCase=()=>e.check(bt()),e.toUpperCase=()=>e.check(yt())}),_t=l("ZodString",(e,n)=>{Le.init(e,n),Ar.init(e,n),e.email=r=>e.check(er(Mr,r)),e.url=r=>e.check(ir(Lr,r)),e.jwt=r=>e.check(xr(no,r)),e.emoji=r=>e.check(ar(qr,r)),e.guid=r=>e.check(Xt(sn,r)),e.uuid=r=>e.check(tr($e,r)),e.uuidv4=r=>e.check(nr($e,r)),e.uuidv6=r=>e.check(rr($e,r)),e.uuidv7=r=>e.check(or($e,r)),e.nanoid=r=>e.check(sr(Fr,r)),e.guid=r=>e.check(Xt(sn,r)),e.cuid=r=>e.check(ur(Hr,r)),e.cuid2=r=>e.check(lr(Vr,r)),e.ulid=r=>e.check(cr(Jr,r)),e.base64=r=>e.check(vr(Xr,r)),e.base64url=r=>e.check(br(eo,r)),e.xid=r=>e.check(dr(Wr,r)),e.ksuid=r=>e.check(pr(Kr,r)),e.ipv4=r=>e.check(mr(Br,r)),e.ipv6=r=>e.check(fr(Gr,r)),e.cidrv4=r=>e.check(gr(Qr,r)),e.cidrv6=r=>e.check(hr(Yr,r)),e.e164=r=>e.check(yr(to,r)),e.datetime=r=>e.check(Ts(r)),e.date=r=>e.check(Os(r)),e.time=r=>e.check(Ns(r)),e.duration=r=>e.check(Es(r))});V=l("ZodStringFormat",(e,n)=>{H.init(e,n),Ar.init(e,n)}),Mr=l("ZodEmail",(e,n)=>{Vi.init(e,n),V.init(e,n)});sn=l("ZodGUID",(e,n)=>{Fi.init(e,n),V.init(e,n)});$e=l("ZodUUID",(e,n)=>{Hi.init(e,n),V.init(e,n)});Lr=l("ZodURL",(e,n)=>{Ji.init(e,n),V.init(e,n)});qr=l("ZodEmoji",(e,n)=>{Wi.init(e,n),V.init(e,n)});Fr=l("ZodNanoID",(e,n)=>{Ki.init(e,n),V.init(e,n)});Hr=l("ZodCUID",(e,n)=>{Bi.init(e,n),V.init(e,n)});Vr=l("ZodCUID2",(e,n)=>{Gi.init(e,n),V.init(e,n)});Jr=l("ZodULID",(e,n)=>{Qi.init(e,n),V.init(e,n)});Wr=l("ZodXID",(e,n)=>{Yi.init(e,n),V.init(e,n)});Kr=l("ZodKSUID",(e,n)=>{Xi.init(e,n),V.init(e,n)});Br=l("ZodIPv4",(e,n)=>{oa.init(e,n),V.init(e,n)});Gr=l("ZodIPv6",(e,n)=>{ia.init(e,n),V.init(e,n)});Qr=l("ZodCIDRv4",(e,n)=>{aa.init(e,n),V.init(e,n)});Yr=l("ZodCIDRv6",(e,n)=>{sa.init(e,n),V.init(e,n)});Xr=l("ZodBase64",(e,n)=>{la.init(e,n),V.init(e,n)});eo=l("ZodBase64URL",(e,n)=>{ca.init(e,n),V.init(e,n)});to=l("ZodE164",(e,n)=>{da.init(e,n),V.init(e,n)});no=l("ZodJWT",(e,n)=>{pa.init(e,n),V.init(e,n)});Cs=l("ZodCustomStringFormat",(e,n)=>{ma.init(e,n),V.init(e,n)});$t=l("ZodNumber",(e,n)=>{Kn.init(e,n),E.init(e,n),e.gt=(i,t)=>e.check(ye(i,t)),e.gte=(i,t)=>e.check(ae(i,t)),e.min=(i,t)=>e.check(ae(i,t)),e.lt=(i,t)=>e.check(be(i,t)),e.lte=(i,t)=>e.check(de(i,t)),e.max=(i,t)=>e.check(de(i,t)),e.int=i=>e.check(Zr(i)),e.safe=i=>e.check(Zr(i)),e.positive=i=>e.check(ye(0,i)),e.nonnegative=i=>e.check(ae(0,i)),e.negative=i=>e.check(be(0,i)),e.nonpositive=i=>e.check(de(0,i)),e.multipleOf=(i,t)=>e.check(Oe(i,t)),e.step=(i,t)=>e.check(Oe(i,t)),e.finite=()=>e;let r=e._zod.bag;e.minValue=Math.max(r.minimum??Number.NEGATIVE_INFINITY,r.exclusiveMinimum??Number.NEGATIVE_INFINITY)??null,e.maxValue=Math.min(r.maximum??Number.POSITIVE_INFINITY,r.exclusiveMaximum??Number.POSITIVE_INFINITY)??null,e.isInt=(r.format??"").includes("int")||Number.isSafeInteger(r.multipleOf??.5),e.isFinite=!0,e.format=r.format??null});Ke=l("ZodNumberFormat",(e,n)=>{fa.init(e,n),$t.init(e,n)});kt=l("ZodBoolean",(e,n)=>{Wt.init(e,n),E.init(e,n)});zt=l("ZodBigInt",(e,n)=>{Bn.init(e,n),E.init(e,n),e.gte=(i,t)=>e.check(ae(i,t)),e.min=(i,t)=>e.check(ae(i,t)),e.gt=(i,t)=>e.check(ye(i,t)),e.gte=(i,t)=>e.check(ae(i,t)),e.min=(i,t)=>e.check(ae(i,t)),e.lt=(i,t)=>e.check(be(i,t)),e.lte=(i,t)=>e.check(de(i,t)),e.max=(i,t)=>e.check(de(i,t)),e.positive=i=>e.check(ye(BigInt(0),i)),e.negative=i=>e.check(be(BigInt(0),i)),e.nonpositive=i=>e.check(de(BigInt(0),i)),e.nonnegative=i=>e.check(ae(BigInt(0),i)),e.multipleOf=(i,t)=>e.check(Oe(i,t));let r=e._zod.bag;e.minValue=r.minimum??null,e.maxValue=r.maximum??null,e.format=r.format??null});ro=l("ZodBigIntFormat",(e,n)=>{ga.init(e,n),zt.init(e,n)});Ds=l("ZodSymbol",(e,n)=>{ha.init(e,n),E.init(e,n)});Zs=l("ZodUndefined",(e,n)=>{va.init(e,n),E.init(e,n)});As=l("ZodNull",(e,n)=>{ba.init(e,n),E.init(e,n)});Ms=l("ZodAny",(e,n)=>{ya.init(e,n),E.init(e,n)});Ls=l("ZodUnknown",(e,n)=>{ot.init(e,n),E.init(e,n)});qs=l("ZodNever",(e,n)=>{xa.init(e,n),E.init(e,n)});Fs=l("ZodVoid",(e,n)=>{_a.init(e,n),E.init(e,n)});pn=l("ZodDate",(e,n)=>{$a.init(e,n),E.init(e,n),e.min=(i,t)=>e.check(ae(i,t)),e.max=(i,t)=>e.check(de(i,t));let r=e._zod.bag;e.minDate=r.minimum?new Date(r.minimum):null,e.maxDate=r.maximum?new Date(r.maximum):null});Hs=l("ZodArray",(e,n)=>{Kt.init(e,n),E.init(e,n),e.element=n.element,e.min=(r,i)=>e.check(we(r,i)),e.nonempty=r=>e.check(we(1,r)),e.max=(r,i)=>e.check(He(r,i)),e.length=(r,i)=>e.check(Ve(r,i)),e.unwrap=()=>e.element});mn=l("ZodObject",(e,n)=>{ka.init(e,n),E.init(e,n),_.defineLazy(e,"shape",()=>n.shape),e.keyof=()=>ie(Object.keys(e._zod.def.shape)),e.catchall=r=>e.clone({...e._zod.def,catchall:r}),e.passthrough=()=>e.clone({...e._zod.def,catchall:W()}),e.loose=()=>e.clone({...e._zod.def,catchall:W()}),e.strict=()=>e.clone({...e._zod.def,catchall:dn()}),e.strip=()=>e.clone({...e._zod.def,catchall:void 0}),e.extend=r=>_.extend(e,r),e.merge=r=>_.merge(e,r),e.pick=r=>_.pick(e,r),e.omit=r=>_.omit(e,r),e.partial=(...r)=>_.partial(uo,e,r[0]),e.required=(...r)=>_.required(lo,e,r[0])});oo=l("ZodUnion",(e,n)=>{Gn.init(e,n),E.init(e,n),e.options=n.options});Vs=l("ZodDiscriminatedUnion",(e,n)=>{oo.init(e,n),za.init(e,n)});Js=l("ZodIntersection",(e,n)=>{Sa.init(e,n),E.init(e,n)});Ws=l("ZodTuple",(e,n)=>{qe.init(e,n),E.init(e,n),e.rest=r=>e.clone({...e._zod.def,rest:r})});io=l("ZodRecord",(e,n)=>{wa.init(e,n),E.init(e,n),e.keyType=n.keyType,e.valueType=n.valueType});Ks=l("ZodMap",(e,n)=>{Ia.init(e,n),E.init(e,n),e.keyType=n.keyType,e.valueType=n.valueType});Bs=l("ZodSet",(e,n)=>{Pa.init(e,n),E.init(e,n),e.min=(...r)=>e.check(Ne(...r)),e.nonempty=r=>e.check(Ne(1,r)),e.max=(...r)=>e.check(Fe(...r)),e.size=(...r)=>e.check(ut(...r))});xt=l("ZodEnum",(e,n)=>{ja.init(e,n),E.init(e,n),e.enum=n.entries,e.options=Object.values(n.entries);let r=new Set(Object.keys(n.entries));e.extract=(i,t)=>{let o={};for(let a of i)if(r.has(a))o[a]=n.entries[a];else throw new Error(`Key ${a} not found in enum`);return new xt({...n,checks:[],..._.normalizeParams(t),entries:o})},e.exclude=(i,t)=>{let o={...n.entries};for(let a of i)if(r.has(a))delete o[a];else throw new Error(`Key ${a} not found in enum`);return new xt({...n,checks:[],..._.normalizeParams(t),entries:o})}});Gs=l("ZodLiteral",(e,n)=>{Ta.init(e,n),E.init(e,n),e.values=new Set(n.values),Object.defineProperty(e,"value",{get(){if(n.values.length>1)throw new Error("This schema contains multiple valid literal values. Use `.values` instead.");return n.values[0]}})});Qs=l("ZodFile",(e,n)=>{Oa.init(e,n),E.init(e,n),e.min=(r,i)=>e.check(Ne(r,i)),e.max=(r,i)=>e.check(Fe(r,i)),e.mime=(r,i)=>e.check(gt(Array.isArray(r)?r:[r],i))});ao=l("ZodTransform",(e,n)=>{Bt.init(e,n),E.init(e,n),e._zod.parse=(r,i)=>{r.addIssue=o=>{if(typeof o=="string")r.issues.push(_.issue(o,r.value,n));else{let a=o;a.fatal&&(a.continue=!1),a.code??(a.code="custom"),a.input??(a.input=r.value),a.inst??(a.inst=e),a.continue??(a.continue=!0),r.issues.push(_.issue(a))}};let t=n.transform(r.value,r);return t instanceof Promise?t.then(o=>(r.value=o,r)):(r.value=t,r)}});uo=l("ZodOptional",(e,n)=>{Na.init(e,n),E.init(e,n),e.unwrap=()=>e._zod.def.innerType});Ys=l("ZodNullable",(e,n)=>{Ea.init(e,n),E.init(e,n),e.unwrap=()=>e._zod.def.innerType});Xs=l("ZodDefault",(e,n)=>{Ra.init(e,n),E.init(e,n),e.unwrap=()=>e._zod.def.innerType,e.removeDefault=e.unwrap});tu=l("ZodPrefault",(e,n)=>{Ua.init(e,n),E.init(e,n),e.unwrap=()=>e._zod.def.innerType});lo=l("ZodNonOptional",(e,n)=>{Ca.init(e,n),E.init(e,n),e.unwrap=()=>e._zod.def.innerType});ou=l("ZodSuccess",(e,n)=>{Da.init(e,n),E.init(e,n),e.unwrap=()=>e._zod.def.innerType});iu=l("ZodCatch",(e,n)=>{Za.init(e,n),E.init(e,n),e.unwrap=()=>e._zod.def.innerType,e.removeCatch=e.unwrap});su=l("ZodNaN",(e,n)=>{Aa.init(e,n),E.init(e,n)});co=l("ZodPipe",(e,n)=>{Gt.init(e,n),E.init(e,n),e.in=n.in,e.out=n.out});uu=l("ZodReadonly",(e,n)=>{Ma.init(e,n),E.init(e,n)});cu=l("ZodTemplateLiteral",(e,n)=>{La.init(e,n),E.init(e,n)});du=l("ZodLazy",(e,n)=>{Fa.init(e,n),E.init(e,n),e.unwrap=()=>e._zod.def.getter()});mu=l("ZodPromise",(e,n)=>{qa.init(e,n),E.init(e,n),e.unwrap=()=>e._zod.def.innerType});gn=l("ZodCustom",(e,n)=>{Ha.init(e,n),E.init(e,n)});up=(...e)=>ws({Pipe:co,Boolean:kt,String:_t,Transform:ao},...e)});function dp(e){G({customError:e})}function pp(){return G().customError}var cp,mp=S(()=>{le();cp={invalid_type:"invalid_type",too_big:"too_big",too_small:"too_small",invalid_format:"invalid_format",not_multiple_of:"not_multiple_of",unrecognized_keys:"unrecognized_keys",invalid_union:"invalid_union",invalid_key:"invalid_key",invalid_element:"invalid_element",invalid_value:"invalid_value",custom:"custom"}});var mo={};Pe(mo,{bigint:()=>mg,boolean:()=>pg,date:()=>fg,number:()=>dg,string:()=>cg});function cg(e){return Ba(_t,e)}function dg(e){return ts($t,e)}function pg(e){return us(kt,e)}function mg(e){return cs(zt,e)}function fg(e){return xs(pn,e)}var fp=S(()=>{le();Er()});var s={};Pe(s,{$brand:()=>Nn,$input:()=>Xn,$output:()=>Yn,NEVER:()=>On,TimePrecision:()=>_r,ZodAny:()=>Ms,ZodArray:()=>Hs,ZodBase64:()=>Xr,ZodBase64URL:()=>eo,ZodBigInt:()=>zt,ZodBigIntFormat:()=>ro,ZodBoolean:()=>kt,ZodCIDRv4:()=>Qr,ZodCIDRv6:()=>Yr,ZodCUID:()=>Hr,ZodCUID2:()=>Vr,ZodCatch:()=>iu,ZodCustom:()=>gn,ZodCustomStringFormat:()=>Cs,ZodDate:()=>pn,ZodDefault:()=>Xs,ZodDiscriminatedUnion:()=>Vs,ZodE164:()=>to,ZodEmail:()=>Mr,ZodEmoji:()=>qr,ZodEnum:()=>xt,ZodError:()=>pd,ZodFile:()=>Qs,ZodGUID:()=>sn,ZodIPv4:()=>Br,ZodIPv6:()=>Gr,ZodISODate:()=>rn,ZodISODateTime:()=>nn,ZodISODuration:()=>an,ZodISOTime:()=>on,ZodIntersection:()=>Js,ZodIssueCode:()=>cp,ZodJWT:()=>no,ZodKSUID:()=>Kr,ZodLazy:()=>du,ZodLiteral:()=>Gs,ZodMap:()=>Ks,ZodNaN:()=>su,ZodNanoID:()=>Fr,ZodNever:()=>qs,ZodNonOptional:()=>lo,ZodNull:()=>As,ZodNullable:()=>Ys,ZodNumber:()=>$t,ZodNumberFormat:()=>Ke,ZodObject:()=>mn,ZodOptional:()=>uo,ZodPipe:()=>co,ZodPrefault:()=>tu,ZodPromise:()=>mu,ZodReadonly:()=>uu,ZodRealError:()=>We,ZodRecord:()=>io,ZodSet:()=>Bs,ZodString:()=>_t,ZodStringFormat:()=>V,ZodSuccess:()=>ou,ZodSymbol:()=>Ds,ZodTemplateLiteral:()=>cu,ZodTransform:()=>ao,ZodTuple:()=>Ws,ZodType:()=>E,ZodULID:()=>Jr,ZodURL:()=>Lr,ZodUUID:()=>$e,ZodUndefined:()=>Zs,ZodUnion:()=>oo,ZodUnknown:()=>Ls,ZodVoid:()=>Fs,ZodXID:()=>Wr,_ZodString:()=>Ar,_default:()=>eu,any:()=>Vd,array:()=>R,base64:()=>Od,base64url:()=>Nd,bigint:()=>Md,boolean:()=>Q,catch:()=>au,check:()=>fu,cidrv4:()=>jd,cidrv6:()=>Td,clone:()=>se,coerce:()=>mo,config:()=>G,core:()=>_e,cuid:()=>$d,cuid2:()=>kd,custom:()=>po,date:()=>Wd,discriminatedUnion:()=>fn,e164:()=>Ed,email:()=>md,emoji:()=>xd,endsWith:()=>ft,enum:()=>ie,file:()=>tp,flattenError:()=>et,float32:()=>Cd,float64:()=>Dd,formatError:()=>tt,function:()=>Pr,getErrorMap:()=>pp,globalRegistry:()=>he,gt:()=>ye,gte:()=>ae,guid:()=>fd,includes:()=>pt,instanceof:()=>sp,int:()=>Zr,int32:()=>Zd,int64:()=>Ld,intersection:()=>St,ipv4:()=>Id,ipv6:()=>Pd,iso:()=>Je,json:()=>lp,jwt:()=>Rd,keyof:()=>Kd,ksuid:()=>wd,lazy:()=>pu,length:()=>Ve,literal:()=>I,locales:()=>it,looseObject:()=>ee,lowercase:()=>ct,lt:()=>be,lte:()=>de,map:()=>Yd,maxLength:()=>He,maxSize:()=>Fe,mime:()=>gt,minLength:()=>we,minSize:()=>Ne,multipleOf:()=>Oe,nan:()=>op,nanoid:()=>_d,nativeEnum:()=>ep,negative:()=>kr,never:()=>dn,nonnegative:()=>Sr,nonoptional:()=>ru,nonpositive:()=>zr,normalize:()=>ht,null:()=>cn,nullable:()=>un,nullish:()=>np,number:()=>Z,object:()=>k,optional:()=>J,overwrite:()=>xe,parse:()=>Rr,parseAsync:()=>Ur,partialRecord:()=>Qd,pipe:()=>ln,positive:()=>$r,prefault:()=>nu,preprocess:()=>hn,prettifyError:()=>Un,promise:()=>ap,property:()=>wr,readonly:()=>lu,record:()=>F,refine:()=>gu,regex:()=>lt,regexes:()=>Te,registry:()=>Yt,safeParse:()=>Cr,safeParseAsync:()=>Dr,set:()=>Xd,setErrorMap:()=>dp,size:()=>ut,startsWith:()=>mt,strictObject:()=>Bd,string:()=>p,stringFormat:()=>Ud,stringbool:()=>up,success:()=>rp,superRefine:()=>hu,symbol:()=>Fd,templateLiteral:()=>ip,toJSONSchema:()=>jr,toLowerCase:()=>bt,toUpperCase:()=>yt,transform:()=>so,treeifyError:()=>Rn,trim:()=>vt,tuple:()=>Gd,uint32:()=>Ad,uint64:()=>qd,ulid:()=>zd,undefined:()=>Hd,union:()=>q,unknown:()=>W,uppercase:()=>dt,url:()=>yd,uuid:()=>gd,uuidv4:()=>hd,uuidv6:()=>vd,uuidv7:()=>bd,void:()=>Jd,xid:()=>Sd});var vu=S(()=>{le();Er();js();Rs();Us();mp();le();Va();le();Ja();Nr();Nr();fp();G(Qn())});var gp,bu=S(()=>{vu();vu();gp=s});var yu={};Pe(yu,{$brand:()=>Nn,$input:()=>Xn,$output:()=>Yn,NEVER:()=>On,TimePrecision:()=>_r,ZodAny:()=>Ms,ZodArray:()=>Hs,ZodBase64:()=>Xr,ZodBase64URL:()=>eo,ZodBigInt:()=>zt,ZodBigIntFormat:()=>ro,ZodBoolean:()=>kt,ZodCIDRv4:()=>Qr,ZodCIDRv6:()=>Yr,ZodCUID:()=>Hr,ZodCUID2:()=>Vr,ZodCatch:()=>iu,ZodCustom:()=>gn,ZodCustomStringFormat:()=>Cs,ZodDate:()=>pn,ZodDefault:()=>Xs,ZodDiscriminatedUnion:()=>Vs,ZodE164:()=>to,ZodEmail:()=>Mr,ZodEmoji:()=>qr,ZodEnum:()=>xt,ZodError:()=>pd,ZodFile:()=>Qs,ZodGUID:()=>sn,ZodIPv4:()=>Br,ZodIPv6:()=>Gr,ZodISODate:()=>rn,ZodISODateTime:()=>nn,ZodISODuration:()=>an,ZodISOTime:()=>on,ZodIntersection:()=>Js,ZodIssueCode:()=>cp,ZodJWT:()=>no,ZodKSUID:()=>Kr,ZodLazy:()=>du,ZodLiteral:()=>Gs,ZodMap:()=>Ks,ZodNaN:()=>su,ZodNanoID:()=>Fr,ZodNever:()=>qs,ZodNonOptional:()=>lo,ZodNull:()=>As,ZodNullable:()=>Ys,ZodNumber:()=>$t,ZodNumberFormat:()=>Ke,ZodObject:()=>mn,ZodOptional:()=>uo,ZodPipe:()=>co,ZodPrefault:()=>tu,ZodPromise:()=>mu,ZodReadonly:()=>uu,ZodRealError:()=>We,ZodRecord:()=>io,ZodSet:()=>Bs,ZodString:()=>_t,ZodStringFormat:()=>V,ZodSuccess:()=>ou,ZodSymbol:()=>Ds,ZodTemplateLiteral:()=>cu,ZodTransform:()=>ao,ZodTuple:()=>Ws,ZodType:()=>E,ZodULID:()=>Jr,ZodURL:()=>Lr,ZodUUID:()=>$e,ZodUndefined:()=>Zs,ZodUnion:()=>oo,ZodUnknown:()=>Ls,ZodVoid:()=>Fs,ZodXID:()=>Wr,_ZodString:()=>Ar,_default:()=>eu,any:()=>Vd,array:()=>R,base64:()=>Od,base64url:()=>Nd,bigint:()=>Md,boolean:()=>Q,catch:()=>au,check:()=>fu,cidrv4:()=>jd,cidrv6:()=>Td,clone:()=>se,coerce:()=>mo,config:()=>G,core:()=>_e,cuid:()=>$d,cuid2:()=>kd,custom:()=>po,date:()=>Wd,default:()=>gg,discriminatedUnion:()=>fn,e164:()=>Ed,email:()=>md,emoji:()=>xd,endsWith:()=>ft,enum:()=>ie,file:()=>tp,flattenError:()=>et,float32:()=>Cd,float64:()=>Dd,formatError:()=>tt,function:()=>Pr,getErrorMap:()=>pp,globalRegistry:()=>he,gt:()=>ye,gte:()=>ae,guid:()=>fd,includes:()=>pt,instanceof:()=>sp,int:()=>Zr,int32:()=>Zd,int64:()=>Ld,intersection:()=>St,ipv4:()=>Id,ipv6:()=>Pd,iso:()=>Je,json:()=>lp,jwt:()=>Rd,keyof:()=>Kd,ksuid:()=>wd,lazy:()=>pu,length:()=>Ve,literal:()=>I,locales:()=>it,looseObject:()=>ee,lowercase:()=>ct,lt:()=>be,lte:()=>de,map:()=>Yd,maxLength:()=>He,maxSize:()=>Fe,mime:()=>gt,minLength:()=>we,minSize:()=>Ne,multipleOf:()=>Oe,nan:()=>op,nanoid:()=>_d,nativeEnum:()=>ep,negative:()=>kr,never:()=>dn,nonnegative:()=>Sr,nonoptional:()=>ru,nonpositive:()=>zr,normalize:()=>ht,null:()=>cn,nullable:()=>un,nullish:()=>np,number:()=>Z,object:()=>k,optional:()=>J,overwrite:()=>xe,parse:()=>Rr,parseAsync:()=>Ur,partialRecord:()=>Qd,pipe:()=>ln,positive:()=>$r,prefault:()=>nu,preprocess:()=>hn,prettifyError:()=>Un,promise:()=>ap,property:()=>wr,readonly:()=>lu,record:()=>F,refine:()=>gu,regex:()=>lt,regexes:()=>Te,registry:()=>Yt,safeParse:()=>Cr,safeParseAsync:()=>Dr,set:()=>Xd,setErrorMap:()=>dp,size:()=>ut,startsWith:()=>mt,strictObject:()=>Bd,string:()=>p,stringFormat:()=>Ud,stringbool:()=>up,success:()=>rp,superRefine:()=>hu,symbol:()=>Fd,templateLiteral:()=>ip,toJSONSchema:()=>jr,toLowerCase:()=>bt,toUpperCase:()=>yt,transform:()=>so,treeifyError:()=>Rn,trim:()=>vt,tuple:()=>Gd,uint32:()=>Ad,uint64:()=>qd,ulid:()=>zd,undefined:()=>Hd,union:()=>q,unknown:()=>W,uppercase:()=>dt,url:()=>yd,uuid:()=>gd,uuidv4:()=>hd,uuidv6:()=>vd,uuidv7:()=>bd,void:()=>Jd,xid:()=>Sd,z:()=>s});var gg,vn=S(()=>{bu();bu();gg=gp});le();function Tr(e){return!!e._zod}function Or(e,n){return Tr(e)?nt(e,n):e.safeParse(n)}function ud(e){if(!e)return;let n;if(Tr(e)?n=e._zod?.def?.shape:n=e.shape,!!n){if(typeof n=="function")try{return n()}catch{return}return n}}function ld(e){if(Tr(e)){let o=e._zod?.def;if(o){if(o.value!==void 0)return o.value;if(Array.isArray(o.values)&&o.values.length>0)return o.values[0]}}let r=e._def;if(r){if(r.value!==void 0)return r.value;if(Array.isArray(r.values)&&r.values.length>0)return r.values[0]}let i=e.value;if(i!==void 0)return i}vn();var Ee="io.modelcontextprotocol/related-task",go="2.0",X=po(e=>e!==null&&(typeof e=="object"||typeof e=="function")),hp=q([p(),Z().int()]),vp=p(),Ex=ee({ttl:Z().optional(),pollInterval:Z().optional()}),hg=k({ttl:Z().optional()}),vg=k({taskId:p()}),_u=ee({progressToken:hp.optional(),[Ee]:vg.optional()}),pe=k({_meta:_u.optional()}),bn=pe.extend({task:hg.optional()}),bp=e=>bn.safeParse(e).success,te=k({method:p(),params:pe.loose().optional()}),me=k({_meta:_u.optional()}),fe=k({method:p(),params:me.loose().optional()}),ne=ee({_meta:_u.optional()}),It=q([p(),Z().int()]),yp=k({jsonrpc:I(go),id:It,...te.shape}).strict(),$u=e=>yp.safeParse(e).success,xp=k({jsonrpc:I(go),...fe.shape}).strict(),_p=e=>xp.safeParse(e).success,ku=k({jsonrpc:I(go),id:It,result:ne}).strict(),yn=e=>ku.safeParse(e).success;var A;(function(e){e[e.ConnectionClosed=-32e3]="ConnectionClosed",e[e.RequestTimeout=-32001]="RequestTimeout",e[e.ParseError=-32700]="ParseError",e[e.InvalidRequest=-32600]="InvalidRequest",e[e.MethodNotFound=-32601]="MethodNotFound",e[e.InvalidParams=-32602]="InvalidParams",e[e.InternalError=-32603]="InternalError",e[e.UrlElicitationRequired=-32042]="UrlElicitationRequired"})(A||(A={}));var zu=k({jsonrpc:I(go),id:It.optional(),error:k({code:Z().int(),message:p(),data:W().optional()})}).strict();var $p=e=>zu.safeParse(e).success;var kp=q([yp,xp,ku,zu]),Rx=q([ku,zu]),ho=ne.strict(),bg=me.extend({requestId:It.optional(),reason:p().optional()}),vo=fe.extend({method:I("notifications/cancelled"),params:bg}),yg=k({src:p(),mimeType:p().optional(),sizes:R(p()).optional(),theme:ie(["light","dark"]).optional()}),xn=k({icons:R(yg).optional()}),wt=k({name:p(),title:p().optional()}),_n=wt.extend({...wt.shape,...xn.shape,version:p(),websiteUrl:p().optional(),description:p().optional()}),xg=St(k({applyDefaults:Q().optional()}),F(p(),W())),_g=hn(e=>e&&typeof e=="object"&&!Array.isArray(e)&&Object.keys(e).length===0?{form:{}}:e,St(k({form:xg.optional(),url:X.optional()}),F(p(),W()).optional())),$g=ee({list:X.optional(),cancel:X.optional(),requests:ee({sampling:ee({createMessage:X.optional()}).optional(),elicitation:ee({create:X.optional()}).optional()}).optional()}),kg=ee({list:X.optional(),cancel:X.optional(),requests:ee({tools:ee({call:X.optional()}).optional()}).optional()}),zg=k({experimental:F(p(),X).optional(),sampling:k({context:X.optional(),tools:X.optional()}).optional(),elicitation:_g.optional(),roots:k({listChanged:Q().optional()}).optional(),tasks:$g.optional(),extensions:F(p(),X).optional()}),Sg=pe.extend({protocolVersion:p(),capabilities:zg,clientInfo:_n}),wg=te.extend({method:I("initialize"),params:Sg});var Ig=k({experimental:F(p(),X).optional(),logging:X.optional(),completions:X.optional(),prompts:k({listChanged:Q().optional()}).optional(),resources:k({subscribe:Q().optional(),listChanged:Q().optional()}).optional(),tools:k({listChanged:Q().optional()}).optional(),tasks:kg.optional(),extensions:F(p(),X).optional()}),Pg=ne.extend({protocolVersion:p(),capabilities:Ig,serverInfo:_n,instructions:p().optional()}),jg=fe.extend({method:I("notifications/initialized"),params:me.optional()});var Pt=te.extend({method:I("ping"),params:pe.optional()}),Tg=k({progress:Z(),total:J(Z()),message:J(p())}),Og=k({...me.shape,...Tg.shape,progressToken:hp}),bo=fe.extend({method:I("notifications/progress"),params:Og}),Ng=pe.extend({cursor:vp.optional()}),$n=te.extend({params:Ng.optional()}),kn=ne.extend({nextCursor:vp.optional()}),Eg=ie(["working","input_required","completed","failed","cancelled"]),zn=k({taskId:p(),status:Eg,ttl:q([Z(),cn()]),createdAt:p(),lastUpdatedAt:p(),pollInterval:J(Z()),statusMessage:J(p())}),yo=ne.extend({task:zn}),Rg=me.merge(zn),Sn=fe.extend({method:I("notifications/tasks/status"),params:Rg}),xo=te.extend({method:I("tasks/get"),params:pe.extend({taskId:p()})}),_o=ne.merge(zn),$o=te.extend({method:I("tasks/result"),params:pe.extend({taskId:p()})}),Ux=ne.loose(),ko=$n.extend({method:I("tasks/list")}),zo=kn.extend({tasks:R(zn)}),So=te.extend({method:I("tasks/cancel"),params:pe.extend({taskId:p()})}),zp=ne.merge(zn),Sp=k({uri:p(),mimeType:J(p()),_meta:F(p(),W()).optional()}),wp=Sp.extend({text:p()}),Su=p().refine(e=>{try{return atob(e),!0}catch{return!1}},{message:"Invalid Base64 string"}),Ip=Sp.extend({blob:Su}),wn=ie(["user","assistant"]),jt=k({audience:R(wn).optional(),priority:Z().min(0).max(1).optional(),lastModified:Je.datetime({offset:!0}).optional()}),Pp=k({...wt.shape,...xn.shape,uri:p(),description:J(p()),mimeType:J(p()),size:J(Z()),annotations:jt.optional(),_meta:J(ee({}))}),Ug=k({...wt.shape,...xn.shape,uriTemplate:p(),description:J(p()),mimeType:J(p()),annotations:jt.optional(),_meta:J(ee({}))}),Cg=$n.extend({method:I("resources/list")}),wu=kn.extend({resources:R(Pp)}),Dg=$n.extend({method:I("resources/templates/list")}),Zg=kn.extend({resourceTemplates:R(Ug)}),Iu=pe.extend({uri:p()}),Ag=Iu,Mg=te.extend({method:I("resources/read"),params:Ag}),Pu=ne.extend({contents:R(q([wp,Ip]))}),Lg=fe.extend({method:I("notifications/resources/list_changed"),params:me.optional()}),qg=Iu,Fg=te.extend({method:I("resources/subscribe"),params:qg}),Hg=Iu,Vg=te.extend({method:I("resources/unsubscribe"),params:Hg}),Jg=me.extend({uri:p()}),Wg=fe.extend({method:I("notifications/resources/updated"),params:Jg}),Kg=k({name:p(),description:J(p()),required:J(Q())}),Bg=k({...wt.shape,...xn.shape,description:J(p()),arguments:J(R(Kg)),_meta:J(ee({}))}),Gg=$n.extend({method:I("prompts/list")}),Qg=kn.extend({prompts:R(Bg)}),Yg=pe.extend({name:p(),arguments:F(p(),p()).optional()}),Xg=te.extend({method:I("prompts/get"),params:Yg}),ju=k({type:I("text"),text:p(),annotations:jt.optional(),_meta:F(p(),W()).optional()}),Tu=k({type:I("image"),data:Su,mimeType:p(),annotations:jt.optional(),_meta:F(p(),W()).optional()}),Ou=k({type:I("audio"),data:Su,mimeType:p(),annotations:jt.optional(),_meta:F(p(),W()).optional()}),eh=k({type:I("tool_use"),name:p(),id:p(),input:F(p(),W()),_meta:F(p(),W()).optional()}),Nu=k({type:I("resource"),resource:q([wp,Ip]),annotations:jt.optional(),_meta:F(p(),W()).optional()}),Eu=Pp.extend({type:I("resource_link")}),Tt=q([ju,Tu,Ou,Eu,Nu]),th=k({role:wn,content:Tt}),nh=ne.extend({description:p().optional(),messages:R(th)}),rh=fe.extend({method:I("notifications/prompts/list_changed"),params:me.optional()}),oh=k({title:p().optional(),readOnlyHint:Q().optional(),destructiveHint:Q().optional(),idempotentHint:Q().optional(),openWorldHint:Q().optional()}),ih=k({taskSupport:ie(["required","optional","forbidden"]).optional()}),wo=k({...wt.shape,...xn.shape,description:p().optional(),inputSchema:k({type:I("object"),properties:F(p(),X).optional(),required:R(p()).optional()}).catchall(W()),outputSchema:k({type:I("object"),properties:F(p(),X).optional(),required:R(p()).optional()}).catchall(W()).optional(),annotations:oh.optional(),execution:ih.optional(),_meta:F(p(),W()).optional()}),Ru=$n.extend({method:I("tools/list")}),ah=kn.extend({tools:R(wo)}),Ot=ne.extend({content:R(Tt).default([]),structuredContent:F(p(),W()).optional(),isError:Q().optional()}),Cx=Ot.or(ne.extend({toolResult:W()})),sh=bn.extend({name:p(),arguments:F(p(),W()).optional()}),Uu=te.extend({method:I("tools/call"),params:sh}),uh=fe.extend({method:I("notifications/tools/list_changed"),params:me.optional()}),Dx=k({autoRefresh:Q().default(!0),debounceMs:Z().int().nonnegative().default(300)}),jp=ie(["debug","info","notice","warning","error","critical","alert","emergency"]),lh=pe.extend({level:jp}),ch=te.extend({method:I("logging/setLevel"),params:lh}),dh=me.extend({level:jp,logger:p().optional(),data:W()}),ph=fe.extend({method:I("notifications/message"),params:dh}),mh=k({name:p().optional()}),fh=k({hints:R(mh).optional(),costPriority:Z().min(0).max(1).optional(),speedPriority:Z().min(0).max(1).optional(),intelligencePriority:Z().min(0).max(1).optional()}),gh=k({mode:ie(["auto","required","none"]).optional()}),hh=k({type:I("tool_result"),toolUseId:p().describe("The unique identifier for the corresponding tool call."),content:R(Tt).default([]),structuredContent:k({}).loose().optional(),isError:Q().optional(),_meta:F(p(),W()).optional()}),vh=fn("type",[ju,Tu,Ou]),fo=fn("type",[ju,Tu,Ou,eh,hh]),bh=k({role:wn,content:q([fo,R(fo)]),_meta:F(p(),W()).optional()}),yh=bn.extend({messages:R(bh),modelPreferences:fh.optional(),systemPrompt:p().optional(),includeContext:ie(["none","thisServer","allServers"]).optional(),temperature:Z().optional(),maxTokens:Z().int(),stopSequences:R(p()).optional(),metadata:X.optional(),tools:R(wo).optional(),toolChoice:gh.optional()}),xh=te.extend({method:I("sampling/createMessage"),params:yh}),Cu=ne.extend({model:p(),stopReason:J(ie(["endTurn","stopSequence","maxTokens"]).or(p())),role:wn,content:vh}),Du=ne.extend({model:p(),stopReason:J(ie(["endTurn","stopSequence","maxTokens","toolUse"]).or(p())),role:wn,content:q([fo,R(fo)])}),_h=k({type:I("boolean"),title:p().optional(),description:p().optional(),default:Q().optional()}),$h=k({type:I("string"),title:p().optional(),description:p().optional(),minLength:Z().optional(),maxLength:Z().optional(),format:ie(["email","uri","date","date-time"]).optional(),default:p().optional()}),kh=k({type:ie(["number","integer"]),title:p().optional(),description:p().optional(),minimum:Z().optional(),maximum:Z().optional(),default:Z().optional()}),zh=k({type:I("string"),title:p().optional(),description:p().optional(),enum:R(p()),default:p().optional()}),Sh=k({type:I("string"),title:p().optional(),description:p().optional(),oneOf:R(k({const:p(),title:p()})),default:p().optional()}),wh=k({type:I("string"),title:p().optional(),description:p().optional(),enum:R(p()),enumNames:R(p()).optional(),default:p().optional()}),Ih=q([zh,Sh]),Ph=k({type:I("array"),title:p().optional(),description:p().optional(),minItems:Z().optional(),maxItems:Z().optional(),items:k({type:I("string"),enum:R(p())}),default:R(p()).optional()}),jh=k({type:I("array"),title:p().optional(),description:p().optional(),minItems:Z().optional(),maxItems:Z().optional(),items:k({anyOf:R(k({const:p(),title:p()}))}),default:R(p()).optional()}),Th=q([Ph,jh]),Oh=q([wh,Ih,Th]),Nh=q([Oh,_h,$h,kh]),Eh=bn.extend({mode:I("form").optional(),message:p(),requestedSchema:k({type:I("object"),properties:F(p(),Nh),required:R(p()).optional()})}),Rh=bn.extend({mode:I("url"),message:p(),elicitationId:p(),url:p().url()}),Uh=q([Eh,Rh]),Ch=te.extend({method:I("elicitation/create"),params:Uh}),Dh=me.extend({elicitationId:p()}),Zh=fe.extend({method:I("notifications/elicitation/complete"),params:Dh}),Ah=ne.extend({action:ie(["accept","decline","cancel"]),content:hn(e=>e===null?void 0:e,F(p(),q([p(),Z(),Q(),R(p())])).optional())}),Mh=k({type:I("ref/resource"),uri:p()});var Lh=k({type:I("ref/prompt"),name:p()}),qh=pe.extend({ref:q([Lh,Mh]),argument:k({name:p(),value:p()}),context:k({arguments:F(p(),p()).optional()}).optional()}),Fh=te.extend({method:I("completion/complete"),params:qh});var Hh=ne.extend({completion:ee({values:R(p()).max(100),total:J(Z().int()),hasMore:J(Q())})}),Vh=k({uri:p().startsWith("file://"),name:p().optional(),_meta:F(p(),W()).optional()}),Jh=te.extend({method:I("roots/list"),params:pe.optional()}),Wh=ne.extend({roots:R(Vh)}),Kh=fe.extend({method:I("notifications/roots/list_changed"),params:me.optional()}),Zx=q([Pt,wg,Fh,ch,Xg,Gg,Cg,Dg,Mg,Fg,Vg,Uu,Ru,xo,$o,ko,So]),Ax=q([vo,bo,jg,Kh,Sn]),Mx=q([ho,Cu,Du,Ah,Wh,_o,zo,yo]),Lx=q([Pt,xh,Ch,Jh,xo,$o,ko,So]),qx=q([vo,bo,ph,Wg,Lg,uh,rh,Sn,Zh]),Fx=q([ho,Pg,Hh,nh,Qg,wu,Zg,Pu,Ot,ah,_o,zo,yo]),U=class e extends Error{constructor(n,r,i){super(`MCP error ${n}: ${r}`),this.code=n,this.data=i,this.name="McpError"}static fromError(n,r,i){if(n===A.UrlElicitationRequired&&i){let t=i;if(t.elicitations)return new xu(t.elicitations,r)}return new e(n,r,i)}},xu=class extends U{constructor(n,r=`URL elicitation${n.length>1?"s":""} required`){super(A.UrlElicitationRequired,r,{elicitations:n})}get elicitations(){return this.data?.elicitations??[]}};function Re(e){return e==="completed"||e==="failed"||e==="cancelled"}var Bh=Symbol("Let zodToJsonSchema decide on which parser to use");var $_=new Set("ABCDEFGHIJKLMNOPQRSTUVXYZabcdefghijklmnopqrstuvxyz0123456789");function Zu(e){let r=ud(e)?.method;if(!r)throw new Error("Schema is missing a method literal");let i=ld(r);if(typeof i!="string")throw new Error("Schema method literal must be a string");return i}function Au(e,n){let r=Or(e,n);if(!r.success)throw r.error;return r.data}var tv=6e4,Io=class{constructor(n){this._options=n,this._requestMessageId=0,this._requestHandlers=new Map,this._requestHandlerAbortControllers=new Map,this._notificationHandlers=new Map,this._responseHandlers=new Map,this._progressHandlers=new Map,this._timeoutInfo=new Map,this._pendingDebouncedNotifications=new Set,this._taskProgressTokens=new Map,this._requestResolvers=new Map,this.setNotificationHandler(vo,r=>{this._oncancel(r)}),this.setNotificationHandler(bo,r=>{this._onprogress(r)}),this.setRequestHandler(Pt,r=>({})),this._taskStore=n?.taskStore,this._taskMessageQueue=n?.taskMessageQueue,this._taskStore&&(this.setRequestHandler(xo,async(r,i)=>{let t=await this._taskStore.getTask(r.params.taskId,i.sessionId);if(!t)throw new U(A.InvalidParams,"Failed to retrieve task: Task not found");return{...t}}),this.setRequestHandler($o,async(r,i)=>{let t=async()=>{let o=r.params.taskId;if(!await this._taskStore.getTask(o,i.sessionId))throw new U(A.InvalidParams,`Task not found: ${o}`);if(this._taskMessageQueue){let u;for(;u=await this._taskMessageQueue.dequeue(o,i.sessionId);){if(u.type==="response"||u.type==="error"){let c=u.message,g=c.id,f=this._requestResolvers.get(g);if(f)if(this._requestResolvers.delete(g),u.type==="response")f(c);else{let m=c,$=new U(m.error.code,m.error.message,m.error.data);f($)}else{let m=u.type==="response"?"Response":"Error";this._onerror(new Error(`${m} handler missing for request ${g}`))}continue}await this._transport?.send(u.message,{relatedRequestId:i.requestId})}}let a=await this._taskStore.getTask(o,i.sessionId);if(!a)throw new U(A.InvalidParams,`Task not found: ${o}`);if(!Re(a.status))return await this._waitForTaskUpdate(o,i.signal,i.sessionId),await t();if(Re(a.status)){let u=await this._taskStore.getTaskResult(o,i.sessionId);return this._clearTaskQueue(o,i.sessionId),{...u,_meta:{...u._meta,[Ee]:{taskId:o}}}}return await t()};return await t()}),this.setRequestHandler(ko,async(r,i)=>{try{let{tasks:t,nextCursor:o}=await this._taskStore.listTasks(r.params?.cursor,i.sessionId);return{tasks:t,nextCursor:o,_meta:{}}}catch(t){throw new U(A.InvalidParams,`Failed to list tasks: ${t instanceof Error?t.message:String(t)}`)}}),this.setRequestHandler(So,async(r,i)=>{try{let t=await this._taskStore.getTask(r.params.taskId,i.sessionId);if(!t)throw new U(A.InvalidParams,`Task not found: ${r.params.taskId}`);if(Re(t.status))throw new U(A.InvalidParams,`Cannot cancel task in terminal status: ${t.status}`);await this._taskStore.updateTaskStatus(r.params.taskId,"cancelled","Client cancelled task execution.",i.sessionId),this._clearTaskQueue(r.params.taskId,i.sessionId);let o=await this._taskStore.getTask(r.params.taskId,i.sessionId);if(!o)throw new U(A.InvalidParams,`Task not found after cancellation: ${r.params.taskId}`);return{_meta:{},...o}}catch(t){throw t instanceof U?t:new U(A.InvalidRequest,`Failed to cancel task: ${t instanceof Error?t.message:String(t)}`)}}))}async _oncancel(n){if(!n.params.requestId)return;this._requestHandlerAbortControllers.get(n.params.requestId)?.abort(n.params.reason)}_setupTimeout(n,r,i,t,o=!1){this._timeoutInfo.set(n,{timeoutId:setTimeout(t,r),startTime:Date.now(),timeout:r,maxTotalTimeout:i,resetTimeoutOnProgress:o,onTimeout:t})}_resetTimeout(n){let r=this._timeoutInfo.get(n);if(!r)return!1;let i=Date.now()-r.startTime;if(r.maxTotalTimeout&&i>=r.maxTotalTimeout)throw this._timeoutInfo.delete(n),U.fromError(A.RequestTimeout,"Maximum total timeout exceeded",{maxTotalTimeout:r.maxTotalTimeout,totalElapsed:i});return clearTimeout(r.timeoutId),r.timeoutId=setTimeout(r.onTimeout,r.timeout),!0}_cleanupTimeout(n){let r=this._timeoutInfo.get(n);r&&(clearTimeout(r.timeoutId),this._timeoutInfo.delete(n))}async connect(n){if(this._transport)throw new Error("Already connected to a transport. Call close() before connecting to a new transport, or use a separate Protocol instance per connection.");this._transport=n;let r=this.transport?.onclose;this._transport.onclose=()=>{r?.(),this._onclose()};let i=this.transport?.onerror;this._transport.onerror=o=>{i?.(o),this._onerror(o)};let t=this._transport?.onmessage;this._transport.onmessage=(o,a)=>{t?.(o,a),yn(o)||$p(o)?this._onresponse(o):$u(o)?this._onrequest(o,a):_p(o)?this._onnotification(o):this._onerror(new Error(`Unknown message type: ${JSON.stringify(o)}`))},await this._transport.start()}_onclose(){let n=this._responseHandlers;this._responseHandlers=new Map,this._progressHandlers.clear(),this._taskProgressTokens.clear(),this._pendingDebouncedNotifications.clear();for(let i of this._timeoutInfo.values())clearTimeout(i.timeoutId);this._timeoutInfo.clear();for(let i of this._requestHandlerAbortControllers.values())i.abort();this._requestHandlerAbortControllers.clear();let r=U.fromError(A.ConnectionClosed,"Connection closed");this._transport=void 0,this.onclose?.();for(let i of n.values())i(r)}_onerror(n){this.onerror?.(n)}_onnotification(n){let r=this._notificationHandlers.get(n.method)??this.fallbackNotificationHandler;r!==void 0&&Promise.resolve().then(()=>r(n)).catch(i=>this._onerror(new Error(`Uncaught error in notification handler: ${i}`)))}_onrequest(n,r){let i=this._requestHandlers.get(n.method)??this.fallbackRequestHandler,t=this._transport,o=n.params?._meta?.[Ee]?.taskId,a=t?.sessionId,u=this._taskStore,c=!0,g;if(o&&u&&this._taskMessageQueue&&a!==void 0&&(c=!1,g=(async()=>{if(!await u.getTask(o,a))throw new U(A.InvalidParams,`Task not found: ${o}`);c=!0})()),i===void 0){let d={jsonrpc:"2.0",id:n.id,error:{code:A.MethodNotFound,message:"Method not found"}};if(o&&g){let v={type:"error",message:d,timestamp:Date.now()};g.then(()=>this._enqueueTaskMessage(o,v,a),()=>t?.send(d)).catch(z=>this._onerror(new Error(`Failed to send an error response: ${z}`)))}else o&&this._taskMessageQueue?this._enqueueTaskMessage(o,{type:"error",message:d,timestamp:Date.now()},t?.sessionId).catch(v=>this._onerror(new Error(`Failed to enqueue error response: ${v}`))):t?.send(d).catch(v=>this._onerror(new Error(`Failed to send an error response: ${v}`)));return}let f=new AbortController;this._requestHandlerAbortControllers.set(n.id,f);let m=bp(n.params)?n.params.task:void 0,$=this._taskStore?this.requestTaskStore(n,t?.sessionId):void 0,y={signal:f.signal,sessionId:t?.sessionId,_meta:n.params?._meta,sendNotification:async d=>{if(f.signal.aborted)return;let v={relatedRequestId:n.id};o&&(v.relatedTask={taskId:o}),await this.notification(d,v)},sendRequest:async(d,v,z)=>{if(f.signal.aborted)throw new U(A.ConnectionClosed,"Request was cancelled");let C={...z,relatedRequestId:n.id};o&&!C.relatedTask&&(C.relatedTask={taskId:o});let w=C.relatedTask?.taskId??o;return w&&$&&await $.updateTaskStatus(w,"input_required"),await this.request(d,v,C)},authInfo:r?.authInfo,requestId:n.id,requestInfo:r?.requestInfo,taskId:o,taskStore:$,taskRequestedTtl:m?.ttl,closeSSEStream:r?.closeSSEStream,closeStandaloneSSEStream:r?.closeStandaloneSSEStream};(g??Promise.resolve()).then(()=>{if(g&&f.signal.aborted)throw new U(A.ConnectionClosed,"Request was cancelled");m&&this.assertTaskHandlerCapability(n.method)}).then(()=>i(n,y)).then(async d=>{if(f.signal.aborted)return;let v={result:d,jsonrpc:"2.0",id:n.id};o&&this._taskMessageQueue?await this._enqueueTaskMessage(o,{type:"response",message:v,timestamp:Date.now()},t?.sessionId):await t?.send(v)},async d=>{if(f.signal.aborted)return;let v={jsonrpc:"2.0",id:n.id,error:{code:Number.isSafeInteger(d.code)?d.code:A.InternalError,message:d.message??"Internal error",...d.data!==void 0&&{data:d.data}}};o&&this._taskMessageQueue&&c?await this._enqueueTaskMessage(o,{type:"error",message:v,timestamp:Date.now()},t?.sessionId):await t?.send(v)}).catch(d=>this._onerror(new Error(`Failed to send response: ${d}`))).finally(()=>{this._requestHandlerAbortControllers.get(n.id)===f&&this._requestHandlerAbortControllers.delete(n.id)})}_onprogress(n){let{progressToken:r,...i}=n.params,t=Number(r),o=this._progressHandlers.get(t);if(!o){this._onerror(new Error(`Received a progress notification for an unknown token: ${JSON.stringify(n)}`));return}let a=this._responseHandlers.get(t),u=this._timeoutInfo.get(t);if(u&&a&&u.resetTimeoutOnProgress)try{this._resetTimeout(t)}catch(c){this._responseHandlers.delete(t),this._progressHandlers.delete(t),this._cleanupTimeout(t),a(c);return}o(i)}_onresponse(n){let r=Number(n.id),i=this._requestResolvers.get(r);if(i){if(this._requestResolvers.delete(r),yn(n))i(n);else{let a=new U(n.error.code,n.error.message,n.error.data);i(a)}return}let t=this._responseHandlers.get(r);if(t===void 0){this._onerror(new Error(`Received a response for an unknown message ID: ${JSON.stringify(n)}`));return}this._responseHandlers.delete(r),this._cleanupTimeout(r);let o=!1;if(yn(n)&&n.result&&typeof n.result=="object"){let a=n.result;if(a.task&&typeof a.task=="object"){let u=a.task;typeof u.taskId=="string"&&(o=!0,this._taskProgressTokens.set(u.taskId,r))}}if(o||this._progressHandlers.delete(r),yn(n))t(n);else{let a=U.fromError(n.error.code,n.error.message,n.error.data);t(a)}}get transport(){return this._transport}async close(){await this._transport?.close()}async*requestStream(n,r,i){let{task:t}=i??{};if(!t){try{yield{type:"result",result:await this.request(n,r,i)}}catch(a){yield{type:"error",error:a instanceof U?a:new U(A.InternalError,String(a))}}return}let o;try{let a=await this.request(n,yo,i);if(a.task)o=a.task.taskId,yield{type:"taskCreated",task:a.task};else throw new U(A.InternalError,"Task creation did not return a task");for(;;){let u=await this.getTask({taskId:o},i);if(yield{type:"taskStatus",task:u},Re(u.status)){u.status==="completed"?yield{type:"result",result:await this.getTaskResult({taskId:o},r,i)}:u.status==="failed"?yield{type:"error",error:new U(A.InternalError,`Task ${o} failed`)}:u.status==="cancelled"&&(yield{type:"error",error:new U(A.InternalError,`Task ${o} was cancelled`)});return}if(u.status==="input_required"){yield{type:"result",result:await this.getTaskResult({taskId:o},r,i)};return}let c=u.pollInterval??this._options?.defaultTaskPollInterval??1e3;await new Promise(g=>setTimeout(g,c)),i?.signal?.throwIfAborted()}}catch(a){yield{type:"error",error:a instanceof U?a:new U(A.InternalError,String(a))}}}request(n,r,i){let{relatedRequestId:t,resumptionToken:o,onresumptiontoken:a,task:u,relatedTask:c}=i??{};return new Promise((g,f)=>{let m=w=>{f(w)};if(!this._transport){m(new Error("Not connected"));return}if(this._options?.enforceStrictCapabilities===!0)try{this.assertCapabilityForMethod(n.method),u&&this.assertTaskCapability(n.method)}catch(w){m(w);return}i?.signal?.throwIfAborted();let $=this._requestMessageId++,y={...n,jsonrpc:"2.0",id:$};i?.onprogress&&(this._progressHandlers.set($,i.onprogress),y.params={...n.params,_meta:{...n.params?._meta||{},progressToken:$}}),u&&(y.params={...y.params,task:u}),c&&(y.params={...y.params,_meta:{...y.params?._meta||{},[Ee]:c}});let d=w=>{this._responseHandlers.delete($),this._progressHandlers.delete($),this._cleanupTimeout($),this._transport?.send({jsonrpc:"2.0",method:"notifications/cancelled",params:{requestId:$,reason:String(w)}},{relatedRequestId:t,resumptionToken:o,onresumptiontoken:a}).catch(D=>this._onerror(new Error(`Failed to send cancellation: ${D}`)));let j=w instanceof U?w:new U(A.RequestTimeout,String(w));f(j)};this._responseHandlers.set($,w=>{if(!i?.signal?.aborted){if(w instanceof Error)return f(w);try{let j=Or(r,w.result);j.success?g(j.data):f(j.error)}catch(j){f(j)}}}),i?.signal?.addEventListener("abort",()=>{d(i?.signal?.reason)});let v=i?.timeout??tv,z=()=>d(U.fromError(A.RequestTimeout,"Request timed out",{timeout:v}));this._setupTimeout($,v,i?.maxTotalTimeout,z,i?.resetTimeoutOnProgress??!1);let C=c?.taskId;if(C){let w=j=>{let D=this._responseHandlers.get($);D?D(j):this._onerror(new Error(`Response handler missing for side-channeled request ${$}`))};this._requestResolvers.set($,w),this._enqueueTaskMessage(C,{type:"request",message:y,timestamp:Date.now()}).catch(j=>{this._cleanupTimeout($),f(j)})}else this._transport.send(y,{relatedRequestId:t,resumptionToken:o,onresumptiontoken:a}).catch(w=>{this._cleanupTimeout($),f(w)})})}async getTask(n,r){return this.request({method:"tasks/get",params:n},_o,r)}async getTaskResult(n,r,i){return this.request({method:"tasks/result",params:n},r,i)}async listTasks(n,r){return this.request({method:"tasks/list",params:n},zo,r)}async cancelTask(n,r){return this.request({method:"tasks/cancel",params:n},zp,r)}async notification(n,r){if(!this._transport)throw new Error("Not connected");this.assertNotificationCapability(n.method);let i=r?.relatedTask?.taskId;if(i){let u={...n,jsonrpc:"2.0",params:{...n.params,_meta:{...n.params?._meta||{},[Ee]:r.relatedTask}}};await this._enqueueTaskMessage(i,{type:"notification",message:u,timestamp:Date.now()});return}if((this._options?.debouncedNotificationMethods??[]).includes(n.method)&&!n.params&&!r?.relatedRequestId&&!r?.relatedTask){if(this._pendingDebouncedNotifications.has(n.method))return;this._pendingDebouncedNotifications.add(n.method),Promise.resolve().then(()=>{if(this._pendingDebouncedNotifications.delete(n.method),!this._transport)return;let u={...n,jsonrpc:"2.0"};r?.relatedTask&&(u={...u,params:{...u.params,_meta:{...u.params?._meta||{},[Ee]:r.relatedTask}}}),this._transport?.send(u,r).catch(c=>this._onerror(c))});return}let a={...n,jsonrpc:"2.0"};r?.relatedTask&&(a={...a,params:{...a.params,_meta:{...a.params?._meta||{},[Ee]:r.relatedTask}}}),await this._transport.send(a,r)}setRequestHandler(n,r){let i=Zu(n);this.assertRequestHandlerCapability(i),this._requestHandlers.set(i,(t,o)=>{let a=Au(n,t);return Promise.resolve(r(a,o))})}removeRequestHandler(n){this._requestHandlers.delete(n)}assertCanSetRequestHandler(n){if(this._requestHandlers.has(n))throw new Error(`A request handler for ${n} already exists, which would be overridden`)}setNotificationHandler(n,r){let i=Zu(n);this._notificationHandlers.set(i,t=>{let o=Au(n,t);return Promise.resolve(r(o))})}removeNotificationHandler(n){this._notificationHandlers.delete(n)}_cleanupTaskProgressHandler(n){let r=this._taskProgressTokens.get(n);r!==void 0&&(this._progressHandlers.delete(r),this._taskProgressTokens.delete(n))}async _enqueueTaskMessage(n,r,i){if(!this._taskStore||!this._taskMessageQueue)throw new Error("Cannot enqueue task message: taskStore and taskMessageQueue are not configured");let t=this._options?.maxTaskQueueSize;await this._taskMessageQueue.enqueue(n,r,i??this._transport?.sessionId,t)}async _clearTaskQueue(n,r){if(this._taskMessageQueue){let i=await this._taskMessageQueue.dequeueAll(n,r);for(let t of i)if(t.type==="request"&&$u(t.message)){let o=t.message.id,a=this._requestResolvers.get(o);a?(a(new U(A.InternalError,"Task cancelled or completed")),this._requestResolvers.delete(o)):this._onerror(new Error(`Resolver missing for request ${o} during task ${n} cleanup`))}}}async _waitForTaskUpdate(n,r,i){let t=this._options?.defaultTaskPollInterval??1e3;try{let o=await this._taskStore?.getTask(n,i);o?.pollInterval&&(t=o.pollInterval)}catch{}return new Promise((o,a)=>{if(r.aborted){a(new U(A.InvalidRequest,"Request cancelled"));return}let u=setTimeout(o,t);r.addEventListener("abort",()=>{clearTimeout(u),a(new U(A.InvalidRequest,"Request cancelled"))},{once:!0})})}requestTaskStore(n,r){let i=this._taskStore;if(!i)throw new Error("No task store configured");return{createTask:async t=>{if(!n)throw new Error("No request provided");return await i.createTask(t,n.id,{method:n.method,params:n.params},r)},getTask:async t=>{let o=await i.getTask(t,r);if(!o)throw new U(A.InvalidParams,"Failed to retrieve task: Task not found");return o},storeTaskResult:async(t,o,a)=>{await i.storeTaskResult(t,o,a,r);let u=await i.getTask(t,r);if(u){let c=Sn.parse({method:"notifications/tasks/status",params:u});await this.notification(c),Re(u.status)&&this._cleanupTaskProgressHandler(t)}},getTaskResult:t=>i.getTaskResult(t,r),updateTaskStatus:async(t,o,a)=>{let u=await i.getTask(t,r);if(!u)throw new U(A.InvalidParams,`Task "${t}" not found - it may have been cleaned up`);if(Re(u.status))throw new U(A.InvalidParams,`Cannot update task "${t}" from terminal status "${u.status}" to "${o}". Terminal states (completed, failed, cancelled) cannot transition to other states.`);await i.updateTaskStatus(t,o,a,r);let c=await i.getTask(t,r);if(c){let g=Sn.parse({method:"notifications/tasks/status",params:c});await this.notification(g),Re(c.status)&&this._cleanupTaskProgressHandler(t)}},listTasks:t=>i.listTasks(t,r)}}};function Tp(e){return e!==null&&typeof e=="object"&&!Array.isArray(e)}function Op(e,n){let r={...e};for(let i in n){let t=i,o=n[t];if(o===void 0)continue;let a=r[t];Tp(a)&&Tp(o)?r[t]={...a,...o}:r[t]=o}return r}vn();vn();var xz=(e=>typeof De<"u"?De:typeof Proxy<"u"?new Proxy(e,{get:(n,r)=>(typeof De<"u"?De:n)[r]}):e)(function(e){if(typeof De<"u")return De.apply(this,arguments);throw Error(\'Dynamic require of "\'+e+\'" is not supported\')}),Mu=class extends Io{_registeredMethods=new Set;_eventSlots=new Map;onEventDispatch(n,r){}_ensureEventSlot(n){let r=this._eventSlots.get(n);if(!r){let i=this.eventSchemas[n];if(!i)throw Error(`Unknown event: ${String(n)}`);r={listeners:[]},this._eventSlots.set(n,r);let t=i.shape.method.value;this._registeredMethods.add(t);let o=r;super.setNotificationHandler(i,a=>{let u=a.params;this.onEventDispatch(n,u),o.onHandler?.(u);for(let c of[...o.listeners])c(u)})}return r}setEventHandler(n,r){let i=this._ensureEventSlot(n);i.onHandler&&r&&console.warn(`[MCP Apps] on${String(n)} handler replaced. Use addEventListener("${String(n)}", \\u2026) to add multiple listeners without replacing.`),i.onHandler=r}getEventHandler(n){return this._eventSlots.get(n)?.onHandler}addEventListener(n,r){this._ensureEventSlot(n).listeners.push(r)}removeEventListener(n,r){let i=this._eventSlots.get(n);if(!i)return;let t=i.listeners.indexOf(r);t!==-1&&i.listeners.splice(t,1)}setRequestHandler=(n,r)=>{this._assertMethodNotRegistered(n,"setRequestHandler"),super.setRequestHandler(n,r)};setNotificationHandler=(n,r)=>{this._assertMethodNotRegistered(n,"setNotificationHandler"),super.setNotificationHandler(n,r)};warnIfRequestHandlerReplaced(n,r,i){r&&i&&console.warn(`[MCP Apps] ${n} handler replaced. Previous handler will no longer be called.`)}replaceRequestHandler=(n,r)=>{let i=n.shape.method.value;this._registeredMethods.add(i),super.setRequestHandler(n,r)};_assertMethodNotRegistered(n,r){let i=n.shape.method.value;if(this._registeredMethods.has(i))throw Error(`Handler for "${i}" already registered (via ${r}). Use addEventListener() to attach multiple listeners, or the on* setter for replace semantics.`);this._registeredMethods.add(i)}},nv="2026-01-26";var rv="ui/notifications/tool-input-partial";var Lu=class{eventTarget;eventSource;messageListener;constructor(n=window.parent,r){this.eventTarget=n,this.eventSource=r,this.messageListener=i=>{if(r&&i.source!==this.eventSource){console.debug("Ignoring message from unknown source",i);return}let t=kp.safeParse(i.data);t.success?(console.debug("Parsed message",t.data),this.onmessage?.(t.data)):i.data?.jsonrpc!=="2.0"?console.debug("Ignoring non-JSON-RPC message",t.error.message,i):(console.error("Failed to parse message",t.error.message,i),this.onerror?.(Error("Invalid JSON-RPC message received: "+t.error.message)))}}async start(){window.addEventListener("message",this.messageListener)}async send(n,r){n.method!==rv&&console.debug("Sending message",n),this.eventTarget.postMessage(n,"*")}async close(){window.removeEventListener("message",this.messageListener),this.onclose?.()}onclose;onerror;onmessage;sessionId;setProtocolVersion},ov=s.union([s.literal("light"),s.literal("dark")]).describe("Color theme preference for the host environment."),Pn=s.union([s.literal("inline"),s.literal("fullscreen"),s.literal("pip")]).describe("Display mode for UI presentation."),iv=s.union([s.literal("--color-background-primary"),s.literal("--color-background-secondary"),s.literal("--color-background-tertiary"),s.literal("--color-background-inverse"),s.literal("--color-background-ghost"),s.literal("--color-background-info"),s.literal("--color-background-danger"),s.literal("--color-background-success"),s.literal("--color-background-warning"),s.literal("--color-background-disabled"),s.literal("--color-text-primary"),s.literal("--color-text-secondary"),s.literal("--color-text-tertiary"),s.literal("--color-text-inverse"),s.literal("--color-text-ghost"),s.literal("--color-text-info"),s.literal("--color-text-danger"),s.literal("--color-text-success"),s.literal("--color-text-warning"),s.literal("--color-text-disabled"),s.literal("--color-border-primary"),s.literal("--color-border-secondary"),s.literal("--color-border-tertiary"),s.literal("--color-border-inverse"),s.literal("--color-border-ghost"),s.literal("--color-border-info"),s.literal("--color-border-danger"),s.literal("--color-border-success"),s.literal("--color-border-warning"),s.literal("--color-border-disabled"),s.literal("--color-ring-primary"),s.literal("--color-ring-secondary"),s.literal("--color-ring-inverse"),s.literal("--color-ring-info"),s.literal("--color-ring-danger"),s.literal("--color-ring-success"),s.literal("--color-ring-warning"),s.literal("--font-sans"),s.literal("--font-mono"),s.literal("--font-weight-normal"),s.literal("--font-weight-medium"),s.literal("--font-weight-semibold"),s.literal("--font-weight-bold"),s.literal("--font-text-xs-size"),s.literal("--font-text-sm-size"),s.literal("--font-text-md-size"),s.literal("--font-text-lg-size"),s.literal("--font-heading-xs-size"),s.literal("--font-heading-sm-size"),s.literal("--font-heading-md-size"),s.literal("--font-heading-lg-size"),s.literal("--font-heading-xl-size"),s.literal("--font-heading-2xl-size"),s.literal("--font-heading-3xl-size"),s.literal("--font-text-xs-line-height"),s.literal("--font-text-sm-line-height"),s.literal("--font-text-md-line-height"),s.literal("--font-text-lg-line-height"),s.literal("--font-heading-xs-line-height"),s.literal("--font-heading-sm-line-height"),s.literal("--font-heading-md-line-height"),s.literal("--font-heading-lg-line-height"),s.literal("--font-heading-xl-line-height"),s.literal("--font-heading-2xl-line-height"),s.literal("--font-heading-3xl-line-height"),s.literal("--border-radius-xs"),s.literal("--border-radius-sm"),s.literal("--border-radius-md"),s.literal("--border-radius-lg"),s.literal("--border-radius-xl"),s.literal("--border-radius-full"),s.literal("--border-width-regular"),s.literal("--shadow-hairline"),s.literal("--shadow-sm"),s.literal("--shadow-md"),s.literal("--shadow-lg")]).describe("CSS variable keys available to MCP apps for theming."),av=s.record(iv.describe(`Style variables for theming MCP apps.\n\nIndividual style keys are optional - hosts may provide any subset of these values.\nValues are strings containing CSS values (colors, sizes, font stacks, etc.).\n\nNote: This type uses \\`Record<K, string | undefined>\\` rather than \\`Partial<Record<K, string>>\\`\nfor compatibility with Zod schema generation. Both are functionally equivalent for validation.`),s.union([s.string(),s.undefined()]).describe(`Style variables for theming MCP apps.\n\nIndividual style keys are optional - hosts may provide any subset of these values.\nValues are strings containing CSS values (colors, sizes, font stacks, etc.).\n\nNote: This type uses \\`Record<K, string | undefined>\\` rather than \\`Partial<Record<K, string>>\\`\nfor compatibility with Zod schema generation. Both are functionally equivalent for validation.`)).describe(`Style variables for theming MCP apps.\n\nIndividual style keys are optional - hosts may provide any subset of these values.\nValues are strings containing CSS values (colors, sizes, font stacks, etc.).\n\nNote: This type uses \\`Record<K, string | undefined>\\` rather than \\`Partial<Record<K, string>>\\`\nfor compatibility with Zod schema generation. Both are functionally equivalent for validation.`),Iz=s.object({method:s.literal("ui/open-link"),params:s.object({url:s.string().describe("URL to open in the host\'s browser")})}),sv=s.object({isError:s.boolean().optional().describe("True if the host failed to open the URL (e.g., due to security policy).")}).passthrough(),uv=s.object({isError:s.boolean().optional().describe("True if the download failed (e.g., user cancelled or host denied).")}).passthrough(),lv=s.object({isError:s.boolean().optional().describe("True if the host rejected or failed to deliver the message.")}).passthrough(),Pz=s.object({method:s.literal("ui/notifications/sandbox-proxy-ready"),params:s.object({})}),qu=s.object({connectDomains:s.array(s.string()).optional().describe(`Origins for network requests (fetch/XHR/WebSocket).\n\n- Maps to CSP \\`connect-src\\` directive\n- Empty or omitted \\u2192 no network connections (secure default)`),resourceDomains:s.array(s.string()).optional().describe("Origins for static resources (images, scripts, stylesheets, fonts, media).\\n\\n- Maps to CSP `img-src`, `script-src`, `style-src`, `font-src`, `media-src` directives\\n- Wildcard subdomains supported: `https://*.example.com`\\n- Empty or omitted \\u2192 no network resources (secure default)"),frameDomains:s.array(s.string()).optional().describe("Origins for nested iframes.\\n\\n- Maps to CSP `frame-src` directive\\n- Empty or omitted \\u2192 no nested iframes allowed (`frame-src \'none\'`)"),baseUriDomains:s.array(s.string()).optional().describe("Allowed base URIs for the document.\\n\\n- Maps to CSP `base-uri` directive\\n- Empty or omitted \\u2192 only same origin allowed (`base-uri \'self\'`)")}),Fu=s.object({camera:s.object({}).optional().describe("Request camera access.\\n\\nMaps to Permission Policy `camera` feature."),microphone:s.object({}).optional().describe("Request microphone access.\\n\\nMaps to Permission Policy `microphone` feature."),geolocation:s.object({}).optional().describe("Request geolocation access.\\n\\nMaps to Permission Policy `geolocation` feature."),clipboardWrite:s.object({}).optional().describe("Request clipboard write access.\\n\\nMaps to Permission Policy `clipboard-write` feature.")}),jz=s.object({method:s.literal("ui/notifications/size-changed"),params:s.object({width:s.number().optional().describe("New width in pixels."),height:s.number().optional().describe("New height in pixels.")})}),cv=s.object({method:s.literal("ui/notifications/tool-input"),params:s.object({arguments:s.record(s.string(),s.unknown().describe("Complete tool call arguments as key-value pairs.")).optional().describe("Complete tool call arguments as key-value pairs.")})}),dv=s.object({method:s.literal("ui/notifications/tool-input-partial"),params:s.object({arguments:s.record(s.string(),s.unknown().describe("Partial tool call arguments (incomplete, may change).")).optional().describe("Partial tool call arguments (incomplete, may change).")})}),pv=s.object({method:s.literal("ui/notifications/tool-cancelled"),params:s.object({reason:s.string().optional().describe(\'Optional reason for the cancellation (e.g., "user action", "timeout").\')})}),mv=s.object({fonts:s.string().optional()}),fv=s.object({variables:av.optional().describe("CSS variables for theming the app."),css:mv.optional().describe("CSS blocks that apps can inject.")}),gv=s.object({method:s.literal("ui/resource-teardown"),params:s.object({})}),Tz=s.record(s.string(),s.unknown()),Np=s.object({text:s.object({}).optional().describe("Host supports text content blocks."),image:s.object({}).optional().describe("Host supports image content blocks."),audio:s.object({}).optional().describe("Host supports audio content blocks."),resource:s.object({}).optional().describe("Host supports resource content blocks."),resourceLink:s.object({}).optional().describe("Host supports resource link content blocks."),structuredContent:s.object({}).optional().describe("Host supports structured content.")}),Oz=s.object({method:s.literal("ui/notifications/request-teardown"),params:s.object({}).optional()}),hv=s.object({experimental:s.record(s.string(),s.record(s.string(),s.any()).describe("Experimental features keyed by identifier.")).optional().describe("Experimental features keyed by identifier."),openLinks:s.object({}).optional().describe("Host supports opening external URLs."),downloadFile:s.object({}).optional().describe("Host supports file downloads via ui/download-file."),serverTools:s.object({listChanged:s.boolean().optional().describe("Host supports tools/list_changed notifications.")}).optional().describe("Host can proxy tool calls to the MCP server."),serverResources:s.object({listChanged:s.boolean().optional().describe("Host supports resources/list_changed notifications.")}).optional().describe("Host can proxy resource reads to the MCP server."),logging:s.object({}).optional().describe("Host accepts log messages."),sandbox:s.object({permissions:Fu.optional().describe("Permissions granted by the host (camera, microphone, geolocation)."),csp:qu.optional().describe("CSP domains approved by the host.")}).optional().describe("Sandbox configuration applied by the host."),updateModelContext:Np.optional().describe("Host accepts context updates (ui/update-model-context) to be included in the model\'s context for future turns."),message:Np.optional().describe("Host supports receiving content messages (ui/message) from the view."),sampling:s.object({tools:s.object({}).optional().describe("Host supports tool use via `tools` and `toolChoice` parameters.")}).optional().describe("Host supports LLM sampling (sampling/createMessage) from the view.\\nMirrors the MCP `ClientCapabilities.sampling` shape so hosts can pass it through.")}),vv=s.object({experimental:s.record(s.string(),s.record(s.string(),s.any()).describe("Experimental features keyed by identifier.")).optional().describe("Experimental features keyed by identifier."),tools:s.object({listChanged:s.boolean().optional().describe("App supports tools/list_changed notifications.")}).optional().describe("App exposes MCP-style tools that the host can call."),availableDisplayModes:s.array(Pn).optional().describe("Display modes the app supports.")}),Nz=s.object({method:s.literal("ui/notifications/initialized"),params:s.object({}).optional()}),Ez=s.object({csp:qu.optional().describe("Content Security Policy configuration for UI resources."),permissions:Fu.optional().describe("Sandbox permissions requested by the UI resource."),domain:s.string().optional().describe(`Dedicated origin for view sandbox.\n\nUseful when views need stable, dedicated origins for OAuth callbacks, CORS policies, or API key allowlists.\n\n**Host-dependent:** The format and validation rules for this field are determined by each host. Servers MUST consult host-specific documentation for the expected domain format. Common patterns include:\n- Hash-based subdomains (e.g., \\`{hash}.claudemcpcontent.com\\`)\n- URL-derived subdomains (e.g., \\`www-example-com.oaiusercontent.com\\`)\n\nIf omitted, host uses default sandbox origin (typically per-conversation).`),prefersBorder:s.boolean().optional().describe(`Visual boundary preference - true if view prefers a visible border.\n\nBoolean requesting whether a visible border and background is provided by the host. Specifying an explicit value for this is recommended because hosts\' defaults may vary.\n\n- \\`true\\`: request visible border + background\n- \\`false\\`: request no visible border + background\n- omitted: host decides border`)}),Rz=s.object({method:s.literal("ui/request-display-mode"),params:s.object({mode:Pn.describe("The display mode being requested.")})}),bv=s.object({mode:Pn.describe("The display mode that was actually set. May differ from requested if not supported.")}).passthrough(),yv=s.union([s.literal("model"),s.literal("app")]).describe("Tool visibility scope - who can access the tool."),Uz=s.object({resourceUri:s.string().optional(),visibility:s.array(yv).optional().describe(`Who can access this tool. Default: ["model", "app"]\n- "model": Tool visible to and callable by the agent\n- "app": Tool callable by the app from this server only`),csp:s.never().optional(),permissions:s.never().optional()}),Cz=s.object({mimeTypes:s.array(s.string()).optional().describe(\'Array of supported MIME types for UI resources.\\nMust include `"text/html;profile=mcp-app"` for MCP Apps support.\')}),Dz=s.object({method:s.literal("ui/download-file"),params:s.object({contents:s.array(s.union([Nu,Eu])).describe("Resource contents to download \\u2014 embedded (inline data) or linked (host fetches). Uses standard MCP resource types.")})}),Zz=s.object({method:s.literal("ui/message"),params:s.object({role:s.literal("user").describe(\'Message role, currently only "user" is supported.\'),content:s.array(Tt).describe("Message content blocks (text, image, etc.).")})}),Az=s.object({method:s.literal("ui/notifications/sandbox-resource-ready"),params:s.object({html:s.string().describe("HTML content to load into the inner iframe."),sandbox:s.string().optional().describe("Optional override for the inner iframe\'s sandbox attribute."),csp:qu.optional().describe("CSP configuration from resource metadata."),permissions:Fu.optional().describe("Sandbox permissions from resource metadata.")})}),xv=s.object({method:s.literal("ui/notifications/tool-result"),params:Ot.describe("Standard MCP tool execution result.")}),Up=s.object({toolInfo:s.object({id:It.optional().describe("JSON-RPC id of the tools/call request."),tool:wo.describe("Tool definition including name, inputSchema, etc.")}).optional().describe("Metadata of the tool call that instantiated this App."),theme:ov.optional().describe("Current color theme preference."),styles:fv.optional().describe("Style configuration for theming the app."),displayMode:Pn.optional().describe("How the UI is currently displayed."),availableDisplayModes:s.array(Pn).optional().describe("Display modes the host supports."),containerDimensions:s.union([s.object({height:s.number().describe("Fixed container height in pixels.")}),s.object({maxHeight:s.union([s.number(),s.undefined()]).optional().describe("Maximum container height in pixels.")})]).and(s.union([s.object({width:s.number().describe("Fixed container width in pixels.")}),s.object({maxWidth:s.union([s.number(),s.undefined()]).optional().describe("Maximum container width in pixels.")})])).optional().describe(`Container dimensions. Represents the dimensions of the iframe or other\ncontainer holding the app. Specify either width or maxWidth, and either height or maxHeight.`),locale:s.string().optional().describe("User\'s language and region preference in BCP 47 format."),timeZone:s.string().optional().describe("User\'s timezone in IANA format."),userAgent:s.string().optional().describe("Host application identifier."),platform:s.union([s.literal("web"),s.literal("desktop"),s.literal("mobile")]).optional().describe("Platform type for responsive design decisions."),deviceCapabilities:s.object({touch:s.boolean().optional().describe("Whether the device supports touch input."),hover:s.boolean().optional().describe("Whether the device supports hover interactions.")}).optional().describe("Device input capabilities."),safeAreaInsets:s.object({top:s.number().describe("Top safe area inset in pixels."),right:s.number().describe("Right safe area inset in pixels."),bottom:s.number().describe("Bottom safe area inset in pixels."),left:s.number().describe("Left safe area inset in pixels.")}).optional().describe("Mobile safe area boundaries in pixels.")}).passthrough(),_v=s.object({method:s.literal("ui/notifications/host-context-changed"),params:Up.describe("Partial context update containing only changed fields.")}),Mz=s.object({method:s.literal("ui/update-model-context"),params:s.object({content:s.array(Tt).optional().describe("Context content blocks (text, image, etc.)."),structuredContent:s.record(s.string(),s.unknown().describe("Structured content for machine-readable context data.")).optional().describe("Structured content for machine-readable context data.")})}),Lz=s.object({method:s.literal("ui/initialize"),params:s.object({appInfo:_n.describe("App identification (name and version)."),appCapabilities:vv.describe("Features and capabilities this app provides."),protocolVersion:s.string().describe("Protocol version this app supports.")})}),$v=s.object({protocolVersion:s.string().describe(\'Negotiated protocol version string (e.g., "2025-11-21").\'),hostInfo:_n.describe("Host application identification and version."),hostCapabilities:hv.describe("Features and capabilities provided by the host."),hostContext:Up.describe("Rich context about the host environment.")}).passthrough(),kv={target:"draft-2020-12"};async function Ep(e,n){let r=e["~standard"];if(r.jsonSchema)return r.jsonSchema[n](kv);if(r.vendor==="zod"){let{z:i}=await Promise.resolve().then(()=>(vn(),yu));return i.toJSONSchema(e,{io:n})}throw Error(`Schema (vendor: ${r.vendor}) does not implement Standard JSON Schema (~standard.jsonSchema). Use a library that does (zod v4, ArkType, Valibot) or wrap your schema accordingly.`)}async function Rp(e,n,r=""){let i=await e["~standard"].validate(n);if(i.issues){let t=i.issues.map(o=>{let a=o.path?.map(u=>typeof u=="object"?u.key:u).join(".");return a?`${a}: ${o.message}`:o.message}).join("; ");throw Error(r+t)}return i.value}function Hu(e){let n=document.documentElement;n.setAttribute("data-theme",e),n.style.colorScheme=e}var Po=class e extends Mu{_appInfo;_capabilities;options;_hostCapabilities;_hostInfo;_hostContext;_registeredTools={};_initializedSent=!1;_assertInitialized(n){if(this._initializedSent)return;let r=`[ext-apps] App.${n}() called before connect() completed the ui/initialize handshake. Await app.connect() before calling this method, or move data loading to an ontoolresult handler.`;if(this.options?.strict)throw Error(r);console.warn(`${r}. This will throw in a future release.`)}eventSchemas={toolinput:cv,toolinputpartial:dv,toolresult:xv,toolcancelled:pv,hostcontextchanged:_v};static ONE_SHOT_EVENTS=new Set(["toolinput","toolinputpartial","toolresult","toolcancelled"]);_everHadListener=new Set;_assertHandlerTiming(n){if(!e.ONE_SHOT_EVENTS.has(n)||this._everHadListener.has(n)||(this._everHadListener.add(n),!this._initializedSent))return;let r=`[ext-apps] "${String(n)}" handler registered after connect() completed the ui/initialize handshake. The host may have already sent this notification. Register handlers before calling app.connect().`;if(this.options?.strict)throw Error(r);console.warn(r)}setEventHandler(n,r){r&&this._assertHandlerTiming(n),super.setEventHandler(n,r)}addEventListener(n,r){this._assertHandlerTiming(n),super.addEventListener(n,r)}onEventDispatch(n,r){n==="hostcontextchanged"&&(this._hostContext={...this._hostContext,...r})}constructor(n,r={},i={autoResize:!0}){super(i),this._appInfo=n,this._capabilities=r,this.options=i,i.allowUnsafeEval||s.config({jitless:!0}),this.setRequestHandler(Pt,t=>(console.log("Received ping:",t.params),{})),this.setEventHandler("hostcontextchanged",void 0)}registerCapabilities(n){if(this.transport)throw Error("Cannot register capabilities after transport is established");this._capabilities=Op(this._capabilities,n)}registerTool(n,r,i){if(this._registeredTools[n])throw Error(`Tool ${n} is already registered`);let t=this,o=()=>{t._initializedSent&&t._capabilities.tools?.listChanged&&t.sendToolListChanged()},a=r.inputSchema!==void 0,u={title:r.title,description:r.description,inputSchema:r.inputSchema,outputSchema:r.outputSchema,annotations:r.annotations,_meta:r._meta,enabled:!0,enable(){this.enabled=!0,o()},disable(){this.enabled=!1,o()},update(c){Object.assign(this,c),o()},remove(){t._registeredTools[n]===u&&(delete t._registeredTools[n],o())},handler:async(c,g)=>{if(!u.enabled)throw Error(`Tool ${n} is disabled`);let f;if(a){let m=u.inputSchema,$=m?await Rp(m,c??{},`Invalid input for tool ${n}: `):c??{};f=await i($,g)}else f=await i(g);return u.outputSchema&&!f.isError&&(f.structuredContent=await Rp(u.outputSchema,f.structuredContent,`Invalid output for tool ${n}: `)),f}};return this._registeredTools[n]=u,!this._capabilities.tools&&!this.transport&&this.registerCapabilities({tools:{listChanged:!0}}),this.ensureToolHandlersInitialized(),o(),u}_toolHandlersInitialized=!1;ensureToolHandlersInitialized(){this._toolHandlersInitialized||(this._toolHandlersInitialized=!0,this.oncalltool=async(n,r)=>{let i=this._registeredTools[n.name];if(!i)throw Error(`Tool ${n.name} not found`);return i.handler(n.arguments,r)},this.onlisttools=async(n,r)=>({tools:await Promise.all(Object.entries(this._registeredTools).filter(([i,t])=>t.enabled).map(async([i,t])=>{let o={name:i,title:t.title,description:t.description,inputSchema:t.inputSchema?await Ep(t.inputSchema,"input"):{type:"object",properties:{}}};return t.outputSchema&&(o.outputSchema=await Ep(t.outputSchema,"output")),t.annotations&&(o.annotations=t.annotations),t._meta&&(o._meta=t._meta),o}))}))}async sendToolListChanged(n={}){this._assertInitialized("sendToolListChanged"),await this.notification({method:"notifications/tools/list_changed",params:n})}getHostCapabilities(){return this._hostCapabilities}getHostVersion(){return this._hostInfo}getHostContext(){return this._hostContext}get ontoolinput(){return this.getEventHandler("toolinput")}set ontoolinput(n){this.setEventHandler("toolinput",n)}get ontoolinputpartial(){return this.getEventHandler("toolinputpartial")}set ontoolinputpartial(n){this.setEventHandler("toolinputpartial",n)}get ontoolresult(){return this.getEventHandler("toolresult")}set ontoolresult(n){this.setEventHandler("toolresult",n)}get ontoolcancelled(){return this.getEventHandler("toolcancelled")}set ontoolcancelled(n){this.setEventHandler("toolcancelled",n)}get onhostcontextchanged(){return this.getEventHandler("hostcontextchanged")}set onhostcontextchanged(n){this.setEventHandler("hostcontextchanged",n)}_onteardown;get onteardown(){return this._onteardown}set onteardown(n){this.warnIfRequestHandlerReplaced("onteardown",this._onteardown,n),this._onteardown=n,this.replaceRequestHandler(gv,(r,i)=>{if(!this._onteardown)throw Error("No onteardown handler set");return this._onteardown(r.params,i)})}_oncalltool;get oncalltool(){return this._oncalltool}set oncalltool(n){this.warnIfRequestHandlerReplaced("oncalltool",this._oncalltool,n),this._oncalltool=n,this.replaceRequestHandler(Uu,(r,i)=>{if(!this._oncalltool)throw Error("No oncalltool handler set");return this._oncalltool(r.params,i)})}_onlisttools;get onlisttools(){return this._onlisttools}set onlisttools(n){this.warnIfRequestHandlerReplaced("onlisttools",this._onlisttools,n),this._onlisttools=n,this.replaceRequestHandler(Ru,(r,i)=>{if(!this._onlisttools)throw Error("No onlisttools handler set");return this._onlisttools(r.params,i)})}assertCapabilityForMethod(n){switch(n){case"sampling/createMessage":if(!this._hostCapabilities?.sampling)throw Error(`Host does not support sampling (required for ${n})`);break}}assertRequestHandlerCapability(n){switch(n){case"tools/call":case"tools/list":if(!this._capabilities.tools)throw Error(`Client does not support tool capability (required for ${n})`);return;case"ping":case"ui/resource-teardown":return;default:throw Error(`No handler for method ${n} registered`)}}assertNotificationCapability(n){}assertTaskCapability(n){throw Error("Tasks are not supported in MCP Apps")}assertTaskHandlerCapability(n){throw Error("Task handlers are not supported in MCP Apps")}async callServerTool(n,r){if(this._assertInitialized("callServerTool"),typeof n=="string")throw Error(`callServerTool() expects an object as its first argument, but received a string ("${n}"). Did you mean: callServerTool({ name: "${n}", arguments: { ... } })?`);return await this.request({method:"tools/call",params:n},Ot,{onprogress:()=>{},resetTimeoutOnProgress:!0,...r})}async readServerResource(n,r){return this._assertInitialized("readServerResource"),await this.request({method:"resources/read",params:n},Pu,r)}async listServerResources(n,r){return this._assertInitialized("listServerResources"),await this.request({method:"resources/list",params:n},wu,r)}async createSamplingMessage(n,r){this._assertInitialized("createSamplingMessage");let i=n.tools?Du:Cu;return await this.request({method:"sampling/createMessage",params:n},i,r)}sendMessage(n,r){return this._assertInitialized("sendMessage"),this.request({method:"ui/message",params:n},lv,r)}sendLog(n){return this.notification({method:"notifications/message",params:n})}updateModelContext(n,r){return this._assertInitialized("updateModelContext"),this.request({method:"ui/update-model-context",params:n},ho,r)}openLink(n,r){return this._assertInitialized("openLink"),this.request({method:"ui/open-link",params:n},sv,r)}sendOpenLink=this.openLink;downloadFile(n,r){return this._assertInitialized("downloadFile"),this.request({method:"ui/download-file",params:n},uv,r)}requestTeardown(n={}){return this.notification({method:"ui/notifications/request-teardown",params:n})}requestDisplayMode(n,r){return this._assertInitialized("requestDisplayMode"),this.request({method:"ui/request-display-mode",params:n},bv,r)}sendSizeChanged(n){return this.notification({method:"ui/notifications/size-changed",params:n})}setupSizeChangedNotifications(){let n=!1,r=0,i=0,t=()=>{n||(n=!0,requestAnimationFrame(()=>{n=!1;let a=document.documentElement,u=a.style.height;a.style.height="max-content";let c=Math.ceil(a.getBoundingClientRect().height);a.style.height=u;let g=Math.ceil(window.innerWidth);(g!==r||c!==i)&&(r=g,i=c,this.sendSizeChanged({width:g,height:c}))}))};t();let o=new ResizeObserver(t);return o.observe(document.documentElement),o.observe(document.body),()=>o.disconnect()}async connect(n=new Lu(window.parent,window.parent),r){if(this.transport)throw Error("App is already connected. Call close() before connecting again.");this._initializedSent=!1,await super.connect(n);try{let i=await this.request({method:"ui/initialize",params:{appCapabilities:this._capabilities,appInfo:this._appInfo,protocolVersion:nv}},$v,r);if(i===void 0)throw Error(`Server sent invalid initialize result: ${i}`);this._hostCapabilities=i.hostCapabilities,this._hostInfo=i.hostInfo,this._hostContext=i.hostContext,await this.notification({method:"ui/notifications/initialized"}),this._initializedSent=!0,this.options?.autoResize&&this.setupSizeChangedNotifications()}catch(i){throw this.close(),i}}};var jn=e=>typeof e=="object"&&e!==null&&!Array.isArray(e)?e:null;function oe(e){return e===null||!/^-?\\d+$/.test(e)?null:BigInt(e)}var zv={USDC:6,EURC:6,ETH:18,XDC:18};function Vu(e,n){let r=n===null?void 0:zv[n];if(e===null||n===null||r===void 0||!/^\\d+$/.test(e))return null;let i=e.padStart(r+1,"0"),t=i.slice(0,i.length-r).replace(/^0+(?=\\d)/,""),o=i.slice(i.length-r).replace(/0+$/,"");return`${t}${o?`.${o}`:""} ${n}`}function Cp(e){return`${e.unitsDone??""}:${e.spentRef??""}:${e.payments??""}`}function Sv(e){return e>=3?null:5e3*e}async function Ju(e,n,r){let i=0;for(;n();)try{await e(),i=0}catch{i+=1;let t=Sv(i);if(t===null)return"gave-up";await r(t)}return"stopped"}function jo(e){return(e.content??[]).map(n=>n.text??"").join(`\n`).trim()}var wv=30*6e4,Iv=6e4,Pv=2e3,jv=1e4,Tv=new Set(["trial","run","publication","completion"]),Ov=new Set(["pending_approval","pending_publication","draft_changed"]),Wu=new Set(["trial","run"]);function Nv(e){let n=jn(e);return n!==null&&typeof n.kind=="string"&&Tv.has(n.kind)&&typeof n.missionId=="string"&&typeof n.status=="string"&&typeof n.versionNumber=="number"&&typeof n.envelopeRef=="string"&&typeof n.currency=="string"}function Ku(e){let n=jn(e)?.card;return Nv(n)?n:null}function Ev(e){let n=jn(e)?.state;return typeof n=="string"?n:null}function To(e){return e!==null&&Ov.has(e.status)}function Rv(e,n){return n-e>=wv}function Dp(e){return e?"empty":"loading"}function Uv(e){return e.runId?{runId:e.runId,known:e.status}:{missionId:e.missionId,versionNumber:e.versionNumber,digest:e.digest,known:e.status}}function Et(e){return e!==null&&Wu.has(e.kind)&&e.status==="active"}function Cv(e,n){return{runId:e.runId,known:"active",progress:Cp(e),pollMs:n<Iv?Pv:jv}}function Dv(e,n,r){return Et(n)?e??r:null}function Zp(e,n){if(!e.expiresAt)return!1;let r=Date.parse(e.expiresAt);return Number.isFinite(r)&&n>=r}function Nt(e){return e!==null&&e.kind==="completion"&&e.runKind==="trial"&&e.status==="completed"&&e.publish!=="none"}function Zv(e){return{missionId:e.missionId,versionNumber:e.versionNumber,known:"unpublished"}}function Av(e){return{...e,status:"published",publish:"none",blocker:null}}function Ap(e,n,r){let i=Dv(n,e,r),t=Et(e);return{args:t?Cv(e,r-(i??r)):Nt(e)?Zv(e):Uv(e),followSince:i,following:t}}function Mp(e,n,r){let i=Ku(n),t=Ev(n),o=e;return i?o=i:t==="published"&&Nt(e)?o=Av(e):t&&!Nt(e)&&(o={...e,status:t}),Et(o)&&Zp(o,r)?{...o,status:"expired"}:o}function Lp(e,n,r){return e===null?!1:To(e)||Nt(e)?!Rv(n,r):Et(e)&&!Zp(e,r)}function Bu(e,n){return e||n||void 0}var Fp="\\u2212",Hp=e=>e<0?Fp:e>0?"+":"",Ue=(e,n)=>n===1||e.endsWith("s")?e:`${e}s`,Mv={headings:{trial:"Trial request",run:"Run request",publication:"Mission publication",completion:"Run completed"},completedHeadings:{trial:"Trial completed",run:"Run completed"},badges:{pending_approval:"Pending approval",active:"Running",declined:"Declined",abandoned:"Withdrawn",completed:"Completed",cancelled:"Cancelled",expired:"Expired",pending_publication:"Ready to publish",draft_changed:"Draft changed",published:"Published",discarded:"Draft discarded"},notes:{active:"The agent can pay inside this run.",declined:"The agent will not run it.",abandoned:"The request is withdrawn.",cancelled:"An operator cancelled the run.",expired:"The request expired before a decision.",ranExpired:"The run reached its deadline.",draft_changed:"The draft changed since this card: what you publish is the draft as it is now.",published:"The mission is published: the wallets it is shared with can run it.",discarded:"The draft was discarded without being published."},validate:"Validate in Keyban",publish:"Publish mission in Keyban",noLink:"Do it from the Keyban dashboard.",notPublishable:e=>`Not publishable yet: ${e}`,perRun:"per run",spentOf:e=>`spent of ${e}`,spent:"spent",payments:e=>`${e} ${e===1?"payment":"payments"}`,anyOtherService:"any other x402 service",otherPayments:"other payments",noLimit:"no limit set",details:"Details",rows:{frequency:"Frequency",simultaneous:"Simultaneous runs",duration:"Run duration",sharing:"Shared with",overrides:"CFO overrides",delivered:"Delivered",paid:"Paid",payments:"Payments"},paidOn:{trial:"Paid on this trial",run:"Paid on this run"},simultaneous:e=>`${e} per wallet`,duration:e=>`${e} ${e===1?"day":"days"}`,columns:{source:"Source",calls:"Calls",paid:"Paid",subtotal:"Subtotal"},planPer:(e,n)=>`Plan per ${n?"run":e??"unit"}`,replaces:e=>`replaces v${e}`,batch:(e,n)=>`${e} ${Ue(n??"unit",e)}`,per:e=>`per ${e??"unit"}`,sample:(e,n,r)=>`Trial on a sample of ${e} ${Ue(n??"unit",e)} \\xB7 up to ${r}`,envelopePerRun:"Envelope per run",estimatedCost:(e,n)=>`Estimated cost per ${n?"run":e??"unit"}`,estimatedTotal:(e,n,r)=>`Estimated total of the ${e?"trial":"run"} \\xB7 ${n} ${Ue(r??"unit",n)}`,unplanned:e=>`+ ${e} ${e===1?"source":"sources"} without plan`,percent:e=>`${Hp(e)}${Math.abs(e)}%`,before:"before",of:e=>`of ${e}`,was:e=>`was ${e}`,newSource:"New",removedSource:"removed",txLink:e=>e===1?"tx":`${e} tx`,units:(e,n,r)=>`${e} ${Ue(n??"unit",e)} \\xD7 ${r}`,onDemand:"Each run waits for an operator",auto:"Runs start without approval",frequency:(e,n)=>`Runs start without approval, ${e===1?"once":`${e} times`} a ${n}`,sharing:{wallet:"this wallet only",application:"the wallets of this application",organization:"the whole organization"},overrides:e=>`${e} ${e===1?"override":"overrides"} of the CFO\'s rules`,watchFailed:"Live updates stopped: the state shown may be out of date.",watchStopped:"The card stopped following this request: open it in Keyban to see where it stands."},Lv={day:"jour",week:"semaine",month:"mois"},qv={headings:{trial:"Demande d\'essai",run:"Demande d\'ex\\xE9cution",publication:"Publication de mission",completion:"Ex\\xE9cution termin\\xE9e"},completedHeadings:{trial:"Essai termin\\xE9",run:"Ex\\xE9cution termin\\xE9e"},badges:{pending_approval:"En attente de validation",active:"En cours",declined:"Refus\\xE9e",abandoned:"Retir\\xE9e",completed:"Termin\\xE9e",cancelled:"Annul\\xE9e",expired:"Expir\\xE9e",pending_publication:"Pr\\xEAte \\xE0 publier",draft_changed:"Brouillon modifi\\xE9",published:"Publi\\xE9e",discarded:"Brouillon abandonn\\xE9"},notes:{active:"L\'agent peut payer dans cette ex\\xE9cution.",declined:"L\'agent ne la lancera pas.",abandoned:"La demande est retir\\xE9e.",cancelled:"Un op\\xE9rateur a annul\\xE9 l\'ex\\xE9cution.",expired:"La demande a expir\\xE9 avant une d\\xE9cision.",ranExpired:"L\'ex\\xE9cution a atteint son \\xE9ch\\xE9ance.",draft_changed:"Le brouillon a chang\\xE9 depuis cette carte : vous publiez le brouillon tel qu\'il est maintenant.",published:"La mission est publi\\xE9e : les wallets avec qui elle est partag\\xE9e peuvent la lancer.",discarded:"Le brouillon a \\xE9t\\xE9 abandonn\\xE9 sans \\xEAtre publi\\xE9."},validate:"Valider dans Keyban",publish:"Publier la mission dans Keyban",noLink:"Faites-le depuis le tableau de bord Keyban.",notPublishable:e=>`Pas encore publiable : ${e}`,perRun:"par ex\\xE9cution",spentOf:e=>`d\\xE9pens\\xE9s sur ${e}`,spent:"d\\xE9pens\\xE9s",payments:e=>`${e} ${e===1?"paiement":"paiements"}`,anyOtherService:"tout autre service x402",otherPayments:"autres paiements",noLimit:"aucune limite fix\\xE9e",details:"D\\xE9tails",rows:{frequency:"Fr\\xE9quence",simultaneous:"Ex\\xE9cutions simultan\\xE9es",duration:"Dur\\xE9e d\'une ex\\xE9cution",sharing:"Partag\\xE9e avec",overrides:"D\\xE9rogations CFO",delivered:"Livr\\xE9",paid:"Pay\\xE9",payments:"Paiements"},paidOn:{trial:"Pay\\xE9 sur cet essai",run:"Pay\\xE9 sur cette ex\\xE9cution"},simultaneous:e=>`${e} par wallet`,duration:e=>`${e} ${e===1?"jour":"jours"}`,columns:{source:"Source",calls:"Appels",paid:"Pay\\xE9",subtotal:"Sous-total"},planPer:(e,n)=>`Plan par ${n?"ex\\xE9cution":e??"unit\\xE9"}`,replaces:e=>`remplace la v${e}`,batch:(e,n)=>`${e} ${Ue(n??"unit\\xE9",e)}`,per:e=>`par ${e??"unit\\xE9"}`,sample:(e,n,r)=>`Essai sur un \\xE9chantillon de ${e} ${Ue(n??"unit\\xE9",e)} \\xB7 jusqu\'\\xE0 ${r}`,envelopePerRun:"Enveloppe par ex\\xE9cution",estimatedCost:(e,n)=>`Co\\xFBt estim\\xE9 par ${n?"ex\\xE9cution":e??"unit\\xE9"}`,estimatedTotal:(e,n,r)=>`Total estim\\xE9 ${e?"de l\'essai":"de l\'ex\\xE9cution"} \\xB7 ${n} ${Ue(r??"unit\\xE9",n)}`,unplanned:e=>`+ ${e} ${e===1?"source":"sources"} sans plan`,percent:e=>`${Hp(e)}${Math.abs(e)}\\u202F%`,before:"avant",of:e=>`sur ${e}`,was:e=>`avant : ${e}`,newSource:"Nouvelle",removedSource:"retir\\xE9e",txLink:e=>e===1?"tx":`${e} tx`,units:(e,n,r)=>`${e} ${Ue(n??"unit\\xE9",e)} \\xD7 ${r}`,onDemand:"Chaque ex\\xE9cution attend un op\\xE9rateur",auto:"Les ex\\xE9cutions d\\xE9marrent sans validation",frequency:(e,n)=>`Les ex\\xE9cutions d\\xE9marrent sans validation, ${e===1?"une fois":`${e} fois`} par ${Lv[n]}`,sharing:{wallet:"ce wallet seulement",application:"les wallets de cette application",organization:"toute l\'organisation"},overrides:e=>`${e} ${e===1?"d\\xE9rogation":"d\\xE9rogations"} aux r\\xE8gles du CFO`,watchFailed:"Le suivi en direct s\'est interrompu : l\'\\xE9tat affich\\xE9 peut dater.",watchStopped:"La carte ne suit plus cette demande : ouvrez-la dans Keyban pour voir o\\xF9 elle en est."};function Xu(e){return e?.toLowerCase().startsWith("fr")?qv:Mv}var Fv={pending_approval:{tone:"waiting",icon:"clock",final:!1},pending_publication:{tone:"waiting",icon:"clock",final:!1},draft_changed:{tone:"waiting",icon:"triangle-alert",final:!1},active:{tone:"success",icon:"loader",final:!0},published:{tone:"success",icon:"circle-check",final:!0},completed:{tone:"success",icon:"circle-check",final:!0},declined:{tone:"danger",icon:"circle-x",final:!0},abandoned:{tone:"neutral",icon:"ban",final:!0},cancelled:{tone:"neutral",icon:"ban",final:!0},expired:{tone:"neutral",icon:"ban",final:!0},discarded:{tone:"neutral",icon:"ban",final:!0}};function el(e,n){return{...Fv[e]??{tone:"neutral",icon:"triangle-alert",final:!0},badge:n.badges[e]??e,note:n.notes[e]??null}}function Vp(e,n,r){return e.status==="expired"&&r?n.notes.ranExpired??null:el(e.status,n).note}function Jp(e,n){return e.kind==="completion"&&e.runKind?n.completedHeadings[e.runKind]:n.headings[e.kind]}function Wp(e,n){let r=`\\xB7 v${e.versionNumber}`;return e.diff?`${r} \\xB7 ${n.replaces(e.diff.replaces)}`:r}function Kp(e,n){return e.kind==="publication"||e.kind==="completion"?n.publish:n.validate}function Bp(e,n){return e.kind==="completion"?e.publish==="ready":!n.final}function Gp(e,n){return e.kind==="completion"&&e.publish==="blocked"&&e.blocker?n.notPublishable(e.blocker):null}function ke(e,n){try{let r=new Intl.NumberFormat(n,{style:"currency",currency:e}),i=r.resolvedOptions().maximumFractionDigits??2;return t=>r.format(Number(t)/10**i)}catch{return r=>`${r} ${e}`.trim()}}function tl(e,n){try{let i=new Intl.NumberFormat(n,{style:"currency",currency:e}).resolvedOptions().maximumFractionDigits??2,t=new Intl.NumberFormat(n,{style:"currency",currency:e,minimumFractionDigits:i,maximumFractionDigits:i+3});return o=>t.format(o/10**i)}catch{return r=>`${r} ${e}`.trim()}}function Qp(e){if(e.spentCents!==null){let r=Number(e.spentCents);return Number.isFinite(r)?r:null}let n=oe(e.spentRef);return n===null?null:Number(n)}function Hv(e){let n=Qp(e);return e.kind!=="completion"||n===null||n===0||e.unitsDone===null||e.unitsDone<=0?null:n/e.unitsDone}function Vv(e){let n=e.reference?.unitPriceCents;if(n==null)return null;let r=Number(n);return Number.isFinite(r)&&r>0?r:null}function Jv(e,n){let r=Qp(e),i=r===null?ke(e.currency,n)(e.spentRef??"0"):tl(e.currency,n)(r),t=Vu(e.spentNative,e.spentAsset);return t?`${i} \\xB7 ${t}`:i}function nl(e,n){return e.unitCount===null||e.unitsDone===null?null:`${e.unitsDone} / ${n.batch(e.unitCount,e.unitLabel)}`}var Wv=new Set(["active","completed","cancelled","expired"]);function Yp(e){return Wu.has(e.kind)&&Wv.has(e.status)}function Xp(e,n,r){if(!Yp(e))return null;let i=ke(e.currency,r),t=[e.payments===null?null:n.payments(e.payments),e.spentRef===null?null:`${i(e.spentRef)} ${n.spentOf(i(e.envelopeRef))}`].filter(o=>o!==null);return t.length===0?null:t.join(" \\xB7 ")}function em(e,n,r){return e.kind!=="completion"?[]:[[n.rows.paid,Jv(e,r)],[n.rows.payments,String(e.payments??0)],[n.rows.delivered,nl(e,n)]].flatMap(([t,o])=>o===null?[]:[{label:t,value:o}])}function tm(e,n){return e.kind==="completion"?n.paidOn[e.runKind??"run"]:null}function Kv(e){let n=/^([A-Za-z]+) ([^\\s/]+)(\\/\\S*)?$/.exec(e.trim());return n?{method:(n[1]??"").toUpperCase(),host:n[2]??"",path:n[3]??"/"}:null}var Oo={tag:null,was:null,plan:null};function rl(e){let n=e===null?null:/^(\\d+)(?:\\.(\\d{1,3}))?$/.exec(e);return n?BigInt(n[1]??"0")*1000n+BigInt((n[2]??"").padEnd(3,"0")):null}function ol(e,n){let r=tl(e,n);return i=>r(Number(i)/1e3)}function qp(e,n,r){let i=rl(n);return e!==null&&i!==null?`${e} \\xD7 ${r(i)}`:null}function Bv(e,n,r){let i=rl(n);return e!==null&&Number.isInteger(e)&&i!==null?r(BigInt(e)*i):"\\u2014"}function nm(e,n){let r=oe(e),i=n.reduce((t,o)=>{let a=oe(o);return t===null||a===null?null:t+a},0n);return r===null||i===null?null:(r>i?r-i:0n).toString()}function Yu(e,n){return e===null||oe(e)===0n?null:Vu(e,n)}function Gv(e,n){let r=n.filter(i=>oe(i.paidNative)!==0n);return r.some(i=>i.asset!==e.spentAsset)?null:Yu(nm(e.spentNative,r.map(i=>i.paidNative)),e.spentAsset)}function Gu(e,n){let r=Kv(e)?.host??null;return{title:n??r??e,host:n?r:null,note:""}}var Qu={host:null};function il(e){return e.kind==="completion"||Yp(e)&&(e.sourceUsage!==null||e.otherPayments!==null)}function al(e,n,r){let i=ke(e.currency,r);if(il(e)){let c=e.otherPayments;if(!e.sourceUsage)return[{...Qu,title:n.anyOtherService,note:n.noLimit,calls:String(e.payments??0),amount:i(e.spentRef??"0"),native:Yu(e.spentNative,e.spentAsset),txUrls:c?.txUrls??[],...Oo}];let g=e.sourceUsage.map(m=>({...Gu(m.endpoint,m.label),calls:String(m.calls),amount:i(m.paidRef),native:Yu(m.paidNative,m.asset),txUrls:m.txUrls,...Oo}));if(!c)return g;let f=nm(e.spentRef??"0",e.sourceUsage.map(m=>m.paidRef));return[...g,{...Qu,title:n.otherPayments,note:"",calls:String(c.calls),amount:f===null?"\\u2014":i(f),native:Gv(e,e.sourceUsage),txUrls:c.txUrls,...Oo}]}if(!e.sources)return[{...Qu,title:n.anyOtherService,note:n.noLimit,calls:"\\u2014",amount:"\\u2014",native:null,txUrls:[],...Oo}];let t=e.diff?.previous??{},o=ol(e.currency,r),a=e.sources.map(c=>{let g=t[c.endpoint],f=g?qp(g.callsPerUnit,g.callPriceRef,o):null;return{...Gu(c.endpoint,c.label),calls:c.callsPerUnit===null?"\\u2014":String(c.callsPerUnit),amount:Bv(c.callsPerUnit,c.callPriceRef,o),native:null,txUrls:[],tag:e.diff?.newEndpoints.includes(c.endpoint)?"new":null,was:f===null?null:n.was(f),plan:qp(c.callsPerUnit,c.callPriceRef,o)}}),u=(e.diff?.removed??[]).map(c=>({...Gu(c.endpoint,c.label),calls:"",amount:"",native:null,txUrls:[],tag:"removed",was:null,plan:null}));return[...a,...u]}function Qv(e){return e<0n?Fp:"+"}function Yv(e,n,r){let i=oe(e),t=oe(n);if(i===null||t===null||t===0n)return null;let o=Math.round(Number(i-t)/Number(t)*100);return o===0?null:{text:r.percent(o),tone:o<0?"better":"worse"}}function Xv(e,n,r){let i=ke(e.currency,r),t=Hv(e);if(t===null)return{was:null,now:i(e.spentRef??"0"),suffix:n.spent,delta:null};let o=tl(e.currency,r),a=Vv(e),u=a===null?0:Math.round((t-a)/a*100);return{was:a===null?null:o(a),now:o(t),suffix:n.per(e.unitLabel),delta:u===0?null:{text:n.percent(u),tone:u<0?"better":"worse"}}}function rm(e,n,r){if(e.kind==="completion")return Xv(e,n,r);let i=ke(e.currency,r),t=e.unitPriceRef??e.envelopeRef,o=(e.unitPriceRef===null?e.diff?.envelopeWas:e.diff?.unitPriceWas)??null;return{was:o===null?null:i(o),now:i(t),suffix:e.unitPriceRef===null?n.perRun:n.per(e.unitLabel),delta:Yv(t,o,n)}}function om(e,n,r){return e.kind!=="trial"||e.unitPriceRef===null||e.unitCount===null?null:n.sample(e.unitCount,e.unitLabel,ke(e.currency,r)(e.envelopeRef))}function im(e,n,r){let i=n===null?0n:e-n;return i===0n?null:{text:`${Qv(i)}${r((i<0n?-i:i).toString())}`,tone:i<0n?"better":"worse"}}function am(e,n,r,i,t){return r===null||i===null?n.envelopePerRun:`${n.envelopePerRun} \\xB7 ${n.units(r,e.unitLabel,t(i.toString()))}`}function eb(e,n,r){let i=ke(e.currency,r),t=oe(e.unitPriceRef),o=e.versionUnitCount,a=t!==null&&o!==null?BigInt(o)*t:t!==null&&e.runKind==="trial"?null:oe(e.envelopeRef),u=oe(e.recalibratedEnvelopeRef),c=u??a;if(c===null)return null;let g=u===null||a===c?null:a;return{label:am(e,n,o,oe(e.recalibratedUnitPriceRef)??t,i),was:g===null?null:i(g.toString()),now:i(c.toString()),diff:im(c,g,i)}}function sm(e,n,r){if(e.kind==="completion")return eb(e,n,r);let i=oe(e.unitPriceRef);if(i===null)return null;let t=ke(e.currency,r),o=e.versionUnitCount;if(o===null&&e.kind==="trial")return null;let a=o===null?oe(e.envelopeRef):BigInt(o)*i;if(a===null)return null;let u=oe(e.diff?.envelopeWas??null);return{label:am(e,n,o,i,t),was:u===null?null:t(u.toString()),now:t(a.toString()),diff:im(a,u,t)}}function um(e){if(e.kind==="completion"||!e.sources)return null;let n=e.sources.flatMap(r=>{let i=rl(r.callPriceRef);return r.callsPerUnit!==null&&Number.isInteger(r.callsPerUnit)&&i!==null?[BigInt(r.callsPerUnit)*i]:[]});return n.length===0?null:{total:n.reduce((r,i)=>r+i,0n),unplanned:e.sources.length-n.length}}function lm(e,n,r){let i=um(e);if(!i)return null;let t=ke(e.currency,r),o=e.unitPriceRef??e.envelopeRef,a=oe(o);return{label:n.estimatedCost(e.unitLabel,e.unitPriceRef===null),value:ol(e.currency,r)(i.total),of:n.of(t(o)),alert:a!==null&&i.total>a*1000n,unplanned:i.unplanned>0?n.unplanned(i.unplanned):null}}function cm(e,n,r){if(e.kind!=="trial"&&e.kind!=="run"||e.unitPriceRef===null||e.unitCount===null)return null;let i=um(e);if(!i)return null;let t=ke(e.currency,r),o=i.total*BigInt(e.unitCount),a=oe(e.envelopeRef);return{label:n.estimatedTotal(e.kind==="trial",e.unitCount,e.unitLabel),value:ol(e.currency,r)(o),of:n.of(t(e.envelopeRef)),alert:a!==null&&o>a*1000n,unplanned:null}}function tb(e,n){if(e.mode==="on_demand")return n.onDemand;if(e.mode==="auto")return n.auto;let r=e.frequency?.period;return e.mode==="frequency"&&e.frequency&&(r==="day"||r==="week"||r==="month")?n.frequency(e.frequency.count,r):null}function dm(e,n){return[[n.rows.frequency,tb(e,n)],[n.rows.simultaneous,e.maxActiveRunsPerWallet===null?null:n.simultaneous(e.maxActiveRunsPerWallet)],[n.rows.duration,e.durationDays===null?null:n.duration(e.durationDays)],[n.rows.sharing,e.sharing?n.sharing[e.sharing]??null:null],[n.rows.overrides,e.overrides>0?n.overrides(e.overrides):null]].flatMap(([i,t])=>t===null?[]:[{label:i,value:t}])}function pm(e){return e.filter(n=>n.txUrls.length>0).map(n=>({label:n.title,links:n.txUrls.map((r,i)=>({text:`tx${n.txUrls.length>1?` ${i+1}`:""} \\u2197`,url:r}))}))}function N(e){let n=document.getElementById(e);if(!n)throw new Error(`#${e} is missing from the card`);return n}var P={card:N("card"),heading:N("heading"),state:N("state"),stateIcon:N("state-icon"),stateLabel:N("state-label"),mission:N("mission"),version:N("version"),wasLabel:N("was-label"),was:N("was"),arrow:N("arrow"),amount:N("amount"),suffix:N("suffix"),delta:N("delta"),progress:N("progress"),units:N("units"),sample:N("sample"),planFoot:N("plan-foot"),estimate:N("estimate"),estimateLabel:N("estimate-label"),estimateValue:N("estimate-value"),estimateOf:N("estimate-of"),estimateUnplanned:N("estimate-unplanned"),total:N("total"),totalLabel:N("total-label"),totalValue:N("total-value"),totalOf:N("total-of"),envelope:N("envelope"),envelopeLabel:N("envelope-label"),envelopeWas:N("envelope-was"),envelopeNow:N("envelope-now"),envelopeDiff:N("envelope-diff"),paidTitle:N("paid-title"),summary:N("summary"),sources:N("sources"),sourcesHead:N("sources-head"),sourcesBody:N("sources-body"),folded:N("folded"),foldedTitle:N("folded-title"),rows:N("rows"),status:N("status"),error:N("error"),foot:N("foot"),actions:N("actions"),open:N("open"),openLabel:N("open-label")},ge,L=Xu(void 0),K=null,fm=null,gm=!1,hm=!1,vm=!1,sl=!1,bm=!1,ul=null,ll=!1,nb=e=>new Promise(n=>setTimeout(n,e));function ym(e){ge=Bu(e,navigator.language),L=Xu(ge),document.documentElement.lang=ge??"en"}function xm(){let e=hm?L.watchFailed:vm?L.watchStopped:fm;P.error.hidden=!e,P.error.textContent=e??""}function No(e,n,r){let i=document.createElement(e);return n&&(i.className=n),r!==void 0&&(i.textContent=r),i}function rb(e){let n=al(e,L,ge),r=il(e);P.sources.hidden=n.length===0;let i=L.planPer(e.unitLabel,e.unitPriceRef===null),t=[L.columns.source,r?L.columns.calls:i,r?L.columns.paid:L.columns.subtotal];P.sourcesHead.replaceChildren(...t.map((o,a)=>No("th",a===0?void 0:"num",o))),P.sourcesBody.replaceChildren(...n.map(o=>{let a=document.createElement("tr");o.tag==="removed"&&(a.className="strike");let u=No("td"),c=document.createElement("div");if(c.className="label",c.textContent=o.title,o.tag){let f=document.createElement("span");f.className=`tag ${o.tag}`,f.textContent=o.tag==="new"?L.newSource:L.removedSource,c.append(f)}if(u.append(c),o.host){let f=document.createElement("div");f.className="ep",f.textContent=o.host,u.append(f)}if(o.note){let f=document.createElement("div");f.className="note",f.textContent=o.note,u.append(f)}if(o.was){let f=document.createElement("div");f.className="was",f.textContent=o.was,u.append(f)}let g=No("td","num",o.amount);if(o.native){let f=document.createElement("div");f.className="native",f.textContent=o.native,g.append(f)}return a.append(u,No("td","num",r?o.calls:o.plan??o.calls),g),a}))}function ob(e){let n=dm(e,L),r=pm(al(e,L,ge));P.folded.hidden=n.length===0&&r.length===0,P.foldedTitle.textContent=L.details;let i=n.flatMap(o=>{let a=document.createElement("dt");a.textContent=o.label;let u=document.createElement("dd");return u.textContent=o.value,[a,u]}),t=r.flatMap(o=>{let a=document.createElement("dt");a.textContent=o.label;let u=document.createElement("dd");return o.links.forEach(({text:c,url:g})=>{let f=document.createElement("a");f.href=g,f.textContent=c,f.addEventListener("click",m=>{m.preventDefault(),_m(g)}),u.append(f)}),[a,u]});P.rows.replaceChildren(...i,...t)}function ze(e,n){e.hidden=!n,e.textContent=n??""}function ib(e,n){ze(P.delta,e),P.delta.className=`delta${n?` ${n}`:""}`}function ab(e){let n=rm(e,L,ge);ze(P.wasLabel,n.was?`${L.before} `:null),ze(P.was,n.was),P.arrow.hidden=!n.was,P.amount.textContent=n.now,P.suffix.textContent=n.suffix,ib(n.delta?.text??null,n.delta?.tone??null),ze(P.sample,om(e,L,ge))}function sb(e){let n=lm(e,L,ge),r=cm(e,L,ge),i=sm(e,L,ge);P.planFoot.hidden=!n&&!r&&!i,P.estimate.hidden=!n,P.estimate.className=`line${n?.alert?" alert":""}`,P.estimateLabel.textContent=n?.label??"",P.estimateValue.textContent=n?.value??"",P.estimateOf.textContent=n?.of??"",ze(P.estimateUnplanned,n?.unplanned??null),P.total.hidden=!r,P.total.className=`line${r?.alert?" alert":""}`,P.totalLabel.textContent=r?.label??"",P.totalValue.textContent=r?.value??"",P.totalOf.textContent=r?.of??"",P.envelope.hidden=!i,P.envelopeLabel.textContent=i?.label??"",ze(P.envelopeWas,i?.was??null),P.envelopeNow.textContent=i?.now??"",ze(P.envelopeDiff,i?.diff?.text??null),P.envelopeDiff.className=`change${i?.diff?` ${i.diff.tone}`:""}`}function ub(e){ab(e),ze(P.paidTitle,tm(e,L)),ze(P.progress,Xp(e,L,ge)),ze(P.units,e.status==="active"?nl(e,L):null),sb(e);let n=em(e,L,ge);P.summary.hidden=n.length===0,P.summary.replaceChildren(...n.flatMap(r=>{let i=document.createElement("dt");i.textContent=r.label;let t=document.createElement("dd");return t.textContent=r.value,[i,t]}))}function Eo(){if(xm(),!K){P.card.dataset.tone=Dp(gm),P.state.hidden=!0,P.foot.hidden=!0;return}let e=el(K.status,L),n=Gp(K,L),r=Bp(K,e);P.card.dataset.tone=e.tone,P.card.dataset.state=K.status,P.heading.textContent=Jp(K,L),P.state.hidden=!1,P.stateIcon.setAttribute("href",`#i-${e.icon}`),P.stateLabel.textContent=e.badge,P.mission.textContent=K.missionTitle,P.version.textContent=Wp(K,L),ub(K),rb(K),ob(K);let i=n??Vp(K,L,ll);P.status.hidden=!i,P.status.textContent=i??"",P.actions.hidden=!r,P.open.disabled=!K.approvalUrl,P.openLabel.textContent=Kp(K,L),P.foot.hidden=!r}async function lb(){if(sl)return;sl=!0;let e=Date.now();await Ju(async()=>{if(!K)return;let r=Ap(K,ul,Date.now());ul=r.followSince,r.following&&(ll=!0);let i=await Be.callServerTool({name:"watch_mission_approval",arguments:r.args});if(i.isError)throw new Error(jo(i));K=Mp(K,i.structuredContent,Date.now()),Eo()},()=>!bm&&Lp(K,e,Date.now()),nb)==="gave-up"?hm=!0:To(K)&&(vm=!0),xm(),sl=!1}function mm(e){P.error.hidden=!1,P.error.textContent=`${L.noLink} ${e}`}async function _m(e){try{let{isError:n}=await Be.openLink({url:e});n&&mm(e)}catch{mm(e)}}function $m(e){e&&(e.theme&&Hu(e.theme),e.locale&&ym(e.locale),Eo())}var Be=new Po({name:"Keyban mission card",version:"1.0.0"});Be.ontoolresult=e=>{gm=!0,K=Ku(e.structuredContent),ul=null,ll=!1,fm=e.isError?jo(e):null,Eo(),(To(K)||Et(K)||Nt(K))&&lb()};Be.onhostcontextchanged=e=>$m(e);Be.onteardown=async()=>(bm=!0,{});P.open.addEventListener("click",()=>{K?.approvalUrl&&_m(K.approvalUrl)});ym(void 0);Hu(matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light");Eo();await Be.connect();$m(Be.getHostContext());\n</script>\n</body>\n</html>\n' : UNBUILT_PAGE,
|
|
172561
172621
|
csp: { resourceDomains: ["https://fonts.googleapis.com", "https://fonts.gstatic.com"] }
|
|
172562
172622
|
}
|
|
172563
172623
|
};
|
|
@@ -172584,9 +172644,9 @@ var BROADCAST_FAILURE_MARKERS = [
|
|
|
172584
172644
|
"facilitator verify failed (429",
|
|
172585
172645
|
"facilitator settle failed (429"
|
|
172586
172646
|
];
|
|
172587
|
-
function isBroadcastFailure(
|
|
172588
|
-
if (!
|
|
172589
|
-
const haystack =
|
|
172647
|
+
function isBroadcastFailure(text5) {
|
|
172648
|
+
if (!text5) return false;
|
|
172649
|
+
const haystack = text5.toLowerCase();
|
|
172590
172650
|
return BROADCAST_FAILURE_MARKERS.some((marker) => haystack.includes(marker));
|
|
172591
172651
|
}
|
|
172592
172652
|
var BROADCAST_FAILURE_HINT = "The payment never reached a block: either the facilitator itself did not answer (a gateway error), or it could not broadcast the transaction from the single account it relays every tenant through. Either way this is infrastructure trouble rather than a problem with this payment \u2014 the authorization was not spent and nothing was charged. Retrying re-sends the same authorization, which cannot double-charge.";
|
|
@@ -172611,10 +172671,10 @@ function explorerTxUrl(chainId, txHash) {
|
|
|
172611
172671
|
return void 0;
|
|
172612
172672
|
}
|
|
172613
172673
|
}
|
|
172614
|
-
async function describeAccountState(publicClient,
|
|
172674
|
+
async function describeAccountState(publicClient, payer2, chainId, requiredAmount) {
|
|
172615
172675
|
const lines = [];
|
|
172616
172676
|
try {
|
|
172617
|
-
const eth = await publicClient.getBalance({ address:
|
|
172677
|
+
const eth = await publicClient.getBalance({ address: payer2 });
|
|
172618
172678
|
lines.push(` native: ${formatEther2(eth)} ETH`);
|
|
172619
172679
|
} catch (err) {
|
|
172620
172680
|
logger.warn(`diagnostics: failed to read native balance: ${String(err)}`);
|
|
@@ -172626,7 +172686,7 @@ async function describeAccountState(publicClient, payer, chainId, requiredAmount
|
|
|
172626
172686
|
address: usdcEntry.address,
|
|
172627
172687
|
abi: erc20Abi,
|
|
172628
172688
|
functionName: "balanceOf",
|
|
172629
|
-
args: [
|
|
172689
|
+
args: [payer2]
|
|
172630
172690
|
});
|
|
172631
172691
|
let line = ` USDC: ${formatUnits(usdc, 6)} USDC (${usdc} units)`;
|
|
172632
172692
|
if (requiredAmount !== void 0) {
|
|
@@ -172650,7 +172710,11 @@ var transferUsdcSchema = external_exports.object({
|
|
|
172650
172710
|
).describe(
|
|
172651
172711
|
'amount of USDC as a human-readable decimal (e.g. "1.5" = 1.5 USDC), NOT base units.'
|
|
172652
172712
|
),
|
|
172653
|
-
missionRunId: external_exports.string().uuid().optional().describe("
|
|
172713
|
+
missionRunId: external_exports.string().uuid().optional().describe("Not here: a transfer of a mission run goes through transfer_usdc_in_mission")
|
|
172714
|
+
});
|
|
172715
|
+
var TRANSFER_USDC_IN_MISSION = "transfer_usdc_in_mission";
|
|
172716
|
+
var transferUsdcInMissionSchema = transferUsdcSchema.extend({
|
|
172717
|
+
missionRunId: external_exports.string().uuid().describe("The mission run this transfer belongs to: the run id from request_mission_trial or start_mission_run")
|
|
172654
172718
|
});
|
|
172655
172719
|
function heldForUser(approval, input) {
|
|
172656
172720
|
return [
|
|
@@ -172703,101 +172767,126 @@ function transferHold(intentId, input, amount2) {
|
|
|
172703
172767
|
refuse: (state2) => refusal2(intentId, state2, input)
|
|
172704
172768
|
};
|
|
172705
172769
|
}
|
|
172770
|
+
var TRANSFER_ANNOTATIONS = {
|
|
172771
|
+
// Moves value on-chain: irreversible once settled, and never idempotent
|
|
172772
|
+
// (calling it twice sends twice).
|
|
172773
|
+
readOnlyHint: false,
|
|
172774
|
+
destructiveHint: true,
|
|
172775
|
+
idempotentHint: false,
|
|
172776
|
+
openWorldHint: true
|
|
172777
|
+
};
|
|
172778
|
+
function sender(session) {
|
|
172779
|
+
return async (input) => {
|
|
172780
|
+
const init = await ensureAccount(session);
|
|
172781
|
+
const { account, signer, frostVerifierAddress } = init;
|
|
172782
|
+
const chain2 = CHAIN_MAP[session.network];
|
|
172783
|
+
if (!chain2) {
|
|
172784
|
+
throw new Error(
|
|
172785
|
+
`USDC transfer is not supported for network "${session.network}". Supported: ${Object.keys(CHAIN_MAP).join(", ")}`
|
|
172786
|
+
);
|
|
172787
|
+
}
|
|
172788
|
+
const usdc = (0, import_agent_wallet_protocol5.getUsdcChainEntry)(chain2.id);
|
|
172789
|
+
if (!usdc) {
|
|
172790
|
+
throw new Error(
|
|
172791
|
+
`No canonical USDC contract registered for network "${session.network}" (chainId ${chain2.id}).`
|
|
172792
|
+
);
|
|
172793
|
+
}
|
|
172794
|
+
const amount2 = parseUnits(input.value, USDC_DECIMALS4);
|
|
172795
|
+
const data = encodeFunctionData({
|
|
172796
|
+
abi: erc20Abi,
|
|
172797
|
+
functionName: "transfer",
|
|
172798
|
+
args: [getAddress(input.to), amount2]
|
|
172799
|
+
});
|
|
172800
|
+
const send = () => executeRelayedWithIntent(
|
|
172801
|
+
account.publicClient,
|
|
172802
|
+
signer,
|
|
172803
|
+
account.dkgBlob,
|
|
172804
|
+
account.address,
|
|
172805
|
+
usdc.address,
|
|
172806
|
+
0n,
|
|
172807
|
+
account.publicKey,
|
|
172808
|
+
frostVerifierAddress,
|
|
172809
|
+
data,
|
|
172810
|
+
input.missionRunId
|
|
172811
|
+
);
|
|
172812
|
+
let sent;
|
|
172813
|
+
try {
|
|
172814
|
+
sent = await send().catch(async (err) => {
|
|
172815
|
+
if (!(err instanceof RelayHeld)) throw err;
|
|
172816
|
+
await holdPayment(session, transferHold(err.intentId, input, amount2));
|
|
172817
|
+
return send().catch(async (again) => {
|
|
172818
|
+
if (!(again instanceof RelayHeld)) throw again;
|
|
172819
|
+
throw await heldAnswer(session, transferHold(again.intentId, input, amount2));
|
|
172820
|
+
});
|
|
172821
|
+
});
|
|
172822
|
+
} catch (err) {
|
|
172823
|
+
const message = err instanceof Error ? err.message : String(err);
|
|
172824
|
+
if (!/revert/i.test(message)) throw err;
|
|
172825
|
+
const diag = await describeAccountState(
|
|
172826
|
+
account.publicClient,
|
|
172827
|
+
account.address,
|
|
172828
|
+
chain2.id,
|
|
172829
|
+
amount2
|
|
172830
|
+
);
|
|
172831
|
+
throw new Error(
|
|
172832
|
+
diag.length > 0 ? `${message}
|
|
172833
|
+
sender on-chain state (chainId ${chain2.id}):
|
|
172834
|
+
${diag.join("\n")}` : message
|
|
172835
|
+
);
|
|
172836
|
+
}
|
|
172837
|
+
const txHash = sent.txHash;
|
|
172838
|
+
const explorer = explorerTxUrl(chain2.id, txHash);
|
|
172839
|
+
const text5 = [
|
|
172840
|
+
"USDC transfer successful.",
|
|
172841
|
+
`Transaction hash: ${txHash}`,
|
|
172842
|
+
...explorer ? [`Explorer: ${explorer}`] : []
|
|
172843
|
+
].join("\n");
|
|
172844
|
+
if (input.missionRunId) {
|
|
172845
|
+
if (sent.intentId) recordRunPayment(session, input.missionRunId, { intentId: sent.intentId, txHash });
|
|
172846
|
+
else logger.warn(`transfer_usdc: transfer in mission run ${input.missionRunId} has no intent id, not recorded for the run card`);
|
|
172847
|
+
return text5;
|
|
172848
|
+
}
|
|
172849
|
+
if (!session.rendersApps) return text5;
|
|
172850
|
+
const receipt = await paymentCard(session, {
|
|
172851
|
+
intentId: null,
|
|
172852
|
+
state: "consumed",
|
|
172853
|
+
asset: "USDC",
|
|
172854
|
+
amountNative: amount2.toString(),
|
|
172855
|
+
payee: input.to,
|
|
172856
|
+
seller: null,
|
|
172857
|
+
resource: null,
|
|
172858
|
+
expiresAt: null,
|
|
172859
|
+
explorerUrl: explorer ?? null
|
|
172860
|
+
});
|
|
172861
|
+
return { text: text5, structuredContent: receipt };
|
|
172862
|
+
};
|
|
172863
|
+
}
|
|
172706
172864
|
function createTransferUsdcTool(session) {
|
|
172865
|
+
const send = sender(session);
|
|
172707
172866
|
return {
|
|
172708
172867
|
name: "transfer_usdc",
|
|
172709
172868
|
title: "Transfer USDC",
|
|
172710
|
-
|
|
172711
|
-
|
|
172712
|
-
annotations: {
|
|
172713
|
-
readOnlyHint: false,
|
|
172714
|
-
destructiveHint: true,
|
|
172715
|
-
idempotentHint: false,
|
|
172716
|
-
openWorldHint: true
|
|
172717
|
-
},
|
|
172718
|
-
description: "Transfer USDC (ERC-20) from the wallet the user provisioned for this agent to an address. Call it when the user asks for a transfer: the wallet policy they set is the safeguard. Routes through the SchnorrAccount relay as a `transfer(to,amount)` call, so the same wallet policy applies as for a native transfer (caps, allow-list, require_human). Requires a network with a canonical USDC contract (BaseSepolia, BaseMainnet, XdcApothem, XdcMainnet). When the policy holds the transfer for a wallet operator's approval, the answer says so and what to do next, and is not an error; in clients that render MCP apps the call waits for the decision while the user approves from a card.",
|
|
172869
|
+
annotations: TRANSFER_ANNOTATIONS,
|
|
172870
|
+
description: `Transfer USDC (ERC-20) from the wallet the user provisioned for this agent to an address. Call it when the user asks for a transfer: the wallet policy they set is the safeguard. Routes through the SchnorrAccount relay as a \`transfer(to,amount)\` call, so the same wallet policy applies as for a native transfer (caps, allow-list, require_human). Requires a network with a canonical USDC contract (BaseSepolia, BaseMainnet, XdcApothem, XdcMainnet). When the policy holds the transfer for a wallet operator's approval, the answer says so and what to do next, and is not an error; in clients that render MCP apps the call waits for the decision while the user approves from a card. Not for a transfer of a mission run: use ${TRANSFER_USDC_IN_MISSION}.`,
|
|
172719
172871
|
inputSchema: transferUsdcSchema,
|
|
172720
172872
|
ui: { resourceUri: PAYMENT_CARD_URI },
|
|
172721
172873
|
handler: async (input) => {
|
|
172722
|
-
|
|
172723
|
-
|
|
172724
|
-
const chain2 = CHAIN_MAP[session.network];
|
|
172725
|
-
if (!chain2) {
|
|
172726
|
-
throw new Error(
|
|
172727
|
-
`USDC transfer is not supported for network "${session.network}". Supported: ${Object.keys(CHAIN_MAP).join(", ")}`
|
|
172728
|
-
);
|
|
172729
|
-
}
|
|
172730
|
-
const usdc = (0, import_agent_wallet_protocol5.getUsdcChainEntry)(chain2.id);
|
|
172731
|
-
if (!usdc) {
|
|
172732
|
-
throw new Error(
|
|
172733
|
-
`No canonical USDC contract registered for network "${session.network}" (chainId ${chain2.id}).`
|
|
172734
|
-
);
|
|
172735
|
-
}
|
|
172736
|
-
const amount2 = parseUnits(input.value, USDC_DECIMALS4);
|
|
172737
|
-
const data = encodeFunctionData({
|
|
172738
|
-
abi: erc20Abi,
|
|
172739
|
-
functionName: "transfer",
|
|
172740
|
-
args: [getAddress(input.to), amount2]
|
|
172741
|
-
});
|
|
172742
|
-
const send = () => executeRelayed(
|
|
172743
|
-
account.publicClient,
|
|
172744
|
-
signer,
|
|
172745
|
-
account.dkgBlob,
|
|
172746
|
-
account.address,
|
|
172747
|
-
usdc.address,
|
|
172748
|
-
0n,
|
|
172749
|
-
account.publicKey,
|
|
172750
|
-
frostVerifierAddress,
|
|
172751
|
-
data,
|
|
172752
|
-
input.missionRunId
|
|
172753
|
-
);
|
|
172754
|
-
let txHash;
|
|
172755
|
-
try {
|
|
172756
|
-
txHash = await send().catch(async (err) => {
|
|
172757
|
-
if (!(err instanceof RelayHeld)) throw err;
|
|
172758
|
-
await holdPayment(session, transferHold(err.intentId, input, amount2));
|
|
172759
|
-
return send().catch(async (again) => {
|
|
172760
|
-
if (!(again instanceof RelayHeld)) throw again;
|
|
172761
|
-
throw await heldAnswer(session, transferHold(again.intentId, input, amount2));
|
|
172762
|
-
});
|
|
172763
|
-
});
|
|
172764
|
-
} catch (err) {
|
|
172765
|
-
const message = err instanceof Error ? err.message : String(err);
|
|
172766
|
-
if (!/revert/i.test(message)) throw err;
|
|
172767
|
-
const diag = await describeAccountState(
|
|
172768
|
-
account.publicClient,
|
|
172769
|
-
account.address,
|
|
172770
|
-
chain2.id,
|
|
172771
|
-
amount2
|
|
172772
|
-
);
|
|
172773
|
-
throw new Error(
|
|
172774
|
-
diag.length > 0 ? `${message}
|
|
172775
|
-
sender on-chain state (chainId ${chain2.id}):
|
|
172776
|
-
${diag.join("\n")}` : message
|
|
172777
|
-
);
|
|
172778
|
-
}
|
|
172779
|
-
const explorer = explorerTxUrl(chain2.id, txHash);
|
|
172780
|
-
const text4 = [
|
|
172781
|
-
"USDC transfer successful.",
|
|
172782
|
-
`Transaction hash: ${txHash}`,
|
|
172783
|
-
...explorer ? [`Explorer: ${explorer}`] : []
|
|
172784
|
-
].join("\n");
|
|
172785
|
-
if (!session.rendersApps) return text4;
|
|
172786
|
-
const receipt = await paymentCard(session, {
|
|
172787
|
-
intentId: null,
|
|
172788
|
-
state: "consumed",
|
|
172789
|
-
asset: "USDC",
|
|
172790
|
-
amountNative: amount2.toString(),
|
|
172791
|
-
payee: input.to,
|
|
172792
|
-
seller: null,
|
|
172793
|
-
resource: null,
|
|
172794
|
-
expiresAt: null,
|
|
172795
|
-
explorerUrl: explorer ?? null
|
|
172796
|
-
});
|
|
172797
|
-
return { text: text4, structuredContent: receipt };
|
|
172874
|
+
refuseMissionPayment(input.missionRunId, TRANSFER_USDC_IN_MISSION);
|
|
172875
|
+
return send(input);
|
|
172798
172876
|
}
|
|
172799
172877
|
};
|
|
172800
172878
|
}
|
|
172879
|
+
function createTransferUsdcInMissionTool(session) {
|
|
172880
|
+
const send = sender(cardlessSession(session));
|
|
172881
|
+
return {
|
|
172882
|
+
name: TRANSFER_USDC_IN_MISSION,
|
|
172883
|
+
title: "Transfer USDC in a mission run",
|
|
172884
|
+
annotations: TRANSFER_ANNOTATIONS,
|
|
172885
|
+
description: "transfer_usdc for a transfer of a mission run (missionRunId required), once the run is active. Same transfer, same policy, same answers, but no card is shown: the run card tells the user what was spent. When the transfer is held for approval, the answer gives the approval link in text and the next steps: tell the user, call wait_for_intent, then call this tool again with the same recipient, amount and missionRunId.",
|
|
172886
|
+
inputSchema: transferUsdcInMissionSchema,
|
|
172887
|
+
handler: async (input) => answerInMission(() => send(input), "transfer_usdc", TRANSFER_USDC_IN_MISSION, input.missionRunId)
|
|
172888
|
+
};
|
|
172889
|
+
}
|
|
172801
172890
|
|
|
172802
172891
|
// src/tools/balance.ts
|
|
172803
172892
|
init_zod();
|
|
@@ -173415,7 +173504,11 @@ var x402PaySchema = external_exports.object({
|
|
|
173415
173504
|
intentId: external_exports.string().optional().describe(
|
|
173416
173505
|
"Resume a specific payment that already exists \u2014 pass the intentId the tool returned when it asked for human approval, to sign and settle that exact intent once approved. Omit it to start a new payment. Concurrent payments to the same URL each have their own intentId."
|
|
173417
173506
|
),
|
|
173418
|
-
missionRunId: external_exports.string().uuid().optional().describe("
|
|
173507
|
+
missionRunId: external_exports.string().uuid().optional().describe("Not here: a payment of a mission run goes through x402_pay_in_mission")
|
|
173508
|
+
});
|
|
173509
|
+
var X402_PAY_IN_MISSION = "x402_pay_in_mission";
|
|
173510
|
+
var x402PayInMissionSchema = x402PaySchema.extend({
|
|
173511
|
+
missionRunId: external_exports.string().uuid().describe("The mission run this payment belongs to: the run id from request_mission_trial or start_mission_run")
|
|
173419
173512
|
});
|
|
173420
173513
|
function readSettleResponse(response) {
|
|
173421
173514
|
const header = response.headers.get("payment-response") ?? response.headers.get("x-payment-response");
|
|
@@ -173426,6 +173519,8 @@ function readSettleResponse(response) {
|
|
|
173426
173519
|
return void 0;
|
|
173427
173520
|
}
|
|
173428
173521
|
}
|
|
173522
|
+
var TX_HASH = /^0x[0-9a-fA-F]{64}$/;
|
|
173523
|
+
var settledTxHash = (settle) => settle?.transaction && TX_HASH.test(settle.transaction) ? settle.transaction : null;
|
|
173429
173524
|
function readChallengeError(response) {
|
|
173430
173525
|
const header = response.headers.get("payment-required") ?? response.headers.get("x-payment-required");
|
|
173431
173526
|
if (!header) return void 0;
|
|
@@ -173496,6 +173591,7 @@ function paymentHold(session, intentId, url2, auth2, resumed) {
|
|
|
173496
173591
|
refuse: (state2) => {
|
|
173497
173592
|
session.pendingX402.delete(intentId);
|
|
173498
173593
|
session.signedX402.delete(intentId);
|
|
173594
|
+
session.intentRuns.delete(intentId);
|
|
173499
173595
|
return new Error(
|
|
173500
173596
|
`Payment ${intentId} is ${state2}: no wallet operator approved it, nothing was signed or paid. Tell the user; start a fresh x402_pay for ${url2} only if they ask for it again.`
|
|
173501
173597
|
);
|
|
@@ -173503,7 +173599,7 @@ function paymentHold(session, intentId, url2, auth2, resumed) {
|
|
|
173503
173599
|
};
|
|
173504
173600
|
}
|
|
173505
173601
|
var PREPAID_DESCRIPTION2 = "Fetch an x402-protected HTTP resource, automatically handling payment. You provide the resource URL (and optionally a max spend in USDC); the Keyban backend resolves the payment from the URL \u2014 it gates the URL host against the account's domain allow-list, fetches the seller to read its recipient and price, and prices it in euros. Keyban signs and pays it from the organization's prepaid credit: this account holds no funds and no key. The tool settles by sending the X-PAYMENT request. If the backend policy requires human approval, the tool FAILS with the intentId \u2014 call wait_for_intent (no arguments; it wakes when any pending approval is decided), then retry x402_pay for the same URL passing that intentId once it reports approved. Concurrent payments to the same URL each get their own intent. Returns the response body. Requires prepaid credit: when the credit does not cover the price, the policy refuses with policy/prepaid-balance-insufficient \u2014 tell the user an admin must buy a pack in Billing \u2192 Prepaid credit of the Keyban dashboard; never retry or split the payment. Call it directly, without asking the user to confirm the spend: the account's own policy is the authorization \u2014 every payment is gated server-side on the per-transaction cap, the human-approval threshold and the domain allow-list, so a payment this tool settles is a payment the policy already allowed. When the policy refuses one, report the reason it gives and carry on with an approved provider.";
|
|
173506
|
-
function
|
|
173602
|
+
function payer(session) {
|
|
173507
173603
|
const pay = async (input, { sponsor }) => {
|
|
173508
173604
|
const refused = bodyRefusedBy(input.method, input.body);
|
|
173509
173605
|
if (refused) return refused;
|
|
@@ -173514,14 +173610,17 @@ function createX402PayTool(session) {
|
|
|
173514
173610
|
let auth2;
|
|
173515
173611
|
let decision;
|
|
173516
173612
|
let intentId = input.intentId;
|
|
173613
|
+
const missionRunId = input.missionRunId ?? (intentId ? session.intentRuns.get(intentId) : void 0);
|
|
173517
173614
|
if (intentId) {
|
|
173518
173615
|
auth2 = session.pendingX402.get(intentId);
|
|
173519
173616
|
if (auth2 && Number(auth2.authorization.validBefore) <= nowSec) {
|
|
173520
173617
|
session.pendingX402.delete(intentId);
|
|
173521
173618
|
session.signedX402.delete(intentId);
|
|
173619
|
+
session.intentRuns.delete(intentId);
|
|
173522
173620
|
auth2 = void 0;
|
|
173523
173621
|
}
|
|
173524
173622
|
if (!auth2) {
|
|
173623
|
+
session.intentRuns.delete(intentId);
|
|
173525
173624
|
throw new Error(
|
|
173526
173625
|
`No live payment envelope for intent ${intentId} \u2014 its approval window may have lapsed. Start a fresh x402_pay for ${input.url}.`
|
|
173527
173626
|
);
|
|
@@ -173564,6 +173663,7 @@ function createX402PayTool(session) {
|
|
|
173564
173663
|
);
|
|
173565
173664
|
}
|
|
173566
173665
|
if (intentId) session.pendingX402.set(intentId, auth2);
|
|
173666
|
+
if (intentId && input.missionRunId) session.intentRuns.set(intentId, input.missionRunId);
|
|
173567
173667
|
if (decision.decision === "require_human" && prepaid) {
|
|
173568
173668
|
throw new Error(
|
|
173569
173669
|
heldPaymentLines({
|
|
@@ -173595,6 +173695,7 @@ function createX402PayTool(session) {
|
|
|
173595
173695
|
if (intentId) {
|
|
173596
173696
|
session.pendingX402.delete(intentId);
|
|
173597
173697
|
session.signedX402.delete(intentId);
|
|
173698
|
+
session.intentRuns.delete(intentId);
|
|
173598
173699
|
}
|
|
173599
173700
|
throw err;
|
|
173600
173701
|
}
|
|
@@ -173646,6 +173747,7 @@ To retry this exact payment, call x402_pay for ${input.url} with intentId=${inte
|
|
|
173646
173747
|
if (intentId) {
|
|
173647
173748
|
session.pendingX402.delete(intentId);
|
|
173648
173749
|
session.signedX402.delete(intentId);
|
|
173750
|
+
session.intentRuns.delete(intentId);
|
|
173649
173751
|
}
|
|
173650
173752
|
logger.info("x402_pay: nonce already spent \u2014 the payment had settled");
|
|
173651
173753
|
return [
|
|
@@ -173697,10 +173799,10 @@ To retry this exact payment, call x402_pay for ${input.url} with intentId=${inte
|
|
|
173697
173799
|
parts.push(`extensions: ${JSON.stringify(settle.extensions)}`);
|
|
173698
173800
|
}
|
|
173699
173801
|
if (ctx.publicClient && ctx.accountAddress) {
|
|
173700
|
-
const
|
|
173802
|
+
const payer2 = settle.payer ?? auth2.authorization.from ?? ctx.accountAddress;
|
|
173701
173803
|
const diag = await describeAccountState(
|
|
173702
173804
|
ctx.publicClient,
|
|
173703
|
-
|
|
173805
|
+
payer2,
|
|
173704
173806
|
chainId,
|
|
173705
173807
|
BigInt(auth2.authorization.value)
|
|
173706
173808
|
);
|
|
@@ -173738,8 +173840,9 @@ ${headerDump}`);
|
|
|
173738
173840
|
let paymentInfo = "";
|
|
173739
173841
|
settle = readSettleResponse(response);
|
|
173740
173842
|
if (settle) {
|
|
173741
|
-
|
|
173742
|
-
|
|
173843
|
+
const hash3 = settledTxHash(settle);
|
|
173844
|
+
paymentInfo = hash3 ? `
|
|
173845
|
+
Payment tx: ${hash3}` : "\nPayment tx: (hash not readable)";
|
|
173743
173846
|
}
|
|
173744
173847
|
if (prepaid) {
|
|
173745
173848
|
paymentInfo += `
|
|
@@ -173750,10 +173853,19 @@ ${paidByKeybanLine({
|
|
|
173750
173853
|
} else if (signedBy === "server") {
|
|
173751
173854
|
paymentInfo += "\nCovered by the Keyban welcome offer: nothing was taken from the wallet.";
|
|
173752
173855
|
}
|
|
173753
|
-
const
|
|
173856
|
+
const text5 = `${response.status} ${response.statusText}${paymentInfo}
|
|
173754
173857
|
|
|
173755
173858
|
${responseBody}`;
|
|
173756
|
-
if (
|
|
173859
|
+
if (missionRunId) {
|
|
173860
|
+
if (intentId) {
|
|
173861
|
+
session.intentRuns.delete(intentId);
|
|
173862
|
+
recordRunPayment(session, missionRunId, { intentId, txHash: settledTxHash(settle) });
|
|
173863
|
+
} else {
|
|
173864
|
+
logger.warn(`x402_pay: payment in mission run ${missionRunId} has no intent id, not recorded for the run card`);
|
|
173865
|
+
}
|
|
173866
|
+
return text5;
|
|
173867
|
+
}
|
|
173868
|
+
if (prepaid || !session.rendersApps) return text5;
|
|
173757
173869
|
const receipt = await paymentCard(session, {
|
|
173758
173870
|
intentId: intentId ?? null,
|
|
173759
173871
|
state: "consumed",
|
|
@@ -173763,29 +173875,52 @@ ${responseBody}`;
|
|
|
173763
173875
|
seller: new URL(input.url).host,
|
|
173764
173876
|
resource: input.url,
|
|
173765
173877
|
expiresAt: null,
|
|
173766
|
-
explorerUrl:
|
|
173878
|
+
explorerUrl: ((hash3) => hash3 ? explorerTxUrl(chainId, hash3) ?? null : null)(settledTxHash(settle))
|
|
173767
173879
|
});
|
|
173768
|
-
return { text:
|
|
173880
|
+
return { text: text5, structuredContent: receipt };
|
|
173769
173881
|
};
|
|
173882
|
+
return (input) => withFundingFallback(pay, input, session.funding);
|
|
173883
|
+
}
|
|
173884
|
+
var PAY_ANNOTATIONS = {
|
|
173885
|
+
// Spends real money against a third-party seller: irreversible, not
|
|
173886
|
+
// idempotent, and it reaches outside our own systems.
|
|
173887
|
+
readOnlyHint: false,
|
|
173888
|
+
destructiveHint: true,
|
|
173889
|
+
idempotentHint: false,
|
|
173890
|
+
openWorldHint: true
|
|
173891
|
+
};
|
|
173892
|
+
function createX402PayTool(session) {
|
|
173893
|
+
const pay = payer(session);
|
|
173894
|
+
const withCard2 = session.funding !== "prepaid";
|
|
173770
173895
|
return {
|
|
173771
173896
|
name: "x402_pay",
|
|
173772
173897
|
title: "Pay for an x402 resource",
|
|
173773
|
-
|
|
173774
|
-
|
|
173775
|
-
annotations: {
|
|
173776
|
-
readOnlyHint: false,
|
|
173777
|
-
destructiveHint: true,
|
|
173778
|
-
idempotentHint: false,
|
|
173779
|
-
openWorldHint: true
|
|
173780
|
-
},
|
|
173781
|
-
description: session.funding === "prepaid" ? PREPAID_DESCRIPTION2 : "Fetch an x402-protected HTTP resource, automatically handling payment. You provide the resource URL (and optionally a max spend); the Keyban backend resolves the payment from the URL \u2014 it gates the URL host against the wallet's domain allow-list, fetches the seller to read its recipient and price, and returns a signed-ready EIP-3009 envelope. The tool then signs it with the wallet's TSS Schnorr key (ERC-7739 + ERC-1271) \u2014 or, when the Keyban welcome offer covers the payment, has the Keyban sponsor wallet sign it (the wallet is not debited) \u2014 and settles by sending the X-PAYMENT request. When the policy holds the payment for a wallet operator's approval, the answer says so and is not an error: in clients that render MCP apps the call itself waits for the decision while the user approves from a card, then signs and settles; elsewhere it gives the approval link and the next steps (wait_for_intent, then x402_pay again with the intentId). Follow what the answer says. Concurrent payments to the same URL each get their own intent. Returns the response body. Requires USDC balance, unless the Keyban welcome offer covers the payment. Call it directly, without asking the user to confirm the spend: the wallet's own policy is the authorization \u2014 every payment is gated server-side on the per-transaction cap, the human-approval threshold and the domain allow-list, so a payment this tool settles is a payment the policy already allowed. When the policy refuses one, report the reason it gives and carry on with an approved provider.",
|
|
173898
|
+
annotations: PAY_ANNOTATIONS,
|
|
173899
|
+
description: session.funding === "prepaid" ? PREPAID_DESCRIPTION2 : `Fetch an x402-protected HTTP resource, automatically handling payment. You provide the resource URL (and optionally a max spend); the Keyban backend resolves the payment from the URL \u2014 it gates the URL host against the wallet's domain allow-list, fetches the seller to read its recipient and price, and returns a signed-ready EIP-3009 envelope. The tool then signs it with the wallet's TSS Schnorr key (ERC-7739 + ERC-1271) \u2014 or, when the Keyban welcome offer covers the payment, has the Keyban sponsor wallet sign it (the wallet is not debited) \u2014 and settles by sending the X-PAYMENT request. When the policy holds the payment for a wallet operator's approval, the answer says so and is not an error: in clients that render MCP apps the call itself waits for the decision while the user approves from a card, then signs and settles; elsewhere it gives the approval link and the next steps (wait_for_intent, then x402_pay again with the intentId). Follow what the answer says. Concurrent payments to the same URL each get their own intent. Returns the response body. Requires USDC balance, unless the Keyban welcome offer covers the payment. Call it directly, without asking the user to confirm the spend: the wallet's own policy is the authorization \u2014 every payment is gated server-side on the per-transaction cap, the human-approval threshold and the domain allow-list, so a payment this tool settles is a payment the policy already allowed. When the policy refuses one, report the reason it gives and carry on with an approved provider. Not for a payment of a mission run: use ${X402_PAY_IN_MISSION}.`,
|
|
173782
173900
|
inputSchema: x402PaySchema,
|
|
173783
|
-
...
|
|
173901
|
+
...withCard2 ? { ui: { resourceUri: PAYMENT_CARD_URI } } : {},
|
|
173784
173902
|
handler: async (input) => {
|
|
173785
|
-
|
|
173903
|
+
if (withCard2) {
|
|
173904
|
+
refuseMissionPayment(
|
|
173905
|
+
input.missionRunId ?? (input.intentId ? session.intentRuns.get(input.intentId) : void 0),
|
|
173906
|
+
X402_PAY_IN_MISSION
|
|
173907
|
+
);
|
|
173908
|
+
}
|
|
173909
|
+
return pay(input);
|
|
173786
173910
|
}
|
|
173787
173911
|
};
|
|
173788
173912
|
}
|
|
173913
|
+
function createX402PayInMissionTool(session) {
|
|
173914
|
+
const pay = payer(cardlessSession(session));
|
|
173915
|
+
return {
|
|
173916
|
+
name: X402_PAY_IN_MISSION,
|
|
173917
|
+
title: "Pay for an x402 resource in a mission run",
|
|
173918
|
+
annotations: PAY_ANNOTATIONS,
|
|
173919
|
+
description: "x402_pay for a payment of a mission run (missionRunId required), once the run is active. Same payment, same policy, same answers, but no card is shown: the run card tells the user what was spent. When the payment is held for approval, the answer gives the approval link in text and the next steps: tell the user, call wait_for_intent, then call this tool again with the intentId and the same missionRunId. Call it directly, without asking the user to confirm each payment: the approved run and the wallet policy are the authorization.",
|
|
173920
|
+
inputSchema: x402PayInMissionSchema,
|
|
173921
|
+
handler: async (input) => answerInMission(() => pay(input), "x402_pay", X402_PAY_IN_MISSION, input.missionRunId)
|
|
173922
|
+
};
|
|
173923
|
+
}
|
|
173789
173924
|
|
|
173790
173925
|
// src/tools/x402-info.ts
|
|
173791
173926
|
init_zod();
|
|
@@ -174320,8 +174455,8 @@ function fieldLines(section, location) {
|
|
|
174320
174455
|
const type = typeof rawType === "string" ? rawType : "any";
|
|
174321
174456
|
const flags = [type, requiredSet.has(name) ? "required" : null, location ?? null].filter((flag) => flag !== null).join(", ");
|
|
174322
174457
|
const description = at(spec, ["description"]);
|
|
174323
|
-
const
|
|
174324
|
-
return ` - ${name} (${flags})${
|
|
174458
|
+
const text5 = typeof description === "string" ? `: ${description.slice(0, MAX_DESCRIPTION)}` : "";
|
|
174459
|
+
return ` - ${name} (${flags})${text5}`;
|
|
174325
174460
|
});
|
|
174326
174461
|
}
|
|
174327
174462
|
function examplePathLines(examples) {
|
|
@@ -174550,6 +174685,7 @@ function createCancelIntentTool(session) {
|
|
|
174550
174685
|
case "released":
|
|
174551
174686
|
session.pendingX402.delete(input.intentId);
|
|
174552
174687
|
session.signedX402.delete(input.intentId);
|
|
174688
|
+
session.intentRuns.delete(input.intentId);
|
|
174553
174689
|
return `Intent ${result.intentId} was signed but its payment never settled and no longer can: nothing was charged and its budget is released (state: failed). You can start a new payment.`;
|
|
174554
174690
|
case "settled":
|
|
174555
174691
|
return `Intent ${result.intentId} cannot be cancelled: its payment settled on-chain, so the charge stands. Call list_expense_transactions to see it.`;
|
|
@@ -174560,6 +174696,7 @@ function createCancelIntentTool(session) {
|
|
|
174560
174696
|
}
|
|
174561
174697
|
session.pendingX402.delete(input.intentId);
|
|
174562
174698
|
session.signedX402.delete(input.intentId);
|
|
174699
|
+
session.intentRuns.delete(input.intentId);
|
|
174563
174700
|
return `Intent ${result.intentId} cancelled (state: ${result.state}). The wallet is no longer blocked by an in-flight intent \u2014 you can start a new payment.`;
|
|
174564
174701
|
}
|
|
174565
174702
|
};
|
|
@@ -174567,9 +174704,10 @@ function createCancelIntentTool(session) {
|
|
|
174567
174704
|
|
|
174568
174705
|
// src/tools/wait-for-intent.ts
|
|
174569
174706
|
init_zod();
|
|
174707
|
+
var WAIT_FOR_INTENT_MS = 45e3;
|
|
174570
174708
|
var waitForIntentSchema = external_exports.object({
|
|
174571
|
-
timeoutMs: external_exports.number().int().positive().optional().default(
|
|
174572
|
-
"How long to block before returning still-waiting (default
|
|
174709
|
+
timeoutMs: external_exports.number().int().positive().max(WAIT_FOR_INTENT_MS).optional().default(WAIT_FOR_INTENT_MS).describe(
|
|
174710
|
+
"How long to block before returning still-waiting (default and maximum 45 s). Call wait_for_intent again to keep waiting if it returns while intents are still awaiting approval."
|
|
174573
174711
|
)
|
|
174574
174712
|
});
|
|
174575
174713
|
var isTimeoutErr = (err) => err instanceof Error && (err.name === "TimeoutError" || err.name === "AbortError");
|
|
@@ -174583,12 +174721,12 @@ function nothingToApprove(recentlyDecided) {
|
|
|
174583
174721
|
summary: decided ? `No intents are awaiting approval. Decided recently: ${decided}.` : "No intents are awaiting approval \u2014 nothing to wait for."
|
|
174584
174722
|
};
|
|
174585
174723
|
}
|
|
174586
|
-
function decidedResult(
|
|
174724
|
+
function decidedResult(changed2, pendingToApprove) {
|
|
174587
174725
|
const rest = pendingToApprove.length ? `${pendingToApprove.length} intent(s) still awaiting approval.` : "No other intents are awaiting approval.";
|
|
174588
174726
|
return {
|
|
174589
|
-
changed,
|
|
174727
|
+
changed: changed2,
|
|
174590
174728
|
pendingToApprove,
|
|
174591
|
-
summary: `Intent ${
|
|
174729
|
+
summary: `Intent ${changed2.intentId} is now ${changed2.state}. ${rest}`
|
|
174592
174730
|
};
|
|
174593
174731
|
}
|
|
174594
174732
|
function timeoutResult(pending, timeoutMs) {
|
|
@@ -174643,7 +174781,7 @@ function createWaitForIntentTool(session) {
|
|
|
174643
174781
|
name: "wait_for_intent",
|
|
174644
174782
|
title: "Wait for approval decisions",
|
|
174645
174783
|
annotations: { readOnlyHint: true, openWorldHint: false },
|
|
174646
|
-
description: "Block until something happens to the wallet's human-approval queue, then return the current picture. Takes no target: it watches ALL of the wallet's intents at once. Call it after a require_human response (from x402_pay or a relay transfer), and whenever you have payments awaiting approval \u2014 it returns as soon as either (a) nothing is awaiting approval, or (b) an intent that WAS awaiting approval is decided (approved / declined / expired / abandoned). The result is JSON: `changed` (the full state of the intent that just changed, or null) and `pendingToApprove` (every intent still awaiting a decision); when nothing awaits approval, `recentlyDecided` gives the intents decided in the last minutes, so a call made after a wallet operator decided still tells the outcome. Loop it: wait, act on `changed` (retry x402_pay / transfer for an approved intent), wait again \u2014 in whatever order the wallet operators approve them.
|
|
174784
|
+
description: "Block until something happens to the wallet's human-approval queue, then return the current picture. Takes no target: it watches ALL of the wallet's intents at once. Call it after a require_human response (from x402_pay or a relay transfer), and whenever you have payments awaiting approval \u2014 it returns as soon as either (a) nothing is awaiting approval, or (b) an intent that WAS awaiting approval is decided (approved / declined / expired / abandoned). The result is JSON: `changed` (the full state of the intent that just changed, or null) and `pendingToApprove` (every intent still awaiting a decision); when nothing awaits approval, `recentlyDecided` gives the intents decided in the last minutes, so a call made after a wallet operator decided still tells the outcome. Loop it: wait, act on `changed` (retry x402_pay / transfer for an approved intent), wait again \u2014 in whatever order the wallet operators approve them. Blocks at most 45 s: it returns still-waiting on timeout, so call it again to keep waiting.",
|
|
174647
174785
|
inputSchema: waitForIntentSchema,
|
|
174648
174786
|
handler: async (input) => {
|
|
174649
174787
|
requireCredentials(session);
|
|
@@ -174784,8 +174922,8 @@ var discoverX402ServicesSchema = external_exports.object({
|
|
|
174784
174922
|
limit: external_exports.number().int().positive().max(50).optional().default(10).describe("Max number of services to return (default 10, max 50).")
|
|
174785
174923
|
});
|
|
174786
174924
|
var MAX_HINT_CHARS = 300;
|
|
174787
|
-
function truncate(
|
|
174788
|
-
return
|
|
174925
|
+
function truncate(text5) {
|
|
174926
|
+
return text5.length <= MAX_HINT_CHARS ? text5 : `${text5.slice(0, MAX_HINT_CHARS)}\u2026 (truncated, ${text5.length} chars)`;
|
|
174789
174927
|
}
|
|
174790
174928
|
var isRecord3 = (value) => typeof value === "object" && value !== null && !Array.isArray(value);
|
|
174791
174929
|
function exampleEntries(params) {
|
|
@@ -175119,7 +175257,7 @@ async function fetchMissionRun(session, runId) {
|
|
|
175119
175257
|
// src/lib/mission-card.ts
|
|
175120
175258
|
var record3 = (v) => typeof v === "object" && v !== null && !Array.isArray(v) ? v : null;
|
|
175121
175259
|
var text3 = (v) => typeof v === "string" ? v : null;
|
|
175122
|
-
var count = (v) => typeof v === "number" ? v : null;
|
|
175260
|
+
var count = (v) => typeof v === "number" && Number.isInteger(v) ? v : null;
|
|
175123
175261
|
var amount = (v) => typeof v === "string" ? v : typeof v === "number" ? String(v) : null;
|
|
175124
175262
|
function frequencyOf(v) {
|
|
175125
175263
|
const frequency = record3(v);
|
|
@@ -175127,14 +175265,62 @@ function frequencyOf(v) {
|
|
|
175127
175265
|
const period = text3(frequency?.period);
|
|
175128
175266
|
return times !== null && period !== null ? { count: times, period } : null;
|
|
175129
175267
|
}
|
|
175268
|
+
var records = (v) => Array.isArray(v) ? v.flatMap((item) => {
|
|
175269
|
+
const found = record3(item);
|
|
175270
|
+
return found ? [found] : [];
|
|
175271
|
+
}) : [];
|
|
175272
|
+
function sourcesOf(v) {
|
|
175273
|
+
if (!Array.isArray(v)) return null;
|
|
175274
|
+
return records(v).flatMap((source) => {
|
|
175275
|
+
const endpoint = text3(source.endpoint);
|
|
175276
|
+
return endpoint === null ? [] : [{ endpoint, label: text3(source.label), callsPerUnit: count(source.callsPerUnit), callPriceRef: amount(source.callPriceRef) }];
|
|
175277
|
+
});
|
|
175278
|
+
}
|
|
175279
|
+
function usageOf(v, txUrls) {
|
|
175280
|
+
if (!Array.isArray(v)) return null;
|
|
175281
|
+
return records(v).flatMap((usage) => {
|
|
175282
|
+
const [source] = sourcesOf([usage]) ?? [];
|
|
175283
|
+
if (!source) return [];
|
|
175284
|
+
const intentIds = Array.isArray(usage.intentIds) ? usage.intentIds.filter((id) => typeof id === "string") : [];
|
|
175285
|
+
return [{
|
|
175286
|
+
...source,
|
|
175287
|
+
calls: count(usage.calls) ?? 0,
|
|
175288
|
+
paidRef: amount(usage.paidRef) ?? "0",
|
|
175289
|
+
paidNative: amount(usage.paidNative),
|
|
175290
|
+
asset: text3(usage.asset),
|
|
175291
|
+
txUrls: intentIds.flatMap(txUrls)
|
|
175292
|
+
}];
|
|
175293
|
+
});
|
|
175294
|
+
}
|
|
175295
|
+
var NOTHING_TO_SHOW = {
|
|
175296
|
+
otherPayments: null,
|
|
175297
|
+
runKind: null,
|
|
175298
|
+
publish: "none",
|
|
175299
|
+
blocker: null,
|
|
175300
|
+
versionUnitCount: null,
|
|
175301
|
+
diff: null,
|
|
175302
|
+
reference: null,
|
|
175303
|
+
recalibratedUnitPriceRef: null,
|
|
175304
|
+
recalibratedEnvelopeRef: null
|
|
175305
|
+
};
|
|
175306
|
+
var NOTHING_SPENT = {
|
|
175307
|
+
spentRef: null,
|
|
175308
|
+
spentCents: null,
|
|
175309
|
+
spentNative: null,
|
|
175310
|
+
spentAsset: null,
|
|
175311
|
+
payments: null,
|
|
175312
|
+
unitsDone: null
|
|
175313
|
+
};
|
|
175130
175314
|
function economics(source) {
|
|
175131
175315
|
return {
|
|
175132
175316
|
currency: text3(source.currency) ?? "",
|
|
175133
175317
|
unitLabel: text3(source.unitLabel),
|
|
175134
175318
|
unitPriceRef: amount(source.unitPriceRef),
|
|
175135
175319
|
unitCount: count(source.unitCount),
|
|
175136
|
-
|
|
175137
|
-
|
|
175320
|
+
overrides: Array.isArray(source.overrides) ? source.overrides.length : 0,
|
|
175321
|
+
sources: sourcesOf(source.sources),
|
|
175322
|
+
durationDays: count(source.durationDays),
|
|
175323
|
+
maxActiveRunsPerWallet: count(source.maxActiveRunsPerWallet)
|
|
175138
175324
|
};
|
|
175139
175325
|
}
|
|
175140
175326
|
function cardOfRun(run, approvalUrl) {
|
|
@@ -175143,6 +175329,9 @@ function cardOfRun(run, approvalUrl) {
|
|
|
175143
175329
|
const status = text3(run.status);
|
|
175144
175330
|
const envelopeRef = amount(run.envelopeRef);
|
|
175145
175331
|
if (!runId || !missionId || !status || envelopeRef === null) return null;
|
|
175332
|
+
const usage = usageOf(run.sourceUsage, () => []);
|
|
175333
|
+
const sourced = (usage ?? []).reduce((sum, source) => sum + source.calls, 0);
|
|
175334
|
+
const payments = count(run.payments) ?? (usage === null ? null : sourced);
|
|
175146
175335
|
return {
|
|
175147
175336
|
kind: run.kind === "trial" ? "trial" : "run",
|
|
175148
175337
|
missionId,
|
|
@@ -175157,7 +175346,53 @@ function cardOfRun(run, approvalUrl) {
|
|
|
175157
175346
|
frequency: null,
|
|
175158
175347
|
digest: null,
|
|
175159
175348
|
expiresAt: text3(run.expiresAt),
|
|
175160
|
-
approvalUrl
|
|
175349
|
+
approvalUrl,
|
|
175350
|
+
sourceUsage: usage,
|
|
175351
|
+
spentRef: amount(run.spentRef),
|
|
175352
|
+
spentCents: text3(run.spentCents),
|
|
175353
|
+
spentNative: amount(run.spentNative),
|
|
175354
|
+
spentAsset: text3(run.spentAsset),
|
|
175355
|
+
payments,
|
|
175356
|
+
unitsDone: count(run.unitsDoneCount),
|
|
175357
|
+
...NOTHING_TO_SHOW,
|
|
175358
|
+
otherPayments: payments !== null && payments > sourced ? { calls: payments - sourced, txUrls: [] } : null,
|
|
175359
|
+
recalibratedUnitPriceRef: amount(run.recalibratedUnitPriceRef),
|
|
175360
|
+
recalibratedEnvelopeRef: amount(run.recalibratedEnvelopeRef)
|
|
175361
|
+
};
|
|
175362
|
+
}
|
|
175363
|
+
function cardOfCompletion(run, context) {
|
|
175364
|
+
const trial = run.kind === "trial";
|
|
175365
|
+
const card = cardOfRun(run, trial && context.checked && context.blocker === null ? context.publishUrl : null);
|
|
175366
|
+
if (!card) return null;
|
|
175367
|
+
const hashOf = new Map(context.payments.map((payment) => [payment.intentId, payment.txHash]));
|
|
175368
|
+
const urlOf = (intentId) => {
|
|
175369
|
+
const hash3 = hashOf.get(intentId);
|
|
175370
|
+
const url2 = hash3 ? context.txUrl(hash3) : void 0;
|
|
175371
|
+
return url2 ? [url2] : [];
|
|
175372
|
+
};
|
|
175373
|
+
const usage = usageOf(run.sourceUsage, urlOf);
|
|
175374
|
+
const sourced = new Set(
|
|
175375
|
+
records(run.sourceUsage).flatMap(
|
|
175376
|
+
(source) => Array.isArray(source.intentIds) ? source.intentIds : []
|
|
175377
|
+
)
|
|
175378
|
+
);
|
|
175379
|
+
const others = context.payments.filter((payment) => !sourced.has(payment.intentId));
|
|
175380
|
+
const sourcedCalls = (usage ?? []).reduce((sum, source) => sum + source.calls, 0);
|
|
175381
|
+
const made = count(run.payments) ?? sourcedCalls + others.length;
|
|
175382
|
+
const otherCalls = Math.max(made - sourcedCalls, others.length);
|
|
175383
|
+
return {
|
|
175384
|
+
...card,
|
|
175385
|
+
kind: "completion",
|
|
175386
|
+
sourceUsage: usage,
|
|
175387
|
+
spentRef: amount(run.spentRef),
|
|
175388
|
+
spentCents: text3(run.spentCents),
|
|
175389
|
+
spentNative: amount(run.spentNative),
|
|
175390
|
+
spentAsset: text3(run.spentAsset),
|
|
175391
|
+
payments: made,
|
|
175392
|
+
otherPayments: otherCalls === 0 ? null : { calls: otherCalls, txUrls: others.flatMap((payment) => urlOf(payment.intentId)) },
|
|
175393
|
+
runKind: trial ? "trial" : "run",
|
|
175394
|
+
publish: !trial || !context.checked ? "none" : context.blocker === null ? "ready" : "blocked",
|
|
175395
|
+
blocker: trial ? context.blocker : null
|
|
175161
175396
|
};
|
|
175162
175397
|
}
|
|
175163
175398
|
function cardOfDraft(mission, approvalUrl) {
|
|
@@ -175180,7 +175415,11 @@ function cardOfDraft(mission, approvalUrl) {
|
|
|
175180
175415
|
frequency: frequencyOf(draft.frequency),
|
|
175181
175416
|
digest: text3(draft.digest),
|
|
175182
175417
|
expiresAt: null,
|
|
175183
|
-
approvalUrl
|
|
175418
|
+
approvalUrl,
|
|
175419
|
+
sourceUsage: null,
|
|
175420
|
+
...NOTHING_SPENT,
|
|
175421
|
+
...NOTHING_TO_SHOW,
|
|
175422
|
+
versionUnitCount: count(draft.unitCount)
|
|
175184
175423
|
};
|
|
175185
175424
|
}
|
|
175186
175425
|
function publicationState(mission, versionNumber, digest2) {
|
|
@@ -175192,23 +175431,24 @@ function publicationState(mission, versionNumber, digest2) {
|
|
|
175192
175431
|
|
|
175193
175432
|
// src/lib/mission-publishability.ts
|
|
175194
175433
|
var record4 = (v) => typeof v === "object" && v !== null && !Array.isArray(v) ? v : null;
|
|
175195
|
-
var
|
|
175434
|
+
var records2 = (v) => Array.isArray(v) ? v.flatMap((item) => {
|
|
175196
175435
|
const found = record4(item);
|
|
175197
175436
|
return found ? [found] : [];
|
|
175198
175437
|
}) : [];
|
|
175199
|
-
function
|
|
175200
|
-
return
|
|
175438
|
+
function completedTrials(draft, trials) {
|
|
175439
|
+
return records2(trials).filter(
|
|
175201
175440
|
(trial) => trial.kind === "trial" && trial.status === "completed" && trial.versionDigest === draft.contentDigest
|
|
175202
175441
|
);
|
|
175203
175442
|
}
|
|
175443
|
+
var unpaid = (completed) => completed.every((trial) => trial.payments === 0);
|
|
175204
175444
|
var TRIAL_UNDER_WAY = /* @__PURE__ */ new Set(["pending", "pending_approval", "active"]);
|
|
175205
175445
|
function trialUnderWay(draft, trials) {
|
|
175206
|
-
return
|
|
175446
|
+
return records2(trials).some(
|
|
175207
175447
|
(trial) => trial.kind === "trial" && TRIAL_UNDER_WAY.has(String(trial.status)) && trial.versionDigest === draft.contentDigest
|
|
175208
175448
|
);
|
|
175209
175449
|
}
|
|
175210
175450
|
function overridesDeclined(draft, events) {
|
|
175211
|
-
const latest =
|
|
175451
|
+
const latest = records2(events).filter((event) => event.kind === "overrides_approved" || event.kind === "overrides_declined").at(-1);
|
|
175212
175452
|
return latest?.kind === "overrides_declined" && latest.digest === draft.digest;
|
|
175213
175453
|
}
|
|
175214
175454
|
function publishBlocker(mission, options = {}) {
|
|
@@ -175219,12 +175459,16 @@ function publishBlocker(mission, options = {}) {
|
|
|
175219
175459
|
if (!draft) {
|
|
175220
175460
|
return { code: "MISSION_NO_DRAFT", detail: "The mission has no open draft to publish: update_mission opens one." };
|
|
175221
175461
|
}
|
|
175222
|
-
|
|
175462
|
+
const completed = options.skipTrialCheck ? null : completedTrials(draft, mission.trials);
|
|
175463
|
+
if (completed?.length === 0) {
|
|
175223
175464
|
return {
|
|
175224
175465
|
code: "MISSION_DRAFT_NOT_TESTED",
|
|
175225
175466
|
detail: trialUnderWay(draft, mission.trials) ? "A trial of the current draft is under way: complete it first." : "No completed trial played the current draft: ask one with request_mission_trial and complete it first."
|
|
175226
175467
|
};
|
|
175227
175468
|
}
|
|
175469
|
+
if (completed && unpaid(completed)) {
|
|
175470
|
+
return { code: "MISSION_TRIAL_UNPAID", detail: "No trial of this draft made a payment: run a trial that pays." };
|
|
175471
|
+
}
|
|
175228
175472
|
const overrides = Array.isArray(draft.overrides) ? draft.overrides : [];
|
|
175229
175473
|
if (overrides.length > 0 && record4(draft.overridesApproval)?.digest !== draft.digest) {
|
|
175230
175474
|
return {
|
|
@@ -175240,7 +175484,7 @@ var publishMissionSchema = external_exports.object({
|
|
|
175240
175484
|
mission: external_exports.string().min(1).describe("Mission id or key")
|
|
175241
175485
|
});
|
|
175242
175486
|
var PUBLISHER_NOTE = "Publishing is done by an operator of the wallet the draft is tuned on, in the dashboard.";
|
|
175243
|
-
var OTHER_WALLET_NOTE = "The trials of this draft ran on another wallet, so they are not checked here: the dashboard checks them.";
|
|
175487
|
+
var OTHER_WALLET_NOTE = "The trials of this draft ran on another wallet, so they are not checked here: the dashboard checks them (publishing needs a completed trial that paid).";
|
|
175244
175488
|
async function tunedElsewhere(session, mission) {
|
|
175245
175489
|
const draft = mission.draft;
|
|
175246
175490
|
const walletId = typeof draft === "object" && draft !== null && "walletId" in draft && typeof draft.walletId === "string" ? draft.walletId : null;
|
|
@@ -175252,7 +175496,7 @@ function createPublishMissionTool(session) {
|
|
|
175252
175496
|
name: "publish_mission",
|
|
175253
175497
|
title: "Publish a mission",
|
|
175254
175498
|
annotations: { readOnlyHint: true, openWorldHint: false },
|
|
175255
|
-
description: "Checks that the open draft of a mission can be published and shows it to the user with the page where they publish it in the Keyban dashboard. It does not publish: publishing is the user's, in their own Keyban session. Refused with MISSION_NO_DRAFT, MISSION_DRAFT_NOT_TESTED or MISSION_OVERRIDES_NOT_APPROVED while the draft cannot be published yet, with what to do first.",
|
|
175499
|
+
description: "Checks that the open draft of a mission can be published and shows it to the user with the page where they publish it in the Keyban dashboard. It does not publish: publishing is the user's, in their own Keyban session. Refused with MISSION_NO_DRAFT, MISSION_DRAFT_NOT_TESTED, MISSION_TRIAL_UNPAID or MISSION_OVERRIDES_NOT_APPROVED while the draft cannot be published yet, with what to do first.",
|
|
175256
175500
|
inputSchema: publishMissionSchema,
|
|
175257
175501
|
ui: { resourceUri: MISSION_CARD_URI },
|
|
175258
175502
|
handler: async (input) => {
|
|
@@ -175265,63 +175509,188 @@ function createPublishMissionTool(session) {
|
|
|
175265
175509
|
const link = missionPageLink(session.baseURL, session.appId, missionId);
|
|
175266
175510
|
const card = cardOfDraft(mission, link);
|
|
175267
175511
|
if (!card) throw new Error(`MISSION_NO_DRAFT: mission ${input.mission} has no draft to publish.`);
|
|
175268
|
-
const
|
|
175512
|
+
const text5 = [
|
|
175269
175513
|
`The draft v${card.versionNumber} of "${card.missionTitle}" can be published. Ask the user to publish it in the Keyban dashboard${link ? `: ${link}` : "."}`,
|
|
175270
175514
|
PUBLISHER_NOTE,
|
|
175271
175515
|
elsewhere ? OTHER_WALLET_NOTE : "",
|
|
175272
175516
|
card.sharing === "organization" ? ORGANIZATION_NOTE : ""
|
|
175273
175517
|
].filter(Boolean).join(" ");
|
|
175274
|
-
return { text:
|
|
175518
|
+
return { text: text5, structuredContent: { card } };
|
|
175275
175519
|
}
|
|
175276
175520
|
};
|
|
175277
175521
|
}
|
|
175278
175522
|
|
|
175279
175523
|
// src/tools/watch-mission-approval.ts
|
|
175280
175524
|
init_zod();
|
|
175525
|
+
|
|
175526
|
+
// src/lib/mission-card-diff.ts
|
|
175527
|
+
function sourcesOf2(v) {
|
|
175528
|
+
if (!Array.isArray(v)) return [];
|
|
175529
|
+
return v.flatMap((item) => {
|
|
175530
|
+
const source = record3(item);
|
|
175531
|
+
const endpoint = text3(source?.endpoint);
|
|
175532
|
+
return source && endpoint !== null ? [{ endpoint, label: text3(source.label), callsPerUnit: count(source.callsPerUnit), callPriceRef: amount(source.callPriceRef) }] : [];
|
|
175533
|
+
});
|
|
175534
|
+
}
|
|
175535
|
+
var planOf = (source) => ({
|
|
175536
|
+
callsPerUnit: source.callsPerUnit,
|
|
175537
|
+
callPriceRef: source.callPriceRef
|
|
175538
|
+
});
|
|
175539
|
+
var samePlan = (a5, b5) => a5.callsPerUnit === b5.callsPerUnit && a5.callPriceRef === b5.callPriceRef;
|
|
175540
|
+
function changed(after, before) {
|
|
175541
|
+
return before !== null && before !== after ? before : null;
|
|
175542
|
+
}
|
|
175543
|
+
function diffOf(version5, published) {
|
|
175544
|
+
const replaces = count(published?.number);
|
|
175545
|
+
if (!published || replaces === null || replaces === count(version5.number)) return null;
|
|
175546
|
+
const before = sourcesOf2(published.sources);
|
|
175547
|
+
const after = sourcesOf2(version5.sources);
|
|
175548
|
+
const previous = {};
|
|
175549
|
+
for (const source of after) {
|
|
175550
|
+
const old = before.find((candidate) => candidate.endpoint === source.endpoint);
|
|
175551
|
+
if (old && !samePlan(old, source)) previous[source.endpoint] = planOf(old);
|
|
175552
|
+
}
|
|
175553
|
+
return {
|
|
175554
|
+
replaces,
|
|
175555
|
+
newEndpoints: after.filter((source) => !before.some((old) => old.endpoint === source.endpoint)).map((source) => source.endpoint),
|
|
175556
|
+
removed: before.filter((old) => !after.some((source) => source.endpoint === old.endpoint)),
|
|
175557
|
+
previous,
|
|
175558
|
+
envelopeWas: changed(amount(version5.envelopeRef), amount(published.envelopeRef)),
|
|
175559
|
+
unitPriceWas: changed(amount(version5.unitPriceRef), amount(published.unitPriceRef))
|
|
175560
|
+
};
|
|
175561
|
+
}
|
|
175562
|
+
function statsOf(mission) {
|
|
175563
|
+
if (!Array.isArray(mission.versionStats)) return [];
|
|
175564
|
+
return mission.versionStats.flatMap((item) => {
|
|
175565
|
+
const stats = record3(item);
|
|
175566
|
+
const number4 = count(stats?.number);
|
|
175567
|
+
const basis = stats?.basis;
|
|
175568
|
+
if (!stats || number4 === null) return [];
|
|
175569
|
+
return [{
|
|
175570
|
+
number: number4,
|
|
175571
|
+
status: text3(stats.status) ?? "",
|
|
175572
|
+
basis: basis === "regular" || basis === "trial" ? basis : null,
|
|
175573
|
+
price: text3(stats.observedUnitPriceCents)
|
|
175574
|
+
}];
|
|
175575
|
+
});
|
|
175576
|
+
}
|
|
175577
|
+
function referenceOf(mission, versionNumber) {
|
|
175578
|
+
const stats = statsOf(mission);
|
|
175579
|
+
const publishedNumber = count(record3(mission.published)?.number);
|
|
175580
|
+
if (publishedNumber !== null && publishedNumber !== versionNumber) {
|
|
175581
|
+
const published = stats.find((entry) => entry.number === publishedNumber);
|
|
175582
|
+
return { versionNumber: publishedNumber, unitPriceCents: published?.price ?? null, basis: published?.basis ?? null };
|
|
175583
|
+
}
|
|
175584
|
+
const found = stats.filter((entry) => entry.number < versionNumber && entry.status === "superseded" && entry.price !== null).sort((x, y) => y.number - x.number)[0];
|
|
175585
|
+
return found ? { versionNumber: found.number, unitPriceCents: found.price, basis: found.basis } : null;
|
|
175586
|
+
}
|
|
175587
|
+
function progressOf(card) {
|
|
175588
|
+
return `${card.unitsDone ?? ""}:${card.spentRef ?? ""}:${card.payments ?? ""}`;
|
|
175589
|
+
}
|
|
175590
|
+
|
|
175591
|
+
// src/lib/mission-card-details.ts
|
|
175592
|
+
function versionOf(mission, number4) {
|
|
175593
|
+
const candidates2 = [mission.draft, mission.published, ...Array.isArray(mission.versions) ? mission.versions : []];
|
|
175594
|
+
return candidates2.map(record3).find((version5) => version5?.number === number4) ?? null;
|
|
175595
|
+
}
|
|
175596
|
+
function withVersionDetails(card, mission) {
|
|
175597
|
+
const version5 = mission ? versionOf(mission, card.versionNumber) : null;
|
|
175598
|
+
if (!version5) return card;
|
|
175599
|
+
const frequency = record3(version5.frequency);
|
|
175600
|
+
return {
|
|
175601
|
+
...card,
|
|
175602
|
+
versionUnitCount: typeof version5.unitCount === "number" ? version5.unitCount : null,
|
|
175603
|
+
diff: diffOf(version5, record3(mission?.published)),
|
|
175604
|
+
reference: mission ? referenceOf(mission, card.versionNumber) : null,
|
|
175605
|
+
sharing: card.sharing ?? (typeof version5.sharing === "string" ? version5.sharing : null),
|
|
175606
|
+
mode: card.mode ?? (typeof version5.mode === "string" ? version5.mode : null),
|
|
175607
|
+
frequency: card.frequency ?? (typeof frequency?.count === "number" && typeof frequency.period === "string" ? { count: frequency.count, period: frequency.period } : null),
|
|
175608
|
+
durationDays: card.durationDays ?? (typeof version5.durationDays === "number" ? version5.durationDays : null),
|
|
175609
|
+
maxActiveRunsPerWallet: card.maxActiveRunsPerWallet ?? (typeof version5.maxActiveRunsPerWallet === "number" ? version5.maxActiveRunsPerWallet : null)
|
|
175610
|
+
};
|
|
175611
|
+
}
|
|
175612
|
+
async function readMission(session, missionId) {
|
|
175613
|
+
try {
|
|
175614
|
+
return await fetchMission(session, missionId);
|
|
175615
|
+
} catch (error3) {
|
|
175616
|
+
logger.error("Could not re-read the mission for its card", error3);
|
|
175617
|
+
return null;
|
|
175618
|
+
}
|
|
175619
|
+
}
|
|
175620
|
+
async function detailedCardOfRun(session, run, approvalUrl, mission = (id) => readMission(session, id)) {
|
|
175621
|
+
const card = cardOfRun(run, approvalUrl);
|
|
175622
|
+
if (!card) return null;
|
|
175623
|
+
return withVersionDetails(card, await mission(card.missionId));
|
|
175624
|
+
}
|
|
175625
|
+
|
|
175626
|
+
// src/tools/watch-mission-approval.ts
|
|
175281
175627
|
var POLL_MS = 2e3;
|
|
175282
175628
|
var watchMissionApprovalSchema = external_exports.object({
|
|
175283
175629
|
runId: external_exports.string().uuid().optional().describe("The trial or run the card shows"),
|
|
175284
175630
|
missionId: external_exports.string().optional().describe("The mission whose publication the card shows"),
|
|
175285
175631
|
versionNumber: external_exports.number().int().optional().describe("Number of the draft the card proposed for publication"),
|
|
175286
|
-
digest: external_exports.string().optional().describe("Publication digest of the draft the card proposed"),
|
|
175632
|
+
digest: external_exports.string().optional().describe("Publication digest of the draft the card proposed; without it, the watch only says whether the version got published"),
|
|
175287
175633
|
known: external_exports.string().describe("The status the card shows: the watch answers once it differs"),
|
|
175634
|
+
progress: external_exports.string().optional().describe("The progress of the run the card shows (units, spend, payments): the watch also answers once it differs"),
|
|
175635
|
+
pollMs: external_exports.number().int().min(2e3).max(3e4).optional().describe("How often to read the run while waiting; the tool never reads faster than its own cadence"),
|
|
175288
175636
|
timeoutMs: external_exports.number().int().positive().max(3e4).optional().default(25e3).describe("How long to wait for a change before answering with the current status")
|
|
175289
175637
|
});
|
|
175290
|
-
async function readRun(session, runId) {
|
|
175291
|
-
const card =
|
|
175292
|
-
|
|
175638
|
+
async function readRun(session, runId, mission) {
|
|
175639
|
+
const card = await detailedCardOfRun(
|
|
175640
|
+
session,
|
|
175641
|
+
await fetchMissionRun(session, runId),
|
|
175642
|
+
missionRunLink(session.baseURL, session.appId, runId),
|
|
175643
|
+
mission
|
|
175644
|
+
);
|
|
175645
|
+
return { state: card?.status ?? "unknown", card, progress: card ? progressOf(card) : null };
|
|
175293
175646
|
}
|
|
175294
175647
|
async function readPublication(session, missionId, versionNumber, digest2) {
|
|
175295
175648
|
const mission = await fetchMission(session, missionId);
|
|
175296
175649
|
const state2 = publicationState(mission, versionNumber, digest2);
|
|
175297
175650
|
const version5 = state2 === "published" ? mission.published : mission.draft;
|
|
175298
175651
|
const card = cardOfDraft({ ...mission, draft: version5 }, missionPageLink(session.baseURL, session.appId, missionId));
|
|
175299
|
-
if (!card) return { state: state2, card: null };
|
|
175300
|
-
return {
|
|
175652
|
+
if (!card) return { state: state2, card: null, progress: null };
|
|
175653
|
+
return {
|
|
175654
|
+
state: state2,
|
|
175655
|
+
card: state2 === "published" ? { ...card, status: state2 } : { ...card, status: state2, versionNumber, digest: digest2 },
|
|
175656
|
+
progress: null
|
|
175657
|
+
};
|
|
175658
|
+
}
|
|
175659
|
+
async function readPublished(session, missionId, versionNumber) {
|
|
175660
|
+
const mission = await fetchMission(session, missionId);
|
|
175661
|
+
const published = record3(mission.published)?.number === versionNumber;
|
|
175662
|
+
return { state: published ? "published" : "unpublished", card: null, progress: null };
|
|
175301
175663
|
}
|
|
175302
175664
|
function reader(session, input) {
|
|
175303
175665
|
const { runId, missionId, versionNumber, digest: digest2 } = input;
|
|
175304
|
-
if (runId)
|
|
175666
|
+
if (runId) {
|
|
175667
|
+
let cached2 = null;
|
|
175668
|
+
const mission = (id) => cached2 ??= readMission(session, id);
|
|
175669
|
+
return () => readRun(session, runId, mission);
|
|
175670
|
+
}
|
|
175305
175671
|
if (missionId && versionNumber !== void 0 && digest2) {
|
|
175306
175672
|
return () => readPublication(session, missionId, versionNumber, digest2);
|
|
175307
175673
|
}
|
|
175308
|
-
|
|
175674
|
+
if (missionId && versionNumber !== void 0) return () => readPublished(session, missionId, versionNumber);
|
|
175675
|
+
throw new Error("Pass runId, or missionId with versionNumber (and digest to follow a draft).");
|
|
175309
175676
|
}
|
|
175310
175677
|
function createWatchMissionApprovalTool(session, pollMs = POLL_MS) {
|
|
175311
175678
|
return {
|
|
175312
175679
|
name: "watch_mission_approval",
|
|
175313
175680
|
title: "Watch a mission approval",
|
|
175314
175681
|
annotations: { readOnlyHint: true, openWorldHint: false },
|
|
175315
|
-
description: "Called by the mission card: waits until the trial, run or publication it shows changes status, or until the timeout, and returns its state.",
|
|
175682
|
+
description: "Called by the mission card: waits until the trial, run or publication it shows changes status or, for an active run, progress, or until the timeout, and returns its state.",
|
|
175316
175683
|
inputSchema: watchMissionApprovalSchema,
|
|
175317
175684
|
ui: { resourceUri: MISSION_CARD_URI, visibility: ["app"] },
|
|
175318
175685
|
handler: async (input) => {
|
|
175319
175686
|
requireCredentials(session);
|
|
175320
175687
|
const read2 = reader(session, input);
|
|
175321
175688
|
const deadline = Date.now() + input.timeoutMs;
|
|
175689
|
+
const cadence = Math.max(pollMs, input.pollMs ?? 0);
|
|
175690
|
+
const unchanged = (reading2) => reading2.state === input.known && (input.progress === void 0 || reading2.progress === input.progress);
|
|
175322
175691
|
let reading = await read2();
|
|
175323
|
-
while (reading
|
|
175324
|
-
await new Promise((resolve) => setTimeout(resolve,
|
|
175692
|
+
while (unchanged(reading) && Date.now() + cadence <= deadline) {
|
|
175693
|
+
await new Promise((resolve) => setTimeout(resolve, cadence));
|
|
175325
175694
|
reading = await read2();
|
|
175326
175695
|
}
|
|
175327
175696
|
return { text: `The mission card shows ${reading.state}.`, structuredContent: { ...reading } };
|
|
@@ -175346,7 +175715,9 @@ function walletTools(session) {
|
|
|
175346
175715
|
createAwaitPaymentApprovalTool(session),
|
|
175347
175716
|
createWatchPaymentApprovalTool(session),
|
|
175348
175717
|
createPublishMissionTool(session),
|
|
175349
|
-
createWatchMissionApprovalTool(session)
|
|
175718
|
+
createWatchMissionApprovalTool(session),
|
|
175719
|
+
createX402PayInMissionTool(session),
|
|
175720
|
+
createTransferUsdcInMissionTool(session)
|
|
175350
175721
|
],
|
|
175351
175722
|
createDiscoverX402ServicesTool(session),
|
|
175352
175723
|
createExpenseStatsTool(session),
|
|
@@ -175493,6 +175864,111 @@ function bootstrapWallet(session = createSession()) {
|
|
|
175493
175864
|
var import_mcp_openapi2 = __toESM(require_dist2(), 1);
|
|
175494
175865
|
init_types();
|
|
175495
175866
|
|
|
175867
|
+
// src/lib/mission-run-wait.ts
|
|
175868
|
+
var MISSION_RUN_PENDING = "pending_approval";
|
|
175869
|
+
var MISSION_RUN_WAIT_MS = 45e3;
|
|
175870
|
+
function missionRunStreamUrl(session, runId) {
|
|
175871
|
+
return `${session.baseURL}/v1/policy/intents/sse?missionRunId=${encodeURIComponent(runId)}`;
|
|
175872
|
+
}
|
|
175873
|
+
async function readStatus(body, runId) {
|
|
175874
|
+
for await (const p3 of sseJsonPayloads(body)) {
|
|
175875
|
+
if (p3.type !== "mission-run" || p3.runId !== runId || typeof p3.status !== "string") continue;
|
|
175876
|
+
if (p3.status !== MISSION_RUN_PENDING) return p3.status;
|
|
175877
|
+
}
|
|
175878
|
+
return null;
|
|
175879
|
+
}
|
|
175880
|
+
async function statusOnOneStream(session, runId, signal) {
|
|
175881
|
+
const body = await openIntentsStream(session, signal, missionRunStreamUrl(session, runId));
|
|
175882
|
+
return body ? readStatus(body, runId).catch(() => null) : null;
|
|
175883
|
+
}
|
|
175884
|
+
async function waitForMissionRun(session, runId, timeoutMs) {
|
|
175885
|
+
const deadline = Date.now() + timeoutMs;
|
|
175886
|
+
const controller = new AbortController();
|
|
175887
|
+
const timer = setTimeout(() => controller.abort(), timeoutMs);
|
|
175888
|
+
try {
|
|
175889
|
+
while (Date.now() < deadline) {
|
|
175890
|
+
let status;
|
|
175891
|
+
try {
|
|
175892
|
+
status = await statusOnOneStream(session, runId, controller.signal);
|
|
175893
|
+
} catch (error3) {
|
|
175894
|
+
logger.warn(
|
|
175895
|
+
`mission run ${runId}: stopped waiting for the decision: ${error3 instanceof Error ? error3.message : String(error3)}`
|
|
175896
|
+
);
|
|
175897
|
+
break;
|
|
175898
|
+
}
|
|
175899
|
+
if (status) return { status, decided: true };
|
|
175900
|
+
await pause(Math.min(RECONNECT_PAUSE_MS, deadline - Date.now()));
|
|
175901
|
+
}
|
|
175902
|
+
} finally {
|
|
175903
|
+
clearTimeout(timer);
|
|
175904
|
+
controller.abort();
|
|
175905
|
+
}
|
|
175906
|
+
return { status: MISSION_RUN_PENDING, decided: false };
|
|
175907
|
+
}
|
|
175908
|
+
|
|
175909
|
+
// src/lib/mission-run-decision.ts
|
|
175910
|
+
var WAIT_TOOL = "wait_for_mission_run";
|
|
175911
|
+
var text4 = (v) => typeof v === "string" ? v : "";
|
|
175912
|
+
var subjectOf = (run) => run.kind === "trial" ? "The trial" : "The run";
|
|
175913
|
+
var validatedAt = (session, runId) => {
|
|
175914
|
+
const link = missionRunLink(session.baseURL, session.appId, runId);
|
|
175915
|
+
return link ? ` The user validates it at ${link}.` : "";
|
|
175916
|
+
};
|
|
175917
|
+
function awaitingDecision(session, run) {
|
|
175918
|
+
const runId = text4(run.id);
|
|
175919
|
+
return `${subjectOf(run)} waits for a wallet operator's approval: its card shows the user the Validate in Keyban button.${validatedAt(session, runId)} Call ${WAIT_TOOL} with runId ${runId} now, and again while it is still waiting. Do not start the work before it says active.`;
|
|
175920
|
+
}
|
|
175921
|
+
function stillWaiting3(session, runId) {
|
|
175922
|
+
return `Still waiting for the operator: call ${WAIT_TOOL} again with runId ${runId}. Do not start the work yet.` + validatedAt(session, runId);
|
|
175923
|
+
}
|
|
175924
|
+
function decisionText(run) {
|
|
175925
|
+
const subject = subjectOf(run);
|
|
175926
|
+
const status = text4(run.status);
|
|
175927
|
+
if (status === "active") {
|
|
175928
|
+
return `${subject} is active: execute the mission now, do not ask the user again (the validation is the go-ahead). Pay with x402_pay_in_mission or transfer_usdc_in_mission and missionRunId ${text4(run.id)}; deliver the result to the user, then call complete_mission_run last.`;
|
|
175929
|
+
}
|
|
175930
|
+
if (status === "completed") return `${subject} is already finished: there is nothing more to do on it. Do not start the work again.`;
|
|
175931
|
+
if (status === MISSION_RUN_PENDING) {
|
|
175932
|
+
return `${subject} is still waiting for the operator: call ${WAIT_TOOL} again with runId ${text4(run.id)}. Do not start the work yet.`;
|
|
175933
|
+
}
|
|
175934
|
+
return `${subject} is ${status}: it was not approved to go on. Stop here, do not start the work, and tell the user.`;
|
|
175935
|
+
}
|
|
175936
|
+
async function settleRun(session, run, timeoutMs) {
|
|
175937
|
+
const runId = text4(run.id);
|
|
175938
|
+
if (run.status !== MISSION_RUN_PENDING || !runId) return { run, text: null };
|
|
175939
|
+
const waited = await waitForMissionRun(session, runId, timeoutMs);
|
|
175940
|
+
if (!waited.decided) return { run, text: stillWaiting3(session, runId) };
|
|
175941
|
+
const decided = await fetchMissionRun(session, runId).catch(() => ({ ...run, status: waited.status }));
|
|
175942
|
+
return { run: decided, text: decisionText(decided) };
|
|
175943
|
+
}
|
|
175944
|
+
|
|
175945
|
+
// src/tools/wait-for-mission-run.ts
|
|
175946
|
+
init_zod();
|
|
175947
|
+
var waitForMissionRunSchema = external_exports.object({
|
|
175948
|
+
runId: external_exports.string().uuid().describe("The trial or run to wait for"),
|
|
175949
|
+
timeoutMs: external_exports.number().int().positive().max(MISSION_RUN_WAIT_MS).optional().default(MISSION_RUN_WAIT_MS)
|
|
175950
|
+
});
|
|
175951
|
+
var waitForMissionRunTool = {
|
|
175952
|
+
name: WAIT_TOOL,
|
|
175953
|
+
title: "Wait for a mission run decision",
|
|
175954
|
+
description: "Waits for a wallet operator to decide on a mission trial or run that waits for approval. Call it with the runId right after request_mission_trial or start_mission_run returned a run pending approval. Each call waits up to 45 s: while it says still waiting, call it again. Once it says active, execute the mission at once without asking the user again (the validation is the go-ahead); declined, expired or cancelled means stop and tell the user.",
|
|
175955
|
+
annotations: { readOnlyHint: true, openWorldHint: false },
|
|
175956
|
+
inputSchema: {
|
|
175957
|
+
type: "object",
|
|
175958
|
+
properties: {
|
|
175959
|
+
runId: { type: "string", format: "uuid", description: "The trial or run to wait for" },
|
|
175960
|
+
timeoutMs: { type: "integer", exclusiveMinimum: 0, maximum: MISSION_RUN_WAIT_MS, default: MISSION_RUN_WAIT_MS }
|
|
175961
|
+
},
|
|
175962
|
+
required: ["runId"]
|
|
175963
|
+
}
|
|
175964
|
+
};
|
|
175965
|
+
async function callWaitForMissionRun(session, args) {
|
|
175966
|
+
const input = waitForMissionRunSchema.parse(args);
|
|
175967
|
+
requireCredentials(session);
|
|
175968
|
+
const { run, text: text5 } = await settleRun(session, await fetchMissionRun(session, input.runId), input.timeoutMs);
|
|
175969
|
+
return { content: [{ type: "text", text: text5 ?? decisionText(run) }], structuredContent: run };
|
|
175970
|
+
}
|
|
175971
|
+
|
|
175496
175972
|
// src/lib/wallet-scope.ts
|
|
175497
175973
|
var GROUPS2 = ["path", "query", "body"];
|
|
175498
175974
|
var GROUP_NAMES = new Set(GROUPS2);
|
|
@@ -175562,8 +176038,10 @@ ${WALLET_NOTE}`.trimStart();
|
|
|
175562
176038
|
}
|
|
175563
176039
|
|
|
175564
176040
|
// src/lib/mission-tools.ts
|
|
175565
|
-
var
|
|
175566
|
-
var
|
|
176041
|
+
var RUN_TOOLS = /* @__PURE__ */ new Set(["start_mission_run", "request_mission_trial"]);
|
|
176042
|
+
var COMPLETE_TOOL = "complete_mission_run";
|
|
176043
|
+
var MISSION_CARD_TOOLS = /* @__PURE__ */ new Set([...RUN_TOOLS, COMPLETE_TOOL]);
|
|
176044
|
+
var failure = (text5) => ({ content: [{ type: "text", text: text5 }], isError: true });
|
|
175567
176045
|
function buildServer(operations, session) {
|
|
175568
176046
|
const server = (0, import_mcp_openapi2.createMcpServer)({ name: "keyban-missions", version: "0" }, { capabilities: { tools: {} } });
|
|
175569
176047
|
const registry2 = new import_mcp_openapi2.ToolRegistry(
|
|
@@ -175573,19 +176051,47 @@ function buildServer(operations, session) {
|
|
|
175573
176051
|
for (const operation2 of operations) registry2.registerOperation(operation2);
|
|
175574
176052
|
return server;
|
|
175575
176053
|
}
|
|
175576
|
-
function withCard(result, session) {
|
|
176054
|
+
async function withCard(name, result, session) {
|
|
175577
176055
|
if (result.isError || !result.structuredContent) return result;
|
|
175578
|
-
|
|
175579
|
-
|
|
175580
|
-
|
|
176056
|
+
if (name === COMPLETE_TOOL) {
|
|
176057
|
+
return result.structuredContent.status === "completed" ? withCompletionCard(result, session) : result;
|
|
176058
|
+
}
|
|
176059
|
+
return withRunCard(result, session);
|
|
176060
|
+
}
|
|
176061
|
+
async function withRunCard(result, session) {
|
|
176062
|
+
const run = result.structuredContent;
|
|
176063
|
+
if (!run) return result;
|
|
176064
|
+
const runId = typeof run.id === "string" ? run.id : "";
|
|
176065
|
+
const card = await detailedCardOfRun(session, run, runId ? missionRunLink(session.baseURL, session.appId, runId) : null);
|
|
175581
176066
|
if (!card) return result;
|
|
175582
|
-
const
|
|
176067
|
+
const next = run.status === MISSION_RUN_PENDING && runId ? awaitingDecision(session, run) : decisionText(run);
|
|
175583
176068
|
return {
|
|
175584
176069
|
...result,
|
|
175585
|
-
content: [...result.content,
|
|
175586
|
-
structuredContent: { ...
|
|
176070
|
+
content: [...result.content, { type: "text", text: next }],
|
|
176071
|
+
structuredContent: { ...run, card }
|
|
175587
176072
|
};
|
|
175588
176073
|
}
|
|
176074
|
+
async function withCompletionCard(result, session) {
|
|
176075
|
+
const run = result.structuredContent;
|
|
176076
|
+
if (!run) return result;
|
|
176077
|
+
const missionId = typeof run.missionId === "string" ? run.missionId : "";
|
|
176078
|
+
const mission = missionId ? await readMission(session, missionId) : null;
|
|
176079
|
+
const blocker = run.kind === "trial" && mission ? publishBlocker(mission) : null;
|
|
176080
|
+
const card = cardOfCompletion(run, {
|
|
176081
|
+
mission,
|
|
176082
|
+
publishUrl: missionId ? missionPageLink(session.baseURL, session.appId, missionId) : null,
|
|
176083
|
+
blocker: blocker ? blocker.detail : null,
|
|
176084
|
+
checked: mission !== null,
|
|
176085
|
+
payments: typeof run.id === "string" ? runPayments(session, run.id) : [],
|
|
176086
|
+
txUrl: (hash3) => {
|
|
176087
|
+
const chainId = session.account?.publicClient.chain?.id;
|
|
176088
|
+
return chainId === void 0 ? void 0 : explorerTxUrl(chainId, hash3);
|
|
176089
|
+
}
|
|
176090
|
+
});
|
|
176091
|
+
if (typeof run.id === "string") forgetRunPayments(session, run.id);
|
|
176092
|
+
if (!card) return result;
|
|
176093
|
+
return { ...result, structuredContent: { ...run, card: withVersionDetails(card, mission) } };
|
|
176094
|
+
}
|
|
175589
176095
|
function scopeMissionTool(tool) {
|
|
175590
176096
|
const own = scopeToWallet(tool);
|
|
175591
176097
|
delete own.tool.outputSchema;
|
|
@@ -175594,7 +176100,15 @@ function scopeMissionTool(tool) {
|
|
|
175594
176100
|
}
|
|
175595
176101
|
return own;
|
|
175596
176102
|
}
|
|
176103
|
+
async function callWaitSafely(session, args) {
|
|
176104
|
+
try {
|
|
176105
|
+
return await callWaitForMissionRun(session, args);
|
|
176106
|
+
} catch (error3) {
|
|
176107
|
+
return failure(error3 instanceof Error ? error3.message : String(error3));
|
|
176108
|
+
}
|
|
176109
|
+
}
|
|
175597
176110
|
async function callMissionTool(client2, scoped, session, name, args) {
|
|
176111
|
+
if (name === WAIT_TOOL) return callWaitSafely(session, args);
|
|
175598
176112
|
const own = scoped.get(name);
|
|
175599
176113
|
if (!own) return failure(`Unknown mission tool: ${name}`);
|
|
175600
176114
|
let walletId;
|
|
@@ -175607,7 +176121,7 @@ async function callMissionTool(client2, scoped, session, name, args) {
|
|
|
175607
176121
|
{ method: "tools/call", params: { name, arguments: own.fill(args, walletId) } },
|
|
175608
176122
|
CallToolResultSchema
|
|
175609
176123
|
);
|
|
175610
|
-
return MISSION_CARD_TOOLS.has(name) ? withCard(result, session) : result;
|
|
176124
|
+
return MISSION_CARD_TOOLS.has(name) ? withCard(name, result, session) : result;
|
|
175611
176125
|
}
|
|
175612
176126
|
async function buildMissionTools(document, session) {
|
|
175613
176127
|
const operations = (0, import_mcp_openapi2.collectOperations)(document).filter((operation2) => operation2.agentWallet);
|
|
@@ -175616,7 +176130,7 @@ async function buildMissionTools(document, session) {
|
|
|
175616
176130
|
const { tools } = await client2.listTools();
|
|
175617
176131
|
const scoped = new Map(tools.map((tool) => [tool.name, scopeMissionTool(tool)]));
|
|
175618
176132
|
return {
|
|
175619
|
-
tools: [...scoped.values()].map(({ tool }) => tool),
|
|
176133
|
+
tools: [...[...scoped.values()].map(({ tool }) => tool), waitForMissionRunTool],
|
|
175620
176134
|
call: (name, args) => callMissionTool(client2, scoped, session, name, args)
|
|
175621
176135
|
};
|
|
175622
176136
|
}
|
|
@@ -176998,7 +177512,7 @@ async function readRequestBody(request, maxBytes = DEFAULT_MAX_REQUEST_BODY_SIZE
|
|
|
176998
177512
|
const reader2 = request.body.getReader();
|
|
176999
177513
|
const decoder2 = new TextDecoder();
|
|
177000
177514
|
let received = 0;
|
|
177001
|
-
let
|
|
177515
|
+
let text5 = "";
|
|
177002
177516
|
try {
|
|
177003
177517
|
for (; ; ) {
|
|
177004
177518
|
const { done, value } = await reader2.read();
|
|
@@ -177009,12 +177523,12 @@ async function readRequestBody(request, maxBytes = DEFAULT_MAX_REQUEST_BODY_SIZE
|
|
|
177009
177523
|
if (received > maxBytes) {
|
|
177010
177524
|
return { tooLarge: true };
|
|
177011
177525
|
}
|
|
177012
|
-
|
|
177526
|
+
text5 += decoder2.decode(value, { stream: true });
|
|
177013
177527
|
}
|
|
177014
177528
|
} finally {
|
|
177015
177529
|
reader2.releaseLock();
|
|
177016
177530
|
}
|
|
177017
|
-
return { tooLarge: false, text:
|
|
177531
|
+
return { tooLarge: false, text: text5 + decoder2.decode() };
|
|
177018
177532
|
}
|
|
177019
177533
|
|
|
177020
177534
|
// node_modules/.pnpm/@modelcontextprotocol+sdk@1.32.1_supports-color@7.2.0_zod@3.25.76/node_modules/@modelcontextprotocol/sdk/dist/esm/server/sseKeepAlive.js
|
|
@@ -178070,19 +178584,19 @@ function commandFor2(tool) {
|
|
|
178070
178584
|
}
|
|
178071
178585
|
return command5.action(async (options) => {
|
|
178072
178586
|
let out = process.stdout;
|
|
178073
|
-
let
|
|
178587
|
+
let text5;
|
|
178074
178588
|
let code = 0;
|
|
178075
178589
|
try {
|
|
178076
|
-
|
|
178590
|
+
text5 = toolText(await tool.handler(tool.inputSchema.parse(options)));
|
|
178077
178591
|
} catch (error3) {
|
|
178078
178592
|
const message = error3 instanceof Error ? error3.message : String(error3);
|
|
178079
178593
|
const cause = error3 instanceof Error && error3.cause ? `
|
|
178080
178594
|
Caused by: ${error3.cause}` : "";
|
|
178081
178595
|
out = process.stderr;
|
|
178082
|
-
|
|
178596
|
+
text5 = `Error: ${message}${cause}`;
|
|
178083
178597
|
code = 1;
|
|
178084
178598
|
}
|
|
178085
|
-
await new Promise((resolve) => out.write(
|
|
178599
|
+
await new Promise((resolve) => out.write(text5.endsWith("\n") ? text5 : `${text5}
|
|
178086
178600
|
`, () => resolve()));
|
|
178087
178601
|
process.exit(code);
|
|
178088
178602
|
});
|
|
@@ -178117,7 +178631,7 @@ ${wallet.instructions}`;
|
|
|
178117
178631
|
}
|
|
178118
178632
|
|
|
178119
178633
|
// src/index.ts
|
|
178120
|
-
var VERSION = true ? "0.2.
|
|
178634
|
+
var VERSION = true ? "0.2.1" : "0.0.0";
|
|
178121
178635
|
if (process.argv[2] !== "mcp" && !process.env.MCP_LOG_LEVEL) logger.setMinLevel("error");
|
|
178122
178636
|
function typedArgv(argv) {
|
|
178123
178637
|
if (argv[2] !== "__complete") return argv;
|