-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
10 changed files
with
103 additions
and
32 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
import * as echarts from 'echarts/core' | ||
import { BarChart, LineChart, PieChart, RadarChart } from 'echarts/charts' | ||
import { CanvasRenderer, SVGRenderer } from 'echarts/renderers' | ||
import { | ||
DataZoomComponent, | ||
GraphicComponent, | ||
GridComponent, | ||
LegendComponent, | ||
PolarComponent, | ||
TitleComponent, | ||
ToolboxComponent, | ||
TooltipComponent, | ||
VisualMapComponent, | ||
} from 'echarts/components' | ||
|
||
import {App} from "vue" | ||
|
||
const { use } = echarts | ||
|
||
use([ | ||
PieChart, | ||
BarChart, | ||
LineChart, | ||
RadarChart, | ||
CanvasRenderer, | ||
SVGRenderer, | ||
GridComponent, | ||
TitleComponent, | ||
PolarComponent, | ||
LegendComponent, | ||
GraphicComponent, | ||
ToolboxComponent, | ||
TooltipComponent, | ||
DataZoomComponent, | ||
VisualMapComponent, | ||
]) | ||
|
||
export default function initEcharts(app: App) { | ||
app.config.globalProperties.$echarts = echarts | ||
} |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,9 @@ | ||
# MaEcharts | ||
|
||
基于 [echarts](https://echarts.apache.org/zh/index.html) 的封装,提供更简单的使用方式。 | ||
|
||
:::tip 说明 | ||
如果单独使用 `@mineadmin/echarts` 依赖的话,需要将 `echarts` 对象注册绑定到 `app.config.globalProperties.$echarts` 上。但在 `MineAdmin` 中已经自动注册了。 | ||
::: | ||
|
||
## 使用 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters