diff --git a/Segmentio/Source/Cells/SegmentioCell.swift b/Segmentio/Source/Cells/SegmentioCell.swift index af70d89..b7c04c0 100644 --- a/Segmentio/Source/Cells/SegmentioCell.swift +++ b/Segmentio/Source/Cells/SegmentioCell.swift @@ -191,7 +191,7 @@ class SegmentioCell: UICollectionViewCell { attribute: .trailing, relatedBy: .equal, toItem: containerView, - attribute: .trailingMargin, + attribute: .trailing, //changed from .trailingMargin. remove std margin 8pt multiplier: 1.0, constant: 0 ) @@ -200,7 +200,7 @@ class SegmentioCell: UICollectionViewCell { attribute: .leading, relatedBy: .equal, toItem: containerView, - attribute: .leadingMargin, + attribute: .leading, //changed from .leadingMargin. remove std margin 8pt multiplier: 1.0, constant: 0 ) diff --git a/Segmentio/Source/Cells/SegmentioCellWithLabel.swift b/Segmentio/Source/Cells/SegmentioCellWithLabel.swift index ab47b8a..0fcdc54 100644 --- a/Segmentio/Source/Cells/SegmentioCellWithLabel.swift +++ b/Segmentio/Source/Cells/SegmentioCellWithLabel.swift @@ -22,7 +22,7 @@ final class SegmentioCellWithLabel: SegmentioCell { // main constraints let segmentTitleLabelHorizontConstraint = NSLayoutConstraint.constraints( - withVisualFormat: "|-[containerView]-|", + withVisualFormat: "|[containerView]|", //changed from |-[containerView]-|. remove standard space options: [.alignAllCenterX], metrics: nil, views: views