CapsulePosition

This commit is contained in:
xaoxuu 2023-08-29 13:26:26 +08:00
parent a636c0d6b4
commit 691b5c7341
1 changed files with 3 additions and 2 deletions

View File

@ -9,7 +9,7 @@ import UIKit
@objc open class CapsuleViewModel: BaseViewModel { @objc open class CapsuleViewModel: BaseViewModel {
@objc public enum Position: Int { @objc(CapsulePosition) public enum Position: Int {
case top case top
case middle case middle
case bottom case bottom
@ -26,7 +26,8 @@ import UIKit
public extension CapsuleViewModel { public extension CapsuleViewModel {
func position(_ position: Position) -> Self { @discardableResult
@objc func position(_ position: Position) -> Self {
self.position = position self.position = position
return self return self
} }