Skip to content

Commit 531604e

Browse files
authored
Fix overly long related post titles (#25011)
1 parent e1e459c commit 531604e

File tree

4 files changed

+12
-13
lines changed

4 files changed

+12
-13
lines changed

RELEASE-NOTES.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22
-----
33
* [*] Fix horizontal insets in Reader article view [#25010]
44

5-
65
26.5
76
-----
87
* [*] Add "Status" field to the "Post Settings" screen to make it easier to move posts from one state to another [#24939]
@@ -15,6 +14,7 @@
1514
* [*] Add permalink preview in the slug editor and make other improvements [#24949]
1615
* [*] Add "Taxonomies" to Site Settings [#24955]
1716
* [*] Update "Categories" picker to indicate multiple selection [#24952]
17+
* [*] Fix overly long related post titles in Reader [#25011]
1818

1919
26.4
2020
-----

WordPress/Classes/ViewRelated/Reader/Detail/Views/ReaderRelatedPostsCell.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ class ReaderRelatedPostsCell: UITableViewCell, NibReusable {
1919
featuredImageView.contentMode = .scaleAspectFill
2020
featuredImageView.backgroundColor = .placeholderText
2121

22-
titleLabel.numberOfLines = 0
22+
titleLabel.numberOfLines = 3
2323
titleLabel.font = WPStyleGuide.fontForTextStyle(.body, fontWeight: .semibold)
2424
titleLabel.textColor = .label
2525

@@ -61,6 +61,6 @@ class ReaderRelatedPostsCell: UITableViewCell, NibReusable {
6161
}
6262

6363
private enum Constants {
64-
static let cornerRadius: CGFloat = 4
64+
static let cornerRadius: CGFloat = 6
6565
}
6666
}

WordPress/Classes/ViewRelated/Reader/Detail/Views/ReaderRelatedPostsCell.xib

Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,8 @@
11
<?xml version="1.0" encoding="UTF-8"?>
2-
<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="17506" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
2+
<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="24412" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
33
<device id="retina6_1" orientation="portrait" appearance="light"/>
44
<dependencies>
5-
<deployment identifier="iOS"/>
6-
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="17505"/>
5+
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="24405"/>
76
<capability name="Safe area layout guides" minToolsVersion="9.0"/>
87
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
98
</dependencies>
@@ -21,23 +20,23 @@
2120
<rect key="frame" x="0.0" y="8" width="320" height="100"/>
2221
<subviews>
2322
<imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" translatesAutoresizingMaskIntoConstraints="NO" id="GT5-Ba-NHj">
24-
<rect key="frame" x="0.0" y="0.0" width="142" height="80"/>
23+
<rect key="frame" x="0.0" y="0.0" width="106.5" height="60"/>
2524
<constraints>
2625
<constraint firstAttribute="width" secondItem="GT5-Ba-NHj" secondAttribute="height" multiplier="16:9" id="Fdq-E8-B0g"/>
27-
<constraint firstAttribute="height" constant="80" id="OVJ-LX-8yx"/>
26+
<constraint firstAttribute="height" constant="60" id="OVJ-LX-8yx"/>
2827
</constraints>
2928
</imageView>
3029
<stackView opaque="NO" contentMode="scaleToFill" axis="vertical" spacing="8" translatesAutoresizingMaskIntoConstraints="NO" id="DBq-yS-yFy">
31-
<rect key="frame" x="158" y="0.0" width="162" height="49"/>
30+
<rect key="frame" x="122.5" y="0.0" width="197.5" height="49"/>
3231
<subviews>
3332
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Label" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="TUE-Aq-2F6">
34-
<rect key="frame" x="0.0" y="0.0" width="162" height="20.5"/>
33+
<rect key="frame" x="0.0" y="0.0" width="197.5" height="20.5"/>
3534
<fontDescription key="fontDescription" type="system" pointSize="17"/>
3635
<nil key="textColor"/>
3736
<nil key="highlightedColor"/>
3837
</label>
3938
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Label" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="FoT-uQ-Ghm">
40-
<rect key="frame" x="0.0" y="28.5" width="162" height="20.5"/>
39+
<rect key="frame" x="0.0" y="28.5" width="197.5" height="20.5"/>
4140
<fontDescription key="fontDescription" type="system" pointSize="17"/>
4241
<nil key="textColor"/>
4342
<nil key="highlightedColor"/>

WordPress/Classes/ViewRelated/Reader/Select Interests/ReaderInterestsStyleGuide.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,11 +15,11 @@ class ReaderInterestsStyleGuide {
1515

1616
static let latest = Metrics(
1717
interestsLabelMargin: 16.0,
18-
cellCornerRadius: 5.0,
18+
cellCornerRadius: 8.0,
1919
cellSpacing: 8.0,
2020
cellHeight: 34.0,
2121
maxCellWidthMultiplier: 0.8,
22-
borderWidth: 1.0,
22+
borderWidth: 0.5,
2323
borderColor: .separator
2424
)
2525
}

0 commit comments

Comments
 (0)