-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
e70631c
commit 5d4ee18
Showing
6 changed files
with
229 additions
and
74 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
53 changes: 53 additions & 0 deletions
53
Tving_CloneProject/Tving_CloneProject/Global/Protocols/TextfieldStatus.swift
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,53 @@ | ||
// | ||
// TextfieldStatus.swift | ||
// Tving_CloneProject | ||
// | ||
// Created by 윤희슬 on 6/7/24. | ||
// | ||
|
||
import UIKit | ||
|
||
protocol TextfieldStatus { | ||
|
||
var bgColor: UIColor { get } | ||
|
||
var borderColor: UIColor { get } | ||
|
||
var borderWidth: CGFloat { get } | ||
|
||
var borderRadius: CGFloat { get } | ||
|
||
} | ||
|
||
extension TextfieldStatus { | ||
|
||
var borderWidth: CGFloat { return 0 } | ||
|
||
var borderRadius: CGFloat { return 3 } | ||
} | ||
|
||
struct UnselectedTextfield: TextfieldStatus { | ||
|
||
var bgColor: UIColor = UIColor(resource: .grey4) | ||
|
||
var borderColor: UIColor = UIColor(resource: .grey4) | ||
|
||
} | ||
|
||
struct SelectedTextfield: TextfieldStatus { | ||
|
||
var bgColor: UIColor = UIColor(resource: .grey4) | ||
|
||
var borderColor: UIColor = UIColor(resource: .grey2) | ||
|
||
var borderWidth: CGFloat = 1 | ||
|
||
} | ||
|
||
struct CreateNicknameTextfield: TextfieldStatus { | ||
|
||
var bgColor: UIColor = UIColor(resource: .grey2) | ||
|
||
var borderColor: UIColor = UIColor(resource: .grey2) | ||
|
||
} |
15 changes: 15 additions & 0 deletions
15
Tving_CloneProject/Tving_CloneProject/Global/Protocols/ViewModelType.swift
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
// | ||
// ViewModelType.swift | ||
// Tving_CloneProject | ||
// | ||
// Created by 윤희슬 on 6/7/24. | ||
// | ||
|
||
import RxSwift | ||
|
||
protocol ViewModelType { | ||
associatedtype Input | ||
associatedtype Output | ||
|
||
func transform(from input: Input, disposeBag: RxSwift.DisposeBag) -> Output | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.