Skip to content

Commit 9c4f7e7

Browse files
Mark Pospeselmpospese
authored andcommitted
Fix linter violations
1 parent 9e907ac commit 9c4f7e7

File tree

3 files changed

+13
-3
lines changed

3 files changed

+13
-3
lines changed

Sources/YMatterType/Typography/TypographyLayout.swift

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,11 @@ public struct TypographyLayout {
6060
self.paragraphSpacing = paragraphSpacing
6161
self.textCase = textCase
6262
self.textDecoration = textDecoration
63-
self.paragraphStyle = NSParagraphStyle.default.styleWithLineHeight(lineHeight, indent: paragraphIndent, spacing: paragraphSpacing)
63+
self.paragraphStyle = NSParagraphStyle.default.styleWithLineHeight(
64+
lineHeight,
65+
indent: paragraphIndent,
66+
spacing: paragraphSpacing
67+
)
6468
}
6569
}
6670

Tests/YMatterTypeTests/Elements/TypographyLabelTests.swift

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,10 @@ final class TypographyLabelTests: TypographyElementTests {
5656
sut.text = array.joined(separator: "\n")
5757

5858
// we expect label height to be a multiple of lineHeight + paragraph spacing
59-
XCTAssertEqual(sut.intrinsicContentSize.height, sut.typography.lineHeight * CGFloat($0) + spacing * CGFloat($0 - 1))
59+
XCTAssertEqual(
60+
sut.intrinsicContentSize.height,
61+
sut.typography.lineHeight * CGFloat($0) + spacing * CGFloat($0 - 1)
62+
)
6063
// after calling sizeToFit we expect bounds to equal intrinsicContentSize
6164
sut.sizeToFit()
6265
XCTAssertEqual(sut.intrinsicContentSize, sut.bounds.size)

Tests/YMatterTypeTests/Elements/TypographyTextViewTests.swift

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,10 @@ final class TypographyTextViewTests: TypographyElementTests {
5353
sut.text = array.joined(separator: "\n")
5454

5555
// we expect label height to be a multiple of lineHeight + paragraph spacing
56-
XCTAssertEqual(sut.intrinsicContentSize.height, sut.typography.lineHeight * CGFloat($0) + spacing * CGFloat($0 - 1))
56+
XCTAssertEqual(
57+
sut.intrinsicContentSize.height,
58+
sut.typography.lineHeight * CGFloat($0) + spacing * CGFloat($0 - 1)
59+
)
5760
// after calling sizeToFit we expect bounds to equal intrinsicContentSize
5861
sut.sizeToFit()
5962
XCTAssertEqual(sut.intrinsicContentSize, sut.bounds.size)

0 commit comments

Comments
 (0)