@itwin/map-layers 3.0.0-dev.78 → 3.0.0-dev.82
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/lib/{map-layers.d.ts → cjs/map-layers.d.ts} +0 -0
- package/lib/cjs/map-layers.d.ts.map +1 -0
- package/lib/{map-layers.js → cjs/map-layers.js} +0 -0
- package/lib/cjs/map-layers.js.map +1 -0
- package/lib/{mapLayers.d.ts → cjs/mapLayers.d.ts} +0 -0
- package/lib/cjs/mapLayers.d.ts.map +1 -0
- package/lib/{mapLayers.js → cjs/mapLayers.js} +0 -0
- package/lib/cjs/mapLayers.js.map +1 -0
- package/lib/{public → cjs/public}/locales/en/mapLayers.json +0 -0
- package/lib/{ui → cjs/ui}/Interfaces.d.ts +0 -0
- package/lib/cjs/ui/Interfaces.d.ts.map +1 -0
- package/lib/{ui → cjs/ui}/Interfaces.js +0 -0
- package/lib/cjs/ui/Interfaces.js.map +1 -0
- package/lib/{ui → cjs/ui}/MapLayersUiItemsProvider.d.ts +0 -0
- package/lib/cjs/ui/MapLayersUiItemsProvider.d.ts.map +1 -0
- package/lib/{ui → cjs/ui}/MapLayersUiItemsProvider.js +0 -0
- package/lib/cjs/ui/MapLayersUiItemsProvider.js.map +1 -0
- package/lib/{ui → cjs/ui}/widget/AttachLayerPopupButton.d.ts +0 -0
- package/lib/cjs/ui/widget/AttachLayerPopupButton.d.ts.map +1 -0
- package/lib/{ui → cjs/ui}/widget/AttachLayerPopupButton.js +0 -0
- package/lib/cjs/ui/widget/AttachLayerPopupButton.js.map +1 -0
- package/lib/{ui → cjs/ui}/widget/BasemapPanel.d.ts +0 -0
- package/lib/cjs/ui/widget/BasemapPanel.d.ts.map +1 -0
- package/lib/{ui → cjs/ui}/widget/BasemapPanel.js +0 -0
- package/lib/cjs/ui/widget/BasemapPanel.js.map +1 -0
- package/lib/{ui → cjs/ui}/widget/BasemapPanel.scss +1 -1
- package/lib/{ui → cjs/ui}/widget/ConfirmMessageDialog.d.ts +0 -0
- package/lib/cjs/ui/widget/ConfirmMessageDialog.d.ts.map +1 -0
- package/lib/{ui → cjs/ui}/widget/ConfirmMessageDialog.js +0 -0
- package/lib/cjs/ui/widget/ConfirmMessageDialog.js.map +1 -0
- package/lib/{ui → cjs/ui}/widget/MapLayerDroppable.d.ts +0 -0
- package/lib/cjs/ui/widget/MapLayerDroppable.d.ts.map +1 -0
- package/lib/{ui → cjs/ui}/widget/MapLayerDroppable.js +0 -0
- package/lib/cjs/ui/widget/MapLayerDroppable.js.map +1 -0
- package/lib/{ui → cjs/ui}/widget/MapLayerManager.d.ts +0 -0
- package/lib/cjs/ui/widget/MapLayerManager.d.ts.map +1 -0
- package/lib/{ui → cjs/ui}/widget/MapLayerManager.js +0 -0
- package/lib/cjs/ui/widget/MapLayerManager.js.map +1 -0
- package/lib/{ui → cjs/ui}/widget/MapLayerManager.scss +1 -1
- package/lib/{ui → cjs/ui}/widget/MapLayerSettingsMenu.d.ts +0 -0
- package/lib/cjs/ui/widget/MapLayerSettingsMenu.d.ts.map +1 -0
- package/lib/{ui → cjs/ui}/widget/MapLayerSettingsMenu.js +0 -0
- package/lib/cjs/ui/widget/MapLayerSettingsMenu.js.map +1 -0
- package/lib/{ui → cjs/ui}/widget/MapLayerSettingsPopupButton.d.ts +0 -0
- package/lib/cjs/ui/widget/MapLayerSettingsPopupButton.d.ts.map +1 -0
- package/lib/{ui → cjs/ui}/widget/MapLayerSettingsPopupButton.js +0 -0
- package/lib/cjs/ui/widget/MapLayerSettingsPopupButton.js.map +1 -0
- package/lib/{ui → cjs/ui}/widget/MapLayerSettingsPopupButton.scss +1 -1
- package/lib/{ui → cjs/ui}/widget/MapLayersWidget.d.ts +0 -0
- package/lib/cjs/ui/widget/MapLayersWidget.d.ts.map +1 -0
- package/lib/{ui → cjs/ui}/widget/MapLayersWidget.js +0 -0
- package/lib/cjs/ui/widget/MapLayersWidget.js.map +1 -0
- package/lib/{ui → cjs/ui}/widget/MapManagerSettings.d.ts +0 -0
- package/lib/cjs/ui/widget/MapManagerSettings.d.ts.map +1 -0
- package/lib/{ui → cjs/ui}/widget/MapManagerSettings.js +0 -0
- package/lib/cjs/ui/widget/MapManagerSettings.js.map +1 -0
- package/lib/{ui → cjs/ui}/widget/MapManagerSettings.scss +1 -1
- package/lib/{ui → cjs/ui}/widget/MapUrlDialog.d.ts +0 -0
- package/lib/cjs/ui/widget/MapUrlDialog.d.ts.map +1 -0
- package/lib/{ui → cjs/ui}/widget/MapUrlDialog.js +0 -0
- package/lib/cjs/ui/widget/MapUrlDialog.js.map +1 -0
- package/lib/{ui → cjs/ui}/widget/MapUrlDialog.scss +1 -1
- package/lib/{ui → cjs/ui}/widget/SubLayersDataProvider.d.ts +0 -0
- package/lib/cjs/ui/widget/SubLayersDataProvider.d.ts.map +1 -0
- package/lib/{ui → cjs/ui}/widget/SubLayersDataProvider.js +0 -0
- package/lib/cjs/ui/widget/SubLayersDataProvider.js.map +1 -0
- package/lib/{ui → cjs/ui}/widget/SubLayersPopupButton.d.ts +0 -0
- package/lib/cjs/ui/widget/SubLayersPopupButton.d.ts.map +1 -0
- package/lib/{ui → cjs/ui}/widget/SubLayersPopupButton.js +0 -0
- package/lib/cjs/ui/widget/SubLayersPopupButton.js.map +1 -0
- package/lib/{ui → cjs/ui}/widget/SubLayersTree.d.ts +0 -0
- package/lib/cjs/ui/widget/SubLayersTree.d.ts.map +1 -0
- package/lib/{ui → cjs/ui}/widget/SubLayersTree.js +0 -0
- package/lib/cjs/ui/widget/SubLayersTree.js.map +1 -0
- package/lib/{ui → cjs/ui}/widget/SubLayersTree.scss +1 -1
- package/lib/{ui → cjs/ui}/widget/TransparencyPopupButton.d.ts +0 -0
- package/lib/cjs/ui/widget/TransparencyPopupButton.d.ts.map +1 -0
- package/lib/{ui → cjs/ui}/widget/TransparencyPopupButton.js +0 -0
- package/lib/cjs/ui/widget/TransparencyPopupButton.js.map +1 -0
- package/lib/{ui → cjs/ui}/widget/TransparencyPopupButton.scss +1 -1
- package/lib/esm/map-layers.d.ts +5 -0
- package/lib/esm/map-layers.d.ts.map +1 -0
- package/lib/esm/map-layers.js +9 -0
- package/lib/esm/map-layers.js.map +1 -0
- package/lib/esm/mapLayers.d.ts +29 -0
- package/lib/esm/mapLayers.d.ts.map +1 -0
- package/lib/esm/mapLayers.js +50 -0
- package/lib/esm/mapLayers.js.map +1 -0
- package/lib/esm/public/locales/en/mapLayers.json +113 -0
- package/lib/esm/ui/Interfaces.d.ts +32 -0
- package/lib/esm/ui/Interfaces.d.ts.map +1 -0
- package/lib/esm/ui/Interfaces.js +2 -0
- package/lib/esm/ui/Interfaces.js.map +1 -0
- package/lib/esm/ui/MapLayersUiItemsProvider.d.ts +23 -0
- package/lib/esm/ui/MapLayersUiItemsProvider.d.ts.map +1 -0
- package/lib/esm/ui/MapLayersUiItemsProvider.js +50 -0
- package/lib/esm/ui/MapLayersUiItemsProvider.js.map +1 -0
- package/lib/esm/ui/widget/AttachLayerPopupButton.d.ts +14 -0
- package/lib/esm/ui/widget/AttachLayerPopupButton.d.ts.map +1 -0
- package/lib/esm/ui/widget/AttachLayerPopupButton.js +308 -0
- package/lib/esm/ui/widget/AttachLayerPopupButton.js.map +1 -0
- package/lib/esm/ui/widget/BasemapPanel.d.ts +5 -0
- package/lib/esm/ui/widget/BasemapPanel.d.ts.map +1 -0
- package/lib/esm/ui/widget/BasemapPanel.js +141 -0
- package/lib/esm/ui/widget/BasemapPanel.js.map +1 -0
- package/lib/esm/ui/widget/BasemapPanel.scss +98 -0
- package/lib/esm/ui/widget/ConfirmMessageDialog.d.ts +22 -0
- package/lib/esm/ui/widget/ConfirmMessageDialog.d.ts.map +1 -0
- package/lib/esm/ui/widget/ConfirmMessageDialog.js +22 -0
- package/lib/esm/ui/widget/ConfirmMessageDialog.js.map +1 -0
- package/lib/esm/ui/widget/MapLayerDroppable.d.ts +19 -0
- package/lib/esm/ui/widget/MapLayerDroppable.d.ts.map +1 -0
- package/lib/esm/ui/widget/MapLayerDroppable.js +80 -0
- package/lib/esm/ui/widget/MapLayerDroppable.js.map +1 -0
- package/lib/esm/ui/widget/MapLayerManager.d.ts +27 -0
- package/lib/esm/ui/widget/MapLayerManager.d.ts.map +1 -0
- package/lib/esm/ui/widget/MapLayerManager.js +347 -0
- package/lib/esm/ui/widget/MapLayerManager.js.map +1 -0
- package/lib/esm/ui/widget/MapLayerManager.scss +525 -0
- package/lib/esm/ui/widget/MapLayerSettingsMenu.d.ts +10 -0
- package/lib/esm/ui/widget/MapLayerSettingsMenu.d.ts.map +1 -0
- package/lib/esm/ui/widget/MapLayerSettingsMenu.js +79 -0
- package/lib/esm/ui/widget/MapLayerSettingsMenu.js.map +1 -0
- package/lib/esm/ui/widget/MapLayerSettingsPopupButton.d.ts +5 -0
- package/lib/esm/ui/widget/MapLayerSettingsPopupButton.d.ts.map +1 -0
- package/lib/esm/ui/widget/MapLayerSettingsPopupButton.js +31 -0
- package/lib/esm/ui/widget/MapLayerSettingsPopupButton.js.map +1 -0
- package/lib/esm/ui/widget/MapLayerSettingsPopupButton.scss +31 -0
- package/lib/esm/ui/widget/MapLayersWidget.d.ts +12 -0
- package/lib/esm/ui/widget/MapLayersWidget.d.ts.map +1 -0
- package/lib/esm/ui/widget/MapLayersWidget.js +23 -0
- package/lib/esm/ui/widget/MapLayersWidget.js.map +1 -0
- package/lib/esm/ui/widget/MapManagerSettings.d.ts +4 -0
- package/lib/esm/ui/widget/MapManagerSettings.d.ts.map +1 -0
- package/lib/esm/ui/widget/MapManagerSettings.js +168 -0
- package/lib/esm/ui/widget/MapManagerSettings.js.map +1 -0
- package/lib/esm/ui/widget/MapManagerSettings.scss +23 -0
- package/lib/esm/ui/widget/MapUrlDialog.d.ts +23 -0
- package/lib/esm/ui/widget/MapUrlDialog.d.ts.map +1 -0
- package/lib/esm/ui/widget/MapUrlDialog.js +346 -0
- package/lib/esm/ui/widget/MapUrlDialog.js.map +1 -0
- package/lib/esm/ui/widget/MapUrlDialog.scss +85 -0
- package/lib/esm/ui/widget/SubLayersDataProvider.d.ts +21 -0
- package/lib/esm/ui/widget/SubLayersDataProvider.d.ts.map +1 -0
- package/lib/esm/ui/widget/SubLayersDataProvider.js +73 -0
- package/lib/esm/ui/widget/SubLayersDataProvider.js.map +1 -0
- package/lib/esm/ui/widget/SubLayersPopupButton.d.ts +11 -0
- package/lib/esm/ui/widget/SubLayersPopupButton.d.ts.map +1 -0
- package/lib/esm/ui/widget/SubLayersPopupButton.js +36 -0
- package/lib/esm/ui/widget/SubLayersPopupButton.js.map +1 -0
- package/lib/esm/ui/widget/SubLayersTree.d.ts +16 -0
- package/lib/esm/ui/widget/SubLayersTree.d.ts.map +1 -0
- package/lib/esm/ui/widget/SubLayersTree.js +374 -0
- package/lib/esm/ui/widget/SubLayersTree.js.map +1 -0
- package/lib/esm/ui/widget/SubLayersTree.scss +64 -0
- package/lib/esm/ui/widget/TransparencyPopupButton.d.ts +14 -0
- package/lib/esm/ui/widget/TransparencyPopupButton.d.ts.map +1 -0
- package/lib/esm/ui/widget/TransparencyPopupButton.js +44 -0
- package/lib/esm/ui/widget/TransparencyPopupButton.js.map +1 -0
- package/lib/esm/ui/widget/TransparencyPopupButton.scss +53 -0
- package/lib/public/en/mapLayers.json +113 -0
- package/package.json +45 -39
- package/lib/map-layers.d.ts.map +0 -1
- package/lib/map-layers.js.map +0 -1
- package/lib/mapLayers.d.ts.map +0 -1
- package/lib/mapLayers.js.map +0 -1
- package/lib/ui/Interfaces.d.ts.map +0 -1
- package/lib/ui/Interfaces.js.map +0 -1
- package/lib/ui/MapLayersUiItemsProvider.d.ts.map +0 -1
- package/lib/ui/MapLayersUiItemsProvider.js.map +0 -1
- package/lib/ui/widget/AttachLayerPopupButton.d.ts.map +0 -1
- package/lib/ui/widget/AttachLayerPopupButton.js.map +0 -1
- package/lib/ui/widget/BasemapPanel.d.ts.map +0 -1
- package/lib/ui/widget/BasemapPanel.js.map +0 -1
- package/lib/ui/widget/ConfirmMessageDialog.d.ts.map +0 -1
- package/lib/ui/widget/ConfirmMessageDialog.js.map +0 -1
- package/lib/ui/widget/MapLayerDroppable.d.ts.map +0 -1
- package/lib/ui/widget/MapLayerDroppable.js.map +0 -1
- package/lib/ui/widget/MapLayerManager.d.ts.map +0 -1
- package/lib/ui/widget/MapLayerManager.js.map +0 -1
- package/lib/ui/widget/MapLayerSettingsMenu.d.ts.map +0 -1
- package/lib/ui/widget/MapLayerSettingsMenu.js.map +0 -1
- package/lib/ui/widget/MapLayerSettingsPopupButton.d.ts.map +0 -1
- package/lib/ui/widget/MapLayerSettingsPopupButton.js.map +0 -1
- package/lib/ui/widget/MapLayersWidget.d.ts.map +0 -1
- package/lib/ui/widget/MapLayersWidget.js.map +0 -1
- package/lib/ui/widget/MapManagerSettings.d.ts.map +0 -1
- package/lib/ui/widget/MapManagerSettings.js.map +0 -1
- package/lib/ui/widget/MapUrlDialog.d.ts.map +0 -1
- package/lib/ui/widget/MapUrlDialog.js.map +0 -1
- package/lib/ui/widget/SubLayersDataProvider.d.ts.map +0 -1
- package/lib/ui/widget/SubLayersDataProvider.js.map +0 -1
- package/lib/ui/widget/SubLayersPopupButton.d.ts.map +0 -1
- package/lib/ui/widget/SubLayersPopupButton.js.map +0 -1
- package/lib/ui/widget/SubLayersTree.d.ts.map +0 -1
- package/lib/ui/widget/SubLayersTree.js.map +0 -1
- package/lib/ui/widget/TransparencyPopupButton.d.ts.map +0 -1
- package/lib/ui/widget/TransparencyPopupButton.js.map +0 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"MapUrlDialog.js","sourceRoot":"","sources":["../../../../src/ui/widget/MapUrlDialog.tsx"],"names":[],"mappings":";AAAA;;;+FAG+F;AAC/F,8BAA8B;;;AAE9B,+BAA+B;AAC/B,wDAAwG;AACxG,kDAA8D;AAC9D,oDAAwD;AACxD,0EAAuE;AAEvE,wDAG8B;AAE9B,+BAA6B;AAC7B,0DAAqE;AAExD,QAAA,SAAS,GAAG;IACvB,GAAG,EAA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,KAAK,EAAE,kBAAkB,EAAE,OAAO,EAAE,eAAe,KAAK,OAAO,EAC/D,QAAQ,EAAE,aAAa,GAAI,CACzB,CACF,CACF;YAGN,6BAAK,SAAS,EAAC,8BAA8B,IAC1C,cAAc,CAAC,CAAC;gBACf;oBACE,oBAAC,iBAAI,IAAC,SAAS,EAAC,mCAAmC,EAAC,QAAQ,EAAC,qBAAqB,GAAG;oBACrF,8BAAM,SAAS,EAAC,oCAAoC,IAAE,cAAc,CAAS,CAC5E;gBACH,CAAC;oBACD,sCAAsC;oBACtC,8BAAM,SAAS,EAAC,8BAA8B,aAAc,CAE1D;YAGL,kBAAkB;gBACjB,6BAAK,SAAS,EAAC,8BAA8B;oBAC3C,oBAAC,8BAAc,IAAC,aAAa,SAAG,CAC5B,CAED,CACJ,CACR,CAAC;AACJ,CAAC;AAlZD,oCAkZC","sourcesContent":["/*---------------------------------------------------------------------------------------------\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\n* See LICENSE.md in the project root for license terms and full copyright notice.\n*--------------------------------------------------------------------------------------------*/\n// cSpell:ignore Modeless WMTS\n\nimport * as React from \"react\";\nimport { Input, LabeledInput, ProgressLinear, Radio, Select, SelectOption } from \"@itwin/itwinui-react\";\nimport { Dialog, Icon, InputStatus } from \"@itwin/core-react\";\nimport { ModalDialogManager } from \"@itwin/appui-react\";\nimport { MapLayersUiItemsProvider } from \"../MapLayersUiItemsProvider\";\nimport { MapTypesOptions } from \"../Interfaces\";\nimport {\n IModelApp, MapLayerImageryProviderStatus, MapLayerSettingsService, MapLayerSource,\n MapLayerSourceStatus, NotifyMessageDetails, OutputMessagePriority, ScreenViewport,\n} from \"@itwin/core-frontend\";\nimport { MapLayerProps } from \"@itwin/core-common\";\nimport \"./MapUrlDialog.scss\";\nimport { DialogButtonType, SpecialKey } from \"@itwin/appui-abstract\";\n\nexport const MAP_TYPES = {\n wms: \"WMS\",\n arcGis: \"ArcGIS\",\n wmts: \"WMTS\",\n tileUrl: \"TileURL\",\n};\n\ninterface MapUrlDialogProps {\n activeViewport?: ScreenViewport;\n isOverlay: boolean;\n onOkResult: () => void;\n onCancelResult?: () => void;\n mapTypesOptions?: MapTypesOptions;\n\n // An optional layer definition can be provide to enable the edit mode\n layerRequiringCredentials?: MapLayerProps;\n\n mapLayerSourceToEdit?: MapLayerSource;\n}\n\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport function MapUrlDialog(props: MapUrlDialogProps) {\n const { isOverlay, onOkResult, mapTypesOptions } = props;\n const supportWmsAuthentication = (mapTypesOptions?.supportWmsAuthentication ? true : false);\n\n const getMapUrlFromProps = React.useCallback(() => {\n if (props.mapLayerSourceToEdit) {\n return props.mapLayerSourceToEdit.url;\n } else if (props.layerRequiringCredentials?.url) {\n return props.layerRequiringCredentials.url;\n }\n return \"\";\n }, [props.layerRequiringCredentials, props.mapLayerSourceToEdit]);\n\n const getMapNameFromProps = React.useCallback(() => {\n if (props.mapLayerSourceToEdit) {\n return props.mapLayerSourceToEdit.name;\n } else if (props.layerRequiringCredentials?.name) {\n return props.layerRequiringCredentials.name;\n }\n return \"\";\n }, [props.layerRequiringCredentials, props.mapLayerSourceToEdit]);\n\n const getFormatFromProps = React.useCallback(() => {\n if (props.mapLayerSourceToEdit) {\n return props.mapLayerSourceToEdit.formatId;\n } else if (props.layerRequiringCredentials?.formatId) {\n return props.layerRequiringCredentials.formatId;\n }\n return undefined;\n }, [props.layerRequiringCredentials, props.mapLayerSourceToEdit]);\n\n const [dialogTitle] = React.useState(MapLayersUiItemsProvider.localization.getLocalizedString(props.layerRequiringCredentials || props.mapLayerSourceToEdit ? \"mapLayers:CustomAttach.EditCustomLayer\" : \"mapLayers:CustomAttach.AttachCustomLayer\"));\n const [typeLabel] = React.useState(MapLayersUiItemsProvider.localization.getLocalizedString(\"mapLayers:CustomAttach.Type\"));\n const [nameLabel] = React.useState(MapLayersUiItemsProvider.localization.getLocalizedString(\"mapLayers:CustomAttach.Name\"));\n const [nameInputPlaceHolder] = React.useState(MapLayersUiItemsProvider.localization.getLocalizedString(\"mapLayers:CustomAttach.NameInputPlaceHolder\"));\n const [urlLabel] = React.useState(MapLayersUiItemsProvider.localization.getLocalizedString(\"mapLayers:CustomAttach.URL\"));\n const [urlInputPlaceHolder] = React.useState(MapLayersUiItemsProvider.localization.getLocalizedString(\"mapLayers:CustomAttach.UrlInputPlaceHolder\"));\n const [iTwinSettingsLabel] = React.useState(MapLayersUiItemsProvider.localization.getLocalizedString(\"mapLayers:CustomAttach.StoreOnITwinSettings\"));\n const [modelSettingsLabel] = React.useState(MapLayersUiItemsProvider.localization.getLocalizedString(\"mapLayers:CustomAttach.StoreOnModelSettings\"));\n const [missingCredentialsLabel] = React.useState(MapLayersUiItemsProvider.localization.getLocalizedString(\"mapLayers:CustomAttach.MissingCredentials\"));\n const [invalidCredentialsLabel] = React.useState(MapLayersUiItemsProvider.localization.getLocalizedString(\"mapLayers:CustomAttach.InvalidCredentials\"));\n const [serverRequireCredentials, setServerRequireCredentials] = React.useState(props.layerRequiringCredentials ?? false);\n const [invalidCredentialsProvided, setInvalidCredentialsProvided] = React.useState(false);\n const [layerAttachPending, setLayerAttachPending] = React.useState(false);\n const [warningMessage, setWarningMessage] = React.useState(props.layerRequiringCredentials ? missingCredentialsLabel : undefined);\n const [mapUrl, setMapUrl] = React.useState(getMapUrlFromProps());\n const [mapName, setMapName] = React.useState(getMapNameFromProps());\n const [userName, setUserName] = React.useState(\"\");\n const [password, setPassword] = React.useState(\"\");\n const [noSaveSettingsWarning] = React.useState(MapLayersUiItemsProvider.localization.getLocalizedString(\"mapLayers:CustomAttach.NoSaveSettingsWarning\"));\n const [passwordLabel] = React.useState(MapLayersUiItemsProvider.localization.getLocalizedString(\"mapLayers:AuthenticationInputs.Password\"));\n const [passwordRequiredLabel] = React.useState(MapLayersUiItemsProvider.localization.getLocalizedString(\"mapLayers:AuthenticationInputs.PasswordRequired\"));\n const [userNameLabel] = React.useState(MapLayersUiItemsProvider.localization.getLocalizedString(\"mapLayers:AuthenticationInputs.Username\"));\n const [userNameRequiredLabel] = React.useState(MapLayersUiItemsProvider.localization.getLocalizedString(\"mapLayers:AuthenticationInputs.UsernameRequired\"));\n const [settingsStorage, setSettingsStorageRadio] = React.useState(\"ITwin\");\n\n const [mapType, setMapType] = React.useState(getFormatFromProps() ?? MAP_TYPES.arcGis);\n\n // 'isMounted' is used to prevent any async operation once the hook has been\n // unloaded. Otherwise we get a 'Can't perform a React state update on an unmounted component.' warning in the console.\n const isMounted = React.useRef(false);\n React.useEffect(() => {\n isMounted.current = true;\n return () => {\n isMounted.current = false;\n };\n }, []);\n\n const [mapTypes] = React.useState((): SelectOption<string>[] => {\n const types = [\n { value: MAP_TYPES.arcGis, label: MAP_TYPES.arcGis },\n { value: MAP_TYPES.wms, label: MAP_TYPES.wms },\n { value: MAP_TYPES.wmts, label: MAP_TYPES.wmts },\n ];\n if (mapTypesOptions?.supportTileUrl)\n types.push({ value: MAP_TYPES.tileUrl, label: MAP_TYPES.tileUrl });\n return types;\n });\n\n const [isSettingsStorageAvailable] = React.useState(props?.activeViewport?.iModel?.iTwinId && props?.activeViewport?.iModel?.iModelId);\n\n // Even though the settings storage is available,\n // we don't always want to enable it in the UI.\n const [settingsStorageDisabled] = React.useState(!isSettingsStorageAvailable || props.mapLayerSourceToEdit !== undefined || props.layerRequiringCredentials !== undefined);\n\n const isAuthSupported = React.useCallback(() => {\n return ((mapType === MAP_TYPES.wms || mapType === MAP_TYPES.wms) && supportWmsAuthentication)\n || mapType === MAP_TYPES.arcGis;\n }, [mapType, supportWmsAuthentication]);\n\n // const [layerIdxToEdit] = React.useState((): number | undefined => {\n const [layerRequiringCredentialsIdx] = React.useState((): number | undefined => {\n if (props.layerRequiringCredentials === undefined || !props.layerRequiringCredentials.name || !props.layerRequiringCredentials.url) {\n return undefined;\n }\n\n const indexInDisplayStyle = props.activeViewport?.displayStyle.findMapLayerIndexByNameAndUrl(props.layerRequiringCredentials.name, props.layerRequiringCredentials.url, isOverlay);\n if (indexInDisplayStyle === undefined || indexInDisplayStyle < 0) {\n return undefined;\n } else {\n return indexInDisplayStyle;\n }\n });\n\n // Update warning message based on the dialog state and server response\n React.useEffect(() => {\n if (invalidCredentialsProvided) {\n setWarningMessage(invalidCredentialsLabel);\n } else if (serverRequireCredentials && (!userName || !password)) {\n setWarningMessage(missingCredentialsLabel);\n } else {\n setWarningMessage(undefined);\n }\n }, [invalidCredentialsProvided, invalidCredentialsLabel, missingCredentialsLabel, serverRequireCredentials, userName, password, setWarningMessage]);\n\n const handleMapTypeSelection = React.useCallback((newValue: string) => {\n setMapType(newValue);\n }, [setMapType]);\n\n const handleCancel = React.useCallback(() => {\n if (props.onCancelResult) {\n props.onCancelResult();\n return;\n }\n ModalDialogManager.closeDialog();\n }, [props]);\n\n const onUsernameChange = React.useCallback((event: React.ChangeEvent<HTMLInputElement>) => {\n setUserName(event.target.value);\n if (invalidCredentialsProvided)\n setInvalidCredentialsProvided(false);\n }, [setUserName, invalidCredentialsProvided, setInvalidCredentialsProvided]);\n\n const onPasswordChange = React.useCallback((event: React.ChangeEvent<HTMLInputElement>) => {\n setPassword(event.target.value);\n if (invalidCredentialsProvided)\n setInvalidCredentialsProvided(false);\n }, [setPassword, invalidCredentialsProvided, setInvalidCredentialsProvided]);\n\n const doAttach = React.useCallback(async (source: MapLayerSource): Promise<boolean> => {\n // Returns a promise, When true, the dialog should closed\n return new Promise<boolean>((resolve, _reject) => {\n const vp = props?.activeViewport;\n if (vp === undefined || source === undefined) {\n resolve(true);\n return;\n }\n\n const storeOnIModel = \"Model\" === settingsStorage;\n source.validateSource(true).then(async (validation) => {\n if (validation.status === MapLayerSourceStatus.Valid\n || validation.status === MapLayerSourceStatus.RequireAuth\n || validation.status === MapLayerSourceStatus.InvalidCredentials) {\n const sourceRequireAuth = (validation.status === MapLayerSourceStatus.RequireAuth);\n const invalidCredentials = (validation.status === MapLayerSourceStatus.InvalidCredentials);\n const closeDialog = !sourceRequireAuth && !invalidCredentials;\n resolve(closeDialog);\n\n if (sourceRequireAuth && !serverRequireCredentials) {\n setServerRequireCredentials(true);\n }\n if (invalidCredentials) {\n setInvalidCredentialsProvided(true);\n return;\n } else if (invalidCredentialsProvided) {\n setInvalidCredentialsProvided(false); // flag reset\n }\n\n if (validation.status === MapLayerSourceStatus.Valid) {\n // Attach layer and update settings service (only if editing)\n if (layerRequiringCredentialsIdx !== undefined) {\n // Update username / password\n vp.displayStyle.changeMapLayerProps({\n subLayers: validation.subLayers,\n }, layerRequiringCredentialsIdx, isOverlay);\n vp.displayStyle.changeMapLayerCredentials(layerRequiringCredentialsIdx, isOverlay, source.userName, source.password);\n\n // Reset the provider's status\n const provider = vp.getMapLayerImageryProvider(layerRequiringCredentialsIdx, isOverlay);\n if (provider && provider.status !== MapLayerImageryProviderStatus.Valid) {\n provider.status = MapLayerImageryProviderStatus.Valid;\n }\n } else {\n // Update service settings if storage is available and we are not prompting user for credentials\n if (!settingsStorageDisabled && !props.layerRequiringCredentials) {\n if (!(await MapLayerSettingsService.storeSourceInSettingsService(source, storeOnIModel, vp.iModel.iTwinId!, vp.iModel.iModelId!)))\n return;\n }\n const layerSettings = source.toLayerSettings(validation.subLayers);\n if (layerSettings) {\n vp.displayStyle.attachMapLayerSettings(layerSettings, isOverlay, undefined);\n\n const msg = IModelApp.localization.getLocalizedString(\"mapLayers:Messages.MapLayerAttached\", { sourceName: source.name, sourceUrl: source.url });\n IModelApp.notifications.outputMessage(new NotifyMessageDetails(OutputMessagePriority.Info, msg));\n } else {\n const msgError = MapLayersUiItemsProvider.localization.getLocalizedString(\"mapLayers:Messages.MapLayerLayerSettingsConversionError\");\n const msg = MapLayersUiItemsProvider.localization.getLocalizedString(\"mapLayers:CustomAttach.MapLayerAttachError\", { error: msgError, sourceUrl: source.url });\n IModelApp.notifications.outputMessage(new NotifyMessageDetails(OutputMessagePriority.Error, msg));\n }\n }\n\n vp.invalidateRenderPlan();\n }\n\n if (closeDialog) {\n // This handler will close the layer source handler, and therefore the MapUrl dialog.\n // don't call it if the dialog needs to remains open.\n onOkResult();\n }\n\n } else {\n const msg = MapLayersUiItemsProvider.localization.getLocalizedString(\"mapLayers:CustomAttach.ValidationError\");\n IModelApp.notifications.outputMessage(new NotifyMessageDetails(OutputMessagePriority.Error, `${msg} ${source.url}`));\n resolve(true);\n }\n resolve(false);\n }).catch((error) => {\n const msg = MapLayersUiItemsProvider.localization.getLocalizedString(\"mapLayers:CustomAttach.MapLayerAttachError\", { error, sourceUrl: source.url });\n IModelApp.notifications.outputMessage(new NotifyMessageDetails(OutputMessagePriority.Error, msg));\n resolve(true);\n });\n });\n }, [props.activeViewport, props.layerRequiringCredentials, settingsStorage, serverRequireCredentials, invalidCredentialsProvided, onOkResult, layerRequiringCredentialsIdx, isOverlay, settingsStorageDisabled]);\n\n const onNameChange = React.useCallback((event: React.ChangeEvent<HTMLInputElement>) => {\n setMapName(event.target.value);\n }, [setMapName]);\n\n const onRadioChange = React.useCallback((event: React.ChangeEvent<HTMLInputElement>) => {\n setSettingsStorageRadio(event.target.value);\n }, [setSettingsStorageRadio]);\n\n const onUrlChange = React.useCallback((event: React.ChangeEvent<HTMLInputElement>) => {\n setMapUrl(event.target.value);\n }, [setMapUrl]);\n\n const handleOk = React.useCallback(() => {\n let source: MapLayerSource | undefined;\n if (mapUrl && mapName) {\n source = MapLayerSource.fromJSON({\n url: mapUrl,\n name: mapName,\n formatId: mapType,\n userName,\n password,\n });\n\n if (source === undefined || props.mapLayerSourceToEdit) {\n\n ModalDialogManager.closeDialog();\n\n if (source === undefined) {\n // Close the dialog and inform end user something went wrong.\n const msgError = MapLayersUiItemsProvider.localization.getLocalizedString(\"mapLayers:Messages.MapLayerLayerSourceCreationFailed\");\n const msg = MapLayersUiItemsProvider.localization.getLocalizedString(\"mapLayers:CustomAttach.MapLayerAttachError\", { error: msgError, sourceUrl: mapUrl });\n IModelApp.notifications.outputMessage(new NotifyMessageDetails(OutputMessagePriority.Error, msg));\n return;\n }\n\n // Simply change the source definition in the setting service\n if (props.mapLayerSourceToEdit !== undefined) {\n const vp = props.activeViewport;\n void (async () => {\n if (isSettingsStorageAvailable && vp) {\n if (!(await MapLayerSettingsService.replaceSourceInSettingsService(props.mapLayerSourceToEdit!, source, vp.iModel.iTwinId!, vp.iModel.iModelId!))) {\n const errorMessage = IModelApp.localization.getLocalizedString(\"mapLayers:Messages.MapLayerEditError\", { layerName: props.mapLayerSourceToEdit?.name });\n IModelApp.notifications.outputMessage(new NotifyMessageDetails(OutputMessagePriority.Error, errorMessage));\n return;\n }\n\n }\n })();\n return;\n }\n }\n\n setLayerAttachPending(true);\n\n void (async () => {\n // Code below is executed in the an async manner but\n // I don't necessarily want to mark the handler as async\n // so Im wrapping it un in a void wrapper.\n try {\n const closeDialog = await doAttach(source);\n if (isMounted.current) {\n setLayerAttachPending(false);\n }\n\n // In theory the modal dialog should always get closed by the parent\n // AttachLayerPanel's 'onOkResult' handler. We close it here just in case.\n if (closeDialog) {\n ModalDialogManager.closeDialog();\n }\n } catch (_error) {\n ModalDialogManager.closeDialog();\n }\n })();\n }\n\n }, [mapUrl, mapName, mapType, userName, password, props.mapLayerSourceToEdit, props.activeViewport, isSettingsStorageAvailable, doAttach]);\n\n const dialogContainer = React.useRef<HTMLDivElement>(null);\n\n const readyToSave = React.useCallback(() => {\n const credentialsSet = !!userName && !!password;\n return (!!mapUrl && !!mapName)\n && (!serverRequireCredentials || (serverRequireCredentials && credentialsSet) && !layerAttachPending)\n && !invalidCredentialsProvided;\n }, [mapUrl, mapName, userName, password, layerAttachPending, invalidCredentialsProvided, serverRequireCredentials]);\n\n const buttonCluster = React.useMemo(() => [\n { type: DialogButtonType.OK, onClick: handleOk, disabled: !readyToSave() },\n { type: DialogButtonType.Cancel, onClick: handleCancel },\n ], [readyToSave, handleCancel, handleOk]);\n\n const handleOnKeyDown = React.useCallback((event: React.KeyboardEvent<HTMLInputElement>) => {\n if (event.key === SpecialKey.Enter) {\n if (readyToSave())\n handleOk();\n }\n }, [handleOk, readyToSave]);\n\n return (\n <div ref={dialogContainer}>\n <Dialog\n className=\"map-layer-url-dialog\"\n title={dialogTitle}\n opened={true}\n resizable={true}\n movable={true}\n modal={true}\n buttonCluster={buttonCluster}\n onClose={handleCancel}\n onEscape={handleCancel}\n minHeight={120}\n maxWidth={600}\n trapFocus={false}\n >\n <div>\n <div className=\"map-layer-source-url\">\n <span className=\"map-layer-source-label\">{typeLabel}</span>\n <Select\n className=\"map-manager-base-select\"\n options={mapTypes}\n value={mapType}\n disabled={props.layerRequiringCredentials !== undefined || props.mapLayerSourceToEdit !== undefined}\n onChange={handleMapTypeSelection} />\n <span className=\"map-layer-source-label\">{nameLabel}</span>\n <Input placeholder={nameInputPlaceHolder} onChange={onNameChange} value={mapName} disabled={props.layerRequiringCredentials !== undefined} />\n <span className=\"map-layer-source-label\">{urlLabel}</span>\n <Input placeholder={urlInputPlaceHolder} onKeyPress={handleOnKeyDown} onChange={onUrlChange} disabled={props.mapLayerSourceToEdit !== undefined} value={mapUrl} />\n {isAuthSupported() && props.mapLayerSourceToEdit === undefined &&\n <>\n <span className=\"map-layer-source-label\">{userNameLabel}</span>\n <LabeledInput placeholder={serverRequireCredentials ? userNameRequiredLabel : userNameLabel}\n status={!userName && serverRequireCredentials ? InputStatus.Warning : undefined}\n onChange={onUsernameChange} />\n\n <span className=\"map-layer-source-label\">{passwordLabel}</span>\n <LabeledInput type=\"password\" placeholder={serverRequireCredentials ? passwordRequiredLabel : passwordLabel}\n status={!password && serverRequireCredentials ? InputStatus.Warning : undefined}\n onChange={onPasswordChange}\n onKeyPress={handleOnKeyDown} />\n </>\n }\n\n {/* Store settings options, not shown when editing a layer */}\n {isSettingsStorageAvailable && <div title={settingsStorageDisabled ? noSaveSettingsWarning : \"\"}>\n <Radio disabled={settingsStorageDisabled}\n name=\"settingsStorage\" value=\"iTwin\"\n label={iTwinSettingsLabel} checked={settingsStorage === \"iTwin\"}\n onChange={onRadioChange} />\n <Radio disabled={settingsStorageDisabled}\n name=\"settingsStorage\" value=\"Model\"\n label={modelSettingsLabel} checked={settingsStorage === \"Model\"}\n onChange={onRadioChange} />\n </div>}\n </div>\n </div>\n\n {/* Warning message */}\n <div className=\"map-layer-source-warnMessage\">\n {warningMessage ?\n <>\n <Icon className=\"map-layer-source-warnMessage-icon\" iconSpec=\"icon-status-warning\" />\n <span className=\"map-layer-source-warnMessage-label\">{warningMessage}</span >\n </>\n :\n // Place holder to avoid dialog resize\n <span className=\"map-layer-source-placeholder\"> </span>\n }\n </div>\n\n {/* Progress bar */}\n {layerAttachPending &&\n <div className=\"map-layer-source-progressBar\">\n <ProgressLinear indeterminate />\n </div>\n }\n </Dialog>\n </div >\n );\n}\n"]}
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* Copyright (c) Bentley Systems, Incorporated. All rights reserved.
|
|
3
3
|
* See LICENSE.md in the project root for license terms and full copyright notice.
|
|
4
4
|
*--------------------------------------------------------------------------------------------*/
|
|
5
|
-
@import "~@itwin/core-react/lib/core-react/index";
|
|
5
|
+
@import "~@itwin/core-react/lib/cjs/core-react/index";
|
|
6
6
|
@import "~@itwin/itwinui-css/scss/style/typography";
|
|
7
7
|
|
|
8
8
|
$divider-color: $buic-background-toolbutton-stroke;
|
|
File without changes
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SubLayersDataProvider.d.ts","sourceRoot":"","sources":["../../../../src/ui/widget/SubLayersDataProvider.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,OAAO,EAA6B,MAAM,qBAAqB,CAAC;AACzE,OAAO,EAAE,gBAAgB,EAAc,MAAM,oBAAoB,CAAC;AAElE,OAAO,EAA2B,iBAAiB,EAAE,uBAAuB,EAAE,YAAY,EAAE,MAAM,yBAAyB,CAAC;AAE5H,OAAO,EAAE,qBAAqB,EAAE,MAAM,eAAe,CAAC;AAEtD;;GAEG;AACH,qBAAa,qBAAsB,YAAW,iBAAiB;IAC7D,OAAO,CAAC,QAAQ,CAAC,QAAQ,CAAqC;IAC9D,OA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,KAAK,CAAC,QAAQ,CAAC,MAAqB;QACzC,MAAM,SAAS,GAA+B,MAAM,CAAC,CAAC,CAAC,IAAI,CAAC,QAAQ,CAAC,GAAG,CAAC,MAAM,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,QAAQ,CAAC,GAAG,CAAC,EAAE,CAAC,CAAC;QAC5G,IAAI,SAAS;YACX,OAAO,SAAS,CAAC;QAEnB,OAAO,EAAE,CAAC;IACZ,CAAC;CACF;AA/ED,sDA+EC","sourcesContent":["/*---------------------------------------------------------------------------------------------\r\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\r\n* See LICENSE.md in the project root for license terms and full copyright notice.\r\n*--------------------------------------------------------------------------------------------*/\r\nimport { BeEvent, compareStringsOrUndefined } from \"@itwin/core-bentley\";\r\nimport { MapSubLayerProps, SubLayerId } from \"@itwin/core-common\";\r\nimport { PropertyRecord } from \"@itwin/appui-abstract\";\r\nimport { DelayLoadedTreeNodeItem, ITreeDataProvider, TreeDataChangesListener, TreeNodeItem } from \"@itwin/components-react\";\r\nimport { CheckBoxState } from \"@itwin/core-react\";\r\nimport { StyleMapLayerSettings } from \"../Interfaces\";\r\n\r\n/**\r\n * Data provider that returns some fake nodes to show in tree.\r\n */\r\nexport class SubLayersDataProvider implements ITreeDataProvider {\r\n private readonly _nodeMap = new Map<string, TreeNodeItem[]>();\r\n private readonly _mapLayer: StyleMapLayerSettings;\r\n\r\n constructor(mapLayer: StyleMapLayerSettings) {\r\n this._mapLayer = mapLayer;\r\n this.loadNodes(mapLayer.subLayers);\r\n }\r\n\r\n public static isUnnamedGroup(subLayer: MapSubLayerProps | undefined): boolean {\r\n if (!subLayer)\r\n return false;\r\n\r\n return (!subLayer.name || subLayer.name.length === 0) && (subLayer.children !== undefined && subLayer.children.length > 0);\r\n }\r\n\r\n private createId(props: MapSubLayerProps): string {\r\n return undefined !== props.id ? `${props.id}` : props.name ? props.name : \"no-id\";\r\n }\r\n\r\n private createNode(props: MapSubLayerProps, expanded?: boolean, isCheckboxDisabled?: boolean, icon?: string): DelayLoadedTreeNodeItem {\r\n return {\r\n id: this.createId(props),\r\n label: PropertyRecord.fromString(props.title ?? props.name ?? \"unknown\"),\r\n hasChildren: !!props.children,\r\n isCheckboxVisible: true,\r\n checkBoxState: props.visible && !isCheckboxDisabled ? CheckBoxState.On : CheckBoxState.Off,\r\n extendedData: { subLayerId: props.id },\r\n isCheckboxDisabled,\r\n autoExpand: expanded,\r\n icon,\r\n };\r\n }\r\n\r\n private loadChildNodes(allSubLayers: MapSubLayerProps[], parentId?: SubLayerId) {\r\n const filteredProps = allSubLayers.filter((props) => parentId === props.parent);\r\n if (filteredProps.length) {\r\n filteredProps?.sort((a: MapSubLayerProps, b: MapSubLayerProps) => compareStringsOrUndefined(a.title, b.title));\r\n const treeNodes: TreeNodeItem[] = [];\r\n\r\n filteredProps.forEach((props) => {\r\n treeNodes.push(this.createNode(props,\r\n (!parentId && props?.children !== undefined) ? true : undefined, // expand root group only (i.e. not the entire tree),\r\n undefined,\r\n SubLayersDataProvider.isUnnamedGroup(props) ? \"icon-folder\" : \"icon-layers\"\r\n\r\n ));\r\n if (props.children)\r\n this.loadChildNodes(allSubLayers, props.id);\r\n });\r\n\r\n this._nodeMap.set(undefined !== parentId ? `${parentId}` : \"\", treeNodes);\r\n }\r\n }\r\n\r\n private loadNodes(subLayerNodes: MapSubLayerProps[] | undefined) {\r\n subLayerNodes?.sort((a: MapSubLayerProps, b: MapSubLayerProps) => compareStringsOrUndefined(a.title, b.title));\r\n if (subLayerNodes) {\r\n this.loadChildNodes(subLayerNodes, undefined);\r\n }\r\n }\r\n\r\n public onTreeNodeChanged = new BeEvent<TreeDataChangesListener>();\r\n\r\n public async getNodesCount(parent?: TreeNodeItem) {\r\n const nodeArray: TreeNodeItem[] | undefined = parent ? this._nodeMap.get(parent.id) : this._nodeMap.get(\"\");\r\n if (nodeArray)\r\n return nodeArray.length;\r\n\r\n return 0;\r\n }\r\n\r\n public async getNodes(parent?: TreeNodeItem) {\r\n const nodeArray: TreeNodeItem[] | undefined = parent ? this._nodeMap.get(parent.id) : this._nodeMap.get(\"\");\r\n if (nodeArray)\r\n return nodeArray;\r\n\r\n return [];\r\n }\r\n}\r\n"]}
|
|
File without changes
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SubLayersPopupButton.d.ts","sourceRoot":"","sources":["../../../../src/ui/widget/SubLayersPopupButton.tsx"],"names":[],"mappings":";AAKA,OAAO,EAAE,cAAc,EAAE,MAAM,sBAAsB,CAAC;AAItD,OAAO,EAAE,qBAAqB,EAAE,MAAM,eAAe,CAAC;AAKtD,gBAAgB;AAChB,MAAM,WAAW,yBAAyB;IACxC,gBAAgB,EAAE,qBAAqB,CAAC;IACxC,cAAc,EAAE,cAAc,CAAC;CAChC;AAED,gBAAgB;AAEhB,wBAAgB,oBAAoB,CAAC,EAAE,gBAAgB,EAAE,cAAc,EAAE,EAAE,yBAAyB,eA0CnG"}
|
|
File without changes
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SubLayersPopupButton.js","sourceRoot":"","sources":["../../../../src/ui/widget/SubLayersPopupButton.tsx"],"names":[],"mappings":";;;AAAA;;;+FAG+F;AAC/F,+BAA+B;AAE/B,0DAAyD;AACzD,kDAA6F;AAC7F,mDAAiD;AAEjD,0EAAuE;AAUvE,gBAAgB;AAChB,gEAAgE;AAChE,SAAgB,oBAAoB,CAAC,EAAE,gBAAgB,EAAE,cAAc,EAA6B;IAElG,MAAM,CAAC,kBAAkB,CAAC,GAAG,KAAK,CAAC,QAAQ,CAAC,mDAAwB,CAAC,YAAY,CAAC,kBAAkB,CAAC,0BAA0B,CAAC,CAAC,CAAC;IAClI,MAAM,CAAC,kBAAkB,CAAC,GAAG,KAAK,CAAC,QAAQ,CAAC,mDAAwB,CAAC,YAAY,CAAC,kBAAkB,CAAC,0BAA0B,CAAC,CAAC,CAAC;IAClI,MAAM,CAAC,SAAS,EAAE,YAAY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AAE,SAAS,EAAC,4BAA4B;oBACxD,oBAAC,8BAAc,IAAC,QAAQ,EAAE,gBAAgB,EAAE,QAAQ,EAAE,cAAc,GAAI,CACpE,CACF,CACC,CACR,CACJ,CAAC;AACJ,CAAC;AA1CD,oDA0CC","sourcesContent":["/*---------------------------------------------------------------------------------------------\r\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\r\n* See LICENSE.md in the project root for license terms and full copyright notice.\r\n*--------------------------------------------------------------------------------------------*/\r\nimport * as React from \"react\";\r\nimport { ScreenViewport } from \"@itwin/core-frontend\";\r\nimport { RelativePosition } from \"@itwin/appui-abstract\";\r\nimport { OutsideClickEvent, Popup, useOnOutsideClick, WebFontIcon } from \"@itwin/core-react\";\r\nimport { SubLayersPanel } from \"./SubLayersTree\";\r\nimport { StyleMapLayerSettings } from \"../Interfaces\";\r\nimport { MapLayersUiItemsProvider } from \"../MapLayersUiItemsProvider\";\r\n\r\n// cSpell:ignore droppable Sublayer\r\n\r\n/** @internal */\r\nexport interface SubLayersPopupButtonProps {\r\n mapLayerSettings: StyleMapLayerSettings;\r\n activeViewport: ScreenViewport;\r\n}\r\n\r\n/** @internal */\r\n// eslint-disable-next-line @typescript-eslint/naming-convention\r\nexport function SubLayersPopupButton({ mapLayerSettings, activeViewport }: SubLayersPopupButtonProps) {\r\n\r\n const [showSubLayersLabel] = React.useState(MapLayersUiItemsProvider.localization.getLocalizedString(\"mapLayers:SubLayers.Show\"));\r\n const [hideSubLayersLabel] = React.useState(MapLayersUiItemsProvider.localization.getLocalizedString(\"mapLayers:SubLayers.Hide\"));\r\n const [popupOpen, setPopupOpen] = React.useState(false);\r\n const buttonRef = React.useRef<HTMLButtonElement>(null);\r\n\r\n const togglePopup = React.useCallback(() => {\r\n setPopupOpen(!popupOpen);\r\n }, [popupOpen]);\r\n\r\n const onOutsideClick = React.useCallback(() => {\r\n setPopupOpen(false);\r\n }, []);\r\n\r\n const isOutsideEvent = React.useCallback((e: OutsideClickEvent) => {\r\n // if clicking on button that open panel - don't trigger outside click processing\r\n return !!buttonRef.current && (e.target instanceof Node) && !buttonRef.current.contains(e.target);\r\n }, []);\r\n\r\n const panelRef = useOnOutsideClick<HTMLDivElement>(onOutsideClick, isOutsideEvent);\r\n\r\n return (\r\n <>\r\n <button ref={buttonRef} className=\"map-manager-item-sub-layer-button\" title={popupOpen ? hideSubLayersLabel : showSubLayersLabel}\r\n onClick={togglePopup}>\r\n <WebFontIcon iconName=\"icon-layers\" />\r\n </button>\r\n <Popup\r\n isOpen={popupOpen}\r\n position={RelativePosition.BottomRight}\r\n onClose={onOutsideClick}\r\n target={buttonRef.current}\r\n >\r\n <div className=\"map-transparency-popup-panel\">\r\n <div ref={panelRef} className=\"map-manager-sublayer-panel\">\r\n <SubLayersPanel mapLayer={mapLayerSettings} viewport={activeViewport} />\r\n </div>\r\n </div>\r\n </Popup >\r\n </>\r\n );\r\n}\r\n"]}
|
|
File without changes
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SubLayersTree.d.ts","sourceRoot":"","sources":["../../../../src/ui/widget/SubLayersTree.tsx"],"names":[],"mappings":";AAMA,OAAO,EAAa,cAAc,EAAE,MAAM,sBAAsB,CAAC;AAYjE,OAAO,EAAE,qBAAqB,EAAE,MAAM,eAAe,CAAC;AAGtD,OAAO,sBAAsB,CAAC;AAsB9B,wBAAgB,cAAc,CAAC,EAAE,QAAQ,EAAE,QAAQ,EAAE,EAAE;IAAE,QAAQ,EAAE,qBAAqB,CAAC;IAAC,QAAQ,EAAE,cAAc,GAAG,SAAS,CAAA;CAAE,eAW/H;AAoBD;;;GAGG;AAEH,wBAAgB,aAAa,CAAC,KAAK,EAAE;IAAE,QAAQ,EAAE,qBAAqB,CAAA;CAAE,eA8FvE"}
|
|
File without changes
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SubLayersTree.js","sourceRoot":"","sources":["../../../../src/ui/widget/SubLayersTree.tsx"],"names":[],"mappings":";;;AAAA;;;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AK;YACR,OAAO,KAAK,CAAC;QACf,OAAO,KAAK,CAAC,QAAQ,CAAC,IAAI,CAAC,OAAO,CAAC,WAAW,EAAE,CAAC,CAAC;IACpD,CAAC;IAEM,KAAK,CAAC,YAAY;QACvB,MAAM,IAAI,CAAC,KAAK,CAAC;QACjB,OAAO,IAAI,CAAC,SAAS,CAAC;IACxB,CAAC;CACF;AAED,MAAM,wBAAwB;IAG5B,YACE,kBAAqC,EACrC,MAAc;QAEd,IAAI,CAAC,UAAU,GAAG,IAAI,qBAAqB,CAAC,kBAAkB,EAAE,MAAM,CAAC,CAAC;IAC1E,CAAC;IAEM,KAAK,CAAC,QAAQ,CAAC,MAAqB;QACzC,MAAM,SAAS,GAAG,MAAM,IAAI,CAAC,UAAU,CAAC,YAAY,EAAE,CAAC;QACvD,MAAM,KAAK,GAAG,SAAS,CAAC,GAAG,CAAC,MAAM,aAAN,MAAM,uBAAN,MAAM,CAAE,EAAE,CAAC,CAAC;QACxC,OAAO,KAAK,IAAI,EAAE,CAAC;IACrB,CAAC;IAEM,KAAK,CAAC,aAAa,CAAC,MAAqB;QAC9C,MAAM,SAAS,GAAG,MAAM,IAAI,CAAC,UAAU,CAAC,YAAY,EAAE,CAAC;QACvD,MAAM,KAAK,GAAG,SAAS,CAAC,GAAG,CAAC,MAAM,aAAN,MAAM,uBAAN,MAAM,CAAE,EAAE,CAAC,CAAC;QACxC,OAAO,CAAA,KAAK,aAAL,KAAK,uBAAL,KAAK,CAAE,MAAM,KAAI,CAAC,CAAC;IAC5B,CAAC;CACF","sourcesContent":["/*---------------------------------------------------------------------------------------------\r\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\r\n* See LICENSE.md in the project root for license terms and full copyright notice.\r\n*--------------------------------------------------------------------------------------------*/\r\nimport * as React from \"react\";\r\nimport { useResizeDetector } from \"react-resize-detector\";\r\nimport { IModelApp, ScreenViewport } from \"@itwin/core-frontend\";\r\nimport { PropertyValueFormat } from \"@itwin/appui-abstract\";\r\nimport { CheckBoxState, ImageCheckBox, NodeCheckboxRenderProps, useDisposable, WebFontIcon } from \"@itwin/core-react\";\r\nimport {\r\n AbstractTreeNodeLoaderWithProvider, ControlledTree, DelayLoadedTreeNodeItem, HighlightableTreeProps, ITreeDataProvider,\r\n MutableTreeModel,\r\n MutableTreeModelNode,\r\n SelectionMode, TreeCheckboxStateChangeEventArgs, TreeDataProvider, TreeEventHandler, TreeImageLoader, TreeModel, TreeModelChanges, TreeModelSource, TreeNodeItem, TreeNodeLoader,\r\n TreeNodeRenderer, TreeNodeRendererProps, TreeRenderer, TreeRendererProps, useTreeModel,\r\n} from \"@itwin/components-react\";\r\nimport { MapLayerSettings, MapSubLayerProps, MapSubLayerSettings } from \"@itwin/core-common\";\r\nimport { Input } from \"@itwin/itwinui-react\";\r\nimport { StyleMapLayerSettings } from \"../Interfaces\";\r\nimport { SubLayersDataProvider } from \"./SubLayersDataProvider\";\r\nimport { MapLayersUiItemsProvider } from \"../MapLayersUiItemsProvider\";\r\nimport \"./SubLayersTree.scss\";\r\n\r\ninterface ToolbarProps {\r\n searchField?: React.ReactNode;\r\n children?: React.ReactNode[];\r\n}\r\n\r\n// eslint-disable-next-line @typescript-eslint/naming-convention\r\nfunction Toolbar(props: ToolbarProps) {\r\n return (\r\n <div className=\"map-manager-sublayer-tree-toolbar\">\r\n <div className=\"tree-toolbar-action-buttons\">\r\n {props.children}\r\n </div>\r\n {props.searchField && <div className=\"tree-toolbar-searchbox\">\r\n {props.searchField}\r\n </div>}\r\n </div>\r\n );\r\n}\r\n\r\n// eslint-disable-next-line @typescript-eslint/naming-convention\r\nexport function SubLayersPanel({ mapLayer, viewport }: { mapLayer: StyleMapLayerSettings, viewport: ScreenViewport | undefined }) {\r\n const [noneAvailableLabel] = React.useState(MapLayersUiItemsProvider.localization.getLocalizedString(\"mapLayers:SubLayers.NoSubLayers\"));\r\n if (!viewport || (undefined === mapLayer.subLayers || 0 === mapLayer.subLayers.length)) {\r\n return <div className=\"map-manager-sublayer-panel\">\r\n <div>{noneAvailableLabel}</div>\r\n </div>;\r\n }\r\n\r\n return (\r\n <SubLayersTree mapLayer={mapLayer} />\r\n );\r\n}\r\n\r\nfunction getSubLayerProps(subLayerSettings: MapSubLayerSettings[]): MapSubLayerProps[] {\r\n return subLayerSettings.map((subLayer) => subLayer.toJSON());\r\n}\r\n\r\nfunction getStyleMapLayerSettings(settings: MapLayerSettings, isOverlay: boolean): StyleMapLayerSettings {\r\n return {\r\n visible: settings.visible,\r\n name: settings.name,\r\n url: settings.url,\r\n transparency: settings.transparency,\r\n transparentBackground: settings.transparentBackground,\r\n subLayers: settings.subLayers ? getSubLayerProps(settings.subLayers) : undefined,\r\n showSubLayers: true,\r\n isOverlay,\r\n provider: IModelApp.mapLayerFormatRegistry.createImageryProvider(settings),\r\n };\r\n}\r\n\r\n/**\r\n * Tree Control that displays sub-layer hierarchy\r\n * @internal\r\n */\r\n// eslint-disable-next-line @typescript-eslint/naming-convention\r\nexport function SubLayersTree(props: { mapLayer: StyleMapLayerSettings }) {\r\n const [placeholderLabel] = React.useState(MapLayersUiItemsProvider.localization.getLocalizedString(\"mapLayers:SubLayers.SearchPlaceholder\"));\r\n const [allOnLabel] = React.useState(MapLayersUiItemsProvider.localization.getLocalizedString(\"mapLayers:SubLayers.AllOn\"));\r\n const [allOffLabel] = React.useState(MapLayersUiItemsProvider.localization.getLocalizedString(\"mapLayers:SubLayers.AllOff\"));\r\n const [mapLayer, setMapLayer] = React.useState(props.mapLayer);\r\n const [layerFilterString, setLayerFilterString] = React.useState<string>(\"\");\r\n\r\n // create data provider to get some nodes to show in tree\r\n // `React.useMemo' is used avoid creating new object on each render cycle\r\n const dataProvider = React.useMemo(() => new SubLayersDataProvider(mapLayer), [mapLayer]);\r\n\r\n const {\r\n modelSource,\r\n nodeLoader,\r\n nodeHighlightingProps,\r\n } = useTreeFiltering(dataProvider, layerFilterString);\r\n\r\n // create custom event handler. It handles all tree event same as `TreeEventHandler` but additionally\r\n // it selects/deselects node when checkbox is checked/unchecked and vice versa.\r\n // `useDisposable` takes care of disposing old event handler when new is created in case 'nodeLoader' has changed\r\n // `React.useCallback` is used to avoid creating new callback that creates handler on each render\r\n const eventHandler = useDisposable(React.useCallback(() => new SubLayerCheckboxHandler(mapLayer, nodeLoader), [nodeLoader, mapLayer]));\r\n\r\n // Get an immutable tree model from the model source. The model is regenerated every time the model source\r\n // emits the `onModelChanged` event.\r\n const treeModel = useTreeModel(modelSource);\r\n\r\n const showAll = React.useCallback(async () => {\r\n const vp = IModelApp.viewManager.selectedView;\r\n const displayStyle = vp?.displayStyle;\r\n if (displayStyle && vp) {\r\n const indexInDisplayStyle = displayStyle ? displayStyle.findMapLayerIndexByNameAndUrl(mapLayer.name, mapLayer.url, mapLayer.isOverlay) : -1;\r\n displayStyle.changeMapSubLayerProps({ visible: true }, -1, indexInDisplayStyle, mapLayer.isOverlay);\r\n vp.invalidateRenderPlan();\r\n const updatedMapLayer = displayStyle.mapLayerAtIndex(indexInDisplayStyle, mapLayer.isOverlay);\r\n if (updatedMapLayer) {\r\n setMapLayer(getStyleMapLayerSettings(updatedMapLayer, mapLayer.isOverlay));\r\n }\r\n }\r\n }, [mapLayer]);\r\n\r\n const hideAll = React.useCallback(async () => {\r\n const vp = IModelApp.viewManager.selectedView;\r\n const displayStyle = vp?.displayStyle;\r\n if (displayStyle && vp) {\r\n const indexInDisplayStyle = displayStyle ? displayStyle.findMapLayerIndexByNameAndUrl(mapLayer.name, mapLayer.url, mapLayer.isOverlay) : -1;\r\n displayStyle.changeMapSubLayerProps({ visible: false }, -1, indexInDisplayStyle, mapLayer.isOverlay);\r\n const updatedMapLayer = displayStyle.mapLayerAtIndex(indexInDisplayStyle, mapLayer.isOverlay);\r\n if (updatedMapLayer) {\r\n setMapLayer(getStyleMapLayerSettings(updatedMapLayer, mapLayer.isOverlay));\r\n }\r\n vp.invalidateRenderPlan();\r\n }\r\n }, [mapLayer]);\r\n\r\n const handleFilterTextChanged = React.useCallback((event: React.ChangeEvent<HTMLInputElement>) => {\r\n setLayerFilterString(event.target.value);\r\n }, []);\r\n\r\n const { width, height, ref } = useResizeDetector();\r\n\r\n return <>\r\n <div className=\"map-manager-sublayer-tree\">\r\n <Toolbar\r\n searchField={\r\n <Input type=\"text\" className=\"map-manager-source-list-filter\"\r\n placeholder={placeholderLabel}\r\n value={layerFilterString}\r\n onChange={handleFilterTextChanged} />\r\n }\r\n >\r\n {mapLayer.provider?.mutualExclusiveSubLayer ? undefined : [\r\n <button key=\"show-all-btn\" title={allOnLabel} onClick={showAll}>\r\n <WebFontIcon iconName=\"icon-visibility\" />\r\n </button>,\r\n <button key=\"hide-all-btn\" title={allOffLabel} onClick={hideAll}>\r\n <WebFontIcon iconName=\"icon-visibility-hide-2\" />\r\n </button>,\r\n ]}\r\n </Toolbar>\r\n <div ref={ref} className=\"map-manager-sublayer-tree-content\">\r\n {width && height ? <ControlledTree\r\n nodeLoader={nodeLoader}\r\n selectionMode={SelectionMode.None}\r\n eventsHandler={eventHandler}\r\n model={treeModel}\r\n treeRenderer={nodeWithEyeCheckboxTreeRenderer}\r\n nodeHighlightingProps={nodeHighlightingProps}\r\n width={width}\r\n height={height}\r\n /> : null}\r\n </div>\r\n </div>\r\n </>;\r\n}\r\n\r\n/** TreeEventHandler derived class that handler processing changes to subLayer visibility */\r\nclass SubLayerCheckboxHandler extends TreeEventHandler {\r\n private _removeModelChangedListener: () => void;\r\n\r\n constructor(private _mapLayer: StyleMapLayerSettings, nodeLoader: AbstractTreeNodeLoaderWithProvider<TreeDataProvider>) {\r\n super({ modelSource: nodeLoader.modelSource, nodeLoader, collapsedChildrenDisposalEnabled: true });\r\n this._removeModelChangedListener = this.modelSource.onModelChanged.addListener(this.onModelChanged);\r\n }\r\n\r\n public override dispose() {\r\n this._removeModelChangedListener();\r\n super.dispose();\r\n }\r\n\r\n // Cascade state\r\n // Children on unnamed groups must get disabled in the tree view, because\r\n // they get rendered anyway.\r\n private cascadeStateToAllChildren(model: MutableTreeModel, parentId?: string) {\r\n const children = model.getChildren(parentId);\r\n if (children === undefined)\r\n return;\r\n\r\n for (const childID of children) {\r\n const childNode = childID ? model.getNode(childID) : undefined;\r\n\r\n if (childNode)\r\n this.syncNodeStateWithParent(model, childNode);\r\n\r\n // Drill down the tree.\r\n this.cascadeStateToAllChildren(model, childID);\r\n }\r\n }\r\n\r\n private applyMutualExclusiveState(model: MutableTreeModel, nodeId: string) {\r\n const changedNode = model.getNode(nodeId);\r\n if (changedNode?.checkbox.state === CheckBoxState.Off)\r\n return;\r\n\r\n for (const node of model.iterateTreeModelNodes()) {\r\n if (node.id === changedNode?.id)\r\n continue;\r\n\r\n if (node && node.checkbox.state === CheckBoxState.On)\r\n node.checkbox.state = CheckBoxState.Off;\r\n }\r\n }\r\n\r\n //-----------------------------------------------------------------------\r\n // Listen to model changes\r\n //------------------------------------------------------------------------\r\n // This is required because nodes are delay loaded in the model until\r\n // they are made visible (i.e. parent node is expanded). So even though\r\n // you might have created nodes in the data provided with a proper\r\n // initial state, by the time it gets loaded, their state might have became\r\n // out of date in the TreeView's active model. So whenever a node\r\n // is added, when must confirm its state matches the current model\r\n // (i.e. state of their parent.)\r\n public onModelChanged = (args: [TreeModel, TreeModelChanges]) => {\r\n this.modelSource.modifyModel((model) => {\r\n const addedNodes = args[1].addedNodeIds.map((id) => model.getNode(id));\r\n addedNodes.forEach((node) => {\r\n if (!node)\r\n return;\r\n\r\n this.syncNodeStateWithParent(model, node);\r\n });\r\n });\r\n };\r\n\r\n private static isUnnamedGroup(subLayer: MapSubLayerProps | undefined): boolean {\r\n if (!subLayer)\r\n return false;\r\n\r\n return (!subLayer.name || subLayer.name.length === 0) && (subLayer.children !== undefined && subLayer.children.length > 0);\r\n }\r\n\r\n // Ensure the state of changed node matches the state of its parent.\r\n private syncNodeStateWithParent(model: MutableTreeModel, changedNode: MutableTreeModelNode) {\r\n // Lookup node parent. If non exists, I assume thats the root node,\r\n // and it must have a proper initial state.\r\n const parentNode = changedNode.parentId ? model.getNode(changedNode.parentId) : undefined;\r\n if (!parentNode)\r\n return;\r\n\r\n if (!changedNode.checkbox)\r\n return; // don't see why this would happen, but if there is no checkbox, we cant do much here.\r\n\r\n const parentLayerId = undefined !== parentNode.item.extendedData?.subLayerId ? parentNode.item.extendedData?.subLayerId : parentNode.item.id;\r\n const parentSubLayer = this._mapLayer.subLayers?.find((subLayer) => subLayer.id === parentLayerId);\r\n\r\n // If parent is disabled, then children must be too.\r\n // Also, Non-visible unnamed group must have their children disabled (unamed groups have visibility inherence)\r\n if (parentNode.checkbox.isDisabled || (SubLayerCheckboxHandler.isUnnamedGroup(parentSubLayer) && parentNode.checkbox.state === CheckBoxState.Off)) {\r\n changedNode.checkbox.isDisabled = true;\r\n changedNode.checkbox.state = CheckBoxState.Off;\r\n } else {\r\n // Visibility state from StyleMapLayerSettings applies\r\n const subLayerId = undefined !== changedNode.item.extendedData?.subLayerId ? changedNode.item.extendedData?.subLayerId : changedNode.item.id;\r\n const foundSubLayer = this._mapLayer.subLayers?.find((subLayer) => subLayer.id === subLayerId);\r\n changedNode.checkbox.isDisabled = false;\r\n changedNode.checkbox.state = foundSubLayer?.visible ? CheckBoxState.On : CheckBoxState.Off;\r\n }\r\n }\r\n\r\n /** Changes nodes checkboxes states until event is handled or handler is disposed */\r\n public override onCheckboxStateChanged({ stateChanges }: TreeCheckboxStateChangeEventArgs) {\r\n // call base checkbox handling\r\n const baseHandling = super.onCheckboxStateChanged({ stateChanges });\r\n\r\n // subscribe to checkbox state changes to new checkbox states and do some additional work with them\r\n const selectionHandling = stateChanges.subscribe({\r\n next: (changes) => {\r\n const vp = IModelApp.viewManager.selectedView;\r\n const displayStyle = vp?.displayStyle;\r\n const indexInDisplayStyle = displayStyle ? displayStyle.findMapLayerIndexByNameAndUrl(this._mapLayer.name, this._mapLayer.url, this._mapLayer.isOverlay) : -1;\r\n changes.forEach((change) => {\r\n const isSelected = (change.newState === CheckBoxState.On);\r\n\r\n const subLayerId = undefined !== change.nodeItem.extendedData?.subLayerId ? change.nodeItem.extendedData?.subLayerId : change.nodeItem.id;\r\n\r\n // Get the previously visible node if any\r\n let prevVisibleLayer: MapSubLayerProps | undefined;\r\n if (this._mapLayer.provider?.mutualExclusiveSubLayer) {\r\n prevVisibleLayer = this._mapLayer.subLayers?.find((subLayer) => subLayer.visible && subLayer.id !== subLayerId);\r\n }\r\n\r\n // Update sublayer object, otherwise state would get out of sync with DisplayStyle each time the TreeView is re-rendered\r\n const foundSubLayer = this._mapLayer.subLayers?.find((subLayer) => subLayer.id === subLayerId);\r\n if (foundSubLayer)\r\n foundSubLayer.visible = isSelected;\r\n if (prevVisibleLayer?.visible)\r\n prevVisibleLayer.visible = false;\r\n\r\n // Update displaystyle state\r\n if (-1 !== indexInDisplayStyle && displayStyle) {\r\n if (prevVisibleLayer && prevVisibleLayer.id !== undefined)\r\n displayStyle.changeMapSubLayerProps({ visible: false }, prevVisibleLayer.id, indexInDisplayStyle, this._mapLayer.isOverlay);\r\n displayStyle.changeMapSubLayerProps({ visible: isSelected }, subLayerId, indexInDisplayStyle, this._mapLayer.isOverlay);\r\n }\r\n\r\n // Cascade state\r\n this.modelSource.modifyModel((model) => {\r\n if (this._mapLayer.provider?.mutualExclusiveSubLayer)\r\n this.applyMutualExclusiveState(model, change.nodeItem.id);\r\n this.cascadeStateToAllChildren(model, change.nodeItem.id);\r\n });\r\n });\r\n\r\n if (vp)\r\n vp.invalidateRenderPlan();\r\n },\r\n });\r\n // stop handling selection when checkboxes handling is stopped\r\n baseHandling?.add(selectionHandling);\r\n return baseHandling;\r\n }\r\n}\r\n\r\n/** Custom checkbox renderer that renders checkbox as an eye */\r\nconst eyeCheckboxRenderer = (props: NodeCheckboxRenderProps) => (\r\n <ImageCheckBox\r\n checked={props.checked}\r\n disabled={props.disabled}\r\n imageOn=\"icon-visibility\"\r\n imageOff=\"icon-visibility-hide-2\"\r\n onClick={props.onChange}\r\n tooltip={props.title}\r\n />\r\n);\r\n\r\n/** Custom node renderer. It uses default 'TreeNodeRenderer' but overrides default checkbox renderer to render checkbox as an eye */\r\nconst imageLoader = new TreeImageLoader();\r\nconst nodeWithEyeCheckboxRenderer = (props: TreeNodeRendererProps) => (\r\n <TreeNodeRenderer\r\n {...props}\r\n checkboxRenderer={eyeCheckboxRenderer}\r\n imageLoader={imageLoader}\r\n />\r\n);\r\n\r\n/** Custom tree renderer. It uses default `TreeRenderer` but overrides default node renderer to render node with custom checkbox */\r\nconst nodeWithEyeCheckboxTreeRenderer = (props: TreeRendererProps) => (\r\n <TreeRenderer\r\n {...props}\r\n nodeRenderer={nodeWithEyeCheckboxRenderer}\r\n />\r\n);\r\n\r\nfunction useTreeFiltering(\r\n dataProvider: ITreeDataProvider,\r\n filter: string,\r\n) {\r\n const nodeLoader = useFilteredProvider(dataProvider, filter);\r\n const nodeHighlightingProps = useNodeHighlightingProps(filter);\r\n return {\r\n nodeLoader,\r\n modelSource: nodeLoader.modelSource,\r\n nodeHighlightingProps,\r\n };\r\n}\r\n\r\nfunction useFilteredProvider(\r\n dataProvider: ITreeDataProvider,\r\n filter: string,\r\n) {\r\n const filteredProvider = React.useMemo(() => {\r\n return new FilteredTreeDataProvider(dataProvider, filter);\r\n }, [dataProvider, filter]);\r\n\r\n const nodeLoader = React.useMemo(() => {\r\n return new TreeNodeLoader(filteredProvider, new TreeModelSource());\r\n }, [filteredProvider]);\r\n\r\n return nodeLoader;\r\n}\r\n\r\nfunction useNodeHighlightingProps(\r\n filter: string,\r\n) {\r\n const [nodeHighlightingProps, setNodeHighlightingProps] = React.useState<HighlightableTreeProps>();\r\n\r\n React.useEffect(() => {\r\n if (filter === \"\") {\r\n setNodeHighlightingProps(undefined);\r\n return;\r\n }\r\n setNodeHighlightingProps({\r\n searchText: filter,\r\n activeMatch: undefined,\r\n });\r\n }, [filter]);\r\n\r\n return nodeHighlightingProps;\r\n}\r\n\r\nclass FullTreeHierarchy {\r\n private _dataProvider: ITreeDataProvider;\r\n private _hierarchy = new Map<string | undefined, DelayLoadedTreeNodeItem[]>();\r\n private _init: Promise<void>;\r\n\r\n public constructor(dataProvider: ITreeDataProvider) {\r\n this._dataProvider = dataProvider;\r\n\r\n this._init = (async () => {\r\n await this.initNode();\r\n })();\r\n }\r\n\r\n private async initNode(parent?: TreeNodeItem) {\r\n const nodes = await this._dataProvider.getNodes(parent);\r\n this._hierarchy.set(parent?.id, nodes);\r\n for (const node of nodes) {\r\n await this.initNode(node);\r\n }\r\n }\r\n\r\n public async getHierarchy() {\r\n await this._init;\r\n return this._hierarchy;\r\n }\r\n}\r\n\r\nclass FilteredTreeHierarchy {\r\n private _fullHierarchy: FullTreeHierarchy;\r\n private _filter: string;\r\n private _filtered = new Map<string | undefined, DelayLoadedTreeNodeItem[]>();\r\n private _init: Promise<void>;\r\n\r\n public constructor(dataProvider: ITreeDataProvider, filter: string) {\r\n this._fullHierarchy = new FullTreeHierarchy(dataProvider);\r\n this._filter = filter;\r\n\r\n this._init = (async () => {\r\n await this.init();\r\n })();\r\n }\r\n\r\n private async init() {\r\n const hierarchy = await this._fullHierarchy.getHierarchy();\r\n if (this._filter === \"\") {\r\n this._filtered = hierarchy;\r\n return;\r\n }\r\n this.filterNodes(hierarchy);\r\n }\r\n\r\n /** Initializes `this._filtered` field. Returns a node if it matches a filter. */\r\n private filterNodes(hierarchy: Map<string | undefined, DelayLoadedTreeNodeItem[]>, current?: DelayLoadedTreeNodeItem): DelayLoadedTreeNodeItem | undefined {\r\n const matches = current ? this.matchesFilter(current) : false;\r\n const children = hierarchy.get(current?.id);\r\n if (!children)\r\n return matches ? current : undefined;\r\n\r\n const matchedChildren = new Array<DelayLoadedTreeNodeItem>();\r\n for (const child of children) {\r\n const matchedChild = this.filterNodes(hierarchy, child);\r\n matchedChild && matchedChildren.push(matchedChild);\r\n }\r\n\r\n const hasChildren = matchedChildren.length > 0;\r\n const included = matches || hasChildren;\r\n let filtered: DelayLoadedTreeNodeItem | undefined;\r\n if (included) {\r\n this._filtered.set(current?.id, matchedChildren);\r\n\r\n // Return a modified copy of current node (to persist initial hierarchy when filter is cleared).\r\n if (current) {\r\n filtered = {\r\n ...current,\r\n hasChildren,\r\n autoExpand: hasChildren ? true : current.autoExpand,\r\n };\r\n }\r\n }\r\n return filtered;\r\n }\r\n\r\n private matchesFilter(node: TreeNodeItem) {\r\n if (node.label.value.valueFormat !== PropertyValueFormat.Primitive)\r\n return false;\r\n\r\n const value = node.label.value.displayValue?.toLowerCase();\r\n if (!value)\r\n return false;\r\n return value.includes(this._filter.toLowerCase());\r\n }\r\n\r\n public async getHierarchy() {\r\n await this._init;\r\n return this._filtered;\r\n }\r\n}\r\n\r\nclass FilteredTreeDataProvider implements ITreeDataProvider {\r\n private _hierarchy: FilteredTreeHierarchy;\r\n\r\n public constructor(\r\n parentDataProvider: ITreeDataProvider,\r\n filter: string,\r\n ) {\r\n this._hierarchy = new FilteredTreeHierarchy(parentDataProvider, filter);\r\n }\r\n\r\n public async getNodes(parent?: TreeNodeItem) {\r\n const hierarchy = await this._hierarchy.getHierarchy();\r\n const nodes = hierarchy.get(parent?.id);\r\n return nodes || [];\r\n }\r\n\r\n public async getNodesCount(parent?: TreeNodeItem) {\r\n const hierarchy = await this._hierarchy.getHierarchy();\r\n const nodes = hierarchy.get(parent?.id);\r\n return nodes?.length || 0;\r\n }\r\n}\r\n"]}
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* Copyright (c) Bentley Systems, Incorporated. All rights reserved.
|
|
3
3
|
* See LICENSE.md in the project root for license terms and full copyright notice.
|
|
4
4
|
*--------------------------------------------------------------------------------------------*/
|
|
5
|
-
@import "~@itwin/core-react/lib/core-react/index";
|
|
5
|
+
@import "~@itwin/core-react/lib/cjs/core-react/index";
|
|
6
6
|
|
|
7
7
|
.map-manager-sublayer-tree {
|
|
8
8
|
height: 100%;
|
|
File without changes
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"TransparencyPopupButton.d.ts","sourceRoot":"","sources":["../../../../src/ui/widget/TransparencyPopupButton.tsx"],"names":[],"mappings":";AAWA,OAAO,gCAAgC,CAAC;AAExC,aAAa;AACb,MAAM,WAAW,4BAA4B;IAC3C,6BAA6B;IAC7B,YAAY,EAAE,MAAM,CAAC;IACrB,mEAAmE;IACnE,oBAAoB,CAAC,KAAK,EAAE,MAAM,GAAG,IAAI,CAAC;IAC1C,uBAAuB;IACvB,aAAa,CAAC,EAAE,MAAM,CAAC;CACxB;AAED,aAAa;AAEb,wBAAgB,uBAAuB,CAAC,EAAE,YAAY,EAAE,oBAAoB,EAAE,aAAa,EAAE,EAAE,4BAA4B,eAgD1H"}
|
|
File without changes
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"TransparencyPopupButton.js","sourceRoot":"","sources":["../../../../src/ui/widget/TransparencyPopupButton.tsx"],"names":[],"mappings":";AAAA;;;+FAG+F;;;AAE/F,+BAA+B;AAC/B,0DAAyD;AACzD,kDAA0C;AAC1C,wDAA8C;AAE9C,0EAAuE;AACvE,0CAAwC;AAYxC,aAAa;AACb,gEAAgE;AAChE,SAAgB,uBAAuB,CAAC,EAAE,YAAY,EAAE,oBAAoB,EAAE,aAAa,EAAgC;IACzH,MAAM,CAAC,cAAc,EAAE,iBAAiB,CAAC,GAAG,KAAK,CAAC,QAAQ,CAAC,KAAK,CAAC,CAAC;IAClE,MAAM,CAAC,wBAAwB,CAAC,GAAG,KAAK,CAAC,QAAQ,CAAC,mDAAwB,CAAC,YAAY,CAAC,kBAAkB,CAAC,6CAA6C,CAAC,CAAC,CAAC;IAC3J,MAAM,YAAY,GAAG,KAAK,CAAC,OAAO,CAAC,GAAG,EAAE,CAAC,aAAa,CAAC,CAAC,CAAC,aAAa,CAAC,CAAC,CAAC,wBAAwB,EAAE,CAAC,aAAa,EAAE,wBAAwB,CAAC,CAAC,CAAC;IAE9I,MAAM,SAAS,GAAG,KAAK,CAAC,MAAM,CAAoB,IAAI,CAAC,CAAC;IACxD,MAAM,kBAAkB,GAAG,KAAK,CAAC,WAAW,CAAC,CAAC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G,EAAE,GAAG,EAAE,MAAM,EAAE,CAAC,YAAY,GAAG,GAAG,CAAC,EAAE,IAAI,EAAE,CAAC,EAAE,QAAQ,EAAE,wBAAwB,GAAI,CACnG,CACF,CACC,CACP,CACL,CAAC;AACJ,CAAC;AAhDD,0DAgDC","sourcesContent":["/*---------------------------------------------------------------------------------------------\r\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\r\n* See LICENSE.md in the project root for license terms and full copyright notice.\r\n*--------------------------------------------------------------------------------------------*/\r\n\r\nimport * as React from \"react\";\r\nimport { RelativePosition } from \"@itwin/appui-abstract\";\r\nimport { Popup } from \"@itwin/core-react\";\r\nimport { Slider } from \"@itwin/itwinui-react\";\r\n\r\nimport { MapLayersUiItemsProvider } from \"../MapLayersUiItemsProvider\";\r\nimport \"./TransparencyPopupButton.scss\";\r\n\r\n/** @alpha */\r\nexport interface TransparencyPopupButtonProps {\r\n /** initialValue range 0-1 */\r\n transparency: number;\r\n /** function called when value changes. Returned value range 0-1 */\r\n onTransparencyChange(value: number): void;\r\n /** optional tooltip */\r\n buttonToolTip?: string;\r\n}\r\n\r\n/** @alpha */\r\n// eslint-disable-next-line @typescript-eslint/naming-convention\r\nexport function TransparencyPopupButton({ transparency, onTransparencyChange, buttonToolTip }: TransparencyPopupButtonProps) {\r\n const [isSettingsOpen, setIsSettingsOpen] = React.useState(false);\r\n const [defaultTransparencyLabel] = React.useState(MapLayersUiItemsProvider.localization.getLocalizedString(\"mapLayers:TransparencyPopup.SetTransparency\"));\r\n const toolTipLabel = React.useMemo(() => buttonToolTip ? buttonToolTip : defaultTransparencyLabel, [buttonToolTip, defaultTransparencyLabel]);\r\n\r\n const buttonRef = React.useRef<HTMLButtonElement>(null);\r\n const togglePopupDisplay = React.useCallback((event: React.MouseEvent<HTMLButtonElement, MouseEvent>) => {\r\n event.preventDefault();\r\n setIsSettingsOpen((prev) => !prev);\r\n }, [setIsSettingsOpen]);\r\n\r\n const handleCloseSetting = React.useCallback(() => {\r\n setIsSettingsOpen(false);\r\n }, [setIsSettingsOpen]);\r\n\r\n const handleTransparencyChange = React.useCallback((values: readonly number[]) => {\r\n if (values.length) {\r\n const newTransparency = values[0];\r\n if (newTransparency !== transparency) {\r\n if (onTransparencyChange)\r\n onTransparencyChange(newTransparency / 100);\r\n }\r\n }\r\n }, [onTransparencyChange, transparency]);\r\n\r\n return (\r\n <>\r\n <button title={toolTipLabel} className=\"map-transparency-popup-button\" onClick={togglePopupDisplay} ref={buttonRef}>\r\n <div className=\"transparent-button\">\r\n <svg className=\"checkered\" viewBox=\"0 0 24 24\">\r\n <path d=\"m21.00427 0h-18.00854a2.9957 2.9957 0 0 0 -2.99573 2.99567v18.0086a2.99575 2.99575 0 0 0 2.99573 2.99573h18.00854a2.99575 2.99575 0 0 0 2.99573-2.99573v-18.0086a2.9957 2.9957 0 0 0 -2.99573-2.99567zm-20.00427 21.00427v-9.00427h11v-11h9.00427a1.998 1.998 0 0 1 1.99573 1.99567v9.00433h-11v11h-9.00427a1.998 1.998 0 0 1 -1.99573-1.99573z\" />\r\n </svg>\r\n </div>\r\n </button>\r\n <Popup\r\n isOpen={isSettingsOpen}\r\n position={RelativePosition.BottomRight}\r\n onClose={handleCloseSetting}\r\n target={buttonRef.current}\r\n >\r\n <div className=\"map-transparency-popup-panel\">\r\n <div className=\"map-transparency-slider-container\">\r\n <Slider min={0} max={100} values={[transparency * 100]} step={1} onChange={handleTransparencyChange} />\r\n </div>\r\n </div>\r\n </Popup >\r\n </ >\r\n );\r\n}\r\n"]}
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* Copyright (c) Bentley Systems, Incorporated. All rights reserved.
|
|
3
3
|
* See LICENSE.md in the project root for license terms and full copyright notice.
|
|
4
4
|
*--------------------------------------------------------------------------------------------*/
|
|
5
|
-
@import "~@itwin/core-react/lib/core-react/index";
|
|
5
|
+
@import "~@itwin/core-react/lib/cjs/core-react/index";
|
|
6
6
|
@import "~@itwin/itwinui-css/scss/style/typography";
|
|
7
7
|
|
|
8
8
|
.map-transparency-popup-panel {
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"map-layers.d.ts","sourceRoot":"","sources":["../../src/map-layers.ts"],"names":[],"mappings":"AAIA,cAAc,aAAa,CAAC;AAC5B,cAAc,iBAAiB,CAAC;AAChC,cAAc,+BAA+B,CAAC;AAC9C,cAAc,6BAA6B,CAAC"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/*---------------------------------------------------------------------------------------------
|
|
2
|
+
* Copyright (c) Bentley Systems, Incorporated. All rights reserved.
|
|
3
|
+
* See LICENSE.md in the project root for license terms and full copyright notice.
|
|
4
|
+
*--------------------------------------------------------------------------------------------*/
|
|
5
|
+
export * from "./mapLayers";
|
|
6
|
+
export * from "./ui/Interfaces";
|
|
7
|
+
export * from "./ui/MapLayersUiItemsProvider";
|
|
8
|
+
export * from "./ui/widget/MapLayersWidget";
|
|
9
|
+
//# sourceMappingURL=map-layers.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"map-layers.js","sourceRoot":"","sources":["../../src/map-layers.ts"],"names":[],"mappings":"AAAA;;;+FAG+F;AAC/F,cAAc,aAAa,CAAC;AAC5B,cAAc,iBAAiB,CAAC;AAChC,cAAc,+BAA+B,CAAC;AAC9C,cAAc,6BAA6B,CAAC","sourcesContent":["/*---------------------------------------------------------------------------------------------\r\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\r\n* See LICENSE.md in the project root for license terms and full copyright notice.\r\n*--------------------------------------------------------------------------------------------*/\r\nexport * from \"./mapLayers\";\r\nexport * from \"./ui/Interfaces\";\r\nexport * from \"./ui/MapLayersUiItemsProvider\";\r\nexport * from \"./ui/widget/MapLayersWidget\";\r\n"]}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { Localization } from "@itwin/core-common";
|
|
2
|
+
/**
|
|
3
|
+
* MapLayersApi is use when the package is used as a dependency to another app and not used as an extension.
|
|
4
|
+
* '''ts
|
|
5
|
+
* // if registerItemsProvider is false the MapLayersWidgetControl control will be registered with appui-react's ConfigurableUiManager
|
|
6
|
+
* // so it can be explicitly added to a stage via a FrontstageDef.
|
|
7
|
+
* await MapLayersUI.initialize (registerItemsProvider);
|
|
8
|
+
* '''
|
|
9
|
+
* @beta
|
|
10
|
+
*/
|
|
11
|
+
export declare class MapLayersUI {
|
|
12
|
+
private static _localization?;
|
|
13
|
+
private static _defaultNs;
|
|
14
|
+
private static _uiItemsProvider;
|
|
15
|
+
/** Used to initialize the MapLayersAPI when used as a package. If `registerItemsProvider` is true then the
|
|
16
|
+
* UiItemsProvider will automatically insert the UI items into the host applications UI. If it is false then
|
|
17
|
+
* explicitly add widget definition to a specific FrontStage definition using the following syntax.
|
|
18
|
+
* ``` tsx
|
|
19
|
+
* <Widget id={MapLayersWidgetControl.id} label={MapLayersWidgetControl.label} control={MapLayersWidgetControl}
|
|
20
|
+
* iconSpec={MapLayersWidgetControl.iconSpec} />,
|
|
21
|
+
* ```
|
|
22
|
+
*/
|
|
23
|
+
static initialize(registerItemsProvider?: boolean, localization?: Localization): Promise<void>;
|
|
24
|
+
/** Unregisters the GeoTools internationalization service namespace */
|
|
25
|
+
static terminate(): void;
|
|
26
|
+
/** The internationalization service namespace. */
|
|
27
|
+
static get localizationNamespace(): string;
|
|
28
|
+
}
|
|
29
|
+
//# sourceMappingURL=mapLayers.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"mapLayers.d.ts","sourceRoot":"","sources":["../../src/mapLayers.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAKlD;;;;;;;;GAQG;AACH,qBAAa,WAAW;IACtB,OAAO,CAAC,MAAM,CAAC,aAAa,CAAC,CAAe;IAC5C,OAAO,CAAC,MAAM,CAAC,UAAU,CAAe;IACxC,OAAO,CAAC,MAAM,CAAC,gBAAgB,CAA2B;IAE1D;;;;;;;OAOG;WACiB,UAAU,CAAC,qBAAqB,UAAO,EAAE,YAAY,CAAC,EAAE,YAAY,GAAG,OAAO,CAAC,IAAI,CAAC;IAaxG,sEAAsE;WACxD,SAAS;IAMvB,kDAAkD;IAClD,WAAkB,qBAAqB,IAAI,MAAM,CAEhD;CACF"}
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
/*---------------------------------------------------------------------------------------------
|
|
2
|
+
* Copyright (c) Bentley Systems, Incorporated. All rights reserved.
|
|
3
|
+
* See LICENSE.md in the project root for license terms and full copyright notice.
|
|
4
|
+
*--------------------------------------------------------------------------------------------*/
|
|
5
|
+
import { IModelApp } from "@itwin/core-frontend";
|
|
6
|
+
import { MapLayersUiItemsProvider, MapLayersWidgetControl } from "./ui/MapLayersUiItemsProvider";
|
|
7
|
+
import { UiItemsManager } from "@itwin/appui-abstract";
|
|
8
|
+
import { ConfigurableUiManager } from "@itwin/appui-react";
|
|
9
|
+
/**
|
|
10
|
+
* MapLayersApi is use when the package is used as a dependency to another app and not used as an extension.
|
|
11
|
+
* '''ts
|
|
12
|
+
* // if registerItemsProvider is false the MapLayersWidgetControl control will be registered with appui-react's ConfigurableUiManager
|
|
13
|
+
* // so it can be explicitly added to a stage via a FrontstageDef.
|
|
14
|
+
* await MapLayersUI.initialize (registerItemsProvider);
|
|
15
|
+
* '''
|
|
16
|
+
* @beta
|
|
17
|
+
*/
|
|
18
|
+
export class MapLayersUI {
|
|
19
|
+
/** Used to initialize the MapLayersAPI when used as a package. If `registerItemsProvider` is true then the
|
|
20
|
+
* UiItemsProvider will automatically insert the UI items into the host applications UI. If it is false then
|
|
21
|
+
* explicitly add widget definition to a specific FrontStage definition using the following syntax.
|
|
22
|
+
* ``` tsx
|
|
23
|
+
* <Widget id={MapLayersWidgetControl.id} label={MapLayersWidgetControl.label} control={MapLayersWidgetControl}
|
|
24
|
+
* iconSpec={MapLayersWidgetControl.iconSpec} />,
|
|
25
|
+
* ```
|
|
26
|
+
*/
|
|
27
|
+
static async initialize(registerItemsProvider = true, localization) {
|
|
28
|
+
// register namespace containing localized strings for this package
|
|
29
|
+
this._localization = (localization ? localization : IModelApp.localization);
|
|
30
|
+
await this._localization.registerNamespace(this.localizationNamespace);
|
|
31
|
+
// _uiItemsProvider always created to provide access to localization.
|
|
32
|
+
MapLayersUI._uiItemsProvider = new MapLayersUiItemsProvider(this._localization);
|
|
33
|
+
if (registerItemsProvider)
|
|
34
|
+
UiItemsManager.register(MapLayersUI._uiItemsProvider);
|
|
35
|
+
else
|
|
36
|
+
ConfigurableUiManager.registerControl(MapLayersWidgetControl.id, MapLayersWidgetControl);
|
|
37
|
+
}
|
|
38
|
+
/** Unregisters the GeoTools internationalization service namespace */
|
|
39
|
+
static terminate() {
|
|
40
|
+
if (MapLayersUI._localization)
|
|
41
|
+
MapLayersUI._localization.unregisterNamespace(this.localizationNamespace);
|
|
42
|
+
MapLayersUI._localization = undefined;
|
|
43
|
+
}
|
|
44
|
+
/** The internationalization service namespace. */
|
|
45
|
+
static get localizationNamespace() {
|
|
46
|
+
return this._defaultNs;
|
|
47
|
+
}
|
|
48
|
+
}
|
|
49
|
+
MapLayersUI._defaultNs = "mapLayers";
|
|
50
|
+
//# sourceMappingURL=mapLayers.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"mapLayers.js","sourceRoot":"","sources":["../../src/mapLayers.ts"],"names":[],"mappings":"AAAA;;;+FAG+F;AAC/F,OAAO,EAAE,SAAS,EAAE,MAAM,sBAAsB,CAAC;AAEjD,OAAO,EAAE,wBAAwB,EAAE,sBAAsB,EAAE,MAAM,+BAA+B,CAAC;AACjG,OAAO,EAAE,cAAc,EAAE,MAAM,uBAAuB,CAAC;AACvD,OAAO,EAAE,qBAAqB,EAAE,MAAM,oBAAoB,CAAC;AAE3D;;;;;;;;GAQG;AACH,MAAM,OAAO,WAAW;IAKtB;;;;;;;OAOG;IACI,MAAM,CAAC,KAAK,CAAC,UAAU,CAAC,qBAAqB,GAAG,IAAI,EAAE,YAA2B;QACtF,mEAAmE;QACnE,IAAI,CAAC,aAAa,GAAG,CAAC,YAAY,CAAC,CAAC,CAAC,YAAY,CAAC,CAAC,CAAC,SAAS,CAAC,YAAY,CAAC,CAAC;QAC5E,MAAM,IAAI,CAAC,aAAa,CAAC,iBAAiB,CAAC,IAAI,CAAC,qBAAqB,CAAC,CAAC;QAEvE,qEAAqE;QACrE,WAAW,CAAC,gBAAgB,GAAG,IAAI,wBAAwB,CAAC,IAAI,CAAC,aAAa,CAAC,CAAC;QAChF,IAAI,qBAAqB;YACvB,cAAc,CAAC,QAAQ,CAAC,WAAW,CAAC,gBAAgB,CAAC,CAAC;;YAEtD,qBAAqB,CAAC,eAAe,CAAC,sBAAsB,CAAC,EAAE,EAAE,sBAAsB,CAAC,CAAC;IAC7F,CAAC;IAED,sEAAsE;IAC/D,MAAM,CAAC,SAAS;QACrB,IAAI,WAAW,CAAC,aAAa;YAC3B,WAAW,CAAC,aAAa,CAAC,mBAAmB,CAAC,IAAI,CAAC,qBAAqB,CAAC,CAAC;QAC5E,WAAW,CAAC,aAAa,GAAG,SAAS,CAAC;IACxC,CAAC;IAED,kDAAkD;IAC3C,MAAM,KAAK,qBAAqB;QACrC,OAAO,IAAI,CAAC,UAAU,CAAC;IACzB,CAAC;;AAlCc,sBAAU,GAAG,WAAW,CAAC","sourcesContent":["/*---------------------------------------------------------------------------------------------\r\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\r\n* See LICENSE.md in the project root for license terms and full copyright notice.\r\n*--------------------------------------------------------------------------------------------*/\r\nimport { IModelApp } from \"@itwin/core-frontend\";\r\nimport { Localization } from \"@itwin/core-common\";\r\nimport { MapLayersUiItemsProvider, MapLayersWidgetControl } from \"./ui/MapLayersUiItemsProvider\";\r\nimport { UiItemsManager } from \"@itwin/appui-abstract\";\r\nimport { ConfigurableUiManager } from \"@itwin/appui-react\";\r\n\r\n/**\r\n * MapLayersApi is use when the package is used as a dependency to another app and not used as an extension.\r\n * '''ts\r\n * // if registerItemsProvider is false the MapLayersWidgetControl control will be registered with appui-react's ConfigurableUiManager\r\n * // so it can be explicitly added to a stage via a FrontstageDef.\r\n * await MapLayersUI.initialize (registerItemsProvider);\r\n * '''\r\n * @beta\r\n */\r\nexport class MapLayersUI {\r\n private static _localization?: Localization;\r\n private static _defaultNs = \"mapLayers\";\r\n private static _uiItemsProvider: MapLayersUiItemsProvider;\r\n\r\n /** Used to initialize the MapLayersAPI when used as a package. If `registerItemsProvider` is true then the\r\n * UiItemsProvider will automatically insert the UI items into the host applications UI. If it is false then\r\n * explicitly add widget definition to a specific FrontStage definition using the following syntax.\r\n * ``` tsx\r\n * <Widget id={MapLayersWidgetControl.id} label={MapLayersWidgetControl.label} control={MapLayersWidgetControl}\r\n * iconSpec={MapLayersWidgetControl.iconSpec} />,\r\n * ```\r\n */\r\n public static async initialize(registerItemsProvider = true, localization?: Localization): Promise<void> {\r\n // register namespace containing localized strings for this package\r\n this._localization = (localization ? localization : IModelApp.localization);\r\n await this._localization.registerNamespace(this.localizationNamespace);\r\n\r\n // _uiItemsProvider always created to provide access to localization.\r\n MapLayersUI._uiItemsProvider = new MapLayersUiItemsProvider(this._localization);\r\n if (registerItemsProvider)\r\n UiItemsManager.register(MapLayersUI._uiItemsProvider);\r\n else\r\n ConfigurableUiManager.registerControl(MapLayersWidgetControl.id, MapLayersWidgetControl);\r\n }\r\n\r\n /** Unregisters the GeoTools internationalization service namespace */\r\n public static terminate() {\r\n if (MapLayersUI._localization)\r\n MapLayersUI._localization.unregisterNamespace(this.localizationNamespace);\r\n MapLayersUI._localization = undefined;\r\n }\r\n\r\n /** The internationalization service namespace. */\r\n public static get localizationNamespace(): string {\r\n return this._defaultNs;\r\n }\r\n}\r\n"]}
|
|
@@ -0,0 +1,113 @@
|
|
|
1
|
+
{
|
|
2
|
+
"AttachLayerPopup": {
|
|
3
|
+
"Attach": "Attach map layer",
|
|
4
|
+
"Close": "Close source map layers pop-up"
|
|
5
|
+
},
|
|
6
|
+
"Basemap": {
|
|
7
|
+
"BaseLayer": "Base:",
|
|
8
|
+
"BaseMapPanelTitle": "Map Layers",
|
|
9
|
+
"ColorFill": "Solid Fill Color",
|
|
10
|
+
"SelectBaseMap": "Select Map for base layer"
|
|
11
|
+
},
|
|
12
|
+
"ColorDialog": {
|
|
13
|
+
"Title": "Specify Base Color"
|
|
14
|
+
},
|
|
15
|
+
"CustomAttach": {
|
|
16
|
+
"LayerWithUrlExistsOverwriting": "Map layer with URL: {{url}} already exists. Updating name from {{oldName}} to {{newName}}.",
|
|
17
|
+
"LayerWithUrlExistsAsITwinSetting": "Map Layer with URL: {{url}} already exists as a iTwin setting under name {{name}}. Cannot overwrite with a model setting!",
|
|
18
|
+
"LayerExistsOverwriting": "Map layer {{layer}} already exists, overwriting info for that layer.",
|
|
19
|
+
"LayerExistsAsITwinSetting": "Map layer {{layer}} already exists as a iTwin setting. Cannot overwrite with a model setting!",
|
|
20
|
+
"AddCustomLayerButtonLabel": "Add Layer",
|
|
21
|
+
"AttachCustomLayer": "Attach New Layer",
|
|
22
|
+
"AttacheInfo": "Map layer attached from URL:",
|
|
23
|
+
"Custom": "New",
|
|
24
|
+
"LoadingMapSources": "Loading Map Sources",
|
|
25
|
+
"EditCustomLayer": "Edit Layer",
|
|
26
|
+
"EditLayerDefButtonTitle": "Edit Layer Definition",
|
|
27
|
+
"ErrorLoadingLayers": "Error retrieving map layers stored in the settings service",
|
|
28
|
+
"ErrorRetrieveUserModel": "Could not get saved Map Layers for user by model: {{errorMessage}}",
|
|
29
|
+
"ErrorRetrieveUserITwin": "Could not get saved Map Layers for user by iTwin: {{errorMessage}}",
|
|
30
|
+
"ErrorRetrieveSharedModel": "Could not get shared Map Layers by model: {{errorMessage}}",
|
|
31
|
+
"ErrorRetrieveSharedITwin": "Could not get shared Map Layers by iTwin: {{errorMessage}}",
|
|
32
|
+
"InvalidCredentials": "Invalid credentials provided",
|
|
33
|
+
"MissingCredentials": "This layer requires credentials to be provided",
|
|
34
|
+
"Name": "Name",
|
|
35
|
+
"NameInputPlaceHolder": "Enter Map Name",
|
|
36
|
+
"RemoveLayerDefButtonTitle": "Delete layer definition",
|
|
37
|
+
"RemoveLayerDefDialogMessage": "Are you sure you want to delete {{layerName}} ?",
|
|
38
|
+
"RemoveLayerDefDialogTitle": "Delete layer definition",
|
|
39
|
+
"RemoveLayerDefError": "Could not delete map layer definition: {{layerName}}",
|
|
40
|
+
"RemoveLayerDefSuccess": "Successfully deleted map layer definition: {{layerName}}",
|
|
41
|
+
"SearchPlaceholder": "Search...",
|
|
42
|
+
"StoreOnModelSettings": "Store on Model Settings",
|
|
43
|
+
"StoreOnITwinSettings": "Store on iTwin Settings",
|
|
44
|
+
"Type": "Type",
|
|
45
|
+
"URL": "URL",
|
|
46
|
+
"UrlInputPlaceHolder": "Enter Map Source URL",
|
|
47
|
+
"ValidationError": "Map layer validation failed for URL:",
|
|
48
|
+
"NoSaveSettingsWarning": "Layer settings cannot saved in the actual configuration"
|
|
49
|
+
},
|
|
50
|
+
"AuthenticationInputs": {
|
|
51
|
+
"Password": "Password",
|
|
52
|
+
"PasswordRequired": "Password required",
|
|
53
|
+
"Username": "Username",
|
|
54
|
+
"UsernameRequired": "Username required"
|
|
55
|
+
},
|
|
56
|
+
"Messages": {
|
|
57
|
+
"NotSupported": "No active viewport or geo-located iModel available.",
|
|
58
|
+
"NoRangeDefined": "No range is defined for Map Layer",
|
|
59
|
+
"Start": "Map Layers Extension Loaded",
|
|
60
|
+
"MapLayerAttached": "Map layer {{sourceName}} attached from URL: {{sourceUrl}}",
|
|
61
|
+
"MapLayerAttachedRequiresAuth": "Map layer {{sourceName}} attached, but requires credentials to be provided",
|
|
62
|
+
"MapLayerAttachError": "Error '{{error}}' occurred attaching MapLayer from URL: {{sourceUrl}}",
|
|
63
|
+
"MapLayerEditError": "Failed to edit '{{layerName}}'",
|
|
64
|
+
"MapLayerLayerSettingsConversionError": "Conversion to layer settings failed",
|
|
65
|
+
"MapLayerLayerSourceCreationFailed": "Map Layer Source creation failed",
|
|
66
|
+
"MapLayerValidationFailed": "Map layer validation failed for URL: {{sourceUrl}}"
|
|
67
|
+
},
|
|
68
|
+
"Widget": {
|
|
69
|
+
"BackgroundLayers": "Background",
|
|
70
|
+
"DropLayerLabel": "Drop layer here",
|
|
71
|
+
"Label": "Map Layers",
|
|
72
|
+
"NoOverlayLayers": "No Overlay layers specified",
|
|
73
|
+
"NoBackgroundLayers": "No Background layers specified",
|
|
74
|
+
"OverlayLayers": "Overlay",
|
|
75
|
+
"RequireAuthTooltip": "Authentication required",
|
|
76
|
+
"ToggleVisibility": "Toggle Visibility",
|
|
77
|
+
"SettingsButtonTooltip": "Settings"
|
|
78
|
+
},
|
|
79
|
+
"LayerMenu": {
|
|
80
|
+
"Detach": "Detach",
|
|
81
|
+
"ZoomToLayer": "Zoom to layer"
|
|
82
|
+
},
|
|
83
|
+
"Settings": {
|
|
84
|
+
"ElevationOffset": "Elevation Offset (m)",
|
|
85
|
+
"ElevationTypeGeodetic": "None",
|
|
86
|
+
"ElevationTypeGeoid": "Geoid Separation",
|
|
87
|
+
"ElevationTypeGround": "Terrain Elevation",
|
|
88
|
+
"Enable": "Enable",
|
|
89
|
+
"Exaggeration": "Exaggeration",
|
|
90
|
+
"HeightOrigin": "Apply Elevation Correction",
|
|
91
|
+
"InvalidElevationError": "Invalid Elevation",
|
|
92
|
+
"InvalidElevationDetails": "Please enter a valid number for elevation.",
|
|
93
|
+
"Mask": "Mask by Models",
|
|
94
|
+
"ModelHeight": "Model Height (m)",
|
|
95
|
+
"Settings": "Settings",
|
|
96
|
+
"ShowMapLayers": "Show Map Layers",
|
|
97
|
+
"Terrain": "Terrain",
|
|
98
|
+
"Transparency": "Transparency",
|
|
99
|
+
"UseDepthBuffer": "Allow Model Under Map",
|
|
100
|
+
"Locatable": "Locatable"
|
|
101
|
+
},
|
|
102
|
+
"SubLayers": {
|
|
103
|
+
"AllOn": "Turn on all Sub-layers",
|
|
104
|
+
"AllOff": "Turn off all Sub-layers",
|
|
105
|
+
"Hide": "Hide Sub-layers",
|
|
106
|
+
"NoSubLayers": "No Sub-layers Available",
|
|
107
|
+
"SearchPlaceholder": "Search...",
|
|
108
|
+
"Show": "Show Sub-layers"
|
|
109
|
+
},
|
|
110
|
+
"TransparencyPopup": {
|
|
111
|
+
"SetTransparency": "Set transparency"
|
|
112
|
+
}
|
|
113
|
+
}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import { MapSubLayerProps } from "@itwin/core-common";
|
|
2
|
+
import { MapLayerImageryProvider } from "@itwin/core-frontend";
|
|
3
|
+
export interface StyleMapLayerSettings {
|
|
4
|
+
/** Name */
|
|
5
|
+
name: string;
|
|
6
|
+
/** URL */
|
|
7
|
+
url: string;
|
|
8
|
+
/** Controls visibility of layer */
|
|
9
|
+
visible: boolean;
|
|
10
|
+
/** A transparency value from 0.0 (fully opaque) to 1.0 (fully transparent) to apply to map graphics when drawing, or false to indicate the transparency should not be overridden. Default value: false. */
|
|
11
|
+
transparency: number;
|
|
12
|
+
/** Transparent background */
|
|
13
|
+
transparentBackground: boolean;
|
|
14
|
+
/** set map as underlay or overlay */
|
|
15
|
+
isOverlay: boolean;
|
|
16
|
+
/** Available map sub-layer */
|
|
17
|
+
subLayers?: MapSubLayerProps[];
|
|
18
|
+
/** sub-layer panel displayed. */
|
|
19
|
+
showSubLayers: boolean;
|
|
20
|
+
/** Some format can publish only a single layer at a time (i.e WMTS) */
|
|
21
|
+
provider?: MapLayerImageryProvider;
|
|
22
|
+
}
|
|
23
|
+
export interface MapTypesOptions {
|
|
24
|
+
readonly supportTileUrl: boolean;
|
|
25
|
+
readonly supportWmsAuthentication: boolean;
|
|
26
|
+
}
|
|
27
|
+
export interface MapLayerOptions {
|
|
28
|
+
hideExternalMapLayers?: boolean;
|
|
29
|
+
fetchPublicMapLayerSources?: boolean;
|
|
30
|
+
mapTypeOptions?: MapTypesOptions;
|
|
31
|
+
}
|
|
32
|
+
//# sourceMappingURL=Interfaces.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Interfaces.d.ts","sourceRoot":"","sources":["../../../src/ui/Interfaces.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAC;AACtD,OAAO,EAAE,uBAAuB,EAAE,MAAM,sBAAsB,CAAC;AAE/D,MAAM,WAAW,qBAAqB;IACpC,WAAW;IACX,IAAI,EAAE,MAAM,CAAC;IACb,UAAU;IACV,GAAG,EAAE,MAAM,CAAC;IACZ,mCAAmC;IACnC,OAAO,EAAE,OAAO,CAAC;IACjB,2MAA2M;IAC3M,YAAY,EAAE,MAAM,CAAC;IACrB,6BAA6B;IAC7B,qBAAqB,EAAE,OAAO,CAAC;IAC/B,qCAAqC;IACrC,SAAS,EAAE,OAAO,CAAC;IACnB,8BAA8B;IAC9B,SAAS,CAAC,EAAE,gBAAgB,EAAE,CAAC;IAC/B,iCAAiC;IACjC,aAAa,EAAE,OAAO,CAAC;IACvB,uEAAuE;IACvE,QAAQ,CAAC,EAAE,uBAAuB,CAAC;CACpC;AAED,MAAM,WAAW,eAAe;IAC9B,QAAQ,CAAC,cAAc,EAAE,OAAO,CAAC;IACjC,QAAQ,CAAC,wBAAwB,EAAE,OAAO,CAAC;CAC5C;AAED,MAAM,WAAW,eAAe;IAC9B,qBAAqB,CAAC,EAAE,OAAO,CAAC;IAChC,0BAA0B,CAAC,EAAE,OAAO,CAAC;IACrC,cAAc,CAAC,EAAE,eAAe,CAAC;CAClC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Interfaces.js","sourceRoot":"","sources":["../../../src/ui/Interfaces.ts"],"names":[],"mappings":"","sourcesContent":["/*---------------------------------------------------------------------------------------------\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\n* See LICENSE.md in the project root for license terms and full copyright notice.\n*--------------------------------------------------------------------------------------------*/\nimport { MapSubLayerProps } from \"@itwin/core-common\";\nimport { MapLayerImageryProvider } from \"@itwin/core-frontend\";\n\nexport interface StyleMapLayerSettings {\n /** Name */\n name: string;\n /** URL */\n url: string;\n /** Controls visibility of layer */\n visible: boolean;\n /** A transparency value from 0.0 (fully opaque) to 1.0 (fully transparent) to apply to map graphics when drawing, or false to indicate the transparency should not be overridden. Default value: false. */\n transparency: number;\n /** Transparent background */\n transparentBackground: boolean;\n /** set map as underlay or overlay */\n isOverlay: boolean;\n /** Available map sub-layer */\n subLayers?: MapSubLayerProps[];\n /** sub-layer panel displayed. */\n showSubLayers: boolean;\n /** Some format can publish only a single layer at a time (i.e WMTS) */\n provider?: MapLayerImageryProvider;\n}\n\nexport interface MapTypesOptions {\n readonly supportTileUrl: boolean;\n readonly supportWmsAuthentication: boolean;\n}\n\nexport interface MapLayerOptions {\n hideExternalMapLayers?: boolean;\n fetchPublicMapLayerSources?: boolean;\n mapTypeOptions?: MapTypesOptions;\n}\n"]}
|