Skip to content
This repository has been archived by the owner on May 14, 2021. It is now read-only.

Fix ui bug #60

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions KinEcosystem/KinEcosystem/View/nibs/NoOffersViewController.xib
Original file line number Diff line number Diff line change
@@ -1,11 +1,9 @@
<?xml version="1.0" encoding="UTF-8"?>
<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="14490.70" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
<device id="retina6_1" orientation="portrait">
<adaptation id="fullscreen"/>
</device>
<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="15705" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
<device id="retina6_1" orientation="portrait" appearance="light"/>
<dependencies>
<deployment identifier="iOS"/>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="14490.49"/>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="15706"/>
<capability name="Safe area layout guides" minToolsVersion="9.0"/>
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
</dependencies>
Expand Down Expand Up @@ -42,9 +40,11 @@ Label</string>
<constraint firstItem="ZZw-Ge-R7H" firstAttribute="leading" secondItem="iN0-l3-epB" secondAttribute="leading" id="Q7t-9h-cpA"/>
<constraint firstItem="BKA-uZ-zBh" firstAttribute="centerX" secondItem="vUN-kp-3ea" secondAttribute="centerX" id="e5r-f6-bsy"/>
<constraint firstItem="BKA-uZ-zBh" firstAttribute="top" secondItem="vUN-kp-3ea" secondAttribute="top" constant="80" id="u9a-kv-ruc"/>
<constraint firstItem="ZZw-Ge-R7H" firstAttribute="centerY" secondItem="vUN-kp-3ea" secondAttribute="centerY" id="w8e-1p-i7h"/>
<constraint firstItem="ZZw-Ge-R7H" firstAttribute="centerY" secondItem="vUN-kp-3ea" secondAttribute="centerY" priority="999" id="w8e-1p-i7h"/>
<constraint firstItem="ZZw-Ge-R7H" firstAttribute="top" relation="greaterThanOrEqual" secondItem="vUN-kp-3ea" secondAttribute="top" constant="200" id="z0L-2Q-qFZ"/>
</constraints>
<viewLayoutGuide key="safeArea" id="vUN-kp-3ea"/>
<point key="canvasLocation" x="139" y="85"/>
</view>
</objects>
<resources>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -197,6 +197,7 @@ extension OffersViewController: UICollectionViewDelegate, UICollectionViewDataSo
} else {
if children.first(where: { $0 is NoOffersViewController }) == nil {
let noOffersViewController = NoOffersViewController(nibName: "NoOffersViewController", bundle: KinBundle.ecosystem.rawValue)
noOffersViewController.view.translatesAutoresizingMaskIntoConstraints = false
addChild(noOffersViewController)
view.addSubview(noOffersViewController.view)
NSLayoutConstraint.activate([
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -110,11 +110,12 @@ class SheetNavigationControllerWrapper: UIViewController, SheetPresented, Themed
view.addSubview(wrappedNavigationController.view)
addChild(wrappedNavigationController)
wrappedNavigationController.didMove(toParent: self)
let safeArea = bcSafeAreaLayoutGuide
NSLayoutConstraint.activate([
wrappedNavigationController.view.topAnchor.constraint(equalTo: bcSafeAreaLayoutGuide.topAnchor, constant: 16.0),
wrappedNavigationController.view.leftAnchor.constraint(equalTo: bcSafeAreaLayoutGuide.leftAnchor, constant: 0.0),
wrappedNavigationController.view.rightAnchor.constraint(equalTo: bcSafeAreaLayoutGuide.rightAnchor, constant: 0.0),
wrappedNavigationController.view.bottomAnchor.constraint(equalTo: bcSafeAreaLayoutGuide.bottomAnchor, constant: 0.0)
wrappedNavigationController.view.topAnchor.constraint(equalTo: safeArea.topAnchor, constant: 16.0),
wrappedNavigationController.view.leftAnchor.constraint(equalTo: safeArea.leftAnchor, constant: 0.0),
wrappedNavigationController.view.rightAnchor.constraint(equalTo: safeArea.rightAnchor, constant: 0.0),
wrappedNavigationController.view.bottomAnchor.constraint(equalTo: safeArea.bottomAnchor, constant: 0.0)
])
view.setNeedsLayout()
}
Expand Down