From 170fae16daa8fea9aa4a7150bc83a55bd2bacbbc Mon Sep 17 00:00:00 2001 From: Nathan Coad Date: Mon, 12 Jan 2026 16:20:59 +1100 Subject: [PATCH] try --- cmd/server/main.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/cmd/server/main.go b/cmd/server/main.go index a4500a6..eaf8ba9 100644 --- a/cmd/server/main.go +++ b/cmd/server/main.go @@ -340,8 +340,8 @@ func buildDiagramsNetURL(r *http.Request, id string, xml string) string { } base := fmt.Sprintf("%s://%s/diagram?id=%s", scheme, r.Host, url.QueryEscape(id)) encoded := url.QueryEscape(base) - // Ask draw.io not to proxy (`proxy=0`) so it fetches directly (CORS headers are already set on /diagram). - return fmt.Sprintf("%s/?splash=0&ui=min&libs=aws4&proxy=0&url=%s", drawioBaseURL, encoded) + // Supply both url= and #U so either proxy or direct loaders work across hosted/self-hosted variants. + return fmt.Sprintf("%s/?splash=0&ui=min&libs=aws4&url=%s#U%s", drawioBaseURL, encoded, base) } func addCORS(w http.ResponseWriter) {