Skip to content

Commit

Permalink
Update 1.1.1
Browse files Browse the repository at this point in the history
  • Loading branch information
mrustaa committed Apr 16, 2022
1 parent 4377bda commit caa4fc1
Show file tree
Hide file tree
Showing 32 changed files with 81 additions and 121 deletions.
2 changes: 1 addition & 1 deletion ButtonClickStyle.podspec
Expand Up @@ -8,7 +8,7 @@

Pod::Spec.new do |s|
s.name = 'ButtonClickStyle'
s.version = '1.1.0'
s.version = '1.1.1'
s.summary = 'This is a customizable designable button view. Inside layer you can style button, create your own subviews. Choose 15 click animation styles'

# This description is used to generate tags and improve search results.
Expand Down
116 changes: 46 additions & 70 deletions Example/ButtonClickStyle.xcodeproj/project.pbxproj

Large diffs are not rendered by default.

16 changes: 0 additions & 16 deletions Example/ButtonClickStyle/ButtonClickStyle+Buttons.swift
Expand Up @@ -176,22 +176,6 @@ extension ButtonClick {
]

public static var shortNames: [String] = ButtonClick.Buttons.allCases.map { $0.rawValue }
// public static var shortCases: [ButtonClick.Buttons] = [
// .JustPink,
// .NoShadow,
// .Blue,
// .BuyNow,
// .Download,
// .Delete,
// .Search,
// .Subscribe,
// .Firefox,
// .Google,
// .GrButton,
// .Neomorphism,
// .TestButton,
// .Green,
// ]
}
}

