@skyux/layout 5.7.2 → 6.0.0-beta.2
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/documentation.json +4 -4
- package/esm2020/index.mjs +74 -0
- package/esm2020/lib/modules/action-button/action-button-adapter-service.mjs +43 -0
- package/esm2020/lib/modules/action-button/action-button-container.component.mjs +139 -0
- package/esm2020/lib/modules/action-button/action-button-details.component.mjs +14 -0
- package/esm2020/lib/modules/action-button/action-button-header.component.mjs +15 -0
- package/esm2020/lib/modules/action-button/action-button-icon.component.mjs +40 -0
- package/esm2020/lib/modules/action-button/action-button-permalink.mjs +2 -0
- package/esm2020/lib/modules/action-button/action-button.component.mjs +34 -0
- package/esm2020/lib/modules/action-button/action-button.module.mjs +62 -0
- package/esm2020/lib/modules/action-button/types/action-button-container-align-items-type.mjs +2 -0
- package/esm2020/lib/modules/action-button/types/action-button-container-align-items.mjs +2 -0
- package/esm2020/lib/modules/back-to-top/back-to-top-adapter.service.mjs +84 -0
- package/esm2020/lib/modules/back-to-top/back-to-top.component.mjs +26 -0
- package/esm2020/lib/modules/back-to-top/back-to-top.directive.mjs +114 -0
- package/esm2020/lib/modules/back-to-top/back-to-top.module.mjs +35 -0
- package/esm2020/lib/modules/back-to-top/models/back-to-top-message-type.mjs +11 -0
- package/esm2020/lib/modules/back-to-top/models/back-to-top-message.mjs +2 -0
- package/esm2020/lib/modules/back-to-top/models/back-to-top-options.mjs +2 -0
- package/esm2020/lib/modules/box/box-content.component.mjs +15 -0
- package/esm2020/lib/modules/box/box-controls.component.mjs +14 -0
- package/esm2020/lib/modules/box/box-header.component.mjs +14 -0
- package/esm2020/lib/modules/box/box.component.mjs +21 -0
- package/esm2020/lib/modules/box/box.module.mjs +38 -0
- package/esm2020/lib/modules/card/card-actions.component.mjs +14 -0
- package/esm2020/lib/modules/card/card-content.component.mjs +14 -0
- package/esm2020/lib/modules/card/card-title.component.mjs +14 -0
- package/esm2020/lib/modules/card/card.component.mjs +75 -0
- package/esm2020/lib/modules/card/card.module.mjs +61 -0
- package/esm2020/lib/modules/definition-list/definition-list-content.component.mjs +14 -0
- package/esm2020/lib/modules/definition-list/definition-list-heading.component.mjs +14 -0
- package/esm2020/lib/modules/definition-list/definition-list-label.component.mjs +20 -0
- package/esm2020/lib/modules/definition-list/definition-list-value.component.mjs +21 -0
- package/esm2020/lib/modules/definition-list/definition-list.component.mjs +38 -0
- package/esm2020/lib/modules/definition-list/definition-list.module.mjs +44 -0
- package/esm2020/lib/modules/definition-list/definition-list.service.mjs +18 -0
- package/esm2020/lib/modules/description-list/description-list-adapter-service.mjs +43 -0
- package/esm2020/lib/modules/description-list/description-list-content.component.mjs +22 -0
- package/esm2020/lib/modules/description-list/description-list-description.component.mjs +49 -0
- package/esm2020/lib/modules/description-list/description-list-term.component.mjs +20 -0
- package/esm2020/lib/modules/description-list/description-list.component.mjs +101 -0
- package/esm2020/lib/modules/description-list/description-list.module.mjs +53 -0
- package/esm2020/lib/modules/description-list/description-list.service.mjs +26 -0
- package/esm2020/lib/modules/description-list/types/description-list-mode-type.mjs +2 -0
- package/esm2020/lib/modules/description-list/types/description-list-mode.mjs +24 -0
- package/esm2020/lib/modules/fluid-grid/column.component.mjs +53 -0
- package/esm2020/lib/modules/fluid-grid/fluid-grid-gutter-size.mjs +20 -0
- package/esm2020/lib/modules/fluid-grid/fluid-grid.component.mjs +62 -0
- package/esm2020/lib/modules/fluid-grid/fluid-grid.module.mjs +20 -0
- package/esm2020/lib/modules/fluid-grid/row.component.mjs +25 -0
- package/esm2020/lib/modules/fluid-grid/types/fluid-grid-gutter-size-type.mjs +2 -0
- package/esm2020/lib/modules/format/format-item.mjs +2 -0
- package/esm2020/lib/modules/format/format.component.mjs +59 -0
- package/esm2020/lib/modules/format/format.module.mjs +18 -0
- package/esm2020/lib/modules/inline-delete/inline-delete-adapter.service.mjs +115 -0
- package/esm2020/lib/modules/inline-delete/inline-delete-type.mjs +16 -0
- package/esm2020/lib/modules/inline-delete/inline-delete.component.mjs +161 -0
- package/esm2020/lib/modules/inline-delete/inline-delete.module.mjs +34 -0
- package/esm2020/lib/modules/page/page-theme-adapter.service.mjs +26 -0
- package/esm2020/lib/modules/page/page.component.mjs +27 -0
- package/esm2020/lib/modules/page/page.module.mjs +16 -0
- package/esm2020/lib/modules/page-summary/page-summary-adapter.service.mjs +23 -0
- package/esm2020/lib/modules/page-summary/page-summary-alert.component.mjs +17 -0
- package/esm2020/lib/modules/page-summary/page-summary-content.component.mjs +16 -0
- package/esm2020/lib/modules/page-summary/page-summary-image.component.mjs +17 -0
- package/esm2020/lib/modules/page-summary/page-summary-key-info.component.mjs +15 -0
- package/esm2020/lib/modules/page-summary/page-summary-status.component.mjs +17 -0
- package/esm2020/lib/modules/page-summary/page-summary-subtitle.component.mjs +16 -0
- package/esm2020/lib/modules/page-summary/page-summary-title.component.mjs +16 -0
- package/esm2020/lib/modules/page-summary/page-summary.component.mjs +45 -0
- package/esm2020/lib/modules/page-summary/page-summary.module.mjs +57 -0
- package/esm2020/lib/modules/shared/sky-layout-resources.module.mjs +60 -0
- package/esm2020/lib/modules/text-expand/text-expand-adapter.service.mjs +31 -0
- package/esm2020/lib/modules/text-expand/text-expand-modal-context.mjs +6 -0
- package/esm2020/lib/modules/text-expand/text-expand-modal.component.mjs +26 -0
- package/esm2020/lib/modules/text-expand/text-expand.component.mjs +247 -0
- package/esm2020/lib/modules/text-expand/text-expand.module.mjs +35 -0
- package/esm2020/lib/modules/text-expand-repeater/text-expand-repeater-adapter.service.mjs +37 -0
- package/esm2020/lib/modules/text-expand-repeater/text-expand-repeater.component.mjs +171 -0
- package/esm2020/lib/modules/text-expand-repeater/text-expand-repeater.module.mjs +20 -0
- package/esm2020/lib/modules/text-expand-repeater/types/text-expand-repeater-list-style-type.mjs +2 -0
- package/esm2020/lib/modules/toolbar/toolbar-item.component.mjs +14 -0
- package/esm2020/lib/modules/toolbar/toolbar-section.component.mjs +14 -0
- package/esm2020/lib/modules/toolbar/toolbar-view-actions.component.mjs +15 -0
- package/esm2020/lib/modules/toolbar/toolbar.component.mjs +25 -0
- package/esm2020/lib/modules/toolbar/toolbar.module.mjs +37 -0
- package/esm2020/skyux-layout.mjs +5 -0
- package/esm2020/testing/action-button-fixture.mjs +44 -0
- package/esm2020/testing/card-fixture.mjs +63 -0
- package/esm2020/testing/page-summary-fixture.mjs +29 -0
- package/esm2020/testing/public-api.mjs +4 -0
- package/esm2020/testing/skyux-layout-testing.mjs +5 -0
- package/fesm2015/{skyux-layout-testing.js → skyux-layout-testing.mjs} +1 -1
- package/fesm2015/skyux-layout-testing.mjs.map +1 -0
- package/fesm2015/skyux-layout.mjs +2724 -0
- package/fesm2015/skyux-layout.mjs.map +1 -0
- package/fesm2020/skyux-layout-testing.mjs +139 -0
- package/fesm2020/skyux-layout-testing.mjs.map +1 -0
- package/fesm2020/skyux-layout.mjs +2722 -0
- package/fesm2020/skyux-layout.mjs.map +1 -0
- package/package.json +45 -21
- package/testing/package.json +5 -5
- package/bundles/skyux-layout-testing.umd.js +0 -191
- package/bundles/skyux-layout.umd.js +0 -3570
- package/esm2015/index.js +0 -74
- package/esm2015/index.js.map +0 -1
- package/esm2015/lib/modules/action-button/action-button-adapter-service.js +0 -43
- package/esm2015/lib/modules/action-button/action-button-adapter-service.js.map +0 -1
- package/esm2015/lib/modules/action-button/action-button-container.component.js +0 -145
- package/esm2015/lib/modules/action-button/action-button-container.component.js.map +0 -1
- package/esm2015/lib/modules/action-button/action-button-details.component.js +0 -17
- package/esm2015/lib/modules/action-button/action-button-details.component.js.map +0 -1
- package/esm2015/lib/modules/action-button/action-button-header.component.js +0 -19
- package/esm2015/lib/modules/action-button/action-button-header.component.js.map +0 -1
- package/esm2015/lib/modules/action-button/action-button-icon.component.js +0 -44
- package/esm2015/lib/modules/action-button/action-button-icon.component.js.map +0 -1
- package/esm2015/lib/modules/action-button/action-button-permalink.js +0 -2
- package/esm2015/lib/modules/action-button/action-button-permalink.js.map +0 -1
- package/esm2015/lib/modules/action-button/action-button.component.js +0 -39
- package/esm2015/lib/modules/action-button/action-button.component.js.map +0 -1
- package/esm2015/lib/modules/action-button/action-button.module.js +0 -62
- package/esm2015/lib/modules/action-button/action-button.module.js.map +0 -1
- package/esm2015/lib/modules/action-button/types/action-button-container-align-items-type.js +0 -2
- package/esm2015/lib/modules/action-button/types/action-button-container-align-items-type.js.map +0 -1
- package/esm2015/lib/modules/action-button/types/action-button-container-align-items.js +0 -2
- package/esm2015/lib/modules/action-button/types/action-button-container-align-items.js.map +0 -1
- package/esm2015/lib/modules/back-to-top/back-to-top-adapter.service.js +0 -84
- package/esm2015/lib/modules/back-to-top/back-to-top-adapter.service.js.map +0 -1
- package/esm2015/lib/modules/back-to-top/back-to-top.component.js +0 -31
- package/esm2015/lib/modules/back-to-top/back-to-top.component.js.map +0 -1
- package/esm2015/lib/modules/back-to-top/back-to-top.directive.js +0 -114
- package/esm2015/lib/modules/back-to-top/back-to-top.directive.js.map +0 -1
- package/esm2015/lib/modules/back-to-top/back-to-top.module.js +0 -36
- package/esm2015/lib/modules/back-to-top/back-to-top.module.js.map +0 -1
- package/esm2015/lib/modules/back-to-top/models/back-to-top-message-type.js +0 -11
- package/esm2015/lib/modules/back-to-top/models/back-to-top-message-type.js.map +0 -1
- package/esm2015/lib/modules/back-to-top/models/back-to-top-message.js +0 -2
- package/esm2015/lib/modules/back-to-top/models/back-to-top-message.js.map +0 -1
- package/esm2015/lib/modules/back-to-top/models/back-to-top-options.js +0 -2
- package/esm2015/lib/modules/back-to-top/models/back-to-top-options.js.map +0 -1
- package/esm2015/lib/modules/box/box-content.component.js +0 -18
- package/esm2015/lib/modules/box/box-content.component.js.map +0 -1
- package/esm2015/lib/modules/box/box-controls.component.js +0 -17
- package/esm2015/lib/modules/box/box-controls.component.js.map +0 -1
- package/esm2015/lib/modules/box/box-header.component.js +0 -17
- package/esm2015/lib/modules/box/box-header.component.js.map +0 -1
- package/esm2015/lib/modules/box/box.component.js +0 -26
- package/esm2015/lib/modules/box/box.component.js.map +0 -1
- package/esm2015/lib/modules/box/box.module.js +0 -38
- package/esm2015/lib/modules/box/box.module.js.map +0 -1
- package/esm2015/lib/modules/card/card-actions.component.js +0 -18
- package/esm2015/lib/modules/card/card-actions.component.js.map +0 -1
- package/esm2015/lib/modules/card/card-content.component.js +0 -17
- package/esm2015/lib/modules/card/card-content.component.js.map +0 -1
- package/esm2015/lib/modules/card/card-title.component.js +0 -17
- package/esm2015/lib/modules/card/card-title.component.js.map +0 -1
- package/esm2015/lib/modules/card/card.component.js +0 -79
- package/esm2015/lib/modules/card/card.component.js.map +0 -1
- package/esm2015/lib/modules/card/card.module.js +0 -61
- package/esm2015/lib/modules/card/card.module.js.map +0 -1
- package/esm2015/lib/modules/definition-list/definition-list-content.component.js +0 -19
- package/esm2015/lib/modules/definition-list/definition-list-content.component.js.map +0 -1
- package/esm2015/lib/modules/definition-list/definition-list-heading.component.js +0 -19
- package/esm2015/lib/modules/definition-list/definition-list-heading.component.js.map +0 -1
- package/esm2015/lib/modules/definition-list/definition-list-label.component.js +0 -25
- package/esm2015/lib/modules/definition-list/definition-list-label.component.js.map +0 -1
- package/esm2015/lib/modules/definition-list/definition-list-value.component.js +0 -25
- package/esm2015/lib/modules/definition-list/definition-list-value.component.js.map +0 -1
- package/esm2015/lib/modules/definition-list/definition-list.component.js +0 -44
- package/esm2015/lib/modules/definition-list/definition-list.component.js.map +0 -1
- package/esm2015/lib/modules/definition-list/definition-list.module.js +0 -44
- package/esm2015/lib/modules/definition-list/definition-list.module.js.map +0 -1
- package/esm2015/lib/modules/definition-list/definition-list.service.js +0 -18
- package/esm2015/lib/modules/definition-list/definition-list.service.js.map +0 -1
- package/esm2015/lib/modules/description-list/description-list-adapter-service.js +0 -43
- package/esm2015/lib/modules/description-list/description-list-adapter-service.js.map +0 -1
- package/esm2015/lib/modules/description-list/description-list-content.component.js +0 -25
- package/esm2015/lib/modules/description-list/description-list-content.component.js.map +0 -1
- package/esm2015/lib/modules/description-list/description-list-description.component.js +0 -53
- package/esm2015/lib/modules/description-list/description-list-description.component.js.map +0 -1
- package/esm2015/lib/modules/description-list/description-list-term.component.js +0 -24
- package/esm2015/lib/modules/description-list/description-list-term.component.js.map +0 -1
- package/esm2015/lib/modules/description-list/description-list.component.js +0 -107
- package/esm2015/lib/modules/description-list/description-list.component.js.map +0 -1
- package/esm2015/lib/modules/description-list/description-list.module.js +0 -53
- package/esm2015/lib/modules/description-list/description-list.module.js.map +0 -1
- package/esm2015/lib/modules/description-list/description-list.service.js +0 -26
- package/esm2015/lib/modules/description-list/description-list.service.js.map +0 -1
- package/esm2015/lib/modules/description-list/types/description-list-mode-type.js +0 -2
- package/esm2015/lib/modules/description-list/types/description-list-mode-type.js.map +0 -1
- package/esm2015/lib/modules/description-list/types/description-list-mode.js +0 -24
- package/esm2015/lib/modules/description-list/types/description-list-mode.js.map +0 -1
- package/esm2015/lib/modules/fluid-grid/column.component.js +0 -58
- package/esm2015/lib/modules/fluid-grid/column.component.js.map +0 -1
- package/esm2015/lib/modules/fluid-grid/fluid-grid-gutter-size.js +0 -20
- package/esm2015/lib/modules/fluid-grid/fluid-grid-gutter-size.js.map +0 -1
- package/esm2015/lib/modules/fluid-grid/fluid-grid.component.js +0 -66
- package/esm2015/lib/modules/fluid-grid/fluid-grid.component.js.map +0 -1
- package/esm2015/lib/modules/fluid-grid/fluid-grid.module.js +0 -20
- package/esm2015/lib/modules/fluid-grid/fluid-grid.module.js.map +0 -1
- package/esm2015/lib/modules/fluid-grid/row.component.js +0 -29
- package/esm2015/lib/modules/fluid-grid/row.component.js.map +0 -1
- package/esm2015/lib/modules/fluid-grid/types/fluid-grid-gutter-size-type.js +0 -2
- package/esm2015/lib/modules/fluid-grid/types/fluid-grid-gutter-size-type.js.map +0 -1
- package/esm2015/lib/modules/format/format-item.js +0 -2
- package/esm2015/lib/modules/format/format-item.js.map +0 -1
- package/esm2015/lib/modules/format/format.component.js +0 -63
- package/esm2015/lib/modules/format/format.component.js.map +0 -1
- package/esm2015/lib/modules/format/format.module.js +0 -18
- package/esm2015/lib/modules/format/format.module.js.map +0 -1
- package/esm2015/lib/modules/inline-delete/inline-delete-adapter.service.js +0 -115
- package/esm2015/lib/modules/inline-delete/inline-delete-adapter.service.js.map +0 -1
- package/esm2015/lib/modules/inline-delete/inline-delete-type.js +0 -16
- package/esm2015/lib/modules/inline-delete/inline-delete-type.js.map +0 -1
- package/esm2015/lib/modules/inline-delete/inline-delete.component.js +0 -167
- package/esm2015/lib/modules/inline-delete/inline-delete.component.js.map +0 -1
- package/esm2015/lib/modules/inline-delete/inline-delete.module.js +0 -34
- package/esm2015/lib/modules/inline-delete/inline-delete.module.js.map +0 -1
- package/esm2015/lib/modules/page/page-theme-adapter.service.js +0 -26
- package/esm2015/lib/modules/page/page-theme-adapter.service.js.map +0 -1
- package/esm2015/lib/modules/page/page.component.js +0 -31
- package/esm2015/lib/modules/page/page.component.js.map +0 -1
- package/esm2015/lib/modules/page/page.module.js +0 -16
- package/esm2015/lib/modules/page/page.module.js.map +0 -1
- package/esm2015/lib/modules/page-summary/page-summary-adapter.service.js +0 -23
- package/esm2015/lib/modules/page-summary/page-summary-adapter.service.js.map +0 -1
- package/esm2015/lib/modules/page-summary/page-summary-alert.component.js +0 -21
- package/esm2015/lib/modules/page-summary/page-summary-alert.component.js.map +0 -1
- package/esm2015/lib/modules/page-summary/page-summary-content.component.js +0 -20
- package/esm2015/lib/modules/page-summary/page-summary-content.component.js.map +0 -1
- package/esm2015/lib/modules/page-summary/page-summary-image.component.js +0 -21
- package/esm2015/lib/modules/page-summary/page-summary-image.component.js.map +0 -1
- package/esm2015/lib/modules/page-summary/page-summary-key-info.component.js +0 -19
- package/esm2015/lib/modules/page-summary/page-summary-key-info.component.js.map +0 -1
- package/esm2015/lib/modules/page-summary/page-summary-status.component.js +0 -21
- package/esm2015/lib/modules/page-summary/page-summary-status.component.js.map +0 -1
- package/esm2015/lib/modules/page-summary/page-summary-subtitle.component.js +0 -20
- package/esm2015/lib/modules/page-summary/page-summary-subtitle.component.js.map +0 -1
- package/esm2015/lib/modules/page-summary/page-summary-title.component.js +0 -20
- package/esm2015/lib/modules/page-summary/page-summary-title.component.js.map +0 -1
- package/esm2015/lib/modules/page-summary/page-summary.component.js +0 -50
- package/esm2015/lib/modules/page-summary/page-summary.component.js.map +0 -1
- package/esm2015/lib/modules/page-summary/page-summary.module.js +0 -57
- package/esm2015/lib/modules/page-summary/page-summary.module.js.map +0 -1
- package/esm2015/lib/modules/shared/sky-layout-resources.module.js +0 -60
- package/esm2015/lib/modules/shared/sky-layout-resources.module.js.map +0 -1
- package/esm2015/lib/modules/text-expand/text-expand-adapter.service.js +0 -31
- package/esm2015/lib/modules/text-expand/text-expand-adapter.service.js.map +0 -1
- package/esm2015/lib/modules/text-expand/text-expand-modal-context.js +0 -6
- package/esm2015/lib/modules/text-expand/text-expand-modal-context.js.map +0 -1
- package/esm2015/lib/modules/text-expand/text-expand-modal.component.js +0 -30
- package/esm2015/lib/modules/text-expand/text-expand-modal.component.js.map +0 -1
- package/esm2015/lib/modules/text-expand/text-expand.component.js +0 -252
- package/esm2015/lib/modules/text-expand/text-expand.component.js.map +0 -1
- package/esm2015/lib/modules/text-expand/text-expand.module.js +0 -36
- package/esm2015/lib/modules/text-expand/text-expand.module.js.map +0 -1
- package/esm2015/lib/modules/text-expand-repeater/text-expand-repeater-adapter.service.js +0 -37
- package/esm2015/lib/modules/text-expand-repeater/text-expand-repeater-adapter.service.js.map +0 -1
- package/esm2015/lib/modules/text-expand-repeater/text-expand-repeater.component.js +0 -176
- package/esm2015/lib/modules/text-expand-repeater/text-expand-repeater.component.js.map +0 -1
- package/esm2015/lib/modules/text-expand-repeater/text-expand-repeater.module.js +0 -20
- package/esm2015/lib/modules/text-expand-repeater/text-expand-repeater.module.js.map +0 -1
- package/esm2015/lib/modules/text-expand-repeater/types/text-expand-repeater-list-style-type.js +0 -2
- package/esm2015/lib/modules/text-expand-repeater/types/text-expand-repeater-list-style-type.js.map +0 -1
- package/esm2015/lib/modules/toolbar/toolbar-item.component.js +0 -18
- package/esm2015/lib/modules/toolbar/toolbar-item.component.js.map +0 -1
- package/esm2015/lib/modules/toolbar/toolbar-section.component.js +0 -18
- package/esm2015/lib/modules/toolbar/toolbar-section.component.js.map +0 -1
- package/esm2015/lib/modules/toolbar/toolbar-view-actions.component.js +0 -20
- package/esm2015/lib/modules/toolbar/toolbar-view-actions.component.js.map +0 -1
- package/esm2015/lib/modules/toolbar/toolbar.component.js +0 -29
- package/esm2015/lib/modules/toolbar/toolbar.component.js.map +0 -1
- package/esm2015/lib/modules/toolbar/toolbar.module.js +0 -37
- package/esm2015/lib/modules/toolbar/toolbar.module.js.map +0 -1
- package/esm2015/skyux-layout.js +0 -5
- package/esm2015/skyux-layout.js.map +0 -1
- package/esm2015/testing/action-button-fixture.js +0 -44
- package/esm2015/testing/action-button-fixture.js.map +0 -1
- package/esm2015/testing/card-fixture.js +0 -63
- package/esm2015/testing/card-fixture.js.map +0 -1
- package/esm2015/testing/page-summary-fixture.js +0 -29
- package/esm2015/testing/page-summary-fixture.js.map +0 -1
- package/esm2015/testing/public-api.js +0 -4
- package/esm2015/testing/public-api.js.map +0 -1
- package/esm2015/testing/skyux-layout-testing.js +0 -5
- package/esm2015/testing/skyux-layout-testing.js.map +0 -1
- package/fesm2015/skyux-layout-testing.js.map +0 -1
- package/fesm2015/skyux-layout.js +0 -2912
- package/fesm2015/skyux-layout.js.map +0 -1
|
@@ -0,0 +1,2722 @@
|
|
|
1
|
+
import * as i3 from '@angular/common';
|
|
2
|
+
import { CommonModule } from '@angular/common';
|
|
3
|
+
import * as i0 from '@angular/core';
|
|
4
|
+
import { Injectable, EventEmitter, Component, ViewEncapsulation, Input, Output, ElementRef, Optional, ContentChildren, ViewChild, HostListener, NgModule, ChangeDetectionStrategy, Directive, TemplateRef, HostBinding } from '@angular/core';
|
|
5
|
+
import * as i2 from '@angular/router';
|
|
6
|
+
import { RouterModule } from '@angular/router';
|
|
7
|
+
import * as i2$1 from '@skyux/indicators';
|
|
8
|
+
import { SkyIconModule, SkyWaitModule } from '@skyux/indicators';
|
|
9
|
+
import * as i4 from '@skyux/router';
|
|
10
|
+
import { SkyHrefModule } from '@skyux/router';
|
|
11
|
+
import * as i3$1 from '@skyux/theme';
|
|
12
|
+
import { SkyThemeModule } from '@skyux/theme';
|
|
13
|
+
import * as i1 from '@skyux/core';
|
|
14
|
+
import { SkyMediaBreakpoints, SkyDockModule, SkyCoreAdapterService } from '@skyux/core';
|
|
15
|
+
import { Subject, BehaviorSubject, forkJoin } from 'rxjs';
|
|
16
|
+
import { takeUntil, take } from 'rxjs/operators';
|
|
17
|
+
import * as i1$1 from '@skyux/i18n';
|
|
18
|
+
import { getLibStringForLocale, SkyI18nModule, SKY_LIB_RESOURCES_PROVIDERS } from '@skyux/i18n';
|
|
19
|
+
import * as i3$2 from '@angular/forms';
|
|
20
|
+
import { FormsModule } from '@angular/forms';
|
|
21
|
+
import * as i1$2 from '@skyux/forms';
|
|
22
|
+
import { SkyCheckboxModule } from '@skyux/forms';
|
|
23
|
+
import { trigger, transition, style, query, group, animate } from '@angular/animations';
|
|
24
|
+
import * as i2$2 from '@skyux/modals';
|
|
25
|
+
import { SkyModalModule } from '@skyux/modals';
|
|
26
|
+
|
|
27
|
+
const RESPONSIVE_CLASS_SM = 'sky-action-button-container-sm';
|
|
28
|
+
const RESPONSIVE_CLASS_MD = 'sky-action-button-container-md';
|
|
29
|
+
const RESPONSIVE_CLASS_LG = 'sky-action-button-container-lg';
|
|
30
|
+
const BREAKPOINT_MD = 912;
|
|
31
|
+
const BREAKPOINT_LG = 1378;
|
|
32
|
+
/**
|
|
33
|
+
* @internal
|
|
34
|
+
*/
|
|
35
|
+
class SkyActionButtonAdapterService {
|
|
36
|
+
constructor(rendererFactory) {
|
|
37
|
+
this.renderer = rendererFactory.createRenderer(undefined, undefined);
|
|
38
|
+
}
|
|
39
|
+
getParentWidth(element) {
|
|
40
|
+
return element.nativeElement.parentNode.getBoundingClientRect().width;
|
|
41
|
+
}
|
|
42
|
+
setResponsiveClass(element, width) {
|
|
43
|
+
const el = element.nativeElement;
|
|
44
|
+
const className = this.getResponsiveClassName(width);
|
|
45
|
+
this.renderer.removeClass(el, RESPONSIVE_CLASS_SM);
|
|
46
|
+
this.renderer.removeClass(el, RESPONSIVE_CLASS_MD);
|
|
47
|
+
this.renderer.removeClass(el, RESPONSIVE_CLASS_LG);
|
|
48
|
+
this.renderer.addClass(el, className);
|
|
49
|
+
}
|
|
50
|
+
getResponsiveClassName(width) {
|
|
51
|
+
if (width < BREAKPOINT_MD) {
|
|
52
|
+
return RESPONSIVE_CLASS_SM;
|
|
53
|
+
}
|
|
54
|
+
else if (width > BREAKPOINT_MD && width < BREAKPOINT_LG) {
|
|
55
|
+
return RESPONSIVE_CLASS_MD;
|
|
56
|
+
}
|
|
57
|
+
else {
|
|
58
|
+
return RESPONSIVE_CLASS_LG;
|
|
59
|
+
}
|
|
60
|
+
}
|
|
61
|
+
}
|
|
62
|
+
SkyActionButtonAdapterService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyActionButtonAdapterService, deps: [{ token: i0.RendererFactory2 }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
63
|
+
SkyActionButtonAdapterService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyActionButtonAdapterService });
|
|
64
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyActionButtonAdapterService, decorators: [{
|
|
65
|
+
type: Injectable
|
|
66
|
+
}], ctorParameters: function () { return [{ type: i0.RendererFactory2 }]; } });
|
|
67
|
+
|
|
68
|
+
/**
|
|
69
|
+
* Creates a button to present users with an option to move forward with tasks.
|
|
70
|
+
*/
|
|
71
|
+
class SkyActionButtonComponent {
|
|
72
|
+
constructor() {
|
|
73
|
+
/**
|
|
74
|
+
* Fires when users select the action button.
|
|
75
|
+
*/
|
|
76
|
+
this.actionClick = new EventEmitter();
|
|
77
|
+
}
|
|
78
|
+
buttonClicked() {
|
|
79
|
+
this.actionClick.emit();
|
|
80
|
+
}
|
|
81
|
+
enterPress() {
|
|
82
|
+
this.actionClick.emit();
|
|
83
|
+
}
|
|
84
|
+
}
|
|
85
|
+
SkyActionButtonComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyActionButtonComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
86
|
+
SkyActionButtonComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.2.7", type: SkyActionButtonComponent, selector: "sky-action-button", inputs: { permalink: "permalink" }, outputs: { actionClick: "actionClick" }, ngImport: i0, template: "<a\n *ngIf=\"permalink && permalink.route\"\n class=\"sky-action-button sky-btn-default sky-rounded-corners\"\n tabindex=\"0\"\n [fragment]=\"permalink.route?.extras?.fragment\"\n [skyThemeClass]=\"{\n 'sky-btn sky-box': 'modern'\n }\"\n [queryParams]=\"permalink.route?.extras?.queryParams\"\n [queryParamsHandling]=\"permalink.route?.extras?.queryParamsHandling\"\n [routerLink]=\"permalink.route?.commands\"\n>\n <ng-container *ngTemplateOutlet=\"actionButtonContent\"> </ng-container>\n</a>\n\n<a\n *ngIf=\"permalink && !permalink.route\"\n class=\"sky-action-button sky-btn-default sky-rounded-corners\"\n tabindex=\"0\"\n [skyHref]=\"permalink.url\"\n [skyThemeClass]=\"{\n 'sky-btn sky-box': 'modern'\n }\"\n>\n <ng-container *ngTemplateOutlet=\"actionButtonContent\"> </ng-container>\n</a>\n\n<div\n *ngIf=\"!permalink\"\n class=\"sky-action-button sky-btn-default sky-rounded-corners\"\n tabindex=\"0\"\n role=\"button\"\n [skyThemeClass]=\"{\n 'sky-btn sky-box': 'modern'\n }\"\n (click)=\"buttonClicked()\"\n (keydown.enter)=\"enterPress()\"\n>\n <ng-container *ngTemplateOutlet=\"actionButtonContent\"> </ng-container>\n</div>\n\n<ng-template #actionButtonContent>\n <ng-container *skyThemeIf=\"'default'\">\n <div class=\"sky-action-button-icon-header-container\">\n <ng-container *ngTemplateOutlet=\"icon\"></ng-container>\n <ng-container *ngTemplateOutlet=\"header\"></ng-container>\n </div>\n <ng-container *ngTemplateOutlet=\"details\"></ng-container>\n </ng-container>\n\n <ng-container *skyThemeIf=\"'modern'\">\n <ng-container *ngTemplateOutlet=\"icon\"></ng-container>\n <div class=\"sky-action-button-content\">\n <ng-container *ngTemplateOutlet=\"header\"></ng-container>\n <div\n class=\"sky-action-button-details\"\n [skyThemeClass]=\"{\n 'sky-font-deemphasized': 'modern'\n }\"\n >\n <ng-container *ngTemplateOutlet=\"details\"></ng-container>\n </div>\n </div>\n </ng-container>\n</ng-template>\n\n<ng-template #icon>\n <ng-content select=\"sky-action-button-icon\"></ng-content>\n</ng-template>\n\n<ng-template #header>\n <ng-content select=\"sky-action-button-header\"></ng-content>\n</ng-template>\n\n<ng-template #details>\n <ng-content select=\"sky-action-button-details\"></ng-content>\n</ng-template>\n", styles: [".sky-action-button{border-top:1px solid #cdcfd2;border-bottom:1px solid #cdcfd2;border-left:1px solid #cdcfd2;border-right:1px solid #cdcfd2;cursor:pointer;text-align:center;text-decoration:none!important;display:block}.sky-action-button:hover{border-color:#c2c4c6}.sky-action-button-icon-header-container{display:flex;justify-content:center}.sky-action-button{padding:20px 20px 30px;margin:0 15px}.sky-action-button-icon-header-container{margin-bottom:20px}.sky-responsive-container-xs .sky-action-button,.sky-responsive-container-sm .sky-action-button,.sky-responsive-container-md .sky-action-button,.sky-responsive-container-lg .sky-action-button{padding:20px 20px 30px;margin:0 15px}.sky-responsive-container-xs .sky-action-button-icon-header-container,.sky-responsive-container-sm .sky-action-button-icon-header-container,.sky-responsive-container-md .sky-action-button-icon-header-container,.sky-responsive-container-lg .sky-action-button-icon-header-container{margin-bottom:20px}@media (min-width: 768px){.sky-action-button{padding:30px 20px;margin:0;max-width:236px}.sky-action-button-icon-header-container{margin-bottom:0;flex-direction:column}}.sky-responsive-container-sm .sky-action-button,.sky-responsive-container-md .sky-action-button,.sky-responsive-container-lg .sky-action-button{padding:30px 20px;margin:0;max-width:236px}.sky-responsive-container-sm .sky-action-button-icon-header-container,.sky-responsive-container-md .sky-action-button-icon-header-container,.sky-responsive-container-lg .sky-action-button-icon-header-container{margin-bottom:0;flex-direction:column}.sky-theme-modern .sky-action-button{display:flex;flex-flow:row nowrap;padding:30px;text-align:left;border:none}.sky-theme-modern .sky-action-button .sky-action-button-content{flex:1 1 auto;margin:0 10px 0 0;white-space:initial}.sky-theme-modern .sky-action-button,.sky-theme-modern .sky-responsive-container-xs .sky-action-button,.sky-theme-modern .sky-responsive-container-sm .sky-action-button,.sky-theme-modern .sky-responsive-container-md .sky-action-button,.sky-theme-modern .sky-responsive-container-lg .sky-action-button{padding:30px;margin:0;max-width:446px}@media (min-width: 768px){.sky-theme-modern .sky-action-button{padding:30px;margin:0}}.sky-theme-modern .sky-responsive-container-sm .sky-action-button,.sky-theme-modern .sky-responsive-container-md .sky-action-button,.sky-theme-modern .sky-responsive-container-lg .sky-action-button{padding:30px;margin:0}\n"], directives: [{ type: i3.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i2.RouterLinkWithHref, selector: "a[routerLink],area[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "preserveFragment", "skipLocationChange", "replaceUrl", "state", "relativeTo", "routerLink"] }, { type: i3$1.λ2, selector: "[skyThemeClass]", inputs: ["class", "skyThemeClass"] }, { type: i3.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet"] }, { type: i4.λ1, selector: "[skyHref]", inputs: ["skyHref", "skyHrefElse"] }, { type: i3$1.λ3, selector: "[skyThemeIf]", inputs: ["skyThemeIf"] }], encapsulation: i0.ViewEncapsulation.None });
|
|
87
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyActionButtonComponent, decorators: [{
|
|
88
|
+
type: Component,
|
|
89
|
+
args: [{ selector: 'sky-action-button', encapsulation: ViewEncapsulation.None, template: "<a\n *ngIf=\"permalink && permalink.route\"\n class=\"sky-action-button sky-btn-default sky-rounded-corners\"\n tabindex=\"0\"\n [fragment]=\"permalink.route?.extras?.fragment\"\n [skyThemeClass]=\"{\n 'sky-btn sky-box': 'modern'\n }\"\n [queryParams]=\"permalink.route?.extras?.queryParams\"\n [queryParamsHandling]=\"permalink.route?.extras?.queryParamsHandling\"\n [routerLink]=\"permalink.route?.commands\"\n>\n <ng-container *ngTemplateOutlet=\"actionButtonContent\"> </ng-container>\n</a>\n\n<a\n *ngIf=\"permalink && !permalink.route\"\n class=\"sky-action-button sky-btn-default sky-rounded-corners\"\n tabindex=\"0\"\n [skyHref]=\"permalink.url\"\n [skyThemeClass]=\"{\n 'sky-btn sky-box': 'modern'\n }\"\n>\n <ng-container *ngTemplateOutlet=\"actionButtonContent\"> </ng-container>\n</a>\n\n<div\n *ngIf=\"!permalink\"\n class=\"sky-action-button sky-btn-default sky-rounded-corners\"\n tabindex=\"0\"\n role=\"button\"\n [skyThemeClass]=\"{\n 'sky-btn sky-box': 'modern'\n }\"\n (click)=\"buttonClicked()\"\n (keydown.enter)=\"enterPress()\"\n>\n <ng-container *ngTemplateOutlet=\"actionButtonContent\"> </ng-container>\n</div>\n\n<ng-template #actionButtonContent>\n <ng-container *skyThemeIf=\"'default'\">\n <div class=\"sky-action-button-icon-header-container\">\n <ng-container *ngTemplateOutlet=\"icon\"></ng-container>\n <ng-container *ngTemplateOutlet=\"header\"></ng-container>\n </div>\n <ng-container *ngTemplateOutlet=\"details\"></ng-container>\n </ng-container>\n\n <ng-container *skyThemeIf=\"'modern'\">\n <ng-container *ngTemplateOutlet=\"icon\"></ng-container>\n <div class=\"sky-action-button-content\">\n <ng-container *ngTemplateOutlet=\"header\"></ng-container>\n <div\n class=\"sky-action-button-details\"\n [skyThemeClass]=\"{\n 'sky-font-deemphasized': 'modern'\n }\"\n >\n <ng-container *ngTemplateOutlet=\"details\"></ng-container>\n </div>\n </div>\n </ng-container>\n</ng-template>\n\n<ng-template #icon>\n <ng-content select=\"sky-action-button-icon\"></ng-content>\n</ng-template>\n\n<ng-template #header>\n <ng-content select=\"sky-action-button-header\"></ng-content>\n</ng-template>\n\n<ng-template #details>\n <ng-content select=\"sky-action-button-details\"></ng-content>\n</ng-template>\n", styles: [".sky-action-button{border-top:1px solid #cdcfd2;border-bottom:1px solid #cdcfd2;border-left:1px solid #cdcfd2;border-right:1px solid #cdcfd2;cursor:pointer;text-align:center;text-decoration:none!important;display:block}.sky-action-button:hover{border-color:#c2c4c6}.sky-action-button-icon-header-container{display:flex;justify-content:center}.sky-action-button{padding:20px 20px 30px;margin:0 15px}.sky-action-button-icon-header-container{margin-bottom:20px}.sky-responsive-container-xs .sky-action-button,.sky-responsive-container-sm .sky-action-button,.sky-responsive-container-md .sky-action-button,.sky-responsive-container-lg .sky-action-button{padding:20px 20px 30px;margin:0 15px}.sky-responsive-container-xs .sky-action-button-icon-header-container,.sky-responsive-container-sm .sky-action-button-icon-header-container,.sky-responsive-container-md .sky-action-button-icon-header-container,.sky-responsive-container-lg .sky-action-button-icon-header-container{margin-bottom:20px}@media (min-width: 768px){.sky-action-button{padding:30px 20px;margin:0;max-width:236px}.sky-action-button-icon-header-container{margin-bottom:0;flex-direction:column}}.sky-responsive-container-sm .sky-action-button,.sky-responsive-container-md .sky-action-button,.sky-responsive-container-lg .sky-action-button{padding:30px 20px;margin:0;max-width:236px}.sky-responsive-container-sm .sky-action-button-icon-header-container,.sky-responsive-container-md .sky-action-button-icon-header-container,.sky-responsive-container-lg .sky-action-button-icon-header-container{margin-bottom:0;flex-direction:column}.sky-theme-modern .sky-action-button{display:flex;flex-flow:row nowrap;padding:30px;text-align:left;border:none}.sky-theme-modern .sky-action-button .sky-action-button-content{flex:1 1 auto;margin:0 10px 0 0;white-space:initial}.sky-theme-modern .sky-action-button,.sky-theme-modern .sky-responsive-container-xs .sky-action-button,.sky-theme-modern .sky-responsive-container-sm .sky-action-button,.sky-theme-modern .sky-responsive-container-md .sky-action-button,.sky-theme-modern .sky-responsive-container-lg .sky-action-button{padding:30px;margin:0;max-width:446px}@media (min-width: 768px){.sky-theme-modern .sky-action-button{padding:30px;margin:0}}.sky-theme-modern .sky-responsive-container-sm .sky-action-button,.sky-theme-modern .sky-responsive-container-md .sky-action-button,.sky-theme-modern .sky-responsive-container-lg .sky-action-button{padding:30px;margin:0}\n"] }]
|
|
90
|
+
}], propDecorators: { permalink: [{
|
|
91
|
+
type: Input
|
|
92
|
+
}], actionClick: [{
|
|
93
|
+
type: Output
|
|
94
|
+
}] } });
|
|
95
|
+
|
|
96
|
+
/**
|
|
97
|
+
* Wraps action buttons to ensures that they have consistent height and spacing.
|
|
98
|
+
* @required
|
|
99
|
+
*/
|
|
100
|
+
class SkyActionButtonContainerComponent {
|
|
101
|
+
constructor(actionButtonAdapterService, changeRef, coreAdapterService, hostElRef, mutationObserverSvc, ngZone, themeSvc) {
|
|
102
|
+
this.actionButtonAdapterService = actionButtonAdapterService;
|
|
103
|
+
this.changeRef = changeRef;
|
|
104
|
+
this.coreAdapterService = coreAdapterService;
|
|
105
|
+
this.hostElRef = hostElRef;
|
|
106
|
+
this.mutationObserverSvc = mutationObserverSvc;
|
|
107
|
+
this.ngZone = ngZone;
|
|
108
|
+
this.themeSvc = themeSvc;
|
|
109
|
+
this.ngUnsubscribe = new Subject();
|
|
110
|
+
}
|
|
111
|
+
/**
|
|
112
|
+
* Specifies how to display the action buttons inside the action button container.
|
|
113
|
+
* Options are `"center"` or `"left"`.
|
|
114
|
+
* @default "center"
|
|
115
|
+
*/
|
|
116
|
+
set alignItems(value) {
|
|
117
|
+
this._alignItems = value;
|
|
118
|
+
}
|
|
119
|
+
get alignItems() {
|
|
120
|
+
return this._alignItems || 'center';
|
|
121
|
+
}
|
|
122
|
+
set themeName(value) {
|
|
123
|
+
this._themeName = value;
|
|
124
|
+
this.updateResponsiveClass();
|
|
125
|
+
this.updateHeight();
|
|
126
|
+
}
|
|
127
|
+
ngOnInit() {
|
|
128
|
+
/* istanbul ignore else */
|
|
129
|
+
if (this.themeSvc) {
|
|
130
|
+
this.themeSvc.settingsChange
|
|
131
|
+
.pipe(takeUntil(this.ngUnsubscribe))
|
|
132
|
+
.subscribe((themeSettings) => {
|
|
133
|
+
this.themeName = themeSettings.currentSettings.theme.name;
|
|
134
|
+
this.changeRef.markForCheck();
|
|
135
|
+
});
|
|
136
|
+
}
|
|
137
|
+
// Wait for children components to complete rendering before container width is determined.
|
|
138
|
+
setTimeout(() => {
|
|
139
|
+
this.updateResponsiveClass();
|
|
140
|
+
});
|
|
141
|
+
}
|
|
142
|
+
ngAfterContentInit() {
|
|
143
|
+
// Watch for dynamic action button changes and recalculate height.
|
|
144
|
+
/* istanbul ignore else */
|
|
145
|
+
if (this.actionButtons) {
|
|
146
|
+
this.actionButtons.changes
|
|
147
|
+
.pipe(takeUntil(this.ngUnsubscribe))
|
|
148
|
+
.subscribe(() => {
|
|
149
|
+
this.updateHeight();
|
|
150
|
+
});
|
|
151
|
+
}
|
|
152
|
+
this.initMutationObserver();
|
|
153
|
+
}
|
|
154
|
+
ngOnDestroy() {
|
|
155
|
+
this.ngUnsubscribe.next();
|
|
156
|
+
this.ngUnsubscribe.complete();
|
|
157
|
+
this.destroyMutationObserver();
|
|
158
|
+
}
|
|
159
|
+
onWindowResize() {
|
|
160
|
+
this.updateResponsiveClass();
|
|
161
|
+
}
|
|
162
|
+
initMutationObserver() {
|
|
163
|
+
/* istanbul ignore else */
|
|
164
|
+
if (!this.mutationObserver) {
|
|
165
|
+
const el = this.containerRef.nativeElement;
|
|
166
|
+
// MutationObserver is patched by Zone.js and therefore becomes part of the
|
|
167
|
+
// Angular change detection cycle, but this can lead to infinite loops in some
|
|
168
|
+
// scenarios. This will keep MutationObserver from triggering change detection.
|
|
169
|
+
this.ngZone.runOutsideAngular(() => {
|
|
170
|
+
this.mutationObserver = this.mutationObserverSvc.create(() => {
|
|
171
|
+
this.updateHeight();
|
|
172
|
+
});
|
|
173
|
+
this.mutationObserver.observe(el, {
|
|
174
|
+
characterData: true,
|
|
175
|
+
subtree: true,
|
|
176
|
+
});
|
|
177
|
+
});
|
|
178
|
+
}
|
|
179
|
+
}
|
|
180
|
+
destroyMutationObserver() {
|
|
181
|
+
if (this.mutationObserver) {
|
|
182
|
+
this.mutationObserver.disconnect();
|
|
183
|
+
this.mutationObserver = undefined;
|
|
184
|
+
}
|
|
185
|
+
}
|
|
186
|
+
updateHeight() {
|
|
187
|
+
this.coreAdapterService.resetHeight(this.containerRef, '.sky-action-button');
|
|
188
|
+
if (this._themeName === 'modern') {
|
|
189
|
+
// Wait for children components to complete rendering before height is determined.
|
|
190
|
+
setTimeout(() => {
|
|
191
|
+
this.coreAdapterService.syncMaxHeight(this.containerRef, '.sky-action-button');
|
|
192
|
+
});
|
|
193
|
+
}
|
|
194
|
+
}
|
|
195
|
+
updateResponsiveClass() {
|
|
196
|
+
const parentWidth = this.actionButtonAdapterService.getParentWidth(this.hostElRef);
|
|
197
|
+
this.actionButtonAdapterService.setResponsiveClass(this.containerRef, parentWidth);
|
|
198
|
+
}
|
|
199
|
+
}
|
|
200
|
+
SkyActionButtonContainerComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyActionButtonContainerComponent, deps: [{ token: SkyActionButtonAdapterService }, { token: i0.ChangeDetectorRef }, { token: i1.SkyCoreAdapterService }, { token: i0.ElementRef }, { token: i1.MutationObserverService }, { token: i0.NgZone }, { token: i3$1.SkyThemeService, optional: true }], target: i0.ɵɵFactoryTarget.Component });
|
|
201
|
+
SkyActionButtonContainerComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.2.7", type: SkyActionButtonContainerComponent, selector: "sky-action-button-container", inputs: { alignItems: "alignItems" }, host: { listeners: { "window:resize": "onWindowResize()" } }, providers: [SkyActionButtonAdapterService], queries: [{ propertyName: "actionButtons", predicate: SkyActionButtonComponent }], viewQueries: [{ propertyName: "containerRef", first: true, predicate: ["container"], descendants: true, read: ElementRef, static: true }], ngImport: i0, template: "<div class=\"sky-action-button-container\" #container>\n <div\n class=\"sky-action-button-flex\"\n [ngClass]=\"{\n 'sky-action-button-flex-align-left': alignItems === 'left',\n 'sky-action-button-flex-align-center': alignItems === 'center'\n }\"\n >\n <ng-content></ng-content>\n </div>\n</div>\n", styles: [":host{display:block}.sky-action-button-flex sky-action-button{display:block}.sky-action-button-flex .sky-action-button{height:100%;min-width:236px;margin-left:10px;margin-right:10px}.sky-action-button-flex{display:block;padding:0}.sky-action-button-flex sky-action-button{margin:20px 0}.sky-responsive-container-xs .sky-action-button-flex,.sky-responsive-container-sm .sky-action-button-flex,.sky-responsive-container-md .sky-action-button-flex,.sky-responsive-container-lg .sky-action-button-flex{display:block;padding:0}.sky-responsive-container-xs .sky-action-button-flex sky-action-button,.sky-responsive-container-sm .sky-action-button-flex sky-action-button,.sky-responsive-container-md .sky-action-button-flex sky-action-button,.sky-responsive-container-lg .sky-action-button-flex sky-action-button{margin:20px 0}@media (min-width: 768px){.sky-action-button-flex{display:flex;flex-flow:row wrap;padding:10px 0}.sky-action-button-flex.sky-action-button-flex-align-center{justify-content:center}.sky-action-button-flex.sky-action-button-flex-align-left{justify-content:flex-start}.sky-action-button-flex sky-action-button{margin:10px 0}}.sky-responsive-container-sm .sky-action-button-flex,.sky-responsive-container-md .sky-action-button-flex,.sky-responsive-container-lg .sky-action-button-flex{display:flex;flex-flow:row wrap;padding:10px 0}.sky-responsive-container-sm .sky-action-button-flex.sky-action-button-flex-align-center,.sky-responsive-container-md .sky-action-button-flex.sky-action-button-flex-align-center,.sky-responsive-container-lg .sky-action-button-flex.sky-action-button-flex-align-center{justify-content:center}.sky-responsive-container-sm .sky-action-button-flex.sky-action-button-flex-align-left,.sky-responsive-container-md .sky-action-button-flex.sky-action-button-flex-align-left,.sky-responsive-container-lg .sky-action-button-flex.sky-action-button-flex-align-left{justify-content:flex-start}.sky-responsive-container-sm .sky-action-button-flex sky-action-button,.sky-responsive-container-md .sky-action-button-flex sky-action-button,.sky-responsive-container-lg .sky-action-button-flex sky-action-button{margin:10px 0}.sky-theme-modern .sky-action-button-container{margin:0 auto}.sky-theme-modern .sky-action-button-container.sky-action-button-container-sm{max-width:446px}.sky-theme-modern .sky-action-button-container.sky-action-button-container-md{max-width:912px}.sky-theme-modern .sky-action-button-container.sky-action-button-container-lg{max-width:1378px}.sky-theme-modern .sky-action-button-container .sky-action-button-flex .sky-action-button{height:auto;min-width:auto;margin:0}.sky-theme-modern .sky-action-button-flex{display:flex;flex-flow:row wrap;padding:0;margin:0 0 -20px -20px}.sky-theme-modern .sky-action-button-flex sky-action-button{margin:0 0 20px 20px;flex:0 1 446px}.sky-theme-modern .sky-responsive-container-xs .sky-action-button-flex,.sky-theme-modern .sky-responsive-container-sm .sky-action-button-flex,.sky-theme-modern .sky-responsive-container-md .sky-action-button-flex,.sky-theme-modern .sky-responsive-container-lg .sky-action-button-flex{display:flex;flex-flow:row wrap;padding:0;margin:0 0 -20px -20px}.sky-theme-modern .sky-responsive-container-xs .sky-action-button-flex sky-action-button,.sky-theme-modern .sky-responsive-container-sm .sky-action-button-flex sky-action-button,.sky-theme-modern .sky-responsive-container-md .sky-action-button-flex sky-action-button,.sky-theme-modern .sky-responsive-container-lg .sky-action-button-flex sky-action-button{margin:0 0 20px 20px;flex:0 1 446px}\n"], directives: [{ type: i3.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }], encapsulation: i0.ViewEncapsulation.None });
|
|
202
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyActionButtonContainerComponent, decorators: [{
|
|
203
|
+
type: Component,
|
|
204
|
+
args: [{ selector: 'sky-action-button-container', providers: [SkyActionButtonAdapterService], encapsulation: ViewEncapsulation.None, template: "<div class=\"sky-action-button-container\" #container>\n <div\n class=\"sky-action-button-flex\"\n [ngClass]=\"{\n 'sky-action-button-flex-align-left': alignItems === 'left',\n 'sky-action-button-flex-align-center': alignItems === 'center'\n }\"\n >\n <ng-content></ng-content>\n </div>\n</div>\n", styles: [":host{display:block}.sky-action-button-flex sky-action-button{display:block}.sky-action-button-flex .sky-action-button{height:100%;min-width:236px;margin-left:10px;margin-right:10px}.sky-action-button-flex{display:block;padding:0}.sky-action-button-flex sky-action-button{margin:20px 0}.sky-responsive-container-xs .sky-action-button-flex,.sky-responsive-container-sm .sky-action-button-flex,.sky-responsive-container-md .sky-action-button-flex,.sky-responsive-container-lg .sky-action-button-flex{display:block;padding:0}.sky-responsive-container-xs .sky-action-button-flex sky-action-button,.sky-responsive-container-sm .sky-action-button-flex sky-action-button,.sky-responsive-container-md .sky-action-button-flex sky-action-button,.sky-responsive-container-lg .sky-action-button-flex sky-action-button{margin:20px 0}@media (min-width: 768px){.sky-action-button-flex{display:flex;flex-flow:row wrap;padding:10px 0}.sky-action-button-flex.sky-action-button-flex-align-center{justify-content:center}.sky-action-button-flex.sky-action-button-flex-align-left{justify-content:flex-start}.sky-action-button-flex sky-action-button{margin:10px 0}}.sky-responsive-container-sm .sky-action-button-flex,.sky-responsive-container-md .sky-action-button-flex,.sky-responsive-container-lg .sky-action-button-flex{display:flex;flex-flow:row wrap;padding:10px 0}.sky-responsive-container-sm .sky-action-button-flex.sky-action-button-flex-align-center,.sky-responsive-container-md .sky-action-button-flex.sky-action-button-flex-align-center,.sky-responsive-container-lg .sky-action-button-flex.sky-action-button-flex-align-center{justify-content:center}.sky-responsive-container-sm .sky-action-button-flex.sky-action-button-flex-align-left,.sky-responsive-container-md .sky-action-button-flex.sky-action-button-flex-align-left,.sky-responsive-container-lg .sky-action-button-flex.sky-action-button-flex-align-left{justify-content:flex-start}.sky-responsive-container-sm .sky-action-button-flex sky-action-button,.sky-responsive-container-md .sky-action-button-flex sky-action-button,.sky-responsive-container-lg .sky-action-button-flex sky-action-button{margin:10px 0}.sky-theme-modern .sky-action-button-container{margin:0 auto}.sky-theme-modern .sky-action-button-container.sky-action-button-container-sm{max-width:446px}.sky-theme-modern .sky-action-button-container.sky-action-button-container-md{max-width:912px}.sky-theme-modern .sky-action-button-container.sky-action-button-container-lg{max-width:1378px}.sky-theme-modern .sky-action-button-container .sky-action-button-flex .sky-action-button{height:auto;min-width:auto;margin:0}.sky-theme-modern .sky-action-button-flex{display:flex;flex-flow:row wrap;padding:0;margin:0 0 -20px -20px}.sky-theme-modern .sky-action-button-flex sky-action-button{margin:0 0 20px 20px;flex:0 1 446px}.sky-theme-modern .sky-responsive-container-xs .sky-action-button-flex,.sky-theme-modern .sky-responsive-container-sm .sky-action-button-flex,.sky-theme-modern .sky-responsive-container-md .sky-action-button-flex,.sky-theme-modern .sky-responsive-container-lg .sky-action-button-flex{display:flex;flex-flow:row wrap;padding:0;margin:0 0 -20px -20px}.sky-theme-modern .sky-responsive-container-xs .sky-action-button-flex sky-action-button,.sky-theme-modern .sky-responsive-container-sm .sky-action-button-flex sky-action-button,.sky-theme-modern .sky-responsive-container-md .sky-action-button-flex sky-action-button,.sky-theme-modern .sky-responsive-container-lg .sky-action-button-flex sky-action-button{margin:0 0 20px 20px;flex:0 1 446px}\n"] }]
|
|
205
|
+
}], ctorParameters: function () { return [{ type: SkyActionButtonAdapterService }, { type: i0.ChangeDetectorRef }, { type: i1.SkyCoreAdapterService }, { type: i0.ElementRef }, { type: i1.MutationObserverService }, { type: i0.NgZone }, { type: i3$1.SkyThemeService, decorators: [{
|
|
206
|
+
type: Optional
|
|
207
|
+
}] }]; }, propDecorators: { alignItems: [{
|
|
208
|
+
type: Input
|
|
209
|
+
}], actionButtons: [{
|
|
210
|
+
type: ContentChildren,
|
|
211
|
+
args: [SkyActionButtonComponent]
|
|
212
|
+
}], containerRef: [{
|
|
213
|
+
type: ViewChild,
|
|
214
|
+
args: ['container', {
|
|
215
|
+
read: ElementRef,
|
|
216
|
+
static: true,
|
|
217
|
+
}]
|
|
218
|
+
}], onWindowResize: [{
|
|
219
|
+
type: HostListener,
|
|
220
|
+
args: ['window:resize']
|
|
221
|
+
}] } });
|
|
222
|
+
|
|
223
|
+
/**
|
|
224
|
+
* Specifies a description to display on an action button.
|
|
225
|
+
*/
|
|
226
|
+
class SkyActionButtonDetailsComponent {
|
|
227
|
+
}
|
|
228
|
+
SkyActionButtonDetailsComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyActionButtonDetailsComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
229
|
+
SkyActionButtonDetailsComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.2.7", type: SkyActionButtonDetailsComponent, selector: "sky-action-button-details", ngImport: i0, template: "<ng-content></ng-content>\n" });
|
|
230
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyActionButtonDetailsComponent, decorators: [{
|
|
231
|
+
type: Component,
|
|
232
|
+
args: [{ selector: 'sky-action-button-details', template: "<ng-content></ng-content>\n" }]
|
|
233
|
+
}] });
|
|
234
|
+
|
|
235
|
+
/**
|
|
236
|
+
* Specifies a header to display on an action button.
|
|
237
|
+
*/
|
|
238
|
+
class SkyActionButtonHeaderComponent {
|
|
239
|
+
}
|
|
240
|
+
SkyActionButtonHeaderComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyActionButtonHeaderComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
241
|
+
SkyActionButtonHeaderComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.2.7", type: SkyActionButtonHeaderComponent, selector: "sky-action-button-header", ngImport: i0, template: "<div\n class=\"sky-action-button-header\"\n [skyThemeClass]=\"{\n 'sky-headline': 'modern',\n 'sky-section-heading': 'default'\n }\"\n>\n <ng-content></ng-content>\n</div>\n", styles: [":host .sky-action-button-header{margin:0 5px}:host-context(.sky-responsive-container-xs) .sky-action-button-header,:host-context(.sky-responsive-container-sm) .sky-action-button-header,:host-context(.sky-responsive-container-md) .sky-action-button-header,:host-context(.sky-responsive-container-lg) .sky-action-button-header{margin:0 5px}@media (min-width: 768px){:host .sky-action-button-header{margin:0 0 20px}}:host-context(.sky-responsive-container-sm) .sky-action-button-header,:host-context(.sky-responsive-container-md) .sky-action-button-header,:host-context(.sky-responsive-container-lg) .sky-action-button-header{margin:0 0 20px}:host-context(.sky-theme-modern) .sky-action-button-header{margin:0 0 10px}.sky-theme-modern .sky-action-button-header{margin:0 0 10px}\n"], directives: [{ type: i3$1.λ2, selector: "[skyThemeClass]", inputs: ["class", "skyThemeClass"] }] });
|
|
242
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyActionButtonHeaderComponent, decorators: [{
|
|
243
|
+
type: Component,
|
|
244
|
+
args: [{ selector: 'sky-action-button-header', template: "<div\n class=\"sky-action-button-header\"\n [skyThemeClass]=\"{\n 'sky-headline': 'modern',\n 'sky-section-heading': 'default'\n }\"\n>\n <ng-content></ng-content>\n</div>\n", styles: [":host .sky-action-button-header{margin:0 5px}:host-context(.sky-responsive-container-xs) .sky-action-button-header,:host-context(.sky-responsive-container-sm) .sky-action-button-header,:host-context(.sky-responsive-container-md) .sky-action-button-header,:host-context(.sky-responsive-container-lg) .sky-action-button-header{margin:0 5px}@media (min-width: 768px){:host .sky-action-button-header{margin:0 0 20px}}:host-context(.sky-responsive-container-sm) .sky-action-button-header,:host-context(.sky-responsive-container-md) .sky-action-button-header,:host-context(.sky-responsive-container-lg) .sky-action-button-header{margin:0 0 20px}:host-context(.sky-theme-modern) .sky-action-button-header{margin:0 0 10px}.sky-theme-modern .sky-action-button-header{margin:0 0 10px}\n"] }]
|
|
245
|
+
}] });
|
|
246
|
+
|
|
247
|
+
const FONTSIZECLASS_SMALL = '2x';
|
|
248
|
+
const FONTSIZECLASS_LARGE = '3x';
|
|
249
|
+
/**
|
|
250
|
+
* Specifies an icon to display on the action button.
|
|
251
|
+
*/
|
|
252
|
+
class SkyActionButtonIconComponent {
|
|
253
|
+
constructor(mediaQueryService) {
|
|
254
|
+
this.mediaQueryService = mediaQueryService;
|
|
255
|
+
this.fontSizeClass = FONTSIZECLASS_LARGE;
|
|
256
|
+
this.subscription = this.mediaQueryService.subscribe((args) => {
|
|
257
|
+
if (args === SkyMediaBreakpoints.xs) {
|
|
258
|
+
this.fontSizeClass = FONTSIZECLASS_SMALL;
|
|
259
|
+
}
|
|
260
|
+
else {
|
|
261
|
+
this.fontSizeClass = FONTSIZECLASS_LARGE;
|
|
262
|
+
}
|
|
263
|
+
});
|
|
264
|
+
}
|
|
265
|
+
ngOnDestroy() {
|
|
266
|
+
/* istanbul ignore else */
|
|
267
|
+
/* sanity check */
|
|
268
|
+
if (this.subscription) {
|
|
269
|
+
this.subscription.unsubscribe();
|
|
270
|
+
}
|
|
271
|
+
}
|
|
272
|
+
}
|
|
273
|
+
SkyActionButtonIconComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyActionButtonIconComponent, deps: [{ token: i1.SkyMediaQueryService }], target: i0.ɵɵFactoryTarget.Component });
|
|
274
|
+
SkyActionButtonIconComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.2.7", type: SkyActionButtonIconComponent, selector: "sky-action-button-icon", inputs: { iconType: "iconType" }, ngImport: i0, template: "<div aria-hidden=\"true\" class=\"sky-action-button-icon-container\">\n <sky-icon\n class=\"sky-action-button-icon\"\n [icon]=\"iconType\"\n [size]=\"fontSizeClass\"\n ></sky-icon>\n</div>\n", styles: [":host .sky-action-button-icon-container{margin:0 5px}:host-context(.sky-responsive-container-xs) .sky-action-button-icon-container,:host-context(.sky-responsive-container-sm) .sky-action-button-icon-container,:host-context(.sky-responsive-container-md) .sky-action-button-icon-container,:host-context(.sky-responsive-container-lg) .sky-action-button-icon-container{margin:0 5px}@media (min-width: 768px){:host .sky-action-button-icon-container{margin:0 0 20px}}:host-context(.sky-responsive-container-sm) .sky-action-button-icon-container,:host-context(.sky-responsive-container-md) .sky-action-button-icon-container,:host-context(.sky-responsive-container-lg) .sky-action-button-icon-container{margin:0 0 20px}.sky-action-button-icon{color:#0974a1}:host-context(.sky-theme-modern) .sky-action-button-icon-container{color:#0974a1;background:#e8f8ff;margin:0 20px 0 0;border-radius:50%;width:42px;height:42px;display:flex;align-items:center;justify-content:center;flex:0 0 auto}:host-context(.sky-theme-modern) .sky-action-button-icon-container ::ng-deep .sky-icon{font-size:24px!important}.sky-theme-modern .sky-action-button-icon-container{color:#0974a1;background:#e8f8ff;margin:0 20px 0 0;border-radius:50%;width:42px;height:42px;display:flex;align-items:center;justify-content:center;flex:0 0 auto}.sky-theme-modern .sky-action-button-icon-container ::ng-deep .sky-icon{font-size:24px!important}\n"], components: [{ type: i2$1.λ4, selector: "sky-icon", inputs: ["icon", "iconType", "size", "fixedWidth", "variant"] }] });
|
|
275
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyActionButtonIconComponent, decorators: [{
|
|
276
|
+
type: Component,
|
|
277
|
+
args: [{ selector: 'sky-action-button-icon', template: "<div aria-hidden=\"true\" class=\"sky-action-button-icon-container\">\n <sky-icon\n class=\"sky-action-button-icon\"\n [icon]=\"iconType\"\n [size]=\"fontSizeClass\"\n ></sky-icon>\n</div>\n", styles: [":host .sky-action-button-icon-container{margin:0 5px}:host-context(.sky-responsive-container-xs) .sky-action-button-icon-container,:host-context(.sky-responsive-container-sm) .sky-action-button-icon-container,:host-context(.sky-responsive-container-md) .sky-action-button-icon-container,:host-context(.sky-responsive-container-lg) .sky-action-button-icon-container{margin:0 5px}@media (min-width: 768px){:host .sky-action-button-icon-container{margin:0 0 20px}}:host-context(.sky-responsive-container-sm) .sky-action-button-icon-container,:host-context(.sky-responsive-container-md) .sky-action-button-icon-container,:host-context(.sky-responsive-container-lg) .sky-action-button-icon-container{margin:0 0 20px}.sky-action-button-icon{color:#0974a1}:host-context(.sky-theme-modern) .sky-action-button-icon-container{color:#0974a1;background:#e8f8ff;margin:0 20px 0 0;border-radius:50%;width:42px;height:42px;display:flex;align-items:center;justify-content:center;flex:0 0 auto}:host-context(.sky-theme-modern) .sky-action-button-icon-container ::ng-deep .sky-icon{font-size:24px!important}.sky-theme-modern .sky-action-button-icon-container{color:#0974a1;background:#e8f8ff;margin:0 20px 0 0;border-radius:50%;width:42px;height:42px;display:flex;align-items:center;justify-content:center;flex:0 0 auto}.sky-theme-modern .sky-action-button-icon-container ::ng-deep .sky-icon{font-size:24px!important}\n"] }]
|
|
278
|
+
}], ctorParameters: function () { return [{ type: i1.SkyMediaQueryService }]; }, propDecorators: { iconType: [{
|
|
279
|
+
type: Input
|
|
280
|
+
}] } });
|
|
281
|
+
|
|
282
|
+
class SkyActionButtonModule {
|
|
283
|
+
}
|
|
284
|
+
SkyActionButtonModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyActionButtonModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
285
|
+
SkyActionButtonModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyActionButtonModule, declarations: [SkyActionButtonComponent,
|
|
286
|
+
SkyActionButtonContainerComponent,
|
|
287
|
+
SkyActionButtonDetailsComponent,
|
|
288
|
+
SkyActionButtonHeaderComponent,
|
|
289
|
+
SkyActionButtonIconComponent], imports: [CommonModule,
|
|
290
|
+
RouterModule,
|
|
291
|
+
SkyHrefModule,
|
|
292
|
+
SkyIconModule,
|
|
293
|
+
SkyThemeModule], exports: [SkyActionButtonComponent,
|
|
294
|
+
SkyActionButtonContainerComponent,
|
|
295
|
+
SkyActionButtonDetailsComponent,
|
|
296
|
+
SkyActionButtonHeaderComponent,
|
|
297
|
+
SkyActionButtonIconComponent] });
|
|
298
|
+
SkyActionButtonModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyActionButtonModule, imports: [[
|
|
299
|
+
CommonModule,
|
|
300
|
+
RouterModule,
|
|
301
|
+
SkyHrefModule,
|
|
302
|
+
SkyIconModule,
|
|
303
|
+
SkyThemeModule,
|
|
304
|
+
]] });
|
|
305
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyActionButtonModule, decorators: [{
|
|
306
|
+
type: NgModule,
|
|
307
|
+
args: [{
|
|
308
|
+
declarations: [
|
|
309
|
+
SkyActionButtonComponent,
|
|
310
|
+
SkyActionButtonContainerComponent,
|
|
311
|
+
SkyActionButtonDetailsComponent,
|
|
312
|
+
SkyActionButtonHeaderComponent,
|
|
313
|
+
SkyActionButtonIconComponent,
|
|
314
|
+
],
|
|
315
|
+
imports: [
|
|
316
|
+
CommonModule,
|
|
317
|
+
RouterModule,
|
|
318
|
+
SkyHrefModule,
|
|
319
|
+
SkyIconModule,
|
|
320
|
+
SkyThemeModule,
|
|
321
|
+
],
|
|
322
|
+
exports: [
|
|
323
|
+
SkyActionButtonComponent,
|
|
324
|
+
SkyActionButtonContainerComponent,
|
|
325
|
+
SkyActionButtonDetailsComponent,
|
|
326
|
+
SkyActionButtonHeaderComponent,
|
|
327
|
+
SkyActionButtonIconComponent,
|
|
328
|
+
],
|
|
329
|
+
}]
|
|
330
|
+
}] });
|
|
331
|
+
|
|
332
|
+
/**
|
|
333
|
+
* NOTICE: DO NOT MODIFY THIS FILE!
|
|
334
|
+
* The contents of this file were automatically generated by
|
|
335
|
+
* the 'ng generate @skyux/i18n:lib-resources-module lib/modules/shared/sky-layout' schematic.
|
|
336
|
+
* To update this file, simply rerun the command.
|
|
337
|
+
*/
|
|
338
|
+
const RESOURCES = {
|
|
339
|
+
'EN-US': {
|
|
340
|
+
skyux_back_to_top: { message: 'Back to top' },
|
|
341
|
+
skyux_card_checkbox_label: { message: 'Select card' },
|
|
342
|
+
skyux_definition_list_none_found: { message: 'None found.' },
|
|
343
|
+
skyux_description_list_none_found: { message: 'None found.' },
|
|
344
|
+
skyux_inline_delete_assistive_text: {
|
|
345
|
+
message: 'Are you sure you want to delete this item?',
|
|
346
|
+
},
|
|
347
|
+
skyux_inline_delete_cancel: { message: 'Cancel' },
|
|
348
|
+
skyux_inline_delete_confirm_deletion: { message: 'Confirm deletion' },
|
|
349
|
+
skyux_inline_delete_delete: { message: 'Delete' },
|
|
350
|
+
skyux_text_expand_close_text: { message: 'Close' },
|
|
351
|
+
skyux_text_expand_modal_title: { message: 'Expanded view' },
|
|
352
|
+
skyux_text_expand_see_less: { message: 'See less' },
|
|
353
|
+
skyux_text_expand_see_more: { message: 'See more' },
|
|
354
|
+
},
|
|
355
|
+
};
|
|
356
|
+
class SkyLayoutResourcesProvider {
|
|
357
|
+
getString(localeInfo, name) {
|
|
358
|
+
return getLibStringForLocale(RESOURCES, localeInfo.locale, name);
|
|
359
|
+
}
|
|
360
|
+
}
|
|
361
|
+
/**
|
|
362
|
+
* Import into any component library module that needs to use resource strings.
|
|
363
|
+
*/
|
|
364
|
+
class SkyLayoutResourcesModule {
|
|
365
|
+
}
|
|
366
|
+
SkyLayoutResourcesModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyLayoutResourcesModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
367
|
+
SkyLayoutResourcesModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyLayoutResourcesModule, exports: [SkyI18nModule] });
|
|
368
|
+
SkyLayoutResourcesModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyLayoutResourcesModule, providers: [
|
|
369
|
+
{
|
|
370
|
+
provide: SKY_LIB_RESOURCES_PROVIDERS,
|
|
371
|
+
useClass: SkyLayoutResourcesProvider,
|
|
372
|
+
multi: true,
|
|
373
|
+
},
|
|
374
|
+
], imports: [SkyI18nModule] });
|
|
375
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyLayoutResourcesModule, decorators: [{
|
|
376
|
+
type: NgModule,
|
|
377
|
+
args: [{
|
|
378
|
+
exports: [SkyI18nModule],
|
|
379
|
+
providers: [
|
|
380
|
+
{
|
|
381
|
+
provide: SKY_LIB_RESOURCES_PROVIDERS,
|
|
382
|
+
useClass: SkyLayoutResourcesProvider,
|
|
383
|
+
multi: true,
|
|
384
|
+
},
|
|
385
|
+
],
|
|
386
|
+
}]
|
|
387
|
+
}] });
|
|
388
|
+
|
|
389
|
+
/**
|
|
390
|
+
* @internal
|
|
391
|
+
*/
|
|
392
|
+
class SkyBackToTopComponent {
|
|
393
|
+
constructor() {
|
|
394
|
+
this._scrollToTopClick = new Subject();
|
|
395
|
+
}
|
|
396
|
+
get scrollToTopClick() {
|
|
397
|
+
return this._scrollToTopClick.asObservable();
|
|
398
|
+
}
|
|
399
|
+
onScrollToTopClick() {
|
|
400
|
+
this._scrollToTopClick.next();
|
|
401
|
+
this._scrollToTopClick.complete();
|
|
402
|
+
}
|
|
403
|
+
}
|
|
404
|
+
SkyBackToTopComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyBackToTopComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
405
|
+
SkyBackToTopComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.2.7", type: SkyBackToTopComponent, selector: "sky-back-to-top", ngImport: i0, template: "<div class=\"sky-back-to-top sky-padding-squish-large\">\n <button\n class=\"sky-btn sky-btn-link-inline\"\n type=\"button\"\n (click)=\"onScrollToTopClick()\"\n >\n {{ 'skyux_back_to_top' | skyLibResources }}\n </button>\n</div>\n", styles: [".sky-back-to-top{display:flex;align-items:center;width:100%;background-color:#fff;box-shadow:0 -3px 3px #cdcfd2}\n"], pipes: { "skyLibResources": i1$1.SkyLibResourcesPipe }, changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
406
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyBackToTopComponent, decorators: [{
|
|
407
|
+
type: Component,
|
|
408
|
+
args: [{ selector: 'sky-back-to-top', changeDetection: ChangeDetectionStrategy.OnPush, template: "<div class=\"sky-back-to-top sky-padding-squish-large\">\n <button\n class=\"sky-btn sky-btn-link-inline\"\n type=\"button\"\n (click)=\"onScrollToTopClick()\"\n >\n {{ 'skyux_back_to_top' | skyLibResources }}\n </button>\n</div>\n", styles: [".sky-back-to-top{display:flex;align-items:center;width:100%;background-color:#fff;box-shadow:0 -3px 3px #cdcfd2}\n"] }]
|
|
409
|
+
}] });
|
|
410
|
+
|
|
411
|
+
/**
|
|
412
|
+
* @internal
|
|
413
|
+
*/
|
|
414
|
+
class SkyBackToTopDomAdapterService {
|
|
415
|
+
constructor(windowRef, scrollableHostService) {
|
|
416
|
+
this.windowRef = windowRef;
|
|
417
|
+
this.scrollableHostService = scrollableHostService;
|
|
418
|
+
this.ngUnsubscribe = new Subject();
|
|
419
|
+
this.scrollableHostScrollEventUnsubscribe = new Subject();
|
|
420
|
+
}
|
|
421
|
+
ngOnDestroy() {
|
|
422
|
+
this.ngUnsubscribe.next();
|
|
423
|
+
this.ngUnsubscribe.complete();
|
|
424
|
+
this.scrollableHostScrollEventUnsubscribe.next();
|
|
425
|
+
this.scrollableHostScrollEventUnsubscribe.complete();
|
|
426
|
+
}
|
|
427
|
+
/**
|
|
428
|
+
* This event returns a boolean on scroll indicating whether the provided element is in view.
|
|
429
|
+
* @param elementRef The target element reference.
|
|
430
|
+
*/
|
|
431
|
+
elementInViewOnScroll(elementRef) {
|
|
432
|
+
const scrollableHostObservable = this.scrollableHostService.watchScrollableHostScrollEvents(elementRef);
|
|
433
|
+
const isInitiallyInView = this.isElementScrolledInView(elementRef);
|
|
434
|
+
const returnedObservable = new BehaviorSubject(isInitiallyInView);
|
|
435
|
+
scrollableHostObservable
|
|
436
|
+
.pipe(takeUntil(this.scrollableHostScrollEventUnsubscribe))
|
|
437
|
+
.subscribe(() => {
|
|
438
|
+
const isInView = this.isElementScrolledInView(elementRef);
|
|
439
|
+
returnedObservable.next(isInView);
|
|
440
|
+
});
|
|
441
|
+
return returnedObservable;
|
|
442
|
+
}
|
|
443
|
+
/**
|
|
444
|
+
* Scrolls the window or scrollable parent to the provided element.
|
|
445
|
+
* @param elementRef The target element reference.
|
|
446
|
+
*/
|
|
447
|
+
scrollToElement(elementRef) {
|
|
448
|
+
/* sanity check */
|
|
449
|
+
/* istanbul ignore if */
|
|
450
|
+
if (!elementRef || !elementRef.nativeElement) {
|
|
451
|
+
return;
|
|
452
|
+
}
|
|
453
|
+
const scrollableHost = this.scrollableHostService.getScrollableHost(elementRef);
|
|
454
|
+
if (scrollableHost instanceof Window) {
|
|
455
|
+
// Scroll to top of window, but account for the body margin that allows for the omnibar if it exists.
|
|
456
|
+
const bodyMarginOffset = parseInt(getComputedStyle(document.body).marginTop, 10);
|
|
457
|
+
const newOffsetTop = elementRef.nativeElement.offsetTop - bodyMarginOffset;
|
|
458
|
+
this.windowRef.nativeWindow.scrollTo(elementRef.nativeElement.offsetLeft, newOffsetTop);
|
|
459
|
+
}
|
|
460
|
+
else {
|
|
461
|
+
// Scroll to top of parent element.
|
|
462
|
+
scrollableHost.scrollTop =
|
|
463
|
+
scrollableHost.offsetTop - elementRef.nativeElement.offsetTop;
|
|
464
|
+
}
|
|
465
|
+
}
|
|
466
|
+
isElementScrolledInView(element) {
|
|
467
|
+
const parentElement = this.scrollableHostService.getScrollableHost(element.nativeElement);
|
|
468
|
+
if (!element.nativeElement.offsetParent) {
|
|
469
|
+
return true;
|
|
470
|
+
}
|
|
471
|
+
const buffer = 25;
|
|
472
|
+
const elementRect = element.nativeElement.getBoundingClientRect();
|
|
473
|
+
/* istanbul ignore else */
|
|
474
|
+
if (parentElement instanceof HTMLElement) {
|
|
475
|
+
const parentRect = parentElement.getBoundingClientRect();
|
|
476
|
+
return elementRect.top > parentRect.top - buffer;
|
|
477
|
+
}
|
|
478
|
+
else {
|
|
479
|
+
return elementRect.top > -buffer;
|
|
480
|
+
}
|
|
481
|
+
}
|
|
482
|
+
}
|
|
483
|
+
SkyBackToTopDomAdapterService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyBackToTopDomAdapterService, deps: [{ token: i1.SkyAppWindowRef }, { token: i1.SkyScrollableHostService }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
484
|
+
SkyBackToTopDomAdapterService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyBackToTopDomAdapterService });
|
|
485
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyBackToTopDomAdapterService, decorators: [{
|
|
486
|
+
type: Injectable
|
|
487
|
+
}], ctorParameters: function () { return [{ type: i1.SkyAppWindowRef }, { type: i1.SkyScrollableHostService }]; } });
|
|
488
|
+
|
|
489
|
+
/**
|
|
490
|
+
* Specifies the type of message to send to the back to top component.
|
|
491
|
+
*/
|
|
492
|
+
var SkyBackToTopMessageType;
|
|
493
|
+
(function (SkyBackToTopMessageType) {
|
|
494
|
+
/**
|
|
495
|
+
* Scrolls the element back to the top.
|
|
496
|
+
*/
|
|
497
|
+
SkyBackToTopMessageType[SkyBackToTopMessageType["BackToTop"] = 0] = "BackToTop";
|
|
498
|
+
})(SkyBackToTopMessageType || (SkyBackToTopMessageType = {}));
|
|
499
|
+
|
|
500
|
+
/**
|
|
501
|
+
* Associates a button with an element on the page and displays that button
|
|
502
|
+
* to return to the element after users scroll away.
|
|
503
|
+
*/
|
|
504
|
+
class SkyBackToTopDirective {
|
|
505
|
+
constructor(dockService, domAdapter, element) {
|
|
506
|
+
this.dockService = dockService;
|
|
507
|
+
this.domAdapter = domAdapter;
|
|
508
|
+
this.element = element;
|
|
509
|
+
this.buttonHidden = false;
|
|
510
|
+
this.ngUnsubscribe = new Subject();
|
|
511
|
+
}
|
|
512
|
+
/**
|
|
513
|
+
* Specifies configuration options for the back to top component.
|
|
514
|
+
*/
|
|
515
|
+
set skyBackToTop(value) {
|
|
516
|
+
this.buttonHidden = !!value?.buttonHidden;
|
|
517
|
+
this.handleBackToTopButton(this.elementInView);
|
|
518
|
+
}
|
|
519
|
+
/**
|
|
520
|
+
* Provides an observable to send commands to the back to top component.
|
|
521
|
+
* The commands respect the `SkyBackToTopMessage` type.
|
|
522
|
+
*/
|
|
523
|
+
set skyBackToTopMessageStream(value) {
|
|
524
|
+
if (this._skyBackToTopMessageStream) {
|
|
525
|
+
this._skyBackToTopMessageStream.unsubscribe();
|
|
526
|
+
}
|
|
527
|
+
this._skyBackToTopMessageStream = value;
|
|
528
|
+
this._skyBackToTopMessageStream
|
|
529
|
+
.pipe(takeUntil(this.ngUnsubscribe))
|
|
530
|
+
.subscribe((message) => this.handleIncomingMessages(message));
|
|
531
|
+
}
|
|
532
|
+
ngAfterViewInit() {
|
|
533
|
+
this.elementInView = this.domAdapter.isElementScrolledInView(this.element);
|
|
534
|
+
this.handleBackToTopButton(this.elementInView);
|
|
535
|
+
this.setBackToTopListeners();
|
|
536
|
+
}
|
|
537
|
+
ngOnDestroy() {
|
|
538
|
+
if (this.dockItem) {
|
|
539
|
+
this.dockItem.destroy();
|
|
540
|
+
}
|
|
541
|
+
}
|
|
542
|
+
handleBackToTopButton(elementInView) {
|
|
543
|
+
// Add back to top button if user scrolls down and button is not hidden.
|
|
544
|
+
if (!this.dockItem &&
|
|
545
|
+
elementInView !== undefined &&
|
|
546
|
+
!elementInView &&
|
|
547
|
+
!this.buttonHidden) {
|
|
548
|
+
this.addBackToTop();
|
|
549
|
+
}
|
|
550
|
+
// Remove back to top button if user scrolls back up.
|
|
551
|
+
if (elementInView || this.buttonHidden) {
|
|
552
|
+
this.destroyBackToTop();
|
|
553
|
+
}
|
|
554
|
+
}
|
|
555
|
+
addBackToTop() {
|
|
556
|
+
this.dockItem = this.dockService.insertComponent(SkyBackToTopComponent);
|
|
557
|
+
// Listen for clicks on the "back to top" button so we know when to scroll up.
|
|
558
|
+
this.dockItem.componentInstance.scrollToTopClick
|
|
559
|
+
.pipe(takeUntil(this.ngUnsubscribe))
|
|
560
|
+
.subscribe(() => {
|
|
561
|
+
this.domAdapter.scrollToElement(this.element);
|
|
562
|
+
});
|
|
563
|
+
}
|
|
564
|
+
handleIncomingMessages(message) {
|
|
565
|
+
/* istanbul ignore else */
|
|
566
|
+
if (message.type === SkyBackToTopMessageType.BackToTop) {
|
|
567
|
+
this.domAdapter.scrollToElement(this.element);
|
|
568
|
+
}
|
|
569
|
+
}
|
|
570
|
+
setBackToTopListeners() {
|
|
571
|
+
/* istanbul ignore else */
|
|
572
|
+
if (this.element) {
|
|
573
|
+
this.domAdapter
|
|
574
|
+
.elementInViewOnScroll(this.element)
|
|
575
|
+
.pipe(takeUntil(this.ngUnsubscribe))
|
|
576
|
+
.subscribe((elementInView) => {
|
|
577
|
+
this.elementInView = elementInView;
|
|
578
|
+
this.handleBackToTopButton(elementInView);
|
|
579
|
+
});
|
|
580
|
+
}
|
|
581
|
+
}
|
|
582
|
+
destroyBackToTop() {
|
|
583
|
+
/* istanbul ignore else */
|
|
584
|
+
if (this.dockItem) {
|
|
585
|
+
this.dockItem.destroy();
|
|
586
|
+
this.dockItem = undefined;
|
|
587
|
+
}
|
|
588
|
+
}
|
|
589
|
+
}
|
|
590
|
+
SkyBackToTopDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyBackToTopDirective, deps: [{ token: i1.SkyDockService }, { token: SkyBackToTopDomAdapterService }, { token: i0.ElementRef }], target: i0.ɵɵFactoryTarget.Directive });
|
|
591
|
+
SkyBackToTopDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "13.2.7", type: SkyBackToTopDirective, selector: "[skyBackToTop]", inputs: { skyBackToTop: "skyBackToTop", skyBackToTopMessageStream: "skyBackToTopMessageStream" }, providers: [SkyBackToTopDomAdapterService], ngImport: i0 });
|
|
592
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyBackToTopDirective, decorators: [{
|
|
593
|
+
type: Directive,
|
|
594
|
+
args: [{
|
|
595
|
+
selector: '[skyBackToTop]',
|
|
596
|
+
providers: [SkyBackToTopDomAdapterService],
|
|
597
|
+
}]
|
|
598
|
+
}], ctorParameters: function () { return [{ type: i1.SkyDockService }, { type: SkyBackToTopDomAdapterService }, { type: i0.ElementRef }]; }, propDecorators: { skyBackToTop: [{
|
|
599
|
+
type: Input
|
|
600
|
+
}], skyBackToTopMessageStream: [{
|
|
601
|
+
type: Input
|
|
602
|
+
}] } });
|
|
603
|
+
|
|
604
|
+
class SkyBackToTopModule {
|
|
605
|
+
}
|
|
606
|
+
SkyBackToTopModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyBackToTopModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
607
|
+
SkyBackToTopModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyBackToTopModule, declarations: [SkyBackToTopComponent, SkyBackToTopDirective], imports: [CommonModule,
|
|
608
|
+
SkyDockModule,
|
|
609
|
+
SkyI18nModule,
|
|
610
|
+
SkyLayoutResourcesModule], exports: [SkyBackToTopComponent, SkyBackToTopDirective] });
|
|
611
|
+
SkyBackToTopModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyBackToTopModule, imports: [[
|
|
612
|
+
CommonModule,
|
|
613
|
+
SkyDockModule,
|
|
614
|
+
SkyI18nModule,
|
|
615
|
+
SkyLayoutResourcesModule,
|
|
616
|
+
]] });
|
|
617
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyBackToTopModule, decorators: [{
|
|
618
|
+
type: NgModule,
|
|
619
|
+
args: [{
|
|
620
|
+
declarations: [SkyBackToTopComponent, SkyBackToTopDirective],
|
|
621
|
+
imports: [
|
|
622
|
+
CommonModule,
|
|
623
|
+
SkyDockModule,
|
|
624
|
+
SkyI18nModule,
|
|
625
|
+
SkyLayoutResourcesModule,
|
|
626
|
+
],
|
|
627
|
+
exports: [SkyBackToTopComponent, SkyBackToTopDirective],
|
|
628
|
+
}]
|
|
629
|
+
}] });
|
|
630
|
+
|
|
631
|
+
/**
|
|
632
|
+
* Specifies the body content to display inside the box and provides padding around that content.
|
|
633
|
+
*/
|
|
634
|
+
class SkyBoxContentComponent {
|
|
635
|
+
}
|
|
636
|
+
SkyBoxContentComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyBoxContentComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
637
|
+
SkyBoxContentComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.2.7", type: SkyBoxContentComponent, selector: "sky-box-content", ngImport: i0, template: "<div\n class=\"sky-box-content\"\n [skyThemeClass]=\"{\n 'sky-padding-even-large': 'default',\n 'sky-padding-even-xl': 'modern'\n }\"\n>\n <ng-content></ng-content>\n</div>\n", directives: [{ type: i3$1.λ2, selector: "[skyThemeClass]", inputs: ["class", "skyThemeClass"] }] });
|
|
638
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyBoxContentComponent, decorators: [{
|
|
639
|
+
type: Component,
|
|
640
|
+
args: [{ selector: 'sky-box-content', template: "<div\n class=\"sky-box-content\"\n [skyThemeClass]=\"{\n 'sky-padding-even-large': 'default',\n 'sky-padding-even-xl': 'modern'\n }\"\n>\n <ng-content></ng-content>\n</div>\n" }]
|
|
641
|
+
}] });
|
|
642
|
+
|
|
643
|
+
/**
|
|
644
|
+
* Specifies the controls to display in upper right corner of the box. These buttons typically let users edit the box content.
|
|
645
|
+
*/
|
|
646
|
+
class SkyBoxControlsComponent {
|
|
647
|
+
}
|
|
648
|
+
SkyBoxControlsComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyBoxControlsComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
649
|
+
SkyBoxControlsComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.2.7", type: SkyBoxControlsComponent, selector: "sky-box-controls", ngImport: i0, template: "<div class=\"sky-box-controls\">\n <ng-content></ng-content>\n</div>\n" });
|
|
650
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyBoxControlsComponent, decorators: [{
|
|
651
|
+
type: Component,
|
|
652
|
+
args: [{ selector: 'sky-box-controls', template: "<div class=\"sky-box-controls\">\n <ng-content></ng-content>\n</div>\n" }]
|
|
653
|
+
}] });
|
|
654
|
+
|
|
655
|
+
/**
|
|
656
|
+
* Specifies a header for the box.
|
|
657
|
+
*/
|
|
658
|
+
class SkyBoxHeaderComponent {
|
|
659
|
+
}
|
|
660
|
+
SkyBoxHeaderComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyBoxHeaderComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
661
|
+
SkyBoxHeaderComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.2.7", type: SkyBoxHeaderComponent, selector: "sky-box-header", ngImport: i0, template: "<div class=\"sky-box-header\">\n <ng-content></ng-content>\n</div>\n" });
|
|
662
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyBoxHeaderComponent, decorators: [{
|
|
663
|
+
type: Component,
|
|
664
|
+
args: [{ selector: 'sky-box-header', template: "<div class=\"sky-box-header\">\n <ng-content></ng-content>\n</div>\n" }]
|
|
665
|
+
}] });
|
|
666
|
+
|
|
667
|
+
/**
|
|
668
|
+
* Provides a common look-and-feel for box content with options to display a common box header, specify body content, and display common box controls.
|
|
669
|
+
*/
|
|
670
|
+
class SkyBoxComponent {
|
|
671
|
+
}
|
|
672
|
+
SkyBoxComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyBoxComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
673
|
+
SkyBoxComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.2.7", type: SkyBoxComponent, selector: "sky-box", inputs: { ariaLabel: "ariaLabel", ariaLabelledBy: "ariaLabelledBy", ariaRole: "ariaRole" }, ngImport: i0, template: "<section\n class=\"sky-box\"\n [attr.aria-label]=\"ariaLabel\"\n [attr.aria-labelledby]=\"ariaLabelledBy\"\n [attr.role]=\"ariaRole\"\n [skyThemeClass]=\"{\n 'sky-shadow sky-border-dark': 'default',\n 'sky-elevation-1-bordered': 'modern'\n }\"\n>\n <div class=\"sky-box-header-content\">\n <ng-content select=\"sky-box-header\"></ng-content>\n <ng-content select=\"sky-box-controls\"></ng-content>\n </div>\n <ng-content></ng-content>\n</section>\n", styles: [".sky-box{background-color:#fff}.sky-box .sky-box-header-content{display:flex;flex-direction:row;flex-wrap:wrap;align-items:baseline;padding:20px 20px 0}.sky-box .sky-box-header-content:empty{display:none}.sky-box .sky-box-header-content sky-box-header{flex:1 0;order:0}.sky-box .sky-box-header-content sky-box-header .sky-box-header{padding:0 20px 0 0}.sky-box .sky-box-header-content sky-box-header .sky-box-header h1,.sky-box .sky-box-header-content sky-box-header .sky-box-header h2,.sky-box .sky-box-header-content sky-box-header .sky-box-header h3,.sky-box .sky-box-header-content sky-box-header .sky-box-header h4,.sky-box .sky-box-header-content sky-box-header .sky-box-header h5,.sky-box .sky-box-header-content sky-box-header .sky-box-header h6{margin:0}.sky-box .sky-box-header-content sky-box-controls{order:1}.sky-box .sky-box-header-content sky-box-controls .sky-box-controls{position:relative;top:-2px}.sky-box sky-box-content{flex:0 1 100%;order:2}.sky-box sky-box-content .sky-box-content{padding:20px}.sky-theme-modern .sky-box{border-radius:6px;overflow:hidden}.sky-theme-modern .sky-box .sky-box-header-content{padding:30px 30px 0}.sky-theme-modern .sky-box .sky-box-header-content sky-box-header .sky-box-header{padding:0 30px 0 0}.sky-theme-modern .sky-box sky-box-content .sky-box-content{padding:30px}\n"], directives: [{ type: i3$1.λ2, selector: "[skyThemeClass]", inputs: ["class", "skyThemeClass"] }], encapsulation: i0.ViewEncapsulation.None });
|
|
674
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyBoxComponent, decorators: [{
|
|
675
|
+
type: Component,
|
|
676
|
+
args: [{ selector: 'sky-box', encapsulation: ViewEncapsulation.None, template: "<section\n class=\"sky-box\"\n [attr.aria-label]=\"ariaLabel\"\n [attr.aria-labelledby]=\"ariaLabelledBy\"\n [attr.role]=\"ariaRole\"\n [skyThemeClass]=\"{\n 'sky-shadow sky-border-dark': 'default',\n 'sky-elevation-1-bordered': 'modern'\n }\"\n>\n <div class=\"sky-box-header-content\">\n <ng-content select=\"sky-box-header\"></ng-content>\n <ng-content select=\"sky-box-controls\"></ng-content>\n </div>\n <ng-content></ng-content>\n</section>\n", styles: [".sky-box{background-color:#fff}.sky-box .sky-box-header-content{display:flex;flex-direction:row;flex-wrap:wrap;align-items:baseline;padding:20px 20px 0}.sky-box .sky-box-header-content:empty{display:none}.sky-box .sky-box-header-content sky-box-header{flex:1 0;order:0}.sky-box .sky-box-header-content sky-box-header .sky-box-header{padding:0 20px 0 0}.sky-box .sky-box-header-content sky-box-header .sky-box-header h1,.sky-box .sky-box-header-content sky-box-header .sky-box-header h2,.sky-box .sky-box-header-content sky-box-header .sky-box-header h3,.sky-box .sky-box-header-content sky-box-header .sky-box-header h4,.sky-box .sky-box-header-content sky-box-header .sky-box-header h5,.sky-box .sky-box-header-content sky-box-header .sky-box-header h6{margin:0}.sky-box .sky-box-header-content sky-box-controls{order:1}.sky-box .sky-box-header-content sky-box-controls .sky-box-controls{position:relative;top:-2px}.sky-box sky-box-content{flex:0 1 100%;order:2}.sky-box sky-box-content .sky-box-content{padding:20px}.sky-theme-modern .sky-box{border-radius:6px;overflow:hidden}.sky-theme-modern .sky-box .sky-box-header-content{padding:30px 30px 0}.sky-theme-modern .sky-box .sky-box-header-content sky-box-header .sky-box-header{padding:0 30px 0 0}.sky-theme-modern .sky-box sky-box-content .sky-box-content{padding:30px}\n"] }]
|
|
677
|
+
}], propDecorators: { ariaLabel: [{
|
|
678
|
+
type: Input
|
|
679
|
+
}], ariaLabelledBy: [{
|
|
680
|
+
type: Input
|
|
681
|
+
}], ariaRole: [{
|
|
682
|
+
type: Input
|
|
683
|
+
}] } });
|
|
684
|
+
|
|
685
|
+
class SkyBoxModule {
|
|
686
|
+
}
|
|
687
|
+
SkyBoxModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyBoxModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
688
|
+
SkyBoxModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyBoxModule, declarations: [SkyBoxComponent,
|
|
689
|
+
SkyBoxHeaderComponent,
|
|
690
|
+
SkyBoxContentComponent,
|
|
691
|
+
SkyBoxControlsComponent], imports: [CommonModule, SkyThemeModule], exports: [SkyBoxComponent,
|
|
692
|
+
SkyBoxHeaderComponent,
|
|
693
|
+
SkyBoxContentComponent,
|
|
694
|
+
SkyBoxControlsComponent] });
|
|
695
|
+
SkyBoxModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyBoxModule, imports: [[CommonModule, SkyThemeModule]] });
|
|
696
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyBoxModule, decorators: [{
|
|
697
|
+
type: NgModule,
|
|
698
|
+
args: [{
|
|
699
|
+
declarations: [
|
|
700
|
+
SkyBoxComponent,
|
|
701
|
+
SkyBoxHeaderComponent,
|
|
702
|
+
SkyBoxContentComponent,
|
|
703
|
+
SkyBoxControlsComponent,
|
|
704
|
+
],
|
|
705
|
+
imports: [CommonModule, SkyThemeModule],
|
|
706
|
+
exports: [
|
|
707
|
+
SkyBoxComponent,
|
|
708
|
+
SkyBoxHeaderComponent,
|
|
709
|
+
SkyBoxContentComponent,
|
|
710
|
+
SkyBoxControlsComponent,
|
|
711
|
+
],
|
|
712
|
+
}]
|
|
713
|
+
}] });
|
|
714
|
+
|
|
715
|
+
/**
|
|
716
|
+
* @internal
|
|
717
|
+
*/
|
|
718
|
+
class SkyInlineDeleteAdapterService {
|
|
719
|
+
constructor(coreAdapterService, rendererFactory) {
|
|
720
|
+
this.coreAdapterService = coreAdapterService;
|
|
721
|
+
this.renderer = rendererFactory.createRenderer(undefined, undefined);
|
|
722
|
+
}
|
|
723
|
+
clearListeners() {
|
|
724
|
+
/* istanbul ignore else */
|
|
725
|
+
if (this.parentElUnlistenFn) {
|
|
726
|
+
this.parentElUnlistenFn();
|
|
727
|
+
}
|
|
728
|
+
}
|
|
729
|
+
setEl(element) {
|
|
730
|
+
this.element = element;
|
|
731
|
+
this.parentEl = element.parentElement;
|
|
732
|
+
/* istanbul ignore else */
|
|
733
|
+
if (this.parentEl) {
|
|
734
|
+
this.parentElUnlistenFn = this.renderer.listen(this.parentEl, 'focusin', (event) => {
|
|
735
|
+
const target = event.target;
|
|
736
|
+
if (!this.element.contains(target) && this.parentEl !== target) {
|
|
737
|
+
event.preventDefault();
|
|
738
|
+
event.stopPropagation();
|
|
739
|
+
event.stopImmediatePropagation();
|
|
740
|
+
target.blur();
|
|
741
|
+
this.focusNextElement(target, this.isShift(event), this.parentEl);
|
|
742
|
+
}
|
|
743
|
+
});
|
|
744
|
+
}
|
|
745
|
+
}
|
|
746
|
+
focusNextElement(targetElement, shiftKey, busyEl) {
|
|
747
|
+
const focussable = this.getFocussableElements();
|
|
748
|
+
// If shift tab, go in the other direction
|
|
749
|
+
const modifier = shiftKey ? -1 : 1;
|
|
750
|
+
// Find the next navigable element that isn't waiting
|
|
751
|
+
const startingIndex = focussable.indexOf(targetElement);
|
|
752
|
+
let curIndex = startingIndex + modifier;
|
|
753
|
+
while (focussable[curIndex] &&
|
|
754
|
+
this.isElementHiddenOrCovered(focussable[curIndex])) {
|
|
755
|
+
curIndex += modifier;
|
|
756
|
+
}
|
|
757
|
+
if (focussable[curIndex] &&
|
|
758
|
+
!this.isElementHiddenOrCovered(focussable[curIndex])) {
|
|
759
|
+
focussable[curIndex].focus();
|
|
760
|
+
}
|
|
761
|
+
else {
|
|
762
|
+
// Try wrapping the navigation
|
|
763
|
+
/* istanbul ignore next */
|
|
764
|
+
curIndex = modifier > 0 ? 0 : focussable.length - 1;
|
|
765
|
+
/* istanbul ignore next */
|
|
766
|
+
while (curIndex !== startingIndex &&
|
|
767
|
+
focussable[curIndex] &&
|
|
768
|
+
this.isElementHiddenOrCovered(focussable[curIndex])) {
|
|
769
|
+
curIndex += modifier;
|
|
770
|
+
}
|
|
771
|
+
/* istanbul ignore else */
|
|
772
|
+
/* sanity check */
|
|
773
|
+
if (focussable[curIndex] &&
|
|
774
|
+
!this.isElementHiddenOrCovered(focussable[curIndex])) {
|
|
775
|
+
focussable[curIndex].focus();
|
|
776
|
+
}
|
|
777
|
+
else {
|
|
778
|
+
// No valid target, wipe focus
|
|
779
|
+
// This should never happen in practice due to the multiple inline delete buttons
|
|
780
|
+
if (document.activeElement && document.activeElement.blur) {
|
|
781
|
+
document.activeElement.blur();
|
|
782
|
+
}
|
|
783
|
+
document.body.focus();
|
|
784
|
+
}
|
|
785
|
+
}
|
|
786
|
+
// clear focussableElements list so that if things change between tabbing we know about it
|
|
787
|
+
this.focussableElements = undefined;
|
|
788
|
+
}
|
|
789
|
+
getFocussableElements() {
|
|
790
|
+
// Keep this cached so we can reduce querys
|
|
791
|
+
if (this.focussableElements) {
|
|
792
|
+
return this.focussableElements;
|
|
793
|
+
}
|
|
794
|
+
this.focussableElements = this.coreAdapterService.getFocusableChildren(document.body);
|
|
795
|
+
return this.focussableElements;
|
|
796
|
+
}
|
|
797
|
+
isElementHiddenOrCovered(element) {
|
|
798
|
+
// Check if the element is hidden by css, not within the inline delete, or a wait is covering it
|
|
799
|
+
return (this.isElementHidden(element) ||
|
|
800
|
+
(this.parentEl.contains(element) &&
|
|
801
|
+
(!this.element.contains(element) ||
|
|
802
|
+
this.parentEl.querySelector('.sky-wait-mask') !== null)));
|
|
803
|
+
}
|
|
804
|
+
isElementHidden(element) {
|
|
805
|
+
const style = window.getComputedStyle(element);
|
|
806
|
+
return style.display === 'none' || style.visibility === 'hidden';
|
|
807
|
+
}
|
|
808
|
+
isShift(event) {
|
|
809
|
+
// Determine if shift+tab was used based on element order
|
|
810
|
+
const elements = this.getFocussableElements().filter((elem) => !this.isElementHidden(elem));
|
|
811
|
+
const previousInd = elements.indexOf(event.relatedTarget);
|
|
812
|
+
const currentInd = elements.indexOf(event.target);
|
|
813
|
+
/* istanbul ignore next */
|
|
814
|
+
return (previousInd === currentInd + 1 ||
|
|
815
|
+
(previousInd === 0 && currentInd === elements.length - 1) ||
|
|
816
|
+
previousInd > currentInd ||
|
|
817
|
+
!event.relatedTarget);
|
|
818
|
+
}
|
|
819
|
+
}
|
|
820
|
+
SkyInlineDeleteAdapterService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyInlineDeleteAdapterService, deps: [{ token: i1.SkyCoreAdapterService }, { token: i0.RendererFactory2 }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
821
|
+
SkyInlineDeleteAdapterService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyInlineDeleteAdapterService });
|
|
822
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyInlineDeleteAdapterService, decorators: [{
|
|
823
|
+
type: Injectable
|
|
824
|
+
}], ctorParameters: function () { return [{ type: i1.SkyCoreAdapterService }, { type: i0.RendererFactory2 }]; } });
|
|
825
|
+
|
|
826
|
+
/**
|
|
827
|
+
* Specifies the type of inline delete that is shown.
|
|
828
|
+
* @internal
|
|
829
|
+
*/
|
|
830
|
+
var SkyInlineDeleteType;
|
|
831
|
+
(function (SkyInlineDeleteType) {
|
|
832
|
+
/**
|
|
833
|
+
* The standard styling for inline deletes.
|
|
834
|
+
*/
|
|
835
|
+
SkyInlineDeleteType["Standard"] = "standard";
|
|
836
|
+
/**
|
|
837
|
+
* The styling for inline delete components which are used in card components.
|
|
838
|
+
*/
|
|
839
|
+
SkyInlineDeleteType["Card"] = "card";
|
|
840
|
+
})(SkyInlineDeleteType || (SkyInlineDeleteType = {}));
|
|
841
|
+
|
|
842
|
+
/**
|
|
843
|
+
* Auto-incrementing integer used to generate unique ids for inline delete components.
|
|
844
|
+
*/
|
|
845
|
+
let nextId$2 = 0;
|
|
846
|
+
class SkyInlineDeleteComponent {
|
|
847
|
+
constructor(adapterService, changeDetector, elRef) {
|
|
848
|
+
this.adapterService = adapterService;
|
|
849
|
+
this.changeDetector = changeDetector;
|
|
850
|
+
this.elRef = elRef;
|
|
851
|
+
/**
|
|
852
|
+
* Indicates whether the deletion is pending.
|
|
853
|
+
* @default false
|
|
854
|
+
*/
|
|
855
|
+
this.pending = false;
|
|
856
|
+
/**
|
|
857
|
+
* Fires when users click the cancel button.
|
|
858
|
+
*/
|
|
859
|
+
this.cancelTriggered = new EventEmitter();
|
|
860
|
+
/**
|
|
861
|
+
* Fires when users click the delete button.
|
|
862
|
+
*/
|
|
863
|
+
this.deleteTriggered = new EventEmitter();
|
|
864
|
+
this.animationState = 'shown';
|
|
865
|
+
this.assistiveTextId = `sky-inline-delete-assistive-text-${++nextId$2}`;
|
|
866
|
+
this.type = SkyInlineDeleteType.Standard;
|
|
867
|
+
}
|
|
868
|
+
/**
|
|
869
|
+
* Initialization lifecycle hook
|
|
870
|
+
* @internal
|
|
871
|
+
*/
|
|
872
|
+
ngOnInit() {
|
|
873
|
+
this.animationState = 'shown';
|
|
874
|
+
}
|
|
875
|
+
/**
|
|
876
|
+
* Destruction lifecycle hook
|
|
877
|
+
* @internal
|
|
878
|
+
*/
|
|
879
|
+
ngOnDestroy() {
|
|
880
|
+
this.adapterService.clearListeners();
|
|
881
|
+
this.cancelTriggered.complete();
|
|
882
|
+
this.deleteTriggered.complete();
|
|
883
|
+
}
|
|
884
|
+
/**
|
|
885
|
+
* @internal
|
|
886
|
+
*/
|
|
887
|
+
onCancelClick() {
|
|
888
|
+
this.animationState = 'hidden';
|
|
889
|
+
}
|
|
890
|
+
/**
|
|
891
|
+
* @internal
|
|
892
|
+
*/
|
|
893
|
+
onDeleteClick() {
|
|
894
|
+
this.deleteTriggered.emit();
|
|
895
|
+
}
|
|
896
|
+
/**
|
|
897
|
+
* Sets the inline delete to one of its predefined types.
|
|
898
|
+
* @param type The inline delete type
|
|
899
|
+
* @internal
|
|
900
|
+
*/
|
|
901
|
+
setType(type) {
|
|
902
|
+
this.type = type;
|
|
903
|
+
this.changeDetector.detectChanges();
|
|
904
|
+
}
|
|
905
|
+
/**
|
|
906
|
+
* Handles actions that should be taken after the inline delete animates
|
|
907
|
+
* @param event The animation event
|
|
908
|
+
* @internal
|
|
909
|
+
*/
|
|
910
|
+
onAnimationDone(event) {
|
|
911
|
+
if (event.toState === 'hidden') {
|
|
912
|
+
this.cancelTriggered.emit();
|
|
913
|
+
}
|
|
914
|
+
else {
|
|
915
|
+
this.deleteButton.nativeElement.focus();
|
|
916
|
+
/* istanbul ignore else */
|
|
917
|
+
if (this.elRef) {
|
|
918
|
+
this.adapterService.setEl(this.elRef.nativeElement);
|
|
919
|
+
}
|
|
920
|
+
}
|
|
921
|
+
}
|
|
922
|
+
}
|
|
923
|
+
SkyInlineDeleteComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyInlineDeleteComponent, deps: [{ token: SkyInlineDeleteAdapterService }, { token: i0.ChangeDetectorRef }, { token: i0.ElementRef }], target: i0.ɵɵFactoryTarget.Component });
|
|
924
|
+
SkyInlineDeleteComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.2.7", type: SkyInlineDeleteComponent, selector: "sky-inline-delete", inputs: { pending: "pending" }, outputs: { cancelTriggered: "cancelTriggered", deleteTriggered: "deleteTriggered" }, providers: [SkyCoreAdapterService, SkyInlineDeleteAdapterService], viewQueries: [{ propertyName: "deleteButton", first: true, predicate: ["delete"], descendants: true, read: ElementRef }], ngImport: i0, template: "<div\n class=\"sky-inline-delete sky-inline-delete-{{ type }}\"\n role=\"alertdialog\"\n [@inlineDeleteAnimation]=\"animationState\"\n (@inlineDeleteAnimation.done)=\"onAnimationDone($event)\"\n [attr.aria-describedby]=\"assistiveTextId\"\n [attr.aria-label]=\"'skyux_inline_delete_confirm_deletion' | skyLibResources\"\n>\n <span class=\"sky-inline-delete-assistive-text\" [id]=\"assistiveTextId\">\n {{ 'skyux_inline_delete_assistive_text' | skyLibResources }}\n </span>\n <sky-wait class=\"sky-inline-delete-wait\" [isWaiting]=\"pending\"></sky-wait>\n <div class=\"sky-inline-delete-content\">\n <div class=\"sky-inline-delete-content-animation-container\">\n <button\n class=\"sky-btn sky-btn-danger sky-inline-delete-button\"\n type=\"button\"\n (click)=\"onDeleteClick()\"\n #delete\n >\n {{ 'skyux_inline_delete_delete' | skyLibResources }}\n </button>\n <button\n class=\"sky-btn sky-btn-default\"\n type=\"button\"\n (click)=\"onCancelClick()\"\n >\n {{ 'skyux_inline_delete_cancel' | skyLibResources }}\n </button>\n </div>\n </div>\n</div>\n", styles: [".sky-inline-delete{position:absolute!important;top:0px;left:0px;width:100%;height:100%;background-color:#00000080;z-index:999;border:2px solid #ef4044}.sky-inline-delete-assistive-text{width:0;height:0;padding:0;opacity:0;position:absolute;margin:-1px;border:0;overflow:hidden;clip:rect(0,0,0,0);outline:none;white-space:nowrap}.sky-inline-delete-button{margin-right:10px}.sky-inline-delete-card .sky-inline-delete-content{position:absolute;bottom:10px;text-align:center;width:100%}.sky-inline-delete-standard .sky-inline-delete-content{position:absolute;top:50%;transform:translateY(-50%);left:20px}.sky-inline-delete-wait{height:100%}\n"], components: [{ type: i2$1.λ14, selector: "sky-wait", inputs: ["ariaLabel", "isWaiting", "isFullPage", "isNonBlocking"] }], pipes: { "skyLibResources": i1$1.SkyLibResourcesPipe }, animations: [
|
|
925
|
+
trigger('inlineDeleteAnimation', [
|
|
926
|
+
transition('* => shown', [
|
|
927
|
+
style({
|
|
928
|
+
opacity: 0,
|
|
929
|
+
}),
|
|
930
|
+
query('.sky-inline-delete-content-animation-container', style({ transform: 'scale(0.0)' })),
|
|
931
|
+
group([
|
|
932
|
+
animate('300ms ease-in-out', style({ opacity: 1 })),
|
|
933
|
+
query('.sky-inline-delete-content-animation-container', animate('300ms ease-in-out', style({
|
|
934
|
+
transform: 'scale(1)',
|
|
935
|
+
}))),
|
|
936
|
+
]),
|
|
937
|
+
]),
|
|
938
|
+
transition(`shown <=> *`, [
|
|
939
|
+
query('.sky-inline-delete-content-animation-container', style({ transform: 'scale(1)' })),
|
|
940
|
+
group([
|
|
941
|
+
animate('300ms ease-in-out', style({
|
|
942
|
+
opacity: 0,
|
|
943
|
+
})),
|
|
944
|
+
query('.sky-inline-delete-content-animation-container', animate('300ms ease-in-out', style({
|
|
945
|
+
transform: 'scale(0.0)',
|
|
946
|
+
}))),
|
|
947
|
+
]),
|
|
948
|
+
]),
|
|
949
|
+
]),
|
|
950
|
+
] });
|
|
951
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyInlineDeleteComponent, decorators: [{
|
|
952
|
+
type: Component,
|
|
953
|
+
args: [{ selector: 'sky-inline-delete', animations: [
|
|
954
|
+
trigger('inlineDeleteAnimation', [
|
|
955
|
+
transition('* => shown', [
|
|
956
|
+
style({
|
|
957
|
+
opacity: 0,
|
|
958
|
+
}),
|
|
959
|
+
query('.sky-inline-delete-content-animation-container', style({ transform: 'scale(0.0)' })),
|
|
960
|
+
group([
|
|
961
|
+
animate('300ms ease-in-out', style({ opacity: 1 })),
|
|
962
|
+
query('.sky-inline-delete-content-animation-container', animate('300ms ease-in-out', style({
|
|
963
|
+
transform: 'scale(1)',
|
|
964
|
+
}))),
|
|
965
|
+
]),
|
|
966
|
+
]),
|
|
967
|
+
transition(`shown <=> *`, [
|
|
968
|
+
query('.sky-inline-delete-content-animation-container', style({ transform: 'scale(1)' })),
|
|
969
|
+
group([
|
|
970
|
+
animate('300ms ease-in-out', style({
|
|
971
|
+
opacity: 0,
|
|
972
|
+
})),
|
|
973
|
+
query('.sky-inline-delete-content-animation-container', animate('300ms ease-in-out', style({
|
|
974
|
+
transform: 'scale(0.0)',
|
|
975
|
+
}))),
|
|
976
|
+
]),
|
|
977
|
+
]),
|
|
978
|
+
]),
|
|
979
|
+
], providers: [SkyCoreAdapterService, SkyInlineDeleteAdapterService], template: "<div\n class=\"sky-inline-delete sky-inline-delete-{{ type }}\"\n role=\"alertdialog\"\n [@inlineDeleteAnimation]=\"animationState\"\n (@inlineDeleteAnimation.done)=\"onAnimationDone($event)\"\n [attr.aria-describedby]=\"assistiveTextId\"\n [attr.aria-label]=\"'skyux_inline_delete_confirm_deletion' | skyLibResources\"\n>\n <span class=\"sky-inline-delete-assistive-text\" [id]=\"assistiveTextId\">\n {{ 'skyux_inline_delete_assistive_text' | skyLibResources }}\n </span>\n <sky-wait class=\"sky-inline-delete-wait\" [isWaiting]=\"pending\"></sky-wait>\n <div class=\"sky-inline-delete-content\">\n <div class=\"sky-inline-delete-content-animation-container\">\n <button\n class=\"sky-btn sky-btn-danger sky-inline-delete-button\"\n type=\"button\"\n (click)=\"onDeleteClick()\"\n #delete\n >\n {{ 'skyux_inline_delete_delete' | skyLibResources }}\n </button>\n <button\n class=\"sky-btn sky-btn-default\"\n type=\"button\"\n (click)=\"onCancelClick()\"\n >\n {{ 'skyux_inline_delete_cancel' | skyLibResources }}\n </button>\n </div>\n </div>\n</div>\n", styles: [".sky-inline-delete{position:absolute!important;top:0px;left:0px;width:100%;height:100%;background-color:#00000080;z-index:999;border:2px solid #ef4044}.sky-inline-delete-assistive-text{width:0;height:0;padding:0;opacity:0;position:absolute;margin:-1px;border:0;overflow:hidden;clip:rect(0,0,0,0);outline:none;white-space:nowrap}.sky-inline-delete-button{margin-right:10px}.sky-inline-delete-card .sky-inline-delete-content{position:absolute;bottom:10px;text-align:center;width:100%}.sky-inline-delete-standard .sky-inline-delete-content{position:absolute;top:50%;transform:translateY(-50%);left:20px}.sky-inline-delete-wait{height:100%}\n"] }]
|
|
980
|
+
}], ctorParameters: function () { return [{ type: SkyInlineDeleteAdapterService }, { type: i0.ChangeDetectorRef }, { type: i0.ElementRef }]; }, propDecorators: { pending: [{
|
|
981
|
+
type: Input
|
|
982
|
+
}], cancelTriggered: [{
|
|
983
|
+
type: Output
|
|
984
|
+
}], deleteTriggered: [{
|
|
985
|
+
type: Output
|
|
986
|
+
}], deleteButton: [{
|
|
987
|
+
type: ViewChild,
|
|
988
|
+
args: ['delete', {
|
|
989
|
+
read: ElementRef,
|
|
990
|
+
static: false,
|
|
991
|
+
}]
|
|
992
|
+
}] } });
|
|
993
|
+
|
|
994
|
+
class SkyInlineDeleteModule {
|
|
995
|
+
}
|
|
996
|
+
SkyInlineDeleteModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyInlineDeleteModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
997
|
+
SkyInlineDeleteModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyInlineDeleteModule, declarations: [SkyInlineDeleteComponent], imports: [CommonModule,
|
|
998
|
+
SkyI18nModule,
|
|
999
|
+
SkyLayoutResourcesModule,
|
|
1000
|
+
SkyWaitModule], exports: [SkyInlineDeleteComponent] });
|
|
1001
|
+
SkyInlineDeleteModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyInlineDeleteModule, imports: [[
|
|
1002
|
+
CommonModule,
|
|
1003
|
+
SkyI18nModule,
|
|
1004
|
+
SkyLayoutResourcesModule,
|
|
1005
|
+
SkyWaitModule,
|
|
1006
|
+
]] });
|
|
1007
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyInlineDeleteModule, decorators: [{
|
|
1008
|
+
type: NgModule,
|
|
1009
|
+
args: [{
|
|
1010
|
+
declarations: [SkyInlineDeleteComponent],
|
|
1011
|
+
imports: [
|
|
1012
|
+
CommonModule,
|
|
1013
|
+
SkyI18nModule,
|
|
1014
|
+
SkyLayoutResourcesModule,
|
|
1015
|
+
SkyWaitModule,
|
|
1016
|
+
],
|
|
1017
|
+
exports: [SkyInlineDeleteComponent],
|
|
1018
|
+
}]
|
|
1019
|
+
}] });
|
|
1020
|
+
|
|
1021
|
+
/**
|
|
1022
|
+
* Specifies an action that users can perform on the card.
|
|
1023
|
+
*/
|
|
1024
|
+
class SkyCardActionsComponent {
|
|
1025
|
+
}
|
|
1026
|
+
SkyCardActionsComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyCardActionsComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
1027
|
+
SkyCardActionsComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.2.7", type: SkyCardActionsComponent, selector: "sky-card-actions", ngImport: i0, template: "<ng-content></ng-content>\n", styles: [":host{display:block;border-top:1px solid #e2e3e4;padding:7px 0}\n"] });
|
|
1028
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyCardActionsComponent, decorators: [{
|
|
1029
|
+
type: Component,
|
|
1030
|
+
args: [{ selector: 'sky-card-actions', template: "<ng-content></ng-content>\n", styles: [":host{display:block;border-top:1px solid #e2e3e4;padding:7px 0}\n"] }]
|
|
1031
|
+
}] });
|
|
1032
|
+
|
|
1033
|
+
/**
|
|
1034
|
+
* Specifies the content to display in the body of the card.
|
|
1035
|
+
*/
|
|
1036
|
+
class SkyCardContentComponent {
|
|
1037
|
+
}
|
|
1038
|
+
SkyCardContentComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyCardContentComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
1039
|
+
SkyCardContentComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.2.7", type: SkyCardContentComponent, selector: "sky-card-content", ngImport: i0, template: "<ng-content></ng-content>\n" });
|
|
1040
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyCardContentComponent, decorators: [{
|
|
1041
|
+
type: Component,
|
|
1042
|
+
args: [{ selector: 'sky-card-content', template: "<ng-content></ng-content>\n" }]
|
|
1043
|
+
}] });
|
|
1044
|
+
|
|
1045
|
+
/**
|
|
1046
|
+
* Specifies a title to identify what the card represents.
|
|
1047
|
+
*/
|
|
1048
|
+
class SkyCardTitleComponent {
|
|
1049
|
+
}
|
|
1050
|
+
SkyCardTitleComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyCardTitleComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
1051
|
+
SkyCardTitleComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.2.7", type: SkyCardTitleComponent, selector: "sky-card-title", ngImport: i0, template: "<ng-content></ng-content>\n" });
|
|
1052
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyCardTitleComponent, decorators: [{
|
|
1053
|
+
type: Component,
|
|
1054
|
+
args: [{ selector: 'sky-card-title', template: "<ng-content></ng-content>\n" }]
|
|
1055
|
+
}] });
|
|
1056
|
+
|
|
1057
|
+
/**
|
|
1058
|
+
* Creates a a small container to highlight important information.
|
|
1059
|
+
*/
|
|
1060
|
+
class SkyCardComponent {
|
|
1061
|
+
constructor() {
|
|
1062
|
+
/**
|
|
1063
|
+
* Fires when users select or deselect the card.
|
|
1064
|
+
*/
|
|
1065
|
+
this.selectedChange = new EventEmitter();
|
|
1066
|
+
this.showTitle = true;
|
|
1067
|
+
}
|
|
1068
|
+
ngAfterContentInit() {
|
|
1069
|
+
this.showTitle = this.titleComponent.length > 0;
|
|
1070
|
+
this.subscription = this.titleComponent.changes.subscribe(() => {
|
|
1071
|
+
this.showTitle = this.titleComponent.length > 0;
|
|
1072
|
+
});
|
|
1073
|
+
this.inlineDeleteComponent.forEach((item) => {
|
|
1074
|
+
item.setType(SkyInlineDeleteType.Card);
|
|
1075
|
+
});
|
|
1076
|
+
this.inlineDeleteComponent.changes.subscribe(() => {
|
|
1077
|
+
this.inlineDeleteComponent.forEach((item) => {
|
|
1078
|
+
item.setType(SkyInlineDeleteType.Card);
|
|
1079
|
+
});
|
|
1080
|
+
});
|
|
1081
|
+
}
|
|
1082
|
+
contentClick() {
|
|
1083
|
+
if (this.selectable) {
|
|
1084
|
+
this.selected = !this.selected;
|
|
1085
|
+
this.selectedChange.emit(this.selected);
|
|
1086
|
+
}
|
|
1087
|
+
}
|
|
1088
|
+
onCheckboxChange(newValue) {
|
|
1089
|
+
if (this.selectable && this.selected !== newValue) {
|
|
1090
|
+
this.selected = newValue;
|
|
1091
|
+
this.selectedChange.emit(this.selected);
|
|
1092
|
+
}
|
|
1093
|
+
}
|
|
1094
|
+
ngOnDestroy() {
|
|
1095
|
+
/* istanbul ignore else */
|
|
1096
|
+
/* sanity check */
|
|
1097
|
+
if (this.subscription) {
|
|
1098
|
+
this.subscription.unsubscribe();
|
|
1099
|
+
}
|
|
1100
|
+
}
|
|
1101
|
+
}
|
|
1102
|
+
SkyCardComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyCardComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
1103
|
+
SkyCardComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.2.7", type: SkyCardComponent, selector: "sky-card", inputs: { size: "size", selectable: "selectable", selected: "selected" }, outputs: { selectedChange: "selectedChange" }, queries: [{ propertyName: "inlineDeleteComponent", predicate: SkyInlineDeleteComponent }, { propertyName: "titleComponent", predicate: SkyCardTitleComponent }], ngImport: i0, template: "<section\n class=\"sky-card sky-shadow\"\n [ngClass]=\"\n {\n 'sky-card-small': size === 'small',\n 'sky-card-selectable': selectable,\n 'sky-card-selected': selectable && selected\n }\"\n>\n <ng-content select=\"sky-inline-delete\"></ng-content>\n <header>\n <div\n *ngIf=\"selectable || showTitle\"\n class=\"sky-card-header\"\n (click)=\"contentClick()\"\n >\n <div class=\"sky-card-heading-middle\">\n <h1 *ngIf=\"showTitle\" class=\"sky-card-title sky-section-heading\">\n <ng-content select=\"sky-card-title\"></ng-content>\n </h1>\n </div>\n <div *ngIf=\"selectable\" class=\"sky-card-check\">\n <sky-checkbox\n [label]=\"'skyux_card_checkbox_label' | skyLibResources\"\n [ngModel]=\"selected\"\n (click)=\"$event.stopPropagation()\"\n (ngModelChange)=\"onCheckboxChange($event)\"\n ></sky-checkbox>\n </div>\n </div>\n </header>\n <div\n class=\"sky-card-content sky-padding-even-default\"\n (click)=\"contentClick()\"\n >\n <ng-content select=\"sky-card-content\"></ng-content>\n </div>\n <div\n class=\"sky-card-actions\"\n [hidden]=\"actionsEl.children.length === 0\"\n #actionsEl\n >\n <ng-content select=\"sky-card-actions\"></ng-content>\n </div>\n</section>\n", styles: [".sky-card{background-color:#fff;border-top:1px solid #cdcfd2;border-bottom:1px solid #cdcfd2;border-left:1px solid #cdcfd2;border-right:1px solid #cdcfd2;display:inline-flex;flex-direction:column;height:350px;margin:0 10px 10px 0;transition:background-color .15s;vertical-align:top;width:350px;position:relative}.sky-card-small{height:250px;width:225px}.sky-card-selectable .sky-card-header,.sky-card-selectable .sky-card-content{cursor:pointer}.sky-card-selected{background-color:#f1eef6;transition:background-color .15s}.sky-card-header{align-items:center;display:flex;flex-shrink:0;margin:0;padding:10px 0 0}.sky-card-heading-left,.sky-card-heading-right{font-weight:400;max-width:34px}.sky-card-heading-left{padding-left:10px}.sky-card-heading-right{padding-right:10px}.sky-card-heading-middle{flex-grow:1;padding:0 10px;overflow:hidden}.sky-card-title{margin:0;line-height:1.428571429}.sky-card-check{flex-shrink:0;padding-right:10px}.sky-card-check .sky-check-wrapper{margin-bottom:2px}.sky-card-content{flex-grow:1;font-weight:400;margin:0;overflow:hidden}.sky-card-actions{bottom:0;flex-shrink:0;text-align:center}.sky-card-actions .sky-context-menu-btn{height:32px;width:32px}\n"], components: [{ type: i1$2.λ3, selector: "sky-checkbox", inputs: ["label", "labelledBy", "id", "disabled", "tabindex", "name", "icon", "checkboxType", "checked", "required"], outputs: ["change", "checkedChange", "disabledChange"] }], directives: [{ type: i3.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { type: i3.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i3$2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { type: i3$2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }], pipes: { "skyLibResources": i1$1.SkyLibResourcesPipe } });
|
|
1104
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyCardComponent, decorators: [{
|
|
1105
|
+
type: Component,
|
|
1106
|
+
args: [{ selector: 'sky-card', template: "<section\n class=\"sky-card sky-shadow\"\n [ngClass]=\"\n {\n 'sky-card-small': size === 'small',\n 'sky-card-selectable': selectable,\n 'sky-card-selected': selectable && selected\n }\"\n>\n <ng-content select=\"sky-inline-delete\"></ng-content>\n <header>\n <div\n *ngIf=\"selectable || showTitle\"\n class=\"sky-card-header\"\n (click)=\"contentClick()\"\n >\n <div class=\"sky-card-heading-middle\">\n <h1 *ngIf=\"showTitle\" class=\"sky-card-title sky-section-heading\">\n <ng-content select=\"sky-card-title\"></ng-content>\n </h1>\n </div>\n <div *ngIf=\"selectable\" class=\"sky-card-check\">\n <sky-checkbox\n [label]=\"'skyux_card_checkbox_label' | skyLibResources\"\n [ngModel]=\"selected\"\n (click)=\"$event.stopPropagation()\"\n (ngModelChange)=\"onCheckboxChange($event)\"\n ></sky-checkbox>\n </div>\n </div>\n </header>\n <div\n class=\"sky-card-content sky-padding-even-default\"\n (click)=\"contentClick()\"\n >\n <ng-content select=\"sky-card-content\"></ng-content>\n </div>\n <div\n class=\"sky-card-actions\"\n [hidden]=\"actionsEl.children.length === 0\"\n #actionsEl\n >\n <ng-content select=\"sky-card-actions\"></ng-content>\n </div>\n</section>\n", styles: [".sky-card{background-color:#fff;border-top:1px solid #cdcfd2;border-bottom:1px solid #cdcfd2;border-left:1px solid #cdcfd2;border-right:1px solid #cdcfd2;display:inline-flex;flex-direction:column;height:350px;margin:0 10px 10px 0;transition:background-color .15s;vertical-align:top;width:350px;position:relative}.sky-card-small{height:250px;width:225px}.sky-card-selectable .sky-card-header,.sky-card-selectable .sky-card-content{cursor:pointer}.sky-card-selected{background-color:#f1eef6;transition:background-color .15s}.sky-card-header{align-items:center;display:flex;flex-shrink:0;margin:0;padding:10px 0 0}.sky-card-heading-left,.sky-card-heading-right{font-weight:400;max-width:34px}.sky-card-heading-left{padding-left:10px}.sky-card-heading-right{padding-right:10px}.sky-card-heading-middle{flex-grow:1;padding:0 10px;overflow:hidden}.sky-card-title{margin:0;line-height:1.428571429}.sky-card-check{flex-shrink:0;padding-right:10px}.sky-card-check .sky-check-wrapper{margin-bottom:2px}.sky-card-content{flex-grow:1;font-weight:400;margin:0;overflow:hidden}.sky-card-actions{bottom:0;flex-shrink:0;text-align:center}.sky-card-actions .sky-context-menu-btn{height:32px;width:32px}\n"] }]
|
|
1107
|
+
}], propDecorators: { size: [{
|
|
1108
|
+
type: Input
|
|
1109
|
+
}], selectable: [{
|
|
1110
|
+
type: Input
|
|
1111
|
+
}], selected: [{
|
|
1112
|
+
type: Input
|
|
1113
|
+
}], selectedChange: [{
|
|
1114
|
+
type: Output
|
|
1115
|
+
}], inlineDeleteComponent: [{
|
|
1116
|
+
type: ContentChildren,
|
|
1117
|
+
args: [SkyInlineDeleteComponent]
|
|
1118
|
+
}], titleComponent: [{
|
|
1119
|
+
type: ContentChildren,
|
|
1120
|
+
args: [SkyCardTitleComponent]
|
|
1121
|
+
}] } });
|
|
1122
|
+
|
|
1123
|
+
class SkyCardModule {
|
|
1124
|
+
}
|
|
1125
|
+
SkyCardModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyCardModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
1126
|
+
SkyCardModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyCardModule, declarations: [SkyCardActionsComponent,
|
|
1127
|
+
SkyCardComponent,
|
|
1128
|
+
SkyCardContentComponent,
|
|
1129
|
+
SkyCardTitleComponent], imports: [CommonModule,
|
|
1130
|
+
FormsModule,
|
|
1131
|
+
SkyCheckboxModule,
|
|
1132
|
+
SkyI18nModule,
|
|
1133
|
+
SkyLayoutResourcesModule,
|
|
1134
|
+
SkyInlineDeleteModule], exports: [SkyCardActionsComponent,
|
|
1135
|
+
SkyCardComponent,
|
|
1136
|
+
SkyCardContentComponent,
|
|
1137
|
+
SkyCardTitleComponent] });
|
|
1138
|
+
SkyCardModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyCardModule, imports: [[
|
|
1139
|
+
CommonModule,
|
|
1140
|
+
FormsModule,
|
|
1141
|
+
SkyCheckboxModule,
|
|
1142
|
+
SkyI18nModule,
|
|
1143
|
+
SkyLayoutResourcesModule,
|
|
1144
|
+
SkyInlineDeleteModule,
|
|
1145
|
+
]] });
|
|
1146
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyCardModule, decorators: [{
|
|
1147
|
+
type: NgModule,
|
|
1148
|
+
args: [{
|
|
1149
|
+
declarations: [
|
|
1150
|
+
SkyCardActionsComponent,
|
|
1151
|
+
SkyCardComponent,
|
|
1152
|
+
SkyCardContentComponent,
|
|
1153
|
+
SkyCardTitleComponent,
|
|
1154
|
+
],
|
|
1155
|
+
imports: [
|
|
1156
|
+
CommonModule,
|
|
1157
|
+
FormsModule,
|
|
1158
|
+
SkyCheckboxModule,
|
|
1159
|
+
SkyI18nModule,
|
|
1160
|
+
SkyLayoutResourcesModule,
|
|
1161
|
+
SkyInlineDeleteModule,
|
|
1162
|
+
],
|
|
1163
|
+
exports: [
|
|
1164
|
+
SkyCardActionsComponent,
|
|
1165
|
+
SkyCardComponent,
|
|
1166
|
+
SkyCardContentComponent,
|
|
1167
|
+
SkyCardTitleComponent,
|
|
1168
|
+
],
|
|
1169
|
+
}]
|
|
1170
|
+
}] });
|
|
1171
|
+
|
|
1172
|
+
/**
|
|
1173
|
+
* Wraps the label-value pairs in the definition list.
|
|
1174
|
+
*/
|
|
1175
|
+
class SkyDefinitionListContentComponent {
|
|
1176
|
+
}
|
|
1177
|
+
SkyDefinitionListContentComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyDefinitionListContentComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
1178
|
+
SkyDefinitionListContentComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.2.7", type: SkyDefinitionListContentComponent, selector: "sky-definition-list-content", ngImport: i0, template: "<div class=\"sky-definition-list-content\">\n <ng-content></ng-content>\n</div>\n", styles: [".sky-definition-list-content{display:flex;flex-wrap:wrap;margin-bottom:5px}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
1179
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyDefinitionListContentComponent, decorators: [{
|
|
1180
|
+
type: Component,
|
|
1181
|
+
args: [{ selector: 'sky-definition-list-content', changeDetection: ChangeDetectionStrategy.OnPush, template: "<div class=\"sky-definition-list-content\">\n <ng-content></ng-content>\n</div>\n", styles: [".sky-definition-list-content{display:flex;flex-wrap:wrap;margin-bottom:5px}\n"] }]
|
|
1182
|
+
}] });
|
|
1183
|
+
|
|
1184
|
+
/**
|
|
1185
|
+
* Specifies a title for the definition list.
|
|
1186
|
+
*/
|
|
1187
|
+
class SkyDefinitionListHeadingComponent {
|
|
1188
|
+
}
|
|
1189
|
+
SkyDefinitionListHeadingComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyDefinitionListHeadingComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
1190
|
+
SkyDefinitionListHeadingComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.2.7", type: SkyDefinitionListHeadingComponent, selector: "sky-definition-list-heading", ngImport: i0, template: "<div class=\"sky-subsection-heading sky-definition-list-heading\">\n <ng-content></ng-content>\n</div>\n", styles: [".sky-definition-list-heading{margin-bottom:5px}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
1191
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyDefinitionListHeadingComponent, decorators: [{
|
|
1192
|
+
type: Component,
|
|
1193
|
+
args: [{ selector: 'sky-definition-list-heading', changeDetection: ChangeDetectionStrategy.OnPush, template: "<div class=\"sky-subsection-heading sky-definition-list-heading\">\n <ng-content></ng-content>\n</div>\n", styles: [".sky-definition-list-heading{margin-bottom:5px}\n"] }]
|
|
1194
|
+
}] });
|
|
1195
|
+
|
|
1196
|
+
/**
|
|
1197
|
+
* @internal
|
|
1198
|
+
*/
|
|
1199
|
+
class SkyDefinitionListService {
|
|
1200
|
+
constructor() {
|
|
1201
|
+
this.labelWidth = new BehaviorSubject('');
|
|
1202
|
+
this.defaultValue = new BehaviorSubject('');
|
|
1203
|
+
}
|
|
1204
|
+
}
|
|
1205
|
+
SkyDefinitionListService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyDefinitionListService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
1206
|
+
SkyDefinitionListService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyDefinitionListService });
|
|
1207
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyDefinitionListService, decorators: [{
|
|
1208
|
+
type: Injectable
|
|
1209
|
+
}] });
|
|
1210
|
+
|
|
1211
|
+
/**
|
|
1212
|
+
* Specifies the label in a label-value pair.
|
|
1213
|
+
*/
|
|
1214
|
+
class SkyDefinitionListLabelComponent {
|
|
1215
|
+
constructor(service) {
|
|
1216
|
+
this.service = service;
|
|
1217
|
+
}
|
|
1218
|
+
}
|
|
1219
|
+
SkyDefinitionListLabelComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyDefinitionListLabelComponent, deps: [{ token: SkyDefinitionListService }], target: i0.ɵɵFactoryTarget.Component });
|
|
1220
|
+
SkyDefinitionListLabelComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.2.7", type: SkyDefinitionListLabelComponent, selector: "sky-definition-list-label", ngImport: i0, template: "<div\n class=\"sky-field-label sky-definition-list-label\"\n [ngStyle]=\"{\n width: (service.labelWidth | async) || ''\n }\"\n>\n <ng-content></ng-content>\n</div>\n", styles: [":host{flex:0 0 90px}.sky-definition-list-label{margin-right:10px;word-wrap:break-word}\n"], directives: [{ type: i3.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }], pipes: { "async": i3.AsyncPipe }, changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
1221
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyDefinitionListLabelComponent, decorators: [{
|
|
1222
|
+
type: Component,
|
|
1223
|
+
args: [{ selector: 'sky-definition-list-label', changeDetection: ChangeDetectionStrategy.OnPush, template: "<div\n class=\"sky-field-label sky-definition-list-label\"\n [ngStyle]=\"{\n width: (service.labelWidth | async) || ''\n }\"\n>\n <ng-content></ng-content>\n</div>\n", styles: [":host{flex:0 0 90px}.sky-definition-list-label{margin-right:10px;word-wrap:break-word}\n"] }]
|
|
1224
|
+
}], ctorParameters: function () { return [{ type: SkyDefinitionListService }]; } });
|
|
1225
|
+
|
|
1226
|
+
/**
|
|
1227
|
+
* Specifies the value in a label-value pair.
|
|
1228
|
+
*/
|
|
1229
|
+
class SkyDefinitionListValueComponent {
|
|
1230
|
+
constructor(service) {
|
|
1231
|
+
this.service = service;
|
|
1232
|
+
}
|
|
1233
|
+
}
|
|
1234
|
+
SkyDefinitionListValueComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyDefinitionListValueComponent, deps: [{ token: SkyDefinitionListService }], target: i0.ɵɵFactoryTarget.Component });
|
|
1235
|
+
SkyDefinitionListValueComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.2.7", type: SkyDefinitionListValueComponent, selector: "sky-definition-list-value", ngImport: i0, template: "<div class=\"sky-definition-list-value\">\n <span #valueEl>\n <ng-content></ng-content>\n </span>\n <span class=\"sky-deemphasized\" *ngIf=\"!valueEl.textContent.trim()\">\n {{\n (service.defaultValue | async) ||\n ('skyux_definition_list_none_found' | skyLibResources)\n }}\n </span>\n</div>\n", styles: [":host{flex:1}\n"], directives: [{ type: i3.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }], pipes: { "async": i3.AsyncPipe, "skyLibResources": i1$1.SkyLibResourcesPipe } });
|
|
1236
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyDefinitionListValueComponent, decorators: [{
|
|
1237
|
+
type: Component,
|
|
1238
|
+
args: [{ selector: 'sky-definition-list-value', template: "<div class=\"sky-definition-list-value\">\n <span #valueEl>\n <ng-content></ng-content>\n </span>\n <span class=\"sky-deemphasized\" *ngIf=\"!valueEl.textContent.trim()\">\n {{\n (service.defaultValue | async) ||\n ('skyux_definition_list_none_found' | skyLibResources)\n }}\n </span>\n</div>\n", styles: [":host{flex:1}\n"] }]
|
|
1239
|
+
}], ctorParameters: function () { return [{ type: SkyDefinitionListService }]; } });
|
|
1240
|
+
|
|
1241
|
+
/**
|
|
1242
|
+
* Creates a definition list to display label-value pairs.
|
|
1243
|
+
*/
|
|
1244
|
+
class SkyDefinitionListComponent {
|
|
1245
|
+
constructor(service) {
|
|
1246
|
+
this.service = service;
|
|
1247
|
+
}
|
|
1248
|
+
/**
|
|
1249
|
+
* Specifies the width of the label portion of the definition list.
|
|
1250
|
+
* @default "90px"
|
|
1251
|
+
*/
|
|
1252
|
+
set labelWidth(value) {
|
|
1253
|
+
this.service.labelWidth.next(value);
|
|
1254
|
+
}
|
|
1255
|
+
/**
|
|
1256
|
+
* Specifies a default value to display when no value is provided
|
|
1257
|
+
* for a label-value pair.
|
|
1258
|
+
* @default "None found"
|
|
1259
|
+
*/
|
|
1260
|
+
set defaultValue(value) {
|
|
1261
|
+
this.service.defaultValue.next(value);
|
|
1262
|
+
}
|
|
1263
|
+
}
|
|
1264
|
+
SkyDefinitionListComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyDefinitionListComponent, deps: [{ token: SkyDefinitionListService }], target: i0.ɵɵFactoryTarget.Component });
|
|
1265
|
+
SkyDefinitionListComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.2.7", type: SkyDefinitionListComponent, selector: "sky-definition-list", inputs: { labelWidth: "labelWidth", defaultValue: "defaultValue" }, providers: [SkyDefinitionListService], ngImport: i0, template: "<div class=\"sky-definition-list\">\n <ng-content select=\"sky-definition-list-heading\"></ng-content>\n <ng-content select=\"sky-definition-list-content\"></ng-content>\n</div>\n", styles: [".sky-definition-list{margin-right:50px;margin-bottom:20px}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
1266
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyDefinitionListComponent, decorators: [{
|
|
1267
|
+
type: Component,
|
|
1268
|
+
args: [{ selector: 'sky-definition-list', providers: [SkyDefinitionListService], changeDetection: ChangeDetectionStrategy.OnPush, template: "<div class=\"sky-definition-list\">\n <ng-content select=\"sky-definition-list-heading\"></ng-content>\n <ng-content select=\"sky-definition-list-content\"></ng-content>\n</div>\n", styles: [".sky-definition-list{margin-right:50px;margin-bottom:20px}\n"] }]
|
|
1269
|
+
}], ctorParameters: function () { return [{ type: SkyDefinitionListService }]; }, propDecorators: { labelWidth: [{
|
|
1270
|
+
type: Input
|
|
1271
|
+
}], defaultValue: [{
|
|
1272
|
+
type: Input
|
|
1273
|
+
}] } });
|
|
1274
|
+
|
|
1275
|
+
class SkyDefinitionListModule {
|
|
1276
|
+
}
|
|
1277
|
+
SkyDefinitionListModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyDefinitionListModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
1278
|
+
SkyDefinitionListModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyDefinitionListModule, declarations: [SkyDefinitionListComponent,
|
|
1279
|
+
SkyDefinitionListContentComponent,
|
|
1280
|
+
SkyDefinitionListHeadingComponent,
|
|
1281
|
+
SkyDefinitionListLabelComponent,
|
|
1282
|
+
SkyDefinitionListValueComponent], imports: [CommonModule, SkyI18nModule, SkyLayoutResourcesModule], exports: [SkyDefinitionListComponent,
|
|
1283
|
+
SkyDefinitionListContentComponent,
|
|
1284
|
+
SkyDefinitionListHeadingComponent,
|
|
1285
|
+
SkyDefinitionListLabelComponent,
|
|
1286
|
+
SkyDefinitionListValueComponent] });
|
|
1287
|
+
SkyDefinitionListModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyDefinitionListModule, imports: [[CommonModule, SkyI18nModule, SkyLayoutResourcesModule]] });
|
|
1288
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyDefinitionListModule, decorators: [{
|
|
1289
|
+
type: NgModule,
|
|
1290
|
+
args: [{
|
|
1291
|
+
declarations: [
|
|
1292
|
+
SkyDefinitionListComponent,
|
|
1293
|
+
SkyDefinitionListContentComponent,
|
|
1294
|
+
SkyDefinitionListHeadingComponent,
|
|
1295
|
+
SkyDefinitionListLabelComponent,
|
|
1296
|
+
SkyDefinitionListValueComponent,
|
|
1297
|
+
],
|
|
1298
|
+
imports: [CommonModule, SkyI18nModule, SkyLayoutResourcesModule],
|
|
1299
|
+
exports: [
|
|
1300
|
+
SkyDefinitionListComponent,
|
|
1301
|
+
SkyDefinitionListContentComponent,
|
|
1302
|
+
SkyDefinitionListHeadingComponent,
|
|
1303
|
+
SkyDefinitionListLabelComponent,
|
|
1304
|
+
SkyDefinitionListValueComponent,
|
|
1305
|
+
],
|
|
1306
|
+
}]
|
|
1307
|
+
}] });
|
|
1308
|
+
|
|
1309
|
+
/**
|
|
1310
|
+
* @internal
|
|
1311
|
+
*/
|
|
1312
|
+
class SkyDescriptionListService {
|
|
1313
|
+
constructor() {
|
|
1314
|
+
this._defaultDescription = new BehaviorSubject('');
|
|
1315
|
+
}
|
|
1316
|
+
get defaultDescription() {
|
|
1317
|
+
return this._defaultDescription.asObservable();
|
|
1318
|
+
}
|
|
1319
|
+
ngOnDestroy() {
|
|
1320
|
+
this._defaultDescription.complete();
|
|
1321
|
+
}
|
|
1322
|
+
updateDefaultDescription(value) {
|
|
1323
|
+
this._defaultDescription.next(value);
|
|
1324
|
+
}
|
|
1325
|
+
}
|
|
1326
|
+
SkyDescriptionListService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyDescriptionListService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
1327
|
+
SkyDescriptionListService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyDescriptionListService });
|
|
1328
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyDescriptionListService, decorators: [{
|
|
1329
|
+
type: Injectable
|
|
1330
|
+
}] });
|
|
1331
|
+
|
|
1332
|
+
/**
|
|
1333
|
+
* Specifies the description in a term-description pair.
|
|
1334
|
+
*/
|
|
1335
|
+
class SkyDescriptionListDescriptionComponent {
|
|
1336
|
+
constructor(service, changeRef, themeSvc) {
|
|
1337
|
+
this.service = service;
|
|
1338
|
+
this.changeRef = changeRef;
|
|
1339
|
+
this.themeSvc = themeSvc;
|
|
1340
|
+
this.ngUnsubscribe = new Subject();
|
|
1341
|
+
}
|
|
1342
|
+
ngOnInit() {
|
|
1343
|
+
/* istanbul ignore else */
|
|
1344
|
+
if (this.themeSvc) {
|
|
1345
|
+
this.themeSvc.settingsChange
|
|
1346
|
+
.pipe(takeUntil(this.ngUnsubscribe))
|
|
1347
|
+
.subscribe((themeSettings) => {
|
|
1348
|
+
this.themeName = themeSettings.currentSettings.theme.name;
|
|
1349
|
+
this.changeRef.markForCheck();
|
|
1350
|
+
});
|
|
1351
|
+
}
|
|
1352
|
+
}
|
|
1353
|
+
ngOnDestroy() {
|
|
1354
|
+
this.ngUnsubscribe.next();
|
|
1355
|
+
this.ngUnsubscribe.complete();
|
|
1356
|
+
}
|
|
1357
|
+
}
|
|
1358
|
+
SkyDescriptionListDescriptionComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyDescriptionListDescriptionComponent, deps: [{ token: SkyDescriptionListService }, { token: i0.ChangeDetectorRef }, { token: i3$1.SkyThemeService }], target: i0.ɵɵFactoryTarget.Component });
|
|
1359
|
+
SkyDescriptionListDescriptionComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.2.7", type: SkyDescriptionListDescriptionComponent, selector: "sky-description-list-description", viewQueries: [{ propertyName: "templateRef", first: true, predicate: ["descriptionTemplateRef"], descendants: true, read: TemplateRef, static: true }], ngImport: i0, template: "<ng-template #descriptionTemplateRef>\n <span #valueEl>\n <ng-content></ng-content>\n </span>\n <span\n *ngIf=\"!valueEl.textContent.trim()\"\n data-sky-id=\"sky-description-list-default-value\"\n [skyThemeClass]=\"{\n 'sky-font-deemphasized': 'modern',\n 'sky-deemphasized': 'default'\n }\"\n >\n {{\n (service.defaultDescription | async) ||\n ('skyux_description_list_none_found' | skyLibResources)\n }}\n </span>\n</ng-template>\n", directives: [{ type: i3.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i3$1.λ2, selector: "[skyThemeClass]", inputs: ["class", "skyThemeClass"] }], pipes: { "async": i3.AsyncPipe, "skyLibResources": i1$1.SkyLibResourcesPipe }, changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
1360
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyDescriptionListDescriptionComponent, decorators: [{
|
|
1361
|
+
type: Component,
|
|
1362
|
+
args: [{ selector: 'sky-description-list-description', changeDetection: ChangeDetectionStrategy.OnPush, template: "<ng-template #descriptionTemplateRef>\n <span #valueEl>\n <ng-content></ng-content>\n </span>\n <span\n *ngIf=\"!valueEl.textContent.trim()\"\n data-sky-id=\"sky-description-list-default-value\"\n [skyThemeClass]=\"{\n 'sky-font-deemphasized': 'modern',\n 'sky-deemphasized': 'default'\n }\"\n >\n {{\n (service.defaultDescription | async) ||\n ('skyux_description_list_none_found' | skyLibResources)\n }}\n </span>\n</ng-template>\n" }]
|
|
1363
|
+
}], ctorParameters: function () { return [{ type: SkyDescriptionListService }, { type: i0.ChangeDetectorRef }, { type: i3$1.SkyThemeService }]; }, propDecorators: { templateRef: [{
|
|
1364
|
+
type: ViewChild,
|
|
1365
|
+
args: ['descriptionTemplateRef', {
|
|
1366
|
+
read: TemplateRef,
|
|
1367
|
+
static: true,
|
|
1368
|
+
}]
|
|
1369
|
+
}] } });
|
|
1370
|
+
|
|
1371
|
+
/**
|
|
1372
|
+
* Specifies the term in a term-description pair.
|
|
1373
|
+
*/
|
|
1374
|
+
class SkyDescriptionListTermComponent {
|
|
1375
|
+
}
|
|
1376
|
+
SkyDescriptionListTermComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyDescriptionListTermComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
1377
|
+
SkyDescriptionListTermComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.2.7", type: SkyDescriptionListTermComponent, selector: "sky-description-list-term", viewQueries: [{ propertyName: "templateRef", first: true, predicate: ["termTemplateRef"], descendants: true, read: TemplateRef, static: true }], ngImport: i0, template: "<ng-template #termTemplateRef>\n <ng-content></ng-content>\n</ng-template>\n", changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
1378
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyDescriptionListTermComponent, decorators: [{
|
|
1379
|
+
type: Component,
|
|
1380
|
+
args: [{ selector: 'sky-description-list-term', changeDetection: ChangeDetectionStrategy.OnPush, template: "<ng-template #termTemplateRef>\n <ng-content></ng-content>\n</ng-template>\n" }]
|
|
1381
|
+
}], propDecorators: { templateRef: [{
|
|
1382
|
+
type: ViewChild,
|
|
1383
|
+
args: ['termTemplateRef', {
|
|
1384
|
+
read: TemplateRef,
|
|
1385
|
+
static: true,
|
|
1386
|
+
}]
|
|
1387
|
+
}] } });
|
|
1388
|
+
|
|
1389
|
+
/**
|
|
1390
|
+
* Wraps the term-description pairs in the description list.
|
|
1391
|
+
*/
|
|
1392
|
+
class SkyDescriptionListContentComponent {
|
|
1393
|
+
}
|
|
1394
|
+
SkyDescriptionListContentComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyDescriptionListContentComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
1395
|
+
SkyDescriptionListContentComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.2.7", type: SkyDescriptionListContentComponent, selector: "sky-description-list-content", queries: [{ propertyName: "termComponents", predicate: SkyDescriptionListTermComponent }, { propertyName: "descriptionComponents", predicate: SkyDescriptionListDescriptionComponent }], ngImport: i0, template: "<ng-content></ng-content>\n" });
|
|
1396
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyDescriptionListContentComponent, decorators: [{
|
|
1397
|
+
type: Component,
|
|
1398
|
+
args: [{ selector: 'sky-description-list-content', template: "<ng-content></ng-content>\n" }]
|
|
1399
|
+
}], propDecorators: { termComponents: [{
|
|
1400
|
+
type: ContentChildren,
|
|
1401
|
+
args: [SkyDescriptionListTermComponent]
|
|
1402
|
+
}], descriptionComponents: [{
|
|
1403
|
+
type: ContentChildren,
|
|
1404
|
+
args: [SkyDescriptionListDescriptionComponent]
|
|
1405
|
+
}] } });
|
|
1406
|
+
|
|
1407
|
+
/**
|
|
1408
|
+
* @internal
|
|
1409
|
+
*/
|
|
1410
|
+
class SkyDescriptionListAdapterService {
|
|
1411
|
+
constructor(rendererFactory) {
|
|
1412
|
+
this.renderer = rendererFactory.createRenderer(undefined, undefined);
|
|
1413
|
+
}
|
|
1414
|
+
getWidth(elementRef) {
|
|
1415
|
+
return elementRef.nativeElement.clientWidth;
|
|
1416
|
+
}
|
|
1417
|
+
setResponsiveClass(element) {
|
|
1418
|
+
const nativeEl = element.nativeElement;
|
|
1419
|
+
const width = this.getWidth(element);
|
|
1420
|
+
const className = this.getResponsiveClassName(width);
|
|
1421
|
+
this.renderer.removeClass(nativeEl, 'sky-responsive-container-xs');
|
|
1422
|
+
this.renderer.removeClass(nativeEl, 'sky-responsive-container-sm');
|
|
1423
|
+
this.renderer.removeClass(nativeEl, 'sky-responsive-container-md');
|
|
1424
|
+
this.renderer.addClass(nativeEl, className);
|
|
1425
|
+
}
|
|
1426
|
+
getResponsiveClassName(width) {
|
|
1427
|
+
const xsBreakpointMaxPixels = 479;
|
|
1428
|
+
const smBreakpointMinPixels = 480;
|
|
1429
|
+
const smBreakpointMaxPixels = 767;
|
|
1430
|
+
if (width <= xsBreakpointMaxPixels) {
|
|
1431
|
+
return 'sky-responsive-container-xs';
|
|
1432
|
+
}
|
|
1433
|
+
else if (width >= smBreakpointMinPixels &&
|
|
1434
|
+
width <= smBreakpointMaxPixels) {
|
|
1435
|
+
return 'sky-responsive-container-sm';
|
|
1436
|
+
}
|
|
1437
|
+
else {
|
|
1438
|
+
return 'sky-responsive-container-md';
|
|
1439
|
+
}
|
|
1440
|
+
}
|
|
1441
|
+
}
|
|
1442
|
+
SkyDescriptionListAdapterService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyDescriptionListAdapterService, deps: [{ token: i0.RendererFactory2 }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
1443
|
+
SkyDescriptionListAdapterService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyDescriptionListAdapterService });
|
|
1444
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyDescriptionListAdapterService, decorators: [{
|
|
1445
|
+
type: Injectable
|
|
1446
|
+
}], ctorParameters: function () { return [{ type: i0.RendererFactory2 }]; } });
|
|
1447
|
+
|
|
1448
|
+
/**
|
|
1449
|
+
* Creates a description list to display term-description pairs.
|
|
1450
|
+
*/
|
|
1451
|
+
class SkyDescriptionListComponent {
|
|
1452
|
+
constructor(adapterService, changeDetector, descriptionListService, mutationSvc) {
|
|
1453
|
+
this.adapterService = adapterService;
|
|
1454
|
+
this.changeDetector = changeDetector;
|
|
1455
|
+
this.descriptionListService = descriptionListService;
|
|
1456
|
+
this.mutationSvc = mutationSvc;
|
|
1457
|
+
this.ngUnsubscribe = new Subject();
|
|
1458
|
+
}
|
|
1459
|
+
/**
|
|
1460
|
+
* Specifies a default description to display when no description is provided
|
|
1461
|
+
* for a term-description pair.
|
|
1462
|
+
* @default "None found"
|
|
1463
|
+
*/
|
|
1464
|
+
set defaultDescription(value) {
|
|
1465
|
+
this.descriptionListService.updateDefaultDescription(value);
|
|
1466
|
+
}
|
|
1467
|
+
/**
|
|
1468
|
+
* Specifies how to display term-description pairs within the description list.
|
|
1469
|
+
* Options include `"horizontal"`, `"longDescription"`, and `"vertical"`.
|
|
1470
|
+
* @default "vertical"
|
|
1471
|
+
*/
|
|
1472
|
+
set mode(value) {
|
|
1473
|
+
this._mode = value;
|
|
1474
|
+
}
|
|
1475
|
+
get mode() {
|
|
1476
|
+
return this._mode || 'vertical';
|
|
1477
|
+
}
|
|
1478
|
+
ngAfterContentInit() {
|
|
1479
|
+
// Wait for all content to render before detecting parent width.
|
|
1480
|
+
setTimeout(() => {
|
|
1481
|
+
this.updateResponsiveClass();
|
|
1482
|
+
});
|
|
1483
|
+
this.contentComponents.changes
|
|
1484
|
+
.pipe(takeUntil(this.ngUnsubscribe))
|
|
1485
|
+
.subscribe(() => {
|
|
1486
|
+
this.changeDetector.markForCheck();
|
|
1487
|
+
});
|
|
1488
|
+
}
|
|
1489
|
+
ngAfterViewInit() {
|
|
1490
|
+
this.contentObserver = this.mutationSvc.create(() => {
|
|
1491
|
+
this.changeDetector.markForCheck();
|
|
1492
|
+
});
|
|
1493
|
+
this.contentObserver.observe(this.elementRef.nativeElement, {
|
|
1494
|
+
childList: true,
|
|
1495
|
+
characterData: true,
|
|
1496
|
+
subtree: true,
|
|
1497
|
+
});
|
|
1498
|
+
}
|
|
1499
|
+
ngOnDestroy() {
|
|
1500
|
+
this.ngUnsubscribe.next();
|
|
1501
|
+
this.ngUnsubscribe.complete();
|
|
1502
|
+
this.contentObserver.disconnect();
|
|
1503
|
+
}
|
|
1504
|
+
onWindowResize() {
|
|
1505
|
+
this.updateResponsiveClass();
|
|
1506
|
+
}
|
|
1507
|
+
updateResponsiveClass() {
|
|
1508
|
+
this.adapterService.setResponsiveClass(this.elementRef);
|
|
1509
|
+
this.changeDetector.markForCheck();
|
|
1510
|
+
}
|
|
1511
|
+
}
|
|
1512
|
+
SkyDescriptionListComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyDescriptionListComponent, deps: [{ token: SkyDescriptionListAdapterService }, { token: i0.ChangeDetectorRef }, { token: SkyDescriptionListService }, { token: i1.MutationObserverService }], target: i0.ɵɵFactoryTarget.Component });
|
|
1513
|
+
SkyDescriptionListComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.2.7", type: SkyDescriptionListComponent, selector: "sky-description-list", inputs: { defaultDescription: "defaultDescription", listItemWidth: "listItemWidth", mode: "mode" }, host: { listeners: { "window:resize": "onWindowResize()" } }, providers: [SkyDescriptionListAdapterService, SkyDescriptionListService], queries: [{ propertyName: "contentComponents", predicate: SkyDescriptionListContentComponent }], viewQueries: [{ propertyName: "elementRef", first: true, predicate: ["descriptionListElement"], descendants: true, read: ElementRef, static: true }], ngImport: i0, template: "<dl\n class=\"sky-description-list\"\n [ngClass]=\"{\n 'sky-description-list-long-description-mode': mode === 'longDescription',\n 'sky-description-list-vertical-mode': mode === 'vertical',\n 'sky-description-list-horizontal-mode': mode === 'horizontal'\n }\"\n #descriptionListElement\n>\n <!--\n Wrapping div is for horizontal flexing. Also injecting children's templateRef directly\n to avoid adding non-semantic HTML tags to DOM\n -->\n <div\n *ngFor=\"let contentComponent of contentComponents\"\n class=\"sky-description-list-content\"\n [style.width]=\"mode === 'horizontal' ? listItemWidth : ''\"\n >\n <dt *ngFor=\"let termComponent of contentComponent?.termComponents\">\n <ng-container\n *ngTemplateOutlet=\"termComponent.templateRef\"\n ></ng-container>\n </dt>\n <dd\n *ngFor=\"\n let descriptionComponent of contentComponent?.descriptionComponents\n \"\n >\n <ng-container\n *ngTemplateOutlet=\"descriptionComponent.templateRef\"\n ></ng-container>\n </dd>\n </div>\n</dl>\n", styles: [".sky-description-list{margin:0;padding:0}.sky-description-list dt{color:#686c73;font-size:14px;font-weight:400;margin:0 0 3px;padding:0}.sky-description-list dd{margin:0;padding:0}.sky-description-list.sky-description-list-vertical-mode .sky-description-list-content{margin:0 0 15px;width:auto}.sky-description-list.sky-description-list-horizontal-mode{display:flex;flex-wrap:wrap}.sky-description-list.sky-description-list-horizontal-mode .sky-description-list-content{margin:0 0 15px;padding:0 60px 0 0;min-width:100px;width:auto}.sky-description-list.sky-description-list-horizontal-mode.sky-responsive-container-xs .sky-description-list-content,.sky-description-list.sky-description-list-horizontal-mode.sky-responsive-container-sm .sky-description-list-content{width:50%}.sky-description-list.sky-description-list-long-description-mode .sky-description-list-content{display:flex}.sky-description-list.sky-description-list-long-description-mode .sky-description-list-content:not(:last-child){margin:0 0 10px}.sky-description-list.sky-description-list-long-description-mode .sky-description-list-content dt{color:#212327;font-size:16px;font-weight:600;margin:0 20px 0 0;width:25%;word-break:break-word}.sky-description-list.sky-description-list-long-description-mode .sky-description-list-content dd{flex:1}.sky-description-list.sky-description-list-long-description-mode.sky-responsive-container-xs .sky-description-list-content{flex-direction:column}.sky-description-list.sky-description-list-long-description-mode.sky-responsive-container-xs .sky-description-list-content dt{margin:0 0 3px;width:100%}.sky-description-list.sky-description-list-long-description-mode.sky-responsive-container-xs .sky-description-list-content dd{margin:0 0 10px}:host-context(.sky-theme-modern) .sky-description-list.sky-description-list-vertical-mode .sky-description-list-content{margin:0 0 20px}:host-context(.sky-theme-modern) .sky-description-list.sky-description-list-vertical-mode dt{color:#686c73;font-size:14px;font-weight:400}:host-context(.sky-theme-modern) .sky-description-list.sky-description-list-vertical-mode dd{font-size:16px;font-weight:400}:host-context(.sky-theme-modern) .sky-description-list.sky-description-list-horizontal-mode{margin:0 0 -20px}:host-context(.sky-theme-modern) .sky-description-list.sky-description-list-horizontal-mode .sky-description-list-content{margin:0 0 20px}:host-context(.sky-theme-modern) .sky-description-list.sky-description-list-long-description-mode dt{color:inherit;font-weight:700;font-size:inherit}:host-context(.sky-theme-modern) .sky-description-list.sky-description-list-long-description-mode dd{font-size:16px;font-weight:400}:host-context(.sky-theme-modern) .sky-description-list.sky-description-list-long-description-mode.sky-responsive-container-xs dt{margin:0 0 5px}:host-context(.sky-theme-modern) .sky-description-list.sky-description-list-long-description-mode.sky-responsive-container-xs dd{margin:0 0 20px}.sky-theme-modern .sky-description-list.sky-description-list-vertical-mode .sky-description-list-content{margin:0 0 20px}.sky-theme-modern .sky-description-list.sky-description-list-vertical-mode dt{color:#686c73;font-size:14px;font-weight:400}.sky-theme-modern .sky-description-list.sky-description-list-vertical-mode dd{font-size:16px;font-weight:400}.sky-theme-modern .sky-description-list.sky-description-list-horizontal-mode{margin:0 0 -20px}.sky-theme-modern .sky-description-list.sky-description-list-horizontal-mode .sky-description-list-content{margin:0 0 20px}.sky-theme-modern .sky-description-list.sky-description-list-long-description-mode dt{color:inherit;font-weight:700;font-size:inherit}.sky-theme-modern .sky-description-list.sky-description-list-long-description-mode dd{font-size:16px;font-weight:400}.sky-theme-modern .sky-description-list.sky-description-list-long-description-mode.sky-responsive-container-xs dt{margin:0 0 5px}.sky-theme-modern .sky-description-list.sky-description-list-long-description-mode.sky-responsive-container-xs dd{margin:0 0 20px}\n"], directives: [{ type: i3.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { type: i3.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i3.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
1514
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyDescriptionListComponent, decorators: [{
|
|
1515
|
+
type: Component,
|
|
1516
|
+
args: [{ selector: 'sky-description-list', providers: [SkyDescriptionListAdapterService, SkyDescriptionListService], changeDetection: ChangeDetectionStrategy.OnPush, template: "<dl\n class=\"sky-description-list\"\n [ngClass]=\"{\n 'sky-description-list-long-description-mode': mode === 'longDescription',\n 'sky-description-list-vertical-mode': mode === 'vertical',\n 'sky-description-list-horizontal-mode': mode === 'horizontal'\n }\"\n #descriptionListElement\n>\n <!--\n Wrapping div is for horizontal flexing. Also injecting children's templateRef directly\n to avoid adding non-semantic HTML tags to DOM\n -->\n <div\n *ngFor=\"let contentComponent of contentComponents\"\n class=\"sky-description-list-content\"\n [style.width]=\"mode === 'horizontal' ? listItemWidth : ''\"\n >\n <dt *ngFor=\"let termComponent of contentComponent?.termComponents\">\n <ng-container\n *ngTemplateOutlet=\"termComponent.templateRef\"\n ></ng-container>\n </dt>\n <dd\n *ngFor=\"\n let descriptionComponent of contentComponent?.descriptionComponents\n \"\n >\n <ng-container\n *ngTemplateOutlet=\"descriptionComponent.templateRef\"\n ></ng-container>\n </dd>\n </div>\n</dl>\n", styles: [".sky-description-list{margin:0;padding:0}.sky-description-list dt{color:#686c73;font-size:14px;font-weight:400;margin:0 0 3px;padding:0}.sky-description-list dd{margin:0;padding:0}.sky-description-list.sky-description-list-vertical-mode .sky-description-list-content{margin:0 0 15px;width:auto}.sky-description-list.sky-description-list-horizontal-mode{display:flex;flex-wrap:wrap}.sky-description-list.sky-description-list-horizontal-mode .sky-description-list-content{margin:0 0 15px;padding:0 60px 0 0;min-width:100px;width:auto}.sky-description-list.sky-description-list-horizontal-mode.sky-responsive-container-xs .sky-description-list-content,.sky-description-list.sky-description-list-horizontal-mode.sky-responsive-container-sm .sky-description-list-content{width:50%}.sky-description-list.sky-description-list-long-description-mode .sky-description-list-content{display:flex}.sky-description-list.sky-description-list-long-description-mode .sky-description-list-content:not(:last-child){margin:0 0 10px}.sky-description-list.sky-description-list-long-description-mode .sky-description-list-content dt{color:#212327;font-size:16px;font-weight:600;margin:0 20px 0 0;width:25%;word-break:break-word}.sky-description-list.sky-description-list-long-description-mode .sky-description-list-content dd{flex:1}.sky-description-list.sky-description-list-long-description-mode.sky-responsive-container-xs .sky-description-list-content{flex-direction:column}.sky-description-list.sky-description-list-long-description-mode.sky-responsive-container-xs .sky-description-list-content dt{margin:0 0 3px;width:100%}.sky-description-list.sky-description-list-long-description-mode.sky-responsive-container-xs .sky-description-list-content dd{margin:0 0 10px}:host-context(.sky-theme-modern) .sky-description-list.sky-description-list-vertical-mode .sky-description-list-content{margin:0 0 20px}:host-context(.sky-theme-modern) .sky-description-list.sky-description-list-vertical-mode dt{color:#686c73;font-size:14px;font-weight:400}:host-context(.sky-theme-modern) .sky-description-list.sky-description-list-vertical-mode dd{font-size:16px;font-weight:400}:host-context(.sky-theme-modern) .sky-description-list.sky-description-list-horizontal-mode{margin:0 0 -20px}:host-context(.sky-theme-modern) .sky-description-list.sky-description-list-horizontal-mode .sky-description-list-content{margin:0 0 20px}:host-context(.sky-theme-modern) .sky-description-list.sky-description-list-long-description-mode dt{color:inherit;font-weight:700;font-size:inherit}:host-context(.sky-theme-modern) .sky-description-list.sky-description-list-long-description-mode dd{font-size:16px;font-weight:400}:host-context(.sky-theme-modern) .sky-description-list.sky-description-list-long-description-mode.sky-responsive-container-xs dt{margin:0 0 5px}:host-context(.sky-theme-modern) .sky-description-list.sky-description-list-long-description-mode.sky-responsive-container-xs dd{margin:0 0 20px}.sky-theme-modern .sky-description-list.sky-description-list-vertical-mode .sky-description-list-content{margin:0 0 20px}.sky-theme-modern .sky-description-list.sky-description-list-vertical-mode dt{color:#686c73;font-size:14px;font-weight:400}.sky-theme-modern .sky-description-list.sky-description-list-vertical-mode dd{font-size:16px;font-weight:400}.sky-theme-modern .sky-description-list.sky-description-list-horizontal-mode{margin:0 0 -20px}.sky-theme-modern .sky-description-list.sky-description-list-horizontal-mode .sky-description-list-content{margin:0 0 20px}.sky-theme-modern .sky-description-list.sky-description-list-long-description-mode dt{color:inherit;font-weight:700;font-size:inherit}.sky-theme-modern .sky-description-list.sky-description-list-long-description-mode dd{font-size:16px;font-weight:400}.sky-theme-modern .sky-description-list.sky-description-list-long-description-mode.sky-responsive-container-xs dt{margin:0 0 5px}.sky-theme-modern .sky-description-list.sky-description-list-long-description-mode.sky-responsive-container-xs dd{margin:0 0 20px}\n"] }]
|
|
1517
|
+
}], ctorParameters: function () { return [{ type: SkyDescriptionListAdapterService }, { type: i0.ChangeDetectorRef }, { type: SkyDescriptionListService }, { type: i1.MutationObserverService }]; }, propDecorators: { defaultDescription: [{
|
|
1518
|
+
type: Input
|
|
1519
|
+
}], listItemWidth: [{
|
|
1520
|
+
type: Input
|
|
1521
|
+
}], mode: [{
|
|
1522
|
+
type: Input
|
|
1523
|
+
}], contentComponents: [{
|
|
1524
|
+
type: ContentChildren,
|
|
1525
|
+
args: [SkyDescriptionListContentComponent]
|
|
1526
|
+
}], elementRef: [{
|
|
1527
|
+
type: ViewChild,
|
|
1528
|
+
args: ['descriptionListElement', {
|
|
1529
|
+
read: ElementRef,
|
|
1530
|
+
static: true,
|
|
1531
|
+
}]
|
|
1532
|
+
}], onWindowResize: [{
|
|
1533
|
+
type: HostListener,
|
|
1534
|
+
args: ['window:resize']
|
|
1535
|
+
}] } });
|
|
1536
|
+
|
|
1537
|
+
class SkyDescriptionListModule {
|
|
1538
|
+
}
|
|
1539
|
+
SkyDescriptionListModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyDescriptionListModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
1540
|
+
SkyDescriptionListModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyDescriptionListModule, declarations: [SkyDescriptionListComponent,
|
|
1541
|
+
SkyDescriptionListContentComponent,
|
|
1542
|
+
SkyDescriptionListTermComponent,
|
|
1543
|
+
SkyDescriptionListDescriptionComponent], imports: [CommonModule,
|
|
1544
|
+
SkyI18nModule,
|
|
1545
|
+
SkyLayoutResourcesModule,
|
|
1546
|
+
SkyThemeModule], exports: [SkyDescriptionListComponent,
|
|
1547
|
+
SkyDescriptionListContentComponent,
|
|
1548
|
+
SkyDescriptionListTermComponent,
|
|
1549
|
+
SkyDescriptionListDescriptionComponent] });
|
|
1550
|
+
SkyDescriptionListModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyDescriptionListModule, imports: [[
|
|
1551
|
+
CommonModule,
|
|
1552
|
+
SkyI18nModule,
|
|
1553
|
+
SkyLayoutResourcesModule,
|
|
1554
|
+
SkyThemeModule,
|
|
1555
|
+
]] });
|
|
1556
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyDescriptionListModule, decorators: [{
|
|
1557
|
+
type: NgModule,
|
|
1558
|
+
args: [{
|
|
1559
|
+
declarations: [
|
|
1560
|
+
SkyDescriptionListComponent,
|
|
1561
|
+
SkyDescriptionListContentComponent,
|
|
1562
|
+
SkyDescriptionListTermComponent,
|
|
1563
|
+
SkyDescriptionListDescriptionComponent,
|
|
1564
|
+
],
|
|
1565
|
+
imports: [
|
|
1566
|
+
CommonModule,
|
|
1567
|
+
SkyI18nModule,
|
|
1568
|
+
SkyLayoutResourcesModule,
|
|
1569
|
+
SkyThemeModule,
|
|
1570
|
+
],
|
|
1571
|
+
exports: [
|
|
1572
|
+
SkyDescriptionListComponent,
|
|
1573
|
+
SkyDescriptionListContentComponent,
|
|
1574
|
+
SkyDescriptionListTermComponent,
|
|
1575
|
+
SkyDescriptionListDescriptionComponent,
|
|
1576
|
+
],
|
|
1577
|
+
}]
|
|
1578
|
+
}] });
|
|
1579
|
+
|
|
1580
|
+
/**
|
|
1581
|
+
* @deprecated Use `SkyDescriptionListModeType` instead.
|
|
1582
|
+
* @internal
|
|
1583
|
+
* Specifies how to display the term-description pairs within a description list.
|
|
1584
|
+
*/
|
|
1585
|
+
var SkyDescriptionListMode;
|
|
1586
|
+
(function (SkyDescriptionListMode) {
|
|
1587
|
+
/**
|
|
1588
|
+
* Displays term-description pairs side by side in a horizontal list.
|
|
1589
|
+
* This mode provides a responsive layout.
|
|
1590
|
+
*/
|
|
1591
|
+
SkyDescriptionListMode["horizontal"] = "horizontal";
|
|
1592
|
+
/**
|
|
1593
|
+
* Displays terms and descriptions side by side with the term on the left and the description
|
|
1594
|
+
* on the right. This mode includes room for long descriptions and uses a responsive layout
|
|
1595
|
+
* that stacks term-description pairs vertically.
|
|
1596
|
+
*/
|
|
1597
|
+
SkyDescriptionListMode["longDescription"] = "longDescription";
|
|
1598
|
+
/**
|
|
1599
|
+
* Displays term-description pairs in a vertical list.
|
|
1600
|
+
*/
|
|
1601
|
+
SkyDescriptionListMode["vertical"] = "vertical";
|
|
1602
|
+
})(SkyDescriptionListMode || (SkyDescriptionListMode = {}));
|
|
1603
|
+
|
|
1604
|
+
/**
|
|
1605
|
+
* @deprecated Use `SkyFluidGridGutterSizeType` instead.
|
|
1606
|
+
* @internal
|
|
1607
|
+
*/
|
|
1608
|
+
var SkyFluidGridGutterSize;
|
|
1609
|
+
(function (SkyFluidGridGutterSize) {
|
|
1610
|
+
/**
|
|
1611
|
+
* Specifies a small gutter.
|
|
1612
|
+
*/
|
|
1613
|
+
SkyFluidGridGutterSize[SkyFluidGridGutterSize["Small"] = 0] = "Small";
|
|
1614
|
+
/**
|
|
1615
|
+
* Specifies a medium gutter.
|
|
1616
|
+
*/
|
|
1617
|
+
SkyFluidGridGutterSize[SkyFluidGridGutterSize["Medium"] = 1] = "Medium";
|
|
1618
|
+
/**
|
|
1619
|
+
* Specifies a large gutter.
|
|
1620
|
+
*/
|
|
1621
|
+
SkyFluidGridGutterSize[SkyFluidGridGutterSize["Large"] = 2] = "Large";
|
|
1622
|
+
})(SkyFluidGridGutterSize || (SkyFluidGridGutterSize = {}));
|
|
1623
|
+
|
|
1624
|
+
/**
|
|
1625
|
+
* Displays a column within a row of the fluid grid.
|
|
1626
|
+
*/
|
|
1627
|
+
class SkyColumnComponent {
|
|
1628
|
+
ngOnChanges(changes) {
|
|
1629
|
+
/* istanbul ignore else */
|
|
1630
|
+
if (changes.screenXSmall ||
|
|
1631
|
+
changes.screenSmall ||
|
|
1632
|
+
changes.screenMedium ||
|
|
1633
|
+
changes.screenLarge) {
|
|
1634
|
+
this.classnames = this.getClassNames();
|
|
1635
|
+
}
|
|
1636
|
+
}
|
|
1637
|
+
getClassNames() {
|
|
1638
|
+
const classnames = ['sky-column'];
|
|
1639
|
+
if (this.screenXSmall) {
|
|
1640
|
+
classnames.push(`sky-column-xs-${this.screenXSmall}`);
|
|
1641
|
+
}
|
|
1642
|
+
if (this.screenSmall) {
|
|
1643
|
+
classnames.push(`sky-column-sm-${this.screenSmall}`);
|
|
1644
|
+
}
|
|
1645
|
+
if (this.screenMedium) {
|
|
1646
|
+
classnames.push(`sky-column-md-${this.screenMedium}`);
|
|
1647
|
+
}
|
|
1648
|
+
if (this.screenLarge) {
|
|
1649
|
+
classnames.push(`sky-column-lg-${this.screenLarge}`);
|
|
1650
|
+
}
|
|
1651
|
+
return classnames.join(' ');
|
|
1652
|
+
}
|
|
1653
|
+
ngOnInit() {
|
|
1654
|
+
this.classnames = this.getClassNames();
|
|
1655
|
+
}
|
|
1656
|
+
}
|
|
1657
|
+
SkyColumnComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyColumnComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
1658
|
+
SkyColumnComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.2.7", type: SkyColumnComponent, selector: "sky-column", inputs: { screenXSmall: "screenXSmall", screenSmall: "screenSmall", screenMedium: "screenMedium", screenLarge: "screenLarge" }, host: { properties: { "class": "this.classnames" } }, usesOnChanges: true, ngImport: i0, template: "<ng-content></ng-content>\n", styles: ["sky-column.sky-column{padding-right:15px;padding-left:15px;width:100%;min-height:1px}.sky-theme-modern sky-column.sky-column{padding-right:30px;padding-left:30px}.sky-fluid-grid-gutter-size-small sky-column.sky-column{padding-right:5px;padding-left:5px}.sky-fluid-grid-gutter-size-medium sky-column.sky-column{padding-right:10px;padding-left:10px}.sky-theme-modern .sky-fluid-grid-gutter-size-small sky-column.sky-column{padding-right:10px;padding-left:10px}.sky-theme-modern .sky-fluid-grid-gutter-size-medium sky-column.sky-column{padding-right:15px;padding-left:15px}sky-column.sky-column-xs-1{width:calc(1 / 12 * 100%)}sky-column.sky-column-xs-2{width:calc(2 / 12 * 100%)}sky-column.sky-column-xs-3{width:25%}sky-column.sky-column-xs-4{width:calc(4 / 12 * 100%)}sky-column.sky-column-xs-5{width:calc(5 / 12 * 100%)}sky-column.sky-column-xs-6{width:50%}sky-column.sky-column-xs-7{width:calc(7 / 12 * 100%)}sky-column.sky-column-xs-8{width:calc(8 / 12 * 100%)}sky-column.sky-column-xs-9{width:75%}sky-column.sky-column-xs-10{width:calc(10 / 12 * 100%)}sky-column.sky-column-xs-11{width:calc(11 / 12 * 100%)}sky-column.sky-column-xs-12{width:100%}sky-column:not([class*=sky-column-xs-]){width:100%}.sky-responsive-container-xs sky-column.sky-column-xs-1,.sky-responsive-container-sm sky-column.sky-column-xs-1,.sky-responsive-container-md sky-column.sky-column-xs-1,.sky-responsive-container-lg sky-column.sky-column-xs-1{width:calc(1 / 12 * 100%)}.sky-responsive-container-xs sky-column.sky-column-xs-2,.sky-responsive-container-sm sky-column.sky-column-xs-2,.sky-responsive-container-md sky-column.sky-column-xs-2,.sky-responsive-container-lg sky-column.sky-column-xs-2{width:calc(2 / 12 * 100%)}.sky-responsive-container-xs sky-column.sky-column-xs-3,.sky-responsive-container-sm sky-column.sky-column-xs-3,.sky-responsive-container-md sky-column.sky-column-xs-3,.sky-responsive-container-lg sky-column.sky-column-xs-3{width:25%}.sky-responsive-container-xs sky-column.sky-column-xs-4,.sky-responsive-container-sm sky-column.sky-column-xs-4,.sky-responsive-container-md sky-column.sky-column-xs-4,.sky-responsive-container-lg sky-column.sky-column-xs-4{width:calc(4 / 12 * 100%)}.sky-responsive-container-xs sky-column.sky-column-xs-5,.sky-responsive-container-sm sky-column.sky-column-xs-5,.sky-responsive-container-md sky-column.sky-column-xs-5,.sky-responsive-container-lg sky-column.sky-column-xs-5{width:calc(5 / 12 * 100%)}.sky-responsive-container-xs sky-column.sky-column-xs-6,.sky-responsive-container-sm sky-column.sky-column-xs-6,.sky-responsive-container-md sky-column.sky-column-xs-6,.sky-responsive-container-lg sky-column.sky-column-xs-6{width:50%}.sky-responsive-container-xs sky-column.sky-column-xs-7,.sky-responsive-container-sm sky-column.sky-column-xs-7,.sky-responsive-container-md sky-column.sky-column-xs-7,.sky-responsive-container-lg sky-column.sky-column-xs-7{width:calc(7 / 12 * 100%)}.sky-responsive-container-xs sky-column.sky-column-xs-8,.sky-responsive-container-sm sky-column.sky-column-xs-8,.sky-responsive-container-md sky-column.sky-column-xs-8,.sky-responsive-container-lg sky-column.sky-column-xs-8{width:calc(8 / 12 * 100%)}.sky-responsive-container-xs sky-column.sky-column-xs-9,.sky-responsive-container-sm sky-column.sky-column-xs-9,.sky-responsive-container-md sky-column.sky-column-xs-9,.sky-responsive-container-lg sky-column.sky-column-xs-9{width:75%}.sky-responsive-container-xs sky-column.sky-column-xs-10,.sky-responsive-container-sm sky-column.sky-column-xs-10,.sky-responsive-container-md sky-column.sky-column-xs-10,.sky-responsive-container-lg sky-column.sky-column-xs-10{width:calc(10 / 12 * 100%)}.sky-responsive-container-xs sky-column.sky-column-xs-11,.sky-responsive-container-sm sky-column.sky-column-xs-11,.sky-responsive-container-md sky-column.sky-column-xs-11,.sky-responsive-container-lg sky-column.sky-column-xs-11{width:calc(11 / 12 * 100%)}.sky-responsive-container-xs sky-column.sky-column-xs-12,.sky-responsive-container-sm sky-column.sky-column-xs-12,.sky-responsive-container-md sky-column.sky-column-xs-12,.sky-responsive-container-lg sky-column.sky-column-xs-12{width:100%}.sky-responsive-container-xs sky-column:not([class*=sky-column-xs-]),.sky-responsive-container-sm sky-column:not([class*=sky-column-xs-]),.sky-responsive-container-md sky-column:not([class*=sky-column-xs-]),.sky-responsive-container-lg sky-column:not([class*=sky-column-xs-]){width:100%}@media (min-width: 768px){sky-column.sky-column-sm-1{width:calc(1 / 12 * 100%)}sky-column.sky-column-sm-2{width:calc(2 / 12 * 100%)}sky-column.sky-column-sm-3{width:25%}sky-column.sky-column-sm-4{width:calc(4 / 12 * 100%)}sky-column.sky-column-sm-5{width:calc(5 / 12 * 100%)}sky-column.sky-column-sm-6{width:50%}sky-column.sky-column-sm-7{width:calc(7 / 12 * 100%)}sky-column.sky-column-sm-8{width:calc(8 / 12 * 100%)}sky-column.sky-column-sm-9{width:75%}sky-column.sky-column-sm-10{width:calc(10 / 12 * 100%)}sky-column.sky-column-sm-11{width:calc(11 / 12 * 100%)}sky-column.sky-column-sm-12{width:100%}}.sky-responsive-container-sm sky-column.sky-column-sm-1,.sky-responsive-container-md sky-column.sky-column-sm-1,.sky-responsive-container-lg sky-column.sky-column-sm-1{width:calc(1 / 12 * 100%)}.sky-responsive-container-sm sky-column.sky-column-sm-2,.sky-responsive-container-md sky-column.sky-column-sm-2,.sky-responsive-container-lg sky-column.sky-column-sm-2{width:calc(2 / 12 * 100%)}.sky-responsive-container-sm sky-column.sky-column-sm-3,.sky-responsive-container-md sky-column.sky-column-sm-3,.sky-responsive-container-lg sky-column.sky-column-sm-3{width:25%}.sky-responsive-container-sm sky-column.sky-column-sm-4,.sky-responsive-container-md sky-column.sky-column-sm-4,.sky-responsive-container-lg sky-column.sky-column-sm-4{width:calc(4 / 12 * 100%)}.sky-responsive-container-sm sky-column.sky-column-sm-5,.sky-responsive-container-md sky-column.sky-column-sm-5,.sky-responsive-container-lg sky-column.sky-column-sm-5{width:calc(5 / 12 * 100%)}.sky-responsive-container-sm sky-column.sky-column-sm-6,.sky-responsive-container-md sky-column.sky-column-sm-6,.sky-responsive-container-lg sky-column.sky-column-sm-6{width:50%}.sky-responsive-container-sm sky-column.sky-column-sm-7,.sky-responsive-container-md sky-column.sky-column-sm-7,.sky-responsive-container-lg sky-column.sky-column-sm-7{width:calc(7 / 12 * 100%)}.sky-responsive-container-sm sky-column.sky-column-sm-8,.sky-responsive-container-md sky-column.sky-column-sm-8,.sky-responsive-container-lg sky-column.sky-column-sm-8{width:calc(8 / 12 * 100%)}.sky-responsive-container-sm sky-column.sky-column-sm-9,.sky-responsive-container-md sky-column.sky-column-sm-9,.sky-responsive-container-lg sky-column.sky-column-sm-9{width:75%}.sky-responsive-container-sm sky-column.sky-column-sm-10,.sky-responsive-container-md sky-column.sky-column-sm-10,.sky-responsive-container-lg sky-column.sky-column-sm-10{width:calc(10 / 12 * 100%)}.sky-responsive-container-sm sky-column.sky-column-sm-11,.sky-responsive-container-md sky-column.sky-column-sm-11,.sky-responsive-container-lg sky-column.sky-column-sm-11{width:calc(11 / 12 * 100%)}.sky-responsive-container-sm sky-column.sky-column-sm-12,.sky-responsive-container-md sky-column.sky-column-sm-12,.sky-responsive-container-lg sky-column.sky-column-sm-12{width:100%}@media (min-width: 992px){sky-column.sky-column-md-1{width:calc(1 / 12 * 100%)}sky-column.sky-column-md-2{width:calc(2 / 12 * 100%)}sky-column.sky-column-md-3{width:25%}sky-column.sky-column-md-4{width:calc(4 / 12 * 100%)}sky-column.sky-column-md-5{width:calc(5 / 12 * 100%)}sky-column.sky-column-md-6{width:50%}sky-column.sky-column-md-7{width:calc(7 / 12 * 100%)}sky-column.sky-column-md-8{width:calc(8 / 12 * 100%)}sky-column.sky-column-md-9{width:75%}sky-column.sky-column-md-10{width:calc(10 / 12 * 100%)}sky-column.sky-column-md-11{width:calc(11 / 12 * 100%)}sky-column.sky-column-md-12{width:100%}}.sky-responsive-container-md sky-column.sky-column-md-1,.sky-responsive-container-lg sky-column.sky-column-md-1{width:calc(1 / 12 * 100%)}.sky-responsive-container-md sky-column.sky-column-md-2,.sky-responsive-container-lg sky-column.sky-column-md-2{width:calc(2 / 12 * 100%)}.sky-responsive-container-md sky-column.sky-column-md-3,.sky-responsive-container-lg sky-column.sky-column-md-3{width:25%}.sky-responsive-container-md sky-column.sky-column-md-4,.sky-responsive-container-lg sky-column.sky-column-md-4{width:calc(4 / 12 * 100%)}.sky-responsive-container-md sky-column.sky-column-md-5,.sky-responsive-container-lg sky-column.sky-column-md-5{width:calc(5 / 12 * 100%)}.sky-responsive-container-md sky-column.sky-column-md-6,.sky-responsive-container-lg sky-column.sky-column-md-6{width:50%}.sky-responsive-container-md sky-column.sky-column-md-7,.sky-responsive-container-lg sky-column.sky-column-md-7{width:calc(7 / 12 * 100%)}.sky-responsive-container-md sky-column.sky-column-md-8,.sky-responsive-container-lg sky-column.sky-column-md-8{width:calc(8 / 12 * 100%)}.sky-responsive-container-md sky-column.sky-column-md-9,.sky-responsive-container-lg sky-column.sky-column-md-9{width:75%}.sky-responsive-container-md sky-column.sky-column-md-10,.sky-responsive-container-lg sky-column.sky-column-md-10{width:calc(10 / 12 * 100%)}.sky-responsive-container-md sky-column.sky-column-md-11,.sky-responsive-container-lg sky-column.sky-column-md-11{width:calc(11 / 12 * 100%)}.sky-responsive-container-md sky-column.sky-column-md-12,.sky-responsive-container-lg sky-column.sky-column-md-12{width:100%}@media (min-width: 1200px){sky-column.sky-column-lg-1{width:calc(1 / 12 * 100%)}sky-column.sky-column-lg-2{width:calc(2 / 12 * 100%)}sky-column.sky-column-lg-3{width:25%}sky-column.sky-column-lg-4{width:calc(4 / 12 * 100%)}sky-column.sky-column-lg-5{width:calc(5 / 12 * 100%)}sky-column.sky-column-lg-6{width:50%}sky-column.sky-column-lg-7{width:calc(7 / 12 * 100%)}sky-column.sky-column-lg-8{width:calc(8 / 12 * 100%)}sky-column.sky-column-lg-9{width:75%}sky-column.sky-column-lg-10{width:calc(10 / 12 * 100%)}sky-column.sky-column-lg-11{width:calc(11 / 12 * 100%)}sky-column.sky-column-lg-12{width:100%}}.sky-responsive-container-lg sky-column.sky-column-lg-1{width:calc(1 / 12 * 100%)}.sky-responsive-container-lg sky-column.sky-column-lg-2{width:calc(2 / 12 * 100%)}.sky-responsive-container-lg sky-column.sky-column-lg-3{width:25%}.sky-responsive-container-lg sky-column.sky-column-lg-4{width:calc(4 / 12 * 100%)}.sky-responsive-container-lg sky-column.sky-column-lg-5{width:calc(5 / 12 * 100%)}.sky-responsive-container-lg sky-column.sky-column-lg-6{width:50%}.sky-responsive-container-lg sky-column.sky-column-lg-7{width:calc(7 / 12 * 100%)}.sky-responsive-container-lg sky-column.sky-column-lg-8{width:calc(8 / 12 * 100%)}.sky-responsive-container-lg sky-column.sky-column-lg-9{width:75%}.sky-responsive-container-lg sky-column.sky-column-lg-10{width:calc(10 / 12 * 100%)}.sky-responsive-container-lg sky-column.sky-column-lg-11{width:calc(11 / 12 * 100%)}.sky-responsive-container-lg sky-column.sky-column-lg-12{width:100%}\n"], encapsulation: i0.ViewEncapsulation.None });
|
|
1659
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyColumnComponent, decorators: [{
|
|
1660
|
+
type: Component,
|
|
1661
|
+
args: [{ selector: 'sky-column', encapsulation: ViewEncapsulation.None, template: "<ng-content></ng-content>\n", styles: ["sky-column.sky-column{padding-right:15px;padding-left:15px;width:100%;min-height:1px}.sky-theme-modern sky-column.sky-column{padding-right:30px;padding-left:30px}.sky-fluid-grid-gutter-size-small sky-column.sky-column{padding-right:5px;padding-left:5px}.sky-fluid-grid-gutter-size-medium sky-column.sky-column{padding-right:10px;padding-left:10px}.sky-theme-modern .sky-fluid-grid-gutter-size-small sky-column.sky-column{padding-right:10px;padding-left:10px}.sky-theme-modern .sky-fluid-grid-gutter-size-medium sky-column.sky-column{padding-right:15px;padding-left:15px}sky-column.sky-column-xs-1{width:calc(1 / 12 * 100%)}sky-column.sky-column-xs-2{width:calc(2 / 12 * 100%)}sky-column.sky-column-xs-3{width:25%}sky-column.sky-column-xs-4{width:calc(4 / 12 * 100%)}sky-column.sky-column-xs-5{width:calc(5 / 12 * 100%)}sky-column.sky-column-xs-6{width:50%}sky-column.sky-column-xs-7{width:calc(7 / 12 * 100%)}sky-column.sky-column-xs-8{width:calc(8 / 12 * 100%)}sky-column.sky-column-xs-9{width:75%}sky-column.sky-column-xs-10{width:calc(10 / 12 * 100%)}sky-column.sky-column-xs-11{width:calc(11 / 12 * 100%)}sky-column.sky-column-xs-12{width:100%}sky-column:not([class*=sky-column-xs-]){width:100%}.sky-responsive-container-xs sky-column.sky-column-xs-1,.sky-responsive-container-sm sky-column.sky-column-xs-1,.sky-responsive-container-md sky-column.sky-column-xs-1,.sky-responsive-container-lg sky-column.sky-column-xs-1{width:calc(1 / 12 * 100%)}.sky-responsive-container-xs sky-column.sky-column-xs-2,.sky-responsive-container-sm sky-column.sky-column-xs-2,.sky-responsive-container-md sky-column.sky-column-xs-2,.sky-responsive-container-lg sky-column.sky-column-xs-2{width:calc(2 / 12 * 100%)}.sky-responsive-container-xs sky-column.sky-column-xs-3,.sky-responsive-container-sm sky-column.sky-column-xs-3,.sky-responsive-container-md sky-column.sky-column-xs-3,.sky-responsive-container-lg sky-column.sky-column-xs-3{width:25%}.sky-responsive-container-xs sky-column.sky-column-xs-4,.sky-responsive-container-sm sky-column.sky-column-xs-4,.sky-responsive-container-md sky-column.sky-column-xs-4,.sky-responsive-container-lg sky-column.sky-column-xs-4{width:calc(4 / 12 * 100%)}.sky-responsive-container-xs sky-column.sky-column-xs-5,.sky-responsive-container-sm sky-column.sky-column-xs-5,.sky-responsive-container-md sky-column.sky-column-xs-5,.sky-responsive-container-lg sky-column.sky-column-xs-5{width:calc(5 / 12 * 100%)}.sky-responsive-container-xs sky-column.sky-column-xs-6,.sky-responsive-container-sm sky-column.sky-column-xs-6,.sky-responsive-container-md sky-column.sky-column-xs-6,.sky-responsive-container-lg sky-column.sky-column-xs-6{width:50%}.sky-responsive-container-xs sky-column.sky-column-xs-7,.sky-responsive-container-sm sky-column.sky-column-xs-7,.sky-responsive-container-md sky-column.sky-column-xs-7,.sky-responsive-container-lg sky-column.sky-column-xs-7{width:calc(7 / 12 * 100%)}.sky-responsive-container-xs sky-column.sky-column-xs-8,.sky-responsive-container-sm sky-column.sky-column-xs-8,.sky-responsive-container-md sky-column.sky-column-xs-8,.sky-responsive-container-lg sky-column.sky-column-xs-8{width:calc(8 / 12 * 100%)}.sky-responsive-container-xs sky-column.sky-column-xs-9,.sky-responsive-container-sm sky-column.sky-column-xs-9,.sky-responsive-container-md sky-column.sky-column-xs-9,.sky-responsive-container-lg sky-column.sky-column-xs-9{width:75%}.sky-responsive-container-xs sky-column.sky-column-xs-10,.sky-responsive-container-sm sky-column.sky-column-xs-10,.sky-responsive-container-md sky-column.sky-column-xs-10,.sky-responsive-container-lg sky-column.sky-column-xs-10{width:calc(10 / 12 * 100%)}.sky-responsive-container-xs sky-column.sky-column-xs-11,.sky-responsive-container-sm sky-column.sky-column-xs-11,.sky-responsive-container-md sky-column.sky-column-xs-11,.sky-responsive-container-lg sky-column.sky-column-xs-11{width:calc(11 / 12 * 100%)}.sky-responsive-container-xs sky-column.sky-column-xs-12,.sky-responsive-container-sm sky-column.sky-column-xs-12,.sky-responsive-container-md sky-column.sky-column-xs-12,.sky-responsive-container-lg sky-column.sky-column-xs-12{width:100%}.sky-responsive-container-xs sky-column:not([class*=sky-column-xs-]),.sky-responsive-container-sm sky-column:not([class*=sky-column-xs-]),.sky-responsive-container-md sky-column:not([class*=sky-column-xs-]),.sky-responsive-container-lg sky-column:not([class*=sky-column-xs-]){width:100%}@media (min-width: 768px){sky-column.sky-column-sm-1{width:calc(1 / 12 * 100%)}sky-column.sky-column-sm-2{width:calc(2 / 12 * 100%)}sky-column.sky-column-sm-3{width:25%}sky-column.sky-column-sm-4{width:calc(4 / 12 * 100%)}sky-column.sky-column-sm-5{width:calc(5 / 12 * 100%)}sky-column.sky-column-sm-6{width:50%}sky-column.sky-column-sm-7{width:calc(7 / 12 * 100%)}sky-column.sky-column-sm-8{width:calc(8 / 12 * 100%)}sky-column.sky-column-sm-9{width:75%}sky-column.sky-column-sm-10{width:calc(10 / 12 * 100%)}sky-column.sky-column-sm-11{width:calc(11 / 12 * 100%)}sky-column.sky-column-sm-12{width:100%}}.sky-responsive-container-sm sky-column.sky-column-sm-1,.sky-responsive-container-md sky-column.sky-column-sm-1,.sky-responsive-container-lg sky-column.sky-column-sm-1{width:calc(1 / 12 * 100%)}.sky-responsive-container-sm sky-column.sky-column-sm-2,.sky-responsive-container-md sky-column.sky-column-sm-2,.sky-responsive-container-lg sky-column.sky-column-sm-2{width:calc(2 / 12 * 100%)}.sky-responsive-container-sm sky-column.sky-column-sm-3,.sky-responsive-container-md sky-column.sky-column-sm-3,.sky-responsive-container-lg sky-column.sky-column-sm-3{width:25%}.sky-responsive-container-sm sky-column.sky-column-sm-4,.sky-responsive-container-md sky-column.sky-column-sm-4,.sky-responsive-container-lg sky-column.sky-column-sm-4{width:calc(4 / 12 * 100%)}.sky-responsive-container-sm sky-column.sky-column-sm-5,.sky-responsive-container-md sky-column.sky-column-sm-5,.sky-responsive-container-lg sky-column.sky-column-sm-5{width:calc(5 / 12 * 100%)}.sky-responsive-container-sm sky-column.sky-column-sm-6,.sky-responsive-container-md sky-column.sky-column-sm-6,.sky-responsive-container-lg sky-column.sky-column-sm-6{width:50%}.sky-responsive-container-sm sky-column.sky-column-sm-7,.sky-responsive-container-md sky-column.sky-column-sm-7,.sky-responsive-container-lg sky-column.sky-column-sm-7{width:calc(7 / 12 * 100%)}.sky-responsive-container-sm sky-column.sky-column-sm-8,.sky-responsive-container-md sky-column.sky-column-sm-8,.sky-responsive-container-lg sky-column.sky-column-sm-8{width:calc(8 / 12 * 100%)}.sky-responsive-container-sm sky-column.sky-column-sm-9,.sky-responsive-container-md sky-column.sky-column-sm-9,.sky-responsive-container-lg sky-column.sky-column-sm-9{width:75%}.sky-responsive-container-sm sky-column.sky-column-sm-10,.sky-responsive-container-md sky-column.sky-column-sm-10,.sky-responsive-container-lg sky-column.sky-column-sm-10{width:calc(10 / 12 * 100%)}.sky-responsive-container-sm sky-column.sky-column-sm-11,.sky-responsive-container-md sky-column.sky-column-sm-11,.sky-responsive-container-lg sky-column.sky-column-sm-11{width:calc(11 / 12 * 100%)}.sky-responsive-container-sm sky-column.sky-column-sm-12,.sky-responsive-container-md sky-column.sky-column-sm-12,.sky-responsive-container-lg sky-column.sky-column-sm-12{width:100%}@media (min-width: 992px){sky-column.sky-column-md-1{width:calc(1 / 12 * 100%)}sky-column.sky-column-md-2{width:calc(2 / 12 * 100%)}sky-column.sky-column-md-3{width:25%}sky-column.sky-column-md-4{width:calc(4 / 12 * 100%)}sky-column.sky-column-md-5{width:calc(5 / 12 * 100%)}sky-column.sky-column-md-6{width:50%}sky-column.sky-column-md-7{width:calc(7 / 12 * 100%)}sky-column.sky-column-md-8{width:calc(8 / 12 * 100%)}sky-column.sky-column-md-9{width:75%}sky-column.sky-column-md-10{width:calc(10 / 12 * 100%)}sky-column.sky-column-md-11{width:calc(11 / 12 * 100%)}sky-column.sky-column-md-12{width:100%}}.sky-responsive-container-md sky-column.sky-column-md-1,.sky-responsive-container-lg sky-column.sky-column-md-1{width:calc(1 / 12 * 100%)}.sky-responsive-container-md sky-column.sky-column-md-2,.sky-responsive-container-lg sky-column.sky-column-md-2{width:calc(2 / 12 * 100%)}.sky-responsive-container-md sky-column.sky-column-md-3,.sky-responsive-container-lg sky-column.sky-column-md-3{width:25%}.sky-responsive-container-md sky-column.sky-column-md-4,.sky-responsive-container-lg sky-column.sky-column-md-4{width:calc(4 / 12 * 100%)}.sky-responsive-container-md sky-column.sky-column-md-5,.sky-responsive-container-lg sky-column.sky-column-md-5{width:calc(5 / 12 * 100%)}.sky-responsive-container-md sky-column.sky-column-md-6,.sky-responsive-container-lg sky-column.sky-column-md-6{width:50%}.sky-responsive-container-md sky-column.sky-column-md-7,.sky-responsive-container-lg sky-column.sky-column-md-7{width:calc(7 / 12 * 100%)}.sky-responsive-container-md sky-column.sky-column-md-8,.sky-responsive-container-lg sky-column.sky-column-md-8{width:calc(8 / 12 * 100%)}.sky-responsive-container-md sky-column.sky-column-md-9,.sky-responsive-container-lg sky-column.sky-column-md-9{width:75%}.sky-responsive-container-md sky-column.sky-column-md-10,.sky-responsive-container-lg sky-column.sky-column-md-10{width:calc(10 / 12 * 100%)}.sky-responsive-container-md sky-column.sky-column-md-11,.sky-responsive-container-lg sky-column.sky-column-md-11{width:calc(11 / 12 * 100%)}.sky-responsive-container-md sky-column.sky-column-md-12,.sky-responsive-container-lg sky-column.sky-column-md-12{width:100%}@media (min-width: 1200px){sky-column.sky-column-lg-1{width:calc(1 / 12 * 100%)}sky-column.sky-column-lg-2{width:calc(2 / 12 * 100%)}sky-column.sky-column-lg-3{width:25%}sky-column.sky-column-lg-4{width:calc(4 / 12 * 100%)}sky-column.sky-column-lg-5{width:calc(5 / 12 * 100%)}sky-column.sky-column-lg-6{width:50%}sky-column.sky-column-lg-7{width:calc(7 / 12 * 100%)}sky-column.sky-column-lg-8{width:calc(8 / 12 * 100%)}sky-column.sky-column-lg-9{width:75%}sky-column.sky-column-lg-10{width:calc(10 / 12 * 100%)}sky-column.sky-column-lg-11{width:calc(11 / 12 * 100%)}sky-column.sky-column-lg-12{width:100%}}.sky-responsive-container-lg sky-column.sky-column-lg-1{width:calc(1 / 12 * 100%)}.sky-responsive-container-lg sky-column.sky-column-lg-2{width:calc(2 / 12 * 100%)}.sky-responsive-container-lg sky-column.sky-column-lg-3{width:25%}.sky-responsive-container-lg sky-column.sky-column-lg-4{width:calc(4 / 12 * 100%)}.sky-responsive-container-lg sky-column.sky-column-lg-5{width:calc(5 / 12 * 100%)}.sky-responsive-container-lg sky-column.sky-column-lg-6{width:50%}.sky-responsive-container-lg sky-column.sky-column-lg-7{width:calc(7 / 12 * 100%)}.sky-responsive-container-lg sky-column.sky-column-lg-8{width:calc(8 / 12 * 100%)}.sky-responsive-container-lg sky-column.sky-column-lg-9{width:75%}.sky-responsive-container-lg sky-column.sky-column-lg-10{width:calc(10 / 12 * 100%)}.sky-responsive-container-lg sky-column.sky-column-lg-11{width:calc(11 / 12 * 100%)}.sky-responsive-container-lg sky-column.sky-column-lg-12{width:100%}\n"] }]
|
|
1662
|
+
}], propDecorators: { screenXSmall: [{
|
|
1663
|
+
type: Input
|
|
1664
|
+
}], screenSmall: [{
|
|
1665
|
+
type: Input
|
|
1666
|
+
}], screenMedium: [{
|
|
1667
|
+
type: Input
|
|
1668
|
+
}], screenLarge: [{
|
|
1669
|
+
type: Input
|
|
1670
|
+
}], classnames: [{
|
|
1671
|
+
type: HostBinding,
|
|
1672
|
+
args: ['class']
|
|
1673
|
+
}] } });
|
|
1674
|
+
|
|
1675
|
+
/**
|
|
1676
|
+
* Wraps the fluid grid to ensure proper spacing. Without the wrapper, the
|
|
1677
|
+
* alignment, padding, and margins do not behave as expected.
|
|
1678
|
+
*/
|
|
1679
|
+
class SkyFluidGridComponent {
|
|
1680
|
+
/**
|
|
1681
|
+
* Disables the outer left and right margin of the fluid grid container.
|
|
1682
|
+
* @default false
|
|
1683
|
+
*/
|
|
1684
|
+
set disableMargin(value) {
|
|
1685
|
+
this._disableMargin = value;
|
|
1686
|
+
}
|
|
1687
|
+
get disableMargin() {
|
|
1688
|
+
return this._disableMargin || false;
|
|
1689
|
+
}
|
|
1690
|
+
/**
|
|
1691
|
+
* Specifies a `SkyFluidGridGutterSizeType` to define the size of the padding
|
|
1692
|
+
* between columns. Options include: `any`, `1`, `2`, `"small"`, `"medium"`, and `"large"`.
|
|
1693
|
+
* @default "large"
|
|
1694
|
+
*/
|
|
1695
|
+
set gutterSize(value) {
|
|
1696
|
+
this._gutterSize = value;
|
|
1697
|
+
}
|
|
1698
|
+
get gutterSize() {
|
|
1699
|
+
return this._gutterSize === undefined ? 'large' : this._gutterSize;
|
|
1700
|
+
}
|
|
1701
|
+
/**
|
|
1702
|
+
* @internal
|
|
1703
|
+
*/
|
|
1704
|
+
get gutterSizeResolved() {
|
|
1705
|
+
// Before this change, the template did a `==` comparison, implicitly converting numerical
|
|
1706
|
+
// string values to their numeric values before comparing them. Checking for the numerical
|
|
1707
|
+
// string value in addition to the values allowed by the type maintains this behavior.
|
|
1708
|
+
switch (this.gutterSize) {
|
|
1709
|
+
case 'medium':
|
|
1710
|
+
case SkyFluidGridGutterSize.Medium:
|
|
1711
|
+
case SkyFluidGridGutterSize.Medium.toString():
|
|
1712
|
+
return 'medium';
|
|
1713
|
+
case 'small':
|
|
1714
|
+
case SkyFluidGridGutterSize.Small:
|
|
1715
|
+
case SkyFluidGridGutterSize.Small.toString():
|
|
1716
|
+
return 'small';
|
|
1717
|
+
default:
|
|
1718
|
+
return 'large';
|
|
1719
|
+
}
|
|
1720
|
+
}
|
|
1721
|
+
}
|
|
1722
|
+
SkyFluidGridComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyFluidGridComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
1723
|
+
SkyFluidGridComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.2.7", type: SkyFluidGridComponent, selector: "sky-fluid-grid", inputs: { disableMargin: "disableMargin", gutterSize: "gutterSize" }, ngImport: i0, template: "<div\n class=\"sky-fluid-grid\"\n [ngClass]=\"{\n 'sky-fluid-grid-gutter-size-small': gutterSizeResolved === 'small',\n 'sky-fluid-grid-gutter-size-medium': gutterSizeResolved === 'medium',\n 'sky-fluid-grid-gutter-size-large': gutterSizeResolved === 'large',\n 'sky-fluid-grid-no-margin': disableMargin\n }\"\n>\n <ng-content></ng-content>\n</div>\n", styles: [".sky-fluid-grid-gutter-size-small{padding-left:5px;padding-right:5px}.sky-fluid-grid-gutter-size-medium{padding-left:10px;padding-right:10px}.sky-fluid-grid-gutter-size-large{padding-left:15px;padding-right:15px}:host-context(.sky-theme-modern) .sky-fluid-grid-gutter-size-small{padding-left:10px;padding-right:10px}:host-context(.sky-theme-modern) .sky-fluid-grid-gutter-size-medium{padding-left:15px;padding-right:15px}:host-context(.sky-theme-modern) .sky-fluid-grid-gutter-size-large{padding-left:30px;padding-right:30px}\n"], directives: [{ type: i3.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }] });
|
|
1724
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyFluidGridComponent, decorators: [{
|
|
1725
|
+
type: Component,
|
|
1726
|
+
args: [{ selector: 'sky-fluid-grid', template: "<div\n class=\"sky-fluid-grid\"\n [ngClass]=\"{\n 'sky-fluid-grid-gutter-size-small': gutterSizeResolved === 'small',\n 'sky-fluid-grid-gutter-size-medium': gutterSizeResolved === 'medium',\n 'sky-fluid-grid-gutter-size-large': gutterSizeResolved === 'large',\n 'sky-fluid-grid-no-margin': disableMargin\n }\"\n>\n <ng-content></ng-content>\n</div>\n", styles: [".sky-fluid-grid-gutter-size-small{padding-left:5px;padding-right:5px}.sky-fluid-grid-gutter-size-medium{padding-left:10px;padding-right:10px}.sky-fluid-grid-gutter-size-large{padding-left:15px;padding-right:15px}:host-context(.sky-theme-modern) .sky-fluid-grid-gutter-size-small{padding-left:10px;padding-right:10px}:host-context(.sky-theme-modern) .sky-fluid-grid-gutter-size-medium{padding-left:15px;padding-right:15px}:host-context(.sky-theme-modern) .sky-fluid-grid-gutter-size-large{padding-left:30px;padding-right:30px}\n"] }]
|
|
1727
|
+
}], propDecorators: { disableMargin: [{
|
|
1728
|
+
type: Input
|
|
1729
|
+
}], gutterSize: [{
|
|
1730
|
+
type: Input
|
|
1731
|
+
}] } });
|
|
1732
|
+
|
|
1733
|
+
/**
|
|
1734
|
+
* Displays a row within the `sky-fluid-grid` wrapper. Previously, you could display a row
|
|
1735
|
+
* without a wrapper, but we no longer officially support that option.
|
|
1736
|
+
*/
|
|
1737
|
+
class SkyRowComponent {
|
|
1738
|
+
constructor() {
|
|
1739
|
+
/**
|
|
1740
|
+
* Indicates whether to reverse the display order for columns in the row.
|
|
1741
|
+
* @default false
|
|
1742
|
+
*/
|
|
1743
|
+
this.reverseColumnOrder = false;
|
|
1744
|
+
}
|
|
1745
|
+
}
|
|
1746
|
+
SkyRowComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyRowComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
1747
|
+
SkyRowComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.2.7", type: SkyRowComponent, selector: "sky-row", inputs: { reverseColumnOrder: "reverseColumnOrder" }, ngImport: i0, template: "<div class=\"sky-row\" [ngClass]=\"{ 'sky-row-reverse': reverseColumnOrder }\">\n <ng-content></ng-content>\n</div>\n", styles: [".sky-row{display:flex;flex-direction:row;flex-wrap:wrap;margin-left:-15px;margin-right:-15px}:host-context(.sky-fluid-grid-gutter-size-small) .sky-row{margin-left:-5px;margin-right:-5px}:host-context(.sky-fluid-grid-gutter-size-small.sky-fluid-grid-no-margin) .sky-row{margin-left:-10px;margin-right:-10px}:host-context(.sky-fluid-grid-gutter-size-medium) .sky-row{margin-left:-10px;margin-right:-10px}:host-context(.sky-fluid-grid-gutter-size-medium.sky-fluid-grid-no-margin) .sky-row{margin-left:-20px;margin-right:-20px}:host-context(.sky-fluid-grid-gutter-size-large) .sky-row{margin-left:-15px;margin-right:-15px}:host-context(.sky-fluid-grid-gutter-size-large.sky-fluid-grid-no-margin) .sky-row{margin-left:-30px;margin-right:-30px}:host-context(.sky-theme-modern .sky-fluid-grid-gutter-size-small) .sky-row{margin-left:-10px;margin-right:-10px}:host-context(.sky-theme-modern .sky-fluid-grid-gutter-size-small.sky-fluid-grid-no-margin) .sky-row{margin-left:-20px;margin-right:-20px}:host-context(.sky-theme-modern .sky-fluid-grid-gutter-size-medium) .sky-row{margin-left:-15px;margin-right:-15px}:host-context(.sky-theme-modern .sky-fluid-grid-gutter-size-medium.sky-fluid-grid-no-margin) .sky-row{margin-left:-30px;margin-right:-30px}:host-context(.sky-theme-modern .sky-fluid-grid-gutter-size-large) .sky-row{margin-left:-30px;margin-right:-30px}:host-context(.sky-theme-modern .sky-fluid-grid-gutter-size-large.sky-fluid-grid-no-margin) .sky-row{margin-left:-60px;margin-right:-60px}:host .sky-row.sky-row-reverse{flex-direction:row}:host-context(.sky-responsive-container-xs) .sky-row.sky-row-reverse,:host-context(.sky-responsive-container-sm) .sky-row.sky-row-reverse,:host-context(.sky-responsive-container-md) .sky-row.sky-row-reverse,:host-context(.sky-responsive-container-lg) .sky-row.sky-row-reverse{flex-direction:row}@media (min-width: 768px){:host .sky-row.sky-row-reverse{flex-direction:row-reverse}}:host-context(.sky-responsive-container-sm) .sky-row.sky-row-reverse,:host-context(.sky-responsive-container-md) .sky-row.sky-row-reverse,:host-context(.sky-responsive-container-lg) .sky-row.sky-row-reverse{flex-direction:row-reverse}:host-context(.sky-theme-modern) .sky-row{margin-left:-30px;margin-right:-30px}.sky-theme-modern .sky-row{margin-left:-30px;margin-right:-30px}\n"], directives: [{ type: i3.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }] });
|
|
1748
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyRowComponent, decorators: [{
|
|
1749
|
+
type: Component,
|
|
1750
|
+
args: [{ selector: 'sky-row', template: "<div class=\"sky-row\" [ngClass]=\"{ 'sky-row-reverse': reverseColumnOrder }\">\n <ng-content></ng-content>\n</div>\n", styles: [".sky-row{display:flex;flex-direction:row;flex-wrap:wrap;margin-left:-15px;margin-right:-15px}:host-context(.sky-fluid-grid-gutter-size-small) .sky-row{margin-left:-5px;margin-right:-5px}:host-context(.sky-fluid-grid-gutter-size-small.sky-fluid-grid-no-margin) .sky-row{margin-left:-10px;margin-right:-10px}:host-context(.sky-fluid-grid-gutter-size-medium) .sky-row{margin-left:-10px;margin-right:-10px}:host-context(.sky-fluid-grid-gutter-size-medium.sky-fluid-grid-no-margin) .sky-row{margin-left:-20px;margin-right:-20px}:host-context(.sky-fluid-grid-gutter-size-large) .sky-row{margin-left:-15px;margin-right:-15px}:host-context(.sky-fluid-grid-gutter-size-large.sky-fluid-grid-no-margin) .sky-row{margin-left:-30px;margin-right:-30px}:host-context(.sky-theme-modern .sky-fluid-grid-gutter-size-small) .sky-row{margin-left:-10px;margin-right:-10px}:host-context(.sky-theme-modern .sky-fluid-grid-gutter-size-small.sky-fluid-grid-no-margin) .sky-row{margin-left:-20px;margin-right:-20px}:host-context(.sky-theme-modern .sky-fluid-grid-gutter-size-medium) .sky-row{margin-left:-15px;margin-right:-15px}:host-context(.sky-theme-modern .sky-fluid-grid-gutter-size-medium.sky-fluid-grid-no-margin) .sky-row{margin-left:-30px;margin-right:-30px}:host-context(.sky-theme-modern .sky-fluid-grid-gutter-size-large) .sky-row{margin-left:-30px;margin-right:-30px}:host-context(.sky-theme-modern .sky-fluid-grid-gutter-size-large.sky-fluid-grid-no-margin) .sky-row{margin-left:-60px;margin-right:-60px}:host .sky-row.sky-row-reverse{flex-direction:row}:host-context(.sky-responsive-container-xs) .sky-row.sky-row-reverse,:host-context(.sky-responsive-container-sm) .sky-row.sky-row-reverse,:host-context(.sky-responsive-container-md) .sky-row.sky-row-reverse,:host-context(.sky-responsive-container-lg) .sky-row.sky-row-reverse{flex-direction:row}@media (min-width: 768px){:host .sky-row.sky-row-reverse{flex-direction:row-reverse}}:host-context(.sky-responsive-container-sm) .sky-row.sky-row-reverse,:host-context(.sky-responsive-container-md) .sky-row.sky-row-reverse,:host-context(.sky-responsive-container-lg) .sky-row.sky-row-reverse{flex-direction:row-reverse}:host-context(.sky-theme-modern) .sky-row{margin-left:-30px;margin-right:-30px}.sky-theme-modern .sky-row{margin-left:-30px;margin-right:-30px}\n"] }]
|
|
1751
|
+
}], propDecorators: { reverseColumnOrder: [{
|
|
1752
|
+
type: Input
|
|
1753
|
+
}] } });
|
|
1754
|
+
|
|
1755
|
+
class SkyFluidGridModule {
|
|
1756
|
+
}
|
|
1757
|
+
SkyFluidGridModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyFluidGridModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
1758
|
+
SkyFluidGridModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyFluidGridModule, declarations: [SkyRowComponent, SkyColumnComponent, SkyFluidGridComponent], imports: [CommonModule], exports: [SkyRowComponent, SkyColumnComponent, SkyFluidGridComponent] });
|
|
1759
|
+
SkyFluidGridModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyFluidGridModule, imports: [[CommonModule]] });
|
|
1760
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyFluidGridModule, decorators: [{
|
|
1761
|
+
type: NgModule,
|
|
1762
|
+
args: [{
|
|
1763
|
+
imports: [CommonModule],
|
|
1764
|
+
declarations: [SkyRowComponent, SkyColumnComponent, SkyFluidGridComponent],
|
|
1765
|
+
exports: [SkyRowComponent, SkyColumnComponent, SkyFluidGridComponent],
|
|
1766
|
+
}]
|
|
1767
|
+
}] });
|
|
1768
|
+
|
|
1769
|
+
const tokenRegex = /(\{\d+\})/;
|
|
1770
|
+
class SkyFormatComponent {
|
|
1771
|
+
/**
|
|
1772
|
+
* The tokenized string that represents the template. Tokens use the `{n}` notation
|
|
1773
|
+
* where `n` is the ordinal of the item to replace the token.
|
|
1774
|
+
*/
|
|
1775
|
+
set text(value) {
|
|
1776
|
+
this._text = value;
|
|
1777
|
+
this.updateItemsForDisplay();
|
|
1778
|
+
}
|
|
1779
|
+
get text() {
|
|
1780
|
+
return this._text;
|
|
1781
|
+
}
|
|
1782
|
+
/**
|
|
1783
|
+
* An array of `TemplateRef` objects to be placed in the template, where the `nth`
|
|
1784
|
+
* item is placed at the `{n}` location in the template.
|
|
1785
|
+
*/
|
|
1786
|
+
set args(value) {
|
|
1787
|
+
this._args = value;
|
|
1788
|
+
this.updateItemsForDisplay();
|
|
1789
|
+
}
|
|
1790
|
+
get args() {
|
|
1791
|
+
return this._args;
|
|
1792
|
+
}
|
|
1793
|
+
updateItemsForDisplay() {
|
|
1794
|
+
this.itemsForDisplay = [];
|
|
1795
|
+
if (this.text && this.args) {
|
|
1796
|
+
const textParts = this.text.split(tokenRegex);
|
|
1797
|
+
for (const textPart of textParts) {
|
|
1798
|
+
// Disregard empty strings.
|
|
1799
|
+
if (textPart) {
|
|
1800
|
+
const item = {};
|
|
1801
|
+
if (tokenRegex.test(textPart)) {
|
|
1802
|
+
const valueIndex = +textPart.substring(1, textPart.length - 1);
|
|
1803
|
+
item.templateRef = this.args[valueIndex];
|
|
1804
|
+
}
|
|
1805
|
+
else {
|
|
1806
|
+
item.text = textPart;
|
|
1807
|
+
}
|
|
1808
|
+
this.itemsForDisplay.push(item);
|
|
1809
|
+
}
|
|
1810
|
+
}
|
|
1811
|
+
}
|
|
1812
|
+
}
|
|
1813
|
+
}
|
|
1814
|
+
SkyFormatComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyFormatComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
1815
|
+
SkyFormatComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.2.7", type: SkyFormatComponent, selector: "sky-format", inputs: { text: "text", args: "args" }, ngImport: i0, template: "<ng-container *ngFor=\"let item of itemsForDisplay\">\n <!--\n The following ng-container must be on one line so no extra whitespace is introduced.\n -->\n <ng-container *ngIf=\"item.text; else item.templateRef\">{{\n item.text\n }}</ng-container>\n</ng-container>\n", directives: [{ type: i3.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i3.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
1816
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyFormatComponent, decorators: [{
|
|
1817
|
+
type: Component,
|
|
1818
|
+
args: [{ selector: 'sky-format', changeDetection: ChangeDetectionStrategy.OnPush, template: "<ng-container *ngFor=\"let item of itemsForDisplay\">\n <!--\n The following ng-container must be on one line so no extra whitespace is introduced.\n -->\n <ng-container *ngIf=\"item.text; else item.templateRef\">{{\n item.text\n }}</ng-container>\n</ng-container>\n" }]
|
|
1819
|
+
}], propDecorators: { text: [{
|
|
1820
|
+
type: Input
|
|
1821
|
+
}], args: [{
|
|
1822
|
+
type: Input
|
|
1823
|
+
}] } });
|
|
1824
|
+
|
|
1825
|
+
class SkyFormatModule {
|
|
1826
|
+
}
|
|
1827
|
+
SkyFormatModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyFormatModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
1828
|
+
SkyFormatModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyFormatModule, declarations: [SkyFormatComponent], imports: [CommonModule], exports: [SkyFormatComponent] });
|
|
1829
|
+
SkyFormatModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyFormatModule, imports: [[CommonModule]] });
|
|
1830
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyFormatModule, decorators: [{
|
|
1831
|
+
type: NgModule,
|
|
1832
|
+
args: [{
|
|
1833
|
+
declarations: [SkyFormatComponent],
|
|
1834
|
+
imports: [CommonModule],
|
|
1835
|
+
exports: [SkyFormatComponent],
|
|
1836
|
+
}]
|
|
1837
|
+
}] });
|
|
1838
|
+
|
|
1839
|
+
/**
|
|
1840
|
+
* @internal
|
|
1841
|
+
*/
|
|
1842
|
+
class SkyPageThemeAdapterService {
|
|
1843
|
+
addTheme() {
|
|
1844
|
+
if (!this.styleEl) {
|
|
1845
|
+
this.styleEl = document.createElement('style');
|
|
1846
|
+
this.styleEl.appendChild(document.createTextNode('body { background-color: #fff; }'));
|
|
1847
|
+
document.head.appendChild(this.styleEl);
|
|
1848
|
+
}
|
|
1849
|
+
}
|
|
1850
|
+
removeTheme() {
|
|
1851
|
+
if (this.styleEl) {
|
|
1852
|
+
document.head.removeChild(this.styleEl);
|
|
1853
|
+
this.styleEl = undefined;
|
|
1854
|
+
}
|
|
1855
|
+
}
|
|
1856
|
+
}
|
|
1857
|
+
SkyPageThemeAdapterService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyPageThemeAdapterService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
1858
|
+
SkyPageThemeAdapterService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyPageThemeAdapterService });
|
|
1859
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyPageThemeAdapterService, decorators: [{
|
|
1860
|
+
type: Injectable
|
|
1861
|
+
}] });
|
|
1862
|
+
|
|
1863
|
+
/**
|
|
1864
|
+
* Resets the SPA's background to white and adds the `sky-theme-default` CSS class to the host
|
|
1865
|
+
* element to let consumers override CSS styling. Consumers can override any element by writing
|
|
1866
|
+
* CSS selectors like this: `:host-context(.sky-theme-default) .my-class {}`.
|
|
1867
|
+
*/
|
|
1868
|
+
class SkyPageComponent {
|
|
1869
|
+
constructor(themeAdapter) {
|
|
1870
|
+
this.themeAdapter = themeAdapter;
|
|
1871
|
+
}
|
|
1872
|
+
ngOnInit() {
|
|
1873
|
+
this.themeAdapter.addTheme();
|
|
1874
|
+
}
|
|
1875
|
+
ngOnDestroy() {
|
|
1876
|
+
this.themeAdapter.removeTheme();
|
|
1877
|
+
}
|
|
1878
|
+
}
|
|
1879
|
+
SkyPageComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyPageComponent, deps: [{ token: SkyPageThemeAdapterService }], target: i0.ɵɵFactoryTarget.Component });
|
|
1880
|
+
SkyPageComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.2.7", type: SkyPageComponent, selector: "sky-page", providers: [SkyPageThemeAdapterService], ngImport: i0, template: "<div class=\"sky-theme-default\">\n <ng-content></ng-content>\n</div>\n" });
|
|
1881
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyPageComponent, decorators: [{
|
|
1882
|
+
type: Component,
|
|
1883
|
+
args: [{ selector: 'sky-page', providers: [SkyPageThemeAdapterService], template: "<div class=\"sky-theme-default\">\n <ng-content></ng-content>\n</div>\n" }]
|
|
1884
|
+
}], ctorParameters: function () { return [{ type: SkyPageThemeAdapterService }]; } });
|
|
1885
|
+
|
|
1886
|
+
class SkyPageModule {
|
|
1887
|
+
}
|
|
1888
|
+
SkyPageModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyPageModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
1889
|
+
SkyPageModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyPageModule, declarations: [SkyPageComponent], exports: [SkyPageComponent] });
|
|
1890
|
+
SkyPageModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyPageModule });
|
|
1891
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyPageModule, decorators: [{
|
|
1892
|
+
type: NgModule,
|
|
1893
|
+
args: [{
|
|
1894
|
+
declarations: [SkyPageComponent],
|
|
1895
|
+
exports: [SkyPageComponent],
|
|
1896
|
+
}]
|
|
1897
|
+
}] });
|
|
1898
|
+
|
|
1899
|
+
/**
|
|
1900
|
+
* Displays messages that require immediate attention as [alerts](https://developer.blackbaud.com/skyux/components/alert) within
|
|
1901
|
+
* the page summary.
|
|
1902
|
+
*/
|
|
1903
|
+
/* istanbul ignore next */
|
|
1904
|
+
/* Code coverage having problems with no statements in classes */
|
|
1905
|
+
class SkyPageSummaryAlertComponent {
|
|
1906
|
+
}
|
|
1907
|
+
SkyPageSummaryAlertComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyPageSummaryAlertComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
1908
|
+
SkyPageSummaryAlertComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.2.7", type: SkyPageSummaryAlertComponent, selector: "sky-page-summary-alert", ngImport: i0, template: "<ng-content></ng-content>\n", styles: ["::ng-deep .sky-alert{margin-top:0;margin-bottom:20px;line-height:initial}\n"] });
|
|
1909
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyPageSummaryAlertComponent, decorators: [{
|
|
1910
|
+
type: Component,
|
|
1911
|
+
args: [{ selector: 'sky-page-summary-alert', template: "<ng-content></ng-content>\n", styles: ["::ng-deep .sky-alert{margin-top:0;margin-bottom:20px;line-height:initial}\n"] }]
|
|
1912
|
+
}] });
|
|
1913
|
+
|
|
1914
|
+
/**
|
|
1915
|
+
* Displays content in the arbitrary section of the page summary.
|
|
1916
|
+
*/
|
|
1917
|
+
/* istanbul ignore next */
|
|
1918
|
+
/* Code coverage having problems with no statements in classes */
|
|
1919
|
+
class SkyPageSummaryContentComponent {
|
|
1920
|
+
}
|
|
1921
|
+
SkyPageSummaryContentComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyPageSummaryContentComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
1922
|
+
SkyPageSummaryContentComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.2.7", type: SkyPageSummaryContentComponent, selector: "sky-page-summary-content", ngImport: i0, template: "<div class=\"sky-page-summary-content\">\n <ng-content></ng-content>\n</div>\n", styles: [".sky-page-summary-content{margin-top:20px}\n"] });
|
|
1923
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyPageSummaryContentComponent, decorators: [{
|
|
1924
|
+
type: Component,
|
|
1925
|
+
args: [{ selector: 'sky-page-summary-content', template: "<div class=\"sky-page-summary-content\">\n <ng-content></ng-content>\n</div>\n", styles: [".sky-page-summary-content{margin-top:20px}\n"] }]
|
|
1926
|
+
}] });
|
|
1927
|
+
|
|
1928
|
+
/**
|
|
1929
|
+
* Displays an image in the page summary to identify a record
|
|
1930
|
+
* or help users complete a core task.
|
|
1931
|
+
*/
|
|
1932
|
+
/* istanbul ignore next */
|
|
1933
|
+
/* Code coverage having problems with no statements in classes */
|
|
1934
|
+
class SkyPageSummaryImageComponent {
|
|
1935
|
+
}
|
|
1936
|
+
SkyPageSummaryImageComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyPageSummaryImageComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
1937
|
+
SkyPageSummaryImageComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.2.7", type: SkyPageSummaryImageComponent, selector: "sky-page-summary-image", ngImport: i0, template: "<div class=\"sky-page-summary-image\">\n <ng-content></ng-content>\n</div>\n", styles: [":host .sky-page-summary-image{width:100px;margin-left:auto;margin-right:auto;margin-bottom:10px}:host-context(.sky-responsive-container-xs) .sky-page-summary-image,:host-context(.sky-responsive-container-sm) .sky-page-summary-image,:host-context(.sky-responsive-container-md) .sky-page-summary-image,:host-context(.sky-responsive-container-lg) .sky-page-summary-image{width:100px;margin-left:auto;margin-right:auto;margin-bottom:10px}@media (min-width: 768px){:host .sky-page-summary-image{width:120px;flex:0 0 120px;margin:initial}}:host-context(.sky-responsive-container-sm) .sky-page-summary-image,:host-context(.sky-responsive-container-md) .sky-page-summary-image,:host-context(.sky-responsive-container-lg) .sky-page-summary-image{width:120px;flex:0 0 120px;margin:initial}\n"] });
|
|
1938
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyPageSummaryImageComponent, decorators: [{
|
|
1939
|
+
type: Component,
|
|
1940
|
+
args: [{ selector: 'sky-page-summary-image', template: "<div class=\"sky-page-summary-image\">\n <ng-content></ng-content>\n</div>\n", styles: [":host .sky-page-summary-image{width:100px;margin-left:auto;margin-right:auto;margin-bottom:10px}:host-context(.sky-responsive-container-xs) .sky-page-summary-image,:host-context(.sky-responsive-container-sm) .sky-page-summary-image,:host-context(.sky-responsive-container-md) .sky-page-summary-image,:host-context(.sky-responsive-container-lg) .sky-page-summary-image{width:100px;margin-left:auto;margin-right:auto;margin-bottom:10px}@media (min-width: 768px){:host .sky-page-summary-image{width:120px;flex:0 0 120px;margin:initial}}:host-context(.sky-responsive-container-sm) .sky-page-summary-image,:host-context(.sky-responsive-container-md) .sky-page-summary-image,:host-context(.sky-responsive-container-lg) .sky-page-summary-image{width:120px;flex:0 0 120px;margin:initial}\n"] }]
|
|
1941
|
+
}] });
|
|
1942
|
+
|
|
1943
|
+
/**
|
|
1944
|
+
* Highlights important information about a page in the key information section of the
|
|
1945
|
+
* page summary.
|
|
1946
|
+
*/
|
|
1947
|
+
class SkyPageSummaryKeyInfoComponent {
|
|
1948
|
+
}
|
|
1949
|
+
SkyPageSummaryKeyInfoComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyPageSummaryKeyInfoComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
1950
|
+
SkyPageSummaryKeyInfoComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.2.7", type: SkyPageSummaryKeyInfoComponent, selector: "sky-page-summary-key-info", ngImport: i0, template: "<div class=\"sky-page-summary-key-info\">\n <ng-content></ng-content>\n</div>\n", styles: [":host .sky-page-summary-key-info{margin-top:20px}:host-context(.sky-responsive-container-xs) .sky-page-summary-key-info,:host-context(.sky-responsive-container-sm) .sky-page-summary-key-info,:host-context(.sky-responsive-container-md) .sky-page-summary-key-info,:host-context(.sky-responsive-container-lg) .sky-page-summary-key-info{margin-top:20px}@media (min-width: 768px){:host .sky-page-summary-key-info{margin-top:initial}}:host-context(.sky-responsive-container-sm) .sky-page-summary-key-info,:host-context(.sky-responsive-container-md) .sky-page-summary-key-info,:host-context(.sky-responsive-container-lg) .sky-page-summary-key-info{margin-top:initial}.sky-page-summary-key-info ::ng-deep .sky-key-info{display:block}\n"] });
|
|
1951
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyPageSummaryKeyInfoComponent, decorators: [{
|
|
1952
|
+
type: Component,
|
|
1953
|
+
args: [{ selector: 'sky-page-summary-key-info', template: "<div class=\"sky-page-summary-key-info\">\n <ng-content></ng-content>\n</div>\n", styles: [":host .sky-page-summary-key-info{margin-top:20px}:host-context(.sky-responsive-container-xs) .sky-page-summary-key-info,:host-context(.sky-responsive-container-sm) .sky-page-summary-key-info,:host-context(.sky-responsive-container-md) .sky-page-summary-key-info,:host-context(.sky-responsive-container-lg) .sky-page-summary-key-info{margin-top:20px}@media (min-width: 768px){:host .sky-page-summary-key-info{margin-top:initial}}:host-context(.sky-responsive-container-sm) .sky-page-summary-key-info,:host-context(.sky-responsive-container-md) .sky-page-summary-key-info,:host-context(.sky-responsive-container-lg) .sky-page-summary-key-info{margin-top:initial}.sky-page-summary-key-info ::ng-deep .sky-key-info{display:block}\n"] }]
|
|
1954
|
+
}] });
|
|
1955
|
+
|
|
1956
|
+
/**
|
|
1957
|
+
* Displays [labels](https://developer.blackbaud.com/skyux/components/label)
|
|
1958
|
+
* to highlight important status information about a page's content.
|
|
1959
|
+
*/
|
|
1960
|
+
/* istanbul ignore next */
|
|
1961
|
+
/* Code coverage having problems with no statements in classes */
|
|
1962
|
+
class SkyPageSummaryStatusComponent {
|
|
1963
|
+
}
|
|
1964
|
+
SkyPageSummaryStatusComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyPageSummaryStatusComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
1965
|
+
SkyPageSummaryStatusComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.2.7", type: SkyPageSummaryStatusComponent, selector: "sky-page-summary-status", ngImport: i0, template: "<div class=\"sky-page-summary-status\">\n <ng-content></ng-content>\n</div>\n", styles: [".sky-page-summary-status{margin-top:10px}.sky-page-summary-status ::ng-deep .sky-label{margin-right:5px}\n"] });
|
|
1966
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyPageSummaryStatusComponent, decorators: [{
|
|
1967
|
+
type: Component,
|
|
1968
|
+
args: [{ selector: 'sky-page-summary-status', template: "<div class=\"sky-page-summary-status\">\n <ng-content></ng-content>\n</div>\n", styles: [".sky-page-summary-status{margin-top:10px}.sky-page-summary-status ::ng-deep .sky-label{margin-right:5px}\n"] }]
|
|
1969
|
+
}] });
|
|
1970
|
+
|
|
1971
|
+
/**
|
|
1972
|
+
* Specifies a subtitle to identify the page content.
|
|
1973
|
+
*/
|
|
1974
|
+
/* istanbul ignore next */
|
|
1975
|
+
/* Code coverage having problems with no statements in classes */
|
|
1976
|
+
class SkyPageSummarySubtitleComponent {
|
|
1977
|
+
}
|
|
1978
|
+
SkyPageSummarySubtitleComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyPageSummarySubtitleComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
1979
|
+
SkyPageSummarySubtitleComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.2.7", type: SkyPageSummarySubtitleComponent, selector: "sky-page-summary-subtitle", ngImport: i0, template: "<p class=\"sky-page-summary-subtitle sky-emphasized\">\n <ng-content></ng-content>\n</p>\n", styles: [".sky-page-summary-subtitle{margin-top:0;margin-bottom:10px;line-height:1.1}\n"] });
|
|
1980
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyPageSummarySubtitleComponent, decorators: [{
|
|
1981
|
+
type: Component,
|
|
1982
|
+
args: [{ selector: 'sky-page-summary-subtitle', template: "<p class=\"sky-page-summary-subtitle sky-emphasized\">\n <ng-content></ng-content>\n</p>\n", styles: [".sky-page-summary-subtitle{margin-top:0;margin-bottom:10px;line-height:1.1}\n"] }]
|
|
1983
|
+
}] });
|
|
1984
|
+
|
|
1985
|
+
/**
|
|
1986
|
+
* Specifies a title to identify the page content.
|
|
1987
|
+
*/
|
|
1988
|
+
/* istanbul ignore next */
|
|
1989
|
+
/* Code coverage having problems with no statements in classes */
|
|
1990
|
+
class SkyPageSummaryTitleComponent {
|
|
1991
|
+
}
|
|
1992
|
+
SkyPageSummaryTitleComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyPageSummaryTitleComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
1993
|
+
SkyPageSummaryTitleComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.2.7", type: SkyPageSummaryTitleComponent, selector: "sky-page-summary-title", ngImport: i0, template: "<h1 class=\"sky-page-summary-title sky-page-heading\">\n <ng-content></ng-content>\n</h1>\n", styles: [".sky-page-summary-title{margin-top:0;margin-bottom:5px}\n"] });
|
|
1994
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyPageSummaryTitleComponent, decorators: [{
|
|
1995
|
+
type: Component,
|
|
1996
|
+
args: [{ selector: 'sky-page-summary-title', template: "<h1 class=\"sky-page-summary-title sky-page-heading\">\n <ng-content></ng-content>\n</h1>\n", styles: [".sky-page-summary-title{margin-top:0;margin-bottom:5px}\n"] }]
|
|
1997
|
+
}] });
|
|
1998
|
+
|
|
1999
|
+
/**
|
|
2000
|
+
* @internal
|
|
2001
|
+
*/
|
|
2002
|
+
class SkyPageSummaryAdapterService {
|
|
2003
|
+
updateKeyInfoLocation(elRef, isXS) {
|
|
2004
|
+
const el = elRef.nativeElement;
|
|
2005
|
+
const keyInfoContainerEl = el.querySelector('.sky-page-summary-key-info-container');
|
|
2006
|
+
if (isXS) {
|
|
2007
|
+
el.querySelector('.sky-page-summary-key-info-xs').appendChild(keyInfoContainerEl);
|
|
2008
|
+
}
|
|
2009
|
+
else {
|
|
2010
|
+
el.querySelector('.sky-page-summary-key-info-sm').appendChild(keyInfoContainerEl);
|
|
2011
|
+
}
|
|
2012
|
+
}
|
|
2013
|
+
}
|
|
2014
|
+
SkyPageSummaryAdapterService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyPageSummaryAdapterService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
2015
|
+
SkyPageSummaryAdapterService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyPageSummaryAdapterService });
|
|
2016
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyPageSummaryAdapterService, decorators: [{
|
|
2017
|
+
type: Injectable
|
|
2018
|
+
}] });
|
|
2019
|
+
|
|
2020
|
+
/**
|
|
2021
|
+
* Specifies the components to display in the page summary.
|
|
2022
|
+
*/
|
|
2023
|
+
class SkyPageSummaryComponent {
|
|
2024
|
+
constructor(elRef, adapter, mediaQueryService) {
|
|
2025
|
+
this.elRef = elRef;
|
|
2026
|
+
this.adapter = adapter;
|
|
2027
|
+
this.mediaQueryService = mediaQueryService;
|
|
2028
|
+
}
|
|
2029
|
+
get hasKeyInfo() {
|
|
2030
|
+
return this.keyInfoComponents.length > 0;
|
|
2031
|
+
}
|
|
2032
|
+
ngAfterViewInit() {
|
|
2033
|
+
this.breakpointSubscription = this.mediaQueryService.subscribe((args) => {
|
|
2034
|
+
this.adapter.updateKeyInfoLocation(this.elRef, args === SkyMediaBreakpoints.xs);
|
|
2035
|
+
});
|
|
2036
|
+
}
|
|
2037
|
+
ngOnDestroy() {
|
|
2038
|
+
/* istanbul ignore else */
|
|
2039
|
+
/* sanity check */
|
|
2040
|
+
if (this.breakpointSubscription) {
|
|
2041
|
+
this.breakpointSubscription.unsubscribe();
|
|
2042
|
+
}
|
|
2043
|
+
}
|
|
2044
|
+
}
|
|
2045
|
+
SkyPageSummaryComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyPageSummaryComponent, deps: [{ token: i0.ElementRef }, { token: SkyPageSummaryAdapterService }, { token: i1.SkyMediaQueryService }], target: i0.ɵɵFactoryTarget.Component });
|
|
2046
|
+
SkyPageSummaryComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.2.7", type: SkyPageSummaryComponent, selector: "sky-page-summary", providers: [SkyPageSummaryAdapterService], queries: [{ propertyName: "keyInfoComponents", predicate: SkyPageSummaryKeyInfoComponent, read: SkyPageSummaryKeyInfoComponent }], ngImport: i0, template: "<div\n class=\"sky-page-summary\"\n [ngClass]=\"{ 'sky-page-summary-with-key-info': hasKeyInfo }\"\n>\n <ng-content select=\"sky-page-summary-alert\"></ng-content>\n <div class=\"sky-page-summary-row\">\n <div class=\"sky-page-summary-left\">\n <ng-content select=\"sky-page-summary-image\"></ng-content>\n <div class=\"sky-page-summary-data\">\n <ng-content select=\"sky-page-summary-title\"></ng-content>\n <ng-content select=\"sky-page-summary-subtitle\"></ng-content>\n <ng-content select=\"sky-page-summary-status\"></ng-content>\n <div class=\"sky-page-summary-key-info-xs\"></div>\n <ng-content select=\"sky-page-summary-content\"></ng-content>\n </div>\n </div>\n <div class=\"sky-page-summary-key-info-sm\">\n <div class=\"sky-page-summary-key-info-container\">\n <ng-content select=\"sky-page-summary-key-info\"></ng-content>\n </div>\n </div>\n </div>\n</div>\n", styles: [".sky-page-summary{background-color:#fff;padding:20px 15px}.sky-page-summary-row{align-items:stretch;display:flex}:host .sky-page-summary-left{flex-basis:100%;display:initial;align-items:initial}:host .sky-page-summary-with-key-info .sky-page-summary-left{flex-basis:100%;padding-right:initial}:host-context(.sky-responsive-container-xs) .sky-page-summary-left,:host-context(.sky-responsive-container-sm) .sky-page-summary-left,:host-context(.sky-responsive-container-md) .sky-page-summary-left,:host-context(.sky-responsive-container-lg) .sky-page-summary-left{flex-basis:100%;display:initial;align-items:initial}:host-context(.sky-responsive-container-xs) .sky-page-summary-with-key-info .sky-page-summary-left,:host-context(.sky-responsive-container-sm) .sky-page-summary-with-key-info .sky-page-summary-left,:host-context(.sky-responsive-container-md) .sky-page-summary-with-key-info .sky-page-summary-left,:host-context(.sky-responsive-container-lg) .sky-page-summary-with-key-info .sky-page-summary-left{flex-basis:100%;padding-right:initial}@media (min-width: 768px){:host .sky-page-summary-with-key-info .sky-page-summary-left{flex-basis:75%;padding-right:15px}:host .sky-page-summary-with-key-info .sky-page-summary-right{flex-basis:25%}:host .sky-page-summary-left{align-items:stretch;display:flex}:host .sky-page-summary-data{flex-grow:1}}:host-context(.sky-responsive-container-sm) .sky-page-summary-with-key-info .sky-page-summary-left,:host-context(.sky-responsive-container-md) .sky-page-summary-with-key-info .sky-page-summary-left,:host-context(.sky-responsive-container-lg) .sky-page-summary-with-key-info .sky-page-summary-left{flex-basis:75%;padding-right:15px}:host-context(.sky-responsive-container-sm) .sky-page-summary-with-key-info .sky-page-summary-right,:host-context(.sky-responsive-container-md) .sky-page-summary-with-key-info .sky-page-summary-right,:host-context(.sky-responsive-container-lg) .sky-page-summary-with-key-info .sky-page-summary-right{flex-basis:25%}:host-context(.sky-responsive-container-sm) .sky-page-summary-left,:host-context(.sky-responsive-container-md) .sky-page-summary-left,:host-context(.sky-responsive-container-lg) .sky-page-summary-left{align-items:stretch;display:flex}:host-context(.sky-responsive-container-sm) .sky-page-summary-data,:host-context(.sky-responsive-container-md) .sky-page-summary-data,:host-context(.sky-responsive-container-lg) .sky-page-summary-data{flex-grow:1}\n"], directives: [{ type: i3.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }] });
|
|
2047
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyPageSummaryComponent, decorators: [{
|
|
2048
|
+
type: Component,
|
|
2049
|
+
args: [{ selector: 'sky-page-summary', providers: [SkyPageSummaryAdapterService], template: "<div\n class=\"sky-page-summary\"\n [ngClass]=\"{ 'sky-page-summary-with-key-info': hasKeyInfo }\"\n>\n <ng-content select=\"sky-page-summary-alert\"></ng-content>\n <div class=\"sky-page-summary-row\">\n <div class=\"sky-page-summary-left\">\n <ng-content select=\"sky-page-summary-image\"></ng-content>\n <div class=\"sky-page-summary-data\">\n <ng-content select=\"sky-page-summary-title\"></ng-content>\n <ng-content select=\"sky-page-summary-subtitle\"></ng-content>\n <ng-content select=\"sky-page-summary-status\"></ng-content>\n <div class=\"sky-page-summary-key-info-xs\"></div>\n <ng-content select=\"sky-page-summary-content\"></ng-content>\n </div>\n </div>\n <div class=\"sky-page-summary-key-info-sm\">\n <div class=\"sky-page-summary-key-info-container\">\n <ng-content select=\"sky-page-summary-key-info\"></ng-content>\n </div>\n </div>\n </div>\n</div>\n", styles: [".sky-page-summary{background-color:#fff;padding:20px 15px}.sky-page-summary-row{align-items:stretch;display:flex}:host .sky-page-summary-left{flex-basis:100%;display:initial;align-items:initial}:host .sky-page-summary-with-key-info .sky-page-summary-left{flex-basis:100%;padding-right:initial}:host-context(.sky-responsive-container-xs) .sky-page-summary-left,:host-context(.sky-responsive-container-sm) .sky-page-summary-left,:host-context(.sky-responsive-container-md) .sky-page-summary-left,:host-context(.sky-responsive-container-lg) .sky-page-summary-left{flex-basis:100%;display:initial;align-items:initial}:host-context(.sky-responsive-container-xs) .sky-page-summary-with-key-info .sky-page-summary-left,:host-context(.sky-responsive-container-sm) .sky-page-summary-with-key-info .sky-page-summary-left,:host-context(.sky-responsive-container-md) .sky-page-summary-with-key-info .sky-page-summary-left,:host-context(.sky-responsive-container-lg) .sky-page-summary-with-key-info .sky-page-summary-left{flex-basis:100%;padding-right:initial}@media (min-width: 768px){:host .sky-page-summary-with-key-info .sky-page-summary-left{flex-basis:75%;padding-right:15px}:host .sky-page-summary-with-key-info .sky-page-summary-right{flex-basis:25%}:host .sky-page-summary-left{align-items:stretch;display:flex}:host .sky-page-summary-data{flex-grow:1}}:host-context(.sky-responsive-container-sm) .sky-page-summary-with-key-info .sky-page-summary-left,:host-context(.sky-responsive-container-md) .sky-page-summary-with-key-info .sky-page-summary-left,:host-context(.sky-responsive-container-lg) .sky-page-summary-with-key-info .sky-page-summary-left{flex-basis:75%;padding-right:15px}:host-context(.sky-responsive-container-sm) .sky-page-summary-with-key-info .sky-page-summary-right,:host-context(.sky-responsive-container-md) .sky-page-summary-with-key-info .sky-page-summary-right,:host-context(.sky-responsive-container-lg) .sky-page-summary-with-key-info .sky-page-summary-right{flex-basis:25%}:host-context(.sky-responsive-container-sm) .sky-page-summary-left,:host-context(.sky-responsive-container-md) .sky-page-summary-left,:host-context(.sky-responsive-container-lg) .sky-page-summary-left{align-items:stretch;display:flex}:host-context(.sky-responsive-container-sm) .sky-page-summary-data,:host-context(.sky-responsive-container-md) .sky-page-summary-data,:host-context(.sky-responsive-container-lg) .sky-page-summary-data{flex-grow:1}\n"] }]
|
|
2050
|
+
}], ctorParameters: function () { return [{ type: i0.ElementRef }, { type: SkyPageSummaryAdapterService }, { type: i1.SkyMediaQueryService }]; }, propDecorators: { keyInfoComponents: [{
|
|
2051
|
+
type: ContentChildren,
|
|
2052
|
+
args: [SkyPageSummaryKeyInfoComponent, {
|
|
2053
|
+
read: SkyPageSummaryKeyInfoComponent,
|
|
2054
|
+
}]
|
|
2055
|
+
}] } });
|
|
2056
|
+
|
|
2057
|
+
class SkyPageSummaryModule {
|
|
2058
|
+
}
|
|
2059
|
+
SkyPageSummaryModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyPageSummaryModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
2060
|
+
SkyPageSummaryModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyPageSummaryModule, declarations: [SkyPageSummaryAlertComponent,
|
|
2061
|
+
SkyPageSummaryComponent,
|
|
2062
|
+
SkyPageSummaryContentComponent,
|
|
2063
|
+
SkyPageSummaryImageComponent,
|
|
2064
|
+
SkyPageSummaryKeyInfoComponent,
|
|
2065
|
+
SkyPageSummaryStatusComponent,
|
|
2066
|
+
SkyPageSummarySubtitleComponent,
|
|
2067
|
+
SkyPageSummaryTitleComponent], imports: [CommonModule], exports: [SkyPageSummaryAlertComponent,
|
|
2068
|
+
SkyPageSummaryComponent,
|
|
2069
|
+
SkyPageSummaryContentComponent,
|
|
2070
|
+
SkyPageSummaryImageComponent,
|
|
2071
|
+
SkyPageSummaryKeyInfoComponent,
|
|
2072
|
+
SkyPageSummaryStatusComponent,
|
|
2073
|
+
SkyPageSummarySubtitleComponent,
|
|
2074
|
+
SkyPageSummaryTitleComponent] });
|
|
2075
|
+
SkyPageSummaryModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyPageSummaryModule, imports: [[CommonModule]] });
|
|
2076
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyPageSummaryModule, decorators: [{
|
|
2077
|
+
type: NgModule,
|
|
2078
|
+
args: [{
|
|
2079
|
+
declarations: [
|
|
2080
|
+
SkyPageSummaryAlertComponent,
|
|
2081
|
+
SkyPageSummaryComponent,
|
|
2082
|
+
SkyPageSummaryContentComponent,
|
|
2083
|
+
SkyPageSummaryImageComponent,
|
|
2084
|
+
SkyPageSummaryKeyInfoComponent,
|
|
2085
|
+
SkyPageSummaryStatusComponent,
|
|
2086
|
+
SkyPageSummarySubtitleComponent,
|
|
2087
|
+
SkyPageSummaryTitleComponent,
|
|
2088
|
+
],
|
|
2089
|
+
imports: [CommonModule],
|
|
2090
|
+
exports: [
|
|
2091
|
+
SkyPageSummaryAlertComponent,
|
|
2092
|
+
SkyPageSummaryComponent,
|
|
2093
|
+
SkyPageSummaryContentComponent,
|
|
2094
|
+
SkyPageSummaryImageComponent,
|
|
2095
|
+
SkyPageSummaryKeyInfoComponent,
|
|
2096
|
+
SkyPageSummaryStatusComponent,
|
|
2097
|
+
SkyPageSummarySubtitleComponent,
|
|
2098
|
+
SkyPageSummaryTitleComponent,
|
|
2099
|
+
],
|
|
2100
|
+
}]
|
|
2101
|
+
}] });
|
|
2102
|
+
|
|
2103
|
+
/**
|
|
2104
|
+
* @internal
|
|
2105
|
+
*/
|
|
2106
|
+
class SkyTextExpandModalContext {
|
|
2107
|
+
}
|
|
2108
|
+
|
|
2109
|
+
/**
|
|
2110
|
+
* @internal
|
|
2111
|
+
*/
|
|
2112
|
+
class SkyTextExpandModalComponent {
|
|
2113
|
+
constructor(context, instance) {
|
|
2114
|
+
this.context = context;
|
|
2115
|
+
this.instance = instance;
|
|
2116
|
+
}
|
|
2117
|
+
close() {
|
|
2118
|
+
this.instance.close();
|
|
2119
|
+
}
|
|
2120
|
+
}
|
|
2121
|
+
SkyTextExpandModalComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyTextExpandModalComponent, deps: [{ token: SkyTextExpandModalContext }, { token: i2$2.SkyModalInstance }], target: i0.ɵɵFactoryTarget.Component });
|
|
2122
|
+
SkyTextExpandModalComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.2.7", type: SkyTextExpandModalComponent, selector: "sky-text-expand-modal", ngImport: i0, template: "<sky-modal>\n <sky-modal-header>{{ context.header }}</sky-modal-header>\n <sky-modal-content class=\"sky-text-expand-modal-content\">{{\n context.text\n }}</sky-modal-content>\n <sky-modal-footer>\n <button class=\"sky-btn sky-btn-link\" (click)=\"close()\">\n {{ 'skyux_text_expand_close_text' | skyLibResources }}\n </button>\n </sky-modal-footer>\n</sky-modal>\n", styles: [".sky-text-expand-ellipsis{letter-spacing:2px;white-space:nowrap}.sky-text-expand-space{white-space:normal}.sky-text-expand-see-more{white-space:nowrap;margin-left:5px}.sky-text-expand-text{margin:0;white-space:pre-wrap}.sky-text-expand-container{word-break:break-word;word-wrap:break-word;overflow:hidden;height:auto;transition:max-height .25s}.sky-text-expand-modal-content{white-space:pre-line;word-wrap:break-word}\n"], components: [{ type: i2$2.λ5, selector: "sky-modal", inputs: ["ariaRole", "tiledBody"] }, { type: i2$2.λ4, selector: "sky-modal-header" }, { type: i2$2.λ2, selector: "sky-modal-content" }, { type: i2$2.λ3, selector: "sky-modal-footer" }], pipes: { "skyLibResources": i1$1.SkyLibResourcesPipe } });
|
|
2123
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyTextExpandModalComponent, decorators: [{
|
|
2124
|
+
type: Component,
|
|
2125
|
+
args: [{ selector: 'sky-text-expand-modal', template: "<sky-modal>\n <sky-modal-header>{{ context.header }}</sky-modal-header>\n <sky-modal-content class=\"sky-text-expand-modal-content\">{{\n context.text\n }}</sky-modal-content>\n <sky-modal-footer>\n <button class=\"sky-btn sky-btn-link\" (click)=\"close()\">\n {{ 'skyux_text_expand_close_text' | skyLibResources }}\n </button>\n </sky-modal-footer>\n</sky-modal>\n", styles: [".sky-text-expand-ellipsis{letter-spacing:2px;white-space:nowrap}.sky-text-expand-space{white-space:normal}.sky-text-expand-see-more{white-space:nowrap;margin-left:5px}.sky-text-expand-text{margin:0;white-space:pre-wrap}.sky-text-expand-container{word-break:break-word;word-wrap:break-word;overflow:hidden;height:auto;transition:max-height .25s}.sky-text-expand-modal-content{white-space:pre-line;word-wrap:break-word}\n"] }]
|
|
2126
|
+
}], ctorParameters: function () { return [{ type: SkyTextExpandModalContext }, { type: i2$2.SkyModalInstance }]; } });
|
|
2127
|
+
|
|
2128
|
+
/**
|
|
2129
|
+
* @internal
|
|
2130
|
+
*/
|
|
2131
|
+
class SkyTextExpandAdapterService {
|
|
2132
|
+
constructor(rendererFactory) {
|
|
2133
|
+
this.rendererFactory = rendererFactory;
|
|
2134
|
+
this.renderer = this.rendererFactory.createRenderer(undefined, undefined);
|
|
2135
|
+
}
|
|
2136
|
+
getContainerHeight(containerEl) {
|
|
2137
|
+
return containerEl.nativeElement.offsetHeight;
|
|
2138
|
+
}
|
|
2139
|
+
setContainerHeight(containerEl, height) {
|
|
2140
|
+
if (height === undefined) {
|
|
2141
|
+
this.renderer.removeStyle(containerEl.nativeElement, 'max-height');
|
|
2142
|
+
}
|
|
2143
|
+
else {
|
|
2144
|
+
this.renderer.setStyle(containerEl.nativeElement, 'max-height', height);
|
|
2145
|
+
}
|
|
2146
|
+
}
|
|
2147
|
+
setText(textEl, text) {
|
|
2148
|
+
textEl.nativeElement.textContent = text;
|
|
2149
|
+
}
|
|
2150
|
+
}
|
|
2151
|
+
SkyTextExpandAdapterService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyTextExpandAdapterService, deps: [{ token: i0.RendererFactory2 }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
2152
|
+
SkyTextExpandAdapterService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyTextExpandAdapterService });
|
|
2153
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyTextExpandAdapterService, decorators: [{
|
|
2154
|
+
type: Injectable
|
|
2155
|
+
}], ctorParameters: function () { return [{ type: i0.RendererFactory2 }]; } });
|
|
2156
|
+
|
|
2157
|
+
/**
|
|
2158
|
+
* Auto-incrementing integer used to generate unique ids for text expand components.
|
|
2159
|
+
*/
|
|
2160
|
+
let nextId$1 = 0;
|
|
2161
|
+
class SkyTextExpandComponent {
|
|
2162
|
+
constructor(resources, modalService, textExpandAdapter) {
|
|
2163
|
+
this.resources = resources;
|
|
2164
|
+
this.modalService = modalService;
|
|
2165
|
+
this.textExpandAdapter = textExpandAdapter;
|
|
2166
|
+
/**
|
|
2167
|
+
* Specifies the maximum number of text characters to display inline when users select the link
|
|
2168
|
+
* to expand the full text. If the text exceeds this limit, then the component expands
|
|
2169
|
+
* the full text in a modal instead.
|
|
2170
|
+
*/
|
|
2171
|
+
this.maxExpandedLength = 600;
|
|
2172
|
+
/**
|
|
2173
|
+
* Specifies the maximum number of newline characters to display inline when users select
|
|
2174
|
+
* the link to expand the full text. If the text exceeds this limit, then
|
|
2175
|
+
* the component expands the full text in a modal view instead.
|
|
2176
|
+
*/
|
|
2177
|
+
this.maxExpandedNewlines = 2;
|
|
2178
|
+
/**
|
|
2179
|
+
* Indicates whether to replace newline characters in truncated text with spaces.
|
|
2180
|
+
*/
|
|
2181
|
+
this.truncateNewlines = true;
|
|
2182
|
+
this.contentSectionId = `sky-text-expand-content-${++nextId$1}`;
|
|
2183
|
+
this.isExpanded = false;
|
|
2184
|
+
this._maxLength = 200;
|
|
2185
|
+
}
|
|
2186
|
+
/**
|
|
2187
|
+
* Specifies the number of text characters to display before truncating the text.
|
|
2188
|
+
* To avoid truncating text in the middle of a word, the component looks for a space
|
|
2189
|
+
* in the 10 characters before the last character.
|
|
2190
|
+
* @default 200
|
|
2191
|
+
*/
|
|
2192
|
+
set maxLength(value) {
|
|
2193
|
+
this._maxLength = value;
|
|
2194
|
+
/* istanbul ignore else */
|
|
2195
|
+
if (this.textEl) {
|
|
2196
|
+
this.setup(this.expandedText);
|
|
2197
|
+
}
|
|
2198
|
+
}
|
|
2199
|
+
get maxLength() {
|
|
2200
|
+
return this._maxLength;
|
|
2201
|
+
}
|
|
2202
|
+
/**
|
|
2203
|
+
* Specifies the text to truncate.
|
|
2204
|
+
*/
|
|
2205
|
+
set text(value) {
|
|
2206
|
+
/* istanbul ignore else */
|
|
2207
|
+
if (this.textEl) {
|
|
2208
|
+
this.setup(value);
|
|
2209
|
+
}
|
|
2210
|
+
}
|
|
2211
|
+
textExpand() {
|
|
2212
|
+
if (this.isModal) {
|
|
2213
|
+
// Modal View
|
|
2214
|
+
/* istanbul ignore else */
|
|
2215
|
+
/* sanity check */
|
|
2216
|
+
if (!this.isExpanded) {
|
|
2217
|
+
this.modalService.open(SkyTextExpandModalComponent, [
|
|
2218
|
+
{
|
|
2219
|
+
provide: SkyTextExpandModalContext,
|
|
2220
|
+
useValue: {
|
|
2221
|
+
header: this.expandModalTitle,
|
|
2222
|
+
text: this.expandedText,
|
|
2223
|
+
},
|
|
2224
|
+
},
|
|
2225
|
+
]);
|
|
2226
|
+
}
|
|
2227
|
+
}
|
|
2228
|
+
else {
|
|
2229
|
+
// Normal View
|
|
2230
|
+
if (!this.isExpanded) {
|
|
2231
|
+
this.setContainerMaxHeight();
|
|
2232
|
+
setTimeout(() => {
|
|
2233
|
+
this.isExpanded = true;
|
|
2234
|
+
this.animateText(this.collapsedText, this.expandedText, true);
|
|
2235
|
+
}, 10);
|
|
2236
|
+
}
|
|
2237
|
+
else {
|
|
2238
|
+
this.setContainerMaxHeight();
|
|
2239
|
+
setTimeout(() => {
|
|
2240
|
+
this.isExpanded = false;
|
|
2241
|
+
this.animateText(this.expandedText, this.collapsedText, false);
|
|
2242
|
+
}, 10);
|
|
2243
|
+
}
|
|
2244
|
+
}
|
|
2245
|
+
}
|
|
2246
|
+
animationEnd() {
|
|
2247
|
+
// Ensure the correct text is displayed
|
|
2248
|
+
this.textExpandAdapter.setText(this.textEl, this.textToShow);
|
|
2249
|
+
// Set height back to auto so the browser can change the height as needed with window changes
|
|
2250
|
+
this.textExpandAdapter.setContainerHeight(this.containerEl, undefined);
|
|
2251
|
+
}
|
|
2252
|
+
ngAfterContentInit() {
|
|
2253
|
+
forkJoin([
|
|
2254
|
+
this.resources.getString('skyux_text_expand_see_more'),
|
|
2255
|
+
this.resources.getString('skyux_text_expand_see_less'),
|
|
2256
|
+
])
|
|
2257
|
+
.pipe(take(1))
|
|
2258
|
+
.subscribe((resources) => {
|
|
2259
|
+
this.seeMoreText = resources[0];
|
|
2260
|
+
this.seeLessText = resources[1];
|
|
2261
|
+
this.setup(this.expandedText);
|
|
2262
|
+
/* istanbul ignore else */
|
|
2263
|
+
if (!this.expandModalTitle) {
|
|
2264
|
+
this.resources
|
|
2265
|
+
.getString('skyux_text_expand_modal_title')
|
|
2266
|
+
.pipe(take(1))
|
|
2267
|
+
.subscribe((resource) => {
|
|
2268
|
+
this.expandModalTitle = resource;
|
|
2269
|
+
});
|
|
2270
|
+
}
|
|
2271
|
+
});
|
|
2272
|
+
}
|
|
2273
|
+
setContainerMaxHeight() {
|
|
2274
|
+
// ensure everything is reset
|
|
2275
|
+
this.animationEnd();
|
|
2276
|
+
/* Before animation is kicked off, ensure that a maxHeight exists */
|
|
2277
|
+
/* Once we have support for angular v4 animations with parameters we can use that instead */
|
|
2278
|
+
const currentHeight = this.textExpandAdapter.getContainerHeight(this.containerEl);
|
|
2279
|
+
this.textExpandAdapter.setContainerHeight(this.containerEl, `${currentHeight}px`);
|
|
2280
|
+
}
|
|
2281
|
+
setup(value) {
|
|
2282
|
+
if (value) {
|
|
2283
|
+
this.newlineCount = this.getNewlineCount(value);
|
|
2284
|
+
this.collapsedText = this.getTruncatedText(value, this.maxLength);
|
|
2285
|
+
this.expandedText = value;
|
|
2286
|
+
if (this.collapsedText !== value) {
|
|
2287
|
+
this.buttonText = this.seeMoreText;
|
|
2288
|
+
this.isExpanded = false;
|
|
2289
|
+
this.expandable = true;
|
|
2290
|
+
this.isModal =
|
|
2291
|
+
this.newlineCount > this.maxExpandedNewlines ||
|
|
2292
|
+
this.expandedText.length > this.maxExpandedLength;
|
|
2293
|
+
}
|
|
2294
|
+
else {
|
|
2295
|
+
this.expandable = false;
|
|
2296
|
+
}
|
|
2297
|
+
this.textToShow = this.collapsedText;
|
|
2298
|
+
}
|
|
2299
|
+
else {
|
|
2300
|
+
this.textToShow = '';
|
|
2301
|
+
this.expandable = false;
|
|
2302
|
+
}
|
|
2303
|
+
this.textExpandAdapter.setText(this.textEl, this.textToShow);
|
|
2304
|
+
}
|
|
2305
|
+
getNewlineCount(value) {
|
|
2306
|
+
const matches = value.match(/\n/gi);
|
|
2307
|
+
if (matches) {
|
|
2308
|
+
return matches.length;
|
|
2309
|
+
}
|
|
2310
|
+
return 0;
|
|
2311
|
+
}
|
|
2312
|
+
getTruncatedText(value, length) {
|
|
2313
|
+
let i;
|
|
2314
|
+
if (this.truncateNewlines) {
|
|
2315
|
+
value = value.replace(/\n+/gi, ' ');
|
|
2316
|
+
}
|
|
2317
|
+
// Jump ahead one character and see if it's a space, and if it isn't,
|
|
2318
|
+
// back up to the first space and break there so a word doesn't get cut
|
|
2319
|
+
// in half.
|
|
2320
|
+
if (length < value.length) {
|
|
2321
|
+
for (i = length; i > length - 10; i--) {
|
|
2322
|
+
if (/\s/.test(value.charAt(i))) {
|
|
2323
|
+
length = i;
|
|
2324
|
+
break;
|
|
2325
|
+
}
|
|
2326
|
+
}
|
|
2327
|
+
}
|
|
2328
|
+
return value.substr(0, length);
|
|
2329
|
+
}
|
|
2330
|
+
animateText(previousText, newText, expanding) {
|
|
2331
|
+
const adapter = this.textExpandAdapter;
|
|
2332
|
+
const container = this.containerEl;
|
|
2333
|
+
// Reset max height
|
|
2334
|
+
adapter.setContainerHeight(container, undefined);
|
|
2335
|
+
// Measure the current height so we can animate from it.
|
|
2336
|
+
const currentHeight = adapter.getContainerHeight(container);
|
|
2337
|
+
this.textToShow = newText;
|
|
2338
|
+
adapter.setText(this.textEl, this.textToShow);
|
|
2339
|
+
this.buttonText = expanding ? this.seeLessText : this.seeMoreText;
|
|
2340
|
+
// Measure the new height so we can animate to it.
|
|
2341
|
+
const newHeight = adapter.getContainerHeight(container);
|
|
2342
|
+
/* istanbul ignore if */
|
|
2343
|
+
if (newHeight < currentHeight) {
|
|
2344
|
+
// The new text is smaller than the old text, so put the old text back before doing
|
|
2345
|
+
// the collapse animation to avoid showing a big chunk of whitespace.
|
|
2346
|
+
adapter.setText(this.textEl, previousText);
|
|
2347
|
+
}
|
|
2348
|
+
adapter.setContainerHeight(container, `${currentHeight}px`);
|
|
2349
|
+
// This timeout is necessary due to the browser needing to pick up the non-auto height being set
|
|
2350
|
+
// in order to do the transtion in height correctly. Without it the transition does not fire.
|
|
2351
|
+
setTimeout(() => {
|
|
2352
|
+
adapter.setContainerHeight(container, `${newHeight}px`);
|
|
2353
|
+
/* This resets values if the transition does not get kicked off */
|
|
2354
|
+
setTimeout(() => {
|
|
2355
|
+
this.animationEnd();
|
|
2356
|
+
}, 500);
|
|
2357
|
+
}, 10);
|
|
2358
|
+
}
|
|
2359
|
+
}
|
|
2360
|
+
SkyTextExpandComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyTextExpandComponent, deps: [{ token: i1$1.SkyLibResourcesService }, { token: i2$2.SkyModalService }, { token: SkyTextExpandAdapterService }], target: i0.ɵɵFactoryTarget.Component });
|
|
2361
|
+
SkyTextExpandComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.2.7", type: SkyTextExpandComponent, selector: "sky-text-expand", inputs: { expandModalTitle: "expandModalTitle", maxExpandedLength: "maxExpandedLength", maxExpandedNewlines: "maxExpandedNewlines", maxLength: "maxLength", text: "text", truncateNewlines: "truncateNewlines" }, providers: [SkyTextExpandAdapterService], viewQueries: [{ propertyName: "containerEl", first: true, predicate: ["container"], descendants: true, read: ElementRef, static: true }, { propertyName: "textEl", first: true, predicate: ["text"], descendants: true, read: ElementRef, static: true }], ngImport: i0, template: "<div\n class=\"sky-text-expand-container\"\n (transitionend)=\"animationEnd()\"\n #container\n>\n <span class=\"sky-text-expand-text\" [id]=\"contentSectionId\" #text></span>\n <span class=\"sky-text-expand-ellipsis\" *ngIf=\"!isExpanded && expandable\"\n >...\n </span>\n <button\n *ngIf=\"expandable\"\n type=\"button\"\n class=\"sky-btn sky-btn-link-inline sky-text-expand-see-more\"\n [attr.aria-expanded]=\"isModal ? undefined : isExpanded\"\n [attr.aria-controls]=\"isModal ? undefined : contentSectionId\"\n [attr.aria-haspopup]=\"isModal ? 'dialog' : undefined\"\n (click)=\"textExpand()\"\n >\n {{ buttonText }}\n </button>\n</div>\n", styles: [".sky-text-expand-ellipsis{letter-spacing:2px;white-space:nowrap}.sky-text-expand-space{white-space:normal}.sky-text-expand-see-more{white-space:nowrap;margin-left:5px}.sky-text-expand-text{margin:0;white-space:pre-wrap}.sky-text-expand-container{word-break:break-word;word-wrap:break-word;overflow:hidden;height:auto;transition:max-height .25s}.sky-text-expand-modal-content{white-space:pre-line;word-wrap:break-word}\n"], directives: [{ type: i3.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }] });
|
|
2362
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyTextExpandComponent, decorators: [{
|
|
2363
|
+
type: Component,
|
|
2364
|
+
args: [{ selector: 'sky-text-expand', providers: [SkyTextExpandAdapterService], template: "<div\n class=\"sky-text-expand-container\"\n (transitionend)=\"animationEnd()\"\n #container\n>\n <span class=\"sky-text-expand-text\" [id]=\"contentSectionId\" #text></span>\n <span class=\"sky-text-expand-ellipsis\" *ngIf=\"!isExpanded && expandable\"\n >...\n </span>\n <button\n *ngIf=\"expandable\"\n type=\"button\"\n class=\"sky-btn sky-btn-link-inline sky-text-expand-see-more\"\n [attr.aria-expanded]=\"isModal ? undefined : isExpanded\"\n [attr.aria-controls]=\"isModal ? undefined : contentSectionId\"\n [attr.aria-haspopup]=\"isModal ? 'dialog' : undefined\"\n (click)=\"textExpand()\"\n >\n {{ buttonText }}\n </button>\n</div>\n", styles: [".sky-text-expand-ellipsis{letter-spacing:2px;white-space:nowrap}.sky-text-expand-space{white-space:normal}.sky-text-expand-see-more{white-space:nowrap;margin-left:5px}.sky-text-expand-text{margin:0;white-space:pre-wrap}.sky-text-expand-container{word-break:break-word;word-wrap:break-word;overflow:hidden;height:auto;transition:max-height .25s}.sky-text-expand-modal-content{white-space:pre-line;word-wrap:break-word}\n"] }]
|
|
2365
|
+
}], ctorParameters: function () { return [{ type: i1$1.SkyLibResourcesService }, { type: i2$2.SkyModalService }, { type: SkyTextExpandAdapterService }]; }, propDecorators: { expandModalTitle: [{
|
|
2366
|
+
type: Input
|
|
2367
|
+
}], maxExpandedLength: [{
|
|
2368
|
+
type: Input
|
|
2369
|
+
}], maxExpandedNewlines: [{
|
|
2370
|
+
type: Input
|
|
2371
|
+
}], maxLength: [{
|
|
2372
|
+
type: Input
|
|
2373
|
+
}], text: [{
|
|
2374
|
+
type: Input
|
|
2375
|
+
}], truncateNewlines: [{
|
|
2376
|
+
type: Input
|
|
2377
|
+
}], containerEl: [{
|
|
2378
|
+
type: ViewChild,
|
|
2379
|
+
args: ['container', {
|
|
2380
|
+
read: ElementRef,
|
|
2381
|
+
static: true,
|
|
2382
|
+
}]
|
|
2383
|
+
}], textEl: [{
|
|
2384
|
+
type: ViewChild,
|
|
2385
|
+
args: ['text', {
|
|
2386
|
+
read: ElementRef,
|
|
2387
|
+
static: true,
|
|
2388
|
+
}]
|
|
2389
|
+
}] } });
|
|
2390
|
+
|
|
2391
|
+
class SkyTextExpandModule {
|
|
2392
|
+
}
|
|
2393
|
+
SkyTextExpandModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyTextExpandModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
2394
|
+
SkyTextExpandModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyTextExpandModule, declarations: [SkyTextExpandComponent, SkyTextExpandModalComponent], imports: [SkyI18nModule,
|
|
2395
|
+
SkyLayoutResourcesModule,
|
|
2396
|
+
SkyModalModule,
|
|
2397
|
+
CommonModule], exports: [SkyTextExpandComponent] });
|
|
2398
|
+
SkyTextExpandModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyTextExpandModule, imports: [[
|
|
2399
|
+
SkyI18nModule,
|
|
2400
|
+
SkyLayoutResourcesModule,
|
|
2401
|
+
SkyModalModule,
|
|
2402
|
+
CommonModule,
|
|
2403
|
+
]] });
|
|
2404
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyTextExpandModule, decorators: [{
|
|
2405
|
+
type: NgModule,
|
|
2406
|
+
args: [{
|
|
2407
|
+
declarations: [SkyTextExpandComponent, SkyTextExpandModalComponent],
|
|
2408
|
+
imports: [
|
|
2409
|
+
SkyI18nModule,
|
|
2410
|
+
SkyLayoutResourcesModule,
|
|
2411
|
+
SkyModalModule,
|
|
2412
|
+
CommonModule,
|
|
2413
|
+
],
|
|
2414
|
+
exports: [SkyTextExpandComponent],
|
|
2415
|
+
}]
|
|
2416
|
+
}] });
|
|
2417
|
+
|
|
2418
|
+
/**
|
|
2419
|
+
* @internal
|
|
2420
|
+
*/
|
|
2421
|
+
class SkyTextExpandRepeaterAdapterService {
|
|
2422
|
+
constructor(rendererFactory) {
|
|
2423
|
+
this.rendererFactory = rendererFactory;
|
|
2424
|
+
this.renderer = this.rendererFactory.createRenderer(undefined, undefined);
|
|
2425
|
+
}
|
|
2426
|
+
getItems(elRef) {
|
|
2427
|
+
return elRef.nativeElement.querySelectorAll('.sky-text-expand-repeater-item');
|
|
2428
|
+
}
|
|
2429
|
+
hideItem(item) {
|
|
2430
|
+
this.renderer.setStyle(item, 'display', 'none');
|
|
2431
|
+
}
|
|
2432
|
+
showItem(item) {
|
|
2433
|
+
this.renderer.setStyle(item, 'display', 'list-item');
|
|
2434
|
+
}
|
|
2435
|
+
getContainerHeight(containerEl) {
|
|
2436
|
+
return containerEl.nativeElement.offsetHeight;
|
|
2437
|
+
}
|
|
2438
|
+
setContainerHeight(containerEl, height) {
|
|
2439
|
+
if (height === undefined) {
|
|
2440
|
+
this.renderer.removeStyle(containerEl.nativeElement, 'max-height');
|
|
2441
|
+
}
|
|
2442
|
+
else {
|
|
2443
|
+
this.renderer.setStyle(containerEl.nativeElement, 'max-height', height);
|
|
2444
|
+
}
|
|
2445
|
+
}
|
|
2446
|
+
}
|
|
2447
|
+
SkyTextExpandRepeaterAdapterService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyTextExpandRepeaterAdapterService, deps: [{ token: i0.RendererFactory2 }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
2448
|
+
SkyTextExpandRepeaterAdapterService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyTextExpandRepeaterAdapterService });
|
|
2449
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyTextExpandRepeaterAdapterService, decorators: [{
|
|
2450
|
+
type: Injectable
|
|
2451
|
+
}], ctorParameters: function () { return [{ type: i0.RendererFactory2 }]; } });
|
|
2452
|
+
|
|
2453
|
+
/**
|
|
2454
|
+
* Auto-incrementing integer used to generate unique ids for text expand repeater components.
|
|
2455
|
+
*/
|
|
2456
|
+
let nextId = 0;
|
|
2457
|
+
class SkyTextExpandRepeaterComponent {
|
|
2458
|
+
constructor(resources, elRef, textExpandRepeaterAdapter, changeDetector) {
|
|
2459
|
+
this.resources = resources;
|
|
2460
|
+
this.elRef = elRef;
|
|
2461
|
+
this.textExpandRepeaterAdapter = textExpandRepeaterAdapter;
|
|
2462
|
+
this.changeDetector = changeDetector;
|
|
2463
|
+
/**
|
|
2464
|
+
* Specifies the style of bullet to use
|
|
2465
|
+
* @default "unordered"
|
|
2466
|
+
*/
|
|
2467
|
+
this.listStyle = 'unordered';
|
|
2468
|
+
this.contentSectionId = `sky-text-expand-repeater-content-${++nextId}`;
|
|
2469
|
+
this.isExpanded = false;
|
|
2470
|
+
}
|
|
2471
|
+
ngAfterViewInit() {
|
|
2472
|
+
if (this.contentItems) {
|
|
2473
|
+
this.items = this.textExpandRepeaterAdapter.getItems(this.elRef);
|
|
2474
|
+
for (let i = this.maxItems; i < this.contentItems.length; i++) {
|
|
2475
|
+
this.textExpandRepeaterAdapter.hideItem(this.items[i]);
|
|
2476
|
+
}
|
|
2477
|
+
}
|
|
2478
|
+
forkJoin([
|
|
2479
|
+
this.resources.getString('skyux_text_expand_see_more'),
|
|
2480
|
+
this.resources.getString('skyux_text_expand_see_less'),
|
|
2481
|
+
])
|
|
2482
|
+
.pipe(take(1))
|
|
2483
|
+
.subscribe((resources) => {
|
|
2484
|
+
this.seeMoreText = resources[0];
|
|
2485
|
+
this.seeLessText = resources[1];
|
|
2486
|
+
/* sanity check */
|
|
2487
|
+
/* istanbul ignore else */
|
|
2488
|
+
if (!this.isExpanded) {
|
|
2489
|
+
this.buttonText = this.seeMoreText;
|
|
2490
|
+
}
|
|
2491
|
+
else {
|
|
2492
|
+
this.buttonText = this.seeLessText;
|
|
2493
|
+
}
|
|
2494
|
+
this.changeDetector.detectChanges();
|
|
2495
|
+
});
|
|
2496
|
+
}
|
|
2497
|
+
ngOnChanges(changes) {
|
|
2498
|
+
/* istanbul ignore else */
|
|
2499
|
+
if (changes.maxItems || changes.data) {
|
|
2500
|
+
this.setup(this.data);
|
|
2501
|
+
}
|
|
2502
|
+
}
|
|
2503
|
+
animationEnd() {
|
|
2504
|
+
// Ensure the correct items are displayed
|
|
2505
|
+
if (!this.isExpanded) {
|
|
2506
|
+
for (let i = this.maxItems; i < this.contentItems.length; i++) {
|
|
2507
|
+
this.textExpandRepeaterAdapter.hideItem(this.items[i]);
|
|
2508
|
+
}
|
|
2509
|
+
}
|
|
2510
|
+
// Set height back to auto so the browser can change the height as needed with window changes
|
|
2511
|
+
this.textExpandRepeaterAdapter.setContainerHeight(this.containerEl, undefined);
|
|
2512
|
+
}
|
|
2513
|
+
repeaterExpand() {
|
|
2514
|
+
if (!this.isExpanded) {
|
|
2515
|
+
this.setContainerMaxHeight();
|
|
2516
|
+
setTimeout(() => {
|
|
2517
|
+
this.isExpanded = true;
|
|
2518
|
+
this.animateRepeater(true);
|
|
2519
|
+
});
|
|
2520
|
+
}
|
|
2521
|
+
else {
|
|
2522
|
+
this.setContainerMaxHeight();
|
|
2523
|
+
setTimeout(() => {
|
|
2524
|
+
this.isExpanded = false;
|
|
2525
|
+
this.animateRepeater(false);
|
|
2526
|
+
});
|
|
2527
|
+
}
|
|
2528
|
+
}
|
|
2529
|
+
setContainerMaxHeight() {
|
|
2530
|
+
// ensure everything is reset
|
|
2531
|
+
this.animationEnd();
|
|
2532
|
+
/* Before animation is kicked off, ensure that a maxHeight exists */
|
|
2533
|
+
/* Once we have support for angular v4 animations with parameters we can use that instead */
|
|
2534
|
+
const currentHeight = this.textExpandRepeaterAdapter.getContainerHeight(this.containerEl);
|
|
2535
|
+
this.textExpandRepeaterAdapter.setContainerHeight(this.containerEl, `${currentHeight}px`);
|
|
2536
|
+
}
|
|
2537
|
+
animateRepeater(expanding) {
|
|
2538
|
+
const adapter = this.textExpandRepeaterAdapter;
|
|
2539
|
+
const container = this.containerEl;
|
|
2540
|
+
adapter.setContainerHeight(container, undefined);
|
|
2541
|
+
const currentHeight = adapter.getContainerHeight(container);
|
|
2542
|
+
for (let i = this.maxItems; i < this.contentItems.length; i++) {
|
|
2543
|
+
if (!expanding) {
|
|
2544
|
+
adapter.hideItem(this.items[i]);
|
|
2545
|
+
}
|
|
2546
|
+
else {
|
|
2547
|
+
adapter.showItem(this.items[i]);
|
|
2548
|
+
}
|
|
2549
|
+
}
|
|
2550
|
+
const newHeight = adapter.getContainerHeight(container);
|
|
2551
|
+
if (!expanding) {
|
|
2552
|
+
this.buttonText = this.seeMoreText;
|
|
2553
|
+
}
|
|
2554
|
+
else {
|
|
2555
|
+
this.buttonText = this.seeLessText;
|
|
2556
|
+
}
|
|
2557
|
+
if (newHeight < currentHeight) {
|
|
2558
|
+
// The new text is smaller than the old text, so put the old text back before doing
|
|
2559
|
+
// the collapse animation to avoid showing a big chunk of whitespace.
|
|
2560
|
+
for (let i = this.maxItems; i < this.contentItems.length; i++) {
|
|
2561
|
+
adapter.showItem(this.items[i]);
|
|
2562
|
+
}
|
|
2563
|
+
}
|
|
2564
|
+
adapter.setContainerHeight(container, `${currentHeight}px`);
|
|
2565
|
+
// This timeout is necessary due to the browser needing to pick up the non-auto height being set
|
|
2566
|
+
// in order to do the transtion in height correctly. Without it the transition does not fire.
|
|
2567
|
+
setTimeout(() => {
|
|
2568
|
+
adapter.setContainerHeight(container, `${newHeight}px`);
|
|
2569
|
+
/* This resets values if the transition does not get kicked off */
|
|
2570
|
+
setTimeout(() => {
|
|
2571
|
+
this.animationEnd();
|
|
2572
|
+
}, 500);
|
|
2573
|
+
}, 10);
|
|
2574
|
+
}
|
|
2575
|
+
setup(value) {
|
|
2576
|
+
if (value) {
|
|
2577
|
+
const length = value.length;
|
|
2578
|
+
if (length > this.maxItems) {
|
|
2579
|
+
this.expandable = true;
|
|
2580
|
+
this.buttonText = this.seeMoreText;
|
|
2581
|
+
this.isExpanded = false;
|
|
2582
|
+
}
|
|
2583
|
+
else {
|
|
2584
|
+
this.expandable = false;
|
|
2585
|
+
}
|
|
2586
|
+
this.contentItems = value;
|
|
2587
|
+
}
|
|
2588
|
+
else {
|
|
2589
|
+
this.contentItems = undefined;
|
|
2590
|
+
this.expandable = false;
|
|
2591
|
+
}
|
|
2592
|
+
}
|
|
2593
|
+
}
|
|
2594
|
+
SkyTextExpandRepeaterComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyTextExpandRepeaterComponent, deps: [{ token: i1$1.SkyLibResourcesService }, { token: i0.ElementRef }, { token: SkyTextExpandRepeaterAdapterService }, { token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
|
|
2595
|
+
SkyTextExpandRepeaterComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.2.7", type: SkyTextExpandRepeaterComponent, selector: "sky-text-expand-repeater", inputs: { data: "data", itemTemplate: "itemTemplate", listStyle: "listStyle", maxItems: "maxItems" }, providers: [SkyTextExpandRepeaterAdapterService], viewQueries: [{ propertyName: "containerEl", first: true, predicate: ["container"], descendants: true, read: ElementRef }], usesOnChanges: true, ngImport: i0, template: "<div class=\"sky-text-expand-repeater\">\n <ul\n *ngIf=\"listStyle !== 'ordered'\"\n class=\"sky-text-expand-repeater-container\"\n [id]=\"contentSectionId\"\n (transitionend)=\"animationEnd()\"\n [ngClass]=\"{\n 'sky-text-expand-repeater-list-style-none': listStyle === 'unstyled'\n }\"\n #container\n >\n <ng-template [ngTemplateOutlet]=\"listItemTemplate\"></ng-template>\n </ul>\n <ol\n *ngIf=\"listStyle === 'ordered'\"\n class=\"sky-text-expand-repeater-container\"\n [id]=\"contentSectionId\"\n (transitionend)=\"animationEnd()\"\n #container\n >\n <ng-template [ngTemplateOutlet]=\"listItemTemplate\"></ng-template>\n </ol>\n <button\n *ngIf=\"expandable\"\n type=\"button\"\n class=\"sky-btn sky-btn-link-inline sky-text-expand-repeater-see-more\"\n [attr.aria-expanded]=\"isExpanded\"\n [attr.aria-controls]=\"contentSectionId\"\n (click)=\"repeaterExpand()\"\n [ngClass]=\"{\n 'sky-text-expand-repeater-see-more-list-style-none':\n listStyle === 'unstyled'\n }\"\n >\n {{ buttonText }}\n </button>\n</div>\n\n<ng-template let-item #defaultItemTemplate>\n {{ item }}\n</ng-template>\n\n<ng-template #listItemTemplate>\n <li *ngFor=\"let item of contentItems\" class=\"sky-text-expand-repeater-item\">\n <ng-template\n [ngTemplateOutlet]=\"itemTemplate || defaultItemTemplate\"\n [ngTemplateOutletContext]=\"{ $implicit: item }\"\n ></ng-template>\n </li>\n</ng-template>\n", styles: [".sky-text-expand-repeater-container{overflow-y:hidden;height:auto;margin-bottom:0;transition:max-height .25s}.sky-text-expand-repeater-see-more{white-space:nowrap;margin-left:40px}.sky-text-expand-repeater-list-style-none{list-style-type:none;padding-left:0}.sky-text-expand-repeater-see-more-list-style-none{margin-left:0}\n"], directives: [{ type: i3.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i3.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { type: i3.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet"] }, { type: i3.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }] });
|
|
2596
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyTextExpandRepeaterComponent, decorators: [{
|
|
2597
|
+
type: Component,
|
|
2598
|
+
args: [{ selector: 'sky-text-expand-repeater', providers: [SkyTextExpandRepeaterAdapterService], template: "<div class=\"sky-text-expand-repeater\">\n <ul\n *ngIf=\"listStyle !== 'ordered'\"\n class=\"sky-text-expand-repeater-container\"\n [id]=\"contentSectionId\"\n (transitionend)=\"animationEnd()\"\n [ngClass]=\"{\n 'sky-text-expand-repeater-list-style-none': listStyle === 'unstyled'\n }\"\n #container\n >\n <ng-template [ngTemplateOutlet]=\"listItemTemplate\"></ng-template>\n </ul>\n <ol\n *ngIf=\"listStyle === 'ordered'\"\n class=\"sky-text-expand-repeater-container\"\n [id]=\"contentSectionId\"\n (transitionend)=\"animationEnd()\"\n #container\n >\n <ng-template [ngTemplateOutlet]=\"listItemTemplate\"></ng-template>\n </ol>\n <button\n *ngIf=\"expandable\"\n type=\"button\"\n class=\"sky-btn sky-btn-link-inline sky-text-expand-repeater-see-more\"\n [attr.aria-expanded]=\"isExpanded\"\n [attr.aria-controls]=\"contentSectionId\"\n (click)=\"repeaterExpand()\"\n [ngClass]=\"{\n 'sky-text-expand-repeater-see-more-list-style-none':\n listStyle === 'unstyled'\n }\"\n >\n {{ buttonText }}\n </button>\n</div>\n\n<ng-template let-item #defaultItemTemplate>\n {{ item }}\n</ng-template>\n\n<ng-template #listItemTemplate>\n <li *ngFor=\"let item of contentItems\" class=\"sky-text-expand-repeater-item\">\n <ng-template\n [ngTemplateOutlet]=\"itemTemplate || defaultItemTemplate\"\n [ngTemplateOutletContext]=\"{ $implicit: item }\"\n ></ng-template>\n </li>\n</ng-template>\n", styles: [".sky-text-expand-repeater-container{overflow-y:hidden;height:auto;margin-bottom:0;transition:max-height .25s}.sky-text-expand-repeater-see-more{white-space:nowrap;margin-left:40px}.sky-text-expand-repeater-list-style-none{list-style-type:none;padding-left:0}.sky-text-expand-repeater-see-more-list-style-none{margin-left:0}\n"] }]
|
|
2599
|
+
}], ctorParameters: function () { return [{ type: i1$1.SkyLibResourcesService }, { type: i0.ElementRef }, { type: SkyTextExpandRepeaterAdapterService }, { type: i0.ChangeDetectorRef }]; }, propDecorators: { data: [{
|
|
2600
|
+
type: Input
|
|
2601
|
+
}], itemTemplate: [{
|
|
2602
|
+
type: Input
|
|
2603
|
+
}], listStyle: [{
|
|
2604
|
+
type: Input
|
|
2605
|
+
}], maxItems: [{
|
|
2606
|
+
type: Input
|
|
2607
|
+
}], containerEl: [{
|
|
2608
|
+
type: ViewChild,
|
|
2609
|
+
args: ['container', {
|
|
2610
|
+
read: ElementRef,
|
|
2611
|
+
static: false,
|
|
2612
|
+
}]
|
|
2613
|
+
}] } });
|
|
2614
|
+
|
|
2615
|
+
class SkyTextExpandRepeaterModule {
|
|
2616
|
+
}
|
|
2617
|
+
SkyTextExpandRepeaterModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyTextExpandRepeaterModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
2618
|
+
SkyTextExpandRepeaterModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyTextExpandRepeaterModule, declarations: [SkyTextExpandRepeaterComponent], imports: [SkyI18nModule, SkyLayoutResourcesModule, CommonModule], exports: [SkyTextExpandRepeaterComponent] });
|
|
2619
|
+
SkyTextExpandRepeaterModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyTextExpandRepeaterModule, imports: [[SkyI18nModule, SkyLayoutResourcesModule, CommonModule]] });
|
|
2620
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyTextExpandRepeaterModule, decorators: [{
|
|
2621
|
+
type: NgModule,
|
|
2622
|
+
args: [{
|
|
2623
|
+
declarations: [SkyTextExpandRepeaterComponent],
|
|
2624
|
+
imports: [SkyI18nModule, SkyLayoutResourcesModule, CommonModule],
|
|
2625
|
+
exports: [SkyTextExpandRepeaterComponent],
|
|
2626
|
+
}]
|
|
2627
|
+
}] });
|
|
2628
|
+
|
|
2629
|
+
/**
|
|
2630
|
+
* Specifies a container for an item in the toolbar.
|
|
2631
|
+
*/
|
|
2632
|
+
class SkyToolbarItemComponent {
|
|
2633
|
+
}
|
|
2634
|
+
SkyToolbarItemComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyToolbarItemComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
2635
|
+
SkyToolbarItemComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.2.7", type: SkyToolbarItemComponent, selector: "sky-toolbar-item", ngImport: i0, template: "<div class=\"sky-toolbar-item\">\n <ng-content></ng-content>\n</div>\n", styles: [".sky-toolbar-item{margin-right:5px;margin-bottom:5px}:host-context(.sky-theme-modern) .sky-toolbar-item{margin-top:5px;margin-bottom:5px;margin-right:10px}:host-context(.sky-theme-modern) .sky-toolbar-item ::ng-deep .sky-btn{padding-left:10px;padding-right:10px}:host-context(.sky-theme-modern) .sky-toolbar-item ::ng-deep .sky-btn.sky-btn-default:not(:disabled){background-color:transparent;border:none}:host-context(.sky-theme-modern) .sky-toolbar-item ::ng-deep .sky-btn.sky-btn-default:not(:disabled):not(:hover):not(:active):not(:focus){box-shadow:inset 0 0 0 1px transparent}.sky-theme-modern .sky-toolbar-item{margin-top:5px;margin-bottom:5px;margin-right:10px}.sky-theme-modern .sky-toolbar-item ::ng-deep .sky-btn{padding-left:10px;padding-right:10px}.sky-theme-modern .sky-toolbar-item ::ng-deep .sky-btn.sky-btn-default:not(:disabled){background-color:transparent;border:none}.sky-theme-modern .sky-toolbar-item ::ng-deep .sky-btn.sky-btn-default:not(:disabled):not(:hover):not(:active):not(:focus){box-shadow:inset 0 0 0 1px transparent}\n"] });
|
|
2636
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyToolbarItemComponent, decorators: [{
|
|
2637
|
+
type: Component,
|
|
2638
|
+
args: [{ selector: 'sky-toolbar-item', template: "<div class=\"sky-toolbar-item\">\n <ng-content></ng-content>\n</div>\n", styles: [".sky-toolbar-item{margin-right:5px;margin-bottom:5px}:host-context(.sky-theme-modern) .sky-toolbar-item{margin-top:5px;margin-bottom:5px;margin-right:10px}:host-context(.sky-theme-modern) .sky-toolbar-item ::ng-deep .sky-btn{padding-left:10px;padding-right:10px}:host-context(.sky-theme-modern) .sky-toolbar-item ::ng-deep .sky-btn.sky-btn-default:not(:disabled){background-color:transparent;border:none}:host-context(.sky-theme-modern) .sky-toolbar-item ::ng-deep .sky-btn.sky-btn-default:not(:disabled):not(:hover):not(:active):not(:focus){box-shadow:inset 0 0 0 1px transparent}.sky-theme-modern .sky-toolbar-item{margin-top:5px;margin-bottom:5px;margin-right:10px}.sky-theme-modern .sky-toolbar-item ::ng-deep .sky-btn{padding-left:10px;padding-right:10px}.sky-theme-modern .sky-toolbar-item ::ng-deep .sky-btn.sky-btn-default:not(:disabled){background-color:transparent;border:none}.sky-theme-modern .sky-toolbar-item ::ng-deep .sky-btn.sky-btn-default:not(:disabled):not(:hover):not(:active):not(:focus){box-shadow:inset 0 0 0 1px transparent}\n"] }]
|
|
2639
|
+
}] });
|
|
2640
|
+
|
|
2641
|
+
/**
|
|
2642
|
+
* Specifies a section to group items within the toolbar. The section displays items in a separate horizontal row.
|
|
2643
|
+
*/
|
|
2644
|
+
class SkyToolbarSectionComponent {
|
|
2645
|
+
}
|
|
2646
|
+
SkyToolbarSectionComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyToolbarSectionComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
2647
|
+
SkyToolbarSectionComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.2.7", type: SkyToolbarSectionComponent, selector: "sky-toolbar-section", ngImport: i0, template: "<div class=\"sky-toolbar-section\">\n <div class=\"sky-toolbar-section-items\">\n <ng-content></ng-content>\n </div>\n <ng-content select=\"sky-toolbar-view-actions\"></ng-content>\n</div>\n", styles: [".sky-toolbar-section{display:flex;flex-wrap:nowrap;padding:5px 10px 0;min-height:49px;align-items:center;position:relative;overflow-x:auto}.sky-toolbar-section-items{display:flex;flex-wrap:wrap;align-items:center}:host-context(.sky-theme-modern) .sky-toolbar-section{padding:10px 0}.sky-theme-modern .sky-toolbar-section{padding:10px 0}\n"] });
|
|
2648
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyToolbarSectionComponent, decorators: [{
|
|
2649
|
+
type: Component,
|
|
2650
|
+
args: [{ selector: 'sky-toolbar-section', template: "<div class=\"sky-toolbar-section\">\n <div class=\"sky-toolbar-section-items\">\n <ng-content></ng-content>\n </div>\n <ng-content select=\"sky-toolbar-view-actions\"></ng-content>\n</div>\n", styles: [".sky-toolbar-section{display:flex;flex-wrap:nowrap;padding:5px 10px 0;min-height:49px;align-items:center;position:relative;overflow-x:auto}.sky-toolbar-section-items{display:flex;flex-wrap:wrap;align-items:center}:host-context(.sky-theme-modern) .sky-toolbar-section{padding:10px 0}.sky-theme-modern .sky-toolbar-section{padding:10px 0}\n"] }]
|
|
2651
|
+
}] });
|
|
2652
|
+
|
|
2653
|
+
/**
|
|
2654
|
+
* Adds a section on the right side of the toolbar for items that substantially alter
|
|
2655
|
+
* the view of the content container. This includes simple filters and view switchers.
|
|
2656
|
+
*/
|
|
2657
|
+
class SkyToolbarViewActionsComponent {
|
|
2658
|
+
}
|
|
2659
|
+
SkyToolbarViewActionsComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyToolbarViewActionsComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
2660
|
+
SkyToolbarViewActionsComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.2.7", type: SkyToolbarViewActionsComponent, selector: "sky-toolbar-view-actions", ngImport: i0, template: "<div class=\"sky-toolbar-view-actions\">\n <ng-content></ng-content>\n</div>\n", styles: [":host{margin-left:auto}.sky-toolbar-view-actions{display:flex;align-items:center;margin-bottom:5px}.sky-toolbar-view-actions ::ng-deep>:not(:last-child){margin-right:5px}:host-context(.sky-theme-modern) .sky-toolbar-view-actions{margin-bottom:0}:host-context(.sky-theme-modern) .sky-toolbar-view-actions ::ng-deep>:not(:last-child){margin-top:5px;margin-bottom:5px;margin-right:10px}:host-context(.sky-theme-modern) .sky-toolbar-view-actions ::ng-deep .sky-btn{background-color:transparent;border:none;padding-left:10px;padding-right:10px}:host-context(.sky-theme-modern) .sky-toolbar-view-actions ::ng-deep .sky-btn:not(:hover):not(:active):not(:focus){box-shadow:inset 0 0 0 1px transparent}.sky-theme-modern .sky-toolbar-view-actions{margin-bottom:0}.sky-theme-modern .sky-toolbar-view-actions ::ng-deep>:not(:last-child){margin-top:5px;margin-bottom:5px;margin-right:10px}.sky-theme-modern .sky-toolbar-view-actions ::ng-deep .sky-btn{background-color:transparent;border:none;padding-left:10px;padding-right:10px}.sky-theme-modern .sky-toolbar-view-actions ::ng-deep .sky-btn:not(:hover):not(:active):not(:focus){box-shadow:inset 0 0 0 1px transparent}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
2661
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyToolbarViewActionsComponent, decorators: [{
|
|
2662
|
+
type: Component,
|
|
2663
|
+
args: [{ selector: 'sky-toolbar-view-actions', changeDetection: ChangeDetectionStrategy.OnPush, template: "<div class=\"sky-toolbar-view-actions\">\n <ng-content></ng-content>\n</div>\n", styles: [":host{margin-left:auto}.sky-toolbar-view-actions{display:flex;align-items:center;margin-bottom:5px}.sky-toolbar-view-actions ::ng-deep>:not(:last-child){margin-right:5px}:host-context(.sky-theme-modern) .sky-toolbar-view-actions{margin-bottom:0}:host-context(.sky-theme-modern) .sky-toolbar-view-actions ::ng-deep>:not(:last-child){margin-top:5px;margin-bottom:5px;margin-right:10px}:host-context(.sky-theme-modern) .sky-toolbar-view-actions ::ng-deep .sky-btn{background-color:transparent;border:none;padding-left:10px;padding-right:10px}:host-context(.sky-theme-modern) .sky-toolbar-view-actions ::ng-deep .sky-btn:not(:hover):not(:active):not(:focus){box-shadow:inset 0 0 0 1px transparent}.sky-theme-modern .sky-toolbar-view-actions{margin-bottom:0}.sky-theme-modern .sky-toolbar-view-actions ::ng-deep>:not(:last-child){margin-top:5px;margin-bottom:5px;margin-right:10px}.sky-theme-modern .sky-toolbar-view-actions ::ng-deep .sky-btn{background-color:transparent;border:none;padding-left:10px;padding-right:10px}.sky-theme-modern .sky-toolbar-view-actions ::ng-deep .sky-btn:not(:hover):not(:active):not(:focus){box-shadow:inset 0 0 0 1px transparent}\n"] }]
|
|
2664
|
+
}] });
|
|
2665
|
+
|
|
2666
|
+
/**
|
|
2667
|
+
* Displays actions for lists, records, and tiles.
|
|
2668
|
+
*/
|
|
2669
|
+
class SkyToolbarComponent {
|
|
2670
|
+
constructor() {
|
|
2671
|
+
this.hasSections = false;
|
|
2672
|
+
}
|
|
2673
|
+
ngAfterContentInit() {
|
|
2674
|
+
this.hasSections = this.sectionComponents.length > 0;
|
|
2675
|
+
}
|
|
2676
|
+
}
|
|
2677
|
+
SkyToolbarComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyToolbarComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
2678
|
+
SkyToolbarComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.2.7", type: SkyToolbarComponent, selector: "sky-toolbar", queries: [{ propertyName: "sectionComponents", predicate: SkyToolbarSectionComponent, descendants: true }], ngImport: i0, template: "<div\n class=\"sky-toolbar-container\"\n [ngClass]=\"{ 'sky-toolbar-sectioned': hasSections }\"\n>\n <ng-content select=\"sky-toolbar-section\"></ng-content>\n <div class=\"sky-toolbar-items\">\n <ng-content></ng-content>\n </div>\n <ng-content select=\"sky-toolbar-view-actions\"></ng-content>\n</div>\n", styles: [".sky-toolbar-container{min-height:49px;background-color:#fff;padding:5px 10px 0;border-top:1px solid #cdcfd2;border-bottom:1px solid #cdcfd2;display:flex;flex-wrap:wrap;align-items:center;position:relative}.sky-toolbar-container ::ng-deep sky-toolbar-section:not(:first-child) .sky-toolbar-section{border-top:1px solid #cdcfd2}.sky-toolbar-container:not(.sky-toolbar-sectioned){flex-wrap:nowrap}.sky-toolbar-sectioned{display:block;padding:0}.sky-toolbar-items{display:flex;flex-wrap:wrap;align-items:center}:host-context(.sky-theme-modern .sky-viewkeeper-fixed) .sky-toolbar-container{background-color:#fcfcfc}:host-context(.sky-theme-modern.sky-theme-mode-dark .sky-viewkeeper-fixed) .sky-toolbar-container{background-color:#121212}:host-context(.sky-theme-modern) .sky-toolbar-container{background-color:transparent;border:none;padding:10px 0}:host-context(.sky-theme-modern) .sky-toolbar-container.sky-viewkeeper-fixed{background-color:#fcfcfc}:host-context(.sky-theme-modern) .sky-toolbar-container ::ng-deep sky-toolbar-section:not(:first-child) .sky-toolbar-section{border-top:1px solid #d2d2d2}:host-context(.sky-theme-modern) .sky-toolbar-sectioned{padding:0}.sky-theme-modern .sky-toolbar-container{background-color:transparent;border:none;padding:10px 0}.sky-theme-modern .sky-toolbar-container.sky-viewkeeper-fixed{background-color:#fcfcfc}.sky-theme-modern .sky-toolbar-container ::ng-deep sky-toolbar-section:not(:first-child) .sky-toolbar-section{border-top:1px solid #d2d2d2}.sky-theme-modern .sky-toolbar-sectioned{padding:0}:host-context(.sky-theme-modern.sky-theme-mode-dark) .sky-toolbar-container.sky-viewkeeper-fixed{background-color:#121212}.sky-theme-modern.sky-theme-mode-dark .sky-toolbar-container.sky-viewkeeper-fixed{background-color:#121212}\n"], directives: [{ type: i3.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }] });
|
|
2679
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyToolbarComponent, decorators: [{
|
|
2680
|
+
type: Component,
|
|
2681
|
+
args: [{ selector: 'sky-toolbar', template: "<div\n class=\"sky-toolbar-container\"\n [ngClass]=\"{ 'sky-toolbar-sectioned': hasSections }\"\n>\n <ng-content select=\"sky-toolbar-section\"></ng-content>\n <div class=\"sky-toolbar-items\">\n <ng-content></ng-content>\n </div>\n <ng-content select=\"sky-toolbar-view-actions\"></ng-content>\n</div>\n", styles: [".sky-toolbar-container{min-height:49px;background-color:#fff;padding:5px 10px 0;border-top:1px solid #cdcfd2;border-bottom:1px solid #cdcfd2;display:flex;flex-wrap:wrap;align-items:center;position:relative}.sky-toolbar-container ::ng-deep sky-toolbar-section:not(:first-child) .sky-toolbar-section{border-top:1px solid #cdcfd2}.sky-toolbar-container:not(.sky-toolbar-sectioned){flex-wrap:nowrap}.sky-toolbar-sectioned{display:block;padding:0}.sky-toolbar-items{display:flex;flex-wrap:wrap;align-items:center}:host-context(.sky-theme-modern .sky-viewkeeper-fixed) .sky-toolbar-container{background-color:#fcfcfc}:host-context(.sky-theme-modern.sky-theme-mode-dark .sky-viewkeeper-fixed) .sky-toolbar-container{background-color:#121212}:host-context(.sky-theme-modern) .sky-toolbar-container{background-color:transparent;border:none;padding:10px 0}:host-context(.sky-theme-modern) .sky-toolbar-container.sky-viewkeeper-fixed{background-color:#fcfcfc}:host-context(.sky-theme-modern) .sky-toolbar-container ::ng-deep sky-toolbar-section:not(:first-child) .sky-toolbar-section{border-top:1px solid #d2d2d2}:host-context(.sky-theme-modern) .sky-toolbar-sectioned{padding:0}.sky-theme-modern .sky-toolbar-container{background-color:transparent;border:none;padding:10px 0}.sky-theme-modern .sky-toolbar-container.sky-viewkeeper-fixed{background-color:#fcfcfc}.sky-theme-modern .sky-toolbar-container ::ng-deep sky-toolbar-section:not(:first-child) .sky-toolbar-section{border-top:1px solid #d2d2d2}.sky-theme-modern .sky-toolbar-sectioned{padding:0}:host-context(.sky-theme-modern.sky-theme-mode-dark) .sky-toolbar-container.sky-viewkeeper-fixed{background-color:#121212}.sky-theme-modern.sky-theme-mode-dark .sky-toolbar-container.sky-viewkeeper-fixed{background-color:#121212}\n"] }]
|
|
2682
|
+
}], propDecorators: { sectionComponents: [{
|
|
2683
|
+
type: ContentChildren,
|
|
2684
|
+
args: [SkyToolbarSectionComponent, { descendants: true }]
|
|
2685
|
+
}] } });
|
|
2686
|
+
|
|
2687
|
+
class SkyToolbarModule {
|
|
2688
|
+
}
|
|
2689
|
+
SkyToolbarModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyToolbarModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
2690
|
+
SkyToolbarModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyToolbarModule, declarations: [SkyToolbarComponent,
|
|
2691
|
+
SkyToolbarItemComponent,
|
|
2692
|
+
SkyToolbarSectionComponent,
|
|
2693
|
+
SkyToolbarViewActionsComponent], imports: [CommonModule], exports: [SkyToolbarComponent,
|
|
2694
|
+
SkyToolbarItemComponent,
|
|
2695
|
+
SkyToolbarSectionComponent,
|
|
2696
|
+
SkyToolbarViewActionsComponent] });
|
|
2697
|
+
SkyToolbarModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyToolbarModule, imports: [[CommonModule]] });
|
|
2698
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.7", ngImport: i0, type: SkyToolbarModule, decorators: [{
|
|
2699
|
+
type: NgModule,
|
|
2700
|
+
args: [{
|
|
2701
|
+
declarations: [
|
|
2702
|
+
SkyToolbarComponent,
|
|
2703
|
+
SkyToolbarItemComponent,
|
|
2704
|
+
SkyToolbarSectionComponent,
|
|
2705
|
+
SkyToolbarViewActionsComponent,
|
|
2706
|
+
],
|
|
2707
|
+
imports: [CommonModule],
|
|
2708
|
+
exports: [
|
|
2709
|
+
SkyToolbarComponent,
|
|
2710
|
+
SkyToolbarItemComponent,
|
|
2711
|
+
SkyToolbarSectionComponent,
|
|
2712
|
+
SkyToolbarViewActionsComponent,
|
|
2713
|
+
],
|
|
2714
|
+
}]
|
|
2715
|
+
}] });
|
|
2716
|
+
|
|
2717
|
+
/**
|
|
2718
|
+
* Generated bundle index. Do not edit.
|
|
2719
|
+
*/
|
|
2720
|
+
|
|
2721
|
+
export { SkyActionButtonModule, SkyBackToTopMessageType, SkyBackToTopModule, SkyBoxModule, SkyCardModule, SkyDefinitionListModule, SkyDescriptionListMode, SkyDescriptionListModule, SkyFluidGridGutterSize, SkyFluidGridModule, SkyFormatModule, SkyInlineDeleteModule, SkyInlineDeleteType, SkyPageModule, SkyPageSummaryModule, SkyTextExpandModule, SkyTextExpandRepeaterModule, SkyToolbarModule, SkyActionButtonComponent as λ1, SkyCardActionsComponent as λ10, SkyCardContentComponent as λ11, SkyCardTitleComponent as λ12, SkyDefinitionListComponent as λ13, SkyDefinitionListContentComponent as λ14, SkyDefinitionListHeadingComponent as λ15, SkyDefinitionListLabelComponent as λ16, SkyDefinitionListValueComponent as λ17, SkyDescriptionListComponent as λ18, SkyDescriptionListTermComponent as λ19, SkyActionButtonContainerComponent as λ2, SkyDescriptionListDescriptionComponent as λ20, SkyDescriptionListContentComponent as λ21, SkyFluidGridComponent as λ22, SkyRowComponent as λ23, SkyColumnComponent as λ24, SkyFormatComponent as λ25, SkyPageComponent as λ26, SkyPageSummaryComponent as λ27, SkyPageSummaryAlertComponent as λ28, SkyPageSummaryContentComponent as λ29, SkyActionButtonDetailsComponent as λ3, SkyPageSummaryImageComponent as λ30, SkyPageSummaryKeyInfoComponent as λ31, SkyPageSummaryStatusComponent as λ32, SkyPageSummarySubtitleComponent as λ33, SkyPageSummaryTitleComponent as λ34, SkyTextExpandComponent as λ35, SkyTextExpandRepeaterComponent as λ36, SkyToolbarComponent as λ37, SkyToolbarSectionComponent as λ38, SkyToolbarItemComponent as λ39, SkyActionButtonHeaderComponent as λ4, SkyToolbarViewActionsComponent as λ40, SkyBoxComponent as λ41, SkyBoxHeaderComponent as λ42, SkyBoxContentComponent as λ43, SkyBoxControlsComponent as λ44, SkyActionButtonIconComponent as λ5, SkyBackToTopComponent as λ6, SkyBackToTopDirective as λ7, SkyInlineDeleteComponent as λ8, SkyCardComponent as λ9 };
|
|
2722
|
+
//# sourceMappingURL=skyux-layout.mjs.map
|