import { BaseView } from "../../BaseView.js";
import HeaderView from "./HeaderView.js";
import ContentView from "./ContentView.js";
import FooterView from "./FooterView.js";
export default class GridView extends BaseView {
    constructor(options) {
        super(options);
    }
    get content() {
        return this.m_content;
    }
    get source() {
        return super.source;
    }
    get header() {
        return this.m_header;
    }
    get footer() {
        return this.m_footer;
    }
    template() {
        return `<div class="-fb-grid"></div>`;
    }
    forEachInput(callback) {
        this.content.categories.each((category) => {
            category.inputs.each((input) => {
                callback(input);
            });
        });
    }
    onActivate(e) {
        super.onActivate(e);
        this.m_header = new HeaderView({
            source: this.source
        });
        this.controls.add(this.m_header);
        this.m_content = new ContentView({
            source: this.source
        });
        this.controls.add(this.m_content);
        this.m_footer = new FooterView({
            source: this.source,
            parent: this
        });
        this.controls.add(this.m_footer);
    }
}
