This commit is contained in:
2026-03-25 14:54:15 +08:00
commit ab4646b43a
827 changed files with 123812 additions and 0 deletions
@@ -0,0 +1,7 @@
{
"component": true,
"usingComponents": {
"qiun-loading": "../qiun-loading/qiun-loading",
"qiun-error": "../qiun-error/qiun-error"
}
}
@@ -0,0 +1 @@
<view class="chartsview data-v-0ca34aee" id="{{ac}}"><view wx:if="{{a}}" class="data-v-0ca34aee"><qiun-loading wx:if="{{b}}" class="data-v-0ca34aee" u-i="0ca34aee-0" bind:__l="__l" u-p="{{b}}"/></view><view wx:if="{{c}}" class="data-v-0ca34aee" bindtap="{{e}}"><qiun-error wx:if="{{d}}" class="data-v-0ca34aee" u-i="0ca34aee-1" bind:__l="__l" u-p="{{d}}"/></view><block wx:if="{{f}}"><view wx:if="{{g}}" class="data-v-0ca34aee" bindtap="{{s}}"><block wx:if="{{r0}}"><canvas class="data-v-0ca34aee" id="{{h}}" canvasId="{{i}}" style="{{'width:' + j + ';' + ('height:' + k) + ';' + ('background:' + l)}}" type="2d" disable-scroll="{{m}}" bindtouchstart="{{n}}" bindtouchmove="{{o}}" bindtouchend="{{p}}" binderror="{{q}}" hidden="{{!r}}"/></block></view><view wx:if="{{t}}" class="data-v-0ca34aee" bindtap="{{D}}"><block wx:if="{{r0}}"><canvas class="data-v-0ca34aee" id="{{v}}" canvasId="{{w}}" style="{{'width:' + x + ';' + ('height:' + y) + ';' + ('background:' + z)}}" type="2d" disable-scroll="{{A}}" binderror="{{B}}" hidden="{{!C}}"/></block></view></block><block wx:if="{{E}}"><view wx:if="{{F}}" class="data-v-0ca34aee" bindtap="{{R}}"><canvas wx:if="{{G}}" class="data-v-0ca34aee" id="{{H}}" canvasId="{{I}}" style="{{'width:' + J + ';' + ('height:' + K) + ';' + ('background:' + L)}}" bindtouchstart="{{M}}" bindtouchmove="{{N}}" bindtouchend="{{O}}" disable-scroll="{{P}}" binderror="{{Q}}"/></view><view wx:if="{{S}}" class="data-v-0ca34aee"><canvas wx:if="{{T}}" class="data-v-0ca34aee" id="{{U}}" canvasId="{{V}}" style="{{'width:' + W + ';' + ('height:' + X) + ';' + ('background:' + Y)}}" disable-scroll="{{Z}}" bindtap="{{aa}}" binderror="{{ab}}"/></view></block></view>
@@ -0,0 +1,9 @@
.chartsview.data-v-0ca34aee {
width: 100%;
height: 100%;
display: flex;
flex: 1;
justify-content: center;
align-items: center;
}
@@ -0,0 +1,22 @@
"use strict";
const common_vendor = require("../../../../common/vendor.js");
const _sfc_main = {
name: "qiun-error",
props: {
errorMessage: {
type: String,
default: null
}
},
data() {
return {};
}
};
function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
return {
a: common_vendor.t($props.errorMessage == null ? "请点击重试" : $props.errorMessage)
};
}
const Component = /* @__PURE__ */ common_vendor._export_sfc(_sfc_main, [["render", _sfc_render]]);
wx.createComponent(Component);
//# sourceMappingURL=../../../../../.sourcemap/mp-weixin/uni_modules/qiun-data-charts/components/qiun-error/qiun-error.js.map
@@ -0,0 +1,4 @@
{
"component": true,
"usingComponents": {}
}
@@ -0,0 +1 @@
<view class="chartsview"><view class="charts-error"></view><view class="charts-font">{{a}}</view></view>
File diff suppressed because one or more lines are too long
@@ -0,0 +1,14 @@
"use strict";
const common_vendor = require("../../../../common/vendor.js");
const _sfc_main = {
name: "loading1",
data() {
return {};
}
};
function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
return {};
}
const Component = /* @__PURE__ */ common_vendor._export_sfc(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-0e645258"]]);
wx.createComponent(Component);
//# sourceMappingURL=../../../../../.sourcemap/mp-weixin/uni_modules/qiun-data-charts/components/qiun-loading/loading1.js.map
@@ -0,0 +1,4 @@
{
"component": true,
"usingComponents": {}
}
@@ -0,0 +1 @@
<view class="container loading1 data-v-0e645258"><view class="shape shape1 data-v-0e645258"></view><view class="shape shape2 data-v-0e645258"></view><view class="shape shape3 data-v-0e645258"></view><view class="shape shape4 data-v-0e645258"></view></view>
@@ -0,0 +1,78 @@
.container.data-v-0e645258 {
width: 30px;
height: 30px;
position: relative;
}
.container.loading1.data-v-0e645258 {
transform: rotate(45deg);
}
.container .shape.data-v-0e645258 {
position: absolute;
width: 10px;
height: 10px;
border-radius: 1px;
}
.container .shape.shape1.data-v-0e645258 {
left: 0;
background-color: #1890FF;
}
.container .shape.shape2.data-v-0e645258 {
right: 0;
background-color: #91CB74;
}
.container .shape.shape3.data-v-0e645258 {
bottom: 0;
background-color: #FAC858;
}
.container .shape.shape4.data-v-0e645258 {
bottom: 0;
right: 0;
background-color: #EE6666;
}
.loading1 .shape1.data-v-0e645258 {
animation: animation1shape1-0e645258 0.5s ease 0s infinite alternate;
}
@keyframes animation1shape1-0e645258 {
from {
transform: translate(0, 0);
}
to {
transform: translate(16px, 16px);
}
}
.loading1 .shape2.data-v-0e645258 {
animation: animation1shape2-0e645258 0.5s ease 0s infinite alternate;
}
@keyframes animation1shape2-0e645258 {
from {
transform: translate(0, 0);
}
to {
transform: translate(-16px, 16px);
}
}
.loading1 .shape3.data-v-0e645258 {
animation: animation1shape3-0e645258 0.5s ease 0s infinite alternate;
}
@keyframes animation1shape3-0e645258 {
from {
transform: translate(0, 0);
}
to {
transform: translate(16px, -16px);
}
}
.loading1 .shape4.data-v-0e645258 {
animation: animation1shape4-0e645258 0.5s ease 0s infinite alternate;
}
@keyframes animation1shape4-0e645258 {
from {
transform: translate(0, 0);
}
to {
transform: translate(-16px, -16px);
}
}
@@ -0,0 +1,14 @@
"use strict";
const common_vendor = require("../../../../common/vendor.js");
const _sfc_main = {
name: "loading2",
data() {
return {};
}
};
function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
return {};
}
const Component = /* @__PURE__ */ common_vendor._export_sfc(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-3df48dc2"]]);
wx.createComponent(Component);
//# sourceMappingURL=../../../../../.sourcemap/mp-weixin/uni_modules/qiun-data-charts/components/qiun-loading/loading2.js.map
@@ -0,0 +1,4 @@
{
"component": true,
"usingComponents": {}
}
@@ -0,0 +1 @@
<view class="container loading2 data-v-3df48dc2"><view class="shape shape1 data-v-3df48dc2"></view><view class="shape shape2 data-v-3df48dc2"></view><view class="shape shape3 data-v-3df48dc2"></view><view class="shape shape4 data-v-3df48dc2"></view></view>
@@ -0,0 +1,83 @@
.container.data-v-3df48dc2 {
width: 30px;
height: 30px;
position: relative;
}
.container.loading2.data-v-3df48dc2 {
transform: rotate(10deg);
}
.container.loading2 .shape.data-v-3df48dc2 {
border-radius: 5px;
}
.container.loading2.data-v-3df48dc2{
animation: rotation 1s infinite;
}
.container .shape.data-v-3df48dc2 {
position: absolute;
width: 10px;
height: 10px;
border-radius: 1px;
}
.container .shape.shape1.data-v-3df48dc2 {
left: 0;
background-color: #1890FF;
}
.container .shape.shape2.data-v-3df48dc2 {
right: 0;
background-color: #91CB74;
}
.container .shape.shape3.data-v-3df48dc2 {
bottom: 0;
background-color: #FAC858;
}
.container .shape.shape4.data-v-3df48dc2 {
bottom: 0;
right: 0;
background-color: #EE6666;
}
.loading2 .shape1.data-v-3df48dc2 {
animation: animation2shape1-3df48dc2 0.5s ease 0s infinite alternate;
}
@keyframes animation2shape1-3df48dc2 {
from {
transform: translate(0, 0);
}
to {
transform: translate(20px, 20px);
}
}
.loading2 .shape2.data-v-3df48dc2 {
animation: animation2shape2-3df48dc2 0.5s ease 0s infinite alternate;
}
@keyframes animation2shape2-3df48dc2 {
from {
transform: translate(0, 0);
}
to {
transform: translate(-20px, 20px);
}
}
.loading2 .shape3.data-v-3df48dc2 {
animation: animation2shape3-3df48dc2 0.5s ease 0s infinite alternate;
}
@keyframes animation2shape3-3df48dc2 {
from {
transform: translate(0, 0);
}
to {
transform: translate(20px, -20px);
}
}
.loading2 .shape4.data-v-3df48dc2 {
animation: animation2shape4-3df48dc2 0.5s ease 0s infinite alternate;
}
@keyframes animation2shape4-3df48dc2 {
from {
transform: translate(0, 0);
}
to {
transform: translate(-20px, -20px);
}
}
@@ -0,0 +1,14 @@
"use strict";
const common_vendor = require("../../../../common/vendor.js");
const _sfc_main = {
name: "loading3",
data() {
return {};
}
};
function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
return {};
}
const Component = /* @__PURE__ */ common_vendor._export_sfc(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-27a8293c"]]);
wx.createComponent(Component);
//# sourceMappingURL=../../../../../.sourcemap/mp-weixin/uni_modules/qiun-data-charts/components/qiun-loading/loading3.js.map
@@ -0,0 +1,4 @@
{
"component": true,
"usingComponents": {}
}
@@ -0,0 +1 @@
<view class="container loading3 data-v-27a8293c"><view class="shape shape1 data-v-27a8293c"></view><view class="shape shape2 data-v-27a8293c"></view><view class="shape shape3 data-v-27a8293c"></view><view class="shape shape4 data-v-27a8293c"></view></view>
@@ -0,0 +1,88 @@
.container.data-v-27a8293c {
width: 30px;
height: 30px;
position: relative;
}
.container.loading3.data-v-27a8293c {
animation: rotation 1s infinite;
}
.container.loading3 .shape1.data-v-27a8293c {
border-top-left-radius: 10px;
}
.container.loading3 .shape2.data-v-27a8293c {
border-top-right-radius: 10px;
}
.container.loading3 .shape3.data-v-27a8293c {
border-bottom-left-radius: 10px;
}
.container.loading3 .shape4.data-v-27a8293c {
border-bottom-right-radius: 10px;
}
.container .shape.data-v-27a8293c {
position: absolute;
width: 10px;
height: 10px;
border-radius: 1px;
}
.container .shape.shape1.data-v-27a8293c {
left: 0;
background-color: #1890FF;
}
.container .shape.shape2.data-v-27a8293c {
right: 0;
background-color: #91CB74;
}
.container .shape.shape3.data-v-27a8293c {
bottom: 0;
background-color: #FAC858;
}
.container .shape.shape4.data-v-27a8293c {
bottom: 0;
right: 0;
background-color: #EE6666;
}
.loading3 .shape1.data-v-27a8293c {
animation: animation3shape1-27a8293c 0.5s ease 0s infinite alternate;
}
@keyframes animation3shape1-27a8293c {
from {
transform: translate(0, 0);
}
to {
transform: translate(5px, 5px);
}
}
.loading3 .shape2.data-v-27a8293c {
animation: animation3shape2-27a8293c 0.5s ease 0s infinite alternate;
}
@keyframes animation3shape2-27a8293c {
from {
transform: translate(0, 0);
}
to {
transform: translate(-5px, 5px);
}
}
.loading3 .shape3.data-v-27a8293c {
animation: animation3shape3-27a8293c 0.5s ease 0s infinite alternate;
}
@keyframes animation3shape3-27a8293c {
from {
transform: translate(0, 0);
}
to {
transform: translate(5px, -5px);
}
}
.loading3 .shape4.data-v-27a8293c {
animation: animation3shape4-27a8293c 0.5s ease 0s infinite alternate;
}
@keyframes animation3shape4-27a8293c {
from {
transform: translate(0, 0);
}
to {
transform: translate(-5px, -5px);
}
}
@@ -0,0 +1,14 @@
"use strict";
const common_vendor = require("../../../../common/vendor.js");
const _sfc_main = {
name: "loading5",
data() {
return {};
}
};
function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
return {};
}
const Component = /* @__PURE__ */ common_vendor._export_sfc(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-2e7deb83"]]);
wx.createComponent(Component);
//# sourceMappingURL=../../../../../.sourcemap/mp-weixin/uni_modules/qiun-data-charts/components/qiun-loading/loading4.js.map
@@ -0,0 +1,4 @@
{
"component": true,
"usingComponents": {}
}
@@ -0,0 +1 @@
<view class="container loading5 data-v-2e7deb83"><view class="shape shape1 data-v-2e7deb83"></view><view class="shape shape2 data-v-2e7deb83"></view><view class="shape shape3 data-v-2e7deb83"></view><view class="shape shape4 data-v-2e7deb83"></view></view>
@@ -0,0 +1,102 @@
.container.data-v-2e7deb83 {
width: 30px;
height: 30px;
position: relative;
}
.container.loading5 .shape.data-v-2e7deb83 {
width: 15px;
height: 15px;
}
.container .shape.data-v-2e7deb83 {
position: absolute;
width: 10px;
height: 10px;
border-radius: 1px;
}
.container .shape.shape1.data-v-2e7deb83 {
left: 0;
background-color: #1890FF;
}
.container .shape.shape2.data-v-2e7deb83 {
right: 0;
background-color: #91CB74;
}
.container .shape.shape3.data-v-2e7deb83 {
bottom: 0;
background-color: #FAC858;
}
.container .shape.shape4.data-v-2e7deb83 {
bottom: 0;
right: 0;
background-color: #EE6666;
}
.loading5 .shape1.data-v-2e7deb83 {
animation: animation5shape1-2e7deb83 2s ease 0s infinite reverse;
}
@keyframes animation5shape1-2e7deb83 {
0% {
transform: translate(0, 0);
}
25% {
transform: translate(0, 15px);
}
50% {
transform: translate(15px, 15px);
}
75% {
transform: translate(15px, 0);
}
}
.loading5 .shape2.data-v-2e7deb83 {
animation: animation5shape2-2e7deb83 2s ease 0s infinite reverse;
}
@keyframes animation5shape2-2e7deb83 {
0% {
transform: translate(0, 0);
}
25% {
transform: translate(-15px, 0);
}
50% {
transform: translate(-15px, 15px);
}
75% {
transform: translate(0, 15px);
}
}
.loading5 .shape3.data-v-2e7deb83 {
animation: animation5shape3-2e7deb83 2s ease 0s infinite reverse;
}
@keyframes animation5shape3-2e7deb83 {
0% {
transform: translate(0, 0);
}
25% {
transform: translate(15px, 0);
}
50% {
transform: translate(15px, -15px);
}
75% {
transform: translate(0, -15px);
}
}
.loading5 .shape4.data-v-2e7deb83 {
animation: animation5shape4-2e7deb83 2s ease 0s infinite reverse;
}
@keyframes animation5shape4-2e7deb83 {
0% {
transform: translate(0, 0);
}
25% {
transform: translate(0, -15px);
}
50% {
transform: translate(-15px, -15px);
}
75% {
transform: translate(-15px, 0);
}
}
@@ -0,0 +1,14 @@
"use strict";
const common_vendor = require("../../../../common/vendor.js");
const _sfc_main = {
name: "loading6",
data() {
return {};
}
};
function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
return {};
}
const Component = /* @__PURE__ */ common_vendor._export_sfc(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-ef674bbb"]]);
wx.createComponent(Component);
//# sourceMappingURL=../../../../../.sourcemap/mp-weixin/uni_modules/qiun-data-charts/components/qiun-loading/loading5.js.map
@@ -0,0 +1,4 @@
{
"component": true,
"usingComponents": {}
}
@@ -0,0 +1 @@
<view class="container loading6 data-v-ef674bbb"><view class="shape shape1 data-v-ef674bbb"></view><view class="shape shape2 data-v-ef674bbb"></view><view class="shape shape3 data-v-ef674bbb"></view><view class="shape shape4 data-v-ef674bbb"></view></view>
@@ -0,0 +1,105 @@
.container.data-v-ef674bbb {
width: 30px;
height: 30px;
position: relative;
}
.container.loading6.data-v-ef674bbb {
animation: rotation 1s infinite;
}
.container.loading6 .shape.data-v-ef674bbb {
width: 12px;
height: 12px;
border-radius: 2px;
}
.container .shape.data-v-ef674bbb {
position: absolute;
width: 10px;
height: 10px;
border-radius: 1px;
}
.container .shape.shape1.data-v-ef674bbb {
left: 0;
background-color: #1890FF;
}
.container .shape.shape2.data-v-ef674bbb {
right: 0;
background-color: #91CB74;
}
.container .shape.shape3.data-v-ef674bbb {
bottom: 0;
background-color: #FAC858;
}
.container .shape.shape4.data-v-ef674bbb {
bottom: 0;
right: 0;
background-color: #EE6666;
}
.loading6 .shape1.data-v-ef674bbb {
animation: animation6shape1-ef674bbb 2s linear 0s infinite normal;
}
@keyframes animation6shape1-ef674bbb {
0% {
transform: translate(0, 0);
}
25% {
transform: translate(0, 18px);
}
50% {
transform: translate(18px, 18px);
}
75% {
transform: translate(18px, 0);
}
}
.loading6 .shape2.data-v-ef674bbb {
animation: animation6shape2-ef674bbb 2s linear 0s infinite normal;
}
@keyframes animation6shape2-ef674bbb {
0% {
transform: translate(0, 0);
}
25% {
transform: translate(-18px, 0);
}
50% {
transform: translate(-18px, 18px);
}
75% {
transform: translate(0, 18px);
}
}
.loading6 .shape3.data-v-ef674bbb {
animation: animation6shape3-ef674bbb 2s linear 0s infinite normal;
}
@keyframes animation6shape3-ef674bbb {
0% {
transform: translate(0, 0);
}
25% {
transform: translate(18px, 0);
}
50% {
transform: translate(18px, -18px);
}
75% {
transform: translate(0, -18px);
}
}
.loading6 .shape4.data-v-ef674bbb {
animation: animation6shape4-ef674bbb 2s linear 0s infinite normal;
}
@keyframes animation6shape4-ef674bbb {
0% {
transform: translate(0, 0);
}
25% {
transform: translate(0, -18px);
}
50% {
transform: translate(-18px, -18px);
}
75% {
transform: translate(-18px, 0);
}
}
@@ -0,0 +1,44 @@
"use strict";
const common_vendor = require("../../../../common/vendor.js");
const Loading1 = () => "./loading1.js";
const Loading2 = () => "./loading2.js";
const Loading3 = () => "./loading3.js";
const Loading4 = () => "./loading4.js";
const Loading5 = () => "./loading5.js";
const _sfc_main = {
components: { Loading1, Loading2, Loading3, Loading4, Loading5 },
name: "qiun-loading",
props: {
loadingType: {
type: Number,
default: 2
}
},
data() {
return {};
}
};
if (!Array) {
const _component_Loading1 = common_vendor.resolveComponent("Loading1");
const _component_Loading2 = common_vendor.resolveComponent("Loading2");
const _component_Loading3 = common_vendor.resolveComponent("Loading3");
const _component_Loading4 = common_vendor.resolveComponent("Loading4");
const _component_Loading5 = common_vendor.resolveComponent("Loading5");
(_component_Loading1 + _component_Loading2 + _component_Loading3 + _component_Loading4 + _component_Loading5)();
}
function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
return common_vendor.e({
a: $props.loadingType == 1
}, $props.loadingType == 1 ? {} : {}, {
b: $props.loadingType == 2
}, $props.loadingType == 2 ? {} : {}, {
c: $props.loadingType == 3
}, $props.loadingType == 3 ? {} : {}, {
d: $props.loadingType == 4
}, $props.loadingType == 4 ? {} : {}, {
e: $props.loadingType == 5
}, $props.loadingType == 5 ? {} : {});
}
const Component = /* @__PURE__ */ common_vendor._export_sfc(_sfc_main, [["render", _sfc_render]]);
wx.createComponent(Component);
//# sourceMappingURL=../../../../../.sourcemap/mp-weixin/uni_modules/qiun-data-charts/components/qiun-loading/qiun-loading.js.map
@@ -0,0 +1,10 @@
{
"component": true,
"usingComponents": {
"loading1": "./loading1",
"loading2": "./loading2",
"loading3": "./loading3",
"loading4": "./loading4",
"loading5": "./loading5"
}
}
@@ -0,0 +1 @@
<view><loading1 wx:if="{{a}}" u-i="64699596-0" bind:__l="__l"/><loading2 wx:if="{{b}}" u-i="64699596-1" bind:__l="__l"/><loading3 wx:if="{{c}}" u-i="64699596-2" bind:__l="__l"/><loading4 wx:if="{{d}}" u-i="64699596-3" bind:__l="__l"/><loading5 wx:if="{{e}}" u-i="64699596-4" bind:__l="__l"/></view>
@@ -0,0 +1,598 @@
"use strict";
const color = ["#1890FF", "#91CB74", "#FAC858", "#EE6666", "#73C0DE", "#3CA272", "#FC8452", "#9A60B4", "#ea7ccc"];
const formatDateTime = (timeStamp, returnType) => {
var date = /* @__PURE__ */ new Date();
date.setTime(timeStamp * 1e3);
var y = date.getFullYear();
var m = date.getMonth() + 1;
m = m < 10 ? "0" + m : m;
var d = date.getDate();
d = d < 10 ? "0" + d : d;
var h = date.getHours();
h = h < 10 ? "0" + h : h;
var minute = date.getMinutes();
var second = date.getSeconds();
minute = minute < 10 ? "0" + minute : minute;
second = second < 10 ? "0" + second : second;
if (returnType == "full") {
return y + "-" + m + "-" + d + " " + h + ":" + minute + ":" + second;
}
if (returnType == "y-m-d") {
return y + "-" + m + "-" + d;
}
if (returnType == "h:m") {
return h + ":" + minute;
}
if (returnType == "h:m:s") {
return h + ":" + minute + ":" + second;
}
return [y, m, d, h, minute, second];
};
const cfu = {
//demotype为自定义图表类型,一般不需要自定义图表类型,只需要改根节点上对应的类型即可
"type": ["pie", "ring", "rose", "word", "funnel", "map", "arcbar", "line", "column", "mount", "bar", "area", "radar", "gauge", "candle", "mix", "tline", "tarea", "scatter", "bubble", "demotype"],
"range": ["饼状图", "圆环图", "玫瑰图", "词云图", "漏斗图", "地图", "圆弧进度条", "折线图", "柱状图", "山峰图", "条状图", "区域图", "雷达图", "仪表盘", "K线图", "混合图", "时间轴折线", "时间轴区域", "散点图", "气泡图", "自定义类型"],
//增加自定义图表类型,如果需要categories,请在这里加入您的图表类型,例如最后的"demotype"
//自定义类型时需要注意"tline","tarea","scatter","bubble"等时间轴(矢量x轴)类图表,没有categories,不需要加入categories
"categories": ["line", "column", "mount", "bar", "area", "radar", "gauge", "candle", "mix", "demotype"],
//instance为实例变量承载属性,不要删除
"instance": {},
//option为opts及eopts承载属性,不要删除
"option": {},
//下面是自定义format配置,因除H5端外的其他端无法通过props传递函数,只能通过此属性对应下标的方式来替换
"formatter": {
"yAxisDemo1": function(val, index, opts) {
return val + "元";
},
"yAxisDemo2": function(val, index, opts) {
return val.toFixed(2);
},
"xAxisDemo1": function(val, index, opts) {
return val + "年";
},
"xAxisDemo2": function(val, index, opts) {
return formatDateTime(val, "h:m");
},
"seriesDemo1": function(val, index, series, opts) {
return val + "元";
},
"tooltipDemo1": function(item, category, index, opts) {
if (index == 0) {
return "随便用" + item.data + "年";
} else {
return "其他我没改" + item.data + "天";
}
},
"formatXLabel": function(val, index, opts) {
return val;
},
"formatDataLabel": function(val, index, opts) {
if (index == 2) {
return `${val}人次`;
} else {
return `${val}台套`;
}
},
"pieDemo": function(val, index, series, opts) {
if (index !== void 0) {
return series[index].name + "" + series[index].data + "元";
}
}
},
//这里演示了自定义您的图表类型的option,可以随意命名,之后在组件上 type="demotype" 后,组件会调用这个花括号里的option,如果组件上还存在opts参数,会将demotype与opts中option合并后渲染图表。
"demotype": {
//我这里把曲线图当做了自定义图表类型,您可以根据需要随意指定类型或配置
"type": "line",
"color": color,
"padding": [15, 10, 0, 15],
"xAxis": {
"disableGrid": true
},
"yAxis": {
"gridType": "dash",
"dashLength": 2
},
"legend": {},
"extra": {
"line": {
"type": "curve",
"width": 2
}
}
},
//下面是自定义配置,请添加项目所需的通用配置
"pie": {
"type": "pie",
"color": color,
"padding": [5, 5, 5, 5],
"extra": {
"pie": {
"activeOpacity": 0.5,
"activeRadius": 10,
"offsetAngle": 0,
"labelWidth": 15,
"border": true,
"borderWidth": 3,
"borderColor": "#FFFFFF"
}
}
},
"ring": {
"type": "ring",
"color": color,
"padding": [5, 5, 5, 5],
"rotate": false,
"dataLabel": true,
"legend": {
"show": true,
"position": "right",
"lineHeight": 25
},
"title": {
"name": "收益率",
"fontSize": 15,
"color": "#666666"
},
"subtitle": {
"name": "70%",
"fontSize": 25,
"color": "#7cb5ec"
},
"extra": {
"ring": {
"ringWidth": 30,
"activeOpacity": 0.5,
"activeRadius": 10,
"offsetAngle": 0,
"labelWidth": 15,
"border": true,
"borderWidth": 3,
"borderColor": "#FFFFFF"
}
}
},
"rose": {
"type": "rose",
"color": color,
"padding": [5, 5, 5, 5],
"legend": {
"show": true,
"position": "left",
"lineHeight": 25
},
"extra": {
"rose": {
"type": "area",
"minRadius": 50,
"activeOpacity": 0.5,
"activeRadius": 10,
"offsetAngle": 0,
"labelWidth": 15,
"border": false,
"borderWidth": 2,
"borderColor": "#FFFFFF"
}
}
},
"word": {
"type": "word",
"color": color,
"extra": {
"word": {
"type": "normal",
"autoColors": false
}
}
},
"funnel": {
"type": "funnel",
"color": color,
"padding": [15, 15, 0, 15],
"extra": {
"funnel": {
"activeOpacity": 0.3,
"activeWidth": 10,
"border": true,
"borderWidth": 2,
"borderColor": "#FFFFFF",
"fillOpacity": 1,
"labelAlign": "right"
}
}
},
"map": {
"type": "map",
"color": color,
"padding": [0, 0, 0, 0],
"dataLabel": true,
"extra": {
"map": {
"border": true,
"borderWidth": 1,
"borderColor": "#666666",
"fillOpacity": 0.6,
"activeBorderColor": "#F04864",
"activeFillColor": "#FACC14",
"activeFillOpacity": 1
}
}
},
"arcbar": {
"type": "arcbar",
"color": color,
"title": {
"name": "百分比",
"fontSize": 25,
"color": "#00FF00"
},
"subtitle": {
"name": "默认标题",
"fontSize": 15,
"color": "#666666"
},
"extra": {
"arcbar": {
"type": "default",
"width": 12,
"backgroundColor": "#E9E9E9",
"startAngle": 0.75,
"endAngle": 0.25,
"gap": 2
}
}
},
"line": {
"type": "line",
"color": color,
"padding": [15, 10, 0, 15],
"xAxis": {
"disableGrid": true
},
"yAxis": {
"gridType": "dash",
"dashLength": 2
},
"legend": {},
"extra": {
"line": {
"type": "straight",
"width": 2,
"activeType": "hollow"
}
}
},
"tline": {
"type": "line",
"color": color,
"padding": [15, 10, 0, 15],
"xAxis": {
"disableGrid": false,
"boundaryGap": "justify"
},
"yAxis": {
"gridType": "dash",
"dashLength": 2,
"data": [
{
"min": 0,
"max": 80
}
]
},
"legend": {},
"extra": {
"line": {
"type": "curve",
"width": 2,
"activeType": "hollow"
}
}
},
"tarea": {
"type": "area",
"color": color,
"padding": [15, 10, 0, 15],
"xAxis": {
"disableGrid": true,
"boundaryGap": "justify"
},
"yAxis": {
"gridType": "dash",
"dashLength": 2,
"data": [
{
"min": 0,
"max": 80
}
]
},
"legend": {},
"extra": {
"area": {
"type": "curve",
"opacity": 0.2,
"addLine": true,
"width": 2,
"gradient": true,
"activeType": "hollow"
}
}
},
"column": {
"type": "column",
"color": color,
"padding": [15, 15, 0, 5],
"xAxis": {
"disableGrid": true
},
"yAxis": {
"data": [{ "min": 0 }]
},
"legend": {},
"extra": {
"column": {
"type": "group",
"width": 30,
"activeBgColor": "#000000",
"activeBgOpacity": 0.08
}
}
},
"mount": {
"type": "mount",
"color": color,
"padding": [15, 15, 0, 5],
"xAxis": {
"disableGrid": true
},
"yAxis": {
"data": [{ "min": 0 }]
},
"legend": {},
"extra": {
"mount": {
"type": "mount",
"widthRatio": 1.5
}
}
},
"bar": {
"type": "bar",
"color": color,
"padding": [15, 30, 0, 5],
"xAxis": {
"boundaryGap": "justify",
"disableGrid": false,
"min": 0,
"axisLine": false
},
"yAxis": {},
"legend": {},
"extra": {
"bar": {
"type": "group",
"width": 30,
"meterBorde": 1,
"meterFillColor": "#FFFFFF",
"activeBgColor": "#000000",
"activeBgOpacity": 0.08
}
}
},
"area": {
"type": "area",
"color": color,
"padding": [15, 15, 0, 15],
"xAxis": {
"disableGrid": true
},
"yAxis": {
"gridType": "dash",
"dashLength": 2
},
"legend": {},
"extra": {
"area": {
"type": "straight",
"opacity": 0.2,
"addLine": true,
"width": 2,
"gradient": false,
"activeType": "hollow"
}
}
},
"radar": {
"type": "radar",
"color": color,
"padding": [5, 5, 5, 5],
"dataLabel": false,
"legend": {
"show": true,
"position": "right",
"lineHeight": 25
},
"extra": {
"radar": {
"gridType": "radar",
"gridColor": "#CCCCCC",
"gridCount": 3,
"opacity": 0.2,
"max": 200,
"labelShow": true
}
}
},
"gauge": {
"type": "gauge",
"color": color,
"title": {
"name": "66Km/H",
"fontSize": 25,
"color": "#2fc25b",
"offsetY": 50
},
"subtitle": {
"name": "实时速度",
"fontSize": 15,
"color": "#1890ff",
"offsetY": -50
},
"extra": {
"gauge": {
"type": "default",
"width": 30,
"labelColor": "#666666",
"startAngle": 0.75,
"endAngle": 0.25,
"startNumber": 0,
"endNumber": 100,
"labelFormat": "",
"splitLine": {
"fixRadius": 0,
"splitNumber": 10,
"width": 30,
"color": "#FFFFFF",
"childNumber": 5,
"childWidth": 12
},
"pointer": {
"width": 24,
"color": "auto"
}
}
}
},
"candle": {
"type": "candle",
"color": color,
"padding": [15, 15, 0, 15],
"enableScroll": true,
"enableMarkLine": true,
"dataLabel": false,
"xAxis": {
"labelCount": 4,
"itemCount": 40,
"disableGrid": true,
"gridColor": "#CCCCCC",
"gridType": "solid",
"dashLength": 4,
"scrollShow": true,
"scrollAlign": "left",
"scrollColor": "#A6A6A6",
"scrollBackgroundColor": "#EFEBEF"
},
"yAxis": {},
"legend": {},
"extra": {
"candle": {
"color": {
"upLine": "#f04864",
"upFill": "#f04864",
"downLine": "#2fc25b",
"downFill": "#2fc25b"
},
"average": {
"show": true,
"name": ["MA5", "MA10", "MA30"],
"day": [5, 10, 20],
"color": ["#1890ff", "#2fc25b", "#facc14"]
}
},
"markLine": {
"type": "dash",
"dashLength": 5,
"data": [
{
"value": 2150,
"lineColor": "#f04864",
"showLabel": true
},
{
"value": 2350,
"lineColor": "#f04864",
"showLabel": true
}
]
}
}
},
"mix": {
"type": "mix",
"color": color,
"padding": [15, 15, 0, 15],
"xAxis": {
"disableGrid": true
},
"yAxis": {
"disabled": false,
"disableGrid": false,
"splitNumber": 5,
"gridType": "dash",
"dashLength": 4,
"gridColor": "#CCCCCC",
"padding": 10,
"showTitle": true,
"data": []
},
"legend": {},
"extra": {
"mix": {
"column": {
"width": 20
}
}
}
},
"scatter": {
"type": "scatter",
"color": color,
"padding": [15, 15, 0, 15],
"dataLabel": false,
"xAxis": {
"disableGrid": false,
"gridType": "dash",
"splitNumber": 5,
"boundaryGap": "justify",
"min": 0
},
"yAxis": {
"disableGrid": false,
"gridType": "dash"
},
"legend": {},
"extra": {
"scatter": {}
}
},
"bubble": {
"type": "bubble",
"color": color,
"padding": [15, 15, 0, 15],
"xAxis": {
"disableGrid": false,
"gridType": "dash",
"splitNumber": 5,
"boundaryGap": "justify",
"min": 0,
"max": 250
},
"yAxis": {
"disableGrid": false,
"gridType": "dash",
"data": [{
"min": 0,
"max": 150
}]
},
"legend": {},
"extra": {
"bubble": {
"border": 2,
"opacity": 0.5
}
}
}
};
exports.cfu = cfu;
//# sourceMappingURL=../../../../../.sourcemap/mp-weixin/uni_modules/qiun-data-charts/js_sdk/u-charts/config-ucharts.js.map
File diff suppressed because it is too large Load Diff