mirror of
https://github.com/wahyd4/Yep.git
synced 2026-08-13 06:46:16 +10:00
Add creator and time on conversation cell
This commit is contained in:
@@ -49,7 +49,7 @@ class FeedConversationsViewController: UIViewController {
|
||||
feedConversationsTableView.registerNib(UINib(nibName: feedConversationCellID, bundle: nil), forCellReuseIdentifier: feedConversationCellID)
|
||||
feedConversationsTableView.registerNib(UINib(nibName: deletedFeedConversationCellID, bundle: nil), forCellReuseIdentifier: deletedFeedConversationCellID)
|
||||
|
||||
feedConversationsTableView.rowHeight = 80
|
||||
feedConversationsTableView.rowHeight = 100
|
||||
feedConversationsTableView.tableFooterView = UIView()
|
||||
|
||||
if let gestures = navigationController?.view.gestureRecognizers {
|
||||
|
||||
@@ -62,7 +62,7 @@ class FeedConversationCell: UITableViewCell {
|
||||
nameLabel.text = feed.body
|
||||
|
||||
if let creator = feed.creator {
|
||||
timeLabel.text = String(format: NSLocalizedString("Posted by %@", comment: ""), creator.nickname)
|
||||
timeLabel.text = String(format: NSLocalizedString("Created by %@ at %@", comment: ""), creator.nickname, NSDate(timeIntervalSince1970: feed.createdUnixTime).timeAgo)
|
||||
|
||||
} else {
|
||||
timeLabel.text = ""
|
||||
|
||||
@@ -84,6 +84,7 @@
|
||||
<constraint firstAttribute="trailing" relation="greaterThanOrEqual" secondItem="0gK-pe-MlO" secondAttribute="trailing" constant="30" id="HAo-kh-0N5"/>
|
||||
<constraint firstItem="G9V-Qw-tkM" firstAttribute="top" secondItem="o0V-gJ-vFo" secondAttribute="top" id="LNO-aD-cNA"/>
|
||||
<constraint firstAttribute="bottom" relation="greaterThanOrEqual" secondItem="Pdh-nY-RnC" secondAttribute="bottom" constant="25" id="OIq-TG-3Bo"/>
|
||||
<constraint firstAttribute="bottom" secondItem="m9D-xj-gfc" secondAttribute="bottom" constant="8" id="QSb-F7-42W"/>
|
||||
<constraint firstItem="1RF-Jq-txW" firstAttribute="leading" secondItem="NEk-lH-Ejr" secondAttribute="leading" constant="5" id="RJE-DF-nn4"/>
|
||||
<constraint firstItem="G9V-Qw-tkM" firstAttribute="centerY" secondItem="o0V-gJ-vFo" secondAttribute="centerY" id="Tqt-nv-oim"/>
|
||||
<constraint firstItem="m9D-xj-gfc" firstAttribute="leading" secondItem="Pdh-nY-RnC" secondAttribute="leading" id="Wlt-ZR-WAi"/>
|
||||
@@ -105,6 +106,7 @@
|
||||
<variation key="default">
|
||||
<mask key="constraints">
|
||||
<exclude reference="OIq-TG-3Bo"/>
|
||||
<exclude reference="dvt-WQ-2Ud"/>
|
||||
</mask>
|
||||
</variation>
|
||||
</tableViewCellContentView>
|
||||
|
||||
@@ -670,5 +670,5 @@
|
||||
|
||||
"You may meet different people and content depends on your skills" = "根据技能的不同,你会遇见不同的人和话题";
|
||||
|
||||
"Posted by %@" = "由 %@ 创建";
|
||||
"Created by %@ at %@" = "%@ 创建于 %@";
|
||||
|
||||
|
||||
Reference in New Issue
Block a user