@10yun/cv-mobile-ui 0.5.55 → 0.5.57
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/{ui-sdks → other}/qiun-data-charts/js_sdk/u-charts/config-ucharts.js +605 -605
- package/{ui-sdks → other}/qiun-data-charts/package.json +2 -1
- package/other/qiun-data-charts_2.5.0-20230101_example/App.vue +20 -0
- package/other/qiun-data-charts_2.5.0-20230101_example/common/uni-icons.css +542 -0
- package/other/qiun-data-charts_2.5.0-20230101_example/common/uni.css +246 -0
- package/other/qiun-data-charts_2.5.0-20230101_example/components/qiun-title-bar/qiun-title-bar.vue +51 -0
- package/other/qiun-data-charts_2.5.0-20230101_example/components/test-charts/test-charts.vue +48 -0
- package/other/qiun-data-charts_2.5.0-20230101_example/main.js +13 -0
- package/other/qiun-data-charts_2.5.0-20230101_example/manifest.json +75 -0
- package/other/qiun-data-charts_2.5.0-20230101_example/mockdata/demodata.json +448 -0
- package/other/qiun-data-charts_2.5.0-20230101_example/mockdata/mapdata.json +1 -0
- package/other/qiun-data-charts_2.5.0-20230101_example/pages/canvas/canvas.vue +142 -0
- package/other/qiun-data-charts_2.5.0-20230101_example/pages/echarts/echarts.vue +228 -0
- package/other/qiun-data-charts_2.5.0-20230101_example/pages/format-e/format-e.vue +113 -0
- package/other/qiun-data-charts_2.5.0-20230101_example/pages/format-u/format-u.vue +110 -0
- package/other/qiun-data-charts_2.5.0-20230101_example/pages/index/index.vue +58 -0
- package/other/qiun-data-charts_2.5.0-20230101_example/pages/layout/layout.vue +174 -0
- package/other/qiun-data-charts_2.5.0-20230101_example/pages/other/other.vue +233 -0
- package/other/qiun-data-charts_2.5.0-20230101_example/pages/tab/tab.vue +115 -0
- package/other/qiun-data-charts_2.5.0-20230101_example/pages/ucharts/ucharts.vue +339 -0
- package/other/qiun-data-charts_2.5.0-20230101_example/pages/unicloud/unicloud.vue +117 -0
- package/other/qiun-data-charts_2.5.0-20230101_example/pages/updata/updata.vue +212 -0
- package/other/qiun-data-charts_2.5.0-20230101_example/pages.json +79 -0
- package/other/qiun-data-charts_2.5.0-20230101_example/static/logo.png +0 -0
- package/other/qiun-data-charts_2.5.0-20230101_example/uni.scss +76 -0
- package/other/qiun-data-charts_2.5.0-20230101_example/uniCloud-aliyun/database/db_init.json +455 -0
- package/other/qiun-data-charts_2.5.0-20230101_example/uniCloud-aliyun/database/qiun-charts-demo.schema.json +76 -0
- package/other/{u-parse-2019 → u-parse}/components/wxParseTemplate0.vue +2 -1
- package/other/{u-parse-2019 → u-parse}/libs/html2json.js +2 -2
- package/other/{uParse → u-parse}/libs/wxDiscode.js +1 -1
- package/other/u-parse/readme.md +102 -0
- package/other/{u-parse-2019 → u-parse}/u-parse.vue +1 -6
- package/other/u-parse2026/libs/html2json.js +2 -2
- package/other/u-parse2026/libs/wxDiscode.js +1 -1
- package/other/u-parse2026/u-parse.css +1 -0
- package/other/u-parse2026/u-parse.vue +1 -3
- package/other/uParse2/components/wxParseAudio.vue +1 -0
- package/other/{uParse → uParse2}/components/wxParseImg.vue +4 -4
- package/other/{uParse → uParse2}/components/wxParseTable.vue +15 -6
- package/other/{uParse → uParse2}/components/wxParseTemplate0.vue +7 -6
- package/other/{uParse → uParse2}/components/wxParseTemplate1.vue +10 -0
- package/other/{uParse → uParse2}/libs/html2json.js +2 -2
- package/other/{u-parse-2019 → uParse2}/libs/wxDiscode.js +1 -1
- package/other/{uParse/wxParse.css → uParse2/u-parse.css} +4 -4
- package/other/{uParse/wxParse.vue → uParse2/u-parse.vue} +18 -11
- package/other/uParse2/u-parse2.css +264 -0
- package/package.json +1 -1
- package/ui-cv/components/cv-dialog-share/cv-dialog-share.vue +7 -7
- package/ui-cv/components/cv-geo-local/cv-geo-local.vue +1 -1
- package/ui-cv/components/cv-icons/cv-icons.vue +18 -62
- package/ui-cv/components/cv-icons/iconfont/font-default-icons.js +127 -131
- package/ui-cv/components/cv-input-password/cv-input-password.vue +1 -1
- package/ui-cv/components/cv-mask-svg/cv-mask-svg.vue +1 -1
- package/ui-cv/components/cv-mask-svg/mixins.js +16 -12
- package/ui-cv/components/cv-upload-image/cv-upload-image.vue +4 -4
- package/ui-fireui/components/u-share-model/u-share-model.vue +1 -1
- package/ui-fireui/components/u-uploadsamll/u-uploadsamll.vue +1 -1
- package/uview-plus/components/u-dropdown-list/u-dropdown-list.vue +1 -2
- package/uview-plus/components/u-form/form.js +13 -12
- package/uview-plus/components/u-image/u-image-wu.vue +25 -1
- package/uview-plus/components/u-parse/README.md +192 -0
- package/uview-plus/components/u-parse/changelog.md +163 -0
- package/uview-plus/components/u-parse/node/node.vue +37 -3
- package/{uni-ui/lib/uni-breadcrumb → uview-plus/components/u-parse}/package.json +24 -29
- package/uview-plus/components/u-parse/parser.js +8 -3
- package/uview-plus/components/u-parse/static/app-plus/up-parse/js/handler.js +1 -0
- package/uview-plus/components/u-parse/static/app-plus/up-parse/local-2.5.2.html +29 -0
- package/uview-plus/components/u-parse/u-parse.vue +29 -1
- package/other/lime-painter2/README2.md +0 -576
- package/other/lime-painter2/changelog.md +0 -225
- package/other/lime-painter2/package.json +0 -93
- package/other/lime-painter2/readme.md +0 -758
- package/other/lime-painter2/test.md +0 -45
- package/other/qiun-data-charts/qiun-data-charts.vue +0 -1618
- package/other/u-parse-2019/readme.md +0 -99
- package/other/uParse/components/style.css +0 -1
- package/other/uParse/components/wxParseAudio.vue +0 -1
- package/other/xt-parse/changelog.md +0 -41
- package/other/xt-parse/node/node.vue +0 -752
- package/other/xt-parse/package.json +0 -129
- package/other/xt-parse/parser.js +0 -1461
- package/other/xt-parse/props.js +0 -49
- package/other/xt-parse/readme.md +0 -145
- package/other/xt-parse/static/app-plus/u-parse/js/handler.js +0 -1
- package/other/xt-parse/u-parse.vue +0 -510
- package/plugins/luch-request/adapters/index.js +0 -131
- package/plugins/luch-request/core/InterceptorManager.js +0 -50
- package/plugins/luch-request/core/Request.js +0 -199
- package/plugins/luch-request/core/buildFullPath.js +0 -20
- package/plugins/luch-request/core/defaults.js +0 -32
- package/plugins/luch-request/core/dispatchRequest.js +0 -5
- package/plugins/luch-request/core/mergeConfig.js +0 -125
- package/plugins/luch-request/core/settle.js +0 -16
- package/plugins/luch-request/helpers/buildURL.js +0 -71
- package/plugins/luch-request/helpers/combineURLs.js +0 -12
- package/plugins/luch-request/helpers/isAbsoluteURL.js +0 -14
- package/plugins/luch-request/index.d.ts +0 -197
- package/plugins/luch-request/index.js +0 -2
- package/plugins/luch-request/readme.md +0 -3
- package/plugins/luch-request/utils/clone.js +0 -260
- package/plugins/luch-request/utils.js +0 -131
- package/ui-cv/components/cv-cell-row/cv-cell-row.vue +0 -220
- package/ui-cv/components/cv-icons/iconfont/font-action-icons.js +0 -73
- package/ui-cv/components/cv-icons/iconfont/font-action.css +0 -7
- package/ui-cv/components/cv-icons/iconfont/font-action.js +0 -5
- package/ui-cv/components/cv-icons/iconfont/font-arrow-icons.js +0 -47
- package/ui-cv/components/cv-icons/iconfont/font-arrow.css +0 -6
- package/ui-cv/components/cv-icons/iconfont/font-arrow.js +0 -5
- package/ui-cv/components/cv-icons/iconfont/font-base-icons.js +0 -92
- package/ui-cv/components/cv-icons/iconfont/font-base.css +0 -6
- package/ui-cv/components/cv-icons/iconfont/font-base.js +0 -5
- package/ui-cv/components/cv-icons/iconfont/font-mall-icons.js +0 -35
- package/ui-cv/components/cv-icons/iconfont/font-mall.css +0 -7
- package/ui-cv/components/cv-icons/iconfont/font-mall.js +0 -5
- package/ui-cv/components/cv-icons/iconfont/font-media-icons.js +0 -45
- package/ui-cv/components/cv-icons/iconfont/font-media.css +0 -7
- package/ui-cv/components/cv-icons/iconfont/font-media.js +0 -5
- package/ui-cv/components/cv-icons/iconfont/font-order-icons.js +0 -34
- package/ui-cv/components/cv-icons/iconfont/font-order.css +0 -6
- package/ui-cv/components/cv-icons/iconfont/font-order.js +0 -5
- package/ui-cv/components/cv-icons/iconfont/font-people-icons.js +0 -49
- package/ui-cv/components/cv-icons/iconfont/font-people.css +0 -7
- package/ui-cv/components/cv-icons/iconfont/font-people.js +0 -5
- package/ui-cv/components/cv-icons/iconfont/font-status-icons.js +0 -34
- package/ui-cv/components/cv-icons/iconfont/font-status.css +0 -6
- package/ui-cv/components/cv-icons/iconfont/font-status.js +0 -5
- package/ui-cv/components/cv-icons/iconfont/font-wallet-icons.js +0 -17
- package/ui-cv/components/cv-icons/iconfont/font-wallet.css +0 -6
- package/ui-cv/components/cv-icons/iconfont/font-wallet.js +0 -5
- package/ui-cv/components/cv-icons/icons/default-icons.js +0 -132
- package/ui-cv/components/cv-icons/icons/icons-action.js +0 -72
- package/ui-cv/components/cv-icons/icons/icons-arrow.js +0 -46
- package/ui-cv/components/cv-icons/icons/icons-base.js +0 -89
- package/ui-cv/components/cv-icons/icons/icons-mall.js +0 -34
- package/ui-cv/components/cv-icons/icons/icons-media.js +0 -44
- package/ui-cv/components/cv-icons/icons/icons-order.js +0 -33
- package/ui-cv/components/cv-icons/icons/icons-people.js +0 -46
- package/ui-cv/components/cv-icons/icons/icons-status.js +0 -32
- package/ui-cv/components/cv-icons/icons/icons-wallet.js +0 -15
- package/ui-sdks/sdk-app-update/img/logo.png +0 -0
- package/ui-sdks/sdk-app-update/img/update_bg.png +0 -0
- package/ui-sdks/sdk-app-update/img/update_bg_top.png +0 -0
- package/ui-sdks/sdk-app-update/sdk-app-update.vue +0 -396
- package/ui-sdks/sdk-app-update/xxxx +0 -62
- package/ui-sdks/sdk-privacy-policy/sdk-privacy-policy.vue +0 -113
- package/ui-sdks/sdk-u-charts/config-echarts.js +0 -420
- package/ui-sdks/sdk-u-charts/config-ucharts.js +0 -630
- package/ui-sdks/sdk-u-charts/u-charts.js +0 -7398
- package/ui-sdks/sdk-u-charts/u-charts.min.js +0 -1
- package/ui-sdks/sdk-webview-main/WebViewMain.vue +0 -1
- package/ui-sdks/sdk-webview-main/main.js +0 -0
- package/ui-sdks/sdk-webview-main/mixin.js +0 -0
- package/uni-ui/lib/uni-badge/changelog.md +0 -33
- package/uni-ui/lib/uni-badge/package.json +0 -107
- package/uni-ui/lib/uni-badge/readme.md +0 -8
- package/uni-ui/lib/uni-breadcrumb/changelog.md +0 -6
- package/uni-ui/lib/uni-breadcrumb/readme.md +0 -66
- package/uni-ui/lib/uni-calendar/changelog.md +0 -30
- package/uni-ui/lib/uni-calendar/package.json +0 -105
- package/uni-ui/lib/uni-calendar/readme.md +0 -103
- package/uni-ui/lib/uni-card/changelog.md +0 -26
- package/uni-ui/lib/uni-card/package.json +0 -107
- package/uni-ui/lib/uni-card/readme.md +0 -10
- package/uni-ui/lib/uni-collapse/changelog.md +0 -48
- package/uni-ui/lib/uni-collapse/package.json +0 -106
- package/uni-ui/lib/uni-collapse/readme.md +0 -11
- package/uni-ui/lib/uni-combox/changelog.md +0 -17
- package/uni-ui/lib/uni-combox/package.json +0 -107
- package/uni-ui/lib/uni-combox/readme.md +0 -10
- package/uni-ui/lib/uni-countdown/changelog.md +0 -30
- package/uni-ui/lib/uni-countdown/package.json +0 -105
- package/uni-ui/lib/uni-countdown/readme.md +0 -9
- package/uni-ui/lib/uni-data-checkbox/changelog.md +0 -51
- package/uni-ui/lib/uni-data-checkbox/package.json +0 -107
- package/uni-ui/lib/uni-data-checkbox/readme.md +0 -17
- package/uni-ui/lib/uni-data-picker/changelog.md +0 -81
- package/uni-ui/lib/uni-data-picker/package.json +0 -109
- package/uni-ui/lib/uni-data-picker/readme.md +0 -21
- package/uni-ui/lib/uni-data-select/changelog.md +0 -51
- package/uni-ui/lib/uni-data-select/package.json +0 -106
- package/uni-ui/lib/uni-data-select/readme.md +0 -7
- package/uni-ui/lib/uni-dateformat/changelog.md +0 -10
- package/uni-ui/lib/uni-dateformat/package.json +0 -107
- package/uni-ui/lib/uni-dateformat/readme.md +0 -10
- package/uni-ui/lib/uni-datetime-picker/changelog.md +0 -177
- package/uni-ui/lib/uni-datetime-picker/package.json +0 -107
- package/uni-ui/lib/uni-datetime-picker/readme.md +0 -20
- package/uni-ui/lib/uni-drawer/changelog.md +0 -13
- package/uni-ui/lib/uni-drawer/package.json +0 -106
- package/uni-ui/lib/uni-drawer/readme.md +0 -9
- package/uni-ui/lib/uni-easyinput/changelog.md +0 -121
- package/uni-ui/lib/uni-easyinput/package.json +0 -107
- package/uni-ui/lib/uni-easyinput/readme.md +0 -10
- package/uni-ui/lib/uni-fab/changelog.md +0 -25
- package/uni-ui/lib/uni-fab/package.json +0 -107
- package/uni-ui/lib/uni-fab/readme.md +0 -8
- package/uni-ui/lib/uni-fav/changelog.md +0 -19
- package/uni-ui/lib/uni-fav/package.json +0 -106
- package/uni-ui/lib/uni-fav/readme.md +0 -9
- package/uni-ui/lib/uni-file-picker/changelog.md +0 -91
- package/uni-ui/lib/uni-file-picker/package.json +0 -105
- package/uni-ui/lib/uni-file-picker/readme.md +0 -10
- package/uni-ui/lib/uni-forms/changelog.md +0 -100
- package/uni-ui/lib/uni-forms/package.json +0 -107
- package/uni-ui/lib/uni-forms/readme.md +0 -22
- package/uni-ui/lib/uni-goods-nav/changelog.md +0 -18
- package/uni-ui/lib/uni-goods-nav/package.json +0 -105
- package/uni-ui/lib/uni-goods-nav/readme.md +0 -9
- package/uni-ui/lib/uni-grid/changelog.md +0 -13
- package/uni-ui/lib/uni-grid/package.json +0 -106
- package/uni-ui/lib/uni-grid/readme.md +0 -10
- package/uni-ui/lib/uni-group/changelog.md +0 -16
- package/uni-ui/lib/uni-group/package.json +0 -106
- package/uni-ui/lib/uni-group/readme.md +0 -8
- package/uni-ui/lib/uni-icons/changelog.md +0 -44
- package/uni-ui/lib/uni-icons/package.json +0 -111
- package/uni-ui/lib/uni-icons/readme.md +0 -7
- package/uni-ui/lib/uni-indexed-list/changelog.md +0 -19
- package/uni-ui/lib/uni-indexed-list/package.json +0 -107
- package/uni-ui/lib/uni-indexed-list/readme.md +0 -10
- package/uni-ui/lib/uni-link/changelog.md +0 -17
- package/uni-ui/lib/uni-link/package.json +0 -106
- package/uni-ui/lib/uni-link/readme.md +0 -10
- package/uni-ui/lib/uni-list/changelog.md +0 -52
- package/uni-ui/lib/uni-list/package.json +0 -108
- package/uni-ui/lib/uni-list/readme.md +0 -44
- package/uni-ui/lib/uni-load-more/changelog.md +0 -27
- package/uni-ui/lib/uni-load-more/package.json +0 -105
- package/uni-ui/lib/uni-load-more/readme.md +0 -12
- package/uni-ui/lib/uni-nav-bar/changelog.md +0 -64
- package/uni-ui/lib/uni-nav-bar/package.json +0 -106
- package/uni-ui/lib/uni-nav-bar/readme.md +0 -13
- package/uni-ui/lib/uni-notice-bar/changelog.md +0 -22
- package/uni-ui/lib/uni-notice-bar/package.json +0 -107
- package/uni-ui/lib/uni-notice-bar/readme.md +0 -11
- package/uni-ui/lib/uni-number-box/changelog.md +0 -39
- package/uni-ui/lib/uni-number-box/package.json +0 -104
- package/uni-ui/lib/uni-number-box/readme.md +0 -11
- package/uni-ui/lib/uni-pagination/changelog.md +0 -27
- package/uni-ui/lib/uni-pagination/package.json +0 -106
- package/uni-ui/lib/uni-pagination/readme.md +0 -10
- package/uni-ui/lib/uni-popup/changelog.md +0 -102
- package/uni-ui/lib/uni-popup/package.json +0 -107
- package/uni-ui/lib/uni-popup/readme.md +0 -15
- package/uni-ui/lib/uni-rate/changelog.md +0 -27
- package/uni-ui/lib/uni-rate/package.json +0 -106
- package/uni-ui/lib/uni-rate/readme.md +0 -11
- package/uni-ui/lib/uni-row/changelog.md +0 -10
- package/uni-ui/lib/uni-row/package.json +0 -106
- package/uni-ui/lib/uni-row/readme.md +0 -9
- package/uni-ui/lib/uni-scss/changelog.md +0 -8
- package/uni-ui/lib/uni-scss/package.json +0 -99
- package/uni-ui/lib/uni-scss/readme.md +0 -3
- package/uni-ui/lib/uni-search-bar/changelog.md +0 -47
- package/uni-ui/lib/uni-search-bar/package.json +0 -106
- package/uni-ui/lib/uni-search-bar/readme.md +0 -12
- package/uni-ui/lib/uni-section/changelog.md +0 -2
- package/uni-ui/lib/uni-section/package.json +0 -104
- package/uni-ui/lib/uni-section/readme.md +0 -7
- package/uni-ui/lib/uni-segmented-control/changelog.md +0 -15
- package/uni-ui/lib/uni-segmented-control/package.json +0 -106
- package/uni-ui/lib/uni-segmented-control/readme.md +0 -11
- package/uni-ui/lib/uni-steps/changelog.md +0 -18
- package/uni-ui/lib/uni-steps/package.json +0 -106
- package/uni-ui/lib/uni-steps/readme.md +0 -11
- package/uni-ui/lib/uni-swipe-action/changelog.md +0 -60
- package/uni-ui/lib/uni-swipe-action/package.json +0 -113
- package/uni-ui/lib/uni-swipe-action/readme.md +0 -10
- package/uni-ui/lib/uni-swiper-dot/changelog.md +0 -12
- package/uni-ui/lib/uni-swiper-dot/package.json +0 -106
- package/uni-ui/lib/uni-swiper-dot/readme.md +0 -10
- package/uni-ui/lib/uni-table/changelog.md +0 -35
- package/uni-ui/lib/uni-table/package.json +0 -106
- package/uni-ui/lib/uni-table/readme.md +0 -11
- package/uni-ui/lib/uni-tag/changelog.md +0 -25
- package/uni-ui/lib/uni-tag/package.json +0 -106
- package/uni-ui/lib/uni-tag/readme.md +0 -11
- package/uni-ui/lib/uni-title/changelog.md +0 -10
- package/uni-ui/lib/uni-title/package.json +0 -107
- package/uni-ui/lib/uni-title/readme.md +0 -12
- package/uni-ui/lib/uni-tooltip/changelog.md +0 -16
- package/uni-ui/lib/uni-tooltip/package.json +0 -104
- package/uni-ui/lib/uni-tooltip/readme.md +0 -7
- package/uni-ui/lib/uni-transition/changelog.md +0 -31
- package/uni-ui/lib/uni-transition/package.json +0 -112
- package/uni-ui/lib/uni-transition/readme.md +0 -10
- package/uni-ui/lib/uni-ui/changelog.md +0 -639
- package/uni-ui/lib/uni-ui/package.json +0 -148
- package/uni-ui/lib/uni-ui/readme.md +0 -247
- /package/other/{lime-painter2/components/lime-painter → lime-painter/components/lime-painter2}/canvas.js +0 -0
- /package/other/{lime-painter2/components/lime-painter → lime-painter/components/lime-painter2}/draw.js +0 -0
- /package/other/{lime-painter2/components/lime-painter → lime-painter/components/lime-painter2}/draw2.js +0 -0
- /package/other/{lime-painter2/components/lime-painter → lime-painter/components/lime-painter2}/gradient.js +0 -0
- /package/other/{lime-painter2/components/lime-painter → lime-painter/components/lime-painter2}/index.vue +0 -0
- /package/other/{lime-painter2/components/lime-painter → lime-painter/components/lime-painter2}/index2.vue +0 -0
- /package/other/{lime-painter2/components/lime-painter → lime-painter/components/lime-painter2}/layout.js +0 -0
- /package/other/{lime-painter2/components/lime-painter → lime-painter/components/lime-painter2}/qrcode.js +0 -0
- /package/other/{lime-painter2/components/lime-painter → lime-painter/components/lime-painter2}/utils.js +0 -0
- /package/{ui-sdks → other}/qiun-data-charts/changelog.md +0 -0
- /package/{ui-sdks → other}/qiun-data-charts/components/qiun-data-charts/qiun-data-charts.vue +0 -0
- /package/{ui-sdks → other}/qiun-data-charts/components/qiun-error/qiun-error.vue +0 -0
- /package/{ui-sdks → other}/qiun-data-charts/components/qiun-loading/loading1.vue +0 -0
- /package/{ui-sdks → other}/qiun-data-charts/components/qiun-loading/loading2.vue +0 -0
- /package/{ui-sdks → other}/qiun-data-charts/components/qiun-loading/loading3.vue +0 -0
- /package/{ui-sdks → other}/qiun-data-charts/components/qiun-loading/loading4.vue +0 -0
- /package/{ui-sdks → other}/qiun-data-charts/components/qiun-loading/loading5.vue +0 -0
- /package/{ui-sdks → other}/qiun-data-charts/components/qiun-loading/qiun-loading.vue +0 -0
- /package/{ui-sdks → other}/qiun-data-charts/js_sdk/u-charts/config-echarts.js +0 -0
- /package/{ui-sdks → other}/qiun-data-charts/js_sdk/u-charts/readme.md +0 -0
- /package/{ui-sdks → other}/qiun-data-charts/js_sdk/u-charts/u-charts.js +0 -0
- /package/{ui-sdks → other}/qiun-data-charts/js_sdk/u-charts/u-charts.min.js +0 -0
- /package/{ui-sdks/sdk-u-charts → other/qiun-data-charts/js_sdk2}/app-echarts.min.js +0 -0
- /package/{ui-sdks/sdk-u-charts → other/qiun-data-charts/js_sdk2}/h5-echarts.min.js +0 -0
- /package/{ui-sdks → other}/qiun-data-charts/license.md +0 -0
- /package/{ui-sdks → other}/qiun-data-charts/readme.md +0 -0
- /package/{ui-sdks → other}/qiun-data-charts/static/app-plus/echarts.min.js +0 -0
- /package/{ui-sdks → other}/qiun-data-charts/static/h5/echarts.min.js +0 -0
- /package/{ui-sdks → other}/tui-clipboard/tui-clipboard.js +0 -0
- /package/other/{u-parse-2019 → u-parse}/components/wxParseAudio.vue +0 -0
- /package/other/{u-parse-2019 → u-parse}/components/wxParseImg.vue +0 -0
- /package/other/{u-parse-2019 → u-parse}/components/wxParseTemplate1.vue +0 -0
- /package/other/{u-parse-2019 → u-parse}/components/wxParseTemplate10.vue +0 -0
- /package/other/{u-parse-2019 → u-parse}/components/wxParseTemplate11.vue +0 -0
- /package/other/{u-parse-2019 → u-parse}/components/wxParseTemplate2.vue +0 -0
- /package/other/{u-parse-2019 → u-parse}/components/wxParseTemplate3.vue +0 -0
- /package/other/{u-parse-2019 → u-parse}/components/wxParseTemplate4.vue +0 -0
- /package/other/{u-parse-2019 → u-parse}/components/wxParseTemplate5.vue +0 -0
- /package/other/{u-parse-2019 → u-parse}/components/wxParseTemplate6.vue +0 -0
- /package/other/{u-parse-2019 → u-parse}/components/wxParseTemplate7.vue +0 -0
- /package/other/{u-parse-2019 → u-parse}/components/wxParseTemplate8.vue +0 -0
- /package/other/{u-parse-2019 → u-parse}/components/wxParseTemplate9.vue +0 -0
- /package/other/{u-parse-2019 → u-parse}/components/wxParseVideo.vue +0 -0
- /package/other/{u-parse-2019 → u-parse}/libs/htmlparser.js +0 -0
- /package/other/{u-parse-2019 → u-parse}/u-parse.css +0 -0
- /package/other/{uParse → uParse2}/components/wxParseTemplate10.vue +0 -0
- /package/other/{uParse → uParse2}/components/wxParseTemplate11.vue +0 -0
- /package/other/{uParse → uParse2}/components/wxParseTemplate2.vue +0 -0
- /package/other/{uParse → uParse2}/components/wxParseTemplate3.vue +0 -0
- /package/other/{uParse → uParse2}/components/wxParseTemplate4.vue +0 -0
- /package/other/{uParse → uParse2}/components/wxParseTemplate5.vue +0 -0
- /package/other/{uParse → uParse2}/components/wxParseTemplate6.vue +0 -0
- /package/other/{uParse → uParse2}/components/wxParseTemplate7.vue +0 -0
- /package/other/{uParse → uParse2}/components/wxParseTemplate8.vue +0 -0
- /package/other/{uParse → uParse2}/components/wxParseTemplate9.vue +0 -0
- /package/other/{uParse → uParse2}/components/wxParseVideo.vue +0 -0
- /package/other/{uParse → uParse2}/editor.css +0 -0
- /package/other/{uParse → uParse2}/libs/htmlparser.js +0 -0
- /package/{other/xt-parse/static/app-plus/u-parse → uview-plus/components/u-parse/static/app-plus/up-parse}/js/handler2.js +0 -0
- /package/{other/xt-parse/static/app-plus/u-parse → uview-plus/components/u-parse/static/app-plus/up-parse}/js/uni.webview.min.js +0 -0
- /package/{other/xt-parse/static/app-plus/u-parse → uview-plus/components/u-parse/static/app-plus/up-parse}/js/uni.webview.min2.js +0 -0
- /package/{other/xt-parse/static/app-plus/u-parse → uview-plus/components/u-parse/static/app-plus/up-parse}/local.html +0 -0
|
@@ -0,0 +1,174 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<view class="content">
|
|
3
|
+
<qiun-title-bar title="在swiper中使用"/>
|
|
4
|
+
<swiper style="height: 330px;" :indicator-dots="true">
|
|
5
|
+
<swiper-item>
|
|
6
|
+
<view class="charts-box">
|
|
7
|
+
<qiun-data-charts type="line" :chartData="chartsDataColumn1" :canvas2d="true" canvasId="swiperida" :inScrollView="true" :pageScrollTop="pageScrollTop"/>
|
|
8
|
+
</view>
|
|
9
|
+
</swiper-item>
|
|
10
|
+
<swiper-item>
|
|
11
|
+
<view class="charts-box">
|
|
12
|
+
<qiun-data-charts type="column" :chartData="chartsDataColumn1" :canvas2d="true" canvasId="swiperidb" :inScrollView="true" :pageScrollTop="pageScrollTop"/>
|
|
13
|
+
</view>
|
|
14
|
+
</swiper-item>
|
|
15
|
+
<swiper-item>
|
|
16
|
+
<view class="charts-box">
|
|
17
|
+
<qiun-data-charts type="area" :chartData="chartsDataColumn1" :canvas2d="true" canvasId="swiperidc" :inScrollView="true" :pageScrollTop="pageScrollTop"/>
|
|
18
|
+
</view>
|
|
19
|
+
</swiper-item>
|
|
20
|
+
</swiper>
|
|
21
|
+
|
|
22
|
+
|
|
23
|
+
<qiun-title-bar title="在scroll-view中使用"/>
|
|
24
|
+
<scroll-view style="height: 400px;" :scroll-y="true">
|
|
25
|
+
<view class="charts-box">
|
|
26
|
+
<!-- 如果您的scroll-view可能和我这个一样,既有页面滚动,还有scroll-view滚动,这种情况下,需要动态传入offsetTop的值为页面滚动条滚动的距离 -->
|
|
27
|
+
<qiun-data-charts type="column" :chartData="chartsDataColumn1" canvasId="scroll-viewid" :inScrollView="true" :pageScrollTop="pageScrollTop"/>
|
|
28
|
+
</view>
|
|
29
|
+
<view style="height: 300px;background: #1890FF;">
|
|
30
|
+
|
|
31
|
+
</view>
|
|
32
|
+
</scroll-view>
|
|
33
|
+
|
|
34
|
+
|
|
35
|
+
<qiun-title-bar title="父元素fixed定位"/>
|
|
36
|
+
<view class="botton-box">
|
|
37
|
+
<button class="uni-button" type="default" @click="openfixed">点击显示弹出层</button>
|
|
38
|
+
</view>
|
|
39
|
+
|
|
40
|
+
|
|
41
|
+
<qiun-title-bar title="组件套组件示例(尽量别这么用)"/>
|
|
42
|
+
<test-charts :pageScrollTop="pageScrollTop"/>
|
|
43
|
+
|
|
44
|
+
|
|
45
|
+
|
|
46
|
+
<qiun-title-bar title="使用v-for生成图表"/>
|
|
47
|
+
<view class="charts-box" v-for="(item, index) in listA" :key="item.id">
|
|
48
|
+
<!-- 建议循环使用时,加上key值 -->
|
|
49
|
+
<qiun-data-charts :key="item.id" :type="item.type" :chartData="item.chartData" :animation="false"/>
|
|
50
|
+
</view>
|
|
51
|
+
<qiun-title-bar title="使用v-for生成图表2"/>
|
|
52
|
+
<view class="charts-box" v-for="(item, index) in listB" :key="item.id">
|
|
53
|
+
<!-- 建议循环使用时,加上key值 -->
|
|
54
|
+
<qiun-data-charts :key="item.id" :type="item.type" :chartData="item.chartData" :canvas2d="true" :canvasId="item.id" :animation="false"/>
|
|
55
|
+
</view>
|
|
56
|
+
|
|
57
|
+
|
|
58
|
+
<view class="fix-class" v-if="fixedzt">
|
|
59
|
+
<view class="fix-bottom">
|
|
60
|
+
<view class="close-title" @click="openfixed">点击此处关闭弹窗</view>
|
|
61
|
+
<qiun-title-bar title="父元素fixed定位"/>
|
|
62
|
+
<view class="charts-box">
|
|
63
|
+
<qiun-data-charts type="area" :chartData="chartsDataColumn1" :canvas2d="true" canvasId="fixedcanvasid" :inScrollView="true" :pageScrollTop="pageScrollTop"/>
|
|
64
|
+
</view>
|
|
65
|
+
</view>
|
|
66
|
+
</view>
|
|
67
|
+
|
|
68
|
+
</view>
|
|
69
|
+
</template>
|
|
70
|
+
|
|
71
|
+
<script>
|
|
72
|
+
//下面是演示数据,您的项目不需要引用,数据需要您从服务器自行获取
|
|
73
|
+
import demodata from '@/mockdata/demodata.json';
|
|
74
|
+
|
|
75
|
+
export default {
|
|
76
|
+
data() {
|
|
77
|
+
return {
|
|
78
|
+
chartsDataColumn1: {},
|
|
79
|
+
pageScrollTop:0,
|
|
80
|
+
fixedzt:false,
|
|
81
|
+
absolutezt:false,
|
|
82
|
+
listA:[],
|
|
83
|
+
listB:[]
|
|
84
|
+
};
|
|
85
|
+
},
|
|
86
|
+
onReady() {
|
|
87
|
+
//模拟从服务器获取数据
|
|
88
|
+
this.getServerData()
|
|
89
|
+
|
|
90
|
+
//模拟v-for数据变化
|
|
91
|
+
setTimeout(() => {
|
|
92
|
+
this.listA=[
|
|
93
|
+
{id:"xlsldkfjiw1",type:'area',chartData:JSON.parse(JSON.stringify(demodata.Column))},
|
|
94
|
+
{id:"docldkfjiw2",type:'line',chartData:JSON.parse(JSON.stringify(demodata.Line))},
|
|
95
|
+
{id:"pptldkfjiw3",type:'column',chartData:JSON.parse(JSON.stringify(demodata.Column))}
|
|
96
|
+
]
|
|
97
|
+
this.listB=[
|
|
98
|
+
{id:"xlsldkfjiw4b",type:'area',chartData:JSON.parse(JSON.stringify(demodata.Column))},
|
|
99
|
+
{id:"docldkfjiw5b",type:'line',chartData:JSON.parse(JSON.stringify(demodata.Line))},
|
|
100
|
+
{id:"pptldkfjiw6b",type:'column',chartData:JSON.parse(JSON.stringify(demodata.Column))}
|
|
101
|
+
]
|
|
102
|
+
},5000)
|
|
103
|
+
},
|
|
104
|
+
onPageScroll(e) {
|
|
105
|
+
this.pageScrollTop = e.scrollTop
|
|
106
|
+
},
|
|
107
|
+
methods: {
|
|
108
|
+
getServerData() {
|
|
109
|
+
setTimeout(() => {
|
|
110
|
+
//因部分数据格式一样,这里不同图表引用同一数据源的话,需要深拷贝一下构造不同的对象
|
|
111
|
+
//开发者需要自行处理服务器返回的数据,应与标准数据格式一致,注意series的data数值应为数字格式
|
|
112
|
+
this.chartsDataColumn1=JSON.parse(JSON.stringify(demodata.Column))
|
|
113
|
+
|
|
114
|
+
this.listA=[
|
|
115
|
+
{id:"xlsldkfjiw1",type:'line',chartData:JSON.parse(JSON.stringify(demodata.Line))},
|
|
116
|
+
{id:"docldkfjiw2",type:'column',chartData:JSON.parse(JSON.stringify(demodata.Column))},
|
|
117
|
+
{id:"pptldkfjiw3",type:'area',chartData:JSON.parse(JSON.stringify(demodata.Line))}
|
|
118
|
+
]
|
|
119
|
+
|
|
120
|
+
this.listB=[
|
|
121
|
+
{id:"xlsldkfjiw4b",type:'line',chartData:JSON.parse(JSON.stringify(demodata.Line))},
|
|
122
|
+
{id:"docldkfjiw5b",type:'column',chartData:JSON.parse(JSON.stringify(demodata.Column))},
|
|
123
|
+
{id:"pptldkfjiw6b",type:'area',chartData:JSON.parse(JSON.stringify(demodata.Line))}
|
|
124
|
+
]
|
|
125
|
+
}, 1500);
|
|
126
|
+
},
|
|
127
|
+
openfixed(){
|
|
128
|
+
this.fixedzt = !this.fixedzt
|
|
129
|
+
},
|
|
130
|
+
openabsolute(){
|
|
131
|
+
|
|
132
|
+
}
|
|
133
|
+
}
|
|
134
|
+
};
|
|
135
|
+
</script>
|
|
136
|
+
|
|
137
|
+
<style>
|
|
138
|
+
.content {
|
|
139
|
+
display: flex;
|
|
140
|
+
flex-direction: column;
|
|
141
|
+
flex: 1;
|
|
142
|
+
}
|
|
143
|
+
.charts-box {
|
|
144
|
+
width: 100%;
|
|
145
|
+
height: 300px;
|
|
146
|
+
}
|
|
147
|
+
.botton-box{
|
|
148
|
+
display: flex;
|
|
149
|
+
align-items: center;
|
|
150
|
+
justify-content: center;
|
|
151
|
+
height: 80px;
|
|
152
|
+
}
|
|
153
|
+
.fix-class{
|
|
154
|
+
position: fixed;
|
|
155
|
+
top:0;
|
|
156
|
+
height: 100vh;
|
|
157
|
+
width: 100vw;
|
|
158
|
+
background: rgba(0,0,0,0.3);
|
|
159
|
+
}
|
|
160
|
+
.fix-bottom{
|
|
161
|
+
position: fixed;
|
|
162
|
+
bottom:0;
|
|
163
|
+
height: 400px;
|
|
164
|
+
width: 100vw;
|
|
165
|
+
border-radius: 15px 15px 0px 0px;
|
|
166
|
+
background: #FFFFFF;
|
|
167
|
+
}
|
|
168
|
+
.close-title{
|
|
169
|
+
border-bottom: 1px solid #999999;
|
|
170
|
+
text-align: center;
|
|
171
|
+
line-height: 30px;
|
|
172
|
+
height: 30px;
|
|
173
|
+
}
|
|
174
|
+
</style>
|
|
@@ -0,0 +1,233 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<view class="content">
|
|
3
|
+
<qiun-title-bar title="localdata渲染图表1+点击获取索引"/>
|
|
4
|
+
<view class="charts-box">
|
|
5
|
+
<!-- 只需绑定@getIndex即可获取点击索引 -->
|
|
6
|
+
<qiun-data-charts type="column" :localdata="chartsDatalocaldataA" @getIndex="getIndex"/>
|
|
7
|
+
</view>
|
|
8
|
+
<qiun-title-bar title="localdata渲染图表2+禁用鼠标移动"/>
|
|
9
|
+
<view class="charts-box">
|
|
10
|
+
<qiun-data-charts type="pie" :localdata="chartsDatalocaldataB" :onmouse="false"/>
|
|
11
|
+
</view>
|
|
12
|
+
<qiun-title-bar title="渲染完成后显示自定义tooltip" />
|
|
13
|
+
<view class="charts-box">
|
|
14
|
+
<!-- 渲染完成后进行操作图表,需要绑定@complete事件,然后在@complete事件中进行操作 -->
|
|
15
|
+
<qiun-data-charts
|
|
16
|
+
type="column"
|
|
17
|
+
:chartData="chartsDataColumn1"
|
|
18
|
+
@complete="complete"
|
|
19
|
+
/>
|
|
20
|
+
</view>
|
|
21
|
+
<qiun-title-bar title="跟手tooltip示例" />
|
|
22
|
+
<view class="charts-box" >
|
|
23
|
+
<!-- 开启onmovetip后,建议同时开启canvas2d模式(需要传canvasId),否则在小程序端会很卡。开启onmovetip功能的前提是需要开启ontouch,并且关闭图表滚动条,即:opts="{enableScroll: false}" -->
|
|
24
|
+
<qiun-data-charts
|
|
25
|
+
type="column"
|
|
26
|
+
:opts="{enableScroll: false}"
|
|
27
|
+
canvasId="canvas2dNeedId"
|
|
28
|
+
:chartData="chartsDataColumn1"
|
|
29
|
+
:canvas2d="true"
|
|
30
|
+
:ontouch="true"
|
|
31
|
+
:onmovetip="true"
|
|
32
|
+
@getTouchMove="getTouchMove"
|
|
33
|
+
/>
|
|
34
|
+
</view>
|
|
35
|
+
<qiun-title-bar title="固定位置显示tooltip+禁用图例点击" />
|
|
36
|
+
<view class="charts-box">
|
|
37
|
+
<!-- 这个demo演示自定义tooltip的样式及增加额外的数据,例如换行等 -->
|
|
38
|
+
<qiun-data-charts
|
|
39
|
+
type="line"
|
|
40
|
+
:opts="{extra:{tooltip:{showArrow: false,borderWidth: 1,borderRadius:8,borderColor: '#FF0000',bgColor: '#FFFFFF',bgOpacity: 0.9,fontColor: '#000000',splitLine: false}}}"
|
|
41
|
+
:chartData="chartsDataColumn1"
|
|
42
|
+
:tapLegend="false"
|
|
43
|
+
:tooltipCustom="{x:2,y:2}"
|
|
44
|
+
/>
|
|
45
|
+
</view>
|
|
46
|
+
<qiun-title-bar title="自定义tooltip(textList换行),内置方法" />
|
|
47
|
+
<view class="charts-box">
|
|
48
|
+
<!-- 需要关闭组件的tooltip,即:tooltipShow="false",然后在@getIndex中调用uCharts的showTooltip方法,注意,APP端不能实现,其他端需要引用config-ucharts.js作为实例承载的中间件。 -->
|
|
49
|
+
<!-- 如果需要做跟手tooltip,需要在@getTouchMove事件中调用,注意需要添加防抖,可参考组件内防抖方法,否则会导致逻辑层与视图层频繁通信造成卡顿 -->
|
|
50
|
+
<qiun-data-charts
|
|
51
|
+
type="line"
|
|
52
|
+
:tooltipShow="false"
|
|
53
|
+
:chartData="chartsDataColumn1"
|
|
54
|
+
@getIndex="showMyTooltip"
|
|
55
|
+
/>
|
|
56
|
+
</view>
|
|
57
|
+
<qiun-title-bar title="自定义tooltip(textList换行),opts参数" />
|
|
58
|
+
<view class="charts-box">
|
|
59
|
+
<!-- 需要关闭组件的tooltip,即:tooltipShow="false",然后在@getIndex中改变opts来实现tooltip,注意,APP端不能实现,其他端需要引用config-ucharts.js作为实例承载的中间件。 -->
|
|
60
|
+
<qiun-data-charts
|
|
61
|
+
type="line"
|
|
62
|
+
:opts="optsTooltip"
|
|
63
|
+
:animation="false"
|
|
64
|
+
:tooltipShow="false"
|
|
65
|
+
:chartData="chartsDataColumn1"
|
|
66
|
+
@getIndex="showOptsTooltip"
|
|
67
|
+
/>
|
|
68
|
+
</view>
|
|
69
|
+
<qiun-title-bar title="强制展示错误信息"/>
|
|
70
|
+
<button class="uni-button" type="default" @click="changeErrorMessage">点击展示错误信息</button>
|
|
71
|
+
<view class="charts-box">
|
|
72
|
+
<qiun-data-charts type="line" :chartData="chartsDataLine1" :errorMessage="errorMessage" :errorReload="false" @error="error"/>
|
|
73
|
+
</view>
|
|
74
|
+
<qiun-title-bar title="uCharts保存为图片"/>
|
|
75
|
+
<button class="uni-button" type="default" @click="createImage('createImageUCharts')">点击保存为图片</button>
|
|
76
|
+
<view class="charts-box">
|
|
77
|
+
<qiun-data-charts type="area" ref="createImageUCharts" :chartData="chartsDataLine1" @getImage="getImage"/>
|
|
78
|
+
</view>
|
|
79
|
+
</view>
|
|
80
|
+
</template>
|
|
81
|
+
|
|
82
|
+
<script>
|
|
83
|
+
//下面是演示数据,您的项目不需要引用,数据需要您从服务器自行获取
|
|
84
|
+
import demodata from '@/mockdata/demodata.json';
|
|
85
|
+
|
|
86
|
+
//下面是uCharts的配置文件及qiun-data-charts组件的公用中转参数,可以从本配置文件中获取uCharts实例、opts配置、format配置(APP端因采用renderjs无法从此配置文件获取uCharts实例)
|
|
87
|
+
//***并不是所有的页面都需要引用这个文件***引入这个configjs是为了获取组件的uCharts实例,从而操作uCharts的一些方法,例如手动显示tooltip及一些其他uCharts包含的方法及事件。
|
|
88
|
+
//再说一遍,只能在H5内使用,APP不行,APP不行,APP不行(如果需要自定义tooltip,也可以通过opts中传递tooltip参数来实现模拟显示tooltip,详见showOptsTooltip方法)
|
|
89
|
+
import uCharts from '@/uni_modules/qiun-data-charts/js_sdk/u-charts/config-ucharts.js';
|
|
90
|
+
|
|
91
|
+
export default {
|
|
92
|
+
data() {
|
|
93
|
+
return {
|
|
94
|
+
//注意如果使用localdata数据格式,默认值的类型应该是数组
|
|
95
|
+
chartsDatalocaldataA:[],
|
|
96
|
+
chartsDatalocaldataB:[],
|
|
97
|
+
//注意如果使用localdata数据格式,默认值的类型应该是数组
|
|
98
|
+
chartsDataColumn1:{},
|
|
99
|
+
chartsDataLine1:{},
|
|
100
|
+
errorMessage:"自定义的错误信息,关闭点击重新加载",
|
|
101
|
+
//在opts中拼接tooltip
|
|
102
|
+
optsTooltip:{}
|
|
103
|
+
};
|
|
104
|
+
},
|
|
105
|
+
onLoad() {
|
|
106
|
+
//模拟从服务器获取数据
|
|
107
|
+
this.getServerData()
|
|
108
|
+
},
|
|
109
|
+
methods: {
|
|
110
|
+
getServerData() {
|
|
111
|
+
setTimeout(() => {
|
|
112
|
+
//因部分数据格式一样,这里不同图表引用同一数据源的话,需要深拷贝一下构造不同的对象
|
|
113
|
+
//开发者需要自行处理服务器返回的数据,应与标准数据格式一致,注意series的data数值应为数字格式
|
|
114
|
+
this.chartsDatalocaldataA=JSON.parse(JSON.stringify(demodata.localdata))
|
|
115
|
+
this.chartsDatalocaldataB=JSON.parse(JSON.stringify(demodata.localdataB))
|
|
116
|
+
this.chartsDataColumn1=JSON.parse(JSON.stringify(demodata.Column))
|
|
117
|
+
this.chartsDataLine1=JSON.parse(JSON.stringify(demodata.Line))
|
|
118
|
+
}, 1500);
|
|
119
|
+
},
|
|
120
|
+
complete(e) {
|
|
121
|
+
console.log("渲染完成事件",e);
|
|
122
|
+
//uCharts.instance[e.id]代表当前的图表实例(除APP端,APP不可在组件外调用uCharts的实例)
|
|
123
|
+
console.log("uCharts实例",uCharts.instance[e.id]);
|
|
124
|
+
//uCharts.option[e.id]代表当前的图表的opts(除APP端,APP不可在组件外调用uCharts的实例)
|
|
125
|
+
console.log("uCharts的option",uCharts.option[e.id]);
|
|
126
|
+
//下面展示渲染完成后,通过实例调用uCharts的showToolTip方法,有了uCharts实例,您也可以在其他地方调用图表的方法及数据(除APP端,APP因采用renderjs,无法获取uCharts实例)
|
|
127
|
+
// #ifndef APP-PLUS
|
|
128
|
+
//如果需要tooltip换行显示,也可以参照本示例,关闭组件本身的tooltip功能,即:tooltipShow="false",然后在@getIndex事件中,通过uCharts.instance[e.id].showToolTip()方法来自定义。
|
|
129
|
+
let textList = [
|
|
130
|
+
{ text: '默认显示的tooltip', color: null },
|
|
131
|
+
{ text: '类别1:某个值xxx', color: '#2fc25b' },
|
|
132
|
+
{ text: '类别2:某个值xxx', color: '#facc14' },
|
|
133
|
+
{ text: '类别3:某个值xxx', color: '#f04864' }
|
|
134
|
+
];
|
|
135
|
+
//这里指定了changedTouches的x和y坐标,当指定index索引时,x值会被自动修正到正确位置,给0即可,主要是y的坐标值
|
|
136
|
+
uCharts.instance[e.id].showToolTip(
|
|
137
|
+
{ changedTouches: [{ x: 0, y: 100 }] },
|
|
138
|
+
{
|
|
139
|
+
index: 3,
|
|
140
|
+
textList: textList
|
|
141
|
+
}
|
|
142
|
+
);
|
|
143
|
+
// #endif
|
|
144
|
+
},
|
|
145
|
+
getIndex(e){
|
|
146
|
+
console.log("获取点击索引事件",e);
|
|
147
|
+
},
|
|
148
|
+
//APP端因为拿不到uCharts的实例,只能通过opts传参的方法来实现tooltip
|
|
149
|
+
showOptsTooltip(e){
|
|
150
|
+
console.log("获取点击索引事件",e);
|
|
151
|
+
//先拿到点击索引,您可以根据索引拼接一下textList
|
|
152
|
+
let currentIndex = e.currentIndex.index;
|
|
153
|
+
if(currentIndex > -1){
|
|
154
|
+
let textList = [
|
|
155
|
+
{text:"我是一个自定义标题"+this.chartsDataColumn1.categories[currentIndex],color:null},
|
|
156
|
+
{ text: '类别1:'+this.chartsDataColumn1.series[0].data[currentIndex], color: '#2fc25b' },
|
|
157
|
+
{ text: '类别2:'+this.chartsDataColumn1.series[1].data[currentIndex], color: '#facc14' },
|
|
158
|
+
];
|
|
159
|
+
this.optsTooltip={
|
|
160
|
+
tooltip:{
|
|
161
|
+
index:currentIndex,
|
|
162
|
+
offset:{
|
|
163
|
+
x:e.opts.chartData.xAxisPoints[currentIndex]+e.opts.chartData.xAxisData.eachSpacing/2,//这里的x坐标为了与x轴categories中的点位对齐,我调用的opts中的参数
|
|
164
|
+
y:e.event.y,//y坐标,用的是点击的点位的y值
|
|
165
|
+
},
|
|
166
|
+
textList:textList
|
|
167
|
+
},
|
|
168
|
+
update:true
|
|
169
|
+
}
|
|
170
|
+
}
|
|
171
|
+
},
|
|
172
|
+
//非APP端可以通过uCharts实例来调用uCharts方法来实现自定义tooltip
|
|
173
|
+
showMyTooltip(e){
|
|
174
|
+
console.log("获取点击索引事件",e);
|
|
175
|
+
//拿到canvasId后即e.id,可以通过uCharts.instance[e.id]代表当前的图表实例(除APP端,APP不可在组件外调用uCharts的实例)
|
|
176
|
+
console.log("获取uCharts实例",uCharts.instance[e.id]);
|
|
177
|
+
//uCharts.option[e.id]代表当前的图表的opts(除APP端,APP不可在组件外调用uCharts的实例)
|
|
178
|
+
console.log("uCharts的option",uCharts.option[e.id]);
|
|
179
|
+
//从option(opts)中获取数据
|
|
180
|
+
let categories = uCharts.option[e.id].categories;
|
|
181
|
+
let series = uCharts.option[e.id].series;
|
|
182
|
+
//e.currentIndex是点击的的点位索引值
|
|
183
|
+
let index = e.currentIndex.index;//注意v2.1.2版本后,e.currentIndex是对象,而e.currentIndex.index是索引值,如果是时间轴图表,index在多个series的情况下会是数组
|
|
184
|
+
//自行通过uCharts的实例调用showToolTip方法(APP端不能实现,无法通过renderjs获取到uCharts实例)
|
|
185
|
+
// #ifndef APP-PLUS
|
|
186
|
+
//如果需要tooltip换行显示,也可以参照本示例,关闭组件本身的tooltip功能,即:tooltipShow="false",然后在@getIndex事件中,通过uCharts.instance[e.id].showToolTip()方法来自定义。
|
|
187
|
+
let textList = [{ text: categories[index] + "年收入情况", color: null }];
|
|
188
|
+
for (let i = 0; i < series.length; i++) {
|
|
189
|
+
textList.push({text: "自定义" + series[i].name + ":" + series[i].data[index] + "美元", color: series[i].color})
|
|
190
|
+
}
|
|
191
|
+
//changedTouches是点击的坐标值
|
|
192
|
+
uCharts.instance[e.id].showToolTip(
|
|
193
|
+
{ changedTouches: [e.event] },
|
|
194
|
+
{
|
|
195
|
+
index: index,
|
|
196
|
+
textList: textList
|
|
197
|
+
}
|
|
198
|
+
);
|
|
199
|
+
// #endif
|
|
200
|
+
|
|
201
|
+
},
|
|
202
|
+
getTouchMove(e){
|
|
203
|
+
console.log("获取TouchMove",e);
|
|
204
|
+
},
|
|
205
|
+
changeErrorMessage(){
|
|
206
|
+
this.errorMessage="自定义错误信息,关闭点击重新加载"+Math.floor(Math.random() * 1000)
|
|
207
|
+
},
|
|
208
|
+
createImage(refid){
|
|
209
|
+
this.$refs[refid].getImage();
|
|
210
|
+
},
|
|
211
|
+
getImage(e){
|
|
212
|
+
console.log(e);
|
|
213
|
+
},
|
|
214
|
+
error(e){
|
|
215
|
+
console.log("组件传递过来的错误信息",e);
|
|
216
|
+
//TODO something 重新加载或者其他你想干的事
|
|
217
|
+
}
|
|
218
|
+
}
|
|
219
|
+
};
|
|
220
|
+
</script>
|
|
221
|
+
|
|
222
|
+
<style>
|
|
223
|
+
.content {
|
|
224
|
+
display: flex;
|
|
225
|
+
flex-direction: column;
|
|
226
|
+
flex: 1;
|
|
227
|
+
}
|
|
228
|
+
|
|
229
|
+
.charts-box {
|
|
230
|
+
width: 100%;
|
|
231
|
+
height: 300px;
|
|
232
|
+
}
|
|
233
|
+
</style>
|
|
@@ -0,0 +1,115 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<view class="content">
|
|
3
|
+
<view class="uni-tabs__header">
|
|
4
|
+
<view class="uni-tabs__nav-wrap">
|
|
5
|
+
<view class="uni-tabs__nav-scroll">
|
|
6
|
+
<scroll-view class="uni-tabs__nav" :scroll-x="true">
|
|
7
|
+
<block v-for="(item, index) in menus" :key="index">
|
|
8
|
+
<view @click="switchTab(item.value)" :class="{'is-active':currentTab===item.value}" class="uni-tabs__item">{{item.text}}</view>
|
|
9
|
+
</block>
|
|
10
|
+
</scroll-view>
|
|
11
|
+
</view>
|
|
12
|
+
</view>
|
|
13
|
+
</view>
|
|
14
|
+
<view v-show="currentTab==='ucharts1'">
|
|
15
|
+
<!-- 如果tab切换的父容器使用了v-show来控制显示,组件上需绑定reshow属性用于强制重新渲染图表。如组件父元素没有v-show,则不必传此参数。-->
|
|
16
|
+
<qiun-title-bar title="基本柱状图"/>
|
|
17
|
+
<view class="charts-box">
|
|
18
|
+
<!-- 这里因为是页面初始化默认显示的,如果不给reshow也会显示,切换回来也不会变成白板,但切换到其他tab后,改变了窗口尺寸再切换回来后,没有reshow则不会根据改变后的窗口自动适应(除非在当前tab显示的情况下再变更窗口大小才会自适应),所以建议加上reshow属性 -->
|
|
19
|
+
<qiun-data-charts type="column" :chartData="chartsDataColumn1" />
|
|
20
|
+
</view>
|
|
21
|
+
<qiun-title-bar title="堆叠柱状图"/>
|
|
22
|
+
<view class="charts-box">
|
|
23
|
+
<!-- 这个图加了reshow属性,上图没加,可以对比一下差异 -->
|
|
24
|
+
<qiun-data-charts type="column" :opts="{extra:{column:{type:'stack'}}}" :chartData="chartsDataColumn2" :reshow="currentTab==='ucharts1'"/>
|
|
25
|
+
</view>
|
|
26
|
+
|
|
27
|
+
</view>
|
|
28
|
+
<view v-if="currentTab==='ucharts2'">
|
|
29
|
+
<!-- 第二个选项卡页面,用v-if控制则不需要加reshow,父元素使用v-if后,会导致组件重新加载,造成资源浪费 -->
|
|
30
|
+
<qiun-title-bar title="基本饼状图"/>
|
|
31
|
+
<view class="charts-box">
|
|
32
|
+
<qiun-data-charts type="pie" :chartData="chartsDataPie1"/>
|
|
33
|
+
</view>
|
|
34
|
+
<qiun-title-bar title="环形图"/>
|
|
35
|
+
<view class="charts-box">
|
|
36
|
+
<qiun-data-charts type="ring" :opts="{extra:{ring:{ringWidth: 60,linearType:'custom'}}}" :chartData="chartsDataRing1"/>
|
|
37
|
+
</view>
|
|
38
|
+
</view>
|
|
39
|
+
<view v-show="currentTab==='echarts1'">
|
|
40
|
+
<qiun-title-bar title="基本折线图"/>
|
|
41
|
+
<view class="charts-box">
|
|
42
|
+
<qiun-data-charts type="line" :chartData="chartsDataLine1" :echartsH5="true" :echartsApp="true" :reshow="currentTab==='echarts1'"/>
|
|
43
|
+
</view>
|
|
44
|
+
<qiun-title-bar title="基本柱状图" />
|
|
45
|
+
<view class="charts-box">
|
|
46
|
+
<qiun-data-charts type="column" :chartData="chartsDataColumn1" :echartsH5="true" :echartsApp="true" :reshow="currentTab==='echarts1'"/>
|
|
47
|
+
</view>
|
|
48
|
+
</view>
|
|
49
|
+
<!-- ECharts如果父元素用了v-if,因renderjs与逻辑层通信不同步,可能会导致初始化时监听不到prop变化,不能成功初始化,虽然组件内使用延时200ms的方法返回逻辑层强制重新读取数据,但这不是正确的解决问题的办法,并且父元素使用了 v-if 会导致组件重新加载,造成资源浪费,强烈建议将v-if改成v-show!!! -->
|
|
50
|
+
<view v-if="currentTab==='echarts2'">
|
|
51
|
+
<qiun-title-bar title="基本柱状图"/>
|
|
52
|
+
<view class="charts-box">
|
|
53
|
+
<qiun-data-charts type="column" :chartData="chartsDataColumn1" :echartsH5="true" :echartsApp="true" :reshow="currentTab==='echarts2'"/>
|
|
54
|
+
</view>
|
|
55
|
+
<qiun-title-bar title="基本折线图" />
|
|
56
|
+
<view class="charts-box">
|
|
57
|
+
<qiun-data-charts type="line" :chartData="chartsDataLine1" :echartsH5="true" :echartsApp="true" :reshow="currentTab==='echarts2'"/>
|
|
58
|
+
</view>
|
|
59
|
+
</view>
|
|
60
|
+
</view>
|
|
61
|
+
</template>
|
|
62
|
+
|
|
63
|
+
<script>
|
|
64
|
+
//下面是演示数据,您的项目不需要引用,数据需要您从服务器自行获取
|
|
65
|
+
import demodata from '@/mockdata/demodata.json';
|
|
66
|
+
|
|
67
|
+
export default {
|
|
68
|
+
data() {
|
|
69
|
+
return {
|
|
70
|
+
chartsDataColumn1:{},
|
|
71
|
+
chartsDataColumn2:{},
|
|
72
|
+
chartsDataPie1:{},
|
|
73
|
+
chartsDataRing1:{},
|
|
74
|
+
chartsDataLine1:{},
|
|
75
|
+
chartsDataLine2:{},
|
|
76
|
+
menus:[{text:"uCharts图1",value:"ucharts1"},{text:"uCharts图2",value:"ucharts2"},{text:"ECharts图1",value:"echarts1"},{text:"ECharts图2",value:"echarts2"}],
|
|
77
|
+
currentTab: 'ucharts1',
|
|
78
|
+
};
|
|
79
|
+
},
|
|
80
|
+
onLoad() {
|
|
81
|
+
//模拟从服务器获取数据
|
|
82
|
+
this.getServerData()
|
|
83
|
+
},
|
|
84
|
+
methods: {
|
|
85
|
+
getServerData() {
|
|
86
|
+
setTimeout(() => {
|
|
87
|
+
//因部分数据格式一样,这里不同图表引用同一数据源的话,需要深拷贝一下构造不同的对象
|
|
88
|
+
//开发者需要自行处理服务器返回的数据,应与标准数据格式一致,注意series的data数值应为数字格式
|
|
89
|
+
this.chartsDataColumn1=JSON.parse(JSON.stringify(demodata.Column))
|
|
90
|
+
this.chartsDataColumn2=JSON.parse(JSON.stringify(demodata.Column))
|
|
91
|
+
this.chartsDataPie1=JSON.parse(JSON.stringify(demodata.PieA))
|
|
92
|
+
this.chartsDataRing1=JSON.parse(JSON.stringify(demodata.PieA))
|
|
93
|
+
this.chartsDataLine1=JSON.parse(JSON.stringify(demodata.Line))
|
|
94
|
+
this.chartsDataLine2=JSON.parse(JSON.stringify(demodata.Line))
|
|
95
|
+
}, 1500);
|
|
96
|
+
},
|
|
97
|
+
switchTab(tab) {
|
|
98
|
+
this.currentTab = tab
|
|
99
|
+
},
|
|
100
|
+
}
|
|
101
|
+
};
|
|
102
|
+
</script>
|
|
103
|
+
|
|
104
|
+
<style>
|
|
105
|
+
.content {
|
|
106
|
+
display: flex;
|
|
107
|
+
flex-direction: column;
|
|
108
|
+
flex: 1;
|
|
109
|
+
}
|
|
110
|
+
|
|
111
|
+
.charts-box {
|
|
112
|
+
width: 100%;
|
|
113
|
+
height: 300px;
|
|
114
|
+
}
|
|
115
|
+
</style>
|