Move translatable URLs out of strings.json for isy994 (#154464)

This commit is contained in:
Anuj Soni
2025-10-14 22:01:01 +05:30
committed by GitHub
parent db48f8cb28
commit 00025c8f42
2 changed files with 16 additions and 4 deletions

View File

@@ -177,6 +177,9 @@ class Isy994ConfigFlow(ConfigFlow, domain=DOMAIN):
step_id="user",
data_schema=_data_schema(self.discovered_conf),
errors=errors,
description_placeholders={
"sample_ip": "http://192.168.10.100:80",
},
)
async def _async_set_unique_id_or_update(
@@ -302,7 +305,10 @@ class Isy994ConfigFlow(ConfigFlow, domain=DOMAIN):
CONF_HOST: existing_data[CONF_HOST],
}
return self.async_show_form(
description_placeholders={CONF_HOST: existing_data[CONF_HOST]},
description_placeholders={
CONF_HOST: existing_data[CONF_HOST],
"sample_ip": "http://192.168.10.100:80",
},
step_id="reauth_confirm",
data_schema=vol.Schema(
{
@@ -347,7 +353,13 @@ class OptionsFlowHandler(OptionsFlowWithReload):
}
)
return self.async_show_form(step_id="init", data_schema=options_schema)
return self.async_show_form(
step_id="init",
data_schema=options_schema,
description_placeholders={
"sample_ip": "http://192.168.10.100:80",
},
)
class InvalidHost(HomeAssistantError):

View File

@@ -9,7 +9,7 @@
"password": "[%key:common::config_flow::data::password%]",
"tls": "The TLS version of the ISY controller."
},
"description": "The host entry must be in full URL format, e.g., http://192.168.10.100:80",
"description": "The host entry must be in full URL format, e.g., {sample_ip}",
"title": "Connect to your ISY"
},
"reauth_confirm": {
@@ -26,7 +26,7 @@
"unknown": "[%key:common::config_flow::error::unknown%]",
"cannot_connect": "[%key:common::config_flow::error::cannot_connect%]",
"invalid_auth": "[%key:common::config_flow::error::invalid_auth%]",
"invalid_host": "The host entry was not in full URL format, e.g., http://192.168.10.100:80"
"invalid_host": "The host entry was not in full URL format, e.g., {sample_ip}"
},
"abort": {
"already_configured": "[%key:common::config_flow::abort::already_configured_device%]",