StorylyVerticalFeedDelegate

@objc(StorylyVerticalFeedDelegate)
public protocol StorylyVerticalFeedDelegate

This interface represents StorylyVerticalFeedDelegate which notifies application when an event occurs in STRVerticalFeedView.

  • This function will let you know that Vertical Feed has completed its network operations and vertical feed group list has just shown to the user.

    Declaration

    Swift

    @objc
    optional func verticalFeedLoaded(_ view: STRVerticalFeedView,
                                     feedGroupList: [VerticalFeedGroup],
                                     dataSource: StorylyDataSource)

    Parameters

    view

    STRVerticalFeedView instance in which vertical feed is loaded

    feedGroupList

    List of vertical feed groups when vertical feed is loaded

    dataSource

    List of vertical feed groups when vertical feed is loaded

  • This function will let you know that Vertical Feed has completed its network operations and had a problem while fetching your stories

    Declaration

    Swift

    @objc
    optional func verticalFeedLoadFailed(_ view: STRVerticalFeedView,
                                         errorMessage: String)

    Parameters

    view

    STRVerticalFeedView instance in which vertical feed is failed to load

    errorMessage

    Error message of the load fail reason

  • This function will notify your application in case of Swipe Up or CTA Button action.

    Declaration

    Swift

    @objc
    optional func verticalFeedActionClicked(_ view: STRVerticalFeedView,
                                            rootViewController: UIViewController,
                                            feedItem: VerticalFeedItem)

    Parameters

    view

    verticalFeedView instance in which action is occurred

    rootViewController

    RootViewController of the vertical feed view

    feedItem

    verticalFeedItem in which action is occurred

  • This function will let you know that stories are started to be presented to the users.

    Declaration

    Swift

    @objc
    optional func verticalFeedPresented(_ view: STRVerticalFeedView)

    Parameters

    view

    STRVerticalFeedView instance in which vertical feed are started to shown

  • This function will let you know that programmatic vertical feed show are failed.

    Declaration

    Swift

    @objc
    optional func verticalFeedPresentFailed(_ view: STRVerticalFeedView,
                                            errorMessage: String)

    Parameters

    view

    STRVerticalFeedView instance that event occurred

    errorMessage

    Error message of the fail reason

  • This function will let you know that user dismissed the current vertical feed while watching it.

    Declaration

    Swift

    @objc
    optional func verticalFeedDismissed(_ view: STRVerticalFeedView)

    Parameters

    view

    STRVerticalFeedView instance in which the vertical feed is dismissed

  • This function will allow you to get reactions of users from specific interactive components.

    Declaration

    Swift

    @objc
    optional func verticalFeedUserInteracted(_ view: STRVerticalFeedView,
                                             feedGroup: VerticalFeedGroup,
                                             feedItem: VerticalFeedItem,
                                             feedItemComponent: VerticalFeedItemComponent)

    Parameters

    view

    STRVerticalFeedView instance in which the user interacted with a component

    feedGroup

    Vertical feed group in which the user interacted with a component

    feedItem

    Vertical feed in which the user interacted with a component

    feedItemComponent

    Interactive component that user is interacted with

  • This function will notify you about all Vertical Feed events and let you to send these events to specific data platforms

    Declaration

    Swift

    @objc
    optional func verticalFeedEvent(_ view: STRVerticalFeedView,
                                    event: VerticalFeedEvent,
                                    feedGroup: VerticalFeedGroup?,
                                    feedItem: VerticalFeedItem?,
                                    feedItemComponent: VerticalFeedItemComponent?)

    Parameters

    view

    STRVerticalFeedView instance in which the event is received

    event

    VerticalFeed event type which is received

    feedGroup

    Vertical feed group in which the event is received

    feedItem

    Vertical feed in which the event is received

    feedItemComponent

    Interactive vertical feed component if event is related with a vertical feed component