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iEAER,GACF,QAAQ,IAAI,4BACZ,QAAQ,IAAI,IACL,GAEF,EAAW,EAAM,EAAS,gBAAgB,EAKlD,CAKH","file":"/npm/reveal.js-simplemenu@2.0.3/plugin/simplemenu/simplemenu.js","sourceRoot":"","sourcesContent":["/**\n * Minified by jsDelivr using Terser v5.37.0.\n * Original file: /npm/reveal.js-simplemenu@2.0.3/plugin/simplemenu/simplemenu.js\n *\n * Do NOT use SRI with dynamically generated files! More information: https://www.jsdelivr.com/using-sri-with-dynamic-files\n */\n","\n/*****************************************************************\n * @author: Martijn De Jongh (Martino), martijn.de.jongh@gmail.com\n * https://github.com/Martinomagnifico\n *\n * Simplemenu.js for Reveal.js \n * Version 2.0.3\n * \n * @license \n * MIT licensed\n *\n * Thanks to:\n *  - Hakim El Hattab, Reveal.js \n ******************************************************************/\n\n\n\n(function (global, factory) {\n\ttypeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :\n\ttypeof define === 'function' && define.amd ? define(factory) :\n\t(global = typeof globalThis !== 'undefined' ? globalThis : global || self, global.Simplemenu = factory());\n})(this, (function () { 'use strict';\n\n\tconst Plugin = () => {\n\t  let options = {};\n\t  const vars = {};\n\t  const sections = {};\n\t  const mainArray = [];\n\t  let autoListItems = [];\n\t  let manualListItems = [];\n\t  const debugLog = text => {\n\t    if (options.debug) console.log(text);\n\t  };\n\t  const isObject = item => {\n\t    return item && typeof item === 'object' && !Array.isArray(item);\n\t  };\n\t  const mergeDeep = function (target) {\n\t    for (var _len = arguments.length, sources = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n\t      sources[_key - 1] = arguments[_key];\n\t    }\n\t    if (!sources.length) return target;\n\t    const source = sources.shift();\n\t    if (isObject(target) && isObject(source)) {\n\t      for (const key in source) {\n\t        if (isObject(source[key])) {\n\t          if (!target[key]) Object.assign(target, {\n\t            [key]: {}\n\t          });\n\t          mergeDeep(target[key], source[key]);\n\t        } else {\n\t          Object.assign(target, {\n\t            [key]: source[key]\n\t          });\n\t        }\n\t      }\n\t    }\n\t    return mergeDeep(target, ...sources);\n\t  };\n\t  const selectionArray = (container, selectors) => {\n\t    let selections = container.querySelectorAll(selectors);\n\t    let selectionarray = Array.prototype.slice.call(selections);\n\t    return selectionarray;\n\t  };\n\t  const pluginPath = filename => {\n\t    let path;\n\t    let pluginScript = document.querySelector(`script[src$=\"${filename}\"]`);\n\t    if (pluginScript) {\n\t      path = pluginScript.getAttribute(\"src\").slice(0, -1 * filename.length);\n\t    } else {\n\t      path = (typeof document === 'undefined' && typeof location === 'undefined' ? new (require('u' + 'rl').URL)('file:' + __filename).href : typeof document === 'undefined' ? location.href : (document.currentScript && document.currentScript.tagName.toUpperCase() === 'SCRIPT' && document.currentScript.src || new URL('simplemenu.js', document.baseURI).href)).slice(0, (typeof document === 'undefined' && typeof location === 'undefined' ? new (require('u' + 'rl').URL)('file:' + __filename).href : typeof document === 'undefined' ? location.href : (document.currentScript && document.currentScript.tagName.toUpperCase() === 'SCRIPT' && document.currentScript.src || new URL('simplemenu.js', document.baseURI).href)).lastIndexOf('/') + 1);\n\t    }\n\t    return path;\n\t  };\n\t  const isBefore = (a, b) => {\n\t    var all = document.getElementsByTagName('*');\n\t    for (var i = 0; i < all.length; ++i) {\n\t      if (all[i] === a) return true;else if (all[i] === b) return false;\n\t    }\n\t  };\n\t  const isStack = section => {\n\t    let isStack = false;\n\t    for (let i = 0; i < section.childNodes.length; i++) {\n\t      if (section.childNodes[i].tagName === \"SECTION\") {\n\t        isStack = true;\n\t        break;\n\t      }\n\t    }\n\t    return isStack;\n\t  };\n\t  const createNode = thehtml => {\n\t    const fragment = document.createRange().createContextualFragment(thehtml);\n\t    return fragment.firstElementChild;\n\t  };\n\t  const loadStyle = (url, type, callback) => {\n\t    let head = document.querySelector('head');\n\t    let style = document.createElement('link');\n\t    style.rel = 'stylesheet';\n\t    style.href = url;\n\t    let finish = () => {\n\t      if (typeof callback === 'function') {\n\t        callback.call();\n\t        callback = null;\n\t      }\n\t    };\n\t    style.onload = finish;\n\t    style.onreadystatechange = function () {\n\t      if (this.readyState === 'loaded') {\n\t        finish();\n\t      }\n\t    };\n\t    head.appendChild(style);\n\t  };\n\t  const checkOccurrence = (array, element) => {\n\t    let counter = 0;\n\t    for (let i = 0; i <= array.length; i++) {\n\t      if (array[i] == element) {\n\t        counter++;\n\t      }\n\t    }\n\t    return counter;\n\t  };\n\t  const menuArray = () => {\n\t    const matchString = vars.matchString;\n\t    let menulist = selectionArray(vars.viewport, `.${options.menuclass}`) ? selectionArray(vars.viewport, `.${options.menuclass}`) : [];\n\t    let automenus = [];\n\t    let manualmenus = [];\n\t    if (menulist.length) {\n\t      menulist.forEach(menu => {\n\t        if (menu.getElementsByTagName('li').length < 1) {\n\t          menu.setAttribute('data-simplemenu-auto', '');\n\t          automenus.push(menu);\n\t        } else {\n\t          if (options.selectby == \"data-name\" || options.selectby == \"name\") {\n\t            let existingListItems = selectionArray(menu, `.${options.menuclass} ${options.activeelement}`);\n\t            existingListItems.forEach(listItem => {\n\t              if (!listItem.dataset[matchString]) {\n\t                let content = listItem.textContent || listItem.querySelector('a').textContent;\n\t                listItem.setAttribute(`data-${matchString}`, content);\n\t              }\n\t            });\n\t          }\n\t          manualmenus.push(menu);\n\t        }\n\t      });\n\t      return {\n\t        automenus: automenus,\n\t        manualmenus: manualmenus\n\t      };\n\t    } else {\n\t      return false;\n\t    }\n\t  };\n\t  const setScale = revealScale => {\n\t    let totalScale = revealScale * vars.userScale;\n\t    vars.viewport.style.setProperty('--simplemenu-scale', totalScale.toFixed(3));\n\t  };\n\t  const moveRevealUI = (curUiEl, newUiEl) => {\n\t    let newUiElClassList = newUiEl.classList;\n\t    newUiEl.parentNode.replaceChild(curUiEl, newUiEl);\n\t    curUiEl.classList = newUiElClassList;\n\t  };\n\t  const getRevealUI = () => {\n\t    let revealUIs = ['controls', 'slide-number'];\n\t    revealUIs.forEach(uielement => {\n\t      let curUiEl = vars.deck.getRevealElement().querySelector(`.reveal > .${uielement}`);\n\t      let newUiEl = vars.deck.getRevealElement().querySelector(`.reveal > * .${uielement}`);\n\t      if (curUiEl && newUiEl) {\n\t        moveRevealUI(curUiEl, newUiEl);\n\t      }\n\t    });\n\t  };\n\t  function copyDataAttributes(source, target) {\n\t    const filteredAttrs = [...source.attributes].filter(attr => attr.nodeName.indexOf('data') > -1);\n\t    for (const attr of filteredAttrs) {\n\t      target.setAttribute(attr.nodeName, attr.nodeValue);\n\t    }\n\t  }\n\t  const prepareSlides = () => {\n\t    debugLog(\"Preparing slides\");\n\t    sections.all = selectionArray(vars.viewport, \"section\");\n\t    sections.all.forEach(section => {\n\t      // In Markdown environments, setting a data-name of a stack is not directly possible. \n\t      // Satting a data-stack-name on the first child solves this.\n\t      if (!section.parentNode.dataset.name && section.dataset && section.dataset.stackName) {\n\t        section.parentNode.dataset.name = section.dataset.stackName;\n\t      }\n\t      // If a section has a data-sm='none', it will also remove the data-name.\n\t      if (section.dataset && section.dataset[vars.matchString] && section.dataset[vars.matchString] == \"false\" && section.dataset.name) {\n\t        delete section.dataset.name;\n\t      }\n\t    });\n\n\t    // Get all of the kinds of sections\n\t    sections.top = sections.all.filter(section => section.parentNode.classList.contains('slides') && !(section.dataset[vars.matchString] && section.dataset[vars.matchString] == \"false\"));\n\t    sections.named = sections.top.filter(section => section.dataset.name || section.getAttribute('name'));\n\t    sections.namedvisible = sections.named.filter(section => section.dataset.visibility != \"hidden\");\n\n\t    // Go through all the named sections\n\t    let namedsectionMatches = [];\n\t    sections.named.forEach(namedsection => {\n\t      // The 'name' attribute is also allowed. \n\t      let matchName = namedsection.dataset.name || namedsection.getAttribute('name');\n\n\t      // Named sections can have the same name, but should then be differentiated.\n\t      namedsectionMatches.push(matchName);\n\t      let dupsBefore = matchName && checkOccurrence(namedsectionMatches, matchName) > 1 ? `-${checkOccurrence(namedsectionMatches, matchName)}` : null;\n\t      let match = dupsBefore ? matchName + dupsBefore : matchName;\n\n\t      // We set the name of the match as a data-attribute\n\t      namedsection.setAttribute(`data-${vars.matchString}`, match);\n\n\t      // If the (named) section is not a stack and does not have an ID, we need to give it one.\n\t      if (!isStack(namedsection) && !namedsection.id) {\n\t        // Note: Quarto will already have assigned an ID, but it may also have been done manually.\n\t        namedsection.id = match.toLowerCase().replace(/\\s+/g, '').replace(/[^\\p{L}\\p{N}-]/gu, '');\n\t      } else if (isStack(namedsection)) {\n\t        // Find the first (visible) section inside a stack.\n\t        let allsects = selectionArray(namedsection, `section`);\n\t        let allVisibleSects = allsects.filter(section => section.dataset.visibility != \"hidden\");\n\t        let firstChildSection = allVisibleSects[0];\n\t        if (firstChildSection && !firstChildSection.id) {\n\t          firstChildSection.id = match.toLowerCase().replace(/\\s+/g, '').replace(/[^\\p{L}\\p{N}-]/gu, '');\n\t          if (namedsection.id == firstChildSection.id) {\n\t            namedsection.removeAttribute('id');\n\t          }\n\t        }\n\t      }\n\t    });\n\t    let currentMatch = null;\n\t    let currentid = null;\n\n\t    // Get all the sections that are actually slides\n\t    sections.regular = sections.all.filter(section => !isStack(section) && section.dataset.visibility != \"hidden\");\n\n\t    // Go through all the sections\n\t    sections.regular.forEach((section, i) => {\n\t      // Filling an array with the needed comparison information\n\n\t      let isChildSection = isStack(section.parentNode) && section.parentNode.tagName == \"SECTION\";\n\t      let theSection = isChildSection ? section.parentNode : section;\n\t      let dataname = theSection.dataset.name;\n\t      let name = theSection.getAttribute(`name`);\n\t      let dataintl = theSection.getAttribute(vars.langattribute) ? theSection.getAttribute(vars.langattribute) : null;\n\t      let parentid = section.parentNode.id ? section.parentNode.id : null;\n\t      let id = section.id ? section.id : isChildSection ? parentid : null;\n\t      let match = theSection.dataset[vars.matchString];\n\t      if (match) {\n\t        currentMatch = match;\n\t      }\n\t      if (id || match == \"false\") {\n\t        currentid = i;\n\t      }\n\t      if (options.flat) {\n\t        if (match != \"false\") {\n\t          match = currentMatch;\n\t        }\n\t      }\n\t      if (match == \"false\") {\n\t        match = null;\n\t      }\n\t      if (dataname == \"false\") {\n\t        dataname = null;\n\t      }\n\t      let sectionObject = {\n\t        index: i,\n\t        ...(section && {\n\t          section\n\t        }),\n\t        ...(dataname && {\n\t          dataname\n\t        }),\n\t        ...(name && {\n\t          name\n\t        }),\n\t        ...(id && {\n\t          id\n\t        }),\n\t        ...(match && {\n\t          match\n\t        }),\n\t        ...(currentid && {\n\t          currentid\n\t        }),\n\t        ...(dataintl && {\n\t          dataintl\n\t        })\n\t      };\n\t      mainArray.push(sectionObject);\n\t    });\n\t  };\n\t  const prepareMenubars = () => {\n\t    debugLog(\"Preparing menubars\");\n\t    let menubars = selectionArray(vars.viewport, `.${options.menubarclass}`) ? selectionArray(vars.viewport, `.${options.menubarclass}`) : [];\n\t    if (options.barhtml.header) {\n\t      // Generate header menubar\n\t      let bar = createNode(options.barhtml.header);\n\t      menubars.push(bar);\n\t      vars.slides.before(bar);\n\t    }\n\t    if (options.barhtml.footer) {\n\t      // Generate footer menubar\n\t      let bar = createNode(options.barhtml.footer);\n\t      menubars.push(bar);\n\t      vars.slides.after(bar);\n\t    }\n\t    if (menubars.length) {\n\t      // If menubar (pre-existing or just added):\n\t      setScale(vars.deck.getScale());\n\t      menubars.forEach((menubar, i) => {\n\t        let barLocation = isBefore(menubar, vars.slides) ? \"top\" : \"bottom\";\n\t        menubar.classList.add(barLocation);\n\t        if (!menubar.id) {\n\t          menubar.id = `${options.menubarclass}${barLocation}`;\n\t        }\n\t        menubar.classList.add(\"ready\");\n\t      });\n\t      vars.menubars = menubars;\n\t    } else {\n\t      console.log(\"There are no menubars. You can still use Simplemenu to populate empty menus like in an Agenda or Table Of Contents.\");\n\t    }\n\t  };\n\t  const prepareMenus = () => {\n\t    debugLog(\"Preparing menus\");\n\t    let menus = menuArray();\n\t    if (!menus || menus && !menus.automenus) {\n\t      console.log(\"There are no menus. Please add one or more menus manually or through the 'barhtml' option.\");\n\t      return;\n\t    }\n\t    if (menus.automenus.length >= 1 && sections.namedvisible.length >= 1) {\n\t      // There are empty menus. Autofill them.\n\t      let idArray = [];\n\t      const autoMenuLinks = sections.namedvisible.map(section => {\n\t        let match = section.dataset[vars.matchString];\n\t        let name = section.dataset.name || section.getAttribute(`name`) || section.id;\n\t        let id = section.id || name.toLowerCase().replace(/\\s+/g, '').replace(/[^\\p{L}\\p{N}-]/gu, '');\n\t        idArray.push(id);\n\t        if (vars.quarto) {\n\t          id = mainArray.find(item => item.match === match).id;\n\t        }\n\t        let duplicatesBefore = checkOccurrence(idArray, id) > 1 ? `-${checkOccurrence(idArray, id)}` : '';\n\t        let href = vars.quarto ? id : id + duplicatesBefore;\n\t        let smmatchString = ` data-${vars.matchString}=\"${match}\"`;\n\t        let nameString = section.getAttribute(`name`) ? ` name=\"${section.getAttribute(`name`)}\"` : '';\n\t        let intlString = section.getAttribute(vars.langattribute) ? ` ${vars.langattribute}=\"${section.getAttribute(vars.langattribute)}\"` : '';\n\t        return `<li><a href=\"#/${href}\"${intlString}${nameString}${smmatchString}>${name}</a></li>`;\n\t      }).reduce((combinedHTML, itemHTML) => {\n\t        let orderedHTML = vars.rtl ? itemHTML + combinedHTML : combinedHTML + itemHTML;\n\t        return orderedHTML;\n\t      });\n\t      menus.automenus.forEach(automenu => {\n\t        automenu.innerHTML = autoMenuLinks;\n\t      });\n\t      autoListItems = menus.automenus.map(menu => Array.from(menu.querySelectorAll(options.activeelement))).flat();\n\t    }\n\t    if (menus.manualmenus.length >= 1) {\n\t      // There are pre-existing menus. Fix link to ID if needed.\n\n\t      // Only get the listitems\n\t      manualListItems = menus.manualmenus.map(menu => Array.from(menu.querySelectorAll(options.activeelement))).flat();\n\t      manualListItems.forEach(listItem => {\n\t        // Get the anchorlinks\n\t        let linker = listItem.tagName == \"a\" ? listItem : listItem.querySelector('a');\n\t        let linkhref = linker.getAttribute('href');\n\t        if (linkhref === \"#\") {\n\t          let newLink = listItem.dataset[vars.matchString].toLowerCase().replace(/\\s+/g, '').replace(/[^\\p{L}\\p{N}-]/gu, '');\n\t          linker.href = `#/${newLink}`;\n\t        }\n\t      });\n\t    }\n\t  };\n\t  const preparePrint = () => {\n\t    const urlParams = new URLSearchParams(window.location.search);\n\t    const hasPrintParam = urlParams.has('print-pdf');\n\t    if (hasPrintParam) {\n\t      mainArray.forEach(item => {\n\t        let printSection = item.section;\n\t        let datainfo = document.createElement(\"div\");\n\t        datainfo.classList.add(\"datainfo\");\n\t        copyDataAttributes(printSection, datainfo);\n\t        let moreData = ['match', 'name', 'dataname', 'currentid', 'id', 'dataintl'];\n\t        moreData.forEach(moreDataItem => {\n\t          if (item[moreDataItem]) {\n\t            datainfo.dataset[moreDataItem] = item[moreDataItem];\n\t          }\n\t        });\n\t        printSection.appendChild(datainfo);\n\t      });\n\t    }\n\t  };\n\t  const prepare = resolve => {\n\t    prepareSlides();\n\t    prepareMenubars();\n\t    prepareMenus();\n\t    preparePrint();\n\t    return setTimeout(resolve, 0);\n\t  };\n\t  const compare = (listItem, section) => {\n\t    let menukind = listItem.parentNode.hasAttribute('data-simplemenu-auto') ? \"auto\" : \"manual\";\n\t    let sectionmatch = section.match ? section.match : null;\n\t    if (menukind == \"manual\") {\n\t      if (options.selectby == \"id\") {\n\t        sectionmatch = section.id ? section.id : section.currentid ? mainArray[section.currentid].id : null;\n\t      } else if (options.selectby == \"name\") {\n\t        sectionmatch = section.name;\n\t      } else {\n\t        sectionmatch = section.dataname;\n\t      }\n\t    }\n\t    if (sectionmatch) {\n\t      let menumatch = listItem.dataset[vars.matchString] || listItem.querySelector('a').dataset[vars.matchString];\n\t      if (options.selectby == \"id\" && menukind == \"manual\") {\n\t        let href = listItem.href || listItem.querySelector('a').href;\n\t        let lastHref = href ? href.substring(href.lastIndexOf(\"/\") + 1) : '';\n\t        menumatch = lastHref;\n\t      }\n\t      if (options.selectby == \"data-name\" && menukind == \"manual\") {\n\t        sectionmatch = section.dataname ? section.dataname : null;\n\t      }\n\t      if (menumatch && menumatch == sectionmatch) {\n\t        listItem.classList.add(options.activeclass);\n\t      } else {\n\t        listItem.classList.remove(options.activeclass);\n\t      }\n\t    } else {\n\t      listItem.classList.remove(options.activeclass);\n\t    }\n\t  };\n\t  const checkSlidesNormal = event => {\n\t    const index = sections.regular.indexOf(event.currentSlide);\n\t    let section = mainArray[index];\n\t    autoListItems.filter(listItem => {\n\t      compare(listItem, section);\n\t    });\n\t    manualListItems.filter(listItem => {\n\t      compare(listItem, section);\n\t    });\n\t  };\n\t  const checkSlidesPDF = event => {\n\t    let pdfPages = selectionArray(vars.viewport, '.slides .pdf-page');\n\n\t    // Check if any menubar has a slide number\n\t    let anyMenubarHasSlidenumber = false;\n\t    if (vars.menubars) {\n\t      vars.menubars.forEach(menubar => {\n\t        anyMenubarHasSlidenumber = !!menubar.getElementsByClassName(\"slide-number\");\n\t      });\n\t    }\n\t    pdfPages.forEach(pdfPage => {\n\t      // The original section has gone, so we rebuild it with the saved data-attributes\n\t      let datainfo = pdfPage.getElementsByClassName(\"datainfo\")[0];\n\t      let section = {};\n\t      section.name = datainfo.dataset.name;\n\t      section.dataname = datainfo.dataset.dataname;\n\t      section.currentid = datainfo.dataset.currentid;\n\t      section.match = datainfo.dataset.match;\n\t      section.id = datainfo.dataset.id;\n\t      if (datainfo.dataset.state) {\n\t        let newClasses = datainfo.dataset.state.split(\" \");\n\t        newClasses.forEach(newClass => {\n\t          pdfPage.classList.add(newClass);\n\t          let vp = vars.deck.getRevealElement().closest(\".reveal-viewport\");\n\t          vp.classList.remove(newClass);\n\t        });\n\t      }\n\n\t      // If any menubar has a slide number, turn the original one on this slide off\n\t      if (anyMenubarHasSlidenumber && pdfPage.getElementsByClassName(\"slide-number\").length > 0) {\n\t        pdfPage.getElementsByClassName(\"slide-number\")[0].style.display = \"none\";\n\t      }\n\t      if (vars.menubars) {\n\t        vars.menubars.forEach(menubar => {\n\t          let bar = menubar.cloneNode(true);\n\t          pdfPage.appendChild(bar);\n\t          let listItems = selectionArray(bar, `.${options.menuclass} ${options.activeelement}`);\n\t          listItems.forEach(listItem => {\n\t            compare(listItem, section);\n\t          });\n\n\t          // If there is a slidenumber in the menu,\n\t          let newSN = pdfPage.querySelector(`.${options.menubarclass} .slide-number`);\n\t          let oldSN = pdfPage.querySelector(`:scope > .slide-number`);\n\t          if (newSN && oldSN) {\n\t            // ...then fill it with the current (total) slidenumber.\n\t            newSN.textContent = oldSN.textContent;\n\t          }\n\t        });\n\t      }\n\t    });\n\t    if (vars.menubars) {\n\t      vars.menubars.forEach(menubar => {\n\t        menubar.parentNode.removeChild(menubar);\n\t      });\n\t    }\n\t  };\n\t  const chapterize = event => {\n\t    if (event && event.type == \"ready\") {\n\t      debugLog(mainArray);\n\t      getRevealUI();\n\t    }\n\t    if (event && (event.type == \"ready\" || event.type == \"slidechanged\")) {\n\t      checkSlidesNormal(event);\n\t    }\n\t    if (event && event.type == \"pdf-ready\") {\n\t      checkSlidesPDF();\n\t    }\n\t  };\n\t  const simpleMenu = (deck, options, es5Filename) => {\n\t    deck.configure({\n\t      hash: true\n\t    });\n\t    vars.deck = deck;\n\t    vars.viewport = deck.getRevealElement().tagName === \"BODY\" ? document : deck.getRevealElement();\n\t    vars.slides = deck.getSlidesElement();\n\t    vars.langattribute = deck.getConfig().internation ? deck.getConfig().internation.langattribute ? deck.getConfig().internation.langattribute : \"data-i18n\" : false;\n\t    vars.rtl = deck.getConfig().rtl;\n\t    vars.quarto = !!(document.querySelector('[name=generator]') && document.querySelector('[name=generator]').content.includes(\"quarto\"));\n\t    vars.matchString = \"sm\";\n\t    vars.userScale = options.scale;\n\t    deck.addEventListener('ready', chapterize, false);\n\t    deck.addEventListener('slidechanged', chapterize, false);\n\t    deck.addEventListener('pdf-ready', chapterize, false);\n\t    deck.addEventListener('resize', _ref => {\n\t      let {\n\t        scale\n\t      } = _ref;\n\t      return setScale(scale);\n\t    }, false);\n\t    const SimplemenuStylePath = options.csspath ? options.csspath : `${pluginPath(es5Filename)}simplemenu.css` || 'plugin/simplemenu/simplemenu.css';\n\t    return new Promise(resolve => {\n\t      if (options.csspath === false) {\n\t        return prepare(resolve);\n\t      } else {\n\t        loadStyle(SimplemenuStylePath, 'stylesheet', async () => prepare(resolve));\n\t      }\n\t    });\n\t  };\n\t  const init = deck => {\n\t    let defaultOptions = {\n\t      menubarclass: 'menubar',\n\t      menuclass: 'menu',\n\t      activeclass: 'active',\n\t      activeelement: 'li',\n\t      selectby: 'id',\n\t      barhtml: {\n\t        header: '',\n\t        footer: ''\n\t      },\n\t      flat: false,\n\t      scale: 0.67,\n\t      csspath: ''\n\t    };\n\t    options = deck.getConfig().simplemenu || {};\n\t    options = mergeDeep(defaultOptions, options);\n\t    let wronginputs = false;\n\t    let warning = '';\n\t    if (options.selectby !== \"id\" && options.selectby !== \"data-name\" && options.selectby !== \"name\") {\n\t      wronginputs = true;\n\t      warning = 'The selectby option can be only \"id\",  \"data-name\" or \"name\".';\n\t    }\n\t    if (wronginputs) {\n\t      console.log('Simplemenu did not load:');\n\t      console.log(warning);\n\t      return false;\n\t    }\n\t    return simpleMenu(deck, options, \"simplemenu.js\");\n\t  };\n\t  return {\n\t    id: 'simplemenu',\n\t    init: init\n\t  };\n\t};\n\n\treturn Plugin;\n\n}));\n"]}