@hybridcore/ui 1.6.0 → 1.6.2
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/CATALOG.md +179 -0
- package/README.md +1 -2
- package/dist/AccordionSummary-CJppWeqF.js +781 -0
- package/dist/Add-CqcD1PWb.js +403 -0
- package/dist/Box-DqUMmZjL.js +31 -0
- package/dist/{Button-CvE2gnly.js → Button-C5yquWAB.js} +120 -133
- package/dist/ButtonBase-BEF7oTOe.js +887 -0
- package/dist/{Delete-CW0UZv1m.js → Delete-BdyYpINH.js} +9 -8
- package/dist/{DialogContent-B3nbEbuv.js → DialogContent-BvVjD9z3.js} +127 -124
- package/dist/FormGroup-CpBsIyYR.js +89 -0
- package/dist/{IconButton-CHwRQF-g.js → IconButton-BoGwbvrP.js} +41 -43
- package/dist/InputLabel-Dd8RrneV.js +341 -0
- package/dist/{MenuItem-xZx_w7zA.js → MenuItem-DwqJqzuM.js} +51 -53
- package/dist/Modal-MUZygjmQ.js +1158 -0
- package/dist/Paper-BkQLdsCI.js +582 -0
- package/dist/Select-DHUl_uG3.js +3916 -0
- package/dist/SwitchBase-DTndTqI8.js +235 -0
- package/dist/TextField-e2oKaUN1.js +669 -0
- package/dist/TransitionGroupContext-BDAp2T0O.js +96 -0
- package/dist/{Typography-CxbneZy_.js → Typography-DgsSLCFC.js} +53 -53
- package/dist/assertThisInitialized-C1dAyb4j.js +7 -0
- package/dist/assets/index4.css +1 -0
- package/dist/clsx-OuTLNxxd.js +16 -0
- package/dist/components/access/helpers.js +1 -1
- package/dist/components/access/index.js +8 -15
- package/dist/components/access/logic.js +25 -0
- package/dist/components/button/index.js +10 -0
- package/dist/components/button/logic.js +26 -0
- package/dist/components/button/styled.js +9 -0
- package/dist/components/card/index.js +158 -498
- package/dist/components/card/logic.js +24 -0
- package/dist/components/card/styled.js +226 -51
- package/dist/components/card-alternate/index.js +111 -139
- package/dist/components/card-alternate/logic.js +17 -0
- package/dist/components/card-alternate/styled.js +113 -19
- package/dist/components/charts/_common/chart-error.js +19 -0
- package/dist/components/charts/candlestick/index.js +3 -3
- package/dist/components/charts/candlestick/logic.js +123 -113
- package/dist/components/charts/chart-wrapper/index.js +5 -5
- package/dist/components/charts/column-line-mix/index.js +9 -8
- package/dist/components/charts/column-line-mix/logic.js +68 -71
- package/dist/components/charts/drill-down-treemap/index.js +8 -7
- package/dist/components/charts/drill-down-treemap/logic.js +138 -144
- package/dist/components/charts/drill-down-voronoi-treemap/index.js +9 -8
- package/dist/components/charts/drill-down-voronoi-treemap/logic.js +222 -228
- package/dist/components/charts/heatmap/index.js +9 -8
- package/dist/components/charts/heatmap/logic.js +167 -173
- package/dist/components/charts/highlighting-line-data/index.js +3 -3
- package/dist/components/charts/line/index.js +9 -8
- package/dist/components/charts/line/logic.js +74 -79
- package/dist/components/charts/logaritmic-scale/index.js +9 -8
- package/dist/components/charts/logaritmic-scale/logic.js +63 -69
- package/dist/components/charts/multiple-value-axes/index.js +9 -8
- package/dist/components/charts/multiple-value-axes/logic.js +101 -107
- package/dist/components/charts/nested-pie/index.js +9 -8
- package/dist/components/charts/nested-pie/logic.js +62 -68
- package/dist/components/charts/packed-circles/index.js +7 -6
- package/dist/components/charts/packed-circles/logic.js +50 -56
- package/dist/components/charts/pie-chart/index.js +9 -8
- package/dist/components/charts/pie-chart/logic.js +49 -54
- package/dist/components/charts/stacked-area-radar/index.js +8 -7
- package/dist/components/charts/stacked-area-radar/logic.js +113 -118
- package/dist/components/charts/stacked-column-chart/index.js +9 -8
- package/dist/components/charts/stacked-column-chart/logic.js +78 -84
- package/dist/components/charts/xy-chart/index.js +9 -8
- package/dist/components/charts/xy-chart/logic.js +56 -60
- package/dist/components/collapsible-card/index.js +11 -10
- package/dist/components/collapsible-card/styled.js +1 -1
- package/dist/components/color-picker/index.js +7120 -0
- package/dist/components/color-picker/logic.js +18 -0
- package/dist/components/color-picker/styled.js +7 -0
- package/dist/components/confirm/dialog.js +3 -3
- package/dist/components/confirm/index.js +1 -1
- package/dist/components/container/index.js +28 -269
- package/dist/components/container/logic.js +12 -0
- package/dist/components/container/styled.js +29 -0
- package/dist/components/context-menu/index.js +25 -457
- package/dist/components/context-menu/logic.js +14 -0
- package/dist/components/context-menu/styled.js +40 -0
- package/dist/components/data-grid/index.js +22 -0
- package/dist/components/data-grid/logic.js +15 -0
- package/dist/components/data-grid/styled.js +20 -0
- package/dist/components/data-map/components/controls/index.js +4 -6
- package/dist/components/data-map/index.js +11 -11
- package/dist/components/data-security-selectors/dissemination-list/index.js +192 -191
- package/dist/components/data-security-selectors/dissemination-list/styled.js +12 -12
- package/dist/components/data-security-selectors/security-level/index.js +39 -91
- package/dist/components/data-security-selectors/security-level/logic.js +28 -0
- package/dist/components/data-security-selectors/security-level/styled.js +53 -0
- package/dist/components/date-picker-with-custom-range/index.js +1 -1
- package/dist/components/date-range-picker/index.js +2748 -0
- package/dist/components/date-range-picker/styled.js +14 -0
- package/dist/components/date-time-picker/index.js +45 -46
- package/dist/components/divider/index.js +11 -11
- package/dist/components/document-viewer/components/action-buttons/index.js +15 -15
- package/dist/components/document-viewer/components/navigation/index.js +9 -9
- package/dist/components/document-viewer/components/viewer/index.js +31 -35
- package/dist/components/document-viewer/index.js +31 -39
- package/dist/components/document-viewer/logic.js +41 -34
- package/dist/components/document-viewer/styled.js +115 -27
- package/dist/components/duration-select/index.js +27 -0
- package/dist/components/duration-select/logic.js +21 -0
- package/dist/components/duration-select/styled.js +26 -0
- package/dist/components/editable-text/index.js +20 -0
- package/dist/components/editable-text/logic.js +18 -0
- package/dist/components/editable-text/styled.js +22 -0
- package/dist/components/geometry-picker/coordinate/index.js +29 -29
- package/dist/components/geometry-picker/edit/index.js +18 -18
- package/dist/components/geometry-picker/geometry/index.js +67 -67
- package/dist/components/geometry-picker/geometry/map-overlay.js +6 -6
- package/dist/components/geometry-picker/index.js +69 -85
- package/dist/components/geometry-picker/kml/index.js +16 -16
- package/dist/components/geometry-picker/logic.js +50 -57
- package/dist/components/geometry-picker/map/index.js +8 -8
- package/dist/components/geometry-picker/parser/coordinate-input/index.js +4 -4
- package/dist/components/geometry-picker/parser/index.js +46 -50
- package/dist/components/geometry-picker/parser/styled.js +22 -4
- package/dist/components/geometry-picker/styled.js +97 -37
- package/dist/components/geometry-picker/wkt/index.js +13 -13
- package/dist/components/heat-map/components/controls/index.js +4 -6
- package/dist/components/heat-map/components/legend/index.js +15 -17
- package/dist/components/heat-map/index.js +7 -7
- package/dist/components/instance-form/components/TopLabelWrapper.js +8 -48
- package/dist/components/instance-form/components/composite-list/index.js +5 -3
- package/dist/components/instance-form/components/composite-matrix/components/editable-table/index.js +83 -74
- package/dist/components/instance-form/components/composite-matrix/components/editor/index.js +45 -66
- package/dist/components/instance-form/components/composite-matrix/components/form/index.js +60 -75
- package/dist/components/instance-form/components/composite-matrix/components/json-editor/index.js +2425 -2422
- package/dist/components/instance-form/components/composite-matrix/components/table/index.js +33 -52
- package/dist/components/instance-form/components/composite-matrix/index.js +30 -36
- package/dist/components/instance-form/components/policy-list/index.js +47 -81
- package/dist/components/instance-form/components/variable/index.js +6 -11
- package/dist/components/instance-form/components/variables/index.js +48 -55
- package/dist/components/instance-form/helpers.js +9 -0
- package/dist/components/instance-form/index.js +402 -518
- package/dist/components/instance-form/logic.js +115 -0
- package/dist/components/instance-form/styled.js +487 -0
- package/dist/components/instance-hierarchy-table/index.js +32 -37
- package/dist/components/instance-hierarchy-table/logic.js +16 -0
- package/dist/components/instance-hierarchy-table/styled.js +53 -12
- package/dist/components/instance-table/index.js +30 -135
- package/dist/components/instance-table/logic.js +122 -0
- package/dist/components/instance-table/styled.js +53 -11
- package/dist/components/instance-variable-list/index.js +11 -11
- package/dist/components/loading/index.js +15 -9
- package/dist/components/loading/logic.js +15 -0
- package/dist/components/loading/styled.js +26 -19
- package/dist/components/map/index.js +28 -6
- package/dist/components/map/styled.js +1 -1
- package/dist/components/notification/index.js +67 -0
- package/dist/components/notification/logic.js +30 -0
- package/dist/components/notification/store.js +23 -0
- package/dist/components/notification/styled.js +52 -0
- package/dist/components/object-profile-card/components/avatar/index.js +9 -10
- package/dist/components/object-profile-card/index.js +19 -20
- package/dist/components/paginated-list/index.js +2 -3
- package/dist/components/phone-input/index.js +18 -22
- package/dist/components/phone-input/logic.js +14 -0
- package/dist/components/phone-input/styled.js +12 -4
- package/dist/components/placeholder/index.js +10 -0
- package/dist/components/placeholder/logic.js +12 -0
- package/dist/components/placeholder/styled.js +32 -0
- package/dist/components/positional-tooltip/index.js +24 -0
- package/dist/components/positional-tooltip/styled.js +17 -0
- package/dist/components/property-mapping/index.js +204 -423
- package/dist/components/property-mapping/logic.js +156 -0
- package/dist/components/property-mapping/styled.js +199 -0
- package/dist/components/prr-map/components/controls/index.js +4 -6
- package/dist/components/prr-map/components/legend/index.js +26 -28
- package/dist/components/prr-map/index.js +5 -5
- package/dist/components/range-selector/components/composite-list-range/index.js +42 -50
- package/dist/components/range-selector/components/date-range/index.js +87 -4221
- package/dist/components/range-selector/components/geometry-range/index.js +11 -17
- package/dist/components/range-selector/components/number-range/index.js +48 -53
- package/dist/components/range-selector/components/string-range/index.js +15 -17
- package/dist/components/range-selector/index.js +63 -57
- package/dist/components/range-selector/logic.js +12 -0
- package/dist/components/range-selector/styled.js +4294 -0
- package/dist/components/raster-grid-map/components/controls/index.js +4 -6
- package/dist/components/raster-grid-map/components/legend/index.js +4 -6
- package/dist/components/raster-grid-map/index.js +5 -5
- package/dist/components/scroll-drag/index.js +22 -0
- package/dist/components/scroll-drag/logic.js +39 -0
- package/dist/components/scroll-drag/styled.js +17 -0
- package/dist/components/search-input/logic.js +35 -33
- package/dist/components/simple-pivot-table/index.js +12 -12
- package/dist/components/sortable-list/index.js +599 -0
- package/dist/components/sortable-list/logic.js +18 -0
- package/dist/components/sortable-list/styled.js +38 -0
- package/dist/components/static-text/index.js +6 -6
- package/dist/components/stats-box/index.js +12 -0
- package/dist/components/stats-box/styled.js +36 -0
- package/dist/components/template-filters/components/filter/index.js +13 -18
- package/dist/components/template-filters/components/tab-panel/index.js +8 -16
- package/dist/components/template-filters/index.js +21 -29
- package/dist/components/template-filters/logic.js +18 -0
- package/dist/components/template-filters/styled.js +44 -1
- package/dist/components/template-form/components/property-list/index.js +27 -26
- package/dist/components/template-form/components/property-list/property-list-columns.js +3 -3
- package/dist/components/template-form/components/property-list/property-list-form.js +758 -14
- package/dist/components/template-form/components/recognition-property-list/index.js +11 -11
- package/dist/components/template-form/components/recognition-property-list/recognition-property-list-columns.js +2 -2
- package/dist/components/template-form/components/recognition-property-list/recognition-property-list-form.js +24 -23
- package/dist/components/template-form/components/select-icon/index.js +24 -24
- package/dist/components/template-form/helpers.js +17 -0
- package/dist/components/template-form/index.js +270 -309
- package/dist/components/template-form/logic.js +69 -0
- package/dist/components/template-form/styled.js +84 -0
- package/dist/components/template-property-filters/index.js +45 -95
- package/dist/components/template-property-filters/logic.js +27 -0
- package/dist/components/template-property-filters/property.js +105 -165
- package/dist/components/template-property-filters/styled.js +121 -20
- package/dist/components/text-overflow/index.js +6 -0
- package/dist/components/text-overflow/styled.js +13 -0
- package/dist/components/timeline/index.js +12 -12
- package/dist/components/toggle-view-button/index.js +35 -0
- package/dist/components/toggle-view-button/logic.js +22 -0
- package/dist/components/toggle-view-button/styled.js +11 -0
- package/dist/components/tree-select/index.js +52 -67
- package/dist/components/tree-select/logic.js +59 -0
- package/dist/components/tree-select/styled.js +45 -62
- package/dist/components/treeview-filter/index.js +43 -65
- package/dist/components/treeview-filter/item/index.js +43 -42
- package/dist/components/treeview-filter/item-label/index.js +17 -37
- package/dist/components/treeview-filter/logic.js +28 -0
- package/dist/components/treeview-filter/styled.js +86 -0
- package/dist/components/uploader/index.js +532 -567
- package/dist/components/uploader/logic.js +74 -0
- package/dist/components/uploader/styled.js +93 -46
- package/dist/components/visually-hidden-input/index.js +4 -0
- package/dist/components/visually-hidden-input/styled.js +18 -0
- package/dist/createChainedFunction-C0nujS3O.js +9 -0
- package/dist/{createSvgIcon-DrtgaibK.js → createSvgIcon-Ch_cT8az.js} +69 -68
- package/dist/createSvgIcon-DuDuASu1.js +62 -0
- package/dist/{dialog-DcwXug9J.js → dialog-BYRnCztH.js} +18 -18
- package/dist/formControlState-vgaj2ksH.js +10 -0
- package/dist/generateUtilityClasses-C3ivN9Ie.js +2973 -0
- package/dist/{helpers-B4UL9NMD.js → helpers-D4uXfBfO.js} +2 -2
- package/dist/index-BtlzPygz.js +470 -0
- package/dist/index-DH6qsPBn.js +153 -0
- package/dist/{index-syTc6m_V.js → index-e9xTIYWt.js} +87 -87
- package/dist/main.d.ts +1722 -562
- package/dist/main.js +161 -128
- package/dist/ownerWindow-wg6foiOE.js +10 -0
- package/dist/setPrototypeOf-NPgp4cYc.js +8 -0
- package/dist/styled-Db1RdcPA.js +323 -0
- package/dist/unsupportedProp-DuqR2hj9.js +36 -0
- package/dist/useId-BW-oWmul.js +19 -0
- package/dist/useMobilePicker-CY8ndYRL.js +8279 -0
- package/dist/useSlot-B_Q4vnX5.js +42 -0
- package/package.json +15 -7
- package/dist/AccordionSummary-DgAwVTk8.js +0 -742
- package/dist/Add-DJLrrVHm.js +0 -382
- package/dist/Box-p6OtTUEo.js +0 -30
- package/dist/ButtonBase-2bPw77UP.js +0 -961
- package/dist/CardContent-CSHh-ZlM.js +0 -74
- package/dist/Checkbox-CWRMFTBp.js +0 -421
- package/dist/FormControl-BLbrq4C7.js +0 -1636
- package/dist/FormControlLabel-C8SPv14J.js +0 -195
- package/dist/InputAdornment-DLxWUE6H.js +0 -157
- package/dist/List-tqElle9C.js +0 -121
- package/dist/ListItem-CfjsIg4B.js +0 -430
- package/dist/Modal-DhPpOoGB.js +0 -1299
- package/dist/Paper-2B03OBmZ.js +0 -169
- package/dist/Select-BgYwkZgI.js +0 -2613
- package/dist/TextField-1yCesIbH.js +0 -457
- package/dist/assertThisInitialized-BUtkG-md.js +0 -13
- package/dist/capitalize-ciszXJ7R.js +0 -9
- package/dist/components/instance-form/components/composite-list/styled.js +0 -73
- package/dist/components/instance-form/components/composite-matrix/components/editor/styled.js +0 -1
- package/dist/components/instance-form/components/composite-matrix/styled.js +0 -69
- package/dist/components/key-protection/index.js +0 -4
- package/dist/components/key-protection/menu.js +0 -85
- package/dist/components/key-protection/utils.js +0 -10
- package/dist/components/treeview-filter/item/styled.js +0 -39
- package/dist/createSvgIcon-BjpIhJ30.js +0 -71
- package/dist/createTheme-DYxDnE9u.js +0 -612
- package/dist/index-BMS1Otro.js +0 -183
- package/dist/index-CcdvNlgr.js +0 -503
- package/dist/index-kCJ_Zvl8.js +0 -34
- package/dist/isHostComponent-kiaBvYVo.js +0 -6
- package/dist/isMuiElement-CxT3_ACP.js +0 -13
- package/dist/listItemTextClasses-C3lndiXO.js +0 -16
- package/dist/property-list-form-zZQfpR0X.js +0 -386
- package/dist/styled-eZwjUruw.js +0 -12
- package/dist/unsupportedProp-BND8AB6O.js +0 -25
- package/dist/useId-B4-oF9Mq.js +0 -34
- package/dist/useMobilePicker-BLg3Blg8.js +0 -7589
- package/dist/useThemeProps-BzzHcQyd.js +0 -58
- package/dist/utils-BDNynJcd.js +0 -365
- package/dist/utils-Bq0ye5vf.js +0 -115
|
@@ -1,67 +1,67 @@
|
|
|
1
|
-
import { jsxs as r, jsx as
|
|
1
|
+
import { jsxs as r, jsx as i, Fragment as R } from "react/jsx-runtime";
|
|
2
2
|
import D, { useState as k } from "react";
|
|
3
|
-
import { Dialog as
|
|
4
|
-
import P from "../map/index.js";
|
|
5
|
-
import b from "../parser/index.js";
|
|
6
|
-
import { c as
|
|
7
|
-
import {
|
|
3
|
+
import { Dialog as B, DialogContent as K, Box as t, Typography as x, DialogActions as F, Button as d } from "@mui/material";
|
|
4
|
+
import { Map as P } from "../map/index.js";
|
|
5
|
+
import { Parser as b } from "../parser/index.js";
|
|
6
|
+
import { c as G } from "../../../ol-yOE-NV0X.js";
|
|
7
|
+
import { GeometryPickerActionButton as l } from "../styled.js";
|
|
8
8
|
import { HorizontalRule as j, ShowChart as O, CircleOutlined as I } from "@mui/icons-material";
|
|
9
9
|
import L from "./map-overlay.js";
|
|
10
|
-
|
|
11
|
-
mapId:
|
|
12
|
-
mapboxAccessToken:
|
|
10
|
+
const Q = ({
|
|
11
|
+
mapId: m,
|
|
12
|
+
mapboxAccessToken: u,
|
|
13
13
|
value: S,
|
|
14
14
|
disableActions: T = !1,
|
|
15
15
|
variant: W = "inline",
|
|
16
|
-
defaultExtent:
|
|
16
|
+
defaultExtent: C,
|
|
17
17
|
onCancel: s,
|
|
18
18
|
onSubmit: v,
|
|
19
19
|
onChange: h
|
|
20
|
-
}) {
|
|
21
|
-
const f = D.useRef(null), [
|
|
22
|
-
v &&
|
|
23
|
-
}, g = (
|
|
24
|
-
if (
|
|
25
|
-
const c =
|
|
26
|
-
|
|
27
|
-
} else
|
|
28
|
-
}, w = (
|
|
29
|
-
|
|
30
|
-
}, a = (
|
|
20
|
+
}) => {
|
|
21
|
+
const f = D.useRef(null), [n, p] = k(S), [e, M] = k(), y = () => {
|
|
22
|
+
v && n && v(n);
|
|
23
|
+
}, g = (o) => {
|
|
24
|
+
if (o.length > 0) {
|
|
25
|
+
const c = G({ features: o });
|
|
26
|
+
p(c);
|
|
27
|
+
} else p(void 0);
|
|
28
|
+
}, w = (o) => {
|
|
29
|
+
p(o);
|
|
30
|
+
}, a = (o) => () => {
|
|
31
31
|
var c;
|
|
32
|
-
|
|
32
|
+
M(o), (c = f.current) == null || c.addInteractions(o);
|
|
33
33
|
};
|
|
34
|
-
return D.useEffect(() => (
|
|
35
|
-
}), [
|
|
34
|
+
return D.useEffect(() => (n !== void 0 && h !== void 0 && h(n), () => {
|
|
35
|
+
}), [n, h]), W === "dialog" ? /* @__PURE__ */ r(B, { open: !0, maxWidth: "sm", fullWidth: !0, onClose: s, children: [
|
|
36
36
|
/* @__PURE__ */ r(K, { children: [
|
|
37
|
-
/* @__PURE__ */ r(
|
|
38
|
-
/* @__PURE__ */
|
|
39
|
-
/* @__PURE__ */ r(
|
|
40
|
-
/* @__PURE__ */
|
|
37
|
+
/* @__PURE__ */ r(t, { display: "flex", justifyContent: "space-between", children: [
|
|
38
|
+
/* @__PURE__ */ i(x, { variant: "subtitle2", children: "Draw On Map" }),
|
|
39
|
+
/* @__PURE__ */ r(t, { display: "flex", justifyContent: "flex-end", mb: 1, children: [
|
|
40
|
+
/* @__PURE__ */ i(
|
|
41
41
|
l,
|
|
42
42
|
{
|
|
43
43
|
color: "inherit",
|
|
44
|
-
startIcon: /* @__PURE__ */
|
|
44
|
+
startIcon: /* @__PURE__ */ i(j, {}),
|
|
45
45
|
onClick: a("LineString"),
|
|
46
46
|
...e === "LineString" && { variant: "contained" },
|
|
47
47
|
children: "Draw Line"
|
|
48
48
|
}
|
|
49
49
|
),
|
|
50
|
-
/* @__PURE__ */
|
|
50
|
+
/* @__PURE__ */ i(
|
|
51
51
|
l,
|
|
52
52
|
{
|
|
53
53
|
color: "inherit",
|
|
54
|
-
startIcon: /* @__PURE__ */
|
|
54
|
+
startIcon: /* @__PURE__ */ i(O, {}),
|
|
55
55
|
onClick: a("Polygon"),
|
|
56
56
|
...e === "Polygon" && { variant: "contained" },
|
|
57
57
|
children: "Draw Polygon"
|
|
58
58
|
}
|
|
59
59
|
),
|
|
60
|
-
/* @__PURE__ */
|
|
60
|
+
/* @__PURE__ */ i(
|
|
61
61
|
l,
|
|
62
62
|
{
|
|
63
63
|
color: "inherit",
|
|
64
|
-
startIcon: /* @__PURE__ */
|
|
64
|
+
startIcon: /* @__PURE__ */ i(I, {}),
|
|
65
65
|
onClick: a("Circle"),
|
|
66
66
|
...e === "Circle" && { variant: "contained" },
|
|
67
67
|
children: "Draw Circle"
|
|
@@ -69,55 +69,55 @@ function N({
|
|
|
69
69
|
)
|
|
70
70
|
] })
|
|
71
71
|
] }),
|
|
72
|
-
/* @__PURE__ */ r(
|
|
73
|
-
/* @__PURE__ */
|
|
72
|
+
/* @__PURE__ */ r(t, { position: "relative", children: [
|
|
73
|
+
/* @__PURE__ */ i(
|
|
74
74
|
P,
|
|
75
75
|
{
|
|
76
|
-
id:
|
|
76
|
+
id: m,
|
|
77
77
|
ref: f,
|
|
78
|
-
mapboxAccessToken:
|
|
79
|
-
drawingWKTData:
|
|
80
|
-
defaultExtent:
|
|
78
|
+
mapboxAccessToken: u,
|
|
79
|
+
drawingWKTData: n,
|
|
80
|
+
defaultExtent: C,
|
|
81
81
|
onDrawEnd: g
|
|
82
82
|
}
|
|
83
83
|
),
|
|
84
|
-
/* @__PURE__ */
|
|
84
|
+
/* @__PURE__ */ i(L, { show: e === void 0 })
|
|
85
85
|
] }),
|
|
86
|
-
|
|
86
|
+
n !== void 0 && /* @__PURE__ */ i(b, { value: n, onChange: w })
|
|
87
87
|
] }),
|
|
88
88
|
/* @__PURE__ */ r(F, { children: [
|
|
89
|
-
/* @__PURE__ */
|
|
90
|
-
/* @__PURE__ */
|
|
89
|
+
/* @__PURE__ */ i(d, { color: "inherit", variant: "contained", onClick: s, children: "Cancel" }),
|
|
90
|
+
/* @__PURE__ */ i(d, { variant: "contained", onClick: y, children: "Ok" })
|
|
91
91
|
] })
|
|
92
|
-
] }) : /* @__PURE__ */ r(
|
|
93
|
-
/* @__PURE__ */ r(
|
|
94
|
-
/* @__PURE__ */
|
|
95
|
-
/* @__PURE__ */ r(
|
|
96
|
-
/* @__PURE__ */
|
|
92
|
+
] }) : /* @__PURE__ */ r(R, { children: [
|
|
93
|
+
/* @__PURE__ */ r(t, { display: "flex", justifyContent: "space-between", children: [
|
|
94
|
+
/* @__PURE__ */ i(x, { variant: "subtitle2", children: "Draw On Map" }),
|
|
95
|
+
/* @__PURE__ */ r(t, { display: "flex", justifyContent: "flex-end", mb: 1, children: [
|
|
96
|
+
/* @__PURE__ */ i(
|
|
97
97
|
l,
|
|
98
98
|
{
|
|
99
99
|
color: "inherit",
|
|
100
|
-
startIcon: /* @__PURE__ */
|
|
100
|
+
startIcon: /* @__PURE__ */ i(j, {}),
|
|
101
101
|
onClick: a("LineString"),
|
|
102
102
|
...e === "LineString" && { variant: "contained" },
|
|
103
103
|
children: "Draw Line"
|
|
104
104
|
}
|
|
105
105
|
),
|
|
106
|
-
/* @__PURE__ */
|
|
106
|
+
/* @__PURE__ */ i(
|
|
107
107
|
l,
|
|
108
108
|
{
|
|
109
109
|
color: "inherit",
|
|
110
|
-
startIcon: /* @__PURE__ */
|
|
110
|
+
startIcon: /* @__PURE__ */ i(O, {}),
|
|
111
111
|
onClick: a("Polygon"),
|
|
112
112
|
...e === "Polygon" && { variant: "contained" },
|
|
113
113
|
children: "Draw Polygon"
|
|
114
114
|
}
|
|
115
115
|
),
|
|
116
|
-
/* @__PURE__ */
|
|
116
|
+
/* @__PURE__ */ i(
|
|
117
117
|
l,
|
|
118
118
|
{
|
|
119
119
|
color: "inherit",
|
|
120
|
-
startIcon: /* @__PURE__ */
|
|
120
|
+
startIcon: /* @__PURE__ */ i(I, {}),
|
|
121
121
|
onClick: a("Circle"),
|
|
122
122
|
...e === "Circle" && { variant: "contained" },
|
|
123
123
|
children: "Draw Circle"
|
|
@@ -125,36 +125,36 @@ function N({
|
|
|
125
125
|
)
|
|
126
126
|
] })
|
|
127
127
|
] }),
|
|
128
|
-
/* @__PURE__ */ r(
|
|
129
|
-
/* @__PURE__ */
|
|
128
|
+
/* @__PURE__ */ r(t, { position: "relative", children: [
|
|
129
|
+
/* @__PURE__ */ i(
|
|
130
130
|
P,
|
|
131
131
|
{
|
|
132
|
-
id:
|
|
132
|
+
id: m,
|
|
133
133
|
ref: f,
|
|
134
|
-
mapboxAccessToken:
|
|
135
|
-
drawingWKTData:
|
|
136
|
-
defaultExtent:
|
|
134
|
+
mapboxAccessToken: u,
|
|
135
|
+
drawingWKTData: n,
|
|
136
|
+
defaultExtent: C,
|
|
137
137
|
onDrawEnd: g
|
|
138
138
|
}
|
|
139
139
|
),
|
|
140
|
-
/* @__PURE__ */
|
|
140
|
+
/* @__PURE__ */ i(L, { show: e === void 0 })
|
|
141
141
|
] }),
|
|
142
|
-
|
|
143
|
-
!T && /* @__PURE__ */ r(
|
|
144
|
-
/* @__PURE__ */
|
|
145
|
-
/* @__PURE__ */
|
|
142
|
+
n !== void 0 && /* @__PURE__ */ i(b, { value: n, onChange: w }),
|
|
143
|
+
!T && /* @__PURE__ */ r(t, { display: "flex", justifyContent: "space-between", mt: 3, children: [
|
|
144
|
+
/* @__PURE__ */ i(d, { color: "primary", onClick: s, children: "Cancel" }),
|
|
145
|
+
/* @__PURE__ */ i(
|
|
146
146
|
d,
|
|
147
147
|
{
|
|
148
148
|
color: "primary",
|
|
149
149
|
variant: "contained",
|
|
150
150
|
onClick: y,
|
|
151
|
-
disabled:
|
|
151
|
+
disabled: n === void 0,
|
|
152
152
|
children: "Ok"
|
|
153
153
|
}
|
|
154
154
|
)
|
|
155
155
|
] })
|
|
156
156
|
] });
|
|
157
|
-
}
|
|
157
|
+
};
|
|
158
158
|
export {
|
|
159
|
-
|
|
159
|
+
Q as Geometry
|
|
160
160
|
};
|
|
@@ -1,22 +1,22 @@
|
|
|
1
1
|
import { jsx as t, Fragment as o, jsxs as a } from "react/jsx-runtime";
|
|
2
2
|
import { Box as e, Typography as i } from "@mui/material";
|
|
3
|
-
|
|
4
|
-
|
|
3
|
+
import { GeometryPickerGeometryMapOverlay as n } from "../styled.js";
|
|
4
|
+
const s = "data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20width='544.605'%20height='568.76'%20viewBox='0%200%20544.605%20568.76'%3e%3cg%20id='Group_160607'%20data-name='Group%20160607'%20transform='translate(-1185.395%20-688.133)'%3e%3cpath%20id='Polygon_2'%20data-name='Polygon%202'%20d='M34.5,0,69,59H0Z'%20transform='translate(1661%20688.133)'%20fill='%23fff'/%3e%3cpath%20id='Path_84395'%20data-name='Path%2084395'%20d='M914.667,851.733s-51.2-206.933,182.4-264.533,308.266-52.267,317.867-145.067,0-121.6,0-121.6'%20transform='translate(278%20402.133)'%20fill='none'%20stroke='%23fff'%20stroke-linecap='round'%20stroke-width='5'/%3e%3c/g%3e%3c/svg%3e";
|
|
5
|
+
function g({ show: r }) {
|
|
5
6
|
return r ? /* @__PURE__ */ a(e, { position: "absolute", top: 0, left: 0, right: 0, bottom: 0, children: [
|
|
6
7
|
/* @__PURE__ */ t(
|
|
7
|
-
|
|
8
|
+
n,
|
|
8
9
|
{
|
|
9
10
|
display: "flex",
|
|
10
11
|
height: "100%",
|
|
11
12
|
justifyContent: "center",
|
|
12
13
|
alignItems: "center",
|
|
13
|
-
sx: { backgroundColor: "rgba(0,0,0,0.5)" },
|
|
14
14
|
children: /* @__PURE__ */ t(i, { color: "white", children: "Select drawing type to start drawing" })
|
|
15
15
|
}
|
|
16
16
|
),
|
|
17
|
-
/* @__PURE__ */ t(e, { position: "absolute", top: 10, right: 0, width: "50%", children: /* @__PURE__ */ t("img", { src:
|
|
17
|
+
/* @__PURE__ */ t(e, { position: "absolute", top: 10, right: 0, width: "50%", children: /* @__PURE__ */ t("img", { src: s, width: "75%", height: 220 }) })
|
|
18
18
|
] }) : /* @__PURE__ */ t(o, {});
|
|
19
19
|
}
|
|
20
20
|
export {
|
|
21
|
-
|
|
21
|
+
g as default
|
|
22
22
|
};
|
|
@@ -1,137 +1,121 @@
|
|
|
1
|
-
import { jsx as
|
|
2
|
-
import { EditOutlined as
|
|
3
|
-
import {
|
|
4
|
-
import
|
|
5
|
-
import
|
|
6
|
-
import
|
|
7
|
-
import
|
|
8
|
-
import
|
|
9
|
-
import W from "./
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
label: r,
|
|
15
|
-
mapboxAccessToken: c,
|
|
16
|
-
value: e = "",
|
|
17
|
-
disableAddCoordinate: f = !1,
|
|
18
|
-
defaultExtent: s,
|
|
19
|
-
variant: d = "outlined",
|
|
20
|
-
labelPosition: m = "top",
|
|
21
|
-
onChange: C
|
|
22
|
-
}) => {
|
|
23
|
-
const { state: t, action: n } = S({
|
|
24
|
-
label: r,
|
|
25
|
-
value: e,
|
|
26
|
-
onChange: C
|
|
27
|
-
}), a = /* @__PURE__ */ o(T, { position: "end", children: e !== "" && /* @__PURE__ */ i(p, { children: [
|
|
28
|
-
/* @__PURE__ */ o(h, { size: "small", onClick: n.onEdit, children: /* @__PURE__ */ o(D, { fontSize: "small" }) }),
|
|
29
|
-
/* @__PURE__ */ o(h, { size: "small", onClick: n.onDelete, children: /* @__PURE__ */ o(A, { fontSize: "small" }) })
|
|
1
|
+
import { jsx as e, jsxs as i, Fragment as f } from "react/jsx-runtime";
|
|
2
|
+
import { EditOutlined as C, DeleteOutline as A, AddLocationOutlined as G, DrawOutlined as b, LayersOutlined as p } from "@mui/icons-material";
|
|
3
|
+
import { Coordinate as D } from "./coordinate/index.js";
|
|
4
|
+
import { Edit as P } from "./edit/index.js";
|
|
5
|
+
import { Geometry as S } from "./geometry/index.js";
|
|
6
|
+
import { Kml as O } from "./kml/index.js";
|
|
7
|
+
import { Wkt as I } from "./wkt/index.js";
|
|
8
|
+
import { useGeometryPickerLogic as E } from "./logic.js";
|
|
9
|
+
import { GeometryPickerEndAdornment as M, GeometryPickerEndAdornmentButton as y, GeometryPickerRoot as x, GeometryPickerTopLabel as T, GeometryPickerContainer as g, GeometryPickerActions as L, GeometryPickerActionButton as c, GeometryPickerFormControl as W, GeometryPickerInputLabel as K, GeometryPickerInputStandard as v, GeometryPickerInputOutlined as w, GeometryPickerInputFilled as z, GeometryPickerDialog as B, GeometryPickerDialogTitle as R, GeometryPickerDialogContent as F } from "./styled.js";
|
|
10
|
+
const X = (s) => {
|
|
11
|
+
const { label: r, mapboxAccessToken: d, value: n = "", defaultExtent: u } = s, { refs: h, state: t, actions: o } = E(s), { ownerState: k, variant: l, labelPosition: a } = t, m = /* @__PURE__ */ e(M, { position: "end", children: n !== "" && /* @__PURE__ */ i(f, { children: [
|
|
12
|
+
/* @__PURE__ */ e(y, { size: "small", onClick: o.onEdit, children: /* @__PURE__ */ e(C, { fontSize: "small" }) }),
|
|
13
|
+
/* @__PURE__ */ e(y, { size: "small", onClick: o.onDelete, children: /* @__PURE__ */ e(A, { fontSize: "small" }) })
|
|
30
14
|
] }) });
|
|
31
|
-
return /* @__PURE__ */ i(
|
|
32
|
-
|
|
33
|
-
/* @__PURE__ */ i(
|
|
34
|
-
/* @__PURE__ */ i(
|
|
35
|
-
|
|
36
|
-
|
|
15
|
+
return /* @__PURE__ */ i(x, { ref: h.rootRef, sx: t.sx, children: [
|
|
16
|
+
a === "top" && r !== void 0 && /* @__PURE__ */ e(T, { children: r }),
|
|
17
|
+
/* @__PURE__ */ i(g, { children: [
|
|
18
|
+
/* @__PURE__ */ i(L, { ownerState: k, children: [
|
|
19
|
+
k.disableAddCoordinate === !1 && /* @__PURE__ */ e(
|
|
20
|
+
c,
|
|
37
21
|
{
|
|
38
22
|
color: "inherit",
|
|
39
|
-
startIcon: /* @__PURE__ */
|
|
40
|
-
onClick:
|
|
23
|
+
startIcon: /* @__PURE__ */ e(G, {}),
|
|
24
|
+
onClick: o.onAddCoordinate,
|
|
41
25
|
children: "Add Coordinate"
|
|
42
26
|
}
|
|
43
27
|
),
|
|
44
|
-
/* @__PURE__ */
|
|
45
|
-
|
|
28
|
+
/* @__PURE__ */ e(
|
|
29
|
+
c,
|
|
46
30
|
{
|
|
47
31
|
color: "inherit",
|
|
48
|
-
startIcon: /* @__PURE__ */
|
|
49
|
-
onClick:
|
|
32
|
+
startIcon: /* @__PURE__ */ e(b, {}),
|
|
33
|
+
onClick: o.onDraw,
|
|
50
34
|
children: "Draw"
|
|
51
35
|
}
|
|
52
36
|
),
|
|
53
|
-
/* @__PURE__ */
|
|
54
|
-
|
|
37
|
+
/* @__PURE__ */ e(
|
|
38
|
+
c,
|
|
55
39
|
{
|
|
56
40
|
color: "inherit",
|
|
57
|
-
startIcon: /* @__PURE__ */
|
|
58
|
-
onClick:
|
|
41
|
+
startIcon: /* @__PURE__ */ e(p, {}),
|
|
42
|
+
onClick: o.onAddKml,
|
|
59
43
|
children: "Add KML"
|
|
60
44
|
}
|
|
61
45
|
),
|
|
62
|
-
/* @__PURE__ */
|
|
63
|
-
|
|
46
|
+
/* @__PURE__ */ e(
|
|
47
|
+
c,
|
|
64
48
|
{
|
|
65
49
|
color: "inherit",
|
|
66
|
-
startIcon: /* @__PURE__ */
|
|
67
|
-
onClick:
|
|
50
|
+
startIcon: /* @__PURE__ */ e(p, {}),
|
|
51
|
+
onClick: o.onAddWkt,
|
|
68
52
|
children: "Add WKT"
|
|
69
53
|
}
|
|
70
54
|
)
|
|
71
55
|
] }),
|
|
72
56
|
/* @__PURE__ */ i(
|
|
73
|
-
|
|
57
|
+
W,
|
|
74
58
|
{
|
|
75
59
|
fullWidth: !0,
|
|
76
|
-
variant:
|
|
60
|
+
variant: l,
|
|
77
61
|
contentEditable: !1,
|
|
78
|
-
onClick:
|
|
62
|
+
onClick: o.onClick,
|
|
79
63
|
children: [
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
64
|
+
a === "default" && /* @__PURE__ */ e(K, { shrink: !!n, children: r }),
|
|
65
|
+
l === "standard" && /* @__PURE__ */ e(v, { value: n, readOnly: !0, endAdornment: m }),
|
|
66
|
+
l === "outlined" && /* @__PURE__ */ e(
|
|
67
|
+
w,
|
|
84
68
|
{
|
|
85
|
-
label:
|
|
86
|
-
value:
|
|
69
|
+
label: a === "default" ? r : void 0,
|
|
70
|
+
value: n,
|
|
87
71
|
readOnly: !0,
|
|
88
|
-
endAdornment:
|
|
72
|
+
endAdornment: m
|
|
89
73
|
}
|
|
90
74
|
),
|
|
91
|
-
|
|
75
|
+
l === "filled" && /* @__PURE__ */ e(z, { value: n, readOnly: !0, endAdornment: m })
|
|
92
76
|
]
|
|
93
77
|
}
|
|
94
78
|
)
|
|
95
79
|
] }),
|
|
96
80
|
/* @__PURE__ */ i(
|
|
97
|
-
|
|
81
|
+
B,
|
|
98
82
|
{
|
|
99
83
|
open: t.modal.isOpen,
|
|
100
|
-
onClose:
|
|
84
|
+
onClose: o.closeModal,
|
|
101
85
|
fullWidth: !0,
|
|
102
86
|
maxWidth: "md",
|
|
103
87
|
children: [
|
|
104
|
-
/* @__PURE__ */
|
|
105
|
-
/* @__PURE__ */ i(
|
|
106
|
-
t.content.action === "ADD" && t.content.type === "COORDINATE" && /* @__PURE__ */
|
|
107
|
-
|
|
88
|
+
/* @__PURE__ */ e(R, { children: t.content.title }),
|
|
89
|
+
/* @__PURE__ */ i(F, { children: [
|
|
90
|
+
t.content.action === "ADD" && t.content.type === "COORDINATE" && /* @__PURE__ */ e(
|
|
91
|
+
D,
|
|
108
92
|
{
|
|
109
|
-
mapboxAccessToken:
|
|
110
|
-
defaultExtent:
|
|
111
|
-
onCancel:
|
|
112
|
-
onSubmit:
|
|
93
|
+
mapboxAccessToken: d,
|
|
94
|
+
defaultExtent: u,
|
|
95
|
+
onCancel: o.closeModal,
|
|
96
|
+
onSubmit: o.onSubmit
|
|
113
97
|
}
|
|
114
98
|
),
|
|
115
|
-
t.content.action === "ADD" && t.content.type === "GEOMETRY" && /* @__PURE__ */
|
|
116
|
-
|
|
99
|
+
t.content.action === "ADD" && t.content.type === "GEOMETRY" && /* @__PURE__ */ e(
|
|
100
|
+
S,
|
|
117
101
|
{
|
|
118
102
|
mapId: "map-geo-picker-001",
|
|
119
|
-
mapboxAccessToken:
|
|
120
|
-
defaultExtent:
|
|
121
|
-
onCancel:
|
|
122
|
-
onSubmit:
|
|
103
|
+
mapboxAccessToken: d,
|
|
104
|
+
defaultExtent: u,
|
|
105
|
+
onCancel: o.closeModal,
|
|
106
|
+
onSubmit: o.onSubmit
|
|
123
107
|
}
|
|
124
108
|
),
|
|
125
|
-
t.content.action === "ADD" && t.content.type === "KML" && /* @__PURE__ */
|
|
126
|
-
t.content.action === "ADD" && t.content.type === "WKT" && /* @__PURE__ */
|
|
127
|
-
t.content.action === "EDIT" && !!
|
|
128
|
-
|
|
109
|
+
t.content.action === "ADD" && t.content.type === "KML" && /* @__PURE__ */ e(O, { onCancel: o.closeModal, onSubmit: o.onSubmit }),
|
|
110
|
+
t.content.action === "ADD" && t.content.type === "WKT" && /* @__PURE__ */ e(I, { onCancel: o.closeModal, onSubmit: o.onSubmit }),
|
|
111
|
+
t.content.action === "EDIT" && !!n && /* @__PURE__ */ e(
|
|
112
|
+
P,
|
|
129
113
|
{
|
|
130
114
|
mapId: "map-geo-edit-001",
|
|
131
|
-
value:
|
|
132
|
-
mapboxAccessToken:
|
|
133
|
-
onCancel:
|
|
134
|
-
onSubmit:
|
|
115
|
+
value: n,
|
|
116
|
+
mapboxAccessToken: d,
|
|
117
|
+
onCancel: o.closeModal,
|
|
118
|
+
onSubmit: o.onSubmit
|
|
135
119
|
}
|
|
136
120
|
)
|
|
137
121
|
] })
|
|
@@ -141,5 +125,5 @@ const _ = ({
|
|
|
141
125
|
] });
|
|
142
126
|
};
|
|
143
127
|
export {
|
|
144
|
-
|
|
128
|
+
X as GeometryPicker
|
|
145
129
|
};
|
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
import { jsx as r, jsxs as
|
|
1
|
+
import { jsx as r, jsxs as u } from "react/jsx-runtime";
|
|
2
2
|
import { useState as i, useEffect as k } from "react";
|
|
3
3
|
import M from "./select-input-method.js";
|
|
4
|
-
import { Box as
|
|
4
|
+
import { Box as m, TextField as b, Button as d } from "@mui/material";
|
|
5
5
|
import { validate as C } from "../../map/helpers/kml.js";
|
|
6
6
|
import { a as L, c as T } from "../../../ol-yOE-NV0X.js";
|
|
7
|
-
|
|
8
|
-
const [t,
|
|
9
|
-
|
|
7
|
+
const W = ({ onCancel: f, onSubmit: a }) => {
|
|
8
|
+
const [t, s] = i(), [o, p] = i(), [l, n] = i(), h = (e) => {
|
|
9
|
+
s(e);
|
|
10
10
|
}, v = (e) => {
|
|
11
|
-
|
|
12
|
-
},
|
|
11
|
+
s(e.target.value);
|
|
12
|
+
}, c = () => {
|
|
13
13
|
if (t && t.trim().length > 0)
|
|
14
14
|
if (C(t)) {
|
|
15
15
|
const e = L(t);
|
|
@@ -21,8 +21,8 @@ function W({ onCancel: f, onSubmit: a }) {
|
|
|
21
21
|
}, x = () => {
|
|
22
22
|
a && o && a(o);
|
|
23
23
|
};
|
|
24
|
-
return k(() => (
|
|
25
|
-
}), [t,
|
|
24
|
+
return k(() => (c(), () => {
|
|
25
|
+
}), [t, c]), t === void 0 ? /* @__PURE__ */ r(M, { onSubmit: h }) : /* @__PURE__ */ u(m, { pt: 1, children: [
|
|
26
26
|
/* @__PURE__ */ r(
|
|
27
27
|
b,
|
|
28
28
|
{
|
|
@@ -36,16 +36,16 @@ function W({ onCancel: f, onSubmit: a }) {
|
|
|
36
36
|
autoFocus: !0,
|
|
37
37
|
InputLabelProps: { shrink: !0 },
|
|
38
38
|
onChange: v,
|
|
39
|
-
...
|
|
39
|
+
...l !== void 0 && {
|
|
40
40
|
error: !0,
|
|
41
|
-
helperText:
|
|
41
|
+
helperText: l
|
|
42
42
|
}
|
|
43
43
|
}
|
|
44
44
|
),
|
|
45
|
-
/* @__PURE__ */
|
|
46
|
-
/* @__PURE__ */ r(
|
|
45
|
+
/* @__PURE__ */ u(m, { display: "flex", justifyContent: "space-between", mt: 3, children: [
|
|
46
|
+
/* @__PURE__ */ r(d, { color: "primary", onClick: f, children: "Cancel" }),
|
|
47
47
|
/* @__PURE__ */ r(
|
|
48
|
-
|
|
48
|
+
d,
|
|
49
49
|
{
|
|
50
50
|
color: "primary",
|
|
51
51
|
variant: "contained",
|
|
@@ -56,7 +56,7 @@ function W({ onCancel: f, onSubmit: a }) {
|
|
|
56
56
|
)
|
|
57
57
|
] })
|
|
58
58
|
] });
|
|
59
|
-
}
|
|
59
|
+
};
|
|
60
60
|
export {
|
|
61
|
-
W as
|
|
61
|
+
W as Kml
|
|
62
62
|
};
|