@c8y/ngx-components
Version:
Angular modules for Cumulocity IoT applications
63 lines (58 loc) • 3.07 kB
JavaScript
import * as i0 from '@angular/core';
import { Injectable, NgModule } from '@angular/core';
import { hookTab } from '@c8y/ngx-components';
import { BrandingTabFactory, BRANDING_EDIT_CHILD_ROUTES, SharedBrandingModule } from '@c8y/ngx-components/branding/shared';
import { gettext } from '@c8y/ngx-components/gettext';
const advancedTabLabel = gettext('Advanced branding');
class PlainBrandingEditorTabFactory extends BrandingTabFactory {
getTabsForVersion(name) {
return [
{
path: this.getPathForBranding(name, 'advanced'),
label: advancedTabLabel,
icon: 'c8y-css',
priority: 200
}
];
}
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.25", ngImport: i0, type: PlainBrandingEditorTabFactory, deps: null, target: i0.ɵɵFactoryTarget.Injectable }); }
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "20.3.25", ngImport: i0, type: PlainBrandingEditorTabFactory, providedIn: 'root' }); }
}
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.25", ngImport: i0, type: PlainBrandingEditorTabFactory, decorators: [{
type: Injectable,
args: [{ providedIn: 'root' }]
}] });
function getBrandingOptionsJsonSchema() {
return import('c8y-schema-loader?interfaceName=BrandingOptionsJson&type=branding!@c8y/ngx-components/branding/shared/data')
.then(m => m.default || m)
.then(s => {
return s.schema;
});
}
BRANDING_EDIT_CHILD_ROUTES.push({
path: 'advanced',
loadComponent: () => import('@c8y/ngx-components/branding/plain-branding-editor/lazy').then(m => m.AdvancedEditBrandingComponent),
data: {
tabName: advancedTabLabel
},
resolve: {
editorSchema: getBrandingOptionsJsonSchema
}
});
class PlainBrandingEditorModule {
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.25", ngImport: i0, type: PlainBrandingEditorModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "20.3.25", ngImport: i0, type: PlainBrandingEditorModule, imports: [SharedBrandingModule] }); }
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "20.3.25", ngImport: i0, type: PlainBrandingEditorModule, providers: [hookTab(PlainBrandingEditorTabFactory)], imports: [SharedBrandingModule] }); }
}
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.25", ngImport: i0, type: PlainBrandingEditorModule, decorators: [{
type: NgModule,
args: [{
imports: [SharedBrandingModule],
providers: [hookTab(PlainBrandingEditorTabFactory)]
}]
}] });
/**
* Generated bundle index. Do not edit.
*/
export { PlainBrandingEditorModule, getBrandingOptionsJsonSchema };
//# sourceMappingURL=c8y-ngx-components-branding-plain-branding-editor.mjs.map