import { EditorBaseOf } from "./EditorBase.js";
export class MacroEditorBase extends EditorBaseOf {
    constructor(options) {
        super(options);
        this.source.controller.onCommit(() => {
            this.onCommit();
        });
    }
    get fill() {
        return this.state.get("fill", false);
    }
    get isPrimaryEditor() {
        return this.source.feature.index == 0;
    }
    resize() {
        this.onResized();
    }
    onActivate(e) {
        super.onActivate(e);
        if (this.fill) {
            this.node.css({
                position: "absolute",
                inset: 0
            });
        }
    }
    onCommit() {
    }
    onResized() {
    }
}
