Added minimal functionality for Robot teaching

- Added minimal HMI
- Added possibility to open and close all chamber doors
This commit is contained in:
2026-01-17 09:20:39 +01:00
parent 9f058db2a3
commit 2d11c43579
2274 changed files with 912690 additions and 162 deletions

View File

@@ -0,0 +1,510 @@
{
"$schema": "../../TcHmiFramework/Schema/ControlDescription.Schema.json",
"apiVersion": 1,
"name": "TcHmiSparkline",
"namespace": "TcHmi.Controls.Beckhoff",
"displayName": "Sparkline",
"version": {
"full": "14.4.1.0",
"major": 14,
"minor": 4,
"build": 1,
"revision": 0
},
"visible": true,
"themeable": "Standard",
"base": "TcHmi.Controls.System.TcHmiControl",
"description": "A multipurpose Sparkline.",
"defaultDesignerEvent": "",
"properties": {
"containerControl": false,
"geometry": {
"width": 300,
"height": 100
}
},
"icons": [
{
"name": "Icons/16x16.png",
"width": 16,
"height": 16
}
],
"template": "Template.html",
"dependencyFiles": [
{
"name": "Style.css",
"type": "Stylesheet",
"description": ""
},
{
"name": "../dist/TcHmiSparkline/TcHmiSparkline.esm.js",
"type": "EsModule",
"description": "Contains all the main logic as ES module."
}
],
"themes": {
"Base": {
"resources": [
{
"name": "Themes/Base/Defaults.theme",
"type": "ThemedValues",
"description": ""
},
{
"name": "Themes/Base/Style.css",
"type": "Stylesheet",
"description": ""
}
]
},
"Base-Dark": {
"resources": [
{
"name": "Themes/Base-Dark/Defaults.theme",
"type": "ThemedValues",
"description": ""
},
{
"name": "Themes/Base-Dark/Style.css",
"type": "Stylesheet",
"description": ""
}
]
}
},
"attributes": [
{
"name": "data-tchmi-line-graph-descriptions",
"propertyName": "LineGraphDescriptions",
"propertySetterName": "setLineGraphDescriptions",
"propertyGetterName": "getLineGraphDescriptions",
"displayName": "Line Graph Descriptions",
"visible": true,
"themeable": "Advanced",
"displayPriority": 10,
"type": "tchmi:framework#/definitions/TcHmi.Controls.Beckhoff.TcHmiSparkline.LineGraphDescriptionList",
"category": "Common",
"description": "Description of the line graph data. Defines the presentation in the graph.",
"readOnly": false,
"bindable": true,
"defaultBindingMode": "OneWay",
"heritable": true,
"allowSymbolExpressionsInObject": true,
"defaultValue": null,
"defaultValueInternal": null
},
{
"name": "data-tchmi-line-graph-data",
"propertyName": "LineGraphData",
"propertySetterName": "setLineGraphData",
"propertyGetterName": "getLineGraphData",
"displayName": "Line Graph Data",
"visible": true,
"themeable": "Advanced",
"displayPriority": 10,
"type": "tchmi:framework#/definitions/TcHmi.Controls.Beckhoff.TcHmiSparkline.LineGraphDataList",
"category": "Common",
"description": "The data to be displayed in the sparkline.",
"readOnly": false,
"bindable": true,
"defaultBindingMode": "OneWay",
"heritable": true,
"allowSymbolExpressionsInObject": true,
"defaultValue": null,
"defaultValueInternal": null
},
{
"name": "data-tchmi-x-axis-start",
"propertyName": "XAxisStart",
"propertySetterName": "setXAxisStart",
"propertyGetterName": "getXAxisStart",
"displayName": "X Axis Start",
"visible": true,
"displayPriority": 10,
"type": "tchmi:general#/definitions/Number",
"category": "Common",
"themeable": "Standard",
"description": "The start value of the imagined xAxis of the sparkline.",
"readOnly": false,
"bindable": true,
"defaultBindingMode": "OneWay",
"heritable": true,
"defaultValue": null,
"defaultValueInternal": null
},
{
"name": "data-tchmi-x-axis-end",
"propertyName": "XAxisEnd",
"propertySetterName": "setXAxisEnd",
"propertyGetterName": "getXAxisEnd",
"displayName": "X Axis End",
"visible": true,
"displayPriority": 10,
"type": "tchmi:general#/definitions/Number",
"category": "Common",
"themeable": "Standard",
"description": "The end value of the imagined xAxis of the sparkline.",
"readOnly": false,
"bindable": true,
"defaultBindingMode": "OneWay",
"heritable": true,
"defaultValue": null,
"defaultValueInternal": null
},
{
"name": "data-tchmi-show-label",
"propertyName": "ShowLabel",
"propertySetterName": "setShowLabel",
"propertyGetterName": "getShowLabel",
"displayName": "Show Label",
"visible": true,
"displayPriority": 10,
"type": "tchmi:general#/definitions/Boolean",
"category": "Label",
"description": "Defines whether the label of each the chart is displayed or not.",
"themeable": "Standard",
"readOnly": false,
"bindable": true,
"defaultBindingMode": "OneWay",
"heritable": true,
"defaultValue": null,
"defaultValueInternal": false
},
{
"name": "data-tchmi-label-color",
"propertyName": "LabelColor",
"propertySetterName": "setLabelColor",
"propertyGetterName": "getLabelColor",
"displayName": "Label Color",
"visible": true,
"displayPriority": 60,
"type": "tchmi:framework#/definitions/SolidColor",
"category": "Colors",
"themeable": "Standard",
"description": "Defines the color of the label.",
"readOnly": false,
"bindable": true,
"defaultBindingMode": "OneWay",
"heritable": true,
"allowSymbolExpressionsInObject": true,
"defaultValue": null,
"defaultValueInternal": null
},
{
"name": "data-tchmi-label-position",
"propertyName": "LabelPosition",
"propertySetterName": "setLabelPosition",
"propertyGetterName": "getLabelPosition",
"displayName": "Label Position",
"visible": true,
"themeable": "Standard",
"displayPriority": 10,
"type": "tchmi:framework#/definitions/TcHmi.Controls.Beckhoff.TcHmiSparkline.LabelPosition",
"category": "Label",
"description": "Defines where the label is displayed.",
"readOnly": false,
"bindable": true,
"defaultBindingMode": "OneWay",
"heritable": true,
"defaultValue": null,
"defaultValueInternal": "Left"
},
{
"name": "data-tchmi-label-font-family",
"propertyName": "LabelFontFamily",
"propertySetterName": "setLabelFontFamily",
"propertyGetterName": "getLabelFontFamily",
"displayName": "Label Font Family",
"visible": true,
"displayPriority": 60,
"type": "tchmi:framework#/definitions/FontFamily",
"category": "Label",
"themeable": "Standard",
"description": "Defines the font family of the label. Comma separated list of family name or keyword: 'serif', 'sans-serif', 'monospace'.",
"readOnly": false,
"bindable": true,
"defaultBindingMode": "OneWay",
"heritable": true,
"defaultValue": null,
"defaultValueInternal": null
},
{
"name": "data-tchmi-label-font-size",
"propertyName": "LabelFontSize",
"propertySetterName": "setLabelFontSize",
"propertyGetterName": "getLabelFontSize",
"displayName": "Label Font Size",
"visible": true,
"displayPriority": 60,
"themeable": "Standard",
"type": "tchmi:framework#/definitions/MeasurementValue",
"category": "Label",
"description": "Defines the label font size.",
"readOnly": false,
"bindable": true,
"defaultBindingMode": "OneWay",
"heritable": true,
"defaultValue": null,
"defaultValueInternal": 12
},
{
"name": "data-tchmi-label-font-size-unit",
"propertyName": "LabelFontSizeUnit",
"propertyGetterName": "getLabelFontSizeUnit",
"refTo": "LabelFontSize",
"displayName": "Label Font Size Unit",
"visible": true,
"displayPriority": 50,
"type": "tchmi:framework#/definitions/PixelUnit",
"category": "Label",
"description": "Is 'px'.",
"readOnly": true,
"bindable": false,
"defaultBindingMode": "OneWay",
"heritable": true,
"defaultValueInternal": "px"
},
{
"name": "data-tchmi-label-font-weight",
"propertyName": "LabelFontWeight",
"propertySetterName": "setLabelFontWeight",
"propertyGetterName": "getLabelFontWeight",
"displayName": "Label Font Weight",
"visible": true,
"displayPriority": 60,
"type": "tchmi:framework#/definitions/FontWeight",
"category": "Label",
"themeable": "Standard",
"description": "Defines the font weight of the label. 'Normal', 'Bold' (glyphs with more weight) or 'Auto' for inherited.",
"readOnly": false,
"bindable": true,
"defaultBindingMode": "OneWay",
"heritable": true,
"defaultValue": null,
"defaultValueInternal": "Auto"
},
{
"name": "data-tchmi-show-y-axis",
"propertyName": "ShowYAxis",
"propertySetterName": "setShowYAxis",
"propertyGetterName": "getShowYAxis",
"displayName": "Show YAxis",
"visible": true,
"themeable": "Standard",
"displayPriority": 10,
"type": "tchmi:general#/definitions/Boolean",
"category": "Y Axis",
"description": "Defines whether the y-axis is displayed or not.",
"readOnly": false,
"bindable": true,
"defaultBindingMode": "OneWay",
"heritable": true,
"defaultValue": null,
"defaultValueInternal": false
},
{
"name": "data-tchmi-y-axis-color",
"propertyName": "YAxisColor",
"propertySetterName": "setYAxisColor",
"propertyGetterName": "getYAxisColor",
"displayName": "Y Axis Color",
"visible": true,
"displayPriority": 60,
"type": "tchmi:framework#/definitions/SolidColor",
"category": "Colors",
"themeable": "Standard",
"description": "Defines the color of the y-axis.",
"readOnly": false,
"bindable": true,
"defaultBindingMode": "OneWay",
"heritable": true,
"allowSymbolExpressionsInObject": true,
"defaultValue": null,
"defaultValueInternal": null
},
{
"name": "data-tchmi-y-axis-position",
"propertyName": "YAxisPosition",
"propertySetterName": "setYAxisPosition",
"propertyGetterName": "getYAxisPosition",
"displayName": "YAxis Position",
"visible": true,
"themeable": "Standard",
"displayPriority": 10,
"type": "tchmi:framework#/definitions/TcHmi.Controls.Beckhoff.TcHmiSparkline.AxisPosition",
"category": "Y Axis",
"description": "Defines where the y-axis is displayed.",
"readOnly": false,
"bindable": true,
"defaultBindingMode": "OneWay",
"heritable": true,
"defaultValue": null,
"defaultValueInternal": "Right"
},
{
"name": "data-tchmi-y-axis-decimal-places",
"propertyName": "YAxisDecimalPlaces",
"propertySetterName": "setYAxisDecimalPlaces",
"propertyGetterName": "getYAxisDecimalPlaces",
"displayName": "Y Axis Decimal Places",
"visible": true,
"displayPriority": 60,
"type": "tchmi:general#/definitions/Number",
"category": "Y Axis",
"themeable": "Standard",
"description": "Determines the decimal places of the label on the y-axis.",
"readOnly": false,
"bindable": true,
"defaultBindingMode": "OneWay",
"heritable": true,
"defaultValue": null,
"defaultValueInternal": 0
},
{
"name": "data-tchmi-y-axis-width",
"propertyName": "YAxisWidth",
"propertySetterName": "setYAxisWidth",
"propertyGetterName": "getYAxisWidth",
"displayName": "Y Axis Width",
"visible": true,
"displayPriority": 60,
"type": "tchmi:general#/definitions/Number",
"category": "Y Axis",
"themeable": "Standard",
"description": "Defines the thickness of the Y-axis.",
"readOnly": false,
"bindable": true,
"defaultBindingMode": "OneWay",
"heritable": true,
"defaultValue": null,
"defaultValueInternal": 1
},
{
"name": "data-tchmi-y-label-font-family",
"propertyName": "YLabelFontFamily",
"propertySetterName": "setYLabelFontFamily",
"propertyGetterName": "getYLabelFontFamily",
"displayName": "Y Label Font Family",
"visible": true,
"displayPriority": 60,
"type": "tchmi:framework#/definitions/FontFamily",
"category": "Y Axis",
"themeable": "Standard",
"description": "Defines the font family of the Y-axis labels. Comma separated list of family name or keyword: 'serif', 'sans-serif', 'monospace'.",
"readOnly": false,
"bindable": true,
"defaultBindingMode": "OneWay",
"heritable": true,
"defaultValue": null,
"defaultValueInternal": null
},
{
"name": "data-tchmi-y-label-font-size",
"propertyName": "YLabelFontSize",
"propertySetterName": "setYLabelFontSize",
"propertyGetterName": "getYLabelFontSize",
"displayName": "Y Label Font Size",
"visible": true,
"displayPriority": 60,
"themeable": "Standard",
"type": "tchmi:framework#/definitions/MeasurementValue",
"category": "Y Axis",
"description": "Defines the Y-axis label font size.",
"readOnly": false,
"bindable": true,
"defaultBindingMode": "OneWay",
"heritable": true,
"defaultValue": null,
"defaultValueInternal": 12
},
{
"name": "data-tchmi-y-label-font-size-unit",
"propertyName": "YLabelFontSizeUnit",
"propertyGetterName": "getYLabelFontSizeUnit",
"refTo": "YLabelFontSize",
"displayName": "Y Label Font Size Unit",
"visible": true,
"displayPriority": 50,
"type": "tchmi:framework#/definitions/PixelUnit",
"category": "Y Axis",
"description": "Is 'px'.",
"readOnly": true,
"bindable": false,
"defaultBindingMode": "OneWay",
"heritable": true,
"defaultValueInternal": "px"
},
{
"name": "data-tchmi-y-label-font-weight",
"propertyName": "YLabelFontWeight",
"propertySetterName": "setYLabelFontWeight",
"propertyGetterName": "getYLabelFontWeight",
"displayName": "Y Label Font Weight",
"visible": true,
"displayPriority": 60,
"type": "tchmi:framework#/definitions/FontWeight",
"category": "Y Axis",
"themeable": "Standard",
"description": "Defines the font weight of the X-axis label. 'Normal', 'Bold' (glyphs with more weight) or 'Auto' for inherited.",
"readOnly": false,
"bindable": true,
"defaultBindingMode": "OneWay",
"heritable": true,
"defaultValue": null,
"defaultValueInternal": "Auto"
}
],
"attributeCategories": [
{
"name": "Label",
"displayPriority": 510,
"description": "Attributes defining the label of the chart"
},
{
"name": "Y Axis",
"displayPriority": 520,
"description": "Attributes defining the Y-Axis of the chart"
}
],
"themedResources": [
{
"name": "DefaultGraphColor",
"displayName": "Default Graph Color",
"description": "Color of a line",
"type": "tchmi:framework#/definitions/SolidColor"
},
{
"name": "DefaultYAxisColor",
"displayName": "Default Y Axis Color",
"description": "Color of a y-axis line",
"type": "tchmi:framework#/definitions/SolidColor"
},
{
"name": "ReferenceLineColor",
"displayName": "Reference Line Color",
"description": "Color of a reference line",
"type": "tchmi:framework#/definitions/SolidColor"
},
{
"name": "LabelColor",
"displayName": "Label Color",
"description": "Color of the label",
"type": "tchmi:framework#/definitions/SolidColor"
}
],
"functions": [],
"events": [],
"dataTypes": [
{
"schema": "Schema/Types.Schema.json"
},
{
"schema": "../Schema/Types.Schema.json"
}
],
"languages": {
"en": "Lang/Language.en.json",
"de": "Lang/Language.de.json"
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 475 B

View File

@@ -0,0 +1,7 @@
{
"$schema": "../../../TwinCAT-HMI-Common/JsonSchemas/Language.Schema.json",
"locale": "de",
"localizedText": {
"Engineering_Text": "Daten werden erst zur Laufzeit angezeigt."
}
}

View File

@@ -0,0 +1,7 @@
{
"$schema": "../../../TwinCAT-HMI-Common/JsonSchemas/Language.Schema.json",
"locale": "en",
"localizedText": {
"Engineering_Text": "Data are only displayed at runtime."
}
}

View File

@@ -0,0 +1,259 @@
{
"$schema": "http://json-schema.org/draft-04/schema",
"definitions": {
"TcHmi.Controls.Beckhoff.TcHmiSparkline": {
"$schema": "http://json-schema.org/draft-04/schema",
"type": "object",
"frameworkInstanceOf": "TcHmi.Controls.System.TcHmiControl",
"frameworkControlType": "TcHmiSparkline",
"frameworkControlNamespace": "TcHmi.Controls.Beckhoff"
},
"TcHmiSparkline": {
"$ref": "tchmi:framework#/definitions/TcHmi.Controls.Beckhoff.TcHmiSparkline"
},
"TcHmi.Controls.Beckhoff.TcHmiSparkline.LineGraphDescriptionList": {
"title": "LineGraphDescriptionList",
"type": "array",
"items": {
"type": "object",
"engineeringColumns": ["lineWidth"],
"propertiesMeta": [
{
"name": "lineColor",
"displayName": "Line Color",
"category": "Colors",
"displayPriority": 10,
"description": "Color for this line",
"defaultValue": "%tr%Control::TcHmi.Controls.Beckhoff.TcHmiLineChart::LineGraphDescriptionLineColor%/tr%",
"defaultValueInternal": null
},
{
"name": "lineWidth",
"displayName": "Line Width",
"category": "General",
"displayPriority": 10,
"description": "Line width in pixel",
"defaultValue": 1,
"defaultValueInternal": null
},
{
"name": "displayName",
"displayName": "Display Name",
"category": "General",
"displayPriority": 10,
"description": "Display name of the historized Symbol",
"defaultValue": null,
"defaultValueInternal": null
},
{
"name": "referenceLines",
"displayName": "Reference Lines",
"category": "General",
"displayPriority": 10,
"description": "Reference lines",
"defaultValue": null,
"defaultValueInternal": null
}
],
"properties": {
"lineColor": {
"$ref": "tchmi:framework#/definitions/SolidColor"
},
"displayName": {
"type": "string"
},
"lineWidth": {
"type": "number"
},
"referenceLines": {
"$ref": "tchmi:framework#/definitions/TcHmi.Controls.Beckhoff.TcHmiSparkline.ReferenceLineDefinitionList"
}
},
"additionalProperties": false,
"required": ["lineWidth"]
}
},
"TcHmi.Controls.Beckhoff.TcHmiSparkline.LineGraphDataList": {
"title": "LineGraphDataList",
"anyOf": [
{
"type": "array",
"title": "Array<Array<Coordinate pair>>",
"items": {
"type": "array",
"title": "List of coordinate pairs",
"items": {
"type": "object",
"title": "Coordinate pair",
"engineeringColumns": ["x", "y"],
"propertiesMeta": [
{
"name": "x",
"displayName": "X",
"category": "General",
"displayPriority": 10,
"description": "x coordinate",
"defaultValue": null,
"defaultValueInternal": null
},
{
"name": "y",
"displayName": "Y",
"category": "General",
"displayPriority": 10,
"description": "y coordinate",
"defaultValue": null,
"defaultValueInternal": null
}
],
"properties": {
"x": {
"type": "number"
},
"y": {
"type": "number"
}
},
"required": ["x", "y"],
"additionalProperties": false
}
}
},
{
"type": "array",
"title": "Array<Array<number>>",
"items": {
"type": "array",
"items": {
"type": "number"
}
}
},
{
"type": "array",
"title": "Array<number>",
"items": {
"type": "number"
}
}
]
},
"TcHmi.Controls.Beckhoff.TcHmiSparkline.ChartStart": {
"anyOf": [
{
"title": "Time",
"$ref": "tchmi:general#/definitions/DateTime"
},
{
"title": "Timespan",
"$ref": "tchmi:general#/definitions/TimeSpan"
},
{
"title": "KeyWords",
"type": "string",
"enum": ["First"]
}
],
"default": "First"
},
"TcHmi.Controls.Beckhoff.TcHmiSparkline.ChartEnd": {
"anyOf": [
{
"title": "Time",
"$ref": "tchmi:general#/definitions/DateTime"
},
{
"title": "Timespan",
"$ref": "tchmi:general#/definitions/TimeSpan"
},
{
"title": "KeyWords",
"type": "string",
"enum": ["Latest"]
}
],
"default": "Latest"
},
"TcHmi.Controls.Beckhoff.TcHmiSparkline.ReferenceLineDefinition": {
"title": "ReferenceLineDefinition",
"type": "object",
"engineeringColumns": ["value"],
"propertiesMeta": [
{
"name": "show",
"category": "General",
"displayName": "Show",
"displayPriority": 10,
"description": "Describes whether the reference line is displayed.",
"defaultValue": null,
"defaultValueInternal": true
},
{
"name": "value",
"category": "General",
"displayName": "Value",
"displayPriority": 10,
"description": "Describes the value of the reference line.",
"defaultValue": 0,
"defaultValueInternal": 0
},
{
"name": "color",
"category": "Colors",
"displayName": "Color",
"displayPriority": 10,
"description": "Describes the color of the reference line.",
"defaultValue": "%tr%Control::TcHmi.Controls.Beckhoff.TcHmiSparkline::ReferenceLineColor%/tr%",
"defaultValueInternal": {
"color": "#4794da"
}
},
{
"name": "lineWidth",
"category": "General",
"displayName": "Line Width",
"displayPriority": 10,
"description": "Describes the line thickness of the reference line.",
"defaultValue": 1,
"defaultValueInternal": null
}
],
"properties": {
"show": {
"type": "boolean"
},
"value": {
"type": "number"
},
"color": {
"$ref": "tchmi:framework#/definitions/SolidColor"
},
"lineWidth": {
"type": "number"
}
},
"additionalProperties": false,
"required": ["value"]
},
"TcHmi.Controls.Beckhoff.TcHmiSparkline.ReferenceLineDefinitionList": {
"$schema": "http://json-schema.org/draft-04/schema",
"title": "ReferenceLineDefinitionList",
"type": "array",
"items": {
"$ref": "tchmi:framework#/definitions/TcHmi.Controls.Beckhoff.TcHmiSparkline.ReferenceLineDefinition"
}
},
"TcHmi.Controls.Beckhoff.TcHmiSparkline.AxisPosition": {
"title": "AxisPosition",
"type": "string",
"enum": ["Right", "Left"],
"default": "Right"
},
"TcHmi.Controls.Beckhoff.TcHmiSparkline.LabelPosition": {
"title": "LabelPosition",
"type": "string",
"enum": ["Right", "Center", "Left"],
"default": "Right"
}
}
}

View File

@@ -0,0 +1,32 @@
/** Styles for all themes */
/* Style for the main element */
.TcHmi_Controls_Beckhoff_TcHmiSparkline {
/* Prevent overflow if the border radius is huge */
overflow: hidden;
}
.TcHmi_Controls_Beckhoff_TcHmiSparkline-template {
position: absolute;
width: 100%;
height: 100%;
padding: 5px;
}
.TcHmi_Controls_Beckhoff_TcHmiSparkline-template-chart {
box-sizing: border-box;
position: relative;
top: 0px;
width: 100%;
}
.TcHmi_Controls_Beckhoff_TcHmiSparkline-chart {
position: relative;
width: 100%;
}
.TcHmi_Controls_Beckhoff_TcHmiSparkline-chart-label {
position: relative;
width: 100%;
top: 0px;
}

View File

@@ -0,0 +1,343 @@
// Compatibility file for non-module typescript compiles without adjustments.
// Use the following line for modern code (needs adjustments to tsconfig.json#configOptions/paths)
// import { TcHmiControl } from "Beckhoff.TwinCAT.HMI.Framework/index.esm.js";
// ***************************************************************************
export declare enum Datatype {
Datetime = 0,
Timespan = 1,
Keyword = 2
}
export declare enum Position {
Left = 0,
Right = 1
}
export declare enum LabelPosition {
Left = 0,
Right = 1,
Center = 2
}
declare class TcHmiSparkline extends TcHmi.Controls.System.TcHmiControl {
#private;
constructor(element: JQuery, pcElement: JQuery, attrs: TcHmi.Controls.ControlAttributeList);
/** member variables */
/** Reference to the root dom element of the current control template as jquery object. */
protected __elementTemplateRoot: JQuery;
/** Internal reference to the attribute 'data-tchmi-line-graph-descriptions' */
protected __lineGraphDescriptions: LineGraphDescription[] | null | undefined;
/** Internal lineDescription array as TcHmiSparkline.LineGraphDescription[] */
protected __lineGraphDescriptionsInternal: LineGraphDescription[] | null | undefined;
/** Internal reference to the attribute 'data-tchmi-line-graph-data' */
protected __lineGraphData: Point[][] | number[][] | number[] | null | undefined;
/** Internal lineGraph array as TcHmiSparkline.Point[][] */
protected __lineGraphDataInternal: Point[][] | null;
/** Internal reference to the attribute 'data-tchmi-x-axis-start' */
__xAxisStart: number | null | undefined;
/** Internal reference to the attribute 'data-tchmi-x-axis-end' */
__xAxisEnd: number | null | undefined;
/** Internal reference to the attribute 'data-tchmi-show-label' */
protected __showLabel: boolean | undefined;
/** Internal reference to the attribute 'data-tchmi-label-color' */
protected __labelColor: TcHmi.SolidColor | null | undefined;
/** Internal reference to the attribute 'data-tchmi-label-position' */
protected __labelPosition: keyof typeof LabelPosition | undefined;
/** Internal reference to the attribute 'data-tchmi-label-font-family' */
protected __labelFontFamily: TcHmi.FontFamily | undefined;
/** Internal reference to the attribute 'data-tchmi-label-font-size' */
protected __labelFontSize: number | undefined;
/** Internal reference to the attribute 'data-tchmi-label-font-weight' */
protected __labelFontWeight: TcHmi.FontWeight | undefined;
/** Internal reference to the attribute 'data-tchmi-show-y-axis' */
protected __showYAxis: boolean | undefined;
/** Internal reference to the attribute 'data-tchmi-y-axis-color' */
protected __yAxisColor: TcHmi.SolidColor | null | undefined;
/** Internal reference to the attribute 'data-tchmi-y-axis-position' */
protected __yAxisPosition: keyof typeof Position | undefined;
/** Internal reference to the attribute 'data-tchmi-y-axis-width' */
protected __yAxisWidth: number | undefined;
/** Internal reference to the attribute 'data-tchmi-y-label-font-family' */
protected __yLabelFontFamily: TcHmi.FontFamily | undefined;
/** Internal reference to the attribute 'data-tchmi-y-label-font-size' */
protected __yLabelFontSize: number | undefined;
/** Internal reference to the attribute 'data-tchmi-y-label-font-weight' */
protected __yLabelFontWeight: TcHmi.FontWeight | undefined;
/** Internal reference to the attribute 'data-tchmi-y-axis-decimal-places' */
protected __yAxisDecimalPlaces: number | undefined;
/** Linechart elements' */
protected __lineCharts: TcHmiCharting.LineChart[];
/** Localization */
protected __localizedElements: Map<string, {
element: HTMLElement;
value: string | null;
}>;
protected __localizedEngineeringElements: Map<string, Element>;
__localizationReader: TcHmi.Locale.LocalizationReader | undefined;
/**
* If raised, the control object exists in control cache and constructor of each inheritation level was called.
* This function is only to be used by the System. Other function calls are not intended.
*/
__previnit(): void;
/**
* If raised, all attributes have been set to it's default or dom values.
* This function is only to be used by the System. Other function calls are not intended.
*/
__init(): void;
/**
* Is called by the system after the control instance gets part of the current DOM.
* This function is only to be used by the System. Other function calls are not intended.
*/
__attach(): void;
/**
* Is called by the system after the control instance is no longer part of the current DOM.
* This function is only to be used by the System. Other function calls are not intended.
*/
__detach(): void;
/**
* Destroy the current control instance.
* Will be called automatically if system destroys control!
*/
destroy(): void;
/** Is raised if the control should be redrawn. */
protected __rebuild(_event: TcHmi.EventProvider.Event, _ctrl?: TcHmi.Controls.System.TcHmiControl): void;
/** Is called initial and and if size changed. */
protected __drawLineChart(): void;
/** Reset the linechart */
protected __reset(): void;
/**
* Sets the value of the member variable 'lineGraphDescriptions' if the new value is not equal to the current value
* and calls the associated process function (processlineGraphDescriptions) after that.
* @param valueNew The new value for lineGraphDescriptions.
*/
setLineGraphDescriptions(valueNew: LineGraphDescription[] | null): void;
/**
* The watch callback for the lineGraphDescriptions object resolver.
*/
protected __onResolverForLineGraphDescriptionsWatchCallback(data: TcHmi.Symbol.ObjectResolver.IWatchResultObject<LineGraphDescription[]>): void;
/**
* Returns the current value of the member variable lineGraphDescriptions.
*/
getLineGraphDescriptions(): LineGraphDescription[] | null | undefined;
/**
* Processes the current value of lineGraphDescriptions.
*/
protected __processLineGraphDescriptions(): void;
/**
* Sets the value of the member variable 'lineGraphData' if the new value is not equal to the current value
* and calls the associated process function (processLineGraphData) after that.
* @param valueNew The new value for lineGraphData.
*/
setLineGraphData(valueNew: Point[][] | number[][] | number[] | null): void;
/**
* The watch callback for the lineGraphData object resolver.
*/
protected __onResolverForLineGraphDataWatchCallback(data: TcHmi.Symbol.ObjectResolver.IWatchResultObject<Point[][] | number[][] | number[]>): void;
/**
* Returns the current value of the member variable lineGraphData.
*/
getLineGraphData(): Point[][] | number[] | number[][] | null | undefined;
/**
* Processes the current value of lineGraphData.
*/
protected __processLineGraphData(): void;
/**
* Sets the value of xAxisStart
* @param valueNew The new value for xAxisStart
*/
setXAxisStart(valueNew: number | null | undefined): void;
/** Gets the value of xAxisStart */
getXAxisStart(): number | null | undefined;
/** Processes xAxisStart */
protected __processXAxisStart(): void;
/**
* Sets the value of xAxisEnd
* @param valueNew The new value for xAxisEnd
*/
setXAxisEnd(valueNew: number | null | undefined): void;
/** Gets the value of xAxisEnd */
getXAxisEnd(): number | null | undefined;
/** Processes xAxisEnd */
protected __processXAxisEnd(): void;
/**
* Sets the value of showLabel
* @param valueNew The new value for showLabel
*/
setShowLabel(valueNew: boolean | null): void;
/** Gets the value of showLabel */
getShowLabel(): boolean | undefined;
/** Processes showLabel */
protected __processShowLabel(): void;
/**
* Sets the labelColor value and calls the associated process function (processLabelColor).
* @param valueNew The new value for the LabelColor attribute as object.
*/
setLabelColor(valueNew: TcHmi.SolidColor | null): void;
/** The watch callback for the labelColor object resolver. */
protected __onResolverForLabelColorWatchCallback(data: TcHmi.Symbol.ObjectResolver.IWatchResultObject<TcHmi.SolidColor>): void;
/** Returns the current labelColor value. */
getLabelColor(): TcHmi.SolidColor | null | undefined;
/** Processes the current labelColor attribute. */
protected __processLabelColor(): void;
/**
* Sets the value of labelPosition
* @param valueNew The new value for labelPosition
*/
setLabelPosition(valueNew: keyof typeof Position | null): void;
/** Gets the value of labelPosition */
getLabelPosition(): "Left" | "Right" | "Center" | undefined;
/** Processes labelPosition. */
protected __processLabelPosition(): void;
/**
* Sets the value of labelFontFamily
* @param valueNew The new value for labelFontFamily
*/
setLabelFontFamily(valueNew: TcHmi.FontFamily | null): void;
/** Gets the value of labelFontFamily */
getLabelFontFamily(): string | undefined;
/** Processes labelFontFamily */
protected __processLabelFontFamily(): void;
/**
* Sets the value of labelFontSize
* @param valueNew The new value for labelFontSize
*/
setLabelFontSize(valueNew: number | null): void;
/** Gets the value of labelFontSize */
getLabelFontSize(): number | undefined;
/** Processes labelFontSize */
protected __processLabelFontSize(): void;
/** Gets the value of labelFontSizeUnit */
getLabelFontSizeUnit(): string;
/**
* Sets the value of labelFontWeight
* @param valueNew The new value for labelFontWeight
*/
setLabelFontWeight(valueNew: TcHmi.FontWeight | null): void;
/** Gets the value of labelFontWeight */
getLabelFontWeight(): TcHmi.FontWeight | undefined;
/** Processes labelFontWeight */
protected __processLabelFontWeight(): void;
/**
* Sets the value of showYAxis
* @param valueNew The new value for showYAxis
*/
setShowYAxis(valueNew: boolean | null): void;
/** Gets the value of showYAxis */
getShowYAxis(): boolean | undefined;
/** Processes showYAxis */
protected __processShowYAxis(): void;
/**
* Sets the yAxisColor value and calls the associated process function (processYAxisColor).
* @param valueNew The new value for the yAxisColor attribute as object.
*/
setYAxisColor(valueNew: TcHmi.SolidColor | null): void;
/** The watch callback for the yAxisColor object resolver. */
protected __onResolverForYAxisColorWatchCallback(data: TcHmi.Symbol.ObjectResolver.IWatchResultObject<TcHmi.SolidColor>): void;
/** Returns the current yAxisColor value. */
getYAxisColor(): TcHmi.SolidColor | null | undefined;
/** Processes the current yAxisColor attribute. */
protected __processYAxisColor(): void;
/**
* Sets the value of yAxisPosition
* @param valueNew The new value for yAxisPosition
*/
setYAxisPosition(valueNew: keyof typeof Position | null): void;
/** Gets the value of yAxisPosition */
getYAxisPosition(): "Left" | "Right" | undefined;
/** Processes yAxisPosition. */
protected __processYAxisPosition(): void;
/**
* Sets the value of yAxisDecimalPlaces
* @param valueNew The new value for yAxisDecimalPlaces
*/
setYAxisDecimalPlaces(valueNew: number | null): void;
/** Gets the value of yAxisDecimalPlaces */
getYAxisDecimalPlaces(): number | undefined;
/** Processes yAxisDecimalPlaces */
protected __processYAxisDecimalPlaces(): void;
/**
* Sets the value of yAxisWidth
* @param valueNew The new value for yAxisWidth
*/
setYAxisWidth(valueNew: number | null): void;
/** Gets the value of yAxisWidth */
getYAxisWidth(): number | undefined;
/** Processes yAxisWidth */
protected __processYAxisWidth(): void;
/**
* Sets the value of yLabelFontFamily
* @param valueNew The new value for yLabelFontFamily
*/
setYLabelFontFamily(valueNew: TcHmi.FontFamily | null): void;
/** Gets the value of yLabelFontFamily */
getYLabelFontFamily(): string | undefined;
/** Processes yLabelFontFamily */
protected __processYLabelFontFamily(): void;
/**
* Sets the value of yLabelFontSize
* @param valueNew The new value for yLabelFontSize
*/
setYLabelFontSize(valueNew: number | null): void;
/** Gets the value of yLabelFontSize */
getYLabelFontSize(): number | undefined;
/** Processes yLabelFontSize */
protected __processYLabelFontSize(): void;
/** Gets the value of yLabelFontSizeUnit */
getYLabelFontSizeUnit(): string;
/**
* Sets the value of yLabelFontWeight
* @param valueNew The new value for yLabelFontWeight
*/
setYLabelFontWeight(valueNew: TcHmi.FontWeight | null): void;
/** Gets the value of yLabelFontWeight */
getYLabelFontWeight(): TcHmi.FontWeight | undefined;
/** Processes yLabelFontWeight */
protected __processYLabelFontWeight(): void;
static Datatype: typeof Datatype;
static Position: typeof Position;
static LabelPosition: typeof LabelPosition;
}
export interface LineGraphDescription {
displayName?: string;
lineWidth: number;
lineColor?: TcHmi.SolidColor;
referenceLines?: ReferenceLine[];
}
export interface Point {
x: number;
y: number;
}
export interface ServerPoint {
x: number;
y?: number;
error?: number;
}
export interface ReferenceLine {
show: boolean;
value: number;
color?: TcHmi.SolidColor;
lineWidth: number;
}
export { TcHmiSparkline as Control };
declare const _TcHmiSparkline: typeof TcHmiSparkline;
type tTcHmiSparkline = TcHmiSparkline;
type tDatatype = Datatype;
type tPosition = Position;
type tLabelPosition = LabelPosition;
type tLineGraphDescription = LineGraphDescription;
type tPoint = Point;
type tServerPoint = ServerPoint;
type tReferenceLine = ReferenceLine;
declare global {
namespace TcHmi.Controls.Beckhoff {
const TcHmiSparkline: typeof _TcHmiSparkline;
type TcHmiSparkline = tTcHmiSparkline;
namespace TcHmiSparkline {
type Datatype = tDatatype;
type Position = tPosition;
type LabelPosition = tLabelPosition;
type LineGraphDescription = tLineGraphDescription;
type Point = tPoint;
type ServerPoint = tServerPoint;
type ReferenceLine = tReferenceLine;
}
}
}

View File

@@ -0,0 +1 @@
<div class="TcHmi_Controls_Beckhoff_TcHmiSparkline-template tchmi-box"></div>

View File

@@ -0,0 +1,22 @@
{
"$schema": "../../../../TcHmiFramework/Schema/ThemeDescription.Schema.json",
"controlTypeValues": {
"TcHmi.Controls.Beckhoff.TcHmiSparkline": {
"attributes": {},
"themedResources": {
"DefaultGraphColor": {
"color": "#2775be"
},
"DefaultYAxisColor": {
"color": "#ffffff"
},
"ReferenceLineColor": {
"color": "#ffffff"
},
"LabelColor": {
"color": "#ffffff"
}
}
}
}
}

View File

@@ -0,0 +1,21 @@
/** Styles for the theme: Base-Dark */
/* Style for the main element */
.TcHmi_Controls_Beckhoff_TcHmiSparkline {
--tchmi-background: var(--tchmi-background-color-1);
--tchmi-background-part: var(--tchmi-background-color-3);
--tchmi-checkbox-background: var(--tchmi-background-color-4);
--tchmi-checkbox-background-checked: var(--tchmi-highlight-color-1);
--tchmi-color: var(--tchmi-foreground-color-1);
--tchmi-border-color: var(--tchmi-background-color-2);
background: var(--tchmi-background);
box-shadow: var(--tchmi-card-shadow);
}
.TcHmi_Controls_Beckhoff_TcHmiSparkline-template-chart {
border-bottom: 1px solid #c0c0c5;
}
.TcHmi_Controls_Beckhoff_TcHmiSparkline-template-chart:last-child {
border-bottom: none;
}

View File

@@ -0,0 +1,22 @@
{
"$schema": "../../../../TcHmiFramework/Schema/ThemeDescription.Schema.json",
"controlTypeValues": {
"TcHmi.Controls.Beckhoff.TcHmiSparkline": {
"attributes": {},
"themedResources": {
"DefaultGraphColor": {
"color": "#4794da"
},
"DefaultYAxisColor": {
"color": "#4794da"
},
"ReferenceLineColor": {
"color": "#4794da"
},
"LabelColor": {
"color": "#4794da"
}
}
}
}
}

View File

@@ -0,0 +1,21 @@
/** Styles for the theme: Base */
/* Style for the main element */
.TcHmi_Controls_Beckhoff_TcHmiSparkline {
--tchmi-background: var(--tchmi-background-color-1);
--tchmi-background-part: var(--tchmi-background-color-1);
--tchmi-checkbox-background: var(--tchmi-background-color-4);
--tchmi-checkbox-background-checked: var(--tchmi-highlight-color-1);
--tchmi-color: var(--tchmi-highlight-color-1);
--tchmi-border-color: var(--tchmi-background-color-2);
background: var(--tchmi-background);
box-shadow: var(--tchmi-card-shadow);
}
.TcHmi_Controls_Beckhoff_TcHmiSparkline-template-chart {
border-bottom: 1px solid #c0c0c5;
}
.TcHmi_Controls_Beckhoff_TcHmiSparkline-template-chart:last-child {
border-bottom: none;
}