-
Notifications
You must be signed in to change notification settings - Fork 20
Search panel
Filip Leitner edited this page Apr 30, 2024
·
6 revisions
The search panel is designed to help the user find the location of a place quickly and easily. Each found location is marked on the map with a point feature.
List of useful config parameters for the search panel can be found here:
import {HsConfig} from 'hslayers-ng/config';
@Component({
selector: 'your-app-component',
templateUrl: 'your-app-component.html',
})
export class YourAppComponent {
constructor(hsConfig: HsConfig) {
this.HsConfig.update({
panelsEnabled: {
search: true //(false by default)
}
});
}
}
Add HsSearchModule import:
import {HsSearchModule} from 'hslayers-ng/components/search';
@NgModule({
imports: [HsSearchModule],
})
export class YourAppModule {}
Add HsSearchComponent component:
import {HsSearchModule} from 'hslayers-ng/components/search';
import {HsLayoutService } from 'hslayers-ng/core';
@Component({
selector: 'your-app-component',
templateUrl: 'your-app-component.html',
})
export class YourAppComponent {
constructor(hsLayoutService: HsLayoutService) {
hsLayoutService.createPanel(HsSearchComponent, {});
}
}
Quick Links: Home ➖ App configuration ➖ Layer configuration ➖ Cesium configuration ➖ Composition schema (separate repo)