@wavemaker/app-ng-runtime 11.10.5-rc.6100 → 11.11.0-next.27920
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/build-task/bundles/index.umd.js +94 -68
- package/build-task/esm2022/advanced/carousel/carousel-template/carousel-template.build.mjs +8 -8
- package/build-task/esm2022/containers/repeat-template.build.mjs +5 -5
- package/build-task/esm2022/containers/wizard/wizard-step/wizard-step.build.mjs +2 -2
- package/build-task/esm2022/containers/wizard/wizard.build.mjs +33 -4
- package/build-task/esm2022/data/form/form-field/form-field.build.mjs +10 -10
- package/build-task/esm2022/data/table/table-column/table-column.build.mjs +15 -11
- package/build-task/esm2022/page/page.build.mjs +2 -8
- package/build-task/esm2022/public_api.mjs +1 -1
- package/build-task/fesm2022/index.mjs +95 -69
- package/build-task/fesm2022/index.mjs.map +1 -1
- package/components/advanced/carousel/bundles/index.umd.js +8 -36
- package/components/advanced/carousel/carousel-template/carousel-template.directive.d.ts +1 -1
- package/components/advanced/carousel/carousel.directive.d.ts +1 -1
- package/components/advanced/carousel/esm2022/carousel-template/carousel-template.directive.mjs +3 -2
- package/components/advanced/carousel/esm2022/carousel.directive.mjs +3 -2
- package/components/advanced/carousel/esm2022/public_api.mjs +1 -2
- package/components/advanced/carousel/fesm2022/index.mjs +8 -36
- package/components/advanced/carousel/fesm2022/index.mjs.map +1 -1
- package/components/advanced/carousel/public_api.d.ts +0 -1
- package/components/advanced/custom/bundles/index.umd.js +8 -33
- package/components/advanced/custom/custom-widget-container/custom-widget-container.directive.d.ts +1 -1
- package/components/advanced/custom/custom-widget.directive.d.ts +1 -1
- package/components/advanced/custom/esm2022/custom-widget-container/custom-widget-container.directive.mjs +3 -2
- package/components/advanced/custom/esm2022/custom-widget.directive.mjs +3 -2
- package/components/advanced/custom/esm2022/public_api.mjs +1 -2
- package/components/advanced/custom/fesm2022/index.mjs +7 -32
- package/components/advanced/custom/fesm2022/index.mjs.map +1 -1
- package/components/advanced/custom/public_api.d.ts +0 -1
- package/components/advanced/login/bundles/index.umd.js +10 -34
- package/components/advanced/login/esm2022/login.component.mjs +7 -6
- package/components/advanced/login/esm2022/public_api.mjs +1 -2
- package/components/advanced/login/fesm2022/index.mjs +8 -32
- package/components/advanced/login/fesm2022/index.mjs.map +1 -1
- package/components/advanced/login/login.component.d.ts +1 -1
- package/components/advanced/login/public_api.d.ts +0 -1
- package/components/advanced/marquee/bundles/index.umd.js +6 -29
- package/components/advanced/marquee/esm2022/marquee.directive.mjs +3 -2
- package/components/advanced/marquee/esm2022/public_api.mjs +1 -2
- package/components/advanced/marquee/fesm2022/index.mjs +5 -28
- package/components/advanced/marquee/fesm2022/index.mjs.map +1 -1
- package/components/advanced/marquee/marquee.directive.d.ts +1 -1
- package/components/advanced/marquee/public_api.d.ts +0 -1
- package/components/base/bundles/index.umd.js +76 -274
- package/components/base/components.module.d.ts +13 -15
- package/components/base/directives/show-in-device.directive.d.ts +1 -1
- package/components/base/esm2022/components.module.mjs +7 -13
- package/components/base/esm2022/directives/show-in-device.directive.mjs +3 -2
- package/components/base/esm2022/pipes/custom-pipes.mjs +32 -16
- package/components/base/esm2022/pipes/image.pipe.mjs +3 -2
- package/components/base/esm2022/pipes/sanitize.pipe.mjs +3 -2
- package/components/base/esm2022/pipes/trust-as.pipe.mjs +3 -2
- package/components/base/esm2022/public_api.mjs +1 -2
- package/components/base/esm2022/utils/form-utils.mjs +2 -1
- package/components/base/esm2022/utils/live-utils.mjs +3 -7
- package/components/base/esm2022/widgets/common/base/base.component.mjs +3 -5
- package/components/base/esm2022/widgets/common/base/custom-widget-container.directive.mjs +3 -2
- package/components/base/esm2022/widgets/common/base/partial-container.directive.mjs +3 -2
- package/components/base/esm2022/widgets/common/base/text-content.directive.mjs +3 -2
- package/components/base/esm2022/widgets/common/container/container.directive.mjs +3 -2
- package/components/base/esm2022/widgets/common/dialog/dialog.service.mjs +3 -3
- package/components/base/esm2022/widgets/common/item-template/item-template.directive.mjs +3 -2
- package/components/base/esm2022/widgets/common/lazy-load/lazy-load.directive.mjs +3 -2
- package/components/base/esm2022/widgets/common/message/message.component.mjs +5 -5
- package/components/base/esm2022/widgets/common/partial/partial.directive.mjs +3 -2
- package/components/base/esm2022/widgets/common/partial-param/partial-param.directive.mjs +5 -3
- package/components/base/esm2022/widgets/common/redraw/redrawable.directive.mjs +3 -2
- package/components/base/esm2022/widgets/common/repeat-template/repeat-template.directive.mjs +3 -2
- package/components/base/fesm2022/index.mjs +76 -272
- package/components/base/fesm2022/index.mjs.map +1 -1
- package/components/base/pipes/custom-pipes.d.ts +16 -16
- package/components/base/pipes/image.pipe.d.ts +1 -1
- package/components/base/pipes/sanitize.pipe.d.ts +1 -1
- package/components/base/pipes/trust-as.pipe.d.ts +1 -1
- package/components/base/public_api.d.ts +0 -1
- package/components/base/widgets/common/base/custom-widget-container.directive.d.ts +1 -1
- package/components/base/widgets/common/base/partial-container.directive.d.ts +1 -1
- package/components/base/widgets/common/base/text-content.directive.d.ts +1 -1
- package/components/base/widgets/common/container/container.directive.d.ts +1 -1
- package/components/base/widgets/common/item-template/item-template.directive.d.ts +1 -1
- package/components/base/widgets/common/lazy-load/lazy-load.directive.d.ts +1 -1
- package/components/base/widgets/common/message/message.component.d.ts +1 -1
- package/components/base/widgets/common/partial/partial.directive.d.ts +1 -1
- package/components/base/widgets/common/partial-param/partial-param.directive.d.ts +2 -2
- package/components/base/widgets/common/redraw/redrawable.directive.d.ts +1 -1
- package/components/base/widgets/common/repeat-template/repeat-template.directive.d.ts +1 -1
- package/components/basic/default/anchor/anchor.component.d.ts +1 -1
- package/components/basic/default/audio/audio.component.d.ts +1 -1
- package/components/basic/default/bundles/index.umd.js +100 -148
- package/components/basic/default/esm2022/anchor/anchor.component.mjs +23 -21
- package/components/basic/default/esm2022/audio/audio.component.mjs +7 -6
- package/components/basic/default/esm2022/html/html.directive.mjs +3 -2
- package/components/basic/default/esm2022/icon/icon.component.mjs +17 -16
- package/components/basic/default/esm2022/iframe/iframe.component.mjs +14 -13
- package/components/basic/default/esm2022/label/label.directive.mjs +3 -2
- package/components/basic/default/esm2022/picture/picture.directive.mjs +3 -2
- package/components/basic/default/esm2022/picture/picture.props.mjs +1 -5
- package/components/basic/default/esm2022/public_api.mjs +1 -2
- package/components/basic/default/esm2022/spinner/spinner.component.mjs +26 -24
- package/components/basic/default/esm2022/video/video.component.mjs +19 -18
- package/components/basic/default/fesm2022/index.mjs +101 -148
- package/components/basic/default/fesm2022/index.mjs.map +1 -1
- package/components/basic/default/html/html.directive.d.ts +1 -1
- package/components/basic/default/icon/icon.component.d.ts +1 -1
- package/components/basic/default/iframe/iframe.component.d.ts +1 -1
- package/components/basic/default/label/label.directive.d.ts +1 -1
- package/components/basic/default/picture/picture.directive.d.ts +1 -1
- package/components/basic/default/public_api.d.ts +0 -1
- package/components/basic/default/spinner/spinner.component.d.ts +1 -1
- package/components/basic/default/video/video.component.d.ts +1 -1
- package/components/basic/progress/bundles/index.umd.js +20 -51
- package/components/basic/progress/esm2022/progress-bar/progress-bar.component.mjs +12 -11
- package/components/basic/progress/esm2022/progress-circle/progress-circle.component.mjs +8 -6
- package/components/basic/progress/esm2022/public_api.mjs +1 -2
- package/components/basic/progress/fesm2022/index.mjs +19 -49
- package/components/basic/progress/fesm2022/index.mjs.map +1 -1
- package/components/basic/progress/progress-bar/progress-bar.component.d.ts +1 -1
- package/components/basic/progress/progress-circle/progress-circle.component.d.ts +1 -1
- package/components/basic/progress/public_api.d.ts +0 -1
- package/components/basic/rich-text-editor/bundles/index.umd.js +15 -40
- package/components/basic/rich-text-editor/esm2022/public_api.mjs +1 -2
- package/components/basic/rich-text-editor/esm2022/rich-text-editor.component.mjs +13 -12
- package/components/basic/rich-text-editor/fesm2022/index.mjs +13 -37
- package/components/basic/rich-text-editor/fesm2022/index.mjs.map +1 -1
- package/components/basic/rich-text-editor/public_api.d.ts +0 -1
- package/components/basic/rich-text-editor/rich-text-editor.component.d.ts +1 -1
- package/components/basic/search/bundles/index.umd.js +170 -207
- package/components/basic/search/esm2022/public_api.mjs +1 -2
- package/components/basic/search/esm2022/scrollable.directive.mjs +3 -2
- package/components/basic/search/esm2022/search.component.mjs +76 -72
- package/components/basic/search/fesm2022/index.mjs +107 -143
- package/components/basic/search/fesm2022/index.mjs.map +1 -1
- package/components/basic/search/public_api.d.ts +0 -1
- package/components/basic/search/scrollable.directive.d.ts +1 -1
- package/components/basic/search/search.component.d.ts +1 -1
- package/components/basic/tree/bundles/index.umd.js +9 -33
- package/components/basic/tree/esm2022/public_api.mjs +1 -2
- package/components/basic/tree/esm2022/tree.component.mjs +7 -6
- package/components/basic/tree/fesm2022/index.mjs +8 -32
- package/components/basic/tree/fesm2022/index.mjs.map +1 -1
- package/components/basic/tree/public_api.d.ts +0 -1
- package/components/basic/tree/tree.component.d.ts +1 -1
- package/components/chart/bundles/index.umd.js +25 -53
- package/components/chart/chart.component.d.ts +1 -1
- package/components/chart/esm2022/chart.component.mjs +26 -24
- package/components/chart/esm2022/chart.utils.mjs +2 -1
- package/components/chart/esm2022/public_api.mjs +1 -2
- package/components/chart/fesm2022/index.mjs +26 -52
- package/components/chart/fesm2022/index.mjs.map +1 -1
- package/components/chart/public_api.d.ts +0 -1
- package/components/containers/accordion/accordion-pane/accordion-pane.component.d.ts +1 -1
- package/components/containers/accordion/accordion.directive.d.ts +1 -1
- package/components/containers/accordion/bundles/index.umd.js +208 -237
- package/components/containers/accordion/esm2022/accordion-pane/accordion-pane.component.mjs +10 -11
- package/components/containers/accordion/esm2022/accordion.directive.mjs +5 -4
- package/components/containers/accordion/esm2022/public_api.mjs +1 -2
- package/components/containers/accordion/fesm2022/index.mjs +189 -217
- package/components/containers/accordion/fesm2022/index.mjs.map +1 -1
- package/components/containers/accordion/public_api.d.ts +0 -1
- package/components/containers/layout-grid/bundles/index.umd.js +13 -43
- package/components/containers/layout-grid/esm2022/layout-grid-column/layout-grid-column.directive.mjs +7 -9
- package/components/containers/layout-grid/esm2022/layout-grid-row/layout-grid-row.directive.mjs +3 -2
- package/components/containers/layout-grid/esm2022/layout-grid.directive.mjs +3 -2
- package/components/containers/layout-grid/esm2022/public_api.mjs +1 -2
- package/components/containers/layout-grid/fesm2022/index.mjs +13 -43
- package/components/containers/layout-grid/fesm2022/index.mjs.map +1 -1
- package/components/containers/layout-grid/layout-grid-column/layout-grid-column.directive.d.ts +1 -1
- package/components/containers/layout-grid/layout-grid-row/layout-grid-row.directive.d.ts +1 -1
- package/components/containers/layout-grid/layout-grid.directive.d.ts +1 -1
- package/components/containers/layout-grid/public_api.d.ts +0 -1
- package/components/containers/linear-layout/bundles/index.umd.js +8 -33
- package/components/containers/linear-layout/esm2022/linear-layout-item/linear-layout-item.directive.mjs +3 -2
- package/components/containers/linear-layout/esm2022/linear-layout.directive.mjs +3 -2
- package/components/containers/linear-layout/esm2022/public_api.mjs +1 -2
- package/components/containers/linear-layout/fesm2022/index.mjs +7 -32
- package/components/containers/linear-layout/fesm2022/index.mjs.map +1 -1
- package/components/containers/linear-layout/linear-layout-item/linear-layout-item.directive.d.ts +1 -1
- package/components/containers/linear-layout/linear-layout.directive.d.ts +1 -1
- package/components/containers/linear-layout/public_api.d.ts +0 -1
- package/components/containers/panel/bundles/index.umd.js +87 -118
- package/components/containers/panel/esm2022/panel.component.mjs +48 -46
- package/components/containers/panel/esm2022/public_api.mjs +1 -2
- package/components/containers/panel/fesm2022/index.mjs +49 -79
- package/components/containers/panel/fesm2022/index.mjs.map +1 -1
- package/components/containers/panel/panel.component.d.ts +1 -1
- package/components/containers/panel/public_api.d.ts +0 -1
- package/components/containers/tabs/bundles/index.umd.js +84 -116
- package/components/containers/tabs/esm2022/public_api.mjs +1 -2
- package/components/containers/tabs/esm2022/tab-pane/tab-pane.component.mjs +8 -10
- package/components/containers/tabs/esm2022/tabs.component.mjs +35 -33
- package/components/containers/tabs/esm2022/tabs.props.mjs +1 -5
- package/components/containers/tabs/fesm2022/index.mjs +45 -76
- package/components/containers/tabs/fesm2022/index.mjs.map +1 -1
- package/components/containers/tabs/public_api.d.ts +0 -1
- package/components/containers/tabs/tab-pane/tab-pane.component.d.ts +1 -1
- package/components/containers/tabs/tabs.component.d.ts +1 -1
- package/components/containers/tile/bundles/index.umd.js +6 -29
- package/components/containers/tile/esm2022/public_api.mjs +1 -2
- package/components/containers/tile/esm2022/tile.directive.mjs +3 -2
- package/components/containers/tile/fesm2022/index.mjs +5 -28
- package/components/containers/tile/fesm2022/index.mjs.map +1 -1
- package/components/containers/tile/public_api.d.ts +0 -1
- package/components/containers/tile/tile.directive.d.ts +1 -1
- package/components/containers/wizard/bundles/index.umd.js +355 -186
- package/components/containers/wizard/esm2022/public_api.mjs +2 -3
- package/components/containers/wizard/esm2022/wizard-action/wizard-action.directive.mjs +3 -2
- package/components/containers/wizard/esm2022/wizard-step/wizard-step.component.mjs +176 -0
- package/components/containers/wizard/esm2022/wizard-step/wizard-step.props.mjs +8 -5
- package/components/containers/wizard/esm2022/wizard.component.mjs +264 -102
- package/components/containers/wizard/esm2022/wizard.props.mjs +8 -4
- package/components/containers/wizard/fesm2022/index.mjs +323 -152
- package/components/containers/wizard/fesm2022/index.mjs.map +1 -1
- package/components/containers/wizard/public_api.d.ts +1 -2
- package/components/containers/wizard/wizard-action/wizard-action.directive.d.ts +1 -1
- package/components/containers/wizard/wizard-step/{wizard-step.directive.d.ts → wizard-step.component.d.ts} +12 -6
- package/components/containers/wizard/wizard.component.d.ts +64 -18
- package/components/data/card/bundles/index.umd.js +92 -135
- package/components/data/card/card-actions/card-actions.directive.d.ts +1 -1
- package/components/data/card/card-content/card-content.component.d.ts +1 -1
- package/components/data/card/card-footer/card-footer.directive.d.ts +1 -1
- package/components/data/card/card.component.d.ts +1 -1
- package/components/data/card/esm2022/card-actions/card-actions.directive.mjs +3 -2
- package/components/data/card/esm2022/card-content/card-content.component.mjs +7 -6
- package/components/data/card/esm2022/card-footer/card-footer.directive.mjs +3 -2
- package/components/data/card/esm2022/card.component.mjs +39 -38
- package/components/data/card/esm2022/public_api.mjs +1 -2
- package/components/data/card/fesm2022/index.mjs +49 -92
- package/components/data/card/fesm2022/index.mjs.map +1 -1
- package/components/data/card/public_api.d.ts +0 -1
- package/components/data/form/bundles/index.umd.js +115 -182
- package/components/data/form/esm2022/form-action/form-action.directive.mjs +3 -2
- package/components/data/form/esm2022/form-field/form-field.directive.mjs +3 -2
- package/components/data/form/esm2022/form-widget.directive.mjs +3 -2
- package/components/data/form/esm2022/form.component.mjs +101 -104
- package/components/data/form/esm2022/form.props.mjs +1 -11
- package/components/data/form/esm2022/live-actions/dependson.directive.mjs +3 -2
- package/components/data/form/esm2022/live-actions/live-actions.directive.mjs +3 -2
- package/components/data/form/esm2022/live-filter/live-filter.directive.mjs +3 -2
- package/components/data/form/esm2022/live-form/live-form.directive.mjs +3 -6
- package/components/data/form/esm2022/public_api.mjs +1 -2
- package/components/data/form/fesm2022/index.mjs +117 -184
- package/components/data/form/fesm2022/index.mjs.map +1 -1
- package/components/data/form/form-action/form-action.directive.d.ts +1 -1
- package/components/data/form/form-field/form-field.directive.d.ts +1 -1
- package/components/data/form/form-widget.directive.d.ts +1 -1
- package/components/data/form/form.component.d.ts +1 -1
- package/components/data/form/live-actions/dependson.directive.d.ts +1 -1
- package/components/data/form/live-actions/live-actions.directive.d.ts +1 -1
- package/components/data/form/live-filter/live-filter.directive.d.ts +1 -1
- package/components/data/form/live-form/live-form.directive.d.ts +1 -1
- package/components/data/form/public_api.d.ts +0 -1
- package/components/data/list/bundles/index.umd.js +195 -504
- package/components/data/list/esm2022/list-item.directive.mjs +4 -3
- package/components/data/list/esm2022/list.component.mjs +187 -232
- package/components/data/list/esm2022/list.props.mjs +2 -3
- package/components/data/list/esm2022/public_api.mjs +1 -2
- package/components/data/list/fesm2022/index.mjs +193 -502
- package/components/data/list/fesm2022/index.mjs.map +1 -1
- package/components/data/list/list-item.directive.d.ts +1 -1
- package/components/data/list/list.component.d.ts +1 -1
- package/components/data/list/public_api.d.ts +0 -1
- package/components/data/live-table/bundles/index.umd.js +9 -33
- package/components/data/live-table/esm2022/live-table.component.mjs +7 -6
- package/components/data/live-table/esm2022/public_api.mjs +1 -2
- package/components/data/live-table/fesm2022/index.mjs +8 -32
- package/components/data/live-table/fesm2022/index.mjs.map +1 -1
- package/components/data/live-table/live-table.component.d.ts +1 -1
- package/components/data/live-table/public_api.d.ts +0 -1
- package/components/data/pagination/bundles/index.umd.js +80 -110
- package/components/data/pagination/esm2022/pagination.component.mjs +80 -76
- package/components/data/pagination/esm2022/public_api.mjs +1 -2
- package/components/data/pagination/fesm2022/index.mjs +81 -110
- package/components/data/pagination/fesm2022/index.mjs.map +1 -1
- package/components/data/pagination/pagination.component.d.ts +1 -1
- package/components/data/pagination/public_api.d.ts +0 -1
- package/components/data/table/bundles/index.umd.js +66 -135
- package/components/data/table/esm2022/public_api.mjs +1 -2
- package/components/data/table/esm2022/table-action/table-action.directive.mjs +3 -2
- package/components/data/table/esm2022/table-column/table-column.directive.mjs +3 -2
- package/components/data/table/esm2022/table-column-group/table-column-group.directive.mjs +3 -2
- package/components/data/table/esm2022/table-cud.directive.mjs +3 -2
- package/components/data/table/esm2022/table-filter.directive.mjs +4 -2
- package/components/data/table/esm2022/table-row/table-row.directive.mjs +3 -2
- package/components/data/table/esm2022/table-row-action/table-row-action.directive.mjs +3 -2
- package/components/data/table/esm2022/table.component.mjs +50 -49
- package/components/data/table/fesm2022/index.mjs +70 -140
- package/components/data/table/fesm2022/index.mjs.map +1 -1
- package/components/data/table/public_api.d.ts +0 -1
- package/components/data/table/table-action/table-action.directive.d.ts +1 -1
- package/components/data/table/table-column/table-column.directive.d.ts +1 -1
- package/components/data/table/table-column-group/table-column-group.directive.d.ts +1 -1
- package/components/data/table/table-cud.directive.d.ts +1 -1
- package/components/data/table/table-filter.directive.d.ts +1 -1
- package/components/data/table/table-row/table-row.directive.d.ts +1 -1
- package/components/data/table/table-row-action/table-row-action.directive.d.ts +1 -1
- package/components/data/table/table.component.d.ts +1 -1
- package/components/dialogs/alert-dialog/alert-dialog.component.d.ts +1 -1
- package/components/dialogs/alert-dialog/bundles/index.umd.js +32 -64
- package/components/dialogs/alert-dialog/esm2022/alert-dialog.component.mjs +10 -10
- package/components/dialogs/alert-dialog/esm2022/public_api.mjs +1 -2
- package/components/dialogs/alert-dialog/fesm2022/index.mjs +11 -43
- package/components/dialogs/alert-dialog/fesm2022/index.mjs.map +1 -1
- package/components/dialogs/alert-dialog/public_api.d.ts +0 -1
- package/components/dialogs/confirm-dialog/bundles/index.umd.js +10 -42
- package/components/dialogs/confirm-dialog/confirm-dialog.component.d.ts +1 -1
- package/components/dialogs/confirm-dialog/esm2022/confirm-dialog.component.mjs +9 -9
- package/components/dialogs/confirm-dialog/esm2022/public_api.mjs +1 -2
- package/components/dialogs/confirm-dialog/fesm2022/index.mjs +10 -42
- package/components/dialogs/confirm-dialog/fesm2022/index.mjs.map +1 -1
- package/components/dialogs/confirm-dialog/public_api.d.ts +0 -1
- package/components/dialogs/default/bundles/index.umd.js +76 -136
- package/components/dialogs/default/dialog-body/dialog-body.directive.d.ts +1 -1
- package/components/dialogs/default/dialog-footer/dialog-footer.directive.d.ts +1 -1
- package/components/dialogs/default/dialog-header/dialog-header.component.d.ts +1 -1
- package/components/dialogs/default/esm2022/base-dialog.mjs +3 -3
- package/components/dialogs/default/esm2022/dialog-body/dialog-body.directive.mjs +3 -2
- package/components/dialogs/default/esm2022/dialog-footer/dialog-footer.directive.mjs +3 -2
- package/components/dialogs/default/esm2022/dialog-header/dialog-header.component.mjs +70 -97
- package/components/dialogs/default/esm2022/public_api.mjs +1 -2
- package/components/dialogs/default/fesm2022/index.mjs +78 -137
- package/components/dialogs/default/fesm2022/index.mjs.map +1 -1
- package/components/dialogs/default/public_api.d.ts +0 -1
- package/components/dialogs/design-dialog/bundles/index.umd.js +16 -47
- package/components/dialogs/design-dialog/dialog.component.d.ts +1 -1
- package/components/dialogs/design-dialog/esm2022/dialog.component.mjs +14 -13
- package/components/dialogs/design-dialog/esm2022/public_api.mjs +1 -2
- package/components/dialogs/design-dialog/fesm2022/index.mjs +14 -45
- package/components/dialogs/design-dialog/fesm2022/index.mjs.map +1 -1
- package/components/dialogs/design-dialog/public_api.d.ts +0 -1
- package/components/dialogs/iframe-dialog/bundles/index.umd.js +20 -57
- package/components/dialogs/iframe-dialog/esm2022/iframe-dialog.component.mjs +21 -21
- package/components/dialogs/iframe-dialog/esm2022/public_api.mjs +1 -2
- package/components/dialogs/iframe-dialog/fesm2022/index.mjs +21 -57
- package/components/dialogs/iframe-dialog/fesm2022/index.mjs.map +1 -1
- package/components/dialogs/iframe-dialog/iframe-dialog.component.d.ts +1 -1
- package/components/dialogs/iframe-dialog/public_api.d.ts +0 -1
- package/components/dialogs/login-dialog/bundles/index.umd.js +6 -38
- package/components/dialogs/login-dialog/esm2022/login-dialog.directive.mjs +3 -2
- package/components/dialogs/login-dialog/esm2022/public_api.mjs +1 -2
- package/components/dialogs/login-dialog/fesm2022/index.mjs +6 -41
- package/components/dialogs/login-dialog/fesm2022/index.mjs.map +1 -1
- package/components/dialogs/login-dialog/login-dialog.directive.d.ts +1 -1
- package/components/dialogs/login-dialog/public_api.d.ts +0 -1
- package/components/dialogs/partial-dialog/bundles/index.umd.js +17 -49
- package/components/dialogs/partial-dialog/esm2022/partial-dialog.component.mjs +16 -15
- package/components/dialogs/partial-dialog/esm2022/public_api.mjs +1 -2
- package/components/dialogs/partial-dialog/fesm2022/index.mjs +16 -47
- package/components/dialogs/partial-dialog/fesm2022/index.mjs.map +1 -1
- package/components/dialogs/partial-dialog/partial-dialog.component.d.ts +1 -1
- package/components/dialogs/partial-dialog/public_api.d.ts +0 -1
- package/components/input/calendar/bundles/index.umd.js +19 -46
- package/components/input/calendar/calendar.component.d.ts +1 -1
- package/components/input/calendar/esm2022/calendar.component.mjs +24 -10
- package/components/input/calendar/esm2022/calendar.props.mjs +1 -1
- package/components/input/calendar/esm2022/public_api.mjs +1 -2
- package/components/input/calendar/fesm2022/index.mjs +26 -48
- package/components/input/calendar/fesm2022/index.mjs.map +1 -1
- package/components/input/calendar/public_api.d.ts +0 -1
- package/components/input/chips/bundles/index.umd.js +86 -114
- package/components/input/chips/chips.component.d.ts +1 -1
- package/components/input/chips/esm2022/chips.component.mjs +28 -27
- package/components/input/chips/esm2022/public_api.mjs +1 -2
- package/components/input/chips/fesm2022/index.mjs +29 -56
- package/components/input/chips/fesm2022/index.mjs.map +1 -1
- package/components/input/chips/public_api.d.ts +0 -1
- package/components/input/color-picker/bundles/index.umd.js +10 -40
- package/components/input/color-picker/color-picker.component.d.ts +1 -1
- package/components/input/color-picker/esm2022/color-picker.component.mjs +10 -6
- package/components/input/color-picker/esm2022/public_api.mjs +1 -2
- package/components/input/color-picker/fesm2022/index.mjs +11 -40
- package/components/input/color-picker/fesm2022/index.mjs.map +1 -1
- package/components/input/color-picker/public_api.d.ts +0 -1
- package/components/input/currency/bundles/index.umd.js +11 -41
- package/components/input/currency/currency.component.d.ts +1 -1
- package/components/input/currency/esm2022/currency.component.mjs +8 -6
- package/components/input/currency/esm2022/public_api.mjs +1 -2
- package/components/input/currency/fesm2022/index.mjs +11 -41
- package/components/input/currency/fesm2022/index.mjs.map +1 -1
- package/components/input/currency/public_api.d.ts +0 -1
- package/components/input/default/bundles/index.umd.js +2183 -2263
- package/components/input/default/button/button.component.d.ts +1 -1
- package/components/input/default/button-group/button-group.directive.d.ts +1 -1
- package/components/input/default/caption-position.directive.d.ts +1 -1
- package/components/input/default/checkbox/checkbox.component.d.ts +1 -1
- package/components/input/default/checkboxset/checkboxset.component.d.ts +1 -1
- package/components/input/default/composite/composite.directive.d.ts +1 -1
- package/components/input/default/esm2022/button/button.component.mjs +23 -21
- package/components/input/default/esm2022/button-group/button-group.directive.mjs +3 -2
- package/components/input/default/esm2022/caption-position.directive.mjs +3 -2
- package/components/input/default/esm2022/checkbox/checkbox.component.mjs +9 -6
- package/components/input/default/esm2022/checkboxset/checkboxset.component.mjs +73 -72
- package/components/input/default/esm2022/composite/composite.directive.mjs +3 -2
- package/components/input/default/esm2022/number/number.component.mjs +9 -6
- package/components/input/default/esm2022/public_api.mjs +1 -2
- package/components/input/default/esm2022/radioset/radioset.component.mjs +73 -72
- package/components/input/default/esm2022/select/select.component.mjs +29 -32
- package/components/input/default/esm2022/switch/switch.component.mjs +29 -27
- package/components/input/default/esm2022/text/calendar/input-calendar.component.mjs +9 -6
- package/components/input/default/esm2022/text/color/input-color.component.mjs +9 -6
- package/components/input/default/esm2022/text/email/input-email.component.mjs +9 -6
- package/components/input/default/esm2022/text/number/input-number.component.mjs +9 -6
- package/components/input/default/esm2022/text/text/input-text.component.mjs +10 -6
- package/components/input/default/esm2022/textarea/textarea.component.mjs +14 -11
- package/components/input/default/fesm2022/index.mjs +2198 -2277
- package/components/input/default/fesm2022/index.mjs.map +1 -1
- package/components/input/default/number/number.component.d.ts +1 -1
- package/components/input/default/public_api.d.ts +0 -1
- package/components/input/default/radioset/radioset.component.d.ts +1 -1
- package/components/input/default/select/select.component.d.ts +1 -1
- package/components/input/default/switch/switch.component.d.ts +1 -1
- package/components/input/default/text/calendar/input-calendar.component.d.ts +1 -1
- package/components/input/default/text/color/input-color.component.d.ts +1 -1
- package/components/input/default/text/email/input-email.component.d.ts +1 -1
- package/components/input/default/text/number/input-number.component.d.ts +1 -1
- package/components/input/default/text/text/input-text.component.d.ts +1 -1
- package/components/input/default/textarea/textarea.component.d.ts +1 -1
- package/components/input/epoch/base-date-time.component.d.ts +0 -1
- package/components/input/epoch/bundles/index.umd.js +181 -229
- package/components/input/epoch/date/date.component.d.ts +1 -1
- package/components/input/epoch/date/imaskUtil.d.ts +2 -2
- package/components/input/epoch/date-time/date-time-picker.component.d.ts +6 -6
- package/components/input/epoch/date-time/date-time.component.d.ts +1 -1
- package/components/input/epoch/esm2022/base-date-time.component.mjs +5 -9
- package/components/input/epoch/esm2022/date/date.component.mjs +19 -18
- package/components/input/epoch/esm2022/date/imaskUtil.mjs +2 -1
- package/components/input/epoch/esm2022/date-time/date-time-picker.component.mjs +75 -62
- package/components/input/epoch/esm2022/date-time/date-time.component.mjs +27 -24
- package/components/input/epoch/esm2022/picker/picker.component.mjs +33 -28
- package/components/input/epoch/esm2022/public_api.mjs +1 -2
- package/components/input/epoch/esm2022/time/time.component.mjs +24 -21
- package/components/input/epoch/fesm2022/index.mjs +158 -204
- package/components/input/epoch/fesm2022/index.mjs.map +1 -1
- package/components/input/epoch/picker/picker.component.d.ts +2 -2
- package/components/input/epoch/public_api.d.ts +0 -1
- package/components/input/epoch/time/time.component.d.ts +1 -1
- package/components/input/file-upload/bundles/index.umd.js +135 -178
- package/components/input/file-upload/esm2022/file-upload.component.mjs +133 -150
- package/components/input/file-upload/esm2022/public_api.mjs +1 -2
- package/components/input/file-upload/fesm2022/index.mjs +133 -175
- package/components/input/file-upload/fesm2022/index.mjs.map +1 -1
- package/components/input/file-upload/file-upload.component.d.ts +1 -2
- package/components/input/file-upload/public_api.d.ts +0 -1
- package/components/input/rating/bundles/index.umd.js +50 -77
- package/components/input/rating/esm2022/public_api.mjs +1 -2
- package/components/input/rating/esm2022/rating.component.mjs +23 -20
- package/components/input/rating/fesm2022/index.mjs +23 -49
- package/components/input/rating/fesm2022/index.mjs.map +1 -1
- package/components/input/rating/public_api.d.ts +0 -1
- package/components/input/rating/rating.component.d.ts +1 -1
- package/components/input/slider/bundles/index.umd.js +35 -63
- package/components/input/slider/esm2022/public_api.mjs +1 -2
- package/components/input/slider/esm2022/slider.component.mjs +15 -13
- package/components/input/slider/fesm2022/index.mjs +15 -42
- package/components/input/slider/fesm2022/index.mjs.map +1 -1
- package/components/input/slider/public_api.d.ts +0 -1
- package/components/input/slider/slider.component.d.ts +1 -1
- package/components/navigation/breadcrumb/breadcrumb.component.d.ts +1 -1
- package/components/navigation/breadcrumb/bundles/index.umd.js +40 -67
- package/components/navigation/breadcrumb/esm2022/breadcrumb.component.mjs +23 -21
- package/components/navigation/breadcrumb/esm2022/public_api.mjs +1 -2
- package/components/navigation/breadcrumb/fesm2022/index.mjs +23 -50
- package/components/navigation/breadcrumb/fesm2022/index.mjs.map +1 -1
- package/components/navigation/breadcrumb/public_api.d.ts +0 -1
- package/components/navigation/menu/bundles/index.umd.js +642 -696
- package/components/navigation/menu/esm2022/menu-adapator.component.mjs +1 -1
- package/components/navigation/menu/esm2022/menu-dropdown/menu-dropdown.component.mjs +11 -9
- package/components/navigation/menu/esm2022/menu-dropdown-item/menu-dropdown-item.component.mjs +24 -18
- package/components/navigation/menu/esm2022/menu.component.mjs +34 -31
- package/components/navigation/menu/esm2022/nav/nav-item/nav-item.directive.mjs +3 -2
- package/components/navigation/menu/esm2022/nav/nav.component.mjs +39 -29
- package/components/navigation/menu/esm2022/nav/navigation-control.directive.mjs +6 -3
- package/components/navigation/menu/esm2022/public_api.mjs +1 -2
- package/components/navigation/menu/fesm2022/index.mjs +534 -587
- package/components/navigation/menu/fesm2022/index.mjs.map +1 -1
- package/components/navigation/menu/menu-dropdown/menu-dropdown.component.d.ts +1 -1
- package/components/navigation/menu/menu-dropdown-item/menu-dropdown-item.component.d.ts +1 -1
- package/components/navigation/menu/menu.component.d.ts +1 -1
- package/components/navigation/menu/nav/nav-item/nav-item.directive.d.ts +1 -1
- package/components/navigation/menu/nav/nav.component.d.ts +1 -1
- package/components/navigation/menu/nav/navigation-control.directive.d.ts +1 -1
- package/components/navigation/menu/public_api.d.ts +0 -1
- package/components/navigation/navbar/bundles/index.umd.js +20 -44
- package/components/navigation/navbar/esm2022/navbar.component.mjs +18 -16
- package/components/navigation/navbar/esm2022/public_api.mjs +1 -2
- package/components/navigation/navbar/fesm2022/index.mjs +18 -41
- package/components/navigation/navbar/fesm2022/index.mjs.map +1 -1
- package/components/navigation/navbar/navbar.component.d.ts +1 -1
- package/components/navigation/navbar/public_api.d.ts +0 -1
- package/components/navigation/popover/bundles/index.umd.js +12 -43
- package/components/navigation/popover/esm2022/popover.component.mjs +11 -9
- package/components/navigation/popover/esm2022/public_api.mjs +1 -2
- package/components/navigation/popover/fesm2022/index.mjs +11 -41
- package/components/navigation/popover/fesm2022/index.mjs.map +1 -1
- package/components/navigation/popover/popover.component.d.ts +1 -1
- package/components/navigation/popover/public_api.d.ts +0 -1
- package/components/page/default/bundles/index.umd.js +96 -138
- package/components/page/default/content/content.component.d.ts +1 -1
- package/components/page/default/esm2022/content/content.component.mjs +7 -6
- package/components/page/default/esm2022/layout.directive.mjs +3 -2
- package/components/page/default/esm2022/page-content/page-content.component.mjs +7 -6
- package/components/page/default/esm2022/page-content/page-content.props.mjs +2 -3
- package/components/page/default/esm2022/page.directive.mjs +3 -2
- package/components/page/default/esm2022/public_api.mjs +1 -2
- package/components/page/default/esm2022/router-outlet.directive.mjs +3 -2
- package/components/page/default/esm2022/spa-page.directive.mjs +3 -2
- package/components/page/default/fesm2022/index.mjs +96 -138
- package/components/page/default/fesm2022/index.mjs.map +1 -1
- package/components/page/default/layout.directive.d.ts +1 -1
- package/components/page/default/page-content/page-content.component.d.ts +1 -1
- package/components/page/default/page.directive.d.ts +1 -1
- package/components/page/default/public_api.d.ts +0 -1
- package/components/page/default/router-outlet.directive.d.ts +1 -1
- package/components/page/default/spa-page.directive.d.ts +1 -1
- package/components/page/footer/bundles/index.umd.js +6 -29
- package/components/page/footer/esm2022/footer.directive.mjs +3 -2
- package/components/page/footer/esm2022/public_api.mjs +1 -2
- package/components/page/footer/fesm2022/index.mjs +5 -28
- package/components/page/footer/fesm2022/index.mjs.map +1 -1
- package/components/page/footer/footer.directive.d.ts +1 -1
- package/components/page/footer/public_api.d.ts +0 -1
- package/components/page/header/bundles/index.umd.js +9 -33
- package/components/page/header/esm2022/header.component.mjs +7 -6
- package/components/page/header/esm2022/public_api.mjs +1 -2
- package/components/page/header/fesm2022/index.mjs +8 -32
- package/components/page/header/fesm2022/index.mjs.map +1 -1
- package/components/page/header/header.component.d.ts +1 -1
- package/components/page/header/public_api.d.ts +0 -1
- package/components/page/left-panel/bundles/index.umd.js +6 -29
- package/components/page/left-panel/esm2022/left-panel.directive.mjs +3 -2
- package/components/page/left-panel/esm2022/public_api.mjs +1 -2
- package/components/page/left-panel/fesm2022/index.mjs +5 -28
- package/components/page/left-panel/fesm2022/index.mjs.map +1 -1
- package/components/page/left-panel/left-panel.directive.d.ts +1 -1
- package/components/page/left-panel/public_api.d.ts +0 -1
- package/components/page/right-panel/bundles/index.umd.js +6 -29
- package/components/page/right-panel/esm2022/public_api.mjs +1 -2
- package/components/page/right-panel/esm2022/right-panel.directive.mjs +3 -2
- package/components/page/right-panel/fesm2022/index.mjs +5 -28
- package/components/page/right-panel/fesm2022/index.mjs.map +1 -1
- package/components/page/right-panel/public_api.d.ts +0 -1
- package/components/page/right-panel/right-panel.directive.d.ts +1 -1
- package/components/page/top-nav/bundles/index.umd.js +6 -29
- package/components/page/top-nav/esm2022/public_api.mjs +1 -2
- package/components/page/top-nav/esm2022/top-nav.directive.mjs +3 -2
- package/components/page/top-nav/fesm2022/index.mjs +5 -28
- package/components/page/top-nav/fesm2022/index.mjs.map +1 -1
- package/components/page/top-nav/public_api.d.ts +0 -1
- package/components/page/top-nav/top-nav.directive.d.ts +1 -1
- package/components/prefab/bundles/index.umd.js +8 -33
- package/components/prefab/esm2022/prefab-container/prefab-container.directive.mjs +3 -2
- package/components/prefab/esm2022/prefab.directive.mjs +3 -2
- package/components/prefab/esm2022/public_api.mjs +1 -2
- package/components/prefab/fesm2022/index.mjs +7 -32
- package/components/prefab/fesm2022/index.mjs.map +1 -1
- package/components/prefab/prefab-container/prefab-container.directive.d.ts +1 -1
- package/components/prefab/prefab.directive.d.ts +1 -1
- package/components/prefab/public_api.d.ts +0 -1
- package/core/bundles/index.umd.js +30 -85
- package/core/esm2022/public_api.mjs +2 -3
- package/core/esm2022/utils/build-utils.mjs +9 -5
- package/core/esm2022/utils/utils.mjs +11 -40
- package/core/fesm2022/index.mjs +31 -81
- package/core/fesm2022/index.mjs.map +1 -1
- package/core/public_api.d.ts +1 -2
- package/core/utils/utils.d.ts +1 -3
- package/http/bundles/index.umd.js +9 -34
- package/http/esm2022/http.service.mjs +6 -3
- package/http/esm2022/public_api.mjs +4 -2
- package/http/fesm2022/index.mjs +9 -34
- package/http/fesm2022/index.mjs.map +1 -1
- package/http/public_api.d.ts +3 -1
- package/npm-shrinkwrap.json +2 -2
- package/oAuth/bundles/index.umd.js +7 -42
- package/oAuth/esm2022/oAuth.utils.mjs +6 -23
- package/oAuth/esm2022/public_api.mjs +1 -2
- package/oAuth/fesm2022/index.mjs +7 -40
- package/oAuth/fesm2022/index.mjs.map +1 -1
- package/oAuth/public_api.d.ts +0 -1
- package/package-lock.json +2 -2
- package/package.json +1 -1
- package/runtime/base/bundles/index.umd.js +681 -596
- package/runtime/base/components/app-component/app.component.d.ts +1 -1
- package/runtime/base/components/app-spinner.component.d.ts +1 -1
- package/runtime/base/components/custom-toaster.component.d.ts +1 -1
- package/runtime/base/components/empty-component/empty-page.component.d.ts +1 -1
- package/runtime/base/components/prefab-preview.component.d.ts +1 -1
- package/runtime/base/directives/accessroles.directive.d.ts +1 -1
- package/runtime/base/directives/prefab.directive.d.ts +1 -1
- package/runtime/base/esm2022/components/app-component/app.component.mjs +42 -49
- package/runtime/base/esm2022/components/app-spinner.component.mjs +29 -21
- package/runtime/base/esm2022/components/base-page.component.mjs +3 -11
- package/runtime/base/esm2022/components/base-spa-page.component.mjs +3 -11
- package/runtime/base/esm2022/components/custom-toaster.component.mjs +20 -14
- package/runtime/base/esm2022/components/empty-component/empty-page.component.mjs +4 -3
- package/runtime/base/esm2022/components/prefab-preview.component.mjs +8 -6
- package/runtime/base/esm2022/directives/accessroles.directive.mjs +3 -2
- package/runtime/base/esm2022/directives/prefab.directive.mjs +3 -2
- package/runtime/base/esm2022/public_api.mjs +1 -1
- package/runtime/base/esm2022/resolves/security-config.resolve.mjs +4 -6
- package/runtime/base/esm2022/runtime-base.module.mjs +486 -337
- package/runtime/base/esm2022/services/app.manager.service.mjs +31 -48
- package/runtime/base/esm2022/services/i18n.service.mjs +37 -72
- package/runtime/base/fesm2022/index.mjs +689 -605
- package/runtime/base/fesm2022/index.mjs.map +1 -1
- package/runtime/base/runtime-base.module.d.ts +115 -84
- package/runtime/base/services/i18n.service.d.ts +1 -1
- package/runtime/dynamic/app/components/page-wrapper.component.d.ts +1 -1
- package/runtime/dynamic/bundles/index.umd.js +113 -69
- package/runtime/dynamic/esm2022/app/app.module.mjs +151 -105
- package/runtime/dynamic/esm2022/app/components/page-wrapper.component.mjs +7 -4
- package/runtime/dynamic/esm2022/app/services/component-ref-provider.service.mjs +4 -2
- package/runtime/dynamic/esm2022/main.mjs +2 -7
- package/runtime/dynamic/fesm2022/index.mjs +159 -114
- package/runtime/dynamic/fesm2022/index.mjs.map +1 -1
- package/security/bundles/index.umd.js +3 -34
- package/security/esm2022/public_api.mjs +1 -2
- package/security/esm2022/security.service.mjs +4 -15
- package/security/fesm2022/index.mjs +5 -32
- package/security/fesm2022/index.mjs.map +1 -1
- package/security/public_api.d.ts +0 -1
- package/transpiler/bundles/index.umd.js +271 -168
- package/transpiler/esm2022/build.mjs +1 -6
- package/transpiler/esm2022/imports.mjs +268 -161
- package/transpiler/fesm2022/index.mjs +267 -165
- package/transpiler/fesm2022/index.mjs.map +1 -1
- package/variables/bundles/index.umd.js +14 -198
- package/variables/constants/variables.constants.d.ts +0 -2
- package/variables/esm2022/constants/variables.constants.mjs +1 -3
- package/variables/esm2022/factory/variable-manager.factory.mjs +1 -3
- package/variables/esm2022/factory/variable.factory.mjs +1 -5
- package/variables/esm2022/manager/action/logout-action.manager.mjs +5 -7
- package/variables/esm2022/manager/variable/web-socket-variable.manager.mjs +3 -3
- package/variables/esm2022/public_api.mjs +1 -5
- package/variables/esm2022/service/metadata-service/metadata.service.mjs +6 -11
- package/variables/esm2022/util/variable/service-variable.utils.mjs +1 -4
- package/variables/esm2022/util/variable/variables.utils.mjs +4 -19
- package/variables/fesm2022/index.mjs +15 -198
- package/variables/fesm2022/index.mjs.map +1 -1
- package/variables/public_api.d.ts +0 -4
- package/components/advanced/carousel/carousel.module.d.ts +0 -11
- package/components/advanced/carousel/esm2022/carousel.module.mjs +0 -36
- package/components/advanced/custom/custom-widget.module.d.ts +0 -10
- package/components/advanced/custom/esm2022/custom-widget.module.mjs +0 -32
- package/components/advanced/login/esm2022/login.module.mjs +0 -28
- package/components/advanced/login/login.module.d.ts +0 -9
- package/components/advanced/marquee/esm2022/marquee.module.mjs +0 -28
- package/components/advanced/marquee/marquee.module.d.ts +0 -9
- package/components/base/esm2022/widgets/common/smooth-scroll/smooth-scroll.directive.mjs +0 -221
- package/components/base/widgets/common/smooth-scroll/smooth-scroll.directive.d.ts +0 -22
- package/components/basic/default/basic.module.d.ts +0 -17
- package/components/basic/default/esm2022/basic.module.mjs +0 -60
- package/components/basic/progress/esm2022/progress.module.mjs +0 -36
- package/components/basic/progress/progress.module.d.ts +0 -11
- package/components/basic/rich-text-editor/esm2022/rich-text-editor.module.mjs +0 -28
- package/components/basic/rich-text-editor/rich-text-editor.module.d.ts +0 -9
- package/components/basic/search/esm2022/search.module.mjs +0 -45
- package/components/basic/search/search.module.d.ts +0 -12
- package/components/basic/tree/esm2022/tree.module.mjs +0 -28
- package/components/basic/tree/tree.module.d.ts +0 -9
- package/components/chart/chart.module.d.ts +0 -10
- package/components/chart/esm2022/chart.module.mjs +0 -32
- package/components/containers/accordion/accordion.module.d.ts +0 -10
- package/components/containers/accordion/esm2022/accordion.module.mjs +0 -32
- package/components/containers/layout-grid/esm2022/layout-grid.module.mjs +0 -36
- package/components/containers/layout-grid/layout-grid.module.d.ts +0 -11
- package/components/containers/linear-layout/esm2022/linear-layout.module.mjs +0 -32
- package/components/containers/linear-layout/linear-layout.module.d.ts +0 -10
- package/components/containers/panel/esm2022/panel.module.mjs +0 -36
- package/components/containers/panel/panel.module.d.ts +0 -11
- package/components/containers/tabs/esm2022/tabs.module.mjs +0 -32
- package/components/containers/tabs/tabs.module.d.ts +0 -10
- package/components/containers/tile/esm2022/tile.module.mjs +0 -28
- package/components/containers/tile/tile.module.d.ts +0 -9
- package/components/containers/wizard/esm2022/wizard-step/wizard-step.directive.mjs +0 -140
- package/components/containers/wizard/esm2022/wizard.module.mjs +0 -40
- package/components/containers/wizard/wizard.module.d.ts +0 -12
- package/components/data/card/card.module.d.ts +0 -15
- package/components/data/card/esm2022/card.module.mjs +0 -52
- package/components/data/form/esm2022/form.module.mjs +0 -68
- package/components/data/form/form.module.d.ts +0 -19
- package/components/data/list/esm2022/list.module.mjs +0 -40
- package/components/data/list/list.module.d.ts +0 -11
- package/components/data/live-table/esm2022/live-table.module.mjs +0 -28
- package/components/data/live-table/live-table.module.d.ts +0 -9
- package/components/data/pagination/esm2022/pagination.module.mjs +0 -36
- package/components/data/pagination/pagination.module.d.ts +0 -11
- package/components/data/table/esm2022/table.module.mjs +0 -91
- package/components/data/table/table.module.d.ts +0 -24
- package/components/dialogs/alert-dialog/alert-dialog.module.d.ts +0 -11
- package/components/dialogs/alert-dialog/esm2022/alert-dialog.module.mjs +0 -36
- package/components/dialogs/confirm-dialog/confirm-dialog.module.d.ts +0 -11
- package/components/dialogs/confirm-dialog/esm2022/confirm-dialog.module.mjs +0 -36
- package/components/dialogs/default/dialog.module.d.ts +0 -12
- package/components/dialogs/default/esm2022/dialog.module.mjs +0 -40
- package/components/dialogs/design-dialog/design-dialog.module.d.ts +0 -11
- package/components/dialogs/design-dialog/esm2022/design-dialog.module.mjs +0 -36
- package/components/dialogs/iframe-dialog/esm2022/iframe-dialog.module.mjs +0 -40
- package/components/dialogs/iframe-dialog/iframe-dialog.module.d.ts +0 -12
- package/components/dialogs/login-dialog/esm2022/login-dialog.module.mjs +0 -40
- package/components/dialogs/login-dialog/login-dialog.module.d.ts +0 -12
- package/components/dialogs/partial-dialog/esm2022/partial-dialog.module.mjs +0 -36
- package/components/dialogs/partial-dialog/partial-dialog.module.d.ts +0 -11
- package/components/input/calendar/calendar.module.d.ts +0 -12
- package/components/input/calendar/esm2022/calendar.module.mjs +0 -40
- package/components/input/chips/chips.module.d.ts +0 -10
- package/components/input/chips/esm2022/chips.module.mjs +0 -32
- package/components/input/color-picker/color-picker.module.d.ts +0 -11
- package/components/input/color-picker/esm2022/color-picker.module.mjs +0 -36
- package/components/input/currency/currency.module.d.ts +0 -11
- package/components/input/currency/esm2022/currency.module.mjs +0 -36
- package/components/input/default/esm2022/input.module.mjs +0 -96
- package/components/input/default/input.module.d.ts +0 -26
- package/components/input/epoch/epoch.module.d.ts +0 -18
- package/components/input/epoch/esm2022/epoch.module.mjs +0 -70
- package/components/input/file-upload/esm2022/file-upload.module.mjs +0 -28
- package/components/input/file-upload/file-upload.module.d.ts +0 -9
- package/components/input/rating/esm2022/rating.module.mjs +0 -32
- package/components/input/rating/rating.module.d.ts +0 -10
- package/components/input/slider/esm2022/slider.module.mjs +0 -32
- package/components/input/slider/slider.module.d.ts +0 -10
- package/components/navigation/breadcrumb/breadcrumb.module.d.ts +0 -10
- package/components/navigation/breadcrumb/esm2022/breadcrumb.module.mjs +0 -32
- package/components/navigation/menu/esm2022/menu.module.mjs +0 -71
- package/components/navigation/menu/menu.module.d.ts +0 -17
- package/components/navigation/navbar/esm2022/navbar.module.mjs +0 -28
- package/components/navigation/navbar/navbar.module.d.ts +0 -9
- package/components/navigation/popover/esm2022/popover.module.mjs +0 -36
- package/components/navigation/popover/popover.module.d.ts +0 -11
- package/components/page/default/esm2022/page.module.mjs +0 -55
- package/components/page/default/page.module.d.ts +0 -14
- package/components/page/footer/esm2022/footer.module.mjs +0 -28
- package/components/page/footer/footer.module.d.ts +0 -9
- package/components/page/header/esm2022/header.module.mjs +0 -28
- package/components/page/header/header.module.d.ts +0 -9
- package/components/page/left-panel/esm2022/left-panel.module.mjs +0 -28
- package/components/page/left-panel/left-panel.module.d.ts +0 -9
- package/components/page/right-panel/esm2022/right-panel.module.mjs +0 -28
- package/components/page/right-panel/right-panel.module.d.ts +0 -9
- package/components/page/top-nav/esm2022/top-nav.module.mjs +0 -28
- package/components/page/top-nav/top-nav.module.d.ts +0 -9
- package/components/prefab/esm2022/prefab.module.mjs +0 -32
- package/components/prefab/prefab.module.d.ts +0 -10
- package/core/core.module.d.ts +0 -9
- package/core/esm2022/core.module.mjs +0 -27
- package/http/esm2022/http-service.module.mjs +0 -36
- package/http/http-service.module.d.ts +0 -14
- package/locales/fullcalendar/af.js +0 -27
- package/locales/fullcalendar/ar-dz.js +0 -28
- package/locales/fullcalendar/ar-kw.js +0 -28
- package/locales/fullcalendar/ar-ly.js +0 -28
- package/locales/fullcalendar/ar-ma.js +0 -28
- package/locales/fullcalendar/ar-sa.js +0 -28
- package/locales/fullcalendar/ar-tn.js +0 -28
- package/locales/fullcalendar/ar.js +0 -28
- package/locales/fullcalendar/az.js +0 -29
- package/locales/fullcalendar/bg.js +0 -28
- package/locales/fullcalendar/bs.js +0 -29
- package/locales/fullcalendar/ca.js +0 -27
- package/locales/fullcalendar/cs.js +0 -29
- package/locales/fullcalendar/da.js +0 -27
- package/locales/fullcalendar/de.js +0 -30
- package/locales/fullcalendar/el.js +0 -27
- package/locales/fullcalendar/en-au.js +0 -14
- package/locales/fullcalendar/en-gb.js +0 -14
- package/locales/fullcalendar/en-nz.js +0 -14
- package/locales/fullcalendar/es-us.js +0 -27
- package/locales/fullcalendar/es.js +0 -27
- package/locales/fullcalendar/et.js +0 -29
- package/locales/fullcalendar/eu.js +0 -27
- package/locales/fullcalendar/fa.js +0 -30
- package/locales/fullcalendar/fi.js +0 -27
- package/locales/fullcalendar/fr-ca.js +0 -24
- package/locales/fullcalendar/fr-ch.js +0 -28
- package/locales/fullcalendar/fr.js +0 -28
- package/locales/fullcalendar/gl.js +0 -27
- package/locales/fullcalendar/he.js +0 -24
- package/locales/fullcalendar/hi.js +0 -29
- package/locales/fullcalendar/hr.js +0 -29
- package/locales/fullcalendar/hu.js +0 -27
- package/locales/fullcalendar/id.js +0 -27
- package/locales/fullcalendar/is.js +0 -27
- package/locales/fullcalendar/it.js +0 -29
- package/locales/fullcalendar/ja.js +0 -25
- package/locales/fullcalendar/ka.js +0 -29
- package/locales/fullcalendar/kk.js +0 -29
- package/locales/fullcalendar/ko.js +0 -23
- package/locales/fullcalendar/lb.js +0 -27
- package/locales/fullcalendar/lt.js +0 -27
- package/locales/fullcalendar/lv.js +0 -29
- package/locales/fullcalendar/mk.js +0 -25
- package/locales/fullcalendar/ms.js +0 -29
- package/locales/fullcalendar/nb.js +0 -27
- package/locales/fullcalendar/ne.js +0 -27
- package/locales/fullcalendar/nl.js +0 -27
- package/locales/fullcalendar/nn.js +0 -27
- package/locales/fullcalendar/pl.js +0 -27
- package/locales/fullcalendar/pt-br.js +0 -25
- package/locales/fullcalendar/pt.js +0 -27
- package/locales/fullcalendar/ro.js +0 -29
- package/locales/fullcalendar/ru.js +0 -29
- package/locales/fullcalendar/sk.js +0 -29
- package/locales/fullcalendar/sl.js +0 -27
- package/locales/fullcalendar/sq.js +0 -29
- package/locales/fullcalendar/sr-cyrl.js +0 -29
- package/locales/fullcalendar/sr.js +0 -29
- package/locales/fullcalendar/sv.js +0 -27
- package/locales/fullcalendar/th.js +0 -30
- package/locales/fullcalendar/tr.js +0 -27
- package/locales/fullcalendar/ug.js +0 -17
- package/locales/fullcalendar/uk.js +0 -29
- package/locales/fullcalendar/uz.js +0 -21
- package/locales/fullcalendar/vi.js +0 -29
- package/locales/fullcalendar/zh-cn.js +0 -30
- package/locales/fullcalendar/zh-tw.js +0 -23
- package/mobile/components/basic/default/.npmignore +0 -2
- package/mobile/components/basic/default/anchor/anchor.directive.d.ts +0 -8
- package/mobile/components/basic/default/app-update/app-update.component.d.ts +0 -26
- package/mobile/components/basic/default/basic.module.d.ts +0 -15
- package/mobile/components/basic/default/bundles/index.umd.js +0 -980
- package/mobile/components/basic/default/esm2022/anchor/anchor.directive.mjs +0 -44
- package/mobile/components/basic/default/esm2022/app-update/app-update.component.mjs +0 -116
- package/mobile/components/basic/default/esm2022/basic.module.mjs +0 -52
- package/mobile/components/basic/default/esm2022/file-browser/file-browser.component.mjs +0 -236
- package/mobile/components/basic/default/esm2022/file-browser/file-selector.service.mjs +0 -85
- package/mobile/components/basic/default/esm2022/image-cache/image-cache.directive.mjs +0 -61
- package/mobile/components/basic/default/esm2022/index.mjs +0 -5
- package/mobile/components/basic/default/esm2022/network-info-toaster/network-info-toaster.component.mjs +0 -183
- package/mobile/components/basic/default/esm2022/network-info-toaster/network-info-toaster.props.mjs +0 -5
- package/mobile/components/basic/default/esm2022/process-manager/process-management.service.mjs +0 -47
- package/mobile/components/basic/default/esm2022/process-manager/process-manager.component.mjs +0 -175
- package/mobile/components/basic/default/esm2022/public_api.mjs +0 -10
- package/mobile/components/basic/default/fesm2022/index.mjs +0 -958
- package/mobile/components/basic/default/fesm2022/index.mjs.map +0 -1
- package/mobile/components/basic/default/file-browser/file-browser.component.d.ts +0 -39
- package/mobile/components/basic/default/file-browser/file-selector.service.d.ts +0 -27
- package/mobile/components/basic/default/image-cache/image-cache.directive.d.ts +0 -18
- package/mobile/components/basic/default/index.d.ts +0 -5
- package/mobile/components/basic/default/network-info-toaster/network-info-toaster.component.d.ts +0 -28
- package/mobile/components/basic/default/network-info-toaster/network-info-toaster.props.d.ts +0 -1
- package/mobile/components/basic/default/package.json +0 -23
- package/mobile/components/basic/default/process-manager/process-management.service.d.ts +0 -36
- package/mobile/components/basic/default/process-manager/process-manager.component.d.ts +0 -33
- package/mobile/components/basic/default/public_api.d.ts +0 -9
- package/mobile/components/basic/search/.npmignore +0 -2
- package/mobile/components/basic/search/bundles/index.umd.js +0 -66
- package/mobile/components/basic/search/esm2022/index.mjs +0 -5
- package/mobile/components/basic/search/esm2022/public_api.mjs +0 -3
- package/mobile/components/basic/search/esm2022/search.directive.mjs +0 -17
- package/mobile/components/basic/search/esm2022/search.module.mjs +0 -28
- package/mobile/components/basic/search/fesm2022/index.mjs +0 -49
- package/mobile/components/basic/search/fesm2022/index.mjs.map +0 -1
- package/mobile/components/basic/search/index.d.ts +0 -5
- package/mobile/components/basic/search/package.json +0 -23
- package/mobile/components/basic/search/public_api.d.ts +0 -2
- package/mobile/components/basic/search/search.directive.d.ts +0 -7
- package/mobile/components/basic/search/search.module.d.ts +0 -9
- package/mobile/components/containers/segmented-control/.npmignore +0 -2
- package/mobile/components/containers/segmented-control/bundles/index.umd.js +0 -281
- package/mobile/components/containers/segmented-control/esm2022/index.mjs +0 -5
- package/mobile/components/containers/segmented-control/esm2022/public_api.mjs +0 -4
- package/mobile/components/containers/segmented-control/esm2022/segment-content/segment-content.component.mjs +0 -70
- package/mobile/components/containers/segmented-control/esm2022/segment-content/segment-content.props.mjs +0 -14
- package/mobile/components/containers/segmented-control/esm2022/segmented-control.component.mjs +0 -147
- package/mobile/components/containers/segmented-control/esm2022/segmented-control.module.mjs +0 -32
- package/mobile/components/containers/segmented-control/esm2022/segmented-control.props.mjs +0 -9
- package/mobile/components/containers/segmented-control/fesm2022/index.mjs +0 -264
- package/mobile/components/containers/segmented-control/fesm2022/index.mjs.map +0 -1
- package/mobile/components/containers/segmented-control/index.d.ts +0 -5
- package/mobile/components/containers/segmented-control/package.json +0 -23
- package/mobile/components/containers/segmented-control/public_api.d.ts +0 -3
- package/mobile/components/containers/segmented-control/segment-content/segment-content.component.d.ts +0 -18
- package/mobile/components/containers/segmented-control/segment-content/segment-content.props.d.ts +0 -1
- package/mobile/components/containers/segmented-control/segmented-control.component.d.ts +0 -20
- package/mobile/components/containers/segmented-control/segmented-control.module.d.ts +0 -10
- package/mobile/components/containers/segmented-control/segmented-control.props.d.ts +0 -1
- package/mobile/components/data/media-list/.npmignore +0 -2
- package/mobile/components/data/media-list/bundles/index.umd.js +0 -310
- package/mobile/components/data/media-list/esm2022/index.mjs +0 -5
- package/mobile/components/data/media-list/esm2022/media-list-item/media-list-item.directive.mjs +0 -24
- package/mobile/components/data/media-list/esm2022/media-list.component.mjs +0 -213
- package/mobile/components/data/media-list/esm2022/media-list.module.mjs +0 -48
- package/mobile/components/data/media-list/esm2022/media-list.props.mjs +0 -16
- package/mobile/components/data/media-list/esm2022/public_api.mjs +0 -4
- package/mobile/components/data/media-list/fesm2022/index.mjs +0 -297
- package/mobile/components/data/media-list/fesm2022/index.mjs.map +0 -1
- package/mobile/components/data/media-list/index.d.ts +0 -5
- package/mobile/components/data/media-list/media-list-item/media-list-item.directive.d.ts +0 -8
- package/mobile/components/data/media-list/media-list.component.d.ts +0 -33
- package/mobile/components/data/media-list/media-list.module.d.ts +0 -14
- package/mobile/components/data/media-list/media-list.props.d.ts +0 -1
- package/mobile/components/data/media-list/package.json +0 -23
- package/mobile/components/data/media-list/public_api.d.ts +0 -3
- package/mobile/components/device/barcode-scanner/.npmignore +0 -2
- package/mobile/components/device/barcode-scanner/barcode-scanner.component.d.ts +0 -18
- package/mobile/components/device/barcode-scanner/barcode-scanner.module.d.ts +0 -9
- package/mobile/components/device/barcode-scanner/barcode-scanner.props.d.ts +0 -1
- package/mobile/components/device/barcode-scanner/bundles/index.umd.js +0 -129
- package/mobile/components/device/barcode-scanner/esm2022/barcode-scanner.component.mjs +0 -69
- package/mobile/components/device/barcode-scanner/esm2022/barcode-scanner.module.mjs +0 -28
- package/mobile/components/device/barcode-scanner/esm2022/barcode-scanner.props.mjs +0 -15
- package/mobile/components/device/barcode-scanner/esm2022/index.mjs +0 -5
- package/mobile/components/device/barcode-scanner/esm2022/public_api.mjs +0 -3
- package/mobile/components/device/barcode-scanner/fesm2022/index.mjs +0 -112
- package/mobile/components/device/barcode-scanner/fesm2022/index.mjs.map +0 -1
- package/mobile/components/device/barcode-scanner/index.d.ts +0 -5
- package/mobile/components/device/barcode-scanner/package.json +0 -23
- package/mobile/components/device/barcode-scanner/public_api.d.ts +0 -2
- package/mobile/components/device/camera/.npmignore +0 -2
- package/mobile/components/device/camera/bundles/index.umd.js +0 -170
- package/mobile/components/device/camera/camera.component.d.ts +0 -37
- package/mobile/components/device/camera/camera.module.d.ts +0 -9
- package/mobile/components/device/camera/camera.props.d.ts +0 -1
- package/mobile/components/device/camera/esm2022/camera.component.mjs +0 -101
- package/mobile/components/device/camera/esm2022/camera.module.mjs +0 -28
- package/mobile/components/device/camera/esm2022/camera.props.mjs +0 -25
- package/mobile/components/device/camera/esm2022/index.mjs +0 -5
- package/mobile/components/device/camera/esm2022/public_api.mjs +0 -3
- package/mobile/components/device/camera/fesm2022/index.mjs +0 -153
- package/mobile/components/device/camera/fesm2022/index.mjs.map +0 -1
- package/mobile/components/device/camera/index.d.ts +0 -5
- package/mobile/components/device/camera/package.json +0 -23
- package/mobile/components/device/camera/public_api.d.ts +0 -2
- package/mobile/components/input/file-upload/.npmignore +0 -2
- package/mobile/components/input/file-upload/bundles/index.umd.js +0 -88
- package/mobile/components/input/file-upload/esm2022/file-upload.directive.mjs +0 -41
- package/mobile/components/input/file-upload/esm2022/file-upload.module.mjs +0 -28
- package/mobile/components/input/file-upload/esm2022/index.mjs +0 -5
- package/mobile/components/input/file-upload/esm2022/public_api.mjs +0 -3
- package/mobile/components/input/file-upload/fesm2022/index.mjs +0 -71
- package/mobile/components/input/file-upload/fesm2022/index.mjs.map +0 -1
- package/mobile/components/input/file-upload/file-upload.directive.d.ts +0 -11
- package/mobile/components/input/file-upload/file-upload.module.d.ts +0 -9
- package/mobile/components/input/file-upload/index.d.ts +0 -5
- package/mobile/components/input/file-upload/package.json +0 -23
- package/mobile/components/input/file-upload/public_api.d.ts +0 -2
- package/mobile/components/page/default/.npmignore +0 -2
- package/mobile/components/page/default/bundles/index.umd.js +0 -127
- package/mobile/components/page/default/esm2022/index.mjs +0 -5
- package/mobile/components/page/default/esm2022/page-content-loader/page-content-loader.component.mjs +0 -24
- package/mobile/components/page/default/esm2022/page.directive.mjs +0 -58
- package/mobile/components/page/default/esm2022/page.module.mjs +0 -32
- package/mobile/components/page/default/esm2022/public_api.mjs +0 -4
- package/mobile/components/page/default/fesm2022/index.mjs +0 -110
- package/mobile/components/page/default/fesm2022/index.mjs.map +0 -1
- package/mobile/components/page/default/index.d.ts +0 -5
- package/mobile/components/page/default/package.json +0 -23
- package/mobile/components/page/default/page-content-loader/page-content-loader.component.d.ts +0 -7
- package/mobile/components/page/default/page.directive.d.ts +0 -19
- package/mobile/components/page/default/page.module.d.ts +0 -10
- package/mobile/components/page/default/public_api.d.ts +0 -3
- package/mobile/components/page/left-panel/.npmignore +0 -2
- package/mobile/components/page/left-panel/bundles/index.umd.js +0 -91
- package/mobile/components/page/left-panel/esm2022/index.mjs +0 -5
- package/mobile/components/page/left-panel/esm2022/left-panel.directive.mjs +0 -45
- package/mobile/components/page/left-panel/esm2022/left-panel.module.mjs +0 -28
- package/mobile/components/page/left-panel/esm2022/public_api.mjs +0 -3
- package/mobile/components/page/left-panel/fesm2022/index.mjs +0 -74
- package/mobile/components/page/left-panel/fesm2022/index.mjs.map +0 -1
- package/mobile/components/page/left-panel/index.d.ts +0 -5
- package/mobile/components/page/left-panel/left-panel.directive.d.ts +0 -16
- package/mobile/components/page/left-panel/left-panel.module.d.ts +0 -9
- package/mobile/components/page/left-panel/package.json +0 -23
- package/mobile/components/page/left-panel/public_api.d.ts +0 -2
- package/mobile/components/page/mobile-navbar/.npmignore +0 -2
- package/mobile/components/page/mobile-navbar/bundles/index.umd.js +0 -332
- package/mobile/components/page/mobile-navbar/esm2022/index.mjs +0 -5
- package/mobile/components/page/mobile-navbar/esm2022/mobile-navbar.component.mjs +0 -247
- package/mobile/components/page/mobile-navbar/esm2022/mobile-navbar.module.mjs +0 -32
- package/mobile/components/page/mobile-navbar/esm2022/mobile-navbar.props.mjs +0 -41
- package/mobile/components/page/mobile-navbar/esm2022/public_api.mjs +0 -3
- package/mobile/components/page/mobile-navbar/fesm2022/index.mjs +0 -317
- package/mobile/components/page/mobile-navbar/fesm2022/index.mjs.map +0 -1
- package/mobile/components/page/mobile-navbar/index.d.ts +0 -5
- package/mobile/components/page/mobile-navbar/mobile-navbar.component.d.ts +0 -50
- package/mobile/components/page/mobile-navbar/mobile-navbar.module.d.ts +0 -10
- package/mobile/components/page/mobile-navbar/mobile-navbar.props.d.ts +0 -2
- package/mobile/components/page/mobile-navbar/package.json +0 -23
- package/mobile/components/page/mobile-navbar/public_api.d.ts +0 -2
- package/mobile/components/page/tab-bar/.npmignore +0 -2
- package/mobile/components/page/tab-bar/bundles/index.umd.js +0 -279
- package/mobile/components/page/tab-bar/esm2022/index.mjs +0 -5
- package/mobile/components/page/tab-bar/esm2022/public_api.mjs +0 -3
- package/mobile/components/page/tab-bar/esm2022/tab-bar.module.mjs +0 -28
- package/mobile/components/page/tab-bar/esm2022/tabbar.component.mjs +0 -219
- package/mobile/components/page/tab-bar/esm2022/tabbar.props.mjs +0 -15
- package/mobile/components/page/tab-bar/fesm2022/index.mjs +0 -262
- package/mobile/components/page/tab-bar/fesm2022/index.mjs.map +0 -1
- package/mobile/components/page/tab-bar/index.d.ts +0 -5
- package/mobile/components/page/tab-bar/package.json +0 -23
- package/mobile/components/page/tab-bar/public_api.d.ts +0 -2
- package/mobile/components/page/tab-bar/tab-bar.module.d.ts +0 -9
- package/mobile/components/page/tab-bar/tabbar.component.d.ts +0 -40
- package/mobile/components/page/tab-bar/tabbar.props.d.ts +0 -1
- package/mobile/core/.npmignore +0 -2
- package/mobile/core/bundles/index.umd.js +0 -1658
- package/mobile/core/core.module.d.ts +0 -15
- package/mobile/core/esm2022/core.module.mjs +0 -79
- package/mobile/core/esm2022/index.mjs +0 -5
- package/mobile/core/esm2022/native.xhr.mjs +0 -340
- package/mobile/core/esm2022/public_api.mjs +0 -12
- package/mobile/core/esm2022/services/device-file-cache.service.mjs +0 -92
- package/mobile/core/esm2022/services/device-file-download.service.mjs +0 -154
- package/mobile/core/esm2022/services/device-file-opener.service.mjs +0 -112
- package/mobile/core/esm2022/services/device-file-upload.service.mjs +0 -91
- package/mobile/core/esm2022/services/device-file.service.mjs +0 -237
- package/mobile/core/esm2022/services/device-start-up-service.mjs +0 -2
- package/mobile/core/esm2022/services/device.service.mjs +0 -150
- package/mobile/core/esm2022/services/ext-app-message.service.mjs +0 -114
- package/mobile/core/esm2022/services/network.service.mjs +0 -358
- package/mobile/core/fesm2022/index.mjs +0 -1660
- package/mobile/core/fesm2022/index.mjs.map +0 -1
- package/mobile/core/index.d.ts +0 -5
- package/mobile/core/native.xhr.d.ts +0 -36
- package/mobile/core/package.json +0 -28
- package/mobile/core/public_api.d.ts +0 -11
- package/mobile/core/services/device-file-cache.service.d.ts +0 -24
- package/mobile/core/services/device-file-download.service.d.ts +0 -36
- package/mobile/core/services/device-file-opener.service.d.ts +0 -25
- package/mobile/core/services/device-file-upload.service.d.ts +0 -27
- package/mobile/core/services/device-file.service.d.ts +0 -45
- package/mobile/core/services/device-start-up-service.d.ts +0 -4
- package/mobile/core/services/device.service.d.ts +0 -52
- package/mobile/core/services/ext-app-message.service.d.ts +0 -24
- package/mobile/core/services/network.service.d.ts +0 -118
- package/mobile/offline/.npmignore +0 -2
- package/mobile/offline/bundles/index.umd.js +0 -3512
- package/mobile/offline/esm2022/index.mjs +0 -5
- package/mobile/offline/esm2022/models/config.mjs +0 -64
- package/mobile/offline/esm2022/models/local-db-store.mjs +0 -412
- package/mobile/offline/esm2022/offline.module.mjs +0 -100
- package/mobile/offline/esm2022/public_api.mjs +0 -7
- package/mobile/offline/esm2022/services/change-log.service.mjs +0 -332
- package/mobile/offline/esm2022/services/local-db-data-pull.service.mjs +0 -525
- package/mobile/offline/esm2022/services/local-db-management.service.mjs +0 -855
- package/mobile/offline/esm2022/services/local-db.service.mjs +0 -193
- package/mobile/offline/esm2022/services/local-key-value.service.mjs +0 -87
- package/mobile/offline/esm2022/services/push.service.mjs +0 -49
- package/mobile/offline/esm2022/services/workers/error-blocker.mjs +0 -115
- package/mobile/offline/esm2022/services/workers/file-handler.mjs +0 -162
- package/mobile/offline/esm2022/services/workers/id-resolver.mjs +0 -154
- package/mobile/offline/esm2022/services/workers/multi-part-param-transformer.mjs +0 -63
- package/mobile/offline/esm2022/utils/file-upload.utils.mjs +0 -59
- package/mobile/offline/esm2022/utils/live-variable.utils.mjs +0 -232
- package/mobile/offline/esm2022/utils/query-executor.utils.mjs +0 -82
- package/mobile/offline/esm2022/utils/security.utils.mjs +0 -119
- package/mobile/offline/esm2022/utils/utils.mjs +0 -8
- package/mobile/offline/fesm2022/index.mjs +0 -3529
- package/mobile/offline/fesm2022/index.mjs.map +0 -1
- package/mobile/offline/index.d.ts +0 -5
- package/mobile/offline/models/config.d.ts +0 -80
- package/mobile/offline/models/local-db-store.d.ts +0 -119
- package/mobile/offline/offline.module.d.ts +0 -17
- package/mobile/offline/package.json +0 -28
- package/mobile/offline/public_api.d.ts +0 -6
- package/mobile/offline/services/change-log.service.d.ts +0 -112
- package/mobile/offline/services/local-db-data-pull.service.d.ts +0 -139
- package/mobile/offline/services/local-db-management.service.d.ts +0 -179
- package/mobile/offline/services/local-db.service.d.ts +0 -83
- package/mobile/offline/services/local-key-value.service.d.ts +0 -38
- package/mobile/offline/services/push.service.d.ts +0 -11
- package/mobile/offline/services/workers/error-blocker.d.ts +0 -26
- package/mobile/offline/services/workers/file-handler.d.ts +0 -56
- package/mobile/offline/services/workers/id-resolver.d.ts +0 -26
- package/mobile/offline/services/workers/multi-part-param-transformer.d.ts +0 -11
- package/mobile/offline/utils/file-upload.utils.d.ts +0 -14
- package/mobile/offline/utils/live-variable.utils.d.ts +0 -24
- package/mobile/offline/utils/query-executor.utils.d.ts +0 -15
- package/mobile/offline/utils/security.utils.d.ts +0 -19
- package/mobile/offline/utils/utils.d.ts +0 -2
- package/mobile/placeholder/runtime/.npmignore +0 -2
- package/mobile/placeholder/runtime/bundles/index.umd.js +0 -70
- package/mobile/placeholder/runtime/components/app-ext.component.d.ts +0 -5
- package/mobile/placeholder/runtime/esm2022/components/app-ext.component.mjs +0 -19
- package/mobile/placeholder/runtime/esm2022/index.mjs +0 -5
- package/mobile/placeholder/runtime/esm2022/mobile-runtime.module.mjs +0 -27
- package/mobile/placeholder/runtime/esm2022/public_api.mjs +0 -3
- package/mobile/placeholder/runtime/fesm2022/index.mjs +0 -50
- package/mobile/placeholder/runtime/fesm2022/index.mjs.map +0 -1
- package/mobile/placeholder/runtime/index.d.ts +0 -5
- package/mobile/placeholder/runtime/mobile-runtime.module.d.ts +0 -9
- package/mobile/placeholder/runtime/package.json +0 -27
- package/mobile/placeholder/runtime/public_api.d.ts +0 -2
- package/mobile/placeholder/runtime-dynamic/.npmignore +0 -2
- package/mobile/placeholder/runtime-dynamic/bundles/index.umd.js +0 -40
- package/mobile/placeholder/runtime-dynamic/esm2022/index.mjs +0 -5
- package/mobile/placeholder/runtime-dynamic/esm2022/mobile-runtime-dynamic.module.mjs +0 -13
- package/mobile/placeholder/runtime-dynamic/esm2022/public_api.mjs +0 -2
- package/mobile/placeholder/runtime-dynamic/fesm2022/index.mjs +0 -20
- package/mobile/placeholder/runtime-dynamic/fesm2022/index.mjs.map +0 -1
- package/mobile/placeholder/runtime-dynamic/index.d.ts +0 -5
- package/mobile/placeholder/runtime-dynamic/mobile-runtime-dynamic.module.d.ts +0 -7
- package/mobile/placeholder/runtime-dynamic/package.json +0 -23
- package/mobile/placeholder/runtime-dynamic/public_api.d.ts +0 -1
- package/mobile/runtime/.npmignore +0 -2
- package/mobile/runtime/bundles/index.umd.js +0 -732
- package/mobile/runtime/components/app-ext.component.d.ts +0 -14
- package/mobile/runtime/esm2022/components/app-ext.component.mjs +0 -59
- package/mobile/runtime/esm2022/index.mjs +0 -5
- package/mobile/runtime/esm2022/mobile-runtime.module.mjs +0 -351
- package/mobile/runtime/esm2022/public_api.mjs +0 -6
- package/mobile/runtime/esm2022/services/cookie.service.mjs +0 -135
- package/mobile/runtime/esm2022/services/http-interceptor.service.mjs +0 -147
- package/mobile/runtime/esm2022/services/webprocess.service.mjs +0 -76
- package/mobile/runtime/fesm2022/index.mjs +0 -742
- package/mobile/runtime/fesm2022/index.mjs.map +0 -1
- package/mobile/runtime/index.d.ts +0 -5
- package/mobile/runtime/mobile-runtime.module.d.ts +0 -51
- package/mobile/runtime/package.json +0 -28
- package/mobile/runtime/public_api.d.ts +0 -5
- package/mobile/runtime/services/cookie.service.d.ts +0 -31
- package/mobile/runtime/services/http-interceptor.service.d.ts +0 -19
- package/mobile/runtime/services/webprocess.service.d.ts +0 -15
- package/mobile/runtime-dynamic/.npmignore +0 -2
- package/mobile/runtime-dynamic/bundles/index.umd.js +0 -461
- package/mobile/runtime-dynamic/esm2022/index.mjs +0 -5
- package/mobile/runtime-dynamic/esm2022/mobile-runtime-dynamic.module.mjs +0 -48
- package/mobile/runtime-dynamic/esm2022/public_api.mjs +0 -2
- package/mobile/runtime-dynamic/esm2022/services/live-sync.service.mjs +0 -404
- package/mobile/runtime-dynamic/fesm2022/index.mjs +0 -454
- package/mobile/runtime-dynamic/fesm2022/index.mjs.map +0 -1
- package/mobile/runtime-dynamic/index.d.ts +0 -5
- package/mobile/runtime-dynamic/mobile-runtime-dynamic.module.d.ts +0 -8
- package/mobile/runtime-dynamic/package.json +0 -23
- package/mobile/runtime-dynamic/public_api.d.ts +0 -1
- package/mobile/runtime-dynamic/services/live-sync.service.d.ts +0 -38
- package/mobile/variables/.npmignore +0 -2
- package/mobile/variables/bundles/index.umd.js +0 -1166
- package/mobile/variables/esm2022/index.mjs +0 -5
- package/mobile/variables/esm2022/public_api.mjs +0 -10
- package/mobile/variables/esm2022/services/calendar-service.mjs +0 -77
- package/mobile/variables/esm2022/services/camera-service.mjs +0 -70
- package/mobile/variables/esm2022/services/contacts-service.mjs +0 -74
- package/mobile/variables/esm2022/services/datasync-service.mjs +0 -363
- package/mobile/variables/esm2022/services/device-service/device-service.mjs +0 -161
- package/mobile/variables/esm2022/services/device-service/location-service.mjs +0 -200
- package/mobile/variables/esm2022/services/file-service.mjs +0 -87
- package/mobile/variables/esm2022/services/scan-service.mjs +0 -60
- package/mobile/variables/esm2022/variables.module.mjs +0 -78
- package/mobile/variables/fesm2022/index.mjs +0 -1143
- package/mobile/variables/fesm2022/index.mjs.map +0 -1
- package/mobile/variables/index.d.ts +0 -5
- package/mobile/variables/package.json +0 -28
- package/mobile/variables/public_api.d.ts +0 -9
- package/mobile/variables/services/calendar-service.d.ts +0 -10
- package/mobile/variables/services/camera-service.d.ts +0 -8
- package/mobile/variables/services/contacts-service.d.ts +0 -6
- package/mobile/variables/services/datasync-service.d.ts +0 -11
- package/mobile/variables/services/device-service/device-service.d.ts +0 -17
- package/mobile/variables/services/device-service/location-service.d.ts +0 -63
- package/mobile/variables/services/file-service.d.ts +0 -7
- package/mobile/variables/services/scan-service.d.ts +0 -7
- package/mobile/variables/variables.module.d.ts +0 -25
- package/oAuth/esm2022/oAuth.module.mjs +0 -19
- package/oAuth/oAuth.module.d.ts +0 -8
- package/scripts/fullcalendar/main.min.js +0 -6
- package/security/esm2022/security.module.mjs +0 -19
- package/security/security.module.d.ts +0 -8
- package/variables/esm2022/manager/variable/device-variable-manager.mjs +0 -48
- package/variables/esm2022/manager/variable/device-variable-operation.mjs +0 -2
- package/variables/esm2022/manager/variable/device-variable-service.mjs +0 -45
- package/variables/esm2022/model/variable/device-variable.mjs +0 -19
- package/variables/esm2022/variables.module.mjs +0 -52
- package/variables/manager/variable/device-variable-manager.d.ts +0 -26
- package/variables/manager/variable/device-variable-operation.d.ts +0 -37
- package/variables/manager/variable/device-variable-service.d.ts +0 -6
- package/variables/model/variable/device-variable.d.ts +0 -6
- package/variables/variables.module.d.ts +0 -16
|
@@ -1,1658 +0,0 @@
|
|
|
1
|
-
(function (global, factory) {
|
|
2
|
-
typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('@angular/core'), require('@wm/core'), require('@awesome-cordova-plugins/file/ngx'), require('@awesome-cordova-plugins/app-version/ngx'), require('lodash-es'), require('@angular/common/http'), require('rxjs/operators'), require('@wm/components/base'), require('@awesome-cordova-plugins/file-opener/ngx'), require('@awesome-cordova-plugins/network/ngx')) :
|
|
3
|
-
typeof define === 'function' && define.amd ? define(['exports', '@angular/core', '@wm/core', '@awesome-cordova-plugins/file/ngx', '@awesome-cordova-plugins/app-version/ngx', 'lodash-es', '@angular/common/http', 'rxjs/operators', '@wm/components/base', '@awesome-cordova-plugins/file-opener/ngx', '@awesome-cordova-plugins/network/ngx'], factory) :
|
|
4
|
-
(global = typeof globalThis !== 'undefined' ? globalThis : global || self, factory((global.wm = global.wm || {}, global.wm.mobile = global.wm.mobile || {}, global.wm.mobile.core = {}), global.ng.core, global.wm.core, global.awesomeCordova.plugins, global.awesomeCordova.plugins, global._, global.ng.common.http, global.rxjs.operators, global.wm.components.base, global.awesomeCordova.plugins, global.awesomeCordova.plugins));
|
|
5
|
-
})(this, (function (exports, i0, i2$2, i1$1, i1, lodashEs, i2, operators, i4, i2$1, i3) { 'use strict';
|
|
6
|
-
|
|
7
|
-
function _interopNamespaceDefault(e) {
|
|
8
|
-
var n = Object.create(null);
|
|
9
|
-
if (e) {
|
|
10
|
-
Object.keys(e).forEach(function (k) {
|
|
11
|
-
if (k !== 'default') {
|
|
12
|
-
var d = Object.getOwnPropertyDescriptor(e, k);
|
|
13
|
-
Object.defineProperty(n, k, d.get ? d : {
|
|
14
|
-
enumerable: true,
|
|
15
|
-
get: function () { return e[k]; }
|
|
16
|
-
});
|
|
17
|
-
}
|
|
18
|
-
});
|
|
19
|
-
}
|
|
20
|
-
n.default = e;
|
|
21
|
-
return Object.freeze(n);
|
|
22
|
-
}
|
|
23
|
-
|
|
24
|
-
var i0__namespace = /*#__PURE__*/_interopNamespaceDefault(i0);
|
|
25
|
-
var i2$2__namespace = /*#__PURE__*/_interopNamespaceDefault(i2$2);
|
|
26
|
-
var i1$1__namespace = /*#__PURE__*/_interopNamespaceDefault(i1$1);
|
|
27
|
-
var i1__namespace = /*#__PURE__*/_interopNamespaceDefault(i1);
|
|
28
|
-
var i2__namespace = /*#__PURE__*/_interopNamespaceDefault(i2);
|
|
29
|
-
var i4__namespace = /*#__PURE__*/_interopNamespaceDefault(i4);
|
|
30
|
-
var i2$1__namespace = /*#__PURE__*/_interopNamespaceDefault(i2$1);
|
|
31
|
-
var i3__namespace = /*#__PURE__*/_interopNamespaceDefault(i3);
|
|
32
|
-
|
|
33
|
-
exports.FileType = void 0;
|
|
34
|
-
(function (FileType) {
|
|
35
|
-
FileType["AUDIO"] = "AUDIO";
|
|
36
|
-
FileType["DOCUMENT"] = "DOCUMENT";
|
|
37
|
-
FileType["IMAGE"] = "IMAGE";
|
|
38
|
-
FileType["VIDEO"] = "VIDEO";
|
|
39
|
-
})(exports.FileType || (exports.FileType = {}));
|
|
40
|
-
const IMAGE_EXTENSIONS = ['gif', 'jpg', 'png', 'svg', 'webp', 'jpeg', 'jif', 'jfif', 'jfi'], VIDEO_EXTENSIONS = ['mp4', 'mpg', 'avi', 'wma', 'mp2', '3gp', '3g2', 'm4p', 'm4v', 'mpg', 'fiv'], AUDIO_EXTENSIONS = ['mp3', 'm4p', 'aiff', 'aa', 'aax', 'wma'];
|
|
41
|
-
const APP_FOLDER_STRUCTURE = [{
|
|
42
|
-
name: '{APP_NAME}',
|
|
43
|
-
children: [{
|
|
44
|
-
name: 'Media',
|
|
45
|
-
children: [
|
|
46
|
-
{
|
|
47
|
-
name: '{APP_NAME} Images',
|
|
48
|
-
fileType: exports.FileType.IMAGE
|
|
49
|
-
},
|
|
50
|
-
{
|
|
51
|
-
name: '{APP_NAME} Audio',
|
|
52
|
-
fileType: exports.FileType.AUDIO
|
|
53
|
-
},
|
|
54
|
-
{
|
|
55
|
-
name: '{APP_NAME} Vedios',
|
|
56
|
-
fileType: exports.FileType.VIDEO
|
|
57
|
-
},
|
|
58
|
-
{
|
|
59
|
-
name: '{APP_NAME} Documents',
|
|
60
|
-
fileType: exports.FileType.DOCUMENT
|
|
61
|
-
}
|
|
62
|
-
]
|
|
63
|
-
}]
|
|
64
|
-
}];
|
|
65
|
-
class DeviceFileService {
|
|
66
|
-
static { this.SERVICE_NAME = 'DeviceFileService'; }
|
|
67
|
-
constructor(cordovaAppVersion, cordovaFile) {
|
|
68
|
-
this.cordovaAppVersion = cordovaAppVersion;
|
|
69
|
-
this.cordovaFile = cordovaFile;
|
|
70
|
-
this._fileTypeVsPathMap = {
|
|
71
|
-
'temporary': {},
|
|
72
|
-
'persistent': {}
|
|
73
|
-
};
|
|
74
|
-
}
|
|
75
|
-
addMediaToGallery(filePath) {
|
|
76
|
-
if (i2$2.isAndroid() && this.isPersistentType(filePath)) {
|
|
77
|
-
return new Promise((resolve, reject) => {
|
|
78
|
-
cordova.plugins.MediaScannerPlugin.scanFile(filePath, resolve, reject);
|
|
79
|
-
});
|
|
80
|
-
}
|
|
81
|
-
return Promise.resolve();
|
|
82
|
-
}
|
|
83
|
-
appendToFileName(fileName, attachment) {
|
|
84
|
-
let splits;
|
|
85
|
-
attachment = attachment || '_' + lodashEs.now();
|
|
86
|
-
fileName = fileName || 'noname';
|
|
87
|
-
splits = fileName.split('.');
|
|
88
|
-
if (splits.length > 1) {
|
|
89
|
-
splits[splits.length - 2] = splits[splits.length - 2] + attachment;
|
|
90
|
-
return splits.join('.');
|
|
91
|
-
}
|
|
92
|
-
return fileName + attachment;
|
|
93
|
-
}
|
|
94
|
-
clearTemporaryStorage() {
|
|
95
|
-
return this.cordovaFile.removeRecursively(this.getTemporaryRootPath() + this._appName + '/', 'Media');
|
|
96
|
-
}
|
|
97
|
-
copy(persistent, sourceFilePath) {
|
|
98
|
-
const sourceFilename = sourceFilePath.split('/').pop(), destFolder = this.findFolderPath(persistent, sourceFilename), sourceFolder = sourceFilePath.substring(0, sourceFilePath.lastIndexOf('/'));
|
|
99
|
-
return this.newFileName(destFolder, sourceFilename)
|
|
100
|
-
.then(destFilename => this.cordovaFile.copyFile(sourceFolder, sourceFilename, destFolder, destFilename)
|
|
101
|
-
.then(() => destFolder + destFilename));
|
|
102
|
-
}
|
|
103
|
-
findFolderPath(persistent, fileName) {
|
|
104
|
-
const typeMap = persistent ? this._fileTypeVsPathMap.persistent : this._fileTypeVsPathMap.temporary, fileType = this.findFileType(fileName);
|
|
105
|
-
return typeMap[fileType] || typeMap[exports.FileType.DOCUMENT];
|
|
106
|
-
}
|
|
107
|
-
getPersistentRootPath() {
|
|
108
|
-
return cordova.file.dataDirectory;
|
|
109
|
-
}
|
|
110
|
-
getTemporaryRootPath() {
|
|
111
|
-
return cordova.file.cacheDirectory;
|
|
112
|
-
}
|
|
113
|
-
getUploadDirectory() {
|
|
114
|
-
return this._uploadDir;
|
|
115
|
-
}
|
|
116
|
-
isPersistentType(filePath) {
|
|
117
|
-
return filePath.startsWith(this.getPersistentRootPath());
|
|
118
|
-
}
|
|
119
|
-
isValidPath(filePath) {
|
|
120
|
-
let folder, fileName;
|
|
121
|
-
if (!filePath) {
|
|
122
|
-
return Promise.reject('File path is required');
|
|
123
|
-
}
|
|
124
|
-
folder = filePath.substring(0, filePath.lastIndexOf('/') + 1);
|
|
125
|
-
fileName = filePath.split('/').pop();
|
|
126
|
-
return this.cordovaFile.checkFile(folder, fileName)
|
|
127
|
-
.then(() => filePath);
|
|
128
|
-
}
|
|
129
|
-
listFiles(folder, search) {
|
|
130
|
-
return new Promise((resolve, reject) => {
|
|
131
|
-
resolveLocalFileSystemURL(folder, directory => {
|
|
132
|
-
if (!directory.files) {
|
|
133
|
-
directory.createReader().readEntries(entries => {
|
|
134
|
-
if (search) {
|
|
135
|
-
entries = entries.filter(e => e.name.match(search));
|
|
136
|
-
}
|
|
137
|
-
entries = entries.map(e => {
|
|
138
|
-
return {
|
|
139
|
-
name: e.name,
|
|
140
|
-
isDirectory: e.isDirectory,
|
|
141
|
-
path: e.nativeURL
|
|
142
|
-
};
|
|
143
|
-
});
|
|
144
|
-
resolve(entries);
|
|
145
|
-
}, reject);
|
|
146
|
-
}
|
|
147
|
-
else {
|
|
148
|
-
resolve([]);
|
|
149
|
-
}
|
|
150
|
-
}, reject);
|
|
151
|
-
});
|
|
152
|
-
}
|
|
153
|
-
newFileName(folder, fileName) {
|
|
154
|
-
return this.cordovaFile.checkFile(folder, fileName)
|
|
155
|
-
.then(() => {
|
|
156
|
-
const extIndex = fileName.lastIndexOf('.');
|
|
157
|
-
if (extIndex > 0) {
|
|
158
|
-
fileName = fileName.substring(0, extIndex) + '_' + lodashEs.now() + '.' + fileName.substring(extIndex + 1);
|
|
159
|
-
}
|
|
160
|
-
else {
|
|
161
|
-
fileName = fileName + '_' + lodashEs.now();
|
|
162
|
-
}
|
|
163
|
-
return this.newFileName(folder, fileName);
|
|
164
|
-
}, () => fileName);
|
|
165
|
-
}
|
|
166
|
-
removeFile(filePath) {
|
|
167
|
-
const i = filePath.lastIndexOf('/'), dir = filePath.substring(0, i), file = filePath.substring(i + 1);
|
|
168
|
-
return this.cordovaFile.removeFile(dir, file);
|
|
169
|
-
}
|
|
170
|
-
/**
|
|
171
|
-
* removes the directory at the specified location.
|
|
172
|
-
*
|
|
173
|
-
* @param dirPath absolute path of directory
|
|
174
|
-
*/
|
|
175
|
-
removeDir(dirPath) {
|
|
176
|
-
const i = dirPath.lastIndexOf('/'), parentdir = dirPath.substring(0, i + 1), dir = dirPath.substring(i + 1), movedDir = dir + lodashEs.now();
|
|
177
|
-
return this.cordovaFile.checkDir(parentdir, dir)
|
|
178
|
-
.then(() => {
|
|
179
|
-
/**
|
|
180
|
-
* If folder is remove directly without moving, then INVALID_MODIFICATION_ERR is thrown in android
|
|
181
|
-
* when a copy operation is done with the same directory name. To avoid this, directory will be moved
|
|
182
|
-
* first and removed.
|
|
183
|
-
*/
|
|
184
|
-
return this.cordovaFile.moveDir(parentdir, dir, parentdir, movedDir)
|
|
185
|
-
.then(() => this.cordovaFile.removeDir(parentdir, movedDir));
|
|
186
|
-
}).catch(i2$2.noop);
|
|
187
|
-
}
|
|
188
|
-
start() {
|
|
189
|
-
/**
|
|
190
|
-
* Default READ_CHUNK_SIZE is 256 Kb. But with that setting readJson method is failing. This is an issue
|
|
191
|
-
* with cordova file plugin. So, increasing it to 512 Kb to read large database schema files (>256 Kb).
|
|
192
|
-
*/
|
|
193
|
-
FileReader.READ_CHUNK_SIZE = 512 * 1024;
|
|
194
|
-
return Promise.resolve().then(() => {
|
|
195
|
-
return this.cordovaAppVersion.getAppName();
|
|
196
|
-
}).then(appName => {
|
|
197
|
-
const promises = [];
|
|
198
|
-
this._appName = appName;
|
|
199
|
-
promises.push(this.createFolderIfNotExists(this.getTemporaryRootPath(), APP_FOLDER_STRUCTURE, this._fileTypeVsPathMap.temporary));
|
|
200
|
-
promises.push(this.createFolderIfNotExists(this.getPersistentRootPath(), APP_FOLDER_STRUCTURE, this._fileTypeVsPathMap.persistent));
|
|
201
|
-
promises.push(this.setupUploadDirectory());
|
|
202
|
-
return Promise.all(promises);
|
|
203
|
-
}).then(() => {
|
|
204
|
-
if (i2$2.isAndroid()) {
|
|
205
|
-
// this is necessary to prevent multiple file permission popup.
|
|
206
|
-
return this.cordovaFile.readAsText(cordova.file.externalRootDirectory, 'random-file-for-permission').catch(i2$2.noop);
|
|
207
|
-
}
|
|
208
|
-
});
|
|
209
|
-
}
|
|
210
|
-
getServiceName() {
|
|
211
|
-
return DeviceFileService.SERVICE_NAME;
|
|
212
|
-
}
|
|
213
|
-
createFolderIfNotExists(parent, folders, fileTypeLocationMap) {
|
|
214
|
-
const childPromises = [];
|
|
215
|
-
if (folders) {
|
|
216
|
-
folders.forEach(folder => {
|
|
217
|
-
let folderPath;
|
|
218
|
-
folder.name = folder.name.replace('{APP_NAME}', this._appName);
|
|
219
|
-
folderPath = parent + folder.name + '/';
|
|
220
|
-
if (folder.fileType && !fileTypeLocationMap[folder.fileType]) {
|
|
221
|
-
fileTypeLocationMap[folder.fileType] = folderPath;
|
|
222
|
-
}
|
|
223
|
-
const p = this.cordovaFile.createDir(parent, folder.name, false)
|
|
224
|
-
.then(() => this.createFolderIfNotExists(folderPath, folder.children, fileTypeLocationMap), () => this.createFolderIfNotExists(folderPath, folder.children, fileTypeLocationMap));
|
|
225
|
-
childPromises.push(p);
|
|
226
|
-
});
|
|
227
|
-
}
|
|
228
|
-
if (childPromises.length > 0) {
|
|
229
|
-
return Promise.all(childPromises);
|
|
230
|
-
}
|
|
231
|
-
}
|
|
232
|
-
findFileType(fileName) {
|
|
233
|
-
let extension;
|
|
234
|
-
if (fileName.indexOf('.') > 0) {
|
|
235
|
-
extension = fileName.split('.').pop().toLowerCase();
|
|
236
|
-
if (IMAGE_EXTENSIONS.some(a => a === extension)) {
|
|
237
|
-
return exports.FileType.IMAGE;
|
|
238
|
-
}
|
|
239
|
-
if (VIDEO_EXTENSIONS.some(a => a === extension)) {
|
|
240
|
-
return exports.FileType.VIDEO;
|
|
241
|
-
}
|
|
242
|
-
if (AUDIO_EXTENSIONS.some(a => a === extension)) {
|
|
243
|
-
return exports.FileType.AUDIO;
|
|
244
|
-
}
|
|
245
|
-
}
|
|
246
|
-
return exports.FileType.DOCUMENT;
|
|
247
|
-
}
|
|
248
|
-
setupUploadDirectory() {
|
|
249
|
-
const uploadsDirName = 'uploads', appDir = cordova.file.dataDirectory;
|
|
250
|
-
return this.cordovaFile.checkDir(appDir, uploadsDirName)
|
|
251
|
-
.then(() => this._uploadDir = appDir + uploadsDirName, () => this.cordovaFile.createDir(appDir, uploadsDirName, true)
|
|
252
|
-
.then(() => this._uploadDir = appDir + uploadsDirName));
|
|
253
|
-
}
|
|
254
|
-
static { this.ɵfac = function DeviceFileService_Factory(__ngFactoryType__) { return new (__ngFactoryType__ || DeviceFileService)(i0__namespace.ɵɵinject(i1__namespace.AppVersion), i0__namespace.ɵɵinject(i1$1__namespace.File)); }; }
|
|
255
|
-
static { this.ɵprov = /*@__PURE__*/ i0__namespace.ɵɵdefineInjectable({ token: DeviceFileService, factory: DeviceFileService.ɵfac, providedIn: 'root' }); }
|
|
256
|
-
}
|
|
257
|
-
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0__namespace.ɵsetClassMetadata(DeviceFileService, [{
|
|
258
|
-
type: i0.Injectable,
|
|
259
|
-
args: [{ providedIn: 'root' }]
|
|
260
|
-
}], () => [{ type: i1__namespace.AppVersion }, { type: i1$1__namespace.File }], null); })();
|
|
261
|
-
|
|
262
|
-
const MAX_CONCURRENT_DOWNLOADS = 2;
|
|
263
|
-
class DeviceFileDownloadService {
|
|
264
|
-
static { this.SERVICE_NAME = 'DeviceFileDownloadService'; }
|
|
265
|
-
constructor(cordovaFile, http, deviceFileService, fileExtensionFromMimePipe) {
|
|
266
|
-
this.cordovaFile = cordovaFile;
|
|
267
|
-
this.http = http;
|
|
268
|
-
this.deviceFileService = deviceFileService;
|
|
269
|
-
this.fileExtensionFromMimePipe = fileExtensionFromMimePipe;
|
|
270
|
-
this._downloadQueue = [];
|
|
271
|
-
this._concurrentDownloads = 0;
|
|
272
|
-
}
|
|
273
|
-
download(url, isPersistent, destFolder, destFile, progressObserver, headers) {
|
|
274
|
-
return this.addToDownloadQueue(url, isPersistent, destFolder, destFile, progressObserver, headers);
|
|
275
|
-
}
|
|
276
|
-
// Adds to download request queue
|
|
277
|
-
addToDownloadQueue(url, isPersistent, destFolder, destFile, progressObserver, headers) {
|
|
278
|
-
return new Promise((resolve, reject) => {
|
|
279
|
-
this._downloadQueue.push({
|
|
280
|
-
url: url,
|
|
281
|
-
headers: headers,
|
|
282
|
-
isPersistent: isPersistent,
|
|
283
|
-
destFolder: destFolder,
|
|
284
|
-
destFile: destFile,
|
|
285
|
-
resolve: resolve,
|
|
286
|
-
reject: reject,
|
|
287
|
-
progressObserver: progressObserver
|
|
288
|
-
});
|
|
289
|
-
if (this._concurrentDownloads < MAX_CONCURRENT_DOWNLOADS) {
|
|
290
|
-
this.downloadNext();
|
|
291
|
-
}
|
|
292
|
-
});
|
|
293
|
-
}
|
|
294
|
-
downloadNext() {
|
|
295
|
-
if (this._downloadQueue.length > 0) {
|
|
296
|
-
const req = this._downloadQueue.shift();
|
|
297
|
-
this.downloadFile(req).then(filePath => {
|
|
298
|
-
req.resolve(filePath);
|
|
299
|
-
this.downloadNext();
|
|
300
|
-
}, () => {
|
|
301
|
-
req.reject();
|
|
302
|
-
this.downloadNext();
|
|
303
|
-
});
|
|
304
|
-
}
|
|
305
|
-
}
|
|
306
|
-
// Start processing a download request
|
|
307
|
-
downloadFile(req) {
|
|
308
|
-
let filePath, blob;
|
|
309
|
-
this._concurrentDownloads++;
|
|
310
|
-
return this.sendHttpRequest(req.url, req.progressObserver, req.headers).then((e) => {
|
|
311
|
-
blob = e.body;
|
|
312
|
-
return this.getFileName(e, req, blob.type);
|
|
313
|
-
}).then((fileName) => {
|
|
314
|
-
if (!req.destFolder) {
|
|
315
|
-
req.destFolder = this.deviceFileService.findFolderPath(req.isPersistent, fileName);
|
|
316
|
-
}
|
|
317
|
-
filePath = req.destFolder + fileName;
|
|
318
|
-
return this.cordovaFile.writeFile(req.destFolder, fileName, blob);
|
|
319
|
-
}).then(() => {
|
|
320
|
-
this._concurrentDownloads--;
|
|
321
|
-
return filePath;
|
|
322
|
-
}, (response) => {
|
|
323
|
-
this._concurrentDownloads--;
|
|
324
|
-
this.cordovaFile.removeFile(req.destFolder, req.destFile);
|
|
325
|
-
return Promise.reject(`Failed to downloaded ${req.url} with error ${JSON.stringify(response)}`);
|
|
326
|
-
});
|
|
327
|
-
}
|
|
328
|
-
/**
|
|
329
|
-
* Returns the filename
|
|
330
|
-
* 1. if filename exists just return
|
|
331
|
-
* 2. retrieve the filename from response headers i.e. content-disposition
|
|
332
|
-
* 3. pick the filename from the end of the url
|
|
333
|
-
* If filename doesnt contain the extension then extract using mimeType.
|
|
334
|
-
* Generates newFileName if filename already exists.
|
|
335
|
-
* @param response, download file response
|
|
336
|
-
* @param req, download request params
|
|
337
|
-
* @param mimeType mime type of file
|
|
338
|
-
* @returns {Promise<string>}
|
|
339
|
-
*/
|
|
340
|
-
getFileName(response, req, mimeType) {
|
|
341
|
-
const disposition = response.headers.get('Content-Disposition');
|
|
342
|
-
let filename = req.destFile;
|
|
343
|
-
if (!filename && disposition && disposition.indexOf('attachment') !== -1) {
|
|
344
|
-
const filenameRegex = /filename[^;=\n]*=((['"]).*?\2|[^;\n]*)/;
|
|
345
|
-
const matches = filenameRegex.exec(disposition);
|
|
346
|
-
if (matches !== null && matches[1]) {
|
|
347
|
-
filename = matches[1].replace(/['"]/g, '');
|
|
348
|
-
}
|
|
349
|
-
}
|
|
350
|
-
if (!filename) {
|
|
351
|
-
filename = req.url.split('?')[0];
|
|
352
|
-
filename = filename.split('/').pop();
|
|
353
|
-
}
|
|
354
|
-
let fileExtension;
|
|
355
|
-
if (mimeType) {
|
|
356
|
-
fileExtension = this.fileExtensionFromMimePipe.transform(mimeType);
|
|
357
|
-
}
|
|
358
|
-
let hasFileExtension;
|
|
359
|
-
// one or more file extensions can have same mimeType then loop over the file extensions.
|
|
360
|
-
if (lodashEs.isArray(fileExtension) && !lodashEs.isEmpty(fileExtension)) {
|
|
361
|
-
hasFileExtension = lodashEs.find(fileExtension, extension => lodashEs.endsWith(filename, extension));
|
|
362
|
-
//File extension will be array for some file formats
|
|
363
|
-
fileExtension = fileExtension[0];
|
|
364
|
-
}
|
|
365
|
-
if (!hasFileExtension && !lodashEs.endsWith(filename, fileExtension)) {
|
|
366
|
-
filename = filename + fileExtension;
|
|
367
|
-
}
|
|
368
|
-
const folder = req.destFolder || this.deviceFileService.findFolderPath(req.isPersistent, filename);
|
|
369
|
-
return this.deviceFileService.newFileName(folder, filename);
|
|
370
|
-
}
|
|
371
|
-
sendHttpRequest(url, progressObserver, headers) {
|
|
372
|
-
let reqHeaders = new i2.HttpHeaders();
|
|
373
|
-
// headers
|
|
374
|
-
if (headers) {
|
|
375
|
-
Object.entries(headers).forEach(([k, v]) => reqHeaders = reqHeaders.append(k, v));
|
|
376
|
-
}
|
|
377
|
-
const req = new i2.HttpRequest('GET', url, {
|
|
378
|
-
headers: reqHeaders,
|
|
379
|
-
responseType: 'blob',
|
|
380
|
-
reportProgress: progressObserver != null
|
|
381
|
-
});
|
|
382
|
-
return this.http.request(req)
|
|
383
|
-
.pipe(operators.map(e => {
|
|
384
|
-
if (progressObserver && progressObserver.next && e.type === i2.HttpEventType.DownloadProgress) {
|
|
385
|
-
progressObserver.next(e);
|
|
386
|
-
}
|
|
387
|
-
return e;
|
|
388
|
-
}), operators.filter(e => e.type === i2.HttpEventType.Response), operators.map(e => {
|
|
389
|
-
if (progressObserver && progressObserver.complete) {
|
|
390
|
-
progressObserver.complete();
|
|
391
|
-
}
|
|
392
|
-
return e;
|
|
393
|
-
}))
|
|
394
|
-
.toPromise();
|
|
395
|
-
}
|
|
396
|
-
static { this.ɵfac = function DeviceFileDownloadService_Factory(__ngFactoryType__) { return new (__ngFactoryType__ || DeviceFileDownloadService)(i0__namespace.ɵɵinject(i1$1__namespace.File), i0__namespace.ɵɵinject(i2__namespace.HttpClient), i0__namespace.ɵɵinject(DeviceFileService), i0__namespace.ɵɵinject(i4__namespace.FileExtensionFromMimePipe)); }; }
|
|
397
|
-
static { this.ɵprov = /*@__PURE__*/ i0__namespace.ɵɵdefineInjectable({ token: DeviceFileDownloadService, factory: DeviceFileDownloadService.ɵfac, providedIn: 'root' }); }
|
|
398
|
-
}
|
|
399
|
-
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0__namespace.ɵsetClassMetadata(DeviceFileDownloadService, [{
|
|
400
|
-
type: i0.Injectable,
|
|
401
|
-
args: [{ providedIn: 'root' }]
|
|
402
|
-
}], () => [{ type: i1$1__namespace.File }, { type: i2__namespace.HttpClient }, { type: DeviceFileService }, { type: i4__namespace.FileExtensionFromMimePipe }], null); })();
|
|
403
|
-
|
|
404
|
-
const CACHE_FILE_INDEX_NAME = 'appCache.json';
|
|
405
|
-
class DeviceFileCacheService {
|
|
406
|
-
static { this.SERVICE_NAME = 'DeviceFileCacheService'; }
|
|
407
|
-
constructor(cordovaFile, fileService, downloadService) {
|
|
408
|
-
this.cordovaFile = cordovaFile;
|
|
409
|
-
this.fileService = fileService;
|
|
410
|
-
this.downloadService = downloadService;
|
|
411
|
-
this._cacheIndex = {};
|
|
412
|
-
}
|
|
413
|
-
addEntry(url, filepath) {
|
|
414
|
-
this._cacheIndex[url] = filepath;
|
|
415
|
-
this.writeCacheIndexToFile();
|
|
416
|
-
}
|
|
417
|
-
getLocalPath(url, downloadIfNotExists, isPersistent, forceRefresh = false) {
|
|
418
|
-
if (forceRefresh) {
|
|
419
|
-
return this.download(url, isPersistent);
|
|
420
|
-
}
|
|
421
|
-
const filePath = this._cacheIndex[url];
|
|
422
|
-
return this.fileService.isValidPath(filePath)
|
|
423
|
-
.catch(() => {
|
|
424
|
-
delete this._cacheIndex[url];
|
|
425
|
-
if (downloadIfNotExists) {
|
|
426
|
-
return this.download(url, isPersistent);
|
|
427
|
-
}
|
|
428
|
-
else {
|
|
429
|
-
return Promise.reject('No cache entry for ' + url);
|
|
430
|
-
}
|
|
431
|
-
});
|
|
432
|
-
}
|
|
433
|
-
invalidateCache() {
|
|
434
|
-
this._cacheIndex = {};
|
|
435
|
-
this.writeCacheIndexToFile();
|
|
436
|
-
this.fileService.clearTemporaryStorage();
|
|
437
|
-
}
|
|
438
|
-
start() {
|
|
439
|
-
return this.cordovaFile.readAsText(cordova.file.dataDirectory, CACHE_FILE_INDEX_NAME)
|
|
440
|
-
.then(content => {
|
|
441
|
-
this._cacheIndex = JSON.parse(content);
|
|
442
|
-
}, i2$2.noop);
|
|
443
|
-
}
|
|
444
|
-
getServiceName() {
|
|
445
|
-
return DeviceFileCacheService.SERVICE_NAME;
|
|
446
|
-
}
|
|
447
|
-
download(url, isPersistent) {
|
|
448
|
-
return this.downloadService.download(url, isPersistent)
|
|
449
|
-
.then(filepath => {
|
|
450
|
-
this._cacheIndex[url] = filepath;
|
|
451
|
-
this.writeCacheIndexToFile();
|
|
452
|
-
return filepath;
|
|
453
|
-
});
|
|
454
|
-
}
|
|
455
|
-
writeCacheIndexToFile() {
|
|
456
|
-
if (!this._writing) {
|
|
457
|
-
this._writing = true;
|
|
458
|
-
this.cordovaFile.writeFile(cordova.file.dataDirectory, CACHE_FILE_INDEX_NAME, JSON.stringify(this._cacheIndex), {
|
|
459
|
-
replace: true
|
|
460
|
-
})
|
|
461
|
-
.catch(i2$2.noop)
|
|
462
|
-
.then(() => {
|
|
463
|
-
if (this._saveCache) {
|
|
464
|
-
setTimeout(() => {
|
|
465
|
-
this._writing = false;
|
|
466
|
-
this._saveCache = false;
|
|
467
|
-
this.writeCacheIndexToFile();
|
|
468
|
-
}, 5000);
|
|
469
|
-
}
|
|
470
|
-
else {
|
|
471
|
-
this._writing = false;
|
|
472
|
-
}
|
|
473
|
-
});
|
|
474
|
-
}
|
|
475
|
-
else {
|
|
476
|
-
this._saveCache = true;
|
|
477
|
-
}
|
|
478
|
-
}
|
|
479
|
-
static { this.ɵfac = function DeviceFileCacheService_Factory(__ngFactoryType__) { return new (__ngFactoryType__ || DeviceFileCacheService)(i0__namespace.ɵɵinject(i1$1__namespace.File), i0__namespace.ɵɵinject(DeviceFileService), i0__namespace.ɵɵinject(DeviceFileDownloadService)); }; }
|
|
480
|
-
static { this.ɵprov = /*@__PURE__*/ i0__namespace.ɵɵdefineInjectable({ token: DeviceFileCacheService, factory: DeviceFileCacheService.ɵfac, providedIn: 'root' }); }
|
|
481
|
-
}
|
|
482
|
-
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0__namespace.ɵsetClassMetadata(DeviceFileCacheService, [{
|
|
483
|
-
type: i0.Injectable,
|
|
484
|
-
args: [{ providedIn: 'root' }]
|
|
485
|
-
}], () => [{ type: i1$1__namespace.File }, { type: DeviceFileService }, { type: DeviceFileDownloadService }], null); })();
|
|
486
|
-
|
|
487
|
-
class DeviceFileOpenerService {
|
|
488
|
-
static { this.SERVICE_NAME = 'DeviceFileOpenerService'; }
|
|
489
|
-
constructor(cordovaFile, cordovaFileOpener, fileService, cacheService, downloadService) {
|
|
490
|
-
this.cordovaFile = cordovaFile;
|
|
491
|
-
this.cordovaFileOpener = cordovaFileOpener;
|
|
492
|
-
this.fileService = fileService;
|
|
493
|
-
this.cacheService = cacheService;
|
|
494
|
-
this.downloadService = downloadService;
|
|
495
|
-
}
|
|
496
|
-
// this method returns the mime type of file from the filePath.
|
|
497
|
-
getFileMimeType(filePath) {
|
|
498
|
-
return new Promise((resolve) => {
|
|
499
|
-
// Read the file entry from the file URL
|
|
500
|
-
resolveLocalFileSystemURL(filePath, fileEntry => {
|
|
501
|
-
fileEntry.file(metadata => {
|
|
502
|
-
resolve(metadata.type);
|
|
503
|
-
});
|
|
504
|
-
});
|
|
505
|
-
});
|
|
506
|
-
}
|
|
507
|
-
openRemoteFile(url, extension, fileName, headers) {
|
|
508
|
-
return this.getLocalPath(url, extension, fileName, headers)
|
|
509
|
-
.then(filePath => {
|
|
510
|
-
return this.getFileMimeType(filePath).then(type => {
|
|
511
|
-
return this.cordovaFileOpener.open(filePath, type);
|
|
512
|
-
});
|
|
513
|
-
});
|
|
514
|
-
}
|
|
515
|
-
start() {
|
|
516
|
-
let downloadsParent;
|
|
517
|
-
if (i2$2.isAndroid()) {
|
|
518
|
-
downloadsParent = cordova.file.externalCacheDirectory;
|
|
519
|
-
}
|
|
520
|
-
else if (i2$2.isIos()) {
|
|
521
|
-
downloadsParent = cordova.file.documentsDirectory + 'NoCloud/';
|
|
522
|
-
}
|
|
523
|
-
else {
|
|
524
|
-
downloadsParent = cordova.file.dataDirectory;
|
|
525
|
-
}
|
|
526
|
-
return this.cordovaFile.createDir(downloadsParent, 'downloads', false)
|
|
527
|
-
.catch(i2$2.noop)
|
|
528
|
-
.then(() => {
|
|
529
|
-
this._downloadsFolder = downloadsParent + 'downloads/';
|
|
530
|
-
});
|
|
531
|
-
}
|
|
532
|
-
getServiceName() {
|
|
533
|
-
return DeviceFileCacheService.SERVICE_NAME;
|
|
534
|
-
}
|
|
535
|
-
generateFileName(url, extension) {
|
|
536
|
-
let fileName = url.split('?')[0];
|
|
537
|
-
fileName = fileName.split('/').pop();
|
|
538
|
-
fileName = this.fileService.appendToFileName(fileName, '' + lodashEs.now());
|
|
539
|
-
if (extension) {
|
|
540
|
-
return fileName.split('.')[0] + '.' + extension;
|
|
541
|
-
}
|
|
542
|
-
return fileName;
|
|
543
|
-
}
|
|
544
|
-
getLocalPath(url, extension, filename, headers) {
|
|
545
|
-
return new Promise((resolve, reject) => {
|
|
546
|
-
return this.cacheService.getLocalPath(url, false, false)
|
|
547
|
-
.then(filePath => {
|
|
548
|
-
let fileName, i, j, fromDir, fromFile;
|
|
549
|
-
// Is it part of downloaded folder.
|
|
550
|
-
if (filePath.startsWith(this._downloadsFolder)) {
|
|
551
|
-
resolve(filePath);
|
|
552
|
-
}
|
|
553
|
-
else {
|
|
554
|
-
//Extract extension from file downloaded earlier.
|
|
555
|
-
j = filePath.lastIndexOf('.');
|
|
556
|
-
extension = filePath.substring(j + 1);
|
|
557
|
-
fileName = filename || this.generateFileName(url, extension);
|
|
558
|
-
i = filePath.lastIndexOf('/');
|
|
559
|
-
fromDir = filePath.substring(0, i);
|
|
560
|
-
fromFile = filePath.substring(i + 1);
|
|
561
|
-
this.cordovaFile.copyFile(fromDir, fromFile, this._downloadsFolder, fileName)
|
|
562
|
-
.then(() => {
|
|
563
|
-
const newFilePath = this._downloadsFolder + fileName;
|
|
564
|
-
this.cacheService.addEntry(url, newFilePath);
|
|
565
|
-
resolve(newFilePath);
|
|
566
|
-
});
|
|
567
|
-
}
|
|
568
|
-
}).catch(() => {
|
|
569
|
-
this.downloadService.download(url, false, this._downloadsFolder, filename, undefined, headers)
|
|
570
|
-
.then(filePath => {
|
|
571
|
-
this.cacheService.addEntry(url, filePath);
|
|
572
|
-
resolve(filePath);
|
|
573
|
-
}, reject);
|
|
574
|
-
});
|
|
575
|
-
});
|
|
576
|
-
}
|
|
577
|
-
static { this.ɵfac = function DeviceFileOpenerService_Factory(__ngFactoryType__) { return new (__ngFactoryType__ || DeviceFileOpenerService)(i0__namespace.ɵɵinject(i1$1__namespace.File), i0__namespace.ɵɵinject(i2$1__namespace.FileOpener), i0__namespace.ɵɵinject(DeviceFileService), i0__namespace.ɵɵinject(DeviceFileCacheService), i0__namespace.ɵɵinject(DeviceFileDownloadService)); }; }
|
|
578
|
-
static { this.ɵprov = /*@__PURE__*/ i0__namespace.ɵɵdefineInjectable({ token: DeviceFileOpenerService, factory: DeviceFileOpenerService.ɵfac, providedIn: 'root' }); }
|
|
579
|
-
}
|
|
580
|
-
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0__namespace.ɵsetClassMetadata(DeviceFileOpenerService, [{
|
|
581
|
-
type: i0.Injectable,
|
|
582
|
-
args: [{ providedIn: 'root' }]
|
|
583
|
-
}], () => [{ type: i1$1__namespace.File }, { type: i2$1__namespace.FileOpener }, { type: DeviceFileService }, { type: DeviceFileCacheService }, { type: DeviceFileDownloadService }], null); })();
|
|
584
|
-
|
|
585
|
-
const REGISTRY_FILE_NAME = 'registry.info';
|
|
586
|
-
class DeviceService {
|
|
587
|
-
static { this.SERVICE_NAME = 'DeviceService'; }
|
|
588
|
-
constructor(file) {
|
|
589
|
-
this.file = file;
|
|
590
|
-
this._registry = {};
|
|
591
|
-
this._isReady = false;
|
|
592
|
-
this._whenReadyPromises = [];
|
|
593
|
-
this._backBtnTapListeners = [];
|
|
594
|
-
this._startUpServices = [];
|
|
595
|
-
this._config = {};
|
|
596
|
-
const maxWaitTime = 10;
|
|
597
|
-
setTimeout(() => {
|
|
598
|
-
if (!this._isReady) {
|
|
599
|
-
console.warn(`Device is not ready even after ${maxWaitTime} seconds`);
|
|
600
|
-
console.warn('Waiting For %O', this._startUpServices.map(i => i.getServiceName()));
|
|
601
|
-
}
|
|
602
|
-
}, maxWaitTime * 1000);
|
|
603
|
-
document.addEventListener('backbutton', this.executeBackTapListeners.bind(this));
|
|
604
|
-
if (i2$2.hasCordova()) {
|
|
605
|
-
const port = location.port ? ':' + location.port : '';
|
|
606
|
-
const configUrl = `${location.protocol}//${location.hostname}${port}${i2$2.isIos() ? '' : '/_www'}/config.json`;
|
|
607
|
-
i2$2.fetchContent('json', configUrl, true, (response => {
|
|
608
|
-
if (!response.error && response.baseUrl) {
|
|
609
|
-
this._config = response;
|
|
610
|
-
}
|
|
611
|
-
}));
|
|
612
|
-
}
|
|
613
|
-
}
|
|
614
|
-
executeBackTapListeners($event) {
|
|
615
|
-
lodashEs.forEach(this._backBtnTapListeners, fn => {
|
|
616
|
-
return fn($event) !== false;
|
|
617
|
-
});
|
|
618
|
-
// explicitly applying the digest cycle as the backbutton listener is not rendering the page content.
|
|
619
|
-
// This is because zone is not run (there is no change detection)
|
|
620
|
-
// https://weblogs.thinktecture.com/thomas/2017/02/cordova-vs-zonejs-or-why-is-angulars-document-event-listener-not-in-a-zone.html
|
|
621
|
-
i2$2.$appDigest();
|
|
622
|
-
}
|
|
623
|
-
addStartUpService(service) {
|
|
624
|
-
this._startUpServices.push(service);
|
|
625
|
-
}
|
|
626
|
-
onBackButtonTap(fn) {
|
|
627
|
-
this._backBtnTapListeners.unshift(fn);
|
|
628
|
-
return () => {
|
|
629
|
-
const i = this._backBtnTapListeners.indexOf(fn);
|
|
630
|
-
if (i >= 0) {
|
|
631
|
-
this._backBtnTapListeners.splice(i, 1);
|
|
632
|
-
}
|
|
633
|
-
};
|
|
634
|
-
}
|
|
635
|
-
start() {
|
|
636
|
-
if (this._isReady || this._startUpServices.length === 0) {
|
|
637
|
-
this._isReady = true;
|
|
638
|
-
return Promise.resolve();
|
|
639
|
-
}
|
|
640
|
-
else {
|
|
641
|
-
return new Promise((resolve) => {
|
|
642
|
-
if (i2$2.hasCordova()) {
|
|
643
|
-
document.addEventListener('deviceready', () => resolve(), false);
|
|
644
|
-
}
|
|
645
|
-
else {
|
|
646
|
-
resolve();
|
|
647
|
-
}
|
|
648
|
-
}).then(() => {
|
|
649
|
-
if (window['cordova']) {
|
|
650
|
-
return this.file.readAsText(cordova.file.dataDirectory, REGISTRY_FILE_NAME)
|
|
651
|
-
.then(content => this._registry = JSON.parse(content), i2$2.noop);
|
|
652
|
-
}
|
|
653
|
-
}).then(() => {
|
|
654
|
-
return Promise.all(this._startUpServices.map(s => {
|
|
655
|
-
return s.start().catch((error) => {
|
|
656
|
-
console.error('%s failed to start due to: %O', s.getServiceName(), error);
|
|
657
|
-
return Promise.reject(error);
|
|
658
|
-
});
|
|
659
|
-
}));
|
|
660
|
-
}).then(() => {
|
|
661
|
-
window['wmDeviceReady'] = true;
|
|
662
|
-
document.dispatchEvent(new CustomEvent('wmDeviceReady'));
|
|
663
|
-
this._startUpServices.length = 0;
|
|
664
|
-
this._whenReadyPromises.forEach(fn => fn());
|
|
665
|
-
this._isReady = true;
|
|
666
|
-
});
|
|
667
|
-
}
|
|
668
|
-
}
|
|
669
|
-
getServiceName() {
|
|
670
|
-
return DeviceService.SERVICE_NAME;
|
|
671
|
-
}
|
|
672
|
-
whenReady() {
|
|
673
|
-
if (this._isReady) {
|
|
674
|
-
return Promise.resolve();
|
|
675
|
-
}
|
|
676
|
-
else {
|
|
677
|
-
return new Promise((resolve) => {
|
|
678
|
-
this._whenReadyPromises.push(resolve);
|
|
679
|
-
});
|
|
680
|
-
}
|
|
681
|
-
}
|
|
682
|
-
getBaseUrl() {
|
|
683
|
-
return this._config.baseUrl === 'http://NOSERVERREQUIRED.com' ? 'NONE' : this._config.baseUrl;
|
|
684
|
-
}
|
|
685
|
-
isAppConnectedToPreview() {
|
|
686
|
-
return this._config.customUrl !== this._config.baseUrl && this.getBaseUrl() !== 'NONE';
|
|
687
|
-
}
|
|
688
|
-
getConfig() {
|
|
689
|
-
return this._config;
|
|
690
|
-
}
|
|
691
|
-
useNativeXHR() {
|
|
692
|
-
return (i2$2.isIos() || this._config.useNativeXHR === true)
|
|
693
|
-
&& i2$2.hasCordova()
|
|
694
|
-
&& cordova.plugin
|
|
695
|
-
&& cordova.plugin.http;
|
|
696
|
-
}
|
|
697
|
-
/**
|
|
698
|
-
* @returns {Promise<number>} promise resolved with the app build time
|
|
699
|
-
*/
|
|
700
|
-
getAppBuildTime() {
|
|
701
|
-
return Promise.resolve(this._config.buildTime);
|
|
702
|
-
}
|
|
703
|
-
/**
|
|
704
|
-
* Stores an entry that survives app restarts and updates.
|
|
705
|
-
*
|
|
706
|
-
* @param {string} key
|
|
707
|
-
* @param {Object} value
|
|
708
|
-
* @returns {Promise<any>}
|
|
709
|
-
*/
|
|
710
|
-
storeEntry(key, value) {
|
|
711
|
-
this._registry[key] = value;
|
|
712
|
-
return this.file.writeFile(cordova.file.dataDirectory, REGISTRY_FILE_NAME, JSON.stringify(this._registry), { replace: true });
|
|
713
|
-
}
|
|
714
|
-
/**
|
|
715
|
-
* @param {string} key
|
|
716
|
-
* @returns {any} entry corresponding to the key
|
|
717
|
-
*/
|
|
718
|
-
getEntry(key) {
|
|
719
|
-
return this._registry[key];
|
|
720
|
-
}
|
|
721
|
-
static { this.ɵfac = function DeviceService_Factory(__ngFactoryType__) { return new (__ngFactoryType__ || DeviceService)(i0__namespace.ɵɵinject(i1$1__namespace.File)); }; }
|
|
722
|
-
static { this.ɵprov = /*@__PURE__*/ i0__namespace.ɵɵdefineInjectable({ token: DeviceService, factory: DeviceService.ɵfac, providedIn: 'root' }); }
|
|
723
|
-
}
|
|
724
|
-
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0__namespace.ɵsetClassMetadata(DeviceService, [{
|
|
725
|
-
type: i0.Injectable,
|
|
726
|
-
args: [{ providedIn: 'root' }]
|
|
727
|
-
}], () => [{ type: i1$1__namespace.File }], null); })();
|
|
728
|
-
|
|
729
|
-
const _XMLHttpRequest = window['XMLHttpRequest'];
|
|
730
|
-
const cordova$1 = window['cordova'];
|
|
731
|
-
class Internals {
|
|
732
|
-
constructor(nXhr) {
|
|
733
|
-
this.nXhr = nXhr;
|
|
734
|
-
this.xhr = new _XMLHttpRequest();
|
|
735
|
-
this.method = 'GET';
|
|
736
|
-
this.requestHeaders = {};
|
|
737
|
-
this.responseHeaders = {};
|
|
738
|
-
this.responseHeaderText = '';
|
|
739
|
-
this.url = '';
|
|
740
|
-
this.async = true;
|
|
741
|
-
this.listeners = {};
|
|
742
|
-
}
|
|
743
|
-
triggerListeners(eventName, data) {
|
|
744
|
-
const listeners = this.listeners[eventName];
|
|
745
|
-
if (listeners) {
|
|
746
|
-
listeners.forEach(function (l) {
|
|
747
|
-
l.apply(window, data);
|
|
748
|
-
});
|
|
749
|
-
}
|
|
750
|
-
}
|
|
751
|
-
copyNativeResponse(res) {
|
|
752
|
-
this.nXhr.status = res.status;
|
|
753
|
-
this.nXhr.statusText = res.statusText || res.status;
|
|
754
|
-
this.nXhr.response = res.data;
|
|
755
|
-
this.nXhr.responseType = (res.headers && res.headers['content-type']) || 'plain/text';
|
|
756
|
-
this.nXhr.responseURL = res.responseURL;
|
|
757
|
-
this.nXhr.responseXML = res.responseXML;
|
|
758
|
-
this.nXhr.responseText = (res.data && res.data.toString()) || res.error;
|
|
759
|
-
this.responseHeaderText = (() => {
|
|
760
|
-
const headers = [];
|
|
761
|
-
for (let k in res.headers) {
|
|
762
|
-
headers.push(k + ': ' + res.headers[k]);
|
|
763
|
-
}
|
|
764
|
-
return headers.join('\r\n');
|
|
765
|
-
})();
|
|
766
|
-
}
|
|
767
|
-
copyXMLHttpResponse(req) {
|
|
768
|
-
this.nXhr.status = req.status;
|
|
769
|
-
this.nXhr.statusText = req.statusText;
|
|
770
|
-
this.nXhr.response = req.response;
|
|
771
|
-
this.nXhr.responseType = req.responseType;
|
|
772
|
-
this.nXhr.responseURL = req.responseURL;
|
|
773
|
-
this.nXhr.responseXML = req.responseXML;
|
|
774
|
-
this.nXhr.responseText = req.responseText;
|
|
775
|
-
this.responseHeaderText = req.getAllResponseHeaders();
|
|
776
|
-
this.nXhr.readyState = req.readyState;
|
|
777
|
-
this.nXhr.getResponseHeader = header => req.getResponseHeader(header);
|
|
778
|
-
}
|
|
779
|
-
sendViaXhr(body) {
|
|
780
|
-
const self = this;
|
|
781
|
-
this.xhr.onreadystatechange = () => {
|
|
782
|
-
self.copyXMLHttpResponse(self.xhr);
|
|
783
|
-
this.nXhr.onreadystatechange && this.nXhr.onreadystatechange();
|
|
784
|
-
};
|
|
785
|
-
this.xhr.onload = function () {
|
|
786
|
-
self.copyXMLHttpResponse(self.xhr);
|
|
787
|
-
if (self.nXhr.onload) {
|
|
788
|
-
self.nXhr.onload.apply(self.nXhr, arguments);
|
|
789
|
-
}
|
|
790
|
-
};
|
|
791
|
-
this.xhr.onerror = this.nXhr.onerror;
|
|
792
|
-
if (!this.async) {
|
|
793
|
-
this.xhr.ontimeout = this.nXhr.ontimeout;
|
|
794
|
-
this.xhr.timeout = this.nXhr.timeout;
|
|
795
|
-
}
|
|
796
|
-
this.xhr.withCredentials = this.nXhr.withCredentials;
|
|
797
|
-
for (let k in this.listeners) {
|
|
798
|
-
this.xhr.addEventListener(k, e => {
|
|
799
|
-
this.copyXMLHttpResponse(this.xhr);
|
|
800
|
-
this.triggerListeners(e.type);
|
|
801
|
-
});
|
|
802
|
-
}
|
|
803
|
-
this.xhr.send(body);
|
|
804
|
-
}
|
|
805
|
-
close() {
|
|
806
|
-
for (let k in this.listeners) {
|
|
807
|
-
this.listeners[k].length = 0;
|
|
808
|
-
}
|
|
809
|
-
}
|
|
810
|
-
}
|
|
811
|
-
class NativeXMLHttpRequest {
|
|
812
|
-
constructor() {
|
|
813
|
-
this.onreadystatechange = null;
|
|
814
|
-
this.readyState = 0;
|
|
815
|
-
this.response = null;
|
|
816
|
-
this.responseType = null;
|
|
817
|
-
this.responseText = null;
|
|
818
|
-
this.responseURL = null;
|
|
819
|
-
this.responseXML = null;
|
|
820
|
-
this.status = 0;
|
|
821
|
-
this.statusText = '';
|
|
822
|
-
this.ontimeout = null;
|
|
823
|
-
this.onload = null;
|
|
824
|
-
this.onloadend = null;
|
|
825
|
-
this.onerror = null;
|
|
826
|
-
this.timeout = 0;
|
|
827
|
-
this.withCredentials = false;
|
|
828
|
-
this.progress = {
|
|
829
|
-
lengthComputable: false,
|
|
830
|
-
loaded: 0,
|
|
831
|
-
total: 0,
|
|
832
|
-
close: (success = false) => { }
|
|
833
|
-
};
|
|
834
|
-
this.upload = {
|
|
835
|
-
addEventListener: this.addEventListener.bind(this)
|
|
836
|
-
};
|
|
837
|
-
this._internal = new Internals(this);
|
|
838
|
-
}
|
|
839
|
-
abort() {
|
|
840
|
-
this.status = -1;
|
|
841
|
-
this._internal.triggerListeners("error" /* EVENT.ERROR */);
|
|
842
|
-
this.onerror && this.onerror();
|
|
843
|
-
this._internal.xhr.abort();
|
|
844
|
-
this.close();
|
|
845
|
-
}
|
|
846
|
-
getResponseHeader(name) {
|
|
847
|
-
return this.response.headers[name];
|
|
848
|
-
}
|
|
849
|
-
getAllResponseHeaders() {
|
|
850
|
-
return this._internal.responseHeaderText;
|
|
851
|
-
}
|
|
852
|
-
setRequestHeader(header, value) {
|
|
853
|
-
this._internal.requestHeaders[header] = value;
|
|
854
|
-
this._internal.xhr.setRequestHeader(header, value);
|
|
855
|
-
}
|
|
856
|
-
overrideMimeType(mime) {
|
|
857
|
-
this._internal.xhr.overrideMimeType(mime);
|
|
858
|
-
}
|
|
859
|
-
open(method, url, async = true, user, password) {
|
|
860
|
-
this._internal.method = method;
|
|
861
|
-
this._internal.url = url;
|
|
862
|
-
this._internal.async = async;
|
|
863
|
-
this._internal.xhr.open(method, url, async, user, password);
|
|
864
|
-
}
|
|
865
|
-
send(body, useBrowserXHR = false) {
|
|
866
|
-
if (useBrowserXHR
|
|
867
|
-
|| this._internal.url.startsWith('http://localhost')
|
|
868
|
-
|| !this._internal.url.startsWith('http')) {
|
|
869
|
-
this._internal.sendViaXhr(body);
|
|
870
|
-
}
|
|
871
|
-
else if (this.responseType === 'blob') {
|
|
872
|
-
this.sendBlobViaNativePlugin(body);
|
|
873
|
-
}
|
|
874
|
-
else {
|
|
875
|
-
this.sendViaNativePlugin(body);
|
|
876
|
-
}
|
|
877
|
-
}
|
|
878
|
-
;
|
|
879
|
-
addEventListener(eventName, handler) {
|
|
880
|
-
this._internal.listeners[eventName] = this._internal.listeners[eventName] || [];
|
|
881
|
-
this._internal.listeners[eventName].push(handler);
|
|
882
|
-
}
|
|
883
|
-
removeEventListener(eventName, handler) {
|
|
884
|
-
if (this._internal.listeners[eventName]) {
|
|
885
|
-
const i = this._internal.listeners[eventName].indexOf(handler);
|
|
886
|
-
this._internal.listeners[eventName].splice(i, 1);
|
|
887
|
-
}
|
|
888
|
-
}
|
|
889
|
-
prepareOptions(body) {
|
|
890
|
-
body = body || {};
|
|
891
|
-
const options = {
|
|
892
|
-
headers: {},
|
|
893
|
-
data: body,
|
|
894
|
-
method: this._internal.method,
|
|
895
|
-
serializer: 'raw'
|
|
896
|
-
};
|
|
897
|
-
if (body != null && body != undefined) {
|
|
898
|
-
if (body.constructor && body.constructor.toString().indexOf('FormData()') >= 0) {
|
|
899
|
-
options.serializer = 'multipart';
|
|
900
|
-
this.startProgress();
|
|
901
|
-
}
|
|
902
|
-
else if (typeof body === 'string') {
|
|
903
|
-
options.serializer = 'utf8';
|
|
904
|
-
}
|
|
905
|
-
else {
|
|
906
|
-
options.serializer = 'urlencoded';
|
|
907
|
-
}
|
|
908
|
-
}
|
|
909
|
-
for (let key in this._internal.requestHeaders) {
|
|
910
|
-
options.headers[key] = this._internal.requestHeaders[key];
|
|
911
|
-
}
|
|
912
|
-
return options;
|
|
913
|
-
}
|
|
914
|
-
/*
|
|
915
|
-
* Native plugin didn't provide any API to track upload progress.
|
|
916
|
-
* This method generates a synthetic event which does not co-relates with the actual upload progress.
|
|
917
|
-
*/
|
|
918
|
-
startProgress(total) {
|
|
919
|
-
const _1mb = 1024 * 1024 * 8;
|
|
920
|
-
total = total || _1mb;
|
|
921
|
-
const interval = Math.ceil(total / _1mb) * 200;
|
|
922
|
-
const slice = Math.ceil(total / _1mb) * (_1mb / 10);
|
|
923
|
-
this.progress = {
|
|
924
|
-
lengthComputable: true,
|
|
925
|
-
loaded: 0,
|
|
926
|
-
total: total,
|
|
927
|
-
close: null
|
|
928
|
-
};
|
|
929
|
-
const triggerEvent = () => {
|
|
930
|
-
this._internal.triggerListeners("progress" /* EVENT.PROGRESS */, [{
|
|
931
|
-
lengthComputable: true,
|
|
932
|
-
total: this.progress.total,
|
|
933
|
-
loaded: this.progress.loaded
|
|
934
|
-
}]);
|
|
935
|
-
};
|
|
936
|
-
const intervalId = setInterval(() => {
|
|
937
|
-
if (this.progress.loaded + slice < total) {
|
|
938
|
-
this.progress.loaded += slice;
|
|
939
|
-
}
|
|
940
|
-
triggerEvent();
|
|
941
|
-
}, interval);
|
|
942
|
-
this.progress.close = (success = false) => {
|
|
943
|
-
if (success) {
|
|
944
|
-
this.progress.loaded = this.progress.total;
|
|
945
|
-
}
|
|
946
|
-
triggerEvent();
|
|
947
|
-
clearInterval(intervalId);
|
|
948
|
-
};
|
|
949
|
-
}
|
|
950
|
-
sendBlobViaNativePlugin(body) {
|
|
951
|
-
const options = this.prepareOptions(body);
|
|
952
|
-
const tempfile = (i2$2.isIos() ? cordova$1.file.tempDirectory : cordova$1.file.cacheDirectory) + Date.now();
|
|
953
|
-
const timerId = setTimeout(() => {
|
|
954
|
-
if (this.timeout > 0) {
|
|
955
|
-
console.error('network call with request %O failed with timeout', this);
|
|
956
|
-
this._internal.triggerListeners("load" /* EVENT.LOAD */);
|
|
957
|
-
this._internal.triggerListeners("error" /* EVENT.ERROR */);
|
|
958
|
-
this.onerror && this.onerror();
|
|
959
|
-
this.ontimeout && this.ontimeout();
|
|
960
|
-
this.close();
|
|
961
|
-
}
|
|
962
|
-
}, this.timeout > 0 ? this.timeout : 1);
|
|
963
|
-
const onSuccess = (file, response) => {
|
|
964
|
-
const res = {
|
|
965
|
-
headers: (response && response.headers) || {},
|
|
966
|
-
status: 200,
|
|
967
|
-
data: file
|
|
968
|
-
};
|
|
969
|
-
let contentType = (response && response.headers && response.headers['content-type']);
|
|
970
|
-
if (contentType) {
|
|
971
|
-
res.data.type = contentType.split(';')[0];
|
|
972
|
-
}
|
|
973
|
-
console.log('network call with request %O successed with response : %O', this, res);
|
|
974
|
-
this._internal.copyNativeResponse(res);
|
|
975
|
-
this._internal.triggerListeners("load" /* EVENT.LOAD */);
|
|
976
|
-
this.onload && this.onload();
|
|
977
|
-
this.onloadend && this.onloadend();
|
|
978
|
-
clearTimeout(timerId);
|
|
979
|
-
this.readyState = 4;
|
|
980
|
-
this.onreadystatechange && this.onreadystatechange();
|
|
981
|
-
};
|
|
982
|
-
const onError = (response) => {
|
|
983
|
-
console.error('network call with request %O failed with response : %O', this, response);
|
|
984
|
-
this._internal.triggerListeners("load" /* EVENT.LOAD */, [response]);
|
|
985
|
-
this._internal.triggerListeners("error" /* EVENT.ERROR */, [response]);
|
|
986
|
-
this.onerror && this.onerror();
|
|
987
|
-
this.onloadend && this.onloadend();
|
|
988
|
-
clearTimeout(timerId);
|
|
989
|
-
this.readyState = 4;
|
|
990
|
-
this.onreadystatechange && this.onreadystatechange();
|
|
991
|
-
};
|
|
992
|
-
cordova$1.plugin.http.downloadFile(new URL(this._internal.url).href, {}, options.headers, tempfile, (entry, response) => {
|
|
993
|
-
entry.file(f => onSuccess(f, response), onError);
|
|
994
|
-
}, onError);
|
|
995
|
-
this.readyState = 1;
|
|
996
|
-
this.onreadystatechange && this.onreadystatechange();
|
|
997
|
-
}
|
|
998
|
-
sendViaNativePlugin(body) {
|
|
999
|
-
const options = this.prepareOptions(body);
|
|
1000
|
-
const timerId = setTimeout(() => {
|
|
1001
|
-
if (this.timeout > 0) {
|
|
1002
|
-
console.error('network call with request %O failed with timeout', this);
|
|
1003
|
-
this._internal.triggerListeners("load" /* EVENT.LOAD */);
|
|
1004
|
-
this._internal.triggerListeners("error" /* EVENT.ERROR */);
|
|
1005
|
-
this.ontimeout && this.ontimeout();
|
|
1006
|
-
this.close();
|
|
1007
|
-
}
|
|
1008
|
-
}, this.timeout > 0 ? this.timeout : 1);
|
|
1009
|
-
new Promise((resolve, reject) => {
|
|
1010
|
-
cordova$1.plugin.http.sendRequest(new URL(this._internal.url).href, options, resolve, reject);
|
|
1011
|
-
this.readyState = 1;
|
|
1012
|
-
this.onreadystatechange && this.onreadystatechange();
|
|
1013
|
-
}).then(response => {
|
|
1014
|
-
console.log('network call with request %O successed with response : %O', this, response);
|
|
1015
|
-
this.progress.close(true);
|
|
1016
|
-
this._internal.copyNativeResponse(response);
|
|
1017
|
-
this._internal.triggerListeners("load" /* EVENT.LOAD */);
|
|
1018
|
-
this.onload && this.onload();
|
|
1019
|
-
this.onloadend && this.onloadend();
|
|
1020
|
-
}, response => {
|
|
1021
|
-
this.progress.close();
|
|
1022
|
-
this._internal.copyNativeResponse(response);
|
|
1023
|
-
console.error('network call with request %O failed with response : %O', this, response);
|
|
1024
|
-
this._internal.triggerListeners("load" /* EVENT.LOAD */, [response]);
|
|
1025
|
-
this._internal.triggerListeners("error" /* EVENT.ERROR */, [response]);
|
|
1026
|
-
this.onerror && this.onerror();
|
|
1027
|
-
this.onloadend && this.onloadend();
|
|
1028
|
-
}).finally(() => {
|
|
1029
|
-
this.readyState = 4;
|
|
1030
|
-
this.onreadystatechange && this.onreadystatechange();
|
|
1031
|
-
clearTimeout(timerId);
|
|
1032
|
-
});
|
|
1033
|
-
}
|
|
1034
|
-
close() {
|
|
1035
|
-
this.ontimeout = null;
|
|
1036
|
-
this.onload = null;
|
|
1037
|
-
this.onerror = null;
|
|
1038
|
-
this.onreadystatechange = null;
|
|
1039
|
-
this._internal.close();
|
|
1040
|
-
}
|
|
1041
|
-
}
|
|
1042
|
-
|
|
1043
|
-
const AUTO_CONNECT_KEY = 'WM.NetworkService._autoConnect', IS_CONNECTED_KEY = 'WM.NetworkService.isConnected', excludedList = [new RegExp('/wmProperties.js')], networkState = {
|
|
1044
|
-
isConnecting: false,
|
|
1045
|
-
isConnected: true,
|
|
1046
|
-
isNetworkAvailable: true,
|
|
1047
|
-
isServiceAvailable: true,
|
|
1048
|
-
noServiceRequired: false
|
|
1049
|
-
};
|
|
1050
|
-
let XML_HTTP_REQUEST = null;
|
|
1051
|
-
/**
|
|
1052
|
-
* If server is not connected and url does not match the unblock list of regular expressions,
|
|
1053
|
-
* then this function return true. Otherwise, return false.
|
|
1054
|
-
* @param url
|
|
1055
|
-
* @returns {boolean}
|
|
1056
|
-
*/
|
|
1057
|
-
const blockUrl = url => {
|
|
1058
|
-
let block = !networkState.isConnected && lodashEs.startsWith(url, 'http');
|
|
1059
|
-
if (block) {
|
|
1060
|
-
block = !lodashEs.find(excludedList, regExp => regExp.test(url));
|
|
1061
|
-
}
|
|
1062
|
-
return block;
|
|
1063
|
-
};
|
|
1064
|
-
const getXMLHttpRequestToUse = ((useNativeXHR) => {
|
|
1065
|
-
const clazz = useNativeXHR ? NativeXMLHttpRequest : XMLHttpRequest;
|
|
1066
|
-
const orig = clazz.prototype.open;
|
|
1067
|
-
// Intercept all XHR calls
|
|
1068
|
-
clazz.prototype.open = function (method, url, async = true, user, password) {
|
|
1069
|
-
if (!networkState.noServiceRequired && blockUrl(url)) {
|
|
1070
|
-
const urlSplits = url.split('://');
|
|
1071
|
-
const pathIndex = urlSplits[1].indexOf('/');
|
|
1072
|
-
urlSplits[1] = 'localhost' + (pathIndex > 0 ? urlSplits[1].substr(pathIndex) : '/');
|
|
1073
|
-
url = urlSplits.join('://');
|
|
1074
|
-
}
|
|
1075
|
-
return orig.apply(this, [method, url, async, user, password]);
|
|
1076
|
-
};
|
|
1077
|
-
return clazz;
|
|
1078
|
-
});
|
|
1079
|
-
class NetworkService {
|
|
1080
|
-
static { this.SERVICE_NAME = 'NetworkService'; }
|
|
1081
|
-
constructor(httpClient, app, network, deviceService) {
|
|
1082
|
-
this.httpClient = httpClient;
|
|
1083
|
-
this.app = app;
|
|
1084
|
-
this.network = network;
|
|
1085
|
-
this.deviceService = deviceService;
|
|
1086
|
-
this._autoConnect = localStorage.getItem(AUTO_CONNECT_KEY) !== 'false';
|
|
1087
|
-
this._isCheckingServer = false;
|
|
1088
|
-
/**
|
|
1089
|
-
* When the auto connect is enabled, then app is automatically connected whenever server is available.
|
|
1090
|
-
* Every time when app goes offline, auto connect is enabled. Before app coming to online, one can disable
|
|
1091
|
-
* the auto connection flow using this method.
|
|
1092
|
-
*/
|
|
1093
|
-
this.disableAutoConnect = () => this.setAutoConnect(false);
|
|
1094
|
-
/**
|
|
1095
|
-
* Returns true, if app is connected to server. Otherwise, returns false.
|
|
1096
|
-
*
|
|
1097
|
-
* @returns {boolean} Returns true, if app is connected to server. Otherwise, returns false.
|
|
1098
|
-
*/
|
|
1099
|
-
this.isConnected = () => {
|
|
1100
|
-
// checking for connection type.
|
|
1101
|
-
if (lodashEs.get(navigator, 'connection') && navigator.connection.type) {
|
|
1102
|
-
networkState.isConnected = networkState.isConnected && (navigator.connection.type !== 'none');
|
|
1103
|
-
}
|
|
1104
|
-
this.checkForNetworkStateChange();
|
|
1105
|
-
return networkState.isConnected;
|
|
1106
|
-
};
|
|
1107
|
-
/**
|
|
1108
|
-
* Returns true if app is trying to connect to server. Otherwise, returns false.
|
|
1109
|
-
*
|
|
1110
|
-
* @returns {boolean} Returns true if app is trying to connect to server. Otherwise, returns false.
|
|
1111
|
-
*/
|
|
1112
|
-
this.isConnecting = () => networkState.isConnecting;
|
|
1113
|
-
networkState.isConnected = localStorage.getItem(IS_CONNECTED_KEY) === 'true';
|
|
1114
|
-
XML_HTTP_REQUEST = XML_HTTP_REQUEST || getXMLHttpRequestToUse(deviceService.useNativeXHR());
|
|
1115
|
-
}
|
|
1116
|
-
/**
|
|
1117
|
-
* This method attempts to connect app to the server and returns a promise that will be resolved with
|
|
1118
|
-
* a boolean value based on the operation result.
|
|
1119
|
-
*
|
|
1120
|
-
* @returns {object} promise
|
|
1121
|
-
*/
|
|
1122
|
-
connect() {
|
|
1123
|
-
this.setAutoConnect(true);
|
|
1124
|
-
return this.tryToConnect();
|
|
1125
|
-
}
|
|
1126
|
-
/**
|
|
1127
|
-
* This method disconnects the app from the server and returns a promise that will be resolved with
|
|
1128
|
-
* a boolean value based on the operation result. Use connect method to reconnect.
|
|
1129
|
-
*
|
|
1130
|
-
* @returns {object} promise
|
|
1131
|
-
*/
|
|
1132
|
-
disconnect() {
|
|
1133
|
-
const p = this.tryToDisconnect();
|
|
1134
|
-
this.disableAutoConnect();
|
|
1135
|
-
return p;
|
|
1136
|
-
}
|
|
1137
|
-
/**
|
|
1138
|
-
* If pingServer is true, then it returns a promise that will be resolved with boolean based on service availability
|
|
1139
|
-
* check.If pingServer is false, returns a boolean value based on the last known service availability.
|
|
1140
|
-
*
|
|
1141
|
-
* @returns {boolean} if pingServer is true, then a promise is returned. Otherwise, a boolean value.
|
|
1142
|
-
*/
|
|
1143
|
-
isAvailable(pingServer = false) {
|
|
1144
|
-
if (pingServer) {
|
|
1145
|
-
return this.isServiceAvailable().then(() => {
|
|
1146
|
-
this.checkForNetworkStateChange();
|
|
1147
|
-
return networkState.isServiceAvailable;
|
|
1148
|
-
});
|
|
1149
|
-
}
|
|
1150
|
-
return networkState.isServiceAvailable;
|
|
1151
|
-
}
|
|
1152
|
-
/**
|
|
1153
|
-
* This method returns a promise that is resolved when connection is established with server.
|
|
1154
|
-
*
|
|
1155
|
-
* @returns {object} promise a promise that is resolved with the returned object of fn
|
|
1156
|
-
*/
|
|
1157
|
-
onConnect() {
|
|
1158
|
-
let defer, cancelSubscription;
|
|
1159
|
-
if (this.isConnected()) {
|
|
1160
|
-
return Promise.resolve();
|
|
1161
|
-
}
|
|
1162
|
-
defer = i2$2.getAbortableDefer();
|
|
1163
|
-
cancelSubscription = this.app.subscribe('onNetworkStateChange', () => {
|
|
1164
|
-
if (this.isConnected()) {
|
|
1165
|
-
defer.resolve(true);
|
|
1166
|
-
cancelSubscription();
|
|
1167
|
-
}
|
|
1168
|
-
});
|
|
1169
|
-
defer.promise.catch(function () {
|
|
1170
|
-
cancelSubscription();
|
|
1171
|
-
});
|
|
1172
|
-
return defer.promise;
|
|
1173
|
-
}
|
|
1174
|
-
/**
|
|
1175
|
-
* This is a util method. If fn cannot execute successfully and network lost connection, then the fn will
|
|
1176
|
-
* be invoked when network is back. The returned can also be aborted.
|
|
1177
|
-
*
|
|
1178
|
-
* @param {function()} fn method to invoke.
|
|
1179
|
-
* @returns {object} promise a promise that is resolved with the returned object of fn
|
|
1180
|
-
*/
|
|
1181
|
-
retryIfNetworkFails(fn) {
|
|
1182
|
-
const defer = i2$2.getAbortableDefer();
|
|
1183
|
-
i2$2.retryIfFails(fn, 0, 0, () => {
|
|
1184
|
-
let onConnectPromise;
|
|
1185
|
-
if (!this.isConnected()) {
|
|
1186
|
-
onConnectPromise = this.onConnect();
|
|
1187
|
-
defer.promise.catch(function () {
|
|
1188
|
-
onConnectPromise.abort();
|
|
1189
|
-
});
|
|
1190
|
-
return onConnectPromise;
|
|
1191
|
-
}
|
|
1192
|
-
return false;
|
|
1193
|
-
}).then(defer.resolve, defer.reject);
|
|
1194
|
-
return defer.promise;
|
|
1195
|
-
}
|
|
1196
|
-
start() {
|
|
1197
|
-
if (window['cordova']) {
|
|
1198
|
-
// Connection constant will be available only when network plugin is included.
|
|
1199
|
-
if (window['Connection'] && navigator.connection) {
|
|
1200
|
-
networkState.isNetworkAvailable = navigator.connection.type !== 'none';
|
|
1201
|
-
networkState.isConnected = networkState.isNetworkAvailable && networkState.isConnected;
|
|
1202
|
-
/*
|
|
1203
|
-
* When the device comes online, check is the service is available. If the service is available and auto
|
|
1204
|
-
* connect flag is true, then app is automatically connected to remote server.
|
|
1205
|
-
*/
|
|
1206
|
-
this.network.onConnect().subscribe(() => {
|
|
1207
|
-
networkState.isNetworkAvailable = true;
|
|
1208
|
-
this.tryToConnect().catch(i2$2.noop);
|
|
1209
|
-
});
|
|
1210
|
-
/*
|
|
1211
|
-
*When device goes offline, then change the network state and emit that notifies about network state change.
|
|
1212
|
-
*/
|
|
1213
|
-
this.network.onDisconnect().subscribe(() => {
|
|
1214
|
-
networkState.isNetworkAvailable = false;
|
|
1215
|
-
networkState.isServiceAvailable = false;
|
|
1216
|
-
this.tryToDisconnect();
|
|
1217
|
-
});
|
|
1218
|
-
this.app.subscribe('onNetworkStateChange', (data) => {
|
|
1219
|
-
/**
|
|
1220
|
-
* If network is available and server is not available,then
|
|
1221
|
-
* try to connect when server is available.
|
|
1222
|
-
*/
|
|
1223
|
-
if (data.isNetworkAvailable && !data.isServiceAvailable && !this._isCheckingServer && !data.noServiceRequired) {
|
|
1224
|
-
this._isCheckingServer = true;
|
|
1225
|
-
this.checkForServiceAvailiblity().then(() => {
|
|
1226
|
-
this._isCheckingServer = false;
|
|
1227
|
-
this.connect();
|
|
1228
|
-
}, () => {
|
|
1229
|
-
this._isCheckingServer = false;
|
|
1230
|
-
});
|
|
1231
|
-
}
|
|
1232
|
-
});
|
|
1233
|
-
}
|
|
1234
|
-
}
|
|
1235
|
-
// to set the default n/w connection values.
|
|
1236
|
-
return this.tryToConnect(true).catch(i2$2.noop);
|
|
1237
|
-
}
|
|
1238
|
-
getServiceName() {
|
|
1239
|
-
return NetworkService.SERVICE_NAME;
|
|
1240
|
-
}
|
|
1241
|
-
/**
|
|
1242
|
-
* This function adds the given regular expression to the unblockList. Even app is in offline mode,
|
|
1243
|
-
* the urls matching with the given regular expression are not blocked by NetworkService.
|
|
1244
|
-
*
|
|
1245
|
-
* @param {string} urlRegex regular expression
|
|
1246
|
-
*/
|
|
1247
|
-
unblock(urlRegex) {
|
|
1248
|
-
excludedList.push(new RegExp(urlRegex));
|
|
1249
|
-
}
|
|
1250
|
-
getState() {
|
|
1251
|
-
return lodashEs.clone(networkState);
|
|
1252
|
-
}
|
|
1253
|
-
checkForNetworkStateChange() {
|
|
1254
|
-
if (!lodashEs.isEqual(this._lastKnownNetworkState, networkState)) {
|
|
1255
|
-
this._lastKnownNetworkState = lodashEs.clone(networkState);
|
|
1256
|
-
this.app.notify('onNetworkStateChange', this._lastKnownNetworkState);
|
|
1257
|
-
}
|
|
1258
|
-
}
|
|
1259
|
-
/**
|
|
1260
|
-
* Returns a promise that is resolved when server is available.
|
|
1261
|
-
* @returns {*}
|
|
1262
|
-
*/
|
|
1263
|
-
checkForServiceAvailiblity() {
|
|
1264
|
-
const maxTimeout = 4500;
|
|
1265
|
-
return new Promise(resolve => {
|
|
1266
|
-
const intervalId = setInterval(() => {
|
|
1267
|
-
if (networkState.isNetworkAvailable) {
|
|
1268
|
-
this.isServiceAvailable(maxTimeout).then(available => {
|
|
1269
|
-
if (available) {
|
|
1270
|
-
clearInterval(intervalId);
|
|
1271
|
-
resolve();
|
|
1272
|
-
}
|
|
1273
|
-
});
|
|
1274
|
-
}
|
|
1275
|
-
}, 5000);
|
|
1276
|
-
});
|
|
1277
|
-
}
|
|
1278
|
-
/**
|
|
1279
|
-
* Pings server to check whether server is available. Based on ping response network state is modified.
|
|
1280
|
-
* @returns {*} a promise that resolved with true, if server responds with valid status.
|
|
1281
|
-
* Otherwise, the promise is resolved with false.
|
|
1282
|
-
*/
|
|
1283
|
-
isServiceAvailable(maxTimeout) {
|
|
1284
|
-
if (this.app.deployedUrl === 'NONE') {
|
|
1285
|
-
networkState.isServiceAvailable = false;
|
|
1286
|
-
networkState.noServiceRequired = true;
|
|
1287
|
-
return Promise.resolve(false);
|
|
1288
|
-
}
|
|
1289
|
-
return this.pingServer(maxTimeout).then(response => {
|
|
1290
|
-
networkState.isServiceAvailable = response;
|
|
1291
|
-
if (!networkState.isServiceAvailable) {
|
|
1292
|
-
networkState.isConnecting = false;
|
|
1293
|
-
networkState.isConnected = false;
|
|
1294
|
-
}
|
|
1295
|
-
return response;
|
|
1296
|
-
});
|
|
1297
|
-
}
|
|
1298
|
-
/**
|
|
1299
|
-
* Pings server
|
|
1300
|
-
* @returns {*} a promise that resolved with true, if server responds with valid status.
|
|
1301
|
-
* Otherwise, the promise is resolved with false.
|
|
1302
|
-
* default timeout value is 1min.
|
|
1303
|
-
*/
|
|
1304
|
-
pingServer(maxTimeout = 60000) {
|
|
1305
|
-
return new Promise(resolve => {
|
|
1306
|
-
const oReq = new XML_HTTP_REQUEST();
|
|
1307
|
-
let baseURL = this.app.deployedUrl;
|
|
1308
|
-
if (baseURL && !lodashEs.endsWith(baseURL, '/')) {
|
|
1309
|
-
baseURL += '/';
|
|
1310
|
-
}
|
|
1311
|
-
else {
|
|
1312
|
-
baseURL = baseURL || '';
|
|
1313
|
-
}
|
|
1314
|
-
const timer = setTimeout(() => {
|
|
1315
|
-
oReq.abort(); // abort request
|
|
1316
|
-
resolve(false);
|
|
1317
|
-
}, maxTimeout);
|
|
1318
|
-
oReq.addEventListener('load', () => {
|
|
1319
|
-
if (oReq.status === 200) {
|
|
1320
|
-
resolve(true);
|
|
1321
|
-
}
|
|
1322
|
-
else {
|
|
1323
|
-
resolve(false);
|
|
1324
|
-
}
|
|
1325
|
-
if (timer) {
|
|
1326
|
-
clearTimeout(timer);
|
|
1327
|
-
}
|
|
1328
|
-
});
|
|
1329
|
-
oReq.addEventListener('error', () => resolve(false));
|
|
1330
|
-
oReq.open('GET', baseURL + 'services/application/wmProperties.js?t=' + Date.now());
|
|
1331
|
-
oReq.send();
|
|
1332
|
-
});
|
|
1333
|
-
}
|
|
1334
|
-
setAutoConnect(flag) {
|
|
1335
|
-
this._autoConnect = flag;
|
|
1336
|
-
localStorage.setItem(AUTO_CONNECT_KEY, '' + flag);
|
|
1337
|
-
}
|
|
1338
|
-
/**
|
|
1339
|
-
* Tries to connect to remote server. Network State will be changed based on the success of connection
|
|
1340
|
-
* operation and emits an event notifying the network state change.
|
|
1341
|
-
*
|
|
1342
|
-
* @param silentMode {boolean} if true and connection is successful, then no event is emitted. Otherwise,
|
|
1343
|
-
* events are emitted for network status change.
|
|
1344
|
-
* @returns {*} a promise
|
|
1345
|
-
*/
|
|
1346
|
-
tryToConnect(silentMode = false) {
|
|
1347
|
-
return new Promise((resolve, reject) => {
|
|
1348
|
-
this.isServiceAvailable(5000).then(() => {
|
|
1349
|
-
if (networkState.isServiceAvailable && this._autoConnect) {
|
|
1350
|
-
networkState.isConnecting = true;
|
|
1351
|
-
if (!silentMode) {
|
|
1352
|
-
this.checkForNetworkStateChange();
|
|
1353
|
-
}
|
|
1354
|
-
setTimeout(() => {
|
|
1355
|
-
networkState.isConnecting = false;
|
|
1356
|
-
networkState.isConnected = true;
|
|
1357
|
-
localStorage.setItem(IS_CONNECTED_KEY, '' + true);
|
|
1358
|
-
if (!silentMode) {
|
|
1359
|
-
this.checkForNetworkStateChange();
|
|
1360
|
-
}
|
|
1361
|
-
resolve(true);
|
|
1362
|
-
}, silentMode ? 0 : 5000);
|
|
1363
|
-
}
|
|
1364
|
-
else {
|
|
1365
|
-
networkState.isConnecting = false;
|
|
1366
|
-
networkState.isConnected = false;
|
|
1367
|
-
localStorage.setItem(IS_CONNECTED_KEY, '' + false);
|
|
1368
|
-
reject();
|
|
1369
|
-
this.checkForNetworkStateChange();
|
|
1370
|
-
}
|
|
1371
|
-
});
|
|
1372
|
-
});
|
|
1373
|
-
}
|
|
1374
|
-
tryToDisconnect() {
|
|
1375
|
-
networkState.isConnected = false;
|
|
1376
|
-
networkState.isConnecting = false;
|
|
1377
|
-
this.checkForNetworkStateChange();
|
|
1378
|
-
localStorage.setItem(IS_CONNECTED_KEY, '' + networkState.isConnected);
|
|
1379
|
-
return Promise.resolve(networkState.isConnected);
|
|
1380
|
-
}
|
|
1381
|
-
static { this.ɵfac = function NetworkService_Factory(__ngFactoryType__) { return new (__ngFactoryType__ || NetworkService)(i0__namespace.ɵɵinject(i2__namespace.HttpClient), i0__namespace.ɵɵinject(i2$2__namespace.App), i0__namespace.ɵɵinject(i3__namespace.Network), i0__namespace.ɵɵinject(DeviceService)); }; }
|
|
1382
|
-
static { this.ɵprov = /*@__PURE__*/ i0__namespace.ɵɵdefineInjectable({ token: NetworkService, factory: NetworkService.ɵfac, providedIn: 'root' }); }
|
|
1383
|
-
}
|
|
1384
|
-
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0__namespace.ɵsetClassMetadata(NetworkService, [{
|
|
1385
|
-
type: i0.Injectable,
|
|
1386
|
-
args: [{ providedIn: 'root' }]
|
|
1387
|
-
}], () => [{ type: i2__namespace.HttpClient }, { type: i2$2__namespace.App }, { type: i3__namespace.Network }, { type: DeviceService }], null); })();
|
|
1388
|
-
|
|
1389
|
-
class MobileCoreModule {
|
|
1390
|
-
static { this.initialized = false; }
|
|
1391
|
-
// Startup services have to be added only once in the app life-cycle.
|
|
1392
|
-
static addStartupServices(deviceService, deviceFileService, fileCacheService, fileOpener, networkService) {
|
|
1393
|
-
if (this.initialized) {
|
|
1394
|
-
return;
|
|
1395
|
-
}
|
|
1396
|
-
deviceService.addStartUpService(networkService);
|
|
1397
|
-
if (i2$2.hasCordova()) {
|
|
1398
|
-
deviceService.addStartUpService(deviceFileService);
|
|
1399
|
-
deviceService.addStartUpService(fileCacheService);
|
|
1400
|
-
deviceService.addStartUpService(fileOpener);
|
|
1401
|
-
}
|
|
1402
|
-
this.initialized = true;
|
|
1403
|
-
}
|
|
1404
|
-
constructor(deviceService, deviceFileService, fileCacheService, fileOpener, networkService) {
|
|
1405
|
-
MobileCoreModule.addStartupServices(deviceService, deviceFileService, fileCacheService, fileOpener, networkService);
|
|
1406
|
-
const isSSLPinningEnabled = deviceService.getConfig().enableSSLPinning;
|
|
1407
|
-
if (i2$2.hasCordova()) {
|
|
1408
|
-
document.addEventListener('wmDeviceReady', () => {
|
|
1409
|
-
if (deviceService.useNativeXHR()) {
|
|
1410
|
-
// ### ANGULAR9TODO###
|
|
1411
|
-
// Adding type as any to avoid error TS2739:
|
|
1412
|
-
window['XMLHttpRequest'] = NativeXMLHttpRequest;
|
|
1413
|
-
if (isSSLPinningEnabled) {
|
|
1414
|
-
cordova.plugin.http.setServerTrustMode('pinned', () => {
|
|
1415
|
-
console.log('SSL Pinning enabled.!');
|
|
1416
|
-
}, e => {
|
|
1417
|
-
console.log('Failed to enable SSL Pinning. Due to: ' + e);
|
|
1418
|
-
});
|
|
1419
|
-
}
|
|
1420
|
-
this.overrideResolveLocalFileSystemURL();
|
|
1421
|
-
}
|
|
1422
|
-
}, false);
|
|
1423
|
-
}
|
|
1424
|
-
}
|
|
1425
|
-
overrideResolveLocalFileSystemURL() {
|
|
1426
|
-
const or = window['resolveLocalFileSystemURL'];
|
|
1427
|
-
window['resolveLocalFileSystemURL'] = (path, onSuccess, onError) => {
|
|
1428
|
-
if (path && path.startsWith('http://localhost')) {
|
|
1429
|
-
path = new URL(path).pathname;
|
|
1430
|
-
const lf = '/local-filesystem';
|
|
1431
|
-
if (path.startsWith(lf)) {
|
|
1432
|
-
path = 'file://' + path.substring(lf.length);
|
|
1433
|
-
}
|
|
1434
|
-
}
|
|
1435
|
-
or.call(window, path, onSuccess, onError);
|
|
1436
|
-
};
|
|
1437
|
-
}
|
|
1438
|
-
static { this.ɵfac = function MobileCoreModule_Factory(__ngFactoryType__) { return new (__ngFactoryType__ || MobileCoreModule)(i0__namespace.ɵɵinject(DeviceService), i0__namespace.ɵɵinject(DeviceFileService), i0__namespace.ɵɵinject(DeviceFileCacheService), i0__namespace.ɵɵinject(DeviceFileOpenerService), i0__namespace.ɵɵinject(NetworkService)); }; }
|
|
1439
|
-
static { this.ɵmod = /*@__PURE__*/ i0__namespace.ɵɵdefineNgModule({ type: MobileCoreModule }); }
|
|
1440
|
-
static { this.ɵinj = /*@__PURE__*/ i0__namespace.ɵɵdefineInjector({}); }
|
|
1441
|
-
}
|
|
1442
|
-
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0__namespace.ɵsetClassMetadata(MobileCoreModule, [{
|
|
1443
|
-
type: i0.NgModule,
|
|
1444
|
-
args: [{
|
|
1445
|
-
declarations: [],
|
|
1446
|
-
imports: [],
|
|
1447
|
-
providers: [
|
|
1448
|
-
// add providers to mobile-runtime module.
|
|
1449
|
-
],
|
|
1450
|
-
bootstrap: []
|
|
1451
|
-
}]
|
|
1452
|
-
}], () => [{ type: DeviceService }, { type: DeviceFileService }, { type: DeviceFileCacheService }, { type: DeviceFileOpenerService }, { type: NetworkService }], null); })();
|
|
1453
|
-
|
|
1454
|
-
class UploadRequest {
|
|
1455
|
-
constructor(url, cordovaFile) {
|
|
1456
|
-
this.url = url;
|
|
1457
|
-
this.cordovaFile = cordovaFile;
|
|
1458
|
-
this._files = [];
|
|
1459
|
-
this._params = [];
|
|
1460
|
-
this._headers = [];
|
|
1461
|
-
}
|
|
1462
|
-
addFile(name, path, filename) {
|
|
1463
|
-
this._files.push({
|
|
1464
|
-
name: name,
|
|
1465
|
-
path: path,
|
|
1466
|
-
fileName: filename
|
|
1467
|
-
});
|
|
1468
|
-
return this;
|
|
1469
|
-
}
|
|
1470
|
-
addHeader(name, value) {
|
|
1471
|
-
this._headers.push({
|
|
1472
|
-
name: name,
|
|
1473
|
-
value: value
|
|
1474
|
-
});
|
|
1475
|
-
return this;
|
|
1476
|
-
}
|
|
1477
|
-
addParam(name, value) {
|
|
1478
|
-
this._params.push({
|
|
1479
|
-
name: name,
|
|
1480
|
-
value: value
|
|
1481
|
-
});
|
|
1482
|
-
return this;
|
|
1483
|
-
}
|
|
1484
|
-
post() {
|
|
1485
|
-
const formData = new FormData();
|
|
1486
|
-
this._params.forEach(e => formData.append(e.name, e.value));
|
|
1487
|
-
return Promise.all(this._files.map(e => {
|
|
1488
|
-
if (e.path) {
|
|
1489
|
-
return i2$2.convertToBlob(e.path)
|
|
1490
|
-
.then(result => {
|
|
1491
|
-
return {
|
|
1492
|
-
name: e.name,
|
|
1493
|
-
fileName: e.fileName,
|
|
1494
|
-
blob: result.blob
|
|
1495
|
-
};
|
|
1496
|
-
});
|
|
1497
|
-
}
|
|
1498
|
-
return e;
|
|
1499
|
-
})).then(params => {
|
|
1500
|
-
params.forEach(e => formData.append(e.name, e.blob || e.path, e.fileName));
|
|
1501
|
-
return new Promise((resolve, reject) => {
|
|
1502
|
-
const request = new XMLHttpRequest();
|
|
1503
|
-
request.open('POST', this.url);
|
|
1504
|
-
this._headers.forEach(e => request.setRequestHeader(e.name, e.value));
|
|
1505
|
-
request.onload = () => {
|
|
1506
|
-
resolve({
|
|
1507
|
-
headers: (name) => request.getResponseHeader(name),
|
|
1508
|
-
response: request.response,
|
|
1509
|
-
text: request.responseText
|
|
1510
|
-
});
|
|
1511
|
-
};
|
|
1512
|
-
request.onerror = reject;
|
|
1513
|
-
request.onabort = reject;
|
|
1514
|
-
request.send(formData);
|
|
1515
|
-
});
|
|
1516
|
-
});
|
|
1517
|
-
}
|
|
1518
|
-
}
|
|
1519
|
-
class DeviceFileUploadService {
|
|
1520
|
-
static { this.SERVICE_NAME = 'DeviceFileUploadService'; }
|
|
1521
|
-
constructor(cordovaFile) {
|
|
1522
|
-
this.cordovaFile = cordovaFile;
|
|
1523
|
-
}
|
|
1524
|
-
upload(url, fileParamName, path, fileName, params, headers) {
|
|
1525
|
-
const req = new UploadRequest(url, this.cordovaFile)
|
|
1526
|
-
.addFile(fileParamName, path, fileName);
|
|
1527
|
-
lodashEs.forEach(params, (k, v) => req.addParam(k, v));
|
|
1528
|
-
lodashEs.forEach(headers, (k, v) => req.addHeader(k, v));
|
|
1529
|
-
return req.post();
|
|
1530
|
-
}
|
|
1531
|
-
static { this.ɵfac = function DeviceFileUploadService_Factory(__ngFactoryType__) { return new (__ngFactoryType__ || DeviceFileUploadService)(i0__namespace.ɵɵinject(i1$1__namespace.File)); }; }
|
|
1532
|
-
static { this.ɵprov = /*@__PURE__*/ i0__namespace.ɵɵdefineInjectable({ token: DeviceFileUploadService, factory: DeviceFileUploadService.ɵfac, providedIn: 'root' }); }
|
|
1533
|
-
}
|
|
1534
|
-
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0__namespace.ɵsetClassMetadata(DeviceFileUploadService, [{
|
|
1535
|
-
type: i0.Injectable,
|
|
1536
|
-
args: [{ providedIn: 'root' }]
|
|
1537
|
-
}], () => [{ type: i1$1__namespace.File }], null); })();
|
|
1538
|
-
|
|
1539
|
-
class ExtAppMessageService {
|
|
1540
|
-
static { this.SERVICE_NAME = 'ExtAppMessageService'; }
|
|
1541
|
-
constructor(app) {
|
|
1542
|
-
this.app = app;
|
|
1543
|
-
this.handlers = [];
|
|
1544
|
-
document.addEventListener('externalAppMessageReceived', e => {
|
|
1545
|
-
const message = (e['detail'].message);
|
|
1546
|
-
this.handlers.forEach(handler => {
|
|
1547
|
-
const matches = handler && message.address.match(handler.pattern);
|
|
1548
|
-
if (matches && matches.length > 0) {
|
|
1549
|
-
handler.callBack(message);
|
|
1550
|
-
}
|
|
1551
|
-
});
|
|
1552
|
-
});
|
|
1553
|
-
}
|
|
1554
|
-
/**
|
|
1555
|
-
* adds a listener for a message whose address matches with the given regex pattern.
|
|
1556
|
-
*
|
|
1557
|
-
* @param {string} messageAddressPattern a regex pattern that is used to target messages to listen.
|
|
1558
|
-
* @param {Function} listener function to invoke when message that matches regex is received.
|
|
1559
|
-
* message received will be sent as first argument.
|
|
1560
|
-
* @returns {Function} a function which removes the listener when invoked.
|
|
1561
|
-
*/
|
|
1562
|
-
subscribe(messageAddressPattern, listener) {
|
|
1563
|
-
const handler = {
|
|
1564
|
-
pattern: new RegExp(messageAddressPattern),
|
|
1565
|
-
callBack: listener
|
|
1566
|
-
};
|
|
1567
|
-
this.handlers.push(handler);
|
|
1568
|
-
return () => lodashEs.remove(this.handlers, handler);
|
|
1569
|
-
}
|
|
1570
|
-
static { this.ɵfac = function ExtAppMessageService_Factory(__ngFactoryType__) { return new (__ngFactoryType__ || ExtAppMessageService)(i0__namespace.ɵɵinject(i2$2__namespace.App)); }; }
|
|
1571
|
-
static { this.ɵprov = /*@__PURE__*/ i0__namespace.ɵɵdefineInjectable({ token: ExtAppMessageService, factory: ExtAppMessageService.ɵfac, providedIn: 'root' }); }
|
|
1572
|
-
}
|
|
1573
|
-
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0__namespace.ɵsetClassMetadata(ExtAppMessageService, [{
|
|
1574
|
-
type: i0.Injectable,
|
|
1575
|
-
args: [{ providedIn: 'root' }]
|
|
1576
|
-
}], () => [{ type: i2$2__namespace.App }], null); })();
|
|
1577
|
-
(function (window, document) {
|
|
1578
|
-
// listen app-to-app communication via url schemes
|
|
1579
|
-
function subString(str, begin, end) {
|
|
1580
|
-
end = end < 0 ? undefined : end;
|
|
1581
|
-
return (str && begin >= 0 && str.length > begin && str.substring(begin, end)) || undefined;
|
|
1582
|
-
}
|
|
1583
|
-
function indexOf(str, pattern) {
|
|
1584
|
-
return str && str.indexOf(pattern);
|
|
1585
|
-
}
|
|
1586
|
-
/**
|
|
1587
|
-
* returns if oAuth flow is implicit or pkce using state object in redirect_uri response.
|
|
1588
|
-
*
|
|
1589
|
-
* @param {url} string which contains access token and state information.
|
|
1590
|
-
* @returns {Boolean}
|
|
1591
|
-
*/
|
|
1592
|
-
function getFlow(url) {
|
|
1593
|
-
if (!url) {
|
|
1594
|
-
return false;
|
|
1595
|
-
}
|
|
1596
|
-
const stateObj = url.match(/\{([^)]+)\}/);
|
|
1597
|
-
if (stateObj) {
|
|
1598
|
-
const parsedObj = i2$2.getValidJSON('{' + stateObj[1] + '}');
|
|
1599
|
-
if (parsedObj && parsedObj.flow) {
|
|
1600
|
-
return parsedObj.flow;
|
|
1601
|
-
}
|
|
1602
|
-
}
|
|
1603
|
-
return false;
|
|
1604
|
-
}
|
|
1605
|
-
function extractData(url) {
|
|
1606
|
-
let str = subString(url, indexOf(url, '?') + 1, indexOf(url, '#'));
|
|
1607
|
-
const data = {}, flow = getFlow(url);
|
|
1608
|
-
// access token comes as a hash for implicit flow
|
|
1609
|
-
if (flow === 'implicit') {
|
|
1610
|
-
str = url.match(/access_token=([^&#]*)/)[0];
|
|
1611
|
-
}
|
|
1612
|
-
else if (flow === 'pkce') {
|
|
1613
|
-
str = url.match(/code=([^&#]*)/)[0];
|
|
1614
|
-
}
|
|
1615
|
-
lodashEs.forEach(lodashEs.split(str, '&'), entry => {
|
|
1616
|
-
const esplits = entry.split('=');
|
|
1617
|
-
data[esplits[0]] = esplits[1];
|
|
1618
|
-
});
|
|
1619
|
-
return data;
|
|
1620
|
-
}
|
|
1621
|
-
function extractAddress(url) {
|
|
1622
|
-
// access token comes as a hash for implicit flow
|
|
1623
|
-
const addressKey = getFlow(url) === 'implicit' ? '#' : '?';
|
|
1624
|
-
return subString(url, indexOf(url, '://') + 3, indexOf(url, addressKey));
|
|
1625
|
-
}
|
|
1626
|
-
function createMessage(url) {
|
|
1627
|
-
return {
|
|
1628
|
-
'address': extractAddress(url),
|
|
1629
|
-
'data': extractData(url)
|
|
1630
|
-
};
|
|
1631
|
-
}
|
|
1632
|
-
window['handleOpenURL'] = function (url) {
|
|
1633
|
-
const handleOpenURL = window['handleOpenURL'];
|
|
1634
|
-
if (handleOpenURL.isReady && !lodashEs.startsWith(url, 'http')) {
|
|
1635
|
-
const message = createMessage(url);
|
|
1636
|
-
const e = new window['CustomEvent']('externalAppMessageReceived', {
|
|
1637
|
-
'detail': {
|
|
1638
|
-
'message': message
|
|
1639
|
-
}
|
|
1640
|
-
});
|
|
1641
|
-
document.dispatchEvent(e);
|
|
1642
|
-
}
|
|
1643
|
-
handleOpenURL.lastURL = url;
|
|
1644
|
-
};
|
|
1645
|
-
}(window, document));
|
|
1646
|
-
|
|
1647
|
-
exports.DeviceFileCacheService = DeviceFileCacheService;
|
|
1648
|
-
exports.DeviceFileDownloadService = DeviceFileDownloadService;
|
|
1649
|
-
exports.DeviceFileOpenerService = DeviceFileOpenerService;
|
|
1650
|
-
exports.DeviceFileService = DeviceFileService;
|
|
1651
|
-
exports.DeviceFileUploadService = DeviceFileUploadService;
|
|
1652
|
-
exports.DeviceService = DeviceService;
|
|
1653
|
-
exports.ExtAppMessageService = ExtAppMessageService;
|
|
1654
|
-
exports.MobileCoreModule = MobileCoreModule;
|
|
1655
|
-
exports.NetworkService = NetworkService;
|
|
1656
|
-
exports.UploadRequest = UploadRequest;
|
|
1657
|
-
|
|
1658
|
-
}));
|