"use strict";
// Copyright (c) Rotorz Limited and portions by original markdown-it-video authors
// Licensed under the MIT license. See LICENSE file in the project root.
var __importDefault = (this && this.__importDefault) || function (mod) {
    return (mod && mod.__esModule) ? mod : { "default": mod };
};
Object.defineProperty(exports, "__esModule", { value: true });
exports.default = setup;
const PluginEnvironment_1 = __importDefault(require("./PluginEnvironment"));
const renderer_1 = __importDefault(require("./renderer"));
const tokenizer_1 = require("./tokenizer");
function setup(md, options) {
    const normalizedOptions = options !== null && options !== void 0 ? options : {};
    let env = new PluginEnvironment_1.default(md, normalizedOptions);
    md.block.ruler.before("fence", "video", (0, tokenizer_1.createTokenizer)(env.services), {
        alt: ["paragraph", "reference", "blockquote", "list"]
    });
    md.renderer.rules["video"] = renderer_1.default.bind(env);
}
//# sourceMappingURL=index.js.map