docs/Structs/SwipeExpansionStyle.html
public struct SwipeExpansionStyle
Describes the expansion style. Expansion is the behavior when the cell is swiped past a defined threshold.
`
selection
`
The default action performs a selection-type behavior. The cell bounces back to its unopened state upon selection and the row remains in the table/collection view.
Swift
public static var selection: SwipeExpansionStyle
`
destructive
`
The default action performs a destructive behavior. The cell is removed from the table/collection view in an animated fashion.
Swift
public static var destructive: SwipeExpansionStyle
`
destructiveAfterFill
`
The default action performs a destructive behavior after the fill animation completes. The cell is removed from the table/collection view in an animated fashion.
Swift
public static var destructiveAfterFill: SwipeExpansionStyle
`
fill
`
The default action performs a fill behavior.
Note
The action handle must call SwipeAction.fulfill(style:) to resolve the fill expansion.
Swift
public static var fill: SwipeExpansionStyle
`
destructive(automaticallyDelete:timing:)
`
Returns a SwipeExpansionStyle instance for the default action which peforms destructive behavior with the specified options.
Swift
public static func destructive(automaticallyDelete: Bool, timing: FillOptions.HandlerInvocationTiming = .with) -> SwipeExpansionStyle
| automaticallyDelete |
Specifies if row/item deletion should be peformed automatically. If false, you must call SwipeAction.fulfill(with style:) at some point while/after your action handler is invoked to trigger deletion.
|
| timing |
The timing which specifies when the action handler will be invoked with respect to the fill animation.
|
The new SwipeExpansionStyle instance.
`
target
`
The relative target expansion threshold. Expansion will occur at the specified value.
Swift
public let target: Target
`
additionalTriggers
`
Additional triggers to useful for determining if expansion should occur.
Swift
public let additionalTriggers: [Trigger]
`
elasticOverscroll
`
Specifies if buttons should expand to fully fill overscroll, or expand at a percentage relative to the overscroll.
Swift
public let elasticOverscroll: Bool
`
completionAnimation
`
Specifies the expansion animation completion style.
Swift
public let completionAnimation: CompletionAnimation
`
minimumTargetOverscroll
`
Specifies the minimum amount of overscroll required if the configured target is less than the fully exposed action view.
Swift
public var minimumTargetOverscroll: CGFloat = 20
`
targetOverscrollElasticity
`
The amount of elasticity applied when dragging past the expansion target.
Note
Default value is 0.2. Valid range is from 0.0 for no movement past the expansion target, to 1.0 for unrestricted movement with dragging.
Swift
public var targetOverscrollElasticity: CGFloat = 0.2
`
init(target:additionalTriggers:elasticOverscroll:completionAnimation:)
`
Contructs a new SwipeExpansionStyle instance.
Swift
public init(target: Target, additionalTriggers: [Trigger] = [], elasticOverscroll: Bool = false, completionAnimation: CompletionAnimation = .bounce)
| target |
The relative target expansion threshold. Expansion will occur at the specified value.
|
| additionalTriggers |
Additional triggers to useful for determining if expansion should occur.
|
| elasticOverscroll |
Specifies if buttons should expand to fully fill overscroll, or expand at a percentage relative to the overscroll.
|
| completionAnimation |
Specifies the expansion animation completion style.
|
The new SwipeExpansionStyle instance.
`
Target
`
Describes the relative target expansion threshold. Expansion will occur at the specified value.
Swift
public enum Target
`
Trigger
`
Describes additional triggers to useful for determining if expansion should occur.
Swift
public enum Trigger
`
CompletionAnimation
`
Describes the expansion animation completion style.
Swift
public enum CompletionAnimation
`
FillOptions
`
Specifies the options for the fill completion animation.
Swift
public struct FillOptions
© 2018 Mohammad Kurabi. All rights reserved. (Last updated: 2018-05-26)
Generated by jazzy ♪♫ v0.8.4, a Realm project.