mirror of
https://github.com/bec-project/bec_widgets.git
synced 2026-05-05 06:16:32 +02:00
12 lines
377 B
Python
12 lines
377 B
Python
from bec_lib.device import Device, Positioner
|
|
|
|
|
|
def map_device_type_to_icon(device_obj: Device) -> str:
|
|
"""Associate device types with material icon names"""
|
|
match device_obj._info.get("device_base_class", "").lower():
|
|
case "positioner":
|
|
return "precision_manufacturing"
|
|
case "signal":
|
|
return "vital_signs"
|
|
return "settings"
|