@opentiny/next-sdk 0.2.8 → 0.2.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.es.dev.js +87 -3
- package/dist/index.es.js +9962 -9898
- package/dist/index.js +878 -814
- package/dist/index.umd.dev.js +87 -3
- package/dist/index.umd.js +40 -40
- package/dist/page-tools/bridge.d.ts +23 -0
- package/package.json +1 -1
- package/page-tools/bridge.ts +134 -0
package/dist/index.js
CHANGED
|
@@ -1,29 +1,29 @@
|
|
|
1
|
-
import { default as
|
|
2
|
-
import { z as
|
|
3
|
-
import { z as
|
|
4
|
-
import { MessageChannelServerTransport as
|
|
5
|
-
import { AuthClientProvider as
|
|
6
|
-
import { McpServer as
|
|
7
|
-
import { ResourceTemplate as
|
|
8
|
-
import { UriTemplate as
|
|
9
|
-
import { completable as
|
|
10
|
-
import { getDisplayName as
|
|
11
|
-
import { InMemoryTransport as
|
|
12
|
-
import { InMemoryTransport as
|
|
13
|
-
import { SetLevelRequestSchema as
|
|
14
|
-
import { Client as
|
|
15
|
-
import { SSEClientTransport as
|
|
16
|
-
import { StreamableHTTPClientTransport as
|
|
17
|
-
import { WebSocketClientTransport as
|
|
18
|
-
import
|
|
19
|
-
import { dynamicTool as
|
|
20
|
-
import { TypeValidationError as
|
|
21
|
-
import * as
|
|
1
|
+
import { default as Qn } from "ajv";
|
|
2
|
+
import { z as G } from "zod";
|
|
3
|
+
import { z as eo } from "zod";
|
|
4
|
+
import { MessageChannelServerTransport as Me, createTransportPair as jt, MessageChannelClientTransport as Ee, sseOptions as Zt, streamOptions as zt, createSseProxy as qt, createSocketProxy as Dt, createStreamProxy as Ht, MessageChannelTransport as Ft } from "@opentiny/next";
|
|
5
|
+
import { AuthClientProvider as ro } from "@opentiny/next";
|
|
6
|
+
import { McpServer as dt } from "@modelcontextprotocol/sdk/server/mcp.js";
|
|
7
|
+
import { ResourceTemplate as oo } from "@modelcontextprotocol/sdk/server/mcp.js";
|
|
8
|
+
import { UriTemplate as io } from "@modelcontextprotocol/sdk/shared/uriTemplate.js";
|
|
9
|
+
import { completable as co } from "@modelcontextprotocol/sdk/server/completable.js";
|
|
10
|
+
import { getDisplayName as uo } from "@modelcontextprotocol/sdk/shared/metadataUtils.js";
|
|
11
|
+
import { InMemoryTransport as Bt } from "@modelcontextprotocol/sdk/inMemory.js";
|
|
12
|
+
import { InMemoryTransport as ho } from "@modelcontextprotocol/sdk/inMemory.js";
|
|
13
|
+
import { SetLevelRequestSchema as De, SubscribeRequestSchema as Vt, UnsubscribeRequestSchema as Jt, ListResourcesRequestSchema as Wt, RootsListChangedNotificationSchema as Gt, CallToolResultSchema as Kt, ElicitRequestSchema as Yt, CreateMessageRequestSchema as Qt, ListRootsRequestSchema as Xt, ToolListChangedNotificationSchema as e2, PromptListChangedNotificationSchema as t2, ResourceListChangedNotificationSchema as r2, ResourceUpdatedNotificationSchema as n2, LoggingMessageNotificationSchema as o2, JSONRPCMessageSchema as Re } from "@modelcontextprotocol/sdk/types.js";
|
|
14
|
+
import { Client as ut } from "@modelcontextprotocol/sdk/client/index.js";
|
|
15
|
+
import { SSEClientTransport as Ie } from "@modelcontextprotocol/sdk/client/sse.js";
|
|
16
|
+
import { StreamableHTTPClientTransport as he } from "@modelcontextprotocol/sdk/client/streamableHttp.js";
|
|
17
|
+
import { WebSocketClientTransport as s2 } from "@modelcontextprotocol/sdk/client/websocket.js";
|
|
18
|
+
import He from "qrcode";
|
|
19
|
+
import { dynamicTool as i2, jsonSchema as a2, generateText as Fe, streamText as ge, stepCountIs as c2, tool as l2 } from "ai";
|
|
20
|
+
import { TypeValidationError as be, JSONParseError as Be, InvalidArgumentError as d2, AISDKError as oe } from "@ai-sdk/provider";
|
|
21
|
+
import * as Ve from "zod/v4";
|
|
22
22
|
import { z as i } from "zod/v4";
|
|
23
23
|
import { ZodFirstPartyTypeKind as w } from "zod/v3";
|
|
24
|
-
import { createOpenAI as
|
|
25
|
-
import { createDeepSeek as
|
|
26
|
-
class
|
|
24
|
+
import { createOpenAI as u2 } from "@ai-sdk/openai";
|
|
25
|
+
import { createDeepSeek as p2 } from "@ai-sdk/deepseek";
|
|
26
|
+
class kn {
|
|
27
27
|
constructor(e, r) {
|
|
28
28
|
const n = {
|
|
29
29
|
name: "web-mcp-server",
|
|
@@ -35,19 +35,19 @@ class xn {
|
|
|
35
35
|
completions: {},
|
|
36
36
|
logging: {}
|
|
37
37
|
};
|
|
38
|
-
this.server = new
|
|
38
|
+
this.server = new dt(e || n, r || { capabilities: o }), this.server.server.oninitialized = () => {
|
|
39
39
|
this.oninitialized?.();
|
|
40
40
|
}, this.server.server.onclose = () => {
|
|
41
41
|
this.onclose?.();
|
|
42
42
|
}, this.server.server.onerror = (s) => {
|
|
43
43
|
this.onerror?.(s);
|
|
44
|
-
}, this.server.server.setRequestHandler(
|
|
44
|
+
}, this.server.server.setRequestHandler(De, async () => ({}));
|
|
45
45
|
}
|
|
46
46
|
/**
|
|
47
47
|
* Connects the server to a transport via the specified option.
|
|
48
48
|
*/
|
|
49
49
|
async connect(e) {
|
|
50
|
-
return typeof e.start == "function" ? (this.transport = e, this.transport.onclose = void 0, this.transport.onerror = void 0, this.transport.onmessage = void 0) : (this.transport = new
|
|
50
|
+
return typeof e.start == "function" ? (this.transport = e, this.transport.onclose = void 0, this.transport.onerror = void 0, this.transport.onmessage = void 0) : (this.transport = new Me(e), await this.transport.listen()), await this.server.connect(this.transport), this.transport;
|
|
51
51
|
}
|
|
52
52
|
/**
|
|
53
53
|
* Closes the connection.
|
|
@@ -189,31 +189,31 @@ class xn {
|
|
|
189
189
|
* Registers a handler for the subscribe request.
|
|
190
190
|
*/
|
|
191
191
|
onSubscribe(e) {
|
|
192
|
-
this.server.server.setRequestHandler(
|
|
192
|
+
this.server.server.setRequestHandler(Vt, e);
|
|
193
193
|
}
|
|
194
194
|
/**
|
|
195
195
|
* Registers a handler for the unsubscribe request.
|
|
196
196
|
*/
|
|
197
197
|
onUnsubscribe(e) {
|
|
198
|
-
this.server.server.setRequestHandler(
|
|
198
|
+
this.server.server.setRequestHandler(Jt, e);
|
|
199
199
|
}
|
|
200
200
|
/**
|
|
201
201
|
* Registers a handler for the set log level request.
|
|
202
202
|
*/
|
|
203
203
|
onSetLogLevel(e) {
|
|
204
|
-
this.server.server.setRequestHandler(
|
|
204
|
+
this.server.server.setRequestHandler(De, e);
|
|
205
205
|
}
|
|
206
206
|
/**
|
|
207
207
|
* Registers a handler for the list tools request.
|
|
208
208
|
*/
|
|
209
209
|
onListResources(e) {
|
|
210
|
-
this.server.server.setRequestHandler(
|
|
210
|
+
this.server.server.setRequestHandler(Wt, e);
|
|
211
211
|
}
|
|
212
212
|
/**
|
|
213
213
|
* Registers a handler for the roots list changed notification.
|
|
214
214
|
*/
|
|
215
215
|
onRootsListChanged(e) {
|
|
216
|
-
this.server.server.setNotificationHandler(
|
|
216
|
+
this.server.server.setNotificationHandler(Gt, e);
|
|
217
217
|
}
|
|
218
218
|
/**
|
|
219
219
|
* Close the transport for window.addEventListener('pagehide')
|
|
@@ -222,8 +222,8 @@ class xn {
|
|
|
222
222
|
e.persisted || this.transport && typeof this.transport.close == "function" && await this.transport.close();
|
|
223
223
|
}
|
|
224
224
|
}
|
|
225
|
-
const
|
|
226
|
-
class
|
|
225
|
+
const Sn = (t, e) => new Me(t, e), Pn = () => jt(), Tn = (t) => t instanceof Me, Mn = (t) => t instanceof dt;
|
|
226
|
+
class h2 {
|
|
227
227
|
constructor(e, r) {
|
|
228
228
|
const n = {
|
|
229
229
|
name: "web-mcp-client",
|
|
@@ -233,7 +233,7 @@ class p2 {
|
|
|
233
233
|
sampling: {},
|
|
234
234
|
elicitation: {}
|
|
235
235
|
};
|
|
236
|
-
this.client = new
|
|
236
|
+
this.client = new ut(e || n, r || { capabilities: o }), this.client.onclose = () => {
|
|
237
237
|
this.onclose?.();
|
|
238
238
|
}, this.client.onerror = (s) => {
|
|
239
239
|
this.onerror?.(s);
|
|
@@ -245,28 +245,28 @@ class p2 {
|
|
|
245
245
|
async connect(e) {
|
|
246
246
|
if (typeof e.start == "function")
|
|
247
247
|
return this.transport = e, this.transport.onclose = void 0, this.transport.onerror = void 0, this.transport.onmessage = void 0, await this.client.connect(this.transport), { transport: this.transport, sessionId: this.transport.sessionId };
|
|
248
|
-
const { url: r, token: n, sessionId: o, type: s, agent: a, onError:
|
|
248
|
+
const { url: r, token: n, sessionId: o, type: s, agent: a, onError: c } = e;
|
|
249
249
|
if (a === !0) {
|
|
250
250
|
const u = { client: this.client, url: r, token: n, sessionId: o };
|
|
251
251
|
let g;
|
|
252
252
|
return await (async () => {
|
|
253
|
-
const { transport: f, sessionId: y } = s === "sse" ? await qt(u) : s === "socket" ? await
|
|
253
|
+
const { transport: f, sessionId: y } = s === "sse" ? await qt(u) : s === "socket" ? await Dt(u) : await Ht(u);
|
|
254
254
|
f.onerror = async (h) => {
|
|
255
|
-
|
|
255
|
+
c?.(h);
|
|
256
256
|
}, g = { transport: f, sessionId: y };
|
|
257
257
|
})(), g;
|
|
258
258
|
}
|
|
259
259
|
const d = new URL(r);
|
|
260
|
-
let
|
|
261
|
-
if (s === "channel" && (
|
|
262
|
-
const u = jt(n, o);
|
|
263
|
-
c = new Re(d, u), await this.client.connect(c);
|
|
264
|
-
}
|
|
265
|
-
if (s === "socket" && (c = new o2(new URL(`${r}?sessionId=${o}&token=${n}`)), c.sessionId = o, await this.client.connect(c)), typeof c > "u") {
|
|
260
|
+
let l;
|
|
261
|
+
if (s === "channel" && (l = new Ee(r), await this.client.connect(l)), s === "sse") {
|
|
266
262
|
const u = Zt(n, o);
|
|
267
|
-
|
|
263
|
+
l = new Ie(d, u), await this.client.connect(l);
|
|
264
|
+
}
|
|
265
|
+
if (s === "socket" && (l = new s2(new URL(`${r}?sessionId=${o}&token=${n}`)), l.sessionId = o, await this.client.connect(l)), typeof l > "u") {
|
|
266
|
+
const u = zt(n, o);
|
|
267
|
+
l = new he(d, u), await this.client.connect(l);
|
|
268
268
|
}
|
|
269
|
-
return this.transport =
|
|
269
|
+
return this.transport = l, { transport: this.transport, sessionId: this.transport.sessionId };
|
|
270
270
|
}
|
|
271
271
|
/**
|
|
272
272
|
* Closes the connection.
|
|
@@ -356,7 +356,7 @@ class p2 {
|
|
|
356
356
|
* Calls a tool on the server with the given parameters.
|
|
357
357
|
*/
|
|
358
358
|
async callTool(e, r) {
|
|
359
|
-
return await this.client.callTool(e,
|
|
359
|
+
return await this.client.callTool(e, Kt, r);
|
|
360
360
|
}
|
|
361
361
|
/**
|
|
362
362
|
* Lists all tools available on the server.
|
|
@@ -416,65 +416,65 @@ class p2 {
|
|
|
416
416
|
* Registers a handler for the elicitation request.
|
|
417
417
|
*/
|
|
418
418
|
onElicit(e) {
|
|
419
|
-
this.client.setRequestHandler(
|
|
419
|
+
this.client.setRequestHandler(Yt, e);
|
|
420
420
|
}
|
|
421
421
|
/**
|
|
422
422
|
* Registers a handler for the create LLM message request.
|
|
423
423
|
*/
|
|
424
424
|
onCreateMessage(e) {
|
|
425
|
-
this.client.setRequestHandler(
|
|
425
|
+
this.client.setRequestHandler(Qt, e);
|
|
426
426
|
}
|
|
427
427
|
/**
|
|
428
428
|
* Registers a handler for the list roots request.
|
|
429
429
|
*/
|
|
430
430
|
onListRoots(e) {
|
|
431
|
-
this.client.setRequestHandler(
|
|
431
|
+
this.client.setRequestHandler(Xt, e);
|
|
432
432
|
}
|
|
433
433
|
/**
|
|
434
434
|
* Registers a handler for the tool list changed notification.
|
|
435
435
|
*/
|
|
436
436
|
onToolListChanged(e) {
|
|
437
|
-
this.client.setNotificationHandler(
|
|
437
|
+
this.client.setNotificationHandler(e2, e);
|
|
438
438
|
}
|
|
439
439
|
/**
|
|
440
440
|
* Registers a handler for the prompt list changed notification.
|
|
441
441
|
*/
|
|
442
442
|
onPromptListChanged(e) {
|
|
443
|
-
this.client.setNotificationHandler(
|
|
443
|
+
this.client.setNotificationHandler(t2, e);
|
|
444
444
|
}
|
|
445
445
|
/**
|
|
446
446
|
* Registers a handler for the resource list changed notification.
|
|
447
447
|
*/
|
|
448
448
|
onResourceListChanged(e) {
|
|
449
|
-
this.client.setNotificationHandler(
|
|
449
|
+
this.client.setNotificationHandler(r2, e);
|
|
450
450
|
}
|
|
451
451
|
/**
|
|
452
452
|
* Registers a handler for the resource updated notification.
|
|
453
453
|
*/
|
|
454
454
|
onResourceUpdated(e) {
|
|
455
|
-
this.client.setNotificationHandler(
|
|
455
|
+
this.client.setNotificationHandler(n2, e);
|
|
456
456
|
}
|
|
457
457
|
/**
|
|
458
458
|
* Registers a handler for the logging message notification.
|
|
459
459
|
*/
|
|
460
460
|
onLoggingMessage(e) {
|
|
461
|
-
this.client.setNotificationHandler(
|
|
461
|
+
this.client.setNotificationHandler(o2, e);
|
|
462
462
|
}
|
|
463
463
|
/**
|
|
464
464
|
* Close the transport for window.addEventListener('pagehide')
|
|
465
465
|
*/
|
|
466
466
|
async onPagehide(e) {
|
|
467
|
-
e.persisted || (
|
|
467
|
+
e.persisted || (m2(this.transport) ? await this.transport.terminateSession() : this.transport && typeof this.transport.close == "function" && await this.transport.close());
|
|
468
468
|
}
|
|
469
469
|
}
|
|
470
|
-
const
|
|
470
|
+
const En = (t, e) => new Ie(t, e), Rn = (t, e) => new he(t, e), In = (t, e) => new Ee(t, e), An = (t) => t instanceof Ie, m2 = (t) => t instanceof he, On = (t) => t instanceof Ee, $n = (t) => t instanceof ut, D = (t, e, r) => {
|
|
471
471
|
window.postMessage({ type: t, direction: r, data: e }, "*");
|
|
472
|
-
},
|
|
472
|
+
}, Je = (t, e, r) => {
|
|
473
473
|
const n = async function(o) {
|
|
474
474
|
o.source === window && o.data.type === t && o.data.direction === r && await e(o.data.data);
|
|
475
475
|
};
|
|
476
476
|
return window.addEventListener("message", n), () => window.removeEventListener("message", n);
|
|
477
|
-
},
|
|
477
|
+
}, xe = (t, e, r) => {
|
|
478
478
|
if (r.endsWith("content"))
|
|
479
479
|
chrome.tabs.query({}, (n) => {
|
|
480
480
|
n.forEach((o) => {
|
|
@@ -483,23 +483,23 @@ const Tn = (t, e) => new Re(t, e), Mn = (t, e) => new ue(t, e), En = (t, e) => n
|
|
|
483
483
|
});
|
|
484
484
|
else
|
|
485
485
|
return chrome.runtime.sendMessage({ direction: r, type: t, data: e });
|
|
486
|
-
},
|
|
487
|
-
const o = (s, a,
|
|
486
|
+
}, Le = (t, e, r, n) => {
|
|
487
|
+
const o = (s, a, c) => {
|
|
488
488
|
if (s.type === t && s.direction === r && (!n || n && s.tabId === n)) {
|
|
489
489
|
const { data: d } = s;
|
|
490
|
-
e(d, a,
|
|
490
|
+
e(d, a, c), c(a);
|
|
491
491
|
}
|
|
492
492
|
};
|
|
493
493
|
return chrome.runtime.onMessage.addListener(o), () => chrome.runtime.onMessage.removeListener(o);
|
|
494
494
|
};
|
|
495
|
-
class
|
|
495
|
+
class f2 {
|
|
496
496
|
constructor(e) {
|
|
497
|
-
this._isStarted = !1, this._isClosed = !1, this.targetSessionId = e, this._messageListener =
|
|
497
|
+
this._isStarted = !1, this._isClosed = !1, this.targetSessionId = e, this._messageListener = Le(
|
|
498
498
|
"mcp-server-to-client",
|
|
499
499
|
(r) => {
|
|
500
500
|
try {
|
|
501
501
|
if (r.sessionId !== this.targetSessionId) return;
|
|
502
|
-
const n =
|
|
502
|
+
const n = Re.parse(r.mcpMessage);
|
|
503
503
|
this.onmessage?.(n);
|
|
504
504
|
} catch (n) {
|
|
505
505
|
console.log("【Client Transport】处理server消息错误:", n);
|
|
@@ -525,7 +525,7 @@ class m2 {
|
|
|
525
525
|
const n = chrome.sessionRegistry.get(this.targetSessionId);
|
|
526
526
|
this._throwError(() => !n, `【Client Transport】sessionRegistry中未找到${this.targetSessionId}`);
|
|
527
527
|
const o = n.tabIds[n.tabIds.length - 1];
|
|
528
|
-
|
|
528
|
+
xe(
|
|
529
529
|
"mcp-client-to-server",
|
|
530
530
|
{ sessionId: this.targetSessionId, tabId: o, mcpMessage: e },
|
|
531
531
|
"side->content"
|
|
@@ -541,13 +541,13 @@ class m2 {
|
|
|
541
541
|
}
|
|
542
542
|
}
|
|
543
543
|
}
|
|
544
|
-
const
|
|
544
|
+
const Ae = () => typeof crypto < "u" && crypto.randomUUID ? crypto.randomUUID() : "xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g, (t) => {
|
|
545
545
|
const e = Math.random() * 16 | 0;
|
|
546
546
|
return (t === "x" ? e : e & 3 | 8).toString(16);
|
|
547
547
|
});
|
|
548
|
-
class
|
|
548
|
+
class Un {
|
|
549
549
|
constructor(e = null) {
|
|
550
|
-
this._isStarted = !1, this._isClosed = !1, this._lastRegistration = null, this.sessionId = e ||
|
|
550
|
+
this._isStarted = !1, this._isClosed = !1, this._lastRegistration = null, this.sessionId = e || Ae(), this._messageListener1 = Je(
|
|
551
551
|
"sidepanel-ready-to-page",
|
|
552
552
|
() => {
|
|
553
553
|
this._lastRegistration && this._isStarted && this.notifyRegistration(this._lastRegistration).catch((r) => {
|
|
@@ -555,12 +555,12 @@ class On {
|
|
|
555
555
|
});
|
|
556
556
|
},
|
|
557
557
|
"content->page"
|
|
558
|
-
), this._messageListener2 =
|
|
558
|
+
), this._messageListener2 = Je(
|
|
559
559
|
"mcp-client-to-server-to-page",
|
|
560
560
|
(r) => {
|
|
561
561
|
if (r.sessionId !== this.sessionId) return;
|
|
562
562
|
console.log("【Page Svr Transport】 即将处理 mcpMessage", r.mcpMessage);
|
|
563
|
-
const n =
|
|
563
|
+
const n = Re.parse(r.mcpMessage);
|
|
564
564
|
this.onmessage?.(n), r.mcpMessage.params?.name && D(
|
|
565
565
|
"update-page-app-message",
|
|
566
566
|
{ status: "run", message: r.mcpMessage.params?.name },
|
|
@@ -630,9 +630,9 @@ class On {
|
|
|
630
630
|
}
|
|
631
631
|
}
|
|
632
632
|
}
|
|
633
|
-
class
|
|
633
|
+
class Nn {
|
|
634
634
|
constructor(e = null, r) {
|
|
635
|
-
this._isStarted = !1, this._isClosed = !1, this._lastRegistration = null, this.sessionId = e ||
|
|
635
|
+
this._isStarted = !1, this._isClosed = !1, this._lastRegistration = null, this.sessionId = e || Ae(), this.tabId = r, Le(
|
|
636
636
|
"sidepanel-ready",
|
|
637
637
|
() => {
|
|
638
638
|
this._lastRegistration && this._isStarted && this.notifyRegistration(this._lastRegistration).catch((n) => {
|
|
@@ -654,13 +654,13 @@ class $n {
|
|
|
654
654
|
async start() {
|
|
655
655
|
if (console.log("【Content Svr Transport】 启动 start", this.sessionId), !this._isStarted) {
|
|
656
656
|
if (this._isClosed) throw new Error("【Content Svr Transport】 已关闭,无法重新启动");
|
|
657
|
-
|
|
657
|
+
Le(
|
|
658
658
|
"mcp-client-to-server",
|
|
659
659
|
(e) => {
|
|
660
660
|
if (!(e.sessionId !== this.sessionId || e.tabId !== this.tabId))
|
|
661
661
|
try {
|
|
662
662
|
console.log("【Content Svr Transport】 即将处理 mcpMessage", e.mcpMessage);
|
|
663
|
-
const r =
|
|
663
|
+
const r = Re.parse(e.mcpMessage);
|
|
664
664
|
this.onmessage?.(r), e.mcpMessage.params?.name && D(
|
|
665
665
|
"update-page-app-message",
|
|
666
666
|
{ status: "run", message: e.mcpMessage.params?.name },
|
|
@@ -680,7 +680,7 @@ class $n {
|
|
|
680
680
|
async send(e, r) {
|
|
681
681
|
this._throwError(() => !this._isStarted, "【Content Svr Transport】 未启动,无法发送消息"), this._throwError(() => this._isClosed, "【Content Svr Transport】 已关闭,无法发送消息");
|
|
682
682
|
try {
|
|
683
|
-
console.log("【Content Svr Transport】 发送消息到 MCP Client", e),
|
|
683
|
+
console.log("【Content Svr Transport】 发送消息到 MCP Client", e), xe(
|
|
684
684
|
"mcp-server-to-client",
|
|
685
685
|
{
|
|
686
686
|
sessionId: this.sessionId,
|
|
@@ -699,7 +699,7 @@ class $n {
|
|
|
699
699
|
}
|
|
700
700
|
/** 通知 Sidepanel 此 Server 已启动并准备接受连接 */
|
|
701
701
|
async notifyRegistration(e) {
|
|
702
|
-
this._isStarted && (this._lastRegistration = e,
|
|
702
|
+
this._isStarted && (this._lastRegistration = e, xe(
|
|
703
703
|
"mcp-server-register",
|
|
704
704
|
{
|
|
705
705
|
sessionId: this.sessionId,
|
|
@@ -721,7 +721,7 @@ class $n {
|
|
|
721
721
|
}
|
|
722
722
|
}
|
|
723
723
|
}
|
|
724
|
-
class
|
|
724
|
+
class g2 {
|
|
725
725
|
constructor(e, { size: r = 200, margin: n = 4, color: o = "#000", bgColor: s = "#fff" }) {
|
|
726
726
|
this.value = e, this.size = r, this.margin = n, this.color = o, this.bgColor = s;
|
|
727
727
|
}
|
|
@@ -739,18 +739,18 @@ class f2 {
|
|
|
739
739
|
}
|
|
740
740
|
/** 生成二维码的 Data URL(base64 图片) */
|
|
741
741
|
async toDataURL() {
|
|
742
|
-
return
|
|
742
|
+
return He.toDataURL(this.value, this.qrCodeOption);
|
|
743
743
|
}
|
|
744
744
|
/** 渲染二维码到指定的 canvas 元素 */
|
|
745
745
|
async toCanvas(e) {
|
|
746
|
-
return
|
|
746
|
+
return He.toCanvas(e, this.value, this.qrCodeOption);
|
|
747
747
|
}
|
|
748
748
|
/** 渲染二维码到指定的 img 元素 */
|
|
749
749
|
async toImage(e) {
|
|
750
750
|
e.src = await this.toDataURL();
|
|
751
751
|
}
|
|
752
752
|
}
|
|
753
|
-
const
|
|
753
|
+
const y2 = {
|
|
754
754
|
content: "",
|
|
755
755
|
placement: "top",
|
|
756
756
|
trigger: "hover",
|
|
@@ -759,10 +759,10 @@ const g2 = {
|
|
|
759
759
|
container: document.body,
|
|
760
760
|
className: "tiny-remoter-native-tooltip"
|
|
761
761
|
};
|
|
762
|
-
class
|
|
762
|
+
class w2 {
|
|
763
763
|
constructor(e, r = {}) {
|
|
764
764
|
if (this.tip = null, this.showTimer = 0, this.hideTimer = 0, this.clickOutside = null, this.el = typeof e == "string" ? document.querySelector(e) : e, !this.el) throw new Error("Tooltip: invalid element");
|
|
765
|
-
this.opts = { ...
|
|
765
|
+
this.opts = { ...y2, ...r }, this.bindEvents();
|
|
766
766
|
}
|
|
767
767
|
/* 公开 API */
|
|
768
768
|
open() {
|
|
@@ -808,9 +808,9 @@ class y2 {
|
|
|
808
808
|
this.applyStyle(this.calcStyle("top"));
|
|
809
809
|
}
|
|
810
810
|
calcStyle(e) {
|
|
811
|
-
const r = this.el.getBoundingClientRect(), n = this.tip.getBoundingClientRect(), o = window.pageYOffset || document.documentElement.scrollTop, s = window.pageXOffset || document.documentElement.scrollLeft, a = 6, [
|
|
812
|
-
let
|
|
813
|
-
return
|
|
811
|
+
const r = this.el.getBoundingClientRect(), n = this.tip.getBoundingClientRect(), o = window.pageYOffset || document.documentElement.scrollTop, s = window.pageXOffset || document.documentElement.scrollLeft, a = 6, [c, d = "center"] = e.split("-");
|
|
812
|
+
let l = 0, u = 0;
|
|
813
|
+
return c === "top" ? l = r.top + o - n.height - a : c === "bottom" ? l = r.bottom + o + a : c === "left" ? u = r.left + s - n.width - a : c === "right" && (u = r.right + s + a), (c === "top" || c === "bottom") && (d === "start" ? u = r.left + s : d === "end" ? u = r.right + s - n.width : u = (r.left + r.right) / 2 + s - n.width / 2), (c === "left" || c === "right") && (d === "start" ? l = r.top + o : d === "end" ? l = r.bottom + o - n.height : l = (r.top + r.bottom) / 2 + o - n.height / 2), { top: Math.round(l), left: Math.round(u) };
|
|
814
814
|
}
|
|
815
815
|
applyStyle({ top: e, left: r }) {
|
|
816
816
|
Object.assign(this.tip.style, {
|
|
@@ -848,11 +848,11 @@ class y2 {
|
|
|
848
848
|
return !!this.tip?.parentNode;
|
|
849
849
|
}
|
|
850
850
|
}
|
|
851
|
-
const
|
|
851
|
+
const We = "tiny-remoter-native-tooltip-style";
|
|
852
852
|
(() => {
|
|
853
|
-
if (document.getElementById(
|
|
853
|
+
if (document.getElementById(We)) return;
|
|
854
854
|
const t = document.createElement("style");
|
|
855
|
-
t.id =
|
|
855
|
+
t.id = We, t.textContent = `
|
|
856
856
|
.tiny-remoter-native-tooltip {
|
|
857
857
|
position: absolute;
|
|
858
858
|
z-index: 9999;
|
|
@@ -901,7 +901,7 @@ const Ve = "tiny-remoter-native-tooltip-style";
|
|
|
901
901
|
}
|
|
902
902
|
`, document.head.appendChild(t);
|
|
903
903
|
})();
|
|
904
|
-
const w2 = "data:image/svg+xml,%3csvg%20viewBox='0%200%2040%2039.9692'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%20width='40.000000'%20height='39.969238'%20fill='none'%20customFrame='url(%23clipPath_3)'%3e%3cdefs%3e%3cclipPath%20id='clipPath_3'%3e%3crect%20width='40.000000'%20height='39.969238'%20x='0.000000'%20y='0.000000'%20rx='12.000000'%20fill='rgb(255,255,255)'%20/%3e%3c/clipPath%3e%3cclipPath%20id='clipPath_4'%3e%3crect%20width='24.000000'%20height='24.000000'%20x='8.000000'%20y='7.984619'%20fill='rgb(255,255,255)'%20/%3e%3c/clipPath%3e%3cclipPath%20id='clipPath_5'%3e%3crect%20width='20.000000'%20height='20.000000'%20x='10.000000'%20y='9.984619'%20fill='rgb(255,255,255)'%20/%3e%3c/clipPath%3e%3cclipPath%20id='clipPath_6'%3e%3crect%20width='20.000000'%20height='20.000000'%20x='10.000000'%20y='9.984619'%20fill='rgb(255,255,255)'%20/%3e%3c/clipPath%3e%3cclipPath%20id='clipPath_7'%3e%3crect%20width='21.666666'%20height='13.333333'%20x='20.000000'%20y='9.984619'%20rx='6.666667'%20fill='rgb(255,255,255)'%20/%3e%3c/clipPath%3e%3cclipPath%20id='clipPath_8'%3e%3crect%20width='6.666667'%20height='6.666667'%20x='23.333496'%20y='9.984619'%20fill='rgb(255,255,255)'%20/%3e%3c/clipPath%3e%3c/defs%3e%3crect%20id='2'%20width='40.000000'%20height='39.969238'%20x='0.000000'%20y='0.000000'%20rx='12.000000'%20fill='rgb(239,246,255)'%20/%3e%3cg%20id='物业'%20clip-path='url(%23clipPath_4)'%20customFrame='url(%23clipPath_4)'%3e%3crect%20id='物业'%20width='24.000000'%20height='24.000000'%20x='8.000000'%20y='7.984619'%20/%3e%3cg%20id='物业服务'%3e%3cg%20id='00公共/红点/图标+红点'%20customFrame='url(%23clipPath_5)'%3e%3crect%20id='00公共/红点/图标+红点'%20width='20.000000'%20height='20.000000'%20x='10.000000'%20y='9.984619'%20/%3e%3cg%20id='common_chats_line'%20customFrame='url(%23clipPath_6)'%3e%3crect%20id='common_chats_line'%20width='20.000000'%20height='20.000000'%20x='10.000000'%20y='9.984619'%20/%3e%3cpath%20id='形状'%20d='M28.3332%2019.9847C28.3332%2015.3823%2024.6022%2011.6514%2019.9998%2011.6514C15.3975%2011.6514%2011.6665%2015.3823%2011.6665%2019.9847C11.6665%2024.5871%2015.3975%2028.318%2019.9998%2028.318C21.0018%2028.318%2021.9624%2028.1412%2022.8522%2027.8171L26.581%2028.1578C26.7205%2028.1706%2026.8611%2028.1598%2026.9971%2028.1259C27.6669%2027.959%2028.0746%2027.2806%2027.9077%2026.6108L27.2716%2024.0578C27.9477%2022.8535%2028.3332%2021.4641%2028.3332%2019.9847ZM19.9998%2013.1514C16.2259%2013.1514%2013.1665%2016.2108%2013.1665%2019.9847C13.1665%2023.7586%2016.2259%2026.818%2019.9998%2026.818C20.8089%2026.818%2021.5967%2026.678%2022.3388%2026.4077C22.505%2026.3471%2022.6803%2026.3166%2022.8565%2026.3171L22.9887%2026.3233L26.3665%2026.6322L25.8161%2024.4205C25.7352%2024.0958%2025.7655%2023.7548%2025.8997%2023.4512L25.9636%2023.3236C26.5311%2022.3126%2026.8332%2021.1723%2026.8332%2019.9847C26.8332%2016.2108%2023.7738%2013.1514%2019.9998%2013.1514ZM23.1152%2021.2468C23.352%2020.9069%2023.2684%2020.4394%2022.9286%2020.2026C22.5887%2019.9659%2022.1212%2020.0494%2021.8845%2020.3893C21.2894%2021.2433%2020.4268%2021.7347%2019.5102%2021.7347C18.9513%2021.7347%2018.4132%2021.554%2017.9375%2021.2122C17.6011%2020.9705%2017.1325%2021.0472%2016.8908%2021.3836C16.6491%2021.7199%2016.7258%2022.1886%2017.0622%2022.4303C17.7879%2022.9518%2018.6305%2023.2347%2019.5102%2023.2347C20.9394%2023.2347%2022.2505%2022.4878%2023.1152%2021.2468Z'%20fill='rgb(65,142,255)'%20fill-rule='evenodd'%20/%3e%3c/g%3e%3cg%20id='00公共/3位数红点'%20opacity='0'%20customFrame='url(%23clipPath_7)'%3e%3crect%20id='00公共/3位数红点'%20width='21.666666'%20height='13.333333'%20x='20.000000'%20y='9.984619'%20rx='6.666667'%20opacity='0'%20fill='rgb(243,111,100)'%20/%3e%3cpath%20id='文本'%20d='M26.0421%2013.4421C26.4259%2013.4421%2026.7677%2013.5255%2027.0675%2013.6923C27.3672%2013.8591%2027.6005%2014.0931%2027.7673%2014.3942C27.9342%2014.694%2028.0176%2015.0351%2028.0176%2015.4176C28.0176%2015.7173%2027.9633%2015.994%2027.8548%2016.2476C27.7463%2016.4999%2027.5673%2016.8315%2027.3177%2017.2425L25.859%2019.6432L25.0167%2019.6432L26.276%2017.5924C26.3534%2017.4704%2026.4307%2017.3564%2026.508%2017.2507C26.3357%2017.3063%2026.1445%2017.3341%2025.9342%2017.3341C25.5721%2017.3341%2025.2493%2017.2479%2024.9658%2017.0757C24.6837%2016.9034%2024.4633%2016.6701%2024.3046%2016.3758C24.1459%2016.0815%2024.0666%2015.7566%2024.0666%2015.4013C24.0666%2015.0351%2024.1513%2014.7021%2024.3209%2014.4023C24.4904%2014.1012%2024.7264%2013.8659%2025.0289%2013.6964C25.3314%2013.5268%2025.6691%2013.4421%2026.0421%2013.4421ZM26.0421%2016.6505C26.4029%2016.6505%2026.6904%2016.5325%2026.9047%2016.2965C27.119%2016.0605%2027.2262%2015.7539%2027.2262%2015.3769C27.2262%2014.9985%2027.119%2014.694%2026.9047%2014.4634C26.6904%2014.2328%2026.4029%2014.1175%2026.0421%2014.1175C25.6867%2014.1175%2025.4019%2014.2342%2025.1876%2014.4674C24.9733%2014.7007%2024.8661%2015.0039%2024.8661%2015.3769C24.8661%2015.7539%2024.9719%2016.0605%2025.1835%2016.2965C25.3951%2016.5325%2025.6813%2016.6505%2026.0421%2016.6505ZM30.7921%2013.4421C31.1759%2013.4421%2031.5177%2013.5255%2031.8175%2013.6923C32.1172%2013.8591%2032.3505%2014.0931%2032.5173%2014.3942C32.6842%2014.694%2032.7676%2015.0351%2032.7676%2015.4176C32.7676%2015.7173%2032.7133%2015.994%2032.6048%2016.2476C32.4963%2016.4999%2032.3173%2016.8315%2032.0677%2017.2425L30.609%2019.6432L29.7667%2019.6432L31.026%2017.5924C31.1034%2017.4704%2031.1807%2017.3564%2031.258%2017.2507C31.0857%2017.3063%2030.8945%2017.3341%2030.6842%2017.3341C30.3221%2017.3341%2029.9993%2017.2479%2029.7158%2017.0757C29.4337%2016.9034%2029.2133%2016.6701%2029.0546%2016.3758C28.8959%2016.0815%2028.8166%2015.7566%2028.8166%2015.4013C28.8166%2015.0351%2028.9013%2014.7021%2029.0709%2014.4023C29.2404%2014.1012%2029.4764%2013.8659%2029.7789%2013.6964C30.0814%2013.5268%2030.4191%2013.4421%2030.7921%2013.4421ZM30.7921%2016.6505C31.1529%2016.6505%2031.4404%2016.5325%2031.6547%2016.2965C31.869%2016.0605%2031.9762%2015.7539%2031.9762%2015.3769C31.9762%2014.9985%2031.869%2014.694%2031.6547%2014.4634C31.4404%2014.2328%2031.1529%2014.1175%2030.7921%2014.1175C30.4367%2014.1175%2030.1519%2014.2342%2029.9376%2014.4674C29.7233%2014.7007%2029.6161%2015.0039%2029.6161%2015.3769C29.6161%2015.7539%2029.7219%2016.0605%2029.9335%2016.2965C30.1451%2016.5325%2030.4313%2016.6505%2030.7921%2016.6505ZM35.2674%2014.6851L35.9001%2014.6851L35.9001%2016.3188L37.5339%2016.3188L37.5339%2016.9516L35.9001%2016.9516L35.9001%2018.5853L35.2674%2018.5853L35.2674%2016.9516L33.6337%2016.9516L33.6337%2016.3188L35.2674%2016.3188L35.2674%2014.6851Z'%20fill='rgb(255,255,255)'%20fill-rule='nonzero'%20/%3e%3c/g%3e%3cg%20id='00公共/单红点'%20opacity='0'%20customFrame='url(%23clipPath_8)'%3e%3crect%20id='00公共/单红点'%20width='6.666667'%20height='6.666667'%20x='23.333496'%20y='9.984619'%20opacity='0'%20fill='rgb(255,255,255)'%20fill-opacity='0'%20/%3e%3ccircle%20id='红点'%20cx='26.6668301'%20cy='13.3179522'%20r='3.33333325'%20fill='rgb(243,111,100)'%20/%3e%3c/g%3e%3c/g%3e%3c/g%3e%3c/g%3e%3c/svg%3e", v2 = "data:image/svg+xml,%3csvg%20viewBox='0%200%2040%2040'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%20width='40.000000'%20height='40.000000'%20fill='none'%20customFrame='url(%23clipPath_12)'%3e%3cdefs%3e%3cclipPath%20id='clipPath_12'%3e%3crect%20width='40.000000'%20height='40.000000'%20x='0.000000'%20y='0.000000'%20rx='12.000000'%20fill='rgb(255,255,255)'%20/%3e%3c/clipPath%3e%3cclipPath%20id='clipPath_13'%3e%3crect%20width='24.000000'%20height='24.000000'%20x='8.000000'%20y='8.000000'%20fill='rgb(255,255,255)'%20/%3e%3c/clipPath%3e%3cclipPath%20id='clipPath_14'%3e%3crect%20width='20.000000'%20height='20.000000'%20x='10.000000'%20y='10.000000'%20fill='rgb(255,255,255)'%20/%3e%3c/clipPath%3e%3c/defs%3e%3crect%20id='4'%20width='40.000000'%20height='40.000000'%20x='0.000000'%20y='0.000000'%20rx='12.000000'%20fill='rgb(234,255,244)'%20/%3e%3cg%20id='我的信息'%20clip-path='url(%23clipPath_13)'%20customFrame='url(%23clipPath_13)'%3e%3crect%20id='我的信息'%20width='24.000000'%20height='24.000000'%20x='8.000000'%20y='8.000000'%20/%3e%3cg%20id='组合%208'%20customFrame='url(%23clipPath_14)'%3e%3crect%20id='组合%208'%20width='20.000000'%20height='20.000000'%20x='10.000000'%20y='10.000000'%20/%3e%3cpath%20id='合并'%20d='M28.4994%2012.3142C28.4994%2012.2578%2028.4937%2012.2018%2028.4825%2012.1465C28.4713%2012.0911%2028.4547%2012.0373%2028.4327%2011.9851C28.4107%2011.933%2028.3836%2011.8835%2028.3516%2011.8365C28.3197%2011.7896%2028.2834%2011.7461%2028.2427%2011.7062C28.202%2011.6663%2028.1579%2011.6307%2028.1101%2011.5993C28.0622%2011.568%2028.0117%2011.5415%2027.9585%2011.5199C27.9054%2011.4983%2027.8506%2011.4819%2027.7942%2011.4709C27.7378%2011.4599%2027.6806%2011.4544%2027.6231%2011.4544L24.1832%2011.5199L24.1832%2010L29.0796%2010C29.1472%2010%2029.2143%2010.0065%2029.2806%2010.0194C29.347%2010.0324%2029.4114%2010.0516%2029.4739%2010.077C29.5364%2010.1024%2029.5961%2010.1336%2029.6523%2010.1705C29.7086%2010.2074%2029.7605%2010.2493%2029.8084%2010.2963C29.8562%2010.3433%2029.8991%2010.3944%2029.9367%2010.4496C29.9743%2010.5048%2030.006%2010.5631%2030.0319%2010.6244C30.0578%2010.6858%2030.0773%2010.7491%2030.0905%2010.8142C30.1037%2010.8794%2030.1104%2010.9451%2030.1104%2011.0115L30.1832%2014.4522L28.4992%2014.5L28.4994%2012.3142ZM11.6995%2012.3143C11.6995%2012.2579%2011.7051%2012.2019%2011.7163%2012.1466C11.7275%2012.0912%2011.7441%2012.0374%2011.7661%2011.9852C11.7882%2011.9331%2011.8152%2011.8836%2011.8472%2011.8366C11.8791%2011.7897%2011.9155%2011.7462%2011.9562%2011.7063C11.9968%2011.6664%2012.0409%2011.6308%2012.0888%2011.5994C12.1366%2011.5681%2012.1871%2011.5416%2012.2403%2011.52C12.2934%2011.4984%2012.3482%2011.482%2012.4046%2011.471C12.4611%2011.46%2012.5182%2011.4545%2012.5758%2011.4545L16.0157%2011.52L16.0157%2010.0001L11.1193%2010.0001C11.0516%2010.0001%2010.9846%2010.0066%2010.9182%2010.0196C10.8518%2010.0325%2010.7874%2010.0517%2010.7249%2010.0771C10.6624%2010.1025%2010.6028%2010.1337%2010.5465%2010.1706C10.4902%2010.2075%2010.4383%2010.2494%2010.3904%2010.2964C10.3426%2010.3434%2010.2997%2010.3945%2010.2621%2010.4497C10.2245%2010.5049%2010.1929%2010.5632%2010.167%2010.6245C10.1411%2010.6859%2010.1215%2010.7492%2010.1083%2010.8143C10.0951%2010.8795%2010.0885%2010.9452%2010.0884%2011.0116L10.0157%2014.4523L11.6997%2014.5L11.6995%2012.3143ZM25.3135%2021.8051L25.3135%2022.8167C25.7656%2022.8929%2026.2209%2022.9249%2026.6792%2022.9127C28.3381%2022.9127%2029.1675%2022.326%2029.1675%2021.1527C29.1733%2020.9869%2029.151%2020.825%2029.1006%2020.667C29.0503%2020.509%2028.9747%2020.3641%2028.8742%2020.2322C28.767%2020.1025%2028.6403%2019.9963%2028.4938%2019.9134C28.3474%2019.8306%2028.191%2019.7767%2028.0246%2019.7517L28.0246%2019.7011C28.0971%2019.6839%2028.1676%2019.6606%2028.236%2019.6311C28.3044%2019.6016%2028.3698%2019.5665%2028.4321%2019.5257C28.4944%2019.4848%2028.5526%2019.4389%2028.6069%2019.3879C28.6613%2019.3369%2028.7109%2019.2816%2028.7556%2019.222C28.8003%2019.1624%2028.8394%2019.0994%2028.8732%2019.033C28.9069%2018.9665%2028.9346%2018.8977%2028.9564%2018.8265C28.9782%2018.7552%2028.9937%2018.6826%2029.0028%2018.6086C29.0119%2018.5347%2029.0145%2018.4605%2029.0107%2018.3861C29.0217%2018.2675%2029.0176%2018.1495%2028.9984%2018.0319C28.9791%2017.9144%2028.9454%2017.8012%2028.8971%2017.6923C28.8489%2017.5834%2028.7875%2017.4823%2028.7134%2017.3891C28.6393%2017.2959%2028.5547%2017.2135%2028.4595%2017.1419C28.219%2017.0003%2027.963%2016.8972%2027.6915%2016.8326C27.4199%2016.7679%2027.1449%2016.7446%2026.8664%2016.7626C26.6258%2016.7621%2026.3864%2016.7791%2026.1482%2016.8132C25.9479%2016.8386%2025.7504%2016.8791%2025.5563%2016.9346L25.5563%2017.8854C25.743%2017.8264%2025.9337%2017.7842%2026.128%2017.759C26.3276%2017.73%2026.5282%2017.7148%2026.7298%2017.7134C27.0252%2017.6949%2027.3049%2017.7523%2027.5692%2017.8854C27.6168%2017.9161%2027.6595%2017.9525%2027.6972%2017.9947C27.7348%2018.037%2027.766%2018.0835%2027.791%2018.1343C27.816%2018.1851%2027.8337%2018.2383%2027.8441%2018.294C27.8545%2018.3496%2027.8573%2018.4056%2027.8525%2018.462C27.8566%2018.5278%2027.8514%2018.5927%2027.8367%2018.657C27.822%2018.7212%2027.7986%2018.7821%2027.7663%2018.8395C27.734%2018.897%2027.694%2018.9487%2027.6468%2018.9946C27.5995%2019.0405%2027.5468%2019.0787%2027.4885%2019.1093C27.1544%2019.2631%2026.8037%2019.3306%2026.4364%2019.3117L25.9862%2019.3117L25.9862%2020.1917L26.4466%2020.1917C26.8409%2020.1669%2027.2202%2020.2309%2027.5845%2020.3839C27.6459%2020.4167%2027.7011%2020.4576%2027.7505%2020.5066C27.7999%2020.5556%2027.8412%2020.6107%2027.8745%2020.6718C27.9077%2020.733%2027.9315%2020.7976%2027.9458%2020.8656C27.9602%2020.9337%2027.9644%2021.0024%2027.9587%2021.0717C27.9648%2021.1402%2027.9612%2021.2083%2027.9478%2021.2757C27.9344%2021.3432%2027.912%2021.4074%2027.8801%2021.4683C27.8483%2021.5293%2027.8086%2021.5846%2027.7609%2021.6341C27.7132%2021.6837%2027.6593%2021.7254%2027.5996%2021.7596C27.2884%2021.9045%2026.9613%2021.9685%2026.6184%2021.9518C26.1786%2021.9465%2025.7436%2021.8977%2025.3135%2021.8051ZM21.3382%2018.6238C21.3445%2018.5593%2021.343%2018.495%2021.3335%2018.4308C21.3241%2018.3667%2021.3069%2018.3046%2021.2822%2018.2447C21.2575%2018.1847%2021.226%2018.1287%2021.1876%2018.0765C21.1492%2018.0242%2021.1049%2017.9774%2021.055%2017.936C20.9359%2017.8608%2020.808%2017.806%2020.6714%2017.7714C20.5349%2017.7368%2020.3964%2017.7242%2020.2558%2017.7337C19.8009%2017.7395%2019.356%2017.8087%2018.9208%2017.9411L18.9208%2016.9598C19.4252%2016.8181%2019.9393%2016.7524%2020.4633%2016.7626C20.7322%2016.7484%2020.9964%2016.7773%2021.256%2016.8491C21.5156%2016.9209%2021.7571%2017.032%2021.9806%2017.1824C22.0729%2017.2601%2022.1548%2017.3474%2022.2263%2017.4446C22.2978%2017.5418%2022.3567%2017.646%2022.4034%2017.7573C22.45%2017.8686%2022.483%2017.9838%2022.5021%2018.1029C22.5213%2018.222%2022.5261%2018.3417%2022.5167%2018.462C22.5245%2018.7882%2022.4655%2019.1017%2022.3396%2019.4027C22.1879%2019.7384%2021.984%2020.0384%2021.7277%2020.3029C21.3021%2020.7337%2020.8502%2021.135%2020.3721%2021.5067L19.9928%2021.8051L19.9928%2021.8759L22.6938%2021.8759L22.6938%2022.8419L18.5464%2022.8419L18.5464%2021.7697C19.2882%2021.1796%2019.8579%2020.6975%2020.2558%2020.3232C20.574%2020.0432%2020.8523%2019.728%2021.0905%2019.3774C21.1675%2019.2665%2021.2269%2019.1469%2021.2691%2019.0187C21.3113%2018.8904%2021.3344%2018.7588%2021.3382%2018.6238ZM12.3102%2017.2127L12.3102%2018.1939L13.7769%2017.9107L13.7769%2022.8419L14.9605%2022.8419L14.9605%2016.8486L14.0957%2016.8486L12.3102%2017.2127ZM28.5524%2028.0475C28.5524%2028.104%2028.5467%2028.1599%2028.5353%2028.2152C28.5239%2028.2706%2028.5071%2028.3244%2028.4849%2028.3766C28.4626%2028.4287%2028.4352%2028.4782%2028.4028%2028.5252C28.3705%2028.5721%2028.3337%2028.6156%2028.2925%2028.6555C28.2513%2028.6954%2028.2067%2028.731%2028.1583%2028.7624C28.1098%2028.7937%2028.0587%2028.8202%2028.0049%2028.8418C27.9511%2028.8634%2027.8957%2028.8798%2027.8385%2028.8908C27.7814%2028.9018%2027.7235%2028.9073%2027.6653%2028.9073L24.1832%2028.8418L24.1832%2030.3617L29.1397%2030.3617C29.2082%2030.3617%2029.276%2030.3552%2029.3432%2030.3423C29.4104%2030.3293%2029.4756%2030.3101%2029.5389%2030.2847C29.6022%2030.2593%2029.6625%2030.2281%2029.7195%2030.1912C29.7765%2030.1543%2029.829%2030.1124%2029.8774%2030.0654C29.9259%2030.0184%2029.9693%2029.9673%2030.0074%2029.9121C30.0454%2029.8569%2030.0774%2029.7986%2030.1037%2029.7373C30.1299%2029.6759%2030.1497%2029.6126%2030.163%2029.5475C30.1764%2029.4823%2030.1831%2029.4166%2030.1832%2029.3502L30.1832%2026.0478L28.4785%2026L28.5524%2028.0475ZM11.6308%2028.0099C11.6308%2028.0664%2011.6365%2028.1223%2011.6479%2028.1777C11.6592%2028.233%2011.676%2028.2868%2011.6983%2028.339C11.7206%2028.3911%2011.748%2028.4406%2011.7803%2028.4876C11.8127%2028.5345%2011.8495%2028.578%2011.8906%2028.6179C11.9318%2028.6578%2011.9765%2028.6934%2012.0249%2028.7248C12.0733%2028.7562%2012.1244%2028.7826%2012.1783%2028.8042C12.2321%2028.8259%2012.2875%2028.8422%2012.3446%2028.8532C12.4017%2028.8642%2012.4596%2028.8697%2012.5178%2028.8698L16%2028.8042L16%2030.3241L11.0435%2030.3241C10.975%2030.3241%2010.9071%2030.3176%2010.8399%2030.3047C10.7727%2030.2917%2010.7076%2030.2725%2010.6443%2030.2471C10.581%2030.2217%2010.5206%2030.1906%2010.4637%2030.1537C10.4067%2030.1168%2010.3542%2030.0748%2010.3057%2030.0278C10.2573%2029.9809%2010.2138%2029.9298%2010.1758%2029.8745C10.1377%2029.8193%2010.1057%2029.7611%2010.0795%2029.6997C10.0533%2029.6383%2010.0335%2029.575%2010.0201%2029.5099C10.0068%2029.4448%2010%2029.379%2010%2029.3126L10%2026.0478L11.7047%2026L11.6308%2028.0099Z'%20fill='rgb(14,191,241)'%20fill-rule='evenodd'%20/%3e%3c/g%3e%3c/g%3e%3c/svg%3e", C2 = "data:image/svg+xml,%3csvg%20viewBox='0%200%2040%2040'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%20width='40.000000'%20height='40.000000'%20fill='none'%20customFrame='url(%23clipPath_9)'%3e%3cdefs%3e%3cclipPath%20id='clipPath_9'%3e%3crect%20width='40.000000'%20height='40.000000'%20x='0.000000'%20y='0.000000'%20rx='12.000000'%20fill='rgb(255,255,255)'%20/%3e%3c/clipPath%3e%3cclipPath%20id='clipPath_10'%3e%3crect%20width='24.000000'%20height='24.000000'%20x='8.000000'%20y='8.000000'%20fill='rgb(255,255,255)'%20/%3e%3c/clipPath%3e%3cclipPath%20id='clipPath_11'%3e%3crect%20width='20.000000'%20height='20.000000'%20x='10.000000'%20y='10.000000'%20fill='rgb(255,255,255)'%20/%3e%3c/clipPath%3e%3c/defs%3e%3crect%20id='3'%20width='40.000000'%20height='40.000000'%20x='0.000000'%20y='0.000000'%20rx='12.000000'%20fill='rgb(236,250,254)'%20/%3e%3cg%20id='画板%202310'%20customFrame='url(%23clipPath_10)'%3e%3crect%20id='画板%202310'%20width='24.000000'%20height='24.000000'%20x='8.000000'%20y='8.000000'%20fill='rgb(255,255,255)'%20fill-opacity='0'%20/%3e%3cg%20id='人事服务'%3e%3cg%20id='ic_public_link'%20clip-path='url(%23clipPath_11)'%20customFrame='url(%23clipPath_11)'%3e%3crect%20id='ic_public_link'%20width='20.000000'%20height='20.000000'%20x='10.000000'%20y='10.000000'%20/%3e%3cpath%20id='path1'%20d='M9.9999%2019.9917C9.9999%2018.4292%209.99573%2016.8667%209.9999%2015.3042C9.99573%2014.5459%2010.0916%2013.7917%2010.2749%2013.0626C10.6874%2011.5126%2011.6957%2010.5917%2013.2457%2010.2334C14.0207%2010.0667%2014.8166%209.98756%2015.6082%2010.0001C18.6041%2010.0001%2021.5999%2010.0001%2024.5999%2010.0001C25.3541%209.99589%2026.1082%2010.0792%2026.8457%2010.2584C28.4416%2010.6459%2029.3999%2011.6584%2029.7624%2013.2501C29.9291%2014.0001%2030.0041%2014.7667%2029.9957%2015.5376C29.9957%2018.5667%2029.9957%2021.5959%2029.9957%2024.6209C29.9999%2025.3709%2029.9166%2026.1209%2029.7416%2026.8459C29.3499%2028.4459%2028.3332%2029.3959%2026.7457%2029.7626C25.9666%2029.9292%2025.1749%2030.0084%2024.3791%2029.9959C21.3957%2029.9959%2018.4124%2029.9959%2015.4291%2029.9959C14.6666%2030.0042%2013.9082%2029.9167%2013.1666%2029.7417C11.5624%2029.3542%2010.5999%2028.3376%2010.2374%2026.7376C10.0499%2025.9251%209.9999%2025.1126%209.9999%2024.2917C9.9999%2022.8584%209.9999%2021.4251%209.9999%2019.9917Z'%20fill='rgb(255,255,255)'%20fill-opacity='0'%20fill-rule='evenodd'%20/%3e%3ccircle%20id='path2'%20cx='20'%20cy='20'%20r='10'%20fill='rgb(255,255,255)'%20fill-opacity='0'%20/%3e%3cpath%20id='path3'%20d='M25.0333%2021.8666L26.9%2020C28.8083%2018.0916%2028.8083%2015%2026.9%2013.0958C24.9958%2011.1875%2021.9041%2011.1875%2020%2013.0958L18.1291%2014.9625M21.8666%2025.0333L20%2026.9C18.0916%2028.8083%2015%2028.8083%2013.0958%2026.9C11.1875%2024.9958%2011.1875%2021.9041%2013.0958%2020L14.9625%2018.1291'%20fill-rule='nonzero'%20stroke='rgb(14,191,241)'%20stroke-linecap='round'%20stroke-width='1.25'%20/%3e%3cpath%20id='pah4'%20d='M18.125%2021.875L21.875%2018.125'%20stroke='rgb(14,191,241)'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-width='1.25'%20/%3e%3cpath%20id='path5'%20d='M25.8207%2019.2626L24.0457%2021.0376C23.7998%2021.2834%2023.6748%2021.5292%2023.6748%2021.7751C23.6748%2022.0209%2023.7998%2022.2667%2024.0457%2022.5126C24.1498%2022.6167%2024.2665%2022.6959%2024.3915%2022.7459C24.5123%2022.7917%2024.6415%2022.8167%2024.779%2022.8167C24.9207%2022.8167%2025.0498%2022.7917%2025.1665%2022.7459C25.2957%2022.6959%2025.4123%2022.6167%2025.5165%2022.5126L27.2915%2020.7334C27.8165%2020.2126%2028.2165%2019.6334%2028.4957%2019.0001C28.5082%2018.9667%2028.5248%2018.9334%2028.5373%2018.8959C28.554%2018.8626%2028.5665%2018.8292%2028.579%2018.7917C28.8332%2018.1501%2028.9582%2017.4584%2028.9582%2016.7209C28.9582%2015.9792%2028.8332%2015.2876%2028.579%2014.6459C28.5665%2014.6084%2028.554%2014.5751%2028.5373%2014.5417C28.5248%2014.5042%2028.5082%2014.4709%2028.4957%2014.4376C28.2165%2013.8042%2027.8165%2013.2292%2027.2915%2012.7042C26.7707%2012.1792%2026.1915%2011.7792%2025.5582%2011.5001C25.5248%2011.4876%2025.4915%2011.4709%2025.454%2011.4584C25.4207%2011.4417%2025.3873%2011.4292%2025.354%2011.4167C24.7082%2011.1667%2024.0165%2011.0417%2023.279%2011.0417C22.5373%2011.0417%2021.8457%2011.1667%2021.204%2011.4167C21.1665%2011.4292%2021.1332%2011.4417%2021.0998%2011.4584C21.0623%2011.4709%2021.029%2011.4876%2020.9957%2011.5001C20.3623%2011.7792%2019.7832%2012.1792%2019.2623%2012.7042L17.4832%2014.4792C17.379%2014.5834%2017.2998%2014.7001%2017.2498%2014.8292C17.204%2014.9501%2017.179%2015.0751%2017.179%2015.2167C17.179%2015.3542%2017.204%2015.4834%2017.2498%2015.6042C17.2998%2015.7292%2017.379%2015.8459%2017.4832%2015.9542C17.5915%2016.0584%2017.7082%2016.1376%2017.8332%2016.1876C17.954%2016.2334%2018.0832%2016.2584%2018.2207%2016.2584C18.3623%2016.2584%2018.4915%2016.2334%2018.6082%2016.1876C18.7373%2016.1376%2018.854%2016.0584%2018.9582%2015.9542L20.7332%2014.1751C21.0873%2013.8209%2021.4748%2013.5584%2021.8957%2013.3834C22.3165%2013.2084%2022.779%2013.1251%2023.279%2013.1251C23.7748%2013.1251%2024.2373%2013.2084%2024.6582%2013.3834C25.079%2013.5584%2025.4665%2013.8209%2025.8207%2014.1751C26.1748%2014.5292%2026.4373%2014.9167%2026.6123%2015.3376C26.7873%2015.7584%2026.8748%2016.2167%2026.8748%2016.7209C26.8748%2017.2209%2026.7873%2017.6792%2026.6123%2018.1001C26.4373%2018.5209%2026.1748%2018.9084%2025.8207%2019.2626ZM13.3832%2021.8959C13.5582%2021.4751%2013.8207%2021.0876%2014.1748%2020.7334L15.954%2018.9584C16.0582%2018.8542%2016.1373%2018.7376%2016.1873%2018.6084C16.2332%2018.4876%2016.2582%2018.3626%2016.2582%2018.2209C16.2582%2018.0834%2016.2332%2017.9542%2016.1873%2017.8334C16.1373%2017.7084%2016.0582%2017.5917%2015.954%2017.4834C15.7082%2017.2417%2015.4623%2017.1167%2015.2165%2017.1167C14.9707%2017.1167%2014.7248%2017.2417%2014.479%2017.4834L12.704%2019.2626C12.179%2019.7876%2011.779%2020.3626%2011.4998%2020.9959C11.4873%2021.0292%2011.4707%2021.0626%2011.4582%2021.1001C11.4415%2021.1334%2011.429%2021.1667%2011.4165%2021.2042C11.1665%2021.8459%2011.0415%2022.5376%2011.0415%2023.2792C11.0415%2024.0167%2011.1665%2024.7084%2011.4165%2025.3542C11.429%2025.3876%2011.4415%2025.4209%2011.4582%2025.4584C11.4707%2025.4917%2011.4873%2025.5251%2011.4998%2025.5584C11.779%2026.1917%2012.179%2026.7709%2012.704%2027.2917C13.2248%2027.8167%2013.804%2028.2167%2014.4373%2028.4959C14.4707%2028.5084%2014.504%2028.5251%2014.5415%2028.5376C14.5748%2028.5542%2014.6082%2028.5667%2014.6457%2028.5792C15.2873%2028.8292%2015.979%2028.9584%2016.7207%2028.9584C17.4582%2028.9584%2018.1498%2028.8292%2018.7915%2028.5792C18.829%2028.5667%2018.8623%2028.5542%2018.8957%2028.5376C18.9332%2028.5251%2018.9665%2028.5084%2018.9998%2028.4959C19.6332%2028.2167%2020.2123%2027.8167%2020.7332%2027.2917L22.5123%2025.5167C22.6165%2025.4126%2022.6957%2025.2959%2022.7457%2025.1667C22.7915%2025.0459%2022.8165%2024.9209%2022.8165%2024.7792C22.8165%2024.6417%2022.7915%2024.5126%2022.7457%2024.3917C22.6957%2024.2667%2022.6165%2024.1501%2022.5123%2024.0417C22.2665%2023.8001%2022.0207%2023.6751%2021.7748%2023.6751C21.529%2023.6751%2021.2832%2023.8001%2021.0373%2024.0417L19.2623%2025.8209C18.9082%2026.1751%2018.5207%2026.4376%2018.0998%2026.6126C17.679%2026.7876%2017.2165%2026.8751%2016.7207%2026.8751C16.2207%2026.8751%2015.7582%2026.7876%2015.3373%2026.6126C14.9165%2026.4376%2014.529%2026.1751%2014.1748%2025.8209C13.8207%2025.4667%2013.5582%2025.0792%2013.3832%2024.6584C13.2082%2024.2376%2013.1248%2023.7792%2013.1248%2023.2792C13.1248%2022.7751%2013.2082%2022.3167%2013.3832%2021.8959Z'%20fill='rgb(255,255,255)'%20fill-opacity='0'%20fill-rule='evenodd'%20/%3e%3cpath%20id='path6'%20d='M21.8127%2016.7458C21.746%2016.7874%2021.6877%2016.8374%2021.6293%2016.8916L16.8918%2021.6291C16.8377%2021.6874%2016.7877%2021.7499%2016.746%2021.8124C16.7127%2021.8624%2016.6877%2021.9166%2016.6627%2021.9749C16.6377%2022.0374%2016.6168%2022.1041%2016.6043%2022.1708C16.5918%2022.2333%2016.5835%2022.2999%2016.5835%2022.3666C16.5835%2022.4333%2016.5918%2022.4999%2016.6043%2022.5666C16.6168%2022.6333%2016.6377%2022.6999%2016.6627%2022.7624C16.6877%2022.8166%2016.7127%2022.8708%2016.746%2022.9208C16.7877%2022.9874%2016.8377%2023.0499%2016.8918%2023.1041C16.946%2023.1583%2017.0085%2023.2083%2017.0752%2023.2499C17.1252%2023.2833%2017.1793%2023.3083%2017.2335%2023.3333C17.3002%2023.3583%2017.3627%2023.3791%2017.4293%2023.3916C17.496%2023.4041%2017.5627%2023.4124%2017.6293%2023.4124C17.696%2023.4124%2017.7627%2023.4041%2017.8252%2023.3916C17.8918%2023.3791%2017.9585%2023.3583%2018.021%2023.3333C18.0793%2023.3083%2018.1335%2023.2833%2018.1835%2023.2499C18.246%2023.2083%2018.3085%2023.1583%2018.3668%2023.1041L23.1043%2018.3666C23.1585%2018.3083%2023.2085%2018.2499%2023.2502%2018.1833C23.2835%2018.1333%2023.3085%2018.0791%2023.3335%2018.0208C23.3585%2017.9583%2023.3793%2017.8916%2023.3918%2017.8249C23.4043%2017.7624%2023.4127%2017.6958%2023.4127%2017.6291C23.4127%2017.5624%2023.4043%2017.4958%2023.3918%2017.4291C23.3793%2017.3624%2023.3585%2017.2999%2023.3335%2017.2333C23.3085%2017.1791%2023.2835%2017.1249%2023.2502%2017.0749C23.2085%2017.0083%2023.1585%2016.9458%2023.1043%2016.8916C23.046%2016.8374%2022.9877%2016.7874%2022.921%2016.7458C22.871%2016.7124%2022.8168%2016.6874%2022.7627%2016.6624C22.696%2016.6374%2022.6335%2016.6166%2022.5668%2016.6041C22.5002%2016.5916%2022.4335%2016.5833%2022.3668%2016.5833C22.3002%2016.5833%2022.2335%2016.5916%2022.171%2016.6041C22.1043%2016.6166%2022.0377%2016.6374%2021.9752%2016.6624C21.9168%2016.6874%2021.8627%2016.7124%2021.8127%2016.7458Z'%20fill='rgb(255,255,255)'%20fill-opacity='0'%20fill-rule='evenodd'%20/%3e%3c/g%3e%3c/g%3e%3c/g%3e%3c/svg%3e", _2 = "data:image/svg+xml,%3csvg%20viewBox='0%200%2040%2040'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%20width='40.000000'%20height='40.000000'%20fill='none'%20customFrame='url(%23clipPath_0)'%3e%3cdefs%3e%3cclipPath%20id='clipPath_0'%3e%3crect%20width='40.000000'%20height='40.000000'%20x='0.000000'%20y='0.000000'%20rx='12.000000'%20fill='rgb(255,255,255)'%20/%3e%3c/clipPath%3e%3cclipPath%20id='clipPath_1'%3e%3crect%20width='24.000000'%20height='24.000000'%20x='8.000000'%20y='8.000000'%20fill='rgb(255,255,255)'%20/%3e%3c/clipPath%3e%3cclipPath%20id='clipPath_2'%3e%3crect%20width='20.000000'%20height='20.000000'%20x='10.000000'%20y='10.000000'%20fill='rgb(255,255,255)'%20/%3e%3c/clipPath%3e%3c/defs%3e%3crect%20id='1'%20width='40.000000'%20height='40.000000'%20x='0.000000'%20y='0.000000'%20rx='12.000000'%20fill='rgb(236,250,254)'%20/%3e%3cg%20id='车辆'%20clip-path='url(%23clipPath_1)'%20customFrame='url(%23clipPath_1)'%3e%3crect%20id='车辆'%20width='24.000000'%20height='24.000000'%20x='8.000000'%20y='8.000000'%20/%3e%3cg%20id='编组'%3e%3cg%20id='ic_public_qrcode'%20clip-path='url(%23clipPath_2)'%20customFrame='url(%23clipPath_2)'%3e%3crect%20id='ic_public_qrcode'%20width='20.000000'%20height='20.000000'%20x='10.000000'%20y='10.000000'%20/%3e%3cg%20id='ic_public_qrcode_1_1'%3e%3cpath%20id='ic_public_qrcode_2_0'%20d='M10.6273%2019.9924C10.6273%2018.5277%2010.6222%2017.0631%2010.6273%2015.5985C10.6243%2014.8898%2010.7114%2014.1836%2010.8865%2013.4968C11.2702%2012.0432%2012.2171%2011.1805%2013.6693%2010.8458C14.3974%2010.6885%2015.1411%2010.6148%2015.886%2010.6261C18.6946%2010.6261%2021.5035%2010.6261%2024.3127%2010.6261C25.0221%2010.6217%2025.7295%2010.7029%2026.4195%2010.8678C27.9156%2011.2339%2028.8134%2012.1816%2029.1554%2013.6725C29.3092%2014.3772%2029.3826%2015.097%2029.3744%2015.8182C29.3744%2018.6571%2029.3744%2021.4963%2029.3744%2024.3357C29.3782%2025.0383%2029.2973%2025.7388%2029.1334%2026.422C28.7673%2027.9189%2027.8153%2028.8123%2026.3243%2029.1543C25.5961%2029.311%2024.8524%2029.3847%2024.1076%2029.374C21.3107%2029.374%2018.514%2029.374%2015.7176%2029.374C15.0027%2029.3798%2014.2897%2029.2999%2013.5939%2029.136C12.0912%2028.7698%2011.189%2027.8178%2010.8477%2026.3195C10.6734%2025.5579%2010.6273%2024.7941%2010.6273%2024.0237C10.6273%2022.6802%2010.6273%2021.3364%2010.6273%2019.9924Z'%20fill='rgb(255,255,255)'%20fill-opacity='0'%20fill-rule='nonzero'%20/%3e%3cpath%20id='ic_public_qrcode_2_0'%20d='M10.6273%2015.5985C10.6243%2014.8898%2010.7114%2014.1836%2010.8865%2013.4968C11.2702%2012.0432%2012.2171%2011.1805%2013.6693%2010.8458C14.3974%2010.6885%2015.1411%2010.6148%2015.886%2010.6261C18.6946%2010.6261%2021.5035%2010.6261%2024.3127%2010.6261C25.0221%2010.6217%2025.7295%2010.7029%2026.4195%2010.8678C27.9156%2011.2339%2028.8134%2012.1816%2029.1554%2013.6725C29.3092%2014.3772%2029.3826%2015.097%2029.3744%2015.8182C29.3744%2018.6571%2029.3744%2021.4963%2029.3744%2024.3357C29.3782%2025.0383%2029.2973%2025.7388%2029.1334%2026.422C28.7673%2027.9189%2027.8153%2028.8123%2026.3243%2029.1543C25.5961%2029.311%2024.8524%2029.3847%2024.1076%2029.374C21.3107%2029.374%2018.514%2029.374%2015.7176%2029.374C15.0027%2029.3798%2014.2897%2029.2999%2013.5939%2029.136C12.0912%2028.7698%2011.189%2027.8178%2010.8477%2026.3195C10.6734%2025.5579%2010.6273%2024.7941%2010.6273%2024.0237C10.6273%2022.6802%2010.6273%2021.3364%2010.6273%2019.9924C10.6273%2018.5277%2010.6222%2017.0631%2010.6273%2015.5985Z'%20fill-rule='nonzero'%20stroke='rgb(255,255,255)'%20stroke-opacity='0'%20stroke-width='1.25'%20/%3e%3cpath%20id='ic_public_qrcode_2_1'%20d='M10.6273%2015.5985C10.6243%2014.8898%2010.7114%2014.1836%2010.8865%2013.4968C11.2702%2012.0432%2012.2171%2011.1805%2013.6693%2010.8458C14.3974%2010.6885%2015.1411%2010.6148%2015.886%2010.6261C18.6946%2010.6261%2021.5035%2010.6261%2024.3127%2010.6261C25.0221%2010.6217%2025.7295%2010.7029%2026.4195%2010.8678C27.9156%2011.2339%2028.8134%2012.1816%2029.1554%2013.6725C29.3092%2014.3772%2029.3826%2015.097%2029.3744%2015.8182C29.3744%2018.6571%2029.3744%2021.4963%2029.3744%2024.3357C29.3782%2025.0383%2029.2973%2025.7388%2029.1334%2026.422C28.7673%2027.9189%2027.8153%2028.8123%2026.3243%2029.1543C25.5961%2029.311%2024.8524%2029.3847%2024.1076%2029.374C21.3107%2029.374%2018.514%2029.374%2015.7176%2029.374C15.0027%2029.3798%2014.2897%2029.2999%2013.5939%2029.136C12.0912%2028.7698%2011.189%2027.8178%2010.8477%2026.3195C10.6734%2025.5579%2010.6273%2024.7941%2010.6273%2024.0237C10.6273%2022.6802%2010.6273%2021.3364%2010.6273%2019.9924C10.6273%2018.5277%2010.6222%2017.0631%2010.6273%2015.5985Z'%20opacity='0.200000003'%20fill-rule='nonzero'%20stroke='rgb(255,255,255)'%20stroke-opacity='0'%20stroke-width='1.25'%20/%3e%3ccircle%20id='ic_public_qrcode_2_2'%20cx='20'%20cy='20'%20r='10'%20fill='rgb(255,255,255)'%20fill-opacity='0'%20/%3e%3cpath%20id='ic_public_qrcode_2_3'%20d='M17.5%2011.25C17.9602%2011.25%2018.3333%2011.6231%2018.3333%2012.0833L18.3333%2017.5C18.3333%2017.9602%2017.9602%2018.3333%2017.5%2018.3333L12.0833%2018.3333C11.6231%2018.3333%2011.25%2017.9602%2011.25%2017.5L11.25%2012.0833C11.25%2011.6231%2011.6231%2011.25%2012.0833%2011.25L17.5%2011.25ZM17.5%2021.6667C17.9602%2021.6667%2018.3333%2022.0398%2018.3333%2022.5L18.3333%2027.9167C18.3333%2028.3769%2017.9602%2028.75%2017.5%2028.75L12.0833%2028.75C11.6231%2028.75%2011.25%2028.3769%2011.25%2027.9167L11.25%2022.5C11.25%2022.0398%2011.6231%2021.6667%2012.0833%2021.6667L17.5%2021.6667ZM27.9167%2011.25C28.3769%2011.25%2028.75%2011.6231%2028.75%2012.0833L28.75%2017.5C28.75%2017.9602%2028.3769%2018.3333%2027.9167%2018.3333L22.5%2018.3333C22.0398%2018.3333%2021.6667%2017.9602%2021.6667%2017.5L21.6667%2012.0833C21.6667%2011.6231%2022.0398%2011.25%2022.5%2011.25L27.9167%2011.25Z'%20fill-rule='evenodd'%20stroke='rgb(14,191,241)'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-width='1.25'%20/%3e%3cpath%20id='ic_public_qrcode_2_4'%20d='M17.5002%2010.8333C18.1905%2010.8333%2018.7502%2011.3929%2018.7502%2012.0833L18.7502%2017.4999C18.7502%2018.1903%2018.1905%2018.7499%2017.5002%2018.7499L12.0835%2018.7499C11.3931%2018.7499%2010.8335%2018.1903%2010.8335%2017.4999L10.8335%2012.0833C10.8335%2011.3929%2011.3931%2010.8333%2012.0835%2010.8333L17.5002%2010.8333ZM17.5002%2011.6666L12.0835%2011.6666C11.8534%2011.6666%2011.6668%2011.8531%2011.6668%2012.0833L11.6668%2017.4999C11.6668%2017.73%2011.8534%2017.9166%2012.0835%2017.9166L17.5002%2017.9166C17.7303%2017.9166%2017.9168%2017.73%2017.9168%2017.4999L17.9168%2012.0833C17.9168%2011.8531%2017.7303%2011.6666%2017.5002%2011.6666ZM17.5002%2021.2499C18.1905%2021.2499%2018.7502%2021.8096%2018.7502%2022.4999L18.7502%2027.9166C18.7502%2028.6069%2018.1905%2029.1666%2017.5002%2029.1666L12.0835%2029.1666C11.3931%2029.1666%2010.8335%2028.6069%2010.8335%2027.9166L10.8335%2022.4999C10.8335%2021.8096%2011.3931%2021.2499%2012.0835%2021.2499L17.5002%2021.2499ZM17.5002%2022.0833L12.0835%2022.0833C11.8534%2022.0833%2011.6668%2022.2698%2011.6668%2022.4999L11.6668%2027.9166C11.6668%2028.1467%2011.8534%2028.3333%2012.0835%2028.3333L17.5002%2028.3333C17.7303%2028.3333%2017.9168%2028.1467%2017.9168%2027.9166L17.9168%2022.4999C17.9168%2022.2698%2017.7303%2022.0833%2017.5002%2022.0833ZM27.9168%2010.8333C28.6072%2010.8333%2029.1668%2011.3929%2029.1668%2012.0833L29.1668%2017.4999C29.1668%2018.1903%2028.6072%2018.7499%2027.9168%2018.7499L22.5002%2018.7499C21.8098%2018.7499%2021.2502%2018.1903%2021.2502%2017.4999L21.2502%2012.0833C21.2502%2011.3929%2021.8098%2010.8333%2022.5002%2010.8333L27.9168%2010.8333ZM27.9168%2011.6666L22.5002%2011.6666C22.27%2011.6666%2022.0835%2011.8531%2022.0835%2012.0833L22.0835%2017.4999C22.0835%2017.73%2022.27%2017.9166%2022.5002%2017.9166L27.9168%2017.9166C28.1469%2017.9166%2028.3335%2017.73%2028.3335%2017.4999L28.3335%2012.0833C28.3335%2011.8531%2028.1469%2011.6666%2027.9168%2011.6666Z'%20fill='rgb(255,255,255)'%20fill-opacity='0'%20fill-rule='nonzero'%20/%3e%3cpath%20id='ic_public_qrcode_2_4'%20d='M18.7502%2012.0833L18.7502%2017.4999C18.7502%2018.1903%2018.1905%2018.7499%2017.5002%2018.7499L12.0835%2018.7499C11.3931%2018.7499%2010.8335%2018.1903%2010.8335%2017.4999L10.8335%2012.0833C10.8335%2011.3929%2011.3931%2010.8333%2012.0835%2010.8333L17.5002%2010.8333C18.1905%2010.8333%2018.7502%2011.3929%2018.7502%2012.0833ZM12.0835%2011.6666C11.8534%2011.6666%2011.6668%2011.8531%2011.6668%2012.0833L11.6668%2017.4999C11.6668%2017.73%2011.8534%2017.9166%2012.0835%2017.9166L17.5002%2017.9166C17.7303%2017.9166%2017.9168%2017.73%2017.9168%2017.4999L17.9168%2012.0833C17.9168%2011.8531%2017.7303%2011.6666%2017.5002%2011.6666L12.0835%2011.6666ZM18.7502%2022.4999L18.7502%2027.9166C18.7502%2028.6069%2018.1905%2029.1666%2017.5002%2029.1666L12.0835%2029.1666C11.3931%2029.1666%2010.8335%2028.6069%2010.8335%2027.9166L10.8335%2022.4999C10.8335%2021.8096%2011.3931%2021.2499%2012.0835%2021.2499L17.5002%2021.2499C18.1905%2021.2499%2018.7502%2021.8096%2018.7502%2022.4999ZM12.0835%2022.0833C11.8534%2022.0833%2011.6668%2022.2698%2011.6668%2022.4999L11.6668%2027.9166C11.6668%2028.1467%2011.8534%2028.3333%2012.0835%2028.3333L17.5002%2028.3333C17.7303%2028.3333%2017.9168%2028.1467%2017.9168%2027.9166L17.9168%2022.4999C17.9168%2022.2698%2017.7303%2022.0833%2017.5002%2022.0833L12.0835%2022.0833ZM29.1668%2012.0833L29.1668%2017.4999C29.1668%2018.1903%2028.6072%2018.7499%2027.9168%2018.7499L22.5002%2018.7499C21.8098%2018.7499%2021.2502%2018.1903%2021.2502%2017.4999L21.2502%2012.0833C21.2502%2011.3929%2021.8098%2010.8333%2022.5002%2010.8333L27.9168%2010.8333C28.6072%2010.8333%2029.1668%2011.3929%2029.1668%2012.0833ZM22.5002%2011.6666C22.27%2011.6666%2022.0835%2011.8531%2022.0835%2012.0833L22.0835%2017.4999C22.0835%2017.73%2022.27%2017.9166%2022.5002%2017.9166L27.9168%2017.9166C28.1469%2017.9166%2028.3335%2017.73%2028.3335%2017.4999L28.3335%2012.0833C28.3335%2011.8531%2028.1469%2011.6666%2027.9168%2011.6666L22.5002%2011.6666Z'%20fill-rule='nonzero'%20stroke='rgb(255,255,255)'%20stroke-opacity='0'%20stroke-linejoin='round'%20stroke-width='1.25'%20/%3e%3cpath%20id='ic_public_qrcode_2_5'%20d='M27.9165%2021.6667L27.9165%2024.5834L28.7498%2024.5834L28.7498%2021.6667L27.9165%2021.6667ZM24.5832%2021.6667L24.5832%2022.639L24.5828%2022.6388L24.5832%2024.5834L23.6109%2024.5834L23.6107%2022.6388L21.6665%2022.639L21.6665%2021.6667L24.5832%2021.6667ZM21.6665%2025.8334L21.6665%2028.7501L22.4998%2028.7501L22.4998%2025.8334L21.6665%2025.8334ZM27.9165%2027.9167L27.9165%2028.7501L28.7498%2028.7501L28.7498%2027.9167L27.9165%2027.9167ZM25.8332%2025.8334L25.8332%2026.6667L26.6665%2026.6667L26.6665%2025.8334L25.8332%2025.8334Z'%20fill='rgb(14,191,241)'%20fill-rule='nonzero'%20/%3e%3cpath%20id='ic_public_qrcode_2_5'%20d='M27.9165%2024.5834L28.7498%2024.5834L28.7498%2021.6667L27.9165%2021.6667L27.9165%2024.5834ZM24.5832%2022.639L24.5828%2022.6388L24.5832%2024.5834L23.6109%2024.5834L23.6107%2022.6388L21.6665%2022.639L21.6665%2021.6667L24.5832%2021.6667L24.5832%2022.639ZM21.6665%2028.7501L22.4998%2028.7501L22.4998%2025.8334L21.6665%2025.8334L21.6665%2028.7501ZM27.9165%2028.7501L28.7498%2028.7501L28.7498%2027.9167L27.9165%2027.9167L27.9165%2028.7501ZM25.8332%2026.6667L26.6665%2026.6667L26.6665%2025.8334L25.8332%2025.8334L25.8332%2026.6667Z'%20fill-rule='nonzero'%20stroke='rgb(14,191,241)'%20stroke-linejoin='round'%20stroke-width='1.25'%20/%3e%3cpath%20id='ic_public_qrcode_2_6'%20d='M14.375%2014.375L14.375%2015.2083L15.2083%2015.2083L15.2083%2014.375L14.375%2014.375ZM14.375%2024.7917L14.375%2025.625L15.2083%2025.625L15.2083%2024.7917L14.375%2024.7917ZM24.7917%2014.375L24.7917%2015.2083L25.625%2015.2083L25.625%2014.375L24.7917%2014.375Z'%20fill='rgb(14,191,241)'%20fill-rule='nonzero'%20/%3e%3cpath%20id='ic_public_qrcode_2_6'%20d='M14.375%2015.2083L15.2083%2015.2083L15.2083%2014.375L14.375%2014.375L14.375%2015.2083ZM14.375%2025.625L15.2083%2025.625L15.2083%2024.7917L14.375%2024.7917L14.375%2025.625ZM24.7917%2015.2083L25.625%2015.2083L25.625%2014.375L24.7917%2014.375L24.7917%2015.2083Z'%20fill-rule='nonzero'%20stroke='rgb(14,191,241)'%20stroke-linejoin='round'%20stroke-width='1.25'%20/%3e%3c/g%3e%3c/g%3e%3c/g%3e%3c/g%3e%3c/svg%3e", b2 = "data:image/svg+xml,%3csvg%20viewBox='0%200%2012%2012'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%20width='12.000000'%20height='12.000000'%20fill='none'%3e%3cdefs%3e%3cfilter%20id='pixso_custom_mask_type_luminance'%3e%3cfeColorMatrix%20type='matrix'%20values='1%200%200%200%200%200%201%200%200%200%200%200%201%200%200%200%200%200%201%200%20'%20/%3e%3c/filter%3e%3c/defs%3e%3cmask%20id='mask_0'%20width='11.999876'%20height='11.999876'%20x='0.000000'%20y='0.000000'%20maskUnits='userSpaceOnUse'%3e%3cg%20filter='url(%23pixso_custom_mask_type_luminance)'%3e%3cg%20id='mask401_19830'%3e%3cpath%20id='蒙版'%20d='M0%200L11.9999%200L11.9999%2011.9999L0%2011.9999L0%200ZM2.69992%201.34999L8.09977%201.34999C9.5082%201.34999%2010.6498%202.49167%2010.6498%203.89998L10.6498%209.2999C10.6498%2010.7082%209.5082%2011.8499%208.09977%2011.8499L2.69992%2011.8499C1.29149%2011.8499%200.149901%2010.7082%200.149901%209.2999L0.149901%203.89998C0.149901%202.49167%201.29149%201.34999%202.69992%201.34999Z'%20fill='rgb(196,196,196)'%20fill-rule='evenodd'%20/%3e%3c/g%3e%3c/g%3e%3c/mask%3e%3crect%20id='ic_public_copy'%20width='12.000000'%20height='12.000000'%20x='0.000000'%20y='0.000000'%20/%3e%3crect%20id='ic_public_copy-复制/base/ic_public_copy'%20width='11.999876'%20height='11.999876'%20x='0.000000'%20y='0.000000'%20fill='rgb(255,255,255)'%20fill-opacity='0'%20/%3e%3cpath%20id='path1'%20d='M0.000134537%205.99497C0.000134537%205.05748%20-0.00236544%204.11999%200.000134537%203.1825C-0.00236544%202.72751%200.055134%202.27501%200.165133%201.83752C0.41263%200.907526%201.01762%200.355032%201.94761%200.140034C2.41261%200.040035%202.8901%20-0.00746449%203.3651%203.54269e-05C5.16258%203.54269e-05%206.96006%203.54269e-05%208.76004%203.54269e-05C9.21254%20-0.00246455%209.66503%200.0475349%2010.1075%200.155034C11.065%200.387531%2011.64%200.995025%2011.8575%201.95002C11.9575%202.40001%2012.005%202.86001%2011.9975%203.3225C11.9975%205.13998%2011.9975%206.95746%2011.9975%208.77244C12%209.22244%2011.95%209.67243%2011.845%2010.1099C11.61%2011.0674%2011%2011.6374%2010.0475%2011.8574C9.58003%2011.9574%209.10504%2012.0049%208.62754%2011.9974C6.83756%2011.9974%205.04758%2011.9974%203.2576%2011.9974C2.80011%2012.0024%202.34511%2011.9499%201.90011%2011.8449C0.937625%2011.6124%200.360131%2011.0024%200.142633%2010.0424C0.0301342%209.55494%200.000134537%209.06744%200.000134537%208.57495C0.000134537%207.71495%200.000134537%206.85496%200.000134537%205.99497Z'%20fill='rgb(255,255,255)'%20fill-opacity='0'%20fill-rule='evenodd'%20/%3e%3ccircle%20id='path2'%20cx='5.99993801'%20cy='5.99993801'%20r='5.99993801'%20fill='rgb(255,255,255)'%20fill-opacity='0'%20/%3e%3cg%20id='mask'%20mask='url(%23mask_0)'%3e%3cg%20id='组合%208'%3e%3cpath%20id='path'%20d='M11.1%203.89993L11.1%206.8999C11.1%208.55488%209.75502%209.89737%208.10004%209.89737L5.10007%209.89737C3.44258%209.89737%202.1001%208.55488%202.1001%206.8999L2.1001%203.89993C2.1001%202.24245%203.44258%200.897461%205.10007%200.897461L8.10004%200.897461C9.75502%200.897461%2011.1%202.24245%2011.1%203.89993Z'%20fill-rule='nonzero'%20stroke='rgb(25,25,25)'%20stroke-linejoin='round'%20stroke-width='0.749992251'%20/%3e%3c/g%3e%3c/g%3e%3cpath%20id='path4'%20d='M2.10008%202.39746L8.10002%202.39746C8.92751%202.39746%209.6%203.06995%209.6%203.89995L9.6%209.89738C9.6%2010.7274%208.92751%2011.3999%208.10002%2011.3999L2.10008%2011.3999C1.27009%2011.3999%200.600098%2010.7274%200.600098%209.89738L0.600098%203.89995C0.600098%203.06995%201.27009%202.39746%202.10008%202.39746Z'%20fill='rgb(255,255,255)'%20fill-opacity='0'%20fill-rule='evenodd'%20/%3e%3cpath%20id='path4'%20d='M9.6%203.89995L9.6%209.89738C9.6%2010.7274%208.92751%2011.3999%208.10002%2011.3999L2.10008%2011.3999C1.27009%2011.3999%200.600098%2010.7274%200.600098%209.89738L0.600098%203.89995C0.600098%203.06995%201.27009%202.39746%202.10008%202.39746L8.10002%202.39746C8.92751%202.39746%209.6%203.06995%209.6%203.89995Z'%20fill-rule='nonzero'%20stroke='rgb(25,25,25)'%20stroke-linejoin='round'%20stroke-width='0.749992251'%20/%3e%3c/svg%3e", x2 = "https://chat.opentiny.design", L2 = "https://ai.opentiny.design/next-remoter", k2 = "https://ai.opentiny.design/next-remoter/svgs/logo-next-no-bg-left.svg", Je = (t) => {
|
|
904
|
+
const v2 = "data:image/svg+xml,%3csvg%20viewBox='0%200%2040%2039.9692'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%20width='40.000000'%20height='39.969238'%20fill='none'%20customFrame='url(%23clipPath_3)'%3e%3cdefs%3e%3cclipPath%20id='clipPath_3'%3e%3crect%20width='40.000000'%20height='39.969238'%20x='0.000000'%20y='0.000000'%20rx='12.000000'%20fill='rgb(255,255,255)'%20/%3e%3c/clipPath%3e%3cclipPath%20id='clipPath_4'%3e%3crect%20width='24.000000'%20height='24.000000'%20x='8.000000'%20y='7.984619'%20fill='rgb(255,255,255)'%20/%3e%3c/clipPath%3e%3cclipPath%20id='clipPath_5'%3e%3crect%20width='20.000000'%20height='20.000000'%20x='10.000000'%20y='9.984619'%20fill='rgb(255,255,255)'%20/%3e%3c/clipPath%3e%3cclipPath%20id='clipPath_6'%3e%3crect%20width='20.000000'%20height='20.000000'%20x='10.000000'%20y='9.984619'%20fill='rgb(255,255,255)'%20/%3e%3c/clipPath%3e%3cclipPath%20id='clipPath_7'%3e%3crect%20width='21.666666'%20height='13.333333'%20x='20.000000'%20y='9.984619'%20rx='6.666667'%20fill='rgb(255,255,255)'%20/%3e%3c/clipPath%3e%3cclipPath%20id='clipPath_8'%3e%3crect%20width='6.666667'%20height='6.666667'%20x='23.333496'%20y='9.984619'%20fill='rgb(255,255,255)'%20/%3e%3c/clipPath%3e%3c/defs%3e%3crect%20id='2'%20width='40.000000'%20height='39.969238'%20x='0.000000'%20y='0.000000'%20rx='12.000000'%20fill='rgb(239,246,255)'%20/%3e%3cg%20id='物业'%20clip-path='url(%23clipPath_4)'%20customFrame='url(%23clipPath_4)'%3e%3crect%20id='物业'%20width='24.000000'%20height='24.000000'%20x='8.000000'%20y='7.984619'%20/%3e%3cg%20id='物业服务'%3e%3cg%20id='00公共/红点/图标+红点'%20customFrame='url(%23clipPath_5)'%3e%3crect%20id='00公共/红点/图标+红点'%20width='20.000000'%20height='20.000000'%20x='10.000000'%20y='9.984619'%20/%3e%3cg%20id='common_chats_line'%20customFrame='url(%23clipPath_6)'%3e%3crect%20id='common_chats_line'%20width='20.000000'%20height='20.000000'%20x='10.000000'%20y='9.984619'%20/%3e%3cpath%20id='形状'%20d='M28.3332%2019.9847C28.3332%2015.3823%2024.6022%2011.6514%2019.9998%2011.6514C15.3975%2011.6514%2011.6665%2015.3823%2011.6665%2019.9847C11.6665%2024.5871%2015.3975%2028.318%2019.9998%2028.318C21.0018%2028.318%2021.9624%2028.1412%2022.8522%2027.8171L26.581%2028.1578C26.7205%2028.1706%2026.8611%2028.1598%2026.9971%2028.1259C27.6669%2027.959%2028.0746%2027.2806%2027.9077%2026.6108L27.2716%2024.0578C27.9477%2022.8535%2028.3332%2021.4641%2028.3332%2019.9847ZM19.9998%2013.1514C16.2259%2013.1514%2013.1665%2016.2108%2013.1665%2019.9847C13.1665%2023.7586%2016.2259%2026.818%2019.9998%2026.818C20.8089%2026.818%2021.5967%2026.678%2022.3388%2026.4077C22.505%2026.3471%2022.6803%2026.3166%2022.8565%2026.3171L22.9887%2026.3233L26.3665%2026.6322L25.8161%2024.4205C25.7352%2024.0958%2025.7655%2023.7548%2025.8997%2023.4512L25.9636%2023.3236C26.5311%2022.3126%2026.8332%2021.1723%2026.8332%2019.9847C26.8332%2016.2108%2023.7738%2013.1514%2019.9998%2013.1514ZM23.1152%2021.2468C23.352%2020.9069%2023.2684%2020.4394%2022.9286%2020.2026C22.5887%2019.9659%2022.1212%2020.0494%2021.8845%2020.3893C21.2894%2021.2433%2020.4268%2021.7347%2019.5102%2021.7347C18.9513%2021.7347%2018.4132%2021.554%2017.9375%2021.2122C17.6011%2020.9705%2017.1325%2021.0472%2016.8908%2021.3836C16.6491%2021.7199%2016.7258%2022.1886%2017.0622%2022.4303C17.7879%2022.9518%2018.6305%2023.2347%2019.5102%2023.2347C20.9394%2023.2347%2022.2505%2022.4878%2023.1152%2021.2468Z'%20fill='rgb(65,142,255)'%20fill-rule='evenodd'%20/%3e%3c/g%3e%3cg%20id='00公共/3位数红点'%20opacity='0'%20customFrame='url(%23clipPath_7)'%3e%3crect%20id='00公共/3位数红点'%20width='21.666666'%20height='13.333333'%20x='20.000000'%20y='9.984619'%20rx='6.666667'%20opacity='0'%20fill='rgb(243,111,100)'%20/%3e%3cpath%20id='文本'%20d='M26.0421%2013.4421C26.4259%2013.4421%2026.7677%2013.5255%2027.0675%2013.6923C27.3672%2013.8591%2027.6005%2014.0931%2027.7673%2014.3942C27.9342%2014.694%2028.0176%2015.0351%2028.0176%2015.4176C28.0176%2015.7173%2027.9633%2015.994%2027.8548%2016.2476C27.7463%2016.4999%2027.5673%2016.8315%2027.3177%2017.2425L25.859%2019.6432L25.0167%2019.6432L26.276%2017.5924C26.3534%2017.4704%2026.4307%2017.3564%2026.508%2017.2507C26.3357%2017.3063%2026.1445%2017.3341%2025.9342%2017.3341C25.5721%2017.3341%2025.2493%2017.2479%2024.9658%2017.0757C24.6837%2016.9034%2024.4633%2016.6701%2024.3046%2016.3758C24.1459%2016.0815%2024.0666%2015.7566%2024.0666%2015.4013C24.0666%2015.0351%2024.1513%2014.7021%2024.3209%2014.4023C24.4904%2014.1012%2024.7264%2013.8659%2025.0289%2013.6964C25.3314%2013.5268%2025.6691%2013.4421%2026.0421%2013.4421ZM26.0421%2016.6505C26.4029%2016.6505%2026.6904%2016.5325%2026.9047%2016.2965C27.119%2016.0605%2027.2262%2015.7539%2027.2262%2015.3769C27.2262%2014.9985%2027.119%2014.694%2026.9047%2014.4634C26.6904%2014.2328%2026.4029%2014.1175%2026.0421%2014.1175C25.6867%2014.1175%2025.4019%2014.2342%2025.1876%2014.4674C24.9733%2014.7007%2024.8661%2015.0039%2024.8661%2015.3769C24.8661%2015.7539%2024.9719%2016.0605%2025.1835%2016.2965C25.3951%2016.5325%2025.6813%2016.6505%2026.0421%2016.6505ZM30.7921%2013.4421C31.1759%2013.4421%2031.5177%2013.5255%2031.8175%2013.6923C32.1172%2013.8591%2032.3505%2014.0931%2032.5173%2014.3942C32.6842%2014.694%2032.7676%2015.0351%2032.7676%2015.4176C32.7676%2015.7173%2032.7133%2015.994%2032.6048%2016.2476C32.4963%2016.4999%2032.3173%2016.8315%2032.0677%2017.2425L30.609%2019.6432L29.7667%2019.6432L31.026%2017.5924C31.1034%2017.4704%2031.1807%2017.3564%2031.258%2017.2507C31.0857%2017.3063%2030.8945%2017.3341%2030.6842%2017.3341C30.3221%2017.3341%2029.9993%2017.2479%2029.7158%2017.0757C29.4337%2016.9034%2029.2133%2016.6701%2029.0546%2016.3758C28.8959%2016.0815%2028.8166%2015.7566%2028.8166%2015.4013C28.8166%2015.0351%2028.9013%2014.7021%2029.0709%2014.4023C29.2404%2014.1012%2029.4764%2013.8659%2029.7789%2013.6964C30.0814%2013.5268%2030.4191%2013.4421%2030.7921%2013.4421ZM30.7921%2016.6505C31.1529%2016.6505%2031.4404%2016.5325%2031.6547%2016.2965C31.869%2016.0605%2031.9762%2015.7539%2031.9762%2015.3769C31.9762%2014.9985%2031.869%2014.694%2031.6547%2014.4634C31.4404%2014.2328%2031.1529%2014.1175%2030.7921%2014.1175C30.4367%2014.1175%2030.1519%2014.2342%2029.9376%2014.4674C29.7233%2014.7007%2029.6161%2015.0039%2029.6161%2015.3769C29.6161%2015.7539%2029.7219%2016.0605%2029.9335%2016.2965C30.1451%2016.5325%2030.4313%2016.6505%2030.7921%2016.6505ZM35.2674%2014.6851L35.9001%2014.6851L35.9001%2016.3188L37.5339%2016.3188L37.5339%2016.9516L35.9001%2016.9516L35.9001%2018.5853L35.2674%2018.5853L35.2674%2016.9516L33.6337%2016.9516L33.6337%2016.3188L35.2674%2016.3188L35.2674%2014.6851Z'%20fill='rgb(255,255,255)'%20fill-rule='nonzero'%20/%3e%3c/g%3e%3cg%20id='00公共/单红点'%20opacity='0'%20customFrame='url(%23clipPath_8)'%3e%3crect%20id='00公共/单红点'%20width='6.666667'%20height='6.666667'%20x='23.333496'%20y='9.984619'%20opacity='0'%20fill='rgb(255,255,255)'%20fill-opacity='0'%20/%3e%3ccircle%20id='红点'%20cx='26.6668301'%20cy='13.3179522'%20r='3.33333325'%20fill='rgb(243,111,100)'%20/%3e%3c/g%3e%3c/g%3e%3c/g%3e%3c/g%3e%3c/svg%3e", C2 = "data:image/svg+xml,%3csvg%20viewBox='0%200%2040%2040'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%20width='40.000000'%20height='40.000000'%20fill='none'%20customFrame='url(%23clipPath_12)'%3e%3cdefs%3e%3cclipPath%20id='clipPath_12'%3e%3crect%20width='40.000000'%20height='40.000000'%20x='0.000000'%20y='0.000000'%20rx='12.000000'%20fill='rgb(255,255,255)'%20/%3e%3c/clipPath%3e%3cclipPath%20id='clipPath_13'%3e%3crect%20width='24.000000'%20height='24.000000'%20x='8.000000'%20y='8.000000'%20fill='rgb(255,255,255)'%20/%3e%3c/clipPath%3e%3cclipPath%20id='clipPath_14'%3e%3crect%20width='20.000000'%20height='20.000000'%20x='10.000000'%20y='10.000000'%20fill='rgb(255,255,255)'%20/%3e%3c/clipPath%3e%3c/defs%3e%3crect%20id='4'%20width='40.000000'%20height='40.000000'%20x='0.000000'%20y='0.000000'%20rx='12.000000'%20fill='rgb(234,255,244)'%20/%3e%3cg%20id='我的信息'%20clip-path='url(%23clipPath_13)'%20customFrame='url(%23clipPath_13)'%3e%3crect%20id='我的信息'%20width='24.000000'%20height='24.000000'%20x='8.000000'%20y='8.000000'%20/%3e%3cg%20id='组合%208'%20customFrame='url(%23clipPath_14)'%3e%3crect%20id='组合%208'%20width='20.000000'%20height='20.000000'%20x='10.000000'%20y='10.000000'%20/%3e%3cpath%20id='合并'%20d='M28.4994%2012.3142C28.4994%2012.2578%2028.4937%2012.2018%2028.4825%2012.1465C28.4713%2012.0911%2028.4547%2012.0373%2028.4327%2011.9851C28.4107%2011.933%2028.3836%2011.8835%2028.3516%2011.8365C28.3197%2011.7896%2028.2834%2011.7461%2028.2427%2011.7062C28.202%2011.6663%2028.1579%2011.6307%2028.1101%2011.5993C28.0622%2011.568%2028.0117%2011.5415%2027.9585%2011.5199C27.9054%2011.4983%2027.8506%2011.4819%2027.7942%2011.4709C27.7378%2011.4599%2027.6806%2011.4544%2027.6231%2011.4544L24.1832%2011.5199L24.1832%2010L29.0796%2010C29.1472%2010%2029.2143%2010.0065%2029.2806%2010.0194C29.347%2010.0324%2029.4114%2010.0516%2029.4739%2010.077C29.5364%2010.1024%2029.5961%2010.1336%2029.6523%2010.1705C29.7086%2010.2074%2029.7605%2010.2493%2029.8084%2010.2963C29.8562%2010.3433%2029.8991%2010.3944%2029.9367%2010.4496C29.9743%2010.5048%2030.006%2010.5631%2030.0319%2010.6244C30.0578%2010.6858%2030.0773%2010.7491%2030.0905%2010.8142C30.1037%2010.8794%2030.1104%2010.9451%2030.1104%2011.0115L30.1832%2014.4522L28.4992%2014.5L28.4994%2012.3142ZM11.6995%2012.3143C11.6995%2012.2579%2011.7051%2012.2019%2011.7163%2012.1466C11.7275%2012.0912%2011.7441%2012.0374%2011.7661%2011.9852C11.7882%2011.9331%2011.8152%2011.8836%2011.8472%2011.8366C11.8791%2011.7897%2011.9155%2011.7462%2011.9562%2011.7063C11.9968%2011.6664%2012.0409%2011.6308%2012.0888%2011.5994C12.1366%2011.5681%2012.1871%2011.5416%2012.2403%2011.52C12.2934%2011.4984%2012.3482%2011.482%2012.4046%2011.471C12.4611%2011.46%2012.5182%2011.4545%2012.5758%2011.4545L16.0157%2011.52L16.0157%2010.0001L11.1193%2010.0001C11.0516%2010.0001%2010.9846%2010.0066%2010.9182%2010.0196C10.8518%2010.0325%2010.7874%2010.0517%2010.7249%2010.0771C10.6624%2010.1025%2010.6028%2010.1337%2010.5465%2010.1706C10.4902%2010.2075%2010.4383%2010.2494%2010.3904%2010.2964C10.3426%2010.3434%2010.2997%2010.3945%2010.2621%2010.4497C10.2245%2010.5049%2010.1929%2010.5632%2010.167%2010.6245C10.1411%2010.6859%2010.1215%2010.7492%2010.1083%2010.8143C10.0951%2010.8795%2010.0885%2010.9452%2010.0884%2011.0116L10.0157%2014.4523L11.6997%2014.5L11.6995%2012.3143ZM25.3135%2021.8051L25.3135%2022.8167C25.7656%2022.8929%2026.2209%2022.9249%2026.6792%2022.9127C28.3381%2022.9127%2029.1675%2022.326%2029.1675%2021.1527C29.1733%2020.9869%2029.151%2020.825%2029.1006%2020.667C29.0503%2020.509%2028.9747%2020.3641%2028.8742%2020.2322C28.767%2020.1025%2028.6403%2019.9963%2028.4938%2019.9134C28.3474%2019.8306%2028.191%2019.7767%2028.0246%2019.7517L28.0246%2019.7011C28.0971%2019.6839%2028.1676%2019.6606%2028.236%2019.6311C28.3044%2019.6016%2028.3698%2019.5665%2028.4321%2019.5257C28.4944%2019.4848%2028.5526%2019.4389%2028.6069%2019.3879C28.6613%2019.3369%2028.7109%2019.2816%2028.7556%2019.222C28.8003%2019.1624%2028.8394%2019.0994%2028.8732%2019.033C28.9069%2018.9665%2028.9346%2018.8977%2028.9564%2018.8265C28.9782%2018.7552%2028.9937%2018.6826%2029.0028%2018.6086C29.0119%2018.5347%2029.0145%2018.4605%2029.0107%2018.3861C29.0217%2018.2675%2029.0176%2018.1495%2028.9984%2018.0319C28.9791%2017.9144%2028.9454%2017.8012%2028.8971%2017.6923C28.8489%2017.5834%2028.7875%2017.4823%2028.7134%2017.3891C28.6393%2017.2959%2028.5547%2017.2135%2028.4595%2017.1419C28.219%2017.0003%2027.963%2016.8972%2027.6915%2016.8326C27.4199%2016.7679%2027.1449%2016.7446%2026.8664%2016.7626C26.6258%2016.7621%2026.3864%2016.7791%2026.1482%2016.8132C25.9479%2016.8386%2025.7504%2016.8791%2025.5563%2016.9346L25.5563%2017.8854C25.743%2017.8264%2025.9337%2017.7842%2026.128%2017.759C26.3276%2017.73%2026.5282%2017.7148%2026.7298%2017.7134C27.0252%2017.6949%2027.3049%2017.7523%2027.5692%2017.8854C27.6168%2017.9161%2027.6595%2017.9525%2027.6972%2017.9947C27.7348%2018.037%2027.766%2018.0835%2027.791%2018.1343C27.816%2018.1851%2027.8337%2018.2383%2027.8441%2018.294C27.8545%2018.3496%2027.8573%2018.4056%2027.8525%2018.462C27.8566%2018.5278%2027.8514%2018.5927%2027.8367%2018.657C27.822%2018.7212%2027.7986%2018.7821%2027.7663%2018.8395C27.734%2018.897%2027.694%2018.9487%2027.6468%2018.9946C27.5995%2019.0405%2027.5468%2019.0787%2027.4885%2019.1093C27.1544%2019.2631%2026.8037%2019.3306%2026.4364%2019.3117L25.9862%2019.3117L25.9862%2020.1917L26.4466%2020.1917C26.8409%2020.1669%2027.2202%2020.2309%2027.5845%2020.3839C27.6459%2020.4167%2027.7011%2020.4576%2027.7505%2020.5066C27.7999%2020.5556%2027.8412%2020.6107%2027.8745%2020.6718C27.9077%2020.733%2027.9315%2020.7976%2027.9458%2020.8656C27.9602%2020.9337%2027.9644%2021.0024%2027.9587%2021.0717C27.9648%2021.1402%2027.9612%2021.2083%2027.9478%2021.2757C27.9344%2021.3432%2027.912%2021.4074%2027.8801%2021.4683C27.8483%2021.5293%2027.8086%2021.5846%2027.7609%2021.6341C27.7132%2021.6837%2027.6593%2021.7254%2027.5996%2021.7596C27.2884%2021.9045%2026.9613%2021.9685%2026.6184%2021.9518C26.1786%2021.9465%2025.7436%2021.8977%2025.3135%2021.8051ZM21.3382%2018.6238C21.3445%2018.5593%2021.343%2018.495%2021.3335%2018.4308C21.3241%2018.3667%2021.3069%2018.3046%2021.2822%2018.2447C21.2575%2018.1847%2021.226%2018.1287%2021.1876%2018.0765C21.1492%2018.0242%2021.1049%2017.9774%2021.055%2017.936C20.9359%2017.8608%2020.808%2017.806%2020.6714%2017.7714C20.5349%2017.7368%2020.3964%2017.7242%2020.2558%2017.7337C19.8009%2017.7395%2019.356%2017.8087%2018.9208%2017.9411L18.9208%2016.9598C19.4252%2016.8181%2019.9393%2016.7524%2020.4633%2016.7626C20.7322%2016.7484%2020.9964%2016.7773%2021.256%2016.8491C21.5156%2016.9209%2021.7571%2017.032%2021.9806%2017.1824C22.0729%2017.2601%2022.1548%2017.3474%2022.2263%2017.4446C22.2978%2017.5418%2022.3567%2017.646%2022.4034%2017.7573C22.45%2017.8686%2022.483%2017.9838%2022.5021%2018.1029C22.5213%2018.222%2022.5261%2018.3417%2022.5167%2018.462C22.5245%2018.7882%2022.4655%2019.1017%2022.3396%2019.4027C22.1879%2019.7384%2021.984%2020.0384%2021.7277%2020.3029C21.3021%2020.7337%2020.8502%2021.135%2020.3721%2021.5067L19.9928%2021.8051L19.9928%2021.8759L22.6938%2021.8759L22.6938%2022.8419L18.5464%2022.8419L18.5464%2021.7697C19.2882%2021.1796%2019.8579%2020.6975%2020.2558%2020.3232C20.574%2020.0432%2020.8523%2019.728%2021.0905%2019.3774C21.1675%2019.2665%2021.2269%2019.1469%2021.2691%2019.0187C21.3113%2018.8904%2021.3344%2018.7588%2021.3382%2018.6238ZM12.3102%2017.2127L12.3102%2018.1939L13.7769%2017.9107L13.7769%2022.8419L14.9605%2022.8419L14.9605%2016.8486L14.0957%2016.8486L12.3102%2017.2127ZM28.5524%2028.0475C28.5524%2028.104%2028.5467%2028.1599%2028.5353%2028.2152C28.5239%2028.2706%2028.5071%2028.3244%2028.4849%2028.3766C28.4626%2028.4287%2028.4352%2028.4782%2028.4028%2028.5252C28.3705%2028.5721%2028.3337%2028.6156%2028.2925%2028.6555C28.2513%2028.6954%2028.2067%2028.731%2028.1583%2028.7624C28.1098%2028.7937%2028.0587%2028.8202%2028.0049%2028.8418C27.9511%2028.8634%2027.8957%2028.8798%2027.8385%2028.8908C27.7814%2028.9018%2027.7235%2028.9073%2027.6653%2028.9073L24.1832%2028.8418L24.1832%2030.3617L29.1397%2030.3617C29.2082%2030.3617%2029.276%2030.3552%2029.3432%2030.3423C29.4104%2030.3293%2029.4756%2030.3101%2029.5389%2030.2847C29.6022%2030.2593%2029.6625%2030.2281%2029.7195%2030.1912C29.7765%2030.1543%2029.829%2030.1124%2029.8774%2030.0654C29.9259%2030.0184%2029.9693%2029.9673%2030.0074%2029.9121C30.0454%2029.8569%2030.0774%2029.7986%2030.1037%2029.7373C30.1299%2029.6759%2030.1497%2029.6126%2030.163%2029.5475C30.1764%2029.4823%2030.1831%2029.4166%2030.1832%2029.3502L30.1832%2026.0478L28.4785%2026L28.5524%2028.0475ZM11.6308%2028.0099C11.6308%2028.0664%2011.6365%2028.1223%2011.6479%2028.1777C11.6592%2028.233%2011.676%2028.2868%2011.6983%2028.339C11.7206%2028.3911%2011.748%2028.4406%2011.7803%2028.4876C11.8127%2028.5345%2011.8495%2028.578%2011.8906%2028.6179C11.9318%2028.6578%2011.9765%2028.6934%2012.0249%2028.7248C12.0733%2028.7562%2012.1244%2028.7826%2012.1783%2028.8042C12.2321%2028.8259%2012.2875%2028.8422%2012.3446%2028.8532C12.4017%2028.8642%2012.4596%2028.8697%2012.5178%2028.8698L16%2028.8042L16%2030.3241L11.0435%2030.3241C10.975%2030.3241%2010.9071%2030.3176%2010.8399%2030.3047C10.7727%2030.2917%2010.7076%2030.2725%2010.6443%2030.2471C10.581%2030.2217%2010.5206%2030.1906%2010.4637%2030.1537C10.4067%2030.1168%2010.3542%2030.0748%2010.3057%2030.0278C10.2573%2029.9809%2010.2138%2029.9298%2010.1758%2029.8745C10.1377%2029.8193%2010.1057%2029.7611%2010.0795%2029.6997C10.0533%2029.6383%2010.0335%2029.575%2010.0201%2029.5099C10.0068%2029.4448%2010%2029.379%2010%2029.3126L10%2026.0478L11.7047%2026L11.6308%2028.0099Z'%20fill='rgb(14,191,241)'%20fill-rule='evenodd'%20/%3e%3c/g%3e%3c/g%3e%3c/svg%3e", _2 = "data:image/svg+xml,%3csvg%20viewBox='0%200%2040%2040'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%20width='40.000000'%20height='40.000000'%20fill='none'%20customFrame='url(%23clipPath_9)'%3e%3cdefs%3e%3cclipPath%20id='clipPath_9'%3e%3crect%20width='40.000000'%20height='40.000000'%20x='0.000000'%20y='0.000000'%20rx='12.000000'%20fill='rgb(255,255,255)'%20/%3e%3c/clipPath%3e%3cclipPath%20id='clipPath_10'%3e%3crect%20width='24.000000'%20height='24.000000'%20x='8.000000'%20y='8.000000'%20fill='rgb(255,255,255)'%20/%3e%3c/clipPath%3e%3cclipPath%20id='clipPath_11'%3e%3crect%20width='20.000000'%20height='20.000000'%20x='10.000000'%20y='10.000000'%20fill='rgb(255,255,255)'%20/%3e%3c/clipPath%3e%3c/defs%3e%3crect%20id='3'%20width='40.000000'%20height='40.000000'%20x='0.000000'%20y='0.000000'%20rx='12.000000'%20fill='rgb(236,250,254)'%20/%3e%3cg%20id='画板%202310'%20customFrame='url(%23clipPath_10)'%3e%3crect%20id='画板%202310'%20width='24.000000'%20height='24.000000'%20x='8.000000'%20y='8.000000'%20fill='rgb(255,255,255)'%20fill-opacity='0'%20/%3e%3cg%20id='人事服务'%3e%3cg%20id='ic_public_link'%20clip-path='url(%23clipPath_11)'%20customFrame='url(%23clipPath_11)'%3e%3crect%20id='ic_public_link'%20width='20.000000'%20height='20.000000'%20x='10.000000'%20y='10.000000'%20/%3e%3cpath%20id='path1'%20d='M9.9999%2019.9917C9.9999%2018.4292%209.99573%2016.8667%209.9999%2015.3042C9.99573%2014.5459%2010.0916%2013.7917%2010.2749%2013.0626C10.6874%2011.5126%2011.6957%2010.5917%2013.2457%2010.2334C14.0207%2010.0667%2014.8166%209.98756%2015.6082%2010.0001C18.6041%2010.0001%2021.5999%2010.0001%2024.5999%2010.0001C25.3541%209.99589%2026.1082%2010.0792%2026.8457%2010.2584C28.4416%2010.6459%2029.3999%2011.6584%2029.7624%2013.2501C29.9291%2014.0001%2030.0041%2014.7667%2029.9957%2015.5376C29.9957%2018.5667%2029.9957%2021.5959%2029.9957%2024.6209C29.9999%2025.3709%2029.9166%2026.1209%2029.7416%2026.8459C29.3499%2028.4459%2028.3332%2029.3959%2026.7457%2029.7626C25.9666%2029.9292%2025.1749%2030.0084%2024.3791%2029.9959C21.3957%2029.9959%2018.4124%2029.9959%2015.4291%2029.9959C14.6666%2030.0042%2013.9082%2029.9167%2013.1666%2029.7417C11.5624%2029.3542%2010.5999%2028.3376%2010.2374%2026.7376C10.0499%2025.9251%209.9999%2025.1126%209.9999%2024.2917C9.9999%2022.8584%209.9999%2021.4251%209.9999%2019.9917Z'%20fill='rgb(255,255,255)'%20fill-opacity='0'%20fill-rule='evenodd'%20/%3e%3ccircle%20id='path2'%20cx='20'%20cy='20'%20r='10'%20fill='rgb(255,255,255)'%20fill-opacity='0'%20/%3e%3cpath%20id='path3'%20d='M25.0333%2021.8666L26.9%2020C28.8083%2018.0916%2028.8083%2015%2026.9%2013.0958C24.9958%2011.1875%2021.9041%2011.1875%2020%2013.0958L18.1291%2014.9625M21.8666%2025.0333L20%2026.9C18.0916%2028.8083%2015%2028.8083%2013.0958%2026.9C11.1875%2024.9958%2011.1875%2021.9041%2013.0958%2020L14.9625%2018.1291'%20fill-rule='nonzero'%20stroke='rgb(14,191,241)'%20stroke-linecap='round'%20stroke-width='1.25'%20/%3e%3cpath%20id='pah4'%20d='M18.125%2021.875L21.875%2018.125'%20stroke='rgb(14,191,241)'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-width='1.25'%20/%3e%3cpath%20id='path5'%20d='M25.8207%2019.2626L24.0457%2021.0376C23.7998%2021.2834%2023.6748%2021.5292%2023.6748%2021.7751C23.6748%2022.0209%2023.7998%2022.2667%2024.0457%2022.5126C24.1498%2022.6167%2024.2665%2022.6959%2024.3915%2022.7459C24.5123%2022.7917%2024.6415%2022.8167%2024.779%2022.8167C24.9207%2022.8167%2025.0498%2022.7917%2025.1665%2022.7459C25.2957%2022.6959%2025.4123%2022.6167%2025.5165%2022.5126L27.2915%2020.7334C27.8165%2020.2126%2028.2165%2019.6334%2028.4957%2019.0001C28.5082%2018.9667%2028.5248%2018.9334%2028.5373%2018.8959C28.554%2018.8626%2028.5665%2018.8292%2028.579%2018.7917C28.8332%2018.1501%2028.9582%2017.4584%2028.9582%2016.7209C28.9582%2015.9792%2028.8332%2015.2876%2028.579%2014.6459C28.5665%2014.6084%2028.554%2014.5751%2028.5373%2014.5417C28.5248%2014.5042%2028.5082%2014.4709%2028.4957%2014.4376C28.2165%2013.8042%2027.8165%2013.2292%2027.2915%2012.7042C26.7707%2012.1792%2026.1915%2011.7792%2025.5582%2011.5001C25.5248%2011.4876%2025.4915%2011.4709%2025.454%2011.4584C25.4207%2011.4417%2025.3873%2011.4292%2025.354%2011.4167C24.7082%2011.1667%2024.0165%2011.0417%2023.279%2011.0417C22.5373%2011.0417%2021.8457%2011.1667%2021.204%2011.4167C21.1665%2011.4292%2021.1332%2011.4417%2021.0998%2011.4584C21.0623%2011.4709%2021.029%2011.4876%2020.9957%2011.5001C20.3623%2011.7792%2019.7832%2012.1792%2019.2623%2012.7042L17.4832%2014.4792C17.379%2014.5834%2017.2998%2014.7001%2017.2498%2014.8292C17.204%2014.9501%2017.179%2015.0751%2017.179%2015.2167C17.179%2015.3542%2017.204%2015.4834%2017.2498%2015.6042C17.2998%2015.7292%2017.379%2015.8459%2017.4832%2015.9542C17.5915%2016.0584%2017.7082%2016.1376%2017.8332%2016.1876C17.954%2016.2334%2018.0832%2016.2584%2018.2207%2016.2584C18.3623%2016.2584%2018.4915%2016.2334%2018.6082%2016.1876C18.7373%2016.1376%2018.854%2016.0584%2018.9582%2015.9542L20.7332%2014.1751C21.0873%2013.8209%2021.4748%2013.5584%2021.8957%2013.3834C22.3165%2013.2084%2022.779%2013.1251%2023.279%2013.1251C23.7748%2013.1251%2024.2373%2013.2084%2024.6582%2013.3834C25.079%2013.5584%2025.4665%2013.8209%2025.8207%2014.1751C26.1748%2014.5292%2026.4373%2014.9167%2026.6123%2015.3376C26.7873%2015.7584%2026.8748%2016.2167%2026.8748%2016.7209C26.8748%2017.2209%2026.7873%2017.6792%2026.6123%2018.1001C26.4373%2018.5209%2026.1748%2018.9084%2025.8207%2019.2626ZM13.3832%2021.8959C13.5582%2021.4751%2013.8207%2021.0876%2014.1748%2020.7334L15.954%2018.9584C16.0582%2018.8542%2016.1373%2018.7376%2016.1873%2018.6084C16.2332%2018.4876%2016.2582%2018.3626%2016.2582%2018.2209C16.2582%2018.0834%2016.2332%2017.9542%2016.1873%2017.8334C16.1373%2017.7084%2016.0582%2017.5917%2015.954%2017.4834C15.7082%2017.2417%2015.4623%2017.1167%2015.2165%2017.1167C14.9707%2017.1167%2014.7248%2017.2417%2014.479%2017.4834L12.704%2019.2626C12.179%2019.7876%2011.779%2020.3626%2011.4998%2020.9959C11.4873%2021.0292%2011.4707%2021.0626%2011.4582%2021.1001C11.4415%2021.1334%2011.429%2021.1667%2011.4165%2021.2042C11.1665%2021.8459%2011.0415%2022.5376%2011.0415%2023.2792C11.0415%2024.0167%2011.1665%2024.7084%2011.4165%2025.3542C11.429%2025.3876%2011.4415%2025.4209%2011.4582%2025.4584C11.4707%2025.4917%2011.4873%2025.5251%2011.4998%2025.5584C11.779%2026.1917%2012.179%2026.7709%2012.704%2027.2917C13.2248%2027.8167%2013.804%2028.2167%2014.4373%2028.4959C14.4707%2028.5084%2014.504%2028.5251%2014.5415%2028.5376C14.5748%2028.5542%2014.6082%2028.5667%2014.6457%2028.5792C15.2873%2028.8292%2015.979%2028.9584%2016.7207%2028.9584C17.4582%2028.9584%2018.1498%2028.8292%2018.7915%2028.5792C18.829%2028.5667%2018.8623%2028.5542%2018.8957%2028.5376C18.9332%2028.5251%2018.9665%2028.5084%2018.9998%2028.4959C19.6332%2028.2167%2020.2123%2027.8167%2020.7332%2027.2917L22.5123%2025.5167C22.6165%2025.4126%2022.6957%2025.2959%2022.7457%2025.1667C22.7915%2025.0459%2022.8165%2024.9209%2022.8165%2024.7792C22.8165%2024.6417%2022.7915%2024.5126%2022.7457%2024.3917C22.6957%2024.2667%2022.6165%2024.1501%2022.5123%2024.0417C22.2665%2023.8001%2022.0207%2023.6751%2021.7748%2023.6751C21.529%2023.6751%2021.2832%2023.8001%2021.0373%2024.0417L19.2623%2025.8209C18.9082%2026.1751%2018.5207%2026.4376%2018.0998%2026.6126C17.679%2026.7876%2017.2165%2026.8751%2016.7207%2026.8751C16.2207%2026.8751%2015.7582%2026.7876%2015.3373%2026.6126C14.9165%2026.4376%2014.529%2026.1751%2014.1748%2025.8209C13.8207%2025.4667%2013.5582%2025.0792%2013.3832%2024.6584C13.2082%2024.2376%2013.1248%2023.7792%2013.1248%2023.2792C13.1248%2022.7751%2013.2082%2022.3167%2013.3832%2021.8959Z'%20fill='rgb(255,255,255)'%20fill-opacity='0'%20fill-rule='evenodd'%20/%3e%3cpath%20id='path6'%20d='M21.8127%2016.7458C21.746%2016.7874%2021.6877%2016.8374%2021.6293%2016.8916L16.8918%2021.6291C16.8377%2021.6874%2016.7877%2021.7499%2016.746%2021.8124C16.7127%2021.8624%2016.6877%2021.9166%2016.6627%2021.9749C16.6377%2022.0374%2016.6168%2022.1041%2016.6043%2022.1708C16.5918%2022.2333%2016.5835%2022.2999%2016.5835%2022.3666C16.5835%2022.4333%2016.5918%2022.4999%2016.6043%2022.5666C16.6168%2022.6333%2016.6377%2022.6999%2016.6627%2022.7624C16.6877%2022.8166%2016.7127%2022.8708%2016.746%2022.9208C16.7877%2022.9874%2016.8377%2023.0499%2016.8918%2023.1041C16.946%2023.1583%2017.0085%2023.2083%2017.0752%2023.2499C17.1252%2023.2833%2017.1793%2023.3083%2017.2335%2023.3333C17.3002%2023.3583%2017.3627%2023.3791%2017.4293%2023.3916C17.496%2023.4041%2017.5627%2023.4124%2017.6293%2023.4124C17.696%2023.4124%2017.7627%2023.4041%2017.8252%2023.3916C17.8918%2023.3791%2017.9585%2023.3583%2018.021%2023.3333C18.0793%2023.3083%2018.1335%2023.2833%2018.1835%2023.2499C18.246%2023.2083%2018.3085%2023.1583%2018.3668%2023.1041L23.1043%2018.3666C23.1585%2018.3083%2023.2085%2018.2499%2023.2502%2018.1833C23.2835%2018.1333%2023.3085%2018.0791%2023.3335%2018.0208C23.3585%2017.9583%2023.3793%2017.8916%2023.3918%2017.8249C23.4043%2017.7624%2023.4127%2017.6958%2023.4127%2017.6291C23.4127%2017.5624%2023.4043%2017.4958%2023.3918%2017.4291C23.3793%2017.3624%2023.3585%2017.2999%2023.3335%2017.2333C23.3085%2017.1791%2023.2835%2017.1249%2023.2502%2017.0749C23.2085%2017.0083%2023.1585%2016.9458%2023.1043%2016.8916C23.046%2016.8374%2022.9877%2016.7874%2022.921%2016.7458C22.871%2016.7124%2022.8168%2016.6874%2022.7627%2016.6624C22.696%2016.6374%2022.6335%2016.6166%2022.5668%2016.6041C22.5002%2016.5916%2022.4335%2016.5833%2022.3668%2016.5833C22.3002%2016.5833%2022.2335%2016.5916%2022.171%2016.6041C22.1043%2016.6166%2022.0377%2016.6374%2021.9752%2016.6624C21.9168%2016.6874%2021.8627%2016.7124%2021.8127%2016.7458Z'%20fill='rgb(255,255,255)'%20fill-opacity='0'%20fill-rule='evenodd'%20/%3e%3c/g%3e%3c/g%3e%3c/g%3e%3c/svg%3e", b2 = "data:image/svg+xml,%3csvg%20viewBox='0%200%2040%2040'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%20width='40.000000'%20height='40.000000'%20fill='none'%20customFrame='url(%23clipPath_0)'%3e%3cdefs%3e%3cclipPath%20id='clipPath_0'%3e%3crect%20width='40.000000'%20height='40.000000'%20x='0.000000'%20y='0.000000'%20rx='12.000000'%20fill='rgb(255,255,255)'%20/%3e%3c/clipPath%3e%3cclipPath%20id='clipPath_1'%3e%3crect%20width='24.000000'%20height='24.000000'%20x='8.000000'%20y='8.000000'%20fill='rgb(255,255,255)'%20/%3e%3c/clipPath%3e%3cclipPath%20id='clipPath_2'%3e%3crect%20width='20.000000'%20height='20.000000'%20x='10.000000'%20y='10.000000'%20fill='rgb(255,255,255)'%20/%3e%3c/clipPath%3e%3c/defs%3e%3crect%20id='1'%20width='40.000000'%20height='40.000000'%20x='0.000000'%20y='0.000000'%20rx='12.000000'%20fill='rgb(236,250,254)'%20/%3e%3cg%20id='车辆'%20clip-path='url(%23clipPath_1)'%20customFrame='url(%23clipPath_1)'%3e%3crect%20id='车辆'%20width='24.000000'%20height='24.000000'%20x='8.000000'%20y='8.000000'%20/%3e%3cg%20id='编组'%3e%3cg%20id='ic_public_qrcode'%20clip-path='url(%23clipPath_2)'%20customFrame='url(%23clipPath_2)'%3e%3crect%20id='ic_public_qrcode'%20width='20.000000'%20height='20.000000'%20x='10.000000'%20y='10.000000'%20/%3e%3cg%20id='ic_public_qrcode_1_1'%3e%3cpath%20id='ic_public_qrcode_2_0'%20d='M10.6273%2019.9924C10.6273%2018.5277%2010.6222%2017.0631%2010.6273%2015.5985C10.6243%2014.8898%2010.7114%2014.1836%2010.8865%2013.4968C11.2702%2012.0432%2012.2171%2011.1805%2013.6693%2010.8458C14.3974%2010.6885%2015.1411%2010.6148%2015.886%2010.6261C18.6946%2010.6261%2021.5035%2010.6261%2024.3127%2010.6261C25.0221%2010.6217%2025.7295%2010.7029%2026.4195%2010.8678C27.9156%2011.2339%2028.8134%2012.1816%2029.1554%2013.6725C29.3092%2014.3772%2029.3826%2015.097%2029.3744%2015.8182C29.3744%2018.6571%2029.3744%2021.4963%2029.3744%2024.3357C29.3782%2025.0383%2029.2973%2025.7388%2029.1334%2026.422C28.7673%2027.9189%2027.8153%2028.8123%2026.3243%2029.1543C25.5961%2029.311%2024.8524%2029.3847%2024.1076%2029.374C21.3107%2029.374%2018.514%2029.374%2015.7176%2029.374C15.0027%2029.3798%2014.2897%2029.2999%2013.5939%2029.136C12.0912%2028.7698%2011.189%2027.8178%2010.8477%2026.3195C10.6734%2025.5579%2010.6273%2024.7941%2010.6273%2024.0237C10.6273%2022.6802%2010.6273%2021.3364%2010.6273%2019.9924Z'%20fill='rgb(255,255,255)'%20fill-opacity='0'%20fill-rule='nonzero'%20/%3e%3cpath%20id='ic_public_qrcode_2_0'%20d='M10.6273%2015.5985C10.6243%2014.8898%2010.7114%2014.1836%2010.8865%2013.4968C11.2702%2012.0432%2012.2171%2011.1805%2013.6693%2010.8458C14.3974%2010.6885%2015.1411%2010.6148%2015.886%2010.6261C18.6946%2010.6261%2021.5035%2010.6261%2024.3127%2010.6261C25.0221%2010.6217%2025.7295%2010.7029%2026.4195%2010.8678C27.9156%2011.2339%2028.8134%2012.1816%2029.1554%2013.6725C29.3092%2014.3772%2029.3826%2015.097%2029.3744%2015.8182C29.3744%2018.6571%2029.3744%2021.4963%2029.3744%2024.3357C29.3782%2025.0383%2029.2973%2025.7388%2029.1334%2026.422C28.7673%2027.9189%2027.8153%2028.8123%2026.3243%2029.1543C25.5961%2029.311%2024.8524%2029.3847%2024.1076%2029.374C21.3107%2029.374%2018.514%2029.374%2015.7176%2029.374C15.0027%2029.3798%2014.2897%2029.2999%2013.5939%2029.136C12.0912%2028.7698%2011.189%2027.8178%2010.8477%2026.3195C10.6734%2025.5579%2010.6273%2024.7941%2010.6273%2024.0237C10.6273%2022.6802%2010.6273%2021.3364%2010.6273%2019.9924C10.6273%2018.5277%2010.6222%2017.0631%2010.6273%2015.5985Z'%20fill-rule='nonzero'%20stroke='rgb(255,255,255)'%20stroke-opacity='0'%20stroke-width='1.25'%20/%3e%3cpath%20id='ic_public_qrcode_2_1'%20d='M10.6273%2015.5985C10.6243%2014.8898%2010.7114%2014.1836%2010.8865%2013.4968C11.2702%2012.0432%2012.2171%2011.1805%2013.6693%2010.8458C14.3974%2010.6885%2015.1411%2010.6148%2015.886%2010.6261C18.6946%2010.6261%2021.5035%2010.6261%2024.3127%2010.6261C25.0221%2010.6217%2025.7295%2010.7029%2026.4195%2010.8678C27.9156%2011.2339%2028.8134%2012.1816%2029.1554%2013.6725C29.3092%2014.3772%2029.3826%2015.097%2029.3744%2015.8182C29.3744%2018.6571%2029.3744%2021.4963%2029.3744%2024.3357C29.3782%2025.0383%2029.2973%2025.7388%2029.1334%2026.422C28.7673%2027.9189%2027.8153%2028.8123%2026.3243%2029.1543C25.5961%2029.311%2024.8524%2029.3847%2024.1076%2029.374C21.3107%2029.374%2018.514%2029.374%2015.7176%2029.374C15.0027%2029.3798%2014.2897%2029.2999%2013.5939%2029.136C12.0912%2028.7698%2011.189%2027.8178%2010.8477%2026.3195C10.6734%2025.5579%2010.6273%2024.7941%2010.6273%2024.0237C10.6273%2022.6802%2010.6273%2021.3364%2010.6273%2019.9924C10.6273%2018.5277%2010.6222%2017.0631%2010.6273%2015.5985Z'%20opacity='0.200000003'%20fill-rule='nonzero'%20stroke='rgb(255,255,255)'%20stroke-opacity='0'%20stroke-width='1.25'%20/%3e%3ccircle%20id='ic_public_qrcode_2_2'%20cx='20'%20cy='20'%20r='10'%20fill='rgb(255,255,255)'%20fill-opacity='0'%20/%3e%3cpath%20id='ic_public_qrcode_2_3'%20d='M17.5%2011.25C17.9602%2011.25%2018.3333%2011.6231%2018.3333%2012.0833L18.3333%2017.5C18.3333%2017.9602%2017.9602%2018.3333%2017.5%2018.3333L12.0833%2018.3333C11.6231%2018.3333%2011.25%2017.9602%2011.25%2017.5L11.25%2012.0833C11.25%2011.6231%2011.6231%2011.25%2012.0833%2011.25L17.5%2011.25ZM17.5%2021.6667C17.9602%2021.6667%2018.3333%2022.0398%2018.3333%2022.5L18.3333%2027.9167C18.3333%2028.3769%2017.9602%2028.75%2017.5%2028.75L12.0833%2028.75C11.6231%2028.75%2011.25%2028.3769%2011.25%2027.9167L11.25%2022.5C11.25%2022.0398%2011.6231%2021.6667%2012.0833%2021.6667L17.5%2021.6667ZM27.9167%2011.25C28.3769%2011.25%2028.75%2011.6231%2028.75%2012.0833L28.75%2017.5C28.75%2017.9602%2028.3769%2018.3333%2027.9167%2018.3333L22.5%2018.3333C22.0398%2018.3333%2021.6667%2017.9602%2021.6667%2017.5L21.6667%2012.0833C21.6667%2011.6231%2022.0398%2011.25%2022.5%2011.25L27.9167%2011.25Z'%20fill-rule='evenodd'%20stroke='rgb(14,191,241)'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-width='1.25'%20/%3e%3cpath%20id='ic_public_qrcode_2_4'%20d='M17.5002%2010.8333C18.1905%2010.8333%2018.7502%2011.3929%2018.7502%2012.0833L18.7502%2017.4999C18.7502%2018.1903%2018.1905%2018.7499%2017.5002%2018.7499L12.0835%2018.7499C11.3931%2018.7499%2010.8335%2018.1903%2010.8335%2017.4999L10.8335%2012.0833C10.8335%2011.3929%2011.3931%2010.8333%2012.0835%2010.8333L17.5002%2010.8333ZM17.5002%2011.6666L12.0835%2011.6666C11.8534%2011.6666%2011.6668%2011.8531%2011.6668%2012.0833L11.6668%2017.4999C11.6668%2017.73%2011.8534%2017.9166%2012.0835%2017.9166L17.5002%2017.9166C17.7303%2017.9166%2017.9168%2017.73%2017.9168%2017.4999L17.9168%2012.0833C17.9168%2011.8531%2017.7303%2011.6666%2017.5002%2011.6666ZM17.5002%2021.2499C18.1905%2021.2499%2018.7502%2021.8096%2018.7502%2022.4999L18.7502%2027.9166C18.7502%2028.6069%2018.1905%2029.1666%2017.5002%2029.1666L12.0835%2029.1666C11.3931%2029.1666%2010.8335%2028.6069%2010.8335%2027.9166L10.8335%2022.4999C10.8335%2021.8096%2011.3931%2021.2499%2012.0835%2021.2499L17.5002%2021.2499ZM17.5002%2022.0833L12.0835%2022.0833C11.8534%2022.0833%2011.6668%2022.2698%2011.6668%2022.4999L11.6668%2027.9166C11.6668%2028.1467%2011.8534%2028.3333%2012.0835%2028.3333L17.5002%2028.3333C17.7303%2028.3333%2017.9168%2028.1467%2017.9168%2027.9166L17.9168%2022.4999C17.9168%2022.2698%2017.7303%2022.0833%2017.5002%2022.0833ZM27.9168%2010.8333C28.6072%2010.8333%2029.1668%2011.3929%2029.1668%2012.0833L29.1668%2017.4999C29.1668%2018.1903%2028.6072%2018.7499%2027.9168%2018.7499L22.5002%2018.7499C21.8098%2018.7499%2021.2502%2018.1903%2021.2502%2017.4999L21.2502%2012.0833C21.2502%2011.3929%2021.8098%2010.8333%2022.5002%2010.8333L27.9168%2010.8333ZM27.9168%2011.6666L22.5002%2011.6666C22.27%2011.6666%2022.0835%2011.8531%2022.0835%2012.0833L22.0835%2017.4999C22.0835%2017.73%2022.27%2017.9166%2022.5002%2017.9166L27.9168%2017.9166C28.1469%2017.9166%2028.3335%2017.73%2028.3335%2017.4999L28.3335%2012.0833C28.3335%2011.8531%2028.1469%2011.6666%2027.9168%2011.6666Z'%20fill='rgb(255,255,255)'%20fill-opacity='0'%20fill-rule='nonzero'%20/%3e%3cpath%20id='ic_public_qrcode_2_4'%20d='M18.7502%2012.0833L18.7502%2017.4999C18.7502%2018.1903%2018.1905%2018.7499%2017.5002%2018.7499L12.0835%2018.7499C11.3931%2018.7499%2010.8335%2018.1903%2010.8335%2017.4999L10.8335%2012.0833C10.8335%2011.3929%2011.3931%2010.8333%2012.0835%2010.8333L17.5002%2010.8333C18.1905%2010.8333%2018.7502%2011.3929%2018.7502%2012.0833ZM12.0835%2011.6666C11.8534%2011.6666%2011.6668%2011.8531%2011.6668%2012.0833L11.6668%2017.4999C11.6668%2017.73%2011.8534%2017.9166%2012.0835%2017.9166L17.5002%2017.9166C17.7303%2017.9166%2017.9168%2017.73%2017.9168%2017.4999L17.9168%2012.0833C17.9168%2011.8531%2017.7303%2011.6666%2017.5002%2011.6666L12.0835%2011.6666ZM18.7502%2022.4999L18.7502%2027.9166C18.7502%2028.6069%2018.1905%2029.1666%2017.5002%2029.1666L12.0835%2029.1666C11.3931%2029.1666%2010.8335%2028.6069%2010.8335%2027.9166L10.8335%2022.4999C10.8335%2021.8096%2011.3931%2021.2499%2012.0835%2021.2499L17.5002%2021.2499C18.1905%2021.2499%2018.7502%2021.8096%2018.7502%2022.4999ZM12.0835%2022.0833C11.8534%2022.0833%2011.6668%2022.2698%2011.6668%2022.4999L11.6668%2027.9166C11.6668%2028.1467%2011.8534%2028.3333%2012.0835%2028.3333L17.5002%2028.3333C17.7303%2028.3333%2017.9168%2028.1467%2017.9168%2027.9166L17.9168%2022.4999C17.9168%2022.2698%2017.7303%2022.0833%2017.5002%2022.0833L12.0835%2022.0833ZM29.1668%2012.0833L29.1668%2017.4999C29.1668%2018.1903%2028.6072%2018.7499%2027.9168%2018.7499L22.5002%2018.7499C21.8098%2018.7499%2021.2502%2018.1903%2021.2502%2017.4999L21.2502%2012.0833C21.2502%2011.3929%2021.8098%2010.8333%2022.5002%2010.8333L27.9168%2010.8333C28.6072%2010.8333%2029.1668%2011.3929%2029.1668%2012.0833ZM22.5002%2011.6666C22.27%2011.6666%2022.0835%2011.8531%2022.0835%2012.0833L22.0835%2017.4999C22.0835%2017.73%2022.27%2017.9166%2022.5002%2017.9166L27.9168%2017.9166C28.1469%2017.9166%2028.3335%2017.73%2028.3335%2017.4999L28.3335%2012.0833C28.3335%2011.8531%2028.1469%2011.6666%2027.9168%2011.6666L22.5002%2011.6666Z'%20fill-rule='nonzero'%20stroke='rgb(255,255,255)'%20stroke-opacity='0'%20stroke-linejoin='round'%20stroke-width='1.25'%20/%3e%3cpath%20id='ic_public_qrcode_2_5'%20d='M27.9165%2021.6667L27.9165%2024.5834L28.7498%2024.5834L28.7498%2021.6667L27.9165%2021.6667ZM24.5832%2021.6667L24.5832%2022.639L24.5828%2022.6388L24.5832%2024.5834L23.6109%2024.5834L23.6107%2022.6388L21.6665%2022.639L21.6665%2021.6667L24.5832%2021.6667ZM21.6665%2025.8334L21.6665%2028.7501L22.4998%2028.7501L22.4998%2025.8334L21.6665%2025.8334ZM27.9165%2027.9167L27.9165%2028.7501L28.7498%2028.7501L28.7498%2027.9167L27.9165%2027.9167ZM25.8332%2025.8334L25.8332%2026.6667L26.6665%2026.6667L26.6665%2025.8334L25.8332%2025.8334Z'%20fill='rgb(14,191,241)'%20fill-rule='nonzero'%20/%3e%3cpath%20id='ic_public_qrcode_2_5'%20d='M27.9165%2024.5834L28.7498%2024.5834L28.7498%2021.6667L27.9165%2021.6667L27.9165%2024.5834ZM24.5832%2022.639L24.5828%2022.6388L24.5832%2024.5834L23.6109%2024.5834L23.6107%2022.6388L21.6665%2022.639L21.6665%2021.6667L24.5832%2021.6667L24.5832%2022.639ZM21.6665%2028.7501L22.4998%2028.7501L22.4998%2025.8334L21.6665%2025.8334L21.6665%2028.7501ZM27.9165%2028.7501L28.7498%2028.7501L28.7498%2027.9167L27.9165%2027.9167L27.9165%2028.7501ZM25.8332%2026.6667L26.6665%2026.6667L26.6665%2025.8334L25.8332%2025.8334L25.8332%2026.6667Z'%20fill-rule='nonzero'%20stroke='rgb(14,191,241)'%20stroke-linejoin='round'%20stroke-width='1.25'%20/%3e%3cpath%20id='ic_public_qrcode_2_6'%20d='M14.375%2014.375L14.375%2015.2083L15.2083%2015.2083L15.2083%2014.375L14.375%2014.375ZM14.375%2024.7917L14.375%2025.625L15.2083%2025.625L15.2083%2024.7917L14.375%2024.7917ZM24.7917%2014.375L24.7917%2015.2083L25.625%2015.2083L25.625%2014.375L24.7917%2014.375Z'%20fill='rgb(14,191,241)'%20fill-rule='nonzero'%20/%3e%3cpath%20id='ic_public_qrcode_2_6'%20d='M14.375%2015.2083L15.2083%2015.2083L15.2083%2014.375L14.375%2014.375L14.375%2015.2083ZM14.375%2025.625L15.2083%2025.625L15.2083%2024.7917L14.375%2024.7917L14.375%2025.625ZM24.7917%2015.2083L25.625%2015.2083L25.625%2014.375L24.7917%2014.375L24.7917%2015.2083Z'%20fill-rule='nonzero'%20stroke='rgb(14,191,241)'%20stroke-linejoin='round'%20stroke-width='1.25'%20/%3e%3c/g%3e%3c/g%3e%3c/g%3e%3c/g%3e%3c/svg%3e", x2 = "data:image/svg+xml,%3csvg%20viewBox='0%200%2012%2012'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%20width='12.000000'%20height='12.000000'%20fill='none'%3e%3cdefs%3e%3cfilter%20id='pixso_custom_mask_type_luminance'%3e%3cfeColorMatrix%20type='matrix'%20values='1%200%200%200%200%200%201%200%200%200%200%200%201%200%200%200%200%200%201%200%20'%20/%3e%3c/filter%3e%3c/defs%3e%3cmask%20id='mask_0'%20width='11.999876'%20height='11.999876'%20x='0.000000'%20y='0.000000'%20maskUnits='userSpaceOnUse'%3e%3cg%20filter='url(%23pixso_custom_mask_type_luminance)'%3e%3cg%20id='mask401_19830'%3e%3cpath%20id='蒙版'%20d='M0%200L11.9999%200L11.9999%2011.9999L0%2011.9999L0%200ZM2.69992%201.34999L8.09977%201.34999C9.5082%201.34999%2010.6498%202.49167%2010.6498%203.89998L10.6498%209.2999C10.6498%2010.7082%209.5082%2011.8499%208.09977%2011.8499L2.69992%2011.8499C1.29149%2011.8499%200.149901%2010.7082%200.149901%209.2999L0.149901%203.89998C0.149901%202.49167%201.29149%201.34999%202.69992%201.34999Z'%20fill='rgb(196,196,196)'%20fill-rule='evenodd'%20/%3e%3c/g%3e%3c/g%3e%3c/mask%3e%3crect%20id='ic_public_copy'%20width='12.000000'%20height='12.000000'%20x='0.000000'%20y='0.000000'%20/%3e%3crect%20id='ic_public_copy-复制/base/ic_public_copy'%20width='11.999876'%20height='11.999876'%20x='0.000000'%20y='0.000000'%20fill='rgb(255,255,255)'%20fill-opacity='0'%20/%3e%3cpath%20id='path1'%20d='M0.000134537%205.99497C0.000134537%205.05748%20-0.00236544%204.11999%200.000134537%203.1825C-0.00236544%202.72751%200.055134%202.27501%200.165133%201.83752C0.41263%200.907526%201.01762%200.355032%201.94761%200.140034C2.41261%200.040035%202.8901%20-0.00746449%203.3651%203.54269e-05C5.16258%203.54269e-05%206.96006%203.54269e-05%208.76004%203.54269e-05C9.21254%20-0.00246455%209.66503%200.0475349%2010.1075%200.155034C11.065%200.387531%2011.64%200.995025%2011.8575%201.95002C11.9575%202.40001%2012.005%202.86001%2011.9975%203.3225C11.9975%205.13998%2011.9975%206.95746%2011.9975%208.77244C12%209.22244%2011.95%209.67243%2011.845%2010.1099C11.61%2011.0674%2011%2011.6374%2010.0475%2011.8574C9.58003%2011.9574%209.10504%2012.0049%208.62754%2011.9974C6.83756%2011.9974%205.04758%2011.9974%203.2576%2011.9974C2.80011%2012.0024%202.34511%2011.9499%201.90011%2011.8449C0.937625%2011.6124%200.360131%2011.0024%200.142633%2010.0424C0.0301342%209.55494%200.000134537%209.06744%200.000134537%208.57495C0.000134537%207.71495%200.000134537%206.85496%200.000134537%205.99497Z'%20fill='rgb(255,255,255)'%20fill-opacity='0'%20fill-rule='evenodd'%20/%3e%3ccircle%20id='path2'%20cx='5.99993801'%20cy='5.99993801'%20r='5.99993801'%20fill='rgb(255,255,255)'%20fill-opacity='0'%20/%3e%3cg%20id='mask'%20mask='url(%23mask_0)'%3e%3cg%20id='组合%208'%3e%3cpath%20id='path'%20d='M11.1%203.89993L11.1%206.8999C11.1%208.55488%209.75502%209.89737%208.10004%209.89737L5.10007%209.89737C3.44258%209.89737%202.1001%208.55488%202.1001%206.8999L2.1001%203.89993C2.1001%202.24245%203.44258%200.897461%205.10007%200.897461L8.10004%200.897461C9.75502%200.897461%2011.1%202.24245%2011.1%203.89993Z'%20fill-rule='nonzero'%20stroke='rgb(25,25,25)'%20stroke-linejoin='round'%20stroke-width='0.749992251'%20/%3e%3c/g%3e%3c/g%3e%3cpath%20id='path4'%20d='M2.10008%202.39746L8.10002%202.39746C8.92751%202.39746%209.6%203.06995%209.6%203.89995L9.6%209.89738C9.6%2010.7274%208.92751%2011.3999%208.10002%2011.3999L2.10008%2011.3999C1.27009%2011.3999%200.600098%2010.7274%200.600098%209.89738L0.600098%203.89995C0.600098%203.06995%201.27009%202.39746%202.10008%202.39746Z'%20fill='rgb(255,255,255)'%20fill-opacity='0'%20fill-rule='evenodd'%20/%3e%3cpath%20id='path4'%20d='M9.6%203.89995L9.6%209.89738C9.6%2010.7274%208.92751%2011.3999%208.10002%2011.3999L2.10008%2011.3999C1.27009%2011.3999%200.600098%2010.7274%200.600098%209.89738L0.600098%203.89995C0.600098%203.06995%201.27009%202.39746%202.10008%202.39746L8.10002%202.39746C8.92751%202.39746%209.6%203.06995%209.6%203.89995Z'%20fill-rule='nonzero'%20stroke='rgb(25,25,25)'%20stroke-linejoin='round'%20stroke-width='0.749992251'%20/%3e%3c/svg%3e", L2 = "https://chat.opentiny.design", k2 = "https://ai.opentiny.design/next-remoter", S2 = "https://ai.opentiny.design/next-remoter/svgs/logo-next-no-bg-left.svg", Ge = (t) => {
|
|
905
905
|
const e = !!t.sessionId;
|
|
906
906
|
return [
|
|
907
907
|
{
|
|
@@ -909,14 +909,14 @@ const w2 = "data:image/svg+xml,%3csvg%20viewBox='0%200%2040%2039.9692'%20xmlns='
|
|
|
909
909
|
show: e,
|
|
910
910
|
text: "扫码登录",
|
|
911
911
|
desc: "使用手机遥控页面",
|
|
912
|
-
icon:
|
|
912
|
+
icon: b2
|
|
913
913
|
},
|
|
914
914
|
{
|
|
915
915
|
action: "ai-chat",
|
|
916
916
|
show: !0,
|
|
917
917
|
text: "打开对话框",
|
|
918
918
|
desc: "支持在网页端操作AI",
|
|
919
|
-
icon:
|
|
919
|
+
icon: v2
|
|
920
920
|
},
|
|
921
921
|
{
|
|
922
922
|
action: "remote-url",
|
|
@@ -926,7 +926,7 @@ const w2 = "data:image/svg+xml,%3csvg%20viewBox='0%200%2040%2039.9692'%20xmlns='
|
|
|
926
926
|
active: !0,
|
|
927
927
|
tip: t.remoteUrl,
|
|
928
928
|
showCopyIcon: !0,
|
|
929
|
-
icon:
|
|
929
|
+
icon: _2
|
|
930
930
|
},
|
|
931
931
|
{
|
|
932
932
|
action: "remote-control",
|
|
@@ -935,11 +935,11 @@ const w2 = "data:image/svg+xml,%3csvg%20viewBox='0%200%2040%2039.9692'%20xmlns='
|
|
|
935
935
|
desc: e ? `${t.sessionId.slice(-6)}` : "",
|
|
936
936
|
know: !0,
|
|
937
937
|
showCopyIcon: !0,
|
|
938
|
-
icon:
|
|
938
|
+
icon: C2
|
|
939
939
|
}
|
|
940
940
|
];
|
|
941
941
|
};
|
|
942
|
-
class
|
|
942
|
+
class P2 {
|
|
943
943
|
constructor(e) {
|
|
944
944
|
this.isExpanded = !1, this.closingTimer = 0, this.getImageUrl = (r) => {
|
|
945
945
|
if (!r) return;
|
|
@@ -955,16 +955,16 @@ class S2 {
|
|
|
955
955
|
});
|
|
956
956
|
}, this.readyTips = (r) => {
|
|
957
957
|
const n = document.getElementById(r);
|
|
958
|
-
n && new
|
|
958
|
+
n && new w2(n, {
|
|
959
959
|
content: "复制",
|
|
960
960
|
placement: "top",
|
|
961
961
|
trigger: "hover"
|
|
962
962
|
});
|
|
963
963
|
}, this.options = {
|
|
964
964
|
...e,
|
|
965
|
-
qrCodeUrl: e.qrCodeUrl ||
|
|
966
|
-
remoteUrl: e.remoteUrl ||
|
|
967
|
-
logoUrl: e.logoUrl ||
|
|
965
|
+
qrCodeUrl: e.qrCodeUrl || k2,
|
|
966
|
+
remoteUrl: e.remoteUrl || L2,
|
|
967
|
+
logoUrl: e.logoUrl || S2
|
|
968
968
|
}, e.menuItems && e.menuItems.length === 0 ? this.menuItems = [] : this.menuItems = this.mergeMenuItems(e.menuItems), this.init();
|
|
969
969
|
}
|
|
970
970
|
// 计算 sessionPrefix 属性
|
|
@@ -977,14 +977,14 @@ class S2 {
|
|
|
977
977
|
* - 无 sessionId:不渲染任何下拉菜单,仅保留点击浮标打开对话框的能力
|
|
978
978
|
*/
|
|
979
979
|
mergeMenuItems(e) {
|
|
980
|
-
return this.options.sessionId ? e ?
|
|
980
|
+
return this.options.sessionId ? e ? Ge(this.options).map((r) => {
|
|
981
981
|
const n = e.find((o) => o.action === r.action);
|
|
982
982
|
return n ? {
|
|
983
983
|
...r,
|
|
984
984
|
...n,
|
|
985
985
|
show: n.show !== void 0 ? n.show : r.show
|
|
986
986
|
} : r;
|
|
987
|
-
}) :
|
|
987
|
+
}) : Ge(this.options) : [];
|
|
988
988
|
}
|
|
989
989
|
init() {
|
|
990
990
|
this.createFloatingBlock(), this.createDropdownMenu(), this.bindEvents(), this.addStyles();
|
|
@@ -1012,7 +1012,7 @@ class S2 {
|
|
|
1012
1012
|
<div>
|
|
1013
1013
|
${r.showCopyIcon ? `
|
|
1014
1014
|
<div class="tiny-remoter-copy-icon" id="${r.action}" data-action="${r.action}">
|
|
1015
|
-
<img src="${
|
|
1015
|
+
<img src="${x2}"/>
|
|
1016
1016
|
</div>
|
|
1017
1017
|
` : ""}
|
|
1018
1018
|
</div>
|
|
@@ -1113,7 +1113,7 @@ class S2 {
|
|
|
1113
1113
|
// 创建二维码弹窗(无 sessionId 时不展示)
|
|
1114
1114
|
async showQRCode() {
|
|
1115
1115
|
if (!this.options.sessionId) return;
|
|
1116
|
-
const r = await new
|
|
1116
|
+
const r = await new g2((this.options.qrCodeUrl || "") + this.sessionPrefix + this.options.sessionId, {}).toDataURL(), n = this.createModal(
|
|
1117
1117
|
"扫码前往智能遥控器",
|
|
1118
1118
|
`
|
|
1119
1119
|
<div style="text-align: center; padding: 32px;">
|
|
@@ -1581,23 +1581,23 @@ class S2 {
|
|
|
1581
1581
|
this.floatingBlock && (this.floatingBlock.style.display = "flex");
|
|
1582
1582
|
}
|
|
1583
1583
|
}
|
|
1584
|
-
const
|
|
1585
|
-
class
|
|
1584
|
+
const jn = (t = {}) => new P2(t);
|
|
1585
|
+
class Ke extends Error {
|
|
1586
1586
|
constructor(e, r) {
|
|
1587
1587
|
super(e), this.name = "ParseError", this.type = r.type, this.field = r.field, this.value = r.value, this.line = r.line;
|
|
1588
1588
|
}
|
|
1589
1589
|
}
|
|
1590
|
-
function
|
|
1590
|
+
function ye(t) {
|
|
1591
1591
|
}
|
|
1592
|
-
function
|
|
1592
|
+
function T2(t) {
|
|
1593
1593
|
if (typeof t == "function")
|
|
1594
1594
|
throw new TypeError(
|
|
1595
1595
|
"`callbacks` must be an object, got a function instead. Did you mean `{onEvent: fn}`?"
|
|
1596
1596
|
);
|
|
1597
|
-
const { onEvent: e =
|
|
1598
|
-
let s = "", a = !0,
|
|
1597
|
+
const { onEvent: e = ye, onError: r = ye, onRetry: n = ye, onComment: o } = t;
|
|
1598
|
+
let s = "", a = !0, c, d = "", l = "";
|
|
1599
1599
|
function u(h) {
|
|
1600
|
-
const m = a ? h.replace(/^\xEF\xBB\xBF/, "") : h, [v, b] =
|
|
1600
|
+
const m = a ? h.replace(/^\xEF\xBB\xBF/, "") : h, [v, b] = M2(`${s}${m}`);
|
|
1601
1601
|
for (const x of v)
|
|
1602
1602
|
g(x);
|
|
1603
1603
|
s = b, a = !1;
|
|
@@ -1622,18 +1622,18 @@ function P2(t) {
|
|
|
1622
1622
|
function p(h, m, v) {
|
|
1623
1623
|
switch (h) {
|
|
1624
1624
|
case "event":
|
|
1625
|
-
|
|
1625
|
+
l = m;
|
|
1626
1626
|
break;
|
|
1627
1627
|
case "data":
|
|
1628
1628
|
d = `${d}${m}
|
|
1629
1629
|
`;
|
|
1630
1630
|
break;
|
|
1631
1631
|
case "id":
|
|
1632
|
-
|
|
1632
|
+
c = m.includes("\0") ? void 0 : m;
|
|
1633
1633
|
break;
|
|
1634
1634
|
case "retry":
|
|
1635
1635
|
/^\d+$/.test(m) ? n(parseInt(m, 10)) : r(
|
|
1636
|
-
new
|
|
1636
|
+
new Ke(`Invalid \`retry\` value: "${m}"`, {
|
|
1637
1637
|
type: "invalid-retry",
|
|
1638
1638
|
value: m,
|
|
1639
1639
|
line: v
|
|
@@ -1642,7 +1642,7 @@ function P2(t) {
|
|
|
1642
1642
|
break;
|
|
1643
1643
|
default:
|
|
1644
1644
|
r(
|
|
1645
|
-
new
|
|
1645
|
+
new Ke(
|
|
1646
1646
|
`Unknown field "${h.length > 20 ? `${h.slice(0, 20)}…` : h}"`,
|
|
1647
1647
|
{ type: "unknown-field", field: h, value: m, line: v }
|
|
1648
1648
|
)
|
|
@@ -1652,20 +1652,20 @@ function P2(t) {
|
|
|
1652
1652
|
}
|
|
1653
1653
|
function f() {
|
|
1654
1654
|
d.length > 0 && e({
|
|
1655
|
-
id:
|
|
1656
|
-
event:
|
|
1655
|
+
id: c,
|
|
1656
|
+
event: l || void 0,
|
|
1657
1657
|
// If the data buffer's last character is a U+000A LINE FEED (LF) character,
|
|
1658
1658
|
// then remove the last character from the data buffer.
|
|
1659
1659
|
data: d.endsWith(`
|
|
1660
1660
|
`) ? d.slice(0, -1) : d
|
|
1661
|
-
}),
|
|
1661
|
+
}), c = void 0, d = "", l = "";
|
|
1662
1662
|
}
|
|
1663
1663
|
function y(h = {}) {
|
|
1664
|
-
s && h.consume && g(s), a = !0,
|
|
1664
|
+
s && h.consume && g(s), a = !0, c = void 0, d = "", l = "", s = "";
|
|
1665
1665
|
}
|
|
1666
1666
|
return { feed: u, reset: y };
|
|
1667
1667
|
}
|
|
1668
|
-
function
|
|
1668
|
+
function M2(t) {
|
|
1669
1669
|
const e = [];
|
|
1670
1670
|
let r = "", n = 0;
|
|
1671
1671
|
for (; n < t.length; ) {
|
|
@@ -1676,19 +1676,19 @@ function T2(t) {
|
|
|
1676
1676
|
r = t.slice(n);
|
|
1677
1677
|
break;
|
|
1678
1678
|
} else {
|
|
1679
|
-
const
|
|
1680
|
-
e.push(
|
|
1679
|
+
const c = t.slice(n, a);
|
|
1680
|
+
e.push(c), n = a + 1, t[n - 1] === "\r" && t[n] === `
|
|
1681
1681
|
` && n++;
|
|
1682
1682
|
}
|
|
1683
1683
|
}
|
|
1684
1684
|
return [e, r];
|
|
1685
1685
|
}
|
|
1686
|
-
class
|
|
1686
|
+
class ke extends TransformStream {
|
|
1687
1687
|
constructor({ onError: e, onRetry: r, onComment: n } = {}) {
|
|
1688
1688
|
let o;
|
|
1689
1689
|
super({
|
|
1690
1690
|
start(s) {
|
|
1691
|
-
o =
|
|
1691
|
+
o = T2({
|
|
1692
1692
|
onEvent: (a) => {
|
|
1693
1693
|
s.enqueue(a);
|
|
1694
1694
|
},
|
|
@@ -1705,7 +1705,7 @@ class xe extends TransformStream {
|
|
|
1705
1705
|
});
|
|
1706
1706
|
}
|
|
1707
1707
|
}
|
|
1708
|
-
var
|
|
1708
|
+
var E2 = ({
|
|
1709
1709
|
prefix: t,
|
|
1710
1710
|
size: e = 16,
|
|
1711
1711
|
alphabet: r = "0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz",
|
|
@@ -1713,25 +1713,25 @@ var M2 = ({
|
|
|
1713
1713
|
} = {}) => {
|
|
1714
1714
|
const o = () => {
|
|
1715
1715
|
const s = r.length, a = new Array(e);
|
|
1716
|
-
for (let
|
|
1717
|
-
a[
|
|
1716
|
+
for (let c = 0; c < e; c++)
|
|
1717
|
+
a[c] = r[Math.random() * s | 0];
|
|
1718
1718
|
return a.join("");
|
|
1719
1719
|
};
|
|
1720
1720
|
if (t == null)
|
|
1721
1721
|
return o;
|
|
1722
1722
|
if (r.includes(n))
|
|
1723
|
-
throw new
|
|
1723
|
+
throw new d2({
|
|
1724
1724
|
argument: "separator",
|
|
1725
1725
|
message: `The separator "${n}" must not be part of the alphabet "${r}".`
|
|
1726
1726
|
});
|
|
1727
1727
|
return () => `${t}${n}${o()}`;
|
|
1728
1728
|
};
|
|
1729
|
-
|
|
1730
|
-
function
|
|
1729
|
+
E2();
|
|
1730
|
+
function pt(t = globalThis) {
|
|
1731
1731
|
var e, r, n;
|
|
1732
1732
|
return t.window ? "runtime/browser" : (e = t.navigator) != null && e.userAgent ? `runtime/${t.navigator.userAgent.toLowerCase()}` : (n = (r = t.process) == null ? void 0 : r.versions) != null && n.node ? `runtime/node.js/${t.process.version.substring(0)}` : t.EdgeRuntime ? "runtime/vercel-edge" : "runtime/unknown";
|
|
1733
1733
|
}
|
|
1734
|
-
function
|
|
1734
|
+
function R2(t) {
|
|
1735
1735
|
if (t == null)
|
|
1736
1736
|
return {};
|
|
1737
1737
|
const e = {};
|
|
@@ -1746,19 +1746,19 @@ function E2(t) {
|
|
|
1746
1746
|
}
|
|
1747
1747
|
return e;
|
|
1748
1748
|
}
|
|
1749
|
-
function
|
|
1750
|
-
const r = new Headers(
|
|
1749
|
+
function ht(t, ...e) {
|
|
1750
|
+
const r = new Headers(R2(t)), n = r.get("user-agent") || "";
|
|
1751
1751
|
return r.set(
|
|
1752
1752
|
"user-agent",
|
|
1753
1753
|
[n, ...e].filter(Boolean).join(" ")
|
|
1754
1754
|
), Object.fromEntries(r.entries());
|
|
1755
1755
|
}
|
|
1756
|
-
var
|
|
1757
|
-
function
|
|
1756
|
+
var I2 = /"(?:_|\\u005[Ff])(?:_|\\u005[Ff])(?:p|\\u0070)(?:r|\\u0072)(?:o|\\u006[Ff])(?:t|\\u0074)(?:o|\\u006[Ff])(?:_|\\u005[Ff])(?:_|\\u005[Ff])"\s*:/, A2 = /"(?:c|\\u0063)(?:o|\\u006[Ff])(?:n|\\u006[Ee])(?:s|\\u0073)(?:t|\\u0074)(?:r|\\u0072)(?:u|\\u0075)(?:c|\\u0063)(?:t|\\u0074)(?:o|\\u006[Ff])(?:r|\\u0072)"\s*:/;
|
|
1757
|
+
function Ye(t) {
|
|
1758
1758
|
const e = JSON.parse(t);
|
|
1759
|
-
return e === null || typeof e != "object" ||
|
|
1759
|
+
return e === null || typeof e != "object" || I2.test(t) === !1 && A2.test(t) === !1 ? e : O2(e);
|
|
1760
1760
|
}
|
|
1761
|
-
function
|
|
1761
|
+
function O2(t) {
|
|
1762
1762
|
let e = [t];
|
|
1763
1763
|
for (; e.length; ) {
|
|
1764
1764
|
const r = e;
|
|
@@ -1776,40 +1776,40 @@ function A2(t) {
|
|
|
1776
1776
|
}
|
|
1777
1777
|
return t;
|
|
1778
1778
|
}
|
|
1779
|
-
function
|
|
1779
|
+
function $2(t) {
|
|
1780
1780
|
const { stackTraceLimit: e } = Error;
|
|
1781
1781
|
try {
|
|
1782
1782
|
Error.stackTraceLimit = 0;
|
|
1783
1783
|
} catch {
|
|
1784
|
-
return
|
|
1784
|
+
return Ye(t);
|
|
1785
1785
|
}
|
|
1786
1786
|
try {
|
|
1787
|
-
return
|
|
1787
|
+
return Ye(t);
|
|
1788
1788
|
} finally {
|
|
1789
1789
|
Error.stackTraceLimit = e;
|
|
1790
1790
|
}
|
|
1791
1791
|
}
|
|
1792
|
-
function
|
|
1792
|
+
function Oe(t) {
|
|
1793
1793
|
if (t.type === "object" || Array.isArray(t.type) && t.type.includes("object")) {
|
|
1794
1794
|
t.additionalProperties = !1;
|
|
1795
1795
|
const { properties: r } = t;
|
|
1796
1796
|
if (r != null)
|
|
1797
1797
|
for (const n of Object.keys(r))
|
|
1798
|
-
r[n] =
|
|
1798
|
+
r[n] = z(r[n]);
|
|
1799
1799
|
}
|
|
1800
|
-
t.items != null && (t.items = Array.isArray(t.items) ? t.items.map(
|
|
1800
|
+
t.items != null && (t.items = Array.isArray(t.items) ? t.items.map(z) : z(t.items)), t.anyOf != null && (t.anyOf = t.anyOf.map(z)), t.allOf != null && (t.allOf = t.allOf.map(z)), t.oneOf != null && (t.oneOf = t.oneOf.map(z));
|
|
1801
1801
|
const { definitions: e } = t;
|
|
1802
1802
|
if (e != null)
|
|
1803
1803
|
for (const r of Object.keys(e))
|
|
1804
|
-
e[r] =
|
|
1804
|
+
e[r] = z(e[r]);
|
|
1805
1805
|
return t;
|
|
1806
1806
|
}
|
|
1807
|
-
function
|
|
1808
|
-
return typeof t == "boolean" ? t :
|
|
1807
|
+
function z(t) {
|
|
1808
|
+
return typeof t == "boolean" ? t : Oe(t);
|
|
1809
1809
|
}
|
|
1810
|
-
var
|
|
1810
|
+
var U2 = Symbol(
|
|
1811
1811
|
"Let zodToJsonSchema decide on which parser to use"
|
|
1812
|
-
),
|
|
1812
|
+
), Qe = {
|
|
1813
1813
|
name: void 0,
|
|
1814
1814
|
$refStrategy: "root",
|
|
1815
1815
|
basePath: ["#"],
|
|
@@ -1829,17 +1829,17 @@ var $2 = Symbol(
|
|
|
1829
1829
|
emailStrategy: "format:email",
|
|
1830
1830
|
base64Strategy: "contentEncoding:base64",
|
|
1831
1831
|
nameStrategy: "ref"
|
|
1832
|
-
},
|
|
1833
|
-
...
|
|
1832
|
+
}, N2 = (t) => typeof t == "string" ? {
|
|
1833
|
+
...Qe,
|
|
1834
1834
|
name: t
|
|
1835
1835
|
} : {
|
|
1836
|
-
...
|
|
1836
|
+
...Qe,
|
|
1837
1837
|
...t
|
|
1838
1838
|
};
|
|
1839
1839
|
function T() {
|
|
1840
1840
|
return {};
|
|
1841
1841
|
}
|
|
1842
|
-
function
|
|
1842
|
+
function j2(t, e) {
|
|
1843
1843
|
var r, n, o;
|
|
1844
1844
|
const s = {
|
|
1845
1845
|
type: "array"
|
|
@@ -1849,7 +1849,7 @@ function N2(t, e) {
|
|
|
1849
1849
|
currentPath: [...e.currentPath, "items"]
|
|
1850
1850
|
})), t.minLength && (s.minItems = t.minLength.value), t.maxLength && (s.maxItems = t.maxLength.value), t.exactLength && (s.minItems = t.exactLength.value, s.maxItems = t.exactLength.value), s;
|
|
1851
1851
|
}
|
|
1852
|
-
function
|
|
1852
|
+
function Z2(t) {
|
|
1853
1853
|
const e = {
|
|
1854
1854
|
type: "integer",
|
|
1855
1855
|
format: "int64"
|
|
@@ -1869,18 +1869,18 @@ function j2(t) {
|
|
|
1869
1869
|
}
|
|
1870
1870
|
return e;
|
|
1871
1871
|
}
|
|
1872
|
-
function
|
|
1872
|
+
function z2() {
|
|
1873
1873
|
return { type: "boolean" };
|
|
1874
1874
|
}
|
|
1875
|
-
function
|
|
1875
|
+
function mt(t, e) {
|
|
1876
1876
|
return _(t.type._def, e);
|
|
1877
1877
|
}
|
|
1878
1878
|
var q2 = (t, e) => _(t.innerType._def, e);
|
|
1879
|
-
function
|
|
1879
|
+
function ft(t, e, r) {
|
|
1880
1880
|
const n = r ?? e.dateStrategy;
|
|
1881
1881
|
if (Array.isArray(n))
|
|
1882
1882
|
return {
|
|
1883
|
-
anyOf: n.map((o, s) =>
|
|
1883
|
+
anyOf: n.map((o, s) => ft(t, e, o))
|
|
1884
1884
|
};
|
|
1885
1885
|
switch (n) {
|
|
1886
1886
|
case "string":
|
|
@@ -1895,10 +1895,10 @@ function ht(t, e, r) {
|
|
|
1895
1895
|
format: "date"
|
|
1896
1896
|
};
|
|
1897
1897
|
case "integer":
|
|
1898
|
-
return
|
|
1898
|
+
return D2(t);
|
|
1899
1899
|
}
|
|
1900
1900
|
}
|
|
1901
|
-
var
|
|
1901
|
+
var D2 = (t) => {
|
|
1902
1902
|
const e = {
|
|
1903
1903
|
type: "integer",
|
|
1904
1904
|
format: "unix-time"
|
|
@@ -1914,23 +1914,23 @@ var z2 = (t) => {
|
|
|
1914
1914
|
}
|
|
1915
1915
|
return e;
|
|
1916
1916
|
};
|
|
1917
|
-
function
|
|
1917
|
+
function H2(t, e) {
|
|
1918
1918
|
return {
|
|
1919
1919
|
..._(t.innerType._def, e),
|
|
1920
1920
|
default: t.defaultValue()
|
|
1921
1921
|
};
|
|
1922
1922
|
}
|
|
1923
|
-
function
|
|
1923
|
+
function F2(t, e) {
|
|
1924
1924
|
return e.effectStrategy === "input" ? _(t.schema._def, e) : T();
|
|
1925
1925
|
}
|
|
1926
|
-
function
|
|
1926
|
+
function B2(t) {
|
|
1927
1927
|
return {
|
|
1928
1928
|
type: "string",
|
|
1929
1929
|
enum: Array.from(t.values)
|
|
1930
1930
|
};
|
|
1931
1931
|
}
|
|
1932
|
-
var
|
|
1933
|
-
function
|
|
1932
|
+
var V2 = (t) => "type" in t && t.type === "string" ? !1 : "allOf" in t;
|
|
1933
|
+
function J2(t, e) {
|
|
1934
1934
|
const r = [
|
|
1935
1935
|
_(t.left._def, {
|
|
1936
1936
|
...e,
|
|
@@ -1942,19 +1942,19 @@ function V2(t, e) {
|
|
|
1942
1942
|
})
|
|
1943
1943
|
].filter((o) => !!o), n = [];
|
|
1944
1944
|
return r.forEach((o) => {
|
|
1945
|
-
if (
|
|
1945
|
+
if (V2(o))
|
|
1946
1946
|
n.push(...o.allOf);
|
|
1947
1947
|
else {
|
|
1948
1948
|
let s = o;
|
|
1949
1949
|
if ("additionalProperties" in o && o.additionalProperties === !1) {
|
|
1950
|
-
const { additionalProperties: a, ...
|
|
1951
|
-
s =
|
|
1950
|
+
const { additionalProperties: a, ...c } = o;
|
|
1951
|
+
s = c;
|
|
1952
1952
|
}
|
|
1953
1953
|
n.push(s);
|
|
1954
1954
|
}
|
|
1955
1955
|
}), n.length ? { allOf: n } : void 0;
|
|
1956
1956
|
}
|
|
1957
|
-
function
|
|
1957
|
+
function W2(t) {
|
|
1958
1958
|
const e = typeof t.value;
|
|
1959
1959
|
return e !== "bigint" && e !== "number" && e !== "boolean" && e !== "string" ? {
|
|
1960
1960
|
type: Array.isArray(t.value) ? "array" : "object"
|
|
@@ -1963,7 +1963,7 @@ function J2(t) {
|
|
|
1963
1963
|
const: t.value
|
|
1964
1964
|
};
|
|
1965
1965
|
}
|
|
1966
|
-
var
|
|
1966
|
+
var we = void 0, O = {
|
|
1967
1967
|
/**
|
|
1968
1968
|
* `c` was changed to `[cC]` to replicate /i flag
|
|
1969
1969
|
*/
|
|
@@ -1985,10 +1985,10 @@ var ge = void 0, O = {
|
|
|
1985
1985
|
* Fix in Zod:
|
|
1986
1986
|
* https://github.com/colinhacks/zod/commit/9340fd51e48576a75adc919bff65dbc4a5d4c99b
|
|
1987
1987
|
*/
|
|
1988
|
-
emoji: () => (
|
|
1988
|
+
emoji: () => (we === void 0 && (we = RegExp(
|
|
1989
1989
|
"^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$",
|
|
1990
1990
|
"u"
|
|
1991
|
-
)),
|
|
1991
|
+
)), we),
|
|
1992
1992
|
/**
|
|
1993
1993
|
* Unused
|
|
1994
1994
|
*/
|
|
@@ -2008,7 +2008,7 @@ var ge = void 0, O = {
|
|
|
2008
2008
|
nanoid: /^[a-zA-Z0-9_-]{21}$/,
|
|
2009
2009
|
jwt: /^[A-Za-z0-9-_]+\.[A-Za-z0-9-_]+\.[A-Za-z0-9-_]*$/
|
|
2010
2010
|
};
|
|
2011
|
-
function
|
|
2011
|
+
function gt(t, e) {
|
|
2012
2012
|
const r = {
|
|
2013
2013
|
type: "string"
|
|
2014
2014
|
};
|
|
@@ -2052,7 +2052,7 @@ function mt(t, e) {
|
|
|
2052
2052
|
case "startsWith":
|
|
2053
2053
|
k(
|
|
2054
2054
|
r,
|
|
2055
|
-
RegExp(`^${
|
|
2055
|
+
RegExp(`^${ve(n.value, e)}`),
|
|
2056
2056
|
n.message,
|
|
2057
2057
|
e
|
|
2058
2058
|
);
|
|
@@ -2060,7 +2060,7 @@ function mt(t, e) {
|
|
|
2060
2060
|
case "endsWith":
|
|
2061
2061
|
k(
|
|
2062
2062
|
r,
|
|
2063
|
-
RegExp(`${
|
|
2063
|
+
RegExp(`${ve(n.value, e)}$`),
|
|
2064
2064
|
n.message,
|
|
2065
2065
|
e
|
|
2066
2066
|
);
|
|
@@ -2083,7 +2083,7 @@ function mt(t, e) {
|
|
|
2083
2083
|
case "includes": {
|
|
2084
2084
|
k(
|
|
2085
2085
|
r,
|
|
2086
|
-
RegExp(
|
|
2086
|
+
RegExp(ve(n.value, e)),
|
|
2087
2087
|
n.message,
|
|
2088
2088
|
e
|
|
2089
2089
|
);
|
|
@@ -2132,16 +2132,16 @@ function mt(t, e) {
|
|
|
2132
2132
|
}
|
|
2133
2133
|
return r;
|
|
2134
2134
|
}
|
|
2135
|
-
function
|
|
2136
|
-
return e.patternStrategy === "escape" ?
|
|
2135
|
+
function ve(t, e) {
|
|
2136
|
+
return e.patternStrategy === "escape" ? K2(t) : t;
|
|
2137
2137
|
}
|
|
2138
|
-
var
|
|
2138
|
+
var G2 = new Set(
|
|
2139
2139
|
"ABCDEFGHIJKLMNOPQRSTUVXYZabcdefghijklmnopqrstuvxyz0123456789"
|
|
2140
2140
|
);
|
|
2141
|
-
function
|
|
2141
|
+
function K2(t) {
|
|
2142
2142
|
let e = "";
|
|
2143
2143
|
for (let r = 0; r < t.length; r++)
|
|
2144
|
-
|
|
2144
|
+
G2.has(t[r]) || (e += "\\"), e += t[r];
|
|
2145
2145
|
return e;
|
|
2146
2146
|
}
|
|
2147
2147
|
function $(t, e, r, n) {
|
|
@@ -2158,11 +2158,11 @@ function k(t, e, r, n) {
|
|
|
2158
2158
|
t.pattern || (o = t.allOf) != null && o.some((s) => s.pattern) ? (t.allOf || (t.allOf = []), t.pattern && (t.allOf.push({
|
|
2159
2159
|
pattern: t.pattern
|
|
2160
2160
|
}), delete t.pattern), t.allOf.push({
|
|
2161
|
-
pattern:
|
|
2161
|
+
pattern: Xe(e, n),
|
|
2162
2162
|
...r && n.errorMessages && { errorMessage: { pattern: r } }
|
|
2163
|
-
})) : t.pattern =
|
|
2163
|
+
})) : t.pattern = Xe(e, n);
|
|
2164
2164
|
}
|
|
2165
|
-
function
|
|
2165
|
+
function Xe(t, e) {
|
|
2166
2166
|
var r;
|
|
2167
2167
|
if (!e.applyRegexFlags || !t.flags)
|
|
2168
2168
|
return t.source;
|
|
@@ -2174,41 +2174,41 @@ function Ye(t, e) {
|
|
|
2174
2174
|
s: t.flags.includes("s")
|
|
2175
2175
|
// `.` matches newlines
|
|
2176
2176
|
}, o = n.i ? t.source.toLowerCase() : t.source;
|
|
2177
|
-
let s = "", a = !1,
|
|
2178
|
-
for (let
|
|
2177
|
+
let s = "", a = !1, c = !1, d = !1;
|
|
2178
|
+
for (let l = 0; l < o.length; l++) {
|
|
2179
2179
|
if (a) {
|
|
2180
|
-
s += o[
|
|
2180
|
+
s += o[l], a = !1;
|
|
2181
2181
|
continue;
|
|
2182
2182
|
}
|
|
2183
2183
|
if (n.i) {
|
|
2184
|
-
if (
|
|
2185
|
-
if (o[
|
|
2186
|
-
d ? (s += o[
|
|
2184
|
+
if (c) {
|
|
2185
|
+
if (o[l].match(/[a-z]/)) {
|
|
2186
|
+
d ? (s += o[l], s += `${o[l - 2]}-${o[l]}`.toUpperCase(), d = !1) : o[l + 1] === "-" && ((r = o[l + 2]) != null && r.match(/[a-z]/)) ? (s += o[l], d = !0) : s += `${o[l]}${o[l].toUpperCase()}`;
|
|
2187
2187
|
continue;
|
|
2188
2188
|
}
|
|
2189
|
-
} else if (o[
|
|
2190
|
-
s += `[${o[
|
|
2189
|
+
} else if (o[l].match(/[a-z]/)) {
|
|
2190
|
+
s += `[${o[l]}${o[l].toUpperCase()}]`;
|
|
2191
2191
|
continue;
|
|
2192
2192
|
}
|
|
2193
2193
|
}
|
|
2194
2194
|
if (n.m) {
|
|
2195
|
-
if (o[
|
|
2195
|
+
if (o[l] === "^") {
|
|
2196
2196
|
s += `(^|(?<=[\r
|
|
2197
2197
|
]))`;
|
|
2198
2198
|
continue;
|
|
2199
|
-
} else if (o[
|
|
2199
|
+
} else if (o[l] === "$") {
|
|
2200
2200
|
s += `($|(?=[\r
|
|
2201
2201
|
]))`;
|
|
2202
2202
|
continue;
|
|
2203
2203
|
}
|
|
2204
2204
|
}
|
|
2205
|
-
if (n.s && o[
|
|
2206
|
-
s +=
|
|
2207
|
-
` : `[${o[
|
|
2205
|
+
if (n.s && o[l] === ".") {
|
|
2206
|
+
s += c ? `${o[l]}\r
|
|
2207
|
+
` : `[${o[l]}\r
|
|
2208
2208
|
]`;
|
|
2209
2209
|
continue;
|
|
2210
2210
|
}
|
|
2211
|
-
s += o[
|
|
2211
|
+
s += o[l], o[l] === "\\" ? a = !0 : c && o[l] === "]" ? c = !1 : !c && o[l] === "[" && (c = !0);
|
|
2212
2212
|
}
|
|
2213
2213
|
try {
|
|
2214
2214
|
new RegExp(s);
|
|
@@ -2221,8 +2221,8 @@ function Ye(t, e) {
|
|
|
2221
2221
|
}
|
|
2222
2222
|
return s;
|
|
2223
2223
|
}
|
|
2224
|
-
function
|
|
2225
|
-
var r, n, o, s, a,
|
|
2224
|
+
function yt(t, e) {
|
|
2225
|
+
var r, n, o, s, a, c;
|
|
2226
2226
|
const d = {
|
|
2227
2227
|
type: "object",
|
|
2228
2228
|
additionalProperties: (r = _(t.valueType._def, {
|
|
@@ -2231,7 +2231,7 @@ function ft(t, e) {
|
|
|
2231
2231
|
})) != null ? r : e.allowedAdditionalProperties
|
|
2232
2232
|
};
|
|
2233
2233
|
if (((n = t.keyType) == null ? void 0 : n._def.typeName) === w.ZodString && ((o = t.keyType._def.checks) != null && o.length)) {
|
|
2234
|
-
const { type:
|
|
2234
|
+
const { type: l, ...u } = gt(t.keyType._def, e);
|
|
2235
2235
|
return {
|
|
2236
2236
|
...d,
|
|
2237
2237
|
propertyNames: u
|
|
@@ -2244,8 +2244,8 @@ function ft(t, e) {
|
|
|
2244
2244
|
enum: t.keyType._def.values
|
|
2245
2245
|
}
|
|
2246
2246
|
};
|
|
2247
|
-
if (((a = t.keyType) == null ? void 0 : a._def.typeName) === w.ZodBranded && t.keyType._def.type._def.typeName === w.ZodString && ((
|
|
2248
|
-
const { type:
|
|
2247
|
+
if (((a = t.keyType) == null ? void 0 : a._def.typeName) === w.ZodBranded && t.keyType._def.type._def.typeName === w.ZodString && ((c = t.keyType._def.type._def.checks) != null && c.length)) {
|
|
2248
|
+
const { type: l, ...u } = mt(
|
|
2249
2249
|
t.keyType._def,
|
|
2250
2250
|
e
|
|
2251
2251
|
);
|
|
@@ -2257,9 +2257,9 @@ function ft(t, e) {
|
|
|
2257
2257
|
}
|
|
2258
2258
|
return d;
|
|
2259
2259
|
}
|
|
2260
|
-
function
|
|
2260
|
+
function Y2(t, e) {
|
|
2261
2261
|
if (e.mapStrategy === "record")
|
|
2262
|
-
return
|
|
2262
|
+
return yt(t, e);
|
|
2263
2263
|
const r = _(t.keyType._def, {
|
|
2264
2264
|
...e,
|
|
2265
2265
|
currentPath: [...e.currentPath, "items", "items", "0"]
|
|
@@ -2278,7 +2278,7 @@ function K2(t, e) {
|
|
|
2278
2278
|
}
|
|
2279
2279
|
};
|
|
2280
2280
|
}
|
|
2281
|
-
function
|
|
2281
|
+
function Q2(t) {
|
|
2282
2282
|
const e = t.values, n = Object.keys(t.values).filter((s) => typeof e[e[s]] != "number").map((s) => e[s]), o = Array.from(
|
|
2283
2283
|
new Set(n.map((s) => typeof s))
|
|
2284
2284
|
);
|
|
@@ -2287,28 +2287,28 @@ function Y2(t) {
|
|
|
2287
2287
|
enum: n
|
|
2288
2288
|
};
|
|
2289
2289
|
}
|
|
2290
|
-
function
|
|
2290
|
+
function X2() {
|
|
2291
2291
|
return { not: T() };
|
|
2292
2292
|
}
|
|
2293
|
-
function
|
|
2293
|
+
function er() {
|
|
2294
2294
|
return {
|
|
2295
2295
|
type: "null"
|
|
2296
2296
|
};
|
|
2297
2297
|
}
|
|
2298
|
-
var
|
|
2298
|
+
var Se = {
|
|
2299
2299
|
ZodString: "string",
|
|
2300
2300
|
ZodNumber: "number",
|
|
2301
2301
|
ZodBigInt: "integer",
|
|
2302
2302
|
ZodBoolean: "boolean",
|
|
2303
2303
|
ZodNull: "null"
|
|
2304
2304
|
};
|
|
2305
|
-
function
|
|
2305
|
+
function tr(t, e) {
|
|
2306
2306
|
const r = t.options instanceof Map ? Array.from(t.options.values()) : t.options;
|
|
2307
2307
|
if (r.every(
|
|
2308
|
-
(n) => n._def.typeName in
|
|
2308
|
+
(n) => n._def.typeName in Se && (!n._def.checks || !n._def.checks.length)
|
|
2309
2309
|
)) {
|
|
2310
2310
|
const n = r.reduce((o, s) => {
|
|
2311
|
-
const a =
|
|
2311
|
+
const a = Se[s._def.typeName];
|
|
2312
2312
|
return a && !o.includes(a) ? [...o, a] : o;
|
|
2313
2313
|
}, []);
|
|
2314
2314
|
return {
|
|
@@ -2337,7 +2337,7 @@ function e0(t, e) {
|
|
|
2337
2337
|
[]
|
|
2338
2338
|
);
|
|
2339
2339
|
if (n.length === r.length) {
|
|
2340
|
-
const o = n.filter((s, a,
|
|
2340
|
+
const o = n.filter((s, a, c) => c.indexOf(s) === a);
|
|
2341
2341
|
return {
|
|
2342
2342
|
type: o.length > 1 ? o : o[0],
|
|
2343
2343
|
enum: r.reduce(
|
|
@@ -2357,9 +2357,9 @@ function e0(t, e) {
|
|
|
2357
2357
|
[]
|
|
2358
2358
|
)
|
|
2359
2359
|
};
|
|
2360
|
-
return
|
|
2360
|
+
return rr(t, e);
|
|
2361
2361
|
}
|
|
2362
|
-
var
|
|
2362
|
+
var rr = (t, e) => {
|
|
2363
2363
|
const r = (t.options instanceof Map ? Array.from(t.options.values()) : t.options).map(
|
|
2364
2364
|
(n, o) => _(n._def, {
|
|
2365
2365
|
...e,
|
|
@@ -2370,13 +2370,13 @@ var t0 = (t, e) => {
|
|
|
2370
2370
|
);
|
|
2371
2371
|
return r.length ? { anyOf: r } : void 0;
|
|
2372
2372
|
};
|
|
2373
|
-
function
|
|
2373
|
+
function nr(t, e) {
|
|
2374
2374
|
if (["ZodString", "ZodNumber", "ZodBigInt", "ZodBoolean", "ZodNull"].includes(
|
|
2375
2375
|
t.innerType._def.typeName
|
|
2376
2376
|
) && (!t.innerType._def.checks || !t.innerType._def.checks.length))
|
|
2377
2377
|
return {
|
|
2378
2378
|
type: [
|
|
2379
|
-
|
|
2379
|
+
Se[t.innerType._def.typeName],
|
|
2380
2380
|
"null"
|
|
2381
2381
|
]
|
|
2382
2382
|
};
|
|
@@ -2386,7 +2386,7 @@ function r0(t, e) {
|
|
|
2386
2386
|
});
|
|
2387
2387
|
return r && { anyOf: [r, { type: "null" }] };
|
|
2388
2388
|
}
|
|
2389
|
-
function
|
|
2389
|
+
function or(t) {
|
|
2390
2390
|
const e = {
|
|
2391
2391
|
type: "number"
|
|
2392
2392
|
};
|
|
@@ -2408,27 +2408,27 @@ function n0(t) {
|
|
|
2408
2408
|
}
|
|
2409
2409
|
return e;
|
|
2410
2410
|
}
|
|
2411
|
-
function
|
|
2411
|
+
function sr(t, e) {
|
|
2412
2412
|
const r = {
|
|
2413
2413
|
type: "object",
|
|
2414
2414
|
properties: {}
|
|
2415
2415
|
}, n = [], o = t.shape();
|
|
2416
2416
|
for (const a in o) {
|
|
2417
|
-
let
|
|
2418
|
-
if (
|
|
2417
|
+
let c = o[a];
|
|
2418
|
+
if (c === void 0 || c._def === void 0)
|
|
2419
2419
|
continue;
|
|
2420
|
-
const d =
|
|
2420
|
+
const d = ar(c), l = _(c._def, {
|
|
2421
2421
|
...e,
|
|
2422
2422
|
currentPath: [...e.currentPath, "properties", a],
|
|
2423
2423
|
propertyPath: [...e.currentPath, "properties", a]
|
|
2424
2424
|
});
|
|
2425
|
-
|
|
2425
|
+
l !== void 0 && (r.properties[a] = l, d || n.push(a));
|
|
2426
2426
|
}
|
|
2427
2427
|
n.length && (r.required = n);
|
|
2428
|
-
const s =
|
|
2428
|
+
const s = ir(t, e);
|
|
2429
2429
|
return s !== void 0 && (r.additionalProperties = s), r;
|
|
2430
2430
|
}
|
|
2431
|
-
function
|
|
2431
|
+
function ir(t, e) {
|
|
2432
2432
|
if (t.catchall._def.typeName !== "ZodNever")
|
|
2433
2433
|
return _(t.catchall._def, {
|
|
2434
2434
|
...e,
|
|
@@ -2443,14 +2443,14 @@ function s0(t, e) {
|
|
|
2443
2443
|
return e.removeAdditionalStrategy === "strict" ? e.allowedAdditionalProperties : e.rejectedAdditionalProperties;
|
|
2444
2444
|
}
|
|
2445
2445
|
}
|
|
2446
|
-
function
|
|
2446
|
+
function ar(t) {
|
|
2447
2447
|
try {
|
|
2448
2448
|
return t.isOptional();
|
|
2449
2449
|
} catch {
|
|
2450
2450
|
return !0;
|
|
2451
2451
|
}
|
|
2452
2452
|
}
|
|
2453
|
-
var
|
|
2453
|
+
var cr = (t, e) => {
|
|
2454
2454
|
var r;
|
|
2455
2455
|
if (e.currentPath.toString() === ((r = e.propertyPath) == null ? void 0 : r.toString()))
|
|
2456
2456
|
return _(t.innerType._def, e);
|
|
@@ -2459,7 +2459,7 @@ var a0 = (t, e) => {
|
|
|
2459
2459
|
currentPath: [...e.currentPath, "anyOf", "1"]
|
|
2460
2460
|
});
|
|
2461
2461
|
return n ? { anyOf: [{ not: T() }, n] } : T();
|
|
2462
|
-
},
|
|
2462
|
+
}, lr = (t, e) => {
|
|
2463
2463
|
if (e.pipeStrategy === "input")
|
|
2464
2464
|
return _(t.in._def, e);
|
|
2465
2465
|
if (e.pipeStrategy === "output")
|
|
@@ -2475,10 +2475,10 @@ var a0 = (t, e) => {
|
|
|
2475
2475
|
allOf: [r, n].filter((o) => o !== void 0)
|
|
2476
2476
|
};
|
|
2477
2477
|
};
|
|
2478
|
-
function
|
|
2478
|
+
function dr(t, e) {
|
|
2479
2479
|
return _(t.type._def, e);
|
|
2480
2480
|
}
|
|
2481
|
-
function
|
|
2481
|
+
function ur(t, e) {
|
|
2482
2482
|
const n = {
|
|
2483
2483
|
type: "array",
|
|
2484
2484
|
uniqueItems: !0,
|
|
@@ -2489,7 +2489,7 @@ function d0(t, e) {
|
|
|
2489
2489
|
};
|
|
2490
2490
|
return t.minSize && (n.minItems = t.minSize.value), t.maxSize && (n.maxItems = t.maxSize.value), n;
|
|
2491
2491
|
}
|
|
2492
|
-
function
|
|
2492
|
+
function pr(t, e) {
|
|
2493
2493
|
return t.rest ? {
|
|
2494
2494
|
type: "array",
|
|
2495
2495
|
minItems: t.items.length,
|
|
@@ -2521,80 +2521,80 @@ function u0(t, e) {
|
|
|
2521
2521
|
)
|
|
2522
2522
|
};
|
|
2523
2523
|
}
|
|
2524
|
-
function
|
|
2524
|
+
function hr() {
|
|
2525
2525
|
return {
|
|
2526
2526
|
not: T()
|
|
2527
2527
|
};
|
|
2528
2528
|
}
|
|
2529
|
-
function
|
|
2529
|
+
function mr() {
|
|
2530
2530
|
return T();
|
|
2531
2531
|
}
|
|
2532
|
-
var
|
|
2532
|
+
var fr = (t, e) => _(t.innerType._def, e), gr = (t, e, r) => {
|
|
2533
2533
|
switch (e) {
|
|
2534
2534
|
case w.ZodString:
|
|
2535
|
-
return
|
|
2535
|
+
return gt(t, r);
|
|
2536
2536
|
case w.ZodNumber:
|
|
2537
|
-
return
|
|
2537
|
+
return or(t);
|
|
2538
2538
|
case w.ZodObject:
|
|
2539
|
-
return
|
|
2539
|
+
return sr(t, r);
|
|
2540
2540
|
case w.ZodBigInt:
|
|
2541
|
-
return
|
|
2541
|
+
return Z2(t);
|
|
2542
2542
|
case w.ZodBoolean:
|
|
2543
|
-
return
|
|
2543
|
+
return z2();
|
|
2544
2544
|
case w.ZodDate:
|
|
2545
|
-
return
|
|
2545
|
+
return ft(t, r);
|
|
2546
2546
|
case w.ZodUndefined:
|
|
2547
|
-
return
|
|
2547
|
+
return hr();
|
|
2548
2548
|
case w.ZodNull:
|
|
2549
|
-
return
|
|
2549
|
+
return er();
|
|
2550
2550
|
case w.ZodArray:
|
|
2551
|
-
return
|
|
2551
|
+
return j2(t, r);
|
|
2552
2552
|
case w.ZodUnion:
|
|
2553
2553
|
case w.ZodDiscriminatedUnion:
|
|
2554
|
-
return
|
|
2554
|
+
return tr(t, r);
|
|
2555
2555
|
case w.ZodIntersection:
|
|
2556
|
-
return
|
|
2556
|
+
return J2(t, r);
|
|
2557
2557
|
case w.ZodTuple:
|
|
2558
|
-
return
|
|
2558
|
+
return pr(t, r);
|
|
2559
2559
|
case w.ZodRecord:
|
|
2560
|
-
return
|
|
2560
|
+
return yt(t, r);
|
|
2561
2561
|
case w.ZodLiteral:
|
|
2562
|
-
return
|
|
2562
|
+
return W2(t);
|
|
2563
2563
|
case w.ZodEnum:
|
|
2564
|
-
return
|
|
2564
|
+
return B2(t);
|
|
2565
2565
|
case w.ZodNativeEnum:
|
|
2566
|
-
return
|
|
2566
|
+
return Q2(t);
|
|
2567
2567
|
case w.ZodNullable:
|
|
2568
|
-
return
|
|
2568
|
+
return nr(t, r);
|
|
2569
2569
|
case w.ZodOptional:
|
|
2570
|
-
return
|
|
2570
|
+
return cr(t, r);
|
|
2571
2571
|
case w.ZodMap:
|
|
2572
|
-
return
|
|
2572
|
+
return Y2(t, r);
|
|
2573
2573
|
case w.ZodSet:
|
|
2574
|
-
return
|
|
2574
|
+
return ur(t, r);
|
|
2575
2575
|
case w.ZodLazy:
|
|
2576
2576
|
return () => t.getter()._def;
|
|
2577
2577
|
case w.ZodPromise:
|
|
2578
|
-
return
|
|
2578
|
+
return dr(t, r);
|
|
2579
2579
|
case w.ZodNaN:
|
|
2580
2580
|
case w.ZodNever:
|
|
2581
|
-
return
|
|
2581
|
+
return X2();
|
|
2582
2582
|
case w.ZodEffects:
|
|
2583
|
-
return
|
|
2583
|
+
return F2(t, r);
|
|
2584
2584
|
case w.ZodAny:
|
|
2585
2585
|
return T();
|
|
2586
2586
|
case w.ZodUnknown:
|
|
2587
|
-
return
|
|
2587
|
+
return mr();
|
|
2588
2588
|
case w.ZodDefault:
|
|
2589
|
-
return
|
|
2589
|
+
return H2(t, r);
|
|
2590
2590
|
case w.ZodBranded:
|
|
2591
|
-
return
|
|
2591
|
+
return mt(t, r);
|
|
2592
2592
|
case w.ZodReadonly:
|
|
2593
|
-
return
|
|
2593
|
+
return fr(t, r);
|
|
2594
2594
|
case w.ZodCatch:
|
|
2595
2595
|
return q2(t, r);
|
|
2596
2596
|
case w.ZodPipeline:
|
|
2597
|
-
return
|
|
2597
|
+
return lr(t, r);
|
|
2598
2598
|
case w.ZodFunction:
|
|
2599
2599
|
case w.ZodVoid:
|
|
2600
2600
|
case w.ZodSymbol:
|
|
@@ -2603,7 +2603,7 @@ var m0 = (t, e) => _(t.innerType._def, e), f0 = (t, e, r) => {
|
|
|
2603
2603
|
return /* @__PURE__ */ ((n) => {
|
|
2604
2604
|
})();
|
|
2605
2605
|
}
|
|
2606
|
-
},
|
|
2606
|
+
}, yr = (t, e) => {
|
|
2607
2607
|
let r = 0;
|
|
2608
2608
|
for (; r < t.length && r < e.length && t[r] === e[r]; r++)
|
|
2609
2609
|
;
|
|
@@ -2620,29 +2620,29 @@ function _(t, e, r = !1) {
|
|
|
2620
2620
|
o,
|
|
2621
2621
|
r
|
|
2622
2622
|
);
|
|
2623
|
-
if (d !==
|
|
2623
|
+
if (d !== U2)
|
|
2624
2624
|
return d;
|
|
2625
2625
|
}
|
|
2626
2626
|
if (o && !r) {
|
|
2627
|
-
const d =
|
|
2627
|
+
const d = wr(o, e);
|
|
2628
2628
|
if (d !== void 0)
|
|
2629
2629
|
return d;
|
|
2630
2630
|
}
|
|
2631
2631
|
const s = { def: t, path: e.currentPath, jsonSchema: void 0 };
|
|
2632
2632
|
e.seen.set(t, s);
|
|
2633
|
-
const a =
|
|
2634
|
-
if (
|
|
2635
|
-
const d = e.postProcess(
|
|
2636
|
-
return s.jsonSchema =
|
|
2633
|
+
const a = gr(t, t.typeName, e), c = typeof a == "function" ? _(a(), e) : a;
|
|
2634
|
+
if (c && vr(t, e, c), e.postProcess) {
|
|
2635
|
+
const d = e.postProcess(c, t, e);
|
|
2636
|
+
return s.jsonSchema = c, d;
|
|
2637
2637
|
}
|
|
2638
|
-
return s.jsonSchema =
|
|
2638
|
+
return s.jsonSchema = c, c;
|
|
2639
2639
|
}
|
|
2640
|
-
var
|
|
2640
|
+
var wr = (t, e) => {
|
|
2641
2641
|
switch (e.$refStrategy) {
|
|
2642
2642
|
case "root":
|
|
2643
2643
|
return { $ref: t.path.join("/") };
|
|
2644
2644
|
case "relative":
|
|
2645
|
-
return { $ref:
|
|
2645
|
+
return { $ref: yr(e.currentPath, t.path) };
|
|
2646
2646
|
case "none":
|
|
2647
2647
|
case "seen":
|
|
2648
2648
|
return t.path.length < e.currentPath.length && t.path.every((r, n) => e.currentPath[n] === r) ? (console.warn(
|
|
@@ -2651,8 +2651,8 @@ var y0 = (t, e) => {
|
|
|
2651
2651
|
)}! Defaulting to any`
|
|
2652
2652
|
), T()) : e.$refStrategy === "seen" ? T() : void 0;
|
|
2653
2653
|
}
|
|
2654
|
-
},
|
|
2655
|
-
const e =
|
|
2654
|
+
}, vr = (t, e, r) => (t.description && (r.description = t.description), r), Cr = (t) => {
|
|
2655
|
+
const e = N2(t), r = e.name !== void 0 ? [...e.basePath, e.definitionPath, e.name] : e.basePath;
|
|
2656
2656
|
return {
|
|
2657
2657
|
...e,
|
|
2658
2658
|
currentPath: r,
|
|
@@ -2669,14 +2669,14 @@ var y0 = (t, e) => {
|
|
|
2669
2669
|
])
|
|
2670
2670
|
)
|
|
2671
2671
|
};
|
|
2672
|
-
},
|
|
2672
|
+
}, _r = (t, e) => {
|
|
2673
2673
|
var r;
|
|
2674
|
-
const n =
|
|
2674
|
+
const n = Cr(e);
|
|
2675
2675
|
let o = typeof e == "object" && e.definitions ? Object.entries(e.definitions).reduce(
|
|
2676
|
-
(
|
|
2676
|
+
(l, [u, g]) => {
|
|
2677
2677
|
var p;
|
|
2678
2678
|
return {
|
|
2679
|
-
...
|
|
2679
|
+
...l,
|
|
2680
2680
|
[u]: (p = _(
|
|
2681
2681
|
g._def,
|
|
2682
2682
|
{
|
|
@@ -2696,8 +2696,8 @@ var y0 = (t, e) => {
|
|
|
2696
2696
|
currentPath: [...n.basePath, n.definitionPath, s]
|
|
2697
2697
|
},
|
|
2698
2698
|
!1
|
|
2699
|
-
)) != null ? r : T(),
|
|
2700
|
-
|
|
2699
|
+
)) != null ? r : T(), c = typeof e == "object" && e.name !== void 0 && e.nameStrategy === "title" ? e.name : void 0;
|
|
2700
|
+
c !== void 0 && (a.title = c);
|
|
2701
2701
|
const d = s === void 0 ? o ? {
|
|
2702
2702
|
...a,
|
|
2703
2703
|
[n.definitionPath]: o
|
|
@@ -2713,12 +2713,12 @@ var y0 = (t, e) => {
|
|
|
2713
2713
|
}
|
|
2714
2714
|
};
|
|
2715
2715
|
return d.$schema = "http://json-schema.org/draft-07/schema#", d;
|
|
2716
|
-
},
|
|
2717
|
-
function
|
|
2716
|
+
}, Pe = Symbol.for("vercel.ai.schema");
|
|
2717
|
+
function Q(t, {
|
|
2718
2718
|
validate: e
|
|
2719
2719
|
} = {}) {
|
|
2720
2720
|
return {
|
|
2721
|
-
[
|
|
2721
|
+
[Pe]: !0,
|
|
2722
2722
|
_type: void 0,
|
|
2723
2723
|
// should never be used directly
|
|
2724
2724
|
get jsonSchema() {
|
|
@@ -2727,15 +2727,15 @@ function K(t, {
|
|
|
2727
2727
|
validate: e
|
|
2728
2728
|
};
|
|
2729
2729
|
}
|
|
2730
|
-
function
|
|
2731
|
-
return typeof t == "object" && t !== null &&
|
|
2730
|
+
function br(t) {
|
|
2731
|
+
return typeof t == "object" && t !== null && Pe in t && t[Pe] === !0 && "jsonSchema" in t && "validate" in t;
|
|
2732
2732
|
}
|
|
2733
|
-
function
|
|
2734
|
-
return t == null ?
|
|
2733
|
+
function wt(t) {
|
|
2734
|
+
return t == null ? Q({ properties: {}, additionalProperties: !1 }) : br(t) ? t : "~standard" in t ? t["~standard"].vendor === "zod" ? Pr(t) : xr(t) : t();
|
|
2735
2735
|
}
|
|
2736
|
-
function
|
|
2737
|
-
return
|
|
2738
|
-
() =>
|
|
2736
|
+
function xr(t) {
|
|
2737
|
+
return Q(
|
|
2738
|
+
() => Oe(
|
|
2739
2739
|
t["~standard"].jsonSchema.input({
|
|
2740
2740
|
target: "draft-07"
|
|
2741
2741
|
})
|
|
@@ -2745,7 +2745,7 @@ function b0(t) {
|
|
|
2745
2745
|
const r = await t["~standard"].validate(e);
|
|
2746
2746
|
return "value" in r ? { success: !0, value: r.value } : {
|
|
2747
2747
|
success: !1,
|
|
2748
|
-
error: new
|
|
2748
|
+
error: new be({
|
|
2749
2749
|
value: e,
|
|
2750
2750
|
cause: r.issues
|
|
2751
2751
|
})
|
|
@@ -2754,12 +2754,12 @@ function b0(t) {
|
|
|
2754
2754
|
}
|
|
2755
2755
|
);
|
|
2756
2756
|
}
|
|
2757
|
-
function
|
|
2757
|
+
function Lr(t, e) {
|
|
2758
2758
|
var r;
|
|
2759
2759
|
const n = (r = void 0) != null ? r : !1;
|
|
2760
|
-
return
|
|
2760
|
+
return Q(
|
|
2761
2761
|
// defer json schema creation to avoid unnecessary computation when only validation is needed
|
|
2762
|
-
() =>
|
|
2762
|
+
() => _r(t, {
|
|
2763
2763
|
$refStrategy: n ? "root" : "none"
|
|
2764
2764
|
}),
|
|
2765
2765
|
{
|
|
@@ -2770,13 +2770,13 @@ function x0(t, e) {
|
|
|
2770
2770
|
}
|
|
2771
2771
|
);
|
|
2772
2772
|
}
|
|
2773
|
-
function
|
|
2773
|
+
function kr(t, e) {
|
|
2774
2774
|
var r;
|
|
2775
2775
|
const n = (r = void 0) != null ? r : !1;
|
|
2776
|
-
return
|
|
2776
|
+
return Q(
|
|
2777
2777
|
// defer json schema creation to avoid unnecessary computation when only validation is needed
|
|
2778
|
-
() =>
|
|
2779
|
-
|
|
2778
|
+
() => Oe(
|
|
2779
|
+
Ve.toJSONSchema(t, {
|
|
2780
2780
|
target: "draft-7",
|
|
2781
2781
|
io: "input",
|
|
2782
2782
|
reused: n ? "ref" : "inline"
|
|
@@ -2784,91 +2784,91 @@ function L0(t, e) {
|
|
|
2784
2784
|
),
|
|
2785
2785
|
{
|
|
2786
2786
|
validate: async (o) => {
|
|
2787
|
-
const s = await
|
|
2787
|
+
const s = await Ve.safeParseAsync(t, o);
|
|
2788
2788
|
return s.success ? { success: !0, value: s.data } : { success: !1, error: s.error };
|
|
2789
2789
|
}
|
|
2790
2790
|
}
|
|
2791
2791
|
);
|
|
2792
2792
|
}
|
|
2793
|
-
function
|
|
2793
|
+
function Sr(t) {
|
|
2794
2794
|
return "_zod" in t;
|
|
2795
2795
|
}
|
|
2796
|
-
function
|
|
2797
|
-
return
|
|
2796
|
+
function Pr(t, e) {
|
|
2797
|
+
return Sr(t) ? kr(t) : Lr(t);
|
|
2798
2798
|
}
|
|
2799
|
-
async function
|
|
2799
|
+
async function vt({
|
|
2800
2800
|
value: t,
|
|
2801
2801
|
schema: e,
|
|
2802
2802
|
context: r
|
|
2803
2803
|
}) {
|
|
2804
|
-
const n =
|
|
2804
|
+
const n = wt(e);
|
|
2805
2805
|
try {
|
|
2806
2806
|
if (n.validate == null)
|
|
2807
2807
|
return { success: !0, value: t, rawValue: t };
|
|
2808
2808
|
const o = await n.validate(t);
|
|
2809
2809
|
return o.success ? { success: !0, value: o.value, rawValue: t } : {
|
|
2810
2810
|
success: !1,
|
|
2811
|
-
error:
|
|
2811
|
+
error: be.wrap({ value: t, cause: o.error, context: r }),
|
|
2812
2812
|
rawValue: t
|
|
2813
2813
|
};
|
|
2814
2814
|
} catch (o) {
|
|
2815
2815
|
return {
|
|
2816
2816
|
success: !1,
|
|
2817
|
-
error:
|
|
2817
|
+
error: be.wrap({ value: t, cause: o, context: r }),
|
|
2818
2818
|
rawValue: t
|
|
2819
2819
|
};
|
|
2820
2820
|
}
|
|
2821
2821
|
}
|
|
2822
|
-
async function
|
|
2822
|
+
async function Tr({
|
|
2823
2823
|
text: t,
|
|
2824
2824
|
schema: e
|
|
2825
2825
|
}) {
|
|
2826
2826
|
try {
|
|
2827
|
-
const r =
|
|
2828
|
-
return e == null ? { success: !0, value: r, rawValue: r } : await
|
|
2827
|
+
const r = $2(t);
|
|
2828
|
+
return e == null ? { success: !0, value: r, rawValue: r } : await vt({ value: r, schema: e });
|
|
2829
2829
|
} catch (r) {
|
|
2830
2830
|
return {
|
|
2831
2831
|
success: !1,
|
|
2832
|
-
error:
|
|
2832
|
+
error: Be.isInstance(r) ? r : new Be({ text: t, cause: r }),
|
|
2833
2833
|
rawValue: void 0
|
|
2834
2834
|
};
|
|
2835
2835
|
}
|
|
2836
2836
|
}
|
|
2837
|
-
function
|
|
2837
|
+
function Mr(t) {
|
|
2838
2838
|
return { ...t, type: "dynamic" };
|
|
2839
2839
|
}
|
|
2840
|
-
let
|
|
2841
|
-
|
|
2842
|
-
async function
|
|
2843
|
-
return (await
|
|
2840
|
+
let $e;
|
|
2841
|
+
$e = globalThis.crypto;
|
|
2842
|
+
async function Er(t) {
|
|
2843
|
+
return (await $e).getRandomValues(new Uint8Array(t));
|
|
2844
2844
|
}
|
|
2845
|
-
async function
|
|
2845
|
+
async function Rr(t) {
|
|
2846
2846
|
const e = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789-._~", r = Math.pow(2, 8) - Math.pow(2, 8) % e.length;
|
|
2847
2847
|
let n = "";
|
|
2848
2848
|
for (; n.length < t; ) {
|
|
2849
|
-
const o = await
|
|
2849
|
+
const o = await Er(t - n.length);
|
|
2850
2850
|
for (const s of o)
|
|
2851
2851
|
s < r && (n += e[s % e.length]);
|
|
2852
2852
|
}
|
|
2853
2853
|
return n;
|
|
2854
2854
|
}
|
|
2855
|
-
async function
|
|
2856
|
-
return await
|
|
2855
|
+
async function Ir(t) {
|
|
2856
|
+
return await Rr(t);
|
|
2857
2857
|
}
|
|
2858
|
-
async function
|
|
2859
|
-
const e = await (await
|
|
2858
|
+
async function Ar(t) {
|
|
2859
|
+
const e = await (await $e).subtle.digest("SHA-256", new TextEncoder().encode(t));
|
|
2860
2860
|
return btoa(String.fromCharCode(...new Uint8Array(e))).replace(/\//g, "_").replace(/\+/g, "-").replace(/=/g, "");
|
|
2861
2861
|
}
|
|
2862
|
-
async function
|
|
2862
|
+
async function Or(t) {
|
|
2863
2863
|
if (t || (t = 43), t < 43 || t > 128)
|
|
2864
2864
|
throw `Expected a length between 43 and 128. Received ${t}.`;
|
|
2865
|
-
const e = await
|
|
2865
|
+
const e = await Ir(t), r = await Ar(e);
|
|
2866
2866
|
return {
|
|
2867
2867
|
code_verifier: e,
|
|
2868
2868
|
code_challenge: r
|
|
2869
2869
|
};
|
|
2870
2870
|
}
|
|
2871
|
-
var
|
|
2871
|
+
var $r = "AI_MCPClientError", Ct = `vercel.ai.error.${$r}`, Ur = Symbol.for(Ct), et, tt, C = class extends (tt = oe, et = Ur, tt) {
|
|
2872
2872
|
constructor({
|
|
2873
2873
|
name: t = "MCPClientError",
|
|
2874
2874
|
message: e,
|
|
@@ -2876,26 +2876,26 @@ var O0 = "AI_MCPClientError", wt = `vercel.ai.error.${O0}`, $0 = Symbol.for(wt),
|
|
|
2876
2876
|
data: n,
|
|
2877
2877
|
code: o
|
|
2878
2878
|
}) {
|
|
2879
|
-
super({ name: t, message: e, cause: r }), this[
|
|
2879
|
+
super({ name: t, message: e, cause: r }), this[et] = !0, this.data = n, this.code = o;
|
|
2880
2880
|
}
|
|
2881
2881
|
static isInstance(t) {
|
|
2882
|
-
return
|
|
2882
|
+
return oe.hasMarker(t, Ct);
|
|
2883
2883
|
}
|
|
2884
|
-
}, B = "2025-06-18",
|
|
2884
|
+
}, B = "2025-06-18", Nr = [
|
|
2885
2885
|
B,
|
|
2886
2886
|
"2025-03-26",
|
|
2887
2887
|
"2024-11-05"
|
|
2888
|
-
],
|
|
2888
|
+
], jr = i.optional(i.record(i.string(), i.unknown())), Zr = i.looseObject({
|
|
2889
2889
|
name: i.string(),
|
|
2890
2890
|
version: i.string()
|
|
2891
|
-
}),
|
|
2891
|
+
}), me = i.looseObject({
|
|
2892
2892
|
_meta: i.optional(i.object({}).loose())
|
|
2893
|
-
}), N =
|
|
2893
|
+
}), N = me, _t = i.object({
|
|
2894
2894
|
method: i.string(),
|
|
2895
|
-
params: i.optional(
|
|
2896
|
-
}),
|
|
2895
|
+
params: i.optional(me)
|
|
2896
|
+
}), bt = i.object({
|
|
2897
2897
|
applyDefaults: i.optional(i.boolean())
|
|
2898
|
-
}).loose(),
|
|
2898
|
+
}).loose(), zr = i.looseObject({
|
|
2899
2899
|
experimental: i.optional(i.object({}).loose()),
|
|
2900
2900
|
logging: i.optional(i.object({}).loose()),
|
|
2901
2901
|
prompts: i.optional(
|
|
@@ -2914,19 +2914,19 @@ var O0 = "AI_MCPClientError", wt = `vercel.ai.error.${O0}`, $0 = Symbol.for(wt),
|
|
|
2914
2914
|
listChanged: i.optional(i.boolean())
|
|
2915
2915
|
})
|
|
2916
2916
|
),
|
|
2917
|
-
elicitation: i.optional(
|
|
2917
|
+
elicitation: i.optional(bt)
|
|
2918
2918
|
});
|
|
2919
2919
|
i.object({
|
|
2920
|
-
elicitation: i.optional(
|
|
2920
|
+
elicitation: i.optional(bt)
|
|
2921
2921
|
}).loose();
|
|
2922
|
-
var
|
|
2922
|
+
var qr = N.extend({
|
|
2923
2923
|
protocolVersion: i.string(),
|
|
2924
|
-
capabilities:
|
|
2925
|
-
serverInfo:
|
|
2924
|
+
capabilities: zr,
|
|
2925
|
+
serverInfo: Zr,
|
|
2926
2926
|
instructions: i.optional(i.string())
|
|
2927
|
-
}),
|
|
2927
|
+
}), Ue = N.extend({
|
|
2928
2928
|
nextCursor: i.optional(i.string())
|
|
2929
|
-
}),
|
|
2929
|
+
}), Dr = i.object({
|
|
2930
2930
|
name: i.string(),
|
|
2931
2931
|
/**
|
|
2932
2932
|
* @see https://modelcontextprotocol.io/specification/2025-11-25/server/tools#tool
|
|
@@ -2946,26 +2946,26 @@ var q0 = N.extend({
|
|
|
2946
2946
|
title: i.optional(i.string())
|
|
2947
2947
|
}).loose()
|
|
2948
2948
|
),
|
|
2949
|
-
_meta:
|
|
2950
|
-
}).loose(),
|
|
2951
|
-
tools: i.array(
|
|
2952
|
-
}),
|
|
2949
|
+
_meta: jr
|
|
2950
|
+
}).loose(), Hr = Ue.extend({
|
|
2951
|
+
tools: i.array(Dr)
|
|
2952
|
+
}), xt = i.object({
|
|
2953
2953
|
type: i.literal("text"),
|
|
2954
2954
|
text: i.string()
|
|
2955
|
-
}).loose(),
|
|
2955
|
+
}).loose(), Lt = i.object({
|
|
2956
2956
|
type: i.literal("image"),
|
|
2957
2957
|
data: i.base64(),
|
|
2958
2958
|
mimeType: i.string()
|
|
2959
|
-
}).loose(),
|
|
2959
|
+
}).loose(), Fr = i.object({
|
|
2960
2960
|
uri: i.string(),
|
|
2961
2961
|
name: i.string(),
|
|
2962
2962
|
title: i.optional(i.string()),
|
|
2963
2963
|
description: i.optional(i.string()),
|
|
2964
2964
|
mimeType: i.optional(i.string()),
|
|
2965
2965
|
size: i.optional(i.number())
|
|
2966
|
-
}).loose(),
|
|
2967
|
-
resources: i.array(
|
|
2968
|
-
}),
|
|
2966
|
+
}).loose(), Br = Ue.extend({
|
|
2967
|
+
resources: i.array(Fr)
|
|
2968
|
+
}), kt = i.object({
|
|
2969
2969
|
/**
|
|
2970
2970
|
* The URI of this resource.
|
|
2971
2971
|
*/
|
|
@@ -2982,16 +2982,16 @@ var q0 = N.extend({
|
|
|
2982
2982
|
* The MIME type of this resource, if known.
|
|
2983
2983
|
*/
|
|
2984
2984
|
mimeType: i.optional(i.string())
|
|
2985
|
-
}).loose(),
|
|
2985
|
+
}).loose(), St = kt.extend({
|
|
2986
2986
|
text: i.string()
|
|
2987
|
-
}),
|
|
2987
|
+
}), Pt = kt.extend({
|
|
2988
2988
|
blob: i.base64()
|
|
2989
|
-
}),
|
|
2989
|
+
}), Tt = i.object({
|
|
2990
2990
|
type: i.literal("resource"),
|
|
2991
|
-
resource: i.union([
|
|
2992
|
-
}).loose(),
|
|
2991
|
+
resource: i.union([St, Pt])
|
|
2992
|
+
}).loose(), Vr = N.extend({
|
|
2993
2993
|
content: i.array(
|
|
2994
|
-
i.union([
|
|
2994
|
+
i.union([xt, Lt, Tt])
|
|
2995
2995
|
),
|
|
2996
2996
|
/**
|
|
2997
2997
|
* @see https://modelcontextprotocol.io/specification/2025-06-18/server/tools#structured-content
|
|
@@ -3002,80 +3002,80 @@ var q0 = N.extend({
|
|
|
3002
3002
|
N.extend({
|
|
3003
3003
|
toolResult: i.unknown()
|
|
3004
3004
|
})
|
|
3005
|
-
),
|
|
3005
|
+
), Jr = i.object({
|
|
3006
3006
|
uriTemplate: i.string(),
|
|
3007
3007
|
name: i.string(),
|
|
3008
3008
|
title: i.optional(i.string()),
|
|
3009
3009
|
description: i.optional(i.string()),
|
|
3010
3010
|
mimeType: i.optional(i.string())
|
|
3011
|
-
}).loose(),
|
|
3012
|
-
resourceTemplates: i.array(
|
|
3013
|
-
}),
|
|
3011
|
+
}).loose(), Wr = N.extend({
|
|
3012
|
+
resourceTemplates: i.array(Jr)
|
|
3013
|
+
}), Gr = N.extend({
|
|
3014
3014
|
contents: i.array(
|
|
3015
|
-
i.union([
|
|
3015
|
+
i.union([St, Pt])
|
|
3016
3016
|
)
|
|
3017
|
-
}),
|
|
3017
|
+
}), Kr = i.object({
|
|
3018
3018
|
name: i.string(),
|
|
3019
3019
|
description: i.optional(i.string()),
|
|
3020
3020
|
required: i.optional(i.boolean())
|
|
3021
|
-
}).loose(),
|
|
3021
|
+
}).loose(), Yr = i.object({
|
|
3022
3022
|
name: i.string(),
|
|
3023
3023
|
title: i.optional(i.string()),
|
|
3024
3024
|
description: i.optional(i.string()),
|
|
3025
|
-
arguments: i.optional(i.array(
|
|
3026
|
-
}).loose(),
|
|
3027
|
-
prompts: i.array(
|
|
3028
|
-
}),
|
|
3025
|
+
arguments: i.optional(i.array(Kr))
|
|
3026
|
+
}).loose(), Qr = Ue.extend({
|
|
3027
|
+
prompts: i.array(Yr)
|
|
3028
|
+
}), Xr = i.object({
|
|
3029
3029
|
role: i.union([i.literal("user"), i.literal("assistant")]),
|
|
3030
3030
|
content: i.union([
|
|
3031
|
-
|
|
3032
|
-
|
|
3033
|
-
|
|
3031
|
+
xt,
|
|
3032
|
+
Lt,
|
|
3033
|
+
Tt
|
|
3034
3034
|
])
|
|
3035
|
-
}).loose(),
|
|
3035
|
+
}).loose(), e0 = N.extend({
|
|
3036
3036
|
description: i.optional(i.string()),
|
|
3037
|
-
messages: i.array(
|
|
3038
|
-
}),
|
|
3037
|
+
messages: i.array(Xr)
|
|
3038
|
+
}), t0 = me.extend({
|
|
3039
3039
|
message: i.string(),
|
|
3040
3040
|
requestedSchema: i.unknown()
|
|
3041
|
-
}),
|
|
3041
|
+
}), rt = _t.extend({
|
|
3042
3042
|
method: i.literal("elicitation/create"),
|
|
3043
|
-
params:
|
|
3044
|
-
}),
|
|
3043
|
+
params: t0
|
|
3044
|
+
}), r0 = N.extend({
|
|
3045
3045
|
action: i.union([
|
|
3046
3046
|
i.literal("accept"),
|
|
3047
3047
|
i.literal("decline"),
|
|
3048
3048
|
i.literal("cancel")
|
|
3049
3049
|
]),
|
|
3050
3050
|
content: i.optional(i.record(i.string(), i.unknown()))
|
|
3051
|
-
}),
|
|
3052
|
-
jsonrpc: i.literal(
|
|
3051
|
+
}), fe = "2.0", n0 = i.object({
|
|
3052
|
+
jsonrpc: i.literal(fe),
|
|
3053
3053
|
id: i.union([i.string(), i.number().int()])
|
|
3054
|
-
}).merge(
|
|
3055
|
-
jsonrpc: i.literal(
|
|
3054
|
+
}).merge(_t).strict(), o0 = i.object({
|
|
3055
|
+
jsonrpc: i.literal(fe),
|
|
3056
3056
|
id: i.union([i.string(), i.number().int()]),
|
|
3057
3057
|
result: N
|
|
3058
|
-
}).strict(),
|
|
3059
|
-
jsonrpc: i.literal(
|
|
3058
|
+
}).strict(), s0 = i.object({
|
|
3059
|
+
jsonrpc: i.literal(fe),
|
|
3060
3060
|
id: i.union([i.string(), i.number().int()]),
|
|
3061
3061
|
error: i.object({
|
|
3062
3062
|
code: i.number().int(),
|
|
3063
3063
|
message: i.string(),
|
|
3064
3064
|
data: i.optional(i.unknown())
|
|
3065
3065
|
})
|
|
3066
|
-
}).strict(),
|
|
3067
|
-
jsonrpc: i.literal(
|
|
3066
|
+
}).strict(), i0 = i.object({
|
|
3067
|
+
jsonrpc: i.literal(fe)
|
|
3068
3068
|
}).merge(
|
|
3069
3069
|
i.object({
|
|
3070
3070
|
method: i.string(),
|
|
3071
|
-
params: i.optional(
|
|
3071
|
+
params: i.optional(me)
|
|
3072
3072
|
})
|
|
3073
|
-
).strict(),
|
|
3074
|
-
|
|
3075
|
-
|
|
3076
|
-
|
|
3077
|
-
|
|
3078
|
-
]),
|
|
3073
|
+
).strict(), K = i.union([
|
|
3074
|
+
n0,
|
|
3075
|
+
i0,
|
|
3076
|
+
o0,
|
|
3077
|
+
s0
|
|
3078
|
+
]), Mt = typeof __PACKAGE_VERSION__ < "u" ? __PACKAGE_VERSION__ : "0.0.0-test", Et = i.object({
|
|
3079
3079
|
access_token: i.string(),
|
|
3080
3080
|
id_token: i.string().optional(),
|
|
3081
3081
|
// Optional for OAuth 2.1, but necessary in OpenID Connect
|
|
@@ -3096,7 +3096,7 @@ var q0 = N.extend({
|
|
|
3096
3096
|
return e.protocol !== "javascript:" && e.protocol !== "data:" && e.protocol !== "vbscript:";
|
|
3097
3097
|
},
|
|
3098
3098
|
{ message: "URL cannot use javascript:, data:, or vbscript: scheme" }
|
|
3099
|
-
),
|
|
3099
|
+
), a0 = i.object({
|
|
3100
3100
|
resource: i.string().url(),
|
|
3101
3101
|
authorization_servers: i.array(S).optional(),
|
|
3102
3102
|
jwks_uri: i.string().url().optional(),
|
|
@@ -3111,7 +3111,7 @@ var q0 = N.extend({
|
|
|
3111
3111
|
authorization_details_types_supported: i.array(i.string()).optional(),
|
|
3112
3112
|
dpop_signing_alg_values_supported: i.array(i.string()).optional(),
|
|
3113
3113
|
dpop_bound_access_tokens_required: i.boolean().optional()
|
|
3114
|
-
}).passthrough(),
|
|
3114
|
+
}).passthrough(), Rt = i.object({
|
|
3115
3115
|
issuer: i.string(),
|
|
3116
3116
|
authorization_endpoint: S,
|
|
3117
3117
|
token_endpoint: S,
|
|
@@ -3122,7 +3122,7 @@ var q0 = N.extend({
|
|
|
3122
3122
|
code_challenge_methods_supported: i.array(i.string()),
|
|
3123
3123
|
token_endpoint_auth_methods_supported: i.array(i.string()).optional(),
|
|
3124
3124
|
token_endpoint_auth_signing_alg_values_supported: i.array(i.string()).optional()
|
|
3125
|
-
}).passthrough(),
|
|
3125
|
+
}).passthrough(), c0 = i.object({
|
|
3126
3126
|
issuer: i.string(),
|
|
3127
3127
|
authorization_endpoint: S,
|
|
3128
3128
|
token_endpoint: S,
|
|
@@ -3136,16 +3136,16 @@ var q0 = N.extend({
|
|
|
3136
3136
|
id_token_signing_alg_values_supported: i.array(i.string()),
|
|
3137
3137
|
claims_supported: i.array(i.string()).optional(),
|
|
3138
3138
|
token_endpoint_auth_methods_supported: i.array(i.string()).optional()
|
|
3139
|
-
}).passthrough(),
|
|
3140
|
-
|
|
3139
|
+
}).passthrough(), l0 = c0.merge(
|
|
3140
|
+
Rt.pick({
|
|
3141
3141
|
code_challenge_methods_supported: !0
|
|
3142
3142
|
})
|
|
3143
|
-
),
|
|
3143
|
+
), d0 = i.object({
|
|
3144
3144
|
client_id: i.string(),
|
|
3145
3145
|
client_secret: i.string().optional(),
|
|
3146
3146
|
client_id_issued_at: i.number().optional(),
|
|
3147
3147
|
client_secret_expires_at: i.number().optional()
|
|
3148
|
-
}).strip(),
|
|
3148
|
+
}).strip(), u0 = i.object({
|
|
3149
3149
|
redirect_uris: i.array(S),
|
|
3150
3150
|
token_endpoint_auth_method: i.string().optional(),
|
|
3151
3151
|
grant_types: i.array(i.string()).optional(),
|
|
@@ -3162,46 +3162,46 @@ var q0 = N.extend({
|
|
|
3162
3162
|
software_id: i.string().optional(),
|
|
3163
3163
|
software_version: i.string().optional(),
|
|
3164
3164
|
software_statement: i.string().optional()
|
|
3165
|
-
}).strip(),
|
|
3165
|
+
}).strip(), p0 = i.object({
|
|
3166
3166
|
error: i.string(),
|
|
3167
3167
|
error_description: i.string().optional(),
|
|
3168
3168
|
error_uri: i.string().optional()
|
|
3169
|
-
}),
|
|
3170
|
-
|
|
3171
|
-
),
|
|
3169
|
+
}), h0 = u0.merge(
|
|
3170
|
+
d0
|
|
3171
|
+
), m0 = "AI_MCPClientOAuthError", It = `vercel.ai.error.${m0}`, f0 = Symbol.for(It), nt, ot, X = class extends (ot = oe, nt = f0, ot) {
|
|
3172
3172
|
constructor({
|
|
3173
3173
|
name: t = "MCPClientOAuthError",
|
|
3174
3174
|
message: e,
|
|
3175
3175
|
cause: r
|
|
3176
3176
|
}) {
|
|
3177
|
-
super({ name: t, message: e, cause: r }), this[
|
|
3177
|
+
super({ name: t, message: e, cause: r }), this[nt] = !0;
|
|
3178
3178
|
}
|
|
3179
3179
|
static isInstance(t) {
|
|
3180
|
-
return
|
|
3180
|
+
return oe.hasMarker(t, It);
|
|
3181
3181
|
}
|
|
3182
|
-
}, H = class extends
|
|
3182
|
+
}, H = class extends X {
|
|
3183
3183
|
};
|
|
3184
3184
|
H.errorCode = "server_error";
|
|
3185
|
-
var
|
|
3185
|
+
var se = class extends X {
|
|
3186
3186
|
};
|
|
3187
|
-
|
|
3188
|
-
var
|
|
3187
|
+
se.errorCode = "invalid_client";
|
|
3188
|
+
var ie = class extends X {
|
|
3189
3189
|
};
|
|
3190
|
-
|
|
3191
|
-
var
|
|
3190
|
+
ie.errorCode = "invalid_grant";
|
|
3191
|
+
var ae = class extends X {
|
|
3192
3192
|
};
|
|
3193
|
-
|
|
3194
|
-
var
|
|
3193
|
+
ae.errorCode = "unauthorized_client";
|
|
3194
|
+
var g0 = {
|
|
3195
3195
|
[H.errorCode]: H,
|
|
3196
|
-
[oe.errorCode]: oe,
|
|
3197
3196
|
[se.errorCode]: se,
|
|
3198
|
-
[ie.errorCode]: ie
|
|
3197
|
+
[ie.errorCode]: ie,
|
|
3198
|
+
[ae.errorCode]: ae
|
|
3199
3199
|
};
|
|
3200
|
-
function
|
|
3200
|
+
function y0(t) {
|
|
3201
3201
|
const e = typeof t == "string" ? new URL(t) : new URL(t.href);
|
|
3202
3202
|
return e.hash = "", e;
|
|
3203
3203
|
}
|
|
3204
|
-
function
|
|
3204
|
+
function w0({
|
|
3205
3205
|
requestedResource: t,
|
|
3206
3206
|
configuredResource: e
|
|
3207
3207
|
}) {
|
|
@@ -3211,12 +3211,12 @@ function yr({
|
|
|
3211
3211
|
const o = r.pathname.endsWith("/") ? r.pathname : r.pathname + "/", s = n.pathname.endsWith("/") ? n.pathname : n.pathname + "/";
|
|
3212
3212
|
return o.startsWith(s);
|
|
3213
3213
|
}
|
|
3214
|
-
var
|
|
3214
|
+
var ce = class extends Error {
|
|
3215
3215
|
constructor(t = "Unauthorized") {
|
|
3216
3216
|
super(t), this.name = "UnauthorizedError";
|
|
3217
3217
|
}
|
|
3218
3218
|
};
|
|
3219
|
-
function
|
|
3219
|
+
function le(t) {
|
|
3220
3220
|
var e;
|
|
3221
3221
|
const r = (e = t.headers.get("www-authenticate")) != null ? e : t.headers.get("WWW-Authenticate");
|
|
3222
3222
|
if (!r)
|
|
@@ -3232,45 +3232,45 @@ function ce(t) {
|
|
|
3232
3232
|
return;
|
|
3233
3233
|
}
|
|
3234
3234
|
}
|
|
3235
|
-
function
|
|
3235
|
+
function v0(t, e = "", r = {}) {
|
|
3236
3236
|
return e.endsWith("/") && (e = e.slice(0, -1)), r.prependPathname ? `${e}/.well-known/${t}` : `/.well-known/${t}${e}`;
|
|
3237
3237
|
}
|
|
3238
|
-
async function
|
|
3238
|
+
async function Ne(t, e, r = fetch) {
|
|
3239
3239
|
try {
|
|
3240
3240
|
return await r(t, { headers: e });
|
|
3241
3241
|
} catch (n) {
|
|
3242
3242
|
if (n instanceof TypeError)
|
|
3243
|
-
return e ?
|
|
3243
|
+
return e ? Ne(t, void 0, r) : void 0;
|
|
3244
3244
|
throw n;
|
|
3245
3245
|
}
|
|
3246
3246
|
}
|
|
3247
|
-
async function
|
|
3248
|
-
return await
|
|
3247
|
+
async function st(t, e, r = fetch) {
|
|
3248
|
+
return await Ne(t, {
|
|
3249
3249
|
"MCP-Protocol-Version": e
|
|
3250
3250
|
}, r);
|
|
3251
3251
|
}
|
|
3252
|
-
function
|
|
3252
|
+
function C0(t, e) {
|
|
3253
3253
|
return !t || t.status >= 400 && t.status < 500 && e !== "/";
|
|
3254
3254
|
}
|
|
3255
|
-
async function
|
|
3255
|
+
async function _0(t, e, r, n) {
|
|
3256
3256
|
var o, s;
|
|
3257
|
-
const a = new URL(t),
|
|
3257
|
+
const a = new URL(t), c = (o = n?.protocolVersion) != null ? o : B;
|
|
3258
3258
|
let d;
|
|
3259
3259
|
if (n?.metadataUrl)
|
|
3260
3260
|
d = new URL(n.metadataUrl);
|
|
3261
3261
|
else {
|
|
3262
|
-
const u =
|
|
3262
|
+
const u = v0(e, a.pathname);
|
|
3263
3263
|
d = new URL(u, (s = n?.metadataServerUrl) != null ? s : a), d.search = a.search;
|
|
3264
3264
|
}
|
|
3265
|
-
let
|
|
3266
|
-
if (!n?.metadataUrl &&
|
|
3265
|
+
let l = await st(d, c, r);
|
|
3266
|
+
if (!n?.metadataUrl && C0(l, a.pathname)) {
|
|
3267
3267
|
const u = new URL(`/.well-known/${e}`, a);
|
|
3268
|
-
|
|
3268
|
+
l = await st(u, c, r);
|
|
3269
3269
|
}
|
|
3270
|
-
return
|
|
3270
|
+
return l;
|
|
3271
3271
|
}
|
|
3272
|
-
async function
|
|
3273
|
-
const n = await
|
|
3272
|
+
async function b0(t, e, r = fetch) {
|
|
3273
|
+
const n = await _0(
|
|
3274
3274
|
t,
|
|
3275
3275
|
"oauth-protected-resource",
|
|
3276
3276
|
r,
|
|
@@ -3287,9 +3287,9 @@ async function _r(t, e, r = fetch) {
|
|
|
3287
3287
|
throw new Error(
|
|
3288
3288
|
`HTTP ${n.status} trying to load well-known OAuth protected resource metadata.`
|
|
3289
3289
|
);
|
|
3290
|
-
return
|
|
3290
|
+
return a0.parse(await n.json());
|
|
3291
3291
|
}
|
|
3292
|
-
function
|
|
3292
|
+
function x0(t) {
|
|
3293
3293
|
const e = typeof t == "string" ? new URL(t) : t, r = e.pathname !== "/", n = [];
|
|
3294
3294
|
if (!r)
|
|
3295
3295
|
return n.push({
|
|
@@ -3317,38 +3317,38 @@ function br(t) {
|
|
|
3317
3317
|
type: "oidc"
|
|
3318
3318
|
}), n;
|
|
3319
3319
|
}
|
|
3320
|
-
async function
|
|
3320
|
+
async function L0(t, {
|
|
3321
3321
|
fetchFn: e = fetch,
|
|
3322
3322
|
protocolVersion: r = B
|
|
3323
3323
|
} = {}) {
|
|
3324
3324
|
var n;
|
|
3325
|
-
const o = { "MCP-Protocol-Version": r }, s =
|
|
3326
|
-
for (const { url: a, type:
|
|
3327
|
-
const d = await
|
|
3325
|
+
const o = { "MCP-Protocol-Version": r }, s = x0(t);
|
|
3326
|
+
for (const { url: a, type: c } of s) {
|
|
3327
|
+
const d = await Ne(a, o, e);
|
|
3328
3328
|
if (d) {
|
|
3329
3329
|
if (!d.ok) {
|
|
3330
3330
|
if (d.status >= 400 && d.status < 500)
|
|
3331
3331
|
continue;
|
|
3332
3332
|
throw new Error(
|
|
3333
|
-
`HTTP ${d.status} trying to load ${
|
|
3333
|
+
`HTTP ${d.status} trying to load ${c === "oauth" ? "OAuth" : "OpenID provider"} metadata from ${a}`
|
|
3334
3334
|
);
|
|
3335
3335
|
}
|
|
3336
|
-
if (
|
|
3337
|
-
return
|
|
3336
|
+
if (c === "oauth")
|
|
3337
|
+
return Rt.parse(await d.json());
|
|
3338
3338
|
{
|
|
3339
|
-
const
|
|
3339
|
+
const l = l0.parse(
|
|
3340
3340
|
await d.json()
|
|
3341
3341
|
);
|
|
3342
|
-
if (!((n =
|
|
3342
|
+
if (!((n = l.code_challenge_methods_supported) != null && n.includes("S256")))
|
|
3343
3343
|
throw new Error(
|
|
3344
3344
|
`Incompatible OIDC provider at ${a}: does not support S256 code challenge method required by MCP specification`
|
|
3345
3345
|
);
|
|
3346
|
-
return
|
|
3346
|
+
return l;
|
|
3347
3347
|
}
|
|
3348
3348
|
}
|
|
3349
3349
|
}
|
|
3350
3350
|
}
|
|
3351
|
-
async function
|
|
3351
|
+
async function k0(t, {
|
|
3352
3352
|
metadata: e,
|
|
3353
3353
|
clientInformation: r,
|
|
3354
3354
|
redirectUrl: n,
|
|
@@ -3356,46 +3356,46 @@ async function Lr(t, {
|
|
|
3356
3356
|
state: s,
|
|
3357
3357
|
resource: a
|
|
3358
3358
|
}) {
|
|
3359
|
-
const
|
|
3360
|
-
let
|
|
3359
|
+
const c = "code", d = "S256";
|
|
3360
|
+
let l;
|
|
3361
3361
|
if (e) {
|
|
3362
|
-
if (
|
|
3362
|
+
if (l = new URL(e.authorization_endpoint), !e.response_types_supported.includes(c))
|
|
3363
3363
|
throw new Error(
|
|
3364
|
-
`Incompatible auth server: does not support response type ${
|
|
3364
|
+
`Incompatible auth server: does not support response type ${c}`
|
|
3365
3365
|
);
|
|
3366
3366
|
if (!e.code_challenge_methods_supported || !e.code_challenge_methods_supported.includes(d))
|
|
3367
3367
|
throw new Error(
|
|
3368
3368
|
`Incompatible auth server: does not support code challenge method ${d}`
|
|
3369
3369
|
);
|
|
3370
3370
|
} else
|
|
3371
|
-
|
|
3372
|
-
const u = await
|
|
3373
|
-
return
|
|
3371
|
+
l = new URL("/authorize", t);
|
|
3372
|
+
const u = await Or(), g = u.code_verifier, p = u.code_challenge;
|
|
3373
|
+
return l.searchParams.set("response_type", c), l.searchParams.set("client_id", r.client_id), l.searchParams.set("code_challenge", p), l.searchParams.set(
|
|
3374
3374
|
"code_challenge_method",
|
|
3375
3375
|
d
|
|
3376
|
-
),
|
|
3376
|
+
), l.searchParams.set("redirect_uri", String(n)), s && l.searchParams.set("state", s), o && l.searchParams.set("scope", o), o?.includes("offline_access") && l.searchParams.append("prompt", "consent"), a && l.searchParams.set("resource", a.href), { authorizationUrl: l, codeVerifier: g };
|
|
3377
3377
|
}
|
|
3378
|
-
function
|
|
3378
|
+
function At(t, e) {
|
|
3379
3379
|
const r = t.client_secret !== void 0;
|
|
3380
3380
|
return e.length === 0 ? r ? "client_secret_post" : "none" : r && e.includes("client_secret_basic") ? "client_secret_basic" : r && e.includes("client_secret_post") ? "client_secret_post" : e.includes("none") ? "none" : r ? "client_secret_post" : "none";
|
|
3381
3381
|
}
|
|
3382
|
-
function
|
|
3382
|
+
function Ot(t, e, r, n) {
|
|
3383
3383
|
const { client_id: o, client_secret: s } = e;
|
|
3384
3384
|
switch (t) {
|
|
3385
3385
|
case "client_secret_basic":
|
|
3386
|
-
|
|
3386
|
+
S0(o, s, r);
|
|
3387
3387
|
return;
|
|
3388
3388
|
case "client_secret_post":
|
|
3389
|
-
|
|
3389
|
+
P0(o, s, n);
|
|
3390
3390
|
return;
|
|
3391
3391
|
case "none":
|
|
3392
|
-
|
|
3392
|
+
T0(o, n);
|
|
3393
3393
|
return;
|
|
3394
3394
|
default:
|
|
3395
3395
|
throw new Error(`Unsupported client authentication method: ${t}`);
|
|
3396
3396
|
}
|
|
3397
3397
|
}
|
|
3398
|
-
function
|
|
3398
|
+
function S0(t, e, r) {
|
|
3399
3399
|
if (!e)
|
|
3400
3400
|
throw new Error(
|
|
3401
3401
|
"client_secret_basic authentication requires a client_secret"
|
|
@@ -3403,17 +3403,17 @@ function kr(t, e, r) {
|
|
|
3403
3403
|
const n = btoa(`${t}:${e}`);
|
|
3404
3404
|
r.set("Authorization", `Basic ${n}`);
|
|
3405
3405
|
}
|
|
3406
|
-
function
|
|
3406
|
+
function P0(t, e, r) {
|
|
3407
3407
|
r.set("client_id", t), e && r.set("client_secret", e);
|
|
3408
3408
|
}
|
|
3409
|
-
function
|
|
3409
|
+
function T0(t, e) {
|
|
3410
3410
|
e.set("client_id", t);
|
|
3411
3411
|
}
|
|
3412
|
-
async function
|
|
3412
|
+
async function je(t) {
|
|
3413
3413
|
const e = t instanceof Response ? t.status : void 0, r = t instanceof Response ? await t.text() : t;
|
|
3414
3414
|
try {
|
|
3415
|
-
const n =
|
|
3416
|
-
return new
|
|
3415
|
+
const n = p0.parse(JSON.parse(r)), { error: o, error_description: s, error_uri: a } = n, c = g0[o] || H;
|
|
3416
|
+
return new c({
|
|
3417
3417
|
message: s || "",
|
|
3418
3418
|
cause: a
|
|
3419
3419
|
});
|
|
@@ -3422,17 +3422,17 @@ async function Ne(t) {
|
|
|
3422
3422
|
return new H({ message: o });
|
|
3423
3423
|
}
|
|
3424
3424
|
}
|
|
3425
|
-
async function
|
|
3425
|
+
async function M0(t, {
|
|
3426
3426
|
metadata: e,
|
|
3427
3427
|
clientInformation: r,
|
|
3428
3428
|
authorizationCode: n,
|
|
3429
3429
|
codeVerifier: o,
|
|
3430
3430
|
redirectUri: s,
|
|
3431
3431
|
resource: a,
|
|
3432
|
-
addClientAuthentication:
|
|
3432
|
+
addClientAuthentication: c,
|
|
3433
3433
|
fetchFn: d
|
|
3434
3434
|
}) {
|
|
3435
|
-
var
|
|
3435
|
+
var l;
|
|
3436
3436
|
const u = "authorization_code", g = e?.token_endpoint ? new URL(e.token_endpoint) : new URL("/token", t);
|
|
3437
3437
|
if (e?.grant_types_supported && !e.grant_types_supported.includes(u))
|
|
3438
3438
|
throw new Error(
|
|
@@ -3447,14 +3447,14 @@ async function Tr(t, {
|
|
|
3447
3447
|
code_verifier: o,
|
|
3448
3448
|
redirect_uri: String(s)
|
|
3449
3449
|
});
|
|
3450
|
-
if (
|
|
3451
|
-
|
|
3450
|
+
if (c)
|
|
3451
|
+
c(p, f, t, e);
|
|
3452
3452
|
else {
|
|
3453
|
-
const h = (
|
|
3453
|
+
const h = (l = e?.token_endpoint_auth_methods_supported) != null ? l : [], m = At(
|
|
3454
3454
|
r,
|
|
3455
3455
|
h
|
|
3456
3456
|
);
|
|
3457
|
-
|
|
3457
|
+
Ot(m, r, p, f);
|
|
3458
3458
|
}
|
|
3459
3459
|
a && f.set("resource", a.href);
|
|
3460
3460
|
const y = await (d ?? fetch)(g, {
|
|
@@ -3463,10 +3463,10 @@ async function Tr(t, {
|
|
|
3463
3463
|
body: f
|
|
3464
3464
|
});
|
|
3465
3465
|
if (!y.ok)
|
|
3466
|
-
throw await
|
|
3467
|
-
return
|
|
3466
|
+
throw await je(y);
|
|
3467
|
+
return Et.parse(await y.json());
|
|
3468
3468
|
}
|
|
3469
|
-
async function
|
|
3469
|
+
async function E0(t, {
|
|
3470
3470
|
metadata: e,
|
|
3471
3471
|
clientInformation: r,
|
|
3472
3472
|
refreshToken: n,
|
|
@@ -3474,16 +3474,16 @@ async function Mr(t, {
|
|
|
3474
3474
|
addClientAuthentication: s,
|
|
3475
3475
|
fetchFn: a
|
|
3476
3476
|
}) {
|
|
3477
|
-
var
|
|
3477
|
+
var c;
|
|
3478
3478
|
const d = "refresh_token";
|
|
3479
|
-
let
|
|
3479
|
+
let l;
|
|
3480
3480
|
if (e) {
|
|
3481
|
-
if (
|
|
3481
|
+
if (l = new URL(e.token_endpoint), e.grant_types_supported && !e.grant_types_supported.includes(d))
|
|
3482
3482
|
throw new Error(
|
|
3483
3483
|
`Incompatible auth server: does not support grant type ${d}`
|
|
3484
3484
|
);
|
|
3485
3485
|
} else
|
|
3486
|
-
|
|
3486
|
+
l = new URL("/token", t);
|
|
3487
3487
|
const u = new Headers({
|
|
3488
3488
|
"Content-Type": "application/x-www-form-urlencoded",
|
|
3489
3489
|
Accept: "application/json"
|
|
@@ -3494,26 +3494,26 @@ async function Mr(t, {
|
|
|
3494
3494
|
if (s)
|
|
3495
3495
|
s(u, g, t, e);
|
|
3496
3496
|
else {
|
|
3497
|
-
const f = (
|
|
3497
|
+
const f = (c = e?.token_endpoint_auth_methods_supported) != null ? c : [], y = At(
|
|
3498
3498
|
r,
|
|
3499
3499
|
f
|
|
3500
3500
|
);
|
|
3501
|
-
|
|
3501
|
+
Ot(y, r, u, g);
|
|
3502
3502
|
}
|
|
3503
3503
|
o && g.set("resource", o.href);
|
|
3504
|
-
const p = await (a ?? fetch)(
|
|
3504
|
+
const p = await (a ?? fetch)(l, {
|
|
3505
3505
|
method: "POST",
|
|
3506
3506
|
headers: u,
|
|
3507
3507
|
body: g
|
|
3508
3508
|
});
|
|
3509
3509
|
if (!p.ok)
|
|
3510
|
-
throw await
|
|
3511
|
-
return
|
|
3510
|
+
throw await je(p);
|
|
3511
|
+
return Et.parse({
|
|
3512
3512
|
refresh_token: n,
|
|
3513
3513
|
...await p.json()
|
|
3514
3514
|
});
|
|
3515
3515
|
}
|
|
3516
|
-
async function
|
|
3516
|
+
async function R0(t, {
|
|
3517
3517
|
metadata: e,
|
|
3518
3518
|
clientMetadata: r,
|
|
3519
3519
|
fetchFn: n
|
|
@@ -3535,30 +3535,30 @@ async function Er(t, {
|
|
|
3535
3535
|
body: JSON.stringify(r)
|
|
3536
3536
|
});
|
|
3537
3537
|
if (!s.ok)
|
|
3538
|
-
throw await
|
|
3539
|
-
return
|
|
3538
|
+
throw await je(s);
|
|
3539
|
+
return h0.parse(await s.json());
|
|
3540
3540
|
}
|
|
3541
|
-
async function
|
|
3541
|
+
async function de(t, e) {
|
|
3542
3542
|
var r, n;
|
|
3543
3543
|
try {
|
|
3544
|
-
return await
|
|
3544
|
+
return await Ce(t, e);
|
|
3545
3545
|
} catch (o) {
|
|
3546
|
-
if (o instanceof
|
|
3547
|
-
return await ((r = t.invalidateCredentials) == null ? void 0 : r.call(t, "all")), await
|
|
3548
|
-
if (o instanceof
|
|
3549
|
-
return await ((n = t.invalidateCredentials) == null ? void 0 : n.call(t, "tokens")), await
|
|
3546
|
+
if (o instanceof se || o instanceof ae)
|
|
3547
|
+
return await ((r = t.invalidateCredentials) == null ? void 0 : r.call(t, "all")), await Ce(t, e);
|
|
3548
|
+
if (o instanceof ie)
|
|
3549
|
+
return await ((n = t.invalidateCredentials) == null ? void 0 : n.call(t, "tokens")), await Ce(t, e);
|
|
3550
3550
|
throw o;
|
|
3551
3551
|
}
|
|
3552
3552
|
}
|
|
3553
|
-
async function
|
|
3554
|
-
const n =
|
|
3553
|
+
async function I0(t, e, r) {
|
|
3554
|
+
const n = y0(t);
|
|
3555
3555
|
if (e.validateResourceURL)
|
|
3556
3556
|
return await e.validateResourceURL(
|
|
3557
3557
|
n,
|
|
3558
3558
|
r?.resource
|
|
3559
3559
|
);
|
|
3560
3560
|
if (r) {
|
|
3561
|
-
if (!
|
|
3561
|
+
if (!w0({
|
|
3562
3562
|
requestedResource: n,
|
|
3563
3563
|
configuredResource: r.resource
|
|
3564
3564
|
}))
|
|
@@ -3568,29 +3568,29 @@ async function Rr(t, e, r) {
|
|
|
3568
3568
|
return new URL(r.resource);
|
|
3569
3569
|
}
|
|
3570
3570
|
}
|
|
3571
|
-
async function
|
|
3571
|
+
async function Ce(t, {
|
|
3572
3572
|
serverUrl: e,
|
|
3573
3573
|
authorizationCode: r,
|
|
3574
3574
|
scope: n,
|
|
3575
3575
|
resourceMetadataUrl: o,
|
|
3576
3576
|
fetchFn: s
|
|
3577
3577
|
}) {
|
|
3578
|
-
let a,
|
|
3578
|
+
let a, c;
|
|
3579
3579
|
try {
|
|
3580
|
-
a = await
|
|
3580
|
+
a = await b0(
|
|
3581
3581
|
e,
|
|
3582
3582
|
{ resourceMetadataUrl: o },
|
|
3583
3583
|
s
|
|
3584
|
-
), a.authorization_servers && a.authorization_servers.length > 0 && (
|
|
3584
|
+
), a.authorization_servers && a.authorization_servers.length > 0 && (c = a.authorization_servers[0]);
|
|
3585
3585
|
} catch {
|
|
3586
3586
|
}
|
|
3587
|
-
|
|
3588
|
-
const d = await
|
|
3587
|
+
c || (c = e);
|
|
3588
|
+
const d = await I0(
|
|
3589
3589
|
e,
|
|
3590
3590
|
t,
|
|
3591
3591
|
a
|
|
3592
|
-
),
|
|
3593
|
-
|
|
3592
|
+
), l = await L0(
|
|
3593
|
+
c,
|
|
3594
3594
|
{
|
|
3595
3595
|
fetchFn: s
|
|
3596
3596
|
}
|
|
@@ -3605,16 +3605,16 @@ async function we(t, {
|
|
|
3605
3605
|
throw new Error(
|
|
3606
3606
|
"OAuth client information must be saveable for dynamic registration"
|
|
3607
3607
|
);
|
|
3608
|
-
const h = await
|
|
3609
|
-
metadata:
|
|
3608
|
+
const h = await R0(c, {
|
|
3609
|
+
metadata: l,
|
|
3610
3610
|
clientMetadata: t.clientMetadata,
|
|
3611
3611
|
fetchFn: s
|
|
3612
3612
|
});
|
|
3613
3613
|
await t.saveClientInformation(h), u = h;
|
|
3614
3614
|
}
|
|
3615
3615
|
if (r !== void 0) {
|
|
3616
|
-
const h = await t.codeVerifier(), m = await
|
|
3617
|
-
metadata:
|
|
3616
|
+
const h = await t.codeVerifier(), m = await M0(c, {
|
|
3617
|
+
metadata: l,
|
|
3618
3618
|
clientInformation: u,
|
|
3619
3619
|
authorizationCode: r,
|
|
3620
3620
|
codeVerifier: h,
|
|
@@ -3628,8 +3628,8 @@ async function we(t, {
|
|
|
3628
3628
|
const g = await t.tokens();
|
|
3629
3629
|
if (g?.refresh_token)
|
|
3630
3630
|
try {
|
|
3631
|
-
const h = await
|
|
3632
|
-
metadata:
|
|
3631
|
+
const h = await E0(c, {
|
|
3632
|
+
metadata: l,
|
|
3633
3633
|
clientInformation: u,
|
|
3634
3634
|
refreshToken: g.refresh_token,
|
|
3635
3635
|
resource: d,
|
|
@@ -3640,13 +3640,13 @@ async function we(t, {
|
|
|
3640
3640
|
} catch (h) {
|
|
3641
3641
|
if (
|
|
3642
3642
|
// If this is a ServerError, or an unknown type, log it out and try to continue. Otherwise, escalate so we can fix things and retry.
|
|
3643
|
-
!(!(h instanceof
|
|
3643
|
+
!(!(h instanceof X) || h instanceof H)
|
|
3644
3644
|
) throw h;
|
|
3645
3645
|
}
|
|
3646
|
-
const p = t.state ? await t.state() : void 0, { authorizationUrl: f, codeVerifier: y } = await
|
|
3647
|
-
|
|
3646
|
+
const p = t.state ? await t.state() : void 0, { authorizationUrl: f, codeVerifier: y } = await k0(
|
|
3647
|
+
c,
|
|
3648
3648
|
{
|
|
3649
|
-
metadata:
|
|
3649
|
+
metadata: l,
|
|
3650
3650
|
clientInformation: u,
|
|
3651
3651
|
state: p,
|
|
3652
3652
|
redirectUrl: t.redirectUrl,
|
|
@@ -3656,7 +3656,7 @@ async function we(t, {
|
|
|
3656
3656
|
);
|
|
3657
3657
|
return await t.saveCodeVerifier(y), await t.redirectToAuthorization(f), "REDIRECT";
|
|
3658
3658
|
}
|
|
3659
|
-
var
|
|
3659
|
+
var A0 = class {
|
|
3660
3660
|
constructor({
|
|
3661
3661
|
url: t,
|
|
3662
3662
|
headers: e,
|
|
@@ -3674,10 +3674,10 @@ var Ir = class {
|
|
|
3674
3674
|
const r = await this.authProvider.tokens();
|
|
3675
3675
|
r?.access_token && (e.Authorization = `Bearer ${r.access_token}`);
|
|
3676
3676
|
}
|
|
3677
|
-
return
|
|
3677
|
+
return ht(
|
|
3678
3678
|
e,
|
|
3679
|
-
`ai-sdk/${
|
|
3680
|
-
|
|
3679
|
+
`ai-sdk/${Mt}`,
|
|
3680
|
+
pt()
|
|
3681
3681
|
);
|
|
3682
3682
|
}
|
|
3683
3683
|
async start() {
|
|
@@ -3686,22 +3686,22 @@ var Ir = class {
|
|
|
3686
3686
|
return t();
|
|
3687
3687
|
this.abortController = new AbortController();
|
|
3688
3688
|
const r = async (n = !1) => {
|
|
3689
|
-
var o, s, a,
|
|
3689
|
+
var o, s, a, c, d;
|
|
3690
3690
|
try {
|
|
3691
|
-
const
|
|
3691
|
+
const l = await this.commonHeaders({
|
|
3692
3692
|
Accept: "text/event-stream"
|
|
3693
3693
|
}), u = await fetch(this.url.href, {
|
|
3694
|
-
headers:
|
|
3694
|
+
headers: l,
|
|
3695
3695
|
signal: (o = this.abortController) == null ? void 0 : o.signal
|
|
3696
3696
|
});
|
|
3697
3697
|
if (u.status === 401 && this.authProvider && !n) {
|
|
3698
|
-
this.resourceMetadataUrl =
|
|
3698
|
+
this.resourceMetadataUrl = le(u);
|
|
3699
3699
|
try {
|
|
3700
|
-
if (await
|
|
3700
|
+
if (await de(this.authProvider, {
|
|
3701
3701
|
serverUrl: this.url,
|
|
3702
3702
|
resourceMetadataUrl: this.resourceMetadataUrl
|
|
3703
3703
|
}) !== "AUTHORIZED") {
|
|
3704
|
-
const h = new
|
|
3704
|
+
const h = new ce();
|
|
3705
3705
|
return (s = this.onerror) == null || s.call(this, h), e(h);
|
|
3706
3706
|
}
|
|
3707
3707
|
} catch (y) {
|
|
@@ -3715,9 +3715,9 @@ var Ir = class {
|
|
|
3715
3715
|
const h = new C({
|
|
3716
3716
|
message: y
|
|
3717
3717
|
});
|
|
3718
|
-
return (
|
|
3718
|
+
return (c = this.onerror) == null || c.call(this, h), e(h);
|
|
3719
3719
|
}
|
|
3720
|
-
const p = u.body.pipeThrough(new TextDecoderStream()).pipeThrough(new
|
|
3720
|
+
const p = u.body.pipeThrough(new TextDecoderStream()).pipeThrough(new ke()).getReader(), f = async () => {
|
|
3721
3721
|
var y, h, m;
|
|
3722
3722
|
try {
|
|
3723
3723
|
for (; ; ) {
|
|
@@ -3738,7 +3738,7 @@ var Ir = class {
|
|
|
3738
3738
|
this.connected = !0, t();
|
|
3739
3739
|
} else if (x === "message")
|
|
3740
3740
|
try {
|
|
3741
|
-
const P =
|
|
3741
|
+
const P = K.parse(
|
|
3742
3742
|
JSON.parse(M)
|
|
3743
3743
|
);
|
|
3744
3744
|
(y = this.onmessage) == null || y.call(this, P);
|
|
@@ -3759,10 +3759,10 @@ var Ir = class {
|
|
|
3759
3759
|
this.sseConnection = {
|
|
3760
3760
|
close: () => p.cancel()
|
|
3761
3761
|
}, f();
|
|
3762
|
-
} catch (
|
|
3763
|
-
if (
|
|
3762
|
+
} catch (l) {
|
|
3763
|
+
if (l instanceof Error && l.name === "AbortError")
|
|
3764
3764
|
return;
|
|
3765
|
-
(d = this.onerror) == null || d.call(this,
|
|
3765
|
+
(d = this.onerror) == null || d.call(this, l), e(l);
|
|
3766
3766
|
}
|
|
3767
3767
|
};
|
|
3768
3768
|
r();
|
|
@@ -3778,7 +3778,7 @@ var Ir = class {
|
|
|
3778
3778
|
message: "MCP SSE Transport Error: Not connected"
|
|
3779
3779
|
});
|
|
3780
3780
|
const e = this.endpoint, r = async (n = !1) => {
|
|
3781
|
-
var o, s, a,
|
|
3781
|
+
var o, s, a, c, d;
|
|
3782
3782
|
try {
|
|
3783
3783
|
const u = {
|
|
3784
3784
|
method: "POST",
|
|
@@ -3789,13 +3789,13 @@ var Ir = class {
|
|
|
3789
3789
|
signal: (o = this.abortController) == null ? void 0 : o.signal
|
|
3790
3790
|
}, g = await fetch(e, u);
|
|
3791
3791
|
if (g.status === 401 && this.authProvider && !n) {
|
|
3792
|
-
this.resourceMetadataUrl =
|
|
3792
|
+
this.resourceMetadataUrl = le(g);
|
|
3793
3793
|
try {
|
|
3794
|
-
if (await
|
|
3794
|
+
if (await de(this.authProvider, {
|
|
3795
3795
|
serverUrl: this.url,
|
|
3796
3796
|
resourceMetadataUrl: this.resourceMetadataUrl
|
|
3797
3797
|
}) !== "AUTHORIZED") {
|
|
3798
|
-
const f = new
|
|
3798
|
+
const f = new ce();
|
|
3799
3799
|
(s = this.onerror) == null || s.call(this, f);
|
|
3800
3800
|
return;
|
|
3801
3801
|
}
|
|
@@ -3809,17 +3809,17 @@ var Ir = class {
|
|
|
3809
3809
|
const p = await g.text().catch(() => null), f = new C({
|
|
3810
3810
|
message: `MCP SSE Transport Error: POSTing to endpoint (HTTP ${g.status}): ${p}`
|
|
3811
3811
|
});
|
|
3812
|
-
(
|
|
3812
|
+
(c = this.onerror) == null || c.call(this, f);
|
|
3813
3813
|
return;
|
|
3814
3814
|
}
|
|
3815
|
-
} catch (
|
|
3816
|
-
(d = this.onerror) == null || d.call(this,
|
|
3815
|
+
} catch (l) {
|
|
3816
|
+
(d = this.onerror) == null || d.call(this, l);
|
|
3817
3817
|
return;
|
|
3818
3818
|
}
|
|
3819
3819
|
};
|
|
3820
3820
|
await r();
|
|
3821
3821
|
}
|
|
3822
|
-
},
|
|
3822
|
+
}, O0 = class {
|
|
3823
3823
|
constructor({
|
|
3824
3824
|
url: t,
|
|
3825
3825
|
headers: e,
|
|
@@ -3842,10 +3842,10 @@ var Ir = class {
|
|
|
3842
3842
|
const r = await this.authProvider.tokens();
|
|
3843
3843
|
r?.access_token && (e.Authorization = `Bearer ${r.access_token}`);
|
|
3844
3844
|
}
|
|
3845
|
-
return
|
|
3845
|
+
return ht(
|
|
3846
3846
|
e,
|
|
3847
|
-
`ai-sdk/${
|
|
3848
|
-
|
|
3847
|
+
`ai-sdk/${Mt}`,
|
|
3848
|
+
pt()
|
|
3849
3849
|
);
|
|
3850
3850
|
}
|
|
3851
3851
|
async start() {
|
|
@@ -3874,7 +3874,7 @@ var Ir = class {
|
|
|
3874
3874
|
}
|
|
3875
3875
|
async send(t) {
|
|
3876
3876
|
const e = async (r = !1) => {
|
|
3877
|
-
var n, o, s, a,
|
|
3877
|
+
var n, o, s, a, c, d, l;
|
|
3878
3878
|
try {
|
|
3879
3879
|
const g = {
|
|
3880
3880
|
method: "POST",
|
|
@@ -3886,13 +3886,13 @@ var Ir = class {
|
|
|
3886
3886
|
signal: (n = this.abortController) == null ? void 0 : n.signal
|
|
3887
3887
|
}, p = await fetch(this.url, g), f = p.headers.get("mcp-session-id");
|
|
3888
3888
|
if (f && (this.sessionId = f), p.status === 401 && this.authProvider && !r) {
|
|
3889
|
-
this.resourceMetadataUrl =
|
|
3889
|
+
this.resourceMetadataUrl = le(p);
|
|
3890
3890
|
try {
|
|
3891
|
-
if (await
|
|
3891
|
+
if (await de(this.authProvider, {
|
|
3892
3892
|
serverUrl: this.url,
|
|
3893
3893
|
resourceMetadataUrl: this.resourceMetadataUrl
|
|
3894
3894
|
}) !== "AUTHORIZED")
|
|
3895
|
-
throw new
|
|
3895
|
+
throw new ce();
|
|
3896
3896
|
} catch (v) {
|
|
3897
3897
|
throw (o = this.onerror) == null || o.call(this, v), v;
|
|
3898
3898
|
}
|
|
@@ -3915,7 +3915,7 @@ var Ir = class {
|
|
|
3915
3915
|
return;
|
|
3916
3916
|
const h = p.headers.get("content-type") || "";
|
|
3917
3917
|
if (h.includes("application/json")) {
|
|
3918
|
-
const v = await p.json(), b = Array.isArray(v) ? v.map((x) =>
|
|
3918
|
+
const v = await p.json(), b = Array.isArray(v) ? v.map((x) => K.parse(x)) : [K.parse(v)];
|
|
3919
3919
|
for (const x of b) (a = this.onmessage) == null || a.call(this, x);
|
|
3920
3920
|
return;
|
|
3921
3921
|
}
|
|
@@ -3924,19 +3924,19 @@ var Ir = class {
|
|
|
3924
3924
|
const M = new C({
|
|
3925
3925
|
message: "MCP HTTP Transport Error: text/event-stream response without body"
|
|
3926
3926
|
});
|
|
3927
|
-
throw (
|
|
3927
|
+
throw (c = this.onerror) == null || c.call(this, M), M;
|
|
3928
3928
|
}
|
|
3929
|
-
const b = p.body.pipeThrough(new TextDecoderStream()).pipeThrough(new
|
|
3929
|
+
const b = p.body.pipeThrough(new TextDecoderStream()).pipeThrough(new ke()).getReader();
|
|
3930
3930
|
(async () => {
|
|
3931
3931
|
var M, P, E;
|
|
3932
3932
|
try {
|
|
3933
3933
|
for (; ; ) {
|
|
3934
|
-
const { done: R, value:
|
|
3934
|
+
const { done: R, value: q } = await b.read();
|
|
3935
3935
|
if (R) return;
|
|
3936
|
-
const { event: I, data: j } =
|
|
3936
|
+
const { event: I, data: j } = q;
|
|
3937
3937
|
if (I === "message")
|
|
3938
3938
|
try {
|
|
3939
|
-
const J =
|
|
3939
|
+
const J = K.parse(JSON.parse(j));
|
|
3940
3940
|
(M = this.onmessage) == null || M.call(this, J);
|
|
3941
3941
|
} catch (J) {
|
|
3942
3942
|
const A = new C({
|
|
@@ -3959,7 +3959,7 @@ var Ir = class {
|
|
|
3959
3959
|
});
|
|
3960
3960
|
throw (d = this.onerror) == null || d.call(this, m), m;
|
|
3961
3961
|
} catch (u) {
|
|
3962
|
-
throw (
|
|
3962
|
+
throw (l = this.onerror) == null || l.call(this, u), u;
|
|
3963
3963
|
}
|
|
3964
3964
|
};
|
|
3965
3965
|
await e();
|
|
@@ -3995,25 +3995,25 @@ var Ir = class {
|
|
|
3995
3995
|
}
|
|
3996
3996
|
// Open optional inbound SSE stream; best-effort and resumable
|
|
3997
3997
|
async openInboundSse(t = !1, e) {
|
|
3998
|
-
var r, n, o, s, a,
|
|
3998
|
+
var r, n, o, s, a, c;
|
|
3999
3999
|
try {
|
|
4000
4000
|
const d = await this.commonHeaders({
|
|
4001
4001
|
Accept: "text/event-stream"
|
|
4002
4002
|
});
|
|
4003
4003
|
e && (d["last-event-id"] = e);
|
|
4004
|
-
const
|
|
4004
|
+
const l = await fetch(this.url.href, {
|
|
4005
4005
|
method: "GET",
|
|
4006
4006
|
headers: d,
|
|
4007
4007
|
signal: (r = this.abortController) == null ? void 0 : r.signal
|
|
4008
|
-
}), u =
|
|
4009
|
-
if (u && (this.sessionId = u),
|
|
4010
|
-
this.resourceMetadataUrl =
|
|
4008
|
+
}), u = l.headers.get("mcp-session-id");
|
|
4009
|
+
if (u && (this.sessionId = u), l.status === 401 && this.authProvider && !t) {
|
|
4010
|
+
this.resourceMetadataUrl = le(l);
|
|
4011
4011
|
try {
|
|
4012
|
-
if (await
|
|
4012
|
+
if (await de(this.authProvider, {
|
|
4013
4013
|
serverUrl: this.url,
|
|
4014
4014
|
resourceMetadataUrl: this.resourceMetadataUrl
|
|
4015
4015
|
}) !== "AUTHORIZED") {
|
|
4016
|
-
const h = new
|
|
4016
|
+
const h = new ce();
|
|
4017
4017
|
(n = this.onerror) == null || n.call(this, h);
|
|
4018
4018
|
return;
|
|
4019
4019
|
}
|
|
@@ -4023,16 +4023,16 @@ var Ir = class {
|
|
|
4023
4023
|
}
|
|
4024
4024
|
return this.openInboundSse(!0, e);
|
|
4025
4025
|
}
|
|
4026
|
-
if (
|
|
4026
|
+
if (l.status === 405)
|
|
4027
4027
|
return;
|
|
4028
|
-
if (!
|
|
4028
|
+
if (!l.ok || !l.body) {
|
|
4029
4029
|
const y = new C({
|
|
4030
|
-
message: `MCP HTTP Transport Error: GET SSE failed: ${
|
|
4030
|
+
message: `MCP HTTP Transport Error: GET SSE failed: ${l.status} ${l.statusText}`
|
|
4031
4031
|
});
|
|
4032
4032
|
(s = this.onerror) == null || s.call(this, y);
|
|
4033
4033
|
return;
|
|
4034
4034
|
}
|
|
4035
|
-
const p =
|
|
4035
|
+
const p = l.body.pipeThrough(new TextDecoderStream()).pipeThrough(new ke()).getReader(), f = async () => {
|
|
4036
4036
|
var y, h, m, v;
|
|
4037
4037
|
try {
|
|
4038
4038
|
for (; ; ) {
|
|
@@ -4041,14 +4041,14 @@ var Ir = class {
|
|
|
4041
4041
|
const { event: M, data: P, id: E } = x;
|
|
4042
4042
|
if (E && (this.lastInboundEventId = E), M === "message")
|
|
4043
4043
|
try {
|
|
4044
|
-
const R =
|
|
4044
|
+
const R = K.parse(JSON.parse(P));
|
|
4045
4045
|
(y = this.onmessage) == null || y.call(this, R);
|
|
4046
4046
|
} catch (R) {
|
|
4047
|
-
const
|
|
4047
|
+
const q = new C({
|
|
4048
4048
|
message: "MCP HTTP Transport Error: Failed to parse message",
|
|
4049
4049
|
cause: R
|
|
4050
4050
|
});
|
|
4051
|
-
(h = this.onerror) == null || h.call(this,
|
|
4051
|
+
(h = this.onerror) == null || h.call(this, q);
|
|
4052
4052
|
}
|
|
4053
4053
|
}
|
|
4054
4054
|
} catch (b) {
|
|
@@ -4063,27 +4063,27 @@ var Ir = class {
|
|
|
4063
4063
|
} catch (d) {
|
|
4064
4064
|
if (d instanceof Error && d.name === "AbortError")
|
|
4065
4065
|
return;
|
|
4066
|
-
(a = this.onerror) == null || a.call(this, d), (
|
|
4066
|
+
(a = this.onerror) == null || a.call(this, d), (c = this.abortController) != null && c.signal.aborted || this.scheduleInboundSseReconnection();
|
|
4067
4067
|
}
|
|
4068
4068
|
}
|
|
4069
4069
|
};
|
|
4070
|
-
function
|
|
4070
|
+
function $0(t) {
|
|
4071
4071
|
switch (t.type) {
|
|
4072
4072
|
case "sse":
|
|
4073
|
-
return new
|
|
4073
|
+
return new A0(t);
|
|
4074
4074
|
case "http":
|
|
4075
|
-
return new
|
|
4075
|
+
return new O0(t);
|
|
4076
4076
|
default:
|
|
4077
4077
|
throw new C({
|
|
4078
4078
|
message: "Unsupported or invalid transport configuration. If you are using a custom transport, make sure it implements the MCPTransport interface."
|
|
4079
4079
|
});
|
|
4080
4080
|
}
|
|
4081
4081
|
}
|
|
4082
|
-
function
|
|
4082
|
+
function U0(t) {
|
|
4083
4083
|
return "start" in t && typeof t.start == "function" && "send" in t && typeof t.send == "function" && "close" in t && typeof t.close == "function";
|
|
4084
4084
|
}
|
|
4085
|
-
var
|
|
4086
|
-
function
|
|
4085
|
+
var N0 = "1.0.0";
|
|
4086
|
+
function it({
|
|
4087
4087
|
output: t
|
|
4088
4088
|
}) {
|
|
4089
4089
|
const e = t;
|
|
@@ -4095,19 +4095,19 @@ function ot({
|
|
|
4095
4095
|
} : { type: "text", text: JSON.stringify(n) }
|
|
4096
4096
|
) };
|
|
4097
4097
|
}
|
|
4098
|
-
async function
|
|
4099
|
-
const e = new
|
|
4098
|
+
async function j0(t) {
|
|
4099
|
+
const e = new Z0(t);
|
|
4100
4100
|
return await e.init(), e;
|
|
4101
4101
|
}
|
|
4102
|
-
var
|
|
4102
|
+
var Z0 = class {
|
|
4103
4103
|
constructor({
|
|
4104
4104
|
transport: t,
|
|
4105
4105
|
name: e = "ai-sdk-mcp-client",
|
|
4106
|
-
version: r =
|
|
4106
|
+
version: r = N0,
|
|
4107
4107
|
onUncaughtError: n,
|
|
4108
4108
|
capabilities: o
|
|
4109
4109
|
}) {
|
|
4110
|
-
this.requestMessageId = 0, this.responseHandlers = /* @__PURE__ */ new Map(), this.serverCapabilities = {}, this.isClosed = !0, this.onUncaughtError = n, this.clientCapabilities = o ?? {},
|
|
4110
|
+
this.requestMessageId = 0, this.responseHandlers = /* @__PURE__ */ new Map(), this.serverCapabilities = {}, this.isClosed = !0, this.onUncaughtError = n, this.clientCapabilities = o ?? {}, U0(t) ? this.transport = t : this.transport = $0(t), this.transport.onclose = () => this.onClose(), this.transport.onerror = (s) => this.onError(s), this.transport.onmessage = (s) => {
|
|
4111
4111
|
if ("method" in s) {
|
|
4112
4112
|
"id" in s ? this.onRequestMessage(s) : this.onError(
|
|
4113
4113
|
new C({
|
|
@@ -4134,13 +4134,13 @@ var jr = class {
|
|
|
4134
4134
|
clientInfo: this.clientInfo
|
|
4135
4135
|
}
|
|
4136
4136
|
},
|
|
4137
|
-
resultSchema:
|
|
4137
|
+
resultSchema: qr
|
|
4138
4138
|
});
|
|
4139
4139
|
if (t === void 0)
|
|
4140
4140
|
throw new C({
|
|
4141
4141
|
message: "Server sent invalid initialize result"
|
|
4142
4142
|
});
|
|
4143
|
-
if (!
|
|
4143
|
+
if (!Nr.includes(t.protocolVersion))
|
|
4144
4144
|
throw new C({
|
|
4145
4145
|
message: `Server's protocol version is not supported: ${t.protocolVersion}`
|
|
4146
4146
|
});
|
|
@@ -4202,14 +4202,14 @@ var jr = class {
|
|
|
4202
4202
|
this.assertCapability(t.method);
|
|
4203
4203
|
const s = r?.signal;
|
|
4204
4204
|
s?.throwIfAborted();
|
|
4205
|
-
const a = this.requestMessageId++,
|
|
4205
|
+
const a = this.requestMessageId++, c = {
|
|
4206
4206
|
...t,
|
|
4207
4207
|
jsonrpc: "2.0",
|
|
4208
4208
|
id: a
|
|
4209
4209
|
}, d = () => {
|
|
4210
4210
|
this.responseHandlers.delete(a);
|
|
4211
4211
|
};
|
|
4212
|
-
this.responseHandlers.set(a, (
|
|
4212
|
+
this.responseHandlers.set(a, (l) => {
|
|
4213
4213
|
if (s?.aborted)
|
|
4214
4214
|
return o(
|
|
4215
4215
|
new C({
|
|
@@ -4217,10 +4217,10 @@ var jr = class {
|
|
|
4217
4217
|
cause: s.reason
|
|
4218
4218
|
})
|
|
4219
4219
|
);
|
|
4220
|
-
if (
|
|
4221
|
-
return o(
|
|
4220
|
+
if (l instanceof Error)
|
|
4221
|
+
return o(l);
|
|
4222
4222
|
try {
|
|
4223
|
-
const u = e.parse(
|
|
4223
|
+
const u = e.parse(l.result);
|
|
4224
4224
|
n(u);
|
|
4225
4225
|
} catch (u) {
|
|
4226
4226
|
const g = new C({
|
|
@@ -4229,8 +4229,8 @@ var jr = class {
|
|
|
4229
4229
|
});
|
|
4230
4230
|
o(g);
|
|
4231
4231
|
}
|
|
4232
|
-
}), this.transport.send(
|
|
4233
|
-
d(), o(
|
|
4232
|
+
}), this.transport.send(c).catch((l) => {
|
|
4233
|
+
d(), o(l);
|
|
4234
4234
|
});
|
|
4235
4235
|
});
|
|
4236
4236
|
}
|
|
@@ -4240,7 +4240,7 @@ var jr = class {
|
|
|
4240
4240
|
} = {}) {
|
|
4241
4241
|
return this.request({
|
|
4242
4242
|
request: { method: "tools/list", params: t },
|
|
4243
|
-
resultSchema:
|
|
4243
|
+
resultSchema: Hr,
|
|
4244
4244
|
options: e
|
|
4245
4245
|
});
|
|
4246
4246
|
}
|
|
@@ -4252,7 +4252,7 @@ var jr = class {
|
|
|
4252
4252
|
try {
|
|
4253
4253
|
return this.request({
|
|
4254
4254
|
request: { method: "tools/call", params: { name: t, arguments: e } },
|
|
4255
|
-
resultSchema:
|
|
4255
|
+
resultSchema: Vr,
|
|
4256
4256
|
options: {
|
|
4257
4257
|
signal: r?.abortSignal
|
|
4258
4258
|
}
|
|
@@ -4268,7 +4268,7 @@ var jr = class {
|
|
|
4268
4268
|
try {
|
|
4269
4269
|
return this.request({
|
|
4270
4270
|
request: { method: "resources/list", params: t },
|
|
4271
|
-
resultSchema:
|
|
4271
|
+
resultSchema: Br,
|
|
4272
4272
|
options: e
|
|
4273
4273
|
});
|
|
4274
4274
|
} catch (r) {
|
|
@@ -4282,7 +4282,7 @@ var jr = class {
|
|
|
4282
4282
|
try {
|
|
4283
4283
|
return this.request({
|
|
4284
4284
|
request: { method: "resources/read", params: { uri: t } },
|
|
4285
|
-
resultSchema:
|
|
4285
|
+
resultSchema: Gr,
|
|
4286
4286
|
options: e
|
|
4287
4287
|
});
|
|
4288
4288
|
} catch (r) {
|
|
@@ -4295,7 +4295,7 @@ var jr = class {
|
|
|
4295
4295
|
try {
|
|
4296
4296
|
return this.request({
|
|
4297
4297
|
request: { method: "resources/templates/list" },
|
|
4298
|
-
resultSchema:
|
|
4298
|
+
resultSchema: Wr,
|
|
4299
4299
|
options: t
|
|
4300
4300
|
});
|
|
4301
4301
|
} catch (e) {
|
|
@@ -4309,7 +4309,7 @@ var jr = class {
|
|
|
4309
4309
|
try {
|
|
4310
4310
|
return this.request({
|
|
4311
4311
|
request: { method: "prompts/list", params: t },
|
|
4312
|
-
resultSchema:
|
|
4312
|
+
resultSchema: Qr,
|
|
4313
4313
|
options: e
|
|
4314
4314
|
});
|
|
4315
4315
|
} catch (r) {
|
|
@@ -4324,7 +4324,7 @@ var jr = class {
|
|
|
4324
4324
|
try {
|
|
4325
4325
|
return this.request({
|
|
4326
4326
|
request: { method: "prompts/get", params: { name: t, arguments: e } },
|
|
4327
|
-
resultSchema:
|
|
4327
|
+
resultSchema: e0,
|
|
4328
4328
|
options: r
|
|
4329
4329
|
});
|
|
4330
4330
|
} catch (n) {
|
|
@@ -4360,12 +4360,12 @@ var jr = class {
|
|
|
4360
4360
|
for (const {
|
|
4361
4361
|
name: s,
|
|
4362
4362
|
title: a,
|
|
4363
|
-
description:
|
|
4363
|
+
description: c,
|
|
4364
4364
|
inputSchema: d,
|
|
4365
|
-
annotations:
|
|
4365
|
+
annotations: l,
|
|
4366
4366
|
_meta: u
|
|
4367
4367
|
} of t.tools) {
|
|
4368
|
-
const g = a ??
|
|
4368
|
+
const g = a ?? l?.title;
|
|
4369
4369
|
if (e !== "automatic" && !(s in e))
|
|
4370
4370
|
continue;
|
|
4371
4371
|
const p = this, f = e !== "automatic" ? (r = e[s]) == null ? void 0 : r.outputSchema : void 0, y = async (m, v) => {
|
|
@@ -4373,23 +4373,23 @@ var jr = class {
|
|
|
4373
4373
|
(b = v?.abortSignal) == null || b.throwIfAborted();
|
|
4374
4374
|
const x = await p.callTool({ name: s, args: m, options: v });
|
|
4375
4375
|
return f != null ? p.extractStructuredContent(x, f, s) : x;
|
|
4376
|
-
}, h = e === "automatic" ?
|
|
4377
|
-
description:
|
|
4376
|
+
}, h = e === "automatic" ? Mr({
|
|
4377
|
+
description: c,
|
|
4378
4378
|
title: g,
|
|
4379
|
-
inputSchema:
|
|
4379
|
+
inputSchema: Q({
|
|
4380
4380
|
...d,
|
|
4381
4381
|
properties: (n = d.properties) != null ? n : {},
|
|
4382
4382
|
additionalProperties: !1
|
|
4383
4383
|
}),
|
|
4384
4384
|
execute: y,
|
|
4385
|
-
toModelOutput:
|
|
4385
|
+
toModelOutput: it
|
|
4386
4386
|
}) : {
|
|
4387
|
-
description:
|
|
4387
|
+
description: c,
|
|
4388
4388
|
title: g,
|
|
4389
4389
|
inputSchema: e[s].inputSchema,
|
|
4390
4390
|
...f != null ? { outputSchema: f } : {},
|
|
4391
4391
|
execute: y,
|
|
4392
|
-
toModelOutput:
|
|
4392
|
+
toModelOutput: it
|
|
4393
4393
|
};
|
|
4394
4394
|
o[s] = { ...h, _meta: u };
|
|
4395
4395
|
}
|
|
@@ -4400,9 +4400,9 @@ var jr = class {
|
|
|
4400
4400
|
*/
|
|
4401
4401
|
async extractStructuredContent(t, e, r) {
|
|
4402
4402
|
if ("structuredContent" in t && t.structuredContent != null) {
|
|
4403
|
-
const n = await
|
|
4403
|
+
const n = await vt({
|
|
4404
4404
|
value: t.structuredContent,
|
|
4405
|
-
schema:
|
|
4405
|
+
schema: wt(e)
|
|
4406
4406
|
});
|
|
4407
4407
|
if (!n.success)
|
|
4408
4408
|
throw new C({
|
|
@@ -4414,7 +4414,7 @@ var jr = class {
|
|
|
4414
4414
|
if ("content" in t && Array.isArray(t.content)) {
|
|
4415
4415
|
const n = t.content.find((o) => o.type === "text");
|
|
4416
4416
|
if (n && "text" in n) {
|
|
4417
|
-
const o = await
|
|
4417
|
+
const o = await Tr({
|
|
4418
4418
|
text: n.text,
|
|
4419
4419
|
schema: e
|
|
4420
4420
|
});
|
|
@@ -4461,7 +4461,7 @@ var jr = class {
|
|
|
4461
4461
|
return this.getPromptInternal({ name: t, args: e, options: r });
|
|
4462
4462
|
}
|
|
4463
4463
|
onElicitationRequest(t, e) {
|
|
4464
|
-
if (t !==
|
|
4464
|
+
if (t !== rt)
|
|
4465
4465
|
throw new C({
|
|
4466
4466
|
message: "Unsupported request schema. Only ElicitationRequestSchema is supported."
|
|
4467
4467
|
});
|
|
@@ -4491,7 +4491,7 @@ var jr = class {
|
|
|
4491
4491
|
});
|
|
4492
4492
|
return;
|
|
4493
4493
|
}
|
|
4494
|
-
const e =
|
|
4494
|
+
const e = rt.safeParse({
|
|
4495
4495
|
method: t.method,
|
|
4496
4496
|
params: t.params
|
|
4497
4497
|
});
|
|
@@ -4508,7 +4508,7 @@ var jr = class {
|
|
|
4508
4508
|
return;
|
|
4509
4509
|
}
|
|
4510
4510
|
try {
|
|
4511
|
-
const r = await this.elicitationRequestHandler(e.data), n =
|
|
4511
|
+
const r = await this.elicitationRequestHandler(e.data), n = r0.parse(r);
|
|
4512
4512
|
await this.transport.send({
|
|
4513
4513
|
jsonrpc: "2.0",
|
|
4514
4514
|
id: t.id,
|
|
@@ -4559,15 +4559,15 @@ var jr = class {
|
|
|
4559
4559
|
);
|
|
4560
4560
|
}
|
|
4561
4561
|
};
|
|
4562
|
-
const
|
|
4562
|
+
const z0 = async (t) => {
|
|
4563
4563
|
const e = {};
|
|
4564
4564
|
try {
|
|
4565
4565
|
const r = await t.listTools();
|
|
4566
4566
|
for (const { name: n, description: o, inputSchema: s } of r.tools) {
|
|
4567
|
-
const a = async (
|
|
4568
|
-
e[n] =
|
|
4567
|
+
const a = async (c, d) => t.callTool({ name: n, arguments: c }, { signal: d?.abortSignal });
|
|
4568
|
+
e[n] = i2({
|
|
4569
4569
|
description: o,
|
|
4570
|
-
inputSchema:
|
|
4570
|
+
inputSchema: a2({
|
|
4571
4571
|
...s,
|
|
4572
4572
|
properties: s.properties ?? {},
|
|
4573
4573
|
additionalProperties: !1
|
|
@@ -4580,7 +4580,7 @@ const Zr = async (t) => {
|
|
|
4580
4580
|
throw r;
|
|
4581
4581
|
}
|
|
4582
4582
|
};
|
|
4583
|
-
function
|
|
4583
|
+
function q0(t) {
|
|
4584
4584
|
const e = Object.entries(t);
|
|
4585
4585
|
if (e.length === 0)
|
|
4586
4586
|
return "";
|
|
@@ -4592,11 +4592,11 @@ function qr(t) {
|
|
|
4592
4592
|
<tools>
|
|
4593
4593
|
`;
|
|
4594
4594
|
return e.forEach(([n, o]) => {
|
|
4595
|
-
const s = o, a = s.description || "无描述",
|
|
4595
|
+
const s = o, a = s.description || "无描述", c = s.parameters || s.inputSchema || {};
|
|
4596
4596
|
r += `${JSON.stringify({
|
|
4597
4597
|
name: n,
|
|
4598
4598
|
description: a,
|
|
4599
|
-
parameters:
|
|
4599
|
+
parameters: c
|
|
4600
4600
|
}, null, 2)}
|
|
4601
4601
|
`;
|
|
4602
4602
|
}), r += `
|
|
@@ -4630,7 +4630,7 @@ Thought: 用户想要获取今天的日期,我需要调用日期相关的工
|
|
|
4630
4630
|
- 如果不需要调用工具,直接给出最终答案即可
|
|
4631
4631
|
`, r;
|
|
4632
4632
|
}
|
|
4633
|
-
function
|
|
4633
|
+
function at(t, e) {
|
|
4634
4634
|
if (!t || typeof t != "string")
|
|
4635
4635
|
return null;
|
|
4636
4636
|
const r = t.match(/<tool_call>([\s\S]*?)<\/tool_call>/i);
|
|
@@ -4643,11 +4643,11 @@ function st(t, e) {
|
|
|
4643
4643
|
}
|
|
4644
4644
|
return null;
|
|
4645
4645
|
}
|
|
4646
|
-
const
|
|
4647
|
-
openai:
|
|
4648
|
-
deepseek:
|
|
4646
|
+
const D0 = {
|
|
4647
|
+
openai: u2,
|
|
4648
|
+
deepseek: p2
|
|
4649
4649
|
};
|
|
4650
|
-
class
|
|
4650
|
+
class Zn {
|
|
4651
4651
|
constructor({ llmConfig: e, mcpServers: r }) {
|
|
4652
4652
|
if (this.mcpServers = {}, this.mcpClients = {}, this.mcpTools = {}, this.ignoreToolnames = [], this.responseMessages = [], this.useReActMode = !1, !e)
|
|
4653
4653
|
throw new Error("llmConfig is required to initialize AgentModelProvider");
|
|
@@ -4656,7 +4656,7 @@ class Nn {
|
|
|
4656
4656
|
else if (e.providerType) {
|
|
4657
4657
|
const n = e.providerType;
|
|
4658
4658
|
let o;
|
|
4659
|
-
typeof n == "string" ? o =
|
|
4659
|
+
typeof n == "string" ? o = D0[n] : o = n, this.llm = o({
|
|
4660
4660
|
apiKey: e.apiKey,
|
|
4661
4661
|
baseURL: e.baseURL
|
|
4662
4662
|
});
|
|
@@ -4668,11 +4668,11 @@ class Nn {
|
|
|
4668
4668
|
async _createOneClient(e) {
|
|
4669
4669
|
try {
|
|
4670
4670
|
let r;
|
|
4671
|
-
if ("type" in e && e.type.toLocaleLowerCase() === "streamablehttp" ? r = new
|
|
4672
|
-
const o = await
|
|
4671
|
+
if ("type" in e && e.type.toLocaleLowerCase() === "streamablehttp" ? r = new he(new URL(e.url)) : "type" in e && e.type === "extension" ? r = new f2(e.sessionId) : "transport" in e ? r = e.transport : r = e, e.useAISdkClient ?? !1) {
|
|
4672
|
+
const o = await j0({ transport: r });
|
|
4673
4673
|
return o.__transport__ = r, o;
|
|
4674
4674
|
} else {
|
|
4675
|
-
const o = new
|
|
4675
|
+
const o = new h2(
|
|
4676
4676
|
{ name: "mcp-web-client", version: "1.0.0" },
|
|
4677
4677
|
{ capabilities: { roots: { listChanged: !0 }, sampling: {}, elicitation: {} } }
|
|
4678
4678
|
);
|
|
@@ -4686,7 +4686,7 @@ class Nn {
|
|
|
4686
4686
|
async _closeOneClient(e) {
|
|
4687
4687
|
try {
|
|
4688
4688
|
const r = e.__transport__;
|
|
4689
|
-
if (r && r instanceof
|
|
4689
|
+
if (r && r instanceof Bt || r && r instanceof Ft)
|
|
4690
4690
|
return;
|
|
4691
4691
|
await r?.terminateSession?.(), await r?.close?.(), await e?.close?.();
|
|
4692
4692
|
} catch {
|
|
@@ -4709,7 +4709,7 @@ class Nn {
|
|
|
4709
4709
|
if (!e)
|
|
4710
4710
|
return null;
|
|
4711
4711
|
try {
|
|
4712
|
-
return typeof e.tools == "function" ? await e.tools() : await
|
|
4712
|
+
return typeof e.tools == "function" ? await e.tools() : await z0(e);
|
|
4713
4713
|
} catch (n) {
|
|
4714
4714
|
return this.onError && this.onError(n?.message || `Failed to query tools for ${r}`, n), console.error(`Failed to query tools for ${r}`, n), null;
|
|
4715
4715
|
}
|
|
@@ -4790,7 +4790,7 @@ class Nn {
|
|
|
4790
4790
|
}
|
|
4791
4791
|
/** 生成 ReAct 模式的系统提示词(包含工具描述) */
|
|
4792
4792
|
_generateReActSystemPrompt(e, r, n) {
|
|
4793
|
-
const o =
|
|
4793
|
+
const o = q0(e);
|
|
4794
4794
|
return n ? `${n}${o}` : `你是一个智能助手,可以通过调用工具来完成任务。
|
|
4795
4795
|
${o}`;
|
|
4796
4796
|
}
|
|
@@ -4814,10 +4814,10 @@ ${o}`;
|
|
|
4814
4814
|
const s = this._tempMergeTools(o.tools);
|
|
4815
4815
|
if (Object.keys(s).length === 0)
|
|
4816
4816
|
return this._chat(e, { model: r, maxSteps: n, ...o });
|
|
4817
|
-
let
|
|
4818
|
-
o.message && !o.messages ?
|
|
4819
|
-
const d = typeof r == "string" ? r : r?.modelId || "default-model", u = { role: "system", content: this._generateReActSystemPrompt(s, d, o.system) }, g =
|
|
4820
|
-
return e ===
|
|
4817
|
+
let c = [];
|
|
4818
|
+
o.message && !o.messages ? c.push({ role: "user", content: o.message }) : o.messages ? c = [...o.messages] : c = [...this.responseMessages];
|
|
4819
|
+
const d = typeof r == "string" ? r : r?.modelId || "default-model", u = { role: "system", content: this._generateReActSystemPrompt(s, d, o.system) }, g = c[0]?.role === "system" ? c : [u, ...c];
|
|
4820
|
+
return e === ge ? this._chatReActStream(g, s, d, n, o) : this._chatReActNonStream(g, s, d, n, o);
|
|
4821
4821
|
}
|
|
4822
4822
|
/**
|
|
4823
4823
|
* 检查消息内容是否包含图片
|
|
@@ -4857,8 +4857,8 @@ ${o}`;
|
|
|
4857
4857
|
e && o.push(e);
|
|
4858
4858
|
let s = 0;
|
|
4859
4859
|
const a = [];
|
|
4860
|
-
for (let
|
|
4861
|
-
const d = r[
|
|
4860
|
+
for (let c = r.length - 1; c >= 0; c--) {
|
|
4861
|
+
const d = r[c];
|
|
4862
4862
|
if (this._messageHasImage(d.content))
|
|
4863
4863
|
if (s < n)
|
|
4864
4864
|
a.unshift(d), s++;
|
|
@@ -4874,19 +4874,19 @@ ${o}`;
|
|
|
4874
4874
|
/** ReAct 模式非流式对话 */
|
|
4875
4875
|
async _chatReActNonStream(e, r, n, o, s) {
|
|
4876
4876
|
let a = [...e];
|
|
4877
|
-
const
|
|
4878
|
-
let
|
|
4877
|
+
const c = e[0]?.role === "system" ? e[0] : null, d = c ? e.slice(1) : e;
|
|
4878
|
+
let l = 0;
|
|
4879
4879
|
const u = s.maxImages ?? 3;
|
|
4880
|
-
for (;
|
|
4881
|
-
|
|
4882
|
-
const p = this._buildMessagesForModel(
|
|
4880
|
+
for (; l < o; ) {
|
|
4881
|
+
l++;
|
|
4882
|
+
const p = this._buildMessagesForModel(c, d, u), { tools: f, ...y } = s, m = (await Fe({
|
|
4883
4883
|
// @ts-ignore ProviderV2 是所有llm的父类,在每一个具体的llm类都有一个选择model的函数用法
|
|
4884
4884
|
model: this.llm(n),
|
|
4885
4885
|
messages: p,
|
|
4886
4886
|
...y
|
|
4887
4887
|
})).text, v = { role: "assistant", content: m };
|
|
4888
4888
|
d.push(v), a.push(v);
|
|
4889
|
-
const b =
|
|
4889
|
+
const b = at(m, r);
|
|
4890
4890
|
if (!b)
|
|
4891
4891
|
return this.responseMessages = a, {
|
|
4892
4892
|
text: m,
|
|
@@ -4907,10 +4907,10 @@ ${x.success ? JSON.stringify(x.result) : `工具执行失败 - ${x.error}`}
|
|
|
4907
4907
|
}
|
|
4908
4908
|
/** ReAct 模式流式对话 */
|
|
4909
4909
|
_chatReActStream(e, r, n, o, s) {
|
|
4910
|
-
const a = this,
|
|
4911
|
-
let d,
|
|
4910
|
+
const a = this, c = this.llm(n);
|
|
4911
|
+
let d, l;
|
|
4912
4912
|
const u = new Promise((p, f) => {
|
|
4913
|
-
d = p,
|
|
4913
|
+
d = p, l = f;
|
|
4914
4914
|
});
|
|
4915
4915
|
return {
|
|
4916
4916
|
fullStream: new ReadableStream({
|
|
@@ -4925,9 +4925,9 @@ ${x.success ? JSON.stringify(x.result) : `工具执行失败 - ${x.error}`}
|
|
|
4925
4925
|
m++;
|
|
4926
4926
|
const x = a._buildMessagesForModel(y, h, b), { tools: M, ...P } = s;
|
|
4927
4927
|
delete P.system, delete P.onFinish;
|
|
4928
|
-
const E = await
|
|
4928
|
+
const E = await ge({
|
|
4929
4929
|
...P,
|
|
4930
|
-
model:
|
|
4930
|
+
model: c,
|
|
4931
4931
|
messages: x
|
|
4932
4932
|
});
|
|
4933
4933
|
let R = "";
|
|
@@ -4937,9 +4937,9 @@ ${x.success ? JSON.stringify(x.result) : `工具执行失败 - ${x.error}`}
|
|
|
4937
4937
|
text: L.text
|
|
4938
4938
|
})) : L.type === "text-start" ? p.enqueue({ type: "text-start" }) : L.type === "text-end" || L.type === "finish-step" || L.type === "finish" || L.type === "start" || L.type === "start-step" || p.enqueue(L);
|
|
4939
4939
|
v += R;
|
|
4940
|
-
const
|
|
4941
|
-
h.push(
|
|
4942
|
-
const I =
|
|
4940
|
+
const q = { role: "assistant", content: v };
|
|
4941
|
+
h.push(q), f.push(q);
|
|
4942
|
+
const I = at(v, r);
|
|
4943
4943
|
if (!I) {
|
|
4944
4944
|
p.enqueue({ type: "text-end" }), p.enqueue({ type: "finish-step" }), p.enqueue({ type: "finish" }), p.close(), a.responseMessages = f, d({ messages: f });
|
|
4945
4945
|
return;
|
|
@@ -4969,11 +4969,11 @@ ${x.success ? JSON.stringify(x.result) : `工具执行失败 - ${x.error}`}
|
|
|
4969
4969
|
input: I.arguments
|
|
4970
4970
|
});
|
|
4971
4971
|
const A = await a._executeReActToolCall(I.toolName, I.arguments, r);
|
|
4972
|
-
let
|
|
4972
|
+
let te, Z = A.result;
|
|
4973
4973
|
if (A.success && A.result && typeof A.result == "object" && A.result.screenshot) {
|
|
4974
|
-
|
|
4975
|
-
const { screenshot: L, ...
|
|
4976
|
-
Z =
|
|
4974
|
+
te = A.result.screenshot;
|
|
4975
|
+
const { screenshot: L, ...re } = A.result;
|
|
4976
|
+
Z = re;
|
|
4977
4977
|
}
|
|
4978
4978
|
let W = "";
|
|
4979
4979
|
if (A.success) {
|
|
@@ -4981,23 +4981,23 @@ ${x.success ? JSON.stringify(x.result) : `工具执行失败 - ${x.error}`}
|
|
|
4981
4981
|
let L = `<tool_response>
|
|
4982
4982
|
${W}
|
|
4983
4983
|
</tool_response>`;
|
|
4984
|
-
|
|
4984
|
+
te && (L += `
|
|
4985
4985
|
请检查截图以确认操作是否成功。如果成功,请继续下一步;如果失败,请重试。`), p.enqueue({
|
|
4986
4986
|
type: "tool-result",
|
|
4987
4987
|
toolCallId: j,
|
|
4988
4988
|
result: L
|
|
4989
4989
|
});
|
|
4990
|
-
const
|
|
4990
|
+
const re = te ? {
|
|
4991
4991
|
role: "user",
|
|
4992
4992
|
content: [
|
|
4993
4993
|
{ type: "text", text: L },
|
|
4994
|
-
{ type: "image", image:
|
|
4994
|
+
{ type: "image", image: te }
|
|
4995
4995
|
]
|
|
4996
4996
|
} : {
|
|
4997
4997
|
role: "user",
|
|
4998
4998
|
content: L
|
|
4999
4999
|
};
|
|
5000
|
-
h.push(
|
|
5000
|
+
h.push(re), f.push(re), v = "";
|
|
5001
5001
|
} else
|
|
5002
5002
|
W = `工具执行失败 - ${A.error}`, p.enqueue({
|
|
5003
5003
|
type: "tool-error",
|
|
@@ -5008,7 +5008,7 @@ ${W}
|
|
|
5008
5008
|
}
|
|
5009
5009
|
p.enqueue({ type: "text-end" }), p.enqueue({ type: "finish-step" }), p.enqueue({ type: "finish" }), p.close(), a.responseMessages = f, d({ messages: f });
|
|
5010
5010
|
} catch (x) {
|
|
5011
|
-
p.error(x),
|
|
5011
|
+
p.error(x), l(x);
|
|
5012
5012
|
}
|
|
5013
5013
|
}
|
|
5014
5014
|
}),
|
|
@@ -5024,41 +5024,41 @@ ${W}
|
|
|
5024
5024
|
const s = this._tempMergeTools(o.tools, !1), a = {
|
|
5025
5025
|
// @ts-ignore ProviderV2 是所有llm的父类, 在每一个具体的llm 类都有一个选择model的函数用法
|
|
5026
5026
|
model: this.llm(r),
|
|
5027
|
-
stopWhen:
|
|
5027
|
+
stopWhen: c2(n),
|
|
5028
5028
|
...o,
|
|
5029
5029
|
tools: s,
|
|
5030
5030
|
activeTools: this._getActiveToolNames(s)
|
|
5031
5031
|
};
|
|
5032
|
-
let
|
|
5032
|
+
let c = null;
|
|
5033
5033
|
if (o.message && !o.messages)
|
|
5034
|
-
|
|
5034
|
+
c = { role: "user", content: o.message }, this.responseMessages.push(c), a.messages = [...this.responseMessages];
|
|
5035
5035
|
else if (o.messages && o.messages.length > 0) {
|
|
5036
|
-
const
|
|
5037
|
-
|
|
5036
|
+
const l = o.messages[o.messages.length - 1];
|
|
5037
|
+
l.role === "user" && (c = l);
|
|
5038
5038
|
}
|
|
5039
5039
|
const d = e(a);
|
|
5040
|
-
return d?.response?.then((
|
|
5041
|
-
const u =
|
|
5042
|
-
|
|
5040
|
+
return d?.response?.then((l) => {
|
|
5041
|
+
const u = l.messages?.[0];
|
|
5042
|
+
c && u?.role !== "user" && this.responseMessages.push(c), this.responseMessages.push(...l.messages);
|
|
5043
5043
|
}), d;
|
|
5044
5044
|
}
|
|
5045
5045
|
async chat(e) {
|
|
5046
|
-
return this._chat(
|
|
5046
|
+
return this._chat(Fe, e);
|
|
5047
5047
|
}
|
|
5048
5048
|
async chatStream(e) {
|
|
5049
|
-
return this._chat(
|
|
5049
|
+
return this._chat(ge, e);
|
|
5050
5050
|
}
|
|
5051
5051
|
}
|
|
5052
|
-
let U = null,
|
|
5053
|
-
const
|
|
5054
|
-
function
|
|
5052
|
+
let U = null, ue = null, ct = null, ne = 0;
|
|
5053
|
+
const H0 = "next-sdk-tool-body-glow";
|
|
5054
|
+
function ee() {
|
|
5055
5055
|
return typeof window < "u" && typeof document < "u";
|
|
5056
5056
|
}
|
|
5057
|
-
function
|
|
5058
|
-
if (!
|
|
5057
|
+
function F0() {
|
|
5058
|
+
if (!ee() || ct) return;
|
|
5059
5059
|
const t = document.createElement("style");
|
|
5060
5060
|
t.textContent = `
|
|
5061
|
-
.${
|
|
5061
|
+
.${H0} {
|
|
5062
5062
|
position: relative;
|
|
5063
5063
|
}
|
|
5064
5064
|
|
|
@@ -5225,11 +5225,11 @@ function Hr() {
|
|
|
5225
5225
|
transform: scale(1) translateY(0);
|
|
5226
5226
|
}
|
|
5227
5227
|
}
|
|
5228
|
-
`, document.head.appendChild(t),
|
|
5228
|
+
`, document.head.appendChild(t), ct = t;
|
|
5229
5229
|
}
|
|
5230
|
-
function
|
|
5231
|
-
if (!
|
|
5232
|
-
|
|
5230
|
+
function B0() {
|
|
5231
|
+
if (!ee() || U) return;
|
|
5232
|
+
F0();
|
|
5233
5233
|
const t = document.createElement("div");
|
|
5234
5234
|
t.className = "next-sdk-tool-overlay";
|
|
5235
5235
|
const e = document.createElement("div");
|
|
@@ -5244,61 +5244,61 @@ function Fr() {
|
|
|
5244
5244
|
s.className = "next-sdk-tool-overlay__indicator-core";
|
|
5245
5245
|
const a = document.createElement("div");
|
|
5246
5246
|
a.className = "next-sdk-tool-overlay__content";
|
|
5247
|
-
const
|
|
5248
|
-
|
|
5247
|
+
const c = document.createElement("div");
|
|
5248
|
+
c.className = "next-sdk-tool-overlay__title", c.textContent = "AI 正在调用页面工具";
|
|
5249
5249
|
const d = document.createElement("span");
|
|
5250
5250
|
d.className = "next-sdk-tool-overlay__title-dot";
|
|
5251
|
-
const
|
|
5252
|
-
|
|
5251
|
+
const l = document.createElement("div");
|
|
5252
|
+
l.className = "next-sdk-tool-overlay__label", c.prepend(d), a.appendChild(c), a.appendChild(l), n.appendChild(o), n.appendChild(s), r.appendChild(n), r.appendChild(a), t.appendChild(e), t.appendChild(r), document.body.appendChild(t), U = t, ue = l;
|
|
5253
5253
|
}
|
|
5254
|
-
function
|
|
5255
|
-
|
|
5254
|
+
function V0(t) {
|
|
5255
|
+
ee() && (B0(), !(!U || !ue) && (U.classList.remove("next-sdk-tool-overlay--exit"), ue.textContent = t.label));
|
|
5256
5256
|
}
|
|
5257
|
-
function
|
|
5257
|
+
function J0() {
|
|
5258
5258
|
if (!U) return;
|
|
5259
5259
|
U.classList.add("next-sdk-tool-overlay--exit");
|
|
5260
5260
|
const t = U;
|
|
5261
5261
|
let e = !1, r;
|
|
5262
5262
|
const n = () => {
|
|
5263
|
-
e || (e = !0, r !== void 0 && (clearTimeout(r), r = void 0), t.parentNode && t.parentNode.removeChild(t), U === t && (U = null,
|
|
5263
|
+
e || (e = !0, r !== void 0 && (clearTimeout(r), r = void 0), t.parentNode && t.parentNode.removeChild(t), U === t && (U = null, ue = null), t.removeEventListener("animationend", n));
|
|
5264
5264
|
};
|
|
5265
5265
|
t.addEventListener("animationend", n), r = setTimeout(n, 500);
|
|
5266
5266
|
}
|
|
5267
|
-
function
|
|
5268
|
-
|
|
5267
|
+
function W0(t) {
|
|
5268
|
+
ee() && (ne += 1, V0(t));
|
|
5269
5269
|
}
|
|
5270
|
-
function
|
|
5271
|
-
!
|
|
5270
|
+
function G0() {
|
|
5271
|
+
!ee() || ne <= 0 || (ne -= 1, ne === 0 && J0());
|
|
5272
5272
|
}
|
|
5273
|
-
function
|
|
5273
|
+
function K0(t, e, r) {
|
|
5274
5274
|
if (!r) return;
|
|
5275
5275
|
const n = e || t;
|
|
5276
5276
|
return typeof r == "boolean" ? r ? { label: n } : void 0 : {
|
|
5277
5277
|
label: r.label || n
|
|
5278
5278
|
};
|
|
5279
5279
|
}
|
|
5280
|
-
const
|
|
5281
|
-
function
|
|
5282
|
-
typeof window < "u" &&
|
|
5280
|
+
const $t = "next-sdk:tool-call", Te = "next-sdk:tool-response", Ze = "next-sdk:page-ready", Y0 = "next-sdk:page-leave", Q0 = "next-sdk:remoter-ready", X0 = "next-sdk:route-state-initial", F = /* @__PURE__ */ new Map(), pe = (t) => t.replace(/\/+$/, "") || "/", ze = /* @__PURE__ */ new Set();
|
|
5281
|
+
function en() {
|
|
5282
|
+
typeof window < "u" && ze.add({ win: window, origin: window.location.origin || "*" });
|
|
5283
5283
|
}
|
|
5284
|
-
|
|
5285
|
-
function
|
|
5284
|
+
en();
|
|
5285
|
+
function lt(t, e) {
|
|
5286
5286
|
const r = { type: t, route: e };
|
|
5287
|
-
|
|
5287
|
+
ze.forEach(({ win: n, origin: o }) => {
|
|
5288
5288
|
try {
|
|
5289
5289
|
n.postMessage(r, o);
|
|
5290
5290
|
} catch {
|
|
5291
5291
|
}
|
|
5292
5292
|
});
|
|
5293
5293
|
}
|
|
5294
|
-
function
|
|
5294
|
+
function tn() {
|
|
5295
5295
|
typeof window > "u" || window.addEventListener("message", (t) => {
|
|
5296
|
-
if (t.data?.type !==
|
|
5296
|
+
if (t.data?.type !== Q0 || !t.source || t.origin !== window.location.origin) return;
|
|
5297
5297
|
const e = t.source;
|
|
5298
|
-
|
|
5298
|
+
ze.add({ win: e, origin: t.origin || "*" });
|
|
5299
5299
|
const r = {
|
|
5300
|
-
type:
|
|
5301
|
-
toolRouteMap: Array.from(
|
|
5300
|
+
type: X0,
|
|
5301
|
+
toolRouteMap: Array.from(qe.entries()),
|
|
5302
5302
|
activeRoutes: Array.from(F.keys())
|
|
5303
5303
|
};
|
|
5304
5304
|
try {
|
|
@@ -5307,35 +5307,98 @@ function en() {
|
|
|
5307
5307
|
}
|
|
5308
5308
|
});
|
|
5309
5309
|
}
|
|
5310
|
-
|
|
5311
|
-
const
|
|
5312
|
-
function
|
|
5313
|
-
return new Map(
|
|
5310
|
+
tn();
|
|
5311
|
+
const qe = /* @__PURE__ */ new Map();
|
|
5312
|
+
function zn() {
|
|
5313
|
+
return new Map(qe);
|
|
5314
5314
|
}
|
|
5315
|
-
function
|
|
5315
|
+
function qn() {
|
|
5316
5316
|
return new Set(F.keys());
|
|
5317
5317
|
}
|
|
5318
|
-
let
|
|
5319
|
-
function
|
|
5320
|
-
|
|
5318
|
+
let Y = null;
|
|
5319
|
+
function Dn(t) {
|
|
5320
|
+
Y = t;
|
|
5321
|
+
}
|
|
5322
|
+
function rn(t, e = 1500) {
|
|
5323
|
+
if (typeof window > "u")
|
|
5324
|
+
return Promise.resolve();
|
|
5325
|
+
const r = pe(t);
|
|
5326
|
+
return new Promise((n) => {
|
|
5327
|
+
let o = !1;
|
|
5328
|
+
const s = () => {
|
|
5329
|
+
o || (o = !0, window.removeEventListener("message", a), n());
|
|
5330
|
+
}, a = (c) => {
|
|
5331
|
+
if (c.source !== window || c.data?.type !== Ze) return;
|
|
5332
|
+
pe(String(c.data.route ?? "")) === r && s();
|
|
5333
|
+
};
|
|
5334
|
+
window.addEventListener("message", a), setTimeout(s, e);
|
|
5335
|
+
});
|
|
5336
|
+
}
|
|
5337
|
+
function Hn(t, e) {
|
|
5338
|
+
const r = e?.name ?? "navigate_to_page", n = e?.title ?? "页面跳转", o = e?.description ?? '当需要的工具在当前页面不可用时,使用此工具跳转到特定页面。例如:要查询订单时跳转到 "/orders",要创建价保时跳转到 "/price-protection"。', s = e?.timeoutMs ?? 1500;
|
|
5339
|
+
return t.registerTool(
|
|
5340
|
+
r,
|
|
5341
|
+
{
|
|
5342
|
+
title: n,
|
|
5343
|
+
description: o,
|
|
5344
|
+
inputSchema: {
|
|
5345
|
+
path: G.string().describe('目标页面的路由地址,例如 "/orders"、"/inventory"、"/price-protection" 等。')
|
|
5346
|
+
}
|
|
5347
|
+
},
|
|
5348
|
+
async ({ path: a }) => {
|
|
5349
|
+
if (typeof window > "u")
|
|
5350
|
+
return {
|
|
5351
|
+
content: [{ type: "text", text: "当前环境不支持页面跳转(window 不存在)。" }]
|
|
5352
|
+
};
|
|
5353
|
+
if (!Y)
|
|
5354
|
+
return {
|
|
5355
|
+
content: [
|
|
5356
|
+
{
|
|
5357
|
+
type: "text",
|
|
5358
|
+
text: "页面跳转失败:尚未在应用入口调用 setNavigator 注册导航函数,无法执行路由跳转。"
|
|
5359
|
+
}
|
|
5360
|
+
]
|
|
5361
|
+
};
|
|
5362
|
+
try {
|
|
5363
|
+
const c = pe(a), d = pe(window.location.pathname);
|
|
5364
|
+
if (d === c || d.endsWith(c) && (d.length === c.length || d[d.lastIndexOf(c) - 1] === "/"))
|
|
5365
|
+
return {
|
|
5366
|
+
content: [{ type: "text", text: `当前已在页面:${a}。请继续你的下一步操作。` }]
|
|
5367
|
+
};
|
|
5368
|
+
const u = rn(a, s);
|
|
5369
|
+
return await Y(a), await u, {
|
|
5370
|
+
content: [{ type: "text", text: `已成功跳转至页面:${a}。请继续你的下一步操作。` }]
|
|
5371
|
+
};
|
|
5372
|
+
} catch (c) {
|
|
5373
|
+
return {
|
|
5374
|
+
content: [
|
|
5375
|
+
{
|
|
5376
|
+
type: "text",
|
|
5377
|
+
text: `页面跳转失败:${c instanceof Error ? c.message : String(c)}。`
|
|
5378
|
+
}
|
|
5379
|
+
]
|
|
5380
|
+
};
|
|
5381
|
+
}
|
|
5382
|
+
}
|
|
5383
|
+
);
|
|
5321
5384
|
}
|
|
5322
|
-
function
|
|
5385
|
+
function nn(t, e, r = 3e4, n) {
|
|
5323
5386
|
return (o) => {
|
|
5324
|
-
const s =
|
|
5325
|
-
return new Promise((a,
|
|
5326
|
-
let d,
|
|
5387
|
+
const s = Ae();
|
|
5388
|
+
return new Promise((a, c) => {
|
|
5389
|
+
let d, l;
|
|
5327
5390
|
const u = () => {
|
|
5328
|
-
clearTimeout(d), window.removeEventListener("message", g),
|
|
5391
|
+
clearTimeout(d), window.removeEventListener("message", g), l && window.removeEventListener("message", l), n && G0();
|
|
5329
5392
|
};
|
|
5330
5393
|
d = setTimeout(() => {
|
|
5331
|
-
u(),
|
|
5394
|
+
u(), c(new Error(`工具 [${t}] 调用超时 (${r}ms),请检查目标页面是否正确调用了 registerPageTool`));
|
|
5332
5395
|
}, r);
|
|
5333
5396
|
const g = (m) => {
|
|
5334
|
-
m.source === window && m.data?.type ===
|
|
5397
|
+
m.source === window && m.data?.type === Te && m.data.callId === s && (u(), m.data.error ? c(new Error(m.data.error)) : a(m.data.result));
|
|
5335
5398
|
};
|
|
5336
5399
|
window.addEventListener("message", g);
|
|
5337
5400
|
const p = () => {
|
|
5338
|
-
window.postMessage({ type:
|
|
5401
|
+
window.postMessage({ type: $t, callId: s, toolName: t, route: e, input: o }, window.location.origin || "*");
|
|
5339
5402
|
};
|
|
5340
5403
|
let f = !1;
|
|
5341
5404
|
const y = () => {
|
|
@@ -5343,61 +5406,61 @@ function tn(t, e, r = 3e4, n) {
|
|
|
5343
5406
|
};
|
|
5344
5407
|
(async () => {
|
|
5345
5408
|
try {
|
|
5346
|
-
if (n &&
|
|
5409
|
+
if (n && W0(n), F.get(e)) {
|
|
5347
5410
|
y();
|
|
5348
5411
|
return;
|
|
5349
5412
|
}
|
|
5350
|
-
|
|
5351
|
-
m.source === window && m.data?.type ===
|
|
5352
|
-
}, window.addEventListener("message",
|
|
5413
|
+
l = (m) => {
|
|
5414
|
+
m.source === window && m.data?.type === Ze && m.data.route === e && (window.removeEventListener("message", l), y());
|
|
5415
|
+
}, window.addEventListener("message", l), Y && await Y(e), F.get(e) && (window.removeEventListener("message", l), y());
|
|
5353
5416
|
} catch (m) {
|
|
5354
|
-
u(),
|
|
5417
|
+
u(), c(m instanceof Error ? m : new Error(String(m)));
|
|
5355
5418
|
}
|
|
5356
5419
|
})();
|
|
5357
5420
|
});
|
|
5358
5421
|
};
|
|
5359
5422
|
}
|
|
5360
|
-
function
|
|
5423
|
+
function Fn(t) {
|
|
5361
5424
|
return new Proxy(t, {
|
|
5362
5425
|
get(e, r, n) {
|
|
5363
5426
|
return r === "registerTool" ? (o, s, a) => {
|
|
5364
|
-
const
|
|
5427
|
+
const c = e.registerTool.bind(e);
|
|
5365
5428
|
if (typeof a == "function")
|
|
5366
|
-
return
|
|
5367
|
-
const { route: d, timeout:
|
|
5368
|
-
|
|
5369
|
-
const g =
|
|
5370
|
-
return
|
|
5429
|
+
return c(o, s, a);
|
|
5430
|
+
const { route: d, timeout: l, invokeEffect: u } = a;
|
|
5431
|
+
qe.set(o, d);
|
|
5432
|
+
const g = K0(o, s?.title, u);
|
|
5433
|
+
return c(o, s, nn(o, d, l, g));
|
|
5371
5434
|
} : Reflect.get(e, r, n);
|
|
5372
5435
|
}
|
|
5373
5436
|
});
|
|
5374
5437
|
}
|
|
5375
|
-
function
|
|
5438
|
+
function Bn(t) {
|
|
5376
5439
|
const { route: e, handlers: r } = t, n = (a) => a.replace(/\/+$/, "") || "/", o = n(e ?? window.location.pathname), s = async (a) => {
|
|
5377
|
-
if (a.source !== window || a.data?.type !==
|
|
5440
|
+
if (a.source !== window || a.data?.type !== $t || n(String(a.data?.route ?? "")) !== o || !(a.data.toolName in r))
|
|
5378
5441
|
return;
|
|
5379
|
-
const { callId:
|
|
5442
|
+
const { callId: c, toolName: d, input: l } = a.data;
|
|
5380
5443
|
try {
|
|
5381
|
-
const u = await r[d](
|
|
5382
|
-
window.postMessage({ type:
|
|
5444
|
+
const u = await r[d](l);
|
|
5445
|
+
window.postMessage({ type: Te, callId: c, result: u }, window.location.origin || "*");
|
|
5383
5446
|
} catch (u) {
|
|
5384
5447
|
window.postMessage(
|
|
5385
5448
|
{
|
|
5386
|
-
type:
|
|
5387
|
-
callId:
|
|
5449
|
+
type: Te,
|
|
5450
|
+
callId: c,
|
|
5388
5451
|
error: u instanceof Error ? u.message : String(u)
|
|
5389
5452
|
},
|
|
5390
5453
|
window.location.origin || "*"
|
|
5391
5454
|
);
|
|
5392
5455
|
}
|
|
5393
5456
|
};
|
|
5394
|
-
return F.set(o, !0), window.addEventListener("message", s),
|
|
5395
|
-
F.delete(o), window.removeEventListener("message", s),
|
|
5457
|
+
return F.set(o, !0), window.addEventListener("message", s), lt(Ze, o), () => {
|
|
5458
|
+
F.delete(o), window.removeEventListener("message", s), lt(Y0, o);
|
|
5396
5459
|
};
|
|
5397
5460
|
}
|
|
5398
|
-
const
|
|
5399
|
-
function
|
|
5400
|
-
const e = t.match(
|
|
5461
|
+
const Ut = /^\.\/[^/]+\/SKILL\.md$/, on = /^---\s*\n([\s\S]+?)\s*\n---/;
|
|
5462
|
+
function Nt(t) {
|
|
5463
|
+
const e = t.match(on);
|
|
5401
5464
|
if (!e?.[1]) return null;
|
|
5402
5465
|
const r = e[1], n = r.match(/^name:\s*(.+)$/m), o = r.match(/^description:\s*(.+)$/m), s = n?.[1]?.trim(), a = o?.[1]?.trim();
|
|
5403
5466
|
return s && a ? { name: s, description: a } : null;
|
|
@@ -5405,21 +5468,21 @@ function Ut(t) {
|
|
|
5405
5468
|
function V(t) {
|
|
5406
5469
|
const e = {};
|
|
5407
5470
|
for (const [r, n] of Object.entries(t)) {
|
|
5408
|
-
const o = r.replace(/\\/g, "/"), s = o.lastIndexOf("skills/"), a = s >= 0 ? o.slice(s + 7) : o,
|
|
5409
|
-
e[
|
|
5471
|
+
const o = r.replace(/\\/g, "/"), s = o.lastIndexOf("skills/"), a = s >= 0 ? o.slice(s + 7) : o, c = a.startsWith("./") ? a : `./${a}`;
|
|
5472
|
+
e[c] = n;
|
|
5410
5473
|
}
|
|
5411
5474
|
return e;
|
|
5412
5475
|
}
|
|
5413
|
-
function
|
|
5476
|
+
function sn(t) {
|
|
5414
5477
|
const e = V(t);
|
|
5415
|
-
return Object.keys(e).filter((r) =>
|
|
5478
|
+
return Object.keys(e).filter((r) => Ut.test(r));
|
|
5416
5479
|
}
|
|
5417
|
-
function
|
|
5418
|
-
const e = V(t), r = Object.keys(e).filter((o) =>
|
|
5480
|
+
function Vn(t) {
|
|
5481
|
+
const e = V(t), r = Object.keys(e).filter((o) => Ut.test(o)), n = [];
|
|
5419
5482
|
for (const o of r) {
|
|
5420
5483
|
const s = e[o];
|
|
5421
5484
|
if (!s) continue;
|
|
5422
|
-
const a =
|
|
5485
|
+
const a = Nt(s);
|
|
5423
5486
|
a && n.push({
|
|
5424
5487
|
name: a.name,
|
|
5425
5488
|
description: a.description,
|
|
@@ -5428,7 +5491,7 @@ function Hn(t) {
|
|
|
5428
5491
|
}
|
|
5429
5492
|
return n;
|
|
5430
5493
|
}
|
|
5431
|
-
function
|
|
5494
|
+
function Jn(t) {
|
|
5432
5495
|
return t.length === 0 ? "" : `## 可用技能
|
|
5433
5496
|
|
|
5434
5497
|
${t.map((r) => `- **${r.name}**: ${r.description}`).join(`
|
|
@@ -5436,122 +5499,123 @@ ${t.map((r) => `- **${r.name}**: ${r.description}`).join(`
|
|
|
5436
5499
|
|
|
5437
5500
|
当需要用到某技能时,请使用 get_skill_content 工具获取该技能的完整文档内容。`;
|
|
5438
5501
|
}
|
|
5439
|
-
function
|
|
5502
|
+
function Wn(t) {
|
|
5440
5503
|
const e = V(t);
|
|
5441
5504
|
return Object.keys(e);
|
|
5442
5505
|
}
|
|
5443
|
-
function
|
|
5506
|
+
function _e(t, e) {
|
|
5444
5507
|
const r = V(t), n = r[e];
|
|
5445
5508
|
if (n) return n;
|
|
5446
5509
|
const o = e.replace(/^\.?\//, "/"), s = Object.keys(r).find((a) => a.endsWith(o));
|
|
5447
5510
|
return s ? r[s] : void 0;
|
|
5448
5511
|
}
|
|
5449
|
-
function
|
|
5450
|
-
const r = V(t), n =
|
|
5512
|
+
function an(t, e) {
|
|
5513
|
+
const r = V(t), n = sn(r), o = n.find((s) => s.startsWith(`./${e}/SKILL.md`));
|
|
5451
5514
|
if (o) return o;
|
|
5452
5515
|
for (const s of n) {
|
|
5453
5516
|
const a = r[s];
|
|
5454
5517
|
if (a) {
|
|
5455
|
-
const
|
|
5456
|
-
if (
|
|
5518
|
+
const c = Nt(a);
|
|
5519
|
+
if (c && c.name === e)
|
|
5457
5520
|
return s;
|
|
5458
5521
|
}
|
|
5459
5522
|
}
|
|
5460
5523
|
}
|
|
5461
|
-
const
|
|
5462
|
-
skillName:
|
|
5524
|
+
const cn = G.object({
|
|
5525
|
+
skillName: G.string().optional().describe(
|
|
5463
5526
|
'进入某个技能的主入口名称。优先匹配技能的目录名(如 ecommerce),或者技能的中文名称(如"客户价保单创建及审核")。'
|
|
5464
5527
|
),
|
|
5465
|
-
path:
|
|
5466
|
-
currentPath:
|
|
5528
|
+
path: G.string().optional().describe("你想查阅的文档的路径。如 ./calculator/SKILL.md 或从其他文档里看到的相对路径 ./reference/inventory.md。"),
|
|
5529
|
+
currentPath: G.string().optional().describe(
|
|
5467
5530
|
"你当前正在阅读的文档路径(如果有)。比如你刚刚读取了 ./ecommerce/SKILL.md,请把这个路径原样传回来,这样系统才能根据你的相对路径准确找到下一份文件。"
|
|
5468
5531
|
)
|
|
5469
5532
|
});
|
|
5470
|
-
function
|
|
5533
|
+
function Gn(t) {
|
|
5471
5534
|
const e = V(t);
|
|
5472
5535
|
return {
|
|
5473
|
-
get_skill_content:
|
|
5536
|
+
get_skill_content: l2({
|
|
5474
5537
|
description: "根据技能名称或文档路径获取该技能的完整文档内容。如果你想根据相对路径查阅文件,请务必同时提供你当前所在的文件路径 currentPath。",
|
|
5475
|
-
inputSchema:
|
|
5538
|
+
inputSchema: cn,
|
|
5476
5539
|
execute: (n) => {
|
|
5477
5540
|
const { skillName: o, path: s, currentPath: a } = n;
|
|
5478
|
-
let
|
|
5541
|
+
let c, d = "";
|
|
5479
5542
|
if (s) {
|
|
5480
|
-
let
|
|
5543
|
+
let l = ".";
|
|
5481
5544
|
if (a) {
|
|
5482
5545
|
const p = a.lastIndexOf("/");
|
|
5483
|
-
p >= 0 && (
|
|
5546
|
+
p >= 0 && (l = a.slice(0, p));
|
|
5484
5547
|
}
|
|
5485
|
-
const u = `http://localhost/${
|
|
5486
|
-
if (d = "." + new URL(s, u).pathname,
|
|
5548
|
+
const u = `http://localhost/${l}/`;
|
|
5549
|
+
if (d = "." + new URL(s, u).pathname, c = _e(e, d), c === void 0 && (s.startsWith("./") || s.startsWith("../")) && a) {
|
|
5487
5550
|
const p = a.split("/");
|
|
5488
5551
|
if (p.length >= 2) {
|
|
5489
5552
|
const y = `http://localhost/${p[1]}/`, m = "." + new URL(s, y).pathname;
|
|
5490
|
-
|
|
5553
|
+
c = _e(e, m), c && (d = m);
|
|
5491
5554
|
}
|
|
5492
5555
|
}
|
|
5493
|
-
if (
|
|
5556
|
+
if (c && !e[d]) {
|
|
5494
5557
|
const p = d.replace(/^\.?\//, "/"), f = Object.keys(e).find((y) => y.endsWith(p));
|
|
5495
5558
|
f && (d = f);
|
|
5496
5559
|
}
|
|
5497
5560
|
} else if (o) {
|
|
5498
|
-
const
|
|
5499
|
-
|
|
5561
|
+
const l = an(e, o);
|
|
5562
|
+
l && (d = l, c = _e(e, l));
|
|
5500
5563
|
}
|
|
5501
|
-
return
|
|
5564
|
+
return c === void 0 ? {
|
|
5502
5565
|
error: "未找到对应技能文档",
|
|
5503
5566
|
skillName: o,
|
|
5504
5567
|
path: s,
|
|
5505
5568
|
providedCurrentPath: a,
|
|
5506
5569
|
attemptedPath: d
|
|
5507
|
-
} : { content:
|
|
5570
|
+
} : { content: c, path: d };
|
|
5508
5571
|
}
|
|
5509
5572
|
})
|
|
5510
5573
|
};
|
|
5511
5574
|
}
|
|
5512
5575
|
export {
|
|
5513
|
-
|
|
5514
|
-
|
|
5515
|
-
|
|
5516
|
-
|
|
5517
|
-
|
|
5518
|
-
|
|
5519
|
-
|
|
5520
|
-
|
|
5521
|
-
|
|
5522
|
-
|
|
5523
|
-
|
|
5524
|
-
|
|
5525
|
-
|
|
5526
|
-
|
|
5527
|
-
|
|
5528
|
-
|
|
5529
|
-
|
|
5530
|
-
|
|
5531
|
-
|
|
5532
|
-
|
|
5533
|
-
|
|
5534
|
-
|
|
5535
|
-
|
|
5536
|
-
|
|
5537
|
-
|
|
5538
|
-
|
|
5539
|
-
|
|
5540
|
-
|
|
5541
|
-
|
|
5542
|
-
|
|
5543
|
-
|
|
5544
|
-
|
|
5545
|
-
|
|
5546
|
-
|
|
5547
|
-
|
|
5548
|
-
|
|
5549
|
-
|
|
5550
|
-
|
|
5551
|
-
|
|
5552
|
-
|
|
5553
|
-
|
|
5554
|
-
|
|
5555
|
-
|
|
5556
|
-
|
|
5576
|
+
Zn as AgentModelProvider,
|
|
5577
|
+
Qn as Ajv,
|
|
5578
|
+
ro as AuthClientProvider,
|
|
5579
|
+
Nn as ContentScriptServerTransport,
|
|
5580
|
+
f2 as ExtensionClientTransport,
|
|
5581
|
+
Un as ExtensionPageServerTransport,
|
|
5582
|
+
ho as InMemoryTransport,
|
|
5583
|
+
Y0 as MSG_PAGE_LEAVE,
|
|
5584
|
+
Q0 as MSG_REMOTER_READY,
|
|
5585
|
+
X0 as MSG_ROUTE_STATE_INITIAL,
|
|
5586
|
+
g2 as QrCode,
|
|
5587
|
+
oo as ResourceTemplate,
|
|
5588
|
+
io as UriTemplate,
|
|
5589
|
+
h2 as WebMcpClient,
|
|
5590
|
+
kn as WebMcpServer,
|
|
5591
|
+
co as completable,
|
|
5592
|
+
In as createMessageChannelClientTransport,
|
|
5593
|
+
Pn as createMessageChannelPairTransport,
|
|
5594
|
+
Sn as createMessageChannelServerTransport,
|
|
5595
|
+
jn as createRemoter,
|
|
5596
|
+
En as createSSEClientTransport,
|
|
5597
|
+
Gn as createSkillTools,
|
|
5598
|
+
Rn as createStreamableHTTPClientTransport,
|
|
5599
|
+
Jn as formatSkillsForSystemPrompt,
|
|
5600
|
+
z0 as getAISDKTools,
|
|
5601
|
+
qn as getActiveRoutes,
|
|
5602
|
+
uo as getDisplayName,
|
|
5603
|
+
an as getMainSkillPathByName,
|
|
5604
|
+
sn as getMainSkillPaths,
|
|
5605
|
+
_e as getSkillMdContent,
|
|
5606
|
+
Wn as getSkillMdPaths,
|
|
5607
|
+
Vn as getSkillOverviews,
|
|
5608
|
+
zn as getToolRouteMap,
|
|
5609
|
+
$n as isMcpClient,
|
|
5610
|
+
Mn as isMcpServer,
|
|
5611
|
+
On as isMessageChannelClientTransport,
|
|
5612
|
+
Tn as isMessageChannelServerTransport,
|
|
5613
|
+
An as isSSEClientTransport,
|
|
5614
|
+
m2 as isStreamableHTTPClientTransport,
|
|
5615
|
+
Nt as parseSkillFrontMatter,
|
|
5616
|
+
Hn as registerNavigateTool,
|
|
5617
|
+
Bn as registerPageTool,
|
|
5618
|
+
Dn as setNavigator,
|
|
5619
|
+
Fn as withPageTools,
|
|
5620
|
+
eo as z
|
|
5557
5621
|
};
|