Expand Down
4 changes: 2 additions & 2 deletions Example/ButtonClickStyle/UI/Button/Blue/BlueButtonView.swift
Expand Up @@ -35,8 +35,8 @@ class BlueButtonView: BtnView {
viewAn.widthAnchor.constraint(equalToConstant: fr.width).isActive = true
viewAn.heightAnchor.constraint(equalToConstant: fr.height).isActive = true

self.animation?.removeFromSuperview()
self.animation = viewAn
self.btnClickStyleView?.removeFromSuperview()
self.btnClickStyleView = viewAn


var frr = mainView.frame;frr.origin = .zero;mainView.frame = frr
Expand Down
Expand Up @@ -46,8 +46,8 @@ class BorderGreenDarkButtonView: BtnView {
viewAn.widthAnchor.constraint(equalToConstant: fr.width).isActive = true
viewAn.heightAnchor.constraint(equalToConstant: fr.height).isActive = true

self.animation?.removeFromSuperview()
self.animation = viewAn
self.btnClickStyleView?.removeFromSuperview()
self.btnClickStyleView = viewAn
var frr = mainView.frame;frr.origin = .zero;mainView.frame = frr
}

Expand Down
Expand Up @@ -39,8 +39,8 @@ class BuyNowButtonView: BtnView {
viewAn.widthAnchor.constraint(equalToConstant: fr.width).isActive = true
viewAn.heightAnchor.constraint(equalToConstant: fr.height).isActive = true

self.animation?.removeFromSuperview()
self.animation = viewAn
self.btnClickStyleView?.removeFromSuperview()
self.btnClickStyleView = viewAn
var frr = mainView.frame;frr.origin = .zero;mainView.frame = frr
}

Expand Down
Expand Up @@ -35,8 +35,8 @@ class DeleteButtonView: BtnView {
viewAn.widthAnchor.constraint(equalToConstant: fr.width).isActive = true
viewAn.heightAnchor.constraint(equalToConstant: fr.height).isActive = true

self.animation?.removeFromSuperview()
self.animation = viewAn
self.btnClickStyleView?.removeFromSuperview()
self.btnClickStyleView = viewAn
var frr = mainView.frame;frr.origin = .zero;mainView.frame = frr
}
// firstImageView?.image = state.firstImage
Expand Down
Expand Up @@ -57,8 +57,8 @@ class DownloadButtonView: BtnView {
viewAn.widthAnchor.constraint(equalToConstant: fr.width).isActive = true
viewAn.heightAnchor.constraint(equalToConstant: fr.height).isActive = true

self.animation?.removeFromSuperview()
self.animation = viewAn
self.btnClickStyleView?.removeFromSuperview()
self.btnClickStyleView = viewAn
var frr = mainView.frame;frr.origin = .zero;mainView.frame = frr
}
mainTitleLabel?.text = state.titleText
Expand Down
Expand Up @@ -49,8 +49,8 @@ class FirefoxButtonView: BtnView {
viewAn.widthAnchor.constraint(equalToConstant: fr.width).isActive = true
viewAn.heightAnchor.constraint(equalToConstant: fr.height).isActive = true

self.animation?.removeFromSuperview()
self.animation = viewAn
self.btnClickStyleView?.removeFromSuperview()
self.btnClickStyleView = viewAn
var frr = mainView.frame;frr.origin = .zero;mainView.frame = frr
}
titleLabel?.text = state.titleText
Expand Down
Expand Up @@ -54,8 +54,8 @@ class GoogleButtonView: BtnView {
viewAn.widthAnchor.constraint(equalToConstant: fr.width).isActive = true
viewAn.heightAnchor.constraint(equalToConstant: fr.height).isActive = true

self.animation?.removeFromSuperview()
self.animation = viewAn
self.btnClickStyleView?.removeFromSuperview()
self.btnClickStyleView = viewAn
var frr = mainView.frame;frr.origin = .zero;mainView.frame = frr
}

Expand Down
Expand Up @@ -70,8 +70,8 @@ class GradientBlueBasicButtonView: BtnView {
viewAn.widthAnchor.constraint(equalToConstant: fr.width).isActive = true
viewAn.heightAnchor.constraint(equalToConstant: fr.height).isActive = true

self.animation?.removeFromSuperview()
self.animation = viewAn
self.btnClickStyleView?.removeFromSuperview()
self.btnClickStyleView = viewAn
var frr = mainView.frame;frr.origin = .zero;mainView.frame = frr
}

Expand Down
Expand Up @@ -116,8 +116,8 @@ class JustPinkButtonView: BtnView {
viewAn.widthAnchor.constraint(equalToConstant: fr.width).isActive = true
viewAn.heightAnchor.constraint(equalToConstant: fr.height).isActive = true

self.animation?.removeFromSuperview()
self.animation = viewAn
self.btnClickStyleView?.removeFromSuperview()
self.btnClickStyleView = viewAn
var frr = mainView.frame;frr.origin = .zero;mainView.frame = frr


Expand Down
Expand Up @@ -65,8 +65,8 @@ class NeomorphismButtonView: BtnView {
viewAn.widthAnchor.constraint(equalToConstant: fr.width).isActive = true
viewAn.heightAnchor.constraint(equalToConstant: fr.height).isActive = true

self.animation?.removeFromSuperview()
self.animation = viewAn
self.btnClickStyleView?.removeFromSuperview()
self.btnClickStyleView = viewAn
var frr = mainView.frame;frr.origin = .zero;mainView.frame = frr
}

Expand Down
Expand Up @@ -28,8 +28,8 @@ class SearchButtonView: BtnView {
viewAn.widthAnchor.constraint(equalToConstant: fr.width).isActive = true
viewAn.heightAnchor.constraint(equalToConstant: fr.height).isActive = true

self.animation?.removeFromSuperview()
self.animation = viewAn
self.btnClickStyleView?.removeFromSuperview()
self.btnClickStyleView = viewAn
var frr = mainView.frame;frr.origin = .zero;mainView.frame = frr
}
titleLabel?.text = state.titleText
Expand Down
Expand Up @@ -55,8 +55,8 @@ class SubscribeButtonView: BtnView {
viewAn.widthAnchor.constraint(equalToConstant: fr.width).isActive = true
viewAn.heightAnchor.constraint(equalToConstant: fr.height).isActive = true

self.animation?.removeFromSuperview()
self.animation = viewAn
self.btnClickStyleView?.removeFromSuperview()
self.btnClickStyleView = viewAn
var frr = mainView.frame;frr.origin = .zero;mainView.frame = frr
}
titleLabel?.text = state.titleText
Expand Down
Expand Up @@ -73,8 +73,8 @@ class TestDemoBlurButtonView: BtnView {
viewAn.widthAnchor.constraint(equalToConstant: fr.width).isActive = true
viewAn.heightAnchor.constraint(equalToConstant: fr.height).isActive = true

self.animation?.removeFromSuperview()
self.animation = viewAn
self.btnClickStyleView?.removeFromSuperview()
self.btnClickStyleView = viewAn

var frr = mainView.frame
frr.origin = .zero
Expand Down
Expand Up @@ -50,8 +50,8 @@ class TestDemoGradientButtonView: BtnView {
viewAn.widthAnchor.constraint(equalToConstant: fr.width).isActive = true
viewAn.heightAnchor.constraint(equalToConstant: fr.height).isActive = true

self.animation?.removeFromSuperview()
self.animation = viewAn
self.btnClickStyleView?.removeFromSuperview()
self.btnClickStyleView = viewAn

var frr = mainView.frame
frr.origin = .zero
Expand Down
Expand Up @@ -40,8 +40,8 @@ class TestDemoSquaresButtonView: BtnView {
viewAn.widthAnchor.constraint(equalToConstant: fr.width).isActive = true
viewAn.heightAnchor.constraint(equalToConstant: fr.height).isActive = true

self.animation?.removeFromSuperview()
self.animation = viewAn
self.btnClickStyleView?.removeFromSuperview()
self.btnClickStyleView = viewAn
var frr = mainView.frame;frr.origin = .zero;mainView.frame = frr
}

Expand Down
2 changes: 1 addition & 1 deletion Example/ButtonClickStyle/Utils/LoadNib/BtnView.swift
Expand Up @@ -12,7 +12,7 @@ class BtnView: XibView {
// MARK: Properties

var state: ButtonClick.State?
var animation: ButtonClickStyleView?
var btnClickStyleView: ButtonClickStyleView?

func fill(state: ButtonClick.State?) {

Expand Down
4 changes: 2 additions & 2 deletions Example/Pods/Pods.xcodeproj/project.pbxproj

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion Source/ButtonClickStyle/ButtonClickStyleView.swift
Expand Up @@ -40,7 +40,7 @@ open class ButtonClickStyleView: UIView {
super.init(frame: frame)
}

init(
public init(
state: ButtonClick.State,
frame: CGRect,
radius: CGFloat = 0.0,
Expand Down

0 comments on commit caa4fc1

Please sign in to comment.