iobroker.schedule-switcher
Version:
Switch states over scheduler
1,141 lines • 79 kB
JavaScript
"use strict";
var __defProp = Object.defineProperty;
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
var __getOwnPropNames = Object.getOwnPropertyNames;
var __hasOwnProp = Object.prototype.hasOwnProperty;
var __export = (target, all) => {
for (var name in all)
__defProp(target, name, { get: all[name], enumerable: true });
};
var __copyProps = (to, from, except, desc) => {
if (from && typeof from === "object" || typeof from === "function") {
for (let key of __getOwnPropNames(from))
if (!__hasOwnProp.call(to, key) && key !== except)
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
}
return to;
};
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
var VisHtmlTable_exports = {};
__export(VisHtmlTable_exports, {
VisHtmlTable: () => VisHtmlTable
});
module.exports = __toCommonJS(VisHtmlTable_exports);
class VisHtmlTable {
adapter;
htmlVal;
stateVal;
lang;
/**
* @param adapter ioBroker
*/
constructor(adapter) {
this.adapter = adapter;
this.htmlVal = {};
this.stateVal = {};
this.lang = "de";
}
/**
* @param id ID
* @param val Value state
*/
async changeEnabled(id, val) {
if (!this.adapter.config.usehtml) {
return;
}
this.adapter.log.debug(`changeEnabled: ${id} - ${JSON.stringify(val)}`);
const value = typeof val === "boolean" ? val : val == null ? void 0 : val.val;
if (value != null) {
this.stateVal[id.replace(".enabled", ".data")].enabled = value;
await this.createHTML();
}
}
/**
* @param id ID
* @param val Value state
*/
async changeHTML(id, val) {
if (!this.adapter.config.usehtml) {
return;
}
this.adapter.log.debug(`changeHTML: ${id} - ${JSON.stringify(val)}`);
if (val != null && val.val != null) {
this.htmlVal[id] = val.val;
await this.createHTML();
}
}
/**
* updateHTML
*/
async updateHTML() {
if (!this.adapter.config.usehtml) {
return;
}
await this.createHTML();
}
/**
* @param id ID
* @param val Value State
* @param first boolean
*/
async changeTrigger(id, val, first = true) {
if (!this.adapter.config.usehtml) {
return;
}
this.adapter.log.debug(`changeTrigger: ${id} - ${JSON.stringify(val)} - ${first}`);
const values = typeof val === "string" ? val : val == null ? void 0 : val.val;
if (id != void 0 && values != null) {
const enabled = await this.adapter.getStateAsync(id.replace(".data", ".enabled"));
const value = typeof values === "string" ? JSON.parse(values) : values;
value.enabled = enabled != null && enabled.val != null ? enabled.val : false;
this.stateVal[id] = value;
if (first) {
await this.createHTML();
}
}
}
async createHTML() {
this.adapter.log.debug(`Start update HTML!`);
if (typeof this.stateVal === "object" && Object.keys(this.stateVal).length === 0) {
return;
}
const id = this.htmlVal;
let text = "";
let count = 0;
let countall = 0;
const now = /* @__PURE__ */ new Date();
const today_style = {
0: "",
1: "",
2: "",
3: "",
4: "",
5: "",
6: "",
7: ""
};
today_style[(/* @__PURE__ */ new Date()).getDay()] = " font-weight:bold;";
for (const state in this.stateVal) {
const data = this.stateVal[state];
let devices = "";
let status = "";
const next_event = ["", "", "", "", "", "", ""];
let triggers = "";
let iTag = "";
let iTagEnd = "";
let font_text_color = id.font_color_text_enabled;
if (!data.enabled) {
iTag = `<i>`;
iTagEnd = `</i>`;
font_text_color = id.font_color_text_disabled;
}
let counter = 0;
let nextDateTime = 0;
let nextDateTimeIcon = 0;
let nextaction = "";
const nextName = [];
for (const trigger of data.triggers) {
++countall;
nextDateTimeIcon = nextDateTime;
let change_times = "";
let times = "";
let action = "";
++counter;
const nextNameData = {
getDate: 0,
date: /* @__PURE__ */ new Date(),
action: ""
};
const isodd = counter % 2 != 0 ? id.background_color_even : id.background_color_odd;
let addDate = 0;
if (trigger.type === "TimeTrigger") {
if (trigger.hour === 0 && trigger.minute === 0) {
addDate = 1;
}
const switchTime = /* @__PURE__ */ new Date(
`${now.getFullYear()}-${now.getMonth() + 1}-${now.getDate() + addDate} ${trigger.hour}:${trigger.minute}`
);
if (switchTime >= now && trigger.weekdays.includes(now.getDay())) {
nextDateTime = await this.nextEvent(now.getDay(), nextDateTime);
} else {
const t = await this.nextDateSwitch(/* @__PURE__ */ new Date(), trigger);
nextDateTime = await this.nextEvent(new Date(t).getDay(), nextDateTime);
}
nextNameData.getDate = nextDateTime;
nextNameData.date = switchTime;
times = `${trigger.hour.toString().padStart(2, "0")}:${trigger.minute.toString().padStart(2, "0")}`;
change_times = `<input type="time" id="nexttime${countall}" value="${times}" required /> <input for="nexttime" type="button" value="save" onclick="sendToTime('${this.adapter.namespace}', 'time', '${trigger.id}', '${state}', '${countall}')" /> `;
} else if (trigger.type === "AstroTrigger") {
if (new Date(trigger.todayTrigger.date) >= now) {
nextDateTime = new Date(trigger.todayTrigger.date).getDay();
} else {
nextDateTime = await this.nextEvent(new Date(trigger.todayTrigger.date).getDay(), nextDateTime);
}
nextNameData.getDate = nextDateTime;
nextNameData.date = new Date(trigger.todayTrigger.date);
times = `${trigger.todayTrigger.hour.toString().padStart(2, "0")}:${trigger.todayTrigger.minute.toString().padStart(2, "0")}`;
change_times = `<select id="timeselect${countall}">
<option value="sunrise" ${trigger.astroTime === "sunrise" ? 'selected="selected"' : ""}>
${await this.helper_translator("sunrise")}</option>
<option value="solarNoon" ${trigger.astroTime === "solarNoon" ? 'selected="selected"' : ""}>
${await this.helper_translator("solarNoon")}</option>
<option value="sunset" ${trigger.astroTime === "sunset" ? 'selected="selected"' : ""}>
${await this.helper_translator("sunset")}</option>
</select>
<input size="2px" type="number" id="shift${countall}" min="-120" max="120" step="1" placeholder="00" required value="${trigger.shiftInMinutes}" />
<input for="timeselect${countall}" type="button" value="save" onclick="sendToAstro('${this.adapter.namespace}', 'astro', '${state}', '${trigger.id}', '${countall}')" />`;
} else if (trigger.type === "OneTimeTrigger") {
nextDateTime = await this.nextEvent(new Date(trigger.date).getDay(), nextDateTime);
if (await this.getWeek(new Date(trigger.date)) === await this.getWeek(/* @__PURE__ */ new Date())) {
trigger.weekdays = [(/* @__PURE__ */ new Date()).getDay()];
}
nextNameData.getDate = nextDateTime;
nextNameData.date = new Date(trigger.date);
times = `${new Date(trigger.date).getHours().toString().padStart(2, "0")}:${new Date(trigger.date).getMinutes().toString().padStart(2, "0")}`;
change_times = `<input class="datetime" type="datetime-local" name="datetime" id="datetime${countall}" value="${this.adapter.formatDate(new Date(trigger.date), "YYYY-MM-DD hh:mm")}"min="${this.adapter.formatDate(/* @__PURE__ */ new Date(), "YYYY-MM-DD hh:mm")}"max="${this.adapter.formatDate(new Date((/* @__PURE__ */ new Date()).setFullYear((/* @__PURE__ */ new Date()).getFullYear() + 1)), "YYYY-MM-DD hh:mm")}"required /><input for="datetime${countall}" type="button" value="save" onclick="sendToDateTime('${this.adapter.namespace}', 'datetime', '${trigger.id}', '${state}', '${countall}')" /> `;
}
if (trigger.action && trigger.action.type === "ConditionAction") {
const iconCon = trigger.action.action.name === "On" ? id.icon_true : id.icon_false;
action = ` ${iTag}${trigger.action.condition.constant}${trigger.action.condition.sign}${trigger.action.condition.constant}${iTagEnd} ${iconCon}`;
if (nextDateTimeIcon != nextDateTime) {
nextaction = iconCon;
}
nextNameData.action = iconCon;
}
if (trigger.action && trigger.action.type === "OnOffStateAction") {
const icon = trigger.action.name === "On" ? id.icon_true : id.icon_false;
action = ` ${icon}`;
if (nextDateTimeIcon != nextDateTime) {
nextaction = icon;
}
nextNameData.action = icon;
}
triggers += `
<tr style="background-color:${isodd};
color:${font_text_color};
font-weight:"bold";
font-size:${id.header_font_size}px;">
<td style="text-align:${id.column_align_row_01}">
<label for="delete${countall}">${iTag}${trigger.type}${iTagEnd}</label> 
<input type="checkbox" id="delete${countall}" name="delete${countall}" />
<input for="delete${countall}" type="button" value="delete" onclick="deleteTrigger('${this.adapter.namespace}', 'delete-trigger', '${trigger.id}', '${state}', '${countall}')" /></td>
<td title="${times}" style="text-align:${id.column_align_row_02}">${change_times}</td>
<td title="${times}" style="text-align:${id.column_align_row_03}">${iTag}${times}${iTagEnd}${action}</td>
<td id="weekday" onClick="changeweekdays('${this.adapter.namespace}', 'week', '${state}', '${trigger.id}', 1, '${trigger.type}')" style="text-align:${id.column_align_row_04}; ${today_style[1]} color:${trigger.weekdays && trigger.weekdays.includes(1) ? id.font_color_weekdays_enabled : id.font_color_weekdays_disabled};">${iTag}${id.column_text_04}${iTagEnd}</td>
<td id="weekday" onClick="changeweekdays('${this.adapter.namespace}', 'week', '${state}', '${trigger.id}', 2, '${trigger.type}')" style="text-align:${id.column_align_row_05}; ${today_style[2]} color:${trigger.weekdays && trigger.weekdays.includes(2) ? id.font_color_weekdays_enabled : id.font_color_weekdays_disabled};">${iTag}${id.column_text_05}${iTagEnd}</td>
<td id="weekday" onClick="changeweekdays('${this.adapter.namespace}', 'week', '${state}', '${trigger.id}', 3, '${trigger.type}')" style="text-align:${id.column_align_row_06}; ${today_style[3]} color:${trigger.weekdays && trigger.weekdays.includes(3) ? id.font_color_weekdays_enabled : id.font_color_weekdays_disabled};">${iTag}${id.column_text_06}${iTagEnd}</td>
<td id="weekday" onClick="changeweekdays('${this.adapter.namespace}', 'week', '${state}', '${trigger.id}', 4, '${trigger.type}')" style="text-align:${id.column_align_row_07}; ${today_style[4]} color:${trigger.weekdays && trigger.weekdays.includes(4) ? id.font_color_weekdays_enabled : id.font_color_weekdays_disabled};">${iTag}${id.column_text_07}${iTagEnd}</td>
<td id="weekday" onClick="changeweekdays('${this.adapter.namespace}', 'week', '${state}', '${trigger.id}', 5, '${trigger.type}')" style="text-align:${id.column_align_row_08}; ${today_style[5]} color:${trigger.weekdays && trigger.weekdays.includes(5) ? id.font_color_weekdays_enabled : id.font_color_weekdays_disabled};">${iTag}${id.column_text_08}${iTagEnd}</td>
<td id="weekday" onClick="changeweekdays('${this.adapter.namespace}', 'week', '${state}', '${trigger.id}', 6, '${trigger.type}')" style="text-align:${id.column_align_row_09}; ${today_style[6]} color:${trigger.weekdays && trigger.weekdays.includes(6) ? id.font_color_weekdays_enabled : id.font_color_weekdays_disabled};">${iTag}${id.column_text_09}${iTagEnd}</td>
<td id="weekday" onClick="changeweekdays('${this.adapter.namespace}', 'week', '${state}', '${trigger.id}', 0, '${trigger.type}')" style="text-align:${id.column_align_row_10}; ${today_style[0]} color:${trigger.weekdays && trigger.weekdays.includes(0) ? id.font_color_weekdays_enabled : id.font_color_weekdays_disabled};">${iTag}${id.column_text_10}${iTagEnd}</td>
</tr>`;
nextName.push(nextNameData);
}
if (nextDateTime < 8) {
if (nextDateTime === 7) {
nextDateTime = 0;
}
next_event[nextDateTime] = await this.nextAction(nextDateTime, nextName, nextaction);
}
if (data.onAction && data.onAction.idsOfStatesToSet) {
if (data.onAction.idsOfStatesToSet[0] !== "default.state") {
for (const dev of data.onAction.idsOfStatesToSet) {
if (devices == "") {
devices = dev;
} else {
devices += `<br/>${dev}`;
}
}
}
}
const val_enabled = data.enabled ? false : true;
status = `${data.onAction.onValue}/${data.onAction.offValue} ${data.enabled ? id.icon_true : id.icon_false}`;
const status_icon = data.enabled ? "green" : "red";
text += `
<tr style="background-color:${id.background_color_trigger};
color:${font_text_color};
font-weight:"bold";
font-size:${id.header_font_size}px;">
<td style="text-align:${id.column_align_row_01}">
<button
style="border:none;
background-color:transparent;
color:${status_icon};
font-size:${id.column_width_01}px;
text-align:left"
value="${val_enabled}" onclick="setState('${state.replace("data", "enabled")}', this.value)">${id.icon_switch_symbol}
</button>  ${iTag}${data.name} (${count})${iTagEnd}</td>
<td title="${devices}" style="text-align:${id.column_align_row_02}">${iTag}${devices}${iTagEnd}</td>
<td title="${status}" style="text-align:${id.column_align_row_03}">${iTag}${status}${iTagEnd}</td>
<td style="text-align:${id.column_align_row_04};">${next_event[1]}</td>
<td style="text-align:${id.column_align_row_05};">${next_event[2]}</td>
<td style="text-align:${id.column_align_row_06};">${next_event[3]}</td>
<td style="text-align:${id.column_align_row_07};">${next_event[4]}</td>
<td style="text-align:${id.column_align_row_08};">${next_event[5]}</td>
<td style="text-align:${id.column_align_row_09};">${next_event[6]}</td>
<td style="text-align:${id.column_align_row_10};">${next_event[0]}</td>
</tr>`;
text += triggers;
++count;
}
await this.mergeHTML(text, countall, count);
}
nextAction(nextDateTime, nextName, nextaction) {
const action = nextName.filter((t) => t.getDate === nextDateTime);
if (action && action.length > 0) {
const next = action.sort((a, b) => a.date - b.date);
return next[0].action;
}
return Promise.resolve(nextaction);
}
getWeek(times) {
const onejan = new Date(times.getFullYear(), 0, 1);
const today = new Date(times.getFullYear(), times.getMonth(), times.getDate());
const dayOfYear = (today - onejan + 864e5) / 864e5;
return Promise.resolve(Math.ceil(dayOfYear / 7));
}
nextEvent(actual, next) {
if (actual === 0) {
actual = 7;
}
if (actual > next) {
return Promise.resolve(actual);
}
return Promise.resolve(next);
}
async nextDateSwitch(now, trigger) {
let diffDays = 0;
const nextDay = trigger.weekdays.length === 1 ? trigger.weekdays[0] : await this.nextActiveDay(trigger.weekdays, now.getDay());
if (nextDay > now.getDay()) {
diffDays = nextDay - now.getDay();
} else {
diffDays = nextDay + 7 - now.getDay();
}
const next = new Date(now.setDate(now.getDate() + diffDays));
const hour = trigger.hour != null ? trigger.hour : trigger.todayTrigger.hour;
const minute = trigger.minute != null ? trigger.minute : trigger.todayTrigger.minute;
return (/* @__PURE__ */ new Date(
`${next.getFullYear()}-${next.getMonth() + 1}-${next.getDate()} ${hour}:${minute}`
)).toISOString();
}
nextActiveDay(array, day) {
array = array.map((val) => {
return val === 0 ? 7 : val;
});
const numChecker = (num) => array.find((v) => v > num);
const next = numChecker(day);
return Promise.resolve(next == void 0 ? 0 : next);
}
async mergeHTML(htmltext, countall, count) {
const id = this.htmlVal;
let div = '<div class="container">';
let div_css = `
div.container {
align-items: center;
justify-content: center;
}`;
let min = "";
if (id.jarvis) {
div = "<div>";
div_css = "";
min = "min-width:100%;";
}
const htmlStart = `
<title>Schedule-Switcher</title>
<meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0">
<meta http-equiv="content-type" content="text/html; charset=utf-8">
<style>
* {
margin: 0;
}
body {
background-color: ${id.background_color_body}; margin: 0 auto;
}
p {
padding-top: 10px; padding-bottom: 10px; text-align: ${id.p_tag_text_algin}
}
#updatetime:hover {
cursor: pointer;
}
#weekday:hover {
cursor: pointer;
background-color: ${id.background_color_weekdays_hover};
}
td {
padding:${id.td_tag_cell}px; border:0px solid ${id.td_tag_border_color};
border-right:${id.td_tag_border_right}px solid ${id.td_tag_border_color};
border-bottom:${id.td_tag_border_bottom}px solid ${id.td_tag_border_color};
}
table {
width: ${id.table_tag_width};
margin: ${id.table_tag_text_align};
border:1px solid ${id.table_tag_border_color};
border-spacing: ${id.table_tag_cell}px;
border-collapse: collapse;
}
${div_css}
thread {
display: table-header-group;
}
tbody {
display: table-row-group;
}
tfoot {
display: table-footer-group
}
</style>
<script>
function deleteTrigger(stateId, command, id, dataid, count) {
var checked = document.getElementById('delete' + count).checked;
if (checked) {
var data = {
"triggerId": id,
"dataId": dataid,
};
this.servConn._socket.emit("sendTo", stateId, command, data);
}
}
function changeweekdays(stateId, command, dataid, id, changeid, type) {
if (type === "OneTimeTrigger") return;
var data = {
"changeid": changeid,
"triggerid": id,
"dataid": dataid
};
this.servConn._socket.emit("sendTo", stateId, command, data);
}
function updateTrigger(stateId) {
this.servConn._socket.emit("setState", stateId + '.html.update', true);
}
function setState(stateId, value) {
this.servConn._socket.emit("setState", stateId, value == "false" ? false : true);
}
function sendToAstro(stateId, command, dataid, id, count) {
var timeselect = document.getElementById('timeselect' + count).value;
var shift = document.getElementById('shift' + count).value;
var data = {
"astrotime": timeselect,
"shift": shift,
"triggerid": id,
"dataid": dataid
};
this.servConn._socket.emit("sendTo", stateId, command, data);
}
function sendToDateTime(stateId, command, id, dataid, count) {
var value = document.getElementById('datetime' + count).value;
var data = {
"time": value,
"triggerid": id,
"dataid": dataid
};
this.servConn._socket.emit("sendTo", stateId, command, data);
}
function sendToTime(stateId, command, id, dataid, count) {
var value = document.getElementById('nexttime' + count).value;
var data = {
"time": value,
"triggerid": id,
"dataid": dataid
};
this.servConn._socket.emit("sendTo", stateId, command, data);
}
</script>
${div}
<table style="${min} width:${id.header_width};
border:${id.header_border}px; border-color:${id.header_tag_border_color};
font-size:${id.header_font_size}px; font-family:${id.header_font_family};
background-image: linear-gradient(42deg,${id.header_linear_color_2},
${id.header_linear_color_1});">
<thead>
<tr>
<th colspan="10" scope="colgroup">
<p onClick="updateTrigger('${this.adapter.namespace}')"
id="updatetime" style="color:${id.top_text_color}; font-family:${id.top_font_family};
font-size:${id.top_font_size}px; font-weight:${id.top_font_weight}">
${id.top_text}  ${await this.helper_translator("top_last_update")}
${this.adapter.formatDate(/* @__PURE__ */ new Date(), "TT.MM.JJJJ hh:mm:ss")}</p></th>
</tr>
<tr style="color:${id.headline_color}; height:${id.headline_height}px;
font-size: ${id.headline_font_size}px; font-weight: ${id.headline_weight};
border-bottom: ${id.headline_underlined}px solid ${id.headline_underlined_color}">
<th style="text-align:${id.column_align_01}; width:${id.column_width_01}">
${id.column_text_01}
</th>
<th style="text-align:${id.column_align_02}; width:${id.column_width_02}">
${id.column_text_02}
</th>
<th style="text-align:${id.column_align_03}; width:${id.column_width_03}">
${id.column_text_03}
</th>
<th style="text-align:${id.column_align_04}; width:${id.column_width_04}">
${id.column_text_04}
</th>
<th style="text-align:${id.column_align_05}; width:${id.column_width_05}">
${id.column_text_05}
</th>
<th style="text-align:${id.column_align_06}; width:${id.column_width_06}">
${id.column_text_06}
</th>
<th style="text-align:${id.column_align_07}; width:${id.column_width_07}">
${id.column_text_07}
</th>
<th style="text-align:${id.column_align_08}; width:${id.column_width_08}">
${id.column_text_08}
</th>
<th style="text-align:${id.column_align_09}; width:${id.column_width_09}">
${id.column_text_09}
</th>
<th style="text-align:${id.column_align_10}; width:${id.column_width_10}">
${id.column_text_10}
</th>
</tr>
</thead>
<tfoot>
<tr>
<th colspan="10" scope="colgroup">
<p style="color:${id.top_text_color}; font-family:${id.top_font_family};
font-size:${id.top_font_size}px; font-weight:${id.top_font_weight}">
${await this.helper_translator("footerobject")}  ${count}</br>
${await this.helper_translator("footer")}  ${countall}</p></th>
</tr>
</tfoot>
<tbody>
${htmltext}
</tbody>
</table></div>`;
await this.adapter.setState(`html.html_code`, {
val: htmlStart,
ack: true
});
}
helper_translator(word) {
const all = {
top_last_update: {
en: "Last update:",
de: "Letzte Aktualisierung:",
ru: "\u041F\u043E\u0441\u043B\u0435\u0434\u043D\u0435\u0435 \u043E\u0431\u043D\u043E\u0432\u043B\u0435\u043D\u0438\u0435:",
pt: "\xDAltima atualiza\xE7\xE3o:",
nl: "Laatste update:",
fr: "Derni\xE8re mise \xE0 jour :",
it: "Ultimo aggiornamento:",
es: "\xDAltima actualizaci\xF3n:",
pl: "Ostatnia aktualizacja",
uk: "\u041E\u0441\u0442\u0430\u043D\u043D\u0454 \u043E\u043D\u043E\u0432\u043B\u0435\u043D\u043D\u044F:",
"zh-cn": "\u4E0A\u6B21\u66F4\u65B0:"
},
footer: {
en: "Total trigger",
de: "Gesamtausl\xF6sung",
ru: "\u041E\u0431\u0449\u0438\u0439 \u0442\u0440\u0438\u0433\u0433\u0435\u0440",
pt: "Total de gatilho",
nl: "Totaal trigger",
fr: "D\xE9clencheur total",
it: "Attacco totale",
es: "Total disparador",
pl: "Wy\u0142\u0105cznik ca\u0142kowity",
uk: "\u0417\u0430\u0433\u0430\u043B\u044C\u043D\u0438\u0439 \u0442\u0440\u0438\u0433\u0435\u0440",
"zh-cn": "\u603B\u89E6\u53D1\u6570"
},
footerobject: {
en: "Total objects",
de: "Objekte insgesamt",
ru: "\u0412\u0441\u0435\u0433\u043E \u043E\u0431\u044A\u0435\u043A\u0442\u043E\u0432",
pt: "Objetos totais",
nl: "Totaal objecten",
fr: "Total des objets",
it: "Oggetti totali",
es: "Total de objetos",
pl: "Ca\u0142kowita liczba obiekt\xF3w",
uk: "\u0412\u0441\u044C\u043E\u0433\u043E \u043E\u0431'\u0454\u043A\u0442\u0456\u0432",
"zh-cn": "\u76EE\u6807\u5171\u8BA1"
},
sunrise: {
en: "Sunrise",
de: "Sonnenaufgang",
ru: "\u0412\u043E\u0441\u0445\u043E\u0434",
pt: "Nascer do sol",
nl: "zonsopkomst",
fr: "lever du soleil",
it: "Alba",
es: "amanecer",
pl: "wsch\xF3d s\u0142o\u0144ca",
uk: "\u0421\u0445\u0456\u0434 \u0441\u043E\u043D\u0446\u044F",
"zh-cn": "\u65E5\u51FA"
},
sunset: {
en: "Sunset",
de: "Sonnenuntergang",
ru: "\u0417\u0430\u043A\u0430\u0442 \u0441\u043E\u043B\u043D\u0446\u0430",
pt: "P\xF4r do sol",
nl: "Zonsondergang",
fr: "Le coucher du soleil",
it: "Tramonto",
es: "Puesta de sol",
pl: "Zach\xF3d s\u0142o\u0144ca",
uk: "\u0417\u0430\u0445\u0456\u0434 \u0441\u043E\u043D\u0446\u044F",
"zh-cn": "\u65E5\u843D"
},
solarNoon: {
en: "Noon",
de: "Mittag",
ru: "\u041F\u043E\u043B\u0434\u0435\u043D\u044C",
pt: "Meio-dia",
nl: "Middag",
fr: "Le midi",
it: "Mezzogiorno",
es: "Mediod\xEDa",
pl: "Po\u0142udnie",
uk: "\u043F\u043E\u043B\u0443\u0434\u0435\u043D\u044C",
"zh-cn": "\u4E2D\u5348"
}
};
return all[word][this.lang];
}
/**
* @param lang Lang
*/
async createStates(lang) {
this.lang = lang;
this.adapter.log.info(`Create HTML states!`);
let common = {};
let val;
common = {
name: "HTML",
desc: "HTML"
};
await this.createDataPoint("html", common, "folder");
common = {
type: "string",
role: "level.color.rgb",
name: {
en: "Heading underlined color",
de: "Heading unterstrichene Farbe",
ru: "\u0417\u0430\u0433\u043E\u043B\u043E\u0432\u043E\u043A \u043F\u043E\u0434\u0447\u0435\u0440\u043A\u043D\u0443\u0442\u044B\u0439 \u0446\u0432\u0435\u0442",
pt: "Cor sublinhada de cabe\xE7a",
nl: "Vertaling:",
fr: "T\xEAte de couleur soulign\xE9e",
it: "Intestazione colore sottolineato",
es: "Cabeza de color subrayado",
pl: "G\u0142owa podkre\u015Blona koloru",
uk: "\u041F\u043E\u0434\u0430\u0454\u0442\u044C\u0441\u044F \u0437\u0433\u0456\u0434\u043D\u043E \u0437 \u043A\u043E\u043B\u044C\u043E\u0440\u043E\u043C",
"zh-cn": "\u6807\u9898\u7A81\u51FA\u5F3A\u8C03\u989C\u8272"
},
desc: "Heading underlined color",
read: true,
write: true,
def: "#ffffff"
};
await this.createDataPoint("html.headline_underlined_color", common, "state");
val = await this.adapter.getStateAsync("html.headline_underlined_color");
this.htmlVal.headline_underlined_color = val == null ? void 0 : val.val;
common = {
type: "number",
role: "value",
name: {
en: "Heading underlined",
de: "Unterstrichen",
ru: "\u0417\u0430\u0433\u043E\u043B\u043E\u0432\u043E\u043A \u043F\u043E\u0434\u0447\u0435\u0440\u043A\u043D\u0443\u0442",
pt: "Rubrica sublinhada",
nl: "Ondersteuning",
fr: "Heading underlined",
it: "Denominazione sottolineata",
es: "Encabezamiento subrayado",
pl: "Headlong underlined",
uk: "\u041F\u043E\u0434\u0430\u0454\u0442\u044C\u0441\u044F \u0437\u0433\u0456\u0434\u043D\u043E \u0437",
"zh-cn": "\u6807\u9898\u5F3A\u8C03"
},
desc: "Heading underlined",
read: true,
write: true,
def: 3,
unit: "px"
};
await this.createDataPoint("html.headline_underlined", common, "state");
val = await this.adapter.getStateAsync("html.headline_underlined");
this.htmlVal.headline_underlined = val == null ? void 0 : val.val;
common = {
type: "string",
role: "state",
name: {
en: "Headline font weight",
de: "Headline Schriftst\xE4rke",
ru: "\u0412\u0435\u0441 \u0448\u0440\u0438\u0444\u0442\u0430 \u0437\u0430\u0433\u043E\u043B\u043E\u0432\u043A\u0430",
pt: "Peso da fonte do t\xEDtulo",
nl: "Hoofdlettertypegewicht",
fr: "Poids de la police en t\xEAte",
it: "Headline font peso",
es: "Headline font weight",
pl: "Masa czcionki nag\u0142\xF3wka",
uk: "\u0412\u0430\u0433\u0430 \u0448\u0440\u0438\u0444\u0442\u0443",
"zh-cn": "\u5934\u6761\u5B57\u4F53\u91CD\u91CF"
},
desc: "Headline font weight",
read: true,
write: true,
def: "normal",
states: {
normal: "normal",
bold: "bold"
}
};
await this.createDataPoint("html.headline_weight", common, "state");
val = await this.adapter.getStateAsync("html.headline_weight");
this.htmlVal.headline_weight = val == null ? void 0 : val.val;
common = {
type: "number",
role: "value",
name: {
en: "Headline font size",
de: "Headline Schriftgr\xF6\xDFe",
ru: "\u0420\u0430\u0437\u043C\u0435\u0440 \u0448\u0440\u0438\u0444\u0442\u0430 Headline",
pt: "Tamanho da fonte do t\xEDtulo",
nl: "Hoofdlijn lettertype",
fr: "Headline font size",
it: "Formato del carattere",
es: "Tama\xF1o de la fuente",
pl: "Fontanny",
uk: "\u0420\u043E\u0437\u043C\u0456\u0440 \u043E\u0441\u043D\u043E\u0432\u043D\u043E\u0433\u043E \u0448\u0440\u0438\u0444\u0442\u0443",
"zh-cn": "\u5BFC \u8A00"
},
desc: "Headline height",
read: true,
write: true,
def: 16,
unit: "px"
};
await this.createDataPoint("html.headline_font_size", common, "state");
val = await this.adapter.getStateAsync("html.headline_font_size");
this.htmlVal.headline_font_size = val == null ? void 0 : val.val;
common = {
type: "number",
role: "value",
name: {
en: "Headline height",
de: "Kopfh\xF6he",
ru: "\u0412\u044B\u0441\u043E\u0442\u0430 \u0437\u0430\u0433\u043E\u043B\u043E\u0432\u043A\u0430",
pt: "Altura do t\xEDtulo",
nl: "Hoofdlijn lengte",
fr: "Hauteur de la t\xEAte",
it: "Altezza della testa",
es: "Altura del t\xEDtulo",
pl: "Headline height",
uk: "\u0412\u0438\u0441\u043E\u0442\u0430 \u043B\u0456\u043D\u0456\u0457",
"zh-cn": "\u6807\u9898\u9AD8"
},
desc: "Headline height",
read: true,
write: true,
def: 35,
unit: "px"
};
await this.createDataPoint("html.headline_height", common, "state");
val = await this.adapter.getStateAsync("html.headline_height");
this.htmlVal.headline_height = val == null ? void 0 : val.val;
common = {
type: "string",
role: "level.color.rgb",
name: {
en: "Headline color",
de: "Kopffarbe",
ru: "\u0426\u0432\u0435\u0442 \u0437\u0430\u0433\u043E\u043B\u043E\u0432\u043A\u0430",
pt: "Cor do t\xEDtulo",
nl: "Hoofdlijn kleur",
fr: "Couleur Headline",
it: "Colore della testa",
es: "Color de encabezado",
pl: "Kolor",
uk: "\u041A\u043E\u043B\u0456\u0440 \u043B\u0456\u043D\u0456\u0457",
"zh-cn": "\u6807\u9898"
},
desc: "Headline color",
read: true,
write: true,
def: "#ffffff"
};
await this.createDataPoint("html.headline_color", common, "state");
val = await this.adapter.getStateAsync("html.headline_color");
this.htmlVal.headline_color = val == null ? void 0 : val.val;
common = {
type: "string",
role: "state",
name: {
en: "TOP text",
de: "TOP-Text",
ru: "\u0422\u041E\u041F-\u0442\u0435\u043A\u0441\u0442",
pt: "Texto do TOP",
nl: "Top",
fr: "Texte TOP",
it: "Testo TOP",
es: "Texto de la p\xE1gina",
pl: "Tekst TOP",
uk: "\u0413\u043E\u043B\u043E\u0432\u043D\u0430",
"zh-cn": "\u6848\u6587"
},
desc: "TOP text",
read: true,
write: true,
def: "your text"
};
await this.createDataPoint("html.top_text", common, "state");
val = await this.adapter.getStateAsync("html.top_text");
this.htmlVal.top_text = val == null ? void 0 : val.val;
common = {
type: "string",
role: "state",
name: {
en: "TOP font weight",
de: "TOP Schriftst\xE4rke",
ru: "TOP \u0432\u0435\u0441 \u0448\u0440\u0438\u0444\u0442\u0430",
pt: "Peso da fonte TOP",
nl: "ToP font gewicht",
fr: "Poids de police TOP",
it: "TOP font peso",
es: "TOP font weight",
pl: "TOP",
uk: "\u041C\u0430\u043A\u0441\u0438\u043C\u0430\u043B\u044C\u043D\u0430 \u0432\u0430\u0433\u0430 \u0448\u0440\u0438\u0444\u0442\u0443",
"zh-cn": "\u6392 \u6743"
},
desc: "TOP font weight",
read: true,
write: true,
def: "normal",
states: {
normal: "normal",
bold: "bold"
}
};
await this.createDataPoint("html.top_font_weight", common, "state");
val = await this.adapter.getStateAsync("html.top_font_weight");
this.htmlVal.top_font_weight = val == null ? void 0 : val.val;
common = {
type: "number",
role: "value",
name: {
en: "TOP font size",
de: "TOP Schriftgr\xF6\xDFe",
ru: "TOP \u0440\u0430\u0437\u043C\u0435\u0440 \u0448\u0440\u0438\u0444\u0442\u0430",
pt: "Tamanho da fonte TOP",
nl: "ToP font maat",
fr: "Taille de police TOP",
it: "Dimensione del carattere TOP",
es: "Tama\xF1o de fuente TOP",
pl: "TOP",
uk: "\u0420\u043E\u0437\u043C\u0456\u0440 \u0448\u0440\u0438\u0444\u0442\u0443",
"zh-cn": "\u6392 \u5EA6"
},
desc: "TOP font size",
read: true,
write: true,
def: 20,
unit: "px"
};
await this.createDataPoint("html.top_font_size", common, "state");
val = await this.adapter.getStateAsync("html.top_font_size");
this.htmlVal.top_font_size = val == null ? void 0 : val.val;
common = {
type: "string",
role: "state",
name: {
en: "TOP font",
de: "TOP Schriftart",
ru: "TOP \u0448\u0440\u0438\u0444\u0442",
pt: "Fonte TOP",
nl: "Top font",
fr: "Police TOP",
it: "TOP font",
es: "Fuente TOP",
pl: "TOP",
uk: "\u0422\u043E\u043F \u0448\u0440\u0438\u0444\u0442",
"zh-cn": "\u4E09\u3001\u7ED3 \u8BBA"
},
desc: "TOP font",
read: true,
write: true,
def: "Helvetica"
};
await this.createDataPoint("html.top_font_family", common, "state");
val = await this.adapter.getStateAsync("html.top_font_family");
this.htmlVal.top_font_family = val == null ? void 0 : val.val;
common = {
type: "string",
role: "level.color.rgb",
name: {
en: "TOP text color",
de: "TOP Textfarbe",
ru: "\u0422\u041E\u041F \u0446\u0432\u0435\u0442 \u0442\u0435\u043A\u0441\u0442\u0430",
pt: "Cor de texto TOP",
nl: "Top sms kleur",
fr: "Couleur du texte TOP",
it: "Colore del testo TOP",
es: "Color de texto",
pl: "Ok\u0142adka",
uk: "\u041A\u043E\u043B\u0456\u0440 \u0442\u0435\u043A\u0441\u0442\u0443",
"zh-cn": "\u6848\u6587"
},
desc: "TOP text color",
read: true,
write: true,
def: "#ffffff"
};
await this.createDataPoint("html.top_text_color", common, "state");
val = await this.adapter.getStateAsync("html.top_text_color");
this.htmlVal.top_text_color = val == null ? void 0 : val.val;
common = {
type: "string",
role: "level.color.rgb",
name: {
en: "TAG <table> header linear color 2.",
de: "TAG <table> Header lineare Farbe 2.",
ru: "TAG <table> \u043B\u0438\u043D\u0435\u0439\u043D\u044B\u0439 \u0446\u0432\u0435\u0442 2.",
pt: "Cor linear de cabe\xE7alho TAG <table> 2.",
nl: "Tag <table> hoofd lineaire kleur 2.",
fr: "Couleur lin\xE9aire TAG <table> en-t\xEAte 2.",
it: "TAG <table> intestazione colore lineare 2.",
es: "TAG <table> Header linear color 2.",
pl: "TAG <table> koloru liniowego 2.",
uk: "TAG <table> \u0437\u0430\u0433\u043E\u043B\u043E\u0432\u043E\u043A \u043B\u0456\u043D\u0456\u0439\u043D\u043E\u0433\u043E \u043A\u043E\u043B\u044C\u043E\u0440\u0443 2.",
"zh-cn": "TAG <table>\u5934\u5BF8ar\u989C\u82722."
},
desc: "TAG <table> header linear color 2.",
read: true,
write: true,
def: "#BDBDBD"
};
await this.createDataPoint("html.header_linear_color_2", common, "state");
val = await this.adapter.getStateAsync("html.header_linear_color_2");
this.htmlVal.header_linear_color_2 = val == null ? void 0 : val.val;
common = {
type: "string",
role: "level.color.rgb",
name: {
en: "TAG <table> header linear color 1.",
de: "TAG <table> Header lineare Farbe 1.",
ru: "TAG <table> \u043B\u0438\u043D\u0435\u0439\u043D\u044B\u0439 \u0446\u0432\u0435\u0442 1.",
pt: "Cor linear de cabe\xE7alho TAG <table> 1.",
nl: "Tag <table> hoofd lineaire kleur 1.",
fr: "Couleur lin\xE9aire TAG <table> en-t\xEAte 1.",
it: "TAG <table> intestazione colore lineare 1.",
es: "TAG <table> Header linear color 1.",
pl: "TAG <table> koloru liniowego 1.",
uk: "TAG <table> \u0437\u0430\u0433\u043E\u043B\u043E\u0432\u043E\u043A \u043B\u0456\u043D\u0456\u0439\u043D\u043E\u0433\u043E \u043A\u043E\u043B\u044C\u043E\u0440\u0443 1.",
"zh-cn": "TAG <table>\u5934\u5BF8ar\u989C\u82721."
},
desc: "TAG <table> header linear color 1.",
read: true,
write: true,
def: "#BDBDBD"
};
await this.createDataPoint("html.header_linear_color_1", common, "state");
val = await this.adapter.getStateAsync("html.header_linear_color_1");
this.htmlVal.header_linear_color_1 = val == null ? void 0 : val.val;
common = {
type: "string",
role: "state",
name: {
en: "TAG <table> header font family.",
de: "TAG <table> Header Schriftfamilie.",
ru: "TAG <table> \u0437\u0430\u0433\u043E\u043B\u043E\u0432\u043E\u043A \u0441\u0435\u043C\u0435\u0439\u0441\u0442\u0432\u0430 \u0448\u0440\u0438\u0444\u0442\u043E\u0432.",
pt: "TAG <table> header font family.",
nl: "TAG-lettertypefamilie <table>.",
fr: "Famille de polices d'en-t\xEAte TAG <table>.",
it: "TAG <table> intestazione famiglia font.",
es: "TAG <table> header font family.",
pl: "Rodzina czcionek TAG <table>.",
uk: "TAG <table> \u0433\u043E\u043B\u043E\u0432\u043A\u0438 \u0441\u0456\u043C\u0435\u0439\u0441\u0442\u0432\u0430 \u0448\u0440\u0438\u0444\u0442\u0456\u0432.",
"zh-cn": "TAG<table>\u5934\u5B57\u4F53\u5BB6\u65CF."
},
desc: "TAG <table> header font family.",
read: true,
write: true,
def: "Helvetica"
};
await this.createDataPoint("html.header_font_family", common, "state");
val = await this.adapter.getStateAsync("html.header_font_family");
this.htmlVal.header_font_family = val == null ? void 0 : val.val;
common = {
type: "number",
role: "value",
name: {
en: "TAG <table> header font size.",
de: "TAG <table> Header Schriftgr\xF6\xDFe.",
ru: "TAG <table> \u0440\u0430\u0437\u043C\u0435\u0440 \u0448\u0440\u0438\u0444\u0442\u0430.",
pt: "TAG <table> tamanho da fonte do cabe\xE7alho.",
nl: "Tag <table> koper lettertype.",
fr: "TAG <table> header font size.",
it: "TAG <table> intestazione formato carattere.",
es: "TAG <table> header font size.",
pl: "TAG <table> \u2013 typ czcionki.",
uk: "TAG <table> \u0440\u043E\u0437\u043C\u0456\u0440 \u0437\u0430\u0433\u043E\u043B\u043E\u0432\u043A\u0430.",
"zh-cn": "TAG <table>\u540D\u5BFC\u5E08\u89C4\u6A21\u3002."
},
desc: "TAG <table> header font size.",
read: true,
write: true,
def: 15,
unit: "px"
};
await this.createDataPoint("html.header_font_size", common, "state");
val = await this.adapter.getStateAsync("html.header_font_size");
this.htmlVal.header_font_size = val == null ? void 0 : val.val;
common = {
type: "number",
role: "value",
name: {
en: "TAG <table> header border.",
de: "TAG <table> Kopfgrenze.",
ru: "TAG <table> \u0433\u0440\u0430\u043D\u0438\u0446\u044B \u0437\u0430\u0433\u043E\u043B\u043E\u0432\u043A\u0430.",
pt: "TAG <table> fronteira de cabe\xE7alho.",
nl: "TAG <table> hoofdgrens.",
fr: "TAG <table> t\xEAte fronti\xE8re.",
it: "TAG <table> bordo intestazione.",
es: "TAG <table> frontera de cabecera.",
pl: "TAG <table> \u2013 granica g\u0142odowa.",
uk: "TAG <table> \u0437\u0430\u0433\u043E\u043B\u043E\u0432\u043E\u043A \u043A\u043E\u0440\u0434\u043E\u043D\u0443.",
"zh-cn": "TAG <table>\u5934\u5BF8\u8FB9\u754C\u3002."
},
desc: "TAG <table> header border.",
read: true,
write: true,
def: 2,
unit: "px"
};
await this.createDataPoint("html.header_border", common, "state");
val = await this.adapter.getStateAsync("html.header_border");
this.htmlVal.header_border = val == null ? void 0 : val.val;
common = {
type: "string",
role: "level.color.rgb",
name: {
en: "TAG <table> header border color.",
de: "TAG <table> Header Randfarbe.",
ru: "TAG <table> \u0446\u0432\u0435\u0442 \u0433\u0440\u0430\u043D\u0438\u0446\u044B \u0437\u0430\u0433\u043E\u043B\u043E\u0432\u043A\u0430.",
pt: "TAG <table> cor da borda do cabe\xE7alho.",
nl: "TAG <table> hoofd grenskleur.",
fr: "TAG <table> couleur de la bordure d'en-t\xEAte.",
it: "TAG <table> intestazione bordo colore.",
es: "TAG <table> de color de borde de cabecera.",
pl: "TAG <table> \u2013 kolor graniczny.",
uk: "TAG <table> \u0437\u0430\u0433\u043E\u043B\u043E\u0432\u043E\u043A \u043F\u0440\u0438\u043A\u043E\u0440\u0434\u043E\u043D\u043D\u043E\u0433\u043E \u043A\u043E\u043B\u044C\u043E\u0440\u0443.",
"zh-cn": "TAG <table>\u5934\u90BB\u3002."
},
desc: "TAG <table> header border color.",
read: true,
write: true,
def: "#424242"
};
await this.createDataPoint("html.header_tag_border_color", common, "state");
val = await this.adapter.getStateAsync("html.header_tag_border_color");
this.htmlVal.header_tag_border_color = val == null ? void 0 : val.val;
common = {
type: "string",
role: "state",
name: {
en: "TAG <table> header width (e.g. auto, 100% or 1080px).",
de: "TAG <table> Kopfbreite (z.B. Auto, 100% oder 1080px.).",
ru: "TAG <table> \u0448\u0438\u0440\u0438\u043D\u0430 \u0437\u0430\u0433\u043E\u043B\u043E\u0432\u043A\u0430 (\u043D\u0430\u043F\u0440\u0438\u043C\u0435\u0440, \u0430\u0432\u0442\u043E, 100% \u0438\u043B\u0438 1080px.).",
pt: "TAG <table> largura do cabe\xE7alho (por exemplo, auto, 100% ou 1080px.).",
nl: "TAG <table> koper width (e.g auto, 100% of 1080px).",
fr: "Largeur d'en-t\xEAte TAG <table> (p. ex. auto, 100% ou 1080px.).",
it: "Larghezza intestazione TAG <table> (ad esempio auto, 100% o 1080px.).",
es: "TAG <table> ancho de cabecera (por ejemplo auto, 100% o 1080px.).",
pl: "TAG <table> (np. auto, 100% lub 1080 KM).",
uk: "TAG <table> \u0448\u0438\u0440\u0438\u043D\u0430 \u0437\u0430\u0433\u043E\u043B\u043E\u0432\u043A\u0430 (\u043D\u0430\u043F\u0440\u0438\u043A\u043B\u0430\u0434, \u0430\u0432\u0442\u043E\u043C\u0430\u0442\u0438\u0447\u043D\u0438\u0439, 100% \u0430\u0431\u043E 1080px).",
"zh-cn": "TAG <table> \u5934\u5DFE(\u5982\u6C7D\u8F66\u3001100%\u62161080px)."
},
desc: "TAG <table> header width (e.g. auto, 100% or 1080px).",
read: true,
write: true,
def: "auto"
};
await this.createDataPoint("html.header_width", common, "state");
val = await this.adapter.getStateAsync("html.header_width");
this.htmlVal.header_width = val == null ? void 0 : val.val;
common = {
type: "number",
role: "value",
name: {
en: "TAG <table> padding",
de: "TAG <table> Padding",
ru: "TAG <table> Padding",
pt: "TAG <table> padding",
nl: "TAG <table> opvulling",
fr: "Rembourrage TAG <table>",
it: "TAG <table> imbottitura",
es: "Acolchado <table> TAG",
pl: "TAG <table> wy\u015Bcie\u0142anie",
uk: "TAG <table> \u043D\u0430\u043F\u043E\u0432\u043D\u044E\u0432\u0430\u0447",
"zh-cn": "TAG <table> \u57AB\u88C5"
},
desc: "TAG <table> padding",
read: true,
write: true,
def: 6,
unit: "px"
};
await this.createDataPoint("html.table_tag_cell", common, "state");
val = await this.adapter.getStateAsync("html.table_tag_cell");
this.htmlVal.table_tag_cell = val == null ? void 0 : val.val;
common = {
type: "string",
role: "level.color.rgb",
name: {
en: "TAG <table> border color",
de: "TAG <table> Grenzfarbe",
ru: "TAG <table> \u043F\u043E\u0433\u0440\u0430\u043D\u0438\u0447\u043D\u044B\u0439 \u0446\u0432\u0435\u0442",
pt: "TAG <table> cor da borda",
nl: "TAG <tabel> randkleur",
fr: "Couleur de la bordure de TAG <table>",
it: "TAG <table> colore di confine",
es: "TAG - color de borde ajustable",
pl: "TAG < table > barwa graniczna",
uk: "TAG <table> \u0431\u043E\u0440\u0434\u043E\u0432\u0438\u0439 \u043A\u043E\u043B\u0456\u0440",
"zh-cn": "TAG < table > \u8FB9\u6846\u989C\u8272"
},
desc: "TAG <table> border color",
read: true,
write: true,
def: "#424242"
};
await this.createDataPoint("html.table_tag_border_color", common, "state");
val = await this.adapter.getStateAsync("html.table_tag_border_color");
this.htmlVal.table_tag_border_color = val == null ? void 0 : val.val;
common = {
type: "string",
role: "state",
name: {
en: "TAG <table> text align",
de: "TAG <table> Text ausrichten",
ru: "TAG <table> \u0442\u0435\u043A\u0441\u0442",
pt: "TAG <table> alinhamento de texto",
nl: "TAG <table> sms-align",
fr: "TAG <table> texte align\xE9",
it: "TAG <table> testo allineare",
es: "TAG <table> texto alineado",
pl: "TAG <table> dopasowa\u0142",
uk: "TAG <table> \u0442\u0435\u043A\u0441\u0442 \u0432\u0438\u0440\u0456\u0432\u043D\u044E\u0432\u0430\u043D\u043D\u044F",
"zh-cn": "TAG<table>\u6848\u6587"
},
desc: "TAG <table> width",
read: true,
write: true,
def: "center",
states: ["center", "left", "right", "auto"]
};
await this.createDataPoint("html.table_tag_text_align", common, "state");
val = await this.adapter.getStateAsync("html.table_tag_text_align");
this.htmlVal.table_tag_text_align = val == null ? void 0 : val.val;
common = {
type: "string",
role: "state",
name: {
en: "TAG <table> width (e.g. auto or 100px)",
de: "TAG <table> Breite (z.B. Auto oder 100px)",
ru: "TAG <table> \u0448\u0438\u0440\u0438\u043D\u0430 (\u043D\u0430\u043F\u0440\u0438\u043C\u0435\u0440, \u0430\u0432\u0442\u043E \u0438\u043B\u0438 100px)",
pt: "TAG <table> largura (por exemplo, auto ou 100px)",
nl: "TAG <table> width (e.g auto of 100px)",
fr: "TAG <table> largeur (p. ex. auto ou 100px)",
it: "Larghezza TAG <table> (ad esempio auto o 100px)",
es: "TAG <table> ancho (por ejemplo auto o 100px)",
pl: "TAG <table> szeroko\u015B\u0107 (np. auto lub 100 KM)",
uk: "TAG <table> \u0448\u0438\u0440\u0438\u043D\u0430 (\u043D\u0430\u043F\u0440\u0438\u043A\u043B\u0430\u0434, \u0430\u0432\u0442\u043E \u0430\u0431\u043E 100px)",
"zh-cn"