Common Configuration Options
SAMO Browser consists of samo-map/samo-lids-browser component, which has to be defined on the desired page among with the context.
using SAMO Browser in page - configuration example
{
"title": "simple Browser",
"security": {
"loggedIn": true
},
"hideMenu": true,
"module": {
"type": "component:samo-map/samo-lids-browser",
"context": "default"
}
}
Map contexts
Each project should contain some default context of the SAMO Browser. The default.json configuration file needs to be created in the following folder structure:
dynamic-app
│
└───samo-demo\configuration
│
└───map
│
└───default.json
Containing the following configuration:
{
"srsName": "EPSG:31467",
"defaultCenterX": 3451632,
"defaultCenterY": 5481774,
"defaultZoom": 6,
"scales": [
200000,
100000,
50000,
20000,
10000,
5000,
2000,
1000,
500,
200,
100
],
"restoreState": true,
"legends": {
"water": {
"src": "resource:legends/water.png"
},
"commons": {
"src": "resource:legends/common_objects.png"
}
},
/** ## See Toolbars Configuration ## **/
"toolbarsConfiguration": {
"context": "default-toolbar"
},
/** ## See Databar Configuration ## **/
"databar": {
"context": "default-databar"
},
/** ## See Layers Configuration ## **/
"layers": [
{
"id": "cat_5040000",
"legends": [
"commons"
]
},
{
"id": "setdefinition_80425981052865018"
},
{
"id": "cat_5060000"
},
"bd_06",
"external-osm-wms"
],
"backdropLayers": [
{
"id": "tms_orthophoto_2014",
"preview": "images/backdrops/orto2014.png"
},
{
"id": "bd_03",
"title": "City Map",
"preview": "images/backdrops/cityMap.png"
}
]
}
SAMO Browser supports multiple contexts, that can be extended.
siimple SAMO Browser context extending the default - configuration example
{
"extends": "default",
"layers": [
{
"id": "setdefinition_705890760039974",
"icon": "samo-demo-icons:water",
"legends": [
"water"
],
"visible": true
}
]
}