@theseam/ui-common 0.2.8 → 0.2.12

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.
Files changed (65) hide show
  1. package/bundles/theseam-ui-common-data-exporter.umd.js.map +1 -1
  2. package/bundles/theseam-ui-common-datatable.umd.js +54 -4
  3. package/bundles/theseam-ui-common-datatable.umd.js.map +1 -1
  4. package/bundles/theseam-ui-common-framework.umd.js +2 -2
  5. package/bundles/theseam-ui-common-framework.umd.js.map +1 -1
  6. package/bundles/theseam-ui-common-table-cell-types.umd.js +245 -19
  7. package/bundles/theseam-ui-common-table-cell-types.umd.js.map +1 -1
  8. package/bundles/theseam-ui-common-utils.umd.js.map +1 -1
  9. package/data-exporter/data-exporter.d.ts +4 -0
  10. package/data-exporter/theseam-ui-common-data-exporter.metadata.json +1 -1
  11. package/datatable/datatable/datatable.component.d.ts +2 -0
  12. package/datatable/datatable-footer/datatable-footer-tpl.directive.d.ts +5 -0
  13. package/datatable/datatable-footer/datatable-footer.directive.d.ts +6 -0
  14. package/datatable/public-api.d.ts +2 -0
  15. package/datatable/theseam-ui-common-datatable.metadata.json +1 -1
  16. package/esm2015/data-exporter/data-exporter.js +1 -1
  17. package/esm2015/datatable/datatable/datatable.component.js +5 -3
  18. package/esm2015/datatable/datatable-export-button/datatable-export-button.component.js +8 -3
  19. package/esm2015/datatable/datatable-footer/datatable-footer-tpl.directive.js +15 -0
  20. package/esm2015/datatable/datatable-footer/datatable-footer.directive.js +18 -0
  21. package/esm2015/datatable/datatable.module.js +7 -1
  22. package/esm2015/datatable/public-api.js +3 -1
  23. package/esm2015/framework/side-nav/side-nav-item/side-nav-item.component.js +3 -3
  24. package/esm2015/table-cell-types/public-api.js +8 -1
  25. package/esm2015/table-cell-types/table-cell-type-currency/table-cell-type-currency-config.js +2 -0
  26. package/esm2015/table-cell-types/table-cell-type-currency/table-cell-type-currency.component.js +74 -0
  27. package/esm2015/table-cell-types/table-cell-type-currency/table-cell-type-currency.js +2 -0
  28. package/esm2015/table-cell-types/table-cell-type-decimal/table-cell-type-decimal-config.js +1 -1
  29. package/esm2015/table-cell-types/table-cell-type-decimal/table-cell-type-decimal.component.js +73 -0
  30. package/esm2015/table-cell-types/table-cell-type-decimal/table-cell-type-decimal.js +2 -0
  31. package/esm2015/table-cell-types/table-cell-type-integer/table-cell-type-integer-config.js +1 -1
  32. package/esm2015/table-cell-types/table-cell-type-integer/table-cell-type-integer.component.js +71 -0
  33. package/esm2015/table-cell-types/table-cell-type-integer/table-cell-type-integer.js +2 -0
  34. package/esm2015/table-cell-types/table-cell-type-manifests.js +29 -17
  35. package/esm2015/table-cell-types/table-cell-types.module.js +9 -2
  36. package/esm2015/utils/router/is-empty-url-route.js +1 -1
  37. package/fesm2015/theseam-ui-common-data-exporter.js.map +1 -1
  38. package/fesm2015/theseam-ui-common-datatable.js +45 -5
  39. package/fesm2015/theseam-ui-common-datatable.js.map +1 -1
  40. package/fesm2015/theseam-ui-common-framework.js +2 -2
  41. package/fesm2015/theseam-ui-common-framework.js.map +1 -1
  42. package/fesm2015/theseam-ui-common-table-cell-types.js +232 -20
  43. package/fesm2015/theseam-ui-common-table-cell-types.js.map +1 -1
  44. package/fesm2015/theseam-ui-common-utils.js.map +1 -1
  45. package/framework/side-nav/side-nav-item/side-nav-item.component.scss +36 -9
  46. package/framework/theseam-ui-common-framework.metadata.json +1 -1
  47. package/package.json +1 -1
  48. package/styles/common/_table.scss +0 -5
  49. package/styles/vendor/ngx-datatable/_ngx-datatable.scss +478 -87
  50. package/styles/vendor/ngx-datatable/_themes/bootstrap/_variables.scss +174 -0
  51. package/styles/vendor/ngx-datatable/_themes/dark/_variables.scss +166 -0
  52. package/styles/vendor/ngx-datatable/_themes/material/_variables.scss +165 -0
  53. package/styles/vendor/ngx-datatable/_variables.scss +3 -0
  54. package/table-cell-types/public-api.d.ts +7 -0
  55. package/table-cell-types/table-cell-type-currency/table-cell-type-currency-config.d.ts +39 -0
  56. package/table-cell-types/table-cell-type-currency/table-cell-type-currency.component.d.ts +19 -0
  57. package/table-cell-types/table-cell-type-currency/table-cell-type-currency.d.ts +3 -0
  58. package/table-cell-types/table-cell-type-decimal/table-cell-type-decimal-config.d.ts +31 -1
  59. package/table-cell-types/table-cell-type-decimal/table-cell-type-decimal.component.d.ts +19 -0
  60. package/table-cell-types/table-cell-type-decimal/table-cell-type-decimal.d.ts +3 -0
  61. package/table-cell-types/table-cell-type-integer/table-cell-type-integer-config.d.ts +23 -1
  62. package/table-cell-types/table-cell-type-integer/table-cell-type-integer.component.d.ts +19 -0
  63. package/table-cell-types/table-cell-type-integer/table-cell-type-integer.d.ts +3 -0
  64. package/table-cell-types/table-cell-type-manifests.d.ts +2 -1
  65. package/table-cell-types/theseam-ui-common-table-cell-types.metadata.json +1 -1
