"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.handleHtmlSnapshotTakingRequests = handleHtmlSnapshotTakingRequests;
const htmlCommands_1 = require("./htmlCommands");
function handleHtmlSnapshotTakingRequests(onCommand, dispatch, frontApplet) {
    onCommand(async (commandEvent) => {
        switch (commandEvent.command.type) {
            case htmlCommands_1.TakeHtmlSnapshot:
                await dispatch({
                    type: htmlCommands_1.HtmlSnapshotTaken,
                    html: frontApplet.window.document.documentElement.outerHTML,
                });
                break;
            default:
        }
    });
}
//# sourceMappingURL=handleHtmlSnapshotTakingRequests.js.map