diff --git a/src/lib.rs b/src/lib.rs index 91b8396..08b3b9a 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -58,21 +58,21 @@ enum KartesianDirection { } impl KartesianDirection { - fn vector>(self) -> Kartesian { + pub fn vector>(self) -> Kartesian { const BELOW: i8 = -1; const ON: i8 = 0; const UPPER: i8 = 1; Kartesian:: { x: match self { - Self::TopLeft | Self::Left | Self::BottomLeft => BELOW.into(), - Self::Top | Self::None | Self::Bottom => ON.into(), - Self::TopRight | Self::Right | Self::BottomRight => UPPER.into(), - }, - y: match self { Self::TopLeft | Self::Top | Self::TopRight => BELOW.into(), Self::Left | Self::None | Self::Right => ON.into(), Self::BottomLeft | Self::Bottom | Self::BottomRight => UPPER.into(), }, + y: match self { + Self::TopLeft | Self::Left | Self::BottomLeft => BELOW.into(), + Self::Top | Self::None | Self::Bottom => ON.into(), + Self::TopRight | Self::Right | Self::BottomRight => UPPER.into(), + }, } } }