@vitemcp/server 1.9.11 → 1.9.12

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.
@@ -1,12 +1,12 @@
1
1
  "use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { newObj[key] = obj[key]; } } } newObj.default = obj; return newObj; } } function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } function _nullishCoalesce(lhs, rhsFn) { if (lhs != null) { return lhs; } else { return rhsFn(); } } function _optionalChain(ops) { let lastAccessLHS = undefined; let value = ops[0]; let i = 1; while (i < ops.length) { const op = ops[i]; const fn = ops[i + 1]; i += 2; if ((op === 'optionalAccess' || op === 'optionalCall') && value == null) { return undefined; } if (op === 'access' || op === 'optionalAccess') { lastAccessLHS = value; value = fn(value); } else if (op === 'call' || op === 'optionalCall') { value = fn((...args) => value.call(lastAccessLHS, ...args)); lastAccessLHS = undefined; } } return value; }
2
2
 
3
- var _chunkXGRRYN5Ycjs = require('./chunk-XGRRYN5Y.cjs');
3
+ var _chunk2X4JCSQQcjs = require('./chunk-2X4JCSQQ.cjs');
4
4
 
5
5
 
6
6
 
7
7
 
8
8
 
9
- var _chunkDURXYPPRcjs = require('./chunk-DURXYPPR.cjs');
9
+ var _chunkQPVEGWOLcjs = require('./chunk-QPVEGWOL.cjs');
10
10
 
11
11
  // src/ViteMCP.ts
12
12
 
@@ -1357,7 +1357,7 @@ var ViteMCP = class {
1357
1357
  res.end(
1358
1358
  JSON.stringify({
1359
1359
  error: "invalid_request",
1360
- error_description: `Request body exceeds ${_chunkDURXYPPRcjs.formatBytes.call(void 0, maxBodySize)}`
1360
+ error_description: `Request body exceeds ${_chunkQPVEGWOLcjs.formatBytes.call(void 0, maxBodySize)}`
1361
1361
  })
1362
1362
  );
1363
1363
  return;
@@ -1432,7 +1432,7 @@ var ViteMCP = class {
1432
1432
  */
1433
1433
  async #toSdkSchema(schema, label, io) {
1434
1434
  try {
1435
- return await _chunkDURXYPPRcjs.toSdkSchema.call(void 0, schema, io, convertToJsonSchema);
1435
+ return await _chunkQPVEGWOLcjs.toSdkSchema.call(void 0, schema, io, convertToJsonSchema);
1436
1436
  } catch (error) {
1437
1437
  throw new UnexpectedStateError(
1438
1438
  `${label} is not a supported Standard Schema: ${error instanceof Error ? error.message : String(error)}`,
@@ -1473,7 +1473,7 @@ var withEndpointAsResource = (config, endpoint) => ({
1473
1473
  ...config,
1474
1474
  protectedResource: {
1475
1475
  ...config.protectedResource,
1476
- resource: `${_chunkXGRRYN5Ycjs.withoutTrailingSlash.call(void 0, config.protectedResource.resource)}${endpoint}`
1476
+ resource: `${_chunk2X4JCSQQcjs.withoutTrailingSlash.call(void 0, config.protectedResource.resource)}${endpoint}`
1477
1477
  }
1478
1478
  });
1479
1479
  var nodeToWebRequest = (req, body, secure, signal) => {
@@ -1569,7 +1569,7 @@ var readCappedNodeBody = async (req, maxBytes) => {
1569
1569
  }
1570
1570
  return Buffer.concat(chunks);
1571
1571
  };
1572
- var convertToJsonSchema = async (schema, io) => schema["~standard"].vendor === "valibot" ? _chunkDURXYPPRcjs.valibotToJsonSchema.call(void 0, schema, io) : _xsschema.toJsonSchema.call(void 0, schema);
1572
+ var convertToJsonSchema = async (schema, io) => schema["~standard"].vendor === "valibot" ? _chunkQPVEGWOLcjs.valibotToJsonSchema.call(void 0, schema, io) : _xsschema.toJsonSchema.call(void 0, schema);
1573
1573
  var assertStandardSchema = (schema, toolName, field) => {
1574
1574
  if (schema === void 0) {
1575
1575
  return;
@@ -1619,7 +1619,7 @@ var promptArgsSchema = (prompt) => {
1619
1619
  ) : described;
1620
1620
  shape[arg.name] = arg.required ? base : base.optional();
1621
1621
  }
1622
- return _chunkDURXYPPRcjs.ownKeysOnly.call(void 0, _zod.z.object(shape));
1622
+ return _chunkQPVEGWOLcjs.ownKeysOnly.call(void 0, _zod.z.object(shape));
1623
1623
  };
1624
1624
  var isStructuredResult = (value) => {
1625
1625
  if (!Object.hasOwn(value, "structuredContent") || value.structuredContent === void 0) {
@@ -1688,4 +1688,4 @@ var normalizeToolResult = (result, hasOutputSchema) => {
1688
1688
 
1689
1689
 
1690
1690
  exports.cancelResponseBody = cancelResponseBody; exports.DiscoveryDocumentCache = DiscoveryDocumentCache; exports.jsonSchemaAdapter = jsonSchemaAdapter; exports.delay = _promises5.setTimeout; exports.MEDIA_FETCH_TIMEOUT_MS = MEDIA_FETCH_TIMEOUT_MS; exports.ViteMCPError = ViteMCPError; exports.UnexpectedStateError = UnexpectedStateError; exports.UserError = UserError; exports.imageContent = imageContent; exports.audioContent = audioContent; exports.ServerState = ServerState; exports.ViteMCP = ViteMCP;
1691
- //# sourceMappingURL=chunk-C2VT2NXC.cjs.map
1691
+ //# sourceMappingURL=chunk-7T5D57AM.cjs.map