mirror of
https://github.com/dbeaver/cloudbeaver.git
synced 2026-09-24 16:04:36 +08:00
feat(core-app): CB-1587 nav tree elements limit message
This commit is contained in:
+7
-3
@@ -6,11 +6,14 @@
|
||||
* you may not use this file except in compliance with the License.
|
||||
*/
|
||||
|
||||
import { observer } from 'mobx-react-lite';
|
||||
import styled, { css } from 'reshadow';
|
||||
|
||||
import { useService } from '@cloudbeaver/core-di';
|
||||
import { Translate } from '@cloudbeaver/core-localization';
|
||||
import { composes, useStyles } from '@cloudbeaver/core-theming';
|
||||
|
||||
import { NavTreeResource } from '../../shared/NodesManager/NavTreeResource';
|
||||
import type { NavigationNodeRendererComponent } from '../NavigationNodeComponent';
|
||||
import { NAVIGATION_TREE_LIMIT } from './elementsTreeLimitFilter';
|
||||
|
||||
@@ -36,6 +39,7 @@ const styles = composes(
|
||||
`
|
||||
);
|
||||
|
||||
const ManageableGroup: NavigationNodeRendererComponent = function ManageableGroup() {
|
||||
return styled(useStyles(styles))(<connection-group><Translate token='app_navigationTree_limited' /></connection-group>);
|
||||
};
|
||||
const ManageableGroup: NavigationNodeRendererComponent = observer(function ManageableGroup() {
|
||||
const navTreeResource = useService(NavTreeResource);
|
||||
return styled(useStyles(styles))(<connection-group><Translate token='app_navigationTree_limited' limit={navTreeResource.childrenLimit} /></connection-group>);
|
||||
});
|
||||
|
||||
@@ -12,7 +12,7 @@ export default [
|
||||
['app_topnavbar_connection_schema_manager_not_selected', '-- not selected --'],
|
||||
['app_navigationTree_openNodeTab', 'Open'],
|
||||
['app_navigationTree_search', 'Search elements...'],
|
||||
['app_navigationTree_limited', 'Some elements were hidden'],
|
||||
['app_navigationTree_limited', 'Elements are limited to ${args.limit} items'],
|
||||
['app_navigationTree_settings_title', 'Settings'],
|
||||
['app_navigationTree_settings_filter_title', 'Filter'],
|
||||
['app_navigationTree_settings_filter_description', 'Show filtering field'],
|
||||
|
||||
@@ -12,7 +12,7 @@ export default [
|
||||
['app_topnavbar_connection_schema_manager_not_selected', '-- non selezionato --'],
|
||||
['app_navigationTree_openNodeTab', 'Apri'],
|
||||
['app_navigationTree_search', 'Search elements...'],
|
||||
['app_navigationTree_limited', 'Some elements were hidden'],
|
||||
['app_navigationTree_limited', 'Elements are limited to ${args.limit} items'],
|
||||
['app_navigationTree_settings_title', 'Settings'],
|
||||
['app_navigationTree_settings_filter_title', 'Filter'],
|
||||
['app_navigationTree_settings_filter_description', 'Show filtering field'],
|
||||
|
||||
@@ -15,7 +15,7 @@ export default [
|
||||
],
|
||||
['app_navigationTree_openNodeTab', 'Открыть'],
|
||||
['app_navigationTree_search', 'Искать элементы...'],
|
||||
['app_navigationTree_limited', 'Некоторые элементы были скрыты'],
|
||||
['app_navigationTree_limited', 'Отображено ${args.limit} элементов'],
|
||||
|
||||
['app_navigationTree_settings_title', 'Настройки'],
|
||||
['app_navigationTree_settings_filter_title', 'Фильтр'],
|
||||
|
||||
@@ -11,7 +11,7 @@ export default [
|
||||
['app_shared_settingsMenu_lang', '语言'],
|
||||
['app_topnavbar_connection_schema_manager_not_selected', '-- 为选择 --'],
|
||||
['app_navigationTree_search', 'Search elements...'],
|
||||
['app_navigationTree_limited', 'Some elements were hidden'],
|
||||
['app_navigationTree_limited', 'Elements are limited to ${args.limit} items'],
|
||||
['app_navigationTree_settings_title', 'Settings'],
|
||||
['app_navigationTree_settings_filter_title', 'Filter'],
|
||||
['app_navigationTree_settings_filter_description', 'Show filtering field'],
|
||||
|
||||
Reference in New Issue
Block a user