@nhtio/phone-object 1.20251202.0 → 1.20251205.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.
package/index.d.mts CHANGED
@@ -69,30 +69,36 @@ export declare class Phone implements PhoneModel {
69
69
  * @param {RawCountryType} [country] - The country code of the phone number. If not provided, the country will be guessed based on the phone number.
70
70
  */
71
71
  constructor(phone: RawPhoneType, country?: RawCountryType);
72
+ /**
73
+ * Returns the phone number as a string stripped of all non-numeric characters.
74
+ * @readonly
75
+ * @type {string}
76
+ */
77
+ readonly phone: string;
72
78
  /**
73
79
  * Returns the country code of the phone number.
74
80
  * @readonly
75
81
  * @type {CountryOrUnknown}
76
82
  */
77
- get country(): CountryOrUnknown;
83
+ readonly country: CountryOrUnknown;
78
84
  /**
79
85
  * Returns whether the phone number uses a valid format for the parsed country or not.
80
86
  * @readonly
81
87
  * @type {boolean}
82
88
  */
83
- get valid(): boolean;
89
+ readonly valid: boolean;
84
90
  /**
85
91
  * Returns the type of the phone number.
86
92
  * @readonly
87
93
  * @type {PhoneTypes}
88
94
  */
89
- get type(): PhoneTypes;
95
+ readonly type: PhoneTypes;
90
96
  /**
91
97
  * Returns whether the phone number is a mobile number or not.
92
98
  * @readonly
93
99
  * @type {boolean}
94
100
  */
95
- get mobile(): boolean;
101
+ readonly mobile: boolean;
96
102
  /**
97
103
  * Returns the raw phone number.
98
104
  * @readonly
@@ -101,7 +107,7 @@ export declare class Phone implements PhoneModel {
101
107
  * @remarks
102
108
  * If the phone number is not a valid phone number, the initial phone number which was passed to the constructor is returned.
103
109
  */
104
- get raw(): string;
110
+ readonly raw: string;
105
111
  /**
106
112
  * Returns the national format of the phone number.
107
113
  * @readonly
@@ -110,7 +116,7 @@ export declare class Phone implements PhoneModel {
110
116
  * @remarks
111
117
  * If the phone number is not a valid phone number, the initial phone number which was passed to the constructor is returned.
112
118
  */
113
- get national(): string;
119
+ readonly national: string;
114
120
  /**
115
121
  * Returns the international format of the phone number.
116
122
  * @readonly
@@ -119,7 +125,7 @@ export declare class Phone implements PhoneModel {
119
125
  * @remarks
120
126
  * If the phone number is not a valid phone number, the initial phone number which was passed to the constructor is returned.
121
127
  */
122
- get international(): string;
128
+ readonly international: string;
123
129
  /**
124
130
  * Returns the E.164 format of the phone number.
125
131
  * @readonly
@@ -128,13 +134,13 @@ export declare class Phone implements PhoneModel {
128
134
  * @remarks
129
135
  * If the phone number is not a valid phone number, the initial phone number which was passed to the constructor is returned.
130
136
  */
131
- get e164(): string;
137
+ readonly e164: string;
132
138
  /**
133
139
  * Returns the timezone of the phone number.
134
140
  * @readonly
135
141
  * @type {PossiblePhoneTimezone}
136
142
  */
137
- get timezone(): PossiblePhoneTimezone;
143
+ readonly timezone: PossiblePhoneTimezone;
138
144
  /**
139
145
  * Returns an object representation of the phone number.
140
146
  * @returns {{