Feat/web swiper indicator style - #2558
Open
yandadaFreedom wants to merge 4 commits into
Open
Conversation
hiyuki
reviewed
Aug 25, 2026
| style: { | ||
| backgroundColor: i === this.currentIndex ? this.indicatorActiveColor : this.indicatorColor | ||
| backgroundColor: i === this.currentIndex ? this.indicatorActiveColor : this.indicatorColor, | ||
| margin: `${this.indicatorSpacing}px`, |
Collaborator
There was a problem hiding this comment.
indicator-spacing 表示相邻指示点的间距,但这里给每个指示点四周都设置了 margin。Flex 子项的 margin 不会折叠,因此 indicator-spacing="4" 实际会产生 8px 的点间距;首尾 margin 还会叠加到 indicator-margin,导致两个属性无法独立控制。建议改为在 dots 容器设置准确的 gap,或只给相邻方向设置单侧 margin,并补充横向、纵向用例。
hiyuki
reviewed
Aug 25, 2026
| type: String, | ||
| default: '#000000' | ||
| }, | ||
| indicatorMargin: { |
Collaborator
There was a problem hiding this comment.
这里新增了 indicator-margin、indicator-spacing、indicator-radius、indicator-width、indicator-height、indicator-alignment 和 indicator-offset 七个用户可见属性,但 PR 最后的提交撤销了对应文档,最终变更中没有说明 Web 端支持范围、默认值及数组语义。按照仓库对公开 API/跨端行为的文档同步约束,请恢复 docs-vitepress/guide/advance/platform.md 中的 swiper 文档更新。
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.