@skyux/core 6.0.0-beta.7 → 6.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,27 +1,21 @@
1
1
  /**
2
2
  * Provides arguments for the number to format.
3
3
  */
4
- export declare class NumericOptions {
4
+ export interface SkyNumericOptions {
5
5
  /**
6
6
  * Specifies the maximum number of digits after the decimal separator.
7
- * @default 1
8
7
  */
9
8
  digits?: number;
10
9
  /**
11
10
  * Specifies how to format the number. Options are `currency` or `number`.
12
- * @default "number"
13
11
  */
14
12
  format?: string;
15
13
  /**
16
14
  * Specifies the format of the currency.
17
- * @default "standard"
18
15
  */
19
16
  currencySign?: 'accounting' | 'standard';
20
17
  /**
21
- * Specifies the ISO4217 currency code to use for currency formatting. If you do not specify a
22
- * currency code, the component uses the browser's culture to determine the currency unless your
23
- * SPA provides a different culture with `SkyAppLocaleProvider`.
24
- * @default "USD"
18
+ * Specifies the ISO4217 currency code to use for currency formatting.
25
19
  */
26
20
  iso?: string;
27
21
  /**
@@ -40,9 +34,21 @@ export declare class NumericOptions {
40
34
  */
41
35
  truncate?: boolean;
42
36
  /**
43
- * Specifies the starting point after which numbers are shortened to rounded numbers
44
- * and abbreviation characters.
45
- * @default 0
37
+ * Specifies the minimum value at which numbers are shortened to rounded numbers and abbreviation characters. Values less than `1000` are not truncated.
46
38
  */
47
39
  truncateAfter?: number;
48
40
  }
41
+ /**
42
+ * Provides arguments for the number to format.
43
+ * @deprecated Use the `SkyNumericOptions` interface instead.
44
+ */
45
+ export declare class NumericOptions implements SkyNumericOptions {
46
+ digits?: number;
47
+ format?: string;
48
+ currencySign?: 'accounting' | 'standard';
49
+ iso?: string;
50
+ locale?: string;
51
+ minDigits?: number;
52
+ truncate?: boolean;
53
+ truncateAfter?: number;
54
+ }
@@ -1,6 +1,6 @@
1
1
  import { ChangeDetectorRef, OnDestroy, PipeTransform } from '@angular/core';
2
2
  import { SkyAppLocaleProvider } from '@skyux/i18n';
3
- import { NumericOptions } from './numeric.options';
3
+ import { SkyNumericOptions } from './numeric.options';
4
4
  import { SkyNumericService } from './numeric.service';
5
5
  import * as i0 from "@angular/core";
6
6
  /**
@@ -23,7 +23,7 @@ export declare class SkyNumericPipe implements PipeTransform, OnDestroy {
23
23
  private ngUnsubscribe;
24
24
  constructor(localeProvider: SkyAppLocaleProvider, numericService: SkyNumericService, changeDetector: ChangeDetectorRef);
25
25
  ngOnDestroy(): void;
26
- transform(value: number, config?: NumericOptions): string;
26
+ transform(value: number, config?: SkyNumericOptions): string;
27
27
  static ɵfac: i0.ɵɵFactoryDeclaration<SkyNumericPipe, never>;
28
28
  static ɵpipe: i0.ɵɵPipeDeclaration<SkyNumericPipe, "skyNumeric">;
29
29
  }
@@ -1,5 +1,5 @@
1
1
  import { SkyLibResourcesService } from '@skyux/i18n';
2
- import { NumericOptions } from './numeric.options';
2
+ import { SkyNumericOptions } from './numeric.options';
3
3
  import * as i0 from "@angular/core";
4
4
  export declare class SkyNumericService {
5
5
  private resourcesService;
@@ -21,7 +21,7 @@ export declare class SkyNumericService {
21
21
  * @param value The number to format.
22
22
  * @param options Format options.
23
23
  */
24
- formatNumber(value: number, options: NumericOptions): string;
24
+ formatNumber(value: number, options: SkyNumericOptions): string;
25
25
  /**
26
26
  * Rounds a given number
27
27
  *
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@skyux/core",
3
- "version": "6.0.0-beta.7",
3
+ "version": "6.0.0",
4
4
  "author": "Blackbaud, Inc.",
5
5
  "keywords": [
6
6
  "blackbaud",
@@ -44,7 +44,7 @@
44
44
  "@angular/core": "^13.3.2",
45
45
  "@angular/platform-browser": "^13.3.2",
46
46
  "@angular/router": "^13.3.2",
47
- "@skyux/i18n": "6.0.0-beta.7"
47
+ "@skyux/i18n": "6.0.0"
48
48
  },
49
49
  "dependencies": {
50
50
  "tslib": "^2.3.1"