         func edgesToSuperview(excluding excludedEdge: LayoutEdge = .none, insets: TinyEdgeInsets = .zero) -> Constraints {
             var constraints = Constraints()
             
-            if excludedEdge != .top {
+            if !excludedEdge.contains(.top) {
                 constraints.append(topToSuperview(offset: insets.top))
             }
             
-            if excludedEdge != .left {
+            if !excludedEdge.contains(.left) {
                 constraints.append(leftToSuperview(offset: insets.left))
             }
             
-            if excludedEdge != .right {
+            if !excludedEdge.contains(.right) {
                 constraints.append(rightToSuperview(offset: -insets.right))
             }
             
-            if excludedEdge != .bottom {
+            if !excludedEdge.contains(.bottom) {
                 constraints.append(bottomToSuperview(offset: -insets.bottom))
             }
             

    }
#endif

public extension View {
    
    enum LayoutEdge {
        case top
        case bottom
        case trailing
        case leading
        case left
        case right
        case none
    }
    
    
    @discardableResult
    public func centerInSuperview(offset: CGPoint = .zero, priority: LayoutPriority = .required, isActive: Bool = true) -> Constraints {
        guard let superview = superview else { fatalError("Unable to create this constraint to it's superview, because it has no superview.") }

        func edgesToSuperview(excluding excludedEdge: LayoutEdge = .none, insets: TinyEdgeInsets = .zero) -> Constraints {
            var constraints = Constraints()
            
            if !excludedEdge.contains(.top) {
                constraints.append(topToSuperview(offset: insets.top))
            }
            
            if effectiveUserInterfaceLayoutDirection == .leftToRight {
                
                if !(excludedEdge.contains(.leading) || excludedEdge.contains(.left)) {
                    constraints.append(leftToSuperview(offset: insets.left))
                }
                
                if !(excludedEdge.contains(.trailing) || excludedEdge.contains(.right)) {
                    constraints.append(rightToSuperview(offset: -insets.right))
                }
            } else {
                
                if !(excludedEdge.contains(.leading) || excludedEdge.contains(.right)) {
                    constraints.append(rightToSuperview(offset: -insets.right))
                }
                
                if !(excludedEdge.contains(.trailing) || excludedEdge.contains(.left)) {
                    constraints.append(leftToSuperview(offset: insets.left))
                }
            }
            
            if !excludedEdge.contains(.bottom) {
                constraints.append(bottomToSuperview(offset: -insets.bottom))
            }
            
