Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: 修复 slider 样式问题 #1788

Merged
merged 4 commits into from
Nov 15, 2022
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
feat: 修复 slider 样式问题
  • Loading branch information
honkinglin committed Nov 14, 2022
commit 4286db999c99d571cc585b4ba4a13eb48d848560
9 changes: 5 additions & 4 deletions src/slider/slider.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -464,10 +464,11 @@ export default mixins(classPrefixMixins).extend({
)}

{this.showSteps && (
<div>
{this.steps.map((item, key) => (
<div class={`${this.componentName}__stop`} key={key} style={this.getStopStyle(item)}></div>
))}
<div class={`${this.componentName}__stops`}>
{this.steps.map((item, key) => {
if (item.position === 0 || item.position === 1) return null;
return <div class={`${this.componentName}__stop`} key={key} style={this.getStopStyle(item)}></div>;
})}
</div>
)}
{masks}
Expand Down