import React from "react"; import { TextValidator, ValidatorForm, SelectValidator, } from "react-material-ui-form-validator"; import { Checkbox, TextField, Typography } from "@material-ui/core"; import SaveIcon from "@material-ui/icons/Save"; import MenuItem from "@material-ui/core/MenuItem"; import { RestFormProps, FormActions, FormButton, BlockFormControlLabel, PasswordValidator, } from "../components"; import { isIP, isHostname, or, isPath } from "../validators"; import { MqttSettings } from "./types"; type MqttSettingsFormProps = RestFormProps; class MqttSettingsForm extends React.Component { componentDidMount() { ValidatorForm.addValidationRule("isIPOrHostname", or(isIP, isHostname)); ValidatorForm.addValidationRule("isPath", isPath); } render() { const { data, handleValueChange, saveData } = this.props; return ( } label="Enable MQTT" /> 0 (default) 1 2 } label="Clean Session" /> } label="Retain Flag" />

Formatting nested on a single topic as individual topics by Sensor ID by Number "on"/"off" true/false 1/0 "ON"/"OFF" general device topic individual topics, main heating circuit individual topics, all heating circuits } label="Use Home Assistant MQTT Discovery" /> {data.ha_enabled && ( use Current temperature (default) use Setpoint temperature Fix to 0 )}

Publish Intervals } variant="contained" color="primary" type="submit" > Save
); } } export default MqttSettingsForm;