forked from NG-ZORRO/ng-zorro-antd
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(module:slider): add nzReverse property
close NG-ZORRO#4937 fix: fix handle position when reverse changes fix: remove verbose logic fix: fix keyboard test: add test feat: add reverse vertical test
- Loading branch information
Wendell Hu
committed
Apr 26, 2020
1 parent
4bfbbf7
commit 2c7b89d
Showing
8 changed files
with
168 additions
and
60 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
--- | ||
order: 8 | ||
title: | ||
zh-CN: 反向 | ||
en-US: Reverse | ||
--- | ||
|
||
## zh-CN | ||
|
||
设置 `nzReverse` 可以将滑动条置反。 | ||
|
||
## en-US | ||
|
||
Using `nzReverse` to render slider reversely. | ||
|
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,26 @@ | ||
import { Component } from '@angular/core'; | ||
|
||
@Component({ | ||
selector: 'nz-demo-slider-reverse', | ||
template: ` | ||
<div> | ||
<nz-slider [ngModel]="30" [nzReverse]="reverse"></nz-slider> | ||
<nz-slider nzRange [ngModel]="[20, 50]" [nzReverse]="reverse"></nz-slider> | ||
Reversed: <nz-switch nzSize="small" [(ngModel)]="reverse"></nz-switch> | ||
</div> | ||
`, | ||
styles: [ | ||
` | ||
h4 { | ||
margin: 0 0 16px; | ||
} | ||
.ant-slider-with-marks { | ||
margin-bottom: 44px; | ||
} | ||
` | ||
] | ||
}) | ||
export class NzDemoSliderReverseComponent { | ||
reverse = true; | ||
} |
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
Oops, something went wrong.