mirror of
https://github.com/home-assistant/core.git
synced 2025-07-19 03:07:37 +00:00
Add missing unit of measurement for tolerance option in proximity (#111876)
This commit is contained in:
parent
b0ed8c4961
commit
2a135b64b6
@ -14,7 +14,7 @@ from homeassistant.config_entries import (
|
|||||||
ConfigFlowResult,
|
ConfigFlowResult,
|
||||||
OptionsFlow,
|
OptionsFlow,
|
||||||
)
|
)
|
||||||
from homeassistant.const import CONF_ZONE
|
from homeassistant.const import CONF_ZONE, UnitOfLength
|
||||||
from homeassistant.core import State, callback
|
from homeassistant.core import State, callback
|
||||||
from homeassistant.helpers.selector import (
|
from homeassistant.helpers.selector import (
|
||||||
EntitySelector,
|
EntitySelector,
|
||||||
@ -54,7 +54,9 @@ def _base_schema(user_input: dict[str, Any]) -> vol.Schema:
|
|||||||
CONF_TOLERANCE,
|
CONF_TOLERANCE,
|
||||||
default=user_input.get(CONF_TOLERANCE, DEFAULT_TOLERANCE),
|
default=user_input.get(CONF_TOLERANCE, DEFAULT_TOLERANCE),
|
||||||
): NumberSelector(
|
): NumberSelector(
|
||||||
NumberSelectorConfig(min=1, max=100, step=1),
|
NumberSelectorConfig(
|
||||||
|
min=1, max=100, step=1, unit_of_measurement=UnitOfLength.METERS
|
||||||
|
),
|
||||||
),
|
),
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user