UNPKG

playable

Version:

Video player based on HTML5Video

42 lines 1.42 kB
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); var tslib_1 = require("tslib"); var extendStyles_1 = (0, tslib_1.__importDefault)(require("./extendStyles")); var Stylable = /** @class */ (function () { function Stylable(theme) { this._themeStyles = {}; var moduleTheme = this.constructor._moduleTheme; if (theme && moduleTheme) { theme.registerModuleTheme(this, moduleTheme); this._themeStyles = theme.get(this); } } Stylable.setTheme = function (theme) { this._moduleTheme = theme; }; Stylable.extendStyleNames = function (styles) { this._styles = (0, extendStyles_1.default)(this._styles, styles); }; Stylable.resetStyles = function () { this._styles = {}; }; Object.defineProperty(Stylable.prototype, "themeStyles", { get: function () { return this._themeStyles; }, enumerable: false, configurable: true }); Object.defineProperty(Stylable.prototype, "styleNames", { get: function () { // NOTE: TS does not work with instance static fields + generic type return this.constructor._styles || {}; }, enumerable: false, configurable: true }); Stylable._styles = {}; return Stylable; }()); exports.default = Stylable; //# sourceMappingURL=stylable.js.map