--- /dev/null
+<!doctype html>
+<html lang="en">
+<head>
+ <meta charset="UTF-8">
+ <meta name="viewport"
+ content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0">
+ <meta http-equiv="X-UA-Compatible" content="ie=edge">
+ <title>Embed Test</title>
+ <style>
+ html, body {
+ height: 100%;
+ }
+ body {
+ margin: 0;
+ padding: 1em;
+ }
+ </style>
+</head>
+<body>
+<b>Embed Test</b>
+<button onclick="document.getElementById('iframe').contentWindow.fluidbook.links.triggerLinkById('survey')">Open Popup</button>
+<br><br>
+<iframe id="iframe" width="100%" height="90%" frameborder="0" marginheight="0" marginwidth="0" allowfullscreen="true" src="index.html"></iframe>
+<script>
+var iframe=document.getElementById('iframe');
+iframe.addEventListener( "load", function(e) {
+ var $=iframe.contentWindow.$;
+ $(function(){
+ var fluidbook=document.getElementById('iframe').contentWindow.fluidbook;
+ $(fluidbook).on('fluidbook.help.show',function(){alert('help is displayed')});
+ $(fluidbook).on('fluidbook.help.hide',function(){alert('help is hidden')});
+ });
+});
+
+</script>
+</body>
+</html>