"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
var Renderables_1 = require("../Renderables");
var node_1 = require("../../support/node");
var Specification_1 = require("../../support/Specification");
/**
 * Implementation of the 'video' markup element.
 * A video HTML element is created and the given attributes
 * id and src are applied from the markup. The lto-video
 * class is added to allow CSS manipulations.
 *
 * @see {@link IRenderable}
 */
var Video = /** @class */ (function () {
    function Video(spec) {
        this.spec = spec;
    }
    /**
     * @inheritDoc
     */
    Video.prototype.render = function (renderer, isNested) {
        var video = node_1.default("video");
        new Specification_1.Specification(this.spec).initNode(video, "lto-video");
        video.addAttributes({ controls: true, src: this.spec.src });
        if (isNested)
            video.addClasses("lto-nested");
        return video.unwrap();
    };
    return Video;
}());
exports.Video = Video;
Renderables_1.default.register("video", Video);
//# sourceMappingURL=index.js.map