@adaptabletools/adaptable 17.0.0-canary.6 → 17.0.0-canary.8
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/base.css +14 -0
- package/base.css.map +1 -1
- package/bundle.cjs.js +128 -128
- package/index.css +16 -0
- package/index.css.map +1 -1
- package/package.json +1 -1
- package/publishTimestamp.d.ts +1 -1
- package/publishTimestamp.js +1 -1
- package/src/AdaptableInterfaces/IAdaptable.d.ts +1 -0
- package/src/AdaptableOptions/EditOptions.d.ts +6 -6
- package/src/AdaptableOptions/GridFilterOptions.d.ts +8 -3
- package/src/Api/GridFilterApi.d.ts +2 -2
- package/src/Api/Implementation/GridFilterApiImpl.d.ts +1 -1
- package/src/Api/Implementation/GridFilterApiImpl.js +1 -1
- package/src/Api/Internal/LayoutInternalApi.d.ts +2 -2
- package/src/Api/Internal/LayoutInternalApi.js +11 -11
- package/src/Utilities/Defaults/DefaultAdaptableOptions.js +1 -1
- package/src/Utilities/ExpressionFunctions/booleanExpressionFunctions.js +6 -0
- package/src/Utilities/Services/ValidationService.js +11 -11
- package/src/View/Components/Selectors/PermittedValuesSelector.d.ts +5 -4
- package/src/View/Components/Selectors/PermittedValuesSelector.js +25 -3
- package/src/View/GridFilter/GridFilterViewPanel.js +4 -2
- package/src/View/GridFilter/useGridFilterExpressionEditor.js +1 -1
- package/src/View/GridFilter/useGridFilterOptionsForExpressionEditor.js +5 -23
- package/src/View/Layout/Wizard/sections/GridFilterSection.js +4 -4
- package/src/View/NamedQuery/EditCurrentQueryButton.js +1 -1
- package/src/agGrid/Adaptable.d.ts +4 -0
- package/src/agGrid/Adaptable.js +3 -18
- package/src/components/ExpressionEditor/QueryBuilder/QueryBuilderInputs.d.ts +6 -0
- package/src/components/ExpressionEditor/QueryBuilder/QueryBuilderInputs.js +7 -1
- package/src/components/ExpressionEditor/QueryBuilder/QueryPredicateBuilder.js +14 -2
- package/src/components/ExpressionEditor/QueryBuilder/booleanExpressions.js +1 -0
- package/src/components/ExpressionEditor/QueryBuilder/utils.js +1 -1
- package/src/components/Select/Select.js +45 -20
- package/src/metamodel/adaptable.metamodel.d.ts +35 -28
- package/src/metamodel/adaptable.metamodel.js +1 -1
- package/src/parser/src/predicate/mapQlPredicateToExpression.js +5 -2
- package/src/parser/src/predicate/types.d.ts +1 -1
- package/src/parser/src/types.d.ts +1 -1
- package/src/renderReactRoot.js +11 -2
- package/src/types.d.ts +2 -2
- package/version.d.ts +1 -1
- package/version.js +1 -1
|
@@ -37,7 +37,7 @@ function mapQlPredicateToExpression(predicate) {
|
|
|
37
37
|
}
|
|
38
38
|
return `"${arg}"`;
|
|
39
39
|
}
|
|
40
|
-
if (typeof arg === 'object') {
|
|
40
|
+
if (typeof arg === 'object' && 'operator' in arg) {
|
|
41
41
|
if ((0, types_1.isQlLogicalOperator)(arg.operator)) {
|
|
42
42
|
return `(${mapQlPredicateToExpression(arg)})`;
|
|
43
43
|
}
|
|
@@ -48,7 +48,7 @@ function mapQlPredicateToExpression(predicate) {
|
|
|
48
48
|
}
|
|
49
49
|
return arg;
|
|
50
50
|
});
|
|
51
|
-
if (typeof firstArg === 'object') {
|
|
51
|
+
if (typeof firstArg === 'object' && 'operator' in firstArg) {
|
|
52
52
|
firstArg = mapQlPredicateToExpression(firstArg);
|
|
53
53
|
}
|
|
54
54
|
if ((0, types_1.isQlLogicalOperator)(operator)) {
|
|
@@ -61,6 +61,9 @@ function mapQlPredicateToExpression(predicate) {
|
|
|
61
61
|
if (operator === 'BETWEEN') {
|
|
62
62
|
return `${firstArg} ${operatorSymbol} (${mappedArgs})`;
|
|
63
63
|
}
|
|
64
|
+
if (operator === 'IN') {
|
|
65
|
+
return `${firstArg} ${operatorSymbol} (${mappedArgs.join(', ')})`;
|
|
66
|
+
}
|
|
64
67
|
return `${firstArg} ${operatorSymbol} ${mappedArgs.join(', ')}`;
|
|
65
68
|
}
|
|
66
69
|
if (predicateType === 'FUNCTION') {
|
|
@@ -4,7 +4,7 @@ export type QlPredicateError = {
|
|
|
4
4
|
};
|
|
5
5
|
export interface QlPredicate {
|
|
6
6
|
operator: BooleanFunctionName;
|
|
7
|
-
args?: (QlPredicate | boolean | number | string)[];
|
|
7
|
+
args?: (QlPredicate | boolean | number | string | string[] | number[] | Date[])[];
|
|
8
8
|
}
|
|
9
9
|
export type QlLogicalOperator = 'AND' | 'OR';
|
|
10
10
|
export declare const isQlLogicalOperator: (operator: string) => operator is QlLogicalOperator;
|
|
@@ -96,7 +96,7 @@ export interface ExpressionFunction {
|
|
|
96
96
|
/**
|
|
97
97
|
* Data Types of Inputs used by Expression (test, number, date, boolean)
|
|
98
98
|
*/
|
|
99
|
-
export type ExpressionFunctionInputType = 'text' | 'number' | 'date' | 'boolean';
|
|
99
|
+
export type ExpressionFunctionInputType = 'text' | 'number' | 'date' | 'boolean' | 'number[]' | 'date[]' | 'text[]';
|
|
100
100
|
/**
|
|
101
101
|
* Categories for Expression Functions
|
|
102
102
|
*/
|
package/src/renderReactRoot.js
CHANGED
|
@@ -3,11 +3,20 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
exports.renderReactRoot = void 0;
|
|
4
4
|
const tslib_1 = require("tslib");
|
|
5
5
|
const ReactDOMClient = tslib_1.__importStar(require("react-dom/client"));
|
|
6
|
+
const renderWeakMap = new WeakMap();
|
|
6
7
|
const renderReactRoot = (el, container) => {
|
|
7
|
-
|
|
8
|
+
let root = renderWeakMap.get(container);
|
|
9
|
+
if (!root) {
|
|
10
|
+
renderWeakMap.set(container, (root = ReactDOMClient.createRoot(container)));
|
|
11
|
+
}
|
|
8
12
|
root.render(el);
|
|
9
13
|
return () => {
|
|
10
|
-
|
|
14
|
+
requestAnimationFrame(() => {
|
|
15
|
+
// This pervents this warning:
|
|
16
|
+
// Warning: Attempted to synchronously unmount a root while React was already rendering. React cannot finish unmounting the root until the current render has completed, which may lead to a race condition.
|
|
17
|
+
// https:stackoverflow.com/questions/73459382/react-18-async-way-to-unmount-root
|
|
18
|
+
root.unmount();
|
|
19
|
+
});
|
|
11
20
|
};
|
|
12
21
|
};
|
|
13
22
|
exports.renderReactRoot = renderReactRoot;
|
package/src/types.d.ts
CHANGED
|
@@ -14,7 +14,7 @@ export type { FlashingCellOptions } from './AdaptableOptions/FlashingCellOptions
|
|
|
14
14
|
export type { TOAST_POSITIONS, NotificationsOptions, } from './AdaptableOptions/NotificationsOptions';
|
|
15
15
|
export type { AlertOptions, ActionHandler, AlertForm, AlertFormContext, AlertMessageContext, } from './AdaptableOptions/AlertOptions';
|
|
16
16
|
export type { DashboardOptions, CustomToolbar, DashboardButtonContext, CustomToolbarButtonContext, } from './AdaptableOptions/DashboardOptions';
|
|
17
|
-
export type { EditOptions,
|
|
17
|
+
export type { EditOptions, ServerValidationResult, SmartEditCustomOperation, SmartEditOperation, SmartEditOperationContext, ServerValidationContext, CellEditableContext, } from './AdaptableOptions/EditOptions';
|
|
18
18
|
export type { ActionRowOptions, ActionRowButtonOptions, ActionRowFormOptions, ActionRowParamContext, ActionRowParamFieldContext, CreateActionRowFormContext, EditActionRowFormContext, ActionRowFormContext, ActionRowType, ActionRowButtonType, ActionRowButtonConfigurationContext, ActionRowButtonsContext, SetPrimaryKeyValueContext, ActionRowFormColumnContext, } from './AdaptableOptions/ActionRowOptions';
|
|
19
19
|
export type { ActionColumnContext, ActionColumn, ActionColumnSettings, ActionColumnOptions, } from './AdaptableOptions/ActionColumnOptions';
|
|
20
20
|
export type { ExportOptions, SystemExportDestination, SystemExportDestinations, CustomDestination, ExternalReport, PreProcessExportContext, AdaptableReportColumn, DataFormatType, ExportFormContext, ReportContext, ExportableColumnContext, ReportFileNameContext, } from './AdaptableOptions/ExportOptions';
|
|
@@ -34,7 +34,7 @@ export type { MasterDetailPluginOptions, DetailInitContext, } from './AdaptableO
|
|
|
34
34
|
export type { FinsemblePluginOptions, FinsemblePluginStateOptions, } from './AdaptableOptions/FinsemblePluginOptions';
|
|
35
35
|
export type { DateInputOptions } from './AdaptableOptions/DateInputOptions';
|
|
36
36
|
export type { ColumnFilterOptions, QuickFilterOptions, FilterFormOptions, ValuesFilterOptions, ColumnFilterContext, } from './AdaptableOptions/ColumnFilterOptions';
|
|
37
|
-
export type { GridFilterOptions } from './AdaptableOptions/GridFilterOptions';
|
|
37
|
+
export type { GridFilterOptions, GridFilterEditors, GridFilterEditor } from './AdaptableOptions/GridFilterOptions';
|
|
38
38
|
export type { QuickSearchOptions, QuickSearchContext } from './AdaptableOptions/QuickSearchOptions';
|
|
39
39
|
export type { FormatColumnOptions, CustomDisplayFormatter, CustomDisplayFormatterContext, } from './AdaptableOptions/FormatColumnOptions';
|
|
40
40
|
export type { ColumnOptions, ColumnFriendlyNameContext } from './AdaptableOptions/ColumnOptions';
|
package/version.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
declare const _default: "17.0.0-canary.
|
|
1
|
+
declare const _default: "17.0.0-canary.8";
|
|
2
2
|
export default _default;
|
package/version.js
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.default = '17.0.0-canary.
|
|
3
|
+
exports.default = '17.0.0-canary.8'; // PLEASE DONT UPDATE THIS!!! - will be updated at build time with the correct version
|