bga-cards
    Preparing search index...

    Interface AutoPlaceSettings<T>

    interface AutoPlaceSettings<T> {
        addSettings?: (card: T) => AddCardSettings;
        removeSettings?: (card: T) => RemoveCardSettings;
    }

    Type Parameters

    • T
    Index

    Properties

    addSettings?: (card: T) => AddCardSettings

    The add cards settings, for example if you want to set an animation from an invisible point (can be the player mini panel) Will only be called if the card match a stock with the "autoPlace" setting.

    Type declaration

      • (card: T): AddCardSettings
      • Parameters

        • card: T

          the card to add

        Returns AddCardSettings

        the settings to add the card. { fromElement: originElement } will add a slide in animation

    removeSettings?: (card: T) => RemoveCardSettings

    The remove settings, when a card does not match any stock with the "autoPlace" setting.

    Type declaration

      • (card: T): RemoveCardSettings
      • Parameters

        • card: T

          the card to remove

        Returns RemoveCardSettings

        the settings to remove the card. {} will simply remove the card from it's current stock without any error. { slideTo: destinationElement } will add an animation before removing the card.