@@ -2,27 +2,57 @@ import Foundation
22
33/// A model that defines the appearance properties for a bottom modal component.
44public struct BottomModalVM : ModalVM {
5+ /// The background color of the modal's content area.
56 public var backgroundColor : UniversalColor = Palette . Base. secondaryBackground
67
8+ /// A Boolean value indicating whether the modal should close when tapping on the overlay.
9+ ///
10+ /// Defaults to `true`.
711 public var closesOnOverlayTap : Bool = true
812
13+ /// The padding applied to the modal's content area.
14+ ///
15+ /// Defaults to a padding value of `16` for all sides.
916 public var contentPaddings : Paddings = . init( padding: 16 )
1017
18+ /// The spacing between header, body and footer.
1119 public var contentSpacing : CGFloat = 16
1220
21+ /// The corner radius of the modal.
22+ ///
23+ /// Defaults to `.medium`.
1324 public var cornerRadius : ModalRadius = . medium
1425
26+ /// A Boolean value indicating whether the modal should hide when it is swiped down.
27+ ///
28+ /// Defaults to `true`.
29+ public var hidesOnSwap : Bool = true
30+
31+ /// A Boolean value indicating whether the modal is draggable.
32+ ///
33+ /// If `true`, the modal can be dragged vertically. Defaults to `true`.
34+ public var isDraggable : Bool = true
35+
36+ /// The style of the overlay displayed behind the modal.
37+ ///
38+ /// Defaults to `.dimmed`.
1539 public var overlayStyle : ModalOverlayStyle = . dimmed
1640
41+ /// The padding applied outside the modal's content area, creating space between the modal and the screen edges.
42+ ///
43+ /// Defaults to a padding value of `20` for all sides.
1744 public var outerPaddings : Paddings = . init( padding: 20 )
1845
46+ /// The predefined maximum size of the modal.
47+ ///
48+ /// Defaults to `.medium`.
1949 public var size : ModalSize = . medium
2050
51+ /// The transition duration of the modal's appearance and dismissal animations.
52+ ///
53+ /// Defaults to `.fast`.
2154 public var transition : ModalTransition = . fast
2255
23- public var isDraggable : Bool = true
24- public var hidesOnSwap : Bool = true
25-
26- /// Initializes a new instance of `ModalVM` with default values.
56+ /// Initializes a new instance of `BottomModalVM` with default values.
2757 public init ( ) { }
2858}
0 commit comments