@finqu/cool 1.1.3 → 1.1.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1 +1 @@
1
- {"version":3,"file":"popover.js","sources":["../src/util/index.js","../src/abstract-ui-component.js","../src/popover.js"],"sourcesContent":["import 'jquery';\n\nconst debounce = function (func, wait, immediate) {\n\n\tlet timeout;\n\n\treturn function() {\n\n\t\tlet context = this;\n\t\tlet args = arguments;\n\t\tlet later = function() {\n\n\t\t\ttimeout = null;\n\n\t\t\tif (!immediate) {\n\t\t\t\tfunc.apply(context, args)\n\t\t\t};\n\t\t};\n\n\t\tlet callNow = immediate && !timeout;\n\n\t\tclearTimeout(timeout);\n\n\t\ttimeout = setTimeout(later, wait);\n\n\t\tif (callNow) {\n\t\t\tfunc.apply(context, args);\n\t\t}\n\t};\n};\n\nconst shallowProperty = function(key) {\n\n\treturn function(obj) {\n\n\t\treturn obj == null ? void 0 : obj[key];\n\t};\n};\n\nconst isArrayLike = function(collection) {\n\n\tlet length = shallowProperty('length');\n\n\treturn typeof length == 'number' && length >= 0 && length <= Math.pow(2, 53) - 1;\n};\n\nconst optimizeCb = function(func, context, argCount) {\n\n if (context === void 0) {\n \treturn func;\n\t}\n\n\tswitch (argCount == null ? 3 : argCount) {\n\n\t\tcase 1: return function(value) {\n\t\t\treturn func.call(context, value);\n\t\t};\n\n\t\tcase 3: return function(value, index, collection) {\n\t\t\treturn func.call(context, value, index, collection);\n\t\t};\n\t\tcase 4: return function(accumulator, value, index, collection) {\n\t\t\treturn func.call(context, accumulator, value, index, collection);\n\t\t};\n\t}\n\n return function() {\n\t\treturn func.apply(context, arguments);\n };\n};\n\nconst each = function(obj, iteratee, context) {\n\n\titeratee = optimizeCb(iteratee, context);\n\n\tlet i;\n\tlet length;\n\n\tif (isArrayLike(obj)) {\n\n\t\tfor (i = 0, length = obj.length; i < length; i++) {\n\t\t\titeratee(obj[i], i, obj);\n\t\t}\n\n\t} else {\n\n\t\tlet keys = Object.keys(obj);\n\n\t\tfor (i = 0, length = keys.length; i < length; i++) {\n\t\t\titeratee(obj[keys[i]], keys[i], obj);\n\t\t}\n\t}\n\n\treturn obj;\n};\n\nconst touchEvents = function () {\n\n\tlet result = false;\n\n\tif (('ontouchstart' in window) || window.DocumentTouch && document instanceof DocumentTouch) {\n\t\tresult = true;\n\t}\n\n\treturn result;\n};\n\nexport {\n\tdebounce,\n\ttouchEvents,\n\teach\n}","export default class AbstractUIComponent {\n\n\t// Init callback\n onInit() {\n\n let onInit = this.opts.onInit;\n\n if (typeof onInit === 'function') {\n\n onInit.call(this.el);\n }\n }\n\n // Update callback\n onUpdate() {\n\n let onUpdate = this.opts.onUpdate;\n\n if (typeof onUpdate === 'function') {\n\n onUpdate.call(this.el);\n }\n }\n\n // Destroy callback\n onDestroy() {\n\n let onDestroy = this.opts.onDestroy;\n\n if (typeof onDestroy === 'function') {\n\n onDestroy.call(this.el);\n }\n }\n\n // Show callback\n onShow() {\n\n let onShow = this.opts.onShow;\n\n if (typeof onShow === 'function') {\n\n onShow.call(this.el);\n }\n }\n\n // Close callback\n onClose() {\n\n let onClose = this.opts.onClose;\n\n if (typeof onClose === 'function') {\n\n onClose.call(this.el);\n }\n }\n\n // Debug log\n log(...args) {\n\n \tif (this.debug) {\n\n if (typeof this.debug === 'function') {\n this.debug(...args);\n } else {\n \t \tconsole.log(...args);\n }\n \t}\n }\n}","import 'jquery';\nimport { debounce } from './util/index';\nimport AbstractUIComponent from './abstract-ui-component';\n\nconst NAME = 'coolPopover';\nconst DATA_KEY = 'plugin_coolPopover';\n\nclass Popover extends AbstractUIComponent {\n\n constructor(el, opts) {\n\n super();\n\n this.opts = {};\n\n if (window.Cool.settings.popover) {\n\n $.extend(true, this.opts, $.fn[NAME].defaults, window.Cool.settings.popover, opts);\n\n } else {\n\n $.extend(true, this.opts, $.fn[NAME].defaults, opts);\n }\n\n this.el = el;\n this.debug = this.opts.debug;\n this.init();\n }\n\n // Init plugin\n init() {\n\n this.buildCache();\n this.bindEvents();\n this.onInit();\n }\n\n // Remove plugin instance completely\n destroy() {\n\n this.unbindEvents();\n this.$el.removeData(DATA_KEY);\n this.onDestroy();\n }\n\n // Update plugin data\n update() {\n\n this.buildCache();\n this.onUpdate();\n }\n\n // Cache DOM nodes for performance\n buildCache() {\n\n this.$el = $(this.el);\n this.$container = this.$el.data('container') ? $(this.$el.data('container')) : $(this.opts.container);\n this.id = 'popover-'+this.generateUUID();\n this.animation = this.$el.data('animation') ? this.$el.data('animation') : this.opts.animation;\n this.animationIn = this.$el.data('animationIn') ? this.$el.data('animationIn') : this.opts.animationIn;\n this.animationOut = this.$el.data('animationOut') ? this.$el.data('animationOut') : this.opts.animationOut;\n this.animationSpeed = this.$el.data('animationSpeed') ? this.$el.data('animationSpeed') : this.opts.animationSpeed;\n this.trigger = this.$el.data('trigger') ? this.$el.data('trigger') : this.opts.trigger;\n this.placement = this.$el.data('placement') ? this.$el.data('placement') : this.opts.placement;\n this.placementChanged = false;\n this.title = this.$el.data('title') ? this.$el.data('title') : this.opts.title;\n this.content = this.$el.data('content') ? this.$el.data('content') : this.opts.content;\n }\n\n // Bind events that trigger methods\n bindEvents() {\n\n if (this.trigger === 'click') {\n\n this.$el.on('click'+'.'+NAME, () => {\n\n if (this.$popover) {\n this.close();\n } else {\n this.show();\n }\n });\n\n } else if (this.trigger === 'hover') {\n\n this.$el.on('mouseenter'+'.'+NAME, () => {\n\n this.show();\n });\n\n this.$el.on('mouseleave'+'.'+NAME, () => {\n\n this.close();\n });\n\n } else if (this.trigger === 'focus') {\n\n this.$el.on('focusin'+'.'+NAME, () => {\n\n this.show();\n });\n\n this.$el.on('focusout'+'.'+NAME, () => {\n\n this.close();\n });\n }\n\n $(window).on('resize', debounce(() => {\n\n if (this.$popover) {\n this.setPosition();\n this.onUpdate();\n }\n }, 250));\n }\n\n // Unbind events that trigger methods\n unbindEvents() {\n\n this.$el.off('.'+NAME);\n }\n\n // Generate UUID\n generateUUID() {\n\n return 'xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx'.replace(/[xy]/g, function(c) {\n let r = Math.random() * 16 | 0, v = c == 'x' ? r : (r & 0x3 | 0x8);\n return v.toString(16);\n });\n }\n\n // Build popover\n buildPopover() {\n\n let content;\n\n \tif (typeof this.content === 'function') {\n \t\tcontent = this.content();\n \t} else {\n content = this.content;\n }\n\n \tthis.$popover = $(`\n \t\t<div class=\"popover\" role=\"tooltip\" id=\"${this.id}\">\n\n\t\t\t <div class=\"arrow\"></div>\n\n\t\t\t <h3 class=\"popover-header\">${this.title}</h3>\n\n\t\t\t <div class=\"popover-body\">${content}</div>\n\n\t\t\t</div>\n \t`);\n\n this.$container.append(this.$popover);\n this.$arrow = this.$popover.find('.arrow') ? this.$popover.find('.arrow') : false;\n\n this.log(this.$el);\n this.log(this.$container);\n this.log(this.$popover);\n this.log(this.$arrow);\n this.log('Id: '+this.id);\n this.log('Trigger: '+this.trigger);\n this.log('Placement: '+this.placement);\n this.log('Animation: '+this.animation);\n this.log('Animation in: '+this.animationIn);\n this.log('Animation out: '+this.animationOut);\n this.log('Animation speed: '+this.animationSpeed);\n this.log('Title: '+this.title);\n this.log('Content: '+this.content);\n }\n\n // Set positions\n setPosition(placement) {\n\n if (typeof placement === 'undefined' || placement === null) {\n placement = this.placement;\n }\n\n this.$popover.addClass('popover-'+placement);\n\n let containerInnerWidth = this.$container.innerWidth();\n let containerInnerHeight = this.$container.innerHeight();\n let popoverWidth = this.$popover.outerWidth(true);\n let popoverHeight = this.$popover.outerHeight(true);\n let popoverTriggerWidth = this.$el.outerWidth();\n let popoverTriggerHeight = this.$el.outerHeight();\n let popoverTriggerPosX = this.$el.position().left;\n let popoverTriggerPosY = this.$el.position().top;\n let arrowWidth = this.$arrow.outerWidth(true);\n let arrowHeight = this.$arrow.outerHeight(true);\n let arrowPos;\n let popoverPosX;\n let popoverPosY;\n\n if (placement === 'top') {\n\n popoverPosX = Math.round(popoverTriggerPosX - (popoverWidth - popoverTriggerWidth) / 2);\n popoverPosY = Math.round(popoverTriggerPosY - popoverHeight);\n arrowPos = Math.round(popoverWidth / 2 - arrowWidth / 2);\n\n this.$arrow.css({\n left: arrowPos+'px'\n });\n\n } else if (placement === 'right') {\n\n popoverPosX = Math.round(popoverTriggerPosX + popoverTriggerWidth);\n popoverPosY = Math.round(popoverTriggerPosY - (popoverHeight - popoverTriggerHeight) / 2);\n arrowPos = Math.round(popoverHeight / 2 - arrowHeight / 2);\n\n this.$arrow.css({\n top: arrowPos+'px'\n });\n\n } else if (placement === 'bottom') {\n\n popoverPosX = Math.round(popoverTriggerPosX - (popoverWidth - popoverTriggerWidth) / 2);\n popoverPosY = Math.round(popoverTriggerPosY + popoverTriggerHeight);\n arrowPos = Math.round(popoverWidth / 2 - arrowWidth / 2);\n\n this.$arrow.css({\n left: arrowPos+'px'\n });\n\n } else if (placement === 'left') {\n\n popoverPosX = Math.round(popoverTriggerPosX - popoverWidth);\n popoverPosY = Math.round(popoverTriggerPosY - (popoverHeight - popoverTriggerHeight) / 2);\n arrowPos = Math.round(popoverHeight / 2 - arrowHeight / 2);\n\n this.$arrow.css({\n top: arrowPos+'px'\n });\n }\n\n this.$popover.css({\n position: 'absolute',\n top: '0px',\n left: '0px',\n transform: 'translate3d('+popoverPosX+'px, '+popoverPosY+'px, 0px)',\n 'will-change': 'transform'\n });\n\n // Correct placement if popover goes outside of container\n let popoverOverflowCount = 0;\n let popoverPosition = {\n left: this.$popover.position().left,\n top: this.$popover.position().top,\n right: containerInnerWidth - (this.$popover.position().left + popoverWidth),\n bottom: containerInnerHeight - (this.$popover.position().top + popoverHeight),\n };\n let popoverOverflow = {\n left: false,\n top: false,\n right: false,\n bottom: false\n };\n\n if (popoverPosition.right < 0) {\n\n popoverOverflow.right = true;\n popoverOverflowCount++;\n\n this.log('Popover overflowing from right');\n }\n\n if (popoverPosition.left < 0) {\n\n popoverOverflow.left = true;\n popoverOverflowCount++;\n\n this.log('Popover overflowing from left');\n }\n\n if (popoverPosition.bottom < 0) {\n\n popoverOverflow.bottom = true;\n popoverOverflowCount++;\n\n this.log('Popover overflowing from bottom');\n }\n\n if (popoverPosition.top < 0) {\n\n popoverOverflow.top = true;\n popoverOverflowCount++;\n\n this.log('Popover overflowing from top');\n }\n\n if (popoverOverflowCount > 0) {\n\n if (!this.placementChanged && popoverOverflow.left && popoverPosition.right > popoverWidth) {\n\n this.log('Changing popover placement to right');\n\n this.placementChanged = true;\n this.$popover.removeClass('popover-'+placement);\n this.$arrow.removeAttr('style');\n this.setPosition('right');\n\n } else if (!this.placementChanged && popoverOverflow.top && popoverPosition.top > popoverHeight) {\n\n this.log('Changing popover placement to bottom');\n\n this.placementChanged = true;\n this.$popover.removeClass('popover-'+placement);\n this.$arrow.removeAttr('style');\n this.setPosition('bottom');\n\n } else if (!this.placementChanged && popoverOverflow.right && popoverPosition.left > popoverWidth) {\n\n this.log('Changing popover placement to left');\n\n this.placementChanged = true;\n this.$popover.removeClass('popover-'+placement);\n this.$arrow.removeAttr('style');\n this.setPosition('left');\n\n } else if (!this.placementChanged && popoverOverflow.bottom && popoverPosition.top > popoverHeight) {\n\n this.log('Changing popover placement to top');\n\n this.placementChanged = true;\n this.$popover.removeClass('popover-'+placement);\n this.$arrow.removeAttr('style');\n this.setPosition('top');\n\n } else if (!this.placementChanged && (placement !== 'top' || placement !== 'bottom') && (popoverOverflow.left || popoverOverflow.right)) {\n\n if (popoverPosition.top > popoverPosition.bottom) {\n\n this.log('Changing popover placement to top');\n\n this.placementChanged = true;\n this.$popover.removeClass('popover-'+placement);\n this.$arrow.removeAttr('style');\n this.setPosition('top');\n\n } else {\n\n this.log('Changing popover placement to bottom');\n\n this.placementChanged = true;\n this.$popover.removeClass('popover-'+placement);\n this.$arrow.removeAttr('style');\n this.setPosition('bottom');\n }\n\n } else {\n\n this.fixPopoverPosition = true;\n }\n\n if (this.fixPopoverPosition) {\n\n this.log('Adjusting popover size or position in order to popover fit in the container');\n\n if (popoverOverflow.left) {\n\n this.log('Popover overflowing from left');\n\n let overflowAmount = Math.abs(popoverPosition.left);\n let excludePlacements = ['top', 'bottom'];\n\n if ((popoverTriggerPosX >= popoverPosX + overflowAmount) && excludePlacements.indexOf(placement) < 0) {\n\n this.log('Popover adjusting width');\n\n popoverWidth -= overflowAmount;\n popoverPosX += overflowAmount;\n\n } else {\n\n this.log('Popover adjusting position x');\n\n popoverPosX += overflowAmount;\n arrowPos -= overflowAmount;\n }\n }\n\n if (popoverOverflow.top) {\n\n this.log('Popover overflowing from top');\n\n let overflowAmount = Math.abs(popoverPosition.top);\n\n this.log('Popover adjusting position y');\n\n popoverPosY += overflowAmount;\n arrowPos -= overflowAmount;\n }\n\n if (popoverOverflow.right) {\n\n this.log('Popover overflowing from right');\n\n let overflowAmount = Math.abs(popoverPosition.right);\n let excludePlacements = ['top', 'bottom'];\n\n if ((popoverTriggerPosX <= popoverPosX - overflowAmount) && excludePlacements.indexOf(placement) < 0) {\n\n this.log('Popover adjusting width');\n\n popoverWidth -= overflowAmount;\n\n } else {\n\n this.log('Popover adjusting position x');\n\n popoverPosX -= overflowAmount;\n arrowPos += overflowAmount;\n }\n }\n\n if (popoverOverflow.bottom) {\n\n this.log('Popover overflowing from bottom');\n\n let overflowAmount = Math.abs(popoverPosition.bottom);\n\n this.log('Popover adjusting position y');\n\n popoverPosY -= overflowAmount;\n arrowPos += overflowAmount;\n }\n\n if (placement === 'top') {\n\n this.$arrow.css({\n left: arrowPos+'px'\n });\n\n } else if (placement === 'right') {\n\n this.$arrow.css({\n top: arrowPos+'px'\n });\n\n } else if (placement === 'bottom') {\n\n this.$arrow.css({\n left: arrowPos+'px'\n });\n\n } else if (placement === 'left') {\n\n this.$arrow.css({\n top: arrowPos+'px'\n });\n }\n\n this.$popover.css({\n width: popoverWidth,\n transform: 'translate3d('+popoverPosX+'px, '+popoverPosY+'px, 0px)'\n });\n\n this.fixPopoverPosition = false;\n\n this.log('Popover placement changed: '+this.placementChanged);\n this.log('Popover container inner width: '+containerInnerWidth+'px');\n this.log('Popover container inner height: '+containerInnerHeight+'px');\n this.log('Popover trigger width: '+popoverTriggerWidth+'px');\n this.log('Popover trigger height: '+popoverTriggerHeight+'px');\n this.log('popover trigger position x: '+popoverTriggerPosX+'px');\n this.log('Popover trigger position Y: '+popoverTriggerPosY+'px');\n this.log('Popover width: '+popoverWidth+'px');\n this.log('Popover height: '+popoverHeight+'px');\n this.log('Popover position x: '+popoverPosX+'px');\n this.log('Popover position y: '+popoverPosY+'px');\n this.log('Popover position left: '+popoverPosition.left+'px');\n this.log('Popover position top: '+popoverPosition.top+'px');\n this.log('Popover position right: '+popoverPosition.right+'px');\n this.log('Popover position bottom: '+popoverPosition.bottom+'px');\n }\n\n } else {\n\n this.log('Popover placement changed: '+this.placementChanged);\n this.log('Popover container inner width: '+containerInnerWidth+'px');\n this.log('Popover container inner height: '+containerInnerHeight+'px');\n this.log('Popover trigger width: '+popoverTriggerWidth+'px');\n this.log('Popover trigger height: '+popoverTriggerHeight+'px');\n this.log('popover trigger position x: '+popoverTriggerPosX+'px');\n this.log('Popover trigger position Y: '+popoverTriggerPosY+'px');\n this.log('Popover width: '+popoverWidth+'px');\n this.log('Popover height: '+popoverHeight+'px');\n this.log('Popover position x: '+popoverPosX+'px');\n this.log('Popover position y: '+popoverPosY+'px');\n this.log('Popover position left: '+popoverPosition.left+'px');\n this.log('Popover position top: '+popoverPosition.top+'px');\n this.log('Popover position right: '+popoverPosition.right+'px');\n this.log('Popover position bottom: '+popoverPosition.bottom+'px');\n }\n }\n\n // Show\n show() {\n\n if (this.$popover) {\n return;\n }\n\n this.buildPopover();\n this.setPosition();\n\n if (this.animation) {\n\n this.$popover.addClass(this.animationSpeed);\n this.$popover.animateCss(this.animationIn);\n this.$popover.addClass('show');\n this.$popover.attr('id', this.id);\n this.$el.attr('data-popover', this.id);\n\n } else {\n\n this.$popover.addClass('show');\n this.$popover.attr('id', this.id);\n this.$el.attr('data-popover', this.id);\n }\n\n this.onShow();\n }\n\n // Close\n close() {\n\n if (!this.$popover) {\n return;\n }\n\n if (this.animation && !this.$popover.hasClass('animated')) {\n\n this.$popover.animateCss(this.animationOut, () => {\n\n this.$popover.remove();\n this.$el.removeAttr('data-popover');\n this.$popover = null;\n this.placementChanged = false;\n\n this.onClose();\n });\n\n } else {\n\n this.$popover.remove();\n this.$el.removeAttr('data-popover');\n this.$popover = null;\n this.placementChanged = false;\n\n this.onClose();\n }\n }\n\n static _jQueryInterface(config) {\n\n \treturn this.each(function() {\n\n \t\tlet data = $(this).data(DATA_KEY);\n \t\tconst _config = typeof config === 'object' && config;\n\n \t\tif (!data) {\n \t\t\tdata = new Popover(this, _config);\n \t\t\t$(this).data(DATA_KEY, data);\n \t\t}\n\n \t\tif (typeof config === 'string') {\n\n \t\t\tif (typeof data[config] === 'undefined') {\n\t\t \tthrow new TypeError(`No method named \"${config}\"`)\n\t\t }\n\n\t\t data[config]()\n \t\t}\n\t });\n }\n}\n\nif (typeof $ !== 'undefined') {\n\n // jQuery\n const JQUERY_NO_CONFLICT = $.fn[NAME];\n\n $.fn[NAME] = Popover._jQueryInterface;\n $.fn[NAME].Constructor = Popover;\n\n $.fn[NAME].noConflict = () => {\n\n $.fn[NAME] = JQUERY_NO_CONFLICT\n\n return Popover._jQueryInterface\n }\n\n $.fn[NAME].defaults = {\n container: '.content-inner',\n trigger: 'focus',\n placement: 'bottom',\n animation: true,\n animationIn: 'fadeIn',\n animationOut: 'fadeOut',\n animationSpeed: 'fastest',\n title: '',\n content: '',\n onInit: null,\n onUpdate: null,\n onDestroy: null,\n onShow: null,\n onClose: null,\n debug: false\n }\n}\n\nexport default Popover;"],"names":["debounce","func","wait","immediate","timeout","context","args","arguments","later","apply","callNow","clearTimeout","setTimeout","AbstractUIComponent","onInit","opts","call","el","onUpdate","onDestroy","onShow","onClose","log","debug","console","NAME","DATA_KEY","Popover","constructor","window","Cool","settings","popover","$","extend","fn","defaults","init","buildCache","bindEvents","destroy","unbindEvents","$el","removeData","update","$container","data","container","id","generateUUID","animation","animationIn","animationOut","animationSpeed","trigger","placement","placementChanged","title","content","on","$popover","close","show","setPosition","off","replace","c","r","Math","random","v","toString","buildPopover","append","$arrow","find","addClass","containerInnerWidth","innerWidth","containerInnerHeight","innerHeight","popoverWidth","outerWidth","popoverHeight","outerHeight","popoverTriggerWidth","popoverTriggerHeight","popoverTriggerPosX","position","left","popoverTriggerPosY","top","arrowWidth","arrowHeight","arrowPos","popoverPosX","popoverPosY","round","css","transform","popoverOverflowCount","popoverPosition","right","bottom","popoverOverflow","removeClass","removeAttr","fixPopoverPosition","overflowAmount","abs","excludePlacements","indexOf","width","animateCss","attr","hasClass","remove","_jQueryInterface","config","each","_config","TypeError","JQUERY_NO_CONFLICT","Constructor","noConflict"],"mappings":";;;;;;;;;;;CAEA,MAAMA,QAAQ,GAAG,UAAUC,IAAV,EAAgBC,IAAhB,EAAsBC,SAAtB,EAAiC;CAEjD,MAAIC,OAAJ;CAEA,SAAO,YAAW;CAEjB,QAAIC,OAAO,GAAG,IAAd;CACA,QAAIC,IAAI,GAAGC,SAAX;;CACA,QAAIC,KAAK,GAAG,YAAW;CAEtBJ,MAAAA,OAAO,GAAG,IAAV;;CAEA,UAAI,CAACD,SAAL,EAAgB;CACfF,QAAAA,IAAI,CAACQ,KAAL,CAAWJ,OAAX,EAAoBC,IAApB;CACA;CACD,KAPD;;CASA,QAAII,OAAO,GAAGP,SAAS,IAAI,CAACC,OAA5B;CAEAO,IAAAA,YAAY,CAACP,OAAD,CAAZ;CAEAA,IAAAA,OAAO,GAAGQ,UAAU,CAACJ,KAAD,EAAQN,IAAR,CAApB;;CAEA,QAAIQ,OAAJ,EAAa;CACZT,MAAAA,IAAI,CAACQ,KAAL,CAAWJ,OAAX,EAAoBC,IAApB;CACA;CACD,GAtBD;CAuBA,CA3BD;;CCFe,MAAMO,mBAAN,CAA0B;CAExC;CACGC,EAAAA,MAAM,GAAG;CAEL,QAAIA,MAAM,GAAG,KAAKC,IAAL,CAAUD,MAAvB;;CA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E,EAAF,CAAKV,IAAL,IAAaiG,kBAAb;CAEA,WAAO/F,OAAO,CAAC0F,gBAAf;CACH,GALD;;CAOApF,EAAAA,CAAC,CAACE,EAAF,CAAKV,IAAL,EAAWW,QAAX,GAAsB;CAClBW,IAAAA,SAAS,EAAE,gBADO;CAElBO,IAAAA,OAAO,EAAE,OAFS;CAGlBC,IAAAA,SAAS,EAAE,QAHO;CAIlBL,IAAAA,SAAS,EAAE,IAJO;CAKlBC,IAAAA,WAAW,EAAE,QALK;CAMlBC,IAAAA,YAAY,EAAE,SANI;CAOlBC,IAAAA,cAAc,EAAE,SAPE;CAQlBI,IAAAA,KAAK,EAAE,EARW;CASlBC,IAAAA,OAAO,EAAE,EATS;CAUlB5C,IAAAA,MAAM,EAAE,IAVU;CAWlBI,IAAAA,QAAQ,EAAE,IAXQ;CAYlBC,IAAAA,SAAS,EAAE,IAZO;CAalBC,IAAAA,MAAM,EAAE,IAbU;CAclBC,IAAAA,OAAO,EAAE,IAdS;CAelBE,IAAAA,KAAK,EAAE;CAfW,GAAtB;CAiBH;;;;;;;;"}
1
+ {"version":3,"file":"popover.js","sources":["../src/util/index.js","../src/abstract-ui-component.js","../src/popover.js"],"sourcesContent":["import 'jquery';\n\nconst debounce = function (func, wait, immediate) {\n\n\tlet timeout;\n\n\treturn function() {\n\n\t\tlet context = this;\n\t\tlet args = arguments;\n\t\tlet later = function() {\n\n\t\t\ttimeout = null;\n\n\t\t\tif (!immediate) {\n\t\t\t\tfunc.apply(context, args)\n\t\t\t};\n\t\t};\n\n\t\tlet callNow = immediate && !timeout;\n\n\t\tclearTimeout(timeout);\n\n\t\ttimeout = setTimeout(later, wait);\n\n\t\tif (callNow) {\n\t\t\tfunc.apply(context, args);\n\t\t}\n\t};\n};\n\nconst shallowProperty = function(key) {\n\n\treturn function(obj) {\n\n\t\treturn obj == null ? void 0 : obj[key];\n\t};\n};\n\nconst isArrayLike = function(collection) {\n\n\tlet length = shallowProperty('length');\n\n\treturn typeof length == 'number' && length >= 0 && length <= Math.pow(2, 53) - 1;\n};\n\nconst optimizeCb = function(func, context, argCount) {\n\n if (context === void 0) {\n \treturn func;\n\t}\n\n\tswitch (argCount == null ? 3 : argCount) {\n\n\t\tcase 1: return function(value) {\n\t\t\treturn func.call(context, value);\n\t\t};\n\n\t\tcase 3: return function(value, index, collection) {\n\t\t\treturn func.call(context, value, index, collection);\n\t\t};\n\t\tcase 4: return function(accumulator, value, index, collection) {\n\t\t\treturn func.call(context, accumulator, value, index, collection);\n\t\t};\n\t}\n\n return function() {\n\t\treturn func.apply(context, arguments);\n };\n};\n\nconst each = function(obj, iteratee, context) {\n\n\titeratee = optimizeCb(iteratee, context);\n\n\tlet i;\n\tlet length;\n\n\tif (isArrayLike(obj)) {\n\n\t\tfor (i = 0, length = obj.length; i < length; i++) {\n\t\t\titeratee(obj[i], i, obj);\n\t\t}\n\n\t} else {\n\n\t\tlet keys = Object.keys(obj);\n\n\t\tfor (i = 0, length = keys.length; i < length; i++) {\n\t\t\titeratee(obj[keys[i]], keys[i], obj);\n\t\t}\n\t}\n\n\treturn obj;\n};\n\nconst touchEvents = function () {\n\n\tlet result = false;\n\n\tif (('ontouchstart' in window) || window.DocumentTouch && document instanceof DocumentTouch) {\n\t\tresult = true;\n\t}\n\n\treturn result;\n};\n\nexport {\n\tdebounce,\n\ttouchEvents,\n\teach\n}","export default class AbstractUIComponent {\n\n\t// Init callback\n onInit() {\n\n let onInit = this.opts.onInit;\n\n if (typeof onInit === 'function') {\n\n onInit.call(this.el);\n }\n }\n\n // Update callback\n onUpdate() {\n\n let onUpdate = this.opts.onUpdate;\n\n if (typeof onUpdate === 'function') {\n\n onUpdate.call(this.el);\n }\n }\n\n // Destroy callback\n onDestroy() {\n\n let onDestroy = this.opts.onDestroy;\n\n if (typeof onDestroy === 'function') {\n\n onDestroy.call(this.el);\n }\n }\n\n // Show callback\n onShow() {\n\n let onShow = this.opts.onShow;\n\n if (typeof onShow === 'function') {\n\n onShow.call(this.el);\n }\n }\n\n // Close callback\n onClose() {\n\n let onClose = this.opts.onClose;\n\n if (typeof onClose === 'function') {\n\n onClose.call(this.el);\n }\n }\n\n // Debug log\n log(...args) {\n\n \tif (this.debug) {\n\n if (typeof this.debug === 'function') {\n this.debug(...args);\n } else {\n \t \tconsole.log(...args);\n }\n \t}\n }\n}","import 'jquery';\nimport { debounce } from './util/index';\nimport AbstractUIComponent from './abstract-ui-component';\n\nconst NAME = 'coolPopover';\nconst DATA_KEY = 'plugin_coolPopover';\n\nclass Popover extends AbstractUIComponent {\n\n constructor(el, opts) {\n\n super();\n\n this.opts = {};\n\n if (window.Cool.settings.popover) {\n\n $.extend(true, this.opts, $.fn[NAME].defaults, window.Cool.settings.popover, opts);\n\n } else {\n\n $.extend(true, this.opts, $.fn[NAME].defaults, opts);\n }\n\n this.el = el;\n this.debug = this.opts.debug;\n this.init();\n }\n\n // Init plugin\n init() {\n\n this.buildCache();\n this.bindEvents();\n this.onInit();\n }\n\n // Remove plugin instance completely\n destroy() {\n\n this.unbindEvents();\n this.$el.removeData(DATA_KEY);\n this.onDestroy();\n }\n\n // Update plugin data\n update() {\n\n this.buildCache();\n this.onUpdate();\n }\n\n // Cache DOM nodes for performance\n buildCache() {\n\n this.$el = $(this.el);\n this.$container = this.$el.data('container') ? $(this.$el.data('container')) : $(this.opts.container);\n this.id = 'popover-'+this.generateUUID();\n this.animation = this.$el.data('animation') ? this.$el.data('animation') : this.opts.animation;\n this.animationIn = this.$el.data('animationIn') ? this.$el.data('animationIn') : this.opts.animationIn;\n this.animationOut = this.$el.data('animationOut') ? this.$el.data('animationOut') : this.opts.animationOut;\n this.animationSpeed = this.$el.data('animationSpeed') ? this.$el.data('animationSpeed') : this.opts.animationSpeed;\n this.trigger = this.$el.data('trigger') ? this.$el.data('trigger') : this.opts.trigger;\n this.placement = this.$el.data('placement') ? this.$el.data('placement') : this.opts.placement;\n this.placementChanged = false;\n this.title = this.$el.data('title') ? this.$el.data('title') : this.opts.title;\n this.content = this.$el.data('content') ? this.$el.data('content') : this.opts.content;\n }\n\n // Bind events that trigger methods\n bindEvents() {\n\n if (this.trigger === 'click') {\n\n this.$el.on('click'+'.'+NAME, () => {\n\n if (this.$popover) {\n this.close();\n } else {\n this.show();\n }\n });\n\n } else if (this.trigger === 'hover') {\n\n this.$el.on('mouseenter'+'.'+NAME, () => {\n\n this.show();\n });\n\n this.$el.on('mouseleave'+'.'+NAME, () => {\n\n this.close();\n });\n\n } else if (this.trigger === 'focus') {\n\n this.$el.on('focusin'+'.'+NAME, () => {\n\n this.show();\n });\n\n this.$el.on('focusout'+'.'+NAME, () => {\n\n this.close();\n });\n }\n\n $(window).on('resize', debounce(() => {\n\n if (this.$popover) {\n this.setPosition();\n this.onUpdate();\n }\n }, 250));\n }\n\n // Unbind events that trigger methods\n unbindEvents() {\n\n this.$el.off('.'+NAME);\n }\n\n // Generate UUID\n generateUUID() {\n\n return 'xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx'.replace(/[xy]/g, function(c) {\n let r = Math.random() * 16 | 0, v = c == 'x' ? r : (r & 0x3 | 0x8);\n return v.toString(16);\n });\n }\n\n // Build popover\n buildPopover() {\n\n let content;\n\n \tif (typeof this.content === 'function') {\n \t\tcontent = this.content();\n \t} else {\n content = this.content;\n }\n\n \tthis.$popover = $(`\n \t\t<div class=\"popover\" role=\"tooltip\" id=\"${this.id}\">\n\n\t\t\t <div class=\"arrow\"></div>\n\n\t\t\t <h3 class=\"popover-header\">${this.title}</h3>\n\n\t\t\t <div class=\"popover-body\">${content}</div>\n\n\t\t\t</div>\n \t`);\n\n this.$container.append(this.$popover);\n this.$arrow = this.$popover.find('.arrow') ? this.$popover.find('.arrow') : false;\n\n this.log(this.$el);\n this.log(this.$container);\n this.log(this.$popover);\n this.log(this.$arrow);\n this.log('Id: '+this.id);\n this.log('Trigger: '+this.trigger);\n this.log('Placement: '+this.placement);\n this.log('Animation: '+this.animation);\n this.log('Animation in: '+this.animationIn);\n this.log('Animation out: '+this.animationOut);\n this.log('Animation speed: '+this.animationSpeed);\n this.log('Title: '+this.title);\n this.log('Content: '+this.content);\n }\n\n // Set positions\n setPosition(placement) {\n\n if (typeof placement === 'undefined' || placement === null) {\n placement = this.placement;\n }\n\n this.$popover.addClass('popover-'+placement);\n\n let containerInnerWidth = this.$container.innerWidth();\n let containerInnerHeight = this.$container.innerHeight();\n let popoverWidth = this.$popover.outerWidth(true);\n let popoverHeight = this.$popover.outerHeight(true);\n let popoverTriggerWidth = this.$el.outerWidth();\n let popoverTriggerHeight = this.$el.outerHeight();\n let popoverTriggerPosX = this.$el.position().left;\n let popoverTriggerPosY = this.$el.position().top;\n let arrowWidth = this.$arrow.outerWidth(true);\n let arrowHeight = this.$arrow.outerHeight(true);\n let arrowPos;\n let popoverPosX;\n let popoverPosY;\n\n if (placement === 'top') {\n\n popoverPosX = Math.round(popoverTriggerPosX - (popoverWidth - popoverTriggerWidth) / 2);\n popoverPosY = Math.round(popoverTriggerPosY - popoverHeight);\n arrowPos = Math.round(popoverWidth / 2 - arrowWidth / 2);\n\n this.$arrow.css({\n left: arrowPos+'px'\n });\n\n } else if (placement === 'right') {\n\n popoverPosX = Math.round(popoverTriggerPosX + popoverTriggerWidth);\n popoverPosY = Math.round(popoverTriggerPosY - (popoverHeight - popoverTriggerHeight) / 2);\n arrowPos = Math.round(popoverHeight / 2 - arrowHeight / 2);\n\n this.$arrow.css({\n top: arrowPos+'px'\n });\n\n } else if (placement === 'bottom') {\n\n popoverPosX = Math.round(popoverTriggerPosX - (popoverWidth - popoverTriggerWidth) / 2);\n popoverPosY = Math.round(popoverTriggerPosY + popoverTriggerHeight);\n arrowPos = Math.round(popoverWidth / 2 - arrowWidth / 2);\n\n this.$arrow.css({\n left: arrowPos+'px'\n });\n\n } else if (placement === 'left') {\n\n popoverPosX = Math.round(popoverTriggerPosX - popoverWidth);\n popoverPosY = Math.round(popoverTriggerPosY - (popoverHeight - popoverTriggerHeight) / 2);\n arrowPos = Math.round(popoverHeight / 2 - arrowHeight / 2);\n\n this.$arrow.css({\n top: arrowPos+'px'\n });\n }\n\n this.$popover.css({\n position: 'absolute',\n top: '0px',\n left: '0px',\n transform: 'translate3d('+popoverPosX+'px, '+popoverPosY+'px, 0px)',\n 'will-change': 'transform'\n });\n\n // Correct placement if popover goes outside of container\n let popoverOverflowCount = 0;\n let popoverPosition = {\n left: this.$popover.position().left,\n top: this.$popover.position().top,\n right: containerInnerWidth - (this.$popover.position().left + popoverWidth),\n bottom: containerInnerHeight - (this.$popover.position().top + popoverHeight),\n };\n let popoverOverflow = {\n left: false,\n top: false,\n right: false,\n bottom: false\n };\n\n if (popoverPosition.right < 0) {\n\n popoverOverflow.right = true;\n popoverOverflowCount++;\n\n this.log('Popover overflowing from right');\n }\n\n if (popoverPosition.left < 0) {\n\n popoverOverflow.left = true;\n popoverOverflowCount++;\n\n this.log('Popover overflowing from left');\n }\n\n if (popoverPosition.bottom < 0) {\n\n popoverOverflow.bottom = true;\n popoverOverflowCount++;\n\n this.log('Popover overflowing from bottom');\n }\n\n if (popoverPosition.top < 0) {\n\n popoverOverflow.top = true;\n popoverOverflowCount++;\n\n this.log('Popover overflowing from top');\n }\n\n if (popoverOverflowCount > 0) {\n\n if (!this.placementChanged && popoverOverflow.left && popoverPosition.right > popoverWidth) {\n\n this.log('Changing popover placement to right');\n\n this.placementChanged = true;\n this.$popover.removeClass('popover-'+placement);\n this.$arrow.removeAttr('style');\n this.setPosition('right');\n\n } else if (!this.placementChanged && popoverOverflow.top && popoverPosition.top > popoverHeight) {\n\n this.log('Changing popover placement to bottom');\n\n this.placementChanged = true;\n this.$popover.removeClass('popover-'+placement);\n this.$arrow.removeAttr('style');\n this.setPosition('bottom');\n\n } else if (!this.placementChanged && popoverOverflow.right && popoverPosition.left > popoverWidth) {\n\n this.log('Changing popover placement to left');\n\n this.placementChanged = true;\n this.$popover.removeClass('popover-'+placement);\n this.$arrow.removeAttr('style');\n this.setPosition('left');\n\n } else if (!this.placementChanged && popoverOverflow.bottom && popoverPosition.top > popoverHeight) {\n\n this.log('Changing popover placement to top');\n\n this.placementChanged = true;\n this.$popover.removeClass('popover-'+placement);\n this.$arrow.removeAttr('style');\n this.setPosition('top');\n\n } else if (!this.placementChanged && (placement !== 'top' || placement !== 'bottom') && (popoverOverflow.left || popoverOverflow.right)) {\n\n if (popoverPosition.top > popoverPosition.bottom) {\n\n this.log('Changing popover placement to top');\n\n this.placementChanged = true;\n this.$popover.removeClass('popover-'+placement);\n this.$arrow.removeAttr('style');\n this.setPosition('top');\n\n } else {\n\n this.log('Changing popover placement to bottom');\n\n this.placementChanged = true;\n this.$popover.removeClass('popover-'+placement);\n this.$arrow.removeAttr('style');\n this.setPosition('bottom');\n }\n\n } else {\n\n this.fixPopoverPosition = true;\n }\n\n if (this.fixPopoverPosition) {\n\n this.log('Adjusting popover size or position in order to popover fit in the container');\n\n if (popoverOverflow.left) {\n\n this.log('Popover overflowing from left');\n\n let overflowAmount = Math.abs(popoverPosition.left);\n let excludePlacements = ['top', 'bottom'];\n\n if ((popoverTriggerPosX >= popoverPosX + overflowAmount) && excludePlacements.indexOf(placement) < 0) {\n\n this.log('Popover adjusting width');\n\n popoverWidth -= overflowAmount;\n popoverPosX += overflowAmount;\n\n } else {\n\n this.log('Popover adjusting position x');\n\n popoverPosX += overflowAmount;\n arrowPos -= overflowAmount;\n }\n }\n\n if (popoverOverflow.top) {\n\n this.log('Popover overflowing from top');\n\n let overflowAmount = Math.abs(popoverPosition.top);\n\n this.log('Popover adjusting position y');\n\n popoverPosY += overflowAmount;\n arrowPos -= overflowAmount;\n }\n\n if (popoverOverflow.right) {\n\n this.log('Popover overflowing from right');\n\n let overflowAmount = Math.abs(popoverPosition.right);\n let excludePlacements = ['top', 'bottom'];\n\n if ((popoverTriggerPosX <= popoverPosX - overflowAmount) && excludePlacements.indexOf(placement) < 0) {\n\n this.log('Popover adjusting width');\n\n popoverWidth -= overflowAmount;\n\n } else {\n\n this.log('Popover adjusting position x');\n\n popoverPosX -= overflowAmount;\n arrowPos += overflowAmount;\n }\n }\n\n if (popoverOverflow.bottom) {\n\n this.log('Popover overflowing from bottom');\n\n let overflowAmount = Math.abs(popoverPosition.bottom);\n\n this.log('Popover adjusting position y');\n\n popoverPosY -= overflowAmount;\n arrowPos += overflowAmount;\n }\n\n if (placement === 'top') {\n\n this.$arrow.css({\n left: arrowPos+'px'\n });\n\n } else if (placement === 'right') {\n\n this.$arrow.css({\n top: arrowPos+'px'\n });\n\n } else if (placement === 'bottom') {\n\n this.$arrow.css({\n left: arrowPos+'px'\n });\n\n } else if (placement === 'left') {\n\n this.$arrow.css({\n top: arrowPos+'px'\n });\n }\n\n this.$popover.css({\n width: popoverWidth,\n transform: 'translate3d('+popoverPosX+'px, '+popoverPosY+'px, 0px)'\n });\n\n this.fixPopoverPosition = false;\n\n this.log('Popover placement changed: '+this.placementChanged);\n this.log('Popover container inner width: '+containerInnerWidth+'px');\n this.log('Popover container inner height: '+containerInnerHeight+'px');\n this.log('Popover trigger width: '+popoverTriggerWidth+'px');\n this.log('Popover trigger height: '+popoverTriggerHeight+'px');\n this.log('popover trigger position x: '+popoverTriggerPosX+'px');\n this.log('Popover trigger position Y: '+popoverTriggerPosY+'px');\n this.log('Popover width: '+popoverWidth+'px');\n this.log('Popover height: '+popoverHeight+'px');\n this.log('Popover position x: '+popoverPosX+'px');\n this.log('Popover position y: '+popoverPosY+'px');\n this.log('Popover position left: '+popoverPosition.left+'px');\n this.log('Popover position top: '+popoverPosition.top+'px');\n this.log('Popover position right: '+popoverPosition.right+'px');\n this.log('Popover position bottom: '+popoverPosition.bottom+'px');\n }\n\n } else {\n\n this.log('Popover placement changed: '+this.placementChanged);\n this.log('Popover container inner width: '+containerInnerWidth+'px');\n this.log('Popover container inner height: '+containerInnerHeight+'px');\n this.log('Popover trigger width: '+popoverTriggerWidth+'px');\n this.log('Popover trigger height: '+popoverTriggerHeight+'px');\n this.log('popover trigger position x: '+popoverTriggerPosX+'px');\n this.log('Popover trigger position Y: '+popoverTriggerPosY+'px');\n this.log('Popover width: '+popoverWidth+'px');\n this.log('Popover height: '+popoverHeight+'px');\n this.log('Popover position x: '+popoverPosX+'px');\n this.log('Popover position y: '+popoverPosY+'px');\n this.log('Popover position left: '+popoverPosition.left+'px');\n this.log('Popover position top: '+popoverPosition.top+'px');\n this.log('Popover position right: '+popoverPosition.right+'px');\n this.log('Popover position bottom: '+popoverPosition.bottom+'px');\n }\n }\n\n // Show\n show() {\n\n if (this.$popover) {\n return;\n }\n\n this.buildPopover();\n this.setPosition();\n\n if (this.animation) {\n\n this.$popover.addClass(this.animationSpeed);\n this.$popover.animateCss(this.animationIn);\n this.$popover.addClass('show');\n this.$popover.attr('id', this.id);\n this.$el.attr('data-popover', this.id);\n\n } else {\n\n this.$popover.addClass('show');\n this.$popover.attr('id', this.id);\n this.$el.attr('data-popover', this.id);\n }\n\n this.onShow();\n }\n\n // Close\n close() {\n\n if (!this.$popover) {\n return;\n }\n\n if (this.animation && !this.$popover.hasClass('animated')) {\n\n this.$popover.animateCss(this.animationOut, () => {\n\n this.$popover.remove();\n this.$el.removeAttr('data-popover');\n this.$popover = null;\n this.placementChanged = false;\n\n this.onClose();\n });\n\n } else {\n\n this.$popover.remove();\n this.$el.removeAttr('data-popover');\n this.$popover = null;\n this.placementChanged = false;\n\n this.onClose();\n }\n }\n\n static _jQueryInterface(config) {\n\n \treturn this.each(function() {\n\n \t\tlet data = $(this).data(DATA_KEY);\n \t\tconst _config = typeof config === 'object' && config;\n\n \t\tif (!data) {\n \t\t\tdata = new Popover(this, _config);\n \t\t\t$(this).data(DATA_KEY, data);\n \t\t}\n\n \t\tif (typeof config === 'string') {\n\n \t\t\tif (typeof data[config] === 'undefined') {\n\t\t \tthrow new TypeError(`No method named \"${config}\"`)\n\t\t }\n\n\t\t data[config]()\n \t\t}\n\t });\n }\n}\n\nif (typeof $ !== 'undefined') {\n\n // jQuery\n const JQUERY_NO_CONFLICT = $.fn[NAME];\n\n $.fn[NAME] = Popover._jQueryInterface;\n $.fn[NAME].Constructor = Popover;\n\n $.fn[NAME].noConflict = () => {\n\n $.fn[NAME] = JQUERY_NO_CONFLICT\n\n return Popover._jQueryInterface\n }\n\n $.fn[NAME].defaults = {\n container: '.content-inner',\n trigger: 'focus',\n placement: 'bottom',\n animation: true,\n animationIn: 'fadeIn',\n animationOut: 'fadeOut',\n animationSpeed: 'fastest',\n title: '',\n content: '',\n onInit: null,\n onUpdate: null,\n onDestroy: null,\n onShow: null,\n onClose: null,\n debug: false\n }\n}\n\nexport default Popover;"],"names":["debounce","func","wait","immediate","timeout","context","args","arguments","later","apply","callNow","clearTimeout","setTimeout","AbstractUIComponent","onInit","opts","call","el","onUpdate","onDestroy","onShow","onClose","log","debug","console","NAME","DATA_KEY","Popover","window","Cool","settings","popover","$","extend","fn","defaults","init","buildCache","bindEvents","destroy","unbindEvents","$el","removeData","update","$container","data","container","id","generateUUID","animation","animationIn","animationOut","animationSpeed","trigger","placement","placementChanged","title","content","on","$popover","close","show","setPosition","off","replace","c","r","Math","random","v","toString","buildPopover","append","$arrow","find","addClass","containerInnerWidth","innerWidth","containerInnerHeight","innerHeight","popoverWidth","outerWidth","popoverHeight","outerHeight","popoverTriggerWidth","popoverTriggerHeight","popoverTriggerPosX","position","left","popoverTriggerPosY","top","arrowWidth","arrowHeight","arrowPos","popoverPosX","popoverPosY","round","css","transform","popoverOverflowCount","popoverPosition","right","bottom","popoverOverflow","removeClass","removeAttr","fixPopoverPosition","overflowAmount","abs","excludePlacements","indexOf","width","animateCss","attr","hasClass","remove","_jQueryInterface","config","each","_config","TypeError","JQUERY_NO_CONFLICT","Constructor","noConflict"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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