@itwin/tree-widget-react 0.7.2 → 0.9.0-dev.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/cjs/TreeWidget.js +1 -1
- package/lib/cjs/TreeWidget.js.map +1 -1
- package/lib/cjs/components/TreeWidgetComponent.scss +6 -6
- package/lib/cjs/components/TreeWidgetUiItemsProvider.d.ts +2 -3
- package/lib/cjs/components/TreeWidgetUiItemsProvider.js +9 -28
- package/lib/cjs/components/TreeWidgetUiItemsProvider.js.map +1 -1
- package/lib/cjs/components/search-bar/SearchBar.js +1 -1
- package/lib/cjs/components/search-bar/SearchBar.js.map +1 -1
- package/lib/cjs/components/search-bar/SearchBar.scss +32 -9
- package/lib/cjs/components/search-bar/SearchBox.js +8 -6
- package/lib/cjs/components/search-bar/SearchBox.js.map +1 -1
- package/lib/cjs/components/search-bar/SearchBox.scss +17 -38
- package/lib/cjs/components/trees/CategoriesVisibilityUtils.d.ts +1 -1
- package/lib/cjs/components/trees/CategoriesVisibilityUtils.js +15 -21
- package/lib/cjs/components/trees/CategoriesVisibilityUtils.js.map +1 -1
- package/lib/cjs/components/trees/VisibilityTreeBase.scss +4 -5
- package/lib/cjs/components/trees/VisibilityTreeEventHandler.js +2 -1
- package/lib/cjs/components/trees/VisibilityTreeEventHandler.js.map +1 -1
- package/lib/cjs/components/trees/category-tree/CategoriesTree.d.ts +1 -1
- package/lib/cjs/components/trees/category-tree/CategoriesTree.js +4 -3
- package/lib/cjs/components/trees/category-tree/CategoriesTree.js.map +1 -1
- package/lib/cjs/components/trees/category-tree/CategoriesTreeComponent.d.ts +1 -1
- package/lib/cjs/components/trees/category-tree/CategoriesTreeComponent.js +16 -12
- package/lib/cjs/components/trees/category-tree/CategoriesTreeComponent.js.map +1 -1
- package/lib/cjs/components/trees/category-tree/CategoryVisibilityHandler.d.ts +1 -1
- package/lib/cjs/components/trees/category-tree/CategoryVisibilityHandler.js +4 -4
- package/lib/cjs/components/trees/category-tree/CategoryVisibilityHandler.js.map +1 -1
- package/lib/cjs/components/trees/index.d.ts +0 -1
- package/lib/cjs/components/trees/index.js +0 -1
- package/lib/cjs/components/trees/index.js.map +1 -1
- package/lib/cjs/components/trees/models-tree/ModelsTree.d.ts +1 -1
- package/lib/cjs/components/trees/models-tree/ModelsTree.js +2 -2
- package/lib/cjs/components/trees/models-tree/ModelsTree.js.map +1 -1
- package/lib/cjs/components/trees/models-tree/ModelsTreeComponent.d.ts +1 -1
- package/lib/cjs/components/trees/models-tree/ModelsTreeComponent.js +11 -12
- package/lib/cjs/components/trees/models-tree/ModelsTreeComponent.js.map +1 -1
- package/lib/cjs/components/trees/models-tree/ModelsVisibilityHandler.js +11 -11
- package/lib/cjs/components/trees/models-tree/ModelsVisibilityHandler.js.map +1 -1
- package/lib/cjs/components/utils/AutoSizer.js +1 -2
- package/lib/cjs/components/utils/AutoSizer.js.map +1 -1
- package/lib/cjs/components/utils/IsPromiseLike.d.ts +3 -0
- package/lib/cjs/components/utils/IsPromiseLike.js +13 -0
- package/lib/cjs/components/utils/IsPromiseLike.js.map +1 -0
- package/lib/cjs/types.d.ts +1 -4
- package/lib/cjs/types.js.map +1 -1
- package/lib/esm/TreeWidget.js +1 -1
- package/lib/esm/TreeWidget.js.map +1 -1
- package/lib/esm/components/TreeWidgetComponent.scss +6 -6
- package/lib/esm/components/TreeWidgetUiItemsProvider.d.ts +2 -3
- package/lib/esm/components/TreeWidgetUiItemsProvider.js +11 -30
- package/lib/esm/components/TreeWidgetUiItemsProvider.js.map +1 -1
- package/lib/esm/components/search-bar/SearchBar.js +1 -1
- package/lib/esm/components/search-bar/SearchBar.js.map +1 -1
- package/lib/esm/components/search-bar/SearchBar.scss +32 -9
- package/lib/esm/components/search-bar/SearchBox.js +8 -6
- package/lib/esm/components/search-bar/SearchBox.js.map +1 -1
- package/lib/esm/components/search-bar/SearchBox.scss +17 -38
- package/lib/esm/components/trees/CategoriesVisibilityUtils.d.ts +1 -1
- package/lib/esm/components/trees/CategoriesVisibilityUtils.js +15 -21
- package/lib/esm/components/trees/CategoriesVisibilityUtils.js.map +1 -1
- package/lib/esm/components/trees/VisibilityTreeBase.scss +4 -5
- package/lib/esm/components/trees/VisibilityTreeEventHandler.js +2 -1
- package/lib/esm/components/trees/VisibilityTreeEventHandler.js.map +1 -1
- package/lib/esm/components/trees/category-tree/CategoriesTree.d.ts +1 -1
- package/lib/esm/components/trees/category-tree/CategoriesTree.js +4 -3
- package/lib/esm/components/trees/category-tree/CategoriesTree.js.map +1 -1
- package/lib/esm/components/trees/category-tree/CategoriesTreeComponent.d.ts +1 -1
- package/lib/esm/components/trees/category-tree/CategoriesTreeComponent.js +16 -12
- package/lib/esm/components/trees/category-tree/CategoriesTreeComponent.js.map +1 -1
- package/lib/esm/components/trees/category-tree/CategoryVisibilityHandler.d.ts +1 -1
- package/lib/esm/components/trees/category-tree/CategoryVisibilityHandler.js +4 -4
- package/lib/esm/components/trees/category-tree/CategoryVisibilityHandler.js.map +1 -1
- package/lib/esm/components/trees/index.d.ts +0 -1
- package/lib/esm/components/trees/index.js +0 -1
- package/lib/esm/components/trees/index.js.map +1 -1
- package/lib/esm/components/trees/models-tree/ModelsTree.d.ts +1 -1
- package/lib/esm/components/trees/models-tree/ModelsTree.js +2 -2
- package/lib/esm/components/trees/models-tree/ModelsTree.js.map +1 -1
- package/lib/esm/components/trees/models-tree/ModelsTreeComponent.d.ts +1 -1
- package/lib/esm/components/trees/models-tree/ModelsTreeComponent.js +11 -12
- package/lib/esm/components/trees/models-tree/ModelsTreeComponent.js.map +1 -1
- package/lib/esm/components/trees/models-tree/ModelsVisibilityHandler.js +11 -11
- package/lib/esm/components/trees/models-tree/ModelsVisibilityHandler.js.map +1 -1
- package/lib/esm/components/utils/AutoSizer.js +2 -3
- package/lib/esm/components/utils/AutoSizer.js.map +1 -1
- package/lib/esm/components/utils/IsPromiseLike.d.ts +3 -0
- package/lib/esm/components/{trees/models-tree/ModelsTree.scss → utils/IsPromiseLike.js} +4 -13
- package/lib/esm/components/utils/IsPromiseLike.js.map +1 -0
- package/lib/esm/types.d.ts +1 -4
- package/lib/esm/types.js.map +1 -1
- package/package.json +54 -31
- package/lib/cjs/components/IconButton.d.ts +0 -15
- package/lib/cjs/components/IconButton.js +0 -42
- package/lib/cjs/components/IconButton.js.map +0 -1
- package/lib/cjs/components/IconButton.scss +0 -73
- package/lib/cjs/components/trees/category-tree/CategoriesTree.scss +0 -18
- package/lib/cjs/components/trees/models-tree/ModelsTree.scss +0 -18
- package/lib/cjs/components/trees/spatial-tree/SpatialTreeComponent.d.ts +0 -4
- package/lib/cjs/components/trees/spatial-tree/SpatialTreeComponent.js +0 -22
- package/lib/cjs/components/trees/spatial-tree/SpatialTreeComponent.js.map +0 -1
- package/lib/esm/components/IconButton.d.ts +0 -15
- package/lib/esm/components/IconButton.js +0 -16
- package/lib/esm/components/IconButton.js.map +0 -1
- package/lib/esm/components/IconButton.scss +0 -73
- package/lib/esm/components/trees/category-tree/CategoriesTree.scss +0 -18
- package/lib/esm/components/trees/spatial-tree/SpatialTreeComponent.d.ts +0 -4
- package/lib/esm/components/trees/spatial-tree/SpatialTreeComponent.js +0 -15
- package/lib/esm/components/trees/spatial-tree/SpatialTreeComponent.js.map +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AutoSizer.js","sourceRoot":"","sources":["../../../../src/components/utils/AutoSizer.tsx"],"names":[],"mappings":"AAAA;;;+FAG+F;AAC/F,OAAO,KAAK,EAAE,EAAE,WAAW,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AACrD,OAAO,EAAE,
|
|
1
|
+
{"version":3,"file":"AutoSizer.js","sourceRoot":"","sources":["../../../../src/components/utils/AutoSizer.tsx"],"names":[],"mappings":"AAAA;;;+FAG+F;AAC/F,OAAO,KAAK,EAAE,EAAE,WAAW,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AACrD,OAAO,EAAE,0BAA0B,EAAE,MAAM,mBAAmB,CAAC;AAW/D,MAAM,CAAC,MAAM,SAAS,GAAG,CAAC,KAAqB,EAAE,EAAE;IACjD,MAAM,CAAC,MAAM,EAAE,SAAS,CAAC,GAAG,QAAQ,CAAC,CAAC,CAAC,CAAC;IACxC,MAAM,CAAC,KAAK,EAAE,QAAQ,CAAC,GAAG,QAAQ,CAAC,CAAC,CAAC,CAAC;IACtC,MAAM,YAAY,GAAG,WAAW,CAAC,CAAC,CAAS,EAAE,CAAS,EAAE,EAAE;QACxD,SAAS,CAAC,CAAC,CAAC,CAAC;QACb,QAAQ,CAAC,CAAC,CAAC,CAAC;IACd,CAAC,EAAE,EAAE,CAAC,CAAC;IAEP,OAAO,CACL,oBAAC,0BAA0B,IAAC,QAAQ,EAAE,YAAY,IAC/C,KAAK,CAAC,QAAQ,CAAC,EAAE,MAAM,EAAE,KAAK,EAAE,CAAC,CACP,CAC9B,CAAC;AACJ,CAAC,CAAC","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 React, { useCallback, useState } from \"react\";\nimport { ResizableContainerObserver } from \"@itwin/core-react\";\n\nexport interface Size {\n width: number;\n height: number;\n}\n\nexport interface AutoSizerProps {\n children: (size: Size) => React.ReactElement | null;\n}\n\nexport const AutoSizer = (props: AutoSizerProps) => {\n const [height, setHeight] = useState(0);\n const [width, setWidth] = useState(0);\n const handleResize = useCallback((w: number, h: number) => {\n setHeight(h);\n setWidth(w);\n }, []);\n\n return (\n <ResizableContainerObserver onResize={handleResize}>\n {props.children({ height, width })}\n </ResizableContainerObserver>\n );\n};\n"]}
|
|
@@ -2,17 +2,8 @@
|
|
|
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
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
.tree-widget-models-tree {
|
|
9
|
-
@include tree-widget-visibility-tree-base;
|
|
10
|
-
}
|
|
11
|
-
|
|
12
|
-
.tree-widget-models-tree-container {
|
|
13
|
-
flex: 1;
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
.tree-widget-models-tree-toolbar-icon {
|
|
17
|
-
color: $buic-icon-color;
|
|
5
|
+
/** Checks if the specified argument is a promise */
|
|
6
|
+
export function isPromiseLike(obj) {
|
|
7
|
+
return !!(obj && (typeof obj === "object") && (typeof obj.then === "function"));
|
|
18
8
|
}
|
|
9
|
+
//# sourceMappingURL=IsPromiseLike.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"IsPromiseLike.js","sourceRoot":"","sources":["../../../../src/components/utils/IsPromiseLike.ts"],"names":[],"mappings":"AAAA;;;+FAG+F;AAC/F,oDAAoD;AACpD,MAAM,UAAU,aAAa,CAAC,GAAY;IACxC,OAAO,CAAC,CAAC,CAAC,GAAG,IAAI,CAAC,OAAO,GAAG,KAAK,QAAQ,CAAC,IAAI,CAAC,OAAQ,GAAW,CAAC,IAAI,KAAK,UAAU,CAAC,CAAC,CAAC;AAC3F,CAAC","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/** Checks if the specified argument is a promise */\nexport function isPromiseLike(obj: unknown): obj is PromiseLike<unknown> {\n return !!(obj && (typeof obj === \"object\") && (typeof (obj as any).then === \"function\"));\n}\n"]}
|
package/lib/esm/types.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
import
|
|
2
|
+
import { StagePanelLocation, StagePanelSection } from "@itwin/appui-react";
|
|
3
3
|
import type { SelectableContentDefinition } from "@itwin/components-react";
|
|
4
4
|
import type { IModelConnection, ScreenViewport } from "@itwin/core-frontend";
|
|
5
5
|
import type { CategoryTreeProps } from "./components/trees/category-tree/CategoriesTree";
|
|
@@ -24,7 +24,6 @@ export interface ModelTreeProps extends Omit<ModelsTreeProps, "iModel" | "active
|
|
|
24
24
|
export interface CategoriesTreeProps extends Omit<CategoryTreeProps, "iModel" | "activeView" | "width" | "height" | "filterInfo" | "onFilterApplied" | "categories"> {
|
|
25
25
|
headerButtons?: Array<(props: CategoriesTreeHeaderButtonProps) => React.ReactNode>;
|
|
26
26
|
}
|
|
27
|
-
export declare type SpatialTreeProps = Omit<SpatialContainmentTreeProps, "iModel" | "width" | "height">;
|
|
28
27
|
export declare const ModelsTreeId = "models-tree";
|
|
29
28
|
export declare const CategoriesTreeId = "categories-tree";
|
|
30
29
|
export declare const SpatialContainmentTreeId = "spatial-containment-tree";
|
|
@@ -36,12 +35,10 @@ export interface TreeWidgetOptions {
|
|
|
36
35
|
additionalTrees?: SelectableContentDefinition[];
|
|
37
36
|
modelsTreeProps?: ModelTreeProps;
|
|
38
37
|
categoriesTreeProps?: CategoriesTreeProps;
|
|
39
|
-
spatialTreeProps?: SpatialTreeProps;
|
|
40
38
|
defaultTreeId?: string;
|
|
41
39
|
hideTrees?: {
|
|
42
40
|
modelsTree?: boolean;
|
|
43
41
|
categoriesTree?: boolean;
|
|
44
|
-
spatialTree?: boolean;
|
|
45
42
|
};
|
|
46
43
|
}
|
|
47
44
|
//# sourceMappingURL=types.d.ts.map
|
package/lib/esm/types.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../src/types.ts"],"names":[],"mappings":"AAAA;;;+FAG+F;
|
|
1
|
+
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../src/types.ts"],"names":[],"mappings":"AAAA;;;+FAG+F;AA8C/F,MAAM,CAAC,MAAM,YAAY,GAAG,aAAa,CAAC;AAE1C,MAAM,CAAC,MAAM,gBAAgB,GAAG,iBAAiB,CAAC;AAElD,MAAM,CAAC,MAAM,wBAAwB,GAAG,0BAA0B,CAAC","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\nimport { StagePanelLocation, StagePanelSection } from \"@itwin/appui-react\";\nimport type { SelectableContentDefinition } from \"@itwin/components-react\";\nimport type { IModelConnection, ScreenViewport } from \"@itwin/core-frontend\";\nimport type { CategoryTreeProps } from \"./components/trees/category-tree/CategoriesTree\";\nimport type { ModelsTreeProps } from \"./components/trees/models-tree/ModelsTree\";\nimport type { CategoryInfo, ModelInfo } from \"./tree-widget-react\";\n\nexport interface TreeHeaderButtonProps {\n viewport: ScreenViewport;\n}\n\nexport interface ModelsTreeHeaderButtonProps extends TreeHeaderButtonProps {\n models: ModelInfo[];\n}\n\nexport interface CategoriesTreeHeaderButtonProps extends TreeHeaderButtonProps {\n categories: CategoryInfo[];\n filteredCategories?: CategoryInfo[];\n}\n\nexport interface IModelContentTreeProps\n extends Omit<React.AllHTMLAttributes<HTMLDivElement>, \"children\"> {\n iModel: IModelConnection;\n}\n\nexport interface ModelTreeProps extends Omit<ModelsTreeProps,\n| \"iModel\"\n| \"activeView\"\n| \"width\"\n| \"height\"\n| \"filterInfo\"\n| \"onFilterApplied\"\n> { headerButtons?: Array<(props: ModelsTreeHeaderButtonProps) => React.ReactNode> }\n\nexport interface CategoriesTreeProps extends Omit<CategoryTreeProps,\n| \"iModel\"\n| \"activeView\"\n| \"width\"\n| \"height\"\n| \"filterInfo\"\n| \"onFilterApplied\"\n| \"categories\"\n> { headerButtons?: Array<(props: CategoriesTreeHeaderButtonProps) => React.ReactNode> }\n\nexport const ModelsTreeId = \"models-tree\";\n\nexport const CategoriesTreeId = \"categories-tree\";\n\nexport const SpatialContainmentTreeId = \"spatial-containment-tree\";\n\nexport interface TreeWidgetOptions {\n defaultPanelLocation?: StagePanelLocation;\n defaultPanelSection?: StagePanelSection;\n defaultTreeWidgetPriority?: number;\n enableElementsClassGrouping?: boolean;\n additionalTrees?: SelectableContentDefinition[];\n modelsTreeProps?: ModelTreeProps;\n categoriesTreeProps?: CategoriesTreeProps;\n defaultTreeId?: string;\n hideTrees?: {\n modelsTree?: boolean;\n categoriesTree?: boolean;\n };\n}\n"]}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@itwin/tree-widget-react",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.9.0-dev.2",
|
|
4
4
|
"description": "Tree Widget React",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"Bentley",
|
|
@@ -20,8 +20,9 @@
|
|
|
20
20
|
"module": "lib/esm/tree-widget-react.js",
|
|
21
21
|
"typings": "lib/cjs/tree-widget-react",
|
|
22
22
|
"dependencies": {
|
|
23
|
-
"@itwin/itwinui-icons-react": "^1.
|
|
24
|
-
"@itwin/itwinui-react": "^
|
|
23
|
+
"@itwin/itwinui-icons-react": "^2.1.0",
|
|
24
|
+
"@itwin/itwinui-react": "^2.7.0",
|
|
25
|
+
"@itwin/itwinui-variables": "^2.0.0",
|
|
25
26
|
"classnames": "^2.3.1",
|
|
26
27
|
"i18next": "^10.2.2",
|
|
27
28
|
"react-redux": "^7.2.0",
|
|
@@ -29,34 +30,37 @@
|
|
|
29
30
|
"rxjs": "^6.6.2"
|
|
30
31
|
},
|
|
31
32
|
"devDependencies": {
|
|
32
|
-
"@itwin/appui-abstract": "
|
|
33
|
-
"@itwin/appui-layout-react": "
|
|
34
|
-
"@itwin/appui-react": "
|
|
35
|
-
"@itwin/build-tools": "
|
|
36
|
-
"@itwin/components-react": "
|
|
37
|
-
"@itwin/core-
|
|
38
|
-
"@itwin/core-
|
|
39
|
-
"@itwin/core-
|
|
40
|
-
"@itwin/core-
|
|
41
|
-
"@itwin/core-
|
|
42
|
-
"@itwin/core-
|
|
43
|
-
"@itwin/core-
|
|
44
|
-
"@itwin/core-
|
|
45
|
-
"@itwin/core-
|
|
46
|
-
"@itwin/
|
|
47
|
-
"@itwin/
|
|
48
|
-
"@itwin/
|
|
49
|
-
"@itwin/
|
|
50
|
-
"@itwin/presentation-
|
|
51
|
-
"@itwin/presentation-
|
|
52
|
-
"@itwin/
|
|
33
|
+
"@itwin/appui-abstract": "3.7.0",
|
|
34
|
+
"@itwin/appui-layout-react": "4.0.0-dev.13",
|
|
35
|
+
"@itwin/appui-react": "4.0.0-dev.13",
|
|
36
|
+
"@itwin/build-tools": "3.7.0",
|
|
37
|
+
"@itwin/components-react": "4.0.0-dev.13",
|
|
38
|
+
"@itwin/core-backend": "3.7.0",
|
|
39
|
+
"@itwin/core-bentley": "3.7.0",
|
|
40
|
+
"@itwin/core-common": "3.7.0",
|
|
41
|
+
"@itwin/core-frontend": "3.7.0",
|
|
42
|
+
"@itwin/core-geometry": "3.7.0",
|
|
43
|
+
"@itwin/core-i18n": "3.7.0",
|
|
44
|
+
"@itwin/core-markup": "3.7.0",
|
|
45
|
+
"@itwin/core-orbitgt": "3.7.0",
|
|
46
|
+
"@itwin/core-quantity": "3.7.0",
|
|
47
|
+
"@itwin/core-react": "4.0.0-dev.13",
|
|
48
|
+
"@itwin/ecschema-metadata": "3.7.0",
|
|
49
|
+
"@itwin/eslint-plugin": "3.7.0",
|
|
50
|
+
"@itwin/imodel-components-react": "4.0.0-dev.13",
|
|
51
|
+
"@itwin/presentation-backend": "3.7.0",
|
|
52
|
+
"@itwin/presentation-common": "3.7.0",
|
|
53
|
+
"@itwin/presentation-components": "4.0.0-dev.31",
|
|
54
|
+
"@itwin/presentation-frontend": "3.7.0",
|
|
55
|
+
"@itwin/presentation-testing": "4.0.0-dev.31",
|
|
56
|
+
"@itwin/webgl-compatibility": "3.7.0",
|
|
53
57
|
"@testing-library/react": "^12.0.0",
|
|
54
58
|
"@testing-library/react-hooks": "^7.0.2",
|
|
55
59
|
"@types/chai": "4.3.1",
|
|
56
60
|
"@types/chai-jest-snapshot": "^1.3.4",
|
|
57
61
|
"@types/deep-equal": "^1.0.1",
|
|
58
62
|
"@types/i18next": "^8.4.2",
|
|
59
|
-
"@types/jsdom-global": "
|
|
63
|
+
"@types/jsdom-global": "3.0.2",
|
|
60
64
|
"@types/mocha": "^8.2.2",
|
|
61
65
|
"@types/react": "^17.0.19",
|
|
62
66
|
"@types/react-dom": "^17.0.9",
|
|
@@ -83,15 +87,34 @@
|
|
|
83
87
|
"xmlhttprequest": "^1.8.0"
|
|
84
88
|
},
|
|
85
89
|
"peerDependencies": {
|
|
86
|
-
"@itwin/appui-abstract": "^3.
|
|
87
|
-
"@itwin/appui-react": "^
|
|
88
|
-
"@itwin/components-react": "^
|
|
89
|
-
"@itwin/core-frontend": "^3.
|
|
90
|
-
"@itwin/core-react": "^
|
|
91
|
-
"@itwin/presentation-components": "^
|
|
90
|
+
"@itwin/appui-abstract": "^3.7.0",
|
|
91
|
+
"@itwin/appui-react": "^4.0.0-dev.13",
|
|
92
|
+
"@itwin/components-react": "^4.0.0-dev.13",
|
|
93
|
+
"@itwin/core-frontend": "^3.7.0",
|
|
94
|
+
"@itwin/core-react": "^4.0.0-dev.13",
|
|
95
|
+
"@itwin/presentation-components": "^4.0.0-dev.31",
|
|
92
96
|
"react": "^17.0.2",
|
|
93
97
|
"react-dom": "^17.0.2"
|
|
94
98
|
},
|
|
99
|
+
"eslintConfig": {
|
|
100
|
+
"plugins": [
|
|
101
|
+
"@itwin"
|
|
102
|
+
],
|
|
103
|
+
"extends": [
|
|
104
|
+
"plugin:@itwin/ui"
|
|
105
|
+
],
|
|
106
|
+
"rules": {
|
|
107
|
+
"@itwin/no-internal": [
|
|
108
|
+
"error"
|
|
109
|
+
],
|
|
110
|
+
"@typescript-eslint/no-floating-promises": [
|
|
111
|
+
"error",
|
|
112
|
+
{
|
|
113
|
+
"ignoreIIFE": true
|
|
114
|
+
}
|
|
115
|
+
]
|
|
116
|
+
}
|
|
117
|
+
},
|
|
95
118
|
"scripts": {
|
|
96
119
|
"build": "npm run -s dual-build && npm run -s copy:assets",
|
|
97
120
|
"dual-build": "npm run -s build:cjs && npm run -s build:esm",
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
import * as React from "react";
|
|
2
|
-
import type { CommonProps } from "@itwin/core-react";
|
|
3
|
-
import "./IconButton.scss";
|
|
4
|
-
/** Properties for [[IconButton]] component */
|
|
5
|
-
export interface IconButtonProps extends React.ButtonHTMLAttributes<HTMLButtonElement>, CommonProps {
|
|
6
|
-
/** Icon name */
|
|
7
|
-
icon: string;
|
|
8
|
-
/** A function to be run when the element is clicked */
|
|
9
|
-
onClick?: (event: React.MouseEvent<HTMLButtonElement, MouseEvent>) => void;
|
|
10
|
-
/** An optional text label to display to the left of the button */
|
|
11
|
-
label?: string;
|
|
12
|
-
}
|
|
13
|
-
/** Generic icon button component */
|
|
14
|
-
export declare function IconButton({ className, icon, onClick, label, ...otherProps }: IconButtonProps): JSX.Element;
|
|
15
|
-
//# sourceMappingURL=IconButton.d.ts.map
|
|
@@ -1,42 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
-
if (k2 === undefined) k2 = k;
|
|
4
|
-
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
|
|
5
|
-
}) : (function(o, m, k, k2) {
|
|
6
|
-
if (k2 === undefined) k2 = k;
|
|
7
|
-
o[k2] = m[k];
|
|
8
|
-
}));
|
|
9
|
-
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
10
|
-
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
11
|
-
}) : function(o, v) {
|
|
12
|
-
o["default"] = v;
|
|
13
|
-
});
|
|
14
|
-
var __importStar = (this && this.__importStar) || function (mod) {
|
|
15
|
-
if (mod && mod.__esModule) return mod;
|
|
16
|
-
var result = {};
|
|
17
|
-
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
18
|
-
__setModuleDefault(result, mod);
|
|
19
|
-
return result;
|
|
20
|
-
};
|
|
21
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
22
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
23
|
-
};
|
|
24
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
25
|
-
exports.IconButton = void 0;
|
|
26
|
-
/*---------------------------------------------------------------------------------------------
|
|
27
|
-
* Copyright (c) Bentley Systems, Incorporated. All rights reserved.
|
|
28
|
-
* See LICENSE.md in the project root for license terms and full copyright notice.
|
|
29
|
-
*--------------------------------------------------------------------------------------------*/
|
|
30
|
-
const React = __importStar(require("react"));
|
|
31
|
-
const classnames_1 = __importDefault(require("classnames"));
|
|
32
|
-
require("./IconButton.scss");
|
|
33
|
-
/** Generic icon button component */
|
|
34
|
-
function IconButton({ className, icon, onClick, label, ...otherProps }) {
|
|
35
|
-
return (React.createElement(React.Fragment, null,
|
|
36
|
-
label &&
|
|
37
|
-
React.createElement("span", { className: (0, classnames_1.default)("tree-widget-icon-label", className) }, label),
|
|
38
|
-
React.createElement("button", { ...otherProps, className: (0, classnames_1.default)("tree-widget-icon-button", className), onClick: onClick },
|
|
39
|
-
React.createElement("span", { className: (0, classnames_1.default)("icon", icon) }))));
|
|
40
|
-
}
|
|
41
|
-
exports.IconButton = IconButton;
|
|
42
|
-
//# sourceMappingURL=IconButton.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"IconButton.js","sourceRoot":"","sources":["../../../src/components/IconButton.tsx"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;AAAA;;;+FAG+F;AAC/F,6CAA+B;AAC/B,4DAAoC;AAEpC,6BAA2B;AAc3B,oCAAoC;AACpC,SAAgB,UAAU,CAAC,EACzB,SAAS,EACT,IAAI,EACJ,OAAO,EACP,KAAK,EACL,GAAG,UAAU,EACG;IAChB,OAAO,CACL;QACG,KAAK;YACJ,8BAAM,SAAS,EAAE,IAAA,oBAAU,EAAC,wBAAwB,EAAE,SAAS,CAAC,IAC7D,KAAK,CACD;QAET,mCACM,UAAU,EACd,SAAS,EAAE,IAAA,oBAAU,EAAC,yBAAyB,EAAE,SAAS,CAAC,EAC3D,OAAO,EAAE,OAAO;YAEhB,8BAAM,SAAS,EAAE,IAAA,oBAAU,EAAC,MAAM,EAAE,IAAI,CAAC,GAAI,CACtC,CACR,CACJ,CAAC;AACJ,CAAC;AAvBD,gCAuBC","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 * as React from \"react\";\nimport classnames from \"classnames\";\nimport type { CommonProps } from \"@itwin/core-react\";\nimport \"./IconButton.scss\";\n\n/** Properties for [[IconButton]] component */\nexport interface IconButtonProps\n extends React.ButtonHTMLAttributes<HTMLButtonElement>,\n CommonProps {\n /** Icon name */\n icon: string;\n /** A function to be run when the element is clicked */\n onClick?: (event: React.MouseEvent<HTMLButtonElement, MouseEvent>) => void;\n /** An optional text label to display to the left of the button */\n label?: string;\n}\n\n/** Generic icon button component */\nexport function IconButton({\n className,\n icon,\n onClick,\n label,\n ...otherProps\n}: IconButtonProps) {\n return (\n <>\n {label &&\n <span className={classnames(\"tree-widget-icon-label\", className)}>\n {label}\n </span>\n }\n <button\n {...otherProps}\n className={classnames(\"tree-widget-icon-button\", className)}\n onClick={onClick}\n >\n <span className={classnames(\"icon\", icon)} />\n </button>\n </>\n );\n}\n"]}
|
|
@@ -1,73 +0,0 @@
|
|
|
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 "~@itwin/core-react/lib/cjs/core-react/index";
|
|
6
|
-
@import "~@itwin/appui-layout-react/lib/cjs/appui-layout-react/footer/_variables";
|
|
7
|
-
|
|
8
|
-
.tree-widget-icon-button {
|
|
9
|
-
display: inline-block;
|
|
10
|
-
align-items: center;
|
|
11
|
-
justify-content: center;
|
|
12
|
-
width: 32px;
|
|
13
|
-
height: 32px;
|
|
14
|
-
border: 0;
|
|
15
|
-
color: $buic-icon-color;
|
|
16
|
-
background-color: transparent;
|
|
17
|
-
outline: none;
|
|
18
|
-
box-shadow: none;
|
|
19
|
-
font-family: $uicore-font-family;
|
|
20
|
-
font-size: $uicore-font-size;
|
|
21
|
-
text-decoration: none;
|
|
22
|
-
cursor: pointer;
|
|
23
|
-
transition: color 0.25s;
|
|
24
|
-
|
|
25
|
-
&:hover {
|
|
26
|
-
text-decoration: none;
|
|
27
|
-
color: $buic-foreground-primary;
|
|
28
|
-
}
|
|
29
|
-
|
|
30
|
-
&:active {
|
|
31
|
-
outline: none;
|
|
32
|
-
box-shadow: none;
|
|
33
|
-
text-decoration: none;
|
|
34
|
-
background-color: transparent;
|
|
35
|
-
}
|
|
36
|
-
|
|
37
|
-
&:focus {
|
|
38
|
-
outline: none;
|
|
39
|
-
box-shadow: none;
|
|
40
|
-
text-decoration: none;
|
|
41
|
-
background-color: transparent;
|
|
42
|
-
}
|
|
43
|
-
|
|
44
|
-
&[disabled],
|
|
45
|
-
&[disabled]:hover,
|
|
46
|
-
&[disabled]:active,
|
|
47
|
-
&[disabled]:focus {
|
|
48
|
-
opacity: 0.4;
|
|
49
|
-
color: $uicore-gray;
|
|
50
|
-
background: transparent;
|
|
51
|
-
cursor: not-allowed;
|
|
52
|
-
pointer-events: none;
|
|
53
|
-
}
|
|
54
|
-
}
|
|
55
|
-
|
|
56
|
-
.tree-widget-icon-label {
|
|
57
|
-
display: inline-flex;
|
|
58
|
-
align-items: center;
|
|
59
|
-
justify-content: center;
|
|
60
|
-
height: 32px;
|
|
61
|
-
font-family: $uicore-font-family;
|
|
62
|
-
font-size: $uicore-font-size;
|
|
63
|
-
color: $buic-icon-color;
|
|
64
|
-
margin-left: 5px;
|
|
65
|
-
|
|
66
|
-
&[disabled] {
|
|
67
|
-
opacity: 0.4;
|
|
68
|
-
color: $uicore-gray;
|
|
69
|
-
background: transparent;
|
|
70
|
-
cursor: not-allowed;
|
|
71
|
-
pointer-events: none;
|
|
72
|
-
}
|
|
73
|
-
}
|
|
@@ -1,18 +0,0 @@
|
|
|
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 "~@itwin/core-react/lib/cjs/core-react/index";
|
|
6
|
-
@import "../VisibilityTreeBase";
|
|
7
|
-
|
|
8
|
-
.tree-widget-categories-tree {
|
|
9
|
-
@include tree-widget-visibility-tree-base;
|
|
10
|
-
}
|
|
11
|
-
|
|
12
|
-
.tree-widget-category-tree-search-bar {
|
|
13
|
-
margin-bottom: $uicore-s;
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
.tree-widget-category-tree-toolbar-icon {
|
|
17
|
-
color: $buic-icon-color;
|
|
18
|
-
}
|
|
@@ -1,18 +0,0 @@
|
|
|
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 "~@itwin/core-react/lib/cjs/core-react/index";
|
|
6
|
-
@import "../VisibilityTreeBase";
|
|
7
|
-
|
|
8
|
-
.tree-widget-models-tree {
|
|
9
|
-
@include tree-widget-visibility-tree-base;
|
|
10
|
-
}
|
|
11
|
-
|
|
12
|
-
.tree-widget-models-tree-container {
|
|
13
|
-
flex: 1;
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
.tree-widget-models-tree-toolbar-icon {
|
|
17
|
-
color: $buic-icon-color;
|
|
18
|
-
}
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
/*---------------------------------------------------------------------------------------------
|
|
3
|
-
* Copyright (c) Bentley Systems, Incorporated. All rights reserved.
|
|
4
|
-
* See LICENSE.md in the project root for license terms and full copyright notice.
|
|
5
|
-
*--------------------------------------------------------------------------------------------*/
|
|
6
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
7
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
8
|
-
};
|
|
9
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
10
|
-
exports.SpatialTreeComponent = void 0;
|
|
11
|
-
const react_1 = __importDefault(require("react"));
|
|
12
|
-
const appui_react_1 = require("@itwin/appui-react");
|
|
13
|
-
const AutoSizer_1 = require("../../utils/AutoSizer");
|
|
14
|
-
const SpatialTreeComponent = (props) => {
|
|
15
|
-
const iModel = (0, appui_react_1.useActiveIModelConnection)();
|
|
16
|
-
return (react_1.default.createElement(react_1.default.Fragment, null, iModel &&
|
|
17
|
-
react_1.default.createElement(AutoSizer_1.AutoSizer, null,
|
|
18
|
-
// eslint-disable-next-line deprecation/deprecation
|
|
19
|
-
({ width, height }) => react_1.default.createElement(appui_react_1.SpatialContainmentTree, { ...props, width: width, height: height, iModel: iModel }))));
|
|
20
|
-
};
|
|
21
|
-
exports.SpatialTreeComponent = SpatialTreeComponent;
|
|
22
|
-
//# sourceMappingURL=SpatialTreeComponent.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"SpatialTreeComponent.js","sourceRoot":"","sources":["../../../../../src/components/trees/spatial-tree/SpatialTreeComponent.tsx"],"names":[],"mappings":";AAAA;;;+FAG+F;;;;;;AAE/F,kDAA0B;AAC1B,oDAAuF;AACvF,qDAAkD;AAI3C,MAAM,oBAAoB,GAAG,CAClC,KAAuB,EAAE,EAAE;IAC3B,MAAM,MAAM,GAAG,IAAA,uCAAyB,GAAE,CAAC;IAE3C,OAAO,CACL,8DACG,MAAM;QACL,8BAAC,qBAAS;QAEN,mDAAmD;QACnD,CAAC,EAAE,KAAK,EAAE,MAAM,EAAE,EAAE,EAAE,CAAC,8BAAC,oCAAsB,OAAK,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,GAAI,CAElG,CAEb,CACJ,CAAC;AACJ,CAAC,CAAC;AAhBW,QAAA,oBAAoB,wBAgB/B","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\nimport React from \"react\";\nimport { SpatialContainmentTree, useActiveIModelConnection } from \"@itwin/appui-react\";\nimport { AutoSizer } from \"../../utils/AutoSizer\";\n\nimport type { SpatialTreeProps } from \"../../../types\";\n\nexport const SpatialTreeComponent = (\n props: SpatialTreeProps) => {\n const iModel = useActiveIModelConnection();\n\n return (\n <>\n {iModel &&\n <AutoSizer>\n {\n // eslint-disable-next-line deprecation/deprecation\n ({ width, height }) => <SpatialContainmentTree {...props} width={width} height={height} iModel={iModel} />\n }\n </AutoSizer>\n }\n </>\n );\n};\n"]}
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
import * as React from "react";
|
|
2
|
-
import type { CommonProps } from "@itwin/core-react";
|
|
3
|
-
import "./IconButton.scss";
|
|
4
|
-
/** Properties for [[IconButton]] component */
|
|
5
|
-
export interface IconButtonProps extends React.ButtonHTMLAttributes<HTMLButtonElement>, CommonProps {
|
|
6
|
-
/** Icon name */
|
|
7
|
-
icon: string;
|
|
8
|
-
/** A function to be run when the element is clicked */
|
|
9
|
-
onClick?: (event: React.MouseEvent<HTMLButtonElement, MouseEvent>) => void;
|
|
10
|
-
/** An optional text label to display to the left of the button */
|
|
11
|
-
label?: string;
|
|
12
|
-
}
|
|
13
|
-
/** Generic icon button component */
|
|
14
|
-
export declare function IconButton({ className, icon, onClick, label, ...otherProps }: IconButtonProps): JSX.Element;
|
|
15
|
-
//# sourceMappingURL=IconButton.d.ts.map
|
|
@@ -1,16 +0,0 @@
|
|
|
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 * as React from "react";
|
|
6
|
-
import classnames from "classnames";
|
|
7
|
-
import "./IconButton.scss";
|
|
8
|
-
/** Generic icon button component */
|
|
9
|
-
export function IconButton({ className, icon, onClick, label, ...otherProps }) {
|
|
10
|
-
return (React.createElement(React.Fragment, null,
|
|
11
|
-
label &&
|
|
12
|
-
React.createElement("span", { className: classnames("tree-widget-icon-label", className) }, label),
|
|
13
|
-
React.createElement("button", { ...otherProps, className: classnames("tree-widget-icon-button", className), onClick: onClick },
|
|
14
|
-
React.createElement("span", { className: classnames("icon", icon) }))));
|
|
15
|
-
}
|
|
16
|
-
//# sourceMappingURL=IconButton.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"IconButton.js","sourceRoot":"","sources":["../../../src/components/IconButton.tsx"],"names":[],"mappings":"AAAA;;;+FAG+F;AAC/F,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAC/B,OAAO,UAAU,MAAM,YAAY,CAAC;AAEpC,OAAO,mBAAmB,CAAC;AAc3B,oCAAoC;AACpC,MAAM,UAAU,UAAU,CAAC,EACzB,SAAS,EACT,IAAI,EACJ,OAAO,EACP,KAAK,EACL,GAAG,UAAU,EACG;IAChB,OAAO,CACL;QACG,KAAK;YACJ,8BAAM,SAAS,EAAE,UAAU,CAAC,wBAAwB,EAAE,SAAS,CAAC,IAC7D,KAAK,CACD;QAET,mCACM,UAAU,EACd,SAAS,EAAE,UAAU,CAAC,yBAAyB,EAAE,SAAS,CAAC,EAC3D,OAAO,EAAE,OAAO;YAEhB,8BAAM,SAAS,EAAE,UAAU,CAAC,MAAM,EAAE,IAAI,CAAC,GAAI,CACtC,CACR,CACJ,CAAC;AACJ,CAAC","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 * as React from \"react\";\nimport classnames from \"classnames\";\nimport type { CommonProps } from \"@itwin/core-react\";\nimport \"./IconButton.scss\";\n\n/** Properties for [[IconButton]] component */\nexport interface IconButtonProps\n extends React.ButtonHTMLAttributes<HTMLButtonElement>,\n CommonProps {\n /** Icon name */\n icon: string;\n /** A function to be run when the element is clicked */\n onClick?: (event: React.MouseEvent<HTMLButtonElement, MouseEvent>) => void;\n /** An optional text label to display to the left of the button */\n label?: string;\n}\n\n/** Generic icon button component */\nexport function IconButton({\n className,\n icon,\n onClick,\n label,\n ...otherProps\n}: IconButtonProps) {\n return (\n <>\n {label &&\n <span className={classnames(\"tree-widget-icon-label\", className)}>\n {label}\n </span>\n }\n <button\n {...otherProps}\n className={classnames(\"tree-widget-icon-button\", className)}\n onClick={onClick}\n >\n <span className={classnames(\"icon\", icon)} />\n </button>\n </>\n );\n}\n"]}
|
|
@@ -1,73 +0,0 @@
|
|
|
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 "~@itwin/core-react/lib/cjs/core-react/index";
|
|
6
|
-
@import "~@itwin/appui-layout-react/lib/cjs/appui-layout-react/footer/_variables";
|
|
7
|
-
|
|
8
|
-
.tree-widget-icon-button {
|
|
9
|
-
display: inline-block;
|
|
10
|
-
align-items: center;
|
|
11
|
-
justify-content: center;
|
|
12
|
-
width: 32px;
|
|
13
|
-
height: 32px;
|
|
14
|
-
border: 0;
|
|
15
|
-
color: $buic-icon-color;
|
|
16
|
-
background-color: transparent;
|
|
17
|
-
outline: none;
|
|
18
|
-
box-shadow: none;
|
|
19
|
-
font-family: $uicore-font-family;
|
|
20
|
-
font-size: $uicore-font-size;
|
|
21
|
-
text-decoration: none;
|
|
22
|
-
cursor: pointer;
|
|
23
|
-
transition: color 0.25s;
|
|
24
|
-
|
|
25
|
-
&:hover {
|
|
26
|
-
text-decoration: none;
|
|
27
|
-
color: $buic-foreground-primary;
|
|
28
|
-
}
|
|
29
|
-
|
|
30
|
-
&:active {
|
|
31
|
-
outline: none;
|
|
32
|
-
box-shadow: none;
|
|
33
|
-
text-decoration: none;
|
|
34
|
-
background-color: transparent;
|
|
35
|
-
}
|
|
36
|
-
|
|
37
|
-
&:focus {
|
|
38
|
-
outline: none;
|
|
39
|
-
box-shadow: none;
|
|
40
|
-
text-decoration: none;
|
|
41
|
-
background-color: transparent;
|
|
42
|
-
}
|
|
43
|
-
|
|
44
|
-
&[disabled],
|
|
45
|
-
&[disabled]:hover,
|
|
46
|
-
&[disabled]:active,
|
|
47
|
-
&[disabled]:focus {
|
|
48
|
-
opacity: 0.4;
|
|
49
|
-
color: $uicore-gray;
|
|
50
|
-
background: transparent;
|
|
51
|
-
cursor: not-allowed;
|
|
52
|
-
pointer-events: none;
|
|
53
|
-
}
|
|
54
|
-
}
|
|
55
|
-
|
|
56
|
-
.tree-widget-icon-label {
|
|
57
|
-
display: inline-flex;
|
|
58
|
-
align-items: center;
|
|
59
|
-
justify-content: center;
|
|
60
|
-
height: 32px;
|
|
61
|
-
font-family: $uicore-font-family;
|
|
62
|
-
font-size: $uicore-font-size;
|
|
63
|
-
color: $buic-icon-color;
|
|
64
|
-
margin-left: 5px;
|
|
65
|
-
|
|
66
|
-
&[disabled] {
|
|
67
|
-
opacity: 0.4;
|
|
68
|
-
color: $uicore-gray;
|
|
69
|
-
background: transparent;
|
|
70
|
-
cursor: not-allowed;
|
|
71
|
-
pointer-events: none;
|
|
72
|
-
}
|
|
73
|
-
}
|
|
@@ -1,18 +0,0 @@
|
|
|
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 "~@itwin/core-react/lib/cjs/core-react/index";
|
|
6
|
-
@import "../VisibilityTreeBase";
|
|
7
|
-
|
|
8
|
-
.tree-widget-categories-tree {
|
|
9
|
-
@include tree-widget-visibility-tree-base;
|
|
10
|
-
}
|
|
11
|
-
|
|
12
|
-
.tree-widget-category-tree-search-bar {
|
|
13
|
-
margin-bottom: $uicore-s;
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
.tree-widget-category-tree-toolbar-icon {
|
|
17
|
-
color: $buic-icon-color;
|
|
18
|
-
}
|
|
@@ -1,15 +0,0 @@
|
|
|
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 React from "react";
|
|
6
|
-
import { SpatialContainmentTree, useActiveIModelConnection } from "@itwin/appui-react";
|
|
7
|
-
import { AutoSizer } from "../../utils/AutoSizer";
|
|
8
|
-
export const SpatialTreeComponent = (props) => {
|
|
9
|
-
const iModel = useActiveIModelConnection();
|
|
10
|
-
return (React.createElement(React.Fragment, null, iModel &&
|
|
11
|
-
React.createElement(AutoSizer, null,
|
|
12
|
-
// eslint-disable-next-line deprecation/deprecation
|
|
13
|
-
({ width, height }) => React.createElement(SpatialContainmentTree, { ...props, width: width, height: height, iModel: iModel }))));
|
|
14
|
-
};
|
|
15
|
-
//# sourceMappingURL=SpatialTreeComponent.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"SpatialTreeComponent.js","sourceRoot":"","sources":["../../../../../src/components/trees/spatial-tree/SpatialTreeComponent.tsx"],"names":[],"mappings":"AAAA;;;+FAG+F;AAE/F,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,sBAAsB,EAAE,yBAAyB,EAAE,MAAM,oBAAoB,CAAC;AACvF,OAAO,EAAE,SAAS,EAAE,MAAM,uBAAuB,CAAC;AAIlD,MAAM,CAAC,MAAM,oBAAoB,GAAG,CAClC,KAAuB,EAAE,EAAE;IAC3B,MAAM,MAAM,GAAG,yBAAyB,EAAE,CAAC;IAE3C,OAAO,CACL,0CACG,MAAM;QACL,oBAAC,SAAS;QAEN,mDAAmD;QACnD,CAAC,EAAE,KAAK,EAAE,MAAM,EAAE,EAAE,EAAE,CAAC,oBAAC,sBAAsB,OAAK,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,GAAI,CAElG,CAEb,CACJ,CAAC;AACJ,CAAC,CAAC","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\nimport React from \"react\";\nimport { SpatialContainmentTree, useActiveIModelConnection } from \"@itwin/appui-react\";\nimport { AutoSizer } from \"../../utils/AutoSizer\";\n\nimport type { SpatialTreeProps } from \"../../../types\";\n\nexport const SpatialTreeComponent = (\n props: SpatialTreeProps) => {\n const iModel = useActiveIModelConnection();\n\n return (\n <>\n {iModel &&\n <AutoSizer>\n {\n // eslint-disable-next-line deprecation/deprecation\n ({ width, height }) => <SpatialContainmentTree {...props} width={width} height={height} iModel={iModel} />\n }\n </AutoSizer>\n }\n </>\n );\n};\n"]}
|