@siliconst/metaui 1.2.0 → 1.4.5
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 +102 -33
- package/package.json +1 -1
- package/src/nz/co/siliconst/ui5/metaui/controls/BaseHardwareControl-dbg.js +70 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/BaseHardwareControl-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/BaseHardwareControl.d.ts +67 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/BaseHardwareControl.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/BaseHardwareControl.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/BaseHardwareControl.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/BaseHardwareControl.ts +58 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/BaseHardwareControlRenderer-dbg.js +28 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/BaseHardwareControlRenderer-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/BaseHardwareControlRenderer.d.ts +16 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/BaseHardwareControlRenderer.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/BaseHardwareControlRenderer.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/BaseHardwareControlRenderer.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/BaseHardwareControlRenderer.ts +28 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/CameraControl-dbg.js +142 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/CameraControl-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/CameraControl.d.ts +33 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/CameraControl.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/CameraControl.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/CameraControl.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/CameraControl.ts +164 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/DynamicHost-dbg.js +305 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/DynamicHost-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/DynamicHost.d.ts +168 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/DynamicHost.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/DynamicHost.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/DynamicHost.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/DynamicHost.ts +247 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/GeolocationControl-dbg.js +73 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/GeolocationControl-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/GeolocationControl.d.ts +32 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/GeolocationControl.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/GeolocationControl.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/GeolocationControl.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/GeolocationControl.ts +86 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/RichTextControl-dbg.js +60 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/RichTextControl-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/RichTextControl.d.ts +32 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/RichTextControl.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/RichTextControl.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/RichTextControl.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/RichTextControl.ts +61 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/SignatureControl-dbg.js +157 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/SignatureControl-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/SignatureControl.d.ts +33 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/SignatureControl.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/SignatureControl.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/SignatureControl.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/SignatureControl.ts +169 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/VoiceInputControl-dbg.js +160 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/VoiceInputControl-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/VoiceInputControl.d.ts +28 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/VoiceInputControl.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/VoiceInputControl.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/VoiceInputControl.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/VoiceInputControl.ts +185 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/host/GeneratorHost-dbg.js +443 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/host/GeneratorHost-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/host/GeneratorHost.d.ts +227 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/host/GeneratorHost.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/host/GeneratorHost.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/host/GeneratorHost.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/host/GeneratorHost.ts +421 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/host/delegates/DataSyncDelegate-dbg.js +103 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/host/delegates/DataSyncDelegate-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/host/delegates/DataSyncDelegate.d.ts +32 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/host/delegates/DataSyncDelegate.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/host/delegates/DataSyncDelegate.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/host/delegates/DataSyncDelegate.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/host/delegates/DataSyncDelegate.ts +119 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/host/delegates/DialogDelegate-dbg.js +64 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/host/delegates/DialogDelegate-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/host/delegates/DialogDelegate.d.ts +21 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/host/delegates/DialogDelegate.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/host/delegates/DialogDelegate.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/host/delegates/DialogDelegate.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/host/delegates/DialogDelegate.ts +64 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/host/delegates/ODataDelegate-dbg.js +122 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/host/delegates/ODataDelegate-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/host/delegates/ODataDelegate.d.ts +49 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/host/delegates/ODataDelegate.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/host/delegates/ODataDelegate.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/host/delegates/ODataDelegate.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/host/delegates/ODataDelegate.ts +118 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/host/delegates/ValidationDelegate-dbg.js +120 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/host/delegates/ValidationDelegate-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/host/delegates/ValidationDelegate.d.ts +45 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/host/delegates/ValidationDelegate.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/host/delegates/ValidationDelegate.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/host/delegates/ValidationDelegate.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/host/delegates/ValidationDelegate.ts +131 -0
- package/src/nz/co/siliconst/ui5/metaui/core/ConditionEngine-dbg.js +40 -15
- package/src/nz/co/siliconst/ui5/metaui/core/ConditionEngine-dbg.js.map +1 -1
- package/src/nz/co/siliconst/ui5/metaui/core/ConditionEngine.d.ts +27 -7
- package/src/nz/co/siliconst/ui5/metaui/core/ConditionEngine.d.ts.map +1 -1
- package/src/nz/co/siliconst/ui5/metaui/core/ConditionEngine.js +1 -1
- package/src/nz/co/siliconst/ui5/metaui/core/ConditionEngine.js.map +1 -1
- package/src/nz/co/siliconst/ui5/metaui/core/ConditionEngine.ts +41 -15
- package/src/nz/co/siliconst/ui5/metaui/core/DefaultLayoutGenerator-dbg.js +78 -0
- package/src/nz/co/siliconst/ui5/metaui/core/DefaultLayoutGenerator-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/core/DefaultLayoutGenerator.d.ts +27 -0
- package/src/nz/co/siliconst/ui5/metaui/core/DefaultLayoutGenerator.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/core/DefaultLayoutGenerator.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/core/DefaultLayoutGenerator.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/core/DefaultLayoutGenerator.ts +79 -0
- package/src/nz/co/siliconst/ui5/metaui/core/Engine-dbg.js +159 -43
- package/src/nz/co/siliconst/ui5/metaui/core/Engine-dbg.js.map +1 -1
- package/src/nz/co/siliconst/ui5/metaui/core/Engine.d.ts +64 -3
- package/src/nz/co/siliconst/ui5/metaui/core/Engine.d.ts.map +1 -1
- package/src/nz/co/siliconst/ui5/metaui/core/Engine.js +1 -1
- package/src/nz/co/siliconst/ui5/metaui/core/Engine.js.map +1 -1
- package/src/nz/co/siliconst/ui5/metaui/core/Engine.ts +166 -43
- package/src/nz/co/siliconst/ui5/metaui/core/LayoutRegistry-dbg.js +32 -0
- package/src/nz/co/siliconst/ui5/metaui/core/LayoutRegistry-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/core/LayoutRegistry.d.ts +16 -0
- package/src/nz/co/siliconst/ui5/metaui/core/LayoutRegistry.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/core/LayoutRegistry.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/core/LayoutRegistry.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/core/LayoutRegistry.ts +26 -0
- package/src/nz/co/siliconst/ui5/metaui/core/PipelineManager-dbg.js +123 -0
- package/src/nz/co/siliconst/ui5/metaui/core/PipelineManager-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/core/PipelineManager.d.ts +49 -0
- package/src/nz/co/siliconst/ui5/metaui/core/PipelineManager.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/core/PipelineManager.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/core/PipelineManager.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/core/PipelineManager.ts +106 -0
- package/src/nz/co/siliconst/ui5/metaui/core/PluginRegistry-dbg.js +104 -25
- package/src/nz/co/siliconst/ui5/metaui/core/PluginRegistry-dbg.js.map +1 -1
- package/src/nz/co/siliconst/ui5/metaui/core/PluginRegistry.d.ts +21 -13
- package/src/nz/co/siliconst/ui5/metaui/core/PluginRegistry.d.ts.map +1 -1
- package/src/nz/co/siliconst/ui5/metaui/core/PluginRegistry.js +1 -1
- package/src/nz/co/siliconst/ui5/metaui/core/PluginRegistry.js.map +1 -1
- package/src/nz/co/siliconst/ui5/metaui/core/PluginRegistry.ts +110 -21
- package/src/nz/co/siliconst/ui5/metaui/core/Registry-dbg.js +79 -0
- package/src/nz/co/siliconst/ui5/metaui/core/Registry-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/core/Registry.d.ts +43 -0
- package/src/nz/co/siliconst/ui5/metaui/core/Registry.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/core/Registry.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/core/Registry.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/core/Registry.ts +70 -0
- package/src/nz/co/siliconst/ui5/metaui/core/SchemaNormalizer-dbg.js +116 -21
- package/src/nz/co/siliconst/ui5/metaui/core/SchemaNormalizer-dbg.js.map +1 -1
- package/src/nz/co/siliconst/ui5/metaui/core/SchemaNormalizer.d.ts +11 -1
- package/src/nz/co/siliconst/ui5/metaui/core/SchemaNormalizer.d.ts.map +1 -1
- package/src/nz/co/siliconst/ui5/metaui/core/SchemaNormalizer.js +1 -1
- package/src/nz/co/siliconst/ui5/metaui/core/SchemaNormalizer.js.map +1 -1
- package/src/nz/co/siliconst/ui5/metaui/core/SchemaNormalizer.ts +115 -21
- package/src/nz/co/siliconst/ui5/metaui/core/SchemaValidator-dbg.js +54 -0
- package/src/nz/co/siliconst/ui5/metaui/core/SchemaValidator-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/core/SchemaValidator.d.ts +11 -0
- package/src/nz/co/siliconst/ui5/metaui/core/SchemaValidator.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/core/SchemaValidator.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/core/SchemaValidator.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/core/SchemaValidator.ts +53 -0
- package/src/nz/co/siliconst/ui5/metaui/core/StateManager-dbg.js +88 -2
- package/src/nz/co/siliconst/ui5/metaui/core/StateManager-dbg.js.map +1 -1
- package/src/nz/co/siliconst/ui5/metaui/core/StateManager.d.ts +15 -1
- package/src/nz/co/siliconst/ui5/metaui/core/StateManager.d.ts.map +1 -1
- package/src/nz/co/siliconst/ui5/metaui/core/StateManager.js +1 -1
- package/src/nz/co/siliconst/ui5/metaui/core/StateManager.js.map +1 -1
- package/src/nz/co/siliconst/ui5/metaui/core/StateManager.ts +103 -1
- package/src/nz/co/siliconst/ui5/metaui/interfaces/ILayoutManager-dbg.js.map +1 -1
- package/src/nz/co/siliconst/ui5/metaui/interfaces/ILayoutManager.d.ts +7 -8
- package/src/nz/co/siliconst/ui5/metaui/interfaces/ILayoutManager.d.ts.map +1 -1
- package/src/nz/co/siliconst/ui5/metaui/interfaces/ILayoutManager.ts +7 -7
- package/src/nz/co/siliconst/ui5/metaui/interfaces/IPipeline-dbg.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/interfaces/IPipeline-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/interfaces/IPipeline.d.ts +38 -0
- package/src/nz/co/siliconst/ui5/metaui/interfaces/IPipeline.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/interfaces/IPipeline.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/interfaces/IPipeline.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/interfaces/IPipeline.ts +39 -0
- package/src/nz/co/siliconst/ui5/metaui/interfaces/IPlugin-dbg.js.map +1 -1
- package/src/nz/co/siliconst/ui5/metaui/interfaces/IPlugin.d.ts +38 -2
- package/src/nz/co/siliconst/ui5/metaui/interfaces/IPlugin.d.ts.map +1 -1
- package/src/nz/co/siliconst/ui5/metaui/interfaces/IPlugin.ts +43 -2
- package/src/nz/co/siliconst/ui5/metaui/interfaces/ISchema-dbg.js.map +1 -1
- package/src/nz/co/siliconst/ui5/metaui/interfaces/ISchema.d.ts +32 -3
- package/src/nz/co/siliconst/ui5/metaui/interfaces/ISchema.d.ts.map +1 -1
- package/src/nz/co/siliconst/ui5/metaui/interfaces/ISchema.ts +35 -3
- package/src/nz/co/siliconst/ui5/metaui/layouts/CompactLayout-dbg.js +148 -0
- package/src/nz/co/siliconst/ui5/metaui/layouts/CompactLayout-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/layouts/CompactLayout.d.ts +27 -0
- package/src/nz/co/siliconst/ui5/metaui/layouts/CompactLayout.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/layouts/CompactLayout.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/layouts/CompactLayout.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/layouts/CompactLayout.ts +139 -0
- package/src/nz/co/siliconst/ui5/metaui/layouts/FormLayout-dbg.js +136 -61
- package/src/nz/co/siliconst/ui5/metaui/layouts/FormLayout-dbg.js.map +1 -1
- package/src/nz/co/siliconst/ui5/metaui/layouts/FormLayout.d.ts +19 -12
- package/src/nz/co/siliconst/ui5/metaui/layouts/FormLayout.d.ts.map +1 -1
- package/src/nz/co/siliconst/ui5/metaui/layouts/FormLayout.js +1 -1
- package/src/nz/co/siliconst/ui5/metaui/layouts/FormLayout.js.map +1 -1
- package/src/nz/co/siliconst/ui5/metaui/layouts/FormLayout.ts +135 -71
- package/src/nz/co/siliconst/ui5/metaui/layouts/TableLayout-dbg.js +111 -51
- package/src/nz/co/siliconst/ui5/metaui/layouts/TableLayout-dbg.js.map +1 -1
- package/src/nz/co/siliconst/ui5/metaui/layouts/TableLayout.d.ts +21 -8
- package/src/nz/co/siliconst/ui5/metaui/layouts/TableLayout.d.ts.map +1 -1
- package/src/nz/co/siliconst/ui5/metaui/layouts/TableLayout.js +1 -1
- package/src/nz/co/siliconst/ui5/metaui/layouts/TableLayout.js.map +1 -1
- package/src/nz/co/siliconst/ui5/metaui/layouts/TableLayout.ts +123 -65
- package/src/nz/co/siliconst/ui5/metaui/layouts/WizardLayout-dbg.js +129 -0
- package/src/nz/co/siliconst/ui5/metaui/layouts/WizardLayout-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/layouts/WizardLayout.d.ts +28 -0
- package/src/nz/co/siliconst/ui5/metaui/layouts/WizardLayout.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/layouts/WizardLayout.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/layouts/WizardLayout.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/layouts/WizardLayout.ts +127 -0
- package/src/nz/co/siliconst/ui5/metaui/library-dbg.js +17 -12
- package/src/nz/co/siliconst/ui5/metaui/library-dbg.js.map +1 -1
- package/src/nz/co/siliconst/ui5/metaui/library-preload.js +73 -25
- package/src/nz/co/siliconst/ui5/metaui/library-preload.js.map +1 -1
- package/src/nz/co/siliconst/ui5/metaui/library.d.ts +1 -0
- package/src/nz/co/siliconst/ui5/metaui/library.d.ts.map +1 -1
- package/src/nz/co/siliconst/ui5/metaui/library.js +1 -1
- package/src/nz/co/siliconst/ui5/metaui/library.js.map +1 -1
- package/src/nz/co/siliconst/ui5/metaui/library.ts +25 -12
- package/src/nz/co/siliconst/ui5/metaui/manifest.json +8 -1
- package/src/nz/co/siliconst/ui5/metaui/plugins/actions/ClearFormActionPlugin-dbg.js +58 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/actions/ClearFormActionPlugin-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/actions/ClearFormActionPlugin.d.ts +22 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/actions/ClearFormActionPlugin.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/actions/ClearFormActionPlugin.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/actions/ClearFormActionPlugin.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/actions/ClearFormActionPlugin.ts +57 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/actions/SubmitFormActionPlugin-dbg.js +55 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/actions/SubmitFormActionPlugin-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/actions/SubmitFormActionPlugin.d.ts +21 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/actions/SubmitFormActionPlugin.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/actions/SubmitFormActionPlugin.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/actions/SubmitFormActionPlugin.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/actions/SubmitFormActionPlugin.ts +54 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/actions/UrlNavigationActionPlugin-dbg.js +46 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/actions/UrlNavigationActionPlugin-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/actions/UrlNavigationActionPlugin.d.ts +23 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/actions/UrlNavigationActionPlugin.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/actions/UrlNavigationActionPlugin.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/actions/UrlNavigationActionPlugin.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/actions/UrlNavigationActionPlugin.ts +45 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/ArrayPlugin-dbg.js +74 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/ArrayPlugin-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/ArrayPlugin.d.ts +15 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/ArrayPlugin.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/ArrayPlugin.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/ArrayPlugin.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/ArrayPlugin.ts +80 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/BarcodeScannerPlugin-dbg.js +75 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/BarcodeScannerPlugin-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/BarcodeScannerPlugin.d.ts +12 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/BarcodeScannerPlugin.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/BarcodeScannerPlugin.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/BarcodeScannerPlugin.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/BarcodeScannerPlugin.ts +83 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/BasePlugin-dbg.js +174 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/BasePlugin-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/BasePlugin.d.ts +78 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/BasePlugin.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/BasePlugin.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/BasePlugin.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/BasePlugin.ts +165 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/BooleanPlugin-dbg.js +79 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/BooleanPlugin-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/BooleanPlugin.d.ts +36 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/BooleanPlugin.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/BooleanPlugin.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/BooleanPlugin.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/BooleanPlugin.ts +77 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/CameraPlugin-dbg.js +60 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/CameraPlugin-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/CameraPlugin.d.ts +11 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/CameraPlugin.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/CameraPlugin.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/CameraPlugin.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/CameraPlugin.ts +56 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/CodeEditorPlugin-dbg.js +122 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/CodeEditorPlugin-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/CodeEditorPlugin.d.ts +24 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/CodeEditorPlugin.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/CodeEditorPlugin.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/CodeEditorPlugin.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/CodeEditorPlugin.ts +125 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/{DatePlugin-dbg.js → controls/DatePlugin-dbg.js} +29 -20
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/DatePlugin-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/{DatePlugin.d.ts → controls/DatePlugin.d.ts} +4 -4
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/DatePlugin.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/DatePlugin.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/DatePlugin.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/DatePlugin.ts +74 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/{DateTimePlugin-dbg.js → controls/DateTimePlugin-dbg.js} +30 -20
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/DateTimePlugin-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/{DateTimePlugin.d.ts → controls/DateTimePlugin.d.ts} +4 -4
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/DateTimePlugin.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/DateTimePlugin.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/DateTimePlugin.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/DateTimePlugin.ts +75 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/DropdownPlugin-dbg.js +109 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/DropdownPlugin-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/DropdownPlugin.d.ts +37 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/DropdownPlugin.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/DropdownPlugin.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/DropdownPlugin.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/DropdownPlugin.ts +105 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/FileUploaderPlugin-dbg.js +65 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/FileUploaderPlugin-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/FileUploaderPlugin.d.ts +21 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/FileUploaderPlugin.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/FileUploaderPlugin.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/FileUploaderPlugin.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/FileUploaderPlugin.ts +64 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/GeolocationPlugin-dbg.js +59 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/GeolocationPlugin-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/GeolocationPlugin.d.ts +11 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/GeolocationPlugin.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/GeolocationPlugin.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/GeolocationPlugin.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/GeolocationPlugin.ts +56 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/MessageStripPlugin-dbg.js +45 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/MessageStripPlugin-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/MessageStripPlugin.d.ts +22 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/MessageStripPlugin.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/MessageStripPlugin.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/MessageStripPlugin.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/MessageStripPlugin.ts +42 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/MultiSelectPlugin-dbg.js +74 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/MultiSelectPlugin-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/MultiSelectPlugin.d.ts +22 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/MultiSelectPlugin.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/MultiSelectPlugin.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/MultiSelectPlugin.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/MultiSelectPlugin.ts +73 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/{NumberPlugin-dbg.js → controls/NumberPlugin-dbg.js} +21 -16
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/NumberPlugin-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/{NumberPlugin.d.ts → controls/NumberPlugin.d.ts} +4 -4
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/NumberPlugin.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/NumberPlugin.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/NumberPlugin.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/NumberPlugin.ts +62 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/ObjectPlugin-dbg.js +74 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/ObjectPlugin-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/ObjectPlugin.d.ts +17 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/ObjectPlugin.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/ObjectPlugin.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/ObjectPlugin.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/ObjectPlugin.ts +81 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/RatingIndicatorPlugin-dbg.js +61 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/RatingIndicatorPlugin-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/RatingIndicatorPlugin.d.ts +21 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/RatingIndicatorPlugin.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/RatingIndicatorPlugin.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/RatingIndicatorPlugin.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/RatingIndicatorPlugin.ts +62 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/RichTextPlugin-dbg.js +64 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/RichTextPlugin-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/RichTextPlugin.d.ts +16 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/RichTextPlugin.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/RichTextPlugin.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/RichTextPlugin.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/RichTextPlugin.ts +67 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/SignaturePlugin-dbg.js +58 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/SignaturePlugin-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/SignaturePlugin.d.ts +11 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/SignaturePlugin.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/SignaturePlugin.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/SignaturePlugin.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/SignaturePlugin.ts +55 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/SliderPlugin-dbg.js +64 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/SliderPlugin-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/SliderPlugin.d.ts +21 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/SliderPlugin.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/SliderPlugin.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/SliderPlugin.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/SliderPlugin.ts +65 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/StringPlugin-dbg.js +87 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/StringPlugin-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/StringPlugin.d.ts +37 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/StringPlugin.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/StringPlugin.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/StringPlugin.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/StringPlugin.ts +85 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/{SwitchPlugin-dbg.js → controls/SwitchPlugin-dbg.js} +24 -6
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/SwitchPlugin-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/{SwitchPlugin.d.ts → controls/SwitchPlugin.d.ts} +4 -4
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/SwitchPlugin.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/SwitchPlugin.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/SwitchPlugin.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/SwitchPlugin.ts +62 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/{TextAreaPlugin-dbg.js → controls/TextAreaPlugin-dbg.js} +20 -14
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/TextAreaPlugin-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/{TextAreaPlugin.d.ts → controls/TextAreaPlugin.d.ts} +4 -4
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/TextAreaPlugin.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/TextAreaPlugin.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/TextAreaPlugin.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/TextAreaPlugin.ts +63 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/{TimePlugin-dbg.js → controls/TimePlugin-dbg.js} +30 -25
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/TimePlugin-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/{TimePlugin.d.ts → controls/TimePlugin.d.ts} +4 -4
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/TimePlugin.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/TimePlugin.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/TimePlugin.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/TimePlugin.ts +76 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/VoiceInputPlugin-dbg.js +62 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/VoiceInputPlugin-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/VoiceInputPlugin.d.ts +11 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/VoiceInputPlugin.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/VoiceInputPlugin.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/VoiceInputPlugin.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/controls/VoiceInputPlugin.ts +59 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/datasources/LiveSearchPlugin-dbg.js +94 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/datasources/LiveSearchPlugin-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/datasources/LiveSearchPlugin.d.ts +29 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/datasources/LiveSearchPlugin.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/datasources/LiveSearchPlugin.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/datasources/LiveSearchPlugin.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/datasources/LiveSearchPlugin.ts +102 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/datasources/ODataListBindingPlugin-dbg.js +60 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/datasources/ODataListBindingPlugin-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/datasources/ODataListBindingPlugin.d.ts +22 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/datasources/ODataListBindingPlugin.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/datasources/ODataListBindingPlugin.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/datasources/ODataListBindingPlugin.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/datasources/ODataListBindingPlugin.ts +57 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/datasources/RemoteDropdownPlugin-dbg.js +106 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/datasources/RemoteDropdownPlugin-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/datasources/RemoteDropdownPlugin.d.ts +22 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/datasources/RemoteDropdownPlugin.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/datasources/RemoteDropdownPlugin.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/datasources/RemoteDropdownPlugin.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/datasources/RemoteDropdownPlugin.ts +101 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/datasources/RemoteValueHelpPlugin-dbg.js +77 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/datasources/RemoteValueHelpPlugin-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/datasources/RemoteValueHelpPlugin.d.ts +25 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/datasources/RemoteValueHelpPlugin.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/datasources/RemoteValueHelpPlugin.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/datasources/RemoteValueHelpPlugin.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/datasources/RemoteValueHelpPlugin.ts +86 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/formatters/CurrencyFormatterPlugin-dbg.js +36 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/formatters/CurrencyFormatterPlugin-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/formatters/CurrencyFormatterPlugin.d.ts +25 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/formatters/CurrencyFormatterPlugin.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/formatters/CurrencyFormatterPlugin.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/formatters/CurrencyFormatterPlugin.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/formatters/CurrencyFormatterPlugin.ts +36 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/formatters/DateFormatterPlugin-dbg.js +32 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/formatters/DateFormatterPlugin-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/formatters/DateFormatterPlugin.d.ts +19 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/formatters/DateFormatterPlugin.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/formatters/DateFormatterPlugin.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/formatters/DateFormatterPlugin.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/formatters/DateFormatterPlugin.ts +31 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/formatters/PhoneFormatterPlugin-dbg.js +32 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/formatters/PhoneFormatterPlugin-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/formatters/PhoneFormatterPlugin.d.ts +17 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/formatters/PhoneFormatterPlugin.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/formatters/PhoneFormatterPlugin.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/formatters/PhoneFormatterPlugin.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/formatters/PhoneFormatterPlugin.ts +27 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/formatters/TextCaseFormatterPlugin-dbg.js +31 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/formatters/TextCaseFormatterPlugin-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/formatters/TextCaseFormatterPlugin.d.ts +18 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/formatters/TextCaseFormatterPlugin.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/formatters/TextCaseFormatterPlugin.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/formatters/TextCaseFormatterPlugin.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/formatters/TextCaseFormatterPlugin.ts +23 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/validators/EmailValidatorPlugin-dbg.js +45 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/validators/EmailValidatorPlugin-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/validators/EmailValidatorPlugin.d.ts +24 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/validators/EmailValidatorPlugin.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/validators/EmailValidatorPlugin.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/validators/EmailValidatorPlugin.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/validators/EmailValidatorPlugin.ts +30 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/validators/IbanValidatorPlugin-dbg.js +42 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/validators/IbanValidatorPlugin-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/validators/IbanValidatorPlugin.d.ts +18 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/validators/IbanValidatorPlugin.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/validators/IbanValidatorPlugin.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/validators/IbanValidatorPlugin.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/validators/IbanValidatorPlugin.ts +29 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/validators/MinLengthValidatorPlugin-dbg.js +41 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/validators/MinLengthValidatorPlugin-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/validators/MinLengthValidatorPlugin.d.ts +17 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/validators/MinLengthValidatorPlugin.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/validators/MinLengthValidatorPlugin.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/validators/MinLengthValidatorPlugin.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/validators/MinLengthValidatorPlugin.ts +25 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/validators/PatternValidatorPlugin-dbg.js +51 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/validators/PatternValidatorPlugin-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/validators/PatternValidatorPlugin.d.ts +17 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/validators/PatternValidatorPlugin.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/validators/PatternValidatorPlugin.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/validators/PatternValidatorPlugin.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/validators/PatternValidatorPlugin.ts +33 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/validators/RangeValidatorPlugin-dbg.js +48 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/validators/RangeValidatorPlugin-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/validators/RangeValidatorPlugin.d.ts +17 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/validators/RangeValidatorPlugin.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/validators/RangeValidatorPlugin.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/validators/RangeValidatorPlugin.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/validators/RangeValidatorPlugin.ts +32 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/validators/UrlValidatorPlugin-dbg.js +46 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/validators/UrlValidatorPlugin-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/validators/UrlValidatorPlugin.d.ts +17 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/validators/UrlValidatorPlugin.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/validators/UrlValidatorPlugin.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/validators/UrlValidatorPlugin.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/plugins/validators/UrlValidatorPlugin.ts +29 -0
- package/src/nz/co/siliconst/ui5/metaui/utils/Logger-dbg.js +83 -0
- package/src/nz/co/siliconst/ui5/metaui/utils/Logger-dbg.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/utils/Logger.d.ts +29 -0
- package/src/nz/co/siliconst/ui5/metaui/utils/Logger.d.ts.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/utils/Logger.js +2 -0
- package/src/nz/co/siliconst/ui5/metaui/utils/Logger.js.map +1 -0
- package/src/nz/co/siliconst/ui5/metaui/utils/Logger.ts +75 -0
- package/src/nz/co/siliconst/ui5/metaui/controls/GeneratorHost-dbg.js +0 -300
- package/src/nz/co/siliconst/ui5/metaui/controls/GeneratorHost-dbg.js.map +0 -1
- package/src/nz/co/siliconst/ui5/metaui/controls/GeneratorHost.d.ts +0 -130
- package/src/nz/co/siliconst/ui5/metaui/controls/GeneratorHost.d.ts.map +0 -1
- package/src/nz/co/siliconst/ui5/metaui/controls/GeneratorHost.js +0 -2
- package/src/nz/co/siliconst/ui5/metaui/controls/GeneratorHost.js.map +0 -1
- package/src/nz/co/siliconst/ui5/metaui/controls/GeneratorHost.ts +0 -292
- package/src/nz/co/siliconst/ui5/metaui/core/EventBus-dbg.js +0 -66
- package/src/nz/co/siliconst/ui5/metaui/core/EventBus-dbg.js.map +0 -1
- package/src/nz/co/siliconst/ui5/metaui/core/EventBus.d.ts +0 -40
- package/src/nz/co/siliconst/ui5/metaui/core/EventBus.d.ts.map +0 -1
- package/src/nz/co/siliconst/ui5/metaui/core/EventBus.js +0 -2
- package/src/nz/co/siliconst/ui5/metaui/core/EventBus.js.map +0 -1
- package/src/nz/co/siliconst/ui5/metaui/core/EventBus.ts +0 -60
- package/src/nz/co/siliconst/ui5/metaui/interfaces/IEventBus-dbg.js +0 -2
- package/src/nz/co/siliconst/ui5/metaui/interfaces/IEventBus-dbg.js.map +0 -1
- package/src/nz/co/siliconst/ui5/metaui/interfaces/IEventBus.d.ts +0 -29
- package/src/nz/co/siliconst/ui5/metaui/interfaces/IEventBus.d.ts.map +0 -1
- package/src/nz/co/siliconst/ui5/metaui/interfaces/IEventBus.js +0 -2
- package/src/nz/co/siliconst/ui5/metaui/interfaces/IEventBus.js.map +0 -1
- package/src/nz/co/siliconst/ui5/metaui/interfaces/IEventBus.ts +0 -29
- package/src/nz/co/siliconst/ui5/metaui/layouts/BaseLayout-dbg.js +0 -24
- package/src/nz/co/siliconst/ui5/metaui/layouts/BaseLayout-dbg.js.map +0 -1
- package/src/nz/co/siliconst/ui5/metaui/layouts/BaseLayout.d.ts +0 -15
- package/src/nz/co/siliconst/ui5/metaui/layouts/BaseLayout.d.ts.map +0 -1
- package/src/nz/co/siliconst/ui5/metaui/layouts/BaseLayout.js +0 -2
- package/src/nz/co/siliconst/ui5/metaui/layouts/BaseLayout.js.map +0 -1
- package/src/nz/co/siliconst/ui5/metaui/layouts/BaseLayout.ts +0 -22
- package/src/nz/co/siliconst/ui5/metaui/plugins/ArrayPlugin-dbg.js +0 -68
- package/src/nz/co/siliconst/ui5/metaui/plugins/ArrayPlugin-dbg.js.map +0 -1
- package/src/nz/co/siliconst/ui5/metaui/plugins/ArrayPlugin.d.ts +0 -15
- package/src/nz/co/siliconst/ui5/metaui/plugins/ArrayPlugin.d.ts.map +0 -1
- package/src/nz/co/siliconst/ui5/metaui/plugins/ArrayPlugin.js +0 -2
- package/src/nz/co/siliconst/ui5/metaui/plugins/ArrayPlugin.js.map +0 -1
- package/src/nz/co/siliconst/ui5/metaui/plugins/ArrayPlugin.ts +0 -71
- package/src/nz/co/siliconst/ui5/metaui/plugins/BasePlugin-dbg.js +0 -55
- package/src/nz/co/siliconst/ui5/metaui/plugins/BasePlugin-dbg.js.map +0 -1
- package/src/nz/co/siliconst/ui5/metaui/plugins/BasePlugin.d.ts +0 -24
- package/src/nz/co/siliconst/ui5/metaui/plugins/BasePlugin.d.ts.map +0 -1
- package/src/nz/co/siliconst/ui5/metaui/plugins/BasePlugin.js +0 -2
- package/src/nz/co/siliconst/ui5/metaui/plugins/BasePlugin.js.map +0 -1
- package/src/nz/co/siliconst/ui5/metaui/plugins/BasePlugin.ts +0 -56
- package/src/nz/co/siliconst/ui5/metaui/plugins/BooleanPlugin-dbg.js +0 -42
- package/src/nz/co/siliconst/ui5/metaui/plugins/BooleanPlugin-dbg.js.map +0 -1
- package/src/nz/co/siliconst/ui5/metaui/plugins/BooleanPlugin.d.ts +0 -18
- package/src/nz/co/siliconst/ui5/metaui/plugins/BooleanPlugin.d.ts.map +0 -1
- package/src/nz/co/siliconst/ui5/metaui/plugins/BooleanPlugin.js +0 -2
- package/src/nz/co/siliconst/ui5/metaui/plugins/BooleanPlugin.js.map +0 -1
- package/src/nz/co/siliconst/ui5/metaui/plugins/BooleanPlugin.ts +0 -41
- package/src/nz/co/siliconst/ui5/metaui/plugins/DatePlugin-dbg.js.map +0 -1
- package/src/nz/co/siliconst/ui5/metaui/plugins/DatePlugin.d.ts.map +0 -1
- package/src/nz/co/siliconst/ui5/metaui/plugins/DatePlugin.js +0 -2
- package/src/nz/co/siliconst/ui5/metaui/plugins/DatePlugin.js.map +0 -1
- package/src/nz/co/siliconst/ui5/metaui/plugins/DatePlugin.ts +0 -69
- package/src/nz/co/siliconst/ui5/metaui/plugins/DateTimePlugin-dbg.js.map +0 -1
- package/src/nz/co/siliconst/ui5/metaui/plugins/DateTimePlugin.d.ts.map +0 -1
- package/src/nz/co/siliconst/ui5/metaui/plugins/DateTimePlugin.js +0 -2
- package/src/nz/co/siliconst/ui5/metaui/plugins/DateTimePlugin.js.map +0 -1
- package/src/nz/co/siliconst/ui5/metaui/plugins/DateTimePlugin.ts +0 -68
- package/src/nz/co/siliconst/ui5/metaui/plugins/DropdownPlugin-dbg.js +0 -67
- package/src/nz/co/siliconst/ui5/metaui/plugins/DropdownPlugin-dbg.js.map +0 -1
- package/src/nz/co/siliconst/ui5/metaui/plugins/DropdownPlugin.d.ts +0 -18
- package/src/nz/co/siliconst/ui5/metaui/plugins/DropdownPlugin.d.ts.map +0 -1
- package/src/nz/co/siliconst/ui5/metaui/plugins/DropdownPlugin.js +0 -2
- package/src/nz/co/siliconst/ui5/metaui/plugins/DropdownPlugin.js.map +0 -1
- package/src/nz/co/siliconst/ui5/metaui/plugins/DropdownPlugin.ts +0 -65
- package/src/nz/co/siliconst/ui5/metaui/plugins/NumberPlugin-dbg.js.map +0 -1
- package/src/nz/co/siliconst/ui5/metaui/plugins/NumberPlugin.d.ts.map +0 -1
- package/src/nz/co/siliconst/ui5/metaui/plugins/NumberPlugin.js +0 -2
- package/src/nz/co/siliconst/ui5/metaui/plugins/NumberPlugin.js.map +0 -1
- package/src/nz/co/siliconst/ui5/metaui/plugins/NumberPlugin.ts +0 -56
- package/src/nz/co/siliconst/ui5/metaui/plugins/StringPlugin-dbg.js +0 -57
- package/src/nz/co/siliconst/ui5/metaui/plugins/StringPlugin-dbg.js.map +0 -1
- package/src/nz/co/siliconst/ui5/metaui/plugins/StringPlugin.d.ts +0 -18
- package/src/nz/co/siliconst/ui5/metaui/plugins/StringPlugin.d.ts.map +0 -1
- package/src/nz/co/siliconst/ui5/metaui/plugins/StringPlugin.js +0 -2
- package/src/nz/co/siliconst/ui5/metaui/plugins/StringPlugin.js.map +0 -1
- package/src/nz/co/siliconst/ui5/metaui/plugins/StringPlugin.ts +0 -58
- package/src/nz/co/siliconst/ui5/metaui/plugins/SwitchPlugin-dbg.js.map +0 -1
- package/src/nz/co/siliconst/ui5/metaui/plugins/SwitchPlugin.d.ts.map +0 -1
- package/src/nz/co/siliconst/ui5/metaui/plugins/SwitchPlugin.js +0 -2
- package/src/nz/co/siliconst/ui5/metaui/plugins/SwitchPlugin.js.map +0 -1
- package/src/nz/co/siliconst/ui5/metaui/plugins/SwitchPlugin.ts +0 -42
- package/src/nz/co/siliconst/ui5/metaui/plugins/TextAreaPlugin-dbg.js.map +0 -1
- package/src/nz/co/siliconst/ui5/metaui/plugins/TextAreaPlugin.d.ts.map +0 -1
- package/src/nz/co/siliconst/ui5/metaui/plugins/TextAreaPlugin.js +0 -2
- package/src/nz/co/siliconst/ui5/metaui/plugins/TextAreaPlugin.js.map +0 -1
- package/src/nz/co/siliconst/ui5/metaui/plugins/TextAreaPlugin.ts +0 -58
- package/src/nz/co/siliconst/ui5/metaui/plugins/TimePlugin-dbg.js.map +0 -1
- package/src/nz/co/siliconst/ui5/metaui/plugins/TimePlugin.d.ts.map +0 -1
- package/src/nz/co/siliconst/ui5/metaui/plugins/TimePlugin.js +0 -2
- package/src/nz/co/siliconst/ui5/metaui/plugins/TimePlugin.js.map +0 -1
- package/src/nz/co/siliconst/ui5/metaui/plugins/TimePlugin.ts +0 -71
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"library-preload.js","sections":[{"offset":{"line":1,"column":0},"map":{"version":3,"names":["SchemaNormalizer","___core_SchemaNormalizer","Engine","___core_Engine","StateManager","___core_StateManager","BaseLayout","___layouts_BaseLayout","GeneratorHost","Control","extend","constructor","prototype","apply","this","arguments","stateManager","generatedContent","engine","renderer","apiVersion","render","rm","control","openStart","style","openEnd","content","getAggregation","renderControl","close","metadata","properties","schemaDefinition","type","defaultValue","initialData","initialDataJson","outputData","outputDataJson","useMessageManager","aggregations","_content","multiple","visibility","events","beforeSubmit","parameters","payload","addError","preventDefault","submit","payloadJson","cancel","init","_init","Control.prototype.init.call","exit","_exit","destroy","getModel","onBeforeRendering","_onBeforeRendering","getProperty","generate","triggerSubmit","_triggerSubmit","isPrevented","messageManager","sap","ui","getCore","getMessageManager","removeAllMessages","pushMessage","path","text","require","Message","addMessages","message","target","getId","processor","validateAll","extractPayload","JSON","stringify","fireEvent","propertyPath","errorMessage","Log","warning","setProperty","_generate","rawSchema","parse","e","error","normalizedSchema","normalize","modelName","setModel","layoutFactory","build","setAggregation","errorPage","MessagePage","description","icon","openInDialog","_openInDialog","title","submitButtonText","dialog","Dialog","contentWidth","beginButton","Button","press","success","endButton","afterClose","open"],"sources":["GeneratorHost.ts"],"sourcesContent":["/**\n * @file GeneratorHost.ts\n * @description The core UI5 custom control that exposes the MetaUI engine to host applications.\n */\n\nimport Control from \"sap/ui/core/Control\";\nimport RenderManager from \"sap/ui/core/RenderManager\";\nimport Dialog from \"sap/m/Dialog\";\nimport Button from \"sap/m/Button\";\nimport MessagePage from \"sap/m/MessagePage\";\nimport Log from \"sap/base/Log\";\nimport { SchemaNormalizer } from \"../core/SchemaNormalizer\";\nimport { Engine } from \"../core/Engine\";\nimport { StateManager } from \"../core/StateManager\";\nimport { BaseLayout } from \"../layouts/BaseLayout\";\n\n/**\n * Wrapper element for embedding or popping the dynamic form.\n * \n * @namespace nz.co.siliconst.ui5.metaui.controls\n */\nexport default class GeneratorHost extends Control {\n \n private stateManager: StateManager | null = null;\n private generatedContent: Control | null = null;\n private engine: Engine | null = null;\n\n static readonly metadata = {\n properties: {\n /** The raw JSON metadata schema provided by the ABAP backend. */\n schemaDefinition: { type: \"any\", defaultValue: null },\n /** The initial data payload to populate the fields as an object. */\n initialData: { type: \"any\", defaultValue: null },\n /** The initial data payload provided as a raw JSON string. */\n initialDataJson: { type: \"string\", defaultValue: null },\n /** The final payload data object, updated on submit. */\n outputData: { type: \"object\", defaultValue: null },\n /** The final payload JSON string, updated on submit. */\n outputDataJson: { type: \"string\", defaultValue: null },\n /** If true, validation errors will be pushed to the global sap.ui.core.message.MessageManager. */\n useMessageManager: { type: \"boolean\", defaultValue: false }\n },\n aggregations: {\n /** The internal hidden container holding the generated layouts. */\n _content: { type: \"sap.ui.core.Control\", multiple: false, visibility: \"hidden\" }\n },\n events: {\n /** Triggered before final submission, allowing host apps to run custom validation logic and halt submission if needed. */\n beforeSubmit: {\n parameters: {\n /** The clean extracted JSON payload representing the current state. */\n payload: { type: \"object\" },\n /** Function to add a custom validation error message for a specific field path. */\n addError: { type: \"function\" },\n /** Function to prevent the default submission and dialog closure. */\n preventDefault: { type: \"function\" }\n }\n },\n /** Triggered when the user submits the form via the Dialog modality. */\n submit: {\n parameters: {\n /** The clean extracted JSON payload representing the current state. */\n payload: { type: \"object\" },\n /** The stringified final JSON payload. */\n payloadJson: { type: \"string\" }\n }\n },\n /** Triggered if the dialog is cancelled. */\n cancel: {}\n }\n };\n\n /**\n * Standard UI5 control renderer. Renders the generated internal content.\n */\n static renderer = {\n apiVersion: 2,\n render(rm: RenderManager, control: GeneratorHost) {\n rm.openStart(\"div\", control);\n rm.style(\"width\", \"100%\");\n rm.style(\"height\", \"100%\");\n rm.openEnd();\n \n const content = control.getAggregation(\"_content\") as Control;\n if (content) {\n rm.renderControl(content);\n }\n \n rm.close(\"div\");\n }\n };\n\n /**\n * Initializes the UI5 control.\n */\n public init(): void {\n super.init();\n }\n\n /**\n * Standard UI5 lifecycle hook for destruction.\n * Guaranteed to tear down isolated models and unbind global event listeners.\n */\n public exit(): void {\n if (this.engine) {\n this.engine.destroy();\n this.engine = null;\n }\n\n if (this.stateManager) {\n this.stateManager.getModel().destroy();\n this.stateManager = null;\n }\n\n if (this.generatedContent) {\n this.generatedContent.destroy();\n this.generatedContent = null;\n }\n }\n\n /**\n * Lifecycle hook to automatically generate the layout if bound declaratively in XML.\n */\n public onBeforeRendering(): void {\n if (!this.generatedContent && this.getProperty(\"schemaDefinition\")) {\n this.generate();\n }\n }\n\n /**\n * Extracts the payload, pushes it to properties, and fires the submit event manually.\n * Returns true if submission was successful, false if validation failed or was prevented.\n */\n public triggerSubmit(): boolean {\n if (this.stateManager && this.engine) {\n let isPrevented = false;\n const useMessageManager = this.getProperty(\"useMessageManager\") as boolean;\n let messageManager: any = null;\n \n if (useMessageManager) {\n messageManager = sap.ui.getCore().getMessageManager();\n messageManager.removeAllMessages();\n }\n\n // Helper to add messages securely via async require so it isn't a hard dependency\n const pushMessage = (path: string, text: string) => {\n if (useMessageManager && messageManager) {\n sap.ui.require([\"sap/ui/core/message/Message\"], (Message: any) => {\n messageManager.addMessages(new Message({\n message: text,\n type: \"Error\" as any,\n target: `${this.stateManager?.getModel().getId()}>/${path}`,\n processor: this.stateManager?.getModel()\n }));\n });\n }\n };\n\n // 1. Run global schema validation\n if (!this.engine.validateAll()) {\n pushMessage(\"\", \"One or more fields failed schema validation. Please review the highlighted fields.\");\n return false; // Schema validation failed, inputs already turned red\n }\n\n const payload = this.stateManager.extractPayload();\n const payloadJson = JSON.stringify(payload);\n \n // 2. Fire beforeSubmit exit\n this.fireEvent(\"beforeSubmit\", {\n payload,\n preventDefault: () => {\n isPrevented = true;\n },\n addError: (propertyPath: string, errorMessage: string) => {\n isPrevented = true;\n if (useMessageManager && messageManager) {\n pushMessage(propertyPath, errorMessage);\n } else {\n Log.warning(`[MetaUI] Validation Error for ${propertyPath}: ${errorMessage}`, \"GeneratorHost\");\n }\n }\n });\n\n if (isPrevented) {\n return false; // Exit validation failed or prevented submission\n }\n \n // Push final values to properties (updating XML bindings)\n this.setProperty(\"outputData\", payload, true);\n this.setProperty(\"outputDataJson\", payloadJson, true);\n \n this.fireEvent(\"submit\", { payload, payloadJson });\n return true;\n }\n return false;\n }\n\n /**\n * Triggers the engine to parse the schema and build the layout.\n * Safely wrapped in a try/catch to prevent Launchpad crashes.\n */\n public generate(): void {\n try {\n const rawSchema = this.getProperty(\"schemaDefinition\");\n \n let initialData = this.getProperty(\"initialData\");\n const initialDataJson = this.getProperty(\"initialDataJson\");\n \n if (initialDataJson) {\n try {\n initialData = JSON.parse(initialDataJson);\n } catch (e) {\n Log.error(\"[MetaUI] Failed to parse initialDataJson string.\", (e as Error).message, \"GeneratorHost\");\n }\n } else if (typeof initialData === \"string\") {\n try {\n initialData = JSON.parse(initialData);\n } catch (e) {\n Log.error(\"[MetaUI] Failed to parse initialData string.\", (e as Error).message, \"GeneratorHost\");\n }\n }\n\n // 1. Normalize schema (allows fallback to data inference)\n const normalizedSchema = SchemaNormalizer.normalize(rawSchema, initialData);\n\n // 2. Bootstrap isolated State Manager\n this.stateManager = new StateManager(initialData || {});\n \n // Dynamically generate a 100% unique model name for isolation\n const modelName = \"metaUI_\" + this.getId();\n this.setModel(this.stateManager.getModel(), modelName);\n\n // 3. Delegate to Layout Engine\n this.engine = new Engine();\n const layoutFactory = new BaseLayout();\n \n this.generatedContent = this.engine.build(normalizedSchema, layoutFactory, modelName);\n\n // 4. Mount into hidden aggregation\n this.setAggregation(\"_content\", this.generatedContent);\n\n } catch (error) {\n Log.error(\"[MetaUI] Engine failed to generate layout. Preventing Launchpad crash.\", (error as Error).message, \"GeneratorHost\");\n \n const errorPage = new MessagePage({\n text: \"UI Generation Failed\",\n description: \"The dynamic schema could not be rendered. Please check the Fiori console for diagnostic logs.\",\n icon: \"sap-icon://error\"\n });\n\n this.setAggregation(\"_content\", errorPage);\n }\n }\n\n /**\n * Dialog Modality: Opens the generated layout inside a sap.m.Dialog.\n * Automatically wires up 'Save' and 'Cancel' buttons.\n */\n public openInDialog(title: string = \"Dynamic Form\", submitButtonText: string = \"Save\"): void {\n if (!this.generatedContent) {\n this.generate();\n }\n\n const dialog = new Dialog({\n title: title,\n contentWidth: \"800px\",\n content: [this], // Mount self inside the dialog\n beginButton: new Button({\n text: submitButtonText,\n type: \"Emphasized\",\n press: () => {\n const success = this.triggerSubmit();\n if (success) {\n dialog.close();\n }\n }\n }),\n endButton: new Button({\n text: \"Cancel\",\n press: () => {\n this.fireEvent(\"cancel\");\n dialog.close();\n }\n }),\n afterClose: () => {\n dialog.destroy();\n }\n });\n\n dialog.open();\n }\n}\n"],"mappings":"AAAA,ySAWSA,EAAgBC,EAAA,0BAChBC,EAAMC,EAAA,gBACNC,EAAYC,EAAA,sBACZC,EAAUC,EAAA,cAEnB,MAKqBC,EAAsBC,EAAOC,OAAA,qDAAAC,YAAA,SAAAA,IAAAF,EAAAG,UAAAD,YAAAE,MAAAC,KAAAC,WAAAD,KAEtCE,aAAoC,KAAIF,KACxCG,iBAAmC,KAAIH,KACvCI,OAAwB,IAAI,EAkD7BC,SAAW,CACdC,WAAY,EACZC,OAAOC,EAAmBC,GACtBD,EAAGE,UAAU,MAAOD,GACpBD,EAAGG,MAAM,QAAS,QAClBH,EAAGG,MAAM,SAAU,QACnBH,EAAGI,UAEH,MAAMC,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B,SAAU,CACxC,IACIA,EAAckD,KAAKU,MAAM5D,EAC7B,CAAE,MAAO6D,GACLN,EAAIO,MAAM,+CAAiDD,EAAYjB,QAAS,gBACpF,CACJ,CAGA,MAAMmB,EAAmBnG,EAAiBoG,UAAUL,EAAW3D,GAG/DtB,KAAKE,aAAe,IAAIZ,EAAagC,GAAe,CAAC,GAGrD,MAAMiE,EAAY,UAAYvF,KAAKoE,QACnCpE,KAAKwF,SAASxF,KAAKE,aAAa4C,WAAYyC,GAG5CvF,KAAKI,OAAS,IAAIhB,EAClB,MAAMqG,EAAgB,IAAIjG,EAE1BQ,KAAKG,iBAAmBH,KAAKI,OAAOsF,MAAML,EAAkBI,EAAeF,GAG3EvF,KAAK2F,eAAe,WAAY3F,KAAKG,iBAEzC,CAAE,MAAOiF,GACLP,EAAIO,MAAM,yEAA2EA,EAAgBlB,QAAS,iBAE9G,MAAM0B,EAAY,IAAIC,EAAY,CAC9B/B,KAAM,uBACNgC,YAAa,gGACbC,KAAM,qBAGV/F,KAAK2F,eAAe,WAAYC,EACpC,CACJ,EAMOI,aAAY,SAAAC,EAACC,EAAgB,eAAgBC,EAA2B,QAC3E,IAAKnG,KAAKG,iBAAkB,CACxBH,KAAKkD,UACT,CAEA,MAAMkD,EAAS,IAAIC,EAAO,CACtBH,MAAOA,EACPI,aAAc,QACdzF,QAAS,CAACb,MACVuG,YAAa,IAAIC,EAAO,CACpB1C,KAAMqC,EACN/E,KAAM,aACNqF,MAAOA,KACH,MAAMC,EAAU1G,KAAKmD,gBACrB,GAAIuD,EAAS,CACTN,EAAOpF,OACX,KAGR2F,UAAW,IAAIH,EAAO,CAClB1C,KAAM,SACN2C,MAAOA,KACHzG,KAAK0E,UAAU,UACf0B,EAAOpF,WAGf4F,WAAYA,KACRR,EAAOvD,aAIfuD,EAAOS,MACX,IAAC,OA7QgBnH,CAAa","ignoreList":[],"sourceRoot":"controls"}},{"offset":{"line":2,"column":0},"map":{"version":3,"names":["EventBus","___EventBus","ConditionEngine","constructor","schema","this","boundHandler","handleEvent","bind","initializeListeners","getInstance","subscribe","event","destroy","unsubscribe","__exports","__esModule"],"sources":["ConditionEngine.ts"],"sourcesContent":["/**\n * @file ConditionEngine.ts\n * @description Evaluates dynamic rules to alter the schema in real-time.\n */\n\nimport { EventBus } from \"./EventBus\";\nimport { ISchema } from \"../interfaces/ISchema\";\nimport { IFieldChangeEvent } from \"../interfaces/IEventBus\";\n\n/**\n * Engine that listens to the EventBus and evaluates cross-field dependencies.\n */\nexport class ConditionEngine {\n private schema: ISchema;\n private boundHandler: (event: IFieldChangeEvent) => void;\n\n /**\n * Initializes the ConditionEngine with the active schema.\n * @param schema The current UI layout schema.\n */\n constructor(schema: ISchema) {\n this.schema = schema;\n this.boundHandler = this.handleEvent.bind(this);\n this.initializeListeners();\n }\n\n /**\n * Subscribes to the EventBus for real-time field change interception.\n */\n private initializeListeners(): void {\n EventBus.getInstance().subscribe(this.boundHandler);\n }\n\n /**\n * Internal handler to evaluate business rules when a field is updated.\n * @param event The structured change event.\n */\n private handleEvent(event: IFieldChangeEvent): void {\n // Architecture hook: Logic to evaluate conditions against the schema \n // and update plugin properties will be injected here in later phases.\n }\n\n /**\n * Cleans up EventBus listeners to prevent memory leaks on destruction.\n */\n public destroy(): void {\n EventBus.getInstance().unsubscribe(this.boundHandler);\n }\n}\n"],"mappings":"AAAA,4GAAA,MAKSA,EAAQC,EAAA,YAOV,MAAMC,EAQTC,YAAYC,GACRC,KAAKD,OAASA,EACdC,KAAKC,aAAeD,KAAKE,YAAYC,KAAKH,MAC1CA,KAAKI,qBACT,CAKQA,sBACJT,EAASU,cAAcC,UAAUN,KAAKC,aAC1C,CAMQC,YAAYK,GAEhB,CAMGC,UACHb,EAASU,cAAcI,YAAYT,KAAKC,aAC5C,EACH,IAAAS,EAAA,CAAAC,WAAA,MAAAD,EAAAb,kBAAA,OAAAa,CAAA","ignoreList":[],"sourceRoot":"core"}},{"offset":{"line":3,"column":0},"map":{"version":3,"names":["ConditionEngine","___ConditionEngine","Engine","conditionEngine","activePlugins","build","schema","layoutManager","modelName","this","trackPlugin","plugin","push","type","items","Error","renderTable","title","container","VBox","renderType","props","properties","formProps","tableProps","key","Object","keys","meta","length","addItem","renderForm","tableProp","ui","label","validateAll","isValid","validate","destroy","__exports","__esModule"],"sources":["Engine.ts"],"sourcesContent":["/**\n * @file Engine.ts\n * @description The central orchestrator that routes data between the Layout Factory and Plugin Registry (v2).\n */\n\nimport { ISchema, IPropertyMetadata } from \"../interfaces/ISchema\";\nimport { ILayoutManager } from \"../interfaces/ILayoutManager\";\nimport { IPlugin } from \"../interfaces/IPlugin\";\nimport { ConditionEngine } from \"./ConditionEngine\";\nimport Control from \"sap/ui/core/Control\";\nimport VBox from \"sap/m/VBox\";\n\nexport class Engine {\n private conditionEngine: ConditionEngine | null = null;\n private activePlugins: IPlugin[] = [];\n \n public build(schema: ISchema, layoutManager: ILayoutManager, modelName: string = \"meta\"): Control {\n this.conditionEngine = new ConditionEngine(schema);\n this.activePlugins = [];\n\n const trackPlugin = (plugin: IPlugin) => this.activePlugins.push(plugin);\n \n // Implicit layout routing based on root type\n if (schema.type === \"array\") {\n if (!schema.items) {\n throw new Error(\"[MetaUI] Array schema must define 'items'.\");\n }\n return layoutManager.renderTable(schema.items, `${modelName}>/`, schema.title);\n }\n \n if (schema.type === \"object\") {\n const container = new VBox({ renderType: \"Bare\" });\n const props = schema.properties || {};\n \n // Separate scalar properties (form fields) from root array properties (inline tables)\n const formProps: Record<string, IPropertyMetadata> = {};\n const tableProps: { key: string; meta: IPropertyMetadata }[] = [];\n \n for (const key of Object.keys(props)) {\n if (props[key].type === \"array\") {\n tableProps.push({ key, meta: props[key] });\n } else {\n formProps[key] = props[key];\n }\n }\n \n // Render the top-level form if there are scalar fields\n if (Object.keys(formProps).length > 0) {\n container.addItem(layoutManager.renderForm(formProps, modelName, schema.title, trackPlugin));\n }\n \n // Render root-level arrays as massive native tables below the form\n for (const tableProp of tableProps) {\n if (tableProp.meta.items) {\n container.addItem(layoutManager.renderTable(tableProp.meta.items, `${modelName}>/${tableProp.key}`, tableProp.meta.ui?.label || tableProp.key));\n }\n }\n \n return container;\n }\n \n throw new Error(`[MetaUI] Unsupported schema type: ${schema.type}`);\n }\n\n public validateAll(): boolean {\n let isValid = true;\n for (const plugin of this.activePlugins) {\n if (!plugin.validate()) {\n isValid = false;\n }\n }\n return isValid;\n }\n\n public destroy(): void {\n if (this.conditionEngine) {\n this.conditionEngine.destroy();\n this.conditionEngine = null;\n }\n this.activePlugins = [];\n }\n}\n"],"mappings":"AAAA,yHAAA,MAQSA,EAAeC,EAAA,mBAIjB,MAAMC,EACDC,gBAA0C,KAC1CC,cAA2B,GAE5BC,MAAMC,EAAiBC,EAA+BC,EAAoB,QAC7EC,KAAKN,gBAAkB,IAAIH,EAAgBM,GAC3CG,KAAKL,cAAgB,GAErB,MAAMM,EAAeC,GAAoBF,KAAKL,cAAcQ,KAAKD,GAGjE,GAAIL,EAAOO,OAAS,QAAS,CACzB,IAAKP,EAAOQ,MAAO,CACf,MAAM,IAAIC,MAAM,6CACpB,CACA,OAAOR,EAAcS,YAAYV,EAAOQ,MAAO,GAAGN,MAAeF,EAAOW,MAC5E,CAEA,GAAIX,EAAOO,OAAS,SAAU,CAC1B,MAAMK,EAAY,IAAIC,EAAK,CAAEC,WAAY,SACzC,MAAMC,EAAQf,EAAOgB,YAAc,CAAC,EAGpC,MAAMC,EAA+C,CAAC,EACtD,MAAMC,EAAyD,GAE/D,IAAK,MAAMC,KAAOC,OAAOC,KAAKN,GAAQ,CAClC,GAAIA,EAAMI,GAAKZ,OAAS,QAAS,CAC7BW,EAAWZ,KAAK,CAAEa,MAAKG,KAAMP,EAAMI,IACvC,KAAO,CACHF,EAAUE,GAAOJ,EAAMI,EAC3B,CACJ,CAGA,GAAIC,OAAOC,KAAKJ,GAAWM,OAAS,EAAG,CACnCX,EAAUY,QAAQvB,EAAcwB,WAAWR,EAAWf,EAAWF,EAAOW,MAAOP,GACnF,CAGA,IAAK,MAAMsB,KAAaR,EAAY,CAChC,GAAIQ,EAAUJ,KAAKd,MAAO,CACtBI,EAAUY,QAAQvB,EAAcS,YAAYgB,EAAUJ,KAAKd,MAAO,GAAGN,MAAcwB,EAAUP,MAAOO,EAAUJ,KAAKK,IAAIC,OAASF,EAAUP,KAC9I,CACJ,CAEA,OAAOP,CACX,CAEA,MAAM,IAAIH,MAAM,qCAAqCT,EAAOO,OAChE,CAEOsB,cACH,IAAIC,EAAU,KACd,IAAK,MAAMzB,KAAUF,KAAKL,cAAe,CACrC,IAAKO,EAAO0B,WAAY,CACpBD,EAAU,KACd,CACJ,CACA,OAAOA,CACX,CAEOE,UACH,GAAI7B,KAAKN,gBAAiB,CACtBM,KAAKN,gBAAgBmC,UACrB7B,KAAKN,gBAAkB,IAC3B,CACAM,KAAKL,cAAgB,EACzB,EACH,IAAAmC,EAAA,CAAAC,WAAA,MAAAD,EAAArC,SAAA,OAAAqC,CAAA","ignoreList":[],"sourceRoot":"core"}},{"offset":{"line":4,"column":0},"map":{"version":3,"names":["EventBus","listeners","constructor","getInstance","instance","publishFieldChange","event","this","forEach","listener","subscribe","push","unsubscribe","filter","l","unsubscribeAll","__exports","__esModule"],"sources":["EventBus.ts"],"sourcesContent":["/**\n * @file EventBus.ts\n * @description Internal pub/sub channel for managing cross-field dependencies.\n */\n\nimport { IEventBus, IFieldChangeEvent } from \"../interfaces/IEventBus\";\n\n/**\n * Singleton orchestrator for localized state changes across the generated UI layout.\n */\nexport class EventBus implements IEventBus {\n private static instance: EventBus;\n private listeners: Array<(event: IFieldChangeEvent) => void> = [];\n\n private constructor() {\n // Enforce singleton\n }\n\n /**\n * Retrieves the singular instance of the EventBus.\n * @returns The EventBus singleton.\n */\n public static getInstance(): EventBus {\n if (!EventBus.instance) {\n EventBus.instance = new EventBus();\n }\n return EventBus.instance;\n }\n\n /**\n * Publishes a value change event to all internal subscribers.\n * @param event The structured payload of the field change.\n */\n public publishFieldChange(event: IFieldChangeEvent): void {\n this.listeners.forEach(listener => listener(event));\n }\n\n /**\n * Registers a callback listener to react to field changes.\n * @param listener The callback function.\n */\n public subscribe(listener: (event: IFieldChangeEvent) => void): void {\n this.listeners.push(listener);\n }\n\n /**\n * Unregisters a callback listener to prevent memory leaks.\n * @param listener The callback function to remove.\n */\n public unsubscribe(listener: (event: IFieldChangeEvent) => void): void {\n this.listeners = this.listeners.filter(l => l !== listener);\n }\n\n /**\n * Unregisters all callback listeners.\n */\n public unsubscribeAll(): void {\n this.listeners = [];\n }\n}\n"],"mappings":"AAAA,wFAUO,MAAMA,EAEDC,UAAuD,GAEvDC,cACJ,CAOJ,kBAAcC,GACV,IAAKH,EAASI,SAAU,CACpBJ,EAASI,SAAW,IAAIJ,CAC5B,CACA,OAAOA,EAASI,QACpB,CAMOC,mBAAmBC,GACtBC,KAAKN,UAAUO,QAAQC,GAAYA,EAASH,GAChD,CAMOI,UAAUD,GACbF,KAAKN,UAAUU,KAAKF,EACxB,CAMOG,YAAYH,GACfF,KAAKN,UAAYM,KAAKN,UAAUY,OAAOC,GAAKA,IAAML,EACtD,CAKOM,iBACHR,KAAKN,UAAY,EACrB,EACH,IAAAe,EAAA,CAAAC,WAAA,MAAAD,EAAAhB,WAAA,OAAAgB,CAAA","ignoreList":[],"sourceRoot":"core"}},{"offset":{"line":5,"column":0},"map":{"version":3,"names":["PluginRegistry","plugins","Map","constructor","getInstance","instance","register","type","pluginConstructor","widgetName","key","this","set","getPlugin","PluginClass","get","Error","__exports","__esModule"],"sources":["PluginRegistry.ts"],"sourcesContent":["/**\n * @file PluginRegistry.ts\n * @description Centralized hub for mapping UI5 controls to SAP schema data types.\n * Enforces the Registry Pattern to decouple the core engine from specific UI5 control implementations.\n */\n\nimport { IPlugin } from \"../interfaces/IPlugin\";\nimport { FieldType } from \"../interfaces/ISchema\";\n\n/**\n * Singleton registry that manages the lifecycle and lookup of UI5 plugin constructors.\n */\nexport class PluginRegistry {\n private static instance: PluginRegistry;\n \n /** Internal map linking string types to their respective constructor functions. */\n private plugins: Map<string, new () => IPlugin> = new Map();\n\n private constructor() {\n // Enforce singleton\n }\n\n /**\n * Retrieves the singular instance of the PluginRegistry.\n * @returns The PluginRegistry singleton.\n */\n public static getInstance(): PluginRegistry {\n if (!PluginRegistry.instance) {\n PluginRegistry.instance = new PluginRegistry();\n }\n return PluginRegistry.instance;\n }\n\n /**\n * Registers a new UI control plugin against a specific schema primitive type (and optional widget).\n * @param type The primitive FieldType (e.g., 'string', 'date').\n * @param pluginConstructor The class constructor for the plugin.\n * @param widgetName Optional widget specific override (e.g., 'textArea').\n */\n public register(type: FieldType, pluginConstructor: new () => IPlugin, widgetName?: string): void {\n const key = widgetName ? `${type}:${widgetName}` : type;\n this.plugins.set(key, pluginConstructor);\n }\n\n /**\n * Instantiates and returns a new plugin based on the requested primitive type and widget.\n * @param type The primitive FieldType to look up.\n * @param widgetName Optional widget specific override.\n * @throws Error if no plugin has been registered for the provided type.\n * @returns A newly instantiated plugin ready for rendering.\n */\n public getPlugin(type: FieldType, widgetName?: string): IPlugin {\n let PluginClass;\n \n // 1. Attempt specific widget lookup\n if (widgetName) {\n PluginClass = this.plugins.get(`${type}:${widgetName}`);\n }\n \n // 2. Fallback to primitive type\n if (!PluginClass) {\n PluginClass = this.plugins.get(type);\n }\n\n if (!PluginClass) {\n throw new Error(`[MetaUI] No plugin registered for FieldType: ${type}`);\n }\n \n return new PluginClass();\n }\n}\n"],"mappings":"AAAA,8FAYO,MAAMA,EAIDC,QAA0C,IAAIC,IAE9CC,cACJ,CAOJ,kBAAcC,GACV,IAAKJ,EAAeK,SAAU,CAC1BL,EAAeK,SAAW,IAAIL,CAClC,CACA,OAAOA,EAAeK,QAC1B,CAQOC,SAASC,EAAiBC,EAAsCC,GACnE,MAAMC,EAAMD,EAAa,GAAGF,KAAQE,IAAeF,EACnDI,KAAKV,QAAQW,IAAIF,EAAKF,EAC1B,CASOK,UAAUN,EAAiBE,GAC9B,IAAIK,EAGJ,GAAIL,EAAY,CACZK,EAAcH,KAAKV,QAAQc,IAAI,GAAGR,KAAQE,IAC9C,CAGA,IAAKK,EAAa,CACdA,EAAcH,KAAKV,QAAQc,IAAIR,EACnC,CAEA,IAAKO,EAAa,CACd,MAAM,IAAIE,MAAM,gDAAgDT,IACpE,CAEA,OAAO,IAAIO,CACf,EACH,IAAAG,EAAA,CAAAC,WAAA,MAAAD,EAAAjB,iBAAA,OAAAiB,CAAA","ignoreList":[],"sourceRoot":"core"}},{"offset":{"line":6,"column":0},"map":{"version":3,"names":["SchemaNormalizer","normalize","rawSchema","data","schemaObj","JSON","parse","e","console","warn","Array","isArray","this","inferSchemaFromData","normalized","title","type","items","properties","normalizeProperties","normalizePropertyMetadata","normalizedProps","key","Object","keys","prop","keyName","ui","label","generateLabel","isKey","readOnly","widget","group","visibleOn","enabledOn","format","required","maxLength","minimum","maximum","pattern","precision","scale","valueHelp","name","spaced","replace","split","filter","w","length","map","word","charAt","toUpperCase","slice","toLowerCase","join","trim","schema","inferPropertiesFromObject","obj","val","undefined","__exports","__esModule"],"sources":["SchemaNormalizer.ts"],"sourcesContent":["/**\n * @file SchemaNormalizer.ts\n * @description Transforms and validates incoming JSON payloads into the strict v2 ISchema dictionary matrix.\n */\n\nimport { ISchema, IPropertyMetadata, FieldType } from \"../interfaces/ISchema\";\n\nexport class SchemaNormalizer {\n \n /**\n * Validates that the provided raw payload conforms to the required ISchema structures.\n */\n public static normalize(rawSchema?: any, data?: any): ISchema {\n let schemaObj = rawSchema;\n\n if (typeof schemaObj === \"string\") {\n try {\n schemaObj = JSON.parse(schemaObj);\n } catch (e) {\n console.warn(\"[MetaUI] Failed to parse schema string, falling back to inference.\", e);\n schemaObj = null;\n }\n }\n\n if (!schemaObj || typeof schemaObj !== 'object' || Array.isArray(schemaObj)) {\n return this.inferSchemaFromData(data);\n }\n\n // It is an object. Ensure it conforms to v2 structure.\n const normalized: ISchema = {\n title: schemaObj.title || \"MetaUI Generated Form\",\n type: schemaObj.type || (schemaObj.items ? \"array\" : \"object\"),\n };\n\n if (normalized.type === \"object\") {\n normalized.properties = this.normalizeProperties(schemaObj.properties || {});\n } else if (normalized.type === \"array\") {\n normalized.items = this.normalizePropertyMetadata(schemaObj.items || { type: \"object\", properties: {} }, \"items\");\n }\n\n return normalized;\n }\n\n private static normalizeProperties(properties: any): Record<string, IPropertyMetadata> {\n const normalizedProps: Record<string, IPropertyMetadata> = {};\n for (const key of Object.keys(properties)) {\n normalizedProps[key] = this.normalizePropertyMetadata(properties[key], key);\n }\n return normalizedProps;\n }\n\n private static normalizePropertyMetadata(prop: any, keyName: string): IPropertyMetadata {\n const normalized: IPropertyMetadata = {\n type: prop.type || \"string\",\n ui: {\n label: prop.ui?.label || this.generateLabel(keyName),\n isKey: !!prop.ui?.isKey,\n readOnly: !!prop.ui?.readOnly,\n widget: prop.ui?.widget,\n group: prop.ui?.group,\n visibleOn: prop.ui?.visibleOn,\n enabledOn: prop.ui?.enabledOn,\n format: prop.ui?.format\n },\n required: !!prop.required,\n maxLength: prop.maxLength,\n minimum: prop.minimum,\n maximum: prop.maximum,\n pattern: prop.pattern,\n precision: prop.precision,\n scale: prop.scale,\n valueHelp: prop.valueHelp\n };\n\n if (normalized.type === \"object\" && prop.properties) {\n normalized.properties = this.normalizeProperties(prop.properties);\n } else if (normalized.type === \"array\" && prop.items) {\n normalized.items = this.normalizePropertyMetadata(prop.items, \"items\");\n }\n\n return normalized;\n }\n\n /**\n * Generates a Title Case label from camelCase or snake_case technical names.\n */\n private static generateLabel(name: string): string {\n if (!name) return \"\";\n let spaced = name.replace(/([A-Z])/g, \" $1\").replace(/_/g, \" \");\n return spaced.split(' ')\n .filter(w => w.length > 0)\n .map(word => word.charAt(0).toUpperCase() + word.slice(1).toLowerCase())\n .join(' ')\n .trim();\n }\n\n /**\n * Infers a v2 ISchema structure dynamically from a plain data payload.\n */\n private static inferSchemaFromData(data: any): ISchema {\n const schema: ISchema = { type: \"object\", properties: {} };\n \n if (!data || typeof data !== \"object\") {\n return schema;\n }\n\n if (Array.isArray(data)) {\n schema.type = \"array\";\n schema.items = {\n type: \"object\",\n properties: data.length > 0 ? this.inferPropertiesFromObject(data[0]) : {}\n };\n } else {\n schema.type = \"object\";\n schema.properties = this.inferPropertiesFromObject(data);\n }\n\n return schema;\n }\n\n private static inferPropertiesFromObject(obj: any): Record<string, IPropertyMetadata> {\n const properties: Record<string, IPropertyMetadata> = {};\n if (!obj || typeof obj !== \"object\") return properties;\n\n for (const key of Object.keys(obj)) {\n const val = obj[key];\n if (val === null || val === undefined) continue;\n \n if (typeof val === \"object\" && !Array.isArray(val)) continue;\n\n let type: FieldType = \"string\";\n let items: IPropertyMetadata | undefined;\n\n if (typeof val === \"number\") type = \"number\";\n else if (typeof val === \"boolean\") type = \"boolean\";\n else if (Array.isArray(val)) {\n type = \"array\";\n items = {\n type: \"object\",\n properties: val.length > 0 ? this.inferPropertiesFromObject(val[0]) : {}\n };\n }\n \n properties[key] = {\n type,\n items,\n ui: {\n label: this.generateLabel(key),\n isKey: false,\n readOnly: false\n }\n };\n }\n\n return properties;\n }\n}\n"],"mappings":"AAAA,gGAOO,MAAMA,EAKT,gBAAcC,CAAUC,EAAiBC,GACrC,IAAIC,EAAYF,EAEhB,UAAWE,IAAc,SAAU,CAC/B,IACIA,EAAYC,KAAKC,MAAMF,EAC3B,CAAE,MAAOG,GACLC,QAAQC,KAAK,qEAAsEF,GACnFH,EAAY,IAChB,CACJ,CAEA,IAAKA,UAAoBA,IAAc,UAAYM,MAAMC,QAAQP,GAAY,CACzE,OAAOQ,KAAKC,oBAAoBV,EACpC,CAGA,MAAMW,EAAsB,CACxBC,MAAOX,EAAUW,OAAS,wBAC1BC,KAAMZ,EAAUY,OAASZ,EAAUa,MAAQ,QAAU,WAGzD,GAAIH,EAAWE,OAAS,SAAU,CAC9BF,EAAWI,WAAaN,KAAKO,oBAAoBf,EAAUc,YAAc,CAAC,EAC9E,MAAO,GAAIJ,EAAWE,OAAS,QAAS,CACpCF,EAAWG,MAAQL,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map":{"version":3,"names":["StateManager","constructor","initialData","safeData","JSON","parse","stringify","this","model","JSONModel","setDefaultBindingMode","getModel","bindControl","control","property","bindingPath","bindProperty","path","extractPayload","data","getData","__exports","__esModule"],"sources":["StateManager.ts"],"sourcesContent":["/**\n * @file StateManager.ts\n * @description Isolated internal state management. Decouples the MetaUI engine from external host models.\n */\n\nimport JSONModel from \"sap/ui/model/json/JSONModel\";\nimport ManagedObject from \"sap/ui/base/ManagedObject\";\n\n/**\n * Manages the isolated internal data payload for the MetaUI engine.\n */\nexport class StateManager {\n private model: JSONModel;\n\n /**\n * Initializes the state manager with an optional initial payload.\n * @param initialData The initial JSON payload to populate the fields.\n */\n constructor(initialData: Record<string, any> = {}) {\n // Deep copy to ensure no reference leakage from the host application\n const safeData = JSON.parse(JSON.stringify(initialData));\n this.model = new JSONModel(safeData);\n this.model.setDefaultBindingMode(\"TwoWay\");\n }\n\n /**\n * Retrieves the isolated JSONModel instance to attach to the root GeneratorHost control.\n * @returns The internal JSONModel.\n */\n public getModel(): JSONModel {\n return this.model;\n }\n\n /**\n * Binds a generated UI control property to a path in the internal model.\n * @param control The target UI5 Control.\n * @param property The UI5 property name (e.g., 'value').\n * @param bindingPath The exact path in the JSON payload.\n */\n public bindControl(control: ManagedObject, property: string, bindingPath: string): void {\n control.bindProperty(property, {\n path: bindingPath,\n model: \"meta\" // Assumes the model is bound to the root container with the name 'meta'\n });\n }\n\n /**\n * Extracts the flat JavaScript object representing the current state of the UI.\n * @returns A serialized record of the data payload, free of UI5 wrappers.\n */\n public extractPayload(): Record<string, any> {\n // Create a deep copy to prevent accidental mutations by the host\n const data = this.model.getData();\n return JSON.parse(JSON.stringify(data));\n }\n}\n"],"mappings":"AAAA,0HAWO,MAAMA,EAOTC,YAAYC,EAAmC,CAAC,GAE5C,MAAMC,EAAWC,KAAKC,MAAMD,KAAKE,UAAUJ,IAC3CK,KAAKC,MAAQ,IAAIC,EAAUN,GAC3BI,KAAKC,MAAME,sBAAsB,SACrC,CAMOC,WACH,OAAOJ,KAAKC,KAChB,CAQOI,YAAYC,EAAwBC,EAAkBC,GACzDF,EAAQG,aAAaF,EAAU,CAC3BG,KAAMF,EACNP,MAAO,QAEf,CAMOU,iBAEH,MAAMC,EAAOZ,KAAKC,MAAMY,UACxB,OAAOhB,KAAKC,MAAMD,KAAKE,UAAUa,GACrC,EACH,IAAAE,EAAA,CAAAC,WAAA,MAAAD,EAAArB,eAAA,OAAAqB,CAAA","ignoreList":[],"sourceRoot":"core"}},{"offset":{"line":8,"column":0},"map":{"version":3,"names":["FormLayout","___FormLayout","TableLayout","___TableLayout","BaseLayout","renderForm","properties","modelName","formTitle","trackPlugin","build","renderTable","tableMeta","tableTitle","__exports","__esModule"],"sources":["BaseLayout.ts"],"sourcesContent":["/**\n * @file BaseLayout.ts\n * @description Central layout factory that delegates to specific form or table layout engines.\n */\n\nimport { ILayoutManager } from \"../interfaces/ILayoutManager\";\nimport { IPropertyMetadata } from \"../interfaces/ISchema\";\nimport Control from \"sap/ui/core/Control\";\nimport { FormLayout } from \"./FormLayout\";\nimport { TableLayout } from \"./TableLayout\";\n\nimport { IPlugin } from \"../interfaces/IPlugin\";\n\nexport class BaseLayout implements ILayoutManager {\n public renderForm(properties: Record<string, IPropertyMetadata>, modelName: string = \"meta\", formTitle?: string, trackPlugin?: (plugin: IPlugin) => void): Control {\n return FormLayout.build(properties, modelName, formTitle, trackPlugin);\n }\n\n public renderTable(tableMeta: IPropertyMetadata, modelName: string = \"meta\", tableTitle?: string, trackPlugin?: (plugin: IPlugin) => void): Control {\n return TableLayout.build(tableMeta, modelName, tableTitle, trackPlugin);\n }\n}\n"],"mappings":"AAAA,8HAAA,MAQSA,EAAUC,EAAA,oBACVC,EAAWC,EAAA,eAIb,MAAMC,EACFC,WAAWC,EAA+CC,EAAoB,OAAQC,EAAoBC,GAC7G,OAAOT,EAAWU,MAAMJ,EAAYC,EAAWC,EAAWC,EAC9D,CAEOE,YAAYC,EAA8BL,EAAoB,OAAQM,EAAqBJ,GAC9F,OAAOP,EAAYQ,MAAME,EAAWL,EAAWM,EAAYJ,EAC/D,EACH,IAAAK,EAAA,CAAAC,WAAA,MAAAD,EAAAV,aAAA,OAAAU,CAAA","ignoreList":[],"sourceRoot":"layouts"}},{"offset":{"line":9,"column":0},"map":{"version":3,"names":["PluginRegistry","___core_PluginRegistry","FormLayout","build","properties","modelName","formTitle","trackPlugin","form","SimpleForm","editable","title","layout","labelSpanXL","labelSpanL","labelSpanM","labelSpanS","adjustLabelSpan","emptySpanXL","emptySpanL","emptySpanM","emptySpanS","columnsXL","columnsL","columnsM","singleContainerFullSize","registry","getInstance","groups","DEFAULT_GROUP","key","Object","keys","meta","groupName","ui","group","push","addContent","Title","text","forEach","field","label","Label","required","visibleOn","expr","replace","bindProperty","parts","path","formatter","plugin","getPlugin","type","widget","control","render","fullWidth","sap","require","GridData","setLayoutData","span","error","Log","message","__exports","__esModule"],"sources":["FormLayout.ts"],"sourcesContent":["/**\n * @file FormLayout.ts\n * @description Generates a fully responsive SAP Fiori Form layout (SimpleForm).\n */\n\nimport SimpleForm from \"sap/ui/layout/form/SimpleForm\";\nimport Label from \"sap/m/Label\";\nimport Title from \"sap/ui/core/Title\";\nimport { IPropertyMetadata } from \"../interfaces/ISchema\";\nimport { PluginRegistry } from \"../core/PluginRegistry\";\nimport { IPlugin } from \"../interfaces/IPlugin\";\n\nexport class FormLayout {\n /**\n * Builds a SimpleForm with ResponsiveGridLayout, injecting the requested plugins.\n * @param properties The dictionary of fields to render.\n * @param modelName The dynamic model name.\n * @param formTitle Optional title for the form block.\n * @param trackPlugin Optional callback to track instantiated plugins.\n */\n public static build(properties: Record<string, IPropertyMetadata>, modelName: string = \"meta\", formTitle?: string, trackPlugin?: (plugin: IPlugin) => void): SimpleForm {\n const form = new SimpleForm({\n editable: true,\n title: formTitle,\n layout: \"ResponsiveGridLayout\",\n labelSpanXL: 4,\n labelSpanL: 4,\n labelSpanM: 4,\n labelSpanS: 12,\n adjustLabelSpan: false,\n emptySpanXL: 0,\n emptySpanL: 0,\n emptySpanM: 0,\n emptySpanS: 0,\n columnsXL: 1,\n columnsL: 1,\n columnsM: 1,\n singleContainerFullSize: false\n });\n\n const registry = PluginRegistry.getInstance();\n \n // Group fields by their ui.group directive\n const groups: Record<string, { key: string; meta: IPropertyMetadata }[]> = {};\n const DEFAULT_GROUP = \"__DEFAULT__\";\n \n for (const key of Object.keys(properties)) {\n const meta = properties[key];\n const groupName = meta.ui?.group || DEFAULT_GROUP;\n if (!groups[groupName]) groups[groupName] = [];\n groups[groupName].push({ key, meta });\n }\n\n // Render groups\n for (const groupName of Object.keys(groups)) {\n if (groupName !== DEFAULT_GROUP) {\n form.addContent(new Title({ text: groupName }));\n }\n \n groups[groupName].forEach((field) => {\n try {\n const label = new Label({\n text: field.meta.ui?.label || field.key,\n required: field.meta.required\n });\n\n // Attach visibility condition to label and control container logic\n if (field.meta.ui?.visibleOn) {\n const expr = `{= ${field.meta.ui.visibleOn.replace(/\\$root\\./g, `${modelName}>/`).replace(/\\./g, '/')} }`;\n label.bindProperty(\"visible\", { parts: [{ path: \"meta>/\" }], formatter: () => false}); // temporary, condition engine does this usually\n }\n\n const plugin = registry.getPlugin(field.meta.type, field.meta.ui?.widget);\n if (trackPlugin) trackPlugin(plugin);\n const control = plugin.render(field.meta, `/${field.key}`, modelName);\n\n if (field.meta.ui?.fullWidth) {\n sap.ui.require([\"sap/ui/layout/GridData\"], (GridData: any) => {\n control.setLayoutData(new GridData({\n span: \"XL12 L12 M12 S12\"\n }));\n });\n }\n\n form.addContent(label);\n form.addContent(control);\n } catch (error) {\n sap.ui.require([\"sap/base/Log\"], (Log: any) => {\n if (Log) Log.error(`[MetaUI] Failed to render field ${field.key}`, (error as Error).message, \"FormLayout\");\n });\n }\n });\n }\n\n return form;\n }\n}\n"],"mappings":"AAAA,oMASSA,EAAcC,EAAA,kBAGhB,MAAMC,EAQT,YAAcC,CAAMC,EAA+CC,EAAoB,OAAQC,EAAoBC,GAC/G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C,EAAMT,KAAKE,IAAIwB,UAAW,CAC1BC,IAAIzB,GAAG0B,QAAQ,CAAC,0BAA4BC,IACxCL,EAAQM,cAAc,IAAID,EAAS,CAC/BE,KAAM,uBAGlB,CAEAxD,EAAK8B,WAAWK,GAChBnC,EAAK8B,WAAWmB,EACpB,CAAE,MAAOQ,GACLL,IAAIzB,GAAG0B,QAAQ,CAAC,gBAAkBK,IAC9B,GAAIA,EAAKA,EAAID,MAAM,mCAAmCvB,EAAMZ,MAAQmC,EAAgBE,QAAS,eAErG,GAER,CAEA,OAAO3D,CACX,EACH,IAAA4D,EAAA,CAAAC,WAAA,MAAAD,EAAAlE,aAAA,OAAAkE,CAAA","ignoreList":[],"sourceRoot":"layouts"}},{"offset":{"line":10,"column":0},"map":{"version":3,"names":["PluginRegistry","___core_PluginRegistry","TableLayout","build","tableMeta","bindingPath","tableTitle","trackPlugin","properties","Error","parts","split","actualModelName","length","undefined","actualPath","table","Table","headerToolbar","Toolbar","content","Title","text","ToolbarSpacer","Button","icon","press","oEvent","btn","getSource","tbl","getParent","model","getModel","info","getBindingInfo","path","data","getProperty","push","setProperty","fixedLayout","mode","delete","item","getParameter","getBindingContext","getPath","splitPaths","index","parseInt","pop","arrayPath","join","splice","templateCells","registry","getInstance","props","Object","keys","forEach","key","fieldMeta","isKey","ui","column","Column","header","Text","label","demandPopin","minScreenWidth","popinDisplay","addColumn","plugin","getPlugin","type","widget","control","render","error","sap","require","Log","message","rowTemplate","ColumnListItem","cells","bindItems","template","templateShareable","__exports","__esModule"],"sources":["TableLayout.ts"],"sourcesContent":["/**\n * @file TableLayout.ts\n * @description Generates a responsive SAP Fiori Table layout for v2 schema.\n */\n\nimport Table from \"sap/m/Table\";\nimport Column from \"sap/m/Column\";\nimport Text from \"sap/m/Text\";\nimport ColumnListItem from \"sap/m/ColumnListItem\";\nimport Toolbar from \"sap/m/Toolbar\";\nimport Title from \"sap/m/Title\";\nimport ToolbarSpacer from \"sap/m/ToolbarSpacer\";\nimport Button from \"sap/m/Button\";\nimport JSONModel from \"sap/ui/model/json/JSONModel\";\nimport { PluginRegistry } from \"../core/PluginRegistry\";\nimport Control from \"sap/ui/core/Control\";\nimport { IPlugin } from \"../interfaces/IPlugin\";\nimport { IPropertyMetadata } from \"../interfaces/ISchema\";\n\nexport class TableLayout {\n /**\n * Builds a responsive Table, dynamically calculating column priorities.\n */\n public static build(tableMeta: IPropertyMetadata, bindingPath: string = \"meta>/\", tableTitle: string = \"Table\", trackPlugin?: (plugin: IPlugin) => void): Table {\n if (!tableMeta.properties) {\n throw new Error(\"[MetaUI] Table requires an items schema with properties.\");\n }\n\n const parts = bindingPath.split(\">\");\n const actualModelName = parts.length > 1 ? parts[0] : undefined;\n const actualPath = parts.length > 1 ? parts[1] : bindingPath;\n // e.g. \"meta>/Contacts\" -> actualModelName = \"meta\", actualPath = \"/Contacts\"\n\n const table = new Table({\n headerToolbar: new Toolbar({\n content: [\n new Title({ text: tableTitle }),\n new ToolbarSpacer(),\n new Button({\n text: \"Add Row\",\n icon: \"sap-icon://add\",\n press: (oEvent: any) => {\n const btn = oEvent.getSource();\n const tbl = btn.getParent().getParent() as Table;\n const model = tbl.getModel(actualModelName) as JSONModel;\n const info = tbl.getBindingInfo(\"items\");\n if (!info || !info.path) return;\n \n const data = model.getProperty(info.path) || [];\n data.push({}); // append empty row\n model.setProperty(info.path, data);\n }\n })\n ]\n }),\n fixedLayout: false,\n mode: \"Delete\",\n delete: (oEvent: any) => {\n const item = oEvent.getParameter(\"listItem\");\n const path = item.getBindingContext(actualModelName).getPath(); \n const model = item.getModel(actualModelName) as JSONModel;\n \n const splitPaths = path.split(\"/\");\n const index = parseInt(splitPaths.pop() || \"0\", 10);\n let arrayPath = splitPaths.join(\"/\");\n if (arrayPath === \"\") arrayPath = \"/\";\n \n const data = model.getProperty(arrayPath);\n data.splice(index, 1);\n model.setProperty(arrayPath, data);\n }\n });\n\n const templateCells: Control[] = [];\n const registry = PluginRegistry.getInstance();\n const props = tableMeta.properties;\n\n Object.keys(props).forEach((key) => {\n try {\n const fieldMeta = props[key];\n const isKey = !!fieldMeta.ui?.isKey;\n \n const column = new Column({\n header: new Text({ text: fieldMeta.ui?.label || key }),\n demandPopin: !isKey, \n minScreenWidth: isKey ? \"\" : \"Tablet\",\n popinDisplay: \"Inline\"\n });\n table.addColumn(column);\n\n const plugin = registry.getPlugin(fieldMeta.type, fieldMeta.ui?.widget);\n if (trackPlugin) trackPlugin(plugin);\n const control = plugin.render(fieldMeta, key, actualModelName); // No trailing slash for relative bindings\n templateCells.push(control);\n } catch (error) {\n sap.ui.require([\"sap/base/Log\"], (Log: any) => {\n if (Log) Log.error(`[MetaUI] Failed to render column ${key}`, (error as Error).message, \"TableLayout\");\n });\n \n // Add an empty text control as a fallback so the table columns match the cells array length\n templateCells.push(new Text({ text: \"Error\" }));\n }\n });\n\n const rowTemplate = new ColumnListItem({\n cells: templateCells\n });\n\n // V2 Fix: Actually bind the items to the table!\n table.bindItems({\n path: actualPath,\n model: actualModelName,\n template: rowTemplate,\n templateShareable: false\n });\n\n return table;\n }\n}\n"],"mappings":"AAAA,iRAcSA,EAAcC,EAAA,kBAKhB,MAAMC,EAIT,YAAcC,CAAMC,EAA8BC,EAAsB,SAAUC,EAAqB,QAASC,GAC5G,IAAKH,EAAUI,WAAY,CACvB,MAAM,IAAIC,MAAM,2DACpB,CAEA,MAAMC,EAAQL,EAAYM,MAAM,KAChC,MAAMC,EAAkBF,EAAMG,OAAS,EAAIH,EAAM,GAAKI,UACtD,MAAMC,EAAaL,EAAMG,OAAS,EAAIH,EAAM,GAAKL,EAGjD,MAAMW,EAAQ,IAAIC,EAAM,CACpBC,cAAe,IAAIC,EAAQ,CACvBC,QAAS,CACL,IAAIC,EAAM,CAAEC,KAAMhB,IAClB,IAAIiB,EACJ,IAAIC,EAAO,CACPF,KAAM,UACNG,KAAM,iBACNC,MAAQC,IACJ,MAAMC,EAAMD,EAAOE,YACnB,MAAMC,EAAMF,EAAIG,YAAYA,YAC5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B,GAAIA,EAAKA,EAAIH,MAAM,oCAAoCnB,IAAQmB,EAAgBI,QAAS,iBAI5F9B,EAAchB,KAAK,IAAI8B,EAAK,CAAE/C,KAAM,UACxC,IAGJ,MAAMgE,EAAc,IAAIC,EAAe,CACnCC,MAAOjC,IAIXvC,EAAMyE,UAAU,CACZrD,KAAMrB,EACNiB,MAAOpB,EACP8E,SAAUJ,EACVK,kBAAmB,QAGvB,OAAO3E,CACX,EACH,IAAA4E,EAAA,CAAAC,WAAA,MAAAD,EAAA1F,cAAA,OAAA0F,CAAA","ignoreList":[],"sourceRoot":"layouts"}},{"offset":{"line":11,"column":0},"map":{"version":3,"names":["PluginRegistry","___core_PluginRegistry","StringPlugin","___plugins_StringPlugin","NumberPlugin","___plugins_NumberPlugin","BooleanPlugin","___plugins_BooleanPlugin","DropdownPlugin","___plugins_DropdownPlugin","DatePlugin","___plugins_DatePlugin","TimePlugin","___plugins_TimePlugin","DateTimePlugin","___plugins_DateTimePlugin","ArrayPlugin","___plugins_ArrayPlugin","TextAreaPlugin","___plugins_TextAreaPlugin","SwitchPlugin","___plugins_SwitchPlugin","Core","initLibrary","name","version","dependencies","controls","elements","interfaces","noLibraryCSS","registry","getInstance","register","__exports","window"],"sources":["library.ts"],"sourcesContent":["/**\n * @file library.ts\n * @description Standard SAP UI5 library registration file. Exposes the MetaUI namespace \n * and automatically bootstraps the internal PluginRegistry.\n */\n\nimport Core from \"sap/ui/core/Core\";\nimport { PluginRegistry } from \"./core/PluginRegistry\";\nimport { StringPlugin } from \"./plugins/StringPlugin\";\nimport { NumberPlugin } from \"./plugins/NumberPlugin\";\nimport { BooleanPlugin } from \"./plugins/BooleanPlugin\";\nimport { DropdownPlugin } from \"./plugins/DropdownPlugin\";\nimport { DatePlugin } from \"./plugins/DatePlugin\";\nimport { TimePlugin } from \"./plugins/TimePlugin\";\nimport { DateTimePlugin } from \"./plugins/DateTimePlugin\";\nimport { ArrayPlugin } from \"./plugins/ArrayPlugin\";\n\nimport { TextAreaPlugin } from \"./plugins/TextAreaPlugin\";\nimport { SwitchPlugin } from \"./plugins/SwitchPlugin\";\n\n// Delegate to standard library registration\nCore.initLibrary({\n name: \"nz.co.siliconst.ui5.metaui\",\n version: \"1.0.0\",\n dependencies: [\n \"sap.ui.core\",\n \"sap.m\",\n \"sap.ui.layout\",\n \"sap.ui.table\"\n ],\n controls: [\n \"nz.co.siliconst.ui5.metaui.controls.GeneratorHost\"\n ],\n elements: [],\n interfaces: [],\n noLibraryCSS: true\n});\n\n/**\n * Global Bootstrapper: Maps all standard primitive types to their respective plugins.\n */\nconst registry = PluginRegistry.getInstance();\nregistry.register(\"string\", StringPlugin);\nregistry.register(\"string\", TextAreaPlugin, \"textArea\");\nregistry.register(\"number\", NumberPlugin);\nregistry.register(\"boolean\", BooleanPlugin);\nregistry.register(\"boolean\", SwitchPlugin, \"switch\");\nregistry.register(\"dropdown\", DropdownPlugin);\nregistry.register(\"date\", DatePlugin);\nregistry.register(\"time\", TimePlugin);\nregistry.register(\"datetime\", DateTimePlugin);\nregistry.register(\"array\", ArrayPlugin);\n\n// Exporting window object safely for UI5 compatibility if needed\nexport default (window as any)[\"nz\"][\"co\"][\"siliconst\"][\"ui5\"][\"metaui\"];\n"],"mappings":"AAAA,qZAOSA,EAAcC,EAAA,wBACdC,EAAYC,EAAA,sBACZC,EAAYC,EAAA,sBACZC,EAAaC,EAAA,uBACbC,EAAcC,EAAA,wBACdC,EAAUC,EAAA,oBACVC,EAAUC,EAAA,oBACVC,EAAcC,EAAA,wBACdC,EAAWC,EAAA,qBAEXC,EAAcC,EAAA,wBACdC,EAAYC,EAAA,gBAGrBC,EAAKC,YAAY,CACbC,KAAM,6BACNC,QAAS,QACTC,aAAc,CACV,cACA,QACA,gBACA,gBAEJC,SAAU,CACN,qDAEJC,SAAU,GACVC,WAAY,GACZC,aAAc,OAMlB,MAAMC,EAAW/B,EAAegC,cAChCD,EAASE,SAAS,SAAU/B,GAC5B6B,EAASE,SAAS,SAAUf,EAAgB,YAC5Ca,EAASE,SAAS,SAAU7B,GAC5B2B,EAASE,SAAS,UAAW3B,GAC7ByB,EAASE,SAAS,UAAWb,EAAc,UAC3CW,EAASE,SAAS,WAAYzB,GAC9BuB,EAASE,SAAS,OAAQvB,GAC1BqB,EAASE,SAAS,OAAQrB,GAC1BmB,EAASE,SAAS,WAAYnB,GAC9BiB,EAASE,SAAS,QAASjB,GAE3B,IAAAkB,EACgBC,OAAe,MAAM,MAAM,aAAa,OAAO,UAAS,OAAAD,CAAA","ignoreList":[],"sourceRoot":""}},{"offset":{"line":12,"column":0},"map":{"version":3,"names":["ArrayPlugin","render","field","bindingPath","modelName","propKey","startsWith","substring","Button","text","icon","press","oEvent","btn","getSource","context","getBindingContext","rowData","getObject","nestedData","subSchema","type","properties","ui","label","items","sap","require","GeneratorHost","host","schemaDefinition","initialData","attachSubmit","e","payload","getParameter","updatedArray","parentModel","getModel","contextPath","getPath","setProperty","openInDialog","validate","onStateChange","newMetadata","__exports","__esModule"],"sources":["ArrayPlugin.ts"],"sourcesContent":["/**\n * @file ArrayPlugin.ts\n * @description Renders a button that drills down into a nested table (array) via a recursive Dialog using v2 schema.\n */\n\nimport { IPlugin } from \"../interfaces/IPlugin\";\nimport { IPropertyMetadata } from \"../interfaces/ISchema\";\nimport Control from \"sap/ui/core/Control\";\nimport Button from \"sap/m/Button\";\nimport JSONModel from \"sap/ui/model/json/JSONModel\";\n\nexport class ArrayPlugin implements IPlugin {\n public render(field: IPropertyMetadata, bindingPath: string, modelName: string): Control {\n // In tables, bindingPath is usually passed simply as the key (e.g. 'lineItems' or '/lineItems')\n const propKey = bindingPath.startsWith(\"/\") ? bindingPath.substring(1) : bindingPath;\n \n return new Button({\n text: \"View Records\",\n icon: \"sap-icon://list\",\n press: (oEvent: any) => {\n const btn = oEvent.getSource() as Button;\n const context = btn.getBindingContext(modelName);\n if (!context) return;\n \n const rowData = context.getObject();\n const nestedData = rowData[propKey] || [];\n \n // Synthesize a v2 schema for the nested array dialog as an object wrapper\n const subSchema = {\n type: \"object\",\n properties: {\n [propKey]: {\n type: \"array\",\n ui: { label: field.ui?.label || propKey },\n items: field.items || {\n type: \"object\",\n properties: {} // inference will handle it if empty\n }\n }\n }\n };\n\n sap.ui.require([\"nz/co/siliconst/ui5/metaui/controls/GeneratorHost\"], (GeneratorHost: any) => {\n const host = new GeneratorHost({\n schemaDefinition: subSchema,\n initialData: {\n [propKey]: nestedData\n }\n });\n\n // V2 Fix: Capture the nested dialog's save event and update the parent model!\n host.attachSubmit((e: any) => {\n const payload = e.getParameter(\"payload\");\n const updatedArray = payload[propKey];\n \n const parentModel = btn.getModel(modelName) as JSONModel;\n const contextPath = btn.getBindingContext(modelName).getPath();\n \n // Push changes back to parent model to force UI5 bindings to refresh\n parentModel.setProperty(`${contextPath}/${propKey}`, updatedArray);\n });\n\n host.openInDialog(`Nested Records: ${field.ui?.label || propKey}`, \"Close\");\n });\n }\n });\n }\n\n public validate(): boolean { return true; }\n public onStateChange(newMetadata: IPropertyMetadata): void {}\n}\n"],"mappings":"AAAA,6GAWO,MAAMA,EACFC,OAAOC,EAA0BC,EAAqBC,GAEzD,MAAMC,EAAUF,EAAYG,WAAW,KAAOH,EAAYI,UAAU,GAAKJ,EAEzE,OAAO,IAAIK,EAAO,CACdC,KAAM,eACNC,KAAM,kBACNC,MAAQC,IACJ,MAAMC,EAAMD,EAAOE,YACnB,MAAMC,EAAUF,EAAIG,kBAAkBZ,GACtC,IAAKW,EAAS,OAEd,MAAME,EAAUF,EAAQG,YACxB,MAAMC,EAAaF,EAAQZ,IAAY,GAGvC,MAAMe,EAAY,CACdC,KAAM,SACNC,WAAY,CACRjB,CAACA,GAAU,CACPgB,KAAM,QACNE,GAAI,CAAEC,MAAOtB,EAAMqB,IAAIC,OAASnB,GAChCoB,MAAOvB,EAAMuB,OAAS,CAClBJ,KAAM,SACNC,WAAY,CAAC,MAM7BI,IAAIH,GAAGI,QAAQ,CAAC,qDAAuDC,IACnE,MAAMC,EAAO,IAAID,EAAc,CAC3BE,iBAAkBV,EAClBW,YAAa,CACT1B,CAACA,GAAUc,KAKnBU,EAAKG,aAAcC,IACf,MAAMC,EAAUD,EAAEE,aAAa,WAC/B,MAAMC,EAAeF,EAAQ7B,GAE7B,MAAMgC,EAAcxB,EAAIyB,SAASlC,GACjC,MAAMmC,EAAc1B,EAAIG,kBAAkBZ,GAAWoC,UAGrDH,EAAYI,YAAY,GAAGF,KAAelC,IAAW+B,KAGzDP,EAAKa,aAAa,mBAAmBxC,EAAMqB,IAAIC,OAASnB,IAAW,aAInF,CAEOsC,WAAsB,OAAO,IAAM,CACnCC,cAAcC,GAAuC,EAC/D,IAAAC,EAAA,CAAAC,WAAA,MAAAD,EAAA9C,cAAA,OAAA8C,CAAA","ignoreList":[],"sourceRoot":"plugins"}},{"offset":{"line":13,"column":0},"map":{"version":3,"names":["EventBus","___core_EventBus","BasePlugin","control","metadata","fieldKey","onStateChange","newMetadata","this","applyState","applyCommonDirectives","modelName","ui","readOnly","undefined","setEditable","visibleOn","expr","replace","bindProperty","parts","path","formatter","enabledOn","setEnabled","publishChange","newValue","getInstance","publishFieldChange","fieldName","__exports","__esModule"],"sources":["BasePlugin.ts"],"sourcesContent":["/**\n * @file BasePlugin.ts\n * @description Abstract foundation for all MetaUI plugins, enforcing lifecycle hooks for v2 Schema.\n */\n\nimport { IPlugin } from \"../interfaces/IPlugin\";\nimport { IPropertyMetadata } from \"../interfaces/ISchema\";\nimport { EventBus } from \"../core/EventBus\";\nimport Control from \"sap/ui/core/Control\";\n\nexport abstract class BasePlugin implements IPlugin {\n protected control: Control | null = null;\n protected metadata: IPropertyMetadata | null = null;\n protected fieldKey: string = \"\";\n\n public abstract render(fieldMetadata: IPropertyMetadata, bindingPath: string, modelName?: string): Control;\n\n public abstract validate(): boolean;\n\n public onStateChange(newMetadata: IPropertyMetadata): void {\n this.metadata = newMetadata;\n this.applyState();\n }\n\n protected abstract applyState(): void;\n\n /**\n * Helper to apply common UI directives (like readOnly, visibleOn) directly to any control.\n */\n protected applyCommonDirectives(control: any, metadata: IPropertyMetadata, modelName: string = \"meta\"): void {\n if (metadata.ui?.readOnly !== undefined && typeof control.setEditable === \"function\") {\n control.setEditable(!metadata.ui.readOnly);\n }\n\n if (metadata.ui?.visibleOn) {\n const expr = `{= ${metadata.ui.visibleOn.replace(/\\$root\\./g, `${modelName}>/`).replace(/\\./g, '/')} }`;\n control.bindProperty(\"visible\", { parts: [{ path: \"meta>/\" }], formatter: () => false });\n // The ConditionEngine handles actual binding injection, but here we can set a fallback or natively bind if we bypass ConditionEngine.\n control.bindProperty(\"visible\", expr);\n }\n \n if (metadata.ui?.enabledOn && typeof control.setEnabled === \"function\") {\n const expr = `{= ${metadata.ui.enabledOn.replace(/\\$root\\./g, `${modelName}>/`).replace(/\\./g, '/')} }`;\n control.bindProperty(\"enabled\", expr);\n }\n }\n\n protected publishChange(newValue: any): void {\n if (this.metadata && this.fieldKey) {\n EventBus.getInstance().publishFieldChange({\n fieldName: this.fieldKey,\n newValue: newValue\n });\n }\n }\n}\n"],"mappings":"AAAA,gHAAA,MAOSA,EAAQC,EAAA,YAGV,MAAeC,EACRC,QAA0B,KAC1BC,SAAqC,KACrCC,SAAmB,GAMtBC,cAAcC,GACjBC,KAAKJ,SAAWG,EAChBC,KAAKC,YACT,CAOUC,sBAAsBP,EAAcC,EAA6BO,EAAoB,QAC3F,GAAIP,EAASQ,IAAIC,WAAaC,kBAAoBX,EAAQY,cAAgB,WAAY,CAClFZ,EAAQY,aAAaX,EAASQ,GAAGC,SACrC,CAEA,GAAIT,EAASQ,IAAII,UAAW,CACxB,MAAMC,EAAO,MAAMb,EAASQ,GAAGI,UAAUE,QAAQ,YAAa,GAAGP,OAAeO,QAAQ,MAAO,SAC/Ff,EAAQgB,aAAa,UAAW,CAAEC,MAAO,CAAC,CAAEC,KAAM,WAAaC,UAAWA,IAAM,QAEhFnB,EAAQgB,aAAa,UAAWF,EACpC,CAEA,GAAIb,EAASQ,IAAIW,kBAAoBpB,EAAQqB,aAAe,WAAY,CACpE,MAAMP,EAAO,MAAMb,EAASQ,GAAGW,UAAUL,QAAQ,YAAa,GAAGP,OAAeO,QAAQ,MAAO,SAC/Ff,EAAQgB,aAAa,UAAWF,EACpC,CACJ,CAEUQ,cAAcC,GACpB,GAAIlB,KAAKJ,UAAYI,KAAKH,SAAU,CAChCL,EAAS2B,cAAcC,mBAAmB,CACtCC,UAAWrB,KAAKH,SAChBqB,SAAUA,GAElB,CACJ,EACH,IAAAI,EAAA,CAAAC,WAAA,MAAAD,EAAA5B,aAAA,OAAA4B,CAAA","ignoreList":[],"sourceRoot":"plugins"}},{"offset":{"line":14,"column":0},"map":{"version":3,"names":["BasePlugin","___BasePlugin","BooleanPlugin","render","fieldMetadata","bindingPath","modelName","this","metadata","control","CheckBox","selected","enabled","ui","readOnly","select","oEvent","val","getParameter","publishChange","validate","applyState","setEnabled","__exports","__esModule"],"sources":["BooleanPlugin.ts"],"sourcesContent":["/**\n * @file BooleanPlugin.ts\n * @description Renders a sap.m.Switch for boolean states.\n */\n\nimport { BasePlugin } from \"./BasePlugin\";\nimport { IPropertyMetadata } from \"../interfaces/ISchema\";\nimport CheckBox from \"sap/m/CheckBox\";\nimport Control from \"sap/ui/core/Control\";\n\n/**\n * Handles rendering logic for toggleable booleans.\n */\nexport class BooleanPlugin extends BasePlugin {\n public render(fieldMetadata: IPropertyMetadata, bindingPath: string, modelName: string = \"meta\"): Control {\n this.metadata = fieldMetadata;\n \n this.control = new CheckBox({\n selected: `{${modelName}>${bindingPath}}`,\n enabled: !fieldMetadata.ui?.readOnly,\n select: (oEvent: any) => {\n const val = oEvent.getParameter(\"selected\");\n this.publishChange(val);\n this.validate();\n }\n });\n\n return this.control;\n }\n\n public validate(): boolean {\n // Boolean states rarely fail validation.\n return true;\n }\n\n protected applyState(): void {\n if (this.control && this.metadata) {\n (this.control as CheckBox).setEnabled(!this.metadata.ui?.readOnly);\n }\n }\n}\n"],"mappings":"AAAA,kIAAA,MAKSA,EAAUC,EAAA,cAQZ,MAAMC,UAAsBF,EACxBG,OAAOC,EAAkCC,EAAqBC,EAAoB,QACrFC,KAAKC,SAAWJ,EAEhBG,KAAKE,QAAU,IAAIC,EAAS,CACxBC,SAAU,IAAIL,KAAaD,KAC3BO,SAAUR,EAAcS,IAAIC,SAC5BC,OAASC,IACL,MAAMC,EAAMD,EAAOE,aAAa,YAChCX,KAAKY,cAAcF,GACnBV,KAAKa,cAIb,OAAOb,KAAKE,OAChB,CAEOW,WAEH,OAAO,IACX,CAEUC,aACN,GAAId,KAAKE,SAAWF,KAAKC,SAAU,CAC9BD,KAAKE,QAAqBa,YAAYf,KAAKC,SAASK,IAAIC,SAC7D,CACJ,EACH,IAAAS,EAAA,CAAAC,WAAA,MAAAD,EAAArB,gBAAA,OAAAqB,CAAA","ignoreList":[],"sourceRoot":"plugins"}},{"offset":{"line":15,"column":0},"map":{"version":3,"names":["BasePlugin","___BasePlugin","DatePlugin","render","fieldMetadata","bindingPath","modelName","this","metadata","control","DatePicker","value","path","type","formatOptions","source","pattern","displayFormat","editable","ui","readOnly","required","change","oEvent","val","getParameter","publishChange","validate","dp","isValid","isValidValue","getValue","trim","setValueState","setValueStateText","applyState","setEditable","setRequired","__exports","__esModule"],"sources":["DatePlugin.ts"],"sourcesContent":["/**\n * @file DatePlugin.ts\n * @description Renders a sap.m.DatePicker natively bound to ISO date strings.\n */\n\nimport { BasePlugin } from \"./BasePlugin\";\nimport { IPropertyMetadata } from \"../interfaces/ISchema\";\nimport DatePicker from \"sap/m/DatePicker\";\nimport Control from \"sap/ui/core/Control\";\n\n/**\n * Handles rendering logic for Date strings.\n */\nexport class DatePlugin extends BasePlugin {\n public render(fieldMetadata: IPropertyMetadata, bindingPath: string, modelName: string = \"meta\"): Control {\n this.metadata = fieldMetadata;\n \n this.control = new DatePicker({\n value: {\n path: `${modelName}>${bindingPath}`,\n type: \"sap.ui.model.type.Date\",\n formatOptions: {\n source: { pattern: \"yyyy-MM-dd\" },\n pattern: \"yyyy-MM-dd\"\n }\n },\n displayFormat: \"long\",\n editable: !fieldMetadata.ui?.readOnly,\n required: fieldMetadata.required,\n change: (oEvent: any) => {\n const val = oEvent.getParameter(\"value\");\n this.publishChange(val);\n this.validate();\n }\n });\n\n return this.control;\n }\n\n public validate(): boolean {\n if (!this.control || !this.metadata) return true;\n const dp = this.control as DatePicker;\n const isValid = typeof dp.isValidValue === \"function\" ? dp.isValidValue() : true;\n const val = dp.getValue();\n\n if (this.metadata.required && (!val || typeof val !== 'string' || val.trim() === \"\")) {\n dp.setValueState(\"Error\" as any);\n dp.setValueStateText(\"A valid date is required.\");\n return false;\n }\n\n if (val && !isValid) {\n dp.setValueState(\"Error\" as any);\n dp.setValueStateText(\"Invalid date format.\");\n return false;\n }\n\n dp.setValueState(\"None\" as any);\n return true;\n }\n\n protected applyState(): void {\n if (this.control && this.metadata) {\n const dp = this.control as DatePicker;\n dp.setEditable(!this.metadata.ui?.readOnly);\n dp.setRequired(this.metadata.required);\n }\n }\n}\n"],"mappings":"AAAA,iIAAA,MAKSA,EAAUC,EAAA,cAQZ,MAAMC,UAAmBF,EACrBG,OAAOC,EAAkCC,EAAqBC,EAAoB,QACrFC,KAAKC,SAAWJ,EAEhBG,KAAKE,QAAU,IAAIC,EAAW,CAC1BC,MAAO,CACHC,KAAM,GAAGN,KAAaD,IACtBQ,KAAM,yBACNC,cAAe,CACXC,OAAQ,CAAEC,QAAS,cACnBA,QAAS,eAGjBC,cAAe,OACfC,UAAWd,EAAce,IAAIC,SAC7BC,SAAUjB,EAAciB,SACxBC,OAASC,IACL,MAAMC,EAAMD,EAAOE,aAAa,SAChClB,KAAKmB,cAAcF,GACnBjB,KAAKoB,cAIb,OAAOpB,KAAKE,OAChB,CAEOkB,WACH,IAAKpB,KAAKE,UAAYF,KAAKC,SAAU,OAAO,KAC5C,MAAMoB,EAAKrB,KAAKE,QAChB,MAAMoB,SAAiBD,EAAGE,eAAiB,WAAaF,EAAGE,eAAiB,KAC5E,MAAMN,EAAMI,EAAGG,WAEf,GAAIxB,KAAKC,SAASa,YAAcG,UAAcA,IAAQ,UAAYA,EAAIQ,SAAW,IAAK,CAClFJ,EAAGK,cAAc,SACjBL,EAAGM,kBAAkB,6BACrB,OAAO,KACX,CAEA,GAAIV,IAAQK,EAAS,CACjBD,EAAGK,cAAc,SACjBL,EAAGM,kBAAkB,wBACrB,OAAO,KACX,CAEAN,EAAGK,cAAc,QACjB,OAAO,IACX,CAEUE,aACN,GAAI5B,KAAKE,SAAWF,KAAKC,SAAU,CAC/B,MAAMoB,EAAKrB,KAAKE,QAChBmB,EAAGQ,aAAa7B,KAAKC,SAASW,IAAIC,UAClCQ,EAAGS,YAAY9B,KAAKC,SAASa,SACjC,CACJ,EACH,IAAAiB,EAAA,CAAAC,WAAA,MAAAD,EAAApC,aAAA,OAAAoC,CAAA","ignoreList":[],"sourceRoot":"plugins"}},{"offset":{"line":16,"column":0},"map":{"version":3,"names":["BasePlugin","___BasePlugin","DateTimePlugin","render","fieldMetadata","bindingPath","modelName","this","metadata","control","DateTimePicker","value","path","type","formatOptions","source","pattern","editable","ui","readOnly","required","change","oEvent","val","getParameter","publishChange","validate","input","isValid","isValidValue","getValue","trim","setValueState","setValueStateText","applyState","setEditable","setRequired","__exports","__esModule"],"sources":["DateTimePlugin.ts"],"sourcesContent":["/**\n * @file DateTimePlugin.ts\n * @description Handles rendering logic for DateTime strings (timestamps).\n */\n\nimport { BasePlugin } from \"./BasePlugin\";\nimport { IPropertyMetadata } from \"../interfaces/ISchema\";\nimport DateTimePicker from \"sap/m/DateTimePicker\";\nimport Control from \"sap/ui/core/Control\";\n\n/**\n * Handles rendering and logic for timestamps/datetime inputs.\n */\nexport class DateTimePlugin extends BasePlugin {\n public render(fieldMetadata: IPropertyMetadata, bindingPath: string, modelName: string = \"meta\"): Control {\n this.metadata = fieldMetadata;\n \n this.control = new DateTimePicker({\n value: {\n path: `${modelName}>${bindingPath}`,\n type: \"sap.ui.model.type.DateTime\",\n formatOptions: {\n source: { pattern: \"yyyy-MM-dd'T'HH:mm:ss'Z'\" },\n pattern: \"yyyy-MM-dd'T'HH:mm:ss'Z'\"\n }\n },\n editable: !fieldMetadata.ui?.readOnly,\n required: fieldMetadata.required,\n change: (oEvent: any) => {\n const val = oEvent.getParameter(\"value\");\n this.publishChange(val);\n this.validate();\n }\n });\n\n return this.control;\n }\n\n public validate(): boolean {\n if (!this.control || !this.metadata) return true;\n const input = this.control as DateTimePicker;\n const isValid = typeof input.isValidValue === \"function\" ? input.isValidValue() : true;\n const val = input.getValue();\n\n if (this.metadata.required && (!val || typeof val !== 'string' || val.trim() === \"\")) {\n input.setValueState(\"Error\" as any);\n input.setValueStateText(\"This field is required.\");\n return false;\n }\n\n if (val && !isValid) {\n input.setValueState(\"Error\" as any);\n input.setValueStateText(\"Invalid datetime format.\");\n return false;\n }\n\n input.setValueState(\"None\" as any);\n return true;\n }\n\n protected applyState(): void {\n if (this.control && this.metadata) {\n const input = this.control as DateTimePicker;\n input.setEditable(!this.metadata.ui?.readOnly);\n input.setRequired(this.metadata.required);\n }\n }\n}\n"],"mappings":"AAAA,yIAAA,MAKSA,EAAUC,EAAA,cAQZ,MAAMC,UAAuBF,EACzBG,OAAOC,EAAkCC,EAAqBC,EAAoB,QACrFC,KAAKC,SAAWJ,EAEhBG,KAAKE,QAAU,IAAIC,EAAe,CAC9BC,MAAO,CACHC,KAAM,GAAGN,KAAaD,IACtBQ,KAAM,6BACNC,cAAe,CACXC,OAAQ,CAAEC,QAAS,4BACnBA,QAAS,6BAGjBC,UAAWb,EAAcc,IAAIC,SAC7BC,SAAUhB,EAAcgB,SACxBC,OAASC,IACL,MAAMC,EAAMD,EAAOE,aAAa,SAChCjB,KAAKkB,cAAcF,GACnBhB,KAAKmB,cAIb,OAAOnB,KAAKE,OAChB,CAEOiB,WACH,IAAKnB,KAAKE,UAAYF,KAAKC,SAAU,OAAO,KAC5C,MAAMmB,EAAQpB,KAAKE,QACnB,MAAMmB,SAAiBD,EAAME,eAAiB,WAAaF,EAAME,eAAiB,KAClF,MAAMN,EAAMI,EAAMG,WAElB,GAAIvB,KAAKC,SAASY,YAAcG,UAAcA,IAAQ,UAAYA,EAAIQ,SAAW,IAAK,CAClFJ,EAAMK,cAAc,SACpBL,EAAMM,kBAAkB,2BACxB,OAAO,KACX,CAEA,GAAIV,IAAQK,EAAS,CACjBD,EAAMK,cAAc,SACpBL,EAAMM,kBAAkB,4BACxB,OAAO,KACX,CAEAN,EAAMK,cAAc,QACpB,OAAO,IACX,CAEUE,aACN,GAAI3B,KAAKE,SAAWF,KAAKC,SAAU,CAC/B,MAAMmB,EAAQpB,KAAKE,QACnBkB,EAAMQ,aAAa5B,KAAKC,SAASU,IAAIC,UACrCQ,EAAMS,YAAY7B,KAAKC,SAASY,SACpC,CACJ,EACH,IAAAiB,EAAA,CAAAC,WAAA,MAAAD,EAAAnC,iBAAA,OAAAmC,CAAA","ignoreList":[],"sourceRoot":"plugins"}},{"offset":{"line":17,"column":0},"map":{"version":3,"names":["BasePlugin","___BasePlugin","DropdownPlugin","render","fieldMetadata","bindingPath","modelName","this","metadata","select","Select","selectedKey","enabled","ui","readOnly","forceSelection","change","oEvent","item","getParameter","val","getKey","publishChange","validate","valueHelp","Array","isArray","addItem","Item","key","text","forEach","vh","control","getSelectedKey","required","trim","setValueState","setValueStateText","applyState","setEnabled","__exports","__esModule"],"sources":["DropdownPlugin.ts"],"sourcesContent":["/**\n * @file DropdownPlugin.ts\n * @description Renders a sap.m.Select utilizing the schema's valueHelp structure.\n */\n\nimport { BasePlugin } from \"./BasePlugin\";\nimport { IPropertyMetadata } from \"../interfaces/ISchema\";\nimport Select from \"sap/m/Select\";\nimport Item from \"sap/ui/core/Item\";\nimport Control from \"sap/ui/core/Control\";\n\n/**\n * Handles rendering logic for dropdown inputs.\n */\nexport class DropdownPlugin extends BasePlugin {\n public render(fieldMetadata: IPropertyMetadata, bindingPath: string, modelName: string = \"meta\"): Control {\n this.metadata = fieldMetadata;\n \n const select = new Select({\n selectedKey: `{${modelName}>${bindingPath}}`,\n enabled: !fieldMetadata.ui?.readOnly,\n forceSelection: false,\n change: (oEvent: any) => {\n const item = oEvent.getParameter(\"selectedItem\");\n const val = item ? item.getKey() : \"\";\n this.publishChange(val);\n this.validate();\n }\n });\n\n if (fieldMetadata.valueHelp && Array.isArray(fieldMetadata.valueHelp)) {\n // Always add the empty placeholder so that 'required' checks can actually fire if the user hasn't made a choice\n select.addItem(new Item({ key: \"\", text: \"--- Select ---\" }));\n \n fieldMetadata.valueHelp.forEach(vh => {\n select.addItem(new Item({ key: vh.key, text: vh.text }));\n });\n }\n\n this.control = select;\n return this.control;\n }\n\n public validate(): boolean {\n if (!this.control || !this.metadata) return true;\n const select = this.control as Select;\n const val = select.getSelectedKey();\n\n if (this.metadata.required && (!val || val.trim() === \"\")) {\n select.setValueState(\"Error\" as any);\n select.setValueStateText(\"Selection is required.\");\n return false;\n }\n\n select.setValueState(\"None\" as any);\n return true;\n }\n\n protected applyState(): void {\n if (this.control && this.metadata) {\n const select = this.control as Select;\n select.setEnabled(!this.metadata.ui?.readOnly);\n }\n }\n}\n"],"mappings":"AAAA,sJAAA,MAKSA,EAAUC,EAAA,cASZ,MAAMC,UAAuBF,EACzBG,OAAOC,EAAkCC,EAAqBC,EAAoB,QACrFC,KAAKC,SAAWJ,EAEhB,MAAMK,EAAS,IAAIC,EAAO,CACtBC,YAAa,IAAIL,KAAaD,KAC9BO,SAAUR,EAAcS,IAAIC,SAC5BC,eAAgB,MAChBC,OAASC,IACL,MAAMC,EAAOD,EAAOE,aAAa,gBACjC,MAAMC,EAAMF,EAAOA,EAAKG,SAAW,GACnCd,KAAKe,cAAcF,GACnBb,KAAKgB,cAIb,GAAInB,EAAcoB,WAAaC,MAAMC,QAAQtB,EAAcoB,WAAY,CAEnEf,EAAOkB,QAAQ,IAAIC,EAAK,CAAEC,IAAK,GAAIC,KAAM,oBAEzC1B,EAAcoB,UAAUO,QAAQC,IAC5BvB,EAAOkB,QAAQ,IAAIC,EAAK,CAAEC,IAAKG,EAAGH,IAAKC,KAAME,EAAGF,SAExD,CAEAvB,KAAK0B,QAAUxB,EACf,OAAOF,KAAK0B,OAChB,CAEOV,WACH,IAAKhB,KAAK0B,UAAY1B,KAAKC,SAAU,OAAO,KAC5C,MAAMC,EAASF,KAAK0B,QACpB,MAAMb,EAAMX,EAAOyB,iBAEnB,GAAI3B,KAAKC,SAAS2B,YAAcf,GAAOA,EAAIgB,SAAW,IAAK,CACvD3B,EAAO4B,cAAc,SACrB5B,EAAO6B,kBAAkB,0BACzB,OAAO,KACX,CAEA7B,EAAO4B,cAAc,QACrB,OAAO,IACX,CAEUE,aACN,GAAIhC,KAAK0B,SAAW1B,KAAKC,SAAU,CAC/B,MAAMC,EAASF,KAAK0B,QACpBxB,EAAO+B,YAAYjC,KAAKC,SAASK,IAAIC,SACzC,CACJ,EACH,IAAA2B,EAAA,CAAAC,WAAA,MAAAD,EAAAvC,iBAAA,OAAAuC,CAAA","ignoreList":[],"sourceRoot":"plugins"}},{"offset":{"line":18,"column":0},"map":{"version":3,"names":["BasePlugin","___BasePlugin","NumberPlugin","render","fieldMetadata","bindingPath","modelName","this","metadata","control","StepInput","value","displayValuePrecision","scale","editable","ui","readOnly","required","change","oEvent","val","getParameter","publishChange","validate","input","getValue","undefined","Number","isNaN","setValueState","setValueStateText","applyState","setEditable","setRequired","__exports","__esModule"],"sources":["NumberPlugin.ts"],"sourcesContent":["/**\n * @file NumberPlugin.ts\n * @description Renders a sap.m.StepInput for numeric data.\n */\n\nimport { BasePlugin } from \"./BasePlugin\";\nimport { IPropertyMetadata } from \"../interfaces/ISchema\";\nimport StepInput from \"sap/m/StepInput\";\nimport Control from \"sap/ui/core/Control\";\n\n/**\n * Handles rendering and logic for numeric inputs.\n */\nexport class NumberPlugin extends BasePlugin {\n public render(fieldMetadata: IPropertyMetadata, bindingPath: string, modelName: string = \"meta\"): Control {\n this.metadata = fieldMetadata;\n\n this.control = new StepInput({\n value: `{${modelName}>${bindingPath}}`,\n displayValuePrecision: fieldMetadata.scale || 0,\n editable: !fieldMetadata.ui?.readOnly,\n required: fieldMetadata.required,\n change: (oEvent: any) => {\n const val = oEvent.getParameter(\"value\");\n this.publishChange(val);\n this.validate();\n }\n });\n\n return this.control;\n }\n\n public validate(): boolean {\n if (!this.control || !this.metadata) return true;\n const input = this.control as StepInput;\n const val = input.getValue();\n\n // StepInput generally defaults to 0 and isn't usually undefined unless unbound or erased\n if (this.metadata.required && (val === null || val === undefined || Number.isNaN(val) || val === \"\")) {\n input.setValueState(\"Error\" as any);\n input.setValueStateText(\"This field is required.\");\n return false;\n }\n\n input.setValueState(\"None\" as any);\n return true;\n }\n\n protected applyState(): void {\n if (this.control && this.metadata) {\n const input = this.control as StepInput;\n input.setEditable(!this.metadata.ui?.readOnly);\n input.setRequired(this.metadata.required);\n }\n }\n}\n"],"mappings":"AAAA,kIAAA,MAKSA,EAAUC,EAAA,cAQZ,MAAMC,UAAqBF,EACvBG,OAAOC,EAAkCC,EAAqBC,EAAoB,QACrFC,KAAKC,SAAWJ,EAEhBG,KAAKE,QAAU,IAAIC,EAAU,CACzBC,MAAO,IAAIL,KAAaD,KACxBO,sBAAuBR,EAAcS,OAAS,EAC9CC,UAAWV,EAAcW,IAAIC,SAC7BC,SAAUb,EAAca,SACxBC,OAASC,IACL,MAAMC,EAAMD,EAAOE,aAAa,SAChCd,KAAKe,cAAcF,GACnBb,KAAKgB,cAIb,OAAOhB,KAAKE,OAChB,CAEOc,WACH,IAAKhB,KAAKE,UAAYF,KAAKC,SAAU,OAAO,KAC5C,MAAMgB,EAAQjB,KAAKE,QACnB,MAAMW,EAAMI,EAAMC,WAGlB,GAAIlB,KAAKC,SAASS,WAAaG,IAAQ,MAAQA,IAAQM,WAAaC,OAAOC,MAAMR,IAAQA,IAAQ,IAAK,CAClGI,EAAMK,cAAc,SACpBL,EAAMM,kBAAkB,2BACxB,OAAO,KACX,CAEAN,EAAMK,cAAc,QACpB,OAAO,IACX,CAEUE,aACN,GAAIxB,KAAKE,SAAWF,KAAKC,SAAU,CAC/B,MAAMgB,EAAQjB,KAAKE,QACnBe,EAAMQ,aAAazB,KAAKC,SAASO,IAAIC,UACrCQ,EAAMS,YAAY1B,KAAKC,SAASS,SACpC,CACJ,EACH,IAAAiB,EAAA,CAAAC,WAAA,MAAAD,EAAAhC,eAAA,OAAAgC,CAAA","ignoreList":[],"sourceRoot":"plugins"}},{"offset":{"line":19,"column":0},"map":{"version":3,"names":["BasePlugin","___BasePlugin","StringPlugin","render","fieldMetadata","bindingPath","modelName","this","metadata","fieldKey","replace","control","Input","value","maxLength","required","showValueHelp","ui","widget","change","oEvent","val","getParameter","publishChange","validate","applyCommonDirectives","input","getValue","trim","setValueState","setValueStateText","applyState","setEditable","readOnly","setRequired","__exports","__esModule"],"sources":["StringPlugin.ts"],"sourcesContent":["/**\n * @file StringPlugin.ts\n * @description Renders a sap.m.Input for string data and validates lengths.\n */\n\nimport { BasePlugin } from \"./BasePlugin\";\nimport { IPropertyMetadata } from \"../interfaces/ISchema\";\nimport Input from \"sap/m/Input\";\nimport Control from \"sap/ui/core/Control\";\n\n/**\n * Handles rendering and logic for basic text inputs.\n */\nexport class StringPlugin extends BasePlugin {\n public render(fieldMetadata: IPropertyMetadata, bindingPath: string, modelName: string = \"meta\"): Control {\n this.metadata = fieldMetadata;\n this.fieldKey = bindingPath.replace(\"/\", \"\"); // For EventBus\n \n this.control = new Input({\n value: `{${modelName}>${bindingPath}}`,\n maxLength: fieldMetadata.maxLength || 0,\n required: !!fieldMetadata.required,\n showValueHelp: fieldMetadata.ui?.widget === \"searchHelp\",\n change: (oEvent: any) => {\n const val = oEvent.getParameter(\"value\");\n this.publishChange(val);\n this.validate();\n }\n });\n\n this.applyCommonDirectives(this.control, fieldMetadata, modelName);\n\n return this.control;\n }\n\n public validate(): boolean {\n if (!this.control || !this.metadata) return true;\n const input = this.control as Input;\n const val = input.getValue();\n\n if (this.metadata.required && (!val || typeof val !== 'string' || val.trim() === \"\")) {\n input.setValueState(\"Error\" as any);\n input.setValueStateText(\"This field is required.\");\n return false;\n }\n\n input.setValueState(\"None\" as any);\n return true;\n }\n\n protected applyState(): void {\n if (this.control && this.metadata) {\n const input = this.control as Input;\n input.setEditable(!this.metadata.ui?.readOnly);\n input.setRequired(this.metadata.required);\n }\n }\n}\n"],"mappings":"AAAA,8HAAA,MAKSA,EAAUC,EAAA,cAQZ,MAAMC,UAAqBF,EACvBG,OAAOC,EAAkCC,EAAqBC,EAAoB,QACrFC,KAAKC,SAAWJ,EAChBG,KAAKE,SAAWJ,EAAYK,QAAQ,IAAK,IAEzCH,KAAKI,QAAU,IAAIC,EAAM,CACrBC,MAAO,IAAIP,KAAaD,KACxBS,UAAWV,EAAcU,WAAa,EACtCC,WAAYX,EAAcW,SAC1BC,cAAeZ,EAAca,IAAIC,SAAW,aAC5CC,OAASC,IACL,MAAMC,EAAMD,EAAOE,aAAa,SAChCf,KAAKgB,cAAcF,GACnBd,KAAKiB,cAIbjB,KAAKkB,sBAAsBlB,KAAKI,QAASP,EAAeE,GAExD,OAAOC,KAAKI,OAChB,CAEOa,WACH,IAAKjB,KAAKI,UAAYJ,KAAKC,SAAU,OAAO,KAC5C,MAAMkB,EAAQnB,KAAKI,QACnB,MAAMU,EAAMK,EAAMC,WAElB,GAAIpB,KAAKC,SAASO,YAAcM,UAAcA,IAAQ,UAAYA,EAAIO,SAAW,IAAK,CAClFF,EAAMG,cAAc,SACpBH,EAAMI,kBAAkB,2BACxB,OAAO,KACX,CAEAJ,EAAMG,cAAc,QACpB,OAAO,IACX,CAEUE,aACN,GAAIxB,KAAKI,SAAWJ,KAAKC,SAAU,CAC/B,MAAMkB,EAAQnB,KAAKI,QACnBe,EAAMM,aAAazB,KAAKC,SAASS,IAAIgB,UACrCP,EAAMQ,YAAY3B,KAAKC,SAASO,SACpC,CACJ,EACH,IAAAoB,EAAA,CAAAC,WAAA,MAAAD,EAAAjC,eAAA,OAAAiC,CAAA","ignoreList":[],"sourceRoot":"plugins"}},{"offset":{"line":20,"column":0},"map":{"version":3,"names":["BasePlugin","___BasePlugin","SwitchPlugin","render","fieldMetadata","bindingPath","modelName","this","metadata","control","Switch","state","enabled","ui","readOnly","change","oEvent","val","getParameter","publishChange","validate","applyState","sw","setEnabled","__exports","__esModule"],"sources":["SwitchPlugin.ts"],"sourcesContent":["/**\n * @file SwitchPlugin.ts\n * @description Renders a sap.m.Switch for boolean data specifically marked with the switch widget.\n */\n\nimport { BasePlugin } from \"./BasePlugin\";\nimport { IPropertyMetadata } from \"../interfaces/ISchema\";\nimport Switch from \"sap/m/Switch\";\nimport Control from \"sap/ui/core/Control\";\n\n/**\n * Handles rendering logic for toggleable boolean switches.\n */\nexport class SwitchPlugin extends BasePlugin {\n public render(fieldMetadata: IPropertyMetadata, bindingPath: string, modelName: string = \"meta\"): Control {\n this.metadata = fieldMetadata;\n\n this.control = new Switch({\n state: `{${modelName}>${bindingPath}}`,\n enabled: !fieldMetadata.ui?.readOnly,\n change: (oEvent: any) => {\n const val = oEvent.getParameter(\"state\");\n this.publishChange(val);\n this.validate();\n }\n });\n\n return this.control;\n }\n\n public validate(): boolean {\n // Boolean states rarely fail validation.\n return true;\n }\n\n protected applyState(): void {\n if (this.control && this.metadata) {\n const sw = this.control as Switch;\n sw.setEnabled(!this.metadata.ui?.readOnly);\n }\n }\n}\n"],"mappings":"AAAA,+HAAA,MAKSA,EAAUC,EAAA,cAQZ,MAAMC,UAAqBF,EACvBG,OAAOC,EAAkCC,EAAqBC,EAAoB,QACrFC,KAAKC,SAAWJ,EAEhBG,KAAKE,QAAU,IAAIC,EAAO,CACtBC,MAAO,IAAIL,KAAaD,KACxBO,SAAUR,EAAcS,IAAIC,SAC5BC,OAASC,IACL,MAAMC,EAAMD,EAAOE,aAAa,SAChCX,KAAKY,cAAcF,GACnBV,KAAKa,cAIb,OAAOb,KAAKE,OAChB,CAEOW,WAEH,OAAO,IACX,CAEUC,aACN,GAAId,KAAKE,SAAWF,KAAKC,SAAU,CAC/B,MAAMc,EAAKf,KAAKE,QAChBa,EAAGC,YAAYhB,KAAKC,SAASK,IAAIC,SACrC,CACJ,EACH,IAAAU,EAAA,CAAAC,WAAA,MAAAD,EAAAtB,eAAA,OAAAsB,CAAA","ignoreList":[],"sourceRoot":"plugins"}},{"offset":{"line":21,"column":0},"map":{"version":3,"names":["BasePlugin","___BasePlugin","TextAreaPlugin","render","fieldMetadata","bindingPath","modelName","this","metadata","fieldKey","replace","control","TextArea","value","maxLength","required","rows","ui","change","oEvent","val","getParameter","publishChange","validate","applyCommonDirectives","input","getValue","trim","setValueState","setValueStateText","applyState","setEditable","readOnly","setRequired","__exports","__esModule"],"sources":["TextAreaPlugin.ts"],"sourcesContent":["/**\n * @file TextAreaPlugin.ts\n * @description Renders a sap.m.TextArea for string data specifically marked with the textArea widget.\n */\n\nimport { BasePlugin } from \"./BasePlugin\";\nimport { IPropertyMetadata } from \"../interfaces/ISchema\";\nimport TextArea from \"sap/m/TextArea\";\nimport Control from \"sap/ui/core/Control\";\n\n/**\n * Handles rendering and logic for multi-line text areas.\n */\nexport class TextAreaPlugin extends BasePlugin {\n public render(fieldMetadata: IPropertyMetadata, bindingPath: string, modelName: string = \"meta\"): Control {\n this.metadata = fieldMetadata;\n this.fieldKey = bindingPath.replace(\"/\", \"\"); // For EventBus\n \n this.control = new TextArea({\n value: `{${modelName}>${bindingPath}}`,\n maxLength: fieldMetadata.maxLength || 0,\n required: !!fieldMetadata.required,\n rows: fieldMetadata.ui?.rows || 4, // Default to 4 rows for text areas\n change: (oEvent: any) => {\n const val = oEvent.getParameter(\"value\");\n this.publishChange(val);\n this.validate();\n }\n });\n\n this.applyCommonDirectives(this.control, fieldMetadata, modelName);\n\n return this.control;\n }\n\n public validate(): boolean {\n if (!this.control || !this.metadata) return true;\n const input = this.control as TextArea;\n const val = input.getValue();\n\n if (this.metadata.required && (!val || typeof val !== 'string' || val.trim() === \"\")) {\n input.setValueState(\"Error\" as any);\n input.setValueStateText(\"This field is required.\");\n return false;\n }\n\n input.setValueState(\"None\" as any);\n return true;\n }\n\n protected applyState(): void {\n if (this.control && this.metadata) {\n const input = this.control as TextArea;\n input.setEditable(!this.metadata.ui?.readOnly);\n input.setRequired(this.metadata.required);\n }\n }\n}\n"],"mappings":"AAAA,mIAAA,MAKSA,EAAUC,EAAA,cAQZ,MAAMC,UAAuBF,EACzBG,OAAOC,EAAkCC,EAAqBC,EAAoB,QACrFC,KAAKC,SAAWJ,EAChBG,KAAKE,SAAWJ,EAAYK,QAAQ,IAAK,IAEzCH,KAAKI,QAAU,IAAIC,EAAS,CACxBC,MAAO,IAAIP,KAAaD,KACxBS,UAAWV,EAAcU,WAAa,EACtCC,WAAYX,EAAcW,SAC1BC,KAAMZ,EAAca,IAAID,MAAQ,EAChCE,OAASC,IACL,MAAMC,EAAMD,EAAOE,aAAa,SAChCd,KAAKe,cAAcF,GACnBb,KAAKgB,cAIbhB,KAAKiB,sBAAsBjB,KAAKI,QAASP,EAAeE,GAExD,OAAOC,KAAKI,OAChB,CAEOY,WACH,IAAKhB,KAAKI,UAAYJ,KAAKC,SAAU,OAAO,KAC5C,MAAMiB,EAAQlB,KAAKI,QACnB,MAAMS,EAAMK,EAAMC,WAElB,GAAInB,KAAKC,SAASO,YAAcK,UAAcA,IAAQ,UAAYA,EAAIO,SAAW,IAAK,CAClFF,EAAMG,cAAc,SACpBH,EAAMI,kBAAkB,2BACxB,OAAO,KACX,CAEAJ,EAAMG,cAAc,QACpB,OAAO,IACX,CAEUE,aACN,GAAIvB,KAAKI,SAAWJ,KAAKC,SAAU,CAC/B,MAAMiB,EAAQlB,KAAKI,QACnBc,EAAMM,aAAaxB,KAAKC,SAASS,IAAIe,UACrCP,EAAMQ,YAAY1B,KAAKC,SAASO,SACpC,CACJ,EACH,IAAAmB,EAAA,CAAAC,WAAA,MAAAD,EAAAhC,iBAAA,OAAAgC,CAAA","ignoreList":[],"sourceRoot":"plugins"}},{"offset":{"line":22,"column":0},"map":{"version":3,"names":["BasePlugin","___BasePlugin","TimePlugin","render","fieldMetadata","bindingPath","modelName","this","metadata","control","TimePicker","value","path","type","formatOptions","source","pattern","displayFormat","editable","ui","readOnly","required","change","oEvent","val","getParameter","publishChange","validate","input","isValid","isValidValue","getValue","coreLibrary","sap","require","ValueState","Error","None","trim","setValueState","setValueStateText","applyState","setEditable","setRequired","__exports","__esModule"],"sources":["TimePlugin.ts"],"sourcesContent":["/**\n * @file TimePlugin.ts\n * @description Handles rendering logic for Time strings.\n */\n\nimport { BasePlugin } from \"./BasePlugin\";\nimport { IPropertyMetadata } from \"../interfaces/ISchema\";\nimport TimePicker from \"sap/m/TimePicker\";\nimport Control from \"sap/ui/core/Control\";\n\n/**\n * Handles rendering and logic for time inputs.\n */\nexport class TimePlugin extends BasePlugin {\n public render(fieldMetadata: IPropertyMetadata, bindingPath: string, modelName: string = \"meta\"): Control {\n this.metadata = fieldMetadata;\n \n this.control = new TimePicker({\n value: {\n path: `${modelName}>${bindingPath}`,\n type: \"sap.ui.model.type.Time\",\n formatOptions: {\n source: { pattern: \"HH:mm:ss\" },\n pattern: \"HH:mm:ss\"\n }\n },\n displayFormat: \"HH:mm:ss\",\n editable: !fieldMetadata.ui?.readOnly,\n required: fieldMetadata.required,\n change: (oEvent: any) => {\n const val = oEvent.getParameter(\"value\");\n this.publishChange(val);\n this.validate();\n }\n });\n\n return this.control;\n }\n\n public validate(): boolean {\n if (!this.control || !this.metadata) return true;\n const input = this.control as TimePicker;\n const isValid = typeof input.isValidValue === \"function\" ? input.isValidValue() : true;\n const val = input.getValue();\n const coreLibrary = sap.ui.require(\"sap/ui/core/library\");\n const ValueState = coreLibrary ? coreLibrary.ValueState : { Error: \"Error\", None: \"None\" };\n\n if (this.metadata.required && (!val || typeof val !== 'string' || val.trim() === \"\")) {\n input.setValueState(ValueState.Error);\n input.setValueStateText(\"This field is required.\");\n return false;\n }\n\n if (val && !isValid) {\n input.setValueState(ValueState.Error);\n input.setValueStateText(\"Invalid time format.\");\n return false;\n }\n\n input.setValueState(ValueState.None);\n return true;\n }\n\n protected applyState(): void {\n if (this.control && this.metadata) {\n const input = this.control as TimePicker;\n input.setEditable(!this.metadata.ui?.readOnly);\n input.setRequired(this.metadata.required);\n }\n }\n}\n"],"mappings":"AAAA,iIAAA,MAKSA,EAAUC,EAAA,cAQZ,MAAMC,UAAmBF,EACrBG,OAAOC,EAAkCC,EAAqBC,EAAoB,QACrFC,KAAKC,SAAWJ,EAEhBG,KAAKE,QAAU,IAAIC,EAAW,CAC1BC,MAAO,CACHC,KAAM,GAAGN,KAAaD,IACtBQ,KAAM,yBACNC,cAAe,CACXC,OAAQ,CAAEC,QAAS,YACnBA,QAAS,aAGjBC,cAAe,WACfC,UAAWd,EAAce,IAAIC,SAC7BC,SAAUjB,EAAciB,SACxBC,OAASC,IACL,MAAMC,EAAMD,EAAOE,aAAa,SAChClB,KAAKmB,cAAcF,GACnBjB,KAAKoB,cAIb,OAAOpB,KAAKE,OAChB,CAEOkB,WACH,IAAKpB,KAAKE,UAAYF,KAAKC,SAAU,OAAO,KAC5C,MAAMoB,EAAQrB,KAAKE,QACnB,MAAMoB,SAAiBD,EAAME,eAAiB,WAAaF,EAAME,eAAiB,KAClF,MAAMN,EAAMI,EAAMG,WAClB,MAAMC,EAAcC,IAAId,GAAGe,QAAQ,uBACnC,MAAMC,EAAaH,EAAcA,EAAYG,WAAa,CAAEC,MAAO,QAASC,KAAM,QAElF,GAAI9B,KAAKC,SAASa,YAAcG,UAAcA,IAAQ,UAAYA,EAAIc,SAAW,IAAK,CAClFV,EAAMW,cAAcJ,EAAWC,OAC/BR,EAAMY,kBAAkB,2BACxB,OAAO,KACX,CAEA,GAAIhB,IAAQK,EAAS,CACjBD,EAAMW,cAAcJ,EAAWC,OAC/BR,EAAMY,kBAAkB,wBACxB,OAAO,KACX,CAEAZ,EAAMW,cAAcJ,EAAWE,MAC/B,OAAO,IACX,CAEUI,aACN,GAAIlC,KAAKE,SAAWF,KAAKC,SAAU,CAC/B,MAAMoB,EAAQrB,KAAKE,QACnBmB,EAAMc,aAAanC,KAAKC,SAASW,IAAIC,UACrCQ,EAAMe,YAAYpC,KAAKC,SAASa,SACpC,CACJ,EACH,IAAAuB,EAAA,CAAAC,WAAA,MAAAD,EAAA1C,aAAA,OAAA0C,CAAA","ignoreList":[],"sourceRoot":"plugins"}},{"offset":{"line":23,"column":0},"map":{"version":3,"names":[],"sources":["library-preload.js?bundle-code-0"],"mappings":"AAAA;AACA","sourcesContent":["sap.ui.require.preload({\n"],"sourceRoot":""}},{"offset":{"line":25,"column":0},"map":{"version":3,"file":"IEventBus.js","names":[],"sources":[],"mappings":"AAAA","ignoreList":[],"sourceRoot":"interfaces"}},{"offset":{"line":28,"column":0},"map":{"version":3,"file":"ILayoutManager.js","names":[],"sources":[],"mappings":"AAAA","ignoreList":[],"sourceRoot":"interfaces"}},{"offset":{"line":31,"column":0},"map":{"version":3,"file":"IPlugin.js","names":[],"sources":[],"mappings":"AAAA","ignoreList":[],"sourceRoot":"interfaces"}},{"offset":{"line":34,"column":0},"map":{"version":3,"file":"ISchema.js","names":[],"sources":[],"mappings":"AAAA","ignoreList":[],"sourceRoot":"interfaces"}}]}
|
|
1
|
+
{"version":3,"file":"library-preload.js","sections":[{"offset":{"line":1,"column":0},"map":{"version":3,"names":["BaseHardwareControlRenderer","_interopRequireDefault","__BaseHardwareControlRenderer","BaseHardwareControl","Control","extend","renderer","metadata","properties","value","type","defaultValue","schemaMetadata","readOnly","aggregations","_content","multiple","visibility","events","capture","parameters","setValueAndFire","_setValueAndFire","val","this","setProperty","fireEvent","renderContent","_renderContent","rm","control"],"sources":["BaseHardwareControl.ts"],"sourcesContent":["/**\n * @file BaseHardwareControl.ts\n * @description Foundational UI5 Custom Control for hardware plugins.\n * Exposes a standard 'value' property for pure two-way data binding.\n * \n */\n\nimport Control from \"sap/ui/core/Control\";\nimport RenderManager from \"sap/ui/core/RenderManager\";\nimport { IPropertyMetadata } from \"../../interfaces/ISchema\";\nimport BaseHardwareControlRenderer from \"./BaseHardwareControlRenderer\";\n\n/**\n * @namespace nz.co.siliconst.ui5.metaui.controls\n */\nexport default class BaseHardwareControl extends Control {\n static readonly metadata = {\n properties: {\n /** The raw data value. Two-way bound to the model. */\n value: { type: \"any\", defaultValue: null },\n /** The schema metadata for rendering dynamic hints (like labels/readOnly) */\n schemaMetadata: { type: \"object\", defaultValue: null },\n /** Indicates if the control should be in a read-only state */\n readOnly: { type: \"boolean\", defaultValue: false }\n },\n aggregations: {\n _content: { type: \"sap.m.VBox\", multiple: false, visibility: \"hidden\" }\n },\n events: {\n /** Fired when the hardware successfully captures a value */\n capture: {\n parameters: {\n value: { type: \"any\" }\n }\n }\n }\n };\n\n /**\n * Updates the bound value and fires the capture event.\n */\n protected setValueAndFire(val: unknown): void {\n this.setProperty(\"value\", val, true); // true to suppress re-rendering if desired, but we want the binding to update\n this.fireEvent(\"capture\", { value: val });\n }\n\n /**\n * Common renderer for all hardware controls\n */\n static readonly renderer = BaseHardwareControlRenderer;\n\n /**\n * Abstract hook for subclasses to render their specific DOM/Controls.\n */\n protected renderContent(rm: RenderManager, control: BaseHardwareControl): void {\n // To be overridden by hardware implementations\n }\n}\n"],"mappings":"AAAA,sPAUOA,EAA2BC,EAAAC,GAElC,MAGqBC,EAA4BC,EAAOC,OAAA,2DAkCpCC,SAAWN,EAjCXO,SAAW,CACvBC,WAAY,CAERC,MAAO,CAAEC,KAAM,MAAOC,aAAc,MAEpCC,eAAgB,CAAEF,KAAM,SAAUC,aAAc,MAEhDE,SAAU,CAAEH,KAAM,UAAWC,aAAc,QAE/CG,aAAc,CACVC,SAAU,CAAEL,KAAM,aAAcM,SAAU,MAAOC,WAAY,WAEjEC,OAAQ,CAEJC,QAAS,CACLC,WAAY,CACRX,MAAO,CAAEC,KAAM,WASrBW,gBAAe,SAAAC,EAACC,GACtBC,KAAKC,YAAY,QAASF,EAAK,MAC/BC,KAAKE,UAAU,UAAW,CAAEjB,MAAOc,GACvC,EAUUI,cAAa,SAAAC,EAACC,EAAmBC,GACvC,IACH,OAzCgB3B,CAAmB","ignoreList":[],"sourceRoot":"controls"}},{"offset":{"line":2,"column":0},"map":{"version":3,"names":["__exports","apiVersion","render","rm","control","openStart","class","openEnd","content","getAggregation","renderControl","renderContent","close"],"sources":["BaseHardwareControlRenderer.ts"],"sourcesContent":["/**\n * @file BaseHardwareControlRenderer.ts\n * @description Standard renderer for all MetaUI hardware controls.\n * \n * @namespace nz.co.siliconst.ui5.metaui.controls\n */\nimport RenderManager from \"sap/ui/core/RenderManager\";\nimport BaseHardwareControl from \"./BaseHardwareControl\";\n\nexport default {\n apiVersion: 2,\n render: function (rm: RenderManager, control: BaseHardwareControl) {\n rm.openStart(\"div\", control);\n rm.class(\"sapUiSmallMarginBottom\");\n rm.openEnd();\n \n const content = control.getAggregation(\"_content\") as sap.ui.core.Control;\n if (content) {\n rm.renderControl(content);\n }\n \n if (typeof (control as unknown).renderContent === \"function\") {\n (control as unknown).renderContent(rm, control);\n }\n \n rm.close(\"div\");\n }\n};\n"],"mappings":"AAAA,+GAAA,IAAAA,EASe,CACXC,WAAY,EACZC,OAAQ,SAAUC,EAAmBC,GACjCD,EAAGE,UAAU,MAAOD,GACpBD,EAAGG,MAAM,0BACTH,EAAGI,UAEH,MAAMC,EAAUJ,EAAQK,eAAe,YACvC,GAAID,EAAS,CACTL,EAAGO,cAAcF,EACrB,CAEA,UAAYJ,EAAoBO,gBAAkB,WAAY,CACzDP,EAAoBO,cAAcR,EAAIC,EAC3C,CAEAD,EAAGS,MAAM,MACb,GACH,OAAAZ,CAAA","ignoreList":[],"sourceRoot":"controls"}},{"offset":{"line":3,"column":0},"map":{"version":3,"names":["BaseHardwareControl","_interopRequireDefault","__BaseHardwareControl","Logger","___utils_Logger","CameraControl","static","properties","events","videoEl","mediaStream","init","super","this","videoHtml","HTML","content","afterRendering","onVideoRendered","bind","addStyleClass","previewImage","Image","width","visible","startBtn","Button","icon","text","press","handleStartCameraPress","captureBtn","captureImage","retakeBtn","retakeImage","vBox","VBox","items","setAggregation","domRef","getDomRef","val","getValue","startsWith","showPreview","startCamera","setVisible","style","display","navigator","mediaDevices","getUserMedia","video","facingMode","srcObject","err","error","message","MessageToast","show","stopCamera","getTracks","forEach","track","stop","canvas","document","createElement","videoWidth","height","videoHeight","ctx","getContext","drawImage","dataUrl","toDataURL","setValueAndFire","setTimeout","setSrc","setValue","value","getVisible","exit"],"sources":["CameraControl.ts"],"sourcesContent":["import BaseHardwareControl from \"./BaseHardwareControl\";\nimport Button from \"sap/m/Button\";\nimport VBox from \"sap/m/VBox\";\nimport HTML from \"sap/ui/core/HTML\";\nimport MessageToast from \"sap/m/MessageToast\";\nimport Image from \"sap/m/Image\";\nimport { Logger } from \"../utils/Logger\";\n\n/**\n * CameraControl\n * Provides a live video feed to capture photos.\n */\nexport default class CameraControl extends BaseHardwareControl {\n static readonly renderer = \"nz.co.siliconst.ui5.metaui.controls.BaseHardwareControlRenderer\";\n static readonly metadata = {\n properties: {},\n events: {}\n };\n\n private startBtn!: Button;\n private vBox!: VBox;\n private captureBtn!: Button;\n private retakeBtn!: Button;\n private videoHtml!: HTML;\n private previewImage!: Image;\n \n private videoEl: HTMLVideoElement | null = null;\n private mediaStream: MediaStream | null = null;\n\n public init(): void {\n super.init();\n\n this.videoHtml = new HTML({\n content: \"<video width='400' height='300' autoplay playsinline style='background-color: #000; display: none;'></video>\",\n afterRendering: this.onVideoRendered.bind(this)\n }).addStyleClass(\"sapUiSmallMarginBottom\");\n\n this.previewImage = new Image({\n width: \"400px\",\n visible: false\n }).addStyleClass(\"sapUiSmallMarginBottom\");\n\n this.startBtn = new Button({\n icon: \"sap-icon://video\",\n text: \"Start Camera\",\n press: this.handleStartCameraPress.bind(this)\n });\n\n this.captureBtn = new Button({\n icon: \"sap-icon://camera\",\n text: \"Capture\",\n visible: false,\n press: this.captureImage.bind(this)\n });\n\n this.retakeBtn = new Button({\n icon: \"sap-icon://undo\",\n text: \"Retake\",\n visible: false,\n press: this.retakeImage.bind(this)\n });\n\n this.vBox = new VBox({\n items: [this.videoHtml, this.previewImage, this.startBtn, this.captureBtn, this.retakeBtn]\n });\n\n this.setAggregation(\"_content\", this.vBox);\n }\n\n private async onVideoRendered(): void {\n const domRef = this.videoHtml.getDomRef() as HTMLElement;\n if (!domRef) return;\n \n this.videoEl = domRef as HTMLVideoElement;\n \n const val = this.getValue();\n if (val && typeof val === \"string\" && val.startsWith(\"data:image\")) {\n this.showPreview(val);\n }\n }\n\n private handleStartCameraPress(): void {\n this.startCamera();\n this.startBtn.setVisible(false);\n this.captureBtn.setVisible(true);\n if (this.videoEl) {\n this.videoEl.style.display = \"block\";\n }\n }\n\n private async startCamera(): Promise<void> {\n try {\n this.mediaStream = await navigator.mediaDevices.getUserMedia({ video: { facingMode: \"environment\" } });\n if (this.videoEl) {\n this.videoEl.srcObject = this.mediaStream;\n }\n } catch (err) {\n Logger.error(\"Camera access denied or unavailable\", (err as Error).message, \"CameraControl\");\n MessageToast.show(\"Camera access denied or unavailable.\");\n }\n }\n\n private stopCamera(): void {\n if (this.mediaStream) {\n this.mediaStream.getTracks().forEach(track => track.stop());\n this.mediaStream = null;\n }\n }\n\n private captureImage(): void {\n if (!this.videoEl) return;\n \n const canvas = document.createElement(\"canvas\");\n canvas.width = this.videoEl.videoWidth || 400;\n canvas.height = this.videoEl.videoHeight || 300;\n \n const ctx = canvas.getContext(\"2d\");\n if (ctx) {\n ctx.drawImage(this.videoEl, 0, 0, canvas.width, canvas.height);\n const dataUrl = canvas.toDataURL(\"image/jpeg\", 0.8);\n this.setValueAndFire(dataUrl);\n this.showPreview(dataUrl);\n MessageToast.show(\"Image captured successfully.\");\n }\n }\n\n private retakeImage(): void {\n this.setValueAndFire(null);\n this.previewImage.setVisible(false);\n this.videoHtml.setVisible(true);\n this.captureBtn.setVisible(true);\n this.retakeBtn.setVisible(false);\n \n // Use a slight timeout to ensure DOM is ready before accessing stream again\n setTimeout(() => this.startCamera(), 100);\n }\n\n private showPreview(dataUrl: string): void {\n this.stopCamera();\n this.videoHtml.setVisible(false);\n this.previewImage.setSrc(dataUrl);\n this.previewImage.setVisible(true);\n this.captureBtn.setVisible(false);\n this.retakeBtn.setVisible(true);\n }\n\n public setValue(value: any): this {\n super.setValue(value);\n if (value && typeof value === \"string\" && value.startsWith(\"data:image\")) {\n this.showPreview(value);\n } else if (!value) {\n // Only retake if we were showing a preview\n if (this.previewImage.getVisible()) {\n this.retakeImage();\n }\n }\n return this;\n }\n\n public exit(): void {\n this.stopCamera();\n super.exit();\n }\n}\n"],"mappings":"AAAA,gUAAOA,EAAmBC,EAAAC,GAAA,MAMjBC,EAAMC,EAAA,UAMA,MAAMC,UAAsBL,EACvCM,gBAA2B,kEAC3BA,gBAA2B,CACvBC,WAAY,CAAC,EACbC,OAAQ,CAAC,GAULC,QAAmC,KACnCC,YAAkC,KAEnCC,OACHC,MAAMD,OAENE,KAAKC,UAAY,IAAIC,EAAK,CACtBC,QAAS,+GACTC,eAAgBJ,KAAKK,gBAAgBC,KAAKN,QAC3CO,cAAc,0BAEjBP,KAAKQ,aAAe,IAAIC,EAAM,CAC1BC,MAAO,QACPC,QAAS,QACVJ,cAAc,0BAEjBP,KAAKY,SAAW,IAAIC,EAAO,CACvBC,KAAM,mBACNC,KAAM,eACNC,MAAOhB,KAAKiB,uBAAuBX,KAAKN,QAG5CA,KAAKkB,WAAa,IAAIL,EAAO,CACzBC,KAAM,oBACNC,KAAM,UACNJ,QAAS,MACTK,MAAOhB,KAAKmB,aAAab,KAAKN,QAGlCA,KAAKoB,UAAY,IAAIP,EAAO,CACxBC,KAAM,kBACNC,KAAM,SACNJ,QAAS,MACTK,MAAOhB,KAAKqB,YAAYf,KAAKN,QAGjCA,KAAKsB,KAAO,IAAIC,EAAK,CACjBC,MAAO,CAACxB,KAAKC,UAAWD,KAAKQ,aAAcR,KAAKY,SAAUZ,KAAKkB,WAAYlB,KAAKoB,aAGpFpB,KAAKyB,eAAe,WAAYzB,KAAKsB,KACzC,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Q,aAAayB,WAAW,OAC7BjC,KAAKC,UAAUgC,WAAW,MAC1BjC,KAAKkB,WAAWe,WAAW,MAC3BjC,KAAKoB,UAAUa,WAAW,OAG1B+B,WAAW,IAAMhE,KAAKgC,cAAe,IACzC,CAEQD,YAAY8B,GAChB7D,KAAK+C,aACL/C,KAAKC,UAAUgC,WAAW,OAC1BjC,KAAKQ,aAAayD,OAAOJ,GACzB7D,KAAKQ,aAAayB,WAAW,MAC7BjC,KAAKkB,WAAWe,WAAW,OAC3BjC,KAAKoB,UAAUa,WAAW,KAC9B,CAEOiC,SAASC,GACZpE,MAAMmE,SAASC,GACf,GAAIA,UAAgBA,IAAU,UAAYA,EAAMrC,WAAW,cAAe,CACtE9B,KAAK+B,YAAYoC,EACrB,MAAO,IAAKA,EAAO,CAEf,GAAInE,KAAKQ,aAAa4D,aAAc,CAChCpE,KAAKqB,aACT,CACJ,CACA,OAAOrB,IACX,CAEOqE,OACHrE,KAAK+C,aACLhD,MAAMsE,MACV,EACH,OAAA7E,CAAA","ignoreList":[],"sourceRoot":"controls"}},{"offset":{"line":4,"column":0},"map":{"version":3,"names":["GeneratorHost","_interopRequireDefault","__GeneratorHost","Logger","___utils_Logger","ODataDelegate","___host_delegates_ODataDelegate","DynamicHost","Control","extend","constructor","prototype","apply","this","arguments","_innerHost","odataDelegate","_initializedInner","renderer","apiVersion","render","rm","control","openStart","style","openEnd","content","getAggregation","renderControl","close","metadata","properties","schemaDefinition","type","defaultValue","data","bindable","dataJson","liveUpdate","isValid","useMessageManager","modelName","debugMode","displayMode","aggregations","_content","multiple","visibility","events","beforeSubmit","parameters","payload","addError","preventDefault","submit","payloadJson","cancel","fieldChange","fieldPath","value","validationStateChanged","validationError","message","validationSuccess","initODataDelegate","_initODataDelegate","oContext","getBindingContext","debug","getPath","requestObject","getObject","syncToEngine","Object","keys","setBindingContext","_setBindingContext","sModelName","Control.prototype.setBindingContext.call","bindElement","_bindElement","vPath","mParameters","Control.prototype.bindElement.call","model","undefined","oBinding","getElementBinding","attachChange","onBeforeRendering","_onBeforeRendering","schema","getProperty","hasSchema","hasData","props","getMetadata","getProperties","propName","val","Control.prototype.getProperty.call","setProperty","setAggregation","getEvents","eventName","attachEvent","oEvent","params","getParameters","Control.prototype.setProperty.call","str","JSON","stringify","handleFieldChange","fireEvent","_setProperty","propertyName","suppressInvalidate","openInDialog","_openInDialog","title","submitButtonText","cancelButtonText","triggerSubmit","_triggerSubmit","_getProperty"],"sources":["DynamicHost.ts"],"sourcesContent":["import Control from \"sap/ui/core/Control\";\nimport RenderManager from \"sap/ui/core/RenderManager\";\nimport GeneratorHost from \"./host/GeneratorHost\";\nimport { Logger } from \"../utils/Logger\";\nimport { ODataDelegate } from \"./host/delegates/ODataDelegate\";\n\n/**\n * A transparent wrapper control (Facade) that automatically chooses between Explicit Schema Mode \n * and Inference Mode based on the presence of a 'schemaDefinition'.\n * \n * This maintains total architectural separation of the modes without forcing developers to \n * use different XML tags.\n * \n * @namespace nz.co.siliconst.ui5.metaui.controls\n */\nexport default class DynamicHost extends Control {\n private _innerHost: GeneratorHost | null = null;\n private odataDelegate: ODataDelegate | null = null;\n private _initializedInner: boolean = false;\n\n static readonly metadata = {\n properties: {\n schemaDefinition: { type: \"any\", defaultValue: null },\n data: { type: \"object\", defaultValue: null, bindable: \"bindable\" },\n dataJson: { type: \"string\", defaultValue: null, bindable: \"bindable\" },\n liveUpdate: { type: \"boolean\", defaultValue: false },\n isValid: { type: \"boolean\", defaultValue: true },\n useMessageManager: { type: \"boolean\", defaultValue: false },\n modelName: { type: \"string\", defaultValue: \"meta\" },\n debugMode: { type: \"boolean\", defaultValue: false },\n displayMode: { type: \"boolean\", defaultValue: false }\n },\n aggregations: {\n _content: { type: \"sap.ui.core.Control\", multiple: false, visibility: \"hidden\" }\n },\n events: {\n beforeSubmit: {\n parameters: {\n payload: { type: \"object\" },\n addError: { type: \"function\" },\n preventDefault: { type: \"function\" }\n }\n },\n submit: {\n parameters: {\n payload: { type: \"object\" },\n payloadJson: { type: \"string\" }\n }\n },\n cancel: {},\n fieldChange: {\n parameters: {\n fieldPath: { type: \"string\" },\n value: { type: \"any\" },\n payload: { type: \"object\" },\n isValid: { type: \"boolean\" }\n }\n },\n validationStateChanged: { parameters: { isValid: { type: \"boolean\" } } },\n validationError: { parameters: { fieldPath: { type: \"string\" }, message: { type: \"string\" } } },\n validationSuccess: { parameters: { fieldPath: { type: \"string\" } } }\n }\n };\n\n static renderer = {\n apiVersion: 2,\n render(rm: RenderManager, control: DynamicHost) {\n rm.openStart(\"div\", control);\n rm.style(\"width\", \"100%\");\n rm.style(\"height\", \"100%\");\n rm.openEnd();\n\n const content = control.getAggregation(\"_content\") as Control;\n if (content) {\n rm.renderControl(content);\n }\n\n rm.close(\"div\");\n }\n };\n\n private _innerHost: GeneratorHost | null = null;\n private _initializedInner: boolean = false;\n\n /**\n * Standard UI5 Lifecycle Hook.\n * Evaluates the initial properties and spawns the appropriate inner host strategy via the HostFactory.\n * It handles the complex lifecycle task of copying all bindings, raw properties, and event listeners \n * down to the inner host perfectly transparently.\n */\n private initODataDelegate(): void {\n if (!this.odataDelegate) {\n const oContext = this.getBindingContext(\"odata\") || this.getBindingContext();\n if (oContext) {\n Logger.debug(\"[MetaUI DynamicHost]\", `Context found for delegate initialization: ${oContext.getPath()}`, \"DynamicHost\");\n if (typeof (oContext as any).requestObject === \"function\" || typeof (oContext as any).getObject === \"function\") {\n Logger.debug(\"[MetaUI DynamicHost]\", `Context supports requestObject/getObject. Instantiating ODataDelegate.`, \"DynamicHost\");\n this.odataDelegate = new ODataDelegate(this, oContext as any);\n this.odataDelegate.syncToEngine();\n } else {\n Logger.debug(\"[MetaUI DynamicHost]\", `Context does NOT support requestObject/getObject! Keys: ${Object.keys(oContext)}`, \"DynamicHost\");\n }\n }\n }\n }\n\n public setBindingContext(oContext: sap.ui.model.Context | null | undefined, sModelName?: string): this {\n super.setBindingContext(oContext, sModelName);\n this.initODataDelegate();\n return this;\n }\n\n public bindElement(vPath: string | any, mParameters?: object): this {\n super.bindElement(vPath, mParameters);\n const sModelName = typeof vPath === \"object\" ? vPath.model : undefined;\n const oBinding = this.getElementBinding(sModelName);\n if (oBinding) {\n oBinding.attachChange(() => {\n this.initODataDelegate();\n });\n }\n return this;\n }\n\n public onBeforeRendering(): void {\n Logger.debug(\"[MetaUI DynamicHost]\", `onBeforeRendering called. _initializedInner: ${this._initializedInner}`, \"DynamicHost\");\n\n this.initODataDelegate();\n\n if (!this._initializedInner) {\n const schema = this.getProperty(\"schemaDefinition\");\n const dataJson = this.getProperty(\"dataJson\");\n const data = this.getProperty(\"data\");\n\n const hasSchema = !!schema;\n const hasData = !!dataJson || !!data;\n\n Logger.debug(\"[MetaUI DynamicHost]\", `Evaluating boot. hasSchema: ${hasSchema}, hasData: ${hasData}`, \"DynamicHost\");\n\n // Only boot if we have either a schema or some data to infer from\n if (hasSchema || hasData) {\n if (this.getProperty(\"debugMode\")) {\n Logger.debug(\"[MetaUI DynamicHost]\", `Booting inner host. hasSchema: ${hasSchema}, hasData: ${hasData}`, \"DynamicHost\");\n }\n // The architectural Facade router logic:\n // We've simplified this! We no longer use HostFactory or separate subclasses.\n // GeneratorHost is fully capable of inferring the schema if none is provided.\n this._innerHost = new GeneratorHost();\n\n // 1. Forward all static values to the spawned host BEFORE mounting.\n // Since we no longer use bindProperty, it's perfectly safe to set raw properties before mounting.\n const props = this.getMetadata().getProperties();\n for (const propName in props) {\n const val = super.getProperty(propName);\n if (val !== null && val !== undefined) {\n this._innerHost.setProperty(propName, val);\n }\n }\n\n // 2. Mount so it inherits models and triggers lifecycle.\n this.setAggregation(\"_content\", this._innerHost);\n\n // 3. Forward all event subscriptions.\n // By proxying the events upwards, the developer can subscribe to `<meta:DynamicHost submit=\"...\">` \n // and perfectly receive the inner host's submission event.\n const events = this.getMetadata().getEvents();\n for (const eventName in events) {\n this._innerHost.attachEvent(eventName, (oEvent: any) => {\n // Natively push updated payload out to any bound Fiori Element properties.\n // Using super.setProperty prevents an infinite loop back down to _innerHost.\n if (eventName === \"submit\" || eventName === \"fieldChange\") {\n const params = oEvent.getParameters();\n if (params.payload) {\n super.setProperty(\"data\", params.payload, true);\n\n const str = params.payloadJson || JSON.stringify(params.payload, null, 2);\n super.setProperty(\"dataJson\", str, true);\n }\n if (eventName === \"fieldChange\" && this.odataDelegate) {\n this.odataDelegate.handleFieldChange(params.fieldPath, params.value);\n }\n }\n this.fireEvent(eventName, oEvent.getParameters());\n });\n }\n\n this._initializedInner = true;\n }\n }\n }\n\n /**\n * Overrides standard UI5 setProperty to act as a transparent proxy.\n * When a property is updated on the wrapper (either programmatically or via a binding update),\n * it instantly mirrors that value down to the inner instantiated host.\n */\n public setProperty(propertyName: string, value: unknown, suppressInvalidate?: boolean): this {\n if (propertyName === \"data\" || propertyName === \"dataJson\" || propertyName === \"schemaDefinition\") {\n if (this.getProperty(\"debugMode\")) {\n Logger.debug(\"[MetaUI DynamicHost]\", `Wrapper received setProperty: ${propertyName}`, \"DynamicHost\");\n }\n }\n super.setProperty(propertyName, value, suppressInvalidate);\n if (this._innerHost) {\n this._innerHost.setProperty(propertyName, value, suppressInvalidate);\n } else if (propertyName === \"data\" || propertyName === \"dataJson\" || propertyName === \"schemaDefinition\") {\n if (this.getProperty(\"debugMode\")) {\n Logger.debug(\"[MetaUI DynamicHost]\", `_innerHost not yet initialized when ${propertyName} was set. Booting will happen on next render.`, \"DynamicHost\");\n }\n }\n return this;\n }\n\n\n\n\n\n /**\n * Programmatic API support. Routes dialog commands down to the spawned inner host.\n */\n public openInDialog(title?: string, submitButtonText?: string, cancelButtonText?: string): void {\n if (!this._innerHost) {\n this.onBeforeRendering(); // Force init if they bypassed UI5 rendering\n }\n this._innerHost?.openInDialog(title, submitButtonText, cancelButtonText);\n }\n\n /**\n * Proxies submission triggering down to the instantiated generator host.\n */\n public triggerSubmit(): boolean {\n if (!this._innerHost) {\n return false;\n }\n return (this._innerHost as any).triggerSubmit();\n }\n\n /**\n * Overrides standard UI5 getProperty to transparently pull extracted data from the inner host.\n */\n public getProperty(propertyName: string): any {\n if (this._innerHost && (propertyName === \"data\" || propertyName === \"dataJson\")) {\n return this._innerHost.getProperty(propertyName);\n }\n return super.getProperty(propertyName);\n }\n}\n"],"mappings":"AAAA,4RAEOA,EAAaC,EAAAC,GAAA,MACXC,EAAMC,EAAA,gBACNC,EAAaC,EAAA,iBAEtB,MASqBC,EAAoBC,EAAOC,OAAA,mDAAAC,YAAA,SAAAA,IAAAF,EAAAG,UAAAD,YAAAE,MAAAC,KAAAC,WAAAD,KACpCE,WAAmC,KAAIF,KACvCG,cAAsC,KAAIH,KAC1CI,kBAA6B,MAAKJ,KA+DlCE,WAAmC,KAAIF,KACvCI,kBAA6B,KAAK,EAlBnCC,SAAW,CACdC,WAAY,EACZC,OAAOC,EAAmBC,GACtBD,EAAGE,UAAU,MAAOD,GACpBD,EAAGG,MAAM,QAAS,QAClBH,EAAGG,MAAM,SAAU,QACnBH,EAAGI,UAEH,MAAMC,EAAUJ,EAAQK,eAAe,YACvC,GAAID,EAAS,CACTL,EAAGO,cAAcF,EACrB,CAEAL,EAAGQ,MAAM,MACb,GA1DYC,SAAW,CACvBC,WAAY,CACRC,iBAAkB,CAAEC,KAAM,MAAOC,aAAc,MAC/CC,KAAM,CAAEF,KAAM,SAAUC,aAAc,KAAME,SAAU,YACtDC,SAAU,CAAEJ,KAAM,SAAUC,aAAc,KAAME,SAAU,YAC1DE,WAAY,CAAEL,KAAM,UAAWC,aAAc,OAC7CK,QAAS,CAAEN,KAAM,UAAWC,aAAc,MAC1CM,kBAAmB,CAAEP,KAAM,UAAWC,aAAc,OACpDO,UAAW,CAAER,KAAM,SAAUC,aAAc,QAC3CQ,UAAW,CAAET,KAAM,UAAWC,aAAc,OAC5CS,YAAa,CAAEV,KAAM,UAAWC,aAAc,QAElDU,aAAc,CACVC,SAAU,CAAEZ,KAAM,sBAAuBa,SAAU,MAAOC,WAAY,WAE1EC,OAAQ,CACJC,aAAc,CACVC,WAAY,CACRC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AAc,eAAiB3F,KAAKG,cAAe,CACnDH,KAAKG,cAAciG,kBAAkBN,EAAOjD,UAAWiD,EAAOhD,MAClE,CACJ,CACA9C,KAAKqG,UAAUV,EAAWE,EAAOE,kBAEzC,CAEA/F,KAAKI,kBAAoB,IAC7B,CACJ,CACJ,EAOOoF,YAAW,SAAAc,EAACC,EAAsBzD,EAAgB0D,GACrD,GAAID,IAAiB,QAAUA,IAAiB,YAAcA,IAAiB,mBAAoB,CAC/F,GAAIvG,KAAK+E,YAAY,aAAc,CAC/BzF,EAAOiE,MAAM,uBAAwB,iCAAiCgD,IAAgB,cAC1F,CACJ,CACAP,6BAAAhG,KAAkBuG,EAAczD,EAAO0D,GACvC,GAAIxG,KAAKE,WAAY,CACjBF,KAAKE,WAAWsF,YAAYe,EAAczD,EAAO0D,EACrD,MAAO,GAAID,IAAiB,QAAUA,IAAiB,YAAcA,IAAiB,mBAAoB,CACtG,GAAIvG,KAAK+E,YAAY,aAAc,CAC/BzF,EAAOiE,MAAM,uBAAwB,uCAAuCgD,iDAA6D,cAC7I,CACJ,CACA,OAAOvG,IACX,EASOyG,aAAY,SAAAC,EAACC,EAAgBC,EAA2BC,GAC3D,IAAK7G,KAAKE,WAAY,CAClBF,KAAK4E,mBACT,CACA5E,KAAKE,YAAYuG,aAAaE,EAAOC,EAAkBC,EAC3D,EAKOC,cAAa,SAAAC,IAChB,IAAK/G,KAAKE,WAAY,CAClB,OAAO,KACX,CACA,OAAQF,KAAKE,WAAmB4G,eACpC,EAKO/B,YAAW,SAAAiC,EAACT,GACf,GAAIvG,KAAKE,aAAeqG,IAAiB,QAAUA,IAAiB,YAAa,CAC7E,OAAOvG,KAAKE,WAAW6E,YAAYwB,EACvC,CACA,OAAAhB,6BAAAvF,KAAyBuG,EAC7B,IAAC,OAtOgB7G,CAAW","ignoreList":[],"sourceRoot":"controls"}},{"offset":{"line":5,"column":0},"map":{"version":3,"names":["BaseHardwareControl","_interopRequireDefault","__BaseHardwareControl","BaseHardwareControlRenderer","__BaseHardwareControlRenderer","GeolocationControl","static","aggregations","_content","type","multiple","visibility","init","super","this","locationBtn","Button","icon","text","press","getLocation","bind","resultInput","Input","editable","visible","vBox","VBox","items","setAggregation","onBeforeRendering","metadata","getProperty","ui","label","setText","readOnly","setEnabled","currentVal","setValue","setVisible","navigator","geolocation","MessageToast","show","getCurrentPosition","position","locStr","coords","latitude","longitude","setValueAndFire"],"sources":["GeolocationControl.ts"],"sourcesContent":["/**\n * @file GeolocationControl.ts\n * @description Native UI5 Control for GPS capture.\n * \n * @namespace nz.co.siliconst.ui5.metaui.controls\n */\nimport BaseHardwareControl from \"./BaseHardwareControl\";\nimport BaseHardwareControlRenderer from \"./BaseHardwareControlRenderer\";\nimport RenderManager from \"sap/ui/core/RenderManager\";\nimport Button from \"sap/m/Button\";\nimport Input from \"sap/m/Input\";\nimport VBox from \"sap/m/VBox\";\nimport MessageToast from \"sap/m/MessageToast\";\n\nexport default class GeolocationControl extends BaseHardwareControl {\n private vBox: VBox;\n private locationBtn: Button;\n private resultInput: Input;\n\n static readonly renderer = BaseHardwareControlRenderer;\n\n static readonly metadata = {\n aggregations: {\n _content: { type: \"sap.m.VBox\", multiple: false, visibility: \"hidden\" }\n }\n };\n\n public init(): void {\n super.init();\n\n this.locationBtn = new Button({\n icon: \"sap-icon://map\",\n text: \"Get Location\",\n press: this.getLocation.bind(this)\n });\n\n this.resultInput = new Input({\n editable: false,\n visible: false\n });\n\n this.vBox = new VBox({\n items: [this.locationBtn, this.resultInput]\n });\n\n this.setAggregation(\"_content\", this.vBox);\n }\n\n public onBeforeRendering(): void {\n const metadata = this.getProperty(\"schemaMetadata\");\n if (metadata && metadata.ui && metadata.ui.label) {\n this.locationBtn.setText(metadata.ui.label);\n }\n\n const readOnly = this.getProperty(\"readOnly\");\n this.locationBtn.setEnabled(!readOnly);\n\n const currentVal = this.getProperty(\"value\");\n if (currentVal) {\n this.resultInput.setValue(currentVal as string);\n this.resultInput.setVisible(true);\n }\n }\n\n private getLocation(): void {\n if (!navigator.geolocation) {\n MessageToast.show(\"Geolocation is not supported by your browser\");\n return;\n }\n\n navigator.geolocation.getCurrentPosition(\n (position) => {\n const locStr = `${position.coords.latitude}, ${position.coords.longitude}`;\n this.resultInput.setValue(locStr);\n this.resultInput.setVisible(true);\n this.setValueAndFire(locStr);\n MessageToast.show(\"Location acquired.\");\n },\n () => {\n MessageToast.show(\"Unable to retrieve your location\");\n }\n );\n }\n\n\n}\n"],"mappings":"AAAA,wTAAA,MAMOA,EAAmBC,EAAAC,GAAA,MACnBC,EAA2BF,EAAAG,GAOnB,MAAMC,UAA2BL,EAK5CM,gBAA2BH,EAE3BG,gBAA2B,CACvBC,aAAc,CACVC,SAAU,CAAEC,KAAM,aAAcC,SAAU,MAAOC,WAAY,YAI9DC,OACHC,MAAMD,OAENE,KAAKC,YAAc,IAAIC,EAAO,CAC1BC,KAAM,iBACNC,KAAM,eACNC,MAAOL,KAAKM,YAAYC,KAAKP,QAGjCA,KAAKQ,YAAc,IAAIC,EAAM,CACzBC,SAAU,MACVC,QAAS,QAGbX,KAAKY,KAAO,IAAIC,EAAK,CACjBC,MAAO,CAACd,KAAKC,YAAaD,KAAKQ,eAGnCR,KAAKe,eAAe,WAAYf,KAAKY,KACzC,CAEOI,oBACH,MAAMC,EAAWjB,KAAKkB,YAAY,kBAClC,GAAID,GAAYA,EAASE,IAAMF,EAASE,GAAGC,MAAO,CAC9CpB,KAAKC,YAAYoB,QAAQJ,EAASE,GAAGC,MACzC,CAEA,MAAME,EAAWtB,KAAKkB,YAAY,YAClClB,KAAKC,YAAYsB,YAAYD,GAE7B,MAAME,EAAaxB,KAAKkB,YAAY,SACpC,GAAIM,EAAY,CACZxB,KAAKQ,YAAYiB,SAASD,GAC1BxB,KAAKQ,YAAYkB,WAAW,KAChC,CACJ,CAEQpB,cACJ,IAAKqB,UAAUC,YAAa,CACxBC,EAAaC,KAAK,gDAClB,MACJ,CAEAH,UAAUC,YAAYG,mBACjBC,IACG,MAAMC,EAAS,GAAGD,EAASE,OAAOC,aAAaH,EAASE,OAAOE,YAC/DpC,KAAKQ,YAAYiB,SAASQ,GAC1BjC,KAAKQ,YAAYkB,WAAW,MAC5B1B,KAAKqC,gBAAgBJ,GACrBJ,EAAaC,KAAK,uBAEtB,KACID,EAAaC,KAAK,qCAG9B,EAGH,OAAAvC,CAAA","ignoreList":[],"sourceRoot":"controls"}},{"offset":{"line":6,"column":0},"map":{"version":3,"names":["BaseHardwareControl","_interopRequireDefault","__BaseHardwareControl","BaseHardwareControlRenderer","__BaseHardwareControlRenderer","RichTextControl","extend","metadata","properties","events","aggregations","_content","type","multiple","visibility","renderer","init","_init","BaseHardwareControl.prototype.init.call","this","richTextEditor","RichTextEditor","width","height","showGroupFont","showGroupInsert","tooltip","change","oEvent","val","getParameter","setValueAndFire","vBox","VBox","items","setAggregation","onBeforeRendering","_onBeforeRendering","readOnly","getProperty","setEditable","currentVal","undefined","getValue","setValue"],"sources":["RichTextControl.ts"],"sourcesContent":["import BaseHardwareControl from \"./BaseHardwareControl\";\nimport BaseHardwareControlRenderer from \"./BaseHardwareControlRenderer\";\nimport RenderManager from \"sap/ui/core/RenderManager\";\nimport VBox from \"sap/m/VBox\";\nimport RichTextEditor from \"sap/ui/richtexteditor/RichTextEditor\";\n\n/**\n * @file RichTextControl.ts\n * @description Native UI5 Control for rich text input.\n * \n * @namespace nz.co.siliconst.ui5.metaui.controls\n */\nexport default class RichTextControl extends BaseHardwareControl {\n private vBox!: VBox;\n private richTextEditor!: RichTextEditor;\n\n static readonly renderer = BaseHardwareControlRenderer;\n\n static readonly metadata = {\n properties: {},\n events: {},\n aggregations: {\n _content: { type: \"sap.m.VBox\", multiple: false, visibility: \"hidden\" }\n }\n };\n\n public init(): void {\n super.init();\n\n this.richTextEditor = new RichTextEditor({\n width: \"100%\",\n height: \"300px\",\n showGroupFont: true,\n showGroupInsert: true,\n tooltip: \"Rich Text Editor\",\n change: (oEvent: sap.ui.base.Event) => {\n const val = oEvent.getParameter(\"newValue\");\n this.setValueAndFire(val);\n }\n });\n\n this.vBox = new VBox({\n items: [this.richTextEditor]\n });\n\n this.setAggregation(\"_content\", this.vBox);\n }\n\n public onBeforeRendering(): void {\n const readOnly = this.getProperty(\"readOnly\");\n this.richTextEditor.setEditable(!readOnly);\n\n const currentVal = this.getProperty(\"value\");\n if (currentVal !== undefined && currentVal !== null) {\n // Prevent recursive update if the value matches the editor's current value\n if (this.richTextEditor.getValue() !== currentVal) {\n this.richTextEditor.setValue(currentVal as string);\n }\n }\n }\n}\n"],"mappings":"AAAA,4SAAOA,EAAmBC,EAAAC,GAAA,MACnBC,EAA2BF,EAAAG,GAKlC,MAMqBC,EAAwBL,EAAmBM,OAAA,uDAM5CC,SAAW,CACvBC,WAAY,CAAC,EACbC,OAAQ,CAAC,EACTC,aAAc,CACVC,SAAU,CAAEC,KAAM,aAAcC,SAAU,MAAOC,WAAY,YANrDC,SAAWZ,EAUpBa,KAAI,SAAAC,IACPC,sBAAAC,MAEAA,KAAKC,eAAiB,IAAIC,EAAe,CACrCC,MAAO,OACPC,OAAQ,QACRC,cAAe,KACfC,gBAAiB,KACjBC,QAAS,mBACTC,OAASC,IACL,MAAMC,EAAMD,EAAOE,aAAa,YAChCX,KAAKY,gBAAgBF,MAI7BV,KAAKa,KAAO,IAAIC,EAAK,CACjBC,MAAO,CAACf,KAAKC,kBAGjBD,KAAKgB,eAAe,WAAYhB,KAAKa,KACzC,EAEOI,kBAAiB,SAAAC,IACpB,MAAMC,EAAWnB,KAAKoB,YAAY,YAClCpB,KAAKC,eAAeoB,aAAaF,GAEjC,MAAMG,EAAatB,KAAKoB,YAAY,SACpC,GAAIE,IAAeC,WAAaD,IAAe,KAAM,CAEjD,GAAItB,KAAKC,eAAeuB,aAAeF,EAAY,CAC/CtB,KAAKC,eAAewB,SAASH,EACjC,CACJ,CACJ,IAAC,OA/CgBpC,CAAe","ignoreList":[],"sourceRoot":"controls"}},{"offset":{"line":7,"column":0},"map":{"version":3,"names":["BaseHardwareControl","_interopRequireDefault","__BaseHardwareControl","SignatureControl","static","properties","events","isDrawing","canvasCtx","canvasEl","init","super","this","canvasHtml","HTML","content","afterRendering","onCanvasRendered","bind","addStyleClass","clearBtn","Button","icon","text","press","clearSignature","vBox","VBox","items","setAggregation","domRef","getDomRef","getContext","lineWidth","lineCap","strokeStyle","addEventListener","startDrawing","draw","stopDrawing","startDrawingTouch","passive","drawTouch","val","getValue","startsWith","loadImageOntoCanvas","dataUrl","img","window","Image","onload","clearRect","width","height","drawImage","src","getCoordinates","e","x","y","rect","getBoundingClientRect","clientX","clientY","type","touches","left","top","preventDefault","pos","lineTo","stroke","beginPath","moveTo","saveSignature","setValueAndFire","MessageToast","show","toDataURL","setValue","value"],"sources":["SignatureControl.ts"],"sourcesContent":["import BaseHardwareControl from \"./BaseHardwareControl\";\nimport Button from \"sap/m/Button\";\nimport VBox from \"sap/m/VBox\";\nimport HTML from \"sap/ui/core/HTML\";\nimport MessageToast from \"sap/m/MessageToast\";\n\n/**\n * SignatureControl\n * Provides an HTML5 Canvas for capturing signatures.\n */\nexport default class SignatureControl extends BaseHardwareControl {\n static readonly renderer = \"nz.co.siliconst.ui5.metaui.controls.BaseHardwareControlRenderer\";\n static readonly metadata = {\n properties: {},\n events: {}\n };\n\n private vBox!: VBox;\n private clearBtn!: Button;\n private canvasHtml!: HTML;\n private isDrawing = false;\n private canvasCtx: CanvasRenderingContext2D | null = null;\n private canvasEl: HTMLCanvasElement | null = null;\n\n public init(): void {\n super.init();\n\n this.canvasHtml = new HTML({\n content: \"<canvas width='400' height='200' style='border: 1px solid #ccc; background-color: #fff; touch-action: none; cursor: crosshair;'></canvas>\",\n afterRendering: this.onCanvasRendered.bind(this)\n }).addStyleClass(\"sapUiSmallMarginBottom\");\n\n this.clearBtn = new Button({\n icon: \"sap-icon://sys-cancel\",\n text: \"Clear Signature\",\n press: this.clearSignature.bind(this)\n });\n\n this.vBox = new VBox({\n items: [this.canvasHtml, this.clearBtn]\n });\n\n this.setAggregation(\"_content\", this.vBox);\n }\n\n private onCanvasRendered(): void {\n const domRef = this.canvasHtml.getDomRef() as HTMLElement;\n if (!domRef) return;\n \n this.canvasEl = domRef as HTMLCanvasElement;\n this.canvasCtx = this.canvasEl.getContext(\"2d\");\n if (this.canvasCtx) {\n this.canvasCtx.lineWidth = 2;\n this.canvasCtx.lineCap = \"round\";\n this.canvasCtx.strokeStyle = \"#000\";\n }\n\n // Mouse events\n this.canvasEl.addEventListener(\"mousedown\", this.startDrawing.bind(this));\n this.canvasEl.addEventListener(\"mousemove\", this.draw.bind(this));\n this.canvasEl.addEventListener(\"mouseup\", this.stopDrawing.bind(this));\n this.canvasEl.addEventListener(\"mouseout\", this.stopDrawing.bind(this));\n \n // Touch events\n this.canvasEl.addEventListener(\"touchstart\", this.startDrawingTouch.bind(this), { passive: false });\n this.canvasEl.addEventListener(\"touchmove\", this.drawTouch.bind(this), { passive: false });\n this.canvasEl.addEventListener(\"touchend\", this.stopDrawing.bind(this));\n\n // Restore existing signature if any\n const val = this.getValue();\n if (val && typeof val === \"string\" && val.startsWith(\"data:image\")) {\n this.loadImageOntoCanvas(val);\n }\n }\n\n private loadImageOntoCanvas(dataUrl: string): void {\n const img = new window.Image();\n img.onload = () => {\n if (this.canvasCtx && this.canvasEl) {\n this.canvasCtx.clearRect(0, 0, this.canvasEl.width, this.canvasEl.height);\n this.canvasCtx.drawImage(img, 0, 0, this.canvasEl.width, this.canvasEl.height);\n }\n };\n img.src = dataUrl;\n }\n\n private getCoordinates(e: MouseEvent | TouchEvent): { x: number, y: number } {\n if (!this.canvasEl) return { x: 0, y: 0 };\n const rect = this.canvasEl.getBoundingClientRect();\n \n let clientX, clientY;\n if (e.type.startsWith(\"touch\")) {\n clientX = (e as TouchEvent).touches[0].clientX;\n clientY = (e as TouchEvent).touches[0].clientY;\n } else {\n clientX = (e as MouseEvent).clientX;\n clientY = (e as MouseEvent).clientY;\n }\n \n return {\n x: clientX - rect.left,\n y: clientY - rect.top\n };\n }\n\n private startDrawing(e: MouseEvent): void {\n this.isDrawing = true;\n this.draw(e);\n }\n\n private startDrawingTouch(e: TouchEvent): void {\n e.preventDefault(); // Prevent scrolling\n this.isDrawing = true;\n this.drawTouch(e);\n }\n\n private draw(e: MouseEvent): void {\n if (!this.isDrawing || !this.canvasCtx) return;\n const pos = this.getCoordinates(e);\n this.canvasCtx.lineTo(pos.x, pos.y);\n this.canvasCtx.stroke();\n this.canvasCtx.beginPath();\n this.canvasCtx.moveTo(pos.x, pos.y);\n }\n\n private drawTouch(e: TouchEvent): void {\n if (!this.isDrawing || !this.canvasCtx) return;\n e.preventDefault(); // Prevent scrolling\n const pos = this.getCoordinates(e);\n this.canvasCtx.lineTo(pos.x, pos.y);\n this.canvasCtx.stroke();\n this.canvasCtx.beginPath();\n this.canvasCtx.moveTo(pos.x, pos.y);\n }\n\n private stopDrawing(): void {\n if (!this.isDrawing) return;\n this.isDrawing = false;\n if (this.canvasCtx) {\n this.canvasCtx.beginPath(); // Reset path\n this.saveSignature();\n }\n }\n\n private clearSignature(): void {\n if (this.canvasCtx && this.canvasEl) {\n this.canvasCtx.clearRect(0, 0, this.canvasEl.width, this.canvasEl.height);\n }\n this.setValueAndFire(null);\n MessageToast.show(\"Signature cleared.\");\n }\n\n private saveSignature(): void {\n if (this.canvasEl) {\n const dataUrl = this.canvasEl.toDataURL(\"image/png\");\n this.setValueAndFire(dataUrl);\n }\n }\n\n public setValue(value: any): this {\n super.setValue(value);\n if (value && typeof value === \"string\" && value.startsWith(\"data:image\")) {\n this.loadImageOntoCanvas(value);\n } else if (!value && this.canvasCtx && this.canvasEl) {\n this.canvasCtx.clearRect(0, 0, this.canvasEl.width, this.canvasEl.height);\n }\n return this;\n }\n}\n"],"mappings":"AAAA,+RAAOA,EAAmBC,EAAAC,GAUX,MAAMC,UAAyBH,EAC1CI,gBAA2B,kEAC3BA,gBAA2B,CACvBC,WAAY,CAAC,EACbC,OAAQ,CAAC,GAMLC,UAAY,MACZC,UAA6C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MC,EAAM1D,KAAK6C,eAAeC,GAChC9C,KAAKJ,UAAU+D,OAAOD,EAAIX,EAAGW,EAAIV,GACjChD,KAAKJ,UAAUgE,SACf5D,KAAKJ,UAAUiE,YACf7D,KAAKJ,UAAUkE,OAAOJ,EAAIX,EAAGW,EAAIV,EACrC,CAEQrB,cACJ,IAAK3B,KAAKL,UAAW,OACrBK,KAAKL,UAAY,MACjB,GAAIK,KAAKJ,UAAW,CAChBI,KAAKJ,UAAUiE,YACf7D,KAAK+D,eACT,CACJ,CAEQlD,iBACJ,GAAIb,KAAKJ,WAAaI,KAAKH,SAAU,CACjCG,KAAKJ,UAAU4C,UAAU,EAAG,EAAGxC,KAAKH,SAAS4C,MAAOzC,KAAKH,SAAS6C,OACtE,CACA1C,KAAKgE,gBAAgB,MACrBC,EAAaC,KAAK,qBACtB,CAEQH,gBACJ,GAAI/D,KAAKH,SAAU,CACf,MAAMsC,EAAUnC,KAAKH,SAASsE,UAAU,aACxCnE,KAAKgE,gBAAgB7B,EACzB,CACJ,CAEOiC,SAASC,GACZtE,MAAMqE,SAASC,GACf,GAAIA,UAAgBA,IAAU,UAAYA,EAAMpC,WAAW,cAAe,CACtEjC,KAAKkC,oBAAoBmC,EAC7B,MAAO,IAAKA,GAASrE,KAAKJ,WAAaI,KAAKH,SAAU,CAClDG,KAAKJ,UAAU4C,UAAU,EAAG,EAAGxC,KAAKH,SAAS4C,MAAOzC,KAAKH,SAAS6C,OACtE,CACA,OAAO1C,IACX,EACH,OAAAT,CAAA","ignoreList":[],"sourceRoot":"controls"}},{"offset":{"line":8,"column":0},"map":{"version":3,"names":["BaseHardwareControl","_interopRequireDefault","__BaseHardwareControl","Logger","___utils_Logger","VoiceInputControl","static","properties","events","recognition","isRecording","init","super","this","textArea","TextArea","rows","width","placeholder","liveChange","oEvent","setValueAndFire","getParameter","startBtn","Button","icon","text","type","press","toggleDictation","bind","hBox","HBox","items","addStyleClass","vBox","VBox","setAggregation","initSpeechRecognition","stopDictation","startDictation","SpeechRecognition","window","webkitSpeechRecognition","continuous","interimResults","onresult","event","finalTranscript","interimTranscript","i","resultIndex","results","length","isFinal","transcript","currentVal","getValue","newVal","setValue","onstart","setIcon","setText","setType","MessageToast","show","onerror","error","sap","ui","require","MessageBox","onend","warn","setEnabled","setTooltip","start","err","message","stop","e","onBeforeRendering","readOnly","getProperty","setEditable","undefined","exit"],"sources":["VoiceInputControl.ts"],"sourcesContent":["import BaseHardwareControl from \"./BaseHardwareControl\";\nimport Button from \"sap/m/Button\";\nimport VBox from \"sap/m/VBox\";\nimport TextArea from \"sap/m/TextArea\";\nimport MessageToast from \"sap/m/MessageToast\";\nimport HBox from \"sap/m/HBox\";\nimport { Logger } from \"../utils/Logger\";\n\n/**\n * VoiceInputControl\n * Provides a UI to dictate text using the browser's native Web Speech API.\n */\nexport default class VoiceInputControl extends BaseHardwareControl {\n static readonly renderer = \"nz.co.siliconst.ui5.metaui.controls.BaseHardwareControlRenderer\";\n static readonly metadata = {\n properties: {},\n events: {}\n };\n\n private vBox!: VBox;\n private textArea!: TextArea;\n private startBtn!: Button;\n private stopBtn!: Button;\n \n private recognition: any = null;\n private isRecording: boolean = false;\n\n public init(): void {\n super.init();\n\n this.textArea = new TextArea({\n rows: 3,\n width: \"100%\",\n placeholder: \"Dictated text will appear here...\",\n liveChange: (oEvent: sap.ui.base.Event) => {\n this.setValueAndFire(oEvent.getParameter(\"value\"));\n }\n });\n\n this.startBtn = new Button({\n icon: \"sap-icon://microphone\",\n text: \"Start Dictation\",\n type: \"Emphasized\",\n press: this.toggleDictation.bind(this)\n });\n\n const hBox = new HBox({\n items: [this.startBtn]\n }).addStyleClass(\"sapUiSmallMarginTop\");\n\n this.vBox = new VBox({\n items: [this.textArea, hBox]\n });\n\n this.setAggregation(\"_content\", this.vBox);\n this.initSpeechRecognition();\n }\n\n private toggleDictation(): void {\n if (this.isRecording) {\n this.stopDictation();\n } else {\n this.startDictation();\n }\n }\n\n private initSpeechRecognition(): void {\n const SpeechRecognition = (window as unknown).SpeechRecognition || (window as unknown).webkitSpeechRecognition;\n if (SpeechRecognition) {\n this.recognition = new SpeechRecognition();\n this.recognition.continuous = true;\n this.recognition.interimResults = true;\n\n this.recognition.onresult = (event: any) => {\n let finalTranscript = \"\";\n let interimTranscript = \"\";\n\n for (let i = event.resultIndex; i < event.results.length; ++i) {\n if (event.results[i].isFinal) {\n finalTranscript += event.results[i][0].transcript;\n } else {\n interimTranscript += event.results[i][0].transcript;\n }\n }\n\n // Append the new final transcript to whatever was already in the textarea\n const currentVal = this.getValue() || \"\";\n const newVal = currentVal ? currentVal + \" \" + finalTranscript : finalTranscript;\n \n if (finalTranscript) {\n this.textArea.setValue(newVal);\n this.setValueAndFire(newVal);\n } else if (interimTranscript) {\n // Just show interim temporarily in textarea without saving to model\n this.textArea.setValue(currentVal ? currentVal + \" \" + interimTranscript : interimTranscript);\n }\n };\n\n this.recognition.onstart = () => {\n this.isRecording = true;\n this.startBtn.setIcon(\"sap-icon://stop\");\n this.startBtn.setText(\"Stop Recording\");\n this.startBtn.setType(\"Reject\");\n MessageToast.show(\"Listening... Please speak now.\");\n };\n\n this.recognition.onerror = (event: any) => {\n Logger.error(\"Speech recognition error\", event.error, \"VoiceInputControl\");\n sap.ui.require([\"sap/m/MessageBox\"], (MessageBox: unknown) => {\n MessageBox.error(\"Microphone Error: \" + event.error + \"\\n\\nPlease ensure you have a working microphone attached and have not blocked access in your browser settings.\");\n });\n this.stopDictation();\n };\n \n this.recognition.onend = () => {\n // If it ends natively (e.g. timeout), update UI\n this.stopDictation();\n };\n } else {\n Logger.warn(\"Web Speech API not supported in this browser.\", \"\", \"VoiceInputControl\");\n this.startBtn.setEnabled(false);\n this.startBtn.setTooltip(\"Speech Recognition is not supported in this browser.\");\n }\n }\n\n private startDictation(): void {\n if (!this.recognition) return;\n \n try {\n this.recognition.start();\n MessageToast.show(\"Requesting microphone access...\");\n // Provide immediate UI feedback in case browser delays the onstart event\n this.startBtn.setIcon(\"sap-icon://stop\");\n this.startBtn.setText(\"Requesting mic...\");\n this.startBtn.setType(\"Reject\");\n } catch (err: any) {\n Logger.error(\"Failed to start speech recognition\", err.message || err, \"VoiceInputControl\");\n sap.ui.require([\"sap/m/MessageBox\"], (MessageBox: unknown) => {\n MessageBox.error(\"Failed to start dictation. Please ensure you have a working microphone and have granted browser permissions.\\n\\nDetails: \" + (err.message || err));\n });\n this.stopDictation();\n }\n }\n\n private stopDictation(): void {\n if (!this.recognition) return;\n \n try {\n this.recognition.stop();\n } catch(e) {}\n \n this.isRecording = false;\n this.startBtn.setIcon(\"sap-icon://microphone\");\n this.startBtn.setText(\"Start Dictation\");\n this.startBtn.setType(\"Emphasized\");\n }\n\n public onBeforeRendering(): void {\n const readOnly = this.getProperty(\"readOnly\");\n this.textArea.setEditable(!readOnly);\n \n // Only enable if it's not readonly AND the browser supports speech recognition\n this.startBtn.setEnabled(!readOnly && !!this.recognition);\n\n const currentVal = this.getProperty(\"value\");\n if (currentVal !== undefined && currentVal !== null) {\n // Only update text area if we aren't currently dictating interim results\n if (!this.isRecording) {\n this.textArea.setValue(currentVal as string);\n }\n }\n }\n\n public exit(): void {\n this.stopDictation();\n if (this.recognition) {\n this.recognition.onstart = null;\n this.recognition.onresult = null;\n this.recognition.onerror = null;\n this.recognition.onend = null;\n this.recognition = null;\n }\n super.exit();\n }\n}\n"],"mappings":"AAAA,iUAAOA,EAAmBC,EAAAC,GAAA,MAMjBC,EAAMC,EAAA,UAMA,MAAMC,UAA0BL,EAC3CM,gBAA2B,kEAC3BA,gBAA2B,CACvBC,WAAY,CAAC,EACbC,OAAQ,CAAC,GAQLC,YAAmB,KACnBC,YAAuB,MAExBC,OACHC,MAAMD,OAENE,KAAKC,SAAW,IAAIC,EAAS,CACzBC,KAAM,EACNC,MAAO,OACPC,YAAa,oCACbC,WAAaC,IACTP,KAAKQ,gBAAgBD,EAAOE,aAAa,aAIjDT,KAAKU,SAAW,IAAIC,EAAO,CACvBC,KAAM,wBACNC,KAAM,kBACNC,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AASH,EAC3B,CACJ,CACJ,CAEO8B,OACHzE,KAAK0B,gBACL,GAAI1B,KAAKJ,YAAa,CAClBI,KAAKJ,YAAYmD,QAAU,KAC3B/C,KAAKJ,YAAYqC,SAAW,KAC5BjC,KAAKJ,YAAYyD,QAAU,KAC3BrD,KAAKJ,YAAY+D,MAAQ,KACzB3D,KAAKJ,YAAc,IACvB,CACAG,MAAM0E,MACV,EACH,OAAAjF,CAAA","ignoreList":[],"sourceRoot":"controls"}},{"offset":{"line":9,"column":0},"map":{"version":3,"names":["Logger","____utils_Logger","SchemaNormalizer","____core_SchemaNormalizer","SchemaValidator","____core_SchemaValidator","Engine","____core_Engine","StateManager","____core_StateManager","DataSyncDelegate","___delegates_DataSyncDelegate","ValidationDelegate","___delegates_ValidationDelegate","DialogDelegate","___delegates_DialogDelegate","GeneratorHost","Control","extend","renderer","apiVersion","render","rm","control","openStart","style","openEnd","content","getAggregation","renderControl","close","metadata","properties","schemaDefinition","type","defaultValue","data","bindable","dataJson","liveUpdate","isValid","useMessageManager","modelName","debugMode","displayMode","aggregations","_content","multiple","visibility","events","beforeSubmit","parameters","payload","addError","preventDefault","submit","payloadJson","cancel","fieldChange","fieldPath","value","validationStateChanged","validationError","message","validationSuccess","constructor","_constructor","idOrSettings","settings","Control.prototype.constructor.call","this","stateManager","generatedContent","engine","activeModelName","parsedSchema","init","_init","Control.prototype.init.call","dataSyncDelegate","validationDelegate","dialogDelegate","onInternalFieldChange","bind","setDebugMode","_setDebugMode","enabled","setProperty","getStateManager","_getStateManager","tearDownGeneratedLayout","_tearDownGeneratedLayout","unregisterObject","destroy","_onInternalFieldChange","fieldKey","errorMessage","controlId","extractPayload","getProperty","debug","pushToBindings","currentValidity","fireEvent","undefined","exit","_exit","getModel","getParsedSchema","_getParsedSchema","onBeforeRendering","_onBeforeRendering","hasSchema","hasData","generate","triggerSubmit","_triggerSubmit","isPrevented","removeAllMessages","errors","validateAll","length","pushMessage","err","JSON","stringify","propertyPath","addCustomError","_addCustomError","clearCustomError","_clearCustomError","setBusy","_setBusy","isBusy","Control.prototype.setBusy.call","_setProperty","propertyName","suppressInvalidate","handleInputDataHotSwap","currentVal","Control.prototype.setProperty.call","setBaseProperty","_setBaseProperty","_generate","internalPayload","rawSchema","inputData","inputDataJson","parse","e","error","finalData","normalizedSchema","normalize","schemaErrors","validateSchemaStructure","errorMsg","join","MessageBox","title","getId","setModel","build","setAggregation","registerObject","mountCrashBoundary","openInDialog","_openInDialog","submitButtonText","isGenerated"],"sources":["GeneratorHost.ts"],"sourcesContent":["import Control from \"sap/ui/core/Control\";\nimport RenderManager from \"sap/ui/core/RenderManager\";\nimport { Logger } from \"../../utils/Logger\";\nimport { SchemaNormalizer } from \"../../core/SchemaNormalizer\";\nimport { SchemaValidator } from \"../../core/SchemaValidator\";\nimport { Engine } from \"../../core/Engine\";\nimport { StateManager } from \"../../core/StateManager\";\nimport { DataSyncDelegate } from \"./delegates/DataSyncDelegate\";\nimport { ValidationDelegate } from \"./delegates/ValidationDelegate\";\nimport { DialogDelegate } from \"./delegates/DialogDelegate\";\nimport MessageBox from \"sap/m/MessageBox\";\n\n/**\n * Base wrapper element for embedding the dynamic form natively via Explicit Schemas.\n * \n * This class serves as the core rendering engine for standard MetaUI implementations.\n * It manages the lifecycle of the Engine, StateManager, and the delegation of \n * data synchronization, validation, and dialog interactions.\n * \n * @namespace nz.co.siliconst.ui5.metaui.controls.host\n */\nexport default class GeneratorHost extends Control {\n\n protected stateManager: StateManager | null = null;\n protected generatedContent: Control | null = null;\n protected engine: Engine | null = null;\n protected activeModelName: string = \"\";\n\n protected dataSyncDelegate!: DataSyncDelegate;\n protected validationDelegate!: ValidationDelegate;\n protected dialogDelegate!: DialogDelegate;\n\n static readonly metadata = {\n properties: {\n schemaDefinition: { type: \"any\", defaultValue: null },\n data: { type: \"object\", defaultValue: null, bindable: \"bindable\" },\n dataJson: { type: \"string\", defaultValue: null, bindable: \"bindable\" },\n liveUpdate: { type: \"boolean\", defaultValue: false },\n isValid: { type: \"boolean\", defaultValue: true },\n useMessageManager: { type: \"boolean\", defaultValue: false },\n modelName: { type: \"string\", defaultValue: \"meta\" },\n debugMode: { type: \"boolean\", defaultValue: false },\n displayMode: { type: \"boolean\", defaultValue: false }\n },\n aggregations: {\n _content: { type: \"sap.ui.core.Control\", multiple: false, visibility: \"hidden\" }\n },\n events: {\n beforeSubmit: {\n parameters: {\n payload: { type: \"object\" },\n addError: { type: \"function\" },\n preventDefault: { type: \"function\" }\n }\n },\n submit: {\n parameters: {\n payload: { type: \"object\" },\n payloadJson: { type: \"string\" }\n }\n },\n cancel: {},\n fieldChange: {\n parameters: {\n fieldPath: { type: \"string\" },\n value: { type: \"any\" },\n payload: { type: \"object\" },\n isValid: { type: \"boolean\" }\n }\n },\n validationStateChanged: { parameters: { isValid: { type: \"boolean\" } } },\n validationError: { parameters: { fieldPath: { type: \"string\" }, message: { type: \"string\" } } },\n validationSuccess: { parameters: { fieldPath: { type: \"string\" } } }\n }\n };\n\n static renderer = {\n apiVersion: 2,\n render(rm: RenderManager, control: GeneratorHost) {\n rm.openStart(\"div\", control);\n rm.style(\"width\", \"100%\");\n rm.style(\"height\", \"100%\");\n rm.openEnd();\n\n const content = control.getAggregation(\"_content\") as Control;\n if (content) {\n rm.renderControl(content);\n }\n\n rm.close(\"div\");\n }\n };\n\n /**\n * Standard UI5 Constructor.\n */\n constructor(idOrSettings?: string | object, settings?: object) {\n super(idOrSettings, settings);\n }\n\n /**\n * Initializes the control and instantiates the composition delegates.\n * Delegates must be initialized here rather than in the constructor so they are \n * available before `applySettings` runs during UI5's control lifecycle.\n */\n public init(): void {\n super.init();\n\n // Initialize Composition Delegates\n this.dataSyncDelegate = new DataSyncDelegate(this as any);\n this.validationDelegate = new ValidationDelegate(this as any);\n this.dialogDelegate = new DialogDelegate(this as any);\n\n this.onInternalFieldChange = this.onInternalFieldChange.bind(this);\n }\n\n /**\n * Enables or disables debug mode.\n */\n public setDebugMode(enabled: boolean): this {\n this.setProperty(\"debugMode\", enabled, true);\n Logger.setDebugMode(enabled);\n return this;\n }\n\n /**\n * Returns the active state manager instance managing the JSON payload.\n */\n public getStateManager(): StateManager | null {\n return this.stateManager;\n }\n\n /**\n * Safely destroys the currently generated UI tree and cleans up references.\n * This is called before every regeneration to prevent memory leaks.\n */\n public tearDownGeneratedLayout(): void {\n if (this.generatedContent) {\n this.validationDelegate.unregisterObject(this.generatedContent);\n this.generatedContent.destroy();\n this.generatedContent = null;\n }\n }\n\n /**\n * Internal event handler triggered by the Engine when a field value changes.\n * Coordinates LiveUpdate syncs, validation state tracking, and bubbling the change upwards.\n */\n protected onInternalFieldChange(isValid: boolean, fieldKey?: string, errorMessage?: string, controlId?: string): void {\n const payload = this.stateManager ? this.stateManager.extractPayload() : {};\n\n if (this.getProperty(\"liveUpdate\") === true) {\n if (this.getProperty(\"debugMode\")) {\n Logger.debug(\"[MetaUI]\", \"liveUpdate is enabled, pushing outbound payload.\", \"GeneratorHost\");\n }\n this.dataSyncDelegate.pushToBindings(payload);\n }\n\n const currentValidity = this.getProperty(\"isValid\") as boolean;\n if (isValid !== currentValidity) {\n this.setProperty(\"isValid\", isValid, true);\n this.fireEvent(\"validationStateChanged\", { isValid });\n if (this.getProperty(\"debugMode\")) {\n Logger.debug(\"[MetaUI]\", `Validation state shifted to: ${isValid}`, \"GeneratorHost\");\n }\n }\n\n this.fireEvent(\"fieldChange\", {\n fieldPath: fieldKey || \"\",\n value: undefined,\n payload: payload,\n isValid: isValid\n });\n }\n\n /**\n * Standard UI5 Exit Hook. Ensures complete teardown of the engine and state manager.\n */\n public exit(): void {\n if (this.engine) {\n this.engine.destroy();\n this.engine = null;\n }\n\n if (this.stateManager) {\n this.stateManager.getModel().destroy();\n this.stateManager = null;\n }\n\n if (this.generatedContent) {\n this.generatedContent.destroy();\n this.generatedContent = null;\n }\n }\n\n /** Cached schema for intelligent diffing during inference mode hot-swaps */\n protected parsedSchema: Record<string, unknown> | null = null;\n\n /**\n * Exposes the parsed schema to the DataSyncDelegate for diffing.\n */\n public getParsedSchema(): Record<string, unknown> | null {\n return this.parsedSchema;\n }\n\n /**\n * Standard UI5 Rendering Hook.\n * Evaluates whether it possesses a schema or data. If so, triggers the internal engine generation.\n */\n public onBeforeRendering(): void {\n if (this.getProperty(\"debugMode\")) {\n Logger.debug(\"[MetaUI GeneratorHost]\", `onBeforeRendering called. Engine boot state: schemaDefinition exists = ${!!this.getProperty(\"schemaDefinition\")}, data exists = ${!!this.getProperty(\"data\")}, dataJson exists = ${!!this.getProperty(\"dataJson\")}`, \"GeneratorHost\");\n }\n\n if (!this.generatedContent) {\n const hasSchema = !!this.getProperty(\"schemaDefinition\");\n const hasData = !!this.getProperty(\"dataJson\") || !!this.getProperty(\"data\");\n\n if (hasSchema || hasData) {\n this.generate();\n } else if (this.getProperty(\"debugMode\")) {\n Logger.debug(\"[MetaUI]\", \"GeneratorHost skipped rendering. Neither 'schemaDefinition' nor data was provided.\", \"GeneratorHost\");\n }\n }\n }\n\n /**\n * Public API method to manually trigger form submission.\n * Executes all structural validations, clears old messages, and pushes payload to bindings.\n * @returns boolean True if submission succeeded, false if validation failed.\n */\n public triggerSubmit(): boolean {\n if (this.stateManager && this.engine) {\n let isPrevented = false;\n\n this.validationDelegate.removeAllMessages();\n\n const errors = this.engine.validateAll();\n if (errors.length > 0) {\n this.validationDelegate.pushMessage(\"\", \"One or more fields failed schema validation. Please review the highlighted fields.\");\n for (const err of errors) {\n if (err.fieldKey && err.errorMessage) {\n this.validationDelegate.pushMessage(err.fieldKey, err.errorMessage);\n }\n }\n return false;\n }\n\n const payload = this.stateManager.extractPayload();\n const payloadJson = JSON.stringify(payload);\n\n this.fireEvent(\"beforeSubmit\", {\n payload,\n preventDefault: () => { isPrevented = true; },\n addError: (propertyPath: string, errorMessage: string) => {\n isPrevented = true;\n this.validationDelegate.pushMessage(propertyPath, errorMessage);\n }\n });\n\n if (isPrevented) {\n return false;\n }\n\n this.dataSyncDelegate.pushToBindings(payload);\n this.fireEvent(\"submit\", { payload, payloadJson });\n return true;\n }\n return false;\n }\n\n /**\n * Injects a custom error message onto a specific field.\n */\n public addCustomError(fieldPath: string, message: string): void {\n this.validationDelegate.addCustomError(fieldPath, message);\n }\n\n /**\n * Clears a custom error message from a specific field.\n */\n public clearCustomError(fieldPath: string): void {\n this.validationDelegate.clearCustomError(fieldPath);\n }\n\n /**\n * Toggles busy state on the host control.\n */\n public setBusy(isBusy: boolean): this {\n super.setBusy(isBusy);\n return this;\n }\n\n /**\n * Intercepts property changes. Hot-swaps data gracefully if it's an inputData change,\n * or forces a full UI teardown if it's a structural property change (like schemaDefinition).\n */\n public setProperty(propertyName: string, value: unknown, suppressInvalidate?: boolean): this {\n if (propertyName === \"dataJson\" || propertyName === \"data\") {\n this.dataSyncDelegate.handleInputDataHotSwap(propertyName, value, suppressInvalidate);\n return this;\n }\n\n if (propertyName === \"displayMode\" || propertyName === \"debugMode\" || propertyName === \"schemaDefinition\") {\n const currentVal = this.getProperty(propertyName);\n if (currentVal !== value) {\n super.setProperty(propertyName, value, suppressInvalidate);\n this.tearDownGeneratedLayout();\n }\n return this;\n }\n\n return super.setProperty(propertyName, value, suppressInvalidate);\n }\n\n /**\n * Bypasses the interceptor to write directly to the base UI5 control.\n */\n public setBaseProperty(propertyName: string, value: unknown, suppressInvalidate?: boolean): this {\n return super.setProperty(propertyName, value, suppressInvalidate);\n }\n\n /**\n * The core rendering pipeline.\n * Normalizes the schema, sets up the state manager, orchestrates the engine build,\n * and sets the generated UI components into the internal aggregation tree.\n */\n public generate(): void {\n try {\n this.tearDownGeneratedLayout();\n\n // CRITICAL FIX: Extract the unsaved internal payload BEFORE destroying the state manager\n // Otherwise, toggling displayMode (or other structural properties) will wipe user inputs!\n let internalPayload = null;\n if (this.stateManager) {\n internalPayload = this.stateManager.extractPayload();\n }\n\n if (this.engine) {\n this.engine.destroy();\n this.engine = null;\n }\n if (this.stateManager) {\n this.stateManager.getModel().destroy();\n this.stateManager = null;\n }\n\n const rawSchema = this.getProperty(\"schemaDefinition\");\n let inputData = this.getProperty(\"data\");\n const inputDataJson = this.getProperty(\"dataJson\");\n\n if (inputDataJson) {\n try {\n inputData = JSON.parse(inputDataJson as string);\n } catch (e) {\n Logger.error(\"[MetaUI]\", \"Failed to parse inputDataJson string: \" + (e as Error).message, \"GeneratorHost\");\n }\n } else if (typeof inputData === \"string\") {\n try {\n inputData = JSON.parse(inputData);\n } catch (e) {\n Logger.error(\"[MetaUI]\", \"Failed to parse inputData string: \" + (e as Error).message, \"GeneratorHost\");\n }\n }\n\n // The internal payload represents the user's latest un-extracted edits. It must take priority.\n const finalData = internalPayload || inputData || {};\n\n const normalizedSchema = SchemaNormalizer.normalize(rawSchema, finalData);\n\n // Cache the parsed/inferred schema so DataSyncDelegate can diff against it later\n this.parsedSchema = normalizedSchema as Record<string, unknown>;\n\n if (normalizedSchema) {\n const schemaErrors = SchemaValidator.validateSchemaStructure(normalizedSchema);\n if (schemaErrors.length > 0) {\n const errorMsg = \"Schema Structural Errors Found:\\n- \" + schemaErrors.join(\"\\n- \");\n // Let's log it out loudly regardless of debug mode, so developers can see why it didn't render\n Logger.error(\"[MetaUI]\", errorMsg, \"GeneratorHost\");\n if (this.getProperty(\"debugMode\")) {\n MessageBox.error(errorMsg, { title: \"MetaUI Schema Error\" });\n return;\n }\n }\n }\n\n this.activeModelName = \"metaUI_\" + this.getId();\n this.stateManager = new StateManager(finalData, normalizedSchema, this.activeModelName);\n this.setModel(this.stateManager.getModel(), this.activeModelName);\n\n this.engine = new Engine(this.getProperty(\"displayMode\") as boolean);\n\n this.generatedContent = this.engine.build(\n normalizedSchema,\n this.stateManager.getModel(),\n this.activeModelName,\n this.triggerSubmit.bind(this),\n this.getId(),\n this.onInternalFieldChange.bind(this)\n );\n\n this.setAggregation(\"_content\", this.generatedContent);\n this.validationDelegate.registerObject(this.generatedContent);\n\n const payload = this.stateManager.extractPayload();\n this.dataSyncDelegate.pushToBindings(payload);\n\n } catch (error) {\n Logger.error(\"[MetaUI]\", \"Fatal crash during layout generation: \" + (error as Error).message, \"GeneratorHost\");\n this.validationDelegate.mountCrashBoundary(error as Error);\n }\n }\n\n /**\n * Programmatic API. Re-parents the generated content into a dialog and opens it.\n */\n public openInDialog(title: string = \"Form\", submitButtonText: string = \"OK\"): void {\n const isGenerated = !!this.generatedContent;\n this.dialogDelegate.openInDialog(title, submitButtonText, isGenerated);\n }\n}\n"],"mappings":"AAAA,kYAESA,EAAMC,EAAA,gBACNC,EAAgBC,EAAA,0BAChBC,EAAeC,EAAA,yBACfC,EAAMC,EAAA,gBACNC,EAAYC,EAAA,sBACZC,EAAgBC,EAAA,0BAChBC,EAAkBC,EAAA,4BAClBC,EAAcC,EAAA,kBAGvB,MASqBC,EAAsBC,EAAOC,OAAA,0DAuDvCC,SAAW,CACdC,WAAY,EACZC,OAAOC,EAAmBC,GACtBD,EAAGE,UAAU,MAAOD,GACpBD,EAAGG,MAAM,QAAS,QAClBH,EAAGG,MAAM,SAAU,QACnBH,EAAGI,UAEH,MAAMC,EAAUJ,EAAQK,eAAe,YACvC,GAAID,EAAS,CACTL,EAAGO,cAAcF,EACrB,CAEAL,EAAGQ,MAAM,MACb,GA1DYC,SAAW,CACvBC,WAAY,CACRC,iBAAkB,CAAEC,KAAM,MAAOC,aAAc,MAC/CC,KAAM,CAAEF,KAAM,SAAUC,aAAc,KAAME,SAAU,YACtDC,SAAU,CAAEJ,KAAM,SAAUC,aAAc,KAAME,SAAU,YAC1DE,WAAY,CAAEL,KAAM,UAAWC,aAAc,OAC7CK,QAAS,CAAEN,KAAM,UAAWC,aAAc,MAC1CM,kBAAmB,CAAEP,KAAM,UAAWC,aAAc,OACpDO,UAAW,CAAER,KAAM,SAAUC,aAAc,QAC3CQ,UAAW,CAAET,KAAM,UAAWC,aAAc,OAC5CS,YAAa,CAAEV,KAAM,UAAWC,aAAc,QAElDU,aAAc,CACVC,SAAU,CAAEZ,KAAM,sBAAuBa,SAAU,MAAOC,WAAY,WAE1EC,OAAQ,CACJ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"controls/host"}},{"offset":{"line":10,"column":0},"map":{"version":3,"names":["Logger","_____utils_Logger","SchemaNormalizer","_____core_SchemaNormalizer","DataSyncDelegate","_lastPushedPayloadJson","_lastPushedPayloadObj","_lastReceivedInputObj","constructor","host","this","pushToBindings","payload","payloadStr","JSON","stringify","deepEqual","parse","setProperty","handleInputDataHotSwap","propertyName","value","suppressInvalidate","incomingObj","e","setBaseProperty","getProperty","debug","extend","stateManager","getStateManager","invalidate","getModel","setData","getParsedSchema","newInferredSchema","inferSchemaFromData","parsedSchema","tearDownGeneratedLayout","msg","message","error","sap","ui","require","MessageBox","__exports","__esModule"],"sources":["DataSyncDelegate.ts"],"sourcesContent":["import deepEqual from \"sap/base/util/deepEqual\";\nimport extend from \"sap/base/util/extend\";\nimport { Logger } from \"../../../utils/Logger\";\nimport { SchemaNormalizer } from \"../../../core/SchemaNormalizer\";\nimport PropertyBinding from \"sap/ui/model/PropertyBinding\";\nimport { StateManager } from \"../../../core/StateManager\";\n\nexport interface IHostDataSync {\n getProperty(name: string): unknown;\n setProperty(name: string, value: unknown, suppressInvalidate?: boolean): any;\n setBaseProperty(name: string, value: unknown, suppressInvalidate?: boolean): any;\n getBinding(name: string): any;\n invalidate(): void;\n getStateManager(): StateManager | null;\n getParsedSchema?(): Record<string, unknown> | null;\n tearDownGeneratedLayout(): void;\n}\n\n/**\n * Handles two-way data sync, JSON parsing, loop-breaking, and inference structural diffs.\n */\nexport class DataSyncDelegate {\n private host: IHostDataSync;\n private _lastPushedPayloadJson: string | null = null;\n private _lastPushedPayloadObj: Record<string, unknown> | null = null;\n private _lastReceivedInputObj: Record<string, unknown> | null = null;\n\n constructor(host: IHostDataSync) {\n this.host = host;\n }\n\n /**\n * Natively forces the UI5 framework to push updated properties back up to any bound ViewModels.\n */\n public pushToBindings(payload: Record<string, unknown>): void {\n const payloadStr = JSON.stringify(payload, null, 2);\n\n // Cache exact payload output to catch echoes on the inbound side\n this._lastPushedPayloadJson = payloadStr;\n this._lastPushedPayloadObj = deepEqual({}, payload) ? null : JSON.parse(JSON.stringify(payload)); // Safe clone\n\n this.host.setProperty(\"data\", payload, true);\n this.host.setProperty(\"dataJson\", payloadStr, true);\n }\n\n /**\n * Intercepts and parses live updates to the data payload from two-way Fiori bindings.\n */\n public handleInputDataHotSwap(propertyName: string, value: unknown, suppressInvalidate?: boolean): void {\n let incomingObj: Record<string, unknown> | null = null;\n\n if (typeof value === \"string\") {\n try {\n incomingObj = JSON.parse(value) as Record<string, unknown>;\n } catch (e) {\n this.host.setBaseProperty(propertyName, value, true);\n return;\n }\n } else {\n incomingObj = value as Record<string, unknown>;\n }\n\n if (incomingObj === null) {\n this.host.setBaseProperty(propertyName, value, true);\n return;\n }\n\n // Loop Breaker 1: Stale Data Injection\n if (this._lastReceivedInputObj && deepEqual(incomingObj, this._lastReceivedInputObj)) {\n if (this.host.getProperty(\"debugMode\")) {\n Logger.debug(\"[MetaUI]\", `Dropped stale data injection for ${propertyName}`, \"DataSyncDelegate\");\n }\n this.host.setBaseProperty(propertyName, value, suppressInvalidate);\n return;\n }\n\n // Loop Breaker 2: Two-Way Data Echoes\n if (this._lastPushedPayloadObj && deepEqual(incomingObj, this._lastPushedPayloadObj)) {\n if (this.host.getProperty(\"debugMode\")) {\n Logger.debug(\"[MetaUI]\", `Dropped echo for ${propertyName}`, \"DataSyncDelegate\");\n }\n this.host.setBaseProperty(propertyName, value, suppressInvalidate);\n return;\n }\n\n this._lastReceivedInputObj = extend(true, {}, incomingObj) as Record<string, unknown>;\n\n if (this.host.getProperty(\"debugMode\")) {\n Logger.debug(\"[MetaUI]\", `Accepted external injection for ${propertyName}`, \"DataSyncDelegate\");\n }\n\n this.host.setBaseProperty(propertyName, value, true);\n\n const stateManager = this.host.getStateManager();\n if (!stateManager) {\n this.host.invalidate();\n return;\n }\n\n try {\n stateManager.getModel().setData(incomingObj, false);\n\n if (!this.host.getProperty(\"schemaDefinition\") && typeof this.host.getParsedSchema === \"function\") {\n const newInferredSchema = SchemaNormalizer.inferSchemaFromData(incomingObj);\n const parsedSchema = this.host.getParsedSchema();\n if (!deepEqual(newInferredSchema, parsedSchema)) {\n this.host.tearDownGeneratedLayout();\n this.host.invalidate();\n }\n }\n } catch (e) {\n const msg = `Failed to hot-swap ${propertyName}: ` + (e as Error).message;\n Logger.error(\"[MetaUI]\", msg, \"DataSyncDelegate\");\n if (this.host.getProperty(\"debugMode\")) {\n sap.ui.require([\"sap/m/MessageBox\"], (MessageBox: unknown) => (MessageBox as Record<string, Function>).error(msg));\n }\n }\n }\n}\n"],"mappings":"AAAA,yOAESA,EAAMC,EAAA,gBACNC,EAAgBC,EAAA,oBAkBlB,MAAMC,EAEDC,uBAAwC,KACxCC,sBAAwD,KACxDC,sBAAwD,KAEhEC,YAAYC,GACRC,KAAKD,KAAOA,CAChB,CAKOE,eAAeC,GAClB,MAAMC,EAAaC,KAAKC,UAAUH,EAAS,KAAM,GAGjDF,KAAKL,uBAAyBQ,EAC9BH,KAAKJ,sBAAwBU,EAAU,CAAC,EAAGJ,GAAW,KAAOE,KAAKG,MAAMH,KAAKC,UAAUH,IAEvFF,KAAKD,KAAKS,YAAY,OAAQN,EAAS,MACvCF,KAAKD,KAAKS,YAAY,WAAYL,EAAY,KAClD,CAKOM,uBAAuBC,EAAsBC,EAAgBC,GAChE,IAAIC,EAA8C,KAElD,UAAWF,IAAU,SAAU,CAC3B,IACIE,EAAcT,KAAKG,MAAMI,EAC7B,CAAE,MAAOG,GACLd,KAAKD,KAAKgB,gBAAgBL,EAAcC,EAAO,MAC/C,MACJ,CACJ,KAAO,CACHE,EAAcF,CAClB,CAEA,GAAIE,IAAgB,KAAM,CACtBb,KAAKD,KAAKgB,gBAAgBL,EAAcC,EAAO,MAC/C,MACJ,CAGA,GAAIX,KAAKH,uBAAyBS,EAAUO,EAAab,KAAKH,uBAAwB,CAClF,GAAIG,KAAKD,KAAKiB,YAAY,aAAc,CACpC1B,EAAO2B,MAAM,WAAY,oCAAoCP,IAAgB,mBACjF,CACAV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ils_Logger","DialogDelegate","constructor","host","this","openInDialog","title","submitButtonText","isGenerated","generate","dialog","Dialog","contentWidth","content","beginButton","Button","text","type","press","success","triggerSubmit","close","err","error","message","fireEvent","fieldPath","endButton","afterClose","destroy","open","__exports","__esModule"],"sources":["DialogDelegate.ts"],"sourcesContent":["import Dialog from \"sap/m/Dialog\";\nimport Button from \"sap/m/Button\";\nimport Control from \"sap/ui/core/Control\";\nimport { Logger } from \"../../../utils/Logger\";\n\nexport interface IHostDialog {\n generate(): void;\n triggerSubmit(): boolean;\n fireEvent(eventName: string, parameters?: any): void;\n}\n\n/**\n * Extracts all popup and dialog generation logic from the Host control.\n */\nexport class DialogDelegate {\n private host: IHostDialog & Control;\n\n constructor(host: IHostDialog & Control) {\n this.host = host;\n }\n\n /**\n * Dialog Modality: Opens the generated layout inside a sap.m.Dialog.\n * Automatically wires up customizable submit (default: 'OK') and 'Cancel' buttons.\n */\n public openInDialog(title: string = \"Form\", submitButtonText: string = \"OK\", isGenerated: boolean): void {\n if (!isGenerated) {\n this.host.generate();\n }\n\n const dialog = new Dialog({\n title: title,\n contentWidth: \"800px\",\n content: [this.host], // Mount host inside the dialog\n beginButton: new Button({\n text: submitButtonText,\n type: \"Emphasized\",\n press: () => {\n try {\n const success = this.host.triggerSubmit();\n if (success) {\n dialog.close();\n }\n } catch (err) {\n Logger.error(\"[MetaUI] Catastrophic error during validation/submit pipeline\", (err as Error).message, \"DialogDelegate\");\n this.host.fireEvent(\"validationError\", { fieldPath: \"root\", message: (err as Error).message });\n }\n }\n }),\n endButton: new Button({\n text: \"Cancel\",\n press: () => {\n this.host.fireEvent(\"cancel\");\n dialog.close();\n }\n }),\n afterClose: () => {\n dialog.destroy();\n }\n });\n\n dialog.open();\n }\n}\n"],"mappings":"AAAA,iLAGSA,EAAMC,EAAA,UAWR,MAAMC,EAGTC,YAAYC,GACRC,KAAKD,KAAOA,CAChB,CAMOE,aAAaC,EAAgB,OAAQC,EAA2B,KAAMC,GACzE,IAAKA,EAAa,CACdJ,KAAKD,KAAKM,UACd,CAEA,MAAMC,EAAS,IAAIC,EAAO,CACtBL,MAAOA,EACPM,aAAc,QACdC,QAAS,CAACT,KAAKD,MACfW,YAAa,IAAIC,EAAO,CACpBC,KAAMT,EACNU,KAAM,aACNC,MAAOA,KACH,IACI,MAAMC,EAAUf,KAAKD,KAAKiB,gBAC1B,GAAID,EAAS,CACTT,EAAOW,OACX,CACJ,CAAE,MAAOC,GACLvB,EAAOwB,MAAM,gEAAkED,EAAcE,QAAS,kBACtGpB,KAAKD,KAAKsB,UAAU,kBAAmB,CAAEC,UAAW,OAAQF,QAAUF,EAAcE,SACxF,KAGRG,UAAW,IAAIZ,EAAO,CAClBC,KAAM,SACNE,MAAOA,KACHd,KAAKD,KAAKsB,UAAU,UACpBf,EAAOW,WAGfO,WAAYA,KACRlB,EAAOmB,aAIfnB,EAAOoB,MACX,EACH,IAAAC,EAAA,CAAAC,WAAA,MAAAD,EAAA9B,iBAAA,OAAA8B,CAAA","ignoreList":[],"sourceRoot":"controls/host/delegates"}},{"offset":{"line":12,"column":0},"map":{"version":3,"names":["Logger","_____utils_Logger","ODataDelegate","odataType","isSyncing","constructor","host","context","this","detectODataType","model","getModel","sClassName","getMetadata","getName","indexOf","syncToEngine","requestObject","then","oData","pushPayload","catch","err","error","message","getObject","cleanData","key","Object","keys","startsWith","setProperty","handleFieldChange","fieldPath","value","getProperty","debug","e","__exports","__esModule"],"sources":["ODataDelegate.ts"],"sourcesContent":["import { DynamicHost } from \"../DynamicHost\";\nimport Context from \"sap/ui/model/Context\";\nimport { Logger } from \"../../../utils/Logger\";\n\n/**\n * Universal OData Delegate.\n * Natively detects and manages two-way synchronization for both OData V2 and V4 contexts\n * without requiring controller-level mappings.\n */\nexport class ODataDelegate {\n private host: DynamicHost;\n private context: Context;\n private odataType: \"V2\" | \"V4\" | null = null;\n private isSyncing: boolean = false;\n\n /**\n * Initializes a new instance of the ODataDelegate.\n * \n * @param {DynamicHost} host The parent MetaUI DynamicHost instance managing the UI generation.\n * @param {Context} context The active UI5 Model Context bound to the host.\n */\n constructor(host: DynamicHost, context: Context) {\n this.host = host;\n this.context = context;\n this.detectODataType();\n }\n\n /**\n * Evaluates the underlying UI5 Model bound to the context to determine if it is an\n * OData V2 or OData V4 model. This determination drives the synchronization strategy.\n * \n * @private\n */\n private detectODataType(): void {\n const model = this.context.getModel();\n // sap.ui.model.odata.v4.ODataModel\n // sap.ui.model.odata.v2.ODataModel\n const sClassName = model.getMetadata().getName();\n if (sClassName.indexOf(\"v4\") > -1) {\n this.odataType = \"V4\";\n } else if (sClassName.indexOf(\"v2\") > -1 || sClassName.indexOf(\"ODataModel\") > -1) {\n this.odataType = \"V2\";\n }\n }\n\n /**\n * Extracts the full entity payload from the bound OData context and pushes it to the Engine.\n * V4 uses an asynchronous requestObject(), while V2 retrieves it synchronously.\n * \n * @public\n */\n public syncToEngine(): void {\n if (!this.odataType) return;\n\n if (this.odataType === \"V4\") {\n // V4 uses async requestObject()\n if (typeof (this.context as any).requestObject === \"function\") {\n (this.context as any).requestObject().then((oData: any) => {\n this.pushPayload(oData);\n }).catch((err: Error) => {\n Logger.error(\"[MetaUI]\", \"Failed to extract V4 Context payload: \" + err.message, \"ODataDelegate\");\n });\n }\n } else if (this.odataType === \"V2\") {\n // V2 uses sync getObject()\n const oData = this.context.getObject();\n if (oData) {\n this.pushPayload(oData);\n }\n }\n }\n\n /**\n * Cleans the raw OData payload by stripping framework metadata properties (keys starting with '@' or '__')\n * and pushes the sanitized business data into the MetaUI DynamicHost state manager.\n * \n * @param {any} oData The raw JSON object extracted from the OData model context.\n * @private\n */\n private pushPayload(oData: any): void {\n if (!oData) return;\n \n // Remove OData metadata properties before pushing to MetaUI\n const cleanData = { ...oData };\n for (const key of Object.keys(cleanData)) {\n if (key.startsWith(\"@\") || key.startsWith(\"__\")) {\n delete cleanData[key];\n }\n }\n\n this.isSyncing = true;\n this.host.setProperty(\"data\", cleanData);\n this.isSyncing = false;\n }\n\n /**\n * Intercepts a field change from the MetaUI Engine and translates it into an OData PATCH.\n */\n public handleFieldChange(fieldPath: string, value: any): void {\n if (this.isSyncing || !this.odataType) return;\n\n try {\n if (this.odataType === \"V4\") {\n // V4 sets property directly on context\n this.context.setProperty(fieldPath, value);\n } else if (this.odataType === \"V2\") {\n // V2 sets property on model, specifying the context path\n const model = this.context.getModel();\n model.setProperty(fieldPath, value, this.context);\n }\n if (this.host.getProperty(\"debugMode\")) {\n Logger.debug(\"[MetaUI]\", `ODataDelegate Patched ${fieldPath} = ${value} via ${this.odataType}`, \"ODataDelegate\");\n }\n } catch (e) {\n Logger.error(\"[MetaUI]\", `Failed to patch OData context: ${(e as Error).message}`, \"ODataDelegate\");\n }\n }\n}\n"],"mappings":"AAAA,8IAESA,EAAMC,EAAA,UAOR,MAAMC,EAGDC,UAAgC,KAChCC,UAAqB,MAQ7BC,YAAYC,EAAmBC,GAC3BC,KAAKF,KAAOA,EACZE,KAAKD,QAAUA,EACfC,KAAKC,iBACT,CAQQA,kBACJ,MAAMC,EAAQF,KAAKD,QAAQI,WAG3B,MAAMC,EAAaF,EAAMG,cAAcC,UACvC,GAAIF,EAAWG,QAAQ,OAAS,EAAG,CAC/BP,KAAKL,UAAY,IACrB,MAAO,GAAIS,EAAWG,QAAQ,OAAS,GAAKH,EAAWG,QAAQ,eAAiB,EAAG,CAC/EP,KAAKL,UAAY,IACrB,CACJ,CAQOa,eACH,IAAKR,KAAKL,UAAW,OAErB,GAAIK,KAAKL,YAAc,KAAM,CAEzB,UAAYK,KAAKD,QAAgBU,gBAAkB,WAAY,CAC1DT,KAAKD,QAAgBU,gBAAgBC,KAAMC,IACxCX,KAAKY,YAAYD,KAClBE,MAAOC,IACNtB,EAAOuB,MAAM,WAAY,yCAA2CD,EAAIE,QAAS,kBAEzF,CACJ,MAAO,GAAIhB,KAAKL,YAAc,KAAM,CAEhC,MAAMgB,EAAQX,KAAKD,QAAQkB,YAC3B,GAAIN,EAAO,CACPX,KAAKY,YAAYD,EACrB,CACJ,CACJ,CASQC,YAAYD,GAChB,IAAKA,EAAO,OAGZ,MAAMO,EAAY,IAAKP,GACvB,IAAK,MAAMQ,KAAOC,OAAOC,KAAKH,GAAY,CACtC,GAAIC,EAAIG,WAAW,MAAQH,EAAIG,WAAW,MAAO,QACtCJ,EAAUC,EACrB,CACJ,CAEAnB,KAAKJ,UAAY,KACjBI,KAAKF,KAAKyB,YAAY,OAAQL,GAC9BlB,KAAKJ,UAAY,KACrB,CAKO4B,kBAAkBC,EAAmBC,GACxC,GAAI1B,KAAKJ,YAAcI,KAAKL,UAAW,OAEvC,IACI,GAAIK,KAAKL,YAAc,KAAM,CAEzBK,KAAKD,QAAQwB,YAAYE,EAAWC,EACxC,MAAO,GAAI1B,KAAKL,YAAc,KAAM,CAEhC,MAAMO,EAAQF,KAAKD,QAAQI,WAC3BD,EAAMqB,YAAYE,EAAWC,EAAO1B,KAAKD,QAC7C,CACA,GAAIC,KAAKF,KAAK6B,YAAY,aAAc,CACpCnC,EAAOoC,MAAM,WAAY,yBAAyBH,OAAeC,SAAa1B,KAAKL,YAAa,gBACpG,CACJ,CAAE,MAAOkC,GACLrC,EAAOuB,MAAM,WAAY,kCAAmCc,EAAYb,UAAW,gBACvF,CACJ,EACH,IAAAc,EAAA,CAAAC,WAAA,MAAAD,EAAApC,gBAAA,OAAAoC,CAAA","ignoreList":[],"sourceRoot":"controls/host/delegates"}},{"offset":{"line":13,"column":0},"map":{"version":3,"names":["Logger","_____utils_Logger","ValidationDelegate","constructor","host","this","registerObject","control","getProperty","Messaging","unregisterObject","removeAllMessages","pushMessage","path","text","targetPath","replace","displayText","warn","sap","ui","require","MessageClass","messageManager","stateManager","getStateManager","addMessages","message","type","target","processor","getModel","addCustomError","fieldPath","useMessageManager","clearCustomError","messages","getMessageModel","getData","messageToRemove","find","m","getTarget","getMessageProcessor","getId","removeMessages","mountCrashBoundary","error","errorPage","MessagePage","description","icon","setAggregation","__exports","__esModule"],"sources":["ValidationDelegate.ts"],"sourcesContent":["import MessagePage from \"sap/m/MessagePage\";\nimport Messaging from \"sap/ui/core/Messaging\";\nimport Control from \"sap/ui/core/Control\";\nimport { StateManager } from \"../../../core/StateManager\";\nimport { Logger } from \"../../../utils/Logger\";\nimport Message from \"sap/ui/core/message/Message\";\n\nexport interface IHostValidation {\n getProperty(name: string): unknown;\n setAggregation(aggregationName: string, object: any, suppressInvalidate?: boolean): any;\n getStateManager(): StateManager | null;\n}\n\n/**\n * Handles Fiori MessageManager integration and provides a standardized Error Boundary UI fallback.\n */\nexport class ValidationDelegate {\n private host: IHostValidation;\n\n constructor(host: IHostValidation) {\n this.host = host;\n }\n\n /**\n * Registers a control and all its children with the global MessageManager.\n */\n public registerObject(control: Control): void {\n if (this.host.getProperty(\"useMessageManager\")) {\n Messaging.registerObject(control, true); // true = recurse all children\n }\n }\n\n /**\n * Unregisters a control from the global MessageManager.\n */\n public unregisterObject(control: Control): void {\n if (this.host.getProperty(\"useMessageManager\")) {\n Messaging.unregisterObject(control);\n }\n }\n\n /**\n * Clears all messages from the global MessageManager.\n */\n public removeAllMessages(): void {\n if (this.host.getProperty(\"useMessageManager\")) {\n Messaging.removeAllMessages();\n }\n }\n\n /**\n * Pushes a validation message to the console, and optionally to the MessageManager.\n */\n public pushMessage(path: string, text: string): void {\n const targetPath = path ? `/${path.replace(/^\\//, \"\")}` : \"\";\n const displayText = path ? `Field '${path}': ${text}` : text;\n\n if (path) {\n Logger.warn(`[MetaUI Validation Error] ${displayText}`);\n } else {\n Logger.warn(`[MetaUI Validation Error] Global - ${text}`);\n }\n\n if (this.host.getProperty(\"useMessageManager\")) {\n sap.ui.require([\"sap/ui/core/message/Message\"], (MessageClass: any) => {\n const messageManager = Messaging;\n const stateManager = this.host.getStateManager();\n messageManager.addMessages(new MessageClass({\n message: displayText,\n type: \"Error\" as unknown,\n target: targetPath,\n processor: stateManager?.getModel()\n }));\n });\n }\n }\n\n /**\n * Imperatively invalidates a field and highlights it with an error message.\n */\n public addCustomError(fieldPath: string, message: string): void {\n const useMessageManager = this.host.getProperty(\"useMessageManager\") as boolean;\n const stateManager = this.host.getStateManager();\n if (useMessageManager && stateManager) {\n sap.ui.require([\"sap/ui/core/message/Message\"], (MessageClass: any) => {\n const messageManager = Messaging;\n messageManager.addMessages(new MessageClass({\n message: message,\n type: \"Error\" as unknown,\n target: `/${fieldPath.replace(/^\\//, \"\")}`,\n processor: stateManager.getModel()\n }));\n });\n }\n }\n\n /**\n * Reverts a custom error state on a field.\n */\n public clearCustomError(fieldPath: string): void {\n const useMessageManager = this.host.getProperty(\"useMessageManager\") as boolean;\n const stateManager = this.host.getStateManager();\n if (useMessageManager && stateManager) {\n const messageManager = Messaging;\n const messages = messageManager.getMessageModel().getData();\n const target = `/${fieldPath.replace(/^\\//, \"\")}`;\n\n const messageToRemove = messages.find((m: any) =>\n m.getTarget() === target && m.getMessageProcessor() && m.getMessageProcessor().getId() === stateManager.getModel().getId()\n );\n if (messageToRemove) {\n messageManager.removeMessages(messageToRemove);\n }\n }\n }\n\n /**\n * Triggers a visual Error Page (Crash Boundary) when generation catastrophically fails.\n */\n public mountCrashBoundary(error: Error): void {\n Logger.error(\"[MetaUI] Engine failed to generate layout. Preventing Launchpad crash.\", error.message, \"ValidationDelegate\");\n\n const errorPage = new MessagePage({\n text: \"UI Generation Failed\",\n description: \"The dynamic schema could not be rendered. Please check the Fiori console for diagnostic logs.\",\n icon: \"sap-icon://error\"\n });\n\n this.host.setAggregation(\"_content\", errorPage);\n }\n}\n"],"mappings":"AAAA,mMAISA,EAAMC,EAAA,UAYR,MAAMC,EAGTC,YAAYC,GACRC,KAAKD,KAAOA,CAChB,CAKOE,eAAeC,GAClB,GAAIF,KAAKD,KAAKI,YAAY,qBAAsB,CAC5CC,EAAUH,eAAeC,EAAS,KACtC,CACJ,CAKOG,iBAAiBH,GACpB,GAAIF,KAAKD,KAAKI,YAAY,qBAAsB,CAC5CC,EAAUC,iBAAiBH,EAC/B,CACJ,CAKOI,oBACH,GAAIN,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aO,WAAWa,SAEvH,GAAIL,EAAiB,CACjBhB,EAAesB,eAAeN,EAClC,CACJ,CACJ,CAKOO,mBAAmBC,GACtB/C,EAAO+C,MAAM,yEAA0EA,EAAMpB,QAAS,sBAEtG,MAAMqB,EAAY,IAAIC,EAAY,CAC9BnC,KAAM,uBACNoC,YAAa,gGACbC,KAAM,qBAGV9C,KAAKD,KAAKgD,eAAe,WAAYJ,EACzC,EACH,IAAAK,EAAA,CAAAC,WAAA,MAAAD,EAAAnD,qBAAA,OAAAmD,CAAA","ignoreList":[],"sourceRoot":"controls/host/delegates"}},{"offset":{"line":14,"column":0},"map":{"version":3,"names":["Registry","___Registry","OperatorRegistry","register","a","b","ConditionEngine","constructor","schema","this","plugins","Map","handleEvent","fieldKey","isValid","registerPlugin","bindingPath","plugin","set","destroy","clear","__exports","__esModule"],"sources":["ConditionEngine.ts"],"sourcesContent":["/**\n * @file ConditionEngine.ts\n * @description Evaluates dynamic rules to alter the schema in real-time.\n */\n\nimport { IPlugin } from \"../interfaces/IPlugin\";\nimport { ISchema } from \"../interfaces/ISchema\";\nimport { Registry } from \"./Registry\";\n\nexport type ConditionOperator = (a: any, b: any) => boolean;\n\nexport const OperatorRegistry = new Registry<ConditionOperator>(\"Operators\");\n\n// Register basic default operators\nOperatorRegistry.register(\"==\", (a, b) => a == b);\nOperatorRegistry.register(\"===\", (a, b) => a === b);\nOperatorRegistry.register(\"!=\", (a, b) => a != b);\nOperatorRegistry.register(\"!==\", (a, b) => a !== b);\nOperatorRegistry.register(\">\", (a, b) => a > b);\nOperatorRegistry.register(\"<\", (a, b) => a < b);\nOperatorRegistry.register(\">=\", (a, b) => a >= b);\nOperatorRegistry.register(\"<=\", (a, b) => a <= b);\n\n/**\n * Engine that listens to the EventBus and evaluates cross-field dependencies (e.g. visibleOn, enabledOn).\n * It delegates actual evaluations to the configurable `OperatorRegistry`.\n * \n * @namespace nz.co.siliconst.ui5.metaui.core\n * @public\n */\nexport class ConditionEngine {\n /** The active form schema being evaluated. */\n private schema: ISchema;\n /** The cached bound event handler reference for strict garbage collection. */\n private boundHandler: (event: IFieldChangeEvent) => void;\n\n /**\n * Initializes the ConditionEngine with the active schema.\n * @param schema The current UI layout schema.\n */\n constructor(schema: ISchema) {\n this.schema = schema;\n }\n\n\n\n /** Internal map tracking active plugins against their binding paths for real-time state updates. */\n private plugins: Map<string, IPlugin> = new Map();\n\n /**\n * Internal handler to evaluate business rules when a field is updated.\n * @param fieldKey The key of the field that was changed\n * @param isValid Whether the field is currently valid\n */\n public handleEvent(fieldKey: string, isValid: boolean): void {\n // Evaluate conditions via registered operators if a rule system is added later\n }\n\n /**\n * Registers a rendered plugin so the condition engine can push dynamic state updates to it.\n * \n * @param bindingPath The JSON path representing the field within the payload.\n * @param plugin The instantiated plugin handling the field.\n */\n public registerPlugin(bindingPath: string, plugin: IPlugin): void {\n this.plugins.set(bindingPath, plugin);\n }\n\n /**\n * Cleans up listeners to prevent memory leaks on destruction.\n */\n public destroy(): void {\n this.plugins.clear();\n }\n}\n"],"mappings":"AAAA,4GAAA,MAOSA,EAAQC,EAAA,YAIV,MAAMC,EAAmB,IAAIF,EAA4B,aAGhEE,EAAiBC,SAAS,KAAM,CAACC,EAAGC,IAAMD,GAAKC,GAC/CH,EAAiBC,SAAS,MAAO,CAACC,EAAGC,IAAMD,IAAMC,GACjDH,EAAiBC,SAAS,KAAM,CAACC,EAAGC,IAAMD,GAAKC,GAC/CH,EAAiBC,SAAS,MAAO,CAACC,EAAGC,IAAMD,IAAMC,GACjDH,EAAiBC,SAAS,IAAK,CAACC,EAAGC,IAAMD,EAAIC,GAC7CH,EAAiBC,SAAS,IAAK,CAACC,EAAGC,IAAMD,EAAIC,GAC7CH,EAAiBC,SAAS,KAAM,CAACC,EAAGC,IAAMD,GAAKC,GAC/CH,EAAiBC,SAAS,KAAM,CAACC,EAAGC,IAAMD,GAAKC,GASxC,MAAMC,EAUTC,YAAYC,GACRC,KAAKD,OAASA,CAClB,CAKQE,QAAgC,IAAIC,IAOrCC,YAAYC,EAAkBC,GACjC,CASGC,eAAeC,EAAqBC,GACvCR,KAAKC,QAAQQ,IAAIF,EAAaC,EAClC,CAKOE,UACHV,KAAKC,QAAQU,OACjB,EACH,IAAAC,EAAA,CAAAC,WAAA,MAAAD,EAAAnB,mBAAAmB,EAAAf,kBAAA,OAAAe,CAAA","ignoreList":[],"sourceRoot":"core"}},{"offset":{"line":15,"column":0},"map":{"version":3,"names":["DefaultLayoutGenerator","ensureLayout","schema","uiLayout","Array","isArray","length","type","props","items","properties","Object","keys","elements","this","generateElementsFromProperties","filter","e","label","title","basePath","key","prop","currentPath","push","ui","scope","__exports","__esModule"],"sources":["DefaultLayoutGenerator.ts"],"sourcesContent":["/**\n * @file DefaultLayoutGenerator.ts\n * @description Automatically synthesizes a default UI layout for schemas that lack an explicit mapping.\n */\n\nimport { ISchema, ILayoutElement } from \"../interfaces/ISchema\";\n\n/**\n * Encapsulates the logic to dynamically build a safe, default layout orchestration\n * when the developer or backend fails to provide an explicit `uiLayout`.\n * \n * By elevating this into a dedicated utility, we avoid polluting layout engines\n * (like FormLayout or TableLayout) with structural inference responsibilities.\n * \n * @namespace nz.co.siliconst.ui5.metaui.core\n * @public\n */\nexport class DefaultLayoutGenerator {\n /**\n * Inspects a schema. If it has properties but no `uiLayout`, it synthesizes a default.\n * @param schema The ISchema dictionary.\n * @returns boolean True if a layout was synthesized, false if it already existed or was empty.\n */\n public static ensureLayout(schema: ISchema): boolean {\n // If it already has a valid array, do nothing\n if (schema.uiLayout && Array.isArray(schema.uiLayout) && schema.uiLayout.length > 0) {\n return false;\n }\n\n const isArray = schema.type === \"array\";\n const props = isArray ? schema.items?.properties : schema.properties;\n\n if (!props || Object.keys(props).length === 0) {\n return false; // Nothing to map\n }\n\n const elements = this.generateElementsFromProperties(props, \"#/properties\");\n\n if (isArray) {\n // Table layouts expect an array of flat Controls at the root uiLayout\n // For tables, we flatten the deep elements or just render the root level\n // To keep it safe, we'll just use the flat elements for tables\n schema.uiLayout = elements.filter(e => e.type === \"Control\");\n } else {\n // Form layouts expect a grouped structure\n schema.uiLayout = [\n {\n type: \"Group\",\n label: schema.title,\n elements: elements\n }\n ];\n }\n\n return true;\n }\n\n private static generateElementsFromProperties(props: any, basePath: string): ILayoutElement[] {\n const elements: ILayoutElement[] = [];\n for (const key of Object.keys(props)) {\n const prop = props[key];\n const currentPath = `${basePath}/${key}`;\n\n if (prop.type === \"object\" && prop.properties) {\n elements.push({\n type: \"Group\",\n label: prop.ui?.label || key,\n elements: this.generateElementsFromProperties(prop.properties, `${currentPath}/properties`)\n });\n } else {\n elements.push({\n type: \"Control\",\n scope: currentPath\n });\n }\n }\n return elements;\n }\n}\n"],"mappings":"AAAA,sGAiBO,MAAMA,EAMT,mBAAcC,CAAaC,GAEvB,GAAIA,EAAOC,UAAYC,MAAMC,QAAQH,EAAOC,WAAaD,EAAOC,SAASG,OAAS,EAAG,CACjF,OAAO,KACX,CAEA,MAAMD,EAAUH,EAAOK,OAAS,QAChC,MAAMC,EAAQH,EAAUH,EAAOO,OAAOC,WAAaR,EAAOQ,WAE1D,IAAKF,GAASG,OAAOC,KAAKJ,GAAOF,SAAW,EAAG,CAC3C,OAAO,KACX,CAEA,MAAMO,EAAWC,KAAKC,+BAA+BP,EAAO,gBAE5D,GAAIH,EAAS,CAITH,EAAOC,SAAWU,EAASG,OAAOC,GAAKA,EAAEV,OAAS,UACtD,KAAO,CAEHL,EAAOC,SAAW,CACd,CACII,KAAM,QACNW,MAAOhB,EAAOiB,MACdN,SAAUA,GAGtB,CAEA,OAAO,IACX,CAEA,qCAAeE,CAA+BP,EAAYY,GACtD,MAAMP,EAA6B,GACnC,IAAK,MAAMQ,KAAOV,OAAOC,KAAKJ,GAAQ,CAClC,MAAMc,EAAOd,EAAMa,GACnB,MAAME,EAAc,GAAGH,KAAYC,IAEnC,GAAIC,EAAKf,OAAS,UAAYe,EAAKZ,WAAY,CAC3CG,EAASW,KAAK,CACVjB,KAAM,QACNW,MAAOI,EAAKG,IAAIP,OAASG,EACzBR,SAAUC,KAAKC,+BAA+BO,EAAKZ,WAAY,GAAGa,iBAE1E,KAAO,CACHV,EAASW,KAAK,CACVjB,KAAM,UACNmB,MAAOH,GAEf,CACJ,CACA,OAAOV,CACX,EACH,IAAAc,EAAA,CAAAC,WAAA,MAAAD,EAAA3B,yBAAA,OAAA2B,CAAA","ignoreList":[],"sourceRoot":"core"}},{"offset":{"line":16,"column":0},"map":{"version":3,"names":["ConditionEngine","___ConditionEngine","PluginRegistry","___PluginRegistry","Logger","___utils_Logger","DefaultLayoutGenerator","___DefaultLayoutGenerator","Engine","conditionEngine","activePlugins","isDisplayMode","constructor","displayMode","this","build","schema","model","modelName","onSubmit","engineScopeId","onChange","activeModel","isValid","fieldKey","errorMessage","controlId","handleEvent","ensureLayout","warn","layoutStrategy","type","layoutManager","layoutRegistry","getStrict","render","error","msg","message","showErrorPopup","Text","text","generateField","fieldMeta","bindingPath","isTemplate","plugin","getInstance","getPlugin","ui","widget","setDisplayMode","push","path","scopeId","undefined","control","registerPlugin","generateLayout","validateAll","errors","item","result","validate","replace","name","destroy","messageManager","Messaging","existingMessages","getMessageModel","getData","messagesToRemove","targetPath","matched","filter","getTarget","getMessageProcessor","getId","length","removeMessages","__exports","__esModule"],"sources":["Engine.ts"],"sourcesContent":["/**\n * @file Engine.ts\n * @description The central orchestrator that routes data between the Layout Factory and Plugin Registry (v2).\n */\n\nimport { ISchema, IPropertyMetadata } from \"../interfaces/ISchema\";\nimport { ILayoutManager } from \"../interfaces/ILayoutManager\";\nimport { IPlugin, IPluginValidationResult } from \"../interfaces/IPlugin\";\nimport { ConditionEngine } from \"./ConditionEngine\";\nimport { PluginRegistry } from \"./PluginRegistry\";\nimport Control from \"sap/ui/core/Control\";\nimport VBox from \"sap/m/VBox\";\nimport Text from \"sap/m/Text\";\nimport { Registry } from \"./Registry\";\nimport { Logger } from \"../utils/Logger\";\nimport { DefaultLayoutGenerator } from \"./DefaultLayoutGenerator\";\nimport Core from \"sap/ui/core/Core\";\nimport Messaging from \"sap/ui/core/Messaging\";\n\n/**\n * The Engine is responsible for translating a normalized schema into a physical UI5 layout.\n * It delegates layout generation to the configured `LayoutManager` and field generation to the `PluginRegistry`.\n * It is NOT a God Class; it strictly routes execution flow and tracks active plugins for validation.\n * It embodies the \"Plugin-First Philosophy\" by routing all complex field and layout rendering\n * through discrete, decoupled plugins rather than handling native overrides.\n * \n * @namespace nz.co.siliconst.ui5.metaui.core\n * @public\n */\nexport class Engine {\n /** Global registry of all available layout strategies (e.g. Form, Table, Wizard). */\n public static layoutRegistry: Registry<ILayoutManager>;\n /** Handles dynamic conditional logic across the active form. */\n private conditionEngine: ConditionEngine | null = null;\n \n /** Array of all instantiated plugins generated during the current build. */\n private activePlugins: { plugin: IPlugin, path: string }[] = [];\n\n /** Deterministic scope ID injected by the host control to prevent clone collisions. */\n public engineScopeId?: string;\n \n private activeModel?: sap.ui.model.Model;\n \n /** Tracks whether the entire engine is running in Read-Only Display mode. */\n public readonly isDisplayMode: boolean = false;\n\n constructor(displayMode: boolean = false) {\n this.isDisplayMode = displayMode;\n }\n \n /**\n * Bootstraps the layout generation process by resolving the correct layout strategy.\n * \n * @param schema The normalized JSON schema representing the view.\n * @param model The active StateManager JSONModel instance.\n * @param modelName The UI5 model alias used for isolation.\n * @param onSubmit Callback fired when form is submitted.\n * @param engineScopeId Deterministic scope ID for this engine instance.\n * @param onChange Callback fired when field values change.\n * @returns The generated root UI5 Control container.\n */\n public build(schema: ISchema, model: sap.ui.model.Model, modelName: string = \"meta\", onSubmit?: () => void, engineScopeId?: string, onChange?: (isValid: boolean, fieldKey?: string, errorMessage?: string, controlId?: string) => void): Control {\n this.conditionEngine = new ConditionEngine(schema);\n this.activePlugins = [];\n this.activeModel = model;\n this.engineScopeId = engineScopeId;\n this.onChange = (isValid: boolean, fieldKey?: string, errorMessage?: string, controlId?: string) => {\n if (this.conditionEngine && fieldKey) {\n this.conditionEngine.handleEvent(fieldKey, isValid);\n }\n if (onChange) {\n onChange(isValid, fieldKey, errorMessage, controlId);\n }\n };\n \n try {\n // Intercept and synthesize a default layout if the developer/backend failed to provide one\n if (DefaultLayoutGenerator.ensureLayout(schema)) {\n Logger.warn(\"[MetaUI Engine] Missing 'uiLayout' array in schema. Synthesized a default layout mapping to prevent a blank render.\");\n }\n\n const layoutStrategy = schema.layoutStrategy || (schema.type === \"array\" ? \"table\" : \"form\");\n const layoutManager = Engine.layoutRegistry.getStrict(layoutStrategy);\n \n return layoutManager.render(schema, modelName, this, onSubmit);\n } catch (error) {\n const msg = (error as Error).message;\n Logger.error(\"[MetaUI Engine] Critical error during layout generation\", msg);\n Logger.showErrorPopup(`Engine failed to generate the layout.\\n\\nDetails: ${msg}`);\n return new Text({ text: \"Critical Layout Error\" });\n }\n }\n\n /**\n * Instantiates the correct plugin for a specific field based on type and widget hints,\n * and tracks the plugin for global validation.\n * \n * @param fieldMeta The metadata schema specific to the field.\n * @param bindingPath The JSON path representing the field within the payload.\n * @param modelName The UI5 JSONModel name used for data binding.\n * @returns The generated UI5 Control for the field.\n */\n public generateField(fieldMeta: IPropertyMetadata, bindingPath: string, modelName: string, isTemplate: boolean = false): Control {\n try {\n const plugin = PluginRegistry.getInstance().getPlugin(fieldMeta.type || \"string\", fieldMeta.ui?.widget);\n plugin.setDisplayMode(this.isDisplayMode);\n \n if (!isTemplate) {\n this.activePlugins.push({ plugin, path: bindingPath });\n }\n const scopeId = isTemplate ? undefined : this.engineScopeId;\n const control = plugin.render(fieldMeta, bindingPath, modelName, scopeId, this.onChange);\n \n if (this.conditionEngine) {\n this.conditionEngine.registerPlugin(bindingPath, plugin);\n }\n \n return control;\n } catch (error) {\n const msg = (error as Error).message;\n Logger.error(`[MetaUI Engine] Failed to generate field at ${bindingPath}`, msg);\n Logger.showErrorPopup(`Failed to generate field '${bindingPath}'.\\n\\nDetails: ${msg}`);\n return new Text({ text: `[Error generating field ${bindingPath}]` });\n }\n }\n\n /**\n * Generates a sub-layout (like an embedded table or nested form) without \n * destroying the current Engine state or Condition tracking.\n * \n * @param schema The normalized JSON schema representing the view.\n * @param modelName The UI5 JSONModel name used for data binding (defaults to \"meta\").\n * @param bindingPath Optional path to bind the sub-layout to a specific array/object property.\n * @returns The generated root UI5 Control container.\n */\n public generateLayout(schema: ISchema, modelName: string, bindingPath?: string): Control {\n try {\n const layoutStrategy = schema.layoutStrategy || (schema.type === \"array\" ? \"table\" : \"form\");\n const layoutManager = Engine.layoutRegistry.getStrict(layoutStrategy);\n return layoutManager.render(schema, modelName, this, undefined, bindingPath);\n } catch (error) {\n const msg = (error as Error).message;\n Logger.error(`[MetaUI Engine] Critical error generating sub-layout for ${bindingPath}`, msg);\n Logger.showErrorPopup(`Engine failed to generate a sub-layout.\\n\\nDetails: ${msg}`);\n return new Text({ text: \"Critical Sub-Layout Error\" });\n }\n }\n\n /**\n * Iterates through all active plugins and triggers their internal validation pipelines.\n * \n * @returns {IPluginValidationResult[]} Array of validation error objects. Empty array if valid.\n */\n public validateAll(): IPluginValidationResult[] {\n const errors: IPluginValidationResult[] = [];\n for (const item of this.activePlugins) {\n const result = item.plugin.validate();\n if (!result.isValid) {\n // Ensure the path is bound to the error so GeneratorHost knows where to target it\n result.fieldKey = result.fieldKey || item.path.replace(/^\\//, \"\");\n errors.push(result);\n // Add console log to find which plugin fails silently\n Logger.error(\"[MetaUI Validation] Plugin failed validation silently:\", item.path || item.plugin.constructor.name);\n }\n }\n return errors;\n }\n\n /**\n * Cleans up internal state and destroys the condition engine to prevent memory leaks.\n */\n public destroy(): void {\n if (this.conditionEngine) {\n this.conditionEngine.destroy();\n this.conditionEngine = null;\n }\n \n // ------------------------------------------------------------------------\n // Ghost Error Prevention\n // Flush MessageManager for active plugins before destroying their controls\n // ------------------------------------------------------------------------\n const messageManager = Messaging;\n const existingMessages = messageManager.getMessageModel().getData();\n const messagesToRemove: any[] = [];\n \n for (const item of this.activePlugins) {\n if (this.activeModel) {\n const targetPath = `/${item.path.replace(/^\\//, \"\")}`;\n const matched = existingMessages.filter((msg: any) => \n msg.getTarget() === targetPath && msg.getMessageProcessor() && msg.getMessageProcessor().getId() === this.activeModel.getId()\n );\n messagesToRemove.push(...matched);\n }\n if (typeof item.plugin.destroy === \"function\") {\n item.plugin.destroy();\n }\n }\n \n if (messagesToRemove.length > 0) {\n messageManager.removeMessages(messagesToRemove);\n }\n \n this.activePlugins = [];\n }\n}\n"],"mappings":"AAAA,yNAAA,MAQSA,EAAeC,EAAA,yBACfC,EAAcC,EAAA,wBAKdC,EAAMC,EAAA,gBACNC,EAAsBC,EAAA,0BAcxB,MAAMC,EAIDC,gBAA0C,KAG1CC,cAAqD,GAQ7CC,cAAyB,MAEzCC,YAAYC,EAAuB,OAC/BC,KAAKH,cAAgBE,CACzB,CAaOE,MAAMC,EAAiBC,EAA2BC,EAAoB,OAAQC,EAAuBC,EAAwBC,GAChIP,KAAKL,gBAAkB,IAAIT,EAAgBgB,GAC3CF,KAAKJ,cAAgB,GACrBI,KAAKQ,YAAcL,EACnBH,KAAKM,cAAgBA,EACrBN,KAAKO,SAAW,CAACE,EAAkBC,EAAmBC,EAAuBC,KACzE,GAAIZ,KAAKL,iBAAmBe,EAAU,CAClCV,KAAKL,gBAAgBkB,YAAYH,EAAUD,EAC/C,CACA,GAAIF,EAAU,CACVA,EAASE,EAASC,EAAUC,EAAcC,EAC9C,GAGJ,IAEI,GAAIpB,EAAuBsB,aAAaZ,GAAS,CAC7CZ,EAAOyB,KAAK,sHAChB,CAEA,MAAMC,EAAiBd,EAAOc,iBAAmBd,EAAOe,OAAS,QAAU,QAAU,QACrF,MAAMC,EAAgBxB,EAAOyB,eAAeC,UAAUJ,GAEtD,OAAOE,EAAcG,OAAOnB,EAAQE,EAAWJ,KAAMK,EACzD,CAAE,MAAOiB,GACL,MAAMC,EAAOD,EAAgBE,QAC7BlC,EAAOgC,MAAM,0DAA2DC,GACxEjC,EAAOmC,eAAe,qDAAqDF,KAC3E,OAAO,IAAIG,EAAK,CAAEC,KAAM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AKR,KAAKW,QAAQ,MAAO,IAC9DJ,EAAOR,KAAKU,GAEZ1D,EAAOgC,MAAM,yDAA0DyB,EAAKR,MAAQQ,EAAKf,OAAOlC,YAAYqD,KAChH,CACJ,CACA,OAAOL,CACX,CAKOM,UACH,GAAIpD,KAAKL,gBAAiB,CACtBK,KAAKL,gBAAgByD,UACrBpD,KAAKL,gBAAkB,IAC3B,CAMA,MAAM0D,EAAiBC,EACvB,MAAMC,EAAmBF,EAAeG,kBAAkBC,UAC1D,MAAMC,EAA0B,GAEhC,IAAK,MAAMX,KAAQ/C,KAAKJ,cAAe,CACnC,GAAII,KAAKQ,YAAa,CAClB,MAAMmD,EAAa,IAAIZ,EAAKR,KAAKW,QAAQ,MAAO,MAChD,MAAMU,EAAUL,EAAiBM,OAAQtC,GACrCA,EAAIuC,cAAgBH,GAAcpC,EAAIwC,uBAAyBxC,EAAIwC,sBAAsBC,UAAYhE,KAAKQ,YAAYwD,SAE1HN,EAAiBpB,QAAQsB,EAC7B,CACA,UAAWb,EAAKf,OAAOoB,UAAY,WAAY,CAC3CL,EAAKf,OAAOoB,SAChB,CACJ,CAEA,GAAIM,EAAiBO,OAAS,EAAG,CAC7BZ,EAAea,eAAeR,EAClC,CAEA1D,KAAKJ,cAAgB,EACzB,EACH,IAAAuE,EAAA,CAAAC,WAAA,MAAAD,EAAAzE,SAAA,OAAAyE,CAAA","ignoreList":[],"sourceRoot":"core"}},{"offset":{"line":17,"column":0},"map":{"version":3,"names":["Registry","___Registry","FormLayout","___layouts_FormLayout","TableLayout","___layouts_TableLayout","WizardLayout","___layouts_WizardLayout","CompactLayout","___layouts_CompactLayout","Engine","___Engine","LayoutRegistry","register","layoutRegistry","__exports","__esModule"],"sources":["LayoutRegistry.ts"],"sourcesContent":["/**\n * @file LayoutRegistry.ts\n * @description Centralized registry for all available layout managers (e.g. Form, Table, Wizard).\n */\nimport { Registry } from \"./Registry\";\nimport { ILayoutManager } from \"../interfaces/ILayoutManager\";\nimport { FormLayout } from \"../layouts/FormLayout\";\nimport { TableLayout } from \"../layouts/TableLayout\";\nimport { WizardLayout } from \"../layouts/WizardLayout\";\nimport { CompactLayout } from \"../layouts/CompactLayout\";\nimport { Engine } from \"./Engine\";\n\n/** \n * The globally exposed registry containing instantiations of the layout strategies.\n * It is injected directly into the Engine to avoid circular dependencies.\n * \n * @public\n */\nexport const LayoutRegistry = new Registry<ILayoutManager>(\"Layouts\");\n\nLayoutRegistry.register(\"form\", new FormLayout());\nLayoutRegistry.register(\"table\", new TableLayout());\nLayoutRegistry.register(\"wizard\", new WizardLayout());\nLayoutRegistry.register(\"compact\", new CompactLayout());\n\nEngine.layoutRegistry = LayoutRegistry;\n"],"mappings":"AAAA,sOAAA,MAISA,EAAQC,EAAA,kBAERC,EAAUC,EAAA,oBACVC,EAAWC,EAAA,qBACXC,EAAYC,EAAA,sBACZC,EAAaC,EAAA,uBACbC,EAAMC,EAAA,UAQR,MAAMC,EAAiB,IAAIZ,EAAyB,WAE3DY,EAAeC,SAAS,OAAQ,IAAIX,GACpCU,EAAeC,SAAS,QAAS,IAAIT,GACrCQ,EAAeC,SAAS,SAAU,IAAIP,GACtCM,EAAeC,SAAS,UAAW,IAAIL,GAEvCE,EAAOI,eAAiBF,EAAe,IAAAG,EAAA,CAAAC,WAAA,MAAAD,EAAAH,iBAAA,OAAAG,CAAA","ignoreList":[],"sourceRoot":"core"}},{"offset":{"line":18,"column":0},"map":{"version":3,"names":["Registry","___Registry","PatternValidatorPlugin","___plugins_validators_PatternValidatorPlugin","MinLengthValidatorPlugin","___plugins_validators_MinLengthValidatorPlugin","RangeValidatorPlugin","___plugins_validators_RangeValidatorPlugin","UrlValidatorPlugin","___plugins_validators_UrlValidatorPlugin","IbanValidatorPlugin","___plugins_validators_IbanValidatorPlugin","EmailValidatorPlugin","___plugins_validators_EmailValidatorPlugin","DateFormatterPlugin","___plugins_formatters_DateFormatterPlugin","PhoneFormatterPlugin","___plugins_formatters_PhoneFormatterPlugin","TextCaseFormatterPlugin","___plugins_formatters_TextCaseFormatterPlugin","Logger","___utils_Logger","RequiredValidator","validate","parsedValue","args","undefined","isValid","errorMessage","MaxLengthValidator","length","PipelineManager","formatters","parsers","validators","constructor","this","register","executeValidation","requestedValidators","argsMap","rule","validator","get","result","warn","GlobalPipeline","__exports","__esModule"],"sources":["PipelineManager.ts"],"sourcesContent":["/**\n * @file PipelineManager.ts\n * @description Central manager for the data manipulation pipeline. \n * Orchestrates Formatting, Parsing, and Validating data using the generic Registry.\n */\n\nimport { Registry } from \"./Registry\";\nimport { IFormatter, IParser, IValidator, IValidationResult } from \"../interfaces/IPipeline\";\nimport { PatternValidatorPlugin } from \"../plugins/validators/PatternValidatorPlugin\";\nimport { MinLengthValidatorPlugin } from \"../plugins/validators/MinLengthValidatorPlugin\";\nimport { RangeValidatorPlugin } from \"../plugins/validators/RangeValidatorPlugin\";\nimport { UrlValidatorPlugin } from \"../plugins/validators/UrlValidatorPlugin\";\nimport { IbanValidatorPlugin } from \"../plugins/validators/IbanValidatorPlugin\";\nimport { EmailValidatorPlugin } from \"../plugins/validators/EmailValidatorPlugin\";\nimport { DateFormatterPlugin } from \"../plugins/formatters/DateFormatterPlugin\";\nimport { PhoneFormatterPlugin } from \"../plugins/formatters/PhoneFormatterPlugin\";\nimport { TextCaseFormatterPlugin } from \"../plugins/formatters/TextCaseFormatterPlugin\";\nimport { Logger } from \"../utils/Logger\";\n\n// --- Built-in Default Validators ---\nclass RequiredValidator implements IValidator {\n validate(parsedValue: unknown, args?: unknown): IValidationResult {\n if (parsedValue === null || parsedValue === undefined || parsedValue === \"\") {\n return { isValid: false, errorMessage: \"This field is required.\" };\n }\n return { isValid: true };\n }\n}\n\nclass MaxLengthValidator implements IValidator {\n validate(parsedValue: unknown, args?: unknown): IValidationResult {\n if (typeof parsedValue === \"string\" && args && typeof args === \"number\") {\n if (parsedValue.length > args) {\n return { isValid: false, errorMessage: `Maximum length is ${args} characters.` };\n }\n }\n return { isValid: true };\n }\n}\n\n\n/**\n * The core engine responsible for marshalling data through the validation, formatting, and parsing phases.\n * Pluggable design allows new validators to be registered dynamically.\n * \n * @namespace nz.co.siliconst.ui5.metaui.core\n * @public\n */\nexport class PipelineManager {\n /** Registry of data formatters applied before pushing to the UI. */\n public readonly formatters: Registry<IFormatter> = new Registry<IFormatter>(\"Formatters\");\n /** Registry of data parsers applied when pulling data from the UI. */\n public readonly parsers: Registry<IParser> = new Registry<IParser>(\"Parsers\");\n /** Registry of business logic validators. */\n public readonly validators: Registry<IValidator> = new Registry<IValidator>(\"Validators\");\n\n /**\n * Bootstraps the PipelineManager with default validators (required, maxLength, email).\n */\n constructor() {\n // Register default validators\n this.validators.register(\"required\", new RequiredValidator());\n this.validators.register(\"maxLength\", new MaxLengthValidator());\n this.validators.register(\"pattern\", new PatternValidatorPlugin());\n this.validators.register(\"minLength\", new MinLengthValidatorPlugin());\n this.validators.register(\"range\", new RangeValidatorPlugin());\n this.validators.register(\"url\", new UrlValidatorPlugin());\n this.validators.register(\"iban\", new IbanValidatorPlugin());\n this.validators.register(\"email\", new EmailValidatorPlugin());\n\n // Register default formatters\n this.formatters.register(\"date\", new DateFormatterPlugin());\n this.formatters.register(\"phone\", new PhoneFormatterPlugin());\n this.formatters.register(\"textCase\", new TextCaseFormatterPlugin());\n }\n\n /**\n * Executes the validation pipeline sequentially. Fails fast on the first encountered error.\n * \n * @param parsedValue The raw extracted value from the UI control.\n * @param requestedValidators Array of validation rule keys (e.g. ['required', 'email']).\n * @param argsMap Optional map of parameters required by specific rules (e.g. { maxLength: 50 }).\n * @returns {IValidationResult} The final result state and any associated error message.\n */\n public executeValidation(parsedValue: unknown, requestedValidators: string[], argsMap?: Record<string, any>): IValidationResult {\n for (const rule of requestedValidators) {\n const validator = this.validators.get(rule);\n if (validator) {\n const args = argsMap ? argsMap[rule] : undefined;\n const result = validator.validate(parsedValue, args);\n if (!result.isValid) {\n return result; // Fast fail on first error\n }\n } else {\n Logger.warn(`[MetaUI] PipelineManager: Requested validator '${rule}' not found in registry.`);\n }\n }\n return { isValid: true };\n }\n}\n\n/** \n * Singleton instance for global access to the active validation pipeline. \n * @public \n */\nexport const GlobalPipeline = new PipelineManager();\n"],"mappings":"AAAA,4iBAAA,MAMSA,EAAQC,EAAA,kBAERC,EAAsBC,EAAA,gCACtBC,EAAwBC,EAAA,kCACxBC,EAAoBC,EAAA,8BACpBC,EAAkBC,EAAA,4BAClBC,EAAmBC,EAAA,6BACnBC,EAAoBC,EAAA,8BACpBC,EAAmBC,EAAA,6BACnBC,EAAoBC,EAAA,8BACpBC,EAAuBC,EAAA,iCACvBC,EAAMC,EAAA,UAGf,MAAMC,EACFC,SAASC,EAAsBC,GAC3B,GAAID,IAAgB,MAAQA,IAAgBE,WAAaF,IAAgB,GAAI,CACzE,MAAO,CAAEG,QAAS,MAAOC,aAAc,0BAC3C,CACA,MAAO,CAAED,QAAS,KACtB,EAGJ,MAAME,EACFN,SAASC,EAAsBC,GAC3B,UAAWD,IAAgB,UAAYC,UAAeA,IAAS,SAAU,CACrE,GAAID,EAAYM,OAASL,EAAM,CAC3B,MAAO,CAAEE,QAAS,MAAOC,aAAc,qBAAqBH,gBAChE,CACJ,CACA,MAAO,CAAEE,QAAS,KACtB,EAWG,MAAMI,EAEOC,WAAmC,IAAIhC,EAAqB,cAE5DiC,QAA6B,IAAIjC,EAAkB,WAEnDkC,WAAmC,IAAIlC,EAAqB,cAK5EmC,cAEIC,KAAKF,WAAWG,SAAS,WAAY,IAAIf,GACzCc,KAAKF,WAAWG,SAAS,YAAa,IAAIR,GAC1CO,KAAKF,WAAWG,SAAS,UAAW,IAAInC,GACxCkC,KAAKF,WAAWG,SAAS,YAAa,IAAIjC,GAC1CgC,KAAKF,WAAWG,SAAS,QAAS,IAAI/B,GACtC8B,KAAKF,WAAWG,SAAS,MAAO,IAAI7B,GACpC4B,KAAKF,WAAWG,SAAS,OAAQ,IAAI3B,GACrC0B,KAAKF,WAAWG,SAAS,QAAS,IAAIzB,GAGtCwB,KAAKJ,WAAWK,SAAS,OAAQ,IAAIvB,GACrCsB,KAAKJ,WAAWK,SAAS,QAAS,IAAIrB,GACtCoB,KAAKJ,WAAWK,SAAS,WAAY,IAAInB,EAC7C,CAUOoB,kBAAkBd,EAAsBe,EAA+BC,GAC1E,IAAK,MAAMC,KAAQF,EAAqB,CACpC,MAAMG,EAAYN,KAAKF,WAAWS,IAAIF,GACtC,GAAIC,EAAW,CACX,MAAMjB,EAAOe,EAAUA,EAAQC,GAAQf,UACvC,MAAMkB,EAASF,EAAUnB,SAASC,EAAaC,GAC/C,IAAKmB,EAAOjB,QAAS,CACjB,OAAOiB,CACX,CACJ,KAAO,CACHxB,EAAOyB,KAAK,kDAAkDJ,4BAClE,CACJ,CACA,MAAO,CAAEd,QAAS,KACtB,EAOG,MAAMmB,EAAiB,IAAIf,EAAkB,IAAAgB,EAAA,CAAAC,WAAA,MAAAD,EAAAhB,kBAAAgB,EAAAD,iBAAA,OAAAC,CAAA","ignoreList":[],"sourceRoot":"core"}},{"offset":{"line":19,"column":0},"map":{"version":3,"names":["Registry","___Registry","Logger","___utils_Logger","StringPlugin","___plugins_controls_StringPlugin","NumberPlugin","___plugins_controls_NumberPlugin","DatePlugin","___plugins_controls_DatePlugin","TimePlugin","___plugins_controls_TimePlugin","DateTimePlugin","___plugins_controls_DateTimePlugin","BooleanPlugin","___plugins_controls_BooleanPlugin","SwitchPlugin","___plugins_controls_SwitchPlugin","ArrayPlugin","___plugins_controls_ArrayPlugin","ObjectPlugin","___plugins_controls_ObjectPlugin","DropdownPlugin","___plugins_controls_DropdownPlugin","TextAreaPlugin","___plugins_controls_TextAreaPlugin","CodeEditorPlugin","___plugins_controls_CodeEditorPlugin","FileUploaderPlugin","___plugins_controls_FileUploaderPlugin","MultiSelectPlugin","___plugins_controls_MultiSelectPlugin","SliderPlugin","___plugins_controls_SliderPlugin","RatingIndicatorPlugin","___plugins_controls_RatingIndicatorPlugin","MessageStripPlugin","___plugins_controls_MessageStripPlugin","CameraPlugin","___plugins_controls_CameraPlugin","SignaturePlugin","___plugins_controls_SignaturePlugin","GeolocationPlugin","___plugins_controls_GeolocationPlugin","BarcodeScannerPlugin","___plugins_controls_BarcodeScannerPlugin","VoiceInputPlugin","___plugins_controls_VoiceInputPlugin","RichTextPlugin","___plugins_controls_RichTextPlugin","UrlNavigationActionPlugin","___plugins_actions_UrlNavigationActionPlugin","SubmitFormActionPlugin","___plugins_actions_SubmitFormActionPlugin","ODataListBindingPlugin","___plugins_datasources_ODataListBindingPlugin","RemoteDropdownPlugin","___plugins_datasources_RemoteDropdownPlugin","PluginRegistry","registry","constructor","this","register","getInstance","instance","type","pluginConstructor","widgetName","key","getPlugin","PluginClass","get","msg","error","showErrorPopup","Error","message","__exports","__esModule"],"sources":["PluginRegistry.ts"],"sourcesContent":["/**\n * @file PluginRegistry.ts\n * @description Centralized hub for mapping UI5 controls to SAP schema data types.\n * Enforces the Registry Pattern to decouple the core engine from specific UI5 control implementations.\n */\n\nimport { IPlugin } from \"../interfaces/IPlugin\";\nimport { FieldType } from \"../interfaces/ISchema\";\n\nimport { Registry } from \"./Registry\";\nimport { Logger } from \"../utils/Logger\";\n\nimport { StringPlugin } from \"../plugins/controls/StringPlugin\";\nimport { NumberPlugin } from \"../plugins/controls/NumberPlugin\";\nimport { DatePlugin } from \"../plugins/controls/DatePlugin\";\nimport { TimePlugin } from \"../plugins/controls/TimePlugin\";\nimport { DateTimePlugin } from \"../plugins/controls/DateTimePlugin\";\nimport { BooleanPlugin } from \"../plugins/controls/BooleanPlugin\";\nimport { SwitchPlugin } from \"../plugins/controls/SwitchPlugin\";\nimport { ArrayPlugin } from \"../plugins/controls/ArrayPlugin\";\nimport { ObjectPlugin } from \"../plugins/controls/ObjectPlugin\";\nimport { DropdownPlugin } from \"../plugins/controls/DropdownPlugin\";\nimport { TextAreaPlugin } from \"../plugins/controls/TextAreaPlugin\";\nimport { CodeEditorPlugin } from \"../plugins/controls/CodeEditorPlugin\";\n\n// New Phase 1 Controls\nimport { FileUploaderPlugin } from \"../plugins/controls/FileUploaderPlugin\";\nimport { MultiSelectPlugin } from \"../plugins/controls/MultiSelectPlugin\";\nimport { SliderPlugin } from \"../plugins/controls/SliderPlugin\";\nimport { RatingIndicatorPlugin } from \"../plugins/controls/RatingIndicatorPlugin\";\nimport { MessageStripPlugin } from \"../plugins/controls/MessageStripPlugin\";\n\n// New Phase 5 Hardware / Base64 Plugins\nimport { CameraPlugin } from \"../plugins/controls/CameraPlugin\";\nimport { SignaturePlugin } from \"../plugins/controls/SignaturePlugin\";\nimport { GeolocationPlugin } from \"../plugins/controls/GeolocationPlugin\";\nimport { BarcodeScannerPlugin } from \"../plugins/controls/BarcodeScannerPlugin\";\nimport { VoiceInputPlugin } from \"../plugins/controls/VoiceInputPlugin\";\nimport { RichTextPlugin } from \"../plugins/controls/RichTextPlugin\";\n\n// New Phase 4 Actions & Datasources\nimport { UrlNavigationActionPlugin } from \"../plugins/actions/UrlNavigationActionPlugin\";\nimport { SubmitFormActionPlugin } from \"../plugins/actions/SubmitFormActionPlugin\";\nimport { ODataListBindingPlugin } from \"../plugins/datasources/ODataListBindingPlugin\";\nimport { RemoteDropdownPlugin } from \"../plugins/datasources/RemoteDropdownPlugin\";\n\n/**\n * Singleton orchestrator responsible for maintaining the registry of all available UI control plugins.\n * Resolves standard JSON schema types to their respective UI5 native controls.\n * \n * @namespace nz.co.siliconst.ui5.metaui.core\n * @public\n */\nexport class PluginRegistry {\n /** The single instance of the PluginRegistry. */\n private static instance: PluginRegistry;\n \n /** Internal strongly typed registry holding plugin constructors. */\n private readonly registry: Registry<new () => IPlugin> = new Registry<new () => IPlugin>(\"Controls\");\n\n private constructor() {\n // Built-in Default Mappings\n this.register(\"string\", StringPlugin);\n this.register(\"number\", NumberPlugin);\n this.register(\"integer\", NumberPlugin);\n this.register(\"date\", DatePlugin);\n this.register(\"boolean\", BooleanPlugin);\n this.register(\"array\", ArrayPlugin);\n this.register(\"object\", ObjectPlugin);\n\n // Widget Overrides\n this.register(\"string\", TimePlugin, \"time\");\n this.register(\"string\", DateTimePlugin, \"datetime\");\n this.register(\"boolean\", SwitchPlugin, \"switch\");\n this.register(\"string\", DropdownPlugin, \"select\");\n this.register(\"string\", TextAreaPlugin, \"textArea\");\n this.register(\"string\", CodeEditorPlugin, \"codeEditor\");\n \n // Phase 1 Mappings\n this.register(\"string\", FileUploaderPlugin, \"fileUploader\");\n this.register(\"array\", MultiSelectPlugin, \"multiSelect\");\n this.register(\"number\", SliderPlugin, \"slider\");\n this.register(\"number\", RatingIndicatorPlugin, \"rating\");\n this.register(\"string\", MessageStripPlugin, \"messageStrip\");\n\n // Phase 5 Mappings (Hardware)\n this.register(\"string\", CameraPlugin, \"camera\");\n this.register(\"string\", SignaturePlugin, \"signature\");\n this.register(\"object\", GeolocationPlugin, \"location\");\n this.register(\"string\", BarcodeScannerPlugin, \"scanner\");\n this.register(\"string\", VoiceInputPlugin, \"voiceInput\");\n this.register(\"string\", RichTextPlugin, \"richText\");\n\n // Phase 4 Mappings\n this.register(\"string\", UrlNavigationActionPlugin, \"urlButton\");\n this.register(\"string\", SubmitFormActionPlugin, \"submitButton\");\n this.register(\"string\", ODataListBindingPlugin, \"odataSelect\");\n this.register(\"string\", RemoteDropdownPlugin, \"remoteDropdown\");\n }\n\n /**\n * Retrieves the singular instance of the PluginRegistry.\n * @returns {PluginRegistry} The active instance.\n */\n public static getInstance(): PluginRegistry {\n if (!PluginRegistry.instance) {\n PluginRegistry.instance = new PluginRegistry();\n }\n return PluginRegistry.instance;\n }\n\n /**\n * Registers a new control plugin to be utilized by the Layout Managers.\n * \n * @param type The JSON Schema primitive type (e.g., 'string', 'number').\n * @param pluginConstructor The class constructor for the plugin implementation.\n * @param widgetName Optional UI hint to override the default type handler (e.g., 'textArea' for a 'string').\n */\n public register(type: FieldType, pluginConstructor: new () => IPlugin, widgetName?: string): void {\n const key = widgetName ? `${type}:${widgetName}` : type;\n this.registry.register(key, pluginConstructor);\n }\n\n /**\n * Resolves and instantiates the correct control plugin based on the field type and widget hint.\n * Falls back to the primitive type handler if the specific widget is not registered.\n * \n * @param type The JSON Schema primitive type.\n * @param widgetName The specific UI widget hint (if provided in schema.ui.widget).\n * @returns {IPlugin} A new instance of the resolved plugin.\n * @throws {Error} If no handler is registered for the specified type.\n */\n public getPlugin(type: FieldType, widgetName?: string): IPlugin {\n let PluginClass;\n \n if (widgetName) {\n PluginClass = this.registry.get(`${type}:${widgetName}`);\n }\n \n if (!PluginClass) {\n PluginClass = this.registry.get(type);\n }\n\n if (!PluginClass) {\n const msg = `No control plugin registered for FieldType: ${type}${widgetName ? ` (widget: ${widgetName})` : ''}`;\n Logger.error(\"[MetaUI PluginRegistry]\", msg);\n Logger.showErrorPopup(`Plugin Registry Error.\\n\\nDetails: ${msg}`);\n throw new Error(`[MetaUI] ${msg}`);\n }\n \n try {\n return new PluginClass();\n } catch (error) {\n const msg = (error as Error).message;\n Logger.error(`[MetaUI PluginRegistry] Failed to instantiate plugin for ${type}`, msg);\n Logger.showErrorPopup(`Failed to instantiate plugin for '${type}'.\\n\\nDetails: ${msg}`);\n throw new Error(`[MetaUI Plugin Instantiation] ${msg}`);\n }\n }\n}\n"],"mappings":"AAAA,ysCAAA,MASSA,EAAQC,EAAA,kBACRC,EAAMC,EAAA,gBAENC,EAAYC,EAAA,sBACZC,EAAYC,EAAA,sBACZC,EAAUC,EAAA,oBACVC,EAAUC,EAAA,oBACVC,EAAcC,EAAA,wBACdC,EAAaC,EAAA,uBACbC,EAAYC,EAAA,sBACZC,EAAWC,EAAA,qBACXC,EAAYC,EAAA,sBACZC,EAAcC,EAAA,wBACdC,EAAcC,EAAA,wBACdC,EAAgBC,EAAA,oBAEzB,MACSC,EAAkBC,EAAA,4BAClBC,EAAiBC,EAAA,2BACjBC,EAAYC,EAAA,sBACZC,EAAqBC,EAAA,+BACrBC,EAAkBC,EAAA,sBAE3B,MACSC,EAAYC,EAAA,sBACZC,EAAeC,EAAA,yBACfC,EAAiBC,EAAA,2BACjBC,EA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GAAeM,SAAU,CAC1BN,GAAeM,SAAW,IAAIN,EAClC,CACA,OAAOA,GAAeM,QAC1B,CASOF,SAASG,EAAiBC,EAAsCC,GACnE,MAAMC,EAAMD,EAAa,GAAGF,KAAQE,IAAeF,EACnDJ,KAAKF,SAASG,SAASM,EAAKF,EAChC,CAWOG,UAAUJ,EAAiBE,GAC9B,IAAIG,EAEJ,GAAIH,EAAY,CACZG,EAAcT,KAAKF,SAASY,IAAI,GAAGN,KAAQE,IAC/C,CAEA,IAAKG,EAAa,CACdA,EAAcT,KAAKF,SAASY,IAAIN,EACpC,CAEA,IAAKK,EAAa,CACd,MAAME,EAAM,+CAA+CP,IAAOE,EAAa,aAAaA,KAAgB,KAC5GjE,EAAOuE,MAAM,0BAA2BD,GACxCtE,EAAOwE,eAAe,sCAAsCF,KAC5D,MAAM,IAAIG,MAAM,YAAYH,IAChC,CAEA,IACI,OAAO,IAAIF,CACf,CAAE,MAAOG,GACL,MAAMD,EAAOC,EAAgBG,QAC7B1E,EAAOuE,MAAM,4DAA4DR,IAAQO,GACjFtE,EAAOwE,eAAe,qCAAqCT,mBAAsBO,KACjF,MAAM,IAAIG,MAAM,iCAAiCH,IACrD,CACJ,EACH,IAAAK,GAAA,CAAAC,WAAA,MAAAD,GAAAnB,kBAAA,OAAAmB,EAAA","ignoreList":[],"sourceRoot":"core"}},{"offset":{"line":20,"column":0},"map":{"version":3,"names":["Logger","___utils_Logger","Registry","items","Map","constructor","registryName","this","register","key","item","has","warn","set","get","getStrict","Error","getKeys","Array","from","keys","clear","__exports","__esModule"],"sources":["Registry.ts"],"sourcesContent":["/**\n * @file Registry.ts\n * @description Universal generic registry pattern used across the MetaUI library \n * for registering and resolving decoupled plugins (Layouts, Controls, Validators, etc).\n */\n\nimport { Logger } from \"../utils/Logger\";\n\n/**\n * Universal generic registry pattern used across the MetaUI library \n * for registering and resolving decoupled plugins (Layouts, Controls, Validators, etc).\n * \n * @template T The type of item being stored in the registry.\n * @namespace nz.co.siliconst.ui5.metaui.core\n * @public\n */\nexport class Registry<T> {\n /** The internal map storing the registered items. */\n public readonly items = new Map<string, T>();\n\n constructor(public readonly registryName: string = \"Registry\") {}\n\n /**\n * Registers a new item (plugin/layout/validator) into the registry.\n * @param key The unique string identifier.\n * @param item The implementation class or instance.\n */\n public register(key: string, item: T): void {\n if (this.items.has(key)) {\n Logger.warn(`[MetaUI] ${this.registryName}: Overwriting existing key '${key}'.`);\n }\n this.items.set(key, item);\n }\n\n /**\n * Retrieves an item by its key.\n * @param key The unique string identifier.\n * @returns The registered item, or undefined if not found.\n */\n public get(key: string): T | undefined {\n return this.items.get(key);\n }\n\n /**\n * Retrieves an item by its key, throwing an error if it doesn't exist.\n * @param key The unique string identifier.\n * @returns The registered item.\n */\n public getStrict(key: string): T {\n const item = this.get(key);\n if (!item) {\n throw new Error(`[MetaUI] ${this.registryName}: Key '${key}' not found.`);\n }\n return item;\n }\n\n /**\n * Returns an array of all registered keys.\n */\n public getKeys(): string[] {\n return Array.from(this.items.keys());\n }\n\n /**\n * Clears the entire registry.\n */\n public clear(): void {\n this.items.clear();\n }\n}\n"],"mappings":"AAAA,0GAAA,MAMSA,EAAMC,EAAA,UAUR,MAAMC,EAEOC,MAAQ,IAAIC,IAE5BC,YAA4BC,EAAuB,YAAYC,KAAnCD,cAAoC,CAOzDE,SAASC,EAAaC,GACzB,GAAIH,KAAKJ,MAAMQ,IAAIF,GAAM,CACrBT,EAAOY,KAAK,YAAYL,KAAKD,2CAA2CG,MAC5E,CACAF,KAAKJ,MAAMU,IAAIJ,EAAKC,EACxB,CAOOI,IAAIL,GACP,OAAOF,KAAKJ,MAAMW,IAAIL,EAC1B,CAOOM,UAAUN,GACb,MAAMC,EAAOH,KAAKO,IAAIL,GACtB,IAAKC,EAAM,CACP,MAAM,IAAIM,MAAM,YAAYT,KAAKD,sBAAsBG,gBAC3D,CACA,OAAOC,CACX,CAKOO,UACH,OAAOC,MAAMC,KAAKZ,KAAKJ,MAAMiB,OACjC,CAKOC,QACHd,KAAKJ,MAAMkB,OACf,EACH,IAAAC,EAAA,CAAAC,WAAA,MAAAD,EAAApB,WAAA,OAAAoB,CAAA","ignoreList":[],"sourceRoot":"core"}},{"offset":{"line":21,"column":0},"map":{"version":3,"names":["Logger","___utils_Logger","SchemaNormalizer","normalize","rawSchema","data","schemaObj","JSON","parse","e","msg","message","error","showErrorPopup","Array","isArray","this","inferSchemaFromData","normalized","title","type","items","layoutStrategy","uiLayout","additionalProperties","targetProperties","properties","inferred","deepMergeProperties","normalizeProperties","normalizePropertyMetadata","base","override","merged","key","Object","keys","overrideVal","baseVal","normalizedProps","prop","keyName","ui","label","generateLabel","isKey","readOnly","widget","valueHelp","enum","undefined","visibleOn","enabledOn","format","validators","formatter","args","rows","fullWidth","required","maxLength","minimum","maximum","pattern","precision","scale","name","spaced","replace","split","filter","w","length","map","word","charAt","toUpperCase","slice","toLowerCase","join","trim","schema","inferPropertiesFromObject","obj","val","nestedProps","resolveScope","scope","startsWith","meta","bindingPath","propKey","pathSegments","current","debug","stringify","i","segment","__exports","__esModule"],"sources":["SchemaNormalizer.ts"],"sourcesContent":["/**\n * @file SchemaNormalizer.ts\n * @description Transforms and validates incoming JSON payloads into the strict v2 ISchema dictionary matrix.\n */\n\nimport { ISchema, IPropertyMetadata, FieldType } from \"../interfaces/ISchema\";\nimport { Logger } from \"../utils/Logger\";\n\nexport class SchemaNormalizer {\n\n /**\n * Validates that the provided raw payload conforms to the required ISchema structures.\n */\n public static normalize(rawSchema?: any, data?: any): ISchema {\n let schemaObj = rawSchema;\n\n if (typeof schemaObj === \"string\") {\n try {\n schemaObj = JSON.parse(schemaObj);\n } catch (e) {\n const msg = (e as Error).message;\n Logger.error(\"[MetaUI SchemaNormalizer] Failed to parse schema string.\", msg);\n Logger.showErrorPopup(`Failed to parse the provided JSON schema.\\n\\nDetails: ${msg}`);\n schemaObj = null;\n }\n }\n\n if (!schemaObj || typeof schemaObj !== 'object' || Array.isArray(schemaObj)) {\n return this.inferSchemaFromData(data);\n }\n\n try {\n // It is an object. Ensure it conforms to v2 structure.\n const normalized: ISchema = {\n title: schemaObj.title,\n type: schemaObj.type || (schemaObj.items ? \"array\" : \"object\"),\n layoutStrategy: schemaObj.layoutStrategy,\n uiLayout: schemaObj.uiLayout,\n additionalProperties: schemaObj.additionalProperties\n };\n\n let targetProperties = schemaObj.properties || {};\n\n if (schemaObj.additionalProperties === true && data) {\n const inferred = this.inferSchemaFromData(data);\n if (inferred.type === \"object\" && inferred.properties) {\n targetProperties = this.deepMergeProperties(inferred.properties, targetProperties);\n } else if (inferred.type === \"array\" && inferred.items && inferred.items.properties) {\n // Array schema merging could be added here if we want full support.\n }\n }\n\n if (normalized.type === \"object\") {\n normalized.properties = this.normalizeProperties(targetProperties);\n } else if (normalized.type === \"array\") {\n // Future expansion: array deep merge\n normalized.items = this.normalizePropertyMetadata(schemaObj.items || { type: \"object\", properties: {} }, \"items\");\n }\n\n return normalized;\n } catch (error) {\n const msg = (error as Error).message;\n Logger.error(\"[MetaUI SchemaNormalizer] Critical error normalizing schema object.\", msg);\n Logger.showErrorPopup(`Schema Normalization failed.\\n\\nDetails: ${msg}`);\n // Fallback to empty object to prevent hard crash downstream\n return { type: \"object\", properties: {} };\n }\n }\n\n private static deepMergeProperties(base: any, override: any): any {\n const merged = { ...base };\n for (const key of Object.keys(override)) {\n const overrideVal = override[key];\n const baseVal = merged[key];\n\n if (baseVal && typeof baseVal === \"object\" && !Array.isArray(baseVal) &&\n overrideVal && typeof overrideVal === \"object\" && !Array.isArray(overrideVal)) {\n merged[key] = this.deepMergeProperties(baseVal, overrideVal);\n } else {\n merged[key] = overrideVal;\n }\n }\n return merged;\n }\n\n private static normalizeProperties(properties: any): Record<string, IPropertyMetadata> {\n const normalizedProps: Record<string, IPropertyMetadata> = {};\n for (const key of Object.keys(properties)) {\n normalizedProps[key] = this.normalizePropertyMetadata(properties[key], key);\n }\n return normalizedProps;\n }\n\n private static normalizePropertyMetadata(prop: any, keyName: string): IPropertyMetadata {\n const normalized: IPropertyMetadata = {\n type: prop.type || \"string\",\n ui: {\n label: prop.ui?.label || this.generateLabel(keyName),\n isKey: !!prop.ui?.isKey,\n readOnly: !!prop.ui?.readOnly,\n widget: prop.ui?.widget || (prop.valueHelp || prop.enum ? \"select\" : undefined),\n visibleOn: prop.ui?.visibleOn,\n enabledOn: prop.ui?.enabledOn,\n format: prop.ui?.format,\n validators: prop.ui?.validators,\n formatter: prop.ui?.formatter,\n args: prop.ui?.args,\n rows: prop.ui?.rows,\n fullWidth: prop.ui?.fullWidth\n },\n required: !!prop.required,\n maxLength: prop.maxLength,\n minimum: prop.minimum,\n maximum: prop.maximum,\n pattern: prop.pattern,\n precision: prop.precision,\n scale: prop.scale,\n valueHelp: prop.valueHelp,\n enum: prop.enum\n };\n\n if (normalized.type === \"object\" && prop.properties) {\n normalized.properties = this.normalizeProperties(prop.properties);\n normalized.uiLayout = prop.uiLayout;\n } else if (normalized.type === \"array\" && prop.items) {\n normalized.items = this.normalizePropertyMetadata(prop.items, \"items\");\n normalized.uiLayout = prop.uiLayout;\n }\n\n return normalized;\n }\n\n /**\n * Generates a Title Case label from camelCase or snake_case technical names.\n */\n private static generateLabel(name: string): string {\n if (!name) return \"\";\n let spaced = name.replace(/([A-Z])/g, \" $1\").replace(/_/g, \" \");\n return spaced.split(' ')\n .filter(w => w.length > 0)\n .map(word => word.charAt(0).toUpperCase() + word.slice(1).toLowerCase())\n .join(' ')\n .trim();\n }\n\n /**\n * Infers a v2 ISchema structure dynamically from a plain data payload.\n */\n private static inferSchemaFromData(data: any): ISchema {\n const schema: ISchema = { type: \"object\", properties: {}, layoutStrategy: \"compact\", title: \"\" };\n\n if (!data || typeof data !== \"object\") {\n return schema;\n }\n\n if (Array.isArray(data)) {\n schema.type = \"array\";\n schema.layoutStrategy = \"table\";\n schema.items = {\n type: \"object\",\n layoutStrategy: \"compact\",\n properties: data.length > 0 ? this.inferPropertiesFromObject(data[0]) : {}\n };\n } else {\n schema.type = \"object\";\n schema.properties = this.inferPropertiesFromObject(data);\n }\n\n return schema;\n }\n\n private static inferPropertiesFromObject(obj: any): Record<string, IPropertyMetadata> {\n const properties: Record<string, IPropertyMetadata> = {};\n if (!obj || typeof obj !== \"object\") return properties;\n\n for (const key of Object.keys(obj)) {\n const val = obj[key];\n if (val === null || val === undefined) continue;\n\n let type: FieldType = \"string\";\n let items: IPropertyMetadata | undefined;\n let nestedProps: Record<string, IPropertyMetadata> | undefined;\n\n if (typeof val === \"number\") type = \"number\";\n else if (typeof val === \"boolean\") type = \"boolean\";\n else if (Array.isArray(val)) {\n type = \"array\";\n items = {\n type: \"object\",\n properties: val.length > 0 ? this.inferPropertiesFromObject(val[0]) : {}\n };\n } else if (typeof val === \"object\") {\n type = \"object\";\n nestedProps = this.inferPropertiesFromObject(val);\n }\n\n properties[key] = {\n type,\n items,\n properties: nestedProps,\n ui: {\n label: this.generateLabel(key),\n isKey: false,\n readOnly: false\n }\n };\n }\n\n return properties;\n }\n\n /**\n * Resolves a JSON Schema scope (e.g. '#/properties/header/properties/id')\n * against the ISchema, returning the PropertyMetadata and the UI5 binding path.\n */\n public static resolveScope(schema: ISchema, scope: string): { meta: IPropertyMetadata | undefined, bindingPath: string, propKey: string } {\n if (!scope || !scope.startsWith(\"#/properties/\")) {\n return { meta: undefined, bindingPath: scope || \"\", propKey: scope || \"\" };\n }\n \n const pathSegments = scope.replace(\"#/properties/\", \"\").split(\"/properties/\");\n let current: any = schema.properties;\n let meta: IPropertyMetadata | undefined;\n \n Logger.debug(\"[MetaUI SchemaNormalizer]\", `Resolving scope '${scope}' with segments: ${JSON.stringify(pathSegments)}`, \"SchemaNormalizer\");\n Logger.debug(\"[MetaUI SchemaNormalizer]\", `Root schema keys: ${Object.keys(schema.properties || {})}`, \"SchemaNormalizer\");\n\n for (let i = 0; i < pathSegments.length; i++) {\n const segment = pathSegments[i];\n if (!current) {\n Logger.debug(\"[MetaUI SchemaNormalizer]\", `current is undefined at segment '${segment}'`, \"SchemaNormalizer\");\n meta = undefined;\n break;\n }\n meta = current[segment];\n Logger.debug(\"[MetaUI SchemaNormalizer]\", `Segment '${segment}' resolved to meta: ${!!meta}. Available keys in current: ${Object.keys(current)}`, \"SchemaNormalizer\");\n if (i < pathSegments.length - 1) {\n current = meta?.properties;\n }\n }\n \n const bindingPath = pathSegments.join(\"/\");\n const propKey = scope.replace(\"#/properties/\", \"\"); // The original raw string for logging\n \n return {\n meta,\n bindingPath,\n propKey\n };\n }\n}\n"],"mappings":"AAAA,kHAAA,MAMSA,EAAMC,EAAA,UAER,MAAMC,EAKT,gBAAcC,CAAUC,EAAiBC,GACrC,IAAIC,EAAYF,EAEhB,UAAWE,IAAc,SAAU,CAC/B,IACIA,EAAYC,KAAKC,MAAMF,EAC3B,CAAE,MAAOG,GACL,MAAMC,EAAOD,EAAYE,QACzBX,EAAOY,MAAM,2DAA4DF,GACzEV,EAAOa,eAAe,yDAAyDH,KAC/EJ,EAAY,IAChB,CACJ,CAEA,IAAKA,UAAoBA,IAAc,UAAYQ,MAAMC,QAAQT,GAAY,CACzE,OAAOU,KAAKC,oBAAoBZ,EACpC,CAEA,IAEI,MAAMa,EAAsB,CACxBC,MAAOb,EAAUa,MACjBC,KAAMd,EAAUc,OAASd,EAAUe,MAAQ,QAAU,UACrDC,eAAgBhB,EAAUgB,eAC1BC,SAAUjB,EAAUiB,SACpBC,qBAAsBlB,EAAUkB,sBAGpC,IAAIC,EAAmBnB,EAAUoB,YAAc,CAAC,EAEhD,GAAIpB,EAAUkB,uBAAyB,MAAQnB,EAAM,CACjD,MAAMsB,EAAWX,KAAKC,oBAAoBZ,GAC1C,GAAIsB,EAASP,OAAS,UAAYO,EAASD,WAAY,CACnDD,EAAmBT,KAAKY,oBAAoBD,EAASD,WAAYD,EACrE,MAAO,GAAIE,EAASP,OAAS,SAAWO,EAASN,OAASM,EAASN,MAAMK,WAAY,CACjF,CAER,CAEA,GAAIR,EAAWE,OAAS,SAAU,CAC9BF,EAAWQ,WAAaV,KA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5F,EAAO8F,MAAM,4BAA6B,qBAAqB3D,OAAOC,KAAK6C,EAAOvD,YAAc,CAAC,KAAM,oBAEvG,IAAK,IAAIsE,EAAI,EAAGA,EAAIJ,EAAapB,OAAQwB,IAAK,CAC1C,MAAMC,EAAUL,EAAaI,GAC7B,IAAKH,EAAS,CACV7F,EAAO8F,MAAM,4BAA6B,oCAAoCG,KAAY,oBAC1FR,EAAOvC,UACP,KACJ,CACAuC,EAAOI,EAAQI,GACfjG,EAAO8F,MAAM,4BAA6B,YAAYG,0BAAgCR,iCAAoCtD,OAAOC,KAAKyD,KAAY,oBAClJ,GAAIG,EAAIJ,EAAapB,OAAS,EAAG,CAC7BqB,EAAUJ,GAAM/D,UACpB,CACJ,CAEA,MAAMgE,EAAcE,EAAab,KAAK,KACtC,MAAMY,EAAUJ,EAAMnB,QAAQ,gBAAiB,IAE/C,MAAO,CACHqB,OACAC,cACAC,UAER,EACH,IAAAO,EAAA,CAAAC,WAAA,MAAAD,EAAAhG,mBAAA,OAAAgG,CAAA","ignoreList":[],"sourceRoot":"core"}},{"offset":{"line":22,"column":0},"map":{"version":3,"names":["SchemaValidator","validateSchemaStructure","schema","errors","type","push","properties","key","Object","keys","prop","allowedTypes","includes","join","__exports","__esModule"],"sources":["SchemaValidator.ts"],"sourcesContent":["/**\n * @file SchemaValidator.ts\n * @description Structural validation utility to catch developer errors in the JSON schema itself.\n */\n\nimport { ISchema, FieldType } from \"../interfaces/ISchema\";\n\nexport class SchemaValidator {\n /**\n * Validates a parsed JSON schema object for structural correctness.\n * @param schema The schema object to validate\n * @returns An array of error strings. Empty if no errors.\n */\n public static validateSchemaStructure(schema: any): string[] {\n const errors: string[] = [];\n\n if (!schema || typeof schema !== \"object\") {\n return [\"Root schema must be an object.\"];\n }\n\n if (schema.type !== \"object\" && schema.type !== \"array\") {\n errors.push(`Root schema must have type 'object' or 'array'. Found: '${schema.type}'`);\n }\n\n if (schema.type === \"object\" && !schema.properties) {\n errors.push(\"Object schema is missing the 'properties' node.\");\n }\n\n if (schema.properties) {\n for (const key of Object.keys(schema.properties)) {\n const prop = schema.properties[key];\n if (!prop || typeof prop !== \"object\") {\n errors.push(`Property '${key}' must be an object.`);\n continue;\n }\n\n if (!prop.type) {\n errors.push(`Property '${key}' is missing 'type'.`);\n } else {\n const allowedTypes: FieldType[] = [\"string\", \"number\", \"boolean\", \"date\", \"object\", \"array\"];\n if (!allowedTypes.includes(prop.type)) {\n errors.push(`Property '${key}' has invalid type '${prop.type}'. Allowed: ${allowedTypes.join(\", \")}`);\n }\n }\n\n // Removed strict check for prop.items on array properties because inference handles empty definitions\n\n }\n }\n\n return errors;\n }\n}\n"],"mappings":"AAAA,+FAOO,MAAMA,EAMT,8BAAcC,CAAwBC,GAClC,MAAMC,EAAmB,GAEzB,IAAKD,UAAiBA,IAAW,SAAU,CACvC,MAAO,CAAC,iCACZ,CAEA,GAAIA,EAAOE,OAAS,UAAYF,EAAOE,OAAS,QAAS,CACrDD,EAAOE,KAAK,2DAA2DH,EAAOE,QAClF,CAEA,GAAIF,EAAOE,OAAS,WAAaF,EAAOI,WAAY,CAChDH,EAAOE,KAAK,kDAChB,CAEA,GAAIH,EAAOI,WAAY,CACnB,IAAK,MAAMC,KAAOC,OAAOC,KAAKP,EAAOI,YAAa,CAC9C,MAAMI,EAAOR,EAAOI,WAAWC,GAC/B,IAAKG,UAAeA,IAAS,SAAU,CACnCP,EAAOE,KAAK,aAAaE,yBACzB,QACJ,CAEA,IAAKG,EAAKN,KAAM,CACZD,EAAOE,KAAK,aAAaE,wBAC7B,KAAO,CACH,MAAMI,EAA4B,CAAC,SAAU,SAAU,UAAW,OAAQ,SAAU,SACpF,IAAKA,EAAaC,SAASF,EAAKN,MAAO,CACnCD,EAAOE,KAAK,aAAaE,wBAA0BG,EAAKN,mBAAmBO,EAAaE,KAAK,QACjG,CACJ,CAIJ,CACJ,CAEA,OAAOV,CACX,EACH,IAAAW,EAAA,CAAAC,WAAA,MAAAD,EAAAd,kBAAA,OAAAc,CAAA","ignoreList":[],"sourceRoot":"core"}},{"offset":{"line":23,"column":0},"map":{"version":3,"names":["GlobalPipeline","___PipelineManager","StateManager","constructor","initialData","schema","modelName","this","activeModelName","safeData","JSON","parse","stringify","model","JSONModel","setDefaultBindingMode","originalSetProperty","setProperty","bind","sPath","oValue","oContext","bAsyncUpdate","result","validatePath","value","fieldKey","replace","metadata","findMetadataForPath","messageManager","Messaging","targetPath","startsWith","existingMessages","getMessageModel","getData","messagesToRemove","filter","msg","isMatch","getTarget","getMessageProcessor","getId","length","removeMessages","validatorsToRun","argsMap","required","push","type","maxLength","max","ui","validators","v","name","args","undefined","validationResult","executeValidation","isValid","newMsg","Message","message","errorMessage","coreLibrary","MessageType","Error","target","processor","addMessages","path","properties","getModel","bindControl","control","property","bindingPath","bindProperty","extractPayload","data","destroy","__exports","__esModule"],"sources":["StateManager.ts"],"sourcesContent":["/**\n * @file StateManager.ts\n * @description Isolated internal state management. Decouples the MetaUI engine from external host models.\n */\n\nimport JSONModel from \"sap/ui/model/json/JSONModel\";\nimport ManagedObject from \"sap/ui/base/ManagedObject\";\nimport { ISchema, IPropertyMetadata } from \"../interfaces/ISchema\";\nimport { GlobalPipeline } from \"./PipelineManager\";\nimport Message from \"sap/ui/core/message/Message\";\nimport coreLibrary from \"sap/ui/core/library\";\nimport Core from \"sap/ui/core/Core\";\nimport Messaging from \"sap/ui/core/Messaging\";\n\n\n/**\n * Manages the isolated internal data payload for the MetaUI engine.\n */\nexport class StateManager {\n private model: JSONModel;\n private activeModelName: string;\n private schema: ISchema;\n\n /**\n * Initializes the state manager with an optional initial payload.\n * @param initialData The initial JSON payload to populate the fields.\n * @param schema The normalized schema for live validation.\n * @param modelName The UI5 model alias used for isolation.\n */\n constructor(initialData: Record<string, any> = {}, schema: ISchema, modelName: string = \"meta\") {\n this.activeModelName = modelName;\n this.schema = schema;\n \n // Deep copy to ensure no reference leakage from the host application\n const safeData = JSON.parse(JSON.stringify(initialData));\n this.model = new JSONModel(safeData);\n this.model.setDefaultBindingMode(\"TwoWay\");\n\n // Centralized Model-Level Validation Interceptor\n const originalSetProperty = this.model.setProperty.bind(this.model);\n this.model.setProperty = (sPath: string, oValue: any, oContext?: any, bAsyncUpdate?: boolean) => {\n const result = originalSetProperty(sPath, oValue, oContext, bAsyncUpdate);\n this.validatePath(sPath, oValue);\n return result;\n };\n }\n\n /**\n * Validates a specific path against the schema and updates the MessageManager.\n */\n private validatePath(sPath: string, value: any): void {\n const fieldKey = sPath.replace(/^\\//, \"\");\n const metadata = this.findMetadataForPath(fieldKey);\n \n const messageManager = Messaging;\n const targetPath = sPath.startsWith(\"/\") ? sPath : `/${sPath}`; // Pure UI5: target MUST be absolute path\n \n // 1. Remove existing messages (strictly for THIS model instance)\n const existingMessages = messageManager.getMessageModel().getData();\n const messagesToRemove = existingMessages.filter((msg: any) => {\n const isMatch = msg.getTarget() === targetPath && msg.getMessageProcessor() && msg.getMessageProcessor().getId() === this.model.getId();\n return isMatch;\n });\n \n \n if (messagesToRemove.length > 0) {\n messageManager.removeMessages(messagesToRemove);\n }\n\n if (!metadata) return;\n\n // 2. Run GlobalPipeline\n const validatorsToRun: string[] = [];\n const argsMap: Record<string, any> = {};\n\n if (metadata.required) {\n validatorsToRun.push(\"required\");\n }\n if (metadata.type === \"string\" && metadata.maxLength) {\n validatorsToRun.push(\"maxLength\");\n argsMap[\"maxLength\"] = { max: metadata.maxLength };\n }\n if (metadata.ui?.validators) {\n for (const v of metadata.ui.validators) {\n if (typeof v === \"string\") {\n validatorsToRun.push(v);\n } else if (v && v.name) {\n validatorsToRun.push(v.name);\n if (v.args !== undefined) {\n argsMap[v.name] = v.args;\n }\n }\n }\n }\n\n if (validatorsToRun.length > 0) {\n const validationResult = GlobalPipeline.executeValidation(value, validatorsToRun, argsMap);\n if (!validationResult.isValid) {\n const newMsg = new Message({\n message: validationResult.errorMessage || \"Invalid value.\",\n type: coreLibrary.MessageType.Error,\n target: targetPath,\n processor: this.model\n });\n messageManager.addMessages(newMsg);\n }\n }\n }\n\n private findMetadataForPath(path: string): IPropertyMetadata | undefined {\n if (!this.schema || !this.schema.properties) return undefined;\n // Basic single-level support for now. Nested object resolution would split by '.' or '/'\n return this.schema.properties[path];\n }\n\n\n\n /**\n * Retrieves the isolated JSONModel instance to attach to the root GeneratorHost control.\n * @returns The internal JSONModel.\n */\n public getModel(): JSONModel {\n return this.model;\n }\n\n /**\n * Binds a generated UI control property to a path in the internal model.\n * @param control The target UI5 Control.\n * @param property The UI5 property name (e.g., 'value').\n * @param bindingPath The exact path in the JSON payload.\n */\n public bindControl(control: ManagedObject, property: string, bindingPath: string): void {\n control.bindProperty(property, {\n path: bindingPath,\n model: \"meta\" // Assumes the model is bound to the root container with the name 'meta'\n });\n }\n\n /**\n * Extracts the flat JavaScript object representing the current state of the UI.\n * @returns A serialized record of the data payload, free of UI5 wrappers.\n */\n public extractPayload(): Record<string, any> {\n // Create a deep copy to prevent accidental mutations by the host\n const data = this.model.getData();\n return JSON.parse(JSON.stringify(data));\n }\n\n /**\n * Cleans up internal state and natively destroys the UI5 JSONModel to prevent memory leaks.\n */\n public destroy(): void {\n \n if (this.model) {\n this.model.destroy();\n }\n }\n}\n"],"mappings":"AAAA,wOAQSA,EAAcC,EAAA,kBAUhB,MAAMC,EAWTC,YAAYC,EAAmC,CAAC,EAAGC,EAAiBC,EAAoB,QACpFC,KAAKC,gBAAkBF,EACvBC,KAAKF,OAASA,EAGd,MAAMI,EAAWC,KAAKC,MAAMD,KAAKE,UAAUR,IAC3CG,KAAKM,MAAQ,IAAIC,EAAUL,GAC3BF,KAAKM,MAAME,sBAAsB,UAGjC,MAAMC,EAAsBT,KAAKM,MAAMI,YAAYC,KAAKX,KAAKM,OAC7DN,KAAKM,MAAMI,YAAc,CAACE,EAAeC,EAAaC,EAAgBC,KAClE,MAAMC,EAASP,EAAoBG,EAAOC,EAAQC,EAAUC,GAC5Df,KAAKiB,aAAaL,EAAOC,GACzB,OAAOG,EAEf,CAKQC,aAAaL,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yC,YAAYT,EAC/B,CACJ,CACJ,CAEQjC,oBAAoB2C,GACxB,IAAKjE,KAAKF,SAAWE,KAAKF,OAAOoE,WAAY,OAAOf,UAEpD,OAAOnD,KAAKF,OAAOoE,WAAWD,EAClC,CAQOE,WACH,OAAOnE,KAAKM,KAChB,CAQO8D,YAAYC,EAAwBC,EAAkBC,GACzDF,EAAQG,aAAaF,EAAU,CAC3BL,KAAMM,EACNjE,MAAO,QAEf,CAMOmE,iBAEH,MAAMC,EAAO1E,KAAKM,MAAMuB,UACxB,OAAO1B,KAAKC,MAAMD,KAAKE,UAAUqE,GACrC,CAKOC,UAEH,GAAI3E,KAAKM,MAAO,CACZN,KAAKM,MAAMqE,SACf,CACJ,EACH,IAAAC,EAAA,CAAAC,WAAA,MAAAD,EAAAjF,eAAA,OAAAiF,CAAA","ignoreList":[],"sourceRoot":"core"}},{"offset":{"line":24,"column":0},"map":{"version":3,"names":["SchemaNormalizer","___core_SchemaNormalizer","Logger","___utils_Logger","CompactLayout","render","schema","modelName","engine","onSubmit","container","VBox","renderType","addStyleClass","uiLayout","Array","isArray","warn","tableElements","renderElement","element","type","label","title","sap","m","Title","text","level","addItem","elements","forEach","scope","startsWith","error","meta","bindingPath","propKey","resolveScope","isCollectionOfRecords","items","properties","hasExplicitWidget","ui","widget","isSubLayout","debug","push","this","_renderScalarField","field","subSchema","control","generateLayout","msg","message","showErrorPopup","labelText","Label","required","effectiveMeta","generateField","fieldBox","__exports","__esModule"],"sources":["CompactLayout.ts"],"sourcesContent":["/**\n * @file CompactLayout.ts\n * @description Generates a lightweight, dense VBox layout for use inside tight spaces like table cells.\n */\n\nimport VBox from \"sap/m/VBox\";\nimport Label from \"sap/m/Label\";\nimport Title from \"sap/ui/core/Title\";\nimport { IPropertyMetadata, ISchema, ILayoutElement } from \"../interfaces/ISchema\";\nimport { ILayoutManager } from \"../interfaces/ILayoutManager\";\nimport { Engine } from \"../core/Engine\";\nimport { SchemaNormalizer } from \"../core/SchemaNormalizer\";\nimport { Logger } from \"../utils/Logger\";\nimport Control from \"sap/ui/core/Control\";\n\n/**\n * Layout Manager responsible for generating a dense, lightweight layout (no SimpleForm padding).\n * Ideal for rendering objects dynamically inside table cells or side-panels.\n * \n * @namespace nz.co.siliconst.ui5.metaui.layouts\n * @public\n */\nexport class CompactLayout implements ILayoutManager {\n /**\n * Renders the JSON Schema properties into a dense VBox layout.\n * \n * @param schema The active JSON schema subset.\n * @param modelName The bound UI5 model name.\n * @param engine The central orchestrator for delegating plugin generation.\n * @param onSubmit Optional submit hook.\n * @returns {Control} The VBox wrapper containing the generated compact form.\n */\n public render(schema: ISchema, modelName: string, engine: Engine, onSubmit?: () => void): Control {\n const container = new VBox({ renderType: \"Bare\" });\n container.addStyleClass(\"sapUiTinyMargin\");\n\n if (!schema.uiLayout || !Array.isArray(schema.uiLayout)) {\n Logger.warn(\"[MetaUI] Missing 'uiLayout' array in schema. CompactLayout will not render any fields.\");\n return container;\n }\n\n const tableElements: { scope: string, meta: IPropertyMetadata, label?: string }[] = [];\n\n // Recursively render layout elements\n const renderElement = (element: ILayoutElement) => {\n if (element.type === \"Group\") {\n if (element.label) {\n const title = new sap.m.Title({ text: element.label, level: \"H5\" });\n title.addStyleClass(\"sapUiTinyMarginTop sapUiTinyMarginBottom\");\n container.addItem(title);\n }\n \n if (element.elements && Array.isArray(element.elements)) {\n element.elements.forEach(renderElement);\n }\n } else if (element.type === \"Control\") {\n if (!element.scope || !element.scope.startsWith(\"#/properties/\")) {\n Logger.error(`[MetaUI] Invalid scope '${element.scope}' in uiLayout Control.`, \"\", \"CompactLayout\");\n return;\n }\n \n const { meta, bindingPath, propKey } = SchemaNormalizer.resolveScope(schema, element.scope);\n \n if (!meta) {\n Logger.error(`[MetaUI] Property '${propKey}' not found in schema definitions.`, \"\", \"CompactLayout\");\n return;\n }\n\n const isCollectionOfRecords = meta.items?.type === \"object\" || meta.items?.properties;\n const hasExplicitWidget = !!meta.ui?.widget;\n const isSubLayout = meta.type === \"array\" && isCollectionOfRecords && !hasExplicitWidget;\n\n if (isSubLayout) {\n Logger.debug(\"[MetaUI CompactLayout]\", `Routing property '${propKey}' to Table Sub-Layout.`, \"CompactLayout\");\n tableElements.push({ scope: bindingPath, meta, label: element.label });\n } else {\n Logger.debug(\"[MetaUI CompactLayout]\", `Rendering scalar field '${bindingPath}'.`, \"CompactLayout\");\n this._renderScalarField(container, element, bindingPath, meta, modelName, engine);\n }\n } else {\n Logger.warn(`[MetaUI] Unsupported layout element type '${element.type}'.`, \"\", \"CompactLayout\");\n }\n };\n\n // Render everything defined in the layout\n schema.uiLayout.forEach(renderElement);\n\n // Render array/table sub-layouts full width below the fields\n tableElements.forEach(field => {\n try {\n const subSchema = {\n type: \"array\",\n title: field.label || field.meta.ui?.label || field.scope,\n items: field.meta.items || { type: \"object\", properties: {} },\n uiLayout: field.meta.items?.uiLayout\n };\n \n const control = engine.generateLayout(subSchema as ISchema, modelName, `/${field.scope}`);\n if (control) {\n control.addStyleClass(\"sapUiTinyMarginTop\");\n container.addItem(control);\n }\n } catch (error) {\n const msg = (error as Error).message;\n Logger.error(`[MetaUI] Failed to render array field ${field.scope}`, msg, \"CompactLayout\");\n Logger.showErrorPopup(`Failed to render array field '${field.scope}'.\\n\\nDetails: ${msg}`);\n }\n });\n\n return container;\n }\n\n private _renderScalarField(container: VBox, element: ILayoutElement, propKey: string, meta: IPropertyMetadata, modelName: string, engine: Engine): void {\n try {\n const labelText = element.label || meta.ui?.label || propKey;\n const label = new Label({\n text: labelText,\n required: meta.required\n });\n label.addStyleClass(\"sapUiTinyMarginTop\");\n\n const effectiveMeta = { ...meta };\n if (element.widget) {\n effectiveMeta.ui = { ...meta.ui, widget: element.widget };\n }\n\n const control = engine.generateField(effectiveMeta, `/${propKey}`, modelName);\n control.addStyleClass(\"sapUiTinyMarginBottom\");\n\n // Wrap label and field tightly\n const fieldBox = new VBox({ renderType: \"Bare\", items: [label, control] });\n container.addItem(fieldBox);\n } catch (error) {\n const msg = (error as Error).message;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,GAAK,IAAKR,EAAKQ,GAAIC,OAAQxB,EAAQwB,OACrD,CAEA,MAAMQ,EAAU5C,EAAOqD,cAAcD,EAAe,IAAIvB,IAAW9B,GACnE6C,EAAQvC,cAAc,yBAGtB,MAAMiD,EAAW,IAAInD,EAAK,CAAEC,WAAY,OAAQ4B,MAAO,CAAClB,EAAO8B,KAC/D1C,EAAUmB,QAAQiC,EACtB,CAAE,MAAO5B,GACL,MAAMoB,EAAOpB,EAAgBqB,QAC7BrD,EAAOgC,MAAM,mCAAmCG,IAAWiB,EAAK,iBAChEpD,EAAOsD,eAAe,2BAA2BnB,mBAAyBiB,IAC9E,CACJ,EACH,IAAAS,EAAA,CAAAC,WAAA,MAAAD,EAAA3D,gBAAA,OAAA2D,CAAA","ignoreList":[],"sourceRoot":"layouts"}},{"offset":{"line":25,"column":0},"map":{"version":3,"names":["SchemaNormalizer","___core_SchemaNormalizer","Logger","___utils_Logger","FormLayout","render","schema","modelName","engine","onSubmit","container","VBox","renderType","form","SimpleForm","editable","title","layout","labelSpanXL","labelSpanL","labelSpanM","labelSpanS","adjustLabelSpan","emptySpanXL","emptySpanL","emptySpanM","emptySpanS","columnsXL","columnsL","columnsM","singleContainerFullSize","uiLayout","Array","isArray","warn","addItem","tableElements","hasFormFields","renderElement","element","type","label","addContent","Title","text","elements","forEach","scope","startsWith","error","meta","bindingPath","propKey","resolveScope","isCollectionOfRecords","items","properties","hasExplicitWidget","ui","widget","isSubLayout","debug","push","this","_renderScalarField","field","subSchema","control","generateLayout","addStyleClass","msg","message","showErrorPopup","labelText","Label","required","effectiveMeta","generateField","fullWidth","sap","require","GridData","setLayoutData","span","__exports","__esModule"],"sources":["FormLayout.ts"],"sourcesContent":["/**\n * @file FormLayout.ts\n * @description Generates a fully responsive SAP Fiori Form layout (SimpleForm).\n */\n\nimport SimpleForm from \"sap/ui/layout/form/SimpleForm\";\nimport Label from \"sap/m/Label\";\nimport Title from \"sap/ui/core/Title\";\nimport VBox from \"sap/m/VBox\";\nimport { IPropertyMetadata, ISchema, ILayoutElement } from \"../interfaces/ISchema\";\nimport { ILayoutManager } from \"../interfaces/ILayoutManager\";\nimport { Engine } from \"../core/Engine\";\nimport { SchemaNormalizer } from \"../core/SchemaNormalizer\";\nimport { Logger } from \"../utils/Logger\";\nimport Control from \"sap/ui/core/Control\";\n\n/**\n * Layout Manager responsible for generating a fully responsive SAP Fiori SimpleForm.\n * It traverses the `uiLayout` tree defined in the schema to build the form groups and fields,\n * completely separating visual orchestration from data modeling.\n * @namespace nz.co.siliconst.ui5.metaui.layouts\n * @public\n */\nexport class FormLayout implements ILayoutManager {\n /**\n * Renders the JSON Schema properties into a UI5 SimpleForm using the uiLayout definitions.\n * \n * @param schema The active JSON schema subset.\n * @param modelName The bound UI5 model name.\n * @param engine The central orchestrator for delegating plugin generation.\n * @param onSubmit Optional submit hook.\n * @returns {Control} The VBox wrapper containing the generated form.\n */\n public render(schema: ISchema, modelName: string, engine: Engine, onSubmit?: () => void): Control {\n const container = new VBox({ renderType: \"Bare\" });\n const form = new SimpleForm({\n editable: true,\n title: schema.title,\n layout: \"ResponsiveGridLayout\",\n labelSpanXL: 4, labelSpanL: 4, labelSpanM: 4, labelSpanS: 12,\n adjustLabelSpan: false,\n emptySpanXL: 0, emptySpanL: 0, emptySpanM: 0, emptySpanS: 0,\n columnsXL: 1, columnsL: 1, columnsM: 1,\n singleContainerFullSize: false\n });\n\n if (!schema.uiLayout || !Array.isArray(schema.uiLayout)) {\n Logger.warn(\"[MetaUI] Missing 'uiLayout' array in schema. Form will not render any fields.\");\n container.addItem(form);\n return container;\n }\n\n const tableElements: { scope: string, meta: IPropertyMetadata, label?: string }[] = [];\n let hasFormFields = false;\n\n // Recursively render layout elements\n const renderElement = (element: ILayoutElement) => {\n if (element.type === \"Group\") {\n if (element.label) {\n form.addContent(new Title({ text: element.label }));\n }\n \n if (element.elements && Array.isArray(element.elements)) {\n element.elements.forEach(renderElement);\n }\n } else if (element.type === \"Control\") {\n if (!element.scope || !element.scope.startsWith(\"#/properties/\")) {\n Logger.error(`[MetaUI] Invalid scope '${element.scope}' in uiLayout Control.`, \"\", \"FormLayout\");\n return;\n }\n \n const { meta, bindingPath, propKey } = SchemaNormalizer.resolveScope(schema, element.scope);\n \n if (!meta) {\n Logger.error(`[MetaUI] Property '${propKey}' not found in schema definitions.`, \"\", \"FormLayout\");\n return;\n }\n\n // Architectural Boundary: Separate Field Controls (Plugins) from Sub-Layouts (LayoutManagers)\n // A property is delegated to a Sub-Layout Manager (Table) ONLY if it represents a collection of complex objects.\n // Collections of primitives, or explicitly assigned widgets (like multiSelect), remain in the Form as Field Plugins.\n const isCollectionOfRecords = meta.items?.type === \"object\" || meta.items?.properties;\n const hasExplicitWidget = !!meta.ui?.widget;\n const isSubLayout = meta.type === \"array\" && isCollectionOfRecords && !hasExplicitWidget;\n\n if (isSubLayout) {\n Logger.debug(\"[MetaUI FormLayout]\", `Routing property '${propKey}' to Table Sub-Layout.`, \"FormLayout\");\n tableElements.push({ scope: bindingPath, meta, label: element.label });\n } else {\n hasFormFields = true;\n Logger.debug(\"[MetaUI FormLayout]\", `Rendering scalar field '${bindingPath}'.`, \"FormLayout\");\n this._renderScalarField(form, element, bindingPath, meta, modelName, engine);\n }\n } else {\n Logger.warn(`[MetaUI] Unsupported layout element type '${element.type}'.`, \"\", \"FormLayout\");\n }\n };\n\n // Render everything defined in the layout\n schema.uiLayout.forEach(renderElement);\n\n if (hasFormFields) {\n container.addItem(form);\n }\n\n // Render array/table sub-layouts full width below the form\n tableElements.forEach(field => {\n try {\n const subSchema = {\n type: \"array\",\n title: field.label || field.meta.ui?.label || field.scope,\n items: field.meta.items || { type: \"object\", properties: {} },\n uiLayout: field.meta.items?.uiLayout // Pass down sub-layout if available\n };\n \n const control = engine.generateLayout(subSchema as ISchema, modelName, `/${field.scope}`);\n if (control) {\n control.addStyleClass(\"sapUiSmallMarginTop\");\n container.addItem(control);\n }\n } catch (error) {\n const msg = (error as Error).message;\n Logger.error(`[MetaUI] Failed to render array field ${field.scope}`, msg, \"FormLayout\");\n Logger.showErrorPopup(`Failed to render array field '${field.scope}'.\\n\\nDetails: ${msg}`);\n }\n });\n\n return container;\n }\n\n private _renderScalarField(form: SimpleForm, element: ILayoutElement, propKey: string, meta: IPropertyMetadata, modelName: string, engine: Engine): void {\n try {\n const labelText = element.label || meta.ui?.label || propKey;\n const label = new Label({\n text: labelText,\n required: meta.required\n });\n\n // Override widget if specified in the layout element\n const effectiveMeta = { ...meta };\n if (element.widget) {\n effectiveMeta.ui = { ...meta.ui, widget: element.widget };\n }\n\n const control = engine.generateField(effectiveMeta, `/${propKey}`, modelName);\n\n if (effectiveMeta.ui?.fullWidth) {\n sap.ui.require([\"sap/ui/layout/GridData\"], (GridData: any) => {\n control.setLayoutData(new GridData({ span: \"XL12 L12 M12 S12\" }));\n });\n }\n\n form.addContent(label);\n form.addContent(control);\n } catch (error) {\n const msg = (error as Error).message;\n Logger.error(`[MetaUI] Failed to render field ${propKey}`, msg, \"FormLayout\");\n Logger.showErrorPopup(`Failed to render field '${propKey}'.\\n\\nDetails: ${msg}`);\n }\n }\n}\n"],"mappings":"AAAA,yOAYSA,EAAgBC,EAAA,0BAChBC,EAAMC,EAAA,UAUR,MAAMC,EAUFC,OAAOC,EAAiBC,EAAmBC,EAAgBC,GAC9D,MAAMC,EAAY,IAAIC,EAAK,CAAEC,WAAY,SACzC,MAAMC,EAAO,IAAIC,EAAW,CACxBC,SAAU,KACVC,MAAOV,EAAOU,MACdC,OAAQ,uBACRC,YAAa,EAAGC,WAAY,EAAGC,WAAY,EAAGC,WAAY,GAC1DC,gBAAiB,MACjBC,YAAa,EAAGC,WAAY,EAAGC,WAAY,EAAGC,WAAY,EAC1DC,UAAW,EAAGC,SAAU,EAAGC,SAAU,EACrCC,wBAAyB,QAG7B,IAAKxB,EAAOyB,WAAaC,MAAMC,QAAQ3B,EAAOyB,UAAW,CACrD7B,EAAOgC,KAAK,iFACZxB,EAAUyB,QAAQtB,GAClB,OA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AOsE,eAAe,2BAA2BpB,mBAAyBkB,IAC9E,CACJ,EACH,IAAAc,EAAA,CAAAC,WAAA,MAAAD,EAAAhF,aAAA,OAAAgF,CAAA","ignoreList":[],"sourceRoot":"layouts"}},{"offset":{"line":26,"column":0},"map":{"version":3,"names":["SchemaNormalizer","___core_SchemaNormalizer","Logger","___utils_Logger","TableLayout","render","schema","modelName","engine","onSubmit","bindingPath","type","items","properties","Error","tableTitle","title","actualModelName","actualPath","table","Table","headerToolbar","Toolbar","content","Title","text","ToolbarSpacer","isDisplayMode","Button","icon","press","oEvent","btn","getSource","tbl","getParent","model","getModel","info","getBindingInfo","path","rawData","getProperty","data","Array","isArray","newData","setProperty","fixedLayout","mode","delete","item","getParameter","getBindingContext","getPath","splitPaths","split","index","parseInt","pop","arrayPath","join","splice","templateCells","props","layoutElements","uiLayout","forEach","element","scope","meta","fieldMeta","propKey","resolveScope","error","addColumn","Column","header","Text","label","ui","demandPopin","isKey","minScreenWidth","popinDisplay","effectiveMeta","widget","control","generateField","push","warn","debug","Object","keys","key","column","msg","message","showErrorPopup","rowTemplate","ColumnListItem","cells","bindItems","template","templateShareable","__exports","__esModule"],"sources":["TableLayout.ts"],"sourcesContent":["/**\n * @file TableLayout.ts\n * @description Generates a responsive SAP Fiori Table layout for v2 schema.\n */\n\nimport Table from \"sap/m/Table\";\nimport Column from \"sap/m/Column\";\nimport Text from \"sap/m/Text\";\nimport ColumnListItem from \"sap/m/ColumnListItem\";\nimport Toolbar from \"sap/m/Toolbar\";\nimport Title from \"sap/m/Title\";\nimport ToolbarSpacer from \"sap/m/ToolbarSpacer\";\nimport Button from \"sap/m/Button\";\nimport JSONModel from \"sap/ui/model/json/JSONModel\";\nimport Control from \"sap/ui/core/Control\";\nimport { IPropertyMetadata, ISchema, ILayoutElement } from \"../interfaces/ISchema\";\nimport { ILayoutManager } from \"../interfaces/ILayoutManager\";\nimport { Engine } from \"../core/Engine\";\nimport { SchemaNormalizer } from \"../core/SchemaNormalizer\";\nimport { Logger } from \"../utils/Logger\";\n\n/**\n * Layout Manager responsible for generating a responsive SAP Fiori Table.\n * It is automatically utilized by the Engine when the schema root or property is of type 'array'.\n * Includes built-in support for adding and deleting rows via dynamic data binding manipulation.\n * \n * @namespace nz.co.siliconst.ui5.metaui.layouts\n * @public\n */\nexport class TableLayout implements ILayoutManager {\n /**\n * Renders the JSON Schema array properties into a UI5 Table.\n * \n * @param schema The active JSON schema array definition.\n * @param modelName The UI5 JSONModel name used for data binding.\n * @param engine The central orchestrator for delegating column plugin generation.\n * @param onSubmit Optional submit hook.\n * @param bindingPath The JSON path representing the array within the payload.\n * @returns {Control} The generated sap.m.Table control.\n * @throws {Error} If the provided schema is not of type 'array'.\n */\n public render(schema: ISchema, modelName: string, engine: Engine, onSubmit?: () => void, bindingPath: string = \"/\"): Control {\n if (schema.type !== \"array\" || !schema.items || !schema.items.properties) {\n throw new Error(\"[MetaUI] TableLayout requires an array schema with items.properties.\");\n }\n\n const tableTitle = schema.title || \"Table\";\n const actualModelName = modelName;\n const actualPath = bindingPath;\n\n const table = new Table({\n headerToolbar: new Toolbar({\n content: [\n new Title({ text: tableTitle }),\n new ToolbarSpacer(),\n ...(engine.isDisplayMode ? [] : [\n new Button({\n text: \"Add Row\",\n icon: \"sap-icon://add\",\n press: (oEvent: sap.ui.base.Event) => {\n const btn = oEvent.getSource();\n const tbl = btn.getParent().getParent() as Table;\n const model = tbl.getModel(actualModelName) as JSONModel;\n const info = tbl.getBindingInfo(\"items\");\n if (!info || !info.path) return;\n\n const rawData = model.getProperty(info.path);\n const data = Array.isArray(rawData) ? rawData : [];\n const newData = [...data, {}];\n model.setProperty(info.path, newData);\n }\n })\n ])\n ]\n }),\n fixedLayout: false,\n mode: engine.isDisplayMode ? \"None\" : \"Delete\",\n delete: (oEvent: sap.ui.base.Event) => {\n const item = oEvent.getParameter(\"listItem\");\n const path = item.getBindingContext(actualModelName).getPath();\n const model = item.getModel(actualModelName) as JSONModel;\n\n const splitPaths = path.split(\"/\");\n const index = parseInt(splitPaths.pop() || \"0\", 10);\n let arrayPath = splitPaths.join(\"/\");\n if (arrayPath === \"\") arrayPath = \"/\";\n\n const rawData = model.getProperty(arrayPath);\n const data = Array.isArray(rawData) ? rawData : [];\n const newData = [...data];\n newData.splice(index, 1);\n model.setProperty(arrayPath, newData);\n }\n });\n\n const templateCells: Control[] = [];\n const props = schema.items.properties;\n const layoutElements = schema.uiLayout;\n\n if (layoutElements && Array.isArray(layoutElements)) {\n // Only render columns defined in uiLayout\n layoutElements.forEach((element: ILayoutElement) => {\n if (element.type === \"Control\" && element.scope) {\n const { meta: fieldMeta, bindingPath, propKey } = SchemaNormalizer.resolveScope(\n { type: \"object\", properties: props } as ISchema, \n element.scope\n );\n \n if (!fieldMeta) {\n Logger.error(`[MetaUI] Property '${propKey}' not found in schema definitions for Table.`, \"\", \"TableLayout\");\n } else {\n // The architectural boundary: Table Layout orchestrates the columns and aggregation binding,\n // but delegates the actual cell rendering to the Engine's Field Plugins.\n table.addColumn(new Column({\n header: new Text({ text: element.label || fieldMeta.ui?.label || propKey }),\n demandPopin: !fieldMeta.ui?.isKey,\n minScreenWidth: fieldMeta.ui?.isKey ? \"\" : \"Tablet\",\n popinDisplay: \"Inline\"\n }));\n\n const effectiveMeta = { ...fieldMeta };\n if (element.widget) {\n effectiveMeta.ui = { ...fieldMeta.ui, widget: element.widget };\n }\n\n // We pass the activeModel as actualModelName down. But the path must be relative to the \n // table row binding context, so we just use the bindingPath (e.g. \"id\" or \"header/id\")\n const control = engine.generateField(effectiveMeta, bindingPath, actualModelName || \"meta\", true);\n templateCells.push(control);\n }\n } else {\n Logger.warn(`[MetaUI] Unsupported layout element type '${element.type}' in Table.`, \"\", \"TableLayout\");\n }\n });\n } else {\n Logger.debug(\"[MetaUI TableLayout]\", \"No uiLayout provided. Falling back to rendering all properties as columns.\", \"TableLayout\");\n // Fallback: If no uiLayout is provided, render all properties as columns\n Object.keys(props).forEach((key) => {\n try {\n const fieldMeta = props[key];\n const isKey = !!fieldMeta.ui?.isKey;\n\n const column = new Column({\n header: new Text({ text: fieldMeta.ui?.label || key }),\n demandPopin: !isKey,\n minScreenWidth: isKey ? \"\" : \"Tablet\",\n popinDisplay: \"Inline\"\n });\n table.addColumn(column);\n\n const control = engine.generateField(fieldMeta, key, actualModelName || \"meta\", true);\n templateCells.push(control);\n } catch (error) {\n const msg = (error as Error).message;\n Logger.error(`[MetaUI] Failed to render fallback column ${key}`, msg, \"TableLayout\");\n Logger.showErrorPopup(`Failed to render fallback table column '${key}'.\\n\\nDetails: ${msg}`);\n templateCells.push(new Text({ text: \"Error\" }));\n }\n });\n }\n\n\n\n const rowTemplate = new ColumnListItem({\n cells: templateCells\n });\n\n table.bindItems({\n path: actualPath,\n model: actualModelName,\n template: rowTemplate,\n templateShareable: false\n });\n\n return table;\n }\n}\n"],"mappings":"AAAA,uSAkBSA,EAAgBC,EAAA,0BAChBC,EAAMC,EAAA,UAUR,MAAMC,EAYFC,OAAOC,EAAiBC,EAAmBC,EAAgBC,EAAuBC,EAAsB,KAC3G,GAAIJ,EAAOK,OAAS,UAAYL,EAAOM,QAAUN,EAAOM,MAAMC,WAAY,CACtE,MAAM,IAAIC,MAAM,uEACpB,CAEA,MAAMC,EAAaT,EAAOU,OAAS,QACnC,MAAMC,EAAkBV,EACxB,MAAMW,EAAaR,EAEnB,MAAMS,EAAQ,IAAIC,EAAM,CACpBC,cAAe,IAAIC,EAAQ,CACvBC,QAAS,CACL,IAAIC,EAAM,CAAEC,KAAMV,IAClB,IAAIW,KACAlB,EAAOmB,cAAgB,GAAK,CAC5B,IAAIC,EAAO,CACPH,KAAM,UACNI,KAAM,iBACNC,MAAQC,IACJ,MAAMC,EAAMD,EAAOE,YACnB,MAAMC,EAAMF,EAAIG,YAAYA,YAC5B,MAAMC,EAAQF,EAAIG,SAASpB,GAC3B,MAAMqB,EAAOJ,EAAIK,eAAe,SAChC,IAAKD,IAASA,EAAKE,KAAM,OAEzB,MAAMC,EAAUL,EAAM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},"map":{"version":3,"names":["SchemaNormalizer","___core_SchemaNormalizer","Logger","___utils_Logger","WizardLayout","render","schema","modelName","engine","onSubmit","wizard","Wizard","renderMode","showNextButton","complete","uiLayout","Array","isArray","warn","forEach","element","type","step","WizardStep","title","label","validated","form","SimpleForm","editable","layout","labelSpanXL","labelSpanL","labelSpanM","labelSpanS","adjustLabelSpan","emptySpanXL","emptySpanL","emptySpanM","emptySpanS","columnsXL","columnsL","columnsM","singleContainerFullSize","elements","childElement","this","_renderElementInForm","addContent","addStep","scope","startsWith","error","meta","bindingPath","propKey","resolveScope","labelText","ui","Label","text","required","effectiveMeta","widget","control","generateField","fullWidth","sap","require","GridData","setLayoutData","span","message","__exports","__esModule"],"sources":["WizardLayout.ts"],"sourcesContent":["/**\n * @file WizardLayout.ts\n * @description Generates a fully responsive SAP Fiori Wizard layout.\n */\n\nimport Wizard from \"sap/m/Wizard\";\nimport WizardStep from \"sap/m/WizardStep\";\nimport SimpleForm from \"sap/ui/layout/form/SimpleForm\";\nimport Label from \"sap/m/Label\";\nimport VBox from \"sap/m/VBox\";\nimport { IPropertyMetadata, ISchema, ILayoutElement } from \"../interfaces/ISchema\";\nimport { ILayoutManager } from \"../interfaces/ILayoutManager\";\nimport { Engine } from \"../core/Engine\";\nimport { SchemaNormalizer } from \"../core/SchemaNormalizer\";\nimport { Logger } from \"../utils/Logger\";\nimport Control from \"sap/ui/core/Control\";\n\n/**\n * Layout Manager responsible for generating a responsive SAP Fiori Wizard.\n * It segments the schema fields into discrete Wizard Steps based on `uiLayout` elements \n * of type `Group` or `WizardStep`.\n * \n * @namespace nz.co.siliconst.ui5.metaui.layouts\n * @public\n */\nexport class WizardLayout implements ILayoutManager {\n /**\n * Renders the JSON Schema properties into a paginated UI5 Wizard using uiLayout.\n * \n * @param schema The active JSON schema object.\n * @param modelName The bound UI5 model name.\n * @param engine The central orchestrator for delegating plugin generation.\n * @param onSubmit Hook executed when the Wizard's native 'complete' event is fired.\n * @returns {Control} The generated sap.m.Wizard control.\n */\n public render(schema: ISchema, modelName: string, engine: Engine, onSubmit?: () => void): Control {\n const wizard = new Wizard({\n renderMode: \"Page\",\n showNextButton: true,\n complete: function() {\n if (onSubmit) onSubmit();\n }\n });\n\n if (!schema.uiLayout || !Array.isArray(schema.uiLayout)) {\n Logger.warn(\"[MetaUI] Missing 'uiLayout' array in wizard schema. Wizard will not render any steps.\");\n return wizard;\n }\n\n schema.uiLayout.forEach((element: ILayoutElement) => {\n if (element.type === \"Group\" || element.type === \"WizardStep\") {\n const step = new WizardStep({\n title: element.label || \"Step\",\n validated: true // The PipelineManager handles global validation, wizard step validation can be local later\n });\n\n const form = new SimpleForm({\n editable: true,\n layout: \"ResponsiveGridLayout\",\n labelSpanXL: 4, labelSpanL: 4, labelSpanM: 4, labelSpanS: 12,\n adjustLabelSpan: false,\n emptySpanXL: 0, emptySpanL: 0, emptySpanM: 0, emptySpanS: 0,\n columnsXL: 1, columnsL: 1, columnsM: 1,\n singleContainerFullSize: false\n });\n \n if (element.elements && Array.isArray(element.elements)) {\n element.elements.forEach(childElement => {\n this._renderElementInForm(form, childElement, schema, modelName, engine);\n });\n }\n\n step.addContent(form);\n wizard.addStep(step);\n } else {\n Logger.warn(`[MetaUI] Top-level element '${element.type}' inside WizardLayout must be 'Group' or 'WizardStep'.`, \"\", \"WizardLayout\");\n }\n });\n\n return wizard;\n }\n\n private _renderElementInForm(form: SimpleForm, element: ILayoutElement, schema: ISchema, modelName: string, engine: Engine): void {\n if (element.type === \"Control\") {\n if (!element.scope || !element.scope.startsWith(\"#/properties/\")) {\n Logger.error(`[MetaUI] Invalid scope '${element.scope}' in uiLayout Control.`, \"\", \"WizardLayout\");\n return;\n }\n \n const { meta, bindingPath, propKey } = SchemaNormalizer.resolveScope(schema, element.scope);\n \n if (!meta) {\n Logger.error(`[MetaUI] Property '${propKey}' not found in schema definitions.`, \"\", \"WizardLayout\");\n return;\n }\n\n try {\n const labelText = element.label || meta.ui?.label || propKey;\n const label = new Label({\n text: labelText,\n required: meta.required\n });\n\n const effectiveMeta = { ...meta };\n if (element.widget) {\n effectiveMeta.ui = { ...meta.ui, widget: element.widget };\n }\n\n const control = engine.generateField(effectiveMeta, `/${bindingPath}`, modelName);\n\n if (effectiveMeta.ui?.fullWidth) {\n sap.ui.require([\"sap/ui/layout/GridData\"], (GridData: any) => {\n control.setLayoutData(new GridData({ span: \"XL12 L12 M12 S12\" }));\n });\n }\n\n form.addContent(label);\n form.addContent(control);\n } catch (error) {\n Logger.error(`[MetaUI] Failed to render Wizard field ${propKey}`, (error as Error).message, \"WizardLayout\");\n form.addContent(new Label({ text: propKey }));\n }\n } else {\n Logger.warn(`[MetaUI] Nested groups within Wizard steps are not fully supported in SimpleForm yet.`, \"\", \"WizardLayout\");\n }\n }\n}\n"],"mappings":"AAAA,4OAaSA,EAAgBC,EAAA,0BAChBC,EAAMC,EAAA,UAWR,MAAMC,EAUFC,OAAOC,EAAiBC,EAAmBC,EAAgBC,GAC9D,MAAMC,EAAS,IAAIC,EAAO,CACtBC,WAAY,OACZC,eAAgB,KAChBC,SAAU,WACN,GAAIL,EAAUA,GAClB,IAGJ,IAAKH,EAAOS,WAAaC,MAAMC,QAAQX,EAAOS,UAAW,CACrDb,EAAOgB,KAAK,yFACZ,OAAOR,CACX,CAEAJ,EAAOS,SAASI,QAASC,IACrB,GAAIA,EAAQC,OAAS,SAAWD,EAAQC,OAAS,aAAc,CAC3D,MAAMC,EAAO,IAAIC,EAAW,CACxBC,MAAOJ,EAAQK,OAAS,OACxBC,UAAW,OAGf,MAAMC,EAAO,IAAIC,EAAW,CACxBC,SAAU,KACVC,OAAQ,uBACRC,YAAa,EAAGC,WAAY,EAAGC,WAAY,EAAGC,WAAY,GAC1DC,gBAAiB,MACjBC,YAAa,EAAGC,WAAY,EAAGC,WAAY,EAAGC,WAAY,EAC1DC,UAAW,EAAGC,SAAU,EAAGC,SAAU,EACrCC,wBAAyB,QAG7B,GAAIvB,EAAQwB,UAAY5B,MAAMC,QAAQG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,gBAC5F7C,EAAKqB,WAAW,IAAIW,EAAM,CAAEC,KAAML,IACtC,CACJ,KAAO,CACHrD,EAAOgB,KAAK,wFAAyF,GAAI,eAC7G,CACJ,EACH,IAAAuD,EAAA,CAAAC,WAAA,MAAAD,EAAArE,eAAA,OAAAqE,CAAA","ignoreList":[],"sourceRoot":"layouts"}},{"offset":{"line":28,"column":0},"map":{"version":3,"names":["PluginRegistry","___core_PluginRegistry","StringPlugin","___plugins_controls_StringPlugin","NumberPlugin","___plugins_controls_NumberPlugin","BooleanPlugin","___plugins_controls_BooleanPlugin","DropdownPlugin","___plugins_controls_DropdownPlugin","DatePlugin","___plugins_controls_DatePlugin","TimePlugin","___plugins_controls_TimePlugin","DateTimePlugin","___plugins_controls_DateTimePlugin","ArrayPlugin","___plugins_controls_ArrayPlugin","TextAreaPlugin","___plugins_controls_TextAreaPlugin","SwitchPlugin","___plugins_controls_SwitchPlugin","LiveSearchPlugin","___plugins_datasources_LiveSearchPlugin","Core","initLibrary","name","version","dependencies","controls","elements","interfaces","noLibraryCSS","registry","getInstance","register","__exports","window"],"sources":["library.ts"],"sourcesContent":["/**\n * @file library.ts\n * @description Standard SAP UI5 library registration file. Exposes the MetaUI namespace \n * and automatically bootstraps the internal PluginRegistry.\n */\n\nimport Core from \"sap/ui/core/Core\";\nimport { PluginRegistry } from \"./core/PluginRegistry\";\nimport \"./core/LayoutRegistry\";\nimport { StringPlugin } from \"./plugins/controls/StringPlugin\";\nimport { NumberPlugin } from \"./plugins/controls/NumberPlugin\";\nimport { BooleanPlugin } from \"./plugins/controls/BooleanPlugin\";\nimport { DropdownPlugin } from \"./plugins/controls/DropdownPlugin\";\nimport { DatePlugin } from \"./plugins/controls/DatePlugin\";\nimport { TimePlugin } from \"./plugins/controls/TimePlugin\";\nimport { DateTimePlugin } from \"./plugins/controls/DateTimePlugin\";\nimport { ArrayPlugin } from \"./plugins/controls/ArrayPlugin\";\n\nimport { TextAreaPlugin } from \"./plugins/controls/TextAreaPlugin\";\nimport { SwitchPlugin } from \"./plugins/controls/SwitchPlugin\";\nimport { LiveSearchPlugin } from \"./plugins/datasources/LiveSearchPlugin\";\n\n// Delegate to standard library registration\nCore.initLibrary({\n name: \"nz.co.siliconst.ui5.metaui\",\n version: \"1.0.0\",\n dependencies: [\n \"sap.ui.core\",\n \"sap.m\",\n \"sap.ui.layout\",\n \"sap.ui.table\"\n ],\n controls: [\n \"nz.co.siliconst.ui5.metaui.controls.GeneratorHost\",\n \"nz.co.siliconst.ui5.metaui.controls.BaseHardwareControl\",\n \"nz.co.siliconst.ui5.metaui.controls.CameraControl\",\n \"nz.co.siliconst.ui5.metaui.controls.BarcodeScannerControl\",\n \"nz.co.siliconst.ui5.metaui.controls.SignatureControl\",\n \"nz.co.siliconst.ui5.metaui.controls.VoiceInputControl\",\n \"nz.co.siliconst.ui5.metaui.controls.GeolocationControl\",\n \"nz.co.siliconst.ui5.metaui.controls.RichTextControl\"\n ],\n elements: [],\n interfaces: [],\n noLibraryCSS: true\n});\n\n/**\n * Global Bootstrapper: Maps all standard primitive types to their respective plugins.\n */\nconst registry = PluginRegistry.getInstance();\nregistry.register(\"string\", StringPlugin);\nregistry.register(\"string\", TextAreaPlugin, \"textArea\");\nregistry.register(\"number\", NumberPlugin);\nregistry.register(\"boolean\", BooleanPlugin);\nregistry.register(\"boolean\", SwitchPlugin, \"switch\");\n// @ts-ignore: Custom UI widgets mapped back to string primitives for UI orchestration\nregistry.register(\"dropdown\", DropdownPlugin);\nregistry.register(\"date\", DatePlugin);\n// @ts-ignore\nregistry.register(\"time\", TimePlugin);\n// @ts-ignore\nregistry.register(\"datetime\", DateTimePlugin);\nregistry.register(\"array\", ArrayPlugin);\nregistry.register(\"string\", LiveSearchPlugin, \"liveSearch\");\n\n// Exporting window object safely for UI5 compatibility if needed\nexport default (window as unknown)[\"nz\"][\"co\"][\"siliconst\"][\"ui5\"][\"metaui\"];\n"],"mappings":"AAAA,ojBAOSA,EAAcC,EAAA,wBAEdC,EAAYC,EAAA,sBACZC,EAAYC,EAAA,sBACZC,EAAaC,EAAA,uBACbC,EAAcC,EAAA,wBACdC,EAAUC,EAAA,oBACVC,EAAUC,EAAA,oBACVC,EAAcC,EAAA,wBACdC,EAAWC,EAAA,qBAEXC,EAAcC,EAAA,wBACdC,EAAYC,EAAA,sBACZC,EAAgBC,EAAA,oBAGzBC,EAAKC,YAAY,CACbC,KAAM,6BACNC,QAAS,QACTC,aAAc,CACV,cACA,QACA,gBACA,gBAEJC,SAAU,CACN,oDACA,0DACA,oDACA,4DACA,uDACA,wDACA,yDACA,uDAEJC,SAAU,GACVC,WAAY,GACZC,aAAc,OAMlB,MAAMC,EAAWjC,EAAekC,cAChCD,EAASE,SAAS,SAAUjC,GAC5B+B,EAASE,SAAS,SAAUjB,EAAgB,YAC5Ce,EAASE,SAAS,SAAU/B,GAC5B6B,EAASE,SAAS,UAAW7B,GAC7B2B,EAASE,SAAS,UAAWf,EAAc,UAE3Ca,EAASE,SAAS,WAAY3B,GAC9ByB,EAASE,SAAS,OAAQzB,GAE1BuB,EAASE,SAAS,OAAQvB,GAE1BqB,EAASE,SAAS,WAAYrB,GAC9BmB,EAASE,SAAS,QAASnB,GAC3BiB,EAASE,SAAS,SAAUb,EAAkB,cAE9C,IAAAc,EACgBC,OAAmB,MAAM,MAAM,aAAa,OAAO,UAAS,OAAAD,CAAA","ignoreList":[],"sourceRoot":""}},{"offset":{"line":29,"column":0},"map":{"version":3,"names":["BasePlugin","___controls_BasePlugin","ClearFormActionPlugin","render","fieldMetadata","bindingPath","modelName","this","metadata","isDisplayMode","sap","ui","requireSync","TextControl","require","control","visible","Button","text","label","type","icon","press","oEvent","btn","getSource","model","getModel","setProperty","getValue","applyState","setEnabled","readOnly","__exports","__esModule"],"sources":["ClearFormActionPlugin.ts"],"sourcesContent":["/**\n * @file ClearFormActionPlugin.ts\n * @description A custom action plugin that renders a Button to reset the model data.\n */\n\nimport { BasePlugin } from \"../controls/BasePlugin\";\nimport { IPropertyMetadata } from \"../../interfaces/ISchema\";\nimport Button from \"sap/m/Button\";\nimport Control from \"sap/ui/core/Control\";\nimport JSONModel from \"sap/ui/model/json/JSONModel\";\n\n/**\n * A custom action plugin that renders a Button to reset the model data.\n * Demonstrates how to create functional action plugins that interact with the bound model.\n * \n * @namespace nz.co.siliconst.ui5.metaui.plugins.actions\n * @public\n */\nexport class ClearFormActionPlugin extends BasePlugin {\n public render(fieldMetadata: IPropertyMetadata, bindingPath: string, modelName: string = \"meta\"): Control {\n this.metadata = fieldMetadata;\n \n if (this.isDisplayMode) {\n sap.ui.requireSync(\"sap/m/Text\");\n const TextControl = sap.ui.require(\"sap/m/Text\");\n this.control = new TextControl({ visible: false });\n return this.control as Control;\n }\n \n this.control = new Button({\n text: fieldMetadata.ui?.label || \"Clear Data\",\n type: \"Reject\",\n icon: \"sap-icon://delete\",\n press: (oEvent: sap.ui.base.Event) => {\n const btn = oEvent.getSource() as Button;\n const model = btn.getModel(modelName) as JSONModel;\n if (model) {\n // Reset the entire model payload to an empty object\n model.setProperty(\"/\", {});\n }\n }\n });\n\n return this.control as Control;\n }\n\n protected getValue(): any {\n return null; // Actions do not store scalar values\n }\n\n protected applyState(): void {\n if (this.control && this.metadata) {\n if (this.isDisplayMode) return;\n (this.control as Button).setEnabled(!this.metadata.ui?.readOnly);\n }\n }\n}\n"],"mappings":"AAAA,0JAAA,MAKSA,EAAUC,EAAA,cAaZ,MAAMC,UAA8BF,EAChCG,OAAOC,EAAkCC,EAAqBC,EAAoB,QACrFC,KAAKC,SAAWJ,EAEhB,GAAIG,KAAKE,cAAe,CACpBC,IAAIC,GAAGC,YAAY,cACnB,MAAMC,EAAcH,IAAIC,GAAGG,QAAQ,cACnCP,KAAKQ,QAAU,IAAIF,EAAY,CAAEG,QAAS,QAC1C,OAAOT,KAAKQ,OAChB,CAEAR,KAAKQ,QAAU,IAAIE,EAAO,CACtBC,KAAMd,EAAcO,IAAIQ,OAAS,aACjCC,KAAM,SACNC,KAAM,oBACNC,MAAQC,IACJ,MAAMC,EAAMD,EAAOE,YACnB,MAAMC,EAAQF,EAAIG,SAASrB,GAC3B,GAAIoB,EAAO,CAEPA,EAAME,YAAY,IAAK,CAAC,EAC5B,KAIR,OAAOrB,KAAKQ,OAChB,CAEUc,WACN,OAAO,IACX,CAEUC,aACN,GAAIvB,KAAKQ,SAAWR,KAAKC,SAAU,CAC/B,GAAID,KAAKE,cAAe,OACvBF,KAAKQ,QAAmBgB,YAAYxB,KAAKC,SAASG,IAAIqB,SAC3D,CACJ,EACH,IAAAC,EAAA,CAAAC,WAAA,MAAAD,EAAA/B,wBAAA,OAAA+B,CAAA","ignoreList":[],"sourceRoot":"plugins/actions"}},{"offset":{"line":30,"column":0},"map":{"version":3,"names":["BasePlugin","___controls_BasePlugin","SubmitFormActionPlugin","render","fieldMetadata","bindingPath","modelName","this","metadata","isDisplayMode","sap","ui","requireSync","TextControl","require","control","visible","Button","text","label","type","icon","press","Core","getEventBus","publish","getValue","applyState","setEnabled","readOnly","__exports","__esModule"],"sources":["SubmitFormActionPlugin.ts"],"sourcesContent":["/**\n * @file SubmitFormActionPlugin.ts\n * @description A custom action plugin that triggers form submission.\n */\n\nimport { BasePlugin } from \"../controls/BasePlugin\";\nimport { IPropertyMetadata } from \"../../interfaces/ISchema\";\nimport Button from \"sap/m/Button\";\nimport Control from \"sap/ui/core/Control\";\nimport Core from \"sap/ui/core/Core\";\n\n/**\n * Renders a Button that requests the host container to execute its submit flow.\n * \n * @namespace nz.co.siliconst.ui5.metaui.plugins.actions\n * @public\n */\nexport class SubmitFormActionPlugin extends BasePlugin {\n public render(fieldMetadata: IPropertyMetadata, bindingPath: string, modelName: string = \"meta\"): Control {\n this.metadata = fieldMetadata;\n \n if (this.isDisplayMode) {\n sap.ui.requireSync(\"sap/m/Text\");\n const TextControl = sap.ui.require(\"sap/m/Text\");\n this.control = new TextControl({ visible: false });\n return this.control as Control;\n }\n \n this.control = new Button({\n text: fieldMetadata.ui?.label || \"Submit\",\n type: \"Emphasized\",\n icon: \"sap-icon://save\",\n press: () => {\n // Fire an event that the GeneratorHost or LayoutManager listens to\n // Suppressing TS error as UI5 1.118+ EventBus signature changed but still requires global bust cast\n // @ts-ignore\n (Core as unknown).getEventBus().publish(\"MetaUI\", \"TriggerSubmit\", {});\n }\n });\n\n return this.control as Control;\n }\n\n protected getValue(): any {\n return null;\n }\n\n protected applyState(): void {\n if (this.control && this.metadata) {\n if (this.isDisplayMode) return;\n (this.control as Button).setEnabled(!this.metadata.ui?.readOnly);\n }\n }\n}\n"],"mappings":"AAAA,gLAAA,MAKSA,EAAUC,EAAA,cAYZ,MAAMC,UAA+BF,EACjCG,OAAOC,EAAkCC,EAAqBC,EAAoB,QACrFC,KAAKC,SAAWJ,EAEhB,GAAIG,KAAKE,cAAe,CACpBC,IAAIC,GAAGC,YAAY,cACnB,MAAMC,EAAcH,IAAIC,GAAGG,QAAQ,cACnCP,KAAKQ,QAAU,IAAIF,EAAY,CAAEG,QAAS,QAC1C,OAAOT,KAAKQ,OAChB,CAEAR,KAAKQ,QAAU,IAAIE,EAAO,CACtBC,KAAMd,EAAcO,IAAIQ,OAAS,SACjCC,KAAM,aACNC,KAAM,kBACNC,MAAOA,KAIFC,EAAiBC,cAAcC,QAAQ,SAAU,gBAAiB,CAAC,MAI5E,OAAOlB,KAAKQ,OAChB,CAEUW,WACN,OAAO,IACX,CAEUC,aACN,GAAIpB,KAAKQ,SAAWR,KAAKC,SAAU,CAC/B,GAAID,KAAKE,cAAe,OACvBF,KAAKQ,QAAmBa,YAAYrB,KAAKC,SAASG,IAAIkB,SAC3D,CACJ,EACH,IAAAC,EAAA,CAAAC,WAAA,MAAAD,EAAA5B,yBAAA,OAAA4B,CAAA","ignoreList":[],"sourceRoot":"plugins/actions"}},{"offset":{"line":31,"column":0},"map":{"version":3,"names":["BasePlugin","___controls_BasePlugin","URLHelper","library","UrlNavigationActionPlugin","render","fieldMetadata","bindingPath","modelName","this","metadata","control","Button","text","ui","label","icon","press","targetUrl","args","redirect","getValue","applyState","setEnabled","readOnly","__exports","__esModule"],"sources":["UrlNavigationActionPlugin.ts"],"sourcesContent":["/**\n * @file UrlNavigationActionPlugin.ts\n * @description A custom action plugin that navigates to a URL.\n */\n\nimport { BasePlugin } from \"../controls/BasePlugin\";\nimport { IPropertyMetadata } from \"../../interfaces/ISchema\";\nimport Button from \"sap/m/Button\";\nimport Control from \"sap/ui/core/Control\";\nimport * as library from \"sap/m/library\";\nconst URLHelper = library.URLHelper;\n\n/**\n * Renders a Button that triggers a redirect to an external URL (defined in args).\n * \n * @namespace nz.co.siliconst.ui5.metaui.plugins.actions\n * @public\n */\nexport class UrlNavigationActionPlugin extends BasePlugin {\n public render(fieldMetadata: IPropertyMetadata, bindingPath: string, modelName: string = \"meta\"): Control {\n this.metadata = fieldMetadata;\n\n this.control = new Button({\n text: fieldMetadata.ui?.label || \"Open Link\",\n icon: \"sap-icon://action\",\n press: () => {\n // In a real scenario, the URL might come from the payload or from schema args\n const targetUrl = fieldMetadata.ui?.args || \"https://sap.com\";\n URLHelper.redirect(targetUrl as string, true); // true = open in new window\n }\n });\n\n return this.control as Control;\n }\n\n protected getValue(): any {\n return null;\n }\n\n protected applyState(): void {\n if (this.control && this.metadata) {\n (this.control as Button).setEnabled(!this.metadata.ui?.readOnly);\n }\n }\n}\n"],"mappings":"AAAA,gLAAA,MAKSA,EAAUC,EAAA,cAKnB,MAAMC,EAAYC,EAAQD,UAQnB,MAAME,UAAkCJ,EACpCK,OAAOC,EAAkCC,EAAqBC,EAAoB,QACrFC,KAAKC,SAAWJ,EAEhBG,KAAKE,QAAU,IAAIC,EAAO,CACtBC,KAAMP,EAAcQ,IAAIC,OAAS,YACjCC,KAAM,oBACNC,MAAOA,KAEH,MAAMC,EAAYZ,EAAcQ,IAAIK,MAAQ,kBAC5CjB,EAAUkB,SAASF,EAAqB,SAIhD,OAAOT,KAAKE,OAChB,CAEUU,WACN,OAAO,IACX,CAEUC,aACN,GAAIb,KAAKE,SAAWF,KAAKC,SAAU,CAC9BD,KAAKE,QAAmBY,YAAYd,KAAKC,SAASI,IAAIU,SAC3D,CACJ,EACH,IAAAC,EAAA,CAAAC,WAAA,MAAAD,EAAArB,4BAAA,OAAAqB,CAAA","ignoreList":[],"sourceRoot":"plugins/actions"}},{"offset":{"line":32,"column":0},"map":{"version":3,"names":["BasePlugin","___BasePlugin","ArrayPlugin","render","field","bindingPath","modelName","engineScopeId","onChange","this","metadata","propKey","startsWith","substring","subSchema","type","title","ui","label","items","properties","uiLayout","control","Button","id","generateStableId","text","isDisplayMode","icon","press","oEvent","btn","getSource","parentModel","getModel","bindingContext","getBindingContext","updatePath","ctxPath","getPath","endsWith","nestedData","getProperty","sap","require","GeneratorHost","host","schemaDefinition","data","displayMode","attachSubmit","e","payload","getParameter","setProperty","buttonText","dialogButtonText","openInDialog","getValue","applyState","__exports","__esModule"],"sources":["ArrayPlugin.ts"],"sourcesContent":["/**\n * @file ArrayPlugin.ts\n * @description Renders a button that drills down into a nested table (array) via a recursive Dialog using v2 schema.\n */\n\nimport { BasePlugin } from \"./BasePlugin\";\nimport { IPropertyMetadata } from \"../../interfaces/ISchema\";\nimport Control from \"sap/ui/core/Control\";\nimport Button from \"sap/m/Button\";\nimport JSONModel from \"sap/ui/model/json/JSONModel\";\n\nexport class ArrayPlugin extends BasePlugin {\n public render(field: IPropertyMetadata, bindingPath: string, modelName: string = \"meta\", engineScopeId?: string, onChange?: (isValid: boolean, fieldKey?: string) => void): Control {\n this.onChange = onChange;\n this.metadata = field;\n const propKey = bindingPath.startsWith(\"/\") ? bindingPath.substring(1) : bindingPath;\n \n const subSchema: any = {\n type: \"array\",\n title: field.ui?.label || propKey,\n items: field.items || {\n type: \"object\",\n properties: {} // inference will handle it if empty\n }\n };\n\n if (field.uiLayout) {\n subSchema.uiLayout = field.uiLayout;\n }\n\n this.control = new Button({\n id: this.generateStableId(engineScopeId, bindingPath),\n text: this.isDisplayMode ? \"View Records\" : \"Edit Records\",\n icon: this.isDisplayMode ? \"sap-icon://display\" : \"sap-icon://list\",\n press: (oEvent: sap.ui.base.Event) => {\n const btn = oEvent.getSource() as Button;\n const parentModel = btn.getModel(modelName) as JSONModel;\n if (!parentModel) return;\n \n const bindingContext = btn.getBindingContext(modelName);\n let updatePath = bindingPath;\n if (bindingContext && !bindingPath.startsWith(\"/\")) {\n const ctxPath = bindingContext.getPath();\n updatePath = ctxPath.endsWith(\"/\") ? ctxPath + bindingPath : (ctxPath === \"/\" ? \"/\" + bindingPath : ctxPath + \"/\" + bindingPath);\n }\n \n const nestedData = parentModel.getProperty(updatePath) || [];\n\n sap.ui.require([\"nz/co/siliconst/ui5/metaui/controls/host/GeneratorHost\"], (GeneratorHost: any) => {\n const host = new GeneratorHost({\n schemaDefinition: subSchema,\n data: nestedData,\n displayMode: this.isDisplayMode // Pass the display mode down to the child Engine!\n });\n\n // Only attach submit event if we are not in display mode\n if (!this.isDisplayMode) {\n host.attachSubmit((e: any) => {\n const payload = e.getParameter(\"payload\");\n parentModel.setProperty(updatePath, payload);\n });\n }\n\n const buttonText = field.ui?.dialogButtonText || (this.isDisplayMode ? \"Close\" : \"OK\");\n host.openInDialog(`Nested Records: ${field.ui?.label || propKey}`, buttonText);\n });\n }\n });\n \n return this.control as Control;\n }\n\n protected getValue(): any {\n return null;\n }\n\n protected applyState(): void {\n // dynamic state changes\n }\n}\n"],"mappings":"AAAA,uIAAA,MAKSA,EAAUC,EAAA,cAMZ,MAAMC,UAAoBF,EACtBG,OAAOC,EAA2BC,EAAsBC,EAAoB,OAAQC,EAAwBC,GAC/GC,KAAKD,SAAWA,EAChBC,KAAKC,SAAWN,EAChB,MAAMO,EAAUN,EAAYO,WAAW,KAAOP,EAAYQ,UAAU,GAAKR,EAEzE,MAAMS,EAAiB,CACnBC,KAAM,QACNC,MAAOZ,EAAMa,IAAIC,OAASP,EAC1BQ,MAAOf,EAAMe,OAAS,CAClBJ,KAAM,SACNK,WAAY,CAAC,IAIrB,GAAIhB,EAAMiB,SAAU,CAChBP,EAAUO,SAAWjB,EAAMiB,QAC/B,CAEAZ,KAAKa,QAAU,IAAIC,EAAO,CACtBC,GAAIf,KAAKgB,iBAAiBlB,EAAeF,GACzCqB,KAAMjB,KAAKkB,cAAgB,eAAiB,eAC5CC,KAAMnB,KAAKkB,cAAgB,qBAAuB,kBAClDE,MAAQC,IACJ,MAAMC,EAAMD,EAAOE,YACnB,MAAMC,EAAcF,EAAIG,SAAS5B,GACjC,IAAK2B,EAAa,OAElB,MAAME,EAAiBJ,EAAIK,kBAAkB9B,GAC7C,IAAI+B,EAAahC,EACjB,GAAI8B,IAAmB9B,EAAYO,WAAW,KAAM,CAChD,MAAM0B,EAAUH,EAAeI,UAC/BF,EAAaC,EAAQE,SAAS,KAAOF,EAAUjC,EAAeiC,IAAY,IAAM,IAAMjC,EAAciC,EAAU,IAAMjC,CACxH,CAEA,MAAMoC,EAAaR,EAAYS,YAAYL,IAAe,GAE1DM,IAAI1B,GAAG2B,QAAQ,CAAC,0DAA4DC,IACxE,MAAMC,EAAO,IAAID,EAAc,CAC3BE,iBAAkBjC,EAClBkC,KAAMP,EACNQ,YAAaxC,KAAKkB,gBAItB,IAAKlB,KAAKkB,cAAe,CACrBmB,EAAKI,aAAcC,IACf,MAAMC,EAAUD,EAAEE,aAAa,WAC/BpB,EAAYqB,YAAYjB,EAAYe,IAE5C,CAEA,MAAMG,EAAanD,EAAMa,IAAIuC,mBAAqB/C,KAAKkB,cAAgB,QAAU,MACjFmB,EAAKW,aAAa,mBAAmBrD,EAAMa,IAAIC,OAASP,IAAW4C,QAK/E,OAAO9C,KAAKa,OAChB,CAEUoC,WACN,OAAO,IACX,CAEUC,aACN,EAEP,IAAAC,EAAA,CAAAC,WAAA,MAAAD,EAAA1D,cAAA,OAAA0D,CAAA","ignoreList":[],"sourceRoot":"plugins/controls"}},{"offset":{"line":33,"column":0},"map":{"version":3,"names":["BasePlugin","___controls_BasePlugin","BarcodeScannerPlugin","render","metadata","bindingPath","modelName","engineScopeId","onChange","this","fieldKey","replace","isDisplayMode","sap","ui","requireSync","TextControl","require","control","id","generateStableId","text","applyCommonDirectives","inputControl","Input","value","editable","readOnly","width","change","result","validate","isValid","scannerBtn","BarcodeScannerButton","scanSuccess","oEvent","getParameter","setValue","model","getModel","setProperty","HBox","items","addStyleClass","getValue","applyState","setEditable","__exports","__esModule"],"sources":["BarcodeScannerPlugin.ts"],"sourcesContent":["import { BasePlugin } from \"../controls/BasePlugin\";\nimport { IPropertyMetadata } from \"../../interfaces/ISchema\";\nimport Control from \"sap/ui/core/Control\";\nimport HBox from \"sap/m/HBox\";\nimport Input from \"sap/m/Input\";\nimport JSONModel from \"sap/ui/model/json/JSONModel\";\n// @ts-ignore\nimport BarcodeScannerButton from \"sap/ndc/BarcodeScannerButton\";\n\nexport class BarcodeScannerPlugin extends BasePlugin {\n private inputControl!: Input;\n\n public render(metadata: IPropertyMetadata, bindingPath: string, modelName: string = \"meta\", engineScopeId?: string, onChange?: (isValid: boolean, fieldKey?: string) => void): Control {\n this.onChange = onChange;\n this.metadata = metadata;\n this.fieldKey = bindingPath.replace('/', '');\n this.modelName = modelName;\n\n if (this.isDisplayMode) {\n sap.ui.requireSync(\"sap/m/Text\");\n const TextControl = sap.ui.require(\"sap/m/Text\");\n this.control = new TextControl({\n id: this.generateStableId(engineScopeId, bindingPath),\n text: `{${modelName}>${bindingPath}}`\n });\n this.applyCommonDirectives(this.control, metadata, modelName);\n return this.control as Control;\n }\n\n this.inputControl = new Input({\n id: this.generateStableId(engineScopeId, bindingPath + \"-input\"),\n value: `{${modelName}>${bindingPath}}`,\n editable: !metadata.ui?.readOnly,\n width: \"100%\",\n change: () => {\n const result = this.validate();\n if (this.onChange) {\n this.onChange(result.isValid, this.fieldKey);\n }\n }\n });\n \n const scannerBtn = new BarcodeScannerButton({\n id: this.generateStableId(engineScopeId, bindingPath + \"-btn\"),\n scanSuccess: (oEvent: sap.ui.base.Event) => {\n const text = oEvent.getParameter(\"text\");\n if (text) {\n this.inputControl.setValue(text);\n // Update model explicitly since setValue doesn't always trigger two-way binding immediately\n const model = this.inputControl.getModel(this.modelName) as JSONModel;\n if (model) {\n model.setProperty(bindingPath, text);\n }\n const result = this.validate();\n if (this.onChange) {\n this.onChange(result.isValid, this.fieldKey);\n }\n }\n }\n });\n\n this.control = new HBox({\n id: this.generateStableId(engineScopeId, bindingPath),\n items: [this.inputControl, scannerBtn],\n width: \"100%\"\n }).addStyleClass(\"sapUiSmallMarginBottom\");\n\n this.applyCommonDirectives(this.control, metadata, modelName);\n\n return this.control as Control;\n }\n\n protected getValue(): any {\n return this.inputControl ? this.inputControl.getValue() : null;\n }\n\n protected applyState(): void {\n if (this.inputControl && this.metadata) {\n if (this.isDisplayMode) return;\n this.inputControl.setEditable(!this.metadata.ui?.readOnly);\n }\n }\n}\n"],"mappings":"AAAA,+MAASA,EAAUC,EAAA,cASZ,MAAMC,UAA6BF,EAG/BG,OAAOC,EAA8BC,EAAsBC,EAAoB,OAAQC,EAAwBC,GAClHC,KAAKD,SAAWA,EAChBC,KAAKL,SAAWA,EAChBK,KAAKC,SAAWL,EAAYM,QAAQ,IAAK,IACzCF,KAAKH,UAAYA,EAEjB,GAAIG,KAAKG,cAAe,CACpBC,IAAIC,GAAGC,YAAY,cACnB,MAAMC,EAAcH,IAAIC,GAAGG,QAAQ,cACnCR,KAAKS,QAAU,IAAIF,EAAY,CAC3BG,GAAIV,KAAKW,iBAAiBb,EAAeF,GACzCgB,KAAM,IAAIf,KAAaD,OAE3BI,KAAKa,sBAAsBb,KAAKS,QAASd,EAAUE,GACnD,OAAOG,KAAKS,OAChB,CAEAT,KAAKc,aAAe,IAAIC,EAAM,CAC1BL,GAAIV,KAAKW,iBAAiBb,EAAeF,EAAc,UACvDoB,MAAO,IAAInB,KAAaD,KACxBqB,UAAWtB,EAASU,IAAIa,SACxBC,MAAO,OACPC,OAAQA,KACJ,MAAMC,EAASrB,KAAKsB,WACpB,GAAItB,KAAKD,SAAU,CACfC,KAAKD,SAASsB,EAAOE,QAASvB,KAAKC,SACvC,KAIR,MAAMuB,EAAa,IAAIC,EAAqB,CACxCf,GAAIV,KAAKW,iBAAiBb,EAAeF,EAAc,QACvD8B,YAAcC,IACV,MAAMf,EAAOe,EAAOC,aAAa,QACjC,GAAIhB,EAAM,CACNZ,KAAKc,aAAae,SAASjB,GAE3B,MAAMkB,EAAQ9B,KAAKc,aAAaiB,SAAS/B,KAAKH,WAC9C,GAAIiC,EAAO,CACPA,EAAME,YAAYpC,EAAagB,EACnC,CACA,MAAMS,EAASrB,KAAKsB,WACxB,GAAItB,KAAKD,SAAU,CACfC,KAAKD,SAASsB,EAAOE,QAASvB,KAAKC,SACvC,CACA,KAIRD,KAAKS,QAAU,IAAIwB,EAAK,CACpBvB,GAAIV,KAAKW,iBAAiBb,EAAeF,GACzCsC,MAAO,CAAClC,KAAKc,aAAcU,GAC3BL,MAAO,SACRgB,cAAc,0BAEjBnC,KAAKa,sBAAsBb,KAAKS,QAASd,EAAUE,GAEnD,OAAOG,KAAKS,OAChB,CAEU2B,WACN,OAAOpC,KAAKc,aAAed,KAAKc,aAAasB,WAAa,IAC9D,CAEUC,aACN,GAAIrC,KAAKc,cAAgBd,KAAKL,SAAU,CACpC,GAAIK,KAAKG,cAAe,OACxBH,KAAKc,aAAawB,aAAatC,KAAKL,SAASU,IAAIa,SACrD,CACJ,EACH,IAAAqB,EAAA,CAAAC,WAAA,MAAAD,EAAA9C,uBAAA,OAAA8C,CAAA","ignoreList":[],"sourceRoot":"plugins/controls"}},{"offset":{"line":34,"column":0},"map":{"version":3,"names":["GlobalPipeline","____core_PipelineManager","BasePlugin","control","metadata","fieldKey","modelName","isDisplayMode","setDisplayMode","mode","this","generateStableId","engineScopeId","bindingPath","undefined","safePath","replace","validate","isValid","getVisible","validatorsToRun","argsMap","maxLength","required","push","ui","validators","v","name","args","length","errorMessage","val","getValue","result","executeValidation","onStateChange","newMetadata","applyState","applyCommonDirectives","readOnly","setEditable","visibleOn","expr","bindProperty","parts","path","formatter","enabledOn","setEnabled","destroy","__exports","__esModule"],"sources":["BasePlugin.ts"],"sourcesContent":["/**\n * @file BasePlugin.ts\n * @description Abstract foundation for all MetaUI plugins, enforcing lifecycle hooks for v2 Schema.\n */\n\nimport { IPlugin } from \"../../interfaces/IPlugin\";\nimport { IPropertyMetadata } from \"../../interfaces/ISchema\";\nimport Control from \"sap/ui/core/Control\";\nimport { GlobalPipeline } from \"../../core/PipelineManager\";\n\n/**\n * Abstract class representing a standard MetaUI Plugin.\n * Enforces the required rendering, state extraction, and validation contracts.\n * \n * @abstract\n * @public\n */\nexport abstract class BasePlugin implements IPlugin {\n /** The instantiated UI5 control for this plugin. */\n protected control: Control | null = null;\n \n /** The metadata schema defining the field rules. */\n protected metadata: IPropertyMetadata | null = null;\n \n /** The internal JSON path of the field relative to its parent payload. */\n protected fieldKey: string = \"\";\n \n /** The UI5 JSONModel name used for absolute binding paths. */\n protected modelName: string = \"meta\";\n\n /** Indicates if the engine is enforcing a read-only display mode. */\n protected isDisplayMode: boolean = false;\n \n /** Internal callback provided by GeneratorHost to signal validation/data changes upwards */\n protected onChange?: (isValid: boolean, fieldKey?: string, errorMessage?: string, controlId?: string) => void;\n\n /**\n * Injects the global display mode context into the plugin before rendering.\n * @param mode True if the plugin should render in a read-only display mode.\n */\n public setDisplayMode(mode: boolean): void {\n this.isDisplayMode = mode;\n }\n\n /**\n * Instantiates the raw UI5 control and binds it to the model.\n * \n * @param fieldMetadata The JSON Schema for the field.\n * @param bindingPath The JSON path to bind to.\n * @param modelName The UI5 model name.\n * @param engineScopeId The deterministic scope ID provided by the Engine to prevent cloning collisions.\n * @param onChange The callback fired natively when a field value blur/change occurs.\n * @returns {Control} The generated UI5 control.\n */\n public abstract render(fieldMetadata: IPropertyMetadata, bindingPath: string, modelName?: string, engineScopeId?: string, onChange?: (isValid: boolean, fieldKey?: string) => void): Control;\n\n /**\n * Generates a deterministic, globally unique ID for this control.\n * Prefixes the sanitized binding path with the Engine's scoped ID.\n */\n protected generateStableId(engineScopeId: string | undefined, bindingPath: string): string | undefined {\n if (!engineScopeId) return undefined;\n // Strip leading slash and replace internal slashes with hyphens\n const safePath = bindingPath.replace(/^\\//, '').replace(/\\//g, '-');\n return `${engineScopeId}--${safePath}`;\n }\n\n /**\n * Extracts the current raw value from the underlying UI5 control.\n */\n protected abstract getValue(): any;\n\n /**\n * Universal pipeline validation.\n */\n public validate(): import(\"../../interfaces/IPlugin\").IPluginValidationResult {\n if (!this.control || !this.metadata) return { isValid: true };\n \n // Skip validation for hidden fields (e.g. hidden by ConditionEngine visibleOn)\n if (typeof (this.control as unknown).getVisible === \"function\") {\n if (!(this.control as unknown).getVisible()) {\n return { isValid: true };\n }\n }\n \n const validatorsToRun: string[] = [];\n const argsMap: Record<string, any> = {\n \"maxLength\": this.metadata.maxLength\n };\n\n if (this.metadata.required) {\n validatorsToRun.push(\"required\");\n }\n if (this.metadata.maxLength) validatorsToRun.push(\"maxLength\");\n \n if (this.metadata.ui?.validators) {\n for (const v of this.metadata.ui.validators) {\n if (typeof v === \"string\") {\n validatorsToRun.push(v);\n } else if (v && v.name) {\n validatorsToRun.push(v.name);\n if (v.args !== undefined) {\n argsMap[v.name] = v.args;\n }\n }\n }\n }\n\n if (validatorsToRun.length === 0) {\n return { isValid: true, errorMessage: undefined, fieldKey: this.fieldKey };\n }\n\n const val = this.getValue();\n const result = GlobalPipeline.executeValidation(val, validatorsToRun, argsMap);\n return { isValid: result.isValid, errorMessage: result.errorMessage, fieldKey: this.fieldKey };\n }\n\n /**\n * Executes when the condition engine pushes new schema metadata to this field (e.g. readOnly changing).\n * @param newMetadata The mutated schema metadata.\n */\n public onStateChange(newMetadata: IPropertyMetadata): void {\n this.metadata = newMetadata;\n this.applyState();\n }\n\n /**\n * Abstract hook for the plugin to apply state changes to its specific UI5 control (e.g. placeholders, labels).\n */\n protected abstract applyState(): void;\n\n /**\n * Helper to apply common UI directives (like readOnly, visibleOn) directly to any control.\n */\n protected applyCommonDirectives(control: any, metadata: IPropertyMetadata, modelName: string = \"meta\"): void {\n if (metadata.ui?.readOnly !== undefined && typeof control.setEditable === \"function\") {\n control.setEditable(!metadata.ui.readOnly);\n }\n\n if (metadata.ui?.visibleOn) {\n const expr = `{= ${metadata.ui.visibleOn.replace(/\\$root\\./g, `${modelName}>/`).replace(/\\./g, '/')} }`;\n control.bindProperty(\"visible\", { parts: [{ path: \"meta>/\" }], formatter: () => false });\n // The ConditionEngine handles actual binding injection, but here we can set a fallback or natively bind if we bypass ConditionEngine.\n control.bindProperty(\"visible\", expr);\n }\n \n if (metadata.ui?.enabledOn && typeof control.setEnabled === \"function\") {\n const expr = `{= ${metadata.ui.enabledOn.replace(/\\$root\\./g, `${modelName}>/`).replace(/\\./g, '/')} }`;\n control.bindProperty(\"enabled\", expr);\n }\n }\n\n\n\n /**\n * Natively destroys the instantiated UI5 control to prevent memory leaks.\n * Can be overridden by subclasses if they manage secondary controls or custom models.\n */\n public destroy(): void {\n if (this.control && typeof this.control.destroy === \"function\") {\n this.control.destroy();\n this.control = null;\n }\n }\n}\n"],"mappings":"AAAA,mIAAA,MAQSA,EAAcC,EAAA,kBAShB,MAAeC,EAERC,QAA0B,KAG1BC,SAAqC,KAGrCC,SAAmB,GAGnBC,UAAoB,OAGpBC,cAAyB,MAS5BC,eAAeC,GAClBC,KAAKH,cAAgBE,CACzB,CAkBUE,iBAAiBC,EAAmCC,GAC1D,IAAKD,EAAe,OAAOE,UAE3B,MAAMC,EAAWF,EAAYG,QAAQ,MAAO,IAAIA,QAAQ,MAAO,KAC/D,MAAO,GAAGJ,MAAkBG,GAChC,CAUOE,WACH,IAAKP,KAAKP,UAAYO,KAAKN,SAAU,MAAO,CAAEc,QAAS,MAGvD,UAAYR,KAAKP,QAAoBgB,aAAe,WAAY,CAC5D,IAAMT,KAAKP,QAAoBgB,aAAc,CACzC,MAAO,CAAED,QAAS,KACtB,CACJ,CAEA,MAAME,EAA4B,GAClC,MAAMC,EAA+B,CACjCC,UAAaZ,KAAKN,SAAS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N,EAAO,MAAMvC,EAASqB,GAAGuB,UAAUhC,QAAQ,YAAa,GAAGV,OAAeU,QAAQ,MAAO,SAC/Fb,EAAQyC,aAAa,UAAWD,EACpC,CACJ,CAQOO,UACH,GAAIxC,KAAKP,gBAAkBO,KAAKP,QAAQ+C,UAAY,WAAY,CAC5DxC,KAAKP,QAAQ+C,UACbxC,KAAKP,QAAU,IACnB,CACJ,EACH,IAAAgD,EAAA,CAAAC,WAAA,MAAAD,EAAAjD,aAAA,OAAAiD,CAAA","ignoreList":[],"sourceRoot":"plugins/controls"}},{"offset":{"line":35,"column":0},"map":{"version":3,"names":["BasePlugin","___BasePlugin","BooleanPlugin","render","fieldMetadata","bindingPath","modelName","engineScopeId","onChange","this","metadata","isDisplayMode","sap","ui","requireSync","TextControl","require","control","id","generateStableId","text","path","formatter","val","applyCommonDirectives","CheckBox","selected","enabled","readOnly","select","oEvent","getParameter","result","validate","isValid","fieldKey","getValue","getSelected","applyState","setEnabled","__exports","__esModule"],"sources":["BooleanPlugin.ts"],"sourcesContent":["/**\n * @file BooleanPlugin.ts\n * @description Renders a sap.m.Switch for boolean states.\n */\n\nimport { BasePlugin } from \"./BasePlugin\";\nimport { IPropertyMetadata } from \"../../interfaces/ISchema\";\nimport CheckBox from \"sap/m/CheckBox\";\nimport Control from \"sap/ui/core/Control\";\n\n/**\n * Handles rendering logic for toggleable booleans using `sap.m.CheckBox`.\n * \n * @namespace nz.co.siliconst.ui5.metaui.plugins.controls\n * @public\n */\nexport class BooleanPlugin extends BasePlugin {\n /**\n * Renders a `sap.m.CheckBox` component for boolean evaluation.\n * \n * @param fieldMetadata The specific JSON schema properties for this field.\n * @param bindingPath The JSON path bound to this control.\n * @param modelName The UI5 JSONModel name.\n * @returns {Control} The configured CheckBox control.\n */\n public render(fieldMetadata: IPropertyMetadata, bindingPath: string, modelName: string = \"meta\", engineScopeId?: string, onChange?: (isValid: boolean, fieldKey?: string) => void): Control {\n this.onChange = onChange;\n this.metadata = fieldMetadata;\n \n if (this.isDisplayMode) {\n sap.ui.requireSync(\"sap/m/Text\");\n const TextControl = sap.ui.require(\"sap/m/Text\");\n this.control = new TextControl({\n id: this.generateStableId(engineScopeId, bindingPath),\n text: {\n path: `${modelName}>${bindingPath}`,\n formatter: (val: boolean) => val ? \"Yes\" : \"No\"\n }\n });\n this.applyCommonDirectives(this.control, fieldMetadata, modelName);\n return this.control as Control;\n }\n\n this.control = new CheckBox({\n id: this.generateStableId(engineScopeId, bindingPath),\n selected: `{${modelName}>${bindingPath}}`,\n enabled: !fieldMetadata.ui?.readOnly,\n select: (oEvent: sap.ui.base.Event) => {\n const val = oEvent.getParameter(\"selected\");\n const result = this.validate();\n if (this.onChange) {\n this.onChange(result.isValid, this.fieldKey);\n }\n }\n });\n\n return this.control as Control;\n }\n\n /**\n * Retrieves the current boolean state.\n * @returns {boolean} The selected state.\n */\n protected getValue(): any {\n return this.control ? (this.control as CheckBox).getSelected() : false;\n }\n\n /**\n * Applies dynamic read-only state.\n */\n protected applyState(): void {\n if (this.control && this.metadata) {\n if (this.isDisplayMode) return;\n (this.control as CheckBox).setEnabled(!this.metadata.ui?.readOnly);\n }\n }\n}\n"],"mappings":"AAAA,2IAAA,MAKSA,EAAUC,EAAA,cAWZ,MAAMC,UAAsBF,EASxBG,OAAOC,EAAmCC,EAAsBC,EAAoB,OAAQC,EAAwBC,GACvHC,KAAKD,SAAWA,EAChBC,KAAKC,SAAWN,EAEhB,GAAIK,KAAKE,cAAe,CACpBC,IAAIC,GAAGC,YAAY,cACnB,MAAMC,EAAcH,IAAIC,GAAGG,QAAQ,cACnCP,KAAKQ,QAAU,IAAIF,EAAY,CAC3BG,GAAIT,KAAKU,iBAAiBZ,EAAeF,GACzCe,KAAM,CACFC,KAAM,GAAGf,KAAaD,IACtBiB,UAAYC,GAAiBA,EAAM,MAAQ,QAGnDd,KAAKe,sBAAsBf,KAAKQ,QAASb,EAAeE,GACxD,OAAOG,KAAKQ,OAChB,CAEAR,KAAKQ,QAAU,IAAIQ,EAAS,CACxBP,GAAIT,KAAKU,iBAAiBZ,EAAeF,GACzCqB,SAAU,IAAIpB,KAAaD,KAC3BsB,SAAUvB,EAAcS,IAAIe,SAC5BC,OAASC,IACL,MAAMP,EAAMO,EAAOC,aAAa,YAChC,MAAMC,EAASvB,KAAKwB,WACpB,GAAIxB,KAAKD,SAAU,CACfC,KAAKD,SAASwB,EAAOE,QAASzB,KAAK0B,SACvC,KAIR,OAAO1B,KAAKQ,OAChB,CAMUmB,WACN,OAAO3B,KAAKQ,QAAWR,KAAKQ,QAAqBoB,cAAgB,KACrE,CAKUC,aACN,GAAI7B,KAAKQ,SAAWR,KAAKC,SAAU,CAC/B,GAAID,KAAKE,cAAe,OACvBF,KAAKQ,QAAqBsB,YAAY9B,KAAKC,SAASG,IAAIe,SAC7D,CACJ,EACH,IAAAY,EAAA,CAAAC,WAAA,MAAAD,EAAAtC,gBAAA,OAAAsC,CAAA","ignoreList":[],"sourceRoot":"plugins/controls"}},{"offset":{"line":36,"column":0},"map":{"version":3,"names":["BasePlugin","___controls_BasePlugin","CameraControl","_interopRequireDefault","__CameraControl","CameraPlugin","render","metadata","bindingPath","modelName","engineScopeId","onChange","this","fieldKey","replace","isDisplayMode","sap","ui","requireSync","ImageControl","require","control","id","generateStableId","src","width","alt","label","applyCommonDirectives","value","schemaMetadata","readOnly","attachCapture","result","validate","isValid","getValue","applyState","setProperty","__exports","__esModule"],"sources":["CameraPlugin.ts"],"sourcesContent":["import { BasePlugin } from \"../controls/BasePlugin\";\nimport { IPropertyMetadata } from \"../../interfaces/ISchema\";\nimport Control from \"sap/ui/core/Control\";\nimport CameraControl from \"../../controls/CameraControl\";\n\nexport class CameraPlugin extends BasePlugin {\n public render(metadata: IPropertyMetadata, bindingPath: string, modelName: string = \"meta\", engineScopeId?: string, onChange?: (isValid: boolean, fieldKey?: string) => void): Control {\n this.onChange = onChange;\n this.metadata = metadata;\n this.fieldKey = bindingPath.replace('/', '');\n this.modelName = modelName;\n\n if (this.isDisplayMode) {\n sap.ui.requireSync(\"sap/m/Image\");\n const ImageControl = sap.ui.require(\"sap/m/Image\");\n this.control = new ImageControl({\n id: this.generateStableId(engineScopeId, bindingPath),\n src: `{${modelName}>${bindingPath}}`,\n width: \"400px\",\n alt: metadata.ui?.label || \"Image\"\n });\n this.applyCommonDirectives(this.control, metadata, modelName);\n return this.control as Control;\n }\n\n this.control = new CameraControl({\n id: this.generateStableId(engineScopeId, bindingPath),\n value: `{${modelName}>${bindingPath}}`,\n schemaMetadata: metadata,\n readOnly: !!metadata.ui?.readOnly\n });\n\n this.applyCommonDirectives(this.control, metadata, modelName);\n\n // Validation mapping could be hooked into the 'capture' event if needed, but Two-Way binding updates the model naturally.\n (this.control as unknown as { attachCapture: (fn: Function) => void }).attachCapture(() => {\n const result = this.validate();\n if (this.onChange) {\n this.onChange(result.isValid, this.fieldKey);\n }\n });\n\n return this.control as Control;\n }\n\n protected getValue(): any {\n return this.control ? (this.control as unknown as { getValue: () => unknown }).getValue() : null;\n }\n\n protected applyState(): void {\n if (this.control && this.metadata) {\n if (this.isDisplayMode) return;\n (this.control as unknown as { setProperty: (k: string, v: unknown) => void }).setProperty(\"readOnly\", !!this.metadata.ui?.readOnly);\n }\n }\n}\n"],"mappings":"AAAA,yPAASA,EAAUC,EAAA,oBAGZC,EAAaC,EAAAC,GAEb,MAAMC,UAAqBL,EACvBM,OAAOC,EAA8BC,EAAsBC,EAAoB,OAAQC,EAAwBC,GAClHC,KAAKD,SAAWA,EAChBC,KAAKL,SAAWA,EAChBK,KAAKC,SAAWL,EAAYM,QAAQ,IAAK,IACzCF,KAAKH,UAAYA,EAEjB,GAAIG,KAAKG,cAAe,CACpBC,IAAIC,GAAGC,YAAY,eACnB,MAAMC,EAAeH,IAAIC,GAAGG,QAAQ,eACpCR,KAAKS,QAAU,IAAIF,EAAa,CAC5BG,GAAIV,KAAKW,iBAAiBb,EAAeF,GACzCgB,IAAK,IAAIf,KAAaD,KACtBiB,MAAO,QACPC,IAAKnB,EAASU,IAAIU,OAAS,UAE/Bf,KAAKgB,sBAAsBhB,KAAKS,QAASd,EAAUE,GACnD,OAAOG,KAAKS,OAChB,CAEAT,KAAKS,QAAU,IAAInB,EAAc,CAC7BoB,GAAIV,KAAKW,iBAAiBb,EAAeF,GACzCqB,MAAO,IAAIpB,KAAaD,KACxBsB,eAAgBvB,EAChBwB,WAAYxB,EAASU,IAAIc,WAG7BnB,KAAKgB,sBAAsBhB,KAAKS,QAASd,EAAUE,GAGlDG,KAAKS,QAAiEW,cAAc,KACjF,MAAMC,EAASrB,KAAKsB,WAChB,GAAItB,KAAKD,SAAU,CACfC,KAAKD,SAASsB,EAAOE,QAASvB,KAAKC,SACvC,IAGR,OAAOD,KAAKS,OAChB,CAEUe,WACN,OAAOxB,KAAKS,QAAWT,KAAKS,QAAmDe,WAAa,IAChG,CAEUC,aACN,GAAIzB,KAAKS,SAAWT,KAAKL,SAAU,CAC/B,GAAIK,KAAKG,cAAe,OACvBH,KAAKS,QAAwEiB,YAAY,aAAc1B,KAAKL,SAASU,IAAIc,SAC9H,CACJ,EACH,IAAAQ,EAAA,CAAAC,WAAA,MAAAD,EAAAlC,eAAA,OAAAkC,CAAA","ignoreList":[],"sourceRoot":"plugins/controls"}},{"offset":{"line":37,"column":0},"map":{"version":3,"names":["BasePlugin","___BasePlugin","CodeEditorPlugin","detectLanguage","value","trimmed","trim","startsWith","JSON","parse","e","test","adjustHeight","this","control","val","getValue","lines","split","length","newHeight","Math","max","setHeight","render","fieldMetadata","bindingPath","modelName","engineScopeId","onChange","metadata","fieldKey","replace","sap","ui","requireSync","CodeEditor","require","id","generateStableId","type","args","editable","isDisplayMode","readOnly","height","width","change","result","validate","isValid","currentVal","detectedType","getType","setType","attachEventOnce","oBinding","getBinding","initLogic","attachChange","applyCommonDirectives","applyState","setEditable","__exports","__esModule"],"sources":["CodeEditorPlugin.ts"],"sourcesContent":["/**\n * @file CodeEditorPlugin.ts\n * @description Renders a sap.ui.codeeditor.CodeEditor for editing source code/JSON.\n */\n\nimport { BasePlugin } from \"./BasePlugin\";\nimport { IPropertyMetadata } from \"../../interfaces/ISchema\";\nimport Control from \"sap/ui/core/Control\";\n\n/**\n * Handles rendering logic for code editing.\n * Requires the `sap.ui.codeeditor` library to be loaded.\n * \n * @namespace nz.co.siliconst.ui5.metaui.plugins.controls\n * @public\n */\nexport class CodeEditorPlugin extends BasePlugin {\n private detectLanguage(value: string): string {\n if (!value || typeof value !== \"string\") return \"javascript\";\n \n const trimmed = value.trim();\n if (trimmed === \"\") return \"javascript\";\n\n // 1. JSON\n if (trimmed.startsWith(\"{\") || trimmed.startsWith(\"[\")) {\n try {\n JSON.parse(trimmed);\n return \"json\";\n } catch (e) {\n // Not valid JSON, continue testing\n }\n }\n\n // 2. XML / HTML\n if (/^\\s*<[\\s\\S]*>\\s*$/.test(trimmed)) {\n return \"xml\";\n }\n\n // 3. Fallback to JavaScript\n return \"javascript\";\n }\n\n private adjustHeight(): void {\n if (!this.control) return;\n const val = (this.control as unknown as { getValue: () => unknown }).getValue() || \"\";\n const lines = val.split(/\\r\\n|\\r|\\n/).length;\n // 18px per line + 20px padding, minimum 100px\n const newHeight = Math.max(100, (lines * 18) + 20);\n (this.control as unknown).setHeight(newHeight + \"px\");\n }\n\n public render(fieldMetadata: IPropertyMetadata, bindingPath: string, modelName: string = \"meta\", engineScopeId?: string, onChange?: (isValid: boolean, fieldKey?: string) => void): Control {\n this.onChange = onChange;\n this.metadata = fieldMetadata;\n this.fieldKey = bindingPath.replace(\"/\", \"\"); // For EventBus\n \n sap.ui.requireSync(\"sap/ui/codeeditor/CodeEditor\");\n const CodeEditor = sap.ui.require(\"sap/ui/codeeditor/CodeEditor\");\n \n this.control = new CodeEditor({\n id: this.generateStableId(engineScopeId, bindingPath),\n value: `{${modelName}>${bindingPath}}`,\n type: fieldMetadata.ui?.args || \"javascript\", // will be dynamically overridden if args is missing\n editable: this.isDisplayMode ? false : !fieldMetadata.ui?.readOnly,\n height: \"100px\", // Initial minimum height\n width: \"100%\",\n change: () => {\n const result = this.validate();\n if (this.onChange) {\n this.onChange(result.isValid, this.fieldKey);\n }\n \n // If language isn't explicitly defined, try to guess it dynamically\n if (!fieldMetadata.ui?.args) {\n const currentVal = (this.control as unknown as { getValue: () => unknown }).getValue();\n const detectedType = this.detectLanguage(currentVal);\n if ((this.control as unknown).getType() !== detectedType) {\n (this.control as unknown).setType(detectedType);\n }\n }\n \n this.adjustHeight();\n }\n });\n\n // Clean architecture: Wait for the model context, then attach safely to the binding itself.\n // No timeouts, no DOM hacks, pure UI5 Eventing.\n (this.control as unknown).attachEventOnce(\"modelContextChange\", () => {\n const oBinding = (this.control as unknown).getBinding(\"value\");\n \n const initLogic = () => {\n if (this.control) {\n const currentVal = (this.control as unknown as { getValue: () => unknown }).getValue();\n if (!fieldMetadata.ui?.args) {\n (this.control as unknown).setType(this.detectLanguage(currentVal));\n }\n this.adjustHeight();\n }\n };\n\n if (oBinding) {\n // Attach for future model changes\n oBinding.attachChange(initLogic);\n }\n \n // Execute immediately in case the model is synchronous (JSONModel)\n initLogic();\n });\n\n this.applyCommonDirectives(this.control, fieldMetadata, modelName);\n\n return this.control as Control;\n }\n\n protected getValue(): any {\n return this.control ? (this.control as unknown as { getValue: () => unknown }).getValue() : null;\n }\n\n protected applyState(): void {\n if (this.control && this.metadata) {\n if (this.isDisplayMode) return;\n (this.control as unknown).setEditable(!this.metadata.ui?.readOnly);\n }\n }\n}\n"],"mappings":"AAAA,2HAAA,MAKSA,EAAUC,EAAA,cAWZ,MAAMC,UAAyBF,EAC1BG,eAAeC,GACnB,IAAKA,UAAgBA,IAAU,SAAU,MAAO,aAEhD,MAAMC,EAAUD,EAAME,OACtB,GAAID,IAAY,GAAI,MAAO,aAG3B,GAAIA,EAAQE,WAAW,MAAQF,EAAQE,WAAW,KAAM,CACpD,IACIC,KAAKC,MAAMJ,GACX,MAAO,MACX,CAAE,MAAOK,GACL,CAER,CAGA,GAAI,oBAAoBC,KAAKN,GAAU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,CACxB5B,KAAKC,QAAoBwC,QAAQzC,KAAKV,eAAegD,GAC1D,CACAtC,KAAKD,cACT,GAGJ,GAAI4C,EAAU,CAEVA,EAASG,aAAaD,EAC1B,CAGAA,MAGJ7C,KAAK+C,sBAAsB/C,KAAKC,QAASW,EAAeE,GAExD,OAAOd,KAAKC,OAChB,CAEUE,WACN,OAAOH,KAAKC,QAAWD,KAAKC,QAAmDE,WAAa,IAChG,CAEU6C,aACN,GAAIhD,KAAKC,SAAWD,KAAKiB,SAAU,CAC/B,GAAIjB,KAAK8B,cAAe,OACvB9B,KAAKC,QAAoBgD,aAAajD,KAAKiB,SAASI,IAAIU,SAC7D,CACJ,EACH,IAAAmB,EAAA,CAAAC,WAAA,MAAAD,EAAA7D,mBAAA,OAAA6D,CAAA","ignoreList":[],"sourceRoot":"plugins/controls"}},{"offset":{"line":38,"column":0},"map":{"version":3,"names":["BasePlugin","___BasePlugin","DatePlugin","render","fieldMetadata","bindingPath","modelName","engineScopeId","onChange","this","metadata","isDisplayMode","sap","ui","requireSync","TextControl","require","control","id","generateStableId","text","path","type","formatOptions","source","pattern","applyCommonDirectives","DatePicker","value","displayFormat","editable","readOnly","required","change","oEvent","val","getParameter","result","validate","isValid","fieldKey","getValue","applyState","dp","setEditable","setRequired","__exports","__esModule"],"sources":["DatePlugin.ts"],"sourcesContent":["/**\n * @file DatePlugin.ts\n * @description Renders a sap.m.DatePicker natively bound to ISO date strings.\n */\n\nimport { BasePlugin } from \"./BasePlugin\";\nimport { IPropertyMetadata } from \"../../interfaces/ISchema\";\nimport DatePicker from \"sap/m/DatePicker\";\nimport Control from \"sap/ui/core/Control\";\n\n/**\n * Handles rendering logic for Date strings.\n */\nexport class DatePlugin extends BasePlugin {\n public render(fieldMetadata: IPropertyMetadata, bindingPath: string, modelName: string = \"meta\", engineScopeId?: string, onChange?: (isValid: boolean, fieldKey?: string) => void): Control {\n this.onChange = onChange;\n this.metadata = fieldMetadata;\n \n if (this.isDisplayMode) {\n sap.ui.requireSync(\"sap/m/Text\");\n const TextControl = sap.ui.require(\"sap/m/Text\");\n this.control = new TextControl({\n id: this.generateStableId(engineScopeId, bindingPath),\n text: {\n path: `${modelName}>${bindingPath}`,\n type: \"sap.ui.model.type.Date\",\n formatOptions: {\n source: { pattern: \"yyyy-MM-dd\" },\n pattern: \"yyyy-MM-dd\"\n }\n }\n });\n this.applyCommonDirectives(this.control, fieldMetadata, modelName);\n return this.control as Control;\n }\n\n this.control = new DatePicker({\n id: this.generateStableId(engineScopeId, bindingPath),\n value: {\n path: `${modelName}>${bindingPath}`,\n type: \"sap.ui.model.type.Date\",\n formatOptions: {\n source: { pattern: \"yyyy-MM-dd\" },\n pattern: \"yyyy-MM-dd\"\n }\n },\n displayFormat: \"long\",\n editable: !fieldMetadata.ui?.readOnly,\n required: fieldMetadata.required,\n change: (oEvent: sap.ui.base.Event) => {\n const val = oEvent.getParameter(\"value\");\n const result = this.validate();\n if (this.onChange) {\n this.onChange(result.isValid, this.fieldKey);\n }\n }\n });\n\n return this.control as Control;\n }\n\n protected getValue(): any {\n return this.control ? (this.control as DatePicker).getValue() : null;\n }\n\n protected applyState(): void {\n if (this.control && this.metadata) {\n if (this.isDisplayMode) return;\n const dp = this.control as DatePicker;\n dp.setEditable(!this.metadata.ui?.readOnly);\n dp.setRequired(this.metadata.required);\n }\n }\n}\n"],"mappings":"AAAA,0IAAA,MAKSA,EAAUC,EAAA,cAQZ,MAAMC,UAAmBF,EACrBG,OAAOC,EAAmCC,EAAsBC,EAAoB,OAAQC,EAAwBC,GACvHC,KAAKD,SAAWA,EAChBC,KAAKC,SAAWN,EAEhB,GAAIK,KAAKE,cAAe,CACpBC,IAAIC,GAAGC,YAAY,cACnB,MAAMC,EAAcH,IAAIC,GAAGG,QAAQ,cACnCP,KAAKQ,QAAU,IAAIF,EAAY,CAC3BG,GAAIT,KAAKU,iBAAiBZ,EAAeF,GACzCe,KAAM,CACFC,KAAM,GAAGf,KAAaD,IACtBiB,KAAM,yBACNC,cAAe,CACXC,OAAQ,CAAEC,QAAS,cACnBA,QAAS,iBAIrBhB,KAAKiB,sBAAsBjB,KAAKQ,QAASb,EAAeE,GACxD,OAAOG,KAAKQ,OAChB,CAEAR,KAAKQ,QAAU,IAAIU,EAAW,CAC1BT,GAAIT,KAAKU,iBAAiBZ,EAAeF,GACzCuB,MAAO,CACHP,KAAM,GAAGf,KAAaD,IACtBiB,KAAM,yBACNC,cAAe,CACXC,OAAQ,CAAEC,QAAS,cACnBA,QAAS,eAGjBI,cAAe,OACfC,UAAW1B,EAAcS,IAAIkB,SAC7BC,SAAU5B,EAAc4B,SACxBC,OAASC,IACL,MAAMC,EAAMD,EAAOE,aAAa,SAChC,MAAMC,EAAS5B,KAAK6B,WACpB,GAAI7B,KAAKD,SAAU,CACfC,KAAKD,SAAS6B,EAAOE,QAAS9B,KAAK+B,SACvC,KAIR,OAAO/B,KAAKQ,OAChB,CAEUwB,WACN,OAAOhC,KAAKQ,QAAWR,KAAKQ,QAAuBwB,WAAa,IACpE,CAEUC,aACN,GAAIjC,KAAKQ,SAAWR,KAAKC,SAAU,CAC/B,GAAID,KAAKE,cAAe,OACxB,MAAMgC,EAAKlC,KAAKQ,QAChB0B,EAAGC,aAAanC,KAAKC,SAASG,IAAIkB,UAClCY,EAAGE,YAAYpC,KAAKC,SAASsB,SACjC,CACJ,EACH,IAAAc,EAAA,CAAAC,WAAA,MAAAD,EAAA5C,aAAA,OAAA4C,CAAA","ignoreList":[],"sourceRoot":"plugins/controls"}},{"offset":{"line":39,"column":0},"map":{"version":3,"names":["BasePlugin","___BasePlugin","DateTimePlugin","render","fieldMetadata","bindingPath","modelName","engineScopeId","onChange","this","metadata","isDisplayMode","sap","ui","requireSync","TextControl","require","control","id","generateStableId","text","path","type","formatOptions","source","pattern","applyCommonDirectives","DateTimePicker","value","editable","readOnly","required","change","oEvent","val","getParameter","result","validate","isValid","fieldKey","getValue","applyState","input","setEditable","setRequired","__exports","__esModule"],"sources":["DateTimePlugin.ts"],"sourcesContent":["/**\n * @file DateTimePlugin.ts\n * @description Handles rendering logic for DateTime strings (timestamps).\n */\n\nimport { BasePlugin } from \"./BasePlugin\";\nimport { IPropertyMetadata } from \"../../interfaces/ISchema\";\nimport DateTimePicker from \"sap/m/DateTimePicker\";\nimport Control from \"sap/ui/core/Control\";\n\n/**\n * Handles rendering and logic for timestamps/datetime inputs.\n */\nexport class DateTimePlugin extends BasePlugin {\n public render(fieldMetadata: IPropertyMetadata, bindingPath: string, modelName: string = \"meta\", engineScopeId?: string, onChange?: (isValid: boolean, fieldKey?: string) => void): Control {\n this.onChange = onChange;\n this.metadata = fieldMetadata;\n \n if (this.isDisplayMode) {\n sap.ui.requireSync(\"sap/m/Text\");\n const TextControl = sap.ui.require(\"sap/m/Text\");\n this.control = new TextControl({\n id: this.generateStableId(engineScopeId, bindingPath),\n text: {\n path: `${modelName}>${bindingPath}`,\n type: \"sap.ui.model.type.DateTime\",\n formatOptions: {\n source: { pattern: \"yyyy-MM-dd'T'HH:mm:ss'Z'\" },\n pattern: \"yyyy-MM-dd'T'HH:mm:ss'Z'\"\n }\n }\n });\n this.applyCommonDirectives(this.control, fieldMetadata, modelName);\n return this.control as Control;\n }\n\n this.control = new DateTimePicker({\n id: this.generateStableId(engineScopeId, bindingPath),\n value: {\n path: `${modelName}>${bindingPath}`,\n type: \"sap.ui.model.type.DateTime\",\n formatOptions: {\n source: { pattern: \"yyyy-MM-dd'T'HH:mm:ss'Z'\" },\n pattern: \"yyyy-MM-dd'T'HH:mm:ss'Z'\"\n }\n },\n editable: !fieldMetadata.ui?.readOnly,\n required: fieldMetadata.required,\n change: (oEvent: sap.ui.base.Event) => {\n const val = oEvent.getParameter(\"value\");\n const result = this.validate();\n if (this.onChange) {\n this.onChange(result.isValid, this.fieldKey);\n }\n }\n });\n\n this.applyCommonDirectives(this.control, fieldMetadata, modelName);\n\n return this.control as Control;\n }\n\n protected getValue(): any {\n return this.control ? (this.control as DateTimePicker).getValue() : null;\n }\n\n protected applyState(): void {\n if (this.control && this.metadata) {\n if (this.isDisplayMode) return;\n const input = this.control as DateTimePicker;\n input.setEditable(!this.metadata.ui?.readOnly);\n input.setRequired(this.metadata.required);\n }\n }\n}\n"],"mappings":"AAAA,kJAAA,MAKSA,EAAUC,EAAA,cAQZ,MAAMC,UAAuBF,EACzBG,OAAOC,EAAmCC,EAAsBC,EAAoB,OAAQC,EAAwBC,GACvHC,KAAKD,SAAWA,EAChBC,KAAKC,SAAWN,EAEhB,GAAIK,KAAKE,cAAe,CACpBC,IAAIC,GAAGC,YAAY,cACnB,MAAMC,EAAcH,IAAIC,GAAGG,QAAQ,cACnCP,KAAKQ,QAAU,IAAIF,EAAY,CAC3BG,GAAIT,KAAKU,iBAAiBZ,EAAeF,GACzCe,KAAM,CACFC,KAAM,GAAGf,KAAaD,IACtBiB,KAAM,6BACNC,cAAe,CACXC,OAAQ,CAAEC,QAAS,4BACnBA,QAAS,+BAIrBhB,KAAKiB,sBAAsBjB,KAAKQ,QAASb,EAAeE,GACxD,OAAOG,KAAKQ,OAChB,CAEAR,KAAKQ,QAAU,IAAIU,EAAe,CAC9BT,GAAIT,KAAKU,iBAAiBZ,EAAeF,GACzCuB,MAAO,CACHP,KAAM,GAAGf,KAAaD,IACtBiB,KAAM,6BACNC,cAAe,CACXC,OAAQ,CAAEC,QAAS,4BACnBA,QAAS,6BAGjBI,UAAWzB,EAAcS,IAAIiB,SAC7BC,SAAU3B,EAAc2B,SACxBC,OAASC,IACL,MAAMC,EAAMD,EAAOE,aAAa,SAChC,MAAMC,EAAS3B,KAAK4B,WACpB,GAAI5B,KAAKD,SAAU,CACfC,KAAKD,SAAS4B,EAAOE,QAAS7B,KAAK8B,SACvC,KAIR9B,KAAKiB,sBAAsBjB,KAAKQ,QAASb,EAAeE,GAExD,OAAOG,KAAKQ,OAChB,CAEUuB,WACN,OAAO/B,KAAKQ,QAAWR,KAAKQ,QAA2BuB,WAAa,IACxE,CAEUC,aACN,GAAIhC,KAAKQ,SAAWR,KAAKC,SAAU,CAC/B,GAAID,KAAKE,cAAe,OACxB,MAAM+B,EAAQjC,KAAKQ,QACnByB,EAAMC,aAAalC,KAAKC,SAASG,IAAIiB,UACrCY,EAAME,YAAYnC,KAAKC,SAASqB,SACpC,CACJ,EACH,IAAAc,EAAA,CAAAC,WAAA,MAAAD,EAAA3C,iBAAA,OAAA2C,CAAA","ignoreList":[],"sourceRoot":"plugins/controls"}},{"offset":{"line":40,"column":0},"map":{"version":3,"names":["BasePlugin","___BasePlugin","DropdownPlugin","render","fieldMetadata","bindingPath","modelName","engineScopeId","onChange","this","metadata","isDisplayMode","sap","ui","requireSync","TextControl","require","valueHelpArray","valueHelp","Array","isArray","enum","map","e","key","String","text","control","id","generateStableId","path","formatter","match","find","vh","applyCommonDirectives","select","Select","selectedKey","enabled","readOnly","forceSelection","change","oEvent","item","getParameter","val","getKey","result","validate","isValid","fieldKey","length","addItem","Item","forEach","getValue","getSelectedKey","applyState","setEnabled","__exports","__esModule"],"sources":["DropdownPlugin.ts"],"sourcesContent":["/**\n * @file DropdownPlugin.ts\n * @description Renders a sap.m.Select utilizing the schema's valueHelp structure.\n */\n\nimport { BasePlugin } from \"./BasePlugin\";\nimport { IPropertyMetadata } from \"../../interfaces/ISchema\";\nimport Select from \"sap/m/Select\";\nimport Item from \"sap/ui/core/Item\";\nimport Control from \"sap/ui/core/Control\";\n\n/**\n * Handles rendering logic for dropdown inputs.\n * Maps the static `valueHelp` schema array to `sap.ui.core.Item` elements.\n * \n * @namespace nz.co.siliconst.ui5.metaui.plugins.controls\n * @public\n */\nexport class DropdownPlugin extends BasePlugin {\n /**\n * Renders a `sap.m.Select` component populated with schema-defined value help.\n * \n * @param fieldMetadata The specific JSON schema properties for this field.\n * @param bindingPath The JSON path bound to this control.\n * @param modelName The UI5 JSONModel name.\n * @returns {Control} The configured Select control.\n */\n public render(fieldMetadata: IPropertyMetadata, bindingPath: string, modelName: string = \"meta\", engineScopeId?: string, onChange?: (isValid: boolean, fieldKey?: string) => void): Control {\n this.onChange = onChange;\n this.metadata = fieldMetadata;\n \n if (this.isDisplayMode) {\n sap.ui.requireSync(\"sap/m/Text\");\n const TextControl = sap.ui.require(\"sap/m/Text\");\n \n const valueHelpArray = fieldMetadata.valueHelp && Array.isArray(fieldMetadata.valueHelp) \n ? fieldMetadata.valueHelp \n : (fieldMetadata.enum ? fieldMetadata.enum.map(e => ({ key: String(e), text: String(e) })) : []);\n \n this.control = new TextControl({\n id: this.generateStableId(engineScopeId, bindingPath),\n text: {\n path: `${modelName}>${bindingPath}`,\n formatter: (key: string) => {\n const match = valueHelpArray.find(vh => vh.key === key);\n return match ? match.text : key;\n }\n }\n });\n this.applyCommonDirectives(this.control, fieldMetadata, modelName);\n return this.control as Control;\n }\n\n const select = new Select({\n id: this.generateStableId(engineScopeId, bindingPath),\n selectedKey: `{${modelName}>${bindingPath}}`,\n enabled: !fieldMetadata.ui?.readOnly,\n forceSelection: false,\n change: (oEvent: sap.ui.base.Event) => {\n const item = oEvent.getParameter(\"selectedItem\");\n const val = item ? item.getKey() : \"\";\n const result = this.validate();\n if (this.onChange) {\n this.onChange(result.isValid, this.fieldKey);\n }\n }\n });\n\n const valueHelpArray = fieldMetadata.valueHelp && Array.isArray(fieldMetadata.valueHelp) \n ? fieldMetadata.valueHelp \n : (fieldMetadata.enum ? fieldMetadata.enum.map(e => ({ key: String(e), text: String(e) })) : []);\n\n if (valueHelpArray.length > 0) {\n // Always add the empty placeholder so that 'required' checks can actually fire if the user hasn't made a choice\n select.addItem(new Item({ key: \"\", text: \"--- Select ---\" }));\n \n valueHelpArray.forEach(vh => {\n select.addItem(new Item({ key: vh.key, text: vh.text }));\n });\n }\n\n this.control = select;\n this.applyCommonDirectives(this.control, fieldMetadata, modelName);\n return this.control as Control;\n }\n\n /**\n * Retrieves the currently selected key.\n * @returns {any} The selected key.\n */\n protected getValue(): any {\n return this.control ? (this.control as Select).getSelectedKey() : null;\n }\n\n /**\n * Applies dynamic metadata state (e.g. readOnly) when the ConditionEngine fires.\n */\n protected applyState(): void {\n if (this.control && this.metadata) {\n if (this.isDisplayMode) return;\n const select = this.control as Select;\n select.setEnabled(!this.metadata.ui?.readOnly);\n }\n }\n}\n"],"mappings":"AAAA,+JAAA,MAKSA,EAAUC,EAAA,cAaZ,MAAMC,UAAuBF,EASzBG,OAAOC,EAAmCC,EAAsBC,EAAoB,OAAQC,EAAwBC,GACvHC,KAAKD,SAAWA,EAChBC,KAAKC,SAAWN,EAEhB,GAAIK,KAAKE,cAAe,CACpBC,IAAIC,GAAGC,YAAY,cACnB,MAAMC,EAAcH,IAAIC,GAAGG,QAAQ,cAEnC,MAAMC,EAAiBb,EAAcc,WAAaC,MAAMC,QAAQhB,EAAcc,WACxEd,EAAcc,UACbd,EAAciB,KAAOjB,EAAciB,KAAKC,IAAIC,IAAC,CAAOC,IAAKC,OAAOF,GAAIG,KAAMD,OAAOF,MAAS,GAEjGd,KAAKkB,QAAU,IAAIZ,EAAY,CAC3Ba,GAAInB,KAAKoB,iBAAiBtB,EAAeF,GACzCqB,KAAM,CACFI,KAAM,GAAGxB,KAAaD,IACtB0B,UAAYP,IACR,MAAMQ,EAAQf,EAAegB,KAAKC,GAAMA,EAAGV,MAAQA,GACnD,OAAOQ,EAAQA,EAAMN,KAAOF,MAIxCf,KAAK0B,sBAAsB1B,KAAKkB,QAASvB,EAAeE,GACxD,OAAOG,KAAKkB,OAChB,CAEA,MAAMS,EAAS,IAAIC,EAAO,CACtBT,GAAInB,KAAKoB,iBAAiBtB,EAAeF,GACzCiC,YAAa,IAAIhC,KAAaD,KAC9BkC,SAAUnC,EAAcS,IAAI2B,SAC5BC,eAAgB,MAChBC,OAASC,IACL,MAAMC,EAAOD,EAAOE,aAAa,gBACjC,MAAMC,EAAMF,EAAOA,EAAKG,SAAW,GACnC,MAAMC,EAASvC,KAAKwC,WACpB,GAAIxC,KAAKD,SAAU,CACfC,KAAKD,SAASwC,EAAOE,QAASzC,KAAK0C,SACvC,KAIR,MAAMlC,EAAiBb,EAAcc,WAAaC,MAAMC,QAAQhB,EAAcc,WACxEd,EAAcc,UACbd,EAAciB,KAAOjB,EAAciB,KAAKC,IAAIC,IAAC,CAAOC,IAAKC,OAAOF,GAAIG,KAAMD,OAAOF,MAAS,GAEjG,GAAIN,EAAemC,OAAS,EAAG,CAE3BhB,EAAOiB,QAAQ,IAAIC,EAAK,CAAE9B,IAAK,GAAIE,KAAM,oBAEzCT,EAAesC,QAAQrB,IACnBE,EAAOiB,QAAQ,IAAIC,EAAK,CAAE9B,IAAKU,EAAGV,IAAKE,KAAMQ,EAAGR,SAExD,CAEAjB,KAAKkB,QAAUS,EACf3B,KAAK0B,sBAAsB1B,KAAKkB,QAASvB,EAAeE,GACxD,OAAOG,KAAKkB,OAChB,CAMU6B,WACN,OAAO/C,KAAKkB,QAAWlB,KAAKkB,QAAmB8B,iBAAmB,IACtE,CAKUC,aACN,GAAIjD,KAAKkB,SAAWlB,KAAKC,SAAU,CAC/B,GAAID,KAAKE,cAAe,OACxB,MAAMyB,EAAS3B,KAAKkB,QACpBS,EAAOuB,YAAYlD,KAAKC,SAASG,IAAI2B,SACzC,CACJ,EACH,IAAAoB,EAAA,CAAAC,WAAA,MAAAD,EAAA1D,iBAAA,OAAA0D,CAAA","ignoreList":[],"sourceRoot":"plugins/controls"}},{"offset":{"line":41,"column":0},"map":{"version":3,"names":["BasePlugin","___BasePlugin","FileUploaderPlugin","render","fieldMetadata","bindingPath","modelName","engineScopeId","onChange","this","metadata","isDisplayMode","sap","ui","requireSync","LinkControl","require","control","id","generateStableId","text","href","target","applyCommonDirectives","FileUploader","value","enabled","readOnly","placeholder","label","width","change","oEvent","val","getParameter","result","validate","isValid","fieldKey","getValue","applyState","setEnabled","__exports","__esModule"],"sources":["FileUploaderPlugin.ts"],"sourcesContent":["/**\n * @file FileUploaderPlugin.ts\n * @description Renders a sap.ui.unified.FileUploader.\n */\n\nimport { BasePlugin } from \"./BasePlugin\";\nimport { IPropertyMetadata } from \"../../interfaces/ISchema\";\nimport FileUploader from \"sap/ui/unified/FileUploader\";\nimport Control from \"sap/ui/core/Control\";\n\n/**\n * Handles rendering logic for file uploads.\n * \n * @namespace nz.co.siliconst.ui5.metaui.plugins.controls\n * @public\n */\nexport class FileUploaderPlugin extends BasePlugin {\n public render(fieldMetadata: IPropertyMetadata, bindingPath: string, modelName: string = \"meta\", engineScopeId?: string, onChange?: (isValid: boolean, fieldKey?: string) => void): Control {\n this.onChange = onChange;\n this.metadata = fieldMetadata;\n \n if (this.isDisplayMode) {\n sap.ui.requireSync(\"sap/m/Link\");\n const LinkControl = sap.ui.require(\"sap/m/Link\");\n this.control = new LinkControl({\n id: this.generateStableId(engineScopeId, bindingPath),\n text: `{${modelName}>${bindingPath}}`,\n href: `{${modelName}>${bindingPath}}`, // Assuming the value is a URL to the file\n target: \"_blank\"\n });\n this.applyCommonDirectives(this.control, fieldMetadata, modelName);\n return this.control as Control;\n }\n\n this.control = new FileUploader({\n id: this.generateStableId(engineScopeId, bindingPath),\n value: `{${modelName}>${bindingPath}}`,\n enabled: !fieldMetadata.ui?.readOnly,\n placeholder: fieldMetadata.ui?.label || \"Choose a file...\",\n width: \"100%\",\n change: (oEvent: sap.ui.base.Event) => {\n const val = oEvent.getParameter(\"newValue\");\n const result = this.validate();\n if (this.onChange) {\n this.onChange(result.isValid, this.fieldKey);\n }\n }\n });\n\n this.applyCommonDirectives(this.control, fieldMetadata, modelName);\n return this.control as Control;\n }\n\n protected getValue(): any {\n return this.control ? (this.control as FileUploader).getValue() : null;\n }\n\n protected applyState(): void {\n if (this.control && this.metadata) {\n if (this.isDisplayMode) return;\n (this.control as FileUploader).setEnabled(!this.metadata.ui?.readOnly);\n }\n }\n}\n"],"mappings":"AAAA,6JAAA,MAKSA,EAAUC,EAAA,cAWZ,MAAMC,UAA2BF,EAC7BG,OAAOC,EAAmCC,EAAsBC,EAAoB,OAAQC,EAAwBC,GACvHC,KAAKD,SAAWA,EAChBC,KAAKC,SAAWN,EAEhB,GAAIK,KAAKE,cAAe,CACpBC,IAAIC,GAAGC,YAAY,cACnB,MAAMC,EAAcH,IAAIC,GAAGG,QAAQ,cACnCP,KAAKQ,QAAU,IAAIF,EAAY,CAC3BG,GAAIT,KAAKU,iBAAiBZ,EAAeF,GACzCe,KAAM,IAAId,KAAaD,KACvBgB,KAAM,IAAIf,KAAaD,KACvBiB,OAAQ,WAEZb,KAAKc,sBAAsBd,KAAKQ,QAASb,EAAeE,GACxD,OAAOG,KAAKQ,OAChB,CAEAR,KAAKQ,QAAU,IAAIO,EAAa,CAC5BN,GAAIT,KAAKU,iBAAiBZ,EAAeF,GACzCoB,MAAO,IAAInB,KAAaD,KACxBqB,SAAUtB,EAAcS,IAAIc,SAC5BC,YAAaxB,EAAcS,IAAIgB,OAAS,mBACxCC,MAAO,OACPC,OAASC,IACL,MAAMC,EAAMD,EAAOE,aAAa,YAChC,MAAMC,EAAS1B,KAAK2B,WACpB,GAAI3B,KAAKD,SAAU,CACfC,KAAKD,SAAS2B,EAAOE,QAAS5B,KAAK6B,SACvC,KAIR7B,KAAKc,sBAAsBd,KAAKQ,QAASb,EAAeE,GACxD,OAAOG,KAAKQ,OAChB,CAEUsB,WACN,OAAO9B,KAAKQ,QAAWR,KAAKQ,QAAyBsB,WAAa,IACtE,CAEUC,aACN,GAAI/B,KAAKQ,SAAWR,KAAKC,SAAU,CAC/B,GAAID,KAAKE,cAAe,OACvBF,KAAKQ,QAAyBwB,YAAYhC,KAAKC,SAASG,IAAIc,SACjE,CACJ,EACH,IAAAe,EAAA,CAAAC,WAAA,MAAAD,EAAAxC,qBAAA,OAAAwC,CAAA","ignoreList":[],"sourceRoot":"plugins/controls"}},{"offset":{"line":42,"column":0},"map":{"version":3,"names":["BasePlugin","___controls_BasePlugin","GeolocationControl","_interopRequireDefault","__GeolocationControl","GeolocationPlugin","render","metadata","bindingPath","modelName","engineScopeId","onChange","this","fieldKey","replace","isDisplayMode","sap","ui","requireSync","TextControl","require","control","id","generateStableId","text","path","formatter","val","lat","undefined","lng","applyCommonDirectives","value","schemaMetadata","readOnly","attachCapture","result","validate","isValid","getValue","applyState","setProperty","__exports","__esModule"],"sources":["GeolocationPlugin.ts"],"sourcesContent":["import { BasePlugin } from \"../controls/BasePlugin\";\nimport { IPropertyMetadata } from \"../../interfaces/ISchema\";\nimport Control from \"sap/ui/core/Control\";\nimport GeolocationControl from \"../../controls/GeolocationControl\";\n\nexport class GeolocationPlugin extends BasePlugin {\n public render(metadata: IPropertyMetadata, bindingPath: string, modelName: string = \"meta\", engineScopeId?: string, onChange?: (isValid: boolean, fieldKey?: string) => void): Control {\n this.onChange = onChange;\n this.metadata = metadata;\n this.fieldKey = bindingPath.replace('/', '');\n this.modelName = modelName;\n\n if (this.isDisplayMode) {\n sap.ui.requireSync(\"sap/m/Text\");\n const TextControl = sap.ui.require(\"sap/m/Text\");\n this.control = new TextControl({\n id: this.generateStableId(engineScopeId, bindingPath),\n text: {\n path: `${modelName}>${bindingPath}`,\n formatter: (val: unknown) => val && val.lat !== undefined && val.lng !== undefined ? `Lat: ${val.lat}, Lng: ${val.lng}` : \"\"\n }\n });\n this.applyCommonDirectives(this.control, metadata, modelName);\n return this.control as Control;\n }\n\n this.control = new GeolocationControl({\n id: this.generateStableId(engineScopeId, bindingPath),\n value: `{${modelName}>${bindingPath}}`,\n schemaMetadata: metadata,\n readOnly: !!metadata.ui?.readOnly\n });\n\n this.applyCommonDirectives(this.control, metadata, modelName);\n\n (this.control as unknown as { attachCapture: (fn: Function) => void }).attachCapture(() => {\n const result = this.validate();\n if (this.onChange) {\n this.onChange(result.isValid, this.fieldKey);\n }\n });\n\n return this.control as Control;\n }\n\n protected getValue(): any {\n return this.control ? (this.control as unknown as { getValue: () => unknown }).getValue() : null;\n }\n\n protected applyState(): void {\n if (this.control && this.metadata) {\n if (this.isDisplayMode) return;\n (this.control as unknown as { setProperty: (k: string, v: unknown) => void }).setProperty(\"readOnly\", !!this.metadata.ui?.readOnly);\n }\n }\n}\n"],"mappings":"AAAA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WAAA,MAAAD,EAAArC,oBAAA,OAAAqC,CAAA","ignoreList":[],"sourceRoot":"plugins/controls"}},{"offset":{"line":43,"column":0},"map":{"version":3,"names":["BasePlugin","___BasePlugin","MessageStripPlugin","render","fieldMetadata","bindingPath","modelName","engineScopeId","onChange","this","metadata","control","MessageStrip","id","generateStableId","text","type","showIcon","showCloseButton","getValue","applyState","__exports","__esModule"],"sources":["MessageStripPlugin.ts"],"sourcesContent":["/**\n * @file MessageStripPlugin.ts\n * @description Renders a sap.m.MessageStrip for informational text.\n */\n\nimport { BasePlugin } from \"./BasePlugin\";\nimport { IPropertyMetadata } from \"../../interfaces/ISchema\";\nimport MessageStrip from \"sap/m/MessageStrip\";\nimport Control from \"sap/ui/core/Control\";\n\n/**\n * Renders read-only informational alerts within the layout.\n * Does not emit values to the payload.\n * \n * @namespace nz.co.siliconst.ui5.metaui.plugins.controls\n * @public\n */\nexport class MessageStripPlugin extends BasePlugin {\n public render(fieldMetadata: IPropertyMetadata, bindingPath: string, modelName: string = \"meta\", engineScopeId?: string, onChange?: (isValid: boolean, fieldKey?: string) => void): Control {\n this.onChange = onChange;\n this.metadata = fieldMetadata;\n \n // Use binding to display text if the field has a value, otherwise use the label\n this.control = new MessageStrip({\n id: this.generateStableId(engineScopeId, bindingPath),\n text: `{${modelName}>${bindingPath}}`,\n type: \"Information\", // Can be driven by schema arguments in the future\n showIcon: true,\n showCloseButton: false\n });\n\n return this.control as Control;\n }\n\n protected getValue(): any {\n return null; // Read-only component\n }\n\n protected applyState(): void {\n // Read-only component, no dynamic state needed currently\n }\n}\n"],"mappings":"AAAA,oJAAA,MAKSA,EAAUC,EAAA,cAYZ,MAAMC,UAA2BF,EAC7BG,OAAOC,EAAmCC,EAAsBC,EAAoB,OAAQC,EAAwBC,GACvHC,KAAKD,SAAWA,EAChBC,KAAKC,SAAWN,EAGhBK,KAAKE,QAAU,IAAIC,EAAa,CAC5BC,GAAIJ,KAAKK,iBAAiBP,EAAeF,GACzCU,KAAM,IAAIT,KAAaD,KACvBW,KAAM,cACNC,SAAU,KACVC,gBAAiB,QAGrB,OAAOT,KAAKE,OAChB,CAEUQ,WACN,OAAO,IACX,CAEUC,aACN,EAEP,IAAAC,EAAA,CAAAC,WAAA,MAAAD,EAAAnB,qBAAA,OAAAmB,CAAA","ignoreList":[],"sourceRoot":"plugins/controls"}},{"offset":{"line":44,"column":0},"map":{"version":3,"names":["BasePlugin","___BasePlugin","MultiSelectPlugin","render","fieldMetadata","bindingPath","modelName","engineScopeId","onChange","this","metadata","isDisplayMode","sap","ui","requireSync","TextControl","require","control","id","generateStableId","text","path","formatter","val","Array","isArray","join","applyCommonDirectives","mcb","MultiComboBox","selectedKeys","enabled","readOnly","placeholder","label","selectionChange","oEvent","keys","getSelectedKeys","result","validate","isValid","fieldKey","enum","forEach","addItem","Item","key","toString","getValue","applyState","setEnabled","__exports","__esModule"],"sources":["MultiSelectPlugin.ts"],"sourcesContent":["/**\n * @file MultiSelectPlugin.ts\n * @description Renders a sap.m.MultiComboBox for selecting multiple string values.\n */\n\nimport { BasePlugin } from \"./BasePlugin\";\nimport { IPropertyMetadata } from \"../../interfaces/ISchema\";\nimport MultiComboBox from \"sap/m/MultiComboBox\";\nimport Item from \"sap/ui/core/Item\";\nimport Control from \"sap/ui/core/Control\";\n\n/**\n * Handles rendering logic for selecting multiple strings from a predefined list.\n * Expects the payload to be an array of strings.\n * \n * @namespace nz.co.siliconst.ui5.metaui.plugins.controls\n * @public\n */\nexport class MultiSelectPlugin extends BasePlugin {\n public render(fieldMetadata: IPropertyMetadata, bindingPath: string, modelName: string = \"meta\", engineScopeId?: string, onChange?: (isValid: boolean, fieldKey?: string) => void): Control {\n this.onChange = onChange;\n this.metadata = fieldMetadata;\n\n if (this.isDisplayMode) {\n sap.ui.requireSync(\"sap/m/Text\");\n const TextControl = sap.ui.require(\"sap/m/Text\");\n this.control = new TextControl({\n id: this.generateStableId(engineScopeId, bindingPath),\n text: {\n path: `${modelName}>${bindingPath}`,\n formatter: (val: any[]) => Array.isArray(val) ? val.join(\", \") : \"\"\n }\n });\n this.applyCommonDirectives(this.control, fieldMetadata, modelName);\n return this.control as Control;\n }\n \n const mcb = new MultiComboBox({\n id: this.generateStableId(engineScopeId, bindingPath),\n selectedKeys: `{${modelName}>${bindingPath}}`,\n enabled: !fieldMetadata.ui?.readOnly,\n placeholder: fieldMetadata.ui?.label || \"Select items...\",\n selectionChange: (oEvent: sap.ui.base.Event) => {\n const keys = (this.control as MultiComboBox).getSelectedKeys();\n const result = this.validate();\n if (this.onChange) {\n this.onChange(result.isValid, this.fieldKey);\n }\n }\n });\n\n if (fieldMetadata.enum) {\n fieldMetadata.enum.forEach((val: string | number) => {\n mcb.addItem(new Item({ key: val.toString(), text: val.toString() }));\n });\n }\n\n this.control = mcb;\n this.applyCommonDirectives(this.control, fieldMetadata, modelName);\n return this.control as Control;\n }\n\n protected getValue(): any {\n return this.control ? (this.control as MultiComboBox).getSelectedKeys() : [];\n }\n\n protected applyState(): void {\n if (this.control && this.metadata) {\n if (this.isDisplayMode) return;\n (this.control as MultiComboBox).setEnabled(!this.metadata.ui?.readOnly);\n }\n }\n}\n"],"mappings":"AAAA,yKAAA,MAKSA,EAAUC,EAAA,cAaZ,MAAMC,UAA0BF,EAC5BG,OAAOC,EAAmCC,EAAsBC,EAAoB,OAAQC,EAAwBC,GACvHC,KAAKD,SAAWA,EAChBC,KAAKC,SAAWN,EAEhB,GAAIK,KAAKE,cAAe,CACpBC,IAAIC,GAAGC,YAAY,cACnB,MAAMC,EAAcH,IAAIC,GAAGG,QAAQ,cACnCP,KAAKQ,QAAU,IAAIF,EAAY,CAC3BG,GAAIT,KAAKU,iBAAiBZ,EAAeF,GACzCe,KAAM,CACFC,KAAM,GAAGf,KAAaD,IACtBiB,UAAYC,GAAeC,MAAMC,QAAQF,GAAOA,EAAIG,KAAK,MAAQ,MAGzEjB,KAAKkB,sBAAsBlB,KAAKQ,QAASb,EAAeE,GACxD,OAAOG,KAAKQ,OAChB,CAEA,MAAMW,EAAM,IAAIC,EAAc,CAC1BX,GAAIT,KAAKU,iBAAiBZ,EAAeF,GACzCyB,aAAc,IAAIxB,KAAaD,KAC/B0B,SAAU3B,EAAcS,IAAImB,SAC5BC,YAAa7B,EAAcS,IAAIqB,OAAS,kBACxCC,gBAAkBC,IACd,MAAMC,EAAQ5B,KAAKQ,QAA0BqB,kBAC7C,MAAMC,EAAS9B,KAAK+B,WACpB,GAAI/B,KAAKD,SAAU,CACfC,KAAKD,SAAS+B,EAAOE,QAAShC,KAAKiC,SACvC,KAIR,GAAItC,EAAcuC,KAAM,CACpBvC,EAAcuC,KAAKC,QAASrB,IACxBK,EAAIiB,QAAQ,IAAIC,EAAK,CAAEC,IAAKxB,EAAIyB,WAAY5B,KAAMG,EAAIyB,eAE9D,CAEAvC,KAAKQ,QAAUW,EACfnB,KAAKkB,sBAAsBlB,KAAKQ,QAASb,EAAeE,GACxD,OAAOG,KAAKQ,OAChB,CAEUgC,WACN,OAAOxC,KAAKQ,QAAWR,KAAKQ,QAA0BqB,kBAAoB,EAC9E,CAEUY,aACN,GAAIzC,KAAKQ,SAAWR,KAAKC,SAAU,CAC/B,GAAID,KAAKE,cAAe,OACvBF,KAAKQ,QAA0BkC,YAAY1C,KAAKC,SAASG,IAAImB,SAClE,CACJ,EACH,IAAAoB,EAAA,CAAAC,WAAA,MAAAD,EAAAlD,oBAAA,OAAAkD,CAAA","ignoreList":[],"sourceRoot":"plugins/controls"}},{"offset":{"line":45,"column":0},"map":{"version":3,"names":["BasePlugin","___BasePlugin","NumberPlugin","render","fieldMetadata","bindingPath","modelName","engineScopeId","onChange","this","metadata","isDisplayMode","sap","ui","requireSync","TextControl","require","control","id","generateStableId","text","applyCommonDirectives","StepInput","value","displayValuePrecision","scale","editable","readOnly","required","change","oEvent","val","getParameter","result","validate","isValid","fieldKey","getValue","applyState","input","setEditable","setRequired","__exports","__esModule"],"sources":["NumberPlugin.ts"],"sourcesContent":["/**\n * @file NumberPlugin.ts\n * @description Renders a sap.m.StepInput for numeric data.\n */\n\nimport { BasePlugin } from \"./BasePlugin\";\nimport { IPropertyMetadata } from \"../../interfaces/ISchema\";\nimport StepInput from \"sap/m/StepInput\";\nimport Control from \"sap/ui/core/Control\";\n\n/**\n * Handles rendering and logic for numeric inputs.\n */\nexport class NumberPlugin extends BasePlugin {\n public render(fieldMetadata: IPropertyMetadata, bindingPath: string, modelName: string = \"meta\", engineScopeId?: string, onChange?: (isValid: boolean, fieldKey?: string) => void): Control {\n this.onChange = onChange;\n this.metadata = fieldMetadata;\n\n if (this.isDisplayMode) {\n sap.ui.requireSync(\"sap/m/Text\");\n const TextControl = sap.ui.require(\"sap/m/Text\");\n this.control = new TextControl({\n id: this.generateStableId(engineScopeId, bindingPath),\n text: `{${modelName}>${bindingPath}}`\n });\n this.applyCommonDirectives(this.control, fieldMetadata, modelName);\n return this.control as Control;\n }\n\n this.control = new StepInput({\n id: this.generateStableId(engineScopeId, bindingPath),\n value: `{${modelName}>${bindingPath}}`,\n displayValuePrecision: fieldMetadata.scale || 0,\n editable: !fieldMetadata.ui?.readOnly,\n required: fieldMetadata.required,\n change: (oEvent: sap.ui.base.Event) => {\n const val = oEvent.getParameter(\"value\");\n const result = this.validate();\n if (this.onChange) {\n this.onChange(result.isValid, this.fieldKey);\n }\n }\n });\n\n this.applyCommonDirectives(this.control, fieldMetadata, modelName);\n\n return this.control as Control;\n }\n\n protected getValue(): any {\n return this.control ? (this.control as StepInput).getValue() : null;\n }\n\n protected applyState(): void {\n if (this.control && this.metadata) {\n if (this.isDisplayMode) return;\n const input = this.control as StepInput;\n input.setEditable(!this.metadata.ui?.readOnly);\n input.setRequired(this.metadata.required);\n }\n }\n}\n"],"mappings":"AAAA,2IAAA,MAKSA,EAAUC,EAAA,cAQZ,MAAMC,UAAqBF,EACvBG,OAAOC,EAAmCC,EAAsBC,EAAoB,OAAQC,EAAwBC,GACvHC,KAAKD,SAAWA,EAChBC,KAAKC,SAAWN,EAEhB,GAAIK,KAAKE,cAAe,CACpBC,IAAIC,GAAGC,YAAY,cACnB,MAAMC,EAAcH,IAAIC,GAAGG,QAAQ,cACnCP,KAAKQ,QAAU,IAAIF,EAAY,CAC3BG,GAAIT,KAAKU,iBAAiBZ,EAAeF,GACzCe,KAAM,IAAId,KAAaD,OAE3BI,KAAKY,sBAAsBZ,KAAKQ,QAASb,EAAeE,GACxD,OAAOG,KAAKQ,OAChB,CAEAR,KAAKQ,QAAU,IAAIK,EAAU,CACzBJ,GAAIT,KAAKU,iBAAiBZ,EAAeF,GACzCkB,MAAO,IAAIjB,KAAaD,KACxBmB,sBAAuBpB,EAAcqB,OAAS,EAC9CC,UAAWtB,EAAcS,IAAIc,SAC7BC,SAAUxB,EAAcwB,SACxBC,OAASC,IACL,MAAMC,EAAMD,EAAOE,aAAa,SAChC,MAAMC,EAASxB,KAAKyB,WACpB,GAAIzB,KAAKD,SAAU,CACfC,KAAKD,SAASyB,EAAOE,QAAS1B,KAAK2B,SACvC,KAIR3B,KAAKY,sBAAsBZ,KAAKQ,QAASb,EAAeE,GAExD,OAAOG,KAAKQ,OAChB,CAEUoB,WACN,OAAO5B,KAAKQ,QAAWR,KAAKQ,QAAsBoB,WAAa,IACnE,CAEUC,aACN,GAAI7B,KAAKQ,SAAWR,KAAKC,SAAU,CAC/B,GAAID,KAAKE,cAAe,OACxB,MAAM4B,EAAQ9B,KAAKQ,QACnBsB,EAAMC,aAAa/B,KAAKC,SAASG,IAAIc,UACrCY,EAAME,YAAYhC,KAAKC,SAASkB,SACpC,CACJ,EACH,IAAAc,EAAA,CAAAC,WAAA,MAAAD,EAAAxC,eAAA,OAAAwC,CAAA","ignoreList":[],"sourceRoot":"plugins/controls"}},{"offset":{"line":46,"column":0},"map":{"version":3,"names":["BasePlugin","___BasePlugin","ObjectPlugin","render","field","bindingPath","modelName","engineScopeId","onChange","this","metadata","propKey","startsWith","substring","subSchema","type","title","ui","label","properties","uiLayout","control","Button","id","generateStableId","text","isDisplayMode","icon","press","oEvent","btn","getSource","parentModel","getModel","bindingContext","getBindingContext","updatePath","ctxPath","getPath","endsWith","nestedData","getProperty","sap","require","GeneratorHost","host","schemaDefinition","data","displayMode","attachSubmit","e","payload","getParameter","setProperty","buttonText","dialogButtonText","openInDialog","validate","isValid","getValue","applyState","__exports","__esModule"],"sources":["ObjectPlugin.ts"],"sourcesContent":["/**\n * @file ObjectPlugin.ts\n * @description Renders a button that opens a dialog to edit a nested object structure.\n */\n\nimport { BasePlugin } from \"./BasePlugin\";\nimport { IPluginValidationResult } from \"../../interfaces/IPlugin\";\nimport { IPropertyMetadata } from \"../../interfaces/ISchema\";\nimport Control from \"sap/ui/core/Control\";\nimport Button from \"sap/m/Button\";\nimport JSONModel from \"sap/ui/model/json/JSONModel\";\n\nexport class ObjectPlugin extends BasePlugin {\n public render(field: IPropertyMetadata, bindingPath: string, modelName: string = \"meta\", engineScopeId?: string, onChange?: (isValid: boolean, fieldKey?: string) => void): Control {\n this.onChange = onChange;\n this.metadata = field;\n const propKey = bindingPath.startsWith(\"/\") ? bindingPath.substring(1) : bindingPath;\n \n const subSchema: any = {\n type: \"object\",\n title: field.ui?.label || propKey,\n properties: field.properties || {}\n };\n \n if (field.uiLayout) {\n subSchema.uiLayout = field.uiLayout;\n }\n\n this.control = new Button({\n id: this.generateStableId(engineScopeId, bindingPath),\n text: this.isDisplayMode ? \"View Details\" : \"Edit Details\",\n icon: this.isDisplayMode ? \"sap-icon://display\" : \"sap-icon://form\",\n press: (oEvent: sap.ui.base.Event) => {\n const btn = oEvent.getSource() as Button;\n const parentModel = btn.getModel(modelName) as JSONModel;\n if (!parentModel) return;\n \n const bindingContext = btn.getBindingContext(modelName);\n let updatePath = bindingPath;\n if (bindingContext && !bindingPath.startsWith(\"/\")) {\n const ctxPath = bindingContext.getPath();\n updatePath = ctxPath.endsWith(\"/\") ? ctxPath + bindingPath : (ctxPath === \"/\" ? \"/\" + bindingPath : ctxPath + \"/\" + bindingPath);\n }\n \n const nestedData = parentModel.getProperty(updatePath) || {};\n\n sap.ui.require([\"nz/co/siliconst/ui5/metaui/controls/host/GeneratorHost\"], (GeneratorHost: any) => {\n const host = new GeneratorHost({\n schemaDefinition: subSchema,\n data: nestedData,\n displayMode: this.isDisplayMode\n });\n\n if (!this.isDisplayMode) {\n host.attachSubmit((e: any) => {\n const payload = e.getParameter(\"payload\");\n parentModel.setProperty(updatePath, payload);\n });\n }\n\n const buttonText = field.ui?.dialogButtonText || (this.isDisplayMode ? \"Close\" : \"OK\");\n host.openInDialog(`Nested Details: ${field.ui?.label || propKey}`, buttonText);\n });\n }\n });\n\n return this.control as Control;\n }\n\n public validate(): IPluginValidationResult {\n return { isValid: true };\n }\n\n protected getValue(): any {\n return null;\n }\n\n protected applyState(): void {\n // No dynamic state handling needed for the button\n }\n}\n"],"mappings":"AAAA,wIAAA,MAKSA,EAAUC,EAAA,cAOZ,MAAMC,UAAqBF,EACvBG,OAAOC,EAA2BC,EAAsBC,EAAoB,OAAQC,EAAwBC,GAC/GC,KAAKD,SAAWA,EAChBC,KAAKC,SAAWN,EAChB,MAAMO,EAAUN,EAAYO,WAAW,KAAOP,EAAYQ,UAAU,GAAKR,EAEzE,MAAMS,EAAiB,CACnBC,KAAM,SACNC,MAAOZ,EAAMa,IAAIC,OAASP,EAC1BQ,WAAYf,EAAMe,YAAc,CAAC,GAGrC,GAAIf,EAAMgB,SAAU,CAChBN,EAAUM,SAAWhB,EAAMgB,QAC/B,CAEAX,KAAKY,QAAU,IAAIC,EAAO,CACtBC,GAAId,KAAKe,iBAAiBjB,EAAeF,GACzCoB,KAAMhB,KAAKiB,cAAgB,eAAiB,eAC5CC,KAAMlB,KAAKiB,cAAgB,qBAAuB,kBAClDE,MAAQC,IACJ,MAAMC,EAAMD,EAAOE,YACnB,MAAMC,EAAcF,EAAIG,SAAS3B,GACjC,IAAK0B,EAAa,OAElB,MAAME,EAAiBJ,EAAIK,kBAAkB7B,GAC7C,IAAI8B,EAAa/B,EACjB,GAAI6B,IAAmB7B,EAAYO,WAAW,KAAM,CAChD,MAAMyB,EAAUH,EAAeI,UAC/BF,EAAaC,EAAQE,SAAS,KAAOF,EAAUhC,EAAegC,IAAY,IAAM,IAAMhC,EAAcgC,EAAU,IAAMhC,CACxH,CAEA,MAAMmC,EAAaR,EAAYS,YAAYL,IAAe,CAAC,EAE3DM,IAAIzB,GAAG0B,QAAQ,CAAC,0DAA4DC,IACxE,MAAMC,EAAO,IAAID,EAAc,CAC3BE,iBAAkBhC,EAClBiC,KAAMP,EACNQ,YAAavC,KAAKiB,gBAGtB,IAAKjB,KAAKiB,cAAe,CACrBmB,EAAKI,aAAcC,IACf,MAAMC,EAAUD,EAAEE,aAAa,WAC/BpB,EAAYqB,YAAYjB,EAAYe,IAE5C,CAEA,MAAMG,EAAalD,EAAMa,IAAIsC,mBAAqB9C,KAAKiB,cAAgB,QAAU,MACjFmB,EAAKW,aAAa,mBAAmBpD,EAAMa,IAAIC,OAASP,IAAW2C,QAK/E,OAAO7C,KAAKY,OAChB,CAEOoC,WACH,MAAO,CAAEC,QAAS,KACtB,CAEUC,WACN,OAAO,IACX,CAEUC,aACN,EAEP,IAAAC,EAAA,CAAAC,WAAA,MAAAD,EAAA3D,eAAA,OAAA2D,CAAA","ignoreList":[],"sourceRoot":"plugins/controls"}},{"offset":{"line":47,"column":0},"map":{"version":3,"names":["BasePlugin","___BasePlugin","RatingIndicatorPlugin","render","fieldMetadata","bindingPath","modelName","engineScopeId","onChange","this","metadata","isDisplayMode","sap","ui","requireSync","TextControl","require","control","id","generateStableId","text","applyCommonDirectives","RatingIndicator","value","enabled","readOnly","maxValue","maximum","undefined","change","oEvent","val","getParameter","result","validate","isValid","fieldKey","getValue","applyState","setEnabled","__exports","__esModule"],"sources":["RatingIndicatorPlugin.ts"],"sourcesContent":["/**\n * @file RatingIndicatorPlugin.ts\n * @description Renders a sap.m.RatingIndicator for 1-5 numeric feedback.\n */\n\nimport { BasePlugin } from \"./BasePlugin\";\nimport { IPropertyMetadata } from \"../../interfaces/ISchema\";\nimport RatingIndicator from \"sap/m/RatingIndicator\";\nimport Control from \"sap/ui/core/Control\";\n\n/**\n * Handles rendering logic for rating feedback.\n * \n * @namespace nz.co.siliconst.ui5.metaui.plugins.controls\n * @public\n */\nexport class RatingIndicatorPlugin extends BasePlugin {\n public render(fieldMetadata: IPropertyMetadata, bindingPath: string, modelName: string = \"meta\", engineScopeId?: string, onChange?: (isValid: boolean, fieldKey?: string) => void): Control {\n this.onChange = onChange;\n this.metadata = fieldMetadata;\n\n if (this.isDisplayMode) {\n sap.ui.requireSync(\"sap/m/Text\");\n const TextControl = sap.ui.require(\"sap/m/Text\");\n this.control = new TextControl({\n id: this.generateStableId(engineScopeId, bindingPath),\n text: `{${modelName}>${bindingPath}}`\n });\n this.applyCommonDirectives(this.control, fieldMetadata, modelName);\n return this.control as Control;\n }\n \n this.control = new RatingIndicator({\n id: this.generateStableId(engineScopeId, bindingPath),\n value: `{${modelName}>${bindingPath}}`,\n enabled: !fieldMetadata.ui?.readOnly,\n maxValue: fieldMetadata.maximum !== undefined ? fieldMetadata.maximum : 5,\n change: (oEvent: sap.ui.base.Event) => {\n const val = oEvent.getParameter(\"value\");\n const result = this.validate();\n if (this.onChange) {\n this.onChange(result.isValid, this.fieldKey);\n }\n }\n });\n\n this.applyCommonDirectives(this.control, fieldMetadata, modelName);\n\n return this.control as Control;\n }\n\n protected getValue(): any {\n return this.control ? (this.control as RatingIndicator).getValue() : 0;\n }\n\n protected applyState(): void {\n if (this.control && this.metadata) {\n if (this.isDisplayMode) return;\n (this.control as RatingIndicator).setEnabled(!this.metadata.ui?.readOnly);\n }\n }\n}\n"],"mappings":"AAAA,0JAAA,MAKSA,EAAUC,EAAA,cAWZ,MAAMC,UAA8BF,EAChCG,OAAOC,EAAmCC,EAAsBC,EAAoB,OAAQC,EAAwBC,GACvHC,KAAKD,SAAWA,EAChBC,KAAKC,SAAWN,EAEhB,GAAIK,KAAKE,cAAe,CACpBC,IAAIC,GAAGC,YAAY,cACnB,MAAMC,EAAcH,IAAIC,GAAGG,QAAQ,cACnCP,KAAKQ,QAAU,IAAIF,EAAY,CAC3BG,GAAIT,KAAKU,iBAAiBZ,EAAeF,GACzCe,KAAM,IAAId,KAAaD,OAE3BI,KAAKY,sBAAsBZ,KAAKQ,QAASb,EAAeE,GACxD,OAAOG,KAAKQ,OAChB,CAEAR,KAAKQ,QAAU,IAAIK,EAAgB,CAC/BJ,GAAIT,KAAKU,iBAAiBZ,EAAeF,GACzCkB,MAAO,IAAIjB,KAAaD,KACxBmB,SAAUpB,EAAcS,IAAIY,SAC5BC,SAAUtB,EAAcuB,UAAYC,UAAYxB,EAAcuB,QAAU,EACxEE,OAASC,IACL,MAAMC,EAAMD,EAAOE,aAAa,SAChC,MAAMC,EAASxB,KAAKyB,WACpB,GAAIzB,KAAKD,SAAU,CACfC,KAAKD,SAASyB,EAAOE,QAAS1B,KAAK2B,SACvC,KAIR3B,KAAKY,sBAAsBZ,KAAKQ,QAASb,EAAeE,GAExD,OAAOG,KAAKQ,OAChB,CAEUoB,WACN,OAAO5B,KAAKQ,QAAWR,KAAKQ,QAA4BoB,WAAa,CACzE,CAEUC,aACN,GAAI7B,KAAKQ,SAAWR,KAAKC,SAAU,CAC/B,GAAID,KAAKE,cAAe,OACvBF,KAAKQ,QAA4BsB,YAAY9B,KAAKC,SAASG,IAAIY,SACpE,CACJ,EACH,IAAAe,EAAA,CAAAC,WAAA,MAAAD,EAAAtC,wBAAA,OAAAsC,CAAA","ignoreList":[],"sourceRoot":"plugins/controls"}},{"offset":{"line":48,"column":0},"map":{"version":3,"names":["BasePlugin","___controls_BasePlugin","RichTextControl","_interopRequireDefault","__RichTextControl","isValueAccessor","control","getValue","RichTextPlugin","render","metadata","bindingPath","modelName","engineScopeId","onChange","this","fieldKey","replace","isDisplayMode","sap","ui","requireSync","FormattedTextControl","require","id","generateStableId","htmlText","applyCommonDirectives","value","schemaMetadata","readOnly","attachCapture","result","validate","isValid","applyState","setProperty","__exports","__esModule"],"sources":["RichTextPlugin.ts"],"sourcesContent":["import { BasePlugin } from \"../controls/BasePlugin\";\nimport { IPropertyMetadata } from \"../../interfaces/ISchema\";\nimport Control from \"sap/ui/core/Control\";\nimport RichTextControl from \"../../controls/RichTextControl\";\n\ninterface IValueAccessor {\n getValue(): unknown;\n attachCapture?(fn: Function): void;\n}\n\nfunction isValueAccessor(control: unknown): control is IValueAccessor {\n return control !== null && typeof (control as IValueAccessor).getValue === 'function';\n}\n\nexport class RichTextPlugin extends BasePlugin {\n public render(metadata: IPropertyMetadata, bindingPath: string, modelName: string = \"meta\", engineScopeId?: string, onChange?: (isValid: boolean, fieldKey?: string) => void): Control {\n this.onChange = onChange;\n this.metadata = metadata;\n this.fieldKey = bindingPath.replace('/', '');\n this.modelName = modelName;\n\n if (this.isDisplayMode) {\n (sap.ui as unknown as { requireSync: (s: string) => unknown }).requireSync(\"sap/m/FormattedText\");\n const FormattedTextControl = sap.ui.require(\"sap/m/FormattedText\");\n this.control = new FormattedTextControl({\n id: this.generateStableId(engineScopeId, bindingPath),\n htmlText: `{${modelName}>${bindingPath}}`\n }) as unknown as sap.ui.core.Control;\n this.applyCommonDirectives(this.control, metadata, modelName);\n return this.control as Control;\n }\n\n this.control = new RichTextControl({\n id: this.generateStableId(engineScopeId, bindingPath),\n value: `{${modelName}>${bindingPath}}`,\n schemaMetadata: metadata,\n readOnly: !!metadata.ui?.readOnly\n }) as unknown as sap.ui.core.Control;\n\n this.applyCommonDirectives(this.control, metadata, modelName);\n\n if (isValueAccessor(this.control) && this.control.attachCapture) {\n this.control.attachCapture(() => {\n const result = this.validate();\n if (this.onChange) {\n this.onChange(result.isValid, this.fieldKey);\n }\n });\n }\n\n return this.control as Control;\n }\n\n protected getValue(): unknown {\n if (isValueAccessor(this.control)) {\n return this.control.getValue();\n }\n return null;\n }\n\n protected applyState(): void {\n if (this.control && this.metadata) {\n if (this.isDisplayMode) return;\n (this.control as unknown as { setProperty: (k: string, v: unknown) => void }).setProperty(\"readOnly\",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,KAAKT,QAAwE8B,YAAY,aAAcrB,KAAKL,SAASU,IAAIU,SAC9H,CACJ,EACH,IAAAO,EAAA,CAAAC,WAAA,MAAAD,EAAA7B,iBAAA,OAAA6B,CAAA","ignoreList":[],"sourceRoot":"plugins/controls"}},{"offset":{"line":49,"column":0},"map":{"version":3,"names":["BasePlugin","___controls_BasePlugin","SignatureControl","_interopRequireDefault","__SignatureControl","SignaturePlugin","render","metadata","bindingPath","modelName","engineScopeId","onChange","this","fieldKey","replace","isDisplayMode","sap","ui","requireSync","ImageControl","require","control","id","generateStableId","src","width","alt","label","applyCommonDirectives","value","schemaMetadata","readOnly","attachCapture","result","validate","isValid","getValue","applyState","setProperty","__exports","__esModule"],"sources":["SignaturePlugin.ts"],"sourcesContent":["import { BasePlugin } from \"../controls/BasePlugin\";\nimport { IPropertyMetadata } from \"../../interfaces/ISchema\";\nimport Control from \"sap/ui/core/Control\";\nimport SignatureControl from \"../../controls/SignatureControl\";\n\nexport class SignaturePlugin extends BasePlugin {\n public render(metadata: IPropertyMetadata, bindingPath: string, modelName: string = \"meta\", engineScopeId?: string, onChange?: (isValid: boolean, fieldKey?: string) => void): Control {\n this.onChange = onChange;\n this.metadata = metadata;\n this.fieldKey = bindingPath.replace('/', '');\n this.modelName = modelName;\n\n if (this.isDisplayMode) {\n (sap.ui as unknown as { requireSync: (s: string) => unknown }).requireSync(\"sap/m/Image\");\n const ImageControl = sap.ui.require(\"sap/m/Image\");\n this.control = new ImageControl({\n id: this.generateStableId(engineScopeId, bindingPath),\n src: `{${modelName}>${bindingPath}}`,\n width: \"400px\",\n alt: metadata.ui?.label || \"Signature\"\n }) as unknown as sap.ui.core.Control;\n this.applyCommonDirectives(this.control, metadata, modelName);\n return this.control as Control;\n }\n\n this.control = new SignatureControl({\n id: this.generateStableId(engineScopeId, bindingPath),\n value: `{${modelName}>${bindingPath}}`,\n schemaMetadata: metadata,\n readOnly: !!metadata.ui?.readOnly\n }) as unknown as sap.ui.core.Control;\n\n this.applyCommonDirectives(this.control, metadata, modelName);\n\n (this.control as unknown as { attachCapture: (fn: Function) => void }).attachCapture(() => {\n const result = this.validate();\n if (this.onChange) {\n this.onChange(result.isValid, this.fieldKey);\n }\n });\n\n return this.control as Control;\n }\n\n protected getValue(): any {\n return this.control ? (this.control as unknown as { getValue: () => unknown }).getValue() : null;\n }\n\n protected applyState(): void {\n if (this.control && this.metadata) {\n if (this.isDisplayMode) return;\n (this.control as unknown as { setProperty: (k: string, v: unknown) => void }).setProperty(\"readOnly\", !!this.metadata.ui?.readOnly);\n }\n }\n}\n"],"mappings":"AAAA,+PAASA,EAAUC,EAAA,oBAGZC,EAAgBC,EAAAC,GAEhB,MAAMC,UAAwBL,EAC1BM,OAAOC,EAA8BC,EAAsBC,EAAoB,OAAQC,EAAwBC,GAClHC,KAAKD,SAAWA,EAChBC,KAAKL,SAAWA,EAChBK,KAAKC,SAAWL,EAAYM,QAAQ,IAAK,IACzCF,KAAKH,UAAYA,EAEjB,GAAIG,KAAKG,cAAe,CACnBC,IAAIC,GAA0DC,YAAY,eAC3E,MAAMC,EAAeH,IAAIC,GAAGG,QAAQ,eACpCR,KAAKS,QAAU,IAAIF,EAAa,CAC5BG,GAAIV,KAAKW,iBAAiBb,EAAeF,GACzCgB,IAAK,IAAIf,KAAaD,KACtBiB,MAAO,QACPC,IAAKnB,EAASU,IAAIU,OAAS,cAE/Bf,KAAKgB,sBAAsBhB,KAAKS,QAASd,EAAUE,GACnD,OAAOG,KAAKS,OAChB,CAEAT,KAAKS,QAAU,IAAInB,EAAiB,CAChCoB,GAAIV,KAAKW,iBAAiBb,EAAeF,GACzCqB,MAAO,IAAIpB,KAAaD,KACxBsB,eAAgBvB,EAChBwB,WAAYxB,EAASU,IAAIc,WAG7BnB,KAAKgB,sBAAsBhB,KAAKS,QAASd,EAAUE,GAElDG,KAAKS,QAAiEW,cAAc,KACjF,MAAMC,EAASrB,KAAKsB,WAChB,GAAItB,KAAKD,SAAU,CACfC,KAAKD,SAASsB,EAAOE,QAASvB,KAAKC,SACvC,IAGR,OAAOD,KAAKS,OAChB,CAEUe,WACN,OAAOxB,KAAKS,QAAWT,KAAKS,QAAmDe,WAAa,IAChG,CAEUC,aACN,GAAIzB,KAAKS,SAAWT,KAAKL,SAAU,CAC/B,GAAIK,KAAKG,cAAe,OACvBH,KAAKS,QAAwEiB,YAAY,aAAc1B,KAAKL,SAASU,IAAIc,SAC9H,CACJ,EACH,IAAAQ,EAAA,CAAAC,WAAA,MAAAD,EAAAlC,kBAAA,OAAAkC,CAAA","ignoreList":[],"sourceRoot":"plugins/controls"}},{"offset":{"line":50,"column":0},"map":{"version":3,"names":["BasePlugin","___BasePlugin","SliderPlugin","render","fieldMetadata","bindingPath","modelName","engineScopeId","onChange","this","metadata","isDisplayMode","sap","ui","requireSync","TextControl","require","control","id","generateStableId","text","applyCommonDirectives","Slider","value","enabled","readOnly","min","minimum","undefined","max","maximum","step","multipleOf","enableTickmarks","change","oEvent","val","getParameter","result","validate","isValid","fieldKey","getValue","applyState","setEnabled","__exports","__esModule"],"sources":["SliderPlugin.ts"],"sourcesContent":["/**\n * @file SliderPlugin.ts\n * @description Renders a sap.m.Slider for picking numbers in a range.\n */\n\nimport { BasePlugin } from \"./BasePlugin\";\nimport { IPropertyMetadata } from \"../../interfaces/ISchema\";\nimport Slider from \"sap/m/Slider\";\nimport Control from \"sap/ui/core/Control\";\n\n/**\n * Handles rendering logic for numeric sliders.\n * \n * @namespace nz.co.siliconst.ui5.metaui.plugins.controls\n * @public\n */\nexport class SliderPlugin extends BasePlugin {\n public render(fieldMetadata: IPropertyMetadata, bindingPath: string, modelName: string = \"meta\", engineScopeId?: string, onChange?: (isValid: boolean, fieldKey?: string) => void): Control {\n this.onChange = onChange;\n this.metadata = fieldMetadata;\n \n if (this.isDisplayMode) {\n (sap.ui as unknown as { requireSync: (s: string) => unknown }).requireSync(\"sap/m/Text\");\n const TextControl = sap.ui.require(\"sap/m/Text\");\n this.control = new TextControl({\n id: this.generateStableId(engineScopeId, bindingPath),\n text: `{${modelName}>${bindingPath}}`\n });\n this.applyCommonDirectives(this.control, fieldMetadata, modelName);\n return this.control as Control;\n }\n\n this.control = new Slider({\n id: this.generateStableId(engineScopeId, bindingPath),\n value: `{${modelName}>${bindingPath}}`,\n enabled: !fieldMetadata.ui?.readOnly,\n min: fieldMetadata.minimum !== undefined ? fieldMetadata.minimum : 0,\n max: fieldMetadata.maximum !== undefined ? fieldMetadata.maximum : 100,\n step: fieldMetadata.multipleOf !== undefined ? fieldMetadata.multipleOf : 1,\n enableTickmarks: true,\n change: (oEvent: unknown) => {\n const val = (oEvent as { getParameter: (s: string) => unknown }).getParameter(\"value\");\n const result = this.validate();\n if (this.onChange) {\n this.onChange(result.isValid, this.fieldKey);\n }\n }\n });\n\n this.applyCommonDirectives(this.control, fieldMetadata, modelName);\n\n return this.control as Control;\n }\n\n protected getValue(): any {\n return this.control ? (this.control as Slider).getValue() : 0;\n }\n\n protected applyState(): void {\n if (this.control && this.metadata) {\n if (this.isDisplayMode) return;\n (this.control as Slider).setEnabled(!this.metadata.ui?.readOnly);\n }\n }\n}\n"],"mappings":"AAAA,wIAAA,MAKSA,EAAUC,EAAA,cAWZ,MAAMC,UAAqBF,EACvBG,OAAOC,EAAmCC,EAAsBC,EAAoB,OAAQC,EAAwBC,GACvHC,KAAKD,SAAWA,EAChBC,KAAKC,SAAWN,EAEhB,GAAIK,KAAKE,cAAe,CACnBC,IAAIC,GAA0DC,YAAY,cAC3E,MAAMC,EAAcH,IAAIC,GAAGG,QAAQ,cACnCP,KAAKQ,QAAU,IAAIF,EAAY,CAC3BG,GAAIT,KAAKU,iBAAiBZ,EAAeF,GACzCe,KAAM,IAAId,KAAaD,OAE3BI,KAAKY,sBAAsBZ,KAAKQ,QAASb,EAAeE,GACxD,OAAOG,KAAKQ,OAChB,CAEAR,KAAKQ,QAAU,IAAIK,EAAO,CACtBJ,GAAIT,KAAKU,iBAAiBZ,EAAeF,GACzCkB,MAAO,IAAIjB,KAAaD,KACxBmB,SAAUpB,EAAcS,IAAIY,SAC5BC,IAAKtB,EAAcuB,UAAYC,UAAYxB,EAAcuB,QAAU,EACnEE,IAAKzB,EAAc0B,UAAYF,UAAYxB,EAAc0B,QAAU,IACnEC,KAAM3B,EAAc4B,aAAeJ,UAAYxB,EAAc4B,WAAa,EAC1EC,gBAAiB,KACjBC,OAASC,IACL,MAAMC,EAAOD,EAAoDE,aAAa,SAC9E,MAAMC,EAAS7B,KAAK8B,WACpB,GAAI9B,KAAKD,SAAU,CACfC,KAAKD,SAAS8B,EAAOE,QAAS/B,KAAKgC,SACvC,KAIRhC,KAAKY,sBAAsBZ,KAAKQ,QAASb,EAAeE,GAExD,OAAOG,KAAKQ,OAChB,CAEUyB,WACN,OAAOjC,KAAKQ,QAAWR,KAAKQ,QAAmByB,WAAa,CAChE,CAEUC,aACN,GAAIlC,KAAKQ,SAAWR,KAAKC,SAAU,CAC/B,GAAID,KAAKE,cAAe,OACvBF,KAAKQ,QAAmB2B,YAAYnC,KAAKC,SAASG,IAAIY,SAC3D,CACJ,EACH,IAAAoB,EAAA,CAAAC,WAAA,MAAAD,EAAA3C,eAAA,OAAA2C,CAAA","ignoreList":[],"sourceRoot":"plugins/controls"}},{"offset":{"line":51,"column":0},"map":{"version":3,"names":["BasePlugin","___BasePlugin","StringPlugin","render","fieldMetadata","bindingPath","modelName","engineScopeId","onChange","this","metadata","fieldKey","replace","isDisplayMode","sap","ui","requireSync","TextControl","require","control","id","generateStableId","text","applyCommonDirectives","Input","value","maxLength","required","showValueHelp","widget","change","oEvent","val","getParameter","result","validate","isValid","getValue","applyState","input","setEditable","readOnly","setRequired","__exports","__esModule"],"sources":["StringPlugin.ts"],"sourcesContent":["/**\n * @file StringPlugin.ts\n * @description Renders a sap.m.Input for string data and validates lengths.\n */\n\nimport { BasePlugin } from \"./BasePlugin\";\nimport { IPropertyMetadata } from \"../../interfaces/ISchema\";\nimport Input from \"sap/m/Input\";\nimport Control from \"sap/ui/core/Control\";\n\n/**\n * Handles rendering and logic for basic text inputs.\n * Maps schema properties like `maxLength` and `required` natively to `sap.m.Input`.\n * \n * @namespace nz.co.siliconst.ui5.metaui.plugins.controls\n * @public\n */\nexport class StringPlugin extends BasePlugin {\n /**\n * Renders a `sap.m.Input` control configured via the provided schema metadata.\n * \n * @param fieldMetadata The specific JSON schema properties for this field.\n * @param bindingPath The JSON path bound to this control.\n * @param modelName The UI5 JSONModel name.\n * @returns {Control} The configured Input control.\n */\n public render(fieldMetadata: IPropertyMetadata, bindingPath: string, modelName: string = \"meta\", engineScopeId?: string, onChange?: (isValid: boolean, fieldKey?: string) => void): Control {\n this.onChange = onChange;\n this.metadata = fieldMetadata;\n this.fieldKey = bindingPath.replace(\"/\", \"\"); // For EventBus\n \n if (this.isDisplayMode) {\n (sap.ui as unknown as { requireSync: (s: string) => unknown }).requireSync(\"sap/m/Text\");\n const TextControl = sap.ui.require(\"sap/m/Text\");\n this.control = new TextControl({\n id: this.generateStableId(engineScopeId, bindingPath),\n text: `{${modelName}>${bindingPath}}`\n });\n this.applyCommonDirectives(this.control, fieldMetadata, modelName);\n return this.control as Control;\n }\n\n this.control = new Input({\n id: this.generateStableId(engineScopeId, bindingPath),\n value: `{${modelName}>${bindingPath}}`,\n maxLength: fieldMetadata.maxLength || 0,\n required: !!fieldMetadata.required,\n showValueHelp: fieldMetadata.ui?.widget === \"searchHelp\",\n change: (oEvent: unknown) => {\n const val = (oEvent as { getParameter: (s: string) => unknown }).getParameter(\"value\");\n const result = this.validate();\n if (this.onChange) {\n this.onChange(result.isValid, this.fieldKey);\n }\n }\n });\n\n this.applyCommonDirectives(this.control, fieldMetadata, modelName);\n\n return this.control as Control;\n }\n\n /**\n * Retrieves the current string value from the input.\n * @returns {any} The string value.\n */\n protected getValue(): any {\n return this.control ? (this.control as Input).getValue() : null;\n }\n\n /**\n * Adjusts dynamic state properties (editable/required) based on ConditionEngine mutations.\n */\n protected applyState(): void {\n if (this.control && this.metadata) {\n if (this.isDisplayMode) {\n // Text doesn't have editable/required state\n return;\n }\n const input = this.control as Input;\n input.setEditable(!this.metadata.ui?.readOnly);\n input.setRequired(this.metadata.required);\n }\n }\n}\n"],"mappings":"AAAA,uIAAA,MAKSA,EAAUC,EAAA,cAYZ,MAAMC,UAAqBF,EASvBG,OAAOC,EAAmCC,EAAsBC,EAAoB,OAAQC,EAAwBC,GACvHC,KAAKD,SAAWA,EAChBC,KAAKC,SAAWN,EAChBK,KAAKE,SAAWN,EAAYO,QAAQ,IAAK,IAEzC,GAAIH,KAAKI,cAAe,CACnBC,IAAIC,GAA0DC,YAAY,cAC3E,MAAMC,EAAcH,IAAIC,GAAGG,QAAQ,cACnCT,KAAKU,QAAU,IAAIF,EAAY,CAC3BG,GAAIX,KAAKY,iBAAiBd,EAAeF,GACzCiB,KAAM,IAAIhB,KAAaD,OAE3BI,KAAKc,sBAAsBd,KAAKU,QAASf,EAAeE,GACxD,OAAOG,KAAKU,OAChB,CAEAV,KAAKU,QAAU,IAAIK,EAAM,CACrBJ,GAAIX,KAAKY,iBAAiBd,EAAeF,GACzCoB,MAAO,IAAInB,KAAaD,KACxBqB,UAAWtB,EAAcsB,WAAa,EACtCC,WAAYvB,EAAcuB,SAC1BC,cAAexB,EAAcW,IAAIc,SAAW,aAC5CC,OAASC,IACL,MAAMC,EAAOD,EAAoDE,aAAa,SAC9E,MAAMC,EAASzB,KAAK0B,WACpB,GAAI1B,KAAKD,SAAU,CACfC,KAAKD,SAAS0B,EAAOE,QAAS3B,KAAKE,SACvC,KAIRF,KAAKc,sBAAsBd,KAAKU,QAASf,EAAeE,GAExD,OAAOG,KAAKU,OAChB,CAMUkB,WACN,OAAO5B,KAAKU,QAAWV,KAAKU,QAAkBkB,WAAa,IAC/D,CAKUC,aACN,GAAI7B,KAAKU,SAAWV,KAAKC,SAAU,CAC/B,GAAID,KAAKI,cAAe,CAEpB,MACJ,CACA,MAAM0B,EAAQ9B,KAAKU,QACnBoB,EAAMC,aAAa/B,KAAKC,SAASK,IAAI0B,UACrCF,EAAMG,YAAYjC,KAAKC,SAASiB,SACpC,CACJ,EACH,IAAAgB,EAAA,CAAAC,WAAA,MAAAD,EAAAzC,eAAA,OAAAyC,CAAA","ignoreList":[],"sourceRoot":"plugins/controls"}},{"offset":{"line":52,"column":0},"map":{"version":3,"names":["BasePlugin","___BasePlugin","SwitchPlugin","render","fieldMetadata","bindingPath","modelName","engineScopeId","onChange","this","metadata","isDisplayMode","sap","ui","requireSync","TextControl","require","control","id","generateStableId","text","path","formatter","val","applyCommonDirectives","Switch","state","enabled","readOnly","change","oEvent","getParameter","result","validate","isValid","fieldKey","getValue","getState","applyState","sw","setEnabled","__exports","__esModule"],"sources":["SwitchPlugin.ts"],"sourcesContent":["/**\n * @file SwitchPlugin.ts\n * @description Renders a sap.m.Switch for boolean data specifically marked with the switch widget.\n */\n\nimport { BasePlugin } from \"./BasePlugin\";\nimport { IPropertyMetadata } from \"../../interfaces/ISchema\";\nimport Switch from \"sap/m/Switch\";\nimport Control from \"sap/ui/core/Control\";\n\n/**\n * Handles rendering logic for toggleable boolean switches.\n */\nexport class SwitchPlugin extends BasePlugin {\n public render(fieldMetadata: IPropertyMetadata, bindingPath: string, modelName: string = \"meta\", engineScopeId?: string, onChange?: (isValid: boolean, fieldKey?: string) => void): Control {\n this.onChange = onChange;\n this.metadata = fieldMetadata;\n\n if (this.isDisplayMode) {\n (sap.ui as unknown as { requireSync: (s: string) => unknown }).requireSync(\"sap/m/Text\");\n const TextControl = sap.ui.require(\"sap/m/Text\");\n this.control = new TextControl({\n id: this.generateStableId(engineScopeId, bindingPath),\n text: {\n path: `${modelName}>${bindingPath}`,\n formatter: (val: boolean) => val ? \"Yes\" : \"No\"\n }\n });\n this.applyCommonDirectives(this.control, fieldMetadata, modelName);\n return this.control as Control;\n }\n\n this.control = new Switch({\n id: this.generateStableId(engineScopeId, bindingPath),\n state: `{${modelName}>${bindingPath}}`,\n enabled: !fieldMetadata.ui?.readOnly,\n change: (oEvent: unknown) => {\n const val = (oEvent as { getParameter: (s: string) => unknown }).getParameter(\"state\");\n const result = this.validate();\n if (this.onChange) {\n this.onChange(result.isValid, this.fieldKey);\n }\n }\n });\n\n this.applyCommonDirectives(this.control, fieldMetadata, modelName);\n\n return this.control as Control;\n }\n\n protected getValue(): any {\n return this.control ? (this.control as Switch).getState() : false;\n }\n\n protected applyState(): void {\n if (this.control && this.metadata) {\n if (this.isDisplayMode) return;\n const sw = this.control as Switch;\n sw.setEnabled(!this.metadata.ui?.readOnly);\n }\n }\n}\n"],"mappings":"AAAA,wIAAA,MAKSA,EAAUC,EAAA,cAQZ,MAAMC,UAAqBF,EACvBG,OAAOC,EAAmCC,EAAsBC,EAAoB,OAAQC,EAAwBC,GACvHC,KAAKD,SAAWA,EAChBC,KAAKC,SAAWN,EAEhB,GAAIK,KAAKE,cAAe,CACnBC,IAAIC,GAA0DC,YAAY,cAC3E,MAAMC,EAAcH,IAAIC,GAAGG,QAAQ,cACnCP,KAAKQ,QAAU,IAAIF,EAAY,CAC3BG,GAAIT,KAAKU,iBAAiBZ,EAAeF,GACzCe,KAAM,CACFC,KAAM,GAAGf,KAAaD,IACtBiB,UAAYC,GAAiBA,EAAM,MAAQ,QAGnDd,KAAKe,sBAAsBf,KAAKQ,QAASb,EAAeE,GACxD,OAAOG,KAAKQ,OAChB,CAEAR,KAAKQ,QAAU,IAAIQ,EAAO,CACtBP,GAAIT,KAAKU,iBAAiBZ,EAAeF,GACzCqB,MAAO,IAAIpB,KAAaD,KACxBsB,SAAUvB,EAAcS,IAAIe,SAC5BC,OAASC,IACL,MAAMP,EAAOO,EAAoDC,aAAa,SAC9E,MAAMC,EAASvB,KAAKwB,WACpB,GAAIxB,KAAKD,SAAU,CACfC,KAAKD,SAASwB,EAAOE,QAASzB,KAAK0B,SACvC,KAIR1B,KAAKe,sBAAsBf,KAAKQ,QAASb,EAAeE,GAExD,OAAOG,KAAKQ,OAChB,CAEUmB,WACN,OAAO3B,KAAKQ,QAAWR,KAAKQ,QAAmBoB,WAAa,KAChE,CAEUC,aACN,GAAI7B,KAAKQ,SAAWR,KAAKC,SAAU,CAC/B,GAAID,KAAKE,cAAe,OACxB,MAAM4B,EAAK9B,KAAKQ,QAChBsB,EAAGC,YAAY/B,KAAKC,SAASG,IAAIe,SACrC,CACJ,EACH,IAAAa,EAAA,CAAAC,WAAA,MAAAD,EAAAvC,eAAA,OAAAuC,CAAA","ignoreList":[],"sourceRoot":"plugins/controls"}},{"offset":{"line":53,"column":0},"map":{"version":3,"names":["BasePlugin","___BasePlugin","TextAreaPlugin","render","fieldMetadata","bindingPath","modelName","engineScopeId","onChange","this","metadata","fieldKey","replace","isDisplayMode","sap","ui","requireSync","TextControl","require","control","id","generateStableId","text","applyCommonDirectives","TextArea","value","maxLength","required","rows","change","oEvent","val","getParameter","result","validate","isValid","getValue","applyState","input","setEditable","readOnly","setRequired","__exports","__esModule"],"sources":["TextAreaPlugin.ts"],"sourcesContent":["/**\n * @file TextAreaPlugin.ts\n * @description Renders a sap.m.TextArea for string data specifically marked with the textArea widget.\n */\n\nimport { BasePlugin } from \"./BasePlugin\";\nimport { IPropertyMetadata } from \"../../interfaces/ISchema\";\nimport TextArea from \"sap/m/TextArea\";\nimport Control from \"sap/ui/core/Control\";\n\n/**\n * Handles rendering and logic for multi-line text areas.\n */\nexport class TextAreaPlugin extends BasePlugin {\n public render(fieldMetadata: IPropertyMetadata, bindingPath: string, modelName: string = \"meta\", engineScopeId?: string, onChange?: (isValid: boolean, fieldKey?: string) => void): Control {\n this.onChange = onChange;\n this.metadata = fieldMetadata;\n this.fieldKey = bindingPath.replace(\"/\", \"\"); // For EventBus\n \n if (this.isDisplayMode) {\n (sap.ui as unknown as { requireSync: (s: string) => unknown }).requireSync(\"sap/m/Text\");\n const TextControl = sap.ui.require(\"sap/m/Text\");\n this.control = new TextControl({\n id: this.generateStableId(engineScopeId, bindingPath),\n text: `{${modelName}>${bindingPath}}`\n });\n this.applyCommonDirectives(this.control, fieldMetadata, modelName);\n return this.control as Control;\n }\n\n this.control = new TextArea({\n id: this.generateStableId(engineScopeId, bindingPath),\n value: `{${modelName}>${bindingPath}}`,\n maxLength: fieldMetadata.maxLength || 0,\n required: !!fieldMetadata.required,\n rows: fieldMetadata.ui?.rows || 4, // Default to 4 rows for text areas\n change: (oEvent: unknown) => {\n const val = (oEvent as { getParameter: (s: string) => unknown }).getParameter(\"value\");\n const result = this.validate();\n if (this.onChange) {\n this.onChange(result.isValid, this.fieldKey);\n }\n }\n });\n\n this.applyCommonDirectives(this.control, fieldMetadata, modelName);\n\n return this.control as Control;\n }\n\n protected getValue(): any {\n return this.control ? (this.control as TextArea).getValue() : null;\n }\n\n protected applyState(): void {\n if (this.control && this.metadata) {\n if (this.isDisplayMode) return;\n const input = this.control as TextArea;\n input.setEditable(!this.metadata.ui?.readOnly);\n input.setRequired(this.metadata.required);\n }\n }\n}\n"],"mappings":"AAAA,4IAAA,MAKSA,EAAUC,EAAA,cAQZ,MAAMC,UAAuBF,EACzBG,OAAOC,EAAmCC,EAAsBC,EAAoB,OAAQC,EAAwBC,GACvHC,KAAKD,SAAWA,EAChBC,KAAKC,SAAWN,EAChBK,KAAKE,SAAWN,EAAYO,QAAQ,IAAK,IAEzC,GAAIH,KAAKI,cAAe,CACnBC,IAAIC,GAA0DC,YAAY,cAC3E,MAAMC,EAAcH,IAAIC,GAAGG,QAAQ,cACnCT,KAAKU,QAAU,IAAIF,EAAY,CAC3BG,GAAIX,KAAKY,iBAAiBd,EAAeF,GACzCiB,KAAM,IAAIhB,KAAaD,OAE3BI,KAAKc,sBAAsBd,KAAKU,QAASf,EAAeE,GACxD,OAAOG,KAAKU,OAChB,CAEAV,KAAKU,QAAU,IAAIK,EAAS,CACxBJ,GAAIX,KAAKY,iBAAiBd,EAAeF,GACzCoB,MAAO,IAAInB,KAAaD,KACxBqB,UAAWtB,EAAcsB,WAAa,EACtCC,WAAYvB,EAAcuB,SAC1BC,KAAMxB,EAAcW,IAAIa,MAAQ,EAChCC,OAASC,IACL,MAAMC,EAAOD,EAAoDE,aAAa,SAC9E,MAAMC,EAASxB,KAAKyB,WACpB,GAAIzB,KAAKD,SAAU,CACfC,KAAKD,SAASyB,EAAOE,QAAS1B,KAAKE,SACvC,KAIRF,KAAKc,sBAAsBd,KAAKU,QAASf,EAAeE,GAExD,OAAOG,KAAKU,OAChB,CAEUiB,WACN,OAAO3B,KAAKU,QAAWV,KAAKU,QAAqBiB,WAAa,IAClE,CAEUC,aACN,GAAI5B,KAAKU,SAAWV,KAAKC,SAAU,CAC/B,GAAID,KAAKI,cAAe,OACxB,MAAMyB,EAAQ7B,KAAKU,QACnBmB,EAAMC,aAAa9B,KAAKC,SAASK,IAAIyB,UACrCF,EAAMG,YAAYhC,KAAKC,SAASiB,SACpC,CACJ,EACH,IAAAe,EAAA,CAAAC,WAAA,MAAAD,EAAAxC,iBAAA,OAAAwC,CAAA","ignoreList":[],"sourceRoot":"plugins/controls"}},{"offset":{"line":54,"column":0},"map":{"version":3,"names":["BasePlugin","___BasePlugin","TimePlugin","render","fieldMetadata","bindingPath","modelName","engineScopeId","onChange","this","metadata","isDisplayMode","sap","ui","requireSync","TextControl","require","control","id","generateStableId","text","path","type","formatOptions","source","pattern","applyCommonDirectives","TimePicker","value","displayFormat","editable","readOnly","required","change","oEvent","val","getParameter","result","validate","isValid","fieldKey","getValue","applyState","input","setEditable","setRequired","__exports","__esModule"],"sources":["TimePlugin.ts"],"sourcesContent":["/**\n * @file TimePlugin.ts\n * @description Handles rendering logic for Time strings.\n */\n\nimport { BasePlugin } from \"./BasePlugin\";\nimport { IPropertyMetadata } from \"../../interfaces/ISchema\";\nimport TimePicker from \"sap/m/TimePicker\";\nimport Control from \"sap/ui/core/Control\";\n\n/**\n * Handles rendering and logic for time inputs.\n */\nexport class TimePlugin extends BasePlugin {\n public render(fieldMetadata: IPropertyMetadata, bindingPath: string, modelName: string = \"meta\", engineScopeId?: string, onChange?: (isValid: boolean, fieldKey?: string) => void): Control {\n this.onChange = onChange;\n this.metadata = fieldMetadata;\n \n if (this.isDisplayMode) {\n (sap.ui as unknown as { requireSync: (s: string) => unknown }).requireSync(\"sap/m/Text\");\n const TextControl = sap.ui.require(\"sap/m/Text\");\n this.control = new TextControl({\n id: this.generateStableId(engineScopeId, bindingPath),\n text: {\n path: `${modelName}>${bindingPath}`,\n type: \"sap.ui.model.type.Time\",\n formatOptions: {\n source: { pattern: \"HH:mm:ss\" },\n pattern: \"HH:mm:ss\"\n }\n }\n });\n this.applyCommonDirectives(this.control, fieldMetadata, modelName);\n return this.control as Control;\n }\n\n this.control = new TimePicker({\n id: this.generateStableId(engineScopeId, bindingPath),\n value: {\n path: `${modelName}>${bindingPath}`,\n type: \"sap.ui.model.type.Time\",\n formatOptions: {\n source: { pattern: \"HH:mm:ss\" },\n pattern: \"HH:mm:ss\"\n }\n },\n displayFormat: \"HH:mm:ss\",\n editable: !fieldMetadata.ui?.readOnly,\n required: fieldMetadata.required,\n change: (oEvent: unknown) => {\n const val = (oEvent as { getParameter: (s: string) => unknown }).getParameter(\"value\");\n const result = this.validate();\n if (this.onChange) {\n this.onChange(result.isValid, this.fieldKey);\n }\n }\n });\n\n this.applyCommonDirectives(this.control, fieldMetadata, modelName);\n\n return this.control as Control;\n }\n\n protected getValue(): any {\n return this.control ? (this.control as TimePicker).getValue() : null;\n }\n\n protected applyState(): void {\n if (this.control && this.metadata) {\n if (this.isDisplayMode) return;\n const input = this.control as TimePicker;\n input.setEditable(!this.metadata.ui?.readOnly);\n input.setRequired(this.metadata.required);\n }\n }\n}\n"],"mappings":"AAAA,0IAAA,MAKSA,EAAUC,EAAA,cAQZ,MAAMC,UAAmBF,EACrBG,OAAOC,EAAmCC,EAAsBC,EAAoB,OAAQC,EAAwBC,GACvHC,KAAKD,SAAWA,EAChBC,KAAKC,SAAWN,EAEhB,GAAIK,KAAKE,cAAe,CACnBC,IAAIC,GAA0DC,YAAY,cAC3E,MAAMC,EAAcH,IAAIC,GAAGG,QAAQ,cACnCP,KAAKQ,QAAU,IAAIF,EAAY,CAC3BG,GAAIT,KAAKU,iBAAiBZ,EAAeF,GACzCe,KAAM,CACFC,KAAM,GAAGf,KAAaD,IACtBiB,KAAM,yBACNC,cAAe,CACXC,OAAQ,CAAEC,QAAS,YACnBA,QAAS,eAIrBhB,KAAKiB,sBAAsBjB,KAAKQ,QAASb,EAAeE,GACxD,OAAOG,KAAKQ,OAChB,CAEAR,KAAKQ,QAAU,IAAIU,EAAW,CAC1BT,GAAIT,KAAKU,iBAAiBZ,EAAeF,GACzCuB,MAAO,CACHP,KAAM,GAAGf,KAAaD,IACtBiB,KAAM,yBACNC,cAAe,CACXC,OAAQ,CAAEC,QAAS,YACnBA,QAAS,aAGjBI,cAAe,WACfC,UAAW1B,EAAcS,IAAIkB,SAC7BC,SAAU5B,EAAc4B,SACxBC,OAASC,IACL,MAAMC,EAAOD,EAAoDE,aAAa,SAC9E,MAAMC,EAAS5B,KAAK6B,WACpB,GAAI7B,KAAKD,SAAU,CACfC,KAAKD,SAAS6B,EAAOE,QAAS9B,KAAK+B,SACvC,KAIR/B,KAAKiB,sBAAsBjB,KAAKQ,QAASb,EAAeE,GAExD,OAAOG,KAAKQ,OAChB,CAEUwB,WACN,OAAOhC,KAAKQ,QAAWR,KAAKQ,QAAuBwB,WAAa,IACpE,CAEUC,aACN,GAAIjC,KAAKQ,SAAWR,KAAKC,SAAU,CAC/B,GAAID,KAAKE,cAAe,OACxB,MAAMgC,EAAQlC,KAAKQ,QACnB0B,EAAMC,aAAanC,KAAKC,SAASG,IAAIkB,UACrCY,EAAME,YAAYpC,KAAKC,SAASsB,SACpC,CACJ,EACH,IAAAc,EAAA,CAAAC,WAAA,MAAAD,EAAA5C,aAAA,OAAA4C,CAAA","ignoreList":[],"sourceRoot":"plugins/controls"}},{"offset":{"line":55,"column":0},"map":{"version":3,"names":["BasePlugin","___controls_BasePlugin","VoiceInputControl","_interopRequireDefault","__VoiceInputControl","VoiceInputPlugin","render","metadata","bindingPath","modelName","engineScopeId","onChange","this","fieldKey","replace","isDisplayMode","sap","ui","requireSync","TextControl","require","control","id","generateStableId","text","path","formatter","val","applyCommonDirectives","value","schemaMetadata","readOnly","attachCapture","result","validate","isValid","getValue","applyState","setProperty","__exports","__esModule"],"sources":["VoiceInputPlugin.ts"],"sourcesContent":["import { BasePlugin } from \"../controls/BasePlugin\";\nimport { IPropertyMetadata } from \"../../interfaces/ISchema\";\nimport Control from \"sap/ui/core/Control\";\nimport VoiceInputControl from \"../../controls/VoiceInputControl\";\n\nexport class VoiceInputPlugin extends BasePlugin {\n public render(metadata: IPropertyMetadata, bindingPath: string, modelName: string = \"meta\", engineScopeId?: string, onChange?: (isValid: boolean, fieldKey?: string) => void): Control {\n this.onChange = onChange;\n this.metadata = metadata;\n this.fieldKey = bindingPath.replace('/', '');\n this.modelName = modelName;\n\n if (this.isDisplayMode) {\n (sap.ui as unknown as { requireSync: (s: string) => unknown }).requireSync(\"sap/m/Text\");\n const TextControl = sap.ui.require(\"sap/m/Text\");\n this.control = new TextControl({\n id: this.generateStableId(engineScopeId, bindingPath),\n text: {\n path: `${modelName}>${bindingPath}`,\n formatter: (val: unknown) => {\n if (!val || val === \"undefined\" || val === \"null\") return \"\";\n return val;\n }\n }\n }) as unknown as sap.ui.core.Control;\n this.applyCommonDirectives(this.control, metadata, modelName);\n return this.control as Control;\n }\n\n this.control = new VoiceInputControl({\n id: this.generateStableId(engineScopeId, bindingPath),\n value: `{${modelName}>${bindingPath}}`,\n schemaMetadata: metadata,\n readOnly: !!metadata.ui?.readOnly\n }) as unknown as sap.ui.core.Control;\n\n this.applyCommonDirectives(this.control, metadata, modelName);\n\n (this.control as unknown as { attachCapture: (fn: Function) => void }).attachCapture(() => {\n const result = this.validate();\n if (this.onChange) {\n this.onChange(result.isValid, this.fieldKey);\n }\n });\n\n return this.control as Control;\n }\n\n protected getValue(): any {\n return this.control ? (this.control as unknown as { getValue: () => unknown }).getValue() : null;\n }\n\n protected applyState(): void {\n if (this.control && this.metadata) {\n if (this.isD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c1B,KAAKL,SAASU,IAAIc,SACtF,CACJ,EACH,IAAAQ,EAAA,CAAAC,WAAA,MAAAD,EAAAlC,mBAAA,OAAAkC,CAAA","ignoreList":[],"sourceRoot":"plugins/controls"}},{"offset":{"line":56,"column":0},"map":{"version":3,"names":["BasePlugin","___controls_BasePlugin","Logger","____utils_Logger","LiveSearchPlugin","render","fieldMetadata","bindingPath","modelName","this","metadata","input","Input","value","enabled","ui","readOnly","placeholder","showSuggestion","suggest","oEvent","query","getParameter","fetchSuggestions","change","validate","control","vhConfig","valueHelp","url","error","removeAllSuggestionItems","setBusy","fetch","then","res","json","data","keyPath","textPath","lowerQuery","toLowerCase","filteredData","filter","item","textValue","String","includes","forEach","itemData","addSuggestionItem","Item","key","text","catch","err","message","finally","getValue","applyState","setEnabled","__exports","__esModule"],"sources":["LiveSearchPlugin.ts"],"sourcesContent":["/**\n * @file LiveSearchPlugin.ts\n * @description A custom datasource plugin that provides asynchronous live search (autocomplete) functionality.\n */\n\nimport { BasePlugin } from \"../controls/BasePlugin\";\nimport { IPropertyMetadata } from \"../../interfaces/ISchema\";\nimport Input from \"sap/m/Input\";\nimport Item from \"sap/ui/core/Item\";\nimport Control from \"sap/ui/core/Control\";\nimport { Logger } from \"../../utils/Logger\";\n\n/**\n * A custom datasource plugin that provides asynchronous live search (autocomplete) functionality.\n * As the user types, it fetches suggestions from a remote endpoint.\n * \n * @namespace nz.co.siliconst.ui5.metaui.plugins.datasources\n * @public\n */\nexport class LiveSearchPlugin extends BasePlugin {\n public render(fieldMetadata: IPropertyMetadata, bindingPath: string, modelName: string = \"meta\"): Control {\n this.metadata = fieldMetadata;\n \n const input = new Input({\n value: `{${modelName}>${bindingPath}}`,\n enabled: !fieldMetadata.ui?.readOnly,\n placeholder: \"Type to search...\",\n showSuggestion: true,\n suggest: (oEvent: unknown) => {\n const query = (oEvent as { getParameter: (s: string) => unknown }).getParameter(\"suggestValue\");\n this.fetchSuggestions(input, query);\n },\n change: (oEvent: unknown) => {\n this.validate();\n }\n });\n\n this.control = input;\n return this.control as Control;\n }\n\n /**\n * Executes the REST fetch for suggestions based on a query. Can be overridden by mock subclasses.\n * @param input The UI5 Input to populate with suggestions.\n * @param query The text typed by the user.\n */\n protected fetchSuggestions(input: Input, query: string): void {\n const vhConfig = this.metadata?.valueHelp as unknown as Record<string, unknown>;\n if (!vhConfig || !vhConfig.url) {\n Logger.error(\"LiveSearchPlugin requires a valid valueHelp configuration with a URL.\", \"\", \"LiveSearchPlugin\");\n return;\n }\n\n if (!query) {\n input.removeAllSuggestionItems();\n return;\n }\n \n input.setBusy(true);\n \n // In a real application, the query parameter would be passed to the backend (e.g. ?q=query)\n // Here, we simulate fetching and filter locally, but subclasses can override this entirely.\n fetch(vhConfig.url)\n .then(res => res.json())\n .then((data: unknown[]) => {\n const keyPath = vhConfig.keyPath || \"key\";\n const textPath = vhConfig.textPath || \"text\";\n \n input.removeAllSuggestionItems();\n\n // Simple client-side filter for demonstration\n const lowerQuery = query.toLowerCase();\n const filteredData = data.filter(item => {\n const textValue = String(item[textPath] || item[keyPath]).toLowerCase();\n return textValue.includes(lowerQuery);\n });\n \n filteredData.forEach(itemData => {\n input.addSuggestionItem(new Item({ \n key: itemData[keyPath], \n text: itemData[textPath] || itemData[keyPath]\n }));\n });\n })\n .catch(err => {\n Logger.error(\"Failed to load value help from \" + vhConfig.url, err.message, \"LiveSearchPlugin\");\n })\n .finally(() => {\n input.setBusy(false);\n });\n }\n\n protected getValue(): any {\n return this.control ? (this.control as Input).getValue() : null;\n }\n\n protected applyState(): void {\n if (this.control && this.metadata) {\n (this.control as Input).setEnabled(!this.metadata.ui?.readOnly);\n }\n }\n}\n"],"mappings":"AAAA,oMAAA,MAKSA,EAAUC,EAAA,oBAKVC,EAAMC,EAAA,UASR,MAAMC,UAAyBJ,EAC3BK,OAAOC,EAAkCC,EAAqBC,EAAoB,QACrFC,KAAKC,SAAWJ,EAEhB,MAAMK,EAAQ,IAAIC,EAAM,CACpBC,MAAO,IAAI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CAAA","ignoreList":[],"sourceRoot":"plugins/datasources"}},{"offset":{"line":57,"column":0},"map":{"version":3,"names":["BasePlugin","___controls_BasePlugin","ODataListBindingPlugin","render","fieldMetadata","bindingPath","modelName","this","metadata","args","ui","path","key","text","control","ComboBox","selectedKey","enabled","readOnly","placeholder","label","change","oEvent","val","getParameter","getKey","validate","bindAggregation","template","Item","templateShareable","getValue","getSelectedKey","applyState","setEnabled","__exports","__esModule"],"sources":["ODataListBindingPlugin.ts"],"sourcesContent":["/**\n * @file ODataListBindingPlugin.ts\n * @description A custom datasource plugin that binds a ComboBox to an OData EntitySet.\n */\n\nimport { BasePlugin } from \"../controls/BasePlugin\";\nimport { IPropertyMetadata } from \"../../interfaces/ISchema\";\nimport ComboBox from \"sap/m/ComboBox\";\nimport Item from \"sap/ui/core/Item\";\nimport Control from \"sap/ui/core/Control\";\n\n/**\n * Renders a ComboBox natively bound to an OData Model entity set.\n * Expects args: { path: \"/Categories\", key: \"ID\", text: \"Name\" }\n * \n * @namespace nz.co.siliconst.ui5.metaui.plugins.datasources\n * @public\n */\nexport class ODataListBindingPlugin extends BasePlugin {\n public render(fieldMetadata: IPropertyMetadata, bindingPath: string, modelName: string = \"meta\"): Control {\n this.metadata = fieldMetadata;\n \n const args = fieldMetadata.ui?.args || { path: \"/\", key: \"ID\", text: \"Name\" };\n \n this.control = new ComboBox({\n selectedKey: `{${modelName}>${bindingPath}}`,\n enabled: !fieldMetadata.ui?.readOnly,\n placeholder: fieldMetadata.ui?.label || \"Select...\",\n change: (oEvent: unknown) => {\n const val = (oEvent as { getParameter: (s: string) => unknown }).getParameter(\"selectedItem\")?.getKey();\n this.validate();\n }\n });\n\n // Natively bind aggregation to the default model (OData)\n (this.control as ComboBox).bindAggregation(\"items\", {\n path: args.path,\n template: new Item({\n key: `{${args.key}}`,\n text: `{${args.text}}`\n }),\n templateShareable: false\n });\n\n return this.control as Control;\n }\n\n protected getValue(): any {\n return this.control ? (this.control as ComboBox).getSelectedKey() : null;\n }\n\n protected applyState(): void {\n if (this.control && this.metadata) {\n (this.control as ComboBox).setEnabled(!this.metadata.ui?.readOnly);\n }\n }\n}\n"],"mappings":"AAAA,sLAAA,MAKSA,EAAUC,EAAA,cAaZ,MAAMC,UAA+BF,EACjCG,OAAOC,EAAkCC,EAAqBC,EAAoB,QACrFC,KAAKC,SAAWJ,EAEhB,MAAMK,EAAOL,EAAcM,IAAID,MAAQ,CAAEE,KAAM,IAAKC,IAAK,KAAMC,KAAM,QAErEN,KAAKO,QAAU,IAAIC,EAAS,CACxBC,YAAa,IAAIV,KAAaD,KAC9BY,SAAUb,EAAcM,IAAIQ,SAC5BC,YAAaf,EAAcM,IAAIU,OAAS,YACxCC,OAASC,IACL,MAAMC,EAAOD,EAAoDE,aAAa,iBAAiBC,SAC/FlB,KAAKmB,cAKZnB,KAAKO,QAAqBa,gBAAgB,QAAS,CAChDhB,KAAMF,EAAKE,KACXiB,SAAU,IAAIC,EAAK,CACfjB,IAAK,IAAIH,EAAKG,OACdC,KAAM,IAAIJ,EAAKI,UAEnBiB,kBAAmB,QAGvB,OAAOvB,KAAKO,OAChB,CAEUiB,WACN,OAAOxB,KAAKO,QAAWP,KAAKO,QAAqBkB,iBAAmB,IACxE,CAEUC,aACN,GAAI1B,KAAKO,SAAWP,KAAKC,SAAU,CAC9BD,KAAKO,QAAqBoB,YAAY3B,KAAKC,SAASE,IAAIQ,SAC7D,CACJ,EACH,IAAAiB,EAAA,CAAAC,WAAA,MAAAD,EAAAjC,yBAAA,OAAAiC,CAAA","ignoreList":[],"sourceRoot":"plugins/datasources"}},{"offset":{"line":58,"column":0},"map":{"version":3,"names":["BasePlugin","___controls_BasePlugin","Logger","____utils_Logger","RemoteDropdownPlugin","render","fieldMetadata","bindingPath","modelName","engineScopeId","onChange","this","metadata","config","valueHelp","url","warn","sap","m","Text","text","isDisplayMode","ui","requireSync","TextControl","require","control","id","generateStableId","applyCommonDirectives","select","Select","selectedKey","enabled","readOnly","forceSelection","busy","change","oEvent","result","validate","isValid","fieldKey","addItem","Item","key","fetch","then","res","ok","Error","status","json","data","arr","Array","isArray","value","forEach","item","k","keyPath","t","textPath","String","setBusy","catch","err","error","message","getValue","getSelectedKey","applyState","setEnabled","__exports","__esModule"],"sources":["RemoteDropdownPlugin.ts"],"sourcesContent":["/**\n * @file RemoteDropdownPlugin.ts\n * @description Renders a sap.m.Select that fetches valueHelp remotely via a JSON URL.\n */\n\nimport { BasePlugin } from \"../controls/BasePlugin\";\nimport { IPropertyMetadata, IRemoteValueHelpConfig } from \"../../interfaces/ISchema\";\nimport Select from \"sap/m/Select\";\nimport Item from \"sap/ui/core/Item\";\nimport Control from \"sap/ui/core/Control\";\nimport { Logger } from \"../../utils/Logger\";\n\n/**\n * Handles rendering logic for dropdown inputs fetching data remotely.\n * Maps a URL response array to `sap.ui.core.Item` elements.\n * \n * @namespace nz.co.siliconst.ui5.metaui.plugins.datasources\n * @public\n */\nexport class RemoteDropdownPlugin extends BasePlugin {\n \n public render(fieldMetadata: IPropertyMetadata, bindingPath: string, modelName: string = \"meta\", engineScopeId?: string, onChange?: (isValid: boolean, fieldKey?: string) => void): Control {\n this.onChange = onChange;\n this.metadata = fieldMetadata;\n\n const config = fieldMetadata.valueHelp as IRemoteValueHelpConfig;\n if (!config || !config.url) {\n Logger.warn(\"[MetaUI RemoteDropdownPlugin] No valid URL provided for remoteDropdown.\");\n return new sap.m.Text({ text: \"Error: No URL provided\" }) as Control;\n }\n \n if (this.isDisplayMode) {\n sap.ui.requireSync(\"sap/m/Text\");\n const TextControl = sap.ui.require(\"sap/m/Text\");\n \n this.control = new TextControl({\n id: this.generateStableId(engineScopeId, bindingPath),\n text: `{${modelName}>${bindingPath}}` // We might not have the text mapping synchronously\n });\n \n // Optionally, we could fetch data and update the text formatter here\n \n this.applyCommonDirectives(this.control, fieldMetadata, modelName);\n return this.control as Control;\n }\n\n const select = new Select({\n id: this.generateStableId(engineScopeId, bindingPath),\n selectedKey: `{${modelName}>${bindingPath}}`,\n enabled: !fieldMetadata.ui?.readOnly,\n forceSelection: false,\n busy: true, // Show busy indicator while fetching\n change: (oEvent: sap.ui.base.Event) => {\n const result = this.validate();\n if (this.onChange) {\n this.onChange(result.isValid, this.fieldKey);\n }\n }\n });\n\n // Add empty placeholder\n select.addItem(new Item({ key: \"\", text: \"--- Select ---\" }));\n\n // Fetch data remotely\n fetch(config.url)\n .then(res => {\n if (!res.ok) throw new Error(`HTTP ${res.status}`);\n return res.json();\n })\n .then(data => {\n const arr = Array.isArray(data) ? data : (data.value || []);\n arr.forEach((item: any) => {\n const k = config.keyPath ? item[config.keyPath] : item;\n const t = config.textPath ? item[config.textPath] : item;\n select.addItem(new Item({ key: String(k), text: String(t) }));\n });\n select.setBusy(false);\n })\n .catch(err => {\n Logger.error(`[MetaUI RemoteDropdownPlugin] Failed to fetch remote data from ${config.url}`, err.message);\n select.addItem(new Item({ key: \"\", text: \"Error loading data\" }));\n select.setBusy(false);\n });\n\n this.control = select;\n this.applyCommonDirectives(this.control, fieldMetadata, modelName);\n return this.control as Control;\n }\n\n protected getValue(): any {\n return this.control ? (this.control as Select).getSelectedKey() : null;\n }\n\n protected applyState(): void {\n if (this.control && this.metadata) {\n if (this.isDisplayMode) return;\n const select = this.control as Select;\n select.setEnabled(!this.metadata.ui?.readOnly);\n }\n }\n}\n"],"mappings":"AAAA,yMAAA,MAKSA,EAAUC,EAAA,oBAKVC,EAAMC,EAAA,UASR,MAAMC,UAA6BJ,EAE/BK,OAAOC,EAAkCC,EAAqBC,EAAoB,OAAQC,EAAwBC,GACrHC,KAAKD,SAAWA,EAChBC,KAAKC,SAAWN,EAEhB,MAAMO,EAASP,EAAcQ,UAC7B,IAAKD,IAAWA,EAAOE,IAAK,CACxBb,EAAOc,KAAK,2EACZ,OAAO,IAAIC,IAAIC,EAAEC,KAAK,CAAEC,KAAM,0BAClC,CAEA,GAAIT,KAAKU,cAAe,CACpBJ,IAAIK,GAAGC,YAAY,cACnB,MAAMC,EAAcP,IAAIK,GAA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AOG,KAAKe,OAChB,CAEU4C,WACN,OAAO3D,KAAKe,QAAWf,KAAKe,QAAmB6C,iBAAmB,IACtE,CAEUC,aACN,GAAI7D,KAAKe,SAAWf,KAAKC,SAAU,CAC/B,GAAID,KAAKU,cAAe,OACxB,MAAMS,EAASnB,KAAKe,QACpBI,EAAO2C,YAAY9D,KAAKC,SAASU,IAAIY,SACzC,CACJ,EACH,IAAAwC,EAAA,CAAAC,WAAA,MAAAD,EAAAtE,uBAAA,OAAAsE,CAAA","ignoreList":[],"sourceRoot":"plugins/datasources"}},{"offset":{"line":59,"column":0},"map":{"version":3,"names":["BasePlugin","___controls_BasePlugin","Logger","____utils_Logger","RemoteValueHelpPlugin","isLoaded","render","fieldMetadata","bindingPath","modelName","this","metadata","comboBox","ComboBox","selectedKey","enabled","ui","readOnly","placeholder","change","oEvent","item","getParameter","val","getKey","validate","attachEventOnce","fetchData","control","vhConfig","valueHelp","url","error","setBusy","fetch","then","res","json","data","keyPath","textPath","forEach","itemData","addItem","Item","key","text","catch","err","message","finally","getValue","getSelectedKey","applyState","setEnabled","__exports","__esModule"],"sources":["RemoteValueHelpPlugin.ts"],"sourcesContent":["/**\n * @file RemoteValueHelpPlugin.ts\n * @description A custom datasource plugin that simulates fetching data from a remote server.\n */\n\nimport { BasePlugin } from \"../controls/BasePlugin\";\nimport { IPropertyMetadata } from \"../../interfaces/ISchema\";\nimport ComboBox from \"sap/m/ComboBox\";\nimport Item from \"sap/ui/core/Item\";\nimport Control from \"sap/ui/core/Control\";\nimport { Logger } from \"../../utils/Logger\";\n\n/**\n * A custom datasource plugin that simulates fetching data from a remote server.\n * Proves out custom data sources that dynamically load value help.\n * \n * @namespace nz.co.siliconst.ui5.metaui.plugins.datasources\n * @public\n */\nexport class RemoteValueHelpPlugin extends BasePlugin {\n private isLoaded = false;\n\n public render(fieldMetadata: IPropertyMetadata, bindingPath: string, modelName: string = \"meta\"): Control {\n this.metadata = fieldMetadata;\n \n const comboBox = new ComboBox({\n selectedKey: `{${modelName}>${bindingPath}}`,\n enabled: !fieldMetadata.ui?.readOnly,\n placeholder: \"Select a country...\",\n change: (oEvent: unknown) => {\n const item = (oEvent as { getParameter: (s: string) => unknown }).getParameter(\"selectedItem\");\n const val = item ? item.getKey() : (oEvent as { getParameter: (s: string) => unknown }).getParameter(\"value\"); // Allow free text as well\n this.validate();\n }\n });\n\n // Perform an async load against the REST endpoint\n comboBox.attachEventOnce(\"loadItems\", () => {\n this.fetchData(comboBox);\n });\n\n this.control = comboBox;\n return this.control as Control;\n }\n\n protected fetchData(comboBox: ComboBox): void {\n const vhConfig = this.metadata?.valueHelp as unknown as Record<string, unknown>;\n if (!vhConfig || !vhConfig.url) {\n Logger.error(\"RemoteValueHelpPlugin requires a valid valueHelp configuration with a URL.\", \"\", \"RemoteValueHelpPlugin\");\n return;\n }\n \n comboBox.setBusy(true);\n \n fetch(vhConfig.url)\n .then(res => res.json())\n .then((data: unknown[]) => {\n const keyPath = vhConfig.keyPath || \"key\";\n const textPath = vhConfig.textPath || \"text\";\n \n data.forEach(itemData => {\n comboBox.addItem(new Item({ \n key: itemData[keyPath], \n text: itemData[textPath] || itemData[keyPath]\n }));\n });\n })\n .catch(err => {\n Logger.error(\"Failed to load value help from \" + vhConfig.url, err.message, \"RemoteValueHelpPlugin\");\n })\n .finally(() => {\n comboBox.setBusy(false);\n this.isLoaded = true;\n });\n }\n\n protected getValue(): any {\n return this.control ? (this.control as ComboBox).getSelectedKey() : null;\n }\n\n protected applyState(): void {\n if (this.control && this.metadata) {\n (this.control as ComboBox).setEnabled(!this.metadata.ui?.readOnly);\n }\n }\n}\n"],"mappings":"AAAA,4MAAA,MAKSA,EAAUC,EAAA,oBAKVC,EAAMC,EAAA,UASR,MAAMC,UAA8BJ,EAC/BK,SAAW,MAEZC,OAAOC,EAAkCC,EAAqBC,EAAoB,QACrFC,KAAKC,SAAWJ,EAEhB,MAAMK,EAAW,IAAIC,EAAS,CAC1BC,YAAa,IAAIL,KAAaD,KAC9BO,SAAUR,EAAcS,IAAIC,SAC5BC,YAAa,sBACbC,OAASC,IACL,MAAMC,EAAQD,EAAoDE,aAAa,gBAC/E,MAAMC,EAAMF,EAAOA,EAAKG,SAAYJ,EAAoDE,aAAa,SACrGZ,KAAKe,cAKbb,EAASc,gBAAgB,YAAa,KAClChB,KAAKiB,UAAUf,KAGnBF,KAAKkB,QAAUhB,EACf,OAAOF,KAAKkB,OAChB,CAEUD,UAAUf,GAChB,MAAMiB,EAAWnB,KAAKC,UAAUmB,UAChC,IAAKD,IAAaA,EAASE,IAAK,CAC5B7B,EAAO8B,MAAM,6EAA8E,GAAI,yBAC/F,MACJ,CAEApB,EAASqB,QAAQ,MAEjBC,MAAML,EAASE,KACVI,KAAKC,GAAOA,EAAIC,QAChBF,KAAMG,IACH,MAAMC,EAAUV,EAASU,SAAW,MACpC,MAAMC,EAAWX,EAASW,UAAY,OAEtCF,EAAKG,QAAQC,IACT9B,EAAS+B,QAAQ,IAAIC,EAAK,CACtBC,IAAKH,EAASH,GACdO,KAAMJ,EAASF,IAAaE,EAASH,UAIhDQ,MAAMC,IACH9C,EAAO8B,MAAM,kCAAoCH,EAASE,IAAKiB,EAAIC,QAAS,2BAE/EC,QAAQ,KACLtC,EAASqB,QAAQ,OACjBvB,KAAKL,SAAW,MAE5B,CAEU8C,WACN,OAAOzC,KAAKkB,QAAWlB,KAAKkB,QAAqBwB,iBAAmB,IACxE,CAEUC,aACN,GAAI3C,KAAKkB,SAAWlB,KAAKC,SAAU,CAC9BD,KAAKkB,QAAqB0B,YAAY5C,KAAKC,SAASK,IAAIC,SAC7D,CACJ,EACH,IAAAsC,EAAA,CAAAC,WAAA,MAAAD,EAAAnD,wBAAA,OAAAmD,CAAA","ignoreList":[],"sourceRoot":"plugins/datasources"}},{"offset":{"line":60,"column":0},"map":{"version":3,"names":["CurrencyFormatterPlugin","constructor","this","currencyFormat","NumberFormat","getCurrencyInstance","showMeasure","format","rawValue","args","undefined","__exports","__esModule"],"sources":["CurrencyFormatterPlugin.ts"],"sourcesContent":["/**\n * @file CurrencyFormatterPlugin.ts\n * @description Standard data formatter for currency values.\n */\n\nimport { IFormatter } from \"../../interfaces/IPipeline\";\nimport NumberFormat from \"sap/ui/core/format/NumberFormat\";\n\n/**\n * Standard data formatter for currency values.\n * Uses sap.ui.core.format.NumberFormat to format raw numbers into localized currency strings.\n * \n * @namespace nz.co.siliconst.ui5.metaui.plugins.formatters\n * @public\n */\nexport class CurrencyFormatterPlugin implements IFormatter {\n private currencyFormat: any;\n\n constructor() {\n this.currencyFormat = NumberFormat.getCurrencyInstance({\n showMeasure: false\n });\n }\n\n /**\n * Formats raw JSON model data into a UI-friendly currency string.\n * @param rawValue The raw numeric value from the JSON payload.\n * @returns The formatted string for the UI control.\n */\n public format(rawValue: unknown, args?: unknown): string {\n if (rawValue === null || rawValue === undefined) {\n return \"\";\n }\n return \"$\" + this.currencyFormat.format(rawValue);\n }\n}\n"],"mappings":"AAAA,uJAeO,MAAMA,EAGTC,cACIC,KAAKC,eAAiBC,EAAaC,oBAAoB,CACnDC,YAAa,OAErB,CAOOC,OAAOC,EAAmBC,GAC7B,GAAID,IAAa,MAAQA,IAAaE,UAAW,CAC7C,MAAO,EACX,CACA,MAAO,IAAMR,KAAKC,eAAeI,OAAOC,EAC5C,EACH,IAAAG,EAAA,CAAAC,WAAA,MAAAD,EAAAX,0BAAA,OAAAW,CAAA","ignoreList":[],"sourceRoot":"plugins/formatters"}},{"offset":{"line":61,"column":0},"map":{"version":3,"names":["DateFormatterPlugin","constructor","this","dateFormat","DateFormat","getDateInstance","style","format","rawValue","args","dateObj","Date","e","__exports","__esModule"],"sources":["DateFormatterPlugin.ts"],"sourcesContent":["/**\n * @file DateFormatterPlugin.ts\n * @description Standard data formatter for dates.\n */\n\nimport { IFormatter } from \"../../interfaces/IPipeline\";\nimport DateFormat from \"sap/ui/core/format/DateFormat\";\n\n/**\n * Formats ISO date strings to localized Medium formats (e.g., \"Oct 15, 2026\").\n * \n * @namespace nz.co.siliconst.ui5.metaui.plugins.formatters\n * @public\n */\nexport class DateFormatterPlugin implements IFormatter {\n private dateFormat: any;\n\n constructor() {\n this.dateFormat = DateFormat.getDateInstance({ style: \"medium\" });\n }\n\n public format(rawValue: unknown, args?: unknown): string {\n if (!rawValue) return \"\";\n try {\n const dateObj = new Date(rawValue as string);\n return this.dateFormat.format(dateObj);\n } catch (e) {\n return rawValue as string; // Fallback to raw string if invalid date\n }\n }\n}\n"],"mappings":"AAAA,iJAcO,MAAMA,EAGTC,cACIC,KAAKC,WAAaC,EAAWC,gBAAgB,CAAEC,MAAO,UAC1D,CAEOC,OAAOC,EAAmBC,GAC7B,IAAKD,EAAU,MAAO,GACtB,IACI,MAAME,EAAU,IAAIC,KAAKH,GACzB,OAAON,KAAKC,WAAWI,OAAOG,EAClC,CAAE,MAAOE,GACL,OAAOJ,CACX,CACJ,EACH,IAAAK,EAAA,CAAAC,WAAA,MAAAD,EAAAb,sBAAA,OAAAa,CAAA","ignoreList":[],"sourceRoot":"plugins/formatters"}},{"offset":{"line":62,"column":0},"map":{"version":3,"names":["PhoneFormatterPlugin","format","rawValue","args","cleaned","replace","match","__exports","__esModule"],"sources":["PhoneFormatterPlugin.ts"],"sourcesContent":["/**\n * @file PhoneFormatterPlugin.ts\n * @description Standard data formatter for phone numbers.\n */\n\nimport { IFormatter } from \"../../interfaces/IPipeline\";\n\n/**\n * Simple mask for 10-digit phone numbers (e.g. 5551234567 -> (555) 123-4567).\n * \n * @namespace nz.co.siliconst.ui5.metaui.plugins.formatters\n * @public\n */\nexport class PhoneFormatterPlugin implements IFormatter {\n public format(rawValue: unknown, args?: unknown): string {\n if (!rawValue || typeof rawValue !== \"string\") return rawValue || \"\";\n \n const cleaned = ('' + rawValue).replace(/\\D/g, '');\n const match = cleaned.match(/^(\\d{3})(\\d{3})(\\d{4})$/);\n \n if (match) {\n return '(' + match[1] + ') ' + match[2] + '-' + match[3];\n }\n \n return rawValue as string;\n }\n}\n"],"mappings":"AAAA,kHAaO,MAAMA,EACFC,OAAOC,EAAmBC,GAC7B,IAAKD,UAAmBA,IAAa,SAAU,OAAOA,GAAY,GAElE,MAAME,GAAW,GAAKF,GAAUG,QAAQ,MAAO,IAC/C,MAAMC,EAAQF,EAAQE,MAAM,2BAE5B,GAAIA,EAAO,CACP,MAAO,IAAMA,EAAM,GAAK,KAAOA,EAAM,GAAK,IAAMA,EAAM,EAC1D,CAEA,OAAOJ,CACX,EACH,IAAAK,EAAA,CAAAC,WAAA,MAAAD,EAAAP,uBAAA,OAAAO,CAAA","ignoreList":[],"sourceRoot":"plugins/formatters"}},{"offset":{"line":63,"column":0},"map":{"version":3,"names":["TextCaseFormatterPlugin","format","rawValue","args","toUpperCase","__exports","__esModule"],"sources":["TextCaseFormatterPlugin.ts"],"sourcesContent":["/**\n * @file TextCaseFormatterPlugin.ts\n * @description Standard data formatter for text casing.\n */\n\nimport { IFormatter } from \"../../interfaces/IPipeline\";\n\n/**\n * Transforms text to UPPERCASE, lowercase, or Title Case.\n * Defaults to uppercase.\n * \n * @namespace nz.co.siliconst.ui5.metaui.plugins.formatters\n * @public\n */\nexport class TextCaseFormatterPlugin implements IFormatter {\n public format(rawValue: unknown, args?: unknown): string {\n if (typeof rawValue !== \"string\") return rawValue || \"\";\n \n // Default to uppercase if no specific arg could be easily parsed by simple formatter \n // (could be enhanced to support schema args if formatters allowed args).\n return rawValue.toUpperCase();\n }\n}\n"],"mappings":"AAAA,qHAcO,MAAMA,EACFC,OAAOC,EAAmBC,GAC7B,UAAWD,IAAa,SAAU,OAAOA,GAAY,GAIrD,OAAOA,EAASE,aACpB,EACH,IAAAC,EAAA,CAAAC,WAAA,MAAAD,EAAAL,0BAAA,OAAAK,CAAA","ignoreList":[],"sourceRoot":"plugins/formatters"}},{"offset":{"line":64,"column":0},"map":{"version":3,"names":["EmailValidatorPlugin","validate","parsedValue","args","isValid","emailRegex","test","errorMessage","__exports","__esModule"],"sources":["EmailValidatorPlugin.ts"],"sourcesContent":["/**\n * @file EmailValidatorPlugin.ts\n * @description Standard business logic validator for email addresses.\n */\n\nimport { IValidator, IValidationResult } from \"../../interfaces/IPipeline\";\n\n/**\n * Standard business logic validator for email addresses.\n * Extracts the email regex validation logic into a standalone, modular plugin.\n * \n * @namespace nz.co.siliconst.ui5.metaui.plugins.validators\n * @public\n */\nexport class EmailValidatorPlugin implements IValidator {\n /**\n * Validates parsed data before it enters the JSON model.\n * @param parsedValue The cleaned data to validate.\n * @param args Optional arguments provided in the schema.\n * @returns IValidationResult containing status and optional error message.\n */\n public validate(parsedValue: unknown, args?: unknown): IValidationResult {\n if (!parsedValue as string) return { isValid: true }; // Let RequiredValidator handle empty\n const emailRegex = /^[^\\s@]+@[^\\s@]+\\.[^\\s@]+$/;\n if (!emailRegex.test(parsedValue as string)) {\n return { isValid: false, errorMessage: \"Please enter a valid email address.\" };\n }\n return { isValid: true };\n }\n}\n"],"mappings":"AAAA,kHAcO,MAAMA,EAOFC,SAASC,EAAsBC,GAClC,IAAKD,EAAuB,MAAO,CAAEE,QAAS,MAC9C,MAAMC,EAAa,6BACnB,IAAKA,EAAWC,KAAKJ,GAAwB,CACzC,MAAO,CAAEE,QAAS,MAAOG,aAAc,sCAC3C,CACA,MAAO,CAAEH,QAAS,KACtB,EACH,IAAAI,EAAA,CAAAC,WAAA,MAAAD,EAAAR,uBAAA,OAAAQ,CAAA","ignoreList":[],"sourceRoot":"plugins/validators"}},{"offset":{"line":65,"column":0},"map":{"version":3,"names":["IbanValidatorPlugin","validate","parsedValue","args","isValid","ibanRegex","test","replace","toUpperCase","errorMessage","__exports","__esModule"],"sources":["IbanValidatorPlugin.ts"],"sourcesContent":["/**\n * @file IbanValidatorPlugin.ts\n * @description Standard business logic validator for International Bank Account Numbers.\n */\n\nimport { IValidator, IValidationResult } from \"../../interfaces/IPipeline\";\n\n/**\n * Validates a standard IBAN string.\n * This provides a simplified check for demonstration (starts with 2 chars, followed by digits/chars).\n * \n * @namespace nz.co.siliconst.ui5.metaui.plugins.validators\n * @public\n */\nexport class IbanValidatorPlugin implements IValidator {\n public validate(parsedValue: unknown, args?: unknown): IValidationResult {\n if (!parsedValue) return { isValid: true }; // Let RequiredValidator handle empty\n \n // Very basic IBAN structure regex (e.g. DE89370400440532013000)\n // A true IBAN check requires modulo 97 arithmetic which is out of scope for a basic mock.\n const ibanRegex = /^[A-Z]{2}\\d{2}[A-Z0-9]{1,30}$/;\n \n if (typeof parsedValue !== \"string\" || !ibanRegex.test(parsedValue.replace(/\\s+/g, '').toUpperCase())) {\n return { isValid: false, errorMessage: \"Please enter a valid IBAN.\" };\n }\n \n return { isValid: true };\n }\n}\n"],"mappings":"AAAA,iHAcO,MAAMA,EACFC,SAASC,EAAsBC,GAClC,IAAKD,EAAa,MAAO,CAAEE,QAAS,MAIpC,MAAMC,EAAY,gCAElB,UAAWH,IAAgB,WAAaG,EAAUC,KAAKJ,EAAYK,QAAQ,OAAQ,IAAIC,eAAgB,CACnG,MAAO,CAAEJ,QAAS,MAAOK,aAAc,6BAC3C,CAEA,MAAO,CAAEL,QAAS,KACtB,EACH,IAAAM,EAAA,CAAAC,WAAA,MAAAD,EAAAV,sBAAA,OAAAU,CAAA","ignoreList":[],"sourceRoot":"plugins/validators"}},{"offset":{"line":66,"column":0},"map":{"version":3,"names":["MinLengthValidatorPlugin","validate","parsedValue","args","isValid","length","errorMessage","__exports","__esModule"],"sources":["MinLengthValidatorPlugin.ts"],"sourcesContent":["/**\n * @file MinLengthValidatorPlugin.ts\n * @description Standard business logic validator for string minimum lengths.\n */\n\nimport { IValidator, IValidationResult } from \"../../interfaces/IPipeline\";\n\n/**\n * Ensures string length meets a minimum threshold.\n * \n * @namespace nz.co.siliconst.ui5.metaui.plugins.validators\n * @public\n */\nexport class MinLengthValidatorPlugin implements IValidator {\n public validate(parsedValue: unknown, args?: unknown): IValidationResult {\n if (!parsedValue) return { isValid: true }; // Let RequiredValidator handle empty\n if (typeof args !== \"number\") return { isValid: true }; // Invalid config\n\n if (typeof parsedValue === \"string\" && parsedValue.length < args) {\n return { isValid: false, errorMessage: `Minimum length is ${args} characters.` };\n }\n \n return { isValid: true };\n }\n}\n"],"mappings":"AAAA,sHAaO,MAAMA,EACFC,SAASC,EAAsBC,GAClC,IAAKD,EAAa,MAAO,CAAEE,QAAS,MACpC,UAAWD,IAAS,SAAU,MAAO,CAAEC,QAAS,MAEhD,UAAWF,IAAgB,UAAYA,EAAYG,OAASF,EAAM,CAC9D,MAAO,CAAEC,QAAS,MAAOE,aAAc,qBAAqBH,gBAChE,CAEA,MAAO,CAAEC,QAAS,KACtB,EACH,IAAAG,EAAA,CAAAC,WAAA,MAAAD,EAAAP,2BAAA,OAAAO,CAAA","ignoreList":[],"sourceRoot":"plugins/validators"}},{"offset":{"line":67,"column":0},"map":{"version":3,"names":["PatternValidatorPlugin","validate","parsedValue","args","isValid","regex","RegExp","test","errorMessage","e","__exports","__esModule"],"sources":["PatternValidatorPlugin.ts"],"sourcesContent":["/**\n * @file PatternValidatorPlugin.ts\n * @description Standard business logic validator for Regex patterns.\n */\n\nimport { IValidator, IValidationResult } from \"../../interfaces/IPipeline\";\n\n/**\n * Validates a string against a regular expression pattern provided in the schema args.\n * \n * @namespace nz.co.siliconst.ui5.metaui.plugins.validators\n * @public\n */\nexport class PatternValidatorPlugin implements IValidator {\n public validate(parsedValue: unknown, args?: unknown): IValidationResult {\n if (!parsedValue as string) return { isValid: true }; // Let RequiredValidator handle empty\n if (!args || typeof args !== \"string\") {\n return { isValid: true }; // Invalid config, skip\n }\n\n try {\n const regex = new RegExp(args);\n if (!regex.test(parsedValue as string)) {\n return { isValid: false, errorMessage: `Input does not match the required pattern.` };\n }\n } catch (e) {\n // Invalid regex string provided\n return { isValid: false, errorMessage: `Schema configuration error: Invalid regex pattern.` };\n }\n \n return { isValid: true };\n }\n}\n"],"mappings":"AAAA,oHAaO,MAAMA,EACFC,SAASC,EAAsBC,GAClC,IAAKD,EAAuB,MAAO,CAAEE,QAAS,MAC9C,IAAKD,UAAeA,IAAS,SAAU,CACnC,MAAO,CAAEC,QAAS,KACtB,CAEA,IACI,MAAMC,EAAQ,IAAIC,OAAOH,GACzB,IAAKE,EAAME,KAAKL,GAAwB,CACpC,MAAO,CAAEE,QAAS,MAAOI,aAAc,6CAC3C,CACJ,CAAE,MAAOC,GAEL,MAAO,CAAEL,QAAS,MAAOI,aAAc,qDAC3C,CAEA,MAAO,CAAEJ,QAAS,KACtB,EACH,IAAAM,EAAA,CAAAC,WAAA,MAAAD,EAAAV,yBAAA,OAAAU,CAAA","ignoreList":[],"sourceRoot":"plugins/validators"}},{"offset":{"line":68,"column":0},"map":{"version":3,"names":["RangeValidatorPlugin","validate","parsedValue","args","undefined","isValid","min","max","errorMessage","__exports","__esModule"],"sources":["RangeValidatorPlugin.ts"],"sourcesContent":["/**\n * @file RangeValidatorPlugin.ts\n * @description Standard business logic validator for numeric ranges.\n */\n\nimport { IValidator, IValidationResult } from \"../../interfaces/IPipeline\";\n\n/**\n * Ensures a numeric value falls within an optionally provided min and max range.\n * \n * @namespace nz.co.siliconst.ui5.metaui.plugins.validators\n * @public\n */\nexport class RangeValidatorPlugin implements IValidator {\n public validate(parsedValue: unknown, args?: Record<string, unknown>): IValidationResult {\n if (parsedValue === null || parsedValue === undefined) return { isValid: true }; \n if (typeof parsedValue !== \"number\") return { isValid: true };\n\n const min = args?.min;\n const max = args?.max;\n\n if (min !== undefined && typeof min === \"number\" && parsedValue < min) {\n return { isValid: false, errorMessage: `Value must be greater than or equal to ${min}.` };\n }\n\n if (max !== undefined && typeof max === \"number\" && parsedValue > max) {\n return { isValid: false, errorMessage: `Value must be less than or equal to ${max}.` };\n }\n \n return { isValid: true };\n }\n}\n"],"mappings":"AAAA,kHAaO,MAAMA,EACFC,SAASC,EAAsBC,GAClC,GAAID,IAAgB,MAAQA,IAAgBE,UAAW,MAAO,CAAEC,QAAS,MACzE,UAAWH,IAAgB,SAAU,MAAO,CAAEG,QAAS,MAEvD,MAAMC,EAAMH,GAAMG,IAClB,MAAMC,EAAMJ,GAAMI,IAElB,GAAID,IAAQF,kBAAoBE,IAAQ,UAAYJ,EAAcI,EAAK,CACnE,MAAO,CAAED,QAAS,MAAOG,aAAc,0CAA0CF,KACrF,CAEA,GAAIC,IAAQH,kBAAoBG,IAAQ,UAAYL,EAAcK,EAAK,CACnE,MAAO,CAAEF,QAAS,MAAOG,aAAc,uCAAuCD,KAClF,CAEA,MAAO,CAAEF,QAAS,KACtB,EACH,IAAAI,EAAA,CAAAC,WAAA,MAAAD,EAAAT,uBAAA,OAAAS,CAAA","ignoreList":[],"sourceRoot":"plugins/validators"}},{"offset":{"line":69,"column":0},"map":{"version":3,"names":["UrlValidatorPlugin","validate","parsedValue","args","isValid","url","URL","protocol","errorMessage","e","__exports","__esModule"],"sources":["UrlValidatorPlugin.ts"],"sourcesContent":["/**\n * @file UrlValidatorPlugin.ts\n * @description Standard business logic validator for URL formats.\n */\n\nimport { IValidator, IValidationResult } from \"../../interfaces/IPipeline\";\n\n/**\n * Ensures a string is a valid HTTP/HTTPS URL.\n * \n * @namespace nz.co.siliconst.ui5.metaui.plugins.validators\n * @public\n */\nexport class UrlValidatorPlugin implements IValidator {\n public validate(parsedValue: unknown, args?: unknown): IValidationResult {\n if (!parsedValue as string) return { isValid: true }; // Let RequiredValidator handle empty\n \n try {\n const url = new URL(parsedValue as string);\n if (url.protocol !== \"http:\" && url.protocol !== \"https:\") {\n return { isValid: false, errorMessage: \"URL must use http or https protocol.\" };\n }\n } catch (e) {\n return { isValid: false, errorMessage: \"Please enter a valid URL.\" };\n }\n \n return { isValid: true };\n }\n}\n"],"mappings":"AAAA,gHAaO,MAAMA,EACFC,SAASC,EAAsBC,GAClC,IAAKD,EAAuB,MAAO,CAAEE,QAAS,MAE9C,IACI,MAAMC,EAAM,IAAIC,IAAIJ,GACpB,GAAIG,EAAIE,WAAa,SAAWF,EAAIE,WAAa,SAAU,CACvD,MAAO,CAAEH,QAAS,MAAOI,aAAc,uCAC3C,CACJ,CAAE,MAAOC,GACL,MAAO,CAAEL,QAAS,MAAOI,aAAc,4BAC3C,CAEA,MAAO,CAAEJ,QAAS,KACtB,EACH,IAAAM,EAAA,CAAAC,WAAA,MAAAD,EAAAV,qBAAA,OAAAU,CAAA","ignoreList":[],"sourceRoot":"plugins/validators"}},{"offset":{"line":70,"column":0},"map":{"version":3,"names":["Logger","static","setDebugMode","enabled","this","debugMode","logInstance","sap","ui","require","Log","isDebugMode","debug","message","details","component","console","info","warn","warning","error","showErrorPopup","title","MessageBox","__exports","__esModule"],"sources":["Logger.ts"],"sourcesContent":["/**\n * @file Logger.ts\n * @description Centralized logging utility for MetaUI.\n * Wraps sap/base/Log and provides a global toggle for debug mode.\n */\n\nexport class Logger {\n private static debugMode: boolean = false;\n private static logInstance: unknown = null;\n\n /**\n * Toggles the global debug mode for MetaUI.\n * @param enabled Set to true to enable logging.\n */\n public static setDebugMode(enabled: boolean): void {\n this.debugMode = enabled;\n if (enabled && !this.logInstance) {\n sap.ui.require([\"sap/base/Log\"], (Log: Record<string, Function>) => {\n this.logInstance = Log;\n });\n }\n }\n\n /**\n * Checks if debug mode is currently active.\n */\n public static isDebugMode(): boolean {\n return this.debugMode;\n }\n\n public static debug(message: string, details?: string, component?: string): void {\n if (!this.debugMode) return;\n if (this.logInstance) {\n this.logInstance.debug(message, details, component || \"MetaUI\");\n } else {\n console.debug(`[MetaUI] ${message}`, details || \"\");\n }\n }\n\n public static info(message: string, details?: string, component?: string): void {\n if (!this.debugMode) return;\n if (this.logInstance) {\n this.logInstance.info(message, details, component || \"MetaUI\");\n } else {\n console.info(`[MetaUI] ${message}`, details || \"\");\n }\n }\n\n public static warn(message: string, details?: string, component?: string): void {\n if (!this.debugMode) return;\n if (this.logInstance) {\n this.logInstance.warning(message, details, component || \"MetaUI\");\n } else {\n console.warn(`[MetaUI] ${message}`, details || \"\");\n }\n }\n\n public static error(message: string, details?: string, component?: string): void {\n if (this.logInstance) {\n this.logInstance.error(message, details, component || \"MetaUI\");\n } else {\n console.error(`[MetaUI Error] ${message}`, details || \"\");\n }\n }\n\n /**\n * Pops up a MessageBox UI alert if debug mode is active.\n */\n public static showErrorPopup(message: string, title?: string): void {\n if (!this.debugMode) return;\n sap.ui.require([\"sap/m/MessageBox\"], (MessageBox: Record<string, Function>) => {\n (MessageBox as Record<string, Function>).error(message, { title: title || \"MetaUI Error\" });\n });\n }\n}\n"],"mappings":"AAAA,uFAMO,MAAMA,EACTC,iBAAoC,MACpCA,mBAAsC,KAMtC,mBAAcC,CAAaC,GACvBC,KAAKC,UAAYF,EACjB,GAAIA,IAAYC,KAAKE,YAAa,CAC9BC,IAAIC,GAAGC,QAAQ,CAAC,gBAAkBC,IAC9BN,KAAKE,YAAcI,GAE3B,CACJ,CAKA,kBAAcC,GACV,OAAOP,KAAKC,SAChB,CAEA,YAAcO,CAAMC,EAAiBC,EAAkBC,GACnD,IAAKX,KAAKC,UAAW,OACrB,GAAID,KAAKE,YAAa,CAClBF,KAAKE,YAAYM,MAAMC,EAASC,EAASC,GAAa,SAC1D,KAAO,CACHC,QAAQJ,MAAM,YAAYC,IAAWC,GAAW,GACpD,CACJ,CAEA,WAAcG,CAAKJ,EAAiBC,EAAkBC,GAClD,IAAKX,KAAKC,UAAW,OACrB,GAAID,KAAKE,YAAa,CAClBF,KAAKE,YAAYW,KAAKJ,EAASC,EAASC,GAAa,SACzD,KAAO,CACHC,QAAQC,KAAK,YAAYJ,IAAWC,GAAW,GACnD,CACJ,CAEA,WAAcI,CAAKL,EAAiBC,EAAkBC,GAClD,IAAKX,KAAKC,UAAW,OACrB,GAAID,KAAKE,YAAa,CAClBF,KAAKE,YAAYa,QAAQN,EAASC,EAASC,GAAa,SAC5D,KAAO,CACHC,QAAQE,KAAK,YAAYL,IAAWC,GAAW,GACnD,CACJ,CAEA,YAAcM,CAAMP,EAAiBC,EAAkBC,GACnD,GAAIX,KAAKE,YAAa,CAClBF,KAAKE,YAAYc,MAAMP,EAASC,EAASC,GAAa,SAC1D,KAAO,CACHC,QAAQI,MAAM,kBAAkBP,IAAWC,GAAW,GAC1D,CACJ,CAKA,qBAAcO,CAAeR,EAAiBS,GAC1C,IAAKlB,KAAKC,UAAW,OACrBE,IAAIC,GAAGC,QAAQ,CAAC,oBAAsBc,IACjCA,EAAwCH,MAAMP,EAAS,CAAES,MAAOA,GAAS,kBAElF,EACH,IAAAE,EAAA,CAAAC,WAAA,MAAAD,EAAAxB,SAAA,OAAAwB,CAAA","ignoreList":[],"sourceRoot":"utils"}},{"offset":{"line":71,"column":0},"map":{"version":3,"names":[],"sources":["library-preload.js?bundle-code-0"],"mappings":"AAAA;AACA","sourcesContent":["sap.ui.require.preload({\n"],"sourceRoot":""}},{"offset":{"line":73,"column":0},"map":{"version":3,"file":"ILayoutManager.js","names":[],"sources":[],"mappings":"AAAA","ignoreList":[],"sourceRoot":"interfaces"}},{"offset":{"line":76,"column":0},"map":{"version":3,"file":"IPipeline.js","names":[],"sources":[],"mappings":"AAAA","ignoreList":[],"sourceRoot":"interfaces"}},{"offset":{"line":79,"column":0},"map":{"version":3,"file":"IPlugin.js","names":[],"sources":[],"mappings":"AAAA","ignoreList":[],"sourceRoot":"interfaces"}},{"offset":{"line":82,"column":0},"map":{"version":3,"file":"ISchema.js","names":[],"sources":[],"mappings":"AAAA","ignoreList":[],"sourceRoot":"interfaces"}}]}
|