"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.MapProvider = void 0;
const helper_1 = require("../../helper");
const extension_provider_1 = require("../../integration/extension.provider");
const web_site_provider_1 = require("./../web-site/web-site.provider");
const map_const_1 = require("./map.const");
const map_service_1 = require("./map.service");
class MapProvider extends extension_provider_1.ExtensionProvider {
    constructor(app) {
        super(map_const_1.MAP_PROVIDER, app);
        this.app = app;
        app.addStaticDir('markercluster', 'node_modules/leaflet.markercluster/dist');
        this.requiredProviders.push(web_site_provider_1.WebSiteProvider);
        this.services.push({ cls: map_service_1.MapService });
        this.objectTypes.push(map_const_1.MAP_TEMPLATE_TYPE, map_const_1.MAP_TYPE, map_const_1.MAP_ENTRY_TYPE, map_const_1.MAP_PAGE_TYPE, map_const_1.MAP_ENTRIES_TYPE);
        this.objectTrees.map = {
            reset: false,
            parentNode: () => this.appCtx.publicTemplatesNode.value,
            treeNodeName: 'map',
            treeNodeTypeId: map_const_1.MAP_TEMPLATE_TYPE.name,
            tree: {
                treeNode: {
                    contentGenericTemplate: helper_1.contentGenericTemplate(__dirname, 'map'),
                },
                children: {},
            },
        };
        this.objectSubTypes.push(map_const_1.CATEGORY_MAP_TEMPLATE_SUBTYPE, map_const_1.MAP_PAGE_MAP_TEMPLATE_SUBTYPE);
    }
}
exports.MapProvider = MapProvider;
//# sourceMappingURL=map.provider.js.map