Skip to content

Commit

Permalink
fix(types): broaden ColorCircle's color prop type
Browse files Browse the repository at this point in the history
  • Loading branch information
bnjm committed Aug 17, 2023
1 parent 2b950d8 commit e736c18
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/components/ColorCircle.vue
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,11 @@ export default defineComponent({
* fill color of the circle
*/
color: {
type: String as PropType<Color>,
type: String as PropType<Color | string>,
default: ''
},
borderColor: {
type: String as PropType<Color>,
type: String as PropType<Color | string>,
default: ''
},
/**
Expand All @@ -27,7 +27,7 @@ export default defineComponent({
},
setup(props) {
const backgroundColor = computed(() =>
props.color ? `${colorMap[props.color] || props.color}` : ''
props.color ? `${colorMap[props.color as Color] || props.color}` : ''
)
const borderColor = computed(() => props.borderColor || backgroundColor.value)
const styles = computed(() => ({
Expand Down

0 comments on commit e736c18

Please sign in to comment.