some changes#12
Open
mhmad-nr wants to merge 6 commits into
Open
Conversation
qant-au
added a commit
to qant-au/axonometra
that referenced
this pull request
Jun 10, 2026
Implements the embedding story the README has been claiming. Hosts can now iframe Axonometra and round-trip plans without baking build-time integration code. - src/embed/embedConfig.ts reads ?embed=1 / ?readonly=1 URL params and VITE_EMBED_ALLOWED_ORIGINS (comma-separated, deny-by-default). - src/embed/EmbedBridge.tsx mounts a message listener gated on the allowlist. Inbound: axo:load (string|object plan, fed through the hardened FloorPlan.load), axo:request-save (replies axo:save with a JSON snapshot to event.source/event.origin), axo:ready? (responds axo:ready). On mount, broadcasts axo:ready to window.parent with targetOrigin '*' so the host can discover us. Cleanup removes the listener. - PageLayout hides the welcome modal when embedded (host loads the plan via postMessage) and the toolbar when readonly=1. - docker/nginx.conf replaces the legacy X-Frame-Options: SAMEORIGIN with Content-Security-Policy frame-ancestors 'self'. Style-src retains 'unsafe-inline' for Mantine + Emotion. connect-src trims to 'self' now that the arcada-backend dependency is gone. - EMBEDDING.md documents the protocol, URL params, origin allowlist, and how to extend frame-ancestors. - README's two embeddability mentions now link to EMBEDDING.md. Also closes action items mehanix#10 (CSP) and mehanix#11 (frame-ancestors). Closes action items mehanix#5, mehanix#10, mehanix#11, #33 (code-review-2026-06-09 mehanix#2, mehanix#12, mehanix#13, #35). Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
add vitejs (it is faster than react-scripts)
add logo to favicon