"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.OjSunburst = void 0;
const OjSunburstBase_1 = require("./OjSunburstBase");
/**
 * The component WebElement for [oj-sunburst](../../jsdocs/oj.ojSunburst.html).
 * Do not instantiate this class directly, instead, use
 * [ojSunburst](../functions/elements.ojSunburst-1.html).
 */
class OjSunburst extends OjSunburstBase_1.OjSunburstBase {
    /**
     * Dispatches drill event.
     * @param {string} nodeId  Id of the new node to drill to. Only visible nodes
     * and breadcrumbs are allowed. Any others will throw an exception.
     */
    async doDrill(nodeId) {
        let drilling = await this.getDrilling();
        if (drilling === 'on') {
            await this.getDriver().executeScript(`
        let sunburst = arguments[0];
        sunburst.getAutomation().dispatchItemDrill(arguments[1]);
      `, this, nodeId);
        }
    }
}
exports.OjSunburst = OjSunburst;
//# sourceMappingURL=OjSunburst.js.map