sublime-mcp 1.13.3 → 1.13.4

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.
@@ -4749,7 +4749,7 @@
4749
4749
  },
4750
4750
  {
4751
4751
  "name": "ui_screenshot",
4752
- "description": "Take a picture of one window of this Sublime Text process (Windows only). The PNG is saved to a file and its path is returned (open it with the Read tool); inline=true returns the image itself. Works for a window that is behind others or not focused, and for dialogs. hwnd comes from list_native_windows (default: the first editor window). Only windows of Sublime Text itself can be captured, never another program.",
4752
+ "description": "Take a picture of one window of this Sublime Text process (Windows only). Returns the image itself as an image block (also through batch); inline=false saves a PNG file instead and returns its path. Works for a window that is behind others or not focused, and for dialogs. hwnd comes from list_native_windows (default: the first editor window). Only windows of Sublime Text itself can be captured, never another program.",
4753
4753
  "inputSchema": {
4754
4754
  "type": "object",
4755
4755
  "properties": {
@@ -4759,7 +4759,7 @@
4759
4759
  },
4760
4760
  "inline": {
4761
4761
  "type": "boolean",
4762
- "description": "Return the image itself instead of a file path (default false)."
4762
+ "description": "Return the image itself (default true); false saves a file and returns its path."
4763
4763
  },
4764
4764
  "settle_ms": {
4765
4765
  "type": "integer",
package/index.js CHANGED
@@ -46,6 +46,12 @@ const GATEWAY_FALLBACKS = [
46
46
  process.stderr.write(`mcp-commander: BASE=${BASE} platform=${process.platform}\n`);
47
47
 
48
48
  function ok(data) {
49
+ // The backend returns a list of MCP content blocks (images from ui_screenshot, also through
50
+ // batch): pass them on as they are instead of wrapping them as JSON text.
51
+ if (Array.isArray(data) && data.length && data.every(
52
+ (b) => b && (b.type === 'image' || b.type === 'text'))) {
53
+ return { content: data };
54
+ }
49
55
  return { content: [{ type: 'text', text: JSON.stringify(data) }] };
50
56
  }
51
57
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "sublime-mcp",
3
- "version": "1.13.3",
3
+ "version": "1.13.4",
4
4
  "description": "MCP server for Sublime Text 4 — exposes editor state and editing tools to AI assistants via the Model Context Protocol.",
5
5
  "type": "module",
6
6
  "bin": {