File tree Expand file tree Collapse file tree 3 files changed +15
-4
lines changed Expand file tree Collapse file tree 3 files changed +15
-4
lines changed Original file line number Diff line number Diff line change @@ -175,7 +175,7 @@ <h2>Datetime Pickers</h2>
175175 < div layout-gt-md ="row " layout ="column " layout-align-gt-md ="center center ">
176176 < div layout ="row " flex-gt-md ="30 " layout-align ="start center ">
177177 < md-input-container md-float >
178- < input type ="date " ng-model ="selectedDateTimeIn " id ="dateinput ">
178+ < input type ="date " ng-model ="selectedDateTimeIn " id ="dateinput " aria-label =" date picker " >
179179 </ md-input-container >
180180 < md-button class ="md-primary md-icon-button " style ="top:-12px;left:-12px; " ng-click ="displayDialogIn() ">
181181 < md-icon class ="material-icons "> today</ md-icon >
Original file line number Diff line number Diff line change 11( function ( ) {
22 'use strict' ;
3+
4+ function ngMaterialDatePicker ( moment ) {
35 var moduleName = "ngMaterialDatePicker" ;
46
57 var VIEW_STATES = {
10551057 }
10561058 } ;
10571059 } ] ) ;
1058-
1060+ }
1061+
1062+ var isElectron = window && window . process && window . process . type ;
1063+ if ( typeof define === 'function' && define . amd ) {
1064+ define ( [ 'moment' ] , ngMaterialDatePicker ) ;
1065+ } else if ( typeof module !== 'undefined' && module && module . exports && ( typeof require === 'function' ) && ! isElectron ) {
1066+ module . exports = ngMaterialDatePicker ( require ( 'moment' ) ) ;
1067+ } else {
1068+ ngMaterialDatePicker ( ( typeof global !== 'undefined' ? global : window ) . moment ) ;
1069+ }
10591070} ) ( ) ;
Original file line number Diff line number Diff line change 5050 . then ( function ( date ) {
5151 $scope . selectedDateTime = date ;
5252 console . log ( 'New Date / Time selected:' , date ) ;
53- } ) ;
53+ } , function ( ) { } ) ;
5454 } ;
5555
5656 $scope . displayDialogIn = function ( ) {
6161 } )
6262 . then ( function ( date ) {
6363 $scope . selectedDateTimeIn = date ;
64- } ) ;
64+ } , function ( ) { } ) ;
6565 } ;
6666
6767 // Set and change the text direction
You can’t perform that action at this time.
0 commit comments