@@ -1 +1 @@
1
- {"version":3,"file":"theseam-ui-common-table-cell-types.js","sources":["../../../projects/ui-common/table-cell-types/table-cell-type-date/table-cell-type-date.component.ts","../../../projects/ui-common/table-cell-types/table-cell-type-icon/table-cell-type-icon.component.ts","../../../projects/ui-common/table-cell-types/table-cell-type-phone/table-cell-type-phone.component.ts","../../../projects/ui-common/table-cell-types/table-cell-type-progress-circle-icon/table-cell-type-progress-circle-icon.component.ts","../../../projects/ui-common/table-cell-types/table-cell-type-progress-circle/table-cell-type-progress-circle.component.ts","../../../projects/ui-common/table-cell-types/table-cell-type-string/table-cell-type-string.component.ts","../../../projects/ui-common/table-cell-types/table-cell-type-manifests.ts","../../../projects/ui-common/table-cell-types/table-cell-types.module.ts","../../../projects/ui-common/table-cell-types/theseam-ui-common-table-cell-types.ts"],"sourcesContent":["import { ChangeDetectionStrategy, ChangeDetectorRef, Component, Inject, Input, OnDestroy, OnInit, Optional } from '@angular/core'\nimport { Subject } from 'rxjs'\nimport { takeUntil } from 'rxjs/operators'\n\nimport { TABLE_CELL_DATA } from '@theseam/ui-common/table-cell-type'\nimport type { TableCellData } from '@theseam/ui-common/table-cell-type'\n\nimport { TableCellTypeConfigDate } from './table-cell-type-date-config'\n\n@Component({\n selector: 'seam-table-cell-type-date',\n templateUrl: './table-cell-type-date.component.html',\n styleUrls: ['./table-cell-type-date.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush\n})\nexport class TableCellTypeDateComponent implements OnInit, OnDestroy {\n\n private readonly _ngUnsubscribe = new Subject()\n\n @Input() value: string | undefined | null\n @Input() format: string | undefined | null\n\n constructor(\n private _cdf: ChangeDetectorRef,\n @Optional() @Inject(TABLE_CELL_DATA) _tableData?: TableCellData<'date', TableCellTypeConfigDate>\n ) {\n const _data = _tableData\n\n this.value = _data && _data.value\n this.format = _data && _data.colData && _data.colData.cellTypeConfig && _data.colData.cellTypeConfig.format\n\n if (_data) {\n _data.changed\n .pipe(takeUntil(this._ngUnsubscribe))\n .subscribe(v => {\n if (v.changes.hasOwnProperty('value')) {\n this.value = v.changes.value.currentValue\n this._cdf.markForCheck()\n }\n\n if (v.changes.hasOwnProperty('colData')) {\n const colData = v.changes.colData.currentValue\n if (colData && colData.format !== this.format) {\n this.format = colData.format\n } else {\n this.format = undefined\n }\n this._cdf.markForCheck()\n }\n })\n }\n }\n\n ngOnInit() { }\n\n ngOnDestroy() {\n this._ngUnsubscribe.next()\n this._ngUnsubscribe.complete()\n }\n\n}\n","import {\n ChangeDetectionStrategy,\n ChangeDetectorRef,\n Component,\n HostBinding,\n Inject,\n Input,\n OnDestroy,\n OnInit,\n Optional\n} from '@angular/core'\nimport { Subject } from 'rxjs'\nimport { takeUntil } from 'rxjs/operators'\n\nimport { DatatableComponent } from '@theseam/ui-common/datatable'\nimport { getKnownIcon, SeamIcon, TheSeamIconType } from '@theseam/ui-common/icon'\nimport { TableComponent } from '@theseam/ui-common/table'\nimport { TableCellTypesHelpersService, TABLE_CELL_DATA } from '@theseam/ui-common/table-cell-type'\nimport type { TableCellData, TheSeamTableColumn } from '@theseam/ui-common/table-cell-type'\n\nimport { TableCellTypeConfigIcon, TableCellTypeIconConfigAction } from './table-cell-type-icon-config'\n\nexport type IconTemplateType = 'default' | 'link' | 'link-external' | 'link-encrypted' | 'button'\n\n@Component({\n selector: 'seam-table-cell-type-icon',\n templateUrl: './table-cell-type-icon.component.html',\n styleUrls: ['./table-cell-type-icon.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush\n})\nexport class TableCellTypeIconComponent<R = any, V = any> implements OnInit, OnDestroy {\n\n private readonly _ngUnsubscribe = new Subject()\n\n @Input()\n get value() { return this._value }\n set value(value: string | undefined | null) {\n this._value = value\n this._icon = value ? getKnownIcon(value) || value : value\n }\n private _value: string | undefined | null\n\n @Input()\n get config() { return this._config }\n set config(value: TableCellTypeConfigIcon | undefined | null) {\n this._config = value\n if (value) {\n this.setAction(value.action)\n this._linkClass = this._parseConfigValue(value.linkClass)\n this._iconClass = this._parseConfigValue(value.iconClass)\n this._iconType = value.iconType\n this._title = this._parseConfigValue(value.titleAttr)\n this._srOnly = this._parseConfigValue(value.srOnly)\n this._tooltip = this._parseConfigValue(value.tooltip)\n if (this._tooltip) {\n this._tooltipClass = this._parseConfigValue(value.tooltipClass)\n this._tooltipPlacement = this._parseConfigValue(value.tooltipPlacement) || 'auto'\n this._tooltipContainer = this._parseConfigValue(value.tooltipContainer)\n this._tooltipDisabled = false\n } else {\n this._tooltipDisabled = true\n }\n }\n }\n private _config: TableCellTypeConfigIcon | undefined | null\n\n _icon: SeamIcon | undefined | null\n _link?: string\n _queryParams?: { [k: string]: any }\n _tplType: IconTemplateType = 'default'\n _title?: string\n _srOnly?: string\n _linkClass?: string\n _iconClass?: string\n _iconType?: TheSeamIconType\n _target?: string\n _tooltip?: string\n _tooltipClass?: string\n _tooltipPlacement?: string\n _tooltipContainer?: string\n _tooltipDisabled: boolean = true\n\n _buttonAction?: TableCellTypeIconConfigAction\n\n _tableCellData?: TableCellData<'icon', TableCellTypeConfigIcon>\n _row?: any\n _rowIndex?: number\n _colData?: TheSeamTableColumn<'icon', TableCellTypeConfigIcon>\n\n _download?: boolean\n _detectMimeContent?: boolean\n\n @HostBinding('class.datatable-cell-type') _isDatatable = false\n\n constructor(\n private _cdf: ChangeDetectorRef,\n private _tableCellTypeHelpers: TableCellTypesHelpersService,\n @Optional() private _datatable?: DatatableComponent,\n @Optional() private _table?: TableComponent,\n @Optional() @Inject(TABLE_CELL_DATA) _tableData?: TableCellData<'icon', TableCellTypeConfigIcon>\n ) {\n if (_datatable) {\n this._isDatatable = true\n // console.log('isDataTable')\n }\n // if (_table) {\n // console.log('isTable')\n // }\n\n const _data = _tableData\n this._tableCellData = _tableData\n\n this._row = _data && _data.row\n this._rowIndex = _data && _data.rowIndex\n\n this.value = _data && _data.value\n this._colData = _data && _data.colData\n if (_data && _data.colData && (<any>_data.colData).cellTypeConfig) {\n this.config = (<any>_data.colData).cellTypeConfig\n }\n\n if (_data) {\n _data.changed\n .pipe(takeUntil(this._ngUnsubscribe))\n .subscribe(v => {\n if (v.changes.hasOwnProperty('value')) {\n this.value = v.changes.value.currentValue\n this.config = this._config\n this._cdf.markForCheck()\n }\n\n if (v.changes.hasOwnProperty('colData')) {\n const colData = v.changes.colData.currentValue\n if (colData && colData.cellTypeConfig !== this.config) {\n this.config = colData.cellTypeConfig\n } else {\n this.config = undefined\n }\n this._cdf.markForCheck()\n } else {\n if (v.changes.hasOwnProperty('row')) {\n this.config = this.config\n this._cdf.markForCheck()\n }\n }\n })\n }\n }\n\n ngOnInit() { }\n\n ngOnDestroy() {\n this._ngUnsubscribe.next()\n this._ngUnsubscribe.complete()\n }\n\n public setAction(configAction?: TableCellTypeIconConfigAction) {\n let newTplType: IconTemplateType = 'default'\n let link: string | undefined\n let download: boolean = false\n let detectMimeContent = false\n let target: string | undefined\n let queryParams: { [l: string]: any } | undefined\n\n if (configAction) {\n if (configAction.type === 'link') {\n link = this._parseConfigValue(configAction.link)\n if (link !== undefined && link !== null) {\n newTplType = this._parseConfigValue(configAction.asset)\n ? 'link-encrypted'\n : this._parseConfigValue(configAction.external) ? 'link-external' : 'link'\n download = !!this._parseConfigValue(configAction.download)\n detectMimeContent = !!this._parseConfigValue(configAction.detectMimeContent)\n target = this._parseConfigValue(configAction.target)\n queryParams = this._parseConfigValue(configAction.queryParams)\n }\n } else if (configAction.type === 'modal') {\n newTplType = 'button'\n this._buttonAction = configAction\n }\n }\n\n this._tplType = newTplType\n this._link = link\n this._download = download\n this._detectMimeContent = detectMimeContent\n this._target = target\n this._queryParams = queryParams\n }\n\n private _parseConfigValue(val: any) {\n const contextFn = () => this._tableCellTypeHelpers.getValueContext(val, this._tableCellData)\n return this._tableCellTypeHelpers.parseValueProp(val, contextFn)\n }\n\n _doButtonAction() {\n if (this._buttonAction && this._buttonAction.type === 'modal') {\n const contextFn = () => this._tableCellTypeHelpers.getValueContext(this.value, this._tableCellData)\n this._tableCellTypeHelpers.handleModalAction(this._buttonAction, contextFn)\n .subscribe(\n r => {},\n err => console.error(err),\n () => this._actionRefreshRequest()\n )\n }\n }\n\n private _actionRefreshRequest() {\n if (this._datatable) {\n this._datatable.triggerActionRefreshRequest()\n } else if (this._table) {\n this._table.triggerActionRefreshRequest()\n }\n }\n\n}\n","import { ChangeDetectionStrategy, ChangeDetectorRef, Component, Inject, Input, OnDestroy, OnInit, Optional } from '@angular/core'\nimport { Subject } from 'rxjs'\nimport { takeUntil } from 'rxjs/operators'\n\nimport { TABLE_CELL_DATA } from '@theseam/ui-common/table-cell-type'\nimport type { TableCellData } from '@theseam/ui-common/table-cell-type'\nimport { coercePhoneNumberFormat, THESEAM_DEFAULT_PHONE_NUMBER_FORMAT } from '@theseam/ui-common/tel-input'\nimport type { intlTelInputUtils } from '@theseam/ui-common/tel-input'\nimport { hasProperty } from '@theseam/ui-common/utils'\n\nimport { TableCellTypeConfigPhone } from './table-cell-type-phone-config'\n\n@Component({\n selector: 'seam-table-cell-type-phone',\n templateUrl: './table-cell-type-phone.component.html',\n styleUrls: ['./table-cell-type-phone.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush\n})\nexport class TableCellTypePhoneComponent implements OnInit, OnDestroy {\n\n /** @ignore */\n private readonly _ngUnsubscribe = new Subject()\n\n /** @ignore */\n _format: intlTelInputUtils.numberFormat = THESEAM_DEFAULT_PHONE_NUMBER_FORMAT\n\n @Input() value?: string | null\n @Input()\n set format(value: intlTelInputUtils.numberFormat) { this._format = coercePhoneNumberFormat(value) }\n get format() { return this._format }\n\n constructor(\n private _cdf: ChangeDetectorRef,\n @Optional() @Inject(TABLE_CELL_DATA) _tableData?: TableCellData<'phone', TableCellTypeConfigPhone>\n ) {\n const _data = _tableData\n\n this.value = _data && _data.value\n if (_data && _data.colData && _data.colData.cellTypeConfig && hasProperty(_data.colData.cellTypeConfig, 'format')) {\n this.format = _data.colData.cellTypeConfig.format as intlTelInputUtils.numberFormat\n }\n\n if (_data) {\n _data.changed\n .pipe(takeUntil(this._ngUnsubscribe))\n .subscribe(v => {\n if (v.changes.hasOwnProperty('value')) {\n this.value = v.changes.value.currentValue\n this._cdf.markForCheck()\n }\n\n if (v.changes.hasOwnProperty('colData')) {\n const colData = v.changes.colData.currentValue\n if (colData && hasProperty(colData, 'cellTypeConfig') &&\n hasProperty(colData.cellTypeConfig, 'format') &&\n colData.cellTypeConfig.format !== this.format\n ) {\n this.format = colData.cellTypeConfig.format\n } else {\n this.format = THESEAM_DEFAULT_PHONE_NUMBER_FORMAT\n }\n this._cdf.markForCheck()\n }\n })\n }\n }\n\n ngOnInit() { }\n\n ngOnDestroy() {\n this._ngUnsubscribe.next()\n this._ngUnsubscribe.complete()\n }\n\n}\n","import { ChangeDetectionStrategy, ChangeDetectorRef, Component, Inject, Input, OnDestroy, OnInit, Optional } from '@angular/core'\nimport { Subject } from 'rxjs'\nimport { takeUntil } from 'rxjs/operators'\n\nimport { SeamIcon } from '@theseam/ui-common/icon'\nimport { TableCellTypesHelpersService, TABLE_CELL_DATA } from '@theseam/ui-common/table-cell-type'\nimport type { TableCellData, TheSeamTableColumn } from '@theseam/ui-common/table-cell-type'\n\nimport { TableCellTypeConfigProgressCircleIcon } from './table-cell-type-progress-circle-icon-config'\n\n@Component({\n selector: 'seam-table-cell-type-progress-circle-icon',\n templateUrl: './table-cell-type-progress-circle-icon.component.html',\n styleUrls: ['./table-cell-type-progress-circle-icon.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush\n})\nexport class TableCellTypeProgressCircleIconComponent implements OnInit, OnDestroy {\n\n private readonly _ngUnsubscribe = new Subject()\n\n @Input() value: number | null | undefined\n\n row?: any\n rowIndex?: number\n colData?: TheSeamTableColumn<'progress-circle-icon', TableCellTypeConfigProgressCircleIcon>\n\n displayIcon: boolean = false\n icon?: SeamIcon\n\n constructor(\n private _cdf: ChangeDetectorRef,\n private _tableCellTypeHelpers: TableCellTypesHelpersService,\n @Optional() @Inject(TABLE_CELL_DATA) _tableData?: TableCellData<'progress-circle-icon', TableCellTypeConfigProgressCircleIcon>\n ) {\n const tableData = _tableData\n this.value = tableData && tableData.value\n this.row = tableData && tableData.row\n this.rowIndex = tableData && tableData.rowIndex\n this.colData = tableData && tableData.colData\n\n this._setIcon(tableData)\n\n if (tableData) {\n tableData.changed\n .pipe(takeUntil(this._ngUnsubscribe))\n .subscribe(v => {\n if (v.changes.hasOwnProperty('value')) {\n this.value = v.changes.value.currentValue\n this._setIcon(tableData)\n this._cdf.markForCheck()\n }\n\n if (v.changes.hasOwnProperty('colData')) {\n this.colData = v.changes.colData.currentValue\n this._setIcon(tableData)\n this._cdf.markForCheck()\n } else {\n if (v.changes.hasOwnProperty('row')) {\n this._setIcon(tableData)\n this._cdf.markForCheck()\n }\n }\n })\n }\n }\n\n private _setIcon(tableData?: TableCellData<'progress-circle-icon', TableCellTypeConfigProgressCircleIcon>) {\n if (tableData &&\n tableData.colData &&\n tableData.colData.cellTypeConfig &&\n tableData.colData.cellTypeConfig.displayIcon &&\n tableData.colData.cellTypeConfig.icon &&\n this._parseConfigValue(tableData.colData.cellTypeConfig.displayIcon, tableData) &&\n this._parseConfigValue(tableData.colData.cellTypeConfig.icon, tableData)) {\n this.icon = this._parseConfigValue(tableData.colData.cellTypeConfig.icon, tableData)\n this.displayIcon = this._parseConfigValue(tableData.colData.cellTypeConfig.displayIcon, tableData)\n }\n }\n\n private _parseConfigValue(val: any, tableData?: TableCellData<'progress-circle-icon', TableCellTypeConfigProgressCircleIcon>) {\n const contextFn = () => this._tableCellTypeHelpers.getValueContext(val, tableData)\n return this._tableCellTypeHelpers.parseValueProp(val, contextFn)\n }\n\n ngOnInit() { }\n\n ngOnDestroy() {\n this._ngUnsubscribe.next()\n this._ngUnsubscribe.complete()\n }\n\n}\n","import { coerceBooleanProperty, coerceNumberProperty } from '@angular/cdk/coercion'\nimport {\n ChangeDetectionStrategy,\n ChangeDetectorRef,\n Component,\n HostBinding,\n Inject,\n Input,\n OnDestroy,\n OnInit,\n Optional\n} from '@angular/core'\nimport { Subject } from 'rxjs'\nimport { takeUntil } from 'rxjs/operators'\n\nimport { DatatableComponent } from '@theseam/ui-common/datatable'\nimport { TableComponent } from '@theseam/ui-common/table'\nimport { TableCellTypesHelpersService, TABLE_CELL_DATA } from '@theseam/ui-common/table-cell-type'\nimport type { TableCellData, TheSeamTableColumn } from '@theseam/ui-common/table-cell-type'\n\nimport { IconTemplateType } from './../table-cell-type-icon/table-cell-type-icon.component'\nimport { TableCellTypeConfigProgressCircle, TableCellTypeProgressCircleConfigAction } from './table-cell-type-progress-circle-config'\n\n@Component({\n selector: 'seam-table-cell-type-progress-circle',\n templateUrl: './table-cell-type-progress-circle.component.html',\n styleUrls: ['./table-cell-type-progress-circle.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush\n})\nexport class TableCellTypeProgressCircleComponent implements OnInit, OnDestroy {\n\n private readonly _ngUnsubscribe = new Subject()\n\n @Input() value: number | null | undefined\n\n _tableCellData?: TableCellData<'progress-circle', TableCellTypeConfigProgressCircle>\n colData?: TheSeamTableColumn<'progress-circle', TableCellTypeConfigProgressCircle>\n\n fillBackground: boolean = false\n showText: boolean = false\n hiddenOnEmpty: boolean = true\n pending: boolean = false\n tooltip?: string\n tooltipClass?: string\n tooltipPlacement?: string\n tooltipContainer?: string\n _tooltipDisabled: boolean = false\n\n _title?: string\n _srOnly?: string\n\n _link?: string\n _linkClass = '' // TODO: Decide if this makes sense\n _tplType: IconTemplateType = 'default'\n _target?: string\n _queryParams?: { [k: string]: any }\n\n _buttonAction?: TableCellTypeProgressCircleConfigAction\n\n _download?: boolean\n _detectMimeContent?: boolean\n\n private _config: TableCellTypeConfigProgressCircle | undefined | null\n\n @HostBinding('class.datatable-cell-type') _isDatatable = false\n\n constructor(\n private _cdf: ChangeDetectorRef,\n private _tableCellTypeHelpers: TableCellTypesHelpersService,\n @Optional() private _datatable?: DatatableComponent,\n @Optional() private _table?: TableComponent,\n @Optional() @Inject(TABLE_CELL_DATA) _tableData?: TableCellData<'progress-circle', TableCellTypeConfigProgressCircle>\n ) {\n if (_datatable) {\n this._isDatatable = true\n }\n\n const tableData = _tableData\n this._tableCellData = _tableData\n\n this.value = tableData && coerceNumberProperty(tableData.value)\n this.colData = tableData && tableData.colData\n\n if (this.colData && this.colData.cellTypeConfig) {\n this._setCellTypeConfigProps(this.colData.cellTypeConfig)\n }\n\n if (tableData) {\n tableData.changed\n .pipe(takeUntil(this._ngUnsubscribe))\n .subscribe(v => {\n if (v.changes.hasOwnProperty('value')) {\n this.value = coerceNumberProperty(v.changes.value.currentValue)\n if (this._config) {\n this._setCellTypeConfigProps(this._config)\n }\n this._cdf.markForCheck()\n }\n\n if (v.changes.hasOwnProperty('colData')) {\n this.colData = v.changes.colData.currentValue\n if (this.colData && this.colData.cellTypeConfig) {\n this._setCellTypeConfigProps(this.colData.cellTypeConfig)\n }\n this._cdf.markForCheck()\n } else {\n if (v.changes.hasOwnProperty('row')) {\n if (this.colData?.cellTypeConfig) {\n this._setCellTypeConfigProps(this.colData.cellTypeConfig)\n this._cdf.markForCheck()\n }\n }\n }\n })\n }\n }\n\n ngOnInit() { }\n\n ngOnDestroy() {\n this._ngUnsubscribe.next()\n this._ngUnsubscribe.complete()\n }\n\n private _parseConfigValue(val: any) {\n const contextFn = () => this._tableCellTypeHelpers.getValueContext(val, this._tableCellData)\n return this._tableCellTypeHelpers.parseValueProp(val, contextFn)\n }\n\n public setAction(configAction?: TableCellTypeProgressCircleConfigAction) {\n let newTplType: IconTemplateType = 'default'\n let link: string | undefined\n let download: boolean = false\n let detectMimeContent = false\n let target: string | undefined\n let queryParams: { [k: string]: any } | undefined\n\n if (configAction) {\n if (configAction.type === 'link') {\n link = this._parseConfigValue(configAction.link)\n if (link !== undefined && link !== null) {\n newTplType = this._parseConfigValue(configAction.asset)\n ? 'link-encrypted'\n : this._parseConfigValue(configAction.external) ? 'link-external' : 'link'\n download = !!this._parseConfigValue(configAction.download)\n detectMimeContent = !!this._parseConfigValue(configAction.detectMimeContent)\n target = this._parseConfigValue(configAction.target)\n queryParams = this._parseConfigValue(configAction.queryParams)\n }\n } else if (configAction.type === 'modal') {\n newTplType = 'button'\n this._buttonAction = configAction\n }\n }\n\n this._tplType = newTplType\n this._link = link\n this._download = download\n this._detectMimeContent = detectMimeContent\n this._target = target\n this._queryParams = queryParams\n }\n\n private _setCellTypeConfigProps(config: TableCellTypeConfigProgressCircle): void {\n this._config = config\n this.setAction(config.action)\n this.fillBackground = coerceBooleanProperty(this._parseConfigValue(config.fillBackground))\n this.showText = coerceBooleanProperty(this._parseConfigValue(config.showText))\n this.hiddenOnEmpty = coerceBooleanProperty(this._parseConfigValue(config.hiddenOnEmpty))\n this.pending = coerceBooleanProperty(this._parseConfigValue(config.pending))\n this.tooltip = this._parseConfigValue(config.tooltip)\n\n this.tooltip = this._parseConfigValue(config.tooltip)\n if (this.tooltip) {\n this.tooltipClass = this._parseConfigValue(config.tooltipClass)\n this.tooltipPlacement = this._parseConfigValue(config.tooltipPlacement) || 'auto'\n this.tooltipContainer = this._parseConfigValue(config.tooltipContainer)\n this._tooltipDisabled = false\n } else {\n this._tooltipDisabled = true\n }\n\n this._title = this._parseConfigValue(config.titleAttr)\n this._srOnly = this._parseConfigValue(config.srOnly)\n }\n\n _doButtonAction() {\n if (this._buttonAction && this._buttonAction.type === 'modal') {\n const contextFn = () => this._tableCellTypeHelpers.getValueContext(this.value, this._tableCellData)\n this._tableCellTypeHelpers.handleModalAction(this._buttonAction, contextFn)\n .subscribe(\n r => {},\n err => console.error(err),\n () => this._actionRefreshRequest()\n )\n }\n }\n\n private _actionRefreshRequest() {\n if (this._datatable) {\n this._datatable.triggerActionRefreshRequest()\n } else if (this._table) {\n this._table.triggerActionRefreshRequest()\n }\n }\n\n}\n","import {\n ChangeDetectionStrategy,\n ChangeDetectorRef,\n Component,\n HostBinding,\n Inject,\n Input,\n OnDestroy,\n OnInit,\n Optional\n} from '@angular/core'\nimport { Subject } from 'rxjs'\nimport { takeUntil } from 'rxjs/operators'\n\nimport { DatatableComponent } from '@theseam/ui-common/datatable'\nimport { TableComponent } from '@theseam/ui-common/table'\nimport { TableCellTypesHelpersService, TABLE_CELL_DATA } from '@theseam/ui-common/table-cell-type'\nimport type { TableCellData, TheSeamTableColumn } from '@theseam/ui-common/table-cell-type'\n\n\nimport { TableCellTypeConfigString, TableCellTypeStringConfigAction } from './table-cell-type-string-config'\n\nexport type StringTemplateType = 'default' | 'link' | 'link-external' | 'link-encrypted' | 'button'\n\n@Component({\n selector: 'seam-table-cell-type-string',\n templateUrl: './table-cell-type-string.component.html',\n styleUrls: ['./table-cell-type-string.component.scss'],\n host: { },\n changeDetection: ChangeDetectionStrategy.OnPush\n})\nexport class TableCellTypeStringComponent implements OnInit, OnDestroy {\n\n private readonly _ngUnsubscribe = new Subject()\n\n @Input()\n get value() { return this._value }\n set value(val: string | null | undefined) {\n this._value = val\n // TODO: This is temporary to test the feature and will be fixed when the\n // dynamic column data is fixed. The plan is to add a config toggle to\n // always enable and depending on performance it could try to decide on its\n // own based on content size.\n if (this.value && this.value.length > 30) {\n this.canPopover = true\n }\n }\n _value: string | null | undefined\n\n @Input()\n get config() { return this._config }\n set config(value: TableCellTypeConfigString | undefined | null) {\n this._config = value\n if (value) {\n this.setAction(value.action)\n }\n }\n private _config: TableCellTypeConfigString | undefined | null\n\n _tplType: StringTemplateType = 'default'\n _link?: string\n _title?: string\n _queryParams?: { [k: string]: any }\n\n _buttonAction?: TableCellTypeStringConfigAction\n\n _tableCellData?: TableCellData<'string', TableCellTypeConfigString>\n _row?: any\n _rowIndex?: number\n _colData?: TheSeamTableColumn<'string', TableCellTypeConfigString>\n\n _download?: boolean\n _detectMimeContent?: boolean\n\n @Input()\n set title(value: string | undefined) { this.title = value }\n get title(): string | undefined { return this._title }\n\n @HostBinding('attr.title') get _titleAttr() { return this.title || this.value }\n\n canPopover = false\n\n constructor(\n private readonly _cdf: ChangeDetectorRef,\n private readonly _tableCellTypeHelpers: TableCellTypesHelpersService,\n @Optional() private _datatable?: DatatableComponent,\n @Optional() private _table?: TableComponent,\n @Optional() @Inject(TABLE_CELL_DATA) readonly _tableData?: TableCellData<'string', TableCellTypeConfigString>\n ) {\n const _data = _tableData\n this._tableCellData = _tableData\n\n this._row = _data && _data.row\n this._rowIndex = _data && _data.rowIndex\n\n this.value = _data && _data.value\n this._colData = _data && _data.colData\n if (_data && _data.colData && (<any>_data.colData).cellTypeConfig) {\n this.config = (<any>_data.colData).cellTypeConfig\n }\n }\n\n ngOnInit() {\n const _data = this._tableData\n if (_data) {\n _data.changed\n .pipe(takeUntil(this._ngUnsubscribe))\n .subscribe(v => {\n if (v.changes.hasOwnProperty('value')) {\n this.value = v.changes.value.currentValue\n this._cdf.markForCheck()\n }\n\n if (v.changes.hasOwnProperty('colData')) {\n const colData = v.changes.colData.currentValue\n if (colData && colData.cellTypeConfig !== this.config) {\n this.config = colData.cellTypeConfig\n } else {\n this.config = undefined\n }\n this._cdf.markForCheck()\n } else {\n if (v.changes.hasOwnProperty('row')) {\n this.config = this.config\n this._cdf.markForCheck()\n }\n }\n })\n }\n }\n\n ngOnDestroy() {\n this._ngUnsubscribe.next()\n this._ngUnsubscribe.complete()\n }\n\n public setAction(configAction?: TableCellTypeStringConfigAction) {\n let newTplType: StringTemplateType = 'default'\n let link: string | undefined\n let download: boolean = false\n let detectMimeContent = false\n let queryParams: { [k: string]: any } | undefined\n\n if (configAction) {\n if (configAction.type === 'link') {\n link = this._parseConfigValue(configAction.link)\n if (link !== undefined && link !== null) {\n newTplType = this._parseConfigValue(configAction.asset) ? 'link-encrypted' : 'link'\n download = !!this._parseConfigValue(configAction.download)\n detectMimeContent = !!this._parseConfigValue(configAction.detectMimeContent)\n queryParams = this._parseConfigValue(configAction.queryParams)\n }\n } else if (configAction.type === 'modal') {\n newTplType = 'button'\n this._buttonAction = configAction\n }\n }\n\n this._tplType = newTplType\n this._link = link\n this._download = download\n this._detectMimeContent = detectMimeContent\n this._queryParams = queryParams\n }\n\n private _parseConfigValue(val: any) {\n const contextFn = () => this._tableCellTypeHelpers.getValueContext(val, this._tableCellData)\n return this._tableCellTypeHelpers.parseValueProp(val, contextFn)\n }\n\n _doButtonAction() {\n if (this._buttonAction && this._buttonAction.type === 'modal') {\n const contextFn = () => this._tableCellTypeHelpers.getValueContext(this.value, this._tableCellData)\n this._tableCellTypeHelpers.handleModalAction(this._buttonAction, contextFn)\n .subscribe(\n r => {},\n err => console.error(err),\n () => this._actionRefreshRequest()\n )\n }\n }\n\n private _actionRefreshRequest() {\n if (this._datatable) {\n this._datatable.triggerActionRefreshRequest()\n } else if (this._table) {\n this._table.triggerActionRefreshRequest()\n }\n }\n\n}\n","import { ITableCellTypeManifestProvider, TABLE_CELL_TYPE_MANIFEST } from '@theseam/ui-common/table-cell-type'\n\nimport { TableCellTypeDateComponent } from './table-cell-type-date/table-cell-type-date.component'\nimport { TableCellTypeIconComponent } from './table-cell-type-icon/table-cell-type-icon.component'\nimport { TableCellTypePhoneComponent } from './table-cell-type-phone/table-cell-type-phone.component'\n// tslint:disable-next-line: max-line-length\nimport { TableCellTypeProgressCircleIconComponent } from './table-cell-type-progress-circle-icon/table-cell-type-progress-circle-icon.component'\nimport { TableCellTypeProgressCircleComponent } from './table-cell-type-progress-circle/table-cell-type-progress-circle.component'\nimport { TableCellTypeStringComponent } from './table-cell-type-string/table-cell-type-string.component'\n\nexport const TABLE_CELL_TYPE_MANIFEST_STRING: ITableCellTypeManifestProvider = {\n provide: TABLE_CELL_TYPE_MANIFEST,\n useValue: {\n name: 'string',\n component: TableCellTypeStringComponent\n },\n multi: true\n}\n\nexport const TABLE_CELL_TYPE_MANIFEST_INTEGER: ITableCellTypeManifestProvider = {\n provide: TABLE_CELL_TYPE_MANIFEST,\n useValue: {\n name: 'integer',\n component: TableCellTypeStringComponent\n },\n multi: true\n}\n\nexport const TABLE_CELL_TYPE_MANIFEST_DECIMAL: ITableCellTypeManifestProvider = {\n provide: TABLE_CELL_TYPE_MANIFEST,\n useValue: {\n name: 'decimal',\n component: TableCellTypeStringComponent\n },\n multi: true\n}\n\nexport const TABLE_CELL_TYPE_MANIFEST_DATE: ITableCellTypeManifestProvider = {\n provide: TABLE_CELL_TYPE_MANIFEST,\n useValue: {\n name: 'date',\n component: TableCellTypeDateComponent\n },\n multi: true\n}\n\nexport const TABLE_CELL_TYPE_MANIFEST_ICON: ITableCellTypeManifestProvider = {\n provide: TABLE_CELL_TYPE_MANIFEST,\n useValue: {\n name: 'icon',\n component: TableCellTypeIconComponent\n },\n multi: true\n}\n\nexport const TABLE_CELL_TYPE_MANIFEST_IMAGE: ITableCellTypeManifestProvider = {\n provide: TABLE_CELL_TYPE_MANIFEST,\n useValue: {\n name: 'image',\n component: TableCellTypeIconComponent\n },\n multi: true\n}\n\nexport const TABLE_CELL_TYPE_MANIFEST_PROGRESS_CIRCLE: ITableCellTypeManifestProvider = {\n provide: TABLE_CELL_TYPE_MANIFEST,\n useValue: {\n name: 'progress-circle',\n component: TableCellTypeProgressCircleComponent\n },\n multi: true\n}\n\nexport const TABLE_CELL_TYPE_MANIFEST_PROGRESS_CIRCLE_ICON: ITableCellTypeManifestProvider = {\n provide: TABLE_CELL_TYPE_MANIFEST,\n useValue: {\n name: 'progress-circle-icon',\n component: TableCellTypeProgressCircleIconComponent\n },\n multi: true\n}\n\nexport const TABLE_CELL_TYPE_MANIFEST_PHONE: ITableCellTypeManifestProvider = {\n provide: TABLE_CELL_TYPE_MANIFEST,\n useValue: {\n name: 'phone',\n component: TableCellTypePhoneComponent\n },\n multi: true\n}\n","import { PortalModule } from '@angular/cdk/portal'\nimport { CommonModule } from '@angular/common'\nimport { NgModule } from '@angular/core'\nimport { RouterModule } from '@angular/router'\n\nimport { NgbTooltipModule } from '@ng-bootstrap/ng-bootstrap'\n\nimport { TheSeamAssetReaderModule } from '@theseam/ui-common/asset-reader'\nimport { TheSeamIconModule } from '@theseam/ui-common/icon'\nimport { TheSeamPopoverModule } from '@theseam/ui-common/popover'\nimport { TheSeamProgressModule } from '@theseam/ui-common/progress'\nimport { TheSeamSharedModule } from '@theseam/ui-common/shared'\nimport { TheSeamTableCellTypeModule } from '@theseam/ui-common/table-cell-type'\nimport { TheSeamTelInputModule } from '@theseam/ui-common/tel-input'\n\nimport { TableCellTypeDateComponent } from './table-cell-type-date/table-cell-type-date.component'\nimport { TableCellTypeIconComponent } from './table-cell-type-icon/table-cell-type-icon.component'\nimport { TableCellTypePhoneComponent } from './table-cell-type-phone/table-cell-type-phone.component'\n// tslint:disable-next-line: max-line-length\nimport { TableCellTypeProgressCircleIconComponent } from './table-cell-type-progress-circle-icon/table-cell-type-progress-circle-icon.component'\nimport { TableCellTypeProgressCircleComponent } from './table-cell-type-progress-circle/table-cell-type-progress-circle.component'\nimport { TableCellTypeStringComponent } from './table-cell-type-string/table-cell-type-string.component'\n\nimport {\n TABLE_CELL_TYPE_MANIFEST_DATE,\n TABLE_CELL_TYPE_MANIFEST_DECIMAL,\n TABLE_CELL_TYPE_MANIFEST_ICON,\n TABLE_CELL_TYPE_MANIFEST_IMAGE,\n TABLE_CELL_TYPE_MANIFEST_INTEGER,\n TABLE_CELL_TYPE_MANIFEST_PHONE,\n TABLE_CELL_TYPE_MANIFEST_PROGRESS_CIRCLE,\n TABLE_CELL_TYPE_MANIFEST_PROGRESS_CIRCLE_ICON,\n TABLE_CELL_TYPE_MANIFEST_STRING\n} from './table-cell-type-manifests'\n\nconst cellTypeComponents = [\n TableCellTypeStringComponent,\n TableCellTypeDateComponent,\n TableCellTypeIconComponent,\n TableCellTypeProgressCircleComponent,\n TableCellTypeProgressCircleIconComponent,\n TableCellTypePhoneComponent\n]\n\nconst cellTypeProviders = [\n TABLE_CELL_TYPE_MANIFEST_STRING,\n TABLE_CELL_TYPE_MANIFEST_INTEGER,\n TABLE_CELL_TYPE_MANIFEST_DECIMAL,\n TABLE_CELL_TYPE_MANIFEST_DATE,\n TABLE_CELL_TYPE_MANIFEST_ICON,\n TABLE_CELL_TYPE_MANIFEST_IMAGE,\n TABLE_CELL_TYPE_MANIFEST_PROGRESS_CIRCLE,\n TABLE_CELL_TYPE_MANIFEST_PROGRESS_CIRCLE_ICON,\n TABLE_CELL_TYPE_MANIFEST_PHONE\n]\n\n@NgModule({\n declarations: [\n ...cellTypeComponents\n ],\n imports: [\n CommonModule,\n NgbTooltipModule,\n RouterModule,\n TheSeamSharedModule,\n TheSeamIconModule,\n PortalModule,\n TheSeamPopoverModule,\n TheSeamProgressModule,\n TheSeamTelInputModule,\n TheSeamAssetReaderModule,\n TheSeamTableCellTypeModule\n ],\n providers: [\n ...cellTypeProviders\n ],\n exports: [\n ...cellTypeComponents\n ],\n entryComponents: [\n ...cellTypeComponents\n ]\n})\nexport class TheSeamTableCellTypesModule { }\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n\nexport {TableCellTypeConfigProgressCircleIcon as ɵb} from './table-cell-type-progress-circle-icon/table-cell-type-progress-circle-icon-config';\nexport {TableCellTypeConfigProgressCircle as ɵa} from './table-cell-type-progress-circle/table-cell-type-progress-circle-config';"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;MAea,0BAA0B;IAOrC,YACU,IAAuB,EACM,UAA2D;QADxF,SAAI,GAAJ,IAAI,CAAmB;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,oCAAoC;IACpC,wCAAwC;IACxC,2BAA2B;CAC5B,CAAA;AAED,MAAM,iBAAiB,GAAG;IACxB,+BAA+B;IAC/B,gCAAgC;IAChC,gCAAgC;IAChC,6BAA6B;IAC7B,6BAA6B;IAC7B,8BAA8B;IAC9B,wCAAwC;IACxC,6CAA6C;IAC7C,8BAA8B;CAC/B,CAAA;MA6BY,2BAA2B;;;YA3BvC,QAAQ,SAAC;gBACR,YAAY,EAAE;oBACZ,GAAG,kBAAkB;iBACtB;gBACD,OAAO,EAAE;oBACP,YAAY;oBACZ,gBAAgB;oBAChB,YAAY;oBACZ,mBAAmB;oBACnB,iBAAiB;oBACjB,YAAY;oBACZ,oBAAoB;oBACpB,qBAAqB;oBACrB,qBAAqB;oBACrB,wBAAwB;oBACxB,0BAA0B;iBAC3B;gBACD,SAAS,EAAE;oBACT,GAAG,iBAAiB;iBACrB;gBACD,OAAO,EAAE;oBACP,GAAG,kBAAkB;iBACtB;gBACD,eAAe,EAAE;oBACf,GAAG,kBAAkB;iBACtB;aACF;;;AClFD;;;;;;"}
1
+ {"version":3,"file":"theseam-ui-common-table-cell-types.js","sources":["../../../projects/ui-common/table-cell-types/table-cell-type-currency/table-cell-type-currency.component.ts","../../../projects/ui-common/table-cell-types/table-cell-type-date/table-cell-type-date.component.ts","../../../projects/ui-common/table-cell-types/table-cell-type-decimal/table-cell-type-decimal.component.ts","../../../projects/ui-common/table-cell-types/table-cell-type-icon/table-cell-type-icon.component.ts","../../../projects/ui-common/table-cell-types/table-cell-type-integer/table-cell-type-integer.component.ts","../../../projects/ui-common/table-cell-types/table-cell-type-phone/table-cell-type-phone.component.ts","../../../projects/ui-common/table-cell-types/table-cell-type-progress-circle-icon/table-cell-type-progress-circle-icon.component.ts","../../../projects/ui-common/table-cell-types/table-cell-type-progress-circle/table-cell-type-progress-circle.component.ts","../../../projects/ui-common/table-cell-types/table-cell-type-string/table-cell-type-string.component.ts","../../../projects/ui-common/table-cell-types/table-cell-type-manifests.ts","../../../projects/ui-common/table-cell-types/table-cell-types.module.ts","../../../projects/ui-common/table-cell-types/theseam-ui-common-table-cell-types.ts"],"sourcesContent":["import { formatCurrency } from '@angular/common'\nimport { ChangeDetectionStrategy, ChangeDetectorRef, Component, Inject, Input, OnDestroy, OnInit, Optional } from '@angular/core'\nimport { Subject } from 'rxjs'\nimport { takeUntil } from 'rxjs/operators'\n\nimport { TableCellTypesHelpersService, TABLE_CELL_DATA, TheSeamTableColumn } from '@theseam/ui-common/table-cell-type'\nimport type { TableCellData } from '@theseam/ui-common/table-cell-type'\n\nimport { TableCellTypeConfigCurrency } from './table-cell-type-currency-config'\n\n@Component({\n selector: 'seam-table-cell-type-currency',\n templateUrl: './table-cell-type-currency.component.html',\n styleUrls: ['./table-cell-type-currency.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush\n})\nexport class TableCellTypeCurrencyComponent implements OnInit, OnDestroy {\n\n private readonly _ngUnsubscribe = new Subject()\n\n @Input() value: string | null | undefined\n\n row?: any\n rowIndex?: number\n colData?: TheSeamTableColumn<'currency', TableCellTypeConfigCurrency>\n textAlign?: 'left' | 'center' | 'right'\n // TODO: implement\n // titleAttr?: string\n\n constructor(\n private _cdf: ChangeDetectorRef,\n private _tableCellTypeHelpers: TableCellTypesHelpersService,\n @Optional() @Inject(TABLE_CELL_DATA) _tableData?: TableCellData<'currency', TableCellTypeConfigCurrency>\n ) {\n const tableData = _tableData\n this.value = tableData && this._formatCurrency(tableData.value, tableData)\n this.row = tableData && tableData.row\n this.rowIndex = tableData && tableData.rowIndex\n this.colData = tableData && tableData.colData\n this.textAlign = this._parseConfigValue(tableData?.colData?.cellTypeConfig?.textAlign, tableData) || 'right'\n // this.titleAttr = this._parseConfigValue(tableData?.colData?.cellTypeConfig?.titleAttr, tableData) || this.value\n\n if (tableData) {\n tableData.changed\n .pipe(takeUntil(this._ngUnsubscribe))\n .subscribe(v => {\n if (v.changes.hasOwnProperty('value')) {\n this.value = this._formatCurrency(v.changes.value.currentValue, tableData)\n this._cdf.markForCheck()\n }\n\n if (v.changes.hasOwnProperty('colData')) {\n this.colData = v.changes.colData.currentValue\n this._cdf.markForCheck()\n }\n })\n }\n }\n\n ngOnInit() {}\n\n ngOnDestroy() {\n this._ngUnsubscribe.next()\n this._ngUnsubscribe.complete()\n }\n\n private _formatCurrency(currentValue?: any, tableData?: TableCellData<'currency', TableCellTypeConfigCurrency>): string {\n const config = tableData?.colData?.cellTypeConfig\n const locale = this._parseConfigValue(config?.locale, tableData) || 'en-US'\n const currency = this._parseConfigValue(config?.currency, tableData) || '$'\n const currencyCode = this._parseConfigValue(config?.currencyCode, tableData) || 'USD'\n const minIntegerDigits = this._parseConfigValue(config?.minIntegerDigits, tableData) || 1\n const minFractionDigits = this._parseConfigValue(config?.minFractionDigits, tableData) || 0\n const maxFractionDigits = this._parseConfigValue(config?.maxFractionDigits, tableData) || 2\n const format = `${ minIntegerDigits }.${ minFractionDigits }-${ maxFractionDigits }`\n\n return formatCurrency(currentValue, locale, currency, currencyCode, format )\n }\n\n private _parseConfigValue(val?: any, tableData?: TableCellData<'currency', TableCellTypeConfigCurrency>) {\n const contextFn = () => this._tableCellTypeHelpers.getValueContext(val, tableData)\n return this._tableCellTypeHelpers.parseValueProp(val, contextFn)\n }\n\n}\n","import { ChangeDetectionStrategy, ChangeDetectorRef, Component, Inject, Input, OnDestroy, OnInit, Optional } from '@angular/core'\nimport { Subject } from 'rxjs'\nimport { takeUntil } from 'rxjs/operators'\n\nimport { TABLE_CELL_DATA } from '@theseam/ui-common/table-cell-type'\nimport type { TableCellData } from '@theseam/ui-common/table-cell-type'\n\nimport { TableCellTypeConfigDate } from './table-cell-type-date-config'\n\n@Component({\n selector: 'seam-table-cell-type-date',\n templateUrl: './table-cell-type-date.component.html',\n styleUrls: ['./table-cell-type-date.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush\n})\nexport class TableCellTypeDateComponent implements OnInit, OnDestroy {\n\n private readonly _ngUnsubscribe = new Subject()\n\n @Input() value: string | undefined | null\n @Input() format: string | undefined | null\n\n constructor(\n private _cdf: ChangeDetectorRef,\n @Optional() @Inject(TABLE_CELL_DATA) _tableData?: TableCellData<'date', TableCellTypeConfigDate>\n ) {\n const _data = _tableData\n\n this.value = _data && _data.value\n this.format = _data && _data.colData && _data.colData.cellTypeConfig && _data.colData.cellTypeConfig.format\n\n if (_data) {\n _data.changed\n .pipe(takeUntil(this._ngUnsubscribe))\n .subscribe(v => {\n if (v.changes.hasOwnProperty('value')) {\n this.value = v.changes.value.currentValue\n this._cdf.markForCheck()\n }\n\n if (v.changes.hasOwnProperty('colData')) {\n const colData = v.changes.colData.currentValue\n if (colData && colData.format !== this.format) {\n this.format = colData.format\n } else {\n this.format = undefined\n }\n this._cdf.markForCheck()\n }\n })\n }\n }\n\n ngOnInit() { }\n\n ngOnDestroy() {\n this._ngUnsubscribe.next()\n this._ngUnsubscribe.complete()\n }\n\n}\n","import { formatNumber } from '@angular/common'\nimport { ChangeDetectionStrategy, ChangeDetectorRef, Component, Inject, Input, OnDestroy, OnInit, Optional } from '@angular/core'\nimport { Subject } from 'rxjs'\nimport { takeUntil } from 'rxjs/operators'\n\nimport { TableCellTypesHelpersService, TABLE_CELL_DATA, TheSeamTableColumn } from '@theseam/ui-common/table-cell-type'\nimport type { TableCellData } from '@theseam/ui-common/table-cell-type'\nimport { notNullOrUndefined } from '@theseam/ui-common/utils'\n\nimport { coerceBooleanProperty } from '@angular/cdk/coercion'\nimport { TableCellTypeConfigDecimal } from './table-cell-type-decimal-config'\n\n@Component({\n selector: 'seam-table-cell-type-decimal',\n templateUrl: './table-cell-type-decimal.component.html',\n styleUrls: ['./table-cell-type-decimal.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush\n})\nexport class TableCellTypeDecimalComponent implements OnInit, OnDestroy {\n\n private readonly _ngUnsubscribe = new Subject()\n\n @Input() value: string | undefined | null\n\n row?: any\n rowIndex?: number\n colData?: TheSeamTableColumn<'decimal', TableCellTypeConfigDecimal>\n textAlign?: 'left' | 'center' | 'right'\n\n constructor(\n private _cdf: ChangeDetectorRef,\n private _tableCellTypeHelpers: TableCellTypesHelpersService,\n @Optional() @Inject(TABLE_CELL_DATA) _tableData?: TableCellData<'decimal', TableCellTypeConfigDecimal>\n ) {\n const tableData = _tableData\n this.value = tableData && this._formatDecimal(tableData.value, tableData)\n this.row = tableData && tableData.row\n this.rowIndex = tableData && tableData.rowIndex\n this.colData = tableData && tableData.colData\n this.textAlign = this._parseConfigValue(tableData?.colData?.cellTypeConfig?.textAlign, tableData) || 'right'\n\n if (tableData) {\n tableData.changed\n .pipe(takeUntil(this._ngUnsubscribe))\n .subscribe(v => {\n if (v.changes.hasOwnProperty('value')) {\n this.value = this._formatDecimal(v.changes.value.currentValue, tableData)\n this._cdf.markForCheck()\n }\n\n if (v.changes.hasOwnProperty('colData')) {\n this.colData = v.changes.colData.currentValue\n this._cdf.markForCheck()\n }\n })\n }\n }\n\n ngOnInit() {}\n\n ngOnDestroy() {\n this._ngUnsubscribe.next()\n this._ngUnsubscribe.complete()\n }\n\n private _formatDecimal(currentValue?: any, tableData?: TableCellData<'decimal', TableCellTypeConfigDecimal> | undefined): string {\n const config = tableData?.colData?.cellTypeConfig\n const formatDecimal = notNullOrUndefined(config?.formatNumber) ?\n this._parseConfigValue(coerceBooleanProperty(config?.formatNumber), tableData) : true\n const locale = this._parseConfigValue(config?.locale, tableData) || 'en-US'\n const minIntegerDigits = this._parseConfigValue(config?.minIntegerDigits, tableData) || 1\n const minFractionDigits = this._parseConfigValue(config?.minFractionDigits, tableData) || 0\n const maxFractionDigits = this._parseConfigValue(config?.maxFractionDigits, tableData) || 3\n const format = `${ minIntegerDigits }.${ minFractionDigits }-${ maxFractionDigits }`\n\n return formatDecimal ? formatNumber(currentValue, locale, format) : currentValue\n }\n\n private _parseConfigValue(val?: any, tableData?: TableCellData<'decimal', TableCellTypeConfigDecimal>) {\n const contextFn = () => this._tableCellTypeHelpers.getValueContext(val, tableData)\n return this._tableCellTypeHelpers.parseValueProp(val, contextFn)\n }\n\n}\n","import {\n ChangeDetectionStrategy,\n ChangeDetectorRef,\n Component,\n HostBinding,\n Inject,\n Input,\n OnDestroy,\n OnInit,\n Optional\n} from '@angular/core'\nimport { Subject } from 'rxjs'\nimport { takeUntil } from 'rxjs/operators'\n\nimport { DatatableComponent } from '@theseam/ui-common/datatable'\nimport { getKnownIcon, SeamIcon, TheSeamIconType } from '@theseam/ui-common/icon'\nimport { TableComponent } from '@theseam/ui-common/table'\nimport { TableCellTypesHelpersService, TABLE_CELL_DATA } from '@theseam/ui-common/table-cell-type'\nimport type { TableCellData, TheSeamTableColumn } from '@theseam/ui-common/table-cell-type'\n\nimport { TableCellTypeConfigIcon, TableCellTypeIconConfigAction } from './table-cell-type-icon-config'\n\nexport type IconTemplateType = 'default' | 'link' | 'link-external' | 'link-encrypted' | 'button'\n\n@Component({\n selector: 'seam-table-cell-type-icon',\n templateUrl: './table-cell-type-icon.component.html',\n styleUrls: ['./table-cell-type-icon.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush\n})\nexport class TableCellTypeIconComponent<R = any, V = any> implements OnInit, OnDestroy {\n\n private readonly _ngUnsubscribe = new Subject()\n\n @Input()\n get value() { return this._value }\n set value(value: string | undefined | null) {\n this._value = value\n this._icon = value ? getKnownIcon(value) || value : value\n }\n private _value: string | undefined | null\n\n @Input()\n get config() { return this._config }\n set config(value: TableCellTypeConfigIcon | undefined | null) {\n this._config = value\n if (value) {\n this.setAction(value.action)\n this._linkClass = this._parseConfigValue(value.linkClass)\n this._iconClass = this._parseConfigValue(value.iconClass)\n this._iconType = value.iconType\n this._title = this._parseConfigValue(value.titleAttr)\n this._srOnly = this._parseConfigValue(value.srOnly)\n this._tooltip = this._parseConfigValue(value.tooltip)\n if (this._tooltip) {\n this._tooltipClass = this._parseConfigValue(value.tooltipClass)\n this._tooltipPlacement = this._parseConfigValue(value.tooltipPlacement) || 'auto'\n this._tooltipContainer = this._parseConfigValue(value.tooltipContainer)\n this._tooltipDisabled = false\n } else {\n this._tooltipDisabled = true\n }\n }\n }\n private _config: TableCellTypeConfigIcon | undefined | null\n\n _icon: SeamIcon | undefined | null\n _link?: string\n _queryParams?: { [k: string]: any }\n _tplType: IconTemplateType = 'default'\n _title?: string\n _srOnly?: string\n _linkClass?: string\n _iconClass?: string\n _iconType?: TheSeamIconType\n _target?: string\n _tooltip?: string\n _tooltipClass?: string\n _tooltipPlacement?: string\n _tooltipContainer?: string\n _tooltipDisabled: boolean = true\n\n _buttonAction?: TableCellTypeIconConfigAction\n\n _tableCellData?: TableCellData<'icon', TableCellTypeConfigIcon>\n _row?: any\n _rowIndex?: number\n _colData?: TheSeamTableColumn<'icon', TableCellTypeConfigIcon>\n\n _download?: boolean\n _detectMimeContent?: boolean\n\n @HostBinding('class.datatable-cell-type') _isDatatable = false\n\n constructor(\n private _cdf: ChangeDetectorRef,\n private _tableCellTypeHelpers: TableCellTypesHelpersService,\n @Optional() private _datatable?: DatatableComponent,\n @Optional() private _table?: TableComponent,\n @Optional() @Inject(TABLE_CELL_DATA) _tableData?: TableCellData<'icon', TableCellTypeConfigIcon>\n ) {\n if (_datatable) {\n this._isDatatable = true\n // console.log('isDataTable')\n }\n // if (_table) {\n // console.log('isTable')\n // }\n\n const _data = _tableData\n this._tableCellData = _tableData\n\n this._row = _data && _data.row\n this._rowIndex = _data && _data.rowIndex\n\n this.value = _data && _data.value\n this._colData = _data && _data.colData\n if (_data && _data.colData && (<any>_data.colData).cellTypeConfig) {\n this.config = (<any>_data.colData).cellTypeConfig\n }\n\n if (_data) {\n _data.changed\n .pipe(takeUntil(this._ngUnsubscribe))\n .subscribe(v => {\n if (v.changes.hasOwnProperty('value')) {\n this.value = v.changes.value.currentValue\n this.config = this._config\n this._cdf.markForCheck()\n }\n\n if (v.changes.hasOwnProperty('colData')) {\n const colData = v.changes.colData.currentValue\n if (colData && colData.cellTypeConfig !== this.config) {\n this.config = colData.cellTypeConfig\n } else {\n this.config = undefined\n }\n this._cdf.markForCheck()\n } else {\n if (v.changes.hasOwnProperty('row')) {\n this.config = this.config\n this._cdf.markForCheck()\n }\n }\n })\n }\n }\n\n ngOnInit() { }\n\n ngOnDestroy() {\n this._ngUnsubscribe.next()\n this._ngUnsubscribe.complete()\n }\n\n public setAction(configAction?: TableCellTypeIconConfigAction) {\n let newTplType: IconTemplateType = 'default'\n let link: string | undefined\n let download: boolean = false\n let detectMimeContent = false\n let target: string | undefined\n let queryParams: { [l: string]: any } | undefined\n\n if (configAction) {\n if (configAction.type === 'link') {\n link = this._parseConfigValue(configAction.link)\n if (link !== undefined && link !== null) {\n newTplType = this._parseConfigValue(configAction.asset)\n ? 'link-encrypted'\n : this._parseConfigValue(configAction.external) ? 'link-external' : 'link'\n download = !!this._parseConfigValue(configAction.download)\n detectMimeContent = !!this._parseConfigValue(configAction.detectMimeContent)\n target = this._parseConfigValue(configAction.target)\n queryParams = this._parseConfigValue(configAction.queryParams)\n }\n } else if (configAction.type === 'modal') {\n newTplType = 'button'\n this._buttonAction = configAction\n }\n }\n\n this._tplType = newTplType\n this._link = link\n this._download = download\n this._detectMimeContent = detectMimeContent\n this._target = target\n this._queryParams = queryParams\n }\n\n private _parseConfigValue(val: any) {\n const contextFn = () => this._tableCellTypeHelpers.getValueContext(val, this._tableCellData)\n return this._tableCellTypeHelpers.parseValueProp(val, contextFn)\n }\n\n _doButtonAction() {\n if (this._buttonAction && this._buttonAction.type === 'modal') {\n const contextFn = () => this._tableCellTypeHelpers.getValueContext(this.value, this._tableCellData)\n this._tableCellTypeHelpers.handleModalAction(this._buttonAction, contextFn)\n .subscribe(\n r => {},\n err => console.error(err),\n () => this._actionRefreshRequest()\n )\n }\n }\n\n private _actionRefreshRequest() {\n if (this._datatable) {\n this._datatable.triggerActionRefreshRequest()\n } else if (this._table) {\n this._table.triggerActionRefreshRequest()\n }\n }\n\n}\n","import { formatNumber } from '@angular/common'\nimport { ChangeDetectionStrategy, ChangeDetectorRef, Component, Inject, Input, OnDestroy, OnInit, Optional } from '@angular/core'\nimport { Subject } from 'rxjs'\nimport { takeUntil } from 'rxjs/operators'\n\nimport { TableCellTypesHelpersService, TABLE_CELL_DATA, TheSeamTableColumn } from '@theseam/ui-common/table-cell-type'\nimport type { TableCellData } from '@theseam/ui-common/table-cell-type'\nimport { notNullOrUndefined } from '@theseam/ui-common/utils'\n\nimport { coerceBooleanProperty } from '@angular/cdk/coercion'\nimport { TableCellTypeConfigInteger } from './table-cell-type-integer-config'\n\n@Component({\n selector: 'seam-table-cell-type-integer',\n templateUrl: './table-cell-type-integer.component.html',\n styleUrls: ['./table-cell-type-integer.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush\n})\nexport class TableCellTypeIntegerComponent implements OnInit, OnDestroy {\n\n private readonly _ngUnsubscribe = new Subject()\n\n @Input() value: string | null | undefined\n\n row?: any\n rowIndex?: number\n colData?: TheSeamTableColumn<'integer', TableCellTypeConfigInteger>\n textAlign?: 'left' | 'center' | 'right'\n\n constructor(\n private _cdf: ChangeDetectorRef,\n private _tableCellTypeHelpers: TableCellTypesHelpersService,\n @Optional() @Inject(TABLE_CELL_DATA) _tableData?: TableCellData<'integer', TableCellTypeConfigInteger>\n ) {\n const tableData = _tableData\n this.value = tableData && this._formatInteger(tableData.value, tableData)\n this.row = tableData && tableData.row\n this.rowIndex = tableData && tableData.rowIndex\n this.colData = tableData && tableData.colData\n this.textAlign = this._parseConfigValue(tableData?.colData?.cellTypeConfig?.textAlign, tableData) || 'right'\n\n if (tableData) {\n tableData.changed\n .pipe(takeUntil(this._ngUnsubscribe))\n .subscribe(v => {\n if (v.changes.hasOwnProperty('value')) {\n this.value = this._formatInteger(v.changes.value.currentValue, tableData)\n this._cdf.markForCheck()\n }\n\n if (v.changes.hasOwnProperty('colData')) {\n this.colData = v.changes.colData.currentValue\n this._cdf.markForCheck()\n }\n })\n }\n }\n\n ngOnInit() {}\n\n ngOnDestroy() {\n this._ngUnsubscribe.next()\n this._ngUnsubscribe.complete()\n }\n\n private _formatInteger(currentValue?: any, tableData?: TableCellData<'integer', TableCellTypeConfigInteger> | undefined): string {\n const config = tableData?.colData?.cellTypeConfig\n const formatInteger = notNullOrUndefined(config?.formatNumber) ?\n this._parseConfigValue(coerceBooleanProperty(config?.formatNumber), tableData) : true\n const locale = this._parseConfigValue(config?.locale, tableData) || 'en-US'\n const minIntegerDigits = this._parseConfigValue(config?.minIntegerDigits, tableData) || 1\n const format = `${ minIntegerDigits }.0-0`\n\n return formatInteger ? formatNumber(currentValue, locale, format ) : currentValue\n }\n\n private _parseConfigValue(val?: any, tableData?: TableCellData<'integer', TableCellTypeConfigInteger>) {\n const contextFn = () => this._tableCellTypeHelpers.getValueContext(val, tableData)\n return this._tableCellTypeHelpers.parseValueProp(val, contextFn)\n }\n\n}\n","import { ChangeDetectionStrategy, ChangeDetectorRef, Component, Inject, Input, OnDestroy, OnInit, Optional } from '@angular/core'\nimport { Subject } from 'rxjs'\nimport { takeUntil } from 'rxjs/operators'\n\nimport { TABLE_CELL_DATA } from '@theseam/ui-common/table-cell-type'\nimport type { TableCellData } from '@theseam/ui-common/table-cell-type'\nimport { coercePhoneNumberFormat, THESEAM_DEFAULT_PHONE_NUMBER_FORMAT } from '@theseam/ui-common/tel-input'\nimport type { intlTelInputUtils } from '@theseam/ui-common/tel-input'\nimport { hasProperty } from '@theseam/ui-common/utils'\n\nimport { TableCellTypeConfigPhone } from './table-cell-type-phone-config'\n\n@Component({\n selector: 'seam-table-cell-type-phone',\n templateUrl: './table-cell-type-phone.component.html',\n styleUrls: ['./table-cell-type-phone.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush\n})\nexport class TableCellTypePhoneComponent implements OnInit, OnDestroy {\n\n /** @ignore */\n private readonly _ngUnsubscribe = new Subject()\n\n /** @ignore */\n _format: intlTelInputUtils.numberFormat = THESEAM_DEFAULT_PHONE_NUMBER_FORMAT\n\n @Input() value?: string | null\n @Input()\n set format(value: intlTelInputUtils.numberFormat) { this._format = coercePhoneNumberFormat(value) }\n get format() { return this._format }\n\n constructor(\n private _cdf: ChangeDetectorRef,\n @Optional() @Inject(TABLE_CELL_DATA) _tableData?: TableCellData<'phone', TableCellTypeConfigPhone>\n ) {\n const _data = _tableData\n\n this.value = _data && _data.value\n if (_data && _data.colData && _data.colData.cellTypeConfig && hasProperty(_data.colData.cellTypeConfig, 'format')) {\n this.format = _data.colData.cellTypeConfig.format as intlTelInputUtils.numberFormat\n }\n\n if (_data) {\n _data.changed\n .pipe(takeUntil(this._ngUnsubscribe))\n .subscribe(v => {\n if (v.changes.hasOwnProperty('value')) {\n this.value = v.changes.value.currentValue\n this._cdf.markForCheck()\n }\n\n if (v.changes.hasOwnProperty('colData')) {\n const colData = v.changes.colData.currentValue\n if (colData && hasProperty(colData, 'cellTypeConfig') &&\n hasProperty(colData.cellTypeConfig, 'format') &&\n colData.cellTypeConfig.format !== this.format\n ) {\n this.format = colData.cellTypeConfig.format\n } else {\n this.format = THESEAM_DEFAULT_PHONE_NUMBER_FORMAT\n }\n this._cdf.markForCheck()\n }\n })\n }\n }\n\n ngOnInit() { }\n\n ngOnDestroy() {\n this._ngUnsubscribe.next()\n this._ngUnsubscribe.complete()\n }\n\n}\n","import { ChangeDetectionStrategy, ChangeDetectorRef, Component, Inject, Input, OnDestroy, OnInit, Optional } from '@angular/core'\nimport { Subject } from 'rxjs'\nimport { takeUntil } from 'rxjs/operators'\n\nimport { SeamIcon } from '@theseam/ui-common/icon'\nimport { TableCellTypesHelpersService, TABLE_CELL_DATA } from '@theseam/ui-common/table-cell-type'\nimport type { TableCellData, TheSeamTableColumn } from '@theseam/ui-common/table-cell-type'\n\nimport { TableCellTypeConfigProgressCircleIcon } from './table-cell-type-progress-circle-icon-config'\n\n@Component({\n selector: 'seam-table-cell-type-progress-circle-icon',\n templateUrl: './table-cell-type-progress-circle-icon.component.html',\n styleUrls: ['./table-cell-type-progress-circle-icon.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush\n})\nexport class TableCellTypeProgressCircleIconComponent implements OnInit, OnDestroy {\n\n private readonly _ngUnsubscribe = new Subject()\n\n @Input() value: number | null | undefined\n\n row?: any\n rowIndex?: number\n colData?: TheSeamTableColumn<'progress-circle-icon', TableCellTypeConfigProgressCircleIcon>\n\n displayIcon: boolean = false\n icon?: SeamIcon\n\n constructor(\n private _cdf: ChangeDetectorRef,\n private _tableCellTypeHelpers: TableCellTypesHelpersService,\n @Optional() @Inject(TABLE_CELL_DATA) _tableData?: TableCellData<'progress-circle-icon', TableCellTypeConfigProgressCircleIcon>\n ) {\n const tableData = _tableData\n this.value = tableData && tableData.value\n this.row = tableData && tableData.row\n this.rowIndex = tableData && tableData.rowIndex\n this.colData = tableData && tableData.colData\n\n this._setIcon(tableData)\n\n if (tableData) {\n tableData.changed\n .pipe(takeUntil(this._ngUnsubscribe))\n .subscribe(v => {\n if (v.changes.hasOwnProperty('value')) {\n this.value = v.changes.value.currentValue\n this._setIcon(tableData)\n this._cdf.markForCheck()\n }\n\n if (v.changes.hasOwnProperty('colData')) {\n this.colData = v.changes.colData.currentValue\n this._setIcon(tableData)\n this._cdf.markForCheck()\n } else {\n if (v.changes.hasOwnProperty('row')) {\n this._setIcon(tableData)\n this._cdf.markForCheck()\n }\n }\n })\n }\n }\n\n private _setIcon(tableData?: TableCellData<'progress-circle-icon', TableCellTypeConfigProgressCircleIcon>) {\n if (tableData &&\n tableData.colData &&\n tableData.colData.cellTypeConfig &&\n tableData.colData.cellTypeConfig.displayIcon &&\n tableData.colData.cellTypeConfig.icon &&\n this._parseConfigValue(tableData.colData.cellTypeConfig.displayIcon, tableData) &&\n this._parseConfigValue(tableData.colData.cellTypeConfig.icon, tableData)) {\n this.icon = this._parseConfigValue(tableData.colData.cellTypeConfig.icon, tableData)\n this.displayIcon = this._parseConfigValue(tableData.colData.cellTypeConfig.displayIcon, tableData)\n }\n }\n\n private _parseConfigValue(val: any, tableData?: TableCellData<'progress-circle-icon', TableCellTypeConfigProgressCircleIcon>) {\n const contextFn = () => this._tableCellTypeHelpers.getValueContext(val, tableData)\n return this._tableCellTypeHelpers.parseValueProp(val, contextFn)\n }\n\n ngOnInit() { }\n\n ngOnDestroy() {\n this._ngUnsubscribe.next()\n this._ngUnsubscribe.complete()\n }\n\n}\n","import { coerceBooleanProperty, coerceNumberProperty } from '@angular/cdk/coercion'\nimport {\n ChangeDetectionStrategy,\n ChangeDetectorRef,\n Component,\n HostBinding,\n Inject,\n Input,\n OnDestroy,\n OnInit,\n Optional\n} from '@angular/core'\nimport { Subject } from 'rxjs'\nimport { takeUntil } from 'rxjs/operators'\n\nimport { DatatableComponent } from '@theseam/ui-common/datatable'\nimport { TableComponent } from '@theseam/ui-common/table'\nimport { TableCellTypesHelpersService, TABLE_CELL_DATA } from '@theseam/ui-common/table-cell-type'\nimport type { TableCellData, TheSeamTableColumn } from '@theseam/ui-common/table-cell-type'\n\nimport { IconTemplateType } from './../table-cell-type-icon/table-cell-type-icon.component'\nimport { TableCellTypeConfigProgressCircle, TableCellTypeProgressCircleConfigAction } from './table-cell-type-progress-circle-config'\n\n@Component({\n selector: 'seam-table-cell-type-progress-circle',\n templateUrl: './table-cell-type-progress-circle.component.html',\n styleUrls: ['./table-cell-type-progress-circle.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush\n})\nexport class TableCellTypeProgressCircleComponent implements OnInit, OnDestroy {\n\n private readonly _ngUnsubscribe = new Subject()\n\n @Input() value: number | null | undefined\n\n _tableCellData?: TableCellData<'progress-circle', TableCellTypeConfigProgressCircle>\n colData?: TheSeamTableColumn<'progress-circle', TableCellTypeConfigProgressCircle>\n\n fillBackground: boolean = false\n showText: boolean = false\n hiddenOnEmpty: boolean = true\n pending: boolean = false\n tooltip?: string\n tooltipClass?: string\n tooltipPlacement?: string\n tooltipContainer?: string\n _tooltipDisabled: boolean = false\n\n _title?: string\n _srOnly?: string\n\n _link?: string\n _linkClass = '' // TODO: Decide if this makes sense\n _tplType: IconTemplateType = 'default'\n _target?: string\n _queryParams?: { [k: string]: any }\n\n _buttonAction?: TableCellTypeProgressCircleConfigAction\n\n _download?: boolean\n _detectMimeContent?: boolean\n\n private _config: TableCellTypeConfigProgressCircle | undefined | null\n\n @HostBinding('class.datatable-cell-type') _isDatatable = false\n\n constructor(\n private _cdf: ChangeDetectorRef,\n private _tableCellTypeHelpers: TableCellTypesHelpersService,\n @Optional() private _datatable?: DatatableComponent,\n @Optional() private _table?: TableComponent,\n @Optional() @Inject(TABLE_CELL_DATA) _tableData?: TableCellData<'progress-circle', TableCellTypeConfigProgressCircle>\n ) {\n if (_datatable) {\n this._isDatatable = true\n }\n\n const tableData = _tableData\n this._tableCellData = _tableData\n\n this.value = tableData && coerceNumberProperty(tableData.value)\n this.colData = tableData && tableData.colData\n\n if (this.colData && this.colData.cellTypeConfig) {\n this._setCellTypeConfigProps(this.colData.cellTypeConfig)\n }\n\n if (tableData) {\n tableData.changed\n .pipe(takeUntil(this._ngUnsubscribe))\n .subscribe(v => {\n if (v.changes.hasOwnProperty('value')) {\n this.value = coerceNumberProperty(v.changes.value.currentValue)\n if (this._config) {\n this._setCellTypeConfigProps(this._config)\n }\n this._cdf.markForCheck()\n }\n\n if (v.changes.hasOwnProperty('colData')) {\n this.colData = v.changes.colData.currentValue\n if (this.colData && this.colData.cellTypeConfig) {\n this._setCellTypeConfigProps(this.colData.cellTypeConfig)\n }\n this._cdf.markForCheck()\n } else {\n if (v.changes.hasOwnProperty('row')) {\n if (this.colData?.cellTypeConfig) {\n this._setCellTypeConfigProps(this.colData.cellTypeConfig)\n this._cdf.markForCheck()\n }\n }\n }\n })\n }\n }\n\n ngOnInit() { }\n\n ngOnDestroy() {\n this._ngUnsubscribe.next()\n this._ngUnsubscribe.complete()\n }\n\n private _parseConfigValue(val: any) {\n const contextFn = () => this._tableCellTypeHelpers.getValueContext(val, this._tableCellData)\n return this._tableCellTypeHelpers.parseValueProp(val, contextFn)\n }\n\n public setAction(configAction?: TableCellTypeProgressCircleConfigAction) {\n let newTplType: IconTemplateType = 'default'\n let link: string | undefined\n let download: boolean = false\n let detectMimeContent = false\n let target: string | undefined\n let queryParams: { [k: string]: any } | undefined\n\n if (configAction) {\n if (configAction.type === 'link') {\n link = this._parseConfigValue(configAction.link)\n if (link !== undefined && link !== null) {\n newTplType = this._parseConfigValue(configAction.asset)\n ? 'link-encrypted'\n : this._parseConfigValue(configAction.external) ? 'link-external' : 'link'\n download = !!this._parseConfigValue(configAction.download)\n detectMimeContent = !!this._parseConfigValue(configAction.detectMimeContent)\n target = this._parseConfigValue(configAction.target)\n queryParams = this._parseConfigValue(configAction.queryParams)\n }\n } else if (configAction.type === 'modal') {\n newTplType = 'button'\n this._buttonAction = configAction\n }\n }\n\n this._tplType = newTplType\n this._link = link\n this._download = download\n this._detectMimeContent = detectMimeContent\n this._target = target\n this._queryParams = queryParams\n }\n\n private _setCellTypeConfigProps(config: TableCellTypeConfigProgressCircle): void {\n this._config = config\n this.setAction(config.action)\n this.fillBackground = coerceBooleanProperty(this._parseConfigValue(config.fillBackground))\n this.showText = coerceBooleanProperty(this._parseConfigValue(config.showText))\n this.hiddenOnEmpty = coerceBooleanProperty(this._parseConfigValue(config.hiddenOnEmpty))\n this.pending = coerceBooleanProperty(this._parseConfigValue(config.pending))\n this.tooltip = this._parseConfigValue(config.tooltip)\n\n this.tooltip = this._parseConfigValue(config.tooltip)\n if (this.tooltip) {\n this.tooltipClass = this._parseConfigValue(config.tooltipClass)\n this.tooltipPlacement = this._parseConfigValue(config.tooltipPlacement) || 'auto'\n this.tooltipContainer = this._parseConfigValue(config.tooltipContainer)\n this._tooltipDisabled = false\n } else {\n this._tooltipDisabled = true\n }\n\n this._title = this._parseConfigValue(config.titleAttr)\n this._srOnly = this._parseConfigValue(config.srOnly)\n }\n\n _doButtonAction() {\n if (this._buttonAction && this._buttonAction.type === 'modal') {\n const contextFn = () => this._tableCellTypeHelpers.getValueContext(this.value, this._tableCellData)\n this._tableCellTypeHelpers.handleModalAction(this._buttonAction, contextFn)\n .subscribe(\n r => {},\n err => console.error(err),\n () => this._actionRefreshRequest()\n )\n }\n }\n\n private _actionRefreshRequest() {\n if (this._datatable) {\n this._datatable.triggerActionRefreshRequest()\n } else if (this._table) {\n this._table.triggerActionRefreshRequest()\n }\n }\n\n}\n","import {\n ChangeDetectionStrategy,\n ChangeDetectorRef,\n Component,\n HostBinding,\n Inject,\n Input,\n OnDestroy,\n OnInit,\n Optional\n} from '@angular/core'\nimport { Subject } from 'rxjs'\nimport { takeUntil } from 'rxjs/operators'\n\nimport { DatatableComponent } from '@theseam/ui-common/datatable'\nimport { TableComponent } from '@theseam/ui-common/table'\nimport { TableCellTypesHelpersService, TABLE_CELL_DATA } from '@theseam/ui-common/table-cell-type'\nimport type { TableCellData, TheSeamTableColumn } from '@theseam/ui-common/table-cell-type'\n\n\nimport { TableCellTypeConfigString, TableCellTypeStringConfigAction } from './table-cell-type-string-config'\n\nexport type StringTemplateType = 'default' | 'link' | 'link-external' | 'link-encrypted' | 'button'\n\n@Component({\n selector: 'seam-table-cell-type-string',\n templateUrl: './table-cell-type-string.component.html',\n styleUrls: ['./table-cell-type-string.component.scss'],\n host: { },\n changeDetection: ChangeDetectionStrategy.OnPush\n})\nexport class TableCellTypeStringComponent implements OnInit, OnDestroy {\n\n private readonly _ngUnsubscribe = new Subject()\n\n @Input()\n get value() { return this._value }\n set value(val: string | null | undefined) {\n this._value = val\n // TODO: This is temporary to test the feature and will be fixed when the\n // dynamic column data is fixed. The plan is to add a config toggle to\n // always enable and depending on performance it could try to decide on its\n // own based on content size.\n if (this.value && this.value.length > 30) {\n this.canPopover = true\n }\n }\n _value: string | null | undefined\n\n @Input()\n get config() { return this._config }\n set config(value: TableCellTypeConfigString | undefined | null) {\n this._config = value\n if (value) {\n this.setAction(value.action)\n }\n }\n private _config: TableCellTypeConfigString | undefined | null\n\n _tplType: StringTemplateType = 'default'\n _link?: string\n _title?: string\n _queryParams?: { [k: string]: any }\n\n _buttonAction?: TableCellTypeStringConfigAction\n\n _tableCellData?: TableCellData<'string', TableCellTypeConfigString>\n _row?: any\n _rowIndex?: number\n _colData?: TheSeamTableColumn<'string', TableCellTypeConfigString>\n\n _download?: boolean\n _detectMimeContent?: boolean\n\n @Input()\n set title(value: string | undefined) { this.title = value }\n get title(): string | undefined { return this._title }\n\n @HostBinding('attr.title') get _titleAttr() { return this.title || this.value }\n\n canPopover = false\n\n constructor(\n private readonly _cdf: ChangeDetectorRef,\n private readonly _tableCellTypeHelpers: TableCellTypesHelpersService,\n @Optional() private _datatable?: DatatableComponent,\n @Optional() private _table?: TableComponent,\n @Optional() @Inject(TABLE_CELL_DATA) readonly _tableData?: TableCellData<'string', TableCellTypeConfigString>\n ) {\n const _data = _tableData\n this._tableCellData = _tableData\n\n this._row = _data && _data.row\n this._rowIndex = _data && _data.rowIndex\n\n this.value = _data && _data.value\n this._colData = _data && _data.colData\n if (_data && _data.colData && (<any>_data.colData).cellTypeConfig) {\n this.config = (<any>_data.colData).cellTypeConfig\n }\n }\n\n ngOnInit() {\n const _data = this._tableData\n if (_data) {\n _data.changed\n .pipe(takeUntil(this._ngUnsubscribe))\n .subscribe(v => {\n if (v.changes.hasOwnProperty('value')) {\n this.value = v.changes.value.currentValue\n this._cdf.markForCheck()\n }\n\n if (v.changes.hasOwnProperty('colData')) {\n const colData = v.changes.colData.currentValue\n if (colData && colData.cellTypeConfig !== this.config) {\n this.config = colData.cellTypeConfig\n } else {\n this.config = undefined\n }\n this._cdf.markForCheck()\n } else {\n if (v.changes.hasOwnProperty('row')) {\n this.config = this.config\n this._cdf.markForCheck()\n }\n }\n })\n }\n }\n\n ngOnDestroy() {\n this._ngUnsubscribe.next()\n this._ngUnsubscribe.complete()\n }\n\n public setAction(configAction?: TableCellTypeStringConfigAction) {\n let newTplType: StringTemplateType = 'default'\n let link: string | undefined\n let download: boolean = false\n let detectMimeContent = false\n let queryParams: { [k: string]: any } | undefined\n\n if (configAction) {\n if (configAction.type === 'link') {\n link = this._parseConfigValue(configAction.link)\n if (link !== undefined && link !== null) {\n newTplType = this._parseConfigValue(configAction.asset) ? 'link-encrypted' : 'link'\n download = !!this._parseConfigValue(configAction.download)\n detectMimeContent = !!this._parseConfigValue(configAction.detectMimeContent)\n queryParams = this._parseConfigValue(configAction.queryParams)\n }\n } else if (configAction.type === 'modal') {\n newTplType = 'button'\n this._buttonAction = configAction\n }\n }\n\n this._tplType = newTplType\n this._link = link\n this._download = download\n this._detectMimeContent = detectMimeContent\n this._queryParams = queryParams\n }\n\n private _parseConfigValue(val: any) {\n const contextFn = () => this._tableCellTypeHelpers.getValueContext(val, this._tableCellData)\n return this._tableCellTypeHelpers.parseValueProp(val, contextFn)\n }\n\n _doButtonAction() {\n if (this._buttonAction && this._buttonAction.type === 'modal') {\n const contextFn = () => this._tableCellTypeHelpers.getValueContext(this.value, this._tableCellData)\n this._tableCellTypeHelpers.handleModalAction(this._buttonAction, contextFn)\n .subscribe(\n r => {},\n err => console.error(err),\n () => this._actionRefreshRequest()\n )\n }\n }\n\n private _actionRefreshRequest() {\n if (this._datatable) {\n this._datatable.triggerActionRefreshRequest()\n } else if (this._table) {\n this._table.triggerActionRefreshRequest()\n }\n }\n\n}\n","import { ITableCellTypeManifestProvider, TABLE_CELL_TYPE_MANIFEST } from '@theseam/ui-common/table-cell-type'\n\nimport { TableCellTypeCurrencyComponent } from './table-cell-type-currency/table-cell-type-currency.component'\nimport { TableCellTypeDateComponent } from './table-cell-type-date/table-cell-type-date.component'\nimport { TableCellTypeDecimalComponent } from './table-cell-type-decimal/table-cell-type-decimal.component'\nimport { TableCellTypeIconComponent } from './table-cell-type-icon/table-cell-type-icon.component'\nimport { TableCellTypeIntegerComponent } from './table-cell-type-integer/table-cell-type-integer.component'\nimport { TableCellTypePhoneComponent } from './table-cell-type-phone/table-cell-type-phone.component'\n// tslint:disable-next-line: max-line-length\nimport { TableCellTypeProgressCircleIconComponent } from './table-cell-type-progress-circle-icon/table-cell-type-progress-circle-icon.component'\nimport { TableCellTypeProgressCircleComponent } from './table-cell-type-progress-circle/table-cell-type-progress-circle.component'\nimport { TableCellTypeStringComponent } from './table-cell-type-string/table-cell-type-string.component'\n\nexport const TABLE_CELL_TYPE_MANIFEST_STRING: ITableCellTypeManifestProvider = {\n provide: TABLE_CELL_TYPE_MANIFEST,\n useValue: {\n name: 'string',\n component: TableCellTypeStringComponent\n },\n multi: true\n}\n\nexport const TABLE_CELL_TYPE_MANIFEST_CURRENCY: ITableCellTypeManifestProvider = {\n provide: TABLE_CELL_TYPE_MANIFEST,\n useValue: {\n name: 'currency',\n component: TableCellTypeCurrencyComponent\n },\n multi: true\n}\n\nexport const TABLE_CELL_TYPE_MANIFEST_DECIMAL: ITableCellTypeManifestProvider = {\n provide: TABLE_CELL_TYPE_MANIFEST,\n useValue: {\n name: 'decimal',\n component: TableCellTypeDecimalComponent\n },\n multi: true\n}\n\nexport const TABLE_CELL_TYPE_MANIFEST_INTEGER: ITableCellTypeManifestProvider = {\n provide: TABLE_CELL_TYPE_MANIFEST,\n useValue: {\n name: 'integer',\n component: TableCellTypeIntegerComponent\n },\n multi: true\n}\n\nexport const TABLE_CELL_TYPE_MANIFEST_DATE: ITableCellTypeManifestProvider = {\n provide: TABLE_CELL_TYPE_MANIFEST,\n useValue: {\n name: 'date',\n component: TableCellTypeDateComponent\n },\n multi: true\n}\n\nexport const TABLE_CELL_TYPE_MANIFEST_ICON: ITableCellTypeManifestProvider = {\n provide: TABLE_CELL_TYPE_MANIFEST,\n useValue: {\n name: 'icon',\n component: TableCellTypeIconComponent\n },\n multi: true\n}\n\nexport const TABLE_CELL_TYPE_MANIFEST_IMAGE: ITableCellTypeManifestProvider = {\n provide: TABLE_CELL_TYPE_MANIFEST,\n useValue: {\n name: 'image',\n component: TableCellTypeIconComponent\n },\n multi: true\n}\n\nexport const TABLE_CELL_TYPE_MANIFEST_PROGRESS_CIRCLE: ITableCellTypeManifestProvider = {\n provide: TABLE_CELL_TYPE_MANIFEST,\n useValue: {\n name: 'progress-circle',\n component: TableCellTypeProgressCircleComponent\n },\n multi: true\n}\n\nexport const TABLE_CELL_TYPE_MANIFEST_PROGRESS_CIRCLE_ICON: ITableCellTypeManifestProvider = {\n provide: TABLE_CELL_TYPE_MANIFEST,\n useValue: {\n name: 'progress-circle-icon',\n component: TableCellTypeProgressCircleIconComponent\n },\n multi: true\n}\n\nexport const TABLE_CELL_TYPE_MANIFEST_PHONE: ITableCellTypeManifestProvider = {\n provide: TABLE_CELL_TYPE_MANIFEST,\n useValue: {\n name: 'phone',\n component: TableCellTypePhoneComponent\n },\n multi: true\n}\n","import { PortalModule } from '@angular/cdk/portal'\nimport { CommonModule } from '@angular/common'\nimport { NgModule } from '@angular/core'\nimport { RouterModule } from '@angular/router'\n\nimport { NgbTooltipModule } from '@ng-bootstrap/ng-bootstrap'\n\nimport { TheSeamAssetReaderModule } from '@theseam/ui-common/asset-reader'\nimport { TheSeamIconModule } from '@theseam/ui-common/icon'\nimport { TheSeamPopoverModule } from '@theseam/ui-common/popover'\nimport { TheSeamProgressModule } from '@theseam/ui-common/progress'\nimport { TheSeamSharedModule } from '@theseam/ui-common/shared'\nimport { TheSeamTableCellTypeModule } from '@theseam/ui-common/table-cell-type'\nimport { TheSeamTelInputModule } from '@theseam/ui-common/tel-input'\n\nimport { TableCellTypeCurrencyComponent } from './table-cell-type-currency/table-cell-type-currency.component'\nimport { TableCellTypeDateComponent } from './table-cell-type-date/table-cell-type-date.component'\nimport { TableCellTypeDecimalComponent } from './table-cell-type-decimal/table-cell-type-decimal.component'\nimport { TableCellTypeIconComponent } from './table-cell-type-icon/table-cell-type-icon.component'\nimport { TableCellTypeIntegerComponent } from './table-cell-type-integer/table-cell-type-integer.component'\nimport { TableCellTypePhoneComponent } from './table-cell-type-phone/table-cell-type-phone.component'\n// tslint:disable-next-line: max-line-length\nimport { TableCellTypeProgressCircleIconComponent } from './table-cell-type-progress-circle-icon/table-cell-type-progress-circle-icon.component'\nimport { TableCellTypeProgressCircleComponent } from './table-cell-type-progress-circle/table-cell-type-progress-circle.component'\nimport { TableCellTypeStringComponent } from './table-cell-type-string/table-cell-type-string.component'\n\nimport {\n TABLE_CELL_TYPE_MANIFEST_CURRENCY,\n TABLE_CELL_TYPE_MANIFEST_DATE,\n TABLE_CELL_TYPE_MANIFEST_DECIMAL,\n TABLE_CELL_TYPE_MANIFEST_ICON,\n TABLE_CELL_TYPE_MANIFEST_IMAGE,\n TABLE_CELL_TYPE_MANIFEST_INTEGER,\n TABLE_CELL_TYPE_MANIFEST_PHONE,\n TABLE_CELL_TYPE_MANIFEST_PROGRESS_CIRCLE,\n TABLE_CELL_TYPE_MANIFEST_PROGRESS_CIRCLE_ICON,\n TABLE_CELL_TYPE_MANIFEST_STRING\n} from './table-cell-type-manifests'\n\nconst cellTypeComponents = [\n TableCellTypeStringComponent,\n TableCellTypeCurrencyComponent,\n TableCellTypeDateComponent,\n TableCellTypeDecimalComponent,\n TableCellTypeIconComponent,\n TableCellTypeIntegerComponent,\n TableCellTypeProgressCircleComponent,\n TableCellTypeProgressCircleIconComponent,\n TableCellTypePhoneComponent\n]\n\nconst cellTypeProviders = [\n TABLE_CELL_TYPE_MANIFEST_STRING,\n TABLE_CELL_TYPE_MANIFEST_INTEGER,\n TABLE_CELL_TYPE_MANIFEST_CURRENCY,\n TABLE_CELL_TYPE_MANIFEST_DECIMAL,\n TABLE_CELL_TYPE_MANIFEST_DATE,\n TABLE_CELL_TYPE_MANIFEST_ICON,\n TABLE_CELL_TYPE_MANIFEST_IMAGE,\n TABLE_CELL_TYPE_MANIFEST_PROGRESS_CIRCLE,\n TABLE_CELL_TYPE_MANIFEST_PROGRESS_CIRCLE_ICON,\n TABLE_CELL_TYPE_MANIFEST_PHONE\n]\n\n@NgModule({\n declarations: [\n ...cellTypeComponents\n ],\n imports: [\n CommonModule,\n NgbTooltipModule,\n RouterModule,\n TheSeamSharedModule,\n TheSeamIconModule,\n PortalModule,\n TheSeamPopoverModule,\n TheSeamProgressModule,\n TheSeamTelInputModule,\n TheSeamAssetReaderModule,\n TheSeamTableCellTypeModule\n ],\n providers: [\n ...cellTypeProviders\n ],\n exports: [\n ...cellTypeComponents\n ],\n entryComponents: [\n ...cellTypeComponents\n ]\n})\nexport class TheSeamTableCellTypesModule { }\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n\nexport {TableCellTypeConfigProgressCircleIcon as ɵb} from './table-cell-type-progress-circle-icon/table-cell-type-progress-circle-icon-config';\nexport {TableCellTypeConfigProgressCircle as ɵa} from './table-cell-type-progress-circle/table-cell-type-progress-circle-config';"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;MAgBa,8BAA8B;;;IAazC,YACU,IAAuB,EACvB,qBAAmD,EACtB,UAAmE;;QAFhG,SAAI,GAAJ,IAAI,CAAmB;QACvB,0BAAqB,GAArB,qBAAqB,CAA8B;QAb5C,mBAAc,GAAG,IAAI,OAAO,EAAE,CAAA;QAgB7C,MAAM,SAAS,GAAG,UAAU,CAAA;QAC5B,IAAI,CAAC,KAAK,GAAG,SAAS,IAAI,IAAI,CAAC,eAAe,CAAC,SAAS,CAAC,KAAK,EAAE,SAAS,CAAC,CAAA;QAC1E,IAAI,CAAC,GAAG,GAAG,SAAS,IAAI,SAAS,CAAC,GAAG,CAAA;QACrC,IAAI,CAAC,QAAQ,GAAG,SAAS,IAAI,SAAS,CAAC,QAAQ,CAAA;QAC/C,IAAI,CAAC,OAAO,GAAG,SAAS,IAAI,SAAS,CAAC,OAAO,CAAA;QAC7C,IAAI,CAAC,SAAS,GAAG,IAAI,CAAC,iBAAiB,CAAC,MAAA,MAAA,SAAS,aAAT,SAAS,uBAAT,SAAS,CAAE,OAAO,0CAAE,cAAc,0CAAE,SAAS,EAAE,SAAS,CAAC,IAAI,OAAO,CAAA;;QAG5G,IAAI,SAAS,EAAE;YACb,SAAS,CAAC,OAAO;iBACd,IAAI,CAAC,SAAS,CAAC,IAAI,CAAC,cAAc,CAAC,CAAC;iBACpC,SAAS,CAAC,CAAC;gBACV,IAAI,CAAC,CAAC,OAAO,CAAC,cAAc,CAAC,OAAO,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;aACF;;;AC1FD;;;;;;"}
@@ -1 +1 @@
1
- {"version":3,"file":"theseam-ui-common-utils.js","sources":["../../../projects/ui-common/utils/get-attribute.ts","../../../projects/ui-common/utils/has-attribute.ts","../../../projects/ui-common/utils/cdk/get-closest-widget-cdk-drag.ts","../../../projects/ui-common/utils/form/get-control-name.ts","../../../projects/ui-common/utils/form/get-control-path.ts","../../../projects/ui-common/utils/form/observe-control-value.ts","../../../projects/ui-common/utils/form/observe-control-is-different.ts","../../../projects/ui-common/utils/form/wait-on-non-pending-status.ts","../../../projects/ui-common/utils/form/observe-control-status.ts","../../../projects/ui-common/utils/form/observe-control-valid.ts","../../../projects/ui-common/utils/form/observe-control-value-change.ts","../../../projects/ui-common/utils/has-property.ts","../../../projects/ui-common/utils/form/has-required-control.ts","../../../projects/ui-common/utils/form/is-empty-input-value.ts","../../../projects/ui-common/utils/operators/map-each.ts","../../../projects/ui-common/utils/operators/tap-first.ts","../../../projects/ui-common/utils/router/leaf-child-route.ts","../../../projects/ui-common/utils/router/will-have-data-prop.ts","../../../projects/ui-common/utils/router/operators/activated-routes-with-data-property.ts","../../../projects/ui-common/utils/router/route-snapshot-path-relative.ts","../../../projects/ui-common/utils/router/route-snapshot-path-full.ts","../../../projects/ui-common/utils/router/is-empty-url-route.ts","../../../projects/ui-common/utils/calc-percentage.ts","../../../projects/ui-common/utils/toggle-attribute.ts","../../../projects/ui-common/utils/input-masks.ts","../../../projects/ui-common/utils/is-null-or-undefined.ts","../../../projects/ui-common/utils/load-style.ts","../../../projects/ui-common/utils/load-style-sheet.ts","../../../projects/ui-common/utils/obj-utils.ts","../../../projects/ui-common/utils/file-utils.ts","../../../projects/ui-common/utils/not-null-or-undefined.ts","../../../projects/ui-common/utils/wait-on-condition-async.ts","../../../projects/ui-common/utils/polling-ticker.ts","../../../projects/ui-common/utils/refreshable.ts","../../../projects/ui-common/utils/wrap-into-observable.ts","../../../projects/ui-common/utils/is-absolute-url.ts","../../../projects/ui-common/utils/subscriber-count.ts","../../../projects/ui-common/utils/observe-query-list.ts","../../../projects/ui-common/utils/create-padding.ts","../../../projects/ui-common/utils/pad-end.ts","../../../projects/ui-common/utils/pad-start.ts","../../../projects/ui-common/utils/is-numeric.ts","../../../projects/ui-common/utils/fractional-digits-count.ts","../../../projects/ui-common/utils/theseam-ui-common-utils.ts"],"sourcesContent":["/**\n *\n */\nexport function getAttribute<E extends HTMLElement>(element: E, name: string): string | null {\n return element.getAttribute(name)\n}\n","/**\n *\n */\nexport function hasAttribute<E extends HTMLElement>(element: E, name: string): boolean {\n return element.hasAttribute(name)\n}\n","import { CdkDrag } from '@angular/cdk/drag-drop'\nimport { ElementRef } from '@angular/core'\n\nimport { getAttribute } from '../get-attribute'\nimport { hasAttribute } from '../has-attribute'\n\n/**\n * Finds the closest CdkDrag to an element by looking at the DOM.\n * @param element Element relative to which to look for a cdkDrag.\n * @param openDialogs References to the currently available cdkDrag.\n */\nexport function getClosestWidgetCdkDrag(element: ElementRef<HTMLElement>, dragDirectives: CdkDrag<any>[]) {\n let parent: HTMLElement | null = element.nativeElement.parentElement\n\n while (parent && !(parent.classList.contains('cdk-drag') && hasAttribute(parent, 'data-widget-id'))) {\n parent = parent.parentElement\n }\n\n const parentId = parent ? getAttribute(parent, 'data-widget-id') : null\n return parentId ?\n dragDirectives.find(drag => getAttribute(drag.getRootElement(), 'data-widget-id') === parentId)\n : null\n}\n","import { AbstractControl } from '@angular/forms'\n\n/**\n * Get the name of the control.\n *\n * Example:\n *\n * ```js\n * const group = new FormGroup({\n * name: new Control(),\n * age: new Control()\n * })\n *\n * for (const c of group.controls) {\n * console.log(getControlName(c))\n * }\n *\n * // Output:\n * // >> 'name'\n * // >> 'age'\n * ```\n */\nexport function getControlName(c: AbstractControl): string | null {\n if (!c.parent) { return null }\n // NOTE: Typed as 'any' because using string for array index is not valid for\n // array index type, but it works and we actually want the index as a string\n // anyway.\n const controls: any = c.parent.controls\n return Object.keys(controls).find(name => c === controls[name]) || null\n}\n","import { AbstractControl } from '@angular/forms'\n\nimport { getControlName } from './get-control-name'\n\n/**\n * Get the path to a control.\n *\n * The path is built by walking back the `parent` properties until `parent` is\n * `null`.\n *\n * Example:\n *\n * ```js\n * const group = new FormGroup({\n * name: new FormControl(),\n * address: new FormGroup({\n * city: new FormControl(),\n * state: new FormControl()\n * })\n * })\n *\n * const control = group.get('address.city')\n * console.log(getControlPath(control))\n *\n * // Output:\n * >> 'address.city'\n * ```\n *\n */\nexport function getControlPath(c: AbstractControl, path: string = ''): string | null {\n path = getControlName(c) + path\n\n if (c.parent && getControlName(c.parent)) {\n path = '.' + path\n return getControlPath(c.parent, path)\n } else {\n return path\n }\n}\n","import { AbstractControl } from '@angular/forms'\nimport { Observable, of } from 'rxjs'\nimport { startWith, switchMap } from 'rxjs/operators'\n\n/**\n * Observe the value of a control.\n */\nexport function observeControlValue<T = any>(control: AbstractControl): Observable<T> {\n return of(control)\n .pipe(switchMap(_control => _control.valueChanges\n .pipe(startWith(_control.value))\n ))\n}\n","import { AbstractControl } from '@angular/forms'\nimport { Observable } from 'rxjs'\nimport { distinctUntilChanged, map } from 'rxjs/operators'\n\nimport { observeControlValue } from './observe-control-value'\n\n/**\n * Observe the changed state of the input value from the time this function is\n * called.\n *\n * When this function is called the value is stored. Each time the control's\n * value changes the value is compared with the initial value. Currenly the\n * values are compared as stringified objects using `JSON.stringify`.\n *\n * TODO: Allow the value compare implementation to be optionally changed.\n */\nexport function observeControlIsDifferent(control: AbstractControl): Observable<boolean> {\n const _initial = JSON.stringify(control.value)\n return observeControlValue(control)\n .pipe(\n map(value => JSON.stringify(value) !== _initial),\n distinctUntilChanged(),\n )\n}\n","import { AbstractControl } from '@angular/forms'\nimport { interval, merge, Observable } from 'rxjs'\nimport { filter, map, mapTo, startWith, take } from 'rxjs/operators'\n\n/**\n * Wait on the status of a form control to not be `'PENDING'`.\n *\n * NOTE: This function is mainly just a work around for an issue where\n * `statusChanges` sometimes emits `'Pending'` without emitting another state\n * when complete. Seems to happen with async validators if the value changes\n * before completing, even if the validator completes(subscription `complete`\n * if observable).\n */\nexport function waitOnNonPendingStatus(control: AbstractControl): Observable<string> {\n return merge(\n control.statusChanges,\n interval(30).pipe(mapTo(control), map(c => c.status))\n )\n .pipe(startWith(control.status))\n .pipe(filter(v => v !== 'PENDING'))\n .pipe(take(1))\n}\n","import { AbstractControl } from '@angular/forms'\nimport { Observable, of } from 'rxjs'\nimport { startWith, switchMap } from 'rxjs/operators'\n\nimport { waitOnNonPendingStatus } from './wait-on-non-pending-status'\n\n/**\n * Observe the status of a control using a work around for status not changing\n * after pending.\n */\nexport function observeControlStatus(control: AbstractControl): Observable<string> {\n return of(control)\n .pipe(switchMap(_control => _control.statusChanges\n .pipe(startWith(_control.status))\n .pipe(switchMap(status => status === 'PENDING'\n ? waitOnNonPendingStatus(control)\n .pipe(startWith(status))\n : of(status)\n ))\n ))\n}\n","import { AbstractControl } from '@angular/forms'\nimport { Observable } from 'rxjs'\nimport { distinctUntilChanged, map, pairwise, startWith } from 'rxjs/operators'\n\nimport { observeControlStatus } from './observe-control-status'\n\n/**\n * Observe the valid state of a control.\n *\n * By default `waitOnPending` is false and the control states map to:\n * 'VALID' => true\n * 'INVALID' => false\n * 'PENDING' => false\n *\n * If `waitOnPending` is true the valid result when 'PENDING' remains the same\n * as it was before 'PENDING' until it is no longer 'PENDING'.\n */\nexport function observeControlValid(control: AbstractControl, waitOnPending: boolean = false): Observable<boolean> {\n if (waitOnPending) {\n return observeControlStatus(control)\n .pipe(distinctUntilChanged())\n .pipe(startWith(undefined))\n .pipe(pairwise())\n .pipe(map(v => ({ previous: v[0], current: v[1] })))\n .pipe(map(v => v.current === 'PENDING' ? v.previous : v.current))\n .pipe(map(status => status === 'VALID'))\n } else {\n return observeControlStatus(control)\n .pipe(distinctUntilChanged())\n .pipe(map(status => status === 'VALID'))\n }\n}\n","import { AbstractControl } from '@angular/forms'\nimport { Observable } from 'rxjs'\nimport { map, pairwise, startWith } from 'rxjs/operators'\n\nimport { observeControlValue } from './observe-control-value'\n\n/**\n * Observe the value of a control with the previous.\n */\nexport function observeControlValueChange(control: AbstractControl): Observable<{ previous: any, current: any }> {\n return observeControlValue(control)\n .pipe(\n startWith(undefined),\n pairwise(),\n map(v => ({ previous: v[0], current: v[1] }))\n )\n}\n","// Source: https://stackoverflow.com/a/59361497/7926298\nexport function hasProperty<T extends object, K extends keyof T>(\n style: T,\n prop: K\n// ): style is T & { [P in K]-?: Exclude<T[K], undefined> } {\n): style is T & Required<Record<K, Exclude<T[K], undefined>>> {\n return style.hasOwnProperty(prop) && style[prop] !== undefined\n}\n","import { AbstractControl } from '@angular/forms'\n\nimport { hasProperty } from '../has-property'\n\n/**\n * Check if control has a required control.\n *\n * ----------------------------------------------------------------------------\n * NOTE: I am not sure about if this should be used or not.\n *\n * From my understanding this assumes that all the validators do not have some\n * unexpected side-effect from being called like this. It could be argued that\n * the validator is flawed and should be fixed if that is the case, but I am not\n * convinced that is correct yet.\n *\n * An example that I think is valid for this argument: A FormControl configured\n * to only check validators when a specific condition happens, because of a\n * reason that it has to do a long process. In that situation should this\n * function be smart enough to consider that or is it up to the validator to\n * consider this function possibly being used.\n *\n * This seems to assume the required validator will always be a synchronous\n * validator. That is a valid assumption if thinking about showing a required\n * state in the UI, but a FormControl does not neccessarily have to be used in\n * UI. So, I think it could be valid to have an async validator that uses the\n * name `required` for it error, but I do not have a good example, so I could be\n * wrong.\n * ----------------------------------------------------------------------------\n *\n * Source: https://gist.github.com/jsdevtom/5589af349a395b37e699b67417ef025b\n * @experimental\n * @ignore\n */\nexport function hasRequiredControl(abstractControl: AbstractControl): boolean {\n if (abstractControl.validator) {\n const validator = abstractControl.validator({}as AbstractControl)\n if (validator && validator.required) {\n return true\n }\n }\n\n const _abstractControl: any = abstractControl\n if (hasProperty(_abstractControl, 'controls')) {\n for (const controlName in _abstractControl.controls) {\n if (_abstractControl.controls[controlName]) {\n if (hasRequiredControl(_abstractControl.controls[controlName])) {\n return true\n }\n }\n }\n }\n\n return false\n}\n","// Source: https://github.com/angular/angular/blob/master/packages/forms/src/validators.ts#L16\nexport function isEmptyInputValue(value: any): boolean {\n // we don't check for string here so it also works with arrays\n return value == null || value.length === 0\n}\n","import { from, Observable } from 'rxjs'\nimport { map, switchMap, toArray } from 'rxjs/operators'\n\nexport function mapEach<T, R>(predicate: (value: T) => R) {\n return (source$: Observable<T[]>): Observable<R[]> =>\n source$.pipe(switchMap(v => from(v).pipe(map(m => predicate(m)), toArray())))\n}\n","import { Observable } from 'rxjs'\nimport { tap } from 'rxjs/operators'\n\n/**\n * Like tap, but only calls predicate on first emission.\n */\nexport function tapFirst<T>(predicate: (value: T) => void) {\n let _initialized = false\n return (source$: Observable<T>): Observable<T> =>\n source$.pipe(\n tap(v => {\n if (!_initialized) {\n predicate(v)\n _initialized = true\n }\n })\n )\n}\n","import { ActivatedRoute } from '@angular/router'\n\nexport function leafChildRoute(activatedRoute: ActivatedRoute): ActivatedRoute {\n let route = activatedRoute\n while (route.firstChild) { route = route.firstChild }\n return route\n}\n","import { ActivatedRoute } from '@angular/router'\n\nfunction hasRouteConfigDataProp(route: ActivatedRoute, prop: string): boolean {\n return !!(route && route.routeConfig && route.routeConfig.data && route.routeConfig.data.hasOwnProperty(prop))\n}\n\nfunction hasRouteConfigResolveProp(route: ActivatedRoute, prop: string): boolean {\n return !!(route && route.routeConfig && route.routeConfig.resolve && route.routeConfig.resolve.hasOwnProperty(prop))\n}\n\nexport function willHaveDataProp(route: ActivatedRoute, prop: string): boolean {\n return hasRouteConfigDataProp(route, prop) || hasRouteConfigResolveProp(route, prop)\n}\n","import { ActivatedRoute, Data } from '@angular/router'\nimport { combineLatest, Observable } from 'rxjs'\nimport { map, switchMap } from 'rxjs/operators'\n\nimport { leafChildRoute } from '../leaf-child-route'\nimport { willHaveDataProp } from '../will-have-data-prop'\n\nexport interface IActivatedRouteWithData {\n route: ActivatedRoute\n data: Data\n}\n\nexport function activatedRoutesWithDataProperty(prop: string, mustHaveDefined: boolean = false) {\n const _data = (r: ActivatedRoute) => r.data.pipe(map(_d => ({ route: r, data: _d })))\n return (source$: Observable<ActivatedRoute>): Observable<IActivatedRouteWithData[]> =>\n source$.pipe(\n map(route => leafChildRoute(route)),\n map(route => route.pathFromRoot),\n switchMap(routes => combineLatest(routes.map(r => _data(r)))),\n map(v => v.filter(_v => _v.data.hasOwnProperty(prop))),\n map(v => mustHaveDefined\n ? v.filter(_v => willHaveDataProp(_v.route, prop))\n : v\n )\n )\n}\n","import { ActivatedRouteSnapshot } from '@angular/router'\n\nexport function routeSnapshotPathRelative(route: ActivatedRouteSnapshot) {\n return route.url.reduce((path, urlSegment) => path += '/' + urlSegment.path, '')\n}\n","import { ActivatedRouteSnapshot } from '@angular/router'\n\nimport { routeSnapshotPathRelative } from './route-snapshot-path-relative'\n\nexport function routeSnapshotPathFull(route: ActivatedRouteSnapshot) {\n return route.pathFromRoot.reduce((path, _route) => path += routeSnapshotPathRelative(_route), '')\n}\n","import { ActivatedRoute } from '@angular/router'\r\n\r\nexport function isEmptyUrlRoute(activatedRoute: ActivatedRoute): boolean {\r\n return activatedRoute.snapshot.url.length === 0\r\n}\r\n","export function calcPercentage(total: number, n: number) {\n return total && total > 0 ? (n / total) * 100 : 0\n}\n","/**\n * Polyfil for `Element.toggleAttribute`\n *\n * Toggles a value without a value. Useful for attributes, such as `disabled`,\n * `readonly`, and `hidden`, that only needs to exist on the `Element` without\n * requiring a value.\n *\n * Most browsers natively support this feature, but IE, which we still try to\n * support for at least the main parts of the app, has \"Unknown\" support of this\n * feature. Until IE support is dropped this polyfil should be used to toggle an\n * attribute.\n *\n * Source:\n * https://developer.mozilla.org/en-US/docs/Web/API/Element/toggleAttribute#Polyfill\n */\nexport function toggleAttribute(element: HTMLElement, name: string, force: boolean): boolean {\n if (force !== void 0) { force = !!force }\n\n if (element.getAttribute(name) !== null) {\n if (force) { return true }\n\n element.removeAttribute(name)\n return false\n } else {\n if (force === false) { return false }\n\n element.setAttribute(name, '')\n return true\n }\n}\n","export const phoneNumberMask = ['(', /[1-9]/, /\\d/, /\\d/, ')', ' ', /\\d/, /\\d/, /\\d/, '-', /\\d/, /\\d/, /\\d/, /\\d/]\n","export function isNullOrUndefined(value: any) {\n return value === undefined || value === null\n}\n","export function loadStyle(content: string): Promise<HTMLStyleElement> {\n return new Promise((resolve, reject) => {\n const s = document.createElement('style')\n s.onload = () => resolve(s)\n s.onerror = (e) => {\n document.head.removeChild(s)\n reject(e)\n }\n s.innerHTML = content\n document.head.appendChild(s)\n })\n}\n","export function loadStyleSheet(path: string): Promise<HTMLLinkElement> {\n return new Promise((resolve, reject) => {\n const s = document.createElement('link')\n s.onload = () => resolve(s)\n s.onerror = (e) => {\n document.head.removeChild(s)\n reject(e)\n }\n s.rel = 'stylesheet'\n s.href = path\n document.head.appendChild(s)\n })\n}\n","/** Returns object without property */\nexport function withoutProperty<T, K extends keyof T>(obj: T, propName: K): Pick<T, Exclude<keyof T, K>> {\n const { [propName]: _, ...without } = obj\n return without\n}\n\n/** Returns object without properties */\nexport function withoutProperties<T, K extends keyof T>(obj: T, propNames: K[]): Pick<T, Exclude<keyof T, K>> {\n let without: any = obj\n for (const propName of propNames) {\n without = withoutProperty(without, propName)\n }\n return without\n}\n\n/** Delete property of object */\nexport function deleteProperty<T extends {}, K extends keyof T>(obj: T, propName: K): void {\n if (obj.hasOwnProperty(propName)) {\n delete obj[propName]\n }\n}\n\n/** Delete properties of object */\nexport function deleteProperties<T, K extends keyof T>(obj: T, propNames: K[]): void {\n for (const propName of propNames) {\n deleteProperty(obj, propName)\n }\n}\n","import fileType from '@marklb/file-type'\n// import { Buffer } from 'buffer/'\nconst Buffer = require('buffer/').Buffer\n\nexport function readFileAsync(file: any): Promise<ArrayBuffer | null> {\n return new Promise<ArrayBuffer | null>((resolve, reject) => {\n const reader = new FileReader()\n reader.onload = () => {\n resolve(reader.result as ArrayBuffer | null)\n }\n reader.readAsArrayBuffer(file)\n })\n}\n\nexport async function readFileAsDataUrlAsync(file: Blob): Promise<string | null> {\n return new Promise<string | null>((resolve, reject) => {\n const reader = new FileReader()\n reader.onload = () => {\n resolve(reader.result as string | null)\n }\n reader.readAsDataURL(file)\n })\n}\n\nexport async function fileBufferToBlob(\n fileBuffer: Buffer,\n defaultMime: string = 'application/octet-stream'\n): Promise<Blob> {\n const fType = fileType(fileBuffer)\n const mime = (fType) ? fType.mime : defaultMime\n const blob = new Blob([fileBuffer as any], { type: mime })\n return blob\n}\n\nexport async function fileBufferToObjectUrl(\n fileBuffer: Buffer,\n defaultMime: string = 'application/octet-stream'\n): Promise<string> {\n const file = await fileBufferToBlob(fileBuffer, defaultMime)\n const fileURL = URL.createObjectURL(file)\n return fileURL\n}\n\nexport interface IFileData {\n ext?: string\n mime?: string\n blob: Blob\n}\n\nexport async function fileDataFromBuffer(\n fileBuffer: Buffer | Uint8Array | ArrayBuffer,\n defaultMime: string = 'application/octet-stream'\n): Promise<IFileData> {\n const _fileBuffer = Buffer.from(fileBuffer)\n const fType = fileType(_fileBuffer as any)\n const ext = fType && fType.ext || undefined\n const mime = fType ? fType.mime : defaultMime\n const blob = new Blob([_fileBuffer as any], { type: mime })\n const fileData: IFileData = { ext, mime, blob }\n return fileData\n}\n\nexport function openBlob(blob: Blob, target?: string, filename?: string) {\n // NOTE: IE and MSEdge do not allow Blob resources as a source for\n // tabs or iframes. msSaveOrOpenBlob is used as a workaround. I\n // haven't been able to find a way to just open the Blob file in\n // another tab yet for IE or MSEdge.\n if (window.navigator.msSaveOrOpenBlob) {\n window.navigator.msSaveOrOpenBlob(blob, filename)\n } else {\n const url = URL.createObjectURL(blob)\n const win = window.open(url, target)\n // TODO: Consider if always setting opener to null is to restrictive\n // if (win && target && target.toLowerCase() === '_blank') {\n // win.opener = null\n // }\n\n }\n}\n","export function notNullOrUndefined<T>(value: T | null | undefined): value is T {\n return value !== null && value !== undefined\n}\n","export async function waitOnConditionAsync(\n condition: () => boolean,\n timeoutDuration: number = -1,\n throwOnTimeout: boolean = true\n): Promise<any> {\n const timeStart: any = new Date()\n\n const _waitFunc = (callback: (boolean: boolean) => any) => {\n let conditionSuccess = false\n\n if (condition()) {\n callback(true)\n conditionSuccess = true\n }\n\n if (!conditionSuccess) {\n const timeNow: any = new Date()\n const duration = timeNow - timeStart\n if (timeoutDuration > -1 && duration > timeoutDuration) {\n if (throwOnTimeout) {\n throw new Error('Timed out waiting on condition.')\n } else {\n callback(false)\n }\n }\n\n setTimeout(() => { _waitFunc(callback) }, 30)\n }\n }\n\n return new Promise((resolve, reject) => {\n const fn = (b: boolean) => {\n resolve(b)\n }\n _waitFunc(fn)\n })\n}\n","import { isObservable, Observable, Subscriber, Subscription } from 'rxjs'\n\nclass IntervalTimer {\n\n private _intervalTime: number\n private _intervalId: number | null = null\n\n constructor(\n private _callback: () => void,\n intervalTime: number,\n startOnInit: boolean = true\n ) {\n this._intervalTime = intervalTime\n if (startOnInit) {\n this.start()\n }\n }\n\n set intervalTime(time: number) {\n this._intervalTime = time\n }\n\n public start(): void {\n if (this._intervalId === null) {\n this._intervalId = window.setInterval(() => {\n this._callback()\n }, this._intervalTime)\n }\n }\n\n public stop(): void {\n if (this._intervalId !== null) {\n clearInterval(this._intervalId)\n this._intervalId = null\n }\n }\n\n public reset(newIntervalTime?: number): void {\n if (newIntervalTime) {\n this.intervalTime = newIntervalTime\n }\n this.stop()\n this.start()\n }\n\n}\n\nexport type PollingActionFn<R> = () => R | Observable<R>\n\n// tslint:disable:no-inferrable-types\nexport class PollingTickerOptions {\n emitOnInit?: boolean = true\n}\n// tslint:enable:no-inferrable-types\n\n// TODO: Simplify complexity.\n\n/**\n * Call an action and emits the result to its subscriber on an interval or when\n * ticker emits. When the ticker emits, the interval time will reset.\n *\n * When subscribed to, the action will be called and emitted right away unless\n * the `emitOnInit` option is set to false.\n */\nexport function pollingTicker<R>(\n action: PollingActionFn<R>,\n pollingInterval?: number,\n ticker?: Observable<number | void>,\n options?: PollingTickerOptions\n): Observable<R> {\n return new Observable((subscriber: Subscriber<R>) => {\n const _opts = { ...(new PollingTickerOptions()), ...(options || {}) }\n\n let timer: IntervalTimer | null = null\n let actionSub: Subscription | null = null\n let tickerSub: Subscription | null = null\n\n try {\n const handleAction = () => {\n if (timer) { timer.stop() }\n\n const actionResult = action()\n\n if (isObservable(actionResult)) {\n if (actionSub) {\n actionSub.unsubscribe()\n }\n actionSub = actionResult.subscribe(\n (v: R) => { subscriber.next(v); if (timer) { timer.reset() } },\n (err) => { subscriber.error(err) },\n () => {\n actionSub = null\n if (timer) { timer.start() }\n }\n )\n } else {\n subscriber.next(actionResult)\n }\n if (timer) { timer.start() }\n }\n\n if (_opts.emitOnInit) {\n handleAction()\n }\n\n if (pollingInterval) {\n timer = new IntervalTimer(() => {\n handleAction()\n }, pollingInterval)\n }\n\n if (ticker) {\n tickerSub = ticker.subscribe(newPollingInterval => {\n if (newPollingInterval && timer) {\n timer.stop()\n if (newPollingInterval) {\n timer.intervalTime = newPollingInterval\n }\n }\n handleAction()\n if (timer) { timer.reset() }\n })\n }\n } catch (err) {\n subscriber.error(err)\n }\n\n return () => {\n if (timer) {\n timer.stop()\n }\n if (actionSub) {\n actionSub.unsubscribe()\n }\n if (tickerSub) {\n tickerSub.unsubscribe()\n }\n }\n })\n}\n","import { BehaviorSubject, isObservable, Observable, Subject } from 'rxjs'\nimport { distinctUntilChanged, mapTo, publishReplay, refCount, shareReplay, skip, take, tap } from 'rxjs/operators'\n\nimport { tapFirst } from './operators/tap-first'\nimport { pollingTicker } from './polling-ticker'\n\nexport class Refreshable<T> {\n\n private _initialized = false\n private _pollingInterval = new BehaviorSubject<number>(0)\n private _ticker = new Subject<void>()\n private _pending = new BehaviorSubject<boolean>(false)\n\n public data$: Observable<T>\n public pending$: Observable<boolean>\n\n constructor(\n action: () => (T | Observable<T>),\n pollingInterval?: number\n ) {\n if (pollingInterval !== null && pollingInterval !== undefined) {\n this._pollingInterval.next(pollingInterval)\n }\n\n this.pending$ = this._pending.asObservable()\n .pipe(\n distinctUntilChanged(),\n shareReplay(1)\n )\n\n this.data$ = pollingTicker(this._actionHandler(action), pollingInterval, this._ticker)\n .pipe(\n tapFirst(() => this._initialized = true),\n publishReplay(),\n refCount()\n )\n }\n\n get initialized(): boolean { return this._initialized }\n\n /**\n * Intercepts the action call to monitor pending state\n */\n private _actionHandler = (action: () => (T | Observable<T>)) => {\n return () => {\n this._pending.next(true)\n\n const actionResult = action()\n if (isObservable(actionResult)) {\n return actionResult.pipe(tap(() => { this._pending.next(false) }))\n } else {\n this._pending.next(true)\n return actionResult\n }\n }\n }\n\n /**\n * Selects the data observable\n */\n public select(refresh?: boolean): Observable<T> {\n if (refresh && this._initialized && !this._pending.value) { this._ticker.next() }\n return this.data$\n }\n\n public refresh(): Observable<void> {\n let result$: Observable<any>\n\n if (this._initialized) {\n // TODO: Add a test and maybe refactor this to be more clear. It worked in\n // my manual tests, but there may be some situations where this doesn't\n // work, since the ticker isn't the only way to trigger a refresh. Right\n // now it should be fine, but if an async operator is added to be run\n // each time `data$` is subscribed to, then this could fail if the data\n // emits one extra time before the ticker is triggered.\n let _polled = false\n result$ = this.data$\n .pipe(\n tap(_ => !_polled && (_polled = true) && this._ticker.next()),\n skip(1)\n )\n } else {\n result$ = this.data$\n }\n\n return result$\n .pipe(\n take(1),\n mapTo(undefined)\n )\n }\n\n}\n","import { from, isObservable, Observable } from 'rxjs'\n\nexport function wrapIntoObservable<T>(value: T | Promise<T>| Observable<T>): Observable<T> {\n if (isObservable(value)) {\n return value\n }\n\n return from(Promise.resolve(value))\n}\n","\n/**\n * Explaination:\n * ^ - beginning of the string\n * (?: - beginning of a non-captured group\n * [a-z]+ - any character of 'a' to 'z' 1 or more times\n * : - string (colon character)\n * )? - end of the non-captured group. Group appearing 0 or 1 times\n * // - string (two forward slash characters)\n * 'i' - non case-sensitive flag\n *\n * source: https://stackoverflow.com/a/19709846\n */\nconst IS_ABSOLUTE_URL_REGEX = new RegExp('^(?:[a-z]+:)?//', 'i')\n\nexport function isAbsoluteUrl(url: string): boolean {\n return IS_ABSOLUTE_URL_REGEX.test(url)\n}\n","import { Observable, Subscriber } from 'rxjs'\n\n/**\n * This is just for helping debug observables that aren't being unsubscribed\n * from correctly.\n */\nfunction subscriberCount<T>(sourceObservable: Observable<T>, description: string) {\n let counter = 0\n return new Observable((subscriber: Subscriber<T>) => {\n const subscription = sourceObservable.subscribe(subscriber)\n counter++\n console.log(`${description} subscriptions: ${counter}`)\n\n return () => {\n subscription.unsubscribe()\n counter--\n console.log(`${description} subscriptions: ${counter}`)\n }\n })\n}\n","import { QueryList } from '@angular/core'\nimport { Observable } from 'rxjs'\nimport { map, startWith } from 'rxjs/operators'\n\nexport function observeQueryList<T>(queryList: QueryList<T>, emitCurrentValue = true): Observable<T[]> {\n return queryList.changes.pipe(\n startWith(queryList),\n map(v => v.toArray() as T[])\n )\n}\n","\nexport function createPadding(len: number, chars: string): string {\n // if (chars.length <= len) {\n // return chars\n // }\n\n if (chars.length === 0) {\n throw Error(`Padding characters must be at least 1 char length.`)\n }\n\n let str = chars\n while (str.length < len) {\n str += chars\n }\n\n if (str.length > len) {\n str = str.slice(0, len)\n }\n\n return str\n}\n","import { createPadding } from './create-padding'\n\nexport function padEnd(\n stringToPad: string,\n paddingLength: number | undefined = 0,\n paddingChars: string | undefined = ' '\n): string {\n const strLength = paddingLength ? stringToPad.length : 0\n\n if (!paddingLength || strLength >= paddingLength) {\n return stringToPad\n }\n\n return stringToPad + createPadding(paddingLength - strLength, paddingChars)\n}\n","import { createPadding } from './create-padding'\n\nexport function padStart(\n stringToPad: string,\n paddingLength: number | undefined = 0,\n paddingChars: string | undefined = ' '\n): string {\n const strLength = paddingLength ? stringToPad.length : 0\n\n if (!paddingLength || strLength >= paddingLength) {\n return stringToPad\n }\n\n return createPadding(paddingLength - strLength, paddingChars) + stringToPad\n}\n","export function isNumeric(value: any): boolean {\n return !isNaN(Number(value) - parseFloat(value))\n}\n","import { isNumeric } from './is-numeric'\n\n/**\n * Returns the number of fractional digits.\n *\n * NOTE: This is intended for input validation, so trailing 0's will be included\n * in the total. Also, localization is not considered, so '.' is assumed to be\n * the fractional separator.\n */\nexport function fractionalDigitsCount(value: string): number | null {\n if (!isNumeric(value)) {\n return null\n }\n\n const a = value.split('.')\n if (a.length !== 2) {\n return null\n }\n\n return a[1].length\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;AAAA;;;SAGgB,YAAY,CAAwB,OAAU,EAAE,IAAY;IAC1E,OAAO,OAAO,CAAC,YAAY,CAAC,IAAI,CAAC,CAAA;AACnC;;ACLA;;;SAGgB,YAAY,CAAwB,OAAU,EAAE,IAAY;IAC1E,OAAO,OAAO,CAAC,YAAY,CAAC,IAAI,CAAC,CAAA;AACnC;;ACCA;;;;;SAKgB,uBAAuB,CAAC,OAAgC,EAAE,cAA8B;IACtG,IAAI,MAAM,GAAuB,OAAO,CAAC,aAAa,CAAC,aAAa,CAAA;IAEpE,OAAO,MAAM,IAAI,EAAE,MAAM,CAAC,SAAS,CAAC,QAAQ,CAAC,UAAU,CAAC,IAAI,YAAY,CAAC,MAAM,EAAE,gBAAgB,CAAC,CAAC,EAAE;QACnG,MAAM,GAAG,MAAM,CAAC,aAAa,CAAA;KAC9B;IAED,MAAM,QAAQ,GAAG,MAAM,GAAG,YAAY,CAAC,MAAM,EAAE,gBAAgB,CAAC,GAAG,IAAI,CAAA;IACvE,OAAO,QAAQ;QACb,cAAc,CAAC,IAAI,CAAC,IAAI,IAAI,YAAY,CAAC,IAAI,CAAC,cAAc,EAAE,EAAE,gBAAgB,CAAC,KAAK,QAAQ,CAAC;UAC7F,IAAI,CAAA;AACV;;ACpBA;;;;;;;;;;;;;;;;;;;;SAoBgB,cAAc,CAAC,CAAkB;IAC/C,IAAI,CAAC,CAAC,CAAC,MAAM,EAAE;QAAE,OAAO,IAAI,CAAA;KAAE;;;;IAI9B,MAAM,QAAQ,GAAQ,CAAC,CAAC,MAAM,CAAC,QAAQ,CAAA;IACvC,OAAO,MAAM,CAAC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;QAClB,OAAO,IAAI,CAAA;KACZ;IAED,OAAO,CAAC,CAAC,CAAC,CAAC,CAAC,MAAM,CAAA;AACpB;;ACpBA;;;;;;"}
1
+ {"version":3,"file":"theseam-ui-common-utils.js","sources":["../../../projects/ui-common/utils/get-attribute.ts","../../../projects/ui-common/utils/has-attribute.ts","../../../projects/ui-common/utils/cdk/get-closest-widget-cdk-drag.ts","../../../projects/ui-common/utils/form/get-control-name.ts","../../../projects/ui-common/utils/form/get-control-path.ts","../../../projects/ui-common/utils/form/observe-control-value.ts","../../../projects/ui-common/utils/form/observe-control-is-different.ts","../../../projects/ui-common/utils/form/wait-on-non-pending-status.ts","../../../projects/ui-common/utils/form/observe-control-status.ts","../../../projects/ui-common/utils/form/observe-control-valid.ts","../../../projects/ui-common/utils/form/observe-control-value-change.ts","../../../projects/ui-common/utils/has-property.ts","../../../projects/ui-common/utils/form/has-required-control.ts","../../../projects/ui-common/utils/form/is-empty-input-value.ts","../../../projects/ui-common/utils/operators/map-each.ts","../../../projects/ui-common/utils/operators/tap-first.ts","../../../projects/ui-common/utils/router/leaf-child-route.ts","../../../projects/ui-common/utils/router/will-have-data-prop.ts","../../../projects/ui-common/utils/router/operators/activated-routes-with-data-property.ts","../../../projects/ui-common/utils/router/route-snapshot-path-relative.ts","../../../projects/ui-common/utils/router/route-snapshot-path-full.ts","../../../projects/ui-common/utils/router/is-empty-url-route.ts","../../../projects/ui-common/utils/calc-percentage.ts","../../../projects/ui-common/utils/toggle-attribute.ts","../../../projects/ui-common/utils/input-masks.ts","../../../projects/ui-common/utils/is-null-or-undefined.ts","../../../projects/ui-common/utils/load-style.ts","../../../projects/ui-common/utils/load-style-sheet.ts","../../../projects/ui-common/utils/obj-utils.ts","../../../projects/ui-common/utils/file-utils.ts","../../../projects/ui-common/utils/not-null-or-undefined.ts","../../../projects/ui-common/utils/wait-on-condition-async.ts","../../../projects/ui-common/utils/polling-ticker.ts","../../../projects/ui-common/utils/refreshable.ts","../../../projects/ui-common/utils/wrap-into-observable.ts","../../../projects/ui-common/utils/is-absolute-url.ts","../../../projects/ui-common/utils/subscriber-count.ts","../../../projects/ui-common/utils/observe-query-list.ts","../../../projects/ui-common/utils/create-padding.ts","../../../projects/ui-common/utils/pad-end.ts","../../../projects/ui-common/utils/pad-start.ts","../../../projects/ui-common/utils/is-numeric.ts","../../../projects/ui-common/utils/fractional-digits-count.ts","../../../projects/ui-common/utils/theseam-ui-common-utils.ts"],"sourcesContent":["/**\n *\n */\nexport function getAttribute<E extends HTMLElement>(element: E, name: string): string | null {\n return element.getAttribute(name)\n}\n","/**\n *\n */\nexport function hasAttribute<E extends HTMLElement>(element: E, name: string): boolean {\n return element.hasAttribute(name)\n}\n","import { CdkDrag } from '@angular/cdk/drag-drop'\nimport { ElementRef } from '@angular/core'\n\nimport { getAttribute } from '../get-attribute'\nimport { hasAttribute } from '../has-attribute'\n\n/**\n * Finds the closest CdkDrag to an element by looking at the DOM.\n * @param element Element relative to which to look for a cdkDrag.\n * @param openDialogs References to the currently available cdkDrag.\n */\nexport function getClosestWidgetCdkDrag(element: ElementRef<HTMLElement>, dragDirectives: CdkDrag<any>[]) {\n let parent: HTMLElement | null = element.nativeElement.parentElement\n\n while (parent && !(parent.classList.contains('cdk-drag') && hasAttribute(parent, 'data-widget-id'))) {\n parent = parent.parentElement\n }\n\n const parentId = parent ? getAttribute(parent, 'data-widget-id') : null\n return parentId ?\n dragDirectives.find(drag => getAttribute(drag.getRootElement(), 'data-widget-id') === parentId)\n : null\n}\n","import { AbstractControl } from '@angular/forms'\n\n/**\n * Get the name of the control.\n *\n * Example:\n *\n * ```js\n * const group = new FormGroup({\n * name: new Control(),\n * age: new Control()\n * })\n *\n * for (const c of group.controls) {\n * console.log(getControlName(c))\n * }\n *\n * // Output:\n * // >> 'name'\n * // >> 'age'\n * ```\n */\nexport function getControlName(c: AbstractControl): string | null {\n if (!c.parent) { return null }\n // NOTE: Typed as 'any' because using string for array index is not valid for\n // array index type, but it works and we actually want the index as a string\n // anyway.\n const controls: any = c.parent.controls\n return Object.keys(controls).find(name => c === controls[name]) || null\n}\n","import { AbstractControl } from '@angular/forms'\n\nimport { getControlName } from './get-control-name'\n\n/**\n * Get the path to a control.\n *\n * The path is built by walking back the `parent` properties until `parent` is\n * `null`.\n *\n * Example:\n *\n * ```js\n * const group = new FormGroup({\n * name: new FormControl(),\n * address: new FormGroup({\n * city: new FormControl(),\n * state: new FormControl()\n * })\n * })\n *\n * const control = group.get('address.city')\n * console.log(getControlPath(control))\n *\n * // Output:\n * >> 'address.city'\n * ```\n *\n */\nexport function getControlPath(c: AbstractControl, path: string = ''): string | null {\n path = getControlName(c) + path\n\n if (c.parent && getControlName(c.parent)) {\n path = '.' + path\n return getControlPath(c.parent, path)\n } else {\n return path\n }\n}\n","import { AbstractControl } from '@angular/forms'\nimport { Observable, of } from 'rxjs'\nimport { startWith, switchMap } from 'rxjs/operators'\n\n/**\n * Observe the value of a control.\n */\nexport function observeControlValue<T = any>(control: AbstractControl): Observable<T> {\n return of(control)\n .pipe(switchMap(_control => _control.valueChanges\n .pipe(startWith(_control.value))\n ))\n}\n","import { AbstractControl } from '@angular/forms'\nimport { Observable } from 'rxjs'\nimport { distinctUntilChanged, map } from 'rxjs/operators'\n\nimport { observeControlValue } from './observe-control-value'\n\n/**\n * Observe the changed state of the input value from the time this function is\n * called.\n *\n * When this function is called the value is stored. Each time the control's\n * value changes the value is compared with the initial value. Currenly the\n * values are compared as stringified objects using `JSON.stringify`.\n *\n * TODO: Allow the value compare implementation to be optionally changed.\n */\nexport function observeControlIsDifferent(control: AbstractControl): Observable<boolean> {\n const _initial = JSON.stringify(control.value)\n return observeControlValue(control)\n .pipe(\n map(value => JSON.stringify(value) !== _initial),\n distinctUntilChanged(),\n )\n}\n","import { AbstractControl } from '@angular/forms'\nimport { interval, merge, Observable } from 'rxjs'\nimport { filter, map, mapTo, startWith, take } from 'rxjs/operators'\n\n/**\n * Wait on the status of a form control to not be `'PENDING'`.\n *\n * NOTE: This function is mainly just a work around for an issue where\n * `statusChanges` sometimes emits `'Pending'` without emitting another state\n * when complete. Seems to happen with async validators if the value changes\n * before completing, even if the validator completes(subscription `complete`\n * if observable).\n */\nexport function waitOnNonPendingStatus(control: AbstractControl): Observable<string> {\n return merge(\n control.statusChanges,\n interval(30).pipe(mapTo(control), map(c => c.status))\n )\n .pipe(startWith(control.status))\n .pipe(filter(v => v !== 'PENDING'))\n .pipe(take(1))\n}\n","import { AbstractControl } from '@angular/forms'\nimport { Observable, of } from 'rxjs'\nimport { startWith, switchMap } from 'rxjs/operators'\n\nimport { waitOnNonPendingStatus } from './wait-on-non-pending-status'\n\n/**\n * Observe the status of a control using a work around for status not changing\n * after pending.\n */\nexport function observeControlStatus(control: AbstractControl): Observable<string> {\n return of(control)\n .pipe(switchMap(_control => _control.statusChanges\n .pipe(startWith(_control.status))\n .pipe(switchMap(status => status === 'PENDING'\n ? waitOnNonPendingStatus(control)\n .pipe(startWith(status))\n : of(status)\n ))\n ))\n}\n","import { AbstractControl } from '@angular/forms'\nimport { Observable } from 'rxjs'\nimport { distinctUntilChanged, map, pairwise, startWith } from 'rxjs/operators'\n\nimport { observeControlStatus } from './observe-control-status'\n\n/**\n * Observe the valid state of a control.\n *\n * By default `waitOnPending` is false and the control states map to:\n * 'VALID' => true\n * 'INVALID' => false\n * 'PENDING' => false\n *\n * If `waitOnPending` is true the valid result when 'PENDING' remains the same\n * as it was before 'PENDING' until it is no longer 'PENDING'.\n */\nexport function observeControlValid(control: AbstractControl, waitOnPending: boolean = false): Observable<boolean> {\n if (waitOnPending) {\n return observeControlStatus(control)\n .pipe(distinctUntilChanged())\n .pipe(startWith(undefined))\n .pipe(pairwise())\n .pipe(map(v => ({ previous: v[0], current: v[1] })))\n .pipe(map(v => v.current === 'PENDING' ? v.previous : v.current))\n .pipe(map(status => status === 'VALID'))\n } else {\n return observeControlStatus(control)\n .pipe(distinctUntilChanged())\n .pipe(map(status => status === 'VALID'))\n }\n}\n","import { AbstractControl } from '@angular/forms'\nimport { Observable } from 'rxjs'\nimport { map, pairwise, startWith } from 'rxjs/operators'\n\nimport { observeControlValue } from './observe-control-value'\n\n/**\n * Observe the value of a control with the previous.\n */\nexport function observeControlValueChange(control: AbstractControl): Observable<{ previous: any, current: any }> {\n return observeControlValue(control)\n .pipe(\n startWith(undefined),\n pairwise(),\n map(v => ({ previous: v[0], current: v[1] }))\n )\n}\n","// Source: https://stackoverflow.com/a/59361497/7926298\nexport function hasProperty<T extends object, K extends keyof T>(\n style: T,\n prop: K\n// ): style is T & { [P in K]-?: Exclude<T[K], undefined> } {\n): style is T & Required<Record<K, Exclude<T[K], undefined>>> {\n return style.hasOwnProperty(prop) && style[prop] !== undefined\n}\n","import { AbstractControl } from '@angular/forms'\n\nimport { hasProperty } from '../has-property'\n\n/**\n * Check if control has a required control.\n *\n * ----------------------------------------------------------------------------\n * NOTE: I am not sure about if this should be used or not.\n *\n * From my understanding this assumes that all the validators do not have some\n * unexpected side-effect from being called like this. It could be argued that\n * the validator is flawed and should be fixed if that is the case, but I am not\n * convinced that is correct yet.\n *\n * An example that I think is valid for this argument: A FormControl configured\n * to only check validators when a specific condition happens, because of a\n * reason that it has to do a long process. In that situation should this\n * function be smart enough to consider that or is it up to the validator to\n * consider this function possibly being used.\n *\n * This seems to assume the required validator will always be a synchronous\n * validator. That is a valid assumption if thinking about showing a required\n * state in the UI, but a FormControl does not neccessarily have to be used in\n * UI. So, I think it could be valid to have an async validator that uses the\n * name `required` for it error, but I do not have a good example, so I could be\n * wrong.\n * ----------------------------------------------------------------------------\n *\n * Source: https://gist.github.com/jsdevtom/5589af349a395b37e699b67417ef025b\n * @experimental\n * @ignore\n */\nexport function hasRequiredControl(abstractControl: AbstractControl): boolean {\n if (abstractControl.validator) {\n const validator = abstractControl.validator({}as AbstractControl)\n if (validator && validator.required) {\n return true\n }\n }\n\n const _abstractControl: any = abstractControl\n if (hasProperty(_abstractControl, 'controls')) {\n for (const controlName in _abstractControl.controls) {\n if (_abstractControl.controls[controlName]) {\n if (hasRequiredControl(_abstractControl.controls[controlName])) {\n return true\n }\n }\n }\n }\n\n return false\n}\n","// Source: https://github.com/angular/angular/blob/master/packages/forms/src/validators.ts#L16\nexport function isEmptyInputValue(value: any): boolean {\n // we don't check for string here so it also works with arrays\n return value == null || value.length === 0\n}\n","import { from, Observable } from 'rxjs'\nimport { map, switchMap, toArray } from 'rxjs/operators'\n\nexport function mapEach<T, R>(predicate: (value: T) => R) {\n return (source$: Observable<T[]>): Observable<R[]> =>\n source$.pipe(switchMap(v => from(v).pipe(map(m => predicate(m)), toArray())))\n}\n","import { Observable } from 'rxjs'\nimport { tap } from 'rxjs/operators'\n\n/**\n * Like tap, but only calls predicate on first emission.\n */\nexport function tapFirst<T>(predicate: (value: T) => void) {\n let _initialized = false\n return (source$: Observable<T>): Observable<T> =>\n source$.pipe(\n tap(v => {\n if (!_initialized) {\n predicate(v)\n _initialized = true\n }\n })\n )\n}\n","import { ActivatedRoute } from '@angular/router'\n\nexport function leafChildRoute(activatedRoute: ActivatedRoute): ActivatedRoute {\n let route = activatedRoute\n while (route.firstChild) { route = route.firstChild }\n return route\n}\n","import { ActivatedRoute } from '@angular/router'\n\nfunction hasRouteConfigDataProp(route: ActivatedRoute, prop: string): boolean {\n return !!(route && route.routeConfig && route.routeConfig.data && route.routeConfig.data.hasOwnProperty(prop))\n}\n\nfunction hasRouteConfigResolveProp(route: ActivatedRoute, prop: string): boolean {\n return !!(route && route.routeConfig && route.routeConfig.resolve && route.routeConfig.resolve.hasOwnProperty(prop))\n}\n\nexport function willHaveDataProp(route: ActivatedRoute, prop: string): boolean {\n return hasRouteConfigDataProp(route, prop) || hasRouteConfigResolveProp(route, prop)\n}\n","import { ActivatedRoute, Data } from '@angular/router'\nimport { combineLatest, Observable } from 'rxjs'\nimport { map, switchMap } from 'rxjs/operators'\n\nimport { leafChildRoute } from '../leaf-child-route'\nimport { willHaveDataProp } from '../will-have-data-prop'\n\nexport interface IActivatedRouteWithData {\n route: ActivatedRoute\n data: Data\n}\n\nexport function activatedRoutesWithDataProperty(prop: string, mustHaveDefined: boolean = false) {\n const _data = (r: ActivatedRoute) => r.data.pipe(map(_d => ({ route: r, data: _d })))\n return (source$: Observable<ActivatedRoute>): Observable<IActivatedRouteWithData[]> =>\n source$.pipe(\n map(route => leafChildRoute(route)),\n map(route => route.pathFromRoot),\n switchMap(routes => combineLatest(routes.map(r => _data(r)))),\n map(v => v.filter(_v => _v.data.hasOwnProperty(prop))),\n map(v => mustHaveDefined\n ? v.filter(_v => willHaveDataProp(_v.route, prop))\n : v\n )\n )\n}\n","import { ActivatedRouteSnapshot } from '@angular/router'\n\nexport function routeSnapshotPathRelative(route: ActivatedRouteSnapshot) {\n return route.url.reduce((path, urlSegment) => path += '/' + urlSegment.path, '')\n}\n","import { ActivatedRouteSnapshot } from '@angular/router'\n\nimport { routeSnapshotPathRelative } from './route-snapshot-path-relative'\n\nexport function routeSnapshotPathFull(route: ActivatedRouteSnapshot) {\n return route.pathFromRoot.reduce((path, _route) => path += routeSnapshotPathRelative(_route), '')\n}\n","import { ActivatedRoute } from '@angular/router'\n\nexport function isEmptyUrlRoute(activatedRoute: ActivatedRoute): boolean {\n return activatedRoute.snapshot.url.length === 0\n}\n","export function calcPercentage(total: number, n: number) {\n return total && total > 0 ? (n / total) * 100 : 0\n}\n","/**\n * Polyfil for `Element.toggleAttribute`\n *\n * Toggles a value without a value. Useful for attributes, such as `disabled`,\n * `readonly`, and `hidden`, that only needs to exist on the `Element` without\n * requiring a value.\n *\n * Most browsers natively support this feature, but IE, which we still try to\n * support for at least the main parts of the app, has \"Unknown\" support of this\n * feature. Until IE support is dropped this polyfil should be used to toggle an\n * attribute.\n *\n * Source:\n * https://developer.mozilla.org/en-US/docs/Web/API/Element/toggleAttribute#Polyfill\n */\nexport function toggleAttribute(element: HTMLElement, name: string, force: boolean): boolean {\n if (force !== void 0) { force = !!force }\n\n if (element.getAttribute(name) !== null) {\n if (force) { return true }\n\n element.removeAttribute(name)\n return false\n } else {\n if (force === false) { return false }\n\n element.setAttribute(name, '')\n return true\n }\n}\n","export const phoneNumberMask = ['(', /[1-9]/, /\\d/, /\\d/, ')', ' ', /\\d/, /\\d/, /\\d/, '-', /\\d/, /\\d/, /\\d/, /\\d/]\n","export function isNullOrUndefined(value: any) {\n return value === undefined || value === null\n}\n","export function loadStyle(content: string): Promise<HTMLStyleElement> {\n return new Promise((resolve, reject) => {\n const s = document.createElement('style')\n s.onload = () => resolve(s)\n s.onerror = (e) => {\n document.head.removeChild(s)\n reject(e)\n }\n s.innerHTML = content\n document.head.appendChild(s)\n })\n}\n","export function loadStyleSheet(path: string): Promise<HTMLLinkElement> {\n return new Promise((resolve, reject) => {\n const s = document.createElement('link')\n s.onload = () => resolve(s)\n s.onerror = (e) => {\n document.head.removeChild(s)\n reject(e)\n }\n s.rel = 'stylesheet'\n s.href = path\n document.head.appendChild(s)\n })\n}\n","/** Returns object without property */\nexport function withoutProperty<T, K extends keyof T>(obj: T, propName: K): Pick<T, Exclude<keyof T, K>> {\n const { [propName]: _, ...without } = obj\n return without\n}\n\n/** Returns object without properties */\nexport function withoutProperties<T, K extends keyof T>(obj: T, propNames: K[]): Pick<T, Exclude<keyof T, K>> {\n let without: any = obj\n for (const propName of propNames) {\n without = withoutProperty(without, propName)\n }\n return without\n}\n\n/** Delete property of object */\nexport function deleteProperty<T extends {}, K extends keyof T>(obj: T, propName: K): void {\n if (obj.hasOwnProperty(propName)) {\n delete obj[propName]\n }\n}\n\n/** Delete properties of object */\nexport function deleteProperties<T, K extends keyof T>(obj: T, propNames: K[]): void {\n for (const propName of propNames) {\n deleteProperty(obj, propName)\n }\n}\n","import fileType from '@marklb/file-type'\n// import { Buffer } from 'buffer/'\nconst Buffer = require('buffer/').Buffer\n\nexport function readFileAsync(file: any): Promise<ArrayBuffer | null> {\n return new Promise<ArrayBuffer | null>((resolve, reject) => {\n const reader = new FileReader()\n reader.onload = () => {\n resolve(reader.result as ArrayBuffer | null)\n }\n reader.readAsArrayBuffer(file)\n })\n}\n\nexport async function readFileAsDataUrlAsync(file: Blob): Promise<string | null> {\n return new Promise<string | null>((resolve, reject) => {\n const reader = new FileReader()\n reader.onload = () => {\n resolve(reader.result as string | null)\n }\n reader.readAsDataURL(file)\n })\n}\n\nexport async function fileBufferToBlob(\n fileBuffer: Buffer,\n defaultMime: string = 'application/octet-stream'\n): Promise<Blob> {\n const fType = fileType(fileBuffer)\n const mime = (fType) ? fType.mime : defaultMime\n const blob = new Blob([fileBuffer as any], { type: mime })\n return blob\n}\n\nexport async function fileBufferToObjectUrl(\n fileBuffer: Buffer,\n defaultMime: string = 'application/octet-stream'\n): Promise<string> {\n const file = await fileBufferToBlob(fileBuffer, defaultMime)\n const fileURL = URL.createObjectURL(file)\n return fileURL\n}\n\nexport interface IFileData {\n ext?: string\n mime?: string\n blob: Blob\n}\n\nexport async function fileDataFromBuffer(\n fileBuffer: Buffer | Uint8Array | ArrayBuffer,\n defaultMime: string = 'application/octet-stream'\n): Promise<IFileData> {\n const _fileBuffer = Buffer.from(fileBuffer)\n const fType = fileType(_fileBuffer as any)\n const ext = fType && fType.ext || undefined\n const mime = fType ? fType.mime : defaultMime\n const blob = new Blob([_fileBuffer as any], { type: mime })\n const fileData: IFileData = { ext, mime, blob }\n return fileData\n}\n\nexport function openBlob(blob: Blob, target?: string, filename?: string) {\n // NOTE: IE and MSEdge do not allow Blob resources as a source for\n // tabs or iframes. msSaveOrOpenBlob is used as a workaround. I\n // haven't been able to find a way to just open the Blob file in\n // another tab yet for IE or MSEdge.\n if (window.navigator.msSaveOrOpenBlob) {\n window.navigator.msSaveOrOpenBlob(blob, filename)\n } else {\n const url = URL.createObjectURL(blob)\n const win = window.open(url, target)\n // TODO: Consider if always setting opener to null is to restrictive\n // if (win && target && target.toLowerCase() === '_blank') {\n // win.opener = null\n // }\n\n }\n}\n","export function notNullOrUndefined<T>(value: T | null | undefined): value is T {\n return value !== null && value !== undefined\n}\n","export async function waitOnConditionAsync(\n condition: () => boolean,\n timeoutDuration: number = -1,\n throwOnTimeout: boolean = true\n): Promise<any> {\n const timeStart: any = new Date()\n\n const _waitFunc = (callback: (boolean: boolean) => any) => {\n let conditionSuccess = false\n\n if (condition()) {\n callback(true)\n conditionSuccess = true\n }\n\n if (!conditionSuccess) {\n const timeNow: any = new Date()\n const duration = timeNow - timeStart\n if (timeoutDuration > -1 && duration > timeoutDuration) {\n if (throwOnTimeout) {\n throw new Error('Timed out waiting on condition.')\n } else {\n callback(false)\n }\n }\n\n setTimeout(() => { _waitFunc(callback) }, 30)\n }\n }\n\n return new Promise((resolve, reject) => {\n const fn = (b: boolean) => {\n resolve(b)\n }\n _waitFunc(fn)\n })\n}\n","import { isObservable, Observable, Subscriber, Subscription } from 'rxjs'\n\nclass IntervalTimer {\n\n private _intervalTime: number\n private _intervalId: number | null = null\n\n constructor(\n private _callback: () => void,\n intervalTime: number,\n startOnInit: boolean = true\n ) {\n this._intervalTime = intervalTime\n if (startOnInit) {\n this.start()\n }\n }\n\n set intervalTime(time: number) {\n this._intervalTime = time\n }\n\n public start(): void {\n if (this._intervalId === null) {\n this._intervalId = window.setInterval(() => {\n this._callback()\n }, this._intervalTime)\n }\n }\n\n public stop(): void {\n if (this._intervalId !== null) {\n clearInterval(this._intervalId)\n this._intervalId = null\n }\n }\n\n public reset(newIntervalTime?: number): void {\n if (newIntervalTime) {\n this.intervalTime = newIntervalTime\n }\n this.stop()\n this.start()\n }\n\n}\n\nexport type PollingActionFn<R> = () => R | Observable<R>\n\n// tslint:disable:no-inferrable-types\nexport class PollingTickerOptions {\n emitOnInit?: boolean = true\n}\n// tslint:enable:no-inferrable-types\n\n// TODO: Simplify complexity.\n\n/**\n * Call an action and emits the result to its subscriber on an interval or when\n * ticker emits. When the ticker emits, the interval time will reset.\n *\n * When subscribed to, the action will be called and emitted right away unless\n * the `emitOnInit` option is set to false.\n */\nexport function pollingTicker<R>(\n action: PollingActionFn<R>,\n pollingInterval?: number,\n ticker?: Observable<number | void>,\n options?: PollingTickerOptions\n): Observable<R> {\n return new Observable((subscriber: Subscriber<R>) => {\n const _opts = { ...(new PollingTickerOptions()), ...(options || {}) }\n\n let timer: IntervalTimer | null = null\n let actionSub: Subscription | null = null\n let tickerSub: Subscription | null = null\n\n try {\n const handleAction = () => {\n if (timer) { timer.stop() }\n\n const actionResult = action()\n\n if (isObservable(actionResult)) {\n if (actionSub) {\n actionSub.unsubscribe()\n }\n actionSub = actionResult.subscribe(\n (v: R) => { subscriber.next(v); if (timer) { timer.reset() } },\n (err) => { subscriber.error(err) },\n () => {\n actionSub = null\n if (timer) { timer.start() }\n }\n )\n } else {\n subscriber.next(actionResult)\n }\n if (timer) { timer.start() }\n }\n\n if (_opts.emitOnInit) {\n handleAction()\n }\n\n if (pollingInterval) {\n timer = new IntervalTimer(() => {\n handleAction()\n }, pollingInterval)\n }\n\n if (ticker) {\n tickerSub = ticker.subscribe(newPollingInterval => {\n if (newPollingInterval && timer) {\n timer.stop()\n if (newPollingInterval) {\n timer.intervalTime = newPollingInterval\n }\n }\n handleAction()\n if (timer) { timer.reset() }\n })\n }\n } catch (err) {\n subscriber.error(err)\n }\n\n return () => {\n if (timer) {\n timer.stop()\n }\n if (actionSub) {\n actionSub.unsubscribe()\n }\n if (tickerSub) {\n tickerSub.unsubscribe()\n }\n }\n })\n}\n","import { BehaviorSubject, isObservable, Observable, Subject } from 'rxjs'\nimport { distinctUntilChanged, mapTo, publishReplay, refCount, shareReplay, skip, take, tap } from 'rxjs/operators'\n\nimport { tapFirst } from './operators/tap-first'\nimport { pollingTicker } from './polling-ticker'\n\nexport class Refreshable<T> {\n\n private _initialized = false\n private _pollingInterval = new BehaviorSubject<number>(0)\n private _ticker = new Subject<void>()\n private _pending = new BehaviorSubject<boolean>(false)\n\n public data$: Observable<T>\n public pending$: Observable<boolean>\n\n constructor(\n action: () => (T | Observable<T>),\n pollingInterval?: number\n ) {\n if (pollingInterval !== null && pollingInterval !== undefined) {\n this._pollingInterval.next(pollingInterval)\n }\n\n this.pending$ = this._pending.asObservable()\n .pipe(\n distinctUntilChanged(),\n shareReplay(1)\n )\n\n this.data$ = pollingTicker(this._actionHandler(action), pollingInterval, this._ticker)\n .pipe(\n tapFirst(() => this._initialized = true),\n publishReplay(),\n refCount()\n )\n }\n\n get initialized(): boolean { return this._initialized }\n\n /**\n * Intercepts the action call to monitor pending state\n */\n private _actionHandler = (action: () => (T | Observable<T>)) => {\n return () => {\n this._pending.next(true)\n\n const actionResult = action()\n if (isObservable(actionResult)) {\n return actionResult.pipe(tap(() => { this._pending.next(false) }))\n } else {\n this._pending.next(true)\n return actionResult\n }\n }\n }\n\n /**\n * Selects the data observable\n */\n public select(refresh?: boolean): Observable<T> {\n if (refresh && this._initialized && !this._pending.value) { this._ticker.next() }\n return this.data$\n }\n\n public refresh(): Observable<void> {\n let result$: Observable<any>\n\n if (this._initialized) {\n // TODO: Add a test and maybe refactor this to be more clear. It worked in\n // my manual tests, but there may be some situations where this doesn't\n // work, since the ticker isn't the only way to trigger a refresh. Right\n // now it should be fine, but if an async operator is added to be run\n // each time `data$` is subscribed to, then this could fail if the data\n // emits one extra time before the ticker is triggered.\n let _polled = false\n result$ = this.data$\n .pipe(\n tap(_ => !_polled && (_polled = true) && this._ticker.next()),\n skip(1)\n )\n } else {\n result$ = this.data$\n }\n\n return result$\n .pipe(\n take(1),\n mapTo(undefined)\n )\n }\n\n}\n","import { from, isObservable, Observable } from 'rxjs'\n\nexport function wrapIntoObservable<T>(value: T | Promise<T>| Observable<T>): Observable<T> {\n if (isObservable(value)) {\n return value\n }\n\n return from(Promise.resolve(value))\n}\n","\n/**\n * Explaination:\n * ^ - beginning of the string\n * (?: - beginning of a non-captured group\n * [a-z]+ - any character of 'a' to 'z' 1 or more times\n * : - string (colon character)\n * )? - end of the non-captured group. Group appearing 0 or 1 times\n * // - string (two forward slash characters)\n * 'i' - non case-sensitive flag\n *\n * source: https://stackoverflow.com/a/19709846\n */\nconst IS_ABSOLUTE_URL_REGEX = new RegExp('^(?:[a-z]+:)?//', 'i')\n\nexport function isAbsoluteUrl(url: string): boolean {\n return IS_ABSOLUTE_URL_REGEX.test(url)\n}\n","import { Observable, Subscriber } from 'rxjs'\n\n/**\n * This is just for helping debug observables that aren't being unsubscribed\n * from correctly.\n */\nfunction subscriberCount<T>(sourceObservable: Observable<T>, description: string) {\n let counter = 0\n return new Observable((subscriber: Subscriber<T>) => {\n const subscription = sourceObservable.subscribe(subscriber)\n counter++\n console.log(`${description} subscriptions: ${counter}`)\n\n return () => {\n subscription.unsubscribe()\n counter--\n console.log(`${description} subscriptions: ${counter}`)\n }\n })\n}\n","import { QueryList } from '@angular/core'\nimport { Observable } from 'rxjs'\nimport { map, startWith } from 'rxjs/operators'\n\nexport function observeQueryList<T>(queryList: QueryList<T>, emitCurrentValue = true): Observable<T[]> {\n return queryList.changes.pipe(\n startWith(queryList),\n map(v => v.toArray() as T[])\n )\n}\n","\nexport function createPadding(len: number, chars: string): string {\n // if (chars.length <= len) {\n // return chars\n // }\n\n if (chars.length === 0) {\n throw Error(`Padding characters must be at least 1 char length.`)\n }\n\n let str = chars\n while (str.length < len) {\n str += chars\n }\n\n if (str.length > len) {\n str = str.slice(0, len)\n }\n\n return str\n}\n","import { createPadding } from './create-padding'\n\nexport function padEnd(\n stringToPad: string,\n paddingLength: number | undefined = 0,\n paddingChars: string | undefined = ' '\n): string {\n const strLength = paddingLength ? stringToPad.length : 0\n\n if (!paddingLength || strLength >= paddingLength) {\n return stringToPad\n }\n\n return stringToPad + createPadding(paddingLength - strLength, paddingChars)\n}\n","import { createPadding } from './create-padding'\n\nexport function padStart(\n stringToPad: string,\n paddingLength: number | undefined = 0,\n paddingChars: string | undefined = ' '\n): string {\n const strLength = paddingLength ? stringToPad.length : 0\n\n if (!paddingLength || strLength >= paddingLength) {\n return stringToPad\n }\n\n return createPadding(paddingLength - strLength, paddingChars) + stringToPad\n}\n","export function isNumeric(value: any): boolean {\n return !isNaN(Number(value) - parseFloat(value))\n}\n","import { isNumeric } from './is-numeric'\n\n/**\n * Returns the number of fractional digits.\n *\n * NOTE: This is intended for input validation, so trailing 0's will be included\n * in the total. Also, localization is not considered, so '.' is assumed to be\n * the fractional separator.\n */\nexport function fractionalDigitsCount(value: string): number | null {\n if (!isNumeric(value)) {\n return null\n }\n\n const a = value.split('.')\n if (a.length !== 2) {\n return null\n }\n\n return a[1].length\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;AAAA;;;SAGgB,YAAY,CAAwB,OAAU,EAAE,IAAY;IAC1E,OAAO,OAAO,CAAC,YAAY,CAAC,IAAI,CAAC,CAAA;AACnC;;ACLA;;;SAGgB,YAAY,CAAwB,OAAU,EAAE,IAAY;IAC1E,OAAO,OAAO,CAAC,YAAY,CAAC,IAAI,CAAC,CAAA;AACnC;;ACCA;;;;;SAKgB,uBAAuB,CAAC,OAAgC,EAAE,cAA8B;IACtG,IAAI,MAAM,GAAuB,OAAO,CAAC,aAAa,CAAC,aAAa,CAAA;IAEpE,OAAO,MAAM,IAAI,EAAE,MAAM,CAAC,SAAS,CAAC,QAAQ,CAAC,UAAU,CAAC,IAAI,YAAY,CAAC,MAAM,EAAE,gBAAgB,CAAC,CAAC,EAAE;QACnG,MAAM,GAAG,MAAM,CAAC,aAAa,CAAA;KAC9B;IAED,MAAM,QAAQ,GAAG,MAAM,GAAG,YAAY,CAAC,MAAM,EAAE,gBAAgB,CAAC,GAAG,IAAI,CAAA;IACvE,OAAO,QAAQ;QACb,cAAc,CAAC,IAAI,CAAC,IAAI,IAAI,YAAY,CAAC,IAAI,CAAC,cAAc,EAAE,EAAE,gBAAgB,CAAC,KAAK,QAAQ,CAAC;UAC7F,IAAI,CAAA;AACV;;ACpBA;;;;;;;;;;;;;;;;;;;;SAoBgB,cAAc,CAAC,CAAkB;IAC/C,IAAI,CAAC,CAAC,CAAC,MAAM,EAAE;QAAE,OAAO,IAAI,CAAA;KAAE;;;;IAI9B,MAAM,QAAQ,GAAQ,CA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