{"version":3,"file":"popover.min.js","sources":["https:\/\/uciliste.zastitanaradu.hr\/theme\/boost\/amd\/src\/bootstrap\/popover.js"],"sourcesContent":["\/**\n * --------------------------------------------------------------------------\n * Bootstrap (v4.6.0): popover.js\n * Licensed under MIT (https:\/\/github.com\/twbs\/bootstrap\/blob\/main\/LICENSE)\n * --------------------------------------------------------------------------\n *\/\n\nimport $ from 'jquery'\nimport Tooltip from '.\/tooltip'\n\n\/**\n * ------------------------------------------------------------------------\n * Constants\n * ------------------------------------------------------------------------\n *\/\n\nconst NAME = 'popover'\nconst VERSION = '4.6.0'\nconst DATA_KEY = 'bs.popover'\nconst EVENT_KEY = `.${DATA_KEY}`\nconst JQUERY_NO_CONFLICT = $.fn[NAME]\nconst CLASS_PREFIX = 'bs-popover'\nconst BSCLS_PREFIX_REGEX = new RegExp(`(^|\\\\s)${CLASS_PREFIX}\\\\S+`, 'g')\n\nconst Default = {\n ...Tooltip.Default,\n placement: 'right',\n trigger: 'click',\n content: '',\n template: '
' +\n '
<\/div>' +\n '

<\/h3>' +\n '
<\/div><\/div>'\n}\n\nconst DefaultType = {\n ...Tooltip.DefaultType,\n content: '(string|element|function)'\n}\n\nconst CLASS_NAME_FADE = 'fade'\nconst CLASS_NAME_SHOW = 'show'\n\nconst SELECTOR_TITLE = '.popover-header'\nconst SELECTOR_CONTENT = '.popover-body'\n\nconst Event = {\n HIDE: `hide${EVENT_KEY}`,\n HIDDEN: `hidden${EVENT_KEY}`,\n SHOW: `show${EVENT_KEY}`,\n SHOWN: `shown${EVENT_KEY}`,\n INSERTED: `inserted${EVENT_KEY}`,\n CLICK: `click${EVENT_KEY}`,\n FOCUSIN: `focusin${EVENT_KEY}`,\n FOCUSOUT: `focusout${EVENT_KEY}`,\n MOUSEENTER: `mouseenter${EVENT_KEY}`,\n MOUSELEAVE: `mouseleave${EVENT_KEY}`\n}\n\n\/**\n * ------------------------------------------------------------------------\n * Class Definition\n * ------------------------------------------------------------------------\n *\/\n\nclass Popover extends Tooltip {\n \/\/ Getters\n\n static get VERSION() {\n return VERSION\n }\n\n static get Default() {\n return Default\n }\n\n static get NAME() {\n return NAME\n }\n\n static get DATA_KEY() {\n return DATA_KEY\n }\n\n static get Event() {\n return Event\n }\n\n static get EVENT_KEY() {\n return EVENT_KEY\n }\n\n static get DefaultType() {\n return DefaultType\n }\n\n \/\/ Overrides\n\n isWithContent() {\n return this.getTitle() || this._getContent()\n }\n\n addAttachmentClass(attachment) {\n $(this.getTipElement()).addClass(`${CLASS_PREFIX}-${attachment}`)\n }\n\n getTipElement() {\n this.tip = this.tip || $(this.config.template)[0]\n return this.tip\n }\n\n setContent() {\n const $tip = $(this.getTipElement())\n\n \/\/ We use append for html objects to maintain js events\n this.setElementContent($tip.find(SELECTOR_TITLE), this.getTitle())\n let content = this._getContent()\n if (typeof content === 'function') {\n content = content.call(this.element)\n }\n\n this.setElementContent($tip.find(SELECTOR_CONTENT), content)\n\n $tip.removeClass(`${CLASS_NAME_FADE} ${CLASS_NAME_SHOW}`)\n }\n\n \/\/ Private\n\n _getContent() {\n return this.element.getAttribute('data-content') ||\n this.config.content\n }\n\n _cleanTipClass() {\n const $tip = $(this.getTipElement())\n const tabClass = $tip.attr('class').match(BSCLS_PREFIX_REGEX)\n if (tabClass !== null && tabClass.length > 0) {\n $tip.removeClass(tabClass.join(''))\n }\n }\n\n \/\/ Static\n\n static _jQueryInterface(config) {\n return this.each(function () {\n let data = $(this).data(DATA_KEY)\n const _config = typeof config === 'object' ? config : null\n\n if (!data && \/dispose|hide\/.test(config)) {\n return\n }\n\n if (!data) {\n data = new Popover(this, _config)\n $(this).data(DATA_KEY, data)\n }\n\n if (typeof config === 'string') {\n if (typeof data[config] === 'undefined') {\n throw new TypeError(`No method named \"${config}\"`)\n }\n\n data[config]()\n }\n })\n }\n}\n\n\/**\n * ------------------------------------------------------------------------\n * jQuery\n * ------------------------------------------------------------------------\n *\/\n\n$.fn[NAME] = Popover._jQueryInterface\n$.fn[NAME].Constructor = Popover\n$.fn[NAME].noConflict = () => {\n $.fn[NAME] = JQUERY_NO_CONFLICT\n return Popover._jQueryInterface\n}\n\nexport default Popover\n"],"names":["NAME","EVENT_KEY","JQUERY_NO_CONFLICT","$","fn","BSCLS_PREFIX_REGEX","RegExp","Default","Tooltip","placement","trigger","content","template","DefaultType","Event","HIDE","HIDDEN","SHOW","SHOWN","INSERTED","CLICK","FOCUSIN","FOCUSOUT","MOUSEENTER","MOUSELEAVE","Popover","config","this","each","data","_config","_typeof","test","TypeError","getTitle","_getContent","attachment","getTipElement","addClass","tip","$tip","setElementContent","find","call","element","removeClass","getAttribute","tabClass","attr","match","length","join","_jQueryInterface","Constructor","noConflict"],"mappings":"wqGAgBMA,KAAO,UAGPC,qBADW,cAEXC,mBAAqBC,gBAAEC,GAAGJ,MAE1BK,mBAAqB,IAAIC,wBADV,qBAC+C,KAE9DC,uCACDC,iBAAQD,aACXE,UAAW,QACXC,QAAS,QACTC,QAAS,GACTC,SAAU,wIAMNC,2CACDL,iBAAQK,iBACXF,QAAS,8BASLG,MAAQ,CACZC,mBAAad,WACbe,uBAAiBf,WACjBgB,mBAAahB,WACbiB,qBAAejB,WACfkB,2BAAqBlB,WACrBmB,qBAAenB,WACfoB,yBAAmBpB,WACnBqB,2BAAqBrB,WACrBsB,+BAAyBtB,WACzBuB,+BAAyBvB,YASrBwB,woBAGJ,iBAnDc,6BAuDd,kBACSlB,0BAGT,kBACSP,2BAGT,iBA9De,gCAkEf,kBACSc,6BAGT,kBACSb,mCAGT,kBACSY,4CAkDT,SAAwBa,eACfC,KAAKC,MAAK,eACXC,MAAO,mBAAEF,MAAME,KA\/HR,cAgILC,QAA4B,WAAlBC,QAAOL,QAAsBA,OAAS,SAEjDG,OAAQ,eAAeG,KAAKN,WAI5BG,OACHA,KAAO,IAAIJ,QAAQE,KAAMG,6BACvBH,MAAME,KAxIC,aAwIcA,OAGH,iBAAXH,QAAqB,SACF,IAAjBG,KAAKH,cACR,IAAIO,qCAA8BP,aAG1CG,K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