1
- < ng-template #labelTemplate >
1
+ <!-- < ng-template #labelTemplate>
2
2
<ng-content select="[igxLabel]"></ng-content>
3
- </ ng-template >
3
+ </ng-template> -->
4
4
5
- < ng-template #dropdownInputTemplate >
5
+ <!-- < ng-template #dropdownInputTemplate>
6
6
<igx-input-group #group (mousedown)="mouseDown($event)" [suppressInputAutofocus]="true">
7
7
<label igxLabel *ngIf="!labelDirective">Time</label>
8
8
<ng-container ngProjectAs="[igxLabel]" *ngTemplateOutlet="labelTemplate"></ng-container>
9
- < igx-prefix (click) ="openDialog(group.element.nativeElement ) ">
9
+ <igx-prefix (click)="open( )">
10
10
<igx-icon>access_time</igx-icon>
11
11
</igx-prefix>
12
- < input
13
- type ="text "
14
- [igxMask] ="mask "
15
- igxInput
16
- [includeLiterals] ="true "
17
- [placeholder] ="format "
18
- [displayValuePipe] ="displayFormat "
19
- [focusedValuePipe] ="inputFormat "
20
- [promptChar] ="promptChar "
21
- [value] ="displayValue "
22
- [igxTextSelection] ="true "
23
- (input) ="onInput($event) "
24
- (blur) ="onBlur($event) "
25
- (focus) ="onFocus($event) "
26
- (wheel) ="spinOnEdit($event) "
27
- [disabled] ="disabled " />
12
+ <input type="text" [igxMask]="mask" igxInput
13
+ [includeLiterals]="true" [placeholder]="format"
14
+ [displayValuePipe]="displayFormat" [focusedValuePipe]="inputFormat" [promptChar]="promptChar"
15
+ [value]="displayValue" [igxTextSelection]="true" (input)="onInput($event)" (blur)="onBlur($event)"
16
+ (focus)="onFocus($event)" (wheel)="spinOnEdit($event)" [disabled]="disabled" />
28
17
<igx-suffix *ngIf="showClearButton" igxRipple (click)="clear()">
29
18
<igx-icon fontSet="material">clear</igx-icon>
30
19
</igx-suffix>
31
20
</igx-input-group>
32
- </ ng-template >
33
- < ng-template #defaultTimePickerTemplate >
34
- < igx-input-group (click) ="openDialog() " (mousedown) ="mouseDown($event) ">
21
+ </ng-template> -->
22
+
23
+ <!-- <ng-template #defaultTimePickerTemplate>
24
+ <igx-input-group (click)="open()" (mousedown)="mouseDown($event)">
35
25
<igx-prefix>
36
26
<igx-icon>access_time</igx-icon>
37
27
</igx-prefix>
44
34
tabindex="0" readonly
45
35
(blur)="onBlur($event)" />
46
36
</igx-input-group>
37
+ </ng-template> -->
38
+ <!-- [igxTextSelection]="true" -->
39
+
40
+ <!-- (mousedown)="mouseDown($event)" -->
41
+ < igx-input-group [suppressInputAutofocus] ="this.isDropdown " (click) ="!this.isDropdown && open() ">
42
+ < input igxInput [igxDateTimeEditor] ="this.inputFormat " type ="text "
43
+ [readonly] ="!this.isDropdown " tabindex ="0 "
44
+ [value] ="this.value "
45
+ [displayFormat] ="this.displayFormat "
46
+ [placeholder] ="this.placeholder "
47
+ role ="combobox " aria-haspopup ="dialog "
48
+ [attr.aria-expanded] ="!toggle.collapsed "
49
+ [attr.aria-labelledby] ="this.label?.id "
50
+ (wheel) ="spinOnEdit($event) "
51
+ />
52
+
53
+ < igx-prefix *ngIf ="!this.toggleComponents.length " (click) ="open() ">
54
+ < ng-container *ngTemplateOutlet ="defaultToggleIcon "> </ ng-container >
55
+ </ igx-prefix >
56
+
57
+ < igx-suffix *ngIf ="showClearButton " igxRipple (click) ="clear() ">
58
+ < ng-container *ngTemplateOutlet ="defaultClearIcon "> </ ng-container >
59
+ </ igx-suffix >
60
+
61
+ < ng-container ngProjectAs ="[igxLabel] ">
62
+ < ng-content select ="[igxLabel] "> </ ng-content >
63
+ </ ng-container >
64
+ < ng-container ngProjectAs ="igx-prefix ">
65
+ < ng-content select ="igx-prefix,[igxPrefix] "> </ ng-content >
66
+ </ ng-container >
67
+ < ng-container ngProjectAs ="igx-suffix ">
68
+ < ng-content select ="igx-suffix,[igxSuffix] "> </ ng-content >
69
+ </ ng-container >
70
+ < ng-container ngProjectAs ="igx-hint ">
71
+ < ng-content select ="igx-hint,[igxHint] "> </ ng-content >
72
+ </ ng-container >
73
+ </ igx-input-group >
74
+
75
+
76
+ < ng-template #defaultToggleIcon >
77
+ < igx-icon fontSet ="material ">
78
+ access_time
79
+ </ igx-icon >
47
80
</ ng-template >
48
- < ng-container *ngTemplateOutlet ="template; context: context "> </ ng-container >
81
+
82
+ < ng-template #defaultClearIcon >
83
+ < igx-icon fontSet ="material ">
84
+ clear
85
+ </ igx-icon >
86
+ </ ng-template >
87
+
88
+ <!-- <ng-container *ngTemplateOutlet="template; context: context"></ng-container> -->
49
89
50
90
< ng-template #defaultTimePickerActions >
51
91
< div *ngIf ="cancelButtonLabel || okButtonLabel " class ="igx-time-picker__buttons ">
57
97
</ button >
58
98
</ div >
59
99
</ ng-template >
60
- < div igxToggle class ="igx-time-picker "
61
- [ngClass] ="{'igx-time-picker--dropdown': mode === 'dropdown', 'igx-time-picker--vertical': vertical && mode === 'dialog'} ">
62
- < div *ngIf ="mode === 'dialog' " class ="igx-time-picker__header ">
100
+
101
+
102
+ < div #toggle ="toggle " igxToggle class ="igx-time-picker "
103
+ [ngClass] ="{'igx-time-picker--dropdown': this.isDropdown, 'igx-time-picker--vertical': vertical && !this.isDropdown} ">
104
+ < div *ngIf ="!this.isDropdown " class ="igx-time-picker__header ">
63
105
< h5 class ="igx-time-picker__header-ampm "> {{ selectedAmPm }}</ h5 >
64
106
< h2 class ="igx-time-picker__header-hour ">
65
107
< span > {{ selectedHour }}</ span > :< span > {{ selectedMinute }}</ span > :< span > {{ selectedSeconds }}</ span >
@@ -69,27 +111,27 @@ <h2 class="igx-time-picker__header-hour">
69
111
< div class ="igx-time-picker__body ">
70
112
< div *ngIf ="showHoursList " #hourList [igxItemList] ="'hourList' ">
71
113
< span [igxHourItem] ="hour "
72
- [ngClass] ="{'igx-time-picker__item--disabled': applyDisabledStyleForItem(timeParts.Hour, hour)} "
73
- *ngFor ="let hour of hourView "> {{ hour }}</ span >
114
+ [ngClass] ="{'igx-time-picker__item--disabled': applyDisabledStyleForItem(timeParts.Hour, hour)} "
115
+ *ngFor ="let hour of hourView "> {{ hour }}</ span >
74
116
</ div >
75
117
< div *ngIf ="showMinutesList " #minuteList [igxItemList] ="'minuteList' ">
76
118
< span [igxMinuteItem] ="minute "
77
- [ngClass] ="{'igx-time-picker__item--disabled': applyDisabledStyleForItem(timeParts.Minute, minute)} "
78
- *ngFor ="let minute of minuteView " > {{ minute }}</ span >
119
+ [ngClass] ="{'igx-time-picker__item--disabled': applyDisabledStyleForItem(timeParts.Minute, minute)} "
120
+ *ngFor ="let minute of minuteView "> {{ minute }}</ span >
79
121
</ div >
80
122
< div *ngIf ="showSecondsList " #secondsList [igxItemList] ="'secondsList' ">
81
123
< span [igxSecondsItem] ="seconds "
82
- [ngClass] ="{'igx-time-picker__item--disabled': applyDisabledStyleForItem(timeParts.Seconds, seconds)} "
83
- *ngFor ="let seconds of secondsView "> {{ seconds }}</ span >
124
+ [ngClass] ="{'igx-time-picker__item--disabled': applyDisabledStyleForItem(timeParts.Seconds, seconds)} "
125
+ *ngFor ="let seconds of secondsView "> {{ seconds }}</ span >
84
126
</ div >
85
127
< div *ngIf ="showAmPmList " #ampmList [igxItemList] ="'ampmList' ">
86
128
< span [igxAmPmItem] ="ampm "
87
- [ngClass] ="{'igx-time-picker__item--disabled': applyDisabledStyleForItem(timeParts.AMPM, ampm)} "
88
- *ngFor ="let ampm of ampmView "> {{ ampm }}</ span >
129
+ [ngClass] ="{'igx-time-picker__item--disabled': applyDisabledStyleForItem(timeParts.AMPM, ampm)} "
130
+ *ngFor ="let ampm of ampmView "> {{ ampm }}</ span >
89
131
</ div >
90
132
</ div >
91
133
< ng-container
92
134
*ngTemplateOutlet ="timePickerActionsDirective ? timePickerActionsDirective.template : defaultTimePickerActions ">
93
135
</ ng-container >
94
136
</ div >
95
- </ div >
137
+ </ div >
0 commit comments