Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
removed old crap from select.component + can now use select with prim…
…itive values
- Loading branch information
Showing
16 changed files
with
73 additions
and
73 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,17 @@ | ||
<h1>ec-select</h1> | ||
|
||
<h3>Default</h3> | ||
<ec-select [list]="products" [config]="products.config" #ecSelect></ec-select> | ||
<pre><code>{{ecSelect.selection.getValue() | json}}</code></pre> | ||
<ec-select [list]="products" [(ngModel)]="values"></ec-select> | ||
<pre><code>{{values | json}}</code></pre> | ||
|
||
<h3>Solo</h3> | ||
<ec-select [list]="products" [config]="products.config" [solo]="true" #ecSelectSolo></ec-select> | ||
<pre><code>{{ecSelectSolo.selection.getValue() | json}}</code></pre> | ||
<ec-select [list]="products" [solo]="true" #ecSelectSolo></ec-select> | ||
<pre><code>{{ecSelectSolo.selection.getValue() | json}}</code></pre> | ||
|
||
<h3>Primitive Solo</h3> | ||
<ec-select [values]="['one','two','three']" #primitiveSelectSolo [solo]="true"></ec-select> | ||
<pre><code>{{primitiveSelectSolo.selection.getValue() | json}}</code></pre> | ||
|
||
<h3>Primitive</h3> | ||
<ec-select [values]="['one','two','three']" #primitiveSelect></ec-select> | ||
<pre><code>{{primitiveSelect.selection.getValue() | json}}</code></pre> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,18 +1,24 @@ | ||
<ec-pagination [pagination]="list?.pagination" | ||
*ngIf="list?.pagination?.getPages()>1"></ec-pagination> | ||
<div class="ec-list"> | ||
<ec-list-header [list]="list" [selection]="selection"></ec-list-header> | ||
<ec-list-header [list]="list" [selection]="selection" | ||
*ngIf="list?.fields.length||list?.config.title"></ec-list-header> | ||
|
||
<div class="ec-list-body"> | ||
<div class="ec-list-group" *ngFor="let group of list?.groups"> | ||
<div class="ec-list-group-header ec-list__row" *ngIf="group.value" (click)="selection?.toggleAll(listItems?.items)"> | ||
<div class="ec-list__cell ec-list__select" *ngIf="selection"><input type="checkbox" [checked]="selection?.hasAll(listItems?.items)"></div> | ||
<div class="ec-list-group-header ec-list__row" *ngIf="group.value" | ||
(click)="selection?.toggleAll(listItems?.items)"> | ||
<div class="ec-list__cell ec-list__select" *ngIf="selection"><input type="checkbox" | ||
[checked]="selection?.hasAll(listItems?.items)"> | ||
</div> | ||
<div class="ec-list__cell"> | ||
<span class="ec-list-group-header__title">{{group.value}}</span> | ||
</div> | ||
</div> | ||
<ec-list-items [host]="this" #listItems [items]="list?.page | group: group.property: group.value"></ec-list-items> | ||
<ec-list-items [host]="this" #listItems | ||
[items]="list?.page | group: group.property: group.value"></ec-list-items> | ||
</div> | ||
</div> | ||
</div> | ||
<ec-pagination [pagination]="list?.pagination" *ngIf="list?.pagination?.getPages()>1"></ec-pagination> | ||
<ec-pagination [pagination]="list?.pagination" | ||
*ngIf="list?.pagination?.getPages()>1"></ec-pagination> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,14 @@ | ||
<div class="ec-select" *ngIf="selection&&list"> | ||
<a (click)="toggle(!active,true)" class="ec-select__placeholder"> | ||
<a (click)="pop.toggle()" class="ec-select__placeholder"> | ||
- Auswählen -- | ||
</a> | ||
<div class="ec-select-selected"> | ||
<li *ngFor="let selected of selection.items" class="pill" (click)="clickItem(selected)"> | ||
{{selected.display()}} <a (click)="removeItem(selected)">×</a> | ||
{{selected.display()}} <a (click)="selection.remove(selected)">×</a> | ||
</li> | ||
</div> | ||
<span class="caret"></span> | ||
<ec-pop> | ||
<ec-list [list]="list" [selection]="selection"></ec-list> | ||
<ec-list [list]="list" (select)="select($event)" [selection]="selection"></ec-list> | ||
</ec-pop> | ||
</div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters