@devexpress/analytics-core 26.1.7-build-26318-0102 → 26.2.2-beta
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/README.md +7 -7
- package/accessibility/_accordionKeyboardHelper.d.ts +1 -0
- package/accessibility/_accordionKeyboardHelper.js +6 -3
- package/accessibility/_dxMutationObserver.js +11 -4
- package/accessibility/_keyboardHelperBase.d.ts +1 -0
- package/accessibility/_keyboardHelperBase.js +14 -4
- package/accessibility/_toolbarKeyboardHelper.d.ts +5 -5
- package/accessibility/_toolbarKeyboardHelper.js +12 -20
- package/accessibility/_treeListKeyboardHelper.d.ts +2 -2
- package/analytics-diagram.d.ts +6 -4
- package/analytics-diagram.js +6 -4
- package/analytics-elements.d.ts +4 -2
- package/analytics-elements.js +4 -2
- package/analytics-internal-native.d.ts +2 -4
- package/analytics-internal-native.js +2 -4
- package/analytics-internal.d.ts +8 -8
- package/analytics-internal.js +8 -8
- package/analytics-serializer-native.d.ts +8 -2
- package/analytics-serializer-native.js +8 -2
- package/analytics-utils-native.d.ts +2 -0
- package/analytics-utils-native.js +2 -0
- package/analytics-utils.d.ts +2 -2
- package/analytics-utils.js +2 -2
- package/analytics-version.js +1 -1
- package/analytics-widgets-filtering.d.ts +2 -0
- package/analytics-widgets-filtering.js +2 -0
- package/analytics-widgets-internal.d.ts +6 -10
- package/analytics-widgets-internal.js +6 -10
- package/analytics-widgets.d.ts +10 -0
- package/analytics-widgets.js +10 -0
- package/analytics-wizard-internal.d.ts +4 -2
- package/analytics-wizard-internal.js +4 -2
- package/bundle/_validator.js +3 -3
- package/core/_actionProvider.d.ts +3 -3
- package/core/_actionProvider.js +4 -11
- package/core/_actionsProvider.interface.d.ts +2 -2
- package/core/_bindings.d.ts +9 -1
- package/core/_bindings.js +103 -117
- package/core/binding/_jsDesignerBindingCommon.js +4 -4
- package/core/dragDrop/_dragDropHandler.d.ts +7 -8
- package/core/dragDrop/_dragDropHandler.js +20 -20
- package/core/dragDrop/_dragHelperContent.d.ts +18 -10
- package/core/dragDrop/_dragHelperContent.js +52 -23
- package/core/dragDrop/_selectionDragDropHandler.d.ts +1 -2
- package/core/dragDrop/_selectionDragDropHandler.js +17 -17
- package/core/dragDrop/_toolboxDragDropHandler.d.ts +1 -2
- package/core/dragDrop/_toolboxDragDropHandler.js +6 -5
- package/core/dragDrop/_wizardDragDropHandler.js +5 -6
- package/core/elements/baseSerializableModel.d.ts +9 -0
- package/core/elements/baseSerializableModel.js +14 -0
- package/core/elements/baseSurface.d.ts +106 -31
- package/core/elements/baseSurface.js +298 -137
- package/core/elements/elementModel.d.ts +102 -0
- package/core/elements/elementModel.js +256 -0
- package/core/elements/margins.d.ts +10 -10
- package/core/elements/margins.js +8 -7
- package/core/elements/paddingModel.d.ts +22 -17
- package/core/elements/paddingModel.js +34 -45
- package/core/elements/point.d.ts +7 -7
- package/core/elements/point.js +7 -5
- package/core/elements/rectangle.d.ts +18 -6
- package/core/elements/rectangle.js +34 -11
- package/core/elements/serializableModel.d.ts +4 -2
- package/core/elements/serializableModel.js +4 -5
- package/core/elements/size.d.ts +16 -6
- package/core/elements/size.js +7 -5
- package/core/internal/_arrayStores.d.ts +2 -2
- package/core/internal/_arrayStores.js +1 -2
- package/core/internal/_controlsHelper.d.ts +16 -12
- package/core/internal/_controlsHelper.js +62 -46
- package/core/internal/_cssCalculator.d.ts +39 -10
- package/core/internal/_cssCalculator.js +62 -64
- package/core/internal/_dimensionNotationsModel.d.ts +28 -8
- package/core/internal/_dimensionNotationsModel.js +65 -30
- package/core/internal/_draggable.d.ts +1 -0
- package/core/internal/_draggable.js +4 -1
- package/core/internal/_getNameHelpers.d.ts +1 -1
- package/core/internal/_getNameHelpers.js +4 -3
- package/core/internal/_hoverInfo.d.ts +10 -7
- package/core/internal/_hoverInfo.js +19 -16
- package/core/internal/_inlineTextEdit.d.ts +21 -6
- package/core/internal/_inlineTextEdit.js +67 -34
- package/core/internal/_ko_integration.d.ts +18 -14
- package/core/internal/_ko_integration.js +48 -79
- package/core/internal/_objectStructureControllers.d.ts +9 -7
- package/core/internal/_objectStructureProviders.d.ts +25 -9
- package/core/internal/_objectStructureProviders.js +113 -48
- package/core/internal/_processError.js +1 -1
- package/core/internal/_resizable.d.ts +27 -22
- package/core/internal/_resizable.js +37 -36
- package/core/internal/_resizableBinding.js +39 -34
- package/core/internal/_stores.d.ts +23 -9
- package/core/internal/_stores.js +50 -17
- package/core/internal/_surfaceHelpers.d.ts +3 -4
- package/core/internal/_surfaceHelpers.js +4 -4
- package/core/internal/_utils.d.ts +2 -1
- package/core/internal/_utils.js +1 -0
- package/core/internal/_validation.d.ts +1 -6
- package/core/internal/dxtTemplate.js +1 -1
- package/core/selection/_combinedObj.d.ts +23 -8
- package/core/selection/_combinedObj.js +114 -55
- package/core/selection/_selection.d.ts +33 -25
- package/core/selection/_selection.js +61 -57
- package/core/selection/_selectionHelpers.js +5 -5
- package/core/snapLines/_snapLineSurface.js +3 -4
- package/core/snapLines/_snapLinesCollector.d.ts +1 -2
- package/core/snapLines/_snapLinesCollector.js +2 -2
- package/core/snapLines/_snapLinesHelper.d.ts +14 -3
- package/core/snapLines/_snapLinesHelper.js +27 -4
- package/core/tools/_actionList.d.ts +5 -5
- package/core/tools/_actionList.js +129 -98
- package/core/tools/_actionListBase.d.ts +20 -12
- package/core/tools/_actionListBase.js +69 -54
- package/core/tools/_actionListBase.viewModel.d.ts +1 -0
- package/core/tools/_actionListBase.viewModel.js +48 -25
- package/core/tools/_copyPaste.d.ts +6 -7
- package/core/tools/_copyPaste.js +34 -32
- package/core/tools/_keyboardHelper.d.ts +8 -6
- package/core/tools/_keyboardHelper.js +58 -37
- package/core/tools/_tabInfoWithPropertyGrid.d.ts +5 -2
- package/core/tools/_tabInfoWithPropertyGrid.js +18 -12
- package/core/tools/contextMenuProvider.d.ts +25 -12
- package/core/tools/contextMenuProvider.js +39 -13
- package/core/tools/toolbox.d.ts +15 -3
- package/core/tools/toolbox.js +32 -4
- package/core/utils/_arrayutils.compareArrays.d.ts +1 -0
- package/core/utils/_arrayutils.compareArrays.js +7 -8
- package/core/utils/_arrayutils.d.ts +7 -5
- package/core/utils/_arrayutils.js +69 -73
- package/core/utils/_designerCreator.d.ts +56 -110
- package/core/utils/_designerCreator.js +173 -167
- package/core/utils/_designerInitializer.d.ts +5 -4
- package/core/utils/_designerInitializer.js +47 -37
- package/core/utils/_designerRootViewModel.d.ts +148 -0
- package/core/utils/_designerRootViewModel.js +243 -0
- package/core/utils/_fieldListProvider.d.ts +5 -2
- package/core/utils/_fieldListProvider.js +10 -7
- package/core/utils/_subscribeProperty.d.ts +21 -0
- package/core/utils/_subscribeProperty.js +56 -0
- package/core/utils/_testHelpers.d.ts +2 -0
- package/core/utils/_testHelpers.js +16 -0
- package/core/utils/_units.d.ts +2 -5
- package/core/utils/_units.js +1 -30
- package/core/utils/_utils.d.ts +3 -2
- package/core/utils/_utils.designerPart.d.ts +1 -0
- package/core/utils/_utils.designerPart.js +4 -1
- package/core/utils/_utils.getResizableOptions.d.ts +2 -2
- package/core/utils/_utils.getResizableOptions.js +12 -20
- package/core/utils/_utils.js +31 -15
- package/core/utils/_utils.staticContext.d.ts +22 -6
- package/core/utils/_utils.staticContext.js +2 -0
- package/core/utils/_visitors.d.ts +1 -1
- package/core/utils/_visitors.js +7 -8
- package/core/utils/controlsFactory.d.ts +2 -2
- package/core/utils/controlsFactory.js +2 -2
- package/core/utils/parsers.d.ts +4 -5
- package/core/utils/parsers.js +10 -15
- package/core/widgets/_criteriaPopupEditorBase.d.ts +13 -6
- package/core/widgets/_criteriaPopupEditorBase.js +39 -9
- package/core/widgets/_dataMemberEditor.d.ts +8 -8
- package/core/widgets/_dataMemberEditor.js +5 -3
- package/core/widgets/_displayNameBindings.d.ts +2 -0
- package/core/widgets/_displayNameBindings.js +14 -0
- package/core/widgets/_fieldlistpicker.d.ts +11 -5
- package/core/widgets/_fieldlistpicker.js +58 -43
- package/core/widgets/_popupEditorBase.d.ts +30 -11
- package/core/widgets/_popupEditorBase.js +65 -17
- package/core/widgets/_requiredNullableEditor.d.ts +3 -4
- package/core/widgets/_requiredNullableEditor.js +2 -6
- package/core/widgets/booleanEditor.d.ts +1 -7
- package/core/widgets/booleanEditor.js +3 -8
- package/core/widgets/bordereditor/_bordereditor.d.ts +30 -20
- package/core/widgets/bordereditor/_bordereditor.js +97 -48
- package/core/widgets/colorPickerEditor.d.ts +7 -9
- package/core/widgets/colorPickerEditor.js +30 -25
- package/core/widgets/criteriaStringEditor.d.ts +17 -0
- package/core/widgets/criteriaStringEditor.js +33 -0
- package/core/widgets/dataMemberEditor.d.ts +4 -3
- package/core/widgets/dataMemberEditor.js +5 -3
- package/core/widgets/expressionStringEditor.d.ts +4 -0
- package/core/widgets/expressionStringEditor.js +3 -0
- package/core/widgets/fieldListEditor.d.ts +21 -7
- package/core/widgets/fieldListEditor.js +68 -17
- package/core/widgets/filterStringEditor.d.ts +17 -0
- package/core/widgets/filterStringEditor.js +16 -0
- package/core/widgets/popover.d.ts +16 -3
- package/core/widgets/popover.js +66 -2
- package/core/widgets/propertygrid/_controlProperties.d.ts +37 -16
- package/core/widgets/propertygrid/_controlProperties.js +127 -55
- package/core/widgets/propertygrid/_controlProperties.viewModel.d.ts +39 -0
- package/core/widgets/propertygrid/_controlProperties.viewModel.js +64 -0
- package/core/widgets/propertygrid/_group.d.ts +25 -15
- package/core/widgets/propertygrid/_group.js +65 -35
- package/core/widgets/propertygrid/_group.viewModel.d.ts +20 -0
- package/core/widgets/propertygrid/_group.viewModel.js +30 -0
- package/core/widgets/registerDesignerEditors.d.ts +1 -1
- package/core/widgets/registerDesignerEditors.js +11 -7
- package/core/widgets/registerDesignerEditors.native.d.ts +1 -1
- package/core/widgets/registerDesignerEditors.native.js +22 -26
- package/core/widgets/tabInfo.d.ts +5 -0
- package/core/widgets/tabInfo.js +16 -2
- package/core/widgets/tabPanel.d.ts +2 -1
- package/core/widgets/tabPanel.js +16 -14
- package/core/widgets/textAlignmentEditor/_textAlignmentEditor.d.ts +8 -8
- package/core/widgets/textAlignmentEditor/_textAlignmentEditor.js +54 -31
- package/diagram/_diagramRootModel.d.ts +11 -0
- package/diagram/_diagramRootModel.js +23 -0
- package/diagram/bindings.js +4 -4
- package/diagram/controlRegistrator.js +17 -17
- package/diagram/dragDrop/connectingPointDragHandler.d.ts +3 -4
- package/diagram/dragDrop/connectingPointDragHandler.js +10 -10
- package/diagram/dragDrop/connectionPointDragHandler.d.ts +1 -2
- package/diagram/dragDrop/connectionPointDragHandler.js +12 -12
- package/diagram/elements/connectingPointModel.d.ts +9 -9
- package/diagram/elements/connectingPointModel.js +32 -30
- package/diagram/elements/connectingPointSurface.d.ts +9 -5
- package/diagram/elements/connectingPointSurface.js +21 -7
- package/diagram/elements/connectors/connectionPointModel.d.ts +9 -7
- package/diagram/elements/connectors/connectionPointModel.js +16 -20
- package/diagram/elements/connectors/connectionPointSurface.d.ts +24 -9
- package/diagram/elements/connectors/connectionPointSurface.js +28 -14
- package/diagram/elements/connectors/connectorModel.d.ts +11 -9
- package/diagram/elements/connectors/connectorModel.js +51 -56
- package/diagram/elements/connectors/connectorSurface.d.ts +16 -8
- package/diagram/elements/connectors/connectorSurface.js +30 -8
- package/diagram/elements/connectors/routedConnectorModel.d.ts +14 -9
- package/diagram/elements/connectors/routedConnectorModel.js +87 -54
- package/diagram/elements/connectors/routedConnectorSurface.d.ts +43 -16
- package/diagram/elements/connectors/routedConnectorSurface.js +84 -53
- package/diagram/elements/{diagramElementBaseViewModel.d.ts → diagramElementBaseModel.d.ts} +5 -4
- package/diagram/elements/{diagramElementBaseViewModel.js → diagramElementBaseModel.js} +2 -2
- package/diagram/elements/diagramElementBaseSurface.d.ts +15 -8
- package/diagram/elements/diagramElementBaseSurface.js +22 -20
- package/diagram/elements/diagramElementModel.d.ts +10 -0
- package/diagram/elements/diagramElementModel.js +13 -0
- package/diagram/elements/diagramElementSurface.d.ts +12 -4
- package/diagram/elements/diagramElementSurface.js +16 -0
- package/diagram/elements/diagramModel.d.ts +6 -7
- package/diagram/elements/diagramModel.js +15 -7
- package/diagram/elements/diagramSurface.d.ts +24 -16
- package/diagram/elements/diagramSurface.js +56 -27
- package/diagram/initializer.d.ts +3 -2
- package/diagram/initializer.js +20 -15
- package/diagram/utils.js +4 -4
- package/dist/css/dx-analytics.carmine.compact.css +13 -10
- package/dist/css/dx-analytics.carmine.css +13 -10
- package/dist/css/dx-analytics.common.css +37 -15
- package/dist/css/dx-analytics.contrast.compact.css +37 -10
- package/dist/css/dx-analytics.contrast.css +37 -10
- package/dist/css/dx-analytics.dark.compact.css +13 -10
- package/dist/css/dx-analytics.dark.css +13 -10
- package/dist/css/dx-analytics.darkmoon.compact.css +13 -10
- package/dist/css/dx-analytics.darkmoon.css +13 -10
- package/dist/css/dx-analytics.darkviolet.compact.css +13 -10
- package/dist/css/dx-analytics.darkviolet.css +13 -10
- package/dist/css/dx-analytics.greenmist.compact.css +13 -10
- package/dist/css/dx-analytics.greenmist.css +13 -10
- package/dist/css/dx-analytics.light.compact.css +12 -9
- package/dist/css/dx-analytics.light.css +12 -9
- package/dist/css/dx-analytics.material.blue.dark.compact.css +17 -14
- package/dist/css/dx-analytics.material.blue.dark.css +17 -14
- package/dist/css/dx-analytics.material.blue.light.compact.css +26 -23
- package/dist/css/dx-analytics.material.blue.light.css +26 -23
- package/dist/css/dx-analytics.material.lime.dark.compact.css +17 -14
- package/dist/css/dx-analytics.material.lime.dark.css +17 -14
- package/dist/css/dx-analytics.material.lime.light.compact.css +16 -13
- package/dist/css/dx-analytics.material.lime.light.css +16 -13
- package/dist/css/dx-analytics.material.orange.dark.compact.css +17 -14
- package/dist/css/dx-analytics.material.orange.dark.css +17 -14
- package/dist/css/dx-analytics.material.orange.light.compact.css +16 -13
- package/dist/css/dx-analytics.material.orange.light.css +16 -13
- package/dist/css/dx-analytics.material.purple.dark.compact.css +17 -14
- package/dist/css/dx-analytics.material.purple.dark.css +17 -14
- package/dist/css/dx-analytics.material.purple.light.compact.css +16 -13
- package/dist/css/dx-analytics.material.purple.light.css +16 -13
- package/dist/css/dx-analytics.material.teal.dark.compact.css +17 -14
- package/dist/css/dx-analytics.material.teal.dark.css +17 -14
- package/dist/css/dx-analytics.material.teal.light.compact.css +16 -13
- package/dist/css/dx-analytics.material.teal.light.css +16 -13
- package/dist/css/dx-analytics.softblue.compact.css +13 -10
- package/dist/css/dx-analytics.softblue.css +13 -10
- package/dist/css/dx-querybuilder.css +7 -7
- package/dist/html/templates.html +3423 -3461
- package/dist/js/dx-analytics-core.d.ts +8951 -7005
- package/dist/js/dx-analytics-core.js +16753 -12987
- package/dist/js/dx-analytics-core.min.js +8 -8
- package/dist/js/dx-querybuilder.js +6246 -3858
- package/dist/js/dx-querybuilder.min.js +8 -8
- package/dx-analytics-core-bindings.generated.js +158 -178
- package/dx-analytics-core-imports.d.ts +0 -1
- package/dx-analytics-core-imports.js +0 -1
- package/dx-analytics-core-templates.generated.js +73 -73
- package/dx-dev-analytics-core-svg-bindings.generated.js +2 -1
- package/dx-dev-analytics-core-svg-templates.generated.js +2 -1
- package/dx-query-builder-bindings.generated.js +181 -194
- package/dx-query-builder-templates.generated.js +75 -79
- package/less/colors/carmine-colors.less +36 -35
- package/less/colors/contrast-colors.less +36 -35
- package/less/colors/dark-colors.less +35 -34
- package/less/colors/darkmoon-colors.less +35 -34
- package/less/colors/darkviolet-colors.less +35 -34
- package/less/colors/greenmist-colors.less +35 -34
- package/less/colors/light-colors.less +35 -34
- package/less/colors/material.dark-colors.less +10 -9
- package/less/colors/material.light-colors.less +5 -4
- package/less/colors/softblue-colors.less +35 -34
- package/less/common.less +128 -128
- package/less/dx-carmine-style.less +2 -2
- package/less/dx-contrast-style.less +133 -95
- package/less/dx-dark-style.less +1 -1
- package/less/dx-darkmoon-style.less +2 -2
- package/less/dx-darkviolet-style.less +2 -2
- package/less/dx-greenmist-style.less +2 -2
- package/less/dx-light-style.less +1 -1
- package/less/dx-material.blue.dark-style.less +4 -4
- package/less/dx-material.blue.light-style.less +4 -4
- package/less/dx-material.dark.fix-varialbles.less +24 -24
- package/less/dx-material.fix-style.less +1344 -1344
- package/less/dx-material.light.fix-varialbles.less +6 -6
- package/less/dx-material.lime.dark-style.less +5 -5
- package/less/dx-material.lime.light-style.less +5 -5
- package/less/dx-material.orange.dark-style.less +5 -5
- package/less/dx-material.orange.light-style.less +5 -5
- package/less/dx-material.purple.dark-style.less +5 -5
- package/less/dx-material.purple.light-style.less +5 -5
- package/less/dx-material.teal.dark-style.less +5 -5
- package/less/dx-material.teal.light-style.less +5 -5
- package/less/dx-softblue-style.less +2 -2
- package/less/dx-variable-style.less +461 -456
- package/less/important.less +426 -426
- package/less/svg.less +42 -42
- package/license/_license.tools.d.ts +4 -0
- package/license/_license.tools.js +13 -5
- package/package.json +5 -5
- package/property-grid/_propertiesAccessibilityProvider.d.ts +10 -3
- package/property-grid/_propertiesAccessibilityProvider.js +24 -18
- package/property-grid/bindings.accordion.js +11 -30
- package/property-grid/bindings.d.ts +3 -6
- package/property-grid/bindings.js +65 -69
- package/property-grid/internal/_addon.d.ts +32 -14
- package/property-grid/internal/_addon.js +100 -40
- package/property-grid/internal/_popupService.d.ts +26 -8
- package/property-grid/internal/_popupService.js +60 -9
- package/property-grid/localization/_localization.d.ts +5 -5
- package/property-grid/localization/_localization.js +1 -1
- package/property-grid/localization/localization_utils.d.ts +1 -1
- package/property-grid/propertygrid.d.ts +67 -33
- package/property-grid/propertygrid.js +232 -140
- package/property-grid/widgets/_undoEditor.d.ts +15 -0
- package/property-grid/widgets/_undoEditor.js +45 -0
- package/property-grid/widgets/collectioneditor/_bindings.d.ts +8 -5
- package/property-grid/widgets/collectioneditor/_bindings.js +72 -15
- package/property-grid/widgets/collectioneditor/_editor.d.ts +11 -9
- package/property-grid/widgets/collectioneditor/_editor.js +68 -76
- package/property-grid/widgets/editor.d.ts +101 -56
- package/property-grid/widgets/editor.js +242 -185
- package/property-grid/widgets/editor.viewmodel.d.ts +2 -0
- package/property-grid/widgets/editor.viewmodel.js +82 -42
- package/property-grid/widgets/editorValidator.d.ts +9 -10
- package/property-grid/widgets/editorValidator.js +9 -2
- package/property-grid/widgets/editorsInfo.d.ts +1 -0
- package/property-grid/widgets/editorsInfo.js +9 -0
- package/property-grid/widgets/ellipsiseditor/_editor.d.ts +2 -2
- package/property-grid/widgets/ellipsiseditor/_editor.js +1 -0
- package/property-grid/widgets/fonteditor/_fonts.d.ts +1 -2
- package/property-grid/widgets/fonteditor/_fonts.js +2 -2
- package/property-grid/widgets/fonteditor/_model.d.ts +23 -14
- package/property-grid/widgets/fonteditor/_model.js +79 -40
- package/property-grid/widgets/fonteditor/_modificatorsEditor.d.ts +28 -0
- package/property-grid/widgets/fonteditor/_modificatorsEditor.js +31 -0
- package/property-grid/widgets/fonteditor/editor.d.ts +7 -6
- package/property-grid/widgets/fonteditor/editor.js +12 -9
- package/property-grid/widgets/guideditor.d.ts +17 -4
- package/property-grid/widgets/guideditor.js +52 -5
- package/property-grid/widgets/internal/_bindingsCache.ko.js +11 -14
- package/property-grid/widgets/internal/_internal.d.ts +4 -3
- package/property-grid/widgets/internal/_svgTemplateEngine.d.ts +1 -2
- package/property-grid/widgets/internal/_svgTemplateEngine.ko.js +4 -7
- package/property-grid/widgets/internal/_utils.d.ts +21 -14
- package/property-grid/widgets/internal/_utils.js +8 -0
- package/property-grid/widgets/registerBaseEdtior.d.ts +1 -1
- package/property-grid/widgets/registerBaseEdtior.js +3 -3
- package/property-grid/widgets/registerBaseEdtior.native.d.ts +1 -1
- package/property-grid/widgets/registerBaseEdtior.native.js +14 -17
- package/query-builder/_accordionTabInfo.d.ts +12 -20
- package/query-builder/_accordionTabInfo.js +49 -30
- package/query-builder/_bindings.js +6 -5
- package/query-builder/_initializer.d.ts +11 -8
- package/query-builder/_initializer.js +205 -164
- package/query-builder/_previewDialog.d.ts +38 -0
- package/query-builder/_previewDialog.js +60 -0
- package/query-builder/_queryBuilderRootModel.d.ts +42 -0
- package/query-builder/_queryBuilderRootModel.js +70 -0
- package/query-builder/binding/jsQueryBuilder.d.ts +5 -7
- package/query-builder/binding/jsQueryBuilder.js +6 -12
- package/query-builder/binding/jsQueryBuilderBinding.d.ts +2 -2
- package/query-builder/binding/jsQueryBuilderBinding.js +15 -16
- package/query-builder/binding/jsQueryBuilderBindingOptions.d.ts +4 -4
- package/query-builder/dataSource/_utils.js +2 -2
- package/query-builder/dataSource/dataSourceParameter.d.ts +18 -12
- package/query-builder/dataSource/dataSourceParameter.js +73 -54
- package/query-builder/dataSource/dbSchemaProvider.js +9 -7
- package/query-builder/dataSource/federation/federatedQueries/selectQuery.d.ts +8 -9
- package/query-builder/dataSource/federation/federatedQueries/selectQuery.js +14 -14
- package/query-builder/dataSource/federation/federatedQueries/sourceQuery.d.ts +4 -5
- package/query-builder/dataSource/federation/federatedQueries/sourceQuery.js +8 -9
- package/query-builder/dataSource/federation/federatedQueries/subNode.d.ts +9 -10
- package/query-builder/dataSource/federation/federatedQueries/subNode.js +18 -19
- package/query-builder/dataSource/federation/federatedQueries/transformQuery.d.ts +13 -14
- package/query-builder/dataSource/federation/federatedQueries/transformQuery.js +14 -14
- package/query-builder/dataSource/federation/federatedQueries/unionQuery.d.ts +5 -6
- package/query-builder/dataSource/federation/federatedQueries/unionQuery.js +5 -7
- package/query-builder/dataSource/federation/federatedQueriesContainer.d.ts +7 -8
- package/query-builder/dataSource/federation/federatedQueriesContainer.js +32 -25
- package/query-builder/dataSource/federation/federatedQueryExpression.d.ts +6 -5
- package/query-builder/dataSource/federation/federatedQueryExpression.js +4 -4
- package/query-builder/dataSource/federation/federationDataSource.d.ts +8 -9
- package/query-builder/dataSource/federation/federationDataSource.js +14 -14
- package/query-builder/dataSource/federation/federationMasterDetailRelation.d.ts +2 -1
- package/query-builder/dataSource/federation/federationMasterDetailRelation.js +4 -4
- package/query-builder/dataSource/federation/federationSerializableModel.d.ts +1 -2
- package/query-builder/dataSource/federation/federationSerializableModel.js +10 -11
- package/query-builder/dataSource/federation/federationSource.d.ts +6 -6
- package/query-builder/dataSource/federation/federationSource.js +7 -9
- package/query-builder/dataSource/json/jsonAuthenticationInfo.d.ts +4 -4
- package/query-builder/dataSource/json/jsonAuthenticationInfo.js +4 -4
- package/query-builder/dataSource/json/jsonDataSource.d.ts +5 -6
- package/query-builder/dataSource/json/jsonDataSource.js +7 -7
- package/query-builder/dataSource/json/jsonParameter.d.ts +42 -17
- package/query-builder/dataSource/json/jsonParameter.js +60 -23
- package/query-builder/dataSource/json/jsonSchemaNode.d.ts +7 -7
- package/query-builder/dataSource/json/jsonSchemaNode.js +19 -11
- package/query-builder/dataSource/json/jsonSchemaProvider.js +6 -5
- package/query-builder/dataSource/json/jsonSource.d.ts +8 -10
- package/query-builder/dataSource/json/jsonSource.js +18 -21
- package/query-builder/dataSource/mongoDB/mongoDBDataConnection.js +2 -2
- package/query-builder/dataSource/mongoDB/mongoDBDataSource.d.ts +4 -4
- package/query-builder/dataSource/mongoDB/mongoDBDataSource.js +11 -9
- package/query-builder/dataSource/mongoDB/mongoDBQuery.d.ts +7 -6
- package/query-builder/dataSource/mongoDB/mongoDBQuery.js +15 -15
- package/query-builder/dataSource/object/objectDataSource.d.ts +3 -4
- package/query-builder/dataSource/object/objectDataSource.js +13 -8
- package/query-builder/dataSource/object/objectSchema.d.ts +2 -3
- package/query-builder/dataSource/object/objectSchema.js +4 -5
- package/query-builder/dataSource/resultSet.d.ts +3 -3
- package/query-builder/dataSource/resultSet.js +7 -6
- package/query-builder/dataSource/resultTable.d.ts +7 -7
- package/query-builder/dataSource/resultTable.js +4 -4
- package/query-builder/dataSource/sql/connectionOptions.d.ts +4 -4
- package/query-builder/dataSource/sql/connectionOptions.js +5 -9
- package/query-builder/dataSource/sql/customSqlQuery.d.ts +6 -6
- package/query-builder/dataSource/sql/customSqlQuery.js +9 -8
- package/query-builder/dataSource/sql/dataConnectionBase.d.ts +5 -5
- package/query-builder/dataSource/sql/dataConnectionBase.js +5 -8
- package/query-builder/dataSource/sql/masterDetailRelation.d.ts +13 -12
- package/query-builder/dataSource/sql/masterDetailRelation.js +9 -25
- package/query-builder/dataSource/sql/masterDetailRelationMeta.d.ts +1 -0
- package/query-builder/dataSource/sql/masterDetailRelationMeta.js +6 -7
- package/query-builder/dataSource/sql/sqlDataSource.d.ts +6 -7
- package/query-builder/dataSource/sql/sqlDataSource.js +13 -13
- package/query-builder/dataSource/sql/storedProcQuery.d.ts +6 -6
- package/query-builder/dataSource/sql/storedProcQuery.js +10 -9
- package/query-builder/dataSource/sql/tableQuery.d.ts +8 -8
- package/query-builder/dataSource/sql/tableQuery.js +10 -9
- package/query-builder/dataSource/utils.d.ts +7 -8
- package/query-builder/dragDrop/_columnDragHandler.d.ts +5 -6
- package/query-builder/dragDrop/_columnDragHandler.js +41 -29
- package/query-builder/dragDrop/_dbObjectDragDropHandler.d.ts +7 -8
- package/query-builder/dragDrop/_dbObjectDragDropHandler.js +14 -12
- package/query-builder/elements/_federationColumnModel.d.ts +7 -7
- package/query-builder/elements/_federationColumnModel.js +4 -4
- package/query-builder/elements/_federationQueryModel.d.ts +22 -23
- package/query-builder/elements/_federationQueryModel.js +50 -43
- package/query-builder/elements/allColumnsModel.d.ts +7 -8
- package/query-builder/elements/allColumnsModel.js +22 -24
- package/query-builder/elements/allColumnsSurface.d.ts +14 -11
- package/query-builder/elements/allColumnsSurface.js +25 -14
- package/query-builder/elements/columnExpression.d.ts +21 -16
- package/query-builder/elements/columnExpression.js +50 -22
- package/query-builder/elements/columnModel.d.ts +19 -18
- package/query-builder/elements/columnModel.js +115 -100
- package/query-builder/elements/columnSurface.d.ts +25 -22
- package/query-builder/elements/columnSurface.js +56 -31
- package/query-builder/elements/joinConditionModel.d.ts +14 -16
- package/query-builder/elements/joinConditionModel.js +32 -18
- package/query-builder/elements/joinConditionSurface.d.ts +3 -3
- package/query-builder/elements/joinConditionSurface.js +4 -8
- package/query-builder/elements/parameterModel.d.ts +3 -6
- package/query-builder/elements/parameterModel.js +3 -2
- package/query-builder/elements/queryElementModel.d.ts +4 -3
- package/query-builder/elements/queryElementModel.js +2 -2
- package/query-builder/elements/queryElementSurface.d.ts +3 -5
- package/query-builder/elements/queryElementSurface.js +5 -14
- package/query-builder/elements/queryModel.d.ts +43 -41
- package/query-builder/elements/queryModel.js +193 -159
- package/query-builder/elements/queryModelMeta.js +1 -1
- package/query-builder/elements/querySurface.d.ts +42 -22
- package/query-builder/elements/querySurface.js +88 -42
- package/query-builder/elements/relationModel.d.ts +17 -17
- package/query-builder/elements/relationModel.js +26 -20
- package/query-builder/elements/relationSurface.d.ts +10 -7
- package/query-builder/elements/relationSurface.js +11 -5
- package/query-builder/elements/tableModel.d.ts +24 -27
- package/query-builder/elements/tableModel.js +80 -67
- package/query-builder/elements/tableSurface.d.ts +28 -11
- package/query-builder/elements/tableSurface.js +49 -14
- package/query-builder/utils/_callbacks.d.ts +2 -2
- package/query-builder/utils/_columnExpressionCollectionHelper.d.ts +9 -10
- package/query-builder/utils/_columnExpressionCollectionHelper.js +38 -22
- package/query-builder/utils/_controlsFactory.js +15 -15
- package/query-builder/utils/_dataConnection.js +2 -2
- package/query-builder/utils/_federationUnionQueryBuilderTreeListController.d.ts +6 -6
- package/query-builder/utils/_jsonSchemaFieldListProviderFactory.d.ts +2 -1
- package/query-builder/utils/_jsonSchemaFieldListProviderFactory.js +7 -7
- package/query-builder/utils/_queryBuilderTreeListController.d.ts +4 -5
- package/query-builder/utils/requestwrapper.js +8 -8
- package/query-builder/widgets/_federatedQueriesHelper.d.ts +2 -2
- package/query-builder/widgets/_federatedQueriesHelper.js +13 -12
- package/query-builder/widgets/_manageFederatedQueriesEditor.d.ts +25 -10
- package/query-builder/widgets/_manageFederatedQueriesEditor.js +48 -22
- package/query-builder/widgets/_parameterExpressionEditor.d.ts +8 -0
- package/query-builder/widgets/_parameterExpressionEditor.js +7 -0
- package/query-builder/widgets/_rightPanelSwitcher.d.ts +17 -14
- package/query-builder/widgets/_rightPanelSwitcher.js +45 -19
- package/query-builder/widgets/filterEditor/_groupFilterEditorSerializer.js +1 -1
- package/query-builder/widgets/filterEditor/_operandParameterQBSurface.d.ts +29 -9
- package/query-builder/widgets/filterEditor/_operandParameterQBSurface.js +60 -23
- package/query-builder/widgets/filterEditor/_operandPropertyQBSurface.d.ts +10 -10
- package/query-builder/widgets/filterEditor/_operandPropertyQBSurface.js +8 -9
- package/query-builder/widgets/filterEditor/_qbFilterEditorHelper.d.ts +1 -2
- package/query-builder/widgets/filterEditor/_qbFilterEditorHelper.js +4 -6
- package/query-builder/widgets/filterEditor/_qbFilterStringOptions.d.ts +4 -4
- package/query-builder/widgets/filterEditor/_qbFilterStringOptions.js +6 -7
- package/query-builder/widgets/filterEditor/_queryBuilderObjectsProvider.d.ts +13 -11
- package/query-builder/widgets/filterEditor/_queryBuilderObjectsProvider.js +15 -14
- package/query-builder/widgets/masterdetaileditor/_keyColumnSurface.d.ts +27 -11
- package/query-builder/widgets/masterdetaileditor/_keyColumnSurface.js +56 -11
- package/query-builder/widgets/masterdetaileditor/_masterDetailEditor.d.ts +22 -15
- package/query-builder/widgets/masterdetaileditor/_masterDetailEditor.js +52 -46
- package/query-builder/widgets/masterdetaileditor/_masterDetailEditorPopupManager.d.ts +29 -10
- package/query-builder/widgets/masterdetaileditor/_masterDetailEditorPopupManager.js +41 -25
- package/query-builder/widgets/masterdetaileditor/_masterDetailRelationSurface.d.ts +44 -16
- package/query-builder/widgets/masterdetaileditor/_masterDetailRelationSurface.js +80 -21
- package/query-builder/widgets/masterdetaileditor/_masterQuerySurface.d.ts +25 -9
- package/query-builder/widgets/masterdetaileditor/_masterQuerySurface.js +58 -22
- package/query-builder/widgets/registerEditorTemplates.d.ts +1 -1
- package/query-builder/widgets/registerEditorTemplates.js +7 -5
- package/query-builder/wizard/chooseAvailableDataSourcePage.d.ts +1 -1
- package/query-builder/wizard/chooseAvailableDataSourcePage.js +4 -4
- package/query-builder/wizard/chooseAvailablePage.d.ts +31 -11
- package/query-builder/wizard/chooseAvailablePage.js +64 -17
- package/query-builder/wizard/dataSourceWizard.d.ts +8 -6
- package/query-builder/wizard/dataSourceWizard.js +12 -13
- package/query-builder/wizard/dataSourceWizardState.d.ts +1 -1
- package/query-builder/wizard/dataSourceWizardState.js +11 -8
- package/query-builder/wizard/fullscreen/fullscreenWizard.d.ts +16 -7
- package/query-builder/wizard/fullscreen/fullscreenWizard.js +50 -16
- package/query-builder/wizard/fullscreen/fullscreenWizardNavigation.d.ts +29 -8
- package/query-builder/wizard/fullscreen/fullscreenWizardNavigation.js +80 -31
- package/query-builder/wizard/fullscreen/pages/fullscreenWizardPage.d.ts +32 -9
- package/query-builder/wizard/fullscreen/pages/fullscreenWizardPage.js +85 -12
- package/query-builder/wizard/fullscreen/pages/selectDataSourcePage.d.ts +1 -1
- package/query-builder/wizard/fullscreen/pages/specifyFederationDataSourceSettingsPage.js +1 -1
- package/query-builder/wizard/fullscreen/pages/specifyJsonDataSourceSettingsPage.js +2 -2
- package/query-builder/wizard/fullscreen/pages/specifyMongoDBDataSourceSettingsPage.js +1 -1
- package/query-builder/wizard/fullscreen/pages/specifyObjectDataSourceSettingsPage.d.ts +17 -3
- package/query-builder/wizard/fullscreen/pages/specifyObjectDataSourceSettingsPage.js +28 -20
- package/query-builder/wizard/fullscreen/pages/specifySqlDataSourceSettingsPage.js +2 -2
- package/query-builder/wizard/internal/_configureParametersUtils.d.ts +16 -17
- package/query-builder/wizard/internal/_configureParametersUtils.js +19 -11
- package/query-builder/wizard/internal/_dataSourceWizardConnectionStringsHolder.d.ts +9 -0
- package/query-builder/wizard/internal/_dataSourceWizardConnectionStringsHolder.js +31 -0
- package/query-builder/wizard/internal/_dbSchemaItemsProvider.d.ts +15 -14
- package/query-builder/wizard/internal/_dbSchemaItemsProvider.js +63 -60
- package/query-builder/wizard/internal/_dbSchemaTreeListController.d.ts +3 -3
- package/query-builder/wizard/internal/_jsonDataSourceWidgets.d.ts +28 -12
- package/query-builder/wizard/internal/_jsonDataSourceWidgets.js +45 -20
- package/query-builder/wizard/internal/_jsonSourceSettings.d.ts +34 -34
- package/query-builder/wizard/internal/_jsonSourceSettings.js +170 -137
- package/query-builder/wizard/internal/_jsonTreeNodeItemsProvider.d.ts +2 -2
- package/query-builder/wizard/internal/_jsonTreeNodeItemsProvider.js +4 -3
- package/query-builder/wizard/internal/_queryBuilderPopup.d.ts +39 -22
- package/query-builder/wizard/internal/_queryBuilderPopup.js +83 -30
- package/query-builder/wizard/internal/_selectQuerySqlTextProvider.js +2 -2
- package/query-builder/wizard/internal/_selectStatementPopup.d.ts +31 -0
- package/query-builder/wizard/internal/_selectStatementPopup.js +63 -0
- package/query-builder/wizard/internal/_selectStatementQueryControl.d.ts +42 -16
- package/query-builder/wizard/internal/_selectStatementQueryControl.js +84 -42
- package/query-builder/wizard/internal/_storedProceduresQueryControl.d.ts +33 -11
- package/query-builder/wizard/internal/_storedProceduresQueryControl.js +71 -26
- package/query-builder/wizard/internal/_treeListNode.d.ts +60 -23
- package/query-builder/wizard/internal/_treeListNode.js +206 -108
- package/query-builder/wizard/internal/_treeNodeItemsProvider.d.ts +7 -4
- package/query-builder/wizard/internal/_treeNodeItemsProvider.js +30 -31
- package/query-builder/wizard/internal/_utils.d.ts +13 -17
- package/query-builder/wizard/internal/_utils.js +4 -35
- package/query-builder/wizard/internal/_wizardPageProcessor.d.ts +1 -2
- package/query-builder/wizard/internal/_wizardPageProcessor.js +12 -13
- package/query-builder/wizard/internal/_wizardPageSectionIterator.d.ts +3 -3
- package/query-builder/wizard/internal/_wizardPageSectionIterator.js +16 -7
- package/query-builder/wizard/internal/federationDataSource/_federatedQueriesTreeNode.d.ts +3 -3
- package/query-builder/wizard/internal/federationDataSource/_federatedQueriesTreeNode.js +3 -3
- package/query-builder/wizard/internal/federationDataSource/_federationDataSourceItemsExtender.d.ts +1 -1
- package/query-builder/wizard/internal/federationDataSource/_federationQueryBuilderPopupBase.d.ts +27 -8
- package/query-builder/wizard/internal/federationDataSource/_federationQueryBuilderPopupBase.js +52 -10
- package/query-builder/wizard/internal/federationDataSource/_federationSelectQueryBuilderPopup.d.ts +32 -14
- package/query-builder/wizard/internal/federationDataSource/_federationSelectQueryBuilderPopup.js +184 -102
- package/query-builder/wizard/internal/federationDataSource/_federationTablesExpressionFieldListProvider.d.ts +2 -2
- package/query-builder/wizard/internal/federationDataSource/_federationTablesExpressionFieldListProvider.js +2 -2
- package/query-builder/wizard/internal/federationDataSource/_federationTransformQueryBuilderPopup.d.ts +46 -12
- package/query-builder/wizard/internal/federationDataSource/_federationTransformQueryBuilderPopup.js +131 -65
- package/query-builder/wizard/internal/federationDataSource/_federationTransformResultSchemaProvider.d.ts +4 -2
- package/query-builder/wizard/internal/federationDataSource/_federationTransformResultSchemaProvider.js +6 -4
- package/query-builder/wizard/internal/federationDataSource/_federationTreeNodeProvider.d.ts +2 -2
- package/query-builder/wizard/internal/federationDataSource/_federationTreeNodeProvider.js +16 -15
- package/query-builder/wizard/internal/federationDataSource/_federationUnionQueryBuilderPopup.d.ts +35 -8
- package/query-builder/wizard/internal/federationDataSource/_federationUnionQueryBuilderPopup.js +130 -62
- package/query-builder/wizard/internal/initializer.d.ts +8 -4
- package/query-builder/wizard/internal/jsonSourceSettings.d.ts +25 -8
- package/query-builder/wizard/internal/objectDataSource/_chooseObjectDataMembers.d.ts +20 -6
- package/query-builder/wizard/internal/objectDataSource/_chooseObjectDataMembers.js +49 -16
- package/query-builder/wizard/internal/objectDataSource/_chooseObjectParameters.d.ts +29 -16
- package/query-builder/wizard/internal/objectDataSource/_chooseObjectParameters.js +93 -57
- package/query-builder/wizard/internal/objectDataSource/_chooseObjectTypes.d.ts +20 -11
- package/query-builder/wizard/internal/objectDataSource/_chooseObjectTypes.js +60 -29
- package/query-builder/wizard/multiQueryDataSourceWizard.d.ts +1 -1
- package/query-builder/wizard/multiQueryDataSourceWizard.js +5 -5
- package/query-builder/wizard/pages/IWizardPage.d.ts +4 -1
- package/query-builder/wizard/pages/__wrappedWizardPage.d.ts +1 -0
- package/query-builder/wizard/pages/__wrappedWizardPage.js +18 -1
- package/query-builder/wizard/pages/chooseDataSourceTypePage.d.ts +21 -3
- package/query-builder/wizard/pages/chooseDataSourceTypePage.js +54 -9
- package/query-builder/wizard/pages/chooseSqlConnectionPage.d.ts +19 -6
- package/query-builder/wizard/pages/chooseSqlConnectionPage.js +51 -24
- package/query-builder/wizard/pages/federationDataSourceWizard/federatedMasterDetailRelationshipsPage.d.ts +0 -4
- package/query-builder/wizard/pages/federationDataSourceWizard/federatedMasterDetailRelationshipsPage.js +6 -9
- package/query-builder/wizard/pages/federationDataSourceWizard/federatedQueryConfigurePage.d.ts +20 -18
- package/query-builder/wizard/pages/federationDataSourceWizard/federatedQueryConfigurePage.js +78 -48
- package/query-builder/wizard/pages/jsonDataSourceWizard/chooseJsonConnectionPage.d.ts +6 -6
- package/query-builder/wizard/pages/jsonDataSourceWizard/chooseJsonConnectionPage.js +3 -3
- package/query-builder/wizard/pages/jsonDataSourceWizard/chooseJsonSchemaPage.d.ts +26 -9
- package/query-builder/wizard/pages/jsonDataSourceWizard/chooseJsonSchemaPage.js +106 -60
- package/query-builder/wizard/pages/jsonDataSourceWizard/chooseJsonSourcePage.d.ts +51 -21
- package/query-builder/wizard/pages/jsonDataSourceWizard/chooseJsonSourcePage.js +90 -42
- package/query-builder/wizard/pages/jsonDataSourceWizard/specifyJsonConnectionPage.d.ts +8 -4
- package/query-builder/wizard/pages/jsonDataSourceWizard/specifyJsonConnectionPage.js +8 -2
- package/query-builder/wizard/pages/mongoDBDataSourceWizard/chooseMongoDBCollectionPage.d.ts +33 -10
- package/query-builder/wizard/pages/mongoDBDataSourceWizard/chooseMongoDBCollectionPage.js +90 -55
- package/query-builder/wizard/pages/mongoDBDataSourceWizard/chooseMongoDBDataConnectionPage.d.ts +2 -2
- package/query-builder/wizard/pages/mongoDBDataSourceWizard/chooseMongoDBDataConnectionPage.js +5 -5
- package/query-builder/wizard/pages/mongoDBDataSourceWizard/chooseMongoDBSchemaPage.d.ts +19 -7
- package/query-builder/wizard/pages/mongoDBDataSourceWizard/chooseMongoDBSchemaPage.js +73 -37
- package/query-builder/wizard/pages/multiQueryWizard/configureMasterDetailRelationshipsPage.d.ts +0 -4
- package/query-builder/wizard/pages/multiQueryWizard/configureMasterDetailRelationshipsPage.js +5 -11
- package/query-builder/wizard/pages/multiQueryWizard/masterDetailRelationshipsPageBase.d.ts +13 -6
- package/query-builder/wizard/pages/multiQueryWizard/masterDetailRelationshipsPageBase.js +52 -37
- package/query-builder/wizard/pages/multiQueryWizard/multiQueryConfigurePage.d.ts +59 -71
- package/query-builder/wizard/pages/multiQueryWizard/multiQueryConfigurePage.js +162 -113
- package/query-builder/wizard/pages/multiQueryWizard/multiQueryConfigureParametersPage.d.ts +16 -10
- package/query-builder/wizard/pages/multiQueryWizard/multiQueryConfigureParametersPage.js +75 -70
- package/query-builder/wizard/pages/objectDataSourceWizard/chooseObjectDataSourceDataMembersPage.d.ts +7 -1
- package/query-builder/wizard/pages/objectDataSourceWizard/chooseObjectDataSourceDataMembersPage.js +19 -10
- package/query-builder/wizard/pages/objectDataSourceWizard/chooseObjectDataSourceTypesPage.d.ts +7 -2
- package/query-builder/wizard/pages/objectDataSourceWizard/chooseObjectDataSourceTypesPage.js +15 -8
- package/query-builder/wizard/pages/objectDataSourceWizard/configureObjectDataSourceParametersPage.d.ts +10 -4
- package/query-builder/wizard/pages/objectDataSourceWizard/configureObjectDataSourceParametersPage.js +10 -5
- package/query-builder/wizard/pages/sqlDataSourceWizard/_sqlDataSourceWrapper.d.ts +1 -1
- package/query-builder/wizard/pages/sqlDataSourceWizard/_sqlDataSourceWrapper.js +9 -9
- package/query-builder/wizard/pages/sqlDataSourceWizard/configureParametersPage.d.ts +13 -4
- package/query-builder/wizard/pages/sqlDataSourceWizard/configureParametersPage.js +37 -14
- package/query-builder/wizard/pages/sqlDataSourceWizard/configureQueryPage.d.ts +33 -10
- package/query-builder/wizard/pages/sqlDataSourceWizard/configureQueryPage.js +102 -49
- package/query-builder/wizard/pages/wizardPageBase.d.ts +10 -2
- package/query-builder/wizard/pages/wizardPageBase.js +20 -5
- package/query-builder/wizard/popupWizard.d.ts +37 -100
- package/query-builder/wizard/popupWizard.js +72 -37
- package/query-builder/wizard/wizard.d.ts +20 -8
- package/query-builder/wizard/wizard.js +55 -23
- package/queryBuilder-internal.d.ts +4 -2
- package/queryBuilder-internal.js +4 -2
- package/queryBuilder-widgets-internal.d.ts +2 -2
- package/queryBuilder-widgets-internal.js +2 -2
- package/serializer/_internal.d.ts +2 -0
- package/serializer/_internal.js +20 -10
- package/serializer/disposable.d.ts +7 -6
- package/serializer/disposable.js +18 -11
- package/serializer/eventManager.d.ts +3 -2
- package/serializer/eventManager.js +26 -17
- package/serializer/native/deserializationEngine.d.ts +42 -3
- package/serializer/native/deserializationEngine.js +221 -83
- package/serializer/native/deserializationEngine.updateViewModel.js +28 -12
- package/serializer/native/diagnostics/derivedCacheDiagnostics.d.ts +10 -0
- package/serializer/native/diagnostics/derivedCacheDiagnostics.js +65 -0
- package/serializer/native/modelGraph.d.ts +10 -0
- package/serializer/native/modelGraph.js +92 -0
- package/serializer/native/models/base.model.d.ts +29 -41
- package/serializer/native/models/base.model.js +75 -96
- package/serializer/native/models/derivedAccessor.d.ts +33 -0
- package/serializer/native/models/derivedAccessor.js +231 -0
- package/serializer/native/models/interfaces.model.d.ts +21 -5
- package/serializer/native/models/interfaces.model.js +24 -1
- package/serializer/native/models/valueAccessor.d.ts +21 -0
- package/serializer/native/models/valueAccessor.js +77 -0
- package/serializer/native/multiplatformEngine.d.ts +11 -35
- package/serializer/native/multiplatformEngine.js +16 -142
- package/serializer/native/serializer.d.ts +16 -1
- package/serializer/native/serializer.js +87 -23
- package/serializer/native/viewModels/viewModelGenerator.d.ts +1 -0
- package/serializer/native/viewModels/viewModelGenerator.js +35 -40
- package/serializer/propertyChangedEvents.d.ts +16 -1
- package/serializer/propertyChangedEvents.js +57 -1
- package/serializer/serializationInfo.d.ts +10 -15
- package/serializer/serializer.d.ts +2 -14
- package/serializer/serializer.js +1 -40
- package/undo-engine/_utils.d.ts +2 -1
- package/undo-engine/_utils.js +1 -1
- package/undo-engine/undoengine.d.ts +59 -27
- package/undo-engine/undoengine.js +209 -201
- package/widgets/_hotKeys.d.ts +15 -0
- package/widgets/_hotKeys.js +150 -0
- package/widgets/_searchHighlighting.binding.d.ts +2 -5
- package/widgets/_searchHighlighting.binding.js +17 -20
- package/widgets/_searchHighlighting.d.ts +6 -3
- package/widgets/_searchHighlighting.js +8 -6
- package/widgets/ace/_binding.js +18 -17
- package/widgets/bindings.js +23 -21
- package/widgets/common/_codeCompletor.d.ts +8 -7
- package/widgets/common/_codeCompletor.js +13 -11
- package/widgets/common/displayNameProvider.d.ts +1 -0
- package/widgets/criteria/operators/options/function.d.ts +26 -1
- package/widgets/criteria/operators/options/function.js +25 -0
- package/widgets/criteria/parser/criteriaparser.d.ts +5 -5
- package/widgets/criteria/parser/criteriaparser.js +910 -910
- package/widgets/expressioneditor/_expressionOptionsBase.d.ts +39 -0
- package/widgets/expressioneditor/_expressionOptionsBase.js +72 -0
- package/widgets/expressioneditor/aiExpressionGenerator.d.ts +34 -41
- package/widgets/expressioneditor/aiExpressionGenerator.js +86 -56
- package/widgets/expressioneditor/bindings.d.ts +18 -1
- package/widgets/expressioneditor/bindings.js +34 -14
- package/widgets/expressioneditor/expressioneditor.d.ts +70 -26
- package/widgets/expressioneditor/expressioneditor.js +194 -116
- package/widgets/expressioneditor/tools/_functions.js +31 -0
- package/widgets/expressioneditor/tools/_tools.d.ts +168 -35
- package/widgets/expressioneditor/tools/_tools.js +365 -145
- package/widgets/expressioneditor/tools/_treeListControllers.d.ts +14 -13
- package/widgets/filtereditor/filtereditor.d.ts +102 -42
- package/widgets/filtereditor/filtereditor.js +395 -263
- package/widgets/filtereditor/filtereditoroptions.d.ts +15 -11
- package/widgets/filtereditor/filtereditoroptions.js +19 -17
- package/widgets/filtereditor/helpers/_addon.d.ts +31 -8
- package/widgets/filtereditor/helpers/_addon.js +71 -34
- package/widgets/filtereditor/helpers/_treelistController.d.ts +7 -8
- package/widgets/filtereditor/helpers/_treelistController.js +13 -5
- package/widgets/filtereditor/helpers/helper.d.ts +11 -3
- package/widgets/filtereditor/helpers/helper.js +20 -17
- package/widgets/filtereditor/operators/_criteriaTypeState.d.ts +7 -0
- package/widgets/filtereditor/operators/_criteriaTypeState.js +17 -0
- package/widgets/filtereditor/operators/aggregateOperandSurface.d.ts +16 -8
- package/widgets/filtereditor/operators/aggregateOperandSurface.js +47 -23
- package/widgets/filtereditor/operators/betweenOperandSurface.d.ts +16 -8
- package/widgets/filtereditor/operators/betweenOperandSurface.js +30 -15
- package/widgets/filtereditor/operators/binaryOperandSurface.d.ts +14 -7
- package/widgets/filtereditor/operators/binaryOperandSurface.js +25 -12
- package/widgets/filtereditor/operators/criteriaOperatorSurface.d.ts +52 -18
- package/widgets/filtereditor/operators/criteriaOperatorSurface.js +133 -38
- package/widgets/filtereditor/operators/functionOperandSurface.d.ts +13 -7
- package/widgets/filtereditor/operators/functionOperandSurface.js +41 -22
- package/widgets/filtereditor/operators/groupOperandSurface.d.ts +12 -5
- package/widgets/filtereditor/operators/groupOperandSurface.js +33 -16
- package/widgets/filtereditor/operators/inOperandSurface.d.ts +16 -7
- package/widgets/filtereditor/operators/inOperandSurface.js +27 -13
- package/widgets/filtereditor/operators/operandParameterSurface.d.ts +12 -5
- package/widgets/filtereditor/operators/operandParameterSurface.js +21 -15
- package/widgets/filtereditor/operators/operandPropertySurface.d.ts +20 -11
- package/widgets/filtereditor/operators/operandPropertySurface.js +67 -46
- package/widgets/filtereditor/operators/operandSurfaceBase.d.ts +4 -4
- package/widgets/filtereditor/operators/operandSurfaceBase.js +6 -33
- package/widgets/filtereditor/operators/operandValueSurface.d.ts +47 -76
- package/widgets/filtereditor/operators/operandValueSurface.js +149 -110
- package/widgets/filtereditor/operators/unaryOperandSurface.d.ts +12 -6
- package/widgets/filtereditor/operators/unaryOperandSurface.js +24 -17
- package/widgets/formatstring/binding.d.ts +15 -1
- package/widgets/formatstring/binding.js +19 -6
- package/widgets/formatstring/formatstringeditor.d.ts +64 -21
- package/widgets/formatstring/formatstringeditor.js +184 -116
- package/widgets/internal/_popupComponentBase.d.ts +4 -4
- package/widgets/internal/_resizeHelper.d.ts +5 -4
- package/widgets/internal/_resizeHelper.js +5 -6
- package/widgets/treelist/_binding.d.ts +1 -2
- package/widgets/treelist/_binding.js +9 -20
- package/widgets/treelist/_ko_binging.js +15 -13
- package/widgets/treelist/_reorderTreeListDragDropHelper.d.ts +7 -7
- package/widgets/treelist/_reorderTreeListDragDropHelper.js +8 -7
- package/widgets/treelist/_treeListSearchModel.d.ts +32 -0
- package/widgets/treelist/_treeListSearchModel.js +133 -0
- package/widgets/treelist/_treelistController.d.ts +26 -22
- package/widgets/treelist/_treelistController.js +3 -1
- package/widgets/treelist/_treelistItem.d.ts +36 -36
- package/widgets/treelist/_treelistItem.js +113 -104
- package/widgets/treelist/_treelistItem.viewModel.d.ts +26 -11
- package/widgets/treelist/_treelistItem.viewModel.js +55 -7
- package/widgets/utils.d.ts +22 -17
- package/core/elements/elementViewModel.d.ts +0 -94
- package/core/elements/elementViewModel.js +0 -180
- package/core/utils/_koUtils.d.ts +0 -7
- package/core/utils/_koUtils.js +0 -11
- package/core/utils/_utils.wrapModelInObservable.d.ts +0 -2
- package/core/utils/_utils.wrapModelInObservable.js +0 -5
- package/core/widgets/bordereditor/_binding.d.ts +0 -1
- package/core/widgets/bordereditor/_binding.js +0 -16
- package/core/widgets/textAlignmentEditor/_binding.d.ts +0 -1
- package/core/widgets/textAlignmentEditor/_binding.js +0 -16
- package/diagram/elements/diagramElementViewModel.d.ts +0 -10
- package/diagram/elements/diagramElementViewModel.js +0 -13
- package/property-grid/widgets/collectioneditor/_ko_model.d.ts +0 -4
- package/property-grid/widgets/collectioneditor/_ko_model.js +0 -66
- package/query-builder/_queryBuilderModel.d.ts +0 -36
- package/query-builder/_queryBuilderModel.js +0 -1
- package/query-builder/widgets/_undoEditor.d.ts +0 -9
- package/query-builder/widgets/_undoEditor.js +0 -22
- package/query-builder/wizard/internal/_wizardAction.d.ts +0 -8
- package/query-builder/wizard/internal/_wizardAction.js +0 -9
- package/serializer/native/models/modelAccessor.d.ts +0 -2
- package/serializer/native/models/modelAccessor.js +0 -6
- package/serializer/utils.d.ts +0 -2
- package/serializer/utils.js +0 -5
- package/undo-engine/_propertiesVisitor.d.ts +0 -1
- package/undo-engine/_propertiesVisitor.js +0 -25
- package/widgets/expressioneditor/_expressioneditor.d.ts +0 -8
- package/widgets/expressioneditor/_expressioneditor.js +0 -54
- package/widgets/treelist/_ko_treelistUtils.d.ts +0 -8
- package/widgets/treelist/_ko_treelistUtils.js +0 -55
- package/widgets/treelist/_treeListSearchViewModel.d.ts +0 -19
- package/widgets/treelist/_treeListSearchViewModel.js +0 -108
|
@@ -1,48 +1,53 @@
|
|
|
1
|
-
|
|
1
|
+
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
2
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
3
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
4
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
5
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
6
|
+
};
|
|
2
7
|
import { getLocalization } from '../../property-grid/localization/localization_utils';
|
|
3
8
|
import { UnaryOperator } from '../criteria/operators/unary';
|
|
4
9
|
import { UnaryOperandSurface } from './operators/unaryOperandSurface';
|
|
5
10
|
import { PopupService } from '../../property-grid/internal/_popupService';
|
|
6
11
|
import { DisplayExpressionConverter } from '../common/_displayNameProvider';
|
|
7
|
-
import {
|
|
12
|
+
import { createDerivedAccessor, debounced, followSources } from '../../serializer/native/models/derivedAccessor';
|
|
13
|
+
import { createValueAccessor, ensureAccessor, readAccessor, toAccessor } from '../../serializer/native/models/valueAccessor';
|
|
8
14
|
import { FilterEditorCodeCompletor } from './helpers/_codeCompletor';
|
|
9
15
|
import { getParentContainer } from '../_utils';
|
|
10
|
-
import { addDisposeCallback } from '../../serializer/_internal';
|
|
11
16
|
import dxTextArea from 'devextreme/ui/text_area';
|
|
12
|
-
import { getTemplate } from '../../property-grid/widgets/templateUtils';
|
|
13
17
|
import { GroupOperator } from '../criteria/operators/group';
|
|
14
|
-
import {
|
|
18
|
+
import { CriteriaEditorModelBase } from '../../core/widgets/_criteriaPopupEditorBase';
|
|
15
19
|
import { GroupOperatorType } from '../criteria/operators/options/group';
|
|
16
20
|
import { criteriaCreator } from '../criteria/utils/criteriaOperatorPreprocessor';
|
|
17
21
|
import { $dx, DxDeferred } from '../../core/utils/_jqueryUtils';
|
|
18
|
-
|
|
22
|
+
import { createViewModelGenerator } from '../../serializer/native/viewModels/viewModelGenerator';
|
|
23
|
+
import { currentRenderingEngine, subscribableProperty } from '../../serializer/native/multiplatformEngine';
|
|
24
|
+
import { mutable } from '../../serializer/native/models/base.model';
|
|
25
|
+
import { registerKoBinding, registerKoComponent } from '../../core/internal/_ko_integration';
|
|
26
|
+
import { getTemplate } from '../../property-grid/widgets/templateUtils';
|
|
27
|
+
import { subscribeProperty } from '../../core/utils/_subscribeProperty';
|
|
28
|
+
import { addDisposeCallback } from '../../serializer/_internal';
|
|
29
|
+
export class FilterEditor extends CriteriaEditorModelBase {
|
|
19
30
|
_generateOperand(value) {
|
|
20
|
-
return this.options
|
|
31
|
+
return this.options.helper.serializer.deserialize(value);
|
|
21
32
|
}
|
|
22
33
|
_generateSurface(operand) {
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
type = this.options().helper.mapper.unary;
|
|
26
|
-
}
|
|
27
|
-
else {
|
|
28
|
-
type = this.options().helper.mapper.group;
|
|
29
|
-
}
|
|
30
|
-
const surface = new type(operand, this, this.fieldListProvider, this.path);
|
|
34
|
+
const type = operand instanceof UnaryOperator ? this.options.helper.mapper.unary : this.options.helper.mapper.group;
|
|
35
|
+
const surface = new type(operand, this, this.fieldListProvider, createValueAccessor(this, 'path'));
|
|
31
36
|
if (surface instanceof UnaryOperandSurface) {
|
|
32
37
|
if (!(surface.model.operand instanceof GroupOperator)) {
|
|
33
38
|
this.operand = new GroupOperator(GroupOperatorType.And, [this.operand]);
|
|
34
39
|
surface.dispose();
|
|
35
40
|
return this._generateSurface(this.operand);
|
|
36
41
|
}
|
|
37
|
-
surface.operand
|
|
42
|
+
surface.operand.canRemove = false;
|
|
38
43
|
}
|
|
39
44
|
surface.canRemove = false;
|
|
40
45
|
return surface;
|
|
41
46
|
}
|
|
42
47
|
_validateValue(value) {
|
|
43
48
|
try {
|
|
44
|
-
if (this.options
|
|
45
|
-
this.options
|
|
49
|
+
if (this.options && this.options.helper) {
|
|
50
|
+
this.options.helper.serializer.deserialize(value);
|
|
46
51
|
return true;
|
|
47
52
|
}
|
|
48
53
|
else {
|
|
@@ -55,26 +60,19 @@ export class FilterEditor extends CriteriaEditorBase {
|
|
|
55
60
|
}
|
|
56
61
|
constructor(options, fieldListProvider, rtl = false, _displayNameProvider, editorInputId) {
|
|
57
62
|
super();
|
|
58
|
-
this.options = options;
|
|
59
63
|
this._displayNameProvider = _displayNameProvider;
|
|
60
|
-
this._advancedMode = ko.observable(false);
|
|
61
|
-
this.onHiddenHandler = () => {
|
|
62
|
-
this.popupVisible(false);
|
|
63
|
-
};
|
|
64
|
-
this.textFocused = ko.observable(false);
|
|
65
64
|
this.languageHelper = {
|
|
66
65
|
getLanguageMode: () => 'ace/mode/criteria',
|
|
67
66
|
createCompleters: (editor, bindingContext, viewModel) => {
|
|
68
|
-
const
|
|
67
|
+
const completor = new FilterEditorCodeCompletor({
|
|
69
68
|
editor,
|
|
70
69
|
bindingContext,
|
|
71
|
-
fieldListProvider:
|
|
72
|
-
path,
|
|
70
|
+
fieldListProvider: readAccessor(this.fieldListProvider),
|
|
71
|
+
path: createValueAccessor(this, 'path'),
|
|
73
72
|
getRealExpression: (path, expression) => {
|
|
74
73
|
return this.displayExpressionConverter && this.displayExpressionConverter.toRealExpression(path, expression) || new DxDeferred().resolve(expression).promise();
|
|
75
74
|
}
|
|
76
75
|
});
|
|
77
|
-
completor._disposables.push(path);
|
|
78
76
|
return [completor];
|
|
79
77
|
}
|
|
80
78
|
};
|
|
@@ -92,159 +90,142 @@ export class FilterEditor extends CriteriaEditorBase {
|
|
|
92
90
|
onFocus: _ => this.onFocus(),
|
|
93
91
|
onBlur: _ => this.onBlur()
|
|
94
92
|
};
|
|
95
|
-
this.textVisible = ko.observable(false);
|
|
96
93
|
this.getPopupContainer = (el) => {
|
|
97
|
-
return getParentContainer(el, this.options
|
|
94
|
+
return getParentContainer(el, this.options['popupContainer']);
|
|
98
95
|
};
|
|
99
96
|
this.timeout = null;
|
|
100
97
|
this.animationTimeout = null;
|
|
101
|
-
this.advancedMode = ko.computed({
|
|
102
|
-
read: () => {
|
|
103
|
-
return this._advancedMode();
|
|
104
|
-
},
|
|
105
|
-
write: (newVal) => {
|
|
106
|
-
this.timeout && clearTimeout(this.timeout);
|
|
107
|
-
this.animationTimeout && clearTimeout(this.animationTimeout);
|
|
108
|
-
if (newVal) {
|
|
109
|
-
this.textVisible(true);
|
|
110
|
-
this.timeout = setTimeout(() => {
|
|
111
|
-
this._advancedMode(true);
|
|
112
|
-
if (!this.options().disabled())
|
|
113
|
-
this.focusText();
|
|
114
|
-
}, 1);
|
|
115
|
-
this.animationTimeout = setTimeout(() => {
|
|
116
|
-
this.editorContainer() && this.editorContainer().resize && this.editorContainer().resize();
|
|
117
|
-
}, 210);
|
|
118
|
-
}
|
|
119
|
-
else {
|
|
120
|
-
this._advancedMode(false);
|
|
121
|
-
this.timeout = setTimeout(() => {
|
|
122
|
-
this.textVisible(false);
|
|
123
|
-
}, 200);
|
|
124
|
-
}
|
|
125
|
-
},
|
|
126
|
-
});
|
|
127
98
|
this.invalidMessage = () => getLocalization('Cannot create a tree for this expression', 'AnalyticsCoreStringId.FilterEditor_TreeCreationError');
|
|
128
|
-
this.advancedModeText =
|
|
129
|
-
this.operandSurface = ko.observable(null);
|
|
99
|
+
this.advancedModeText = getLocalization('Advanced Mode', 'AnalyticsCoreStringId.FilterEditor_AdvancedMode');
|
|
130
100
|
this.operand = null;
|
|
101
|
+
this.advancedModeTop = () => this.advancedModePosition.indexOf('Top') !== -1;
|
|
102
|
+
this.advancedModeLeft = () => this.advancedModePosition.indexOf('Left') !== -1;
|
|
103
|
+
this.advancedModePosition = 'TopRight';
|
|
104
|
+
this.assignDerivedProperty('options', ensureAccessor(options));
|
|
105
|
+
this.assignDerivedProperty('path', () => this.options?.path, () => this._optionsSourceList(['path']));
|
|
131
106
|
this.popupService = new PopupService();
|
|
132
107
|
this.rtl = rtl;
|
|
108
|
+
this.fieldListProvider = fieldListProvider;
|
|
109
|
+
this.editorInputId = editorInputId;
|
|
110
|
+
this.displayExpressionConverter = _displayNameProvider && new DisplayExpressionConverter(_displayNameProvider);
|
|
111
|
+
this.assignProperty('convertedValue', '');
|
|
112
|
+
this.assignProperty('convertedModelValue', '');
|
|
133
113
|
this.initializeInnerValue();
|
|
134
|
-
options
|
|
135
|
-
this.
|
|
136
|
-
|
|
114
|
+
this.options && this.options.helper && (this.options.helper.rtl = rtl);
|
|
115
|
+
this.addDisposable(followSources(() => this._optionsSourceList(['value', 'path', 'disabled', 'title']), () => {
|
|
116
|
+
this.disabled = !!(this.options && this.options.disabled);
|
|
117
|
+
this.title = this.options && this.options.title;
|
|
118
|
+
this.modelValueIsValid = !!this.options && this._validateValue(this.options.value);
|
|
119
|
+
this._convertToDisplay(this.options && this.options.value, (display) => { this.convertedModelValue = display; });
|
|
137
120
|
}));
|
|
138
|
-
this.displayExpressionConverter
|
|
139
|
-
this.
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
}
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
};
|
|
150
|
-
this.
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
return
|
|
165
|
-
}
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
this._disposables.push(this.popupVisible.subscribe((newVal) => {
|
|
182
|
-
if (newVal) {
|
|
183
|
-
this.value(this.options().value());
|
|
184
|
-
this.aiFilterGenerator = this.aiFilterGenerator?.initialize(this);
|
|
185
|
-
if (this.isSurfaceValid()) {
|
|
186
|
-
this.operand = this._generateOperand(this.value());
|
|
187
|
-
this.operandSurface(this._generateSurface(this.operand));
|
|
188
|
-
}
|
|
189
|
-
else {
|
|
190
|
-
this.textVisible(true);
|
|
191
|
-
this._advancedMode(true);
|
|
192
|
-
this.editorContainer() && this.focusText();
|
|
193
|
-
}
|
|
194
|
-
options().helper.onChange = () => {
|
|
195
|
-
this.value(options().helper.serializer.serialize(this.operand, false));
|
|
196
|
-
};
|
|
121
|
+
this.assignDerivedProperty('displayValue', () => this.displayExpressionConverter ? this.convertedValue : this.value, () => [subscribableProperty(this, ['convertedValue', 'value'])]);
|
|
122
|
+
this.assignDerivedProperty('modelDisplayValue', () => this.displayExpressionConverter ? this.convertedModelValue : (this.options && this.options.value), () => [subscribableProperty(this, ['convertedModelValue']), ...this._optionsSourceList(['value'])]);
|
|
123
|
+
this.assignDerivedProperty('helper', () => this.options && this.options.helper, () => [subscribableProperty(this, ['options'])]);
|
|
124
|
+
this.addDisposable(followSources(() => this._optionsSourceList(['path']).concat([subscribableProperty(this, ['value'])]), () => {
|
|
125
|
+
this.isValid = this._validateValue(this.value);
|
|
126
|
+
this.isSurfaceValid = this._isSurfaceValid();
|
|
127
|
+
this._convertToDisplay(this.value, (display) => { this.convertedValue = display; });
|
|
128
|
+
}));
|
|
129
|
+
this.createAddButton = (criteria) => { return this.options.helper.handlers.create(criteria, this.popupService); };
|
|
130
|
+
this.createChangeType = (criteria) => { return this.options.helper.handlers.change(criteria, this.popupService); };
|
|
131
|
+
this.createChangeProperty = (criteria) => { return this.options.helper.handlers.changeProperty(criteria, this.popupService); };
|
|
132
|
+
this.createChangeParameter = (criteria) => { return this.options.helper.handlers.changeParameter(criteria, this.popupService); };
|
|
133
|
+
this.createChangeValueType = (criteria) => { return this.options.helper.handlers.changeValueType(criteria, this.popupService); };
|
|
134
|
+
}
|
|
135
|
+
saveStateSources() {
|
|
136
|
+
return [subscribableProperty(this, ['isValid'])];
|
|
137
|
+
}
|
|
138
|
+
_optionsSourceList(propertyNames) {
|
|
139
|
+
return [subscribableProperty(this, ['options']), this.options && subscribableProperty(this.options, propertyNames)];
|
|
140
|
+
}
|
|
141
|
+
_isSurfaceValid() {
|
|
142
|
+
try {
|
|
143
|
+
return this.options && this.isValid
|
|
144
|
+
&& this.options.helper.criteriaTreeValidator.validateModel(this.options.helper.serializer.deserialize(this.value));
|
|
145
|
+
}
|
|
146
|
+
catch (e) {
|
|
147
|
+
return false;
|
|
148
|
+
}
|
|
149
|
+
}
|
|
150
|
+
_convertToDisplay(value, apply) {
|
|
151
|
+
if (!this.displayExpressionConverter)
|
|
152
|
+
return;
|
|
153
|
+
this.displayExpressionConverter.toDisplayExpression(this.path, value)
|
|
154
|
+
.done((result) => apply(result))
|
|
155
|
+
.fail(() => apply(value));
|
|
156
|
+
}
|
|
157
|
+
_onPopupVisibleChanged(newVal) {
|
|
158
|
+
if (newVal) {
|
|
159
|
+
this.value = this.options.value;
|
|
160
|
+
this.aiFilterGenerator = this.aiFilterGenerator?.initialize(this);
|
|
161
|
+
if (this.isSurfaceValid) {
|
|
162
|
+
this.operand = this._generateOperand(this.value);
|
|
163
|
+
this.operandSurface = this._generateSurface(this.operand);
|
|
197
164
|
}
|
|
198
165
|
else {
|
|
199
|
-
this.
|
|
200
|
-
this.
|
|
201
|
-
this.
|
|
202
|
-
this.operandSurface(null);
|
|
203
|
-
this.operand = null;
|
|
166
|
+
this.textVisible = true;
|
|
167
|
+
this.advancedMode = true;
|
|
168
|
+
this.editorContainer && this.focusText();
|
|
204
169
|
}
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
170
|
+
this.options.helper.onChange = () => {
|
|
171
|
+
this.value = this.options.helper.serializer.serialize(this.operand, false);
|
|
172
|
+
};
|
|
173
|
+
}
|
|
174
|
+
else {
|
|
175
|
+
this.helper.onClosing();
|
|
176
|
+
this.value = null;
|
|
177
|
+
this.operandSurface && this.operandSurface.dispose();
|
|
178
|
+
this.operandSurface = null;
|
|
179
|
+
this.operand = null;
|
|
180
|
+
}
|
|
214
181
|
}
|
|
215
182
|
canSave() {
|
|
216
|
-
return this.isValid
|
|
183
|
+
return this.isValid;
|
|
217
184
|
}
|
|
218
185
|
initializeInnerValue() {
|
|
219
|
-
this.value
|
|
186
|
+
this.assignProperty('value', '');
|
|
220
187
|
}
|
|
221
|
-
|
|
222
|
-
this.
|
|
223
|
-
this.
|
|
224
|
-
|
|
225
|
-
if (this.operand instanceof UnaryOperator) {
|
|
226
|
-
newType = this.options().helper.mapper.unary;
|
|
188
|
+
save() {
|
|
189
|
+
this.helper.onSave(this.value);
|
|
190
|
+
if (this.operandSurface && this.isSurfaceValid) {
|
|
191
|
+
this.options.value = this.options.helper.serializer.serialize(this.operand, false);
|
|
227
192
|
}
|
|
228
193
|
else {
|
|
229
|
-
|
|
194
|
+
this.options.value = this.value;
|
|
230
195
|
}
|
|
231
|
-
|
|
196
|
+
this.popupVisible = false;
|
|
197
|
+
}
|
|
198
|
+
change(type, surface) {
|
|
199
|
+
this.operand = criteriaCreator.changeByType(type);
|
|
200
|
+
this.operand.assignFrom(surface.model);
|
|
201
|
+
const newType = this.operand instanceof UnaryOperator ? this.options.helper.mapper.unary : this.options.helper.mapper.group;
|
|
202
|
+
const newSurface = new newType(this.operand, this, this.fieldListProvider, createValueAccessor(this, 'path'));
|
|
232
203
|
newSurface.canRemove = false;
|
|
233
204
|
if (newSurface instanceof UnaryOperandSurface) {
|
|
234
|
-
newSurface.operand
|
|
205
|
+
newSurface.operand.canRemove = false;
|
|
235
206
|
}
|
|
236
|
-
this.operandSurface
|
|
207
|
+
this.operandSurface = newSurface;
|
|
237
208
|
}
|
|
238
|
-
|
|
239
|
-
|
|
209
|
+
setDisplayValue(newValue) {
|
|
210
|
+
if (this.displayExpressionConverter)
|
|
211
|
+
this.convertedValue = newValue;
|
|
212
|
+
else
|
|
213
|
+
this.value = newValue;
|
|
240
214
|
}
|
|
241
|
-
|
|
242
|
-
|
|
215
|
+
setModelDisplayValue(newValue) {
|
|
216
|
+
if (!this.displayExpressionConverter) {
|
|
217
|
+
this.options.value = newValue;
|
|
218
|
+
return;
|
|
219
|
+
}
|
|
220
|
+
this.convertedModelValue = newValue;
|
|
221
|
+
this.displayExpressionConverter.toRealExpression(this.path, newValue)
|
|
222
|
+
.done((result) => { this.options.value = result; })
|
|
223
|
+
.fail(() => { this.options.value = newValue; });
|
|
243
224
|
}
|
|
244
225
|
dispose() {
|
|
245
226
|
super.dispose();
|
|
246
|
-
this.editorContainer
|
|
247
|
-
this.operandSurface
|
|
227
|
+
this.editorContainer = null;
|
|
228
|
+
this.operandSurface && this.operandSurface.dispose();
|
|
248
229
|
}
|
|
249
230
|
onInput(s, e) {
|
|
250
231
|
const self = this;
|
|
@@ -254,35 +235,35 @@ export class FilterEditor extends CriteriaEditorBase {
|
|
|
254
235
|
}, 200);
|
|
255
236
|
}
|
|
256
237
|
onFocus() {
|
|
257
|
-
this.textFocused
|
|
238
|
+
this.textFocused = true;
|
|
258
239
|
}
|
|
259
240
|
onBlur() {
|
|
260
|
-
this.textFocused
|
|
241
|
+
this.textFocused = false;
|
|
261
242
|
this.helper.onEditorFocusOut(this.operand);
|
|
262
243
|
}
|
|
263
244
|
cacheElement(element) {
|
|
264
|
-
this.editorContainer
|
|
245
|
+
this.editorContainer = dxTextArea.getInstance(element);
|
|
265
246
|
}
|
|
266
247
|
updateCriteria() {
|
|
267
|
-
if (this.isSurfaceValid
|
|
268
|
-
const currentValue = this.operand && this.options
|
|
269
|
-
if (currentValue !== this.value
|
|
270
|
-
this.operand = this._generateOperand(this.value
|
|
271
|
-
this.operandSurface
|
|
272
|
-
this.operandSurface
|
|
248
|
+
if (this.isSurfaceValid) {
|
|
249
|
+
const currentValue = this.operand && this.options.helper.serializer.serialize(this.operand, false);
|
|
250
|
+
if (currentValue !== this.value) {
|
|
251
|
+
this.operand = this._generateOperand(this.value);
|
|
252
|
+
this.operandSurface && this.operandSurface.dispose();
|
|
253
|
+
this.operandSurface = this._generateSurface(this.operand);
|
|
273
254
|
}
|
|
274
255
|
}
|
|
275
256
|
}
|
|
276
257
|
onValueChange(value) {
|
|
277
|
-
if (this.displayValue
|
|
258
|
+
if (this.displayValue === value.trim())
|
|
278
259
|
return;
|
|
279
|
-
this.
|
|
260
|
+
this.setDisplayValue(value);
|
|
280
261
|
if (this.displayExpressionConverter) {
|
|
281
|
-
this.displayExpressionConverter.toRealExpression(this.path
|
|
282
|
-
this.value
|
|
262
|
+
this.displayExpressionConverter.toRealExpression(this.path, value).done((result) => {
|
|
263
|
+
this.value = result;
|
|
283
264
|
this.updateCriteria();
|
|
284
265
|
}).fail(() => {
|
|
285
|
-
this.value
|
|
266
|
+
this.value = value;
|
|
286
267
|
this.updateCriteria();
|
|
287
268
|
});
|
|
288
269
|
}
|
|
@@ -291,22 +272,13 @@ export class FilterEditor extends CriteriaEditorBase {
|
|
|
291
272
|
}
|
|
292
273
|
}
|
|
293
274
|
focusText() {
|
|
294
|
-
|
|
275
|
+
this.withEditorContainer((editor) => {
|
|
295
276
|
setTimeout(_ => {
|
|
296
277
|
if (editor.renderer)
|
|
297
278
|
editor.renderer.updateText();
|
|
298
279
|
editor.focus();
|
|
299
280
|
}, 1);
|
|
300
|
-
};
|
|
301
|
-
if (!this.editorContainer()) {
|
|
302
|
-
const subscription = this.editorContainer.subscribe((editor) => {
|
|
303
|
-
subscription.dispose();
|
|
304
|
-
focusFn(editor);
|
|
305
|
-
});
|
|
306
|
-
}
|
|
307
|
-
else {
|
|
308
|
-
focusFn(this.editorContainer());
|
|
309
|
-
}
|
|
281
|
+
});
|
|
310
282
|
this.notifyResizeListeners();
|
|
311
283
|
}
|
|
312
284
|
setCriteriaValue(value) {
|
|
@@ -316,139 +288,299 @@ export class FilterEditor extends CriteriaEditorBase {
|
|
|
316
288
|
getEditorContext() {
|
|
317
289
|
return {
|
|
318
290
|
isFilter: true,
|
|
319
|
-
value: this.value
|
|
291
|
+
value: this.value
|
|
320
292
|
};
|
|
321
293
|
}
|
|
322
|
-
|
|
323
|
-
|
|
294
|
+
_applyAdvancedMode(newVal) {
|
|
295
|
+
if (newVal === this.advancedMode)
|
|
296
|
+
return;
|
|
297
|
+
this.timeout && clearTimeout(this.timeout);
|
|
298
|
+
this.animationTimeout && clearTimeout(this.animationTimeout);
|
|
299
|
+
if (newVal) {
|
|
300
|
+
this.textVisible = true;
|
|
301
|
+
this.timeout = setTimeout(() => {
|
|
302
|
+
this.advancedMode = true;
|
|
303
|
+
if (!this.options.disabled)
|
|
304
|
+
this.focusText();
|
|
305
|
+
}, 1);
|
|
306
|
+
this.animationTimeout = setTimeout(() => {
|
|
307
|
+
this.editorContainer && this.editorContainer.resize && this.editorContainer.resize();
|
|
308
|
+
}, 210);
|
|
309
|
+
}
|
|
310
|
+
else {
|
|
311
|
+
this.advancedMode = false;
|
|
312
|
+
this.timeout = setTimeout(() => {
|
|
313
|
+
this.textVisible = false;
|
|
314
|
+
}, 200);
|
|
315
|
+
}
|
|
324
316
|
}
|
|
325
|
-
|
|
326
|
-
|
|
317
|
+
onPropertyChanged(args) {
|
|
318
|
+
super.onPropertyChanged(args);
|
|
319
|
+
if (args.propertyName === 'popupVisible')
|
|
320
|
+
this._onPopupVisibleChanged(args.newValue);
|
|
321
|
+
if (args.propertyName === 'advancedModeRequest')
|
|
322
|
+
this._applyAdvancedMode(args.newValue);
|
|
323
|
+
if (args.propertyName === 'advancedMode')
|
|
324
|
+
this.advancedModeRequest = args.newValue;
|
|
325
|
+
}
|
|
326
|
+
getTextCssClasses() {
|
|
327
|
+
return {
|
|
328
|
+
'advanced': this.getViewModel().advancedMode,
|
|
329
|
+
'dx-filtereditor-text-container-bottom': !this.advancedModeTop(),
|
|
330
|
+
'dx-filtereditor-text-container-top': this.advancedModeTop()
|
|
331
|
+
};
|
|
332
|
+
}
|
|
333
|
+
getCheckBoxStyles() {
|
|
334
|
+
const position = {};
|
|
335
|
+
if (this.advancedModeTop())
|
|
336
|
+
position['top'] = '0px';
|
|
337
|
+
else
|
|
338
|
+
position['bottom'] = '0px';
|
|
339
|
+
if (this.advancedModeLeft())
|
|
340
|
+
position['left'] = '0px';
|
|
341
|
+
else
|
|
342
|
+
position['right'] = '0px';
|
|
343
|
+
return position;
|
|
344
|
+
}
|
|
345
|
+
getContentStyles() {
|
|
346
|
+
const styles = {
|
|
347
|
+
pointerEvents: this.getViewModel().disabled ? 'none' : ''
|
|
348
|
+
};
|
|
349
|
+
if (!this.advancedModeTop())
|
|
350
|
+
styles['top'] = '0px';
|
|
351
|
+
return styles;
|
|
352
|
+
}
|
|
353
|
+
getButtonItems() {
|
|
354
|
+
return super.getButtonItems().concat([{
|
|
355
|
+
toolbar: 'bottom', location: 'before', widget: 'dxCheckBox',
|
|
356
|
+
options: {
|
|
357
|
+
value: this.advancedModeRequest,
|
|
358
|
+
text: this.advancedModeText,
|
|
359
|
+
onValueChanged: (e) => { this.advancedModeRequest = e.value; }
|
|
360
|
+
}
|
|
361
|
+
}]);
|
|
362
|
+
}
|
|
363
|
+
updateViewModel(args) {
|
|
364
|
+
super.updateViewModel(args);
|
|
365
|
+
const viewModel = this.getViewModel();
|
|
366
|
+
if (args.propertyName === 'displayValue')
|
|
367
|
+
viewModel.displayValue = this.displayValue;
|
|
368
|
+
if (args.propertyName === 'modelDisplayValue')
|
|
369
|
+
viewModel.modelDisplayValue = this.modelDisplayValue;
|
|
370
|
+
if (args.propertyName === 'helper')
|
|
371
|
+
viewModel.helper = this.helper;
|
|
372
|
+
if (args.propertyName === 'advancedModeRequest')
|
|
373
|
+
this.republishButtonItems();
|
|
374
|
+
if (args.propertyName === 'disabled')
|
|
375
|
+
viewModel.disabled = this.disabled;
|
|
376
|
+
if (args.propertyName === 'title')
|
|
377
|
+
viewModel.title = this.title;
|
|
378
|
+
if (args.propertyName === 'isValid')
|
|
379
|
+
viewModel.isValid = this.isValid;
|
|
380
|
+
if (args.propertyName === 'isSurfaceValid')
|
|
381
|
+
viewModel.isSurfaceValid = this.isSurfaceValid;
|
|
382
|
+
if (args.propertyName === 'modelValueIsValid')
|
|
383
|
+
viewModel.modelValueIsValid = this.modelValueIsValid;
|
|
384
|
+
if (args.propertyName === 'textFocused')
|
|
385
|
+
viewModel.textFocused = this.textFocused;
|
|
386
|
+
if (args.propertyName === 'textVisible')
|
|
387
|
+
viewModel.textVisible = this.textVisible;
|
|
388
|
+
if (args.propertyName === 'advancedMode')
|
|
389
|
+
viewModel.advancedMode = this.advancedMode;
|
|
390
|
+
if (args.propertyName === 'advancedModeRequest')
|
|
391
|
+
viewModel.advancedModeRequest = this.advancedModeRequest;
|
|
392
|
+
if (args.propertyName === 'operandSurface') {
|
|
393
|
+
viewModel.operandSurface = this.operandSurface && this.operandSurface.getViewModel();
|
|
394
|
+
}
|
|
395
|
+
if (args.propertyName === 'aiFilterGenerator')
|
|
396
|
+
viewModel.aiFilterGenerator = this.aiFilterGenerator;
|
|
397
|
+
}
|
|
398
|
+
createViewModel() {
|
|
399
|
+
return createViewModelGenerator(super.createViewModel())
|
|
400
|
+
.generateProperty('disabled', this.disabled)
|
|
401
|
+
.generateProperty('title', this.title)
|
|
402
|
+
.generateProperty('editorInputId', this.editorInputId)
|
|
403
|
+
.generateProperty('rtl', this.rtl)
|
|
404
|
+
.generateProperty('helper', this.helper)
|
|
405
|
+
.generateProperty('popupService', this.popupService.getViewModel())
|
|
406
|
+
.generateProperty('modelDisplayValue', this.modelDisplayValue)
|
|
407
|
+
.generateProperty('onModelDisplayValueChanged', (e) => { this.setModelDisplayValue(e.value); })
|
|
408
|
+
.generateProperty('modelValueIsValid', this.modelValueIsValid)
|
|
409
|
+
.generateProperty('displayValue', this.displayValue)
|
|
410
|
+
.generateProperty('displayValueSource', createValueAccessor(this, 'displayValue'))
|
|
411
|
+
.generateProperty('isValid', this.isValid)
|
|
412
|
+
.generateProperty('onInput', (sender, e) => this.onInput(sender, e))
|
|
413
|
+
.generateProperty('cacheElement', (element) => this.cacheElement(element))
|
|
414
|
+
.generateProperty('setEditorContainer', (editor) => { this.editorContainer = editor; })
|
|
415
|
+
.generateProperty('textFocused', this.textFocused)
|
|
416
|
+
.generateProperty('textVisible', this.textVisible)
|
|
417
|
+
.generateProperty('aceOptions', this.aceOptions)
|
|
418
|
+
.generateProperty('additionalOptions', this.additionalOptions)
|
|
419
|
+
.generateProperty('languageHelper', this.languageHelper)
|
|
420
|
+
.generateProperty('advancedMode', this.advancedMode)
|
|
421
|
+
.generateProperty('advancedModeRequest', this.advancedModeRequest)
|
|
422
|
+
.generateProperty('onAdvancedModeRequestChanged', (e) => { this.advancedModeRequest = e.value; })
|
|
423
|
+
.generateProperty('advancedModeText', this.advancedModeText)
|
|
424
|
+
.generateProperty('requestAdvancedMode', () => { this.advancedModeRequest = true; })
|
|
425
|
+
.generateProperty('advancedModeTop', () => this.advancedModeTop())
|
|
426
|
+
.generateProperty('getTextCssClasses', () => this.getTextCssClasses())
|
|
427
|
+
.generateProperty('getCheckBoxStyles', () => this.getCheckBoxStyles())
|
|
428
|
+
.generateProperty('getContentStyles', () => this.getContentStyles())
|
|
429
|
+
.generateProperty('operandSurface', this.operandSurface && this.operandSurface.getViewModel())
|
|
430
|
+
.generateProperty('isSurfaceValid', this.isSurfaceValid)
|
|
431
|
+
.generateProperty('invalidMessage', () => this.invalidMessage())
|
|
432
|
+
.generateProperty('aiFilterGenerator', this.aiFilterGenerator)
|
|
433
|
+
.generateProperty('focusText', () => this.focusText())
|
|
434
|
+
.generateProperty('getPopupContainer', (element) => this.getPopupContainer(element))
|
|
435
|
+
.generateProperty('createAddButton', (criteria) => this.createAddButton(criteria))
|
|
436
|
+
.generateProperty('createChangeType', (criteria) => this.createChangeType(criteria))
|
|
437
|
+
.generateProperty('createChangeProperty', (criteria) => this.createChangeProperty(criteria))
|
|
438
|
+
.generateProperty('createChangeParameter', (criteria) => this.createChangeParameter(criteria))
|
|
439
|
+
.generateProperty('createChangeValueType', (criteria) => this.createChangeValueType(criteria))
|
|
440
|
+
.getViewModel();
|
|
327
441
|
}
|
|
328
442
|
}
|
|
329
|
-
|
|
330
|
-
|
|
443
|
+
__decorate([
|
|
444
|
+
mutable(false)
|
|
445
|
+
], FilterEditor.prototype, "advancedMode", void 0);
|
|
446
|
+
__decorate([
|
|
447
|
+
mutable(false)
|
|
448
|
+
], FilterEditor.prototype, "advancedModeRequest", void 0);
|
|
449
|
+
__decorate([
|
|
450
|
+
mutable(false)
|
|
451
|
+
], FilterEditor.prototype, "disabled", void 0);
|
|
452
|
+
__decorate([
|
|
453
|
+
mutable('')
|
|
454
|
+
], FilterEditor.prototype, "title", void 0);
|
|
455
|
+
__decorate([
|
|
456
|
+
mutable(false)
|
|
457
|
+
], FilterEditor.prototype, "modelValueIsValid", void 0);
|
|
458
|
+
__decorate([
|
|
459
|
+
mutable(false)
|
|
460
|
+
], FilterEditor.prototype, "isSurfaceValid", void 0);
|
|
461
|
+
__decorate([
|
|
462
|
+
mutable(false)
|
|
463
|
+
], FilterEditor.prototype, "isValid", void 0);
|
|
464
|
+
__decorate([
|
|
465
|
+
mutable(false)
|
|
466
|
+
], FilterEditor.prototype, "textFocused", void 0);
|
|
467
|
+
__decorate([
|
|
468
|
+
mutable(false)
|
|
469
|
+
], FilterEditor.prototype, "textVisible", void 0);
|
|
470
|
+
__decorate([
|
|
471
|
+
mutable(null)
|
|
472
|
+
], FilterEditor.prototype, "aiFilterGenerator", void 0);
|
|
473
|
+
__decorate([
|
|
474
|
+
mutable(null)
|
|
475
|
+
], FilterEditor.prototype, "operandSurface", void 0);
|
|
476
|
+
function resolveFieldList(values, viewModel) {
|
|
477
|
+
const fromTemplate = toAccessor(values.fieldListProvider);
|
|
478
|
+
const fromViewModel = {
|
|
479
|
+
getValue: () => viewModel?.fieldListProvider,
|
|
480
|
+
setValueChangedEvent: viewModel?.setFieldListProviderChangedEvent
|
|
481
|
+
};
|
|
482
|
+
return !fromTemplate.setValueChangedEvent && fromViewModel.setValueChangedEvent ? fromViewModel : fromTemplate;
|
|
483
|
+
}
|
|
484
|
+
registerKoBinding('dxFilterEditor', {
|
|
485
|
+
init: function (element, valueAccessor, bindings, viewModel, bindingContext) {
|
|
331
486
|
const values = valueAccessor();
|
|
487
|
+
values.onInitialized?.({ element });
|
|
332
488
|
const templateHtml = getTemplate(values.templateName || 'dx-filtereditor');
|
|
333
489
|
const $element = $dx(element).empty().addClass('dx-popup-general').append(templateHtml);
|
|
334
|
-
const
|
|
335
|
-
const
|
|
336
|
-
const
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
itemsProvider(ko.unwrap(values.fieldListProvider));
|
|
343
|
-
}
|
|
344
|
-
}));
|
|
345
|
-
computedFunctions.push(ko.computed(() => {
|
|
346
|
-
if (values.getDisplayNameByPath && options() && options().helper && !options().helper.getDisplayPropertyName) {
|
|
347
|
-
options().helper.getDisplayPropertyName = values.getDisplayNameByPath;
|
|
490
|
+
const releases = [];
|
|
491
|
+
const options = toAccessor(values.options);
|
|
492
|
+
const fieldList = resolveFieldList(values, viewModel);
|
|
493
|
+
const itemsProvider = createDerivedAccessor(() => options.getValue()?.itemsProvider || fieldList.getValue(), () => [options, fieldList]);
|
|
494
|
+
releases.push(followSources(() => [options, fieldList], () => {
|
|
495
|
+
const current = options.getValue();
|
|
496
|
+
if (values.getDisplayNameByPath && current && current.helper && !current.helper.getDisplayPropertyName) {
|
|
497
|
+
current.helper.getDisplayPropertyName = values.getDisplayNameByPath;
|
|
348
498
|
}
|
|
349
499
|
}));
|
|
350
500
|
const editor = new FilterEditor(options, itemsProvider, $element.closest('.dx-rtl').length > 0, values.displayNameProvider, viewModel.editorInputId);
|
|
351
501
|
if (values.aiExpressionGenerator) {
|
|
352
502
|
editor.aiFilterGenerator = values.aiExpressionGenerator.initialize(editor);
|
|
353
503
|
}
|
|
354
|
-
if (values.popupVisible) {
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
editor.popupVisible(newVal);
|
|
504
|
+
if (values.popupVisible !== undefined) {
|
|
505
|
+
const popupVisible = toAccessor(values.popupVisible);
|
|
506
|
+
editor.popupVisible = popupVisible.getValue();
|
|
507
|
+
releases.push(subscribeProperty(editor, 'popupVisible', (newVal) => { popupVisible.setValue?.(newVal); }));
|
|
508
|
+
popupVisible.setValueChangedEvent && releases.push(popupVisible.setValueChangedEvent((newVal) => {
|
|
509
|
+
editor.popupVisible = newVal;
|
|
361
510
|
}));
|
|
362
511
|
}
|
|
363
|
-
|
|
512
|
+
currentRenderingEngine.applyBindingsToDescendants(editor.getViewModel(), $element.children()[0]);
|
|
364
513
|
addDisposeCallback($element.children()[0], () => {
|
|
365
|
-
|
|
366
|
-
options.dispose();
|
|
514
|
+
releases.forEach(release => release());
|
|
367
515
|
editor.dispose();
|
|
368
516
|
});
|
|
369
517
|
return { controlsDescendantBindings: true };
|
|
370
518
|
}
|
|
371
|
-
};
|
|
519
|
+
});
|
|
372
520
|
export class FilterEditorPlain extends FilterEditor {
|
|
373
521
|
constructor(element, options, fieldListProvider, rtl = false, _displayNameProvider) {
|
|
374
522
|
super(options, fieldListProvider, rtl, _displayNameProvider);
|
|
375
523
|
this.element = element;
|
|
376
|
-
this.
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
this.
|
|
524
|
+
this.advancedModePosition = this.options.advancedModePosition;
|
|
525
|
+
}
|
|
526
|
+
get _realTimeUpdate() {
|
|
527
|
+
return !!this.options?.realTimeUpdate;
|
|
380
528
|
}
|
|
381
529
|
initializeInnerValue() {
|
|
382
|
-
if (this.
|
|
383
|
-
this.value
|
|
384
|
-
|
|
385
|
-
this.
|
|
386
|
-
valueUpdateTimeout && clearTimeout(valueUpdateTimeout);
|
|
387
|
-
valueUpdateTimeout = setTimeout(() => {
|
|
388
|
-
this.updateCriteria();
|
|
389
|
-
}, 100);
|
|
390
|
-
}));
|
|
530
|
+
if (this._realTimeUpdate) {
|
|
531
|
+
this.assignProperty('value', this.options.value);
|
|
532
|
+
this._updateCriteriaLater = debounced(() => this.updateCriteria(), 100);
|
|
533
|
+
this.addDisposable(followSources(() => [subscribableProperty(this.options, ['value'])], () => { this.value = this.options.value; }, false));
|
|
391
534
|
}
|
|
392
535
|
else {
|
|
393
536
|
super.initializeInnerValue();
|
|
394
537
|
}
|
|
395
538
|
}
|
|
396
|
-
|
|
397
|
-
|
|
398
|
-
if (this.
|
|
399
|
-
|
|
400
|
-
|
|
401
|
-
|
|
402
|
-
if (this.advancedModeLeft())
|
|
403
|
-
position['left'] = '0px';
|
|
404
|
-
else
|
|
405
|
-
position['right'] = '0px';
|
|
406
|
-
return position;
|
|
407
|
-
}
|
|
408
|
-
getContentStyles() {
|
|
409
|
-
const styles = {
|
|
410
|
-
pointerEvents: this.options().disabled() ? 'none' : ''
|
|
411
|
-
};
|
|
412
|
-
if (!this.advancedModeTop())
|
|
413
|
-
styles['top'] = '0px';
|
|
414
|
-
return styles;
|
|
415
|
-
}
|
|
416
|
-
getTextCssClasses() {
|
|
417
|
-
return {
|
|
418
|
-
'advanced': this.advancedMode(),
|
|
419
|
-
'dx-filtereditor-text-container-bottom': !this.advancedModeTop(),
|
|
420
|
-
'dx-filtereditor-text-container-top': this.advancedModeTop()
|
|
421
|
-
};
|
|
539
|
+
onPropertyChanged(args) {
|
|
540
|
+
super.onPropertyChanged(args);
|
|
541
|
+
if (args.propertyName === 'value' && this._realTimeUpdate) {
|
|
542
|
+
this.options.value = this.value;
|
|
543
|
+
this._updateCriteriaLater && this._updateCriteriaLater();
|
|
544
|
+
}
|
|
422
545
|
}
|
|
423
546
|
}
|
|
424
|
-
|
|
547
|
+
function asComponentViewModel(editor) {
|
|
548
|
+
const viewModel = editor.getViewModel();
|
|
549
|
+
viewModel.dispose = () => editor.dispose();
|
|
550
|
+
return viewModel;
|
|
551
|
+
}
|
|
552
|
+
registerKoComponent('dx-filtereditor-plain', {
|
|
425
553
|
viewModel: {
|
|
426
554
|
createViewModel: (params, componentInfo) => {
|
|
427
|
-
const
|
|
428
|
-
|
|
429
|
-
return
|
|
555
|
+
const editor = new FilterEditorPlain(componentInfo.element, toAccessor(params.options), toAccessor(params.fieldListProvider), undefined, params.displayNameProvider);
|
|
556
|
+
editor.popupVisible = true;
|
|
557
|
+
return asComponentViewModel(editor);
|
|
430
558
|
}
|
|
431
559
|
},
|
|
432
560
|
template: getTemplate('dx-filtereditor-plain')
|
|
433
561
|
});
|
|
434
|
-
|
|
562
|
+
registerKoComponent('dx-filtereditor-advanced', {
|
|
435
563
|
viewModel: {
|
|
436
564
|
createViewModel: (params, componentInfo) => {
|
|
437
|
-
const
|
|
438
|
-
|
|
439
|
-
|
|
440
|
-
|
|
441
|
-
|
|
442
|
-
|
|
443
|
-
|
|
444
|
-
|
|
565
|
+
const options = toAccessor(params.options);
|
|
566
|
+
const editor = new FilterEditor(options, toAccessor(params.fieldListProvider), undefined, params.displayNameProvider);
|
|
567
|
+
editor.advancedModeRequest = true;
|
|
568
|
+
editor.popupVisible = true;
|
|
569
|
+
editor.addDisposable(followSources(() => {
|
|
570
|
+
const current = options.getValue();
|
|
571
|
+
return [options, current && subscribableProperty(current, ['value'])];
|
|
572
|
+
}, () => {
|
|
573
|
+
editor.popupVisible = false;
|
|
574
|
+
editor.popupVisible = true;
|
|
575
|
+
}, false));
|
|
576
|
+
return asComponentViewModel(editor);
|
|
445
577
|
}
|
|
446
578
|
},
|
|
447
579
|
template: getTemplate('dx-filtereditor-advanced')
|
|
448
580
|
});
|
|
449
|
-
|
|
581
|
+
registerKoBinding('cacheElement', {
|
|
450
582
|
init: function (element, valueAccessor, allBindings, viewModel, bindingContext) {
|
|
451
583
|
const value = valueAccessor();
|
|
452
584
|
value.action(element);
|
|
453
585
|
}
|
|
454
|
-
};
|
|
586
|
+
});
|