mirror of
https://github.com/penpot/penpot.git
synced 2026-05-11 11:03:52 +00:00
🐛 Fix MCP integrations copy button to match displayed URL (#9239)
This commit is contained in:
parent
9b336e9a3d
commit
9c771ae6b9
@ -1,6 +1,5 @@
|
||||
# CHANGELOG
|
||||
|
||||
|
||||
## 2.15.0 (Unreleased)
|
||||
|
||||
### :sparkles: New features & Enhancements
|
||||
@ -11,6 +10,7 @@
|
||||
|
||||
### :bug: Bugs fixed
|
||||
|
||||
- Fix MCP integrations URL copy action to match the URL displayed in settings [Github #9238](https://github.com/penpot/penpot/issues/9238)
|
||||
- Fix Plugin API token methods rejecting JS array of strings [Github #9162](https://github.com/penpot/penpot/issues/9162)
|
||||
- Harden Nginx responses with standard security headers and hide upstream `X-Powered-By` headers
|
||||
- Fix keep-alive interval leak in PluginBridge (by @opcode81) [Github #9435](https://github.com/penpot/penpot/pull/9435)
|
||||
|
||||
@ -410,6 +410,8 @@
|
||||
profile (mf/deref refs/profile)
|
||||
|
||||
mcp-key (some #(when (= (:type %) "mcp") %) tokens)
|
||||
mcp-token (:token mcp-key "")
|
||||
mcp-url (dm/str cf/mcp-server-url "?userToken=" mcp-token)
|
||||
mcp-enabled? (true? (-> profile :props :mcp-enabled))
|
||||
|
||||
expires-at (:expires-at mcp-key)
|
||||
@ -457,9 +459,10 @@
|
||||
|
||||
on-copy-to-clipboard
|
||||
(mf/use-fn
|
||||
(mf/deps mcp-url)
|
||||
(fn [event]
|
||||
(dom/prevent-default event)
|
||||
(clipboard/to-clipboard cf/mcp-server-url)
|
||||
(clipboard/to-clipboard mcp-url)
|
||||
(st/emit! (ntf/show {:level :info
|
||||
:type :toast
|
||||
:content (tr "integrations.notification.success.copied-link")
|
||||
@ -550,7 +553,7 @@
|
||||
:class (stl/css :color-secondary)}
|
||||
(tr "integrations.mcp-server.mcp-keys.info")]
|
||||
|
||||
[:> input-copy* {:value (dm/str cf/mcp-server-url "?userToken=")
|
||||
[:> input-copy* {:value mcp-url
|
||||
:on-copy-to-clipboard on-copy-to-clipboard}]
|
||||
|
||||
[:> text* {:as "div"
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user