Repository URL to install this package:
|
Version:
0.0.15 ▾
|
import { PaymentAddressType } from '@skava/packages/core/addressAndPayment';
import { ObservableContainer } from '@skava/packages/libraries/observable-container';
import { OnSelectChangeArgs } from '@skava/packages/ui/typings';
import { CheckoutAddressStateType } from './typings';
declare class StepperContainer extends ObservableContainer {
state: {
currentIndex: number;
showAddressForm: boolean;
isAlreadyOpened: boolean[];
accordionLength: number;
isGuestUser: boolean;
isRegisteredUser: string | true | undefined;
changeHeightOnToggle: boolean;
isFromError: boolean;
readonly isNextVisible: boolean;
readonly isPrevVisible: boolean;
shippingMethod: {};
isItemLevelShipping: boolean;
billingAddress: {};
isClickTriggered: boolean;
selectedCostCenterValue: string;
};
addressState: CheckoutAddressStateType;
/**
* @deprecated
* renderParams = fromAddressToSomeProps
*/
handleShipToMultipleAddress(): void;
handleCostCenterToggle(value: OnSelectChangeArgs): void;
toggleCheckBox(): void;
/**
* @todo @fixme this is not the right data
*/
handleCommunicationPreference(): Promise<void>;
handleBillingAddress(state?: {
toSerialized: () => string;
}): void;
setIndex(index: number): void;
isSelected: (index: number) => boolean;
shouldDisable: (index: number) => boolean;
toggleShippingForm(): void;
nextClick(): {
currentIndex: number;
showAddressForm: boolean;
isAlreadyOpened: boolean[];
accordionLength: number;
isGuestUser: boolean;
isRegisteredUser: string | true | undefined;
changeHeightOnToggle: boolean;
isFromError: boolean;
readonly isNextVisible: boolean;
readonly isPrevVisible: boolean;
shippingMethod: {};
isItemLevelShipping: boolean;
billingAddress: {};
isClickTriggered: boolean;
selectedCostCenterValue: string;
};
prevClick(): {
currentIndex: number;
showAddressForm: boolean;
isAlreadyOpened: boolean[];
accordionLength: number;
isGuestUser: boolean;
isRegisteredUser: string | true | undefined;
changeHeightOnToggle: boolean;
isFromError: boolean;
readonly isNextVisible: boolean;
readonly isPrevVisible: boolean;
shippingMethod: {};
isItemLevelShipping: boolean;
billingAddress: {};
isClickTriggered: boolean;
selectedCostCenterValue: string;
};
handleClickFor(index: number): (() => {
currentIndex: number;
showAddressForm: boolean;
isAlreadyOpened: boolean[];
accordionLength: number;
isGuestUser: boolean;
isRegisteredUser: string | true | undefined;
changeHeightOnToggle: boolean;
isFromError: boolean;
readonly isNextVisible: boolean;
readonly isPrevVisible: boolean;
shippingMethod: {};
isItemLevelShipping: boolean;
billingAddress: {};
isClickTriggered: boolean;
selectedCostCenterValue: string;
}) & import("xmobx/mobx").IAction;
gotoHomepage: () => void;
handleGoToFirst(index: number): {
currentIndex: number;
showAddressForm: boolean;
isAlreadyOpened: boolean[];
accordionLength: number;
isGuestUser: boolean;
isRegisteredUser: string | true | undefined;
changeHeightOnToggle: boolean;
isFromError: boolean;
readonly isNextVisible: boolean;
readonly isPrevVisible: boolean;
shippingMethod: {};
isItemLevelShipping: boolean;
billingAddress: {};
isClickTriggered: boolean;
selectedCostCenterValue: string;
};
setIsAlreadyOpenedFor(index: number, isNotOpened: boolean): void;
handleToggle(): void;
handleFirst(): {
currentIndex: number;
showAddressForm: boolean;
isAlreadyOpened: boolean[];
accordionLength: number;
isGuestUser: boolean;
isRegisteredUser: string | true | undefined;
changeHeightOnToggle: boolean;
isFromError: boolean;
readonly isNextVisible: boolean;
readonly isPrevVisible: boolean;
shippingMethod: {};
isItemLevelShipping: boolean;
billingAddress: {};
isClickTriggered: boolean;
selectedCostCenterValue: string;
};
handlePaymentError(): void;
handleNext(): {
currentIndex: number;
showAddressForm: boolean;
isAlreadyOpened: boolean[];
accordionLength: number;
isGuestUser: boolean;
isRegisteredUser: string | true | undefined;
changeHeightOnToggle: boolean;
isFromError: boolean;
readonly isNextVisible: boolean;
readonly isPrevVisible: boolean;
shippingMethod: {};
isItemLevelShipping: boolean;
billingAddress: {};
isClickTriggered: boolean;
selectedCostCenterValue: string;
};
handlePrev(): void;
handleBillingNext(): {
currentIndex: number;
showAddressForm: boolean;
isAlreadyOpened: boolean[];
accordionLength: number;
isGuestUser: boolean;
isRegisteredUser: string | true | undefined;
changeHeightOnToggle: boolean;
isFromError: boolean;
readonly isNextVisible: boolean;
readonly isPrevVisible: boolean;
shippingMethod: {};
isItemLevelShipping: boolean;
billingAddress: {};
isClickTriggered: boolean;
selectedCostCenterValue: string;
};
/**
* @todo move to shipping only
*/
handleShippingAddress(address: PaymentAddressType, itemId: number): Promise<void>;
handleSkipShippingMethod(): void;
handleShippingMethodNext(): void;
handlePaymentNext(): void;
}
declare const stepperContainer: StepperContainer;
export { stepperContainer };
export default stepperContainer;