Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(module:input-number): support setting status (#7462)
* feat(module:input-number): support setting status * feat(module:input-number): add tests for status
- Loading branch information
1 parent
e34ed5c
commit 0c9287a
Showing
7 changed files
with
106 additions
and
4 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 |
---|---|---|
@@ -0,0 +1,14 @@ | ||
--- | ||
order: 6 | ||
title: | ||
zh-CN: 自定义状态 | ||
en-US: Status | ||
--- | ||
|
||
## zh-CN | ||
|
||
使用 `nzStatus` 为 InputNumber 添加状态,可选 `error` 或者 `warning`。 | ||
|
||
## en-US | ||
|
||
Add status to InputNumber with `nzStatus`, which could be `error` or `warning`. |
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 |
---|---|---|
@@ -0,0 +1,18 @@ | ||
import { Component } from '@angular/core'; | ||
|
||
@Component({ | ||
selector: 'nz-demo-input-number-status', | ||
template: ` | ||
<nz-input-number [nzStep]="1" nzStatus="error"></nz-input-number> | ||
<nz-input-number [nzStep]="1" nzStatus="warning"></nz-input-number> | ||
`, | ||
styles: [ | ||
` | ||
nz-input-number { | ||
width: 100%; | ||
margin-bottom: 8px; | ||
} | ||
` | ||
] | ||
}) | ||
export class NzDemoInputNumberStatusComponent {} |
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