ydb-embedded-ui 1.13.1 → 1.13.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/CHANGELOG.md CHANGED
@@ -1,5 +1,14 @@
1
1
  # Changelog
2
2
 
3
+ ## [1.13.2](https://github.com/ydb-platform/ydb-embedded-ui/compare/v1.13.1...v1.13.2) (2022-09-05)
4
+
5
+
6
+ ### Bug Fixes
7
+
8
+ * **Tenant:** fix acl scroll ([161bc8d](https://github.com/ydb-platform/ydb-embedded-ui/commit/161bc8d507de126c1383a10713e2ffaaaf13301d))
9
+ * **Tenant:** fix layout after moving tabs ([6abfded](https://github.com/ydb-platform/ydb-embedded-ui/commit/6abfdedb97345b555be306d49ea2454f35de9bb4))
10
+ * **Tenant:** load root if cahced path is not in tree ([2d86044](https://github.com/ydb-platform/ydb-embedded-ui/commit/2d8604464711a638dbd20cf8a14142b0de3e3a95))
11
+
3
12
  ## [1.13.1](https://github.com/ydb-platform/ydb-embedded-ui/compare/v1.13.0...v1.13.1) (2022-09-02)
4
13
 
5
14
 
@@ -13,6 +13,12 @@ const b = cn('kv-acl');
13
13
 
14
14
  const COLUMN_WIDTH = 140;
15
15
 
16
+ const TABLE_SETTINGS = {
17
+ ...DEFAULT_TABLE_SETTINGS,
18
+ dynamicRender: false,
19
+ stickyTop: 36,
20
+ };
21
+
16
22
  class Acl extends React.Component {
17
23
  static propTypes = {
18
24
  error: PropTypes.string,
@@ -81,7 +87,7 @@ class Acl extends React.Component {
81
87
  <DataTable
82
88
  columns={this.COLUMNS}
83
89
  data={acl}
84
- settings={{...DEFAULT_TABLE_SETTINGS, stickyTop: 36}}
90
+ settings={TABLE_SETTINGS}
85
91
  />
86
92
  );
87
93
  };
@@ -7,7 +7,7 @@
7
7
  flex: 1 1 auto;
8
8
  flex-direction: column;
9
9
 
10
- height: calc(100% - 56px);
10
+ height: 100%;
11
11
 
12
12
  @include query-data-table;
13
13
 
@@ -1,3 +1,4 @@
1
+ import {useEffect} from 'react';
1
2
  import {useDispatch} from 'react-redux';
2
3
 
3
4
  import {NavigationTree} from 'ydb-ui-components';
@@ -48,6 +49,13 @@ export function SchemaTree(props: SchemaTreeProps) {
48
49
  dispatch(getSchemaAcl({path: activePath}));
49
50
  };
50
51
 
52
+ useEffect(() => {
53
+ // if the cached path is not in the current tree, show root
54
+ if (!currentPath.startsWith(rootPath)) {
55
+ handleActivePathUpdate(rootPath);
56
+ }
57
+ }, []);
58
+
51
59
  return (
52
60
  <NavigationTree
53
61
  rootState={{
@@ -11,55 +11,7 @@
11
11
  overflow: initial;
12
12
  }
13
13
 
14
- &__loader {
15
- display: flex;
16
- flex: 1 1 auto;
17
- justify-content: center;
18
- align-items: center;
19
- }
20
-
21
- &__content {
22
- overflow: auto;
23
- @include flex-container();
24
- }
25
-
26
- &__storage {
27
- overflow: auto;
28
-
29
- height: 100%;
30
- padding-left: 20px;
31
- }
32
-
33
- &__row {
34
- display: flex;
35
- align-items: flex-start;
36
-
37
- &_schema {
38
- height: 100%;
39
- }
40
-
41
- &_schema-tags {
42
- align-items: center;
43
- }
44
- }
45
-
46
- &__schema-wrapper {
47
- overflow: auto;
48
-
49
- min-width: 300px;
50
- height: 100%;
51
- padding-top: 15px;
52
- padding-left: 8px;
53
- }
54
-
55
- &__schema-tabs-wrapper {
56
- overflow: auto;
57
-
58
- width: 100%;
59
- height: 100%;
60
- padding: 15px 0 0 15px;
61
-
62
- border-left: 1px solid rgba(0, 0, 0, 0.07);
63
- @include flex-container();
14
+ &__tab-content {
15
+ height: calc(100% - 56px); // general tabs height
64
16
  }
65
17
  }
@@ -134,28 +134,30 @@ function Tenant(props: TenantProps) {
134
134
  ) : (
135
135
  <>
136
136
  <ObjectGeneralTabs />
137
- <SplitPane
138
- defaultSizePaneKey={DEFAULT_SIZE_TENANT_KEY}
139
- defaultSizes={[25, 75]}
140
- triggerCollapse={summaryVisibilityState.triggerCollapse}
141
- triggerExpand={summaryVisibilityState.triggerExpand}
142
- minSize={[36, 200]}
143
- onSplitStartDragAdditional={onSplitStartDragAdditional}
144
- >
145
- <ObjectSummary
146
- type={currentPathType}
147
- subType={currentPathSubType}
148
- onCollapseSummary={onCollapseSummaryHandler}
149
- onExpandSummary={onExpandSummaryHandler}
150
- isCollapsed={summaryVisibilityState.collapsed}
151
- additionalTenantInfo={props.additionalTenantInfo}
152
- />
153
- <ObjectGeneral
154
- type={currentPathType}
155
- additionalTenantInfo={props.additionalTenantInfo}
156
- additionalNodesInfo={props.additionalNodesInfo}
157
- />
158
- </SplitPane>
137
+ <div className={b('tab-content')}>
138
+ <SplitPane
139
+ defaultSizePaneKey={DEFAULT_SIZE_TENANT_KEY}
140
+ defaultSizes={[25, 75]}
141
+ triggerCollapse={summaryVisibilityState.triggerCollapse}
142
+ triggerExpand={summaryVisibilityState.triggerExpand}
143
+ minSize={[36, 200]}
144
+ onSplitStartDragAdditional={onSplitStartDragAdditional}
145
+ >
146
+ <ObjectSummary
147
+ type={currentPathType}
148
+ subType={currentPathSubType}
149
+ onCollapseSummary={onCollapseSummaryHandler}
150
+ onExpandSummary={onExpandSummaryHandler}
151
+ isCollapsed={summaryVisibilityState.collapsed}
152
+ additionalTenantInfo={props.additionalTenantInfo}
153
+ />
154
+ <ObjectGeneral
155
+ type={currentPathType}
156
+ additionalTenantInfo={props.additionalTenantInfo}
157
+ additionalNodesInfo={props.additionalNodesInfo}
158
+ />
159
+ </SplitPane>
160
+ </div>
159
161
  </>
160
162
  )}
161
163
  </div>
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ydb-embedded-ui",
3
- "version": "1.13.1",
3
+ "version": "1.13.2",
4
4
  "files": [
5
5
  "dist"
6
6
  ],