@operato/chart 7.0.37 → 7.0.40
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/CHANGELOG.md +20 -0
- package/dist/src/editors/configurer.d.ts +4 -2
- package/dist/src/editors/configurer.js +27 -14
- package/dist/src/editors/configurer.js.map +1 -1
- package/dist/src/editors/input-chart-abstract.d.ts +0 -26
- package/dist/src/editors/input-chart-abstract.js +1 -607
- package/dist/src/editors/input-chart-abstract.js.map +1 -1
- package/dist/src/editors/input-chart-styles.js +27 -0
- package/dist/src/editors/input-chart-styles.js.map +1 -1
- package/dist/src/editors/ox-input-chart-hbar.d.ts +1 -1
- package/dist/src/editors/ox-input-chart-hbar.js +2 -69
- package/dist/src/editors/ox-input-chart-hbar.js.map +1 -1
- package/dist/src/editors/ox-input-chart-mixed.d.ts +1 -0
- package/dist/src/editors/ox-input-chart-mixed.js +2 -2
- package/dist/src/editors/ox-input-chart-mixed.js.map +1 -1
- package/dist/src/editors/ox-input-chart-pie.d.ts +1 -0
- package/dist/src/editors/ox-input-chart-pie.js +3 -1
- package/dist/src/editors/ox-input-chart-pie.js.map +1 -1
- package/dist/src/editors/ox-input-chart-radar.d.ts +1 -0
- package/dist/src/editors/ox-input-chart-radar.js +2 -2
- package/dist/src/editors/ox-input-chart-radar.js.map +1 -1
- package/dist/src/editors/ox-input-chart-timeseries.d.ts +2 -0
- package/dist/src/editors/ox-input-chart-timeseries.js +9 -3
- package/dist/src/editors/ox-input-chart-timeseries.js.map +1 -1
- package/dist/src/editors/ox-property-editor-chart.js.map +1 -1
- package/dist/src/editors/templates/annotations.d.ts +23 -0
- package/dist/src/editors/templates/annotations.js +270 -0
- package/dist/src/editors/templates/annotations.js.map +1 -0
- package/dist/src/editors/templates/display-value.d.ts +12 -0
- package/dist/src/editors/templates/display-value.js +105 -0
- package/dist/src/editors/templates/display-value.js.map +1 -0
- package/dist/src/editors/templates/series.d.ts +31 -0
- package/dist/src/editors/templates/series.js +277 -0
- package/dist/src/editors/templates/series.js.map +1 -0
- package/dist/src/scichart/ox-scichart.js +4 -3
- package/dist/src/scichart/ox-scichart.js.map +1 -1
- package/dist/src/scichart/scichart-builder.js +25 -7
- package/dist/src/scichart/scichart-builder.js.map +1 -1
- package/dist/stories/common.d.ts +2 -2
- package/dist/stories/common.js +6 -3
- package/dist/stories/common.js.map +1 -1
- package/dist/stories/ox-input-chart-timeseries.stories.js +2 -2
- package/dist/stories/ox-input-chart-timeseries.stories.js.map +1 -1
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/package.json +2 -2
- package/src/editors/configurer.ts +28 -15
- package/src/editors/input-chart-abstract.ts +1 -655
- package/src/editors/input-chart-styles.ts +27 -0
- package/src/editors/ox-input-chart-hbar.ts +3 -73
- package/src/editors/ox-input-chart-mixed.ts +2 -2
- package/src/editors/ox-input-chart-pie.ts +3 -2
- package/src/editors/ox-input-chart-radar.ts +3 -2
- package/src/editors/ox-input-chart-timeseries.ts +10 -3
- package/src/editors/ox-property-editor-chart.ts +1 -1
- package/src/editors/templates/annotations.ts +287 -0
- package/src/editors/templates/display-value.ts +110 -0
- package/src/editors/templates/series.ts +304 -0
- package/src/scichart/ox-scichart.ts +7 -3
- package/src/scichart/scichart-builder.ts +30 -6
- package/stories/common.ts +6 -3
- package/stories/ox-input-chart-timeseries.stories.ts +2 -2
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"input-chart-abstract.js","sourceRoot":"","sources":["../../../src/editors/input-chart-abstract.ts"],"names":[],"mappings":";AAAA,OAAO,0BAA0B,CAAA;AAEjC,OAAO,EAAE,IAAI,EAAkB,MAAM,KAAK,CAAA;AAC1C,OAAO,EAAE,QAAQ,EAAE,KAAK,EAAE,MAAM,mBAAmB,CAAA;AACnD,OAAO,EAAE,KAAK,EAAE,MAAM,yBAAyB,CAAA;AAE/C,OAAO,EAAE,MAAM,IAAI,WAAW,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAA;AAGlE,OAAO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AC;aAAM,CAAC;YACN,YAAY,GAAG,IAAI,CAAC,uBAAuB,CAAA;QAC7C,CAAC;QAED,IAAI,CAAC,YAAY,EAAE,CAAC;YAClB,OAAM;QACR,CAAC;QAED,YAAY,CAAC,KAAK,CAAC,cAAc,GAAG,QAAQ,CAAA;QAC5C,YAAY,CAAC,UAAU,IAAI,YAAY,CAAC,WAAW,CAAA;QACnD,YAAY,CAAC,KAAK,CAAC,cAAc,GAAG,MAAM,CAAA;IAC5C,CAAC;;AAt0B2B;IAA3B,QAAQ,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;iDAA8C;AACpB;IAApD,QAAQ,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,SAAS,EAAE,YAAY,EAAE,CAAC;qDAAkC;AAE1D;IAA3B,KAAK,CAAC,mBAAmB,CAAC;2DAA8B;AACd;IAA1C,KAAK,CAAC,kCAAkC,CAAC;uEAAqC;AACnC;IAA3C,KAAK,CAAC,mCAAmC,CAAC;wEAAsC;AAE1D;IAAtB,KAAK,CAAC,cAAc,CAAC;sDAAyB;AACT;IAArC,KAAK,CAAC,6BAA6B,CAAC;kEAAgC;AAC9B;IAAtC,KAAK,CAAC,8BAA8B,CAAC;mEAAiC","sourcesContent":["import '@operato/i18n/ox-i18n.js'\n\nimport { html, PropertyValues } from 'lit'\nimport { property, query } from 'lit/decorators.js'\nimport { keyed } from 'lit/directives/keyed.js'\n\nimport { random as randomColor, TinyColor } from '@ctrl/tinycolor'\nimport { MdIcon } from '@material/web/icon/icon.js'\n\nimport { InputChartStyles } from './input-chart-styles'\nimport { Configurer } from './configurer'\nimport { OxFormField } from '@operato/input'\n\nexport class InputChartAbstract extends OxFormField {\n static styles = [InputChartStyles]\n\n @property({ type: Object }) value: OperatoChart.ChartConfig | null = null\n @property({ type: String, attribute: 'chart-type' }) chartType: OperatoChart.ChartType\n\n @query('#annotations-tabs') annotationsTabs!: HTMLElement\n @query('#annotations-tab-nav-left-button') annotationsTabNavLeftButton!: MdIcon\n @query('#annotations-tab-nav-right-button') annotationsTabNavRightButton!: MdIcon\n\n @query('#series-tabs') seriesTabs!: HTMLElement\n @query('#series-tab-nav-left-button') seriesTabNavLeftButton!: MdIcon\n @query('#series-tab-nav-right-button') seriesTabNavRightButton!: MdIcon\n\n private _configurer?: Configurer\n\n get configurer() {\n if (!this._configurer) {\n this._configurer = new Configurer(this.value, () => {\n return this.value || this.getDefaultChartConfig(this.chartType, this.getDefaultDatasets())\n })\n }\n return this._configurer\n }\n\n updated(changes: PropertyValues<this>) {\n if (changes.has('value')) {\n this.configurer.updateValue(this.value!)\n }\n }\n\n render() {\n const configurer = this.configurer\n\n return html`\n <legend><ox-i18n msgid=\"label.chart\">Chart</ox-i18n></legend>\n\n <label for=\"theme\"> <ox-i18n msgid=\"label.theme\">Theme</ox-i18n> </label>\n <select id=\"theme\" value-key=\"theme\" class=\"select-content\" .value=${configurer.theme || 'light'}>\n <option value=\"auto\">auto</option>\n <option value=\"dark\">dark</option>\n <option value=\"light\" checked>light</option>\n </select>\n\n <input id=\"tooltip\" type=\"checkbox\" value-key=\"tooltip\" ?checked=${configurer.tooltip} />\n <label for=\"tooltip\"> <ox-i18n msgid=\"label.tooltip\">Tooltip</ox-i18n> </label>\n\n <input id=\"animation\" type=\"checkbox\" value-key=\"animation\" ?checked=${configurer.animation} />\n <label for=\"animation\"> <ox-i18n msgid=\"label.animation\">Animation</ox-i18n> </label>\n\n <input id=\"display\" type=\"checkbox\" value-key=\"display\" ?checked=${configurer.display} />\n <label for=\"display\"> <ox-i18n msgid=\"label.legend\">Legend</ox-i18n> </label>\n\n <input id=\"stacked\" type=\"checkbox\" value-key=\"stacked\" ?checked=${configurer.stacked} />\n <label for=\"stacked\"> <ox-i18n msgid=\"label.stacked\">Stacked</ox-i18n> </label>\n\n ${configurer.display\n ? html`\n <label for=\"position\"> <ox-i18n msgid=\"label.position\">Position</ox-i18n> </label>\n <select id=\"position\" value-key=\"position\" class=\"select-content\" .value=${configurer.position || ''}>\n <option value=\"top\">top</option>\n <option value=\"right\">right</option>\n <option value=\"bottom\">bottom</option>\n <option value=\"left\">left</option>\n </select>\n `\n : html``}\n ${this.subTemplate()}\n `\n }\n\n connectedCallback() {\n super.connectedCallback()\n\n this.renderRoot.addEventListener('change', this.onValuesChanged.bind(this))\n }\n\n protected firstUpdated(_changedProperties: PropertyValues): void {\n this.seriesTabContainer?.addEventListener('scroll', e => {\n this._onTabScroll(e, 'series')\n })\n\n this.annotationsTabContainer?.addEventListener('scroll', e => {\n this._onTabScroll(e, 'annotations')\n })\n }\n\n get seriesTabContainer(): HTMLElement | null | undefined {\n return this.seriesTabs\n }\n\n get annotationsTabContainer(): HTMLElement | null | undefined {\n return this.annotationsTabs\n }\n\n displayValueTemplate() {\n const configurer = this.configurer\n\n return html`\n <label for=\"value-format\"> <ox-i18n msgid=\"label.value-format\">Value Format</ox-i18n> </label>\n <input\n id=\"value-format\"\n type=\"text\"\n value-key=\"series.valueFormat\"\n .value=${configurer.series.valueFormat || ''}\n list=\"format-list\"\n />\n <datalist id=\"format-list\">\n <option value=\"#,###.\"></option>\n <option value=\"#,###.#\"></option>\n <option value=\"#,###.0\"></option>\n <option value=\"#,##0.#\"></option>\n <option value=\"#,##0.0\"></option>\n <option value=\"#,##0.0%\"></option>\n </datalist>\n\n <label for=\"value-prefix\"> <ox-i18n msgid=\"label.value-prefix\">Value Prefix</ox-i18n> </label>\n <input\n id=\"value-prefix\"\n type=\"text\"\n value-key=\"series.valuePrefix\"\n .value=${configurer.series.valuePrefix || ''}\n />\n\n <label for=\"value-suffix\"> <ox-i18n msgid=\"label.value-suffix\">Value Suffix</ox-i18n> </label>\n <input\n id=\"value-suffix\"\n type=\"text\"\n value-key=\"series.valueSuffix\"\n .value=${configurer.series.valueSuffix || ''}\n />\n\n <input\n id=\"display-value\"\n type=\"checkbox\"\n value-key=\"series.displayValue\"\n ?checked=${!!configurer.series.displayValue}\n />\n <label for=\"display-value\"> <ox-i18n msgid=\"label.value-display\">Value Display</ox-i18n> </label>\n\n ${configurer.series.displayValue\n ? html`\n <label for=\"font-color\"> <ox-i18n msgid=\"label.font-color\">Font Color</ox-i18n> </label>\n <ox-input-color\n id=\"font-color\"\n value-key=\"series.defaultFontColor\"\n .value=${configurer.series.defaultFontColor || '#000'}\n ></ox-input-color>\n <label for=\"font-size\"> <ox-i18n msgid=\"label.font-size\">Font Size</ox-i18n> </label>\n <input\n id=\"font-size\"\n type=\"number\"\n value-key=\"series.defaultFontSize\"\n value=${configurer.series.defaultFontSize || 10}\n />\n <label for=\"data-label-anchor\"> <ox-i18n msgid=\"label.data-label-anchor\">Position</ox-i18n> </label>\n <select\n id=\"data-label-anchor\"\n value-key=\"series.dataLabelAnchor\"\n .value=${configurer.series.dataLabelAnchor || 'center'}\n >\n <option value=\"\"></option>\n <option value=\"start\">Start</option>\n <option value=\"center\">Center</option>\n <option value=\"end\">End</option>\n </select>\n <label for=\"data-label-offset\"> <ox-i18n msgid=\"label.data-label-offset\">Offset</ox-i18n> </label>\n <input\n id=\"data-label-offset\"\n type=\"number\"\n value-key=\"series.dataLabelOffset\"\n value=${configurer.series.dataLabelOffset || 0}\n />\n <label for=\"data-label-rotation\"> <ox-i18n msgid=\"label.data-label-rotation\">Rotation</ox-i18n> </label>\n <input\n id=\"data-label-rotation\"\n type=\"number\"\n value-key=\"series.dataLabelRotation\"\n value=${configurer.series.dataLabelRotation || 0}\n />\n `\n : html``}\n `\n }\n\n subTemplate() {\n return html``\n }\n\n getDefaultDatasets(): OperatoChart.Dataset[] {\n return [this.getDefaultDataset('bar')]\n }\n\n getDefaultDataset(seriesType: 'bar' | 'horizontalBar' | 'line' | 'radar' | 'pie'): OperatoChart.Dataset {\n return {\n label: 'Series 1',\n data: [],\n borderWidth: 1,\n dataKey: '',\n yAxisID: 'left',\n color: randomColor({\n hue: new TinyColor('#fff').clone().toString()\n }).toRgbString(),\n backgroundColor: '#FFFFFF',\n type: seriesType,\n stack: '',\n fill: false,\n lineTension: 0.4,\n pointStyle: 'circle',\n pointRadius: 3,\n valuePrefix: '',\n valueSuffix: '',\n displayValue: false\n }\n }\n\n getDefaultChartConfig(type: OperatoChart.ChartType, datasets?: OperatoChart.Dataset[]): OperatoChart.ChartConfig {\n return {\n data: {\n datasets: datasets || [],\n labelDataKey: ''\n },\n options: {\n theme: 'light',\n tooltip: true,\n animation: true,\n legend: {\n display: true,\n position: 'top'\n },\n scales: {\n xAxes: [this.getDefaultAxisOptions()],\n yAxes: [this.getDefaultAxisOptions()]\n },\n stacked: false,\n xGridLine: true,\n yGridLine: true,\n y2ndGridLine: false,\n multiAxis: false\n },\n type\n }\n }\n\n getDefaultAxisOptions(): OperatoChart.AxisOptions {\n return {\n axisTitle: '',\n barSpacing: 0,\n categorySpacing: 0,\n barPercentage: 0.9,\n ticks: {\n display: true,\n autoMin: true,\n autoMax: true,\n min: undefined,\n max: undefined,\n stepSize: undefined\n }\n }\n }\n\n onValuesChanged(e: Event) {\n e.stopPropagation()\n\n const element = e.target as HTMLInputElement\n let key = element.getAttribute('value-key')\n let value = element.value\n\n if (!key) {\n return\n }\n\n value = this._getElementValue(element)\n\n const attrs = key.split('.')\n let attr = attrs.shift() || ''\n let variable: any = this.configurer\n\n while (attrs.length > 0) {\n variable = variable[attr]\n attr = attrs.shift() || ''\n }\n\n variable[attr] = value\n\n this.value = { ...this.configurer.value }\n\n this.dispatchEvent(new CustomEvent('change', { bubbles: true, composed: true }))\n this.requestUpdate()\n }\n\n onTapAddSeriesTab(e: Event) {\n const configurer = this.configurer\n\n if (!configurer.config.data.datasets) return\n\n const lastSeriesIndex = configurer.config.data.datasets.length\n const chartType = configurer.series.type || configurer.config.type\n const color = configurer.datasets[lastSeriesIndex - 1]?.backgroundColor\n const lastSeriesColor = new TinyColor(Array.isArray(color) ? color[0] : color)\n\n const seriesModel = this._getSeriesModel({\n chartType: chartType!,\n datasetsLength: lastSeriesIndex,\n lastSeriesColor\n })\n\n configurer.config.data.datasets.push(seriesModel)\n this.dispatchEvent(new CustomEvent('change', { bubbles: true, composed: true }))\n configurer.setCurrentSeriesIndex(lastSeriesIndex)\n\n this.value = { ...this.configurer.value }\n }\n\n onTapRemoveCurrentSeriesTab(index: number) {\n const configurer = this.configurer\n\n if (!configurer.config.data.datasets) {\n return\n }\n\n this.configurer.data.datasets.splice(index, 1)\n\n this.dispatchEvent(new CustomEvent('change', { bubbles: true, composed: true }))\n configurer.setCurrentSeriesIndex(Math.max(0, configurer.currentSeriesIndex - 1))\n\n this.requestUpdate()\n }\n\n onTapAddAnnotation(e: Event) {\n const configurer = this.configurer\n\n const lastAnnotationIndex = configurer.annotations.length\n configurer.annotations.push({ type: 'line', x1: 0, y1: 0 })\n\n this.dispatchEvent(new CustomEvent('change', { bubbles: true, composed: true }))\n configurer.setCurrentAnnotationIndex(lastAnnotationIndex)\n\n this.value = { ...this.configurer.value }\n }\n\n onTapRemoveCurrentAnnotation(index: number) {\n const configurer = this.configurer\n\n if (!configurer.annotations) {\n return\n }\n\n configurer.annotations.splice(index, 1)\n\n this.dispatchEvent(new CustomEvent('change', { bubbles: true, composed: true }))\n configurer.setCurrentAnnotationIndex(Math.max(0, configurer.currentAnnotationIndex - 1))\n\n this.requestUpdate()\n }\n\n _getSeriesModel({\n chartType,\n datasetsLength,\n lastSeriesColor\n }: {\n chartType: string\n datasetsLength: number\n lastSeriesColor: TinyColor\n }) {\n const addSeriesOption: any = {\n label: `series ${datasetsLength + 1}`,\n data: [],\n borderWidth: 1,\n dataKey: '',\n yAxisID: 'left',\n color: randomColor({\n hue: lastSeriesColor.toHsv().h\n }).toRgbString(),\n stack: ''\n }\n\n addSeriesOption.type = addSeriesOption.chartType = chartType\n return addSeriesOption\n }\n\n _getElementValue(element: HTMLElement) {\n switch (element.tagName) {\n case 'INPUT':\n switch ((element as HTMLInputElement).type) {\n case 'checkbox':\n return (element as HTMLInputElement).checked\n case 'number':\n return Number((element as HTMLInputElement).value) || 0\n case 'text':\n return String((element as HTMLInputElement).value)\n }\n default:\n return (element as any).value\n }\n }\n\n annotationsTabTemplate() {\n const configurer = this.configurer\n const currentAnnotation = configurer.annotations[configurer.currentAnnotationIndex] || {}\n\n return keyed(\n configurer.currentAnnotationIndex,\n html`\n <div id=\"annotations-properties-container\" fullwidth>\n <div id=\"annotations-tab-header\">\n <md-icon\n id=\"annotations-tab-nav-left-button\"\n @tap=${(e: Event) => {\n this._onTabScrollNavLeft(e, 'annotations')\n }}\n disabled\n >chevron_left</md-icon\n >\n <div\n id=\"annotations-tabs\"\n @change=${(e: Event) => {\n configurer.setCurrentAnnotationIndex((e.target as any).activeTabIndex)\n }}\n active-tab-index=${configurer.currentAnnotationIndex}\n fit-container\n >\n ${configurer.annotations!.map(\n (annotation: any, index: number) => html`\n <div\n data-annotation=${index + 1}\n data-tab-index=${index}\n tab\n ?selected=${index == configurer.currentAnnotationIndex}\n @click=${(e: Event) => {\n const target = e.target as HTMLDivElement\n this.configurer.setCurrentAnnotationIndex(Number(target.getAttribute('data-tab-index')))\n this.value = { ...this.configurer.value }\n }}\n >\n ${index + 1}\n ${!configurer.annotations ||\n (configurer.annotations.length != 1 && configurer.currentAnnotationIndex == index)\n ? html`\n <md-icon @tap=${(e: Event) => this.onTapRemoveCurrentAnnotation(index)}> close </md-icon>\n `\n : html``}\n </div>\n `\n )}\n </div>\n <md-icon\n id=\"annotations-tab-nav-right-button\"\n @click=${(e: Event) => {\n this._onTabScrollNavRight(e, 'annotations')\n }}\n disabled\n >chevron_right</md-icon\n >\n </div>\n <div id=\"add-annotation-button-container\">\n <md-icon id=\"add-annotation-button\" @tap=${(e: Event) => this.onTapAddAnnotation(e)}>add</md-icon>\n </div>\n\n <div class=\"tab-content\">\n <label for=\"annotation-type\"> <ox-i18n msgid=\"label.chart-annotation-type\">Type</ox-i18n> </label>\n <select\n id=\"annotation-type\"\n class=\"select-content\"\n value-key=\"annotation.type\"\n .value=${currentAnnotation.type || ''}\n >\n <option value=\"\"> </option>\n <option value=\"line\">Line</option>\n <option value=\"text\">Text</option>\n <option value=\"box\">Box</option>\n <option value=\"horizontalLine\">Horizontal Line</option>\n <option value=\"verticalLine\">Vertical Line</option>\n </select>\n\n <label for=\"annotation-x1\">X1</label>\n <input\n id=\"annotation-x1\"\n type=\"number\"\n value-key=\"annotation.x1\"\n .value=${String(currentAnnotation.x1 || 0)}\n />\n\n <label for=\"annotation-y1\">Y1</label>\n <input\n id=\"annotation-y1\"\n type=\"number\"\n value-key=\"annotation.y1\"\n .value=${String(currentAnnotation.y1 || 0)}\n />\n\n <label for=\"annotation-x2\">X2</label>\n <input\n id=\"annotation-x2\"\n type=\"number\"\n value-key=\"annotation.x2\"\n .value=${String(currentAnnotation.x2 || 0)}\n />\n\n <label for=\"annotation-y2\">Y2</label>\n <input\n id=\"annotation-y2\"\n type=\"number\"\n value-key=\"annotation.y2\"\n .value=${String(currentAnnotation.y2 || 0)}\n />\n\n <label for=\"annotation-stroke\"> <ox-i18n msgid=\"label.stroke-style\">Stroke Style</ox-i18n> </label>\n <ox-input-color\n id=\"annotation-stroke\"\n value-key=\"annotation.stroke\"\n .value=${currentAnnotation.stroke}\n ></ox-input-color>\n\n <label for=\"annotation-stroke-thickness\">\n <ox-i18n msgid=\"label.stroke-thickness\">Stroke Thickness</ox-i18n>\n </label>\n <input\n id=\"annotation-stroke-thickness\"\n type=\"number\"\n value-key=\"annotation.strokeThickness\"\n .value=${String(currentAnnotation.strokeThickness || 1)}\n />\n\n <label for=\"annotation-fill\"> <ox-i18n msgid=\"label.fill\">Fill</ox-i18n> </label>\n <ox-input-color\n id=\"annotation-fill\"\n value-key=\"annotation.fill\"\n .value=${currentAnnotation.fill}\n ></ox-input-color>\n\n <label for=\"annotation-text\"> <ox-i18n msgid=\"label.annotation-text\">Text</ox-i18n> </label>\n <input\n id=\"annotation-text\"\n type=\"text\"\n value-key=\"annotation.text\"\n .value=${currentAnnotation.text || ''}\n />\n\n <label for=\"annotation-horizontal-anchor\">\n <ox-i18n msgid=\"label.horizontal-anchor\">Horizontal Anchor</ox-i18n>\n </label>\n <select\n id=\"annotation-horizontal-anchor\"\n class=\"select-content\"\n value-key=\"annotation.horizontalAnchorPoint\"\n .value=${currentAnnotation.horizontalAnchorPoint || ''}\n >\n <option value=\"\"> </option>\n <option value=\"Left\">Left</option>\n <option value=\"Center\">Center</option>\n <option value=\"Right\">Right</option>\n </select>\n\n <label for=\"annotation-vertical-anchor\">\n <ox-i18n msgid=\"label.vertical-anchor\">Vertical Anchor</ox-i18n>\n </label>\n <select\n id=\"annotation-vertical-anchor\"\n class=\"select-content\"\n value-key=\"annotation.verticalAnchorPoint\"\n .value=${currentAnnotation.verticalAnchorPoint || ''}\n >\n <option value=\"\"> </option>\n <option value=\"Top\">Top</option>\n <option value=\"Center\">Center</option>\n <option value=\"Bottom\">Bottom</option>\n </select>\n\n <label for=\"annotation-x-coordinate-mode\">X Coordinate Mode</label>\n <select\n id=\"annotation-x-coordinate-mode\"\n class=\"select-content\"\n value-key=\"annotation.xCoordinateMode\"\n .value=${currentAnnotation.xCoordinateMode || 'DataValue'}\n >\n <option value=\"\"> </option>\n <option value=\"DataValue\">DataValue</option>\n <option value=\"Pixel\">Pixel</option>\n <option value=\"Relative\">Relative</option>\n </select>\n\n <label for=\"annotation-y-coordinate-mode\">Y Coordinate Mode</label>\n <select\n id=\"annotation-y-coordinate-mode\"\n class=\"select-content\"\n value-key=\"annotation.yCoordinateMode\"\n .value=${currentAnnotation.yCoordinateMode || 'DataValue'}\n >\n <option value=\"\"> </option>\n <option value=\"DataValue\">DataValue</option>\n <option value=\"Pixel\">Pixel</option>\n <option value=\"Relative\">Relative</option>\n </select>\n </div>\n </div>\n `\n )\n }\n\n multiSeriesTabTemplate() {\n const configurer = this.configurer\n\n return keyed(\n configurer.currentSeriesIndex,\n html`\n <div id=\"series-properties-container\" fullwidth>\n <div id=\"series-tab-header\">\n <md-icon\n id=\"series-tab-nav-left-button\"\n @tap=${(e: Event) => {\n this._onTabScrollNavLeft(e, 'series')\n }}\n disabled\n >chevron_left</md-icon\n >\n <div\n id=\"series-tabs\"\n @change=${(e: Event) => {\n // configurer.currentSeriesIndex = (e.target as any).activeTabIndex\n configurer.setCurrentSeriesIndex((e.target as any).activeTabIndex)\n }}\n active-tab-index=${configurer.currentSeriesIndex}\n fit-container\n >\n ${configurer.datasets.map(\n (dataset: any, index: number) => html`\n <div\n data-series=${index + 1}\n data-tab-index=${index}\n tab\n ?selected=${index == configurer.currentSeriesIndex}\n @click=${(e: Event) => {\n const target = e.target as HTMLDivElement\n this.configurer.setCurrentSeriesIndex(Number(target.getAttribute('data-tab-index')))\n this.value = { ...this.configurer.value }\n }}\n >\n ${index + 1}\n ${!configurer.datasets ||\n (configurer.datasets.length != 1 && configurer.currentSeriesIndex == index)\n ? html` <md-icon @tap=${(e: Event) => this.onTapRemoveCurrentSeriesTab(index)}> close </md-icon> `\n : html``}\n </div>\n `\n )}\n </div>\n <md-icon\n id=\"series-tab-nav-right-button\"\n @click=${(e: Event) => {\n this._onTabScrollNavRight(e, 'series')\n }}\n disabled\n >chevron_right</md-icon\n >\n </div>\n <div id=\"add-series-button-container\">\n <md-icon id=\"add-series-button\" @tap=${(e: Event) => this.onTapAddSeriesTab(e)}>add</md-icon>\n </div>\n\n <div class=\"tab-content\">\n <label for=\"data-key\"> <ox-i18n msgid=\"label.data-key\">Data Key</ox-i18n> </label>\n <input id=\"data-key\" type=\"text\" value-key=\"dataKey\" .value=${configurer.dataKey || ''} />\n\n ${this.chartType == 'line' || this.chartType == 'bar'\n ? html`\n <label for=\"series-type\"> <ox-i18n msgid=\"label.series-type\">Type</ox-i18n> </label>\n <select\n id=\"series-type\"\n class=\"select-content\"\n value-key=\"series.type\"\n .value=${configurer.series.type || ''}\n >\n <option value=\"bar\" selected>Bar</option>\n <option value=\"line\">Line</option>\n </select>\n `\n : html``}\n\n <label for=\"series-label\"> <ox-i18n msgid=\"label.label\">Label</ox-i18n> </label>\n <input id=\"series-label\" type=\"text\" value-key=\"series.label\" .value=${configurer.series.label || ''} />\n\n ${configurer.series.type == 'line'\n ? html`\n <label for=\"series-line-tension\"> <ox-i18n msgid=\"label.line-tension\">Line Tension</ox-i18n> </label>\n <select\n id=\"series-line-tension\"\n class=\"select-content\"\n value-key=\"series.lineTension\"\n .value=${String(configurer.series.lineTension || 0)}\n >\n <option value=\"0.4\">Smooth</option>\n <option value=\"0\">Angled</option>\n </select>\n `\n : html``}\n ${configurer.series.type == 'line'\n ? html`\n <label for=\"series-border-width\"> <ox-i18n msgid=\"label.border-width\">Border Width</ox-i18n> </label>\n <input\n id=\"series-border-width\"\n type=\"number\"\n value-key=\"series.borderWidth\"\n .value=${String(configurer.series.borderWidth || 0)}\n />\n `\n : html``}\n\n <label for=\"series-color\"> <ox-i18n msgid=\"label.color\">Color</ox-i18n> </label>\n <ox-input-color id=\"series-color\" value-key=\"color\" .value=${configurer.color}></ox-input-color>\n\n ${configurer.series.type == 'line'\n ? html`\n <label for=\"series-point-style\"> <ox-i18n msgid=\"label.point-shape\">Point Shape</ox-i18n> </label>\n <select\n id=\"series-point-style\"\n class=\"select-content\"\n value-key=\"series.pointStyle\"\n .value=${configurer.series.pointStyle || ''}\n >\n <option value=\"\"> </option>\n <option value=\"circle\">⚬</option>\n <option value=\"triangle\">▵</option>\n <option value=\"rect\">□</option>\n <option value=\"rectRot\">◇</option>\n <option value=\"cross\">+</option>\n <option value=\"crossRot\">⨉</option>\n <option value=\"star\">✱</option>\n <option value=\"line\">―</option>\n <option value=\"dash\">┄</option>\n </select>\n\n <label for=\"series-point-radius\"> <ox-i18n msgid=\"label.point-size\">Point Size</ox-i18n> </label>\n <input\n id=\"series-point-radius\"\n type=\"number\"\n value-key=\"series.pointRadius\"\n .value=${String(configurer.series.pointRadius || 0)}\n />\n `\n : html``} <label for=\"series-stack\"> <ox-i18n msgid=\"label.stack-group\">Stack group</ox-i18n> </label>\n <input id=\"series-stack\" type=\"text\" value-key=\"series.stack\" .value=${configurer.series.stack || ''} />\n ${configurer.series.type == 'line'\n ? html`\n <input id=\"seires-fill\" type=\"checkbox\" value-key=\"series.fill\" ?checked=${configurer.series.fill} />\n <label for=\"seires-fill\"> <ox-i18n msgid=\"label.fill\">Fill</ox-i18n> </label>\n `\n : html``}\n ${configurer.multiAxis\n ? html`\n <label for=\"series-y-axis-id\"> <ox-i18n msgid=\"label.target-axis\">Target Axis</ox-i18n> </label>\n <select\n id=\"series-y-axis-id\"\n class=\"select-content\"\n value-key=\"series.yAxisID\"\n .value=${configurer.series.yAxisID || ''}\n >\n <option value=\"left\">Left</option>\n <option value=\"right\">Right</option>\n </select>\n `\n : html``}\n ${this.displayValueTemplate()}\n </div>\n </div>\n `\n )\n }\n\n _onTabScroll(e: Event, type: 'series' | 'annotations') {\n let tabContainer: HTMLElement | null | undefined\n let tabNavLeftButton: MdIcon\n let tabNavRightButton: MdIcon\n\n if (type === 'series') {\n tabContainer = this.seriesTabContainer\n tabNavLeftButton = this.seriesTabNavLeftButton\n tabNavRightButton = this.seriesTabNavRightButton\n } else {\n tabContainer = this.annotationsTabContainer\n tabNavLeftButton = this.annotationsTabNavLeftButton\n tabNavRightButton = this.annotationsTabNavRightButton\n }\n\n if (!tabContainer) {\n return\n }\n\n if (tabContainer.clientWidth == tabContainer.scrollWidth) {\n tabNavLeftButton.setAttribute('disabled', '')\n tabNavRightButton.setAttribute('disabled', '')\n }\n // left-end\n else if (tabContainer.scrollLeft == 0) {\n tabNavLeftButton.setAttribute('disabled', '')\n tabNavRightButton.removeAttribute('disabled')\n }\n // right-end\n else if (tabContainer.scrollLeft + tabContainer.clientWidth >= tabContainer.scrollWidth) {\n tabNavLeftButton.removeAttribute('disabled')\n tabNavRightButton.setAttribute('disabled', '')\n } else {\n tabNavLeftButton.removeAttribute('disabled')\n tabNavRightButton.removeAttribute('disabled')\n }\n }\n\n _onTabScrollNavLeft(e: Event, type: 'series' | 'annotations') {\n let tabContainer: HTMLElement | null | undefined\n\n if (type === 'series') {\n tabContainer = this.seriesTabContainer\n } else {\n tabContainer = this.annotationsTabContainer\n }\n\n if (!tabContainer) {\n return\n }\n\n tabContainer.style.scrollBehavior = 'smooth'\n tabContainer.scrollLeft -= tabContainer.clientWidth\n tabContainer.style.scrollBehavior = 'auto'\n }\n\n _onTabScrollNavRight(e: Event, type: 'series' | 'annotations') {\n let tabContainer: HTMLElement | null | undefined\n\n if (type === 'series') {\n tabContainer = this.seriesTabContainer\n } else {\n tabContainer = this.annotationsTabContainer\n }\n\n if (!tabContainer) {\n return\n }\n\n tabContainer.style.scrollBehavior = 'smooth'\n tabContainer.scrollLeft += tabContainer.clientWidth\n tabContainer.style.scrollBehavior = 'auto'\n }\n}\n"]}
|
|
1
|
+
{"version":3,"file":"input-chart-abstract.js","sourceRoot":"","sources":["../../../src/editors/input-chart-abstract.ts"],"names":[],"mappings":";AAAA,OAAO,0BAA0B,CAAA;AAEjC,OAAO,EAAE,IAAI,EAAkB,MAAM,KAAK,CAAA;AAC1C,OAAO,EAAE,QAAQ,EAAE,MAAM,mBAAmB,CAAA;AAE5C,OAAO,EAAE,MAAM,IAAI,WAAW,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAA;AAElE,OAAO,EAAE,gBAAgB,EAAE,MAAM,sBAAsB,CAAA;AACvD,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAA;AACzC,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAA;AAE5C,MAAM,OAAO,kBAAmB,SAAQ,WAAW;IAAnD;;QAG8B,UAAK,GAAoC,IAAI,CAAA;IA2L3E,CAAC;aA7LQ,WAAM,GAAG,CAAC,gBAAgB,CAAC,AAArB,CAAqB;IAOlC,IAAI,UAAU;QACZ,IAAI,CAAC,IAAI,CAAC,WAAW,EAAE,CAAC;YACtB,IAAI,CAAC,WAAW,GAAG,IAAI,UAAU,CAAC,IAAI,CAAC,KAAK,EAAE,GAAG,EAAE;gBACjD,OAAO,IAAI,CAAC,KAAK,IAAI,IAAI,CAAC,qBAAqB,CAAC,IAAI,CAAC,SAAS,EAAE,IAAI,CAAC,kBA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C;oBAC3C,KAAK,UAAU;wBACb,OAAQ,OAA4B,CAAC,OAAO,CAAA;oBAC9C,KAAK,QAAQ;wBACX,OAAO,MAAM,CAAE,OAA4B,CAAC,KAAK,CAAC,IAAI,CAAC,CAAA;oBACzD,KAAK,MAAM;wBACT,OAAO,MAAM,CAAE,OAA4B,CAAC,KAAK,CAAC,CAAA;gBACtD,CAAC;YACH;gBACE,OAAQ,OAAe,CAAC,KAAK,CAAA;QACjC,CAAC;IACH,CAAC;;AA1L2B;IAA3B,QAAQ,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;iDAA8C;AACpB;IAApD,QAAQ,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,SAAS,EAAE,YAAY,EAAE,CAAC;qDAAkC","sourcesContent":["import '@operato/i18n/ox-i18n.js'\n\nimport { html, PropertyValues } from 'lit'\nimport { property } from 'lit/decorators.js'\n\nimport { random as randomColor, TinyColor } from '@ctrl/tinycolor'\n\nimport { InputChartStyles } from './input-chart-styles'\nimport { Configurer } from './configurer'\nimport { OxFormField } from '@operato/input'\n\nexport class InputChartAbstract extends OxFormField {\n static styles = [InputChartStyles]\n\n @property({ type: Object }) value: OperatoChart.ChartConfig | null = null\n @property({ type: String, attribute: 'chart-type' }) chartType: OperatoChart.ChartType\n\n private _configurer?: Configurer\n\n get configurer() {\n if (!this._configurer) {\n this._configurer = new Configurer(this.value, () => {\n return this.value || this.getDefaultChartConfig(this.chartType, this.getDefaultDatasets())\n })\n }\n return this._configurer\n }\n\n updated(changes: PropertyValues<this>) {\n if (changes.has('value')) {\n this.configurer.updateValue(this.value!)\n }\n }\n\n render() {\n const configurer = this.configurer\n\n return html`\n <legend><ox-i18n msgid=\"label.chart\">Chart</ox-i18n></legend>\n\n <label for=\"theme\"> <ox-i18n msgid=\"label.theme\">Theme</ox-i18n> </label>\n <select id=\"theme\" value-key=\"theme\" class=\"select-content\" .value=${configurer.theme || 'light'}>\n <option value=\"auto\">auto</option>\n <option value=\"dark\">dark</option>\n <option value=\"light\" checked>light</option>\n </select>\n\n <input id=\"tooltip\" type=\"checkbox\" value-key=\"tooltip\" ?checked=${configurer.tooltip} />\n <label for=\"tooltip\"> <ox-i18n msgid=\"label.tooltip\">Tooltip</ox-i18n> </label>\n\n <input id=\"animation\" type=\"checkbox\" value-key=\"animation\" ?checked=${configurer.animation} />\n <label for=\"animation\"> <ox-i18n msgid=\"label.animation\">Animation</ox-i18n> </label>\n\n <input id=\"display\" type=\"checkbox\" value-key=\"display\" ?checked=${configurer.display} />\n <label for=\"display\"> <ox-i18n msgid=\"label.legend\">Legend</ox-i18n> </label>\n\n <input id=\"stacked\" type=\"checkbox\" value-key=\"stacked\" ?checked=${configurer.stacked} />\n <label for=\"stacked\"> <ox-i18n msgid=\"label.stacked\">Stacked</ox-i18n> </label>\n\n ${configurer.display\n ? html`\n <label for=\"position\"> <ox-i18n msgid=\"label.position\">Position</ox-i18n> </label>\n <select id=\"position\" value-key=\"position\" class=\"select-content\" .value=${configurer.position || ''}>\n <option value=\"top\">top</option>\n <option value=\"right\">right</option>\n <option value=\"bottom\">bottom</option>\n <option value=\"left\">left</option>\n </select>\n `\n : html``}\n ${this.subTemplate()}\n `\n }\n\n connectedCallback() {\n super.connectedCallback()\n\n this.renderRoot.addEventListener('change', this.onValuesChanged.bind(this))\n }\n\n subTemplate() {\n return html``\n }\n\n getDefaultDatasets(): OperatoChart.Dataset[] {\n return [this.getDefaultDataset('bar')]\n }\n\n getDefaultDataset(seriesType: 'bar' | 'horizontalBar' | 'line' | 'radar' | 'pie'): OperatoChart.Dataset {\n return {\n label: 'Series 1',\n data: [],\n borderWidth: 1,\n dataKey: '',\n yAxisID: 'left',\n color: randomColor({\n hue: new TinyColor('#fff').clone().toString()\n }).toRgbString(),\n backgroundColor: '#FFFFFF',\n type: seriesType,\n stack: '',\n fill: false,\n lineTension: 0.4,\n pointStyle: 'circle',\n pointRadius: 3,\n valuePrefix: '',\n valueSuffix: '',\n displayValue: false\n }\n }\n\n getDefaultChartConfig(type: OperatoChart.ChartType, datasets?: OperatoChart.Dataset[]): OperatoChart.ChartConfig {\n return {\n data: {\n datasets: datasets || [],\n labelDataKey: ''\n },\n options: {\n theme: 'light',\n tooltip: true,\n animation: true,\n legend: {\n display: true,\n position: 'top'\n },\n scales: {\n xAxes: [this.getDefaultAxisOptions()],\n yAxes: [this.getDefaultAxisOptions()]\n },\n stacked: false,\n xGridLine: true,\n yGridLine: true,\n y2ndGridLine: false,\n multiAxis: false\n },\n type\n }\n }\n\n getDefaultAxisOptions(): OperatoChart.AxisOptions {\n return {\n axisTitle: '',\n barSpacing: 0,\n categorySpacing: 0,\n barPercentage: 0.9,\n ticks: {\n display: true,\n autoMin: true,\n autoMax: true,\n min: undefined,\n max: undefined,\n stepSize: undefined\n }\n }\n }\n\n onValuesChanged(e: Event) {\n e.stopPropagation()\n\n const element = e.target as HTMLInputElement\n let key = element.getAttribute('value-key')\n let value = element.value\n\n if (!key) {\n return\n }\n\n value = this._getElementValue(element)\n\n const attrs = key.split('.')\n let attr = attrs.shift() || ''\n let variable: any = this.configurer\n\n while (attrs.length > 0) {\n variable = variable[attr]\n attr = attrs.shift() || ''\n }\n\n variable[attr] = value\n\n this.value = { ...this.configurer.value }\n\n this.dispatchEvent(new CustomEvent('change', { bubbles: true, composed: true }))\n this.requestUpdate()\n }\n\n _getElementValue(element: HTMLElement) {\n switch (element.tagName) {\n case 'INPUT':\n switch ((element as HTMLInputElement).type) {\n case 'checkbox':\n return (element as HTMLInputElement).checked\n case 'number':\n return Number((element as HTMLInputElement).value) || 0\n case 'text':\n return String((element as HTMLInputElement).value)\n }\n default:\n return (element as any).value\n }\n }\n}\n"]}
|
|
@@ -175,5 +175,32 @@ export const InputChartStyles = css `
|
|
|
175
175
|
background-color: var(--md-sys-color-surface);
|
|
176
176
|
color: var(--md-sys-color-on-surface);
|
|
177
177
|
}
|
|
178
|
+
|
|
179
|
+
#display-value-container {
|
|
180
|
+
display: grid;
|
|
181
|
+
grid-template-columns: repeat(10, 1fr);
|
|
182
|
+
grid-gap: 5px;
|
|
183
|
+
|
|
184
|
+
background-color: var(--ox-input-background-color, var(--md-sys-color-surface));
|
|
185
|
+
color: var(--ox-input-color, var(--md-sys-color-on-surface));
|
|
186
|
+
}
|
|
187
|
+
|
|
188
|
+
#display-value-container > * {
|
|
189
|
+
box-sizing: border-box;
|
|
190
|
+
grid-column: span 7;
|
|
191
|
+
}
|
|
192
|
+
|
|
193
|
+
#display-value-container > label {
|
|
194
|
+
box-sizing: border-box;
|
|
195
|
+
grid-column: span 3;
|
|
196
|
+
}
|
|
197
|
+
|
|
198
|
+
#display-value-container > legend {
|
|
199
|
+
box-sizing: border-box;
|
|
200
|
+
grid-column: 1 / -1;
|
|
201
|
+
color: var(--md-sys-color-on-secondary-container, #e46c2e);
|
|
202
|
+
font: var(--property-sidebar-fieldset-legend, bold 13px var(--theme-font));
|
|
203
|
+
text-transform: capitalize;
|
|
204
|
+
}
|
|
178
205
|
`;
|
|
179
206
|
//# sourceMappingURL=input-chart-styles.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"input-chart-styles.js","sourceRoot":"","sources":["../../../src/editors/input-chart-styles.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,KAAK,CAAA;AAEzB,MAAM,CAAC,MAAM,gBAAgB,GAAG,GAAG,CAAA
|
|
1
|
+
{"version":3,"file":"input-chart-styles.js","sourceRoot":"","sources":["../../../src/editors/input-chart-styles.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,KAAK,CAAA;AAEzB,MAAM,CAAC,MAAM,gBAAgB,GAAG,GAAG,CAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA2MlC,CAAA","sourcesContent":["import { css } from 'lit'\n\nexport const InputChartStyles = css`\n :host {\n display: grid;\n grid-template-columns: repeat(10, 1fr);\n grid-gap: 5px;\n\n background-color: var(--ox-input-background-color, var(--md-sys-color-surface));\n color: var(--ox-input-color, var(--md-sys-color-on-surface));\n }\n\n :host > * {\n box-sizing: border-box;\n grid-column: span 7;\n }\n\n :host > label {\n box-sizing: border-box;\n grid-column: span 3;\n }\n\n :host > legend {\n box-sizing: border-box;\n grid-column: 1 / -1;\n color: var(--md-sys-color-on-secondary-container, #e46c2e);\n font: var(--property-sidebar-fieldset-legend, bold 13px var(--theme-font));\n text-transform: capitalize;\n }\n\n #series-properties-container,\n #annotations-properties-container {\n display: grid;\n grid-template-columns: 1fr 25px;\n align-items: center;\n justify-content: center;\n }\n\n #series-properties-container > [tab-content],\n #annotations-properties-container > [tab-content] {\n grid-column: span 2;\n }\n\n #series-tab-header,\n #annotations-tab-header {\n display: grid;\n grid-template-columns: 25px 1fr 25px;\n grid-gap: 5px;\n overflow: hidden;\n border: 1px solid rgba(0, 0, 0, 0.2);\n border-bottom: 0;\n background-color: var(--md-sys-color-surface-variant);\n color: var(--md-sys-color-on-surface);\n box-sizing: border-box;\n padding-top: 3px;\n align-items: center;\n }\n\n #series-tab-header > div,\n #annotations-tab-header > div {\n height: 25px;\n }\n\n #series-tab-header md-icon[disabled],\n #annotations-tab-header md-icon[disabled] {\n opacity: 0.1;\n }\n\n #series-tabs,\n #annotations-tabs {\n display: flex;\n overflow: hidden;\n }\n\n #series-tab-header #series-tabs [tab] md-icon,\n #annotations-tab-header #annotations-tabs [tab] md-icon {\n margin-left: auto;\n padding: 2px;\n color: var(--md-sys-color-on-surface);\n\n --md-icon-size: 12px;\n }\n\n #add-series-button-container,\n #add-annotation-button-container {\n height: 100%;\n box-sizing: border-box;\n align-items: center;\n justify-content: center;\n padding-top: 3px;\n display: flex;\n border-bottom: rgba(0, 0, 0, 0.2) 1px solid;\n }\n\n #add-series-button,\n #add-annotation-button {\n width: 20px;\n height: 20px;\n padding: 0;\n color: var(--md-sys-color-on-secondary-container);\n }\n\n .tab-content {\n grid-column: 1 / -1;\n\n background-color: rgba(255, 255, 255, 0.5);\n border: 1px solid rgba(0, 0, 0, 0.2);\n border-width: 0 1px 1px 1px;\n padding: 5px;\n display: grid;\n grid-template-columns: repeat(10, 1fr);\n grid-gap: 5px;\n }\n\n .tab-content > * {\n box-sizing: border-box;\n grid-column: span 7;\n }\n\n label,\n .tab-content > label {\n grid-column: span 3;\n text-align: right;\n color: var(--md-sys-color-on-secondary-container);\n font-size: 0.8em;\n line-height: 2;\n text-transform: capitalize;\n }\n\n input,\n select {\n border: 1px solid rgba(0, 0, 0, 0.2);\n border-radius: var(--spacing-small);\n }\n\n input[type='checkbox'],\n .tab-content > input[type='checkbox'] {\n grid-column: span 4;\n justify-self: end;\n align-self: center;\n }\n\n input[type='checkbox'] + label,\n .tab-content > input[type='checkbox'] + label {\n grid-column: span 6;\n\n text-align: left;\n }\n\n [fullwidth] {\n grid-column: 1 / -1;\n margin: 0;\n border: 0;\n }\n\n div[tab] {\n display: flex;\n align-items: center;\n background-color: rgba(0, 0, 0, 0.2);\n border-width: 1px 1px 0 1px;\n padding: 0 5px;\n color: var(--md-sys-color-on-surface);\n box-sizing: border-box;\n min-width: 45px;\n }\n\n div[tab][disabled] {\n background-color: rgba(0, 0, 0, 0.1);\n }\n\n div[tab]:last-child {\n border-width: 0;\n }\n\n div[tab][selected] {\n background-color: var(--md-sys-color-surface);\n color: var(--md-sys-color-on-surface);\n }\n\n #display-value-container {\n display: grid;\n grid-template-columns: repeat(10, 1fr);\n grid-gap: 5px;\n\n background-color: var(--ox-input-background-color, var(--md-sys-color-surface));\n color: var(--ox-input-color, var(--md-sys-color-on-surface));\n }\n\n #display-value-container > * {\n box-sizing: border-box;\n grid-column: span 7;\n }\n\n #display-value-container > label {\n box-sizing: border-box;\n grid-column: span 3;\n }\n\n #display-value-container > legend {\n box-sizing: border-box;\n grid-column: 1 / -1;\n color: var(--md-sys-color-on-secondary-container, #e46c2e);\n font: var(--property-sidebar-fieldset-legend, bold 13px var(--theme-font));\n text-transform: capitalize;\n }\n`\n"]}
|
|
@@ -2,9 +2,9 @@ import '@material/web/icon/icon.js';
|
|
|
2
2
|
import '@operato/input/ox-input-color.js';
|
|
3
3
|
import '@operato/i18n/ox-i18n.js';
|
|
4
4
|
import { InputChartAbstract } from './input-chart-abstract';
|
|
5
|
+
import './templates/display-value';
|
|
5
6
|
export declare class OxInputChartHBar extends InputChartAbstract {
|
|
6
7
|
static styles: import("lit").CSSResult[];
|
|
7
8
|
subTemplate(): import("lit-html").TemplateResult<1>;
|
|
8
|
-
multiSeriesTabTemplate(): import("lit-html").TemplateResult<1>;
|
|
9
9
|
getDefaultDatasets(): OperatoChart.Dataset[];
|
|
10
10
|
}
|
|
@@ -6,13 +6,14 @@ import { html } from 'lit';
|
|
|
6
6
|
import { customElement } from 'lit/decorators.js';
|
|
7
7
|
import { ifDefined } from 'lit/directives/if-defined.js';
|
|
8
8
|
import { InputChartAbstract } from './input-chart-abstract';
|
|
9
|
+
import './templates/display-value';
|
|
9
10
|
let OxInputChartHBar = class OxInputChartHBar extends InputChartAbstract {
|
|
10
11
|
static { this.styles = InputChartAbstract.styles; }
|
|
11
12
|
subTemplate() {
|
|
12
13
|
const configurer = this.configurer;
|
|
13
14
|
return html `
|
|
14
15
|
<legend><ox-i18n msgid="label.series">Series</ox-i18n></legend>
|
|
15
|
-
|
|
16
|
+
<ox-chart-series .configurer=${configurer} .chartType=${this.chartType} fullwidth></ox-chart-series>
|
|
16
17
|
|
|
17
18
|
<legend><ox-i18n msgid="label.y-axes">Y Axes</ox-i18n></legend>
|
|
18
19
|
|
|
@@ -138,74 +139,6 @@ let OxInputChartHBar = class OxInputChartHBar extends InputChartAbstract {
|
|
|
138
139
|
<label for="y-axes0-ticks-display"> <ox-i18n msgid="label.display-tick">Display Tick</ox-i18n> </label>
|
|
139
140
|
`;
|
|
140
141
|
}
|
|
141
|
-
multiSeriesTabTemplate() {
|
|
142
|
-
const configurer = this.configurer;
|
|
143
|
-
return html `
|
|
144
|
-
<div id="series-properties-container" fullwidth>
|
|
145
|
-
<div id="series-tab-header">
|
|
146
|
-
<md-icon
|
|
147
|
-
id="series-tab-nav-left-button"
|
|
148
|
-
@tap=${(e) => {
|
|
149
|
-
this._onTabScrollNavLeft(e, 'series');
|
|
150
|
-
}}
|
|
151
|
-
disabled
|
|
152
|
-
>chevron_left</md-icon
|
|
153
|
-
>
|
|
154
|
-
<div
|
|
155
|
-
id="series-tabs"
|
|
156
|
-
@change=${(e) => {
|
|
157
|
-
configurer.currentSeriesIndex = e.target.activeTabIndex;
|
|
158
|
-
}}
|
|
159
|
-
active-tab-index=${configurer.currentSeriesIndex}
|
|
160
|
-
fit-container
|
|
161
|
-
>
|
|
162
|
-
${configurer.datasets.map((dataset, index) => html `
|
|
163
|
-
<div
|
|
164
|
-
data-series=${index + 1}
|
|
165
|
-
data-tab-index=${index}
|
|
166
|
-
tab
|
|
167
|
-
?selected=${index == configurer.currentSeriesIndex}
|
|
168
|
-
@click=${(e) => {
|
|
169
|
-
const target = e.target;
|
|
170
|
-
this.configurer.setCurrentSeriesIndex(Number(target.getAttribute('data-tab-index')));
|
|
171
|
-
this.value = { ...this.configurer.value };
|
|
172
|
-
}}
|
|
173
|
-
>
|
|
174
|
-
${index + 1}
|
|
175
|
-
${!configurer.datasets || (configurer.datasets.length != 1 && configurer.currentSeriesIndex == index)
|
|
176
|
-
? html ` <md-icon @tap=${(e) => this.onTapRemoveCurrentSeriesTab(index)}> close </md-icon> `
|
|
177
|
-
: html ``}
|
|
178
|
-
</div>
|
|
179
|
-
`)}
|
|
180
|
-
</div>
|
|
181
|
-
<md-icon
|
|
182
|
-
id="series-tab-nav-right-button"
|
|
183
|
-
@click=${(e) => {
|
|
184
|
-
this._onTabScrollNavRight(e, 'series');
|
|
185
|
-
}}
|
|
186
|
-
disabled
|
|
187
|
-
>chevron_right</md-icon
|
|
188
|
-
>
|
|
189
|
-
</div>
|
|
190
|
-
<div id="add-series-button-container">
|
|
191
|
-
<md-icon id="add-series-button" @tap=${(e) => this.onTapAddSeriesTab(e)}>add</md-icon>
|
|
192
|
-
</div>
|
|
193
|
-
|
|
194
|
-
<div class="tab-content">
|
|
195
|
-
<label for="data-key"> <ox-i18n msgid="label.data-key">Data Key</ox-i18n> </label>
|
|
196
|
-
<input id="data-key" type="text" value-key="dataKey" .value=${configurer.dataKey || ''} />
|
|
197
|
-
<label for="series-label"> <ox-i18n msgid="label.label">Label</ox-i18n> </label>
|
|
198
|
-
<input id="series-label" type="text" value-key="series.label" .value=${configurer.series.label || ''} />
|
|
199
|
-
<label for="series-color"> <ox-i18n msgid="label.color">Color</ox-i18n> </label>
|
|
200
|
-
<ox-input-color id="series-color" value-key="color" .value=${configurer.color || '#000'}></ox-input-color>
|
|
201
|
-
<label for="series-stack"> <ox-i18n msgid="label.stack-group">Stack Group</ox-i18n> </label>
|
|
202
|
-
<input id="series-stack" type="text" value-key="series.stack" .value=${configurer.series.stack || ''} />
|
|
203
|
-
|
|
204
|
-
${this.displayValueTemplate()}
|
|
205
|
-
</div>
|
|
206
|
-
</div>
|
|
207
|
-
`;
|
|
208
|
-
}
|
|
209
142
|
getDefaultDatasets() {
|
|
210
143
|
return [this.getDefaultDataset('horizontalBar')];
|
|
211
144
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ox-input-chart-hbar.js","sourceRoot":"","sources":["../../../src/editors/ox-input-chart-hbar.ts"],"names":[],"mappings":";AAAA,OAAO,4BAA4B,CAAA;AACnC,OAAO,kCAAkC,CAAA;AACzC,OAAO,0BAA0B,CAAA;AAEjC,OAAO,EAAE,IAAI,EAAE,MAAM,KAAK,CAAA;AAC1B,OAAO,EAAE,aAAa,EAAE,MAAM,mBAAmB,CAAA;AACjD,OAAO,EAAE,SAA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,CAAC,CAAC,IAAI,CAAA,kBAAkB,CAAC,CAAQ,EAAE,EAAE,CAAC,IAAI,CAAC,2BAA2B,CAAC,KAAK,CAAC,qBAAqB;YAClG,CAAC,CAAC,IAAI,CAAA,EAAE;;eAEb,CACF;;;;qBAIQ,CAAC,CAAQ,EAAE,EAAE;YACpB,IAAI,CAAC,oBAAoB,CAAC,CAAC,EAAE,QAAQ,CAAC,CAAA;QACxC,CAAC;;;;;;iDAMoC,CAAC,CAAQ,EAAE,EAAE,CAAC,IAAI,CAAC,iBAAiB,CAAC,CAAC,CAAC;;;;;wEAKhB,UAAU,CAAC,OAAO,IAAI,EAAE;;iFAEf,UAAU,CAAC,MAAM,CAAC,KAAK,IAAI,EAAE;;uEAEvC,UAAU,CAAC,KAAK,IAAI,MAAM;;iFAEhB,UAAU,CAAC,MAAM,CAAC,KAAK,IAAI,EAAE;;YAElG,IAAI,CAAC,oBAAoB,EAAE;;;KAGlC,CAAA;IACH,CAAC;IAED,kBAAkB;QAChB,OAAO,CAAC,IAAI,CAAC,iBAAiB,CAAC,eAAe,CAAC,CAAC,CAAA;IAClD,CAAC;;AAjNU,gBAAgB;IAD5B,aAAa,CAAC,qBAAqB,CAAC;GACxB,gBAAgB,CAkN5B","sourcesContent":["import '@material/web/icon/icon.js'\nimport '@operato/input/ox-input-color.js'\nimport '@operato/i18n/ox-i18n.js'\n\nimport { html } from 'lit'\nimport { customElement } from 'lit/decorators.js'\nimport { ifDefined } from 'lit/directives/if-defined.js'\n\nimport { InputChartAbstract } from './input-chart-abstract'\n\n@customElement('ox-input-chart-hbar')\nexport class OxInputChartHBar extends InputChartAbstract {\n static styles = InputChartAbstract.styles\n\n subTemplate() {\n const configurer = this.configurer\n\n return html`\n <legend><ox-i18n msgid=\"label.series\">Series</ox-i18n></legend>\n ${this.multiSeriesTabTemplate()}\n\n <legend><ox-i18n msgid=\"label.y-axes\">Y Axes</ox-i18n></legend>\n\n <label for=\"label-data-key\"> <ox-i18n msgid=\"label.data-key\">Data Key</ox-i18n> </label>\n <input id=\"label-data-key\" type=\"text\" value-key=\"labelDataKey\" value=${ifDefined(configurer.labelDataKey)} />\n\n <label for=\"y-axes0-axis-title\"> <ox-i18n msgid=\"label.title\">Title</ox-i18n> </label>\n <input\n id=\"y-axes0-axis-title\"\n type=\"text\"\n value-key=\"yAxes0.axisTitle\"\n value=${ifDefined(configurer.yAxes0.axisTitle)}\n />\n\n <label for=\"y-axes0-bar-spacing\"><ox-i18n msgid=\"label.bar-spacing\">Bar Spacing</ox-i18n></label>\n <input\n id=\"y-axes0-bar-spacing\"\n type=\"number\"\n min=\"0\"\n max=\"1\"\n step=\"0.1\"\n value-key=\"yAxes0.barSpacing\"\n value=${ifDefined(configurer.yAxes0.barSpacing)}\n />\n <label for=\"y-axes0-category-spacing\"><ox-i18n msgid=\"label.tick-spacing\">Tick Spacing</ox-i18n></label>\n <input\n id=\"y-axes0-category-spacing\"\n type=\"number\"\n min=\"0\"\n max=\"1\"\n step=\"0.1\"\n value-key=\"yAxes0.categorySpacing\"\n value=${ifDefined(configurer.yAxes0.categorySpacing)}\n />\n\n <input\n id=\"x-grid-line\"\n type=\"checkbox\"\n value-key=\"value.options.xGridLine\"\n ?checked=${configurer.config.options?.xGridLine}\n />\n <label for=\"x-grid-line\"> <ox-i18n msgid=\"label.grid-line\">Grid Line</ox-i18n> </label>\n\n <input\n id=\"x-axes0-ticks-display\"\n type=\"checkbox\"\n value-key=\"xAxes0.ticks.display\"\n ?checked=${configurer.xAxes0.ticks?.display}\n />\n <label for=\"x-axes0-ticks-display\"> <ox-i18n msgid=\"label.display-tick\">Display Tick</ox-i18n> </label>\n\n <legend><ox-i18n msgid=\"label.x-axes\">X Axes</ox-i18n></legend>\n\n <label for=\"x-axes0-axis-title\"> <ox-i18n msgid=\"label.title\">Title</ox-i18n> </label>\n <input\n id=\"x-axes0-axis-title\"\n type=\"text\"\n value-key=\"xAxes0.axisTitle\"\n .value=${configurer.xAxes0.axisTitle || ''}\n />\n\n <input\n id=\"x-axes0-axis-min-auto\"\n type=\"checkbox\"\n value-key=\"xAxes0.ticks.autoMin\"\n ?checked=${configurer.xAxes0.ticks?.autoMin}\n />\n <label for=\"x-axes0-axis-min-auto\"> <ox-i18n msgid=\"label.axis-min-auto\">Axis Min Auto</ox-i18n> </label>\n\n <input\n id=\"x-axes0-ticks-auto-max\"\n type=\"checkbox\"\n value-key=\"xAxes0.ticks.autoMax\"\n ?checked=${configurer.xAxes0.ticks?.autoMax}\n />\n <label for=\"x-axes0-ticks-auto-max\"> <ox-i18n msgid=\"label.axis-max-auto\">Axis Max Auto</ox-i18n> </label>\n\n ${!configurer.xAxes0.ticks?.autoMin\n ? html`\n <label for=\"x-axes0-ticks-min\"> <ox-i18n msgid=\"label.axis-min\">Axis Min</ox-i18n> </label>\n <input\n id=\"x-axes0-ticks-min\"\n type=\"number\"\n value-key=\"xAxes0.ticks.min\"\n value=${ifDefined(configurer.xAxes0.ticks?.min)}\n />\n `\n : html``}\n ${!configurer.xAxes0.ticks?.autoMax\n ? html`\n <label for=\"x-axes0-ticks-max\"> <ox-i18n msgid=\"label.axis-max\">Axis Max</ox-i18n> </label>\n <input\n id=\"x-axes0-ticks-max\"\n type=\"number\"\n value-key=\"xAxes0.ticks.max\"\n value=${ifDefined(configurer.xAxes0.ticks?.max)}\n />\n `\n : html``}\n\n <label for=\"y-axes0-ticks-step-size\"> <ox-i18n msgid=\"label.axis-step-size\">Axis Step Size</ox-i18n> </label>\n <input\n id=\"y-axes0-ticks-step-size\"\n type=\"number\"\n value-key=\"yAxes0.ticks.stepSize\"\n value=${ifDefined(configurer.yAxes0.ticks?.stepSize)}\n />\n\n <input\n id=\"y-grid-line\"\n type=\"checkbox\"\n value-key=\"value.options.yGridLine\"\n ?checked=${configurer.config.options?.yGridLine}\n />\n <label for=\"y-grid-line\"> <ox-i18n msgid=\"label.grid-line\">Grid Line</ox-i18n> </label>\n\n <input\n id=\"y-axes0-ticks-display\"\n type=\"checkbox\"\n value-key=\"yAxes0.ticks.display\"\n ?checked=${configurer.yAxes0.ticks?.display}\n />\n <label for=\"y-axes0-ticks-display\"> <ox-i18n msgid=\"label.display-tick\">Display Tick</ox-i18n> </label>\n `\n }\n\n multiSeriesTabTemplate() {\n const configurer = this.configurer\n\n return html`\n <div id=\"series-properties-container\" fullwidth>\n <div id=\"series-tab-header\">\n <md-icon\n id=\"series-tab-nav-left-button\"\n @tap=${(e: Event) => {\n this._onTabScrollNavLeft(e, 'series')\n }}\n disabled\n >chevron_left</md-icon\n >\n <div\n id=\"series-tabs\"\n @change=${(e: Event) => {\n configurer.currentSeriesIndex = (e.target as any).activeTabIndex\n }}\n active-tab-index=${configurer.currentSeriesIndex}\n fit-container\n >\n ${configurer.datasets.map(\n (dataset: any, index: number) => html`\n <div\n data-series=${index + 1}\n data-tab-index=${index}\n tab\n ?selected=${index == configurer.currentSeriesIndex}\n @click=${(e: Event) => {\n const target = e.target as HTMLDivElement\n this.configurer.setCurrentSeriesIndex(Number(target.getAttribute('data-tab-index')))\n this.value = { ...this.configurer.value }\n }}\n >\n ${index + 1}\n ${!configurer.datasets || (configurer.datasets.length != 1 && configurer.currentSeriesIndex == index)\n ? html` <md-icon @tap=${(e: Event) => this.onTapRemoveCurrentSeriesTab(index)}> close </md-icon> `\n : html``}\n </div>\n `\n )}\n </div>\n <md-icon\n id=\"series-tab-nav-right-button\"\n @click=${(e: Event) => {\n this._onTabScrollNavRight(e, 'series')\n }}\n disabled\n >chevron_right</md-icon\n >\n </div>\n <div id=\"add-series-button-container\">\n <md-icon id=\"add-series-button\" @tap=${(e: Event) => this.onTapAddSeriesTab(e)}>add</md-icon>\n </div>\n\n <div class=\"tab-content\">\n <label for=\"data-key\"> <ox-i18n msgid=\"label.data-key\">Data Key</ox-i18n> </label>\n <input id=\"data-key\" type=\"text\" value-key=\"dataKey\" .value=${configurer.dataKey || ''} />\n <label for=\"series-label\"> <ox-i18n msgid=\"label.label\">Label</ox-i18n> </label>\n <input id=\"series-label\" type=\"text\" value-key=\"series.label\" .value=${configurer.series.label || ''} />\n <label for=\"series-color\"> <ox-i18n msgid=\"label.color\">Color</ox-i18n> </label>\n <ox-input-color id=\"series-color\" value-key=\"color\" .value=${configurer.color || '#000'}></ox-input-color>\n <label for=\"series-stack\"> <ox-i18n msgid=\"label.stack-group\">Stack Group</ox-i18n> </label>\n <input id=\"series-stack\" type=\"text\" value-key=\"series.stack\" .value=${configurer.series.stack || ''} />\n\n ${this.displayValueTemplate()}\n </div>\n </div>\n `\n }\n\n getDefaultDatasets(): OperatoChart.Dataset[] {\n return [this.getDefaultDataset('horizontalBar')]\n }\n}\n"]}
|
|
1
|
+
{"version":3,"file":"ox-input-chart-hbar.js","sourceRoot":"","sources":["../../../src/editors/ox-input-chart-hbar.ts"],"names":[],"mappings":";AAAA,OAAO,4BAA4B,CAAA;AACnC,OAAO,kCAAkC,CAAA;AACzC,OAAO,0BAA0B,CAAA;AAEjC,OAAO,EAAE,IAAI,EAAE,MAAM,KAAK,CAAA;AAC1B,OAAO,EAAE,aAAa,EAAE,MAAM,mBAAmB,CAAA;AACjD,OAAO,EAAE,SAAS,EAAE,MAAM,8BAA8B,CAAA;AAExD,OAAO,EAAE,kBAAkB,EAAE,MAAM,wBAAwB,CAAA;AAE3D,OAAO,2BAA2B,CAAA;AAG3B,IAAM,gBAAgB,GAAtB,MAAM,gBAAiB,SAAQ,kBAAkB;aAC/C,WAAM,GAAG,kBAAkB,CAAC,MAAM,AAA5B,CAA4B;IAEzC,WAAW;QACT,MAAM,UAAU,GAAG,IAAI,CAAC,UAAU,CAAA;QAElC,OAAO,IAAI,CAAA;;qCAEsB,UAAU,eAAe,IAAI,CAAC,SAAS;;;;;8EAKE,SAAS,CAAC,UAAU,CAAC,YAAY,CAAC;;;;;;;gBAOhG,SAAS,CAAC,UAAU,CAAC,MAAM,CAAC,SAAS,CAAC;;;;;;;;;;;gBAWtC,SAAS,CAAC,UAAU,CAAC,MAAM,CAAC,UAAU,CAAC;;;;;;;;;;gBAU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lit'\nimport { customElement } from 'lit/decorators.js'\nimport { ifDefined } from 'lit/directives/if-defined.js'\n\nimport { InputChartAbstract } from './input-chart-abstract'\n\nimport './templates/display-value'\n\n@customElement('ox-input-chart-hbar')\nexport class OxInputChartHBar extends InputChartAbstract {\n static styles = InputChartAbstract.styles\n\n subTemplate() {\n const configurer = this.configurer\n\n return html`\n <legend><ox-i18n msgid=\"label.series\">Series</ox-i18n></legend>\n <ox-chart-series .configurer=${configurer} .chartType=${this.chartType} fullwidth></ox-chart-series>\n\n <legend><ox-i18n msgid=\"label.y-axes\">Y Axes</ox-i18n></legend>\n\n <label for=\"label-data-key\"> <ox-i18n msgid=\"label.data-key\">Data Key</ox-i18n> </label>\n <input id=\"label-data-key\" type=\"text\" value-key=\"labelDataKey\" value=${ifDefined(configurer.labelDataKey)} />\n\n <label for=\"y-axes0-axis-title\"> <ox-i18n msgid=\"label.title\">Title</ox-i18n> </label>\n <input\n id=\"y-axes0-axis-title\"\n type=\"text\"\n value-key=\"yAxes0.axisTitle\"\n value=${ifDefined(configurer.yAxes0.axisTitle)}\n />\n\n <label for=\"y-axes0-bar-spacing\"><ox-i18n msgid=\"label.bar-spacing\">Bar Spacing</ox-i18n></label>\n <input\n id=\"y-axes0-bar-spacing\"\n type=\"number\"\n min=\"0\"\n max=\"1\"\n step=\"0.1\"\n value-key=\"yAxes0.barSpacing\"\n value=${ifDefined(configurer.yAxes0.barSpacing)}\n />\n <label for=\"y-axes0-category-spacing\"><ox-i18n msgid=\"label.tick-spacing\">Tick Spacing</ox-i18n></label>\n <input\n id=\"y-axes0-category-spacing\"\n type=\"number\"\n min=\"0\"\n max=\"1\"\n step=\"0.1\"\n value-key=\"yAxes0.categorySpacing\"\n value=${ifDefined(configurer.yAxes0.categorySpacing)}\n />\n\n <input\n id=\"x-grid-line\"\n type=\"checkbox\"\n value-key=\"value.options.xGridLine\"\n ?checked=${configurer.config.options?.xGridLine}\n />\n <label for=\"x-grid-line\"> <ox-i18n msgid=\"label.grid-line\">Grid Line</ox-i18n> </label>\n\n <input\n id=\"x-axes0-ticks-display\"\n type=\"checkbox\"\n value-key=\"xAxes0.ticks.display\"\n ?checked=${configurer.xAxes0.ticks?.display}\n />\n <label for=\"x-axes0-ticks-display\"> <ox-i18n msgid=\"label.display-tick\">Display Tick</ox-i18n> </label>\n\n <legend><ox-i18n msgid=\"label.x-axes\">X Axes</ox-i18n></legend>\n\n <label for=\"x-axes0-axis-title\"> <ox-i18n msgid=\"label.title\">Title</ox-i18n> </label>\n <input\n id=\"x-axes0-axis-title\"\n type=\"text\"\n value-key=\"xAxes0.axisTitle\"\n .value=${configurer.xAxes0.axisTitle || ''}\n />\n\n <input\n id=\"x-axes0-axis-min-auto\"\n type=\"checkbox\"\n value-key=\"xAxes0.ticks.autoMin\"\n ?checked=${configurer.xAxes0.ticks?.autoMin}\n />\n <label for=\"x-axes0-axis-min-auto\"> <ox-i18n msgid=\"label.axis-min-auto\">Axis Min Auto</ox-i18n> </label>\n\n <input\n id=\"x-axes0-ticks-auto-max\"\n type=\"checkbox\"\n value-key=\"xAxes0.ticks.autoMax\"\n ?checked=${configurer.xAxes0.ticks?.autoMax}\n />\n <label for=\"x-axes0-ticks-auto-max\"> <ox-i18n msgid=\"label.axis-max-auto\">Axis Max Auto</ox-i18n> </label>\n\n ${!configurer.xAxes0.ticks?.autoMin\n ? html`\n <label for=\"x-axes0-ticks-min\"> <ox-i18n msgid=\"label.axis-min\">Axis Min</ox-i18n> </label>\n <input\n id=\"x-axes0-ticks-min\"\n type=\"number\"\n value-key=\"xAxes0.ticks.min\"\n value=${ifDefined(configurer.xAxes0.ticks?.min)}\n />\n `\n : html``}\n ${!configurer.xAxes0.ticks?.autoMax\n ? html`\n <label for=\"x-axes0-ticks-max\"> <ox-i18n msgid=\"label.axis-max\">Axis Max</ox-i18n> </label>\n <input\n id=\"x-axes0-ticks-max\"\n type=\"number\"\n value-key=\"xAxes0.ticks.max\"\n value=${ifDefined(configurer.xAxes0.ticks?.max)}\n />\n `\n : html``}\n\n <label for=\"y-axes0-ticks-step-size\"> <ox-i18n msgid=\"label.axis-step-size\">Axis Step Size</ox-i18n> </label>\n <input\n id=\"y-axes0-ticks-step-size\"\n type=\"number\"\n value-key=\"yAxes0.ticks.stepSize\"\n value=${ifDefined(configurer.yAxes0.ticks?.stepSize)}\n />\n\n <input\n id=\"y-grid-line\"\n type=\"checkbox\"\n value-key=\"value.options.yGridLine\"\n ?checked=${configurer.config.options?.yGridLine}\n />\n <label for=\"y-grid-line\"> <ox-i18n msgid=\"label.grid-line\">Grid Line</ox-i18n> </label>\n\n <input\n id=\"y-axes0-ticks-display\"\n type=\"checkbox\"\n value-key=\"yAxes0.ticks.display\"\n ?checked=${configurer.yAxes0.ticks?.display}\n />\n <label for=\"y-axes0-ticks-display\"> <ox-i18n msgid=\"label.display-tick\">Display Tick</ox-i18n> </label>\n `\n }\n\n getDefaultDatasets(): OperatoChart.Dataset[] {\n return [this.getDefaultDataset('horizontalBar')]\n }\n}\n"]}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import '@operato/i18n/ox-i18n.js';
|
|
2
2
|
import { InputChartAbstract } from './input-chart-abstract';
|
|
3
|
+
import './templates/series';
|
|
3
4
|
export declare class OxInputChartMixed extends InputChartAbstract {
|
|
4
5
|
static styles: import("lit").CSSResult[];
|
|
5
6
|
subTemplate(): import("lit-html").TemplateResult<1>;
|
|
@@ -4,6 +4,7 @@ import { html } from 'lit';
|
|
|
4
4
|
import { customElement } from 'lit/decorators.js';
|
|
5
5
|
import { ifDefined } from 'lit/directives/if-defined.js';
|
|
6
6
|
import { InputChartAbstract } from './input-chart-abstract';
|
|
7
|
+
import './templates/series';
|
|
7
8
|
let OxInputChartMixed = class OxInputChartMixed extends InputChartAbstract {
|
|
8
9
|
static { this.styles = InputChartAbstract.styles; }
|
|
9
10
|
subTemplate() {
|
|
@@ -13,8 +14,7 @@ let OxInputChartMixed = class OxInputChartMixed extends InputChartAbstract {
|
|
|
13
14
|
<label for="multi-axis"> <ox-i18n msgid="label.multi-axis">Multi Axis</ox-i18n> </label>
|
|
14
15
|
|
|
15
16
|
<legend><ox-i18n msgid="label.series">Series</ox-i18n></legend>
|
|
16
|
-
|
|
17
|
-
<div fullwidth>${this.multiSeriesTabTemplate()}</div>
|
|
17
|
+
<ox-chart-series .configurer=${configurer} .chartType=${this.chartType} fullwidth></ox-chart-series>
|
|
18
18
|
|
|
19
19
|
<legend><ox-i18n msgid="label.x-axes">X Axes</ox-i18n></legend>
|
|
20
20
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ox-input-chart-mixed.js","sourceRoot":"","sources":["../../../src/editors/ox-input-chart-mixed.ts"],"names":[],"mappings":";AAAA,OAAO,0BAA0B,CAAA;AAEjC,OAAO,EAAE,IAAI,EAAE,MAAM,KAAK,CAAA;AAC1B,OAAO,EAAE,aAAa,EAAE,MAAM,mBAAmB,CAAA;AACjD,OAAO,EAAE,SAAS,EAAE,MAAM,8BAA8B,CAAA;AAExD,OAAO,EAAE,kBAAkB,EAAE,MAAM,wBAAwB,CAAA;AAGpD,IAAM,iBAAiB,GAAvB,MAAM,iBAAkB,SAAQ,kBAAkB;aAChD,WAAM,GAAG,kBAAkB,CAAC,MAAM,AAA5B,CAA4B;IAEzC,WAAW;QACT,MAAM,UAAU,GAAG,IAAI,CAAC,UAAU,CAAA;QAElC,OAAO,IAAI,CAAA;8EAC+D,UAAU,CAAC,SAAS;;;;;uBAK3E,IAAI,CAAC,sBAAsB,EAAE;;;;;+EAK2B,SAAS,CAAC,UAAU,CAAC,YAAY,CAAC;;;;;;;gBAOjG,SAAS,CAAC,UAAU,CAAC,MAAM,CAAC,SAAS,CAAC;;;QAG9C,IAAI,CAAC,aAAa,CAAC,UAAU,CAAC,KAAK,CAAC;YACpC,CAAC,CAAC,IAAI,CAAA;;;;;;;;;sBASQ,SAAS,CAAC,UAAU,CAAC,MAAM,CAAC,UAAU,CAAC;;;;;;;;;;sBAUvC,SAAS,CAAC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AAO;;;;cAI5C,CAAC,UAAU,CAAC,MAAM,EAAE,KAAK,EAAE,OAAO;gBAClC,CAAC,CAAC,IAAI,CAAA;;;;;;4BAMQ,SAAS,CAAC,UAAU,CAAC,MAAM,EAAE,KAAK,EAAE,GAAG,CAAC;;iBAEnD;gBACH,CAAC,CAAC,IAAI,CAAA,EAAE;cACR,CAAC,UAAU,CAAC,MAAM,EAAE,KAAK,EAAE,OAAO;gBAClC,CAAC,CAAC,IAAI,CAAA;;;;;;4BAMQ,SAAS,CAAC,UAAU,CAAC,MAAM,EAAE,KAAK,EAAE,GAAG,CAAC;;iBAEnD;gBACH,CAAC,CAAC,IAAI,CAAA,EAAE;;;;;;;sBAOA,SAAS,CAAC,UAAU,CAAC,MAAM,EAAE,KAAK,EAAE,QAAQ,CAAC;;;;;;;yBAO1C,UAAU,CAAC,MAAM,CAAC,OAAO,EAAE,YAAY;;;;;;;;yBAQvC,UAAU,CAAC,MAAM,EAAE,KAAK,EAAE,OAAO;;;WAG/C;YACH,CAAC,CAAC,IAAI,CAAA,EAAE;KACX,CAAA;IACH,CAAC;IAED,aAAa,CAAC,MAAW;QACvB,IAAI,YAAY,GAAG,KAAK,CAAA;QACxB,YAAY,GAAG,MAAM,CAAC,IAAI,CAAC,QAAQ,EAAE,IAAI,CAAC,CAAC,CAAM,EAAE,EAAE,CAAC,CAAC,CAAC,IAAI,IAAI,KAAK,CAAC,CAAA;QAEtE,OAAO,YAAY,CAAA;IACrB,CAAC;;AAjOU,iBAAiB;IAD7B,aAAa,CAAC,sBAAsB,CAAC;GACzB,iBAAiB,CAkO7B","sourcesContent":["import '@operato/i18n/ox-i18n.js'\n\nimport { html } from 'lit'\nimport { customElement } from 'lit/decorators.js'\nimport { ifDefined } from 'lit/directives/if-defined.js'\n\nimport { InputChartAbstract } from './input-chart-abstract'\n\n@customElement('ox-input-chart-mixed')\nexport class OxInputChartMixed extends InputChartAbstract {\n static styles = InputChartAbstract.styles\n\n subTemplate() {\n const configurer = this.configurer\n\n return html`\n <input id=\"multi-axis\" type=\"checkbox\" value-key=\"multiAxis\" ?checked=${configurer.multiAxis} />\n <label for=\"multi-axis\"> <ox-i18n msgid=\"label.multi-axis\">Multi Axis</ox-i18n> </label>\n\n <legend><ox-i18n msgid=\"label.series\">Series</ox-i18n></legend>\n\n <div fullwidth>${this.multiSeriesTabTemplate()}</div>\n\n <legend><ox-i18n msgid=\"label.x-axes\">X Axes</ox-i18n></legend>\n\n <label for=\"series-data-key\"> <ox-i18n msgid=\"label.data-key\">Data Key</ox-i18n> </label>\n <input id=\"series-data-key\" type=\"text\" value-key=\"labelDataKey\" value=${ifDefined(configurer.labelDataKey)} />\n\n <label for=\"x-axes0-axis-title\"> <ox-i18n msgid=\"label.title\">Title</ox-i18n> </label>\n <input\n id=\"x-axes0-axis-title\"\n type=\"text\"\n value-key=\"xAxes0.axisTitle\"\n value=${ifDefined(configurer.xAxes0.axisTitle)}\n />\n\n ${this._hasBarSeries(configurer.value)\n ? html`\n <label for=\"bar-spacing\"><ox-i18n msgid=\"label.bar-spacing\">Bar Spacing</ox-i18n></label>\n <input\n id=\"bar-spacing\"\n type=\"number\"\n min=\"0\"\n max=\"1\"\n step=\"0.1\"\n value-key=\"xAxes0.barSpacing\"\n value=${ifDefined(configurer.xAxes0.barSpacing)}\n />\n <label for=\"tick-spacing\"><ox-i18n msgid=\"label.tick-spacing\">Tick Spacing</ox-i18n></label>\n <input\n id=\"tick-spacing\"\n type=\"number\"\n min=\"0\"\n max=\"1\"\n step=\"0.1\"\n value-key=\"xAxes0.categorySpacing\"\n value=${ifDefined(configurer.xAxes0.categorySpacing)}\n />\n `\n : html``}\n\n <input\n id=\"x-grid-line\"\n type=\"checkbox\"\n value-key=\"value.options.xGridLine\"\n ?checked=${configurer.config.options?.xGridLine}\n />\n <label for=\"x-grid-line\"> <ox-i18n msgid=\"label.grid-line\">Grid Line</ox-i18n> </label>\n\n <input\n id=\"x-axes0-ticks-display\"\n type=\"checkbox\"\n value-key=\"xAxes0.ticks.display\"\n ?checked=${configurer.xAxes0.ticks?.display}\n />\n <label for=\"x-axes0-ticks-display\"> <ox-i18n msgid=\"label.display-tick\">Display Tick</ox-i18n> </label>\n\n <legend><ox-i18n msgid=\"label.y-axes\">Y Axes</ox-i18n></legend>\n\n <label for=\"y-axes0-axis-title\"> <ox-i18n msgid=\"label.title\">Title</ox-i18n> </label>\n <input\n id=\"y-axes0-axis-title\"\n type=\"text\"\n value-key=\"yAxes0.axisTitle\"\n value=${configurer.yAxes0.axisTitle || ''}\n />\n\n <input\n id=\"axis-min-auto\"\n type=\"checkbox\"\n value-key=\"yAxes0.ticks.autoMin\"\n ?checked=${configurer.yAxes0.ticks?.autoMin}\n />\n <label for=\"axis-min-auto\"> <ox-i18n msgid=\"label.axis-min-auto\">Min Auto</ox-i18n> </label>\n\n <input\n id=\"axis-max-auto\"\n type=\"checkbox\"\n value-key=\"yAxes0.ticks.autoMax\"\n ?checked=${configurer.yAxes0.ticks?.autoMax}\n />\n <label for=\"axis-max-auto\"> <ox-i18n msgid=\"label.axis-max-auto\">Max Auto</ox-i18n> </label>\n\n ${!configurer.yAxes0.ticks?.autoMin\n ? html`\n <label for=\"y-axes0-ticks-min\"> <ox-i18n msgid=\"label.axis-min\">Min</ox-i18n> </label>\n <input\n id=\"y-axes0-ticks-min\"\n type=\"number\"\n value-key=\"yAxes0.ticks.min\"\n value=${ifDefined(configurer.yAxes0.ticks?.min)}\n />\n `\n : html``}\n ${!configurer.yAxes0.ticks?.autoMax\n ? html`\n <label for=\"y-axes0-ticks-max\"> <ox-i18n msgid=\"label.axis-max\">Max</ox-i18n> </label>\n <input\n id=\"y-axes0-ticks-max\"\n type=\"number\"\n value-key=\"yAxes0.ticks.max\"\n value=${ifDefined(configurer.yAxes0.ticks?.max)}\n />\n `\n : html``}\n\n <label for=\"y-axes0-ticks-step-size\"> <ox-i18n msgid=\"label.axis-step-size\">StepSize</ox-i18n> </label>\n <input\n id=\"y-axes0-ticks-step-size\"\n type=\"number\"\n value-key=\"yAxes0.ticks.stepSize\"\n value=${ifDefined(configurer.yAxes0.ticks?.stepSize)}\n />\n\n <input\n id=\"y-grid-line\"\n type=\"checkbox\"\n value-key=\"value.options.yGridLine\"\n ?checked=${configurer.config.options?.yGridLine}\n />\n <label for=\"y-grid-line\"> <ox-i18n msgid=\"label.grid-line\">Grid Line</ox-i18n> </label>\n\n <input\n id=\"y-axes0-ticks-display\"\n type=\"checkbox\"\n value-key=\"yAxes0.ticks.display\"\n ?checked=${configurer.yAxes0.ticks?.display}\n />\n <label for=\"y-axes0-ticks-display\"> <ox-i18n msgid=\"label.display-tick\">Display Tick</ox-i18n> </label>\n\n ${configurer.config.options?.multiAxis\n ? html`\n <legend><ox-i18n msgid=\"label.y-2nd-axes\">Y 2nd Axes</ox-i18n></legend>\n\n <label for=\"y-axes1.axis-title\"> <ox-i18n msgid=\"label.title\">Title</ox-i18n> </label>\n <input\n id=\"y-axes1.axis-title\"\n type=\"text\"\n value-key=\"yAxes1.axisTitle\"\n value=${ifDefined(configurer.yAxes1?.axisTitle)}\n />\n\n <input\n id=\"y-axes1-ticks-auto-min\"\n type=\"checkbox\"\n value-key=\"yAxes1.ticks.autoMin\"\n ?checked=${configurer.yAxes1?.ticks?.autoMin}\n />\n <label for=\"y-axes1-ticks-auto-min\"> <ox-i18n msgid=\"label.axis-min-auto\">Min Auto</ox-i18n> </label>\n\n <input\n id=\"y-axes1-ticks-auto-max\"\n type=\"checkbox\"\n value-key=\"yAxes1.ticks.autoMax\"\n ?checked=${configurer.yAxes1?.ticks?.autoMax}\n />\n <label for=\"y-axes1-ticks-auto-max\"> <ox-i18n msgid=\"label.axis-max-auto\">Max Auto</ox-i18n> </label>\n\n ${!configurer.yAxes1?.ticks?.autoMin\n ? html`\n <label for=\"y-axes1-ticks-min\"> <ox-i18n msgid=\"label.axis-min\">Min</ox-i18n> </label>\n <input\n id=\"y-axes1-ticks-min\"\n type=\"number\"\n value-key=\"yAxes1.ticks.min\"\n value=${ifDefined(configurer.yAxes1?.ticks?.min)}\n />\n `\n : html``}\n ${!configurer.yAxes1?.ticks?.autoMax\n ? html`\n <label for=\"y-axes1-ticks-max\"> <ox-i18n msgid=\"label.axis-max\">Max</ox-i18n> </label>\n <input\n id=\"y-axes1-ticks-max\"\n type=\"number\"\n value-key=\"yAxes1.ticks.max\"\n value=${ifDefined(configurer.yAxes1?.ticks?.max)}\n />\n `\n : html``}\n\n <label for=\"y-axes1-ticks-step-size\"> <ox-i18n msgid=\"label.axis-step-size\">StepSize</ox-i18n> </label>\n <input\n id=\"y-axes1-ticks-step-size\"\n type=\"number\"\n value-key=\"yAxes1.ticks.stepSize\"\n value=${ifDefined(configurer.yAxes1?.ticks?.stepSize)}\n />\n\n <input\n id=\"y-2nd-grid-line\"\n type=\"checkbox\"\n value-key=\"value.options.y2ndGridLine\"\n ?checked=${configurer.config.options?.y2ndGridLine}\n />\n <label for=\"y-2nd-grid-line\"> <ox-i18n msgid=\"label.grid-line\">Grid Line</ox-i18n> </label>\n\n <input\n id=\"y-axes1-ticks-display\"\n type=\"checkbox\"\n value-key=\"yAxes1.ticks.display\"\n ?checked=${configurer.yAxes1?.ticks?.display}\n />\n <label for=\"y-axes1-ticks-display\"> <ox-i18n msgid=\"label.display-tick\">Display Tick</ox-i18n> </label>\n `\n : html``}\n `\n }\n\n _hasBarSeries(config: any) {\n var hasBarSeries = false\n hasBarSeries = config.data.datasets?.some((s: any) => s.type == 'bar')\n\n return hasBarSeries\n }\n}\n"]}
|
|
1
|
+
{"version":3,"file":"ox-input-chart-mixed.js","sourceRoot":"","sources":["../../../src/editors/ox-input-chart-mixed.ts"],"names":[],"mappings":";AAAA,OAAO,0BAA0B,CAAA;AAEjC,OAAO,EAAE,IAAI,EAAE,MAAM,KAAK,CAAA;AAC1B,OAAO,EAAE,aAAa,EAAE,MAAM,mBAAmB,CAAA;AACjD,OAAO,EAAE,SAAS,EAAE,MAAM,8BAA8B,CAAA;AAExD,OAAO,EAAE,kBAAkB,EAAE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ACH,CAAC,CAAC,IAAI,CAAA,EAAE;KACX,CAAA;IACH,CAAC;IAED,aAAa,CAAC,MAAW;QACvB,IAAI,YAAY,GAAG,KAAK,CAAA;QACxB,YAAY,GAAG,MAAM,CAAC,IAAI,CAAC,QAAQ,EAAE,IAAI,CAAC,CAAC,CAAM,EAAE,EAAE,CAAC,CAAC,CAAC,IAAI,IAAI,KAAK,CAAC,CAAA;QAEtE,OAAO,YAAY,CAAA;IACrB,CAAC;;AAhOU,iBAAiB;IAD7B,aAAa,CAAC,sBAAsB,CAAC;GACzB,iBAAiB,CAiO7B","sourcesContent":["import '@operato/i18n/ox-i18n.js'\n\nimport { html } from 'lit'\nimport { customElement } from 'lit/decorators.js'\nimport { ifDefined } from 'lit/directives/if-defined.js'\n\nimport { InputChartAbstract } from './input-chart-abstract'\nimport './templates/series'\n\n@customElement('ox-input-chart-mixed')\nexport class OxInputChartMixed extends InputChartAbstract {\n static styles = InputChartAbstract.styles\n\n subTemplate() {\n const configurer = this.configurer\n\n return html`\n <input id=\"multi-axis\" type=\"checkbox\" value-key=\"multiAxis\" ?checked=${configurer.multiAxis} />\n <label for=\"multi-axis\"> <ox-i18n msgid=\"label.multi-axis\">Multi Axis</ox-i18n> </label>\n\n <legend><ox-i18n msgid=\"label.series\">Series</ox-i18n></legend>\n <ox-chart-series .configurer=${configurer} .chartType=${this.chartType} fullwidth></ox-chart-series>\n\n <legend><ox-i18n msgid=\"label.x-axes\">X Axes</ox-i18n></legend>\n\n <label for=\"series-data-key\"> <ox-i18n msgid=\"label.data-key\">Data Key</ox-i18n> </label>\n <input id=\"series-data-key\" type=\"text\" value-key=\"labelDataKey\" value=${ifDefined(configurer.labelDataKey)} />\n\n <label for=\"x-axes0-axis-title\"> <ox-i18n msgid=\"label.title\">Title</ox-i18n> </label>\n <input\n id=\"x-axes0-axis-title\"\n type=\"text\"\n value-key=\"xAxes0.axisTitle\"\n value=${ifDefined(configurer.xAxes0.axisTitle)}\n />\n\n ${this._hasBarSeries(configurer.value)\n ? html`\n <label for=\"bar-spacing\"><ox-i18n msgid=\"label.bar-spacing\">Bar Spacing</ox-i18n></label>\n <input\n id=\"bar-spacing\"\n type=\"number\"\n min=\"0\"\n max=\"1\"\n step=\"0.1\"\n value-key=\"xAxes0.barSpacing\"\n value=${ifDefined(configurer.xAxes0.barSpacing)}\n />\n <label for=\"tick-spacing\"><ox-i18n msgid=\"label.tick-spacing\">Tick Spacing</ox-i18n></label>\n <input\n id=\"tick-spacing\"\n type=\"number\"\n min=\"0\"\n max=\"1\"\n step=\"0.1\"\n value-key=\"xAxes0.categorySpacing\"\n value=${ifDefined(configurer.xAxes0.categorySpacing)}\n />\n `\n : html``}\n\n <input\n id=\"x-grid-line\"\n type=\"checkbox\"\n value-key=\"value.options.xGridLine\"\n ?checked=${configurer.config.options?.xGridLine}\n />\n <label for=\"x-grid-line\"> <ox-i18n msgid=\"label.grid-line\">Grid Line</ox-i18n> </label>\n\n <input\n id=\"x-axes0-ticks-display\"\n type=\"checkbox\"\n value-key=\"xAxes0.ticks.display\"\n ?checked=${configurer.xAxes0.ticks?.display}\n />\n <label for=\"x-axes0-ticks-display\"> <ox-i18n msgid=\"label.display-tick\">Display Tick</ox-i18n> </label>\n\n <legend><ox-i18n msgid=\"label.y-axes\">Y Axes</ox-i18n></legend>\n\n <label for=\"y-axes0-axis-title\"> <ox-i18n msgid=\"label.title\">Title</ox-i18n> </label>\n <input\n id=\"y-axes0-axis-title\"\n type=\"text\"\n value-key=\"yAxes0.axisTitle\"\n value=${configurer.yAxes0.axisTitle || ''}\n />\n\n <input\n id=\"axis-min-auto\"\n type=\"checkbox\"\n value-key=\"yAxes0.ticks.autoMin\"\n ?checked=${configurer.yAxes0.ticks?.autoMin}\n />\n <label for=\"axis-min-auto\"> <ox-i18n msgid=\"label.axis-min-auto\">Min Auto</ox-i18n> </label>\n\n <input\n id=\"axis-max-auto\"\n type=\"checkbox\"\n value-key=\"yAxes0.ticks.autoMax\"\n ?checked=${configurer.yAxes0.ticks?.autoMax}\n />\n <label for=\"axis-max-auto\"> <ox-i18n msgid=\"label.axis-max-auto\">Max Auto</ox-i18n> </label>\n\n ${!configurer.yAxes0.ticks?.autoMin\n ? html`\n <label for=\"y-axes0-ticks-min\"> <ox-i18n msgid=\"label.axis-min\">Min</ox-i18n> </label>\n <input\n id=\"y-axes0-ticks-min\"\n type=\"number\"\n value-key=\"yAxes0.ticks.min\"\n value=${ifDefined(configurer.yAxes0.ticks?.min)}\n />\n `\n : html``}\n ${!configurer.yAxes0.ticks?.autoMax\n ? html`\n <label for=\"y-axes0-ticks-max\"> <ox-i18n msgid=\"label.axis-max\">Max</ox-i18n> </label>\n <input\n id=\"y-axes0-ticks-max\"\n type=\"number\"\n value-key=\"yAxes0.ticks.max\"\n value=${ifDefined(configurer.yAxes0.ticks?.max)}\n />\n `\n : html``}\n\n <label for=\"y-axes0-ticks-step-size\"> <ox-i18n msgid=\"label.axis-step-size\">StepSize</ox-i18n> </label>\n <input\n id=\"y-axes0-ticks-step-size\"\n type=\"number\"\n value-key=\"yAxes0.ticks.stepSize\"\n value=${ifDefined(configurer.yAxes0.ticks?.stepSize)}\n />\n\n <input\n id=\"y-grid-line\"\n type=\"checkbox\"\n value-key=\"value.options.yGridLine\"\n ?checked=${configurer.config.options?.yGridLine}\n />\n <label for=\"y-grid-line\"> <ox-i18n msgid=\"label.grid-line\">Grid Line</ox-i18n> </label>\n\n <input\n id=\"y-axes0-ticks-display\"\n type=\"checkbox\"\n value-key=\"yAxes0.ticks.display\"\n ?checked=${configurer.yAxes0.ticks?.display}\n />\n <label for=\"y-axes0-ticks-display\"> <ox-i18n msgid=\"label.display-tick\">Display Tick</ox-i18n> </label>\n\n ${configurer.config.options?.multiAxis\n ? html`\n <legend><ox-i18n msgid=\"label.y-2nd-axes\">Y 2nd Axes</ox-i18n></legend>\n\n <label for=\"y-axes1.axis-title\"> <ox-i18n msgid=\"label.title\">Title</ox-i18n> </label>\n <input\n id=\"y-axes1.axis-title\"\n type=\"text\"\n value-key=\"yAxes1.axisTitle\"\n value=${ifDefined(configurer.yAxes1?.axisTitle)}\n />\n\n <input\n id=\"y-axes1-ticks-auto-min\"\n type=\"checkbox\"\n value-key=\"yAxes1.ticks.autoMin\"\n ?checked=${configurer.yAxes1?.ticks?.autoMin}\n />\n <label for=\"y-axes1-ticks-auto-min\"> <ox-i18n msgid=\"label.axis-min-auto\">Min Auto</ox-i18n> </label>\n\n <input\n id=\"y-axes1-ticks-auto-max\"\n type=\"checkbox\"\n value-key=\"yAxes1.ticks.autoMax\"\n ?checked=${configurer.yAxes1?.ticks?.autoMax}\n />\n <label for=\"y-axes1-ticks-auto-max\"> <ox-i18n msgid=\"label.axis-max-auto\">Max Auto</ox-i18n> </label>\n\n ${!configurer.yAxes1?.ticks?.autoMin\n ? html`\n <label for=\"y-axes1-ticks-min\"> <ox-i18n msgid=\"label.axis-min\">Min</ox-i18n> </label>\n <input\n id=\"y-axes1-ticks-min\"\n type=\"number\"\n value-key=\"yAxes1.ticks.min\"\n value=${ifDefined(configurer.yAxes1?.ticks?.min)}\n />\n `\n : html``}\n ${!configurer.yAxes1?.ticks?.autoMax\n ? html`\n <label for=\"y-axes1-ticks-max\"> <ox-i18n msgid=\"label.axis-max\">Max</ox-i18n> </label>\n <input\n id=\"y-axes1-ticks-max\"\n type=\"number\"\n value-key=\"yAxes1.ticks.max\"\n value=${ifDefined(configurer.yAxes1?.ticks?.max)}\n />\n `\n : html``}\n\n <label for=\"y-axes1-ticks-step-size\"> <ox-i18n msgid=\"label.axis-step-size\">StepSize</ox-i18n> </label>\n <input\n id=\"y-axes1-ticks-step-size\"\n type=\"number\"\n value-key=\"yAxes1.ticks.stepSize\"\n value=${ifDefined(configurer.yAxes1?.ticks?.stepSize)}\n />\n\n <input\n id=\"y-2nd-grid-line\"\n type=\"checkbox\"\n value-key=\"value.options.y2ndGridLine\"\n ?checked=${configurer.config.options?.y2ndGridLine}\n />\n <label for=\"y-2nd-grid-line\"> <ox-i18n msgid=\"label.grid-line\">Grid Line</ox-i18n> </label>\n\n <input\n id=\"y-axes1-ticks-display\"\n type=\"checkbox\"\n value-key=\"yAxes1.ticks.display\"\n ?checked=${configurer.yAxes1?.ticks?.display}\n />\n <label for=\"y-axes1-ticks-display\"> <ox-i18n msgid=\"label.display-tick\">Display Tick</ox-i18n> </label>\n `\n : html``}\n `\n }\n\n _hasBarSeries(config: any) {\n var hasBarSeries = false\n hasBarSeries = config.data.datasets?.some((s: any) => s.type == 'bar')\n\n return hasBarSeries\n }\n}\n"]}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import '@operato/i18n/ox-i18n.js';
|
|
2
2
|
import '@operato/input/ox-input-multiple-colors.js';
|
|
3
3
|
import { InputChartAbstract } from './input-chart-abstract';
|
|
4
|
+
import './templates/display-value';
|
|
4
5
|
export default class OxInputChartPie extends InputChartAbstract {
|
|
5
6
|
static styles: import("lit").CSSResult[];
|
|
6
7
|
subTemplate(): import("lit-html").TemplateResult<1>;
|
|
@@ -4,6 +4,7 @@ import '@operato/input/ox-input-multiple-colors.js';
|
|
|
4
4
|
import { html } from 'lit';
|
|
5
5
|
import { customElement } from 'lit/decorators.js';
|
|
6
6
|
import { InputChartAbstract } from './input-chart-abstract';
|
|
7
|
+
import './templates/display-value';
|
|
7
8
|
let OxInputChartPie = class OxInputChartPie extends InputChartAbstract {
|
|
8
9
|
static { this.styles = InputChartAbstract.styles; }
|
|
9
10
|
subTemplate() {
|
|
@@ -21,7 +22,8 @@ let OxInputChartPie = class OxInputChartPie extends InputChartAbstract {
|
|
|
21
22
|
.value=${configurer.color || []}
|
|
22
23
|
></ox-input-multiple-colors>
|
|
23
24
|
|
|
24
|
-
|
|
25
|
+
<label></label>
|
|
26
|
+
<ox-chart-display-value .configurer=${configurer} fullwidth></ox-chart-display-value>
|
|
25
27
|
|
|
26
28
|
<legend><ox-i18n msgid="label.axes">Axes</ox-i18n></legend>
|
|
27
29
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ox-input-chart-pie.js","sourceRoot":"","sources":["../../../src/editors/ox-input-chart-pie.ts"],"names":[],"mappings":";AAAA,OAAO,0BAA0B,CAAA;AACjC,OAAO,4CAA4C,CAAA;AAEnD,OAAO,EAAE,IAAI,EAAE,MAAM,KAAK,CAAA;AAC1B,OAAO,EAAE,aAAa,EAAE,MAAM,mBAAmB,CAAA;
|
|
1
|
+
{"version":3,"file":"ox-input-chart-pie.js","sourceRoot":"","sources":["../../../src/editors/ox-input-chart-pie.ts"],"names":[],"mappings":";AAAA,OAAO,0BAA0B,CAAA;AACjC,OAAO,4CAA4C,CAAA;AAEnD,OAAO,EAAE,IAAI,EAAE,MAAM,KAAK,CAAA;AAC1B,OAAO,EAAE,aAAa,EAAE,MAAM,mBAAmB,CAAA;AAEjD,OAAO,EAAE,kBAAkB,EAAE,MAAM,wBAAwB,CAAA;AAC3D,OAAO,2BAA2B,CAAA;AAGnB,IAAM,eAAe,GAArB,MAAM,eAAgB,SAAQ,kBAAkB;aACtD,WAAM,GAAG,kBAAkB,CAAC,MAAM,AAA5B,CAA4B;IAEzC,WAAW;QACT,MAAM,UAAU,GAAG,IAAI,CAAC,UAAU,CAAA;QAElC,OAAO,IAAI,CAAA;;;;2EAI4D,UAAU,CAAC,MAAM,CAAC,OAAO,IAAI,EAAE;;;;;;iBAMzF,UAAU,CAAC,KAAK,IAAI,EAAE;;;;4CAIK,UAAU;;;;;gFAK0B,UAAU,CAAC,YAAY,IAAI,EAAE;KACxG,CAAA;IACH,CAAC;IAED,qBAAqB,CAAC,IAA4B,EAAE,QAAiC;QACnF,OAAO;YACL,IAAI,EAAE,KAAK;YACX,IAAI,EAAE;gBACJ,MAAM,EAAE,EAAE;gBACV,QAAQ,EAAE,IAAI,CAAC,kBAAkB,EAAE;gBACnC,YAAY,EAAE,OAAO;aACtB;YACD,OAAO,EAAE;gBACP,KAAK,EAAE,MAAM;gBACb,MAAM,EAAE;oBACN,OAAO,EAAE,IAAI;oBACb,QAAQ,EAAE,KAAK;iBAChB;aACF;SACF,CAAA;IACH,CAAC;IAED,kBAAkB;QAChB,OAAO,CAAC,IAAI,CAAC,iBAAiB,CAAC,KAAK,CAAC,CAAC,CAAA;IACxC,CAAC;IAED,iBAAiB,CAAC,UAAkC;QAClD,OAAO;YACL,eAAe,EAAE,CAAC,SAAS,EAAE,SAAS,EAAE,SAAS,CAAC;YAClD,WAAW,EAAE,CAAC;YACd,OAAO,EAAE,OAAO;SACjB,CAAA;IACH,CAAC;;AAzDkB,eAAe;IADnC,aAAa,CAAC,oBAAoB,CAAC;GACf,eAAe,CA0DnC;eA1DoB,eAAe","sourcesContent":["import '@operato/i18n/ox-i18n.js'\nimport '@operato/input/ox-input-multiple-colors.js'\n\nimport { html } from 'lit'\nimport { customElement } from 'lit/decorators.js'\n\nimport { InputChartAbstract } from './input-chart-abstract'\nimport './templates/display-value'\n\n@customElement('ox-input-chart-pie')\nexport default class OxInputChartPie extends InputChartAbstract {\n static styles = InputChartAbstract.styles\n\n subTemplate() {\n const configurer = this.configurer\n\n return html`\n <legend><ox-i18n msgid=\"label.series\">Series</ox-i18n></legend>\n\n <label for=\"series-data-key\"> <ox-i18n msgid=\"label.data-key\">Data Key</ox-i18n> </label>\n <input id=\"series-data-key\" type=\"text\" value-key=\"dataKey\" .value=${configurer.series.dataKey || ''} />\n\n <label for=\"series-colors\"> <ox-i18n msgid=\"label.color\">Color</ox-i18n> </label>\n <ox-input-multiple-colors\n id=\"series-colors\"\n value-key=\"color\"\n .value=${configurer.color || []}\n ></ox-input-multiple-colors>\n\n <label></label>\n <ox-chart-display-value .configurer=${configurer} fullwidth></ox-chart-display-value>\n\n <legend><ox-i18n msgid=\"label.axes\">Axes</ox-i18n></legend>\n\n <label for=\"series-data-key\"> <ox-i18n msgid=\"label.data-key\">Data Key</ox-i18n> </label>\n <input id=\"series-data-key\" type=\"text\" value-key=\"labelDataKey\" .value=${configurer.labelDataKey || ''} />\n `\n }\n\n getDefaultChartConfig(type: OperatoChart.ChartType, datasets?: OperatoChart.Dataset[]): OperatoChart.ChartConfig {\n return {\n type: 'pie',\n data: {\n labels: [],\n datasets: this.getDefaultDatasets(),\n labelDataKey: 'label'\n },\n options: {\n theme: 'dark',\n legend: {\n display: true,\n position: 'top'\n }\n }\n }\n }\n\n getDefaultDatasets(): OperatoChart.Dataset[] {\n return [this.getDefaultDataset('pie')]\n }\n\n getDefaultDataset(seriesType: OperatoChart.ChartType): OperatoChart.Dataset {\n return {\n backgroundColor: ['#FF6384', '#36A2EB', '#FFCE56'],\n borderWidth: 0,\n dataKey: 'value'\n }\n }\n}\n"]}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import '@operato/i18n/ox-i18n.js';
|
|
2
2
|
import { InputChartAbstract } from './input-chart-abstract';
|
|
3
|
+
import './templates/series';
|
|
3
4
|
export default class OxInputChartRadar extends InputChartAbstract {
|
|
4
5
|
static styles: import("lit").CSSResult[];
|
|
5
6
|
subTemplate(): import("lit-html").TemplateResult<1>;
|
|
@@ -4,14 +4,14 @@ import { html } from 'lit';
|
|
|
4
4
|
import { customElement } from 'lit/decorators.js';
|
|
5
5
|
import { ifDefined } from 'lit/directives/if-defined.js';
|
|
6
6
|
import { InputChartAbstract } from './input-chart-abstract';
|
|
7
|
+
import './templates/series';
|
|
7
8
|
let OxInputChartRadar = class OxInputChartRadar extends InputChartAbstract {
|
|
8
9
|
static { this.styles = InputChartAbstract.styles; }
|
|
9
10
|
subTemplate() {
|
|
10
11
|
const configurer = this.configurer;
|
|
11
12
|
return html `
|
|
12
13
|
<legend><ox-i18n msgid="label.series">Series</ox-i18n></legend>
|
|
13
|
-
|
|
14
|
-
<div fullwidth>${this.multiSeriesTabTemplate()}</div>
|
|
14
|
+
<ox-chart-series .configurer=${configurer} .chartType=${this.chartType} fullwidth></ox-chart-series>
|
|
15
15
|
|
|
16
16
|
<legend><ox-i18n msgid="label.axes">Axes</ox-i18n></legend>
|
|
17
17
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ox-input-chart-radar.js","sourceRoot":"","sources":["../../../src/editors/ox-input-chart-radar.ts"],"names":[],"mappings":";AAAA,OAAO,0BAA0B,CAAA;AAEjC,OAAO,EAAE,IAAI,EAAE,MAAM,KAAK,CAAA;AAC1B,OAAO,EAAE,aAAa,EAAE,MAAM,mBAAmB,CAAA;AACjD,OAAO,EAAE,SAAS,EAAE,MAAM,8BAA8B,CAAA;AAExD,OAAO,EAAE,kBAAkB,EAAE,MAAM,wBAAwB,CAAA;
|
|
1
|
+
{"version":3,"file":"ox-input-chart-radar.js","sourceRoot":"","sources":["../../../src/editors/ox-input-chart-radar.ts"],"names":[],"mappings":";AAAA,OAAO,0BAA0B,CAAA;AAEjC,OAAO,EAAE,IAAI,EAAE,MAAM,KAAK,CAAA;AAC1B,OAAO,EAAE,aAAa,EAAE,MAAM,mBAAmB,CAAA;AACjD,OAAO,EAAE,SAAS,EAAE,MAAM,8BAA8B,CAAA;AAExD,OAAO,EAAE,kBAAkB,EAAE,MAAM,wBAAwB,CAAA;AAE3D,OAAO,oBAAoB,CAAA;AAGZ,IAAM,iBAAiB,GAAvB,MAAM,iBAAkB,SAAQ,kBAAkB;aACxD,WAAM,GAAG,kBAAkB,CAAC,MAAM,AAA5B,CAA4B;IAEzC,WAAW;QACT,MAAM,UAAU,GAAG,IAAI,CAAC,UAAU,CAAA;QAElC,OAAO,IAAI,CAAA;;qCAEsB,UAAU,eAAe,IAAI,CAAC,SAAS;;;;;+EAKG,SAAS,CAAC,UAAU,CAAC,YAAY,CAAC;KAC5G,CAAA;IACH,CAAC;IAED,kBAAkB;QAChB,OAAO;YACL;gBACE,KAAK,EAAE,gBAAgB;gBACvB,IAAI,EAAE,CAAC,EAAE,EAAE,EAAE,EAAE,EAAE,CAAC;gBAClB,eAAe,EAAE,yBAAyB;gBAC1C,WAAW,EAAE,uBAAuB;gBACpC,WAAW,EAAE,CAAC;gBACd,UAAU,EAAE,QAAQ;gBACpB,WAAW,EAAE,CAAC;aACf;YACD;gBACE,KAAK,EAAE,gBAAgB;gBACvB,IAAI,EAAE,CAAC,EAAE,EAAE,EAAE,EAAE,EAAE,CAAC;gBAClB,eAAe,EAAE,yBAAyB;gBAC1C,WAAW,EAAE,uBAAuB;gBACpC,WAAW,EAAE,CAAC;gBACd,UAAU,EAAE,QAAQ;gBACpB,WAAW,EAAE,CAAC;aACf;SACF,CAAA;IACH,CAAC;;AAtCkB,iBAAiB;IADrC,aAAa,CAAC,sBAAsB,CAAC;GACjB,iBAAiB,CAuCrC;eAvCoB,iBAAiB","sourcesContent":["import '@operato/i18n/ox-i18n.js'\n\nimport { html } from 'lit'\nimport { customElement } from 'lit/decorators.js'\nimport { ifDefined } from 'lit/directives/if-defined.js'\n\nimport { InputChartAbstract } from './input-chart-abstract'\n\nimport './templates/series'\n\n@customElement('ox-input-chart-radar')\nexport default class OxInputChartRadar extends InputChartAbstract {\n static styles = InputChartAbstract.styles\n\n subTemplate() {\n const configurer = this.configurer\n\n return html`\n <legend><ox-i18n msgid=\"label.series\">Series</ox-i18n></legend>\n <ox-chart-series .configurer=${configurer} .chartType=${this.chartType} fullwidth></ox-chart-series>\n\n <legend><ox-i18n msgid=\"label.axes\">Axes</ox-i18n></legend>\n\n <label for=\"series-data-key\"> <ox-i18n msgid=\"label.data-key\">Data Key</ox-i18n> </label>\n <input id=\"series-data-key\" type=\"text\" value-key=\"labelDataKey\" value=${ifDefined(configurer.labelDataKey)} />\n `\n }\n\n getDefaultDatasets(): OperatoChart.Dataset[] {\n return [\n {\n label: 'Radar Series 1',\n data: [10, 20, 30],\n backgroundColor: 'rgba(255, 99, 132, 0.2)',\n borderColor: 'rgba(255, 99, 132, 1)',\n borderWidth: 1,\n pointStyle: 'circle',\n pointRadius: 3\n },\n {\n label: 'Radar Series 2',\n data: [15, 25, 35],\n backgroundColor: 'rgba(54, 162, 235, 0.2)',\n borderColor: 'rgba(54, 162, 235, 1)',\n borderWidth: 1,\n pointStyle: 'circle',\n pointRadius: 3\n }\n ]\n }\n}\n"]}
|
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
import '@operato/i18n/ox-i18n.js';
|
|
2
2
|
import { InputChartAbstract } from './input-chart-abstract';
|
|
3
|
+
import './templates/annotations';
|
|
4
|
+
import './templates/series';
|
|
3
5
|
export declare class OxInputChartTimeseries extends InputChartAbstract {
|
|
4
6
|
static styles: import("lit").CSSResult[];
|
|
5
7
|
annotationExpanded: boolean;
|
|
@@ -4,6 +4,8 @@ import { html, css } from 'lit';
|
|
|
4
4
|
import { customElement, state } from 'lit/decorators.js';
|
|
5
5
|
import { ifDefined } from 'lit/directives/if-defined.js';
|
|
6
6
|
import { InputChartAbstract } from './input-chart-abstract';
|
|
7
|
+
import './templates/annotations';
|
|
8
|
+
import './templates/series';
|
|
7
9
|
let OxInputChartTimeseries = class OxInputChartTimeseries extends InputChartAbstract {
|
|
8
10
|
constructor() {
|
|
9
11
|
super(...arguments);
|
|
@@ -23,7 +25,7 @@ let OxInputChartTimeseries = class OxInputChartTimeseries extends InputChartAbst
|
|
|
23
25
|
margin: 0;
|
|
24
26
|
}
|
|
25
27
|
|
|
26
|
-
|
|
28
|
+
[collapsed] {
|
|
27
29
|
display: none;
|
|
28
30
|
}
|
|
29
31
|
`
|
|
@@ -35,7 +37,7 @@ let OxInputChartTimeseries = class OxInputChartTimeseries extends InputChartAbst
|
|
|
35
37
|
<label for="multi-axis"> <ox-i18n msgid="label.multi-axis">Multi Axis</ox-i18n> </label>
|
|
36
38
|
|
|
37
39
|
<legend><ox-i18n msgid="label.series">Series</ox-i18n></legend>
|
|
38
|
-
<
|
|
40
|
+
<ox-chart-series .configurer=${configurer} .chartType=${this.chartType} fullwidth></ox-chart-series>
|
|
39
41
|
|
|
40
42
|
<legend><ox-i18n msgid="label.x-axes">X Axes</ox-i18n></legend>
|
|
41
43
|
|
|
@@ -250,7 +252,11 @@ let OxInputChartTimeseries = class OxInputChartTimeseries extends InputChartAbst
|
|
|
250
252
|
>${this.annotationExpanded ? 'expand_less' : 'expand_more'}</md-icon
|
|
251
253
|
>
|
|
252
254
|
</legend>
|
|
253
|
-
<
|
|
255
|
+
<ox-chart-annotations
|
|
256
|
+
.configurer=${configurer}
|
|
257
|
+
?collapsed=${!this.annotationExpanded}
|
|
258
|
+
fullwidth
|
|
259
|
+
></ox-chart-annotations>
|
|
254
260
|
`;
|
|
255
261
|
}
|
|
256
262
|
_hasBarSeries(config) {
|