chore(progress): get off work checkpoint

This commit is contained in:
07akioni 2019-08-01 20:00:12 +08:00
parent 10097059f9
commit 5114908c6d
4 changed files with 64 additions and 1 deletions

View File

@ -8,7 +8,10 @@
style="flex-wrap: nowrap;"
>
<!--EXAMPLE_START-->
Write some demo here
<n-progress
type="circle"
:percentage="60"
/>
<!--EXAMPLE_END-->
</div>
<pre class="n-doc-section__inspect">Inspect some value here</pre>

View File

@ -18,6 +18,7 @@ import Input from './packages/common/Input'
import Message from './packages/common/Message'
import Notification from './packages/common/Notification'
import Pagination from './packages/common/Pagination'
import Progress from './packages/common/Progress'
import Tooltip from './packages/common/Tooltip'
import Popup from './packages/common/Popover'
import Alert from './packages/common/Alert'
@ -76,6 +77,7 @@ function install (Vue) {
Scrollbar.install(Vue)
Steps.install(Vue)
Confirm.install(Vue)
Progress.install(Vue)
}
export default {

View File

@ -0,0 +1,8 @@
/* istanbul ignore file */
import Progress from './src/main.vue'
Progress.install = function (Vue) {
Vue.component(Progress.name, Progress)
}
export default Progress

View File

@ -0,0 +1,50 @@
<template>
<div
:style="{
width: width + 'px',
height: width + 'px'
}"
>
<svg viewBox="0 0 100 100">
<g>
<path
d="
m 50 3
a 47 47 0 1 1 0 94
a 47 47 0 1 1 0 -94
"
stroke-width="3"
stroke-linecap="round"
stroke="white"
fill="none"
style="stroke-dasharray: 157, 1000; stroke-dashoffset: 0;"
/>
</g>
<g>
<path
d="
m 50 6
a 44 44 0 1 1 0 88
a 44 44 0 1 1 0 -88
"
stroke-width="3"
stroke-linecap="round"
stroke="red"
fill="none"
style="stroke-dasharray: 120, 1000; stroke-dashoffset: 0;"
/>
</g>
</svg>
</div>
</template>
<script>
export default {
name: 'NProgress',
data () {
return {
width: 126
}
}
}
</script>