Strange angular-ui datepicker dependency error Strange angular-ui datepicker dependency error angularjs angularjs

Strange angular-ui datepicker dependency error


I had this error updating to ui.bootstrap 0.14.x.

I had overwritten the templates in own modules which caused the problems:

    angular.module("template/datepicker/datepicker.html", []).run(["$templateCache", function ($templateCache) {    $templateCache.put("template/datepicker/datepicker.html",      "<div ng-switch=\"datepickerMode\" role=\"application\" ng-keydown=\"keydown($event)\">\n" +      "  <daypicker ng-switch-when=\"day\" tabindex=\"0\"></daypicker>\n" +      "  <monthpicker ng-switch-when=\"month\" tabindex=\"0\"></monthpicker>\n" +      "  <yearpicker ng-switch-when=\"year\" tabindex=\"0\"></yearpicker>\n" +      "</div>");    }]);

After removing the modules it worked again.

Originally I had changed the templates for using font-awesome icons instead of glyphicons. Now I override the glyphicon css class to change to font-awesome icons:

.glyphicon {    font: normal normal normal 14px/1 ourIconFont;}.glyphicon-arrow-right:before,.glyphicon-chevron-right:before {    content: "\f054";}.glyphicon-arrow-left:before,.glyphicon-chevron-left:before {    content: "\f053";}


You need to update your ui.bootstrap.0.12.0.js to ui-bootstrap-tpls-0.13.3.js


Had the same issue, our solution was that after upgrading to uib 0.14 we had a custom template for datepicker and had to add the uib- prefixes to the child directives inside the datepicker (day, month year). e.g.

<div ng-switch="datepickerMode" role="application" ng-keydown="keydown($event)">  <daypicker ng-switch-when="day" tabindex="0"></daypicker>  <monthpicker ng-switch-when="month" tabindex="0"></monthpicker>  <yearpicker ng-switch-when="year" tabindex="0"></yearpicker></div>

Changed to

<div ng-switch="datepickerMode" role="application" ng-keydown="keydown($event)">  <uib-daypicker ng-switch-when="day" tabindex="0"></uib-daypicker>  <uib-monthpicker ng-switch-when="month" tabindex="0"></uib-monthpicker>  <uib-yearpicker ng-switch-when="year" tabindex="0"></uib-yearpicker></div>