{"version":3,"sources":["mdPickers.min.js"],"names":["DatePickerCtrl","$scope","$mdDialog","$mdMedia","$timeout","currentDate","options","self","this","date","moment","minDate","isValid","maxDate","displayFormat","dateFilter","angular","isFunction","selectingYear","isBefore","add","isAfter","yearItems","currentIndex_","PAGE_SIZE","START","year","END","getItemAtIndex","index","getLength","Math","min","floor","abs","selectYear","animate","showYear","yearTopIndex","showCalendar","clear","hide","cancel","confirm","toDate","animating","noop","then","CalendarCtrl","$onInit","daysInMonth","dow","localeData","firstDayOfWeek","weekDays","concat","weekdaysMin","slice","$watch","unix","newValue","oldValue","updateDaysInMonth","getDaysInMonth","days","firstDay","day","length","arr","i","value","enabled","isDayEnabled","push","selectDate","dom","nextMonth","prevMonth","subtract","formatValidator","format","isDate","compareDateValidator","otherDate","comparator","minDateValidator","d","md","isSameOrAfter","maxDateValidator","isSameOrBefore","filterValidator","filter","TimePickerCtrl","time","autoSwitch","ampm","VIEW_HOURS","VIEW_MINUTES","currentView","hoursFormat","minutesFormat","clockHours","parseInt","clockMinutes","switchView","setAM","hours","hour","setPM","ClockCtrl","TYPE_HOURS","TYPE_MINUTES","STEP_DEG","steps","CLOCK_TYPES","range","minutes","type","f","t","selected","getPointerStyle","divider","degrees","round","-webkit-transform","-ms-transform","transform","setTimeByDeg","deg","setTime","compareTimeValidator","otherTime","minTimeValidator","minTime","mt","maxTimeValidator","maxTime","module","config","$mdIconProvider","mdpIconsRegistry","forEach","icon","id","url","run","$templateCache","put","svg","constant","factory","$mdpLocale","okLabel","cancelLabel","timeFormat","noFloat","openOnClick","clearOnCancel","dateFormat","directive","$mdUtil","restrict","priority","compile","element","inputContainer","getClosest","toggleClass","provider","LABEL_OK","LABEL_CANCEL","LABEL_CLEAR","DISPLAY_FORMAT","PARENT_GETTER","setDisplayFormat","setOKButtonLabel","label","setCancelButtonLabel","setClearButtonLabel","setDialogParentGetter","fn","$get","datePicker","Date","now","isObject","labelOk","labelCancel","labelClear","clearLabel","show","controller","controllerAs","clickOutsideToClose","template","targetEvent","locals","multiple","parent","$animate","bindToController","link","scope","attrs","ctrl","animElements","querySelector","map","a","raised","direction","addClass","removeClass","$mdpDatePicker","require","transclude","isDefined","mdpNoFloat","mdpOpenOnClick","mdpDisabled","placeholder","disabled","inputName","pre","constollers","$transclude","post","controllers","updateInputElement","inputElement","inputContainerCtrl","setHasValue","ngModel","$isEmpty","updateDate","strValue","$setViewValue","$pristine","messages","hasClass","$render","onInputElementEvents","event","target","$viewVaue","form","opts","clone","append","model","isError","$invalid","$submitted","required","$formatters","unshift","strVal","$validators","modelValue","viewValue","isUndefined","$parsers","parsed","$modelValue","originalModel","month","showPicker","ev","error","on","$on","off","$validate","replace","timepickerCtrl","$parent","timepicker","onEvent","containerCoords","currentTarget","getClientRects","x","offsetWidth","pageX","left","y","pageY","top","offsetHeight","atan2","PI","indexOf","e","timePicker","$mdpTimePicker","updateTime","undefined","$error","setInvalid","Object","keys","seconds"],"mappings":"CAAA,WACA,YAkGA,SAASA,GAAeC,EAAQC,EAAWC,EAAUC,EAAUC,EAAaC,GACxE,GAAIC,GAAOC,IAEXA,MAAKC,KAAOC,OAAOL,GACnBG,KAAKG,QAAUL,EAAQK,SAAWD,OAAOJ,EAAQK,SAASC,UAAYF,OAAOJ,EAAQK,SAAW,KAChGH,KAAKK,QAAUP,EAAQO,SAAWH,OAAOJ,EAAQO,SAASD,UAAYF,OAAOJ,EAAQO,SAAW,KAChGL,KAAKM,cAAgBR,EAAQQ,eAAiB,cAC9CN,KAAKO,WAAaC,QAAQC,WAAWX,EAAQS,YAAcT,EAAQS,WAAa,KAChFP,KAAKU,eAAgB,EAGjBV,KAAKG,SAAWH,KAAKK,SACjBL,KAAKK,QAAQM,SAASX,KAAKG,WAC3BH,KAAKK,QAAUH,OAAOF,KAAKG,SAASS,IAAI,EAAG,SAI/CZ,KAAKC,OAEDD,KAAKG,SAAWH,KAAKC,KAAKU,SAASX,KAAKG,WACxCH,KAAKC,KAAOC,OAAOF,KAAKG,UAIxBH,KA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,WAAa,SAASC,GACxB2B,EAAe9D,EAAQ+B,aACnBpE,YAAawE,EACbnH,QAASkD,EAAMlD,QACfC,YAAaiD,EAAMjD,YACnB5D,WAAY6G,EAAM7G,WAClBC,KAAM4G,EAAM5G,OACbjD,KAAK,SAAS+C,GACb2M,EAAW3M,GAAM,IAClB,SAAUgL,GACLtB,EAAKzF,eACL0I,EAAW,MAAM,MAU7BlE,EAAawC,GAAG,mBAAoB5B,GAEpCvC,EAAMoE,IAAI,WAAY,WAClBzC,EAAa0C,IAAI,mBAAoB9B,KAIzCvC,EAAMlJ,OAAO,oBAAqB,WAC9BgL,EAAQwC,mBAMxBvI,EAAOsB,UAAU,iBAAkB,iBAAkB,WAAY,SAASuI,EAAgBpS,GACtF,OACI+J,SAAU,IACVqD,QAAS,UACTZ,OACIhD,WAAc,aACdF,QAAW,eACXC,YAAe,mBACf5D,WAAc,kBACdC,KAAQ,aAEZ2G,KAAM,SAASC,EAAOtC,EAASuC,EAAO6B,EAASP,GAE3C,QAASyC,GAAWC,GAChB2B,EAAe9D,EAAQ+B,aACnBpE,YAAawE,EACb9K,WAAY6G,EAAM7G,WAClB2D,QAASkD,EAAMlD,QACfC,YAAaiD,EAAMjD,YACnB3D,KAAM4G,EAAM5G,OACbjD,KAAK,SAAS+C,GACb4I,EAAQI,cAAcpO,OAAOoF,GAAMd,OAAO4H,EAAM5H,SAChD0J,EAAQQ,YAVhBtC,EAAM5H,OAAS4H,EAAM5H,QAAU,QAc/BsF,EAAQyG,GAAG,QAASH,GAEpBhE,EAAMoE,IAAI,WAAY,WAClB1G,EAAQ2G,IAAI,QAASL","file":"mdPickers.min.js","sourcesContent":["(function() {\n\"use strict\";\n/* global moment, angular */\r\n\r\nvar module = angular.module(\"mdPickers\", [\r\n \"ngMaterial\",\r\n \"ngAnimate\",\r\n \"ngAria\"\r\n]);\r\n\r\nmodule.config([\"$mdIconProvider\", \"mdpIconsRegistry\", function($mdIconProvider, mdpIconsRegistry) {\r\n angular.forEach(mdpIconsRegistry, function(icon, index) {\r\n $mdIconProvider.icon(icon.id, icon.url);\r\n });\r\n}]);\r\n\r\nmodule.run([\"$templateCache\", \"mdpIconsRegistry\", function($templateCache, mdpIconsRegistry) {\r\n angular.forEach(mdpIconsRegistry, function(icon, index) {\r\n $templateCache.put(icon.url, icon.svg);\r\n });\r\n}]);\nmodule.constant(\"mdpIconsRegistry\", [\r\n {\r\n id: 'mdp-chevron-left',\r\n url: 'mdp-chevron-left.svg',\r\n svg: ''\r\n },\r\n {\r\n id: 'mdp-chevron-right',\r\n url: 'mdp-chevron-right.svg',\r\n svg: ''\r\n },\r\n {\r\n id: 'mdp-access-time',\r\n url: 'mdp-access-time.svg',\r\n svg: ''\r\n },\r\n {\r\n id: 'mdp-event',\r\n url: 'mdp-event.svg',\r\n svg: ''\r\n }\r\n]);\n/**\r\n * Created by Robin Thoni on 6/21/17.\r\n */\r\n\r\nmodule.factory('$mdpLocale', [function () {\r\n var $mdpLocale = {\r\n time: {\r\n minTime: null,\r\n maxTime: null,\r\n okLabel: \"OK\",\r\n cancelLabel: \"Cancel\",\r\n timeFormat: \"HH:mm\",\r\n noFloat: false,\r\n openOnClick: false,\r\n autoSwitch: false,\r\n ampm: true,\r\n clearOnCancel: false\r\n },\r\n date: {\r\n minDate: null,\r\n maxDate: null,\r\n okLabel: \"OK\",\r\n cancelLabel: \"Cancel\",\r\n dateFilter: null,\r\n dateFormat: \"YYYY-MM-DD\",\r\n displayFormat: \"ddd, MMM DD\",\r\n noFloat: false,\r\n openOnClick: false,\r\n clearOnCancel: false\r\n }\r\n };\r\n\r\n return $mdpLocale;\r\n}]);\r\n\nmodule.directive(\"ngMessage\", [\"$mdUtil\", function($mdUtil) {\r\n return {\r\n restrict: \"EA\",\r\n priority: 101,\r\n compile: function(element) {\r\n var inputContainer = $mdUtil.getClosest(element, \"mdp-time-picker\", true) ||\r\n $mdUtil.getClosest(element, \"mdp-date-picker\", true);\r\n\r\n // If we are not a child of an input container, don't do anything\r\n if (!inputContainer) return;\r\n\r\n // Add our animation class\r\n element.toggleClass('md-input-message-animation', true);\r\n\r\n return {};\r\n }\r\n }\r\n\r\n}]);\n/* global moment, angular */\r\n\r\nfunction DatePickerCtrl($scope, $mdDialog, $mdMedia, $timeout, currentDate, options) {\r\n var self = this;\r\n\r\n this.date = moment(currentDate);\r\n this.minDate = options.minDate && moment(options.minDate).isValid() ? moment(options.minDate) : null;\r\n this.maxDate = options.maxDate && moment(options.maxDate).isValid() ? moment(options.maxDate) : null;\r\n this.displayFormat = options.displayFormat || \"ddd, MMM DD\";\r\n this.dateFilter = angular.isFunction(options.dateFilter) ? options.dateFilter : null;\r\n this.selectingYear = false;\r\n\r\n // validate min and max date\r\n if (this.minDate && this.maxDate) {\r\n if (this.maxDate.isBefore(this.minDate)) {\r\n this.maxDate = moment(this.minDate).add(1, 'days');\r\n }\r\n }\r\n\r\n if (this.date) {\r\n // check min date\r\n if (this.minDate && this.date.isBefore(this.minDate)) {\r\n this.date = moment(this.minDate);\r\n }\r\n\r\n // check max date\r\n if (this.maxDate && this.date.isAfter(this.maxDate)) {\r\n this.date = moment(this.maxDate);\r\n }\r\n }\r\n\r\n this.yearItems = {\r\n currentIndex_: 0,\r\n PAGE_SIZE: 5,\r\n START: (self.minDate ? self.minDate.year() : 1900),\r\n END: (self.maxDate ? self.maxDate.year() : 0),\r\n getItemAtIndex: function(index) {\r\n if(this.currentIndex_ < index)\r\n this.currentIndex_ = index;\r\n\r\n return this.START + index;\r\n },\r\n getLength: function() {\r\n return Math.min(\r\n this.currentIndex_ + Math.floor(this.PAGE_SIZE / 2),\r\n Math.abs(this.START - this.END) + 1\r\n );\r\n }\r\n };\r\n\r\n $scope.$mdMedia = $mdMedia;\r\n $scope.year = this.date.year();\r\n\r\n this.selectYear = function(year) {\r\n self.date.year(year);\r\n $scope.year = year;\r\n self.selectingYear = false;\r\n self.animate();\r\n };\r\n\r\n this.showYear = function() {\r\n\r\n self.yearTopIndex = (self.date.year() - self.yearItems.START) + Math.floor(self.yearItems.PAGE_SIZE / 2);\r\n self.yearItems.currentIndex_ = (self.date.year() - self.yearItems.START) + 1;\r\n self.selectingYear = true;\r\n };\r\n\r\n this.showCalendar = function() {\r\n self.selectingYear = false;\r\n };\r\n\r\n this.clear = function () {\r\n var date = this.date;\r\n date = null;\r\n $mdDialog.hide(date);\r\n };\r\n\r\n this.cancel = function() {\r\n $mdDialog.cancel();\r\n };\r\n\r\n this.confirm = function() {\r\n var date = this.date;\r\n\r\n if (this.minDate && this.date.isBefore(this.minDate)) {\r\n date = moment(this.minDate);\r\n }\r\n\r\n if (this.maxDate && this.date.isAfter(this.maxDate)) {\r\n date = moment(this.maxDate);\r\n }\r\n\r\n $mdDialog.hide(date.toDate());\r\n };\r\n\r\n this.animate = function() {\r\n self.animating = true;\r\n $timeout(angular.noop).then(function() {\r\n self.animating = false;\r\n })\r\n\r\n };\r\n}\r\n\r\nmodule.provider(\"$mdpDatePicker\", function() {\r\n var LABEL_OK = \"OK\",\r\n LABEL_CANCEL = \"Cancel\",\r\n LABEL_CLEAR = \"Clear\",\r\n DISPLAY_FORMAT = \"ddd, MMM DD\",\r\n PARENT_GETTER = function() { return undefined };\r\n\r\n this.setDisplayFormat = function(format) {\r\n DISPLAY_FORMAT = format;\r\n\r\n };\r\n\r\n this.setOKButtonLabel = function(label) {\r\n LABEL_OK = label;\r\n };\r\n\r\n this.setCancelButtonLabel = function(label) {\r\n LABEL_CANCEL = label;\r\n };\r\n\r\n this.setClearButtonLabel = function (label) {\r\n LABEL_CLEAR = label;\r\n };\r\n \r\n this.setDialogParentGetter = function(fn) {\r\n PARENT_GETTER = fn;\r\n };\r\n\r\n this.$get = [\"$mdDialog\", \"$mdpLocale\", function($mdDialog, $mdpLocale) {\r\n var datePicker = function(currentDate, options) {\r\n if (!angular.isDate(currentDate)) currentDate = Date.now();\r\n if (!angular.isObject(options)) options = {};\r\n\r\n options.displayFormat = options.displayFormat || $mdpLocale.date.displayFormat || DISPLAY_FORMAT;\r\n\r\n var labelOk = options.okLabel || $mdpLocale.date.okLabel || LABEL_OK;\r\n var labelCancel = options.cancelLabel || $mdpLocale.date.cancelLabel || LABEL_CANCEL;\r\n var labelClear = options.clearLabel || $mdpLocale.date.clearLabel || LABEL_CLEAR;\r\n\r\n return $mdDialog.show({\r\n controller: ['$scope', '$mdDialog', '$mdMedia', '$timeout', 'currentDate', 'options', DatePickerCtrl],\r\n controllerAs: 'datepicker',\r\n clickOutsideToClose: true,\r\n template: '