feat(Circle): add startPosition prop (#9305)

* feat(Circle): add startPosition prop

* docs(Circle): add start-position demo
This commit is contained in:
neverland
2021-08-22 16:19:37 +08:00
committed by GitHub
parent 5a93179b6b
commit f24c521d26
7 changed files with 184 additions and 1 deletions
@@ -152,4 +152,63 @@ exports[`should render demo and match snapshot 1`] = `
</div>
</button>
</div>
<div>
<div class="van-circle">
<svg viewbox="0 0 1040 1040"
style="transform: rotate(270deg);"
>
<path class="van-circle__layer"
style="fill: none; stroke-width: 40px;"
d="M 520 520 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
>
</path>
<path d="M 520 520 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
style="stroke-width: 41px; stroke-dasharray: 2355px 3140px;"
class="van-circle__hover"
>
</path>
</svg>
<div class="van-circle__text">
Left
</div>
</div>
<div class="van-circle">
<svg viewbox="0 0 1040 1040"
style="transform: rotate(90deg);"
>
<path class="van-circle__layer"
style="fill: none; stroke-width: 40px;"
d="M 520 520 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
>
</path>
<path d="M 520 520 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
style="stroke-width: 41px; stroke-dasharray: 2355px 3140px;"
class="van-circle__hover"
>
</path>
</svg>
<div class="van-circle__text">
Right
</div>
</div>
<div class="van-circle">
<svg viewbox="0 0 1040 1040"
style="transform: rotate(180deg);"
>
<path class="van-circle__layer"
style="fill: none; stroke-width: 40px;"
d="M 520 520 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
>
</path>
<path d="M 520 520 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
style="stroke-width: 41px; stroke-dasharray: 2355px 3140px;"
class="van-circle__hover"
>
</path>
</svg>
<div class="van-circle__text">
Bottom
</div>
</div>
</div>
`;