feat(plugin-aws-cloud-explorer): CB-830 select all select only visible nodes now

This commit is contained in:
Naumov Alexey
2021-03-22 14:45:31 +03:00
parent fe3abb37e8
commit f162a98b7d
2 changed files with 26 additions and 0 deletions
@@ -0,0 +1,25 @@
/*
* CloudBeaver - Cloud Database Manager
* Copyright (C) 2020-2021 DBeaver Corp and others
*
* Licensed under the Apache License, Version 2.0.
* you may not use this file except in compliance with the License.
*/
export function declensionOfNumber(value: number, words: string[]) {
value = Math.abs(value) % 100;
const num = value % 10;
if (value > 10 && value < 20) {
return words[2];
}
if (num > 1 && num < 5) {
return words[1];
}
if (num === 1) {
return words[0];
}
return words[2];
}
+1
View File
@@ -7,6 +7,7 @@ export * from './generateFileName';
export * from './md5';
export * from './TextTools';
export * from './copyToClipboard';
export * from './declensionOfNumber';
export * from './Promises/CancellablePromise';
export * from './Promises/Deferred';