From 7162f16f7a4d55be767d9c007cfb370e8d7709aa Mon Sep 17 00:00:00 2001 From: Stratoula Kalafateli Date: Mon, 4 Oct 2021 08:53:40 +0300 Subject: [PATCH] [Vislib] Removes fontAwesome usage (#113516) * [Vislib] Removes fontAwesome usage * Fix CI * Fix types * Update src/plugins/vis_types/vislib/public/vislib/components/tooltip/_tooltip.scss Co-authored-by: Caroline Horn <549577+cchaos@users.noreply.github.com> Co-authored-by: Caroline Horn <549577+cchaos@users.noreply.github.com> Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com> --- src/plugins/vis_types/vislib/kibana.json | 2 +- .../editor/components/gauge/labels_panel.tsx | 14 ---- src/plugins/vis_types/vislib/public/plugin.ts | 2 - .../vislib/public/vis_controller.tsx | 3 - .../vislib/components/tooltip/_tooltip.scss | 3 +- .../vislib/public/vislib/lib/_alerts.scss | 55 ------------- .../vislib/public/vislib/lib/_index.scss | 1 - .../vislib/public/vislib/lib/alerts.js | 79 ------------------- .../vislib/public/vislib/lib/binder.ts | 6 +- .../vislib/public/vislib/lib/handler.js | 5 +- .../public/vislib/lib/layout/_layout.scss | 4 - .../vislib/lib/layout/types/column_layout.js | 4 - .../vislib/lib/layout/types/gauge_layout.js | 4 - .../vislib/public/vislib/lib/vis_config.js | 1 - .../vislib/partials/touchdown_template.tsx | 3 +- .../vislib/visualizations/gauges/meter.js | 13 --- .../point_series/heatmap_chart.js | 7 -- src/plugins/vis_types/vislib/tsconfig.json | 1 - .../translations/translations/ja-JP.json | 2 - .../translations/translations/zh-CN.json | 2 - 20 files changed, 8 insertions(+), 203 deletions(-) delete mode 100644 src/plugins/vis_types/vislib/public/vislib/lib/_alerts.scss delete mode 100644 src/plugins/vis_types/vislib/public/vislib/lib/alerts.js diff --git a/src/plugins/vis_types/vislib/kibana.json b/src/plugins/vis_types/vislib/kibana.json index 39cc9bb53c01c..dfefa11cb06e5 100644 --- a/src/plugins/vis_types/vislib/kibana.json +++ b/src/plugins/vis_types/vislib/kibana.json @@ -3,7 +3,7 @@ "version": "kibana", "server": true, "ui": true, - "requiredPlugins": ["charts", "data", "expressions", "visualizations", "kibanaLegacy"], + "requiredPlugins": ["charts", "data", "expressions", "visualizations"], "requiredBundles": ["kibanaUtils", "visDefaultEditor", "visTypeXy", "visTypePie", "fieldFormats"], "owner": { "name": "Vis Editors", diff --git a/src/plugins/vis_types/vislib/public/editor/components/gauge/labels_panel.tsx b/src/plugins/vis_types/vislib/public/editor/components/gauge/labels_panel.tsx index ae200892cec57..4650a37d2f986 100644 --- a/src/plugins/vis_types/vislib/public/editor/components/gauge/labels_panel.tsx +++ b/src/plugins/vis_types/vislib/public/editor/components/gauge/labels_panel.tsx @@ -49,20 +49,6 @@ function LabelsPanel({ stateParams, setValue, setGaugeValue }: GaugeOptionsInter setGaugeValue('style', { ...stateParams.gauge.style, [paramName]: value }) } /> - - ); } diff --git a/src/plugins/vis_types/vislib/public/plugin.ts b/src/plugins/vis_types/vislib/public/plugin.ts index 7e9095ce41990..07e9b72aa429f 100644 --- a/src/plugins/vis_types/vislib/public/plugin.ts +++ b/src/plugins/vis_types/vislib/public/plugin.ts @@ -12,7 +12,6 @@ import { Plugin as ExpressionsPublicPlugin } from '../../../expressions/public'; import { VisualizationsSetup } from '../../../visualizations/public'; import { ChartsPluginSetup } from '../../../charts/public'; import { DataPublicPluginStart } from '../../../data/public'; -import { KibanaLegacyStart } from '../../../kibana_legacy/public'; import { LEGACY_PIE_CHARTS_LIBRARY } from '../../pie/common/index'; import { createVisTypeVislibVisFn } from './vis_type_vislib_vis_fn'; @@ -31,7 +30,6 @@ export interface VisTypeVislibPluginSetupDependencies { /** @internal */ export interface VisTypeVislibPluginStartDependencies { data: DataPublicPluginStart; - kibanaLegacy: KibanaLegacyStart; } export type VisTypeVislibCoreSetup = CoreSetup; diff --git a/src/plugins/vis_types/vislib/public/vis_controller.tsx b/src/plugins/vis_types/vislib/public/vis_controller.tsx index 7bae32d031b46..1e940d23e83da 100644 --- a/src/plugins/vis_types/vislib/public/vis_controller.tsx +++ b/src/plugins/vis_types/vislib/public/vis_controller.tsx @@ -79,9 +79,6 @@ export const createVislibVisController = ( return; } - const [, { kibanaLegacy }] = await core.getStartServices(); - kibanaLegacy.loadFontAwesome(); - // @ts-expect-error const { Vis: Vislib } = await import('./vislib/vis'); const { uiState, event: fireEvent } = handlers; diff --git a/src/plugins/vis_types/vislib/public/vislib/components/tooltip/_tooltip.scss b/src/plugins/vis_types/vislib/public/vislib/components/tooltip/_tooltip.scss index bafec7edf3b94..6448ceca38c23 100644 --- a/src/plugins/vis_types/vislib/public/vislib/components/tooltip/_tooltip.scss +++ b/src/plugins/vis_types/vislib/public/vislib/components/tooltip/_tooltip.scss @@ -49,8 +49,7 @@ } .visTooltip__headerIcon { - flex: 0 0 auto; - padding-right: $euiSizeS; + margin-right: $euiSizeXS; } .visTooltip__headerText { diff --git a/src/plugins/vis_types/vislib/public/vislib/lib/_alerts.scss b/src/plugins/vis_types/vislib/public/vislib/lib/_alerts.scss deleted file mode 100644 index 596f4675b1254..0000000000000 --- a/src/plugins/vis_types/vislib/public/vislib/lib/_alerts.scss +++ /dev/null @@ -1,55 +0,0 @@ - -.visAlerts__tray { - position: absolute; - bottom: ($euiSizeXS + 1px); - left: 0; - right: 0; - list-style: none; - padding: 0; - - transition-property: opacity; - transition-delay: $euiAnimSpeedExtraFast; - transition-duration: $euiAnimSpeedExtraFast; -} - -.visAlerts__icon { - margin: 0; - padding: 0 $euiSizeS; - flex: 0 0 auto; - align-self: center; -} - -.visAlerts__text { - flex: 1 1 auto; - margin: 0; - padding: 0; -} - -.visAlerts__close { - cursor: pointer; -} - -.visAlert { - margin: 0 $euiSizeS $euiSizeS; - padding: $euiSizeXS $euiSizeS $euiSizeXS $euiSizeXS; - display: flex; -} - -// Modifier naming and colors. -$visAlertTypes: ( - info: $euiColorPrimary, - success: $euiColorSecondary, - warning: $euiColorWarning, - danger: $euiColorDanger, -); - -// Create button modifiders based upon the map. -@each $name, $color in $visAlertTypes { - .visAlert--#{$name} { - $backgroundColor: tintOrShade($color, 90%, 70%); - $textColor: makeHighContrastColor($color, $backgroundColor); - - background-color: $backgroundColor; - color: $textColor; - } -} diff --git a/src/plugins/vis_types/vislib/public/vislib/lib/_index.scss b/src/plugins/vis_types/vislib/public/vislib/lib/_index.scss index 6ab284fd8d122..5217bc7300bf5 100644 --- a/src/plugins/vis_types/vislib/public/vislib/lib/_index.scss +++ b/src/plugins/vis_types/vislib/public/vislib/lib/_index.scss @@ -1,2 +1 @@ -@import './alerts'; @import './layout/index'; diff --git a/src/plugins/vis_types/vislib/public/vislib/lib/alerts.js b/src/plugins/vis_types/vislib/public/vislib/lib/alerts.js deleted file mode 100644 index 6d4299c125edf..0000000000000 --- a/src/plugins/vis_types/vislib/public/vislib/lib/alerts.js +++ /dev/null @@ -1,79 +0,0 @@ -/* - * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one - * or more contributor license agreements. Licensed under the Elastic License - * 2.0 and the Server Side Public License, v 1; you may not use this file except - * in compliance with, at your election, the Elastic License 2.0 or the Server - * Side Public License, v 1. - */ - -import $ from 'jquery'; -import _ from 'lodash'; - -/** - * Adds alerts that float in front of a visualization - * - * @class Alerts - * @constructor - * @param el {HTMLElement} Reference to DOM element - */ -export class Alerts { - constructor(vis, alertDefs) { - this.vis = vis; - this.data = vis.data; - this.alertDefs = _.cloneDeep(alertDefs); - - this.alerts = _(alertDefs) - .map((alertDef) => { - if (!alertDef) return; - if (alertDef.test && !alertDef.test(vis, this.data)) return; - return this._addAlert(alertDef); - }) - .compact(); - } - - _addAlert(alertDef) { - const type = alertDef.type || 'info'; - const icon = alertDef.icon || type; - const msg = alertDef.msg; - // alert container - const $icon = $('').addClass('visAlerts__icon fa fa-' + icon); - const $text = $('

').addClass('visAlerts__text').text(msg); - const $closeIcon = $('').addClass('fa fa-close'); - const $closeDiv = $('

').addClass('visAlerts__close').append($closeIcon); - - const $alert = $('
') - .addClass('visAlert visAlert--' + type) - .append([$icon, $text, $closeDiv]); - $closeDiv.on('click', () => { - $alert.remove(); - }); - - return $alert; - } - - // renders initial alerts - render() { - const alerts = this.alerts; - const vis = this.vis; - - $(vis.element).find('.visWrapper__alerts').append($('
').addClass('visAlerts__tray')); - if (!alerts.size()) return; - $(vis.element).find('.visAlerts__tray').append(alerts.value()); - } - - // shows new alert - show(msg, type) { - const vis = this.vis; - const alert = { - msg: msg, - type: type, - }; - if (this.alertDefs.find((alertDef) => alertDef.msg === alert.msg)) return; - this.alertDefs.push(alert); - $(vis.element).find('.visAlerts__tray').append(this._addAlert(alert)); - } - - destroy() { - $(this.vis.element).find('.visWrapper__alerts').remove(); - } -} diff --git a/src/plugins/vis_types/vislib/public/vislib/lib/binder.ts b/src/plugins/vis_types/vislib/public/vislib/lib/binder.ts index 886745ba19563..31e49697d4bd9 100644 --- a/src/plugins/vis_types/vislib/public/vislib/lib/binder.ts +++ b/src/plugins/vis_types/vislib/public/vislib/lib/binder.ts @@ -33,14 +33,14 @@ export class Binder { destroyers.forEach((fn) => fn()); } - jqOn(el: HTMLElement, ...args: [string, (event: JQueryEventObject) => void]) { + jqOn(el: HTMLElement, ...args: [string, (event: JQuery.Event) => void]) { const $el = $(el); $el.on(...args); this.disposal.push(() => $el.off(...args)); } - fakeD3Bind(el: HTMLElement, event: string, handler: (event: JQueryEventObject) => void) { - this.jqOn(el, event, (e: JQueryEventObject) => { + fakeD3Bind(el: HTMLElement, event: string, handler: (event: JQuery.Event) => void) { + this.jqOn(el, event, (e: JQuery.Event) => { // mimic https://github.com/mbostock/d3/blob/3abb00113662463e5c19eb87cd33f6d0ddc23bc0/src/selection/on.js#L87-L94 const o = d3.event; // Events can be reentrant (e.g., focus). d3.event = e; diff --git a/src/plugins/vis_types/vislib/public/vislib/lib/handler.js b/src/plugins/vis_types/vislib/public/vislib/lib/handler.js index a2b747f4d5d9c..7a68b128faf09 100644 --- a/src/plugins/vis_types/vislib/public/vislib/lib/handler.js +++ b/src/plugins/vis_types/vislib/public/vislib/lib/handler.js @@ -17,7 +17,6 @@ import { visTypes as chartTypes } from '../visualizations/vis_types'; import { NoResults } from '../errors'; import { Layout } from './layout/layout'; import { ChartTitle } from './chart_title'; -import { Alerts } from './alerts'; import { Axis } from './axis/axis'; import { ChartGrid as Grid } from './chart_grid'; import { Binder } from './binder'; @@ -46,7 +45,6 @@ export class Handler { this.ChartClass = chartTypes[visConfig.get('type')]; this.uiSettings = uiSettings; this.charts = []; - this.vis = vis; this.visConfig = visConfig; this.data = visConfig.data; @@ -56,7 +54,6 @@ export class Handler { .map((axisArgs) => new Axis(visConfig, axisArgs)); this.valueAxes = visConfig.get('valueAxes').map((axisArgs) => new Axis(visConfig, axisArgs)); this.chartTitle = new ChartTitle(visConfig); - this.alerts = new Alerts(this, visConfig.get('alerts')); this.grid = new Grid(this, visConfig.get('grid')); if (visConfig.get('type') === 'point_series') { @@ -69,7 +66,7 @@ export class Handler { this.layout = new Layout(visConfig); this.binder = new Binder(); - this.renderArray = _.filter([this.layout, this.chartTitle, this.alerts], Boolean); + this.renderArray = _.filter([this.layout, this.chartTitle], Boolean); this.renderArray = this.renderArray .concat(this.valueAxes) diff --git a/src/plugins/vis_types/vislib/public/vislib/lib/layout/_layout.scss b/src/plugins/vis_types/vislib/public/vislib/lib/layout/_layout.scss index 7ead0b314c7ad..4612602d93f1c 100644 --- a/src/plugins/vis_types/vislib/public/vislib/lib/layout/_layout.scss +++ b/src/plugins/vis_types/vislib/public/vislib/lib/layout/_layout.scss @@ -271,10 +271,6 @@ min-width: 0; } -.visWrapper__alerts { - position: relative; -} - // General Axes .visAxis__column--top .axis-div svg { diff --git a/src/plugins/vis_types/vislib/public/vislib/lib/layout/types/column_layout.js b/src/plugins/vis_types/vislib/public/vislib/lib/layout/types/column_layout.js index e8cc0f15e89e2..02910394035f8 100644 --- a/src/plugins/vis_types/vislib/public/vislib/lib/layout/types/column_layout.js +++ b/src/plugins/vis_types/vislib/public/vislib/lib/layout/types/column_layout.js @@ -90,10 +90,6 @@ export function columnLayout(el, data) { class: 'visWrapper__chart', splits: chartSplit, }, - { - type: 'div', - class: 'visWrapper__alerts', - }, { type: 'div', class: 'visAxis--x visAxis__column--bottom', diff --git a/src/plugins/vis_types/vislib/public/vislib/lib/layout/types/gauge_layout.js b/src/plugins/vis_types/vislib/public/vislib/lib/layout/types/gauge_layout.js index 6b38f126232c7..e3b808b63c8c1 100644 --- a/src/plugins/vis_types/vislib/public/vislib/lib/layout/types/gauge_layout.js +++ b/src/plugins/vis_types/vislib/public/vislib/lib/layout/types/gauge_layout.js @@ -51,10 +51,6 @@ export function gaugeLayout(el, data) { class: 'visWrapper__chart', splits: chartSplit, }, - { - type: 'div', - class: 'visWrapper__alerts', - }, { type: 'div', class: 'visAxis__splitTitles--x', diff --git a/src/plugins/vis_types/vislib/public/vislib/lib/vis_config.js b/src/plugins/vis_types/vislib/public/vislib/lib/vis_config.js index 30dc2d82d4890..cc9e48897d053 100644 --- a/src/plugins/vis_types/vislib/public/vislib/lib/vis_config.js +++ b/src/plugins/vis_types/vislib/public/vislib/lib/vis_config.js @@ -18,7 +18,6 @@ const DEFAULT_VIS_CONFIG = { style: { margin: { top: 10, right: 3, bottom: 5, left: 3 }, }, - alerts: [], categoryAxes: [], valueAxes: [], grid: {}, diff --git a/src/plugins/vis_types/vislib/public/vislib/partials/touchdown_template.tsx b/src/plugins/vis_types/vislib/public/vislib/partials/touchdown_template.tsx index 55955da07ebdd..731fbed7482c4 100644 --- a/src/plugins/vis_types/vislib/public/vislib/partials/touchdown_template.tsx +++ b/src/plugins/vis_types/vislib/public/vislib/partials/touchdown_template.tsx @@ -8,6 +8,7 @@ import React from 'react'; import ReactDOM from 'react-dom/server'; +import { EuiIcon } from '@elastic/eui'; interface Props { wholeBucket: boolean; @@ -16,7 +17,7 @@ interface Props { export const touchdownTemplate = ({ wholeBucket }: Props) => { return ReactDOM.renderToStaticMarkup(

- + {wholeBucket ? 'Part of this bucket' : 'This area'} may contain partial data. The selected time range does not fully cover it. diff --git a/src/plugins/vis_types/vislib/public/vislib/visualizations/gauges/meter.js b/src/plugins/vis_types/vislib/public/vislib/visualizations/gauges/meter.js index ad278847b0780..4073aeeed434b 100644 --- a/src/plugins/vis_types/vislib/public/vislib/visualizations/gauges/meter.js +++ b/src/plugins/vis_types/vislib/public/vislib/visualizations/gauges/meter.js @@ -175,7 +175,6 @@ export class MeterGauge { const marginFactor = 0.95; const tooltip = this.gaugeChart.tooltip; const isTooltip = this.gaugeChart.handler.visConfig.get('addTooltip'); - const isDisplayWarning = this.gaugeChart.handler.visConfig.get('isDisplayWarning', false); const { angleFactor, maxAngle, minAngle } = this.gaugeConfig.gaugeType === 'Circle' ? circleAngles : arcAngles; const maxRadius = (Math.min(width, height / angleFactor) / 2) * marginFactor; @@ -261,7 +260,6 @@ export class MeterGauge { .style('fill', (d) => this.getColorBucket(Math.max(min, d.y))); const smallContainer = svg.node().getBBox().height < 70; - let hiddenLabels = smallContainer; // If the value label is hidden we later want to hide also all other labels // since they don't make sense as long as the actual value is hidden. @@ -286,7 +284,6 @@ export class MeterGauge { // The text is too long if it's larger than the inner free space minus a couple of random pixels for padding. const textTooLong = textLength >= getInnerFreeSpace() - 6; if (textTooLong) { - hiddenLabels = true; valueLabelHidden = true; } return textTooLong ? 'none' : 'initial'; @@ -302,9 +299,6 @@ export class MeterGauge { .style('display', function () { const textLength = this.getBBox().width; const textTooLong = textLength > maxRadius; - if (textTooLong) { - hiddenLabels = true; - } return smallContainer || textTooLong ? 'none' : 'initial'; }); @@ -317,9 +311,6 @@ export class MeterGauge { .style('display', function () { const textLength = this.getBBox().width; const textTooLong = textLength > maxRadius; - if (textTooLong) { - hiddenLabels = true; - } return valueLabelHidden || smallContainer || textTooLong ? 'none' : 'initial'; }); } @@ -335,10 +326,6 @@ export class MeterGauge { }); } - if (hiddenLabels && isDisplayWarning) { - this.gaugeChart.handler.alerts.show('Some labels were hidden due to size constraints'); - } - //center the visualization const transformX = width / 2; const transformY = height / 2 > maxRadius ? height / 2 : maxRadius; diff --git a/src/plugins/vis_types/vislib/public/vislib/visualizations/point_series/heatmap_chart.js b/src/plugins/vis_types/vislib/public/vislib/visualizations/point_series/heatmap_chart.js index bef6c939f864a..ecab91103d614 100644 --- a/src/plugins/vis_types/vislib/public/vislib/visualizations/point_series/heatmap_chart.js +++ b/src/plugins/vis_types/vislib/public/vislib/visualizations/point_series/heatmap_chart.js @@ -248,7 +248,6 @@ export class HeatmapChart extends PointSeries { }; } - let hiddenLabels = false; squares .append('text') .text((d) => zAxisFormatter(d.y)) @@ -257,9 +256,6 @@ export class HeatmapChart extends PointSeries { const textHeight = this.getBBox().height; const textTooLong = textLength > maxLength; const textTooWide = textHeight > maxHeight; - if (!d.hide && (textTooLong || textTooWide)) { - hiddenLabels = true; - } return d.hide || textTooLong || textTooWide ? 'none' : 'initial'; }) .style('dominant-baseline', 'central') @@ -278,9 +274,6 @@ export class HeatmapChart extends PointSeries { const verticalCenter = y(d) + squareHeight / 2; return `rotate(${rotate},${horizontalCenter},${verticalCenter})`; }); - if (hiddenLabels) { - this.baseChart.handler.alerts.show('Some labels were hidden due to size constraints'); - } } if (isTooltip) { diff --git a/src/plugins/vis_types/vislib/tsconfig.json b/src/plugins/vis_types/vislib/tsconfig.json index 8246b3f30646b..db00cd34203e6 100644 --- a/src/plugins/vis_types/vislib/tsconfig.json +++ b/src/plugins/vis_types/vislib/tsconfig.json @@ -17,7 +17,6 @@ { "path": "../../data/tsconfig.json" }, { "path": "../../expressions/tsconfig.json" }, { "path": "../../visualizations/tsconfig.json" }, - { "path": "../../kibana_legacy/tsconfig.json" }, { "path": "../../kibana_utils/tsconfig.json" }, { "path": "../../vis_default_editor/tsconfig.json" }, { "path": "../../vis_types/xy/tsconfig.json" }, diff --git a/x-pack/plugins/translations/translations/ja-JP.json b/x-pack/plugins/translations/translations/ja-JP.json index 34e44d37bc4b8..1b83bcac5837f 100644 --- a/x-pack/plugins/translations/translations/ja-JP.json +++ b/x-pack/plugins/translations/translations/ja-JP.json @@ -5628,7 +5628,6 @@ "visTypeVislib.aggResponse.allDocsTitle": "すべてのドキュメント", "visTypeVislib.controls.gaugeOptions.alignmentLabel": "アラインメント", "visTypeVislib.controls.gaugeOptions.autoExtendRangeLabel": "範囲を自動拡張", - "visTypeVislib.controls.gaugeOptions.displayWarningsLabel": "警告を表示", "visTypeVislib.controls.gaugeOptions.extendRangeTooltip": "範囲をデータの最高値に広げます。", "visTypeVislib.controls.gaugeOptions.gaugeTypeLabel": "ゲージタイプ", "visTypeVislib.controls.gaugeOptions.labelsTitle": "ラベル", @@ -5639,7 +5638,6 @@ "visTypeVislib.controls.gaugeOptions.showScaleLabel": "縮尺を表示", "visTypeVislib.controls.gaugeOptions.styleTitle": "スタイル", "visTypeVislib.controls.gaugeOptions.subTextLabel": "サブラベル", - "visTypeVislib.controls.gaugeOptions.switchWarningsTooltip": "警告のオン/オフを切り替えます。オンにすると、すべてのラベルを表示できない際に警告が表示されます。", "visTypeVislib.controls.heatmapOptions.colorLabel": "色", "visTypeVislib.controls.heatmapOptions.colorScaleLabel": "カラースケール", "visTypeVislib.controls.heatmapOptions.colorsNumberLabel": "色の数", diff --git a/x-pack/plugins/translations/translations/zh-CN.json b/x-pack/plugins/translations/translations/zh-CN.json index 1ec387f8f0f30..c29557eebd3f8 100644 --- a/x-pack/plugins/translations/translations/zh-CN.json +++ b/x-pack/plugins/translations/translations/zh-CN.json @@ -5674,7 +5674,6 @@ "visTypeVislib.aggResponse.allDocsTitle": "所有文档", "visTypeVislib.controls.gaugeOptions.alignmentLabel": "对齐方式", "visTypeVislib.controls.gaugeOptions.autoExtendRangeLabel": "自动扩展范围", - "visTypeVislib.controls.gaugeOptions.displayWarningsLabel": "显示警告", "visTypeVislib.controls.gaugeOptions.extendRangeTooltip": "将数据范围扩展到数据中的最大值。", "visTypeVislib.controls.gaugeOptions.gaugeTypeLabel": "仪表类型", "visTypeVislib.controls.gaugeOptions.labelsTitle": "标签", @@ -5685,7 +5684,6 @@ "visTypeVislib.controls.gaugeOptions.showScaleLabel": "显示比例", "visTypeVislib.controls.gaugeOptions.styleTitle": "样式", "visTypeVislib.controls.gaugeOptions.subTextLabel": "子标签", - "visTypeVislib.controls.gaugeOptions.switchWarningsTooltip": "打开/关闭警告。打开时,如果标签没有全部显示,则显示警告。", "visTypeVislib.controls.heatmapOptions.colorLabel": "颜色", "visTypeVislib.controls.heatmapOptions.colorScaleLabel": "色阶", "visTypeVislib.controls.heatmapOptions.colorsNumberLabel": "颜色个数",