Skip to content

Commit

Permalink
VueUiWheel add exposed methods
Browse files Browse the repository at this point in the history
  • Loading branch information
graphieros committed Dec 17, 2023
1 parent 9bc51cf commit 67836e4
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 4 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
![GitHub issues](https://img.shields.io/github/issues/graphieros/vue-data-ui)
![NPM](https://img.shields.io/npm/l/vue-data-ui)
![npm](https://img.shields.io/npm/dt/vue-data-ui)
![Static Badge](https://img.shields.io/badge/components-27-green)
![Static Badge](https://img.shields.io/badge/components-28-green)

[Interactive documentation](https://vue-data-ui.graphieros.com/)

Expand Down
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "vue-data-ui",
"private": false,
"version": "1.9.25",
"version": "1.9.26",
"type": "module",
"description": "A user-empowering data visualization Vue components library",
"keywords": [
Expand Down
6 changes: 6 additions & 0 deletions src/components/vue-ui-wheel.vue
Original file line number Diff line number Diff line change
Expand Up @@ -134,6 +134,11 @@ function generateImage() {
}, 100)
}
defineExpose({
generatePdf,
generateImage
});
</script>

<template>
Expand Down Expand Up @@ -208,6 +213,7 @@ function generateImage() {
:fill="wheelConfig.style.chart.layout.wheel.ticks.gradient.show ? shiftHue(wheelConfig.style.chart.layout.wheel.ticks.activeColor, activeValue / 100 * (wheelConfig.style.chart.layout.wheel.ticks.gradient.shiftHueIntensity / 100)) : wheelConfig.style.chart.layout.wheel.ticks.activeColor"
text-anchor="middle"
:font-weight="wheelConfig.style.chart.layout.percentage.bold ? 'bold' : 'normal'"
style="font-variant-numeric:tabluar-nums"
>
{{ Number(activeValue.toFixed(wheelConfig.style.chart.layout.percentage.rounding)).toLocaleString() }}%
</text>
Expand Down

0 comments on commit 67836e4

Please sign in to comment.