From 9c6a6dd0cb4a991188682347129be3ee9e381d48 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Cle=CC=81ment=20Perrousset?= Date: Tue, 28 Mar 2023 17:52:54 +0200 Subject: [PATCH] fix(EN-5880) : fix Autolink labels --- .../Conversations/ConversationListMainCell.swift | 8 +++++--- .../Events/Cells/Feed/EventDetailFullCell.swift | 8 +++++--- .../Events/Cells/Feed/EventDetailFullCell.xib | 7 ++++++- .../Events/Cells/Feed/EventDetailTopFullCell.swift | 6 ++++-- .../Events/Cells/Feed/EventDetailTopFullCell.xib | 7 ++++++- .../Cells/Detail/NeighborhoodDetailTopCell.swift | 9 +++------ .../Cells/Detail/NeighborhoodDetailTopCell.xib | 12 ++++++++++-- .../Cells/Detail/NeighborhoodPostCell.swift | 14 +++++++------- .../Cells/Detail/NeighborhoodPostDeletedCell.xib | 2 +- .../Cells/Detail/NeighborhoodPostImageCell.xib | 2 +- .../Cells/Detail/NeighborhoodPostTextCell.xib | 7 ++++++- .../Cells/NeighborhoodMessageCell.swift | 2 +- entourage/Storyboards/Messages.storyboard | 7 ++++++- entourage/Storyboards/Neighborhood.storyboard | 7 ++++++- 14 files changed, 67 insertions(+), 31 deletions(-) diff --git a/entourage/Scenes/Conversations/ConversationListMainCell.swift b/entourage/Scenes/Conversations/ConversationListMainCell.swift index 4d425b607..ff617d227 100644 --- a/entourage/Scenes/Conversations/ConversationListMainCell.swift +++ b/entourage/Scenes/Conversations/ConversationListMainCell.swift @@ -6,13 +6,14 @@ // import UIKit +import ActiveLabel class ConversationListMainCell: UITableViewCell { @IBOutlet weak var ui_image: UIImageView! @IBOutlet weak var ui_username: UILabel! - @IBOutlet weak var ui_detail_message: UILabel! + @IBOutlet weak var ui_detail_message: ActiveLabel! @IBOutlet weak var ui_role: UILabel! @IBOutlet weak var ui_view_separator: UIView! @@ -46,8 +47,9 @@ class ConversationListMainCell: UITableViewCell { ui_username.text = message.title ui_role.text = message.getRolesWithPartnerFormated() if let _message = message.getLastMessage { - ui_detail_message.setTextWithLinksDetected(_message) { url in - delegate.showWebUrl(url:url) + ui_detail_message.text = _message + ui_detail_message.handleURLTap { url in + delegate.showWebUrl(url: url) } } ui_detail_message.text = message.getLastMessage diff --git a/entourage/Scenes/Events/Cells/Feed/EventDetailFullCell.swift b/entourage/Scenes/Events/Cells/Feed/EventDetailFullCell.swift index e127f232d..61464945c 100644 --- a/entourage/Scenes/Events/Cells/Feed/EventDetailFullCell.swift +++ b/entourage/Scenes/Events/Cells/Feed/EventDetailFullCell.swift @@ -7,6 +7,7 @@ import UIKit import MapKit +import ActiveLabel class EventDetailFullCell: UITableViewCell { @@ -45,7 +46,7 @@ class EventDetailFullCell: UITableViewCell { @IBOutlet weak var ui_mapview: MKMapView! @IBOutlet weak var ui_lbl_about_title: UILabel! - @IBOutlet weak var ui_lbl_about_desc: UILabel! + @IBOutlet weak var ui_lbl_about_desc: ActiveLabel! @IBOutlet weak var ui_view_organised_by: UIView! @@ -238,8 +239,9 @@ class EventDetailFullCell: UITableViewCell { ui_lbl_nb_members.text = membersCount if let _desc = event.descriptionEvent { - ui_lbl_about_desc.setTextWithLinksDetected(_desc) { url in - delegate.showWebviewUrl(url:url) + ui_lbl_about_desc.text = _desc + ui_lbl_about_desc.handleURLTap { url in + delegate.showWebviewUrl(url: url) } } diff --git a/entourage/Scenes/Events/Cells/Feed/EventDetailFullCell.xib b/entourage/Scenes/Events/Cells/Feed/EventDetailFullCell.xib index 4c6c7a1b0..4e766c56e 100644 --- a/entourage/Scenes/Events/Cells/Feed/EventDetailFullCell.xib +++ b/entourage/Scenes/Events/Cells/Feed/EventDetailFullCell.xib @@ -509,11 +509,16 @@ - - -