@acorex/core 19.14.0-next.3 → 19.14.1

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 (49) hide show
  1. package/date-time/index.d.ts +2 -1
  2. package/date-time/lib/calendar.service.d.ts +1 -1
  3. package/date-time/lib/formatters/date.formatter.d.ts +3 -3
  4. package/date-time/lib/formatters/time-duration.formatter.d.ts +3 -0
  5. package/fesm2022/acorex-core-components.mjs.map +1 -1
  6. package/fesm2022/acorex-core-config.mjs.map +1 -1
  7. package/fesm2022/acorex-core-constants.mjs +1 -16
  8. package/fesm2022/acorex-core-constants.mjs.map +1 -1
  9. package/fesm2022/acorex-core-date-time.mjs +135 -103
  10. package/fesm2022/acorex-core-date-time.mjs.map +1 -1
  11. package/fesm2022/acorex-core-events.mjs.map +1 -1
  12. package/fesm2022/acorex-core-file.mjs.map +1 -1
  13. package/fesm2022/acorex-core-format.mjs +39 -39
  14. package/fesm2022/acorex-core-format.mjs.map +1 -1
  15. package/fesm2022/acorex-core-image.mjs.map +1 -1
  16. package/fesm2022/acorex-core-locale-en-AU.profile-DNjKIaZS.mjs.map +1 -1
  17. package/fesm2022/acorex-core-locale.mjs +110 -110
  18. package/fesm2022/acorex-core-locale.mjs.map +1 -1
  19. package/fesm2022/acorex-core-memoize.mjs.map +1 -1
  20. package/fesm2022/acorex-core-network.mjs +42 -43
  21. package/fesm2022/acorex-core-network.mjs.map +1 -1
  22. package/fesm2022/acorex-core-pipes.mjs.map +1 -1
  23. package/fesm2022/acorex-core-platform.mjs +4 -7
  24. package/fesm2022/acorex-core-platform.mjs.map +1 -1
  25. package/fesm2022/acorex-core-storage.mjs.map +1 -1
  26. package/fesm2022/acorex-core-translation.mjs +53 -19
  27. package/fesm2022/acorex-core-translation.mjs.map +1 -1
  28. package/fesm2022/acorex-core-types.mjs +1 -7
  29. package/fesm2022/acorex-core-types.mjs.map +1 -1
  30. package/fesm2022/acorex-core-utils.mjs +120 -115
  31. package/fesm2022/acorex-core-utils.mjs.map +1 -1
  32. package/fesm2022/acorex-core-validation.mjs +12 -8
  33. package/fesm2022/acorex-core-validation.mjs.map +1 -1
  34. package/fesm2022/acorex-core.mjs.map +1 -1
  35. package/format/index.d.ts +1 -1
  36. package/locale/index.d.ts +4 -4
  37. package/locale/lib/locale-profile-provider.service.d.ts +2 -2
  38. package/locale/lib/locale.config.d.ts +1 -1
  39. package/locale/lib/profiles/en-AU.profile.d.ts +1 -1
  40. package/locale/lib/profiles/en-US.profile.d.ts +1 -1
  41. package/locale/lib/profiles/fa-IR.profile.d.ts +1 -1
  42. package/network/index.d.ts +2 -2
  43. package/network/lib/download-task.d.ts +1 -1
  44. package/package.json +1 -1
  45. package/translation/index.d.ts +1 -1
  46. package/translation/lib/translation.parser.d.ts +1 -1
  47. package/translation/lib/translation.resolver.d.ts +1 -1
  48. package/translation/lib/translation.service.d.ts +1 -1
  49. package/utils/index.d.ts +2 -2
@@ -1,9 +1,10 @@
1
1
  export * from './lib/calendar.service';
2
2
  export * from './lib/dateTime.config';
3
- export * from './lib/datetime.types';
4
3
  export * from './lib/datetime.module';
5
4
  export * from './lib/datetime.pipe';
5
+ export * from './lib/datetime.types';
6
6
  export * from './lib/formatters/datetime.formatter';
7
+ export * from './lib/formatters/time-duration.formatter';
7
8
  export * from './lib/formatters/timeleft.formatter';
8
9
  export * from './lib/gregorian.calendar';
9
10
  export * from './lib/holidays.loader';
@@ -1,7 +1,7 @@
1
1
  import { Subject } from 'rxjs';
