diff --git a/pytiled_parser/properties.py b/pytiled_parser/properties.py index d40938c..e0c8af0 100644 --- a/pytiled_parser/properties.py +++ b/pytiled_parser/properties.py @@ -17,19 +17,19 @@ Property = Union[float, Path, str, bool, Color] Properties = Dict[str, Property] -RawProperty = Union[float, str, bool] +RawValue = Union[float, str, bool] -class RawProperties(TypedDict): +class RawProperty(TypedDict): """A dictionary of raw properties.""" name: str type: str - value: RawProperty + value: RawValue -def cast(raw_properties: List[RawProperties]) -> Properties: - """ Cast a list of `RawProperties` into `Properties` +def cast(raw_properties: List[RawProperty]) -> Properties: + """ Cast a list of `RawProperty`s into `Properties` Args: raw_properties: The list of `RawProperty`s to cast. diff --git a/pytiled_parser/tiled_object.py b/pytiled_parser/tiled_object.py index dac1aa8..a96141e 100644 --- a/pytiled_parser/tiled_object.py +++ b/pytiled_parser/tiled_object.py @@ -183,7 +183,7 @@ class RawTiledObject(TypedDict): visible: bool name: str type: str - properties: List[properties_.RawProperties] + properties: List[properties_.RawProperty] ellipse: bool point: bool polygon: List[Dict[str, float]]