UNPKG

@lifi/sdk

Version:

LI.FI Any-to-Any Cross-Chain-Swap SDK

30 lines 1.06 kB
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.BaseStepExecutor = void 0; const StatusManager_js_1 = require("./StatusManager.js"); const defaultInteractionSettings = { allowInteraction: true, allowUpdates: true, allowExecution: true, }; class BaseStepExecutor { executionOptions; statusManager; allowUserInteraction = true; allowExecution = true; constructor(options) { this.statusManager = new StatusManager_js_1.StatusManager(options.routeId); this.executionOptions = options.executionOptions; } setInteraction = (settings) => { const interactionSettings = { ...defaultInteractionSettings, ...settings, }; this.allowUserInteraction = interactionSettings.allowInteraction; this.statusManager.allowUpdates(interactionSettings.allowUpdates); this.allowExecution = interactionSettings.allowExecution; }; } exports.BaseStepExecutor = BaseStepExecutor; //# sourceMappingURL=BaseStepExecutor.js.map