{"action":"created","issue":{"url":"https://api.github.com/repos/hypothesis/h/issues/2244","labels_url":"https://api.github.com/repos/hypothesis/h/issues/2244/labels{/name}","comments_url":"https://api.github.com/repos/hypothesis/h/issues/2244/comments","events_url":"https://api.github.com/repos/hypothesis/h/issues/2244/events","html_url":"https://github.com/hypothesis/h/issues/2244","id":78117942,"number":2244,"title":"Etherpad and Hypothesis Embed Code (iframe problems)","user":{"login":"JohnMcLear","id":220864,"avatar_url":"https://avatars.githubusercontent.com/u/220864?v=3","gravatar_id":"","url":"https://api.github.com/users/JohnMcLear","html_url":"https://github.com/JohnMcLear","followers_url":"https://api.github.com/users/JohnMcLear/followers","following_url":"https://api.github.com/users/JohnMcLear/following{/other_user}","gists_url":"https://api.github.com/users/JohnMcLear/gists{/gist_id}","starred_url":"https://api.github.com/users/JohnMcLear/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/JohnMcLear/subscriptions","organizations_url":"https://api.github.com/users/JohnMcLear/orgs","repos_url":"https://api.github.com/users/JohnMcLear/repos","events_url":"https://api.github.com/users/JohnMcLear/events{/privacy}","received_events_url":"https://api.github.com/users/JohnMcLear/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":6,"created_at":"2015-05-19T14:44:05Z","updated_at":"2015-05-20T02:29:03Z","closed_at":null,"body":"I thought I already made an issue for this but I can't find it, I'm going to create another issue here just to document the problem.\r\n\r\nThe TLDR; is the controls for Hypoteh.is need to be injected into the page with the content and this causes the contents to be written into the pad itself.\r\n\r\nThe problem: We use iframes to embed pad contents into a page in Etherpad, while this is somewhat hacky it's the current status quo.  \r\n\r\nThe \"fix\" would to allow the javascript to inject the controls into a target item which in my case would be ``parent.body``..  A syntax might be..\r\n\r\n```\r\n<script async defer src=\"//hypothes.is/embedTarget.js\"></script>\r\n<script>\r\nhypothesis.controlsAppendTarget(\"parent.body\");\r\n</script>\r\n```\r\n\r\nThe above targeting would only modify the \"append\" parts of the hypothesis embed client. All range selection / selection events would still be triggered on the iframe where the pad is loaded.\r\n\r\nThe \"real\" fix here and there is no hiding from this is that we need to not use iframes in Etherpad so if that's your answer I'm totally fine with that too.\r\n"},"comment":{"url":"https://api.github.com/repos/hypothesis/h/issues/comments/103730249","html_url":"https://github.com/hypothesis/h/issues/2244#issuecomment-103730249","issue_url":"https://api.github.com/repos/hypothesis/h/issues/2244","id":103730249,"user":{"login":"tilgovi","id":20818,"avatar_url":"https://avatars.githubusercontent.com/u/20818?v=3","gravatar_id":"","url":"https://api.github.com/users/tilgovi","html_url":"https://github.com/tilgovi","followers_url":"https://api.github.com/users/tilgovi/followers","following_url":"https://api.github.com/users/tilgovi/following{/other_user}","gists_url":"https://api.github.com/users/tilgovi/gists{/gist_id}","starred_url":"https://api.github.com/users/tilgovi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tilgovi/subscriptions","organizations_url":"https://api.github.com/users/tilgovi/orgs","repos_url":"https://api.github.com/users/tilgovi/repos","events_url":"https://api.github.com/users/tilgovi/events{/privacy}","received_events_url":"https://api.github.com/users/tilgovi/received_events","type":"User","site_admin":false},"created_at":"2015-05-20T02:29:03Z","updated_at":"2015-05-20T02:29:03Z","body":"An option for the container to inject into would be great for these simple same-domain scenarios."}}