1.1.3 • Published 2 years ago

@forter/counter-circle v1.1.3

Weekly downloads
-
License
Apache-2.0
Repository
github
Last release
2 years ago

fc-counter-circle

An element by Forter

npm.io npm.io npm.io npm.io npm.io npm.io

Usage

<script>
   import '@forter/counter-circle';
</script>

<fc-counter-circle completed="1" total="2">
</fc-counter-circle

Examples

<!-- default size with zero state -->
<fc-counter-circle completed="0" total="4">
</fc-counter-circle>

<!-- default size with completed and total -->
<fc-counter-circle completed="12" total="16">
</fc-counter-circle>

<!-- custom radius with fully completed single digits -->
<fc-counter-circle radius="30" completed="2" total="2">
</fc-counter-circle>

<!-- custom radius with 50 percent completed -->
<fc-counter-circle radius="40" completed="8" total="16">
</fc-counter-circle>

<!-- larger custom radius -->
<fc-counter-circle radius="60" completed="3" total="12">
</fc-counter-circle>

Properties

PropertyAttributeTypeDefaultDescription
completedcompletednumber0Count of tasks completed
cssCircumferencenumbercssCircumference
cssRadiusnumbercssRadius
piCircumferencenumberpiCircumference
radiusradiusnumber18Radius
totaltotalnumber4Count of total tasks

CSS Custom Properties

PropertyDescription
--fc-counter-circle-animation-durationfill animation duration. example: 600ms
--fc-counter-circle-animation-timing-functionfill animation timing function. example: ease-in-out
--fc-counter-circle-empty-colorempty color. example: var(--cyan-1)
--fc-counter-circle-face-colorface background color. example: var(--indigo-1)
--fc-counter-circle-fill-colorfill color. example: var(--pink-4)
--fc-counter-circle-font-colorfont color. example: var(--cyan-9)