@haloduck/ui 2.0.35 → 2.0.36

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.
@@ -3056,19 +3056,40 @@ class TableComponent {
3056
3056
  }
3057
3057
  getNumber(data) {
3058
3058
  const numberPipe = new DecimalPipe('en-US');
3059
- return of(numberPipe.transform(data) || '');
3059
+ try {
3060
+ return of(numberPipe.transform(data) || '');
3061
+ }
3062
+ catch (error) {
3063
+ return of('');
3064
+ }
3060
3065
  }
3061
3066
  getDate(data) {
3062
3067
  const datePipe = new DatePipe('en-US');
3068
+ try {
3069
+ return of(datePipe.transform(data, 'shortDate') || '');
3070
+ }
3071
+ catch (error) {
3072
+ return of('');
3073
+ }
3063
3074
  return of(datePipe.transform(data, 'shortDate') || '');
3064
3075
  }
3065
3076
  getDateTime(data) {
3066
3077
  const datePipe = new DatePipe('en-US');
3067
- return of(datePipe.transform(data, this.coreService.getDateFormatLong()) || '');
3078
+ try {
3079
+ return of(datePipe.transform(data, this.coreService.getDateFormatLong()) || '');
3080
+ }
3081
+ catch (error) {
3082
+ return of('');
3083
+ }
3068
3084
  }
3069
3085
  getTime(data) {
3070
3086
  const datePipe = new DatePipe('en-US');
3071
- return of(datePipe.transform(data, 'Time') || '');
3087
+ try {
3088
+ return of(datePipe.transform(data, 'Time') || '');
3089
+ }
3090
+ catch (error) {
3091
+ return of('');
3092
+ }
3072
3093
  }
3073
3094
  onUpdateSort(field, direction) {
3074
3095
  this.onSortChange.emit({ field, direction });