-
Notifications
You must be signed in to change notification settings - Fork 357
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(chips): ability to disable chip addition (input). (closes #500) #547
Changes from 12 commits
9b1fbd0
1d19cde
4c5d6ba
43bb340
bcb3145
f55d200
fc1e306
61d029e
fd1d598
e5a3cf2
f13979a
296dd60
f9c8338
b9e084e
d661d1a
4e1fe5a
cfa7d62
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -9,6 +9,7 @@ | |
</md-icon> | ||
</md-basic-chip> | ||
</ng-template> | ||
<div *ngIf="allowAdd"> | ||
<md-input-container floatPlaceholder="never" | ||
[style.width.px]="readOnly ? 0 : null" | ||
[color]="matches ? 'primary' : 'warn'"> | ||
|
@@ -23,11 +24,13 @@ | |
(focus)="handleFocus()" | ||
(blur)="handleBlur()"> | ||
</md-input-container> | ||
|
||
<md-autocomplete #autocomplete="mdAutocomplete"> | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. There is a weird bug when you toggle the The fix is to put the e. g.
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. When I move the There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The alternative approach would be to change There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Yeah, I think it should use There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. cool thanks! |
||
<ng-template let-item ngFor [ngForOf]="filteredItems | async"> | ||
<md-option (click)="addChip(input.value)" [value]="item">{{item}}</md-option> | ||
</ng-template> | ||
</md-autocomplete> | ||
</div> | ||
</md-chip-list> | ||
<div class="mat-input-underline" | ||
[class.mat-disabled]="readOnly"> | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you add indentation for the content of the
<div *ngIf="allowAdd">
? 😄