2
2
  import { AXCalendar, AXDateTime, AXDateValue, AXValidDateTimeValue } from './datetime.types';
3
- import { AXHolidayDate, AXHolidaysLoaderOptions } from './holidays.loader';
4
3
  import { AXDateTimeFormatterOptions } from './formatters/datetime.formatter';
4
+ import { AXHolidayDate, AXHolidaysLoaderOptions } from './holidays.loader';
5
5
  import * as i0 from "@angular/core";
6
6
  export declare class AXCalendarService {
7
7
  private config;
@@ -1,6 +1,6 @@
1
- import { AXFormatter } from "@acorex/core/format";
2
- import { AXValidDateTimeValue } from "../datetime.types";
3
- import { AXDateTimeFormatterOptions } from "./datetime.formatter";
1
+ import { AXFormatter } from '@acorex/core/format';
2
+ import { AXValidDateTimeValue } from '../datetime.types';
3
+ import { AXDateTimeFormatterOptions } from './datetime.formatter';
4
4
  import * as i0 from "@angular/core";
5
5
  export declare class AXDateFormatter implements AXFormatter {
6
6
  private calendarService;
@@ -8,9 +8,12 @@ declare module '@acorex/core/format' {
8
8
  duration: AXTimeDurationFormatterOptions;
9
9
  }
10
10
  }
11
+ type AXTimeDurationUnit = 'YEAR' | 'MONTH' | 'WEEK' | 'DAY' | 'HOUR' | 'MINUTE' | 'SECOND' | 'MILLISECOND';
11
12
  export declare class AXTimeDurationFormatter implements AXFormatter {
12
13
  get name(): string;
13
14
  format(value: number, options?: AXTimeDurationFormatterOptions): string;
15
+ millisecondsToMask(milliseconds: number, start?: AXTimeDurationUnit, end?: string): string;
14
16
  static ɵfac: i0.ɵɵFactoryDeclaration<AXTimeDurationFormatter, never>;
15
17
  static ɵprov: i0.ɵɵInjectableDeclaration<AXTimeDurationFormatter>;
16
18
  }
19
+ export {};
@@ -1 +1 @@
1
- {"version":3,"file":"acorex-core-components.mjs","sources":["../../../../libs/core/components/src/lib/component.service.ts","../../../../libs/core/components/src/acorex-core-components.ts"],"sourcesContent":["import {\n ApplicationRef,\n ComponentRef,\n EmbeddedViewRef,\n inject,\n Injectable,\n TemplateRef,\n ViewContainerRef,\n} from '@angular/core';\nimport { AXComponentType } from './component.types';\n\n@Injectable({\n providedIn: 'root',\n})\nexport class AXComponentService {\n private appRef = inject(ApplicationRef);\n\n private getRootViewContainerRef(): ViewContainerRef | null {\n // Get all components in the application\n const components = this.appRef.components;\n\n if (components.length > 0) {\n const rootComponentRef: ComponentRef<any> = components[0];\n return rootComponentRef.injector.get(ViewContainerRef, null);\n }\n\n return null;\n }\n\n async createFromComponent<T>(content: AXComponentType<T>): Promise<ComponentRef<T>> {\n return this.getRootViewContainerRef().createComponent<T>(content);\n }\n\n async createFromTemplate<T>(content: TemplateRef<T>): Promise<EmbeddedViewRef<T>> {\n return this.getRootViewContainerRef().createEmbeddedView(content);\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;MAca,kBAAkB,CAAA;AAH/B,IAAA,WAAA,GAAA;AAIU,QAAA,IAAA,CAAA,MAAM,GAAG,MAAM,CAAC,cAAc,CAAC;AAqBxC;IAnBS,uBAAuB,GAAA;;AAE7B,QAAA,MAAM,UAAU,GAAG,IAAI,CAAC,MAAM,CAAC,UAAU;AAEzC,QAAA,IAAI,UAAU,CAAC,MAAM,GAAG,CAAC,EAAE;AACzB,YAAA,MAAM,gBAAgB,GAAsB,UAAU,CAAC,CAAC,CAAC;YACzD,OAAO,gBAAgB,CAAC,QAAQ,CAAC,GAAG,CAAC,gBAAgB,EAAE,IAAI,CAAC;;AAG9D,QAAA,OAAO,IAAI;;IAGb,MAAM,mBAAmB,CAAI,OAA2B,EAAA;QACtD,OAAO,IAAI,CAAC,uBAAuB,EAAE,CAAC,eAAe,CAAI,OAAO,CAAC;;IAGnE,MAAM,kBAAkB,CAAI,OAAuB,EAAA;QACjD,OAAO,IAAI,CAAC,uBAAuB,EAAE,CAAC,kBAAkB,CAAC,OAAO,CAAC;;+GApBxD,kBAAkB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,UAAA,EAAA,CAAA,CAAA;AAAlB,IAAA,SAAA,IAAA,CAAA,KAAA,GAAA,EAAA,CAAA,qBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,SAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,kBAAkB,cAFjB,MAAM,EAAA,CAAA,CAAA;;4FAEP,kBAAkB,EAAA,UAAA,EAAA,CAAA;kBAH9B,UAAU;AAAC,YAAA,IAAA,EAAA,CAAA;AACV,oBAAA,UAAU,EAAE,MAAM;AACnB,iBAAA;;;ACbD;;AAEG;;;;"}
1
+ {"version":3,"file":"acorex-core-components.mjs","sources":["../../../../packages/core/components/src/lib/component.service.ts","../../../../packages/core/components/src/acorex-core-components.ts"],"sourcesContent":["import {\n ApplicationRef,\n ComponentRef,\n EmbeddedViewRef,\n inject,\n Injectable,\n TemplateRef,\n ViewContainerRef,\n} from '@angular/core';\nimport { AXComponentType } from './component.types';\n\n@Injectable({\n providedIn: 'root',\n})\nexport class AXComponentService {\n private appRef = inject(ApplicationRef);\n\n private getRootViewContainerRef(): ViewContainerRef | null {\n // Get all components in the application\n const components = this.appRef.components;\n\n if (components.length > 0) {\n const rootComponentRef: ComponentRef<any> = components[0];\n return rootComponentRef.injector.get(ViewContainerRef, null);\n }\n\n return null;\n }\n\n async createFromComponent<T>(content: AXComponentType<T>): Promise<ComponentRef<T>> {\n return this.getRootViewContainerRef().createComponent<T>(content);\n }\n\n async createFromTemplate<T>(content: TemplateRef<T>): Promise<EmbeddedViewRef<T>> {\n return this.getRootViewContainerRef().createEmbeddedView(content);\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;MAca,kBAAkB,CAAA;AAH/B,IAAA,WAAA,GAAA;AAIU,QAAA,IAAA,CAAA,MAAM,GAAG,MAAM,CAAC,cAAc,CAAC;AAqBxC;IAnBS,uBAAuB,GAAA;;AAE7B,QAAA,MAAM,UAAU,GAAG,IAAI,CAAC,MAAM,CAAC,UAAU;AAEzC,QAAA,IAAI,UAAU,CAAC,MAAM,GAAG,CAAC,EAAE;AACzB,YAAA,MAAM,gBAAgB,GAAsB,UAAU,CAAC,CAAC,CAAC;YACzD,OAAO,gBAAgB,CAAC,QAAQ,CAAC,GAAG,CAAC,gBAAgB,EAAE,IAAI,CAAC;;AAG9D,QAAA,OAAO,IAAI;;IAGb,MAAM,mBAAmB,CAAI,OAA2B,EAAA;QACtD,OAAO,IAAI,CAAC,uBAAuB,EAAE,CAAC,eAAe,CAAI,OAAO,CAAC;;IAGnE,MAAM,kBAAkB,CAAI,OAAuB,EAAA;QACjD,OAAO,IAAI,CAAC,uBAAuB,EAAE,CAAC,kBAAkB,CAAC,OAAO,CAAC;;+GApBxD,kBAAkB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,UAAA,EAAA,CAAA,CAAA;AAAlB,IAAA,SAAA,IAAA,CAAA,KAAA,GAAA,EAAA,CAAA,qBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,SAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,kBAAkB,cAFjB,MAAM,EAAA,CAAA,CAAA;;4FAEP,kBAAkB,EAAA,UAAA,EAAA,CAAA;kBAH9B,UAAU;AAAC,YAAA,IAAA,EAAA,CAAA;AACV,oBAAA,UAAU,EAAE,MAAM;AACnB,iBAAA;;;ACbD;;AAEG;;;;"}
@@ -1 +1 @@
1
- {"version":3,"file":"acorex-core-config.mjs","sources":["../../../../libs/core/config/src/lib/configs.ts","../../../../libs/core/config/src/lib/configs.service.ts","../../../../libs/core/config/src/acorex-core-config.ts"],"sourcesContent":["import { InjectionToken } from '@angular/core';\n\nexport type AXGlobalConfig = {\n [key: string]: unknown;\n};\n\nexport const AXGlobalDefaultConfig: AXGlobalConfig = {};\n\nexport const AX_GLOBAL_CONFIG = new InjectionToken<AXGlobalConfig>('AX_GLOBAL_CONFIG', {\n providedIn: 'root',\n factory: () => AXGlobalDefaultConfig,\n});\n","import { Injectable, InjectionToken, Injector } from '@angular/core';\nimport { get } from 'lodash-es';\nimport { AX_GLOBAL_CONFIG } from './configs';\n\n@Injectable({ providedIn: 'root' })\nexport class AXConfigService {\n /**\n * @ignore\n */\n constructor(private injector: Injector) {}\n\n public get<T = string>(key: string, defaultValue?: T) {\n const v1 = this.injector.get(AX_GLOBAL_CONFIG);\n const parts = key.split('.');\n const tokenName = parts.slice(0, parts.length - 1).join('.');\n const providerToken = get(v1, tokenName);\n const v2 = this.injector.get(providerToken as InjectionToken<unknown>);\n return get(v2, parts[parts.length - 1], defaultValue);\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;AAMO,MAAM,qBAAqB,GAAmB;MAExC,gBAAgB,GAAG,IAAI,cAAc,CAAiB,kBAAkB,EAAE;AACrF,IAAA,UAAU,EAAE,MAAM;AAClB,IAAA,OAAO,EAAE,MAAM,qBAAqB;AACrC,CAAA;;MCNY,eAAe,CAAA;AAC1B;;AAEG;AACH,IAAA,WAAA,CAAoB,QAAkB,EAAA;QAAlB,IAAQ,CAAA,QAAA,GAAR,QAAQ;;IAErB,GAAG,CAAa,GAAW,EAAE,YAAgB,EAAA;QAClD,MAAM,EAAE,GAAG,IAAI,CAAC,QAAQ,CAAC,GAAG,CAAC,gBAAgB,CAAC;QAC9C,MAAM,KAAK,GAAG,GAAG,CAAC,KAAK,CAAC,GAAG,CAAC;AAC5B,QAAA,MAAM,SAAS,GAAG,KAAK,CAAC,KAAK,CAAC,CAAC,EAAE,KAAK,CAAC,MAAM,GAAG,CAAC,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC;QAC5D,MAAM,aAAa,GAAG,GAAG,CAAC,EAAE,EAAE,SAAS,CAAC;QACxC,MAAM,EAAE,GAAG,IAAI,CAAC,QAAQ,CAAC,GAAG,CAAC,aAAwC,CAAC;AACtE,QAAA,OAAO,GAAG,CAAC,EAAE,EAAE,KAAK,CAAC,KAAK,CAAC,MAAM,GAAG,CAAC,CAAC,EAAE,YAAY,CAAC;;+GAZ5C,eAAe,EAAA,IAAA,EAAA,CAAA,EAAA,KAAA,EAAA,EAAA,CAAA,QAAA,EAAA,CAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,UAAA,EAAA,CAAA,CAAA;AAAf,IAAA,SAAA,IAAA,CAAA,KAAA,GAAA,EAAA,CAAA,qBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,SAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,eAAe,cADF,MAAM,EAAA,CAAA,CAAA;;4FACnB,eAAe,EAAA,UAAA,EAAA,CAAA;kBAD3B,UAAU;mBAAC,EAAE,UAAU,EAAE,MAAM,EAAE;;;ACJlC;;AAEG;;;;"}
1
+ {"version":3,"file":"acorex-core-config.mjs","sources":["../../../../packages/core/config/src/lib/configs.ts","../../../../packages/core/config/src/lib/configs.service.ts","../../../../packages/core/config/src/acorex-core-config.ts"],"sourcesContent":["import { InjectionToken } from '@angular/core';\n\nexport type AXGlobalConfig = {\n [key: string]: unknown;\n};\n\nexport const AXGlobalDefaultConfig: AXGlobalConfig = {};\n\nexport const AX_GLOBAL_CONFIG = new InjectionToken<AXGlobalConfig>('AX_GLOBAL_CONFIG', {\n providedIn: 'root',\n factory: () => AXGlobalDefaultConfig,\n});\n","import { Injectable, InjectionToken, Injector } from '@angular/core';\nimport { get } from 'lodash-es';\nimport { AX_GLOBAL_CONFIG } from './configs';\n\n@Injectable({ providedIn: 'root' })\nexport class AXConfigService {\n /**\n * @ignore\n */\n constructor(private injector: Injector) {}\n\n public get<T = string>(key: string, defaultValue?: T) {\n const v1 = this.injector.get(AX_GLOBAL_CONFIG);\n const parts = key.split('.');\n const tokenName = parts.slice(0, parts.length - 1).join('.');\n const providerToken = get(v1, tokenName);\n const v2 = this.injector.get(providerToken as InjectionToken<unknown>);\n return get(v2, parts[parts.length - 1], defaultValue);\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;AAMO,MAAM,qBAAqB,GAAmB;MAExC,gBAAgB,GAAG,IAAI,cAAc,CAAiB,kBAAkB,EAAE;AACrF,IAAA,UAAU,EAAE,MAAM;AAClB,IAAA,OAAO,EAAE,MAAM,qBAAqB;AACrC,CAAA;;MCNY,eAAe,CAAA;AAC1B;;AAEG;AACH,IAAA,WAAA,CAAoB,QAAkB,EAAA;QAAlB,IAAQ,CAAA,QAAA,GAAR,QAAQ;;IAErB,GAAG,CAAa,GAAW,EAAE,YAAgB,EAAA;QAClD,MAAM,EAAE,GAAG,IAAI,CAAC,QAAQ,CAAC,GAAG,CAAC,gBAAgB,CAAC;QAC9C,MAAM,KAAK,GAAG,GAAG,CAAC,KAAK,CAAC,GAAG,CAAC;AAC5B,QAAA,MAAM,SAAS,GAAG,KAAK,CAAC,KAAK,CAAC,CAAC,EAAE,KAAK,CAAC,MAAM,GAAG,CAAC,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC;QAC5D,MAAM,aAAa,GAAG,GAAG,CAAC,EAAE,EAAE,SAAS,CAAC;QACxC,MAAM,EAAE,GAAG,IAAI,CAAC,QAAQ,CAAC,GAAG,CAAC,aAAwC,CAAC;AACtE,QAAA,OAAO,GAAG,CAAC,EAAE,EAAE,KAAK,CAAC,KAAK,CAAC,MAAM,GAAG,CAAC,CAAC,EAAE,YAAY,CAAC;;+GAZ5C,eAAe,EAAA,IAAA,EAAA,CAAA,EAAA,KAAA,EAAA,EAAA,CAAA,QAAA,EAAA,CAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,UAAA,EAAA,CAAA,CAAA;AAAf,IAAA,SAAA,IAAA,CAAA,KAAA,GAAA,EAAA,CAAA,qBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,SAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,eAAe,cADF,MAAM,EAAA,CAAA,CAAA;;4FACnB,eAAe,EAAA,UAAA,EAAA,CAAA;kBAD3B,UAAU;mBAAC,EAAE,UAAU,EAAE,MAAM,EAAE;;;ACJlC;;AAEG;;;;"}
@@ -1105,22 +1105,7 @@ const COUNTRIES =
1105
1105
  iso2code: '+7',
1106
1106
  format: '000 000-00-00',
1107
1107
  orderPriority: 1,
1108
- areaCodes: [
1109
- '310',
1110
- '311',
1111
- '312',
1112
- '313',
1113
- '315',
1114
- '318',
1115
- '321',
1116
- '324',
1117
- '325',
1118
- '326',
1119
- '327',
1120
- '336',
1121
- '7172',
1122
- '73622',
1123
- ],
1108
+ areaCodes: ['310', '311', '312', '313', '315', '318', '321', '324', '325', '326', '327', '336', '7172', '73622'],
1124
1109
  bkPosition: {
1125
1110
  x: '-96px',
1126
1111
  y: '-194px',