diff --git a/README.md b/README.md index c0e4b7f..1a982ad 100644 --- a/README.md +++ b/README.md @@ -638,6 +638,9 @@ my_service.status = MyStatus.FAILED ![ColouredEnum Component](docs/images/ColouredEnum_component.png) +**Note** that each enumeration name and value must be unique. +This means that you should use different colour formats when you want to use a colour multiple times. + #### Extending with New Components Users can also extend the library by creating custom components. This involves defining the behavior on the Python backend and the visual representation on the frontend. For those looking to introduce new components, the [guide on adding components](https://pydase.readthedocs.io/en/latest/dev-guide/Adding_Components/) provides detailed steps on achieving this. diff --git a/src/pydase/components/coloured_enum.py b/src/pydase/components/coloured_enum.py index 689a828..9c33539 100644 --- a/src/pydase/components/coloured_enum.py +++ b/src/pydase/components/coloured_enum.py @@ -56,4 +56,9 @@ class ColouredEnum(Enum): my_service = StatusExample() my_service.status = MyStatus.FAILED ``` + + Note + ---- + Each enumeration name and value must be unique. This means that you should use + different colour formats when you want to use a colour multiple times. """