Manos Chorianopoulos

add CouponsetViewController

......@@ -51,6 +51,7 @@ let package = Package(
.process("cells/ProfileCouponTableViewCell/ProfileCouponTableViewCell.xib"),
.process("cells/ProfileFilterCollectionViewCell/ProfileFilterCollectionViewCell.xib"),
.process("screens/CouponViewController/CouponViewController.xib"),
.process("screens/CouponsetViewController/CouponsetViewController.xib"),
.process("screens/ProfileViewController/ProfileViewController.xib"),
.process("screens/CampaignViewController/CampaignViewController.xib"),
.process("cells/MyRewardsOfferCollectionViewCell/MyRewardsOfferCollectionViewCell.xib"),
......
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>SchemeUserState</key>
<dict>
<key>Pods-SwiftWarplyFramework.xcscheme_^#shared#^_</key>
<dict>
<key>orderHint</key>
<integer>1</integer>
</dict>
</dict>
</dict>
</plist>
......@@ -71,6 +71,8 @@
1EDBAF112DE8443B00911E79 /* ProfileHeaderTableViewCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = 1EDBAF0E2DE8443B00911E79 /* ProfileHeaderTableViewCell.swift */; };
1EDD0ABD2E0D308A005E162B /* XIBLoader.swift in Sources */ = {isa = PBXBuildFile; fileRef = 1EDD0ABC2E0D308A005E162B /* XIBLoader.swift */; };
1EDD0AC62E0D68B6005E162B /* SQLite in Frameworks */ = {isa = PBXBuildFile; productRef = 1EDD0AC52E0D68B6005E162B /* SQLite */; };
622DA0AE2F51CAEE00308AB8 /* CouponsetViewController.xib in Resources */ = {isa = PBXBuildFile; fileRef = 622DA0AD2F51CAEE00308AB8 /* CouponsetViewController.xib */; };
622DA0AF2F51CAEE00308AB8 /* CouponsetViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 622DA0AC2F51CAEE00308AB8 /* CouponsetViewController.swift */; };
7630AD9A6242D60846D6750C /* Pods_SwiftWarplyFramework.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = C0D5F56DD4E5371A50AD2D87 /* Pods_SwiftWarplyFramework.framework */; };
A07936762885E9CC00064122 /* UIColorExtensions.swift in Sources */ = {isa = PBXBuildFile; fileRef = A07936752885E9CC00064122 /* UIColorExtensions.swift */; };
E6A77853282933340045BBA8 /* SwiftWarplyFramework.docc in Sources */ = {isa = PBXBuildFile; fileRef = E6A77852282933340045BBA8 /* SwiftWarplyFramework.docc */; };
......@@ -146,6 +148,8 @@
1EDBAF0E2DE8443B00911E79 /* ProfileHeaderTableViewCell.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ProfileHeaderTableViewCell.swift; sourceTree = "<group>"; };
1EDBAF0F2DE8443B00911E79 /* ProfileHeaderTableViewCell.xib */ = {isa = PBXFileReference; lastKnownFileType = file.xib; path = ProfileHeaderTableViewCell.xib; sourceTree = "<group>"; };
1EDD0ABC2E0D308A005E162B /* XIBLoader.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = XIBLoader.swift; sourceTree = "<group>"; };
622DA0AC2F51CAEE00308AB8 /* CouponsetViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = CouponsetViewController.swift; sourceTree = "<group>"; };
622DA0AD2F51CAEE00308AB8 /* CouponsetViewController.xib */ = {isa = PBXFileReference; lastKnownFileType = file.xib; path = CouponsetViewController.xib; sourceTree = "<group>"; };
A07936752885E9CC00064122 /* UIColorExtensions.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = UIColorExtensions.swift; sourceTree = "<group>"; };
A9B7BE01A4E812DE49866EF8 /* Pods-SwiftWarplyFramework.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-SwiftWarplyFramework.debug.xcconfig"; path = "Target Support Files/Pods-SwiftWarplyFramework/Pods-SwiftWarplyFramework.debug.xcconfig"; sourceTree = "<group>"; };
B9EB8A451EF0C5AD75094EEE /* Pods-SwiftWarplyFramework.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-SwiftWarplyFramework.release.xcconfig"; path = "Target Support Files/Pods-SwiftWarplyFramework/Pods-SwiftWarplyFramework.release.xcconfig"; sourceTree = "<group>"; };
......@@ -319,6 +323,7 @@
1EA8E5B42DDF315600CD3418 /* screens */ = {
isa = PBXGroup;
children = (
622DA0AB2F51CA9100308AB8 /* CouponsetViewController */,
1EBE45642E02DDF90055A0D4 /* CampaignViewController */,
1E917CD32DDF6472002221D8 /* MyRewardsViewController */,
1E917CD82DDF687E002221D8 /* CouponViewController */,
......@@ -425,6 +430,15 @@
path = ProfileFilterCollectionViewCell;
sourceTree = "<group>";
};
622DA0AB2F51CA9100308AB8 /* CouponsetViewController */ = {
isa = PBXGroup;
children = (
622DA0AC2F51CAEE00308AB8 /* CouponsetViewController.swift */,
622DA0AD2F51CAEE00308AB8 /* CouponsetViewController.xib */,
);
path = CouponsetViewController;
sourceTree = "<group>";
};
98AD36FA62350CEABCD961A7 /* Frameworks */ = {
isa = PBXGroup;
children = (
......@@ -598,6 +612,7 @@
1E116F682DE845B1009AE791 /* ProfileFilterCollectionViewCell.xib in Resources */,
1EB4F4252DE09AAC00D934C0 /* MyRewardsBannerOffersScrollTableViewCell.xib in Resources */,
1EA8E5C02DDF427A00CD3418 /* PingLCG-Bold.otf in Resources */,
622DA0AE2F51CAEE00308AB8 /* CouponsetViewController.xib in Resources */,
1E64E1832DE48E0600543217 /* MyRewardsOfferCollectionViewCell.xib in Resources */,
1EA8E5C12DDF427A00CD3418 /* PingLCG-Light.otf in Resources */,
1EA8E5C22DDF427A00CD3418 /* PingLCG-Regular.otf in Resources */,
......@@ -660,6 +675,7 @@
1E089E062DF87CED007459F1 /* Endpoints.swift in Sources */,
1E089E072DF87CED007459F1 /* NetworkService.swift in Sources */,
1EBE45672E02DE9A0055A0D4 /* CampaignViewController.swift in Sources */,
622DA0AF2F51CAEE00308AB8 /* CouponsetViewController.swift in Sources */,
1E089DFE2DF87C39007459F1 /* Coupon.swift in Sources */,
1E089DFF2DF87C39007459F1 /* OfferModel.swift in Sources */,
1ED41E4C2DE0C24D00836ABA /* MyRewardsBannerOfferCollectionViewCell.swift in Sources */,
......
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>SchemeUserState</key>
<dict>
<key>SwiftWarplyFramework.xcscheme_^#shared#^_</key>
<dict>
<key>orderHint</key>
<integer>0</integer>
</dict>
</dict>
</dict>
</plist>
//
// CouponsetViewController.swift
// SwiftWarplyFramework
//
// Created by Manos Chorianopoulos on 27/2/26.
//
import UIKit
@objc public class CouponsetViewController: UIViewController {
@IBOutlet weak var couponImage: UIImageView!
// MARK: - Initializers
public convenience init() {
self.init(nibName: "CouponsetViewController", bundle: Bundle.frameworkBundle)
}
public override init(nibName nibNameOrNil: String?, bundle nibBundleOrNil: Bundle?) {
super.init(nibName: nibNameOrNil, bundle: nibBundleOrNil)
}
required init?(coder: NSCoder) {
super.init(coder: coder)
}
@IBOutlet weak var infoView: UIView!
@IBOutlet weak var infoImage: UIImageView!
@IBOutlet weak var infoLabel: UILabel!
@IBOutlet weak var favoriteImage: UIImageView!
@IBOutlet weak var shareImage: UIImageView!
@IBOutlet weak var titleLabel: UILabel!
@IBOutlet weak var subtitleLabel: UILabel!
@IBOutlet weak var expirationLabel: UILabel!
@IBOutlet weak var detailsLabel: UILabel!
// MARK: - IBOutlets for Coupon Code Section
@IBOutlet weak var couponCodeContainerView: UIView!
@IBOutlet weak var couponCodeHeaderView: UIView!
@IBOutlet weak var couponCodeContentView: UIView!
// Header elements
@IBOutlet weak var couponCodeTitleLabel: UILabel!
@IBOutlet weak var couponCodeArrowImage: UIImageView!
@IBOutlet weak var couponCodeButton: UIButton!
// Content elements (initially hidden)
@IBOutlet weak var couponCodeValueLabel: UILabel!
@IBOutlet weak var copyButtonImage: UIImageView!
@IBOutlet weak var copyButton: UIButton!
// Constraints for animation
@IBOutlet weak var couponCodeContentHeightConstraint: NSLayoutConstraint!
// MARK: - IBOutlets for Coupon Code Section
@IBOutlet weak var couponQRContainerView: UIView!
@IBOutlet weak var couponQRHeaderView: UIView!
@IBOutlet weak var couponQRContentView: UIView!
// Header elements
@IBOutlet weak var couponQRTitleLabel: UILabel!
@IBOutlet weak var couponQRArrowImage: UIImageView!
@IBOutlet weak var couponQRButton: UIButton!
// Content elements (initially hidden)
@IBOutlet weak var couponQRImage: UIImageView!
// Constraints for animation
@IBOutlet weak var couponQRContentHeightConstraint: NSLayoutConstraint!
@IBOutlet weak var termsButtonView: UIView!
@IBOutlet weak var termsButtonTitleLabel: UILabel!
@IBOutlet weak var termsButtonArrowImage: UIImageView!
@IBOutlet weak var termsButton: UIButton!
@IBOutlet weak var termsLabel: UILabel!
@IBOutlet weak var termsLabelHeight: NSLayoutConstraint!
@IBOutlet weak var mapButton: UIButton!
@IBOutlet weak var websiteButton: UIButton!
var couponset: CouponSetItemModel?
private var isDetailsExpanded = false
private var isCouponCodeExpanded = false
private var isCouponQRExpanded = false
private var isTermsExpanded = false
public override func viewDidLoad() {
super.viewDidLoad()
// Show navigation bar for this screen (with back button)
self.navigationController?.setNavigationBarHidden(false, animated: false)
setBackButton()
setNavigationTitle("Προσφορά")
infoView.backgroundColor = UIColor(rgb: 0xFFFFFF)
infoView.layer.cornerRadius = 10.0
infoView.layer.borderWidth = 1.0
infoView.layer.borderColor = UIColor(red: 0.01, green: 0.05, blue: 0.11, alpha: 0.19).cgColor
infoImage.image = UIImage(named: "info", in: Bundle.frameworkResourceBundle, compatibleWith: nil)
shareImage.image = UIImage(named: "share", in: Bundle.frameworkResourceBundle, compatibleWith: nil)
couponCodeArrowImage.image = UIImage(named: "arrow_down", in: Bundle.frameworkResourceBundle, compatibleWith: nil)
copyButtonImage.image = UIImage(named: "copy", in: Bundle.frameworkResourceBundle, compatibleWith: nil)
couponQRArrowImage.image = UIImage(named: "arrow_down", in: Bundle.frameworkResourceBundle, compatibleWith: nil)
couponQRImage.image = UIImage(named: "barcode", in: Bundle.frameworkResourceBundle, compatibleWith: nil)
termsButtonArrowImage.image = UIImage(named: "arrow_down", in: Bundle.frameworkResourceBundle, compatibleWith: nil)
infoLabel.font = UIFont(name: "PingLCG-Regular", size: 13)
infoLabel.textColor = UIColor(rgb: 0x020E1C)
infoLabel.text = "Περισσότερα"
couponCodeContainerView.backgroundColor = UIColor(rgb: 0xFFFFFF)
couponCodeContainerView.layer.cornerRadius = 8.0
couponCodeContainerView.clipsToBounds = true
couponCodeButton.addTarget(self, action: #selector(toggleCouponCode), for: .touchUpInside)
couponCodeContentHeightConstraint.constant = 0
couponCodeContentView.isHidden = true
couponQRContainerView.backgroundColor = UIColor(rgb: 0xFFFFFF)
couponQRContainerView.layer.cornerRadius = 8.0
couponQRContainerView.clipsToBounds = true
couponQRButton.addTarget(self, action: #selector(toggleCouponQR), for: .touchUpInside)
couponQRContentHeightConstraint.constant = 0
couponQRContentView.isHidden = true
termsButtonTitleLabel.font = UIFont(name: "PingLCG-Bold", size: 16)
termsButtonTitleLabel.textColor = UIColor(rgb: 0x020E1C)
termsButtonTitleLabel.text = "Όροι Χρήσης"
termsButton.addTarget(self, action: #selector(toggleTerms), for: .touchUpInside)
termsLabelHeight.constant = 0
mapButton.titleLabel?.font = UIFont(name: "PingLCG-Bold", size: 16)
mapButton.setTitle("Καταστήματα κοντά μου", for: .normal)
mapButton.setTitleColor(UIColor(rgb: 0xFFFFFF), for: .normal)
mapButton.setTitleColor(UIColor(rgb: 0xFFFFFF), for: .highlighted)
mapButton.layer.cornerRadius = 4.0
mapButton.backgroundColor = UIColor(rgb: 0x000F1E)
websiteButton.titleLabel?.font = UIFont(name: "PingLCG-Bold", size: 16)
websiteButton.setTitle("Δες το website", for: .normal)
websiteButton.setTitleColor(UIColor(rgb: 0x000F1E), for: .normal)
websiteButton.setTitleColor(UIColor(rgb: 0x000F1E), for: .highlighted)
websiteButton.backgroundColor = .clear
websiteButton.layer.borderWidth = 1
websiteButton.layer.borderColor = UIColor(rgb: 0x000F1E).cgColor
websiteButton.layer.cornerRadius = 4.0
// Configure the view with offer data
if let offer = couponset {
setupUI(with: offer)
}
}
private func setupUI(with couponset: CouponSetItemModel) {
couponImage.image = UIImage(named: couponset.bannerImage, in: Bundle.frameworkResourceBundle, compatibleWith: nil)
favoriteImage.image = UIImage(named: couponset.isFavorite ? "favorite2_filled" : "favorite2_empty", in: Bundle.frameworkResourceBundle, compatibleWith: nil)
titleLabel.font = UIFont(name: "PingLCG-Bold", size: 24)
titleLabel.textColor = UIColor(rgb: 0xF2709D)
titleLabel.text = couponset.title
subtitleLabel.font = UIFont(name: "PingLCG-Regular", size: 18)
subtitleLabel.textColor = UIColor(rgb: 0x020E1C)
subtitleLabel.text = couponset.description
expirationLabel.font = UIFont(name: "PingLCG-Regular", size: 14)
expirationLabel.textColor = UIColor(rgb: 0x020E1C)
// expirationLabel.text = ("Η προσφορά ισχύει " + couponset.expirationDate)
expirationLabel.text = "Η προσφορά ισχύει έως 30-09-2025"
setupExpandableDetails()
couponCodeTitleLabel.font = UIFont(name: "PingLCG-Regular", size: 16)
couponCodeTitleLabel.textColor = UIColor(rgb: 0x000F1E)
couponCodeTitleLabel.text = "Κωδικός Κουπονιού"
couponCodeValueLabel.font = UIFont(name: "PingLCG-Bold", size: 24)
couponCodeValueLabel.textColor = UIColor(rgb: 0x000F1E)
couponCodeValueLabel.text = "coupons_ab"
copyButton.addTarget(self, action: #selector(copyButtonTapped), for: .touchUpInside)
couponQRTitleLabel.font = UIFont(name: "PingLCG-Regular", size: 16)
couponQRTitleLabel.textColor = UIColor(rgb: 0x000F1E)
couponQRTitleLabel.text = "QR Κουπονιού"
termsLabel.font = UIFont(name: "PingLCG-Regular", size: 16)
termsLabel.textColor = UIColor(rgb: 0x020E1C)
termsLabel.text = "Lorem ipsum dolor sit amet, consectetur adipiscing elit. Maecenas sed ex euismod, feugiat justo eu, faucibus urna. Nulla sodales euismod arcu volutpat finibus. Etiam id urna at justo facilisis tempor. Morbi dignissim erat vitae magna sodales dignissim ac in mauris. Mauris tempor convallis tortor, interdum hendrerit turpis eleifend at. Praesent."
}
private var fullDetailsText = ""
private var shouldTruncaitDetails = false
private func setupExpandableDetails() {
fullDetailsText = "Lorem ipsum dolor sit amet, consectetur adipiscing elit. Maecenas sed ex euismod, feugiat justo eu, faucibus urna. Nulla sodales euismod arcu volutpat finibus. Etiam id urna at justo facilisis tempor. Morbi dignissim erat vitae magna sodales dignissim ac in mauris. Mauris tempor convallis tortor, interdum hendrerit turpis eleifend at. Praesent."
detailsLabel.font = UIFont(name: "PingLCG-Regular", size: 18)
detailsLabel.textColor = UIColor(rgb: 0x020E1C)
updateDetailsText()
let tapGesture = UITapGestureRecognizer(target: self, action: #selector(toggleDetails))
detailsLabel.isUserInteractionEnabled = true
detailsLabel.addGestureRecognizer(tapGesture)
}
private func updateDetailsText() {
if isDetailsExpanded {
// Show full text with "Λιγότερα"
if (shouldTruncaitDetails) {
let fullTextWithLess = fullDetailsText + " Λιγότερα"
let attributedString = createAttributedString(text: fullTextWithLess, linkText: "Λιγότερα")
detailsLabel.attributedText = attributedString
} else {
detailsLabel.text = fullDetailsText
}
detailsLabel.numberOfLines = 0
} else {
// Calculate approximate characters for 4 lines and truncate if needed
let truncatedText = getTruncatedTextForFourLines()
let attributedString = createAttributedString(text: truncatedText, linkText: "Περισσότερα")
detailsLabel.attributedText = attributedString
detailsLabel.numberOfLines = 4
}
}
private func getTruncatedTextForFourLines() -> String {
// Calculate approximate characters that fit in 4 lines
let labelWidth = detailsLabel.frame.width
let fontSize: CGFloat = 18
let averageCharWidth: CGFloat = fontSize * 0.5 // Rough estimate for character width
let charactersPerLine = Int(labelWidth / averageCharWidth)
let maxCharactersFor4Lines = charactersPerLine * 4
let moreText = " Περισσότερα"
let ellipsis = "..."
let reservedCharacters = ellipsis.count + moreText.count + 15
// If text is short enough, don't truncate
if fullDetailsText.count <= maxCharactersFor4Lines {
shouldTruncaitDetails = false
return fullDetailsText
} else {
shouldTruncaitDetails = true
}
// Calculate how many characters we can use from original text
let availableCharacters = maxCharactersFor4Lines - reservedCharacters
// Truncate text and add ellipsis + more
let truncatedText = String(fullDetailsText.prefix(availableCharacters))
return truncatedText + ellipsis + moreText
}
private func createAttributedString(text: String, linkText: String) -> NSAttributedString {
let attributedString = NSMutableAttributedString(string: text)
// Regular text attributes
let regularAttributes: [NSAttributedString.Key: Any] = [
.font: UIFont(name: "PingLCG-Regular", size: 18) ?? UIFont.systemFont(ofSize: 18),
.foregroundColor: UIColor(rgb: 0x020E1C)
]
// Link text attributes (blue color)
let linkAttributes: [NSAttributedString.Key: Any] = [
.font: UIFont(name: "PingLCG-Regular", size: 18) ?? UIFont.systemFont(ofSize: 18),
.foregroundColor: UIColor(rgb: 0x00A8E8) // Blue color
]
// Apply regular attributes to entire text
attributedString.addAttributes(regularAttributes, range: NSRange(location: 0, length: text.count))
// Find and style the link text
if let range = text.range(of: linkText) {
let nsRange = NSRange(range, in: text)
attributedString.addAttributes(linkAttributes, range: nsRange)
}
return attributedString
}
@objc private func toggleDetails() {
isDetailsExpanded.toggle()
UIView.animate(withDuration: 0.3) {
self.updateDetailsText()
self.view.layoutIfNeeded()
}
}
@objc private func toggleCouponCode() {
isCouponCodeExpanded.toggle()
// Calculate the target height before animation
let targetHeight: CGFloat = isCouponCodeExpanded ? 80.67 : 0 // Set a fixed height instead of intrinsicContentSize
// Show content immediately if expanding
if isCouponCodeExpanded {
couponCodeContentView.isHidden = false
couponCodeContentView.alpha = 0
}
UIView.animate(withDuration: 0.3, animations: {
// // Update arrow image
// self.couponCodeArrowImage.image = UIImage(named: self.isCouponCodeExpanded ? "arrow_up" : "arrow_down", in: MyEmptyClass.resourceBundle(), compatibleWith: nil)
// Update arrow with rotation
let rotation = self.isCouponCodeExpanded ? CGAffineTransform(rotationAngle: .pi) : .identity
self.couponCodeArrowImage.transform = rotation
// Update height constraint
self.couponCodeContentHeightConstraint.constant = targetHeight
// Update alpha for smooth fade
self.couponCodeContentView.alpha = self.isCouponCodeExpanded ? 1.0 : 0.0
// Force layout update
self.view.layoutIfNeeded()
}) { _ in
// Hide content after animation completes if collapsing
if !self.isCouponCodeExpanded {
self.couponCodeContentView.isHidden = true
}
}
}
@objc private func toggleCouponQR() {
isCouponQRExpanded.toggle()
// Calculate the target height before animation
let targetHeight: CGFloat = isCouponQRExpanded ? 250 : 0 // Set a fixed height for QR code
// Show content immediately if expanding
if isCouponQRExpanded {
couponQRContentView.isHidden = false
couponQRContentView.alpha = 0
}
UIView.animate(withDuration: 0.3, animations: {
// Update arrow image
// self.couponQRArrowImage.image = UIImage(named: self.isCouponQRExpanded ? "arrow_up" : "arrow_down", in: MyEmptyClass.resourceBundle(), compatibleWith: nil)
// Update arrow with rotation
let rotation = self.isCouponQRExpanded ? CGAffineTransform(rotationAngle: .pi) : .identity
self.couponQRArrowImage.transform = rotation
// Update height constraint
self.couponQRContentHeightConstraint.constant = targetHeight
// Update alpha for smooth fade
self.couponQRContentView.alpha = self.isCouponQRExpanded ? 1.0 : 0.0
// Force layout update
self.view.layoutIfNeeded()
}) { _ in
// Hide content after animation completes if collapsing
if !self.isCouponQRExpanded {
self.couponQRContentView.isHidden = true
}
}
}
@objc private func toggleTerms() {
isTermsExpanded.toggle()
UIView.animate(withDuration: 0.3) {
// self.termsButtonArrowImage.image = UIImage(named: self.isTermsExpanded ? "arrow_up" : "arrow_down", in: MyEmptyClass.resourceBundle(), compatibleWith: nil)
// Update arrow with rotation
let rotation = self.isTermsExpanded ? CGAffineTransform(rotationAngle: .pi) : .identity
self.termsButtonArrowImage.transform = rotation
self.termsLabelHeight.constant = self.isTermsExpanded ? self.termsLabel.intrinsicContentSize.height : 0
self.view.layoutIfNeeded()
}
}
@objc private func copyButtonTapped() {
// Get the coupon code text
guard let couponCode = couponCodeValueLabel.text else { return }
// Copy to clipboard
UIPasteboard.general.string = couponCode
// Show visual feedback
showCopyFeedback()
// Optional: Haptic feedback
let impactFeedback = UIImpactFeedbackGenerator(style: .medium)
impactFeedback.impactOccurred()
}
private func showCopyFeedback() {
// Store original image
// let originalImage = copyButtonImage.image
// Change to checkmark temporarily
// copyButtonImage.image = UIImage(systemName: "checkmark")
// copyButtonImage.tintColor = UIColor(rgb: 0x09914E) // Green color
// Show toast message
showToast(message: "Κωδικός αντιγράφηκε!")
// Reset after 1.5 seconds
// DispatchQueue.main.asyncAfter(deadline: .now() + 1.5) {
// self.copyButtonImage.image = originalImage
// self.copyButtonImage.tintColor = UIColor(rgb: 0xCBCED1) // Original color
// }
}
private func showToast(message: String) {
// Create toast label
let toast = UILabel()
toast.backgroundColor = UIColor.black.withAlphaComponent(0.8)
toast.textColor = .white
toast.textAlignment = .center
toast.font = UIFont(name: "PingLCG-Regular", size: 14)
toast.text = message
toast.alpha = 0.0
toast.layer.cornerRadius = 8
toast.clipsToBounds = true
// Add to view
view.addSubview(toast)
toast.translatesAutoresizingMaskIntoConstraints = false
NSLayoutConstraint.activate([
toast.centerXAnchor.constraint(equalTo: view.centerXAnchor),
toast.bottomAnchor.constraint(equalTo: view.safeAreaLayoutGuide.bottomAnchor, constant: -100),
toast.widthAnchor.constraint(equalToConstant: 200),
toast.heightAnchor.constraint(equalToConstant: 40)
])
// Animate in
UIView.animate(withDuration: 0.3, animations: {
toast.alpha = 1.0
}) { _ in
// Animate out after delay
UIView.animate(withDuration: 0.3, delay: 1.5, animations: {
toast.alpha = 0.0
}) { _ in
toast.removeFromSuperview()
}
}
}
}
<?xml version="1.0" encoding="UTF-8"?>
<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="24506" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
<device id="retina6_12" orientation="portrait" appearance="light"/>
<dependencies>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="24504"/>
<capability name="Safe area layout guides" minToolsVersion="9.0"/>
<capability name="System colors in document resources" minToolsVersion="11.0"/>
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
</dependencies>
<objects>
<placeholder placeholderIdentifier="IBFilesOwner" id="-1" userLabel="File's Owner" customClass="CouponsetViewController" customModule="SwiftWarplyFramework" customModuleProvider="target">
<connections>
<outlet property="copyButton" destination="m3i-vZ-CnB" id="RvZ-a5-lOk"/>
<outlet property="copyButtonImage" destination="gvk-s4-PBD" id="NB5-Cs-XIZ"/>
<outlet property="couponCodeArrowImage" destination="cLt-W0-J7b" id="rhG-F2-CEF"/>
<outlet property="couponCodeButton" destination="Or4-Qv-FhV" id="HNQ-W8-EJt"/>
<outlet property="couponCodeContainerView" destination="29d-hw-9hc" id="bFc-aC-TB8"/>
<outlet property="couponCodeContentHeightConstraint" destination="Pdw-1g-EBR" id="c8h-hL-86W"/>
<outlet property="couponCodeContentView" destination="fPF-zq-mmh" id="TzU-Cp-YiP"/>
<outlet property="couponCodeHeaderView" destination="aiu-GV-BNh" id="S0d-Rf-fJk"/>
<outlet property="couponCodeTitleLabel" destination="QFx-zm-Qpn" id="hwX-hU-Odi"/>
<outlet property="couponCodeValueLabel" destination="fLU-pC-Plj" id="aJj-My-W8v"/>
<outlet property="couponImage" destination="50f-Uw-WmD" id="yxn-pQ-nCT"/>
<outlet property="couponQRArrowImage" destination="41k-Lv-Ekd" id="t3K-U3-iKg"/>
<outlet property="couponQRButton" destination="GHf-9X-rhc" id="KTg-qi-csy"/>
<outlet property="couponQRContainerView" destination="YkU-9O-TIA" id="ZYg-PQ-pc5"/>
<outlet property="couponQRContentHeightConstraint" destination="WnV-ph-lxQ" id="mFh-ob-BUc"/>
<outlet property="couponQRContentView" destination="g3y-cV-fMg" id="kGI-iD-j8P"/>
<outlet property="couponQRHeaderView" destination="eUm-Wc-G5O" id="byR-SI-PUH"/>
<outlet property="couponQRImage" destination="Zkh-qS-gYz" id="5aD-AM-Qc7"/>
<outlet property="couponQRTitleLabel" destination="yia-c1-g1x" id="Aft-FH-B0b"/>
<outlet property="detailsLabel" destination="tOt-gP-Et5" id="H2V-Uq-Dsj"/>
<outlet property="expirationLabel" destination="PZ8-Go-A85" id="hXE-lo-i0w"/>
<outlet property="favoriteImage" destination="kQb-LM-Zaa" id="75J-Ez-RZx"/>
<outlet property="infoImage" destination="RK8-R9-SZK" id="ZjM-PX-DgT"/>
<outlet property="infoLabel" destination="oln-Zl-Mu1" id="OZb-dV-dlF"/>
<outlet property="infoView" destination="raJ-sJ-NGX" id="fol-KV-D65"/>
<outlet property="mapButton" destination="bTa-jT-Ufb" id="gH0-yo-in7"/>
<outlet property="shareImage" destination="a1t-wH-dMg" id="Viw-KD-1JB"/>
<outlet property="subtitleLabel" destination="iWC-mi-WKw" id="peM-oa-eSS"/>
<outlet property="termsButton" destination="eGV-3B-aQo" id="Y0X-hP-SDU"/>
<outlet property="termsButtonArrowImage" destination="TeG-69-TfN" id="FSe-bA-hAS"/>
<outlet property="termsButtonTitleLabel" destination="uSf-AS-iFa" id="qJm-Be-jIb"/>
<outlet property="termsButtonView" destination="12M-YC-Cox" id="YyK-Ox-225"/>
<outlet property="termsLabel" destination="jug-xV-lmv" id="QLz-mM-7dR"/>
<outlet property="termsLabelHeight" destination="9VB-9j-Q79" id="G0C-tp-L7M"/>
<outlet property="titleLabel" destination="aSO-pm-a0W" id="uyw-AX-ElA"/>
<outlet property="view" destination="i5M-Pr-FkT" id="sfx-zR-JGt"/>
<outlet property="websiteButton" destination="lU8-hR-MF0" id="cj6-X8-D8Z"/>
</connections>
</placeholder>
<placeholder placeholderIdentifier="IBFirstResponder" id="-2" customClass="UIResponder"/>
<view clearsContextBeforeDrawing="NO" contentMode="scaleToFill" id="i5M-Pr-FkT">
<rect key="frame" x="0.0" y="0.0" width="393" height="852"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews>
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="SHO-CC-9Fd" userLabel="Main View">
<rect key="frame" x="0.0" y="118" width="393" height="734"/>
<subviews>
<scrollView clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="scaleToFill" showsHorizontalScrollIndicator="NO" showsVerticalScrollIndicator="NO" translatesAutoresizingMaskIntoConstraints="NO" id="GDr-bX-h2w">
<rect key="frame" x="0.0" y="0.0" width="393" height="734"/>
<subviews>
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="mci-HQ-9iu" userLabel="Scroll Content View">
<rect key="frame" x="0.0" y="0.0" width="393" height="1177"/>
<subviews>
<imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" translatesAutoresizingMaskIntoConstraints="NO" id="50f-Uw-WmD" userLabel="Coupon Image View">
<rect key="frame" x="0.0" y="0.0" width="393" height="211"/>
<color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<constraints>
<constraint firstAttribute="height" constant="211" id="9fB-Rk-hOH"/>
</constraints>
</imageView>
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="raJ-sJ-NGX" userLabel="Info View">
<rect key="frame" x="239" y="17" width="138" height="20.666666666666671"/>
<subviews>
<imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" translatesAutoresizingMaskIntoConstraints="NO" id="RK8-R9-SZK" userLabel="Info Image View">
<rect key="frame" x="10" y="3.6666666666666581" width="13.666666666666664" height="13.333333333333336"/>
<constraints>
<constraint firstAttribute="width" constant="13.5" id="K5D-fX-XS0"/>
<constraint firstAttribute="height" constant="13.5" id="vHI-H6-Ehp"/>
</constraints>
</imageView>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Περισσότερα" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="oln-Zl-Mu1" userLabel="Info Label">
<rect key="frame" x="28" y="-0.33333333333334281" width="100" height="21"/>
<fontDescription key="fontDescription" type="system" pointSize="17"/>
<nil key="textColor"/>
<nil key="highlightedColor"/>
</label>
</subviews>
<color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<constraints>
<constraint firstItem="RK8-R9-SZK" firstAttribute="top" secondItem="raJ-sJ-NGX" secondAttribute="top" constant="3.5" id="1MP-Cj-DCi"/>
<constraint firstAttribute="trailing" secondItem="oln-Zl-Mu1" secondAttribute="trailing" constant="10" id="4SV-XE-IRS"/>
<constraint firstItem="oln-Zl-Mu1" firstAttribute="centerY" secondItem="raJ-sJ-NGX" secondAttribute="centerY" id="e0C-hf-tpb"/>
<constraint firstItem="RK8-R9-SZK" firstAttribute="leading" secondItem="raJ-sJ-NGX" secondAttribute="leading" constant="10" id="nim-JL-sOm"/>
<constraint firstAttribute="bottom" secondItem="RK8-R9-SZK" secondAttribute="bottom" constant="3.5" id="t6e-f0-5Uf"/>
<constraint firstItem="oln-Zl-Mu1" firstAttribute="leading" secondItem="RK8-R9-SZK" secondAttribute="trailing" constant="4.5" id="uSA-Gk-Fws"/>
</constraints>
</view>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Label" lineBreakMode="tailTruncation" numberOfLines="0" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="aSO-pm-a0W" userLabel="Title Label">
<rect key="frame" x="24" y="234" width="249" height="20.333333333333343"/>
<fontDescription key="fontDescription" type="system" pointSize="17"/>
<nil key="textColor"/>
<nil key="highlightedColor"/>
</label>
<imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" translatesAutoresizingMaskIntoConstraints="NO" id="kQb-LM-Zaa" userLabel="Favorite Image View">
<rect key="frame" x="284" y="228" width="40" height="40"/>
<color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<constraints>
<constraint firstAttribute="width" constant="40" id="1I4-KR-lcE"/>
<constraint firstAttribute="height" constant="40" id="uqG-Va-NOQ"/>
</constraints>
</imageView>
<imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" translatesAutoresizingMaskIntoConstraints="NO" id="a1t-wH-dMg" userLabel="Share Image View">
<rect key="frame" x="335" y="228" width="40" height="40"/>
<color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<constraints>
<constraint firstAttribute="width" constant="40" id="WKb-kR-izm"/>
<constraint firstAttribute="height" constant="40" id="Woz-Er-jU5"/>
</constraints>
</imageView>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Label" textAlignment="natural" lineBreakMode="tailTruncation" numberOfLines="0" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="iWC-mi-WKw" userLabel="Subtitle Label">
<rect key="frame" x="24" y="254.33333333333334" width="345" height="20.333333333333343"/>
<fontDescription key="fontDescription" type="system" pointSize="17"/>
<nil key="textColor"/>
<nil key="highlightedColor"/>
</label>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Label" textAlignment="natural" lineBreakMode="tailTruncation" numberOfLines="0" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="PZ8-Go-A85" userLabel="Expiration Label">
<rect key="frame" x="24" y="288.66666666666669" width="345" height="20.333333333333314"/>
<fontDescription key="fontDescription" type="system" pointSize="17"/>
<nil key="textColor"/>
<nil key="highlightedColor"/>
</label>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Label" textAlignment="natural" lineBreakMode="tailTruncation" numberOfLines="0" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="tOt-gP-Et5" userLabel="Details Label">
<rect key="frame" x="24" y="329" width="345" height="20.333333333333314"/>
<fontDescription key="fontDescription" type="system" pointSize="17"/>
<nil key="textColor"/>
<nil key="highlightedColor"/>
</label>
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="29d-hw-9hc" userLabel="CouponCodeContainerView">
<rect key="frame" x="24" y="383.33333333333331" width="345" height="134.33333333333331"/>
<subviews>
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="aiu-GV-BNh" userLabel="CouponCodeHeaderView">
<rect key="frame" x="0.0" y="0.0" width="345" height="54.333333333333336"/>
<subviews>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Label" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="QFx-zm-Qpn" userLabel="CouponCodeTitleLabel">
<rect key="frame" x="17" y="17.000000000000057" width="277" height="20.333333333333329"/>
<fontDescription key="fontDescription" type="system" pointSize="17"/>
<nil key="textColor"/>
<nil key="highlightedColor"/>
</label>
<imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" translatesAutoresizingMaskIntoConstraints="NO" id="cLt-W0-J7b" userLabel="CouponCodeArrowImage">
<rect key="frame" x="311" y="20.666666666666686" width="13" height="13"/>
<color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<constraints>
<constraint firstAttribute="height" constant="13" id="5n5-5K-6Gl"/>
<constraint firstAttribute="width" constant="13" id="HOb-s9-jHn"/>
</constraints>
</imageView>
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="system" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="Or4-Qv-FhV" userLabel="CouponCodeButton">
<rect key="frame" x="0.0" y="0.0" width="345" height="54.333333333333336"/>
<color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<state key="normal" title="Button"/>
<buttonConfiguration key="configuration" style="plain" title="Button">
<color key="baseForegroundColor" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
</buttonConfiguration>
</button>
</subviews>
<color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<constraints>
<constraint firstItem="Or4-Qv-FhV" firstAttribute="leading" secondItem="aiu-GV-BNh" secondAttribute="leading" id="3L1-2d-c9l"/>
<constraint firstItem="cLt-W0-J7b" firstAttribute="leading" secondItem="QFx-zm-Qpn" secondAttribute="trailing" constant="17" id="BY0-sX-Ij6"/>
<constraint firstItem="Or4-Qv-FhV" firstAttribute="top" secondItem="aiu-GV-BNh" secondAttribute="top" id="HbR-kc-b0S"/>
<constraint firstAttribute="trailing" secondItem="Or4-Qv-FhV" secondAttribute="trailing" id="PAh-NE-K8G"/>
<constraint firstAttribute="bottom" secondItem="Or4-Qv-FhV" secondAttribute="bottom" id="Xlv-SC-QlR"/>
<constraint firstItem="QFx-zm-Qpn" firstAttribute="top" secondItem="aiu-GV-BNh" secondAttribute="top" constant="17" id="Yjr-Rs-j8t"/>
<constraint firstAttribute="trailing" secondItem="cLt-W0-J7b" secondAttribute="trailing" constant="21" id="cf5-ur-kx8"/>
<constraint firstItem="cLt-W0-J7b" firstAttribute="centerY" secondItem="aiu-GV-BNh" secondAttribute="centerY" id="oah-FX-t8K"/>
<constraint firstAttribute="bottom" secondItem="QFx-zm-Qpn" secondAttribute="bottom" constant="17" id="pIk-PV-GY0"/>
<constraint firstItem="QFx-zm-Qpn" firstAttribute="leading" secondItem="aiu-GV-BNh" secondAttribute="leading" constant="17" id="uMw-90-i4l"/>
</constraints>
</view>
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="fPF-zq-mmh" userLabel="CouponCodeContentView">
<rect key="frame" x="0.0" y="54.333333333333314" width="345" height="80"/>
<subviews>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Label" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="fLU-pC-Plj" userLabel="CouponCodeValueLabel">
<rect key="frame" x="16.999999999999996" y="26" width="56.666666666666657" height="28"/>
<fontDescription key="fontDescription" type="system" pointSize="24"/>
<nil key="textColor"/>
<nil key="highlightedColor"/>
</label>
<imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" translatesAutoresizingMaskIntoConstraints="NO" id="gvk-s4-PBD" userLabel="CopyButtonImage">
<rect key="frame" x="84.666666666666671" y="23.666666666666742" width="33" height="33"/>
<color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<constraints>
<constraint firstAttribute="width" constant="33" id="ALY-g4-dih"/>
<constraint firstAttribute="height" constant="33" id="PaJ-hI-z6k"/>
</constraints>
</imageView>
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="system" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="m3i-vZ-CnB" userLabel="CouponCopyButton">
<rect key="frame" x="0.0" y="0.0" width="117.66666666666667" height="80"/>
<color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<state key="normal" title="Button"/>
<buttonConfiguration key="configuration" style="plain" title="Button">
<color key="baseForegroundColor" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
</buttonConfiguration>
</button>
</subviews>
<color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<constraints>
<constraint firstItem="gvk-s4-PBD" firstAttribute="trailing" secondItem="m3i-vZ-CnB" secondAttribute="trailing" id="1O8-g3-Mle"/>
<constraint firstItem="fLU-pC-Plj" firstAttribute="top" secondItem="fPF-zq-mmh" secondAttribute="top" constant="26" id="CsE-B4-Fy6"/>
<constraint firstItem="fLU-pC-Plj" firstAttribute="leading" secondItem="fPF-zq-mmh" secondAttribute="leading" constant="17" id="DcA-Yo-ZfZ"/>
<constraint firstAttribute="bottom" secondItem="fLU-pC-Plj" secondAttribute="bottom" constant="26" id="J3W-Ep-wZk"/>
<constraint firstAttribute="bottom" secondItem="m3i-vZ-CnB" secondAttribute="bottom" id="LUo-NY-g9R"/>
<constraint firstItem="m3i-vZ-CnB" firstAttribute="leading" secondItem="fPF-zq-mmh" secondAttribute="leading" id="Lek-00-bZQ"/>
<constraint firstAttribute="height" constant="80" id="Pdw-1g-EBR"/>
<constraint firstItem="gvk-s4-PBD" firstAttribute="centerY" secondItem="fPF-zq-mmh" secondAttribute="centerY" id="dSc-Jp-D00"/>
<constraint firstItem="m3i-vZ-CnB" firstAttribute="top" secondItem="fPF-zq-mmh" secondAttribute="top" id="grU-Ao-7aq"/>
<constraint firstAttribute="trailing" relation="greaterThanOrEqual" secondItem="gvk-s4-PBD" secondAttribute="trailing" constant="17" id="maW-DE-22h"/>
<constraint firstItem="gvk-s4-PBD" firstAttribute="leading" secondItem="fLU-pC-Plj" secondAttribute="trailing" constant="11" id="viJ-A9-Vq4"/>
</constraints>
</view>
</subviews>
<color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<constraints>
<constraint firstItem="fPF-zq-mmh" firstAttribute="top" secondItem="aiu-GV-BNh" secondAttribute="bottom" id="4vc-xd-rhc"/>
<constraint firstItem="aiu-GV-BNh" firstAttribute="leading" secondItem="29d-hw-9hc" secondAttribute="leading" id="78S-aR-g2z"/>
<constraint firstAttribute="trailing" secondItem="aiu-GV-BNh" secondAttribute="trailing" id="TKA-7b-5s3"/>
<constraint firstAttribute="trailing" secondItem="fPF-zq-mmh" secondAttribute="trailing" id="WvZ-7R-yvJ"/>
<constraint firstItem="fPF-zq-mmh" firstAttribute="leading" secondItem="29d-hw-9hc" secondAttribute="leading" id="dUy-qI-4Gi"/>
<constraint firstItem="aiu-GV-BNh" firstAttribute="top" secondItem="29d-hw-9hc" secondAttribute="top" id="sgM-Gh-9Zh"/>
<constraint firstAttribute="bottom" secondItem="fPF-zq-mmh" secondAttribute="bottom" id="tKQ-k1-OV3"/>
</constraints>
</view>
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="YkU-9O-TIA" userLabel="CouponQRContainerView">
<rect key="frame" x="24" y="540.66666666666663" width="345" height="305"/>
<subviews>
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="eUm-Wc-G5O" userLabel="CouponQRHeaderView">
<rect key="frame" x="0.0" y="0.0" width="345" height="55"/>
<subviews>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Label" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="yia-c1-g1x" userLabel="CouponQRTitleLabel">
<rect key="frame" x="17" y="17" width="277" height="21"/>
<fontDescription key="fontDescription" type="system" pointSize="17"/>
<nil key="textColor"/>
<nil key="highlightedColor"/>
</label>
<imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" translatesAutoresizingMaskIntoConstraints="NO" id="41k-Lv-Ekd" userLabel="CouponQRArrowImage">
<rect key="frame" x="311" y="21" width="13" height="13"/>
<color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<constraints>
<constraint firstAttribute="height" constant="13" id="6id-7o-w1B"/>
<constraint firstAttribute="width" constant="13" id="GbL-3z-lLO"/>
</constraints>
</imageView>
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="system" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="GHf-9X-rhc" userLabel="CouponQRButton">
<rect key="frame" x="0.0" y="0.0" width="345" height="55"/>
<color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<state key="normal" title="Button"/>
<buttonConfiguration key="configuration" style="plain" title="Button">
<color key="baseForegroundColor" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
</buttonConfiguration>
</button>
</subviews>
<color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<constraints>
<constraint firstItem="yia-c1-g1x" firstAttribute="leading" secondItem="eUm-Wc-G5O" secondAttribute="leading" constant="17" id="0Hm-ir-dIJ"/>
<constraint firstItem="GHf-9X-rhc" firstAttribute="leading" secondItem="eUm-Wc-G5O" secondAttribute="leading" id="43c-Zl-wzz"/>
<constraint firstAttribute="bottom" secondItem="GHf-9X-rhc" secondAttribute="bottom" id="4Cs-jO-J62"/>
<constraint firstItem="41k-Lv-Ekd" firstAttribute="centerY" secondItem="eUm-Wc-G5O" secondAttribute="centerY" id="9z5-4x-NhN"/>
<constraint firstItem="yia-c1-g1x" firstAttribute="top" secondItem="eUm-Wc-G5O" secondAttribute="top" constant="17" id="Goi-Tx-bOj"/>
<constraint firstAttribute="bottom" secondItem="yia-c1-g1x" secondAttribute="bottom" constant="17" id="OT0-Qv-M2p"/>
<constraint firstItem="41k-Lv-Ekd" firstAttribute="leading" secondItem="yia-c1-g1x" secondAttribute="trailing" constant="17" id="cmx-fJ-sSY"/>
<constraint firstItem="GHf-9X-rhc" firstAttribute="top" secondItem="eUm-Wc-G5O" secondAttribute="top" id="ixt-bM-i74"/>
<constraint firstAttribute="trailing" secondItem="GHf-9X-rhc" secondAttribute="trailing" id="kIR-05-5gY"/>
<constraint firstAttribute="trailing" secondItem="41k-Lv-Ekd" secondAttribute="trailing" constant="21" id="nXi-62-ZGj"/>
</constraints>
</view>
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="g3y-cV-fMg" userLabel="CouponQRContentView">
<rect key="frame" x="0.0" y="55" width="345" height="250"/>
<subviews>
<imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" translatesAutoresizingMaskIntoConstraints="NO" id="Zkh-qS-gYz" userLabel="CouponQRImage">
<rect key="frame" x="72.666666666666686" y="20" width="200" height="200"/>
<color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<constraints>
<constraint firstAttribute="height" constant="200" id="HhN-a9-oG4"/>
<constraint firstAttribute="width" constant="200" id="MAf-tL-aEA"/>
</constraints>
</imageView>
</subviews>
<color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<constraints>
<constraint firstItem="Zkh-qS-gYz" firstAttribute="centerX" secondItem="g3y-cV-fMg" secondAttribute="centerX" id="PnZ-55-u2G"/>
<constraint firstAttribute="bottom" secondItem="Zkh-qS-gYz" secondAttribute="bottom" constant="30" id="WHc-Fb-R48"/>
<constraint firstAttribute="height" constant="250" id="WnV-ph-lxQ"/>
<constraint firstItem="Zkh-qS-gYz" firstAttribute="top" secondItem="g3y-cV-fMg" secondAttribute="top" constant="20" id="lUq-E0-XWZ"/>
</constraints>
</view>
</subviews>
<color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<constraints>
<constraint firstItem="g3y-cV-fMg" firstAttribute="leading" secondItem="YkU-9O-TIA" secondAttribute="leading" id="BsA-zX-5pc"/>
<constraint firstItem="eUm-Wc-G5O" firstAttribute="top" secondItem="YkU-9O-TIA" secondAttribute="top" id="EKt-pT-pvf"/>
<constraint firstItem="eUm-Wc-G5O" firstAttribute="leading" secondItem="YkU-9O-TIA" secondAttribute="leading" id="QN2-kp-Jes"/>
<constraint firstAttribute="trailing" secondItem="g3y-cV-fMg" secondAttribute="trailing" id="RaR-Mz-V26"/>
<constraint firstItem="g3y-cV-fMg" firstAttribute="top" secondItem="eUm-Wc-G5O" secondAttribute="bottom" id="a87-KC-HwB"/>
<constraint firstAttribute="trailing" secondItem="eUm-Wc-G5O" secondAttribute="trailing" id="ci5-TU-kpQ"/>
<constraint firstAttribute="bottom" secondItem="g3y-cV-fMg" secondAttribute="bottom" id="xVE-F8-Zzh"/>
</constraints>
</view>
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="12M-YC-Cox" userLabel="TermsButtonView">
<rect key="frame" x="23.999999999999993" y="895.66666666666663" width="123.33333333333331" height="35"/>
<subviews>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Όροι Χρήσης" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="uSf-AS-iFa" userLabel="TermsButtonTitleLabel">
<rect key="frame" x="0.0" y="5" width="101.33333333333333" height="25"/>
<fontDescription key="fontDescription" type="system" pointSize="17"/>
<nil key="textColor"/>
<nil key="highlightedColor"/>
</label>
<imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" translatesAutoresizingMaskIntoConstraints="NO" id="TeG-69-TfN" userLabel="TermsButtonArrowImage">
<rect key="frame" x="109.33333333333334" y="15.000000000000114" width="9" height="5"/>
<color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<constraints>
<constraint firstAttribute="width" constant="9" id="Mvm-l4-0Qv"/>
<constraint firstAttribute="height" constant="5" id="P8V-hT-LdL"/>
</constraints>
</imageView>
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="system" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="eGV-3B-aQo" userLabel="TermsButton">
<rect key="frame" x="0.0" y="0.0" width="123.33333333333333" height="35"/>
<color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<state key="normal" title="Button"/>
<buttonConfiguration key="configuration" style="plain" title="Button">
<color key="baseForegroundColor" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
</buttonConfiguration>
</button>
</subviews>
<color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<constraints>
<constraint firstAttribute="trailing" secondItem="TeG-69-TfN" secondAttribute="trailing" constant="5" id="1nA-8b-mNq"/>
<constraint firstItem="TeG-69-TfN" firstAttribute="leading" secondItem="uSf-AS-iFa" secondAttribute="trailing" constant="8" id="3Br-ig-6Ty"/>
<constraint firstItem="uSf-AS-iFa" firstAttribute="leading" secondItem="12M-YC-Cox" secondAttribute="leading" id="3Yt-dW-LUF"/>
<constraint firstAttribute="trailing" secondItem="eGV-3B-aQo" secondAttribute="trailing" id="7LJ-BO-WHh"/>
<constraint firstItem="TeG-69-TfN" firstAttribute="centerY" secondItem="12M-YC-Cox" secondAttribute="centerY" id="CdC-4X-HfA"/>
<constraint firstItem="eGV-3B-aQo" firstAttribute="top" secondItem="12M-YC-Cox" secondAttribute="top" id="Ibk-ZQ-b1j"/>
<constraint firstItem="uSf-AS-iFa" firstAttribute="top" secondItem="12M-YC-Cox" secondAttribute="top" constant="5" id="MCG-6H-uMT"/>
<constraint firstItem="eGV-3B-aQo" firstAttribute="leading" secondItem="12M-YC-Cox" secondAttribute="leading" id="S8K-hE-afS"/>
<constraint firstAttribute="bottom" secondItem="uSf-AS-iFa" secondAttribute="bottom" constant="5" id="nJH-Wu-ZCd"/>
<constraint firstAttribute="bottom" secondItem="eGV-3B-aQo" secondAttribute="bottom" id="sGt-sy-MSw"/>
</constraints>
</view>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Label" lineBreakMode="tailTruncation" numberOfLines="0" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="jug-xV-lmv" userLabel="TermsLabel">
<rect key="frame" x="24" y="940.66666666666674" width="345" height="20.333333333333371"/>
<constraints>
<constraint firstAttribute="height" constant="20.329999999999998" id="9VB-9j-Q79"/>
</constraints>
<fontDescription key="fontDescription" type="system" pointSize="17"/>
<nil key="textColor"/>
<nil key="highlightedColor"/>
</label>
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="system" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="bTa-jT-Ufb" userLabel="MapButton">
<rect key="frame" x="24" y="1001" width="345" height="55"/>
<constraints>
<constraint firstAttribute="height" constant="55" id="5AV-zY-O6v"/>
</constraints>
<state key="normal" title="Button"/>
<buttonConfiguration key="configuration" style="plain" title="Button"/>
</button>
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="system" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="lU8-hR-MF0" userLabel="WebsiteButton">
<rect key="frame" x="24" y="1076" width="345" height="55"/>
<constraints>
<constraint firstAttribute="height" constant="55" id="aeV-F1-tWk"/>
</constraints>
<state key="normal" title="Button"/>
<buttonConfiguration key="configuration" style="plain" title="Button"/>
</button>
</subviews>
<color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<constraints>
<constraint firstAttribute="trailing" secondItem="PZ8-Go-A85" secondAttribute="trailing" constant="24" id="0BS-5a-p2w"/>
<constraint firstAttribute="trailing" secondItem="raJ-sJ-NGX" secondAttribute="trailing" constant="16" id="3pn-zS-erd"/>
<constraint firstAttribute="trailing" secondItem="50f-Uw-WmD" secondAttribute="trailing" id="5vF-D2-mBO"/>
<constraint firstItem="12M-YC-Cox" firstAttribute="top" secondItem="YkU-9O-TIA" secondAttribute="bottom" constant="50" id="6cC-FH-1Xw"/>
<constraint firstItem="50f-Uw-WmD" firstAttribute="leading" secondItem="mci-HQ-9iu" secondAttribute="leading" id="7Rd-U6-d9j"/>
<constraint firstItem="lU8-hR-MF0" firstAttribute="leading" secondItem="mci-HQ-9iu" secondAttribute="leading" constant="24" id="9R6-Lj-xSo"/>
<constraint firstAttribute="trailing" secondItem="29d-hw-9hc" secondAttribute="trailing" constant="24" id="A4S-YK-o00"/>
<constraint firstItem="aSO-pm-a0W" firstAttribute="leading" secondItem="mci-HQ-9iu" secondAttribute="leading" constant="24" id="BIn-gA-oSw"/>
<constraint firstItem="a1t-wH-dMg" firstAttribute="leading" secondItem="kQb-LM-Zaa" secondAttribute="trailing" constant="11" id="DlZ-NN-vE2"/>
<constraint firstItem="12M-YC-Cox" firstAttribute="leading" secondItem="mci-HQ-9iu" secondAttribute="leading" constant="24" id="Eal-pm-W9t"/>
<constraint firstItem="PZ8-Go-A85" firstAttribute="leading" secondItem="mci-HQ-9iu" secondAttribute="leading" constant="24" id="Fgh-6n-hpZ"/>
<constraint firstAttribute="trailing" secondItem="a1t-wH-dMg" secondAttribute="trailing" constant="18" id="H8F-yd-t0Z"/>
<constraint firstAttribute="trailing" secondItem="iWC-mi-WKw" secondAttribute="trailing" constant="24" id="HII-Zz-ySA"/>
<constraint firstItem="iWC-mi-WKw" firstAttribute="top" secondItem="aSO-pm-a0W" secondAttribute="bottom" id="HZs-3D-vZV"/>
<constraint firstItem="kQb-LM-Zaa" firstAttribute="leading" secondItem="aSO-pm-a0W" secondAttribute="trailing" constant="11" id="MAX-rt-Ne3"/>
<constraint firstItem="PZ8-Go-A85" firstAttribute="top" secondItem="iWC-mi-WKw" secondAttribute="bottom" constant="14" id="PYW-1u-Cgl"/>
<constraint firstAttribute="trailing" secondItem="bTa-jT-Ufb" secondAttribute="trailing" constant="24" id="Qcz-Xf-6ks"/>
<constraint firstAttribute="trailing" secondItem="tOt-gP-Et5" secondAttribute="trailing" constant="24" id="TEj-0l-zzv"/>
<constraint firstItem="bTa-jT-Ufb" firstAttribute="top" secondItem="jug-xV-lmv" secondAttribute="bottom" constant="40" id="WGs-Pa-TME"/>
<constraint firstItem="kQb-LM-Zaa" firstAttribute="top" secondItem="50f-Uw-WmD" secondAttribute="bottom" constant="17" id="Z5G-42-yfN"/>
<constraint firstItem="50f-Uw-WmD" firstAttribute="top" secondItem="mci-HQ-9iu" secondAttribute="top" id="a5j-3R-Mwh"/>
<constraint firstAttribute="trailing" secondItem="jug-xV-lmv" secondAttribute="trailing" constant="24" id="b0Q-bb-wh3"/>
<constraint firstItem="a1t-wH-dMg" firstAttribute="top" secondItem="50f-Uw-WmD" secondAttribute="bottom" constant="17" id="bSw-JI-jDV"/>
<constraint firstItem="29d-hw-9hc" firstAttribute="leading" secondItem="mci-HQ-9iu" secondAttribute="leading" constant="24" id="cGC-SD-gUM"/>
<constraint firstItem="iWC-mi-WKw" firstAttribute="leading" secondItem="mci-HQ-9iu" secondAttribute="leading" constant="24" id="dMq-cH-vOX"/>
<constraint firstItem="raJ-sJ-NGX" firstAttribute="top" secondItem="mci-HQ-9iu" secondAttribute="top" constant="17" id="g7b-Ql-ifv"/>
<constraint firstItem="lU8-hR-MF0" firstAttribute="top" secondItem="bTa-jT-Ufb" secondAttribute="bottom" constant="20" id="hGL-sc-uEw"/>
<constraint firstItem="YkU-9O-TIA" firstAttribute="top" secondItem="29d-hw-9hc" secondAttribute="bottom" constant="23" id="igh-S5-wVl"/>
<constraint firstItem="aSO-pm-a0W" firstAttribute="top" secondItem="50f-Uw-WmD" secondAttribute="bottom" constant="23" id="jvc-rb-E6b"/>
<constraint firstItem="tOt-gP-Et5" firstAttribute="top" secondItem="PZ8-Go-A85" secondAttribute="bottom" constant="20" id="kQ3-4v-3Jp"/>
<constraint firstItem="jug-xV-lmv" firstAttribute="top" secondItem="12M-YC-Cox" secondAttribute="bottom" constant="9.9999999999998863" id="kSx-qT-pPa"/>
<constraint firstAttribute="bottom" secondItem="lU8-hR-MF0" secondAttribute="bottom" constant="46" id="l1j-ca-Uq9"/>
<constraint firstAttribute="trailing" secondItem="lU8-hR-MF0" secondAttribute="trailing" constant="24" id="lEm-My-Oi9"/>
<constraint firstItem="bTa-jT-Ufb" firstAttribute="leading" secondItem="mci-HQ-9iu" secondAttribute="leading" constant="24" id="nR2-Py-LTi"/>
<constraint firstItem="jug-xV-lmv" firstAttribute="leading" secondItem="mci-HQ-9iu" secondAttribute="leading" constant="24" id="oUa-cz-J7N"/>
<constraint firstAttribute="trailing" secondItem="YkU-9O-TIA" secondAttribute="trailing" constant="24" id="qPb-Zk-uAy"/>
<constraint firstItem="YkU-9O-TIA" firstAttribute="leading" secondItem="mci-HQ-9iu" secondAttribute="leading" constant="24" id="qaA-KW-dD7"/>
<constraint firstItem="29d-hw-9hc" firstAttribute="top" secondItem="tOt-gP-Et5" secondAttribute="bottom" constant="34" id="xG9-Pc-sWu"/>
<constraint firstItem="tOt-gP-Et5" firstAttribute="leading" secondItem="mci-HQ-9iu" secondAttribute="leading" constant="24" id="xz5-C4-0GD"/>
</constraints>
</view>
</subviews>
<color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<constraints>
<constraint firstItem="mci-HQ-9iu" firstAttribute="top" secondItem="h4g-s9-7SF" secondAttribute="top" id="03G-xq-Mcz"/>
<constraint firstItem="mci-HQ-9iu" firstAttribute="trailing" secondItem="h4g-s9-7SF" secondAttribute="trailing" id="GPq-Ja-g8u"/>
<constraint firstItem="mci-HQ-9iu" firstAttribute="leading" secondItem="h4g-s9-7SF" secondAttribute="leading" id="MEM-3Q-VXV"/>
<constraint firstItem="mci-HQ-9iu" firstAttribute="bottom" secondItem="h4g-s9-7SF" secondAttribute="bottom" id="qUk-qX-b3J"/>
<constraint firstItem="mci-HQ-9iu" firstAttribute="width" secondItem="VdI-CU-gtr" secondAttribute="width" id="r9B-kb-TPd"/>
</constraints>
<viewLayoutGuide key="contentLayoutGuide" id="h4g-s9-7SF"/>
<viewLayoutGuide key="frameLayoutGuide" id="VdI-CU-gtr"/>
</scrollView>
</subviews>
<color key="backgroundColor" red="0.94901960780000005" green="0.94901960780000005" blue="0.94901960780000005" alpha="1" colorSpace="calibratedRGB"/>
<constraints>
<constraint firstAttribute="trailing" secondItem="GDr-bX-h2w" secondAttribute="trailing" id="6Rw-Bg-NO4"/>
<constraint firstItem="mci-HQ-9iu" firstAttribute="height" relation="greaterThanOrEqual" secondItem="SHO-CC-9Fd" secondAttribute="height" id="MbQ-SS-x84"/>
<constraint firstItem="GDr-bX-h2w" firstAttribute="leading" secondItem="SHO-CC-9Fd" secondAttribute="leading" id="MlF-Ct-Ncs"/>
<constraint firstAttribute="bottom" secondItem="GDr-bX-h2w" secondAttribute="bottom" id="ffd-WV-jyV"/>
<constraint firstItem="GDr-bX-h2w" firstAttribute="top" secondItem="SHO-CC-9Fd" secondAttribute="top" id="o5D-CB-c8M"/>
</constraints>
</view>
</subviews>
<viewLayoutGuide key="safeArea" id="fnl-2z-Ty3"/>
<color key="backgroundColor" systemColor="systemBackgroundColor"/>
<constraints>
<constraint firstItem="SHO-CC-9Fd" firstAttribute="leading" secondItem="i5M-Pr-FkT" secondAttribute="leading" id="HgA-qe-JaT"/>
<constraint firstItem="SHO-CC-9Fd" firstAttribute="top" secondItem="fnl-2z-Ty3" secondAttribute="top" id="c1X-3g-JjK"/>
<constraint firstAttribute="trailing" secondItem="SHO-CC-9Fd" secondAttribute="trailing" id="g67-1Q-pk8"/>
<constraint firstAttribute="bottom" secondItem="SHO-CC-9Fd" secondAttribute="bottom" id="tcy-z9-Apq"/>
</constraints>
<point key="canvasLocation" x="141" y="154"/>
</view>
</objects>
<resources>
<systemColor name="systemBackgroundColor">
<color white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
</systemColor>
</resources>
</document>
......@@ -566,6 +566,13 @@ import UIKit
print("CouponViewController navigation commented out - will handle later")
}
private func openCouponsetViewController(with couponSet: CouponSetItemModel) {
let vc = SwiftWarplyFramework.CouponsetViewController(nibName: "CouponsetViewController", bundle: Bundle.frameworkBundle)
vc.couponSet = couponSet
self.navigationController?.pushViewController(vc, animated: true)
}
private func openProfileViewController() {
let vc = SwiftWarplyFramework.ProfileViewController(nibName: "ProfileViewController", bundle: Bundle.frameworkBundle)
......@@ -680,7 +687,6 @@ extension MyRewardsViewController: MyRewardsOffersScrollTableViewCellDelegate {
}
func didSelectCouponSet(_ couponSet: CouponSetItemModel) {
// New logic for CouponSetItemModel - will handle navigation later
print("CouponSet selected: \(couponSet._name)")
openCouponsetViewController(with: couponSet)
}
}
......