diff --git a/penpot-plugin/index.html b/penpot-plugin/index.html
index 436652b..9abb1db 100644
--- a/penpot-plugin/index.html
+++ b/penpot-plugin/index.html
@@ -8,8 +8,6 @@
Penpot MCP Plugin
-
-
Not connected
diff --git a/penpot-plugin/src/main.ts b/penpot-plugin/src/main.ts
index 8345ed1..b48d849 100644
--- a/penpot-plugin/src/main.ts
+++ b/penpot-plugin/src/main.ts
@@ -77,12 +77,6 @@ function connectToMcpServer(): void {
}
}
-// Event handlers
-document.querySelector("[data-handler='create-text']")?.addEventListener("click", () => {
- // send message to plugin.ts
- parent.postMessage("create-text", "*");
-});
-
document.querySelector("[data-handler='connect-mcp']")?.addEventListener("click", () => {
connectToMcpServer();
});
diff --git a/penpot-plugin/src/plugin.ts b/penpot-plugin/src/plugin.ts
index 086f6f4..e91270c 100644
--- a/penpot-plugin/src/plugin.ts
+++ b/penpot-plugin/src/plugin.ts
@@ -11,22 +11,6 @@ penpot.ui.open("Penpot MCP Plugin", `?theme=${penpot.theme}`);
// Handle both legacy string messages and new request-based messages
penpot.ui.onMessage((message) => {
- // Legacy string-based message handling
- if (typeof message === "string") {
- if (message === "create-text") {
- const text = penpot.createText("Hello world!");
-
- if (text) {
- text.x = penpot.viewport.center.x;
- text.y = penpot.viewport.center.y;
-
- penpot.selection = [text];
- }
- }
- return;
- }
-
- // New request-based message handling
if (typeof message === "object" && message.task && message.id) {
handlePluginTaskRequest(message).catch((error) => {
console.error("Error in handlePluginTaskRequest:", error);