first commit

This commit is contained in:
Beyhan Oğur
2026-04-26 21:30:42 +03:00
commit 4d92991817
1982 changed files with 284835 additions and 0 deletions

View File

@@ -0,0 +1,28 @@
class Theme {
static DEFAULTS = {
modules: {}
};
static themes = {
default: Theme
};
modules = {};
constructor(quill, options) {
this.quill = quill;
this.options = options;
}
init() {
Object.keys(this.options.modules).forEach(name => {
if (this.modules[name] == null) {
this.addModule(name);
}
});
}
addModule(name) {
// @ts-expect-error
const ModuleClass = this.quill.constructor.import(`modules/${name}`);
this.modules[name] = new ModuleClass(this.quill, this.options.modules[name] || {});
return this.modules[name];
}
}
export default Theme;
//# sourceMappingURL=theme.js.map