File tree Expand file tree Collapse file tree 4 files changed +26
-3
lines changed
Sources/FlexUI/Classes/Extensions Expand file tree Collapse file tree 4 files changed +26
-3
lines changed Original file line number Diff line number Diff line change 22All notable changes to this project will be documented in this file.
33
44#### 1.x Releases
5+ - ` 1.3.x ` Releases - [ 1.3.0] ( #130 )
56- ` 1.2.x ` Releases - [ 1.2.0] ( #120 )
67- ` 1.1.x ` Releases - [ 1.1.0] ( #110 )
78- ` 1.0.x ` Releases - [ 1.0.0] ( #100 )
89
10+ ## [ 1.3.0] ( https://github.com/space-code/flex-ui/releases/tag/1.3.0 )
11+ Released on 2025-05-08.
12+
13+ #### Added
14+ - Implement a new ` setImage ` method for the ` UIButton ` class.
15+ - Added in Pull Request [ #9 ] ( https://github.com/space-code/flex-ui/pull/9 ) .
16+ - Implement setting an optional value as the UILabel's text.
17+ - Added in Pull Request [ #8 ] ( https://github.com/space-code/flex-ui/pull/8 ) .
18+
919## [ 1.2.0] ( https://github.com/space-code/flex-ui/releases/tag/1.2.0 )
1020Released on 2025-02-15.
1121
Original file line number Diff line number Diff line change @@ -205,4 +205,17 @@ public extension FlexUI where Component: UIButton {
205205 component. isEnabled = isEnable
206206 return self
207207 }
208+
209+ /// Sets the image for a specific button state.
210+ ///
211+ /// - Parameters:
212+ /// - image: The image to set.
213+ /// - controlState: The state for which to set the background image (default is `.normal`).
214+ /// - Returns: The current instance of `FlexUI` for further configuration.
215+ @discardableResult
216+ @MainActor
217+ func setImage( _ image: UIImage , for controlState: UIControl . State = . normal) -> Self {
218+ component. setImage ( image, for: controlState)
219+ return self
220+ }
208221}
Original file line number Diff line number Diff line change 11//
22// flex-ui
3- // Copyright © 2024 Space Code. All rights reserved.
3+ // Copyright © 2025 Space Code. All rights reserved.
44//
55
66import UIKit
@@ -12,7 +12,7 @@ public extension FlexUI where Component: UILabel {
1212 /// - Returns: The current instance of `FlexUI` for further configuration.
1313 @discardableResult
1414 @MainActor
15- func text( _ text: String ) -> Self {
15+ func text( _ text: String ? ) -> Self {
1616 component. text = text
1717 return self
1818 }
Original file line number Diff line number Diff line change @@ -23,7 +23,7 @@ public extension FlexUI where Component: UITextField {
2323 /// - Returns: The current instance of `FlexUI` for further configuration.
2424 @discardableResult
2525 @MainActor
26- func placeholder( _ placeholder: String ) -> Self {
26+ func placeholder( _ placeholder: String ? ) -> Self {
2727 component. placeholder = placeholder
2828 return self
2929 }
You can’t perform that action at this time.
0 commit comments