/*! bespoke-secondary v1.0.1 © 2021 Joel Purra, MIT License */ !function(e){if("object"==typeof exports&&"undefined"!=typeof module)module.exports=e();else if("function"==typeof define&&define.amd)define([],e);else{var n;"undefined"!=typeof window?n=window:"undefined"!=typeof global?n=global:"undefined"!=typeof self&&(n=self);var t=n;t=t.bespoke||(t.bespoke={}),t=t.plugins||(t.plugins={}),t.secondary=e()}}(function(){return function e(n,t,i){function o(r,c){if(!t[r]){if(!n[r]){var d="function"==typeof require&&require;if(!c&&d)return d(r,!0);if(s)return s(r,!0);throw new Error("Cannot find module '"+r+"'")}var u=t[r]={exports:{}};n[r][0].call(u.exports,function(e){var t=n[r][1][e];return o(t?t:e)},u,u.exports,e,n,t,i)}return t[r].exports}for(var s="function"==typeof require&&require,r=0;rNotes
"},f=function(e){var n=function(n){var t=s.activateDeck(n),i={},r={getNotesElement:function(){return this.secondary.window&&this.secondary.window.document&&this.secondary.window.document.getElementById("notes")},isOpen:function(){var e=this.secondary,n=e.window,t=!(void 0===e||null===n||n.closed===!0||n.opener!==window||null===this.secondary.getNotesElement());return t},open:function(){return this.secondary.isOpen()||(this.secondary.window=window.open(),a(this.secondary.window.document)),this.secondary.isOpen()},close:function(){return this.secondary.isOpen()&&this.secondary.window.close(),!this.secondary.isOpen()},focus:function(){return this.secondary.isOpen()&&this.secondary.window.focus(),this.secondary.isOpen()},toggle:function(){return this.secondary.isOpen()?this.secondary.close():this.secondary.open(),this.secondary.isOpen()},synchronize:function(){var n,t,i,s;return this.secondary.isOpen()?(n=this.secondary.getNotesElement(),t=this.getActiveSlide(),i=o.copyArray(t.querySelectorAll(e.notes)),s=i.reduce(function(e,n){return e+n.outerHTML},""),n.innerHTML=s,this.secondary.isOpen()):!1}},d=function(){n.secondary={window:null,secondaryWindowName:l(),getNotesElement:r.getNotesElement.bind(n),isOpen:r.isOpen.bind(n),open:r.open.bind(n),close:r.close.bind(n),focus:r.focus.bind(n),toggle:r.toggle.bind(n),synchronize:r.synchronize.bind(n)}},u=function(){var n={};e=e||{},n.keys={},n.keys.toggle=e.keys&&e.keys.toggle||c.keys.toggle,n.notes=e.notes||c.notes,e=n},f=function(i){var o=!1;return i.altKey||i.ctrlKey||i.metaKey||i.shiftKey||(o=o||i.which===e.keys.toggle&&t.fire("toggle",i)&&n.secondary.toggle()&&n.secondary.synchronize()),o&&i.preventDefault(),!o},p=function(){return n.secondary.close(),null},y=function(){n.secondary.synchronize()},g=function(){window.onbeforeunload=p,document.addEventListener("keydown",f,!1),i.activate=n.on("activate",y)},v=function(){u(),d(),g()};v()};return n};n.exports=f},{"bespoke-indexfinger":2}],2:[function(e,n){"use strict";var t="indexfinger",i=function(e){return e("return this")()}(Function),o=i.bespoke&&i.bespoke.plugins&&i.bespoke.plugins.convenient||e("bespoke-convenient"),s=o.builder(t),r=function(){var e=function(e){var n=(s.activateDeck(e),{}),t=null,i=-1,o={enableActiveSlideListener:function(){n.saveActiveSlide=this.on("activate",o.saveActiveSlide.bind(this))},saveActiveSlide:function(e){t=e.slide,i=e.index},getActiveSlide:function(){return t},getActiveSlideIndex:function(){return i}},r=function(){e.getActiveSlide=o.getActiveSlide.bind(e),e.getActiveSlideIndex=o.getActiveSlideIndex.bind(e)},c=function(){o.enableActiveSlideListener.call(e)},d=function(){r(),c()};d()};return e};n.exports=r},{}]},{},[1])(1)});