-
Notifications
You must be signed in to change notification settings - Fork 20
Legend panel
Raitis Berzins edited this page Oct 6, 2021
·
6 revisions
Legend panel gathers legends from all layers added to map and displays them in a list. They can be ImageWms, TileWms services for which legend is served by the WMS provider (geoserver, mapserver etc.) or Vector layers for which legend is derived from Openlayers style or SLD string. For that geostyler-legend library is used under the hood.
Add HsLegendModule module import:
import {HsLegendModule} from 'hslayers-ng';
@NgModule({
imports: [HsLegendModule],
})
export class YourAppModule {}
Add HsLegendPanel component:
import {HsLayoutService, HsLegendComponent} from 'hslayers-ng';
@Component({
selector: 'your-app-component',
templateUrl: 'your-app-component.html',
})
export class YourAppComponent {
constructor(hsLayoutService: HsLayoutService) {
hsLayoutService.createPanel(HsLegendComponent, {});
}
}
Quick Links: Home ➖ App configuration ➖ Layer configuration ➖ Cesium configuration ➖ Composition schema (separate repo)