@bravobit/bb-foundation 0.26.2 → 0.27.0
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/auth/lib/directives/authenticated.directive.d.ts +1 -1
- package/collections/lib/components/collections-pager/collections-pager.component.d.ts +1 -1
- package/collections/lib/components/collections-viewer/collections-viewer.component.d.ts +1 -1
- package/controls/lib/checkbox/checkbox/checkbox.component.d.ts +1 -1
- package/controls/lib/checkbox/checkbox-group/checkbox-group.component.d.ts +1 -1
- package/controls/lib/control-error/control-error/control-error.component.d.ts +1 -1
- package/controls/lib/form-control/form-control/form-control.component.d.ts +1 -1
- package/controls/lib/form-control/form-control-addon/form-control-addon.component.d.ts +1 -1
- package/controls/lib/form-control/form-control-input.directive.d.ts +1 -1
- package/controls/lib/radio/radio-button/radio-button.component.d.ts +1 -1
- package/controls/lib/radio/radio-group/radio-group.component.d.ts +1 -1
- package/controls/lib/toggle/toggle/toggle.component.d.ts +1 -1
- package/controls/lib/toggle/toggle-group/toggle-group.component.d.ts +1 -1
- package/dashboard/lib/dashboard/dashboard.component.d.ts +1 -1
- package/dashboard/lib/dashboard-menu/dashboard-menu.component.d.ts +1 -1
- package/dashboard/lib/dashboard-menu-item/dashboard-menu-item.component.d.ts +1 -1
- package/dashboard/lib/dashboard-sidebar-group/dashboard-sidebar-group.component.d.ts +1 -1
- package/dashboard/lib/dashboard-sidebar-item/dashboard-sidebar-item.component.d.ts +1 -1
- package/dialog/lib/dialog-modal/dialog-modal.component.d.ts +1 -1
- package/elements/lib/avatar/avatar.component.d.ts +1 -1
- package/elements/lib/button/button.component.d.ts +2 -2
- package/elements/lib/checkbox/checkbox.component.d.ts +1 -1
- package/elements/lib/date-picker/date-picker.component.d.ts +1 -1
- package/elements/lib/directives/input.directive.d.ts +2 -2
- package/elements/lib/dropdown/dropdown.component.d.ts +1 -1
- package/elements/lib/file-picker/file-picker.component.d.ts +2 -2
- package/elements/lib/form-control/form-control.component.d.ts +1 -1
- package/elements/lib/form-error/form-error.component.d.ts +1 -1
- package/elements/lib/form-group/form-group.component.d.ts +1 -1
- package/elements/lib/icon/icon.component.d.ts +1 -1
- package/elements/lib/image-picker/image-picker.component.d.ts +1 -1
- package/elements/lib/spinner/spinner.component.d.ts +1 -1
- package/esm2022/auth/lib/auth.interceptor.mjs +91 -0
- package/esm2022/auth/lib/auth.module.mjs +36 -0
- package/esm2022/auth/lib/auth.service.mjs +271 -0
- package/esm2022/auth/lib/directives/authenticated.directive.mjs +43 -0
- package/esm2022/auth/lib/guards/anonymous.guard.mjs +54 -0
- package/esm2022/auth/lib/guards/authenticated.guard.mjs +57 -0
- package/esm2022/collections/lib/collections.module.mjs +55 -0
- package/esm2022/collections/lib/components/collections-pager/collections-pager.component.mjs +124 -0
- package/esm2022/collections/lib/components/collections-viewer/collections-viewer.component.mjs +32 -0
- package/esm2022/collections/lib/components/collections.directive.mjs +47 -0
- package/esm2022/controls/lib/checkbox/checkbox/checkbox.component.mjs +179 -0
- package/esm2022/controls/lib/checkbox/checkbox-group/checkbox-group.component.mjs +69 -0
- package/esm2022/controls/lib/checkbox/checkbox.module.mjs +21 -0
- package/esm2022/controls/lib/control-error/control-error/control-error.component.mjs +64 -0
- package/esm2022/controls/lib/control-error/control-error-submit.directive.mjs +48 -0
- package/esm2022/controls/lib/control-error/control-error.module.mjs +20 -0
- package/esm2022/controls/lib/controls.module.mjs +63 -0
- package/esm2022/controls/lib/form-control/form-control/form-control.component.mjs +80 -0
- package/esm2022/controls/lib/form-control/form-control-addon/form-control-addon.component.mjs +23 -0
- package/esm2022/controls/lib/form-control/form-control-input.directive.mjs +125 -0
- package/esm2022/controls/lib/form-control/form-control.module.mjs +35 -0
- package/esm2022/controls/lib/radio/radio-button/radio-button.component.mjs +76 -0
- package/esm2022/controls/lib/radio/radio-group/radio-group.component.mjs +169 -0
- package/esm2022/controls/lib/radio/radio.module.mjs +22 -0
- package/esm2022/controls/lib/toggle/toggle/toggle.component.mjs +154 -0
- package/esm2022/controls/lib/toggle/toggle-group/toggle-group.component.mjs +63 -0
- package/esm2022/controls/lib/toggle/toggle.module.mjs +21 -0
- package/esm2022/dashboard/lib/dashboard/dashboard.component.mjs +58 -0
- package/{esm2020 → esm2022}/dashboard/lib/dashboard-header/dashboard-header.component.mjs +6 -5
- package/esm2022/dashboard/lib/dashboard-menu/dashboard-menu.component.mjs +32 -0
- package/esm2022/dashboard/lib/dashboard-menu-item/dashboard-menu-item.component.mjs +30 -0
- package/esm2022/dashboard/lib/dashboard-sidebar/dashboard-sidebar.component.mjs +76 -0
- package/esm2022/dashboard/lib/dashboard-sidebar-group/dashboard-sidebar-group.component.mjs +100 -0
- package/esm2022/dashboard/lib/dashboard-sidebar-item/dashboard-sidebar-item.component.mjs +63 -0
- package/esm2022/dashboard/lib/dashboard.module.mjs +48 -0
- package/esm2022/dialog/lib/dialog-actions/dialog-actions.component.mjs +13 -0
- package/esm2022/dialog/lib/dialog-confirm/dialog-confirm.component.mjs +47 -0
- package/esm2022/dialog/lib/dialog-container/dialog-container.component.mjs +78 -0
- package/esm2022/dialog/lib/dialog-header/dialog-header.component.mjs +19 -0
- package/esm2022/dialog/lib/dialog-link/dialog-link.component.mjs +12 -0
- package/esm2022/dialog/lib/dialog-modal/dialog-modal.component.mjs +68 -0
- package/esm2022/dialog/lib/dialog-overlay/dialog-overlay.component.mjs +80 -0
- package/esm2022/dialog/lib/dialog.insertion.mjs +17 -0
- package/esm2022/dialog/lib/dialog.module.mjs +69 -0
- package/esm2022/dialog/lib/dialog.service.mjs +69 -0
- package/esm2022/elements/lib/avatar/avatar.component.mjs +150 -0
- package/esm2022/elements/lib/button/button.component.mjs +63 -0
- package/esm2022/elements/lib/checkbox/checkbox.component.mjs +74 -0
- package/esm2022/elements/lib/date-picker/date-picker.component.mjs +308 -0
- package/esm2022/elements/lib/directives/addon.directive.mjs +31 -0
- package/esm2022/elements/lib/directives/form-submit.directive.mjs +51 -0
- package/esm2022/elements/lib/directives/form-submitter.directive.mjs +26 -0
- package/esm2022/elements/lib/directives/input.directive.mjs +138 -0
- package/esm2022/elements/lib/dropdown/dropdown.component.mjs +102 -0
- package/esm2022/elements/lib/elements.module.mjs +178 -0
- package/esm2022/elements/lib/file-picker/file-picker.component.mjs +237 -0
- package/esm2022/elements/lib/form-control/form-control.component.mjs +50 -0
- package/esm2022/elements/lib/form-error/form-error.component.mjs +124 -0
- package/esm2022/elements/lib/form-group/form-group.component.mjs +19 -0
- package/esm2022/elements/lib/icon/icon.component.mjs +103 -0
- package/esm2022/elements/lib/image-picker/image-picker.component.mjs +107 -0
- package/esm2022/elements/lib/pipes/file-image.pipe.mjs +44 -0
- package/esm2022/elements/lib/pipes/file-size.pipe.mjs +29 -0
- package/esm2022/elements/lib/pipes/relative-time.pipe.mjs +97 -0
- package/esm2022/elements/lib/spinner/spinner.component.mjs +26 -0
- package/esm2022/elements/lib/tag/tag.component.mjs +19 -0
- package/esm2022/http/lib/http.module.mjs +44 -0
- package/esm2022/http/lib/interceptors/base-url.interceptor.mjs +51 -0
- package/esm2022/http/lib/interceptors/error.interceptor.mjs +33 -0
- package/esm2022/lib/core/services/clipboard.service.mjs +71 -0
- package/esm2022/lib/core/services/exif.service.mjs +164 -0
- package/esm2022/lib/core/services/file-loader.service.mjs +88 -0
- package/esm2022/lib/core/services/image-converter.service.mjs +124 -0
- package/esm2022/lib/core/services/languages.service.mjs +75 -0
- package/esm2022/lib/core/services/network.service.mjs +56 -0
- package/esm2022/lib/core/services/patch.service.mjs +64 -0
- package/esm2022/localize/lib/localize.module.mjs +82 -0
- package/esm2022/localize/lib/localize.pipe.mjs +47 -0
- package/esm2022/localize/lib/localize.service.mjs +186 -0
- package/{esm2020 → esm2022}/localize/lib/transforms/interpolate.transform.mjs +1 -1
- package/{esm2020 → esm2022}/localize/lib/transforms/reference.transform.mjs +1 -1
- package/esm2022/localize/lib/views/localize-string/localize-string.component.mjs +89 -0
- package/esm2022/localize/lib/views/localize-template.directive.mjs +22 -0
- package/esm2022/masking/lib/directives/currency-mask.directive.mjs +36 -0
- package/esm2022/masking/lib/directives/date-mask.directive.mjs +36 -0
- package/esm2022/masking/lib/directives/input-mask.directive.mjs +119 -0
- package/esm2022/masking/lib/masking.module.mjs +31 -0
- package/esm2022/masking/lib/masking.service.mjs +104 -0
- package/esm2022/notifications/lib/notifications-item/notifications-item.component.mjs +101 -0
- package/esm2022/notifications/lib/notifications-list/notifications-list.component.mjs +48 -0
- package/esm2022/notifications/lib/notifications.module.mjs +31 -0
- package/esm2022/notifications/lib/notifications.service.mjs +142 -0
- package/esm2022/permissions/lib/directives/permission.directive.mjs +89 -0
- package/esm2022/permissions/lib/guards/permission.guard.mjs +57 -0
- package/esm2022/permissions/lib/permissions.module.mjs +40 -0
- package/esm2022/permissions/lib/permissions.service.mjs +97 -0
- package/esm2022/recaptcha/lib/recaptcha/recaptcha.component.mjs +220 -0
- package/esm2022/recaptcha/lib/recaptcha-loader.service.mjs +96 -0
- package/esm2022/recaptcha/lib/recaptcha.module.mjs +28 -0
- package/esm2022/storage/lib/storage.service.mjs +110 -0
- package/esm2022/table/lib/components/table/table.component.mjs +194 -0
- package/esm2022/table/lib/components/table-cell/table-cell.component.mjs +12 -0
- package/esm2022/table/lib/components/table-header-cell/table-header-cell.component.mjs +132 -0
- package/esm2022/table/lib/components/table-pager/table-pager.component.mjs +137 -0
- package/esm2022/table/lib/data/generic.data.mjs +82 -0
- package/esm2022/table/lib/table.module.mjs +43 -0
- package/esm2022/theming/lib/theming.directive.mjs +39 -0
- package/esm2022/theming/lib/theming.module.mjs +17 -0
- package/esm2022/tooltip/lib/tooltip-container/tooltip-container.component.mjs +32 -0
- package/esm2022/tooltip/lib/tooltip.directive.mjs +141 -0
- package/esm2022/tooltip/lib/tooltip.module.mjs +32 -0
- package/esm2022/utils/lib/directives/autosize.directive.mjs +73 -0
- package/esm2022/utils/lib/directives/focus-trap.directive.mjs +78 -0
- package/esm2022/utils/lib/directives/focus.directive.mjs +38 -0
- package/esm2022/utils/lib/directives/template.directive.mjs +29 -0
- package/esm2022/utils/lib/functions/parse-date.function.mjs +19 -0
- package/esm2022/utils/lib/utils.module.mjs +36 -0
- package/esm2022/utils/public_api.mjs +7 -0
- package/{fesm2020 → fesm2022}/bravobit-bb-foundation-auth.mjs +19 -19
- package/{fesm2020 → fesm2022}/bravobit-bb-foundation-auth.mjs.map +1 -1
- package/{fesm2020 → fesm2022}/bravobit-bb-foundation-collections.mjs +38 -38
- package/{fesm2020 → fesm2022}/bravobit-bb-foundation-collections.mjs.map +1 -1
- package/{fesm2020 → fesm2022}/bravobit-bb-foundation-controls.mjs +83 -83
- package/{fesm2020 → fesm2022}/bravobit-bb-foundation-controls.mjs.map +1 -1
- package/{fesm2020 → fesm2022}/bravobit-bb-foundation-dashboard.mjs +37 -37
- package/{fesm2020 → fesm2022}/bravobit-bb-foundation-dashboard.mjs.map +1 -1
- package/{fesm2020 → fesm2022}/bravobit-bb-foundation-dialog.mjs +46 -46
- package/{fesm2020 → fesm2022}/bravobit-bb-foundation-dialog.mjs.map +1 -1
- package/{fesm2020 → fesm2022}/bravobit-bb-foundation-elements.mjs +185 -185
- package/fesm2022/bravobit-bb-foundation-elements.mjs.map +1 -0
- package/{fesm2020 → fesm2022}/bravobit-bb-foundation-http.mjs +10 -10
- package/{fesm2020 → fesm2022}/bravobit-bb-foundation-http.mjs.map +1 -1
- package/{fesm2020 → fesm2022}/bravobit-bb-foundation-localize.mjs +20 -20
- package/{fesm2020 → fesm2022}/bravobit-bb-foundation-localize.mjs.map +1 -1
- package/{fesm2020 → fesm2022}/bravobit-bb-foundation-masking.mjs +20 -20
- package/{fesm2020 → fesm2022}/bravobit-bb-foundation-masking.mjs.map +1 -1
- package/{fesm2020 → fesm2022}/bravobit-bb-foundation-notifications.mjs +13 -13
- package/{fesm2020 → fesm2022}/bravobit-bb-foundation-notifications.mjs.map +1 -1
- package/{fesm2020 → fesm2022}/bravobit-bb-foundation-permissions.mjs +13 -13
- package/{fesm2020 → fesm2022}/bravobit-bb-foundation-permissions.mjs.map +1 -1
- package/{fesm2020 → fesm2022}/bravobit-bb-foundation-recaptcha.mjs +16 -16
- package/{fesm2015 → fesm2022}/bravobit-bb-foundation-recaptcha.mjs.map +1 -1
- package/{fesm2020 → fesm2022}/bravobit-bb-foundation-storage.mjs +3 -3
- package/{fesm2020 → fesm2022}/bravobit-bb-foundation-storage.mjs.map +1 -1
- package/{fesm2020 → fesm2022}/bravobit-bb-foundation-table.mjs +46 -36
- package/fesm2022/bravobit-bb-foundation-table.mjs.map +1 -0
- package/{fesm2020 → fesm2022}/bravobit-bb-foundation-theming.mjs +7 -7
- package/{fesm2020 → fesm2022}/bravobit-bb-foundation-theming.mjs.map +1 -1
- package/{fesm2020 → fesm2022}/bravobit-bb-foundation-tooltip.mjs +13 -13
- package/{fesm2020 → fesm2022}/bravobit-bb-foundation-tooltip.mjs.map +1 -1
- package/{fesm2020 → fesm2022}/bravobit-bb-foundation-utils.mjs +42 -23
- package/fesm2022/bravobit-bb-foundation-utils.mjs.map +1 -0
- package/{fesm2020 → fesm2022}/bravobit-bb-foundation.mjs +21 -21
- package/{fesm2020 → fesm2022}/bravobit-bb-foundation.mjs.map +1 -1
- package/localize/lib/views/localize-string/localize-string.component.d.ts +1 -1
- package/localize/lib/views/localize-template.directive.d.ts +1 -1
- package/masking/lib/directives/currency-mask.directive.d.ts +1 -1
- package/masking/lib/directives/date-mask.directive.d.ts +1 -1
- package/masking/lib/directives/input-mask.directive.d.ts +1 -1
- package/notifications/lib/notifications-item/notifications-item.component.d.ts +1 -1
- package/package.json +70 -112
- package/permissions/lib/directives/permission.directive.d.ts +1 -1
- package/recaptcha/lib/recaptcha/recaptcha.component.d.ts +1 -1
- package/table/lib/components/table/table.component.d.ts +1 -1
- package/table/lib/components/table-header-cell/table-header-cell.component.d.ts +1 -1
- package/table/lib/components/table-pager/table-pager.component.d.ts +1 -1
- package/table/lib/data/generic.data.d.ts +2 -0
- package/theming/lib/theming.directive.d.ts +1 -1
- package/tooltip/lib/tooltip.directive.d.ts +1 -1
- package/utils/lib/directives/autosize.directive.d.ts +1 -1
- package/utils/lib/directives/template.directive.d.ts +1 -1
- package/utils/lib/functions/parse-date.function.d.ts +1 -0
- package/utils/public_api.d.ts +1 -0
- package/esm2020/auth/lib/auth.interceptor.mjs +0 -90
- package/esm2020/auth/lib/auth.module.mjs +0 -35
- package/esm2020/auth/lib/auth.service.mjs +0 -270
- package/esm2020/auth/lib/directives/authenticated.directive.mjs +0 -42
- package/esm2020/auth/lib/guards/anonymous.guard.mjs +0 -53
- package/esm2020/auth/lib/guards/authenticated.guard.mjs +0 -56
- package/esm2020/collections/lib/collections.module.mjs +0 -54
- package/esm2020/collections/lib/components/collections-pager/collections-pager.component.mjs +0 -123
- package/esm2020/collections/lib/components/collections-viewer/collections-viewer.component.mjs +0 -31
- package/esm2020/collections/lib/components/collections.directive.mjs +0 -43
- package/esm2020/controls/lib/checkbox/checkbox/checkbox.component.mjs +0 -178
- package/esm2020/controls/lib/checkbox/checkbox-group/checkbox-group.component.mjs +0 -68
- package/esm2020/controls/lib/checkbox/checkbox.module.mjs +0 -20
- package/esm2020/controls/lib/control-error/control-error/control-error.component.mjs +0 -63
- package/esm2020/controls/lib/control-error/control-error-submit.directive.mjs +0 -47
- package/esm2020/controls/lib/control-error/control-error.module.mjs +0 -19
- package/esm2020/controls/lib/controls.module.mjs +0 -62
- package/esm2020/controls/lib/form-control/form-control/form-control.component.mjs +0 -79
- package/esm2020/controls/lib/form-control/form-control-addon/form-control-addon.component.mjs +0 -22
- package/esm2020/controls/lib/form-control/form-control-input.directive.mjs +0 -124
- package/esm2020/controls/lib/form-control/form-control.module.mjs +0 -34
- package/esm2020/controls/lib/radio/radio-button/radio-button.component.mjs +0 -75
- package/esm2020/controls/lib/radio/radio-group/radio-group.component.mjs +0 -168
- package/esm2020/controls/lib/radio/radio.module.mjs +0 -21
- package/esm2020/controls/lib/toggle/toggle/toggle.component.mjs +0 -153
- package/esm2020/controls/lib/toggle/toggle-group/toggle-group.component.mjs +0 -62
- package/esm2020/controls/lib/toggle/toggle.module.mjs +0 -20
- package/esm2020/dashboard/lib/dashboard/dashboard.component.mjs +0 -57
- package/esm2020/dashboard/lib/dashboard-menu/dashboard-menu.component.mjs +0 -31
- package/esm2020/dashboard/lib/dashboard-menu-item/dashboard-menu-item.component.mjs +0 -29
- package/esm2020/dashboard/lib/dashboard-sidebar/dashboard-sidebar.component.mjs +0 -75
- package/esm2020/dashboard/lib/dashboard-sidebar-group/dashboard-sidebar-group.component.mjs +0 -99
- package/esm2020/dashboard/lib/dashboard-sidebar-item/dashboard-sidebar-item.component.mjs +0 -62
- package/esm2020/dashboard/lib/dashboard.module.mjs +0 -47
- package/esm2020/dialog/lib/dialog-actions/dialog-actions.component.mjs +0 -12
- package/esm2020/dialog/lib/dialog-confirm/dialog-confirm.component.mjs +0 -46
- package/esm2020/dialog/lib/dialog-container/dialog-container.component.mjs +0 -77
- package/esm2020/dialog/lib/dialog-header/dialog-header.component.mjs +0 -18
- package/esm2020/dialog/lib/dialog-link/dialog-link.component.mjs +0 -11
- package/esm2020/dialog/lib/dialog-modal/dialog-modal.component.mjs +0 -67
- package/esm2020/dialog/lib/dialog-overlay/dialog-overlay.component.mjs +0 -79
- package/esm2020/dialog/lib/dialog.insertion.mjs +0 -16
- package/esm2020/dialog/lib/dialog.module.mjs +0 -68
- package/esm2020/dialog/lib/dialog.service.mjs +0 -68
- package/esm2020/elements/lib/avatar/avatar.component.mjs +0 -149
- package/esm2020/elements/lib/button/button.component.mjs +0 -61
- package/esm2020/elements/lib/checkbox/checkbox.component.mjs +0 -73
- package/esm2020/elements/lib/date-picker/date-picker.component.mjs +0 -307
- package/esm2020/elements/lib/directives/addon.directive.mjs +0 -29
- package/esm2020/elements/lib/directives/form-submit.directive.mjs +0 -50
- package/esm2020/elements/lib/directives/form-submitter.directive.mjs +0 -25
- package/esm2020/elements/lib/directives/input.directive.mjs +0 -136
- package/esm2020/elements/lib/dropdown/dropdown.component.mjs +0 -100
- package/esm2020/elements/lib/elements.module.mjs +0 -177
- package/esm2020/elements/lib/file-picker/file-picker.component.mjs +0 -236
- package/esm2020/elements/lib/form-control/form-control.component.mjs +0 -49
- package/esm2020/elements/lib/form-error/form-error.component.mjs +0 -123
- package/esm2020/elements/lib/form-group/form-group.component.mjs +0 -18
- package/esm2020/elements/lib/icon/icon.component.mjs +0 -102
- package/esm2020/elements/lib/image-picker/image-picker.component.mjs +0 -106
- package/esm2020/elements/lib/pipes/file-image.pipe.mjs +0 -43
- package/esm2020/elements/lib/pipes/file-size.pipe.mjs +0 -28
- package/esm2020/elements/lib/pipes/relative-time.pipe.mjs +0 -96
- package/esm2020/elements/lib/spinner/spinner.component.mjs +0 -25
- package/esm2020/elements/lib/tag/tag.component.mjs +0 -18
- package/esm2020/http/lib/http.module.mjs +0 -43
- package/esm2020/http/lib/interceptors/base-url.interceptor.mjs +0 -50
- package/esm2020/http/lib/interceptors/error.interceptor.mjs +0 -32
- package/esm2020/lib/core/services/clipboard.service.mjs +0 -70
- package/esm2020/lib/core/services/exif.service.mjs +0 -163
- package/esm2020/lib/core/services/file-loader.service.mjs +0 -87
- package/esm2020/lib/core/services/image-converter.service.mjs +0 -123
- package/esm2020/lib/core/services/languages.service.mjs +0 -74
- package/esm2020/lib/core/services/network.service.mjs +0 -55
- package/esm2020/lib/core/services/patch.service.mjs +0 -63
- package/esm2020/localize/lib/localize.module.mjs +0 -81
- package/esm2020/localize/lib/localize.pipe.mjs +0 -46
- package/esm2020/localize/lib/localize.service.mjs +0 -185
- package/esm2020/localize/lib/views/localize-string/localize-string.component.mjs +0 -88
- package/esm2020/localize/lib/views/localize-template.directive.mjs +0 -21
- package/esm2020/masking/lib/directives/currency-mask.directive.mjs +0 -35
- package/esm2020/masking/lib/directives/date-mask.directive.mjs +0 -35
- package/esm2020/masking/lib/directives/input-mask.directive.mjs +0 -118
- package/esm2020/masking/lib/masking.module.mjs +0 -30
- package/esm2020/masking/lib/masking.service.mjs +0 -103
- package/esm2020/notifications/lib/notifications-item/notifications-item.component.mjs +0 -100
- package/esm2020/notifications/lib/notifications-list/notifications-list.component.mjs +0 -47
- package/esm2020/notifications/lib/notifications.module.mjs +0 -30
- package/esm2020/notifications/lib/notifications.service.mjs +0 -141
- package/esm2020/permissions/lib/directives/permission.directive.mjs +0 -88
- package/esm2020/permissions/lib/guards/permission.guard.mjs +0 -56
- package/esm2020/permissions/lib/permissions.module.mjs +0 -39
- package/esm2020/permissions/lib/permissions.service.mjs +0 -96
- package/esm2020/recaptcha/lib/recaptcha/recaptcha.component.mjs +0 -219
- package/esm2020/recaptcha/lib/recaptcha-loader.service.mjs +0 -95
- package/esm2020/recaptcha/lib/recaptcha.module.mjs +0 -27
- package/esm2020/storage/lib/storage.service.mjs +0 -109
- package/esm2020/table/lib/components/table/table.component.mjs +0 -191
- package/esm2020/table/lib/components/table-cell/table-cell.component.mjs +0 -11
- package/esm2020/table/lib/components/table-header-cell/table-header-cell.component.mjs +0 -131
- package/esm2020/table/lib/components/table-pager/table-pager.component.mjs +0 -136
- package/esm2020/table/lib/data/generic.data.mjs +0 -72
- package/esm2020/table/lib/table.module.mjs +0 -42
- package/esm2020/theming/lib/theming.directive.mjs +0 -38
- package/esm2020/theming/lib/theming.module.mjs +0 -16
- package/esm2020/tooltip/lib/tooltip-container/tooltip-container.component.mjs +0 -31
- package/esm2020/tooltip/lib/tooltip.directive.mjs +0 -140
- package/esm2020/tooltip/lib/tooltip.module.mjs +0 -31
- package/esm2020/utils/lib/directives/autosize.directive.mjs +0 -72
- package/esm2020/utils/lib/directives/focus-trap.directive.mjs +0 -77
- package/esm2020/utils/lib/directives/focus.directive.mjs +0 -37
- package/esm2020/utils/lib/directives/template.directive.mjs +0 -28
- package/esm2020/utils/lib/utils.module.mjs +0 -35
- package/esm2020/utils/public_api.mjs +0 -6
- package/fesm2015/bravobit-bb-foundation-auth.mjs +0 -851
- package/fesm2015/bravobit-bb-foundation-auth.mjs.map +0 -1
- package/fesm2015/bravobit-bb-foundation-collections.mjs +0 -474
- package/fesm2015/bravobit-bb-foundation-collections.mjs.map +0 -1
- package/fesm2015/bravobit-bb-foundation-controls.mjs +0 -1217
- package/fesm2015/bravobit-bb-foundation-controls.mjs.map +0 -1
- package/fesm2015/bravobit-bb-foundation-dashboard.mjs +0 -417
- package/fesm2015/bravobit-bb-foundation-dashboard.mjs.map +0 -1
- package/fesm2015/bravobit-bb-foundation-dialog.mjs +0 -512
- package/fesm2015/bravobit-bb-foundation-dialog.mjs.map +0 -1
- package/fesm2015/bravobit-bb-foundation-elements.mjs +0 -1883
- package/fesm2015/bravobit-bb-foundation-elements.mjs.map +0 -1
- package/fesm2015/bravobit-bb-foundation-http.mjs +0 -176
- package/fesm2015/bravobit-bb-foundation-http.mjs.map +0 -1
- package/fesm2015/bravobit-bb-foundation-localize.mjs +0 -835
- package/fesm2015/bravobit-bb-foundation-localize.mjs.map +0 -1
- package/fesm2015/bravobit-bb-foundation-masking.mjs +0 -334
- package/fesm2015/bravobit-bb-foundation-masking.mjs.map +0 -1
- package/fesm2015/bravobit-bb-foundation-notifications.mjs +0 -357
- package/fesm2015/bravobit-bb-foundation-notifications.mjs.map +0 -1
- package/fesm2015/bravobit-bb-foundation-permissions.mjs +0 -310
- package/fesm2015/bravobit-bb-foundation-permissions.mjs.map +0 -1
- package/fesm2015/bravobit-bb-foundation-recaptcha.mjs +0 -349
- package/fesm2015/bravobit-bb-foundation-rxjs.mjs +0 -22
- package/fesm2015/bravobit-bb-foundation-rxjs.mjs.map +0 -1
- package/fesm2015/bravobit-bb-foundation-storage.mjs +0 -418
- package/fesm2015/bravobit-bb-foundation-storage.mjs.map +0 -1
- package/fesm2015/bravobit-bb-foundation-table.mjs +0 -603
- package/fesm2015/bravobit-bb-foundation-table.mjs.map +0 -1
- package/fesm2015/bravobit-bb-foundation-theming.mjs +0 -382
- package/fesm2015/bravobit-bb-foundation-theming.mjs.map +0 -1
- package/fesm2015/bravobit-bb-foundation-tooltip.mjs +0 -210
- package/fesm2015/bravobit-bb-foundation-tooltip.mjs.map +0 -1
- package/fesm2015/bravobit-bb-foundation-utils.mjs +0 -246
- package/fesm2015/bravobit-bb-foundation-utils.mjs.map +0 -1
- package/fesm2015/bravobit-bb-foundation.mjs +0 -929
- package/fesm2015/bravobit-bb-foundation.mjs.map +0 -1
- package/fesm2020/bravobit-bb-foundation-elements.mjs.map +0 -1
- package/fesm2020/bravobit-bb-foundation-recaptcha.mjs.map +0 -1
- package/fesm2020/bravobit-bb-foundation-table.mjs.map +0 -1
- package/fesm2020/bravobit-bb-foundation-utils.mjs.map +0 -1
- /package/{esm2020 → esm2022}/auth/bravobit-bb-foundation-auth.mjs +0 -0
- /package/{esm2020 → esm2022}/auth/lib/auth.session.mjs +0 -0
- /package/{esm2020 → esm2022}/auth/lib/directives/abstract.directive.mjs +0 -0
- /package/{esm2020 → esm2022}/auth/lib/helpers/jwt.helper.mjs +0 -0
- /package/{esm2020 → esm2022}/auth/lib/interfaces/config.interface.mjs +0 -0
- /package/{esm2020 → esm2022}/auth/lib/interfaces/provider.interface.mjs +0 -0
- /package/{esm2020 → esm2022}/auth/lib/interfaces/token.interface.mjs +0 -0
- /package/{esm2020 → esm2022}/auth/lib/providers/email.provider.mjs +0 -0
- /package/{esm2020 → esm2022}/auth/lib/providers/verify.provider.mjs +0 -0
- /package/{esm2020 → esm2022}/auth/lib/tokens/use-authorization.token.mjs +0 -0
- /package/{esm2020 → esm2022}/auth/public_api.mjs +0 -0
- /package/{esm2020 → esm2022}/bravobit-bb-foundation.mjs +0 -0
- /package/{esm2020 → esm2022}/collections/bravobit-bb-foundation-collections.mjs +0 -0
- /package/{esm2020 → esm2022}/collections/lib/collection.mjs +0 -0
- /package/{esm2020 → esm2022}/collections/lib/interfaces/collection.interface.mjs +0 -0
- /package/{esm2020 → esm2022}/collections/lib/providers/api-collection.provider.mjs +0 -0
- /package/{esm2020 → esm2022}/collections/lib/providers/collection.provider.mjs +0 -0
- /package/{esm2020 → esm2022}/collections/lib/providers/local-collection.provider.mjs +0 -0
- /package/{esm2020 → esm2022}/collections/public_api.mjs +0 -0
- /package/{esm2020 → esm2022}/controls/bravobit-bb-foundation-controls.mjs +0 -0
- /package/{esm2020 → esm2022}/controls/lib/control-error/control-error/control-error.animation.mjs +0 -0
- /package/{esm2020 → esm2022}/controls/lib/control-error/control-error.defaults.mjs +0 -0
- /package/{esm2020 → esm2022}/controls/lib/control-error/control-error.interface.mjs +0 -0
- /package/{esm2020 → esm2022}/controls/lib/control-error/control-error.utils.mjs +0 -0
- /package/{esm2020 → esm2022}/controls/lib/controls.interfaces.mjs +0 -0
- /package/{esm2020 → esm2022}/controls/public_api.mjs +0 -0
- /package/{esm2020 → esm2022}/dashboard/bravobit-bb-foundation-dashboard.mjs +0 -0
- /package/{esm2020 → esm2022}/dashboard/public_api.mjs +0 -0
- /package/{esm2020 → esm2022}/dialog/bravobit-bb-foundation-dialog.mjs +0 -0
- /package/{esm2020 → esm2022}/dialog/lib/dialog-container/dialog-container.animations.mjs +0 -0
- /package/{esm2020 → esm2022}/dialog/lib/dialog-overlay/dialog-overlay.animations.mjs +0 -0
- /package/{esm2020 → esm2022}/dialog/lib/dialog.interfaces.mjs +0 -0
- /package/{esm2020 → esm2022}/dialog/lib/dialog.ref.mjs +0 -0
- /package/{esm2020 → esm2022}/dialog/public_api.mjs +0 -0
- /package/{esm2020 → esm2022}/elements/bravobit-bb-foundation-elements.mjs +0 -0
- /package/{esm2020 → esm2022}/elements/lib/elements.interfaces.mjs +0 -0
- /package/{esm2020 → esm2022}/elements/public_api.mjs +0 -0
- /package/{esm2020 → esm2022}/http/bravobit-bb-foundation-http.mjs +0 -0
- /package/{esm2020 → esm2022}/http/lib/classes/http.config.mjs +0 -0
- /package/{esm2020 → esm2022}/http/lib/classes/http.error.mjs +0 -0
- /package/{esm2020 → esm2022}/http/lib/http.interfaces.mjs +0 -0
- /package/{esm2020 → esm2022}/http/public_api.mjs +0 -0
- /package/{esm2020 → esm2022}/lib/core/functions/date.utils.mjs +0 -0
- /package/{esm2020 → esm2022}/lib/core/functions/password.utils.mjs +0 -0
- /package/{esm2020 → esm2022}/lib/core/miscellaneous/regex.mjs +0 -0
- /package/{esm2020 → esm2022}/lib/core/miscellaneous/validator.mjs +0 -0
- /package/{esm2020 → esm2022}/lib/core/mixins/can-disable.mjs +0 -0
- /package/{esm2020 → esm2022}/lib/core/mixins/can-hide-errors.mjs +0 -0
- /package/{esm2020 → esm2022}/lib/core/mixins/can-load.mjs +0 -0
- /package/{esm2020 → esm2022}/lib/core/mixins/constructor.mjs +0 -0
- /package/{esm2020 → esm2022}/lib/core/mixins/has-error.mjs +0 -0
- /package/{esm2020 → esm2022}/lib/core/mixins/is-focused.mjs +0 -0
- /package/{esm2020 → esm2022}/lib/core/mixins/is-grouped.mjs +0 -0
- /package/{esm2020 → esm2022}/lib/core/mixins/is-readonly.mjs +0 -0
- /package/{esm2020 → esm2022}/lib/core/mixins/is-required.mjs +0 -0
- /package/{esm2020 → esm2022}/lib/core/tokens/accept-language.token.mjs +0 -0
- /package/{esm2020 → esm2022}/lib/core/tokens/base-url.token.mjs +0 -0
- /package/{esm2020 → esm2022}/lib/core/tokens/cookie.token.mjs +0 -0
- /package/{esm2020 → esm2022}/lib/core/tokens/location.token.mjs +0 -0
- /package/{esm2020 → esm2022}/lib/core/tokens/navigator.token.mjs +0 -0
- /package/{esm2020 → esm2022}/lib/core/tokens/window.token.mjs +0 -0
- /package/{esm2020 → esm2022}/localize/bravobit-bb-foundation-localize.mjs +0 -0
- /package/{esm2020 → esm2022}/localize/lib/dictionary/dictionary.class.mjs +0 -0
- /package/{esm2020 → esm2022}/localize/lib/dictionary/dictionary.context.mjs +0 -0
- /package/{esm2020 → esm2022}/localize/lib/dictionary/dictionary.data.mjs +0 -0
- /package/{esm2020 → esm2022}/localize/lib/functions/date.function.mjs +0 -0
- /package/{esm2020 → esm2022}/localize/lib/functions/lowercase.function.mjs +0 -0
- /package/{esm2020 → esm2022}/localize/lib/functions/uppercase.function.mjs +0 -0
- /package/{esm2020 → esm2022}/localize/lib/handlers/missing.handler.mjs +0 -0
- /package/{esm2020 → esm2022}/localize/lib/interfaces/config.interfaces.mjs +0 -0
- /package/{esm2020 → esm2022}/localize/lib/interfaces/functions.interfaces.mjs +0 -0
- /package/{esm2020 → esm2022}/localize/lib/interfaces/handlers.interfaces.mjs +0 -0
- /package/{esm2020 → esm2022}/localize/lib/interfaces/options.interfaces.mjs +0 -0
- /package/{esm2020 → esm2022}/localize/lib/interfaces/transforms.interfaces.mjs +0 -0
- /package/{esm2020 → esm2022}/localize/lib/locale.token.mjs +0 -0
- /package/{esm2020 → esm2022}/localize/lib/localizations/dutch.localization.mjs +0 -0
- /package/{esm2020 → esm2022}/localize/lib/localizations/english.localization.mjs +0 -0
- /package/{esm2020 → esm2022}/localize/lib/transforms/abstract.transform.mjs +0 -0
- /package/{esm2020 → esm2022}/localize/public_api.mjs +0 -0
- /package/{esm2020 → esm2022}/masking/bravobit-bb-foundation-masking.mjs +0 -0
- /package/{esm2020 → esm2022}/masking/lib/input-mask.interface.mjs +0 -0
- /package/{esm2020 → esm2022}/masking/public_api.mjs +0 -0
- /package/{esm2020 → esm2022}/notifications/bravobit-bb-foundation-notifications.mjs +0 -0
- /package/{esm2020 → esm2022}/notifications/lib/notifications.animations.mjs +0 -0
- /package/{esm2020 → esm2022}/notifications/lib/notifications.interfaces.mjs +0 -0
- /package/{esm2020 → esm2022}/notifications/public_api.mjs +0 -0
- /package/{esm2020 → esm2022}/permissions/bravobit-bb-foundation-permissions.mjs +0 -0
- /package/{esm2020 → esm2022}/permissions/lib/handlers/abstract.handler.mjs +0 -0
- /package/{esm2020 → esm2022}/permissions/lib/handlers/local.handler.mjs +0 -0
- /package/{esm2020 → esm2022}/permissions/lib/permissions.interface.mjs +0 -0
- /package/{esm2020 → esm2022}/permissions/public_api.mjs +0 -0
- /package/{esm2020 → esm2022}/public_api.mjs +0 -0
- /package/{esm2020 → esm2022}/recaptcha/bravobit-bb-foundation-recaptcha.mjs +0 -0
- /package/{esm2020 → esm2022}/recaptcha/lib/recaptcha.interface.mjs +0 -0
- /package/{esm2020 → esm2022}/recaptcha/public_api.mjs +0 -0
- /package/{esm2020 → esm2022}/rxjs/bravobit-bb-foundation-rxjs.mjs +0 -0
- /package/{esm2020 → esm2022}/rxjs/lib/observables/get-control-value.observable.mjs +0 -0
- /package/{esm2020 → esm2022}/rxjs/lib/operators/combine-latest-map.operator.mjs +0 -0
- /package/{esm2020 → esm2022}/rxjs/lib/operators/filter-nil.operator.mjs +0 -0
- /package/{esm2020 → esm2022}/rxjs/public_api.mjs +0 -0
- /package/{esm2020 → esm2022}/storage/bravobit-bb-foundation-storage.mjs +0 -0
- /package/{esm2020 → esm2022}/storage/lib/interfaces/attributes.interface.mjs +0 -0
- /package/{esm2020 → esm2022}/storage/lib/interfaces/memory.interface.mjs +0 -0
- /package/{esm2020 → esm2022}/storage/lib/interfaces/strategy.interface.mjs +0 -0
- /package/{esm2020 → esm2022}/storage/lib/strategies/cookie-storage.strategy.mjs +0 -0
- /package/{esm2020 → esm2022}/storage/lib/strategies/memory-storage.strategy.mjs +0 -0
- /package/{esm2020 → esm2022}/storage/lib/strategies/polyfill-storage.strategy.mjs +0 -0
- /package/{esm2020 → esm2022}/storage/public_api.mjs +0 -0
- /package/{esm2020 → esm2022}/table/bravobit-bb-foundation-table.mjs +0 -0
- /package/{esm2020 → esm2022}/table/lib/data/datasource.data.mjs +0 -0
- /package/{esm2020 → esm2022}/table/lib/interfaces/datasource.interface.mjs +0 -0
- /package/{esm2020 → esm2022}/table/lib/interfaces/table.interfaces.mjs +0 -0
- /package/{esm2020 → esm2022}/table/public_api.mjs +0 -0
- /package/{esm2020 → esm2022}/theming/bravobit-bb-foundation-theming.mjs +0 -0
- /package/{esm2020 → esm2022}/theming/lib/themes/checkbox-group.theme.mjs +0 -0
- /package/{esm2020 → esm2022}/theming/lib/themes/checkbox.theme.mjs +0 -0
- /package/{esm2020 → esm2022}/theming/lib/themes/control-error.theme.mjs +0 -0
- /package/{esm2020 → esm2022}/theming/lib/themes/form-control-addon.theme.mjs +0 -0
- /package/{esm2020 → esm2022}/theming/lib/themes/form-control.theme.mjs +0 -0
- /package/{esm2020 → esm2022}/theming/lib/themes/radio-button.theme.mjs +0 -0
- /package/{esm2020 → esm2022}/theming/lib/themes/radio-group.theme.mjs +0 -0
- /package/{esm2020 → esm2022}/theming/lib/themes/toggle-group.theme.mjs +0 -0
- /package/{esm2020 → esm2022}/theming/lib/themes/toggle.theme.mjs +0 -0
- /package/{esm2020 → esm2022}/theming/lib/theming.data.mjs +0 -0
- /package/{esm2020 → esm2022}/theming/lib/theming.interface.mjs +0 -0
- /package/{esm2020 → esm2022}/theming/lib/utils/theming.variable.mjs +0 -0
- /package/{esm2020 → esm2022}/theming/public_api.mjs +0 -0
- /package/{esm2020 → esm2022}/tooltip/bravobit-bb-foundation-tooltip.mjs +0 -0
- /package/{esm2020 → esm2022}/tooltip/lib/tooltip.interfaces.mjs +0 -0
- /package/{esm2020 → esm2022}/tooltip/public_api.mjs +0 -0
- /package/{esm2020 → esm2022}/utils/bravobit-bb-foundation-utils.mjs +0 -0
- /package/{fesm2020 → fesm2022}/bravobit-bb-foundation-rxjs.mjs +0 -0
- /package/{fesm2020 → fesm2022}/bravobit-bb-foundation-rxjs.mjs.map +0 -0
|
@@ -1,512 +0,0 @@
|
|
|
1
|
-
import { take, switchMap } from 'rxjs/operators';
|
|
2
|
-
import { Subject, Subscription, lastValueFrom, fromEvent, race, firstValueFrom } from 'rxjs';
|
|
3
|
-
import * as i0 from '@angular/core';
|
|
4
|
-
import { EventEmitter, Component, ChangeDetectionStrategy, ViewEncapsulation, Output, HostListener, Optional, Inject, HostBinding, Input, Directive, ViewChild, createEnvironmentInjector, createComponent, Injectable, NgModule } from '@angular/core';
|
|
5
|
-
import { trigger, transition, group, query, style, animate } from '@angular/animations';
|
|
6
|
-
import * as i3 from '@angular/common';
|
|
7
|
-
import { DOCUMENT, CommonModule } from '@angular/common';
|
|
8
|
-
import * as i1 from '@bravobit/bb-foundation';
|
|
9
|
-
import * as i1$1 from '@bravobit/bb-foundation/elements';
|
|
10
|
-
import { BbButton, ElementsModule } from '@bravobit/bb-foundation/elements';
|
|
11
|
-
import { __awaiter } from 'tslib';
|
|
12
|
-
import * as i5 from '@bravobit/bb-foundation/utils';
|
|
13
|
-
import * as i9 from '@bravobit/bb-foundation/localize';
|
|
14
|
-
import { LocalizeModule } from '@bravobit/bb-foundation/localize';
|
|
15
|
-
|
|
16
|
-
class BbDialogRef {
|
|
17
|
-
constructor() {
|
|
18
|
-
// Data.
|
|
19
|
-
this._afterClosed$ = new Subject();
|
|
20
|
-
this._overlayClicked$ = new Subject();
|
|
21
|
-
}
|
|
22
|
-
get afterClosed() {
|
|
23
|
-
return this._afterClosed$.pipe(take(1));
|
|
24
|
-
}
|
|
25
|
-
get overlayClicked() {
|
|
26
|
-
return this._overlayClicked$.pipe(take(1));
|
|
27
|
-
}
|
|
28
|
-
onOverlayClicked() {
|
|
29
|
-
this._overlayClicked$.next();
|
|
30
|
-
}
|
|
31
|
-
close(result) {
|
|
32
|
-
this._afterClosed$.next(result);
|
|
33
|
-
}
|
|
34
|
-
}
|
|
35
|
-
|
|
36
|
-
class BbDialogConfig {
|
|
37
|
-
}
|
|
38
|
-
|
|
39
|
-
const bbDialogOverlayAnimation = trigger('bbDialogOverlayAnimation', [
|
|
40
|
-
transition(':enter, * => open', [
|
|
41
|
-
group([
|
|
42
|
-
query('.bb-dialog-overlay-backdrop', [
|
|
43
|
-
style({ opacity: 0 }),
|
|
44
|
-
animate('240ms cubic-bezier(0, 0, 0.2, 1)', style({ opacity: 1 }))
|
|
45
|
-
]),
|
|
46
|
-
query('.bb-dialog-modal', [
|
|
47
|
-
style({ opacity: 0, transform: 'scale(0.98)' }),
|
|
48
|
-
animate('200ms cubic-bezier(0, 0, 0.2, 1)', style({ opacity: 1, transform: 'none' }))
|
|
49
|
-
])
|
|
50
|
-
])
|
|
51
|
-
]),
|
|
52
|
-
transition(':leave, * => close', [
|
|
53
|
-
group([
|
|
54
|
-
query('.bb-dialog-modal', [
|
|
55
|
-
animate('200ms cubic-bezier(0, 0, 0.2, 1)', style({ opacity: 0, transform: 'scale(0.98)' }))
|
|
56
|
-
]),
|
|
57
|
-
query('.bb-dialog-overlay-backdrop', [
|
|
58
|
-
animate('240ms cubic-bezier(0, 0, 0.2, 1)', style({ opacity: 0 }))
|
|
59
|
-
])
|
|
60
|
-
])
|
|
61
|
-
])
|
|
62
|
-
]);
|
|
63
|
-
|
|
64
|
-
class BbDialogOverlay {
|
|
65
|
-
constructor(_elementRef, _changeDetection) {
|
|
66
|
-
this._elementRef = _elementRef;
|
|
67
|
-
this._changeDetection = _changeDetection;
|
|
68
|
-
// Outputs.
|
|
69
|
-
this.closeRequested = new EventEmitter();
|
|
70
|
-
// State.
|
|
71
|
-
this.state = 'open';
|
|
72
|
-
this._closed$ = new Subject();
|
|
73
|
-
// Subscriptions.
|
|
74
|
-
this._subscription = new Subscription();
|
|
75
|
-
}
|
|
76
|
-
ngOnInit() {
|
|
77
|
-
this.listenForClicks();
|
|
78
|
-
}
|
|
79
|
-
ngOnDestroy() {
|
|
80
|
-
var _a;
|
|
81
|
-
(_a = this._subscription) === null || _a === void 0 ? void 0 : _a.unsubscribe();
|
|
82
|
-
}
|
|
83
|
-
onKeyEvent(event) {
|
|
84
|
-
if ((event === null || event === void 0 ? void 0 : event.key) === 'Escape') {
|
|
85
|
-
this.closeRequested.emit();
|
|
86
|
-
}
|
|
87
|
-
}
|
|
88
|
-
onAnimationDone(event) {
|
|
89
|
-
// Check if the dialog is being destroyed.
|
|
90
|
-
if (!['close'].includes(event === null || event === void 0 ? void 0 : event.toState)) {
|
|
91
|
-
return;
|
|
92
|
-
}
|
|
93
|
-
this._closed$.next();
|
|
94
|
-
this._closed$.complete();
|
|
95
|
-
}
|
|
96
|
-
close() {
|
|
97
|
-
// We need change detection to run
|
|
98
|
-
// here else it won't close in all scenario's.
|
|
99
|
-
this.state = 'close';
|
|
100
|
-
this._changeDetection.markForCheck();
|
|
101
|
-
// Listen for the closed trigger.
|
|
102
|
-
const observable$ = this._closed$.pipe(take(1));
|
|
103
|
-
return lastValueFrom(observable$);
|
|
104
|
-
}
|
|
105
|
-
listenForClicks() {
|
|
106
|
-
var _a, _b;
|
|
107
|
-
const element = (_b = (_a = this._elementRef) === null || _a === void 0 ? void 0 : _a.nativeElement) !== null && _b !== void 0 ? _b : null;
|
|
108
|
-
if (!element) {
|
|
109
|
-
return;
|
|
110
|
-
}
|
|
111
|
-
const mouseDown$ = fromEvent(element, 'mousedown');
|
|
112
|
-
const touchStart$ = fromEvent(element, 'touchstart');
|
|
113
|
-
const start$ = race([mouseDown$, touchStart$]);
|
|
114
|
-
const mouseUp$ = fromEvent(element, 'mouseup');
|
|
115
|
-
const touchEnd$ = fromEvent(element, 'touchend');
|
|
116
|
-
const end$ = race([mouseUp$, touchEnd$]);
|
|
117
|
-
const clicks$ = start$.pipe(switchMap(() => end$));
|
|
118
|
-
const subscription = clicks$.subscribe(() => this.closeRequested.next());
|
|
119
|
-
this._subscription.add(subscription);
|
|
120
|
-
}
|
|
121
|
-
}
|
|
122
|
-
BbDialogOverlay.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.6", ngImport: i0, type: BbDialogOverlay, deps: [{ token: i0.ElementRef }, { token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
|
|
123
|
-
BbDialogOverlay.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.6", type: BbDialogOverlay, selector: "bb-dialog-overlay", outputs: { closeRequested: "closeRequested" }, host: { listeners: { "window:keyup": "onKeyEvent($event)", "@bbDialogOverlayAnimation.done": "onAnimationDone($event)" }, properties: { "@bbDialogOverlayAnimation": "state" }, classAttribute: "bb-dialog-overlay" }, ngImport: i0, template: "<div class=\"bb-dialog-overlay-backdrop\"></div>\n\n<ng-content select=\"[bb-dialog-modal]\"></ng-content>\n", styles: [".bb-dialog-overlay,.bb-dialog-overlay-backdrop{inset:0;display:flex;z-index:1000;position:fixed;flex-direction:column}.bb-dialog-overlay{padding:20px}.bb-dialog-overlay-backdrop{will-change:opacity;background-color:#1119}.bb-dialog-overlay-component{z-index:1001;display:block;position:relative}\n"], animations: [bbDialogOverlayAnimation], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
124
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.6", ngImport: i0, type: BbDialogOverlay, decorators: [{
|
|
125
|
-
type: Component,
|
|
126
|
-
args: [{ selector: 'bb-dialog-overlay', changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, preserveWhitespaces: false, host: {
|
|
127
|
-
'class': 'bb-dialog-overlay',
|
|
128
|
-
'[@bbDialogOverlayAnimation]': 'state'
|
|
129
|
-
}, animations: [bbDialogOverlayAnimation], template: "<div class=\"bb-dialog-overlay-backdrop\"></div>\n\n<ng-content select=\"[bb-dialog-modal]\"></ng-content>\n", styles: [".bb-dialog-overlay,.bb-dialog-overlay-backdrop{inset:0;display:flex;z-index:1000;position:fixed;flex-direction:column}.bb-dialog-overlay{padding:20px}.bb-dialog-overlay-backdrop{will-change:opacity;background-color:#1119}.bb-dialog-overlay-component{z-index:1001;display:block;position:relative}\n"] }]
|
|
130
|
-
}], ctorParameters: function () { return [{ type: i0.ElementRef }, { type: i0.ChangeDetectorRef }]; }, propDecorators: { closeRequested: [{
|
|
131
|
-
type: Output
|
|
132
|
-
}], onKeyEvent: [{
|
|
133
|
-
type: HostListener,
|
|
134
|
-
args: ['window:keyup', ['$event']]
|
|
135
|
-
}], onAnimationDone: [{
|
|
136
|
-
type: HostListener,
|
|
137
|
-
args: ['@bbDialogOverlayAnimation.done', ['$event']]
|
|
138
|
-
}] } });
|
|
139
|
-
|
|
140
|
-
class BbDialogModal {
|
|
141
|
-
onOverlayClickedEvent(event) {
|
|
142
|
-
event.stopPropagation();
|
|
143
|
-
}
|
|
144
|
-
constructor(_patch, _renderer, _document) {
|
|
145
|
-
this._patch = _patch;
|
|
146
|
-
this._renderer = _renderer;
|
|
147
|
-
this._document = _document;
|
|
148
|
-
// Styling.
|
|
149
|
-
this.maxWidth = '420px';
|
|
150
|
-
}
|
|
151
|
-
ngOnInit() {
|
|
152
|
-
this._patch.mobileVerticalHeight();
|
|
153
|
-
this.allowGlobalOverflow(false);
|
|
154
|
-
}
|
|
155
|
-
ngOnDestroy() {
|
|
156
|
-
this.allowGlobalOverflow(true);
|
|
157
|
-
}
|
|
158
|
-
allowGlobalOverflow(allow) {
|
|
159
|
-
var _a, _b;
|
|
160
|
-
const element = (_b = (_a = this._document) === null || _a === void 0 ? void 0 : _a.body) !== null && _b !== void 0 ? _b : null;
|
|
161
|
-
if (!element) {
|
|
162
|
-
return;
|
|
163
|
-
}
|
|
164
|
-
allow
|
|
165
|
-
? this._renderer.removeStyle(element, 'overflow')
|
|
166
|
-
: this._renderer.setStyle(element, 'overflow', 'hidden');
|
|
167
|
-
}
|
|
168
|
-
}
|
|
169
|
-
BbDialogModal.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.6", ngImport: i0, type: BbDialogModal, deps: [{ token: i1.Patch }, { token: i0.Renderer2 }, { token: DOCUMENT, optional: true }], target: i0.ɵɵFactoryTarget.Component });
|
|
170
|
-
BbDialogModal.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.6", type: BbDialogModal, selector: "[bb-dialog-modal]", inputs: { maxWidth: "maxWidth" }, host: { attributes: { "role": "dialog" }, listeners: { "click": "onOverlayClickedEvent($event)", "touchstart": "onOverlayClickedEvent($event)", "touchend": "onOverlayClickedEvent($event)", "mouseup": "onOverlayClickedEvent($event)", "mousedown": "onOverlayClickedEvent($event)" }, properties: { "style.max-width": "this.maxWidth" }, classAttribute: "bb-dialog-modal" }, ngImport: i0, template: "<ng-content select=\"[bb-dialog-header]\">\n\n</ng-content>\n\n<div class=\"bb-dialog-modal-body\">\n <ng-content></ng-content>\n</div>\n\n<ng-content select=\"[bb-dialog-actions]\">\n\n</ng-content>\n", styles: [".bb-dialog-modal{width:100%;margin:auto;z-index:1001;display:flex;max-width:420px;border-radius:4px;position:relative;flex-direction:column;background-color:#fff;will-change:opacity,transform;max-height:calc(var(--vh, 1vh) * 100 - 40px)}.bb-dialog-modal-body{padding:20px;color:#738694;font-size:13px;overflow-y:auto;line-height:1.4;background-color:#f1f3f6}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
171
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.6", ngImport: i0, type: BbDialogModal, decorators: [{
|
|
172
|
-
type: Component,
|
|
173
|
-
args: [{ selector: '[bb-dialog-modal]', changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, preserveWhitespaces: false, host: {
|
|
174
|
-
'class': 'bb-dialog-modal',
|
|
175
|
-
'role': 'dialog'
|
|
176
|
-
}, template: "<ng-content select=\"[bb-dialog-header]\">\n\n</ng-content>\n\n<div class=\"bb-dialog-modal-body\">\n <ng-content></ng-content>\n</div>\n\n<ng-content select=\"[bb-dialog-actions]\">\n\n</ng-content>\n", styles: [".bb-dialog-modal{width:100%;margin:auto;z-index:1001;display:flex;max-width:420px;border-radius:4px;position:relative;flex-direction:column;background-color:#fff;will-change:opacity,transform;max-height:calc(var(--vh, 1vh) * 100 - 40px)}.bb-dialog-modal-body{padding:20px;color:#738694;font-size:13px;overflow-y:auto;line-height:1.4;background-color:#f1f3f6}\n"] }]
|
|
177
|
-
}], ctorParameters: function () {
|
|
178
|
-
return [{ type: i1.Patch }, { type: i0.Renderer2 }, { type: Document, decorators: [{
|
|
179
|
-
type: Optional
|
|
180
|
-
}, {
|
|
181
|
-
type: Inject,
|
|
182
|
-
args: [DOCUMENT]
|
|
183
|
-
}] }];
|
|
184
|
-
}, propDecorators: { maxWidth: [{
|
|
185
|
-
type: HostBinding,
|
|
186
|
-
args: ['style.max-width']
|
|
187
|
-
}, {
|
|
188
|
-
type: Input
|
|
189
|
-
}], onOverlayClickedEvent: [{
|
|
190
|
-
type: HostListener,
|
|
191
|
-
args: ['click', ['$event']]
|
|
192
|
-
}, {
|
|
193
|
-
type: HostListener,
|
|
194
|
-
args: ['touchstart', ['$event']]
|
|
195
|
-
}, {
|
|
196
|
-
type: HostListener,
|
|
197
|
-
args: ['touchend', ['$event']]
|
|
198
|
-
}, {
|
|
199
|
-
type: HostListener,
|
|
200
|
-
args: ['mouseup', ['$event']]
|
|
201
|
-
}, {
|
|
202
|
-
type: HostListener,
|
|
203
|
-
args: ['mousedown', ['$event']]
|
|
204
|
-
}] } });
|
|
205
|
-
|
|
206
|
-
class BbDialogHeader {
|
|
207
|
-
constructor() {
|
|
208
|
-
// Outputs.
|
|
209
|
-
this.closeRequested = new EventEmitter();
|
|
210
|
-
}
|
|
211
|
-
}
|
|
212
|
-
BbDialogHeader.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.6", ngImport: i0, type: BbDialogHeader, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
213
|
-
BbDialogHeader.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.6", type: BbDialogHeader, selector: "[bb-dialog-header]", outputs: { closeRequested: "closeRequested" }, host: { classAttribute: "bb-dialog-header" }, ngImport: i0, template: "<div class=\"bb-dialog-header-row\">\n <div class=\"bb-dialog-header-content\">\n <ng-content></ng-content>\n </div>\n\n <button *ngIf=\"closeRequested?.observed\"\n (click)=\"closeRequested?.emit()\"\n type=\"button\"\n class=\"bb-dialog-header-close\">\n </button>\n</div>\n\n<nav class=\"bb-dialog-header-navigation\">\n <ng-content select=\"[bb-dialog-link]\"></ng-content>\n</nav>\n", styles: [".bb-dialog-header{display:flex;min-height:60px;flex-direction:column;justify-content:center;background-color:#fff;border-top-left-radius:4px;border-top-right-radius:4px;border-bottom:1px solid #d8d8d8}.bb-dialog-header .bb-dialog-header-content,.bb-dialog-header .bb-dialog-header-content h1{max-width:100%;font-size:20px;font-weight:500;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}.bb-dialog-header-row,.bb-dialog-header-navigation{width:100%;display:flex;align-items:center}.bb-dialog-header-row{padding:10px 20px}.bb-dialog-header-navigation{width:100%;padding:0 20px;overflow-x:auto;white-space:nowrap}.bb-dialog-header-navigation:empty{margin:0;height:0;padding:0;visibility:hidden}.bb-dialog-header-content{flex:1}.bb-dialog-header-close{width:32px;height:32px;border:none;min-width:32px;min-height:32px;overflow:hidden;margin-left:10px;border-radius:4px;position:relative;margin-right:-10px;display:inline-block;background-color:transparent}.bb-dialog-header-close:before,.bb-dialog-header-close:after{top:50%;left:20%;width:60%;height:2px;content:\"\";margin-top:-1px;position:absolute;background-color:#a2a9ba}.bb-dialog-header-close:before{transform:rotate(45deg)}.bb-dialog-header-close:after{transform:rotate(-45deg)}.bb-dialog-header-close:hover{background-color:#00000014}.bb-dialog-header-close:focus{background-color:#0000001f}.bb-dialog-header-close:active{background-color:#00000029}\n"], dependencies: [{ kind: "directive", type: i3.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
214
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.6", ngImport: i0, type: BbDialogHeader, decorators: [{
|
|
215
|
-
type: Component,
|
|
216
|
-
args: [{ selector: '[bb-dialog-header]', changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, preserveWhitespaces: false, host: { 'class': 'bb-dialog-header' }, template: "<div class=\"bb-dialog-header-row\">\n <div class=\"bb-dialog-header-content\">\n <ng-content></ng-content>\n </div>\n\n <button *ngIf=\"closeRequested?.observed\"\n (click)=\"closeRequested?.emit()\"\n type=\"button\"\n class=\"bb-dialog-header-close\">\n </button>\n</div>\n\n<nav class=\"bb-dialog-header-navigation\">\n <ng-content select=\"[bb-dialog-link]\"></ng-content>\n</nav>\n", styles: [".bb-dialog-header{display:flex;min-height:60px;flex-direction:column;justify-content:center;background-color:#fff;border-top-left-radius:4px;border-top-right-radius:4px;border-bottom:1px solid #d8d8d8}.bb-dialog-header .bb-dialog-header-content,.bb-dialog-header .bb-dialog-header-content h1{max-width:100%;font-size:20px;font-weight:500;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}.bb-dialog-header-row,.bb-dialog-header-navigation{width:100%;display:flex;align-items:center}.bb-dialog-header-row{padding:10px 20px}.bb-dialog-header-navigation{width:100%;padding:0 20px;overflow-x:auto;white-space:nowrap}.bb-dialog-header-navigation:empty{margin:0;height:0;padding:0;visibility:hidden}.bb-dialog-header-content{flex:1}.bb-dialog-header-close{width:32px;height:32px;border:none;min-width:32px;min-height:32px;overflow:hidden;margin-left:10px;border-radius:4px;position:relative;margin-right:-10px;display:inline-block;background-color:transparent}.bb-dialog-header-close:before,.bb-dialog-header-close:after{top:50%;left:20%;width:60%;height:2px;content:\"\";margin-top:-1px;position:absolute;background-color:#a2a9ba}.bb-dialog-header-close:before{transform:rotate(45deg)}.bb-dialog-header-close:after{transform:rotate(-45deg)}.bb-dialog-header-close:hover{background-color:#00000014}.bb-dialog-header-close:focus{background-color:#0000001f}.bb-dialog-header-close:active{background-color:#00000029}\n"] }]
|
|
217
|
-
}], propDecorators: { closeRequested: [{
|
|
218
|
-
type: Output
|
|
219
|
-
}] } });
|
|
220
|
-
|
|
221
|
-
class BbDialogLink {
|
|
222
|
-
}
|
|
223
|
-
BbDialogLink.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.6", ngImport: i0, type: BbDialogLink, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
224
|
-
BbDialogLink.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.6", type: BbDialogLink, selector: "[bb-dialog-link]", host: { classAttribute: "bb-dialog-link" }, ngImport: i0, template: "<ng-content></ng-content>\n", styles: [".bb-dialog-link{border:none;height:30px;display:flex;font-size:16px;-webkit-appearance:none;appearance:none;font-weight:500;white-space:nowrap;align-items:center;color:#6b5c5c!important;background-color:transparent;text-decoration:none!important;border-bottom:2px solid transparent}.bb-dialog-link+.bb-dialog-link{margin-left:10px}.bb-dialog-link:hover:not(.disabled){border-bottom:2px solid rgba(117,119,148,.2)}.bb-dialog-link.active,.bb-dialog-link.active:hover{color:#5b53ff!important;border-bottom-color:#5b53ff}.bb-dialog-link.disabled,.bb-dialog-link.disabled:focus,.bb-dialog-link.disabled:hover,.bb-dialog-link.disabled:active{opacity:.4;cursor:default;box-shadow:none}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
225
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.6", ngImport: i0, type: BbDialogLink, decorators: [{
|
|
226
|
-
type: Component,
|
|
227
|
-
args: [{ selector: '[bb-dialog-link]', changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, preserveWhitespaces: false, host: { 'class': 'bb-dialog-link' }, template: "<ng-content></ng-content>\n", styles: [".bb-dialog-link{border:none;height:30px;display:flex;font-size:16px;-webkit-appearance:none;appearance:none;font-weight:500;white-space:nowrap;align-items:center;color:#6b5c5c!important;background-color:transparent;text-decoration:none!important;border-bottom:2px solid transparent}.bb-dialog-link+.bb-dialog-link{margin-left:10px}.bb-dialog-link:hover:not(.disabled){border-bottom:2px solid rgba(117,119,148,.2)}.bb-dialog-link.active,.bb-dialog-link.active:hover{color:#5b53ff!important;border-bottom-color:#5b53ff}.bb-dialog-link.disabled,.bb-dialog-link.disabled:focus,.bb-dialog-link.disabled:hover,.bb-dialog-link.disabled:active{opacity:.4;cursor:default;box-shadow:none}\n"] }]
|
|
228
|
-
}] });
|
|
229
|
-
|
|
230
|
-
class BbDialogActions {
|
|
231
|
-
}
|
|
232
|
-
BbDialogActions.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.6", ngImport: i0, type: BbDialogActions, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
233
|
-
BbDialogActions.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.6", type: BbDialogActions, selector: "[bb-dialog-actions]", host: { classAttribute: "bb-dialog-actions" }, ngImport: i0, template: "<bb-form-group class=\"end\">\n <ng-content></ng-content>\n</bb-form-group>\n", styles: [".bb-dialog-actions{padding:20px;display:block;background-color:#fff;border-top:1px solid #d8d8d8;border-bottom-left-radius:4px;border-bottom-right-radius:4px}\n"], dependencies: [{ kind: "component", type: i1$1.BbFormGroup, selector: "bb-form-group", inputs: ["grouped"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
234
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.6", ngImport: i0, type: BbDialogActions, decorators: [{
|
|
235
|
-
type: Component,
|
|
236
|
-
args: [{ selector: '[bb-dialog-actions]', changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, preserveWhitespaces: false, host: { 'class': 'bb-dialog-actions' }, template: "<bb-form-group class=\"end\">\n <ng-content></ng-content>\n</bb-form-group>\n", styles: [".bb-dialog-actions{padding:20px;display:block;background-color:#fff;border-top:1px solid #d8d8d8;border-bottom-left-radius:4px;border-bottom-right-radius:4px}\n"] }]
|
|
237
|
-
}] });
|
|
238
|
-
|
|
239
|
-
const bbDialogContainerAnimation = trigger('bbDialogContainerAnimation', [
|
|
240
|
-
transition(':enter', [
|
|
241
|
-
group([
|
|
242
|
-
query('.bb-dialog-container-backdrop', [
|
|
243
|
-
style({ opacity: 0 }),
|
|
244
|
-
animate('180ms cubic-bezier(0, 0, 0.2, 1)', style({ opacity: 1 }))
|
|
245
|
-
]),
|
|
246
|
-
query('.bb-dialog-container-component', [
|
|
247
|
-
style({ opacity: 0, transform: 'scale(0.96)' }),
|
|
248
|
-
animate('180ms cubic-bezier(0, 0, 0.2, 1)', style({ opacity: 1, transform: 'none' }))
|
|
249
|
-
])
|
|
250
|
-
])
|
|
251
|
-
]),
|
|
252
|
-
transition(':leave', [
|
|
253
|
-
group([
|
|
254
|
-
query('.bb-dialog-container-backdrop', [
|
|
255
|
-
animate('180ms cubic-bezier(0, 0, 0.2, 1)', style({ opacity: 0 }))
|
|
256
|
-
]),
|
|
257
|
-
query('.bb-dialog-container-component', [
|
|
258
|
-
animate('180ms cubic-bezier(0, 0, 0.2, 1)', style({
|
|
259
|
-
opacity: 0,
|
|
260
|
-
transform: 'scale(0.96)'
|
|
261
|
-
}))
|
|
262
|
-
])
|
|
263
|
-
])
|
|
264
|
-
])
|
|
265
|
-
]);
|
|
266
|
-
|
|
267
|
-
class BbDialogInsertion {
|
|
268
|
-
constructor(viewContainerRef) {
|
|
269
|
-
this.viewContainerRef = viewContainerRef;
|
|
270
|
-
}
|
|
271
|
-
}
|
|
272
|
-
BbDialogInsertion.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.6", ngImport: i0, type: BbDialogInsertion, deps: [{ token: i0.ViewContainerRef }], target: i0.ɵɵFactoryTarget.Directive });
|
|
273
|
-
BbDialogInsertion.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "15.2.6", type: BbDialogInsertion, selector: "[bbDialogInsertion]", ngImport: i0 });
|
|
274
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.6", ngImport: i0, type: BbDialogInsertion, decorators: [{
|
|
275
|
-
type: Directive,
|
|
276
|
-
args: [{
|
|
277
|
-
selector: '[bbDialogInsertion]'
|
|
278
|
-
}]
|
|
279
|
-
}], ctorParameters: function () { return [{ type: i0.ViewContainerRef }]; } });
|
|
280
|
-
|
|
281
|
-
class BbDialogContainer {
|
|
282
|
-
get onOverlayClicked() {
|
|
283
|
-
return this.overlayClicked$.pipe(take(1));
|
|
284
|
-
}
|
|
285
|
-
constructor(_elementRef) {
|
|
286
|
-
this._elementRef = _elementRef;
|
|
287
|
-
// Data.
|
|
288
|
-
this.componentRef = null;
|
|
289
|
-
this.childComponentType = null;
|
|
290
|
-
// State.
|
|
291
|
-
this.overlayClicked$ = new Subject();
|
|
292
|
-
// Subscription.
|
|
293
|
-
this._subscription = new Subscription();
|
|
294
|
-
}
|
|
295
|
-
ngOnInit() {
|
|
296
|
-
// Load the child component.
|
|
297
|
-
this.loadChildComponent(this.childComponentType);
|
|
298
|
-
// Listen for mouse click on the dialog container.
|
|
299
|
-
this.listenForClicks();
|
|
300
|
-
}
|
|
301
|
-
ngOnDestroy() {
|
|
302
|
-
var _a;
|
|
303
|
-
(_a = this._subscription) === null || _a === void 0 ? void 0 : _a.unsubscribe();
|
|
304
|
-
}
|
|
305
|
-
onAnimationDone(event) {
|
|
306
|
-
var _a;
|
|
307
|
-
// Check if the dialog is being destroyed.
|
|
308
|
-
if ((event === null || event === void 0 ? void 0 : event.toState) !== 'void') {
|
|
309
|
-
return;
|
|
310
|
-
}
|
|
311
|
-
// Destroy the ref if it exists.
|
|
312
|
-
(_a = this.componentRef) === null || _a === void 0 ? void 0 : _a.destroy();
|
|
313
|
-
}
|
|
314
|
-
listenForClicks() {
|
|
315
|
-
var _a, _b;
|
|
316
|
-
const element = (_b = (_a = this._elementRef) === null || _a === void 0 ? void 0 : _a.nativeElement) !== null && _b !== void 0 ? _b : null;
|
|
317
|
-
if (!element) {
|
|
318
|
-
return;
|
|
319
|
-
}
|
|
320
|
-
const mouseDown$ = fromEvent(element, 'mousedown');
|
|
321
|
-
const touchStart$ = fromEvent(element, 'touchstart');
|
|
322
|
-
const start$ = race([mouseDown$, touchStart$]);
|
|
323
|
-
const mouseUp$ = fromEvent(element, 'mouseup');
|
|
324
|
-
const touchEnd$ = fromEvent(element, 'touchend');
|
|
325
|
-
const end$ = race([mouseUp$, touchEnd$]);
|
|
326
|
-
const clicks$ = start$.pipe(switchMap(() => end$));
|
|
327
|
-
const subscription = clicks$.subscribe(() => this.overlayClicked$.next());
|
|
328
|
-
this._subscription.add(subscription);
|
|
329
|
-
}
|
|
330
|
-
loadChildComponent(componentType) {
|
|
331
|
-
// Get the view container ref and clear it.
|
|
332
|
-
const viewContainerRef = this.insertion.viewContainerRef;
|
|
333
|
-
viewContainerRef.clear();
|
|
334
|
-
// Create an instance of the component.
|
|
335
|
-
this.componentRef = viewContainerRef.createComponent(componentType);
|
|
336
|
-
}
|
|
337
|
-
}
|
|
338
|
-
BbDialogContainer.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.6", ngImport: i0, type: BbDialogContainer, deps: [{ token: i0.ElementRef }], target: i0.ɵɵFactoryTarget.Component });
|
|
339
|
-
BbDialogContainer.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.6", type: BbDialogContainer, selector: "bb-dialog-container", host: { listeners: { "@bbDialogContainerAnimation.done": "onAnimationDone($event)" }, properties: { "@bbDialogContainerAnimation": "true" }, classAttribute: "bb-dialog-container" }, viewQueries: [{ propertyName: "insertion", first: true, predicate: BbDialogInsertion, descendants: true, static: true }], ngImport: i0, template: "<div class=\"bb-dialog-container-backdrop\"></div>\n\n<div class=\"bb-dialog-container-component\">\n <ng-container bbDialogInsertion></ng-container>\n</div>\n", styles: [".bb-dialog-container,.bb-dialog-container-backdrop{inset:0;z-index:1000;position:fixed}.bb-dialog-container{display:flex}.bb-dialog-container-backdrop{will-change:opacity;background-color:#1119}.bb-dialog-container-component{width:100%;margin:auto;padding:20px;z-index:1001;display:block;will-change:opacity,transform}\n"], dependencies: [{ kind: "directive", type: BbDialogInsertion, selector: "[bbDialogInsertion]" }], animations: [bbDialogContainerAnimation], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
340
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.6", ngImport: i0, type: BbDialogContainer, decorators: [{
|
|
341
|
-
type: Component,
|
|
342
|
-
args: [{ selector: 'bb-dialog-container', changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, host: {
|
|
343
|
-
'class': 'bb-dialog-container',
|
|
344
|
-
'[@bbDialogContainerAnimation]': 'true'
|
|
345
|
-
}, preserveWhitespaces: false, animations: [bbDialogContainerAnimation], template: "<div class=\"bb-dialog-container-backdrop\"></div>\n\n<div class=\"bb-dialog-container-component\">\n <ng-container bbDialogInsertion></ng-container>\n</div>\n", styles: [".bb-dialog-container,.bb-dialog-container-backdrop{inset:0;z-index:1000;position:fixed}.bb-dialog-container{display:flex}.bb-dialog-container-backdrop{will-change:opacity;background-color:#1119}.bb-dialog-container-component{width:100%;margin:auto;padding:20px;z-index:1001;display:block;will-change:opacity,transform}\n"] }]
|
|
346
|
-
}], ctorParameters: function () { return [{ type: i0.ElementRef }]; }, propDecorators: { insertion: [{
|
|
347
|
-
type: ViewChild,
|
|
348
|
-
args: [BbDialogInsertion, { static: true }]
|
|
349
|
-
}], onAnimationDone: [{
|
|
350
|
-
type: HostListener,
|
|
351
|
-
args: ['@bbDialogContainerAnimation.done', ['$event']]
|
|
352
|
-
}] } });
|
|
353
|
-
|
|
354
|
-
let nextUniqueId = 0;
|
|
355
|
-
class BbDialogConfirm {
|
|
356
|
-
constructor(_config, _dialogRef) {
|
|
357
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v, _w;
|
|
358
|
-
this._config = _config;
|
|
359
|
-
this._dialogRef = _dialogRef;
|
|
360
|
-
// Readonly data.
|
|
361
|
-
this.title = (_c = (_b = (_a = this._config) === null || _a === void 0 ? void 0 : _a.data) === null || _b === void 0 ? void 0 : _b.title) !== null && _c !== void 0 ? _c : null;
|
|
362
|
-
this.description = (_f = (_e = (_d = this._config) === null || _d === void 0 ? void 0 : _d.data) === null || _e === void 0 ? void 0 : _e.description) !== null && _f !== void 0 ? _f : null;
|
|
363
|
-
this.confirmButtonText = (_j = (_h = (_g = this._config) === null || _g === void 0 ? void 0 : _g.data) === null || _h === void 0 ? void 0 : _h.confirmButtonText) !== null && _j !== void 0 ? _j : 'dialog.default_confirm_button';
|
|
364
|
-
this.cancelButtonText = (_m = (_l = (_k = this._config) === null || _k === void 0 ? void 0 : _k.data) === null || _l === void 0 ? void 0 : _l.cancelButtonText) !== null && _m !== void 0 ? _m : 'dialog.default_cancel_button';
|
|
365
|
-
this.confirmButtonClass = (_q = (_p = (_o = this._config) === null || _o === void 0 ? void 0 : _o.data) === null || _p === void 0 ? void 0 : _p.confirmButtonClass) !== null && _q !== void 0 ? _q : null;
|
|
366
|
-
this.cancelButtonClass = (_t = (_s = (_r = this._config) === null || _r === void 0 ? void 0 : _r.data) === null || _s === void 0 ? void 0 : _s.cancelButtonClass) !== null && _t !== void 0 ? _t : null;
|
|
367
|
-
this.width = (_w = (_v = (_u = this._config) === null || _u === void 0 ? void 0 : _u.data) === null || _v === void 0 ? void 0 : _v.width) !== null && _w !== void 0 ? _w : '420px';
|
|
368
|
-
// Id.
|
|
369
|
-
this.dialogId = `bb-dialog-confirm-${nextUniqueId++}`;
|
|
370
|
-
}
|
|
371
|
-
ngAfterViewInit() {
|
|
372
|
-
var _a;
|
|
373
|
-
// Initial focus the button.
|
|
374
|
-
(_a = this.confirmButton) === null || _a === void 0 ? void 0 : _a.focus();
|
|
375
|
-
}
|
|
376
|
-
onClose(result) {
|
|
377
|
-
this._dialogRef.close(result);
|
|
378
|
-
}
|
|
379
|
-
}
|
|
380
|
-
BbDialogConfirm.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.6", ngImport: i0, type: BbDialogConfirm, deps: [{ token: BbDialogConfig }, { token: BbDialogRef }], target: i0.ɵɵFactoryTarget.Component });
|
|
381
|
-
BbDialogConfirm.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.6", type: BbDialogConfirm, selector: "bb-dialog-confirm", host: { classAttribute: "bb-dialog-confirm" }, viewQueries: [{ propertyName: "confirmButton", first: true, predicate: ["confirm"], descendants: true, read: BbButton }], ngImport: i0, template: "<div [attr.aria-labelledby]=\"dialogId\"\n [maxWidth]=\"width\"\n bb-dialog-modal\n bbFocusTrap>\n <header bb-dialog-header>\n <h1 *ngIf=\"title as titleContent\"\n [id]=\"dialogId\">\n <ng-template [bbTemplate]=\"titleContent\">\n {{ $any(titleContent) | bbLocalize:{optional: true} }}\n </ng-template>\n </h1>\n </header>\n\n <p *ngIf=\"description as descriptionContent\"\n class=\"bb-dialog-confirm-description\">\n <ng-template [bbTemplate]=\"descriptionContent\">\n {{ $any(descriptionContent) | bbLocalize:{optional: true} }}\n </ng-template>\n </p>\n\n <footer bb-dialog-actions>\n <button *ngIf=\"cancelButtonText as cancelButtonTextLabel\"\n [ngClass]=\"cancelButtonClass ? cancelButtonClass : null\"\n (click)=\"onClose(false)\"\n bb-button\n type=\"button\">\n {{ cancelButtonTextLabel | bbLocalize:{optional: true} }}\n </button>\n <button #confirm\n *ngIf=\"confirmButtonText as confirmButtonTextLabel\"\n [ngClass]=\"confirmButtonClass ? confirmButtonClass : 'destructive'\"\n (click)=\"onClose(true)\"\n bb-button\n type=\"button\">\n {{ confirmButtonTextLabel | bbLocalize:{optional: true} }}\n </button>\n </footer>\n</div>\n", styles: [".bb-dialog-confirm{display:block}.bb-dialog-confirm-description{line-height:2}\n"], dependencies: [{ kind: "directive", type: i3.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i3.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i1$1.BbButton, selector: "button[bb-button]", inputs: ["disabled", "loading"], exportAs: ["bbButton"] }, { kind: "directive", type: i5.BbTemplate, selector: "[bbTemplate]", inputs: ["bbTemplate"] }, { kind: "directive", type: i5.BbFocusTrap, selector: "[bbFocusTrap]" }, { kind: "component", type: BbDialogModal, selector: "[bb-dialog-modal]", inputs: ["maxWidth"] }, { kind: "component", type: BbDialogHeader, selector: "[bb-dialog-header]", outputs: ["closeRequested"] }, { kind: "component", type: BbDialogActions, selector: "[bb-dialog-actions]" }, { kind: "pipe", type: i9.BbLocalize, name: "bbLocalize" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
382
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.6", ngImport: i0, type: BbDialogConfirm, decorators: [{
|
|
383
|
-
type: Component,
|
|
384
|
-
args: [{ selector: 'bb-dialog-confirm', changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, preserveWhitespaces: false, host: { 'class': 'bb-dialog-confirm' }, template: "<div [attr.aria-labelledby]=\"dialogId\"\n [maxWidth]=\"width\"\n bb-dialog-modal\n bbFocusTrap>\n <header bb-dialog-header>\n <h1 *ngIf=\"title as titleContent\"\n [id]=\"dialogId\">\n <ng-template [bbTemplate]=\"titleContent\">\n {{ $any(titleContent) | bbLocalize:{optional: true} }}\n </ng-template>\n </h1>\n </header>\n\n <p *ngIf=\"description as descriptionContent\"\n class=\"bb-dialog-confirm-description\">\n <ng-template [bbTemplate]=\"descriptionContent\">\n {{ $any(descriptionContent) | bbLocalize:{optional: true} }}\n </ng-template>\n </p>\n\n <footer bb-dialog-actions>\n <button *ngIf=\"cancelButtonText as cancelButtonTextLabel\"\n [ngClass]=\"cancelButtonClass ? cancelButtonClass : null\"\n (click)=\"onClose(false)\"\n bb-button\n type=\"button\">\n {{ cancelButtonTextLabel | bbLocalize:{optional: true} }}\n </button>\n <button #confirm\n *ngIf=\"confirmButtonText as confirmButtonTextLabel\"\n [ngClass]=\"confirmButtonClass ? confirmButtonClass : 'destructive'\"\n (click)=\"onClose(true)\"\n bb-button\n type=\"button\">\n {{ confirmButtonTextLabel | bbLocalize:{optional: true} }}\n </button>\n </footer>\n</div>\n", styles: [".bb-dialog-confirm{display:block}.bb-dialog-confirm-description{line-height:2}\n"] }]
|
|
385
|
-
}], ctorParameters: function () { return [{ type: BbDialogConfig }, { type: BbDialogRef }]; }, propDecorators: { confirmButton: [{
|
|
386
|
-
type: ViewChild,
|
|
387
|
-
args: ['confirm', { read: BbButton, static: false }]
|
|
388
|
-
}] } });
|
|
389
|
-
|
|
390
|
-
class Dialog {
|
|
391
|
-
constructor(_injector, _applicationRef, _environmentInjector) {
|
|
392
|
-
this._injector = _injector;
|
|
393
|
-
this._applicationRef = _applicationRef;
|
|
394
|
-
this._environmentInjector = _environmentInjector;
|
|
395
|
-
}
|
|
396
|
-
open(componentType, config) {
|
|
397
|
-
return this.createDialog(componentType, config);
|
|
398
|
-
}
|
|
399
|
-
confirm(title, description, options) {
|
|
400
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
401
|
-
const dialogRef = this.open(BbDialogConfirm, {
|
|
402
|
-
data: Object.assign({ title, description }, (options !== null && options !== void 0 ? options : {}))
|
|
403
|
-
});
|
|
404
|
-
return yield firstValueFrom(dialogRef.afterClosed);
|
|
405
|
-
});
|
|
406
|
-
}
|
|
407
|
-
createDialog(componentType, config) {
|
|
408
|
-
// Create a reference.
|
|
409
|
-
const dialogRef = new BbDialogRef();
|
|
410
|
-
const environmentInjector = createEnvironmentInjector([
|
|
411
|
-
{ provide: BbDialogConfig, useValue: config !== null && config !== void 0 ? config : {} },
|
|
412
|
-
{ provide: BbDialogRef, useValue: dialogRef }
|
|
413
|
-
], this._environmentInjector);
|
|
414
|
-
const dialogComponentRef = createComponent(BbDialogContainer, { environmentInjector });
|
|
415
|
-
// Attach the host view to the application.
|
|
416
|
-
this._applicationRef.attachView(dialogComponentRef.hostView);
|
|
417
|
-
try {
|
|
418
|
-
// Remove the current focus.
|
|
419
|
-
const activeElement = document.activeElement;
|
|
420
|
-
activeElement.blur();
|
|
421
|
-
// Append the element to the DOM.
|
|
422
|
-
document.body.appendChild(dialogComponentRef.location.nativeElement);
|
|
423
|
-
}
|
|
424
|
-
catch (_a) {
|
|
425
|
-
// Don't do anything, because it must've failed.
|
|
426
|
-
}
|
|
427
|
-
// Set the child component type on the component.
|
|
428
|
-
dialogComponentRef.instance.childComponentType = componentType;
|
|
429
|
-
dialogComponentRef.instance.onOverlayClicked.subscribe(() => dialogRef.onOverlayClicked());
|
|
430
|
-
// Listen for close events.
|
|
431
|
-
dialogRef.afterClosed.subscribe(() => this.deleteDialog(dialogComponentRef));
|
|
432
|
-
// Return the reference.
|
|
433
|
-
return dialogRef;
|
|
434
|
-
}
|
|
435
|
-
deleteDialog(dialogComponentRef) {
|
|
436
|
-
// Only continue if the dialog component ref exists.
|
|
437
|
-
if (!dialogComponentRef) {
|
|
438
|
-
return;
|
|
439
|
-
}
|
|
440
|
-
// Detach the dialog.
|
|
441
|
-
this._applicationRef.detachView(dialogComponentRef.hostView);
|
|
442
|
-
// Destroy the dialog.
|
|
443
|
-
dialogComponentRef.destroy();
|
|
444
|
-
dialogComponentRef = null;
|
|
445
|
-
}
|
|
446
|
-
}
|
|
447
|
-
Dialog.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.6", ngImport: i0, type: Dialog, deps: [{ token: i0.Injector }, { token: i0.ApplicationRef }, { token: i0.EnvironmentInjector }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
448
|
-
Dialog.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.2.6", ngImport: i0, type: Dialog });
|
|
449
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.6", ngImport: i0, type: Dialog, decorators: [{
|
|
450
|
-
type: Injectable
|
|
451
|
-
}], ctorParameters: function () { return [{ type: i0.Injector }, { type: i0.ApplicationRef }, { type: i0.EnvironmentInjector }]; } });
|
|
452
|
-
|
|
453
|
-
class DialogModule {
|
|
454
|
-
static forRoot() {
|
|
455
|
-
return {
|
|
456
|
-
ngModule: DialogModule,
|
|
457
|
-
providers: [Dialog]
|
|
458
|
-
};
|
|
459
|
-
}
|
|
460
|
-
}
|
|
461
|
-
DialogModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.6", ngImport: i0, type: DialogModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
462
|
-
DialogModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.2.6", ngImport: i0, type: DialogModule, declarations: [BbDialogContainer,
|
|
463
|
-
BbDialogOverlay,
|
|
464
|
-
BbDialogModal,
|
|
465
|
-
BbDialogHeader,
|
|
466
|
-
BbDialogLink,
|
|
467
|
-
BbDialogActions,
|
|
468
|
-
BbDialogConfirm,
|
|
469
|
-
BbDialogInsertion], imports: [CommonModule,
|
|
470
|
-
LocalizeModule,
|
|
471
|
-
ElementsModule], exports: [BbDialogOverlay,
|
|
472
|
-
BbDialogModal,
|
|
473
|
-
BbDialogHeader,
|
|
474
|
-
BbDialogLink,
|
|
475
|
-
BbDialogActions] });
|
|
476
|
-
DialogModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.2.6", ngImport: i0, type: DialogModule, imports: [CommonModule,
|
|
477
|
-
LocalizeModule,
|
|
478
|
-
ElementsModule] });
|
|
479
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.6", ngImport: i0, type: DialogModule, decorators: [{
|
|
480
|
-
type: NgModule,
|
|
481
|
-
args: [{
|
|
482
|
-
imports: [
|
|
483
|
-
CommonModule,
|
|
484
|
-
LocalizeModule,
|
|
485
|
-
ElementsModule
|
|
486
|
-
],
|
|
487
|
-
declarations: [
|
|
488
|
-
BbDialogContainer,
|
|
489
|
-
BbDialogOverlay,
|
|
490
|
-
BbDialogModal,
|
|
491
|
-
BbDialogHeader,
|
|
492
|
-
BbDialogLink,
|
|
493
|
-
BbDialogActions,
|
|
494
|
-
BbDialogConfirm,
|
|
495
|
-
BbDialogInsertion
|
|
496
|
-
],
|
|
497
|
-
exports: [
|
|
498
|
-
BbDialogOverlay,
|
|
499
|
-
BbDialogModal,
|
|
500
|
-
BbDialogHeader,
|
|
501
|
-
BbDialogLink,
|
|
502
|
-
BbDialogActions
|
|
503
|
-
]
|
|
504
|
-
}]
|
|
505
|
-
}] });
|
|
506
|
-
|
|
507
|
-
/**
|
|
508
|
-
* Generated bundle index. Do not edit.
|
|
509
|
-
*/
|
|
510
|
-
|
|
511
|
-
export { BbDialogActions, BbDialogConfig, BbDialogHeader, BbDialogLink, BbDialogModal, BbDialogOverlay, BbDialogRef, Dialog, DialogModule };
|
|
512
|
-
//# sourceMappingURL=bravobit-bb-foundation-dialog.mjs.map
|