|
2 | 2 | declare var $: any; // JQuery |
3 | 3 | declare var _: any; // lodash |
4 | 4 |
|
5 | | -require('./gridstack.component.html') |
6 | | - |
7 | 5 | @Component({ |
8 | 6 | selector: 'gridStack', |
9 | 7 | template: `<div> |
10 | | - < button * ngIf="addFunction"(click)="addItem()" class='{{buttonClass}}' > Ajouter une carte< /button> |
11 | | - < button * ngIf="saveFunction"(click)="savePanel()" class='btn-gridstack-save {{buttonClass}}' > Enregistrer le panneau< /button> |
12 | | - < button * ngIf="deleteFunction"(click)="deletePanel()" class='btn-gridstack-del {{buttonClass}}' > Supprimer le panneau< /button> |
13 | | - < span class="card-management" hidden> |
14 | | - <button *ngIf="deleteCardFunc"(click)="deleteCard()" class='btn-gridstack-del-card {{buttonClass}}' > Supprimer la carte< /button> |
15 | | - < /span> |
16 | | - < /div> |
17 | | - < br /> |
18 | | - <div class="grid-stack" [attr.data - gs - width] = "w"[attr.data - gs - animate] = "animate" > |
| 8 | + <button *ngIf="addFunction" (click)="addItem()" class='{{buttonClass}}'> Ajouter une carte</button> |
| 9 | + <button *ngIf="saveFunction" (click)="savePanel()" class='btn-gridstack-save {{buttonClass}}'> Enregistrer le panneau</button> |
| 10 | + <button *ngIf="deleteFunction" (click)="deletePanel()" class='btn-gridstack-del {{buttonClass}}'> Supprimer le panneau</button> |
| 11 | + <span class="card-management" hidden> |
| 12 | + <button *ngIf="deleteCardFunc" (click)="deleteCard()" class='btn-gridstack-del-card {{buttonClass}}'> Supprimer la carte</button> |
| 13 | + </span> |
| 14 | + </div> |
| 15 | + <br/> |
| 16 | + <div class="grid-stack" [attr.data-gs-width]="w" [attr.data-gs-animate]="animate"> |
19 | 17 | <ng-content > </ng-content> |
20 | | - < div gridStackItem |
21 | | - spellcheck= "false" |
22 | | - * ngFor="let item of items" |
23 | | - [x] = "item.X"[y] = "item.Y"[h] = "item.Height"[w] = "item.Width"[customid] = "item.CardId"[content] = "item.Content" |
24 | | - (dblclick) = "onItemClick()" > |
25 | | - </div> |
| 18 | + <div gridStackItem |
| 19 | + spellcheck="false" |
| 20 | + *ngFor="let item of items" |
| 21 | + [x]="item.X" [y]="item.Y" [h]="item.Height" [w]="item.Width" [customid]="item.CardId" [content]="item.Content" |
| 22 | + (dblclick)="onItemClick()"> |
26 | 23 | </div>` |
27 | 24 | }) |
28 | 25 |
|
|
0 commit comments