Skip to content

Commit

Permalink
fix(module:typography): fix the actions button order (NG-ZORRO#3677)
Browse files Browse the repository at this point in the history
  • Loading branch information
hsuanxyz authored and vthinkxie committed Jun 29, 2019
1 parent 4473539 commit cc08741
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
7 changes: 4 additions & 3 deletions components/typography/demo/interactive.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,12 @@ import { Component } from '@angular/core';
@Component({
selector: 'nz-demo-typography-interactive',
template: `
<p nz-paragraph nzEditable [(nzContent)]="str"></p>
<p nz-paragraph nzCopyable nzContent="This is a copyable text."></p>
<p nz-paragraph nzEditable [(nzContent)]="editStr"></p>
<p nz-paragraph nzCopyable nzEditable [(nzContent)]="copyStr"></p>
<p nz-paragraph nzCopyable nzCopyText="Hello, Ant Design!">Replace copy text.</p>
`
})
export class NzDemoTypographyInteractiveComponent {
str = 'This is an editable text.';
editStr = 'This is an editable text.';
copyStr = 'This is a copyable text.';
}
3 changes: 2 additions & 1 deletion components/typography/nz-typography.component.html
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,12 @@
</ng-container>
</ng-container>

<nz-text-copy *ngIf="nzCopyable" [text]="copyText" (textCopy)="onTextCopy($event)"></nz-text-copy>
<nz-text-edit
*ngIf="nzEditable"
[text]="nzContent"
(endEditing)="onEndEditing($event)"
(startEditing)="onStartEditing()">
</nz-text-edit>

<nz-text-copy *ngIf="nzCopyable && !editing" [text]="copyText" (textCopy)="onTextCopy($event)"></nz-text-copy>

0 comments on commit cc08741

Please sign in to comment.