|
|
@@ -10,24 +10,29 @@ export const HsComponent = {
|
|
|
return HsCore.hslayersNgTemplate;
|
|
|
},
|
|
|
bindings: {},
|
|
|
- controller: function (
|
|
|
- gettext,
|
|
|
- HsCore,
|
|
|
- HsLayoutService,
|
|
|
- HsSidebarService,
|
|
|
- AdjusterService,
|
|
|
- AppService
|
|
|
- ) {
|
|
|
- 'ngInject';
|
|
|
- const vm = this;
|
|
|
- vm.exists = HsCore.exists;
|
|
|
- vm.panelVisible = HsLayoutService.panelVisible;
|
|
|
- vm.PraAdjusterService = AdjusterService;
|
|
|
- HsLayoutService.sidebarRight = false;
|
|
|
- console.log(HsLayoutService.sidebarRight);
|
|
|
- // HsLayoutService.sidebarToggleable = false;
|
|
|
- // HsLayoutService.sidebarButtons = true;
|
|
|
- /*$scope.$on('scope_loaded', function (event, args) {
|
|
|
+ controllerAs: 'vm',
|
|
|
+ controller: class HsComponent {
|
|
|
+ exists;
|
|
|
+ panelVisible;
|
|
|
+ PraAdjusterService;
|
|
|
+ constructor(
|
|
|
+ gettext,
|
|
|
+ HsCore,
|
|
|
+ HsLayoutService,
|
|
|
+ HsSidebarService,
|
|
|
+ AdjusterService,
|
|
|
+ AppService
|
|
|
+ ) {
|
|
|
+ 'ngInject';
|
|
|
+ const vm = this;
|
|
|
+ vm.exists = HsCore.exists;
|
|
|
+ vm.panelVisible = HsLayoutService.panelVisible;
|
|
|
+ vm.PraAdjusterService = AdjusterService;
|
|
|
+ HsLayoutService.sidebarRight = false;
|
|
|
+ console.log(HsLayoutService.sidebarRight);
|
|
|
+ // HsLayoutService.sidebarToggleable = false;
|
|
|
+ // HsLayoutService.sidebarButtons = true;
|
|
|
+ /*$scope.$on('scope_loaded', function (event, args) {
|
|
|
if (args === 'Sidebar') {
|
|
|
const loader = angular.element(
|
|
|
'<pra-adjuster-loader class="loader-splash" ng-if="vm.PraAdjusterService.isClusteringInProcess()"></pra-adjuster-loader>'
|
|
|
@@ -38,13 +43,13 @@ export const HsComponent = {
|
|
|
$compile(loader)(event.targetScope);
|
|
|
}
|
|
|
});*/
|
|
|
- AdjusterService.clustersLoaded.subscribe(() => {
|
|
|
- colorPalette = generateRandomColorPalette(
|
|
|
- AdjusterService.clusters.length
|
|
|
- );
|
|
|
- });
|
|
|
+ AdjusterService.clustersLoaded.subscribe(() => {
|
|
|
+ colorPalette = generateRandomColorPalette(
|
|
|
+ AdjusterService.clusters.length
|
|
|
+ );
|
|
|
+ });
|
|
|
+ }
|
|
|
},
|
|
|
- controllerAs: 'vm',
|
|
|
};
|
|
|
|
|
|
// https://colorbrewer2.org/?type=qualitative&scheme=Paired&n=12
|