@webority-technologies/mobile-core 0.0.3 → 0.0.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/commonjs/formatters/dateMath.js +292 -0
- package/lib/commonjs/formatters/index.js +67 -0
- package/lib/commonjs/formatters/phone.js +65 -99
- package/lib/commonjs/index.js +66 -0
- package/lib/module/formatters/dateMath.js +277 -0
- package/lib/module/formatters/index.js +1 -0
- package/lib/module/formatters/phone.js +62 -95
- package/lib/module/index.js +1 -1
- package/lib/typescript/commonjs/formatters/dateMath.d.ts +79 -0
- package/lib/typescript/commonjs/formatters/index.d.ts +1 -0
- package/lib/typescript/commonjs/formatters/phone.d.ts +28 -17
- package/lib/typescript/commonjs/index.d.ts +1 -1
- package/lib/typescript/module/formatters/dateMath.d.ts +79 -0
- package/lib/typescript/module/formatters/index.d.ts +1 -0
- package/lib/typescript/module/formatters/phone.d.ts +28 -17
- package/lib/typescript/module/index.d.ts +1 -1
- package/package.json +1 -1
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
import type { DateInput } from './date';
|
|
2
|
+
/**
|
|
3
|
+
* Whether two values fall on the same calendar day in the device's local
|
|
4
|
+
* timezone. Invalid input on either side returns false rather than throwing.
|
|
5
|
+
*/
|
|
6
|
+
export declare const isSameDay: (a: DateInput, b: DateInput) => boolean;
|
|
7
|
+
/** `a` is strictly before `b`. Invalid input on either side returns false. */
|
|
8
|
+
export declare const isDateBefore: (a: DateInput, b: DateInput) => boolean;
|
|
9
|
+
/** `a` is strictly after `b`. Invalid input on either side returns false. */
|
|
10
|
+
export declare const isDateAfter: (a: DateInput, b: DateInput) => boolean;
|
|
11
|
+
/**
|
|
12
|
+
* `a - b` in milliseconds, matching dayjs's `a.diff(b)` sign convention
|
|
13
|
+
* (positive when `a` is later than `b`). Returns `NaN` if either side fails
|
|
14
|
+
* to parse, the same way subtracting two invalid dayjs objects would.
|
|
15
|
+
*/
|
|
16
|
+
export declare const diffMs: (a: DateInput, b: DateInput) => number;
|
|
17
|
+
/**
|
|
18
|
+
* Midnight of the given date, in the device's local timezone. Returns null
|
|
19
|
+
* for unparseable input.
|
|
20
|
+
*/
|
|
21
|
+
export declare const startOfDay: (value: DateInput) => Date | null;
|
|
22
|
+
/**
|
|
23
|
+
* Adds (or, with a negative count, subtracts) whole calendar days in the
|
|
24
|
+
* device's local timezone. Returns null for unparseable input.
|
|
25
|
+
*/
|
|
26
|
+
export declare const addDays: (value: DateInput, count: number) => Date | null;
|
|
27
|
+
/**
|
|
28
|
+
* Small dayjs/moment-style token formatter — YYYY/YY, MMMM/MMM/MM/M,
|
|
29
|
+
* DD/D, dddd/ddd, HH/H (24h), hh/h (12h), mm/m, ss/s, A/a (upper/lower AM/PM).
|
|
30
|
+
* Everything else in the pattern (spaces, commas, colons) passes through
|
|
31
|
+
* literally. Hand-rolled rather than a dependency because this fleet's date
|
|
32
|
+
* formatting needs are a small, closed token set, not general i18n — for
|
|
33
|
+
* genuinely locale-aware output, `formatDate`/`formatTime` (Intl-backed, in
|
|
34
|
+
* `./date`) are the ones to reach for; this is for matching an exact
|
|
35
|
+
* existing pattern (a legacy display string, an API's expected shape).
|
|
36
|
+
*
|
|
37
|
+
* `utc: true` reads every field from the UTC calendar/clock instead of the
|
|
38
|
+
* device's local one — see `formatDateDDMMMYYYY`'s note on why this isn't
|
|
39
|
+
* cosmetic.
|
|
40
|
+
*/
|
|
41
|
+
export declare const formatDatePattern: (value: DateInput, pattern: string, options?: {
|
|
42
|
+
utc?: boolean;
|
|
43
|
+
}) => string;
|
|
44
|
+
/**
|
|
45
|
+
* `DD MMM, YYYY` — zero-padded day, short month, comma, year (e.g.
|
|
46
|
+
* `05 Sep, 2025`). A specific legacy pattern some apps already display,
|
|
47
|
+
* not the fleet's own product convention: `formatDate` (the Intl `style`-based
|
|
48
|
+
* formatter in `./date`) is the one to reach for in new code. This exists so
|
|
49
|
+
* an app already showing this exact pattern can move off a date library
|
|
50
|
+
* without a visible change.
|
|
51
|
+
*
|
|
52
|
+
* `utc: true` reads the calendar day from the UTC fields instead of the
|
|
53
|
+
* device's local ones — matching `dayjs.utc(x).format(...)`, not
|
|
54
|
+
* `dayjs(x).format(...)`. The two disagree whenever local time has crossed a
|
|
55
|
+
* day boundary UTC hasn't yet (or vice versa), so this is not a cosmetic
|
|
56
|
+
* option; pass it only to match a call site that was genuinely UTC-explicit.
|
|
57
|
+
*/
|
|
58
|
+
export declare const formatDateDDMMMYYYY: (value: DateInput, options?: {
|
|
59
|
+
utc?: boolean;
|
|
60
|
+
}) => string;
|
|
61
|
+
/** `YYYY-MM-DD`, in the device's local timezone. */
|
|
62
|
+
export declare const formatDateISO: (value: DateInput) => string;
|
|
63
|
+
/**
|
|
64
|
+
* `hh:mm A` in the device's local timezone — zero-padded 12-hour clock,
|
|
65
|
+
* uppercase AM/PM (e.g. `09:30 PM`).
|
|
66
|
+
*/
|
|
67
|
+
export declare const formatTime12h: (value: DateInput) => string;
|
|
68
|
+
/**
|
|
69
|
+
* `hh:mm a` (zero-padded 12-hour, lowercase am/pm) of the given instant as
|
|
70
|
+
* seen in `ianaTimeZone` (e.g. `Asia/Kolkata`) — not the device's own
|
|
71
|
+
* timezone. Reads the hour/minute/period through `Intl.DateTimeFormat`'s
|
|
72
|
+
* `formatToParts` rather than its assembled string, because the assembled
|
|
73
|
+
* string's spacing before AM/PM varies by JS engine (some insert a narrow
|
|
74
|
+
* no-break space, U+202F, instead of a plain space) and isn't reliably
|
|
75
|
+
* zero-padded either. Throws if `ianaTimeZone` isn't a timezone Intl
|
|
76
|
+
* recognises — the same failure mode as handing dayjs.tz() a bad zone name.
|
|
77
|
+
*/
|
|
78
|
+
export declare const formatTimeInZone: (value: DateInput, ianaTimeZone: string) => string;
|
|
79
|
+
//# sourceMappingURL=dateMath.d.ts.map
|
|
@@ -2,6 +2,7 @@ export type { FormatCurrencyOptions } from './currency';
|
|
|
2
2
|
export { formatCurrency } from './currency';
|
|
3
3
|
export type { DateInput, DateStyle, TimeStyle } from './date';
|
|
4
4
|
export { formatDate, formatDateTime, formatRelativeTime, formatTime } from './date';
|
|
5
|
+
export { addDays, diffMs, formatDateDDMMMYYYY, formatDateISO, formatDatePattern, formatTime12h, formatTimeInZone, isDateAfter, isDateBefore, isSameDay, startOfDay } from './dateMath';
|
|
5
6
|
export { getInitials } from './initials';
|
|
6
7
|
export { formatCompactNumber, formatNumber, formatPercent } from './number';
|
|
7
8
|
export type { FormatPhoneOptions, PhoneCountry, PhoneNumber } from './phone';
|
|
@@ -1,15 +1,21 @@
|
|
|
1
1
|
/**
|
|
2
|
-
*
|
|
3
|
-
*
|
|
4
|
-
*
|
|
5
|
-
*
|
|
6
|
-
*
|
|
7
|
-
* hand-rolling that risks silently-wrong validation for a country nobody
|
|
8
|
-
* tests against. Both live here so consumers get one phone module, not two.
|
|
2
|
+
* The bare 'libphonenumber-js' entry point actually resolves to the library's
|
|
3
|
+
* OWN slimmed-down min/ metadata internally, not its full data - './max' is
|
|
4
|
+
* the variant with complete per-country metadata. Since the reason this
|
|
5
|
+
* module exists is validation and formatting accuracy, the more accurate
|
|
6
|
+
* variant wins throughout this file, not just for validation.
|
|
9
7
|
*/
|
|
10
|
-
|
|
11
|
-
export {
|
|
12
|
-
export
|
|
8
|
+
import { type CountryCode } from 'libphonenumber-js/max';
|
|
9
|
+
export type { PhoneNumber } from 'libphonenumber-js/max';
|
|
10
|
+
export { isValidPhoneNumber, parsePhoneNumber, parsePhoneNumberFromString } from 'libphonenumber-js/max';
|
|
11
|
+
/**
|
|
12
|
+
* Re-exported under our own name rather than importing CountryCode directly
|
|
13
|
+
* everywhere, so a future need to diverge (or re-narrow) has one place to do
|
|
14
|
+
* it. Every ISO 3166-1 alpha-2 code libphonenumber-js recognises - formatPhone
|
|
15
|
+
* and detectPhoneCountry below are genuinely correct for all of them, not a
|
|
16
|
+
* curated subset.
|
|
17
|
+
*/
|
|
18
|
+
export type PhoneCountry = CountryCode;
|
|
13
19
|
export interface FormatPhoneOptions {
|
|
14
20
|
defaultCountryCode?: string;
|
|
15
21
|
country?: PhoneCountry;
|
|
@@ -22,17 +28,22 @@ export declare const normalizePhone: (input: string) => string;
|
|
|
22
28
|
/**
|
|
23
29
|
* Detect the country of a phone number: from its own `+` country code when
|
|
24
30
|
* present, otherwise from `defaultCountryCode`. Returns null when neither
|
|
25
|
-
*
|
|
31
|
+
* parses to a recognised country.
|
|
26
32
|
*/
|
|
27
33
|
export declare const detectPhoneCountry: (input: string, defaultCountryCode?: string) => PhoneCountry | null;
|
|
28
34
|
/**
|
|
29
|
-
* Format a phone number for human display
|
|
35
|
+
* Format a phone number for human display, via libphonenumber-js's own
|
|
36
|
+
* per-country formatting rather than a hand-rolled grouping table - correct
|
|
37
|
+
* for every country it recognises, not a curated subset.
|
|
30
38
|
*
|
|
31
|
-
* -
|
|
32
|
-
* -
|
|
33
|
-
*
|
|
34
|
-
*
|
|
35
|
-
*
|
|
39
|
+
* - A number that already carries a `+` country code formats for that country.
|
|
40
|
+
* - A bare national number formats for `options.country` when given, else for
|
|
41
|
+
* the country implied by `defaultCountryCode` (default `+91`).
|
|
42
|
+
* - `includeCountryCode` controls international vs national format; defaults
|
|
43
|
+
* to international whenever the country was detected rather than passed in
|
|
44
|
+
* explicitly as `options.country`, and to national when it was.
|
|
45
|
+
* - Input libphonenumber-js can't parse into a valid number for the resolved
|
|
46
|
+
* country falls back to a best-effort `+CC NNNN NNNN…` digit grouping.
|
|
36
47
|
*/
|
|
37
48
|
export declare function formatPhone(input: string, defaultCountryCode?: string): string;
|
|
38
49
|
export declare function formatPhone(input: string, options?: FormatPhoneOptions): string;
|
|
@@ -29,7 +29,7 @@ export { getConfig, getConfigValue, resetConfig, setConfig } from './config';
|
|
|
29
29
|
export type { DeepLinkConfig, DeepLinkRoute, ParsedLink } from './deepLink';
|
|
30
30
|
export { DeepLink, parseDeepLink, useDeepLink } from './deepLink';
|
|
31
31
|
export type { DateInput, DateStyle, FormatCurrencyOptions, FormatPhoneOptions, PhoneCountry, PhoneNumber, TimeStyle } from './formatters';
|
|
32
|
-
export { detectPhoneCountry, formatCompactNumber, formatCurrency, formatDate, formatDateTime, formatNumber, formatPercent, formatPhone, formatRelativeTime, formatTime, getInitials, isValidPhoneNumber, normalizePhone, parsePhoneNumber, parsePhoneNumberFromString } from './formatters';
|
|
32
|
+
export { addDays, detectPhoneCountry, diffMs, formatCompactNumber, formatCurrency, formatDate, formatDateDDMMMYYYY, formatDateISO, formatDatePattern, formatDateTime, formatNumber, formatPercent, formatPhone, formatRelativeTime, formatTime, formatTime12h, formatTimeInZone, getInitials, isDateAfter, isDateBefore, isSameDay, isValidPhoneNumber, normalizePhone, parsePhoneNumber, parsePhoneNumberFromString, startOfDay } from './formatters';
|
|
33
33
|
export type { InitConfig } from './initSDK';
|
|
34
34
|
export { initWebority } from './initSDK';
|
|
35
35
|
export type { AuthActions } from './initUserAuth';
|
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
import type { DateInput } from './date.js';
|
|
2
|
+
/**
|
|
3
|
+
* Whether two values fall on the same calendar day in the device's local
|
|
4
|
+
* timezone. Invalid input on either side returns false rather than throwing.
|
|
5
|
+
*/
|
|
6
|
+
export declare const isSameDay: (a: DateInput, b: DateInput) => boolean;
|
|
7
|
+
/** `a` is strictly before `b`. Invalid input on either side returns false. */
|
|
8
|
+
export declare const isDateBefore: (a: DateInput, b: DateInput) => boolean;
|
|
9
|
+
/** `a` is strictly after `b`. Invalid input on either side returns false. */
|
|
10
|
+
export declare const isDateAfter: (a: DateInput, b: DateInput) => boolean;
|
|
11
|
+
/**
|
|
12
|
+
* `a - b` in milliseconds, matching dayjs's `a.diff(b)` sign convention
|
|
13
|
+
* (positive when `a` is later than `b`). Returns `NaN` if either side fails
|
|
14
|
+
* to parse, the same way subtracting two invalid dayjs objects would.
|
|
15
|
+
*/
|
|
16
|
+
export declare const diffMs: (a: DateInput, b: DateInput) => number;
|
|
17
|
+
/**
|
|
18
|
+
* Midnight of the given date, in the device's local timezone. Returns null
|
|
19
|
+
* for unparseable input.
|
|
20
|
+
*/
|
|
21
|
+
export declare const startOfDay: (value: DateInput) => Date | null;
|
|
22
|
+
/**
|
|
23
|
+
* Adds (or, with a negative count, subtracts) whole calendar days in the
|
|
24
|
+
* device's local timezone. Returns null for unparseable input.
|
|
25
|
+
*/
|
|
26
|
+
export declare const addDays: (value: DateInput, count: number) => Date | null;
|
|
27
|
+
/**
|
|
28
|
+
* Small dayjs/moment-style token formatter — YYYY/YY, MMMM/MMM/MM/M,
|
|
29
|
+
* DD/D, dddd/ddd, HH/H (24h), hh/h (12h), mm/m, ss/s, A/a (upper/lower AM/PM).
|
|
30
|
+
* Everything else in the pattern (spaces, commas, colons) passes through
|
|
31
|
+
* literally. Hand-rolled rather than a dependency because this fleet's date
|
|
32
|
+
* formatting needs are a small, closed token set, not general i18n — for
|
|
33
|
+
* genuinely locale-aware output, `formatDate`/`formatTime` (Intl-backed, in
|
|
34
|
+
* `./date`) are the ones to reach for; this is for matching an exact
|
|
35
|
+
* existing pattern (a legacy display string, an API's expected shape).
|
|
36
|
+
*
|
|
37
|
+
* `utc: true` reads every field from the UTC calendar/clock instead of the
|
|
38
|
+
* device's local one — see `formatDateDDMMMYYYY`'s note on why this isn't
|
|
39
|
+
* cosmetic.
|
|
40
|
+
*/
|
|
41
|
+
export declare const formatDatePattern: (value: DateInput, pattern: string, options?: {
|
|
42
|
+
utc?: boolean;
|
|
43
|
+
}) => string;
|
|
44
|
+
/**
|
|
45
|
+
* `DD MMM, YYYY` — zero-padded day, short month, comma, year (e.g.
|
|
46
|
+
* `05 Sep, 2025`). A specific legacy pattern some apps already display,
|
|
47
|
+
* not the fleet's own product convention: `formatDate` (the Intl `style`-based
|
|
48
|
+
* formatter in `./date`) is the one to reach for in new code. This exists so
|
|
49
|
+
* an app already showing this exact pattern can move off a date library
|
|
50
|
+
* without a visible change.
|
|
51
|
+
*
|
|
52
|
+
* `utc: true` reads the calendar day from the UTC fields instead of the
|
|
53
|
+
* device's local ones — matching `dayjs.utc(x).format(...)`, not
|
|
54
|
+
* `dayjs(x).format(...)`. The two disagree whenever local time has crossed a
|
|
55
|
+
* day boundary UTC hasn't yet (or vice versa), so this is not a cosmetic
|
|
56
|
+
* option; pass it only to match a call site that was genuinely UTC-explicit.
|
|
57
|
+
*/
|
|
58
|
+
export declare const formatDateDDMMMYYYY: (value: DateInput, options?: {
|
|
59
|
+
utc?: boolean;
|
|
60
|
+
}) => string;
|
|
61
|
+
/** `YYYY-MM-DD`, in the device's local timezone. */
|
|
62
|
+
export declare const formatDateISO: (value: DateInput) => string;
|
|
63
|
+
/**
|
|
64
|
+
* `hh:mm A` in the device's local timezone — zero-padded 12-hour clock,
|
|
65
|
+
* uppercase AM/PM (e.g. `09:30 PM`).
|
|
66
|
+
*/
|
|
67
|
+
export declare const formatTime12h: (value: DateInput) => string;
|
|
68
|
+
/**
|
|
69
|
+
* `hh:mm a` (zero-padded 12-hour, lowercase am/pm) of the given instant as
|
|
70
|
+
* seen in `ianaTimeZone` (e.g. `Asia/Kolkata`) — not the device's own
|
|
71
|
+
* timezone. Reads the hour/minute/period through `Intl.DateTimeFormat`'s
|
|
72
|
+
* `formatToParts` rather than its assembled string, because the assembled
|
|
73
|
+
* string's spacing before AM/PM varies by JS engine (some insert a narrow
|
|
74
|
+
* no-break space, U+202F, instead of a plain space) and isn't reliably
|
|
75
|
+
* zero-padded either. Throws if `ianaTimeZone` isn't a timezone Intl
|
|
76
|
+
* recognises — the same failure mode as handing dayjs.tz() a bad zone name.
|
|
77
|
+
*/
|
|
78
|
+
export declare const formatTimeInZone: (value: DateInput, ianaTimeZone: string) => string;
|
|
79
|
+
//# sourceMappingURL=dateMath.d.ts.map
|
|
@@ -2,6 +2,7 @@ export type { FormatCurrencyOptions } from './currency.js';
|
|
|
2
2
|
export { formatCurrency } from './currency.js';
|
|
3
3
|
export type { DateInput, DateStyle, TimeStyle } from './date.js';
|
|
4
4
|
export { formatDate, formatDateTime, formatRelativeTime, formatTime } from './date.js';
|
|
5
|
+
export { addDays, diffMs, formatDateDDMMMYYYY, formatDateISO, formatDatePattern, formatTime12h, formatTimeInZone, isDateAfter, isDateBefore, isSameDay, startOfDay } from './dateMath.js';
|
|
5
6
|
export { getInitials } from './initials.js';
|
|
6
7
|
export { formatCompactNumber, formatNumber, formatPercent } from './number.js';
|
|
7
8
|
export type { FormatPhoneOptions, PhoneCountry, PhoneNumber } from './phone.js';
|
|
@@ -1,15 +1,21 @@
|
|
|
1
1
|
/**
|
|
2
|
-
*
|
|
3
|
-
*
|
|
4
|
-
*
|
|
5
|
-
*
|
|
6
|
-
*
|
|
7
|
-
* hand-rolling that risks silently-wrong validation for a country nobody
|
|
8
|
-
* tests against. Both live here so consumers get one phone module, not two.
|
|
2
|
+
* The bare 'libphonenumber-js' entry point actually resolves to the library's
|
|
3
|
+
* OWN slimmed-down min/ metadata internally, not its full data - './max' is
|
|
4
|
+
* the variant with complete per-country metadata. Since the reason this
|
|
5
|
+
* module exists is validation and formatting accuracy, the more accurate
|
|
6
|
+
* variant wins throughout this file, not just for validation.
|
|
9
7
|
*/
|
|
10
|
-
|
|
11
|
-
export {
|
|
12
|
-
export
|
|
8
|
+
import { type CountryCode } from 'libphonenumber-js/max';
|
|
9
|
+
export type { PhoneNumber } from 'libphonenumber-js/max';
|
|
10
|
+
export { isValidPhoneNumber, parsePhoneNumber, parsePhoneNumberFromString } from 'libphonenumber-js/max';
|
|
11
|
+
/**
|
|
12
|
+
* Re-exported under our own name rather than importing CountryCode directly
|
|
13
|
+
* everywhere, so a future need to diverge (or re-narrow) has one place to do
|
|
14
|
+
* it. Every ISO 3166-1 alpha-2 code libphonenumber-js recognises - formatPhone
|
|
15
|
+
* and detectPhoneCountry below are genuinely correct for all of them, not a
|
|
16
|
+
* curated subset.
|
|
17
|
+
*/
|
|
18
|
+
export type PhoneCountry = CountryCode;
|
|
13
19
|
export interface FormatPhoneOptions {
|
|
14
20
|
defaultCountryCode?: string;
|
|
15
21
|
country?: PhoneCountry;
|
|
@@ -22,17 +28,22 @@ export declare const normalizePhone: (input: string) => string;
|
|
|
22
28
|
/**
|
|
23
29
|
* Detect the country of a phone number: from its own `+` country code when
|
|
24
30
|
* present, otherwise from `defaultCountryCode`. Returns null when neither
|
|
25
|
-
*
|
|
31
|
+
* parses to a recognised country.
|
|
26
32
|
*/
|
|
27
33
|
export declare const detectPhoneCountry: (input: string, defaultCountryCode?: string) => PhoneCountry | null;
|
|
28
34
|
/**
|
|
29
|
-
* Format a phone number for human display
|
|
35
|
+
* Format a phone number for human display, via libphonenumber-js's own
|
|
36
|
+
* per-country formatting rather than a hand-rolled grouping table - correct
|
|
37
|
+
* for every country it recognises, not a curated subset.
|
|
30
38
|
*
|
|
31
|
-
* -
|
|
32
|
-
* -
|
|
33
|
-
*
|
|
34
|
-
*
|
|
35
|
-
*
|
|
39
|
+
* - A number that already carries a `+` country code formats for that country.
|
|
40
|
+
* - A bare national number formats for `options.country` when given, else for
|
|
41
|
+
* the country implied by `defaultCountryCode` (default `+91`).
|
|
42
|
+
* - `includeCountryCode` controls international vs national format; defaults
|
|
43
|
+
* to international whenever the country was detected rather than passed in
|
|
44
|
+
* explicitly as `options.country`, and to national when it was.
|
|
45
|
+
* - Input libphonenumber-js can't parse into a valid number for the resolved
|
|
46
|
+
* country falls back to a best-effort `+CC NNNN NNNN…` digit grouping.
|
|
36
47
|
*/
|
|
37
48
|
export declare function formatPhone(input: string, defaultCountryCode?: string): string;
|
|
38
49
|
export declare function formatPhone(input: string, options?: FormatPhoneOptions): string;
|
|
@@ -29,7 +29,7 @@ export { getConfig, getConfigValue, resetConfig, setConfig } from './config/inde
|
|
|
29
29
|
export type { DeepLinkConfig, DeepLinkRoute, ParsedLink } from './deepLink/index.js';
|
|
30
30
|
export { DeepLink, parseDeepLink, useDeepLink } from './deepLink/index.js';
|
|
31
31
|
export type { DateInput, DateStyle, FormatCurrencyOptions, FormatPhoneOptions, PhoneCountry, PhoneNumber, TimeStyle } from './formatters/index.js';
|
|
32
|
-
export { detectPhoneCountry, formatCompactNumber, formatCurrency, formatDate, formatDateTime, formatNumber, formatPercent, formatPhone, formatRelativeTime, formatTime, getInitials, isValidPhoneNumber, normalizePhone, parsePhoneNumber, parsePhoneNumberFromString } from './formatters/index.js';
|
|
32
|
+
export { addDays, detectPhoneCountry, diffMs, formatCompactNumber, formatCurrency, formatDate, formatDateDDMMMYYYY, formatDateISO, formatDatePattern, formatDateTime, formatNumber, formatPercent, formatPhone, formatRelativeTime, formatTime, formatTime12h, formatTimeInZone, getInitials, isDateAfter, isDateBefore, isSameDay, isValidPhoneNumber, normalizePhone, parsePhoneNumber, parsePhoneNumberFromString, startOfDay } from './formatters/index.js';
|
|
33
33
|
export type { InitConfig } from './initSDK.js';
|
|
34
34
|
export { initWebority } from './initSDK.js';
|
|
35
35
|
export type { AuthActions } from './initUserAuth.js';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@webority-technologies/mobile-core",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.5",
|
|
4
4
|
"description": "Platform layer for Webority React Native apps: HTTP clients, auth/token storage, config, logging, formatters, validators, network status, permissions, storage and version checks. No UI.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"react-native",
|