qwc2 2025.11.18 → 2025.11.26
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/actions/windows.js +3 -1
- package/components/AppMenu.js +141 -204
- package/components/AttributeTableWidget.js +5 -1
- package/components/FeatureAttributesWindow.js +1 -2
- package/components/FullscreenSwitcher.js +3 -0
- package/components/Icon.js +6 -0
- package/components/ImportLayer.js +3 -9
- package/components/LayerInfoWindow.js +1 -2
- package/components/MapButton.js +2 -0
- package/components/NumericInputWindow.js +1 -2
- package/components/PickFeature.js +1 -1
- package/components/PluginsContainer.js +48 -6
- package/components/ResizeableWindow.js +18 -9
- package/components/SearchBox.js +117 -124
- package/components/ServiceInfoWindow.js +1 -2
- package/components/ThemeLayersListWindow.js +22 -11
- package/components/ThemeList.js +7 -2
- package/components/WindowManager.js +14 -2
- package/components/map/layers/VectorLayer.js +4 -2
- package/components/map3d/HeightProfile3D.js +0 -1
- package/components/map3d/Map3D.js +36 -35
- package/components/map3d/View3DSwitcher.js +2 -1
- package/components/map3d/drawtool/NumericInput3D.js +1 -2
- package/components/map3d/layers/GeoTIFFLayer3D.js +2 -1
- package/components/map3d/layers/VectorLayer3D.js +12 -2
- package/components/map3d/layers/WFSLayer3D.js +17 -1
- package/components/style/App.css +4 -0
- package/components/style/AppMenu.css +33 -48
- package/components/style/DefaultColorScheme.css +1 -0
- package/components/style/PickFeature.css +0 -6
- package/components/style/ResizeableWindow.css +0 -4
- package/components/style/SearchBox.css +0 -21
- package/components/style/WindowManager.css +6 -0
- package/components/widgets/ColorButton.js +7 -2
- package/components/widgets/ComboBox.js +18 -16
- package/components/widgets/EditableSelect.js +5 -10
- package/components/widgets/LayerCatalogWidget.js +66 -16
- package/components/widgets/MenuButton.js +16 -15
- package/components/widgets/PopupMenu.js +153 -13
- package/components/widgets/ToggleSwitch.js +5 -2
- package/components/widgets/style/ComboBox.css +7 -20
- package/components/widgets/style/EditableSelect.css +0 -2
- package/components/widgets/style/MenuButton.css +1 -17
- package/components/widgets/style/PopupMenu.css +20 -0
- package/package.json +2 -2
- package/plugins/AttributeTable.js +0 -1
- package/plugins/BackgroundSwitcher.js +104 -8
- package/plugins/Cyclomedia.js +1 -2
- package/plugins/FeatureForm.js +3 -6
- package/plugins/GeometryDigitizer.js +1 -2
- package/plugins/HeightProfile.js +2 -5
- package/plugins/Identify.js +2 -5
- package/plugins/LayerCatalog.js +2 -13
- package/plugins/LayerTree.js +22 -13
- package/plugins/MapLegend.js +1 -2
- package/plugins/ObjectList.js +0 -1
- package/plugins/Panoramax.js +1 -2
- package/plugins/Print.js +1 -2
- package/plugins/Routing.js +1 -2
- package/plugins/TimeManager.js +2 -5
- package/plugins/ValueTool.js +1 -2
- package/plugins/View3D.js +0 -1
- package/plugins/map/MeasurementSupport.js +2 -2
- package/plugins/map3d/Identify3D.js +1 -2
- package/plugins/map3d/Measure3D.js +21 -12
- package/plugins/style/BackgroundSwitcher.css +2 -1
- package/plugins/style/LayerTree.css +3 -18
- package/reducers/windows.js +2 -1
- package/static/translations/bg-BG.json +1 -0
- package/static/translations/ca-ES.json +29 -28
- package/static/translations/cs-CZ.json +1 -0
- package/static/translations/de-CH.json +1 -0
- package/static/translations/de-DE.json +1 -0
- package/static/translations/en-US.json +1 -0
- package/static/translations/es-ES.json +34 -33
- package/static/translations/fi-FI.json +1 -0
- package/static/translations/fr-FR.json +2 -1
- package/static/translations/hu-HU.json +1 -0
- package/static/translations/it-IT.json +1 -0
- package/static/translations/ja-JP.json +1 -0
- package/static/translations/nl-NL.json +1 -0
- package/static/translations/no-NO.json +1 -0
- package/static/translations/pl-PL.json +1 -0
- package/static/translations/pt-BR.json +1 -0
- package/static/translations/pt-PT.json +1 -0
- package/static/translations/ro-RO.json +1 -0
- package/static/translations/ru-RU.json +1 -0
- package/static/translations/sv-SE.json +1 -0
- package/static/translations/tr-TR.json +1 -0
- package/static/translations/tsconfig.json +1 -0
- package/static/translations/uk-UA.json +1 -0
- package/utils/MapUtils.js +6 -0
- package/utils/MiscUtils.js +12 -0
- package/utils/ThemeUtils.js +2 -1
|
@@ -23,6 +23,7 @@ function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e
|
|
|
23
23
|
import React from 'react';
|
|
24
24
|
import classnames from 'classnames';
|
|
25
25
|
import PropTypes from 'prop-types';
|
|
26
|
+
import MiscUtils from '../../utils/MiscUtils';
|
|
26
27
|
import Icon from '../Icon';
|
|
27
28
|
import './style/ToggleSwitch.css';
|
|
28
29
|
var ToggleSwitch = /*#__PURE__*/function (_React$Component) {
|
|
@@ -52,7 +53,9 @@ var ToggleSwitch = /*#__PURE__*/function (_React$Component) {
|
|
|
52
53
|
});
|
|
53
54
|
return /*#__PURE__*/React.createElement("div", {
|
|
54
55
|
className: classNames,
|
|
55
|
-
onClick: this.onClick
|
|
56
|
+
onClick: this.onClick,
|
|
57
|
+
onKeyDown: MiscUtils.checkKeyActivate,
|
|
58
|
+
tabIndex: 0
|
|
56
59
|
}, /*#__PURE__*/React.createElement("span", {
|
|
57
60
|
className: "toggle-switch-yes"
|
|
58
61
|
}, /*#__PURE__*/React.createElement(Icon, {
|
|
@@ -72,7 +75,7 @@ var ToggleSwitch = /*#__PURE__*/function (_React$Component) {
|
|
|
72
75
|
readOnly: this.props.readOnly,
|
|
73
76
|
required: this.props.required,
|
|
74
77
|
style: {
|
|
75
|
-
visibility: '
|
|
78
|
+
visibility: 'hidden'
|
|
76
79
|
},
|
|
77
80
|
type: "checkbox",
|
|
78
81
|
value: this.props.active
|
|
@@ -40,35 +40,18 @@ div.combobox-button > span.icon {
|
|
|
40
40
|
flex: 0 0 1em;
|
|
41
41
|
}
|
|
42
42
|
|
|
43
|
-
div.combobox-menu {
|
|
44
|
-
border: 1px solid var(--border-color);
|
|
45
|
-
background-color: var(--list-bg-color);
|
|
46
|
-
user-select: none;
|
|
47
|
-
-webkit-touch-callout: none;
|
|
48
|
-
-webkit-user-select: none;
|
|
49
|
-
}
|
|
50
|
-
|
|
51
43
|
div.combobox-menu-entry {
|
|
52
44
|
padding: 0.25em;
|
|
53
45
|
}
|
|
54
46
|
|
|
55
|
-
div.combobox-menu-entry:not(.combobox-menu-entry-disabled):hover {
|
|
56
|
-
background-color: var(--list-item-bg-color-hover);
|
|
57
|
-
color: var(--list-item-text-color-hover);
|
|
58
|
-
}
|
|
59
|
-
|
|
60
47
|
div.combobox-menu-entry-active {
|
|
61
48
|
background-color: var(--list-item-bg-color-active);
|
|
62
49
|
color: var(--list-item-text-color-active);
|
|
63
50
|
}
|
|
64
51
|
|
|
65
|
-
div.combobox-menu-entry-active:
|
|
66
|
-
background-color: var(--list-item-bg-color-active-hover)
|
|
67
|
-
color: var(--list-item-text-color-active-hover)
|
|
68
|
-
}
|
|
69
|
-
|
|
70
|
-
div.combobox-menu-entry-disabled {
|
|
71
|
-
color: var(--text-color-disabled);
|
|
52
|
+
div.combobox-menu-entry-active:focus {
|
|
53
|
+
background-color: var(--list-item-bg-color-active-hover);
|
|
54
|
+
color: var(--list-item-text-color-active-hover);
|
|
72
55
|
}
|
|
73
56
|
|
|
74
57
|
div.combobox-menu-entry-group-header {
|
|
@@ -78,6 +61,10 @@ div.combobox-menu-entry-group-header {
|
|
|
78
61
|
font-weight: bold;
|
|
79
62
|
}
|
|
80
63
|
|
|
64
|
+
div.combobox-menu-entry-group-header:focus {
|
|
65
|
+
background-color: var(--list-section-bg-color-hover);
|
|
66
|
+
}
|
|
67
|
+
|
|
81
68
|
div.combobox-menu-entry-group-header > span.icon {
|
|
82
69
|
flex: 0 0 auto;
|
|
83
70
|
}
|
|
@@ -11,10 +11,8 @@ div.editable-select-inputcontainer > span.icon-clear {
|
|
|
11
11
|
}
|
|
12
12
|
|
|
13
13
|
div.editable-select-dropdown {
|
|
14
|
-
border: 1px solid var(--border-color);
|
|
15
14
|
max-height: 8em;
|
|
16
15
|
overflow-y: auto;
|
|
17
|
-
background-color: var(--input-bg-color);
|
|
18
16
|
}
|
|
19
17
|
|
|
20
18
|
div.editable-select-dropdown > div {
|
|
@@ -64,36 +64,20 @@ div.menubutton-togglebutton span.menubotton-button-arrow {
|
|
|
64
64
|
border-left: 1px solid var(--border-color);
|
|
65
65
|
}
|
|
66
66
|
|
|
67
|
-
div.menubutton-menu {
|
|
68
|
-
background-color: var(--list-bg-color);
|
|
69
|
-
border: 1px solid var(--border-color);
|
|
70
|
-
color: var(--text-color);
|
|
71
|
-
box-shadow: 0px 2px 4px rgba(136, 136, 136, 0.5);
|
|
72
|
-
}
|
|
73
|
-
|
|
74
67
|
div.menubutton-menu > div {
|
|
75
68
|
padding: 0.25em;
|
|
76
69
|
}
|
|
77
70
|
|
|
78
|
-
div.menubutton-menu > div:hover {
|
|
79
|
-
background-color: var(--list-item-bg-color-hover);
|
|
80
|
-
color: var(--list-item-text-color-hover);
|
|
81
|
-
}
|
|
82
|
-
|
|
83
71
|
div.menubutton-menu > div.menubutton-menu-active {
|
|
84
72
|
background-color: var(--list-item-bg-color-active);
|
|
85
73
|
color: var(--list-item-text-color-active);
|
|
86
74
|
}
|
|
87
75
|
|
|
88
|
-
div.menubutton-menu > div.menubutton-menu-active:
|
|
76
|
+
div.menubutton-menu > div.menubutton-menu-active:focus {
|
|
89
77
|
background-color: var(--list-item-bg-color-active-hover);
|
|
90
78
|
color: var(--list-item-text-color-active-hover);
|
|
91
79
|
}
|
|
92
80
|
|
|
93
|
-
div.menubutton-menu-disabled {
|
|
94
|
-
color: var(--text-color-disabled);
|
|
95
|
-
}
|
|
96
|
-
|
|
97
81
|
span.menubutton-tooltip {
|
|
98
82
|
position: absolute;
|
|
99
83
|
display: none;
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
div.popup-menu {
|
|
2
|
+
background-color: var(--list-bg-color);
|
|
3
|
+
border: 1px solid var(--border-color);
|
|
4
|
+
color: var(--text-color);
|
|
5
|
+
box-shadow: 0px 2px 4px rgba(136, 136, 136, 0.5);
|
|
6
|
+
}
|
|
7
|
+
|
|
8
|
+
div.popup-menu:focus {
|
|
9
|
+
outline: none;
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
div.popup-menu-item-disabled {
|
|
13
|
+
color: var(--text-color-disabled);
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
div.popup-menu > *:focus {
|
|
17
|
+
background-color: var(--list-item-bg-color-hover);
|
|
18
|
+
color: var(--list-item-text-color-hover);
|
|
19
|
+
outline: none;
|
|
20
|
+
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "qwc2",
|
|
3
|
-
"version": "2025.11.
|
|
3
|
+
"version": "2025.11.26",
|
|
4
4
|
"description": "QGIS Web Client",
|
|
5
5
|
"author": "Sourcepole AG",
|
|
6
6
|
"license": "BSD-2-Clause",
|
|
@@ -17,7 +17,7 @@
|
|
|
17
17
|
],
|
|
18
18
|
"dependencies": {
|
|
19
19
|
"@furkot/webfonts-generator": "^2.0.2",
|
|
20
|
-
"@
|
|
20
|
+
"@sourcepole/qwc-giro3d": "^0.44.0-dev",
|
|
21
21
|
"@kayahr/text-encoding": "^2.0.0",
|
|
22
22
|
"@loaders.gl/core": "^4.3.3",
|
|
23
23
|
"@loaders.gl/shapefile": "^4.3.3",
|
|
@@ -76,7 +76,6 @@ var AttributeTable = /*#__PURE__*/function (_React$Component) {
|
|
|
76
76
|
iface: this.props.iface,
|
|
77
77
|
initialLayer: (_this$props$taskData = this.props.taskData) === null || _this$props$taskData === void 0 ? void 0 : _this$props$taskData.layer,
|
|
78
78
|
limitToExtent: this.props.limitToExtent,
|
|
79
|
-
role: "body",
|
|
80
79
|
showEditFormButton: this.props.showEditFormButton,
|
|
81
80
|
showHiddenFields: this.props.showHiddenFields,
|
|
82
81
|
showLimitToExtent: this.props.showLimitToExtent,
|
|
@@ -1,4 +1,10 @@
|
|
|
1
1
|
function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
|
|
2
|
+
function _toConsumableArray(r) { return _arrayWithoutHoles(r) || _iterableToArray(r) || _unsupportedIterableToArray(r) || _nonIterableSpread(); }
|
|
3
|
+
function _nonIterableSpread() { throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
4
|
+
function _unsupportedIterableToArray(r, a) { if (r) { if ("string" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }
|
|
5
|
+
function _iterableToArray(r) { if ("undefined" != typeof Symbol && null != r[Symbol.iterator] || null != r["@@iterator"]) return Array.from(r); }
|
|
6
|
+
function _arrayWithoutHoles(r) { if (Array.isArray(r)) return _arrayLikeToArray(r); }
|
|
7
|
+
function _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }
|
|
2
8
|
function _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError("Cannot call a class as a function"); }
|
|
3
9
|
function _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, "value" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }
|
|
4
10
|
function _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, "prototype", { writable: !1 }), e; }
|
|
@@ -30,19 +36,17 @@ import Icon from '../components/Icon';
|
|
|
30
36
|
import MapButton from '../components/MapButton';
|
|
31
37
|
import ConfigUtils from '../utils/ConfigUtils';
|
|
32
38
|
import LocaleUtils from '../utils/LocaleUtils';
|
|
39
|
+
import MiscUtils from '../utils/MiscUtils';
|
|
33
40
|
import './style/BackgroundSwitcher.css';
|
|
34
41
|
|
|
35
42
|
/**
|
|
36
43
|
* Map button for switching the background layer.
|
|
37
44
|
*/
|
|
38
45
|
export var BackgroundSwitcher = /*#__PURE__*/function (_React$Component) {
|
|
39
|
-
function BackgroundSwitcher() {
|
|
46
|
+
function BackgroundSwitcher(props) {
|
|
40
47
|
var _this;
|
|
41
48
|
_classCallCheck(this, BackgroundSwitcher);
|
|
42
|
-
|
|
43
|
-
args[_key] = arguments[_key];
|
|
44
|
-
}
|
|
45
|
-
_this = _callSuper(this, BackgroundSwitcher, [].concat(args));
|
|
49
|
+
_this = _callSuper(this, BackgroundSwitcher, [props]);
|
|
46
50
|
_defineProperty(_this, "state", {
|
|
47
51
|
visible: false
|
|
48
52
|
});
|
|
@@ -61,10 +65,13 @@ export var BackgroundSwitcher = /*#__PURE__*/function (_React$Component) {
|
|
|
61
65
|
key: layer ? layer.name : "empty",
|
|
62
66
|
onClick: function onClick() {
|
|
63
67
|
return _this.backgroundLayerClicked(layer);
|
|
64
|
-
}
|
|
68
|
+
},
|
|
69
|
+
onKeyDown: _this.KeyNav,
|
|
70
|
+
tabIndex: _this.state.visible ? 0 : -1
|
|
65
71
|
}, /*#__PURE__*/React.createElement("div", {
|
|
66
72
|
className: "background-switcher-item-title"
|
|
67
73
|
}, layer ? /*#__PURE__*/React.createElement("span", {
|
|
74
|
+
tabIndex: -1,
|
|
68
75
|
title: _this.itemTitle(layer)
|
|
69
76
|
}, _this.itemTitle(layer)) : /*#__PURE__*/React.createElement("span", null, LocaleUtils.tr("bgswitcher.nobg"))), /*#__PURE__*/React.createElement("div", {
|
|
70
77
|
className: "background-switcher-item-thumbnail"
|
|
@@ -85,10 +92,13 @@ export var BackgroundSwitcher = /*#__PURE__*/function (_React$Component) {
|
|
|
85
92
|
});
|
|
86
93
|
return /*#__PURE__*/React.createElement("div", {
|
|
87
94
|
className: itemclasses,
|
|
88
|
-
key: layer.name
|
|
95
|
+
key: layer.name,
|
|
96
|
+
onKeyDown: _this.KeyNav,
|
|
97
|
+
tabIndex: _this.state.visible ? 0 : -1
|
|
89
98
|
}, /*#__PURE__*/React.createElement("div", {
|
|
90
99
|
className: "background-switcher-item-title"
|
|
91
100
|
}, /*#__PURE__*/React.createElement("span", {
|
|
101
|
+
tabIndex: "-1",
|
|
92
102
|
title: _this.itemTitle(layer)
|
|
93
103
|
}, _this.itemTitle(layer)), /*#__PURE__*/React.createElement(Icon, {
|
|
94
104
|
icon: "chevron-down"
|
|
@@ -109,15 +119,23 @@ export var BackgroundSwitcher = /*#__PURE__*/function (_React$Component) {
|
|
|
109
119
|
return /*#__PURE__*/React.createElement("div", {
|
|
110
120
|
className: menuitemclasses,
|
|
111
121
|
key: l.name,
|
|
122
|
+
onBlur: function onBlur(ev) {
|
|
123
|
+
return _this.updateGroupItem(ev, layer);
|
|
124
|
+
},
|
|
112
125
|
onClick: function onClick() {
|
|
113
126
|
return _this.backgroundLayerClicked(l);
|
|
114
127
|
},
|
|
128
|
+
onFocus: function onFocus(ev) {
|
|
129
|
+
return _this.updateGroupItem(ev, l);
|
|
130
|
+
},
|
|
131
|
+
onKeyDown: _this.KeyNav,
|
|
115
132
|
onMouseEnter: function onMouseEnter(ev) {
|
|
116
133
|
return _this.updateGroupItem(ev, l);
|
|
117
134
|
},
|
|
118
135
|
onMouseLeave: function onMouseLeave(ev) {
|
|
119
136
|
return _this.updateGroupItem(ev, layer);
|
|
120
137
|
},
|
|
138
|
+
tabIndex: 0,
|
|
121
139
|
title: _this.itemTitle(l)
|
|
122
140
|
}, _this.itemTitle(l));
|
|
123
141
|
})));
|
|
@@ -127,6 +145,60 @@ export var BackgroundSwitcher = /*#__PURE__*/function (_React$Component) {
|
|
|
127
145
|
ev.target.parentElement.parentElement.childNodes[0].firstChild.innerText = _this.itemTitle(layer);
|
|
128
146
|
ev.target.parentElement.parentElement.childNodes[1].firstChild.src = assetsPath + "/" + layer.thumbnail;
|
|
129
147
|
});
|
|
148
|
+
_defineProperty(_this, "KeyNav", function (ev) {
|
|
149
|
+
if (ev.key === "ArrowUp" || ev.key === "ArrowDown") {
|
|
150
|
+
var group = null;
|
|
151
|
+
if (ev.target.parentElement.classList.contains("background-switcher-group")) {
|
|
152
|
+
group = ev.target.parentElement;
|
|
153
|
+
} else {
|
|
154
|
+
group = ev.target.getElementsByClassName("background-switcher-group")[0];
|
|
155
|
+
}
|
|
156
|
+
if (!group) {
|
|
157
|
+
return;
|
|
158
|
+
}
|
|
159
|
+
var childCount = group.children.length;
|
|
160
|
+
var delta = ev.key === 'ArrowUp' ? -1 : 1;
|
|
161
|
+
var currentIndex = Array.from(group.children).findIndex(function (el) {
|
|
162
|
+
return document.activeElement === el || el.contains(document.activeElement);
|
|
163
|
+
});
|
|
164
|
+
if (currentIndex === -1) {
|
|
165
|
+
currentIndex = Array.from(group.children).findIndex(function (el) {
|
|
166
|
+
return el.classList.contains("background-switcher-group-item-active");
|
|
167
|
+
});
|
|
168
|
+
}
|
|
169
|
+
var next = (currentIndex + childCount + delta) % childCount;
|
|
170
|
+
while (group.children[next].tabIndex !== 0 && next !== currentIndex) {
|
|
171
|
+
next = (next + childCount + delta) % childCount;
|
|
172
|
+
}
|
|
173
|
+
if (next !== currentIndex) {
|
|
174
|
+
group.children[next].focus();
|
|
175
|
+
}
|
|
176
|
+
MiscUtils.killEvent(ev);
|
|
177
|
+
} else if (ev.key === "Tab") {
|
|
178
|
+
// Move to next tile
|
|
179
|
+
var current = _toConsumableArray(_this.listEl.children).find(function (el) {
|
|
180
|
+
return el === document.activeElement || el.contains(document.activeElement);
|
|
181
|
+
});
|
|
182
|
+
if (current) {
|
|
183
|
+
if (ev.shiftKey) {
|
|
184
|
+
if (current.previousElementSibling) {
|
|
185
|
+
current.previousElementSibling.focus();
|
|
186
|
+
} else {
|
|
187
|
+
_this.listEl.children[_this.listEl.children.length - 1].focus();
|
|
188
|
+
}
|
|
189
|
+
} else {
|
|
190
|
+
if (current.nextElementSibling) {
|
|
191
|
+
current.nextElementSibling.focus();
|
|
192
|
+
} else {
|
|
193
|
+
_this.listEl.children[0].focus();
|
|
194
|
+
}
|
|
195
|
+
}
|
|
196
|
+
}
|
|
197
|
+
MiscUtils.killEvent(ev);
|
|
198
|
+
} else {
|
|
199
|
+
MiscUtils.checkKeyActivate(ev, _this.hide);
|
|
200
|
+
}
|
|
201
|
+
});
|
|
130
202
|
_defineProperty(_this, "buttonClicked", function () {
|
|
131
203
|
_this.setState(function (state) {
|
|
132
204
|
return {
|
|
@@ -149,10 +221,28 @@ export var BackgroundSwitcher = /*#__PURE__*/function (_React$Component) {
|
|
|
149
221
|
visible: false
|
|
150
222
|
});
|
|
151
223
|
});
|
|
224
|
+
_defineProperty(_this, "hide", function () {
|
|
225
|
+
_this.setState({
|
|
226
|
+
visible: false
|
|
227
|
+
});
|
|
228
|
+
});
|
|
229
|
+
_this.buttonEl = null;
|
|
230
|
+
_this.listEl = null;
|
|
152
231
|
return _this;
|
|
153
232
|
}
|
|
154
233
|
_inherits(BackgroundSwitcher, _React$Component);
|
|
155
234
|
return _createClass(BackgroundSwitcher, [{
|
|
235
|
+
key: "componentDidUpdate",
|
|
236
|
+
value: function componentDidUpdate(prevProps, prevState) {
|
|
237
|
+
if (this.state.visible && !prevState.visible) {
|
|
238
|
+
var _this$listEl, _this$listEl$focus;
|
|
239
|
+
(_this$listEl = this.listEl) === null || _this$listEl === void 0 || (_this$listEl = _this$listEl.firstElementChild) === null || _this$listEl === void 0 || (_this$listEl$focus = _this$listEl.focus) === null || _this$listEl$focus === void 0 || _this$listEl$focus.call(_this$listEl);
|
|
240
|
+
} else if (!this.state.visible && prevState.visible) {
|
|
241
|
+
var _this$buttonEl, _this$buttonEl$focus;
|
|
242
|
+
(_this$buttonEl = this.buttonEl) === null || _this$buttonEl === void 0 || (_this$buttonEl$focus = _this$buttonEl.focus) === null || _this$buttonEl$focus === void 0 || _this$buttonEl$focus.call(_this$buttonEl);
|
|
243
|
+
}
|
|
244
|
+
}
|
|
245
|
+
}, {
|
|
156
246
|
key: "render",
|
|
157
247
|
value: function render() {
|
|
158
248
|
var _this2 = this;
|
|
@@ -185,12 +275,18 @@ export var BackgroundSwitcher = /*#__PURE__*/function (_React$Component) {
|
|
|
185
275
|
if (entries.length > 0) {
|
|
186
276
|
return /*#__PURE__*/React.createElement(MapButton, {
|
|
187
277
|
active: this.state.visible,
|
|
278
|
+
buttonRef: function buttonRef(el) {
|
|
279
|
+
_this2.buttonEl = el;
|
|
280
|
+
},
|
|
188
281
|
icon: "bglayer",
|
|
189
282
|
onClick: this.buttonClicked,
|
|
190
283
|
position: this.props.position,
|
|
191
284
|
tooltip: LocaleUtils.tr("tooltip.background")
|
|
192
285
|
}, /*#__PURE__*/React.createElement("div", {
|
|
193
|
-
className: "background-switcher " + (this.state.visible ? 'background-switcher-active' : '')
|
|
286
|
+
className: "background-switcher " + (this.state.visible ? 'background-switcher-active' : ''),
|
|
287
|
+
ref: function ref(el) {
|
|
288
|
+
_this2.listEl = el;
|
|
289
|
+
}
|
|
194
290
|
}, this.renderLayerItem(null, backgroundLayers.filter(function (layer) {
|
|
195
291
|
return layer.visibility === true;
|
|
196
292
|
}).length === 0), entries.map(function (entry) {
|
package/plugins/Cyclomedia.js
CHANGED
|
@@ -358,8 +358,7 @@ var Cyclomedia = /*#__PURE__*/function (_React$Component) {
|
|
|
358
358
|
title: LocaleUtils.tr("cyclomedia.title"),
|
|
359
359
|
usePortal: false
|
|
360
360
|
}, /*#__PURE__*/React.createElement("div", {
|
|
361
|
-
className: "cyclomedia-body"
|
|
362
|
-
role: "body"
|
|
361
|
+
className: "cyclomedia-body"
|
|
363
362
|
}, this.props.mapScale > this.props.maxMapScale && this.state.status > Status.LOGIN ? /*#__PURE__*/React.createElement("div", {
|
|
364
363
|
className: "cyclomedia-scale-hint"
|
|
365
364
|
}, LocaleUtils.tr("cyclomedia.scalehint", this.props.maxMapScale)) : null, this.state.status > Status.LOGIN ? /*#__PURE__*/React.createElement("iframe", {
|
package/plugins/FeatureForm.js
CHANGED
|
@@ -224,15 +224,13 @@ var FeatureForm = /*#__PURE__*/function (_React$Component) {
|
|
|
224
224
|
var body = null;
|
|
225
225
|
if (this.state.pendingRequests > 0) {
|
|
226
226
|
body = /*#__PURE__*/React.createElement("div", {
|
|
227
|
-
className: "feature-query-body"
|
|
228
|
-
role: "body"
|
|
227
|
+
className: "feature-query-body"
|
|
229
228
|
}, /*#__PURE__*/React.createElement("span", {
|
|
230
229
|
className: "identify-body-message"
|
|
231
230
|
}, LocaleUtils.tr("featureform.querying")));
|
|
232
231
|
} else if (isEmpty(this.state.pickedFeatures)) {
|
|
233
232
|
body = /*#__PURE__*/React.createElement("div", {
|
|
234
|
-
className: "feature-query-body"
|
|
235
|
-
role: "body"
|
|
233
|
+
className: "feature-query-body"
|
|
236
234
|
}, /*#__PURE__*/React.createElement("span", {
|
|
237
235
|
className: "identify-body-message"
|
|
238
236
|
}, LocaleUtils.tr("featureform.noresults")));
|
|
@@ -252,8 +250,7 @@ var FeatureForm = /*#__PURE__*/function (_React$Component) {
|
|
|
252
250
|
});
|
|
253
251
|
}
|
|
254
252
|
body = /*#__PURE__*/React.createElement("div", {
|
|
255
|
-
className: "feature-query-body"
|
|
256
|
-
role: "body"
|
|
253
|
+
className: "feature-query-body"
|
|
257
254
|
}, Object.keys(this.state.pickedFeatures).length > 1 ? /*#__PURE__*/React.createElement("div", {
|
|
258
255
|
className: "feature-query-selection"
|
|
259
256
|
}, /*#__PURE__*/React.createElement("select", {
|
|
@@ -332,8 +332,7 @@ var GeometryDigitizer = /*#__PURE__*/function (_React$Component) {
|
|
|
332
332
|
title: _this.state.outputWindowTitle,
|
|
333
333
|
visible: _this.state.outputWindowVisible
|
|
334
334
|
}, /*#__PURE__*/React.createElement("div", {
|
|
335
|
-
className: "geomdigitizer-output-window-body"
|
|
336
|
-
role: "body"
|
|
335
|
+
className: "geomdigitizer-output-window-body"
|
|
337
336
|
}, !_this.state.outputLoaded ? /*#__PURE__*/React.createElement("span", {
|
|
338
337
|
className: "geomdigitizer-output-window-wait"
|
|
339
338
|
}, /*#__PURE__*/React.createElement(Spinner, null), " ", /*#__PURE__*/React.createElement("span", null, LocaleUtils.tr("geomdigitizer.wait"))) : null, /*#__PURE__*/React.createElement("iframe", {
|
package/plugins/HeightProfile.js
CHANGED
|
@@ -299,8 +299,7 @@ var HeightProfile = /*#__PURE__*/function (_React$Component) {
|
|
|
299
299
|
}
|
|
300
300
|
if (_this3.state.data.error) {
|
|
301
301
|
return /*#__PURE__*/React.createElement("div", {
|
|
302
|
-
className: "height-profile-error"
|
|
303
|
-
role: "body"
|
|
302
|
+
className: "height-profile-error"
|
|
304
303
|
}, LocaleUtils.tr("heightprofile.error") + ": " + _this3.state.data.error);
|
|
305
304
|
}
|
|
306
305
|
var distanceStr = LocaleUtils.tr("heightprofile.distance");
|
|
@@ -449,7 +448,6 @@ var HeightProfile = /*#__PURE__*/function (_React$Component) {
|
|
|
449
448
|
}
|
|
450
449
|
return /*#__PURE__*/React.createElement("div", {
|
|
451
450
|
className: "height-profile-chart-container",
|
|
452
|
-
role: "body",
|
|
453
451
|
style: {
|
|
454
452
|
position: 'relative'
|
|
455
453
|
}
|
|
@@ -735,8 +733,7 @@ var HeightProfile = /*#__PURE__*/function (_React$Component) {
|
|
|
735
733
|
title: LocaleUtils.tr("heightprofile.title"),
|
|
736
734
|
usePortal: false
|
|
737
735
|
}, this.state.isloading ? /*#__PURE__*/React.createElement("div", {
|
|
738
|
-
className: "height-profile-loading-indicator"
|
|
739
|
-
role: "body"
|
|
736
|
+
className: "height-profile-loading-indicator"
|
|
740
737
|
}, /*#__PURE__*/React.createElement(Spinner, {
|
|
741
738
|
className: "spinner"
|
|
742
739
|
}), " ", LocaleUtils.tr("heightprofile.loading")) : this.renderHeightProfile(function (el) {
|
package/plugins/Identify.js
CHANGED
|
@@ -389,15 +389,13 @@ var Identify = /*#__PURE__*/function (_React$Component) {
|
|
|
389
389
|
if (isEmpty(this.state.identifyResults)) {
|
|
390
390
|
if (this.state.pendingRequests > 0) {
|
|
391
391
|
body = /*#__PURE__*/React.createElement("div", {
|
|
392
|
-
className: "identify-body"
|
|
393
|
-
role: "body"
|
|
392
|
+
className: "identify-body"
|
|
394
393
|
}, /*#__PURE__*/React.createElement("span", {
|
|
395
394
|
className: "identify-body-message"
|
|
396
395
|
}, LocaleUtils.tr("identify.querying")));
|
|
397
396
|
} else {
|
|
398
397
|
body = /*#__PURE__*/React.createElement("div", {
|
|
399
|
-
className: "identify-body"
|
|
400
|
-
role: "body"
|
|
398
|
+
className: "identify-body"
|
|
401
399
|
}, /*#__PURE__*/React.createElement("span", {
|
|
402
400
|
className: "identify-body-message"
|
|
403
401
|
}, LocaleUtils.tr("identify.noresults")));
|
|
@@ -417,7 +415,6 @@ var Identify = /*#__PURE__*/function (_React$Component) {
|
|
|
417
415
|
longAttributesDisplay: this.props.longAttributesDisplay,
|
|
418
416
|
replaceImageUrls: this.props.replaceImageUrls,
|
|
419
417
|
resultDisplayMode: this.props.resultDisplayMode,
|
|
420
|
-
role: "body",
|
|
421
418
|
showLayerSelector: this.props.showLayerSelector
|
|
422
419
|
});
|
|
423
420
|
}
|
package/plugins/LayerCatalog.js
CHANGED
|
@@ -25,7 +25,6 @@ import { connect } from 'react-redux';
|
|
|
25
25
|
import axios from 'axios';
|
|
26
26
|
import { remove as removeDiacritics } from 'diacritics';
|
|
27
27
|
import PropTypes from 'prop-types';
|
|
28
|
-
import { addLayer, removeLayer, replacePlaceholderLayer } from '../actions/layers';
|
|
29
28
|
import { setCurrentTask } from '../actions/task';
|
|
30
29
|
import ResizeableWindow from '../components/ResizeableWindow';
|
|
31
30
|
import LayerCatalogWidget from '../components/widgets/LayerCatalogWidget';
|
|
@@ -197,22 +196,17 @@ var LayerCatalog = /*#__PURE__*/function (_React$Component) {
|
|
|
197
196
|
onClose: this.onClose,
|
|
198
197
|
title: LocaleUtils.tr("layercatalog.windowtitle")
|
|
199
198
|
}, /*#__PURE__*/React.createElement("div", {
|
|
200
|
-
className: "layer-catalog"
|
|
201
|
-
role: "body"
|
|
199
|
+
className: "layer-catalog"
|
|
202
200
|
}, /*#__PURE__*/React.createElement(LayerCatalogWidget, {
|
|
203
|
-
addLayer: this.props.addLayer,
|
|
204
201
|
catalog: this.state.catalog,
|
|
205
202
|
levelBasedIndentSize: this.props.levelBasedIndentSize,
|
|
206
|
-
pendingRequests: 0
|
|
207
|
-
removeLayer: this.props.removeLayer,
|
|
208
|
-
replacePlaceholderLayer: this.props.replacePlaceholderLayer
|
|
203
|
+
pendingRequests: 0
|
|
209
204
|
})));
|
|
210
205
|
}
|
|
211
206
|
}]);
|
|
212
207
|
}(React.Component);
|
|
213
208
|
_defineProperty(LayerCatalog, "propTypes", {
|
|
214
209
|
active: PropTypes.bool,
|
|
215
|
-
addLayer: PropTypes.func,
|
|
216
210
|
/** The URL to the catalog JSON file. */
|
|
217
211
|
catalogUrl: PropTypes.string,
|
|
218
212
|
/** Default window geometry with size, position and docking status. Positive position values (including '0') are related to top (InitialY) and left (InitialX), negative values (including '-0') to bottom (InitialY) and right (InitialX). */
|
|
@@ -228,8 +222,6 @@ _defineProperty(LayerCatalog, "propTypes", {
|
|
|
228
222
|
levelBasedIndentSize: PropTypes.bool,
|
|
229
223
|
/** Whether to register a search provider which allows searching catalog layers through the global search field. */
|
|
230
224
|
registerCatalogSearchProvider: PropTypes.bool,
|
|
231
|
-
removeLayer: PropTypes.func,
|
|
232
|
-
replacePlaceholderLayer: PropTypes.func,
|
|
233
225
|
setCurrentTask: PropTypes.func
|
|
234
226
|
});
|
|
235
227
|
_defineProperty(LayerCatalog, "defaultProps", {
|
|
@@ -249,8 +241,5 @@ export default connect(function (state) {
|
|
|
249
241
|
active: state.task.id === "LayerCatalog"
|
|
250
242
|
};
|
|
251
243
|
}, {
|
|
252
|
-
addLayer: addLayer,
|
|
253
|
-
removeLayer: removeLayer,
|
|
254
|
-
replacePlaceholderLayer: replacePlaceholderLayer,
|
|
255
244
|
setCurrentTask: setCurrentTask
|
|
256
245
|
})(LayerCatalog);
|
package/plugins/LayerTree.js
CHANGED
|
@@ -51,6 +51,7 @@ import LayerInfoWindow from '../components/LayerInfoWindow';
|
|
|
51
51
|
import ResizeableWindow from '../components/ResizeableWindow';
|
|
52
52
|
import ServiceInfoWindow from '../components/ServiceInfoWindow';
|
|
53
53
|
import SideBar from '../components/SideBar';
|
|
54
|
+
import PopupMenu from '../components/widgets/PopupMenu';
|
|
54
55
|
import { Image } from '../components/widgets/Primitives';
|
|
55
56
|
import Spinner from '../components/widgets/Spinner';
|
|
56
57
|
import ConfigUtils from '../utils/ConfigUtils';
|
|
@@ -505,7 +506,9 @@ var LayerTree = /*#__PURE__*/function (_React$Component) {
|
|
|
505
506
|
key: name,
|
|
506
507
|
onClick: function onClick() {
|
|
507
508
|
return onStyleChange(name);
|
|
508
|
-
}
|
|
509
|
+
},
|
|
510
|
+
onKeyDown: MiscUtils.checkKeyActivate,
|
|
511
|
+
tabIndex: 0
|
|
509
512
|
}, /*#__PURE__*/React.createElement(Icon, {
|
|
510
513
|
icon: selectedStyles.includes(name) ? checkedIcon : "radio_unchecked"
|
|
511
514
|
}), /*#__PURE__*/React.createElement("div", null, title));
|
|
@@ -588,7 +591,9 @@ var LayerTree = /*#__PURE__*/function (_React$Component) {
|
|
|
588
591
|
if (_this.props.allowImport) {
|
|
589
592
|
layerImportExpander = /*#__PURE__*/React.createElement("div", {
|
|
590
593
|
className: "layertree-option",
|
|
591
|
-
onClick: _this.toggleImportLayers
|
|
594
|
+
onClick: _this.toggleImportLayers,
|
|
595
|
+
onKeyDown: MiscUtils.checkKeyActivate,
|
|
596
|
+
tabIndex: 0
|
|
592
597
|
}, /*#__PURE__*/React.createElement(Icon, {
|
|
593
598
|
icon: _this.state.importvisible ? 'collapse' : 'expand'
|
|
594
599
|
}), " ", LocaleUtils.tr("layertree.importlayer"));
|
|
@@ -663,12 +668,6 @@ var LayerTree = /*#__PURE__*/function (_React$Component) {
|
|
|
663
668
|
"layertree-visibility-button": true,
|
|
664
669
|
"layertree-visibility-button-active": _this.state.visibilityMenu
|
|
665
670
|
});
|
|
666
|
-
var style = {};
|
|
667
|
-
if (_this.props.side === 'left') {
|
|
668
|
-
style.left = 0;
|
|
669
|
-
} else {
|
|
670
|
-
style.right = 0;
|
|
671
|
-
}
|
|
672
671
|
return /*#__PURE__*/React.createElement("span", {
|
|
673
672
|
className: buttonClasses,
|
|
674
673
|
onClick: function onClick() {
|
|
@@ -677,14 +676,24 @@ var LayerTree = /*#__PURE__*/function (_React$Component) {
|
|
|
677
676
|
visibilityMenu: !state.visibilityMenu
|
|
678
677
|
};
|
|
679
678
|
});
|
|
680
|
-
}
|
|
679
|
+
},
|
|
680
|
+
onKeyDown: MiscUtils.checkKeyActivate,
|
|
681
|
+
ref: function ref(el) {
|
|
682
|
+
_this.visibilityButton = el;
|
|
683
|
+
},
|
|
684
|
+
tabIndex: 0
|
|
681
685
|
}, /*#__PURE__*/React.createElement(Icon, {
|
|
682
686
|
icon: "eye"
|
|
683
687
|
}), /*#__PURE__*/React.createElement(Icon, {
|
|
684
688
|
icon: "chevron-down"
|
|
685
|
-
}), _this.state.visibilityMenu ? /*#__PURE__*/React.createElement(
|
|
689
|
+
}), _this.state.visibilityMenu ? /*#__PURE__*/React.createElement(PopupMenu, {
|
|
690
|
+
anchor: _this.visibilityButton,
|
|
686
691
|
className: "layertree-visibility-menu",
|
|
687
|
-
|
|
692
|
+
onClose: function onClose() {
|
|
693
|
+
return _this.setState({
|
|
694
|
+
visibilityMenu: false
|
|
695
|
+
});
|
|
696
|
+
}
|
|
688
697
|
}, _this.props.showToggleAllLayersCheckbox ? /*#__PURE__*/React.createElement("div", {
|
|
689
698
|
onClick: function onClick() {
|
|
690
699
|
return _this.toggleLayerTreeVisibility(vis === 0);
|
|
@@ -760,8 +769,7 @@ var LayerTree = /*#__PURE__*/function (_React$Component) {
|
|
|
760
769
|
},
|
|
761
770
|
title: LocaleUtils.tr("layertree.printlegend")
|
|
762
771
|
}, /*#__PURE__*/React.createElement("div", {
|
|
763
|
-
className: "layertree-legend-print-body"
|
|
764
|
-
role: "body"
|
|
772
|
+
className: "layertree-legend-print-body"
|
|
765
773
|
}, /*#__PURE__*/React.createElement("iframe", {
|
|
766
774
|
ref: setLegendPrintContents,
|
|
767
775
|
src: MiscUtils.resolveAssetsPath(_this.props.templatePath)
|
|
@@ -966,6 +974,7 @@ var LayerTree = /*#__PURE__*/function (_React$Component) {
|
|
|
966
974
|
}
|
|
967
975
|
});
|
|
968
976
|
});
|
|
977
|
+
_this.visibilityButton = null;
|
|
969
978
|
_this.legendPrintWindow = null;
|
|
970
979
|
window.addEventListener('beforeunload', function () {
|
|
971
980
|
if (_this.legendPrintWindow && !_this.legendPrintWindow.closed) {
|
package/plugins/MapLegend.js
CHANGED
|
@@ -179,8 +179,7 @@ var MapLegend = /*#__PURE__*/function (_React$Component) {
|
|
|
179
179
|
onClose: this.props.lockedWindow ? null : this.onClose,
|
|
180
180
|
title: LocaleUtils.tr("maplegend.windowtitle")
|
|
181
181
|
}, /*#__PURE__*/React.createElement("div", {
|
|
182
|
-
className: "map-legend"
|
|
183
|
-
role: "body"
|
|
182
|
+
className: "map-legend"
|
|
184
183
|
}, this.props.layers.map(function (layer) {
|
|
185
184
|
if (_this2.state.onlyVisibleLegend && !layer.visibility) {
|
|
186
185
|
return null;
|
package/plugins/ObjectList.js
CHANGED
|
@@ -74,7 +74,6 @@ var ObjectList = /*#__PURE__*/function (_React$Component) {
|
|
|
74
74
|
initialLayer: (_this$props$taskData = this.props.taskData) === null || _this$props$taskData === void 0 ? void 0 : _this$props$taskData.layer,
|
|
75
75
|
limitToExtent: this.props.limitToExtent,
|
|
76
76
|
readOnly: true,
|
|
77
|
-
role: "body",
|
|
78
77
|
showDisplayFieldOnly: true,
|
|
79
78
|
showEditFormButton: false,
|
|
80
79
|
showHiddenFields: false,
|
package/plugins/Panoramax.js
CHANGED
|
@@ -237,8 +237,7 @@ var Panoramax = /*#__PURE__*/function (_React$Component) {
|
|
|
237
237
|
splitScreenWhenDocked: true,
|
|
238
238
|
title: LocaleUtils.tr("panoramax.title")
|
|
239
239
|
}, /*#__PURE__*/React.createElement("div", {
|
|
240
|
-
className: "panoramax-body"
|
|
241
|
-
role: "body"
|
|
240
|
+
className: "panoramax-body"
|
|
242
241
|
}, !queryData ? /*#__PURE__*/React.createElement("div", {
|
|
243
242
|
style: {
|
|
244
243
|
display: 'flex',
|
package/plugins/Print.js
CHANGED
|
@@ -582,8 +582,7 @@ var Print = /*#__PURE__*/function (_React$Component) {
|
|
|
582
582
|
title: LocaleUtils.tr("print.output"),
|
|
583
583
|
visible: _this.state.printOutputVisible
|
|
584
584
|
}, /*#__PURE__*/React.createElement("div", {
|
|
585
|
-
className: "print-output-window-body"
|
|
586
|
-
role: "body"
|
|
585
|
+
className: "print-output-window-body"
|
|
587
586
|
}, !_this.state.outputLoaded ? /*#__PURE__*/React.createElement("span", {
|
|
588
587
|
className: "print-output-window-wait"
|
|
589
588
|
}, /*#__PURE__*/React.createElement(Spinner, null), " ", LocaleUtils.tr("print.wait")) : null, /*#__PURE__*/React.createElement("iframe", {
|