14 lines
269 B
Python
14 lines
269 B
Python
from typing import Literal
|
|
|
|
|
|
Metric = Literal["flow", "pressure", "velocity"]
|
|
|
|
DISPLAY_UNITS: dict[Metric, str] = {
|
|
"flow": "m³/h",
|
|
"pressure": "m",
|
|
"velocity": "m/s",
|
|
}
|
|
|
|
def display_unit_for_metric(metric: Metric) -> str:
|
|
return DISPLAY_UNITS[metric]
|