@theseam/ui-common 0.2.9 → 0.2.13
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/assets/vendor/intl-tel-input/js/utils.js +255 -254
- package/bundles/theseam-ui-common-asset-reader.umd.js +7 -9
- package/bundles/theseam-ui-common-asset-reader.umd.js.map +1 -1
- package/bundles/theseam-ui-common-breadcrumbs.umd.js +6 -8
- package/bundles/theseam-ui-common-breadcrumbs.umd.js.map +1 -1
- package/bundles/theseam-ui-common-buttons.umd.js +5 -5
- package/bundles/theseam-ui-common-buttons.umd.js.map +1 -1
- package/bundles/theseam-ui-common-card.umd.js +6 -6
- package/bundles/theseam-ui-common-card.umd.js.map +1 -1
- package/bundles/theseam-ui-common-checkbox.umd.js +4 -4
- package/bundles/theseam-ui-common-checkbox.umd.js.map +1 -1
- package/bundles/theseam-ui-common-confirm-dialog.umd.js +4 -4
- package/bundles/theseam-ui-common-confirm-dialog.umd.js.map +1 -1
- package/bundles/theseam-ui-common-core.umd.js +4 -4
- package/bundles/theseam-ui-common-core.umd.js.map +1 -1
- package/bundles/theseam-ui-common-data-exporter.umd.js +5 -5
- package/bundles/theseam-ui-common-data-filters.umd.js +9 -6
- package/bundles/theseam-ui-common-data-filters.umd.js.map +1 -1
- package/bundles/theseam-ui-common-datatable-dynamic.umd.js +7 -7
- package/bundles/theseam-ui-common-datatable-dynamic.umd.js.map +1 -1
- package/bundles/theseam-ui-common-datatable.umd.js +1353 -375
- package/bundles/theseam-ui-common-datatable.umd.js.map +1 -1
- package/bundles/theseam-ui-common-dynamic-component-loader.umd.js +5 -7
- package/bundles/theseam-ui-common-dynamic-component-loader.umd.js.map +1 -1
- package/bundles/theseam-ui-common-dynamic.umd.js +7 -9
- package/bundles/theseam-ui-common-dynamic.umd.js.map +1 -1
- package/bundles/theseam-ui-common-footer-bar.umd.js +3 -3
- package/bundles/theseam-ui-common-form-field-error.umd.js +5 -5
- package/bundles/theseam-ui-common-form-field-error.umd.js.map +1 -1
- package/bundles/theseam-ui-common-form-field.umd.js +5 -5
- package/bundles/theseam-ui-common-form-field.umd.js.map +1 -1
- package/bundles/theseam-ui-common-framework.umd.js +28 -30
- package/bundles/theseam-ui-common-framework.umd.js.map +1 -1
- package/bundles/theseam-ui-common-graphql.umd.js +958 -8
- package/bundles/theseam-ui-common-graphql.umd.js.map +1 -1
- package/bundles/theseam-ui-common-icon.umd.js +5 -5
- package/bundles/theseam-ui-common-icon.umd.js.map +1 -1
- package/bundles/theseam-ui-common-layout.umd.js +5 -7
- package/bundles/theseam-ui-common-layout.umd.js.map +1 -1
- package/bundles/theseam-ui-common-loading.umd.js +4 -4
- package/bundles/theseam-ui-common-menu.umd.js +5 -5
- package/bundles/theseam-ui-common-menu.umd.js.map +1 -1
- package/bundles/theseam-ui-common-modal.umd.js +6 -6
- package/bundles/theseam-ui-common-modal.umd.js.map +1 -1
- package/bundles/theseam-ui-common-models.umd.js +3 -3
- package/bundles/theseam-ui-common-popover.umd.js +4 -4
- package/bundles/theseam-ui-common-progress.umd.js +5 -5
- package/bundles/theseam-ui-common-progress.umd.js.map +1 -1
- package/bundles/theseam-ui-common-scrollbar.umd.js +7 -9
- package/bundles/theseam-ui-common-scrollbar.umd.js.map +1 -1
- package/bundles/theseam-ui-common-services.umd.js +6 -8
- package/bundles/theseam-ui-common-services.umd.js.map +1 -1
- package/bundles/theseam-ui-common-shared.umd.js +4 -4
- package/bundles/theseam-ui-common-shared.umd.js.map +1 -1
- package/bundles/theseam-ui-common-storage.umd.js +5 -7
- package/bundles/theseam-ui-common-storage.umd.js.map +1 -1
- package/bundles/theseam-ui-common-story-helpers.umd.js +4 -4
- package/bundles/theseam-ui-common-story-helpers.umd.js.map +1 -1
- package/bundles/theseam-ui-common-tabbed.umd.js +5 -5
- package/bundles/theseam-ui-common-tabbed.umd.js.map +1 -1
- package/bundles/theseam-ui-common-table-cell-type.umd.js +5 -7
- package/bundles/theseam-ui-common-table-cell-type.umd.js.map +1 -1
- package/bundles/theseam-ui-common-table-cell-types.umd.js +258 -32
- package/bundles/theseam-ui-common-table-cell-types.umd.js.map +1 -1
- package/bundles/theseam-ui-common-table.umd.js +5 -5
- package/bundles/theseam-ui-common-table.umd.js.map +1 -1
- package/bundles/theseam-ui-common-tel-input.umd.js +6 -6
- package/bundles/theseam-ui-common-tel-input.umd.js.map +1 -1
- package/bundles/theseam-ui-common-testing.umd.js +568 -0
- package/bundles/theseam-ui-common-testing.umd.js.map +1 -0
- package/bundles/theseam-ui-common-tiled-select.umd.js +56 -39
- package/bundles/theseam-ui-common-tiled-select.umd.js.map +1 -1
- package/bundles/theseam-ui-common-toggle-edit.umd.js +8 -10
- package/bundles/theseam-ui-common-toggle-edit.umd.js.map +1 -1
- package/bundles/theseam-ui-common-toggle-group.umd.js +4 -4
- package/bundles/theseam-ui-common-toggle-group.umd.js.map +1 -1
- package/bundles/theseam-ui-common-unsaved-changes-dialog.umd.js +5 -7
- package/bundles/theseam-ui-common-unsaved-changes-dialog.umd.js.map +1 -1
- package/bundles/theseam-ui-common-utils.umd.js +174 -81
- package/bundles/theseam-ui-common-utils.umd.js.map +1 -1
- package/bundles/theseam-ui-common-validators.umd.js +3 -3
- package/bundles/theseam-ui-common-viewers.umd.js +6 -8
- package/bundles/theseam-ui-common-viewers.umd.js.map +1 -1
- package/bundles/theseam-ui-common-widget.umd.js +18 -20
- package/bundles/theseam-ui-common-widget.umd.js.map +1 -1
- package/bundles/theseam-ui-common.umd.js +2 -2
- package/buttons/theseam-ui-common-buttons.metadata.json +1 -1
- package/card/theseam-ui-common-card.metadata.json +1 -1
- package/data-filters/data-filter.d.ts +10 -6
- package/data-filters/theseam-ui-common-data-filters.metadata.json +1 -1
- package/datatable/datatable/datatable.component.d.ts +48 -32
- package/datatable/datatable-column/datatable-column.component.d.ts +26 -25
- package/datatable/datatable-column-preferences/datatable-column-preferences.component.d.ts +7 -5
- package/datatable/datatable-column-preferences-button/datatable-column-preferences-button.component.d.ts +7 -1
- package/datatable/datatable-footer/datatable-footer-tpl.directive.d.ts +5 -0
- package/datatable/datatable-footer/datatable-footer.directive.d.ts +6 -0
- package/datatable/datatable-menu-bar/datatable-menu-bar.component.d.ts +1 -1
- package/datatable/directives/datatable-filter.directive.d.ts +1 -1
- package/datatable/models/columns-alteration.d.ts +61 -0
- package/datatable/models/columns-alterations/hide-column.columns-alteration.d.ts +15 -0
- package/datatable/models/columns-alterations/order.columns-alteration.d.ts +20 -0
- package/datatable/models/columns-alterations/sort.columns-alteration.d.ts +14 -0
- package/datatable/models/columns-alterations/width.columns-alteration.d.ts +16 -0
- package/datatable/models/datatable-accessor.d.ts +5 -3
- package/datatable/models/internal-column-props.d.ts +7 -0
- package/datatable/models/page-info.d.ts +12 -0
- package/datatable/models/preferences-accessor.d.ts +1 -1
- package/datatable/models/preferences.d.ts +11 -3
- package/datatable/models/sort-item.d.ts +2 -1
- package/datatable/public-api.d.ts +2 -0
- package/datatable/services/columns-alterations-manager.service.d.ts +39 -0
- package/datatable/services/columns-manager.service.d.ts +55 -0
- package/datatable/services/datatable-preferences.service.d.ts +10 -7
- package/datatable/theseam-ui-common-datatable.d.ts +2 -0
- package/datatable/theseam-ui-common-datatable.metadata.json +1 -1
- package/datatable/tokens/datatable-preferences-accessor.d.ts +2 -2
- package/datatable/utils/create-action-menu-column.d.ts +3 -0
- package/datatable/utils/create-checkbox-column.d.ts +3 -0
- package/datatable/utils/get-column-prop.d.ts +5 -0
- package/datatable/utils/map-columns-alterations-states.d.ts +2 -0
- package/datatable/utils/remove-unused-diffs.d.ts +7 -0
- package/datatable/utils/set-column-defaults.d.ts +2 -0
- package/datatable/utils/translate-templates.d.ts +2 -0
- package/datatable/utils/with-stored-column-info.d.ts +2 -2
- package/datatable-dynamic/theseam-ui-common-datatable-dynamic.metadata.json +1 -1
- package/esm2015/buttons/progress-circle-button/progress-circle-button.component.js +1 -1
- package/esm2015/card/card-action/card-action.component.js +1 -1
- package/esm2015/card/card-body/card-body.component.js +1 -1
- package/esm2015/data-filters/data-filter.js +5 -2
- package/esm2015/data-filters/filters/data-filter-search/data-filter-search.component.js +1 -1
- package/esm2015/data-filters/filters/data-filter-text/data-filter-text.component.js +1 -1
- package/esm2015/datatable/datatable/datatable.component.js +197 -211
- package/esm2015/datatable/datatable-action-menu/datatable-action-menu.component.js +1 -1
- package/esm2015/datatable/datatable-column/datatable-column.component.js +1 -1
- package/esm2015/datatable/datatable-column-preferences/datatable-column-preferences.component.js +42 -19
- package/esm2015/datatable/datatable-column-preferences-button/datatable-column-preferences-button.component.js +38 -4
- package/esm2015/datatable/datatable-export-button/datatable-export-button.component.js +1 -1
- package/esm2015/datatable/datatable-footer/datatable-footer-tpl.directive.js +15 -0
- package/esm2015/datatable/datatable-footer/datatable-footer.directive.js +18 -0
- package/esm2015/datatable/datatable-menu-bar/datatable-menu-bar.component.js +1 -1
- package/esm2015/datatable/datatable-menu-bar-column-center/datatable-menu-bar-column-center.component.js +1 -1
- package/esm2015/datatable/datatable-menu-bar-column-left/datatable-menu-bar-column-left.component.js +1 -1
- package/esm2015/datatable/datatable-menu-bar-column-right/datatable-menu-bar-column-right.component.js +1 -1
- package/esm2015/datatable/datatable-menu-bar-row/datatable-menu-bar-row.component.js +1 -1
- package/esm2015/datatable/datatable.module.js +7 -1
- package/esm2015/datatable/models/columns-alteration.js +38 -0
- package/esm2015/datatable/models/columns-alterations/hide-column.columns-alteration.js +38 -0
- package/esm2015/datatable/models/columns-alterations/order.columns-alteration.js +81 -0
- package/esm2015/datatable/models/columns-alterations/sort.columns-alteration.js +33 -0
- package/esm2015/datatable/models/columns-alterations/width.columns-alteration.js +41 -0
- package/esm2015/datatable/models/datatable-accessor.js +1 -1
- package/esm2015/datatable/models/internal-column-props.js +15 -0
- package/esm2015/datatable/models/page-info.js +1 -1
- package/esm2015/datatable/models/preferences-accessor.js +1 -1
- package/esm2015/datatable/models/preferences.js +6 -2
- package/esm2015/datatable/models/sort-item.js +1 -1
- package/esm2015/datatable/public-api.js +3 -1
- package/esm2015/datatable/services/columns-alterations-manager.service.js +134 -0
- package/esm2015/datatable/services/columns-manager.service.js +257 -0
- package/esm2015/datatable/services/datatable-preferences.service.js +78 -32
- package/esm2015/datatable/theseam-ui-common-datatable.js +3 -1
- package/esm2015/datatable/tokens/datatable-preferences-accessor.js +2 -2
- package/esm2015/datatable/utils/create-action-menu-column.js +18 -0
- package/esm2015/datatable/utils/create-checkbox-column.js +15 -0
- package/esm2015/datatable/utils/get-column-prop.js +9 -0
- package/esm2015/datatable/utils/map-columns-alterations-states.js +39 -0
- package/esm2015/datatable/utils/remove-unused-diffs.js +9 -0
- package/esm2015/datatable/utils/set-column-defaults.js +10 -0
- package/esm2015/datatable/utils/translate-templates.js +12 -0
- package/esm2015/datatable/utils/with-stored-column-info.js +1 -1
- package/esm2015/datatable-dynamic/datatable-dynamic-action-menu/datatable-dynamic-action-menu.component.js +1 -1
- package/esm2015/datatable-dynamic/datatable-dynamic-filter-container/datatable-dynamic-filter-container.component.js +1 -1
- package/esm2015/datatable-dynamic/datatable-dynamic.component.js +1 -1
- package/esm2015/form-field/form-field.component.js +1 -1
- package/esm2015/form-field-error/form-field-error/form-field-error.component.js +1 -1
- package/esm2015/framework/base-layout/base-layout.component.js +1 -1
- package/esm2015/framework/dashboard/dashboard-widgets/dashboard-widgets.component.js +1 -1
- package/esm2015/framework/dynamic-router/hierarchy-router-outlet/hierarchy-router-outlet.component.js +1 -1
- package/esm2015/framework/schema-form-controls/schema-form-input/schema-form-input.component.js +1 -1
- package/esm2015/framework/schema-form-controls/schema-form-number/schema-form-number.component.js +1 -1
- package/esm2015/framework/schema-form-controls/schema-form-select/schema-form-select.component.js +1 -1
- package/esm2015/framework/schema-form-controls/schema-form-submit-split/schema-form-submit-split.component.js +1 -1
- package/esm2015/framework/side-nav/side-nav-item/side-nav-item.component.js +3 -3
- package/esm2015/framework/side-nav/side-nav-toggle/side-nav-toggle.component.js +1 -1
- package/esm2015/framework/side-nav/side-nav.component.js +1 -1
- package/esm2015/framework/top-bar/top-bar-menu-button/top-bar-menu-button.component.js +1 -1
- package/esm2015/framework/top-bar/top-bar-title/top-bar-title.component.js +1 -1
- package/esm2015/framework/top-bar/top-bar.component.js +1 -1
- package/esm2015/graphql/datatable/create-page-info-observable.js +38 -0
- package/esm2015/graphql/datatable/datatable-graphql-query-ref.js +236 -0
- package/esm2015/graphql/datatable/datatable-graphql.service.js +35 -0
- package/esm2015/graphql/datatable/datatable-helpers.js +170 -0
- package/esm2015/graphql/datatable/get-page-info.js +11 -0
- package/esm2015/graphql/datatable/index.js +7 -0
- package/esm2015/graphql/datatable/map-filter-states.js +64 -0
- package/esm2015/graphql/datatable/map-page-info.js +14 -0
- package/esm2015/graphql/datatable/mapper-context.js +2 -0
- package/esm2015/graphql/models/gql-datatable-accessor.js +2 -0
- package/esm2015/graphql/models/index.js +2 -1
- package/esm2015/graphql/models/query-processing-config.js +1 -1
- package/esm2015/graphql/public-api.js +2 -1
- package/esm2015/graphql/utils/parse-hints.js +3 -3
- package/esm2015/icon/icon/icon.component.js +1 -1
- package/esm2015/loading/loading/loading.component.js +1 -1
- package/esm2015/menu/menu.component.js +1 -1
- package/esm2015/modal/modal-body/modal-body.component.js +1 -1
- package/esm2015/modal/modal-container/modal-container.component.js +1 -1
- package/esm2015/popover/popover/popover.component.js +1 -1
- package/esm2015/progress/progress-circle/progress-circle.component.js +1 -1
- package/esm2015/tabbed/tabbed.component.js +1 -1
- package/esm2015/table/table/table.component.js +1 -1
- package/esm2015/table-cell-types/public-api.js +8 -1
- package/esm2015/table-cell-types/table-cell-type-currency/table-cell-type-currency-config.js +2 -0
- package/esm2015/table-cell-types/table-cell-type-currency/table-cell-type-currency.component.js +74 -0
- package/esm2015/table-cell-types/table-cell-type-currency/table-cell-type-currency.js +2 -0
- package/esm2015/table-cell-types/table-cell-type-decimal/table-cell-type-decimal-config.js +1 -1
- package/esm2015/table-cell-types/table-cell-type-decimal/table-cell-type-decimal.component.js +73 -0
- package/esm2015/table-cell-types/table-cell-type-decimal/table-cell-type-decimal.js +2 -0
- package/esm2015/table-cell-types/table-cell-type-icon/table-cell-type-icon.component.js +1 -1
- package/esm2015/table-cell-types/table-cell-type-integer/table-cell-type-integer-config.js +1 -1
- package/esm2015/table-cell-types/table-cell-type-integer/table-cell-type-integer.component.js +71 -0
- package/esm2015/table-cell-types/table-cell-type-integer/table-cell-type-integer.js +2 -0
- package/esm2015/table-cell-types/table-cell-type-manifests.js +29 -17
- package/esm2015/table-cell-types/table-cell-type-progress-circle/table-cell-type-progress-circle.component.js +1 -1
- package/esm2015/table-cell-types/table-cell-types.module.js +9 -2
- package/esm2015/tel-input/tel-input/tel-input.component.js +1 -1
- package/esm2015/testing/current-tick-time.js +16 -0
- package/esm2015/testing/fake-toastr.js +29 -0
- package/esm2015/testing/get-harness.js +16 -0
- package/esm2015/testing/public-api.js +7 -0
- package/esm2015/testing/render-story.js +12 -0
- package/esm2015/testing/story-expect.js +39 -0
- package/esm2015/testing/theseam-ui-common-testing.js +5 -0
- package/esm2015/testing/tick-helper.js +74 -0
- package/esm2015/tiled-select/components/tiled-select/tiled-select.component.js +25 -17
- package/esm2015/tiled-select/components/tiled-select-tile/tiled-select-tile.component.js +5 -2
- package/esm2015/tiled-select/components/tiled-select-tile-icon/tiled-select-tile-icon.component.js +1 -1
- package/esm2015/tiled-select/public-api.js +2 -1
- package/esm2015/tiled-select/tiled-select.models.js +1 -1
- package/esm2015/tiled-select/tiled-select.module.js +4 -4
- package/esm2015/toggle-edit/toggle-edit-actions-container/toggle-edit-actions-container.component.js +1 -1
- package/esm2015/toggle-edit/toggle-edit.component.js +1 -1
- package/esm2015/utils/array-move.js +62 -0
- package/esm2015/utils/public-api.js +2 -1
- package/esm2015/utils/subscriber-count.js +31 -4
- package/esm2015/widget/widget/widget.component.js +1 -1
- package/esm2015/widget/widget-content-components/widget-button-group/widget-button-group.component.js +1 -1
- package/esm2015/widget/widget-content-components/widget-content-header/widget-content-header.component.js +1 -1
- package/esm2015/widget/widget-content-components/widget-empty-label/widget-empty-label.component.js +1 -1
- package/esm2015/widget/widget-content-components/widget-footer-link/widget-footer-link.component.js +1 -1
- package/esm2015/widget/widget-content-components/widget-footer-text/widget-footer-text.component.js +1 -1
- package/esm2015/widget/widget-content-components/widget-header-badge/widget-header-badge.component.js +1 -1
- package/esm2015/widget/widget-content-components/widget-tile/widget-tile-footer-item/widget-tile-footer-item.component.js +1 -1
- package/esm2015/widget/widget-content-components/widget-tile/widget-tile-group/widget-tile-group.component.js +1 -1
- package/esm2015/widget/widget-content-components/widget-tile/widget-tile.component.js +1 -1
- package/esm2015/widget/widget-content-components/widget-tile-list/widget-tile-list.component.js +1 -1
- package/esm2015/widget/widget-footer/widget-footer.component.js +1 -1
- package/fesm2015/theseam-ui-common-buttons.js +1 -1
- package/fesm2015/theseam-ui-common-card.js +2 -2
- package/fesm2015/theseam-ui-common-data-filters.js +6 -3
- package/fesm2015/theseam-ui-common-data-filters.js.map +1 -1
- package/fesm2015/theseam-ui-common-datatable-dynamic.js +3 -3
- package/fesm2015/theseam-ui-common-datatable.js +1136 -316
- package/fesm2015/theseam-ui-common-datatable.js.map +1 -1
- package/fesm2015/theseam-ui-common-form-field-error.js +1 -1
- package/fesm2015/theseam-ui-common-form-field.js +1 -1
- package/fesm2015/theseam-ui-common-framework.js +14 -14
- package/fesm2015/theseam-ui-common-framework.js.map +1 -1
- package/fesm2015/theseam-ui-common-graphql.js +555 -5
- package/fesm2015/theseam-ui-common-graphql.js.map +1 -1
- package/fesm2015/theseam-ui-common-icon.js +1 -1
- package/fesm2015/theseam-ui-common-loading.js +1 -1
- package/fesm2015/theseam-ui-common-menu.js +1 -1
- package/fesm2015/theseam-ui-common-modal.js +2 -2
- package/fesm2015/theseam-ui-common-popover.js +1 -1
- package/fesm2015/theseam-ui-common-progress.js +1 -1
- package/fesm2015/theseam-ui-common-tabbed.js +1 -1
- package/fesm2015/theseam-ui-common-table-cell-types.js +234 -22
- package/fesm2015/theseam-ui-common-table-cell-types.js.map +1 -1
- package/fesm2015/theseam-ui-common-table.js +1 -1
- package/fesm2015/theseam-ui-common-tel-input.js +1 -1
- package/fesm2015/theseam-ui-common-testing.js +191 -0
- package/fesm2015/theseam-ui-common-testing.js.map +1 -0
- package/fesm2015/theseam-ui-common-tiled-select.js +34 -21
- package/fesm2015/theseam-ui-common-tiled-select.js.map +1 -1
- package/fesm2015/theseam-ui-common-toggle-edit.js +2 -2
- package/fesm2015/theseam-ui-common-utils.js +92 -4
- package/fesm2015/theseam-ui-common-utils.js.map +1 -1
- package/fesm2015/theseam-ui-common-widget.js +12 -12
- package/form-field/theseam-ui-common-form-field.metadata.json +1 -1
- package/form-field-error/theseam-ui-common-form-field-error.metadata.json +1 -1
- package/framework/side-nav/side-nav-item/side-nav-item.component.scss +36 -9
- package/framework/theseam-ui-common-framework.metadata.json +1 -1
- package/graphql/datatable/create-page-info-observable.d.ts +4 -0
- package/graphql/datatable/datatable-graphql-query-ref.d.ts +65 -0
- package/graphql/datatable/datatable-graphql.service.d.ts +26 -0
- package/graphql/datatable/datatable-helpers.d.ts +12 -0
- package/graphql/datatable/get-page-info.d.ts +4 -0
- package/graphql/datatable/index.d.ts +6 -0
- package/graphql/datatable/map-filter-states.d.ts +18 -0
- package/graphql/datatable/map-page-info.d.ts +11 -0
- package/graphql/datatable/mapper-context.d.ts +6 -0
- package/graphql/models/gql-datatable-accessor.d.ts +9 -0
- package/graphql/models/index.d.ts +1 -0
- package/graphql/models/query-processing-config.d.ts +4 -0
- package/graphql/public-api.d.ts +1 -0
- package/graphql/theseam-ui-common-graphql.metadata.json +1 -1
- package/icon/theseam-ui-common-icon.metadata.json +1 -1
- package/loading/theseam-ui-common-loading.metadata.json +1 -1
- package/menu/theseam-ui-common-menu.metadata.json +1 -1
- package/modal/theseam-ui-common-modal.metadata.json +1 -1
- package/package.json +1 -1
- package/popover/theseam-ui-common-popover.metadata.json +1 -1
- package/progress/theseam-ui-common-progress.metadata.json +1 -1
- package/styles/common/_table.scss +0 -5
- package/styles/vendor/ngx-datatable/_ngx-datatable.scss +478 -87
- package/styles/vendor/ngx-datatable/_themes/bootstrap/_variables.scss +174 -0
- package/styles/vendor/ngx-datatable/_themes/dark/_variables.scss +166 -0
- package/styles/vendor/ngx-datatable/_themes/material/_variables.scss +165 -0
- package/styles/vendor/ngx-datatable/_variables.scss +3 -0
- package/tabbed/theseam-ui-common-tabbed.metadata.json +1 -1
- package/table/theseam-ui-common-table.metadata.json +1 -1
- package/table-cell-types/public-api.d.ts +7 -0
- package/table-cell-types/table-cell-type-currency/table-cell-type-currency-config.d.ts +39 -0
- package/table-cell-types/table-cell-type-currency/table-cell-type-currency.component.d.ts +19 -0
- package/table-cell-types/table-cell-type-currency/table-cell-type-currency.d.ts +3 -0
- package/table-cell-types/table-cell-type-decimal/table-cell-type-decimal-config.d.ts +31 -1
- package/table-cell-types/table-cell-type-decimal/table-cell-type-decimal.component.d.ts +19 -0
- package/table-cell-types/table-cell-type-decimal/table-cell-type-decimal.d.ts +3 -0
- package/table-cell-types/table-cell-type-integer/table-cell-type-integer-config.d.ts +23 -1
- package/table-cell-types/table-cell-type-integer/table-cell-type-integer.component.d.ts +19 -0
- package/table-cell-types/table-cell-type-integer/table-cell-type-integer.d.ts +3 -0
- package/table-cell-types/table-cell-type-manifests.d.ts +2 -1
- package/table-cell-types/theseam-ui-common-table-cell-types.metadata.json +1 -1
- package/tel-input/theseam-ui-common-tel-input.metadata.json +1 -1
- package/testing/current-tick-time.d.ts +13 -0
- package/testing/fake-toastr.d.ts +30 -0
- package/testing/get-harness.d.ts +7 -0
- package/testing/package.json +11 -0
- package/testing/public-api.d.ts +6 -0
- package/testing/render-story.d.ts +2 -0
- package/testing/story-expect.d.ts +5 -0
- package/{test-helpers/theseam-ui-common-test-helpers.d.ts → testing/theseam-ui-common-testing.d.ts} +0 -0
- package/testing/theseam-ui-common-testing.metadata.json +1 -0
- package/{test-helpers → testing}/tick-helper.d.ts +0 -0
- package/tiled-select/components/tiled-select/tiled-select.component.d.ts +7 -3
- package/tiled-select/components/tiled-select-tile/tiled-select-tile.component.d.ts +1 -0
- package/tiled-select/theseam-ui-common-tiled-select.metadata.json +1 -1
- package/tiled-select/tiled-select.models.d.ts +3 -1
- package/toggle-edit/theseam-ui-common-toggle-edit.metadata.json +1 -1
- package/utils/array-move.d.ts +49 -0
- package/utils/public-api.d.ts +1 -0
- package/utils/subscriber-count.d.ts +13 -1
- package/utils/theseam-ui-common-utils.metadata.json +1 -1
- package/widget/theseam-ui-common-widget.metadata.json +1 -1
- package/bundles/theseam-ui-common-test-helpers.umd.js +0 -94
- package/bundles/theseam-ui-common-test-helpers.umd.js.map +0 -1
- package/esm2015/test-helpers/public-api.js +0 -2
- package/esm2015/test-helpers/theseam-ui-common-test-helpers.js +0 -5
- package/esm2015/test-helpers/tick-helper.js +0 -74
- package/fesm2015/theseam-ui-common-test-helpers.js +0 -81
- package/fesm2015/theseam-ui-common-test-helpers.js.map +0 -1
- package/test-helpers/package.json +0 -11
- package/test-helpers/public-api.d.ts +0 -1
- package/test-helpers/theseam-ui-common-test-helpers.metadata.json +0 -1
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { TableCellTypesHelpersService, TABLE_CELL_DATA, TABLE_CELL_TYPE_MANIFEST, TheSeamTableCellTypeModule } from '@theseam/ui-common/table-cell-type';
|
|
2
|
+
import { formatCurrency, formatNumber, CommonModule } from '@angular/common';
|
|
2
3
|
import { Component, ChangeDetectionStrategy, ChangeDetectorRef, Optional, Inject, Input, HostBinding, NgModule } from '@angular/core';
|
|
3
4
|
import { Subject } from 'rxjs';
|
|
4
5
|
import { takeUntil } from 'rxjs/operators';
|
|
6
|
+
import { notNullOrUndefined, hasProperty } from '@theseam/ui-common/utils';
|
|
7
|
+
import { coerceBooleanProperty, coerceNumberProperty } from '@angular/cdk/coercion';
|
|
5
8
|
import { DatatableComponent } from '@theseam/ui-common/datatable';
|
|
6
9
|
import { getKnownIcon, TheSeamIconModule } from '@theseam/ui-common/icon';
|
|
7
10
|
import { TableComponent } from '@theseam/ui-common/table';
|
|
8
11
|
import { THESEAM_DEFAULT_PHONE_NUMBER_FORMAT, coercePhoneNumberFormat, TheSeamTelInputModule } from '@theseam/ui-common/tel-input';
|
|
9
|
-
import { hasProperty } from '@theseam/ui-common/utils';
|
|
10
|
-
import { coerceNumberProperty, coerceBooleanProperty } from '@angular/cdk/coercion';
|
|
11
12
|
import { PortalModule } from '@angular/cdk/portal';
|
|
12
|
-
import { CommonModule } from '@angular/common';
|
|
13
13
|
import { RouterModule } from '@angular/router';
|
|
14
14
|
import { NgbTooltipModule } from '@ng-bootstrap/ng-bootstrap';
|
|
15
15
|
import { TheSeamAssetReaderModule } from '@theseam/ui-common/asset-reader';
|
|
@@ -17,6 +17,75 @@ import { TheSeamPopoverModule } from '@theseam/ui-common/popover';
|
|
|
17
17
|
import { TheSeamProgressModule } from '@theseam/ui-common/progress';
|
|
18
18
|
import { TheSeamSharedModule } from '@theseam/ui-common/shared';
|
|
19
19
|
|
|
20
|
+
class TableCellTypeCurrencyComponent {
|
|
21
|
+
// TODO: implement
|
|
22
|
+
// titleAttr?: string
|
|
23
|
+
constructor(_cdf, _tableCellTypeHelpers, _tableData) {
|
|
24
|
+
var _a, _b;
|
|
25
|
+
this._cdf = _cdf;
|
|
26
|
+
this._tableCellTypeHelpers = _tableCellTypeHelpers;
|
|
27
|
+
this._ngUnsubscribe = new Subject();
|
|
28
|
+
const tableData = _tableData;
|
|
29
|
+
this.value = tableData && this._formatCurrency(tableData.value, tableData);
|
|
30
|
+
this.row = tableData && tableData.row;
|
|
31
|
+
this.rowIndex = tableData && tableData.rowIndex;
|
|
32
|
+
this.colData = tableData && tableData.colData;
|
|
33
|
+
this.textAlign = this._parseConfigValue((_b = (_a = tableData === null || tableData === void 0 ? void 0 : tableData.colData) === null || _a === void 0 ? void 0 : _a.cellTypeConfig) === null || _b === void 0 ? void 0 : _b.textAlign, tableData) || 'right';
|
|
34
|
+
// this.titleAttr = this._parseConfigValue(tableData?.colData?.cellTypeConfig?.titleAttr, tableData) || this.value
|
|
35
|
+
if (tableData) {
|
|
36
|
+
tableData.changed
|
|
37
|
+
.pipe(takeUntil(this._ngUnsubscribe))
|
|
38
|
+
.subscribe(v => {
|
|
39
|
+
if (v.changes.hasOwnProperty('value')) {
|
|
40
|
+
this.value = this._formatCurrency(v.changes.value.currentValue, tableData);
|
|
41
|
+
this._cdf.markForCheck();
|
|
42
|
+
}
|
|
43
|
+
if (v.changes.hasOwnProperty('colData')) {
|
|
44
|
+
this.colData = v.changes.colData.currentValue;
|
|
45
|
+
this._cdf.markForCheck();
|
|
46
|
+
}
|
|
47
|
+
});
|
|
48
|
+
}
|
|
49
|
+
}
|
|
50
|
+
ngOnInit() { }
|
|
51
|
+
ngOnDestroy() {
|
|
52
|
+
this._ngUnsubscribe.next();
|
|
53
|
+
this._ngUnsubscribe.complete();
|
|
54
|
+
}
|
|
55
|
+
_formatCurrency(currentValue, tableData) {
|
|
56
|
+
var _a;
|
|
57
|
+
const config = (_a = tableData === null || tableData === void 0 ? void 0 : tableData.colData) === null || _a === void 0 ? void 0 : _a.cellTypeConfig;
|
|
58
|
+
const locale = this._parseConfigValue(config === null || config === void 0 ? void 0 : config.locale, tableData) || 'en-US';
|
|
59
|
+
const currency = this._parseConfigValue(config === null || config === void 0 ? void 0 : config.currency, tableData) || '$';
|
|
60
|
+
const currencyCode = this._parseConfigValue(config === null || config === void 0 ? void 0 : config.currencyCode, tableData) || 'USD';
|
|
61
|
+
const minIntegerDigits = this._parseConfigValue(config === null || config === void 0 ? void 0 : config.minIntegerDigits, tableData) || 1;
|
|
62
|
+
const minFractionDigits = this._parseConfigValue(config === null || config === void 0 ? void 0 : config.minFractionDigits, tableData) || 0;
|
|
63
|
+
const maxFractionDigits = this._parseConfigValue(config === null || config === void 0 ? void 0 : config.maxFractionDigits, tableData) || 2;
|
|
64
|
+
const format = `${minIntegerDigits}.${minFractionDigits}-${maxFractionDigits}`;
|
|
65
|
+
return formatCurrency(currentValue, locale, currency, currencyCode, format);
|
|
66
|
+
}
|
|
67
|
+
_parseConfigValue(val, tableData) {
|
|
68
|
+
const contextFn = () => this._tableCellTypeHelpers.getValueContext(val, tableData);
|
|
69
|
+
return this._tableCellTypeHelpers.parseValueProp(val, contextFn);
|
|
70
|
+
}
|
|
71
|
+
}
|
|
72
|
+
TableCellTypeCurrencyComponent.decorators = [
|
|
73
|
+
{ type: Component, args: [{
|
|
74
|
+
selector: 'seam-table-cell-type-currency',
|
|
75
|
+
template: "<div [class]=\"'text-' + textAlign\">\n <seam-table-cell-type-selector\n type=\"string\"\n [value]=\"value\"\n [rowIndex]=\"rowIndex\"\n [row]=\"row\"\n [colData]=\"colData\"></seam-table-cell-type-selector>\n</div>\n",
|
|
76
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
77
|
+
styles: [""]
|
|
78
|
+
},] }
|
|
79
|
+
];
|
|
80
|
+
TableCellTypeCurrencyComponent.ctorParameters = () => [
|
|
81
|
+
{ type: ChangeDetectorRef },
|
|
82
|
+
{ type: TableCellTypesHelpersService },
|
|
83
|
+
{ type: undefined, decorators: [{ type: Optional }, { type: Inject, args: [TABLE_CELL_DATA,] }] }
|
|
84
|
+
];
|
|
85
|
+
TableCellTypeCurrencyComponent.propDecorators = {
|
|
86
|
+
value: [{ type: Input }]
|
|
87
|
+
};
|
|
88
|
+
|
|
20
89
|
class TableCellTypeDateComponent {
|
|
21
90
|
constructor(_cdf, _tableData) {
|
|
22
91
|
this._cdf = _cdf;
|
|
@@ -68,6 +137,72 @@ TableCellTypeDateComponent.propDecorators = {
|
|
|
68
137
|
format: [{ type: Input }]
|
|
69
138
|
};
|
|
70
139
|
|
|
140
|
+
class TableCellTypeDecimalComponent {
|
|
141
|
+
constructor(_cdf, _tableCellTypeHelpers, _tableData) {
|
|
142
|
+
var _a, _b;
|
|
143
|
+
this._cdf = _cdf;
|
|
144
|
+
this._tableCellTypeHelpers = _tableCellTypeHelpers;
|
|
145
|
+
this._ngUnsubscribe = new Subject();
|
|
146
|
+
const tableData = _tableData;
|
|
147
|
+
this.value = tableData && this._formatDecimal(tableData.value, tableData);
|
|
148
|
+
this.row = tableData && tableData.row;
|
|
149
|
+
this.rowIndex = tableData && tableData.rowIndex;
|
|
150
|
+
this.colData = tableData && tableData.colData;
|
|
151
|
+
this.textAlign = this._parseConfigValue((_b = (_a = tableData === null || tableData === void 0 ? void 0 : tableData.colData) === null || _a === void 0 ? void 0 : _a.cellTypeConfig) === null || _b === void 0 ? void 0 : _b.textAlign, tableData) || 'right';
|
|
152
|
+
if (tableData) {
|
|
153
|
+
tableData.changed
|
|
154
|
+
.pipe(takeUntil(this._ngUnsubscribe))
|
|
155
|
+
.subscribe(v => {
|
|
156
|
+
if (v.changes.hasOwnProperty('value')) {
|
|
157
|
+
this.value = this._formatDecimal(v.changes.value.currentValue, tableData);
|
|
158
|
+
this._cdf.markForCheck();
|
|
159
|
+
}
|
|
160
|
+
if (v.changes.hasOwnProperty('colData')) {
|
|
161
|
+
this.colData = v.changes.colData.currentValue;
|
|
162
|
+
this._cdf.markForCheck();
|
|
163
|
+
}
|
|
164
|
+
});
|
|
165
|
+
}
|
|
166
|
+
}
|
|
167
|
+
ngOnInit() { }
|
|
168
|
+
ngOnDestroy() {
|
|
169
|
+
this._ngUnsubscribe.next();
|
|
170
|
+
this._ngUnsubscribe.complete();
|
|
171
|
+
}
|
|
172
|
+
_formatDecimal(currentValue, tableData) {
|
|
173
|
+
var _a;
|
|
174
|
+
const config = (_a = tableData === null || tableData === void 0 ? void 0 : tableData.colData) === null || _a === void 0 ? void 0 : _a.cellTypeConfig;
|
|
175
|
+
const formatDecimal = notNullOrUndefined(config === null || config === void 0 ? void 0 : config.formatNumber) ?
|
|
176
|
+
this._parseConfigValue(coerceBooleanProperty(config === null || config === void 0 ? void 0 : config.formatNumber), tableData) : true;
|
|
177
|
+
const locale = this._parseConfigValue(config === null || config === void 0 ? void 0 : config.locale, tableData) || 'en-US';
|
|
178
|
+
const minIntegerDigits = this._parseConfigValue(config === null || config === void 0 ? void 0 : config.minIntegerDigits, tableData) || 1;
|
|
179
|
+
const minFractionDigits = this._parseConfigValue(config === null || config === void 0 ? void 0 : config.minFractionDigits, tableData) || 0;
|
|
180
|
+
const maxFractionDigits = this._parseConfigValue(config === null || config === void 0 ? void 0 : config.maxFractionDigits, tableData) || 3;
|
|
181
|
+
const format = `${minIntegerDigits}.${minFractionDigits}-${maxFractionDigits}`;
|
|
182
|
+
return formatDecimal ? formatNumber(currentValue, locale, format) : currentValue;
|
|
183
|
+
}
|
|
184
|
+
_parseConfigValue(val, tableData) {
|
|
185
|
+
const contextFn = () => this._tableCellTypeHelpers.getValueContext(val, tableData);
|
|
186
|
+
return this._tableCellTypeHelpers.parseValueProp(val, contextFn);
|
|
187
|
+
}
|
|
188
|
+
}
|
|
189
|
+
TableCellTypeDecimalComponent.decorators = [
|
|
190
|
+
{ type: Component, args: [{
|
|
191
|
+
selector: 'seam-table-cell-type-decimal',
|
|
192
|
+
template: "<div [class]=\"'text-' + textAlign\">\n <seam-table-cell-type-selector\n type=\"string\"\n [value]=\"value\"\n [rowIndex]=\"rowIndex\"\n [row]=\"row\"\n [colData]=\"colData\"></seam-table-cell-type-selector>\n</div>\n",
|
|
193
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
194
|
+
styles: [""]
|
|
195
|
+
},] }
|
|
196
|
+
];
|
|
197
|
+
TableCellTypeDecimalComponent.ctorParameters = () => [
|
|
198
|
+
{ type: ChangeDetectorRef },
|
|
199
|
+
{ type: TableCellTypesHelpersService },
|
|
200
|
+
{ type: undefined, decorators: [{ type: Optional }, { type: Inject, args: [TABLE_CELL_DATA,] }] }
|
|
201
|
+
];
|
|
202
|
+
TableCellTypeDecimalComponent.propDecorators = {
|
|
203
|
+
value: [{ type: Input }]
|
|
204
|
+
};
|
|
205
|
+
|
|
71
206
|
class TableCellTypeIconComponent {
|
|
72
207
|
constructor(_cdf, _tableCellTypeHelpers, _datatable, _table, _tableData) {
|
|
73
208
|
this._cdf = _cdf;
|
|
@@ -211,7 +346,7 @@ TableCellTypeIconComponent.decorators = [
|
|
|
211
346
|
selector: 'seam-table-cell-type-icon',
|
|
212
347
|
template: "<ng-container *ngIf=\"_icon\">\n <div *ngIf=\"!_tplType || _tplType === 'default'\"\n class=\"d-flex align-items-center justify-center\"\n [class.datatable-icon-fix]=\"_isDatatable\">\n <a class=\"d-block m-auto{{ _linkClass ? ' ' + _linkClass : '' }}\"\n [attr.title]=\"_tooltipDisabled ? _title : undefined\"\n [attr.target]=\"_target\"\n [ngbTooltip]=\"_tooltip\"\n [tooltipClass]=\"$any(_tooltipClass)\"\n [placement]=\"$any(_tooltipPlacement)\"\n [container]=\"$any(_tooltipContainer)\"\n [disableTooltip]=\"_tooltipDisabled\">\n <seam-icon [icon]=\"_icon\" size=\"lg\" [iconType]=\"_iconType\" [iconClass]=\"_iconClass || ''\"></seam-icon>\n <span *ngIf=\"_srOnly\" class=\"sr-only\">{{ _srOnly }}</span>\n </a>\n </div>\n\n <div *ngIf=\"_tplType === 'link'\"\n class=\"d-flex align-items-center justify-center\"\n [class.datatable-icon-fix]=\"_isDatatable\">\n <a class=\"d-block m-auto{{ _linkClass ? ' ' + _linkClass : '' }}\"\n [routerLink]=\"_link\"\n [queryParams]=\"_queryParams\"\n [attr.title]=\"_tooltipDisabled ? _title : undefined\"\n [attr.target]=\"_target\"\n [ngbTooltip]=\"_tooltip\"\n [tooltipClass]=\"$any(_tooltipClass)\"\n [placement]=\"$any(_tooltipPlacement)\"\n [container]=\"$any(_tooltipContainer)\"\n [disableTooltip]=\"_tooltipDisabled\">\n <seam-icon *ngIf=\"_icon\" [icon]=\"_icon\" size=\"lg\" [iconType]=\"_iconType\" [iconClass]=\"_iconClass\"></seam-icon>\n <span *ngIf=\"_srOnly\" class=\"sr-only\">{{ _srOnly }}</span>\n </a>\n </div>\n\n <div *ngIf=\"_tplType === 'link-external'\"\n class=\"d-flex align-items-center justify-center\"\n [class.datatable-icon-fix]=\"_isDatatable\">\n <a class=\"d-block m-auto{{ _linkClass ? ' ' + _linkClass : '' }}\"\n [attr.href]=\"_link\"\n [attr.title]=\"_tooltipDisabled ? _title : undefined\"\n [attr.target]=\"_target\"\n [ngbTooltip]=\"_tooltip\"\n [tooltipClass]=\"$any(_tooltipClass)\"\n [placement]=\"$any(_tooltipPlacement)\"\n [container]=\"$any(_tooltipContainer)\"\n [disableTooltip]=\"_tooltipDisabled\">\n <seam-icon *ngIf=\"_icon\" [icon]=\"_icon\" size=\"lg\" [iconType]=\"_iconType\" [iconClass]=\"_iconClass\"></seam-icon>\n <span *ngIf=\"_srOnly\" class=\"sr-only\">{{ _srOnly }}</span>\n </a>\n </div>\n\n <div *ngIf=\"_tplType === 'link-encrypted'\"\n class=\"d-flex align-items-center justify-center\"\n [class.datatable-icon-fix]=\"_isDatatable\">\n <button\n class=\"btn btn-link p-0 m-auto{{ _linkClass ? ' ' + _linkClass : '' }}\"\n type=\"button\"\n [seamEncryptedAssetLink]=\"_link\"\n [seamDetectMimeFromContent]=\"_detectMimeContent\"\n [seamDownloadAsset]=\"_download\"\n [attr.title]=\"_tooltipDisabled ? _title : undefined\"\n [ngbTooltip]=\"_tooltip\"\n [tooltipClass]=\"$any(_tooltipClass)\"\n [placement]=\"$any(_tooltipPlacement)\"\n [container]=\"$any(_tooltipContainer)\"\n [disableTooltip]=\"_tooltipDisabled\">\n <seam-icon *ngIf=\"_icon\" iconType=\"styled-square\" [icon]=\"_icon\" size=\"lg\" [iconType]=\"_iconType\" [iconClass]=\"_iconClass\"></seam-icon>\n <span *ngIf=\"_srOnly\" class=\"sr-only\">{{ _srOnly }}</span>\n </button>\n </div>\n\n <div *ngIf=\"_tplType === 'button'\"\n class=\"d-flex align-items-center justify-center\"\n [class.datatable-icon-fix]=\"_isDatatable\"\n (click)=\"_doButtonAction()\">\n <button\n class=\"btn btn-link p-0 m-auto{{ _linkClass ? ' ' + _linkClass : '' }}\"\n type=\"button\"\n [attr.title]=\"_tooltipDisabled ? _title : undefined\"\n [ngbTooltip]=\"_tooltip\"\n [tooltipClass]=\"$any(_tooltipClass)\"\n [placement]=\"$any(_tooltipPlacement)\"\n [container]=\"$any(_tooltipContainer)\"\n [disableTooltip]=\"_tooltipDisabled\">\n <seam-icon *ngIf=\"_icon\" iconType=\"styled-square\" [icon]=\"_icon\" size=\"lg\" [iconType]=\"_iconType\" [iconClass]=\"_iconClass\"></seam-icon>\n <span *ngIf=\"_srOnly\" class=\"sr-only\">{{ _srOnly }}</span>\n </button>\n </div>\n</ng-container>\n",
|
|
213
348
|
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
214
|
-
styles: [":host.datatable-cell-type ::ng-deep .seam-icon--img{max-height:40px}:host.datatable-cell-type a{max-height:40px}:host.datatable-cell-type button{max-height:40px}:host:not(.datatable-cell-type) ::ng-deep .seam-icon--img{max-height:20px}:host:not(.datatable-cell-type) a{max-height:20px}:host:not(.datatable-cell-type) button{max-height:20px}.datatable-icon-fix{margin-top:calc(-1px - .75rem);height:calc(50px)}"]
|
|
349
|
+
styles: [":host.datatable-cell-type ::ng-deep .seam-icon--img{max-height:40px}:host.datatable-cell-type a{max-height:40px}:host.datatable-cell-type button{max-height:40px}:host:not(.datatable-cell-type) ::ng-deep .seam-icon--img{max-height:20px}:host:not(.datatable-cell-type) a{max-height:20px}:host:not(.datatable-cell-type) button{max-height:20px}.datatable-icon-fix{margin-top:calc(-1px - .75rem);height:calc(50px)}\n"]
|
|
215
350
|
},] }
|
|
216
351
|
];
|
|
217
352
|
TableCellTypeIconComponent.ctorParameters = () => [
|
|
@@ -227,6 +362,70 @@ TableCellTypeIconComponent.propDecorators = {
|
|
|
227
362
|
_isDatatable: [{ type: HostBinding, args: ['class.datatable-cell-type',] }]
|
|
228
363
|
};
|
|
229
364
|
|
|
365
|
+
class TableCellTypeIntegerComponent {
|
|
366
|
+
constructor(_cdf, _tableCellTypeHelpers, _tableData) {
|
|
367
|
+
var _a, _b;
|
|
368
|
+
this._cdf = _cdf;
|
|
369
|
+
this._tableCellTypeHelpers = _tableCellTypeHelpers;
|
|
370
|
+
this._ngUnsubscribe = new Subject();
|
|
371
|
+
const tableData = _tableData;
|
|
372
|
+
this.value = tableData && this._formatInteger(tableData.value, tableData);
|
|
373
|
+
this.row = tableData && tableData.row;
|
|
374
|
+
this.rowIndex = tableData && tableData.rowIndex;
|
|
375
|
+
this.colData = tableData && tableData.colData;
|
|
376
|
+
this.textAlign = this._parseConfigValue((_b = (_a = tableData === null || tableData === void 0 ? void 0 : tableData.colData) === null || _a === void 0 ? void 0 : _a.cellTypeConfig) === null || _b === void 0 ? void 0 : _b.textAlign, tableData) || 'right';
|
|
377
|
+
if (tableData) {
|
|
378
|
+
tableData.changed
|
|
379
|
+
.pipe(takeUntil(this._ngUnsubscribe))
|
|
380
|
+
.subscribe(v => {
|
|
381
|
+
if (v.changes.hasOwnProperty('value')) {
|
|
382
|
+
this.value = this._formatInteger(v.changes.value.currentValue, tableData);
|
|
383
|
+
this._cdf.markForCheck();
|
|
384
|
+
}
|
|
385
|
+
if (v.changes.hasOwnProperty('colData')) {
|
|
386
|
+
this.colData = v.changes.colData.currentValue;
|
|
387
|
+
this._cdf.markForCheck();
|
|
388
|
+
}
|
|
389
|
+
});
|
|
390
|
+
}
|
|
391
|
+
}
|
|
392
|
+
ngOnInit() { }
|
|
393
|
+
ngOnDestroy() {
|
|
394
|
+
this._ngUnsubscribe.next();
|
|
395
|
+
this._ngUnsubscribe.complete();
|
|
396
|
+
}
|
|
397
|
+
_formatInteger(currentValue, tableData) {
|
|
398
|
+
var _a;
|
|
399
|
+
const config = (_a = tableData === null || tableData === void 0 ? void 0 : tableData.colData) === null || _a === void 0 ? void 0 : _a.cellTypeConfig;
|
|
400
|
+
const formatInteger = notNullOrUndefined(config === null || config === void 0 ? void 0 : config.formatNumber) ?
|
|
401
|
+
this._parseConfigValue(coerceBooleanProperty(config === null || config === void 0 ? void 0 : config.formatNumber), tableData) : true;
|
|
402
|
+
const locale = this._parseConfigValue(config === null || config === void 0 ? void 0 : config.locale, tableData) || 'en-US';
|
|
403
|
+
const minIntegerDigits = this._parseConfigValue(config === null || config === void 0 ? void 0 : config.minIntegerDigits, tableData) || 1;
|
|
404
|
+
const format = `${minIntegerDigits}.0-0`;
|
|
405
|
+
return formatInteger ? formatNumber(currentValue, locale, format) : currentValue;
|
|
406
|
+
}
|
|
407
|
+
_parseConfigValue(val, tableData) {
|
|
408
|
+
const contextFn = () => this._tableCellTypeHelpers.getValueContext(val, tableData);
|
|
409
|
+
return this._tableCellTypeHelpers.parseValueProp(val, contextFn);
|
|
410
|
+
}
|
|
411
|
+
}
|
|
412
|
+
TableCellTypeIntegerComponent.decorators = [
|
|
413
|
+
{ type: Component, args: [{
|
|
414
|
+
selector: 'seam-table-cell-type-integer',
|
|
415
|
+
template: "<div [class]=\"'text-' + textAlign\">\n <seam-table-cell-type-selector\n type=\"string\"\n [value]=\"value\"\n [rowIndex]=\"rowIndex\"\n [row]=\"row\"\n [colData]=\"colData\"></seam-table-cell-type-selector>\n</div>\n",
|
|
416
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
417
|
+
styles: [""]
|
|
418
|
+
},] }
|
|
419
|
+
];
|
|
420
|
+
TableCellTypeIntegerComponent.ctorParameters = () => [
|
|
421
|
+
{ type: ChangeDetectorRef },
|
|
422
|
+
{ type: TableCellTypesHelpersService },
|
|
423
|
+
{ type: undefined, decorators: [{ type: Optional }, { type: Inject, args: [TABLE_CELL_DATA,] }] }
|
|
424
|
+
];
|
|
425
|
+
TableCellTypeIntegerComponent.propDecorators = {
|
|
426
|
+
value: [{ type: Input }]
|
|
427
|
+
};
|
|
428
|
+
|
|
230
429
|
class TableCellTypePhoneComponent {
|
|
231
430
|
constructor(_cdf, _tableData) {
|
|
232
431
|
this._cdf = _cdf;
|
|
@@ -499,7 +698,7 @@ TableCellTypeProgressCircleComponent.decorators = [
|
|
|
499
698
|
selector: 'seam-table-cell-type-progress-circle',
|
|
500
699
|
template: "<ng-container *ngIf=\"!_tplType || _tplType === 'default'\">\n <ng-template [ngTemplateOutlet]=\"progressCircleTpl\"></ng-template>\n</ng-container>\n\n<ng-container *ngIf=\"_tplType === 'link'\">\n <a class=\"d-block m-auto{{ _linkClass ? ' ' + _linkClass : '' }}\"\n [routerLink]=\"_link\"\n [queryParams]=\"_queryParams\"\n [attr.title]=\"_tooltipDisabled ? _title : undefined\"\n [attr.target]=\"_target\">\n <ng-template [ngTemplateOutlet]=\"progressCircleTpl\"></ng-template>\n\n </a>\n</ng-container>\n\n<ng-container *ngIf=\"_tplType === 'link-external'\"\n class=\"d-flex align-items-center justify-center\"\n [class.datatable-icon-fix]=\"_isDatatable\">\n <a class=\"d-block m-auto{{ _linkClass ? ' ' + _linkClass : '' }}\"\n [attr.href]=\"_link\"\n [attr.title]=\"_tooltipDisabled ? _title : undefined\"\n [attr.target]=\"_target\">\n <ng-template [ngTemplateOutlet]=\"progressCircleTpl\"></ng-template>\n </a>\n</ng-container>\n\n<ng-container *ngIf=\"_tplType === 'link-encrypted'\"\n class=\"d-flex align-items-center justify-center\"\n [class.datatable-icon-fix]=\"_isDatatable\">\n <button\n class=\"btn btn-link p-0 m-auto{{ _linkClass ? ' ' + _linkClass : '' }}\"\n type=\"button\"\n [seamEncryptedAssetLink]=\"_link\"\n [seamDetectMimeFromContent]=\"_detectMimeContent\"\n [seamDownloadAsset]=\"_download\"\n [attr.title]=\"_tooltipDisabled ? _title : undefined\">\n <ng-template [ngTemplateOutlet]=\"progressCircleTpl\"></ng-template>\n </button>\n</ng-container>\n\n<ng-container *ngIf=\"_tplType === 'button'\"\n class=\"d-flex align-items-center justify-center\"\n [class.datatable-icon-fix]=\"_isDatatable\"\n (click)=\"_doButtonAction()\">\n <button\n class=\"btn btn-link p-0 m-auto{{ _linkClass ? ' ' + _linkClass : '' }}\"\n type=\"button\"\n [attr.title]=\"_tooltipDisabled ? _title : undefined\">\n <ng-template [ngTemplateOutlet]=\"progressCircleTpl\"></ng-template>\n </button>\n</ng-container>\n\n<ng-template #progressCircleTpl>\n <div class=\"progress-circle-wrapper\">\n <seam-progress-circle\n class=\"progress-circle\"\n [fillBackground]=\"fillBackground\"\n [showText]=\"showText\"\n [hiddenOnEmpty]=\"hiddenOnEmpty\"\n [percentage]=\"$any(value)\"\n [pending]=\"pending\"\n [ngbTooltip]=\"tooltip\"\n [tooltipClass]=\"$any(tooltipClass)\"\n [placement]=\"$any(tooltipPlacement)\"\n [container]=\"$any(tooltipContainer)\">\n </seam-progress-circle>\n <span *ngIf=\"_srOnly\" class=\"sr-only\">{{ _srOnly }}</span>\n </div>\n</ng-template>\n",
|
|
501
700
|
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
502
|
-
styles: [":host.datatable-cell-type .progress-circle-wrapper{max-height:25px}:host.datatable-cell-type .progress-circle{position:relative;width:25px;height:25px;margin:0 auto}:host.datatable-cell-type .progress-circle ::ng-deep .seam-progress-circle{padding:0}:host:not(.datatable-cell-type) .progress-circle-wrapper{height:22px;max-height:22px}:host:not(.datatable-cell-type) .progress-circle{position:relative;width:25px;height:25px;margin:calc(-.03rem)
|
|
701
|
+
styles: [":host.datatable-cell-type .progress-circle-wrapper{max-height:25px}:host.datatable-cell-type .progress-circle{position:relative;width:25px;height:25px;margin:0 auto}:host.datatable-cell-type .progress-circle ::ng-deep .seam-progress-circle{padding:0}:host:not(.datatable-cell-type) .progress-circle-wrapper{height:22px;max-height:22px}:host:not(.datatable-cell-type) .progress-circle{position:relative;width:25px;height:25px;margin:0 auto;margin-top:calc(-.03rem)}:host:not(.datatable-cell-type) .progress-circle ::ng-deep .seam-progress-circle{padding:0}\n"]
|
|
503
702
|
},] }
|
|
504
703
|
];
|
|
505
704
|
TableCellTypeProgressCircleComponent.ctorParameters = () => [
|
|
@@ -668,17 +867,17 @@ const TABLE_CELL_TYPE_MANIFEST_STRING = {
|
|
|
668
867
|
multi: true
|
|
669
868
|
};
|
|
670
869
|
const ɵ1 = {
|
|
671
|
-
name: '
|
|
672
|
-
component:
|
|
870
|
+
name: 'currency',
|
|
871
|
+
component: TableCellTypeCurrencyComponent
|
|
673
872
|
};
|
|
674
|
-
const
|
|
873
|
+
const TABLE_CELL_TYPE_MANIFEST_CURRENCY = {
|
|
675
874
|
provide: TABLE_CELL_TYPE_MANIFEST,
|
|
676
875
|
useValue: ɵ1,
|
|
677
876
|
multi: true
|
|
678
877
|
};
|
|
679
878
|
const ɵ2 = {
|
|
680
879
|
name: 'decimal',
|
|
681
|
-
component:
|
|
880
|
+
component: TableCellTypeDecimalComponent
|
|
682
881
|
};
|
|
683
882
|
const TABLE_CELL_TYPE_MANIFEST_DECIMAL = {
|
|
684
883
|
provide: TABLE_CELL_TYPE_MANIFEST,
|
|
@@ -686,64 +885,76 @@ const TABLE_CELL_TYPE_MANIFEST_DECIMAL = {
|
|
|
686
885
|
multi: true
|
|
687
886
|
};
|
|
688
887
|
const ɵ3 = {
|
|
888
|
+
name: 'integer',
|
|
889
|
+
component: TableCellTypeIntegerComponent
|
|
890
|
+
};
|
|
891
|
+
const TABLE_CELL_TYPE_MANIFEST_INTEGER = {
|
|
892
|
+
provide: TABLE_CELL_TYPE_MANIFEST,
|
|
893
|
+
useValue: ɵ3,
|
|
894
|
+
multi: true
|
|
895
|
+
};
|
|
896
|
+
const ɵ4 = {
|
|
689
897
|
name: 'date',
|
|
690
898
|
component: TableCellTypeDateComponent
|
|
691
899
|
};
|
|
692
900
|
const TABLE_CELL_TYPE_MANIFEST_DATE = {
|
|
693
901
|
provide: TABLE_CELL_TYPE_MANIFEST,
|
|
694
|
-
useValue: ɵ
|
|
902
|
+
useValue: ɵ4,
|
|
695
903
|
multi: true
|
|
696
904
|
};
|
|
697
|
-
const ɵ
|
|
905
|
+
const ɵ5 = {
|
|
698
906
|
name: 'icon',
|
|
699
907
|
component: TableCellTypeIconComponent
|
|
700
908
|
};
|
|
701
909
|
const TABLE_CELL_TYPE_MANIFEST_ICON = {
|
|
702
910
|
provide: TABLE_CELL_TYPE_MANIFEST,
|
|
703
|
-
useValue: ɵ
|
|
911
|
+
useValue: ɵ5,
|
|
704
912
|
multi: true
|
|
705
913
|
};
|
|
706
|
-
const ɵ
|
|
914
|
+
const ɵ6 = {
|
|
707
915
|
name: 'image',
|
|
708
916
|
component: TableCellTypeIconComponent
|
|
709
917
|
};
|
|
710
918
|
const TABLE_CELL_TYPE_MANIFEST_IMAGE = {
|
|
711
919
|
provide: TABLE_CELL_TYPE_MANIFEST,
|
|
712
|
-
useValue: ɵ
|
|
920
|
+
useValue: ɵ6,
|
|
713
921
|
multi: true
|
|
714
922
|
};
|
|
715
|
-
const ɵ
|
|
923
|
+
const ɵ7 = {
|
|
716
924
|
name: 'progress-circle',
|
|
717
925
|
component: TableCellTypeProgressCircleComponent
|
|
718
926
|
};
|
|
719
927
|
const TABLE_CELL_TYPE_MANIFEST_PROGRESS_CIRCLE = {
|
|
720
928
|
provide: TABLE_CELL_TYPE_MANIFEST,
|
|
721
|
-
useValue: ɵ
|
|
929
|
+
useValue: ɵ7,
|
|
722
930
|
multi: true
|
|
723
931
|
};
|
|
724
|
-
const ɵ
|
|
932
|
+
const ɵ8 = {
|
|
725
933
|
name: 'progress-circle-icon',
|
|
726
934
|
component: TableCellTypeProgressCircleIconComponent
|
|
727
935
|
};
|
|
728
936
|
const TABLE_CELL_TYPE_MANIFEST_PROGRESS_CIRCLE_ICON = {
|
|
729
937
|
provide: TABLE_CELL_TYPE_MANIFEST,
|
|
730
|
-
useValue: ɵ
|
|
938
|
+
useValue: ɵ8,
|
|
731
939
|
multi: true
|
|
732
940
|
};
|
|
733
|
-
const ɵ
|
|
941
|
+
const ɵ9 = {
|
|
734
942
|
name: 'phone',
|
|
735
943
|
component: TableCellTypePhoneComponent
|
|
736
944
|
};
|
|
737
945
|
const TABLE_CELL_TYPE_MANIFEST_PHONE = {
|
|
738
946
|
provide: TABLE_CELL_TYPE_MANIFEST,
|
|
739
|
-
useValue: ɵ
|
|
947
|
+
useValue: ɵ9,
|
|
740
948
|
multi: true
|
|
741
949
|
};
|
|
742
950
|
|
|
743
951
|
const cellTypeComponents = [
|
|
744
952
|
TableCellTypeStringComponent,
|
|
953
|
+
TableCellTypeCurrencyComponent,
|
|
745
954
|
TableCellTypeDateComponent,
|
|
955
|
+
TableCellTypeDecimalComponent,
|
|
746
956
|
TableCellTypeIconComponent,
|
|
957
|
+
TableCellTypeIntegerComponent,
|
|
747
958
|
TableCellTypeProgressCircleComponent,
|
|
748
959
|
TableCellTypeProgressCircleIconComponent,
|
|
749
960
|
TableCellTypePhoneComponent
|
|
@@ -751,6 +962,7 @@ const cellTypeComponents = [
|
|
|
751
962
|
const cellTypeProviders = [
|
|
752
963
|
TABLE_CELL_TYPE_MANIFEST_STRING,
|
|
753
964
|
TABLE_CELL_TYPE_MANIFEST_INTEGER,
|
|
965
|
+
TABLE_CELL_TYPE_MANIFEST_CURRENCY,
|
|
754
966
|
TABLE_CELL_TYPE_MANIFEST_DECIMAL,
|
|
755
967
|
TABLE_CELL_TYPE_MANIFEST_DATE,
|
|
756
968
|
TABLE_CELL_TYPE_MANIFEST_ICON,
|
|
@@ -795,5 +1007,5 @@ TheSeamTableCellTypesModule.decorators = [
|
|
|
795
1007
|
* Generated bundle index. Do not edit.
|
|
796
1008
|
*/
|
|
797
1009
|
|
|
798
|
-
export { TABLE_CELL_TYPE_MANIFEST_DATE, TABLE_CELL_TYPE_MANIFEST_DECIMAL, TABLE_CELL_TYPE_MANIFEST_ICON, TABLE_CELL_TYPE_MANIFEST_IMAGE, TABLE_CELL_TYPE_MANIFEST_INTEGER, TABLE_CELL_TYPE_MANIFEST_PHONE, TABLE_CELL_TYPE_MANIFEST_PROGRESS_CIRCLE, TABLE_CELL_TYPE_MANIFEST_PROGRESS_CIRCLE_ICON, TABLE_CELL_TYPE_MANIFEST_STRING, TableCellTypeDateComponent, TableCellTypeIconComponent, TableCellTypePhoneComponent, TableCellTypeProgressCircleComponent, TableCellTypeProgressCircleIconComponent, TableCellTypeStringComponent, TheSeamTableCellTypesModule, ɵ0, ɵ1, ɵ2, ɵ3, ɵ4, ɵ5, ɵ6, ɵ7, ɵ8 };
|
|
1010
|
+
export { TABLE_CELL_TYPE_MANIFEST_CURRENCY, TABLE_CELL_TYPE_MANIFEST_DATE, TABLE_CELL_TYPE_MANIFEST_DECIMAL, TABLE_CELL_TYPE_MANIFEST_ICON, TABLE_CELL_TYPE_MANIFEST_IMAGE, TABLE_CELL_TYPE_MANIFEST_INTEGER, TABLE_CELL_TYPE_MANIFEST_PHONE, TABLE_CELL_TYPE_MANIFEST_PROGRESS_CIRCLE, TABLE_CELL_TYPE_MANIFEST_PROGRESS_CIRCLE_ICON, TABLE_CELL_TYPE_MANIFEST_STRING, TableCellTypeCurrencyComponent, TableCellTypeDateComponent, TableCellTypeDecimalComponent, TableCellTypeIconComponent, TableCellTypeIntegerComponent, TableCellTypePhoneComponent, TableCellTypeProgressCircleComponent, TableCellTypeProgressCircleIconComponent, TableCellTypeStringComponent, TheSeamTableCellTypesModule, ɵ0, ɵ1, ɵ2, ɵ3, ɵ4, ɵ5, ɵ6, ɵ7, ɵ8, ɵ9 };
|
|
799
1011
|
//# sourceMappingURL=theseam-ui-common-table-cell-types.js.map
|