{"version":3,"sources":["webpack:///./LeLab.Web/src/utils/pikaday/pikaday.js","webpack:///./LeLab.Web/src/js/datepicker.entry.js","webpack:///./node_modules/pikaday/pikaday.js"],"names":["Pikaday","pickadayConfig","format","toString","date","day","getDate","padStart","month","getMonth","year","getFullYear","parse","dateString","parts","split","parseInt","Date","i18n","previousMonth","nextMonth","months","weekdays","weekdaysShort","yearRange","inputmaskConfig","mask","BarbaDatepicker","PageHooks","afterLeave","current","node","this","getNodes","Inputmask","remove","picker","destroy","beforeEnter","next","field","container","querySelectorAll","root","factory","moment","e","module","exports","hasMoment","hasEventListeners","window","addEventListener","document","sto","setTimeout","addEvent","el","callback","capture","attachEvent","removeEvent","removeEventListener","detachEvent","hasClass","cn","className","indexOf","addClass","removeClass","str","replace","trim","isArray","obj","test","Object","prototype","call","isDate","isNaN","getTime","isWeekend","getDay","isLeapYear","getDaysInMonth","setToStartOfDay","setHours","compareDates","a","b","extend","to","from","overwrite","prop","hasProp","undefined","nodeName","slice","fireEvent","eventName","data","ev","createEvent","initEvent","dispatchEvent","createEventObject","adjustCalendar","calendar","Math","ceil","abs","floor","defaults","bound","ariaLabel","position","reposition","defaultDate","setDefaultDate","firstDay","formatStrict","minDate","maxDate","showWeekNumber","pickWholeWeek","minYear","maxYear","minMonth","maxMonth","startRange","endRange","isRTL","yearSuffix","showMonthAfterYear","showDaysInNextAndPreviousMonths","enableSelectionDaysInNextAndPreviousMonths","numberOfMonths","mainCalendar","blurFieldOnSelect","theme","events","onSelect","onOpen","onClose","onDraw","keyboardInput","renderDayName","opts","abbr","renderDay","arr","ariaSelected","isEmpty","push","isDisabled","isToday","isSelected","hasEvent","isInRange","isStartRange","isEndRange","join","renderRow","days","isRowSelected","reverse","renderTitle","instance","c","refYear","randId","i","j","monthHtml","yearHtml","_o","isMinYear","isMaxYear","html","prev","options","self","config","_onMouseDown","_v","target","event","srcElement","parentNode","prevMonth","setDate","getAttribute","hide","blur","_c","preventDefault","returnValue","_onChange","gotoMonth","value","gotoYear","_onKeyChange","isVisible","keyCode","adjustDate","_onInputChange","firedBy","isValid","toDate","show","_onInputFocus","_onInputClick","_onInputBlur","pEl","activeElement","_b","_onClick","onchange","setAttribute","trigger","createElement","appendChild","body","insertBefore","nextSibling","defDate","gotoDate","disableWeekends","disableDayFn","nom","setMinDate","setMaxDate","fallback","_d","toDateString","getMoment","setMoment","preventOnSelect","isMoment","draw","min","max","newCalendar","calendars","firstVisibleDate","lastVisibleDate","length","visibleDate","setMonth","adjustCalendars","sign","newDay","difference","valueOf","gotoToday","setStartRange","setEndRange","force","_y","_m","random","substr","render","innerHTML","type","focus","adjustPosition","width","height","viewportWidth","viewportHeight","scrollTop","left","top","clientRect","leftAligned","bottomAligned","style","offsetWidth","offsetHeight","innerWidth","documentElement","clientWidth","innerHeight","clientHeight","pageYOffset","getBoundingClientRect","pageXOffset","bottom","offsetLeft","offsetTop","offsetParent","now","before","row","yearOfPreviousMonth","yearOfNextMonth","daysInPreviousMonth","cells","after","d","m","y","onejan","isWeekSelected","r","dayNumber","monthNumber","yearNumber","dayConfig","unshift","weekNum","renderHead","rows","renderTable","v","removeChild"],"mappings":"qJAGeA,G,OAAAA,EAAf,G,wsBCMA,MAAMC,EAAiB,CACnBC,OAAQ,aACRC,SAASC,EAAMF,GACX,MAAMG,EAAMD,EAAKE,UAAUH,WAAWI,SAAS,EAAG,KAC5CC,GAASJ,EAAKK,WAAa,GAAGN,WAAWI,SAAS,EAAG,KACrDG,EAAON,EAAKO,cAAcR,WAAWI,SAAS,EAAG,KACvD,gBAAUF,EAAV,YAAiBG,EAAjB,YAA0BE,IAE9BE,MAAMC,EAAYX,GACd,MAAMY,EAAQD,EAAWE,MAAM,KACzBV,EAAMW,SAASF,EAAM,GAAI,IACzBN,EAAQQ,SAASF,EAAM,GAAI,IAAM,EACjCJ,EAAOM,SAASF,EAAM,GAAI,IAChC,OAAO,IAAIG,KAAKP,EAAMF,EAAOH,IAEjCa,KAAM,CACFC,cAAe,iBACfC,UAAW,eAC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KAAM,WAEF,IAAI2H,EAAI7R,KAAK0J,IACH,IAANmI,IACI7R,KAAKiJ,GAAG9D,OACRtD,EAAYR,EAAU,QAASrB,KAAK0L,UAExC1L,KAAKyB,GAAG8N,MAAMlK,SAAW,SACzBrF,KAAKyB,GAAG8N,MAAML,KAAO,OACrBlP,KAAKyB,GAAG8N,MAAMJ,IAAM,OACpB/M,EAASpC,KAAKyB,GAAI,aAClBzB,KAAK0J,IAAK,OACAzF,IAAN4N,GAA8C,mBAApB7R,KAAKiJ,GAAGhC,SAClCjH,KAAKiJ,GAAGhC,QAAQnE,KAAK9C,QAQjCK,QAAS,WAEL,IAAIgH,EAAOrH,KAAKiJ,GAEhBjJ,KAAKkK,OACLrI,EAAY7B,KAAKyB,GAAI,YAAazB,KAAKyJ,cAAc,GACrD5H,EAAY7B,KAAKyB,GAAI,WAAYzB,KAAKyJ,cAAc,GACpD5H,EAAY7B,KAAKyB,GAAI,SAAUzB,KAAKuK,WAChClD,EAAKF,eACLtF,EAAYR,EAAU,UAAWrB,KAAK2K,cAEtCtD,EAAK7G,QACLqB,EAAYwF,EAAK7G,MAAO,SAAUR,KAAK+K,gBACnC1D,EAAKlC,QACLtD,EAAYwF,EAAKwE,QAAS,QAAS7L,KAAKqL,eACxCxJ,EAAYwF,EAAKwE,QAAS,QAAS7L,KAAKoL,eACxCvJ,EAAYwF,EAAKwE,QAAS,OAAQ7L,KAAKsL,gBAG3CtL,KAAKyB,GAAGqI,YACR9J,KAAKyB,GAAGqI,WAAWgI,YAAY9R,KAAKyB,MAMzCzD,EAxtCc4C,CAAQC,GATjC,K","file":"datepicker.js","sourcesContent":["import Pikaday from \"pikaday\";\r\nimport \"./pikaday.scss\";\r\n\r\nexport default Pikaday;\r\n","import { PageHooks } from \"barba\"\r\nimport Pikaday from \"utils/pikaday/pikaday\"\r\nimport Inputmask from \"inputmask\"\r\n\r\n\r\n\r\n// Documentation :\r\n// https://github.com/Pikaday/Pikaday\r\n\r\nconst pickadayConfig = {\r\n format: \"DD-MM-YYYY\",\r\n toString(date, format) {\r\n const day = date.getDate().toString().padStart(2, \"0\");\r\n const month = (date.getMonth() + 1).toString().padStart(2, \"0\");\r\n const year = date.getFullYear().toString().padStart(2, \"0\");\r\n return `${day}-${month}-${year}`;\r\n },\r\n parse(dateString, format) {\r\n const parts = dateString.split(\"-\");\r\n const day = parseInt(parts[0], 10);\r\n const month = parseInt(parts[1], 10) - 1;\r\n const year = parseInt(parts[2], 10);\r\n return new Date(year, month, day);\r\n },\r\n i18n: {\r\n previousMonth: \"Mois précédent\",\r\n nextMonth: \"Mois suivant\",\r\n months: [\"Janvier\", \"Février\", \"Mars\", \"Avril\", \"Mai\", \"Juin\", \"Juillet\", \"Août\", \"Septembre\", \"Octobre\", \"Novembre\", \"Décembre\"],\r\n weekdays: [\"Dimanche\", \"Lundi\", \"Mardi\", \"Mercredi\", \"Jeudi\", \"Vendredi\", \"Samedi\"],\r\n weekdaysShort: [\"Dim\", \"Lun\", \"Mar\", \"Mer\", \"Jeu\", \"Ven\", \"Sam\"]\r\n },\r\n yearRange: [1920, 2020]\r\n}\r\n\r\n\r\n\r\n// Documentation :\r\n// https://github.com/RobinHerbots/Inputmask\r\n\r\nconst inputmaskConfig = {\r\n mask: \"99-99-9999\"\r\n}\r\n\r\n\r\n\r\nclass BarbaDatepicker extends PageHooks {\r\n afterLeave({ current }) {\r\n for (let node of this.getNodes(current)) {\r\n Inputmask.remove(node)\r\n if (node.picker) {\r\n node.picker.destroy()\r\n delete node.picker\r\n }\r\n }\r\n }\r\n beforeEnter({ next }) {\r\n for (let node of this.getNodes(next)) {\r\n Inputmask(inputmaskConfig).mask(node)\r\n node.picker = new Pikaday({\r\n ...pickadayConfig,\r\n field: node\r\n })\r\n }\r\n }\r\n getNodes({ container }) {\r\n return container.querySelectorAll(\"input[data-datepicker]\")\r\n }\r\n}\r\nnew BarbaDatepicker()","/*!\n * Pikaday\n *\n * Copyright © 2014 David Bushell | BSD & MIT license | https://github.com/Pikaday/Pikaday\n */\n\n(function (root, factory)\n{\n 'use strict';\n\n var moment;\n if (typeof exports === 'object') {\n // CommonJS module\n // Load moment.js as an optional dependency\n try { moment = require('moment'); } catch (e) {}\n module.exports = factory(moment);\n } else if (typeof define === 'function' && define.amd) {\n // AMD. Register as an anonymous module.\n define(function (req)\n {\n // Load moment.js as an optional dependency\n var id = 'moment';\n try { moment = req(id); } catch (e) {}\n return factory(moment);\n });\n } else {\n root.Pikaday = factory(root.moment);\n }\n}(this, function (moment)\n{\n 'use strict';\n\n /**\n * feature detection and helper functions\n */\n var hasMoment = typeof moment === 'function',\n\n hasEventListeners = !!window.addEventListener,\n\n document = window.document,\n\n sto = window.setTimeout,\n\n addEvent = function(el, e, callback, capture)\n {\n if (hasEventListeners) {\n el.addEventListener(e, callback, !!capture);\n } else {\n el.attachEvent('on' + e, callback);\n }\n },\n\n removeEvent = function(el, e, callback, capture)\n {\n if (hasEventListeners) {\n el.removeEventListener(e, callback, !!capture);\n } else {\n el.detachEvent('on' + e, callback);\n }\n },\n\n trim = function(str)\n {\n return str.trim ? str.trim() : str.replace(/^\\s+|\\s+$/g,'');\n },\n\n hasClass = function(el, cn)\n {\n return (' ' + el.className + ' ').indexOf(' ' + cn + ' ') !== -1;\n },\n\n addClass = function(el, cn)\n {\n if (!hasClass(el, cn)) {\n el.className = (el.className === '') ? cn : el.className + ' ' + cn;\n }\n },\n\n removeClass = function(el, cn)\n {\n el.className = trim((' ' + el.className + ' ').replace(' ' + cn + ' ', ' '));\n },\n\n isArray = function(obj)\n {\n return (/Array/).test(Object.prototype.toString.call(obj));\n },\n\n isDate = function(obj)\n {\n return (/Date/).test(Object.prototype.toString.call(obj)) && !isNaN(obj.getTime());\n },\n\n isWeekend = function(date)\n {\n var day = date.getDay();\n return day === 0 || day === 6;\n },\n\n isLeapYear = function(year)\n {\n // solution by Matti Virkkunen: http://stackoverflow.com/a/4881951\n return year % 4 === 0 && year % 100 !== 0 || year % 400 === 0;\n },\n\n getDaysInMonth = function(year, month)\n {\n return [31, isLeapYear(year) ? 29 : 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31][month];\n },\n\n setToStartOfDay = function(date)\n {\n if (isDate(date)) date.setHours(0,0,0,0);\n },\n\n compareDates = function(a,b)\n {\n // weak date comparison (use setToStartOfDay(date) to ensure correct result)\n return a.getTime() === b.getTime();\n },\n\n extend = function(to, from, overwrite)\n {\n var prop, hasProp;\n for (prop in from) {\n hasProp = to[prop] !== undefined;\n if (hasProp && typeof from[prop] === 'object' && from[prop] !== null && from[prop].nodeName === undefined) {\n if (isDate(from[prop])) {\n if (overwrite) {\n to[prop] = new Date(from[prop].getTime());\n }\n }\n else if (isArray(from[prop])) {\n if (overwrite) {\n to[prop] = from[prop].slice(0);\n }\n } else {\n to[prop] = extend({}, from[prop], overwrite);\n }\n } else if (overwrite || !hasProp) {\n to[prop] = from[prop];\n }\n }\n return to;\n },\n\n fireEvent = function(el, eventName, data)\n {\n var ev;\n\n if (document.createEvent) {\n ev = document.createEvent('HTMLEvents');\n ev.initEvent(eventName, true, false);\n ev = extend(ev, data);\n el.dispatchEvent(ev);\n } else if (document.createEventObject) {\n ev = document.createEventObject();\n ev = extend(ev, data);\n el.fireEvent('on' + eventName, ev);\n }\n },\n\n adjustCalendar = function(calendar) {\n if (calendar.month < 0) {\n calendar.year -= Math.ceil(Math.abs(calendar.month)/12);\n calendar.month += 12;\n }\n if (calendar.month > 11) {\n calendar.year += Math.floor(Math.abs(calendar.month)/12);\n calendar.month -= 12;\n }\n return calendar;\n },\n\n /**\n * defaults and localisation\n */\n defaults = {\n\n // bind the picker to a form field\n field: null,\n\n // automatically show/hide the picker on `field` focus (default `true` if `field` is set)\n bound: undefined,\n\n // data-attribute on the input field with an aria assistance tekst (only applied when `bound` is set)\n ariaLabel: 'Use the arrow keys to pick a date',\n\n // position of the datepicker, relative to the field (default to bottom & left)\n // ('bottom' & 'left' keywords are not used, 'top' & 'right' are modifier on the bottom/left position)\n position: 'bottom left',\n\n // automatically fit in the viewport even if it means repositioning from the position option\n reposition: true,\n\n // the default output format for `.toString()` and `field` value\n format: 'YYYY-MM-DD',\n\n // the toString function which gets passed a current date object and format\n // and returns a string\n toString: null,\n\n // used to create date object from current input string\n parse: null,\n\n // the initial date to view when first opened\n defaultDate: null,\n\n // make the `defaultDate` the initial selected value\n setDefaultDate: false,\n\n // first day of week (0: Sunday, 1: Monday etc)\n firstDay: 0,\n\n // the default flag for moment's strict date parsing\n formatStrict: false,\n\n // the minimum/earliest date that can be selected\n minDate: null,\n // the maximum/latest date that can be selected\n maxDate: null,\n\n // number of years either side, or array of upper/lower range\n yearRange: 10,\n\n // show week numbers at head of row\n showWeekNumber: false,\n\n // Week picker mode\n pickWholeWeek: false,\n\n // used internally (don't config outside)\n minYear: 0,\n maxYear: 9999,\n minMonth: undefined,\n maxMonth: undefined,\n\n startRange: null,\n endRange: null,\n\n isRTL: false,\n\n // Additional text to append to the year in the calendar title\n yearSuffix: '',\n\n // Render the month after year in the calendar title\n showMonthAfterYear: false,\n\n // Render days of the calendar grid that fall in the next or previous month\n showDaysInNextAndPreviousMonths: false,\n\n // Allows user to select days that fall in the next or previous month\n enableSelectionDaysInNextAndPreviousMonths: false,\n\n // how many months are visible\n numberOfMonths: 1,\n\n // when numberOfMonths is used, this will help you to choose where the main calendar will be (default `left`, can be set to `right`)\n // only used for the first display or when a selected date is not visible\n mainCalendar: 'left',\n\n // Specify a DOM element to render the calendar in\n container: undefined,\n\n // Blur field when date is selected\n blurFieldOnSelect : true,\n\n // internationalization\n i18n: {\n previousMonth : 'Previous Month',\n nextMonth : 'Next Month',\n months : ['January','February','March','April','May','June','July','August','September','October','November','December'],\n weekdays : ['Sunday','Monday','Tuesday','Wednesday','Thursday','Friday','Saturday'],\n weekdaysShort : ['Sun','Mon','Tue','Wed','Thu','Fri','Sat']\n },\n\n // Theme Classname\n theme: null,\n\n // events array\n events: [],\n\n // callback function\n onSelect: null,\n onOpen: null,\n onClose: null,\n onDraw: null,\n\n // Enable keyboard input\n keyboardInput: true\n },\n\n\n /**\n * templating functions to abstract HTML rendering\n */\n renderDayName = function(opts, day, abbr)\n {\n day += opts.firstDay;\n while (day >= 7) {\n day -= 7;\n }\n return abbr ? opts.i18n.weekdaysShort[day] : opts.i18n.weekdays[day];\n },\n\n renderDay = function(opts)\n {\n var arr = [];\n var ariaSelected = 'false';\n if (opts.isEmpty) {\n if (opts.showDaysInNextAndPreviousMonths) {\n arr.push('is-outside-current-month');\n\n if(!opts.enableSelectionDaysInNextAndPreviousMonths) {\n arr.push('is-selection-disabled');\n }\n\n } else {\n return '';\n }\n }\n if (opts.isDisabled) {\n arr.push('is-disabled');\n }\n if (opts.isToday) {\n arr.push('is-today');\n }\n if (opts.isSelected) {\n arr.push('is-selected');\n ariaSelected = 'true';\n }\n if (opts.hasEvent) {\n arr.push('has-event');\n }\n if (opts.isInRange) {\n arr.push('is-inrange');\n }\n if (opts.isStartRange) {\n arr.push('is-startrange');\n }\n if (opts.isEndRange) {\n arr.push('is-endrange');\n }\n return '' +\n '' +\n '';\n },\n\n renderWeek = function (d, m, y) {\n // Lifted from http://javascript.about.com/library/blweekyear.htm, lightly modified.\n var onejan = new Date(y, 0, 1),\n weekNum = Math.ceil((((new Date(y, m, d) - onejan) / 86400000) + onejan.getDay()+1)/7);\n return '' + weekNum + '';\n },\n\n renderRow = function(days, isRTL, pickWholeWeek, isRowSelected)\n {\n return '' + (isRTL ? days.reverse() : days).join('') + '';\n },\n\n renderBody = function(rows)\n {\n return '' + rows.join('') + '';\n },\n\n renderHead = function(opts)\n {\n var i, arr = [];\n if (opts.showWeekNumber) {\n arr.push('');\n }\n for (i = 0; i < 7; i++) {\n arr.push('' + renderDayName(opts, i, true) + '');\n }\n return '' + (opts.isRTL ? arr.reverse() : arr).join('') + '';\n },\n\n renderTitle = function(instance, c, year, month, refYear, randId)\n {\n var i, j, arr,\n opts = instance._o,\n isMinYear = year === opts.minYear,\n isMaxYear = year === opts.maxYear,\n html = '
',\n monthHtml,\n yearHtml,\n prev = true,\n next = true;\n\n for (arr = [], i = 0; i < 12; i++) {\n arr.push('');\n }\n\n monthHtml = '
' + opts.i18n.months[month] + '
';\n\n if (isArray(opts.yearRange)) {\n i = opts.yearRange[0];\n j = opts.yearRange[1] + 1;\n } else {\n i = year - opts.yearRange;\n j = 1 + year + opts.yearRange;\n }\n\n for (arr = []; i < j && i <= opts.maxYear; i++) {\n if (i >= opts.minYear) {\n arr.push('');\n }\n }\n yearHtml = '
' + year + opts.yearSuffix + '
';\n\n if (opts.showMonthAfterYear) {\n html += yearHtml + monthHtml;\n } else {\n html += monthHtml + yearHtml;\n }\n\n if (isMinYear && (month === 0 || opts.minMonth >= month)) {\n prev = false;\n }\n\n if (isMaxYear && (month === 11 || opts.maxMonth <= month)) {\n next = false;\n }\n\n if (c === 0) {\n html += '';\n }\n if (c === (instance._o.numberOfMonths - 1) ) {\n html += '';\n }\n\n return html += '
';\n },\n\n renderTable = function(opts, data, randId)\n {\n return '' + renderHead(opts) + renderBody(data) + '
';\n },\n\n\n /**\n * Pikaday constructor\n */\n Pikaday = function(options)\n {\n var self = this,\n opts = self.config(options);\n\n self._onMouseDown = function(e)\n {\n if (!self._v) {\n return;\n }\n e = e || window.event;\n var target = e.target || e.srcElement;\n if (!target) {\n return;\n }\n\n if (!hasClass(target, 'is-disabled')) {\n if (hasClass(target, 'pika-button') && !hasClass(target, 'is-empty') && !hasClass(target.parentNode, 'is-disabled')) {\n self.setDate(new Date(target.getAttribute('data-pika-year'), target.getAttribute('data-pika-month'), target.getAttribute('data-pika-day')));\n if (opts.bound) {\n sto(function() {\n self.hide();\n if (opts.blurFieldOnSelect && opts.field) {\n opts.field.blur();\n }\n }, 100);\n }\n }\n else if (hasClass(target, 'pika-prev')) {\n self.prevMonth();\n }\n else if (hasClass(target, 'pika-next')) {\n self.nextMonth();\n }\n }\n if (!hasClass(target, 'pika-select')) {\n // if this is touch event prevent mouse events emulation\n if (e.preventDefault) {\n e.preventDefault();\n } else {\n e.returnValue = false;\n return false;\n }\n } else {\n self._c = true;\n }\n };\n\n self._onChange = function(e)\n {\n e = e || window.event;\n var target = e.target || e.srcElement;\n if (!target) {\n return;\n }\n if (hasClass(target, 'pika-select-month')) {\n self.gotoMonth(target.value);\n }\n else if (hasClass(target, 'pika-select-year')) {\n self.gotoYear(target.value);\n }\n };\n\n self._onKeyChange = function(e)\n {\n e = e || window.event;\n\n if (self.isVisible()) {\n\n switch(e.keyCode){\n case 13:\n case 27:\n if (opts.field) {\n opts.field.blur();\n }\n break;\n case 37:\n e.preventDefault();\n self.adjustDate('subtract', 1);\n break;\n case 38:\n self.adjustDate('subtract', 7);\n break;\n case 39:\n self.adjustDate('add', 1);\n break;\n case 40:\n self.adjustDate('add', 7);\n break;\n }\n }\n };\n\n self._onInputChange = function(e)\n {\n var date;\n\n if (e.firedBy === self) {\n return;\n }\n if (opts.parse) {\n date = opts.parse(opts.field.value, opts.format);\n } else if (hasMoment) {\n date = moment(opts.field.value, opts.format, opts.formatStrict);\n date = (date && date.isValid()) ? date.toDate() : null;\n }\n else {\n date = new Date(Date.parse(opts.field.value));\n }\n if (isDate(date)) {\n self.setDate(date);\n }\n if (!self._v) {\n self.show();\n }\n };\n\n self._onInputFocus = function()\n {\n self.show();\n };\n\n self._onInputClick = function()\n {\n self.show();\n };\n\n self._onInputBlur = function()\n {\n // IE allows pika div to gain focus; catch blur the input field\n var pEl = document.activeElement;\n do {\n if (hasClass(pEl, 'pika-single')) {\n return;\n }\n }\n while ((pEl = pEl.parentNode));\n\n if (!self._c) {\n self._b = sto(function() {\n self.hide();\n }, 50);\n }\n self._c = false;\n };\n\n self._onClick = function(e)\n {\n e = e || window.event;\n var target = e.target || e.srcElement,\n pEl = target;\n if (!target) {\n return;\n }\n if (!hasEventListeners && hasClass(target, 'pika-select')) {\n if (!target.onchange) {\n target.setAttribute('onchange', 'return;');\n addEvent(target, 'change', self._onChange);\n }\n }\n do {\n if (hasClass(pEl, 'pika-single') || pEl === opts.trigger) {\n return;\n }\n }\n while ((pEl = pEl.parentNode));\n if (self._v && target !== opts.trigger && pEl !== opts.trigger) {\n self.hide();\n }\n };\n\n self.el = document.createElement('div');\n self.el.className = 'pika-single' + (opts.isRTL ? ' is-rtl' : '') + (opts.theme ? ' ' + opts.theme : '');\n\n addEvent(self.el, 'mousedown', self._onMouseDown, true);\n addEvent(self.el, 'touchend', self._onMouseDown, true);\n addEvent(self.el, 'change', self._onChange);\n\n if (opts.keyboardInput) {\n addEvent(document, 'keydown', self._onKeyChange);\n }\n\n if (opts.field) {\n if (opts.container) {\n opts.container.appendChild(self.el);\n } else if (opts.bound) {\n document.body.appendChild(self.el);\n } else {\n opts.field.parentNode.insertBefore(self.el, opts.field.nextSibling);\n }\n addEvent(opts.field, 'change', self._onInputChange);\n\n if (!opts.defaultDate) {\n if (hasMoment && opts.field.value) {\n opts.defaultDate = moment(opts.field.value, opts.format).toDate();\n } else {\n opts.defaultDate = new Date(Date.parse(opts.field.value));\n }\n opts.setDefaultDate = true;\n }\n }\n\n var defDate = opts.defaultDate;\n\n if (isDate(defDate)) {\n if (opts.setDefaultDate) {\n self.setDate(defDate, true);\n } else {\n self.gotoDate(defDate);\n }\n } else {\n self.gotoDate(new Date());\n }\n\n if (opts.bound) {\n this.hide();\n self.el.className += ' is-bound';\n addEvent(opts.trigger, 'click', self._onInputClick);\n addEvent(opts.trigger, 'focus', self._onInputFocus);\n addEvent(opts.trigger, 'blur', self._onInputBlur);\n } else {\n this.show();\n }\n };\n\n\n /**\n * public Pikaday API\n */\n Pikaday.prototype = {\n\n\n /**\n * configure functionality\n */\n config: function(options)\n {\n if (!this._o) {\n this._o = extend({}, defaults, true);\n }\n\n var opts = extend(this._o, options, true);\n\n opts.isRTL = !!opts.isRTL;\n\n opts.field = (opts.field && opts.field.nodeName) ? opts.field : null;\n\n opts.theme = (typeof opts.theme) === 'string' && opts.theme ? opts.theme : null;\n\n opts.bound = !!(opts.bound !== undefined ? opts.field && opts.bound : opts.field);\n\n opts.trigger = (opts.trigger && opts.trigger.nodeName) ? opts.trigger : opts.field;\n\n opts.disableWeekends = !!opts.disableWeekends;\n\n opts.disableDayFn = (typeof opts.disableDayFn) === 'function' ? opts.disableDayFn : null;\n\n var nom = parseInt(opts.numberOfMonths, 10) || 1;\n opts.numberOfMonths = nom > 4 ? 4 : nom;\n\n if (!isDate(opts.minDate)) {\n opts.minDate = false;\n }\n if (!isDate(opts.maxDate)) {\n opts.maxDate = false;\n }\n if ((opts.minDate && opts.maxDate) && opts.maxDate < opts.minDate) {\n opts.maxDate = opts.minDate = false;\n }\n if (opts.minDate) {\n this.setMinDate(opts.minDate);\n }\n if (opts.maxDate) {\n this.setMaxDate(opts.maxDate);\n }\n\n if (isArray(opts.yearRange)) {\n var fallback = new Date().getFullYear() - 10;\n opts.yearRange[0] = parseInt(opts.yearRange[0], 10) || fallback;\n opts.yearRange[1] = parseInt(opts.yearRange[1], 10) || fallback;\n } else {\n opts.yearRange = Math.abs(parseInt(opts.yearRange, 10)) || defaults.yearRange;\n if (opts.yearRange > 100) {\n opts.yearRange = 100;\n }\n }\n\n return opts;\n },\n\n /**\n * return a formatted string of the current selection (using Moment.js if available)\n */\n toString: function(format)\n {\n format = format || this._o.format;\n if (!isDate(this._d)) {\n return '';\n }\n if (this._o.toString) {\n return this._o.toString(this._d, format);\n }\n if (hasMoment) {\n return moment(this._d).format(format);\n }\n return this._d.toDateString();\n },\n\n /**\n * return a Moment.js object of the current selection (if available)\n */\n getMoment: function()\n {\n return hasMoment ? moment(this._d) : null;\n },\n\n /**\n * set the current selection from a Moment.js object (if available)\n */\n setMoment: function(date, preventOnSelect)\n {\n if (hasMoment && moment.isMoment(date)) {\n this.setDate(date.toDate(), preventOnSelect);\n }\n },\n\n /**\n * return a Date object of the current selection\n */\n getDate: function()\n {\n return isDate(this._d) ? new Date(this._d.getTime()) : null;\n },\n\n /**\n * set the current selection\n */\n setDate: function(date, preventOnSelect)\n {\n if (!date) {\n this._d = null;\n\n if (this._o.field) {\n this._o.field.value = '';\n fireEvent(this._o.field, 'change', { firedBy: this });\n }\n\n return this.draw();\n }\n if (typeof date === 'string') {\n date = new Date(Date.parse(date));\n }\n if (!isDate(date)) {\n return;\n }\n\n var min = this._o.minDate,\n max = this._o.maxDate;\n\n if (isDate(min) && date < min) {\n date = min;\n } else if (isDate(max) && date > max) {\n date = max;\n }\n\n this._d = new Date(date.getTime());\n setToStartOfDay(this._d);\n this.gotoDate(this._d);\n\n if (this._o.field) {\n this._o.field.value = this.toString();\n fireEvent(this._o.field, 'change', { firedBy: this });\n }\n if (!preventOnSelect && typeof this._o.onSelect === 'function') {\n this._o.onSelect.call(this, this.getDate());\n }\n },\n\n /**\n * change view to a specific date\n */\n gotoDate: function(date)\n {\n var newCalendar = true;\n\n if (!isDate(date)) {\n return;\n }\n\n if (this.calendars) {\n var firstVisibleDate = new Date(this.calendars[0].year, this.calendars[0].month, 1),\n lastVisibleDate = new Date(this.calendars[this.calendars.length-1].year, this.calendars[this.calendars.length-1].month, 1),\n visibleDate = date.getTime();\n // get the end of the month\n lastVisibleDate.setMonth(lastVisibleDate.getMonth()+1);\n lastVisibleDate.setDate(lastVisibleDate.getDate()-1);\n newCalendar = (visibleDate < firstVisibleDate.getTime() || lastVisibleDate.getTime() < visibleDate);\n }\n\n if (newCalendar) {\n this.calendars = [{\n month: date.getMonth(),\n year: date.getFullYear()\n }];\n if (this._o.mainCalendar === 'right') {\n this.calendars[0].month += 1 - this._o.numberOfMonths;\n }\n }\n\n this.adjustCalendars();\n },\n\n adjustDate: function(sign, days) {\n\n var day = this.getDate() || new Date();\n var difference = parseInt(days)*24*60*60*1000;\n\n var newDay;\n\n if (sign === 'add') {\n newDay = new Date(day.valueOf() + difference);\n } else if (sign === 'subtract') {\n newDay = new Date(day.valueOf() - difference);\n }\n\n this.setDate(newDay);\n },\n\n adjustCalendars: function() {\n this.calendars[0] = adjustCalendar(this.calendars[0]);\n for (var c = 1; c < this._o.numberOfMonths; c++) {\n this.calendars[c] = adjustCalendar({\n month: this.calendars[0].month + c,\n year: this.calendars[0].year\n });\n }\n this.draw();\n },\n\n gotoToday: function()\n {\n this.gotoDate(new Date());\n },\n\n /**\n * change view to a specific month (zero-index, e.g. 0: January)\n */\n gotoMonth: function(month)\n {\n if (!isNaN(month)) {\n this.calendars[0].month = parseInt(month, 10);\n this.adjustCalendars();\n }\n },\n\n nextMonth: function()\n {\n this.calendars[0].month++;\n this.adjustCalendars();\n },\n\n prevMonth: function()\n {\n this.calendars[0].month--;\n this.adjustCalendars();\n },\n\n /**\n * change view to a specific full year (e.g. \"2012\")\n */\n gotoYear: function(year)\n {\n if (!isNaN(year)) {\n this.calendars[0].year = parseInt(year, 10);\n this.adjustCalendars();\n }\n },\n\n /**\n * change the minDate\n */\n setMinDate: function(value)\n {\n if(value instanceof Date) {\n setToStartOfDay(value);\n this._o.minDate = value;\n this._o.minYear = value.getFullYear();\n this._o.minMonth = value.getMonth();\n } else {\n this._o.minDate = defaults.minDate;\n this._o.minYear = defaults.minYear;\n this._o.minMonth = defaults.minMonth;\n this._o.startRange = defaults.startRange;\n }\n\n this.draw();\n },\n\n /**\n * change the maxDate\n */\n setMaxDate: function(value)\n {\n if(value instanceof Date) {\n setToStartOfDay(value);\n this._o.maxDate = value;\n this._o.maxYear = value.getFullYear();\n this._o.maxMonth = value.getMonth();\n } else {\n this._o.maxDate = defaults.maxDate;\n this._o.maxYear = defaults.maxYear;\n this._o.maxMonth = defaults.maxMonth;\n this._o.endRange = defaults.endRange;\n }\n\n this.draw();\n },\n\n setStartRange: function(value)\n {\n this._o.startRange = value;\n },\n\n setEndRange: function(value)\n {\n this._o.endRange = value;\n },\n\n /**\n * refresh the HTML\n */\n draw: function(force)\n {\n if (!this._v && !force) {\n return;\n }\n var opts = this._o,\n minYear = opts.minYear,\n maxYear = opts.maxYear,\n minMonth = opts.minMonth,\n maxMonth = opts.maxMonth,\n html = '',\n randId;\n\n if (this._y <= minYear) {\n this._y = minYear;\n if (!isNaN(minMonth) && this._m < minMonth) {\n this._m = minMonth;\n }\n }\n if (this._y >= maxYear) {\n this._y = maxYear;\n if (!isNaN(maxMonth) && this._m > maxMonth) {\n this._m = maxMonth;\n }\n }\n\n randId = 'pika-title-' + Math.random().toString(36).replace(/[^a-z]+/g, '').substr(0, 2);\n\n for (var c = 0; c < opts.numberOfMonths; c++) {\n html += '
' + renderTitle(this, c, this.calendars[c].year, this.calendars[c].month, this.calendars[0].year, randId) + this.render(this.calendars[c].year, this.calendars[c].month, randId) + '
';\n }\n\n this.el.innerHTML = html;\n\n if (opts.bound) {\n if(opts.field.type !== 'hidden') {\n sto(function() {\n opts.trigger.focus();\n }, 1);\n }\n }\n\n if (typeof this._o.onDraw === 'function') {\n this._o.onDraw(this);\n }\n\n if (opts.bound) {\n // let the screen reader user know to use arrow keys\n opts.field.setAttribute('aria-label', opts.ariaLabel);\n }\n },\n\n adjustPosition: function()\n {\n var field, pEl, width, height, viewportWidth, viewportHeight, scrollTop, left, top, clientRect, leftAligned, bottomAligned;\n\n if (this._o.container) return;\n\n this.el.style.position = 'absolute';\n\n field = this._o.trigger;\n pEl = field;\n width = this.el.offsetWidth;\n height = this.el.offsetHeight;\n viewportWidth = window.innerWidth || document.documentElement.clientWidth;\n viewportHeight = window.innerHeight || document.documentElement.clientHeight;\n scrollTop = window.pageYOffset || document.body.scrollTop || document.documentElement.scrollTop;\n leftAligned = true;\n bottomAligned = true;\n\n if (typeof field.getBoundingClientRect === 'function') {\n clientRect = field.getBoundingClientRect();\n left = clientRect.left + window.pageXOffset;\n top = clientRect.bottom + window.pageYOffset;\n } else {\n left = pEl.offsetLeft;\n top = pEl.offsetTop + pEl.offsetHeight;\n while((pEl = pEl.offsetParent)) {\n left += pEl.offsetLeft;\n top += pEl.offsetTop;\n }\n }\n\n // default position is bottom & left\n if ((this._o.reposition && left + width > viewportWidth) ||\n (\n this._o.position.indexOf('right') > -1 &&\n left - width + field.offsetWidth > 0\n )\n ) {\n left = left - width + field.offsetWidth;\n leftAligned = false;\n }\n if ((this._o.reposition && top + height > viewportHeight + scrollTop) ||\n (\n this._o.position.indexOf('top') > -1 &&\n top - height - field.offsetHeight > 0\n )\n ) {\n top = top - height - field.offsetHeight;\n bottomAligned = false;\n }\n\n this.el.style.left = left + 'px';\n this.el.style.top = top + 'px';\n\n addClass(this.el, leftAligned ? 'left-aligned' : 'right-aligned');\n addClass(this.el, bottomAligned ? 'bottom-aligned' : 'top-aligned');\n removeClass(this.el, !leftAligned ? 'left-aligned' : 'right-aligned');\n removeClass(this.el, !bottomAligned ? 'bottom-aligned' : 'top-aligned');\n },\n\n /**\n * render HTML for a particular month\n */\n render: function(year, month, randId)\n {\n var opts = this._o,\n now = new Date(),\n days = getDaysInMonth(year, month),\n before = new Date(year, month, 1).getDay(),\n data = [],\n row = [];\n setToStartOfDay(now);\n if (opts.firstDay > 0) {\n before -= opts.firstDay;\n if (before < 0) {\n before += 7;\n }\n }\n var previousMonth = month === 0 ? 11 : month - 1,\n nextMonth = month === 11 ? 0 : month + 1,\n yearOfPreviousMonth = month === 0 ? year - 1 : year,\n yearOfNextMonth = month === 11 ? year + 1 : year,\n daysInPreviousMonth = getDaysInMonth(yearOfPreviousMonth, previousMonth);\n var cells = days + before,\n after = cells;\n while(after > 7) {\n after -= 7;\n }\n cells += 7 - after;\n var isWeekSelected = false;\n for (var i = 0, r = 0; i < cells; i++)\n {\n var day = new Date(year, month, 1 + (i - before)),\n isSelected = isDate(this._d) ? compareDates(day, this._d) : false,\n isToday = compareDates(day, now),\n hasEvent = opts.events.indexOf(day.toDateString()) !== -1 ? true : false,\n isEmpty = i < before || i >= (days + before),\n dayNumber = 1 + (i - before),\n monthNumber = month,\n yearNumber = year,\n isStartRange = opts.startRange && compareDates(opts.startRange, day),\n isEndRange = opts.endRange && compareDates(opts.endRange, day),\n isInRange = opts.startRange && opts.endRange && opts.startRange < day && day < opts.endRange,\n isDisabled = (opts.minDate && day < opts.minDate) ||\n (opts.maxDate && day > opts.maxDate) ||\n (opts.disableWeekends && isWeekend(day)) ||\n (opts.disableDayFn && opts.disableDayFn(day));\n\n if (isEmpty) {\n if (i < before) {\n dayNumber = daysInPreviousMonth + dayNumber;\n monthNumber = previousMonth;\n yearNumber = yearOfPreviousMonth;\n } else {\n dayNumber = dayNumber - days;\n monthNumber = nextMonth;\n yearNumber = yearOfNextMonth;\n }\n }\n\n var dayConfig = {\n day: dayNumber,\n month: monthNumber,\n year: yearNumber,\n hasEvent: hasEvent,\n isSelected: isSelected,\n isToday: isToday,\n isDisabled: isDisabled,\n isEmpty: isEmpty,\n isStartRange: isStartRange,\n isEndRange: isEndRange,\n isInRange: isInRange,\n showDaysInNextAndPreviousMonths: opts.showDaysInNextAndPreviousMonths,\n enableSelectionDaysInNextAndPreviousMonths: opts.enableSelectionDaysInNextAndPreviousMonths\n };\n\n if (opts.pickWholeWeek && isSelected) {\n isWeekSelected = true;\n }\n\n row.push(renderDay(dayConfig));\n\n if (++r === 7) {\n if (opts.showWeekNumber) {\n row.unshift(renderWeek(i - before, month, year));\n }\n data.push(renderRow(row, opts.isRTL, opts.pickWholeWeek, isWeekSelected));\n row = [];\n r = 0;\n isWeekSelected = false;\n }\n }\n return renderTable(opts, data, randId);\n },\n\n isVisible: function()\n {\n return this._v;\n },\n\n show: function()\n {\n if (!this.isVisible()) {\n this._v = true;\n this.draw();\n removeClass(this.el, 'is-hidden');\n if (this._o.bound) {\n addEvent(document, 'click', this._onClick);\n this.adjustPosition();\n }\n if (typeof this._o.onOpen === 'function') {\n this._o.onOpen.call(this);\n }\n }\n },\n\n hide: function()\n {\n var v = this._v;\n if (v !== false) {\n if (this._o.bound) {\n removeEvent(document, 'click', this._onClick);\n }\n this.el.style.position = 'static'; // reset\n this.el.style.left = 'auto';\n this.el.style.top = 'auto';\n addClass(this.el, 'is-hidden');\n this._v = false;\n if (v !== undefined && typeof this._o.onClose === 'function') {\n this._o.onClose.call(this);\n }\n }\n },\n\n /**\n * GAME OVER\n */\n destroy: function()\n {\n var opts = this._o;\n\n this.hide();\n removeEvent(this.el, 'mousedown', this._onMouseDown, true);\n removeEvent(this.el, 'touchend', this._onMouseDown, true);\n removeEvent(this.el, 'change', this._onChange);\n if (opts.keyboardInput) {\n removeEvent(document, 'keydown', this._onKeyChange);\n }\n if (opts.field) {\n removeEvent(opts.field, 'change', this._onInputChange);\n if (opts.bound) {\n removeEvent(opts.trigger, 'click', this._onInputClick);\n removeEvent(opts.trigger, 'focus', this._onInputFocus);\n removeEvent(opts.trigger, 'blur', this._onInputBlur);\n }\n }\n if (this.el.parentNode) {\n this.el.parentNode.removeChild(this.el);\n }\n }\n\n };\n\n return Pikaday;\n}));\n"],"sourceRoot":""}