mirror of
https://codeberg.org/comaps/comaps
synced 2025-12-21 13:53:37 +00:00
[ios] Replace InfoItemViewController with InfoItemView
To simplify logic and increase reusability Signed-off-by: Kiryl Kaveryn <kirylkaveryn@gmail.com>
This commit is contained in:
committed by
Yannik Bloscheck
parent
8e28470490
commit
ec6a98a6fd
@@ -10,8 +10,7 @@ enum PlacePageEditData {
|
|||||||
final class PlacePageEditBookmarkOrTrackViewController: UIViewController {
|
final class PlacePageEditBookmarkOrTrackViewController: UIViewController {
|
||||||
|
|
||||||
@IBOutlet var stackView: UIStackView!
|
@IBOutlet var stackView: UIStackView!
|
||||||
@IBOutlet var spinner: UIImageView!
|
@IBOutlet var editView: InfoItemView!
|
||||||
@IBOutlet var editButton: UIButton!
|
|
||||||
@IBOutlet var topConstraint: NSLayoutConstraint!
|
@IBOutlet var topConstraint: NSLayoutConstraint!
|
||||||
@IBOutlet var expandableLabel: ExpandableLabel! {
|
@IBOutlet var expandableLabel: ExpandableLabel! {
|
||||||
didSet {
|
didSet {
|
||||||
@@ -44,10 +43,21 @@ final class PlacePageEditBookmarkOrTrackViewController: UIViewController {
|
|||||||
|
|
||||||
private func updateViews() {
|
private func updateViews() {
|
||||||
guard let data else { return }
|
guard let data else { return }
|
||||||
editButton.isEnabled = true
|
|
||||||
switch data {
|
switch data {
|
||||||
case .bookmark(let bookmark):
|
case .bookmark(let bookmark):
|
||||||
editButton.setTitle(L("placepage_edit_bookmark_button"), for: .normal)
|
|
||||||
|
editView.isHidden = false
|
||||||
|
editView.imageView.image = UIImage(resource: .icFolder)
|
||||||
|
editView.infoLabel.text = bookmark.bookmarkCategory
|
||||||
|
editView.setStyle(.link)
|
||||||
|
editView.tapHandler = {
|
||||||
|
print("Edit bookmark tapped")
|
||||||
|
}
|
||||||
|
let accessoryImage = circleImageForColor(bookmark.color.color, frameSize: 28, diameter: 22, iconName: "ic_bm_none")
|
||||||
|
editView.setAccessory(image: accessoryImage, tapHandler: {
|
||||||
|
print("Accessory tapped")
|
||||||
|
})
|
||||||
|
|
||||||
if let description = bookmark.bookmarkDescription {
|
if let description = bookmark.bookmarkDescription {
|
||||||
if bookmark.isHtmlDescription {
|
if bookmark.isHtmlDescription {
|
||||||
setHtmlDescription(description)
|
setHtmlDescription(description)
|
||||||
@@ -60,7 +70,9 @@ final class PlacePageEditBookmarkOrTrackViewController: UIViewController {
|
|||||||
topConstraint.constant = 0
|
topConstraint.constant = 0
|
||||||
}
|
}
|
||||||
case .track:
|
case .track:
|
||||||
editButton.setTitle(L("edit_track"), for: .normal)
|
|
||||||
|
// TODO: implement track editing
|
||||||
|
|
||||||
expandableLabel.isHidden = true
|
expandableLabel.isHidden = true
|
||||||
topConstraint.constant = 0
|
topConstraint.constant = 0
|
||||||
}
|
}
|
||||||
@@ -92,20 +104,6 @@ final class PlacePageEditBookmarkOrTrackViewController: UIViewController {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private func startSpinner() {
|
|
||||||
editButton.isHidden = true
|
|
||||||
let postfix = UIColor.isNightMode() ? "dark" : "light"
|
|
||||||
spinner.image = UIImage(named: "Spinner_" + postfix)
|
|
||||||
spinner.isHidden = false
|
|
||||||
spinner.startRotation()
|
|
||||||
}
|
|
||||||
|
|
||||||
private func stopSpinner() {
|
|
||||||
editButton.isHidden = false
|
|
||||||
spinner.isHidden = true
|
|
||||||
spinner.stopRotation()
|
|
||||||
}
|
|
||||||
|
|
||||||
// MARK: - Actions
|
// MARK: - Actions
|
||||||
|
|
||||||
@IBAction func onEdit(_ sender: UIButton) {
|
@IBAction func onEdit(_ sender: UIButton) {
|
||||||
|
|||||||
@@ -1,4 +1,14 @@
|
|||||||
class InfoItemViewController: UIViewController {
|
final class InfoItemView: UIView {
|
||||||
|
private enum Constants {
|
||||||
|
static let imageViewWidth: CGFloat = 56
|
||||||
|
static let imageViewHeight: CGFloat = 28
|
||||||
|
static let accessoryButtonSize: CGFloat = 44
|
||||||
|
static let infoLabelFontSize: CGFloat = 16
|
||||||
|
static let infoLabelTopBottomSpacing: CGFloat = 10
|
||||||
|
static let stackViewSpacing: CGFloat = 0
|
||||||
|
static let viewHeight: CGFloat = 44
|
||||||
|
}
|
||||||
|
|
||||||
enum Style {
|
enum Style {
|
||||||
case regular
|
case regular
|
||||||
case link
|
case link
|
||||||
@@ -6,9 +16,9 @@ class InfoItemViewController: UIViewController {
|
|||||||
|
|
||||||
typealias TapHandler = () -> Void
|
typealias TapHandler = () -> Void
|
||||||
|
|
||||||
@IBOutlet var imageView: UIImageView!
|
let imageView = UIImageView()
|
||||||
@IBOutlet var infoLabel: UILabel!
|
let infoLabel = UILabel()
|
||||||
@IBOutlet var accessoryButton: UIButton!
|
let accessoryButton = UIButton()
|
||||||
|
|
||||||
private var tapGestureRecognizer: UITapGestureRecognizer!
|
private var tapGestureRecognizer: UITapGestureRecognizer!
|
||||||
private var longPressGestureRecognizer: UILongPressGestureRecognizer!
|
private var longPressGestureRecognizer: UILongPressGestureRecognizer!
|
||||||
@@ -19,19 +29,51 @@ class InfoItemViewController: UIViewController {
|
|||||||
|
|
||||||
private var style: Style = .regular
|
private var style: Style = .regular
|
||||||
|
|
||||||
override func viewDidLoad() {
|
override init(frame: CGRect) {
|
||||||
super.viewDidLoad()
|
super.init(frame: frame)
|
||||||
|
setupView()
|
||||||
|
}
|
||||||
|
|
||||||
|
required init?(coder: NSCoder) {
|
||||||
|
super.init(coder: coder)
|
||||||
setupView()
|
setupView()
|
||||||
}
|
}
|
||||||
|
|
||||||
private func setupView() {
|
private func setupView() {
|
||||||
tapGestureRecognizer = UITapGestureRecognizer(target: self, action: #selector(onTap))
|
tapGestureRecognizer = UITapGestureRecognizer(target: self, action: #selector(onTap))
|
||||||
longPressGestureRecognizer = UILongPressGestureRecognizer(target: self, action: #selector(onLongPress(_:)))
|
longPressGestureRecognizer = UILongPressGestureRecognizer(target: self, action: #selector(onLongPress(_:)))
|
||||||
view.addGestureRecognizer(tapGestureRecognizer)
|
addGestureRecognizer(tapGestureRecognizer)
|
||||||
view.addGestureRecognizer(longPressGestureRecognizer)
|
addGestureRecognizer(longPressGestureRecognizer)
|
||||||
|
|
||||||
|
imageView.contentMode = .scaleAspectFit
|
||||||
accessoryButton.addTarget(self, action: #selector(onAccessoryButtonTap), for: .touchUpInside)
|
accessoryButton.addTarget(self, action: #selector(onAccessoryButtonTap), for: .touchUpInside)
|
||||||
setStyle(style)
|
|
||||||
|
addSubview(imageView)
|
||||||
|
addSubview(infoLabel)
|
||||||
|
addSubview(accessoryButton)
|
||||||
|
|
||||||
|
translatesAutoresizingMaskIntoConstraints = false
|
||||||
|
imageView.translatesAutoresizingMaskIntoConstraints = false
|
||||||
|
infoLabel.translatesAutoresizingMaskIntoConstraints = false
|
||||||
|
accessoryButton.translatesAutoresizingMaskIntoConstraints = false
|
||||||
|
|
||||||
|
NSLayoutConstraint.activate([
|
||||||
|
heightAnchor.constraint(equalToConstant: Constants.viewHeight),
|
||||||
|
|
||||||
|
imageView.leadingAnchor.constraint(equalTo: leadingAnchor),
|
||||||
|
imageView.centerYAnchor.constraint(equalTo: centerYAnchor),
|
||||||
|
imageView.widthAnchor.constraint(equalToConstant: Constants.imageViewWidth),
|
||||||
|
imageView.heightAnchor.constraint(equalToConstant: Constants.imageViewHeight),
|
||||||
|
|
||||||
|
infoLabel.leadingAnchor.constraint(equalTo: imageView.trailingAnchor),
|
||||||
|
infoLabel.centerYAnchor.constraint(equalTo: centerYAnchor),
|
||||||
|
infoLabel.trailingAnchor.constraint(equalTo: accessoryButton.leadingAnchor),
|
||||||
|
|
||||||
|
accessoryButton.trailingAnchor.constraint(equalTo: trailingAnchor),
|
||||||
|
accessoryButton.centerYAnchor.constraint(equalTo: centerYAnchor),
|
||||||
|
accessoryButton.widthAnchor.constraint(equalToConstant: Constants.accessoryButtonSize),
|
||||||
|
accessoryButton.heightAnchor.constraint(equalToConstant: Constants.accessoryButtonSize)
|
||||||
|
])
|
||||||
}
|
}
|
||||||
|
|
||||||
@objc
|
@objc
|
||||||
@@ -53,11 +95,11 @@ class InfoItemViewController: UIViewController {
|
|||||||
func setStyle(_ style: Style) {
|
func setStyle(_ style: Style) {
|
||||||
switch style {
|
switch style {
|
||||||
case .regular:
|
case .regular:
|
||||||
imageView?.setStyleAndApply(.black)
|
imageView.setStyleAndApply(.black)
|
||||||
infoLabel?.setFontStyleAndApply(.blackPrimary)
|
infoLabel.setFontStyleAndApply(.regular16, color: .blackPrimary)
|
||||||
case .link:
|
case .link:
|
||||||
imageView?.setStyleAndApply(.blue)
|
imageView.setStyleAndApply(.blue)
|
||||||
infoLabel?.setFontStyleAndApply(.linkBlue)
|
infoLabel.setFontStyleAndApply(.regular16, color: .linkBlue)
|
||||||
}
|
}
|
||||||
accessoryButton.setStyleAndApply(.black)
|
accessoryButton.setStyleAndApply(.black)
|
||||||
self.style = style
|
self.style = style
|
||||||
@@ -96,44 +138,45 @@ class PlacePageInfoViewController: UIViewController {
|
|||||||
private struct Constants {
|
private struct Constants {
|
||||||
static let coordFormatIdKey = "PlacePageInfoViewController_coordFormatIdKey"
|
static let coordFormatIdKey = "PlacePageInfoViewController_coordFormatIdKey"
|
||||||
}
|
}
|
||||||
private typealias TapHandler = InfoItemViewController.TapHandler
|
|
||||||
private typealias Style = InfoItemViewController.Style
|
private typealias TapHandler = InfoItemView.TapHandler
|
||||||
|
private typealias Style = InfoItemView.Style
|
||||||
|
|
||||||
@IBOutlet var stackView: UIStackView!
|
@IBOutlet var stackView: UIStackView!
|
||||||
|
|
||||||
private lazy var openingHoursView: OpeningHoursViewController = {
|
private lazy var openingHoursViewController: OpeningHoursViewController = {
|
||||||
storyboard!.instantiateViewController(ofType: OpeningHoursViewController.self)
|
storyboard!.instantiateViewController(ofType: OpeningHoursViewController.self)
|
||||||
}()
|
}()
|
||||||
|
|
||||||
private var rawOpeningHoursView: InfoItemViewController?
|
private var rawOpeningHoursView: InfoItemView?
|
||||||
private var phoneViews: [InfoItemViewController] = []
|
private var phoneViews: [InfoItemView] = []
|
||||||
private var websiteView: InfoItemViewController?
|
private var websiteView: InfoItemView?
|
||||||
private var websiteMenuView: InfoItemViewController?
|
private var websiteMenuView: InfoItemView?
|
||||||
private var wikipediaView: InfoItemViewController?
|
private var wikipediaView: InfoItemView?
|
||||||
private var wikimediaCommonsView: InfoItemViewController?
|
private var wikimediaCommonsView: InfoItemView?
|
||||||
private var emailView: InfoItemViewController?
|
private var emailView: InfoItemView?
|
||||||
private var fediverseView: InfoItemViewController?
|
private var fediverseView: InfoItemView?
|
||||||
private var facebookView: InfoItemViewController?
|
private var facebookView: InfoItemView?
|
||||||
private var instagramView: InfoItemViewController?
|
private var instagramView: InfoItemView?
|
||||||
private var twitterView: InfoItemViewController?
|
private var twitterView: InfoItemView?
|
||||||
private var vkView: InfoItemViewController?
|
private var vkView: InfoItemView?
|
||||||
private var lineView: InfoItemViewController?
|
private var lineView: InfoItemView?
|
||||||
private var blueskyView: InfoItemViewController?
|
private var blueskyView: InfoItemView?
|
||||||
private var panoramaxView: InfoItemViewController?
|
private var panoramaxView: InfoItemView?
|
||||||
private var cuisineView: InfoItemViewController?
|
private var cuisineView: InfoItemView?
|
||||||
private var operatorView: InfoItemViewController?
|
private var operatorView: InfoItemView?
|
||||||
private var wifiView: InfoItemViewController?
|
private var wifiView: InfoItemView?
|
||||||
private var atmView: InfoItemViewController?
|
private var atmView: InfoItemView?
|
||||||
private var addressView: InfoItemViewController?
|
private var addressView: InfoItemView?
|
||||||
private var levelView: InfoItemViewController?
|
private var levelView: InfoItemView?
|
||||||
private var coordinatesView: InfoItemViewController?
|
private var coordinatesView: InfoItemView?
|
||||||
private var openWithAppView: InfoItemViewController?
|
private var openWithAppView: InfoItemView?
|
||||||
private var capacityView: InfoItemViewController?
|
private var capacityView: InfoItemView?
|
||||||
private var wheelchairView: InfoItemViewController?
|
private var wheelchairView: InfoItemView?
|
||||||
private var selfServiceView: InfoItemViewController?
|
private var selfServiceView: InfoItemView?
|
||||||
private var outdoorSeatingView: InfoItemViewController?
|
private var outdoorSeatingView: InfoItemView?
|
||||||
private var driveThroughView: InfoItemViewController?
|
private var driveThroughView: InfoItemView?
|
||||||
private var networkView: InfoItemViewController?
|
private var networkView: InfoItemView?
|
||||||
|
|
||||||
weak var placePageInfoData: PlacePageInfoData!
|
weak var placePageInfoData: PlacePageInfoData!
|
||||||
weak var delegate: PlacePageInfoViewControllerDelegate?
|
weak var delegate: PlacePageInfoViewControllerDelegate?
|
||||||
@@ -144,14 +187,27 @@ class PlacePageInfoViewController: UIViewController {
|
|||||||
|
|
||||||
override func viewDidLoad() {
|
override func viewDidLoad() {
|
||||||
super.viewDidLoad()
|
super.viewDidLoad()
|
||||||
|
stackView.axis = .vertical
|
||||||
|
stackView.alignment = .fill
|
||||||
|
stackView.spacing = 0
|
||||||
|
stackView.translatesAutoresizingMaskIntoConstraints = false
|
||||||
|
view.addSubview(stackView)
|
||||||
|
NSLayoutConstraint.activate([
|
||||||
|
stackView.leadingAnchor.constraint(equalTo: view.leadingAnchor),
|
||||||
|
stackView.trailingAnchor.constraint(equalTo: view.trailingAnchor),
|
||||||
|
stackView.topAnchor.constraint(equalTo: view.topAnchor),
|
||||||
|
stackView.bottomAnchor.constraint(equalTo: view.bottomAnchor)
|
||||||
|
])
|
||||||
setupViews()
|
setupViews()
|
||||||
}
|
}
|
||||||
|
|
||||||
// MARK: private
|
// MARK: private
|
||||||
private func setupViews() {
|
private func setupViews() {
|
||||||
if let openingHours = placePageInfoData.openingHours {
|
if let openingHours = placePageInfoData.openingHours {
|
||||||
openingHoursView.openingHours = openingHours
|
openingHoursViewController.openingHours = openingHours
|
||||||
addToStack(openingHoursView)
|
addChild(openingHoursViewController)
|
||||||
|
addToStack(openingHoursViewController.view)
|
||||||
|
openingHoursViewController.didMove(toParent: self)
|
||||||
} else if let openingHoursString = placePageInfoData.openingHoursString {
|
} else if let openingHoursString = placePageInfoData.openingHoursString {
|
||||||
rawOpeningHoursView = createInfoItem(openingHoursString, icon: UIImage(named: "ic_placepage_open_hours"))
|
rawOpeningHoursView = createInfoItem(openingHoursString, icon: UIImage(named: "ic_placepage_open_hours"))
|
||||||
rawOpeningHoursView?.infoLabel.numberOfLines = 0
|
rawOpeningHoursView?.infoLabel.numberOfLines = 0
|
||||||
@@ -437,7 +493,7 @@ class PlacePageInfoViewController: UIViewController {
|
|||||||
style: .link,
|
style: .link,
|
||||||
tapHandler: { [weak self] in
|
tapHandler: { [weak self] in
|
||||||
guard let self, let openWithAppView else { return }
|
guard let self, let openWithAppView else { return }
|
||||||
self.delegate?.didPressOpenInApp(from: openWithAppView.view)
|
self.delegate?.didPressOpenInApp(from: openWithAppView)
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -447,22 +503,20 @@ class PlacePageInfoViewController: UIViewController {
|
|||||||
accessoryImage: UIImage? = nil,
|
accessoryImage: UIImage? = nil,
|
||||||
tapHandler: TapHandler? = nil,
|
tapHandler: TapHandler? = nil,
|
||||||
longPressHandler: TapHandler? = nil,
|
longPressHandler: TapHandler? = nil,
|
||||||
accessoryImageTapHandler: TapHandler? = nil) -> InfoItemViewController {
|
accessoryImageTapHandler: TapHandler? = nil) -> InfoItemView {
|
||||||
let vc = storyboard!.instantiateViewController(ofType: InfoItemViewController.self)
|
let view = InfoItemView()
|
||||||
addToStack(vc)
|
addToStack(view)
|
||||||
vc.imageView.image = icon
|
view.imageView.image = icon?.withRenderingMode(.alwaysTemplate)
|
||||||
vc.infoLabel.text = info
|
view.infoLabel.text = info
|
||||||
vc.setStyle(style)
|
view.setStyle(style)
|
||||||
vc.tapHandler = tapHandler
|
view.tapHandler = tapHandler
|
||||||
vc.longPressHandler = longPressHandler
|
view.longPressHandler = longPressHandler
|
||||||
vc.setAccessory(image: accessoryImage, tapHandler: accessoryImageTapHandler)
|
view.setAccessory(image: accessoryImage, tapHandler: accessoryImageTapHandler)
|
||||||
return vc;
|
return view
|
||||||
}
|
}
|
||||||
|
|
||||||
private func addToStack(_ viewController: UIViewController) {
|
private func addToStack(_ view: UIView) {
|
||||||
addChild(viewController)
|
stackView.addArrangedSubviewWithSeparator(view, insets: UIEdgeInsets(top: 0, left: 56, bottom: 0, right: 0))
|
||||||
stackView.addArrangedSubviewWithSeparator(viewController.view, insets: UIEdgeInsets(top: 0, left: 56, bottom: 0, right: 0))
|
|
||||||
viewController.didMove(toParent: self)
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private static let kHttp = "http://"
|
private static let kHttp = "http://"
|
||||||
|
|||||||
@@ -515,80 +515,6 @@
|
|||||||
</objects>
|
</objects>
|
||||||
<point key="canvasLocation" x="929" y="655"/>
|
<point key="canvasLocation" x="929" y="655"/>
|
||||||
</scene>
|
</scene>
|
||||||
<!--Info Item View Controller-->
|
|
||||||
<scene sceneID="f7X-K7-lgf">
|
|
||||||
<objects>
|
|
||||||
<viewController storyboardIdentifier="InfoItemViewController" id="cJQ-4x-NFc" customClass="InfoItemViewController" customModule="CoMaps" customModuleProvider="target" sceneMemberID="viewController">
|
|
||||||
<view key="view" contentMode="scaleToFill" id="oz0-2o-icQ">
|
|
||||||
<rect key="frame" x="0.0" y="0.0" width="375" height="44"/>
|
|
||||||
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
|
|
||||||
<subviews>
|
|
||||||
<stackView opaque="NO" contentMode="scaleToFill" alignment="center" translatesAutoresizingMaskIntoConstraints="NO" id="LQd-fA-r9c">
|
|
||||||
<rect key="frame" x="0.0" y="0.0" width="367" height="44"/>
|
|
||||||
<subviews>
|
|
||||||
<imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="ic_operator" translatesAutoresizingMaskIntoConstraints="NO" id="l7d-ck-nSv">
|
|
||||||
<rect key="frame" x="0.0" y="8" width="56" height="28"/>
|
|
||||||
<color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
|
|
||||||
<constraints>
|
|
||||||
<constraint firstAttribute="height" constant="28" id="dbx-It-HsN"/>
|
|
||||||
<constraint firstAttribute="width" constant="56" id="uhV-yT-jBd"/>
|
|
||||||
</constraints>
|
|
||||||
<userDefinedRuntimeAttributes>
|
|
||||||
<userDefinedRuntimeAttribute type="string" keyPath="coloring" value="MWMBlack"/>
|
|
||||||
</userDefinedRuntimeAttributes>
|
|
||||||
</imageView>
|
|
||||||
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" horizontalCompressionResistancePriority="250" text="Label" textAlignment="natural" lineBreakMode="tailTruncation" numberOfLines="0" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="8eU-Fj-XRv" customClass="CopyLabel" customModule="CoMaps" customModuleProvider="target">
|
|
||||||
<rect key="frame" x="56" y="10" width="267" height="24"/>
|
|
||||||
<color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
|
|
||||||
<fontDescription key="fontDescription" type="system" pointSize="17"/>
|
|
||||||
<nil key="textColor"/>
|
|
||||||
<nil key="highlightedColor"/>
|
|
||||||
<userDefinedRuntimeAttributes>
|
|
||||||
<userDefinedRuntimeAttribute type="string" keyPath="styleName" value="regular16:blackPrimaryText"/>
|
|
||||||
</userDefinedRuntimeAttributes>
|
|
||||||
</label>
|
|
||||||
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="system" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="7B8-M6-Hae" userLabel="Accessory Button">
|
|
||||||
<rect key="frame" x="323" y="0.0" width="44" height="44"/>
|
|
||||||
<constraints>
|
|
||||||
<constraint firstAttribute="height" constant="44" id="cKy-lg-gNZ"/>
|
|
||||||
<constraint firstAttribute="width" constant="44" id="g6o-VG-fZY"/>
|
|
||||||
</constraints>
|
|
||||||
<state key="normal" title="Button"/>
|
|
||||||
<buttonConfiguration key="configuration" style="plain"/>
|
|
||||||
</button>
|
|
||||||
</subviews>
|
|
||||||
<constraints>
|
|
||||||
<constraint firstAttribute="height" relation="greaterThanOrEqual" constant="44" id="Dzf-g4-a7d"/>
|
|
||||||
<constraint firstAttribute="bottom" secondItem="8eU-Fj-XRv" secondAttribute="bottom" constant="10" id="Oju-fx-VZb"/>
|
|
||||||
<constraint firstItem="8eU-Fj-XRv" firstAttribute="top" secondItem="LQd-fA-r9c" secondAttribute="top" constant="10" id="iCj-QI-o3i"/>
|
|
||||||
<constraint firstItem="l7d-ck-nSv" firstAttribute="centerY" secondItem="LQd-fA-r9c" secondAttribute="centerY" id="srg-qZ-iXx"/>
|
|
||||||
</constraints>
|
|
||||||
</stackView>
|
|
||||||
</subviews>
|
|
||||||
<viewLayoutGuide key="safeArea" id="xdh-hy-Bxo"/>
|
|
||||||
<color key="backgroundColor" systemColor="systemBackgroundColor"/>
|
|
||||||
<gestureRecognizers/>
|
|
||||||
<constraints>
|
|
||||||
<constraint firstAttribute="trailing" secondItem="LQd-fA-r9c" secondAttribute="trailing" constant="8" id="Foi-HR-gnE"/>
|
|
||||||
<constraint firstItem="LQd-fA-r9c" firstAttribute="top" secondItem="oz0-2o-icQ" secondAttribute="top" id="K4k-Mo-mLZ"/>
|
|
||||||
<constraint firstAttribute="bottom" secondItem="LQd-fA-r9c" secondAttribute="bottom" id="dC0-Xu-45b"/>
|
|
||||||
<constraint firstItem="LQd-fA-r9c" firstAttribute="leading" secondItem="oz0-2o-icQ" secondAttribute="leading" id="ggJ-Q6-6Ir"/>
|
|
||||||
</constraints>
|
|
||||||
<userDefinedRuntimeAttributes>
|
|
||||||
<userDefinedRuntimeAttribute type="string" keyPath="styleName" value="Background"/>
|
|
||||||
</userDefinedRuntimeAttributes>
|
|
||||||
</view>
|
|
||||||
<size key="freeformSize" width="375" height="44"/>
|
|
||||||
<connections>
|
|
||||||
<outlet property="accessoryButton" destination="7B8-M6-Hae" id="Idt-3q-OmT"/>
|
|
||||||
<outlet property="imageView" destination="l7d-ck-nSv" id="Llp-U6-qLx"/>
|
|
||||||
<outlet property="infoLabel" destination="8eU-Fj-XRv" id="72o-pM-iKo"/>
|
|
||||||
</connections>
|
|
||||||
</viewController>
|
|
||||||
<placeholder placeholderIdentifier="IBFirstResponder" id="4nU-eg-9AS" userLabel="First Responder" customClass="UIResponder" sceneMemberID="firstResponder"/>
|
|
||||||
</objects>
|
|
||||||
<point key="canvasLocation" x="1565.5999999999999" y="-315.74212893553226"/>
|
|
||||||
</scene>
|
|
||||||
<!--Opening Hours View Controller-->
|
<!--Opening Hours View Controller-->
|
||||||
<scene sceneID="txO-kw-ZRm">
|
<scene sceneID="txO-kw-ZRm">
|
||||||
<objects>
|
<objects>
|
||||||
@@ -1202,45 +1128,16 @@
|
|||||||
<stackView opaque="NO" contentMode="scaleToFill" axis="vertical" translatesAutoresizingMaskIntoConstraints="NO" id="iB6-kj-Bi1">
|
<stackView opaque="NO" contentMode="scaleToFill" axis="vertical" translatesAutoresizingMaskIntoConstraints="NO" id="iB6-kj-Bi1">
|
||||||
<rect key="frame" x="16" y="16" width="343" height="184"/>
|
<rect key="frame" x="16" y="16" width="343" height="184"/>
|
||||||
<subviews>
|
<subviews>
|
||||||
<view contentMode="scaleToFill" verticalHuggingPriority="251" translatesAutoresizingMaskIntoConstraints="NO" id="5nz-eA-gNS" customClass="ExpandableLabel" customModule="CoMaps" customModuleProvider="target">
|
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="wB7-XJ-Nck" userLabel="Edit View" customClass="InfoItemView" customModule="CoMaps" customModuleProvider="target">
|
||||||
<rect key="frame" x="0.0" y="0.0" width="343" height="140"/>
|
|
||||||
<color key="backgroundColor" systemColor="systemBackgroundColor"/>
|
|
||||||
<userDefinedRuntimeAttributes>
|
|
||||||
<userDefinedRuntimeAttribute type="string" keyPath="styleName" value="Background"/>
|
|
||||||
</userDefinedRuntimeAttributes>
|
|
||||||
</view>
|
|
||||||
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="wB7-XJ-Nck">
|
|
||||||
<rect key="frame" x="0.0" y="140" width="343" height="44"/>
|
|
||||||
<subviews>
|
|
||||||
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="system" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="XR5-Np-W07">
|
|
||||||
<rect key="frame" x="0.0" y="0.0" width="343" height="44"/>
|
<rect key="frame" x="0.0" y="0.0" width="343" height="44"/>
|
||||||
<inset key="contentEdgeInsets" minX="16" minY="0.0" maxX="9" maxY="0.0"/>
|
|
||||||
<state key="normal" title="Edit bookmark"/>
|
|
||||||
<userDefinedRuntimeAttributes>
|
|
||||||
<userDefinedRuntimeAttribute type="string" keyPath="styleName" value="FlatNormalTransButtonBig"/>
|
|
||||||
</userDefinedRuntimeAttributes>
|
|
||||||
<connections>
|
|
||||||
<action selector="onEdit:" destination="cB4-oj-3Tv" eventType="touchUpInside" id="1TN-b8-s90"/>
|
|
||||||
</connections>
|
|
||||||
</button>
|
|
||||||
<imageView hidden="YES" userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" translatesAutoresizingMaskIntoConstraints="NO" id="OUV-mg-G9u">
|
|
||||||
<rect key="frame" x="153.5" y="4" width="36" height="36"/>
|
|
||||||
<constraints>
|
|
||||||
<constraint firstAttribute="height" constant="36" id="BVc-KM-8Hg"/>
|
|
||||||
<constraint firstAttribute="width" constant="36" id="ngt-Z5-4pT"/>
|
|
||||||
</constraints>
|
|
||||||
</imageView>
|
|
||||||
</subviews>
|
|
||||||
<color key="backgroundColor" systemColor="systemBackgroundColor"/>
|
<color key="backgroundColor" systemColor="systemBackgroundColor"/>
|
||||||
<constraints>
|
<constraints>
|
||||||
<constraint firstItem="OUV-mg-G9u" firstAttribute="centerY" secondItem="wB7-XJ-Nck" secondAttribute="centerY" id="4vr-RY-Khl"/>
|
|
||||||
<constraint firstItem="XR5-Np-W07" firstAttribute="leading" secondItem="wB7-XJ-Nck" secondAttribute="leading" id="B2T-Yo-3vW"/>
|
|
||||||
<constraint firstAttribute="height" constant="44" id="Dh1-Jl-owY"/>
|
<constraint firstAttribute="height" constant="44" id="Dh1-Jl-owY"/>
|
||||||
<constraint firstAttribute="bottom" secondItem="XR5-Np-W07" secondAttribute="bottom" id="MeL-ju-0XR"/>
|
|
||||||
<constraint firstAttribute="trailing" secondItem="XR5-Np-W07" secondAttribute="trailing" id="WgB-Yd-xBS"/>
|
|
||||||
<constraint firstItem="XR5-Np-W07" firstAttribute="top" secondItem="wB7-XJ-Nck" secondAttribute="top" id="Wll-QX-ljL"/>
|
|
||||||
<constraint firstItem="OUV-mg-G9u" firstAttribute="centerX" secondItem="wB7-XJ-Nck" secondAttribute="centerX" id="wyh-oj-4AU"/>
|
|
||||||
</constraints>
|
</constraints>
|
||||||
|
</view>
|
||||||
|
<view contentMode="scaleToFill" verticalHuggingPriority="251" translatesAutoresizingMaskIntoConstraints="NO" id="5nz-eA-gNS" customClass="ExpandableLabel" customModule="CoMaps" customModuleProvider="target">
|
||||||
|
<rect key="frame" x="0.0" y="44" width="343" height="140"/>
|
||||||
|
<color key="backgroundColor" systemColor="systemBackgroundColor"/>
|
||||||
<userDefinedRuntimeAttributes>
|
<userDefinedRuntimeAttributes>
|
||||||
<userDefinedRuntimeAttribute type="string" keyPath="styleName" value="Background"/>
|
<userDefinedRuntimeAttribute type="string" keyPath="styleName" value="Background"/>
|
||||||
</userDefinedRuntimeAttributes>
|
</userDefinedRuntimeAttributes>
|
||||||
@@ -1262,9 +1159,8 @@
|
|||||||
</view>
|
</view>
|
||||||
<size key="freeformSize" width="375" height="200"/>
|
<size key="freeformSize" width="375" height="200"/>
|
||||||
<connections>
|
<connections>
|
||||||
<outlet property="editButton" destination="XR5-Np-W07" id="cUN-mD-Fth"/>
|
<outlet property="editView" destination="wB7-XJ-Nck" id="iPO-d0-Pw4"/>
|
||||||
<outlet property="expandableLabel" destination="5nz-eA-gNS" id="iui-Iu-EiB"/>
|
<outlet property="expandableLabel" destination="5nz-eA-gNS" id="iui-Iu-EiB"/>
|
||||||
<outlet property="spinner" destination="OUV-mg-G9u" id="7Og-Ix-dr7"/>
|
|
||||||
<outlet property="stackView" destination="iB6-kj-Bi1" id="CSH-xH-X4b"/>
|
<outlet property="stackView" destination="iB6-kj-Bi1" id="CSH-xH-X4b"/>
|
||||||
<outlet property="topConstraint" destination="Afw-Mq-NV9" id="Oth-ao-05T"/>
|
<outlet property="topConstraint" destination="Afw-Mq-NV9" id="Oth-ao-05T"/>
|
||||||
</connections>
|
</connections>
|
||||||
@@ -1495,16 +1391,15 @@
|
|||||||
<image name="arrow.forward.circle.fill" catalog="system" width="128" height="123"/>
|
<image name="arrow.forward.circle.fill" catalog="system" width="128" height="123"/>
|
||||||
<image name="dialog_btn_press" width="280" height="44"/>
|
<image name="dialog_btn_press" width="280" height="44"/>
|
||||||
<image name="ic_arrow_gray_down" width="28" height="28"/>
|
<image name="ic_arrow_gray_down" width="28" height="28"/>
|
||||||
<image name="ic_operator" width="28" height="28"/>
|
|
||||||
<image name="ic_placepage_open_hours" width="28" height="28"/>
|
<image name="ic_placepage_open_hours" width="28" height="28"/>
|
||||||
<systemColor name="separatorColor">
|
<systemColor name="separatorColor">
|
||||||
<color red="0.23529411759999999" green="0.23529411759999999" blue="0.26274509800000001" alpha="0.28999999999999998" colorSpace="custom" customColorSpace="sRGB"/>
|
<color red="0.23529411764705882" green="0.23529411764705882" blue="0.2627450980392157" alpha="0.28999999999999998" colorSpace="custom" customColorSpace="sRGB"/>
|
||||||
</systemColor>
|
</systemColor>
|
||||||
<systemColor name="systemBackgroundColor">
|
<systemColor name="systemBackgroundColor">
|
||||||
<color white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
|
<color white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
|
||||||
</systemColor>
|
</systemColor>
|
||||||
<systemColor name="systemRedColor">
|
<systemColor name="systemRedColor">
|
||||||
<color red="1" green="0.23137254900000001" blue="0.18823529410000001" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
<color red="1" green="0.23137254901960785" blue="0.18823529411764706" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||||
</systemColor>
|
</systemColor>
|
||||||
</resources>
|
</resources>
|
||||||
</document>
|
</document>
|
||||||
|
|||||||
Reference in New Issue
Block a user