html2pptx-local-mcp 1.1.31 → 1.1.32

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.
@@ -443,7 +443,7 @@ export const LOCAL_TOOL_DEFINITIONS = [
443
443
  },
444
444
  openBrowser: {
445
445
  type: 'boolean',
446
- description: 'When true, open the editor in the browser. Defaults to false for MCP calls so agents can return one URL without spawning extra tabs.',
446
+ description: 'Whether to open the editor in the browser. Defaults to true: the tool opens the correct loopback editor URL itself so you never hand-build it. Set false only if your surface renders the returned editorUrl inline. Never open https://html2pptx.app/edit-slide for local files.',
447
447
  },
448
448
  reuseExisting: {
449
449
  type: 'boolean',
@@ -754,23 +754,21 @@ export function extractClientInfo(raw) {
754
754
  * Decide whether html2pptx_open_local_slide_editor should auto-open the OS
755
755
  * default browser when the MCP caller did not explicitly set `openBrowser`.
756
756
  *
757
- * Strategy: conservative allowlist. Only known terminal-style CLI clients
758
- * (Claude Code, Codex CLI, anything whose advertised clientInfo.name ends in
759
- * `-cli`) get the auto-open default. Desktop/IDE clients (Claude Desktop,
760
- * Cursor, Cline, unknown) keep the existing "return URL only, let the host
761
- * render it inline" behavior that's the right default for future MCP
762
- * side-pane UI surfaces.
757
+ * Default to auto-open for every client. Local file editing inherently needs a
758
+ * browser on the user's own machine, and the tool already opens the correct
759
+ * loopback editor URL itself. The previous conservative allowlist left
760
+ * non-CLI clients on a "return URL only" path, where agents tend to hand-build
761
+ * the editor URL and substitute the hosted `https://html2pptx.app/edit-slide`
762
+ * origin -- which can never reach a localhost bridge (mixed-content + CORS) and
763
+ * lands the user on the bridge error page. Auto-opening removes that failure
764
+ * mode. Callers with their own inline render surface can still opt out with an
765
+ * explicit `openBrowser: false`.
763
766
  *
764
767
  * @param {{ name?: string } | null | undefined} clientInfo
765
768
  * @returns {boolean}
766
769
  */
767
770
  export function inferOpenBrowserDefault(clientInfo) {
768
- const rawName = String(clientInfo?.name ?? '').trim().toLowerCase();
769
- if (!rawName) return false;
770
- if (/^claude[\s\-_]?code/.test(rawName)) return true;
771
- if (/^codex(?:[\s\-_]|$)/.test(rawName)) return true;
772
- if (/[\-_]cli$/.test(rawName)) return true;
773
- return false;
771
+ return true;
774
772
  }
775
773
 
776
774
  /**
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "html2pptx-local-mcp",
3
- "version": "1.1.31",
3
+ "version": "1.1.32",
4
4
  "type": "module",
5
5
  "description": "Local stdio MCP server for opening html2pptx slide HTML in the local edit-slide editor.",
6
6
  "bin": {