Skip to content

Commit

Permalink
chore: add liquidFill logo in demo
Browse files Browse the repository at this point in the history
  • Loading branch information
kingyue737 committed Jun 17, 2024
1 parent 402a634 commit 28f9e57
Show file tree
Hide file tree
Showing 4 changed files with 70 additions and 1 deletion.
4 changes: 3 additions & 1 deletion playground/app.vue
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,9 @@ const themeOptions = [

<div class="grid gap-y-4 justify-center py-15 text-align-center">
<header>
<EChartsLogo class="mx-auto fill-green-5 dark:fill-brand" />
<!-- <EChartsLogo class="mx-auto fill-green-5 dark:fill-brand" /> -->
<ChartLogo class="!inline-flex !w-fit !h-fit" />

<h1>
<NuxtLink to="https://github.com/kingyue737/nuxt-echarts"
>Nuxt ECharts</NuxtLink
Expand Down
34 changes: 34 additions & 0 deletions playground/components/Chart/Logo.server.vue
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
<script setup lang="ts">
import 'echarts-liquidfill'
const option = {
backgroundColor: 'transparent',
series: [
{
type: 'liquidFill',
data: [0.75, 0.6, 0.55, 0.45],
amplitude: 10,
outline: {
show: false,
},
radius: '100%',
color: ['#4fc08d', '#44d64a', '#33c762', '#4acc80'],
backgroundStyle: {
color: 'transparent',
},
shape: `path://M12 0A12 12 0 0 0 0 12a12 12 0 0 0 12 12 12 12 0 0 0 12-12A12 12 0 0 0 12 0zm-.792 5.307c2.192-.025 4.366 1.134 5.43 3.304.909 1.852.878 3.61-.098 5.645-.477.995-.487 1.06-.241 1.578.214.452.727.779 1.221.779.454 0 1.15-.586 1.252-1.054.1-.454-.193-1.118-.607-1.377a10.11 10.11 0 0 1-.393-.255c-.129-.1.42-.38.741-.38.687 0 1.247.526 1.375 1.29.055.333.134.422.44.502.859.222 1.297 1.451.755 2.116-.22.27-.23.271-.305.042-.267-.801-.666-1.12-1.403-1.12-.319 0-.572.128-1.098.556-1.006.82-1.866 1.303-2.907 1.632-1.276.384-2.752.478-4.086.156-2.162-.431-4.232-2.11-5.252-4.257C4.758 11.782 5.135 9 7.033 7.077a5.924 5.924 0 0 1 4.175-1.77Z`,
label: {
show: false,
},
itemStyle: {
shadowBlur: 12,
shadowColor: 'rgba(150, 150, 150, 0.5)',
},
},
],
}
</script>

<template>
<VChartServer :option="option" :init-options="{ height: 100, width: 100 }" />
</template>
1 change: 1 addition & 0 deletions playground/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
"generate": "nuxi generate"
},
"dependencies": {
"echarts-liquidfill": "^3.1.0",
"nuxt": "^3.11.2"
},
"devDependencies": {
Expand Down
32 changes: 32 additions & 0 deletions playground/pnpm-lock.yaml

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

0 comments on commit 28f9e57

Please sign in to comment.