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

Commit

Permalink
Standardize segmented control color and update snapshots
Browse files Browse the repository at this point in the history
  • Loading branch information
Akiva Leffert committed Apr 7, 2016
1 parent 2b65a63 commit a34a802
Show file tree
Hide file tree
Showing 19 changed files with 1 addition and 12 deletions.
6 changes: 0 additions & 6 deletions Source/JSONFormBuilder.swift
Original file line number Diff line number Diff line change
Expand Up @@ -64,12 +64,6 @@ class JSONFormBuilder {

titleLabel.textAlignment = .Natural

let selectedAttributes = OEXTextStyle(weight: .Normal, size: .Small, color: OEXStyles.sharedStyles().neutralBlackT())
let unselectedAttributes = OEXTextStyle(weight: .Normal, size: .Small, color: OEXStyles.sharedStyles().neutralDark())
typeControl.setTitleTextAttributes(selectedAttributes.attributes, forState: .Selected)
typeControl.setTitleTextAttributes(unselectedAttributes.attributes, forState: .Normal)
typeControl.tintColor = OEXStyles.sharedStyles().primaryXLightColor()

descriptionLabel.textAlignment = .Natural
descriptionLabel.numberOfLines = 0
descriptionLabel.preferredMaxLayoutWidth = 200 //value doesn't seem to matter as long as it's small enough
Expand Down
2 changes: 1 addition & 1 deletion Source/OEXStyles+Swift.swift
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ extension OEXStyles {
let styleAttributes = OEXTextStyle(weight: .Normal, size : .Small, color : self.neutralBlack()).attributes
UISegmentedControl.appearance().setTitleTextAttributes(styleAttributes, forState: UIControlState.Selected)
UISegmentedControl.appearance().setTitleTextAttributes(styleAttributes, forState: UIControlState.Normal)
UISegmentedControl.appearance().tintColor = self.neutralLight()
UISegmentedControl.appearance().tintColor = self.primaryXLightColor()

UINavigationBar.appearance().translucent = false

Expand Down
5 changes: 0 additions & 5 deletions Source/TabContainerView.swift
Original file line number Diff line number Diff line change
Expand Up @@ -39,11 +39,6 @@ class TabContainerView : UIView {
make.bottom.equalTo(self.snp_bottomMargin)
}

let selectedAttributes = OEXTextStyle(weight: .Normal, size: .Small, color: OEXStyles.sharedStyles().neutralBlackT())
let unselectedAttributes = OEXTextStyle(weight: .Normal, size: .Small, color: OEXStyles.sharedStyles().neutralDark())
control.setTitleTextAttributes(selectedAttributes.attributes, forState: .Selected)
control.setTitleTextAttributes(unselectedAttributes.attributes, forState: .Normal)
control.tintColor = OEXStyles.sharedStyles().primaryXLightColor()
control.oex_addAction({[weak self] control in
let index = (control as! UISegmentedControl).selectedSegmentIndex
self?.showTabAtIndex(index)
Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit a34a802

Please sign in to comment.